diff --git a/index-rmo.html b/index-rmo.html new file mode 100644 index 00000000..8f9e7730 --- /dev/null +++ b/index-rmo.html @@ -0,0 +1,13 @@ + + + + + + + Nidus Sync + + +
+ + + diff --git a/index-sync.html b/index-sync.html new file mode 100644 index 00000000..8f9e7730 --- /dev/null +++ b/index-sync.html @@ -0,0 +1,13 @@ + + + + + + + Nidus Sync + + +
+ + + diff --git a/index.html b/index.html index 16892e94..8f9e7730 100644 --- a/index.html +++ b/index.html @@ -8,6 +8,6 @@
- + diff --git a/package.json b/package.json index 3a728441..7c109bf7 100644 --- a/package.json +++ b/package.json @@ -6,6 +6,7 @@ "dependencies": { "@popperjs/core": "^2.11.8", "@vueuse/core": "^14.2.1", + "@vueuse/head": "^2.0.0", "axios": "^1.13.6", "bootstrap": "^5.3.8", "bootstrap-icons": "^1.13.1", @@ -25,7 +26,8 @@ }, "scripts": { "build": "vue-tsc && vite build", - "dev": "vite", + "dev-rmo": "vite --config vite/rmo.ts", + "dev-sync": "vite --config vite/sync.ts", "generate-icons": "node generate-icons.js", "typecheck": "vue-tsc --noEmit", "typecheck:watch": "vue-tsc --noEmit --watch" diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index e7324c4c..cf8e720f 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -14,6 +14,9 @@ importers: '@vueuse/core': specifier: ^14.2.1 version: 14.2.1(vue@3.5.30(typescript@5.9.3)) + '@vueuse/head': + specifier: ^2.0.0 + version: 2.0.0(vue@3.5.30(typescript@5.9.3)) axios: specifier: ^1.13.6 version: 1.13.6 @@ -347,6 +350,23 @@ packages: '@types/web-bluetooth@0.0.21': resolution: {integrity: sha512-oIQLCGWtcFZy2JW77j9k8nHzAOpqMHLQejDA48XXMWH6tjCQHz5RCFz1bzsmROyL6PUm+LLnUiI4BCn221inxA==} + '@unhead/dom@1.11.20': + resolution: {integrity: sha512-jgfGYdOH+xHJF/j8gudjsYu3oIjFyXhCWcgKaw3vQnT616gSqyqnGQGOItL+BQtQZACKNISwIfx5PuOtztMKLA==} + + '@unhead/schema@1.11.20': + resolution: {integrity: sha512-0zWykKAaJdm+/Y7yi/Yds20PrUK7XabLe9c3IRcjnwYmSWY6z0Cr19VIs3ozCj8P+GhR+/TI2mwtGlueCEYouA==} + + '@unhead/shared@1.11.20': + resolution: {integrity: sha512-1MOrBkGgkUXS+sOKz/DBh4U20DNoITlJwpmvSInxEUNhghSNb56S0RnaHRq0iHkhrO/cDgz2zvfdlRpoPLGI3w==} + + '@unhead/ssr@1.11.20': + resolution: {integrity: sha512-j6ehzmdWGAvv0TEZyLE3WBnG1ULnsbKQcLqBDh3fvKS6b3xutcVZB7mjvrVE7ckSZt6WwOtG0ED3NJDS7IjzBA==} + + '@unhead/vue@1.11.20': + resolution: {integrity: sha512-sqQaLbwqY9TvLEGeq8Fd7+F2TIuV3nZ5ihVISHjWpAM3y7DwNWRU7NmT9+yYT+2/jw1Vjwdkv5/HvDnvCLrgmg==} + peerDependencies: + vue: '>=2.7 || >=3' + '@vitejs/plugin-vue@6.0.5': resolution: {integrity: sha512-bL3AxKuQySfk1iGcBsQnoRVexTPJq0Z/ixFVM8OhVJAP6ZXXXLtM7NFKWhLl30Kg7uTBqIaPXbh+nuQCuBDedg==} engines: {node: ^20.19.0 || >=22.12.0} @@ -427,6 +447,11 @@ packages: peerDependencies: vue: ^3.5.0 + '@vueuse/head@2.0.0': + resolution: {integrity: sha512-ykdOxTGs95xjD4WXE4na/umxZea2Itl0GWBILas+O4oqS7eXIods38INvk3XkJKjqMdWPcpCyLX/DioLQxU1KA==} + peerDependencies: + vue: '>=2.7 || >=3' + '@vueuse/metadata@14.2.1': resolution: {integrity: sha512-1ButlVtj5Sb/HDtIy1HFr1VqCP4G6Ypqt5MAo0lCgjokrk2mvQKsK2uuy0vqu/Ks+sHfuHo0B9Y9jn9xKdjZsw==} @@ -756,6 +781,9 @@ packages: resolution: {integrity: sha512-9qny7Z9DsQU8Ou39ERsPU4OZQlSTP47ShQzuKZ6PRXpYLtIFgl/DEBYEXKlvcEa+9tHVcK8CF81Y2V72qaZhWA==} engines: {node: '>=18'} + packrup@0.1.2: + resolution: {integrity: sha512-ZcKU7zrr5GlonoS9cxxrb5HVswGnyj6jQvwFBa6p5VFw7G71VAHcUKL5wyZSU/ECtPM/9gacWxy2KFQKt1gMNA==} + path-browserify@1.0.1: resolution: {integrity: sha512-b7uo2UCUOYZcnF/3ID0lulOJi/bafxa1xPe7ZPsammBSpjSWQkjNxlt635YGS2MiR9GjvuXCtz2emr3jbsz98g==} @@ -883,6 +911,9 @@ packages: ufo@1.6.3: resolution: {integrity: sha512-yDJTmhydvl5lJzBmy/hyOAA0d+aqCBuwl818haVdYCRrWV84o7YyeVm4QlVHStqNrrJSTb6jKuFAVqAFsr+K3Q==} + unhead@1.11.20: + resolution: {integrity: sha512-3AsNQC0pjwlLqEYHLjtichGWankK8yqmocReITecmpB1H0aOabeESueyy+8X1gyJx4ftZVwo9hqQ4O3fPWffCA==} + unicorn-magic@0.3.0: resolution: {integrity: sha512-+QBBXBCvifc56fsbuxZQ6Sic3wqqc3WWaqxs58gvJrcOuN83HGTCwz3oS5phzU9LthRNE9VrJCFCLUgHeeFnfA==} engines: {node: '>=18'} @@ -1015,6 +1046,9 @@ packages: engines: {node: '>= 14.6'} hasBin: true + zhead@2.2.4: + resolution: {integrity: sha512-8F0OI5dpWIA5IGG5NHUg9staDwz/ZPxZtvGVf01j7vHqSyZ0raHY+78atOVxRqb73AotX22uV1pXt3gYSstGag==} + snapshots: '@babel/code-frame@7.29.0': @@ -1265,6 +1299,34 @@ snapshots: '@types/web-bluetooth@0.0.21': {} + '@unhead/dom@1.11.20': + dependencies: + '@unhead/schema': 1.11.20 + '@unhead/shared': 1.11.20 + + '@unhead/schema@1.11.20': + dependencies: + hookable: 5.5.3 + zhead: 2.2.4 + + '@unhead/shared@1.11.20': + dependencies: + '@unhead/schema': 1.11.20 + packrup: 0.1.2 + + '@unhead/ssr@1.11.20': + dependencies: + '@unhead/schema': 1.11.20 + '@unhead/shared': 1.11.20 + + '@unhead/vue@1.11.20(vue@3.5.30(typescript@5.9.3))': + dependencies: + '@unhead/schema': 1.11.20 + '@unhead/shared': 1.11.20 + hookable: 5.5.3 + unhead: 1.11.20 + vue: 3.5.30(typescript@5.9.3) + '@vitejs/plugin-vue@6.0.5(vite@8.0.1(sass@1.98.0)(yaml@2.8.3))(vue@3.5.30(typescript@5.9.3))': dependencies: '@rolldown/pluginutils': 1.0.0-rc.2 @@ -1395,6 +1457,14 @@ snapshots: '@vueuse/shared': 14.2.1(vue@3.5.30(typescript@5.9.3)) vue: 3.5.30(typescript@5.9.3) + '@vueuse/head@2.0.0(vue@3.5.30(typescript@5.9.3))': + dependencies: + '@unhead/dom': 1.11.20 + '@unhead/schema': 1.11.20 + '@unhead/ssr': 1.11.20 + '@unhead/vue': 1.11.20(vue@3.5.30(typescript@5.9.3)) + vue: 3.5.30(typescript@5.9.3) + '@vueuse/metadata@14.2.1': {} '@vueuse/shared@14.2.1(vue@3.5.30(typescript@5.9.3))': @@ -1686,6 +1756,8 @@ snapshots: path-key: 4.0.0 unicorn-magic: 0.3.0 + packrup@0.1.2: {} + path-browserify@1.0.1: {} path-key@4.0.0: {} @@ -1810,6 +1882,13 @@ snapshots: ufo@1.6.3: {} + unhead@1.11.20: + dependencies: + '@unhead/dom': 1.11.20 + '@unhead/schema': 1.11.20 + '@unhead/shared': 1.11.20 + hookable: 5.5.3 + unicorn-magic@0.3.0: {} unplugin-utils@0.3.1: @@ -1895,3 +1974,5 @@ snapshots: webpack-virtual-modules@0.6.2: {} yaml@2.8.3: {} + + zhead@2.2.4: {} diff --git a/ts/AppRMO.vue b/ts/AppRMO.vue new file mode 100644 index 00000000..ebdbc2aa --- /dev/null +++ b/ts/AppRMO.vue @@ -0,0 +1,31 @@ + + + diff --git a/ts/App.vue b/ts/AppSync.vue similarity index 100% rename from ts/App.vue rename to ts/AppSync.vue diff --git a/ts/main-rmo.ts b/ts/main-rmo.ts new file mode 100644 index 00000000..8475c8df --- /dev/null +++ b/ts/main-rmo.ts @@ -0,0 +1,9 @@ +import { createApp } from "vue"; +import { createHead } from "@vueuse/head"; +import App from "./AppRMO.vue"; + +const app = createApp(App); +const head = createHead(); + +app.use(head); +app.mount("#app"); diff --git a/ts/main.ts b/ts/main-sync.ts similarity index 100% rename from ts/main.ts rename to ts/main-sync.ts diff --git a/vite/rmo.ts b/vite/rmo.ts new file mode 100644 index 00000000..1d42ddab --- /dev/null +++ b/vite/rmo.ts @@ -0,0 +1,71 @@ +import { defineConfig } from "vite"; +import vue from "@vitejs/plugin-vue"; +import checker from "vite-plugin-checker"; +import path from "path"; + +export default defineConfig({ + plugins: [ + vue(), + checker({ + vueTsc: true, + }), + ], + + resolve: { + alias: { + "@": path.resolve(__dirname, "../ts"), + }, + }, + + css: { + preprocessorOptions: { + scss: { + additionalData: `@use "sass:map";\n@import "@/style/variables.scss";`, + api: "modern-compiler", + silenceDeprecations: [ + "import", + "global-builtin", + "if-function", + "color-functions", + ], + }, + }, + }, + + build: { + manifest: true, + outDir: "static/gen", + emptyOutDir: true, + rollupOptions: { + input: { + main: path.resolve(__dirname, "../ts/main-rmo.ts"), + }, + output: { + entryFileNames: "js/bundle.[hash].js", + chunkFileNames: "js/[name].[hash].js", + assetFileNames: (assetInfo) => { + if (/\.(woff2?|ttf|eot)$/.test(assetInfo.name || "")) { + return "fonts/[name].[hash][extname]"; + } + if (/\.css$/.test(assetInfo.name || "")) { + return "css/style.[hash][extname]"; + } + return "assets/[name].[hash][extname]"; + }, + }, + }, + sourcemap: true, + }, + + server: { + allowedHosts: ["poweredge.local", "dev-report.mosquitoes.online"], + port: 9001, + /*proxy: { + "/api": { + target: "http://127.0.0.1:9002", + changeOrigin: false, + }, + },*/ + strictPort: true, + }, +}); diff --git a/vite.config.ts b/vite/sync.ts similarity index 89% rename from vite.config.ts rename to vite/sync.ts index 56390aac..94d27b7d 100644 --- a/vite.config.ts +++ b/vite/sync.ts @@ -13,7 +13,7 @@ export default defineConfig({ resolve: { alias: { - "@": path.resolve(__dirname, "./ts"), + "@": path.resolve(__dirname, "../ts"), }, }, @@ -38,7 +38,7 @@ export default defineConfig({ emptyOutDir: true, rollupOptions: { input: { - main: path.resolve(__dirname, "ts/main.ts"), + main: path.resolve(__dirname, "index-sync.html"), }, output: { entryFileNames: "js/bundle.[hash].js", @@ -58,7 +58,11 @@ export default defineConfig({ }, server: { - allowedHosts: ["poweredge.local", "dev-sync.nidus.cloud"], + allowedHosts: [ + "poweredge.local", + "dev-report.mosquitoes.online", + "dev-sync.nidus.cloud", + ], port: 9000, proxy: { "/api": {