🔥 remove i18n

Former-commit-id: ec13e090536cc2b10a59ab2a0925f67447776707 [formerly ec13e090536cc2b10a59ab2a0925f67447776707 [formerly ec13e090536cc2b10a59ab2a0925f67447776707 [formerly ec13e090536cc2b10a59ab2a0925f67447776707 [formerly a85bc56998230bd4c02fc3bafcd7eb168866b845 [formerly d14ce8df37b36251df088c8aa12dfcc1f6548090]]]]]
Former-commit-id: 852ee70439012622395d2c63d677e86d7b6ad46b
Former-commit-id: cb355c0933aaa84d245455c9e2f8e86cb31d83c1
Former-commit-id: 988a555fbe58fdd775ab1c6be63b4d6fdb99a3b6 [formerly aed213c981208504393caf487ce7befe94f4f70e]
Former-commit-id: d5ffc9c6534019053d5f9735b13b4fa8cbbbbea5
Former-commit-id: 3c198534afd615a39f71c8a98118b2e40a63c05b
Former-commit-id: d3dd07e3731496f1ef709119e793f6bcf50872d0
Former-commit-id: a0d04bcd00330f10651642e25f7c96dde1bfc66f
Former-commit-id: b76e190be6d730ead12cbc967c9c1257d5afde75
This commit is contained in:
liyang 2019-05-21 23:04:57 +08:00
parent 00d833a44b
commit cb65b56ce9
14 changed files with 1 additions and 198 deletions

View File

@ -1 +1 @@
37a0bf8c45158e97c62ed1be6466ad1ad977e544
fed37778e9514dc3dec6b8c767aa01b05250a597

View File

@ -45,7 +45,6 @@
"v-contextmenu": "^2.8.0",
"vue": "^2.6.10",
"vue-grid-layout": "^2.3.4",
"vue-i18n": "^8.10.0",
"vue-json-tree-view": "^2.1.4",
"vue-router": "^3.0.3",
"vue-splitpane": "^1.0.4",
@ -53,7 +52,6 @@
"vuex": "^3.0.1"
},
"devDependencies": {
"@kazupon/vue-i18n-loader": "^0.3.0",
"@vue/cli-plugin-babel": "^3.6.0",
"@vue/cli-plugin-eslint": "^3.6.0",
"@vue/cli-plugin-unit-jest": "^3.6.0",

View File

@ -1,17 +0,0 @@
import Vue from 'vue'
import VueI18n from 'vue-i18n'
import cn from './lang/cn'
import ja from './lang/ja'
import en from './lang/en'
Vue.use(VueI18n)
export default new VueI18n({
locale: 'cn',
messages: {
cn,
ja,
en
}
})

View File

@ -1,7 +0,0 @@
export default {
pub: {
pageHeader: {
demo: '示例'
}
}
}

View File

@ -1,7 +0,0 @@
export default {
pub: {
pageHeader: {
demo: 'Demo'
}
}
}

View File

@ -1,7 +0,0 @@
export default {
pub: {
pageHeader: {
demo: 'サンプル'
}
}
}

View File

@ -5,8 +5,6 @@ import App from './App'
import d2Admin from '@/plugin/d2admin'
// store
import store from '@/store/index'
// 多国语
import i18n from './i18n'
// [ 可选组件 ]D2-Crud
import D2Crud from '@d2-projects/d2-crud'
@ -53,7 +51,6 @@ Vue.component('VueUeditorWrap', VueUeditorWrap)
new Vue({
router,
store,
i18n,
render: h => h(App),
created () {
// 处理路由 得到每一级的路由设置

View File

@ -32,15 +32,6 @@ export default {
{ path: `${pre}export/txt`, title: '文本' }
]
},
{
path: `${pre}i18n`,
title: '多国语',
icon: 'language',
children: [
{ path: `${pre}i18n/demo1`, title: '示例1' },
{ path: `${pre}i18n/demo2`, title: '示例2' }
]
},
{
path: `${pre}better-scroll`,
title: '滚动扩展',

View File

@ -18,8 +18,6 @@ export default {
{ path: 'day', name: `${pre}day`, component: _import('demo/plugins/day'), meta: { ...meta, title: '日期计算' } },
{ path: 'export/table', name: `${pre}export-table`, component: _import('demo/plugins/export/table.vue'), meta: { ...meta, title: '导出表格' } },
{ path: 'export/txt', name: `${pre}export-txt`, component: _import('demo/plugins/export/txt.vue'), meta: { ...meta, title: '导出文本' } },
{ path: 'i18n/demo1', name: `${pre}i18n-demo1`, component: _import('demo/plugins/i18n/demo1.vue'), meta: { ...meta, title: '多国语示例 1' } },
{ path: 'i18n/demo2', name: `${pre}i18n-demo2`, component: _import('demo/plugins/i18n/demo2.vue'), meta: { ...meta, title: '多国语示例 2' } },
{ path: 'import/csv', name: `${pre}import-csv`, component: _import('demo/plugins/import/csv.vue'), meta: { ...meta, title: '导入 csv' } },
{ path: 'import/xlsx', name: `${pre}import-xlsx`, component: _import('demo/plugins/import/xlsx.vue'), meta: { ...meta, title: '导入 xlsx' } },
{ path: 'index', name: `${pre}index`, component: _import('demo/plugins/index'), meta: { ...meta, title: '插件首页' } },

View File

@ -1,67 +0,0 @@
<i18n>
{
"cn": {
"subtitle": "点击上面的按钮,你可以在两个示例页面之间切换,检查语言变化",
"hello": "你好",
"vue": "Vue (读音 /vjuː/,类似于 view) 是一套用于构建用户界面的渐进式框架。与其它大型框架不同的是Vue 被设计为可以自底向上逐层应用。Vue 的核心库只关注视图层不仅易于上手还便于与第三方库或既有项目整合。另一方面当与现代化的工具链以及各种支持类库结合使用时Vue 也完全能够为复杂的单页应用提供驱动。",
"check": {
"title": "请选择",
"label": {
"Beijing": "北京",
"Tokyo": "东京",
"NewYork": "纽约"
}
}
},
"en": {
"subtitle": "Click the button above, you can switch between two sample pages to check language changes",
"hello": "hello",
"vue": "Vue (pronounced /vjuː/, like view) is a progressive framework for building user interfaces. Unlike other monolithic frameworks, Vue is designed from the ground up to be incrementally adoptable. The core library is focused on the view layer only, and is easy to pick up and integrate with other libraries or existing projects. On the other hand, Vue is also perfectly capable of powering sophisticated Single-Page Applications when used in combination with modern tooling and supporting libraries.",
"check": {
"title": "Please choose",
"label": {
"Beijing": "Beijing",
"Tokyo": "Tokyo",
"NewYork": "NewYork"
}
}
},
"ja": {
"subtitle": "上のボタンをクリックしてあなたは2つの例のページの間で切り替えて、言語の変化を検査することができます",
"hello": "こんにちは",
"vue": "Vue (発音は /vjuː/、view と同様)はユーザーインターフェイスを構築するためのプログレッシブフレームワークです。他の一枚板(モノリシック: monolithic)なフレームワークとは異なり、Vue は少しずつ適用していけるように設計されています。中核となるライブラリは view 層だけに焦点を当てています。そのため、使い始めるのも、他のライブラリや既存のプロジェクトに統合するのも、とても簡単です。また、モダンなツールやサポートライブラリと併用することで、洗練されたシングルページアプリケーションの開発も可能です。",
"check": {
"title": "選択してください",
"label": {
"Beijing": "北京",
"Tokyo": "東京",
"NewYork": "ニューヨーク"
}
}
}
}
</i18n>
<template>
<div>
<p>{{$t('subtitle')}}</p>
<el-tag>{{$t('hello')}}</el-tag>
<p>{{$t('vue')}}</p>
<p>{{$t('check.title')}}</p>
<el-checkbox-group v-model="check">
<el-checkbox label="a">{{$t('check.label.Beijing')}}</el-checkbox>
<el-checkbox label="b">{{$t('check.label.Tokyo')}}</el-checkbox>
<el-checkbox label="c">{{$t('check.label.NewYork')}}</el-checkbox>
</el-checkbox-group>
</div>
</template>
<script>
export default {
data () {
return {
check: ['a', 'b']
}
}
}
</script>

View File

@ -1,27 +0,0 @@
<template>
<div class="d2-mb">
<el-radio-group v-model="lang" @change="handleChange">
<el-radio-button label="cn">中文</el-radio-button>
<el-radio-button label="ja">日本語</el-radio-button>
<el-radio-button label="en">English</el-radio-button>
</el-radio-group>
</div>
</template>
<script>
export default {
data () {
return {
lang: 'cn'
}
},
created () {
this.lang = this.$i18n.locale
},
methods: {
handleChange (val) {
this.$i18n.locale = val
}
}
}
</script>

View File

@ -1,21 +0,0 @@
<template>
<d2-container>
<template slot="header">{{`${$t('pub.pageHeader.demo')} 1`}}</template>
<DemoI18nControl></DemoI18nControl>
<DemoI18n></DemoI18n>
</d2-container>
</template>
<script>
export default {
components: {
DemoI18nControl: () => import('./components/DemoI18nControl'),
DemoI18n: () => import('./components/DemoI18n')
},
data () {
return {
filename: __filename
}
}
}
</script>

View File

@ -1,21 +0,0 @@
<template>
<d2-container>
<template slot="header">{{`${$t('pub.pageHeader.demo')} 2`}}</template>
<DemoI18nControl></DemoI18nControl>
<DemoI18n></DemoI18n>
</d2-container>
</template>
<script>
export default {
components: {
DemoI18nControl: () => import('./components/DemoI18nControl'),
DemoI18n: () => import('./components/DemoI18n')
},
data () {
return {
filename: __filename
}
}
}
</script>

View File

@ -75,13 +75,6 @@ module.exports = {
.use('text-loader')
.loader('text-loader')
.end()
// i18n
config.module
.rule('i18n')
.resourceQuery(/blockType=i18n/)
.use('i18n')
.loader('@kazupon/vue-i18n-loader')
.end()
// svg
const svgRule = config.module.rule('svg')
svgRule.uses.clear()