@ebubekirylmaz/link-test 1.0.0
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/.babelrc +3 -0
- package/.browserslistrc +1 -0
- package/.env +2 -0
- package/.eslintignore +3 -0
- package/.eslintrc.json +58 -0
- package/.gitattributes +1 -0
- package/.github/workflows/publish.yml +66 -0
- package/.prettierignore +1 -0
- package/.prettierrc +10 -0
- package/.storybook/main.js +15 -0
- package/.storybook/preview.js +17 -0
- package/.storybook/vitest.setup.js +6 -0
- package/README.md +1 -0
- package/cypress.config.js +11 -0
- package/index.js +1 -0
- package/package.json +111 -0
- package/project/.eslintrc.cjs +22 -0
- package/project/config.js +18 -0
- package/project/config.menu.js +39 -0
- package/project/config.template.js +31 -0
- package/project/cypress/e2e/layouts.cy.js +170 -0
- package/project/cypress/e2e/login.cy.js +35 -0
- package/project/cypress/e2e/selectbar.cy.js +80 -0
- package/project/cypress/fixtures/CONFIG/MENU_CONFIG.js +39 -0
- package/project/cypress/fixtures/EMPEROR/EMPERORS_GET.json +51 -0
- package/project/cypress/fixtures/EMPEROR/EMPERORS_POST.json +9 -0
- package/project/cypress/fixtures/OAUTH/GITHUB/user.json +46 -0
- package/project/cypress/fixtures/example.json +5 -0
- package/project/cypress/support/commands.js +104 -0
- package/project/cypress/support/e2e.js +1 -0
- package/project/cypress.config.js +10 -0
- package/project/index.html +12 -0
- package/project/media/ProjectIcons/3d.png +0 -0
- package/project/media/ProjectIcons/box.png +0 -0
- package/project/media/ProjectIcons/cafe.png +0 -0
- package/project/media/ProjectIcons/cargo.png +0 -0
- package/project/media/ProjectIcons/cloud.png +0 -0
- package/project/media/ProjectIcons/code.png +0 -0
- package/project/media/ProjectIcons/company.png +0 -0
- package/project/media/ProjectIcons/conversation.png +0 -0
- package/project/media/ProjectIcons/distributed.png +0 -0
- package/project/media/ProjectIcons/fingerprint.png +0 -0
- package/project/media/ProjectIcons/forest.png +0 -0
- package/project/media/ProjectIcons/headphones.png +0 -0
- package/project/media/ProjectIcons/office.png +0 -0
- package/project/media/ProjectIcons/path.png +0 -0
- package/project/media/ProjectIcons/printer.png +0 -0
- package/project/media/ProjectIcons/project.png +0 -0
- package/project/media/ProjectIcons/resume.png +0 -0
- package/project/media/ProjectIcons/rocket.png +0 -0
- package/project/media/ProjectIcons/rtruck.png +0 -0
- package/project/media/ProjectIcons/sign.png +0 -0
- package/project/media/ProjectIcons/site.png +0 -0
- package/project/media/ProjectIcons/truck.png +0 -0
- package/project/media/logo.png +0 -0
- package/project/package-lock.json +22434 -0
- package/project/package.json +42 -0
- package/project/public/assets/background/overlay_2.jpg +0 -0
- package/project/public/assets/illustrations/illustration_dashboard.png +0 -0
- package/project/public/media/largeLogo.png +0 -0
- package/project/public/media/logo.png +0 -0
- package/project/public/vite.svg +1 -0
- package/project/routes.jsx +47 -0
- package/project/server/mock.json +110 -0
- package/project/server/oauthMock.js +27 -0
- package/project/server/package-lock.json +1505 -0
- package/project/server/package.json +20 -0
- package/project/server/server.js +127 -0
- package/project/src/Container.jsx +7 -0
- package/project/src/components/ActionButton.jsx +18 -0
- package/project/src/hooks/useEmperor.jsx +21 -0
- package/project/src/http/index.js +39 -0
- package/project/src/main.jsx +10 -0
- package/project/src/pages/Battles.jsx +16 -0
- package/project/src/pages/Emperor.jsx +50 -0
- package/project/src/pages/index.jsx +33 -0
- package/project/src/theme.js +151 -0
- package/project/src/widgets/ActionButton.jsx +68 -0
- package/project/src/widgets/AddNewEmperor.jsx +120 -0
- package/project/src/widgets/ProjectContainer.jsx +27 -0
- package/project/vite.config.js +6 -0
- package/project/vite.config.js.timestamp-1709564450418-45fdd27900806.mjs +341 -0
- package/public/assets/background/overlay_2.jpg +0 -0
- package/public/assets/illustrations/illustration_dashboard.png +0 -0
- package/public/vite.svg +1 -0
- package/src/ContextProvider/ContextProvider.jsx +19 -0
- package/src/GlobalSnackMessage/GlobalSnackMessage.jsx +45 -0
- package/src/GlobalSnackMessage/index.js +1 -0
- package/src/GlobalSnackMessage/styles.js +3 -0
- package/src/Platform.jsx +76 -0
- package/src/RouteManager/RouteManager.jsx +56 -0
- package/src/RouteManager/index.js +1 -0
- package/src/assets/illustrations/avatar-shape.jsx +31 -0
- package/src/assets/illustrations/background-shape.jsx +37 -0
- package/src/assets/illustrations/booking-illustration.jsx +335 -0
- package/src/assets/illustrations/check-in-illustration.jsx +96 -0
- package/src/assets/illustrations/check-out-illustration.jsx +69 -0
- package/src/assets/illustrations/coming-soon-illustration.jsx +125 -0
- package/src/assets/illustrations/forbidden-illustration.jsx +95 -0
- package/src/assets/illustrations/index.js +2 -0
- package/src/assets/illustrations/maintenance-illustration.jsx +228 -0
- package/src/assets/illustrations/motivation-illustration.jsx +74 -0
- package/src/assets/illustrations/order-complete-illustration.jsx +126 -0
- package/src/assets/illustrations/page-not-found-illustration.jsx +81 -0
- package/src/assets/illustrations/seo-illustration.jsx +244 -0
- package/src/assets/illustrations/sever-error-illustration.jsx +152 -0
- package/src/assets/illustrations/upgrade-storage-illustration.jsx +161 -0
- package/src/assets/illustrations/upload-illustration.jsx +622 -0
- package/src/components/Iconify/Iconify.jsx +18 -0
- package/src/components/Iconify/index.js +1 -0
- package/src/components/MiniTopBar/MiniTopBar.jsx +25 -0
- package/src/components/MiniTopBar/index.js +1 -0
- package/src/components/MiniTopBar/styles.js +6 -0
- package/src/components/NucleoidLoginForm/NucleoidLoginForm.jsx +69 -0
- package/src/components/NucleoidLoginForm/index.js +1 -0
- package/src/components/NucleoidLoginForm/styles.js +3 -0
- package/src/components/Sidebar/Sidebar.jsx +76 -0
- package/src/components/Sidebar/index.js +1 -0
- package/src/components/Sidebar/styles.js +25 -0
- package/src/components/SocialLoginButtons/SocialLoginButtons.jsx +55 -0
- package/src/components/SocialLoginButtons/index.js +1 -0
- package/src/components/SocialLoginButtons/styles.js +3 -0
- package/src/components/TopNavBar/TopNavBar.jsx +186 -0
- package/src/components/TopNavBar/index.js +1 -0
- package/src/components/TopNavBar/styles.js +7 -0
- package/src/components/animate/index.js +4 -0
- package/src/components/animate/motion-container.jsx +38 -0
- package/src/components/animate/motion-lazy.jsx +11 -0
- package/src/components/animate/motion-viewport.jsx +30 -0
- package/src/components/animate/variants/actions.js +4 -0
- package/src/components/animate/variants/background.js +97 -0
- package/src/components/animate/variants/bounce.js +107 -0
- package/src/components/animate/variants/container.js +20 -0
- package/src/components/animate/variants/fade.js +127 -0
- package/src/components/animate/variants/flip.js +54 -0
- package/src/components/animate/variants/index.js +12 -0
- package/src/components/animate/variants/path.js +12 -0
- package/src/components/animate/variants/rotate.js +33 -0
- package/src/components/animate/variants/scale.js +54 -0
- package/src/components/animate/variants/slide.js +65 -0
- package/src/components/animate/variants/transition.js +20 -0
- package/src/components/animate/variants/zoom.js +130 -0
- package/src/components/chart/chart.js +69 -0
- package/src/components/chart/index.js +5 -0
- package/src/components/chart/use-chart.js +215 -0
- package/src/components/custom-popover/custom-popover.jsx +46 -0
- package/src/components/custom-popover/index.js +3 -0
- package/src/components/custom-popover/styles.js +84 -0
- package/src/components/custom-popover/use-popover.js +22 -0
- package/src/components/custom-popover/utils.js +100 -0
- package/src/components/file-thumbnail/download-button.jsx +39 -0
- package/src/components/file-thumbnail/file-thumbnail.jsx +72 -0
- package/src/components/file-thumbnail/index.js +5 -0
- package/src/components/file-thumbnail/utils.js +148 -0
- package/src/components/image/image.jsx +119 -0
- package/src/components/image/index.js +1 -0
- package/src/components/image/utils.js +15 -0
- package/src/components/label/index.js +1 -0
- package/src/components/label/label.jsx +51 -0
- package/src/components/label/styles.js +78 -0
- package/src/components/loading-screen/index.js +2 -0
- package/src/components/loading-screen/loading-screen.jsx +23 -0
- package/src/components/loading-screen/splash-screen.jsx +95 -0
- package/src/components/logo/index.js +1 -0
- package/src/components/logo/logo.jsx +61 -0
- package/src/components/logo/styles.js +17 -0
- package/src/components/nav-section/horizontal/index.js +1 -0
- package/src/components/nav-section/horizontal/nav-item.jsx +224 -0
- package/src/components/nav-section/horizontal/nav-list.jsx +113 -0
- package/src/components/nav-section/horizontal/nav-section-horizontal.jsx +41 -0
- package/src/components/nav-section/index.js +3 -0
- package/src/components/nav-section/mini/index.js +1 -0
- package/src/components/nav-section/mini/nav-item.jsx +242 -0
- package/src/components/nav-section/mini/nav-list.jsx +107 -0
- package/src/components/nav-section/mini/nav-section-mini.jsx +35 -0
- package/src/components/nav-section/vertical/index.js +1 -0
- package/src/components/nav-section/vertical/nav-item.jsx +294 -0
- package/src/components/nav-section/vertical/nav-list.jsx +66 -0
- package/src/components/nav-section/vertical/nav-section-vertical.jsx +74 -0
- package/src/components/scrollbar/index.js +1 -0
- package/src/components/scrollbar/scrollbar.jsx +39 -0
- package/src/components/scrollbar/styles.js +27 -0
- package/src/components/search-not-found/index.js +1 -0
- package/src/components/search-not-found/search-not-found.jsx +29 -0
- package/src/components/settings/context/index.js +2 -0
- package/src/components/settings/context/settings-context.js +14 -0
- package/src/components/settings/context/settings-provider.jsx +46 -0
- package/src/components/settings/drawer/base-option.jsx +52 -0
- package/src/components/settings/drawer/fullscreen-option.jsx +58 -0
- package/src/components/settings/drawer/index.js +1 -0
- package/src/components/settings/drawer/layout-options.jsx +144 -0
- package/src/components/settings/drawer/presets-options.jsx +53 -0
- package/src/components/settings/drawer/settings-drawer.jsx +189 -0
- package/src/components/settings/drawer/stretch-options.jsx +67 -0
- package/src/components/settings/index.js +3 -0
- package/src/components/svg-color/index.js +1 -0
- package/src/components/svg-color/svg-color.jsx +23 -0
- package/src/config/config.js +48 -0
- package/src/config/schemas.js +148 -0
- package/src/context/reducer.js +52 -0
- package/src/global.css +2 -0
- package/src/hooks/index.js +2 -0
- package/src/hooks/use-boolean.js +27 -0
- package/src/hooks/use-event-listener.js +34 -0
- package/src/hooks/use-local-storage.js +89 -0
- package/src/hooks/use-off-set-top.js +37 -0
- package/src/hooks/use-responsive.js +47 -0
- package/src/hooks/use-scroll-to-top.js +14 -0
- package/src/hooks/use-user.js +58 -0
- package/src/hooks/useApi.js +25 -0
- package/src/hooks/useItemsState.js +23 -0
- package/src/hooks/useProjects.js +24 -0
- package/src/hooks/useSettings.jsx +51 -0
- package/src/http/index.js +155 -0
- package/src/http/oauth.js +27 -0
- package/src/http/user.js +110 -0
- package/src/layouts/AppLayout.jsx +113 -0
- package/src/layouts/CompactLayout/CompactLayout.jsx +32 -0
- package/src/layouts/CompactLayout/index.js +1 -0
- package/src/layouts/DashboardLayout/DashboardLayout.jsx +87 -0
- package/src/layouts/DashboardLayout/config-navigation.jsx +0 -0
- package/src/layouts/DashboardLayout/header.jsx +104 -0
- package/src/layouts/DashboardLayout/index.js +2 -0
- package/src/layouts/DashboardLayout/main.jsx +64 -0
- package/src/layouts/DashboardLayout/nav-horizontal.jsx +62 -0
- package/src/layouts/DashboardLayout/nav-mini.jsx +99 -0
- package/src/layouts/DashboardLayout/nav-vertical.jsx +201 -0
- package/src/layouts/FullScreenLayout/FullScreenLayout.jsx +101 -0
- package/src/layouts/FullScreenLayout/index.js +1 -0
- package/src/layouts/FullScreenLayout/nav-horizontal.jsx +50 -0
- package/src/layouts/FullScreenLayout/nav-vertical.jsx +136 -0
- package/src/layouts/MainLayout/MainLayout.jsx +21 -0
- package/src/layouts/MainLayout/footer.jsx +153 -0
- package/src/layouts/MainLayout/header.jsx +81 -0
- package/src/layouts/MainLayout/index.js +1 -0
- package/src/layouts/MainLayout/nav/desktop/index.jsx +20 -0
- package/src/layouts/MainLayout/nav/desktop/nav-item.jsx +186 -0
- package/src/layouts/MainLayout/nav/desktop/nav-list.jsx +145 -0
- package/src/layouts/MainLayout/nav/mobile/index.jsx +60 -0
- package/src/layouts/MainLayout/nav/mobile/nav-item.jsx +90 -0
- package/src/layouts/MainLayout/nav/mobile/nav-list.jsx +72 -0
- package/src/layouts/Page.jsx +16 -0
- package/src/layouts/SimpleLayout/SimpleLayout.jsx +8 -0
- package/src/layouts/SimpleLayout/index.js +1 -0
- package/src/layouts/TwoSideLayout/TwoSideLayout.jsx +31 -0
- package/src/layouts/TwoSideLayout/index.js +1 -0
- package/src/layouts/auth/classic.jsx +95 -0
- package/src/layouts/auth/modern-compact.jsx +51 -0
- package/src/layouts/auth/modern.jsx +94 -0
- package/src/layouts/common/ProjectBar/index.jsx +325 -0
- package/src/layouts/common/ProjectBar/result-item.jsx +90 -0
- package/src/layouts/common/ProjectBar/utils.js +86 -0
- package/src/layouts/common/account-popover.jsx +116 -0
- package/src/layouts/common/header-shadow.jsx +26 -0
- package/src/layouts/common/header-sim.jsx +52 -0
- package/src/layouts/common/header-simple.jsx +76 -0
- package/src/layouts/common/nav-toggle-button.jsx +57 -0
- package/src/layouts/common/notifications-popover/index.jsx +177 -0
- package/src/layouts/common/notifications-popover/notification-item.jsx +252 -0
- package/src/layouts/common/settings-button.jsx +48 -0
- package/src/layouts/config-layout.js +12 -0
- package/src/layouts/index.js +7 -0
- package/src/lib/AddItemWizard/AddItemWizard.jsx +211 -0
- package/src/lib/AddItemWizard/index.js +1 -0
- package/src/lib/CustomBreadcrumbs/CustomBreadcrumbs.jsx +88 -0
- package/src/lib/CustomBreadcrumbs/index.js +1 -0
- package/src/lib/CustomBreadcrumbs/link-item.jsx +58 -0
- package/src/lib/CustomPopover/CustomPopover.jsx +46 -0
- package/src/lib/CustomPopover/index.js +3 -0
- package/src/lib/CustomPopover/styles.js +82 -0
- package/src/lib/CustomPopover/usePopover.js +20 -0
- package/src/lib/CustomPopover/utils.js +100 -0
- package/src/lib/Flow/connectors/DynamicConnector.jsx +247 -0
- package/src/lib/Flow/core/Flow.jsx +79 -0
- package/src/lib/Flow/core/FlowNode.jsx +68 -0
- package/src/lib/Flow/core/FlowViewport.jsx +259 -0
- package/src/lib/Flow/graph/FloatingGraph.jsx +44 -0
- package/src/lib/Flow/hooks/useGraphOperations.js +362 -0
- package/src/lib/Flow/hooks/useNodeStyle.js +56 -0
- package/src/lib/Flow/index.js +1 -0
- package/src/lib/Flow/layouts/ActionNode.jsx +78 -0
- package/src/lib/Flow/layouts/AnimatedNode.jsx +22 -0
- package/src/lib/Flow/layouts/CardLayout.jsx +397 -0
- package/src/lib/Flow/layouts/InfoNode.jsx +255 -0
- package/src/lib/Flow/layouts/LoadingNode.jsx +37 -0
- package/src/lib/Flow/nodes/DefaultCard.jsx +107 -0
- package/src/lib/Flow/nodes/DraggableNode.jsx +162 -0
- package/src/lib/Flow/nodes/FlowNodeView.jsx +214 -0
- package/src/lib/Flow/selection/SelectionContext.jsx +259 -0
- package/src/lib/Flow/selection/SelectionOverlay.jsx +31 -0
- package/src/lib/Flow/styles.js +154 -0
- package/src/lib/Flow/utils/flowUtils.js +268 -0
- package/src/lib/FormProvider/FormProvider.jsx +16 -0
- package/src/lib/FormProvider/index.js +1 -0
- package/src/lib/IconSelector/IconSelector.jsx +89 -0
- package/src/lib/Iconify/Iconify.jsx +17 -0
- package/src/lib/Iconify/index.js +1 -0
- package/src/lib/Image/Image.jsx +116 -0
- package/src/lib/Image/index.js +1 -0
- package/src/lib/Image/utils.js +15 -0
- package/src/lib/ItemSummary/ItemSummary.jsx +77 -0
- package/src/lib/ItemSummary/ItemsSummary.jsx +163 -0
- package/src/lib/Label/Label.jsx +51 -0
- package/src/lib/Label/index.js +1 -0
- package/src/lib/Label/styles.js +76 -0
- package/src/lib/ProjectWizard.jsx +137 -0
- package/src/lib/RHFTextfield/RHFTextfield.jsx +39 -0
- package/src/lib/RHFTextfield/index.js +1 -0
- package/src/lib/Scrollbar/Scrollbar.jsx +39 -0
- package/src/lib/Scrollbar/index.js +1 -0
- package/src/lib/Scrollbar/styles.js +27 -0
- package/src/lib/SearchNotFound/SearchNotFound.jsx +29 -0
- package/src/lib/SearchNotFound/index.js +1 -0
- package/src/lib/SparkleInput/SparkleInput.jsx +51 -0
- package/src/lib/StepComponent/StepComponent.jsx +98 -0
- package/src/lib/SvgColor/SvgColor.jsx +28 -0
- package/src/lib/SvgColor/index.js +1 -0
- package/src/lib/TableHeadCustom/TableHeadCustom.jsx +87 -0
- package/src/lib/TableHeadCustom/index.js +1 -0
- package/src/lib/TableSelectedAction/TableSelectedAction.jsx +72 -0
- package/src/lib/TableSelectedAction/index.js +1 -0
- package/src/lib/index.js +36 -0
- package/src/lib/lib/Icons.js +40 -0
- package/src/lib/lib/context.json +272 -0
- package/src/lib/useChart/useChart.js +179 -0
- package/src/lib/useTable/useTable.js +121 -0
- package/src/pages/404.jsx +17 -0
- package/src/pages/Callback.jsx +126 -0
- package/src/pages/ConfigError.jsx +49 -0
- package/src/pages/LoginPage.jsx +43 -0
- package/src/routes/components/index.js +1 -0
- package/src/routes/components/router-link.jsx +11 -0
- package/src/routes/hooks/index.js +4 -0
- package/src/routes/hooks/use-active-link.js +15 -0
- package/src/routes/hooks/use-pathname.js +10 -0
- package/src/routes/hooks/use-router.js +21 -0
- package/src/stories/FlowChart.stories.jsx +333 -0
- package/src/stories/Iconify.stories.jsx +183 -0
- package/src/stories/Label.stories.jsx +447 -0
- package/src/stories/Navbar.stories.jsx +588 -0
- package/src/theme/css.js +152 -0
- package/src/theme/custom-shadows.js +47 -0
- package/src/theme/index.jsx +100 -0
- package/src/theme/options/contrast.js +34 -0
- package/src/theme/options/presets.js +89 -0
- package/src/theme/options/right-to-left.jsx +26 -0
- package/src/theme/overrides/components/accordion.js +43 -0
- package/src/theme/overrides/components/alert.js +69 -0
- package/src/theme/overrides/components/appbar.js +13 -0
- package/src/theme/overrides/components/autocomplete.js +44 -0
- package/src/theme/overrides/components/avatar.js +111 -0
- package/src/theme/overrides/components/backdrop.js +18 -0
- package/src/theme/overrides/components/badge.js +90 -0
- package/src/theme/overrides/components/breadcrumbs.js +21 -0
- package/src/theme/overrides/components/button-group.js +90 -0
- package/src/theme/overrides/components/button.js +145 -0
- package/src/theme/overrides/components/card.js +30 -0
- package/src/theme/overrides/components/checkbox.js +13 -0
- package/src/theme/overrides/components/chip.js +129 -0
- package/src/theme/overrides/components/css-baseline.js +48 -0
- package/src/theme/overrides/components/data-grid.js +94 -0
- package/src/theme/overrides/components/date-picker.jsx +94 -0
- package/src/theme/overrides/components/dialog.js +49 -0
- package/src/theme/overrides/components/drawer.js +39 -0
- package/src/theme/overrides/components/fab.js +165 -0
- package/src/theme/overrides/components/list.js +33 -0
- package/src/theme/overrides/components/loading-button.js +30 -0
- package/src/theme/overrides/components/menu.js +15 -0
- package/src/theme/overrides/components/pagination.js +81 -0
- package/src/theme/overrides/components/paper.js +18 -0
- package/src/theme/overrides/components/popover.js +20 -0
- package/src/theme/overrides/components/progress.js +40 -0
- package/src/theme/overrides/components/radio.js +22 -0
- package/src/theme/overrides/components/rating.js +40 -0
- package/src/theme/overrides/components/select.js +26 -0
- package/src/theme/overrides/components/skeleton.js +16 -0
- package/src/theme/overrides/components/slider.js +30 -0
- package/src/theme/overrides/components/stepper.js +13 -0
- package/src/theme/overrides/components/svg-icon.js +15 -0
- package/src/theme/overrides/components/switch.js +66 -0
- package/src/theme/overrides/components/table.js +79 -0
- package/src/theme/overrides/components/tabs.js +39 -0
- package/src/theme/overrides/components/textfield.js +146 -0
- package/src/theme/overrides/components/timeline.js +20 -0
- package/src/theme/overrides/components/toggle-button.js +70 -0
- package/src/theme/overrides/components/tooltip.js +18 -0
- package/src/theme/overrides/components/tree-view.js +16 -0
- package/src/theme/overrides/components/typography.js +16 -0
- package/src/theme/overrides/default-props.jsx +238 -0
- package/src/theme/overrides/index.js +100 -0
- package/src/theme/palette.js +144 -0
- package/src/theme/shadows.js +41 -0
- package/src/theme/typography.js +107 -0
- package/src/utils/flatten-array.js +16 -0
- package/src/utils/format-number.js +37 -0
- package/src/utils/format-time.js +27 -0
- package/src/utils/storage-available.js +24 -0
- package/src/widgets/Login/CognitoLogin.jsx +43 -0
- package/src/widgets/Login/Login.jsx +58 -0
- package/src/widgets/Login/cognitoAuth.jsx +26 -0
- package/src/widgets/LoginForm/LoginForm.jsx +87 -0
- package/src/widgets/LoginForm/LoginFormStyles.js +43 -0
- package/src/widgets/LoginForm/index.js +1 -0
- package/src/widgets/SettingsDialog.jsx +308 -0
- package/src/widgets/error/index.js +1 -0
- package/src/widgets/error/not-found-view.jsx +42 -0
- package/vite/vite.js +77 -0
- package/vite.config.js +7 -0
- package/vitest.config.js +32 -0
|
@@ -0,0 +1,224 @@
|
|
|
1
|
+
import Box from "@mui/material/Box";
|
|
2
|
+
import Iconify from "../../Iconify";
|
|
3
|
+
import Link from "@mui/material/Link";
|
|
4
|
+
import ListItemButton from "@mui/material/ListItemButton";
|
|
5
|
+
import React from "react";
|
|
6
|
+
import { RouterLink } from "../../../routes/components";
|
|
7
|
+
import Tooltip from "@mui/material/Tooltip";
|
|
8
|
+
import { forwardRef } from "react";
|
|
9
|
+
import { styled } from "@mui/material/styles";
|
|
10
|
+
|
|
11
|
+
const NavItem = forwardRef(
|
|
12
|
+
(
|
|
13
|
+
{
|
|
14
|
+
title,
|
|
15
|
+
path,
|
|
16
|
+
icon,
|
|
17
|
+
info,
|
|
18
|
+
disabled,
|
|
19
|
+
caption,
|
|
20
|
+
roles,
|
|
21
|
+
//
|
|
22
|
+
open,
|
|
23
|
+
depth,
|
|
24
|
+
active,
|
|
25
|
+
hasChild,
|
|
26
|
+
externalLink,
|
|
27
|
+
currentRole = "admin",
|
|
28
|
+
...other
|
|
29
|
+
},
|
|
30
|
+
ref
|
|
31
|
+
) => {
|
|
32
|
+
const subItem = depth !== 1;
|
|
33
|
+
|
|
34
|
+
const renderContent = (
|
|
35
|
+
<StyledNavItem
|
|
36
|
+
ref={ref}
|
|
37
|
+
open={open}
|
|
38
|
+
depth={depth}
|
|
39
|
+
active={active}
|
|
40
|
+
disabled={disabled}
|
|
41
|
+
{...other}
|
|
42
|
+
>
|
|
43
|
+
{icon && (
|
|
44
|
+
<Box component="span" className="icon">
|
|
45
|
+
<Iconify width={16} icon={icon} />
|
|
46
|
+
</Box>
|
|
47
|
+
)}
|
|
48
|
+
|
|
49
|
+
{title && (
|
|
50
|
+
<Box component="span" className="label">
|
|
51
|
+
{title}
|
|
52
|
+
</Box>
|
|
53
|
+
)}
|
|
54
|
+
|
|
55
|
+
{caption && (
|
|
56
|
+
<Tooltip title={caption} arrow>
|
|
57
|
+
<Iconify width={16} icon="eva:info-outline" className="caption" />
|
|
58
|
+
</Tooltip>
|
|
59
|
+
)}
|
|
60
|
+
|
|
61
|
+
{info && (
|
|
62
|
+
<Box component="span" className="info">
|
|
63
|
+
{info}
|
|
64
|
+
</Box>
|
|
65
|
+
)}
|
|
66
|
+
|
|
67
|
+
{hasChild && (
|
|
68
|
+
<Iconify
|
|
69
|
+
width={16}
|
|
70
|
+
className="arrow"
|
|
71
|
+
icon={
|
|
72
|
+
subItem
|
|
73
|
+
? "eva:arrow-ios-forward-fill"
|
|
74
|
+
: "eva:arrow-ios-downward-fill"
|
|
75
|
+
}
|
|
76
|
+
/>
|
|
77
|
+
)}
|
|
78
|
+
</StyledNavItem>
|
|
79
|
+
);
|
|
80
|
+
|
|
81
|
+
if (roles && !roles.includes(`${currentRole}`)) {
|
|
82
|
+
return null;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
if (externalLink)
|
|
86
|
+
return (
|
|
87
|
+
<Link
|
|
88
|
+
href={path}
|
|
89
|
+
target="_blank"
|
|
90
|
+
rel="noopener"
|
|
91
|
+
color="inherit"
|
|
92
|
+
underline="none"
|
|
93
|
+
sx={{
|
|
94
|
+
...(disabled && {
|
|
95
|
+
cursor: "default",
|
|
96
|
+
}),
|
|
97
|
+
}}
|
|
98
|
+
>
|
|
99
|
+
{renderContent}
|
|
100
|
+
</Link>
|
|
101
|
+
);
|
|
102
|
+
|
|
103
|
+
return (
|
|
104
|
+
<Link
|
|
105
|
+
component={RouterLink}
|
|
106
|
+
href={path}
|
|
107
|
+
color="inherit"
|
|
108
|
+
underline="none"
|
|
109
|
+
sx={{
|
|
110
|
+
...(disabled && {
|
|
111
|
+
cursor: "default",
|
|
112
|
+
}),
|
|
113
|
+
}}
|
|
114
|
+
>
|
|
115
|
+
{renderContent}
|
|
116
|
+
</Link>
|
|
117
|
+
);
|
|
118
|
+
}
|
|
119
|
+
);
|
|
120
|
+
|
|
121
|
+
export default NavItem;
|
|
122
|
+
|
|
123
|
+
const StyledNavItem = styled(ListItemButton, {
|
|
124
|
+
shouldForwardProp: (prop) => prop !== "active",
|
|
125
|
+
})(({ active, open, depth, theme }) => {
|
|
126
|
+
const subItem = depth !== 1;
|
|
127
|
+
|
|
128
|
+
const opened = open && !active;
|
|
129
|
+
|
|
130
|
+
const baseStyles = {
|
|
131
|
+
item: {
|
|
132
|
+
...theme.typography.body2,
|
|
133
|
+
borderRadius: 6,
|
|
134
|
+
color: theme.palette.text.secondary,
|
|
135
|
+
fontWeight: theme.typography.fontWeightMedium,
|
|
136
|
+
},
|
|
137
|
+
icon: {
|
|
138
|
+
width: 22,
|
|
139
|
+
height: 22,
|
|
140
|
+
flexShrink: 0,
|
|
141
|
+
marginRight: theme.spacing(1),
|
|
142
|
+
},
|
|
143
|
+
label: {
|
|
144
|
+
textTransform: "capitalize",
|
|
145
|
+
},
|
|
146
|
+
caption: {
|
|
147
|
+
marginLeft: theme.spacing(0.75),
|
|
148
|
+
color: theme.palette.text.disabled,
|
|
149
|
+
},
|
|
150
|
+
info: {
|
|
151
|
+
display: "inline-flex",
|
|
152
|
+
marginLeft: theme.spacing(0.75),
|
|
153
|
+
},
|
|
154
|
+
arrow: {
|
|
155
|
+
marginLeft: theme.spacing(0.75),
|
|
156
|
+
},
|
|
157
|
+
};
|
|
158
|
+
|
|
159
|
+
return {
|
|
160
|
+
...(!subItem && {
|
|
161
|
+
...baseStyles.item,
|
|
162
|
+
minHeight: 32,
|
|
163
|
+
flexShrink: 0,
|
|
164
|
+
padding: theme.spacing(0, 0.75),
|
|
165
|
+
"& .icon": {
|
|
166
|
+
...baseStyles.icon,
|
|
167
|
+
},
|
|
168
|
+
"& .label": {
|
|
169
|
+
...baseStyles.label,
|
|
170
|
+
whiteSpace: "nowrap",
|
|
171
|
+
},
|
|
172
|
+
"& .caption": {
|
|
173
|
+
...baseStyles.caption,
|
|
174
|
+
},
|
|
175
|
+
"& .info": {
|
|
176
|
+
...baseStyles.info,
|
|
177
|
+
},
|
|
178
|
+
"& .arrow": {
|
|
179
|
+
...baseStyles.arrow,
|
|
180
|
+
},
|
|
181
|
+
...(active && {
|
|
182
|
+
color: theme.palette.text.primary,
|
|
183
|
+
backgroundColor: theme.palette.action.selected,
|
|
184
|
+
fontWeight: theme.typography.fontWeightSemiBold,
|
|
185
|
+
}),
|
|
186
|
+
...(opened && {
|
|
187
|
+
color: theme.palette.text.primary,
|
|
188
|
+
backgroundColor: theme.palette.action.hover,
|
|
189
|
+
}),
|
|
190
|
+
}),
|
|
191
|
+
|
|
192
|
+
...(subItem && {
|
|
193
|
+
...baseStyles.item,
|
|
194
|
+
minHeight: 34,
|
|
195
|
+
padding: theme.spacing(0, 1),
|
|
196
|
+
"& .icon": {
|
|
197
|
+
...baseStyles.icon,
|
|
198
|
+
},
|
|
199
|
+
"& .label": {
|
|
200
|
+
...baseStyles.label,
|
|
201
|
+
flexGrow: 1,
|
|
202
|
+
},
|
|
203
|
+
"& .caption": {
|
|
204
|
+
...baseStyles.caption,
|
|
205
|
+
},
|
|
206
|
+
"& .info": {
|
|
207
|
+
...baseStyles.info,
|
|
208
|
+
},
|
|
209
|
+
"& .arrow": {
|
|
210
|
+
...baseStyles.arrow,
|
|
211
|
+
marginRight: theme.spacing(-0.5),
|
|
212
|
+
},
|
|
213
|
+
...(active && {
|
|
214
|
+
color: theme.palette.text.primary,
|
|
215
|
+
backgroundColor: theme.palette.action.selected,
|
|
216
|
+
fontWeight: theme.typography.fontWeightSemiBold,
|
|
217
|
+
}),
|
|
218
|
+
...(opened && {
|
|
219
|
+
color: theme.palette.text.primary,
|
|
220
|
+
backgroundColor: theme.palette.action.hover,
|
|
221
|
+
}),
|
|
222
|
+
}),
|
|
223
|
+
};
|
|
224
|
+
});
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
import NavItem from "./nav-item";
|
|
2
|
+
import Popover from "@mui/material/Popover";
|
|
3
|
+
import React from "react";
|
|
4
|
+
import Stack from "@mui/material/Stack";
|
|
5
|
+
import { useActiveLink } from "../../../routes/hooks";
|
|
6
|
+
import { usePathname } from "../../../routes/hooks";
|
|
7
|
+
|
|
8
|
+
import { useCallback, useEffect, useRef, useState } from "react";
|
|
9
|
+
|
|
10
|
+
export default function NavList({ data, depth, slotProps }) {
|
|
11
|
+
const navRef = useRef(null);
|
|
12
|
+
|
|
13
|
+
const pathname = usePathname();
|
|
14
|
+
|
|
15
|
+
const active = useActiveLink(data.path, !!data.children);
|
|
16
|
+
|
|
17
|
+
const [openMenu, setOpenMenu] = useState(false);
|
|
18
|
+
|
|
19
|
+
useEffect(() => {
|
|
20
|
+
if (openMenu) {
|
|
21
|
+
handleCloseMenu();
|
|
22
|
+
}
|
|
23
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
24
|
+
}, [pathname]);
|
|
25
|
+
|
|
26
|
+
const handleOpenMenu = useCallback(() => {
|
|
27
|
+
if (data.children) {
|
|
28
|
+
setOpenMenu(true);
|
|
29
|
+
}
|
|
30
|
+
}, [data.children]);
|
|
31
|
+
|
|
32
|
+
const handleCloseMenu = useCallback(() => {
|
|
33
|
+
setOpenMenu(false);
|
|
34
|
+
}, []);
|
|
35
|
+
return (
|
|
36
|
+
<>
|
|
37
|
+
<NavItem
|
|
38
|
+
ref={navRef}
|
|
39
|
+
open={openMenu}
|
|
40
|
+
onMouseEnter={handleOpenMenu}
|
|
41
|
+
onMouseLeave={handleCloseMenu}
|
|
42
|
+
title={data.title}
|
|
43
|
+
path={data.path}
|
|
44
|
+
icon={data.icon}
|
|
45
|
+
info={data.info}
|
|
46
|
+
roles={data.roles}
|
|
47
|
+
caption={data.caption}
|
|
48
|
+
disabled={data.disabled}
|
|
49
|
+
depth={depth}
|
|
50
|
+
hasChild={!!data.children}
|
|
51
|
+
externalLink={data.path?.includes("http")}
|
|
52
|
+
currentRole={slotProps?.currentRole}
|
|
53
|
+
active={active}
|
|
54
|
+
className={active ? "active" : ""}
|
|
55
|
+
sx={depth === 1 ? slotProps?.rootItem : slotProps?.subItem}
|
|
56
|
+
/>
|
|
57
|
+
|
|
58
|
+
{!!data.children && (
|
|
59
|
+
<Popover
|
|
60
|
+
disableScrollLock
|
|
61
|
+
open={openMenu}
|
|
62
|
+
anchorEl={navRef.current}
|
|
63
|
+
anchorOrigin={
|
|
64
|
+
depth === 1
|
|
65
|
+
? { vertical: "bottom", horizontal: "left" }
|
|
66
|
+
: { vertical: "center", horizontal: "right" }
|
|
67
|
+
}
|
|
68
|
+
transformOrigin={
|
|
69
|
+
depth === 1
|
|
70
|
+
? { vertical: "top", horizontal: "left" }
|
|
71
|
+
: { vertical: "center", horizontal: "left" }
|
|
72
|
+
}
|
|
73
|
+
slotProps={{
|
|
74
|
+
paper: {
|
|
75
|
+
onMouseEnter: handleOpenMenu,
|
|
76
|
+
onMouseLeave: handleCloseMenu,
|
|
77
|
+
sx: {
|
|
78
|
+
minWidth: 160,
|
|
79
|
+
...(openMenu && {
|
|
80
|
+
pointerEvents: "auto",
|
|
81
|
+
}),
|
|
82
|
+
},
|
|
83
|
+
},
|
|
84
|
+
}}
|
|
85
|
+
sx={{
|
|
86
|
+
pointerEvents: "none",
|
|
87
|
+
}}
|
|
88
|
+
>
|
|
89
|
+
<NavSubList
|
|
90
|
+
data={data.children}
|
|
91
|
+
depth={depth}
|
|
92
|
+
slotProps={slotProps}
|
|
93
|
+
/>
|
|
94
|
+
</Popover>
|
|
95
|
+
)}
|
|
96
|
+
</>
|
|
97
|
+
);
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
function NavSubList({ data, depth, slotProps }) {
|
|
101
|
+
return (
|
|
102
|
+
<Stack spacing={0.5}>
|
|
103
|
+
{data.map((list) => (
|
|
104
|
+
<NavList
|
|
105
|
+
key={list.title}
|
|
106
|
+
data={list}
|
|
107
|
+
depth={depth + 1}
|
|
108
|
+
slotProps={slotProps}
|
|
109
|
+
/>
|
|
110
|
+
))}
|
|
111
|
+
</Stack>
|
|
112
|
+
);
|
|
113
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import NavList from "./nav-list";
|
|
2
|
+
import React from "react";
|
|
3
|
+
import Stack from "@mui/material/Stack";
|
|
4
|
+
import { memo } from "react";
|
|
5
|
+
|
|
6
|
+
function NavSectionHorizontal({ data, slotProps, sx, ...other }) {
|
|
7
|
+
return (
|
|
8
|
+
<Stack
|
|
9
|
+
component="nav"
|
|
10
|
+
id="nav-section-horizontal"
|
|
11
|
+
direction="row"
|
|
12
|
+
alignItems="center"
|
|
13
|
+
spacing={`${slotProps?.gap || 6}px`}
|
|
14
|
+
sx={{
|
|
15
|
+
mx: "auto",
|
|
16
|
+
...sx,
|
|
17
|
+
}}
|
|
18
|
+
{...other}
|
|
19
|
+
>
|
|
20
|
+
{data.map((group, index) => (
|
|
21
|
+
<Group
|
|
22
|
+
key={group?.subheader || index}
|
|
23
|
+
items={group?.items}
|
|
24
|
+
slotProps={slotProps}
|
|
25
|
+
/>
|
|
26
|
+
))}
|
|
27
|
+
</Stack>
|
|
28
|
+
);
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
export default memo(NavSectionHorizontal);
|
|
32
|
+
|
|
33
|
+
function Group({ items, slotProps }) {
|
|
34
|
+
return (
|
|
35
|
+
<>
|
|
36
|
+
{items.map((list) => (
|
|
37
|
+
<NavList key={list.title} data={list} depth={1} slotProps={slotProps} />
|
|
38
|
+
))}
|
|
39
|
+
</>
|
|
40
|
+
);
|
|
41
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from "./nav-section-mini";
|
|
@@ -0,0 +1,242 @@
|
|
|
1
|
+
import Box from "@mui/material/Box";
|
|
2
|
+
import Iconify from "../../Iconify";
|
|
3
|
+
import Link from "@mui/material/Link";
|
|
4
|
+
import ListItemButton from "@mui/material/ListItemButton";
|
|
5
|
+
import React from "react";
|
|
6
|
+
import { RouterLink } from "../../../routes/components";
|
|
7
|
+
import Tooltip from "@mui/material/Tooltip";
|
|
8
|
+
import { forwardRef } from "react";
|
|
9
|
+
|
|
10
|
+
import { alpha, styled } from "@mui/material/styles";
|
|
11
|
+
|
|
12
|
+
const NavItem = forwardRef(
|
|
13
|
+
(
|
|
14
|
+
{
|
|
15
|
+
title,
|
|
16
|
+
path,
|
|
17
|
+
icon,
|
|
18
|
+
info,
|
|
19
|
+
disabled,
|
|
20
|
+
caption,
|
|
21
|
+
roles,
|
|
22
|
+
//
|
|
23
|
+
open,
|
|
24
|
+
depth,
|
|
25
|
+
active,
|
|
26
|
+
hasChild,
|
|
27
|
+
externalLink,
|
|
28
|
+
currentRole = "admin",
|
|
29
|
+
...other
|
|
30
|
+
},
|
|
31
|
+
ref
|
|
32
|
+
) => {
|
|
33
|
+
const subItem = depth !== 1;
|
|
34
|
+
const renderContent = (
|
|
35
|
+
<StyledNavItem
|
|
36
|
+
disableGutters
|
|
37
|
+
ref={ref}
|
|
38
|
+
open={open}
|
|
39
|
+
depth={depth}
|
|
40
|
+
active={active}
|
|
41
|
+
disabled={disabled}
|
|
42
|
+
{...other}
|
|
43
|
+
>
|
|
44
|
+
{icon && (
|
|
45
|
+
<Box component="span" className="icon">
|
|
46
|
+
<Iconify width={16} icon={icon} />
|
|
47
|
+
</Box>
|
|
48
|
+
)}
|
|
49
|
+
|
|
50
|
+
{title && (
|
|
51
|
+
<Box component="span" className="label">
|
|
52
|
+
{title}
|
|
53
|
+
</Box>
|
|
54
|
+
)}
|
|
55
|
+
|
|
56
|
+
{caption && (
|
|
57
|
+
<Tooltip title={caption} arrow placement="right">
|
|
58
|
+
<Iconify width={16} icon="eva:info-outline" className="caption" />
|
|
59
|
+
</Tooltip>
|
|
60
|
+
)}
|
|
61
|
+
|
|
62
|
+
{info && subItem && (
|
|
63
|
+
<Box component="span" className="info">
|
|
64
|
+
{info}
|
|
65
|
+
</Box>
|
|
66
|
+
)}
|
|
67
|
+
|
|
68
|
+
{hasChild && (
|
|
69
|
+
<Iconify
|
|
70
|
+
width={16}
|
|
71
|
+
className="arrow"
|
|
72
|
+
icon="eva:arrow-ios-forward-fill"
|
|
73
|
+
/>
|
|
74
|
+
)}
|
|
75
|
+
</StyledNavItem>
|
|
76
|
+
);
|
|
77
|
+
|
|
78
|
+
if (roles && !roles.includes(`${currentRole}`)) {
|
|
79
|
+
return null;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
if (externalLink)
|
|
83
|
+
return (
|
|
84
|
+
<Link
|
|
85
|
+
href={path}
|
|
86
|
+
target="_blank"
|
|
87
|
+
rel="noopener"
|
|
88
|
+
color="inherit"
|
|
89
|
+
underline="none"
|
|
90
|
+
sx={{
|
|
91
|
+
width: 1,
|
|
92
|
+
...(disabled && {
|
|
93
|
+
cursor: "default",
|
|
94
|
+
}),
|
|
95
|
+
}}
|
|
96
|
+
>
|
|
97
|
+
{renderContent}
|
|
98
|
+
</Link>
|
|
99
|
+
);
|
|
100
|
+
|
|
101
|
+
return (
|
|
102
|
+
<Link
|
|
103
|
+
component={RouterLink}
|
|
104
|
+
href={path}
|
|
105
|
+
color="inherit"
|
|
106
|
+
underline="none"
|
|
107
|
+
sx={{
|
|
108
|
+
width: 1,
|
|
109
|
+
...(disabled && {
|
|
110
|
+
cursor: "default",
|
|
111
|
+
}),
|
|
112
|
+
}}
|
|
113
|
+
>
|
|
114
|
+
{renderContent}
|
|
115
|
+
</Link>
|
|
116
|
+
);
|
|
117
|
+
}
|
|
118
|
+
);
|
|
119
|
+
|
|
120
|
+
export default NavItem;
|
|
121
|
+
|
|
122
|
+
const StyledNavItem = styled(ListItemButton, {
|
|
123
|
+
shouldForwardProp: (prop) => prop !== "active",
|
|
124
|
+
})(({ active, open, depth, theme }) => {
|
|
125
|
+
const subItem = depth !== 1;
|
|
126
|
+
|
|
127
|
+
const opened = open && !active;
|
|
128
|
+
|
|
129
|
+
const lightMode = theme.palette.mode === "light";
|
|
130
|
+
|
|
131
|
+
const noWrapStyles = {
|
|
132
|
+
width: "100%",
|
|
133
|
+
maxWidth: "100%",
|
|
134
|
+
display: "block",
|
|
135
|
+
overflow: "hidden",
|
|
136
|
+
whiteSpace: "nowrap",
|
|
137
|
+
textOverflow: "ellipsis",
|
|
138
|
+
};
|
|
139
|
+
|
|
140
|
+
const baseStyles = {
|
|
141
|
+
item: {
|
|
142
|
+
borderRadius: 6,
|
|
143
|
+
color: theme.palette.text.secondary,
|
|
144
|
+
},
|
|
145
|
+
icon: {
|
|
146
|
+
width: 22,
|
|
147
|
+
height: 22,
|
|
148
|
+
flexShrink: 0,
|
|
149
|
+
},
|
|
150
|
+
label: {
|
|
151
|
+
textTransform: "capitalize",
|
|
152
|
+
},
|
|
153
|
+
caption: {
|
|
154
|
+
color: theme.palette.text.disabled,
|
|
155
|
+
},
|
|
156
|
+
};
|
|
157
|
+
|
|
158
|
+
return {
|
|
159
|
+
...(!subItem && {
|
|
160
|
+
...baseStyles.item,
|
|
161
|
+
fontSize: 10,
|
|
162
|
+
minHeight: 56,
|
|
163
|
+
lineHeight: "16px",
|
|
164
|
+
textAlign: "center",
|
|
165
|
+
flexDirection: "column",
|
|
166
|
+
justifyContent: "center",
|
|
167
|
+
padding: theme.spacing(0.5),
|
|
168
|
+
margin: theme.spacing(0, 0.5),
|
|
169
|
+
fontWeight: theme.typography.fontWeightSemiBold,
|
|
170
|
+
"& .icon": {
|
|
171
|
+
...baseStyles.icon,
|
|
172
|
+
},
|
|
173
|
+
"& .label": {
|
|
174
|
+
...noWrapStyles,
|
|
175
|
+
...baseStyles.label,
|
|
176
|
+
marginTop: theme.spacing(0.5),
|
|
177
|
+
},
|
|
178
|
+
"& .caption": {
|
|
179
|
+
...baseStyles.caption,
|
|
180
|
+
top: 11,
|
|
181
|
+
left: 6,
|
|
182
|
+
position: "absolute",
|
|
183
|
+
},
|
|
184
|
+
"& .arrow": {
|
|
185
|
+
top: 11,
|
|
186
|
+
right: 6,
|
|
187
|
+
position: "absolute",
|
|
188
|
+
},
|
|
189
|
+
...(active && {
|
|
190
|
+
fontWeight: theme.typography.fontWeightBold,
|
|
191
|
+
backgroundColor: alpha(theme.palette.primary.main, 0.08),
|
|
192
|
+
color: lightMode
|
|
193
|
+
? theme.palette.primary.main
|
|
194
|
+
: theme.palette.primary.light,
|
|
195
|
+
"&:hover": {
|
|
196
|
+
backgroundColor: alpha(theme.palette.primary.main, 0.16),
|
|
197
|
+
},
|
|
198
|
+
}),
|
|
199
|
+
...(opened && {
|
|
200
|
+
color: theme.palette.text.primary,
|
|
201
|
+
backgroundColor: theme.palette.action.hover,
|
|
202
|
+
}),
|
|
203
|
+
}),
|
|
204
|
+
|
|
205
|
+
...(subItem && {
|
|
206
|
+
...baseStyles.item,
|
|
207
|
+
...theme.typography.body2,
|
|
208
|
+
minHeight: 34,
|
|
209
|
+
padding: theme.spacing(0, 1),
|
|
210
|
+
fontWeight: theme.typography.fontWeightMedium,
|
|
211
|
+
"& .icon": {
|
|
212
|
+
...baseStyles.icon,
|
|
213
|
+
marginRight: theme.spacing(1),
|
|
214
|
+
},
|
|
215
|
+
"& .label": {
|
|
216
|
+
...baseStyles.label,
|
|
217
|
+
flexGrow: 1,
|
|
218
|
+
},
|
|
219
|
+
"& .caption": {
|
|
220
|
+
...baseStyles.caption,
|
|
221
|
+
marginLeft: theme.spacing(0.75),
|
|
222
|
+
},
|
|
223
|
+
"& .info": {
|
|
224
|
+
display: "inline-flex",
|
|
225
|
+
marginLeft: theme.spacing(0.75),
|
|
226
|
+
},
|
|
227
|
+
"& .arrow": {
|
|
228
|
+
marginLeft: theme.spacing(0.75),
|
|
229
|
+
marginRight: theme.spacing(-0.5),
|
|
230
|
+
},
|
|
231
|
+
...(active && {
|
|
232
|
+
color: theme.palette.text.primary,
|
|
233
|
+
backgroundColor: theme.palette.action.selected,
|
|
234
|
+
fontWeight: theme.typography.fontWeightSemiBold,
|
|
235
|
+
}),
|
|
236
|
+
...(opened && {
|
|
237
|
+
color: theme.palette.text.primary,
|
|
238
|
+
backgroundColor: theme.palette.action.hover,
|
|
239
|
+
}),
|
|
240
|
+
}),
|
|
241
|
+
};
|
|
242
|
+
});
|