diff --git a/frontend/package.json b/frontend/package.json index 824047017e..3db830fb4e 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -55,7 +55,7 @@ "vue-float-action-button": "^0.6.6", "vue-i18n": "^8.15.3", "vue-jsonpath-picker": "^1.1.5", - "vue-minder-editor-plus": "1.0.46", + "vue-minder-editor-plus": "1.1.2", "vue-papa-parse": "^2.0.0", "vue-pdf": "^4.2.0", "vue-router": "^3.1.3", diff --git a/frontend/src/business/main.js b/frontend/src/business/main.js index 435f12a50c..895db5451a 100644 --- a/frontend/src/business/main.js +++ b/frontend/src/business/main.js @@ -31,8 +31,6 @@ import 'mavon-editor/dist/css/index.css' import 'element-ui/lib/theme-chalk/display.css'; Vue.use(mavonEditor) -Vue.use(vueMinderEditor) - Vue.use(JsonSchemaEditor); Vue.use(ComparedEditor); @@ -45,6 +43,10 @@ Vue.use(icon); Vue.use(ElementUI, { i18n: (key, value) => i18n.t(key, value) }); +Vue.use(vueMinderEditor, { + i18n: (key, value) => i18n.t(key, value) +}); + Vue.use(filters); Vue.use(ajax); Vue.use(chart); diff --git a/frontend/src/i18n/i18n.js b/frontend/src/i18n/i18n.js index de3eb372f8..9145607952 100644 --- a/frontend/src/i18n/i18n.js +++ b/frontend/src/i18n/i18n.js @@ -4,6 +4,11 @@ import axios from "axios"; import enLocale from "element-ui/lib/locale/lang/en"; import zh_CNLocale from "element-ui/lib/locale/lang/zh-CN"; import zh_TWLocale from "element-ui/lib/locale/lang/zh-TW"; + +import minder_en_US from "vue-minder-editor-plus/src/locale/lang/en-US"; +import minder_zh_CN from "vue-minder-editor-plus/src/locale/lang/zh-CN"; +import minder_zh_TW from "vue-minder-editor-plus/src/locale/lang/zh-TW"; + import zh_CN from "./zh-CN"; import en_US from "./en-US"; import zh_TW from "./zh-TW"; @@ -15,15 +20,18 @@ Vue.use(VueI18n); const messages = { 'en_US': { ...enLocale, - ...en_US + ...en_US, + ...minder_en_US }, 'zh_CN': { ...zh_CNLocale, - ...zh_CN + ...zh_CN, + ...minder_zh_CN }, 'zh_TW': { ...zh_TWLocale, - ...zh_TW + ...zh_TW, + ...minder_zh_TW } };