From b7cd25b6147d21c471a79755b56d2e50f065ef18 Mon Sep 17 00:00:00 2001 From: louiscklaw Date: Sun, 15 Jun 2025 11:28:24 +0800 Subject: [PATCH] build ok, --- 03_source/cms_backend/package.json | 4 +- 03_source/cms_backend/scripts/10_build.sh | 11 ++- 03_source/cms_backend/src/_mock/_chat.ts | 6 +- 03_source/cms_backend/src/_mock/_kanban.ts | 19 ++--- 03_source/cms_backend/src/_mock/_mail.ts | 15 +--- 03_source/cms_backend/src/_mock/_mock.ts | 9 +-- 03_source/cms_backend/src/_mock/_product.ts | 23 ++---- 03_source/cms_backend/src/_mock/assets.ts | 33 +++------ .../src/app/api/AccessLog/detail/route.ts | 2 +- .../src/app/api/AccessLog/route.ts | 2 +- .../cms_backend/src/app/api/AppLog/route.ts | 2 +- .../cms_backend/src/app/api/auth/me/route.ts | 2 +- .../src/app/api/auth/sign-in/route.ts | 2 +- .../src/app/api/event/details/route.ts | 2 +- .../src/app/api/helloworld/detail/route.ts | 2 +- .../src/app/api/invoice/search/route.ts | 4 +- .../cms_backend/src/app/api/kanban/route.ts | 17 ++--- .../src/app/api/mail/list/route.ts | 5 +- .../src/app/api/order/search/route.ts | 4 +- .../src/app/api/pagination/route.ts | 8 +-- .../src/app/api/post/search/route.ts | 5 +- .../src/app/api/product/create/route.ts | 7 +- .../src/app/api/product/create/test.http | 4 +- .../src/app/api/product/details/route.ts | 2 +- .../src/app/api/product/list/route.ts | 2 +- .../src/app/api/user/changeToAdmin/route.ts | 2 +- .../src/app/api/user/changeToUser/route.ts | 2 +- .../src/app/api/user/checkAdmin/route.ts | 2 +- .../src/app/api/user/helloworld/route.ts | 2 +- .../src/app/api/user/list/route.ts | 2 +- .../cms_backend/src/app/api/user/route.ts | 2 +- .../src/app/api/user/search/route.ts | 4 +- ...ssLog.service.ts => access-log.service.ts} | 0 .../{AppLog.service.ts => app-log.service.ts} | 0 .../src/app/services/product.service.ts | 28 +------- ...erItem.service.ts => user-item.service.ts} | 0 03_source/cms_backend/src/global-config.ts | 3 +- 03_source/cms_backend/src/utils/hash.ts | 3 +- 03_source/cms_backend/src/utils/logger.ts | 6 +- 03_source/cms_backend/src/utils/set-date.ts | 26 ++----- 03_source/frontend/package.json | 6 +- 03_source/frontend/scripts/10_build.sh | 10 +++ 03_source/frontend/src/_mock/_calendar.ts | 2 +- 03_source/frontend/src/_mock/_files.ts | 2 +- 03_source/frontend/src/_mock/_invoice.ts | 5 +- 03_source/frontend/src/_mock/_mock.ts | 52 +++++++------- 03_source/frontend/src/_mock/_overview.ts | 4 +- 03_source/frontend/src/actions/product.ts | 1 - .../src/assets/icons/plan-starter-icon.tsx | 4 +- .../server-error-illustration.tsx | 6 +- .../src/auth/components/form-divider.tsx | 3 +- .../src/auth/components/form-head.tsx | 1 - .../src/auth/components/form-resend-code.tsx | 1 - .../src/auth/components/form-return-link.tsx | 5 +- .../src/auth/components/form-socials.tsx | 2 - .../src/auth/components/sign-up-terms.tsx | 1 - .../src/auth/context/amplify/action.tsx | 23 +++--- .../auth/context/amplify/auth-provider.tsx | 11 ++- .../src/auth/context/auth-context.tsx | 1 - .../src/auth/context/auth0/auth-provider.tsx | 9 +-- .../src/auth/context/firebase/action.ts | 13 ++-- .../auth/context/firebase/auth-provider.tsx | 9 +-- .../frontend/src/auth/context/jwt/action.ts | 3 +- .../src/auth/context/jwt/auth-provider.tsx | 11 ++- .../frontend/src/auth/context/jwt/utils.ts | 4 +- .../src/auth/context/supabase/action.tsx | 6 +- .../auth/context/supabase/auth-provider.tsx | 7 +- .../frontend/src/auth/guard/auth-guard.tsx | 12 ++-- .../frontend/src/auth/guard/guest-guard.tsx | 10 +-- .../src/auth/guard/role-based-guard.tsx | 10 +-- .../src/auth/hooks/use-auth-context.ts | 1 - .../amplify/amplify-reset-password-view.tsx | 17 ++--- .../view/amplify/amplify-sign-in-view.tsx | 28 ++++---- .../view/amplify/amplify-sign-up-view.tsx | 28 ++++---- .../amplify/amplify-update-password-view.tsx | 21 +++--- .../auth/view/amplify/amplify-verify-view.tsx | 21 +++--- .../centered/centered-reset-password-view.tsx | 13 ++-- .../centered/centered-sign-in-view.tsx | 22 +++--- .../centered/centered-sign-up-view.tsx | 22 +++--- .../centered-update-password-view.tsx | 15 ++-- .../centered/centered-verify-view.tsx | 13 ++-- .../split/split-reset-password-view.tsx | 13 ++-- .../auth-demo/split/split-sign-in-view.tsx | 20 +++--- .../auth-demo/split/split-sign-up-view.tsx | 20 +++--- .../split/split-update-password-view.tsx | 15 ++-- .../auth-demo/split/split-verify-view.tsx | 15 ++-- .../auth/view/auth0/auth0-sign-in-view.tsx | 7 +- .../firebase/firebase-reset-password-view.tsx | 17 ++--- .../view/firebase/firebase-sign-in-view.tsx | 34 ++++----- .../view/firebase/firebase-sign-up-view.tsx | 30 ++++---- .../view/firebase/firebase-verify-view.tsx | 4 +- .../src/auth/view/jwt/jwt-sign-in-view.tsx | 28 ++++---- .../src/auth/view/jwt/jwt-sign-up-view.tsx | 28 ++++---- .../supabase/supabase-reset-password-view.tsx | 17 ++--- .../view/supabase/supabase-sign-in-view.tsx | 28 ++++---- .../view/supabase/supabase-sign-up-view.tsx | 28 ++++---- .../supabase-update-password-view.tsx | 23 +++--- .../view/supabase/supabase-verify-view.tsx | 4 +- .../src/components/animate/animate-border.tsx | 17 ++--- .../components/animate/animate-count-up.tsx | 8 +-- .../src/components/animate/animate-logo.tsx | 8 +-- .../src/components/animate/animate-text.tsx | 18 ++--- .../components/animate/back-to-top-button.tsx | 7 +- .../components/animate/motion-container.tsx | 7 +- .../components/animate/motion-viewport.tsx | 7 +- .../scroll-progress/scroll-progress.tsx | 13 ++-- .../scroll-progress/use-scroll-progress.ts | 3 +- .../components/animate/variants/background.ts | 2 +- .../src/components/animate/variants/bounce.ts | 5 +- .../components/animate/variants/container.ts | 2 +- .../src/components/animate/variants/fade.ts | 5 +- .../src/components/animate/variants/flip.ts | 5 +- .../src/components/animate/variants/path.ts | 2 +- .../src/components/animate/variants/rotate.ts | 5 +- .../src/components/animate/variants/scale.ts | 5 +- .../src/components/animate/variants/slide.ts | 5 +- .../src/components/animate/variants/zoom.ts | 5 +- .../src/components/carousel/carousel.tsx | 9 +-- .../carousel/components/arrow-button.tsx | 11 ++- .../components/carousel-arrow-buttons.tsx | 8 +-- .../components/carousel-dot-buttons.tsx | 10 +-- .../components/carousel-progress-bar.tsx | 5 +- .../carousel/components/carousel-slide.tsx | 7 +- .../carousel/components/carousel-thumb.tsx | 7 +- .../carousel/components/carousel-thumbs.tsx | 9 +-- .../carousel/hooks/use-carousel-arrows.ts | 4 +- .../carousel/hooks/use-carousel-auto-play.ts | 4 +- .../hooks/use-carousel-auto-scroll.ts | 4 +- .../carousel/hooks/use-carousel-dots.ts | 4 +- .../carousel/hooks/use-carousel-parallax.ts | 7 +- .../carousel/hooks/use-carousel-progress.ts | 4 +- .../components/carousel/hooks/use-carousel.ts | 20 +++--- .../components/carousel/hooks/use-thumbs.ts | 4 +- .../frontend/src/components/carousel/types.ts | 4 +- .../frontend/src/components/carousel/utils.ts | 1 - .../frontend/src/components/chart/chart.tsx | 7 +- .../chart/components/chart-legends.tsx | 4 +- .../chart/components/chart-loading.tsx | 6 +- .../chart/components/chart-select.tsx | 14 ++-- .../frontend/src/components/chart/types.ts | 2 +- .../src/components/chart/use-chart.ts | 5 +- .../components/color-utils/color-picker.tsx | 11 ++- .../components/color-utils/color-preview.tsx | 4 +- .../country-select/country-select.tsx | 16 ++--- .../custom-breadcrumbs/back-link.tsx | 3 - .../custom-breadcrumbs/breadcrumb-link.tsx | 4 +- .../custom-breadcrumbs/custom-breadcrumbs.tsx | 17 ++--- .../custom-date-range-picker.tsx | 15 ++-- .../use-date-range-picker.ts | 6 +- .../custom-popover/custom-popover.tsx | 6 +- .../src/components/custom-popover/styles.tsx | 7 +- .../src/components/custom-popover/types.ts | 2 +- .../src/components/custom-popover/utils.ts | 3 +- .../components/custom-tabs/custom-tabs.tsx | 10 ++- .../components/code-highlight-block.tsx | 3 - .../editor/components/heading-block.tsx | 13 ++-- .../editor/components/image-block.tsx | 7 +- .../editor/components/link-block.tsx | 7 +- .../editor/components/toolbar-item.tsx | 5 +- .../frontend/src/components/editor/editor.tsx | 33 ++++----- .../frontend/src/components/editor/styles.tsx | 4 +- .../src/components/editor/toolbar.tsx | 18 ++--- .../frontend/src/components/editor/types.ts | 4 +- .../empty-content/empty-content.tsx | 9 +-- .../file-thumbnail/action-buttons.tsx | 7 +- .../src/components/file-thumbnail/types.ts | 4 +- .../src/components/file-thumbnail/utils.ts | 1 - .../filters-result/filters-block.tsx | 3 +- .../filters-result/filters-result.tsx | 6 +- .../src/components/flag-icon/flag-icon.tsx | 4 +- .../components/hook-form/form-provider.tsx | 1 - .../src/components/hook-form/help-text.tsx | 1 - .../components/hook-form/rhf-autocomplete.tsx | 8 +-- .../src/components/hook-form/rhf-checkbox.tsx | 21 +++--- .../src/components/hook-form/rhf-code.tsx | 9 +-- .../hook-form/rhf-country-select.tsx | 2 - .../components/hook-form/rhf-date-picker.tsx | 9 +-- .../src/components/hook-form/rhf-editor.tsx | 2 - .../components/hook-form/rhf-number-input.tsx | 2 - .../components/hook-form/rhf-phone-input.tsx | 2 - .../components/hook-form/rhf-radio-group.tsx | 19 +++-- .../src/components/hook-form/rhf-rating.tsx | 9 +-- .../src/components/hook-form/rhf-select.tsx | 27 ++++--- .../src/components/hook-form/rhf-slider.tsx | 9 +-- .../src/components/hook-form/rhf-switch.tsx | 23 +++--- .../components/hook-form/rhf-text-field.tsx | 6 +- .../hook-form/rhf-upload-avatar.tsx | 8 +-- .../components/hook-form/rhf-upload-box.tsx | 3 - .../src/components/hook-form/rhf-upload.tsx | 2 + .../src/components/hook-form/schema-helper.ts | 3 +- .../src/components/iconify/iconify.tsx | 8 +-- .../src/components/iconify/register-icons.ts | 2 - .../frontend/src/components/image/image.tsx | 11 ++- .../frontend/src/components/image/styles.ts | 2 - .../frontend/src/components/label/label.tsx | 4 +- .../frontend/src/components/label/styles.tsx | 5 +- .../frontend/src/components/label/types.ts | 2 +- .../src/components/lightbox/lightbox.tsx | 7 +- .../src/components/lightbox/use-light-box.ts | 3 +- .../frontend/src/components/lightbox/utils.ts | 7 +- .../loading-screen/loading-screen.tsx | 10 ++- .../loading-screen/splash-screen.tsx | 7 +- .../frontend/src/components/logo/logo.tsx | 8 +-- .../src/components/map/map-controls.tsx | 9 ++- .../src/components/map/map-marker.tsx | 2 - .../frontend/src/components/map/map-popup.tsx | 3 +- 03_source/frontend/src/components/map/map.tsx | 9 +-- .../components/markdown/html-to-markdown.ts | 4 +- .../src/components/markdown/markdown.tsx | 18 ++--- .../src/components/markdown/styles.ts | 4 +- .../frontend/src/components/markdown/types.ts | 2 +- .../mega-menu/components/nav-carousel.tsx | 13 ++-- .../mega-menu/components/nav-drawer.tsx | 3 +- .../components/nav-dropdown-content.tsx | 13 ++-- .../mega-menu/components/nav-dropdown.tsx | 4 +- .../mega-menu/components/nav-elements.tsx | 4 +- .../mega-menu/components/nav-item.tsx | 11 ++- .../horizontal/mega-menu-horizontal.tsx | 9 +-- .../mega-menu/horizontal/nav-list.tsx | 7 +- .../mega-menu/mobile/mega-menu-mobile.tsx | 18 ++--- .../components/mega-menu/mobile/nav-list.tsx | 12 ++-- .../components/mega-menu/styles/css-vars.ts | 1 - .../mega-menu/styles/nav-item-styles.ts | 2 +- .../src/components/mega-menu/types.ts | 5 +- .../mega-menu/utils/create-nav-item.ts | 2 - .../mega-menu/vertical/mega-menu-vertical.tsx | 11 ++- .../mega-menu/vertical/nav-list.tsx | 7 +- .../nav-basic/components/nav-collapse.tsx | 6 +- .../nav-basic/components/nav-dropdown.tsx | 5 +- .../nav-basic/components/nav-elements.tsx | 4 +- .../nav-basic/desktop/nav-basic-desktop.tsx | 6 +- .../components/nav-basic/desktop/nav-item.tsx | 14 ++-- .../components/nav-basic/desktop/nav-list.tsx | 14 ++-- .../nav-basic/mobile/nav-basic-mobile.tsx | 6 +- .../components/nav-basic/mobile/nav-item.tsx | 16 ++--- .../components/nav-basic/mobile/nav-list.tsx | 9 +-- .../components/nav-basic/styles/css-vars.ts | 1 - .../nav-basic/styles/nav-item-styles.ts | 2 +- .../src/components/nav-basic/types.ts | 2 +- .../nav-basic/utils/create-nav-item.ts | 2 - .../nav-section/components/nav-collapse.tsx | 6 +- .../nav-section/components/nav-dropdown.tsx | 5 +- .../nav-section/components/nav-elements.tsx | 4 +- .../nav-section/horizontal/nav-item.tsx | 14 ++-- .../nav-section/horizontal/nav-list.tsx | 14 ++-- .../horizontal/nav-section-horizontal.tsx | 23 +++--- .../components/nav-section/mini/nav-item.tsx | 14 ++-- .../components/nav-section/mini/nav-list.tsx | 12 ++-- .../nav-section/mini/nav-section-mini.tsx | 24 ++++--- .../components/nav-section/styles/css-vars.ts | 1 - .../nav-section/styles/nav-item-styles.ts | 2 +- .../src/components/nav-section/types.ts | 2 +- .../nav-section/utils/create-nav-item.ts | 2 - .../vertical/nav-section-vertical.tsx | 3 +- .../components/number-input/number-input.tsx | 11 ++- .../src/components/number-input/styles.ts | 2 +- .../organizational-chart.tsx | 6 +- .../components/phone-input/list-popover.tsx | 22 +++--- .../components/phone-input/phone-input.tsx | 17 ++--- .../src/components/phone-input/types.ts | 4 +- .../components/progress-bar/progress-bar.tsx | 4 +- .../src/components/scrollbar/scrollbar.tsx | 7 +- .../src/components/scrollbar/types.ts | 2 +- .../search-not-found/search-not-found.tsx | 5 +- .../settings/context/settings-context.ts | 1 - .../settings/context/settings-provider.tsx | 8 +-- .../settings/context/use-settings-context.ts | 1 - .../settings/drawer/base-option.tsx | 9 +-- .../settings/drawer/font-options.tsx | 10 +-- .../settings/drawer/fullscreen-button.tsx | 6 +- .../settings/drawer/nav-layout-option.tsx | 8 +-- .../settings/drawer/presets-options.tsx | 5 +- .../settings/drawer/settings-drawer.tsx | 31 ++++---- .../src/components/settings/drawer/styles.tsx | 9 +-- .../components/settings/settings-config.ts | 1 - .../frontend/src/components/settings/types.ts | 4 +- .../src/components/snackbar/snackbar.tsx | 3 +- .../src/components/snackbar/styles.tsx | 7 +- .../src/components/svg-color/svg-color.tsx | 5 +- .../src/components/svg-color/types.ts | 2 +- .../src/components/table/table-empty-rows.tsx | 5 +- .../components/table/table-head-custom.tsx | 7 +- .../src/components/table/table-no-data.tsx | 6 +- .../table/table-pagination-custom.tsx | 9 ++- .../table/table-selected-action.tsx | 1 - .../src/components/table/table-skeleton.tsx | 5 +- .../src/components/table/use-table.ts | 2 +- .../upload/components/placeholder.tsx | 9 +-- .../upload/components/preview-multi-file.tsx | 10 +-- .../upload/components/preview-single-file.tsx | 8 +-- .../upload/components/rejection-files.tsx | 10 +-- .../frontend/src/components/upload/types.ts | 3 +- .../src/components/upload/upload-avatar.tsx | 28 +++++--- .../src/components/upload/upload-box.tsx | 7 +- .../frontend/src/components/upload/upload.tsx | 9 +-- 03_source/frontend/src/global-config.ts | 1 - .../src/layouts/auth-centered/content.tsx | 5 +- .../src/layouts/auth-centered/layout.tsx | 31 ++++---- .../src/layouts/auth-split/content.tsx | 7 +- .../src/layouts/auth-split/layout.tsx | 35 ++++------ .../src/layouts/auth-split/section.tsx | 10 +-- .../src/layouts/components/account-button.tsx | 9 +-- .../src/layouts/components/account-drawer.tsx | 41 +++++------ .../layouts/components/account-popover.tsx | 24 +++---- .../layouts/components/contacts-popover.tsx | 24 +++---- .../layouts/components/language-popover.tsx | 22 +++--- .../src/layouts/components/menu-button.tsx | 2 - .../layouts/components/nav-toggle-button.tsx | 5 +- .../src/layouts/components/nav-upgrade.tsx | 18 ++--- .../components/notifications-drawer/index.tsx | 29 ++++---- .../notification-item.tsx | 13 ++-- .../layouts/components/searchbar/index.tsx | 32 ++++----- .../components/searchbar/result-item.tsx | 12 ++-- .../src/layouts/components/searchbar/utils.ts | 8 ++- .../layouts/components/settings-button.tsx | 11 ++- .../src/layouts/components/sign-in-button.tsx | 5 +- .../layouts/components/sign-out-button.tsx | 22 +++--- .../layouts/components/workspaces-popover.tsx | 29 ++++---- .../src/layouts/core/header-section.tsx | 13 ++-- .../src/layouts/core/layout-section.tsx | 9 +-- .../src/layouts/core/main-section.tsx | 4 +- .../src/layouts/dashboard/content.tsx | 10 +-- .../src/layouts/dashboard/css-vars.ts | 6 +- .../frontend/src/layouts/dashboard/layout.tsx | 47 ++++++++++--- .../src/layouts/dashboard/nav-horizontal.tsx | 10 +-- .../src/layouts/dashboard/nav-mobile.tsx | 17 ++--- .../src/layouts/dashboard/nav-vertical.tsx | 56 ++++++++++----- .../frontend/src/layouts/main/footer.tsx | 20 +++--- .../frontend/src/layouts/main/layout.tsx | 38 +++++----- .../main/nav/components/nav-dropdown.tsx | 1 - .../main/nav/components/nav-elements.tsx | 4 +- .../desktop/nav-desktop-item-dashboard.tsx | 13 ++-- .../main/nav/desktop/nav-desktop-item.tsx | 6 +- .../main/nav/desktop/nav-desktop-list.tsx | 7 +- .../frontend/src/layouts/nav-config-main.tsx | 7 +- .../src/layouts/nav-config-workspace.tsx | 1 - .../frontend/src/layouts/simple/content.tsx | 7 +- .../frontend/src/layouts/simple/layout.tsx | 28 +++----- 03_source/frontend/src/lib/firebase.ts | 8 +-- 03_source/frontend/src/lib/supabase.ts | 2 - .../src/locales/utils/number-format-locale.ts | 1 - .../frontend/src/pages/about-us/index.tsx | 1 - .../auth-demo/centered/reset-password.tsx | 3 +- .../src/pages/auth-demo/centered/sign-in.tsx | 3 +- .../src/pages/auth-demo/centered/sign-up.tsx | 3 +- .../auth-demo/centered/update-password.tsx | 3 +- .../src/pages/auth-demo/centered/verify.tsx | 3 +- .../pages/auth-demo/split/reset-password.tsx | 3 +- .../src/pages/auth-demo/split/sign-in.tsx | 3 +- .../src/pages/auth-demo/split/sign-up.tsx | 3 +- .../pages/auth-demo/split/update-password.tsx | 3 +- .../src/pages/auth-demo/split/verify.tsx | 3 +- .../src/pages/auth/amplify/reset-password.tsx | 2 +- .../src/pages/auth/amplify/sign-in.tsx | 3 +- .../src/pages/auth/amplify/sign-up.tsx | 3 +- .../pages/auth/amplify/update-password.tsx | 3 +- .../src/pages/auth/amplify/verify.tsx | 3 +- .../frontend/src/pages/auth/auth0/sign-in.tsx | 3 +- .../pages/auth/firebase/reset-password.tsx | 3 +- .../src/pages/auth/firebase/sign-in.tsx | 3 +- .../src/pages/auth/firebase/sign-up.tsx | 3 +- .../src/pages/auth/firebase/verify.tsx | 3 +- .../frontend/src/pages/auth/jwt/sign-in.tsx | 3 +- .../frontend/src/pages/auth/jwt/sign-up.tsx | 3 +- .../pages/auth/supabase/reset-password.tsx | 3 +- .../src/pages/auth/supabase/sign-in.tsx | 3 +- .../src/pages/auth/supabase/sign-up.tsx | 3 +- .../pages/auth/supabase/update-password.tsx | 3 +- .../src/pages/auth/supabase/verify.tsx | 3 +- 03_source/frontend/src/pages/blank/index.tsx | 1 - .../frontend/src/pages/coming-soon/index.tsx | 1 - .../pages/components/extra/animate/index.tsx | 1 - .../pages/components/extra/carousel/index.tsx | 1 - .../pages/components/extra/chart/index.tsx | 1 - .../src/pages/components/extra/dnd/index.tsx | 1 - .../pages/components/extra/editor/index.tsx | 1 - .../extra/form-validation/index.tsx | 1 - .../components/extra/form-wizard/index.tsx | 1 - .../pages/components/extra/image/index.tsx | 1 - .../pages/components/extra/label/index.tsx | 1 - .../pages/components/extra/layout/index.tsx | 1 - .../pages/components/extra/lightbox/index.tsx | 1 - .../src/pages/components/extra/map/index.tsx | 1 - .../pages/components/extra/markdown/index.tsx | 1 - .../components/extra/mega-menu/index.tsx | 1 - .../components/extra/multi-language/index.tsx | 1 - .../components/extra/navigation-bar/index.tsx | 1 - .../extra/organization-chart/index.tsx | 1 - .../extra/scroll-progress/index.tsx | 1 - .../pages/components/extra/scroll/index.tsx | 1 - .../pages/components/extra/snackbar/index.tsx | 1 - .../pages/components/extra/upload/index.tsx | 1 - .../components/extra/utilities/index.tsx | 1 - .../components/foundation/colors/index.tsx | 1 - .../components/foundation/grid/index.tsx | 1 - .../components/foundation/icons/iconify.tsx | 1 - .../components/foundation/icons/index.tsx | 1 - .../components/foundation/shadows/index.tsx | 1 - .../foundation/typography/index.tsx | 1 - .../frontend/src/pages/components/index.tsx | 1 - .../pages/components/mui/accordion/index.tsx | 1 - .../src/pages/components/mui/alert/index.tsx | 1 - .../components/mui/autocomplete/index.tsx | 1 - .../src/pages/components/mui/avatar/index.tsx | 1 - .../src/pages/components/mui/badge/index.tsx | 1 - .../components/mui/breadcrumbs/index.tsx | 1 - .../pages/components/mui/buttons/index.tsx | 1 - .../pages/components/mui/checkbox/index.tsx | 1 - .../src/pages/components/mui/chip/index.tsx | 1 - .../pages/components/mui/data-grid/index.tsx | 1 - .../components/mui/date-pickers/index.tsx | 1 - .../src/pages/components/mui/dialog/index.tsx | 1 - .../src/pages/components/mui/drawer/index.tsx | 1 - .../src/pages/components/mui/list/index.tsx | 1 - .../src/pages/components/mui/menu/index.tsx | 1 - .../pages/components/mui/pagination/index.tsx | 1 - .../pages/components/mui/popover/index.tsx | 1 - .../pages/components/mui/progress/index.tsx | 1 - .../components/mui/radio-button/index.tsx | 1 - .../src/pages/components/mui/rating/index.tsx | 1 - .../src/pages/components/mui/slider/index.tsx | 1 - .../pages/components/mui/stepper/index.tsx | 1 - .../src/pages/components/mui/switch/index.tsx | 1 - .../src/pages/components/mui/table/index.tsx | 1 - .../src/pages/components/mui/tabs/index.tsx | 1 - .../pages/components/mui/textfield/index.tsx | 1 - .../pages/components/mui/timeline/index.tsx | 1 - .../pages/components/mui/tooltip/index.tsx | 1 - .../components/mui/transfer-list/index.tsx | 1 - .../pages/components/mui/tree-view/index.tsx | 1 - .../frontend/src/pages/contact-us/index.tsx | 1 - .../src/pages/dashboard/analytics/index.tsx | 1 - .../src/pages/dashboard/banking/index.tsx | 1 - .../src/pages/dashboard/blank/index.tsx | 1 - .../src/pages/dashboard/booking/index.tsx | 1 - .../src/pages/dashboard/calendar/index.tsx | 1 - .../src/pages/dashboard/chat/index.tsx | 1 - .../src/pages/dashboard/course/index.tsx | 1 - .../src/pages/dashboard/ecommerce/index.tsx | 1 - .../pages/dashboard/file-manager/index.tsx | 1 - .../src/pages/dashboard/file/index.tsx | 1 - .../frontend/src/pages/dashboard/index.tsx | 1 - .../src/pages/dashboard/invoice/details.tsx | 8 +-- .../src/pages/dashboard/invoice/edit.tsx | 6 +- .../src/pages/dashboard/invoice/list.tsx | 1 - .../src/pages/dashboard/invoice/new.tsx | 1 - .../src/pages/dashboard/job/details.tsx | 4 +- .../frontend/src/pages/dashboard/job/edit.tsx | 4 +- .../frontend/src/pages/dashboard/job/list.tsx | 1 - .../frontend/src/pages/dashboard/job/new.tsx | 1 - .../src/pages/dashboard/kanban/index.tsx | 1 - .../src/pages/dashboard/mail/index.tsx | 1 - .../src/pages/dashboard/order/details.tsx | 6 +- .../src/pages/dashboard/order/list.tsx | 1 - .../src/pages/dashboard/params/index.tsx | 1 - .../src/pages/dashboard/permission/index.tsx | 1 - .../src/pages/dashboard/post/details.tsx | 6 +- .../src/pages/dashboard/post/edit.tsx | 6 +- .../src/pages/dashboard/post/list.tsx | 1 - .../frontend/src/pages/dashboard/post/new.tsx | 1 - .../src/pages/dashboard/product/new.tsx | 1 - .../src/pages/dashboard/tour/details.tsx | 4 +- .../src/pages/dashboard/tour/edit.tsx | 4 +- .../src/pages/dashboard/tour/list.tsx | 1 - .../frontend/src/pages/dashboard/tour/new.tsx | 1 - .../pages/dashboard/user/account/billing.tsx | 1 - .../user/account/change-password.tsx | 1 - .../pages/dashboard/user/account/general.tsx | 1 - .../dashboard/user/account/notifications.tsx | 1 - .../pages/dashboard/user/account/socials.tsx | 1 - .../src/pages/dashboard/user/cards.tsx | 1 - .../src/pages/dashboard/user/edit.tsx | 2 +- .../frontend/src/pages/dashboard/user/new.tsx | 1 - 03_source/frontend/src/pages/error/403.tsx | 1 - 03_source/frontend/src/pages/error/404.tsx | 1 - 03_source/frontend/src/pages/error/500.tsx | 1 - 03_source/frontend/src/pages/faqs/index.tsx | 1 - .../frontend/src/pages/maintenance/index.tsx | 1 - .../frontend/src/pages/payment/index.tsx | 1 - 03_source/frontend/src/pages/post/details.tsx | 6 +- 03_source/frontend/src/pages/post/list.tsx | 3 +- .../frontend/src/pages/pricing/index.tsx | 1 - .../frontend/src/pages/product/checkout.tsx | 1 - .../frontend/src/pages/product/details.tsx | 6 +- .../src/routes/components/error-boundary.tsx | 6 +- .../src/routes/components/router-link.tsx | 1 - 03_source/frontend/src/routes/paths.ts | 1 - .../src/routes/sections/auth-demo.tsx | 11 ++- .../frontend/src/routes/sections/auth.tsx | 12 ++-- .../src/routes/sections/components.tsx | 6 +- .../src/routes/sections/dashboard.tsx | 14 ++-- .../frontend/src/routes/sections/index.tsx | 12 ++-- .../frontend/src/routes/sections/main.tsx | 9 +-- .../animate-view/background/container.tsx | 6 +- .../extra/animate-view/background/index.tsx | 9 +-- .../extra/animate-view/background/toolbar.tsx | 2 - .../extra/animate-view/control-panel.tsx | 4 +- .../extra/animate-view/dialog/container.tsx | 13 ++-- .../extra/animate-view/dialog/index.tsx | 9 +-- .../extra/animate-view/get-variant.ts | 17 +++-- .../extra/animate-view/inview/container.tsx | 7 +- .../extra/animate-view/inview/index.tsx | 11 ++- .../extra/animate-view/inview/toolbar.tsx | 6 +- .../extra/animate-view/other/avatar.tsx | 8 +-- .../extra/animate-view/other/border.tsx | 7 +- .../extra/animate-view/other/index.tsx | 15 ++-- .../extra/animate-view/other/svg-path.tsx | 4 +- .../extra/animate-view/other/tap-hover.tsx | 12 ++-- .../extra/animate-view/scroll/container.tsx | 12 ++-- .../extra/animate-view/scroll/index.tsx | 9 +-- .../extra/animate-view/scroll/toolbar.tsx | 2 - .../_examples/extra/animate-view/view.tsx | 16 ++--- .../extra/carousel-view/carousel-align.tsx | 6 +- .../carousel-view/carousel-animation.tsx | 9 +-- .../carousel-view/carousel-auto-height.tsx | 7 +- .../carousel-view/carousel-auto-scroll.tsx | 7 +- .../extra/carousel-view/carousel-autoplay.tsx | 7 +- .../extra/carousel-view/carousel-customs.tsx | 8 +-- .../carousel-view/carousel-dots-number.tsx | 10 ++- .../extra/carousel-view/carousel-fade.tsx | 9 +-- .../extra/carousel-view/carousel-opacity.tsx | 6 +- .../extra/carousel-view/carousel-parallax.tsx | 6 +- .../extra/carousel-view/carousel-progress.tsx | 6 +- .../extra/carousel-view/carousel-scale.tsx | 4 +- .../extra/carousel-view/carousel-thumbs-x.tsx | 6 +- .../extra/carousel-view/carousel-thumbs-y.tsx | 6 +- .../carousel-variable-widths.tsx | 6 +- .../extra/carousel-view/carousel-yaxis.tsx | 6 +- .../extra/carousel-view/elements.tsx | 4 +- .../_examples/extra/carousel-view/view.tsx | 23 +++--- .../_examples/extra/chart-view/chart-area.tsx | 1 - .../_examples/extra/chart-view/chart-bar.tsx | 3 +- .../extra/chart-view/chart-box-plot.tsx | 1 - .../chart-view/chart-column-multiple.tsx | 3 +- .../chart-view/chart-column-negative.tsx | 4 +- .../extra/chart-view/chart-column-single.tsx | 3 +- .../extra/chart-view/chart-column-stacked.tsx | 3 +- .../extra/chart-view/chart-donut.tsx | 5 +- .../extra/chart-view/chart-heatmap.tsx | 1 - .../_examples/extra/chart-view/chart-line.tsx | 3 +- .../extra/chart-view/chart-mixed.tsx | 3 +- .../_examples/extra/chart-view/chart-pie.tsx | 5 +- .../extra/chart-view/chart-radar-bar.tsx | 1 - .../extra/chart-view/chart-radial-bar.tsx | 7 +- .../chart-view/chart-semi-circle-gauge.tsx | 4 +- .../extra/chart-view/chart-stroked-gauge.tsx | 4 +- .../extra/chart-view/chart-treemap.tsx | 1 - .../_examples/extra/chart-view/view.tsx | 31 ++++---- .../extra/dnd-view/sortable-container.tsx | 45 ++++++------ .../extra/dnd-view/sortable-item-base.tsx | 14 ++-- .../_examples/extra/dnd-view/view.tsx | 2 +- .../_examples/extra/editor-view/view.tsx | 7 +- .../components/elements.tsx | 3 +- .../components/values-preview.tsx | 21 +++--- .../form-validation-view/controls-demo.tsx | 14 ++-- .../form-validation-view/fields-demo.tsx | 25 +++---- .../extra/form-validation-view/other-demo.tsx | 12 ++-- .../extra/form-validation-view/schema.ts | 6 +- .../extra/form-validation-view/view.tsx | 17 ++--- .../extra/form-wizard-view/form-steps.tsx | 7 +- .../extra/form-wizard-view/form-wizard.tsx | 13 ++-- .../_examples/extra/form-wizard-view/view.tsx | 2 +- .../_examples/extra/image-view/view.tsx | 9 +-- .../_examples/extra/label-view/view.tsx | 7 +- .../_examples/extra/layout-view/view.tsx | 25 +++---- .../_examples/extra/lightbox-view/view.tsx | 13 ++-- .../map-view/change-theme/control-panel.tsx | 3 +- .../extra/map-view/change-theme/index.tsx | 5 +- .../draggable-markers/control-panel.tsx | 4 +- .../map-view/draggable-markers/index.tsx | 9 +-- .../extra/map-view/heatmap/control-panel.tsx | 4 +- .../extra/map-view/heatmap/index.tsx | 9 +-- .../map-view/interaction/control-panel.tsx | 7 +- .../extra/map-view/interaction/index.tsx | 6 +- .../_examples/extra/map-view/map-clusters.tsx | 6 +- .../extra/map-view/map-geo-json-animation.tsx | 11 ++- .../map-view/map-highlight-by-filter.tsx | 13 ++-- .../extra/map-view/map-markers-popups.tsx | 11 ++- .../map-view/side-by-side/control-panel.tsx | 1 - .../extra/map-view/side-by-side/index.tsx | 8 +-- .../_examples/extra/map-view/styles.tsx | 3 +- .../_examples/extra/map-view/view.tsx | 18 +++-- .../viewport-animation/control-panel.tsx | 3 +- .../map-view/viewport-animation/index.tsx | 6 +- .../_examples/extra/markdown-view/view.tsx | 5 +- .../_examples/extra/mega-menu-view/data.tsx | 6 +- .../extra/mega-menu-view/horizontal.tsx | 4 +- .../_examples/extra/mega-menu-view/mobile.tsx | 4 +- .../extra/mega-menu-view/vertical.tsx | 7 +- .../_examples/extra/mega-menu-view/view.tsx | 4 +- .../nav-config-translate.tsx | 9 +-- .../extra/multi-language-view/view.tsx | 26 +++---- .../extra/navigation-bar-view/data.tsx | 6 +- .../extra/navigation-bar-view/nav-api.tsx | 13 ++-- .../extra/navigation-bar-view/nav-basic.tsx | 11 ++- .../navigation-bar-view/nav-horizontal.tsx | 2 - .../extra/navigation-bar-view/nav-mini.tsx | 2 - .../navigation-bar-view/nav-vertical.tsx | 24 +++---- .../extra/navigation-bar-view/view.tsx | 8 +-- .../extra/organizational-chart-view/data.ts | 5 +- .../organizational-chart-view/group-node.tsx | 24 +++---- .../organizational-chart-view/simple-node.tsx | 4 +- .../standard-node.tsx | 15 ++-- .../extra/organizational-chart-view/view.tsx | 8 +-- .../extra/scroll-progress-view/view.tsx | 10 +-- .../_examples/extra/scrollbar-view/view.tsx | 4 +- .../_examples/extra/snackbar-view/view.tsx | 5 +- .../_examples/extra/upload-view/view.tsx | 14 ++-- .../extra/utilities-view/color-pickers.tsx | 8 +-- .../extra/utilities-view/countdown.tsx | 4 +- .../extra/utilities-view/gradients.tsx | 8 +-- .../extra/utilities-view/number-inputs.tsx | 2 - .../_examples/extra/utilities-view/styled.tsx | 6 +- .../extra/utilities-view/text-max-line.tsx | 1 - .../_examples/extra/utilities-view/view.tsx | 14 ++-- .../_examples/foundation/colors-view/view.tsx | 10 +-- .../_examples/foundation/grid-view/view.tsx | 14 ++-- .../foundation/icons-view/iconify-view.tsx | 17 ++--- .../_examples/foundation/icons-view/view.tsx | 34 ++++----- .../foundation/shadows-view/view.tsx | 6 +- .../foundation/typography-view/view.tsx | 7 +- .../_examples/layout/component-box.tsx | 3 +- .../_examples/layout/component-card.tsx | 15 ++-- .../_examples/layout/component-layout.tsx | 32 ++++----- .../_examples/layout/component-nav-item.tsx | 3 +- .../_examples/layout/component-nav.tsx | 15 ++-- .../_examples/layout/component-search.tsx | 27 +++---- .../src/sections/_examples/layout/hooks.ts | 2 +- .../_examples/layout/nav-config-components.ts | 3 +- .../_examples/mui/accordion-view/view.tsx | 10 +-- .../_examples/mui/alert-view/view.tsx | 9 +-- .../_examples/mui/autocomplete-view/view.tsx | 10 +-- .../_examples/mui/avatar-view/view.tsx | 7 +- .../_examples/mui/badge-view/view.tsx | 7 +- .../_examples/mui/breadcrumbs-view/view.tsx | 10 ++- .../mui/button-view/button-groups.tsx | 1 - .../mui/button-view/button-variants.tsx | 2 - .../button-view/floating-action-button.tsx | 7 +- .../mui/button-view/icon-buttons.tsx | 7 +- .../mui/button-view/toggle-buttons.tsx | 5 +- .../_examples/mui/button-view/view.tsx | 12 ++-- .../_examples/mui/checkbox-view/view.tsx | 7 +- .../sections/_examples/mui/chip-view/chip.tsx | 5 +- .../sections/_examples/mui/chip-view/view.tsx | 2 +- .../mui/data-grid-view/data-grid-basic.tsx | 4 +- .../mui/data-grid-view/data-grid-custom.tsx | 42 +++++------ .../_examples/mui/data-grid-view/view.tsx | 2 - .../date-pickers-view/picker-date-range.tsx | 10 +-- .../date-pickers-view/picker-date-time.tsx | 11 ++- .../mui/date-pickers-view/picker-date.tsx | 13 ++-- .../mui/date-pickers-view/picker-time.tsx | 13 ++-- .../_examples/mui/date-pickers-view/view.tsx | 7 +- .../mui/dialog-view/alert-dialog.tsx | 5 +- .../_examples/mui/dialog-view/form-dialog.tsx | 9 ++- .../mui/dialog-view/full-screen-dialog.tsx | 19 +++-- .../mui/dialog-view/max-width-dialog.tsx | 24 +++---- .../mui/dialog-view/scroll-dialog.tsx | 10 ++- .../mui/dialog-view/simple-dialog.tsx | 12 ++-- .../mui/dialog-view/transitions-dialog.tsx | 10 ++- .../_examples/mui/dialog-view/view.tsx | 8 +-- .../mui/drawer-view/anchor-drawer.tsx | 12 ++-- .../_examples/mui/drawer-view/view.tsx | 2 +- .../sections/_examples/mui/list-view/view.tsx | 24 +++---- .../sections/_examples/mui/menu-view/view.tsx | 13 ++-- .../mui/pagination-view/pagination-items.tsx | 16 ++--- .../_examples/mui/pagination-view/view.tsx | 9 +-- .../_examples/mui/popover-view/view.tsx | 22 +++--- .../mui/progress-view/progress-circular.tsx | 1 - .../mui/progress-view/progress-linear.tsx | 1 - .../_examples/mui/progress-view/view.tsx | 9 +-- .../_examples/mui/radio-button-view/view.tsx | 10 ++- .../_examples/mui/rating-view/view.tsx | 8 +-- .../_examples/mui/slider-view/view.tsx | 7 +- .../mui/stepper-view/customized-steppers.tsx | 17 ++--- .../horizontal-linear-stepper.tsx | 11 ++- .../linear-alternative-label-stepper.tsx | 11 ++- .../stepper-view/vertical-linear-stepper.tsx | 15 ++-- .../_examples/mui/stepper-view/view.tsx | 7 +- .../_examples/mui/switch-view/view.tsx | 5 +- .../_examples/mui/table-view/basic.tsx | 8 +-- .../_examples/mui/table-view/collapsible.tsx | 16 ++--- .../mui/table-view/grouping-fixed-header.tsx | 9 ++- .../mui/table-view/pagination-with-api.tsx | 22 +++--- .../mui/table-view/sorting-selecting.tsx | 21 +++--- .../table-view/table-pagination-with-api.tsx | 29 ++++---- .../_examples/mui/table-view/view.tsx | 7 +- .../sections/_examples/mui/tabs-view/view.tsx | 11 ++- .../mui/textfield-view/textfield.tsx | 12 ++-- .../_examples/mui/textfield-view/view.tsx | 6 +- .../_examples/mui/timeline-view/view.tsx | 15 ++-- .../_examples/mui/tooltip-view/view.tsx | 18 ++--- .../enhanced-transfer-list.tsx | 16 ++--- .../simple-transfer-list.tsx | 14 ++-- .../_examples/mui/transfer-list-view/view.tsx | 2 +- .../_examples/mui/tree-view/basic.tsx | 3 +- .../_examples/mui/tree-view/custom-icon.tsx | 3 +- .../mui/tree-view/custom-styling.tsx | 8 +-- .../sections/_examples/mui/tree-view/view.tsx | 4 +- .../frontend/src/sections/_examples/view.tsx | 9 +-- .../src/sections/about/about-hero.tsx | 8 +-- .../src/sections/about/about-team.tsx | 16 ++--- .../src/sections/about/about-testimonials.tsx | 31 ++++---- .../src/sections/about/about-vision.tsx | 20 +++--- .../src/sections/about/about-what.tsx | 21 +++--- .../src/sections/about/view/about-view.tsx | 4 +- .../account/account-billing-address.tsx | 22 +++--- .../account/account-billing-history.tsx | 22 +++--- .../account/account-billing-payment.tsx | 18 ++--- .../sections/account/account-billing-plan.tsx | 21 +++--- .../src/sections/account/account-billing.tsx | 12 ++-- .../account/account-change-password.tsx | 14 ++-- .../src/sections/account/account-general.tsx | 18 ++--- .../src/sections/account/account-layout.tsx | 19 ++--- .../account/account-notifications.tsx | 21 +++--- .../src/sections/account/account-socials.tsx | 13 ++-- .../account/view/account-billing-view.tsx | 3 +- .../account/view/account-socials-view.tsx | 1 - .../src/sections/address/address-item.tsx | 6 +- .../sections/address/address-list-dialog.tsx | 17 ++--- .../src/sections/address/address-new-form.tsx | 17 ++--- .../frontend/src/sections/blank/view.tsx | 7 +- .../src/sections/blog/post-comment-form.tsx | 8 +-- .../src/sections/blog/post-comment-item.tsx | 12 ++-- .../src/sections/blog/post-comment-list.tsx | 4 +- .../src/sections/blog/post-details-hero.tsx | 21 +++--- .../sections/blog/post-details-preview.tsx | 13 ++-- .../sections/blog/post-details-toolbar.tsx | 16 ++--- .../sections/blog/post-item-horizontal.tsx | 35 ++++------ .../frontend/src/sections/blog/post-item.tsx | 30 ++++---- .../sections/blog/post-list-horizontal.tsx | 7 +- .../frontend/src/sections/blog/post-list.tsx | 11 ++- .../src/sections/blog/post-new-edit-form.tsx | 46 ++++++------ .../src/sections/blog/post-search.tsx | 29 ++++---- .../src/sections/blog/post-skeleton.tsx | 1 - .../frontend/src/sections/blog/post-sort.tsx | 8 +-- .../sections/blog/view/post-create-view.tsx | 7 +- .../blog/view/post-details-home-view.tsx | 37 +++++----- .../sections/blog/view/post-details-view.tsx | 45 +++++------- .../src/sections/blog/view/post-edit-view.tsx | 10 +-- .../blog/view/post-list-home-view.tsx | 16 ++--- .../src/sections/blog/view/post-list-view.tsx | 30 ++++---- .../calendar/calendar-filters-result.tsx | 16 ++--- .../sections/calendar/calendar-filters.tsx | 28 ++++---- .../src/sections/calendar/calendar-form.tsx | 31 ++++---- .../sections/calendar/calendar-toolbar.tsx | 19 +++-- .../sections/calendar/hooks/use-calendar.ts | 10 ++- .../src/sections/calendar/hooks/use-event.ts | 4 +- .../frontend/src/sections/calendar/styles.tsx | 3 +- .../sections/calendar/view/calendar-view.tsx | 38 +++++----- .../src/sections/chat/chat-header-compose.tsx | 13 ++-- .../src/sections/chat/chat-header-detail.tsx | 26 +++---- .../src/sections/chat/chat-message-input.tsx | 24 +++---- .../src/sections/chat/chat-message-item.tsx | 15 ++-- .../src/sections/chat/chat-message-list.tsx | 9 +-- .../src/sections/chat/chat-nav-account.tsx | 36 +++++----- .../src/sections/chat/chat-nav-item.tsx | 27 +++---- .../sections/chat/chat-nav-search-results.tsx | 8 +-- .../frontend/src/sections/chat/chat-nav.tsx | 39 ++++------- .../sections/chat/chat-room-attachments.tsx | 13 ++-- .../src/sections/chat/chat-room-group.tsx | 15 ++-- .../chat/chat-room-participant-dialog.tsx | 15 ++-- .../src/sections/chat/chat-room-single.tsx | 12 ++-- .../frontend/src/sections/chat/chat-room.tsx | 12 ++-- .../src/sections/chat/chat-skeleton.tsx | 3 +- .../sections/chat/hooks/use-collapse-nav.ts | 2 +- .../chat/hooks/use-messages-scroll.ts | 3 +- .../frontend/src/sections/chat/layout.tsx | 3 +- .../frontend/src/sections/chat/styles.tsx | 6 +- .../chat/utils/initial-conversation.ts | 4 +- .../src/sections/chat/view/chat-view.tsx | 33 ++++----- .../checkout/checkout-billing-address.tsx | 15 ++-- .../checkout/checkout-billing-info.tsx | 10 ++- .../checkout/checkout-cart-product-list.tsx | 7 +- .../checkout/checkout-cart-product.tsx | 19 +++-- .../src/sections/checkout/checkout-cart.tsx | 22 +++--- .../sections/checkout/checkout-delivery.tsx | 11 ++- .../checkout/checkout-order-complete.tsx | 16 ++--- .../checkout/checkout-payment-methods.tsx | 24 +++---- .../sections/checkout/checkout-payment.tsx | 26 +++---- .../src/sections/checkout/checkout-steps.tsx | 10 ++- .../sections/checkout/checkout-summary.tsx | 19 +++-- .../checkout/context/checkout-context.ts | 3 +- .../checkout/context/checkout-provider.tsx | 15 ++-- .../checkout/context/use-checkout-context.ts | 1 - .../sections/checkout/view/checkout-view.tsx | 13 ++-- .../src/sections/coming-soon/view.tsx | 13 ++-- .../src/sections/contact/contact-form.tsx | 1 - .../src/sections/contact/contact-hero.tsx | 10 +-- .../src/sections/contact/contact-map.tsx | 11 ++- .../sections/contact/view/contact-view.tsx | 6 +- .../frontend/src/sections/error/403-view.tsx | 12 ++-- .../frontend/src/sections/error/500-view.tsx | 12 ++-- .../src/sections/error/not-found-view.tsx | 12 ++-- .../src/sections/faqs/faqs-category.tsx | 15 ++-- .../frontend/src/sections/faqs/faqs-form.tsx | 1 - .../frontend/src/sections/faqs/faqs-hero.tsx | 14 ++-- .../frontend/src/sections/faqs/faqs-list.tsx | 11 ++- .../src/sections/faqs/view/faqs-view.tsx | 5 +- .../file-manager/file-data-activity.tsx | 12 ++-- .../file-manager-action-selected.tsx | 6 +- .../file-manager-file-details.tsx | 41 +++++------ .../file-manager/file-manager-file-item.tsx | 43 +++++------- .../file-manager-filters-result.tsx | 14 ++-- .../file-manager/file-manager-filters.tsx | 30 ++++---- .../file-manager/file-manager-folder-item.tsx | 38 +++++----- .../file-manager/file-manager-grid-view.tsx | 20 +++--- .../file-manager-invited-item.tsx | 19 +++-- .../file-manager-new-folder-dialog.tsx | 13 ++-- .../file-manager/file-manager-panel.tsx | 5 +- .../file-manager-share-dialog.tsx | 11 ++- .../file-manager/file-manager-table-row.tsx | 43 +++++------- .../file-manager/file-manager-table.tsx | 19 +++-- .../file-manager/file-recent-item.tsx | 35 ++++------ .../file-manager/file-storage-overview.tsx | 9 +-- .../sections/file-manager/file-upgrade.tsx | 9 +-- .../src/sections/file-manager/file-widget.tsx | 9 +-- .../file-manager/view/file-manager-view.tsx | 34 ++++----- .../home/components/hero-background.tsx | 13 ++-- .../src/sections/home/components/hero-svg.tsx | 11 ++- .../home/components/section-title.tsx | 11 ++- .../sections/home/components/svg-elements.tsx | 11 ++- .../src/sections/home/home-advertisement.tsx | 18 ++--- .../frontend/src/sections/home/home-faqs.tsx | 26 +++---- .../src/sections/home/home-for-designer.tsx | 18 ++--- .../frontend/src/sections/home/home-hero.tsx | 30 ++++---- .../sections/home/home-highlight-features.tsx | 25 +++---- .../sections/home/home-hugepack-elements.tsx | 26 +++---- .../src/sections/home/home-integrations.tsx | 13 ++-- .../src/sections/home/home-minimal.tsx | 13 ++-- .../src/sections/home/home-pricing.tsx | 28 +++----- .../src/sections/home/home-testimonials.tsx | 30 ++++---- .../src/sections/home/home-zone-ui.tsx | 22 +++--- .../src/sections/home/view/home-view.tsx | 16 ++--- .../src/sections/invoice/invoice-analytic.tsx | 12 ++-- .../src/sections/invoice/invoice-details.tsx | 28 +++----- .../invoice/invoice-new-edit-address.tsx | 11 +-- .../invoice/invoice-new-edit-details.tsx | 19 ++--- .../invoice/invoice-new-edit-form.tsx | 26 +++---- .../invoice/invoice-new-edit-status-date.tsx | 6 +- .../src/sections/invoice/invoice-pdf.tsx | 28 ++++---- .../invoice/invoice-table-filters-result.tsx | 14 ++-- .../sections/invoice/invoice-table-row.tsx | 37 +++++----- .../invoice/invoice-table-toolbar.tsx | 43 ++++++------ .../src/sections/invoice/invoice-toolbar.tsx | 27 +++---- .../invoice/invoice-total-summary.tsx | 6 +- .../invoice/view/invoice-create-view.tsx | 7 +- .../invoice/view/invoice-details-view.tsx | 14 ++-- .../invoice/view/invoice-edit-view.tsx | 10 +-- .../invoice/view/invoice-list-view.tsx | 68 ++++++++---------- .../sections/job/job-details-candidates.tsx | 15 ++-- .../src/sections/job/job-details-content.tsx | 17 ++--- .../src/sections/job/job-details-toolbar.tsx | 16 ++--- .../src/sections/job/job-filters-result.tsx | 11 ++- .../frontend/src/sections/job/job-filters.tsx | 29 ++++---- .../frontend/src/sections/job/job-item.tsx | 31 ++++---- .../frontend/src/sections/job/job-list.tsx | 8 +-- .../src/sections/job/job-new-edit-form.tsx | 43 +++++------- .../frontend/src/sections/job/job-search.tsx | 29 ++++---- .../frontend/src/sections/job/job-sort.tsx | 8 +-- .../src/sections/job/view/job-create-view.tsx | 7 +- .../sections/job/view/job-details-view.tsx | 20 ++---- .../src/sections/job/view/job-edit-view.tsx | 10 +-- .../src/sections/job/view/job-list-view.tsx | 36 ++++------ .../sections/kanban/column/column-base.tsx | 7 +- .../kanban/column/kanban-column-add.tsx | 14 ++-- .../kanban/column/kanban-column-toolbar.tsx | 18 ++--- .../sections/kanban/column/kanban-column.tsx | 16 ++--- .../components/kanban-contacts-dialog.tsx | 18 ++--- .../kanban/components/kanban-drag-overlay.tsx | 13 ++-- .../kanban/components/kanban-input-name.tsx | 1 - .../kanban/components/kanban-skeleton.tsx | 1 - .../kanban/components/kanban-task-add.tsx | 16 ++--- .../details/kanban-details-attachments.tsx | 5 +- .../details/kanban-details-comment-input.tsx | 12 ++-- .../details/kanban-details-comment-list.tsx | 11 ++- .../details/kanban-details-priority.tsx | 5 +- .../kanban/details/kanban-details-toolbar.tsx | 15 ++-- .../kanban/details/kanban-details.tsx | 48 ++++++------- .../src/sections/kanban/item/item-base.tsx | 16 ++--- .../sections/kanban/item/kanban-task-item.tsx | 12 ++-- .../frontend/src/sections/kanban/utils.ts | 3 +- .../src/sections/kanban/view/kanban-view.tsx | 49 ++++++------- .../frontend/src/sections/mail/layout.tsx | 3 +- .../src/sections/mail/mail-compose.tsx | 18 +++-- .../src/sections/mail/mail-details.tsx | 35 ++++------ .../src/sections/mail/mail-header.tsx | 4 +- .../frontend/src/sections/mail/mail-item.tsx | 12 ++-- .../frontend/src/sections/mail/mail-list.tsx | 14 ++-- .../src/sections/mail/mail-nav-item.tsx | 8 +-- .../frontend/src/sections/mail/mail-nav.tsx | 14 ++-- .../src/sections/mail/mail-skeleton.tsx | 4 +- .../src/sections/mail/view/mail-view.tsx | 20 +++--- .../src/sections/maintenance/view.tsx | 4 +- .../sections/order/order-details-customer.tsx | 12 ++-- .../sections/order/order-details-delivery.tsx | 10 ++- .../sections/order/order-details-history.tsx | 20 +++--- .../sections/order/order-details-items.tsx | 15 ++-- .../sections/order/order-details-payment.tsx | 6 +- .../sections/order/order-details-shipping.tsx | 8 +-- .../sections/order/order-details-toolbar.tsx | 25 +++---- .../order/order-table-filters-result.tsx | 14 ++-- .../src/sections/order/order-table-row.tsx | 39 +++++------ .../sections/order/order-table-toolbar.tsx | 25 +++---- .../order/view/order-details-view.tsx | 29 ++++---- .../sections/order/view/order-list-view.tsx | 61 +++++++--------- .../analytics/analytics-conversion-rates.tsx | 9 +-- .../analytics/analytics-current-subject.tsx | 8 +-- .../analytics/analytics-current-visits.tsx | 9 +-- .../overview/analytics/analytics-news.tsx | 19 +++-- .../analytics/analytics-order-timeline.tsx | 20 +++--- .../overview/analytics/analytics-tasks.tsx | 23 +++--- .../analytics/analytics-traffic-by-site.tsx | 10 +-- .../analytics/analytics-website-visits.tsx | 6 +- .../analytics/analytics-widget-summary.tsx | 19 ++--- .../view/overview-analytics-view.tsx | 24 +++---- .../overview/app/app-area-installed.tsx | 12 ++-- .../overview/app/app-current-download.tsx | 9 +-- .../sections/overview/app/app-featured.tsx | 15 ++-- .../sections/overview/app/app-new-invoice.tsx | 32 ++++----- .../sections/overview/app/app-top-authors.tsx | 14 ++-- .../app/app-top-installed-countries.tsx | 11 ++- .../sections/overview/app/app-top-related.tsx | 30 ++++---- .../src/sections/overview/app/app-welcome.tsx | 5 +- .../overview/app/app-widget-summary.tsx | 11 ++- .../src/sections/overview/app/app-widget.tsx | 14 ++-- .../overview/app/view/overview-app-view.tsx | 24 +++---- .../banking/banking-balance-statistics.tsx | 14 ++-- .../overview/banking/banking-contacts.tsx | 16 ++--- .../banking/banking-current-balance.tsx | 21 +++--- .../banking/banking-expenses-categories.tsx | 11 ++- .../banking/banking-invite-friends.tsx | 4 +- .../overview/banking/banking-overview.tsx | 20 +++--- .../banking/banking-quick-transfer.tsx | 42 +++++------ .../banking/banking-recent-transitions.tsx | 50 ++++++------- .../banking/view/overview-banking-view.tsx | 15 ++-- .../overview/booking/booking-available.tsx | 16 ++--- .../overview/booking/booking-booked.tsx | 7 +- .../booking/booking-check-in-widgets.tsx | 11 ++- .../booking/booking-customer-reviews.tsx | 28 ++++---- .../overview/booking/booking-details.tsx | 46 ++++++------ .../overview/booking/booking-newest.tsx | 17 ++--- .../overview/booking/booking-statistics.tsx | 12 ++-- .../booking/booking-total-incomes.tsx | 16 ++--- .../booking/booking-widget-summary.tsx | 7 +- .../booking/view/overview-booking-view.tsx | 16 ++--- .../overview/course/course-continue.tsx | 15 ++-- .../overview/course/course-featured.tsx | 15 ++-- .../overview/course/course-hours-spent.tsx | 11 ++- .../overview/course/course-my-account.tsx | 13 ++-- .../overview/course/course-my-strength.tsx | 2 - .../overview/course/course-progress.tsx | 11 ++- .../overview/course/course-reminders.tsx | 18 ++--- .../overview/course/course-widget-summary.tsx | 9 +-- .../course/view/overview-course-view.tsx | 13 ++-- .../e-commerce/ecommerce-best-salesman.tsx | 23 +++--- .../e-commerce/ecommerce-current-balance.tsx | 6 +- .../e-commerce/ecommerce-latest-products.tsx | 17 ++--- .../e-commerce/ecommerce-new-products.tsx | 11 ++- .../e-commerce/ecommerce-sale-by-gender.tsx | 14 ++-- .../e-commerce/ecommerce-sales-overview.tsx | 9 +-- .../overview/e-commerce/ecommerce-welcome.tsx | 5 +- .../e-commerce/ecommerce-widget-summary.tsx | 14 ++-- .../e-commerce/ecommerce-yearly-sales.tsx | 12 ++-- .../view/overview-ecommerce-view.tsx | 23 +++--- .../overview/file/view/overview-file-view.tsx | 27 +++---- .../sections/payment/payment-card-item.tsx | 19 +++-- .../payment/payment-card-list-dialog.tsx | 12 ++-- .../src/sections/payment/payment-methods.tsx | 16 ++--- .../payment/payment-new-card-form.tsx | 9 +-- .../src/sections/payment/payment-summary.tsx | 8 +-- .../sections/payment/view/payment-view.tsx | 7 +- .../frontend/src/sections/permission/view.tsx | 15 ++-- .../src/sections/pricing/pricing-card.tsx | 16 ++--- .../sections/pricing/view/pricing-view.tsx | 6 +- .../src/sections/product/cart-icon.tsx | 11 ++- .../product/product-details-carousel.tsx | 15 ++-- .../product/product-details-description.tsx | 3 +- .../product/product-details-review.tsx | 19 ++--- .../product/product-details-summary.tsx | 35 ++++------ .../product/product-filters-drawer.tsx | 35 +++++----- .../product/product-filters-result.tsx | 13 ++-- .../sections/product/product-review-item.tsx | 13 ++-- .../sections/product/product-review-list.tsx | 4 +- .../product/product-review-new-form.tsx | 17 ++--- .../src/sections/product/product-search.tsx | 29 ++++---- .../src/sections/product/product-skeleton.tsx | 7 +- .../src/sections/product/product-sort.tsx | 8 +-- .../product/product-table-filters-result.tsx | 13 ++-- .../view/confirm-delete-product-dialog.tsx | 5 +- .../product/view/product-shop-view.tsx | 32 ++++----- .../sections/tour/tour-details-bookers.tsx | 19 +++-- .../sections/tour/tour-details-content.tsx | 18 ++--- .../sections/tour/tour-details-toolbar.tsx | 16 ++--- .../src/sections/tour/tour-filters-result.tsx | 16 ++--- .../src/sections/tour/tour-filters.tsx | 41 +++++------ .../frontend/src/sections/tour/tour-item.tsx | 27 +++---- .../frontend/src/sections/tour/tour-list.tsx | 8 +-- .../src/sections/tour/tour-new-edit-form.tsx | 50 ++++++------- .../src/sections/tour/tour-search.tsx | 29 ++++---- .../frontend/src/sections/tour/tour-sort.tsx | 8 +-- .../sections/tour/view/tour-create-view.tsx | 7 +- .../sections/tour/view/tour-details-view.tsx | 18 ++--- .../src/sections/tour/view/tour-edit-view.tsx | 10 +-- .../src/sections/tour/view/tour-list-view.tsx | 37 ++++------ .../src/sections/user/profile-cover.tsx | 10 ++- .../src/sections/user/profile-followers.tsx | 17 ++--- .../src/sections/user/profile-friends.tsx | 24 +++---- .../src/sections/user/profile-gallery.tsx | 11 ++- .../src/sections/user/profile-home.tsx | 39 +++++------ .../src/sections/user/profile-post-item.tsx | 37 +++++----- .../src/sections/user/user-card-list.tsx | 7 +- .../frontend/src/sections/user/user-card.tsx | 19 ++--- .../user/user-table-filters-result.tsx | 11 ++- .../src/sections/user/user-table-toolbar.tsx | 29 ++++---- .../sections/user/view/user-cards-view.tsx | 25 +++---- .../sections/user/view/user-create-view.tsx | 11 ++- .../src/sections/user/view/user-edit-view.tsx | 2 +- .../src/sections/user/view/user-list-view.tsx | 4 +- .../sections/user/view/user-profile-view.tsx | 49 +++++++------ .../src/theme/core/components/accordion.tsx | 5 +- .../src/theme/core/components/alert.tsx | 10 ++- .../src/theme/core/components/appbar.tsx | 2 +- .../theme/core/components/autocomplete.tsx | 10 ++- .../src/theme/core/components/avatar.tsx | 6 +- .../src/theme/core/components/backdrop.tsx | 3 +- .../src/theme/core/components/badge.tsx | 2 +- .../src/theme/core/components/breadcrumbs.tsx | 2 +- .../src/theme/core/components/button-fab.tsx | 6 +- .../theme/core/components/button-group.tsx | 6 +- .../theme/core/components/button-toggle.tsx | 6 +- .../src/theme/core/components/button.tsx | 6 +- .../src/theme/core/components/card.tsx | 2 +- .../src/theme/core/components/checkbox.tsx | 7 +- .../src/theme/core/components/chip.tsx | 10 ++- .../src/theme/core/components/dialog.tsx | 2 +- .../src/theme/core/components/drawer.tsx | 3 +- .../src/theme/core/components/form.tsx | 3 +- .../src/theme/core/components/index.ts | 70 +++++++++---------- .../src/theme/core/components/link.tsx | 2 +- .../src/theme/core/components/list.tsx | 2 +- .../src/theme/core/components/menu.tsx | 2 +- .../theme/core/components/mui-x-data-grid.tsx | 24 +++---- .../core/components/mui-x-date-picker.tsx | 7 +- .../theme/core/components/mui-x-tree-view.tsx | 2 +- .../src/theme/core/components/pagination.tsx | 6 +- .../src/theme/core/components/paper.tsx | 3 +- .../src/theme/core/components/popover.tsx | 3 +- .../src/theme/core/components/progress.tsx | 3 +- .../src/theme/core/components/radio.tsx | 7 +- .../src/theme/core/components/rating.tsx | 8 +-- .../src/theme/core/components/select.tsx | 3 +- .../src/theme/core/components/skeleton.tsx | 3 +- .../src/theme/core/components/slider.tsx | 6 +- .../src/theme/core/components/stack.tsx | 2 +- .../src/theme/core/components/stepper.tsx | 2 +- .../src/theme/core/components/svg-icon.tsx | 2 +- .../src/theme/core/components/switch.tsx | 6 +- .../src/theme/core/components/table.tsx | 8 +-- .../src/theme/core/components/tabs.tsx | 3 +- .../src/theme/core/components/textfield.tsx | 8 +-- .../src/theme/core/components/timeline.tsx | 2 +- .../src/theme/core/components/tooltip.tsx | 3 +- .../src/theme/core/components/typography.tsx | 2 +- .../frontend/src/theme/core/custom-shadows.ts | 4 +- .../core/mixins/global-styles-components.ts | 12 ++-- .../frontend/src/theme/core/mixins/mixins.ts | 7 +- .../frontend/src/theme/core/mixins/text.ts | 6 +- 03_source/frontend/src/theme/core/palette.ts | 7 +- 03_source/frontend/src/theme/core/shadows.ts | 5 +- .../frontend/src/theme/core/typography.ts | 7 +- 03_source/frontend/src/theme/create-theme.ts | 19 +++-- .../src/theme/extend-theme-types.d.ts | 17 +++-- .../frontend/src/theme/theme-overrides.ts | 1 - .../frontend/src/theme/theme-provider.tsx | 9 +-- 03_source/frontend/src/theme/types.ts | 7 +- .../src/theme/with-settings/color-presets.ts | 3 +- .../src/theme/with-settings/right-to-left.tsx | 5 +- .../theme/with-settings/update-components.ts | 7 +- .../src/theme/with-settings/update-core.ts | 9 +-- 03_source/frontend/src/types/chat.ts | 1 - 03_source/frontend/src/types/file.ts | 2 +- 03_source/frontend/src/types/invoice.ts | 2 +- 03_source/frontend/src/types/kanban.ts | 1 - 03_source/frontend/src/types/order.ts | 2 +- 03_source/frontend/src/types/tour.ts | 2 +- 03_source/frontend/src/utils/format-time.ts | 1 - 03_source/mobile/package.json | 9 ++- HKSingleParty.code-workspace | 2 +- 1088 files changed, 4376 insertions(+), 7002 deletions(-) rename 03_source/cms_backend/src/app/services/{AccessLog.service.ts => access-log.service.ts} (100%) rename 03_source/cms_backend/src/app/services/{AppLog.service.ts => app-log.service.ts} (100%) rename 03_source/cms_backend/src/app/services/{userItem.service.ts => user-item.service.ts} (100%) diff --git a/03_source/cms_backend/package.json b/03_source/cms_backend/package.json index 5a45071..dafd392 100644 --- a/03_source/cms_backend/package.json +++ b/03_source/cms_backend/package.json @@ -19,8 +19,10 @@ "re:build": "yarn clean && yarn install && yarn build", "re:build-npm": "npm run clean && npm install && npm run build", "tsc:dev": "yarn dev & yarn tsc:watch", - "tsc:watch": "tsc --noEmit --watch", "tsc:print": "npx tsc --showConfig", + "tsc:w": "npx nodemon --delay 3 --ext ts,tsx --exec \"yarn tsc\"", + "tsc:watch": "tsc --noEmit --watch", + "tsc": "tsc --noEmit", "migrate": "npx prisma migrate dev --skip-seed", "seed": "tsx ./prisma/seed.ts", "seed:w": "npx nodemon --ext \"ts,tsx,json\" -w prisma --exec \"yarn seed\"", diff --git a/03_source/cms_backend/scripts/10_build.sh b/03_source/cms_backend/scripts/10_build.sh index 3d13936..8154f68 100755 --- a/03_source/cms_backend/scripts/10_build.sh +++ b/03_source/cms_backend/scripts/10_build.sh @@ -2,11 +2,16 @@ set -x -yarn db:push +rm -rf ./**/*Zone.Identifier -npx nodemon --ext ts,tsx --exec "yarn tsc" +# yarn db:push +# npx nodemon --ext ts,tsx --exec "yarn tsc" +set -ex +yarn fm:fix -# yarn build +yarn tsc + +yarn build diff --git a/03_source/cms_backend/src/_mock/_chat.ts b/03_source/cms_backend/src/_mock/_chat.ts index b0ff070..f7963c9 100644 --- a/03_source/cms_backend/src/_mock/_chat.ts +++ b/03_source/cms_backend/src/_mock/_chat.ts @@ -16,11 +16,7 @@ export const _contacts = () => address: _mock.fullAddress(index), avatarUrl: _mock.image.avatar(index), phoneNumber: _mock.phoneNumber(index), - status: - ([0, 1, 6, 12].includes(index) && 'online') || - ([3, 8, 14].includes(index) && 'offline') || - ([4, 10, 16].includes(index) && 'busy') || - 'always', + status: ([0, 1, 6, 12].includes(index) && 'online') || ([3, 8, 14].includes(index) && 'offline') || ([4, 10, 16].includes(index) && 'busy') || 'always', })); export const _conversations = () => { diff --git a/03_source/cms_backend/src/_mock/_kanban.ts b/03_source/cms_backend/src/_mock/_kanban.ts index 9c7bc58..e87797e 100644 --- a/03_source/cms_backend/src/_mock/_kanban.ts +++ b/03_source/cms_backend/src/_mock/_kanban.ts @@ -6,8 +6,7 @@ import { _tags } from './assets'; // ---------------------------------------------------------------------- -const generateAttachments = () => - Array.from({ length: 20 }, (_, index) => _mock.image.cover(index)); +const generateAttachments = () => Array.from({ length: 20 }, (_, index) => _mock.image.cover(index)); const generateAssignees = () => Array.from({ length: 20 }, (_, index) => ({ @@ -68,24 +67,14 @@ const createTask = (index: number, status: string) => { assignee: assignedUser.slice(0, index), description: _mock.description(index), due: [fAdd({ days: index + 1 }), fAdd({ days: index + 2 })], - priority: - ([1, 3].includes(index) && PRIORITY_LEVEL.hight) || - ([2, 4].includes(index) && PRIORITY_LEVEL.medium) || - PRIORITY_LEVEL.low, - attachments: - (index === 1 && attachmentList.slice(11, 15)) || - (index === 5 && attachmentList.slice(4, 9)) || - [], + priority: ([1, 3].includes(index) && PRIORITY_LEVEL.hight) || ([2, 4].includes(index) && PRIORITY_LEVEL.medium) || PRIORITY_LEVEL.low, + attachments: (index === 1 && attachmentList.slice(11, 15)) || (index === 5 && attachmentList.slice(4, 9)) || [], status, }; }; const tasks = () => ({ - [COLUMN_IDS.id1]: [ - createTask(1, COLUMN_NAMES.name1), - createTask(2, COLUMN_NAMES.name1), - createTask(3, COLUMN_NAMES.name1), - ], + [COLUMN_IDS.id1]: [createTask(1, COLUMN_NAMES.name1), createTask(2, COLUMN_NAMES.name1), createTask(3, COLUMN_NAMES.name1)], [COLUMN_IDS.id2]: [createTask(4, COLUMN_NAMES.name2), createTask(5, COLUMN_NAMES.name2)], [COLUMN_IDS.id3]: [], [COLUMN_IDS.id4]: [createTask(6, COLUMN_NAMES.name4)], diff --git a/03_source/cms_backend/src/_mock/_mail.ts b/03_source/cms_backend/src/_mock/_mail.ts index fcbecb5..bdbea7a 100644 --- a/03_source/cms_backend/src/_mock/_mail.ts +++ b/03_source/cms_backend/src/_mock/_mail.ts @@ -28,20 +28,11 @@ export const _mails = () => Array.from({ length: 9 }, (_, index) => { const files = _files(); - const attachments = - (index === 1 && files.slice(0, 2)) || - (index === 2 && files.slice(0, 4)) || - (index === 5 && files.slice(4, 10)) || - []; + const attachments = (index === 1 && files.slice(0, 2)) || (index === 2 && files.slice(0, 4)) || (index === 5 && files.slice(4, 10)) || []; - const folder = - ([1, 2].includes(index) && 'spam') || ([3, 4].includes(index) && 'sent') || 'inbox'; + const folder = ([1, 2].includes(index) && 'spam') || ([3, 4].includes(index) && 'sent') || 'inbox'; - const labelIds = - (index === 1 && ['promotions', 'forums']) || - (index === 2 && ['forums']) || - (index === 5 && ['social']) || - []; + const labelIds = (index === 1 && ['promotions', 'forums']) || (index === 2 && ['forums']) || (index === 5 && ['social']) || []; const from = { name: _mock.fullName(index), diff --git a/03_source/cms_backend/src/_mock/_mock.ts b/03_source/cms_backend/src/_mock/_mock.ts index 9ebe817..dda1a1e 100644 --- a/03_source/cms_backend/src/_mock/_mock.ts +++ b/03_source/cms_backend/src/_mock/_mock.ts @@ -78,11 +78,8 @@ export const _mock = { avatar: (index: number) => `${CONFIG.basePath}/assets/images/avatar/avatar-${index + 1}.webp`, travel: (index: number) => `${CONFIG.basePath}/assets/images/travel/travel-${index + 1}.webp`, course: (index: number) => `${CONFIG.basePath}/assets/images/course/course-${index + 1}.webp`, - company: (index: number) => - `${CONFIG.basePath}/assets/images/company/company-${index + 1}.webp`, - product: (index: number) => - `${CONFIG.basePath}/assets/images/m-product/product-${index + 1}.webp`, - portrait: (index: number) => - `${CONFIG.basePath}/assets/images/portrait/portrait-${index + 1}.webp`, + company: (index: number) => `${CONFIG.basePath}/assets/images/company/company-${index + 1}.webp`, + product: (index: number) => `${CONFIG.basePath}/assets/images/m-product/product-${index + 1}.webp`, + portrait: (index: number) => `${CONFIG.basePath}/assets/images/portrait/portrait-${index + 1}.webp`, }, }; diff --git a/03_source/cms_backend/src/_mock/_product.ts b/03_source/cms_backend/src/_mock/_product.ts index 80c59f1..1098831 100644 --- a/03_source/cms_backend/src/_mock/_product.ts +++ b/03_source/cms_backend/src/_mock/_product.ts @@ -3,16 +3,7 @@ import { _tags } from './assets'; // ---------------------------------------------------------------------- -const COLORS = [ - '#FF4842', - '#1890FF', - '#FFC0CB', - '#00AB55', - '#FFC107', - '#7F00FF', - '#000000', - '#FFFFFF', -]; +const COLORS = ['#FF4842', '#1890FF', '#FFC0CB', '#00AB55', '#FFC107', '#7F00FF', '#000000', '#FFFFFF']; const DESCRIPTION = `
Specifications
@@ -93,8 +84,7 @@ const DESCRIPTION = ` `; -const generateAttachments = () => - Array.from({ length: 20 }, (_, index) => _mock.image.product(index)); +const generateAttachments = () => Array.from({ length: 20 }, (_, index) => _mock.image.product(index)); const generateReviews = () => { const attachments = generateAttachments(); @@ -108,11 +98,7 @@ const generateReviews = () => { rating: _mock.number.rating(index), avatarUrl: _mock.image.avatar(index), helpful: _mock.number.nativeL(index), - attachments: - (index === 1 && attachments.slice(0, 1)) || - (index === 3 && attachments.slice(2, 4)) || - (index === 5 && attachments.slice(5, 8)) || - [], + attachments: (index === 1 && attachments.slice(0, 1)) || (index === 3 && attachments.slice(2, 4)) || (index === 5 && attachments.slice(5, 8)) || [], })); }; @@ -192,7 +178,6 @@ export const _products = () => newLabel: { enabled: [1, 2, 3].includes(index), content: 'NEW' }, saleLabel: { enabled: [4, 5].includes(index), content: 'SALE' }, sizes: ['6', '7', '8', '8.5', '9', '9.5', '10', '10.5', '11', '11.5', '12', '13'], - subDescription: - 'Featuring the original ripple design inspired by Japanese bullet trains, the Nike Air Max 97 lets you push your style full-speed ahead.', + subDescription: 'Featuring the original ripple design inspired by Japanese bullet trains, the Nike Air Max 97 lets you push your style full-speed ahead.', }; }); diff --git a/03_source/cms_backend/src/_mock/assets.ts b/03_source/cms_backend/src/_mock/assets.ts index aba637c..6b8d2b9 100644 --- a/03_source/cms_backend/src/_mock/assets.ts +++ b/03_source/cms_backend/src/_mock/assets.ts @@ -1,9 +1,6 @@ // ---------------------------------------------------------------------- -export const _id = Array.from( - { length: 40 }, - (_, index) => `e99f09a7-dd88-49d5-b1c8-1daf80c2d7b${index + 1}` -); +export const _id = Array.from({ length: 40 }, (_, index) => `e99f09a7-dd88-49d5-b1c8-1daf80c2d7b${index + 1}`); // ---------------------------------------------------------------------- @@ -37,36 +34,24 @@ export const _booleans = [ // ---------------------------------------------------------------------- export const _prices = [ - 83.74, 97.14, 68.71, 85.21, 52.17, 25.18, 43.84, 60.98, 98.42, 53.37, 72.75, 56.61, 64.55, 77.32, - 60.62, 79.81, 93.68, 47.44, 76.24, 92.87, 72.91, 20.54, 94.25, 37.51, + 83.74, 97.14, 68.71, 85.21, 52.17, 25.18, 43.84, 60.98, 98.42, 53.37, 72.75, 56.61, 64.55, 77.32, 60.62, 79.81, 93.68, 47.44, 76.24, 92.87, 72.91, 20.54, + 94.25, 37.51, ]; -export const _ratings = [ - 4.2, 3.7, 4.5, 3.5, 0.5, 3.0, 2.5, 2.8, 4.9, 3.6, 2.5, 1.7, 3.9, 2.8, 4.1, 4.5, 2.2, 3.2, 0.6, - 1.3, 3.8, 3.8, 3.8, 2.0, -]; +export const _ratings = [4.2, 3.7, 4.5, 3.5, 0.5, 3.0, 2.5, 2.8, 4.9, 3.6, 2.5, 1.7, 3.9, 2.8, 4.1, 4.5, 2.2, 3.2, 0.6, 1.3, 3.8, 3.8, 3.8, 2.0]; -export const _ages = [ - 30, 26, 59, 47, 29, 46, 18, 56, 39, 19, 45, 18, 46, 56, 38, 41, 44, 48, 32, 45, 42, 60, 33, 57, -]; +export const _ages = [30, 26, 59, 47, 29, 46, 18, 56, 39, 19, 45, 18, 46, 56, 38, 41, 44, 48, 32, 45, 42, 60, 33, 57]; export const _percents = [ - 10.1, 13.6, 28.2, 42.1, 37.2, 18.5, 40.1, 94.8, 91.4, 53.0, 25.4, 62.9, 86.6, 62.4, 35.4, 17.6, - 52.0, 6.8, 95.3, 26.6, 69.9, 92.1, 46.2, 85.6, + 10.1, 13.6, 28.2, 42.1, 37.2, 18.5, 40.1, 94.8, 91.4, 53.0, 25.4, 62.9, 86.6, 62.4, 35.4, 17.6, 52.0, 6.8, 95.3, 26.6, 69.9, 92.1, 46.2, 85.6, ]; -export const _nativeS = [ - 11, 10, 7, 10, 12, 5, 10, 1, 8, 8, 10, 11, 12, 8, 4, 11, 8, 9, 4, 9, 2, 6, 3, 7, -]; +export const _nativeS = [11, 10, 7, 10, 12, 5, 10, 1, 8, 8, 10, 11, 12, 8, 4, 11, 8, 9, 4, 9, 2, 6, 3, 7]; -export const _nativeM = [ - 497, 763, 684, 451, 433, 463, 951, 194, 425, 435, 807, 521, 538, 839, 394, 269, 453, 821, 364, - 849, 804, 776, 263, 239, -]; +export const _nativeM = [497, 763, 684, 451, 433, 463, 951, 194, 425, 435, 807, 521, 538, 839, 394, 269, 453, 821, 364, 849, 804, 776, 263, 239]; export const _nativeL = [ - 9911, 1947, 9124, 6984, 8488, 2034, 3364, 8401, 8996, 5271, 8478, 1139, 8061, 3035, 6733, 3952, - 2405, 3127, 6843, 4672, 6995, 6053, 5192, 9686, + 9911, 1947, 9124, 6984, 8488, 2034, 3364, 8401, 8996, 5271, 8478, 1139, 8061, 3035, 6733, 3952, 2405, 3127, 6843, 4672, 6995, 6053, 5192, 9686, ]; export const _fullAddress = [ diff --git a/03_source/cms_backend/src/app/api/AccessLog/detail/route.ts b/03_source/cms_backend/src/app/api/AccessLog/detail/route.ts index 02b0c71..685e650 100644 --- a/03_source/cms_backend/src/app/api/AccessLog/detail/route.ts +++ b/03_source/cms_backend/src/app/api/AccessLog/detail/route.ts @@ -11,7 +11,7 @@ import type { NextRequest } from 'next/server'; import { STATUS, response, handleError } from 'src/utils/response'; // import { AccessLogService } from '../../../../modules/AccessLog/AccessLog.service'; -import { getAccessLogById } from 'src/app/services/AccessLog.service'; +import { getAccessLogById } from 'src/app/services/access-log.service'; // ---------------------------------------------------------------------- diff --git a/03_source/cms_backend/src/app/api/AccessLog/route.ts b/03_source/cms_backend/src/app/api/AccessLog/route.ts index d71b30c..5b12782 100644 --- a/03_source/cms_backend/src/app/api/AccessLog/route.ts +++ b/03_source/cms_backend/src/app/api/AccessLog/route.ts @@ -2,7 +2,7 @@ import type { NextRequest, NextResponse } from 'next/server'; import { STATUS, response, handleError } from 'src/utils/response'; -import { listAccessLogs } from 'src/app/services/AccessLog.service'; +import { listAccessLogs } from 'src/app/services/access-log.service'; // import prisma from '../../lib/prisma'; diff --git a/03_source/cms_backend/src/app/api/AppLog/route.ts b/03_source/cms_backend/src/app/api/AppLog/route.ts index ce22c18..8a36299 100644 --- a/03_source/cms_backend/src/app/api/AppLog/route.ts +++ b/03_source/cms_backend/src/app/api/AppLog/route.ts @@ -2,7 +2,7 @@ import type { NextRequest, NextResponse } from 'next/server'; import { STATUS, response, handleError } from 'src/utils/response'; -import { listAppLogs, deleteAppLog, createNewAppLog } from 'src/app/services/AppLog.service'; +import { listAppLogs, deleteAppLog, createNewAppLog } from 'src/app/services/app-log.service'; // import prisma from '../../lib/prisma'; diff --git a/03_source/cms_backend/src/app/api/auth/me/route.ts b/03_source/cms_backend/src/app/api/auth/me/route.ts index 18fa6b4..ce056b1 100644 --- a/03_source/cms_backend/src/app/api/auth/me/route.ts +++ b/03_source/cms_backend/src/app/api/auth/me/route.ts @@ -8,7 +8,7 @@ import { STATUS, response, handleError } from 'src/utils/response'; import { JWT_SECRET } from 'src/_mock/_auth'; import { getUserById } from 'src/app/services/user.service'; -import { createAccessLog } from 'src/app/services/AccessLog.service'; +import { createAccessLog } from 'src/app/services/access-log.service'; import { flattenNextjsRequest } from '../sign-in/flattenNextjsRequest'; diff --git a/03_source/cms_backend/src/app/api/auth/sign-in/route.ts b/03_source/cms_backend/src/app/api/auth/sign-in/route.ts index 68eaee0..66fcca1 100644 --- a/03_source/cms_backend/src/app/api/auth/sign-in/route.ts +++ b/03_source/cms_backend/src/app/api/auth/sign-in/route.ts @@ -4,7 +4,7 @@ import { sign } from 'src/utils/jwt'; import { STATUS, response, handleError } from 'src/utils/response'; import { JWT_SECRET, JWT_EXPIRES_IN } from 'src/_mock/_auth'; -import { createAccessLog } from 'src/app/services/AccessLog.service'; +import { createAccessLog } from 'src/app/services/access-log.service'; import prisma from '../../../lib/prisma'; import { flattenNextjsRequest } from './flattenNextjsRequest'; diff --git a/03_source/cms_backend/src/app/api/event/details/route.ts b/03_source/cms_backend/src/app/api/event/details/route.ts index c4db193..d552959 100644 --- a/03_source/cms_backend/src/app/api/event/details/route.ts +++ b/03_source/cms_backend/src/app/api/event/details/route.ts @@ -12,7 +12,7 @@ import { STATUS, response, handleError } from 'src/utils/response'; import { L_INFO, L_ERROR } from 'src/constants'; import { getEvent } from 'src/app/services/eventItem.service'; -import { createAppLog } from 'src/app/services/AppLog.service'; +import { createAppLog } from 'src/app/services/app-log.service'; // ---------------------------------------------------------------------- diff --git a/03_source/cms_backend/src/app/api/helloworld/detail/route.ts b/03_source/cms_backend/src/app/api/helloworld/detail/route.ts index 3ea4445..4e92da4 100644 --- a/03_source/cms_backend/src/app/api/helloworld/detail/route.ts +++ b/03_source/cms_backend/src/app/api/helloworld/detail/route.ts @@ -11,7 +11,7 @@ import type { NextRequest } from 'next/server'; import { STATUS, response, handleError } from 'src/utils/response'; import { L_INFO, L_ERROR } from 'src/constants'; -import { createAppLog } from 'src/app/services/AppLog.service'; +import { createAppLog } from 'src/app/services/app-log.service'; import prisma from '../../../lib/prisma'; import { flattenNextjsRequest } from '../../auth/sign-in/flattenNextjsRequest'; diff --git a/03_source/cms_backend/src/app/api/invoice/search/route.ts b/03_source/cms_backend/src/app/api/invoice/search/route.ts index bf77d2d..6583336 100644 --- a/03_source/cms_backend/src/app/api/invoice/search/route.ts +++ b/03_source/cms_backend/src/app/api/invoice/search/route.ts @@ -24,9 +24,7 @@ export async function GET(req: NextRequest) { const products = _products(); // Accept search by name or sku - const results = products.filter( - ({ name, sku }) => name.toLowerCase().includes(query) || sku?.toLowerCase().includes(query) - ); + const results = products.filter(({ name, sku }) => name.toLowerCase().includes(query) || sku?.toLowerCase().includes(query)); logger('[Product] search-results', results.length); diff --git a/03_source/cms_backend/src/app/api/kanban/route.ts b/03_source/cms_backend/src/app/api/kanban/route.ts index 1582e68..19b3b3e 100644 --- a/03_source/cms_backend/src/app/api/kanban/route.ts +++ b/03_source/cms_backend/src/app/api/kanban/route.ts @@ -25,13 +25,8 @@ const ENDPOINTS = { }; function loggerData(action?: string, value?: unknown) { - const columnsWithTasks = boardData.columns.map( - (col) => `${col.name} (${boardData.tasks[col.id].length} tasks)` - ); - logger( - '[Kanban] get-board', - `columns (${boardData.columns.length}): ${JSON.stringify(columnsWithTasks, null, 2)}` - ); + const columnsWithTasks = boardData.columns.map((col) => `${col.name} (${boardData.tasks[col.id].length} tasks)`); + logger('[Kanban] get-board', `columns (${boardData.columns.length}): ${JSON.stringify(columnsWithTasks, null, 2)}`); if (value || action) { logger(`[Kanban] ${action}`, value); } @@ -126,9 +121,7 @@ async function updateColumn(req: NextRequest) { // Find and update the specified column. updateBoardData({ - columns: boardData.columns.map((col) => - col.id === columnId ? { ...col, name: columnName } : col - ), + columns: boardData.columns.map((col) => (col.id === columnId ? { ...col, name: columnName } : col)), }); loggerData('updated-column', columnName); @@ -222,9 +215,7 @@ async function updateTask(req: NextRequest) { updateBoardData({ tasks: { ...boardData.tasks, - [columnId]: boardData.tasks[columnId].map((task) => - task.id === taskData.id ? { ...task, ...taskData } : task - ), + [columnId]: boardData.tasks[columnId].map((task) => (task.id === taskData.id ? { ...task, ...taskData } : task)), }, }); diff --git a/03_source/cms_backend/src/app/api/mail/list/route.ts b/03_source/cms_backend/src/app/api/mail/list/route.ts index 3c60a35..48eae43 100644 --- a/03_source/cms_backend/src/app/api/mail/list/route.ts +++ b/03_source/cms_backend/src/app/api/mail/list/route.ts @@ -31,10 +31,7 @@ export async function GET(req: NextRequest) { } // Get filtered mails - const filteredMails = - label.type === 'custom' - ? mails.filter((mail) => mail.labelIds.includes(labelId!)) - : filterMailsByLabelId(mails, labelId); + const filteredMails = label.type === 'custom' ? mails.filter((mail) => mail.labelIds.includes(labelId!)) : filterMailsByLabelId(mails, labelId); logger(`[Mail] label-[${labelId}]`, filteredMails.length); diff --git a/03_source/cms_backend/src/app/api/order/search/route.ts b/03_source/cms_backend/src/app/api/order/search/route.ts index bf77d2d..6583336 100644 --- a/03_source/cms_backend/src/app/api/order/search/route.ts +++ b/03_source/cms_backend/src/app/api/order/search/route.ts @@ -24,9 +24,7 @@ export async function GET(req: NextRequest) { const products = _products(); // Accept search by name or sku - const results = products.filter( - ({ name, sku }) => name.toLowerCase().includes(query) || sku?.toLowerCase().includes(query) - ); + const results = products.filter(({ name, sku }) => name.toLowerCase().includes(query) || sku?.toLowerCase().includes(query)); logger('[Product] search-results', results.length); diff --git a/03_source/cms_backend/src/app/api/pagination/route.ts b/03_source/cms_backend/src/app/api/pagination/route.ts index cddb195..81c0c6c 100644 --- a/03_source/cms_backend/src/app/api/pagination/route.ts +++ b/03_source/cms_backend/src/app/api/pagination/route.ts @@ -47,9 +47,7 @@ export async function GET(req: NextRequest) { products: paginatedProducts, totalPages, totalItems, - categoryOptions: Array.from( - new Set(_products.map(({ category: c_category }) => c_category)) - ), // Remove duplicate categories + categoryOptions: Array.from(new Set(_products.map(({ category: c_category }) => c_category))), // Remove duplicate categories }, STATUS.OK ); @@ -70,9 +68,7 @@ function paginateProducts(products: Products, page: number, perPage: number) { function filterProducts(products: Products, searchQuery: string, category: string) { return products.filter(({ id, name, category: prodCategory }) => { // Accept search by id or name - const matchesSearch = searchQuery - ? id.includes(searchQuery) || name.toLowerCase().includes(searchQuery) - : true; + const matchesSearch = searchQuery ? id.includes(searchQuery) || name.toLowerCase().includes(searchQuery) : true; const matchesCategory = category ? prodCategory === category : true; return matchesSearch && matchesCategory; diff --git a/03_source/cms_backend/src/app/api/post/search/route.ts b/03_source/cms_backend/src/app/api/post/search/route.ts index fdd8c12..c638f22 100644 --- a/03_source/cms_backend/src/app/api/post/search/route.ts +++ b/03_source/cms_backend/src/app/api/post/search/route.ts @@ -24,10 +24,7 @@ export async function GET(req: NextRequest) { const posts = _posts(); // Accept search by title or description - const results = posts.filter( - ({ title, description }) => - title.toLowerCase().includes(query) || description?.toLowerCase().includes(query) - ); + const results = posts.filter(({ title, description }) => title.toLowerCase().includes(query) || description?.toLowerCase().includes(query)); logger('[Post] search-results', results.length); diff --git a/03_source/cms_backend/src/app/api/product/create/route.ts b/03_source/cms_backend/src/app/api/product/create/route.ts index 9fc848e..d5bf269 100644 --- a/03_source/cms_backend/src/app/api/product/create/route.ts +++ b/03_source/cms_backend/src/app/api/product/create/route.ts @@ -15,6 +15,8 @@ import { STATUS, response, handleError } from 'src/utils/response'; import { isDev } from 'src/constants'; import prisma from '../../../lib/prisma'; +import { createProduct } from 'src/app/services/product.service'; +// import { createProduct } from 'src/app/services/product.service'; // ---------------------------------------------------------------------- @@ -29,13 +31,14 @@ export async function POST(req: NextRequest) { console.log({ productData }); } - await prisma.productItem.create({ data: productData }); + const created = await createProduct(productData); + // const created = await prisma.productItem.create({ data: productData }); if (isDev) { console.log('create done'); } - return response({ hello: 'world' }, STATUS.OK); + return response(created, STATUS.OK); } catch (error) { console.log({ hello: 'world', productData }); return handleError('Product - Create', error); diff --git a/03_source/cms_backend/src/app/api/product/create/test.http b/03_source/cms_backend/src/app/api/product/create/test.http index 46163ae..75193b4 100644 --- a/03_source/cms_backend/src/app/api/product/create/test.http +++ b/03_source/cms_backend/src/app/api/product/create/test.http @@ -1,10 +1,10 @@ ### -POST http://localhost:7272/api/product/createProduct +POST http://localhost:7272/api/product/create Content-Type: application/json { - "data": { + "productData": { "available": 99, "category": "T-shirts", "code": "PD-12345", diff --git a/03_source/cms_backend/src/app/api/product/details/route.ts b/03_source/cms_backend/src/app/api/product/details/route.ts index a5f4158..f577d7b 100644 --- a/03_source/cms_backend/src/app/api/product/details/route.ts +++ b/03_source/cms_backend/src/app/api/product/details/route.ts @@ -15,7 +15,7 @@ import { STATUS, response, handleError } from 'src/utils/response'; import { L_INFO, L_ERROR } from 'src/constants'; import { getProduct } from 'src/app/services/product.service'; -import { createAppLog } from 'src/app/services/AppLog.service'; +import { createAppLog } from 'src/app/services/app-log.service'; import { flattenNextjsRequest } from '../../auth/sign-in/flattenNextjsRequest'; diff --git a/03_source/cms_backend/src/app/api/product/list/route.ts b/03_source/cms_backend/src/app/api/product/list/route.ts index 5e553df..13cad72 100644 --- a/03_source/cms_backend/src/app/api/product/list/route.ts +++ b/03_source/cms_backend/src/app/api/product/list/route.ts @@ -11,7 +11,7 @@ import type { NextRequest } from 'next/server'; import { STATUS, response, handleError } from 'src/utils/response'; import { L_INFO, L_ERROR } from 'src/constants'; -import { createAppLog } from 'src/app/services/AppLog.service'; +import { createAppLog } from 'src/app/services/app-log.service'; import { listProducts } from 'src/app/services/product.service'; import { flattenNextjsRequest } from '../../auth/sign-in/flattenNextjsRequest'; diff --git a/03_source/cms_backend/src/app/api/user/changeToAdmin/route.ts b/03_source/cms_backend/src/app/api/user/changeToAdmin/route.ts index 7157583..43817e4 100644 --- a/03_source/cms_backend/src/app/api/user/changeToAdmin/route.ts +++ b/03_source/cms_backend/src/app/api/user/changeToAdmin/route.ts @@ -4,7 +4,7 @@ import type { NextRequest } from 'next/server'; import { STATUS, response, handleError } from 'src/utils/response'; -import { changeToAdmin } from 'src/app/services/userItem.service'; +import { changeToAdmin } from 'src/app/services/user-item.service'; /** *************************************** diff --git a/03_source/cms_backend/src/app/api/user/changeToUser/route.ts b/03_source/cms_backend/src/app/api/user/changeToUser/route.ts index 4191a4d..2298ee5 100644 --- a/03_source/cms_backend/src/app/api/user/changeToUser/route.ts +++ b/03_source/cms_backend/src/app/api/user/changeToUser/route.ts @@ -4,7 +4,7 @@ import type { NextRequest } from 'next/server'; import { STATUS, response, handleError } from 'src/utils/response'; -import { changeToUser } from 'src/app/services/userItem.service'; +import { changeToUser } from 'src/app/services/user-item.service'; /** *************************************** diff --git a/03_source/cms_backend/src/app/api/user/checkAdmin/route.ts b/03_source/cms_backend/src/app/api/user/checkAdmin/route.ts index 1e49d8b..04fb686 100644 --- a/03_source/cms_backend/src/app/api/user/checkAdmin/route.ts +++ b/03_source/cms_backend/src/app/api/user/checkAdmin/route.ts @@ -2,7 +2,7 @@ import type { NextRequest, NextResponse } from 'next/server'; import { STATUS, response, handleError } from 'src/utils/response'; -import { isAdmin } from 'src/app/services/userItem.service'; +import { isAdmin } from 'src/app/services/user-item.service'; // import prisma from '../../lib/prisma'; diff --git a/03_source/cms_backend/src/app/api/user/helloworld/route.ts b/03_source/cms_backend/src/app/api/user/helloworld/route.ts index 0a30567..1a7f12b 100644 --- a/03_source/cms_backend/src/app/api/user/helloworld/route.ts +++ b/03_source/cms_backend/src/app/api/user/helloworld/route.ts @@ -2,7 +2,7 @@ import type { NextRequest, NextResponse } from 'next/server'; import { STATUS, response, handleError } from 'src/utils/response'; -import { isAdmin } from 'src/app/services/userItem.service'; +import { isAdmin } from 'src/app/services/user-item.service'; // import prisma from '../../lib/prisma'; diff --git a/03_source/cms_backend/src/app/api/user/list/route.ts b/03_source/cms_backend/src/app/api/user/list/route.ts index 9324e74..599bff2 100644 --- a/03_source/cms_backend/src/app/api/user/list/route.ts +++ b/03_source/cms_backend/src/app/api/user/list/route.ts @@ -3,7 +3,7 @@ import { logger } from 'src/utils/logger'; import { STATUS, response, handleError } from 'src/utils/response'; -import { listUsers } from 'src/app/services/userItem.service'; +import { listUsers } from 'src/app/services/user-item.service'; // ---------------------------------------------------------------------- diff --git a/03_source/cms_backend/src/app/api/user/route.ts b/03_source/cms_backend/src/app/api/user/route.ts index cc88f52..08ac8b4 100644 --- a/03_source/cms_backend/src/app/api/user/route.ts +++ b/03_source/cms_backend/src/app/api/user/route.ts @@ -2,7 +2,7 @@ import type { NextRequest, NextResponse } from 'next/server'; import { STATUS, response, handleError } from 'src/utils/response'; -import { listUsers, deleteUser, updateUser, createNewUser } from 'src/app/services/userItem.service'; +import { listUsers, deleteUser, updateUser, createNewUser } from 'src/app/services/user-item.service'; // import prisma from '../../lib/prisma'; diff --git a/03_source/cms_backend/src/app/api/user/search/route.ts b/03_source/cms_backend/src/app/api/user/search/route.ts index bf77d2d..6583336 100644 --- a/03_source/cms_backend/src/app/api/user/search/route.ts +++ b/03_source/cms_backend/src/app/api/user/search/route.ts @@ -24,9 +24,7 @@ export async function GET(req: NextRequest) { const products = _products(); // Accept search by name or sku - const results = products.filter( - ({ name, sku }) => name.toLowerCase().includes(query) || sku?.toLowerCase().includes(query) - ); + const results = products.filter(({ name, sku }) => name.toLowerCase().includes(query) || sku?.toLowerCase().includes(query)); logger('[Product] search-results', results.length); diff --git a/03_source/cms_backend/src/app/services/AccessLog.service.ts b/03_source/cms_backend/src/app/services/access-log.service.ts similarity index 100% rename from 03_source/cms_backend/src/app/services/AccessLog.service.ts rename to 03_source/cms_backend/src/app/services/access-log.service.ts diff --git a/03_source/cms_backend/src/app/services/AppLog.service.ts b/03_source/cms_backend/src/app/services/app-log.service.ts similarity index 100% rename from 03_source/cms_backend/src/app/services/AppLog.service.ts rename to 03_source/cms_backend/src/app/services/app-log.service.ts diff --git a/03_source/cms_backend/src/app/services/product.service.ts b/03_source/cms_backend/src/app/services/product.service.ts index fccf049..d69f1a0 100644 --- a/03_source/cms_backend/src/app/services/product.service.ts +++ b/03_source/cms_backend/src/app/services/product.service.ts @@ -82,32 +82,8 @@ async function getProduct(productId: string): Promise { }); } -async function createProduct(createForm: CreateProduct) { - // return prisma.productItem.create({ - // data: { - // ...createForm, - // code: createForm.code || '', - // taxes: createForm.taxes || 0, - // tags: createForm.tags || [], - // sizes: createForm.sizes || [], - // gender: createForm.gender || [], - // colors: createForm.colors || [], - // category: createForm.category || '', - // quantity: createForm.quantity || 0, - // available: createForm.available || 0, - // coverUrl: createForm.coverUrl || '', - // images: createForm.images || [], - // description: createForm.description || '', - // subDescription: createForm.subDescription || '', - // publish: createForm.publish || 'published', - // totalSold: createForm.totalSold || 0, - // totalRatings: createForm.totalRatings || 0, - // totalReviews: createForm.totalReviews || 0, - // inventoryType: createForm.inventoryType || '', - // ratings: createForm.ratings || [], - // reviews: createForm.reviews || [], - // }, - // }); +async function createProduct(productData: any) { + return await prisma.productItem.create({ data: productData }); } async function updateProduct(productId: string, updateForm: UpdateProduct) { diff --git a/03_source/cms_backend/src/app/services/userItem.service.ts b/03_source/cms_backend/src/app/services/user-item.service.ts similarity index 100% rename from 03_source/cms_backend/src/app/services/userItem.service.ts rename to 03_source/cms_backend/src/app/services/user-item.service.ts diff --git a/03_source/cms_backend/src/global-config.ts b/03_source/cms_backend/src/global-config.ts index 9a382ef..6f2318f 100644 --- a/03_source/cms_backend/src/global-config.ts +++ b/03_source/cms_backend/src/global-config.ts @@ -13,8 +13,7 @@ type ConfigType = { export const CONFIG: ConfigType = { appVersion: packageJson.version, - basePath: - process.env.NODE_ENV === 'production' ? process.env.PRODUCTION_API : process.env.DEV_API, + basePath: process.env.NODE_ENV === 'production' ? process.env.PRODUCTION_API : process.env.DEV_API, cors: { /** * [] = allow all origins diff --git a/03_source/cms_backend/src/utils/hash.ts b/03_source/cms_backend/src/utils/hash.ts index 36f3210..5639aae 100644 --- a/03_source/cms_backend/src/utils/hash.ts +++ b/03_source/cms_backend/src/utils/hash.ts @@ -2,7 +2,6 @@ import bcrypt from 'bcrypt'; const generateHash = async (password: string) => bcrypt.hash(password, await bcrypt.genSalt(10)); -const validatePassword = async (password: string, hash: string) => - bcrypt.compare(password, hash as string); +const validatePassword = async (password: string, hash: string) => bcrypt.compare(password, hash as string); export { generateHash, validatePassword }; diff --git a/03_source/cms_backend/src/utils/logger.ts b/03_source/cms_backend/src/utils/logger.ts index 1b0ec0e..9f7d684 100644 --- a/03_source/cms_backend/src/utils/logger.ts +++ b/03_source/cms_backend/src/utils/logger.ts @@ -40,11 +40,7 @@ export function logger(label: string, value: unknown, breakLine: boolean = false if (value === null || value === undefined) { formattedValue = String(value); } else if (type === 'object') { - formattedValue = JSON.stringify( - value, - null, - breakLine || JSON.stringify(value).length > 50 ? 2 : 0 - ); + formattedValue = JSON.stringify(value, null, breakLine || JSON.stringify(value).length > 50 ? 2 : 0); } else { formattedValue = String(value); } diff --git a/03_source/cms_backend/src/utils/set-date.ts b/03_source/cms_backend/src/utils/set-date.ts index deac87d..0933d94 100644 --- a/03_source/cms_backend/src/utils/set-date.ts +++ b/03_source/cms_backend/src/utils/set-date.ts @@ -15,10 +15,8 @@ export function setDate(now: Date, options: { days?: number; hours?: number; min return new Date(`${year}-${month}-${days ?? today} ${hours}:${minutes}`).toJSON(); } -export const subHours = ( - value: number, - option: 'years' | 'months' | 'days' | 'hours' | 'minutes' | 'seconds' | 'milliseconds' -) => dayjs().subtract(value, option).format(); +export const subHours = (value: number, option: 'years' | 'months' | 'days' | 'hours' | 'minutes' | 'seconds' | 'milliseconds') => + dayjs().subtract(value, option).format(); // years, // months, @@ -38,15 +36,7 @@ export type DurationProps = { milliseconds?: number; }; -export function fSub({ - years = 0, - months = 0, - days = 0, - hours = 0, - minutes = 0, - seconds = 0, - milliseconds = 0, -}: DurationProps) { +export function fSub({ years = 0, months = 0, days = 0, hours = 0, minutes = 0, seconds = 0, milliseconds = 0 }: DurationProps) { const result = dayjs() .subtract( dayjs.duration({ @@ -64,15 +54,7 @@ export function fSub({ return result; } -export function fAdd({ - years = 0, - months = 0, - days = 0, - hours = 0, - minutes = 0, - seconds = 0, - milliseconds = 0, -}: DurationProps) { +export function fAdd({ years = 0, months = 0, days = 0, hours = 0, minutes = 0, seconds = 0, milliseconds = 0 }: DurationProps) { const result = dayjs() .add( dayjs.duration({ diff --git a/03_source/frontend/package.json b/03_source/frontend/package.json index 817c36b..960f62c 100644 --- a/03_source/frontend/package.json +++ b/03_source/frontend/package.json @@ -21,8 +21,10 @@ "re:build": "yarn clean && yarn install && yarn build", "re:build-npm": "npm run clean && npm install && npm run build", "tsc:dev": "yarn dev & yarn tsc:watch", - "tsc:w": "tsc --noEmit --watch", - "tsc:print": "npx tsc --showConfig" + "tsc:print": "npx tsc --showConfig", + "tsc:w": "npx nodemon --delay 3 --ext ts,tsx --exec \"yarn tsc\"", + "tsc:watch": "tsc --noEmit --watch", + "tsc": "tsc --noEmit" }, "engines": { "node": ">=20" diff --git a/03_source/frontend/scripts/10_build.sh b/03_source/frontend/scripts/10_build.sh index b8eb8c0..4257cc6 100755 --- a/03_source/frontend/scripts/10_build.sh +++ b/03_source/frontend/scripts/10_build.sh @@ -1,3 +1,13 @@ #!/usr/bin/env bash +set -x + +rm -rf ./**/*Zone.Identifier + +set -ex + +yarn fm:fix + +yarn tsc + yarn build diff --git a/03_source/frontend/src/_mock/_calendar.ts b/03_source/frontend/src/_mock/_calendar.ts index 284ea28..bc0ef55 100644 --- a/03_source/frontend/src/_mock/_calendar.ts +++ b/03_source/frontend/src/_mock/_calendar.ts @@ -1,4 +1,4 @@ -import { info, error, primary, success, warning, secondary } from 'src/theme/core'; +import { error, info, primary, secondary, success, warning } from 'src/theme/core'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/_mock/_files.ts b/03_source/frontend/src/_mock/_files.ts index a17efbe..44eda1f 100644 --- a/03_source/frontend/src/_mock/_files.ts +++ b/03_source/frontend/src/_mock/_files.ts @@ -1,5 +1,5 @@ import { _mock } from './_mock'; -import { _tags, _fileNames } from './assets'; +import { _fileNames, _tags } from './assets'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/_mock/_invoice.ts b/03_source/frontend/src/_mock/_invoice.ts index 0df00b7..8a16743 100644 --- a/03_source/frontend/src/_mock/_invoice.ts +++ b/03_source/frontend/src/_mock/_invoice.ts @@ -1,8 +1,7 @@ -import { fSub, fAdd } from 'src/utils/format-time'; - +import { fAdd, fSub } from 'src/utils/format-time'; import { _mock } from './_mock'; -import { _tags } from './assets'; import { _addressBooks } from './_others'; +import { _tags } from './assets'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/_mock/_mock.ts b/03_source/frontend/src/_mock/_mock.ts index 90651cd..8eb2ab7 100644 --- a/03_source/frontend/src/_mock/_mock.ts +++ b/03_source/frontend/src/_mock/_mock.ts @@ -1,36 +1,34 @@ -import { fSub } from 'src/utils/format-time'; - import { CONFIG } from 'src/global-config'; - +import { fSub } from 'src/utils/format-time'; import { - _id, _ages, - _roles, - _prices, - _emails, - _ratings, - _nativeS, - _nativeM, - _nativeL, - _percents, _booleans, - _sentences, - _lastNames, - _fullNames, - _tourNames, - _jobTitles, - _taskNames, - _fileNames, - _postTitles, - _firstNames, - _eventNames, - _courseNames, - _fullAddress, _companyNames, - _productNames, - _descriptions, - _phoneNumbers, _countryNames, + _courseNames, + _descriptions, + _emails, + _eventNames, + _fileNames, + _firstNames, + _fullAddress, + _fullNames, + _id, + _jobTitles, + _lastNames, + _nativeL, + _nativeM, + _nativeS, + _percents, + _phoneNumbers, + _postTitles, + _prices, + _productNames, + _ratings, + _roles, + _sentences, + _taskNames, + _tourNames, } from './assets'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/_mock/_overview.ts b/03_source/frontend/src/_mock/_overview.ts index b350739..6c30499 100644 --- a/03_source/frontend/src/_mock/_overview.ts +++ b/03_source/frontend/src/_mock/_overview.ts @@ -1,7 +1,5 @@ -import { today } from 'src/utils/format-time'; - import { CONFIG } from 'src/global-config'; - +import { today } from 'src/utils/format-time'; import { _mock } from './_mock'; // APP diff --git a/03_source/frontend/src/actions/product.ts b/03_source/frontend/src/actions/product.ts index e818325..364fdd1 100644 --- a/03_source/frontend/src/actions/product.ts +++ b/03_source/frontend/src/actions/product.ts @@ -1,4 +1,3 @@ -// // src/actions/product.ts // import { useMemo } from 'react'; diff --git a/03_source/frontend/src/assets/icons/plan-starter-icon.tsx b/03_source/frontend/src/assets/icons/plan-starter-icon.tsx index d043e6a..853b01e 100644 --- a/03_source/frontend/src/assets/icons/plan-starter-icon.tsx +++ b/03_source/frontend/src/assets/icons/plan-starter-icon.tsx @@ -1,8 +1,6 @@ import type { SvgIconProps } from '@mui/material/SvgIcon'; - -import { memo } from 'react'; - import SvgIcon from '@mui/material/SvgIcon'; +import { memo } from 'react'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/assets/illustrations/server-error-illustration.tsx b/03_source/frontend/src/assets/illustrations/server-error-illustration.tsx index 47ae103..932d052 100644 --- a/03_source/frontend/src/assets/illustrations/server-error-illustration.tsx +++ b/03_source/frontend/src/assets/illustrations/server-error-illustration.tsx @@ -1,11 +1,7 @@ import type { SvgIconProps } from '@mui/material/SvgIcon'; - -import { memo } from 'react'; - import SvgIcon from '@mui/material/SvgIcon'; - +import { memo } from 'react'; import { CONFIG } from 'src/global-config'; - import { BackgroundShape } from './background-shape'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/components/form-divider.tsx b/03_source/frontend/src/auth/components/form-divider.tsx index 1b2ddc1..28adf45 100644 --- a/03_source/frontend/src/auth/components/form-divider.tsx +++ b/03_source/frontend/src/auth/components/form-divider.tsx @@ -1,6 +1,5 @@ -import type { Theme, SxProps } from '@mui/material/styles'; - import Divider from '@mui/material/Divider'; +import type { SxProps, Theme } from '@mui/material/styles'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/components/form-head.tsx b/03_source/frontend/src/auth/components/form-head.tsx index 3eea302..24f5e68 100644 --- a/03_source/frontend/src/auth/components/form-head.tsx +++ b/03_source/frontend/src/auth/components/form-head.tsx @@ -1,5 +1,4 @@ import type { BoxProps } from '@mui/material/Box'; - import Box from '@mui/material/Box'; import Typography from '@mui/material/Typography'; diff --git a/03_source/frontend/src/auth/components/form-resend-code.tsx b/03_source/frontend/src/auth/components/form-resend-code.tsx index c2f3ce9..eb1edc5 100644 --- a/03_source/frontend/src/auth/components/form-resend-code.tsx +++ b/03_source/frontend/src/auth/components/form-resend-code.tsx @@ -1,5 +1,4 @@ import type { BoxProps } from '@mui/material/Box'; - import Box from '@mui/material/Box'; import Link from '@mui/material/Link'; diff --git a/03_source/frontend/src/auth/components/form-return-link.tsx b/03_source/frontend/src/auth/components/form-return-link.tsx index 23065e6..4149d49 100644 --- a/03_source/frontend/src/auth/components/form-return-link.tsx +++ b/03_source/frontend/src/auth/components/form-return-link.tsx @@ -1,10 +1,7 @@ import type { LinkProps } from '@mui/material/Link'; - import Link from '@mui/material/Link'; - -import { RouterLink } from 'src/routes/components'; - import { Iconify } from 'src/components/iconify'; +import { RouterLink } from 'src/routes/components'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/components/form-socials.tsx b/03_source/frontend/src/auth/components/form-socials.tsx index 756e960..74ac5c7 100644 --- a/03_source/frontend/src/auth/components/form-socials.tsx +++ b/03_source/frontend/src/auth/components/form-socials.tsx @@ -1,8 +1,6 @@ import type { BoxProps } from '@mui/material/Box'; - import Box from '@mui/material/Box'; import IconButton from '@mui/material/IconButton'; - import { Iconify } from 'src/components/iconify'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/components/sign-up-terms.tsx b/03_source/frontend/src/auth/components/sign-up-terms.tsx index 0c3e749..3cd8894 100644 --- a/03_source/frontend/src/auth/components/sign-up-terms.tsx +++ b/03_source/frontend/src/auth/components/sign-up-terms.tsx @@ -1,5 +1,4 @@ import type { BoxProps } from '@mui/material/Box'; - import Box from '@mui/material/Box'; import Link from '@mui/material/Link'; diff --git a/03_source/frontend/src/auth/context/amplify/action.tsx b/03_source/frontend/src/auth/context/amplify/action.tsx index 4125194..b39e9e0 100644 --- a/03_source/frontend/src/auth/context/amplify/action.tsx +++ b/03_source/frontend/src/auth/context/amplify/action.tsx @@ -1,20 +1,19 @@ import type { - SignUpInput, - SignInInput, - ConfirmSignUpInput, - ResetPasswordInput, - ResendSignUpCodeInput, ConfirmResetPasswordInput, + ConfirmSignUpInput, + ResendSignUpCodeInput, + ResetPasswordInput, + SignInInput, + SignUpInput, } from 'aws-amplify/auth'; - import { - signIn as _signIn, - signUp as _signUp, - signOut as _signOut, - confirmSignUp as _confirmSignUp, - resetPassword as _resetPassword, - resendSignUpCode as _resendSignUpCode, confirmResetPassword as _confirmResetPassword, + confirmSignUp as _confirmSignUp, + resendSignUpCode as _resendSignUpCode, + resetPassword as _resetPassword, + signIn as _signIn, + signOut as _signOut, + signUp as _signUp, } from 'aws-amplify/auth'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/context/amplify/auth-provider.tsx b/03_source/frontend/src/auth/context/amplify/auth-provider.tsx index 8ae0df6..a7a599a 100644 --- a/03_source/frontend/src/auth/context/amplify/auth-provider.tsx +++ b/03_source/frontend/src/auth/context/amplify/auth-provider.tsx @@ -1,14 +1,11 @@ import { Amplify } from 'aws-amplify'; -import { useSetState } from 'minimal-shared/hooks'; -import { useMemo, useEffect, useCallback } from 'react'; import { fetchAuthSession, fetchUserAttributes } from 'aws-amplify/auth'; - -import axios from 'src/lib/axios'; +import { useSetState } from 'minimal-shared/hooks'; +import { useCallback, useEffect, useMemo } from 'react'; import { CONFIG } from 'src/global-config'; - -import { AuthContext } from '../auth-context'; - +import axios from 'src/lib/axios'; import type { AuthState } from '../../types'; +import { AuthContext } from '../auth-context'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/context/auth-context.tsx b/03_source/frontend/src/auth/context/auth-context.tsx index 52b8e90..42d7f65 100644 --- a/03_source/frontend/src/auth/context/auth-context.tsx +++ b/03_source/frontend/src/auth/context/auth-context.tsx @@ -1,5 +1,4 @@ import { createContext } from 'react'; - import type { AuthContextValue } from '../types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/context/auth0/auth-provider.tsx b/03_source/frontend/src/auth/context/auth0/auth-provider.tsx index b9adf16..d485810 100644 --- a/03_source/frontend/src/auth/context/auth0/auth-provider.tsx +++ b/03_source/frontend/src/auth/context/auth0/auth-provider.tsx @@ -1,11 +1,8 @@ import type { AppState } from '@auth0/auth0-react'; - -import { useAuth0, Auth0Provider } from '@auth0/auth0-react'; -import { useMemo, useState, useEffect, useCallback } from 'react'; - -import axios from 'src/lib/axios'; +import { Auth0Provider, useAuth0 } from '@auth0/auth0-react'; +import { useCallback, useEffect, useMemo, useState } from 'react'; import { CONFIG } from 'src/global-config'; - +import axios from 'src/lib/axios'; import { AuthContext } from '../auth-context'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/context/firebase/action.ts b/03_source/frontend/src/auth/context/firebase/action.ts index fea61dc..3c7fbef 100644 --- a/03_source/frontend/src/auth/context/firebase/action.ts +++ b/03_source/frontend/src/auth/context/firebase/action.ts @@ -1,16 +1,15 @@ -import { doc, setDoc, collection } from 'firebase/firestore'; import { - signOut as _signOut, - signInWithPopup as _signInWithPopup, - GoogleAuthProvider as _GoogleAuthProvider, + createUserWithEmailAndPassword as _createUserWithEmailAndPassword, GithubAuthProvider as _GithubAuthProvider, - TwitterAuthProvider as _TwitterAuthProvider, + GoogleAuthProvider as _GoogleAuthProvider, sendEmailVerification as _sendEmailVerification, sendPasswordResetEmail as _sendPasswordResetEmail, signInWithEmailAndPassword as _signInWithEmailAndPassword, - createUserWithEmailAndPassword as _createUserWithEmailAndPassword, + signInWithPopup as _signInWithPopup, + signOut as _signOut, + TwitterAuthProvider as _TwitterAuthProvider, } from 'firebase/auth'; - +import { collection, doc, setDoc } from 'firebase/firestore'; import { AUTH, FIRESTORE } from 'src/lib/firebase'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/context/firebase/auth-provider.tsx b/03_source/frontend/src/auth/context/firebase/auth-provider.tsx index ea7204e..be0783c 100644 --- a/03_source/frontend/src/auth/context/firebase/auth-provider.tsx +++ b/03_source/frontend/src/auth/context/firebase/auth-provider.tsx @@ -1,14 +1,11 @@ -import { doc, getDoc } from 'firebase/firestore'; import { onAuthStateChanged } from 'firebase/auth'; +import { doc, getDoc } from 'firebase/firestore'; import { useSetState } from 'minimal-shared/hooks'; -import { useMemo, useEffect, useCallback } from 'react'; - +import { useCallback, useEffect, useMemo } from 'react'; import axios from 'src/lib/axios'; import { AUTH, FIRESTORE } from 'src/lib/firebase'; - -import { AuthContext } from '../auth-context'; - import type { AuthState } from '../../types'; +import { AuthContext } from '../auth-context'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/context/jwt/action.ts b/03_source/frontend/src/auth/context/jwt/action.ts index 7a8491e..aea67b9 100644 --- a/03_source/frontend/src/auth/context/jwt/action.ts +++ b/03_source/frontend/src/auth/context/jwt/action.ts @@ -1,7 +1,6 @@ import axios, { endpoints } from 'src/lib/axios'; - -import { setSession } from './utils'; import { JWT_STORAGE_KEY } from './constant'; +import { setSession } from './utils'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/context/jwt/auth-provider.tsx b/03_source/frontend/src/auth/context/jwt/auth-provider.tsx index b803981..b386e57 100644 --- a/03_source/frontend/src/auth/context/jwt/auth-provider.tsx +++ b/03_source/frontend/src/auth/context/jwt/auth-provider.tsx @@ -1,13 +1,10 @@ import { useSetState } from 'minimal-shared/hooks'; -import { useMemo, useEffect, useCallback } from 'react'; - +import { useCallback, useEffect, useMemo } from 'react'; import axios, { endpoints } from 'src/lib/axios'; - -import { JWT_STORAGE_KEY } from './constant'; -import { AuthContext } from '../auth-context'; -import { setSession, isValidToken } from './utils'; - import type { AuthState } from '../../types'; +import { AuthContext } from '../auth-context'; +import { JWT_STORAGE_KEY } from './constant'; +import { isValidToken, setSession } from './utils'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/context/jwt/utils.ts b/03_source/frontend/src/auth/context/jwt/utils.ts index 9c71ea5..2e9f335 100644 --- a/03_source/frontend/src/auth/context/jwt/utils.ts +++ b/03_source/frontend/src/auth/context/jwt/utils.ts @@ -1,7 +1,5 @@ -import { paths } from 'src/routes/paths'; - import axios from 'src/lib/axios'; - +import { paths } from 'src/routes/paths'; import { JWT_STORAGE_KEY } from './constant'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/context/supabase/action.tsx b/03_source/frontend/src/auth/context/supabase/action.tsx index db590e9..8117da1 100644 --- a/03_source/frontend/src/auth/context/supabase/action.tsx +++ b/03_source/frontend/src/auth/context/supabase/action.tsx @@ -1,15 +1,13 @@ import type { AuthError, AuthResponse, - UserResponse, AuthTokenResponsePassword, SignInWithPasswordCredentials, SignUpWithPasswordCredentials, + UserResponse, } from '@supabase/supabase-js'; - -import { paths } from 'src/routes/paths'; - import { supabase } from 'src/lib/supabase'; +import { paths } from 'src/routes/paths'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/context/supabase/auth-provider.tsx b/03_source/frontend/src/auth/context/supabase/auth-provider.tsx index dd09871..2079636 100644 --- a/03_source/frontend/src/auth/context/supabase/auth-provider.tsx +++ b/03_source/frontend/src/auth/context/supabase/auth-provider.tsx @@ -1,12 +1,9 @@ import { useSetState } from 'minimal-shared/hooks'; -import { useMemo, useEffect, useCallback } from 'react'; - +import { useCallback, useEffect, useMemo } from 'react'; import axios from 'src/lib/axios'; import { supabase } from 'src/lib/supabase'; - -import { AuthContext } from '../auth-context'; - import type { AuthState } from '../../types'; +import { AuthContext } from '../auth-context'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/guard/auth-guard.tsx b/03_source/frontend/src/auth/guard/auth-guard.tsx index a625d50..6db8a05 100644 --- a/03_source/frontend/src/auth/guard/auth-guard.tsx +++ b/03_source/frontend/src/auth/guard/auth-guard.tsx @@ -1,12 +1,8 @@ -import { useState, useEffect } from 'react'; - -import { paths } from 'src/routes/paths'; -import { useRouter, usePathname } from 'src/routes/hooks'; - -import { CONFIG } from 'src/global-config'; - +import { useEffect, useState } from 'react'; import { SplashScreen } from 'src/components/loading-screen'; - +import { CONFIG } from 'src/global-config'; +import { usePathname, useRouter } from 'src/routes/hooks'; +import { paths } from 'src/routes/paths'; import { useAuthContext } from '../hooks'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/guard/guest-guard.tsx b/03_source/frontend/src/auth/guard/guest-guard.tsx index 1da5f44..a7ea6ad 100644 --- a/03_source/frontend/src/auth/guard/guest-guard.tsx +++ b/03_source/frontend/src/auth/guard/guest-guard.tsx @@ -1,11 +1,7 @@ -import { useState, useEffect } from 'react'; - -import { useSearchParams } from 'src/routes/hooks'; - -import { CONFIG } from 'src/global-config'; - +import { useEffect, useState } from 'react'; import { SplashScreen } from 'src/components/loading-screen'; - +import { CONFIG } from 'src/global-config'; +import { useSearchParams } from 'src/routes/hooks'; import { useAuthContext } from '../hooks'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/guard/role-based-guard.tsx b/03_source/frontend/src/auth/guard/role-based-guard.tsx index d9ea6b7..c0c3d48 100644 --- a/03_source/frontend/src/auth/guard/role-based-guard.tsx +++ b/03_source/frontend/src/auth/guard/role-based-guard.tsx @@ -1,13 +1,9 @@ -import type { Theme, SxProps } from '@mui/material/styles'; - -import { m } from 'framer-motion'; - import Container from '@mui/material/Container'; +import type { SxProps, Theme } from '@mui/material/styles'; import Typography from '@mui/material/Typography'; - +import { m } from 'framer-motion'; import { ForbiddenIllustration } from 'src/assets/illustrations'; - -import { varBounce, MotionContainer } from 'src/components/animate'; +import { MotionContainer, varBounce } from 'src/components/animate'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/hooks/use-auth-context.ts b/03_source/frontend/src/auth/hooks/use-auth-context.ts index 0816ff2..6ac50fa 100644 --- a/03_source/frontend/src/auth/hooks/use-auth-context.ts +++ b/03_source/frontend/src/auth/hooks/use-auth-context.ts @@ -1,5 +1,4 @@ import { use } from 'react'; - import { AuthContext } from '../context/auth-context'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/view/amplify/amplify-reset-password-view.tsx b/03_source/frontend/src/auth/view/amplify/amplify-reset-password-view.tsx index 802b3bf..d236321 100644 --- a/03_source/frontend/src/auth/view/amplify/amplify-reset-password-view.tsx +++ b/03_source/frontend/src/auth/view/amplify/amplify-reset-password-view.tsx @@ -1,20 +1,15 @@ -import { z as zod } from 'zod'; -import { useForm } from 'react-hook-form'; import { zodResolver } from '@hookform/resolvers/zod'; - import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; - -import { paths } from 'src/routes/paths'; -import { useRouter } from 'src/routes/hooks'; - +import { useForm } from 'react-hook-form'; import { PasswordIcon } from 'src/assets/icons'; - -import { Form, Field } from 'src/components/hook-form'; - -import { resetPassword } from '../../context/amplify'; +import { Field, Form } from 'src/components/hook-form'; +import { useRouter } from 'src/routes/hooks'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; import { FormHead } from '../../components/form-head'; import { FormReturnLink } from '../../components/form-return-link'; +import { resetPassword } from '../../context/amplify'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/view/amplify/amplify-sign-in-view.tsx b/03_source/frontend/src/auth/view/amplify/amplify-sign-in-view.tsx index 450113e..bdc687f 100644 --- a/03_source/frontend/src/auth/view/amplify/amplify-sign-in-view.tsx +++ b/03_source/frontend/src/auth/view/amplify/amplify-sign-in-view.tsx @@ -1,27 +1,23 @@ -import { z as zod } from 'zod'; -import { useState } from 'react'; -import { useForm } from 'react-hook-form'; -import { useBoolean } from 'minimal-shared/hooks'; import { zodResolver } from '@hookform/resolvers/zod'; - -import Box from '@mui/material/Box'; -import Link from '@mui/material/Link'; import Alert from '@mui/material/Alert'; +import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; import IconButton from '@mui/material/IconButton'; import InputAdornment from '@mui/material/InputAdornment'; - -import { paths } from 'src/routes/paths'; -import { useRouter } from 'src/routes/hooks'; -import { RouterLink } from 'src/routes/components'; - +import Link from '@mui/material/Link'; +import { useBoolean } from 'minimal-shared/hooks'; +import { useState } from 'react'; +import { useForm } from 'react-hook-form'; +import { Field, Form } from 'src/components/hook-form'; import { Iconify } from 'src/components/iconify'; -import { Form, Field } from 'src/components/hook-form'; - -import { useAuthContext } from '../../hooks'; -import { getErrorMessage } from '../../utils'; +import { RouterLink } from 'src/routes/components'; +import { useRouter } from 'src/routes/hooks'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; import { FormHead } from '../../components/form-head'; import { signInWithPassword } from '../../context/amplify'; +import { useAuthContext } from '../../hooks'; +import { getErrorMessage } from '../../utils'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/view/amplify/amplify-sign-up-view.tsx b/03_source/frontend/src/auth/view/amplify/amplify-sign-up-view.tsx index dff0c80..3476263 100644 --- a/03_source/frontend/src/auth/view/amplify/amplify-sign-up-view.tsx +++ b/03_source/frontend/src/auth/view/amplify/amplify-sign-up-view.tsx @@ -1,27 +1,23 @@ -import { z as zod } from 'zod'; -import { useState } from 'react'; -import { useForm } from 'react-hook-form'; -import { useBoolean } from 'minimal-shared/hooks'; import { zodResolver } from '@hookform/resolvers/zod'; - -import Box from '@mui/material/Box'; -import Link from '@mui/material/Link'; import Alert from '@mui/material/Alert'; +import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; import IconButton from '@mui/material/IconButton'; import InputAdornment from '@mui/material/InputAdornment'; - -import { paths } from 'src/routes/paths'; -import { useRouter } from 'src/routes/hooks'; -import { RouterLink } from 'src/routes/components'; - +import Link from '@mui/material/Link'; +import { useBoolean } from 'minimal-shared/hooks'; +import { useState } from 'react'; +import { useForm } from 'react-hook-form'; +import { Field, Form } from 'src/components/hook-form'; import { Iconify } from 'src/components/iconify'; -import { Form, Field } from 'src/components/hook-form'; - -import { getErrorMessage } from '../../utils'; -import { signUp } from '../../context/amplify'; +import { RouterLink } from 'src/routes/components'; +import { useRouter } from 'src/routes/hooks'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; import { FormHead } from '../../components/form-head'; import { SignUpTerms } from '../../components/sign-up-terms'; +import { signUp } from '../../context/amplify'; +import { getErrorMessage } from '../../utils'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/view/amplify/amplify-update-password-view.tsx b/03_source/frontend/src/auth/view/amplify/amplify-update-password-view.tsx index 6b08336..3981251 100644 --- a/03_source/frontend/src/auth/view/amplify/amplify-update-password-view.tsx +++ b/03_source/frontend/src/auth/view/amplify/amplify-update-password-view.tsx @@ -1,25 +1,20 @@ -import { z as zod } from 'zod'; -import { useCallback } from 'react'; -import { useForm } from 'react-hook-form'; import { zodResolver } from '@hookform/resolvers/zod'; -import { useBoolean, useCountdownSeconds } from 'minimal-shared/hooks'; - import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; import IconButton from '@mui/material/IconButton'; import InputAdornment from '@mui/material/InputAdornment'; - -import { paths } from 'src/routes/paths'; -import { useRouter, useSearchParams } from 'src/routes/hooks'; - +import { useBoolean, useCountdownSeconds } from 'minimal-shared/hooks'; +import { useCallback } from 'react'; +import { useForm } from 'react-hook-form'; import { SentIcon } from 'src/assets/icons'; - +import { Field, Form } from 'src/components/hook-form'; import { Iconify } from 'src/components/iconify'; -import { Form, Field } from 'src/components/hook-form'; - +import { useRouter, useSearchParams } from 'src/routes/hooks'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; import { FormHead } from '../../components/form-head'; -import { FormReturnLink } from '../../components/form-return-link'; import { FormResendCode } from '../../components/form-resend-code'; +import { FormReturnLink } from '../../components/form-return-link'; import { resetPassword, updatePassword } from '../../context/amplify'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/view/amplify/amplify-verify-view.tsx b/03_source/frontend/src/auth/view/amplify/amplify-verify-view.tsx index 4079714..dd24185 100644 --- a/03_source/frontend/src/auth/view/amplify/amplify-verify-view.tsx +++ b/03_source/frontend/src/auth/view/amplify/amplify-verify-view.tsx @@ -1,22 +1,17 @@ -import { z as zod } from 'zod'; -import { useCallback } from 'react'; -import { useForm } from 'react-hook-form'; import { zodResolver } from '@hookform/resolvers/zod'; -import { useCountdownSeconds } from 'minimal-shared/hooks'; - import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; - -import { paths } from 'src/routes/paths'; -import { useRouter, useSearchParams } from 'src/routes/hooks'; - +import { useCountdownSeconds } from 'minimal-shared/hooks'; +import { useCallback } from 'react'; +import { useForm } from 'react-hook-form'; import { EmailInboxIcon } from 'src/assets/icons'; - -import { Form, Field } from 'src/components/hook-form'; - +import { Field, Form } from 'src/components/hook-form'; +import { useRouter, useSearchParams } from 'src/routes/hooks'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; import { FormHead } from '../../components/form-head'; -import { FormReturnLink } from '../../components/form-return-link'; import { FormResendCode } from '../../components/form-resend-code'; +import { FormReturnLink } from '../../components/form-return-link'; import { confirmSignUp, resendSignUpCode } from '../../context/amplify'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/view/auth-demo/centered/centered-reset-password-view.tsx b/03_source/frontend/src/auth/view/auth-demo/centered/centered-reset-password-view.tsx index fa3c4c5..b933605 100644 --- a/03_source/frontend/src/auth/view/auth-demo/centered/centered-reset-password-view.tsx +++ b/03_source/frontend/src/auth/view/auth-demo/centered/centered-reset-password-view.tsx @@ -1,16 +1,11 @@ -import { z as zod } from 'zod'; -import { useForm } from 'react-hook-form'; import { zodResolver } from '@hookform/resolvers/zod'; - import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; - -import { paths } from 'src/routes/paths'; - +import { useForm } from 'react-hook-form'; import { PasswordIcon } from 'src/assets/icons'; - -import { Form, Field } from 'src/components/hook-form'; - +import { Field, Form } from 'src/components/hook-form'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; import { FormHead } from '../../../components/form-head'; import { FormReturnLink } from '../../../components/form-return-link'; diff --git a/03_source/frontend/src/auth/view/auth-demo/centered/centered-sign-in-view.tsx b/03_source/frontend/src/auth/view/auth-demo/centered/centered-sign-in-view.tsx index 43bfb62..15e0c52 100644 --- a/03_source/frontend/src/auth/view/auth-demo/centered/centered-sign-in-view.tsx +++ b/03_source/frontend/src/auth/view/auth-demo/centered/centered-sign-in-view.tsx @@ -1,24 +1,20 @@ -import { z as zod } from 'zod'; -import { useForm } from 'react-hook-form'; -import { useBoolean } from 'minimal-shared/hooks'; import { zodResolver } from '@hookform/resolvers/zod'; - import Box from '@mui/material/Box'; -import Link from '@mui/material/Link'; import Button from '@mui/material/Button'; import IconButton from '@mui/material/IconButton'; import InputAdornment from '@mui/material/InputAdornment'; - -import { paths } from 'src/routes/paths'; -import { RouterLink } from 'src/routes/components'; - -import { Iconify } from 'src/components/iconify'; -import { Form, Field } from 'src/components/hook-form'; +import Link from '@mui/material/Link'; +import { useBoolean } from 'minimal-shared/hooks'; +import { useForm } from 'react-hook-form'; import { AnimateLogoRotate } from 'src/components/animate'; - +import { Field, Form } from 'src/components/hook-form'; +import { Iconify } from 'src/components/iconify'; +import { RouterLink } from 'src/routes/components'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; +import { FormDivider } from '../../../components/form-divider'; import { FormHead } from '../../../components/form-head'; import { FormSocials } from '../../../components/form-socials'; -import { FormDivider } from '../../../components/form-divider'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/view/auth-demo/centered/centered-sign-up-view.tsx b/03_source/frontend/src/auth/view/auth-demo/centered/centered-sign-up-view.tsx index 5e6a47d..c8630ba 100644 --- a/03_source/frontend/src/auth/view/auth-demo/centered/centered-sign-up-view.tsx +++ b/03_source/frontend/src/auth/view/auth-demo/centered/centered-sign-up-view.tsx @@ -1,24 +1,20 @@ -import { z as zod } from 'zod'; -import { useForm } from 'react-hook-form'; -import { useBoolean } from 'minimal-shared/hooks'; import { zodResolver } from '@hookform/resolvers/zod'; - import Box from '@mui/material/Box'; -import Link from '@mui/material/Link'; import Button from '@mui/material/Button'; import IconButton from '@mui/material/IconButton'; import InputAdornment from '@mui/material/InputAdornment'; - -import { paths } from 'src/routes/paths'; -import { RouterLink } from 'src/routes/components'; - -import { Iconify } from 'src/components/iconify'; -import { Form, Field } from 'src/components/hook-form'; +import Link from '@mui/material/Link'; +import { useBoolean } from 'minimal-shared/hooks'; +import { useForm } from 'react-hook-form'; import { AnimateLogoRotate } from 'src/components/animate'; - +import { Field, Form } from 'src/components/hook-form'; +import { Iconify } from 'src/components/iconify'; +import { RouterLink } from 'src/routes/components'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; +import { FormDivider } from '../../../components/form-divider'; import { FormHead } from '../../../components/form-head'; import { FormSocials } from '../../../components/form-socials'; -import { FormDivider } from '../../../components/form-divider'; import { SignUpTerms } from '../../../components/sign-up-terms'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/view/auth-demo/centered/centered-update-password-view.tsx b/03_source/frontend/src/auth/view/auth-demo/centered/centered-update-password-view.tsx index 895f114..25b89b7 100644 --- a/03_source/frontend/src/auth/view/auth-demo/centered/centered-update-password-view.tsx +++ b/03_source/frontend/src/auth/view/auth-demo/centered/centered-update-password-view.tsx @@ -1,20 +1,15 @@ -import { z as zod } from 'zod'; -import { useForm } from 'react-hook-form'; -import { useBoolean } from 'minimal-shared/hooks'; import { zodResolver } from '@hookform/resolvers/zod'; - import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; import IconButton from '@mui/material/IconButton'; import InputAdornment from '@mui/material/InputAdornment'; - -import { paths } from 'src/routes/paths'; - +import { useBoolean } from 'minimal-shared/hooks'; +import { useForm } from 'react-hook-form'; import { SentIcon } from 'src/assets/icons'; - +import { Field, Form } from 'src/components/hook-form'; import { Iconify } from 'src/components/iconify'; -import { Form, Field } from 'src/components/hook-form'; - +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; import { FormHead } from '../../../components/form-head'; import { FormResendCode } from '../../../components/form-resend-code'; import { FormReturnLink } from '../../../components/form-return-link'; diff --git a/03_source/frontend/src/auth/view/auth-demo/centered/centered-verify-view.tsx b/03_source/frontend/src/auth/view/auth-demo/centered/centered-verify-view.tsx index 1892cfd..d395d66 100644 --- a/03_source/frontend/src/auth/view/auth-demo/centered/centered-verify-view.tsx +++ b/03_source/frontend/src/auth/view/auth-demo/centered/centered-verify-view.tsx @@ -1,16 +1,11 @@ -import { z as zod } from 'zod'; -import { useForm } from 'react-hook-form'; import { zodResolver } from '@hookform/resolvers/zod'; - import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; - -import { paths } from 'src/routes/paths'; - +import { useForm } from 'react-hook-form'; import { EmailInboxIcon } from 'src/assets/icons'; - -import { Form, Field } from 'src/components/hook-form'; - +import { Field, Form } from 'src/components/hook-form'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; import { FormHead } from '../../../components/form-head'; import { FormResendCode } from '../../../components/form-resend-code'; import { FormReturnLink } from '../../../components/form-return-link'; diff --git a/03_source/frontend/src/auth/view/auth-demo/split/split-reset-password-view.tsx b/03_source/frontend/src/auth/view/auth-demo/split/split-reset-password-view.tsx index b755d2d..ccb95f2 100644 --- a/03_source/frontend/src/auth/view/auth-demo/split/split-reset-password-view.tsx +++ b/03_source/frontend/src/auth/view/auth-demo/split/split-reset-password-view.tsx @@ -1,16 +1,11 @@ -import { z as zod } from 'zod'; -import { useForm } from 'react-hook-form'; import { zodResolver } from '@hookform/resolvers/zod'; - import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; - -import { paths } from 'src/routes/paths'; - +import { useForm } from 'react-hook-form'; import { PasswordIcon } from 'src/assets/icons'; - -import { Form, Field } from 'src/components/hook-form'; - +import { Field, Form } from 'src/components/hook-form'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; import { FormHead } from '../../../components/form-head'; import { FormReturnLink } from '../../../components/form-return-link'; diff --git a/03_source/frontend/src/auth/view/auth-demo/split/split-sign-in-view.tsx b/03_source/frontend/src/auth/view/auth-demo/split/split-sign-in-view.tsx index 3213fff..dd00413 100644 --- a/03_source/frontend/src/auth/view/auth-demo/split/split-sign-in-view.tsx +++ b/03_source/frontend/src/auth/view/auth-demo/split/split-sign-in-view.tsx @@ -1,23 +1,19 @@ -import { z as zod } from 'zod'; -import { useForm } from 'react-hook-form'; -import { useBoolean } from 'minimal-shared/hooks'; import { zodResolver } from '@hookform/resolvers/zod'; - import Box from '@mui/material/Box'; -import Link from '@mui/material/Link'; import Button from '@mui/material/Button'; import IconButton from '@mui/material/IconButton'; import InputAdornment from '@mui/material/InputAdornment'; - -import { paths } from 'src/routes/paths'; -import { RouterLink } from 'src/routes/components'; - +import Link from '@mui/material/Link'; +import { useBoolean } from 'minimal-shared/hooks'; +import { useForm } from 'react-hook-form'; +import { Field, Form } from 'src/components/hook-form'; import { Iconify } from 'src/components/iconify'; -import { Form, Field } from 'src/components/hook-form'; - +import { RouterLink } from 'src/routes/components'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; +import { FormDivider } from '../../../components/form-divider'; import { FormHead } from '../../../components/form-head'; import { FormSocials } from '../../../components/form-socials'; -import { FormDivider } from '../../../components/form-divider'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/view/auth-demo/split/split-sign-up-view.tsx b/03_source/frontend/src/auth/view/auth-demo/split/split-sign-up-view.tsx index 46812aa..e9b0c7b 100644 --- a/03_source/frontend/src/auth/view/auth-demo/split/split-sign-up-view.tsx +++ b/03_source/frontend/src/auth/view/auth-demo/split/split-sign-up-view.tsx @@ -1,22 +1,18 @@ -import { z as zod } from 'zod'; -import { useForm } from 'react-hook-form'; -import { useBoolean } from 'minimal-shared/hooks'; import { zodResolver } from '@hookform/resolvers/zod'; - import Box from '@mui/material/Box'; -import Link from '@mui/material/Link'; import Button from '@mui/material/Button'; import IconButton from '@mui/material/IconButton'; import InputAdornment from '@mui/material/InputAdornment'; - -import { paths } from 'src/routes/paths'; -import { RouterLink } from 'src/routes/components'; - +import Link from '@mui/material/Link'; +import { useBoolean } from 'minimal-shared/hooks'; +import { useForm } from 'react-hook-form'; +import { Field, Form } from 'src/components/hook-form'; import { Iconify } from 'src/components/iconify'; -import { Form, Field } from 'src/components/hook-form'; - -import { FormHead } from '../../../components/form-head'; +import { RouterLink } from 'src/routes/components'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; import { FormDivider } from '../../../components/form-divider'; +import { FormHead } from '../../../components/form-head'; import { FormSocials } from '../../../components/form-socials'; import { SignUpTerms } from '../../../components/sign-up-terms'; diff --git a/03_source/frontend/src/auth/view/auth-demo/split/split-update-password-view.tsx b/03_source/frontend/src/auth/view/auth-demo/split/split-update-password-view.tsx index be1940f..702e362 100644 --- a/03_source/frontend/src/auth/view/auth-demo/split/split-update-password-view.tsx +++ b/03_source/frontend/src/auth/view/auth-demo/split/split-update-password-view.tsx @@ -1,20 +1,15 @@ -import { z as zod } from 'zod'; -import { useForm } from 'react-hook-form'; -import { useBoolean } from 'minimal-shared/hooks'; import { zodResolver } from '@hookform/resolvers/zod'; - import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; import IconButton from '@mui/material/IconButton'; import InputAdornment from '@mui/material/InputAdornment'; - -import { paths } from 'src/routes/paths'; - +import { useBoolean } from 'minimal-shared/hooks'; +import { useForm } from 'react-hook-form'; import { SentIcon } from 'src/assets/icons'; - +import { Field, Form } from 'src/components/hook-form'; import { Iconify } from 'src/components/iconify'; -import { Form, Field } from 'src/components/hook-form'; - +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; import { FormHead } from '../../../components/form-head'; import { FormResendCode } from '../../../components/form-resend-code'; import { FormReturnLink } from '../../../components/form-return-link'; diff --git a/03_source/frontend/src/auth/view/auth-demo/split/split-verify-view.tsx b/03_source/frontend/src/auth/view/auth-demo/split/split-verify-view.tsx index 19d7b14..df24c66 100644 --- a/03_source/frontend/src/auth/view/auth-demo/split/split-verify-view.tsx +++ b/03_source/frontend/src/auth/view/auth-demo/split/split-verify-view.tsx @@ -1,19 +1,14 @@ -import { z as zod } from 'zod'; -import { useForm } from 'react-hook-form'; import { zodResolver } from '@hookform/resolvers/zod'; - import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; - -import { paths } from 'src/routes/paths'; - +import { useForm } from 'react-hook-form'; import { EmailInboxIcon } from 'src/assets/icons'; - -import { Form, Field } from 'src/components/hook-form'; - +import { Field, Form } from 'src/components/hook-form'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; import { FormHead } from '../../../components/form-head'; -import { FormReturnLink } from '../../../components/form-return-link'; import { FormResendCode } from '../../../components/form-resend-code'; +import { FormReturnLink } from '../../../components/form-return-link'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/view/auth0/auth0-sign-in-view.tsx b/03_source/frontend/src/auth/view/auth0/auth0-sign-in-view.tsx index 558f8eb..a1af791 100644 --- a/03_source/frontend/src/auth/view/auth0/auth0-sign-in-view.tsx +++ b/03_source/frontend/src/auth/view/auth0/auth0-sign-in-view.tsx @@ -1,14 +1,11 @@ -import { useCallback } from 'react'; import { useAuth0 } from '@auth0/auth0-react'; - import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; import Divider from '@mui/material/Divider'; import Typography from '@mui/material/Typography'; - -import { useSearchParams } from 'src/routes/hooks'; - +import { useCallback } from 'react'; import { CONFIG } from 'src/global-config'; +import { useSearchParams } from 'src/routes/hooks'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/view/firebase/firebase-reset-password-view.tsx b/03_source/frontend/src/auth/view/firebase/firebase-reset-password-view.tsx index 0409223..b69ba54 100644 --- a/03_source/frontend/src/auth/view/firebase/firebase-reset-password-view.tsx +++ b/03_source/frontend/src/auth/view/firebase/firebase-reset-password-view.tsx @@ -1,20 +1,15 @@ -import { z as zod } from 'zod'; -import { useForm } from 'react-hook-form'; import { zodResolver } from '@hookform/resolvers/zod'; - import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; - -import { paths } from 'src/routes/paths'; -import { useRouter } from 'src/routes/hooks'; - +import { useForm } from 'react-hook-form'; import { PasswordIcon } from 'src/assets/icons'; - -import { Form, Field } from 'src/components/hook-form'; - +import { Field, Form } from 'src/components/hook-form'; +import { useRouter } from 'src/routes/hooks'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; import { FormHead } from '../../components/form-head'; -import { sendPasswordResetEmail } from '../../context/firebase'; import { FormReturnLink } from '../../components/form-return-link'; +import { sendPasswordResetEmail } from '../../context/firebase'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/view/firebase/firebase-sign-in-view.tsx b/03_source/frontend/src/auth/view/firebase/firebase-sign-in-view.tsx index 3967af3..ed37edd 100644 --- a/03_source/frontend/src/auth/view/firebase/firebase-sign-in-view.tsx +++ b/03_source/frontend/src/auth/view/firebase/firebase-sign-in-view.tsx @@ -1,34 +1,30 @@ -import { z as zod } from 'zod'; -import { useState } from 'react'; -import { useForm } from 'react-hook-form'; -import { useBoolean } from 'minimal-shared/hooks'; import { zodResolver } from '@hookform/resolvers/zod'; - -import Box from '@mui/material/Box'; -import Link from '@mui/material/Link'; import Alert from '@mui/material/Alert'; +import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; import IconButton from '@mui/material/IconButton'; import InputAdornment from '@mui/material/InputAdornment'; - -import { paths } from 'src/routes/paths'; -import { useRouter } from 'src/routes/hooks'; -import { RouterLink } from 'src/routes/components'; - +import Link from '@mui/material/Link'; +import { useBoolean } from 'minimal-shared/hooks'; +import { useState } from 'react'; +import { useForm } from 'react-hook-form'; +import { Field, Form } from 'src/components/hook-form'; import { Iconify } from 'src/components/iconify'; -import { Form, Field } from 'src/components/hook-form'; - -import { useAuthContext } from '../../hooks'; -import { getErrorMessage } from '../../utils'; -import { FormHead } from '../../components/form-head'; +import { RouterLink } from 'src/routes/components'; +import { useRouter } from 'src/routes/hooks'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; import { FormDivider } from '../../components/form-divider'; +import { FormHead } from '../../components/form-head'; import { FormSocials } from '../../components/form-socials'; import { - signInWithGoogle, signInWithGithub, - signInWithTwitter, + signInWithGoogle, signInWithPassword, + signInWithTwitter, } from '../../context/firebase'; +import { useAuthContext } from '../../hooks'; +import { getErrorMessage } from '../../utils'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/view/firebase/firebase-sign-up-view.tsx b/03_source/frontend/src/auth/view/firebase/firebase-sign-up-view.tsx index 4566c42..b18c81d 100644 --- a/03_source/frontend/src/auth/view/firebase/firebase-sign-up-view.tsx +++ b/03_source/frontend/src/auth/view/firebase/firebase-sign-up-view.tsx @@ -1,34 +1,30 @@ -import { z as zod } from 'zod'; -import { useState } from 'react'; -import { useForm } from 'react-hook-form'; -import { useBoolean } from 'minimal-shared/hooks'; import { zodResolver } from '@hookform/resolvers/zod'; - -import Box from '@mui/material/Box'; -import Link from '@mui/material/Link'; import Alert from '@mui/material/Alert'; +import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; import IconButton from '@mui/material/IconButton'; import InputAdornment from '@mui/material/InputAdornment'; - -import { paths } from 'src/routes/paths'; -import { useRouter } from 'src/routes/hooks'; -import { RouterLink } from 'src/routes/components'; - +import Link from '@mui/material/Link'; +import { useBoolean } from 'minimal-shared/hooks'; +import { useState } from 'react'; +import { useForm } from 'react-hook-form'; +import { Field, Form } from 'src/components/hook-form'; import { Iconify } from 'src/components/iconify'; -import { Form, Field } from 'src/components/hook-form'; - -import { getErrorMessage } from '../../utils'; -import { FormHead } from '../../components/form-head'; +import { RouterLink } from 'src/routes/components'; +import { useRouter } from 'src/routes/hooks'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; import { FormDivider } from '../../components/form-divider'; +import { FormHead } from '../../components/form-head'; import { FormSocials } from '../../components/form-socials'; import { SignUpTerms } from '../../components/sign-up-terms'; import { - signUp, signInWithGithub, signInWithGoogle, signInWithTwitter, + signUp, } from '../../context/firebase'; +import { getErrorMessage } from '../../utils'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/view/firebase/firebase-verify-view.tsx b/03_source/frontend/src/auth/view/firebase/firebase-verify-view.tsx index 57fdc19..848d11d 100644 --- a/03_source/frontend/src/auth/view/firebase/firebase-verify-view.tsx +++ b/03_source/frontend/src/auth/view/firebase/firebase-verify-view.tsx @@ -1,7 +1,5 @@ -import { paths } from 'src/routes/paths'; - import { EmailInboxIcon } from 'src/assets/icons'; - +import { paths } from 'src/routes/paths'; import { FormHead } from '../../components/form-head'; import { FormReturnLink } from '../../components/form-return-link'; diff --git a/03_source/frontend/src/auth/view/jwt/jwt-sign-in-view.tsx b/03_source/frontend/src/auth/view/jwt/jwt-sign-in-view.tsx index 7701c1f..8e67e40 100644 --- a/03_source/frontend/src/auth/view/jwt/jwt-sign-in-view.tsx +++ b/03_source/frontend/src/auth/view/jwt/jwt-sign-in-view.tsx @@ -1,27 +1,23 @@ -import { z as zod } from 'zod'; -import { useState } from 'react'; -import { useForm } from 'react-hook-form'; -import { useBoolean } from 'minimal-shared/hooks'; import { zodResolver } from '@hookform/resolvers/zod'; - -import Box from '@mui/material/Box'; -import Link from '@mui/material/Link'; import Alert from '@mui/material/Alert'; +import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; import IconButton from '@mui/material/IconButton'; import InputAdornment from '@mui/material/InputAdornment'; - -import { paths } from 'src/routes/paths'; -import { useRouter } from 'src/routes/hooks'; -import { RouterLink } from 'src/routes/components'; - +import Link from '@mui/material/Link'; +import { useBoolean } from 'minimal-shared/hooks'; +import { useState } from 'react'; +import { useForm } from 'react-hook-form'; +import { Field, Form } from 'src/components/hook-form'; import { Iconify } from 'src/components/iconify'; -import { Form, Field } from 'src/components/hook-form'; - -import { useAuthContext } from '../../hooks'; -import { getErrorMessage } from '../../utils'; +import { RouterLink } from 'src/routes/components'; +import { useRouter } from 'src/routes/hooks'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; import { FormHead } from '../../components/form-head'; import { signInWithPassword } from '../../context/jwt'; +import { useAuthContext } from '../../hooks'; +import { getErrorMessage } from '../../utils'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/view/jwt/jwt-sign-up-view.tsx b/03_source/frontend/src/auth/view/jwt/jwt-sign-up-view.tsx index 8b35a24..dcc0aef 100644 --- a/03_source/frontend/src/auth/view/jwt/jwt-sign-up-view.tsx +++ b/03_source/frontend/src/auth/view/jwt/jwt-sign-up-view.tsx @@ -1,28 +1,24 @@ -import { z as zod } from 'zod'; -import { useState } from 'react'; -import { useForm } from 'react-hook-form'; -import { useBoolean } from 'minimal-shared/hooks'; import { zodResolver } from '@hookform/resolvers/zod'; - -import Box from '@mui/material/Box'; -import Link from '@mui/material/Link'; import Alert from '@mui/material/Alert'; +import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; import IconButton from '@mui/material/IconButton'; import InputAdornment from '@mui/material/InputAdornment'; - -import { paths } from 'src/routes/paths'; -import { useRouter } from 'src/routes/hooks'; -import { RouterLink } from 'src/routes/components'; - +import Link from '@mui/material/Link'; +import { useBoolean } from 'minimal-shared/hooks'; +import { useState } from 'react'; +import { useForm } from 'react-hook-form'; +import { Field, Form } from 'src/components/hook-form'; import { Iconify } from 'src/components/iconify'; -import { Form, Field } from 'src/components/hook-form'; - +import { RouterLink } from 'src/routes/components'; +import { useRouter } from 'src/routes/hooks'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; +import { FormHead } from '../../components/form-head'; +import { SignUpTerms } from '../../components/sign-up-terms'; import { signUp } from '../../context/jwt'; import { useAuthContext } from '../../hooks'; import { getErrorMessage } from '../../utils'; -import { FormHead } from '../../components/form-head'; -import { SignUpTerms } from '../../components/sign-up-terms'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/view/supabase/supabase-reset-password-view.tsx b/03_source/frontend/src/auth/view/supabase/supabase-reset-password-view.tsx index 532184c..96b2645 100644 --- a/03_source/frontend/src/auth/view/supabase/supabase-reset-password-view.tsx +++ b/03_source/frontend/src/auth/view/supabase/supabase-reset-password-view.tsx @@ -1,20 +1,15 @@ -import { z as zod } from 'zod'; -import { useForm } from 'react-hook-form'; import { zodResolver } from '@hookform/resolvers/zod'; - import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; - -import { paths } from 'src/routes/paths'; -import { useRouter } from 'src/routes/hooks'; - +import { useForm } from 'react-hook-form'; import { PasswordIcon } from 'src/assets/icons'; - -import { Form, Field } from 'src/components/hook-form'; - +import { Field, Form } from 'src/components/hook-form'; +import { useRouter } from 'src/routes/hooks'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; import { FormHead } from '../../components/form-head'; -import { resetPassword } from '../../context/supabase'; import { FormReturnLink } from '../../components/form-return-link'; +import { resetPassword } from '../../context/supabase'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/view/supabase/supabase-sign-in-view.tsx b/03_source/frontend/src/auth/view/supabase/supabase-sign-in-view.tsx index 362a732..7b84a12 100644 --- a/03_source/frontend/src/auth/view/supabase/supabase-sign-in-view.tsx +++ b/03_source/frontend/src/auth/view/supabase/supabase-sign-in-view.tsx @@ -1,27 +1,23 @@ -import { z as zod } from 'zod'; -import { useState } from 'react'; -import { useForm } from 'react-hook-form'; -import { useBoolean } from 'minimal-shared/hooks'; import { zodResolver } from '@hookform/resolvers/zod'; - -import Box from '@mui/material/Box'; -import Link from '@mui/material/Link'; import Alert from '@mui/material/Alert'; +import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; import IconButton from '@mui/material/IconButton'; import InputAdornment from '@mui/material/InputAdornment'; - -import { paths } from 'src/routes/paths'; -import { useRouter } from 'src/routes/hooks'; -import { RouterLink } from 'src/routes/components'; - +import Link from '@mui/material/Link'; +import { useBoolean } from 'minimal-shared/hooks'; +import { useState } from 'react'; +import { useForm } from 'react-hook-form'; +import { Field, Form } from 'src/components/hook-form'; import { Iconify } from 'src/components/iconify'; -import { Form, Field } from 'src/components/hook-form'; - -import { useAuthContext } from '../../hooks'; -import { getErrorMessage } from '../../utils'; +import { RouterLink } from 'src/routes/components'; +import { useRouter } from 'src/routes/hooks'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; import { FormHead } from '../../components/form-head'; import { signInWithPassword } from '../../context/supabase'; +import { useAuthContext } from '../../hooks'; +import { getErrorMessage } from '../../utils'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/view/supabase/supabase-sign-up-view.tsx b/03_source/frontend/src/auth/view/supabase/supabase-sign-up-view.tsx index 448f176..838f2b1 100644 --- a/03_source/frontend/src/auth/view/supabase/supabase-sign-up-view.tsx +++ b/03_source/frontend/src/auth/view/supabase/supabase-sign-up-view.tsx @@ -1,27 +1,23 @@ -import { z as zod } from 'zod'; -import { useState } from 'react'; -import { useForm } from 'react-hook-form'; -import { useBoolean } from 'minimal-shared/hooks'; import { zodResolver } from '@hookform/resolvers/zod'; - -import Box from '@mui/material/Box'; -import Link from '@mui/material/Link'; import Alert from '@mui/material/Alert'; +import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; import IconButton from '@mui/material/IconButton'; import InputAdornment from '@mui/material/InputAdornment'; - -import { paths } from 'src/routes/paths'; -import { useRouter } from 'src/routes/hooks'; -import { RouterLink } from 'src/routes/components'; - +import Link from '@mui/material/Link'; +import { useBoolean } from 'minimal-shared/hooks'; +import { useState } from 'react'; +import { useForm } from 'react-hook-form'; +import { Field, Form } from 'src/components/hook-form'; import { Iconify } from 'src/components/iconify'; -import { Form, Field } from 'src/components/hook-form'; - -import { getErrorMessage } from '../../utils'; -import { signUp } from '../../context/supabase'; +import { RouterLink } from 'src/routes/components'; +import { useRouter } from 'src/routes/hooks'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; import { FormHead } from '../../components/form-head'; import { SignUpTerms } from '../../components/sign-up-terms'; +import { signUp } from '../../context/supabase'; +import { getErrorMessage } from '../../utils'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/view/supabase/supabase-update-password-view.tsx b/03_source/frontend/src/auth/view/supabase/supabase-update-password-view.tsx index 9d11569..36406fa 100644 --- a/03_source/frontend/src/auth/view/supabase/supabase-update-password-view.tsx +++ b/03_source/frontend/src/auth/view/supabase/supabase-update-password-view.tsx @@ -1,26 +1,21 @@ -import { z as zod } from 'zod'; -import { useState } from 'react'; -import { useForm } from 'react-hook-form'; -import { useBoolean } from 'minimal-shared/hooks'; import { zodResolver } from '@hookform/resolvers/zod'; - -import Box from '@mui/material/Box'; import Alert from '@mui/material/Alert'; +import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; import IconButton from '@mui/material/IconButton'; import InputAdornment from '@mui/material/InputAdornment'; - -import { paths } from 'src/routes/paths'; -import { useRouter } from 'src/routes/hooks'; - +import { useBoolean } from 'minimal-shared/hooks'; +import { useState } from 'react'; +import { useForm } from 'react-hook-form'; import { NewPasswordIcon } from 'src/assets/icons'; - +import { Field, Form } from 'src/components/hook-form'; import { Iconify } from 'src/components/iconify'; -import { Form, Field } from 'src/components/hook-form'; - -import { getErrorMessage } from '../../utils'; +import { useRouter } from 'src/routes/hooks'; +import { paths } from 'src/routes/paths'; +import { z as zod } from 'zod'; import { FormHead } from '../../components/form-head'; import { updatePassword } from '../../context/supabase'; +import { getErrorMessage } from '../../utils'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/auth/view/supabase/supabase-verify-view.tsx b/03_source/frontend/src/auth/view/supabase/supabase-verify-view.tsx index db90d2f..f5df255 100644 --- a/03_source/frontend/src/auth/view/supabase/supabase-verify-view.tsx +++ b/03_source/frontend/src/auth/view/supabase/supabase-verify-view.tsx @@ -1,7 +1,5 @@ -import { paths } from 'src/routes/paths'; - import { EmailInboxIcon } from 'src/assets/icons'; - +import { paths } from 'src/routes/paths'; import { FormHead } from '../../components/form-head'; import { FormReturnLink } from '../../components/form-return-link'; diff --git a/03_source/frontend/src/components/animate/animate-border.tsx b/03_source/frontend/src/components/animate/animate-border.tsx index 2ba1a0c..f071e17 100644 --- a/03_source/frontend/src/components/animate/animate-border.tsx +++ b/03_source/frontend/src/components/animate/animate-border.tsx @@ -1,19 +1,16 @@ import type { BoxProps } from '@mui/material/Box'; -import type { Theme, SxProps, CSSObject } from '@mui/material/styles'; - -import { mergeClasses } from 'minimal-shared/utils'; -import { useRef, useState, useEffect } from 'react'; +import Box from '@mui/material/Box'; +import type { CSSObject, SxProps, Theme } from '@mui/material/styles'; +import { useTheme } from '@mui/material/styles'; import { m, - useTransform, - useMotionValue, useAnimationFrame, useMotionTemplate, + useMotionValue, + useTransform, } from 'framer-motion'; - -import Box from '@mui/material/Box'; -import { useTheme } from '@mui/material/styles'; - +import { mergeClasses } from 'minimal-shared/utils'; +import { useEffect, useRef, useState } from 'react'; import { createClasses } from 'src/theme/create-classes'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/animate/animate-count-up.tsx b/03_source/frontend/src/components/animate/animate-count-up.tsx index 9f46a55..f0a06fb 100644 --- a/03_source/frontend/src/components/animate/animate-count-up.tsx +++ b/03_source/frontend/src/components/animate/animate-count-up.tsx @@ -1,10 +1,8 @@ -import type { UseInViewOptions } from 'framer-motion'; import type { TypographyProps } from '@mui/material/Typography'; - -import { useRef, useEffect } from 'react'; -import { m, animate, useInView, useTransform, useMotionValue } from 'framer-motion'; - import Typography from '@mui/material/Typography'; +import type { UseInViewOptions } from 'framer-motion'; +import { animate, m, useInView, useMotionValue, useTransform } from 'framer-motion'; +import { useEffect, useRef } from 'react'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/animate/animate-logo.tsx b/03_source/frontend/src/components/animate/animate-logo.tsx index 113000f..8b0cb2e 100644 --- a/03_source/frontend/src/components/animate/animate-logo.tsx +++ b/03_source/frontend/src/components/animate/animate-logo.tsx @@ -1,12 +1,8 @@ -import type { Theme, SxProps } from '@mui/material/styles'; - +import type { SxProps, Theme } from '@mui/material/styles'; +import { styled } from '@mui/material/styles'; import { m } from 'framer-motion'; import { varAlpha } from 'minimal-shared/utils'; - -import { styled } from '@mui/material/styles'; - import { Logo } from '../logo'; - import type { LogoProps } from '../logo'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/animate/animate-text.tsx b/03_source/frontend/src/components/animate/animate-text.tsx index aa02b86..605945c 100644 --- a/03_source/frontend/src/components/animate/animate-text.tsx +++ b/03_source/frontend/src/components/animate/animate-text.tsx @@ -1,17 +1,13 @@ -import type { Theme, SxProps } from '@mui/material/styles'; -import type { TypographyProps } from '@mui/material/Typography'; -import type { Variants, UseInViewOptions } from 'framer-motion'; - -import { useRef, useMemo, useEffect } from 'react'; -import { mergeClasses } from 'minimal-shared/utils'; -import { m, useInView, useAnimation } from 'framer-motion'; - +import type { SxProps, Theme } from '@mui/material/styles'; import { styled } from '@mui/material/styles'; +import type { TypographyProps } from '@mui/material/Typography'; import Typography from '@mui/material/Typography'; - +import type { UseInViewOptions, Variants } from 'framer-motion'; +import { m, useAnimation, useInView } from 'framer-motion'; +import { mergeClasses } from 'minimal-shared/utils'; +import { useEffect, useMemo, useRef } from 'react'; import { createClasses } from 'src/theme/create-classes'; - -import { varFade, varContainer } from './variants'; +import { varContainer, varFade } from './variants'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/animate/back-to-top-button.tsx b/03_source/frontend/src/components/animate/back-to-top-button.tsx index 7185988..572b001 100644 --- a/03_source/frontend/src/components/animate/back-to-top-button.tsx +++ b/03_source/frontend/src/components/animate/back-to-top-button.tsx @@ -1,10 +1,7 @@ import type { FabProps } from '@mui/material/Fab'; - -import { cloneElement } from 'react'; -import { useBackToTop } from 'minimal-shared/hooks'; - import Fab from '@mui/material/Fab'; - +import { useBackToTop } from 'minimal-shared/hooks'; +import { cloneElement } from 'react'; import { Iconify } from '../iconify'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/animate/motion-container.tsx b/03_source/frontend/src/components/animate/motion-container.tsx index d50e66a..71f8e64 100644 --- a/03_source/frontend/src/components/animate/motion-container.tsx +++ b/03_source/frontend/src/components/animate/motion-container.tsx @@ -1,10 +1,7 @@ -import type { MotionProps } from 'framer-motion'; import type { BoxProps } from '@mui/material/Box'; - -import { m } from 'framer-motion'; - import Box from '@mui/material/Box'; - +import type { MotionProps } from 'framer-motion'; +import { m } from 'framer-motion'; import { varContainer } from './variants'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/animate/motion-viewport.tsx b/03_source/frontend/src/components/animate/motion-viewport.tsx index 0c74666..b3c921d 100644 --- a/03_source/frontend/src/components/animate/motion-viewport.tsx +++ b/03_source/frontend/src/components/animate/motion-viewport.tsx @@ -1,11 +1,8 @@ -import type { MotionProps } from 'framer-motion'; import type { BoxProps } from '@mui/material/Box'; - -import { m } from 'framer-motion'; - import Box from '@mui/material/Box'; import useMediaQuery from '@mui/material/useMediaQuery'; - +import type { MotionProps } from 'framer-motion'; +import { m } from 'framer-motion'; import { varContainer } from './variants'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/animate/scroll-progress/scroll-progress.tsx b/03_source/frontend/src/components/animate/scroll-progress/scroll-progress.tsx index 18b408c..9cd8634 100644 --- a/03_source/frontend/src/components/animate/scroll-progress/scroll-progress.tsx +++ b/03_source/frontend/src/components/animate/scroll-progress/scroll-progress.tsx @@ -1,15 +1,12 @@ import type { BoxProps } from '@mui/material/Box'; -import type { Theme, SxProps } from '@mui/material/styles'; -import type { MotionValue, MotionProps } from 'framer-motion'; - -import { Fragment } from 'react'; -import { mergeClasses } from 'minimal-shared/utils'; -import { m, useSpring, useTransform } from 'framer-motion'; - import Box from '@mui/material/Box'; import Portal from '@mui/material/Portal'; +import type { SxProps, Theme } from '@mui/material/styles'; import { styled, useTheme } from '@mui/material/styles'; - +import type { MotionProps, MotionValue } from 'framer-motion'; +import { m, useSpring, useTransform } from 'framer-motion'; +import { mergeClasses } from 'minimal-shared/utils'; +import { Fragment } from 'react'; import { createClasses } from 'src/theme/create-classes'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/animate/scroll-progress/use-scroll-progress.ts b/03_source/frontend/src/components/animate/scroll-progress/use-scroll-progress.ts index 210c8a1..f02fcd6 100644 --- a/03_source/frontend/src/components/animate/scroll-progress/use-scroll-progress.ts +++ b/03_source/frontend/src/components/animate/scroll-progress/use-scroll-progress.ts @@ -1,7 +1,6 @@ import type { MotionValue } from 'framer-motion'; - -import { useRef, useMemo } from 'react'; import { useScroll } from 'framer-motion'; +import { useMemo, useRef } from 'react'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/animate/variants/background.ts b/03_source/frontend/src/components/animate/variants/background.ts index 1d76340..bdef71c 100644 --- a/03_source/frontend/src/components/animate/variants/background.ts +++ b/03_source/frontend/src/components/animate/variants/background.ts @@ -1,4 +1,4 @@ -import type { Variants, Transition, TargetAndTransition } from 'framer-motion'; +import type { TargetAndTransition, Transition, Variants } from 'framer-motion'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/animate/variants/bounce.ts b/03_source/frontend/src/components/animate/variants/bounce.ts index f1919b6..9fb620b 100644 --- a/03_source/frontend/src/components/animate/variants/bounce.ts +++ b/03_source/frontend/src/components/animate/variants/bounce.ts @@ -1,6 +1,5 @@ -import type { Variants, Transition } from 'framer-motion'; - -import { transitionExit, transitionEnter } from './transition'; +import type { Transition, Variants } from 'framer-motion'; +import { transitionEnter, transitionExit } from './transition'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/animate/variants/container.ts b/03_source/frontend/src/components/animate/variants/container.ts index 83f6f64..b55a4a0 100644 --- a/03_source/frontend/src/components/animate/variants/container.ts +++ b/03_source/frontend/src/components/animate/variants/container.ts @@ -1,4 +1,4 @@ -import type { Variants, Transition } from 'framer-motion'; +import type { Transition, Variants } from 'framer-motion'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/animate/variants/fade.ts b/03_source/frontend/src/components/animate/variants/fade.ts index a4273c5..1ee50a1 100644 --- a/03_source/frontend/src/components/animate/variants/fade.ts +++ b/03_source/frontend/src/components/animate/variants/fade.ts @@ -1,6 +1,5 @@ -import type { Variants, Transition } from 'framer-motion'; - -import { transitionExit, transitionEnter } from './transition'; +import type { Transition, Variants } from 'framer-motion'; +import { transitionEnter, transitionExit } from './transition'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/animate/variants/flip.ts b/03_source/frontend/src/components/animate/variants/flip.ts index 94592b4..3e19f9c 100644 --- a/03_source/frontend/src/components/animate/variants/flip.ts +++ b/03_source/frontend/src/components/animate/variants/flip.ts @@ -1,6 +1,5 @@ -import type { Variants, Transition } from 'framer-motion'; - -import { transitionExit, transitionEnter } from './transition'; +import type { Transition, Variants } from 'framer-motion'; +import { transitionEnter, transitionExit } from './transition'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/animate/variants/path.ts b/03_source/frontend/src/components/animate/variants/path.ts index d3db77c..2bfec05 100644 --- a/03_source/frontend/src/components/animate/variants/path.ts +++ b/03_source/frontend/src/components/animate/variants/path.ts @@ -1,4 +1,4 @@ -import type { Variants, TargetAndTransition } from 'framer-motion'; +import type { TargetAndTransition, Variants } from 'framer-motion'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/animate/variants/rotate.ts b/03_source/frontend/src/components/animate/variants/rotate.ts index 2db4322..f018403 100644 --- a/03_source/frontend/src/components/animate/variants/rotate.ts +++ b/03_source/frontend/src/components/animate/variants/rotate.ts @@ -1,6 +1,5 @@ -import type { Variants, Transition } from 'framer-motion'; - -import { transitionExit, transitionEnter } from './transition'; +import type { Transition, Variants } from 'framer-motion'; +import { transitionEnter, transitionExit } from './transition'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/animate/variants/scale.ts b/03_source/frontend/src/components/animate/variants/scale.ts index 59cca40..1d3f27a 100644 --- a/03_source/frontend/src/components/animate/variants/scale.ts +++ b/03_source/frontend/src/components/animate/variants/scale.ts @@ -1,6 +1,5 @@ -import type { Variants, Transition } from 'framer-motion'; - -import { transitionExit, transitionEnter } from './transition'; +import type { Transition, Variants } from 'framer-motion'; +import { transitionEnter, transitionExit } from './transition'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/animate/variants/slide.ts b/03_source/frontend/src/components/animate/variants/slide.ts index 32c197c..4130c2e 100644 --- a/03_source/frontend/src/components/animate/variants/slide.ts +++ b/03_source/frontend/src/components/animate/variants/slide.ts @@ -1,6 +1,5 @@ -import type { Variants, Transition } from 'framer-motion'; - -import { transitionExit, transitionEnter } from './transition'; +import type { Transition, Variants } from 'framer-motion'; +import { transitionEnter, transitionExit } from './transition'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/animate/variants/zoom.ts b/03_source/frontend/src/components/animate/variants/zoom.ts index 4e57930..305348f 100644 --- a/03_source/frontend/src/components/animate/variants/zoom.ts +++ b/03_source/frontend/src/components/animate/variants/zoom.ts @@ -1,6 +1,5 @@ -import type { Variants, Transition } from 'framer-motion'; - -import { transitionExit, transitionEnter } from './transition'; +import type { Transition, Variants } from 'framer-motion'; +import { transitionEnter, transitionExit } from './transition'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/carousel/carousel.tsx b/03_source/frontend/src/components/carousel/carousel.tsx index 4825026..5d1287d 100644 --- a/03_source/frontend/src/components/carousel/carousel.tsx +++ b/03_source/frontend/src/components/carousel/carousel.tsx @@ -1,12 +1,9 @@ -import { Children, isValidElement } from 'react'; -import { mergeClasses } from 'minimal-shared/utils'; - import { styled } from '@mui/material/styles'; - +import { mergeClasses } from 'minimal-shared/utils'; +import { Children, isValidElement } from 'react'; import { carouselClasses } from './classes'; import { CarouselSlide } from './components/carousel-slide'; - -import type { CarouselProps, CarouselOptions } from './types'; +import type { CarouselOptions, CarouselProps } from './types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/carousel/components/arrow-button.tsx b/03_source/frontend/src/components/carousel/components/arrow-button.tsx index 55c363d..e535e9a 100644 --- a/03_source/frontend/src/components/carousel/components/arrow-button.tsx +++ b/03_source/frontend/src/components/carousel/components/arrow-button.tsx @@ -1,12 +1,9 @@ -import { mergeClasses } from 'minimal-shared/utils'; - -import SvgIcon from '@mui/material/SvgIcon'; -import { styled } from '@mui/material/styles'; import ButtonBase from '@mui/material/ButtonBase'; - +import { styled } from '@mui/material/styles'; +import SvgIcon from '@mui/material/SvgIcon'; +import { mergeClasses } from 'minimal-shared/utils'; import { carouselClasses } from '../classes'; - -import type { CarouselOptions, CarouselArrowButtonProps } from '../types'; +import type { CarouselArrowButtonProps, CarouselOptions } from '../types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/carousel/components/carousel-arrow-buttons.tsx b/03_source/frontend/src/components/carousel/components/carousel-arrow-buttons.tsx index e9d88da..a9e75d9 100644 --- a/03_source/frontend/src/components/carousel/components/carousel-arrow-buttons.tsx +++ b/03_source/frontend/src/components/carousel/components/carousel-arrow-buttons.tsx @@ -1,13 +1,9 @@ import type { Theme } from '@mui/material/styles'; - -import { varAlpha, mergeClasses } from 'minimal-shared/utils'; - import { styled } from '@mui/material/styles'; - -import { ArrowButton } from './arrow-button'; +import { mergeClasses, varAlpha } from 'minimal-shared/utils'; import { carouselClasses } from '../classes'; - import type { CarouselArrowButtonsProps } from '../types'; +import { ArrowButton } from './arrow-button'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/carousel/components/carousel-dot-buttons.tsx b/03_source/frontend/src/components/carousel/components/carousel-dot-buttons.tsx index 71c8bba..b01095d 100644 --- a/03_source/frontend/src/components/carousel/components/carousel-dot-buttons.tsx +++ b/03_source/frontend/src/components/carousel/components/carousel-dot-buttons.tsx @@ -1,13 +1,9 @@ -import type { CSSObject } from '@mui/material/styles'; - -import { varAlpha, mergeClasses } from 'minimal-shared/utils'; - import Box from '@mui/material/Box'; -import { styled } from '@mui/material/styles'; import ButtonBase from '@mui/material/ButtonBase'; - +import type { CSSObject } from '@mui/material/styles'; +import { styled } from '@mui/material/styles'; +import { mergeClasses, varAlpha } from 'minimal-shared/utils'; import { carouselClasses } from '../classes'; - import type { CarouselDotButtonsProps } from '../types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/carousel/components/carousel-progress-bar.tsx b/03_source/frontend/src/components/carousel/components/carousel-progress-bar.tsx index 0eb031e..cf1047d 100644 --- a/03_source/frontend/src/components/carousel/components/carousel-progress-bar.tsx +++ b/03_source/frontend/src/components/carousel/components/carousel-progress-bar.tsx @@ -1,9 +1,6 @@ -import { varAlpha, mergeClasses } from 'minimal-shared/utils'; - import { styled } from '@mui/material/styles'; - +import { mergeClasses, varAlpha } from 'minimal-shared/utils'; import { carouselClasses } from '../classes'; - import type { CarouselProgressBarProps } from '../types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/carousel/components/carousel-slide.tsx b/03_source/frontend/src/components/carousel/components/carousel-slide.tsx index 68ee510..9d1cdad 100644 --- a/03_source/frontend/src/components/carousel/components/carousel-slide.tsx +++ b/03_source/frontend/src/components/carousel/components/carousel-slide.tsx @@ -1,11 +1,8 @@ -import { mergeClasses } from 'minimal-shared/utils'; - import { styled } from '@mui/material/styles'; - -import { getSlideSize } from '../utils'; +import { mergeClasses } from 'minimal-shared/utils'; import { carouselClasses } from '../classes'; - import type { CarouselOptions, CarouselSlideProps } from '../types'; +import { getSlideSize } from '../utils'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/carousel/components/carousel-thumb.tsx b/03_source/frontend/src/components/carousel/components/carousel-thumb.tsx index ef0454c..3809c84 100644 --- a/03_source/frontend/src/components/carousel/components/carousel-thumb.tsx +++ b/03_source/frontend/src/components/carousel/components/carousel-thumb.tsx @@ -1,10 +1,7 @@ -import { mergeClasses } from 'minimal-shared/utils'; - -import { styled } from '@mui/material/styles'; import ButtonBase from '@mui/material/ButtonBase'; - +import { styled } from '@mui/material/styles'; +import { mergeClasses } from 'minimal-shared/utils'; import { carouselClasses } from '../classes'; - import type { CarouselThumbProps } from '../types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/carousel/components/carousel-thumbs.tsx b/03_source/frontend/src/components/carousel/components/carousel-thumbs.tsx index 1bac0c9..a56aa21 100644 --- a/03_source/frontend/src/components/carousel/components/carousel-thumbs.tsx +++ b/03_source/frontend/src/components/carousel/components/carousel-thumbs.tsx @@ -1,12 +1,9 @@ -import { Children, isValidElement } from 'react'; -import { mergeClasses } from 'minimal-shared/utils'; - import { styled } from '@mui/material/styles'; - +import { mergeClasses } from 'minimal-shared/utils'; +import { Children, isValidElement } from 'react'; import { carouselClasses } from '../classes'; -import { CarouselSlide } from './carousel-slide'; - import type { CarouselOptions, CarouselThumbsProps } from '../types'; +import { CarouselSlide } from './carousel-slide'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/carousel/hooks/use-carousel-arrows.ts b/03_source/frontend/src/components/carousel/hooks/use-carousel-arrows.ts index 3ac361f..70a1073 100644 --- a/03_source/frontend/src/components/carousel/hooks/use-carousel-arrows.ts +++ b/03_source/frontend/src/components/carousel/hooks/use-carousel-arrows.ts @@ -1,7 +1,5 @@ import type { EmblaCarouselType } from 'embla-carousel'; - -import { useState, useEffect, useCallback } from 'react'; - +import { useCallback, useEffect, useState } from 'react'; import type { UseCarouselArrowsReturn } from '../types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/carousel/hooks/use-carousel-auto-play.ts b/03_source/frontend/src/components/carousel/hooks/use-carousel-auto-play.ts index 9c64135..7975531 100644 --- a/03_source/frontend/src/components/carousel/hooks/use-carousel-auto-play.ts +++ b/03_source/frontend/src/components/carousel/hooks/use-carousel-auto-play.ts @@ -1,8 +1,6 @@ import type {} from 'embla-carousel-autoplay'; import type { EmblaCarouselType } from 'embla-carousel'; - -import { useState, useEffect, useCallback } from 'react'; - +import { useCallback, useEffect, useState } from 'react'; import type { UseCarouselAutoPlayReturn } from '../types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/carousel/hooks/use-carousel-auto-scroll.ts b/03_source/frontend/src/components/carousel/hooks/use-carousel-auto-scroll.ts index b618818..b7ce2f9 100644 --- a/03_source/frontend/src/components/carousel/hooks/use-carousel-auto-scroll.ts +++ b/03_source/frontend/src/components/carousel/hooks/use-carousel-auto-scroll.ts @@ -1,8 +1,6 @@ import type {} from 'embla-carousel-auto-scroll'; import type { EmblaCarouselType } from 'embla-carousel'; - -import { useState, useEffect, useCallback } from 'react'; - +import { useCallback, useEffect, useState } from 'react'; import type { UseCarouselAutoPlayReturn } from '../types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/carousel/hooks/use-carousel-dots.ts b/03_source/frontend/src/components/carousel/hooks/use-carousel-dots.ts index 72c7786..6397202 100644 --- a/03_source/frontend/src/components/carousel/hooks/use-carousel-dots.ts +++ b/03_source/frontend/src/components/carousel/hooks/use-carousel-dots.ts @@ -1,7 +1,5 @@ import type { EmblaCarouselType } from 'embla-carousel'; - -import { useState, useEffect, useCallback } from 'react'; - +import { useCallback, useEffect, useState } from 'react'; import type { UseCarouselDotsReturn } from '../types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/carousel/hooks/use-carousel-parallax.ts b/03_source/frontend/src/components/carousel/hooks/use-carousel-parallax.ts index 16d0800..5b10e83 100644 --- a/03_source/frontend/src/components/carousel/hooks/use-carousel-parallax.ts +++ b/03_source/frontend/src/components/carousel/hooks/use-carousel-parallax.ts @@ -1,9 +1,6 @@ -import type { EmblaEventType, EmblaCarouselType } from 'embla-carousel'; - -import { useRef, useEffect, useCallback } from 'react'; - +import type { EmblaCarouselType, EmblaEventType } from 'embla-carousel'; +import { useCallback, useEffect, useRef } from 'react'; import { carouselClasses } from '../classes'; - import type { CarouselOptions } from '../types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/carousel/hooks/use-carousel-progress.ts b/03_source/frontend/src/components/carousel/hooks/use-carousel-progress.ts index cff35bf..5c236a6 100644 --- a/03_source/frontend/src/components/carousel/hooks/use-carousel-progress.ts +++ b/03_source/frontend/src/components/carousel/hooks/use-carousel-progress.ts @@ -1,7 +1,5 @@ import type { EmblaCarouselType } from 'embla-carousel'; - -import { useState, useEffect, useCallback } from 'react'; - +import { useCallback, useEffect, useState } from 'react'; import type { UseCarouselProgressReturn } from '../types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/carousel/hooks/use-carousel.ts b/03_source/frontend/src/components/carousel/hooks/use-carousel.ts index df1dc25..d08d5c5 100644 --- a/03_source/frontend/src/components/carousel/hooks/use-carousel.ts +++ b/03_source/frontend/src/components/carousel/hooks/use-carousel.ts @@ -1,19 +1,15 @@ -import type { EmblaPluginType } from 'embla-carousel'; - -import { useMemo } from 'react'; -import useEmblaCarousel from 'embla-carousel-react'; - import { useTheme } from '@mui/material/styles'; - -import { useThumbs } from './use-thumbs'; -import { useCarouselDots } from './use-carousel-dots'; -import { useParallax } from './use-carousel-parallax'; +import type { EmblaPluginType } from 'embla-carousel'; +import useEmblaCarousel from 'embla-carousel-react'; +import { useMemo } from 'react'; +import type { CarouselOptions, UseCarouselReturn } from '../types'; import { useCarouselArrows } from './use-carousel-arrows'; -import { useCarouselProgress } from './use-carousel-progress'; import { useCarouselAutoPlay } from './use-carousel-auto-play'; import { useCarouselAutoScroll } from './use-carousel-auto-scroll'; - -import type { CarouselOptions, UseCarouselReturn } from '../types'; +import { useCarouselDots } from './use-carousel-dots'; +import { useParallax } from './use-carousel-parallax'; +import { useCarouselProgress } from './use-carousel-progress'; +import { useThumbs } from './use-thumbs'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/carousel/hooks/use-thumbs.ts b/03_source/frontend/src/components/carousel/hooks/use-thumbs.ts index 05c9e54..7f26e24 100644 --- a/03_source/frontend/src/components/carousel/hooks/use-thumbs.ts +++ b/03_source/frontend/src/components/carousel/hooks/use-thumbs.ts @@ -1,8 +1,6 @@ import type { EmblaCarouselType } from 'embla-carousel'; - import useEmblaCarousel from 'embla-carousel-react'; -import { useState, useEffect, useCallback } from 'react'; - +import { useCallback, useEffect, useState } from 'react'; import type { CarouselOptions, UseCarouselThumbsReturn } from '../types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/carousel/types.ts b/03_source/frontend/src/components/carousel/types.ts index 5239666..211a9fc 100644 --- a/03_source/frontend/src/components/carousel/types.ts +++ b/03_source/frontend/src/components/carousel/types.ts @@ -1,8 +1,8 @@ import type { BoxProps } from '@mui/material/Box'; import type { ButtonBaseProps } from '@mui/material/ButtonBase'; +import type { Breakpoint, SxProps, Theme } from '@mui/material/styles'; +import type { EmblaCarouselType, EmblaOptionsType } from 'embla-carousel'; import type { UseEmblaCarouselType } from 'embla-carousel-react'; -import type { Theme, SxProps, Breakpoint } from '@mui/material/styles'; -import type { EmblaOptionsType, EmblaCarouselType } from 'embla-carousel'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/carousel/utils.ts b/03_source/frontend/src/components/carousel/utils.ts index 6c0b9de..f48b910 100644 --- a/03_source/frontend/src/components/carousel/utils.ts +++ b/03_source/frontend/src/components/carousel/utils.ts @@ -1,5 +1,4 @@ import type { Breakpoint } from '@mui/material/styles'; - import type { CarouselOptions } from './types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/chart/chart.tsx b/03_source/frontend/src/components/chart/chart.tsx index 1d78f38..c06a13f 100644 --- a/03_source/frontend/src/components/chart/chart.tsx +++ b/03_source/frontend/src/components/chart/chart.tsx @@ -1,12 +1,9 @@ -import { lazy, Suspense } from 'react'; +import { styled } from '@mui/material/styles'; import { useIsClient } from 'minimal-shared/hooks'; import { mergeClasses } from 'minimal-shared/utils'; - -import { styled } from '@mui/material/styles'; - +import { lazy, Suspense } from 'react'; import { chartClasses } from './classes'; import { ChartLoading } from './components'; - import type { ChartProps } from './types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/chart/components/chart-legends.tsx b/03_source/frontend/src/components/chart/components/chart-legends.tsx index ec7c113..7b950cf 100644 --- a/03_source/frontend/src/components/chart/components/chart-legends.tsx +++ b/03_source/frontend/src/components/chart/components/chart-legends.tsx @@ -1,7 +1,5 @@ -import { mergeClasses } from 'minimal-shared/utils'; - import { styled } from '@mui/material/styles'; - +import { mergeClasses } from 'minimal-shared/utils'; import { chartClasses } from '../classes'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/chart/components/chart-loading.tsx b/03_source/frontend/src/components/chart/components/chart-loading.tsx index f4e031e..df67c05 100644 --- a/03_source/frontend/src/components/chart/components/chart-loading.tsx +++ b/03_source/frontend/src/components/chart/components/chart-loading.tsx @@ -1,12 +1,8 @@ import type { BoxProps } from '@mui/material/Box'; - -import { mergeClasses } from 'minimal-shared/utils'; - import Box from '@mui/material/Box'; import Skeleton from '@mui/material/Skeleton'; - +import { mergeClasses } from 'minimal-shared/utils'; import { chartClasses } from '../classes'; - import type { ChartProps } from '../types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/chart/components/chart-select.tsx b/03_source/frontend/src/components/chart/components/chart-select.tsx index 1631cb3..4eebc20 100644 --- a/03_source/frontend/src/components/chart/components/chart-select.tsx +++ b/03_source/frontend/src/components/chart/components/chart-select.tsx @@ -1,16 +1,12 @@ import type { ButtonBaseProps } from '@mui/material/ButtonBase'; - -import { varAlpha } from 'minimal-shared/utils'; -import { usePopover } from 'minimal-shared/hooks'; - -import MenuList from '@mui/material/MenuList'; -import MenuItem from '@mui/material/MenuItem'; import ButtonBase from '@mui/material/ButtonBase'; - -import { Iconify } from '../../iconify'; +import MenuItem from '@mui/material/MenuItem'; +import MenuList from '@mui/material/MenuList'; +import { usePopover } from 'minimal-shared/hooks'; +import { varAlpha } from 'minimal-shared/utils'; import { CustomPopover } from '../../custom-popover'; - import type { CustomPopoverProps } from '../../custom-popover'; +import { Iconify } from '../../iconify'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/chart/types.ts b/03_source/frontend/src/components/chart/types.ts index 0e3922a..46c9d65 100644 --- a/03_source/frontend/src/components/chart/types.ts +++ b/03_source/frontend/src/components/chart/types.ts @@ -1,4 +1,4 @@ -import type { Theme, SxProps } from '@mui/material/styles'; +import type { SxProps, Theme } from '@mui/material/styles'; import type { Props as ApexProps } from 'react-apexcharts'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/chart/use-chart.ts b/03_source/frontend/src/components/chart/use-chart.ts index 2deca76..95b4d56 100644 --- a/03_source/frontend/src/components/chart/use-chart.ts +++ b/03_source/frontend/src/components/chart/use-chart.ts @@ -1,10 +1,7 @@ import type { Theme } from '@mui/material/styles'; - +import { useTheme } from '@mui/material/styles'; import { merge } from 'es-toolkit'; import { varAlpha } from 'minimal-shared/utils'; - -import { useTheme } from '@mui/material/styles'; - import type { ChartOptions } from './types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/color-utils/color-picker.tsx b/03_source/frontend/src/components/color-utils/color-picker.tsx index 2dc3efe..e06b4fa 100644 --- a/03_source/frontend/src/components/color-utils/color-picker.tsx +++ b/03_source/frontend/src/components/color-utils/color-picker.tsx @@ -1,11 +1,8 @@ -import type { Theme, SxProps } from '@mui/material/styles'; - -import { useCallback } from 'react'; -import { varAlpha, mergeClasses } from 'minimal-shared/utils'; - import ButtonBase from '@mui/material/ButtonBase'; -import { styled, alpha as hexAlpha } from '@mui/material/styles'; - +import type { SxProps, Theme } from '@mui/material/styles'; +import { alpha as hexAlpha, styled } from '@mui/material/styles'; +import { mergeClasses, varAlpha } from 'minimal-shared/utils'; +import { useCallback } from 'react'; import { Iconify } from '../iconify'; import { colorPickerClasses } from './classes'; diff --git a/03_source/frontend/src/components/color-utils/color-preview.tsx b/03_source/frontend/src/components/color-utils/color-preview.tsx index f485ad2..e6d1d7b 100644 --- a/03_source/frontend/src/components/color-utils/color-preview.tsx +++ b/03_source/frontend/src/components/color-utils/color-preview.tsx @@ -1,7 +1,5 @@ -import { varAlpha, mergeClasses } from 'minimal-shared/utils'; - import { styled } from '@mui/material/styles'; - +import { mergeClasses, varAlpha } from 'minimal-shared/utils'; import { colorPreviewClasses } from './classes'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/country-select/country-select.tsx b/03_source/frontend/src/components/country-select/country-select.tsx index 8e84045..2fcd2d4 100644 --- a/03_source/frontend/src/components/country-select/country-select.tsx +++ b/03_source/frontend/src/components/country-select/country-select.tsx @@ -1,21 +1,17 @@ -import type { TextFieldProps } from '@mui/material/TextField'; import type { AutocompleteProps, - AutocompleteRenderInputParams, AutocompleteRenderGetTagProps, + AutocompleteRenderInputParams, } from '@mui/material/Autocomplete'; - -import { useMemo, useCallback } from 'react'; - -import Chip from '@mui/material/Chip'; -import TextField from '@mui/material/TextField'; import Autocomplete from '@mui/material/Autocomplete'; -import InputAdornment from '@mui/material/InputAdornment'; +import Chip from '@mui/material/Chip'; import { filledInputClasses } from '@mui/material/FilledInput'; +import InputAdornment from '@mui/material/InputAdornment'; import { outlinedInputClasses } from '@mui/material/OutlinedInput'; - +import type { TextFieldProps } from '@mui/material/TextField'; +import TextField from '@mui/material/TextField'; +import { useCallback, useMemo } from 'react'; import { countries } from 'src/assets/data'; - import { FlagIcon, flagIconClasses } from '../flag-icon'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/custom-breadcrumbs/back-link.tsx b/03_source/frontend/src/components/custom-breadcrumbs/back-link.tsx index b50cbbd..a96f1fc 100644 --- a/03_source/frontend/src/components/custom-breadcrumbs/back-link.tsx +++ b/03_source/frontend/src/components/custom-breadcrumbs/back-link.tsx @@ -1,9 +1,6 @@ import type { LinkProps } from '@mui/material/Link'; - import Link from '@mui/material/Link'; - import { RouterLink } from 'src/routes/components'; - import { Iconify, iconifyClasses } from '../iconify'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/custom-breadcrumbs/breadcrumb-link.tsx b/03_source/frontend/src/components/custom-breadcrumbs/breadcrumb-link.tsx index b74d904..927f80f 100644 --- a/03_source/frontend/src/components/custom-breadcrumbs/breadcrumb-link.tsx +++ b/03_source/frontend/src/components/custom-breadcrumbs/breadcrumb-link.tsx @@ -1,8 +1,6 @@ -import type { Theme, SxProps } from '@mui/material/styles'; - import Link from '@mui/material/Link'; +import type { SxProps, Theme } from '@mui/material/styles'; import { styled } from '@mui/material/styles'; - import { RouterLink } from 'src/routes/components'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/custom-breadcrumbs/custom-breadcrumbs.tsx b/03_source/frontend/src/components/custom-breadcrumbs/custom-breadcrumbs.tsx index 277ce12..99b88c7 100644 --- a/03_source/frontend/src/components/custom-breadcrumbs/custom-breadcrumbs.tsx +++ b/03_source/frontend/src/components/custom-breadcrumbs/custom-breadcrumbs.tsx @@ -1,22 +1,19 @@ -import type { Theme, SxProps } from '@mui/material/styles'; import type { BreadcrumbsProps } from '@mui/material/Breadcrumbs'; - import Breadcrumbs from '@mui/material/Breadcrumbs'; - +import type { SxProps, Theme } from '@mui/material/styles'; import { BackLink } from './back-link'; -import { MoreLinks } from './more-links'; import { BreadcrumbsLink } from './breadcrumb-link'; +import type { BreadcrumbsLinkProps } from './breadcrumb-link'; +import { MoreLinks } from './more-links'; +import type { MoreLinksProps } from './more-links'; import { - BreadcrumbsRoot, - BreadcrumbsHeading, - BreadcrumbsContent, BreadcrumbsContainer, + BreadcrumbsContent, + BreadcrumbsHeading, + BreadcrumbsRoot, BreadcrumbsSeparator, } from './styles'; -import type { MoreLinksProps } from './more-links'; -import type { BreadcrumbsLinkProps } from './breadcrumb-link'; - // ---------------------------------------------------------------------- export type CustomBreadcrumbsSlotProps = { diff --git a/03_source/frontend/src/components/custom-date-range-picker/custom-date-range-picker.tsx b/03_source/frontend/src/components/custom-date-range-picker/custom-date-range-picker.tsx index d37221f..8429b31 100644 --- a/03_source/frontend/src/components/custom-date-range-picker/custom-date-range-picker.tsx +++ b/03_source/frontend/src/components/custom-date-range-picker/custom-date-range-picker.tsx @@ -1,20 +1,17 @@ import type { PaperProps } from '@mui/material'; -import type { DialogProps } from '@mui/material/Dialog'; -import type { Theme, SxProps } from '@mui/material/styles'; - -import { useCallback } from 'react'; - import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; +import type { DialogProps } from '@mui/material/Dialog'; import Dialog from '@mui/material/Dialog'; -import DialogTitle from '@mui/material/DialogTitle'; import DialogActions from '@mui/material/DialogActions'; import DialogContent from '@mui/material/DialogContent'; -import useMediaQuery from '@mui/material/useMediaQuery'; +import DialogTitle from '@mui/material/DialogTitle'; import FormHelperText from '@mui/material/FormHelperText'; -import { DatePicker } from '@mui/x-date-pickers/DatePicker'; +import type { SxProps, Theme } from '@mui/material/styles'; +import useMediaQuery from '@mui/material/useMediaQuery'; import { DateCalendar } from '@mui/x-date-pickers/DateCalendar'; - +import { DatePicker } from '@mui/x-date-pickers/DatePicker'; +import { useCallback } from 'react'; import type { UseDateRangePickerReturn } from './use-date-range-picker'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/custom-date-range-picker/use-date-range-picker.ts b/03_source/frontend/src/components/custom-date-range-picker/use-date-range-picker.ts index 68e893f..3ca385e 100644 --- a/03_source/frontend/src/components/custom-date-range-picker/use-date-range-picker.ts +++ b/03_source/frontend/src/components/custom-date-range-picker/use-date-range-picker.ts @@ -1,8 +1,6 @@ +import { useCallback, useState } from 'react'; import type { IDatePickerControl } from 'src/types/common'; - -import { useState, useCallback } from 'react'; - -import { fIsAfter, fDateRangeShortLabel } from 'src/utils/format-time'; +import { fDateRangeShortLabel, fIsAfter } from 'src/utils/format-time'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/custom-popover/custom-popover.tsx b/03_source/frontend/src/components/custom-popover/custom-popover.tsx index 5e99279..7af92dd 100644 --- a/03_source/frontend/src/components/custom-popover/custom-popover.tsx +++ b/03_source/frontend/src/components/custom-popover/custom-popover.tsx @@ -1,11 +1,9 @@ -import Popover from '@mui/material/Popover'; import { listClasses } from '@mui/material/List'; import { menuItemClasses } from '@mui/material/MenuItem'; - +import Popover from '@mui/material/Popover'; import { Arrow } from './styles'; -import { calculateAnchorOrigin } from './utils'; - import type { CustomPopoverProps } from './types'; +import { calculateAnchorOrigin } from './utils'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/custom-popover/styles.tsx b/03_source/frontend/src/components/custom-popover/styles.tsx index 3dcd3b9..04da6cf 100644 --- a/03_source/frontend/src/components/custom-popover/styles.tsx +++ b/03_source/frontend/src/components/custom-popover/styles.tsx @@ -1,9 +1,6 @@ -import type { Theme, CSSObject } from '@mui/material/styles'; - -import { varAlpha } from 'minimal-shared/utils'; - +import type { CSSObject, Theme } from '@mui/material/styles'; import { styled } from '@mui/material/styles'; - +import { varAlpha } from 'minimal-shared/utils'; import type { PopoverArrow } from './types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/custom-popover/types.ts b/03_source/frontend/src/components/custom-popover/types.ts index b7a96d4..5a57c83 100644 --- a/03_source/frontend/src/components/custom-popover/types.ts +++ b/03_source/frontend/src/components/custom-popover/types.ts @@ -1,6 +1,6 @@ import type { PaperProps } from '@mui/material/Paper'; import type { PopoverProps } from '@mui/material/Popover'; -import type { Theme, SxProps } from '@mui/material/styles'; +import type { SxProps, Theme } from '@mui/material/styles'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/custom-popover/utils.ts b/03_source/frontend/src/components/custom-popover/utils.ts index ca4eefd..f47c63e 100644 --- a/03_source/frontend/src/components/custom-popover/utils.ts +++ b/03_source/frontend/src/components/custom-popover/utils.ts @@ -1,6 +1,5 @@ -import type { CSSObject } from '@mui/material/styles'; import type { PopoverOrigin } from '@mui/material/Popover'; - +import type { CSSObject } from '@mui/material/styles'; import type { PopoverArrow } from './types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/custom-tabs/custom-tabs.tsx b/03_source/frontend/src/components/custom-tabs/custom-tabs.tsx index 954fd1f..1681eb1 100644 --- a/03_source/frontend/src/components/custom-tabs/custom-tabs.tsx +++ b/03_source/frontend/src/components/custom-tabs/custom-tabs.tsx @@ -1,11 +1,9 @@ -import type { TabsProps } from '@mui/material/Tabs'; -import type { Theme, SxProps } from '@mui/material/styles'; - -import { useIsClient } from 'minimal-shared/hooks'; - -import Tabs from '@mui/material/Tabs'; +import type { SxProps, Theme } from '@mui/material/styles'; import { styled } from '@mui/material/styles'; import { tabClasses } from '@mui/material/Tab'; +import type { TabsProps } from '@mui/material/Tabs'; +import Tabs from '@mui/material/Tabs'; +import { useIsClient } from 'minimal-shared/hooks'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/editor/components/code-highlight-block.tsx b/03_source/frontend/src/components/editor/components/code-highlight-block.tsx index 1d186db..3518d81 100644 --- a/03_source/frontend/src/components/editor/components/code-highlight-block.tsx +++ b/03_source/frontend/src/components/editor/components/code-highlight-block.tsx @@ -1,9 +1,6 @@ import './code-highlight-block.css'; - import type { NodeViewProps } from '@tiptap/react'; - import { NodeViewContent, NodeViewWrapper } from '@tiptap/react'; - import { editorClasses } from '../classes'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/editor/components/heading-block.tsx b/03_source/frontend/src/components/editor/components/heading-block.tsx index 1ed02f0..a54279a 100644 --- a/03_source/frontend/src/components/editor/components/heading-block.tsx +++ b/03_source/frontend/src/components/editor/components/heading-block.tsx @@ -1,14 +1,11 @@ -import { useState } from 'react'; -import { varAlpha } from 'minimal-shared/utils'; - -import Menu from '@mui/material/Menu'; -import { listClasses } from '@mui/material/List'; import ButtonBase, { buttonBaseClasses } from '@mui/material/ButtonBase'; - +import { listClasses } from '@mui/material/List'; +import Menu from '@mui/material/Menu'; +import { varAlpha } from 'minimal-shared/utils'; +import { useState } from 'react'; import { Iconify } from '../../iconify'; -import { ToolbarItem } from './toolbar-item'; - import type { EditorToolbarProps } from '../types'; +import { ToolbarItem } from './toolbar-item'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/editor/components/image-block.tsx b/03_source/frontend/src/components/editor/components/image-block.tsx index b77d9c5..4c9659a 100644 --- a/03_source/frontend/src/components/editor/components/image-block.tsx +++ b/03_source/frontend/src/components/editor/components/image-block.tsx @@ -1,15 +1,12 @@ -import { useState, useCallback } from 'react'; - import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; import Popover from '@mui/material/Popover'; import TextField from '@mui/material/TextField'; import Typography from '@mui/material/Typography'; - +import { useCallback, useState } from 'react'; import { editorClasses } from '../classes'; -import { ToolbarItem } from './toolbar-item'; - import type { EditorToolbarProps } from '../types'; +import { ToolbarItem } from './toolbar-item'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/editor/components/link-block.tsx b/03_source/frontend/src/components/editor/components/link-block.tsx index 202a7d4..91e660d 100644 --- a/03_source/frontend/src/components/editor/components/link-block.tsx +++ b/03_source/frontend/src/components/editor/components/link-block.tsx @@ -1,15 +1,12 @@ -import { useState, useCallback } from 'react'; - import Box from '@mui/material/Box'; import Button from '@mui/material/Button'; import Popover from '@mui/material/Popover'; import TextField from '@mui/material/TextField'; import Typography from '@mui/material/Typography'; - +import { useCallback, useState } from 'react'; import { editorClasses } from '../classes'; -import { ToolbarItem } from './toolbar-item'; - import type { EditorToolbarProps } from '../types'; +import { ToolbarItem } from './toolbar-item'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/editor/components/toolbar-item.tsx b/03_source/frontend/src/components/editor/components/toolbar-item.tsx index 5bfbf63..72bed91 100644 --- a/03_source/frontend/src/components/editor/components/toolbar-item.tsx +++ b/03_source/frontend/src/components/editor/components/toolbar-item.tsx @@ -1,7 +1,6 @@ -import SvgIcon from '@mui/material/SvgIcon'; -import { styled } from '@mui/material/styles'; import ButtonBase from '@mui/material/ButtonBase'; - +import { styled } from '@mui/material/styles'; +import SvgIcon from '@mui/material/SvgIcon'; import type { EditorToolbarItemProps } from '../types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/editor/editor.tsx b/03_source/frontend/src/components/editor/editor.tsx index e6e79b6..e4a8534 100644 --- a/03_source/frontend/src/components/editor/editor.tsx +++ b/03_source/frontend/src/components/editor/editor.tsx @@ -1,25 +1,22 @@ -import { common, createLowlight } from 'lowlight'; -import LinkExtension from '@tiptap/extension-link'; -import Underline from '@tiptap/extension-underline'; -import { mergeClasses } from 'minimal-shared/utils'; -import ImageExtension from '@tiptap/extension-image'; -import StarterKitExtension from '@tiptap/starter-kit'; -import { useState, useEffect, useCallback } from 'react'; -import TextAlignExtension from '@tiptap/extension-text-align'; -import PlaceholderExtension from '@tiptap/extension-placeholder'; -import CodeBlockLowlightExtension from '@tiptap/extension-code-block-lowlight'; -import { useEditor, EditorContent, ReactNodeViewRenderer } from '@tiptap/react'; - -import Box from '@mui/material/Box'; -import Portal from '@mui/material/Portal'; import Backdrop from '@mui/material/Backdrop'; +import Box from '@mui/material/Box'; import FormHelperText from '@mui/material/FormHelperText'; - -import { Toolbar } from './toolbar'; -import { EditorRoot } from './styles'; +import Portal from '@mui/material/Portal'; +import CodeBlockLowlightExtension from '@tiptap/extension-code-block-lowlight'; +import ImageExtension from '@tiptap/extension-image'; +import LinkExtension from '@tiptap/extension-link'; +import PlaceholderExtension from '@tiptap/extension-placeholder'; +import TextAlignExtension from '@tiptap/extension-text-align'; +import Underline from '@tiptap/extension-underline'; +import { EditorContent, ReactNodeViewRenderer, useEditor } from '@tiptap/react'; +import StarterKitExtension from '@tiptap/starter-kit'; +import { common, createLowlight } from 'lowlight'; +import { mergeClasses } from 'minimal-shared/utils'; +import { useCallback, useEffect, useState } from 'react'; import { editorClasses } from './classes'; import { CodeHighlightBlock } from './components/code-highlight-block'; - +import { EditorRoot } from './styles'; +import { Toolbar } from './toolbar'; import type { EditorProps } from './types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/editor/styles.tsx b/03_source/frontend/src/components/editor/styles.tsx index aca2654..ccbb852 100644 --- a/03_source/frontend/src/components/editor/styles.tsx +++ b/03_source/frontend/src/components/editor/styles.tsx @@ -1,7 +1,5 @@ -import { varAlpha } from 'minimal-shared/utils'; - import { styled } from '@mui/material/styles'; - +import { varAlpha } from 'minimal-shared/utils'; import { editorClasses } from './classes'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/editor/toolbar.tsx b/03_source/frontend/src/components/editor/toolbar.tsx index 348c9e6..b56b8e9 100644 --- a/03_source/frontend/src/components/editor/toolbar.tsx +++ b/03_source/frontend/src/components/editor/toolbar.tsx @@ -1,18 +1,14 @@ -import type { StackProps } from '@mui/material/Stack'; -import type { Theme, SxProps } from '@mui/material/styles'; - -import { varAlpha } from 'minimal-shared/utils'; - import Box from '@mui/material/Box'; -import Stack from '@mui/material/Stack'; import Divider from '@mui/material/Divider'; - +import type { StackProps } from '@mui/material/Stack'; +import Stack from '@mui/material/Stack'; +import type { SxProps, Theme } from '@mui/material/styles'; +import { varAlpha } from 'minimal-shared/utils'; import { editorClasses } from './classes'; -import { LinkBlock } from './components/link-block'; -import { ImageBlock } from './components/image-block'; -import { ToolbarItem } from './components/toolbar-item'; import { HeadingBlock } from './components/heading-block'; - +import { ImageBlock } from './components/image-block'; +import { LinkBlock } from './components/link-block'; +import { ToolbarItem } from './components/toolbar-item'; import type { EditorToolbarProps } from './types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/editor/types.ts b/03_source/frontend/src/components/editor/types.ts index bd2ac2e..f2882068 100644 --- a/03_source/frontend/src/components/editor/types.ts +++ b/03_source/frontend/src/components/editor/types.ts @@ -1,7 +1,7 @@ import type { BoxProps } from '@mui/material/Box'; -import type { Theme, SxProps } from '@mui/material/styles'; -import type { Editor, EditorOptions } from '@tiptap/react'; import type { ButtonBaseProps } from '@mui/material/ButtonBase'; +import type { SxProps, Theme } from '@mui/material/styles'; +import type { Editor, EditorOptions } from '@tiptap/react'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/empty-content/empty-content.tsx b/03_source/frontend/src/components/empty-content/empty-content.tsx index dc189e7..5a163a5 100644 --- a/03_source/frontend/src/components/empty-content/empty-content.tsx +++ b/03_source/frontend/src/components/empty-content/empty-content.tsx @@ -1,13 +1,10 @@ import type { BoxProps } from '@mui/material/Box'; -import type { Theme, SxProps } from '@mui/material/styles'; -import type { TypographyProps } from '@mui/material/Typography'; - -import { varAlpha } from 'minimal-shared/utils'; - import Box from '@mui/material/Box'; +import type { SxProps, Theme } from '@mui/material/styles'; import { styled } from '@mui/material/styles'; +import type { TypographyProps } from '@mui/material/Typography'; import Typography from '@mui/material/Typography'; - +import { varAlpha } from 'minimal-shared/utils'; import { CONFIG } from 'src/global-config'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/file-thumbnail/action-buttons.tsx b/03_source/frontend/src/components/file-thumbnail/action-buttons.tsx index b3464f9..6a17989 100644 --- a/03_source/frontend/src/components/file-thumbnail/action-buttons.tsx +++ b/03_source/frontend/src/components/file-thumbnail/action-buttons.tsx @@ -1,11 +1,8 @@ import type { ButtonBaseProps } from '@mui/material/ButtonBase'; -import type { IconButtonProps } from '@mui/material/IconButton'; - -import { varAlpha } from 'minimal-shared/utils'; - import ButtonBase from '@mui/material/ButtonBase'; +import type { IconButtonProps } from '@mui/material/IconButton'; import IconButton from '@mui/material/IconButton'; - +import { varAlpha } from 'minimal-shared/utils'; import { Iconify } from '../iconify'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/file-thumbnail/types.ts b/03_source/frontend/src/components/file-thumbnail/types.ts index 12572ad..16ce812 100644 --- a/03_source/frontend/src/components/file-thumbnail/types.ts +++ b/03_source/frontend/src/components/file-thumbnail/types.ts @@ -1,7 +1,7 @@ -import type { TooltipProps } from '@mui/material/Tooltip'; -import type { Theme, SxProps } from '@mui/material/styles'; import type { ButtonBaseProps } from '@mui/material/ButtonBase'; import type { IconButtonProps } from '@mui/material/IconButton'; +import type { SxProps, Theme } from '@mui/material/styles'; +import type { TooltipProps } from '@mui/material/Tooltip'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/file-thumbnail/utils.ts b/03_source/frontend/src/components/file-thumbnail/utils.ts index 8df5b1f..64fd9f3 100644 --- a/03_source/frontend/src/components/file-thumbnail/utils.ts +++ b/03_source/frontend/src/components/file-thumbnail/utils.ts @@ -1,5 +1,4 @@ import { CONFIG } from 'src/global-config'; - import type { ExtendFile } from './types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/filters-result/filters-block.tsx b/03_source/frontend/src/components/filters-result/filters-block.tsx index d57e7b4..3c1cef2 100644 --- a/03_source/frontend/src/components/filters-result/filters-block.tsx +++ b/03_source/frontend/src/components/filters-result/filters-block.tsx @@ -1,5 +1,4 @@ -import type { Theme, SxProps } from '@mui/material/styles'; - +import type { SxProps, Theme } from '@mui/material/styles'; import { styled } from '@mui/material/styles'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/filters-result/filters-result.tsx b/03_source/frontend/src/components/filters-result/filters-result.tsx index eb1b34f..f03bc93 100644 --- a/03_source/frontend/src/components/filters-result/filters-result.tsx +++ b/03_source/frontend/src/components/filters-result/filters-result.tsx @@ -1,9 +1,7 @@ -import type { ChipProps } from '@mui/material/Chip'; -import type { Theme, SxProps } from '@mui/material/styles'; - import Button from '@mui/material/Button'; +import type { ChipProps } from '@mui/material/Chip'; +import type { SxProps, Theme } from '@mui/material/styles'; import { styled } from '@mui/material/styles'; - import { Iconify } from '../iconify'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/flag-icon/flag-icon.tsx b/03_source/frontend/src/components/flag-icon/flag-icon.tsx index cc34bd0..553fdca 100644 --- a/03_source/frontend/src/components/flag-icon/flag-icon.tsx +++ b/03_source/frontend/src/components/flag-icon/flag-icon.tsx @@ -1,7 +1,5 @@ -import { mergeClasses } from 'minimal-shared/utils'; - import { styled } from '@mui/material/styles'; - +import { mergeClasses } from 'minimal-shared/utils'; import { flagIconClasses } from './classes'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/hook-form/form-provider.tsx b/03_source/frontend/src/components/hook-form/form-provider.tsx index b91d4ee..a1d1cc9 100644 --- a/03_source/frontend/src/components/hook-form/form-provider.tsx +++ b/03_source/frontend/src/components/hook-form/form-provider.tsx @@ -1,5 +1,4 @@ import type { UseFormReturn } from 'react-hook-form'; - import { FormProvider as RHFForm } from 'react-hook-form'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/hook-form/help-text.tsx b/03_source/frontend/src/components/hook-form/help-text.tsx index 6843454..24e8028 100644 --- a/03_source/frontend/src/components/hook-form/help-text.tsx +++ b/03_source/frontend/src/components/hook-form/help-text.tsx @@ -1,5 +1,4 @@ import type { FormHelperTextProps } from '@mui/material/FormHelperText'; - import FormHelperText from '@mui/material/FormHelperText'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/hook-form/rhf-autocomplete.tsx b/03_source/frontend/src/components/hook-form/rhf-autocomplete.tsx index ed0dd29..2fbcf7a 100644 --- a/03_source/frontend/src/components/hook-form/rhf-autocomplete.tsx +++ b/03_source/frontend/src/components/hook-form/rhf-autocomplete.tsx @@ -1,10 +1,8 @@ -import type { TextFieldProps } from '@mui/material/TextField'; import type { AutocompleteProps } from '@mui/material/Autocomplete'; - -import { Controller, useFormContext } from 'react-hook-form'; - -import TextField from '@mui/material/TextField'; import Autocomplete from '@mui/material/Autocomplete'; +import type { TextFieldProps } from '@mui/material/TextField'; +import TextField from '@mui/material/TextField'; +import { Controller, useFormContext } from 'react-hook-form'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/hook-form/rhf-checkbox.tsx b/03_source/frontend/src/components/hook-form/rhf-checkbox.tsx index e64b128..36d9c7e 100644 --- a/03_source/frontend/src/components/hook-form/rhf-checkbox.tsx +++ b/03_source/frontend/src/components/hook-form/rhf-checkbox.tsx @@ -1,20 +1,17 @@ import type { BoxProps } from '@mui/material/Box'; -import type { CheckboxProps } from '@mui/material/Checkbox'; -import type { FormGroupProps } from '@mui/material/FormGroup'; -import type { FormLabelProps } from '@mui/material/FormLabel'; -import type { FormControlProps } from '@mui/material/FormControl'; -import type { FormHelperTextProps } from '@mui/material/FormHelperText'; -import type { FormControlLabelProps } from '@mui/material/FormControlLabel'; - -import { Controller, useFormContext } from 'react-hook-form'; - import Box from '@mui/material/Box'; +import type { CheckboxProps } from '@mui/material/Checkbox'; import Checkbox from '@mui/material/Checkbox'; -import FormGroup from '@mui/material/FormGroup'; -import FormLabel from '@mui/material/FormLabel'; +import type { FormControlProps } from '@mui/material/FormControl'; import FormControl from '@mui/material/FormControl'; +import type { FormControlLabelProps } from '@mui/material/FormControlLabel'; import FormControlLabel from '@mui/material/FormControlLabel'; - +import type { FormGroupProps } from '@mui/material/FormGroup'; +import FormGroup from '@mui/material/FormGroup'; +import type { FormHelperTextProps } from '@mui/material/FormHelperText'; +import type { FormLabelProps } from '@mui/material/FormLabel'; +import FormLabel from '@mui/material/FormLabel'; +import { Controller, useFormContext } from 'react-hook-form'; import { HelperText } from './help-text'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/hook-form/rhf-code.tsx b/03_source/frontend/src/components/hook-form/rhf-code.tsx index 008855e..ccf3fbe 100644 --- a/03_source/frontend/src/components/hook-form/rhf-code.tsx +++ b/03_source/frontend/src/components/hook-form/rhf-code.tsx @@ -1,13 +1,10 @@ import type { BoxProps } from '@mui/material/Box'; -import type { MuiOtpInputProps } from 'mui-one-time-password-input'; +import Box from '@mui/material/Box'; import type { FormHelperTextProps } from '@mui/material/FormHelperText'; - +import { inputBaseClasses } from '@mui/material/InputBase'; +import type { MuiOtpInputProps } from 'mui-one-time-password-input'; import { MuiOtpInput } from 'mui-one-time-password-input'; import { Controller, useFormContext } from 'react-hook-form'; - -import Box from '@mui/material/Box'; -import { inputBaseClasses } from '@mui/material/InputBase'; - import { HelperText } from './help-text'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/hook-form/rhf-country-select.tsx b/03_source/frontend/src/components/hook-form/rhf-country-select.tsx index 5b7a318..081eb18 100644 --- a/03_source/frontend/src/components/hook-form/rhf-country-select.tsx +++ b/03_source/frontend/src/components/hook-form/rhf-country-select.tsx @@ -1,7 +1,5 @@ import { Controller, useFormContext } from 'react-hook-form'; - import { CountrySelect } from '../country-select'; - import type { CountrySelectProps } from '../country-select'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/hook-form/rhf-date-picker.tsx b/03_source/frontend/src/components/hook-form/rhf-date-picker.tsx index bb9c119..434d90c 100644 --- a/03_source/frontend/src/components/hook-form/rhf-date-picker.tsx +++ b/03_source/frontend/src/components/hook-form/rhf-date-picker.tsx @@ -1,14 +1,11 @@ -import type { Dayjs } from 'dayjs'; import type { TextFieldProps } from '@mui/material/TextField'; import type { DatePickerProps } from '@mui/x-date-pickers/DatePicker'; +import { DatePicker } from '@mui/x-date-pickers/DatePicker'; import type { MobileDateTimePickerProps } from '@mui/x-date-pickers/MobileDateTimePicker'; - +import { MobileDateTimePicker } from '@mui/x-date-pickers/MobileDateTimePicker'; +import type { Dayjs } from 'dayjs'; import dayjs from 'dayjs'; import { Controller, useFormContext } from 'react-hook-form'; - -import { DatePicker } from '@mui/x-date-pickers/DatePicker'; -import { MobileDateTimePicker } from '@mui/x-date-pickers/MobileDateTimePicker'; - import { formatPatterns } from 'src/utils/format-time'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/hook-form/rhf-editor.tsx b/03_source/frontend/src/components/hook-form/rhf-editor.tsx index 24e8e34..f2882062 100644 --- a/03_source/frontend/src/components/hook-form/rhf-editor.tsx +++ b/03_source/frontend/src/components/hook-form/rhf-editor.tsx @@ -1,7 +1,5 @@ import { Controller, useFormContext } from 'react-hook-form'; - import { Editor } from '../editor'; - import type { EditorProps } from '../editor'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/hook-form/rhf-number-input.tsx b/03_source/frontend/src/components/hook-form/rhf-number-input.tsx index 36820f2..7f5bb38 100644 --- a/03_source/frontend/src/components/hook-form/rhf-number-input.tsx +++ b/03_source/frontend/src/components/hook-form/rhf-number-input.tsx @@ -1,7 +1,5 @@ import { Controller, useFormContext } from 'react-hook-form'; - import { NumberInput } from '../number-input'; - import type { NumberInputProps } from '../number-input'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/hook-form/rhf-phone-input.tsx b/03_source/frontend/src/components/hook-form/rhf-phone-input.tsx index 5d3d9c0..000df3b 100644 --- a/03_source/frontend/src/components/hook-form/rhf-phone-input.tsx +++ b/03_source/frontend/src/components/hook-form/rhf-phone-input.tsx @@ -1,7 +1,5 @@ import { Controller, useFormContext } from 'react-hook-form'; - import { PhoneInput } from '../phone-input'; - import type { PhoneInputProps } from '../phone-input'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/hook-form/rhf-radio-group.tsx b/03_source/frontend/src/components/hook-form/rhf-radio-group.tsx index 8d3be0f..a3d819e 100644 --- a/03_source/frontend/src/components/hook-form/rhf-radio-group.tsx +++ b/03_source/frontend/src/components/hook-form/rhf-radio-group.tsx @@ -1,17 +1,14 @@ -import type { RadioProps } from '@mui/material/Radio'; -import type { FormLabelProps } from '@mui/material/FormLabel'; -import type { RadioGroupProps } from '@mui/material/RadioGroup'; import type { FormControlProps } from '@mui/material/FormControl'; -import type { FormHelperTextProps } from '@mui/material/FormHelperText'; - -import { Controller, useFormContext } from 'react-hook-form'; - -import Radio from '@mui/material/Radio'; -import FormLabel from '@mui/material/FormLabel'; -import RadioGroup from '@mui/material/RadioGroup'; import FormControl from '@mui/material/FormControl'; import FormControlLabel from '@mui/material/FormControlLabel'; - +import type { FormHelperTextProps } from '@mui/material/FormHelperText'; +import type { FormLabelProps } from '@mui/material/FormLabel'; +import FormLabel from '@mui/material/FormLabel'; +import type { RadioProps } from '@mui/material/Radio'; +import Radio from '@mui/material/Radio'; +import type { RadioGroupProps } from '@mui/material/RadioGroup'; +import RadioGroup from '@mui/material/RadioGroup'; +import { Controller, useFormContext } from 'react-hook-form'; import { HelperText } from './help-text'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/hook-form/rhf-rating.tsx b/03_source/frontend/src/components/hook-form/rhf-rating.tsx index 74d30e4..f76176f 100644 --- a/03_source/frontend/src/components/hook-form/rhf-rating.tsx +++ b/03_source/frontend/src/components/hook-form/rhf-rating.tsx @@ -1,12 +1,9 @@ import type { BoxProps } from '@mui/material/Box'; -import type { RatingProps } from '@mui/material/Rating'; -import type { FormHelperTextProps } from '@mui/material/FormHelperText'; - -import { Controller, useFormContext } from 'react-hook-form'; - import Box from '@mui/material/Box'; +import type { FormHelperTextProps } from '@mui/material/FormHelperText'; +import type { RatingProps } from '@mui/material/Rating'; import Rating from '@mui/material/Rating'; - +import { Controller, useFormContext } from 'react-hook-form'; import { HelperText } from './help-text'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/hook-form/rhf-select.tsx b/03_source/frontend/src/components/hook-form/rhf-select.tsx index d975bad..d1d60b9 100644 --- a/03_source/frontend/src/components/hook-form/rhf-select.tsx +++ b/03_source/frontend/src/components/hook-form/rhf-select.tsx @@ -1,23 +1,20 @@ -import type { ChipProps } from '@mui/material/Chip'; -import type { SelectProps } from '@mui/material/Select'; +import Box from '@mui/material/Box'; import type { CheckboxProps } from '@mui/material/Checkbox'; -import type { TextFieldProps } from '@mui/material/TextField'; -import type { InputLabelProps } from '@mui/material/InputLabel'; +import Checkbox from '@mui/material/Checkbox'; +import type { ChipProps } from '@mui/material/Chip'; +import Chip from '@mui/material/Chip'; import type { FormControlProps } from '@mui/material/FormControl'; +import FormControl from '@mui/material/FormControl'; import type { FormHelperTextProps } from '@mui/material/FormHelperText'; - +import type { InputLabelProps } from '@mui/material/InputLabel'; +import InputLabel from '@mui/material/InputLabel'; +import MenuItem from '@mui/material/MenuItem'; +import type { SelectProps } from '@mui/material/Select'; +import Select from '@mui/material/Select'; +import type { TextFieldProps } from '@mui/material/TextField'; +import TextField from '@mui/material/TextField'; import { merge } from 'es-toolkit'; import { Controller, useFormContext } from 'react-hook-form'; - -import Box from '@mui/material/Box'; -import Chip from '@mui/material/Chip'; -import Select from '@mui/material/Select'; -import MenuItem from '@mui/material/MenuItem'; -import Checkbox from '@mui/material/Checkbox'; -import TextField from '@mui/material/TextField'; -import InputLabel from '@mui/material/InputLabel'; -import FormControl from '@mui/material/FormControl'; - import { HelperText } from './help-text'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/hook-form/rhf-slider.tsx b/03_source/frontend/src/components/hook-form/rhf-slider.tsx index 81c592e..e3e501f 100644 --- a/03_source/frontend/src/components/hook-form/rhf-slider.tsx +++ b/03_source/frontend/src/components/hook-form/rhf-slider.tsx @@ -1,12 +1,9 @@ import type { BoxProps } from '@mui/material/Box'; -import type { SliderProps } from '@mui/material/Slider'; -import type { FormHelperTextProps } from '@mui/material/FormHelperText'; - -import { Controller, useFormContext } from 'react-hook-form'; - import Box from '@mui/material/Box'; +import type { FormHelperTextProps } from '@mui/material/FormHelperText'; +import type { SliderProps } from '@mui/material/Slider'; import Slider from '@mui/material/Slider'; - +import { Controller, useFormContext } from 'react-hook-form'; import { HelperText } from './help-text'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/hook-form/rhf-switch.tsx b/03_source/frontend/src/components/hook-form/rhf-switch.tsx index c3f9a35..6bb301b 100644 --- a/03_source/frontend/src/components/hook-form/rhf-switch.tsx +++ b/03_source/frontend/src/components/hook-form/rhf-switch.tsx @@ -1,20 +1,17 @@ import type { BoxProps } from '@mui/material/Box'; -import type { SwitchProps } from '@mui/material/Switch'; -import type { FormGroupProps } from '@mui/material/FormGroup'; -import type { FormLabelProps } from '@mui/material/FormLabel'; -import type { FormControlProps } from '@mui/material/FormControl'; -import type { FormHelperTextProps } from '@mui/material/FormHelperText'; -import type { FormControlLabelProps } from '@mui/material/FormControlLabel'; - -import { Controller, useFormContext } from 'react-hook-form'; - import Box from '@mui/material/Box'; -import Switch from '@mui/material/Switch'; -import FormGroup from '@mui/material/FormGroup'; -import FormLabel from '@mui/material/FormLabel'; +import type { FormControlProps } from '@mui/material/FormControl'; import FormControl from '@mui/material/FormControl'; +import type { FormControlLabelProps } from '@mui/material/FormControlLabel'; import FormControlLabel from '@mui/material/FormControlLabel'; - +import type { FormGroupProps } from '@mui/material/FormGroup'; +import FormGroup from '@mui/material/FormGroup'; +import type { FormHelperTextProps } from '@mui/material/FormHelperText'; +import type { FormLabelProps } from '@mui/material/FormLabel'; +import FormLabel from '@mui/material/FormLabel'; +import type { SwitchProps } from '@mui/material/Switch'; +import Switch from '@mui/material/Switch'; +import { Controller, useFormContext } from 'react-hook-form'; import { HelperText } from './help-text'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/hook-form/rhf-text-field.tsx b/03_source/frontend/src/components/hook-form/rhf-text-field.tsx index 6d4bc47..0ae06db 100644 --- a/03_source/frontend/src/components/hook-form/rhf-text-field.tsx +++ b/03_source/frontend/src/components/hook-form/rhf-text-field.tsx @@ -1,9 +1,7 @@ import type { TextFieldProps } from '@mui/material/TextField'; - -import { Controller, useFormContext } from 'react-hook-form'; -import { transformValue, transformValueOnBlur, transformValueOnChange } from 'minimal-shared/utils'; - import TextField from '@mui/material/TextField'; +import { transformValue, transformValueOnBlur, transformValueOnChange } from 'minimal-shared/utils'; +import { Controller, useFormContext } from 'react-hook-form'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/hook-form/rhf-upload-avatar.tsx b/03_source/frontend/src/components/hook-form/rhf-upload-avatar.tsx index ac10a79..0234ce1 100644 --- a/03_source/frontend/src/components/hook-form/rhf-upload-avatar.tsx +++ b/03_source/frontend/src/components/hook-form/rhf-upload-avatar.tsx @@ -1,13 +1,9 @@ import type { BoxProps } from '@mui/material/Box'; - -import { Controller, useFormContext } from 'react-hook-form'; - import Box from '@mui/material/Box'; - -import { HelperText } from './help-text'; +import { Controller, useFormContext } from 'react-hook-form'; import { UploadAvatar } from '../upload'; - import type { UploadProps } from '../upload'; +import { HelperText } from './help-text'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/hook-form/rhf-upload-box.tsx b/03_source/frontend/src/components/hook-form/rhf-upload-box.tsx index e949e50..4765bf7 100644 --- a/03_source/frontend/src/components/hook-form/rhf-upload-box.tsx +++ b/03_source/frontend/src/components/hook-form/rhf-upload-box.tsx @@ -1,9 +1,6 @@ import type { BoxProps } from '@mui/material/Box'; - import { Controller, useFormContext } from 'react-hook-form'; - import { UploadBox } from '../upload'; - import type { UploadProps } from '../upload'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/hook-form/rhf-upload.tsx b/03_source/frontend/src/components/hook-form/rhf-upload.tsx index 1a82b0c..d2c8470 100644 --- a/03_source/frontend/src/components/hook-form/rhf-upload.tsx +++ b/03_source/frontend/src/components/hook-form/rhf-upload.tsx @@ -79,6 +79,8 @@ export function RHFUpload({ name, multiple, helperText, ...other }: RHFUploadPro setValue(name, value, { shouldValidate: true }); }; + // return <>{JSON.stringify({ t: field.value })}; + return ; }} /> diff --git a/03_source/frontend/src/components/hook-form/schema-helper.ts b/03_source/frontend/src/components/hook-form/schema-helper.ts index ef20b6e..c75f477 100644 --- a/03_source/frontend/src/components/hook-form/schema-helper.ts +++ b/03_source/frontend/src/components/hook-form/schema-helper.ts @@ -1,6 +1,5 @@ -import type { ZodTypeAny } from 'zod'; - import dayjs from 'dayjs'; +import type { ZodTypeAny } from 'zod'; import { z as zod } from 'zod'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/iconify/iconify.tsx b/03_source/frontend/src/components/iconify/iconify.tsx index 8c18c95..8a1829b 100644 --- a/03_source/frontend/src/components/iconify/iconify.tsx +++ b/03_source/frontend/src/components/iconify/iconify.tsx @@ -1,14 +1,10 @@ import type { IconProps } from '@iconify/react'; - -import { useId } from 'react'; import { Icon } from '@iconify/react'; -import { mergeClasses } from 'minimal-shared/utils'; - import { styled } from '@mui/material/styles'; - +import { mergeClasses } from 'minimal-shared/utils'; +import { useId } from 'react'; import { iconifyClasses } from './classes'; import { allIconNames, registerIcons } from './register-icons'; - import type { IconifyName } from './register-icons'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/iconify/register-icons.ts b/03_source/frontend/src/components/iconify/register-icons.ts index f00575b..470b082 100644 --- a/03_source/frontend/src/components/iconify/register-icons.ts +++ b/03_source/frontend/src/components/iconify/register-icons.ts @@ -1,7 +1,5 @@ import type { IconifyJSON } from '@iconify/react'; - import { addCollection } from '@iconify/react'; - import allIcons from './icon-sets'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/image/image.tsx b/03_source/frontend/src/components/image/image.tsx index b538a02..994e410 100644 --- a/03_source/frontend/src/components/image/image.tsx +++ b/03_source/frontend/src/components/image/image.tsx @@ -1,13 +1,10 @@ -import type { UseInViewOptions } from 'framer-motion'; import type { Breakpoint } from '@mui/material/styles'; - +import type { UseInViewOptions } from 'framer-motion'; import { useInView } from 'framer-motion'; -import { mergeRefs, mergeClasses } from 'minimal-shared/utils'; -import { useRef, useState, useCallback, startTransition } from 'react'; - +import { mergeClasses, mergeRefs } from 'minimal-shared/utils'; +import { startTransition, useCallback, useRef, useState } from 'react'; import { imageClasses } from './classes'; -import { ImageImg, ImageRoot, ImageOverlay, ImagePlaceholder } from './styles'; - +import { ImageImg, ImageOverlay, ImagePlaceholder, ImageRoot } from './styles'; import type { EffectsType } from './styles'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/image/styles.ts b/03_source/frontend/src/components/image/styles.ts index 1149d41..9f7ac16 100644 --- a/03_source/frontend/src/components/image/styles.ts +++ b/03_source/frontend/src/components/image/styles.ts @@ -1,7 +1,5 @@ import type { CSSObject } from '@mui/material/styles'; - import { styled } from '@mui/material/styles'; - import { imageClasses } from './classes'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/label/label.tsx b/03_source/frontend/src/components/label/label.tsx index a2b07d6..c57fa49 100644 --- a/03_source/frontend/src/components/label/label.tsx +++ b/03_source/frontend/src/components/label/label.tsx @@ -1,9 +1,7 @@ import { upperFirst } from 'es-toolkit'; import { mergeClasses } from 'minimal-shared/utils'; - import { labelClasses } from './classes'; -import { LabelRoot, LabelIcon } from './styles'; - +import { LabelIcon, LabelRoot } from './styles'; import type { LabelProps } from './types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/label/styles.tsx b/03_source/frontend/src/components/label/styles.tsx index b266699..0465506 100644 --- a/03_source/frontend/src/components/label/styles.tsx +++ b/03_source/frontend/src/components/label/styles.tsx @@ -1,9 +1,6 @@ import type { CSSObject } from '@mui/material/styles'; - -import { varAlpha } from 'minimal-shared/utils'; - import { styled } from '@mui/material/styles'; - +import { varAlpha } from 'minimal-shared/utils'; import type { LabelProps } from './types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/label/types.ts b/03_source/frontend/src/components/label/types.ts index 4db6635..b7a6676 100644 --- a/03_source/frontend/src/components/label/types.ts +++ b/03_source/frontend/src/components/label/types.ts @@ -1,4 +1,4 @@ -import type { Theme, SxProps } from '@mui/material/styles'; +import type { SxProps, Theme } from '@mui/material/styles'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/lightbox/lightbox.tsx b/03_source/frontend/src/components/lightbox/lightbox.tsx index 3b6faf8..5a95a74 100644 --- a/03_source/frontend/src/components/lightbox/lightbox.tsx +++ b/03_source/frontend/src/components/lightbox/lightbox.tsx @@ -1,13 +1,10 @@ +import Box from '@mui/material/Box'; import { mergeClasses } from 'minimal-shared/utils'; import ReactLightbox, { useLightboxState } from 'yet-another-react-lightbox'; - -import Box from '@mui/material/Box'; - import { Iconify } from '../iconify'; -import { getPlugins } from './utils'; import { lightboxClasses } from './classes'; - import type { LightBoxProps } from './types'; +import { getPlugins } from './utils'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/lightbox/use-light-box.ts b/03_source/frontend/src/components/lightbox/use-light-box.ts index 375d3b6..9507ab8 100644 --- a/03_source/frontend/src/components/lightbox/use-light-box.ts +++ b/03_source/frontend/src/components/lightbox/use-light-box.ts @@ -1,7 +1,6 @@ +import { useCallback, useState } from 'react'; import type { Slide, SlideImage, SlideVideo } from 'yet-another-react-lightbox'; -import { useState, useCallback } from 'react'; - // ---------------------------------------------------------------------- export type UseLightBoxReturn = { diff --git a/03_source/frontend/src/components/lightbox/utils.ts b/03_source/frontend/src/components/lightbox/utils.ts index 11c79ea..0c72354 100644 --- a/03_source/frontend/src/components/lightbox/utils.ts +++ b/03_source/frontend/src/components/lightbox/utils.ts @@ -1,10 +1,9 @@ -import Zoom from 'yet-another-react-lightbox/plugins/zoom'; -import Video from 'yet-another-react-lightbox/plugins/video'; import Captions from 'yet-another-react-lightbox/plugins/captions'; -import Slideshow from 'yet-another-react-lightbox/plugins/slideshow'; import Fullscreen from 'yet-another-react-lightbox/plugins/fullscreen'; +import Slideshow from 'yet-another-react-lightbox/plugins/slideshow'; import Thumbnails from 'yet-another-react-lightbox/plugins/thumbnails'; - +import Video from 'yet-another-react-lightbox/plugins/video'; +import Zoom from 'yet-another-react-lightbox/plugins/zoom'; import type { LightBoxProps } from './types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/loading-screen/loading-screen.tsx b/03_source/frontend/src/components/loading-screen/loading-screen.tsx index f96d17f..2f13954 100644 --- a/03_source/frontend/src/components/loading-screen/loading-screen.tsx +++ b/03_source/frontend/src/components/loading-screen/loading-screen.tsx @@ -1,10 +1,8 @@ -import type { Theme, SxProps } from '@mui/material/styles'; - -import { Fragment } from 'react'; - -import Portal from '@mui/material/Portal'; -import { styled } from '@mui/material/styles'; import LinearProgress from '@mui/material/LinearProgress'; +import Portal from '@mui/material/Portal'; +import type { SxProps, Theme } from '@mui/material/styles'; +import { styled } from '@mui/material/styles'; +import { Fragment } from 'react'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/loading-screen/splash-screen.tsx b/03_source/frontend/src/components/loading-screen/splash-screen.tsx index 813511d..f07d588 100644 --- a/03_source/frontend/src/components/loading-screen/splash-screen.tsx +++ b/03_source/frontend/src/components/loading-screen/splash-screen.tsx @@ -1,10 +1,7 @@ -import type { Theme, SxProps } from '@mui/material/styles'; - -import { Fragment } from 'react'; - import Portal from '@mui/material/Portal'; +import type { SxProps, Theme } from '@mui/material/styles'; import { styled } from '@mui/material/styles'; - +import { Fragment } from 'react'; import { AnimateLogoZoom } from '../animate'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/logo/logo.tsx b/03_source/frontend/src/components/logo/logo.tsx index df3cab2..5fbc2bc 100644 --- a/03_source/frontend/src/components/logo/logo.tsx +++ b/03_source/frontend/src/components/logo/logo.tsx @@ -1,13 +1,9 @@ import type { LinkProps } from '@mui/material/Link'; - -import { useId } from 'react'; -import { mergeClasses } from 'minimal-shared/utils'; - import Link from '@mui/material/Link'; import { styled, useTheme } from '@mui/material/styles'; - +import { mergeClasses } from 'minimal-shared/utils'; +import { useId } from 'react'; import { RouterLink } from 'src/routes/components'; - import { logoClasses } from './classes'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/map/map-controls.tsx b/03_source/frontend/src/components/map/map-controls.tsx index 7bf150b..cda5634 100644 --- a/03_source/frontend/src/components/map/map-controls.tsx +++ b/03_source/frontend/src/components/map/map-controls.tsx @@ -1,15 +1,14 @@ import type { - ScaleControlProps, - GeolocateControlProps, FullscreenControlProps, + GeolocateControlProps, NavigationControlProps, + ScaleControlProps, } from 'react-map-gl/mapbox'; - import { - ScaleControl, + FullscreenControl, GeolocateControl, NavigationControl, - FullscreenControl, + ScaleControl, } from 'react-map-gl/mapbox'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/map/map-marker.tsx b/03_source/frontend/src/components/map/map-marker.tsx index c2f87f1..0afdd11 100644 --- a/03_source/frontend/src/components/map/map-marker.tsx +++ b/03_source/frontend/src/components/map/map-marker.tsx @@ -1,7 +1,5 @@ import type { MarkerProps } from 'react-map-gl/mapbox'; - import { Marker } from 'react-map-gl/mapbox'; - import { Iconify } from '../iconify'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/map/map-popup.tsx b/03_source/frontend/src/components/map/map-popup.tsx index 2cf3654..ead78d4 100644 --- a/03_source/frontend/src/components/map/map-popup.tsx +++ b/03_source/frontend/src/components/map/map-popup.tsx @@ -1,6 +1,5 @@ -import { Popup } from 'react-map-gl/mapbox'; - import { styled } from '@mui/material/styles'; +import { Popup } from 'react-map-gl/mapbox'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/map/map.tsx b/03_source/frontend/src/components/map/map.tsx index 915e248..a9bb886 100644 --- a/03_source/frontend/src/components/map/map.tsx +++ b/03_source/frontend/src/components/map/map.tsx @@ -1,10 +1,7 @@ -import type { Theme, SxProps } from '@mui/material/styles'; -import type { MapRef, MapProps as ReactMapProps } from 'react-map-gl/mapbox'; - -import ReactMap from 'react-map-gl/mapbox'; - +import type { SxProps, Theme } from '@mui/material/styles'; import { styled } from '@mui/material/styles'; - +import type { MapRef, MapProps as ReactMapProps } from 'react-map-gl/mapbox'; +import ReactMap from 'react-map-gl/mapbox'; import { CONFIG } from 'src/global-config'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/markdown/html-to-markdown.ts b/03_source/frontend/src/components/markdown/html-to-markdown.ts index 17fe0a8..d7977e2 100644 --- a/03_source/frontend/src/components/markdown/html-to-markdown.ts +++ b/03_source/frontend/src/components/markdown/html-to-markdown.ts @@ -1,7 +1,5 @@ -import type { Node, Filter } from 'turndown'; - +import type { Filter, Node } from 'turndown'; import TurndownService from 'turndown'; - import { htmlTags } from './html-tags'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/markdown/markdown.tsx b/03_source/frontend/src/components/markdown/markdown.tsx index 5eb7723..80406cb 100644 --- a/03_source/frontend/src/components/markdown/markdown.tsx +++ b/03_source/frontend/src/components/markdown/markdown.tsx @@ -1,23 +1,17 @@ import './code-highlight-block.css'; - -import type { Options } from 'react-markdown'; - +import Link from '@mui/material/Link'; +import { isExternalLink, mergeClasses } from 'minimal-shared/utils'; import { useMemo } from 'react'; -import remarkGfm from 'remark-gfm'; -import rehypeRaw from 'rehype-raw'; +import type { Options } from 'react-markdown'; import ReactMarkdown from 'react-markdown'; import rehypeHighlight from 'rehype-highlight'; -import { mergeClasses, isExternalLink } from 'minimal-shared/utils'; - -import Link from '@mui/material/Link'; - +import rehypeRaw from 'rehype-raw'; +import remarkGfm from 'remark-gfm'; import { RouterLink } from 'src/routes/components'; - import { Image } from '../image'; -import { MarkdownRoot } from './styles'; import { markdownClasses } from './classes'; import { htmlToMarkdown, isMarkdownContent } from './html-to-markdown'; - +import { MarkdownRoot } from './styles'; import type { MarkdownProps } from './types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/markdown/styles.ts b/03_source/frontend/src/components/markdown/styles.ts index bd16887..e5fb1d9 100644 --- a/03_source/frontend/src/components/markdown/styles.ts +++ b/03_source/frontend/src/components/markdown/styles.ts @@ -1,7 +1,5 @@ -import { varAlpha } from 'minimal-shared/utils'; - import { styled } from '@mui/material/styles'; - +import { varAlpha } from 'minimal-shared/utils'; import { markdownClasses } from './classes'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/markdown/types.ts b/03_source/frontend/src/components/markdown/types.ts index de5fe94..42e2cf7 100644 --- a/03_source/frontend/src/components/markdown/types.ts +++ b/03_source/frontend/src/components/markdown/types.ts @@ -1,5 +1,5 @@ +import type { SxProps, Theme } from '@mui/material/styles'; import type { Options } from 'react-markdown'; -import type { Theme, SxProps } from '@mui/material/styles'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/mega-menu/components/nav-carousel.tsx b/03_source/frontend/src/components/mega-menu/components/nav-carousel.tsx index df8995a..4129761 100644 --- a/03_source/frontend/src/components/mega-menu/components/nav-carousel.tsx +++ b/03_source/frontend/src/components/mega-menu/components/nav-carousel.tsx @@ -1,17 +1,14 @@ -import { mergeClasses } from 'minimal-shared/utils'; - import Link from '@mui/material/Link'; import { styled } from '@mui/material/styles'; - -import { Image } from '../../image'; -import { megaMenuClasses } from '../styles'; +import { mergeClasses } from 'minimal-shared/utils'; import { Carousel, - useCarousel, - CarouselDotButtons, CarouselArrowBasicButtons, + CarouselDotButtons, + useCarousel, } from '../../carousel'; - +import { Image } from '../../image'; +import { megaMenuClasses } from '../styles'; import type { NavCarouselProps } from '../types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/mega-menu/components/nav-drawer.tsx b/03_source/frontend/src/components/mega-menu/components/nav-drawer.tsx index 3d48269..e4e49b8 100644 --- a/03_source/frontend/src/components/mega-menu/components/nav-drawer.tsx +++ b/03_source/frontend/src/components/mega-menu/components/nav-drawer.tsx @@ -1,6 +1,5 @@ -import { styled } from '@mui/material/styles'; import IconButton from '@mui/material/IconButton'; - +import { styled } from '@mui/material/styles'; import { Iconify } from '../../iconify'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/mega-menu/components/nav-dropdown-content.tsx b/03_source/frontend/src/components/mega-menu/components/nav-dropdown-content.tsx index 543dd63..ce87e9d 100644 --- a/03_source/frontend/src/components/mega-menu/components/nav-dropdown-content.tsx +++ b/03_source/frontend/src/components/mega-menu/components/nav-dropdown-content.tsx @@ -1,18 +1,15 @@ -import Box from '@mui/material/Box'; -import Link from '@mui/material/Link'; import Masonry from '@mui/lab/Masonry'; +import Box from '@mui/material/Box'; import Divider from '@mui/material/Divider'; +import Link from '@mui/material/Link'; import Typography from '@mui/material/Typography'; - import { RouterLink } from 'src/routes/components'; - -import { NavUl } from './nav-elements'; import { Iconify } from '../../iconify'; -import { NavSubList } from './nav-sub-list'; import { megaMenuClasses } from '../styles'; -import { NavCarousel } from './nav-carousel'; - import type { NavListProps } from '../types'; +import { NavCarousel } from './nav-carousel'; +import { NavUl } from './nav-elements'; +import { NavSubList } from './nav-sub-list'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/mega-menu/components/nav-dropdown.tsx b/03_source/frontend/src/components/mega-menu/components/nav-dropdown.tsx index f118591..9253b06 100644 --- a/03_source/frontend/src/components/mega-menu/components/nav-dropdown.tsx +++ b/03_source/frontend/src/components/mega-menu/components/nav-dropdown.tsx @@ -1,7 +1,5 @@ -import { mergeClasses } from 'minimal-shared/utils'; - import { styled } from '@mui/material/styles'; - +import { mergeClasses } from 'minimal-shared/utils'; import { megaMenuClasses } from '../styles'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/mega-menu/components/nav-elements.tsx b/03_source/frontend/src/components/mega-menu/components/nav-elements.tsx index 5be2d56..4aadd83 100644 --- a/03_source/frontend/src/components/mega-menu/components/nav-elements.tsx +++ b/03_source/frontend/src/components/mega-menu/components/nav-elements.tsx @@ -1,7 +1,5 @@ -import { mergeClasses } from 'minimal-shared/utils'; - import { styled } from '@mui/material/styles'; - +import { mergeClasses } from 'minimal-shared/utils'; import { megaMenuClasses } from '../styles'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/mega-menu/components/nav-item.tsx b/03_source/frontend/src/components/mega-menu/components/nav-item.tsx index 4245d26..e6ffa01 100644 --- a/03_source/frontend/src/components/mega-menu/components/nav-item.tsx +++ b/03_source/frontend/src/components/mega-menu/components/nav-item.tsx @@ -1,13 +1,10 @@ -import { mergeClasses } from 'minimal-shared/utils'; - -import { styled } from '@mui/material/styles'; import ButtonBase from '@mui/material/ButtonBase'; - +import { styled } from '@mui/material/styles'; +import { mergeClasses } from 'minimal-shared/utils'; import { Iconify } from '../../iconify'; -import { createNavItem } from '../utils'; -import { navItemStyles, megaMenuClasses } from '../styles'; - +import { megaMenuClasses, navItemStyles } from '../styles'; import type { NavItemProps } from '../types'; +import { createNavItem } from '../utils'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/mega-menu/horizontal/mega-menu-horizontal.tsx b/03_source/frontend/src/components/mega-menu/horizontal/mega-menu-horizontal.tsx index 1b57964..5454c69 100644 --- a/03_source/frontend/src/components/mega-menu/horizontal/mega-menu-horizontal.tsx +++ b/03_source/frontend/src/components/mega-menu/horizontal/mega-menu-horizontal.tsx @@ -1,12 +1,9 @@ -import { mergeClasses } from 'minimal-shared/utils'; - import { useTheme } from '@mui/material/styles'; - -import { NavList } from './nav-list'; +import { mergeClasses } from 'minimal-shared/utils'; import { Nav, NavUl } from '../components'; -import { megaMenuVars, megaMenuClasses } from '../styles'; - +import { megaMenuClasses, megaMenuVars } from '../styles'; import type { MegaMenuProps } from '../types'; +import { NavList } from './nav-list'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/mega-menu/horizontal/nav-list.tsx b/03_source/frontend/src/components/mega-menu/horizontal/nav-list.tsx index d6fbdab..7fd926e 100644 --- a/03_source/frontend/src/components/mega-menu/horizontal/nav-list.tsx +++ b/03_source/frontend/src/components/mega-menu/horizontal/nav-list.tsx @@ -1,12 +1,9 @@ -import { useRef, useCallback } from 'react'; import { useBoolean } from 'minimal-shared/hooks'; import { isActiveLink, isExternalLink } from 'minimal-shared/utils'; - +import { useCallback, useRef } from 'react'; import { usePathname } from 'src/routes/hooks'; - +import { NavDropdown, NavDropdownContent, NavItem, NavLi } from '../components'; import { megaMenuClasses } from '../styles'; -import { NavLi, NavItem, NavDropdown, NavDropdownContent } from '../components'; - import type { NavListProps } from '../types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/mega-menu/mobile/mega-menu-mobile.tsx b/03_source/frontend/src/components/mega-menu/mobile/mega-menu-mobile.tsx index 92304bf..adb0d57 100644 --- a/03_source/frontend/src/components/mega-menu/mobile/mega-menu-mobile.tsx +++ b/03_source/frontend/src/components/mega-menu/mobile/mega-menu-mobile.tsx @@ -1,20 +1,16 @@ -import { useEffect, cloneElement } from 'react'; +import Drawer, { drawerClasses } from '@mui/material/Drawer'; +import IconButton from '@mui/material/IconButton'; +import { useTheme } from '@mui/material/styles'; import { useBoolean } from 'minimal-shared/hooks'; import { mergeClasses } from 'minimal-shared/utils'; - -import { useTheme } from '@mui/material/styles'; -import IconButton from '@mui/material/IconButton'; -import Drawer, { drawerClasses } from '@mui/material/Drawer'; - +import { cloneElement, useEffect } from 'react'; import { usePathname } from 'src/routes/hooks'; - -import { NavList } from './nav-list'; import { Iconify } from '../../iconify'; -import { Nav, NavUl } from '../components'; import { Scrollbar } from '../../scrollbar'; -import { megaMenuVars, megaMenuClasses } from '../styles'; - +import { Nav, NavUl } from '../components'; +import { megaMenuClasses, megaMenuVars } from '../styles'; import type { MegaMenuProps } from '../types'; +import { NavList } from './nav-list'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/mega-menu/mobile/nav-list.tsx b/03_source/frontend/src/components/mega-menu/mobile/nav-list.tsx index 93e4288..6d30a1e 100644 --- a/03_source/frontend/src/components/mega-menu/mobile/nav-list.tsx +++ b/03_source/frontend/src/components/mega-menu/mobile/nav-list.tsx @@ -1,15 +1,11 @@ -import { useBoolean } from 'minimal-shared/hooks'; -import { useRef, useEffect, useCallback } from 'react'; -import { isActiveLink, isExternalLink } from 'minimal-shared/utils'; - import Divider from '@mui/material/Divider'; import Drawer, { drawerClasses } from '@mui/material/Drawer'; - +import { useBoolean } from 'minimal-shared/hooks'; +import { isActiveLink, isExternalLink } from 'minimal-shared/utils'; +import { useCallback, useEffect, useRef } from 'react'; import { usePathname } from 'src/routes/hooks'; - import { Scrollbar } from '../../scrollbar'; -import { Nav, NavUl, NavLi, NavItem, NavSubList, NavDrawerHeader } from '../components'; - +import { Nav, NavDrawerHeader, NavItem, NavLi, NavSubList, NavUl } from '../components'; import type { NavListProps } from '../types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/mega-menu/styles/css-vars.ts b/03_source/frontend/src/components/mega-menu/styles/css-vars.ts index 450ca34..b1478d8 100644 --- a/03_source/frontend/src/components/mega-menu/styles/css-vars.ts +++ b/03_source/frontend/src/components/mega-menu/styles/css-vars.ts @@ -1,5 +1,4 @@ import type { Theme } from '@mui/material/styles'; - import { varAlpha } from 'minimal-shared/utils'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/mega-menu/styles/nav-item-styles.ts b/03_source/frontend/src/components/mega-menu/styles/nav-item-styles.ts index 03252f8..0b6caac 100644 --- a/03_source/frontend/src/components/mega-menu/styles/nav-item-styles.ts +++ b/03_source/frontend/src/components/mega-menu/styles/nav-item-styles.ts @@ -1,4 +1,4 @@ -import type { Theme, CSSObject } from '@mui/material/styles'; +import type { CSSObject, Theme } from '@mui/material/styles'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/mega-menu/types.ts b/03_source/frontend/src/components/mega-menu/types.ts index bd86c9a..5ed8cd5 100644 --- a/03_source/frontend/src/components/mega-menu/types.ts +++ b/03_source/frontend/src/components/mega-menu/types.ts @@ -1,8 +1,7 @@ -import type { LinkProps } from '@mui/material/Link'; import type { MasonryProps } from '@mui/lab/Masonry'; import type { ButtonBaseProps } from '@mui/material/ButtonBase'; -import type { Theme, SxProps, CSSObject } from '@mui/material/styles'; - +import type { LinkProps } from '@mui/material/Link'; +import type { CSSObject, SxProps, Theme } from '@mui/material/styles'; import type { CarouselOptions } from '../carousel'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/mega-menu/utils/create-nav-item.ts b/03_source/frontend/src/components/mega-menu/utils/create-nav-item.ts index 3dbe7bb..b45137b 100644 --- a/03_source/frontend/src/components/mega-menu/utils/create-nav-item.ts +++ b/03_source/frontend/src/components/mega-menu/utils/create-nav-item.ts @@ -1,7 +1,5 @@ import { cloneElement } from 'react'; - import { RouterLink } from 'src/routes/components'; - import type { NavItemDataProps, NavItemOptionsProps } from '../types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/mega-menu/vertical/mega-menu-vertical.tsx b/03_source/frontend/src/components/mega-menu/vertical/mega-menu-vertical.tsx index 08e0857..aee116c 100644 --- a/03_source/frontend/src/components/mega-menu/vertical/mega-menu-vertical.tsx +++ b/03_source/frontend/src/components/mega-menu/vertical/mega-menu-vertical.tsx @@ -1,13 +1,10 @@ -import { mergeClasses } from 'minimal-shared/utils'; -import { useClientRect } from 'minimal-shared/hooks'; - import { useTheme } from '@mui/material/styles'; - -import { NavList } from './nav-list'; +import { useClientRect } from 'minimal-shared/hooks'; +import { mergeClasses } from 'minimal-shared/utils'; import { Nav, NavUl } from '../components'; -import { megaMenuVars, megaMenuClasses } from '../styles'; - +import { megaMenuClasses, megaMenuVars } from '../styles'; import type { MegaMenuProps } from '../types'; +import { NavList } from './nav-list'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/mega-menu/vertical/nav-list.tsx b/03_source/frontend/src/components/mega-menu/vertical/nav-list.tsx index 69e6bda..ce6ee71 100644 --- a/03_source/frontend/src/components/mega-menu/vertical/nav-list.tsx +++ b/03_source/frontend/src/components/mega-menu/vertical/nav-list.tsx @@ -1,11 +1,8 @@ -import { useRef, useCallback } from 'react'; import { useBoolean } from 'minimal-shared/hooks'; import { isActiveLink, isExternalLink } from 'minimal-shared/utils'; - +import { useCallback, useRef } from 'react'; import { usePathname } from 'src/routes/hooks'; - -import { NavLi, NavItem, NavDropdown, NavDropdownContent } from '../components'; - +import { NavDropdown, NavDropdownContent, NavItem, NavLi } from '../components'; import type { NavListProps } from '../types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/nav-basic/components/nav-collapse.tsx b/03_source/frontend/src/components/nav-basic/components/nav-collapse.tsx index 183c078..39ffb26 100644 --- a/03_source/frontend/src/components/nav-basic/components/nav-collapse.tsx +++ b/03_source/frontend/src/components/nav-basic/components/nav-collapse.tsx @@ -1,8 +1,6 @@ -import type { CSSObject } from '@mui/material/styles'; - -import { styled } from '@mui/material/styles'; import Collapse from '@mui/material/Collapse'; - +import type { CSSObject } from '@mui/material/styles'; +import { styled } from '@mui/material/styles'; import { navBasicClasses } from '../styles'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/nav-basic/components/nav-dropdown.tsx b/03_source/frontend/src/components/nav-basic/components/nav-dropdown.tsx index fbee218..8495b7d 100644 --- a/03_source/frontend/src/components/nav-basic/components/nav-dropdown.tsx +++ b/03_source/frontend/src/components/nav-basic/components/nav-dropdown.tsx @@ -1,7 +1,6 @@ -import type { CSSObject } from '@mui/material/styles'; - -import { styled } from '@mui/material/styles'; import Popover, { popoverClasses } from '@mui/material/Popover'; +import type { CSSObject } from '@mui/material/styles'; +import { styled } from '@mui/material/styles'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/nav-basic/components/nav-elements.tsx b/03_source/frontend/src/components/nav-basic/components/nav-elements.tsx index 2a2b0b7..0363c19 100644 --- a/03_source/frontend/src/components/nav-basic/components/nav-elements.tsx +++ b/03_source/frontend/src/components/nav-basic/components/nav-elements.tsx @@ -1,7 +1,5 @@ -import { mergeClasses } from 'minimal-shared/utils'; - import { styled } from '@mui/material/styles'; - +import { mergeClasses } from 'minimal-shared/utils'; import { navBasicClasses } from '../styles'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/nav-basic/desktop/nav-basic-desktop.tsx b/03_source/frontend/src/components/nav-basic/desktop/nav-basic-desktop.tsx index bf5bd4e..efee4ee 100644 --- a/03_source/frontend/src/components/nav-basic/desktop/nav-basic-desktop.tsx +++ b/03_source/frontend/src/components/nav-basic/desktop/nav-basic-desktop.tsx @@ -1,10 +1,8 @@ import { useTheme } from '@mui/material/styles'; - -import { NavList } from './nav-list'; import { Nav, NavUl } from '../components'; -import { navBasicVars, navBasicClasses } from '../styles'; - +import { navBasicClasses, navBasicVars } from '../styles'; import type { NavBasicProps } from '../types'; +import { NavList } from './nav-list'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/nav-basic/desktop/nav-item.tsx b/03_source/frontend/src/components/nav-basic/desktop/nav-item.tsx index f742091..2fa6b75 100644 --- a/03_source/frontend/src/components/nav-basic/desktop/nav-item.tsx +++ b/03_source/frontend/src/components/nav-basic/desktop/nav-item.tsx @@ -1,15 +1,11 @@ -import type { CSSObject } from '@mui/material/styles'; - -import { mergeClasses } from 'minimal-shared/utils'; - -import { styled } from '@mui/material/styles'; import ButtonBase from '@mui/material/ButtonBase'; - +import type { CSSObject } from '@mui/material/styles'; +import { styled } from '@mui/material/styles'; +import { mergeClasses } from 'minimal-shared/utils'; import { Iconify } from '../../iconify'; -import { createNavItem } from '../utils'; -import { navItemStyles, navBasicClasses } from '../styles'; - +import { navBasicClasses, navItemStyles } from '../styles'; import type { NavItemProps } from '../types'; +import { createNavItem } from '../utils'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/nav-basic/desktop/nav-list.tsx b/03_source/frontend/src/components/nav-basic/desktop/nav-list.tsx index c6474f6..1252190 100644 --- a/03_source/frontend/src/components/nav-basic/desktop/nav-list.tsx +++ b/03_source/frontend/src/components/nav-basic/desktop/nav-list.tsx @@ -1,17 +1,13 @@ -import { useEffect, useCallback } from 'react'; +import { popoverClasses } from '@mui/material/Popover'; +import { useTheme } from '@mui/material/styles'; import { usePopoverHover } from 'minimal-shared/hooks'; import { isActiveLink, isExternalLink } from 'minimal-shared/utils'; - -import { useTheme } from '@mui/material/styles'; -import { popoverClasses } from '@mui/material/Popover'; - +import { useCallback, useEffect } from 'react'; import { usePathname } from 'src/routes/hooks'; - -import { NavItem } from './nav-item'; +import { NavDropdown, NavDropdownPaper, NavLi, NavUl } from '../components'; import { navBasicClasses } from '../styles'; -import { NavUl, NavLi, NavDropdown, NavDropdownPaper } from '../components'; - import type { NavListProps, NavSubListProps } from '../types'; +import { NavItem } from './nav-item'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/nav-basic/mobile/nav-basic-mobile.tsx b/03_source/frontend/src/components/nav-basic/mobile/nav-basic-mobile.tsx index e162181..9525556 100644 --- a/03_source/frontend/src/components/nav-basic/mobile/nav-basic-mobile.tsx +++ b/03_source/frontend/src/components/nav-basic/mobile/nav-basic-mobile.tsx @@ -1,10 +1,8 @@ import { useTheme } from '@mui/material/styles'; - -import { NavList } from './nav-list'; import { Nav, NavUl } from '../components'; -import { navBasicVars, navBasicClasses } from '../styles'; - +import { navBasicClasses, navBasicVars } from '../styles'; import type { NavBasicProps } from '../types'; +import { NavList } from './nav-list'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/nav-basic/mobile/nav-item.tsx b/03_source/frontend/src/components/nav-basic/mobile/nav-item.tsx index c737d9a..e61317c 100644 --- a/03_source/frontend/src/components/nav-basic/mobile/nav-item.tsx +++ b/03_source/frontend/src/components/nav-basic/mobile/nav-item.tsx @@ -1,16 +1,12 @@ -import type { CSSObject } from '@mui/material/styles'; - -import { mergeClasses } from 'minimal-shared/utils'; - -import Tooltip from '@mui/material/Tooltip'; -import { styled } from '@mui/material/styles'; import ButtonBase from '@mui/material/ButtonBase'; - +import type { CSSObject } from '@mui/material/styles'; +import { styled } from '@mui/material/styles'; +import Tooltip from '@mui/material/Tooltip'; +import { mergeClasses } from 'minimal-shared/utils'; import { Iconify } from '../../iconify'; -import { createNavItem } from '../utils'; -import { navItemStyles, navBasicClasses } from '../styles'; - +import { navBasicClasses, navItemStyles } from '../styles'; import type { NavItemProps } from '../types'; +import { createNavItem } from '../utils'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/nav-basic/mobile/nav-list.tsx b/03_source/frontend/src/components/nav-basic/mobile/nav-list.tsx index 89df341..83c4a5e 100644 --- a/03_source/frontend/src/components/nav-basic/mobile/nav-list.tsx +++ b/03_source/frontend/src/components/nav-basic/mobile/nav-list.tsx @@ -1,14 +1,11 @@ import { useBoolean } from 'minimal-shared/hooks'; -import { useRef, useEffect, useCallback } from 'react'; import { isActiveLink, isExternalLink } from 'minimal-shared/utils'; - +import { useCallback, useEffect, useRef } from 'react'; import { usePathname } from 'src/routes/hooks'; - -import { NavItem } from './nav-item'; +import { NavCollapse, NavLi, NavUl } from '../components'; import { navBasicClasses } from '../styles'; -import { NavLi, NavUl, NavCollapse } from '../components'; - import type { NavListProps, NavSubListProps } from '../types'; +import { NavItem } from './nav-item'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/nav-basic/styles/css-vars.ts b/03_source/frontend/src/components/nav-basic/styles/css-vars.ts index c7eeba2..be11e02 100644 --- a/03_source/frontend/src/components/nav-basic/styles/css-vars.ts +++ b/03_source/frontend/src/components/nav-basic/styles/css-vars.ts @@ -1,5 +1,4 @@ import type { Theme } from '@mui/material/styles'; - import { varAlpha } from 'minimal-shared/utils'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/nav-basic/styles/nav-item-styles.ts b/03_source/frontend/src/components/nav-basic/styles/nav-item-styles.ts index 03252f8..0b6caac 100644 --- a/03_source/frontend/src/components/nav-basic/styles/nav-item-styles.ts +++ b/03_source/frontend/src/components/nav-basic/styles/nav-item-styles.ts @@ -1,4 +1,4 @@ -import type { Theme, CSSObject } from '@mui/material/styles'; +import type { CSSObject, Theme } from '@mui/material/styles'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/nav-basic/types.ts b/03_source/frontend/src/components/nav-basic/types.ts index 2530712..7c92d63 100644 --- a/03_source/frontend/src/components/nav-basic/types.ts +++ b/03_source/frontend/src/components/nav-basic/types.ts @@ -1,5 +1,5 @@ import type { ButtonBaseProps } from '@mui/material/ButtonBase'; -import type { Theme, SxProps, CSSObject } from '@mui/material/styles'; +import type { CSSObject, SxProps, Theme } from '@mui/material/styles'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/nav-basic/utils/create-nav-item.ts b/03_source/frontend/src/components/nav-basic/utils/create-nav-item.ts index 151dc73..595b4ca 100644 --- a/03_source/frontend/src/components/nav-basic/utils/create-nav-item.ts +++ b/03_source/frontend/src/components/nav-basic/utils/create-nav-item.ts @@ -1,7 +1,5 @@ import { cloneElement } from 'react'; - import { RouterLink } from 'src/routes/components'; - import type { NavItemDataProps, NavItemOptionsProps } from '../types'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/nav-section/components/nav-collapse.tsx b/03_source/frontend/src/components/nav-section/components/nav-collapse.tsx index 767b85d..46b78d7 100644 --- a/03_source/frontend/src/components/nav-section/components/nav-collapse.tsx +++ b/03_source/frontend/src/components/nav-section/components/nav-collapse.tsx @@ -1,8 +1,6 @@ -import type { CSSObject } from '@mui/material/styles'; - -import { styled } from '@mui/material/styles'; import Collapse from '@mui/material/Collapse'; - +import type { CSSObject } from '@mui/material/styles'; +import { styled } from '@mui/material/styles'; import { navSectionClasses } from '../styles'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/nav-section/components/nav-dropdown.tsx b/03_source/frontend/src/components/nav-section/components/nav-dropdown.tsx index f38c145..22af760 100644 --- a/03_source/frontend/src/components/nav-section/components/nav-dropdown.tsx +++ b/03_source/frontend/src/components/nav-section/components/nav-dropdown.tsx @@ -1,7 +1,6 @@ -import type { CSSObject } from '@mui/material/styles'; - -import { styled } from '@mui/material/styles'; import Popover, { popoverClasses } from '@mui/material/Popover'; +import type { CSSObject } from '@mui/material/styles'; +import { styled } from '@mui/material/styles'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/nav-section/components/nav-elements.tsx b/03_source/frontend/src/components/nav-section/components/nav-elements.tsx index bebf407..3e944d7 100644 --- a/03_source/frontend/src/components/nav-section/components/nav-elements.tsx +++ b/03_source/frontend/src/components/nav-section/components/nav-elements.tsx @@ -1,7 +1,5 @@ -import { mergeClasses } from 'minimal-shared/utils'; - import { styled } from '@mui/material/styles'; - +import { mergeClasses } from 'minimal-shared/utils'; import { navSectionClasses } from '../styles'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/nav-section/horizontal/nav-item.tsx b/03_source/frontend/src/components/nav-section/horizontal/nav-item.tsx index a0ed657..c53827b 100644 --- a/03_source/frontend/src/components/nav-section/horizontal/nav-item.tsx +++ b/03_source/frontend/src/components/nav-section/horizontal/nav-item.tsx @@ -1,16 +1,12 @@ -import type { CSSObject } from '@mui/material/styles'; - -import { mergeClasses } from 'minimal-shared/utils'; - -import Tooltip from '@mui/material/Tooltip'; -import { styled } from '@mui/material/styles'; import ButtonBase from '@mui/material/ButtonBase'; - +import type { CSSObject } from '@mui/material/styles'; +import { styled } from '@mui/material/styles'; +import Tooltip from '@mui/material/Tooltip'; +import { mergeClasses } from 'minimal-shared/utils'; import { Iconify } from '../../iconify'; -import { createNavItem } from '../utils'; import { navItemStyles, navSectionClasses } from '../styles'; - import type { NavItemProps } from '../types'; +import { createNavItem } from '../utils'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/nav-section/horizontal/nav-list.tsx b/03_source/frontend/src/components/nav-section/horizontal/nav-list.tsx index 4b7a65a..9bfa264 100644 --- a/03_source/frontend/src/components/nav-section/horizontal/nav-list.tsx +++ b/03_source/frontend/src/components/nav-section/horizontal/nav-list.tsx @@ -1,17 +1,13 @@ -import { useEffect, useCallback } from 'react'; +import { popoverClasses } from '@mui/material/Popover'; +import { useTheme } from '@mui/material/styles'; import { usePopoverHover } from 'minimal-shared/hooks'; import { isActiveLink, isExternalLink } from 'minimal-shared/utils'; - -import { useTheme } from '@mui/material/styles'; -import { popoverClasses } from '@mui/material/Popover'; - +import { useCallback, useEffect } from 'react'; import { usePathname } from 'src/routes/hooks'; - -import { NavItem } from './nav-item'; +import { NavDropdown, NavDropdownPaper, NavLi, NavUl } from '../components'; import { navSectionClasses } from '../styles'; -import { NavUl, NavLi, NavDropdown, NavDropdownPaper } from '../components'; - import type { NavListProps, NavSubListProps } from '../types'; +import { NavItem } from './nav-item'; // ---------------------------------------------------------------------- diff --git a/03_source/frontend/src/components/nav-section/horizontal/nav-section-horizontal.tsx b/03_source/frontend/src/components/nav-section/horizontal/nav-section-horizontal.tsx index 2d44c9e..e1132c5 100644 --- a/03_source/frontend/src/components/nav-section/horizontal/nav-section-horizontal.tsx +++ b/03_source/frontend/src/components/nav-section/horizontal/nav-section-horizontal.tsx @@ -1,13 +1,10 @@ -import { mergeClasses } from 'minimal-shared/utils'; - import { useTheme } from '@mui/material/styles'; - -import { NavList } from './nav-list'; +import { mergeClasses } from 'minimal-shared/utils'; import { Scrollbar } from '../../scrollbar'; -import { Nav, NavUl, NavLi } from '../components'; +import { Nav, NavLi, NavUl } from '../components'; import { navSectionClasses, navSectionCssVars } from '../styles'; - import type { NavGroupProps, NavSectionProps } from '../types'; +import { NavList } from './nav-list'; // ---------------------------------------------------------------------- @@ -27,7 +24,10 @@ export function NavSectionHorizontal({ const cssVars = { ...navSectionCssVars.horizontal(theme), ...overridesVars }; return ( - +