@vitnode/core 1.2.0-canary.52 → 1.2.0-canary.53
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/config/next.config.ts +3 -3
- package/dist/scripts/get-config.d.ts +2 -2
- package/dist/scripts/get-config.d.ts.map +1 -1
- package/dist/scripts/plugin.d.ts.map +1 -1
- package/dist/scripts/prepare-database.d.ts.map +1 -1
- package/dist/scripts/prepare-plugins-files.d.ts.map +1 -1
- package/dist/scripts/scripts.js +4 -4
- package/dist/scripts/shared/file-utils.d.ts.map +1 -1
- package/dist/src/api/adapters/email/nodemailer.d.ts +1 -1
- package/dist/src/api/adapters/email/nodemailer.js +3 -3
- package/dist/src/api/adapters/email/resend.d.ts +1 -1
- package/dist/src/api/adapters/email/resend.js +2 -2
- package/dist/src/api/adapters/sso/discord.d.ts +1 -1
- package/dist/src/api/adapters/sso/discord.d.ts.map +1 -1
- package/dist/src/api/adapters/sso/discord.js +21 -21
- package/dist/src/api/adapters/sso/facebook.d.ts +1 -1
- package/dist/src/api/adapters/sso/facebook.d.ts.map +1 -1
- package/dist/src/api/adapters/sso/facebook.js +23 -23
- package/dist/src/api/adapters/sso/google.d.ts +1 -1
- package/dist/src/api/adapters/sso/google.d.ts.map +1 -1
- package/dist/src/api/adapters/sso/google.js +21 -21
- package/dist/src/api/config.d.ts +3 -3
- package/dist/src/api/config.d.ts.map +1 -1
- package/dist/src/api/config.js +11 -11
- package/dist/src/api/lib/check-plugin-id.js +8 -8
- package/dist/src/api/lib/logger-middleware.d.ts +1 -1
- package/dist/src/api/lib/logger-middleware.js +9 -9
- package/dist/src/api/lib/module.d.ts +2 -2
- package/dist/src/api/lib/plugin.d.ts +2 -2
- package/dist/src/api/lib/plugin.d.ts.map +1 -1
- package/dist/src/api/lib/route.d.ts +2 -2
- package/dist/src/api/lib/route.d.ts.map +1 -1
- package/dist/src/api/lib/route.js +1 -1
- package/dist/src/api/lib/with-pagination.d.ts +7 -7
- package/dist/src/api/lib/with-pagination.d.ts.map +1 -1
- package/dist/src/api/lib/with-pagination.js +37 -24
- package/dist/src/api/middlewares/captcha.middleware.d.ts +1 -1
- package/dist/src/api/middlewares/captcha.middleware.d.ts.map +1 -1
- package/dist/src/api/middlewares/captcha.middleware.js +14 -13
- package/dist/src/api/middlewares/global.middleware.d.ts +12 -12
- package/dist/src/api/middlewares/global.middleware.d.ts.map +1 -1
- package/dist/src/api/middlewares/global.middleware.js +29 -28
- package/dist/src/api/middlewares/rate-limiter.middleware.d.ts +3 -3
- package/dist/src/api/middlewares/rate-limiter.middleware.d.ts.map +1 -1
- package/dist/src/api/middlewares/rate-limiter.middleware.js +4 -4
- package/dist/src/api/models/device.d.ts +1 -1
- package/dist/src/api/models/device.d.ts.map +1 -1
- package/dist/src/api/models/device.js +13 -13
- package/dist/src/api/models/email.d.ts +15 -15
- package/dist/src/api/models/email.d.ts.map +1 -1
- package/dist/src/api/models/email.js +11 -10
- package/dist/src/api/models/password.js +9 -9
- package/dist/src/api/models/session-admin.d.ts +1 -1
- package/dist/src/api/models/session-admin.d.ts.map +1 -1
- package/dist/src/api/models/session-admin.js +19 -19
- package/dist/src/api/models/session.d.ts +1 -1
- package/dist/src/api/models/session.d.ts.map +1 -1
- package/dist/src/api/models/session.js +17 -17
- package/dist/src/api/models/sso.d.ts +1 -1
- package/dist/src/api/models/sso.d.ts.map +1 -1
- package/dist/src/api/models/sso.js +22 -25
- package/dist/src/api/models/user/get-user-by-id.d.ts +1 -1
- package/dist/src/api/models/user/get-user-by-id.d.ts.map +1 -1
- package/dist/src/api/models/user/get-user-by-id.js +1 -1
- package/dist/src/api/models/user/sign-in-with-passwords.d.ts +1 -1
- package/dist/src/api/models/user/sign-in-with-passwords.d.ts.map +1 -1
- package/dist/src/api/models/user/sign-in-with-passwords.js +1 -1
- package/dist/src/api/models/user/sign-up.d.ts +1 -1
- package/dist/src/api/models/user/sign-up.d.ts.map +1 -1
- package/dist/src/api/models/user/sign-up.js +11 -12
- package/dist/src/api/models/user.d.ts.map +1 -1
- package/dist/src/api/modules/admin/admin.module.d.ts +3 -3
- package/dist/src/api/modules/admin/admin.module.js +1 -1
- package/dist/src/api/modules/admin/debug/debug.admin.module.d.ts +1 -1
- package/dist/src/api/modules/admin/debug/debug.admin.module.js +1 -1
- package/dist/src/api/modules/admin/debug/routes/logs.route.d.ts +2 -2
- package/dist/src/api/modules/admin/debug/routes/logs.route.js +16 -16
- package/dist/src/api/modules/admin/routes/session.route.d.ts +2 -2
- package/dist/src/api/modules/admin/routes/session.route.js +7 -7
- package/dist/src/api/modules/admin/users/routes/list.route.d.ts +2 -2
- package/dist/src/api/modules/admin/users/routes/list.route.js +12 -12
- package/dist/src/api/modules/admin/users/routes/users.route.d.ts +2 -2
- package/dist/src/api/modules/admin/users/routes/users.route.js +15 -15
- package/dist/src/api/modules/admin/users/users.admin.module.d.ts +1 -1
- package/dist/src/api/modules/admin/users/users.admin.module.js +1 -1
- package/dist/src/api/modules/middleware/middleware.module.d.ts +1 -1
- package/dist/src/api/modules/middleware/middleware.module.js +1 -1
- package/dist/src/api/modules/middleware/route.d.ts +2 -2
- package/dist/src/api/modules/middleware/route.js +12 -12
- package/dist/src/api/modules/users/routes/change-password.route.d.ts +2 -2
- package/dist/src/api/modules/users/routes/change-password.route.js +13 -13
- package/dist/src/api/modules/users/routes/reset-passowrd.route.d.ts +2 -2
- package/dist/src/api/modules/users/routes/reset-passowrd.route.js +17 -17
- package/dist/src/api/modules/users/routes/session.route.d.ts +2 -2
- package/dist/src/api/modules/users/routes/session.route.js +6 -6
- package/dist/src/api/modules/users/routes/sign-in.route.d.ts +3 -3
- package/dist/src/api/modules/users/routes/sign-in.route.js +10 -10
- package/dist/src/api/modules/users/routes/sign-out.route.d.ts +2 -2
- package/dist/src/api/modules/users/routes/sign-out.route.js +7 -7
- package/dist/src/api/modules/users/routes/sign-up.route.d.ts +3 -3
- package/dist/src/api/modules/users/routes/sign-up.route.js +14 -14
- package/dist/src/api/modules/users/routes/test.route.d.ts +3 -3
- package/dist/src/api/modules/users/routes/test.route.js +9 -9
- package/dist/src/api/modules/users/sso/routes/callback.route.d.ts +2 -2
- package/dist/src/api/modules/users/sso/routes/callback.route.js +8 -8
- package/dist/src/api/modules/users/sso/routes/create-url.route.d.ts +2 -2
- package/dist/src/api/modules/users/sso/routes/create-url.route.js +6 -6
- package/dist/src/api/modules/users/sso/sso.module.d.ts +2 -2
- package/dist/src/api/modules/users/sso/sso.module.js +1 -1
- package/dist/src/api/modules/users/users.module.d.ts +12 -12
- package/dist/src/api/modules/users/users.module.js +1 -1
- package/dist/src/app/login/page.d.ts +1 -1
- package/dist/src/app/login/page.js +2 -2
- package/dist/src/app/login/reset-password/page.d.ts +2 -2
- package/dist/src/app/login/reset-password/page.js +2 -2
- package/dist/src/app/register/page.d.ts +1 -1
- package/dist/src/app/register/page.js +2 -2
- package/dist/src/app_admin/core/debug/page.d.ts +1 -1
- package/dist/src/app_admin/core/debug/page.js +8 -8
- package/dist/src/app_admin/core/users/page.d.ts +2 -2
- package/dist/src/app_admin/core/users/page.d.ts.map +1 -1
- package/dist/src/app_admin/core/users/page.js +7 -7
- package/dist/src/components/avatar.d.ts +1 -1
- package/dist/src/components/avatar.js +1 -1
- package/dist/src/components/confirm-action/confirm-action-alert-dialog.d.ts +2 -2
- package/dist/src/components/confirm-action/confirm-action-alert-dialog.js +5 -5
- package/dist/src/components/confirm-action/content.d.ts.map +1 -1
- package/dist/src/components/confirm-action/content.js +3 -4
- package/dist/src/components/date-format.js +8 -8
- package/dist/src/components/form/auto-form.d.ts +16 -16
- package/dist/src/components/form/auto-form.d.ts.map +1 -1
- package/dist/src/components/form/auto-form.js +13 -12
- package/dist/src/components/form/common/desc.js +1 -1
- package/dist/src/components/form/common/label.d.ts +1 -1
- package/dist/src/components/form/common/label.js +1 -1
- package/dist/src/components/form/fields/checkbox.d.ts +2 -2
- package/dist/src/components/form/fields/checkbox.d.ts.map +1 -1
- package/dist/src/components/form/fields/combobox-async.d.ts +3 -3
- package/dist/src/components/form/fields/combobox-async.d.ts.map +1 -1
- package/dist/src/components/form/fields/combobox-async.js +29 -23
- package/dist/src/components/form/fields/combobox.d.ts +3 -3
- package/dist/src/components/form/fields/combobox.d.ts.map +1 -1
- package/dist/src/components/form/fields/combobox.js +6 -7
- package/dist/src/components/form/fields/input.d.ts +2 -2
- package/dist/src/components/form/fields/input.d.ts.map +1 -1
- package/dist/src/components/form/fields/input.js +2 -2
- package/dist/src/components/form/fields/radio-group.d.ts +3 -3
- package/dist/src/components/form/fields/radio-group.d.ts.map +1 -1
- package/dist/src/components/form/fields/radio-group.js +0 -1
- package/dist/src/components/form/fields/select.d.ts +3 -3
- package/dist/src/components/form/fields/select.d.ts.map +1 -1
- package/dist/src/components/form/fields/select.js +2 -3
- package/dist/src/components/form/fields/switch.d.ts +2 -2
- package/dist/src/components/form/fields/switch.d.ts.map +1 -1
- package/dist/src/components/form/fields/textarea.d.ts +3 -3
- package/dist/src/components/form/fields/textarea.d.ts.map +1 -1
- package/dist/src/components/form/fields/textarea.js +1 -2
- package/dist/src/components/i18n-provider.d.ts +2 -2
- package/dist/src/components/i18n-provider.js +3 -3
- package/dist/src/components/logo-vitnode.d.ts.map +1 -1
- package/dist/src/components/logo-vitnode.js +8 -2
- package/dist/src/components/switchers/langs/language-swietcher.d.ts +1 -1
- package/dist/src/components/switchers/langs/language-swietcher.d.ts.map +1 -1
- package/dist/src/components/switchers/langs/language-swietcher.js +3 -3
- package/dist/src/components/switchers/themes/theme-switcher.js +4 -4
- package/dist/src/components/table/content.d.ts +1 -1
- package/dist/src/components/table/content.d.ts.map +1 -1
- package/dist/src/components/table/content.js +5 -5
- package/dist/src/components/table/data-table.d.ts +7 -7
- package/dist/src/components/table/data-table.d.ts.map +1 -1
- package/dist/src/components/table/data-table.js +22 -15
- package/dist/src/components/table/order-table-head.d.ts +4 -4
- package/dist/src/components/table/order-table-head.d.ts.map +1 -1
- package/dist/src/components/table/order-table-head.js +20 -9
- package/dist/src/components/table/pagination.js +19 -19
- package/dist/src/components/ui/accordion.d.ts +2 -2
- package/dist/src/components/ui/accordion.d.ts.map +1 -1
- package/dist/src/components/ui/accordion.js +4 -5
- package/dist/src/components/ui/alert-dialog.d.ts +7 -7
- package/dist/src/components/ui/alert-dialog.d.ts.map +1 -1
- package/dist/src/components/ui/alert-dialog.js +12 -12
- package/dist/src/components/ui/alert.d.ts +5 -5
- package/dist/src/components/ui/alert.d.ts.map +1 -1
- package/dist/src/components/ui/alert.js +6 -7
- package/dist/src/components/ui/badge.d.ts +3 -3
- package/dist/src/components/ui/badge.d.ts.map +1 -1
- package/dist/src/components/ui/badge.js +7 -8
- package/dist/src/components/ui/button-client.d.ts +1 -1
- package/dist/src/components/ui/button-client.js +9 -9
- package/dist/src/components/ui/button.d.ts +8 -8
- package/dist/src/components/ui/button.d.ts.map +1 -1
- package/dist/src/components/ui/button.js +13 -14
- package/dist/src/components/ui/card.d.ts +8 -8
- package/dist/src/components/ui/card.js +7 -7
- package/dist/src/components/ui/checkbox.d.ts +2 -2
- package/dist/src/components/ui/checkbox.d.ts.map +1 -1
- package/dist/src/components/ui/checkbox.js +2 -3
- package/dist/src/components/ui/collapsible.d.ts +1 -1
- package/dist/src/components/ui/collapsible.js +1 -1
- package/dist/src/components/ui/command.d.ts +4 -4
- package/dist/src/components/ui/command.d.ts.map +1 -1
- package/dist/src/components/ui/command.js +9 -10
- package/dist/src/components/ui/context-menu.d.ts +4 -4
- package/dist/src/components/ui/context-menu.d.ts.map +1 -1
- package/dist/src/components/ui/context-menu.js +7 -8
- package/dist/src/components/ui/dialog.d.ts +6 -6
- package/dist/src/components/ui/dialog.d.ts.map +1 -1
- package/dist/src/components/ui/dialog.js +16 -16
- package/dist/src/components/ui/drawer.d.ts +4 -4
- package/dist/src/components/ui/drawer.d.ts.map +1 -1
- package/dist/src/components/ui/drawer.js +7 -8
- package/dist/src/components/ui/dropdown-menu.d.ts +4 -4
- package/dist/src/components/ui/dropdown-menu.d.ts.map +1 -1
- package/dist/src/components/ui/dropdown-menu.js +8 -9
- package/dist/src/components/ui/form.d.ts +10 -10
- package/dist/src/components/ui/form.d.ts.map +1 -1
- package/dist/src/components/ui/form.js +15 -15
- package/dist/src/components/ui/header-content.js +1 -1
- package/dist/src/components/ui/hover-card.d.ts +2 -2
- package/dist/src/components/ui/hover-card.d.ts.map +1 -1
- package/dist/src/components/ui/hover-card.js +3 -4
- package/dist/src/components/ui/input-otp.d.ts +5 -5
- package/dist/src/components/ui/input-otp.d.ts.map +1 -1
- package/dist/src/components/ui/input-otp.js +6 -7
- package/dist/src/components/ui/input.d.ts +2 -2
- package/dist/src/components/ui/input.d.ts.map +1 -1
- package/dist/src/components/ui/input.js +1 -2
- package/dist/src/components/ui/label.d.ts +2 -2
- package/dist/src/components/ui/label.d.ts.map +1 -1
- package/dist/src/components/ui/label.js +2 -3
- package/dist/src/components/ui/loader.js +3 -3
- package/dist/src/components/ui/menubar.d.ts +4 -4
- package/dist/src/components/ui/menubar.d.ts.map +1 -1
- package/dist/src/components/ui/menubar.js +11 -12
- package/dist/src/components/ui/navigation-menu.d.ts +2 -2
- package/dist/src/components/ui/navigation-menu.d.ts.map +1 -1
- package/dist/src/components/ui/navigation-menu.js +10 -11
- package/dist/src/components/ui/popover.d.ts +2 -2
- package/dist/src/components/ui/popover.d.ts.map +1 -1
- package/dist/src/components/ui/popover.js +3 -4
- package/dist/src/components/ui/progress.d.ts +2 -2
- package/dist/src/components/ui/progress.d.ts.map +1 -1
- package/dist/src/components/ui/progress.js +2 -3
- package/dist/src/components/ui/radio-group.d.ts +2 -2
- package/dist/src/components/ui/radio-group.d.ts.map +1 -1
- package/dist/src/components/ui/radio-group.js +3 -4
- package/dist/src/components/ui/select.d.ts +3 -3
- package/dist/src/components/ui/select.d.ts.map +1 -1
- package/dist/src/components/ui/select.js +9 -10
- package/dist/src/components/ui/separator.d.ts +2 -2
- package/dist/src/components/ui/separator.d.ts.map +1 -1
- package/dist/src/components/ui/separator.js +3 -4
- package/dist/src/components/ui/sheet.d.ts +5 -5
- package/dist/src/components/ui/sheet.d.ts.map +1 -1
- package/dist/src/components/ui/sheet.js +8 -9
- package/dist/src/components/ui/sidebar.d.ts +31 -31
- package/dist/src/components/ui/sidebar.d.ts.map +1 -1
- package/dist/src/components/ui/sidebar.js +67 -69
- package/dist/src/components/ui/skeleton.d.ts +1 -1
- package/dist/src/components/ui/skeleton.js +1 -1
- package/dist/src/components/ui/slider.d.ts +2 -2
- package/dist/src/components/ui/slider.d.ts.map +1 -1
- package/dist/src/components/ui/slider.js +16 -8
- package/dist/src/components/ui/sonner.d.ts +1 -1
- package/dist/src/components/ui/sonner.d.ts.map +1 -1
- package/dist/src/components/ui/sonner.js +6 -6
- package/dist/src/components/ui/switch.d.ts +2 -2
- package/dist/src/components/ui/switch.d.ts.map +1 -1
- package/dist/src/components/ui/switch.js +3 -4
- package/dist/src/components/ui/table.d.ts +9 -9
- package/dist/src/components/ui/table.d.ts.map +1 -1
- package/dist/src/components/ui/table.js +8 -9
- package/dist/src/components/ui/tabs.d.ts +2 -2
- package/dist/src/components/ui/tabs.d.ts.map +1 -1
- package/dist/src/components/ui/tabs.js +4 -5
- package/dist/src/components/ui/textarea.d.ts +2 -2
- package/dist/src/components/ui/textarea.d.ts.map +1 -1
- package/dist/src/components/ui/textarea.js +1 -2
- package/dist/src/components/ui/toggle-group.d.ts +4 -4
- package/dist/src/components/ui/toggle-group.d.ts.map +1 -1
- package/dist/src/components/ui/toggle-group.js +6 -6
- package/dist/src/components/ui/toggle.d.ts +3 -3
- package/dist/src/components/ui/toggle.d.ts.map +1 -1
- package/dist/src/components/ui/toggle.js +8 -9
- package/dist/src/components/ui/tooltip.d.ts +2 -2
- package/dist/src/components/ui/tooltip.d.ts.map +1 -1
- package/dist/src/components/ui/tooltip.js +2 -3
- package/dist/src/config.js +2 -2
- package/dist/src/database/admins.js +10 -10
- package/dist/src/database/languages.js +7 -7
- package/dist/src/database/logs.js +9 -9
- package/dist/src/database/moderators.js +5 -5
- package/dist/src/database/roles.js +1 -1
- package/dist/src/database/sessions.js +6 -6
- package/dist/src/database/users.js +13 -13
- package/dist/src/drizzle.config.d.ts +2 -2
- package/dist/src/drizzle.config.d.ts.map +1 -1
- package/dist/src/drizzle.config.js +19 -12
- package/dist/src/emails/default-template.d.ts +3 -3
- package/dist/src/emails/default-template.d.ts.map +1 -1
- package/dist/src/emails/default-template.js +39 -38
- package/dist/src/emails/reset-password.d.ts +1 -1
- package/dist/src/emails/reset-password.d.ts.map +1 -1
- package/dist/src/emails/reset-password.js +51 -51
- package/dist/src/emails/ui/button.d.ts +2 -2
- package/dist/src/emails/ui/button.js +13 -13
- package/dist/src/emails/ui/card.d.ts +1 -1
- package/dist/src/emails/ui/card.js +6 -6
- package/dist/src/hooks/use-before-unload.js +3 -3
- package/dist/src/hooks/use-captcha.d.ts +2 -2
- package/dist/src/hooks/use-captcha.d.ts.map +1 -1
- package/dist/src/hooks/use-captcha.js +29 -37
- package/dist/src/hooks/use-mobile.d.ts.map +1 -1
- package/dist/src/hooks/use-mobile.js +3 -4
- package/dist/src/lib/api/get-middleware-api.js +4 -4
- package/dist/src/lib/api/get-session-admin-api.js +5 -5
- package/dist/src/lib/api/get-session-api.js +4 -4
- package/dist/src/lib/colors.js +28 -19
- package/dist/src/lib/colors.test.js +60 -60
- package/dist/src/lib/config.js +3 -3
- package/dist/src/lib/fetcher/cookie-from-string-to-object.d.ts.map +1 -1
- package/dist/src/lib/fetcher/cookie-from-string-to-object.js +1 -1
- package/dist/src/lib/fetcher/cookie-from-string-to-object.test.js +27 -27
- package/dist/src/lib/fetcher/core.d.ts +5 -5
- package/dist/src/lib/fetcher/core.d.ts.map +1 -1
- package/dist/src/lib/fetcher/core.js +11 -10
- package/dist/src/lib/fetcher/helpers-server.d.ts +1 -1
- package/dist/src/lib/fetcher/helpers-server.js +1 -1
- package/dist/src/lib/fetcher/helpers.test.js +17 -17
- package/dist/src/lib/fetcher/types.d.ts +26 -26
- package/dist/src/lib/fetcher/types.d.ts.map +1 -1
- package/dist/src/lib/fetcher-client.d.ts +4 -4
- package/dist/src/lib/fetcher-client.d.ts.map +1 -1
- package/dist/src/lib/fetcher-client.js +3 -3
- package/dist/src/lib/fetcher.d.ts +5 -5
- package/dist/src/lib/fetcher.d.ts.map +1 -1
- package/dist/src/lib/fetcher.js +4 -4
- package/dist/src/lib/helpers/auto-form.d.ts +3 -3
- package/dist/src/lib/helpers/auto-form.d.ts.map +1 -1
- package/dist/src/lib/helpers/auto-form.js +16 -15
- package/dist/src/lib/helpers/auto-form.test.js +129 -129
- package/dist/src/lib/navigation.d.ts +2 -2
- package/dist/src/lib/navigation.d.ts.map +1 -1
- package/dist/src/lib/plugin.d.ts +3 -3
- package/dist/src/lib/special-characters.js +1 -1
- package/dist/src/lib/special-characters.test.js +36 -36
- package/dist/src/lib/utils.d.ts +1 -1
- package/dist/src/tests/setup.d.ts +1 -1
- package/dist/src/views/admin/layouts/admin-layout.d.ts +1 -1
- package/dist/src/views/admin/layouts/admin-layout.d.ts.map +1 -1
- package/dist/src/views/admin/layouts/admin-layout.js +4 -8
- package/dist/src/views/admin/layouts/sidebar/nav/item.d.ts.map +1 -1
- package/dist/src/views/admin/layouts/sidebar/nav/item.js +11 -12
- package/dist/src/views/admin/layouts/sidebar/nav/nav.d.ts +1 -1
- package/dist/src/views/admin/layouts/sidebar/nav/nav.js +11 -11
- package/dist/src/views/admin/layouts/sidebar/sidebar.d.ts +1 -1
- package/dist/src/views/admin/layouts/sidebar/sidebar.d.ts.map +1 -1
- package/dist/src/views/admin/layouts/sidebar/sidebar.js +1 -2
- package/dist/src/views/admin/layouts/sidebar/sign-out.js +1 -1
- package/dist/src/views/admin/layouts/user-bar/client.js +5 -5
- package/dist/src/views/admin/layouts/user-bar/user-bar.d.ts +1 -1
- package/dist/src/views/admin/layouts/user-bar/user-bar.d.ts.map +1 -1
- package/dist/src/views/admin/layouts/user-bar/user-bar.js +1 -1
- package/dist/src/views/admin/sign-in/sign-in-admin-view.js +1 -1
- package/dist/src/views/admin/views/core/dashboard/dashboard-admin-view.js +3 -3
- package/dist/src/views/admin/views/core/debug/actions/clear-cache/clear-cache.js +10 -10
- package/dist/src/views/admin/views/core/debug/actions/clear-cache/mutation-api.js +2 -2
- package/dist/src/views/admin/views/core/debug/system-logs/actions/more/content.d.ts +1 -1
- package/dist/src/views/admin/views/core/debug/system-logs/actions/more/content.d.ts.map +1 -1
- package/dist/src/views/admin/views/core/debug/system-logs/actions/more/content.js +15 -15
- package/dist/src/views/admin/views/core/debug/system-logs/actions/more/more.d.ts +1 -1
- package/dist/src/views/admin/views/core/debug/system-logs/actions/more/more.js +7 -7
- package/dist/src/views/admin/views/core/debug/system-logs/badges/badge-status.d.ts.map +1 -1
- package/dist/src/views/admin/views/core/debug/system-logs/badges/badge-status.js +7 -1
- package/dist/src/views/admin/views/core/debug/system-logs/badges/badge-type-log.d.ts +1 -1
- package/dist/src/views/admin/views/core/debug/system-logs/badges/badge-type-log.js +3 -3
- package/dist/src/views/admin/views/core/debug/system-logs/system-logs-view.js +25 -25
- package/dist/src/views/admin/views/core/test.js +43 -43
- package/dist/src/views/admin/views/core/users/users-admin-view.d.ts.map +1 -1
- package/dist/src/views/admin/views/core/users/users-admin-view.js +13 -14
- package/dist/src/views/auth/password-reset/change-password-form/form.js +9 -9
- package/dist/src/views/auth/password-reset/change-password-form/mutation-api.d.ts +2 -2
- package/dist/src/views/auth/password-reset/change-password-form/mutation-api.js +5 -5
- package/dist/src/views/auth/password-reset/change-password-form/use-form.d.ts +2 -2
- package/dist/src/views/auth/password-reset/change-password-form/use-form.d.ts.map +1 -1
- package/dist/src/views/auth/password-reset/change-password-form/use-form.js +7 -7
- package/dist/src/views/auth/password-reset/form/form.d.ts +2 -2
- package/dist/src/views/auth/password-reset/form/form.d.ts.map +1 -1
- package/dist/src/views/auth/password-reset/form/form.js +15 -15
- package/dist/src/views/auth/password-reset/form/mutation-api.js +5 -5
- package/dist/src/views/auth/password-reset/form/use-form.d.ts +2 -2
- package/dist/src/views/auth/password-reset/form/use-form.js +7 -7
- package/dist/src/views/auth/password-reset/password-reset-view.js +4 -4
- package/dist/src/views/auth/sign-in/form/form.js +9 -9
- package/dist/src/views/auth/sign-in/form/mutation-api.d.ts +2 -2
- package/dist/src/views/auth/sign-in/form/mutation-api.d.ts.map +1 -1
- package/dist/src/views/auth/sign-in/form/mutation-api.js +10 -10
- package/dist/src/views/auth/sign-in/form/use-form.d.ts +2 -2
- package/dist/src/views/auth/sign-in/form/use-form.js +11 -11
- package/dist/src/views/auth/sign-in/sign-in-view.js +5 -5
- package/dist/src/views/auth/sign-up/components/password-input.d.ts +3 -3
- package/dist/src/views/auth/sign-up/components/password-input.d.ts.map +1 -1
- package/dist/src/views/auth/sign-up/components/password-input.js +9 -10
- package/dist/src/views/auth/sign-up/email-confirmation-view.js +4 -4
- package/dist/src/views/auth/sign-up/form/form.d.ts +2 -2
- package/dist/src/views/auth/sign-up/form/form.d.ts.map +1 -1
- package/dist/src/views/auth/sign-up/form/form.js +18 -18
- package/dist/src/views/auth/sign-up/form/mutation-api.d.ts +2 -2
- package/dist/src/views/auth/sign-up/form/mutation-api.d.ts.map +1 -1
- package/dist/src/views/auth/sign-up/form/mutation-api.js +6 -6
- package/dist/src/views/auth/sign-up/form/use-form.d.ts +2 -2
- package/dist/src/views/auth/sign-up/form/use-form.js +21 -21
- package/dist/src/views/auth/sign-up/sign-up-view.js +5 -5
- package/dist/src/views/auth/sign-up/wrapper.d.ts +1 -1
- package/dist/src/views/auth/sign-up/wrapper.d.ts.map +1 -1
- package/dist/src/views/auth/sign-up/wrapper.js +5 -8
- package/dist/src/views/auth/sso/buttons/client.js +4 -4
- package/dist/src/views/auth/sso/buttons/mutation-api.js +5 -5
- package/dist/src/views/auth/sso/buttons/sso-buttons.js +2 -2
- package/dist/src/views/auth/sso/callback/callback-sso-view.js +6 -6
- package/dist/src/views/auth/sso/callback/client/client.d.ts +1 -1
- package/dist/src/views/auth/sso/callback/client/client.d.ts.map +1 -1
- package/dist/src/views/auth/sso/callback/client/client.js +9 -9
- package/dist/src/views/auth/sso/callback/client/mutation-api.js +7 -7
- package/dist/src/views/error/back-button.js +1 -1
- package/dist/src/views/error/error-view.js +4 -4
- package/dist/src/views/error/global-error-view.d.ts +3 -3
- package/dist/src/views/error/global-error-view.d.ts.map +1 -1
- package/dist/src/views/error/global-error-view.js +36 -44
- package/dist/src/views/layouts/provider.d.ts +4 -4
- package/dist/src/views/layouts/provider.d.ts.map +1 -1
- package/dist/src/views/layouts/provider.js +3 -3
- package/dist/src/views/layouts/root-layout.d.ts +3 -3
- package/dist/src/views/layouts/root-layout.d.ts.map +1 -1
- package/dist/src/views/layouts/root-layout.js +1 -2
- package/dist/src/views/layouts/theme/header/header.d.ts +2 -2
- package/dist/src/views/layouts/theme/header/header.d.ts.map +1 -1
- package/dist/src/views/layouts/theme/header/header.js +1 -1
- package/dist/src/views/layouts/theme/header/user/auth/client.d.ts +1 -1
- package/dist/src/views/layouts/theme/header/user/auth/client.d.ts.map +1 -1
- package/dist/src/views/layouts/theme/header/user/auth/client.js +4 -4
- package/dist/src/views/layouts/theme/header/user/auth/log-out-mutation-api.js +8 -8
- package/dist/src/views/layouts/theme/header/user/user.js +4 -4
- package/dist/src/views/layouts/theme/layout.d.ts +2 -2
- package/dist/src/views/layouts/theme/layout.js +1 -1
- package/dist/src/vitnode.config.d.ts +16 -16
- package/dist/src/vitnode.config.d.ts.map +1 -1
- package/dist/src/vitnode.config.js +3 -2
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +2 -5
- package/src/app/login/page.tsx +5 -5
- package/src/app/login/reset-password/page.tsx +5 -5
- package/src/app/login/sso/[providerId]/page.tsx +1 -1
- package/src/app/register/page.tsx +5 -5
- package/src/app_admin/core/debug/page.tsx +14 -14
- package/src/app_admin/core/page.tsx +1 -1
- package/src/app_admin/core/test/page.tsx +1 -1
- package/src/app_admin/core/users/page.tsx +12 -13
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
2
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
3
|
import { XIcon } from "lucide-react";
|
|
4
4
|
import { useTranslations } from "next-intl";
|
|
5
5
|
import { Dialog as DialogPrimitive } from "radix-ui";
|
|
6
|
-
import
|
|
6
|
+
import React from "react";
|
|
7
7
|
import { cn } from "../../lib/utils.js";
|
|
8
8
|
import { AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogTitle } from "./alert-dialog.js";
|
|
9
9
|
const DialogContext = /*#__PURE__*/ React.createContext({
|
|
@@ -12,9 +12,9 @@ const DialogContext = /*#__PURE__*/ React.createContext({
|
|
|
12
12
|
isDirty: false,
|
|
13
13
|
setOpenAlertDialogBeforeClose: ()=>{}
|
|
14
14
|
});
|
|
15
|
-
|
|
15
|
+
const useDialog = ()=>React.use(DialogContext);
|
|
16
16
|
function Dialog({ onOpenChange, open: openProp, ...props }) {
|
|
17
|
-
const t = useTranslations(
|
|
17
|
+
const t = useTranslations("core.global");
|
|
18
18
|
const [open, setOpen] = React.useState(false);
|
|
19
19
|
const [isDirty, setIsDirty] = React.useState(false);
|
|
20
20
|
const [openAlertDialogBeforeClose, setOpenAlertDialogBeforeClose] = React.useState(false);
|
|
@@ -53,24 +53,24 @@ function Dialog({ onOpenChange, open: openProp, ...props }) {
|
|
|
53
53
|
/*#__PURE__*/ _jsxs(AlertDialogHeader, {
|
|
54
54
|
children: [
|
|
55
55
|
/*#__PURE__*/ _jsx(AlertDialogTitle, {
|
|
56
|
-
children: t(
|
|
56
|
+
children: t("are_you_sure_want_to_leave_form.title")
|
|
57
57
|
}),
|
|
58
58
|
/*#__PURE__*/ _jsx(AlertDialogDescription, {
|
|
59
|
-
children: t(
|
|
59
|
+
children: t("are_you_sure_want_to_leave_form.desc")
|
|
60
60
|
})
|
|
61
61
|
]
|
|
62
62
|
}),
|
|
63
63
|
/*#__PURE__*/ _jsxs(AlertDialogFooter, {
|
|
64
64
|
children: [
|
|
65
65
|
/*#__PURE__*/ _jsx(AlertDialogCancel, {
|
|
66
|
-
children: t(
|
|
66
|
+
children: t("are_you_sure_want_to_leave_form.cancel")
|
|
67
67
|
}),
|
|
68
68
|
/*#__PURE__*/ _jsx(AlertDialogAction, {
|
|
69
69
|
onClick: ()=>{
|
|
70
70
|
setIsDirty(false);
|
|
71
71
|
setTimeout(()=>setOpen(false), 100);
|
|
72
72
|
},
|
|
73
|
-
children: t(
|
|
73
|
+
children: t("are_you_sure_want_to_leave_form.confirm")
|
|
74
74
|
})
|
|
75
75
|
]
|
|
76
76
|
})
|
|
@@ -110,7 +110,7 @@ function DialogClose({ ...props }) {
|
|
|
110
110
|
}
|
|
111
111
|
function DialogOverlay({ className, ...props }) {
|
|
112
112
|
return /*#__PURE__*/ _jsx(DialogPrimitive.Overlay, {
|
|
113
|
-
className: cn(
|
|
113
|
+
className: cn("data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50", className),
|
|
114
114
|
"data-slot": "dialog-overlay",
|
|
115
115
|
...props
|
|
116
116
|
});
|
|
@@ -122,11 +122,11 @@ function DialogContent({ className, children, showCloseButton = true, ...props }
|
|
|
122
122
|
children: [
|
|
123
123
|
/*#__PURE__*/ _jsx(DialogOverlay, {}),
|
|
124
124
|
/*#__PURE__*/ _jsxs(DialogPrimitive.Content, {
|
|
125
|
-
className: cn(
|
|
125
|
+
className: cn("dark:bg-background bg-card data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 fixed left-[50%] top-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border p-6 shadow-lg duration-200 sm:max-w-lg", "max-h-[calc(100vh_-_2rem)] overflow-y-scroll sm:max-h-[calc(100vh_-_5rem)]", className),
|
|
126
126
|
"data-slot": "dialog-content",
|
|
127
127
|
onInteractOutside: (e)=>{
|
|
128
128
|
// Prevent dismissing the dialog when clicking on a toast
|
|
129
|
-
const isToastItem = e.target?.closest(
|
|
129
|
+
const isToastItem = e.target?.closest("[data-sonner-toaster]");
|
|
130
130
|
if (isToastItem || isDirty) e.preventDefault();
|
|
131
131
|
if (props?.onInteractOutside) {
|
|
132
132
|
props.onInteractOutside(e);
|
|
@@ -160,30 +160,30 @@ function DialogContent({ className, children, showCloseButton = true, ...props }
|
|
|
160
160
|
}
|
|
161
161
|
function DialogHeader({ className, ...props }) {
|
|
162
162
|
return /*#__PURE__*/ _jsx("div", {
|
|
163
|
-
className: cn(
|
|
163
|
+
className: cn("flex flex-col gap-2 text-center sm:text-left", className),
|
|
164
164
|
"data-slot": "dialog-header",
|
|
165
165
|
...props
|
|
166
166
|
});
|
|
167
167
|
}
|
|
168
168
|
function DialogFooter({ className, ...props }) {
|
|
169
169
|
return /*#__PURE__*/ _jsx("div", {
|
|
170
|
-
className: cn(
|
|
170
|
+
className: cn("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end", className),
|
|
171
171
|
"data-slot": "dialog-footer",
|
|
172
172
|
...props
|
|
173
173
|
});
|
|
174
174
|
}
|
|
175
175
|
function DialogTitle({ className, ...props }) {
|
|
176
176
|
return /*#__PURE__*/ _jsx(DialogPrimitive.Title, {
|
|
177
|
-
className: cn(
|
|
177
|
+
className: cn("text-lg font-semibold leading-none", className),
|
|
178
178
|
"data-slot": "dialog-title",
|
|
179
179
|
...props
|
|
180
180
|
});
|
|
181
181
|
}
|
|
182
182
|
function DialogDescription({ className, ...props }) {
|
|
183
183
|
return /*#__PURE__*/ _jsx(DialogPrimitive.Description, {
|
|
184
|
-
className: cn(
|
|
184
|
+
className: cn("text-muted-foreground text-sm", className),
|
|
185
185
|
"data-slot": "dialog-description",
|
|
186
186
|
...props
|
|
187
187
|
});
|
|
188
188
|
}
|
|
189
|
-
export { Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger };
|
|
189
|
+
export { Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, useDialog };
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import * as React from
|
|
2
|
-
import { Drawer as DrawerPrimitive } from
|
|
1
|
+
import type * as React from "react";
|
|
2
|
+
import { Drawer as DrawerPrimitive } from "vaul";
|
|
3
3
|
declare function Drawer({ ...props }: React.ComponentProps<typeof DrawerPrimitive.Root>): import("react/jsx-runtime").JSX.Element;
|
|
4
4
|
declare function DrawerTrigger({ ...props }: React.ComponentProps<typeof DrawerPrimitive.Trigger>): import("react/jsx-runtime").JSX.Element;
|
|
5
5
|
declare function DrawerPortal({ ...props }: React.ComponentProps<typeof DrawerPrimitive.Portal>): import("react/jsx-runtime").JSX.Element;
|
|
6
6
|
declare function DrawerClose({ ...props }: React.ComponentProps<typeof DrawerPrimitive.Close>): import("react/jsx-runtime").JSX.Element;
|
|
7
7
|
declare function DrawerOverlay({ className, ...props }: React.ComponentProps<typeof DrawerPrimitive.Overlay>): import("react/jsx-runtime").JSX.Element;
|
|
8
8
|
declare function DrawerContent({ className, children, ...props }: React.ComponentProps<typeof DrawerPrimitive.Content>): import("react/jsx-runtime").JSX.Element;
|
|
9
|
-
declare function DrawerHeader({ className, ...props }: React.ComponentProps<
|
|
10
|
-
declare function DrawerFooter({ className, ...props }: React.ComponentProps<
|
|
9
|
+
declare function DrawerHeader({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
declare function DrawerFooter({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element;
|
|
11
11
|
declare function DrawerTitle({ className, ...props }: React.ComponentProps<typeof DrawerPrimitive.Title>): import("react/jsx-runtime").JSX.Element;
|
|
12
12
|
declare function DrawerDescription({ className, ...props }: React.ComponentProps<typeof DrawerPrimitive.Description>): import("react/jsx-runtime").JSX.Element;
|
|
13
13
|
export { Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"drawer.d.ts","sourceRoot":"","sources":["../../../../src/components/ui/drawer.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"drawer.d.ts","sourceRoot":"","sources":["../../../../src/components/ui/drawer.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AACpC,OAAO,EAAE,MAAM,IAAI,eAAe,EAAE,MAAM,MAAM,CAAC;AAIjD,iBAAS,MAAM,CAAC,EACd,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,eAAe,CAAC,IAAI,CAAC,2CAEnD;AAED,iBAAS,aAAa,CAAC,EACrB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,eAAe,CAAC,OAAO,CAAC,2CAEtD;AAED,iBAAS,YAAY,CAAC,EACpB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,eAAe,CAAC,MAAM,CAAC,2CAErD;AAED,iBAAS,WAAW,CAAC,EACnB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,eAAe,CAAC,KAAK,CAAC,2CAEpD;AAED,iBAAS,aAAa,CAAC,EACrB,SAAS,EACT,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,eAAe,CAAC,OAAO,CAAC,2CAWtD;AAED,iBAAS,aAAa,CAAC,EACrB,SAAS,EACT,QAAQ,EACR,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,eAAe,CAAC,OAAO,CAAC,2CAqBtD;AAED,iBAAS,YAAY,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,2CAQzE;AAED,iBAAS,YAAY,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,2CAQzE;AAED,iBAAS,WAAW,CAAC,EACnB,SAAS,EACT,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,eAAe,CAAC,KAAK,CAAC,2CAQpD;AAED,iBAAS,iBAAiB,CAAC,EACzB,SAAS,EACT,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,eAAe,CAAC,WAAW,CAAC,2CAQ1D;AAED,OAAO,EACL,MAAM,EACN,WAAW,EACX,aAAa,EACb,iBAAiB,EACjB,YAAY,EACZ,YAAY,EACZ,aAAa,EACb,YAAY,EACZ,WAAW,EACX,aAAa,GACd,CAAC"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
2
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
-
import * as React from "react";
|
|
4
3
|
import { Drawer as DrawerPrimitive } from "vaul";
|
|
5
4
|
import { cn } from "../../lib/utils.js";
|
|
6
5
|
function Drawer({ ...props }) {
|
|
@@ -29,7 +28,7 @@ function DrawerClose({ ...props }) {
|
|
|
29
28
|
}
|
|
30
29
|
function DrawerOverlay({ className, ...props }) {
|
|
31
30
|
return /*#__PURE__*/ _jsx(DrawerPrimitive.Overlay, {
|
|
32
|
-
className: cn(
|
|
31
|
+
className: cn("data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50", className),
|
|
33
32
|
"data-slot": "drawer-overlay",
|
|
34
33
|
...props
|
|
35
34
|
});
|
|
@@ -40,7 +39,7 @@ function DrawerContent({ className, children, ...props }) {
|
|
|
40
39
|
children: [
|
|
41
40
|
/*#__PURE__*/ _jsx(DrawerOverlay, {}),
|
|
42
41
|
/*#__PURE__*/ _jsxs(DrawerPrimitive.Content, {
|
|
43
|
-
className: cn(
|
|
42
|
+
className: cn("group/drawer-content bg-background fixed z-50 flex h-auto flex-col", "data-[vaul-drawer-direction=top]:inset-x-0 data-[vaul-drawer-direction=top]:top-0 data-[vaul-drawer-direction=top]:mb-24 data-[vaul-drawer-direction=top]:max-h-[80vh] data-[vaul-drawer-direction=top]:rounded-b-lg data-[vaul-drawer-direction=top]:border-b", "data-[vaul-drawer-direction=bottom]:inset-x-0 data-[vaul-drawer-direction=bottom]:bottom-0 data-[vaul-drawer-direction=bottom]:mt-24 data-[vaul-drawer-direction=bottom]:max-h-[80vh] data-[vaul-drawer-direction=bottom]:rounded-t-lg data-[vaul-drawer-direction=bottom]:border-t", "data-[vaul-drawer-direction=right]:inset-y-0 data-[vaul-drawer-direction=right]:right-0 data-[vaul-drawer-direction=right]:w-3/4 data-[vaul-drawer-direction=right]:border-l data-[vaul-drawer-direction=right]:sm:max-w-sm", "data-[vaul-drawer-direction=left]:inset-y-0 data-[vaul-drawer-direction=left]:left-0 data-[vaul-drawer-direction=left]:w-3/4 data-[vaul-drawer-direction=left]:border-r data-[vaul-drawer-direction=left]:sm:max-w-sm", className),
|
|
44
43
|
"data-slot": "drawer-content",
|
|
45
44
|
...props,
|
|
46
45
|
children: [
|
|
@@ -55,28 +54,28 @@ function DrawerContent({ className, children, ...props }) {
|
|
|
55
54
|
}
|
|
56
55
|
function DrawerHeader({ className, ...props }) {
|
|
57
56
|
return /*#__PURE__*/ _jsx("div", {
|
|
58
|
-
className: cn(
|
|
57
|
+
className: cn("flex flex-col gap-1.5 p-4", className),
|
|
59
58
|
"data-slot": "drawer-header",
|
|
60
59
|
...props
|
|
61
60
|
});
|
|
62
61
|
}
|
|
63
62
|
function DrawerFooter({ className, ...props }) {
|
|
64
63
|
return /*#__PURE__*/ _jsx("div", {
|
|
65
|
-
className: cn(
|
|
64
|
+
className: cn("mt-auto flex flex-col gap-2 p-4", className),
|
|
66
65
|
"data-slot": "drawer-footer",
|
|
67
66
|
...props
|
|
68
67
|
});
|
|
69
68
|
}
|
|
70
69
|
function DrawerTitle({ className, ...props }) {
|
|
71
70
|
return /*#__PURE__*/ _jsx(DrawerPrimitive.Title, {
|
|
72
|
-
className: cn(
|
|
71
|
+
className: cn("text-foreground font-semibold", className),
|
|
73
72
|
"data-slot": "drawer-title",
|
|
74
73
|
...props
|
|
75
74
|
});
|
|
76
75
|
}
|
|
77
76
|
function DrawerDescription({ className, ...props }) {
|
|
78
77
|
return /*#__PURE__*/ _jsx(DrawerPrimitive.Description, {
|
|
79
|
-
className: cn(
|
|
78
|
+
className: cn("text-muted-foreground text-sm", className),
|
|
80
79
|
"data-slot": "drawer-description",
|
|
81
80
|
...props
|
|
82
81
|
});
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { DropdownMenu as DropdownMenuPrimitive } from
|
|
2
|
-
import * as React from
|
|
1
|
+
import { DropdownMenu as DropdownMenuPrimitive } from "radix-ui";
|
|
2
|
+
import type * as React from "react";
|
|
3
3
|
declare function DropdownMenu({ ...props }: React.ComponentProps<typeof DropdownMenuPrimitive.Root>): import("react/jsx-runtime").JSX.Element;
|
|
4
4
|
declare function DropdownMenuPortal({ ...props }: React.ComponentProps<typeof DropdownMenuPrimitive.Portal>): import("react/jsx-runtime").JSX.Element;
|
|
5
5
|
declare function DropdownMenuTrigger({ ...props }: React.ComponentProps<typeof DropdownMenuPrimitive.Trigger>): import("react/jsx-runtime").JSX.Element;
|
|
@@ -7,7 +7,7 @@ declare function DropdownMenuContent({ className, sideOffset, ...props }: React.
|
|
|
7
7
|
declare function DropdownMenuGroup({ ...props }: React.ComponentProps<typeof DropdownMenuPrimitive.Group>): import("react/jsx-runtime").JSX.Element;
|
|
8
8
|
declare function DropdownMenuItem({ className, inset, variant, ...props }: React.ComponentProps<typeof DropdownMenuPrimitive.Item> & {
|
|
9
9
|
inset?: boolean;
|
|
10
|
-
variant?:
|
|
10
|
+
variant?: "default" | "destructive";
|
|
11
11
|
}): import("react/jsx-runtime").JSX.Element;
|
|
12
12
|
declare function DropdownMenuCheckboxItem({ className, children, checked, ...props }: React.ComponentProps<typeof DropdownMenuPrimitive.CheckboxItem>): import("react/jsx-runtime").JSX.Element;
|
|
13
13
|
declare function DropdownMenuRadioGroup({ ...props }: React.ComponentProps<typeof DropdownMenuPrimitive.RadioGroup>): import("react/jsx-runtime").JSX.Element;
|
|
@@ -16,7 +16,7 @@ declare function DropdownMenuLabel({ className, inset, ...props }: React.Compone
|
|
|
16
16
|
inset?: boolean;
|
|
17
17
|
}): import("react/jsx-runtime").JSX.Element;
|
|
18
18
|
declare function DropdownMenuSeparator({ className, ...props }: React.ComponentProps<typeof DropdownMenuPrimitive.Separator>): import("react/jsx-runtime").JSX.Element;
|
|
19
|
-
declare function DropdownMenuShortcut({ className, ...props }: React.ComponentProps<
|
|
19
|
+
declare function DropdownMenuShortcut({ className, ...props }: React.ComponentProps<"span">): import("react/jsx-runtime").JSX.Element;
|
|
20
20
|
declare function DropdownMenuSub({ ...props }: React.ComponentProps<typeof DropdownMenuPrimitive.Sub>): import("react/jsx-runtime").JSX.Element;
|
|
21
21
|
declare function DropdownMenuSubTrigger({ className, inset, children, ...props }: React.ComponentProps<typeof DropdownMenuPrimitive.SubTrigger> & {
|
|
22
22
|
inset?: boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dropdown-menu.d.ts","sourceRoot":"","sources":["../../../../src/components/ui/dropdown-menu.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAE,YAAY,IAAI,qBAAqB,EAAE,MAAM,UAAU,CAAC;AACjE,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"dropdown-menu.d.ts","sourceRoot":"","sources":["../../../../src/components/ui/dropdown-menu.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAE,YAAY,IAAI,qBAAqB,EAAE,MAAM,UAAU,CAAC;AACjE,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AAIpC,iBAAS,YAAY,CAAC,EACpB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,qBAAqB,CAAC,IAAI,CAAC,2CAEzD;AAED,iBAAS,kBAAkB,CAAC,EAC1B,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,qBAAqB,CAAC,MAAM,CAAC,2CAI3D;AAED,iBAAS,mBAAmB,CAAC,EAC3B,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,qBAAqB,CAAC,OAAO,CAAC,2CAO5D;AAED,iBAAS,mBAAmB,CAAC,EAC3B,SAAS,EACT,UAAc,EACd,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,qBAAqB,CAAC,OAAO,CAAC,2CAc5D;AAED,iBAAS,iBAAiB,CAAC,EACzB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,qBAAqB,CAAC,KAAK,CAAC,2CAI1D;AAED,iBAAS,gBAAgB,CAAC,EACxB,SAAS,EACT,KAAK,EACL,OAAmB,EACnB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,qBAAqB,CAAC,IAAI,CAAC,GAAG;IAC3D,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,OAAO,CAAC,EAAE,SAAS,GAAG,aAAa,CAAC;CACrC,2CAaA;AAED,iBAAS,wBAAwB,CAAC,EAChC,SAAS,EACT,QAAQ,EACR,OAAO,EACP,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,qBAAqB,CAAC,YAAY,CAAC,2CAmBjE;AAED,iBAAS,sBAAsB,CAAC,EAC9B,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,qBAAqB,CAAC,UAAU,CAAC,2CAO/D;AAED,iBAAS,qBAAqB,CAAC,EAC7B,SAAS,EACT,QAAQ,EACR,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,qBAAqB,CAAC,SAAS,CAAC,2CAkB9D;AAED,iBAAS,iBAAiB,CAAC,EACzB,SAAS,EACT,KAAK,EACL,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,qBAAqB,CAAC,KAAK,CAAC,GAAG;IAC5D,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB,2CAYA;AAED,iBAAS,qBAAqB,CAAC,EAC7B,SAAS,EACT,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,qBAAqB,CAAC,SAAS,CAAC,2CAQ9D;AAED,iBAAS,oBAAoB,CAAC,EAC5B,SAAS,EACT,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,MAAM,CAAC,2CAW9B;AAED,iBAAS,eAAe,CAAC,EACvB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,qBAAqB,CAAC,GAAG,CAAC,2CAExD;AAED,iBAAS,sBAAsB,CAAC,EAC9B,SAAS,EACT,KAAK,EACL,QAAQ,EACR,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,qBAAqB,CAAC,UAAU,CAAC,GAAG;IACjE,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB,2CAeA;AAED,iBAAS,sBAAsB,CAAC,EAC9B,SAAS,EACT,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,qBAAqB,CAAC,UAAU,CAAC,2CAW/D;AAED,OAAO,EACL,YAAY,EACZ,wBAAwB,EACxB,mBAAmB,EACnB,iBAAiB,EACjB,gBAAgB,EAChB,iBAAiB,EACjB,kBAAkB,EAClB,sBAAsB,EACtB,qBAAqB,EACrB,qBAAqB,EACrB,oBAAoB,EACpB,eAAe,EACf,sBAAsB,EACtB,sBAAsB,EACtB,mBAAmB,GACpB,CAAC"}
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
2
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
3
|
import { CheckIcon, ChevronRightIcon, CircleIcon } from "lucide-react";
|
|
4
4
|
import { DropdownMenu as DropdownMenuPrimitive } from "radix-ui";
|
|
5
|
-
import * as React from "react";
|
|
6
5
|
import { cn } from "../../lib/utils.js";
|
|
7
6
|
function DropdownMenu({ ...props }) {
|
|
8
7
|
return /*#__PURE__*/ _jsx(DropdownMenuPrimitive.Root, {
|
|
@@ -25,7 +24,7 @@ function DropdownMenuTrigger({ ...props }) {
|
|
|
25
24
|
function DropdownMenuContent({ className, sideOffset = 4, ...props }) {
|
|
26
25
|
return /*#__PURE__*/ _jsx(DropdownMenuPrimitive.Portal, {
|
|
27
26
|
children: /*#__PURE__*/ _jsx(DropdownMenuPrimitive.Content, {
|
|
28
|
-
className: cn(
|
|
27
|
+
className: cn("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 max-h-(--radix-dropdown-menu-content-available-height) origin-(--radix-dropdown-menu-content-transform-origin) z-50 min-w-[8rem] overflow-y-auto overflow-x-hidden rounded-md border p-1 shadow-md", className),
|
|
29
28
|
"data-slot": "dropdown-menu-content",
|
|
30
29
|
sideOffset: sideOffset,
|
|
31
30
|
...props
|
|
@@ -38,7 +37,7 @@ function DropdownMenuGroup({ ...props }) {
|
|
|
38
37
|
...props
|
|
39
38
|
});
|
|
40
39
|
}
|
|
41
|
-
function DropdownMenuItem({ className, inset, variant =
|
|
40
|
+
function DropdownMenuItem({ className, inset, variant = "default", ...props }) {
|
|
42
41
|
return /*#__PURE__*/ _jsx(DropdownMenuPrimitive.Item, {
|
|
43
42
|
className: cn("focus:bg-accent focus:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 dark:data-[variant=destructive]:focus:bg-destructive/20 data-[variant=destructive]:focus:text-destructive data-[variant=destructive]:*:[svg]:!text-destructive [&_svg:not([class*='text-'])]:text-muted-foreground outline-hidden relative flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm data-[disabled]:pointer-events-none data-[inset]:pl-8 data-[disabled]:opacity-50 [&_svg:not([class*='size-'])]:size-4 [&_svg]:pointer-events-none [&_svg]:shrink-0", className),
|
|
44
43
|
"data-inset": inset,
|
|
@@ -92,7 +91,7 @@ function DropdownMenuRadioItem({ className, children, ...props }) {
|
|
|
92
91
|
}
|
|
93
92
|
function DropdownMenuLabel({ className, inset, ...props }) {
|
|
94
93
|
return /*#__PURE__*/ _jsx(DropdownMenuPrimitive.Label, {
|
|
95
|
-
className: cn(
|
|
94
|
+
className: cn("px-2 py-1.5 text-sm font-medium data-[inset]:pl-8", className),
|
|
96
95
|
"data-inset": inset,
|
|
97
96
|
"data-slot": "dropdown-menu-label",
|
|
98
97
|
...props
|
|
@@ -100,14 +99,14 @@ function DropdownMenuLabel({ className, inset, ...props }) {
|
|
|
100
99
|
}
|
|
101
100
|
function DropdownMenuSeparator({ className, ...props }) {
|
|
102
101
|
return /*#__PURE__*/ _jsx(DropdownMenuPrimitive.Separator, {
|
|
103
|
-
className: cn(
|
|
102
|
+
className: cn("bg-border -mx-1 my-1 h-px", className),
|
|
104
103
|
"data-slot": "dropdown-menu-separator",
|
|
105
104
|
...props
|
|
106
105
|
});
|
|
107
106
|
}
|
|
108
107
|
function DropdownMenuShortcut({ className, ...props }) {
|
|
109
108
|
return /*#__PURE__*/ _jsx("span", {
|
|
110
|
-
className: cn(
|
|
109
|
+
className: cn("text-muted-foreground ml-auto text-xs tracking-widest", className),
|
|
111
110
|
"data-slot": "dropdown-menu-shortcut",
|
|
112
111
|
...props
|
|
113
112
|
});
|
|
@@ -120,7 +119,7 @@ function DropdownMenuSub({ ...props }) {
|
|
|
120
119
|
}
|
|
121
120
|
function DropdownMenuSubTrigger({ className, inset, children, ...props }) {
|
|
122
121
|
return /*#__PURE__*/ _jsxs(DropdownMenuPrimitive.SubTrigger, {
|
|
123
|
-
className: cn(
|
|
122
|
+
className: cn("focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground outline-hidden flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm data-[inset]:pl-8", className),
|
|
124
123
|
"data-inset": inset,
|
|
125
124
|
"data-slot": "dropdown-menu-sub-trigger",
|
|
126
125
|
...props,
|
|
@@ -134,7 +133,7 @@ function DropdownMenuSubTrigger({ className, inset, children, ...props }) {
|
|
|
134
133
|
}
|
|
135
134
|
function DropdownMenuSubContent({ className, ...props }) {
|
|
136
135
|
return /*#__PURE__*/ _jsx(DropdownMenuPrimitive.SubContent, {
|
|
137
|
-
className: cn(
|
|
136
|
+
className: cn("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-(--radix-dropdown-menu-content-transform-origin) z-50 min-w-[8rem] overflow-hidden rounded-md border p-1 shadow-lg", className),
|
|
138
137
|
"data-slot": "dropdown-menu-sub-content",
|
|
139
138
|
...props
|
|
140
139
|
});
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import type { Label as LabelPrimitive } from
|
|
2
|
-
import { Slot } from
|
|
3
|
-
import
|
|
4
|
-
import { type ControllerProps, type FieldPath, type FieldValues, FormProvider, type SubmitHandler } from
|
|
5
|
-
import { Button } from
|
|
6
|
-
declare function Form<TFieldValues extends FieldValues, TContext = unknown, TTransformedValues extends FieldValues | undefined = undefined>({ children, form, className, onSubmit, ...props }: Omit<React.ComponentProps<
|
|
1
|
+
import type { Label as LabelPrimitive } from "radix-ui";
|
|
2
|
+
import { Slot } from "radix-ui";
|
|
3
|
+
import React from "react";
|
|
4
|
+
import { type ControllerProps, type FieldPath, type FieldValues, FormProvider, type SubmitHandler } from "react-hook-form";
|
|
5
|
+
import { Button } from "./button";
|
|
6
|
+
declare function Form<TFieldValues extends FieldValues, TContext = unknown, TTransformedValues extends FieldValues | undefined = undefined>({ children, form, className, onSubmit, ...props }: Omit<React.ComponentProps<"form">, "onSubmit"> & {
|
|
7
7
|
disableBeforeUnload?: boolean;
|
|
8
|
-
form: Omit<React.ComponentProps<typeof FormProvider<TFieldValues, TContext, TTransformedValues>>,
|
|
8
|
+
form: Omit<React.ComponentProps<typeof FormProvider<TFieldValues, TContext, TTransformedValues>>, "children">;
|
|
9
9
|
onSubmit: SubmitHandler<TTransformedValues>;
|
|
10
10
|
}): import("react/jsx-runtime").JSX.Element;
|
|
11
11
|
declare const FormField: <TFieldValues extends FieldValues = FieldValues, TName extends FieldPath<TFieldValues> = FieldPath<TFieldValues>>({ ...props }: ControllerProps<TFieldValues, TName>) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -21,13 +21,13 @@ declare const useFormField: () => {
|
|
|
21
21
|
formDescriptionId: string;
|
|
22
22
|
formMessageId: string;
|
|
23
23
|
};
|
|
24
|
-
declare function FormItem({ className, ...props }: React.ComponentProps<
|
|
24
|
+
declare function FormItem({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element;
|
|
25
25
|
declare function FormLabel({ className, children, isOptional, ...props }: React.ComponentProps<typeof LabelPrimitive.Root> & {
|
|
26
26
|
isOptional?: boolean;
|
|
27
27
|
}): import("react/jsx-runtime").JSX.Element;
|
|
28
28
|
declare function FormControl({ ...props }: React.ComponentProps<typeof Slot.Root>): import("react/jsx-runtime").JSX.Element;
|
|
29
|
-
declare function FormDescription({ className, ...props }: React.ComponentProps<
|
|
30
|
-
declare function FormMessage({ className, ...props }: React.ComponentProps<
|
|
29
|
+
declare function FormDescription({ className, ...props }: React.ComponentProps<"p">): import("react/jsx-runtime").JSX.Element;
|
|
30
|
+
declare function FormMessage({ className, ...props }: React.ComponentProps<"p">): import("react/jsx-runtime").JSX.Element | null;
|
|
31
31
|
declare const FormButtonSubmit: ({ className, ...props }: React.ComponentProps<typeof Button>) => import("react/jsx-runtime").JSX.Element;
|
|
32
32
|
export { Form, FormButtonSubmit, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, useFormField, };
|
|
33
33
|
//# sourceMappingURL=form.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"form.d.ts","sourceRoot":"","sources":["../../../../src/components/ui/form.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"form.d.ts","sourceRoot":"","sources":["../../../../src/components/ui/form.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,KAAK,IAAI,cAAc,EAAE,MAAM,UAAU,CAAC;AACxD,OAAO,EAAE,IAAI,EAAE,MAAM,UAAU,CAAC;AAChC,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAEL,KAAK,eAAe,EACpB,KAAK,SAAS,EACd,KAAK,WAAW,EAChB,YAAY,EACZ,KAAK,aAAa,EAGnB,MAAM,iBAAiB,CAAC;AAMzB,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAGlC,iBAAS,IAAI,CACX,YAAY,SAAS,WAAW,EAChC,QAAQ,GAAG,OAAO,EAClB,kBAAkB,SAAS,WAAW,GAAG,SAAS,GAAG,SAAS,EAC9D,EACA,QAAQ,EACR,IAAI,EACJ,SAAS,EACT,QAAQ,EACR,GAAG,KAAK,EACT,EAAE,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,MAAM,CAAC,EAAE,UAAU,CAAC,GAAG;IAClD,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAC9B,IAAI,EAAE,IAAI,CACR,KAAK,CAAC,cAAc,CAClB,OAAO,YAAY,CAAC,YAAY,EAAE,QAAQ,EAAE,kBAAkB,CAAC,CAChE,EACD,UAAU,CACX,CAAC;IACF,QAAQ,EAAE,aAAa,CAAC,kBAAkB,CAAC,CAAC;CAC7C,2CA0BA;AAaD,QAAA,MAAM,SAAS,GACb,YAAY,SAAS,WAAW,GAAG,WAAW,EAC9C,KAAK,SAAS,SAAS,CAAC,YAAY,CAAC,GAAG,SAAS,CAAC,YAAY,CAAC,EAC/D,cAEC,eAAe,CAAC,YAAY,EAAE,KAAK,CAAC,4CAWtC,CAAC;AAEF,QAAA,MAAM,YAAY;;;;;;;;;;;CAqBjB,CAAC;AAUF,iBAAS,QAAQ,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,2CAarE;AAED,iBAAS,SAAS,CAAC,EACjB,SAAS,EACT,QAAQ,EACR,UAAU,EACV,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,cAAc,CAAC,IAAI,CAAC,GAAG;IACpD,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB,2CAkBA;AAED,iBAAS,WAAW,CAAC,EAAE,GAAG,KAAK,EAAE,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,IAAI,CAAC,IAAI,CAAC,2CAexE;AAED,iBAAS,eAAe,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,KAAK,CAAC,cAAc,CAAC,GAAG,CAAC,2CAW1E;AAED,iBAAS,WAAW,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,KAAK,CAAC,cAAc,CAAC,GAAG,CAAC,kDAkBtE;AAED,QAAA,MAAM,gBAAgB,GAAI,yBAGvB,KAAK,CAAC,cAAc,CAAC,OAAO,MAAM,CAAC,4CAYrC,CAAC;AAEF,OAAO,EACL,IAAI,EACJ,gBAAgB,EAChB,WAAW,EACX,eAAe,EACf,SAAS,EACT,QAAQ,EACR,SAAS,EACT,WAAW,EACX,YAAY,GACb,CAAC"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
2
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
3
|
import { useTranslations } from "next-intl";
|
|
4
4
|
import { Slot } from "radix-ui";
|
|
5
|
-
import
|
|
5
|
+
import React from "react";
|
|
6
6
|
import { Controller, FormProvider, useFormContext, useFormState } from "react-hook-form";
|
|
7
7
|
import { Label } from "./label.js";
|
|
8
8
|
import { cn } from "../../lib/utils.js";
|
|
@@ -10,9 +10,9 @@ import { useBeforeUnload } from "../../hooks/use-before-unload.js";
|
|
|
10
10
|
import { Button } from "./button.js";
|
|
11
11
|
import { useDialog } from "./dialog.js";
|
|
12
12
|
function Form({ children, form, className, onSubmit, ...props }) {
|
|
13
|
-
const t = useTranslations(
|
|
13
|
+
const t = useTranslations("core.global");
|
|
14
14
|
const formIsDirty = form.formState.isDirty;
|
|
15
|
-
useBeforeUnload(formIsDirty && !props.disableBeforeUnload, `${t(
|
|
15
|
+
useBeforeUnload(formIsDirty && !props.disableBeforeUnload, `${t("are_you_sure_want_to_leave_form.title")} ${t("are_you_sure_want_to_leave_form.desc")}`);
|
|
16
16
|
const { setIsDirty } = useDialog();
|
|
17
17
|
React.useEffect(()=>{
|
|
18
18
|
if (props.disableBeforeUnload) return;
|
|
@@ -25,7 +25,7 @@ function Form({ children, form, className, onSubmit, ...props }) {
|
|
|
25
25
|
return /*#__PURE__*/ _jsx(FormProvider, {
|
|
26
26
|
...form,
|
|
27
27
|
children: /*#__PURE__*/ _jsx("form", {
|
|
28
|
-
className: cn(
|
|
28
|
+
className: cn("space-y-8", className),
|
|
29
29
|
onSubmit: form.handleSubmit(onSubmit),
|
|
30
30
|
...props,
|
|
31
31
|
children: children
|
|
@@ -55,7 +55,7 @@ const useFormField = ()=>{
|
|
|
55
55
|
});
|
|
56
56
|
const fieldState = getFieldState(fieldContext.name, formState);
|
|
57
57
|
if (!fieldContext) {
|
|
58
|
-
throw new Error(
|
|
58
|
+
throw new Error("useFormField should be used within <FormField>");
|
|
59
59
|
}
|
|
60
60
|
const { id } = itemContext;
|
|
61
61
|
return {
|
|
@@ -78,17 +78,17 @@ function FormItem({ className, ...props }) {
|
|
|
78
78
|
return /*#__PURE__*/ _jsx(FormItemContext, {
|
|
79
79
|
value: contextValue,
|
|
80
80
|
children: /*#__PURE__*/ _jsx("div", {
|
|
81
|
-
className: cn(
|
|
81
|
+
className: cn("grid gap-2", className),
|
|
82
82
|
"data-slot": "form-item",
|
|
83
83
|
...props
|
|
84
84
|
})
|
|
85
85
|
});
|
|
86
86
|
}
|
|
87
87
|
function FormLabel({ className, children, isOptional, ...props }) {
|
|
88
|
-
const t = useTranslations(
|
|
88
|
+
const t = useTranslations("core.global");
|
|
89
89
|
const { error, formItemId } = useFormField();
|
|
90
90
|
return /*#__PURE__*/ _jsxs(Label, {
|
|
91
|
-
className: cn(
|
|
91
|
+
className: cn("data-[error=true]:text-destructive", className),
|
|
92
92
|
"data-error": !!error,
|
|
93
93
|
"data-slot": "form-label",
|
|
94
94
|
htmlFor: formItemId,
|
|
@@ -97,7 +97,7 @@ function FormLabel({ className, children, isOptional, ...props }) {
|
|
|
97
97
|
children,
|
|
98
98
|
isOptional && /*#__PURE__*/ _jsx("span", {
|
|
99
99
|
className: "text-muted-foreground text-xs",
|
|
100
|
-
children: t(
|
|
100
|
+
children: t("optional")
|
|
101
101
|
})
|
|
102
102
|
]
|
|
103
103
|
});
|
|
@@ -105,7 +105,7 @@ function FormLabel({ className, children, isOptional, ...props }) {
|
|
|
105
105
|
function FormControl({ ...props }) {
|
|
106
106
|
const { error, formItemId, formDescriptionId, formMessageId } = useFormField();
|
|
107
107
|
return /*#__PURE__*/ _jsx(Slot.Root, {
|
|
108
|
-
"aria-describedby":
|
|
108
|
+
"aria-describedby": error ? `${formDescriptionId} ${formMessageId}` : formDescriptionId,
|
|
109
109
|
"aria-invalid": !!error,
|
|
110
110
|
"data-slot": "form-control",
|
|
111
111
|
id: formItemId,
|
|
@@ -115,7 +115,7 @@ function FormControl({ ...props }) {
|
|
|
115
115
|
function FormDescription({ className, ...props }) {
|
|
116
116
|
const { formDescriptionId } = useFormField();
|
|
117
117
|
return /*#__PURE__*/ _jsx("p", {
|
|
118
|
-
className: cn(
|
|
118
|
+
className: cn("text-muted-foreground text-sm", className),
|
|
119
119
|
"data-slot": "form-description",
|
|
120
120
|
id: formDescriptionId,
|
|
121
121
|
...props
|
|
@@ -123,12 +123,12 @@ function FormDescription({ className, ...props }) {
|
|
|
123
123
|
}
|
|
124
124
|
function FormMessage({ className, ...props }) {
|
|
125
125
|
const { error, formMessageId } = useFormField();
|
|
126
|
-
const body = error ? error?.message ??
|
|
126
|
+
const body = error ? error?.message ?? "" : props.children;
|
|
127
127
|
if (!body) {
|
|
128
128
|
return null;
|
|
129
129
|
}
|
|
130
130
|
return /*#__PURE__*/ _jsx("p", {
|
|
131
|
-
className: cn(
|
|
131
|
+
className: cn("text-destructive text-sm", className),
|
|
132
132
|
"data-slot": "form-message",
|
|
133
133
|
id: formMessageId,
|
|
134
134
|
...props,
|
|
@@ -138,7 +138,7 @@ function FormMessage({ className, ...props }) {
|
|
|
138
138
|
const FormButtonSubmit = ({ className, ...props })=>{
|
|
139
139
|
const { formState } = useFormContext();
|
|
140
140
|
return /*#__PURE__*/ _jsx(Button, {
|
|
141
|
-
className: cn(
|
|
141
|
+
className: cn("w-full", className),
|
|
142
142
|
disabled: !formState.isValid,
|
|
143
143
|
isLoading: formState.isSubmitting,
|
|
144
144
|
type: "submit",
|
|
@@ -2,7 +2,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
2
2
|
import { cn } from "../../lib/utils.js";
|
|
3
3
|
export const HeaderContent = ({ children, className, desc, h1, h2, ref })=>{
|
|
4
4
|
return /*#__PURE__*/ _jsxs("div", {
|
|
5
|
-
className: cn(
|
|
5
|
+
className: cn("mb-6 flex min-h-9 flex-col items-start gap-2 sm:flex-row sm:gap-4", className),
|
|
6
6
|
ref: ref,
|
|
7
7
|
children: [
|
|
8
8
|
/*#__PURE__*/ _jsxs("div", {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { HoverCard as HoverCardPrimitive } from
|
|
2
|
-
import * as React from
|
|
1
|
+
import { HoverCard as HoverCardPrimitive } from "radix-ui";
|
|
2
|
+
import type * as React from "react";
|
|
3
3
|
declare function HoverCard({ ...props }: React.ComponentProps<typeof HoverCardPrimitive.Root>): import("react/jsx-runtime").JSX.Element;
|
|
4
4
|
declare function HoverCardTrigger({ ...props }: React.ComponentProps<typeof HoverCardPrimitive.Trigger>): import("react/jsx-runtime").JSX.Element;
|
|
5
5
|
declare function HoverCardContent({ className, align, sideOffset, ...props }: React.ComponentProps<typeof HoverCardPrimitive.Content>): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"hover-card.d.ts","sourceRoot":"","sources":["../../../../src/components/ui/hover-card.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,SAAS,IAAI,kBAAkB,EAAE,MAAM,UAAU,CAAC;AAC3D,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"hover-card.d.ts","sourceRoot":"","sources":["../../../../src/components/ui/hover-card.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,SAAS,IAAI,kBAAkB,EAAE,MAAM,UAAU,CAAC;AAC3D,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AAIpC,iBAAS,SAAS,CAAC,EACjB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,kBAAkB,CAAC,IAAI,CAAC,2CAEtD;AAED,iBAAS,gBAAgB,CAAC,EACxB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,kBAAkB,CAAC,OAAO,CAAC,2CAIzD;AAED,iBAAS,gBAAgB,CAAC,EACxB,SAAS,EACT,KAAgB,EAChB,UAAc,EACd,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,kBAAkB,CAAC,OAAO,CAAC,2CAezD;AAED,OAAO,EAAE,SAAS,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,CAAC"}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
2
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
3
3
|
import { HoverCard as HoverCardPrimitive } from "radix-ui";
|
|
4
|
-
import * as React from "react";
|
|
5
4
|
import { cn } from "../../lib/utils.js";
|
|
6
5
|
function HoverCard({ ...props }) {
|
|
7
6
|
return /*#__PURE__*/ _jsx(HoverCardPrimitive.Root, {
|
|
@@ -15,12 +14,12 @@ function HoverCardTrigger({ ...props }) {
|
|
|
15
14
|
...props
|
|
16
15
|
});
|
|
17
16
|
}
|
|
18
|
-
function HoverCardContent({ className, align =
|
|
17
|
+
function HoverCardContent({ className, align = "center", sideOffset = 4, ...props }) {
|
|
19
18
|
return /*#__PURE__*/ _jsx(HoverCardPrimitive.Portal, {
|
|
20
19
|
"data-slot": "hover-card-portal",
|
|
21
20
|
children: /*#__PURE__*/ _jsx(HoverCardPrimitive.Content, {
|
|
22
21
|
align: align,
|
|
23
|
-
className: cn(
|
|
22
|
+
className: cn("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-(--radix-hover-card-content-transform-origin) outline-hidden z-50 w-64 rounded-md border p-4 shadow-md", className),
|
|
24
23
|
"data-slot": "hover-card-content",
|
|
25
24
|
sideOffset: sideOffset,
|
|
26
25
|
...props
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { OTPInput } from
|
|
2
|
-
import
|
|
1
|
+
import { OTPInput } from "input-otp";
|
|
2
|
+
import React from "react";
|
|
3
3
|
declare function InputOTP({ className, containerClassName, ...props }: React.ComponentProps<typeof OTPInput> & {
|
|
4
4
|
containerClassName?: string;
|
|
5
5
|
}): import("react/jsx-runtime").JSX.Element;
|
|
6
|
-
declare function InputOTPGroup({ className, ...props }: React.ComponentProps<
|
|
7
|
-
declare function InputOTPSlot({ index, className, ...props }: React.ComponentProps<
|
|
6
|
+
declare function InputOTPGroup({ className, ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
declare function InputOTPSlot({ index, className, ...props }: React.ComponentProps<"div"> & {
|
|
8
8
|
index: number;
|
|
9
9
|
}): import("react/jsx-runtime").JSX.Element;
|
|
10
|
-
declare function InputOTPSeparator({ ...props }: React.ComponentProps<
|
|
10
|
+
declare function InputOTPSeparator({ ...props }: React.ComponentProps<"div">): import("react/jsx-runtime").JSX.Element;
|
|
11
11
|
export { InputOTP, InputOTPGroup, InputOTPSeparator, InputOTPSlot };
|
|
12
12
|
//# sourceMappingURL=input-otp.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"input-otp.d.ts","sourceRoot":"","sources":["../../../../src/components/ui/input-otp.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,QAAQ,EAAmB,MAAM,WAAW,CAAC;AAEtD,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"input-otp.d.ts","sourceRoot":"","sources":["../../../../src/components/ui/input-otp.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,QAAQ,EAAmB,MAAM,WAAW,CAAC;AAEtD,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,iBAAS,QAAQ,CAAC,EAChB,SAAS,EACT,kBAAkB,EAClB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,QAAQ,CAAC,GAAG;IACzC,kBAAkB,CAAC,EAAE,MAAM,CAAC;CAC7B,2CAYA;AAED,iBAAS,aAAa,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,2CAQ1E;AAED,iBAAS,YAAY,CAAC,EACpB,KAAK,EACL,SAAS,EACT,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,GAAG;IAC/B,KAAK,EAAE,MAAM,CAAC;CACf,2CAsBA;AAED,iBAAS,iBAAiB,CAAC,EAAE,GAAG,KAAK,EAAE,EAAE,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,2CAMnE;AAED,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,iBAAiB,EAAE,YAAY,EAAE,CAAC"}
|
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
2
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
3
|
import { OTPInput, OTPInputContext } from "input-otp";
|
|
4
4
|
import { MinusIcon } from "lucide-react";
|
|
5
|
-
import
|
|
5
|
+
import React from "react";
|
|
6
6
|
import { cn } from "../../lib/utils.js";
|
|
7
7
|
function InputOTP({ className, containerClassName, ...props }) {
|
|
8
8
|
return /*#__PURE__*/ _jsx(OTPInput, {
|
|
9
|
-
className: cn(
|
|
10
|
-
containerClassName: cn(
|
|
9
|
+
className: cn("disabled:cursor-not-allowed", className),
|
|
10
|
+
containerClassName: cn("has-disabled:opacity-50 flex items-center gap-2", containerClassName),
|
|
11
11
|
"data-slot": "input-otp",
|
|
12
12
|
...props
|
|
13
13
|
});
|
|
14
14
|
}
|
|
15
15
|
function InputOTPGroup({ className, ...props }) {
|
|
16
16
|
return /*#__PURE__*/ _jsx("div", {
|
|
17
|
-
className: cn(
|
|
17
|
+
className: cn("flex items-center", className),
|
|
18
18
|
"data-slot": "input-otp-group",
|
|
19
19
|
...props
|
|
20
20
|
});
|
|
@@ -23,7 +23,7 @@ function InputOTPSlot({ index, className, ...props }) {
|
|
|
23
23
|
const inputOTPContext = React.use(OTPInputContext);
|
|
24
24
|
const { char, hasFakeCaret, isActive } = inputOTPContext?.slots[index] ?? {};
|
|
25
25
|
return /*#__PURE__*/ _jsxs("div", {
|
|
26
|
-
className: cn(
|
|
26
|
+
className: cn("data-[active=true]:border-ring data-[active=true]:ring-ring/50 data-[active=true]:aria-invalid:ring-destructive/20 dark:data-[active=true]:aria-invalid:ring-destructive/40 aria-invalid:border-destructive data-[active=true]:aria-invalid:border-destructive dark:bg-input/30 border-input shadow-xs relative flex h-9 w-9 items-center justify-center border-y border-r text-sm outline-none transition-all first:rounded-l-md first:border-l last:rounded-r-md data-[active=true]:z-10 data-[active=true]:ring-[3px]", className),
|
|
27
27
|
"data-active": isActive,
|
|
28
28
|
"data-slot": "input-otp-slot",
|
|
29
29
|
...props,
|
|
@@ -41,7 +41,6 @@ function InputOTPSlot({ index, className, ...props }) {
|
|
|
41
41
|
function InputOTPSeparator({ ...props }) {
|
|
42
42
|
return /*#__PURE__*/ _jsx("div", {
|
|
43
43
|
"data-slot": "input-otp-separator",
|
|
44
|
-
role: "separator",
|
|
45
44
|
...props,
|
|
46
45
|
children: /*#__PURE__*/ _jsx(MinusIcon, {})
|
|
47
46
|
});
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as React from
|
|
2
|
-
declare function Input({ className, type, ...props }: React.ComponentProps<
|
|
1
|
+
import type * as React from "react";
|
|
2
|
+
declare function Input({ className, type, ...props }: React.ComponentProps<"input">): import("react/jsx-runtime").JSX.Element;
|
|
3
3
|
export { Input };
|
|
4
4
|
//# sourceMappingURL=input.d.ts.map
|