@ibiz-template/vue3-util 0.2.11 → 0.2.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.min.css +1 -0
- package/dist/index.system.min.js +1 -1
- package/dist/index.system.min.js.map +1 -1
- package/es/_virtual/_commonjsHelpers.mjs +40 -0
- package/es/common/code-list/code-list.css +1 -0
- package/es/common/code-list/code-list.d.ts +58 -0
- package/es/common/code-list/code-list.d.ts.map +1 -0
- package/es/common/code-list/code-list.mjs +85 -0
- package/es/common/control-base/control-base.css +1 -0
- package/es/common/control-base/control-base.d.ts +2 -0
- package/es/common/control-base/control-base.d.ts.map +1 -0
- package/es/common/control-base/control-base.mjs +99 -0
- package/es/common/control-loading-placeholder/control-loading-placeholder.d.ts +31 -0
- package/es/common/control-loading-placeholder/control-loading-placeholder.d.ts.map +1 -0
- package/es/common/control-loading-placeholder/control-loading-placeholder.mjs +30 -0
- package/es/common/control-shell/control-shell.css +1 -0
- package/es/common/control-shell/control-shell.d.ts +21 -0
- package/es/common/control-shell/control-shell.d.ts.map +1 -0
- package/es/common/control-shell/control-shell.mjs +56 -0
- package/es/common/icon/icon.d.ts +29 -0
- package/es/common/icon/icon.d.ts.map +1 -0
- package/es/common/icon/icon.mjs +89 -0
- package/es/common/index.d.ts +9 -0
- package/es/common/index.d.ts.map +1 -0
- package/es/common/index.mjs +9 -0
- package/es/common/router-view/router-view.d.ts +30 -0
- package/es/common/router-view/router-view.d.ts.map +1 -0
- package/es/common/router-view/router-view.mjs +75 -0
- package/es/common/view-shell/view-shell.css +1 -0
- package/es/common/view-shell/view-shell.d.ts +40 -0
- package/es/common/view-shell/view-shell.d.ts.map +1 -0
- package/es/common/view-shell/view-shell.mjs +77 -0
- package/{out → es}/index.d.ts +3 -0
- package/es/index.d.ts.map +1 -0
- package/es/index.mjs +107 -0
- package/es/interface/index.mjs +3 -0
- package/es/interface/util/index.mjs +3 -0
- package/es/interface/util/route/route.mjs +1 -0
- package/es/node_modules/.pnpm/path-browserify@1.0.1/node_modules/path-browserify/index.mjs +535 -0
- package/es/panel-component/grid-container/grid-container.controller.d.ts +15 -0
- package/es/panel-component/grid-container/grid-container.controller.d.ts.map +1 -0
- package/es/panel-component/grid-container/grid-container.controller.mjs +12 -0
- package/es/panel-component/grid-container/grid-container.css +1 -0
- package/es/panel-component/grid-container/grid-container.d.ts +38 -0
- package/es/panel-component/grid-container/grid-container.d.ts.map +1 -0
- package/es/panel-component/grid-container/grid-container.mjs +106 -0
- package/es/panel-component/grid-container/grid-container.provider.d.ts +16 -0
- package/es/panel-component/grid-container/grid-container.provider.d.ts.map +1 -0
- package/es/panel-component/grid-container/grid-container.provider.mjs +15 -0
- package/es/panel-component/grid-container/grid-container.state.d.ts +13 -0
- package/es/panel-component/grid-container/grid-container.state.d.ts.map +1 -0
- package/es/panel-component/grid-container/grid-container.state.mjs +7 -0
- package/es/panel-component/grid-container/index.d.ts +39 -0
- package/es/panel-component/grid-container/index.d.ts.map +1 -0
- package/es/panel-component/grid-container/index.mjs +18 -0
- package/es/panel-component/index.d.ts +10 -0
- package/es/panel-component/index.d.ts.map +1 -0
- package/es/panel-component/index.mjs +38 -0
- package/es/panel-component/multi-data-container/index.d.ts +38 -0
- package/es/panel-component/multi-data-container/index.d.ts.map +1 -0
- package/es/panel-component/multi-data-container/index.mjs +21 -0
- package/es/panel-component/multi-data-container/multi-data-container-item.controller.d.ts +61 -0
- package/es/panel-component/multi-data-container/multi-data-container-item.controller.d.ts.map +1 -0
- package/es/panel-component/multi-data-container/multi-data-container-item.controller.mjs +117 -0
- package/es/panel-component/multi-data-container/multi-data-container-itm.state.d.ts +20 -0
- package/es/panel-component/multi-data-container/multi-data-container-itm.state.d.ts.map +1 -0
- package/es/panel-component/multi-data-container/multi-data-container-itm.state.mjs +17 -0
- package/es/panel-component/multi-data-container/multi-data-container.controller.d.ts +107 -0
- package/es/panel-component/multi-data-container/multi-data-container.controller.d.ts.map +1 -0
- package/es/panel-component/multi-data-container/multi-data-container.controller.mjs +260 -0
- package/es/panel-component/multi-data-container/multi-data-container.css +1 -0
- package/es/panel-component/multi-data-container/multi-data-container.d.ts +36 -0
- package/es/panel-component/multi-data-container/multi-data-container.d.ts.map +1 -0
- package/es/panel-component/multi-data-container/multi-data-container.mjs +87 -0
- package/es/panel-component/multi-data-container/multi-data-container.provider.d.ts +16 -0
- package/es/panel-component/multi-data-container/multi-data-container.provider.d.ts.map +1 -0
- package/es/panel-component/multi-data-container/multi-data-container.provider.mjs +15 -0
- package/es/panel-component/multi-data-container/multi-data-container.state.d.ts +20 -0
- package/es/panel-component/multi-data-container/multi-data-container.state.d.ts.map +1 -0
- package/es/panel-component/multi-data-container/multi-data-container.state.mjs +17 -0
- package/es/panel-component/nav-pos/index.d.ts +29 -0
- package/es/panel-component/nav-pos/index.d.ts.map +1 -0
- package/es/panel-component/nav-pos/index.mjs +15 -0
- package/es/panel-component/nav-pos/nav-pos.controller.d.ts +162 -0
- package/es/panel-component/nav-pos/nav-pos.controller.d.ts.map +1 -0
- package/es/panel-component/nav-pos/nav-pos.controller.mjs +261 -0
- package/es/panel-component/nav-pos/nav-pos.css +1 -0
- package/es/panel-component/nav-pos/nav-pos.d.ts +29 -0
- package/es/panel-component/nav-pos/nav-pos.d.ts.map +1 -0
- package/es/panel-component/nav-pos/nav-pos.mjs +105 -0
- package/es/panel-component/nav-pos/nav-pos.provider.d.ts +23 -0
- package/es/panel-component/nav-pos/nav-pos.provider.d.ts.map +1 -0
- package/es/panel-component/nav-pos/nav-pos.provider.mjs +24 -0
- package/es/panel-component/nav-pos/nav-pos.state.d.ts +50 -0
- package/es/panel-component/nav-pos/nav-pos.state.d.ts.map +1 -0
- package/es/panel-component/nav-pos/nav-pos.state.mjs +47 -0
- package/es/panel-component/panel-container/index.d.ts +28 -0
- package/es/panel-component/panel-container/index.d.ts.map +1 -0
- package/es/panel-component/panel-container/index.mjs +22 -0
- package/es/panel-component/panel-container/panel-container.controller.d.ts +15 -0
- package/es/panel-component/panel-container/panel-container.controller.d.ts.map +1 -0
- package/es/panel-component/panel-container/panel-container.controller.mjs +12 -0
- package/es/panel-component/panel-container/panel-container.css +1 -0
- package/es/panel-component/panel-container/panel-container.d.ts +27 -0
- package/es/panel-component/panel-container/panel-container.d.ts.map +1 -0
- package/es/panel-component/panel-container/panel-container.mjs +70 -0
- package/es/panel-component/panel-container/panel-container.provider.d.ts +16 -0
- package/es/panel-component/panel-container/panel-container.provider.d.ts.map +1 -0
- package/es/panel-component/panel-container/panel-container.provider.mjs +15 -0
- package/es/panel-component/panel-container/panel-container.state.d.ts +13 -0
- package/es/panel-component/panel-container/panel-container.state.d.ts.map +1 -0
- package/es/panel-component/panel-container/panel-container.state.mjs +7 -0
- package/es/panel-component/panel-ctrl-pos/index.d.ts +26 -0
- package/es/panel-component/panel-ctrl-pos/index.d.ts.map +1 -0
- package/es/panel-component/panel-ctrl-pos/index.mjs +14 -0
- package/es/panel-component/panel-ctrl-pos/panel-ctrl-pos.controller.d.ts +36 -0
- package/es/panel-component/panel-ctrl-pos/panel-ctrl-pos.controller.d.ts.map +1 -0
- package/es/panel-component/panel-ctrl-pos/panel-ctrl-pos.controller.mjs +23 -0
- package/es/panel-component/panel-ctrl-pos/panel-ctrl-pos.css +1 -0
- package/es/panel-component/panel-ctrl-pos/panel-ctrl-pos.d.ts +25 -0
- package/es/panel-component/panel-ctrl-pos/panel-ctrl-pos.d.ts.map +1 -0
- package/es/panel-component/panel-ctrl-pos/panel-ctrl-pos.mjs +45 -0
- package/es/panel-component/panel-ctrl-pos/panel-ctrl-pos.provider.d.ts +17 -0
- package/es/panel-component/panel-ctrl-pos/panel-ctrl-pos.provider.d.ts.map +1 -0
- package/es/panel-component/panel-ctrl-pos/panel-ctrl-pos.provider.mjs +15 -0
- package/es/panel-component/panel-field/index.d.ts +27 -0
- package/es/panel-component/panel-field/index.d.ts.map +1 -0
- package/es/panel-component/panel-field/index.mjs +14 -0
- package/es/panel-component/panel-field/panel-field.controller.d.ts +75 -0
- package/es/panel-component/panel-field/panel-field.controller.d.ts.map +1 -0
- package/es/panel-component/panel-field/panel-field.controller.mjs +90 -0
- package/es/panel-component/panel-field/panel-field.css +1 -0
- package/es/panel-component/panel-field/panel-field.d.ts +28 -0
- package/es/panel-component/panel-field/panel-field.d.ts.map +1 -0
- package/es/panel-component/panel-field/panel-field.mjs +73 -0
- package/es/panel-component/panel-field/panel-field.provider.d.ts +15 -0
- package/es/panel-component/panel-field/panel-field.provider.d.ts.map +1 -0
- package/es/panel-component/panel-field/panel-field.provider.mjs +15 -0
- package/es/panel-component/panel-field/panel-field.state.d.ts +13 -0
- package/es/panel-component/panel-field/panel-field.state.d.ts.map +1 -0
- package/es/panel-component/panel-field/panel-field.state.mjs +7 -0
- package/es/panel-component/panel-rawitem/index.d.ts +26 -0
- package/es/panel-component/panel-rawitem/index.d.ts.map +1 -0
- package/es/panel-component/panel-rawitem/index.mjs +18 -0
- package/es/panel-component/panel-rawitem/panel-rawitem.controller.d.ts +29 -0
- package/es/panel-component/panel-rawitem/panel-rawitem.controller.d.ts.map +1 -0
- package/es/panel-component/panel-rawitem/panel-rawitem.controller.mjs +28 -0
- package/es/panel-component/panel-rawitem/panel-rawitem.css +1 -0
- package/es/panel-component/panel-rawitem/panel-rawitem.d.ts +27 -0
- package/es/panel-component/panel-rawitem/panel-rawitem.d.ts.map +1 -0
- package/es/panel-component/panel-rawitem/panel-rawitem.mjs +50 -0
- package/es/panel-component/panel-rawitem/panel-rawitem.provider.d.ts +15 -0
- package/es/panel-component/panel-rawitem/panel-rawitem.provider.d.ts.map +1 -0
- package/es/panel-component/panel-rawitem/panel-rawitem.provider.mjs +15 -0
- package/es/panel-component/scroll-container/index.d.ts +26 -0
- package/es/panel-component/scroll-container/index.d.ts.map +1 -0
- package/es/panel-component/scroll-container/index.mjs +46 -0
- package/es/panel-component/scroll-container/scroll-container/index.d.ts +4 -0
- package/es/panel-component/scroll-container/scroll-container/index.d.ts.map +1 -0
- package/es/panel-component/scroll-container/scroll-container/index.mjs +5 -0
- package/es/panel-component/scroll-container/scroll-container/scroll-container.controller.d.ts +23 -0
- package/es/panel-component/scroll-container/scroll-container/scroll-container.controller.d.ts.map +1 -0
- package/es/panel-component/scroll-container/scroll-container/scroll-container.controller.mjs +12 -0
- package/es/panel-component/scroll-container/scroll-container/scroll-container.css +1 -0
- package/es/panel-component/scroll-container/scroll-container/scroll-container.d.ts +27 -0
- package/es/panel-component/scroll-container/scroll-container/scroll-container.d.ts.map +1 -0
- package/es/panel-component/scroll-container/scroll-container/scroll-container.mjs +112 -0
- package/es/panel-component/scroll-container/scroll-container/scroll-container.provider.d.ts +17 -0
- package/es/panel-component/scroll-container/scroll-container/scroll-container.provider.d.ts.map +1 -0
- package/es/panel-component/scroll-container/scroll-container/scroll-container.provider.mjs +15 -0
- package/es/panel-component/scroll-container/scroll-container-item/index.d.ts +4 -0
- package/es/panel-component/scroll-container/scroll-container-item/index.d.ts.map +1 -0
- package/es/panel-component/scroll-container/scroll-container-item/index.mjs +5 -0
- package/es/panel-component/scroll-container/scroll-container-item/scroll-container-item.controller.d.ts +22 -0
- package/es/panel-component/scroll-container/scroll-container-item/scroll-container-item.controller.d.ts.map +1 -0
- package/es/panel-component/scroll-container/scroll-container-item/scroll-container-item.controller.mjs +7 -0
- package/es/panel-component/scroll-container/scroll-container-item/scroll-container-item.css +1 -0
- package/es/panel-component/scroll-container/scroll-container-item/scroll-container-item.d.ts +27 -0
- package/es/panel-component/scroll-container/scroll-container-item/scroll-container-item.d.ts.map +1 -0
- package/es/panel-component/scroll-container/scroll-container-item/scroll-container-item.mjs +64 -0
- package/es/panel-component/scroll-container/scroll-container-item/scroll-container-item.provider.d.ts +17 -0
- package/es/panel-component/scroll-container/scroll-container-item/scroll-container-item.provider.d.ts.map +1 -0
- package/es/panel-component/scroll-container/scroll-container-item/scroll-container-item.provider.mjs +15 -0
- package/es/panel-component/single-data-container/index.d.ts +38 -0
- package/es/panel-component/single-data-container/index.d.ts.map +1 -0
- package/es/panel-component/single-data-container/index.mjs +21 -0
- package/es/panel-component/single-data-container/single-data-container.controller.d.ts +122 -0
- package/es/panel-component/single-data-container/single-data-container.controller.d.ts.map +1 -0
- package/es/panel-component/single-data-container/single-data-container.controller.mjs +285 -0
- package/es/panel-component/single-data-container/single-data-container.css +1 -0
- package/es/panel-component/single-data-container/single-data-container.d.ts +36 -0
- package/es/panel-component/single-data-container/single-data-container.d.ts.map +1 -0
- package/es/panel-component/single-data-container/single-data-container.mjs +77 -0
- package/es/panel-component/single-data-container/single-data-container.provider.d.ts +16 -0
- package/es/panel-component/single-data-container/single-data-container.provider.d.ts.map +1 -0
- package/es/panel-component/single-data-container/single-data-container.provider.mjs +15 -0
- package/es/panel-component/single-data-container/single-data-container.state.d.ts +20 -0
- package/es/panel-component/single-data-container/single-data-container.state.d.ts.map +1 -0
- package/es/panel-component/single-data-container/single-data-container.state.mjs +17 -0
- package/es/plugin/index.mjs +3 -0
- package/es/plugin/plugin-factory/plugin-factory.mjs +292 -0
- package/es/props/common.mjs +15 -0
- package/es/props/editor/array.mjs +11 -0
- package/es/props/editor/autocomplete.mjs +11 -0
- package/es/props/editor/cascader.mjs +11 -0
- package/es/props/editor/check-box-list.mjs +11 -0
- package/es/props/editor/check-box.mjs +11 -0
- package/es/props/editor/code.mjs +20 -0
- package/es/props/editor/color-picker.mjs +11 -0
- package/es/props/editor/common.mjs +48 -0
- package/es/props/editor/data-picker.mjs +11 -0
- package/es/props/editor/date-picker.mjs +11 -0
- package/es/props/editor/date-range.mjs +11 -0
- package/es/props/editor/dropdown-list.mjs +11 -0
- package/es/props/editor/html.mjs +11 -0
- package/es/props/editor/index.mjs +27 -0
- package/es/props/editor/list-box.mjs +11 -0
- package/es/props/editor/markdown.mjs +19 -0
- package/es/props/editor/number-range.mjs +11 -0
- package/es/props/editor/radio-button-list.mjs +11 -0
- package/es/props/editor/rate.mjs +11 -0
- package/es/props/editor/raw.mjs +11 -0
- package/es/props/editor/slider.mjs +11 -0
- package/{out → es}/props/editor/span.d.ts +2 -2
- package/es/props/editor/span.mjs +11 -0
- package/es/props/editor/stepper.mjs +11 -0
- package/es/props/editor/switch.mjs +11 -0
- package/es/props/editor/text-box.mjs +23 -0
- package/es/props/editor/upload.mjs +11 -0
- package/es/props/index.mjs +29 -0
- package/es/use/click-outside/click-outside.mjs +48 -0
- package/es/use/control/index.mjs +3 -0
- package/es/use/control/use-control-controller/use-control-controller.mjs +74 -0
- package/es/use/event/event.mjs +37 -0
- package/es/use/focus-blur/focus-blur.mjs +46 -0
- package/es/use/index.mjs +13 -0
- package/es/use/namespace/namespace.mjs +8 -0
- package/es/use/route/route.mjs +28 -0
- package/es/use/util/index.mjs +11 -0
- package/{out/use/view/index.js → es/use/view/index.mjs} +3 -1
- package/es/use/view/use-view-controller/use-view-controller.mjs +72 -0
- package/es/use/vue/vue.mjs +55 -0
- package/es/util/control/prepare-control.mjs +22 -0
- package/es/util/index.d.ts +11 -0
- package/es/util/index.d.ts.map +1 -0
- package/es/util/index.mjs +14 -0
- package/es/util/install.mjs +9 -0
- package/es/util/overlay-container/overlay-container.d.ts +93 -0
- package/es/util/overlay-container/overlay-container.d.ts.map +1 -0
- package/es/util/overlay-container/overlay-container.mjs +114 -0
- package/es/util/overlay-popover-container/overlay-popover-container.d.ts +17 -0
- package/es/util/overlay-popover-container/overlay-popover-container.d.ts.map +1 -0
- package/es/util/overlay-popover-container/overlay-popover-container.mjs +10 -0
- package/es/util/overlay-view-util/overlay-view-util.d.ts +9 -0
- package/es/util/overlay-view-util/overlay-view-util.d.ts.map +1 -0
- package/es/util/overlay-view-util/overlay-view-util.mjs +63 -0
- package/es/util/render/render.mjs +20 -0
- package/es/util/route/route-listener.mjs +73 -0
- package/{out → es}/util/route/route.d.ts +20 -20
- package/es/util/route/route.d.ts.map +1 -0
- package/es/util/route/route.mjs +252 -0
- package/es/util/router-callback/router-callback-item.d.ts +62 -0
- package/es/util/router-callback/router-callback-item.d.ts.map +1 -0
- package/es/util/router-callback/router-callback-item.mjs +72 -0
- package/es/util/router-callback/router-callback.d.ts +60 -0
- package/es/util/router-callback/router-callback.d.ts.map +1 -0
- package/es/util/router-callback/router-callback.mjs +86 -0
- package/es/util/store/app-store/app-store.d.ts +10 -0
- package/es/util/store/app-store/app-store.d.ts.map +1 -0
- package/es/util/store/app-store/app-store.mjs +10 -0
- package/es/util/store/index.d.ts +4 -0
- package/es/util/store/index.d.ts.map +1 -0
- package/es/util/store/index.mjs +8 -0
- package/es/util/store/ui-store/ui-store.d.ts +32 -0
- package/es/util/store/ui-store/ui-store.d.ts.map +1 -0
- package/es/util/store/ui-store/ui-store.mjs +15 -0
- package/es/util/store/ui-store/z-index.d.ts +35 -0
- package/es/util/store/ui-store/z-index.d.ts.map +1 -0
- package/es/util/store/ui-store/z-index.mjs +18 -0
- package/es/view/app-redirect-view/app-redirect-view.d.ts +2 -0
- package/es/view/app-redirect-view/app-redirect-view.d.ts.map +1 -0
- package/es/view/app-redirect-view/app-redirect-view.mjs +27 -0
- package/es/view/common/index.d.ts +51 -0
- package/es/view/common/index.d.ts.map +1 -0
- package/es/view/common/index.mjs +13 -0
- package/es/view/common/view.css +1 -0
- package/es/view/common/view.d.ts +53 -0
- package/es/view/common/view.d.ts.map +1 -0
- package/es/view/common/view.mjs +143 -0
- package/es/view/common/view.provider.d.ts +14 -0
- package/es/view/common/view.provider.d.ts.map +1 -0
- package/es/view/common/view.provider.mjs +8 -0
- package/es/view/index.d.ts +5 -0
- package/es/view/index.d.ts.map +1 -0
- package/es/view/index.mjs +8 -0
- package/es/view/portal-view/index.d.ts +43 -0
- package/es/view/portal-view/index.d.ts.map +1 -0
- package/es/view/portal-view/index.mjs +21 -0
- package/es/view/portal-view/portal-view.d.ts +44 -0
- package/es/view/portal-view/portal-view.d.ts.map +1 -0
- package/es/view/portal-view/portal-view.mjs +93 -0
- package/es/view/portal-view/portal-view.provider.d.ts +14 -0
- package/es/view/portal-view/portal-view.provider.d.ts.map +1 -0
- package/es/view/portal-view/portal-view.provider.mjs +8 -0
- package/es/view/todo-redirect/todo-redirect.d.ts +2 -0
- package/es/view/todo-redirect/todo-redirect.d.ts.map +1 -0
- package/es/view/todo-redirect/todo-redirect.mjs +52 -0
- package/lib/index.cjs +260 -0
- package/package.json +19 -14
- package/src/common/code-list/code-list.scss +5 -0
- package/src/common/code-list/code-list.tsx +108 -0
- package/src/common/control-base/control-base.scss +4 -0
- package/src/common/control-base/control-base.tsx +129 -0
- package/src/common/control-loading-placeholder/control-loading-placeholder.tsx +22 -0
- package/src/common/control-shell/control-shell.scss +5 -0
- package/src/common/control-shell/control-shell.tsx +70 -0
- package/src/common/icon/icon.tsx +69 -0
- package/src/common/index.ts +8 -0
- package/src/common/router-view/router-view.tsx +74 -0
- package/src/common/view-shell/view-shell.scss +5 -0
- package/src/common/view-shell/view-shell.tsx +70 -0
- package/src/index.ts +3 -0
- package/src/panel-component/grid-container/grid-container.controller.ts +18 -0
- package/src/panel-component/grid-container/grid-container.provider.ts +30 -0
- package/src/panel-component/grid-container/grid-container.scss +17 -0
- package/src/panel-component/grid-container/grid-container.state.ts +12 -0
- package/src/panel-component/grid-container/grid-container.tsx +119 -0
- package/src/panel-component/grid-container/index.ts +19 -0
- package/src/panel-component/index.ts +9 -0
- package/src/panel-component/multi-data-container/index.ts +26 -0
- package/src/panel-component/multi-data-container/multi-data-container-item.controller.ts +166 -0
- package/src/panel-component/multi-data-container/multi-data-container-itm.state.ts +20 -0
- package/src/panel-component/multi-data-container/multi-data-container.controller.ts +308 -0
- package/src/panel-component/multi-data-container/multi-data-container.provider.ts +30 -0
- package/src/panel-component/multi-data-container/multi-data-container.scss +10 -0
- package/src/panel-component/multi-data-container/multi-data-container.state.ts +20 -0
- package/src/panel-component/multi-data-container/multi-data-container.tsx +109 -0
- package/src/panel-component/nav-pos/index.ts +16 -0
- package/src/panel-component/nav-pos/nav-pos.controller.ts +351 -0
- package/src/panel-component/nav-pos/nav-pos.provider.ts +38 -0
- package/src/panel-component/nav-pos/nav-pos.scss +4 -0
- package/src/panel-component/nav-pos/nav-pos.state.ts +52 -0
- package/src/panel-component/nav-pos/nav-pos.tsx +121 -0
- package/src/panel-component/panel-container/index.ts +31 -0
- package/src/panel-component/panel-container/panel-container.controller.ts +18 -0
- package/src/panel-component/panel-container/panel-container.provider.ts +30 -0
- package/src/panel-component/panel-container/panel-container.scss +15 -0
- package/src/panel-component/panel-container/panel-container.state.ts +12 -0
- package/src/panel-component/panel-container/panel-container.tsx +72 -0
- package/src/panel-component/panel-ctrl-pos/index.ts +14 -0
- package/src/panel-component/panel-ctrl-pos/panel-ctrl-pos.controller.ts +53 -0
- package/src/panel-component/panel-ctrl-pos/panel-ctrl-pos.provider.ts +30 -0
- package/src/panel-component/panel-ctrl-pos/panel-ctrl-pos.scss +8 -0
- package/src/panel-component/panel-ctrl-pos/panel-ctrl-pos.tsx +53 -0
- package/src/panel-component/panel-field/index.ts +15 -0
- package/src/panel-component/panel-field/panel-field.controller.ts +130 -0
- package/src/panel-component/panel-field/panel-field.provider.ts +28 -0
- package/src/panel-component/panel-field/panel-field.scss +36 -0
- package/src/panel-component/panel-field/panel-field.state.ts +12 -0
- package/src/panel-component/panel-field/panel-field.tsx +78 -0
- package/src/panel-component/panel-rawitem/index.ts +19 -0
- package/src/panel-component/panel-rawitem/panel-rawitem.controller.ts +34 -0
- package/src/panel-component/panel-rawitem/panel-rawitem.provider.ts +28 -0
- package/src/panel-component/panel-rawitem/panel-rawitem.scss +8 -0
- package/src/panel-component/panel-rawitem/panel-rawitem.tsx +51 -0
- package/src/panel-component/scroll-container/index.ts +44 -0
- package/src/panel-component/scroll-container/scroll-container/index.ts +3 -0
- package/src/panel-component/scroll-container/scroll-container/scroll-container.controller.ts +32 -0
- package/src/panel-component/scroll-container/scroll-container/scroll-container.provider.ts +30 -0
- package/src/panel-component/scroll-container/scroll-container/scroll-container.scss +34 -0
- package/src/panel-component/scroll-container/scroll-container/scroll-container.tsx +110 -0
- package/src/panel-component/scroll-container/scroll-container-item/index.ts +3 -0
- package/src/panel-component/scroll-container/scroll-container-item/scroll-container-item.controller.ts +25 -0
- package/src/panel-component/scroll-container/scroll-container-item/scroll-container-item.provider.ts +30 -0
- package/src/panel-component/scroll-container/scroll-container-item/scroll-container-item.scss +9 -0
- package/src/panel-component/scroll-container/scroll-container-item/scroll-container-item.tsx +60 -0
- package/src/panel-component/single-data-container/index.ts +26 -0
- package/src/panel-component/single-data-container/single-data-container.controller.ts +345 -0
- package/src/panel-component/single-data-container/single-data-container.provider.ts +30 -0
- package/src/panel-component/single-data-container/single-data-container.scss +10 -0
- package/src/panel-component/single-data-container/single-data-container.state.ts +20 -0
- package/src/panel-component/single-data-container/single-data-container.tsx +95 -0
- package/src/props/editor/span.ts +1 -1
- package/src/util/index.ts +5 -0
- package/src/util/overlay-container/overlay-container.ts +155 -0
- package/src/util/overlay-popover-container/overlay-popover-container.ts +30 -0
- package/src/util/overlay-view-util/overlay-view-util.ts +89 -0
- package/src/util/route/route.ts +140 -140
- package/src/util/router-callback/router-callback-item.ts +98 -0
- package/src/util/router-callback/router-callback.ts +97 -0
- package/src/util/store/app-store/app-store.ts +10 -0
- package/src/util/store/index.ts +6 -0
- package/src/util/store/ui-store/ui-store.ts +27 -0
- package/src/util/store/ui-store/z-index.ts +53 -0
- package/src/view/app-redirect-view/app-redirect-view.tsx +26 -0
- package/src/view/common/index.ts +12 -0
- package/src/view/common/view.provider.ts +14 -0
- package/src/view/common/view.scss +38 -0
- package/src/view/common/view.tsx +180 -0
- package/src/view/index.ts +4 -0
- package/src/view/portal-view/index.ts +20 -0
- package/src/view/portal-view/portal-view.provider.ts +14 -0
- package/src/view/portal-view/portal-view.tsx +79 -0
- package/src/view/todo-redirect/todo-redirect.tsx +51 -0
- package/dist/index.esm.js +0 -1859
- package/out/index.d.ts.map +0 -1
- package/out/index.js +0 -5
- package/out/interface/index.js +0 -1
- package/out/interface/util/index.js +0 -1
- package/out/interface/util/route/route.js +0 -1
- package/out/plugin/index.js +0 -1
- package/out/plugin/plugin-factory/plugin-factory.js +0 -297
- package/out/props/common.js +0 -23
- package/out/props/editor/array.js +0 -25
- package/out/props/editor/autocomplete.js +0 -25
- package/out/props/editor/cascader.js +0 -25
- package/out/props/editor/check-box-list.js +0 -25
- package/out/props/editor/check-box.js +0 -25
- package/out/props/editor/code.js +0 -29
- package/out/props/editor/color-picker.js +0 -25
- package/out/props/editor/common.js +0 -79
- package/out/props/editor/data-picker.js +0 -25
- package/out/props/editor/date-picker.js +0 -25
- package/out/props/editor/date-range.js +0 -21
- package/out/props/editor/dropdown-list.js +0 -25
- package/out/props/editor/html.js +0 -25
- package/out/props/editor/index.js +0 -25
- package/out/props/editor/list-box.js +0 -25
- package/out/props/editor/markdown.js +0 -28
- package/out/props/editor/number-range.js +0 -21
- package/out/props/editor/radio-button-list.js +0 -25
- package/out/props/editor/rate.js +0 -21
- package/out/props/editor/raw.js +0 -21
- package/out/props/editor/slider.js +0 -21
- package/out/props/editor/span.js +0 -25
- package/out/props/editor/stepper.js +0 -21
- package/out/props/editor/switch.js +0 -21
- package/out/props/editor/text-box.js +0 -73
- package/out/props/editor/upload.js +0 -25
- package/out/props/index.js +0 -2
- package/out/use/click-outside/click-outside.js +0 -50
- package/out/use/control/index.js +0 -1
- package/out/use/control/use-control-controller/use-control-controller.js +0 -94
- package/out/use/event/event.js +0 -39
- package/out/use/focus-blur/focus-blur.js +0 -63
- package/out/use/index.js +0 -9
- package/out/use/namespace/namespace.js +0 -13
- package/out/use/route/route.js +0 -41
- package/out/use/util/index.js +0 -23
- package/out/use/view/use-view-controller/use-view-controller.js +0 -94
- package/out/use/vue/vue.js +0 -112
- package/out/util/control/prepare-control.js +0 -25
- package/out/util/index.d.ts +0 -6
- package/out/util/index.d.ts.map +0 -1
- package/out/util/index.js +0 -5
- package/out/util/install.js +0 -6
- package/out/util/render/render.js +0 -28
- package/out/util/route/route-listener.js +0 -76
- package/out/util/route/route.d.ts.map +0 -1
- package/out/util/route/route.js +0 -385
- /package/{out → es}/interface/index.d.ts +0 -0
- /package/{out → es}/interface/index.d.ts.map +0 -0
- /package/{out → es}/interface/util/index.d.ts +0 -0
- /package/{out → es}/interface/util/index.d.ts.map +0 -0
- /package/{out → es}/interface/util/route/route.d.ts +0 -0
- /package/{out → es}/interface/util/route/route.d.ts.map +0 -0
- /package/{out → es}/plugin/index.d.ts +0 -0
- /package/{out → es}/plugin/index.d.ts.map +0 -0
- /package/{out → es}/plugin/plugin-factory/plugin-factory.d.ts +0 -0
- /package/{out → es}/plugin/plugin-factory/plugin-factory.d.ts.map +0 -0
- /package/{out → es}/props/common.d.ts +0 -0
- /package/{out → es}/props/common.d.ts.map +0 -0
- /package/{out → es}/props/editor/array.d.ts +0 -0
- /package/{out → es}/props/editor/array.d.ts.map +0 -0
- /package/{out → es}/props/editor/autocomplete.d.ts +0 -0
- /package/{out → es}/props/editor/autocomplete.d.ts.map +0 -0
- /package/{out → es}/props/editor/cascader.d.ts +0 -0
- /package/{out → es}/props/editor/cascader.d.ts.map +0 -0
- /package/{out → es}/props/editor/check-box-list.d.ts +0 -0
- /package/{out → es}/props/editor/check-box-list.d.ts.map +0 -0
- /package/{out → es}/props/editor/check-box.d.ts +0 -0
- /package/{out → es}/props/editor/check-box.d.ts.map +0 -0
- /package/{out → es}/props/editor/code.d.ts +0 -0
- /package/{out → es}/props/editor/code.d.ts.map +0 -0
- /package/{out → es}/props/editor/color-picker.d.ts +0 -0
- /package/{out → es}/props/editor/color-picker.d.ts.map +0 -0
- /package/{out → es}/props/editor/common.d.ts +0 -0
- /package/{out → es}/props/editor/common.d.ts.map +0 -0
- /package/{out → es}/props/editor/data-picker.d.ts +0 -0
- /package/{out → es}/props/editor/data-picker.d.ts.map +0 -0
- /package/{out → es}/props/editor/date-picker.d.ts +0 -0
- /package/{out → es}/props/editor/date-picker.d.ts.map +0 -0
- /package/{out → es}/props/editor/date-range.d.ts +0 -0
- /package/{out → es}/props/editor/date-range.d.ts.map +0 -0
- /package/{out → es}/props/editor/dropdown-list.d.ts +0 -0
- /package/{out → es}/props/editor/dropdown-list.d.ts.map +0 -0
- /package/{out → es}/props/editor/html.d.ts +0 -0
- /package/{out → es}/props/editor/html.d.ts.map +0 -0
- /package/{out → es}/props/editor/index.d.ts +0 -0
- /package/{out → es}/props/editor/index.d.ts.map +0 -0
- /package/{out → es}/props/editor/list-box.d.ts +0 -0
- /package/{out → es}/props/editor/list-box.d.ts.map +0 -0
- /package/{out → es}/props/editor/markdown.d.ts +0 -0
- /package/{out → es}/props/editor/markdown.d.ts.map +0 -0
- /package/{out → es}/props/editor/number-range.d.ts +0 -0
- /package/{out → es}/props/editor/number-range.d.ts.map +0 -0
- /package/{out → es}/props/editor/radio-button-list.d.ts +0 -0
- /package/{out → es}/props/editor/radio-button-list.d.ts.map +0 -0
- /package/{out → es}/props/editor/rate.d.ts +0 -0
- /package/{out → es}/props/editor/rate.d.ts.map +0 -0
- /package/{out → es}/props/editor/raw.d.ts +0 -0
- /package/{out → es}/props/editor/raw.d.ts.map +0 -0
- /package/{out → es}/props/editor/slider.d.ts +0 -0
- /package/{out → es}/props/editor/slider.d.ts.map +0 -0
- /package/{out → es}/props/editor/span.d.ts.map +0 -0
- /package/{out → es}/props/editor/stepper.d.ts +0 -0
- /package/{out → es}/props/editor/stepper.d.ts.map +0 -0
- /package/{out → es}/props/editor/switch.d.ts +0 -0
- /package/{out → es}/props/editor/switch.d.ts.map +0 -0
- /package/{out → es}/props/editor/text-box.d.ts +0 -0
- /package/{out → es}/props/editor/text-box.d.ts.map +0 -0
- /package/{out → es}/props/editor/upload.d.ts +0 -0
- /package/{out → es}/props/editor/upload.d.ts.map +0 -0
- /package/{out → es}/props/index.d.ts +0 -0
- /package/{out → es}/props/index.d.ts.map +0 -0
- /package/{out → es}/use/click-outside/click-outside.d.ts +0 -0
- /package/{out → es}/use/click-outside/click-outside.d.ts.map +0 -0
- /package/{out → es}/use/control/index.d.ts +0 -0
- /package/{out → es}/use/control/index.d.ts.map +0 -0
- /package/{out → es}/use/control/use-control-controller/use-control-controller.d.ts +0 -0
- /package/{out → es}/use/control/use-control-controller/use-control-controller.d.ts.map +0 -0
- /package/{out → es}/use/event/event.d.ts +0 -0
- /package/{out → es}/use/event/event.d.ts.map +0 -0
- /package/{out → es}/use/focus-blur/focus-blur.d.ts +0 -0
- /package/{out → es}/use/focus-blur/focus-blur.d.ts.map +0 -0
- /package/{out → es}/use/index.d.ts +0 -0
- /package/{out → es}/use/index.d.ts.map +0 -0
- /package/{out → es}/use/namespace/namespace.d.ts +0 -0
- /package/{out → es}/use/namespace/namespace.d.ts.map +0 -0
- /package/{out → es}/use/route/route.d.ts +0 -0
- /package/{out → es}/use/route/route.d.ts.map +0 -0
- /package/{out → es}/use/util/index.d.ts +0 -0
- /package/{out → es}/use/util/index.d.ts.map +0 -0
- /package/{out → es}/use/view/index.d.ts +0 -0
- /package/{out → es}/use/view/index.d.ts.map +0 -0
- /package/{out → es}/use/view/use-view-controller/use-view-controller.d.ts +0 -0
- /package/{out → es}/use/view/use-view-controller/use-view-controller.d.ts.map +0 -0
- /package/{out → es}/use/vue/vue.d.ts +0 -0
- /package/{out → es}/use/vue/vue.d.ts.map +0 -0
- /package/{out → es}/util/control/prepare-control.d.ts +0 -0
- /package/{out → es}/util/control/prepare-control.d.ts.map +0 -0
- /package/{out → es}/util/install.d.ts +0 -0
- /package/{out → es}/util/install.d.ts.map +0 -0
- /package/{out → es}/util/render/render.d.ts +0 -0
- /package/{out → es}/util/render/render.d.ts.map +0 -0
- /package/{out → es}/util/route/route-listener.d.ts +0 -0
- /package/{out → es}/util/route/route-listener.d.ts.map +0 -0
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
/* eslint-disable no-param-reassign */
|
|
2
|
+
/* eslint-disable vue/no-mutating-props */
|
|
3
|
+
import {
|
|
4
|
+
CTX,
|
|
5
|
+
getControlProvider,
|
|
6
|
+
IControlProvider,
|
|
7
|
+
} from '@ibiz-template/runtime';
|
|
8
|
+
import {
|
|
9
|
+
defineComponent,
|
|
10
|
+
h,
|
|
11
|
+
inject,
|
|
12
|
+
PropType,
|
|
13
|
+
ref,
|
|
14
|
+
resolveComponent,
|
|
15
|
+
} from 'vue';
|
|
16
|
+
import './control-shell.scss';
|
|
17
|
+
import { IControl } from '@ibiz/model-core';
|
|
18
|
+
import { useNamespace } from '../../use';
|
|
19
|
+
|
|
20
|
+
export const IBizControlShell = defineComponent({
|
|
21
|
+
name: 'IBizControlShell',
|
|
22
|
+
props: {
|
|
23
|
+
modelData: { type: Object as PropType<IControl>, required: true },
|
|
24
|
+
},
|
|
25
|
+
setup(props) {
|
|
26
|
+
// 上下文里提前预告部件
|
|
27
|
+
const ctx = inject('ctx') as CTX;
|
|
28
|
+
|
|
29
|
+
ctx.evt.emit('onForecast', props.modelData.name!);
|
|
30
|
+
|
|
31
|
+
const isComplete = ref(false);
|
|
32
|
+
const errMsg = ref('');
|
|
33
|
+
const provider = ref<IControlProvider>();
|
|
34
|
+
getControlProvider(props.modelData)
|
|
35
|
+
.then(item => {
|
|
36
|
+
if (!item) {
|
|
37
|
+
errMsg.value = `未找到对应部件的适配器`;
|
|
38
|
+
} else {
|
|
39
|
+
provider.value = item;
|
|
40
|
+
}
|
|
41
|
+
isComplete.value = true;
|
|
42
|
+
})
|
|
43
|
+
.catch(err => {
|
|
44
|
+
ibiz.log.error(err);
|
|
45
|
+
errMsg.value = err.message;
|
|
46
|
+
isComplete.value = true;
|
|
47
|
+
});
|
|
48
|
+
const ns = useNamespace('control-shell');
|
|
49
|
+
|
|
50
|
+
return { ns, isComplete, errMsg, provider };
|
|
51
|
+
},
|
|
52
|
+
render() {
|
|
53
|
+
if (this.isComplete && this.provider) {
|
|
54
|
+
return h(
|
|
55
|
+
resolveComponent(this.provider.component) as string,
|
|
56
|
+
{
|
|
57
|
+
provider: this.provider,
|
|
58
|
+
...this.$props,
|
|
59
|
+
...this.$attrs,
|
|
60
|
+
},
|
|
61
|
+
this.$slots,
|
|
62
|
+
);
|
|
63
|
+
}
|
|
64
|
+
return (
|
|
65
|
+
<div class={this.ns.b()} v-loading={!this.isComplete}>
|
|
66
|
+
{this.isComplete ? this.errMsg : null}
|
|
67
|
+
</div>
|
|
68
|
+
);
|
|
69
|
+
},
|
|
70
|
+
});
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import { defineComponent, PropType, VNode, computed } from 'vue';
|
|
2
|
+
import { ISysImage } from '@ibiz/model-core';
|
|
3
|
+
import { IIcon } from '@ibiz-template/runtime';
|
|
4
|
+
import { isSvg } from '@ibiz-template/core';
|
|
5
|
+
import { useNamespace } from '../../use';
|
|
6
|
+
|
|
7
|
+
export const IBizIcon = defineComponent({
|
|
8
|
+
name: 'IBizIcon',
|
|
9
|
+
props: {
|
|
10
|
+
icon: {
|
|
11
|
+
type: Object as PropType<ISysImage | IIcon>,
|
|
12
|
+
},
|
|
13
|
+
size: {
|
|
14
|
+
type: String as PropType<'small' | 'medium' | 'large'>,
|
|
15
|
+
},
|
|
16
|
+
baseDir: {
|
|
17
|
+
type: String,
|
|
18
|
+
default: 'images',
|
|
19
|
+
},
|
|
20
|
+
},
|
|
21
|
+
setup(props) {
|
|
22
|
+
const ns = useNamespace('icon');
|
|
23
|
+
const BaseUrl = `${ibiz.env.assetsUrl}/${props.baseDir}/`;
|
|
24
|
+
|
|
25
|
+
function getContent(icon?: IData): VNode | null {
|
|
26
|
+
if (icon) {
|
|
27
|
+
if (icon.htmlStr) {
|
|
28
|
+
return <span class={ns.b()} v-html={icon.htmlStr}></span>;
|
|
29
|
+
}
|
|
30
|
+
if (icon.cssClass) {
|
|
31
|
+
if (icon.cssClass.indexOf('fa-') !== -1) {
|
|
32
|
+
return <i class={[ns.b(), icon.cssClass]} />;
|
|
33
|
+
}
|
|
34
|
+
return <ion-icon class={ns.b()} name={icon.cssClass}></ion-icon>;
|
|
35
|
+
}
|
|
36
|
+
if (icon.imagePath) {
|
|
37
|
+
if (icon.imagePath.endsWith('svg')) {
|
|
38
|
+
if (icon.imagePath.startsWith('http')) {
|
|
39
|
+
return <img class={ns.b()} src={icon.imagePath}></img>;
|
|
40
|
+
}
|
|
41
|
+
return (
|
|
42
|
+
<ion-icon
|
|
43
|
+
src={BaseUrl + icon.imagePath}
|
|
44
|
+
class={ns.b()}
|
|
45
|
+
></ion-icon>
|
|
46
|
+
);
|
|
47
|
+
}
|
|
48
|
+
if (icon.imagePath.startsWith('http')) {
|
|
49
|
+
return <img class={ns.b()} src={icon.imagePath} />;
|
|
50
|
+
}
|
|
51
|
+
return <img class={ns.b()} src={BaseUrl + icon.imagePath} />;
|
|
52
|
+
}
|
|
53
|
+
if (icon.rawContent) {
|
|
54
|
+
if (isSvg(icon.rawContent)) {
|
|
55
|
+
return <div class={ns.b()} v-html={icon.rawContent}></div>;
|
|
56
|
+
}
|
|
57
|
+
return <img class={ns.b()} src={icon.rawContent} />;
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
return null;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
const content = computed<VNode | null>(() => {
|
|
64
|
+
return getContent(props.icon);
|
|
65
|
+
});
|
|
66
|
+
|
|
67
|
+
return (): VNode | null => content.value;
|
|
68
|
+
},
|
|
69
|
+
});
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export * from './icon/icon';
|
|
2
|
+
export * from './router-view/router-view';
|
|
3
|
+
export * from './control-base/control-base';
|
|
4
|
+
export * from './control-shell/control-shell';
|
|
5
|
+
export * from './view-shell/view-shell';
|
|
6
|
+
export * from './code-list/code-list';
|
|
7
|
+
export * from './code-list/code-list';
|
|
8
|
+
export * from './control-loading-placeholder/control-loading-placeholder';
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
2
|
+
import { isNotNil } from 'ramda';
|
|
3
|
+
import { defineComponent, h, PropType, VNode, watch } from 'vue';
|
|
4
|
+
import { RouteLocationNormalizedLoaded } from 'vue-router';
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* 只会第一次绘制的时候绘制路由相关的内容,后面路由导致的router-view的回调都屏蔽了。
|
|
8
|
+
* 通过变更manualKey,来强制刷新router-view的slot回调。并且吧manualKey传给Component的key,搭配AppKeepAlive可以缓存组件
|
|
9
|
+
*/
|
|
10
|
+
|
|
11
|
+
export const IBizRouterView = defineComponent({
|
|
12
|
+
name: 'IBizRouterView',
|
|
13
|
+
inheritAttrs: false,
|
|
14
|
+
props: {
|
|
15
|
+
name: {
|
|
16
|
+
type: String as PropType<string>,
|
|
17
|
+
default: 'default',
|
|
18
|
+
},
|
|
19
|
+
route: Object as PropType<RouteLocationNormalizedLoaded>,
|
|
20
|
+
manualKey: {
|
|
21
|
+
type: String,
|
|
22
|
+
},
|
|
23
|
+
},
|
|
24
|
+
setup(props, { attrs }) {
|
|
25
|
+
const cache: { vNode?: VNode } = {};
|
|
26
|
+
|
|
27
|
+
let isActive = true;
|
|
28
|
+
|
|
29
|
+
watch(
|
|
30
|
+
() => props.manualKey,
|
|
31
|
+
(newVal, oldVal) => {
|
|
32
|
+
if (isNotNil(newVal) && newVal !== oldVal) {
|
|
33
|
+
isActive = true;
|
|
34
|
+
}
|
|
35
|
+
},
|
|
36
|
+
);
|
|
37
|
+
|
|
38
|
+
const renderComp = (Component: VNode, _route: any): VNode | undefined => {
|
|
39
|
+
// 非激活时返回缓存
|
|
40
|
+
if (!isActive) {
|
|
41
|
+
return cache.vNode;
|
|
42
|
+
}
|
|
43
|
+
isActive = false;
|
|
44
|
+
if (Component) {
|
|
45
|
+
const tempProps = { ...Component.props };
|
|
46
|
+
delete tempProps.onVnodeUnmounted;
|
|
47
|
+
delete tempProps.ref;
|
|
48
|
+
const hNode = h(Component.type as string, {
|
|
49
|
+
...tempProps,
|
|
50
|
+
...attrs,
|
|
51
|
+
key: props.manualKey,
|
|
52
|
+
});
|
|
53
|
+
cache.vNode = hNode;
|
|
54
|
+
return hNode;
|
|
55
|
+
}
|
|
56
|
+
return undefined;
|
|
57
|
+
};
|
|
58
|
+
|
|
59
|
+
return { renderComp };
|
|
60
|
+
},
|
|
61
|
+
render() {
|
|
62
|
+
return (
|
|
63
|
+
<router-view name={this.name} route={this.route}>
|
|
64
|
+
{({ Component, route }: any): VNode | VNode[] | undefined => {
|
|
65
|
+
const newComp = this.renderComp(Component, route);
|
|
66
|
+
if (this.$slots.default) {
|
|
67
|
+
return this.$slots.default({ Component: newComp, route });
|
|
68
|
+
}
|
|
69
|
+
return newComp;
|
|
70
|
+
}}
|
|
71
|
+
</router-view>
|
|
72
|
+
);
|
|
73
|
+
},
|
|
74
|
+
});
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
/* eslint-disable no-param-reassign */
|
|
2
|
+
/* eslint-disable vue/no-mutating-props */
|
|
3
|
+
import { getViewProvider, IViewProvider } from '@ibiz-template/runtime';
|
|
4
|
+
import { defineComponent, h, PropType, ref, resolveComponent } from 'vue';
|
|
5
|
+
import './view-shell.scss';
|
|
6
|
+
import { IAppView } from '@ibiz/model-core';
|
|
7
|
+
import { RuntimeError } from '@ibiz-template/core';
|
|
8
|
+
import { useNamespace } from '../../use';
|
|
9
|
+
|
|
10
|
+
export const IBizViewShell = defineComponent({
|
|
11
|
+
name: 'IBizViewShell',
|
|
12
|
+
props: {
|
|
13
|
+
context: { type: Object as PropType<IContext>, required: true },
|
|
14
|
+
params: { type: Object as PropType<IParams> },
|
|
15
|
+
modelData: { type: Object as PropType<IAppView> },
|
|
16
|
+
viewId: { type: String },
|
|
17
|
+
},
|
|
18
|
+
setup(props) {
|
|
19
|
+
const ns = useNamespace('view-shell');
|
|
20
|
+
const isComplete = ref(false);
|
|
21
|
+
const errMsg = ref('');
|
|
22
|
+
const provider = ref<IViewProvider>();
|
|
23
|
+
const viewModelData = ref<IAppView | undefined>();
|
|
24
|
+
// 初始化方法
|
|
25
|
+
const init = async (): Promise<void> => {
|
|
26
|
+
let viewModel: IAppView | undefined;
|
|
27
|
+
if (props.modelData) {
|
|
28
|
+
viewModel = props.modelData;
|
|
29
|
+
} else {
|
|
30
|
+
viewModel = await ibiz.hub.getAppView(props.viewId!);
|
|
31
|
+
}
|
|
32
|
+
if (!viewModel) {
|
|
33
|
+
throw new RuntimeError('未找到视图模型');
|
|
34
|
+
}
|
|
35
|
+
viewModelData.value = viewModel;
|
|
36
|
+
try {
|
|
37
|
+
provider.value = await getViewProvider(viewModel);
|
|
38
|
+
} catch (error) {
|
|
39
|
+
ibiz.log.error(error);
|
|
40
|
+
errMsg.value = (error as IData).message;
|
|
41
|
+
} finally {
|
|
42
|
+
isComplete.value = true;
|
|
43
|
+
}
|
|
44
|
+
};
|
|
45
|
+
|
|
46
|
+
init();
|
|
47
|
+
|
|
48
|
+
return { ns, isComplete, errMsg, viewModelData, provider };
|
|
49
|
+
},
|
|
50
|
+
render() {
|
|
51
|
+
if (this.isComplete && this.provider) {
|
|
52
|
+
return h(
|
|
53
|
+
resolveComponent(this.provider.component) as string,
|
|
54
|
+
{
|
|
55
|
+
context: this.$props.context,
|
|
56
|
+
params: this.$props.params,
|
|
57
|
+
modelData: this.viewModelData,
|
|
58
|
+
...this.$attrs,
|
|
59
|
+
provider: this.provider,
|
|
60
|
+
},
|
|
61
|
+
this.$slots,
|
|
62
|
+
);
|
|
63
|
+
}
|
|
64
|
+
return (
|
|
65
|
+
<div class={this.ns.b()} v-loading={!this.isComplete}>
|
|
66
|
+
{this.isComplete ? this.errMsg : null}
|
|
67
|
+
</div>
|
|
68
|
+
);
|
|
69
|
+
},
|
|
70
|
+
});
|
package/src/index.ts
CHANGED
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { PanelItemController } from '@ibiz-template/runtime';
|
|
2
|
+
import { IPanelContainer } from '@ibiz/model-core';
|
|
3
|
+
import { GridContainerState } from './grid-container.state';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* 面板栅格容器控制器
|
|
7
|
+
*
|
|
8
|
+
* @export
|
|
9
|
+
* @class GridContainerController
|
|
10
|
+
* @extends {PanelItemController}
|
|
11
|
+
*/
|
|
12
|
+
export class GridContainerController extends PanelItemController<IPanelContainer> {
|
|
13
|
+
declare state: GridContainerState;
|
|
14
|
+
|
|
15
|
+
protected createState(): GridContainerState {
|
|
16
|
+
return new GridContainerState(this.parent?.state);
|
|
17
|
+
}
|
|
18
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import {
|
|
2
|
+
IPanelItemProvider,
|
|
3
|
+
PanelController,
|
|
4
|
+
PanelItemController,
|
|
5
|
+
} from '@ibiz-template/runtime';
|
|
6
|
+
import { IPanelContainer } from '@ibiz/model-core';
|
|
7
|
+
import { GridContainerController } from './grid-container.controller';
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* 面板容器适配器
|
|
11
|
+
*
|
|
12
|
+
* @author lxm
|
|
13
|
+
* @date 2022-09-19 22:09:03
|
|
14
|
+
* @export
|
|
15
|
+
* @class GridContainerProvider
|
|
16
|
+
* @implements {EditorProvider}
|
|
17
|
+
*/
|
|
18
|
+
export class GridContainerProvider implements IPanelItemProvider {
|
|
19
|
+
component: string = 'IBizGridContainer';
|
|
20
|
+
|
|
21
|
+
async createController(
|
|
22
|
+
panelItem: IPanelContainer,
|
|
23
|
+
panel: PanelController,
|
|
24
|
+
parent: PanelItemController | undefined,
|
|
25
|
+
): Promise<PanelItemController> {
|
|
26
|
+
const c = new GridContainerController(panelItem, panel, parent);
|
|
27
|
+
await c.init();
|
|
28
|
+
return c;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
$grid-container: (
|
|
2
|
+
'bg-color': getCssVar('bg-color', 'overlay'),
|
|
3
|
+
'padding': getCssVar('padding'),
|
|
4
|
+
);
|
|
5
|
+
|
|
6
|
+
// 默认样式
|
|
7
|
+
@include b(grid-container) {
|
|
8
|
+
@include set-component-css-var('grid-container', $grid-container);
|
|
9
|
+
|
|
10
|
+
width: 100%;
|
|
11
|
+
height: 100%;
|
|
12
|
+
overflow: auto;
|
|
13
|
+
|
|
14
|
+
@include when(hidden) {
|
|
15
|
+
display: none;
|
|
16
|
+
}
|
|
17
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { PanelItemState } from '@ibiz-template/runtime';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* 面板栅格容器状态
|
|
5
|
+
*
|
|
6
|
+
* @author lxm
|
|
7
|
+
* @date 2023-02-07 06:04:27
|
|
8
|
+
* @export
|
|
9
|
+
* @class GridContainerState
|
|
10
|
+
* @extends {PanelItemState}
|
|
11
|
+
*/
|
|
12
|
+
export class GridContainerState extends PanelItemState {}
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
import { IFlexLayoutPos, IPanelContainer } from '@ibiz/model-core';
|
|
2
|
+
import { computed, defineComponent, PropType, ref, Ref, VNode } from 'vue';
|
|
3
|
+
import { useNamespace } from '../../use';
|
|
4
|
+
import { GridContainerController } from './grid-container.controller';
|
|
5
|
+
import './grid-container.scss';
|
|
6
|
+
|
|
7
|
+
export const GridContainer = defineComponent({
|
|
8
|
+
name: 'IBizGridContainer',
|
|
9
|
+
props: {
|
|
10
|
+
modelData: {
|
|
11
|
+
type: Object as PropType<IPanelContainer>,
|
|
12
|
+
required: true,
|
|
13
|
+
},
|
|
14
|
+
controller: {
|
|
15
|
+
type: GridContainerController,
|
|
16
|
+
required: true,
|
|
17
|
+
},
|
|
18
|
+
},
|
|
19
|
+
setup(props) {
|
|
20
|
+
const ns = useNamespace('grid-container');
|
|
21
|
+
const { id } = props.modelData;
|
|
22
|
+
|
|
23
|
+
// 类名控制
|
|
24
|
+
const classArr = computed(() => {
|
|
25
|
+
let result: Array<string | false> = [ns.b(), ns.m(id)];
|
|
26
|
+
result = [
|
|
27
|
+
...result,
|
|
28
|
+
...props.controller.containerClass,
|
|
29
|
+
ns.is('hidden', !props.controller.state.visible),
|
|
30
|
+
];
|
|
31
|
+
return result;
|
|
32
|
+
});
|
|
33
|
+
|
|
34
|
+
const layoutModel = computed(() => {
|
|
35
|
+
return { ...props.modelData.layout, layout: 'TABLE_12COL' };
|
|
36
|
+
});
|
|
37
|
+
|
|
38
|
+
const convertLayoutPos = (
|
|
39
|
+
layoutPos: IFlexLayoutPos,
|
|
40
|
+
adaptGrow: number,
|
|
41
|
+
): IFlexLayoutPos => {
|
|
42
|
+
const result = {
|
|
43
|
+
...layoutPos,
|
|
44
|
+
layout: 'TABLE_12COL',
|
|
45
|
+
colXS: layoutPos.grow || adaptGrow,
|
|
46
|
+
colSM: layoutPos.grow || adaptGrow,
|
|
47
|
+
colMD: layoutPos.grow || adaptGrow,
|
|
48
|
+
colLG: layoutPos.grow || adaptGrow,
|
|
49
|
+
};
|
|
50
|
+
delete result.grow;
|
|
51
|
+
return result;
|
|
52
|
+
};
|
|
53
|
+
|
|
54
|
+
// 自适应列个数, 算一次记录下来,后续不用计算
|
|
55
|
+
const adaptCols: Ref<undefined | number> = ref(undefined);
|
|
56
|
+
// 自适应列默认占据的grow
|
|
57
|
+
const adaptGrow: Ref<number> = ref(12);
|
|
58
|
+
|
|
59
|
+
return {
|
|
60
|
+
ns,
|
|
61
|
+
classArr,
|
|
62
|
+
layoutModel,
|
|
63
|
+
convertLayoutPos,
|
|
64
|
+
adaptGrow,
|
|
65
|
+
adaptCols,
|
|
66
|
+
};
|
|
67
|
+
},
|
|
68
|
+
render() {
|
|
69
|
+
// 内容区默认插槽处理,封装app-col
|
|
70
|
+
const defaultSlots: VNode[] = this.$slots.default?.() || [];
|
|
71
|
+
|
|
72
|
+
if (this.adaptCols === undefined) {
|
|
73
|
+
// 当前已经配置的grow
|
|
74
|
+
let currentGrow = 0;
|
|
75
|
+
// 自适应列个数
|
|
76
|
+
let adaptCols = 0;
|
|
77
|
+
defaultSlots.forEach(slot => {
|
|
78
|
+
const props = slot.props as IData;
|
|
79
|
+
if (props && props.modelData && props.modelData.layoutPos) {
|
|
80
|
+
if (typeof props.modelData.layoutPos.grow === 'number') {
|
|
81
|
+
currentGrow += props.modelData.layoutPos.grow;
|
|
82
|
+
} else if (typeof props.modelData.layoutPos.grow === 'undefined') {
|
|
83
|
+
adaptCols += 1;
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
});
|
|
87
|
+
// 自适应列默认占据的grow
|
|
88
|
+
let adaptGrow = 12;
|
|
89
|
+
if (adaptCols > 0) {
|
|
90
|
+
adaptGrow = (12 - currentGrow) / adaptCols;
|
|
91
|
+
}
|
|
92
|
+
this.adaptCols = adaptCols;
|
|
93
|
+
this.adaptGrow = adaptGrow;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
return (
|
|
97
|
+
<iBizRow class={this.classArr} layout={this.layoutModel}>
|
|
98
|
+
{defaultSlots.map(slot => {
|
|
99
|
+
const props = slot.props as IData;
|
|
100
|
+
if (!props || !props.controller) {
|
|
101
|
+
return slot;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
return (
|
|
105
|
+
<iBizCol
|
|
106
|
+
layoutPos={this.convertLayoutPos(
|
|
107
|
+
props.modelData.layoutPos,
|
|
108
|
+
this.adaptGrow,
|
|
109
|
+
)}
|
|
110
|
+
state={props.controller.state}
|
|
111
|
+
>
|
|
112
|
+
{slot}
|
|
113
|
+
</iBizCol>
|
|
114
|
+
);
|
|
115
|
+
})}
|
|
116
|
+
</iBizRow>
|
|
117
|
+
);
|
|
118
|
+
},
|
|
119
|
+
});
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { App } from 'vue';
|
|
2
|
+
import { registerPanelItemProvider } from '@ibiz-template/runtime';
|
|
3
|
+
import { withInstall } from '../../util';
|
|
4
|
+
import { GridContainer } from './grid-container';
|
|
5
|
+
import { GridContainerProvider } from './grid-container.provider';
|
|
6
|
+
import { GridContainerState } from './grid-container.state';
|
|
7
|
+
import { GridContainerController } from './grid-container.controller';
|
|
8
|
+
|
|
9
|
+
export { GridContainerProvider, GridContainerState, GridContainerController };
|
|
10
|
+
|
|
11
|
+
export const IBizGridContainer = withInstall(GridContainer, function (v: App) {
|
|
12
|
+
v.component(GridContainer.name, GridContainer);
|
|
13
|
+
registerPanelItemProvider(
|
|
14
|
+
'CONTAINER_CONTAINER_GRID',
|
|
15
|
+
() => new GridContainerProvider(),
|
|
16
|
+
);
|
|
17
|
+
});
|
|
18
|
+
|
|
19
|
+
export default IBizGridContainer;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export * from './panel-container';
|
|
2
|
+
export * from './panel-ctrl-pos';
|
|
3
|
+
export * from './scroll-container';
|
|
4
|
+
export * from './nav-pos';
|
|
5
|
+
export * from './panel-field';
|
|
6
|
+
export * from './panel-rawitem';
|
|
7
|
+
export * from './multi-data-container';
|
|
8
|
+
export * from './single-data-container';
|
|
9
|
+
export * from './grid-container';
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { App } from 'vue';
|
|
2
|
+
import { registerPanelItemProvider } from '@ibiz-template/runtime';
|
|
3
|
+
import { withInstall } from '../../util';
|
|
4
|
+
import { MultiDataContainer } from './multi-data-container';
|
|
5
|
+
import { MultiDataContainerProvider } from './multi-data-container.provider';
|
|
6
|
+
import { MultiDataContainerState } from './multi-data-container.state';
|
|
7
|
+
import { MultiDataContainerController } from './multi-data-container.controller';
|
|
8
|
+
|
|
9
|
+
export {
|
|
10
|
+
MultiDataContainerProvider,
|
|
11
|
+
MultiDataContainerState,
|
|
12
|
+
MultiDataContainerController,
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
export const IBizMultiDataContainer = withInstall(
|
|
16
|
+
MultiDataContainer,
|
|
17
|
+
function (v: App) {
|
|
18
|
+
v.component(MultiDataContainer.name, MultiDataContainer);
|
|
19
|
+
registerPanelItemProvider(
|
|
20
|
+
'CONTAINER_CONTAINER_MULTIDATA',
|
|
21
|
+
() => new MultiDataContainerProvider(),
|
|
22
|
+
);
|
|
23
|
+
},
|
|
24
|
+
);
|
|
25
|
+
|
|
26
|
+
export default IBizMultiDataContainer;
|