@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
package/dist/index.esm.js
DELETED
|
@@ -1,1859 +0,0 @@
|
|
|
1
|
-
var __create = Object.create;
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
6
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
-
var __commonJS = (cb, mod) => function __require() {
|
|
8
|
-
return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
|
|
9
|
-
};
|
|
10
|
-
var __copyProps = (to, from, except, desc) => {
|
|
11
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
-
for (let key of __getOwnPropNames(from))
|
|
13
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
-
}
|
|
16
|
-
return to;
|
|
17
|
-
};
|
|
18
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
19
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
20
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
21
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
22
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
23
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
24
|
-
mod
|
|
25
|
-
));
|
|
26
|
-
|
|
27
|
-
// ../../node_modules/.pnpm/path-browserify@1.0.1/node_modules/path-browserify/index.js
|
|
28
|
-
var require_path_browserify = __commonJS({
|
|
29
|
-
"../../node_modules/.pnpm/path-browserify@1.0.1/node_modules/path-browserify/index.js"(exports, module) {
|
|
30
|
-
"use strict";
|
|
31
|
-
function assertPath(path2) {
|
|
32
|
-
if (typeof path2 !== "string") {
|
|
33
|
-
throw new TypeError("Path must be a string. Received " + JSON.stringify(path2));
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
function normalizeStringPosix(path2, allowAboveRoot) {
|
|
37
|
-
var res = "";
|
|
38
|
-
var lastSegmentLength = 0;
|
|
39
|
-
var lastSlash = -1;
|
|
40
|
-
var dots = 0;
|
|
41
|
-
var code;
|
|
42
|
-
for (var i = 0; i <= path2.length; ++i) {
|
|
43
|
-
if (i < path2.length)
|
|
44
|
-
code = path2.charCodeAt(i);
|
|
45
|
-
else if (code === 47)
|
|
46
|
-
break;
|
|
47
|
-
else
|
|
48
|
-
code = 47;
|
|
49
|
-
if (code === 47) {
|
|
50
|
-
if (lastSlash === i - 1 || dots === 1) {
|
|
51
|
-
} else if (lastSlash !== i - 1 && dots === 2) {
|
|
52
|
-
if (res.length < 2 || lastSegmentLength !== 2 || res.charCodeAt(res.length - 1) !== 46 || res.charCodeAt(res.length - 2) !== 46) {
|
|
53
|
-
if (res.length > 2) {
|
|
54
|
-
var lastSlashIndex = res.lastIndexOf("/");
|
|
55
|
-
if (lastSlashIndex !== res.length - 1) {
|
|
56
|
-
if (lastSlashIndex === -1) {
|
|
57
|
-
res = "";
|
|
58
|
-
lastSegmentLength = 0;
|
|
59
|
-
} else {
|
|
60
|
-
res = res.slice(0, lastSlashIndex);
|
|
61
|
-
lastSegmentLength = res.length - 1 - res.lastIndexOf("/");
|
|
62
|
-
}
|
|
63
|
-
lastSlash = i;
|
|
64
|
-
dots = 0;
|
|
65
|
-
continue;
|
|
66
|
-
}
|
|
67
|
-
} else if (res.length === 2 || res.length === 1) {
|
|
68
|
-
res = "";
|
|
69
|
-
lastSegmentLength = 0;
|
|
70
|
-
lastSlash = i;
|
|
71
|
-
dots = 0;
|
|
72
|
-
continue;
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
if (allowAboveRoot) {
|
|
76
|
-
if (res.length > 0)
|
|
77
|
-
res += "/..";
|
|
78
|
-
else
|
|
79
|
-
res = "..";
|
|
80
|
-
lastSegmentLength = 2;
|
|
81
|
-
}
|
|
82
|
-
} else {
|
|
83
|
-
if (res.length > 0)
|
|
84
|
-
res += "/" + path2.slice(lastSlash + 1, i);
|
|
85
|
-
else
|
|
86
|
-
res = path2.slice(lastSlash + 1, i);
|
|
87
|
-
lastSegmentLength = i - lastSlash - 1;
|
|
88
|
-
}
|
|
89
|
-
lastSlash = i;
|
|
90
|
-
dots = 0;
|
|
91
|
-
} else if (code === 46 && dots !== -1) {
|
|
92
|
-
++dots;
|
|
93
|
-
} else {
|
|
94
|
-
dots = -1;
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
return res;
|
|
98
|
-
}
|
|
99
|
-
function _format(sep, pathObject) {
|
|
100
|
-
var dir = pathObject.dir || pathObject.root;
|
|
101
|
-
var base = pathObject.base || (pathObject.name || "") + (pathObject.ext || "");
|
|
102
|
-
if (!dir) {
|
|
103
|
-
return base;
|
|
104
|
-
}
|
|
105
|
-
if (dir === pathObject.root) {
|
|
106
|
-
return dir + base;
|
|
107
|
-
}
|
|
108
|
-
return dir + sep + base;
|
|
109
|
-
}
|
|
110
|
-
var posix = {
|
|
111
|
-
// path.resolve([from ...], to)
|
|
112
|
-
resolve: function resolve() {
|
|
113
|
-
var resolvedPath = "";
|
|
114
|
-
var resolvedAbsolute = false;
|
|
115
|
-
var cwd;
|
|
116
|
-
for (var i = arguments.length - 1; i >= -1 && !resolvedAbsolute; i--) {
|
|
117
|
-
var path2;
|
|
118
|
-
if (i >= 0)
|
|
119
|
-
path2 = arguments[i];
|
|
120
|
-
else {
|
|
121
|
-
if (cwd === void 0)
|
|
122
|
-
cwd = process.cwd();
|
|
123
|
-
path2 = cwd;
|
|
124
|
-
}
|
|
125
|
-
assertPath(path2);
|
|
126
|
-
if (path2.length === 0) {
|
|
127
|
-
continue;
|
|
128
|
-
}
|
|
129
|
-
resolvedPath = path2 + "/" + resolvedPath;
|
|
130
|
-
resolvedAbsolute = path2.charCodeAt(0) === 47;
|
|
131
|
-
}
|
|
132
|
-
resolvedPath = normalizeStringPosix(resolvedPath, !resolvedAbsolute);
|
|
133
|
-
if (resolvedAbsolute) {
|
|
134
|
-
if (resolvedPath.length > 0)
|
|
135
|
-
return "/" + resolvedPath;
|
|
136
|
-
else
|
|
137
|
-
return "/";
|
|
138
|
-
} else if (resolvedPath.length > 0) {
|
|
139
|
-
return resolvedPath;
|
|
140
|
-
} else {
|
|
141
|
-
return ".";
|
|
142
|
-
}
|
|
143
|
-
},
|
|
144
|
-
normalize: function normalize(path2) {
|
|
145
|
-
assertPath(path2);
|
|
146
|
-
if (path2.length === 0)
|
|
147
|
-
return ".";
|
|
148
|
-
var isAbsolute = path2.charCodeAt(0) === 47;
|
|
149
|
-
var trailingSeparator = path2.charCodeAt(path2.length - 1) === 47;
|
|
150
|
-
path2 = normalizeStringPosix(path2, !isAbsolute);
|
|
151
|
-
if (path2.length === 0 && !isAbsolute)
|
|
152
|
-
path2 = ".";
|
|
153
|
-
if (path2.length > 0 && trailingSeparator)
|
|
154
|
-
path2 += "/";
|
|
155
|
-
if (isAbsolute)
|
|
156
|
-
return "/" + path2;
|
|
157
|
-
return path2;
|
|
158
|
-
},
|
|
159
|
-
isAbsolute: function isAbsolute(path2) {
|
|
160
|
-
assertPath(path2);
|
|
161
|
-
return path2.length > 0 && path2.charCodeAt(0) === 47;
|
|
162
|
-
},
|
|
163
|
-
join: function join2() {
|
|
164
|
-
if (arguments.length === 0)
|
|
165
|
-
return ".";
|
|
166
|
-
var joined;
|
|
167
|
-
for (var i = 0; i < arguments.length; ++i) {
|
|
168
|
-
var arg = arguments[i];
|
|
169
|
-
assertPath(arg);
|
|
170
|
-
if (arg.length > 0) {
|
|
171
|
-
if (joined === void 0)
|
|
172
|
-
joined = arg;
|
|
173
|
-
else
|
|
174
|
-
joined += "/" + arg;
|
|
175
|
-
}
|
|
176
|
-
}
|
|
177
|
-
if (joined === void 0)
|
|
178
|
-
return ".";
|
|
179
|
-
return posix.normalize(joined);
|
|
180
|
-
},
|
|
181
|
-
relative: function relative(from, to) {
|
|
182
|
-
assertPath(from);
|
|
183
|
-
assertPath(to);
|
|
184
|
-
if (from === to)
|
|
185
|
-
return "";
|
|
186
|
-
from = posix.resolve(from);
|
|
187
|
-
to = posix.resolve(to);
|
|
188
|
-
if (from === to)
|
|
189
|
-
return "";
|
|
190
|
-
var fromStart = 1;
|
|
191
|
-
for (; fromStart < from.length; ++fromStart) {
|
|
192
|
-
if (from.charCodeAt(fromStart) !== 47)
|
|
193
|
-
break;
|
|
194
|
-
}
|
|
195
|
-
var fromEnd = from.length;
|
|
196
|
-
var fromLen = fromEnd - fromStart;
|
|
197
|
-
var toStart = 1;
|
|
198
|
-
for (; toStart < to.length; ++toStart) {
|
|
199
|
-
if (to.charCodeAt(toStart) !== 47)
|
|
200
|
-
break;
|
|
201
|
-
}
|
|
202
|
-
var toEnd = to.length;
|
|
203
|
-
var toLen = toEnd - toStart;
|
|
204
|
-
var length = fromLen < toLen ? fromLen : toLen;
|
|
205
|
-
var lastCommonSep = -1;
|
|
206
|
-
var i = 0;
|
|
207
|
-
for (; i <= length; ++i) {
|
|
208
|
-
if (i === length) {
|
|
209
|
-
if (toLen > length) {
|
|
210
|
-
if (to.charCodeAt(toStart + i) === 47) {
|
|
211
|
-
return to.slice(toStart + i + 1);
|
|
212
|
-
} else if (i === 0) {
|
|
213
|
-
return to.slice(toStart + i);
|
|
214
|
-
}
|
|
215
|
-
} else if (fromLen > length) {
|
|
216
|
-
if (from.charCodeAt(fromStart + i) === 47) {
|
|
217
|
-
lastCommonSep = i;
|
|
218
|
-
} else if (i === 0) {
|
|
219
|
-
lastCommonSep = 0;
|
|
220
|
-
}
|
|
221
|
-
}
|
|
222
|
-
break;
|
|
223
|
-
}
|
|
224
|
-
var fromCode = from.charCodeAt(fromStart + i);
|
|
225
|
-
var toCode = to.charCodeAt(toStart + i);
|
|
226
|
-
if (fromCode !== toCode)
|
|
227
|
-
break;
|
|
228
|
-
else if (fromCode === 47)
|
|
229
|
-
lastCommonSep = i;
|
|
230
|
-
}
|
|
231
|
-
var out = "";
|
|
232
|
-
for (i = fromStart + lastCommonSep + 1; i <= fromEnd; ++i) {
|
|
233
|
-
if (i === fromEnd || from.charCodeAt(i) === 47) {
|
|
234
|
-
if (out.length === 0)
|
|
235
|
-
out += "..";
|
|
236
|
-
else
|
|
237
|
-
out += "/..";
|
|
238
|
-
}
|
|
239
|
-
}
|
|
240
|
-
if (out.length > 0)
|
|
241
|
-
return out + to.slice(toStart + lastCommonSep);
|
|
242
|
-
else {
|
|
243
|
-
toStart += lastCommonSep;
|
|
244
|
-
if (to.charCodeAt(toStart) === 47)
|
|
245
|
-
++toStart;
|
|
246
|
-
return to.slice(toStart);
|
|
247
|
-
}
|
|
248
|
-
},
|
|
249
|
-
_makeLong: function _makeLong(path2) {
|
|
250
|
-
return path2;
|
|
251
|
-
},
|
|
252
|
-
dirname: function dirname(path2) {
|
|
253
|
-
assertPath(path2);
|
|
254
|
-
if (path2.length === 0)
|
|
255
|
-
return ".";
|
|
256
|
-
var code = path2.charCodeAt(0);
|
|
257
|
-
var hasRoot = code === 47;
|
|
258
|
-
var end = -1;
|
|
259
|
-
var matchedSlash = true;
|
|
260
|
-
for (var i = path2.length - 1; i >= 1; --i) {
|
|
261
|
-
code = path2.charCodeAt(i);
|
|
262
|
-
if (code === 47) {
|
|
263
|
-
if (!matchedSlash) {
|
|
264
|
-
end = i;
|
|
265
|
-
break;
|
|
266
|
-
}
|
|
267
|
-
} else {
|
|
268
|
-
matchedSlash = false;
|
|
269
|
-
}
|
|
270
|
-
}
|
|
271
|
-
if (end === -1)
|
|
272
|
-
return hasRoot ? "/" : ".";
|
|
273
|
-
if (hasRoot && end === 1)
|
|
274
|
-
return "//";
|
|
275
|
-
return path2.slice(0, end);
|
|
276
|
-
},
|
|
277
|
-
basename: function basename(path2, ext) {
|
|
278
|
-
if (ext !== void 0 && typeof ext !== "string")
|
|
279
|
-
throw new TypeError('"ext" argument must be a string');
|
|
280
|
-
assertPath(path2);
|
|
281
|
-
var start = 0;
|
|
282
|
-
var end = -1;
|
|
283
|
-
var matchedSlash = true;
|
|
284
|
-
var i;
|
|
285
|
-
if (ext !== void 0 && ext.length > 0 && ext.length <= path2.length) {
|
|
286
|
-
if (ext.length === path2.length && ext === path2)
|
|
287
|
-
return "";
|
|
288
|
-
var extIdx = ext.length - 1;
|
|
289
|
-
var firstNonSlashEnd = -1;
|
|
290
|
-
for (i = path2.length - 1; i >= 0; --i) {
|
|
291
|
-
var code = path2.charCodeAt(i);
|
|
292
|
-
if (code === 47) {
|
|
293
|
-
if (!matchedSlash) {
|
|
294
|
-
start = i + 1;
|
|
295
|
-
break;
|
|
296
|
-
}
|
|
297
|
-
} else {
|
|
298
|
-
if (firstNonSlashEnd === -1) {
|
|
299
|
-
matchedSlash = false;
|
|
300
|
-
firstNonSlashEnd = i + 1;
|
|
301
|
-
}
|
|
302
|
-
if (extIdx >= 0) {
|
|
303
|
-
if (code === ext.charCodeAt(extIdx)) {
|
|
304
|
-
if (--extIdx === -1) {
|
|
305
|
-
end = i;
|
|
306
|
-
}
|
|
307
|
-
} else {
|
|
308
|
-
extIdx = -1;
|
|
309
|
-
end = firstNonSlashEnd;
|
|
310
|
-
}
|
|
311
|
-
}
|
|
312
|
-
}
|
|
313
|
-
}
|
|
314
|
-
if (start === end)
|
|
315
|
-
end = firstNonSlashEnd;
|
|
316
|
-
else if (end === -1)
|
|
317
|
-
end = path2.length;
|
|
318
|
-
return path2.slice(start, end);
|
|
319
|
-
} else {
|
|
320
|
-
for (i = path2.length - 1; i >= 0; --i) {
|
|
321
|
-
if (path2.charCodeAt(i) === 47) {
|
|
322
|
-
if (!matchedSlash) {
|
|
323
|
-
start = i + 1;
|
|
324
|
-
break;
|
|
325
|
-
}
|
|
326
|
-
} else if (end === -1) {
|
|
327
|
-
matchedSlash = false;
|
|
328
|
-
end = i + 1;
|
|
329
|
-
}
|
|
330
|
-
}
|
|
331
|
-
if (end === -1)
|
|
332
|
-
return "";
|
|
333
|
-
return path2.slice(start, end);
|
|
334
|
-
}
|
|
335
|
-
},
|
|
336
|
-
extname: function extname(path2) {
|
|
337
|
-
assertPath(path2);
|
|
338
|
-
var startDot = -1;
|
|
339
|
-
var startPart = 0;
|
|
340
|
-
var end = -1;
|
|
341
|
-
var matchedSlash = true;
|
|
342
|
-
var preDotState = 0;
|
|
343
|
-
for (var i = path2.length - 1; i >= 0; --i) {
|
|
344
|
-
var code = path2.charCodeAt(i);
|
|
345
|
-
if (code === 47) {
|
|
346
|
-
if (!matchedSlash) {
|
|
347
|
-
startPart = i + 1;
|
|
348
|
-
break;
|
|
349
|
-
}
|
|
350
|
-
continue;
|
|
351
|
-
}
|
|
352
|
-
if (end === -1) {
|
|
353
|
-
matchedSlash = false;
|
|
354
|
-
end = i + 1;
|
|
355
|
-
}
|
|
356
|
-
if (code === 46) {
|
|
357
|
-
if (startDot === -1)
|
|
358
|
-
startDot = i;
|
|
359
|
-
else if (preDotState !== 1)
|
|
360
|
-
preDotState = 1;
|
|
361
|
-
} else if (startDot !== -1) {
|
|
362
|
-
preDotState = -1;
|
|
363
|
-
}
|
|
364
|
-
}
|
|
365
|
-
if (startDot === -1 || end === -1 || // We saw a non-dot character immediately before the dot
|
|
366
|
-
preDotState === 0 || // The (right-most) trimmed path component is exactly '..'
|
|
367
|
-
preDotState === 1 && startDot === end - 1 && startDot === startPart + 1) {
|
|
368
|
-
return "";
|
|
369
|
-
}
|
|
370
|
-
return path2.slice(startDot, end);
|
|
371
|
-
},
|
|
372
|
-
format: function format(pathObject) {
|
|
373
|
-
if (pathObject === null || typeof pathObject !== "object") {
|
|
374
|
-
throw new TypeError('The "pathObject" argument must be of type Object. Received type ' + typeof pathObject);
|
|
375
|
-
}
|
|
376
|
-
return _format("/", pathObject);
|
|
377
|
-
},
|
|
378
|
-
parse: function parse(path2) {
|
|
379
|
-
assertPath(path2);
|
|
380
|
-
var ret = { root: "", dir: "", base: "", ext: "", name: "" };
|
|
381
|
-
if (path2.length === 0)
|
|
382
|
-
return ret;
|
|
383
|
-
var code = path2.charCodeAt(0);
|
|
384
|
-
var isAbsolute = code === 47;
|
|
385
|
-
var start;
|
|
386
|
-
if (isAbsolute) {
|
|
387
|
-
ret.root = "/";
|
|
388
|
-
start = 1;
|
|
389
|
-
} else {
|
|
390
|
-
start = 0;
|
|
391
|
-
}
|
|
392
|
-
var startDot = -1;
|
|
393
|
-
var startPart = 0;
|
|
394
|
-
var end = -1;
|
|
395
|
-
var matchedSlash = true;
|
|
396
|
-
var i = path2.length - 1;
|
|
397
|
-
var preDotState = 0;
|
|
398
|
-
for (; i >= start; --i) {
|
|
399
|
-
code = path2.charCodeAt(i);
|
|
400
|
-
if (code === 47) {
|
|
401
|
-
if (!matchedSlash) {
|
|
402
|
-
startPart = i + 1;
|
|
403
|
-
break;
|
|
404
|
-
}
|
|
405
|
-
continue;
|
|
406
|
-
}
|
|
407
|
-
if (end === -1) {
|
|
408
|
-
matchedSlash = false;
|
|
409
|
-
end = i + 1;
|
|
410
|
-
}
|
|
411
|
-
if (code === 46) {
|
|
412
|
-
if (startDot === -1)
|
|
413
|
-
startDot = i;
|
|
414
|
-
else if (preDotState !== 1)
|
|
415
|
-
preDotState = 1;
|
|
416
|
-
} else if (startDot !== -1) {
|
|
417
|
-
preDotState = -1;
|
|
418
|
-
}
|
|
419
|
-
}
|
|
420
|
-
if (startDot === -1 || end === -1 || // We saw a non-dot character immediately before the dot
|
|
421
|
-
preDotState === 0 || // The (right-most) trimmed path component is exactly '..'
|
|
422
|
-
preDotState === 1 && startDot === end - 1 && startDot === startPart + 1) {
|
|
423
|
-
if (end !== -1) {
|
|
424
|
-
if (startPart === 0 && isAbsolute)
|
|
425
|
-
ret.base = ret.name = path2.slice(1, end);
|
|
426
|
-
else
|
|
427
|
-
ret.base = ret.name = path2.slice(startPart, end);
|
|
428
|
-
}
|
|
429
|
-
} else {
|
|
430
|
-
if (startPart === 0 && isAbsolute) {
|
|
431
|
-
ret.name = path2.slice(1, startDot);
|
|
432
|
-
ret.base = path2.slice(1, end);
|
|
433
|
-
} else {
|
|
434
|
-
ret.name = path2.slice(startPart, startDot);
|
|
435
|
-
ret.base = path2.slice(startPart, end);
|
|
436
|
-
}
|
|
437
|
-
ret.ext = path2.slice(startDot, end);
|
|
438
|
-
}
|
|
439
|
-
if (startPart > 0)
|
|
440
|
-
ret.dir = path2.slice(0, startPart - 1);
|
|
441
|
-
else if (isAbsolute)
|
|
442
|
-
ret.dir = "/";
|
|
443
|
-
return ret;
|
|
444
|
-
},
|
|
445
|
-
sep: "/",
|
|
446
|
-
delimiter: ":",
|
|
447
|
-
win32: null,
|
|
448
|
-
posix: null
|
|
449
|
-
};
|
|
450
|
-
posix.posix = posix;
|
|
451
|
-
module.exports = posix;
|
|
452
|
-
}
|
|
453
|
-
});
|
|
454
|
-
|
|
455
|
-
// src/plugin/plugin-factory/plugin-factory.ts
|
|
456
|
-
var import_path_browserify = __toESM(require_path_browserify(), 1);
|
|
457
|
-
import { RuntimeError, RuntimeModelError } from "@ibiz-template/core";
|
|
458
|
-
import {
|
|
459
|
-
RemotePluginItem
|
|
460
|
-
} from "@ibiz-template/runtime";
|
|
461
|
-
var PluginFactory = class {
|
|
462
|
-
constructor() {
|
|
463
|
-
/**
|
|
464
|
-
* 是否为 http || https 开头
|
|
465
|
-
*
|
|
466
|
-
* @author chitanda
|
|
467
|
-
* @date 2022-11-07 14:11:28
|
|
468
|
-
* @protected
|
|
469
|
-
*/
|
|
470
|
-
this.urlReg = /^http[s]?:\/\/[^\s]*/;
|
|
471
|
-
/**
|
|
472
|
-
* 是否已经加载过文件缓存
|
|
473
|
-
*
|
|
474
|
-
* @author chitanda
|
|
475
|
-
* @date 2022-10-31 14:10:17
|
|
476
|
-
* @protected
|
|
477
|
-
* @type {Map<string, boolean>}
|
|
478
|
-
*/
|
|
479
|
-
this.cache = /* @__PURE__ */ new Map();
|
|
480
|
-
/**
|
|
481
|
-
* 本地开发测试包,只在本地开发生效
|
|
482
|
-
*
|
|
483
|
-
* @author chitanda
|
|
484
|
-
* @date 2022-11-02 21:11:41
|
|
485
|
-
* @protected
|
|
486
|
-
*/
|
|
487
|
-
this.devPackages = /* @__PURE__ */ new Map();
|
|
488
|
-
/**
|
|
489
|
-
* 插件缓存
|
|
490
|
-
*
|
|
491
|
-
* @author chitanda
|
|
492
|
-
* @date 2022-10-31 14:10:28
|
|
493
|
-
* @protected
|
|
494
|
-
* @type {Map<string, RemotePluginItem>}
|
|
495
|
-
*/
|
|
496
|
-
this.pluginCache = /* @__PURE__ */ new Map();
|
|
497
|
-
/**
|
|
498
|
-
* 所有的插件
|
|
499
|
-
*
|
|
500
|
-
* @author chitanda
|
|
501
|
-
* @date 2023-02-02 16:02:55
|
|
502
|
-
* @protected
|
|
503
|
-
* @type {Plugin[]}
|
|
504
|
-
*/
|
|
505
|
-
this.pluginCodes = [];
|
|
506
|
-
/**
|
|
507
|
-
* 预定义插件集合
|
|
508
|
-
*
|
|
509
|
-
* @author chitanda
|
|
510
|
-
* @date 2023-03-09 17:03:46
|
|
511
|
-
* @protected
|
|
512
|
-
* @type {Map<string, IPluginItem>}
|
|
513
|
-
*/
|
|
514
|
-
this.predefinedPlugins = /* @__PURE__ */ new Map();
|
|
515
|
-
}
|
|
516
|
-
/**
|
|
517
|
-
* 注册视图默认插件
|
|
518
|
-
*
|
|
519
|
-
* @author chitanda
|
|
520
|
-
* @date 2023-02-06 21:02:10
|
|
521
|
-
* @param {IPluginItem} plugin
|
|
522
|
-
*/
|
|
523
|
-
registerPredefinedPlugin(plugin) {
|
|
524
|
-
this.predefinedPlugins.set(plugin.name, plugin);
|
|
525
|
-
}
|
|
526
|
-
/**
|
|
527
|
-
* 给入应用实例,将已经加载的过插件注入。主要用于多实例的情况
|
|
528
|
-
*
|
|
529
|
-
* @author chitanda
|
|
530
|
-
* @date 2023-02-02 16:02:51
|
|
531
|
-
* @param {App} app
|
|
532
|
-
*/
|
|
533
|
-
register(app) {
|
|
534
|
-
this.pluginCodes.forEach((plugin) => {
|
|
535
|
-
app.use(plugin);
|
|
536
|
-
});
|
|
537
|
-
}
|
|
538
|
-
/**
|
|
539
|
-
* 加载预置插件
|
|
540
|
-
*
|
|
541
|
-
* @author chitanda
|
|
542
|
-
* @date 2023-03-09 18:03:48
|
|
543
|
-
* @param {string} name
|
|
544
|
-
* @return {*} {Promise<void>}
|
|
545
|
-
*/
|
|
546
|
-
async loadPredefinedPlugin(name) {
|
|
547
|
-
if (this.predefinedPlugins.has(name)) {
|
|
548
|
-
const plugin = this.predefinedPlugins.get(name);
|
|
549
|
-
if (plugin) {
|
|
550
|
-
await this.loadPluginRef(plugin.name, plugin.path);
|
|
551
|
-
}
|
|
552
|
-
}
|
|
553
|
-
}
|
|
554
|
-
/**
|
|
555
|
-
* 插件刚加载完成回来,设置到目前所有的 vue 实例当中
|
|
556
|
-
*
|
|
557
|
-
* @author chitanda
|
|
558
|
-
* @date 2023-02-02 17:02:38
|
|
559
|
-
* @protected
|
|
560
|
-
* @param {Plugin} code
|
|
561
|
-
*/
|
|
562
|
-
setPluginCode(code) {
|
|
563
|
-
this.pluginCodes.push(code);
|
|
564
|
-
window.vueInstances.forEach((inst) => {
|
|
565
|
-
inst.use(code);
|
|
566
|
-
});
|
|
567
|
-
}
|
|
568
|
-
/**
|
|
569
|
-
* 设置开发插件,用于本地调试
|
|
570
|
-
*
|
|
571
|
-
* @author chitanda
|
|
572
|
-
* @date 2022-11-02 21:11:56
|
|
573
|
-
* @param {string} name
|
|
574
|
-
* @param {() => Promise<unknown>} fn
|
|
575
|
-
*/
|
|
576
|
-
setDevPlugin(name, fn) {
|
|
577
|
-
this.devPackages.set(name, fn);
|
|
578
|
-
}
|
|
579
|
-
/**
|
|
580
|
-
* 加载插件
|
|
581
|
-
*
|
|
582
|
-
* @author chitanda
|
|
583
|
-
* @date 2022-10-31 14:10:13
|
|
584
|
-
* @param {ISysPFPlugin} plugin
|
|
585
|
-
* @return {*} {Promise<boolean>}
|
|
586
|
-
*/
|
|
587
|
-
async loadPlugin(plugin) {
|
|
588
|
-
if (plugin.runtimeObject === true) {
|
|
589
|
-
const pluginRef = plugin;
|
|
590
|
-
if (pluginRef) {
|
|
591
|
-
try {
|
|
592
|
-
await this.loadPluginRef(
|
|
593
|
-
pluginRef.rtobjectName,
|
|
594
|
-
pluginRef.rtobjectRepo
|
|
595
|
-
);
|
|
596
|
-
} catch (error) {
|
|
597
|
-
throw new RuntimeModelError(pluginRef, "\u914D\u7F6E\u52A0\u8F7D\u5931\u8D25");
|
|
598
|
-
}
|
|
599
|
-
}
|
|
600
|
-
}
|
|
601
|
-
return false;
|
|
602
|
-
}
|
|
603
|
-
/**
|
|
604
|
-
* 加载应用插件
|
|
605
|
-
*
|
|
606
|
-
* @author chitanda
|
|
607
|
-
* @date 2022-10-31 16:10:57
|
|
608
|
-
* @param {IPSAppPFPluginRef} pluginRef
|
|
609
|
-
* @return {*} {Promise<boolean>}
|
|
610
|
-
*/
|
|
611
|
-
async loadPluginRef(rtObjectName, rtObjectRepo) {
|
|
612
|
-
if (this.pluginCache.has(rtObjectName)) {
|
|
613
|
-
return true;
|
|
614
|
-
}
|
|
615
|
-
let configData = null;
|
|
616
|
-
const fn = this.devPackages.get(rtObjectName);
|
|
617
|
-
if (fn) {
|
|
618
|
-
configData = await fn();
|
|
619
|
-
} else {
|
|
620
|
-
const pluginPath = rtObjectRepo;
|
|
621
|
-
const configUrl = this.urlReg.test(pluginPath) ? "".concat(pluginPath, "/package.json") : "".concat(ibiz.env.pluginBaseUrl, "/").concat((0, import_path_browserify.join)(pluginPath, "package.json"));
|
|
622
|
-
const res = await ibiz.net.axios({
|
|
623
|
-
method: "get",
|
|
624
|
-
headers: { "Access-Control-Allow-Origin": "*" },
|
|
625
|
-
url: configUrl
|
|
626
|
-
});
|
|
627
|
-
if (res.status !== 200) {
|
|
628
|
-
throw new Error("\u914D\u7F6E\u52A0\u8F7D\u5931\u8D25");
|
|
629
|
-
}
|
|
630
|
-
configData = res.data;
|
|
631
|
-
}
|
|
632
|
-
const remotePlugin = new RemotePluginItem(
|
|
633
|
-
rtObjectName,
|
|
634
|
-
rtObjectRepo,
|
|
635
|
-
configData
|
|
636
|
-
);
|
|
637
|
-
if (remotePlugin) {
|
|
638
|
-
try {
|
|
639
|
-
await this.loadScript(remotePlugin);
|
|
640
|
-
this.pluginCache.set(rtObjectName, remotePlugin);
|
|
641
|
-
return true;
|
|
642
|
-
} catch (error) {
|
|
643
|
-
ibiz.log.error(error);
|
|
644
|
-
}
|
|
645
|
-
}
|
|
646
|
-
return false;
|
|
647
|
-
}
|
|
648
|
-
/**
|
|
649
|
-
* 加载插件
|
|
650
|
-
*
|
|
651
|
-
* @author chitanda
|
|
652
|
-
* @date 2022-11-02 14:11:31
|
|
653
|
-
* @protected
|
|
654
|
-
* @param {RemotePluginItem} remotePlugin
|
|
655
|
-
* @return {*} {Promise<void>}
|
|
656
|
-
*/
|
|
657
|
-
async loadScript(remotePlugin) {
|
|
658
|
-
const pluginPath = remotePlugin.repo;
|
|
659
|
-
const { name, version, system, module, styles } = remotePlugin.config;
|
|
660
|
-
let scriptUrl = "";
|
|
661
|
-
if (this.devPackages.has(name)) {
|
|
662
|
-
scriptUrl = (0, import_path_browserify.join)("".concat(name, "@").concat(version), module);
|
|
663
|
-
} else if (ibiz.env.dev) {
|
|
664
|
-
scriptUrl = this.urlReg.test(pluginPath) ? "".concat(pluginPath, "/").concat((0, import_path_browserify.join)(module)) : "".concat(ibiz.env.pluginBaseUrl, "/").concat(pluginPath, "/").concat((0, import_path_browserify.join)(module));
|
|
665
|
-
} else {
|
|
666
|
-
scriptUrl = (0, import_path_browserify.join)(pluginPath, system);
|
|
667
|
-
}
|
|
668
|
-
if (scriptUrl) {
|
|
669
|
-
if (this.cache.has(scriptUrl)) {
|
|
670
|
-
return;
|
|
671
|
-
}
|
|
672
|
-
let data = null;
|
|
673
|
-
const url = this.parseUrl(scriptUrl);
|
|
674
|
-
const styleUrls = (typeof styles === "string" ? [styles] : styles).map(
|
|
675
|
-
(styleUrl) => this.parseUrl(import_path_browserify.default.join(pluginPath, styleUrl))
|
|
676
|
-
);
|
|
677
|
-
if (this.devPackages.has(name)) {
|
|
678
|
-
const fn = this.devPackages.get(name);
|
|
679
|
-
const pluginModule = await fn();
|
|
680
|
-
this.setPluginCode(pluginModule.default);
|
|
681
|
-
this.cache.set(scriptUrl, true);
|
|
682
|
-
} else if (ibiz.env.dev) {
|
|
683
|
-
data = await import(
|
|
684
|
-
scriptUrl
|
|
685
|
-
/* @vite-ignore */
|
|
686
|
-
);
|
|
687
|
-
} else {
|
|
688
|
-
System.addImportMap({
|
|
689
|
-
imports: {
|
|
690
|
-
[name]: url
|
|
691
|
-
},
|
|
692
|
-
styles: {
|
|
693
|
-
[name]: styleUrls
|
|
694
|
-
}
|
|
695
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
696
|
-
});
|
|
697
|
-
data = await System.import(name);
|
|
698
|
-
}
|
|
699
|
-
if (data) {
|
|
700
|
-
if (data.default) {
|
|
701
|
-
this.setPluginCode(data.default);
|
|
702
|
-
} else {
|
|
703
|
-
throw new RuntimeError(
|
|
704
|
-
"\u8FDC\u7A0B\u63D2\u4EF6\u52A0\u8F7D\u5931\u8D25, \u8FDC\u7A0B\u63D2\u4EF6\u672A\u627E\u5230[default]\u9ED8\u8BA4\u5BFC\u51FA"
|
|
705
|
-
);
|
|
706
|
-
}
|
|
707
|
-
this.cache.set(scriptUrl, true);
|
|
708
|
-
} else {
|
|
709
|
-
throw new RuntimeError(
|
|
710
|
-
"\u8FDC\u7A0B\u63D2\u4EF6\u52A0\u8F7D\u5931\u8D25, \u672A\u627E\u5230\u6587\u4EF6\u6216\u6587\u4EF6\u5185\u5BB9\u683C\u5F0F\u4E0D\u6B63\u786E"
|
|
711
|
-
);
|
|
712
|
-
}
|
|
713
|
-
}
|
|
714
|
-
}
|
|
715
|
-
/**
|
|
716
|
-
* 编译请求文件地址
|
|
717
|
-
*
|
|
718
|
-
* @author chitanda
|
|
719
|
-
* @date 2022-10-31 14:10:19
|
|
720
|
-
* @protected
|
|
721
|
-
* @param {string} script
|
|
722
|
-
* @return {*} {string}
|
|
723
|
-
*/
|
|
724
|
-
parseUrl(script) {
|
|
725
|
-
if (this.urlReg.test(script)) {
|
|
726
|
-
return script;
|
|
727
|
-
}
|
|
728
|
-
let url = "";
|
|
729
|
-
if (this.urlReg.test(ibiz.env.pluginBaseUrl)) {
|
|
730
|
-
if (script.startsWith("/")) {
|
|
731
|
-
url = ibiz.env.pluginBaseUrl + script;
|
|
732
|
-
} else {
|
|
733
|
-
url = "".concat(ibiz.env.pluginBaseUrl, "/").concat(script);
|
|
734
|
-
}
|
|
735
|
-
} else {
|
|
736
|
-
url = "".concat((0, import_path_browserify.join)(ibiz.env.pluginBaseUrl, script));
|
|
737
|
-
}
|
|
738
|
-
const { origin, pathname } = window.location;
|
|
739
|
-
if (pathname.endsWith("/") && url.startsWith("/")) {
|
|
740
|
-
url = url.substring(1);
|
|
741
|
-
}
|
|
742
|
-
url = "".concat(origin).concat(pathname).concat(url);
|
|
743
|
-
return url;
|
|
744
|
-
}
|
|
745
|
-
};
|
|
746
|
-
|
|
747
|
-
// src/use/click-outside/click-outside.ts
|
|
748
|
-
import {
|
|
749
|
-
NOOP,
|
|
750
|
-
onClickOutside
|
|
751
|
-
} from "@ibiz-template/core";
|
|
752
|
-
import { isNil } from "ramda";
|
|
753
|
-
import { onBeforeUnmount, watch } from "vue";
|
|
754
|
-
function useClickOutside(elRef, handler, options = {}) {
|
|
755
|
-
let stop = NOOP;
|
|
756
|
-
let pause = NOOP;
|
|
757
|
-
let proceed = NOOP;
|
|
758
|
-
const destroy = () => {
|
|
759
|
-
stop();
|
|
760
|
-
stop = NOOP;
|
|
761
|
-
pause = NOOP;
|
|
762
|
-
proceed = NOOP;
|
|
763
|
-
};
|
|
764
|
-
watch(
|
|
765
|
-
elRef,
|
|
766
|
-
(newVal, oldVal) => {
|
|
767
|
-
if (newVal !== oldVal) {
|
|
768
|
-
if (isNil(newVal)) {
|
|
769
|
-
destroy();
|
|
770
|
-
} else {
|
|
771
|
-
const result = onClickOutside(
|
|
772
|
-
(newVal == null ? void 0 : newVal.$el) || newVal,
|
|
773
|
-
handler,
|
|
774
|
-
options
|
|
775
|
-
);
|
|
776
|
-
stop = result.stop;
|
|
777
|
-
pause = result.pause;
|
|
778
|
-
proceed = result.proceed;
|
|
779
|
-
}
|
|
780
|
-
}
|
|
781
|
-
},
|
|
782
|
-
{ immediate: true }
|
|
783
|
-
);
|
|
784
|
-
onBeforeUnmount(() => {
|
|
785
|
-
if (stop !== NOOP) {
|
|
786
|
-
destroy();
|
|
787
|
-
}
|
|
788
|
-
});
|
|
789
|
-
return {
|
|
790
|
-
stop: () => stop(),
|
|
791
|
-
pause: () => pause(),
|
|
792
|
-
proceed: () => proceed()
|
|
793
|
-
};
|
|
794
|
-
}
|
|
795
|
-
|
|
796
|
-
// src/use/control/use-control-controller/use-control-controller.ts
|
|
797
|
-
import { getCurrentInstance as getCurrentInstance2, onBeforeUnmount as onBeforeUnmount2, reactive, watch as watch3 } from "vue";
|
|
798
|
-
|
|
799
|
-
// src/use/vue/vue.ts
|
|
800
|
-
import { isFunc } from "qx-util";
|
|
801
|
-
import {
|
|
802
|
-
createCommentVNode,
|
|
803
|
-
getCurrentInstance,
|
|
804
|
-
isReactive,
|
|
805
|
-
toRaw,
|
|
806
|
-
watch as watch2
|
|
807
|
-
} from "vue";
|
|
808
|
-
function useProps() {
|
|
809
|
-
const vue = getCurrentInstance().proxy;
|
|
810
|
-
return vue.$props;
|
|
811
|
-
}
|
|
812
|
-
function getOrigin(val) {
|
|
813
|
-
return isReactive(val) ? toRaw(val) : val;
|
|
814
|
-
}
|
|
815
|
-
function usePropsWatch(key, callback, options) {
|
|
816
|
-
const props = useProps();
|
|
817
|
-
if (Object.prototype.hasOwnProperty.call(props, key)) {
|
|
818
|
-
watch2(
|
|
819
|
-
() => props[key],
|
|
820
|
-
(newVal, oldVal) => {
|
|
821
|
-
callback(getOrigin(newVal), getOrigin(oldVal));
|
|
822
|
-
},
|
|
823
|
-
options
|
|
824
|
-
);
|
|
825
|
-
callback(getOrigin(props[key]), void 0);
|
|
826
|
-
}
|
|
827
|
-
}
|
|
828
|
-
function useForce() {
|
|
829
|
-
const vue = getCurrentInstance().proxy;
|
|
830
|
-
return (callback) => {
|
|
831
|
-
vue.$forceUpdate();
|
|
832
|
-
if (callback && isFunc(callback)) {
|
|
833
|
-
vue.$nextTick(() => {
|
|
834
|
-
callback();
|
|
835
|
-
});
|
|
836
|
-
}
|
|
837
|
-
};
|
|
838
|
-
}
|
|
839
|
-
function useForceTogether(vue, controller) {
|
|
840
|
-
const orignForce = controller.force;
|
|
841
|
-
const selfForce = useForce();
|
|
842
|
-
controller.force = (callback) => {
|
|
843
|
-
orignForce(callback);
|
|
844
|
-
selfForce();
|
|
845
|
-
};
|
|
846
|
-
}
|
|
847
|
-
function useController(controller) {
|
|
848
|
-
controller.force = useForce();
|
|
849
|
-
}
|
|
850
|
-
var EmptyVNode = createCommentVNode("EmptyVNode");
|
|
851
|
-
function isEmptyVNode(nodes) {
|
|
852
|
-
if (!Array.isArray(nodes)) {
|
|
853
|
-
return nodes === EmptyVNode;
|
|
854
|
-
}
|
|
855
|
-
return nodes.length === 1 && nodes[0] === EmptyVNode;
|
|
856
|
-
}
|
|
857
|
-
|
|
858
|
-
// src/use/util/index.ts
|
|
859
|
-
import { inject } from "vue";
|
|
860
|
-
function useCtx() {
|
|
861
|
-
return inject("ctx");
|
|
862
|
-
}
|
|
863
|
-
function useMobCtx() {
|
|
864
|
-
return inject("ctx");
|
|
865
|
-
}
|
|
866
|
-
|
|
867
|
-
// src/use/control/use-control-controller/use-control-controller.ts
|
|
868
|
-
function watchAndUpdateContextParams(props, control) {
|
|
869
|
-
watch3(
|
|
870
|
-
() => ({ context: props.context, params: props.params }),
|
|
871
|
-
(newVal) => {
|
|
872
|
-
control.updateContextParams({ ...newVal });
|
|
873
|
-
ibiz.log.debug("".concat(control.model.id, "\u7684\u4E0A\u4E0B\u6587\u6216\u89C6\u56FE\u53C2\u6570\u53D8\u66F4\uFF1A"), newVal);
|
|
874
|
-
}
|
|
875
|
-
);
|
|
876
|
-
}
|
|
877
|
-
function watchAndUpdateState(props, control) {
|
|
878
|
-
const excludeKeys = ["context", "params", "modelData"];
|
|
879
|
-
watch3(
|
|
880
|
-
() => {
|
|
881
|
-
const watchProps = {};
|
|
882
|
-
Object.keys(props).forEach((key) => {
|
|
883
|
-
if (!excludeKeys.includes(key)) {
|
|
884
|
-
watchProps[key] = props[key];
|
|
885
|
-
}
|
|
886
|
-
});
|
|
887
|
-
return watchProps;
|
|
888
|
-
},
|
|
889
|
-
(newVal, oldVal) => {
|
|
890
|
-
const changeProps = {};
|
|
891
|
-
Object.keys(newVal).forEach((key) => {
|
|
892
|
-
if (newVal[key] !== (oldVal || {})[key]) {
|
|
893
|
-
changeProps[key] = newVal[key];
|
|
894
|
-
}
|
|
895
|
-
});
|
|
896
|
-
ibiz.log.debug("\u90E8\u4EF6 [".concat(control.model.name, "] state \u53D8\u66F4"), changeProps);
|
|
897
|
-
Object.keys(changeProps).forEach((key) => {
|
|
898
|
-
if (changeProps[key] !== void 0) {
|
|
899
|
-
control.state[key] = changeProps[key];
|
|
900
|
-
}
|
|
901
|
-
});
|
|
902
|
-
},
|
|
903
|
-
{ immediate: true }
|
|
904
|
-
);
|
|
905
|
-
}
|
|
906
|
-
function useControlController(fn) {
|
|
907
|
-
const ctx = useCtx();
|
|
908
|
-
const props = useProps();
|
|
909
|
-
ctx.evt.emit("onForecast", props.modelData.name);
|
|
910
|
-
const provider = props.provider;
|
|
911
|
-
let c;
|
|
912
|
-
if (provider == null ? void 0 : provider.createController) {
|
|
913
|
-
c = provider.createController(
|
|
914
|
-
props.modelData,
|
|
915
|
-
props.context,
|
|
916
|
-
props.params,
|
|
917
|
-
ctx
|
|
918
|
-
);
|
|
919
|
-
} else {
|
|
920
|
-
c = fn(props.modelData, props.context, props.params, ctx);
|
|
921
|
-
}
|
|
922
|
-
watchAndUpdateContextParams(props, c);
|
|
923
|
-
watchAndUpdateState(props, c);
|
|
924
|
-
c.state = reactive(c.state);
|
|
925
|
-
c.force = useForce();
|
|
926
|
-
const vue = getCurrentInstance2().proxy;
|
|
927
|
-
c.evt.onAll((eventName, event) => {
|
|
928
|
-
vue.$emit(eventName.slice(2), event);
|
|
929
|
-
});
|
|
930
|
-
vue.$emit("controllerAppear", c);
|
|
931
|
-
c.created();
|
|
932
|
-
onBeforeUnmount2(() => c.destroyed());
|
|
933
|
-
return c;
|
|
934
|
-
}
|
|
935
|
-
|
|
936
|
-
// src/use/event/event.ts
|
|
937
|
-
import { listenJSEvent, NOOP as NOOP2 } from "@ibiz-template/core";
|
|
938
|
-
import { isNil as isNil2 } from "ramda";
|
|
939
|
-
import { onBeforeUnmount as onBeforeUnmount3, watch as watch4 } from "vue";
|
|
940
|
-
function useEventListener(elRef, eventName, listener, options = {}) {
|
|
941
|
-
let cleanup = NOOP2;
|
|
942
|
-
watch4(
|
|
943
|
-
elRef,
|
|
944
|
-
(newVal, oldVal) => {
|
|
945
|
-
if (newVal !== oldVal) {
|
|
946
|
-
if (isNil2(newVal)) {
|
|
947
|
-
cleanup();
|
|
948
|
-
cleanup = NOOP2;
|
|
949
|
-
} else {
|
|
950
|
-
cleanup = listenJSEvent(
|
|
951
|
-
(newVal == null ? void 0 : newVal.$el) || newVal,
|
|
952
|
-
eventName,
|
|
953
|
-
listener,
|
|
954
|
-
options
|
|
955
|
-
);
|
|
956
|
-
}
|
|
957
|
-
}
|
|
958
|
-
},
|
|
959
|
-
{ immediate: true }
|
|
960
|
-
);
|
|
961
|
-
onBeforeUnmount3(() => {
|
|
962
|
-
if (cleanup !== NOOP2) {
|
|
963
|
-
cleanup();
|
|
964
|
-
}
|
|
965
|
-
});
|
|
966
|
-
return () => {
|
|
967
|
-
cleanup();
|
|
968
|
-
};
|
|
969
|
-
}
|
|
970
|
-
|
|
971
|
-
// src/use/focus-blur/focus-blur.ts
|
|
972
|
-
import { ref } from "vue";
|
|
973
|
-
function useFocusAndBlur(focus, blur) {
|
|
974
|
-
const componentRef = ref();
|
|
975
|
-
const isFocus = ref(false);
|
|
976
|
-
let outsideFuns;
|
|
977
|
-
const doBlur = () => {
|
|
978
|
-
if (!isFocus.value) {
|
|
979
|
-
ibiz.log.debug("\u6CA1\u6709\u805A\u7126\uFF0C\u4E0D\u89E6\u53D1\u5931\u7126");
|
|
980
|
-
}
|
|
981
|
-
blur();
|
|
982
|
-
outsideFuns.stop();
|
|
983
|
-
isFocus.value = false;
|
|
984
|
-
};
|
|
985
|
-
const pause = () => {
|
|
986
|
-
if (outsideFuns) {
|
|
987
|
-
outsideFuns.pause();
|
|
988
|
-
}
|
|
989
|
-
};
|
|
990
|
-
const stop = () => {
|
|
991
|
-
if (outsideFuns) {
|
|
992
|
-
outsideFuns.stop();
|
|
993
|
-
}
|
|
994
|
-
};
|
|
995
|
-
useEventListener(
|
|
996
|
-
componentRef,
|
|
997
|
-
"click",
|
|
998
|
-
(_evt) => {
|
|
999
|
-
if (!isFocus.value) {
|
|
1000
|
-
outsideFuns = useClickOutside(componentRef, () => {
|
|
1001
|
-
doBlur();
|
|
1002
|
-
});
|
|
1003
|
-
isFocus.value = true;
|
|
1004
|
-
focus();
|
|
1005
|
-
}
|
|
1006
|
-
},
|
|
1007
|
-
{ capture: true }
|
|
1008
|
-
// 捕获防止内部ui拦截点击事件
|
|
1009
|
-
);
|
|
1010
|
-
return { componentRef, isFocus, doBlur, pause, stop };
|
|
1011
|
-
}
|
|
1012
|
-
|
|
1013
|
-
// src/use/namespace/namespace.ts
|
|
1014
|
-
import { Namespace } from "@ibiz-template/core";
|
|
1015
|
-
function useNamespace(block) {
|
|
1016
|
-
return new Namespace(block, ibiz.env.namespace);
|
|
1017
|
-
}
|
|
1018
|
-
|
|
1019
|
-
// src/use/route/route.ts
|
|
1020
|
-
import { useRoute as useRoute2 } from "vue-router";
|
|
1021
|
-
import { ref as ref2, watch as watch7 } from "vue";
|
|
1022
|
-
|
|
1023
|
-
// src/util/route/route.ts
|
|
1024
|
-
import { notNilEmpty } from "qx-util";
|
|
1025
|
-
import { RuntimeError as RuntimeError2 } from "@ibiz-template/core";
|
|
1026
|
-
import qs from "qs";
|
|
1027
|
-
import { useRoute } from "vue-router";
|
|
1028
|
-
import { watch as watch5 } from "vue";
|
|
1029
|
-
import {
|
|
1030
|
-
calcDeCodeNameById,
|
|
1031
|
-
getMatchResPath,
|
|
1032
|
-
ViewType
|
|
1033
|
-
} from "@ibiz-template/runtime";
|
|
1034
|
-
function getOwnRouteContext(context) {
|
|
1035
|
-
const ownContext = context.getOwnContext();
|
|
1036
|
-
const excludeKeys = ["srfsessionid", "srfappid"];
|
|
1037
|
-
Object.keys(ownContext).forEach((key) => {
|
|
1038
|
-
if (excludeKeys.includes(key)) {
|
|
1039
|
-
delete ownContext[key];
|
|
1040
|
-
}
|
|
1041
|
-
});
|
|
1042
|
-
return ownContext;
|
|
1043
|
-
}
|
|
1044
|
-
var excludeViewTypes = [
|
|
1045
|
-
ViewType.DE_GRID_VIEW,
|
|
1046
|
-
ViewType.DE_GRID_EXP_VIEW,
|
|
1047
|
-
ViewType.DE_LIST_VIEW,
|
|
1048
|
-
ViewType.DE_LIST_EXP_VIEW,
|
|
1049
|
-
ViewType.DE_DATA_VIEW,
|
|
1050
|
-
ViewType.DE_DATAVIEW_EXP_VIEW,
|
|
1051
|
-
ViewType.DE_CALENDAR_VIEW,
|
|
1052
|
-
ViewType.DE_CALENDAR_EXP_VIEW,
|
|
1053
|
-
ViewType.DE_CHART_VIEW,
|
|
1054
|
-
ViewType.DE_CHART_EXP_VIEW,
|
|
1055
|
-
ViewType.DE_KANBAN_VIEW
|
|
1056
|
-
];
|
|
1057
|
-
async function calcResRoutePath(routePath, context, appDataEntityId) {
|
|
1058
|
-
if (!appDataEntityId) {
|
|
1059
|
-
routePath.pathNodes[0].context = void 0;
|
|
1060
|
-
} else {
|
|
1061
|
-
const entity = await ibiz.hub.getAppDataEntity(appDataEntityId);
|
|
1062
|
-
let match = getMatchResPath(context, entity);
|
|
1063
|
-
if (!match) {
|
|
1064
|
-
match = { path: "", keys: [entity.codeName.toLowerCase()] };
|
|
1065
|
-
}
|
|
1066
|
-
if (match) {
|
|
1067
|
-
const currentContext = routePath.pathNodes[1].context;
|
|
1068
|
-
const resContext = {};
|
|
1069
|
-
match.keys.forEach((key) => {
|
|
1070
|
-
if (context && Object.prototype.hasOwnProperty.call(context, key)) {
|
|
1071
|
-
resContext[key] = context[key];
|
|
1072
|
-
if (currentContext) {
|
|
1073
|
-
delete currentContext[key];
|
|
1074
|
-
}
|
|
1075
|
-
}
|
|
1076
|
-
});
|
|
1077
|
-
routePath.pathNodes[0].context = resContext;
|
|
1078
|
-
}
|
|
1079
|
-
}
|
|
1080
|
-
}
|
|
1081
|
-
async function generateRoutePath(appView, route, context, params) {
|
|
1082
|
-
const routePath = route2routePath(route);
|
|
1083
|
-
let depth = 2;
|
|
1084
|
-
if (context.toRouteDepth) {
|
|
1085
|
-
depth = context.toRouteDepth;
|
|
1086
|
-
delete context.toRouteDepth;
|
|
1087
|
-
} else if (ibiz.env.isMob) {
|
|
1088
|
-
routePath.pathNodes[0] = {
|
|
1089
|
-
viewName: "home"
|
|
1090
|
-
};
|
|
1091
|
-
}
|
|
1092
|
-
routePath.pathNodes.splice(depth - 1, routePath.pathNodes.length - depth + 1);
|
|
1093
|
-
if (context.currentSrfNav) {
|
|
1094
|
-
const currentNode = routePath.pathNodes[routePath.pathNodes.length - 1];
|
|
1095
|
-
currentNode.params = currentNode.params || {};
|
|
1096
|
-
currentNode.srfnav = context.currentSrfNav;
|
|
1097
|
-
delete context.currentSrfNav;
|
|
1098
|
-
}
|
|
1099
|
-
if (route.fullPath.startsWith("/appredirectview")) {
|
|
1100
|
-
if (params == null ? void 0 : params.srfindexname) {
|
|
1101
|
-
routePath.pathNodes[0].viewName = params.srfindexname;
|
|
1102
|
-
delete params.srfindexname;
|
|
1103
|
-
} else {
|
|
1104
|
-
routePath.pathNodes[0].viewName = "index";
|
|
1105
|
-
}
|
|
1106
|
-
}
|
|
1107
|
-
routePath.pathNodes.push({
|
|
1108
|
-
viewName: appView.codeName.toLowerCase(),
|
|
1109
|
-
context: getOwnRouteContext(context),
|
|
1110
|
-
params
|
|
1111
|
-
});
|
|
1112
|
-
if (depth === 2) {
|
|
1113
|
-
await calcResRoutePath(routePath, context, appView.appDataEntityId);
|
|
1114
|
-
if (excludeViewTypes.includes(appView.viewType)) {
|
|
1115
|
-
const deName = calcDeCodeNameById(appView.appDataEntityId);
|
|
1116
|
-
delete routePath.pathNodes[0].context[deName];
|
|
1117
|
-
}
|
|
1118
|
-
}
|
|
1119
|
-
return { path: routePath2string(routePath) };
|
|
1120
|
-
}
|
|
1121
|
-
async function parseRouteViewData(route, depth) {
|
|
1122
|
-
var _a;
|
|
1123
|
-
const routePath = route2routePath(route);
|
|
1124
|
-
let viewCodeName = routePath.pathNodes[depth - 1].viewName;
|
|
1125
|
-
if (!viewCodeName) {
|
|
1126
|
-
throw new RuntimeError2("\u7B2C".concat(depth, "\u7EA7\u8DEF\u7531\u4E0D\u5B58\u5728\u89C6\u56FE\u6807\u8BC6"));
|
|
1127
|
-
}
|
|
1128
|
-
if (viewCodeName === "index") {
|
|
1129
|
-
viewCodeName = ibiz.hub.defaultAppIndexViewName;
|
|
1130
|
-
}
|
|
1131
|
-
const viewModel = await ibiz.hub.getAppView(viewCodeName);
|
|
1132
|
-
if (!viewModel) {
|
|
1133
|
-
throw new RuntimeError2("\u627E\u4E0D\u5230\u89C6\u56FE".concat(viewCodeName));
|
|
1134
|
-
}
|
|
1135
|
-
const context = {};
|
|
1136
|
-
if ((_a = ibiz.appData) == null ? void 0 : _a.context) {
|
|
1137
|
-
Object.assign(context, ibiz.appData.context);
|
|
1138
|
-
}
|
|
1139
|
-
if (routePath.appContext) {
|
|
1140
|
-
Object.assign(context, routePath.appContext);
|
|
1141
|
-
}
|
|
1142
|
-
if (depth !== 1) {
|
|
1143
|
-
for (let index = 0; index < depth; index++) {
|
|
1144
|
-
const pathNode = routePath.pathNodes[index];
|
|
1145
|
-
if (notNilEmpty(pathNode.context)) {
|
|
1146
|
-
Object.assign(context, pathNode.context);
|
|
1147
|
-
}
|
|
1148
|
-
}
|
|
1149
|
-
}
|
|
1150
|
-
const { params, srfnav } = routePath.pathNodes[depth - 1];
|
|
1151
|
-
return {
|
|
1152
|
-
viewModel,
|
|
1153
|
-
context,
|
|
1154
|
-
params,
|
|
1155
|
-
srfnav
|
|
1156
|
-
};
|
|
1157
|
-
}
|
|
1158
|
-
function route2routePath(route) {
|
|
1159
|
-
const depth = route.matched.length;
|
|
1160
|
-
const pathNodes = [];
|
|
1161
|
-
for (let index = 1; index <= depth; index++) {
|
|
1162
|
-
const viewName = route.path.split("/")[index * 2];
|
|
1163
|
-
const paramsStr = route.params["params".concat(index)];
|
|
1164
|
-
let params;
|
|
1165
|
-
let context;
|
|
1166
|
-
let srfnav;
|
|
1167
|
-
if (!paramsStr || paramsStr === ibiz.env.routePlaceholder) {
|
|
1168
|
-
params = void 0;
|
|
1169
|
-
} else {
|
|
1170
|
-
params = qs.parse(paramsStr, {
|
|
1171
|
-
strictNullHandling: true,
|
|
1172
|
-
delimiter: ";"
|
|
1173
|
-
});
|
|
1174
|
-
}
|
|
1175
|
-
if (params) {
|
|
1176
|
-
if (index === 1) {
|
|
1177
|
-
context = params;
|
|
1178
|
-
params = void 0;
|
|
1179
|
-
} else {
|
|
1180
|
-
if (params.srfnavctx) {
|
|
1181
|
-
context = JSON.parse(decodeURIComponent(params.srfnavctx));
|
|
1182
|
-
delete params.srfnavctx;
|
|
1183
|
-
}
|
|
1184
|
-
if (params.srfnav) {
|
|
1185
|
-
srfnav = params.srfnav;
|
|
1186
|
-
delete params.srfnav;
|
|
1187
|
-
}
|
|
1188
|
-
}
|
|
1189
|
-
}
|
|
1190
|
-
pathNodes.push({ viewName, context, params, srfnav });
|
|
1191
|
-
}
|
|
1192
|
-
let appContext;
|
|
1193
|
-
if (route.params.appContext && route.params.appContext !== ibiz.env.routePlaceholder) {
|
|
1194
|
-
appContext = qs.parse(route.params.appContext, {
|
|
1195
|
-
strictNullHandling: true,
|
|
1196
|
-
delimiter: ";"
|
|
1197
|
-
});
|
|
1198
|
-
}
|
|
1199
|
-
return { appContext, pathNodes };
|
|
1200
|
-
}
|
|
1201
|
-
function routePath2string(routePath) {
|
|
1202
|
-
let pathStr = "";
|
|
1203
|
-
if (routePath.appContext) {
|
|
1204
|
-
pathStr += "/".concat(qs.stringify(routePath.appContext, {
|
|
1205
|
-
delimiter: ";",
|
|
1206
|
-
strictNullHandling: true
|
|
1207
|
-
}));
|
|
1208
|
-
} else {
|
|
1209
|
-
pathStr += "/".concat(ibiz.env.routePlaceholder);
|
|
1210
|
-
}
|
|
1211
|
-
routePath.pathNodes.forEach((pathNode, index) => {
|
|
1212
|
-
pathStr += "/".concat(pathNode.viewName, "/");
|
|
1213
|
-
let routeParams = {};
|
|
1214
|
-
if (index === 0) {
|
|
1215
|
-
if (notNilEmpty(pathNode.context)) {
|
|
1216
|
-
routeParams = pathNode.context;
|
|
1217
|
-
}
|
|
1218
|
-
} else {
|
|
1219
|
-
routeParams = notNilEmpty(pathNode.params) ? pathNode.params : {};
|
|
1220
|
-
if (notNilEmpty(pathNode.context)) {
|
|
1221
|
-
const objStr = JSON.stringify(pathNode.context);
|
|
1222
|
-
if (objStr !== "{}") {
|
|
1223
|
-
routeParams.srfnavctx = encodeURIComponent(objStr);
|
|
1224
|
-
}
|
|
1225
|
-
}
|
|
1226
|
-
if (pathNode.srfnav) {
|
|
1227
|
-
routeParams.srfnav = pathNode.srfnav;
|
|
1228
|
-
}
|
|
1229
|
-
}
|
|
1230
|
-
const paramsStr = qs.stringify(routeParams, {
|
|
1231
|
-
delimiter: ";",
|
|
1232
|
-
strictNullHandling: true,
|
|
1233
|
-
skipNulls: true
|
|
1234
|
-
});
|
|
1235
|
-
if (notNilEmpty(paramsStr)) {
|
|
1236
|
-
pathStr += paramsStr;
|
|
1237
|
-
} else {
|
|
1238
|
-
pathStr += ibiz.env.routePlaceholder;
|
|
1239
|
-
}
|
|
1240
|
-
});
|
|
1241
|
-
return pathStr;
|
|
1242
|
-
}
|
|
1243
|
-
function getNestedRoutePath(route, depth, noSrfNav = true) {
|
|
1244
|
-
if (route.matched.length < depth) {
|
|
1245
|
-
return "";
|
|
1246
|
-
}
|
|
1247
|
-
if (route.name) {
|
|
1248
|
-
return route.path;
|
|
1249
|
-
}
|
|
1250
|
-
const routePath = route2routePath(route);
|
|
1251
|
-
if (routePath.pathNodes.length < depth) {
|
|
1252
|
-
return route.path;
|
|
1253
|
-
}
|
|
1254
|
-
if (routePath.pathNodes.length > depth) {
|
|
1255
|
-
routePath.pathNodes = routePath.pathNodes.slice(0, depth);
|
|
1256
|
-
}
|
|
1257
|
-
if (noSrfNav) {
|
|
1258
|
-
delete routePath.pathNodes[depth - 1].srfnav;
|
|
1259
|
-
}
|
|
1260
|
-
return routePath2string(routePath);
|
|
1261
|
-
}
|
|
1262
|
-
function onRouteChange(callback, depth) {
|
|
1263
|
-
const route = useRoute();
|
|
1264
|
-
if (!route) {
|
|
1265
|
-
throw new RuntimeError2("\u65E0\u6CD5\u6B63\u786E\u83B7\u53D6route,\u53EF\u80FD\u662F\u4F9D\u8D56\u95EE\u9898");
|
|
1266
|
-
}
|
|
1267
|
-
watch5(
|
|
1268
|
-
() => route == null ? void 0 : route.path,
|
|
1269
|
-
() => {
|
|
1270
|
-
const currentKey = getNestedRoutePath(route, depth);
|
|
1271
|
-
callback({ currentKey, fullPath: route.fullPath });
|
|
1272
|
-
},
|
|
1273
|
-
{ immediate: true }
|
|
1274
|
-
);
|
|
1275
|
-
}
|
|
1276
|
-
|
|
1277
|
-
// src/util/route/route-listener.ts
|
|
1278
|
-
import { watch as watch6 } from "vue";
|
|
1279
|
-
var RouteListener = class {
|
|
1280
|
-
constructor(route, wait) {
|
|
1281
|
-
/**
|
|
1282
|
-
* 回调集合
|
|
1283
|
-
*
|
|
1284
|
-
* @memberof RouteListener
|
|
1285
|
-
*/
|
|
1286
|
-
this.callbacks = [];
|
|
1287
|
-
/**
|
|
1288
|
-
* 计时器集合
|
|
1289
|
-
*
|
|
1290
|
-
* @private
|
|
1291
|
-
* @type {any[]}
|
|
1292
|
-
* @memberof RouteListener
|
|
1293
|
-
*/
|
|
1294
|
-
this.timers = [];
|
|
1295
|
-
/**
|
|
1296
|
-
* 等待路由响应时间
|
|
1297
|
-
*
|
|
1298
|
-
* @private
|
|
1299
|
-
* @type {number}
|
|
1300
|
-
* @memberof RouteListener
|
|
1301
|
-
*/
|
|
1302
|
-
this.wait = 500;
|
|
1303
|
-
if (wait) {
|
|
1304
|
-
this.wait = wait;
|
|
1305
|
-
}
|
|
1306
|
-
watch6(
|
|
1307
|
-
() => route.path,
|
|
1308
|
-
(newVal, oldVal) => {
|
|
1309
|
-
if (newVal !== oldVal) {
|
|
1310
|
-
if (this.callbacks.length) {
|
|
1311
|
-
for (let index = 0; index < this.callbacks.length; index++) {
|
|
1312
|
-
const fn = this.callbacks[index];
|
|
1313
|
-
fn();
|
|
1314
|
-
}
|
|
1315
|
-
}
|
|
1316
|
-
this.callbacks = [];
|
|
1317
|
-
if (this.timers.length) {
|
|
1318
|
-
for (let index = 0; index < this.timers.length; index++) {
|
|
1319
|
-
const timer = this.timers[index];
|
|
1320
|
-
clearTimeout(timer);
|
|
1321
|
-
}
|
|
1322
|
-
}
|
|
1323
|
-
this.timers = [];
|
|
1324
|
-
}
|
|
1325
|
-
}
|
|
1326
|
-
);
|
|
1327
|
-
}
|
|
1328
|
-
/**
|
|
1329
|
-
* 下一次路由变更后执行回调,只执行一次
|
|
1330
|
-
*
|
|
1331
|
-
* @param {ChangeCallback} callback
|
|
1332
|
-
* @memberof RouteListener
|
|
1333
|
-
*/
|
|
1334
|
-
nextChange(callback) {
|
|
1335
|
-
if (callback) {
|
|
1336
|
-
this.timers.push(
|
|
1337
|
-
setTimeout(() => {
|
|
1338
|
-
callback();
|
|
1339
|
-
const index = this.callbacks.findIndex((item) => item === callback);
|
|
1340
|
-
this.callbacks.splice(index, 1);
|
|
1341
|
-
}, this.wait)
|
|
1342
|
-
);
|
|
1343
|
-
this.callbacks.push(callback);
|
|
1344
|
-
}
|
|
1345
|
-
}
|
|
1346
|
-
};
|
|
1347
|
-
|
|
1348
|
-
// src/util/install.ts
|
|
1349
|
-
var withInstall = (main, install) => {
|
|
1350
|
-
main.install = (app) => {
|
|
1351
|
-
install(app);
|
|
1352
|
-
};
|
|
1353
|
-
return main;
|
|
1354
|
-
};
|
|
1355
|
-
|
|
1356
|
-
// src/util/control/prepare-control.ts
|
|
1357
|
-
function prepareControl(c) {
|
|
1358
|
-
const commonNs = useNamespace("control");
|
|
1359
|
-
const { controlType, sysCss, codeName } = c.model;
|
|
1360
|
-
const typeClass = controlType.toLowerCase();
|
|
1361
|
-
const sysCssName = sysCss == null ? void 0 : sysCss.cssName;
|
|
1362
|
-
const ns = useNamespace("control-".concat(typeClass));
|
|
1363
|
-
const controlClass = [
|
|
1364
|
-
commonNs.b(),
|
|
1365
|
-
commonNs.b(typeClass),
|
|
1366
|
-
commonNs.m(codeName)
|
|
1367
|
-
];
|
|
1368
|
-
if (sysCssName) {
|
|
1369
|
-
controlClass.push(sysCssName);
|
|
1370
|
-
}
|
|
1371
|
-
return { controlClass, ns };
|
|
1372
|
-
}
|
|
1373
|
-
|
|
1374
|
-
// src/util/render/render.ts
|
|
1375
|
-
import { isNil as isNil3 } from "ramda";
|
|
1376
|
-
function renderString(value) {
|
|
1377
|
-
if (isNil3(value)) {
|
|
1378
|
-
return "";
|
|
1379
|
-
}
|
|
1380
|
-
if (typeof value === "string") {
|
|
1381
|
-
return value;
|
|
1382
|
-
}
|
|
1383
|
-
try {
|
|
1384
|
-
const str = value.toString();
|
|
1385
|
-
return str;
|
|
1386
|
-
} catch (error) {
|
|
1387
|
-
ibiz.log.error(value, "\u8F6C\u6362\u6210\u5B57\u7B26\u4E32\u5931\u8D25", error);
|
|
1388
|
-
}
|
|
1389
|
-
return "";
|
|
1390
|
-
}
|
|
1391
|
-
|
|
1392
|
-
// src/use/route/route.ts
|
|
1393
|
-
function useRouterQuery() {
|
|
1394
|
-
const route = useRoute2();
|
|
1395
|
-
const { query } = route;
|
|
1396
|
-
return query;
|
|
1397
|
-
}
|
|
1398
|
-
function useRouteKey(originKey, route, routeKey) {
|
|
1399
|
-
if (!routeKey) {
|
|
1400
|
-
routeKey = ref2("");
|
|
1401
|
-
}
|
|
1402
|
-
routeKey.value = originKey.value;
|
|
1403
|
-
const routeListener = new RouteListener(route);
|
|
1404
|
-
watch7(originKey, (newVal, oldVal) => {
|
|
1405
|
-
if (newVal !== oldVal) {
|
|
1406
|
-
routeListener.nextChange(() => {
|
|
1407
|
-
routeKey.value = newVal;
|
|
1408
|
-
});
|
|
1409
|
-
}
|
|
1410
|
-
});
|
|
1411
|
-
return routeKey;
|
|
1412
|
-
}
|
|
1413
|
-
|
|
1414
|
-
// src/use/view/use-view-controller/use-view-controller.ts
|
|
1415
|
-
import { clearAll } from "qx-util";
|
|
1416
|
-
import {
|
|
1417
|
-
getCurrentInstance as getCurrentInstance3,
|
|
1418
|
-
inject as inject2,
|
|
1419
|
-
onBeforeUnmount as onBeforeUnmount4,
|
|
1420
|
-
provide,
|
|
1421
|
-
reactive as reactive2,
|
|
1422
|
-
watch as watch8
|
|
1423
|
-
} from "vue";
|
|
1424
|
-
function watchAndUpdateContextParams2(props, view) {
|
|
1425
|
-
watch8(
|
|
1426
|
-
() => ({ context: props.context, params: props.params }),
|
|
1427
|
-
(newVal) => {
|
|
1428
|
-
view.context.reset({}, newVal.context);
|
|
1429
|
-
clearAll(view.params);
|
|
1430
|
-
Object.assign(view.params, newVal.params);
|
|
1431
|
-
view.handleContextParams();
|
|
1432
|
-
ibiz.log.debug("".concat(view.model.id, "\u7684\u4E0A\u4E0B\u6587\u6216\u89C6\u56FE\u53C2\u6570\u53D8\u66F4\uFF1A"), newVal);
|
|
1433
|
-
}
|
|
1434
|
-
);
|
|
1435
|
-
}
|
|
1436
|
-
function watchAndUpdateState2(props, view) {
|
|
1437
|
-
watch8(
|
|
1438
|
-
() => {
|
|
1439
|
-
return props.state ? { ...props.state } : {};
|
|
1440
|
-
},
|
|
1441
|
-
(newVal, oldVal) => {
|
|
1442
|
-
const changeProps = {};
|
|
1443
|
-
Object.keys(newVal).forEach((key) => {
|
|
1444
|
-
if (newVal[key] !== (oldVal || {})[key]) {
|
|
1445
|
-
changeProps[key] = newVal[key];
|
|
1446
|
-
}
|
|
1447
|
-
});
|
|
1448
|
-
ibiz.log.debug("\u89C6\u56FE [".concat(view.model.name, "] state \u53D8\u66F4"), changeProps);
|
|
1449
|
-
Object.keys(changeProps).forEach((key) => {
|
|
1450
|
-
view.state[key] = changeProps[key];
|
|
1451
|
-
});
|
|
1452
|
-
},
|
|
1453
|
-
{ immediate: true }
|
|
1454
|
-
);
|
|
1455
|
-
}
|
|
1456
|
-
function useViewController(fn) {
|
|
1457
|
-
const props = useProps();
|
|
1458
|
-
const ctx = inject2("ctx", void 0);
|
|
1459
|
-
ctx == null ? void 0 : ctx.evt.emit("onForecast", props.modelData.name);
|
|
1460
|
-
const provider = props.provider;
|
|
1461
|
-
let c;
|
|
1462
|
-
if (provider == null ? void 0 : provider.createController) {
|
|
1463
|
-
c = provider.createController(
|
|
1464
|
-
props.modelData,
|
|
1465
|
-
props.context,
|
|
1466
|
-
props.params,
|
|
1467
|
-
ctx
|
|
1468
|
-
);
|
|
1469
|
-
} else {
|
|
1470
|
-
c = fn(props.modelData, props.context, props.params, ctx);
|
|
1471
|
-
}
|
|
1472
|
-
watchAndUpdateContextParams2(props, c);
|
|
1473
|
-
watchAndUpdateState2(props, c);
|
|
1474
|
-
provide("ctx", c.ctx);
|
|
1475
|
-
c.state = reactive2(c.state);
|
|
1476
|
-
c.slotProps = reactive2(c.slotProps);
|
|
1477
|
-
if (props.modal) {
|
|
1478
|
-
c.modal = props.modal;
|
|
1479
|
-
}
|
|
1480
|
-
c.force = useForce();
|
|
1481
|
-
const vue = getCurrentInstance3().proxy;
|
|
1482
|
-
c.evt.onAll((eventName, event) => {
|
|
1483
|
-
vue.$emit(eventName.slice(2), event);
|
|
1484
|
-
});
|
|
1485
|
-
c.created();
|
|
1486
|
-
onBeforeUnmount4(() => c.destroyed());
|
|
1487
|
-
return c;
|
|
1488
|
-
}
|
|
1489
|
-
|
|
1490
|
-
// src/props/common.ts
|
|
1491
|
-
var RequiredProp = class {
|
|
1492
|
-
constructor(type, _default, validator) {
|
|
1493
|
-
this.required = true;
|
|
1494
|
-
if (_default) {
|
|
1495
|
-
this.default = _default;
|
|
1496
|
-
}
|
|
1497
|
-
if (validator) {
|
|
1498
|
-
this.validator = validator;
|
|
1499
|
-
}
|
|
1500
|
-
this.type = type;
|
|
1501
|
-
}
|
|
1502
|
-
};
|
|
1503
|
-
|
|
1504
|
-
// src/props/editor/common.ts
|
|
1505
|
-
function getEditorProps() {
|
|
1506
|
-
return {
|
|
1507
|
-
value: String,
|
|
1508
|
-
controller: new RequiredProp(Object),
|
|
1509
|
-
data: new RequiredProp(Object),
|
|
1510
|
-
disabled: {
|
|
1511
|
-
type: Boolean
|
|
1512
|
-
},
|
|
1513
|
-
readonly: {
|
|
1514
|
-
type: Boolean,
|
|
1515
|
-
default: false
|
|
1516
|
-
},
|
|
1517
|
-
autoFocus: {
|
|
1518
|
-
type: Boolean,
|
|
1519
|
-
default: false
|
|
1520
|
-
}
|
|
1521
|
-
};
|
|
1522
|
-
}
|
|
1523
|
-
function getEditorEmits() {
|
|
1524
|
-
return {
|
|
1525
|
-
/** 值变更事件 */
|
|
1526
|
-
change: (_value, _name) => true,
|
|
1527
|
-
/** 失焦事件 */
|
|
1528
|
-
blur: () => true,
|
|
1529
|
-
/** 聚焦事件 */
|
|
1530
|
-
focus: () => true
|
|
1531
|
-
};
|
|
1532
|
-
}
|
|
1533
|
-
function getGridEditorEmits() {
|
|
1534
|
-
return {
|
|
1535
|
-
/** 值变更事件 */
|
|
1536
|
-
change: (_value, _name) => true,
|
|
1537
|
-
/** 是否正在操作事件 */
|
|
1538
|
-
rowSave: () => true
|
|
1539
|
-
};
|
|
1540
|
-
}
|
|
1541
|
-
function getGridEditorCommonProps() {
|
|
1542
|
-
return {
|
|
1543
|
-
hasError: {
|
|
1544
|
-
type: Boolean
|
|
1545
|
-
}
|
|
1546
|
-
};
|
|
1547
|
-
}
|
|
1548
|
-
|
|
1549
|
-
// src/props/editor/text-box.ts
|
|
1550
|
-
function getInputProps() {
|
|
1551
|
-
return { ...getEditorProps(), value: [String, Number] };
|
|
1552
|
-
}
|
|
1553
|
-
function getGridInputProps() {
|
|
1554
|
-
return { ...getInputProps(), ...getGridEditorCommonProps() };
|
|
1555
|
-
}
|
|
1556
|
-
function getInputNumberProps() {
|
|
1557
|
-
return { ...getEditorProps(), value: Number };
|
|
1558
|
-
}
|
|
1559
|
-
function getGridInputNumberProps() {
|
|
1560
|
-
return { ...getInputNumberProps(), ...getGridEditorCommonProps() };
|
|
1561
|
-
}
|
|
1562
|
-
function getInputIpProps() {
|
|
1563
|
-
return { ...getEditorProps(), value: String };
|
|
1564
|
-
}
|
|
1565
|
-
function getGridInputIpProps() {
|
|
1566
|
-
return { ...getInputIpProps(), ...getGridEditorCommonProps() };
|
|
1567
|
-
}
|
|
1568
|
-
|
|
1569
|
-
// src/props/editor/span.ts
|
|
1570
|
-
function getSpanProps() {
|
|
1571
|
-
return { ...getEditorProps(), value: [String, Number] };
|
|
1572
|
-
}
|
|
1573
|
-
function getGridSpanProps() {
|
|
1574
|
-
return { ...getSpanProps(), ...getGridEditorCommonProps() };
|
|
1575
|
-
}
|
|
1576
|
-
|
|
1577
|
-
// src/props/editor/dropdown-list.ts
|
|
1578
|
-
function getDropdownProps() {
|
|
1579
|
-
return { ...getEditorProps(), value: [String, Number] };
|
|
1580
|
-
}
|
|
1581
|
-
function getGridDropdownProps() {
|
|
1582
|
-
return { ...getDropdownProps(), ...getGridEditorCommonProps() };
|
|
1583
|
-
}
|
|
1584
|
-
|
|
1585
|
-
// src/props/editor/check-box-list.ts
|
|
1586
|
-
function getCheckboxListProps() {
|
|
1587
|
-
return { ...getEditorProps(), value: [String, Number] };
|
|
1588
|
-
}
|
|
1589
|
-
function getGridCheckboxListProps() {
|
|
1590
|
-
return { ...getCheckboxListProps(), ...getGridEditorCommonProps() };
|
|
1591
|
-
}
|
|
1592
|
-
|
|
1593
|
-
// src/props/editor/check-box.ts
|
|
1594
|
-
function getCheckboxProps() {
|
|
1595
|
-
return { ...getEditorProps(), value: [String, Number] };
|
|
1596
|
-
}
|
|
1597
|
-
function getGridCheckboxProps() {
|
|
1598
|
-
return { ...getCheckboxProps(), ...getGridEditorCommonProps() };
|
|
1599
|
-
}
|
|
1600
|
-
|
|
1601
|
-
// src/props/editor/data-picker.ts
|
|
1602
|
-
function getDataPickerProps() {
|
|
1603
|
-
return { ...getEditorProps(), value: [String, Array, Object, Number] };
|
|
1604
|
-
}
|
|
1605
|
-
function getGridDataPickerProps() {
|
|
1606
|
-
return { ...getDataPickerProps(), ...getGridEditorCommonProps() };
|
|
1607
|
-
}
|
|
1608
|
-
|
|
1609
|
-
// src/props/editor/date-picker.ts
|
|
1610
|
-
function getDatePickerProps() {
|
|
1611
|
-
return { ...getEditorProps(), value: [String, Number] };
|
|
1612
|
-
}
|
|
1613
|
-
function getGridDatePickerProps() {
|
|
1614
|
-
return { ...getDatePickerProps(), ...getGridEditorCommonProps() };
|
|
1615
|
-
}
|
|
1616
|
-
|
|
1617
|
-
// src/props/editor/date-range.ts
|
|
1618
|
-
function getDateRangeProps() {
|
|
1619
|
-
return { ...getEditorProps(), value: [String, Number] };
|
|
1620
|
-
}
|
|
1621
|
-
function getGridDateRangeProps() {
|
|
1622
|
-
return { ...getDateRangeProps(), ...getGridEditorCommonProps() };
|
|
1623
|
-
}
|
|
1624
|
-
|
|
1625
|
-
// src/props/editor/list-box.ts
|
|
1626
|
-
function getListBoxProps() {
|
|
1627
|
-
return { ...getEditorProps(), value: [String, Number] };
|
|
1628
|
-
}
|
|
1629
|
-
function getGridListBoxProps() {
|
|
1630
|
-
return { ...getListBoxProps(), ...getGridEditorCommonProps() };
|
|
1631
|
-
}
|
|
1632
|
-
|
|
1633
|
-
// src/props/editor/number-range.ts
|
|
1634
|
-
function getNumberRangeProps() {
|
|
1635
|
-
return { ...getEditorProps(), value: [String, Number] };
|
|
1636
|
-
}
|
|
1637
|
-
function getGridNumberRangeProps() {
|
|
1638
|
-
return { ...getNumberRangeProps(), ...getGridEditorCommonProps() };
|
|
1639
|
-
}
|
|
1640
|
-
|
|
1641
|
-
// src/props/editor/radio-button-list.ts
|
|
1642
|
-
function getRadioProps() {
|
|
1643
|
-
return { ...getEditorProps(), value: [String, Number] };
|
|
1644
|
-
}
|
|
1645
|
-
function getGridRadioProps() {
|
|
1646
|
-
return { ...getRadioProps(), ...getGridEditorCommonProps() };
|
|
1647
|
-
}
|
|
1648
|
-
|
|
1649
|
-
// src/props/editor/rate.ts
|
|
1650
|
-
function getRateProps() {
|
|
1651
|
-
return { ...getEditorProps(), value: [String, Number] };
|
|
1652
|
-
}
|
|
1653
|
-
function getGridRateProps() {
|
|
1654
|
-
return { ...getRateProps(), ...getGridEditorCommonProps() };
|
|
1655
|
-
}
|
|
1656
|
-
|
|
1657
|
-
// src/props/editor/raw.ts
|
|
1658
|
-
function getRawProps() {
|
|
1659
|
-
return { ...getEditorProps(), value: [String, Number, Array] };
|
|
1660
|
-
}
|
|
1661
|
-
function getGridRawProps() {
|
|
1662
|
-
return { ...getRawProps(), ...getGridEditorCommonProps() };
|
|
1663
|
-
}
|
|
1664
|
-
|
|
1665
|
-
// src/props/editor/slider.ts
|
|
1666
|
-
function getSliderProps() {
|
|
1667
|
-
return { ...getEditorProps(), value: [String, Number] };
|
|
1668
|
-
}
|
|
1669
|
-
function getGridSliderProps() {
|
|
1670
|
-
return { ...getSliderProps(), ...getGridEditorCommonProps() };
|
|
1671
|
-
}
|
|
1672
|
-
|
|
1673
|
-
// src/props/editor/stepper.ts
|
|
1674
|
-
function getStepperProps() {
|
|
1675
|
-
return { ...getEditorProps(), value: [String, Number] };
|
|
1676
|
-
}
|
|
1677
|
-
function getGridStepperProps() {
|
|
1678
|
-
return { ...getStepperProps(), ...getGridEditorCommonProps() };
|
|
1679
|
-
}
|
|
1680
|
-
|
|
1681
|
-
// src/props/editor/switch.ts
|
|
1682
|
-
function getSwitchProps() {
|
|
1683
|
-
return { ...getEditorProps(), value: [String, Number] };
|
|
1684
|
-
}
|
|
1685
|
-
function getGridSwitchProps() {
|
|
1686
|
-
return { ...getSwitchProps(), ...getGridEditorCommonProps() };
|
|
1687
|
-
}
|
|
1688
|
-
|
|
1689
|
-
// src/props/editor/upload.ts
|
|
1690
|
-
function getUploadProps() {
|
|
1691
|
-
return { ...getEditorProps(), value: String };
|
|
1692
|
-
}
|
|
1693
|
-
function getGridUploadProps() {
|
|
1694
|
-
return { ...getUploadProps(), ...getGridEditorCommonProps() };
|
|
1695
|
-
}
|
|
1696
|
-
|
|
1697
|
-
// src/props/editor/autocomplete.ts
|
|
1698
|
-
function getAutoCompleteProps() {
|
|
1699
|
-
return { ...getEditorProps(), value: [String, Number] };
|
|
1700
|
-
}
|
|
1701
|
-
function getGridAutoCompleteProps() {
|
|
1702
|
-
return { ...getAutoCompleteProps(), ...getGridEditorCommonProps() };
|
|
1703
|
-
}
|
|
1704
|
-
|
|
1705
|
-
// src/props/editor/code.ts
|
|
1706
|
-
function getCodeProps() {
|
|
1707
|
-
return {
|
|
1708
|
-
...getEditorProps(),
|
|
1709
|
-
value: String,
|
|
1710
|
-
language: {
|
|
1711
|
-
type: String
|
|
1712
|
-
},
|
|
1713
|
-
theme: {
|
|
1714
|
-
type: String
|
|
1715
|
-
}
|
|
1716
|
-
};
|
|
1717
|
-
}
|
|
1718
|
-
function getGridCodeProps() {
|
|
1719
|
-
return { ...getCodeProps(), ...getGridEditorCommonProps() };
|
|
1720
|
-
}
|
|
1721
|
-
|
|
1722
|
-
// src/props/editor/html.ts
|
|
1723
|
-
function getHtmlProps() {
|
|
1724
|
-
return { ...getEditorProps(), value: String };
|
|
1725
|
-
}
|
|
1726
|
-
function getGridHtmlProps() {
|
|
1727
|
-
return { ...getHtmlProps(), ...getGridEditorCommonProps() };
|
|
1728
|
-
}
|
|
1729
|
-
|
|
1730
|
-
// src/props/editor/markdown.ts
|
|
1731
|
-
function getMarkDownProps() {
|
|
1732
|
-
return {
|
|
1733
|
-
...getEditorProps(),
|
|
1734
|
-
data: { type: Object, required: false },
|
|
1735
|
-
controller: { type: Object, required: false },
|
|
1736
|
-
disabled: {
|
|
1737
|
-
type: Boolean,
|
|
1738
|
-
required: false
|
|
1739
|
-
}
|
|
1740
|
-
};
|
|
1741
|
-
}
|
|
1742
|
-
function getGridMarkDownProps() {
|
|
1743
|
-
return { ...getMarkDownProps(), ...getGridEditorCommonProps() };
|
|
1744
|
-
}
|
|
1745
|
-
|
|
1746
|
-
// src/props/editor/array.ts
|
|
1747
|
-
function getArrayProps() {
|
|
1748
|
-
return { ...getEditorProps(), value: [Array, Array] };
|
|
1749
|
-
}
|
|
1750
|
-
function getGridArrayProps() {
|
|
1751
|
-
return { ...getArrayProps(), ...getGridEditorCommonProps() };
|
|
1752
|
-
}
|
|
1753
|
-
|
|
1754
|
-
// src/props/editor/cascader.ts
|
|
1755
|
-
function getCascaderProps() {
|
|
1756
|
-
return { ...getEditorProps(), value: String };
|
|
1757
|
-
}
|
|
1758
|
-
function getGridCascaderProps() {
|
|
1759
|
-
return { ...getCascaderProps(), ...getGridEditorCommonProps() };
|
|
1760
|
-
}
|
|
1761
|
-
|
|
1762
|
-
// src/props/editor/color-picker.ts
|
|
1763
|
-
function getColorPickerProps() {
|
|
1764
|
-
return { ...getEditorProps(), value: String };
|
|
1765
|
-
}
|
|
1766
|
-
function getGridColorPickerProps() {
|
|
1767
|
-
return { ...getColorPickerProps(), ...getGridEditorCommonProps() };
|
|
1768
|
-
}
|
|
1769
|
-
export {
|
|
1770
|
-
EmptyVNode,
|
|
1771
|
-
PluginFactory,
|
|
1772
|
-
RequiredProp,
|
|
1773
|
-
RouteListener,
|
|
1774
|
-
calcResRoutePath,
|
|
1775
|
-
excludeViewTypes,
|
|
1776
|
-
generateRoutePath,
|
|
1777
|
-
getArrayProps,
|
|
1778
|
-
getAutoCompleteProps,
|
|
1779
|
-
getCascaderProps,
|
|
1780
|
-
getCheckboxListProps,
|
|
1781
|
-
getCheckboxProps,
|
|
1782
|
-
getCodeProps,
|
|
1783
|
-
getColorPickerProps,
|
|
1784
|
-
getDataPickerProps,
|
|
1785
|
-
getDatePickerProps,
|
|
1786
|
-
getDateRangeProps,
|
|
1787
|
-
getDropdownProps,
|
|
1788
|
-
getEditorEmits,
|
|
1789
|
-
getEditorProps,
|
|
1790
|
-
getGridArrayProps,
|
|
1791
|
-
getGridAutoCompleteProps,
|
|
1792
|
-
getGridCascaderProps,
|
|
1793
|
-
getGridCheckboxListProps,
|
|
1794
|
-
getGridCheckboxProps,
|
|
1795
|
-
getGridCodeProps,
|
|
1796
|
-
getGridColorPickerProps,
|
|
1797
|
-
getGridDataPickerProps,
|
|
1798
|
-
getGridDatePickerProps,
|
|
1799
|
-
getGridDateRangeProps,
|
|
1800
|
-
getGridDropdownProps,
|
|
1801
|
-
getGridEditorCommonProps,
|
|
1802
|
-
getGridEditorEmits,
|
|
1803
|
-
getGridHtmlProps,
|
|
1804
|
-
getGridInputIpProps,
|
|
1805
|
-
getGridInputNumberProps,
|
|
1806
|
-
getGridInputProps,
|
|
1807
|
-
getGridListBoxProps,
|
|
1808
|
-
getGridMarkDownProps,
|
|
1809
|
-
getGridNumberRangeProps,
|
|
1810
|
-
getGridRadioProps,
|
|
1811
|
-
getGridRateProps,
|
|
1812
|
-
getGridRawProps,
|
|
1813
|
-
getGridSliderProps,
|
|
1814
|
-
getGridSpanProps,
|
|
1815
|
-
getGridStepperProps,
|
|
1816
|
-
getGridSwitchProps,
|
|
1817
|
-
getGridUploadProps,
|
|
1818
|
-
getHtmlProps,
|
|
1819
|
-
getInputIpProps,
|
|
1820
|
-
getInputNumberProps,
|
|
1821
|
-
getInputProps,
|
|
1822
|
-
getListBoxProps,
|
|
1823
|
-
getMarkDownProps,
|
|
1824
|
-
getNestedRoutePath,
|
|
1825
|
-
getNumberRangeProps,
|
|
1826
|
-
getOrigin,
|
|
1827
|
-
getOwnRouteContext,
|
|
1828
|
-
getRadioProps,
|
|
1829
|
-
getRateProps,
|
|
1830
|
-
getRawProps,
|
|
1831
|
-
getSliderProps,
|
|
1832
|
-
getSpanProps,
|
|
1833
|
-
getStepperProps,
|
|
1834
|
-
getSwitchProps,
|
|
1835
|
-
getUploadProps,
|
|
1836
|
-
isEmptyVNode,
|
|
1837
|
-
onRouteChange,
|
|
1838
|
-
parseRouteViewData,
|
|
1839
|
-
prepareControl,
|
|
1840
|
-
renderString,
|
|
1841
|
-
route2routePath,
|
|
1842
|
-
routePath2string,
|
|
1843
|
-
useClickOutside,
|
|
1844
|
-
useControlController,
|
|
1845
|
-
useController,
|
|
1846
|
-
useCtx,
|
|
1847
|
-
useEventListener,
|
|
1848
|
-
useFocusAndBlur,
|
|
1849
|
-
useForce,
|
|
1850
|
-
useForceTogether,
|
|
1851
|
-
useMobCtx,
|
|
1852
|
-
useNamespace,
|
|
1853
|
-
useProps,
|
|
1854
|
-
usePropsWatch,
|
|
1855
|
-
useRouteKey,
|
|
1856
|
-
useRouterQuery,
|
|
1857
|
-
useViewController,
|
|
1858
|
-
withInstall
|
|
1859
|
-
};
|