fixed - Cannot read property '$t'

This commit is contained in:
carodej
2020-04-06 19:56:56 +02:00
parent 6235ffd0dc
commit 01b399e4a6
5 changed files with 158 additions and 45 deletions

View File

@@ -1,4 +1,113 @@
{
"/js/main.js": "/js/main.js",
"/css/app.css": "/css/app.css"
"/css/app.css": "/css/app.css",
"/js/main.e7f30bdbf0af3612b526.hot-update.js": "/js/main.e7f30bdbf0af3612b526.hot-update.js",
"/js/main.ff7c1c1321839e44327f.hot-update.js": "/js/main.ff7c1c1321839e44327f.hot-update.js",
"/js/main.53f0d016b94dcb1c715e.hot-update.js": "/js/main.53f0d016b94dcb1c715e.hot-update.js",
"/js/main.91dfc6fa641b9cd39c02.hot-update.js": "/js/main.91dfc6fa641b9cd39c02.hot-update.js",
"/js/main.667efc00994378e71d93.hot-update.js": "/js/main.667efc00994378e71d93.hot-update.js",
"/js/main.7692d2f34f77320bb11f.hot-update.js": "/js/main.7692d2f34f77320bb11f.hot-update.js",
"/js/main.7f69426c4fe2e8b497c6.hot-update.js": "/js/main.7f69426c4fe2e8b497c6.hot-update.js",
"/js/main.6fdca76d612e9a1f0d0b.hot-update.js": "/js/main.6fdca76d612e9a1f0d0b.hot-update.js",
"/js/main.c31ff848b09d13ca7c2d.hot-update.js": "/js/main.c31ff848b09d13ca7c2d.hot-update.js",
"/js/main.41b7087afdc9a8fa2918.hot-update.js": "/js/main.41b7087afdc9a8fa2918.hot-update.js",
"/js/main.da608518980a26060e6d.hot-update.js": "/js/main.da608518980a26060e6d.hot-update.js",
"/js/main.44865fca901443079e80.hot-update.js": "/js/main.44865fca901443079e80.hot-update.js",
"/js/main.34f68da0edd206bdf449.hot-update.js": "/js/main.34f68da0edd206bdf449.hot-update.js",
"/js/main.76e28a6cf1d089d14407.hot-update.js": "/js/main.76e28a6cf1d089d14407.hot-update.js",
"/js/main.42910696b2219784c525.hot-update.js": "/js/main.42910696b2219784c525.hot-update.js",
"/js/main.67b8b2d86326cbcc783e.hot-update.js": "/js/main.67b8b2d86326cbcc783e.hot-update.js",
"/js/main.2f6b86e9ae2e618eef5c.hot-update.js": "/js/main.2f6b86e9ae2e618eef5c.hot-update.js",
"/js/main.eb2e4334f35dc22ae007.hot-update.js": "/js/main.eb2e4334f35dc22ae007.hot-update.js",
"/js/main.993617a0d9fe5acd8d0c.hot-update.js": "/js/main.993617a0d9fe5acd8d0c.hot-update.js",
"/js/main.eb3f0ccc6ba4c70aa967.hot-update.js": "/js/main.eb3f0ccc6ba4c70aa967.hot-update.js",
"/js/main.489694c4592da3a41269.hot-update.js": "/js/main.489694c4592da3a41269.hot-update.js",
"/js/main.581b9bcbc6d41f76cc3a.hot-update.js": "/js/main.581b9bcbc6d41f76cc3a.hot-update.js",
"/js/main.cfc0762d114afd6424ff.hot-update.js": "/js/main.cfc0762d114afd6424ff.hot-update.js",
"/js/main.a7c716373eb673a7f285.hot-update.js": "/js/main.a7c716373eb673a7f285.hot-update.js",
"/js/main.e126d1845fd72a5c0161.hot-update.js": "/js/main.e126d1845fd72a5c0161.hot-update.js",
"/js/main.352e26546f4fe2821c2e.hot-update.js": "/js/main.352e26546f4fe2821c2e.hot-update.js",
"/js/main.922b31c6f37de4446969.hot-update.js": "/js/main.922b31c6f37de4446969.hot-update.js",
"/js/main.4b1be0b5c77c9901c35d.hot-update.js": "/js/main.4b1be0b5c77c9901c35d.hot-update.js",
"/js/main.3e2b02f36a075c87eeb8.hot-update.js": "/js/main.3e2b02f36a075c87eeb8.hot-update.js",
"/js/main.4af814c53a654a34e904.hot-update.js": "/js/main.4af814c53a654a34e904.hot-update.js",
"/js/main.6b3c398f901108d13836.hot-update.js": "/js/main.6b3c398f901108d13836.hot-update.js",
"/js/main.f41e53673d2e295978b4.hot-update.js": "/js/main.f41e53673d2e295978b4.hot-update.js",
"/js/main.5f840767e9c6130f5356.hot-update.js": "/js/main.5f840767e9c6130f5356.hot-update.js",
"/js/main.423db5f2e4dfc74a2964.hot-update.js": "/js/main.423db5f2e4dfc74a2964.hot-update.js",
"/js/main.12aff97caaae89cd3e8b.hot-update.js": "/js/main.12aff97caaae89cd3e8b.hot-update.js",
"/js/main.9f29f80eff6641f65abb.hot-update.js": "/js/main.9f29f80eff6641f65abb.hot-update.js",
"/js/main.4124c4b13d33dcae6e72.hot-update.js": "/js/main.4124c4b13d33dcae6e72.hot-update.js",
"/js/main.6ff4de79821f8c889c68.hot-update.js": "/js/main.6ff4de79821f8c889c68.hot-update.js",
"/js/main.28cb2b46fc2632c022a8.hot-update.js": "/js/main.28cb2b46fc2632c022a8.hot-update.js",
"/js/main.571327025a1eb083c342.hot-update.js": "/js/main.571327025a1eb083c342.hot-update.js",
"/js/main.d86182800943a3c3db27.hot-update.js": "/js/main.d86182800943a3c3db27.hot-update.js",
"/js/main.7003dbcc7ef9f0a96491.hot-update.js": "/js/main.7003dbcc7ef9f0a96491.hot-update.js",
"/js/main.979687c964f2b30c2af4.hot-update.js": "/js/main.979687c964f2b30c2af4.hot-update.js",
"/js/main.2ee700b6bd0e8c809f86.hot-update.js": "/js/main.2ee700b6bd0e8c809f86.hot-update.js",
"/js/main.592d60d033bfcef8b18b.hot-update.js": "/js/main.592d60d033bfcef8b18b.hot-update.js",
"/js/main.9ea1d9d63047b8a70709.hot-update.js": "/js/main.9ea1d9d63047b8a70709.hot-update.js",
"/js/main.211a33977506e5cc972c.hot-update.js": "/js/main.211a33977506e5cc972c.hot-update.js",
"/js/main.fc18269e0e2a57bfa749.hot-update.js": "/js/main.fc18269e0e2a57bfa749.hot-update.js",
"/js/main.2d96606dfee12bbf2e2d.hot-update.js": "/js/main.2d96606dfee12bbf2e2d.hot-update.js",
"/js/main.a73cc8c938ec93a42697.hot-update.js": "/js/main.a73cc8c938ec93a42697.hot-update.js",
"/js/main.8382c3a1344f4204753c.hot-update.js": "/js/main.8382c3a1344f4204753c.hot-update.js",
"/js/main.662361c9d724944e080b.hot-update.js": "/js/main.662361c9d724944e080b.hot-update.js",
"/js/main.e4e2534d512313077893.hot-update.js": "/js/main.e4e2534d512313077893.hot-update.js",
"/js/main.51f2667edf8b2add512c.hot-update.js": "/js/main.51f2667edf8b2add512c.hot-update.js",
"/js/main.4d741ebaa620d0385db6.hot-update.js": "/js/main.4d741ebaa620d0385db6.hot-update.js",
"/js/main.0c7c1626421531bfde30.hot-update.js": "/js/main.0c7c1626421531bfde30.hot-update.js",
"/js/main.5547baee42f7c43a9d68.hot-update.js": "/js/main.5547baee42f7c43a9d68.hot-update.js",
"/js/main.379b12896cb2d8dc5dfd.hot-update.js": "/js/main.379b12896cb2d8dc5dfd.hot-update.js",
"/js/main.69169d21cb9c798cee55.hot-update.js": "/js/main.69169d21cb9c798cee55.hot-update.js",
"/js/main.06e378419c44d61a73a9.hot-update.js": "/js/main.06e378419c44d61a73a9.hot-update.js",
"/js/main.abe45830bb5f74a87492.hot-update.js": "/js/main.abe45830bb5f74a87492.hot-update.js",
"/js/main.3c26bcfaac1764dcb695.hot-update.js": "/js/main.3c26bcfaac1764dcb695.hot-update.js",
"/js/main.42675c137c9be9cc6cbd.hot-update.js": "/js/main.42675c137c9be9cc6cbd.hot-update.js",
"/js/main.515ee9927d6ac79600a1.hot-update.js": "/js/main.515ee9927d6ac79600a1.hot-update.js",
"/js/main.fd96c8e9517a25f24267.hot-update.js": "/js/main.fd96c8e9517a25f24267.hot-update.js",
"/js/main.9ed1f46fd2a980db7a94.hot-update.js": "/js/main.9ed1f46fd2a980db7a94.hot-update.js",
"/js/main.e9a46e7cb63345e78d87.hot-update.js": "/js/main.e9a46e7cb63345e78d87.hot-update.js",
"/js/main.d15c62c50568d76a382b.hot-update.js": "/js/main.d15c62c50568d76a382b.hot-update.js",
"/js/main.6193797d6c1f8c17aaba.hot-update.js": "/js/main.6193797d6c1f8c17aaba.hot-update.js",
"/js/main.faf6ee5fbe0a15bd1d8e.hot-update.js": "/js/main.faf6ee5fbe0a15bd1d8e.hot-update.js",
"/js/main.b0717733357e2685ae52.hot-update.js": "/js/main.b0717733357e2685ae52.hot-update.js",
"/js/main.ce135143a7d035e2e6f0.hot-update.js": "/js/main.ce135143a7d035e2e6f0.hot-update.js",
"/js/main.4c778030c5c81c6af821.hot-update.js": "/js/main.4c778030c5c81c6af821.hot-update.js",
"/js/main.0550ffbc69d4d875ac6c.hot-update.js": "/js/main.0550ffbc69d4d875ac6c.hot-update.js",
"/js/main.6e17a1db946814f637a4.hot-update.js": "/js/main.6e17a1db946814f637a4.hot-update.js",
"/js/main.051eb6b27d0c22e1a411.hot-update.js": "/js/main.051eb6b27d0c22e1a411.hot-update.js",
"/js/main.4cd63de9d44c1d9f7135.hot-update.js": "/js/main.4cd63de9d44c1d9f7135.hot-update.js",
"/js/main.29edb50ea18b55b0c523.hot-update.js": "/js/main.29edb50ea18b55b0c523.hot-update.js",
"/js/main.6cdf442892e4847c4f60.hot-update.js": "/js/main.6cdf442892e4847c4f60.hot-update.js",
"/js/main.1c51f73087b631f16211.hot-update.js": "/js/main.1c51f73087b631f16211.hot-update.js",
"/js/main.1ec761ecadf80f27fffc.hot-update.js": "/js/main.1ec761ecadf80f27fffc.hot-update.js",
"/js/main.66e6478ece3f8c617c56.hot-update.js": "/js/main.66e6478ece3f8c617c56.hot-update.js",
"/js/main.f892cca704db04f9bd2d.hot-update.js": "/js/main.f892cca704db04f9bd2d.hot-update.js",
"/js/main.1a9e29684e0706bff64e.hot-update.js": "/js/main.1a9e29684e0706bff64e.hot-update.js",
"/js/main.5b40ae6cfcb202b440e8.hot-update.js": "/js/main.5b40ae6cfcb202b440e8.hot-update.js",
"/js/main.f8d02b41c8fe0ddd11f4.hot-update.js": "/js/main.f8d02b41c8fe0ddd11f4.hot-update.js",
"/js/main.c2f2d9ba582bf012b3ba.hot-update.js": "/js/main.c2f2d9ba582bf012b3ba.hot-update.js",
"/js/main.a4ed8e299894d0f3e170.hot-update.js": "/js/main.a4ed8e299894d0f3e170.hot-update.js",
"/js/main.f4d1aceb1493a95f0973.hot-update.js": "/js/main.f4d1aceb1493a95f0973.hot-update.js",
"/js/main.e8d9e02ad685eb0cb0a9.hot-update.js": "/js/main.e8d9e02ad685eb0cb0a9.hot-update.js",
"/js/main.b61ea149b4679eb735a4.hot-update.js": "/js/main.b61ea149b4679eb735a4.hot-update.js",
"/js/main.f4838e6c4cee6bbbd58c.hot-update.js": "/js/main.f4838e6c4cee6bbbd58c.hot-update.js",
"/js/main.9793a25b1cbcbbca608f.hot-update.js": "/js/main.9793a25b1cbcbbca608f.hot-update.js",
"/js/main.5f82981096301f7c14c6.hot-update.js": "/js/main.5f82981096301f7c14c6.hot-update.js",
"/js/main.147de5c546116b82b172.hot-update.js": "/js/main.147de5c546116b82b172.hot-update.js",
"/js/main.549924132e085db25697.hot-update.js": "/js/main.549924132e085db25697.hot-update.js",
"/js/main.6c6906253d93fd4e9f49.hot-update.js": "/js/main.6c6906253d93fd4e9f49.hot-update.js",
"/js/main.5c8df9ef886b2d973d09.hot-update.js": "/js/main.5c8df9ef886b2d973d09.hot-update.js",
"/js/main.50c83faee1c7cd29d33e.hot-update.js": "/js/main.50c83faee1c7cd29d33e.hot-update.js",
"/js/main.53e3daf64e1e8b0c63d0.hot-update.js": "/js/main.53e3daf64e1e8b0c63d0.hot-update.js",
"/js/main.6eb4044b179cc2a36255.hot-update.js": "/js/main.6eb4044b179cc2a36255.hot-update.js",
"/js/main.13219cf32b68d75b6fde.hot-update.js": "/js/main.13219cf32b68d75b6fde.hot-update.js",
"/js/main.2b85c9dfe8855a302b4c.hot-update.js": "/js/main.2b85c9dfe8855a302b4c.hot-update.js",
"/js/main.2945557ddcfe6d700857.hot-update.js": "/js/main.2945557ddcfe6d700857.hot-update.js",
"/js/main.3a0f92c1ad27a9f654b8.hot-update.js": "/js/main.3a0f92c1ad27a9f654b8.hot-update.js",
"/js/main.a3fd6ea744fa29df6f2f.hot-update.js": "/js/main.a3fd6ea744fa29df6f2f.hot-update.js",
"/js/main.fd4a172f187a86625543.hot-update.js": "/js/main.fd4a172f187a86625543.hot-update.js",
"/js/main.337958133c59a2cd4cde.hot-update.js": "/js/main.337958133c59a2cd4cde.hot-update.js",
"/js/main.df7e7e8e5a9f85c44e94.hot-update.js": "/js/main.df7e7e8e5a9f85c44e94.hot-update.js"
}

View File

@@ -1,7 +1,16 @@
// index.js
import Vue from 'vue';
import VueI18n from 'vue-i18n';
import en from './lang/en.json'
import sk from './lang/sk.json'
export const languages = {
en, sk
}
Vue.use(VueI18n);
const i18n = new VueI18n({
locale: config.locale,
messages: Object.assign({
en, sk
}),
});
export default i18n;

11
resources/js/main.js vendored
View File

@@ -1,7 +1,6 @@
require('./bootstrap');
import Vue from 'vue'
import VueI18n from 'vue-i18n'
import { languages } from './i18n/index.js'
import i18n from './i18n/index.js'
import App from './App.vue'
import store from './store/index'
import Helpers from './helpers'
@@ -65,17 +64,9 @@ library.add(
Vue.component('FontAwesomeIcon', FontAwesomeIcon)
Vue.use(Helpers)
Vue.use(VueI18n)
Vue.config.productionTip = false
const messages = Object.assign(languages)
const i18n = new VueI18n({
locale: config.locale,
messages
})
var vueFileManager = new Vue({
i18n,
store,

View File

@@ -1,5 +1,6 @@
import axios from 'axios'
import {events} from '@/bus'
import i18n from '@/i18n/index.js'
const defaultState = {
fileInfoPanelVisible: localStorage.getItem('file_info_visibility') == 'true' || false,
@@ -62,8 +63,8 @@ const actions = {
.catch(() => {
// Show error message
events.$emit('alert:open', {
title: this.$t('popup_error.title'),
message: this.$t('popup_error.message'),
title: i18n.t('popup_error.title'),
message: i18n.t('popup_error.message'),
})
})
},
@@ -99,8 +100,8 @@ const actions = {
.catch(() => {
// Show error message
events.$emit('alert:open', {
title: this.$t('popup_error.title'),
message: this.$t('popup_error.message'),
title: i18n.t('popup_error.title'),
message: i18n.t('popup_error.message'),
})
})
},
@@ -119,15 +120,15 @@ const actions = {
// Show error message
events.$emit('success:open', {
title: this.$t('popup_trashed.title'),
message: this.$t('popup_trashed.message'),
title: i18n.t('popup_trashed.title'),
message: i18n.t('popup_trashed.message'),
})
})
.catch(() => {
// Show error message
events.$emit('alert:open', {
title: this.$t('popup_error.title'),
message: this.$t('popup_error.message'),
title: i18n.t('popup_error.title'),
message: i18n.t('popup_error.message'),
})
})
},
@@ -147,8 +148,8 @@ const actions = {
.catch(() => {
// Show error message
events.$emit('alert:open', {
title: this.$t('popup_error.title'),
message: this.$t('popup_error.message'),
title: i18n.t('popup_error.title'),
message: i18n.t('popup_error.message'),
})
})
},
@@ -165,8 +166,8 @@ const actions = {
.catch(() => {
// Show error message
events.$emit('alert:open', {
title: this.$t('popup_error.title'),
message: this.$t('popup_error.message'),
title: i18n.t('popup_error.title'),
message: i18n.t('popup_error.message'),
})
})
},
@@ -192,8 +193,8 @@ const actions = {
.catch(() => {
// Show error message
events.$emit('alert:open', {
title: this.$t('popup_error.title'),
message: this.$t('popup_error.message'),
title: i18n.t('popup_error.title'),
message: i18n.t('popup_error.message'),
})
})
},
@@ -219,8 +220,8 @@ const actions = {
.catch(() => {
// Show error message
events.$emit('alert:open', {
title: this.$t('popup_error.title'),
message: this.$t('popup_error.message'),
title: i18n.t('popup_error.title'),
message: i18n.t('popup_error.message'),
})
})
},
@@ -264,6 +265,8 @@ const actions = {
})
},
changeItemName: (context, data) => {
if (data.type === 'folder') context.commit('UPDATE_NAME_IN_FAVOURITES', data)
axios
@@ -274,8 +277,8 @@ const actions = {
.catch(() => {
// Show error message
events.$emit('alert:open', {
title: this.$t('popup_error.title'),
message: this.$t('popup_error.message'),
title: i18n.t('popup_error.title'),
message: i18n.t('popup_error.message'),
})
})
},
@@ -295,8 +298,8 @@ const actions = {
.catch(() => {
// Show error message
events.$emit('alert:open', {
title: this.$t('popup_error.title'),
message: this.$t('popup_error.message'),
title: i18n.t('popup_error.title'),
message: i18n.t('popup_error.message'),
})
})
},
@@ -337,8 +340,8 @@ const actions = {
.catch(() => {
// Show error message
events.$emit('alert:open', {
title: this.$t('popup_error.title'),
message: this.$t('popup_error.message'),
title: i18n.t('popup_error.title'),
message: i18n.t('popup_error.message'),
})
})
},
@@ -360,8 +363,8 @@ const actions = {
.catch(() => {
// Show error message
events.$emit('alert:open', {
title: this.$t('popup_error.title'),
message: this.$t('popup_error.message'),
title: i18n.t('popup_error.title'),
message: i18n.t('popup_error.message'),
})
})
}

View File

@@ -1,5 +1,6 @@
import axios from 'axios'
import {events} from '@/bus'
import i18n from '@/i18n/index.js'
const defaultState = {
authorized: undefined,
@@ -41,8 +42,8 @@ const actions = {
.catch(() => {
// Show error message
events.$emit('alert:open', {
title: this.$t('popup_error.title'),
message: this.$t('popup_error.message'),
title: i18n.t('popup_error.title'),
message: i18n.t('popup_error.message'),
})
})
},
@@ -56,8 +57,8 @@ const actions = {
.catch(() => {
// Show error message
events.$emit('alert:open', {
title: this.$t('popup_error.title'),
message: this.$t('popup_error.message'),
title: i18n.t('popup_error.title'),
message: i18n.t('popup_error.message'),
})
})
},
@@ -75,8 +76,8 @@ const actions = {
// Show error message
events.$emit('alert:open', {
title: this.$t('popup_error.title'),
message: this.$t('popup_error.message'),
title: i18n.t('popup_error.title'),
message: i18n.t('popup_error.message'),
})
})
})