@tulip-systems/core 0.2.1 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/auth/client.d.ts +3 -1
- package/dist/auth/client.js +4 -2
- package/dist/auth/server.d.ts +2 -2
- package/dist/auth/server.js +3 -3
- package/dist/auth.d.ts +2 -1
- package/dist/auth.js +3 -2
- package/dist/commands/client.d.ts +4 -4
- package/dist/commands/client.js +4 -4
- package/dist/components/client.d.ts +5 -3
- package/dist/components/client.js +6 -4
- package/dist/components/common/icons.d.ts +5 -2
- package/dist/components/common/icons.d.ts.map +1 -1
- package/dist/components/common/icons.js +4 -1
- package/dist/components/common/icons.js.map +1 -1
- package/dist/components/common/status.d.ts +3 -3
- package/dist/components/editor/components/content.client.d.ts +2 -2
- package/dist/components/editor/components/fixed-menu.client.d.ts +2 -2
- package/dist/components/editor/context.client.d.ts +2 -2
- package/dist/components/editor/index.client.d.ts +2 -2
- package/dist/components/editor/preview.client.d.ts +2 -2
- package/dist/components/header/back-button.client.d.ts +2 -2
- package/dist/components/header/bottom-bar.client.d.ts +5 -5
- package/dist/components/header/bottom-bar.client.d.ts.map +1 -1
- package/dist/components/header/bottom-bar.client.js.map +1 -1
- package/dist/components/header/breadcrumbs.client.d.ts +7 -7
- package/dist/components/header/breadcrumbs.client.js +1 -1
- package/dist/components/header/header.client.d.ts +2 -2
- package/dist/components/header/mobile-nav-switcher.client.d.ts +2 -2
- package/dist/components/header/top-bar.client.d.ts +4 -4
- package/dist/components/layouts/admin-content.client.d.ts +13 -0
- package/dist/components/layouts/admin-content.client.d.ts.map +1 -0
- package/dist/components/layouts/admin-layout.d.ts +8 -0
- package/dist/components/layouts/admin-layout.d.ts.map +1 -0
- package/dist/components/layouts/admin-layout.js +15 -0
- package/dist/components/layouts/admin-layout.js.map +1 -0
- package/dist/components/layouts/admin-loading.d.ts +3 -3
- package/dist/components/layouts/admin-loading.d.ts.map +1 -1
- package/dist/components/layouts/admin-loading.js +2 -2
- package/dist/components/layouts/admin-loading.js.map +1 -1
- package/dist/components/layouts/empty-page.d.ts +4 -4
- package/dist/components/layouts/list-layout.d.ts +2 -2
- package/dist/components/layouts/not-found-page.d.ts +4 -3
- package/dist/components/layouts/not-found-page.d.ts.map +1 -1
- package/dist/components/layouts/not-found-page.js +8 -2
- package/dist/components/layouts/not-found-page.js.map +1 -1
- package/dist/components/layouts/not-found-section.js +1 -1
- package/dist/components/layouts/not-found-section.js.map +1 -1
- package/dist/components/layouts/providers.client.d.ts +2 -2
- package/dist/components/layouts/root-layout.server.d.ts +2 -2
- package/dist/components/layouts/root-layout.server.d.ts.map +1 -1
- package/dist/components/layouts/root-loading.d.ts +7 -0
- package/dist/components/layouts/root-loading.d.ts.map +1 -0
- package/dist/components/layouts/root-loading.js +14 -0
- package/dist/components/layouts/root-loading.js.map +1 -0
- package/dist/components/layouts/tab-layout.d.ts +2 -2
- package/dist/components/lists/data-list.d.ts +5 -5
- package/dist/components/lists/data-stack.d.ts +8 -8
- package/dist/components/{layouts → navigation}/admin-sidebar-header.client.js +8 -9
- package/dist/components/navigation/admin-sidebar-header.client.js.map +1 -0
- package/dist/components/navigation/admin-sidebar-paths.client.d.ts +81 -0
- package/dist/components/navigation/admin-sidebar-paths.client.d.ts.map +1 -0
- package/dist/components/navigation/admin-sidebar-paths.client.js +143 -0
- package/dist/components/navigation/admin-sidebar-paths.client.js.map +1 -0
- package/dist/components/navigation/admin-sidebar-skeleton.js +31 -0
- package/dist/components/navigation/admin-sidebar-skeleton.js.map +1 -0
- package/dist/components/server.d.ts +1 -1
- package/dist/components/server.js +1 -1
- package/dist/components/ui/accordion.d.ts +5 -5
- package/dist/components/ui/alert-dialog.d.ts +12 -12
- package/dist/components/ui/alert.d.ts +6 -6
- package/dist/components/ui/aspect-ratio.d.ts +2 -2
- package/dist/components/ui/avatar.client.d.ts +4 -4
- package/dist/components/ui/badge.d.ts +4 -4
- package/dist/components/ui/breadcrumb.d.ts +8 -8
- package/dist/components/ui/button.d.ts +4 -4
- package/dist/components/ui/calendar.d.ts +2 -2
- package/dist/components/ui/card.d.ts +7 -7
- package/dist/components/ui/carousel.d.ts +6 -6
- package/dist/components/ui/chart.client.d.ts +5 -5
- package/dist/components/ui/checkbox.d.ts +2 -2
- package/dist/components/ui/collapsible.client.d.ts +4 -4
- package/dist/components/ui/color-picker.client.d.ts +2 -2
- package/dist/components/ui/combobox-dropdown.client.d.ts +2 -2
- package/dist/components/ui/combobox.client.d.ts +2 -2
- package/dist/components/ui/command.d.ts +10 -10
- package/dist/components/ui/context-menu.d.ts +16 -16
- package/dist/components/ui/dialog.client.d.ts +11 -11
- package/dist/components/ui/drawer.client.d.ts +11 -11
- package/dist/components/ui/dropdown-menu.d.ts +16 -16
- package/dist/components/ui/form.client.d.ts +8 -8
- package/dist/components/ui/hover-card.client.d.ts +4 -4
- package/dist/components/ui/input.d.ts +2 -2
- package/dist/components/ui/label.d.ts +2 -2
- package/dist/components/ui/navigation-menu.d.ts +11 -11
- package/dist/components/ui/pagination.d.ts +8 -8
- package/dist/components/ui/popover.d.ts +5 -5
- package/dist/components/ui/progress.client.d.ts +2 -2
- package/dist/components/ui/radio-group.d.ts +3 -3
- package/dist/components/ui/resizable.client.d.ts +4 -4
- package/dist/components/ui/scroll-area.d.ts +3 -3
- package/dist/components/ui/select.client.d.ts +11 -11
- package/dist/components/ui/separator.d.ts +2 -2
- package/dist/components/ui/sheet.client.d.ts +9 -9
- package/dist/components/ui/sidebar.client.d.ts +24 -24
- package/dist/components/ui/sidebar.client.js +1 -1
- package/dist/components/ui/skeleton.d.ts +2 -2
- package/dist/components/ui/slider.d.ts +2 -2
- package/dist/components/ui/sonner.client.d.ts +2 -2
- package/dist/components/ui/sonner.client.js +1 -1
- package/dist/components/ui/spinner.js +63 -0
- package/dist/components/ui/spinner.js.map +1 -0
- package/dist/components/ui/switch.d.ts +2 -2
- package/dist/components/ui/tabs.d.ts +5 -5
- package/dist/components/ui/textarea.d.ts +2 -2
- package/dist/components/ui/time-input.client.d.ts +2 -2
- package/dist/components/ui/toggle-group.client.d.ts +3 -3
- package/dist/components/ui/toggle.d.ts +4 -4
- package/dist/components/ui/tooltip.client.d.ts +5 -5
- package/dist/components/ui/tree.client.d.ts +5 -5
- package/dist/components/ui/tree.client.d.ts.map +1 -1
- package/dist/components.d.ts +6 -5
- package/dist/components.js +8 -7
- package/dist/config/server.d.ts +2 -3
- package/dist/config/server.js +3 -4
- package/dist/config.d.ts +3 -2
- package/dist/config.js +2 -1
- package/dist/lib/client.js +1 -1
- package/dist/lib/hooks/use-action.d.ts +2 -2
- package/dist/modules/auth/components/allowed.client.js +1 -1
- package/dist/modules/auth/components/allowed.client.js.map +1 -1
- package/dist/modules/auth/components/auth-layout.server.d.ts +3 -4
- package/dist/modules/auth/components/auth-layout.server.d.ts.map +1 -1
- package/dist/modules/auth/components/auth-layout.server.js +1 -4
- package/dist/modules/auth/components/auth-layout.server.js.map +1 -1
- package/dist/modules/auth/components/auth-loading.d.ts +7 -0
- package/dist/modules/auth/components/auth-loading.d.ts.map +1 -0
- package/dist/modules/auth/components/auth-loading.js +18 -0
- package/dist/modules/auth/components/auth-loading.js.map +1 -0
- package/dist/modules/auth/components/forget-password-page.client.js +2 -2
- package/dist/modules/auth/components/guard.client.js +16 -0
- package/dist/modules/auth/components/guard.client.js.map +1 -0
- package/dist/modules/auth/components/login-page.client.d.ts +1 -5
- package/dist/modules/auth/components/login-page.client.d.ts.map +1 -1
- package/dist/modules/auth/components/login-page.client.js +41 -31
- package/dist/modules/auth/components/login-page.client.js.map +1 -1
- package/dist/modules/auth/components/reset-password-page.client.js +3 -3
- package/dist/modules/auth/components/update-password-command.d.ts +1 -1
- package/dist/modules/auth/components/update-password-command.js +1 -1
- package/dist/modules/auth/handler/client.client.d.ts +48 -48
- package/dist/modules/auth/handler/client.client.d.ts.map +1 -1
- package/dist/modules/auth/handler/proxy.server.d.ts +13 -0
- package/dist/modules/auth/handler/proxy.server.d.ts.map +1 -0
- package/dist/modules/auth/handler/proxy.server.js +22 -0
- package/dist/modules/auth/handler/proxy.server.js.map +1 -0
- package/dist/modules/auth/handler/server.server.js +3 -1
- package/dist/modules/auth/handler/server.server.js.map +1 -1
- package/dist/modules/auth/hooks/use-permission.d.ts +26 -0
- package/dist/modules/auth/hooks/use-permission.d.ts.map +1 -0
- package/dist/modules/auth/hooks/{use-permission.client.js → use-permission.js} +5 -3
- package/dist/modules/auth/hooks/use-permission.js.map +1 -0
- package/dist/modules/auth/hooks/use-session.d.ts +34 -0
- package/dist/modules/auth/hooks/use-session.d.ts.map +1 -0
- package/dist/modules/auth/hooks/use-session.js +21 -0
- package/dist/modules/auth/hooks/use-session.js.map +1 -0
- package/dist/modules/auth/lib/helpers.server.d.ts +2 -2
- package/dist/modules/auth/lib/helpers.server.d.ts.map +1 -1
- package/dist/modules/auth/lib/helpers.server.js +3 -6
- package/dist/modules/auth/lib/helpers.server.js.map +1 -1
- package/dist/modules/auth/lib/validators.d.ts +4 -4
- package/dist/modules/auth/lib/validators.d.ts.map +1 -1
- package/dist/modules/auth/lib/validators.js +1 -1
- package/dist/modules/auth/lib/validators.js.map +1 -1
- package/dist/modules/commands/components/alert-dialog-command.client.d.ts +11 -11
- package/dist/modules/commands/components/alert-dialog-command.client.js +1 -1
- package/dist/modules/commands/components/click-command.client.d.ts +2 -2
- package/dist/modules/commands/components/command-trigger.client.d.ts +4 -4
- package/dist/modules/commands/components/command-trigger.client.js +1 -1
- package/dist/modules/commands/components/dialog-command.client.d.ts +8 -8
- package/dist/modules/commands/components/dialog-command.client.js +1 -1
- package/dist/modules/commands/components/dropdown-command.client.d.ts +5 -5
- package/dist/modules/commands/components/empty-command.client.d.ts +2 -2
- package/dist/modules/commands/components/form-dialog-command.client.d.ts +12 -12
- package/dist/modules/commands/components/form-dialog-command.client.js +1 -1
- package/dist/modules/commands/hooks/use-command-action.client.js +1 -1
- package/dist/modules/commands/hooks/use-command-menu.client.js +1 -1
- package/dist/modules/commands/hooks/use-command-menu.client.js.map +1 -1
- package/dist/modules/commands/menus/context-menu.client.d.ts +2 -2
- package/dist/modules/commands/menus/dropdown-menu.client.d.ts +8 -4
- package/dist/modules/commands/menus/dropdown-menu.client.d.ts.map +1 -1
- package/dist/modules/commands/menus/dropdown-menu.client.js +9 -1
- package/dist/modules/commands/menus/dropdown-menu.client.js.map +1 -1
- package/dist/modules/commands/menus/inline-menu.client.d.ts +8 -4
- package/dist/modules/commands/menus/inline-menu.client.d.ts.map +1 -1
- package/dist/modules/commands/menus/inline-menu.client.js +12 -1
- package/dist/modules/commands/menus/inline-menu.client.js.map +1 -1
- package/dist/modules/commands/menus/responsive-menu.client.d.ts +2 -1
- package/dist/modules/commands/menus/responsive-menu.client.d.ts.map +1 -1
- package/dist/modules/commands/menus/responsive-menu.client.js +6 -3
- package/dist/modules/commands/menus/responsive-menu.client.js.map +1 -1
- package/dist/modules/commands/utils/archive-command.client.d.ts +3 -3
- package/dist/modules/commands/utils/delete-command.client.d.ts +2 -2
- package/dist/modules/commands/utils/send-mail-command.client.d.ts +2 -2
- package/dist/modules/commands/utils/send-mail-command.client.d.ts.map +1 -1
- package/dist/modules/commands/utils/send-mail-command.client.js +3 -3
- package/dist/modules/config/db/helpers.d.ts +5 -5
- package/dist/modules/config/db/helpers.d.ts.map +1 -1
- package/dist/modules/config/lib/config.server.d.ts +0 -2
- package/dist/modules/config/lib/config.server.d.ts.map +1 -1
- package/dist/modules/config/lib/config.server.js.map +1 -1
- package/dist/modules/config/lib/resolve.server.d.ts +192 -190
- package/dist/modules/config/lib/resolve.server.d.ts.map +1 -1
- package/dist/modules/config/paths/helpers.d.ts +11 -0
- package/dist/modules/config/paths/helpers.d.ts.map +1 -0
- package/dist/modules/config/paths/helpers.js +9 -0
- package/dist/modules/config/paths/helpers.js.map +1 -0
- package/dist/modules/config/paths/types.d.ts +8 -37
- package/dist/modules/config/paths/types.d.ts.map +1 -1
- package/dist/modules/config/router/client.server.d.ts +4 -4
- package/dist/modules/config/router/client.server.d.ts.map +1 -1
- package/dist/modules/config/router/context.server.d.ts +194 -192
- package/dist/modules/config/router/context.server.d.ts.map +1 -1
- package/dist/modules/config/router/init.server.d.ts +200 -198
- package/dist/modules/config/router/init.server.d.ts.map +1 -1
- package/dist/modules/data-tables/components/cell/common.client.d.ts +5 -5
- package/dist/modules/data-tables/components/cell/common.client.d.ts.map +1 -1
- package/dist/modules/data-tables/components/column-header.d.ts +2 -2
- package/dist/modules/data-tables/components/filters/combobox.client.d.ts +2 -2
- package/dist/modules/data-tables/components/filters/combobox.client.d.ts.map +1 -1
- package/dist/modules/data-tables/components/filters/combobox.client.js +1 -1
- package/dist/modules/data-tables/components/filters/combobox.client.js.map +1 -1
- package/dist/modules/data-tables/components/filters/slider.client.d.ts +2 -2
- package/dist/modules/data-tables/components/filters/slider.client.d.ts.map +1 -1
- package/dist/modules/data-tables/components/header.d.ts +4 -4
- package/dist/modules/data-tables/components/layout.d.ts +2 -2
- package/dist/modules/data-tables/components/search-input.client.d.ts +2 -2
- package/dist/modules/data-tables/components/search-input.client.d.ts.map +1 -1
- package/dist/modules/data-tables/components/skeleton.d.ts +2 -2
- package/dist/modules/data-tables/components/table.d.ts +7 -7
- package/dist/modules/data-tables/components/toolbar.d.ts +3 -3
- package/dist/modules/data-tables/hooks/use-context.client.d.ts +2 -2
- package/dist/modules/data-tables/hooks/use-context.client.d.ts.map +1 -1
- package/dist/modules/data-tables/lib/filters/resolvers.d.ts +1 -1
- package/dist/modules/data-tables/lib/filters/resolvers.d.ts.map +1 -1
- package/dist/modules/data-tables/lib/search-params.d.ts +5 -5
- package/dist/modules/data-tables/lib/search-params.d.ts.map +1 -1
- package/dist/modules/data-tables/lib/types.d.ts +1 -1
- package/dist/modules/data-tables/tables/data-table/components/table.d.ts +2 -2
- package/dist/modules/data-tables/tables/inline-table/components/cells/common.d.ts +2 -2
- package/dist/modules/data-tables/tables/inline-table/components/cells/common.d.ts.map +1 -1
- package/dist/modules/data-tables/tables/inline-table/components/inputs/advanced-select.client.d.ts +2 -2
- package/dist/modules/data-tables/tables/inline-table/components/inputs/advanced-select.client.d.ts.map +1 -1
- package/dist/modules/data-tables/tables/inline-table/components/inputs/combobox.client.d.ts +2 -2
- package/dist/modules/data-tables/tables/inline-table/components/inputs/input.client.d.ts +3 -3
- package/dist/modules/data-tables/tables/inline-table/components/inputs/read-only.d.ts +2 -2
- package/dist/modules/data-tables/tables/inline-table/components/inputs/select.client.d.ts +2 -2
- package/dist/modules/data-tables/tables/inline-table/components/table.d.ts +2 -2
- package/dist/modules/data-tables/tables/inline-table/hooks/context.client.d.ts +2 -2
- package/dist/modules/data-tables/tables/inline-table/hooks/context.client.js +1 -1
- package/dist/modules/data-tables/tables/inline-table/hooks/use-input.client.js +1 -1
- package/dist/modules/data-tables/tables/inline-table/hooks/use-input.client.js.map +1 -1
- package/dist/modules/inline-edit/components/combobox-dropdown.client.d.ts +2 -2
- package/dist/modules/inline-edit/components/combobox-dropdown.client.d.ts.map +1 -1
- package/dist/modules/inline-edit/components/combobox.client.d.ts +2 -2
- package/dist/modules/inline-edit/components/combobox.client.d.ts.map +1 -1
- package/dist/modules/inline-edit/components/date-input.client.d.ts +2 -2
- package/dist/modules/inline-edit/components/date-input.client.js +1 -1
- package/dist/modules/inline-edit/components/date-picker.client.d.ts +2 -2
- package/dist/modules/inline-edit/components/editor.client.d.ts +2 -2
- package/dist/modules/inline-edit/components/input-toggle.client.d.ts +2 -2
- package/dist/modules/inline-edit/components/input.client.d.ts +3 -3
- package/dist/modules/inline-edit/components/richtext.client.d.ts +2 -2
- package/dist/modules/inline-edit/components/select.client.d.ts +6 -6
- package/dist/modules/inline-edit/components/switch.client.d.ts +2 -2
- package/dist/modules/inline-edit/components/toggle.client.d.ts +2 -2
- package/dist/modules/inline-edit/hooks/context.client.d.ts +2 -2
- package/dist/modules/inline-edit/hooks/use-inline.client.js +1 -1
- package/dist/modules/inline-edit/hooks/use-inline.client.js.map +1 -1
- package/dist/modules/uploads/components/button.client.d.ts +2 -2
- package/dist/modules/uploads/components/button.client.d.ts.map +1 -1
- package/dist/modules/uploads/components/images/grid.client.d.ts +2 -2
- package/dist/modules/uploads/components/images/grid.client.d.ts.map +1 -1
- package/dist/modules/uploads/components/images/grid.client.js +1 -1
- package/dist/modules/uploads/components/images/input.client.d.ts +2 -2
- package/dist/modules/uploads/components/images/input.client.d.ts.map +1 -1
- package/dist/modules/uploads/components/preview-dialog.client.d.ts +2 -2
- package/dist/modules/uploads/components/preview-dialog.client.d.ts.map +1 -1
- package/dist/modules/uploads/components/zone.client.d.ts +2 -2
- package/dist/modules/uploads/components/zone.client.d.ts.map +1 -1
- package/dist/modules/uploads/hooks/use-upload-image.client.js +1 -1
- package/dist/modules/uploads/lib/proxy.server.d.ts +1 -1
- package/dist/modules/uploads/lib/proxy.server.js +4 -4
- package/dist/modules/uploads/lib/route.server.d.ts +1 -1
- package/dist/modules/uploads/lib/route.server.js +2 -2
- package/dist/modules/uploads/lib/router.server.d.ts +965 -965
- package/dist/modules/uploads/lib/router.server.d.ts.map +1 -1
- package/dist/modules/uploads/lib/router.server.js +2 -2
- package/dist/modules/uploads/lib/schema.d.ts +61 -61
- package/dist/modules/uploads/lib/validators.d.ts +56 -56
- package/dist/modules/uploads/lib/validators.d.ts.map +1 -1
- package/package.json +5 -4
- package/src/components/common/icons.tsx +6 -0
- package/src/components/entry.client.ts +6 -0
- package/src/components/entry.server.ts +1 -1
- package/src/components/entry.ts +1 -0
- package/src/components/header/bottom-bar.client.tsx +2 -2
- package/src/components/layouts/admin-layout.tsx +13 -0
- package/src/components/layouts/admin-loading.tsx +1 -1
- package/src/components/layouts/not-found-page.tsx +9 -1
- package/src/components/layouts/not-found-section.tsx +10 -5
- package/src/components/layouts/root-loading.tsx +9 -0
- package/src/components/{layouts → navigation}/admin-sidebar-header.client.tsx +11 -6
- package/src/components/navigation/admin-sidebar-paths.client.tsx +190 -0
- package/src/components/navigation/admin-sidebar-skeleton.tsx +44 -0
- package/src/components/navigation/admin-sidebar.client.tsx +123 -0
- package/src/components/ui/spinner.tsx +51 -0
- package/src/modules/auth/components/allowed.client.tsx +1 -1
- package/src/modules/auth/components/auth-layout.server.tsx +2 -10
- package/src/modules/auth/components/auth-loading.tsx +11 -0
- package/src/modules/auth/components/guard.client.tsx +12 -0
- package/src/modules/auth/components/login-page.client.tsx +45 -37
- package/src/modules/auth/entry.client.ts +2 -0
- package/src/modules/auth/entry.server.ts +1 -1
- package/src/modules/auth/entry.ts +1 -0
- package/src/modules/auth/handler/proxy.server.ts +28 -0
- package/src/modules/auth/handler/server.server.ts +5 -0
- package/src/modules/auth/hooks/{use-permission.client.ts → use-permission.ts} +4 -2
- package/src/modules/auth/hooks/use-session.ts +18 -0
- package/src/modules/auth/lib/helpers.server.ts +1 -5
- package/src/modules/auth/lib/validators.ts +1 -1
- package/src/modules/commands/hooks/use-command-menu.client.tsx +6 -7
- package/src/modules/commands/menus/dropdown-menu.client.tsx +11 -2
- package/src/modules/commands/menus/inline-menu.client.tsx +14 -1
- package/src/modules/commands/menus/responsive-menu.client.tsx +11 -2
- package/src/modules/config/entry.server.ts +1 -2
- package/src/modules/config/entry.ts +3 -0
- package/src/modules/config/lib/config.server.ts +1 -2
- package/src/modules/config/lib/router.server.ts +64 -0
- package/src/modules/config/paths/helpers.ts +6 -0
- package/src/modules/config/paths/types.ts +26 -38
- package/src/modules/data-tables/components/filters/combobox.client.tsx +1 -1
- package/src/modules/data-tables/tables/inline-table/hooks/use-input.client.ts +1 -1
- package/src/modules/inline-edit/hooks/use-inline.client.tsx +1 -1
- package/dist/components/layouts/admin-layout.server.d.ts +0 -14
- package/dist/components/layouts/admin-layout.server.d.ts.map +0 -1
- package/dist/components/layouts/admin-layout.server.js +0 -26
- package/dist/components/layouts/admin-layout.server.js.map +0 -1
- package/dist/components/layouts/admin-sidebar-context.client.js +0 -28
- package/dist/components/layouts/admin-sidebar-context.client.js.map +0 -1
- package/dist/components/layouts/admin-sidebar-header.client.js.map +0 -1
- package/dist/components/layouts/admin-sidebar.client.js +0 -51
- package/dist/components/layouts/admin-sidebar.client.js.map +0 -1
- package/dist/modules/auth/components/allowed.server.d.ts +0 -23
- package/dist/modules/auth/components/allowed.server.d.ts.map +0 -1
- package/dist/modules/auth/components/allowed.server.js +0 -24
- package/dist/modules/auth/components/allowed.server.js.map +0 -1
- package/dist/modules/auth/hooks/use-permission.client.js.map +0 -1
- package/dist/modules/config/paths/create.server.d.ts +0 -14
- package/dist/modules/config/paths/create.server.d.ts.map +0 -1
- package/dist/modules/config/paths/create.server.js +0 -12
- package/dist/modules/config/paths/create.server.js.map +0 -1
- package/dist/modules/config/paths/get.server.js +0 -47
- package/dist/modules/config/paths/get.server.js.map +0 -1
- package/src/components/layouts/admin-layout.server.tsx +0 -31
- package/src/components/layouts/admin-sidebar-context.client.tsx +0 -34
- package/src/components/layouts/admin-sidebar.client.tsx +0 -88
- package/src/modules/auth/components/allowed.server.tsx +0 -41
- package/src/modules/config/paths/create.server.ts +0 -10
- package/src/modules/config/paths/get.server.ts +0 -69
|
@@ -1,27 +1,26 @@
|
|
|
1
1
|
import { Permission } from "../../auth/lib/permissions.js";
|
|
2
2
|
import { TDatabaseSchema } from "../db/types.js";
|
|
3
|
-
import { PathConfig } from "../paths/types.js";
|
|
4
3
|
import { ProtectedRPCContext, RPCContext } from "./context.server.js";
|
|
4
|
+
import * as zod0 from "zod";
|
|
5
5
|
import "server-cli-only";
|
|
6
|
-
import * as
|
|
7
|
-
import * as
|
|
8
|
-
import * as
|
|
9
|
-
import * as better_auth_plugins51 from "better-auth/plugins";
|
|
10
|
-
import * as drizzle_orm_postgres_js1 from "drizzle-orm/postgres-js";
|
|
6
|
+
import * as better_auth52 from "better-auth";
|
|
7
|
+
import * as better_auth_plugins5 from "better-auth/plugins";
|
|
8
|
+
import * as drizzle_orm_postgres_js0 from "drizzle-orm/postgres-js";
|
|
11
9
|
import * as _aws_sdk_client_s30 from "@aws-sdk/client-s3";
|
|
12
10
|
import * as resend0 from "resend";
|
|
11
|
+
import * as _orpc_server0 from "@orpc/server";
|
|
13
12
|
import * as next_dist_server_web_spec_extension_adapters_headers0 from "next/dist/server/web/spec-extension/adapters/headers";
|
|
14
|
-
import * as
|
|
13
|
+
import * as _orpc_contract0 from "@orpc/contract";
|
|
15
14
|
|
|
16
15
|
//#region src/modules/config/router/init.server.d.ts
|
|
17
16
|
/**
|
|
18
17
|
* Initialize TRPC
|
|
19
18
|
*/
|
|
20
19
|
declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
21
|
-
publicProcedure:
|
|
22
|
-
protectedProcedure:
|
|
23
|
-
authMiddleware:
|
|
24
|
-
permissionMiddleware: (permission: Permission) =>
|
|
20
|
+
publicProcedure: _orpc_server0.Builder<RPCContext<TSchema> & Record<never, never>, RPCContext<TSchema>, _orpc_contract0.Schema<unknown, unknown>, _orpc_contract0.Schema<unknown, unknown>, Record<never, never>, Record<never, never>>;
|
|
21
|
+
protectedProcedure: _orpc_server0.BuilderWithMiddlewares<_orpc_server0.MergedInitialContext<RPCContext<TSchema> & Record<never, never>, RPCContext<TSchema> & Record<never, never>, RPCContext<TSchema>>, _orpc_server0.MergedCurrentContext<RPCContext<TSchema>, ProtectedRPCContext<TSchema>>, _orpc_contract0.Schema<unknown, unknown>, _orpc_contract0.Schema<unknown, unknown>, Record<never, never>, Record<never, never>>;
|
|
22
|
+
authMiddleware: _orpc_server0.DecoratedMiddleware<RPCContext<TSchema> & Record<never, never>, ProtectedRPCContext<TSchema>, unknown, any, any, Record<never, never>>;
|
|
23
|
+
permissionMiddleware: (permission: Permission) => _orpc_server0.DecoratedMiddleware<{
|
|
25
24
|
session: {
|
|
26
25
|
session: {
|
|
27
26
|
id: string;
|
|
@@ -55,11 +54,14 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
55
54
|
name: string;
|
|
56
55
|
shortName: string;
|
|
57
56
|
};
|
|
58
|
-
paths:
|
|
57
|
+
paths: any;
|
|
59
58
|
schema: TSchema;
|
|
60
|
-
db:
|
|
61
|
-
auth:
|
|
62
|
-
|
|
59
|
+
db: drizzle_orm_postgres_js0.PostgresJsDatabase<TSchema>;
|
|
60
|
+
auth: better_auth52.Auth<{
|
|
61
|
+
advanced: {
|
|
62
|
+
cookiePrefix: string;
|
|
63
|
+
};
|
|
64
|
+
database: (options: better_auth52.BetterAuthOptions) => better_auth52.Adapter;
|
|
63
65
|
emailAndPassword: {
|
|
64
66
|
enabled: true;
|
|
65
67
|
};
|
|
@@ -84,8 +86,8 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
84
86
|
id: "next-cookies";
|
|
85
87
|
hooks: {
|
|
86
88
|
after: {
|
|
87
|
-
matcher(ctx:
|
|
88
|
-
handler: (inputContext:
|
|
89
|
+
matcher(ctx: better_auth52.HookEndpointContext): true;
|
|
90
|
+
handler: (inputContext: better_auth52.MiddlewareInputContext<better_auth52.MiddlewareOptions>) => Promise<void>;
|
|
89
91
|
}[];
|
|
90
92
|
};
|
|
91
93
|
}, {
|
|
@@ -128,7 +130,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
128
130
|
token: string;
|
|
129
131
|
ipAddress?: string | null | undefined;
|
|
130
132
|
userAgent?: string | null | undefined;
|
|
131
|
-
} & Record<string, unknown>, ctx:
|
|
133
|
+
} & Record<string, unknown>, ctx: better_auth52.GenericEndpointContext | undefined): Promise<void>;
|
|
132
134
|
};
|
|
133
135
|
};
|
|
134
136
|
};
|
|
@@ -136,8 +138,8 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
136
138
|
};
|
|
137
139
|
hooks: {
|
|
138
140
|
after: {
|
|
139
|
-
matcher(context:
|
|
140
|
-
handler: (inputContext:
|
|
141
|
+
matcher(context: better_auth52.HookEndpointContext): boolean;
|
|
142
|
+
handler: (inputContext: better_auth52.MiddlewareInputContext<better_auth52.MiddlewareOptions>) => Promise<better_auth_plugins5.SessionWithImpersonatedBy[] | undefined>;
|
|
141
143
|
}[];
|
|
142
144
|
};
|
|
143
145
|
endpoints: {
|
|
@@ -160,7 +162,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
160
162
|
} & {
|
|
161
163
|
asResponse?: boolean;
|
|
162
164
|
returnHeaders?: boolean;
|
|
163
|
-
use?:
|
|
165
|
+
use?: better_auth52.Middleware[];
|
|
164
166
|
path?: string;
|
|
165
167
|
} & {
|
|
166
168
|
asResponse?: AsResponse | undefined;
|
|
@@ -168,22 +170,22 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
168
170
|
}): Promise<[AsResponse] extends [true] ? Response : [ReturnHeaders] extends [true] ? {
|
|
169
171
|
headers: Headers;
|
|
170
172
|
response: {
|
|
171
|
-
user:
|
|
173
|
+
user: better_auth_plugins5.UserWithRole;
|
|
172
174
|
};
|
|
173
175
|
} : {
|
|
174
|
-
user:
|
|
176
|
+
user: better_auth_plugins5.UserWithRole;
|
|
175
177
|
}>;
|
|
176
178
|
options: {
|
|
177
179
|
method: "POST";
|
|
178
|
-
body:
|
|
179
|
-
userId:
|
|
180
|
-
role:
|
|
181
|
-
},
|
|
180
|
+
body: zod0.ZodObject<{
|
|
181
|
+
userId: zod0.ZodCoercedString<unknown>;
|
|
182
|
+
role: zod0.ZodUnion<readonly [zod0.ZodString, zod0.ZodArray<zod0.ZodString>]>;
|
|
183
|
+
}, better_auth52.$strip>;
|
|
182
184
|
requireHeaders: true;
|
|
183
|
-
use: ((inputContext:
|
|
185
|
+
use: ((inputContext: better_auth52.MiddlewareInputContext<better_auth52.MiddlewareOptions>) => Promise<{
|
|
184
186
|
session: {
|
|
185
|
-
user:
|
|
186
|
-
session:
|
|
187
|
+
user: better_auth_plugins5.UserWithRole;
|
|
188
|
+
session: better_auth52.Session;
|
|
187
189
|
};
|
|
188
190
|
}>)[];
|
|
189
191
|
metadata: {
|
|
@@ -239,7 +241,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
239
241
|
} & {
|
|
240
242
|
asResponse?: boolean;
|
|
241
243
|
returnHeaders?: boolean;
|
|
242
|
-
use?:
|
|
244
|
+
use?: better_auth52.Middleware[];
|
|
243
245
|
path?: string;
|
|
244
246
|
} & {
|
|
245
247
|
asResponse?: AsResponse | undefined;
|
|
@@ -266,13 +268,13 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
266
268
|
}>;
|
|
267
269
|
options: {
|
|
268
270
|
method: "GET";
|
|
269
|
-
query:
|
|
270
|
-
id:
|
|
271
|
-
},
|
|
272
|
-
use: ((inputContext:
|
|
271
|
+
query: zod0.ZodObject<{
|
|
272
|
+
id: zod0.ZodString;
|
|
273
|
+
}, better_auth52.$strip>;
|
|
274
|
+
use: ((inputContext: better_auth52.MiddlewareInputContext<better_auth52.MiddlewareOptions>) => Promise<{
|
|
273
275
|
session: {
|
|
274
|
-
user:
|
|
275
|
-
session:
|
|
276
|
+
user: better_auth_plugins5.UserWithRole;
|
|
277
|
+
session: better_auth52.Session;
|
|
276
278
|
};
|
|
277
279
|
}>)[];
|
|
278
280
|
metadata: {
|
|
@@ -326,7 +328,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
326
328
|
} & {
|
|
327
329
|
asResponse?: boolean;
|
|
328
330
|
returnHeaders?: boolean;
|
|
329
|
-
use?:
|
|
331
|
+
use?: better_auth52.Middleware[];
|
|
330
332
|
path?: string;
|
|
331
333
|
} & {
|
|
332
334
|
asResponse?: AsResponse | undefined;
|
|
@@ -334,20 +336,20 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
334
336
|
}): Promise<[AsResponse] extends [true] ? Response : [ReturnHeaders] extends [true] ? {
|
|
335
337
|
headers: Headers;
|
|
336
338
|
response: {
|
|
337
|
-
user:
|
|
339
|
+
user: better_auth_plugins5.UserWithRole;
|
|
338
340
|
};
|
|
339
341
|
} : {
|
|
340
|
-
user:
|
|
342
|
+
user: better_auth_plugins5.UserWithRole;
|
|
341
343
|
}>;
|
|
342
344
|
options: {
|
|
343
345
|
method: "POST";
|
|
344
|
-
body:
|
|
345
|
-
email:
|
|
346
|
-
password:
|
|
347
|
-
name:
|
|
348
|
-
role:
|
|
349
|
-
data:
|
|
350
|
-
},
|
|
346
|
+
body: zod0.ZodObject<{
|
|
347
|
+
email: zod0.ZodString;
|
|
348
|
+
password: zod0.ZodString;
|
|
349
|
+
name: zod0.ZodString;
|
|
350
|
+
role: zod0.ZodOptional<zod0.ZodUnion<readonly [zod0.ZodString, zod0.ZodArray<zod0.ZodString>]>>;
|
|
351
|
+
data: zod0.ZodOptional<zod0.ZodRecord<zod0.ZodString, zod0.ZodAny>>;
|
|
352
|
+
}, better_auth52.$strip>;
|
|
351
353
|
metadata: {
|
|
352
354
|
openapi: {
|
|
353
355
|
operationId: string;
|
|
@@ -405,25 +407,25 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
405
407
|
} & {
|
|
406
408
|
asResponse?: boolean;
|
|
407
409
|
returnHeaders?: boolean;
|
|
408
|
-
use?:
|
|
410
|
+
use?: better_auth52.Middleware[];
|
|
409
411
|
path?: string;
|
|
410
412
|
} & {
|
|
411
413
|
asResponse?: AsResponse | undefined;
|
|
412
414
|
returnHeaders?: ReturnHeaders | undefined;
|
|
413
415
|
}): Promise<[AsResponse] extends [true] ? Response : [ReturnHeaders] extends [true] ? {
|
|
414
416
|
headers: Headers;
|
|
415
|
-
response:
|
|
416
|
-
} :
|
|
417
|
+
response: better_auth_plugins5.UserWithRole;
|
|
418
|
+
} : better_auth_plugins5.UserWithRole>;
|
|
417
419
|
options: {
|
|
418
420
|
method: "POST";
|
|
419
|
-
body:
|
|
420
|
-
userId:
|
|
421
|
-
data:
|
|
422
|
-
},
|
|
423
|
-
use: ((inputContext:
|
|
421
|
+
body: zod0.ZodObject<{
|
|
422
|
+
userId: zod0.ZodCoercedString<unknown>;
|
|
423
|
+
data: zod0.ZodRecord<zod0.ZodAny, zod0.ZodAny>;
|
|
424
|
+
}, better_auth52.$strip>;
|
|
425
|
+
use: ((inputContext: better_auth52.MiddlewareInputContext<better_auth52.MiddlewareOptions>) => Promise<{
|
|
424
426
|
session: {
|
|
425
|
-
user:
|
|
426
|
-
session:
|
|
427
|
+
user: better_auth_plugins5.UserWithRole;
|
|
428
|
+
session: better_auth52.Session;
|
|
427
429
|
};
|
|
428
430
|
}>)[];
|
|
429
431
|
metadata: {
|
|
@@ -482,7 +484,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
482
484
|
} & {
|
|
483
485
|
asResponse?: boolean;
|
|
484
486
|
returnHeaders?: boolean;
|
|
485
|
-
use?:
|
|
487
|
+
use?: better_auth52.Middleware[];
|
|
486
488
|
path?: string;
|
|
487
489
|
} & {
|
|
488
490
|
asResponse?: AsResponse | undefined;
|
|
@@ -490,7 +492,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
490
492
|
}): Promise<[AsResponse] extends [true] ? Response : [ReturnHeaders] extends [true] ? {
|
|
491
493
|
headers: Headers;
|
|
492
494
|
response: {
|
|
493
|
-
users:
|
|
495
|
+
users: better_auth_plugins5.UserWithRole[];
|
|
494
496
|
total: number;
|
|
495
497
|
limit: number | undefined;
|
|
496
498
|
offset: number | undefined;
|
|
@@ -499,7 +501,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
499
501
|
total: number;
|
|
500
502
|
};
|
|
501
503
|
} : {
|
|
502
|
-
users:
|
|
504
|
+
users: better_auth_plugins5.UserWithRole[];
|
|
503
505
|
total: number;
|
|
504
506
|
limit: number | undefined;
|
|
505
507
|
offset: number | undefined;
|
|
@@ -509,33 +511,33 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
509
511
|
}>;
|
|
510
512
|
options: {
|
|
511
513
|
method: "GET";
|
|
512
|
-
use: ((inputContext:
|
|
514
|
+
use: ((inputContext: better_auth52.MiddlewareInputContext<better_auth52.MiddlewareOptions>) => Promise<{
|
|
513
515
|
session: {
|
|
514
|
-
user:
|
|
515
|
-
session:
|
|
516
|
+
user: better_auth_plugins5.UserWithRole;
|
|
517
|
+
session: better_auth52.Session;
|
|
516
518
|
};
|
|
517
519
|
}>)[];
|
|
518
|
-
query:
|
|
519
|
-
searchValue:
|
|
520
|
-
searchField:
|
|
520
|
+
query: zod0.ZodObject<{
|
|
521
|
+
searchValue: zod0.ZodOptional<zod0.ZodString>;
|
|
522
|
+
searchField: zod0.ZodOptional<zod0.ZodEnum<{
|
|
521
523
|
name: "name";
|
|
522
524
|
email: "email";
|
|
523
525
|
}>>;
|
|
524
|
-
searchOperator:
|
|
526
|
+
searchOperator: zod0.ZodOptional<zod0.ZodEnum<{
|
|
525
527
|
contains: "contains";
|
|
526
528
|
starts_with: "starts_with";
|
|
527
529
|
ends_with: "ends_with";
|
|
528
530
|
}>>;
|
|
529
|
-
limit:
|
|
530
|
-
offset:
|
|
531
|
-
sortBy:
|
|
532
|
-
sortDirection:
|
|
531
|
+
limit: zod0.ZodOptional<zod0.ZodUnion<[zod0.ZodString, zod0.ZodNumber]>>;
|
|
532
|
+
offset: zod0.ZodOptional<zod0.ZodUnion<[zod0.ZodString, zod0.ZodNumber]>>;
|
|
533
|
+
sortBy: zod0.ZodOptional<zod0.ZodString>;
|
|
534
|
+
sortDirection: zod0.ZodOptional<zod0.ZodEnum<{
|
|
533
535
|
asc: "asc";
|
|
534
536
|
desc: "desc";
|
|
535
537
|
}>>;
|
|
536
|
-
filterField:
|
|
537
|
-
filterValue:
|
|
538
|
-
filterOperator:
|
|
538
|
+
filterField: zod0.ZodOptional<zod0.ZodString>;
|
|
539
|
+
filterValue: zod0.ZodOptional<zod0.ZodUnion<[zod0.ZodUnion<[zod0.ZodString, zod0.ZodNumber]>, zod0.ZodBoolean]>>;
|
|
540
|
+
filterOperator: zod0.ZodOptional<zod0.ZodEnum<{
|
|
539
541
|
eq: "eq";
|
|
540
542
|
ne: "ne";
|
|
541
543
|
lt: "lt";
|
|
@@ -544,7 +546,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
544
546
|
gte: "gte";
|
|
545
547
|
contains: "contains";
|
|
546
548
|
}>>;
|
|
547
|
-
},
|
|
549
|
+
}, better_auth52.$strip>;
|
|
548
550
|
metadata: {
|
|
549
551
|
openapi: {
|
|
550
552
|
operationId: string;
|
|
@@ -605,7 +607,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
605
607
|
} & {
|
|
606
608
|
asResponse?: boolean;
|
|
607
609
|
returnHeaders?: boolean;
|
|
608
|
-
use?:
|
|
610
|
+
use?: better_auth52.Middleware[];
|
|
609
611
|
path?: string;
|
|
610
612
|
} & {
|
|
611
613
|
asResponse?: AsResponse | undefined;
|
|
@@ -613,22 +615,22 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
613
615
|
}): Promise<[AsResponse] extends [true] ? Response : [ReturnHeaders] extends [true] ? {
|
|
614
616
|
headers: Headers;
|
|
615
617
|
response: {
|
|
616
|
-
sessions:
|
|
618
|
+
sessions: better_auth_plugins5.SessionWithImpersonatedBy[];
|
|
617
619
|
};
|
|
618
620
|
} : {
|
|
619
|
-
sessions:
|
|
621
|
+
sessions: better_auth_plugins5.SessionWithImpersonatedBy[];
|
|
620
622
|
}>;
|
|
621
623
|
options: {
|
|
622
624
|
method: "POST";
|
|
623
|
-
use: ((inputContext:
|
|
625
|
+
use: ((inputContext: better_auth52.MiddlewareInputContext<better_auth52.MiddlewareOptions>) => Promise<{
|
|
624
626
|
session: {
|
|
625
|
-
user:
|
|
626
|
-
session:
|
|
627
|
+
user: better_auth_plugins5.UserWithRole;
|
|
628
|
+
session: better_auth52.Session;
|
|
627
629
|
};
|
|
628
630
|
}>)[];
|
|
629
|
-
body:
|
|
630
|
-
userId:
|
|
631
|
-
},
|
|
631
|
+
body: zod0.ZodObject<{
|
|
632
|
+
userId: zod0.ZodCoercedString<unknown>;
|
|
633
|
+
}, better_auth52.$strip>;
|
|
632
634
|
metadata: {
|
|
633
635
|
openapi: {
|
|
634
636
|
operationId: string;
|
|
@@ -679,7 +681,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
679
681
|
} & {
|
|
680
682
|
asResponse?: boolean;
|
|
681
683
|
returnHeaders?: boolean;
|
|
682
|
-
use?:
|
|
684
|
+
use?: better_auth52.Middleware[];
|
|
683
685
|
path?: string;
|
|
684
686
|
} & {
|
|
685
687
|
asResponse?: AsResponse | undefined;
|
|
@@ -694,13 +696,13 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
694
696
|
}>;
|
|
695
697
|
options: {
|
|
696
698
|
method: "POST";
|
|
697
|
-
body:
|
|
698
|
-
userId:
|
|
699
|
-
},
|
|
700
|
-
use: ((inputContext:
|
|
699
|
+
body: zod0.ZodObject<{
|
|
700
|
+
userId: zod0.ZodCoercedString<unknown>;
|
|
701
|
+
}, better_auth52.$strip>;
|
|
702
|
+
use: ((inputContext: better_auth52.MiddlewareInputContext<better_auth52.MiddlewareOptions>) => Promise<{
|
|
701
703
|
session: {
|
|
702
|
-
user:
|
|
703
|
-
session:
|
|
704
|
+
user: better_auth_plugins5.UserWithRole;
|
|
705
|
+
session: better_auth52.Session;
|
|
704
706
|
};
|
|
705
707
|
}>)[];
|
|
706
708
|
metadata: {
|
|
@@ -752,7 +754,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
752
754
|
} & {
|
|
753
755
|
asResponse?: boolean;
|
|
754
756
|
returnHeaders?: boolean;
|
|
755
|
-
use?:
|
|
757
|
+
use?: better_auth52.Middleware[];
|
|
756
758
|
path?: string;
|
|
757
759
|
} & {
|
|
758
760
|
asResponse?: AsResponse | undefined;
|
|
@@ -767,15 +769,15 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
767
769
|
}>;
|
|
768
770
|
options: {
|
|
769
771
|
method: "POST";
|
|
770
|
-
body:
|
|
771
|
-
userId:
|
|
772
|
-
banReason:
|
|
773
|
-
banExpiresIn:
|
|
774
|
-
},
|
|
775
|
-
use: ((inputContext:
|
|
772
|
+
body: zod0.ZodObject<{
|
|
773
|
+
userId: zod0.ZodCoercedString<unknown>;
|
|
774
|
+
banReason: zod0.ZodOptional<zod0.ZodString>;
|
|
775
|
+
banExpiresIn: zod0.ZodOptional<zod0.ZodNumber>;
|
|
776
|
+
}, better_auth52.$strip>;
|
|
777
|
+
use: ((inputContext: better_auth52.MiddlewareInputContext<better_auth52.MiddlewareOptions>) => Promise<{
|
|
776
778
|
session: {
|
|
777
|
-
user:
|
|
778
|
-
session:
|
|
779
|
+
user: better_auth_plugins5.UserWithRole;
|
|
780
|
+
session: better_auth52.Session;
|
|
779
781
|
};
|
|
780
782
|
}>)[];
|
|
781
783
|
metadata: {
|
|
@@ -825,7 +827,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
825
827
|
} & {
|
|
826
828
|
asResponse?: boolean;
|
|
827
829
|
returnHeaders?: boolean;
|
|
828
|
-
use?:
|
|
830
|
+
use?: better_auth52.Middleware[];
|
|
829
831
|
path?: string;
|
|
830
832
|
} & {
|
|
831
833
|
asResponse?: AsResponse | undefined;
|
|
@@ -876,13 +878,13 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
876
878
|
}>;
|
|
877
879
|
options: {
|
|
878
880
|
method: "POST";
|
|
879
|
-
body:
|
|
880
|
-
userId:
|
|
881
|
-
},
|
|
882
|
-
use: ((inputContext:
|
|
881
|
+
body: zod0.ZodObject<{
|
|
882
|
+
userId: zod0.ZodCoercedString<unknown>;
|
|
883
|
+
}, better_auth52.$strip>;
|
|
884
|
+
use: ((inputContext: better_auth52.MiddlewareInputContext<better_auth52.MiddlewareOptions>) => Promise<{
|
|
883
885
|
session: {
|
|
884
|
-
user:
|
|
885
|
-
session:
|
|
886
|
+
user: better_auth_plugins5.UserWithRole;
|
|
887
|
+
session: better_auth52.Session;
|
|
886
888
|
};
|
|
887
889
|
}>)[];
|
|
888
890
|
metadata: {
|
|
@@ -933,7 +935,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
933
935
|
} & {
|
|
934
936
|
asResponse?: boolean;
|
|
935
937
|
returnHeaders?: boolean;
|
|
936
|
-
use?:
|
|
938
|
+
use?: better_auth52.Middleware[];
|
|
937
939
|
path?: string;
|
|
938
940
|
} & {
|
|
939
941
|
asResponse?: AsResponse | undefined;
|
|
@@ -941,11 +943,11 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
941
943
|
}): Promise<[AsResponse] extends [true] ? Response : [ReturnHeaders] extends [true] ? {
|
|
942
944
|
headers: Headers;
|
|
943
945
|
response: {
|
|
944
|
-
session:
|
|
946
|
+
session: better_auth52.Session & Record<string, any>;
|
|
945
947
|
user: packages_core_dist_db.User & Record<string, any>;
|
|
946
948
|
};
|
|
947
949
|
} : {
|
|
948
|
-
session:
|
|
950
|
+
session: better_auth52.Session & Record<string, any>;
|
|
949
951
|
user: packages_core_dist_db.User & Record<string, any>;
|
|
950
952
|
}>;
|
|
951
953
|
options: {
|
|
@@ -974,7 +976,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
974
976
|
} & {
|
|
975
977
|
asResponse?: boolean;
|
|
976
978
|
returnHeaders?: boolean;
|
|
977
|
-
use?:
|
|
979
|
+
use?: better_auth52.Middleware[];
|
|
978
980
|
path?: string;
|
|
979
981
|
} & {
|
|
980
982
|
asResponse?: AsResponse | undefined;
|
|
@@ -989,13 +991,13 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
989
991
|
}>;
|
|
990
992
|
options: {
|
|
991
993
|
method: "POST";
|
|
992
|
-
body:
|
|
993
|
-
sessionToken:
|
|
994
|
-
},
|
|
995
|
-
use: ((inputContext:
|
|
994
|
+
body: zod0.ZodObject<{
|
|
995
|
+
sessionToken: zod0.ZodString;
|
|
996
|
+
}, better_auth52.$strip>;
|
|
997
|
+
use: ((inputContext: better_auth52.MiddlewareInputContext<better_auth52.MiddlewareOptions>) => Promise<{
|
|
996
998
|
session: {
|
|
997
|
-
user:
|
|
998
|
-
session:
|
|
999
|
+
user: better_auth_plugins5.UserWithRole;
|
|
1000
|
+
session: better_auth52.Session;
|
|
999
1001
|
};
|
|
1000
1002
|
}>)[];
|
|
1001
1003
|
metadata: {
|
|
@@ -1045,7 +1047,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1045
1047
|
} & {
|
|
1046
1048
|
asResponse?: boolean;
|
|
1047
1049
|
returnHeaders?: boolean;
|
|
1048
|
-
use?:
|
|
1050
|
+
use?: better_auth52.Middleware[];
|
|
1049
1051
|
path?: string;
|
|
1050
1052
|
} & {
|
|
1051
1053
|
asResponse?: AsResponse | undefined;
|
|
@@ -1060,13 +1062,13 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1060
1062
|
}>;
|
|
1061
1063
|
options: {
|
|
1062
1064
|
method: "POST";
|
|
1063
|
-
body:
|
|
1064
|
-
userId:
|
|
1065
|
-
},
|
|
1066
|
-
use: ((inputContext:
|
|
1065
|
+
body: zod0.ZodObject<{
|
|
1066
|
+
userId: zod0.ZodCoercedString<unknown>;
|
|
1067
|
+
}, better_auth52.$strip>;
|
|
1068
|
+
use: ((inputContext: better_auth52.MiddlewareInputContext<better_auth52.MiddlewareOptions>) => Promise<{
|
|
1067
1069
|
session: {
|
|
1068
|
-
user:
|
|
1069
|
-
session:
|
|
1070
|
+
user: better_auth_plugins5.UserWithRole;
|
|
1071
|
+
session: better_auth52.Session;
|
|
1070
1072
|
};
|
|
1071
1073
|
}>)[];
|
|
1072
1074
|
metadata: {
|
|
@@ -1116,7 +1118,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1116
1118
|
} & {
|
|
1117
1119
|
asResponse?: boolean;
|
|
1118
1120
|
returnHeaders?: boolean;
|
|
1119
|
-
use?:
|
|
1121
|
+
use?: better_auth52.Middleware[];
|
|
1120
1122
|
path?: string;
|
|
1121
1123
|
} & {
|
|
1122
1124
|
asResponse?: AsResponse | undefined;
|
|
@@ -1131,13 +1133,13 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1131
1133
|
}>;
|
|
1132
1134
|
options: {
|
|
1133
1135
|
method: "POST";
|
|
1134
|
-
body:
|
|
1135
|
-
userId:
|
|
1136
|
-
},
|
|
1137
|
-
use: ((inputContext:
|
|
1136
|
+
body: zod0.ZodObject<{
|
|
1137
|
+
userId: zod0.ZodCoercedString<unknown>;
|
|
1138
|
+
}, better_auth52.$strip>;
|
|
1139
|
+
use: ((inputContext: better_auth52.MiddlewareInputContext<better_auth52.MiddlewareOptions>) => Promise<{
|
|
1138
1140
|
session: {
|
|
1139
|
-
user:
|
|
1140
|
-
session:
|
|
1141
|
+
user: better_auth_plugins5.UserWithRole;
|
|
1142
|
+
session: better_auth52.Session;
|
|
1141
1143
|
};
|
|
1142
1144
|
}>)[];
|
|
1143
1145
|
metadata: {
|
|
@@ -1188,7 +1190,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1188
1190
|
} & {
|
|
1189
1191
|
asResponse?: boolean;
|
|
1190
1192
|
returnHeaders?: boolean;
|
|
1191
|
-
use?:
|
|
1193
|
+
use?: better_auth52.Middleware[];
|
|
1192
1194
|
path?: string;
|
|
1193
1195
|
} & {
|
|
1194
1196
|
asResponse?: AsResponse | undefined;
|
|
@@ -1203,14 +1205,14 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1203
1205
|
}>;
|
|
1204
1206
|
options: {
|
|
1205
1207
|
method: "POST";
|
|
1206
|
-
body:
|
|
1207
|
-
newPassword:
|
|
1208
|
-
userId:
|
|
1209
|
-
},
|
|
1210
|
-
use: ((inputContext:
|
|
1208
|
+
body: zod0.ZodObject<{
|
|
1209
|
+
newPassword: zod0.ZodString;
|
|
1210
|
+
userId: zod0.ZodCoercedString<unknown>;
|
|
1211
|
+
}, better_auth52.$strip>;
|
|
1212
|
+
use: ((inputContext: better_auth52.MiddlewareInputContext<better_auth52.MiddlewareOptions>) => Promise<{
|
|
1211
1213
|
session: {
|
|
1212
|
-
user:
|
|
1213
|
-
session:
|
|
1214
|
+
user: better_auth_plugins5.UserWithRole;
|
|
1215
|
+
session: better_auth52.Session;
|
|
1214
1216
|
};
|
|
1215
1217
|
}>)[];
|
|
1216
1218
|
metadata: {
|
|
@@ -1246,12 +1248,12 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1246
1248
|
<AsResponse extends boolean = false, ReturnHeaders extends boolean = false>(inputCtx_0: {
|
|
1247
1249
|
body: ({
|
|
1248
1250
|
permission: {
|
|
1249
|
-
readonly [x: string]:
|
|
1251
|
+
readonly [x: string]: better_auth52.LiteralString[] | undefined;
|
|
1250
1252
|
};
|
|
1251
1253
|
permissions?: never;
|
|
1252
1254
|
} | {
|
|
1253
1255
|
permissions: {
|
|
1254
|
-
readonly [x: string]:
|
|
1256
|
+
readonly [x: string]: better_auth52.LiteralString[] | undefined;
|
|
1255
1257
|
};
|
|
1256
1258
|
permission?: never;
|
|
1257
1259
|
}) & {
|
|
@@ -1271,7 +1273,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1271
1273
|
} & {
|
|
1272
1274
|
asResponse?: boolean;
|
|
1273
1275
|
returnHeaders?: boolean;
|
|
1274
|
-
use?:
|
|
1276
|
+
use?: better_auth52.Middleware[];
|
|
1275
1277
|
path?: string;
|
|
1276
1278
|
} & {
|
|
1277
1279
|
asResponse?: AsResponse | undefined;
|
|
@@ -1288,16 +1290,16 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1288
1290
|
}>;
|
|
1289
1291
|
options: {
|
|
1290
1292
|
method: "POST";
|
|
1291
|
-
body:
|
|
1292
|
-
userId:
|
|
1293
|
-
role:
|
|
1294
|
-
},
|
|
1295
|
-
permission:
|
|
1296
|
-
permissions:
|
|
1297
|
-
},
|
|
1298
|
-
permission:
|
|
1299
|
-
permissions:
|
|
1300
|
-
},
|
|
1293
|
+
body: zod0.ZodIntersection<zod0.ZodObject<{
|
|
1294
|
+
userId: zod0.ZodOptional<zod0.ZodCoercedString<unknown>>;
|
|
1295
|
+
role: zod0.ZodOptional<zod0.ZodString>;
|
|
1296
|
+
}, better_auth52.$strip>, zod0.ZodUnion<readonly [zod0.ZodObject<{
|
|
1297
|
+
permission: zod0.ZodRecord<zod0.ZodString, zod0.ZodArray<zod0.ZodString>>;
|
|
1298
|
+
permissions: zod0.ZodUndefined;
|
|
1299
|
+
}, better_auth52.$strip>, zod0.ZodObject<{
|
|
1300
|
+
permission: zod0.ZodUndefined;
|
|
1301
|
+
permissions: zod0.ZodRecord<zod0.ZodString, zod0.ZodArray<zod0.ZodString>>;
|
|
1302
|
+
}, better_auth52.$strip>]>>;
|
|
1301
1303
|
metadata: {
|
|
1302
1304
|
openapi: {
|
|
1303
1305
|
description: string;
|
|
@@ -1347,12 +1349,12 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1347
1349
|
$Infer: {
|
|
1348
1350
|
body: ({
|
|
1349
1351
|
permission: {
|
|
1350
|
-
readonly [x: string]:
|
|
1352
|
+
readonly [x: string]: better_auth52.LiteralString[] | undefined;
|
|
1351
1353
|
};
|
|
1352
1354
|
permissions?: never;
|
|
1353
1355
|
} | {
|
|
1354
1356
|
permissions: {
|
|
1355
|
-
readonly [x: string]:
|
|
1357
|
+
readonly [x: string]: better_auth52.LiteralString[] | undefined;
|
|
1356
1358
|
};
|
|
1357
1359
|
permission?: never;
|
|
1358
1360
|
}) & {
|
|
@@ -1425,7 +1427,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1425
1427
|
options: any;
|
|
1426
1428
|
}, {
|
|
1427
1429
|
id: "email-otp";
|
|
1428
|
-
init(ctx:
|
|
1430
|
+
init(ctx: better_auth52.AuthContext): {
|
|
1429
1431
|
options: {
|
|
1430
1432
|
emailVerification: {
|
|
1431
1433
|
sendVerificationEmail(data: {
|
|
@@ -1456,7 +1458,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1456
1458
|
} & {
|
|
1457
1459
|
asResponse?: boolean;
|
|
1458
1460
|
returnHeaders?: boolean;
|
|
1459
|
-
use?:
|
|
1461
|
+
use?: better_auth52.Middleware[];
|
|
1460
1462
|
path?: string;
|
|
1461
1463
|
} & {
|
|
1462
1464
|
asResponse?: AsResponse | undefined;
|
|
@@ -1467,14 +1469,14 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1467
1469
|
} : string>;
|
|
1468
1470
|
options: {
|
|
1469
1471
|
method: "POST";
|
|
1470
|
-
body:
|
|
1471
|
-
email:
|
|
1472
|
-
type:
|
|
1472
|
+
body: zod0.ZodObject<{
|
|
1473
|
+
email: zod0.ZodString;
|
|
1474
|
+
type: zod0.ZodEnum<{
|
|
1473
1475
|
"sign-in": "sign-in";
|
|
1474
1476
|
"forget-password": "forget-password";
|
|
1475
1477
|
"email-verification": "email-verification";
|
|
1476
1478
|
}>;
|
|
1477
|
-
},
|
|
1479
|
+
}, better_auth52.$strip>;
|
|
1478
1480
|
metadata: {
|
|
1479
1481
|
SERVER_ONLY: true;
|
|
1480
1482
|
openapi: {
|
|
@@ -1517,7 +1519,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1517
1519
|
} & {
|
|
1518
1520
|
asResponse?: boolean;
|
|
1519
1521
|
returnHeaders?: boolean;
|
|
1520
|
-
use?:
|
|
1522
|
+
use?: better_auth52.Middleware[];
|
|
1521
1523
|
path?: string;
|
|
1522
1524
|
} & {
|
|
1523
1525
|
asResponse?: AsResponse | undefined;
|
|
@@ -1536,14 +1538,14 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1536
1538
|
}>;
|
|
1537
1539
|
options: {
|
|
1538
1540
|
method: "GET";
|
|
1539
|
-
query:
|
|
1540
|
-
email:
|
|
1541
|
-
type:
|
|
1541
|
+
query: zod0.ZodObject<{
|
|
1542
|
+
email: zod0.ZodString;
|
|
1543
|
+
type: zod0.ZodEnum<{
|
|
1542
1544
|
"sign-in": "sign-in";
|
|
1543
1545
|
"forget-password": "forget-password";
|
|
1544
1546
|
"email-verification": "email-verification";
|
|
1545
1547
|
}>;
|
|
1546
|
-
},
|
|
1548
|
+
}, better_auth52.$strip>;
|
|
1547
1549
|
metadata: {
|
|
1548
1550
|
SERVER_ONLY: true;
|
|
1549
1551
|
openapi: {
|
|
@@ -1595,7 +1597,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1595
1597
|
} & {
|
|
1596
1598
|
asResponse?: boolean;
|
|
1597
1599
|
returnHeaders?: boolean;
|
|
1598
|
-
use?:
|
|
1600
|
+
use?: better_auth52.Middleware[];
|
|
1599
1601
|
path?: string;
|
|
1600
1602
|
} & {
|
|
1601
1603
|
asResponse?: AsResponse | undefined;
|
|
@@ -1610,15 +1612,15 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1610
1612
|
}>;
|
|
1611
1613
|
options: {
|
|
1612
1614
|
method: "POST";
|
|
1613
|
-
body:
|
|
1614
|
-
email:
|
|
1615
|
-
type:
|
|
1615
|
+
body: zod0.ZodObject<{
|
|
1616
|
+
email: zod0.ZodString;
|
|
1617
|
+
type: zod0.ZodEnum<{
|
|
1616
1618
|
"sign-in": "sign-in";
|
|
1617
1619
|
"forget-password": "forget-password";
|
|
1618
1620
|
"email-verification": "email-verification";
|
|
1619
1621
|
}>;
|
|
1620
|
-
otp:
|
|
1621
|
-
},
|
|
1622
|
+
otp: zod0.ZodString;
|
|
1623
|
+
}, better_auth52.$strip>;
|
|
1622
1624
|
metadata: {
|
|
1623
1625
|
openapi: {
|
|
1624
1626
|
description: string;
|
|
@@ -1665,7 +1667,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1665
1667
|
} & {
|
|
1666
1668
|
asResponse?: boolean;
|
|
1667
1669
|
returnHeaders?: boolean;
|
|
1668
|
-
use?:
|
|
1670
|
+
use?: better_auth52.Middleware[];
|
|
1669
1671
|
path?: string;
|
|
1670
1672
|
} & {
|
|
1671
1673
|
asResponse?: AsResponse | undefined;
|
|
@@ -1724,10 +1726,10 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1724
1726
|
}>;
|
|
1725
1727
|
options: {
|
|
1726
1728
|
method: "POST";
|
|
1727
|
-
body:
|
|
1728
|
-
email:
|
|
1729
|
-
otp:
|
|
1730
|
-
},
|
|
1729
|
+
body: zod0.ZodObject<{
|
|
1730
|
+
email: zod0.ZodString;
|
|
1731
|
+
otp: zod0.ZodString;
|
|
1732
|
+
}, better_auth52.$strip>;
|
|
1731
1733
|
metadata: {
|
|
1732
1734
|
openapi: {
|
|
1733
1735
|
description: string;
|
|
@@ -1785,7 +1787,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1785
1787
|
} & {
|
|
1786
1788
|
asResponse?: boolean;
|
|
1787
1789
|
returnHeaders?: boolean;
|
|
1788
|
-
use?:
|
|
1790
|
+
use?: better_auth52.Middleware[];
|
|
1789
1791
|
path?: string;
|
|
1790
1792
|
} & {
|
|
1791
1793
|
asResponse?: AsResponse | undefined;
|
|
@@ -1818,10 +1820,10 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1818
1820
|
}>;
|
|
1819
1821
|
options: {
|
|
1820
1822
|
method: "POST";
|
|
1821
|
-
body:
|
|
1822
|
-
email:
|
|
1823
|
-
otp:
|
|
1824
|
-
},
|
|
1823
|
+
body: zod0.ZodObject<{
|
|
1824
|
+
email: zod0.ZodString;
|
|
1825
|
+
otp: zod0.ZodString;
|
|
1826
|
+
}, better_auth52.$strip>;
|
|
1825
1827
|
metadata: {
|
|
1826
1828
|
openapi: {
|
|
1827
1829
|
description: string;
|
|
@@ -1872,7 +1874,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1872
1874
|
} & {
|
|
1873
1875
|
asResponse?: boolean;
|
|
1874
1876
|
returnHeaders?: boolean;
|
|
1875
|
-
use?:
|
|
1877
|
+
use?: better_auth52.Middleware[];
|
|
1876
1878
|
path?: string;
|
|
1877
1879
|
} & {
|
|
1878
1880
|
asResponse?: AsResponse | undefined;
|
|
@@ -1887,9 +1889,9 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1887
1889
|
}>;
|
|
1888
1890
|
options: {
|
|
1889
1891
|
method: "POST";
|
|
1890
|
-
body:
|
|
1891
|
-
email:
|
|
1892
|
-
},
|
|
1892
|
+
body: zod0.ZodObject<{
|
|
1893
|
+
email: zod0.ZodString;
|
|
1894
|
+
}, better_auth52.$strip>;
|
|
1893
1895
|
metadata: {
|
|
1894
1896
|
openapi: {
|
|
1895
1897
|
description: string;
|
|
@@ -1938,7 +1940,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1938
1940
|
} & {
|
|
1939
1941
|
asResponse?: boolean;
|
|
1940
1942
|
returnHeaders?: boolean;
|
|
1941
|
-
use?:
|
|
1943
|
+
use?: better_auth52.Middleware[];
|
|
1942
1944
|
path?: string;
|
|
1943
1945
|
} & {
|
|
1944
1946
|
asResponse?: AsResponse | undefined;
|
|
@@ -1953,11 +1955,11 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
1953
1955
|
}>;
|
|
1954
1956
|
options: {
|
|
1955
1957
|
method: "POST";
|
|
1956
|
-
body:
|
|
1957
|
-
email:
|
|
1958
|
-
otp:
|
|
1959
|
-
password:
|
|
1960
|
-
},
|
|
1958
|
+
body: zod0.ZodObject<{
|
|
1959
|
+
email: zod0.ZodString;
|
|
1960
|
+
otp: zod0.ZodString;
|
|
1961
|
+
password: zod0.ZodString;
|
|
1962
|
+
}, better_auth52.$strip>;
|
|
1961
1963
|
metadata: {
|
|
1962
1964
|
openapi: {
|
|
1963
1965
|
description: string;
|
|
@@ -2004,7 +2006,7 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
2004
2006
|
} & {
|
|
2005
2007
|
asResponse?: boolean;
|
|
2006
2008
|
returnHeaders?: boolean;
|
|
2007
|
-
use?:
|
|
2009
|
+
use?: better_auth52.Middleware[];
|
|
2008
2010
|
path?: string;
|
|
2009
2011
|
} & {
|
|
2010
2012
|
asResponse?: AsResponse | undefined;
|
|
@@ -2019,14 +2021,14 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
2019
2021
|
}>;
|
|
2020
2022
|
options: {
|
|
2021
2023
|
method: "POST";
|
|
2022
|
-
body:
|
|
2023
|
-
email:
|
|
2024
|
-
type:
|
|
2024
|
+
body: zod0.ZodObject<{
|
|
2025
|
+
email: zod0.ZodString;
|
|
2026
|
+
type: zod0.ZodEnum<{
|
|
2025
2027
|
"sign-in": "sign-in";
|
|
2026
2028
|
"forget-password": "forget-password";
|
|
2027
2029
|
"email-verification": "email-verification";
|
|
2028
2030
|
}>;
|
|
2029
|
-
},
|
|
2031
|
+
}, better_auth52.$strip>;
|
|
2030
2032
|
metadata: {
|
|
2031
2033
|
openapi: {
|
|
2032
2034
|
description: string;
|
|
@@ -2057,8 +2059,8 @@ declare function initRPC<TSchema extends TDatabaseSchema>(): {
|
|
|
2057
2059
|
};
|
|
2058
2060
|
hooks: {
|
|
2059
2061
|
after: {
|
|
2060
|
-
matcher(context:
|
|
2061
|
-
handler: (inputContext:
|
|
2062
|
+
matcher(context: better_auth52.HookEndpointContext): boolean;
|
|
2063
|
+
handler: (inputContext: better_auth52.MiddlewareInputContext<better_auth52.MiddlewareOptions>) => Promise<void>;
|
|
2062
2064
|
}[];
|
|
2063
2065
|
};
|
|
2064
2066
|
$ERROR_CODES: {
|