Skip to content

Commit

Permalink
chore: updated shoelace, utils, components
Browse files Browse the repository at this point in the history
  • Loading branch information
akelch committed Sep 12, 2023
1 parent 82a5039 commit 4ba19b1
Show file tree
Hide file tree
Showing 10 changed files with 266 additions and 168 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,4 @@ vi-base/public/viur-shoelace/assets
node_modules
admin/stats.html
admin/public/viur-shoelace/assets
admin/public/shoelace/assets
9 changes: 6 additions & 3 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
[submodule "vi-base/src/style/ignite"]
path = vi-base/src/style/ignite
url = https://github.com/viur-framework/ignite.git
[submodule "packages/vi-vue-components"]
path = packages/vi-vue-components
url = git@github.com:viur-framework/vi-vue-components.git
[submodule "packages/vi-vue-utils"]
path = packages/vi-vue-utils
url = git@github.com:viur-framework/vi-vue-utils.git
294 changes: 201 additions & 93 deletions admin/package-lock.json

Large diffs are not rendered by default.

13 changes: 8 additions & 5 deletions admin/package.json
Original file line number Diff line number Diff line change
@@ -1,18 +1,21 @@
{
"name": "admin",
"version": "4.0.4",
"version": "4.0.5",
"private": true,
"description": "A ViUR Admin Interface",
"scripts": {
"dev": "vite --port=8082",
"build": "vue-tsc --noEmit && vite build"
"build": "vue-tsc --noEmit && vite build",
"install-prod": "npm un @viur/vue-utils && npm i @viur/vue-utils && npm un --prefix ../packages/vi-vue-components/components @viur/vue-utils && npm i --prefix ../packages/vi-vue-components/components @viur/vue-utils && npm un @viur/vue-components && npm i @viur/vue-components && npm i",
"install-dev": "npm un --prefix ../packages/vi-vue-components/components @viur/vue-utils && npm i --prefix ../packages/vi-vue-components/components ../packages/vi-vue-utils/packages/viur-vue-utils && npm un @viur/vue-utils && npm i ../packages/vi-vue-utils/packages/viur-vue-utils && npm un @viur/vue-components && npm i ../packages/vi-vue-components/components && npm i --prefix ../packages/vi-vue-components/components && npm i --prefix ../packages/vi-vue-utils/packages/viur-vue-utils && npm i"
},
"author": "Andreas H. Kelch",
"dependencies": {
"@ckeditor/ckeditor5-vue": "^5.1.0",
"@viur/viur-shoelace": "^2.4.0-viur-0.5.17",
"@viur/vue-components": "^1.0.9",
"@viur/vue-utils": "^1.0.1",
"@viur/ckeditor5-build-classic": "^1.0.1-v38.0.1",
"@viur/shoelace": "^0.6.1-v2.8.0",
"@viur/vue-components": "^1.0.12",
"@viur/vue-utils": "^1.0.3",
"pinia": "^2.1.4",
"pinia-plugin-persistedstate": "^3.1.0",
"vue": "^3.3.4",
Expand Down
86 changes: 43 additions & 43 deletions admin/src/shoelaceConfig.ts
Original file line number Diff line number Diff line change
@@ -1,53 +1,53 @@
// @ts-nocheck
import "@viur/viur-shoelace/dist/components/button/button"
import "@viur/viur-shoelace/dist/components/button-group/button-group"
import "@viur/viur-shoelace/dist/components/icon/icon"
import "@viur/viur-shoelace/dist/components/input/input"
import "@viur/viur-shoelace/dist/components/dropdown/dropdown"
import "@viur/viur-shoelace/dist/components/option/option"
import "@viur/viur-shoelace/dist/components/menu/menu"
import "@viur/viur-shoelace/dist/components/menu-item/menu-item"
import "@viur/viur-shoelace/dist/components/badge/badge"
import "@viur/viur-shoelace/dist/components/divider/divider"
import "@viur/viur-shoelace/dist/components/avatar/avatar"
import "@viur/viur-shoelace/dist/components/dialog/dialog"
import "@viur/viur-shoelace/dist/components/tooltip/tooltip"
import "@viur/viur-shoelace/dist/components/split-panel/split-panel"
import "@viur/viur-shoelace/dist/components/radio-group/radio-group"
import "@viur/viur-shoelace/dist/components/radio-button/radio-button"
import "@viur/viur-shoelace/dist/components/select/select"
import "@viur/viur-shoelace/dist/components/spinner/spinner"
import "@viur/viur-shoelace/dist/components/card/card"
import "@viur/viur-shoelace/dist/components/tag/tag"
import "@viur/viur-shoelace/dist/components/tooltip/tooltip"
import "@viur/viur-shoelace/dist/components/checkbox/checkbox"
import "@viur/viur-shoelace/dist/components/drawer/drawer"
import "@viur/viur-shoelace/dist/components/alert/alert"
import "@viur/viur-shoelace/dist/components/tab/tab"
import "@viur/viur-shoelace/dist/components/tab-group/tab-group"
import "@viur/viur-shoelace/dist/components/tab-panel/tab-panel"
import "@viur/viur-shoelace/dist/components/details/details"
import "@viur/viur-shoelace/dist/components/switch/switch"
import "@viur/viur-shoelace/dist/components/combobox/combobox"
import "@viur/viur-shoelace/dist/components/icon-button/icon-button"
import "@viur/viur-shoelace/dist/components/breadcrumb/breadcrumb"
import "@viur/viur-shoelace/dist/components/breadcrumb-item/breadcrumb-item"
import "@viur/viur-shoelace/dist/components/dialog/dialog"
import "@viur/viur-shoelace/dist/components/format-bytes/format-bytes"
import "@viur/viur-shoelace/dist/components/format-date/format-date"
import "@viur/viur-shoelace/dist/components/color-picker/color-picker"
import "@viur/viur-shoelace/dist/components/textarea/textarea"
import "@viur/viur-shoelace/dist/components/animation/animation"
import "@viur/shoelace/dist/components/button/button"
import "@viur/shoelace/dist/components/button-group/button-group"
import "@viur/shoelace/dist/components/icon/icon"
import "@viur/shoelace/dist/components/input/input"
import "@viur/shoelace/dist/components/dropdown/dropdown"
import "@viur/shoelace/dist/components/option/option"
import "@viur/shoelace/dist/components/menu/menu"
import "@viur/shoelace/dist/components/menu-item/menu-item"
import "@viur/shoelace/dist/components/badge/badge"
import "@viur/shoelace/dist/components/divider/divider"
import "@viur/shoelace/dist/components/avatar/avatar"
import "@viur/shoelace/dist/components/dialog/dialog"
import "@viur/shoelace/dist/components/tooltip/tooltip"
import "@viur/shoelace/dist/components/split-panel/split-panel"
import "@viur/shoelace/dist/components/radio-group/radio-group"
import "@viur/shoelace/dist/components/radio-button/radio-button"
import "@viur/shoelace/dist/components/select/select"
import "@viur/shoelace/dist/components/spinner/spinner"
import "@viur/shoelace/dist/components/card/card"
import "@viur/shoelace/dist/components/tag/tag"
import "@viur/shoelace/dist/components/tooltip/tooltip"
import "@viur/shoelace/dist/components/checkbox/checkbox"
import "@viur/shoelace/dist/components/drawer/drawer"
import "@viur/shoelace/dist/components/alert/alert"
import "@viur/shoelace/dist/components/tab/tab"
import "@viur/shoelace/dist/components/tab-group/tab-group"
import "@viur/shoelace/dist/components/tab-panel/tab-panel"
import "@viur/shoelace/dist/components/details/details"
import "@viur/shoelace/dist/components/switch/switch"
import "@viur/shoelace/dist/components/combobox/combobox"
import "@viur/shoelace/dist/components/icon-button/icon-button"
import "@viur/shoelace/dist/components/breadcrumb/breadcrumb"
import "@viur/shoelace/dist/components/breadcrumb-item/breadcrumb-item"
import "@viur/shoelace/dist/components/dialog/dialog"
import "@viur/shoelace/dist/components/format-bytes/format-bytes"
import "@viur/shoelace/dist/components/format-date/format-date"
import "@viur/shoelace/dist/components/color-picker/color-picker"
import "@viur/shoelace/dist/components/textarea/textarea"
import "@viur/shoelace/dist/components/animation/animation"

import { setBasePath, getBasePath } from "@viur/viur-shoelace/dist/utilities/base-path"
import { registerIconLibrary } from "@viur/viur-shoelace/dist/utilities/icon-library.js"
import { setBasePath, getBasePath } from "@viur/shoelace/dist/utilities/base-path"
import { registerIconLibrary } from "@viur/shoelace/dist/utilities/icon-library.js"

let basePath = ""
if (import.meta.env.DEV) {
setBasePath(`s/viur-shoelace`)
setBasePath(`s/shoelace`)
basePath = "s/"
} else {
setBasePath(`viur-shoelace`)
setBasePath(`shoelace`)
}

import "@viur/vue-components/style/app.css"
11 changes: 5 additions & 6 deletions admin/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,14 @@ import copy from 'rollup-plugin-copy'
import {visualizer} from 'rollup-plugin-visualizer'

// https://vitejs.dev/config/
console.log(path.join(__dirname, "node_modules", "@viur", "viur-shoelace", "dist", "assets"))
export default defineConfig({
plugins: [
visualizer(),
copy({
targets: [
{
src: path.join(__dirname, "node_modules", "@viur", "viur-shoelace", "dist", "assets"),
dest: path.join(__dirname, 'public', "viur-shoelace")
src: path.join(__dirname, "node_modules", "@viur", "shoelace", "dist", "assets"),
dest: path.join(__dirname, 'public', "shoelace")
}
]
}),
Expand Down Expand Up @@ -52,16 +51,16 @@ export default defineConfig({
},
output: {
chunkFileNames: (chunkinfo) => {
if (chunkinfo['moduleIds'].filter(x => x.includes('node_modules/@viur/viur-shoelace/dist/components')).length > 0) {
if (chunkinfo['moduleIds'].filter(x => x.includes('node_modules/@viur/shoelace/dist/components')).length > 0) {
return `[name].js`
} else {
return `[name]-[hash].js`
}

},
manualChunks(id) {
if (id.includes('node_modules/@viur/viur-shoelace/dist/components')) {
return "viur-shoelace/component_" + id.split("/").slice(-2)[0];
if (id.includes('node_modules/@viur/shoelace/dist/components')) {
return "shoelace/component_" + id.split("/").slice(-2)[0];
}
if(id.includes("node_modules/@viur/ckeditor5-build-classic/build/ckeditor.js")){
return "viur-ckeditor.js"
Expand Down
12 changes: 0 additions & 12 deletions package-lock.json

This file was deleted.

6 changes: 0 additions & 6 deletions package.json

This file was deleted.

1 change: 1 addition & 0 deletions packages/vi-vue-components
Submodule vi-vue-components added at 48f7d1
1 change: 1 addition & 0 deletions packages/vi-vue-utils
Submodule vi-vue-utils added at bb28f1

0 comments on commit 4ba19b1

Please sign in to comment.