Merge branch 'master' into glitch-soc/merge

This commit is contained in:
Thibaut Girka
2018-05-14 20:51:50 +02:00
36 changed files with 314 additions and 260 deletions

View File

@ -68,6 +68,7 @@ module Mastodon
:'pt-BR',
:ru,
:sk,
:sl,
:sr,
:'sr-Latn',
:sv,

View File

@ -693,6 +693,7 @@ en:
video:
one: "%{count} video"
other: "%{count} videos"
boosted_from_html: Boosted from %{acct_link}
content_warning: 'Content warning: %{warning}'
disallowed_hashtags:
one: 'contained a disallowed hashtag: %{tags}'

View File

@ -326,7 +326,7 @@ Rails.application.routes.draw do
end
namespace :push do
resource :subscription, only: [:create, :update, :destroy]
resource :subscription, only: [:create, :show, :update, :destroy]
end
end

View File

@ -80,7 +80,10 @@ module.exports = {
settings,
core,
flavours,
env,
env: {
CDN_HOST: env.CDN_HOST,
NODE_ENV: env.NODE_ENV,
},
loadersDir,
output,
};

View File

@ -6,7 +6,7 @@ const CompressionPlugin = require('compression-webpack-plugin');
const sharedConfig = require('./shared.js');
const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin;
const OfflinePlugin = require('offline-plugin');
const { publicPath } = require('./configuration.js');
const { env, publicPath } = require('./configuration.js');
const path = require('path');
let compressionAlgorithm;
@ -90,7 +90,7 @@ module.exports = merge(sharedConfig, {
'**/*.woff',
],
ServiceWorker: {
entry: `imports-loader?process.env=>${encodeURIComponent(JSON.stringify(process.env))}!${encodeURI(path.join(__dirname, '../../app/javascript/mastodon/service_worker/entry.js'))}`,
entry: `imports-loader?process.env=>${encodeURIComponent(JSON.stringify(env))}!${encodeURI(path.join(__dirname, '../../app/javascript/mastodon/service_worker/entry.js'))}`,
cacheName: 'mastodon',
output: '../assets/sw.js',
publicPath: '/sw.js',