diff --git a/html/src/app.js b/html/src/app.js index 159622bd..32ce5d41 100644 --- a/html/src/app.js +++ b/html/src/app.js @@ -4,6 +4,13 @@ // This work is licensed under the terms of the MIT license. // For a copy, see . +import Noty from 'noty'; +import Vue from 'vue'; +import VueLazyload from 'vue-lazyload'; +import { DataTables } from 'vue-data-tables'; +import ElementUI from 'element-ui'; +import locale from 'element-ui/lib/locale/lang/en'; + CefSharp.BindObjectAsync( 'VRCX', 'VRCXStorage', @@ -95,6 +102,10 @@ CefSharp.BindObjectAsync( timeout: 6000 }); + Vue.use(ElementUI, { + locale + }); + var removeFromArray = function (array, item) { var { length } = array; for (var i = 0; i < length; ++i) { @@ -187,9 +198,7 @@ CefSharp.BindObjectAsync( } }); - Vue.use(DataTables.DataTables); - - ELEMENT.locale(ELEMENT.lang.en); + Vue.use(DataTables); var uuidv4 = () => 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, (c) => { var v = Math.random() * 16 | 0; diff --git a/html/src/app.scss b/html/src/app.scss index 0a0e4160..4782c72f 100644 --- a/html/src/app.scss +++ b/html/src/app.scss @@ -1,4 +1,5 @@ @charset "utf-8"; + /* Copyright(c) 2019-2020 pypy and individual contributors. All rights reserved. @@ -7,6 +8,12 @@ This work is licensed under the terms of the MIT license. For a copy, see . */ +@import '~normalize.css/normalize.css'; +@import '~animate.css/animate.min.css'; +@import '~noty/lib/noty.css'; +@import '~element-ui/lib/theme-chalk/index.css'; +@import '~famfamfam-flags/dist/sprite/famfamfam-flags.min.css'; + .color-palettes { background: #409EFF; background: #67C23A; diff --git a/html/src/index.pug b/html/src/index.pug index f205048c..78f78b0f 100644 --- a/html/src/index.pug +++ b/html/src/index.pug @@ -9,11 +9,6 @@ html link(rel="dns-prefetch" href="https://fonts.gstatic.com") link(rel="preconnect" href="https://api.vrchat.cloud") link(rel="preconnect" href="https://d348imysud55la.cloudfront.net") - link(rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/8.0.1/normalize.min.css") - link(rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/animate.css/4.1.0/animate.min.css") - link(rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/noty/3.2.0-beta/noty.min.css") - link(rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/element-ui/2.13.1/theme-chalk/index.css") - link(rel="stylesheet" href="https://cdn.jsdelivr.net/npm/famfamfam-flags/dist/sprite/famfamfam-flags.min.css") link(rel="stylesheet" href="https://fonts.googleapis.com/css?family=Noto+Sans+JP|Noto+Sans+KR&display=swap") link(rel="stylesheet" href="app.css") body @@ -1318,10 +1313,4 @@ html LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - script(src="https://cdnjs.cloudflare.com/ajax/libs/noty/3.2.0-beta/noty.min.js") - script(src="https://cdnjs.cloudflare.com/ajax/libs/vue/2.6.11/vue.js") - script(src="https://cdnjs.cloudflare.com/ajax/libs/vue-lazyload/1.3.3/vue-lazyload.js") - script(src="https://unpkg.com/vue-data-tables@3.4.5/dist/data-tables.min.js") - script(src="https://cdnjs.cloudflare.com/ajax/libs/element-ui/2.13.1/index.js") - script(src="https://cdnjs.cloudflare.com/ajax/libs/element-ui/2.13.1/locale/en.min.js") - script(src="app.js") \ No newline at end of file + script(src="app.js") diff --git a/html/src/vr.js b/html/src/vr.js index df6aeea5..1e874d35 100644 --- a/html/src/vr.js +++ b/html/src/vr.js @@ -4,6 +4,11 @@ // This work is licensed under the terms of the MIT license. // For a copy, see . +import Noty from 'noty'; +import Vue from 'vue'; +import ElementUI from 'element-ui'; +import locale from 'element-ui/lib/locale/lang/en'; + CefSharp.BindObjectAsync( 'VRCX', 'VRCXStorage', @@ -77,6 +82,10 @@ CefSharp.BindObjectAsync( timeout: 6000 }); + Vue.use(ElementUI, { + locale + }); + var escapeTag = (s) => String(s).replace(/["&'<>]/gu, (c) => `&#${c.charCodeAt(0)};`); Vue.filter('escapeTag', escapeTag); diff --git a/html/src/vr.scss b/html/src/vr.scss index dbc1dac9..d6bcae9e 100644 --- a/html/src/vr.scss +++ b/html/src/vr.scss @@ -6,6 +6,11 @@ This work is licensed under the terms of the MIT license. For a copy, see . */ +@import '~normalize.css/normalize.css'; +@import '~animate.css/animate.min.css'; +@import '~noty/lib/noty.css'; +@import '~element-ui/lib/theme-chalk/index.css'; + /* 마지노선인듯 화면 24px -> 나나 32 diff --git a/html/webpack.mix.js b/html/webpack.mix.js index bff4e48c..5d961782 100644 --- a/html/webpack.mix.js +++ b/html/webpack.mix.js @@ -22,6 +22,11 @@ mix.override(function (webpackConfig) { })); }); +// vendor +mix.copyDirectory('node_modules/element-ui/lib/theme-chalk/fonts/', 'dist/fonts/'); +mix.copyDirectory('node_modules/famfamfam-flags/dist/sprite/famfamfam-flags.png', 'dist/'); + +// app mix.copyDirectory('images/', 'dist/images/'); mix.copy('src/vr.html', 'dist/'); mix.js('src/app.js', 'dist/');