@dt-frames/ui 3.0.1 → 4.0.1
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/es/_virtual/preload-helper.mjs +1 -0
- package/dist/es/assets/node_modules/.pnpm/nprogress@0.2.0/node_modules/nprogress/nprogress-BgDCIyLK.css +1 -0
- package/dist/es/components/drawer/index.d.ts +5 -0
- package/dist/es/components/drawer/index.mjs +1 -0
- package/{es → dist/es}/components/drawer/src/hooks/useDrawer.d.ts +1 -1
- package/dist/es/components/drawer/src/index.d.ts +20 -0
- package/dist/es/components/drawer/src/types/index.d.ts +208 -0
- package/dist/es/components/drawer/src/types/index.ts +223 -0
- package/dist/es/components/form/index.d.ts +9 -0
- package/dist/es/components/form/index.mjs +1 -0
- package/dist/es/components/form/src/conponents/FormButtons.d.ts +29 -0
- package/dist/es/components/form/src/conponents/FormItems.d.ts +19 -0
- package/dist/es/components/form/src/conponents/RadioGroup.d.ts +10 -0
- package/{es/components/form/src/components → dist/es/components/form/src/conponents}/componentMap.d.ts +1 -1
- package/dist/es/components/form/src/hooks/useForm.d.ts +8 -0
- package/dist/es/components/form/src/hooks/useFormActions.d.ts +32 -0
- package/dist/es/components/form/src/hooks/useFormEvent.d.ts +29 -0
- package/dist/es/components/form/src/hooks/useFormValues.d.ts +13 -0
- package/dist/es/components/form/src/index.d.ts +493 -0
- package/dist/es/components/form/src/types/form.d.ts +355 -0
- package/dist/es/components/form/src/types/form.ts +391 -0
- package/dist/es/components/form/src/types/item.d.ts +3036 -0
- package/dist/es/components/form/src/types/item.ts +3169 -0
- package/dist/es/components/form/src/utils/index.d.ts +16 -0
- package/dist/es/components/form/styles/index.scss +10 -0
- package/dist/es/components/hover-card/index.d.ts +7 -0
- package/dist/es/components/hover-card/index.mjs +1 -0
- package/dist/es/components/hover-card/src/hover-card-content.d.ts +24 -0
- package/dist/es/components/hover-card/src/hover-card-trigger.d.ts +18 -0
- package/dist/es/components/hover-card/src/hover-card.d.ts +22 -0
- package/dist/es/components/icon/index.d.ts +4 -0
- package/dist/es/components/icon/index.mjs +1 -0
- package/dist/es/components/icon/src/index.d.ts +31 -0
- package/dist/es/components/icon/src/types/index.d.ts +6 -0
- package/dist/es/components/icon-picker/index.d.ts +4 -0
- package/dist/es/components/icon-picker/index.mjs +9 -0
- package/dist/es/components/icon-picker/src/components/IconPicker.d.ts +23 -0
- package/dist/es/components/icon-picker/src/components/SelectIcon.d.ts +39 -0
- package/dist/es/components/icon-picker/src/icon.d.ts +13 -0
- package/dist/es/components/icon-picker/src/index.d.ts +27 -0
- package/dist/es/components/icon-picker/styles/index.scss +0 -0
- package/dist/es/components/iframe/index.d.ts +4 -0
- package/dist/es/components/iframe/index.mjs +1 -0
- package/dist/es/components/iframe/src/index.d.ts +46 -0
- package/dist/es/components/modal/index.d.ts +7 -0
- package/dist/es/components/modal/index.mjs +1 -0
- package/dist/es/components/modal/src/components/Header.d.ts +8 -0
- package/dist/es/components/modal/src/hooks/useModal.d.ts +24 -0
- package/dist/es/components/modal/src/index.d.ts +822 -0
- package/dist/es/components/modal/src/types/modal.d.ts +246 -0
- package/dist/es/components/modal/src/types/modal.ts +265 -0
- package/dist/es/components/modal/styles/index.scss +8 -0
- package/dist/es/components/table/index.d.ts +9 -0
- package/dist/es/components/table/index.mjs +1 -0
- package/dist/es/components/table/src/components/Pagination.d.ts +15 -0
- package/dist/es/components/table/src/components/TableAction.d.ts +18 -0
- package/dist/es/components/table/src/components/TableHeader.d.ts +28 -0
- package/dist/es/components/table/src/components/TableLoading.d.ts +2 -0
- package/dist/es/components/table/src/components/tableSetting/Column.d.ts +222 -0
- package/dist/es/components/table/src/components/tableSetting/Download.d.ts +6 -0
- package/dist/es/components/table/src/components/tableSetting/DownloadCtrl.d.ts +2 -0
- package/dist/es/components/table/src/components/tableSetting/Fullscreen.d.ts +2 -0
- package/dist/es/components/table/src/components/tableSetting/Search.d.ts +5 -0
- package/dist/es/components/table/src/components/tableSetting/index.d.ts +7 -0
- package/dist/es/components/table/src/hooks/useColumns.d.ts +18 -0
- package/dist/es/components/table/src/hooks/useDataSource.d.ts +17 -0
- package/dist/es/components/table/src/hooks/useLoading.d.ts +7 -0
- package/dist/es/components/table/src/hooks/usePagination.d.ts +9 -0
- package/dist/es/components/table/src/hooks/useRowSelection.d.ts +7 -0
- package/dist/es/components/table/src/hooks/useTable.d.ts +3 -0
- package/dist/es/components/table/src/hooks/useTableIns.d.ts +12 -0
- package/dist/es/components/table/src/index.d.ts +775 -0
- package/dist/es/components/table/src/types/pagination.d.ts +100 -0
- package/dist/es/components/table/src/types/pagination.ts +102 -0
- package/dist/es/components/table/src/types/table.d.ts +632 -0
- package/dist/es/components/table/src/types/table.ts +668 -0
- package/dist/es/components/table/styles/index.scss +66 -0
- package/dist/es/components/tree/index.d.ts +7 -0
- package/dist/es/components/tree/index.mjs +1 -0
- package/dist/es/components/tree/src/components/ContextMenu.d.ts +80 -0
- package/dist/es/components/tree/src/components/TreeHeader.d.ts +31 -0
- package/dist/es/components/tree/src/hooks/useContextMenu.d.ts +11 -0
- package/dist/es/components/tree/src/hooks/useTree.d.ts +2 -0
- package/dist/es/components/tree/src/index.d.ts +116 -0
- package/dist/es/components/tree/src/types/index.d.ts +758 -0
- package/dist/es/components/tree/src/types/index.ts +788 -0
- package/dist/es/components/tree/styles/index.scss +15 -0
- package/dist/es/components/upload/assets/docx-preview-BLYEK_jf.js +38 -0
- package/dist/es/components/upload/assets/index-CUsgWuYW.css +1 -0
- package/dist/es/components/upload/assets/nprogress-BgDCIyLK.css +1 -0
- package/dist/es/components/upload/index.d.ts +6 -0
- package/dist/es/components/upload/index.mjs +1 -0
- package/dist/es/components/upload/src/components/PdfView.d.ts +2 -0
- package/dist/es/components/upload/src/components/WordView.d.ts +4 -0
- package/dist/es/components/upload/src/hooks/useFile.d.ts +14 -0
- package/dist/es/components/upload/src/index.d.ts +23 -0
- package/dist/es/components/upload/src/types/index.d.ts +229 -0
- package/dist/es/components/upload/src/utils/index.d.ts +15 -0
- package/dist/es/components/upload/styles/index.scss +0 -0
- package/dist/es/components/virtual-list/index.d.ts +4 -0
- package/dist/es/components/virtual-list/index.mjs +1 -0
- package/dist/es/components/virtual-list/src/index.d.ts +32 -0
- package/dist/es/components/virtual-list/src/types/index.d.ts +26 -0
- package/dist/es/components/virtual-list/styles/index.scss +0 -0
- package/dist/es/components/vxe-table/index.d.ts +7 -0
- package/dist/es/components/vxe-table/index.mjs +1 -0
- package/dist/es/components/vxe-table/src/components/Header.d.ts +28 -0
- package/dist/es/components/vxe-table/src/components/Pagination.d.ts +15 -0
- package/dist/es/components/vxe-table/src/components/RenderCell.d.ts +10 -0
- package/dist/es/components/vxe-table/src/components/TableAction.d.ts +18 -0
- package/dist/es/components/vxe-table/src/components/tableSetting/Column.d.ts +222 -0
- package/dist/es/components/vxe-table/src/components/tableSetting/Download.d.ts +6 -0
- package/dist/es/components/vxe-table/src/components/tableSetting/DownloadCtrl.d.ts +2 -0
- package/dist/es/components/vxe-table/src/components/tableSetting/Fullscreen.d.ts +2 -0
- package/dist/es/components/vxe-table/src/components/tableSetting/index.d.ts +7 -0
- package/dist/es/components/vxe-table/src/helper/index.d.ts +7 -0
- package/dist/es/components/vxe-table/src/hooks/useColumns.d.ts +5 -0
- package/dist/es/components/vxe-table/src/hooks/usePagination.d.ts +7 -0
- package/dist/es/components/vxe-table/src/hooks/useTableIns.d.ts +15 -0
- package/dist/es/components/vxe-table/src/hooks/useVxeTable.d.ts +2 -0
- package/dist/es/components/vxe-table/src/index.d.ts +155 -0
- package/dist/es/components/vxe-table/src/types/index.d.ts +181 -0
- package/dist/es/components/vxe-table/src/types/pagination.d.ts +100 -0
- package/dist/es/components/vxe-table/src/types/table.d.ts +25 -0
- package/dist/es/components/vxe-table/src/utils/index.d.ts +5 -0
- package/dist/es/components/vxe-table/styles/index.scss +6 -0
- package/dist/es/hooks/useCurd.d.ts +4 -0
- package/dist/es/hooks/useCurd.mjs +1 -0
- package/dist/es/hooks/useDownload.d.ts +9 -0
- package/dist/es/hooks/useDownload.mjs +1 -0
- package/dist/es/hooks/useSource.d.ts +10 -0
- package/dist/es/hooks/useSource.mjs +1 -0
- package/dist/es/index.d.ts +11 -0
- package/dist/es/index.mjs +1 -0
- package/dist/es/init/config.d.ts +6 -0
- package/dist/es/init/config.mjs +1 -0
- package/dist/es/init/index.d.ts +11 -0
- package/dist/es/init/index.mjs +1 -0
- package/dist/es/init/types/appConf.d.ts +331 -0
- package/dist/es/init/vxeTable.d.ts +5 -0
- package/dist/es/layout/assets/avator-uscRzRXF.png +0 -0
- package/dist/es/layout/index.d.ts +11 -0
- package/dist/es/layout/index.mjs +3 -0
- package/dist/es/layout/src/components/LayoutContent.d.ts +22 -0
- package/dist/es/layout/src/components/LayoutFooter.d.ts +23 -0
- package/dist/es/layout/src/components/LayoutHeader.d.ts +49 -0
- package/dist/es/layout/src/components/LayoutSidebar.d.ts +116 -0
- package/dist/es/layout/src/components/LayoutTabbar.d.ts +20 -0
- package/dist/es/layout/src/components/content/Content.d.ts +2 -0
- package/dist/es/layout/src/components/footer/CopyRight.d.ts +15 -0
- package/dist/es/layout/src/components/header/ArrowRight.d.ts +2 -0
- package/dist/es/layout/src/components/header/Breadcrumb.d.ts +13 -0
- package/dist/es/layout/src/components/header/FullScreen.d.ts +2 -0
- package/dist/es/layout/src/components/header/GlobalSearch.d.ts +417 -0
- package/dist/es/layout/src/components/header/Header.d.ts +22 -0
- package/dist/es/layout/src/components/header/IconButton.d.ts +29 -0
- package/dist/es/layout/src/components/header/LanguageToggle.d.ts +8 -0
- package/dist/es/layout/src/components/header/Logo.d.ts +54 -0
- package/dist/es/layout/src/components/header/User.d.ts +2 -0
- package/dist/es/layout/src/components/header/perferences/block/block.d.ts +22 -0
- package/dist/es/layout/src/components/header/perferences/block/component/CheckboxItem.d.ts +38 -0
- package/dist/es/layout/src/components/header/perferences/block/component/InputItem.d.ts +35 -0
- package/dist/es/layout/src/components/header/perferences/block/component/NumberItem.d.ts +36 -0
- package/dist/es/layout/src/components/header/perferences/block/component/SelectItem.d.ts +35 -0
- package/dist/es/layout/src/components/header/perferences/block/component/SwitchItem.d.ts +33 -0
- package/dist/es/layout/src/components/header/perferences/block/component/ToggleItem.d.ts +32 -0
- package/dist/es/layout/src/components/header/perferences/block/general/Animation.d.ts +18 -0
- package/dist/es/layout/src/components/header/perferences/block/general/General.d.ts +18 -0
- package/dist/es/layout/src/components/header/perferences/block/layout/Breadcrumb.d.ts +24 -0
- package/dist/es/layout/src/components/header/perferences/block/layout/Content.d.ts +9 -0
- package/dist/es/layout/src/components/header/perferences/block/layout/Copyright.d.ts +27 -0
- package/dist/es/layout/src/components/header/perferences/block/layout/Footer.d.ts +12 -0
- package/dist/es/layout/src/components/header/perferences/block/layout/Header.d.ts +19 -0
- package/dist/es/layout/src/components/header/perferences/block/layout/Layout.d.ts +10 -0
- package/dist/es/layout/src/components/header/perferences/block/layout/Navigation.d.ts +19 -0
- package/dist/es/layout/src/components/header/perferences/block/layout/Sidebar.d.ts +35 -0
- package/dist/es/layout/src/components/header/perferences/block/layout/Tabbar.d.ts +39 -0
- package/dist/es/layout/src/components/header/perferences/block/layout/Widget.d.ts +33 -0
- package/dist/es/layout/src/components/header/perferences/block/shortcut-keys/Global.d.ts +18 -0
- package/dist/es/layout/src/components/header/perferences/block/theme/BuiltinTheme.d.ts +16 -0
- package/dist/es/layout/src/components/header/perferences/block/theme/ColorMode.d.ts +12 -0
- package/dist/es/layout/src/components/header/perferences/block/theme/Radius.d.ts +9 -0
- package/dist/es/layout/src/components/header/perferences/block/theme/Theme.d.ts +15 -0
- package/dist/es/layout/src/components/header/perferences/icons/content-compact.d.ts +2 -0
- package/dist/es/layout/src/components/header/perferences/icons/full-content.d.ts +2 -0
- package/dist/es/layout/src/components/header/perferences/icons/header-mixed-nav.d.ts +2 -0
- package/dist/es/layout/src/components/header/perferences/icons/header-nav.d.ts +2 -0
- package/dist/es/layout/src/components/header/perferences/icons/header-sidebar-nav.d.ts +2 -0
- package/dist/es/layout/src/components/header/perferences/icons/index.d.ts +10 -0
- package/dist/es/layout/src/components/header/perferences/icons/mixed-nav.d.ts +2 -0
- package/dist/es/layout/src/components/header/perferences/icons/sidebar-mixed-nav.d.ts +2 -0
- package/dist/es/layout/src/components/header/perferences/icons/sidebar-nav.d.ts +2 -0
- package/dist/es/layout/src/components/header/perferences/preferences-button.d.ts +6 -0
- package/dist/es/layout/src/components/header/perferences/preferences-drawer.d.ts +223 -0
- package/dist/es/layout/src/components/header/perferences/preferences.d.ts +27 -0
- package/dist/es/layout/src/components/lockscreen/Lockscreen.d.ts +2 -0
- package/{es/theme/src/components/header/components/lock → dist/es/layout/src/components/lockscreen}/Recharge.d.ts +3 -3
- package/dist/es/layout/src/components/lockscreen/useBattery.d.ts +16 -0
- package/dist/es/layout/src/components/lockscreen/useTime.d.ts +3 -0
- package/dist/es/layout/src/components/menu/ExtraMenu.d.ts +11 -0
- package/dist/es/layout/src/components/menu/Menu.d.ts +12 -0
- package/dist/es/layout/src/components/menu/MixedMenu.d.ts +11 -0
- package/dist/es/layout/src/components/menu/SidebarCollapseButton.d.ts +9 -0
- package/dist/es/layout/src/components/menu/SidebarFixedButton.d.ts +9 -0
- package/dist/es/layout/src/components/menu/basic-menu/BasicMenu.d.ts +37 -0
- package/dist/es/layout/src/components/menu/basic-menu/CollapseTransition.d.ts +17 -0
- package/dist/es/layout/src/components/menu/basic-menu/HoverCard.d.ts +29 -0
- package/dist/es/layout/src/components/menu/basic-menu/Menu.d.ts +5 -0
- package/dist/es/layout/src/components/menu/basic-menu/MenuBadge.d.ts +6 -0
- package/dist/es/layout/src/components/menu/basic-menu/MenuBadgeDot.d.ts +10 -0
- package/dist/es/layout/src/components/menu/basic-menu/MenuItem.d.ts +28 -0
- package/dist/es/layout/src/components/menu/basic-menu/NoramalMenu.d.ts +14 -0
- package/dist/es/layout/src/components/menu/basic-menu/SubMenu.d.ts +6 -0
- package/dist/es/layout/src/components/menu/basic-menu/SubMenuCom.d.ts +25 -0
- package/dist/es/layout/src/components/menu/basic-menu/SubMenuContent.d.ts +27 -0
- package/dist/es/layout/src/components/menu/basic-menu/index.d.ts +2 -0
- package/dist/es/layout/src/components/menu/basic-menu/type.d.ts +127 -0
- package/dist/es/layout/src/components/menu/hooks/useMenu.d.ts +9 -0
- package/dist/es/layout/src/components/menu/hooks/useMenuScroll.d.ts +9 -0
- package/dist/es/layout/src/components/tabbar/Tabbar.d.ts +6 -0
- package/dist/es/layout/src/components/tabbar/hooks/useTab.d.ts +25 -0
- package/dist/es/layout/src/components/tabbar/hooks/useTabbar.d.ts +15 -0
- package/dist/es/layout/src/components/tabbar/hooks/useTabsDrag.d.ts +8 -0
- package/dist/es/layout/src/components/tabbar/hooks/useTabsViewScroll.d.ts +11 -0
- package/dist/es/layout/src/components/tabbar/tabsView/TabsContent.d.ts +959 -0
- package/dist/es/layout/src/components/tabbar/tabsView/ToolScreen.d.ts +9 -0
- package/dist/es/layout/src/components/tabbar/tabsView/ToolsMore.d.ts +6 -0
- package/dist/es/layout/src/components/tabbar/tabsView/types.d.ts +68 -0
- package/dist/es/layout/src/const/constants.d.ts +13 -0
- package/dist/es/layout/src/const/preferences.config.d.ts +8 -0
- package/dist/es/layout/src/hooks/useContext.d.ts +6 -0
- package/dist/es/layout/src/hooks/useDesignTokens.d.ts +1 -0
- package/dist/es/layout/src/hooks/useExtraMenu.d.ts +12 -0
- package/dist/es/layout/src/hooks/useLayoutStyle.d.ts +36 -0
- package/dist/es/layout/src/hooks/useMenu.d.ts +4 -0
- package/dist/es/layout/src/hooks/useMixedMenu.d.ts +13 -0
- package/dist/es/layout/src/hooks/useNavigation.d.ts +5 -0
- package/dist/es/layout/src/hooks/useTheme.d.ts +34 -0
- package/dist/es/layout/src/index.d.ts +28 -0
- package/dist/es/layout/src/layout.d.ts +71 -0
- package/dist/es/layout/src/stores/preferences.store.d.ts +66 -0
- package/dist/es/layout/src/stores/useTabbar.store.d.ts +185 -0
- package/dist/es/layout/src/types/basic.type.d.ts +5 -0
- package/dist/es/layout/src/types/menu.type.d.ts +102 -0
- package/dist/es/layout/src/types/perferences.type.d.ts +287 -0
- package/dist/es/layout/src/types/route.type.d.ts +109 -0
- package/dist/es/layout/src/utils/color.d.ts +19 -0
- package/dist/es/layout/src/utils/css.d.ts +14 -0
- package/dist/es/layout/src/utils/diff.d.ts +6 -0
- package/dist/es/layout/src/utils/dom.d.ts +6 -0
- package/dist/es/layout/src/utils/letter.d.ts +20 -0
- package/dist/es/layout/src/utils/menu.d.ts +20 -0
- package/dist/es/layout/styles/css/animation.css +299 -0
- package/dist/es/layout/styles/css/dark.css +232 -0
- package/dist/es/layout/styles/css/default.css +174 -0
- package/dist/es/layout/styles/css/uncss.css +109 -0
- package/dist/es/layout/styles/index.scss +871 -0
- package/dist/es/lib/components/drawer/index.d.ts +5 -0
- package/dist/es/lib/components/drawer/src/hooks/useDrawer.d.ts +3 -0
- package/dist/es/lib/components/drawer/src/types/index.d.ts +208 -0
- package/dist/es/lib/components/form/index.d.ts +9 -0
- package/dist/es/lib/components/form/src/conponents/componentMap.d.ts +4 -0
- package/dist/es/lib/components/form/src/hooks/useForm.d.ts +8 -0
- package/dist/es/lib/components/form/src/hooks/useFormActions.d.ts +32 -0
- package/dist/es/lib/components/form/src/hooks/useFormEvent.d.ts +29 -0
- package/dist/es/lib/components/form/src/hooks/useFormValues.d.ts +13 -0
- package/dist/es/lib/components/form/src/types/form.d.ts +355 -0
- package/dist/es/lib/components/form/src/types/item.d.ts +3170 -0
- package/dist/es/lib/components/form/src/utils/index.d.ts +16 -0
- package/dist/es/lib/components/hover-card/index.d.ts +7 -0
- package/dist/es/lib/components/icon/index.d.ts +4 -0
- package/dist/es/lib/components/icon-picker/index.d.ts +4 -0
- package/dist/es/lib/components/icon-picker/src/icon.d.ts +13 -0
- package/dist/es/lib/components/iframe/index.d.ts +4 -0
- package/dist/es/lib/components/modal/index.d.ts +7 -0
- package/dist/es/lib/components/modal/src/hooks/useModal.d.ts +24 -0
- package/dist/es/lib/components/modal/src/types/modal.d.ts +246 -0
- package/dist/es/lib/components/table/index.d.ts +9 -0
- package/dist/es/lib/components/table/src/hooks/useColumns.d.ts +18 -0
- package/dist/es/lib/components/table/src/hooks/useDataSource.d.ts +17 -0
- package/dist/es/lib/components/table/src/hooks/useLoading.d.ts +7 -0
- package/dist/es/lib/components/table/src/hooks/usePagination.d.ts +9 -0
- package/dist/es/lib/components/table/src/hooks/useRowSelection.d.ts +7 -0
- package/dist/es/lib/components/table/src/hooks/useTable.d.ts +3 -0
- package/dist/es/lib/components/table/src/hooks/useTableIns.d.ts +12 -0
- package/dist/es/lib/components/table/src/types/pagination.d.ts +100 -0
- package/dist/es/lib/components/table/src/types/table.d.ts +632 -0
- package/dist/es/lib/components/tree/index.d.ts +7 -0
- package/dist/es/lib/components/tree/src/enums/index.d.ts +6 -0
- package/dist/es/lib/components/tree/src/hooks/useContextMenu.d.ts +11 -0
- package/dist/es/lib/components/tree/src/hooks/useTree.d.ts +2 -0
- package/dist/es/lib/components/tree/src/types/index.d.ts +758 -0
- package/dist/es/lib/components/upload/index.d.ts +4 -0
- package/dist/es/lib/components/upload/src/hooks/useFile.d.ts +14 -0
- package/dist/es/lib/components/upload/src/types/index.d.ts +88 -0
- package/dist/es/lib/components/upload/src/utils/index.d.ts +15 -0
- package/dist/es/lib/components/virtual-list/index.d.ts +4 -0
- package/dist/es/lib/components/virtual-list/src/types/index.d.ts +26 -0
- package/dist/es/lib/components/vxe-table/index.d.ts +7 -0
- package/dist/es/lib/components/vxe-table/src/helper/index.d.ts +7 -0
- package/dist/es/lib/components/vxe-table/src/hooks/useColumns.d.ts +5 -0
- package/dist/es/lib/components/vxe-table/src/hooks/usePagination.d.ts +7 -0
- package/dist/es/lib/components/vxe-table/src/hooks/useTableIns.d.ts +15 -0
- package/dist/es/lib/components/vxe-table/src/hooks/useVxeTable.d.ts +2 -0
- package/dist/es/lib/components/vxe-table/src/types/index.d.ts +181 -0
- package/dist/es/lib/components/vxe-table/src/types/pagination.d.ts +100 -0
- package/dist/es/lib/components/vxe-table/src/types/table.d.ts +25 -0
- package/dist/es/lib/components/vxe-table/src/utils/index.d.ts +5 -0
- package/dist/es/lib/hooks/useCurd.d.ts +4 -0
- package/dist/es/lib/hooks/useDownload.d.ts +9 -0
- package/dist/es/lib/hooks/useSource.d.ts +10 -0
- package/dist/es/lib/index.d.ts +10 -0
- package/dist/es/lib/init/config.d.ts +6 -0
- package/dist/es/lib/init/index.d.ts +11 -0
- package/dist/es/lib/init/types/appConf.d.ts +331 -0
- package/dist/es/lib/init/vxeTable.d.ts +9 -0
- package/dist/es/lib/layout/index.d.ts +11 -0
- package/dist/es/lib/layout/src/components/header/perferences/icons/index.d.ts +10 -0
- package/dist/es/lib/layout/src/components/lockscreen/lockscreen.store.d.ts +9 -0
- package/dist/es/lib/layout/src/components/lockscreen/useBattery.d.ts +16 -0
- package/dist/es/lib/layout/src/components/lockscreen/useTime.d.ts +3 -0
- package/dist/es/lib/layout/src/components/menu/basic-menu/index.d.ts +2 -0
- package/dist/es/lib/layout/src/components/menu/basic-menu/type.d.ts +127 -0
- package/dist/es/lib/layout/src/components/menu/hooks/useMenu.d.ts +9 -0
- package/dist/es/lib/layout/src/components/menu/hooks/useMenuScroll.d.ts +9 -0
- package/dist/es/lib/layout/src/components/tabbar/hooks/useTab.d.ts +25 -0
- package/dist/es/lib/layout/src/components/tabbar/hooks/useTabbar.d.ts +15 -0
- package/dist/es/lib/layout/src/components/tabbar/hooks/useTabsDrag.d.ts +8 -0
- package/dist/es/lib/layout/src/components/tabbar/hooks/useTabsViewScroll.d.ts +11 -0
- package/dist/es/lib/layout/src/components/tabbar/tabsView/types.d.ts +68 -0
- package/dist/es/lib/layout/src/const/constants.d.ts +13 -0
- package/dist/es/lib/layout/src/const/preferences.config.d.ts +8 -0
- package/dist/es/lib/layout/src/hooks/useContext.d.ts +6 -0
- package/dist/es/lib/layout/src/hooks/useDesignTokens.d.ts +1 -0
- package/dist/es/lib/layout/src/hooks/useExtraMenu.d.ts +12 -0
- package/dist/es/lib/layout/src/hooks/useLayoutStyle.d.ts +36 -0
- package/dist/es/lib/layout/src/hooks/useMenu.d.ts +4 -0
- package/dist/es/lib/layout/src/hooks/useMixedMenu.d.ts +13 -0
- package/dist/es/lib/layout/src/hooks/useNavigation.d.ts +5 -0
- package/dist/es/lib/layout/src/hooks/useTheme.d.ts +34 -0
- package/dist/es/lib/layout/src/stores/preferences.store.d.ts +66 -0
- package/dist/es/lib/layout/src/stores/useTabbar.store.d.ts +185 -0
- package/dist/es/lib/layout/src/types/basic.type.d.ts +5 -0
- package/dist/es/lib/layout/src/types/menu.type.d.ts +102 -0
- package/dist/es/lib/layout/src/types/perferences.type.d.ts +287 -0
- package/dist/es/lib/layout/src/types/route.type.d.ts +109 -0
- package/dist/es/lib/layout/src/utils/color.d.ts +19 -0
- package/dist/es/lib/layout/src/utils/css.d.ts +14 -0
- package/dist/es/lib/layout/src/utils/diff.d.ts +6 -0
- package/dist/es/lib/layout/src/utils/dom.d.ts +6 -0
- package/dist/es/lib/layout/src/utils/letter.d.ts +20 -0
- package/dist/es/lib/layout/src/utils/menu.d.ts +20 -0
- package/dist/es/lib/router/goPage.d.ts +1 -0
- package/dist/es/lib/router/guard.d.ts +3 -0
- package/dist/es/lib/router/index.d.ts +8 -0
- package/dist/es/lib/stores/access.store.d.ts +59 -0
- package/dist/es/lib/stores/app.store.d.ts +11 -0
- package/dist/es/lib/stores/auth.store.d.ts +35 -0
- package/dist/es/lib/stores/user.store.d.ts +19 -0
- package/dist/es/lib/types/curd.type.d.ts +55 -0
- package/dist/es/lib/types/source.type.d.ts +177 -0
- package/dist/es/lib/types/user.type.d.ts +32 -0
- package/dist/es/lib/utils/api.d.ts +2 -0
- package/dist/es/lib/utils/index.d.ts +4 -0
- package/dist/es/lib/utils/namespace.d.ts +17 -0
- package/dist/es/lib/utils/progress.d.ts +11 -0
- package/dist/es/lib/utils/useAuth.d.ts +3 -0
- package/dist/es/lib/utils/withInstall.d.ts +4 -0
- package/dist/es/mock/userInfo.d.ts +13 -0
- package/dist/es/mock/userInfo.mjs +1 -0
- package/dist/es/pages/iframe.d.ts +4 -0
- package/dist/es/pages/iframe.vue.mjs +1 -0
- package/dist/es/pages/iframe.vue2.mjs +1 -0
- package/dist/es/pages/init-project.d.ts +2 -0
- package/dist/es/pages/init-project.vue.mjs +1 -0
- package/dist/es/pages/init-project.vue2.mjs +1 -0
- package/dist/es/pages/not-found.d.ts +2 -0
- package/dist/es/pages/not-found.vue.mjs +1 -0
- package/dist/es/pages/not-found.vue2.mjs +1 -0
- package/dist/es/router/goPage.d.ts +1 -0
- package/dist/es/router/goPage.mjs +1 -0
- package/dist/es/router/guard.d.ts +3 -0
- package/dist/es/router/guard.mjs +1 -0
- package/dist/es/router/index.d.ts +8 -0
- package/dist/es/router/index.mjs +2 -0
- package/dist/es/src/index.d.ts +34 -0
- package/dist/es/src/types/index.d.ts +6 -0
- package/dist/es/stores/access.store.d.ts +59 -0
- package/dist/es/stores/access.store.mjs +1 -0
- package/dist/es/stores/app.store.d.ts +11 -0
- package/dist/es/stores/app.store.mjs +1 -0
- package/dist/es/stores/auth.store.d.ts +35 -0
- package/dist/es/stores/auth.store.mjs +1 -0
- package/dist/es/stores/user.store.d.ts +19 -0
- package/dist/es/stores/user.store.mjs +1 -0
- package/dist/es/types/curd.type.d.ts +55 -0
- package/dist/es/types/source.type.d.ts +177 -0
- package/dist/es/types/user.type.d.ts +32 -0
- package/dist/es/utils/api.d.ts +2 -0
- package/dist/es/utils/index.d.ts +4 -0
- package/dist/es/utils/namespace.d.ts +17 -0
- package/dist/es/utils/namespace.mjs +1 -0
- package/dist/es/utils/progress.d.ts +11 -0
- package/dist/es/utils/progress.mjs +2 -0
- package/dist/es/utils/useAuth.d.ts +3 -0
- package/dist/es/utils/withInstall.d.ts +4 -0
- package/dist/es/utils/withInstall.mjs +1 -0
- package/dist/es/vite.config.d.ts +30 -0
- package/index.d.ts +83 -12
- package/index.ts +16 -0
- package/package.json +75 -49
- package/README.md +0 -18
- package/es/assets/fonts/iconfont.css +0 -7266
- package/es/assets/fonts/iconfont.eot +0 -0
- package/es/assets/fonts/iconfont.svg +0 -5445
- package/es/assets/fonts/iconfont.ttf +0 -0
- package/es/assets/fonts/iconfont.woff +0 -0
- package/es/assets/fonts/iconfont.woff2 +0 -0
- package/es/assets/icons/ui-blank.svg +0 -1
- package/es/assets/icons/ui-docx.svg +0 -1
- package/es/assets/icons/ui-exl.svg +0 -1
- package/es/assets/icons/ui-forder-open.svg +0 -1
- package/es/assets/icons/ui-forder.svg +0 -1
- package/es/assets/icons/ui-jpg.svg +0 -1
- package/es/assets/icons/ui-pdf.svg +0 -1
- package/es/assets/icons/ui-ppt.svg +0 -1
- package/es/assets/icons/ui-rar.svg +0 -1
- package/es/assets/icons/ui-table-empty.svg +0 -1
- package/es/assets/icons/ui-txt.svg +0 -1
- package/es/assets/imgs/header/avatar.png +0 -0
- package/es/assets/imgs/logo/logo.png +0 -0
- package/es/assets/imgs/table/empty.png +0 -0
- package/es/assets/index.e67ea2f5.css +0 -1
- package/es/assets/locales/en.d.ts +0 -104
- package/es/assets/locales/en.ts +0 -104
- package/es/assets/locales/index.d.ts +0 -2
- package/es/assets/locales/index.ts +0 -5
- package/es/assets/locales/zh.d.ts +0 -105
- package/es/assets/locales/zh.ts +0 -105
- package/es/assets/test.ts +0 -1
- package/es/components/container/index.d.ts +0 -3
- package/es/components/container/index.js +0 -367
- package/es/components/container/src/components/bar.d.ts +0 -14
- package/es/components/container/src/hooks/scroll.d.ts +0 -10
- package/es/components/container/src/index.scss +0 -57
- package/es/components/container/src/types/index.d.ts +0 -22
- package/es/components/container/src/utils/scroll.d.ts +0 -5
- package/es/components/curd/index.d.ts +0 -4
- package/es/components/curd/index.js +0 -141
- package/es/components/curd/src/components/props.d.ts +0 -53
- package/es/components/curd/src/components/types/curd.type.d.ts +0 -13
- package/es/components/curd/src/hooks/useCurd.d.ts +0 -3
- package/es/components/curd/src/props.d.ts +0 -138
- package/es/components/curd/src/types/curd.type.d.ts +0 -59
- package/es/components/drawer/index.d.ts +0 -3
- package/es/components/drawer/index.js +0 -299
- package/es/components/drawer/src/components/DrawerFooter.d.ts +0 -54
- package/es/components/drawer/src/index.d.ts +0 -16
- package/es/components/drawer/src/index.scss +0 -24
- package/es/components/drawer/src/props.d.ts +0 -2
- package/es/components/drawer/src/type/drawer.type.d.ts +0 -62
- package/es/components/form/index.d.ts +0 -7
- package/es/components/form/index.js +0 -1604
- package/es/components/form/src/components/DynanicInput.d.ts +0 -2
- package/es/components/form/src/components/FormButtons.d.ts +0 -84
- package/es/components/form/src/components/FormInputUseDialog.d.ts +0 -2
- package/es/components/form/src/components/FormItem.d.ts +0 -55
- package/es/components/form/src/components/RadioButton.d.ts +0 -26
- package/es/components/form/src/components/index.d.ts +0 -2
- package/es/components/form/src/hooks/useForm.d.ts +0 -6
- package/es/components/form/src/hooks/useFormActions.d.ts +0 -45
- package/es/components/form/src/hooks/useFormEvent.d.ts +0 -27
- package/es/components/form/src/hooks/useFormValue.d.ts +0 -3
- package/es/components/form/src/hooks/useFormValues.d.ts +0 -13
- package/es/components/form/src/hooks/useLabelWidth.d.ts +0 -6
- package/es/components/form/src/index.d.ts +0 -358
- package/es/components/form/src/index.scss +0 -162
- package/es/components/form/src/props.d.ts +0 -165
- package/es/components/form/src/types/actions.type.d.ts +0 -15
- package/es/components/form/src/types/form.type.d.ts +0 -113
- package/es/components/form/src/types/items.type.d.ts +0 -417
- package/es/components/form/src/utils/helper.d.ts +0 -21
- package/es/components/icons/index.d.ts +0 -2
- package/es/components/icons/index.js +0 -100
- package/es/components/icons/src/SvgIcon.d.ts +0 -37
- package/es/components/icons/src/index.scss +0 -3
- package/es/components/iframe/index.d.ts +0 -2
- package/es/components/iframe/index.js +0 -83
- package/es/components/iframe/src/index.d.ts +0 -43
- package/es/components/iframe/src/index.scss +0 -20
- package/es/components/modal/index.d.ts +0 -5
- package/es/components/modal/index.js +0 -636
- package/es/components/modal/src/components/CloseIcon.d.ts +0 -24
- package/es/components/modal/src/components/Modal.d.ts +0 -201
- package/es/components/modal/src/components/ModalFooter.d.ts +0 -54
- package/es/components/modal/src/hooks/useDrag.d.ts +0 -6
- package/es/components/modal/src/hooks/useFullScreen.d.ts +0 -6
- package/es/components/modal/src/hooks/useModal.d.ts +0 -5
- package/es/components/modal/src/index.d.ts +0 -216
- package/es/components/modal/src/index.scss +0 -104
- package/es/components/modal/src/props.d.ts +0 -94
- package/es/components/modal/src/types/index.type.d.ts +0 -18
- package/es/components/source/index.d.ts +0 -2
- package/es/components/source/index.js +0 -448
- package/es/components/source/src/hooks/useDownload.d.ts +0 -8
- package/es/components/source/src/hooks/useSource.d.ts +0 -61
- package/es/components/source/src/types/source.type.d.ts +0 -34
- package/es/components/table/index.d.ts +0 -8
- package/es/components/table/index.js +0 -2356
- package/es/components/table/src/components/TableAction.d.ts +0 -75
- package/es/components/table/src/components/TableHeader.d.ts +0 -35
- package/es/components/table/src/components/TableRender.d.ts +0 -13
- package/es/components/table/src/components/editTable/CellComponent.d.ts +0 -22
- package/es/components/table/src/components/editTable/EditTableCell.d.ts +0 -52
- package/es/components/table/src/components/editTable/componentMap.d.ts +0 -4
- package/es/components/table/src/components/editTable/index.d.ts +0 -9
- package/es/components/table/src/components/editTable/props.d.ts +0 -27
- package/es/components/table/src/components/tableSetting/Column.d.ts +0 -4
- package/es/components/table/src/components/tableSetting/Download.d.ts +0 -11
- package/es/components/table/src/components/tableSetting/DownloadCtrl.d.ts +0 -2
- package/es/components/table/src/components/tableSetting/Fullscreen.d.ts +0 -2
- package/es/components/table/src/components/tableSetting/index.d.ts +0 -17
- package/es/components/table/src/hooks/useColumns.d.ts +0 -14
- package/es/components/table/src/hooks/useCustomRow.d.ts +0 -20
- package/es/components/table/src/hooks/useDataSource.d.ts +0 -14
- package/es/components/table/src/hooks/useHeader.d.ts +0 -8
- package/es/components/table/src/hooks/useHeaderCode.d.ts +0 -3
- package/es/components/table/src/hooks/useLoading.d.ts +0 -6
- package/es/components/table/src/hooks/usePagination.d.ts +0 -7
- package/es/components/table/src/hooks/useRowSelection.d.ts +0 -12
- package/es/components/table/src/hooks/useTable.d.ts +0 -9
- package/es/components/table/src/hooks/useTableInstance.d.ts +0 -16
- package/es/components/table/src/hooks/useTableScroll.d.ts +0 -12
- package/es/components/table/src/hooks/useTableStyle.d.ts +0 -5
- package/es/components/table/src/index.d.ts +0 -470
- package/es/components/table/src/index.scss +0 -310
- package/es/components/table/src/props.d.ts +0 -205
- package/es/components/table/src/types/actions.type.d.ts +0 -21
- package/es/components/table/src/types/header.type.d.ts +0 -23
- package/es/components/table/src/types/table.type.d.ts +0 -167
- package/es/components/tree/index.d.ts +0 -3
- package/es/components/tree/index.js +0 -1199
- package/es/components/tree/src/basicProps.d.ts +0 -190
- package/es/components/tree/src/components/ContextMenu.d.ts +0 -70
- package/es/components/tree/src/components/TreeHeader.d.ts +0 -78
- package/es/components/tree/src/hooks/useContextMenu.d.ts +0 -2
- package/es/components/tree/src/hooks/useMethod.d.ts +0 -16
- package/es/components/tree/src/hooks/useTree.d.ts +0 -5
- package/es/components/tree/src/index.d.ts +0 -300
- package/es/components/tree/src/index.scss +0 -178
- package/es/components/tree/src/types/action.type.d.ts +0 -64
- package/es/components/tree/src/types/menu.d.ts +0 -36
- package/es/components/tree/src/types/tree.d.ts +0 -31
- package/es/components/tree/src/utils/tree.d.ts +0 -7
- package/es/components/upload/index.d.ts +0 -4
- package/es/components/upload/index.js +0 -664
- package/es/components/upload/src/basicProps.d.ts +0 -95
- package/es/components/upload/src/components/PdfView.d.ts +0 -2
- package/es/components/upload/src/components/WordView.d.ts +0 -2
- package/es/components/upload/src/hooks/useFile.d.ts +0 -17
- package/es/components/upload/src/index.d.ts +0 -209
- package/es/components/upload/src/index.scss +0 -89
- package/es/components/upload/src/type/file.d.ts +0 -17
- package/es/components/upload/src/utils/fileSize.d.ts +0 -1
- package/es/components/upload/src/utils/upload.d.ts +0 -2
- package/es/components/vxe_table/index.d.ts +0 -4
- package/es/components/vxe_table/index.js +0 -1162
- package/es/components/vxe_table/src/components/AApiSelect.d.ts +0 -12
- package/es/components/vxe_table/src/components/AAutoComplete.d.ts +0 -2
- package/es/components/vxe_table/src/components/AButton.d.ts +0 -12
- package/es/components/vxe_table/src/components/AButtonGroup.d.ts +0 -2
- package/es/components/vxe_table/src/components/ACascader.d.ts +0 -2
- package/es/components/vxe_table/src/components/ACheckbox.d.ts +0 -2
- package/es/components/vxe_table/src/components/ACheckboxGroup.d.ts +0 -6
- package/es/components/vxe_table/src/components/ADatePicker.d.ts +0 -4
- package/es/components/vxe_table/src/components/AEmpty.d.ts +0 -6
- package/es/components/vxe_table/src/components/AInput.d.ts +0 -2
- package/es/components/vxe_table/src/components/AInputNumber.d.ts +0 -2
- package/es/components/vxe_table/src/components/AInputSearch.d.ts +0 -2
- package/es/components/vxe_table/src/components/AMonthPicker.d.ts +0 -2
- package/es/components/vxe_table/src/components/ARadioGroup.d.ts +0 -6
- package/es/components/vxe_table/src/components/ARangePicker.d.ts +0 -2
- package/es/components/vxe_table/src/components/ARate.d.ts +0 -2
- package/es/components/vxe_table/src/components/ASelect.d.ts +0 -2
- package/es/components/vxe_table/src/components/ASwitch.d.ts +0 -2
- package/es/components/vxe_table/src/components/ATimePicker.d.ts +0 -2
- package/es/components/vxe_table/src/components/ATreeSelect.d.ts +0 -2
- package/es/components/vxe_table/src/components/AWeekPicker.d.ts +0 -2
- package/es/components/vxe_table/src/components/AYearPicker.d.ts +0 -2
- package/es/components/vxe_table/src/components/Select.d.ts +0 -2
- package/es/components/vxe_table/src/components/common.d.ts +0 -52
- package/es/components/vxe_table/src/components/componentMap.d.ts +0 -3
- package/es/components/vxe_table/src/components/index.d.ts +0 -4
- package/es/components/vxe_table/src/hooks/useColumns.d.ts +0 -1
- package/es/components/vxe_table/src/hooks/useComponents.d.ts +0 -2
- package/es/components/vxe_table/src/hooks/useHeader.d.ts +0 -6
- package/es/components/vxe_table/src/hooks/useProps.d.ts +0 -3
- package/es/components/vxe_table/src/hooks/useVxeTable.d.ts +0 -7
- package/es/components/vxe_table/src/index.d.ts +0 -26
- package/es/components/vxe_table/src/index.scss +0 -13
- package/es/components/vxe_table/src/props.d.ts +0 -1
- package/es/components/vxe_table/src/types/componentType.d.ts +0 -1
- package/es/components/vxe_table/src/types/vxeTable.type.d.ts +0 -45
- package/es/components/vxe_table/src/utils/index.d.ts +0 -6
- package/es/directives/index.d.ts +0 -4
- package/es/directives/index.js +0 -30
- package/es/directives/permission.d.ts +0 -2
- package/es/theme/index.d.ts +0 -12
- package/es/theme/index.js +0 -3792
- package/es/theme/src/components/content/index.d.ts +0 -2
- package/es/theme/src/components/feature/BackTop.d.ts +0 -2
- package/es/theme/src/components/feature/index.d.ts +0 -2
- package/es/theme/src/components/footer/index.d.ts +0 -2
- package/es/theme/src/components/header/MultipleHeader.d.ts +0 -2
- package/es/theme/src/components/header/components/BreadCrumb.d.ts +0 -2
- package/es/theme/src/components/header/components/FullScreen.d.ts +0 -2
- package/es/theme/src/components/header/components/LangPicker.d.ts +0 -12
- package/es/theme/src/components/header/components/Logo.d.ts +0 -22
- package/es/theme/src/components/header/components/MenuFilter.d.ts +0 -2
- package/es/theme/src/components/header/components/Notice.d.ts +0 -2
- package/es/theme/src/components/header/components/SettintTheme.d.ts +0 -2
- package/es/theme/src/components/header/components/Size.d.ts +0 -2
- package/es/theme/src/components/header/components/Trigger.d.ts +0 -6
- package/es/theme/src/components/header/components/UserInfo.d.ts +0 -2
- package/es/theme/src/components/header/components/lock/Lockscreen.d.ts +0 -2
- package/es/theme/src/components/header/components/lock/useBattery.d.ts +0 -11
- package/es/theme/src/components/header/components/lock/useTime.d.ts +0 -7
- package/es/theme/src/components/header/components/theme-drawer/Color.d.ts +0 -26
- package/es/theme/src/components/header/components/theme-drawer/ColorPrimary.d.ts +0 -27
- package/es/theme/src/components/header/components/theme-drawer/Feature.d.ts +0 -2
- package/es/theme/src/components/header/components/theme-drawer/InputNumber.d.ts +0 -28
- package/es/theme/src/components/header/components/theme-drawer/MenuType.d.ts +0 -2
- package/es/theme/src/components/header/components/theme-drawer/Select.d.ts +0 -44
- package/es/theme/src/components/header/components/theme-drawer/Switch.d.ts +0 -29
- package/es/theme/src/components/header/components/theme-drawer/Var.d.ts +0 -2
- package/es/theme/src/components/header/components/theme-drawer/styles/GlobalStyle.d.ts +0 -2
- package/es/theme/src/components/header/components/theme-drawer/styles/MenuStyle.d.ts +0 -2
- package/es/theme/src/components/header/helper/changeTheme.d.ts +0 -15
- package/es/theme/src/components/header/helper/menuTree.d.ts +0 -4
- package/es/theme/src/components/header/index.d.ts +0 -8
- package/es/theme/src/components/sider/components/DragBar.d.ts +0 -2
- package/es/theme/src/components/sider/components/LayoutMenu.d.ts +0 -22
- package/es/theme/src/components/sider/components/MixSider.d.ts +0 -2
- package/es/theme/src/components/sider/components/SiderTrigger.d.ts +0 -14
- package/es/theme/src/components/sider/components/basic-menu/basic-menu-item.d.ts +0 -35
- package/es/theme/src/components/sider/components/basic-menu/basic-sub-menu-item.d.ts +0 -35
- package/es/theme/src/components/sider/components/basic-menu/index.d.ts +0 -64
- package/es/theme/src/components/sider/components/basic-menu/menu-item-content.d.ts +0 -22
- package/es/theme/src/components/sider/components/basic-menu/props.d.ts +0 -52
- package/es/theme/src/components/sider/helper/sider.d.ts +0 -12
- package/es/theme/src/components/sider/helper/split-menu.d.ts +0 -10
- package/es/theme/src/components/sider/index.d.ts +0 -2
- package/es/theme/src/components/tabs/components/TabContent.d.ts +0 -19
- package/es/theme/src/components/tabs/components/TabRedo.d.ts +0 -2
- package/es/theme/src/components/tabs/hooks/useMultifyTabs.d.ts +0 -7
- package/es/theme/src/components/tabs/hooks/useTabDropdown.d.ts +0 -14
- package/es/theme/src/components/tabs/hooks/useTabs.d.ts +0 -10
- package/es/theme/src/components/tabs/index.d.ts +0 -2
- package/es/theme/src/consts/color.d.ts +0 -3
- package/es/theme/src/consts/index.d.ts +0 -14
- package/es/theme/src/enums/index.d.ts +0 -34
- package/es/theme/src/hooks/index.d.ts +0 -6
- package/es/theme/src/hooks/useDragLine.d.ts +0 -2
- package/es/theme/src/hooks/useHeader.d.ts +0 -25
- package/es/theme/src/hooks/useMenu.d.ts +0 -29
- package/es/theme/src/hooks/useMultifyTab.d.ts +0 -8
- package/es/theme/src/hooks/useOpenKeys.d.ts +0 -7
- package/es/theme/src/hooks/useTheme.d.ts +0 -27
- package/es/theme/src/index.d.ts +0 -2
- package/es/theme/src/index.scss +0 -1134
- package/es/theme/src/stores/index.d.ts +0 -3
- package/es/theme/src/stores/routeReuse.store.d.ts +0 -23
- package/es/theme/src/stores/theme.store.d.ts +0 -13
- package/es/theme/src/transition.scss +0 -105
- package/es/theme/src/types/menu.type.d.ts +0 -16
- package/es/theme/src/types/theme.type.d.ts +0 -81
- package/es/theme/src/utils/color.d.ts +0 -14
- package/es/theme/src/utils/index.d.ts +0 -3
- package/es/theme/src/utils.ts/index.d.ts +0 -3
- package/index.js +0 -44
- package/manualContentPath.js +0 -192
- package/tsconfig.json +0 -31
- package/tsconfig.tsbuildinfo +0 -1
- package/vite.config.ts +0 -82
- /package/{es/theme/src/types/index.d.ts → dist/es/components/drawer/styles/index.scss} +0 -0
- /package/{es → dist/es}/components/tree/src/enums/index.d.ts +0 -0
- /package/{es/theme/src/stores → dist/es/layout/src/components/lockscreen}/lockscreen.store.d.ts +0 -0
package/es/theme/index.js
DELETED
|
@@ -1,3792 +0,0 @@
|
|
|
1
|
-
import { getLocal, CacheKey, deepMerge, setLocal, removeLocal, Language, Pages, useGo, useRedo, useI18n, getParentSlots, trim, useTimeoutFn, isFunction, isUrl, openWindow, localeList, changeLocale, copyText, isNullOrUnDef, useApp, withInstall } from "@dt-frames/core";
|
|
2
|
-
import { BackTop, Breadcrumb, MenuItem, SubMenu, Menu, Empty, InputSearch, Popover, Avatar, InputPassword, Button, Modal, Tooltip, Switch, Select, InputNumber, Divider, TabPane, Tabs, Drawer, LayoutHeader, LayoutSider, MenuDivider, Dropdown, LayoutContent, LayoutFooter, Layout, ConfigProvider } from "ant-design-vue/es";
|
|
3
|
-
import { ref, unref, computed, onMounted, nextTick, defineComponent, openBlock, createBlock, createCommentVNode, createElementBlock, normalizeClass, normalizeStyle, Fragment, createElementVNode, withDirectives, toDisplayString, vShow, watchEffect, withCtx, watch, createVNode, normalizeProps, guardReactiveProps, resolveComponent, mergeProps, renderList, reactive, toRef, isRef, createSlots, withKeys, createTextVNode, withModifiers, Transition, h, toRaw, toRefs, onUnmounted, KeepAlive, resolveDynamicComponent } from "vue";
|
|
4
|
-
import dayjs from "dayjs";
|
|
5
|
-
import "dayjs/locale/zh-cn";
|
|
6
|
-
import "dayjs/locale/es-us";
|
|
7
|
-
import { defineStore } from "pinia";
|
|
8
|
-
import { cloneDeep } from "lodash-es";
|
|
9
|
-
import zhCN from "ant-design-vue/es/locale/zh_CN";
|
|
10
|
-
import en from "ant-design-vue/es/locale/en_US";
|
|
11
|
-
import { useDebounceFn, useThrottleFn, useFullscreen } from "@vueuse/core";
|
|
12
|
-
import logoUrl from "../assets/imgs/logo/logo.png";
|
|
13
|
-
import { DtSlotContainer, DtScrollContainer } from "../components/container";
|
|
14
|
-
import { useRouter } from "vue-router";
|
|
15
|
-
import txUrl from "../assets/imgs/header/avatar.png";
|
|
16
|
-
import { Modal as Modal$1 } from "ant-design-vue";
|
|
17
|
-
var Theme = /* @__PURE__ */ ((Theme2) => {
|
|
18
|
-
Theme2["DARK"] = "dark";
|
|
19
|
-
Theme2["LIGHT"] = "light";
|
|
20
|
-
return Theme2;
|
|
21
|
-
})(Theme || {});
|
|
22
|
-
var MenuType = /* @__PURE__ */ ((MenuType2) => {
|
|
23
|
-
MenuType2["SIDE"] = "sidebar";
|
|
24
|
-
MenuType2["TOP_MENU"] = "top-menu";
|
|
25
|
-
MenuType2["MIX"] = "mix";
|
|
26
|
-
MenuType2["MIX_SIDEBAR"] = "mix-sidebar";
|
|
27
|
-
return MenuType2;
|
|
28
|
-
})(MenuType || {});
|
|
29
|
-
var MenuMode = /* @__PURE__ */ ((MenuMode2) => {
|
|
30
|
-
MenuMode2["INLINE"] = "inline";
|
|
31
|
-
MenuMode2["HORIZONTAL"] = "horizontal";
|
|
32
|
-
MenuMode2["VERTICAL"] = "vertical";
|
|
33
|
-
return MenuMode2;
|
|
34
|
-
})(MenuMode || {});
|
|
35
|
-
var ContentMode = /* @__PURE__ */ ((ContentMode2) => {
|
|
36
|
-
ContentMode2["FULL"] = "full";
|
|
37
|
-
ContentMode2["FIXED"] = "fixed";
|
|
38
|
-
return ContentMode2;
|
|
39
|
-
})(ContentMode || {});
|
|
40
|
-
var MenuSplitTye = /* @__PURE__ */ ((MenuSplitTye2) => {
|
|
41
|
-
MenuSplitTye2[MenuSplitTye2["NONE"] = 0] = "NONE";
|
|
42
|
-
MenuSplitTye2[MenuSplitTye2["TOP"] = 1] = "TOP";
|
|
43
|
-
MenuSplitTye2[MenuSplitTye2["LEFT"] = 2] = "LEFT";
|
|
44
|
-
return MenuSplitTye2;
|
|
45
|
-
})(MenuSplitTye || {});
|
|
46
|
-
var UiSize = /* @__PURE__ */ ((UiSize2) => {
|
|
47
|
-
UiSize2["LARGE"] = "large";
|
|
48
|
-
UiSize2["MIDDLE"] = "middle";
|
|
49
|
-
UiSize2["SMALL"] = "small";
|
|
50
|
-
return UiSize2;
|
|
51
|
-
})(UiSize || {});
|
|
52
|
-
const defaultThemeConf = {
|
|
53
|
-
vars: {
|
|
54
|
-
token: {
|
|
55
|
-
colorPrimary: "#269ac1",
|
|
56
|
-
borderRadiusLG: 8,
|
|
57
|
-
borderRadius: 5,
|
|
58
|
-
borderRadiusSM: 3,
|
|
59
|
-
controlHeightLG: 38,
|
|
60
|
-
controlHeight: 34,
|
|
61
|
-
controlHeightSM: 30,
|
|
62
|
-
colorTextBase: "#333"
|
|
63
|
-
},
|
|
64
|
-
components: {
|
|
65
|
-
Menu: {
|
|
66
|
-
colorItemBg: "#001529",
|
|
67
|
-
colorSubItemBg: "#00061a"
|
|
68
|
-
}
|
|
69
|
-
}
|
|
70
|
-
},
|
|
71
|
-
content: {
|
|
72
|
-
contentMode: ContentMode.FULL
|
|
73
|
-
},
|
|
74
|
-
headOptions: {
|
|
75
|
-
fixed: true,
|
|
76
|
-
theme: Theme.LIGHT,
|
|
77
|
-
showLogo: true,
|
|
78
|
-
showBackToTop: true,
|
|
79
|
-
useLockPage: true,
|
|
80
|
-
size: UiSize.SMALL,
|
|
81
|
-
showBreadCrumb: true,
|
|
82
|
-
showFullScreen: true,
|
|
83
|
-
showSearch: true,
|
|
84
|
-
showNotice: true,
|
|
85
|
-
showLocaleSwitch: true,
|
|
86
|
-
showSettingTheme: true,
|
|
87
|
-
showLoginOut: true
|
|
88
|
-
},
|
|
89
|
-
menuOptions: {
|
|
90
|
-
fixed: true,
|
|
91
|
-
theme: Theme.DARK,
|
|
92
|
-
collapsed: false,
|
|
93
|
-
collapsedShowTitle: false,
|
|
94
|
-
canDrag: true,
|
|
95
|
-
show: true,
|
|
96
|
-
hidden: false,
|
|
97
|
-
split: false,
|
|
98
|
-
menuWidth: 240,
|
|
99
|
-
trigger: true,
|
|
100
|
-
type: MenuType.SIDE,
|
|
101
|
-
mode: MenuMode.INLINE,
|
|
102
|
-
mixSideTrigger: "hover"
|
|
103
|
-
},
|
|
104
|
-
footerOptions: {
|
|
105
|
-
show: true,
|
|
106
|
-
title: "Copyright(C) 2021 by www.ithinkdt.com. All rights reserved.",
|
|
107
|
-
subTitle: "Privacy Statement"
|
|
108
|
-
},
|
|
109
|
-
routeReuse: {
|
|
110
|
-
show: true,
|
|
111
|
-
cache: false,
|
|
112
|
-
canDrag: true,
|
|
113
|
-
showQuick: true,
|
|
114
|
-
showRedo: true,
|
|
115
|
-
showFold: true
|
|
116
|
-
}
|
|
117
|
-
};
|
|
118
|
-
const useThemeStore = defineStore("dt-theme", () => {
|
|
119
|
-
const themeConf = ref(getLocal(CacheKey.THEME) ?? cloneDeep(defaultThemeConf));
|
|
120
|
-
const pageLoading = ref(false);
|
|
121
|
-
const mixSiderHasSubMenu = ref(false);
|
|
122
|
-
function setPrimayColor() {
|
|
123
|
-
if (unref(themeConf).vars.token.colorPrimary) {
|
|
124
|
-
document.getElementsByTagName("html")[0].style.cssText = `--colorPrimary: ${unref(themeConf).vars.token.colorPrimary};`;
|
|
125
|
-
}
|
|
126
|
-
}
|
|
127
|
-
function setThemeConf(conf = {}) {
|
|
128
|
-
themeConf.value = deepMerge(unref(themeConf), conf);
|
|
129
|
-
setPrimayColor();
|
|
130
|
-
setLocal(CacheKey.THEME, themeConf.value);
|
|
131
|
-
}
|
|
132
|
-
function setMixSiderIsHasMenu(val) {
|
|
133
|
-
mixSiderHasSubMenu.value = val;
|
|
134
|
-
}
|
|
135
|
-
function resetState() {
|
|
136
|
-
removeLocal(CacheKey.THEME);
|
|
137
|
-
themeConf.value = cloneDeep(defaultThemeConf);
|
|
138
|
-
}
|
|
139
|
-
return {
|
|
140
|
-
themeConf,
|
|
141
|
-
pageLoading,
|
|
142
|
-
mixSiderHasSubMenu,
|
|
143
|
-
setThemeConf,
|
|
144
|
-
setMixSiderIsHasMenu,
|
|
145
|
-
resetState
|
|
146
|
-
};
|
|
147
|
-
});
|
|
148
|
-
function useMenu() {
|
|
149
|
-
const { setThemeConf } = useThemeStore();
|
|
150
|
-
const getMenuConf = useThemeStore().themeConf.menuOptions;
|
|
151
|
-
const getCollapsedShowTitle = computed(() => getMenuConf.collapsedShowTitle);
|
|
152
|
-
const getIsSidebarType = computed(() => getMenuConf.type === MenuType.SIDE);
|
|
153
|
-
const getMenuFixed = computed(() => getMenuConf.fixed);
|
|
154
|
-
const getShowMenu = computed(() => getMenuConf.show);
|
|
155
|
-
const getSplit = computed(() => getMenuConf.split);
|
|
156
|
-
const getMenuMode = computed(() => getMenuConf.mode);
|
|
157
|
-
const getShowSidebar = computed(() => {
|
|
158
|
-
return unref(getSplit) || unref(getShowMenu) && unref(getMenuMode) !== MenuMode.HORIZONTAL;
|
|
159
|
-
});
|
|
160
|
-
const getMenuHidden = computed(() => getMenuConf.hidden);
|
|
161
|
-
const getMenuTheme = computed(() => getMenuConf.theme);
|
|
162
|
-
const getTrigger = computed(() => getMenuConf.trigger);
|
|
163
|
-
const getCanDrag = computed(() => getMenuConf.canDrag);
|
|
164
|
-
const getMenuType = computed(() => getMenuConf.type);
|
|
165
|
-
const getIsMixMode = computed(() => {
|
|
166
|
-
return unref(getMenuMode) === MenuMode.INLINE && unref(getMenuType) === MenuType.MIX;
|
|
167
|
-
});
|
|
168
|
-
const getIsMixSidebar = computed(() => {
|
|
169
|
-
const isMix = unref(getMenuType) === MenuType.MIX_SIDEBAR;
|
|
170
|
-
if (isMix) {
|
|
171
|
-
useThemeStore().setThemeConf({
|
|
172
|
-
menuOptions: {
|
|
173
|
-
collapsed: false
|
|
174
|
-
}
|
|
175
|
-
});
|
|
176
|
-
}
|
|
177
|
-
return isMix;
|
|
178
|
-
});
|
|
179
|
-
const getMenuWidth = computed(() => {
|
|
180
|
-
if (unref(getIsMixMode)) {
|
|
181
|
-
return Number(getMenuConf.menuWidth) - 40;
|
|
182
|
-
} else if (unref(getIsMixSidebar)) {
|
|
183
|
-
return Number(getMenuConf.menuWidth) - 10;
|
|
184
|
-
} else {
|
|
185
|
-
return Number(getMenuConf.menuWidth);
|
|
186
|
-
}
|
|
187
|
-
});
|
|
188
|
-
const getMixSideTrigger = computed(() => getMenuConf.mixSideTrigger);
|
|
189
|
-
const getLogoWidth = computed(() => unref(getIsMixSidebar) ? "80px" : getMenuConf.menuWidth);
|
|
190
|
-
const getIsTopMenu = computed(() => unref(getMenuType) === MenuType.TOP_MENU);
|
|
191
|
-
const getCollapsed = computed(() => getMenuConf.collapsed);
|
|
192
|
-
const getIsHorizontal = computed(() => unref(getMenuMode) === MenuMode.HORIZONTAL);
|
|
193
|
-
const getMiniWidthNumber = computed(() => getMenuConf.collapsedShowTitle ? 80 : 48);
|
|
194
|
-
const getRealWidth = computed(() => {
|
|
195
|
-
return unref(getCollapsed) ? unref(getMiniWidthNumber) : unref(getMenuWidth);
|
|
196
|
-
});
|
|
197
|
-
const getCalcContentWidth = computed(() => {
|
|
198
|
-
const width = unref(getIsTopMenu) || !unref(getShowMenu) || unref(getSplit) && unref(getMenuHidden) ? 0 : unref(getRealWidth);
|
|
199
|
-
return `calc(100% - ${unref(width)}px)`;
|
|
200
|
-
});
|
|
201
|
-
const setThemeStore = (conf = {}) => setThemeConf(conf);
|
|
202
|
-
const toggleCollapsed = () => setThemeStore({
|
|
203
|
-
menuOptions: {
|
|
204
|
-
collapsed: !unref(getCollapsed)
|
|
205
|
-
}
|
|
206
|
-
});
|
|
207
|
-
return {
|
|
208
|
-
getCollapsedShowTitle,
|
|
209
|
-
getIsSidebarType,
|
|
210
|
-
getMenuFixed,
|
|
211
|
-
getShowMenu,
|
|
212
|
-
getSplit,
|
|
213
|
-
getMenuMode,
|
|
214
|
-
getShowSidebar,
|
|
215
|
-
getMenuHidden,
|
|
216
|
-
getMenuTheme,
|
|
217
|
-
getTrigger,
|
|
218
|
-
getCanDrag,
|
|
219
|
-
getIsMixMode,
|
|
220
|
-
getMenuType,
|
|
221
|
-
getIsMixSidebar,
|
|
222
|
-
getMenuWidth,
|
|
223
|
-
getMixSideTrigger,
|
|
224
|
-
getLogoWidth,
|
|
225
|
-
getIsTopMenu,
|
|
226
|
-
getCollapsed,
|
|
227
|
-
getIsHorizontal,
|
|
228
|
-
getMiniWidthNumber,
|
|
229
|
-
getRealWidth,
|
|
230
|
-
getCalcContentWidth,
|
|
231
|
-
setThemeStore,
|
|
232
|
-
toggleCollapsed
|
|
233
|
-
};
|
|
234
|
-
}
|
|
235
|
-
function useMultipleTab() {
|
|
236
|
-
const getRouteConf = useThemeStore().themeConf.routeReuse;
|
|
237
|
-
const getShowMultipleTab = computed(() => getRouteConf.show);
|
|
238
|
-
const getShowQuick = computed(() => getRouteConf.showQuick);
|
|
239
|
-
const getMultipleTabPosIsTop = computed(() => getRouteConf.position === "top");
|
|
240
|
-
const getShowRedo = computed(() => getRouteConf.showRedo);
|
|
241
|
-
const getCanCache = computed(() => getRouteConf.cache);
|
|
242
|
-
const getCanDrag = computed(() => getRouteConf.canDrag);
|
|
243
|
-
return {
|
|
244
|
-
getShowMultipleTab,
|
|
245
|
-
getShowQuick,
|
|
246
|
-
getMultipleTabPosIsTop,
|
|
247
|
-
getShowRedo,
|
|
248
|
-
getCanCache,
|
|
249
|
-
getCanDrag
|
|
250
|
-
};
|
|
251
|
-
}
|
|
252
|
-
function useHeader() {
|
|
253
|
-
const HEADER_HEIGHT = 48;
|
|
254
|
-
const TABS_HEIGHT = 33;
|
|
255
|
-
const getHeaderConf = useThemeStore().themeConf.headOptions;
|
|
256
|
-
const {
|
|
257
|
-
getIsSidebarType,
|
|
258
|
-
getMenuType,
|
|
259
|
-
getShowMenu,
|
|
260
|
-
getMenuHidden,
|
|
261
|
-
getTrigger,
|
|
262
|
-
getMenuMode,
|
|
263
|
-
getSplit,
|
|
264
|
-
getIsTopMenu,
|
|
265
|
-
getIsMixSidebar
|
|
266
|
-
} = useMenu();
|
|
267
|
-
const { getShowMultipleTab, getMultipleTabPosIsTop } = useMultipleTab();
|
|
268
|
-
const getHeaderTheme = computed(() => getHeaderConf.theme);
|
|
269
|
-
const getFixed = computed(() => getHeaderConf.fixed);
|
|
270
|
-
const getShowLogo = computed(() => getHeaderConf.showLogo);
|
|
271
|
-
const getShowHeaderLogo = computed(() => unref(getShowLogo) && !unref(getIsSidebarType) && !unref(getIsMixSidebar));
|
|
272
|
-
const getShowSearch = computed(() => getHeaderConf.showSearch);
|
|
273
|
-
const getShowHeaderTrigger = computed(() => {
|
|
274
|
-
if (unref(getMenuType) === MenuType.TOP_MENU || unref(getMenuType) === MenuType.MIX_SIDEBAR || !unref(getShowMenu) || unref(getMenuHidden)) {
|
|
275
|
-
return false;
|
|
276
|
-
}
|
|
277
|
-
return unref(getTrigger);
|
|
278
|
-
});
|
|
279
|
-
const getShowBread = computed(
|
|
280
|
-
() => unref(getMenuMode) !== MenuMode.HORIZONTAL && !unref(getSplit) && getHeaderConf.showBreadCrumb
|
|
281
|
-
);
|
|
282
|
-
const getShowTopMenu = computed(() => unref(getMenuMode) === MenuMode.HORIZONTAL || unref(getSplit));
|
|
283
|
-
const getShowNotice = computed(() => getHeaderConf.showNotice);
|
|
284
|
-
const getShowFullScreen = computed(() => getHeaderConf.showFullScreen);
|
|
285
|
-
const getShowLocale = computed(() => getHeaderConf.showLocaleSwitch);
|
|
286
|
-
const getShowSettingTheme = computed(() => getHeaderConf.showSettingTheme);
|
|
287
|
-
const getShowFullHeaderRef = computed(() => {
|
|
288
|
-
return !unref(getIsSidebarType) && !unref(getIsMixSidebar) && !unref(getIsTopMenu);
|
|
289
|
-
});
|
|
290
|
-
const getHeaderHeight = computed(() => {
|
|
291
|
-
let height = 0;
|
|
292
|
-
height += HEADER_HEIGHT;
|
|
293
|
-
if (unref(getShowMultipleTab) && !unref(getSplit) && !unref(getMultipleTabPosIsTop)) {
|
|
294
|
-
height += TABS_HEIGHT;
|
|
295
|
-
}
|
|
296
|
-
return height;
|
|
297
|
-
});
|
|
298
|
-
const getTabsHeight = TABS_HEIGHT;
|
|
299
|
-
const getShowInsetHeaderRef = computed(() => {
|
|
300
|
-
return unref(getIsSidebarType) || unref(getIsTopMenu) || unref(getIsMixSidebar);
|
|
301
|
-
});
|
|
302
|
-
const getShowBackToTop = computed(() => getHeaderConf.showBackToTop);
|
|
303
|
-
const getIsZH = computed(() => {
|
|
304
|
-
let local = getLocal(CacheKey.LOCALE);
|
|
305
|
-
if (!local)
|
|
306
|
-
return true;
|
|
307
|
-
return local === Language.ZH;
|
|
308
|
-
});
|
|
309
|
-
const getUiSize = computed(() => getHeaderConf?.size ?? UiSize.SMALL);
|
|
310
|
-
const getShowLoginOut = computed(() => getHeaderConf.showLoginOut);
|
|
311
|
-
const getLockscreen = computed(() => getHeaderConf.useLockPage);
|
|
312
|
-
const loginOutClick = getHeaderConf.logoutClick;
|
|
313
|
-
return {
|
|
314
|
-
getHeaderTheme,
|
|
315
|
-
getFixed,
|
|
316
|
-
getShowHeaderLogo,
|
|
317
|
-
getShowLogo,
|
|
318
|
-
getShowSearch,
|
|
319
|
-
getShowHeaderTrigger,
|
|
320
|
-
getShowBread,
|
|
321
|
-
getShowTopMenu,
|
|
322
|
-
getShowNotice,
|
|
323
|
-
getShowFullScreen,
|
|
324
|
-
getShowLocale,
|
|
325
|
-
getShowSettingTheme,
|
|
326
|
-
getShowFullHeaderRef,
|
|
327
|
-
getHeaderHeight,
|
|
328
|
-
getTabsHeight,
|
|
329
|
-
getShowInsetHeaderRef,
|
|
330
|
-
getShowBackToTop,
|
|
331
|
-
getIsZH,
|
|
332
|
-
getUiSize,
|
|
333
|
-
getShowLoginOut,
|
|
334
|
-
getLockscreen,
|
|
335
|
-
loginOutClick
|
|
336
|
-
};
|
|
337
|
-
}
|
|
338
|
-
const LOCKSCREEN = "LOCKSCREEN_";
|
|
339
|
-
const useLockscreenStore = defineStore("lockscreen", () => {
|
|
340
|
-
const isLock = ref(getLocal(LOCKSCREEN)?.isLock === true);
|
|
341
|
-
function setLock(payload, pwd) {
|
|
342
|
-
isLock.value = payload;
|
|
343
|
-
let info = getLocal(LOCKSCREEN) ?? {};
|
|
344
|
-
if (pwd)
|
|
345
|
-
info.pwd = pwd;
|
|
346
|
-
setLocal(LOCKSCREEN, {
|
|
347
|
-
...info,
|
|
348
|
-
isLock
|
|
349
|
-
});
|
|
350
|
-
}
|
|
351
|
-
return {
|
|
352
|
-
isLock,
|
|
353
|
-
setLock
|
|
354
|
-
};
|
|
355
|
-
});
|
|
356
|
-
function handleGotoPage(router) {
|
|
357
|
-
const go = useGo(router);
|
|
358
|
-
go(unref(router.currentRoute).path, true);
|
|
359
|
-
}
|
|
360
|
-
const useRouteReuseStore = defineStore("route-reuse", () => {
|
|
361
|
-
let cacheTabList = /* @__PURE__ */ new Set();
|
|
362
|
-
const tabList = ref(getLocal(CacheKey.ROUTE_REUSE) || []);
|
|
363
|
-
const lastDragEndIndex = ref(0);
|
|
364
|
-
const getCachedTabList = computed(() => Array.from(cacheTabList));
|
|
365
|
-
function addTab(route) {
|
|
366
|
-
const { path, fullPath, params, query } = route;
|
|
367
|
-
if (path === Pages.NOT_FOUND || path === Pages.LOGIN || path === Pages.BASE_PAGE) {
|
|
368
|
-
return;
|
|
369
|
-
}
|
|
370
|
-
let updateIndex = -1;
|
|
371
|
-
const tabHasExits = unref(tabList).some((tab, index) => {
|
|
372
|
-
updateIndex = index;
|
|
373
|
-
return (tab.fullPath || tab.path) === (fullPath || path);
|
|
374
|
-
});
|
|
375
|
-
if (tabHasExits) {
|
|
376
|
-
const curTab = unref(tabList)[updateIndex];
|
|
377
|
-
curTab.params = params || curTab.params;
|
|
378
|
-
curTab.query = query || curTab.query;
|
|
379
|
-
curTab.fullPath = fullPath || curTab.fullPath;
|
|
380
|
-
unref(tabList).splice(updateIndex, 1, curTab);
|
|
381
|
-
} else {
|
|
382
|
-
unref(tabList).push(JSON.parse(JSON.stringify(route)));
|
|
383
|
-
}
|
|
384
|
-
updateCacheTab();
|
|
385
|
-
}
|
|
386
|
-
function closeTab(route, router) {
|
|
387
|
-
const go = useGo(router);
|
|
388
|
-
const index = unref(tabList).findIndex((item) => item.path === route.path);
|
|
389
|
-
let goPage = null;
|
|
390
|
-
if (index === 0) {
|
|
391
|
-
if (unref(tabList).length !== 1) {
|
|
392
|
-
goPage = unref(tabList)[index + 1];
|
|
393
|
-
}
|
|
394
|
-
} else {
|
|
395
|
-
goPage = unref(tabList)[index - 1];
|
|
396
|
-
}
|
|
397
|
-
bulkCloseTabs([route.path]);
|
|
398
|
-
updateCacheTab();
|
|
399
|
-
route.path === router.currentRoute.value.path && go(goPage.path);
|
|
400
|
-
}
|
|
401
|
-
function closeAllTab(currentRoute, router) {
|
|
402
|
-
const go = useGo(router);
|
|
403
|
-
const filterTabList = unref(tabList).filter((item) => item?.meta?.affix ?? false);
|
|
404
|
-
const route = filterTabList.length > 0 ? filterTabList[filterTabList.length - 1] : unref(currentRoute);
|
|
405
|
-
tabList.value = [route];
|
|
406
|
-
updateCacheTab();
|
|
407
|
-
go(route.path);
|
|
408
|
-
}
|
|
409
|
-
function closeLeftTabs(route, router) {
|
|
410
|
-
const index = unref(tabList).findIndex((item) => item.path === route.path);
|
|
411
|
-
if (index > 0) {
|
|
412
|
-
const leftTabs = unref(tabList).slice(0, index);
|
|
413
|
-
const pathList = [];
|
|
414
|
-
for (const item of leftTabs) {
|
|
415
|
-
const affix = item?.meta?.affix ?? false;
|
|
416
|
-
if (!affix) {
|
|
417
|
-
pathList.push(item.fullPath);
|
|
418
|
-
}
|
|
419
|
-
}
|
|
420
|
-
bulkCloseTabs(pathList);
|
|
421
|
-
}
|
|
422
|
-
updateCacheTab();
|
|
423
|
-
handleGotoPage(router);
|
|
424
|
-
}
|
|
425
|
-
function closeRightTabs(route, router) {
|
|
426
|
-
const index = unref(tabList).findIndex((item) => item.path === route.path);
|
|
427
|
-
if (index >= 0 && index < unref(tabList).length - 1) {
|
|
428
|
-
const rightTabs = unref(tabList).slice(index + 1, unref(tabList).length);
|
|
429
|
-
const pathList = [];
|
|
430
|
-
for (const item of rightTabs) {
|
|
431
|
-
const affix = item?.meta?.affix ?? false;
|
|
432
|
-
if (!affix) {
|
|
433
|
-
pathList.push(item.fullPath);
|
|
434
|
-
}
|
|
435
|
-
}
|
|
436
|
-
bulkCloseTabs(pathList);
|
|
437
|
-
}
|
|
438
|
-
updateCacheTab();
|
|
439
|
-
handleGotoPage(router);
|
|
440
|
-
}
|
|
441
|
-
function closeOtherTabs(route, router) {
|
|
442
|
-
const pathList = [];
|
|
443
|
-
for (let item of unref(tabList)) {
|
|
444
|
-
const affix = item?.meta?.affix ?? false;
|
|
445
|
-
if (item.path !== route.path && !affix) {
|
|
446
|
-
pathList.push(item.path);
|
|
447
|
-
}
|
|
448
|
-
}
|
|
449
|
-
bulkCloseTabs(pathList);
|
|
450
|
-
updateCacheTab();
|
|
451
|
-
handleGotoPage(router);
|
|
452
|
-
}
|
|
453
|
-
function closeTabByKey(path, router) {
|
|
454
|
-
const go = useGo(router);
|
|
455
|
-
const index = unref(tabList).findIndex((item) => item.path === path);
|
|
456
|
-
let page;
|
|
457
|
-
if (index === 0) {
|
|
458
|
-
if (unref(tabList).length !== 1) {
|
|
459
|
-
page = unref(tabList)[index + 1];
|
|
460
|
-
}
|
|
461
|
-
} else {
|
|
462
|
-
page = unref(tabList)[index - 1];
|
|
463
|
-
}
|
|
464
|
-
bulkCloseTabs([path]);
|
|
465
|
-
updateCacheTab();
|
|
466
|
-
path === router.currentRoute.value.path && go(page.path);
|
|
467
|
-
}
|
|
468
|
-
function updateCacheTab() {
|
|
469
|
-
setLocal(CacheKey.ROUTE_REUSE, unref(tabList));
|
|
470
|
-
const cacheMap = /* @__PURE__ */ new Set();
|
|
471
|
-
for (const tab of unref(tabList)) {
|
|
472
|
-
if (tab.meta?.hideTab) {
|
|
473
|
-
continue;
|
|
474
|
-
}
|
|
475
|
-
const name = tab.name;
|
|
476
|
-
cacheMap.add(name);
|
|
477
|
-
}
|
|
478
|
-
cacheTabList = cacheMap;
|
|
479
|
-
}
|
|
480
|
-
function bulkCloseTabs(pathList) {
|
|
481
|
-
tabList.value = unref(tabList).filter((item) => !pathList.includes(item.fullPath));
|
|
482
|
-
}
|
|
483
|
-
async function refreshPage(router) {
|
|
484
|
-
const findTab = unref(getCachedTabList).find((item) => item === unref(router.currentRoute).name);
|
|
485
|
-
if (findTab) {
|
|
486
|
-
unref(cacheTabList).delete(findTab.toString());
|
|
487
|
-
}
|
|
488
|
-
const redo = useRedo(router);
|
|
489
|
-
await redo();
|
|
490
|
-
}
|
|
491
|
-
function sortTabs(oldIndex, newIndex) {
|
|
492
|
-
const currentTab = unref(tabList)[oldIndex];
|
|
493
|
-
unref(tabList).splice(oldIndex, 1);
|
|
494
|
-
unref(tabList).splice(newIndex, 0, currentTab);
|
|
495
|
-
lastDragEndIndex.value = unref(lastDragEndIndex) + 1;
|
|
496
|
-
}
|
|
497
|
-
function resetState() {
|
|
498
|
-
tabList.value = [];
|
|
499
|
-
updateCacheTab();
|
|
500
|
-
}
|
|
501
|
-
return {
|
|
502
|
-
cacheTabList,
|
|
503
|
-
tabList,
|
|
504
|
-
lastDragEndIndex,
|
|
505
|
-
getCachedTabList,
|
|
506
|
-
addTab,
|
|
507
|
-
closeTab,
|
|
508
|
-
closeAllTab,
|
|
509
|
-
closeLeftTabs,
|
|
510
|
-
closeRightTabs,
|
|
511
|
-
closeOtherTabs,
|
|
512
|
-
closeTabByKey,
|
|
513
|
-
refreshPage,
|
|
514
|
-
sortTabs,
|
|
515
|
-
resetState
|
|
516
|
-
};
|
|
517
|
-
});
|
|
518
|
-
function useDragLine(siderRef, dragBarRef) {
|
|
519
|
-
const { getMiniWidthNumber, setThemeStore } = useMenu();
|
|
520
|
-
onMounted(() => {
|
|
521
|
-
nextTick(() => {
|
|
522
|
-
const exec = useDebounceFn(changeWrapWidth, 80);
|
|
523
|
-
exec();
|
|
524
|
-
});
|
|
525
|
-
});
|
|
526
|
-
function getEl(elRef) {
|
|
527
|
-
const el = unref(elRef);
|
|
528
|
-
if (!el)
|
|
529
|
-
return null;
|
|
530
|
-
if (Reflect.has(el, "$el")) {
|
|
531
|
-
return unref(elRef)?.$el;
|
|
532
|
-
}
|
|
533
|
-
return unref(elRef);
|
|
534
|
-
}
|
|
535
|
-
function handleMouseMove(ele, wrap, clientX) {
|
|
536
|
-
document.onmousemove = function(innerE) {
|
|
537
|
-
innerE = innerE || window.event;
|
|
538
|
-
let iT = ele.left + (innerE.clientX - clientX);
|
|
539
|
-
const maxT = 800;
|
|
540
|
-
const minT = unref(getMiniWidthNumber);
|
|
541
|
-
iT < 0 && (iT = 0);
|
|
542
|
-
iT > maxT && (iT = maxT);
|
|
543
|
-
iT < minT && (iT = minT);
|
|
544
|
-
ele.style.left = wrap.style.width = iT + "px";
|
|
545
|
-
return false;
|
|
546
|
-
};
|
|
547
|
-
}
|
|
548
|
-
function removeMouseup(ele) {
|
|
549
|
-
const wrap = getEl(siderRef);
|
|
550
|
-
document.onmouseup = function() {
|
|
551
|
-
document.onmousemove = null;
|
|
552
|
-
document.onmouseup = null;
|
|
553
|
-
wrap.style.transition = "width 0.2s";
|
|
554
|
-
const width = parseInt(wrap.style.width);
|
|
555
|
-
setThemeStore({
|
|
556
|
-
menuOptions: {
|
|
557
|
-
menuWidth: width
|
|
558
|
-
}
|
|
559
|
-
});
|
|
560
|
-
ele.releaseCapture?.();
|
|
561
|
-
};
|
|
562
|
-
}
|
|
563
|
-
function changeWrapWidth() {
|
|
564
|
-
const ele = getEl(dragBarRef);
|
|
565
|
-
if (!ele)
|
|
566
|
-
return;
|
|
567
|
-
const wrap = getEl(siderRef);
|
|
568
|
-
if (!wrap)
|
|
569
|
-
return;
|
|
570
|
-
ele.onmousedown = (e) => {
|
|
571
|
-
wrap.style.transition = "unset";
|
|
572
|
-
const clientX = e?.clientX;
|
|
573
|
-
ele.left = ele.offsetLeft;
|
|
574
|
-
handleMouseMove(ele, wrap, clientX);
|
|
575
|
-
removeMouseup(ele);
|
|
576
|
-
ele.setCapture?.();
|
|
577
|
-
return false;
|
|
578
|
-
};
|
|
579
|
-
}
|
|
580
|
-
}
|
|
581
|
-
function useTheme() {
|
|
582
|
-
const getThemeConf = useThemeStore().themeConf;
|
|
583
|
-
const getShowFooter = computed(() => getThemeConf.footerOptions.show);
|
|
584
|
-
const getContentMode = computed(() => getThemeConf.content.contentMode);
|
|
585
|
-
const getPageLoading = computed(() => useThemeStore().pageLoading);
|
|
586
|
-
const getLayoutContentMode = computed(() => getThemeConf.content.contentMode);
|
|
587
|
-
const getVars = computed(() => getThemeConf.vars);
|
|
588
|
-
return {
|
|
589
|
-
getShowFooter,
|
|
590
|
-
getContentMode,
|
|
591
|
-
getPageLoading,
|
|
592
|
-
getLayoutContentMode,
|
|
593
|
-
getVars
|
|
594
|
-
};
|
|
595
|
-
}
|
|
596
|
-
const _sfc_main$B = /* @__PURE__ */ defineComponent({
|
|
597
|
-
__name: "BackTop",
|
|
598
|
-
setup(__props) {
|
|
599
|
-
const getTarget = () => document.getElementById("dt-layout-content");
|
|
600
|
-
const { getShowBackToTop } = useHeader();
|
|
601
|
-
return (_ctx, _cache) => {
|
|
602
|
-
const _component_ABackTop = BackTop;
|
|
603
|
-
return unref(getShowBackToTop) ? (openBlock(), createBlock(_component_ABackTop, {
|
|
604
|
-
key: 0,
|
|
605
|
-
class: "dt-back-top",
|
|
606
|
-
target: getTarget,
|
|
607
|
-
visibilityHeight: 300
|
|
608
|
-
})) : createCommentVNode("", true);
|
|
609
|
-
};
|
|
610
|
-
}
|
|
611
|
-
});
|
|
612
|
-
const _sfc_main$A = /* @__PURE__ */ defineComponent({
|
|
613
|
-
__name: "index",
|
|
614
|
-
setup(__props) {
|
|
615
|
-
return (_ctx, _cache) => {
|
|
616
|
-
return openBlock(), createBlock(_sfc_main$B);
|
|
617
|
-
};
|
|
618
|
-
}
|
|
619
|
-
});
|
|
620
|
-
const _hoisted_1$k = ["src"];
|
|
621
|
-
const _sfc_main$z = /* @__PURE__ */ defineComponent({
|
|
622
|
-
__name: "Logo",
|
|
623
|
-
props: {
|
|
624
|
-
theme: { type: String, validator: (v) => ["light", "dark"].includes(v) },
|
|
625
|
-
showTitle: { type: Boolean, default: true }
|
|
626
|
-
},
|
|
627
|
-
setup(__props) {
|
|
628
|
-
const props = __props;
|
|
629
|
-
const { t } = useI18n("UI");
|
|
630
|
-
const { getLogoWidth } = useMenu();
|
|
631
|
-
const slots = getParentSlots(null, "dt-theme");
|
|
632
|
-
const getLogoClass = computed(() => {
|
|
633
|
-
return `${props.theme} dt-logo`;
|
|
634
|
-
});
|
|
635
|
-
return (_ctx, _cache) => {
|
|
636
|
-
return openBlock(), createElementBlock("div", {
|
|
637
|
-
class: normalizeClass([unref(getLogoClass), "h-12"]),
|
|
638
|
-
style: normalizeStyle({
|
|
639
|
-
minWidth: `${unref(getLogoWidth)}px`
|
|
640
|
-
})
|
|
641
|
-
}, [
|
|
642
|
-
unref(slots)?.logo ? (openBlock(), createBlock(unref(DtSlotContainer), {
|
|
643
|
-
key: 0,
|
|
644
|
-
template: unref(slots).logo
|
|
645
|
-
}, null, 8, ["template"])) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
646
|
-
createElementVNode("img", {
|
|
647
|
-
class: "w-8 h-8",
|
|
648
|
-
src: unref(logoUrl)
|
|
649
|
-
}, null, 8, _hoisted_1$k),
|
|
650
|
-
withDirectives(createElementVNode("div", { class: "dt-logo__title" }, toDisplayString(unref(t)("COMPANY_NAME")), 513), [
|
|
651
|
-
[vShow, __props.showTitle]
|
|
652
|
-
])
|
|
653
|
-
], 64))
|
|
654
|
-
], 6);
|
|
655
|
-
};
|
|
656
|
-
}
|
|
657
|
-
});
|
|
658
|
-
const _sfc_main$y = /* @__PURE__ */ defineComponent({
|
|
659
|
-
__name: "Trigger",
|
|
660
|
-
props: { theme: String },
|
|
661
|
-
setup(__props) {
|
|
662
|
-
const props = __props;
|
|
663
|
-
const { getCollapsed, toggleCollapsed } = useMenu();
|
|
664
|
-
return (_ctx, _cache) => {
|
|
665
|
-
return openBlock(), createElementBlock("div", {
|
|
666
|
-
class: normalizeClass(["flex pl-4 h-full cursor-pointer items-center justify-center", props.theme]),
|
|
667
|
-
onClick: _cache[0] || (_cache[0] = (...args) => unref(toggleCollapsed) && unref(toggleCollapsed)(...args))
|
|
668
|
-
}, [
|
|
669
|
-
createElementVNode("i", {
|
|
670
|
-
class: normalizeClass(["i", unref(getCollapsed) ? "ic:baseline-format-indent-increase" : "ic:baseline-format-indent-decrease"])
|
|
671
|
-
}, null, 2)
|
|
672
|
-
], 2);
|
|
673
|
-
};
|
|
674
|
-
}
|
|
675
|
-
});
|
|
676
|
-
function deleteChildrenProp(menu) {
|
|
677
|
-
let obj = { ...menu };
|
|
678
|
-
delete obj.children;
|
|
679
|
-
return obj;
|
|
680
|
-
}
|
|
681
|
-
function getBreadCrumb(path, menus) {
|
|
682
|
-
const _menus = menus || getLocal(CacheKey.MENUS)?.children || [];
|
|
683
|
-
let routes = [];
|
|
684
|
-
let getParentByPath = (menu, path2 = "") => {
|
|
685
|
-
if (menu.children && menu.children.length) {
|
|
686
|
-
menu.children.forEach((subMenu) => {
|
|
687
|
-
subMenu.parentMenus = [...menu.parentMenus].concat([deleteChildrenProp(subMenu)]);
|
|
688
|
-
getParentByPath(subMenu, path2);
|
|
689
|
-
});
|
|
690
|
-
}
|
|
691
|
-
if (menu.url === path2) {
|
|
692
|
-
routes = menu.parentMenus;
|
|
693
|
-
}
|
|
694
|
-
};
|
|
695
|
-
_menus.forEach((menu) => {
|
|
696
|
-
menu.parentMenus = [deleteChildrenProp(menu)];
|
|
697
|
-
getParentByPath(menu, path);
|
|
698
|
-
});
|
|
699
|
-
return routes;
|
|
700
|
-
}
|
|
701
|
-
function getFilterMenu(filter = "", flag = false) {
|
|
702
|
-
let _menus = [];
|
|
703
|
-
const { getIsZH } = useHeader();
|
|
704
|
-
if (!trim(filter) && !flag)
|
|
705
|
-
return _menus;
|
|
706
|
-
let getTargetMenus = (menusArr) => {
|
|
707
|
-
menusArr.forEach((menu) => {
|
|
708
|
-
if (menu.children && menu.children.length) {
|
|
709
|
-
getTargetMenus(menu.children);
|
|
710
|
-
} else {
|
|
711
|
-
let flabel = unref(getIsZH) ? menu.label : menu.enLabel?.toLowerCase();
|
|
712
|
-
let ffilter = unref(getIsZH) ? filter : filter.toLowerCase();
|
|
713
|
-
if (flabel.indexOf(ffilter) !== -1 || flag && !trim(filter)) {
|
|
714
|
-
_menus.push(menu);
|
|
715
|
-
}
|
|
716
|
-
}
|
|
717
|
-
});
|
|
718
|
-
};
|
|
719
|
-
getTargetMenus(getLocal(CacheKey.MENUS)?.children);
|
|
720
|
-
return _menus;
|
|
721
|
-
}
|
|
722
|
-
function getParentTreeByPath(path) {
|
|
723
|
-
const _menus = getLocal(CacheKey.MENUS)?.children || [];
|
|
724
|
-
let routes = [];
|
|
725
|
-
let getParentByPath = (menu, path2 = "") => {
|
|
726
|
-
if (menu.children && menu.children.length) {
|
|
727
|
-
menu.children.forEach((subMenu) => {
|
|
728
|
-
subMenu.parentMenus = [...menu.parentMenus].concat([subMenu]);
|
|
729
|
-
getParentByPath(subMenu, path2);
|
|
730
|
-
});
|
|
731
|
-
}
|
|
732
|
-
if (menu.url === path2) {
|
|
733
|
-
routes = menu.parentMenus;
|
|
734
|
-
}
|
|
735
|
-
};
|
|
736
|
-
_menus.forEach((menu) => {
|
|
737
|
-
menu.parentMenus = [menu];
|
|
738
|
-
getParentByPath(menu, path);
|
|
739
|
-
});
|
|
740
|
-
return routes.length ? routes[0] : { id: null, children: [], icon: "", label: "" };
|
|
741
|
-
}
|
|
742
|
-
const _sfc_main$x = /* @__PURE__ */ defineComponent({
|
|
743
|
-
__name: "BreadCrumb",
|
|
744
|
-
setup(__props) {
|
|
745
|
-
const { getIsZH } = useHeader();
|
|
746
|
-
const routes = ref([]);
|
|
747
|
-
const { currentRoute = null } = useRouter();
|
|
748
|
-
watchEffect(() => {
|
|
749
|
-
if (!currentRoute || currentRoute.value.path === "/")
|
|
750
|
-
return;
|
|
751
|
-
const { meta, path } = unref(currentRoute);
|
|
752
|
-
let activePath = meta?.currentActiveMenu || path;
|
|
753
|
-
routes.value = getBreadCrumb(activePath);
|
|
754
|
-
});
|
|
755
|
-
return (_ctx, _cache) => {
|
|
756
|
-
const _component_ABreadcrumb = Breadcrumb;
|
|
757
|
-
return openBlock(), createBlock(_component_ABreadcrumb, {
|
|
758
|
-
class: "pl-4",
|
|
759
|
-
routes: unref(routes)
|
|
760
|
-
}, {
|
|
761
|
-
itemRender: withCtx(({ route }) => [
|
|
762
|
-
createElementVNode("span", null, toDisplayString((unref(getIsZH) ? route.label : route.enLabel) || route.meta?.title), 1)
|
|
763
|
-
]),
|
|
764
|
-
_: 1
|
|
765
|
-
}, 8, ["routes"]);
|
|
766
|
-
};
|
|
767
|
-
}
|
|
768
|
-
});
|
|
769
|
-
function useSplitMenu(splitType) {
|
|
770
|
-
const menusRef = ref([]);
|
|
771
|
-
const { currentRoute } = useRouter();
|
|
772
|
-
const { menusMap } = getMenusMap();
|
|
773
|
-
const { getIsHorizontal, getSplit } = useMenu();
|
|
774
|
-
const throttleHandleSplitLeftMenu = useThrottleFn(handleSplitLeftMenu, 50);
|
|
775
|
-
const splitNotLeft = computed(
|
|
776
|
-
() => unref(splitType) !== MenuSplitTye.LEFT && !unref(getIsHorizontal)
|
|
777
|
-
);
|
|
778
|
-
const getSplitLeft = computed(
|
|
779
|
-
() => !unref(getSplit) || unref(splitType) !== MenuSplitTye.LEFT
|
|
780
|
-
);
|
|
781
|
-
const getSplitTop = computed(
|
|
782
|
-
() => unref(splitType) === MenuSplitTye.TOP
|
|
783
|
-
);
|
|
784
|
-
const normalType = computed(
|
|
785
|
-
() => !unref(getSplit) || unref(splitType) === MenuSplitTye.NONE
|
|
786
|
-
);
|
|
787
|
-
watch(
|
|
788
|
-
[() => unref(currentRoute)?.path, () => unref(splitType)],
|
|
789
|
-
([path]) => {
|
|
790
|
-
if (unref(splitNotLeft))
|
|
791
|
-
return;
|
|
792
|
-
throttleHandleSplitLeftMenu(path);
|
|
793
|
-
},
|
|
794
|
-
{
|
|
795
|
-
immediate: true
|
|
796
|
-
}
|
|
797
|
-
);
|
|
798
|
-
watch(
|
|
799
|
-
() => getSplit.value,
|
|
800
|
-
() => {
|
|
801
|
-
if (unref(splitNotLeft))
|
|
802
|
-
return;
|
|
803
|
-
getMenus2();
|
|
804
|
-
}
|
|
805
|
-
);
|
|
806
|
-
function handleSplitLeftMenu(path) {
|
|
807
|
-
if (unref(getSplitLeft))
|
|
808
|
-
return;
|
|
809
|
-
menusRef.value = menusMap.filter((it) => it.includesPath.includes(path))[0]?.children;
|
|
810
|
-
}
|
|
811
|
-
async function getMenus2() {
|
|
812
|
-
if (unref(normalType)) {
|
|
813
|
-
menusRef.value = getLocal(CacheKey.MENUS)?.children;
|
|
814
|
-
return;
|
|
815
|
-
}
|
|
816
|
-
if (unref(getSplitTop)) {
|
|
817
|
-
menusRef.value = await getShallowMenus();
|
|
818
|
-
}
|
|
819
|
-
}
|
|
820
|
-
getMenus2();
|
|
821
|
-
return { menusRef };
|
|
822
|
-
}
|
|
823
|
-
function getMenus() {
|
|
824
|
-
return getLocal(CacheKey.MENUS)?.children;
|
|
825
|
-
}
|
|
826
|
-
function getFirstMenuPath(item) {
|
|
827
|
-
let isFind = false, path = "";
|
|
828
|
-
const getPath = (menu) => {
|
|
829
|
-
if (isFind)
|
|
830
|
-
return;
|
|
831
|
-
if (menu.children && menu.children.length) {
|
|
832
|
-
menu.children.forEach((node) => getPath(node));
|
|
833
|
-
} else {
|
|
834
|
-
path = menu.url;
|
|
835
|
-
isFind = true;
|
|
836
|
-
}
|
|
837
|
-
};
|
|
838
|
-
getPath(item);
|
|
839
|
-
return path;
|
|
840
|
-
}
|
|
841
|
-
function getMenusMap() {
|
|
842
|
-
const menus = getMenus();
|
|
843
|
-
const menusMap = [];
|
|
844
|
-
const getPaths = (menu, path) => {
|
|
845
|
-
if (menu.children && menu.children.length) {
|
|
846
|
-
menu.children.forEach((node) => getPaths(node, path));
|
|
847
|
-
} else {
|
|
848
|
-
path.push(menu.url);
|
|
849
|
-
}
|
|
850
|
-
return path;
|
|
851
|
-
};
|
|
852
|
-
(menus || []).map((item) => {
|
|
853
|
-
item.url = getFirstMenuPath(item);
|
|
854
|
-
menusMap.push({
|
|
855
|
-
parentPath: item.url,
|
|
856
|
-
children: item.children || [],
|
|
857
|
-
includesPath: getPaths(item, [])
|
|
858
|
-
});
|
|
859
|
-
});
|
|
860
|
-
return { menusMap };
|
|
861
|
-
}
|
|
862
|
-
function getShallowMenus() {
|
|
863
|
-
const menus = getMenus();
|
|
864
|
-
const shallowMenuList = menus.map((item) => {
|
|
865
|
-
item.url = getFirstMenuPath(item);
|
|
866
|
-
return { ...item, children: void 0 };
|
|
867
|
-
});
|
|
868
|
-
return shallowMenuList;
|
|
869
|
-
}
|
|
870
|
-
const BasicMenu = {
|
|
871
|
-
items: {
|
|
872
|
-
type: Array
|
|
873
|
-
},
|
|
874
|
-
collapsedShowTitle: Boolean,
|
|
875
|
-
inlineIndent: {
|
|
876
|
-
default: 20
|
|
877
|
-
},
|
|
878
|
-
mode: {
|
|
879
|
-
type: String,
|
|
880
|
-
default: MenuMode.INLINE
|
|
881
|
-
},
|
|
882
|
-
type: {
|
|
883
|
-
type: String,
|
|
884
|
-
default: MenuType.SIDE
|
|
885
|
-
},
|
|
886
|
-
theme: {
|
|
887
|
-
default: Theme.DARK
|
|
888
|
-
},
|
|
889
|
-
inlineCollapsed: Boolean,
|
|
890
|
-
isHorizontal: Boolean,
|
|
891
|
-
beforeClickFn: {
|
|
892
|
-
type: Function
|
|
893
|
-
},
|
|
894
|
-
mixSider: Boolean
|
|
895
|
-
};
|
|
896
|
-
const contentProps = {
|
|
897
|
-
item: {
|
|
898
|
-
type: Object,
|
|
899
|
-
default: {}
|
|
900
|
-
},
|
|
901
|
-
showTitle: Boolean,
|
|
902
|
-
level: Number,
|
|
903
|
-
isHorizontal: Boolean
|
|
904
|
-
};
|
|
905
|
-
const ItemProp = {
|
|
906
|
-
item: {
|
|
907
|
-
type: Object,
|
|
908
|
-
default: {}
|
|
909
|
-
},
|
|
910
|
-
theme: {
|
|
911
|
-
type: String,
|
|
912
|
-
default: Theme.DARK
|
|
913
|
-
},
|
|
914
|
-
isHorizontal: Boolean,
|
|
915
|
-
showTitle: Boolean,
|
|
916
|
-
beforeClickFn: {
|
|
917
|
-
type: Function
|
|
918
|
-
}
|
|
919
|
-
};
|
|
920
|
-
function useOpenKeys(menuState, menus, type) {
|
|
921
|
-
function setOpenKeys(path) {
|
|
922
|
-
if (type === MenuType.TOP_MENU)
|
|
923
|
-
return;
|
|
924
|
-
useTimeoutFn(
|
|
925
|
-
() => {
|
|
926
|
-
if (menus?.length === 0) {
|
|
927
|
-
menuState.openKeys = [];
|
|
928
|
-
return;
|
|
929
|
-
}
|
|
930
|
-
const parentNodes = getBreadCrumb(path, menus);
|
|
931
|
-
menuState.openKeys = parentNodes.map((it) => it.id);
|
|
932
|
-
},
|
|
933
|
-
20,
|
|
934
|
-
true
|
|
935
|
-
);
|
|
936
|
-
}
|
|
937
|
-
const getOpenKeys = computed(() => menuState.openKeys);
|
|
938
|
-
function resetKeys() {
|
|
939
|
-
menuState.selectedKeys = [];
|
|
940
|
-
menuState.openKeys = [];
|
|
941
|
-
}
|
|
942
|
-
function handleOpenChange(openKeys) {
|
|
943
|
-
menuState.openKeys = openKeys;
|
|
944
|
-
}
|
|
945
|
-
return {
|
|
946
|
-
getOpenKeys,
|
|
947
|
-
setOpenKeys,
|
|
948
|
-
resetKeys,
|
|
949
|
-
handleOpenChange
|
|
950
|
-
};
|
|
951
|
-
}
|
|
952
|
-
const _sfc_main$w = /* @__PURE__ */ defineComponent({
|
|
953
|
-
__name: "menu-item-content",
|
|
954
|
-
props: contentProps,
|
|
955
|
-
setup(__props) {
|
|
956
|
-
const { getIsZH, getUiSize } = useHeader();
|
|
957
|
-
return (_ctx, _cache) => {
|
|
958
|
-
return openBlock(), createElementBlock("span", {
|
|
959
|
-
class: normalizeClass(["items-center dt-menu-item h-full flex", unref(getUiSize)])
|
|
960
|
-
}, [
|
|
961
|
-
createElementVNode("i", {
|
|
962
|
-
class: normalizeClass(["menu-icon i mr-2", _ctx.item.icon])
|
|
963
|
-
}, null, 2),
|
|
964
|
-
createElementVNode("span", null, toDisplayString(unref(getIsZH) ? _ctx.item.label : _ctx.item.enLabel), 1)
|
|
965
|
-
], 2);
|
|
966
|
-
};
|
|
967
|
-
}
|
|
968
|
-
});
|
|
969
|
-
const _sfc_main$v = /* @__PURE__ */ defineComponent({
|
|
970
|
-
__name: "basic-menu-item",
|
|
971
|
-
props: ItemProp,
|
|
972
|
-
setup(__props) {
|
|
973
|
-
const props = __props;
|
|
974
|
-
return (_ctx, _cache) => {
|
|
975
|
-
const _component_AMenuItem = MenuItem;
|
|
976
|
-
return openBlock(), createBlock(_component_AMenuItem, {
|
|
977
|
-
key: _ctx.item.url
|
|
978
|
-
}, {
|
|
979
|
-
default: withCtx(() => [
|
|
980
|
-
createVNode(_sfc_main$w, normalizeProps(guardReactiveProps(props)), null, 16)
|
|
981
|
-
]),
|
|
982
|
-
_: 1
|
|
983
|
-
});
|
|
984
|
-
};
|
|
985
|
-
}
|
|
986
|
-
});
|
|
987
|
-
const _sfc_main$u = /* @__PURE__ */ defineComponent({
|
|
988
|
-
__name: "basic-sub-menu-item",
|
|
989
|
-
props: ItemProp,
|
|
990
|
-
setup(__props) {
|
|
991
|
-
const props = __props;
|
|
992
|
-
const { getShowMenu } = useMenu();
|
|
993
|
-
const {
|
|
994
|
-
theme,
|
|
995
|
-
item
|
|
996
|
-
} = props;
|
|
997
|
-
const menuHasChildren = (menu) => {
|
|
998
|
-
return !!menu.children && menu.children.length > 0;
|
|
999
|
-
};
|
|
1000
|
-
return (_ctx, _cache) => {
|
|
1001
|
-
const _component_BasicSubMenuItem = resolveComponent("BasicSubMenuItem", true);
|
|
1002
|
-
const _component_ASubMenu = SubMenu;
|
|
1003
|
-
return openBlock(), createElementBlock(Fragment, null, [
|
|
1004
|
-
!menuHasChildren(unref(item)) && unref(getShowMenu) ? (openBlock(), createBlock(_sfc_main$v, normalizeProps(mergeProps({ key: 0 }, props)), null, 16)) : createCommentVNode("", true),
|
|
1005
|
-
menuHasChildren(unref(item)) && unref(getShowMenu) ? (openBlock(), createBlock(_component_ASubMenu, {
|
|
1006
|
-
class: normalizeClass([unref(theme)]),
|
|
1007
|
-
key: unref(item).id,
|
|
1008
|
-
popupClassName: "app-top-menu-popup"
|
|
1009
|
-
}, {
|
|
1010
|
-
title: withCtx(() => [
|
|
1011
|
-
createVNode(_sfc_main$w, mergeProps(props, { item: unref(item) }), null, 16, ["item"])
|
|
1012
|
-
]),
|
|
1013
|
-
default: withCtx(() => [
|
|
1014
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(item).children, (childrenItem) => {
|
|
1015
|
-
return openBlock(), createBlock(_component_BasicSubMenuItem, mergeProps({
|
|
1016
|
-
key: childrenItem.id
|
|
1017
|
-
}, props, { item: childrenItem }), null, 16, ["item"]);
|
|
1018
|
-
}), 128))
|
|
1019
|
-
]),
|
|
1020
|
-
_: 1
|
|
1021
|
-
}, 8, ["class"])) : createCommentVNode("", true)
|
|
1022
|
-
], 64);
|
|
1023
|
-
};
|
|
1024
|
-
}
|
|
1025
|
-
});
|
|
1026
|
-
const _sfc_main$t = /* @__PURE__ */ defineComponent({
|
|
1027
|
-
__name: "index",
|
|
1028
|
-
props: BasicMenu,
|
|
1029
|
-
emits: ["menuClick"],
|
|
1030
|
-
setup(__props, { emit: emits }) {
|
|
1031
|
-
const {
|
|
1032
|
-
theme,
|
|
1033
|
-
items,
|
|
1034
|
-
mode,
|
|
1035
|
-
type,
|
|
1036
|
-
isHorizontal,
|
|
1037
|
-
inlineIndent,
|
|
1038
|
-
mixSider,
|
|
1039
|
-
beforeClickFn
|
|
1040
|
-
} = __props;
|
|
1041
|
-
const { getSplit } = useMenu();
|
|
1042
|
-
const { getCollapsed } = useMenu();
|
|
1043
|
-
const getInlineCollapsed = computed(() => {
|
|
1044
|
-
const isInline = unref(mode) === MenuMode.INLINE;
|
|
1045
|
-
if (isInline) {
|
|
1046
|
-
return mixSider ? false : unref(getCollapsed);
|
|
1047
|
-
}
|
|
1048
|
-
return false;
|
|
1049
|
-
});
|
|
1050
|
-
const { currentRoute } = useRouter();
|
|
1051
|
-
const menuState = reactive({
|
|
1052
|
-
defaultSelectedKeys: [],
|
|
1053
|
-
openKeys: [],
|
|
1054
|
-
selectedKeys: [],
|
|
1055
|
-
collapsedOpenKeys: []
|
|
1056
|
-
});
|
|
1057
|
-
const { handleOpenChange, setOpenKeys } = useOpenKeys(
|
|
1058
|
-
menuState,
|
|
1059
|
-
items,
|
|
1060
|
-
type
|
|
1061
|
-
);
|
|
1062
|
-
watch(
|
|
1063
|
-
() => currentRoute.value.path,
|
|
1064
|
-
(val) => {
|
|
1065
|
-
if (val === "/")
|
|
1066
|
-
return;
|
|
1067
|
-
const { meta, path } = unref(currentRoute);
|
|
1068
|
-
let activePath = meta?.currentActiveMenu || path;
|
|
1069
|
-
handleMenuChange(activePath);
|
|
1070
|
-
},
|
|
1071
|
-
{
|
|
1072
|
-
immediate: true
|
|
1073
|
-
}
|
|
1074
|
-
);
|
|
1075
|
-
function handleMenuChange(path) {
|
|
1076
|
-
setOpenKeys(path);
|
|
1077
|
-
if (isHorizontal && unref(getSplit)) {
|
|
1078
|
-
const parentPath = getBreadCrumb(path, items);
|
|
1079
|
-
menuState.selectedKeys = [parentPath?.[0]?.url];
|
|
1080
|
-
} else {
|
|
1081
|
-
const parentPaths = getBreadCrumb(path);
|
|
1082
|
-
menuState.selectedKeys = parentPaths.reduce((keys, it) => {
|
|
1083
|
-
it.url && keys.push(it.url);
|
|
1084
|
-
return keys;
|
|
1085
|
-
}, []);
|
|
1086
|
-
}
|
|
1087
|
-
}
|
|
1088
|
-
async function handleMenuClick(item) {
|
|
1089
|
-
if (beforeClickFn && isFunction(beforeClickFn)) {
|
|
1090
|
-
const flag = await beforeClickFn(item.key);
|
|
1091
|
-
if (!flag)
|
|
1092
|
-
return;
|
|
1093
|
-
}
|
|
1094
|
-
emits("menuClick", item.key);
|
|
1095
|
-
menuState.selectedKeys = [item.key];
|
|
1096
|
-
}
|
|
1097
|
-
return (_ctx, _cache) => {
|
|
1098
|
-
const _component_AMenu = Menu;
|
|
1099
|
-
return openBlock(), createBlock(_component_AMenu, {
|
|
1100
|
-
theme: _ctx.theme,
|
|
1101
|
-
selectedKeys: unref(menuState).selectedKeys,
|
|
1102
|
-
defaultSelectedKeys: unref(menuState).defaultSelectedKeys,
|
|
1103
|
-
openKeys: unref(menuState).openKeys,
|
|
1104
|
-
inlineIndent: _ctx.inlineIndent,
|
|
1105
|
-
subMenuOpenDelay: 0.2,
|
|
1106
|
-
mode: _ctx.mode,
|
|
1107
|
-
collapsible: "",
|
|
1108
|
-
onClick: handleMenuClick,
|
|
1109
|
-
onOpenChange: unref(handleOpenChange),
|
|
1110
|
-
collapsed: unref(getInlineCollapsed),
|
|
1111
|
-
class: normalizeClass(unref(getSplit) ? "dt-split-menu" : "")
|
|
1112
|
-
}, {
|
|
1113
|
-
default: withCtx(() => [
|
|
1114
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.items, (item) => {
|
|
1115
|
-
return openBlock(), createBlock(_sfc_main$u, {
|
|
1116
|
-
key: item.id,
|
|
1117
|
-
item,
|
|
1118
|
-
theme: _ctx.theme,
|
|
1119
|
-
isHorizontal: _ctx.isHorizontal
|
|
1120
|
-
}, null, 8, ["item", "theme", "isHorizontal"]);
|
|
1121
|
-
}), 128))
|
|
1122
|
-
]),
|
|
1123
|
-
_: 1
|
|
1124
|
-
}, 8, ["theme", "selectedKeys", "defaultSelectedKeys", "openKeys", "inlineIndent", "mode", "onOpenChange", "collapsed", "class"]);
|
|
1125
|
-
};
|
|
1126
|
-
}
|
|
1127
|
-
});
|
|
1128
|
-
const _sfc_main$s = /* @__PURE__ */ defineComponent({
|
|
1129
|
-
name: "LayoutMenu",
|
|
1130
|
-
props: {
|
|
1131
|
-
theme: String,
|
|
1132
|
-
splitType: {
|
|
1133
|
-
type: Number,
|
|
1134
|
-
default: MenuSplitTye.NONE
|
|
1135
|
-
},
|
|
1136
|
-
isHorizontal: Boolean,
|
|
1137
|
-
menuMode: String
|
|
1138
|
-
},
|
|
1139
|
-
setup(props) {
|
|
1140
|
-
const {
|
|
1141
|
-
getMenuTheme,
|
|
1142
|
-
getMenuMode,
|
|
1143
|
-
getIsSidebarType,
|
|
1144
|
-
getIsHorizontal,
|
|
1145
|
-
getCollapsed,
|
|
1146
|
-
getCollapsedShowTitle,
|
|
1147
|
-
getMenuType
|
|
1148
|
-
} = useMenu();
|
|
1149
|
-
const {
|
|
1150
|
-
getShowLogo
|
|
1151
|
-
} = useHeader();
|
|
1152
|
-
const {
|
|
1153
|
-
menusRef
|
|
1154
|
-
} = useSplitMenu(toRef(props, "splitType"));
|
|
1155
|
-
const slots = getParentSlots(null, "dt-theme");
|
|
1156
|
-
const getComputedTheme = computed(() => props.theme || unref(getMenuTheme));
|
|
1157
|
-
const getComputedMenuMode = computed(() => props.menuMode || unref(getMenuMode));
|
|
1158
|
-
const getIsShowLogo = computed(() => unref(getShowLogo) && unref(getIsSidebarType));
|
|
1159
|
-
const getUseScroll = computed(() => {
|
|
1160
|
-
return !unref(getIsHorizontal) && (unref(getIsSidebarType) || props.splitType === MenuSplitTye.LEFT || props.splitType === MenuSplitTye.NONE);
|
|
1161
|
-
});
|
|
1162
|
-
const getLogoClass = computed(() => [`dt-menu-logo`, unref(getComputedTheme)]);
|
|
1163
|
-
const getMenuProps = computed(() => {
|
|
1164
|
-
const menus = unref(menusRef);
|
|
1165
|
-
return {
|
|
1166
|
-
menus,
|
|
1167
|
-
beforeClickFn: beforeMenuClickFn,
|
|
1168
|
-
items: menus,
|
|
1169
|
-
theme: unref(getComputedTheme),
|
|
1170
|
-
collapse: unref(getCollapsed),
|
|
1171
|
-
collapsedShowTitle: unref(getCollapsedShowTitle),
|
|
1172
|
-
onMenuClick: handleMenuClick
|
|
1173
|
-
};
|
|
1174
|
-
});
|
|
1175
|
-
function beforeMenuClickFn(path) {
|
|
1176
|
-
if (!isUrl(path)) {
|
|
1177
|
-
return true;
|
|
1178
|
-
}
|
|
1179
|
-
openWindow(path);
|
|
1180
|
-
return false;
|
|
1181
|
-
}
|
|
1182
|
-
const go = useGo();
|
|
1183
|
-
function handleMenuClick(path) {
|
|
1184
|
-
go(path);
|
|
1185
|
-
}
|
|
1186
|
-
function renderHeader() {
|
|
1187
|
-
if (!unref(getIsShowLogo))
|
|
1188
|
-
return null;
|
|
1189
|
-
if (slots?.logo) {
|
|
1190
|
-
return createVNode(DtSlotContainer, {
|
|
1191
|
-
"template": slots?.logo,
|
|
1192
|
-
"data": {
|
|
1193
|
-
theme: unref(getComputedTheme),
|
|
1194
|
-
collapsed: unref(getCollapsed)
|
|
1195
|
-
}
|
|
1196
|
-
}, null);
|
|
1197
|
-
}
|
|
1198
|
-
return createVNode(_sfc_main$z, {
|
|
1199
|
-
"showTitle": !unref(getCollapsed),
|
|
1200
|
-
"class": unref(getLogoClass),
|
|
1201
|
-
"theme": unref(getComputedTheme)
|
|
1202
|
-
}, null);
|
|
1203
|
-
}
|
|
1204
|
-
function renderFooter() {
|
|
1205
|
-
if (unref(getMenuType) === MenuType.SIDE || unref(getMenuType) === MenuType.MIX && props.splitType === 2) {
|
|
1206
|
-
return slots?.menuFooter ? createVNode(DtSlotContainer, {
|
|
1207
|
-
"template": slots?.menuFooter,
|
|
1208
|
-
"data": {
|
|
1209
|
-
theme: unref(getComputedTheme),
|
|
1210
|
-
collapsed: unref(getCollapsed)
|
|
1211
|
-
}
|
|
1212
|
-
}, null) : null;
|
|
1213
|
-
}
|
|
1214
|
-
return null;
|
|
1215
|
-
}
|
|
1216
|
-
function renderMenu() {
|
|
1217
|
-
const {
|
|
1218
|
-
menus,
|
|
1219
|
-
...menuProps
|
|
1220
|
-
} = unref(getMenuProps);
|
|
1221
|
-
if (!menus || !menus.length)
|
|
1222
|
-
return null;
|
|
1223
|
-
return createVNode(_sfc_main$t, mergeProps(menuProps, {
|
|
1224
|
-
"isHorizontal": props.isHorizontal,
|
|
1225
|
-
"type": unref(getMenuType),
|
|
1226
|
-
"showLogo": unref(getIsShowLogo),
|
|
1227
|
-
"mode": unref(getComputedMenuMode),
|
|
1228
|
-
"items": menus
|
|
1229
|
-
}), null);
|
|
1230
|
-
}
|
|
1231
|
-
return () => {
|
|
1232
|
-
return createVNode(Fragment, null, [renderHeader(), unref(getUseScroll) ? createVNode(DtScrollContainer, null, {
|
|
1233
|
-
default: () => renderMenu()
|
|
1234
|
-
}) : renderMenu(), renderFooter()]);
|
|
1235
|
-
};
|
|
1236
|
-
}
|
|
1237
|
-
});
|
|
1238
|
-
const _hoisted_1$j = { class: "dt-menu-filter h-7 pr-2" };
|
|
1239
|
-
const _hoisted_2$b = ["onClick"];
|
|
1240
|
-
const _hoisted_3$9 = {
|
|
1241
|
-
key: 0,
|
|
1242
|
-
class: "flex items-center justify-center h-full overflow-hidden"
|
|
1243
|
-
};
|
|
1244
|
-
const _sfc_main$r = /* @__PURE__ */ defineComponent({
|
|
1245
|
-
__name: "MenuFilter",
|
|
1246
|
-
setup(__props) {
|
|
1247
|
-
const { t } = useI18n("UI");
|
|
1248
|
-
const { getIsZH } = useHeader();
|
|
1249
|
-
const filter = ref("");
|
|
1250
|
-
function openChange(e) {
|
|
1251
|
-
if (e) {
|
|
1252
|
-
filterMenu();
|
|
1253
|
-
} else {
|
|
1254
|
-
filter.value = null;
|
|
1255
|
-
}
|
|
1256
|
-
}
|
|
1257
|
-
const menuList = ref([]);
|
|
1258
|
-
function filterMenu() {
|
|
1259
|
-
menuList.value = getFilterMenu(filter.value, true);
|
|
1260
|
-
}
|
|
1261
|
-
const go = useGo();
|
|
1262
|
-
function navigation(url) {
|
|
1263
|
-
go(url);
|
|
1264
|
-
setTimeout(() => {
|
|
1265
|
-
filter.value = "";
|
|
1266
|
-
menuList.value = [];
|
|
1267
|
-
});
|
|
1268
|
-
}
|
|
1269
|
-
return (_ctx, _cache) => {
|
|
1270
|
-
const _component_AEmpty = Empty;
|
|
1271
|
-
const _component_AInputSearch = InputSearch;
|
|
1272
|
-
const _component_APopover = Popover;
|
|
1273
|
-
return openBlock(), createElementBlock("div", _hoisted_1$j, [
|
|
1274
|
-
createVNode(_component_APopover, {
|
|
1275
|
-
placement: "bottom",
|
|
1276
|
-
overlayClassName: "dt-menu-filter__popover",
|
|
1277
|
-
trigger: "focus",
|
|
1278
|
-
onOpenChange: openChange
|
|
1279
|
-
}, {
|
|
1280
|
-
content: withCtx(() => [
|
|
1281
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(menuList), (menu) => {
|
|
1282
|
-
return openBlock(), createElementBlock("p", {
|
|
1283
|
-
onClick: ($event) => navigation(menu.url),
|
|
1284
|
-
class: "px-5 leading-9 border-gray-200 border-dashed border-b m-0 cursor-pointer transition-all duration-300 text-13"
|
|
1285
|
-
}, toDisplayString(unref(getIsZH) ? menu.label : menu.enLabel), 9, _hoisted_2$b);
|
|
1286
|
-
}), 256)),
|
|
1287
|
-
!unref(menuList).length ? (openBlock(), createElementBlock("div", _hoisted_3$9, [
|
|
1288
|
-
createVNode(_component_AEmpty, {
|
|
1289
|
-
description: "\u6682\u65E0\u6570\u636E",
|
|
1290
|
-
imageStyle: { width: "100%" }
|
|
1291
|
-
})
|
|
1292
|
-
])) : createCommentVNode("", true)
|
|
1293
|
-
]),
|
|
1294
|
-
default: withCtx(() => [
|
|
1295
|
-
createVNode(_component_AInputSearch, {
|
|
1296
|
-
value: unref(filter),
|
|
1297
|
-
"onUpdate:value": _cache[0] || (_cache[0] = ($event) => isRef(filter) ? filter.value = $event : null),
|
|
1298
|
-
placeholder: unref(t)("FILTER_MORE"),
|
|
1299
|
-
onInput: filterMenu
|
|
1300
|
-
}, null, 8, ["value", "placeholder"])
|
|
1301
|
-
]),
|
|
1302
|
-
_: 1
|
|
1303
|
-
})
|
|
1304
|
-
]);
|
|
1305
|
-
};
|
|
1306
|
-
}
|
|
1307
|
-
});
|
|
1308
|
-
const _hoisted_1$i = { class: "dt_header_icon" };
|
|
1309
|
-
const _hoisted_2$a = /* @__PURE__ */ createElementVNode("i", { class: "i ant-design:bell-outlined" }, null, -1);
|
|
1310
|
-
const _sfc_main$q = /* @__PURE__ */ defineComponent({
|
|
1311
|
-
__name: "Notice",
|
|
1312
|
-
setup(__props) {
|
|
1313
|
-
let slots = getParentSlots(null, "dt-theme");
|
|
1314
|
-
return (_ctx, _cache) => {
|
|
1315
|
-
const _component_APopover = Popover;
|
|
1316
|
-
return openBlock(), createBlock(_component_APopover, {
|
|
1317
|
-
trigger: "click",
|
|
1318
|
-
overlayClassName: "dt-notify__popover"
|
|
1319
|
-
}, {
|
|
1320
|
-
content: withCtx(() => [
|
|
1321
|
-
unref(slots)?.notify ? (openBlock(), createBlock(unref(DtSlotContainer), {
|
|
1322
|
-
key: 0,
|
|
1323
|
-
template: unref(slots).notify
|
|
1324
|
-
}, null, 8, ["template"])) : createCommentVNode("", true)
|
|
1325
|
-
]),
|
|
1326
|
-
default: withCtx(() => [
|
|
1327
|
-
createElementVNode("span", _hoisted_1$i, [
|
|
1328
|
-
_hoisted_2$a,
|
|
1329
|
-
unref(slots)?.notifyBadge ? (openBlock(), createBlock(unref(DtSlotContainer), {
|
|
1330
|
-
key: 0,
|
|
1331
|
-
template: unref(slots).notifyBadge
|
|
1332
|
-
}, null, 8, ["template"])) : createCommentVNode("", true)
|
|
1333
|
-
])
|
|
1334
|
-
]),
|
|
1335
|
-
_: 1
|
|
1336
|
-
});
|
|
1337
|
-
};
|
|
1338
|
-
}
|
|
1339
|
-
});
|
|
1340
|
-
const _sfc_main$p = /* @__PURE__ */ defineComponent({
|
|
1341
|
-
__name: "FullScreen",
|
|
1342
|
-
setup(__props) {
|
|
1343
|
-
const { toggle, isFullscreen } = useFullscreen();
|
|
1344
|
-
return (_ctx, _cache) => {
|
|
1345
|
-
return openBlock(), createElementBlock("span", {
|
|
1346
|
-
class: "dt_header_icon",
|
|
1347
|
-
onClick: _cache[0] || (_cache[0] = (...args) => unref(toggle) && unref(toggle)(...args))
|
|
1348
|
-
}, [
|
|
1349
|
-
createElementVNode("i", {
|
|
1350
|
-
class: normalizeClass(["i block", !unref(isFullscreen) ? "ic:baseline-fullscreen" : "ic:baseline-fullscreen-exit"])
|
|
1351
|
-
}, null, 2)
|
|
1352
|
-
]);
|
|
1353
|
-
};
|
|
1354
|
-
}
|
|
1355
|
-
});
|
|
1356
|
-
const _hoisted_1$h = { class: "lang m-0" };
|
|
1357
|
-
const _hoisted_2$9 = ["onClick"];
|
|
1358
|
-
const _hoisted_3$8 = /* @__PURE__ */ createElementVNode("span", { class: "dt_header_icon" }, [
|
|
1359
|
-
/* @__PURE__ */ createElementVNode("i", { class: "block i ic:baseline-language" })
|
|
1360
|
-
], -1);
|
|
1361
|
-
const _sfc_main$o = /* @__PURE__ */ defineComponent({
|
|
1362
|
-
__name: "LangPicker",
|
|
1363
|
-
props: {
|
|
1364
|
-
reload: { type: Boolean }
|
|
1365
|
-
},
|
|
1366
|
-
setup(__props) {
|
|
1367
|
-
const props = __props;
|
|
1368
|
-
const visible = ref(false);
|
|
1369
|
-
let currentLang = getLocal(CacheKey.LOCALE);
|
|
1370
|
-
async function toggleLang(lang) {
|
|
1371
|
-
visible.value = false;
|
|
1372
|
-
if (lang !== currentLang) {
|
|
1373
|
-
currentLang = lang;
|
|
1374
|
-
await changeLocale(lang);
|
|
1375
|
-
props.reload && location.reload();
|
|
1376
|
-
}
|
|
1377
|
-
}
|
|
1378
|
-
return (_ctx, _cache) => {
|
|
1379
|
-
const _component_APopover = Popover;
|
|
1380
|
-
return openBlock(), createBlock(_component_APopover, {
|
|
1381
|
-
placement: "bottom",
|
|
1382
|
-
open: unref(visible),
|
|
1383
|
-
"onUpdate:open": _cache[0] || (_cache[0] = ($event) => isRef(visible) ? visible.value = $event : null),
|
|
1384
|
-
overlayClassName: "dt-lang-picker__popover",
|
|
1385
|
-
trigger: "click"
|
|
1386
|
-
}, {
|
|
1387
|
-
content: withCtx(() => [
|
|
1388
|
-
createElementVNode("ul", _hoisted_1$h, [
|
|
1389
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(localeList), (it) => {
|
|
1390
|
-
return openBlock(), createElementBlock("li", {
|
|
1391
|
-
onClick: ($event) => toggleLang(it.event),
|
|
1392
|
-
class: normalizeClass(it.event === unref(currentLang) ? "active bg-gray-100" : "")
|
|
1393
|
-
}, [
|
|
1394
|
-
createElementVNode("i", {
|
|
1395
|
-
class: normalizeClass(["i pr-2", it.icon]),
|
|
1396
|
-
size: 16
|
|
1397
|
-
}, null, 2),
|
|
1398
|
-
createElementVNode("span", null, toDisplayString(it.text), 1)
|
|
1399
|
-
], 10, _hoisted_2$9);
|
|
1400
|
-
}), 256))
|
|
1401
|
-
])
|
|
1402
|
-
]),
|
|
1403
|
-
default: withCtx(() => [
|
|
1404
|
-
_hoisted_3$8
|
|
1405
|
-
]),
|
|
1406
|
-
_: 1
|
|
1407
|
-
}, 8, ["open"]);
|
|
1408
|
-
};
|
|
1409
|
-
}
|
|
1410
|
-
});
|
|
1411
|
-
const _hoisted_1$g = { class: "m-0" };
|
|
1412
|
-
const _hoisted_2$8 = /* @__PURE__ */ createElementVNode("i", { class: "i ant-design:lock-filled pr-2 text-16px" }, null, -1);
|
|
1413
|
-
const _hoisted_3$7 = /* @__PURE__ */ createElementVNode("span", null, "\u9501\u5B9A\u5C4F\u5E55", -1);
|
|
1414
|
-
const _hoisted_4$5 = [
|
|
1415
|
-
_hoisted_2$8,
|
|
1416
|
-
_hoisted_3$7
|
|
1417
|
-
];
|
|
1418
|
-
const _hoisted_5$3 = /* @__PURE__ */ createElementVNode("i", { class: "i ant-design:logout-outlined pr-2 text-16px" }, null, -1);
|
|
1419
|
-
const _hoisted_6$3 = { class: "dt_header_icon" };
|
|
1420
|
-
const _hoisted_7$2 = ["src"];
|
|
1421
|
-
const _hoisted_8$2 = { class: "pl-2 text-13" };
|
|
1422
|
-
const _hoisted_9$2 = { class: "lock-box" };
|
|
1423
|
-
const _hoisted_10$1 = ["src"];
|
|
1424
|
-
const _hoisted_11$1 = { class: "pl-2 text-13" };
|
|
1425
|
-
const _sfc_main$n = /* @__PURE__ */ defineComponent({
|
|
1426
|
-
__name: "UserInfo",
|
|
1427
|
-
setup(__props) {
|
|
1428
|
-
const { t } = useI18n("UI");
|
|
1429
|
-
const go = useGo();
|
|
1430
|
-
const slots = getParentSlots(null, "dt-theme");
|
|
1431
|
-
const popoverVisible = ref(false);
|
|
1432
|
-
const visible = ref(false);
|
|
1433
|
-
const password = ref(null);
|
|
1434
|
-
const getUserInfo = getLocal(CacheKey.USER_INFO);
|
|
1435
|
-
const { getShowLoginOut, getLockscreen, loginOutClick } = useHeader();
|
|
1436
|
-
const useLockscreen = useLockscreenStore();
|
|
1437
|
-
function signOut() {
|
|
1438
|
-
popoverVisible.value = false;
|
|
1439
|
-
if (loginOutClick && isFunction(loginOutClick)) {
|
|
1440
|
-
loginOutClick();
|
|
1441
|
-
} else {
|
|
1442
|
-
go(Pages.LOGIN);
|
|
1443
|
-
}
|
|
1444
|
-
}
|
|
1445
|
-
function lockScreen() {
|
|
1446
|
-
popoverVisible.value = false;
|
|
1447
|
-
visible.value = true;
|
|
1448
|
-
}
|
|
1449
|
-
function onLock() {
|
|
1450
|
-
useLockscreen.setLock(true, unref(password));
|
|
1451
|
-
visible.value = false;
|
|
1452
|
-
popoverVisible.value = false;
|
|
1453
|
-
}
|
|
1454
|
-
return (_ctx, _cache) => {
|
|
1455
|
-
const _component_AAvatar = Avatar;
|
|
1456
|
-
const _component_APopover = Popover;
|
|
1457
|
-
const _component_AInputPassword = InputPassword;
|
|
1458
|
-
const _component_AButton = Button;
|
|
1459
|
-
const _component_AModal = Modal;
|
|
1460
|
-
return openBlock(), createElementBlock(Fragment, null, [
|
|
1461
|
-
createVNode(_component_APopover, {
|
|
1462
|
-
open: unref(popoverVisible),
|
|
1463
|
-
"onUpdate:open": _cache[2] || (_cache[2] = ($event) => isRef(popoverVisible) ? popoverVisible.value = $event : null),
|
|
1464
|
-
placement: "bottom",
|
|
1465
|
-
overlayClassName: "dt-user-info__popover",
|
|
1466
|
-
trigger: "click"
|
|
1467
|
-
}, {
|
|
1468
|
-
content: withCtx(() => [
|
|
1469
|
-
createElementVNode("div", _hoisted_1$g, [
|
|
1470
|
-
unref(slots).userInfo ? (openBlock(), createBlock(unref(DtSlotContainer), {
|
|
1471
|
-
key: 0,
|
|
1472
|
-
template: unref(slots).userInfo
|
|
1473
|
-
}, null, 8, ["template"])) : createCommentVNode("", true),
|
|
1474
|
-
unref(getLockscreen) ? (openBlock(), createElementBlock("div", {
|
|
1475
|
-
key: 1,
|
|
1476
|
-
onClick: _cache[0] || (_cache[0] = ($event) => lockScreen()),
|
|
1477
|
-
class: "px-4 items-center my-1 leading-9 flex border-gray-200 cursor-pointer hover:bg-gray-100 transition-all duration-300 text-13"
|
|
1478
|
-
}, _hoisted_4$5)) : createCommentVNode("", true),
|
|
1479
|
-
unref(getShowLoginOut) ? (openBlock(), createElementBlock("div", {
|
|
1480
|
-
key: 2,
|
|
1481
|
-
onClick: _cache[1] || (_cache[1] = ($event) => signOut()),
|
|
1482
|
-
class: "px-4 items-center my-1 leading-9 flex border-gray-200 cursor-pointer hover:bg-gray-100 transition-all duration-300 text-13"
|
|
1483
|
-
}, [
|
|
1484
|
-
_hoisted_5$3,
|
|
1485
|
-
createElementVNode("span", null, toDisplayString(unref(t)("LOGIN_OUT")), 1)
|
|
1486
|
-
])) : createCommentVNode("", true)
|
|
1487
|
-
])
|
|
1488
|
-
]),
|
|
1489
|
-
default: withCtx(() => [
|
|
1490
|
-
createElementVNode("div", _hoisted_6$3, [
|
|
1491
|
-
createVNode(_component_AAvatar, { size: 28 }, createSlots({
|
|
1492
|
-
default: withCtx(() => [
|
|
1493
|
-
unref(slots)?.icon ? (openBlock(), createBlock(unref(DtSlotContainer), {
|
|
1494
|
-
key: 0,
|
|
1495
|
-
template: unref(slots).icon
|
|
1496
|
-
}, null, 8, ["template"])) : createCommentVNode("", true)
|
|
1497
|
-
]),
|
|
1498
|
-
_: 2
|
|
1499
|
-
}, [
|
|
1500
|
-
!unref(slots)?.icon ? {
|
|
1501
|
-
name: "icon",
|
|
1502
|
-
fn: withCtx(() => [
|
|
1503
|
-
createElementVNode("img", { src: unref(txUrl) }, null, 8, _hoisted_7$2)
|
|
1504
|
-
]),
|
|
1505
|
-
key: "0"
|
|
1506
|
-
} : void 0
|
|
1507
|
-
]), 1024),
|
|
1508
|
-
createElementVNode("span", _hoisted_8$2, toDisplayString(unref(getUserInfo)?.userNo), 1)
|
|
1509
|
-
])
|
|
1510
|
-
]),
|
|
1511
|
-
_: 1
|
|
1512
|
-
}, 8, ["open"]),
|
|
1513
|
-
createVNode(_component_AModal, {
|
|
1514
|
-
open: unref(visible),
|
|
1515
|
-
"onUpdate:open": _cache[4] || (_cache[4] = ($event) => isRef(visible) ? visible.value = $event : null),
|
|
1516
|
-
title: "\u9501\u5B9A\u5C4F\u5E55",
|
|
1517
|
-
class: "lockscreen",
|
|
1518
|
-
footer: null
|
|
1519
|
-
}, {
|
|
1520
|
-
default: withCtx(() => [
|
|
1521
|
-
createElementVNode("div", _hoisted_9$2, [
|
|
1522
|
-
unref(slots)?.icon ? (openBlock(), createBlock(unref(DtSlotContainer), {
|
|
1523
|
-
key: 0,
|
|
1524
|
-
template: unref(slots).icon
|
|
1525
|
-
}, null, 8, ["template"])) : (openBlock(), createElementBlock("img", {
|
|
1526
|
-
key: 1,
|
|
1527
|
-
src: unref(txUrl)
|
|
1528
|
-
}, null, 8, _hoisted_10$1)),
|
|
1529
|
-
createElementVNode("span", _hoisted_11$1, toDisplayString(unref(getUserInfo)?.userNo), 1),
|
|
1530
|
-
createVNode(_component_AInputPassword, {
|
|
1531
|
-
class: "mt-4",
|
|
1532
|
-
autofocus: "",
|
|
1533
|
-
value: unref(password),
|
|
1534
|
-
"onUpdate:value": _cache[3] || (_cache[3] = ($event) => isRef(password) ? password.value = $event : null),
|
|
1535
|
-
onKeyup: withKeys(onLock, ["enter"]),
|
|
1536
|
-
placeholder: "\u8BF7\u8F93\u5165\u9501\u5C4F\u5BC6\u7801"
|
|
1537
|
-
}, null, 8, ["value", "onKeyup"]),
|
|
1538
|
-
createVNode(_component_AButton, {
|
|
1539
|
-
class: "mt-4",
|
|
1540
|
-
type: "primary",
|
|
1541
|
-
onClick: onLock,
|
|
1542
|
-
block: ""
|
|
1543
|
-
}, {
|
|
1544
|
-
default: withCtx(() => [
|
|
1545
|
-
createTextVNode("\u9501\u5B9A")
|
|
1546
|
-
]),
|
|
1547
|
-
_: 1
|
|
1548
|
-
})
|
|
1549
|
-
])
|
|
1550
|
-
]),
|
|
1551
|
-
_: 1
|
|
1552
|
-
}, 8, ["open"])
|
|
1553
|
-
], 64);
|
|
1554
|
-
};
|
|
1555
|
-
}
|
|
1556
|
-
});
|
|
1557
|
-
const PRIMARY_COLOR_LIST = [
|
|
1558
|
-
"#0960bd",
|
|
1559
|
-
"#0084f4",
|
|
1560
|
-
"#009688",
|
|
1561
|
-
"#536dfe",
|
|
1562
|
-
"#ff5c93",
|
|
1563
|
-
"#ee4f12",
|
|
1564
|
-
"#269ac1",
|
|
1565
|
-
"#9c27b0",
|
|
1566
|
-
"#ff9800"
|
|
1567
|
-
];
|
|
1568
|
-
var HandlerEnum = /* @__PURE__ */ ((HandlerEnum2) => {
|
|
1569
|
-
HandlerEnum2[HandlerEnum2["CHANGE_LAYOUT"] = 0] = "CHANGE_LAYOUT";
|
|
1570
|
-
HandlerEnum2[HandlerEnum2["SHOW_BREADCRUMB"] = 1] = "SHOW_BREADCRUMB";
|
|
1571
|
-
HandlerEnum2[HandlerEnum2["SHOW_SEARCH"] = 2] = "SHOW_SEARCH";
|
|
1572
|
-
HandlerEnum2[HandlerEnum2["SHOW_NOTICY"] = 3] = "SHOW_NOTICY";
|
|
1573
|
-
HandlerEnum2[HandlerEnum2["SHOW_FULL_SCREEN"] = 4] = "SHOW_FULL_SCREEN";
|
|
1574
|
-
HandlerEnum2[HandlerEnum2["SHOW_LOCAL"] = 5] = "SHOW_LOCAL";
|
|
1575
|
-
HandlerEnum2[HandlerEnum2["SHOW_ROUTE_REUSE"] = 6] = "SHOW_ROUTE_REUSE";
|
|
1576
|
-
HandlerEnum2[HandlerEnum2["SHOW_FOOTER"] = 7] = "SHOW_FOOTER";
|
|
1577
|
-
HandlerEnum2[HandlerEnum2["CONTENT_MODE"] = 8] = "CONTENT_MODE";
|
|
1578
|
-
HandlerEnum2[HandlerEnum2["COLOR_PRIMARY"] = 9] = "COLOR_PRIMARY";
|
|
1579
|
-
HandlerEnum2[HandlerEnum2["VAR"] = 10] = "VAR";
|
|
1580
|
-
HandlerEnum2[HandlerEnum2["SIZE"] = 11] = "SIZE";
|
|
1581
|
-
return HandlerEnum2;
|
|
1582
|
-
})(HandlerEnum || {});
|
|
1583
|
-
function changeTheme(event, value = {}) {
|
|
1584
|
-
let conf = {};
|
|
1585
|
-
switch (event) {
|
|
1586
|
-
case 0:
|
|
1587
|
-
const { mode, type, split, headTheme, menuTheme } = value;
|
|
1588
|
-
conf = {
|
|
1589
|
-
headOptions: {
|
|
1590
|
-
theme: headTheme
|
|
1591
|
-
},
|
|
1592
|
-
menuOptions: {
|
|
1593
|
-
mode,
|
|
1594
|
-
type,
|
|
1595
|
-
split,
|
|
1596
|
-
theme: menuTheme,
|
|
1597
|
-
show: true
|
|
1598
|
-
}
|
|
1599
|
-
};
|
|
1600
|
-
break;
|
|
1601
|
-
case 1:
|
|
1602
|
-
conf = {
|
|
1603
|
-
headOptions: {
|
|
1604
|
-
showBreadCrumb: value
|
|
1605
|
-
}
|
|
1606
|
-
};
|
|
1607
|
-
break;
|
|
1608
|
-
case 2:
|
|
1609
|
-
conf = {
|
|
1610
|
-
headOptions: {
|
|
1611
|
-
showSearch: value
|
|
1612
|
-
}
|
|
1613
|
-
};
|
|
1614
|
-
break;
|
|
1615
|
-
case 3:
|
|
1616
|
-
conf = {
|
|
1617
|
-
headOptions: {
|
|
1618
|
-
showNotice: value
|
|
1619
|
-
}
|
|
1620
|
-
};
|
|
1621
|
-
break;
|
|
1622
|
-
case 4:
|
|
1623
|
-
conf = {
|
|
1624
|
-
headOptions: {
|
|
1625
|
-
showFullScreen: value
|
|
1626
|
-
}
|
|
1627
|
-
};
|
|
1628
|
-
break;
|
|
1629
|
-
case 5:
|
|
1630
|
-
conf = {
|
|
1631
|
-
headOptions: {
|
|
1632
|
-
showLocaleSwitch: value
|
|
1633
|
-
}
|
|
1634
|
-
};
|
|
1635
|
-
break;
|
|
1636
|
-
case 6:
|
|
1637
|
-
conf = {
|
|
1638
|
-
routeReuse: {
|
|
1639
|
-
show: value
|
|
1640
|
-
}
|
|
1641
|
-
};
|
|
1642
|
-
break;
|
|
1643
|
-
case 7:
|
|
1644
|
-
conf = {
|
|
1645
|
-
footerOptions: {
|
|
1646
|
-
show: value
|
|
1647
|
-
}
|
|
1648
|
-
};
|
|
1649
|
-
break;
|
|
1650
|
-
case 8:
|
|
1651
|
-
conf = {
|
|
1652
|
-
content: {
|
|
1653
|
-
contentMode: value
|
|
1654
|
-
}
|
|
1655
|
-
};
|
|
1656
|
-
break;
|
|
1657
|
-
case 9:
|
|
1658
|
-
conf = {
|
|
1659
|
-
vars: {
|
|
1660
|
-
token: {
|
|
1661
|
-
colorPrimary: value
|
|
1662
|
-
}
|
|
1663
|
-
}
|
|
1664
|
-
};
|
|
1665
|
-
document.getElementsByTagName("body")[0].style.setProperty("--colorPrimary", value);
|
|
1666
|
-
break;
|
|
1667
|
-
case 10:
|
|
1668
|
-
conf = {
|
|
1669
|
-
vars: value
|
|
1670
|
-
};
|
|
1671
|
-
break;
|
|
1672
|
-
case 11:
|
|
1673
|
-
conf = {
|
|
1674
|
-
headOptions: {
|
|
1675
|
-
size: value
|
|
1676
|
-
}
|
|
1677
|
-
};
|
|
1678
|
-
break;
|
|
1679
|
-
}
|
|
1680
|
-
useThemeStore().setThemeConf(conf);
|
|
1681
|
-
}
|
|
1682
|
-
const _hoisted_1$f = { class: "dt-menu-type" };
|
|
1683
|
-
const _hoisted_2$7 = ["onClick"];
|
|
1684
|
-
const _hoisted_3$6 = /* @__PURE__ */ createElementVNode("div", { class: "dt-menu-type__item" }, null, -1);
|
|
1685
|
-
const _hoisted_4$4 = [
|
|
1686
|
-
_hoisted_3$6
|
|
1687
|
-
];
|
|
1688
|
-
const _sfc_main$m = /* @__PURE__ */ defineComponent({
|
|
1689
|
-
__name: "MenuType",
|
|
1690
|
-
setup(__props) {
|
|
1691
|
-
const { getMenuType, getMenuMode } = useMenu();
|
|
1692
|
-
const menuTypeList = [
|
|
1693
|
-
{
|
|
1694
|
-
title: "\u5DE6\u4FA7\u83DC\u5355\u6A21\u5F0F",
|
|
1695
|
-
headTheme: Theme.LIGHT,
|
|
1696
|
-
menuTheme: Theme.DARK,
|
|
1697
|
-
mode: MenuMode.INLINE,
|
|
1698
|
-
type: MenuType.SIDE,
|
|
1699
|
-
split: false
|
|
1700
|
-
},
|
|
1701
|
-
{
|
|
1702
|
-
title: "\u83DC\u5355\u6DF7\u5408\u6A21\u5F0F",
|
|
1703
|
-
headTheme: Theme.DARK,
|
|
1704
|
-
menuTheme: Theme.LIGHT,
|
|
1705
|
-
mode: MenuMode.INLINE,
|
|
1706
|
-
type: MenuType.MIX,
|
|
1707
|
-
split: true
|
|
1708
|
-
},
|
|
1709
|
-
{
|
|
1710
|
-
title: "\u9876\u90E8\u83DC\u5355\u6A21\u5F0F",
|
|
1711
|
-
headTheme: Theme.DARK,
|
|
1712
|
-
menuTheme: Theme.LIGHT,
|
|
1713
|
-
mode: MenuMode.HORIZONTAL,
|
|
1714
|
-
type: MenuType.TOP_MENU,
|
|
1715
|
-
split: false
|
|
1716
|
-
},
|
|
1717
|
-
{
|
|
1718
|
-
title: "\u5DE6\u4FA7\u83DC\u5355\u6DF7\u5408\u6A21\u5F0F",
|
|
1719
|
-
headTheme: Theme.LIGHT,
|
|
1720
|
-
menuTheme: Theme.DARK,
|
|
1721
|
-
mode: MenuMode.INLINE,
|
|
1722
|
-
type: MenuType.MIX_SIDEBAR,
|
|
1723
|
-
split: false
|
|
1724
|
-
}
|
|
1725
|
-
];
|
|
1726
|
-
function changeMenuType(item) {
|
|
1727
|
-
changeTheme(HandlerEnum.CHANGE_LAYOUT, item);
|
|
1728
|
-
}
|
|
1729
|
-
return (_ctx, _cache) => {
|
|
1730
|
-
const _component_ATooltip = Tooltip;
|
|
1731
|
-
return openBlock(), createElementBlock("div", _hoisted_1$f, [
|
|
1732
|
-
(openBlock(), createElementBlock(Fragment, null, renderList(menuTypeList, (item) => {
|
|
1733
|
-
return createVNode(_component_ATooltip, {
|
|
1734
|
-
key: item.title,
|
|
1735
|
-
title: item.title,
|
|
1736
|
-
placement: "bottom"
|
|
1737
|
-
}, {
|
|
1738
|
-
default: withCtx(() => [
|
|
1739
|
-
createElementVNode("div", {
|
|
1740
|
-
onClick: ($event) => changeMenuType(item),
|
|
1741
|
-
class: normalizeClass([
|
|
1742
|
-
`dt-menu-type__list `,
|
|
1743
|
-
`dt-menu-type__item--${item.type}`,
|
|
1744
|
-
{
|
|
1745
|
-
[`dt-menu-type__item--active`]: unref(getMenuType) === item.type && unref(getMenuMode) === item.mode
|
|
1746
|
-
}
|
|
1747
|
-
])
|
|
1748
|
-
}, _hoisted_4$4, 10, _hoisted_2$7)
|
|
1749
|
-
]),
|
|
1750
|
-
_: 2
|
|
1751
|
-
}, 1032, ["title"]);
|
|
1752
|
-
}), 64))
|
|
1753
|
-
]);
|
|
1754
|
-
};
|
|
1755
|
-
}
|
|
1756
|
-
});
|
|
1757
|
-
const _hoisted_1$e = { class: "flex justify-between items-center mb-5" };
|
|
1758
|
-
const _sfc_main$l = /* @__PURE__ */ defineComponent({
|
|
1759
|
-
__name: "Switch",
|
|
1760
|
-
props: {
|
|
1761
|
-
event: {},
|
|
1762
|
-
disabled: { type: Boolean },
|
|
1763
|
-
title: {},
|
|
1764
|
-
def: {}
|
|
1765
|
-
},
|
|
1766
|
-
setup(__props) {
|
|
1767
|
-
const props = __props;
|
|
1768
|
-
const { t } = useI18n("UI");
|
|
1769
|
-
const getBindValue = computed(() => {
|
|
1770
|
-
return props.def ? { checked: unref(props.def) } : {};
|
|
1771
|
-
});
|
|
1772
|
-
function handleChange(e) {
|
|
1773
|
-
props.event && changeTheme(props.event, e);
|
|
1774
|
-
}
|
|
1775
|
-
return (_ctx, _cache) => {
|
|
1776
|
-
const _component_ASwitch = Switch;
|
|
1777
|
-
return openBlock(), createElementBlock("div", _hoisted_1$e, [
|
|
1778
|
-
createElementVNode("span", null, toDisplayString(_ctx.title), 1),
|
|
1779
|
-
createVNode(_component_ASwitch, mergeProps(unref(getBindValue), {
|
|
1780
|
-
disabled: _ctx.disabled,
|
|
1781
|
-
checkedChildren: unref(t)("ON"),
|
|
1782
|
-
unCheckedChildren: unref(t)("OFF"),
|
|
1783
|
-
onChange: handleChange
|
|
1784
|
-
}), null, 16, ["disabled", "checkedChildren", "unCheckedChildren"])
|
|
1785
|
-
]);
|
|
1786
|
-
};
|
|
1787
|
-
}
|
|
1788
|
-
});
|
|
1789
|
-
const _hoisted_1$d = { class: "flex justify-between items-center mb-5" };
|
|
1790
|
-
const _sfc_main$k = /* @__PURE__ */ defineComponent({
|
|
1791
|
-
__name: "Select",
|
|
1792
|
-
props: {
|
|
1793
|
-
event: {},
|
|
1794
|
-
title: {},
|
|
1795
|
-
def: {},
|
|
1796
|
-
initValue: {},
|
|
1797
|
-
options: {}
|
|
1798
|
-
},
|
|
1799
|
-
setup(__props) {
|
|
1800
|
-
const props = __props;
|
|
1801
|
-
const getBindValue = computed(() => {
|
|
1802
|
-
return props.def ? { value: props.def, defaultValue: props.initValue || props.def } : {};
|
|
1803
|
-
});
|
|
1804
|
-
function handleChange(val) {
|
|
1805
|
-
props.event && changeTheme(props.event, val);
|
|
1806
|
-
}
|
|
1807
|
-
return (_ctx, _cache) => {
|
|
1808
|
-
const _component_ASelect = Select;
|
|
1809
|
-
return openBlock(), createElementBlock("div", _hoisted_1$d, [
|
|
1810
|
-
createElementVNode("span", null, toDisplayString(_ctx.title), 1),
|
|
1811
|
-
createVNode(_component_ASelect, mergeProps(unref(getBindValue), {
|
|
1812
|
-
class: "w-32",
|
|
1813
|
-
options: _ctx.options,
|
|
1814
|
-
onChange: handleChange
|
|
1815
|
-
}), null, 16, ["options"])
|
|
1816
|
-
]);
|
|
1817
|
-
};
|
|
1818
|
-
}
|
|
1819
|
-
});
|
|
1820
|
-
const _sfc_main$j = /* @__PURE__ */ defineComponent({
|
|
1821
|
-
__name: "Feature",
|
|
1822
|
-
setup(__props) {
|
|
1823
|
-
const {
|
|
1824
|
-
getShowBread,
|
|
1825
|
-
getShowSearch,
|
|
1826
|
-
getShowNotice,
|
|
1827
|
-
getShowFullScreen,
|
|
1828
|
-
getShowLocale
|
|
1829
|
-
} = useHeader();
|
|
1830
|
-
const { getShowMultipleTab } = useMultipleTab();
|
|
1831
|
-
const { getShowFooter, getContentMode } = useTheme();
|
|
1832
|
-
const { t } = useI18n("UI");
|
|
1833
|
-
const switchItems = [
|
|
1834
|
-
{
|
|
1835
|
-
title: t("BREAD_CURB"),
|
|
1836
|
-
event: HandlerEnum.SHOW_BREADCRUMB,
|
|
1837
|
-
def: getShowBread
|
|
1838
|
-
},
|
|
1839
|
-
{
|
|
1840
|
-
title: t("MENU_FILTER"),
|
|
1841
|
-
event: HandlerEnum.SHOW_SEARCH,
|
|
1842
|
-
def: getShowSearch
|
|
1843
|
-
},
|
|
1844
|
-
{
|
|
1845
|
-
title: t("NOTICE"),
|
|
1846
|
-
event: HandlerEnum.SHOW_NOTICY,
|
|
1847
|
-
def: getShowNotice
|
|
1848
|
-
},
|
|
1849
|
-
{
|
|
1850
|
-
title: t("SHOW_FULLE"),
|
|
1851
|
-
event: HandlerEnum.SHOW_FULL_SCREEN,
|
|
1852
|
-
def: getShowFullScreen
|
|
1853
|
-
},
|
|
1854
|
-
{
|
|
1855
|
-
title: t("LOCAL"),
|
|
1856
|
-
event: HandlerEnum.SHOW_LOCAL,
|
|
1857
|
-
def: getShowLocale
|
|
1858
|
-
},
|
|
1859
|
-
{
|
|
1860
|
-
title: t("ROUTE_REUSE"),
|
|
1861
|
-
event: HandlerEnum.SHOW_ROUTE_REUSE,
|
|
1862
|
-
def: getShowMultipleTab
|
|
1863
|
-
},
|
|
1864
|
-
{
|
|
1865
|
-
title: t("SHOW_FOOTER"),
|
|
1866
|
-
event: HandlerEnum.SHOW_FOOTER,
|
|
1867
|
-
def: getShowFooter
|
|
1868
|
-
}
|
|
1869
|
-
];
|
|
1870
|
-
const selectItems = [
|
|
1871
|
-
{
|
|
1872
|
-
title: t("CONTENT_FIXED_WIDTH"),
|
|
1873
|
-
event: HandlerEnum.CONTENT_MODE,
|
|
1874
|
-
def: getContentMode,
|
|
1875
|
-
options: [
|
|
1876
|
-
{
|
|
1877
|
-
value: ContentMode.FULL,
|
|
1878
|
-
label: t("FULL")
|
|
1879
|
-
},
|
|
1880
|
-
{
|
|
1881
|
-
value: ContentMode.FIXED,
|
|
1882
|
-
label: t("FIXED")
|
|
1883
|
-
}
|
|
1884
|
-
]
|
|
1885
|
-
}
|
|
1886
|
-
];
|
|
1887
|
-
return (_ctx, _cache) => {
|
|
1888
|
-
return openBlock(), createElementBlock(Fragment, null, [
|
|
1889
|
-
(openBlock(), createElementBlock(Fragment, null, renderList(switchItems, (item) => {
|
|
1890
|
-
return createVNode(_sfc_main$l, {
|
|
1891
|
-
key: item.title,
|
|
1892
|
-
title: item.title,
|
|
1893
|
-
event: item.event,
|
|
1894
|
-
def: item.def
|
|
1895
|
-
}, null, 8, ["title", "event", "def"]);
|
|
1896
|
-
}), 64)),
|
|
1897
|
-
(openBlock(), createElementBlock(Fragment, null, renderList(selectItems, (item) => {
|
|
1898
|
-
return createVNode(_sfc_main$k, {
|
|
1899
|
-
key: item.title,
|
|
1900
|
-
title: item.title,
|
|
1901
|
-
event: item.event,
|
|
1902
|
-
def: item.def,
|
|
1903
|
-
options: item.options
|
|
1904
|
-
}, null, 8, ["title", "event", "def", "options"]);
|
|
1905
|
-
}), 64))
|
|
1906
|
-
], 64);
|
|
1907
|
-
};
|
|
1908
|
-
}
|
|
1909
|
-
});
|
|
1910
|
-
const _hoisted_1$c = { class: "flex flex-wrap justify-between" };
|
|
1911
|
-
const _hoisted_2$6 = ["onClick"];
|
|
1912
|
-
const _hoisted_3$5 = {
|
|
1913
|
-
key: 0,
|
|
1914
|
-
class: "i ic:baseline-done text-2xl"
|
|
1915
|
-
};
|
|
1916
|
-
const _sfc_main$i = /* @__PURE__ */ defineComponent({
|
|
1917
|
-
__name: "ColorPrimary",
|
|
1918
|
-
props: {
|
|
1919
|
-
colorList: {
|
|
1920
|
-
type: Array,
|
|
1921
|
-
default: () => []
|
|
1922
|
-
},
|
|
1923
|
-
event: {
|
|
1924
|
-
type: Number
|
|
1925
|
-
},
|
|
1926
|
-
def: {
|
|
1927
|
-
type: String
|
|
1928
|
-
}
|
|
1929
|
-
},
|
|
1930
|
-
setup(__props) {
|
|
1931
|
-
const props = __props;
|
|
1932
|
-
function handleClick(color) {
|
|
1933
|
-
props.event && changeTheme(props.event, color);
|
|
1934
|
-
}
|
|
1935
|
-
return (_ctx, _cache) => {
|
|
1936
|
-
return openBlock(), createElementBlock("div", _hoisted_1$c, [
|
|
1937
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(__props.colorList || [], (color) => {
|
|
1938
|
-
return openBlock(), createElementBlock("span", {
|
|
1939
|
-
key: color,
|
|
1940
|
-
onClick: ($event) => handleClick(color),
|
|
1941
|
-
class: "w-6 h-6 block rounded-2px flex items-center justify-center text-white cursor-pointer",
|
|
1942
|
-
style: normalizeStyle({ background: color })
|
|
1943
|
-
}, [
|
|
1944
|
-
__props.def === color ? (openBlock(), createElementBlock("i", _hoisted_3$5)) : createCommentVNode("", true)
|
|
1945
|
-
], 12, _hoisted_2$6);
|
|
1946
|
-
}), 128))
|
|
1947
|
-
]);
|
|
1948
|
-
};
|
|
1949
|
-
}
|
|
1950
|
-
});
|
|
1951
|
-
const _hoisted_1$b = { class: "flex justify-between items-center mb-5" };
|
|
1952
|
-
const _sfc_main$h = /* @__PURE__ */ defineComponent({
|
|
1953
|
-
__name: "InputNumber",
|
|
1954
|
-
props: {
|
|
1955
|
-
event: {},
|
|
1956
|
-
title: {},
|
|
1957
|
-
def: {}
|
|
1958
|
-
},
|
|
1959
|
-
setup(__props) {
|
|
1960
|
-
const props = __props;
|
|
1961
|
-
const bindVal = ref(props.def);
|
|
1962
|
-
function handleChange(val) {
|
|
1963
|
-
props.event && props.event(val);
|
|
1964
|
-
}
|
|
1965
|
-
return (_ctx, _cache) => {
|
|
1966
|
-
const _component_AInputNumber = InputNumber;
|
|
1967
|
-
return openBlock(), createElementBlock("div", _hoisted_1$b, [
|
|
1968
|
-
createElementVNode("span", null, toDisplayString(_ctx.title), 1),
|
|
1969
|
-
createVNode(_component_AInputNumber, {
|
|
1970
|
-
class: "w-32",
|
|
1971
|
-
placeholder: "\u8BF7\u8F93\u5165",
|
|
1972
|
-
value: unref(bindVal),
|
|
1973
|
-
"onUpdate:value": _cache[0] || (_cache[0] = ($event) => isRef(bindVal) ? bindVal.value = $event : null),
|
|
1974
|
-
"addon-after": "px",
|
|
1975
|
-
onChange: handleChange
|
|
1976
|
-
}, null, 8, ["value"])
|
|
1977
|
-
]);
|
|
1978
|
-
};
|
|
1979
|
-
}
|
|
1980
|
-
});
|
|
1981
|
-
const _sfc_main$g = /* @__PURE__ */ defineComponent({
|
|
1982
|
-
__name: "GlobalStyle",
|
|
1983
|
-
setup(__props) {
|
|
1984
|
-
const { t } = useI18n("UI");
|
|
1985
|
-
const { getUiSize } = useHeader();
|
|
1986
|
-
const sizeList = [
|
|
1987
|
-
{
|
|
1988
|
-
label: t("LARGE_SIZE"),
|
|
1989
|
-
value: UiSize.LARGE
|
|
1990
|
-
},
|
|
1991
|
-
{
|
|
1992
|
-
label: t("MIDDLE_SIZE"),
|
|
1993
|
-
value: UiSize.MIDDLE
|
|
1994
|
-
},
|
|
1995
|
-
{
|
|
1996
|
-
label: t("SMALL_SIZE"),
|
|
1997
|
-
value: UiSize.SMALL
|
|
1998
|
-
}
|
|
1999
|
-
];
|
|
2000
|
-
const { getVars } = useTheme();
|
|
2001
|
-
const varItems = {
|
|
2002
|
-
large: [
|
|
2003
|
-
{
|
|
2004
|
-
title: "\u63A7\u4EF6\u5706\u89D2",
|
|
2005
|
-
type: (borderRadiusLG) => setTheme({ borderRadiusLG }),
|
|
2006
|
-
def: unref(getVars).token?.borderRadiusLG
|
|
2007
|
-
},
|
|
2008
|
-
{
|
|
2009
|
-
title: "\u63A7\u4EF6\u9AD8\u5EA6",
|
|
2010
|
-
type: (controlHeightLG) => setTheme({ controlHeightLG }),
|
|
2011
|
-
def: unref(getVars).token?.controlHeightLG
|
|
2012
|
-
}
|
|
2013
|
-
],
|
|
2014
|
-
middle: [
|
|
2015
|
-
{
|
|
2016
|
-
title: "\u63A7\u4EF6\u5706\u89D2",
|
|
2017
|
-
type: (borderRadius) => setTheme({ borderRadius }),
|
|
2018
|
-
def: unref(getVars).token?.borderRadius
|
|
2019
|
-
},
|
|
2020
|
-
{
|
|
2021
|
-
title: "\u63A7\u4EF6\u9AD8\u5EA6",
|
|
2022
|
-
type: (controlHeight) => setTheme({ controlHeight }),
|
|
2023
|
-
def: unref(getVars).token?.controlHeight
|
|
2024
|
-
}
|
|
2025
|
-
],
|
|
2026
|
-
small: [
|
|
2027
|
-
{
|
|
2028
|
-
title: "\u63A7\u4EF6\u5706\u89D2",
|
|
2029
|
-
type: (borderRadiusSM) => setTheme({ borderRadiusSM }),
|
|
2030
|
-
def: unref(getVars).token?.borderRadiusSM
|
|
2031
|
-
},
|
|
2032
|
-
{
|
|
2033
|
-
title: "\u63A7\u4EF6\u9AD8\u5EA6",
|
|
2034
|
-
type: (controlHeightSM) => setTheme({ controlHeightSM }),
|
|
2035
|
-
def: unref(getVars).token?.controlHeightSM
|
|
2036
|
-
}
|
|
2037
|
-
]
|
|
2038
|
-
};
|
|
2039
|
-
function setTheme(token) {
|
|
2040
|
-
changeTheme(HandlerEnum.VAR, {
|
|
2041
|
-
token
|
|
2042
|
-
});
|
|
2043
|
-
}
|
|
2044
|
-
return (_ctx, _cache) => {
|
|
2045
|
-
const _component_ADivider = Divider;
|
|
2046
|
-
return openBlock(), createElementBlock(Fragment, null, [
|
|
2047
|
-
createVNode(_component_ADivider, null, {
|
|
2048
|
-
default: withCtx(() => [
|
|
2049
|
-
createTextVNode("\u5168\u5C40\u6837\u5F0F")
|
|
2050
|
-
]),
|
|
2051
|
-
_: 1
|
|
2052
|
-
}),
|
|
2053
|
-
createVNode(_sfc_main$k, {
|
|
2054
|
-
title: "\u9875\u9762\u5C3A\u5BF8",
|
|
2055
|
-
event: unref(HandlerEnum).SIZE,
|
|
2056
|
-
def: unref(getUiSize),
|
|
2057
|
-
options: sizeList
|
|
2058
|
-
}, null, 8, ["event", "def"]),
|
|
2059
|
-
unref(getUiSize) === unref(UiSize).LARGE ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(varItems.large, (item) => {
|
|
2060
|
-
return openBlock(), createBlock(_sfc_main$h, {
|
|
2061
|
-
key: item.title,
|
|
2062
|
-
title: item.title,
|
|
2063
|
-
event: item.type,
|
|
2064
|
-
def: item.def
|
|
2065
|
-
}, null, 8, ["title", "event", "def"]);
|
|
2066
|
-
}), 128)) : createCommentVNode("", true),
|
|
2067
|
-
unref(getUiSize) === unref(UiSize).MIDDLE ? (openBlock(true), createElementBlock(Fragment, { key: 1 }, renderList(varItems.middle, (item) => {
|
|
2068
|
-
return openBlock(), createBlock(_sfc_main$h, {
|
|
2069
|
-
key: item.title,
|
|
2070
|
-
title: item.title,
|
|
2071
|
-
event: item.type,
|
|
2072
|
-
def: item.def
|
|
2073
|
-
}, null, 8, ["title", "event", "def"]);
|
|
2074
|
-
}), 128)) : createCommentVNode("", true),
|
|
2075
|
-
unref(getUiSize) === unref(UiSize).SMALL ? (openBlock(true), createElementBlock(Fragment, { key: 2 }, renderList(varItems.small, (item) => {
|
|
2076
|
-
return openBlock(), createBlock(_sfc_main$h, {
|
|
2077
|
-
key: item.title,
|
|
2078
|
-
title: item.title,
|
|
2079
|
-
event: item.type,
|
|
2080
|
-
def: item.def
|
|
2081
|
-
}, null, 8, ["title", "event", "def"]);
|
|
2082
|
-
}), 128)) : createCommentVNode("", true)
|
|
2083
|
-
], 64);
|
|
2084
|
-
};
|
|
2085
|
-
}
|
|
2086
|
-
});
|
|
2087
|
-
const _sfc_main$f = /* @__PURE__ */ defineComponent({
|
|
2088
|
-
__name: "Var",
|
|
2089
|
-
setup(__props) {
|
|
2090
|
-
return (_ctx, _cache) => {
|
|
2091
|
-
return openBlock(), createBlock(_sfc_main$g);
|
|
2092
|
-
};
|
|
2093
|
-
}
|
|
2094
|
-
});
|
|
2095
|
-
const _hoisted_1$a = /* @__PURE__ */ createElementVNode("i", { class: "i ant-design:setting-outlined" }, null, -1);
|
|
2096
|
-
const _hoisted_2$5 = [
|
|
2097
|
-
_hoisted_1$a
|
|
2098
|
-
];
|
|
2099
|
-
const _hoisted_3$4 = { class: "mt-5" };
|
|
2100
|
-
const _hoisted_4$3 = { class: "dt-setting-theme__tips" };
|
|
2101
|
-
const _sfc_main$e = /* @__PURE__ */ defineComponent({
|
|
2102
|
-
__name: "SettintTheme",
|
|
2103
|
-
setup(__props) {
|
|
2104
|
-
const { t } = useI18n("UI");
|
|
2105
|
-
const visible = ref(false);
|
|
2106
|
-
const {
|
|
2107
|
-
getShowBread,
|
|
2108
|
-
getShowSearch,
|
|
2109
|
-
getShowNotice,
|
|
2110
|
-
getShowFullScreen,
|
|
2111
|
-
getShowLocale
|
|
2112
|
-
} = useHeader();
|
|
2113
|
-
const { getShowMultipleTab } = useMultipleTab();
|
|
2114
|
-
const { getShowFooter, getContentMode, getVars } = useTheme();
|
|
2115
|
-
const { getMenuType, getMenuMode } = useMenu();
|
|
2116
|
-
const defaultConf = getConfig();
|
|
2117
|
-
function getConfig() {
|
|
2118
|
-
return {
|
|
2119
|
-
vars: unref(getVars),
|
|
2120
|
-
contentMode: unref(getContentMode),
|
|
2121
|
-
menuOptions: {
|
|
2122
|
-
mode: unref(getMenuMode),
|
|
2123
|
-
type: unref(getMenuType),
|
|
2124
|
-
split: unref(getMenuType) === _sfc_main$m.MIX ? true : false
|
|
2125
|
-
},
|
|
2126
|
-
headOptions: {
|
|
2127
|
-
showBreadCrumb: unref(getShowBread),
|
|
2128
|
-
showSearch: unref(getShowSearch),
|
|
2129
|
-
notice: unref(getShowNotice),
|
|
2130
|
-
showFullScreen: unref(getShowFullScreen),
|
|
2131
|
-
showLocaleSwitch: unref(getShowLocale)
|
|
2132
|
-
},
|
|
2133
|
-
mulTabsOptions: {
|
|
2134
|
-
show: unref(getShowMultipleTab)
|
|
2135
|
-
},
|
|
2136
|
-
footerOptions: {
|
|
2137
|
-
show: unref(getShowFooter)
|
|
2138
|
-
}
|
|
2139
|
-
};
|
|
2140
|
-
}
|
|
2141
|
-
function copy() {
|
|
2142
|
-
const afterUpdateConfig = getConfig();
|
|
2143
|
-
let copyObj = {};
|
|
2144
|
-
const isDiff = (newVal, oldVal) => newVal !== oldVal ? newVal : null;
|
|
2145
|
-
const isSameObj = (val1, val2) => JSON.stringify(val1) === JSON.stringify(val2);
|
|
2146
|
-
const getDiff = (target, orgTarget) => {
|
|
2147
|
-
let obj = {};
|
|
2148
|
-
for (let it in target) {
|
|
2149
|
-
if (isDiff(target[it], orgTarget[it]) !== null) {
|
|
2150
|
-
obj[it] = target[it];
|
|
2151
|
-
}
|
|
2152
|
-
}
|
|
2153
|
-
return obj;
|
|
2154
|
-
};
|
|
2155
|
-
for (let it in afterUpdateConfig) {
|
|
2156
|
-
if (!isSameObj(afterUpdateConfig[it], defaultConf[it])) {
|
|
2157
|
-
copyObj[it] = getDiff(afterUpdateConfig[it], defaultConf[it]);
|
|
2158
|
-
}
|
|
2159
|
-
}
|
|
2160
|
-
if (Object.keys(copyObj).length) {
|
|
2161
|
-
if (copyText(JSON.stringify(copyObj).replaceAll('"', ""))) {
|
|
2162
|
-
Modal$1.success({
|
|
2163
|
-
centered: true,
|
|
2164
|
-
okText: "\u786E\u5B9A",
|
|
2165
|
-
title: "\u64CD\u4F5C\u6210\u529F",
|
|
2166
|
-
content: "\u590D\u5236\u6210\u529F,\u8BF7\u5230 src/core/settings/theme.ts \u4E2D\u4FEE\u6539\u914D\u7F6E\uFF01"
|
|
2167
|
-
});
|
|
2168
|
-
}
|
|
2169
|
-
} else {
|
|
2170
|
-
Modal$1.info({
|
|
2171
|
-
centered: true,
|
|
2172
|
-
okText: "\u786E\u5B9A",
|
|
2173
|
-
title: "\u62F7\u8D1D\u63D0\u793A",
|
|
2174
|
-
content: "\u672A\u68C0\u6D4B\u5230\u4FEE\u6539\u4EFB\u4F55\u914D\u7F6E\u4FE1\u606F!"
|
|
2175
|
-
});
|
|
2176
|
-
}
|
|
2177
|
-
}
|
|
2178
|
-
function reset() {
|
|
2179
|
-
useThemeStore().setThemeConf(defaultConf);
|
|
2180
|
-
}
|
|
2181
|
-
return (_ctx, _cache) => {
|
|
2182
|
-
const _component_ADivider = Divider;
|
|
2183
|
-
const _component_ATabPane = TabPane;
|
|
2184
|
-
const _component_ATabs = Tabs;
|
|
2185
|
-
const _component_AButton = Button;
|
|
2186
|
-
const _component_ADrawer = Drawer;
|
|
2187
|
-
return openBlock(), createElementBlock(Fragment, null, [
|
|
2188
|
-
createElementVNode("span", {
|
|
2189
|
-
onClick: _cache[0] || (_cache[0] = ($event) => visible.value = true),
|
|
2190
|
-
class: "dt_header_icon"
|
|
2191
|
-
}, _hoisted_2$5),
|
|
2192
|
-
createVNode(_component_ADrawer, {
|
|
2193
|
-
open: unref(visible),
|
|
2194
|
-
"onUpdate:open": _cache[1] || (_cache[1] = ($event) => isRef(visible) ? visible.value = $event : null),
|
|
2195
|
-
class: "theme-drawer",
|
|
2196
|
-
title: unref(t)("PROJECT_SETTING"),
|
|
2197
|
-
placement: "right",
|
|
2198
|
-
width: "320"
|
|
2199
|
-
}, {
|
|
2200
|
-
default: withCtx(() => [
|
|
2201
|
-
createVNode(_component_ATabs, null, {
|
|
2202
|
-
default: withCtx(() => [
|
|
2203
|
-
createVNode(_component_ATabPane, {
|
|
2204
|
-
key: "1",
|
|
2205
|
-
tab: "\u5E03\u5C40\u8BBE\u7F6E"
|
|
2206
|
-
}, {
|
|
2207
|
-
default: withCtx(() => [
|
|
2208
|
-
createVNode(_component_ADivider, null, {
|
|
2209
|
-
default: withCtx(() => [
|
|
2210
|
-
createTextVNode(toDisplayString(unref(t)("PRIMARY_COLOR")), 1)
|
|
2211
|
-
]),
|
|
2212
|
-
_: 1
|
|
2213
|
-
}),
|
|
2214
|
-
createVNode(_sfc_main$i, {
|
|
2215
|
-
"color-list": unref(PRIMARY_COLOR_LIST),
|
|
2216
|
-
def: unref(getVars)?.token?.colorPrimary,
|
|
2217
|
-
event: unref(HandlerEnum).COLOR_PRIMARY
|
|
2218
|
-
}, null, 8, ["color-list", "def", "event"]),
|
|
2219
|
-
createVNode(_component_ADivider, null, {
|
|
2220
|
-
default: withCtx(() => [
|
|
2221
|
-
createTextVNode(toDisplayString(unref(t)("NAV_MODE")), 1)
|
|
2222
|
-
]),
|
|
2223
|
-
_: 1
|
|
2224
|
-
}),
|
|
2225
|
-
createVNode(_sfc_main$m),
|
|
2226
|
-
createVNode(_component_ADivider, null, {
|
|
2227
|
-
default: withCtx(() => [
|
|
2228
|
-
createTextVNode(toDisplayString(unref(t)("PAGE_SHOW")), 1)
|
|
2229
|
-
]),
|
|
2230
|
-
_: 1
|
|
2231
|
-
}),
|
|
2232
|
-
createVNode(_sfc_main$j)
|
|
2233
|
-
]),
|
|
2234
|
-
_: 1
|
|
2235
|
-
}),
|
|
2236
|
-
createVNode(_component_ATabPane, {
|
|
2237
|
-
key: "2",
|
|
2238
|
-
tab: "\u6837\u5F0F\u8BBE\u7F6E"
|
|
2239
|
-
}, {
|
|
2240
|
-
default: withCtx(() => [
|
|
2241
|
-
createVNode(_sfc_main$f)
|
|
2242
|
-
]),
|
|
2243
|
-
_: 1
|
|
2244
|
-
})
|
|
2245
|
-
]),
|
|
2246
|
-
_: 1
|
|
2247
|
-
}),
|
|
2248
|
-
createElementVNode("div", _hoisted_3$4, [
|
|
2249
|
-
createVNode(_component_AButton, {
|
|
2250
|
-
onClick: copy,
|
|
2251
|
-
class: "mb-3",
|
|
2252
|
-
type: "primary",
|
|
2253
|
-
block: ""
|
|
2254
|
-
}, {
|
|
2255
|
-
default: withCtx(() => [
|
|
2256
|
-
createTextVNode(toDisplayString(unref(t)("COPY")), 1)
|
|
2257
|
-
]),
|
|
2258
|
-
_: 1
|
|
2259
|
-
}),
|
|
2260
|
-
createVNode(_component_AButton, {
|
|
2261
|
-
onClick: reset,
|
|
2262
|
-
class: "mb-3",
|
|
2263
|
-
block: ""
|
|
2264
|
-
}, {
|
|
2265
|
-
default: withCtx(() => [
|
|
2266
|
-
createTextVNode(toDisplayString(unref(t)("RESET")), 1)
|
|
2267
|
-
]),
|
|
2268
|
-
_: 1
|
|
2269
|
-
})
|
|
2270
|
-
]),
|
|
2271
|
-
createElementVNode("div", _hoisted_4$3, toDisplayString(unref(t)("DRAWER_TIPS")), 1)
|
|
2272
|
-
]),
|
|
2273
|
-
_: 1
|
|
2274
|
-
}, 8, ["open", "title"])
|
|
2275
|
-
], 64);
|
|
2276
|
-
};
|
|
2277
|
-
}
|
|
2278
|
-
});
|
|
2279
|
-
const _hoisted_1$9 = {
|
|
2280
|
-
key: 0,
|
|
2281
|
-
class: "flex-1 h-full min-w-0 items-center"
|
|
2282
|
-
};
|
|
2283
|
-
const _sfc_main$d = /* @__PURE__ */ defineComponent({
|
|
2284
|
-
__name: "index",
|
|
2285
|
-
props: {
|
|
2286
|
-
fixed: Boolean
|
|
2287
|
-
},
|
|
2288
|
-
setup(__props) {
|
|
2289
|
-
const props = __props;
|
|
2290
|
-
const slots = getParentSlots(null, "dt-theme");
|
|
2291
|
-
const { getSplit } = useMenu();
|
|
2292
|
-
const {
|
|
2293
|
-
getHeaderTheme,
|
|
2294
|
-
getShowHeaderLogo,
|
|
2295
|
-
getShowHeaderTrigger,
|
|
2296
|
-
getShowBread,
|
|
2297
|
-
getShowTopMenu,
|
|
2298
|
-
getShowSettingTheme,
|
|
2299
|
-
getShowSearch,
|
|
2300
|
-
getShowNotice,
|
|
2301
|
-
getShowFullScreen,
|
|
2302
|
-
getShowLocale
|
|
2303
|
-
} = useHeader();
|
|
2304
|
-
const { getShowMultipleTab, getMultipleTabPosIsTop } = useMultipleTab();
|
|
2305
|
-
const getShowTab = computed(() => unref(getShowMultipleTab) && unref(getMultipleTabPosIsTop));
|
|
2306
|
-
const getHeaderCls = computed(() => {
|
|
2307
|
-
let theme = unref(getHeaderTheme);
|
|
2308
|
-
let cls = "dt-header ";
|
|
2309
|
-
if (props.fixed) {
|
|
2310
|
-
cls += "fixed top-0 left-0 w-full z-10 ";
|
|
2311
|
-
}
|
|
2312
|
-
cls += `dt-header--${theme}`;
|
|
2313
|
-
return cls;
|
|
2314
|
-
});
|
|
2315
|
-
const getSplitType = computed(() => {
|
|
2316
|
-
return unref(getSplit) ? MenuSplitTye.TOP : MenuSplitTye.NONE;
|
|
2317
|
-
});
|
|
2318
|
-
const getMenuMode = computed(() => {
|
|
2319
|
-
return unref(getSplit) ? MenuMode.HORIZONTAL : null;
|
|
2320
|
-
});
|
|
2321
|
-
return (_ctx, _cache) => {
|
|
2322
|
-
const _component_ALayoutHeader = LayoutHeader;
|
|
2323
|
-
return openBlock(), createBlock(_component_ALayoutHeader, {
|
|
2324
|
-
class: normalizeClass(unref(getHeaderCls))
|
|
2325
|
-
}, {
|
|
2326
|
-
default: withCtx(() => [
|
|
2327
|
-
createElementVNode("div", {
|
|
2328
|
-
class: normalizeClass(["dt-header-left flex h-full items-center", {
|
|
2329
|
-
"w-0 flex-1": unref(getShowTab)
|
|
2330
|
-
}])
|
|
2331
|
-
}, [
|
|
2332
|
-
unref(getShowHeaderLogo) ? (openBlock(), createBlock(_sfc_main$z, {
|
|
2333
|
-
key: 0,
|
|
2334
|
-
theme: unref(getHeaderTheme),
|
|
2335
|
-
class: "dt-header-logo"
|
|
2336
|
-
}, null, 8, ["theme"])) : createCommentVNode("", true),
|
|
2337
|
-
unref(getShowHeaderTrigger) && !unref(getSplit) && !unref(getShowTab) ? (openBlock(), createBlock(_sfc_main$y, {
|
|
2338
|
-
key: 1,
|
|
2339
|
-
theme: unref(getHeaderTheme)
|
|
2340
|
-
}, null, 8, ["theme"])) : createCommentVNode("", true),
|
|
2341
|
-
unref(getShowBread) && !unref(getShowTab) ? (openBlock(), createBlock(_sfc_main$x, { key: 2 })) : createCommentVNode("", true)
|
|
2342
|
-
], 2),
|
|
2343
|
-
unref(getShowTopMenu) ? (openBlock(), createElementBlock("div", _hoisted_1$9, [
|
|
2344
|
-
createVNode(_sfc_main$s, {
|
|
2345
|
-
isHorizontal: true,
|
|
2346
|
-
theme: unref(getHeaderTheme),
|
|
2347
|
-
splitType: unref(getSplitType),
|
|
2348
|
-
menuMode: unref(getMenuMode)
|
|
2349
|
-
}, null, 8, ["theme", "splitType", "menuMode"])
|
|
2350
|
-
])) : createCommentVNode("", true),
|
|
2351
|
-
createElementVNode("div", {
|
|
2352
|
-
class: "flex items-center",
|
|
2353
|
-
style: normalizeStyle({
|
|
2354
|
-
"padding-right": unref(getShowSettingTheme) ? "" : "20px"
|
|
2355
|
-
})
|
|
2356
|
-
}, [
|
|
2357
|
-
unref(slots).headerBefore ? (openBlock(), createBlock(unref(DtSlotContainer), {
|
|
2358
|
-
key: 0,
|
|
2359
|
-
template: unref(slots).headerBefore
|
|
2360
|
-
}, null, 8, ["template"])) : createCommentVNode("", true),
|
|
2361
|
-
unref(getShowSearch) ? (openBlock(), createBlock(_sfc_main$r, { key: 1 })) : createCommentVNode("", true),
|
|
2362
|
-
unref(getShowNotice) ? (openBlock(), createBlock(_sfc_main$q, { key: 2 })) : createCommentVNode("", true),
|
|
2363
|
-
unref(getShowFullScreen) ? (openBlock(), createBlock(_sfc_main$p, { key: 3 })) : createCommentVNode("", true),
|
|
2364
|
-
unref(getShowLocale) ? (openBlock(), createBlock(_sfc_main$o, {
|
|
2365
|
-
key: 4,
|
|
2366
|
-
reload: true
|
|
2367
|
-
})) : createCommentVNode("", true),
|
|
2368
|
-
unref(slots).headerAfter ? (openBlock(), createBlock(unref(DtSlotContainer), {
|
|
2369
|
-
key: 5,
|
|
2370
|
-
template: unref(slots).headerAfter
|
|
2371
|
-
}, null, 8, ["template"])) : createCommentVNode("", true),
|
|
2372
|
-
createVNode(_sfc_main$n),
|
|
2373
|
-
unref(getShowSettingTheme) ? (openBlock(), createBlock(_sfc_main$e, { key: 6 })) : createCommentVNode("", true)
|
|
2374
|
-
], 4)
|
|
2375
|
-
]),
|
|
2376
|
-
_: 1
|
|
2377
|
-
}, 8, ["class"]);
|
|
2378
|
-
};
|
|
2379
|
-
}
|
|
2380
|
-
});
|
|
2381
|
-
function useMenuSwitch() {
|
|
2382
|
-
const brokenRef = ref(false);
|
|
2383
|
-
const { getMiniWidthNumber } = useMenu();
|
|
2384
|
-
const getCollapsedWidth = computed(() => {
|
|
2385
|
-
return unref(brokenRef) ? 0 : unref(getMiniWidthNumber);
|
|
2386
|
-
});
|
|
2387
|
-
function onBreakPointChange(broken) {
|
|
2388
|
-
brokenRef.value = broken;
|
|
2389
|
-
}
|
|
2390
|
-
return { getCollapsedWidth, onBreakPointChange };
|
|
2391
|
-
}
|
|
2392
|
-
function useTrigger() {
|
|
2393
|
-
const { getTrigger, getSplit } = useMenu();
|
|
2394
|
-
const getShowTrigger = computed(() => {
|
|
2395
|
-
const trigger = unref(getTrigger);
|
|
2396
|
-
return trigger && unref(getSplit);
|
|
2397
|
-
});
|
|
2398
|
-
const getTriggerAttr = computed(() => {
|
|
2399
|
-
if (unref(getShowTrigger)) {
|
|
2400
|
-
return {};
|
|
2401
|
-
}
|
|
2402
|
-
return {
|
|
2403
|
-
trigger: null
|
|
2404
|
-
};
|
|
2405
|
-
});
|
|
2406
|
-
return { getTriggerAttr, getShowTrigger };
|
|
2407
|
-
}
|
|
2408
|
-
const _sfc_main$c = /* @__PURE__ */ defineComponent({
|
|
2409
|
-
__name: "SiderTrigger",
|
|
2410
|
-
props: {
|
|
2411
|
-
type: {
|
|
2412
|
-
type: String,
|
|
2413
|
-
default: null
|
|
2414
|
-
}
|
|
2415
|
-
},
|
|
2416
|
-
setup(__props) {
|
|
2417
|
-
const { getCollapsed, toggleCollapsed } = useMenu();
|
|
2418
|
-
return (_ctx, _cache) => {
|
|
2419
|
-
return openBlock(), createElementBlock("div", {
|
|
2420
|
-
onClick: _cache[0] || (_cache[0] = withModifiers(
|
|
2421
|
-
(...args) => unref(toggleCollapsed) && unref(toggleCollapsed)(...args),
|
|
2422
|
-
["stop"]
|
|
2423
|
-
))
|
|
2424
|
-
}, [
|
|
2425
|
-
createElementVNode("i", {
|
|
2426
|
-
class: normalizeClass(["i", unref(getCollapsed) ? "ant-design:double-right-outlined" : "ant-design:double-left-outlined"])
|
|
2427
|
-
}, null, 2)
|
|
2428
|
-
]);
|
|
2429
|
-
};
|
|
2430
|
-
}
|
|
2431
|
-
});
|
|
2432
|
-
const _sfc_main$b = /* @__PURE__ */ defineComponent({
|
|
2433
|
-
__name: "DragBar",
|
|
2434
|
-
setup(__props) {
|
|
2435
|
-
const { getCollapsed, getCanDrag, getMenuWidth } = useMenu();
|
|
2436
|
-
const getDragBarStyle = computed(() => {
|
|
2437
|
-
if (!unref(getCollapsed)) {
|
|
2438
|
-
return { left: `${unref(getMenuWidth)}px` };
|
|
2439
|
-
}
|
|
2440
|
-
return {};
|
|
2441
|
-
});
|
|
2442
|
-
const getClass = computed(() => {
|
|
2443
|
-
return [
|
|
2444
|
-
"dt-darg-bar",
|
|
2445
|
-
{
|
|
2446
|
-
"dt-darg-bar--hide": !unref(getCanDrag)
|
|
2447
|
-
}
|
|
2448
|
-
];
|
|
2449
|
-
});
|
|
2450
|
-
return (_ctx, _cache) => {
|
|
2451
|
-
return openBlock(), createElementBlock("div", {
|
|
2452
|
-
class: normalizeClass(unref(getClass)),
|
|
2453
|
-
style: normalizeStyle(unref(getDragBarStyle))
|
|
2454
|
-
}, null, 6);
|
|
2455
|
-
};
|
|
2456
|
-
}
|
|
2457
|
-
});
|
|
2458
|
-
const _hoisted_1$8 = { class: "dt-mix-sider__shallow-menu" };
|
|
2459
|
-
const _hoisted_2$4 = { class: "m-0" };
|
|
2460
|
-
const _hoisted_3$3 = { class: "dt-mix-sider__sub-shallow-menu" };
|
|
2461
|
-
const _hoisted_4$2 = { key: 0 };
|
|
2462
|
-
const _hoisted_5$2 = { class: "opacity-40 m-0 py-3 text-12px pt-6" };
|
|
2463
|
-
const _hoisted_6$2 = ["onClick"];
|
|
2464
|
-
const _hoisted_7$1 = { class: "m-0" };
|
|
2465
|
-
const _hoisted_8$1 = ["onClick"];
|
|
2466
|
-
const _hoisted_9$1 = { class: "m-0" };
|
|
2467
|
-
const MENU_WIDTH = 80;
|
|
2468
|
-
const _sfc_main$a = /* @__PURE__ */ defineComponent({
|
|
2469
|
-
__name: "MixSider",
|
|
2470
|
-
setup(__props) {
|
|
2471
|
-
const go = useGo();
|
|
2472
|
-
const menuModules = getShallowMenus();
|
|
2473
|
-
const { getMenuWidth, getMenuTheme, getMixSideTrigger } = useMenu();
|
|
2474
|
-
const getSubMenuStyle = computed(() => {
|
|
2475
|
-
return {
|
|
2476
|
-
width: `${unref(getMenuWidth) - MENU_WIDTH}px`,
|
|
2477
|
-
left: `${MENU_WIDTH}px`
|
|
2478
|
-
};
|
|
2479
|
-
});
|
|
2480
|
-
const subMenus = ref([]);
|
|
2481
|
-
const getDomStyle = computed(() => setDomWidth(`${unref(subMenus)?.length ? unref(getMenuWidth) : MENU_WIDTH}px`));
|
|
2482
|
-
function setDomWidth(width) {
|
|
2483
|
-
return {
|
|
2484
|
-
width,
|
|
2485
|
-
minWidth: width,
|
|
2486
|
-
maxWidth: width,
|
|
2487
|
-
flex: `0 0 ${width}`,
|
|
2488
|
-
transition: "all 0.2s"
|
|
2489
|
-
};
|
|
2490
|
-
}
|
|
2491
|
-
const getWrapStyle = computed(() => setDomWidth(`${MENU_WIDTH}px`));
|
|
2492
|
-
const getItemEvents = (item) => {
|
|
2493
|
-
if (unref(getMixSideTrigger) === "hover") {
|
|
2494
|
-
return {
|
|
2495
|
-
onMouseenter: () => handleModuleClick(item.url, true),
|
|
2496
|
-
onClick: () => handleModuleClick(item.url)
|
|
2497
|
-
};
|
|
2498
|
-
}
|
|
2499
|
-
return {
|
|
2500
|
-
onClick: () => handleModuleClick(item.url)
|
|
2501
|
-
};
|
|
2502
|
-
};
|
|
2503
|
-
function handleModuleClick(path, isHover = false) {
|
|
2504
|
-
setActive(path, isHover);
|
|
2505
|
-
if (!isHover) {
|
|
2506
|
-
go(path);
|
|
2507
|
-
}
|
|
2508
|
-
}
|
|
2509
|
-
const { setMixSiderIsHasMenu } = useThemeStore();
|
|
2510
|
-
const activeId = ref(null), activePath = ref(null), getMenuEvents = {
|
|
2511
|
-
onMouseleave: () => {
|
|
2512
|
-
setActive(unref(activePath));
|
|
2513
|
-
}
|
|
2514
|
-
};
|
|
2515
|
-
function setActive(path, isHover = false) {
|
|
2516
|
-
const pTree = getParentTreeByPath(path);
|
|
2517
|
-
if (!isHover) {
|
|
2518
|
-
activeId.value = pTree.id;
|
|
2519
|
-
}
|
|
2520
|
-
subMenus.value = pTree.children;
|
|
2521
|
-
setMixSiderIsHasMenu(Boolean(pTree.children?.length));
|
|
2522
|
-
}
|
|
2523
|
-
const { currentRoute = null } = useRouter();
|
|
2524
|
-
watchEffect(() => {
|
|
2525
|
-
if (!currentRoute || currentRoute.value.path === "/")
|
|
2526
|
-
return;
|
|
2527
|
-
const { meta, path } = unref(currentRoute);
|
|
2528
|
-
activePath.value = meta?.currentActiveMenu || path;
|
|
2529
|
-
setActive(unref(activePath));
|
|
2530
|
-
});
|
|
2531
|
-
return (_ctx, _cache) => {
|
|
2532
|
-
return openBlock(), createElementBlock(Fragment, null, [
|
|
2533
|
-
createElementVNode("div", {
|
|
2534
|
-
class: "h-full overflow-hidden",
|
|
2535
|
-
style: normalizeStyle(unref(getDomStyle))
|
|
2536
|
-
}, null, 4),
|
|
2537
|
-
createElementVNode("div", mergeProps({
|
|
2538
|
-
style: unref(getWrapStyle),
|
|
2539
|
-
class: ["dt-mix-sider fixed top-0 left-0 h-full overflow-hidden", unref(getMenuTheme)]
|
|
2540
|
-
}, getMenuEvents), [
|
|
2541
|
-
createVNode(_sfc_main$z, {
|
|
2542
|
-
showTitle: false,
|
|
2543
|
-
class: normalizeClass("justify-center z-10")
|
|
2544
|
-
}),
|
|
2545
|
-
createVNode(unref(DtScrollContainer), { class: "z-10" }, {
|
|
2546
|
-
default: withCtx(() => [
|
|
2547
|
-
createElementVNode("ul", _hoisted_1$8, [
|
|
2548
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(menuModules), (item) => {
|
|
2549
|
-
return openBlock(), createElementBlock("li", mergeProps({
|
|
2550
|
-
key: item.id,
|
|
2551
|
-
class: ["py-3 cursor-pointer relative text-center", {
|
|
2552
|
-
"active-menu": item.id === unref(activeId)
|
|
2553
|
-
}]
|
|
2554
|
-
}, getItemEvents(item)), [
|
|
2555
|
-
createElementVNode("i", {
|
|
2556
|
-
class: normalizeClass(["i", item.icon])
|
|
2557
|
-
}, null, 2),
|
|
2558
|
-
createElementVNode("p", _hoisted_2$4, toDisplayString(item.label), 1)
|
|
2559
|
-
], 16);
|
|
2560
|
-
}), 128))
|
|
2561
|
-
])
|
|
2562
|
-
]),
|
|
2563
|
-
_: 1
|
|
2564
|
-
}),
|
|
2565
|
-
createVNode(Transition, { name: "dt-mix-sider__animate" }, {
|
|
2566
|
-
default: withCtx(() => [
|
|
2567
|
-
unref(subMenus)?.length ? (openBlock(), createElementBlock("div", {
|
|
2568
|
-
key: 0,
|
|
2569
|
-
class: "fixed top-0 h-full sub-menu bg-white",
|
|
2570
|
-
style: normalizeStyle(unref(getSubMenuStyle))
|
|
2571
|
-
}, [
|
|
2572
|
-
createVNode(unref(DtScrollContainer), null, {
|
|
2573
|
-
default: withCtx(() => [
|
|
2574
|
-
createElementVNode("ul", _hoisted_3$3, [
|
|
2575
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(subMenus), (menu) => {
|
|
2576
|
-
return openBlock(), createElementBlock("li", {
|
|
2577
|
-
key: menu.id
|
|
2578
|
-
}, [
|
|
2579
|
-
menu.children?.length ? (openBlock(), createElementBlock("div", _hoisted_4$2, [
|
|
2580
|
-
createElementVNode("p", _hoisted_5$2, toDisplayString(menu.label), 1),
|
|
2581
|
-
createElementVNode("ul", null, [
|
|
2582
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(menu.children, (subMenu) => {
|
|
2583
|
-
return openBlock(), createElementBlock("li", {
|
|
2584
|
-
key: subMenu.id,
|
|
2585
|
-
class: normalizeClass(["flex cursor-pointer", {
|
|
2586
|
-
"active-menu": subMenu.url === unref(activePath)
|
|
2587
|
-
}]),
|
|
2588
|
-
onClick: ($event) => unref(go)(subMenu.url)
|
|
2589
|
-
}, [
|
|
2590
|
-
createElementVNode("p", _hoisted_7$1, toDisplayString(subMenu.label), 1)
|
|
2591
|
-
], 10, _hoisted_6$2);
|
|
2592
|
-
}), 128))
|
|
2593
|
-
])
|
|
2594
|
-
])) : (openBlock(), createElementBlock("div", {
|
|
2595
|
-
key: 1,
|
|
2596
|
-
class: normalizeClass(["sub-menu flex cursor-pointer", {
|
|
2597
|
-
"active-menu": menu.url === unref(activePath)
|
|
2598
|
-
}]),
|
|
2599
|
-
onClick: ($event) => unref(go)(menu.url)
|
|
2600
|
-
}, [
|
|
2601
|
-
createElementVNode("p", _hoisted_9$1, toDisplayString(menu.label), 1)
|
|
2602
|
-
], 10, _hoisted_8$1))
|
|
2603
|
-
]);
|
|
2604
|
-
}), 128))
|
|
2605
|
-
])
|
|
2606
|
-
]),
|
|
2607
|
-
_: 1
|
|
2608
|
-
})
|
|
2609
|
-
], 4)) : createCommentVNode("", true)
|
|
2610
|
-
]),
|
|
2611
|
-
_: 1
|
|
2612
|
-
})
|
|
2613
|
-
], 16)
|
|
2614
|
-
], 64);
|
|
2615
|
-
};
|
|
2616
|
-
}
|
|
2617
|
-
});
|
|
2618
|
-
const _sfc_main$9 = /* @__PURE__ */ defineComponent({
|
|
2619
|
-
__name: "index",
|
|
2620
|
-
setup(__props) {
|
|
2621
|
-
const {
|
|
2622
|
-
getIsMixSidebar,
|
|
2623
|
-
getMenuFixed,
|
|
2624
|
-
getRealWidth,
|
|
2625
|
-
getSplit,
|
|
2626
|
-
getMenuHidden,
|
|
2627
|
-
getIsMixMode,
|
|
2628
|
-
getMenuWidth,
|
|
2629
|
-
getCollapsed,
|
|
2630
|
-
getMenuTheme
|
|
2631
|
-
} = useMenu();
|
|
2632
|
-
const { getCollapsedWidth, onBreakPointChange } = useMenuSwitch();
|
|
2633
|
-
const { getTriggerAttr } = useTrigger();
|
|
2634
|
-
const hiddenDomStyle = computed(() => {
|
|
2635
|
-
const width = `${unref(getRealWidth)}px`;
|
|
2636
|
-
return {
|
|
2637
|
-
width,
|
|
2638
|
-
overflow: "hidden",
|
|
2639
|
-
flex: `0 0 ${width}`,
|
|
2640
|
-
maxWidth: width,
|
|
2641
|
-
minWidth: width,
|
|
2642
|
-
transition: "all 0.2s"
|
|
2643
|
-
};
|
|
2644
|
-
});
|
|
2645
|
-
const getSplitType = computed(() => {
|
|
2646
|
-
return unref(getSplit) ? MenuSplitTye.LEFT : MenuSplitTye.NONE;
|
|
2647
|
-
});
|
|
2648
|
-
const showClassSideBarRef = computed(() => {
|
|
2649
|
-
const { menusRef } = useSplitMenu(getSplitType);
|
|
2650
|
-
if (!unref(menusRef)?.length)
|
|
2651
|
-
return false;
|
|
2652
|
-
return unref(getSplit) ? !unref(getMenuHidden) : true;
|
|
2653
|
-
});
|
|
2654
|
-
const getSiderClass = computed(() => {
|
|
2655
|
-
let cls = `dt-sideBar overflow-hidden z-10 `;
|
|
2656
|
-
if (unref(getMenuFixed)) {
|
|
2657
|
-
cls += `dt-sideBar--fixed t-0 l-0 h-full `;
|
|
2658
|
-
}
|
|
2659
|
-
if (unref(getIsMixMode)) {
|
|
2660
|
-
cls += "dt-sideBar--mix ";
|
|
2661
|
-
}
|
|
2662
|
-
return cls;
|
|
2663
|
-
});
|
|
2664
|
-
const renderTrigger = h(_sfc_main$c);
|
|
2665
|
-
const getMode = computed(() => {
|
|
2666
|
-
return unref(getSplit) ? MenuMode.INLINE : null;
|
|
2667
|
-
});
|
|
2668
|
-
const dragBarRef = ref(null);
|
|
2669
|
-
const sideRef = ref(null);
|
|
2670
|
-
useDragLine(sideRef, dragBarRef);
|
|
2671
|
-
return (_ctx, _cache) => {
|
|
2672
|
-
const _component_ALayoutSider = LayoutSider;
|
|
2673
|
-
return unref(getIsMixSidebar) ? (openBlock(), createBlock(_sfc_main$a, { key: 0 })) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
2674
|
-
unref(getMenuFixed) ? withDirectives((openBlock(), createElementBlock("div", {
|
|
2675
|
-
key: 0,
|
|
2676
|
-
style: normalizeStyle(unref(hiddenDomStyle))
|
|
2677
|
-
}, null, 4)), [
|
|
2678
|
-
[vShow, unref(showClassSideBarRef)]
|
|
2679
|
-
]) : createCommentVNode("", true),
|
|
2680
|
-
withDirectives(createVNode(_component_ALayoutSider, mergeProps({
|
|
2681
|
-
ref_key: "sideRef",
|
|
2682
|
-
ref: sideRef,
|
|
2683
|
-
collapsible: "",
|
|
2684
|
-
class: unref(getSiderClass),
|
|
2685
|
-
width: unref(getMenuWidth),
|
|
2686
|
-
collapsed: unref(getCollapsed),
|
|
2687
|
-
collapsedWidth: unref(getCollapsedWidth),
|
|
2688
|
-
theme: unref(getMenuTheme),
|
|
2689
|
-
trigger: unref(renderTrigger)
|
|
2690
|
-
}, unref(getTriggerAttr), { onBreakpoint: unref(onBreakPointChange) }), {
|
|
2691
|
-
default: withCtx(() => [
|
|
2692
|
-
createVNode(_sfc_main$s, {
|
|
2693
|
-
theme: unref(getMenuTheme),
|
|
2694
|
-
menuMode: unref(getMode),
|
|
2695
|
-
splitType: unref(getSplitType)
|
|
2696
|
-
}, null, 8, ["theme", "menuMode", "splitType"]),
|
|
2697
|
-
createVNode(_sfc_main$b, {
|
|
2698
|
-
ref_key: "dragBarRef",
|
|
2699
|
-
ref: dragBarRef
|
|
2700
|
-
}, null, 512)
|
|
2701
|
-
]),
|
|
2702
|
-
_: 1
|
|
2703
|
-
}, 16, ["class", "width", "collapsed", "collapsedWidth", "theme", "trigger", "onBreakpoint"]), [
|
|
2704
|
-
[vShow, unref(showClassSideBarRef)]
|
|
2705
|
-
])
|
|
2706
|
-
], 64));
|
|
2707
|
-
};
|
|
2708
|
-
}
|
|
2709
|
-
});
|
|
2710
|
-
function initAffixTabs() {
|
|
2711
|
-
const tabStore = useRouteReuseStore();
|
|
2712
|
-
const filterAffixTabs = (routes = []) => {
|
|
2713
|
-
return routes && routes.reduce((tabs, route) => {
|
|
2714
|
-
if (route.meta && route.meta.affix) {
|
|
2715
|
-
tabs.push(toRaw(route));
|
|
2716
|
-
}
|
|
2717
|
-
return tabs;
|
|
2718
|
-
}, []);
|
|
2719
|
-
};
|
|
2720
|
-
const affixList = ref([]);
|
|
2721
|
-
const router = useRouter();
|
|
2722
|
-
const addAffixTabs = () => {
|
|
2723
|
-
const affixTabs = filterAffixTabs(router.getRoutes());
|
|
2724
|
-
affixList.value = affixTabs;
|
|
2725
|
-
for (const tab of affixTabs) {
|
|
2726
|
-
tabStore.addTab({
|
|
2727
|
-
meta: tab.meta,
|
|
2728
|
-
name: tab.name,
|
|
2729
|
-
path: tab.path
|
|
2730
|
-
});
|
|
2731
|
-
}
|
|
2732
|
-
};
|
|
2733
|
-
let isAddAffix = false;
|
|
2734
|
-
if (!isAddAffix) {
|
|
2735
|
-
addAffixTabs();
|
|
2736
|
-
isAddAffix = true;
|
|
2737
|
-
}
|
|
2738
|
-
return affixList.value.map((item) => item.meta?.title).filter(Boolean);
|
|
2739
|
-
}
|
|
2740
|
-
function useSortable(el, options) {
|
|
2741
|
-
function initSortable() {
|
|
2742
|
-
nextTick(async () => {
|
|
2743
|
-
if (!el)
|
|
2744
|
-
return;
|
|
2745
|
-
const Sortable = (await import("sortablejs")).default;
|
|
2746
|
-
Sortable.create(unref(el), {
|
|
2747
|
-
animation: 500,
|
|
2748
|
-
delay: 400,
|
|
2749
|
-
delayOnTouchOnly: true,
|
|
2750
|
-
...options
|
|
2751
|
-
});
|
|
2752
|
-
});
|
|
2753
|
-
}
|
|
2754
|
-
return { initSortable };
|
|
2755
|
-
}
|
|
2756
|
-
function useTabsDrag(affixList) {
|
|
2757
|
-
const tabStore = useRouteReuseStore();
|
|
2758
|
-
const { getCanDrag } = useMultipleTab();
|
|
2759
|
-
nextTick(() => {
|
|
2760
|
-
if (!unref(getCanDrag))
|
|
2761
|
-
return;
|
|
2762
|
-
const el = document.querySelectorAll(`.dt-reuse-tabs .ant-tabs-nav-list`)?.[0];
|
|
2763
|
-
const { initSortable } = useSortable(el, {
|
|
2764
|
-
filter: (e) => {
|
|
2765
|
-
const text = e?.target?.innerText;
|
|
2766
|
-
if (!text)
|
|
2767
|
-
return false;
|
|
2768
|
-
return affixList.includes(text);
|
|
2769
|
-
},
|
|
2770
|
-
onEnd: (evt) => {
|
|
2771
|
-
const { oldIndex, newIndex } = evt;
|
|
2772
|
-
if (isNullOrUnDef(oldIndex) || isNullOrUnDef(newIndex) || oldIndex === newIndex)
|
|
2773
|
-
return;
|
|
2774
|
-
tabStore.sortTabs(oldIndex, newIndex);
|
|
2775
|
-
}
|
|
2776
|
-
});
|
|
2777
|
-
initSortable();
|
|
2778
|
-
});
|
|
2779
|
-
}
|
|
2780
|
-
const _hoisted_1$7 = /* @__PURE__ */ createElementVNode("i", { class: "block i ic:baseline-autorenew" }, null, -1);
|
|
2781
|
-
const _hoisted_2$3 = [
|
|
2782
|
-
_hoisted_1$7
|
|
2783
|
-
];
|
|
2784
|
-
const _sfc_main$8 = /* @__PURE__ */ defineComponent({
|
|
2785
|
-
__name: "TabRedo",
|
|
2786
|
-
setup(__props) {
|
|
2787
|
-
const tabStore = useRouteReuseStore();
|
|
2788
|
-
const router = useRouter();
|
|
2789
|
-
function handleRedo() {
|
|
2790
|
-
tabStore.refreshPage(router);
|
|
2791
|
-
}
|
|
2792
|
-
return (_ctx, _cache) => {
|
|
2793
|
-
return openBlock(), createElementBlock("span", {
|
|
2794
|
-
onClick: handleRedo,
|
|
2795
|
-
class: "inline-block w-9 h-33px leading-32px text-zinc-600 text-center cursor-pointer border-l border-zinc-200 hover:text-zinc-900"
|
|
2796
|
-
}, _hoisted_2$3);
|
|
2797
|
-
};
|
|
2798
|
-
}
|
|
2799
|
-
});
|
|
2800
|
-
function menuList2Map() {
|
|
2801
|
-
const { getIsZH } = useHeader();
|
|
2802
|
-
let map = /* @__PURE__ */ new Map();
|
|
2803
|
-
const setMap = (menus) => {
|
|
2804
|
-
menus.forEach((menu) => {
|
|
2805
|
-
if (menu.url) {
|
|
2806
|
-
map.set(menu.url, unref(getIsZH) ? menu.label : menu.enLabel);
|
|
2807
|
-
}
|
|
2808
|
-
if (menu.children && menu.children.length)
|
|
2809
|
-
setMap(menu.children);
|
|
2810
|
-
});
|
|
2811
|
-
};
|
|
2812
|
-
setMap(getLocal(CacheKey.MENUS)?.children || []);
|
|
2813
|
-
return map;
|
|
2814
|
-
}
|
|
2815
|
-
function useTabs(_router) {
|
|
2816
|
-
const tabStore = useRouteReuseStore();
|
|
2817
|
-
const router = _router || useRouter();
|
|
2818
|
-
const { currentRoute } = router;
|
|
2819
|
-
const getCurrentTab = () => {
|
|
2820
|
-
const route = unref(currentRoute);
|
|
2821
|
-
return unref(tabStore.tabList).find((item) => item.fullPath === route.fullPath);
|
|
2822
|
-
};
|
|
2823
|
-
function handleTabAction(action, tab) {
|
|
2824
|
-
const currentTab = getCurrentTab();
|
|
2825
|
-
switch (action) {
|
|
2826
|
-
case 0:
|
|
2827
|
-
tabStore.refreshPage(router);
|
|
2828
|
-
break;
|
|
2829
|
-
case 1:
|
|
2830
|
-
tabStore.closeAllTab(currentRoute, router);
|
|
2831
|
-
break;
|
|
2832
|
-
case 2:
|
|
2833
|
-
tabStore.closeLeftTabs(currentTab, router);
|
|
2834
|
-
break;
|
|
2835
|
-
case 3:
|
|
2836
|
-
tabStore.closeRightTabs(currentTab, router);
|
|
2837
|
-
break;
|
|
2838
|
-
case 4:
|
|
2839
|
-
tabStore.closeOtherTabs(currentTab, router);
|
|
2840
|
-
break;
|
|
2841
|
-
case 5:
|
|
2842
|
-
case 6:
|
|
2843
|
-
tabStore.closeTab(tab || currentTab, router);
|
|
2844
|
-
}
|
|
2845
|
-
}
|
|
2846
|
-
return {
|
|
2847
|
-
refreshPage: () => handleTabAction(0),
|
|
2848
|
-
closeAll: () => handleTabAction(1),
|
|
2849
|
-
closeLeft: () => handleTabAction(2),
|
|
2850
|
-
closeRight: () => handleTabAction(3),
|
|
2851
|
-
closeOther: () => handleTabAction(4),
|
|
2852
|
-
closeCurrent: () => handleTabAction(5),
|
|
2853
|
-
close: (tab) => handleTabAction(6, tab)
|
|
2854
|
-
};
|
|
2855
|
-
}
|
|
2856
|
-
function useTabDropdown(tabItem, getIsTabs) {
|
|
2857
|
-
const router = useRouter();
|
|
2858
|
-
const { currentRoute } = router;
|
|
2859
|
-
const tabStore = useRouteReuseStore();
|
|
2860
|
-
const { refreshPage, closeAll, close, closeLeft, closeOther, closeRight } = useTabs();
|
|
2861
|
-
const getTargetTab = computed(() => {
|
|
2862
|
-
return unref(getIsTabs) ? tabItem : unref(currentRoute);
|
|
2863
|
-
});
|
|
2864
|
-
const state = reactive({
|
|
2865
|
-
current: null,
|
|
2866
|
-
currentIndex: 0
|
|
2867
|
-
});
|
|
2868
|
-
const getDropMenuList = computed(() => {
|
|
2869
|
-
const { t } = useI18n("UI");
|
|
2870
|
-
const { meta } = unref(getTargetTab);
|
|
2871
|
-
const { path } = unref(currentRoute);
|
|
2872
|
-
const curItem = state.current;
|
|
2873
|
-
const isCurItem = curItem ? curItem.path === path : false;
|
|
2874
|
-
const index = state.currentIndex;
|
|
2875
|
-
const refreshDisabled = !isCurItem;
|
|
2876
|
-
const closeLeftDisabled = index === 0 || !isCurItem;
|
|
2877
|
-
const closeRightDisabled = !isCurItem || index === unref(tabStore.tabList).length - 1 && unref(tabStore.lastDragEndIndex) >= 0;
|
|
2878
|
-
const disabled = unref(tabStore.tabList).length === 1;
|
|
2879
|
-
const dropMenuList = [
|
|
2880
|
-
{
|
|
2881
|
-
icon: "ic:baseline-autorenew",
|
|
2882
|
-
text: t("REFRESH"),
|
|
2883
|
-
onClick: refreshPage,
|
|
2884
|
-
disabled: refreshDisabled
|
|
2885
|
-
},
|
|
2886
|
-
{
|
|
2887
|
-
icon: "ic:baseline-close",
|
|
2888
|
-
text: t("CLOSE_CURRENT_TAG"),
|
|
2889
|
-
onClick: () => close(tabItem),
|
|
2890
|
-
disabled: !!meta?.affix || disabled,
|
|
2891
|
-
divider: true
|
|
2892
|
-
},
|
|
2893
|
-
{
|
|
2894
|
-
icon: "mdi:arrow-collapse-left",
|
|
2895
|
-
text: t("CLOSE_LEFT_TAGS"),
|
|
2896
|
-
onClick: closeLeft,
|
|
2897
|
-
disabled: closeLeftDisabled,
|
|
2898
|
-
divider: false
|
|
2899
|
-
},
|
|
2900
|
-
{
|
|
2901
|
-
icon: "mdi:arrow-collapse-right",
|
|
2902
|
-
text: t("CLOSE_RIGHT_TAGS"),
|
|
2903
|
-
onClick: closeRight,
|
|
2904
|
-
disabled: closeRightDisabled,
|
|
2905
|
-
divider: true
|
|
2906
|
-
},
|
|
2907
|
-
{
|
|
2908
|
-
icon: "ic:baseline-sync-alt",
|
|
2909
|
-
text: t("CLOSE_OTHER_TAGS"),
|
|
2910
|
-
onClick: closeOther,
|
|
2911
|
-
disabled: disabled || !isCurItem
|
|
2912
|
-
},
|
|
2913
|
-
{
|
|
2914
|
-
icon: "ic:baseline-horizontal-rule",
|
|
2915
|
-
text: t("CLOSE_ALL_TAGE"),
|
|
2916
|
-
onClick: closeAll,
|
|
2917
|
-
disabled
|
|
2918
|
-
}
|
|
2919
|
-
];
|
|
2920
|
-
return dropMenuList;
|
|
2921
|
-
});
|
|
2922
|
-
function handleContextMenu(tabItem2) {
|
|
2923
|
-
return (e) => {
|
|
2924
|
-
if (!tabItem2)
|
|
2925
|
-
return;
|
|
2926
|
-
e?.preventDefault();
|
|
2927
|
-
const index = unref(tabStore.tabList).findIndex((tab) => tab.path === tabItem2.path);
|
|
2928
|
-
state.current = tabItem2;
|
|
2929
|
-
state.currentIndex = index;
|
|
2930
|
-
};
|
|
2931
|
-
}
|
|
2932
|
-
function handleMenuEvent(item) {
|
|
2933
|
-
item.onClick?.();
|
|
2934
|
-
}
|
|
2935
|
-
return {
|
|
2936
|
-
getDropMenuList,
|
|
2937
|
-
handleContextMenu,
|
|
2938
|
-
handleMenuEvent
|
|
2939
|
-
};
|
|
2940
|
-
}
|
|
2941
|
-
const _hoisted_1$6 = /* @__PURE__ */ createElementVNode("i", { class: "block i ic:baseline-keyboard-arrow-down" }, null, -1);
|
|
2942
|
-
const _hoisted_2$2 = [
|
|
2943
|
-
_hoisted_1$6
|
|
2944
|
-
];
|
|
2945
|
-
const _hoisted_3$2 = { class: "text-13" };
|
|
2946
|
-
const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
2947
|
-
__name: "TabContent",
|
|
2948
|
-
props: {
|
|
2949
|
-
tabItem: {
|
|
2950
|
-
type: Object,
|
|
2951
|
-
default: null
|
|
2952
|
-
},
|
|
2953
|
-
isExtra: Boolean
|
|
2954
|
-
},
|
|
2955
|
-
setup(__props) {
|
|
2956
|
-
const props = __props;
|
|
2957
|
-
const { t } = useI18n("UI");
|
|
2958
|
-
const menuLabelMap = menuList2Map();
|
|
2959
|
-
const getIsTabs = computed(() => !props.isExtra);
|
|
2960
|
-
const getTrigger = computed(
|
|
2961
|
-
() => unref(getIsTabs) ? ["contextmenu"] : ["click"]
|
|
2962
|
-
);
|
|
2963
|
-
const { getDropMenuList, handleContextMenu, handleMenuEvent } = useTabDropdown(props?.tabItem, getIsTabs);
|
|
2964
|
-
function handleContext(e) {
|
|
2965
|
-
props.tabItem && handleContextMenu(props.tabItem)(e);
|
|
2966
|
-
}
|
|
2967
|
-
return (_ctx, _cache) => {
|
|
2968
|
-
const _component_AMenuItem = MenuItem;
|
|
2969
|
-
const _component_AMenuDivider = MenuDivider;
|
|
2970
|
-
const _component_AMenu = Menu;
|
|
2971
|
-
const _component_ADropdown = Dropdown;
|
|
2972
|
-
return openBlock(), createBlock(_component_ADropdown, {
|
|
2973
|
-
placement: "bottomRight",
|
|
2974
|
-
trigger: getTrigger.value,
|
|
2975
|
-
overlayClassName: "dt-reuse-tabs__dropdown"
|
|
2976
|
-
}, {
|
|
2977
|
-
overlay: withCtx(() => [
|
|
2978
|
-
createVNode(_component_AMenu, null, {
|
|
2979
|
-
default: withCtx(() => [
|
|
2980
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(getDropMenuList), (item, index) => {
|
|
2981
|
-
return openBlock(), createElementBlock(Fragment, null, [
|
|
2982
|
-
createVNode(_component_AMenuItem, {
|
|
2983
|
-
onClick: ($event) => unref(handleMenuEvent)(item),
|
|
2984
|
-
disabled: item.disabled
|
|
2985
|
-
}, {
|
|
2986
|
-
default: withCtx(() => [
|
|
2987
|
-
createElementVNode("i", {
|
|
2988
|
-
class: normalizeClass(["i pr-4", item.icon])
|
|
2989
|
-
}, null, 2),
|
|
2990
|
-
createElementVNode("span", _hoisted_3$2, toDisplayString(item.text), 1)
|
|
2991
|
-
]),
|
|
2992
|
-
_: 2
|
|
2993
|
-
}, 1032, ["onClick", "disabled"]),
|
|
2994
|
-
item.divider ? (openBlock(), createBlock(_component_AMenuDivider, {
|
|
2995
|
-
key: `d-${index}`
|
|
2996
|
-
})) : createCommentVNode("", true)
|
|
2997
|
-
], 64);
|
|
2998
|
-
}), 256))
|
|
2999
|
-
]),
|
|
3000
|
-
_: 1
|
|
3001
|
-
})
|
|
3002
|
-
]),
|
|
3003
|
-
default: withCtx(() => [
|
|
3004
|
-
getIsTabs.value ? (openBlock(), createElementBlock("div", {
|
|
3005
|
-
key: 0,
|
|
3006
|
-
onContextmenu: handleContext
|
|
3007
|
-
}, [
|
|
3008
|
-
createElementVNode("span", null, toDisplayString(unref(menuLabelMap).get(__props.tabItem.path) || __props.tabItem?.meta?.title || unref(t)("UNKNOWN_ROUTE")), 1)
|
|
3009
|
-
], 32)) : (openBlock(), createElementBlock("span", {
|
|
3010
|
-
key: 1,
|
|
3011
|
-
onClick: handleContext,
|
|
3012
|
-
class: "inline-block w-9 h-33px leading-32px text-zinc-600 text-center cursor-pointer border-l border-zinc-200 hover:text-zinc-900"
|
|
3013
|
-
}, _hoisted_2$2))
|
|
3014
|
-
]),
|
|
3015
|
-
_: 1
|
|
3016
|
-
}, 8, ["trigger"]);
|
|
3017
|
-
};
|
|
3018
|
-
}
|
|
3019
|
-
});
|
|
3020
|
-
const _hoisted_1$5 = { class: "dt-reuse-tabs" };
|
|
3021
|
-
const _sfc_main$6 = /* @__PURE__ */ defineComponent({
|
|
3022
|
-
__name: "index",
|
|
3023
|
-
setup(__props) {
|
|
3024
|
-
const router = useRouter();
|
|
3025
|
-
const go = useGo(router);
|
|
3026
|
-
const tabStore = useRouteReuseStore();
|
|
3027
|
-
const { getShowQuick, getShowRedo } = useMultipleTab();
|
|
3028
|
-
const activeKeyRef = ref(null);
|
|
3029
|
-
const getTabsState = computed(() => {
|
|
3030
|
-
return unref(tabStore.tabList).filter((item) => !item.meta?.hideTab);
|
|
3031
|
-
});
|
|
3032
|
-
const unClose = computed(() => unref(getTabsState).length === 1);
|
|
3033
|
-
function handleChange(activeKey) {
|
|
3034
|
-
activeKeyRef.value = activeKey;
|
|
3035
|
-
go(activeKey);
|
|
3036
|
-
}
|
|
3037
|
-
function handleEdit(targetKey) {
|
|
3038
|
-
if (unref(unClose))
|
|
3039
|
-
return;
|
|
3040
|
-
tabStore.closeTabByKey(targetKey, router);
|
|
3041
|
-
}
|
|
3042
|
-
const affixTextList = initAffixTabs();
|
|
3043
|
-
useTabsDrag(affixTextList);
|
|
3044
|
-
watch(
|
|
3045
|
-
() => router.currentRoute.value.path,
|
|
3046
|
-
(v) => {
|
|
3047
|
-
if (v === "/" || v === "/login")
|
|
3048
|
-
return;
|
|
3049
|
-
const { meta = {} } = unref(router.currentRoute);
|
|
3050
|
-
const { hideTab = false } = meta;
|
|
3051
|
-
if (activeKeyRef.value !== v) {
|
|
3052
|
-
activeKeyRef.value = v;
|
|
3053
|
-
}
|
|
3054
|
-
if (!hideTab) {
|
|
3055
|
-
tabStore.addTab(unref(router.currentRoute));
|
|
3056
|
-
}
|
|
3057
|
-
},
|
|
3058
|
-
{
|
|
3059
|
-
immediate: true
|
|
3060
|
-
}
|
|
3061
|
-
);
|
|
3062
|
-
return (_ctx, _cache) => {
|
|
3063
|
-
const _component_ATabPane = TabPane;
|
|
3064
|
-
const _component_ATabs = Tabs;
|
|
3065
|
-
return openBlock(), createElementBlock("div", _hoisted_1$5, [
|
|
3066
|
-
createVNode(_component_ATabs, {
|
|
3067
|
-
type: "editable-card",
|
|
3068
|
-
size: "small",
|
|
3069
|
-
animated: false,
|
|
3070
|
-
hideAdd: true,
|
|
3071
|
-
tabBarGutter: 3,
|
|
3072
|
-
activeKey: unref(activeKeyRef),
|
|
3073
|
-
onChange: handleChange,
|
|
3074
|
-
onEdit: handleEdit,
|
|
3075
|
-
class: "h-8"
|
|
3076
|
-
}, createSlots({
|
|
3077
|
-
default: withCtx(() => [
|
|
3078
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(getTabsState), (item) => {
|
|
3079
|
-
return openBlock(), createBlock(_component_ATabPane, {
|
|
3080
|
-
key: item.query ? item.fullPath : item.path,
|
|
3081
|
-
closable: !(item && item.meta && item.meta.affix)
|
|
3082
|
-
}, {
|
|
3083
|
-
tab: withCtx(() => [
|
|
3084
|
-
unref(getShowQuick) ? (openBlock(), createBlock(_sfc_main$7, {
|
|
3085
|
-
key: 0,
|
|
3086
|
-
tabItem: item
|
|
3087
|
-
}, null, 8, ["tabItem"])) : createCommentVNode("", true)
|
|
3088
|
-
]),
|
|
3089
|
-
_: 2
|
|
3090
|
-
}, 1032, ["closable"]);
|
|
3091
|
-
}), 128))
|
|
3092
|
-
]),
|
|
3093
|
-
_: 2
|
|
3094
|
-
}, [
|
|
3095
|
-
unref(getShowRedo) || unref(getShowQuick) ? {
|
|
3096
|
-
name: "rightExtra",
|
|
3097
|
-
fn: withCtx(() => [
|
|
3098
|
-
unref(getShowRedo) ? (openBlock(), createBlock(_sfc_main$8, { key: 0 })) : createCommentVNode("", true),
|
|
3099
|
-
unref(getShowQuick) ? (openBlock(), createBlock(_sfc_main$7, {
|
|
3100
|
-
key: 1,
|
|
3101
|
-
isExtra: "",
|
|
3102
|
-
tabItem: _ctx.$route
|
|
3103
|
-
}, null, 8, ["tabItem"])) : createCommentVNode("", true)
|
|
3104
|
-
]),
|
|
3105
|
-
key: "0"
|
|
3106
|
-
} : void 0
|
|
3107
|
-
]), 1032, ["activeKey"])
|
|
3108
|
-
]);
|
|
3109
|
-
};
|
|
3110
|
-
}
|
|
3111
|
-
});
|
|
3112
|
-
const _hoisted_1$4 = { class: "transition-width duration-200 z-10" };
|
|
3113
|
-
const _sfc_main$5 = /* @__PURE__ */ defineComponent({
|
|
3114
|
-
__name: "MultipleHeader",
|
|
3115
|
-
setup(__props) {
|
|
3116
|
-
const {
|
|
3117
|
-
getShowInsetHeaderRef
|
|
3118
|
-
} = useHeader();
|
|
3119
|
-
const { getShowMultipleTab, getMultipleTabPosIsTop } = useMultipleTab();
|
|
3120
|
-
return (_ctx, _cache) => {
|
|
3121
|
-
return openBlock(), createElementBlock("div", _hoisted_1$4, [
|
|
3122
|
-
unref(getShowInsetHeaderRef) ? (openBlock(), createBlock(_sfc_main$d, { key: 0 })) : createCommentVNode("", true),
|
|
3123
|
-
unref(getShowMultipleTab) && !unref(getMultipleTabPosIsTop) ? (openBlock(), createBlock(_sfc_main$6, { key: 1 })) : createCommentVNode("", true)
|
|
3124
|
-
]);
|
|
3125
|
-
};
|
|
3126
|
-
}
|
|
3127
|
-
});
|
|
3128
|
-
const _hoisted_1$3 = { class: "dt-lock-page" };
|
|
3129
|
-
const _hoisted_2$1 = { class: "absolute z-10 text-white text-center" };
|
|
3130
|
-
const _hoisted_3$1 = { class: "overflow-hidden bg-black" };
|
|
3131
|
-
const _hoisted_4$1 = /* @__PURE__ */ createElementVNode("div", { class: "relative box-border circle" }, null, -1);
|
|
3132
|
-
const _hoisted_5$1 = { class: "bubbles absolute left-1/2" };
|
|
3133
|
-
const _hoisted_6$1 = { class: "charging" };
|
|
3134
|
-
const _sfc_main$4 = /* @__PURE__ */ defineComponent({
|
|
3135
|
-
__name: "Recharge",
|
|
3136
|
-
props: {
|
|
3137
|
-
battery: {
|
|
3138
|
-
type: Object
|
|
3139
|
-
},
|
|
3140
|
-
calcDischargingTime: {
|
|
3141
|
-
type: String
|
|
3142
|
-
},
|
|
3143
|
-
calcChargingTime: {
|
|
3144
|
-
type: String
|
|
3145
|
-
},
|
|
3146
|
-
batteryStatus: {
|
|
3147
|
-
type: String,
|
|
3148
|
-
validator: (val) => ["\u5145\u7535\u4E2D", "\u5DF2\u5145\u6EE1", "\u5DF2\u65AD\u5F00\u7535\u6E90"].includes(val)
|
|
3149
|
-
}
|
|
3150
|
-
},
|
|
3151
|
-
setup(__props) {
|
|
3152
|
-
return (_ctx, _cache) => {
|
|
3153
|
-
return openBlock(), createElementBlock("div", _hoisted_1$3, [
|
|
3154
|
-
createElementVNode("div", _hoisted_2$1, toDisplayString(__props.battery?.level) + "%", 1),
|
|
3155
|
-
createElementVNode("div", _hoisted_3$1, [
|
|
3156
|
-
_hoisted_4$1,
|
|
3157
|
-
createElementVNode("ul", _hoisted_5$1, [
|
|
3158
|
-
(openBlock(), createElementBlock(Fragment, null, renderList(15, (i) => {
|
|
3159
|
-
return createElementVNode("li", { key: i });
|
|
3160
|
-
}), 64))
|
|
3161
|
-
])
|
|
3162
|
-
]),
|
|
3163
|
-
createElementVNode("div", _hoisted_6$1, [
|
|
3164
|
-
createElementVNode("div", null, toDisplayString(__props.batteryStatus), 1),
|
|
3165
|
-
withDirectives(createElementVNode("div", null, " \u5269\u4F59\u53EF\u4F7F\u7528\u65F6\u95F4\uFF1A" + toDisplayString(__props.calcDischargingTime), 513), [
|
|
3166
|
-
[vShow, Number.isFinite(__props.battery.dischargingTime) && __props.battery.dischargingTime != 0]
|
|
3167
|
-
]),
|
|
3168
|
-
withDirectives(createElementVNode("span", null, " \u8DDD\u79BB\u7535\u6C60\u5145\u6EE1\u9700\u8981\uFF1A" + toDisplayString(__props.calcChargingTime), 513), [
|
|
3169
|
-
[vShow, Number.isFinite(__props.battery.chargingTime) && __props.battery.chargingTime != 0]
|
|
3170
|
-
])
|
|
3171
|
-
])
|
|
3172
|
-
]);
|
|
3173
|
-
};
|
|
3174
|
-
}
|
|
3175
|
-
});
|
|
3176
|
-
function useBattery() {
|
|
3177
|
-
const state = reactive({
|
|
3178
|
-
battery: {
|
|
3179
|
-
charging: false,
|
|
3180
|
-
chargingTime: 0,
|
|
3181
|
-
dischargingTime: 0,
|
|
3182
|
-
level: 100
|
|
3183
|
-
}
|
|
3184
|
-
});
|
|
3185
|
-
function updateBattery(target) {
|
|
3186
|
-
for (const key in state.battery) {
|
|
3187
|
-
state.battery[key] = target[key];
|
|
3188
|
-
}
|
|
3189
|
-
state.battery.level = state.battery.level * 100;
|
|
3190
|
-
}
|
|
3191
|
-
const calcDischargingTime = computed(() => {
|
|
3192
|
-
const hour = state.battery.dischargingTime / 3600;
|
|
3193
|
-
const minute = state.battery.dischargingTime / 60 % 60;
|
|
3194
|
-
return `${hour}\u5C0F\u65F6${minute}\u5206\u949F`;
|
|
3195
|
-
});
|
|
3196
|
-
const calcChargingTime = computed(() => {
|
|
3197
|
-
const hour = state.battery.chargingTime / 3600;
|
|
3198
|
-
const minute = state.battery.chargingTime / 60 % 60;
|
|
3199
|
-
return `${hour}\u5C0F\u65F6${minute}\u5206\u949F`;
|
|
3200
|
-
});
|
|
3201
|
-
const batteryStatus = computed(() => {
|
|
3202
|
-
if (state.battery.charging && state.battery.level >= 100) {
|
|
3203
|
-
return "\u5DF2\u5145\u6EE1";
|
|
3204
|
-
} else if (state.battery.charging) {
|
|
3205
|
-
return "\u5145\u7535\u4E2D";
|
|
3206
|
-
} else {
|
|
3207
|
-
return "\u5DF2\u65AD\u5F00\u7535\u6E90";
|
|
3208
|
-
}
|
|
3209
|
-
});
|
|
3210
|
-
onMounted(async () => {
|
|
3211
|
-
const BatteryManager = await window.navigator.getBattery();
|
|
3212
|
-
updateBattery(BatteryManager);
|
|
3213
|
-
BatteryManager.onchargingchange = ({ target }) => {
|
|
3214
|
-
updateBattery(target);
|
|
3215
|
-
};
|
|
3216
|
-
BatteryManager.onchargingtimechange = ({ target }) => {
|
|
3217
|
-
updateBattery(target);
|
|
3218
|
-
};
|
|
3219
|
-
BatteryManager.ondischargingtimechange = ({ target }) => {
|
|
3220
|
-
updateBattery(target);
|
|
3221
|
-
};
|
|
3222
|
-
BatteryManager.onlevelchange = ({ target }) => {
|
|
3223
|
-
updateBattery(target);
|
|
3224
|
-
};
|
|
3225
|
-
});
|
|
3226
|
-
return {
|
|
3227
|
-
...toRefs(state),
|
|
3228
|
-
batteryStatus,
|
|
3229
|
-
calcDischargingTime,
|
|
3230
|
-
calcChargingTime
|
|
3231
|
-
};
|
|
3232
|
-
}
|
|
3233
|
-
function useTime() {
|
|
3234
|
-
let timer = null;
|
|
3235
|
-
let t = reactive({
|
|
3236
|
-
month: null,
|
|
3237
|
-
week: null,
|
|
3238
|
-
date: null,
|
|
3239
|
-
hour: null,
|
|
3240
|
-
minute: null
|
|
3241
|
-
});
|
|
3242
|
-
function updateTime() {
|
|
3243
|
-
const fillZero = (time) => time < 10 ? `0${time}` : `${time}`;
|
|
3244
|
-
t.hour = fillZero(dayjs().get("hour"));
|
|
3245
|
-
t.minute = fillZero(dayjs().get("minute"));
|
|
3246
|
-
t.month = fillZero(dayjs().get("month") + 1);
|
|
3247
|
-
t.date = fillZero(dayjs().get("date"));
|
|
3248
|
-
t.week = ["\u4E00", "\u4E8C", "\u4E09", "\u56DB", "\u4E94", "\u516D", "\u65E5"][dayjs().get("day") - 1];
|
|
3249
|
-
}
|
|
3250
|
-
updateTime();
|
|
3251
|
-
onMounted(() => {
|
|
3252
|
-
clearInterval(timer);
|
|
3253
|
-
timer = setInterval(() => updateTime(), 1e3);
|
|
3254
|
-
});
|
|
3255
|
-
onUnmounted(() => {
|
|
3256
|
-
clearInterval(timer);
|
|
3257
|
-
});
|
|
3258
|
-
return {
|
|
3259
|
-
...toRefs(t)
|
|
3260
|
-
};
|
|
3261
|
-
}
|
|
3262
|
-
const _hoisted_1$2 = { class: "lock-box absolute top-5 left-1/2 transform -translate-x-1/2 z-20" };
|
|
3263
|
-
const _hoisted_2 = { class: "flex justify-center" };
|
|
3264
|
-
const _hoisted_3 = /* @__PURE__ */ createElementVNode("i", { class: "i ic:baseline-lock" }, null, -1);
|
|
3265
|
-
const _hoisted_4 = [
|
|
3266
|
-
_hoisted_3
|
|
3267
|
-
];
|
|
3268
|
-
const _hoisted_5 = {
|
|
3269
|
-
key: 1,
|
|
3270
|
-
class: "lock-box absolute left-0 top-0 bottom-0 right-0 m-auto w-60 h-80"
|
|
3271
|
-
};
|
|
3272
|
-
const _hoisted_6 = ["src"];
|
|
3273
|
-
const _hoisted_7 = { class: "pb-3 block text-gray-300" };
|
|
3274
|
-
const _hoisted_8 = { class: "w-full mt-1 flex justify-around pt-2" };
|
|
3275
|
-
const _hoisted_9 = { class: "local-time absolute" };
|
|
3276
|
-
const _hoisted_10 = { class: "time" };
|
|
3277
|
-
const _hoisted_11 = { class: "date" };
|
|
3278
|
-
const _hoisted_12 = { class: "computer-status absolute flex flex-col" };
|
|
3279
|
-
const _hoisted_13 = /* @__PURE__ */ createElementVNode("i", { class: "i ant-design:wifi-outlined" }, null, -1);
|
|
3280
|
-
const _hoisted_14 = [
|
|
3281
|
-
_hoisted_13
|
|
3282
|
-
];
|
|
3283
|
-
const _hoisted_15 = /* @__PURE__ */ createElementVNode("i", { class: "i ant-design:api-outlined" }, null, -1);
|
|
3284
|
-
const _sfc_main$3 = /* @__PURE__ */ defineComponent({
|
|
3285
|
-
__name: "Lockscreen",
|
|
3286
|
-
setup(__props) {
|
|
3287
|
-
const go = useGo();
|
|
3288
|
-
let slots = getParentSlots(null, "dt-theme");
|
|
3289
|
-
const { loginOutClick } = useHeader();
|
|
3290
|
-
const getUserInfo = getLocal(CacheKey.USER_INFO);
|
|
3291
|
-
const useLockscreen = useLockscreenStore();
|
|
3292
|
-
const online = computed(() => navigator.onLine);
|
|
3293
|
-
const { month, week, date, hour, minute } = useTime();
|
|
3294
|
-
const state = reactive({
|
|
3295
|
-
showLogin: false,
|
|
3296
|
-
loginLoading: false,
|
|
3297
|
-
loginParams: {
|
|
3298
|
-
password: ""
|
|
3299
|
-
}
|
|
3300
|
-
});
|
|
3301
|
-
const onLockLogin = (value) => state.showLogin = value;
|
|
3302
|
-
const {
|
|
3303
|
-
battery,
|
|
3304
|
-
batteryStatus,
|
|
3305
|
-
calcDischargingTime,
|
|
3306
|
-
calcChargingTime
|
|
3307
|
-
} = useBattery();
|
|
3308
|
-
const goLogin = () => {
|
|
3309
|
-
useLockscreen.setLock(false);
|
|
3310
|
-
if (loginOutClick && isFunction(loginOutClick)) {
|
|
3311
|
-
loginOutClick();
|
|
3312
|
-
} else {
|
|
3313
|
-
go(Pages.LOGIN);
|
|
3314
|
-
}
|
|
3315
|
-
};
|
|
3316
|
-
function resetLockInfo() {
|
|
3317
|
-
useLockscreen.setLock(false);
|
|
3318
|
-
removeLocal(LOCKSCREEN);
|
|
3319
|
-
state.loginParams.password = null;
|
|
3320
|
-
}
|
|
3321
|
-
const onLogin = () => {
|
|
3322
|
-
let pwd = getLocal(LOCKSCREEN)?.pwd;
|
|
3323
|
-
if (state.loginParams.password === pwd) {
|
|
3324
|
-
resetLockInfo();
|
|
3325
|
-
}
|
|
3326
|
-
};
|
|
3327
|
-
return (_ctx, _cache) => {
|
|
3328
|
-
const _component_AInputPassword = InputPassword;
|
|
3329
|
-
return openBlock(), createElementBlock("div", {
|
|
3330
|
-
class: normalizeClass([{ onLockLogin: unref(state).showLogin }, "lockscreen fixed top-0 left-0 flex bg-black text-white overflow-hidden z-50 w-full h-full"]),
|
|
3331
|
-
onMousedown: _cache[3] || (_cache[3] = withModifiers(() => {
|
|
3332
|
-
}, ["stop"])),
|
|
3333
|
-
onContextmenu: _cache[4] || (_cache[4] = withModifiers(() => {
|
|
3334
|
-
}, ["prevent"]))
|
|
3335
|
-
}, [
|
|
3336
|
-
!unref(state).showLogin ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
3337
|
-
createElementVNode("div", _hoisted_1$2, [
|
|
3338
|
-
createElementVNode("div", _hoisted_2, [
|
|
3339
|
-
createElementVNode("span", {
|
|
3340
|
-
class: "cursor-pointer",
|
|
3341
|
-
title: "\u89E3\u9501\u5C4F\u5E55",
|
|
3342
|
-
onClick: _cache[0] || (_cache[0] = ($event) => onLockLogin(true))
|
|
3343
|
-
}, _hoisted_4)
|
|
3344
|
-
])
|
|
3345
|
-
]),
|
|
3346
|
-
createVNode(_sfc_main$4, {
|
|
3347
|
-
battery: unref(battery),
|
|
3348
|
-
"battery-status": unref(batteryStatus),
|
|
3349
|
-
"calc-discharging-time": unref(calcDischargingTime),
|
|
3350
|
-
"calc-charging-time": unref(calcChargingTime)
|
|
3351
|
-
}, null, 8, ["battery", "battery-status", "calc-discharging-time", "calc-charging-time"])
|
|
3352
|
-
], 64)) : (openBlock(), createElementBlock("div", _hoisted_5, [
|
|
3353
|
-
unref(slots)?.icon ? (openBlock(), createBlock(unref(DtSlotContainer), {
|
|
3354
|
-
key: 0,
|
|
3355
|
-
template: unref(slots).icon
|
|
3356
|
-
}, null, 8, ["template"])) : (openBlock(), createElementBlock("img", {
|
|
3357
|
-
key: 1,
|
|
3358
|
-
src: unref(txUrl)
|
|
3359
|
-
}, null, 8, _hoisted_6)),
|
|
3360
|
-
createElementVNode("span", _hoisted_7, toDisplayString(unref(getUserInfo)?.userNo), 1),
|
|
3361
|
-
createVNode(_component_AInputPassword, {
|
|
3362
|
-
class: "mt-2",
|
|
3363
|
-
autofocus: "",
|
|
3364
|
-
value: unref(state).loginParams.password,
|
|
3365
|
-
"onUpdate:value": _cache[1] || (_cache[1] = ($event) => unref(state).loginParams.password = $event),
|
|
3366
|
-
onKeyup: withKeys(onLogin, ["enter"]),
|
|
3367
|
-
placeholder: "\u8BF7\u8F93\u5165\u9501\u5C4F\u5BC6\u7801"
|
|
3368
|
-
}, null, 8, ["value", "onKeyup"]),
|
|
3369
|
-
createElementVNode("div", _hoisted_8, [
|
|
3370
|
-
createElementVNode("a", {
|
|
3371
|
-
onClick: _cache[2] || (_cache[2] = ($event) => unref(state).showLogin = false)
|
|
3372
|
-
}, "\u8FD4\u56DE"),
|
|
3373
|
-
createElementVNode("a", { onClick: goLogin }, "\u91CD\u65B0\u767B\u5F55"),
|
|
3374
|
-
createElementVNode("a", { onClick: onLogin }, "\u8FDB\u5165\u7CFB\u7EDF")
|
|
3375
|
-
])
|
|
3376
|
-
])),
|
|
3377
|
-
createElementVNode("div", _hoisted_9, [
|
|
3378
|
-
createElementVNode("div", _hoisted_10, toDisplayString(unref(hour)) + ":" + toDisplayString(unref(minute)), 1),
|
|
3379
|
-
createElementVNode("div", _hoisted_11, toDisplayString(unref(month)) + "\u6708" + toDisplayString(unref(date)) + "\u53F7\uFF0C\u661F\u671F" + toDisplayString(unref(week)), 1)
|
|
3380
|
-
]),
|
|
3381
|
-
createElementVNode("div", _hoisted_12, [
|
|
3382
|
-
createElementVNode("span", {
|
|
3383
|
-
class: normalizeClass([{ offline: !unref(online) }, "network"])
|
|
3384
|
-
}, _hoisted_14, 2),
|
|
3385
|
-
_hoisted_15
|
|
3386
|
-
])
|
|
3387
|
-
], 34);
|
|
3388
|
-
};
|
|
3389
|
-
}
|
|
3390
|
-
});
|
|
3391
|
-
const _hoisted_1$1 = ["loading"];
|
|
3392
|
-
const _sfc_main$2 = /* @__PURE__ */ defineComponent({
|
|
3393
|
-
__name: "index",
|
|
3394
|
-
setup(__props) {
|
|
3395
|
-
const { getTransitionMode } = useApp();
|
|
3396
|
-
const { getLayoutContentMode, getPageLoading } = useTheme();
|
|
3397
|
-
const { getCanCache } = useMultipleTab();
|
|
3398
|
-
const tabStore = useRouteReuseStore();
|
|
3399
|
-
const { currentRoute } = useRouter();
|
|
3400
|
-
const contentMode = computed(() => unref(currentRoute).meta.contentMode || unref(getLayoutContentMode));
|
|
3401
|
-
function getTransitionName(route) {
|
|
3402
|
-
return route.meta.transitionName || unref(getTransitionMode);
|
|
3403
|
-
}
|
|
3404
|
-
const getCaches = computed(() => {
|
|
3405
|
-
return tabStore.getCachedTabList;
|
|
3406
|
-
});
|
|
3407
|
-
return (_ctx, _cache) => {
|
|
3408
|
-
const _component_router_view = resolveComponent("router-view");
|
|
3409
|
-
const _component_ALayoutContent = LayoutContent;
|
|
3410
|
-
return openBlock(), createElementBlock("div", {
|
|
3411
|
-
id: "dt-layout-content",
|
|
3412
|
-
class: normalizeClass([["dt-layout-content", unref(contentMode)], "relative flex-auto min-h-0 flex flex-1 h-0"]),
|
|
3413
|
-
loading: unref(getPageLoading) && unref(getPageLoading)
|
|
3414
|
-
}, [
|
|
3415
|
-
createVNode(_component_ALayoutContent, { class: "overflow-y-auto overflow-x-hidden" }, {
|
|
3416
|
-
default: withCtx(() => [
|
|
3417
|
-
createVNode(_component_router_view, null, {
|
|
3418
|
-
default: withCtx(({ Component, route }) => [
|
|
3419
|
-
createVNode(Transition, {
|
|
3420
|
-
name: getTransitionName(route),
|
|
3421
|
-
mode: "out-in",
|
|
3422
|
-
appear: ""
|
|
3423
|
-
}, {
|
|
3424
|
-
default: withCtx(() => [
|
|
3425
|
-
!route.meta.hideTab && unref(getCanCache) ? (openBlock(), createBlock(KeepAlive, {
|
|
3426
|
-
key: 0,
|
|
3427
|
-
include: unref(getCaches)
|
|
3428
|
-
}, [
|
|
3429
|
-
(openBlock(), createBlock(resolveDynamicComponent(Component), {
|
|
3430
|
-
key: route.path
|
|
3431
|
-
}))
|
|
3432
|
-
], 1032, ["include"])) : (openBlock(), createBlock(resolveDynamicComponent(Component), { key: 1 }))
|
|
3433
|
-
]),
|
|
3434
|
-
_: 2
|
|
3435
|
-
}, 1032, ["name"])
|
|
3436
|
-
]),
|
|
3437
|
-
_: 1
|
|
3438
|
-
})
|
|
3439
|
-
]),
|
|
3440
|
-
_: 1
|
|
3441
|
-
})
|
|
3442
|
-
], 10, _hoisted_1$1);
|
|
3443
|
-
};
|
|
3444
|
-
}
|
|
3445
|
-
});
|
|
3446
|
-
const _hoisted_1 = { class: "pr-2.5" };
|
|
3447
|
-
const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
3448
|
-
__name: "index",
|
|
3449
|
-
setup(__props) {
|
|
3450
|
-
const slots = getParentSlots(null, "dt-theme");
|
|
3451
|
-
const { title, subTitle } = useThemeStore().themeConf.footerOptions;
|
|
3452
|
-
const footerOptions = computed(() => {
|
|
3453
|
-
return {
|
|
3454
|
-
padding: "0",
|
|
3455
|
-
color: "rgb(156,163,175)"
|
|
3456
|
-
};
|
|
3457
|
-
});
|
|
3458
|
-
return (_ctx, _cache) => {
|
|
3459
|
-
const _component_ALayoutFooter = LayoutFooter;
|
|
3460
|
-
return openBlock(), createBlock(_component_ALayoutFooter, {
|
|
3461
|
-
class: "dt-footer",
|
|
3462
|
-
style: normalizeStyle(unref(footerOptions))
|
|
3463
|
-
}, {
|
|
3464
|
-
default: withCtx(() => [
|
|
3465
|
-
unref(slots)?.footer ? (openBlock(), createBlock(unref(DtSlotContainer), {
|
|
3466
|
-
key: 0,
|
|
3467
|
-
template: unref(slots).footer
|
|
3468
|
-
}, null, 8, ["template"])) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
3469
|
-
createElementVNode("span", _hoisted_1, toDisplayString(unref(title)), 1),
|
|
3470
|
-
createElementVNode("span", null, toDisplayString(unref(subTitle)), 1)
|
|
3471
|
-
], 64))
|
|
3472
|
-
]),
|
|
3473
|
-
_: 1
|
|
3474
|
-
}, 8, ["style"]);
|
|
3475
|
-
};
|
|
3476
|
-
}
|
|
3477
|
-
});
|
|
3478
|
-
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
3479
|
-
__name: "index",
|
|
3480
|
-
setup(__props) {
|
|
3481
|
-
const { getShowFooter, getVars } = useTheme();
|
|
3482
|
-
const { currentRoute } = useRouter();
|
|
3483
|
-
const {
|
|
3484
|
-
getUiSize,
|
|
3485
|
-
getIsZH,
|
|
3486
|
-
getShowFullHeaderRef,
|
|
3487
|
-
getHeaderHeight,
|
|
3488
|
-
getLockscreen
|
|
3489
|
-
} = useHeader();
|
|
3490
|
-
const { getShowMenu, getIsMixSidebar, getSplit, getShowSidebar } = useMenu();
|
|
3491
|
-
dayjs.locale(unref(getIsZH) ? "zh-cn" : "en");
|
|
3492
|
-
const useLockscreen = useLockscreenStore();
|
|
3493
|
-
const isLock = computed(() => useLockscreen.isLock);
|
|
3494
|
-
const layoutClass = computed(() => {
|
|
3495
|
-
let cls = "ant-layout";
|
|
3496
|
-
if (unref(getIsMixSidebar)) {
|
|
3497
|
-
cls += " ant-layout-has-sider";
|
|
3498
|
-
}
|
|
3499
|
-
if (unref(getShowMenu)) {
|
|
3500
|
-
cls += " flex flex-row";
|
|
3501
|
-
}
|
|
3502
|
-
return cls;
|
|
3503
|
-
});
|
|
3504
|
-
const layoutOption = computed(() => {
|
|
3505
|
-
if (unref(getSplit)) {
|
|
3506
|
-
return {
|
|
3507
|
-
paddingTop: unref(getHeaderHeight) + "px",
|
|
3508
|
-
background: "#f0f2f5"
|
|
3509
|
-
};
|
|
3510
|
-
}
|
|
3511
|
-
});
|
|
3512
|
-
return (_ctx, _cache) => {
|
|
3513
|
-
const _component_ALayout = Layout;
|
|
3514
|
-
const _component_router_view = resolveComponent("router-view");
|
|
3515
|
-
const _component_AConfigProvider = ConfigProvider;
|
|
3516
|
-
return openBlock(), createElementBlock("div", {
|
|
3517
|
-
class: normalizeClass(["dt-theme", `dt-theme-${unref(getUiSize)}`])
|
|
3518
|
-
}, [
|
|
3519
|
-
!unref(isLock) ? (openBlock(), createBlock(_component_AConfigProvider, {
|
|
3520
|
-
key: 0,
|
|
3521
|
-
locale: unref(getIsZH) ? unref(zhCN) : unref(en),
|
|
3522
|
-
"component-size": unref(getUiSize),
|
|
3523
|
-
theme: unref(getVars)
|
|
3524
|
-
}, {
|
|
3525
|
-
default: withCtx(() => [
|
|
3526
|
-
unref(currentRoute)?.name && unref(currentRoute).meta?.requiresAuth !== false ? (openBlock(), createBlock(_component_ALayout, {
|
|
3527
|
-
key: 0,
|
|
3528
|
-
class: "w-full h-full flex"
|
|
3529
|
-
}, {
|
|
3530
|
-
default: withCtx(() => [
|
|
3531
|
-
createVNode(_sfc_main$A),
|
|
3532
|
-
unref(getShowFullHeaderRef) ? (openBlock(), createBlock(_sfc_main$d, {
|
|
3533
|
-
key: 0,
|
|
3534
|
-
fixed: ""
|
|
3535
|
-
})) : createCommentVNode("", true),
|
|
3536
|
-
createVNode(_component_ALayout, {
|
|
3537
|
-
class: normalizeClass(unref(layoutClass)),
|
|
3538
|
-
style: normalizeStyle(unref(layoutOption))
|
|
3539
|
-
}, {
|
|
3540
|
-
default: withCtx(() => [
|
|
3541
|
-
unref(getShowSidebar) ? (openBlock(), createBlock(_sfc_main$9, { key: 0 })) : createCommentVNode("", true),
|
|
3542
|
-
createVNode(_component_ALayout, { class: "dt-theme-main" }, {
|
|
3543
|
-
default: withCtx(() => [
|
|
3544
|
-
createVNode(_sfc_main$5),
|
|
3545
|
-
createVNode(_sfc_main$2),
|
|
3546
|
-
unref(getShowFooter) ? (openBlock(), createBlock(_sfc_main$1, { key: 0 })) : createCommentVNode("", true)
|
|
3547
|
-
]),
|
|
3548
|
-
_: 1
|
|
3549
|
-
})
|
|
3550
|
-
]),
|
|
3551
|
-
_: 1
|
|
3552
|
-
}, 8, ["class", "style"])
|
|
3553
|
-
]),
|
|
3554
|
-
_: 1
|
|
3555
|
-
})) : (openBlock(), createBlock(_component_router_view, { key: 1 }))
|
|
3556
|
-
]),
|
|
3557
|
-
_: 1
|
|
3558
|
-
}, 8, ["locale", "component-size", "theme"])) : createCommentVNode("", true),
|
|
3559
|
-
unref(getLockscreen) && unref(isLock) && unref(currentRoute)?.name && unref(currentRoute).meta?.requiresAuth !== false ? (openBlock(), createBlock(Transition, {
|
|
3560
|
-
key: 1,
|
|
3561
|
-
name: "fade-slide"
|
|
3562
|
-
}, {
|
|
3563
|
-
default: withCtx(() => [
|
|
3564
|
-
createVNode(_sfc_main$3)
|
|
3565
|
-
]),
|
|
3566
|
-
_: 1
|
|
3567
|
-
})) : createCommentVNode("", true)
|
|
3568
|
-
], 2);
|
|
3569
|
-
};
|
|
3570
|
-
}
|
|
3571
|
-
});
|
|
3572
|
-
const EN = {
|
|
3573
|
-
"UI": {
|
|
3574
|
-
"ADD": "Add ",
|
|
3575
|
-
"DELETE_CONFIRM": "Delete Confirm",
|
|
3576
|
-
"CONFIRM_DELETE": "Confirm that you want to delete the selected data\uFF1F",
|
|
3577
|
-
"NEED_CURD": "Missing curd function configuration, pass the curd parameter returned by useSource to the useCurd configuration option!",
|
|
3578
|
-
"EDIT": "Edit ",
|
|
3579
|
-
"EMPTY": "No Selected Data Yet!",
|
|
3580
|
-
"EMPTY_URL": "Request Url Can Not Empty!",
|
|
3581
|
-
"MULTIFY_DELETE_CONFIRM": "Batch Deletion Confirmation",
|
|
3582
|
-
"CONFIRM_MULTIFY_DELETE": "Confirm that you want to delete the selected data in batches?",
|
|
3583
|
-
"ADVANCED": "Retract",
|
|
3584
|
-
"EXPAND": "Expand",
|
|
3585
|
-
"SELECT_ICON": "Select Icon",
|
|
3586
|
-
"MUSE_FUNCTION": "openDialog must be a fouction",
|
|
3587
|
-
"NEED_RENDER": "Configure the render function",
|
|
3588
|
-
"SEARCH": "Search",
|
|
3589
|
-
"RESET": "Reset",
|
|
3590
|
-
"PLEASE_INPUT": "Please Input",
|
|
3591
|
-
"PLEASE_SELECT": "Please Select",
|
|
3592
|
-
"PLEASE_SET_ICON": "Please Set The Icon",
|
|
3593
|
-
"INPUT_FILTER": "Enter Filter Criteria",
|
|
3594
|
-
"EXIT_FULLSCREEN": "Exit Full Screen",
|
|
3595
|
-
"FULLSCREEN": "Full Screen",
|
|
3596
|
-
"SAVE": "Save",
|
|
3597
|
-
"CLOSE": "Close",
|
|
3598
|
-
"ADD_SUCCESS": "Add Success!",
|
|
3599
|
-
"UPDATE_SUCCESS": "Update data successfully!",
|
|
3600
|
-
"MULTIFY": "Batch",
|
|
3601
|
-
"DELETE_SUCCESS": "Successfully delete!",
|
|
3602
|
-
"COLUMN_CONTROL": "Column Control",
|
|
3603
|
-
"COLUMN_SHOW": "Column Show",
|
|
3604
|
-
"INDEX": "Serial Number",
|
|
3605
|
-
"CHECKBOX": "Checkbox",
|
|
3606
|
-
"FIXED_TO_LEFT": "Fixed to the left",
|
|
3607
|
-
"FIXED_TO_RIGHT": "Fixed to the right",
|
|
3608
|
-
"EXPORT": "Export",
|
|
3609
|
-
"DOWNLOAD_TEMPLATE": "Download Template",
|
|
3610
|
-
"EXPORT_CURRENT_PAGE": "Export the current page",
|
|
3611
|
-
"EXPORT_SELECT_COLUMN": "Export Selected columns",
|
|
3612
|
-
"EXPORT_ALL": "Export all columns",
|
|
3613
|
-
"SELECT_ALL": "Select All",
|
|
3614
|
-
"SETTING_EXPORT_COLUMN": "Setting the export column",
|
|
3615
|
-
"NO_EXPORT_COLUMN": "There are no exported columns!",
|
|
3616
|
-
"NUMBER": "Number",
|
|
3617
|
-
"ACTIONS": "Actions",
|
|
3618
|
-
"TOTAL_PAGE": "Total {total}",
|
|
3619
|
-
"FILTER": "Filter",
|
|
3620
|
-
"EXPAND_ALL": "Expand All",
|
|
3621
|
-
"COLLAPSE_ALL": "Collapse All",
|
|
3622
|
-
"SELECT_ALL1": "Select All",
|
|
3623
|
-
"CANCEL_SELECT_ALL": "Cancel Select All",
|
|
3624
|
-
"LEVEL_CONNECTION": "Level Connection",
|
|
3625
|
-
"LEVEL_SOLATE": "Independent Hierarchy",
|
|
3626
|
-
"LOADING": "Loading...",
|
|
3627
|
-
"SUPPORT_FILES": "Support {message} format",
|
|
3628
|
-
"MAX_SIZE": "Not exceeding {maxSize}M",
|
|
3629
|
-
"MAX_NUMBER": "A maximum of {maxNumber} files can be selected",
|
|
3630
|
-
"SUPPORT_TYPES": "Upload Types: pptx\u3001doc\u3001jpg\u3001jpeg\u3001png\u3001bmp\u3001gif\u3001xls\u3001xlsx\u3001txt\u3001rar\u3001zip\u30017z\u3001tar\u3001gz",
|
|
3631
|
-
"FILE_UPLOAD": "Files Upload",
|
|
3632
|
-
"FILE_NAME": "File Name",
|
|
3633
|
-
"FILE_STATUS": "Upload Status",
|
|
3634
|
-
"PREVIEW": "Preview",
|
|
3635
|
-
"DELETE": "Delete",
|
|
3636
|
-
"HISTORY_UPLOAD": "History Upload",
|
|
3637
|
-
"MAX_MB": "Only files up to {maxSize}MB can be uploaded!",
|
|
3638
|
-
"PRE_UPLOAD": "To Upload",
|
|
3639
|
-
"COMPANY_NAME": "Longi Co overseas tax system",
|
|
3640
|
-
"FILTER_MORE": "Menu Search...",
|
|
3641
|
-
"LARGE_SIZE": "Large Size",
|
|
3642
|
-
"MIDDLE_SIZE": "Middle Size",
|
|
3643
|
-
"SMALL_SIZE": "Small Size",
|
|
3644
|
-
"MODIFY_PASSWORD": "Modify Password",
|
|
3645
|
-
"LOGIN_OUT": "Log out",
|
|
3646
|
-
"REFRESH": "Refresh",
|
|
3647
|
-
"CLOSE_CURRENT_TAG": "Close the current tab",
|
|
3648
|
-
"CLOSE_LEFT_TAGS": "Close the left tab",
|
|
3649
|
-
"CLOSE_RIGHT_TAGS": "Close the right tab",
|
|
3650
|
-
"CLOSE_OTHER_TAGS": "Close other tabs",
|
|
3651
|
-
"CLOSE_ALL_TAGE": "Close All",
|
|
3652
|
-
"SETTING_THEME": "Style Settings",
|
|
3653
|
-
"PROJECT_SETTING": "Project Configuration",
|
|
3654
|
-
"NAV_MODE": "Navigation bar mode",
|
|
3655
|
-
"PRIMARY_COLOR": "Primary Color",
|
|
3656
|
-
"PAGE_SHOW": "Interface Display",
|
|
3657
|
-
"COPY": "Copy",
|
|
3658
|
-
"DRAWER_TIPS": "The function mainly real-time preview layout effect, more complete configuration in the src/core/Settings/theme.ts. The layout preview function will be turned off in production.",
|
|
3659
|
-
"FULL": "Flow-based",
|
|
3660
|
-
"FIXED": "Fixed width",
|
|
3661
|
-
"BREAD_CURB": "Bread crumbs",
|
|
3662
|
-
"MENU_FILTER": "Menu search",
|
|
3663
|
-
"NOTICE": "Notification",
|
|
3664
|
-
"SIZE": "Size",
|
|
3665
|
-
"SHOW_FULLE": "Page full screen",
|
|
3666
|
-
"LOCAL": "Internationalization",
|
|
3667
|
-
"ROUTE_REUSE": "Routing reuse",
|
|
3668
|
-
"SHOW_FOOTER": "Show Footer",
|
|
3669
|
-
"CONTENT_FIXED_WIDTH": "Content area width",
|
|
3670
|
-
"ON": "On",
|
|
3671
|
-
"OFF": "Off",
|
|
3672
|
-
"UNKNOWN_ROUTE": "Unknown route",
|
|
3673
|
-
"COPY_SUCCESS": "Copy Success\uFF01"
|
|
3674
|
-
}
|
|
3675
|
-
};
|
|
3676
|
-
const ZH = {
|
|
3677
|
-
"UI": {
|
|
3678
|
-
"ADD": "\u65B0\u589E",
|
|
3679
|
-
"DELETE_CONFIRM": "\u5220\u9664\u786E\u8BA4",
|
|
3680
|
-
"CONFIRM_DELETE": "\u786E\u8BA4\u8981\u5220\u9664\u9009\u4E2D\u7684\u6570\u636E\uFF1F",
|
|
3681
|
-
"NEED_CURD": "\u7F3A\u5C11curd\u51FD\u6570\u914D\u7F6E, \u8BF7\u5C06useSource\u4E2D\u8FD4\u56DE\u7684curd\u53C2\u6570\u4F20\u5165useCurd\u914D\u7F6E\u9879\u4E2D!",
|
|
3682
|
-
"EDIT": "\u7F16\u8F91",
|
|
3683
|
-
"EMPTY": "\u6682\u65E0\u9009\u4E2D\u7684\u6570\u636E!",
|
|
3684
|
-
"EMPTY_URL": "\u8BF7\u6C42url\u4E0D\u80FD\u4E3A\u7A7A!",
|
|
3685
|
-
"MULTIFY_DELETE_CONFIRM": "\u6279\u91CF\u5220\u9664\u786E\u8BA4",
|
|
3686
|
-
"CONFIRM_MULTIFY_DELETE": "\u786E\u8BA4\u8981\u6279\u91CF\u5220\u9664\u9009\u4E2D\u7684\u6570\u636E\uFF1F",
|
|
3687
|
-
"ADVANCED": "\u6536\u8D77",
|
|
3688
|
-
"EXPAND": "\u5C55\u5F00",
|
|
3689
|
-
"SELECT_ICON": "\u9009\u62E9\u5B57\u4F53\u56FE\u6807",
|
|
3690
|
-
"MUSE_FUNCTION": "openDialog\u5FC5\u987B\u662F\u51FD\u6570",
|
|
3691
|
-
"NEED_RENDER": "\u8BF7\u914D\u7F6Erender\u51FD\u6570",
|
|
3692
|
-
"SEARCH": "\u67E5\u8BE2",
|
|
3693
|
-
"RESET": "\u91CD\u7F6E",
|
|
3694
|
-
"PLEASE_INPUT": "\u8BF7\u8F93\u5165",
|
|
3695
|
-
"PLEASE_SELECT": "\u8BF7\u9009\u62E9",
|
|
3696
|
-
"PLEASE_SET_ICON": "\u8BF7\u8BBE\u7F6E\u56FE\u6807",
|
|
3697
|
-
"INPUT_FILTER": "\u8BF7\u8F93\u5165\u8FC7\u6EE4\u6761\u4EF6",
|
|
3698
|
-
"EXIT_FULLSCREEN": "\u9000\u51FA\u5168\u5C4F",
|
|
3699
|
-
"FULLSCREEN": "\u5168\u5C4F",
|
|
3700
|
-
"SAVE": "\u4FDD\u5B58",
|
|
3701
|
-
"CLOSE": "\u5173\u95ED",
|
|
3702
|
-
"ADD_SUCCESS": "\u65B0\u589E\u6210\u529F\uFF01",
|
|
3703
|
-
"UPDATE_SUCCESS": "\u66F4\u65B0\u6570\u636E\u6210\u529F\uFF01",
|
|
3704
|
-
"MULTIFY": "\u6279\u91CF",
|
|
3705
|
-
"DELETE_SUCCESS": "\u5220\u9664\u6210\u529F\uFF01",
|
|
3706
|
-
"COLUMN_CONTROL": "\u5217\u63A7\u5236",
|
|
3707
|
-
"COLUMN_SHOW": "\u5217\u5C55\u793A",
|
|
3708
|
-
"INDEX": "\u5E8F\u5217\u53F7",
|
|
3709
|
-
"CHECKBOX": "\u590D\u9009\u6846",
|
|
3710
|
-
"FIXED_TO_LEFT": "\u56FA\u5B9A\u5230\u5DE6\u4FA7",
|
|
3711
|
-
"FIXED_TO_RIGHT": "\u56FA\u5B9A\u5230\u53F3\u4FA7",
|
|
3712
|
-
"EXPORT": "\u5BFC\u51FA",
|
|
3713
|
-
"DOWNLOAD_TEMPLATE": "\u6A21\u677F\u4E0B\u8F7D",
|
|
3714
|
-
"EXPORT_CURRENT_PAGE": "\u5BFC\u51FA\u5F53\u524D\u9875",
|
|
3715
|
-
"EXPORT_SELECT_COLUMN": "\u5BFC\u51FA\u9009\u4E2D\u5217",
|
|
3716
|
-
"EXPORT_ALL": "\u5BFC\u51FA\u6240\u6709\u5217",
|
|
3717
|
-
"SELECT_ALL": "\u5168\u9009",
|
|
3718
|
-
"SETTING_EXPORT_COLUMN": "\u8BBE\u7F6E\u5BFC\u51FA\u5217",
|
|
3719
|
-
"NO_EXPORT_COLUMN": "\u6682\u65E0\u53EF\u5BFC\u51FA\u7684\u5217\uFF01",
|
|
3720
|
-
"NUMBER": "\u5E8F\u53F7",
|
|
3721
|
-
"ACTIONS": "\u64CD\u4F5C",
|
|
3722
|
-
"TOTAL_PAGE": "\u603B\u5171{total}\u6761",
|
|
3723
|
-
"FILTER": "\u641C\u7D22...",
|
|
3724
|
-
"EXPAND_ALL": "\u5C55\u5F00\u5168\u90E8",
|
|
3725
|
-
"COLLAPSE_ALL": "\u6298\u53E0\u5168\u90E8",
|
|
3726
|
-
"SELECT_ALL1": "\u9009\u62E9\u5168\u90E8",
|
|
3727
|
-
"CANCEL_SELECT_ALL": "\u53D6\u6D88\u9009\u62E9",
|
|
3728
|
-
"LEVEL_CONNECTION": "\u5C42\u7EA7\u5173\u8054",
|
|
3729
|
-
"LEVEL_SOLATE": "\u5C42\u7EA7\u72EC\u7ACB",
|
|
3730
|
-
"LOADING": "\u52A0\u8F7D\u4E2D...",
|
|
3731
|
-
"SUPPORT_FILES": "\u652F\u6301{message}\u683C\u5F0F",
|
|
3732
|
-
"MAX_SIZE": "\u4E0D\u8D85\u8FC7{maxSize}M",
|
|
3733
|
-
"MAX_NUMBER": "\u6700\u591A\u53EF\u9009\u62E9{maxNumber}\u4E2A\u6587\u4EF6",
|
|
3734
|
-
"SUPPORT_TYPES": "\u8BF7\u4E0A\u4F20pptx\u3001doc\u3001jpg\u3001jpeg\u3001png\u3001bmp\u3001gif\u3001xls\u3001xlsx\u3001txt\u3001rar\u3001zip\u30017z\u3001tar\u3001gz\u683C\u5F0F\u6587\u4EF6",
|
|
3735
|
-
"FILE_UPLOAD": "\u6587\u4EF6\u4E0A\u4F20",
|
|
3736
|
-
"FILE_NAME": "\u6587\u4EF6\u540D\u79F0",
|
|
3737
|
-
"FILE_STATUS": "\u4E0A\u4F20\u72B6\u6001",
|
|
3738
|
-
"PREVIEW": "\u9884\u89C8",
|
|
3739
|
-
"DELETE": "\u5220\u9664",
|
|
3740
|
-
"HISTORY_UPLOAD": "\u5386\u53F2\u4E0A\u4F20",
|
|
3741
|
-
"MAX_MB": "\u53EA\u80FD\u4E0A\u4F20\u4E0D\u8D85\u8FC7{maxSize}MB\u7684\u6587\u4EF6!",
|
|
3742
|
-
"PRE_UPLOAD": "\u5F85\u4E0A\u4F20",
|
|
3743
|
-
"COMPANY_NAME": "\u5B89\u5FBD\u6DF1\u8FEA\u4E2D\u53F0\u7CFB\u7EDF\u6A21\u677F",
|
|
3744
|
-
"FILTER_MORE": "\u83DC\u5355\u68C0\u7D22...",
|
|
3745
|
-
"LARGE_SIZE": "\u5927\u5C3A\u5BF8",
|
|
3746
|
-
"MIDDLE_SIZE": "\u4E2D\u5C3A\u5BF8",
|
|
3747
|
-
"SMALL_SIZE": "\u5C0F\u5C3A\u5BF8",
|
|
3748
|
-
"MODIFY_PASSWORD": "\u4FEE\u6539\u5BC6\u7801",
|
|
3749
|
-
"LOGIN_OUT": "\u9000\u51FA\u7CFB\u7EDF",
|
|
3750
|
-
"REFRESH": "\u91CD\u65B0\u52A0\u8F7D",
|
|
3751
|
-
"CLOSE_CURRENT_TAG": "\u5173\u95ED\u5F53\u524D",
|
|
3752
|
-
"CLOSE_LEFT_TAGS": "\u5173\u95ED\u5DE6\u4FA7",
|
|
3753
|
-
"CLOSE_RIGHT_TAGS": "\u5173\u95ED\u53F3\u4FA7",
|
|
3754
|
-
"CLOSE_OTHER_TAGS": "\u5173\u95ED\u5176\u4ED6",
|
|
3755
|
-
"CLOSE_ALL_TAGE": "\u5173\u95ED\u5168\u90E8",
|
|
3756
|
-
"SETTING_THEME": "\u98CE\u683C\u8BBE\u7F6E",
|
|
3757
|
-
"PROJECT_SETTING": "\u9879\u76EE\u914D\u7F6E",
|
|
3758
|
-
"NAV_MODE": "\u5BFC\u822A\u680F\u6A21\u5F0F",
|
|
3759
|
-
"PRIMARY_COLOR": "\u4E3B\u9898\u8272",
|
|
3760
|
-
"PAGE_SHOW": "\u754C\u9762\u663E\u793A",
|
|
3761
|
-
"COPY": "\u62F7\u8D1D",
|
|
3762
|
-
"DRAWER_TIPS": "\u8BE5\u529F\u80FD\u4E3B\u8981\u5B9E\u65F6\u9884\u89C8\u5404\u79CD\u5E03\u5C40\u6548\u679C\uFF0C\u66F4\u591A\u5B8C\u6574\u914D\u7F6E\u5728 src/core/settings/theme.ts \u4E2D\u8BBE\u7F6E\uFF0C\u5728\u751F\u4EA7\u73AF\u5883\u8BE5\u5E03\u5C40\u9884\u89C8\u529F\u80FD\u5C06\u88AB\u5173\u95ED\u3002",
|
|
3763
|
-
"FULL": "\u6D41\u5F0F",
|
|
3764
|
-
"FIXED": "\u5B9A\u5BBD",
|
|
3765
|
-
"BREAD_CURB": "\u9762\u5305\u5C51",
|
|
3766
|
-
"MENU_FILTER": "\u83DC\u5355\u68C0\u7D22",
|
|
3767
|
-
"NOTICE": "\u901A\u77E5\u516C\u544A",
|
|
3768
|
-
"SIZE": "\u5143\u7D20\u5C3A\u5BF8",
|
|
3769
|
-
"SHOW_FULLE": "\u9875\u9762\u5168\u5C4F",
|
|
3770
|
-
"LOCAL": "\u56FD\u9645\u5316",
|
|
3771
|
-
"ROUTE_REUSE": "\u8DEF\u7531\u590D\u7528",
|
|
3772
|
-
"SHOW_FOOTER": "\u663E\u793A\u5E95\u90E8",
|
|
3773
|
-
"CONTENT_FIXED_WIDTH": "\u5185\u5BB9\u533A\u57DF\u5BBD\u5EA6",
|
|
3774
|
-
"ON": "\u5F00",
|
|
3775
|
-
"OFF": "\u5173",
|
|
3776
|
-
"DOWNLOAD": "\u4E0B\u8F7D",
|
|
3777
|
-
"UNKNOWN_ROUTE": "\u672A\u77E5\u8DEF\u7531",
|
|
3778
|
-
"COPY_SUCCESS": "\u62F7\u8D1D\u6210\u529F\uFF01"
|
|
3779
|
-
}
|
|
3780
|
-
};
|
|
3781
|
-
const uiLang = (lang) => lang === Language.ZH ? ZH : EN;
|
|
3782
|
-
const DtTheme = withInstall(_sfc_main);
|
|
3783
|
-
export {
|
|
3784
|
-
DtTheme,
|
|
3785
|
-
UiSize,
|
|
3786
|
-
uiLang,
|
|
3787
|
-
useHeader,
|
|
3788
|
-
useMenu,
|
|
3789
|
-
useRouteReuseStore,
|
|
3790
|
-
useTheme,
|
|
3791
|
-
useThemeStore
|
|
3792
|
-
};
|