@questpie/admin 1.1.0 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +245 -474
- package/dist/_virtual/rolldown_runtime.mjs +18 -0
- package/dist/augmentation.d.mts +315 -0
- package/dist/augmentation.d.mts.map +1 -0
- package/dist/client/blocks/block-registry.d.mts +199 -0
- package/dist/client/blocks/block-registry.d.mts.map +1 -0
- package/dist/client/blocks/block-registry.mjs +88 -0
- package/dist/client/blocks/block-registry.mjs.map +1 -0
- package/dist/client/blocks/block-renderer.d.mts +52 -0
- package/dist/client/blocks/block-renderer.d.mts.map +1 -0
- package/dist/client/blocks/block-renderer.mjs +71 -0
- package/dist/client/blocks/block-renderer.mjs.map +1 -0
- package/dist/client/blocks/index.d.mts +4 -0
- package/dist/client/blocks/prefetch.d.mts +45 -0
- package/dist/client/blocks/prefetch.d.mts.map +1 -0
- package/dist/client/blocks/prefetch.mjs +26 -0
- package/dist/client/blocks/prefetch.mjs.map +1 -0
- package/dist/client/blocks/types.d.mts +69 -0
- package/dist/client/blocks/types.d.mts.map +1 -0
- package/dist/client/blocks/types.mjs +20 -0
- package/dist/client/blocks/types.mjs.map +1 -0
- package/dist/client/builder/admin-builder.d.mts +112 -0
- package/dist/client/builder/admin-builder.d.mts.map +1 -0
- package/dist/client/builder/admin-builder.mjs +185 -0
- package/dist/client/builder/admin-builder.mjs.map +1 -0
- package/dist/client/builder/admin-types.d.mts +73 -0
- package/dist/client/builder/admin-types.d.mts.map +1 -0
- package/dist/client/builder/admin.d.mts +121 -0
- package/dist/client/builder/admin.d.mts.map +1 -0
- package/dist/client/builder/admin.mjs +160 -0
- package/dist/client/builder/admin.mjs.map +1 -0
- package/dist/client/builder/defaults/components.mjs +20 -0
- package/dist/client/builder/defaults/components.mjs.map +1 -0
- package/dist/client/builder/defaults/core.d.mts +354 -0
- package/dist/client/builder/defaults/core.d.mts.map +1 -0
- package/dist/client/builder/defaults/core.mjs +49 -0
- package/dist/client/builder/defaults/core.mjs.map +1 -0
- package/dist/client/builder/defaults/fields.mjs +328 -0
- package/dist/client/builder/defaults/fields.mjs.map +1 -0
- package/dist/client/builder/defaults/pages.mjs +58 -0
- package/dist/client/builder/defaults/pages.mjs.map +1 -0
- package/dist/client/builder/defaults/starter.d.mts +351 -0
- package/dist/client/builder/defaults/starter.d.mts.map +1 -0
- package/dist/client/builder/defaults/starter.mjs +28 -0
- package/dist/client/builder/defaults/starter.mjs.map +1 -0
- package/dist/client/builder/defaults/views.mjs +27 -0
- package/dist/client/builder/defaults/views.mjs.map +1 -0
- package/dist/client/builder/defaults/widgets.mjs +31 -0
- package/dist/client/builder/defaults/widgets.mjs.map +1 -0
- package/dist/client/builder/field/field.d.mts +229 -0
- package/dist/client/builder/field/field.d.mts.map +1 -0
- package/dist/client/builder/field/field.mjs +83 -0
- package/dist/client/builder/field/field.mjs.map +1 -0
- package/dist/client/builder/index.d.mts +36 -0
- package/dist/client/builder/index.d.mts.map +1 -0
- package/dist/client/builder/page/page.d.mts +36 -0
- package/dist/client/builder/page/page.d.mts.map +1 -0
- package/dist/client/builder/page/page.mjs +27 -0
- package/dist/client/builder/page/page.mjs.map +1 -0
- package/dist/client/builder/proxies.d.mts +2 -0
- package/dist/client/builder/proxies.mjs +24 -0
- package/dist/client/builder/proxies.mjs.map +1 -0
- package/dist/client/builder/qa.d.mts +50 -0
- package/dist/client/builder/qa.d.mts.map +1 -0
- package/dist/client/builder/qa.mjs +42 -0
- package/dist/client/builder/qa.mjs.map +1 -0
- package/dist/client/builder/registry.d.mts +70 -0
- package/dist/client/builder/registry.d.mts.map +1 -0
- package/dist/client/builder/types/action-registry.d.mts +2 -0
- package/dist/client/builder/types/action-registry.mjs +142 -0
- package/dist/client/builder/types/action-registry.mjs.map +1 -0
- package/dist/client/builder/types/action-types.d.mts +253 -0
- package/dist/client/builder/types/action-types.d.mts.map +1 -0
- package/dist/client/builder/types/collection-types.d.mts +199 -0
- package/dist/client/builder/types/collection-types.d.mts.map +1 -0
- package/dist/client/builder/types/collection-types.mjs +11 -0
- package/dist/client/builder/types/collection-types.mjs.map +1 -0
- package/dist/client/builder/types/common.d.mts +60 -0
- package/dist/client/builder/types/common.d.mts.map +1 -0
- package/dist/client/builder/types/field-types.d.mts +593 -0
- package/dist/client/builder/types/field-types.d.mts.map +1 -0
- package/dist/client/builder/types/field-types.mjs +19 -0
- package/dist/client/builder/types/field-types.mjs.map +1 -0
- package/dist/client/builder/types/global-types.d.mts +22 -0
- package/dist/client/builder/types/global-types.d.mts.map +1 -0
- package/dist/client/builder/types/ui-config.d.mts +160 -0
- package/dist/client/builder/types/ui-config.d.mts.map +1 -0
- package/dist/client/builder/types/views.d.mts +89 -0
- package/dist/client/builder/types/views.d.mts.map +1 -0
- package/dist/client/builder/types/widget-types.d.mts +563 -0
- package/dist/client/builder/types/widget-types.d.mts.map +1 -0
- package/dist/client/builder/validation.d.mts +3 -0
- package/dist/client/builder/validation.mjs +208 -0
- package/dist/client/builder/validation.mjs.map +1 -0
- package/dist/client/builder/view/view.d.mts +129 -0
- package/dist/client/builder/view/view.d.mts.map +1 -0
- package/dist/client/builder/view/view.mjs +109 -0
- package/dist/client/builder/view/view.mjs.map +1 -0
- package/dist/client/builder/widget/widget.d.mts +33 -0
- package/dist/client/builder/widget/widget.d.mts.map +1 -0
- package/dist/client/builder/widget/widget.mjs +26 -0
- package/dist/client/builder/widget/widget.mjs.map +1 -0
- package/dist/client/components/actions/action-button.d.mts +2 -0
- package/dist/client/components/actions/action-button.mjs +135 -0
- package/dist/client/components/actions/action-button.mjs.map +1 -0
- package/dist/client/components/actions/action-dialog.d.mts +2 -0
- package/dist/client/components/actions/action-dialog.mjs +264 -0
- package/dist/client/components/actions/action-dialog.mjs.map +1 -0
- package/dist/client/components/actions/confirmation-dialog.d.mts +2 -0
- package/dist/client/components/actions/confirmation-dialog.mjs +82 -0
- package/dist/client/components/actions/confirmation-dialog.mjs.map +1 -0
- package/dist/client/components/actions/header-actions.d.mts +2 -0
- package/dist/client/components/actions/header-actions.mjs +117 -0
- package/dist/client/components/actions/header-actions.mjs.map +1 -0
- package/dist/client/components/actions/index.d.mts +4 -0
- package/dist/client/components/admin-link.d.mts +67 -0
- package/dist/client/components/admin-link.d.mts.map +1 -0
- package/dist/client/components/admin-link.mjs +92 -0
- package/dist/client/components/admin-link.mjs.map +1 -0
- package/dist/client/components/auth/auth-guard.d.mts +51 -0
- package/dist/client/components/auth/auth-guard.d.mts.map +1 -0
- package/dist/client/components/auth/auth-guard.mjs +60 -0
- package/dist/client/components/auth/auth-guard.mjs.map +1 -0
- package/dist/client/components/auth/auth-loading.d.mts +36 -0
- package/dist/client/components/auth/auth-loading.d.mts.map +1 -0
- package/dist/client/components/auth/auth-loading.mjs +27 -0
- package/dist/client/components/auth/auth-loading.mjs.map +1 -0
- package/dist/client/components/auth/index.d.mts +2 -0
- package/dist/client/components/blocks/block-canvas.mjs +90 -0
- package/dist/client/components/blocks/block-canvas.mjs.map +1 -0
- package/dist/client/components/blocks/block-editor-context.mjs +58 -0
- package/dist/client/components/blocks/block-editor-context.mjs.map +1 -0
- package/dist/client/components/blocks/block-editor-layout.mjs +82 -0
- package/dist/client/components/blocks/block-editor-layout.mjs.map +1 -0
- package/dist/client/components/blocks/block-editor-provider.mjs +155 -0
- package/dist/client/components/blocks/block-editor-provider.mjs.map +1 -0
- package/dist/client/components/blocks/block-fields-renderer.mjs +70 -0
- package/dist/client/components/blocks/block-fields-renderer.mjs.map +1 -0
- package/dist/client/components/blocks/block-insert-button.mjs +72 -0
- package/dist/client/components/blocks/block-insert-button.mjs.map +1 -0
- package/dist/client/components/blocks/block-item-menu.mjs +161 -0
- package/dist/client/components/blocks/block-item-menu.mjs.map +1 -0
- package/dist/client/components/blocks/block-item.mjs +187 -0
- package/dist/client/components/blocks/block-item.mjs.map +1 -0
- package/dist/client/components/blocks/block-library-sidebar.mjs +190 -0
- package/dist/client/components/blocks/block-library-sidebar.mjs.map +1 -0
- package/dist/client/components/blocks/block-tree.mjs +45 -0
- package/dist/client/components/blocks/block-tree.mjs.map +1 -0
- package/dist/client/components/blocks/block-type-icon.mjs +50 -0
- package/dist/client/components/blocks/block-type-icon.mjs.map +1 -0
- package/dist/client/components/blocks/utils/tree-utils.mjs +186 -0
- package/dist/client/components/blocks/utils/tree-utils.mjs.map +1 -0
- package/dist/client/components/component-renderer.d.mts +125 -0
- package/dist/client/components/component-renderer.d.mts.map +1 -0
- package/dist/client/components/component-renderer.mjs +145 -0
- package/dist/client/components/component-renderer.mjs.map +1 -0
- package/dist/client/components/error-boundary.mjs +92 -0
- package/dist/client/components/error-boundary.mjs.map +1 -0
- package/dist/client/components/fields/array-field.d.mts +44 -0
- package/dist/client/components/fields/array-field.d.mts.map +1 -0
- package/dist/client/components/fields/array-field.mjs +231 -0
- package/dist/client/components/fields/array-field.mjs.map +1 -0
- package/dist/client/components/fields/asset-preview-field.d.mts +52 -0
- package/dist/client/components/fields/asset-preview-field.d.mts.map +1 -0
- package/dist/client/components/fields/asset-preview-field.mjs +60 -0
- package/dist/client/components/fields/asset-preview-field.mjs.map +1 -0
- package/dist/client/components/fields/blocks-field/blocks-field.d.mts +41 -0
- package/dist/client/components/fields/blocks-field/blocks-field.d.mts.map +1 -0
- package/dist/client/components/fields/blocks-field/blocks-field.mjs +101 -0
- package/dist/client/components/fields/blocks-field/blocks-field.mjs.map +1 -0
- package/dist/client/components/fields/blocks-field/index.d.mts +1 -0
- package/dist/client/components/fields/boolean-field.d.mts +30 -0
- package/dist/client/components/fields/boolean-field.d.mts.map +1 -0
- package/dist/client/components/fields/boolean-field.mjs +47 -0
- package/dist/client/components/fields/boolean-field.mjs.map +1 -0
- package/dist/client/components/fields/custom-field.d.mts +3 -0
- package/dist/client/components/fields/date-field.d.mts +22 -0
- package/dist/client/components/fields/date-field.d.mts.map +1 -0
- package/dist/client/components/fields/date-field.mjs +42 -0
- package/dist/client/components/fields/date-field.mjs.map +1 -0
- package/dist/client/components/fields/datetime-field.d.mts +23 -0
- package/dist/client/components/fields/datetime-field.d.mts.map +1 -0
- package/dist/client/components/fields/datetime-field.mjs +43 -0
- package/dist/client/components/fields/datetime-field.mjs.map +1 -0
- package/dist/client/components/fields/email-field.d.mts +19 -0
- package/dist/client/components/fields/email-field.d.mts.map +1 -0
- package/dist/client/components/fields/email-field.mjs +38 -0
- package/dist/client/components/fields/email-field.mjs.map +1 -0
- package/dist/client/components/fields/embedded-collection.d.mts +3 -0
- package/dist/client/components/fields/field-types.d.mts +571 -0
- package/dist/client/components/fields/field-types.d.mts.map +1 -0
- package/dist/client/components/fields/field-utils.d.mts +1 -0
- package/dist/client/components/fields/field-utils.mjs +65 -0
- package/dist/client/components/fields/field-utils.mjs.map +1 -0
- package/dist/client/components/fields/field-wrapper.d.mts +3 -0
- package/dist/client/components/fields/field-wrapper.mjs +49 -0
- package/dist/client/components/fields/field-wrapper.mjs.map +1 -0
- package/dist/client/components/fields/index.d.mts +33 -0
- package/dist/client/components/fields/json-field.d.mts +84 -0
- package/dist/client/components/fields/json-field.d.mts.map +1 -0
- package/dist/client/components/fields/json-field.mjs +248 -0
- package/dist/client/components/fields/json-field.mjs.map +1 -0
- package/dist/client/components/fields/locale-badge.d.mts +1 -0
- package/dist/client/components/fields/locale-badge.mjs +17 -0
- package/dist/client/components/fields/locale-badge.mjs.map +1 -0
- package/dist/client/components/fields/number-field.d.mts +23 -0
- package/dist/client/components/fields/number-field.d.mts.map +1 -0
- package/dist/client/components/fields/number-field.mjs +40 -0
- package/dist/client/components/fields/number-field.mjs.map +1 -0
- package/dist/client/components/fields/object-array-field.d.mts +2 -0
- package/dist/client/components/fields/object-array-field.mjs +313 -0
- package/dist/client/components/fields/object-array-field.mjs.map +1 -0
- package/dist/client/components/fields/object-field.d.mts +32 -0
- package/dist/client/components/fields/object-field.d.mts.map +1 -0
- package/dist/client/components/fields/object-field.mjs +128 -0
- package/dist/client/components/fields/object-field.mjs.map +1 -0
- package/dist/client/components/fields/relation/displays/cards-display.d.mts +2 -0
- package/dist/client/components/fields/relation/displays/cards-display.mjs +140 -0
- package/dist/client/components/fields/relation/displays/cards-display.mjs.map +1 -0
- package/dist/client/components/fields/relation/displays/chips-display.d.mts +2 -0
- package/dist/client/components/fields/relation/displays/chips-display.mjs +100 -0
- package/dist/client/components/fields/relation/displays/chips-display.mjs.map +1 -0
- package/dist/client/components/fields/relation/displays/grid-display.d.mts +2 -0
- package/dist/client/components/fields/relation/displays/grid-display.mjs +114 -0
- package/dist/client/components/fields/relation/displays/grid-display.mjs.map +1 -0
- package/dist/client/components/fields/relation/displays/index.d.mts +6 -0
- package/dist/client/components/fields/relation/displays/list-display.d.mts +2 -0
- package/dist/client/components/fields/relation/displays/list-display.mjs +128 -0
- package/dist/client/components/fields/relation/displays/list-display.mjs.map +1 -0
- package/dist/client/components/fields/relation/displays/table-display.d.mts +2 -0
- package/dist/client/components/fields/relation/displays/table-display.mjs +134 -0
- package/dist/client/components/fields/relation/displays/table-display.mjs.map +1 -0
- package/dist/client/components/fields/relation/displays/types.d.mts +22 -0
- package/dist/client/components/fields/relation/displays/types.d.mts.map +1 -0
- package/dist/client/components/fields/relation/displays/types.mjs +73 -0
- package/dist/client/components/fields/relation/displays/types.mjs.map +1 -0
- package/dist/client/components/fields/relation/index.d.mts +3 -0
- package/dist/client/components/fields/relation/relation-items-display.d.mts +5 -0
- package/dist/client/components/fields/relation/relation-items-display.mjs +47 -0
- package/dist/client/components/fields/relation/relation-items-display.mjs.map +1 -0
- package/dist/client/components/fields/relation-field.d.mts +134 -0
- package/dist/client/components/fields/relation-field.d.mts.map +1 -0
- package/dist/client/components/fields/relation-field.mjs +106 -0
- package/dist/client/components/fields/relation-field.mjs.map +1 -0
- package/dist/client/components/fields/relation-picker.d.mts +4 -0
- package/dist/client/components/fields/relation-picker.mjs +301 -0
- package/dist/client/components/fields/relation-picker.mjs.map +1 -0
- package/dist/client/components/fields/relation-select.d.mts +3 -0
- package/dist/client/components/fields/relation-select.mjs +219 -0
- package/dist/client/components/fields/relation-select.mjs.map +1 -0
- package/dist/client/components/fields/reverse-relation-field.d.mts +2 -0
- package/dist/client/components/fields/rich-text-editor/bubble-menu.mjs +56 -0
- package/dist/client/components/fields/rich-text-editor/bubble-menu.mjs.map +1 -0
- package/dist/client/components/fields/rich-text-editor/extensions.mjs +118 -0
- package/dist/client/components/fields/rich-text-editor/extensions.mjs.map +1 -0
- package/dist/client/components/fields/rich-text-editor/image-popover.mjs +196 -0
- package/dist/client/components/fields/rich-text-editor/image-popover.mjs.map +1 -0
- package/dist/client/components/fields/rich-text-editor/index.d.mts +4 -0
- package/dist/client/components/fields/rich-text-editor/index.mjs +187 -0
- package/dist/client/components/fields/rich-text-editor/index.mjs.map +1 -0
- package/dist/client/components/fields/rich-text-editor/link-popover.mjs +86 -0
- package/dist/client/components/fields/rich-text-editor/link-popover.mjs.map +1 -0
- package/dist/client/components/fields/rich-text-editor/presets.d.mts +11 -0
- package/dist/client/components/fields/rich-text-editor/presets.d.mts.map +1 -0
- package/dist/client/components/fields/rich-text-editor/presets.mjs +124 -0
- package/dist/client/components/fields/rich-text-editor/presets.mjs.map +1 -0
- package/dist/client/components/fields/rich-text-editor/slash-commands.mjs +145 -0
- package/dist/client/components/fields/rich-text-editor/slash-commands.mjs.map +1 -0
- package/dist/client/components/fields/rich-text-editor/table-controls.mjs +124 -0
- package/dist/client/components/fields/rich-text-editor/table-controls.mjs.map +1 -0
- package/dist/client/components/fields/rich-text-editor/toolbar.mjs +280 -0
- package/dist/client/components/fields/rich-text-editor/toolbar.mjs.map +1 -0
- package/dist/client/components/fields/rich-text-editor/types.d.mts +78 -0
- package/dist/client/components/fields/rich-text-editor/types.d.mts.map +1 -0
- package/dist/client/components/fields/rich-text-editor/types.mjs +31 -0
- package/dist/client/components/fields/rich-text-editor/types.mjs.map +1 -0
- package/dist/client/components/fields/rich-text-editor/utils.mjs +51 -0
- package/dist/client/components/fields/rich-text-editor/utils.mjs.map +1 -0
- package/dist/client/components/fields/rich-text-editor/variants.d.mts +2 -0
- package/dist/client/components/fields/rich-text-field.d.mts +14 -0
- package/dist/client/components/fields/rich-text-field.d.mts.map +1 -0
- package/dist/client/components/fields/rich-text-field.mjs +26 -0
- package/dist/client/components/fields/rich-text-field.mjs.map +1 -0
- package/dist/client/components/fields/select-field.d.mts +25 -0
- package/dist/client/components/fields/select-field.d.mts.map +1 -0
- package/dist/client/components/fields/select-field.mjs +53 -0
- package/dist/client/components/fields/select-field.mjs.map +1 -0
- package/dist/client/components/fields/status-field.d.mts +2 -0
- package/dist/client/components/fields/text-field.d.mts +22 -0
- package/dist/client/components/fields/text-field.d.mts.map +1 -0
- package/dist/client/components/fields/text-field.mjs +39 -0
- package/dist/client/components/fields/text-field.mjs.map +1 -0
- package/dist/client/components/fields/textarea-field.d.mts +22 -0
- package/dist/client/components/fields/textarea-field.d.mts.map +1 -0
- package/dist/client/components/fields/textarea-field.mjs +39 -0
- package/dist/client/components/fields/textarea-field.mjs.map +1 -0
- package/dist/client/components/fields/time-field.d.mts +20 -0
- package/dist/client/components/fields/time-field.d.mts.map +1 -0
- package/dist/client/components/fields/time-field.mjs +39 -0
- package/dist/client/components/fields/time-field.mjs.map +1 -0
- package/dist/client/components/fields/upload-field.d.mts +97 -0
- package/dist/client/components/fields/upload-field.d.mts.map +1 -0
- package/dist/client/components/fields/upload-field.mjs +497 -0
- package/dist/client/components/fields/upload-field.mjs.map +1 -0
- package/dist/client/components/filter-builder/columns-tab.d.mts +1 -0
- package/dist/client/components/filter-builder/columns-tab.mjs +131 -0
- package/dist/client/components/filter-builder/columns-tab.mjs.map +1 -0
- package/dist/client/components/filter-builder/filter-builder-sheet.d.mts +1 -0
- package/dist/client/components/filter-builder/filter-builder-sheet.mjs +157 -0
- package/dist/client/components/filter-builder/filter-builder-sheet.mjs.map +1 -0
- package/dist/client/components/filter-builder/filters-tab.d.mts +1 -0
- package/dist/client/components/filter-builder/filters-tab.mjs +380 -0
- package/dist/client/components/filter-builder/filters-tab.mjs.map +1 -0
- package/dist/client/components/filter-builder/index.d.mts +5 -0
- package/dist/client/components/filter-builder/saved-views-tab.d.mts +1 -0
- package/dist/client/components/filter-builder/saved-views-tab.mjs +125 -0
- package/dist/client/components/filter-builder/saved-views-tab.mjs.map +1 -0
- package/dist/client/components/index.d.mts +80 -0
- package/dist/client/components/locale-switcher.d.mts +2 -0
- package/dist/client/components/locale-switcher.mjs +128 -0
- package/dist/client/components/locale-switcher.mjs.map +1 -0
- package/dist/client/components/media/media-grid.mjs +139 -0
- package/dist/client/components/media/media-grid.mjs.map +1 -0
- package/dist/client/components/media/media-picker-dialog.mjs +255 -0
- package/dist/client/components/media/media-picker-dialog.mjs.map +1 -0
- package/dist/client/components/preview/live-preview-mode.mjs +211 -0
- package/dist/client/components/preview/live-preview-mode.mjs.map +1 -0
- package/dist/client/components/preview/preview-pane.mjs +179 -0
- package/dist/client/components/preview/preview-pane.mjs.map +1 -0
- package/dist/client/components/primitives/asset-preview.mjs +363 -0
- package/dist/client/components/primitives/asset-preview.mjs.map +1 -0
- package/dist/client/components/primitives/checkbox-input.mjs +33 -0
- package/dist/client/components/primitives/checkbox-input.mjs.map +1 -0
- package/dist/client/components/primitives/date-input.mjs +218 -0
- package/dist/client/components/primitives/date-input.mjs.map +1 -0
- package/dist/client/components/primitives/dropzone.mjs +239 -0
- package/dist/client/components/primitives/dropzone.mjs.map +1 -0
- package/dist/client/components/primitives/number-input.mjs +113 -0
- package/dist/client/components/primitives/number-input.mjs.map +1 -0
- package/dist/client/components/primitives/select-multi.mjs +256 -0
- package/dist/client/components/primitives/select-multi.mjs.map +1 -0
- package/dist/client/components/primitives/select-single.mjs +183 -0
- package/dist/client/components/primitives/select-single.mjs.map +1 -0
- package/dist/client/components/primitives/text-input.mjs +40 -0
- package/dist/client/components/primitives/text-input.mjs.map +1 -0
- package/dist/client/components/primitives/textarea-input.mjs +38 -0
- package/dist/client/components/primitives/textarea-input.mjs.map +1 -0
- package/dist/client/components/primitives/time-input.mjs +72 -0
- package/dist/client/components/primitives/time-input.mjs.map +1 -0
- package/dist/client/components/primitives/toggle-input.mjs +31 -0
- package/dist/client/components/primitives/toggle-input.mjs.map +1 -0
- package/dist/client/components/primitives/types.d.mts +14 -0
- package/dist/client/components/primitives/types.d.mts.map +1 -0
- package/dist/client/components/primitives/types.mjs +13 -0
- package/dist/client/components/primitives/types.mjs.map +1 -0
- package/dist/client/components/sheets/index.d.mts +1 -0
- package/dist/client/components/sheets/resource-sheet.d.mts +1 -0
- package/dist/client/components/sheets/resource-sheet.mjs +78 -0
- package/dist/client/components/sheets/resource-sheet.mjs.map +1 -0
- package/dist/client/components/ui/accordion.d.mts +2 -0
- package/dist/client/components/ui/accordion.mjs +50 -0
- package/dist/client/components/ui/accordion.mjs.map +1 -0
- package/dist/client/components/ui/alert.mjs +32 -0
- package/dist/client/components/ui/alert.mjs.map +1 -0
- package/dist/client/components/ui/avatar.d.mts +3 -0
- package/dist/client/components/ui/badge.d.mts +3 -0
- package/dist/client/components/ui/badge.mjs +35 -0
- package/dist/client/components/ui/badge.mjs.map +1 -0
- package/dist/client/components/ui/button.d.mts +3 -0
- package/dist/client/components/ui/button.mjs +49 -0
- package/dist/client/components/ui/button.mjs.map +1 -0
- package/dist/client/components/ui/card.d.mts +2 -0
- package/dist/{card-BKHjBQfw.mjs → client/components/ui/card.mjs} +3 -10
- package/dist/{card-BKHjBQfw.mjs.map → client/components/ui/card.mjs.map} +1 -1
- package/dist/client/components/ui/checkbox.d.mts +2 -0
- package/dist/client/components/ui/checkbox.mjs +27 -0
- package/dist/client/components/ui/checkbox.mjs.map +1 -0
- package/dist/client/components/ui/combobox.d.mts +3 -0
- package/dist/client/components/ui/command.mjs +69 -0
- package/dist/client/components/ui/command.mjs.map +1 -0
- package/dist/client/components/ui/dialog.d.mts +3 -0
- package/dist/client/components/ui/dialog.mjs +83 -0
- package/dist/client/components/ui/dialog.mjs.map +1 -0
- package/dist/client/components/ui/drawer.mjs +75 -0
- package/dist/client/components/ui/drawer.mjs.map +1 -0
- package/dist/client/components/ui/dropdown-menu.d.mts +3 -0
- package/dist/client/components/ui/dropdown-menu.mjs +89 -0
- package/dist/client/components/ui/dropdown-menu.mjs.map +1 -0
- package/dist/client/components/ui/empty-state.mjs +53 -0
- package/dist/client/components/ui/empty-state.mjs.map +1 -0
- package/dist/client/components/ui/field.d.mts +3 -0
- package/dist/client/components/ui/field.mjs +78 -0
- package/dist/client/components/ui/field.mjs.map +1 -0
- package/dist/client/components/ui/input-group.d.mts +4 -0
- package/dist/client/components/ui/input-group.mjs +68 -0
- package/dist/client/components/ui/input-group.mjs.map +1 -0
- package/dist/client/components/ui/input.d.mts +2 -0
- package/dist/client/components/ui/input.mjs +17 -0
- package/dist/client/components/ui/input.mjs.map +1 -0
- package/dist/client/components/ui/kbd.mjs +24 -0
- package/dist/client/components/ui/kbd.mjs.map +1 -0
- package/dist/client/components/ui/label.d.mts +2 -0
- package/dist/client/components/ui/label.mjs +15 -0
- package/dist/client/components/ui/label.mjs.map +1 -0
- package/dist/client/components/ui/popover.d.mts +3 -0
- package/dist/client/components/ui/popover.mjs +49 -0
- package/dist/client/components/ui/popover.mjs.map +1 -0
- package/dist/client/components/ui/responsive-dialog.mjs +102 -0
- package/dist/client/components/ui/responsive-dialog.mjs.map +1 -0
- package/dist/client/components/ui/scroll-area.d.mts +2 -0
- package/dist/client/components/ui/search-input.mjs +74 -0
- package/dist/client/components/ui/search-input.mjs.map +1 -0
- package/dist/client/components/ui/select.d.mts +3 -0
- package/dist/client/components/ui/select.mjs +85 -0
- package/dist/client/components/ui/select.mjs.map +1 -0
- package/dist/client/components/ui/separator.d.mts +2 -0
- package/dist/client/components/ui/separator.mjs +17 -0
- package/dist/client/components/ui/separator.mjs.map +1 -0
- package/dist/client/components/ui/sheet.d.mts +3 -0
- package/dist/client/components/ui/sheet.mjs +78 -0
- package/dist/client/components/ui/sheet.mjs.map +1 -0
- package/dist/client/components/ui/sidebar.d.mts +8 -0
- package/dist/client/components/ui/sidebar.mjs +256 -0
- package/dist/client/components/ui/sidebar.mjs.map +1 -0
- package/dist/client/components/ui/skeleton.d.mts +1 -0
- package/dist/client/components/ui/skeleton.mjs +15 -0
- package/dist/client/components/ui/skeleton.mjs.map +1 -0
- package/dist/client/components/ui/sonner.d.mts +14 -0
- package/dist/client/components/ui/sonner.d.mts.map +1 -0
- package/dist/client/components/ui/sonner.mjs +55 -0
- package/dist/client/components/ui/sonner.mjs.map +1 -0
- package/dist/client/components/ui/spinner.d.mts +1 -0
- package/dist/client/components/ui/spinner.mjs +18 -0
- package/dist/client/components/ui/spinner.mjs.map +1 -0
- package/dist/client/components/ui/switch.d.mts +2 -0
- package/dist/client/components/ui/switch.mjs +23 -0
- package/dist/client/components/ui/switch.mjs.map +1 -0
- package/dist/client/components/ui/table.d.mts +2 -0
- package/dist/client/components/ui/table.mjs +66 -0
- package/dist/client/components/ui/table.mjs.map +1 -0
- package/dist/client/components/ui/tabs.d.mts +3 -0
- package/dist/client/components/ui/tabs.mjs +49 -0
- package/dist/client/components/ui/tabs.mjs.map +1 -0
- package/dist/client/components/ui/textarea.d.mts +2 -0
- package/dist/client/components/ui/textarea.mjs +15 -0
- package/dist/client/components/ui/textarea.mjs.map +1 -0
- package/dist/client/components/ui/toolbar.mjs +54 -0
- package/dist/client/components/ui/toolbar.mjs.map +1 -0
- package/dist/client/components/ui/tooltip.d.mts +2 -0
- package/dist/client/components/ui/tooltip.mjs +45 -0
- package/dist/client/components/ui/tooltip.mjs.map +1 -0
- package/dist/client/components/widgets/chart-widget.d.mts +57 -0
- package/dist/client/components/widgets/chart-widget.d.mts.map +1 -0
- package/dist/client/components/widgets/chart-widget.mjs +282 -0
- package/dist/client/components/widgets/chart-widget.mjs.map +1 -0
- package/dist/client/components/widgets/progress-widget.d.mts +41 -0
- package/dist/client/components/widgets/progress-widget.d.mts.map +1 -0
- package/dist/client/components/widgets/progress-widget.mjs +110 -0
- package/dist/client/components/widgets/progress-widget.mjs.map +1 -0
- package/dist/client/components/widgets/quick-actions-widget.d.mts +29 -0
- package/dist/client/components/widgets/quick-actions-widget.d.mts.map +1 -0
- package/dist/client/components/widgets/quick-actions-widget.mjs +121 -0
- package/dist/client/components/widgets/quick-actions-widget.mjs.map +1 -0
- package/dist/client/components/widgets/recent-items-widget.d.mts +51 -0
- package/dist/client/components/widgets/recent-items-widget.d.mts.map +1 -0
- package/dist/client/components/widgets/recent-items-widget.mjs +101 -0
- package/dist/client/components/widgets/recent-items-widget.mjs.map +1 -0
- package/dist/client/components/widgets/stats-widget.d.mts +55 -0
- package/dist/client/components/widgets/stats-widget.d.mts.map +1 -0
- package/dist/client/components/widgets/stats-widget.mjs +150 -0
- package/dist/client/components/widgets/stats-widget.mjs.map +1 -0
- package/dist/client/components/widgets/table-widget.d.mts +31 -0
- package/dist/client/components/widgets/table-widget.d.mts.map +1 -0
- package/dist/client/components/widgets/table-widget.mjs +139 -0
- package/dist/client/components/widgets/table-widget.mjs.map +1 -0
- package/dist/client/components/widgets/timeline-widget.d.mts +51 -0
- package/dist/client/components/widgets/timeline-widget.d.mts.map +1 -0
- package/dist/client/components/widgets/timeline-widget.mjs +168 -0
- package/dist/client/components/widgets/timeline-widget.mjs.map +1 -0
- package/dist/client/components/widgets/value-widget.d.mts +39 -0
- package/dist/client/components/widgets/value-widget.d.mts.map +1 -0
- package/dist/client/components/widgets/value-widget.mjs +111 -0
- package/dist/client/components/widgets/value-widget.mjs.map +1 -0
- package/dist/client/components/widgets/widget-skeletons.mjs +145 -0
- package/dist/client/components/widgets/widget-skeletons.mjs.map +1 -0
- package/dist/client/context/focus-context.d.mts +88 -0
- package/dist/client/context/focus-context.d.mts.map +1 -0
- package/dist/client/context/focus-context.mjs +178 -0
- package/dist/client/context/focus-context.mjs.map +1 -0
- package/dist/client/contexts/breadcrumb-context.mjs +32 -0
- package/dist/client/contexts/breadcrumb-context.mjs.map +1 -0
- package/dist/client/hooks/typed-hooks.d.mts +84 -0
- package/dist/client/hooks/typed-hooks.d.mts.map +1 -0
- package/dist/client/hooks/typed-hooks.mjs +272 -0
- package/dist/client/hooks/typed-hooks.mjs.map +1 -0
- package/dist/client/hooks/use-action.mjs +201 -0
- package/dist/client/hooks/use-action.mjs.map +1 -0
- package/dist/client/hooks/use-admin-config.mjs +40 -0
- package/dist/client/hooks/use-admin-config.mjs.map +1 -0
- package/dist/client/hooks/use-admin-preferences.mjs +68 -0
- package/dist/client/hooks/use-admin-preferences.mjs.map +1 -0
- package/dist/client/hooks/use-admin-routes.mjs +97 -0
- package/dist/client/hooks/use-admin-routes.mjs.map +1 -0
- package/dist/client/hooks/use-auth.d.mts +98 -0
- package/dist/client/hooks/use-auth.d.mts.map +1 -0
- package/dist/{use-auth-BoLmWtmU.mjs → client/hooks/use-auth.mjs} +3 -3
- package/dist/client/hooks/use-auth.mjs.map +1 -0
- package/dist/client/hooks/use-collection-fields.mjs +32 -0
- package/dist/client/hooks/use-collection-fields.mjs.map +1 -0
- package/dist/client/hooks/use-collection-meta.mjs +121 -0
- package/dist/client/hooks/use-collection-meta.mjs.map +1 -0
- package/dist/client/hooks/use-collection-schema.mjs +67 -0
- package/dist/client/hooks/use-collection-schema.mjs.map +1 -0
- package/dist/client/hooks/use-collection-validation.mjs +74 -0
- package/dist/client/hooks/use-collection-validation.mjs.map +1 -0
- package/dist/client/hooks/use-collection.d.mts +86 -0
- package/dist/client/hooks/use-collection.d.mts.map +1 -0
- package/dist/client/hooks/use-collection.mjs +214 -0
- package/dist/client/hooks/use-collection.mjs.map +1 -0
- package/dist/client/hooks/use-current-user.d.mts +57 -0
- package/dist/client/hooks/use-current-user.d.mts.map +1 -0
- package/dist/client/hooks/use-current-user.mjs +79 -0
- package/dist/client/hooks/use-current-user.mjs.map +1 -0
- package/dist/client/hooks/use-field-hooks.mjs +191 -0
- package/dist/client/hooks/use-field-hooks.mjs.map +1 -0
- package/dist/client/hooks/use-field-options.d.mts +90 -0
- package/dist/client/hooks/use-field-options.d.mts.map +1 -0
- package/dist/client/hooks/use-field-options.mjs +184 -0
- package/dist/client/hooks/use-field-options.mjs.map +1 -0
- package/dist/client/hooks/use-global-fields.mjs +27 -0
- package/dist/client/hooks/use-global-fields.mjs.map +1 -0
- package/dist/client/hooks/use-global-meta.mjs +59 -0
- package/dist/client/hooks/use-global-meta.mjs.map +1 -0
- package/dist/client/hooks/use-global-schema.mjs +33 -0
- package/dist/client/hooks/use-global-schema.mjs.map +1 -0
- package/dist/client/hooks/use-global.d.mts +40 -0
- package/dist/client/hooks/use-global.d.mts.map +1 -0
- package/dist/client/hooks/use-global.mjs +74 -0
- package/dist/client/hooks/use-global.mjs.map +1 -0
- package/dist/client/hooks/use-locks.mjs +245 -0
- package/dist/client/hooks/use-locks.mjs.map +1 -0
- package/dist/client/hooks/use-media-query.d.mts +23 -0
- package/dist/client/hooks/use-media-query.d.mts.map +1 -0
- package/dist/client/hooks/use-media-query.mjs +62 -0
- package/dist/client/hooks/use-media-query.mjs.map +1 -0
- package/dist/client/hooks/use-prefill-params.mjs +47 -0
- package/dist/client/hooks/use-prefill-params.mjs.map +1 -0
- package/dist/client/hooks/use-questpie-query-options.mjs +28 -0
- package/dist/client/hooks/use-questpie-query-options.mjs.map +1 -0
- package/dist/client/hooks/use-reactive-fields.d.mts +75 -0
- package/dist/client/hooks/use-reactive-fields.d.mts.map +1 -0
- package/dist/client/hooks/use-reactive-fields.mjs +164 -0
- package/dist/client/hooks/use-reactive-fields.mjs.map +1 -0
- package/dist/client/hooks/use-realtime-highlight.mjs +96 -0
- package/dist/client/hooks/use-realtime-highlight.mjs.map +1 -0
- package/dist/client/hooks/use-saved-views.mjs +65 -0
- package/dist/client/hooks/use-saved-views.mjs.map +1 -0
- package/dist/client/hooks/use-search.mjs +147 -0
- package/dist/client/hooks/use-search.mjs.map +1 -0
- package/dist/client/hooks/use-server-validation.mjs +199 -0
- package/dist/client/hooks/use-server-validation.mjs.map +1 -0
- package/dist/client/hooks/use-server-widget-data.d.mts +26 -0
- package/dist/client/hooks/use-server-widget-data.d.mts.map +1 -0
- package/dist/client/hooks/use-server-widget-data.mjs +40 -0
- package/dist/client/hooks/use-server-widget-data.mjs.map +1 -0
- package/dist/client/hooks/use-setup-status.d.mts +39 -0
- package/dist/client/hooks/use-setup-status.d.mts.map +1 -0
- package/dist/client/hooks/use-setup-status.mjs +50 -0
- package/dist/client/hooks/use-setup-status.mjs.map +1 -0
- package/dist/client/hooks/use-upload-collection.mjs +32 -0
- package/dist/client/hooks/use-upload-collection.mjs.map +1 -0
- package/dist/client/hooks/use-upload.d.mts +23 -0
- package/dist/client/hooks/use-upload.d.mts.map +1 -0
- package/dist/client/hooks/use-upload.mjs +145 -0
- package/dist/client/hooks/use-upload.mjs.map +1 -0
- package/dist/client/hooks/use-validation-error-map.mjs +53 -0
- package/dist/client/hooks/use-validation-error-map.mjs.map +1 -0
- package/dist/client/hooks/use-view-state.mjs +261 -0
- package/dist/client/hooks/use-view-state.mjs.map +1 -0
- package/dist/client/i18n/hooks.mjs +160 -0
- package/dist/client/i18n/hooks.mjs.map +1 -0
- package/dist/client/i18n/intl-cache.mjs +65 -0
- package/dist/client/i18n/intl-cache.mjs.map +1 -0
- package/dist/client/i18n/messages.mjs +7 -0
- package/dist/client/i18n/messages.mjs.map +1 -0
- package/dist/client/i18n/simple.d.mts +22 -0
- package/dist/client/i18n/simple.d.mts.map +1 -0
- package/dist/client/i18n/simple.mjs +157 -0
- package/dist/client/i18n/simple.mjs.map +1 -0
- package/dist/client/i18n/types.d.mts +110 -0
- package/dist/client/i18n/types.d.mts.map +1 -0
- package/dist/client/lib/utils.d.mts +1 -0
- package/dist/client/lib/utils.mjs +28 -0
- package/dist/client/lib/utils.mjs.map +1 -0
- package/dist/client/preview/block-scope-context.d.mts +74 -0
- package/dist/client/preview/block-scope-context.d.mts.map +1 -0
- package/dist/client/preview/block-scope-context.mjs +93 -0
- package/dist/client/preview/block-scope-context.mjs.map +1 -0
- package/dist/client/preview/index.d.mts +5 -0
- package/dist/client/preview/preview-banner.d.mts +46 -0
- package/dist/client/preview/preview-banner.d.mts.map +1 -0
- package/dist/client/preview/preview-banner.mjs +95 -0
- package/dist/client/preview/preview-banner.mjs.map +1 -0
- package/dist/client/preview/preview-field.d.mts +108 -0
- package/dist/client/preview/preview-field.d.mts.map +1 -0
- package/dist/client/preview/preview-field.mjs +125 -0
- package/dist/client/preview/preview-field.mjs.map +1 -0
- package/dist/client/preview/types.d.mts +115 -0
- package/dist/client/preview/types.d.mts.map +1 -0
- package/dist/client/preview/types.mjs +21 -0
- package/dist/client/preview/types.mjs.map +1 -0
- package/dist/client/preview/use-collection-preview.d.mts +71 -0
- package/dist/client/preview/use-collection-preview.d.mts.map +1 -0
- package/dist/client/preview/use-collection-preview.mjs +114 -0
- package/dist/client/preview/use-collection-preview.mjs.map +1 -0
- package/dist/client/runtime/content-locales-provider.d.mts +1 -0
- package/dist/client/runtime/content-locales-provider.mjs +85 -0
- package/dist/client/runtime/content-locales-provider.mjs.map +1 -0
- package/dist/client/runtime/index.d.mts +7 -0
- package/dist/client/runtime/index.mjs +8 -0
- package/dist/client/runtime/locale-scope.d.mts +2 -0
- package/dist/{runtime-6VZM878K.mjs → client/runtime/locale-scope.mjs} +3 -4
- package/dist/client/runtime/locale-scope.mjs.map +1 -0
- package/dist/client/runtime/provider.d.mts +10107 -0
- package/dist/client/runtime/provider.d.mts.map +1 -0
- package/dist/client/runtime/provider.mjs +229 -0
- package/dist/client/runtime/provider.mjs.map +1 -0
- package/dist/client/runtime/routes.d.mts +49 -0
- package/dist/client/runtime/routes.d.mts.map +1 -0
- package/dist/client/runtime/routes.mjs +107 -0
- package/dist/client/runtime/routes.mjs.map +1 -0
- package/dist/client/runtime/translations-provider.d.mts +2 -0
- package/dist/client/runtime/translations-provider.mjs +181 -0
- package/dist/client/runtime/translations-provider.mjs.map +1 -0
- package/dist/client/scope/index.d.mts +3 -0
- package/dist/client/scope/picker.d.mts +54 -0
- package/dist/client/scope/picker.d.mts.map +1 -0
- package/dist/client/scope/picker.mjs +161 -0
- package/dist/client/scope/picker.mjs.map +1 -0
- package/dist/client/scope/provider.d.mts +104 -0
- package/dist/client/scope/provider.d.mts.map +1 -0
- package/dist/client/scope/provider.mjs +159 -0
- package/dist/client/scope/provider.mjs.map +1 -0
- package/dist/client/scope/types.d.mts +112 -0
- package/dist/client/scope/types.d.mts.map +1 -0
- package/dist/client/styles/index.css +80 -0
- package/dist/client/utils/auto-expand-fields.mjs +65 -0
- package/dist/client/utils/auto-expand-fields.mjs.map +1 -0
- package/dist/client/utils/build-field-definitions-from-schema.mjs +256 -0
- package/dist/client/utils/build-field-definitions-from-schema.mjs.map +1 -0
- package/dist/client/utils/detect-relations.mjs +46 -0
- package/dist/client/utils/detect-relations.mjs.map +1 -0
- package/dist/client/utils/locale-to-flag.d.mts +118 -0
- package/dist/client/utils/locale-to-flag.d.mts.map +1 -0
- package/dist/client/utils/locale-to-flag.mjs +130 -0
- package/dist/client/utils/locale-to-flag.mjs.map +1 -0
- package/dist/client/utils/routes.mjs +196 -0
- package/dist/client/utils/routes.mjs.map +1 -0
- package/dist/client/views/auth/accept-invite-form.d.mts +73 -0
- package/dist/client/views/auth/accept-invite-form.d.mts.map +1 -0
- package/dist/client/views/auth/accept-invite-form.mjs +180 -0
- package/dist/client/views/auth/accept-invite-form.mjs.map +1 -0
- package/dist/client/views/auth/auth-layout.d.mts +44 -0
- package/dist/client/views/auth/auth-layout.d.mts.map +1 -0
- package/dist/client/views/auth/auth-layout.mjs +53 -0
- package/dist/client/views/auth/auth-layout.mjs.map +1 -0
- package/dist/client/views/auth/forgot-password-form.d.mts +59 -0
- package/dist/client/views/auth/forgot-password-form.d.mts.map +1 -0
- package/dist/{forgot-password-page-Bcp-An4Y.mjs → client/views/auth/forgot-password-form.mjs} +22 -89
- package/dist/client/views/auth/forgot-password-form.mjs.map +1 -0
- package/dist/client/views/auth/index.d.mts +7 -0
- package/dist/client/views/auth/invite-form.d.mts +1 -0
- package/dist/client/views/auth/invite-form.mjs +155 -0
- package/dist/client/views/auth/invite-form.mjs.map +1 -0
- package/dist/client/views/auth/login-form.d.mts +76 -0
- package/dist/client/views/auth/login-form.d.mts.map +1 -0
- package/dist/client/views/auth/login-form.mjs +167 -0
- package/dist/client/views/auth/login-form.mjs.map +1 -0
- package/dist/client/views/auth/reset-password-form.d.mts +66 -0
- package/dist/client/views/auth/reset-password-form.d.mts.map +1 -0
- package/dist/client/views/auth/reset-password-form.mjs +188 -0
- package/dist/client/views/auth/reset-password-form.mjs.map +1 -0
- package/dist/client/views/auth/setup-form.d.mts +61 -0
- package/dist/client/views/auth/setup-form.d.mts.map +1 -0
- package/dist/{setup-page-YAP_fzqh.mjs → client/views/auth/setup-form.mjs} +46 -124
- package/dist/client/views/auth/setup-form.mjs.map +1 -0
- package/dist/client/views/collection/auto-form-fields.d.mts +4 -0
- package/dist/client/views/collection/auto-form-fields.mjs +453 -0
- package/dist/client/views/collection/auto-form-fields.mjs.map +1 -0
- package/dist/client/views/collection/bulk-action-toolbar.mjs +291 -0
- package/dist/client/views/collection/bulk-action-toolbar.mjs.map +1 -0
- package/dist/client/views/collection/cells/complex-cells.d.mts +46 -0
- package/dist/client/views/collection/cells/complex-cells.d.mts.map +1 -0
- package/dist/client/views/collection/cells/complex-cells.mjs +327 -0
- package/dist/client/views/collection/cells/complex-cells.mjs.map +1 -0
- package/dist/client/views/collection/cells/index.d.mts +7 -0
- package/dist/client/views/collection/cells/primitive-cells.d.mts +76 -0
- package/dist/client/views/collection/cells/primitive-cells.d.mts.map +1 -0
- package/dist/client/views/collection/cells/primitive-cells.mjs +165 -0
- package/dist/client/views/collection/cells/primitive-cells.mjs.map +1 -0
- package/dist/client/views/collection/cells/relation-cells.d.mts +21 -0
- package/dist/client/views/collection/cells/relation-cells.d.mts.map +1 -0
- package/dist/client/views/collection/cells/relation-cells.mjs +105 -0
- package/dist/client/views/collection/cells/relation-cells.mjs.map +1 -0
- package/dist/client/views/collection/cells/shared/asset-thumbnail.d.mts +1 -0
- package/dist/client/views/collection/cells/shared/asset-thumbnail.mjs +189 -0
- package/dist/client/views/collection/cells/shared/asset-thumbnail.mjs.map +1 -0
- package/dist/client/views/collection/cells/shared/cell-helpers.d.mts +2 -0
- package/dist/client/views/collection/cells/shared/cell-helpers.mjs +78 -0
- package/dist/client/views/collection/cells/shared/cell-helpers.mjs.map +1 -0
- package/dist/client/views/collection/cells/shared/relation-chip.d.mts +1 -0
- package/dist/client/views/collection/cells/shared/relation-chip.mjs +37 -0
- package/dist/client/views/collection/cells/shared/relation-chip.mjs.map +1 -0
- package/dist/client/views/collection/cells/upload-cells.d.mts +25 -0
- package/dist/client/views/collection/cells/upload-cells.d.mts.map +1 -0
- package/dist/client/views/collection/cells/upload-cells.mjs +20 -0
- package/dist/client/views/collection/cells/upload-cells.mjs.map +1 -0
- package/dist/client/views/collection/columns/build-columns.d.mts +2 -0
- package/dist/client/views/collection/columns/build-columns.mjs +156 -0
- package/dist/client/views/collection/columns/build-columns.mjs.map +1 -0
- package/dist/client/views/collection/columns/column-defaults.d.mts +2 -0
- package/dist/client/views/collection/columns/column-defaults.mjs +108 -0
- package/dist/client/views/collection/columns/column-defaults.mjs.map +1 -0
- package/dist/client/views/collection/columns/index.d.mts +3 -0
- package/dist/client/views/collection/columns/types.d.mts +2 -0
- package/dist/client/views/collection/field-context.mjs +127 -0
- package/dist/client/views/collection/field-context.mjs.map +1 -0
- package/dist/client/views/collection/field-renderer.mjs +171 -0
- package/dist/client/views/collection/field-renderer.mjs.map +1 -0
- package/dist/client/views/collection/form-view.d.mts +112 -0
- package/dist/client/views/collection/form-view.d.mts.map +1 -0
- package/dist/client/views/collection/form-view.mjs +903 -0
- package/dist/client/views/collection/form-view.mjs.map +1 -0
- package/dist/client/views/collection/index.d.mts +9 -0
- package/dist/client/views/collection/table-view.d.mts +102 -0
- package/dist/client/views/collection/table-view.d.mts.map +1 -0
- package/dist/client/views/collection/table-view.mjs +695 -0
- package/dist/client/views/collection/table-view.mjs.map +1 -0
- package/dist/client/views/collection/view-skeletons.mjs +121 -0
- package/dist/client/views/collection/view-skeletons.mjs.map +1 -0
- package/dist/client/views/common/global-search.d.mts +1 -0
- package/dist/client/views/common/global-search.mjs +376 -0
- package/dist/client/views/common/global-search.mjs.map +1 -0
- package/dist/client/views/common/index.d.mts +1 -0
- package/dist/client/views/dashboard/dashboard-grid.mjs +385 -0
- package/dist/client/views/dashboard/dashboard-grid.mjs.map +1 -0
- package/dist/client/views/dashboard/dashboard-widget.mjs +178 -0
- package/dist/client/views/dashboard/dashboard-widget.mjs.map +1 -0
- package/dist/client/views/dashboard/widget-card.mjs +159 -0
- package/dist/client/views/dashboard/widget-card.mjs.map +1 -0
- package/dist/client/views/globals/global-form-view.d.mts +74 -0
- package/dist/client/views/globals/global-form-view.d.mts.map +1 -0
- package/dist/client/views/globals/global-form-view.mjs +181 -0
- package/dist/client/views/globals/global-form-view.mjs.map +1 -0
- package/dist/client/views/index.d.mts +28 -0
- package/dist/client/views/layout/admin-layout-provider.d.mts +140 -0
- package/dist/client/views/layout/admin-layout-provider.d.mts.map +1 -0
- package/dist/client/views/layout/admin-layout-provider.mjs +90 -0
- package/dist/client/views/layout/admin-layout-provider.mjs.map +1 -0
- package/dist/client/views/layout/admin-layout.d.mts +151 -0
- package/dist/client/views/layout/admin-layout.d.mts.map +1 -0
- package/dist/client/views/layout/admin-layout.mjs +144 -0
- package/dist/client/views/layout/admin-layout.mjs.map +1 -0
- package/dist/client/views/layout/admin-root.d.mts +7 -0
- package/dist/client/views/layout/admin-router.d.mts +125 -0
- package/dist/client/views/layout/admin-router.d.mts.map +1 -0
- package/dist/client/views/layout/admin-router.mjs +594 -0
- package/dist/client/views/layout/admin-router.mjs.map +1 -0
- package/dist/client/views/layout/admin-sidebar.d.mts +105 -0
- package/dist/client/views/layout/admin-sidebar.d.mts.map +1 -0
- package/dist/client/views/layout/admin-sidebar.mjs +550 -0
- package/dist/client/views/layout/admin-sidebar.mjs.map +1 -0
- package/dist/client/views/layout/admin-topbar.mjs +128 -0
- package/dist/client/views/layout/admin-topbar.mjs.map +1 -0
- package/dist/client/views/layout/index.d.mts +5 -0
- package/dist/client/views/pages/accept-invite-page.d.mts +67 -0
- package/dist/client/views/pages/accept-invite-page.d.mts.map +1 -0
- package/dist/client/views/pages/accept-invite-page.mjs +143 -0
- package/dist/client/views/pages/accept-invite-page.mjs.map +1 -0
- package/dist/client/views/pages/dashboard-page.d.mts +52 -0
- package/dist/client/views/pages/dashboard-page.d.mts.map +1 -0
- package/dist/client/views/pages/dashboard-page.mjs +45 -0
- package/dist/client/views/pages/dashboard-page.mjs.map +1 -0
- package/dist/client/views/pages/forgot-password-page.d.mts +59 -0
- package/dist/client/views/pages/forgot-password-page.d.mts.map +1 -0
- package/dist/client/views/pages/forgot-password-page.mjs +80 -0
- package/dist/client/views/pages/forgot-password-page.mjs.map +1 -0
- package/dist/client/views/pages/index.d.mts +7 -0
- package/dist/client/views/pages/invite-page.d.mts +71 -0
- package/dist/client/views/pages/invite-page.d.mts.map +1 -0
- package/dist/client/views/pages/invite-page.mjs +86 -0
- package/dist/client/views/pages/invite-page.mjs.map +1 -0
- package/dist/client/views/pages/login-page.d.mts +76 -0
- package/dist/client/views/pages/login-page.d.mts.map +1 -0
- package/dist/client/views/pages/login-page.mjs +98 -0
- package/dist/client/views/pages/login-page.mjs.map +1 -0
- package/dist/client/views/pages/reset-password-page.d.mts +66 -0
- package/dist/client/views/pages/reset-password-page.d.mts.map +1 -0
- package/dist/client/views/pages/reset-password-page.mjs +105 -0
- package/dist/client/views/pages/reset-password-page.mjs.map +1 -0
- package/dist/client/views/pages/setup-page.d.mts +64 -0
- package/dist/client/views/pages/setup-page.d.mts.map +1 -0
- package/dist/client/views/pages/setup-page.mjs +91 -0
- package/dist/client/views/pages/setup-page.mjs.map +1 -0
- package/dist/client.d.mts +92 -3
- package/dist/client.d.mts.map +1 -0
- package/dist/client.mjs +54 -12
- package/dist/components/rich-text/index.d.mts +1 -0
- package/dist/components/rich-text/rich-text-renderer.d.mts +104 -0
- package/dist/components/rich-text/rich-text-renderer.d.mts.map +1 -0
- package/dist/components/rich-text/rich-text-renderer.mjs +210 -0
- package/dist/components/rich-text/rich-text-renderer.mjs.map +1 -0
- package/dist/index.d.mts +62 -3
- package/dist/index.mjs +54 -12
- package/dist/server/adapters/nextjs.d.mts +121 -0
- package/dist/server/adapters/nextjs.d.mts.map +1 -0
- package/dist/server/adapters/nextjs.mjs +111 -0
- package/dist/server/adapters/nextjs.mjs.map +1 -0
- package/dist/server/adapters/tanstack.d.mts +133 -0
- package/dist/server/adapters/tanstack.d.mts.map +1 -0
- package/dist/server/adapters/tanstack.mjs +90 -0
- package/dist/server/adapters/tanstack.mjs.map +1 -0
- package/dist/server/augmentation.d.mts +1523 -0
- package/dist/server/augmentation.d.mts.map +1 -0
- package/dist/server/auth-helpers.d.mts +143 -0
- package/dist/server/auth-helpers.d.mts.map +1 -0
- package/dist/server/auth-helpers.mjs +108 -0
- package/dist/server/auth-helpers.mjs.map +1 -0
- package/dist/server/block/block-builder.d.mts +319 -0
- package/dist/server/block/block-builder.d.mts.map +1 -0
- package/dist/server/block/block-builder.mjs +217 -0
- package/dist/server/block/block-builder.mjs.map +1 -0
- package/dist/server/block/index.d.mts +3 -0
- package/dist/server/block/introspection.d.mts +84 -0
- package/dist/server/block/introspection.d.mts.map +1 -0
- package/dist/server/block/introspection.mjs +89 -0
- package/dist/server/block/introspection.mjs.map +1 -0
- package/dist/server/block/prefetch.d.mts +78 -0
- package/dist/server/block/prefetch.d.mts.map +1 -0
- package/dist/server/block/prefetch.mjs +240 -0
- package/dist/server/block/prefetch.mjs.map +1 -0
- package/dist/server/fields/blocks.d.mts +139 -0
- package/dist/server/fields/blocks.d.mts.map +1 -0
- package/dist/server/fields/blocks.mjs +192 -0
- package/dist/server/fields/blocks.mjs.map +1 -0
- package/dist/server/fields/index.d.mts +48 -0
- package/dist/server/fields/index.d.mts.map +1 -0
- package/dist/server/fields/index.mjs +16 -0
- package/dist/server/fields/index.mjs.map +1 -0
- package/dist/server/fields/rich-text.d.mts +135 -0
- package/dist/server/fields/rich-text.d.mts.map +1 -0
- package/dist/server/fields/rich-text.mjs +188 -0
- package/dist/server/fields/rich-text.mjs.map +1 -0
- package/dist/server/i18n/index.d.mts +16 -0
- package/dist/server/i18n/index.d.mts.map +1 -0
- package/dist/server/i18n/index.mjs +44 -0
- package/dist/server/i18n/index.mjs.map +1 -0
- package/dist/server/i18n/messages/cs.mjs +461 -0
- package/dist/server/i18n/messages/cs.mjs.map +1 -0
- package/dist/server/i18n/messages/de.mjs +461 -0
- package/dist/server/i18n/messages/de.mjs.map +1 -0
- package/dist/server/i18n/messages/en.mjs +493 -0
- package/dist/server/i18n/messages/en.mjs.map +1 -0
- package/dist/server/i18n/messages/es.mjs +461 -0
- package/dist/server/i18n/messages/es.mjs.map +1 -0
- package/dist/server/i18n/messages/fr.mjs +461 -0
- package/dist/server/i18n/messages/fr.mjs.map +1 -0
- package/dist/server/i18n/messages/index.mjs +24 -0
- package/dist/server/i18n/messages/index.mjs.map +1 -0
- package/dist/server/i18n/messages/pl.mjs +461 -0
- package/dist/server/i18n/messages/pl.mjs.map +1 -0
- package/dist/server/i18n/messages/pt.mjs +464 -0
- package/dist/server/i18n/messages/pt.mjs.map +1 -0
- package/dist/server/i18n/messages/sk.mjs +490 -0
- package/dist/server/i18n/messages/sk.mjs.map +1 -0
- package/dist/server/index.d.mts +20 -0
- package/dist/server/modules/admin/functions/admin-config.mjs +348 -0
- package/dist/server/modules/admin/functions/admin-config.mjs.map +1 -0
- package/dist/server/modules/admin/functions/execute-action.d.mts +107 -0
- package/dist/server/modules/admin/functions/execute-action.d.mts.map +1 -0
- package/dist/server/modules/admin/functions/execute-action.mjs +331 -0
- package/dist/server/modules/admin/functions/execute-action.mjs.map +1 -0
- package/dist/server/modules/admin/functions/locales.mjs +80 -0
- package/dist/server/modules/admin/functions/locales.mjs.map +1 -0
- package/dist/server/modules/admin/functions/preview.d.mts +70 -0
- package/dist/server/modules/admin/functions/preview.d.mts.map +1 -0
- package/dist/server/modules/admin/functions/preview.mjs +243 -0
- package/dist/server/modules/admin/functions/preview.mjs.map +1 -0
- package/dist/server/modules/admin/functions/reactive.d.mts +99 -0
- package/dist/server/modules/admin/functions/reactive.d.mts.map +1 -0
- package/dist/server/modules/admin/functions/reactive.mjs +378 -0
- package/dist/server/modules/admin/functions/reactive.mjs.map +1 -0
- package/dist/server/modules/admin/functions/setup.d.mts +84 -0
- package/dist/server/modules/admin/functions/setup.d.mts.map +1 -0
- package/dist/server/modules/admin/functions/setup.mjs +131 -0
- package/dist/server/modules/admin/functions/setup.mjs.map +1 -0
- package/dist/server/modules/admin/functions/translations.mjs +125 -0
- package/dist/server/modules/admin/functions/translations.mjs.map +1 -0
- package/dist/server/modules/admin/functions/widget-data.d.mts +33 -0
- package/dist/server/modules/admin/functions/widget-data.d.mts.map +1 -0
- package/dist/server/modules/admin/functions/widget-data.mjs +70 -0
- package/dist/server/modules/admin/functions/widget-data.mjs.map +1 -0
- package/dist/server/modules/admin/index.d.mts +16879 -0
- package/dist/server/modules/admin/index.d.mts.map +1 -0
- package/dist/server/modules/admin/index.mjs +249 -0
- package/dist/server/modules/admin/index.mjs.map +1 -0
- package/dist/server/modules/admin-preferences/collections/admin-preferences.collection.d.mts +3 -0
- package/dist/server/modules/admin-preferences/collections/admin-preferences.collection.mjs +48 -0
- package/dist/server/modules/admin-preferences/collections/admin-preferences.collection.mjs.map +1 -0
- package/dist/server/modules/admin-preferences/collections/locks.collection.d.mts +3 -0
- package/dist/server/modules/admin-preferences/collections/locks.collection.mjs +79 -0
- package/dist/server/modules/admin-preferences/collections/locks.collection.mjs.map +1 -0
- package/dist/server/modules/admin-preferences/collections/saved-views.collection.d.mts +1490 -0
- package/dist/server/modules/admin-preferences/collections/saved-views.collection.d.mts.map +1 -0
- package/dist/server/modules/admin-preferences/collections/saved-views.collection.mjs +57 -0
- package/dist/server/modules/admin-preferences/collections/saved-views.collection.mjs.map +1 -0
- package/dist/server/patch.d.mts +100 -0
- package/dist/server/patch.d.mts.map +1 -0
- package/dist/server/patch.mjs +1062 -0
- package/dist/server/patch.mjs.map +1 -0
- package/dist/server.d.mts +21 -250
- package/dist/server.mjs +19 -832
- package/dist/shared/preview-utils.d.mts +54 -0
- package/dist/shared/preview-utils.d.mts.map +1 -0
- package/dist/{preview-utils-BKQ9-TMa.mjs → shared/preview-utils.mjs} +2 -2
- package/dist/shared/preview-utils.mjs.map +1 -0
- package/dist/{saved-views.types-BMsz5mCy.d.mts → shared/types/saved-views.types.d.mts} +7 -2
- package/dist/shared/types/saved-views.types.d.mts.map +1 -0
- package/dist/shared.d.mts +3 -57
- package/dist/shared.mjs +1 -1
- package/package.json +12 -17
- package/dist/auth-layout-M8K8_q5R.mjs +0 -181
- package/dist/auth-layout-M8K8_q5R.mjs.map +0 -1
- package/dist/bulk-upload-dialog-D7w7W1Hl.mjs +0 -273
- package/dist/bulk-upload-dialog-D7w7W1Hl.mjs.map +0 -1
- package/dist/client-B7r47hEd.d.mts +0 -13403
- package/dist/client-B7r47hEd.d.mts.map +0 -1
- package/dist/client-njX1rZmi.mjs +0 -22612
- package/dist/client-njX1rZmi.mjs.map +0 -1
- package/dist/content-locales-provider-BXvuIgfg.mjs +0 -1650
- package/dist/content-locales-provider-BXvuIgfg.mjs.map +0 -1
- package/dist/dashboard-page-B4PGEdc2.mjs +0 -2500
- package/dist/dashboard-page-B4PGEdc2.mjs.map +0 -1
- package/dist/dashboard-page-mCY0pgZv.mjs +0 -3
- package/dist/dropzone-Do3awXKd.mjs +0 -634
- package/dist/dropzone-Do3awXKd.mjs.map +0 -1
- package/dist/forgot-password-page-Bcp-An4Y.mjs.map +0 -1
- package/dist/forgot-password-page-CEwsdLwn.mjs +0 -3
- package/dist/index-BYyqkWtn.d.mts +0 -2753
- package/dist/index-BYyqkWtn.d.mts.map +0 -1
- package/dist/login-page-BUnpCbCa.mjs +0 -3
- package/dist/login-page-CP4gA-dl.mjs +0 -298
- package/dist/login-page-CP4gA-dl.mjs.map +0 -1
- package/dist/preview-utils-BKQ9-TMa.mjs.map +0 -1
- package/dist/reset-password-page-BqfDmLxA.mjs +0 -281
- package/dist/reset-password-page-BqfDmLxA.mjs.map +0 -1
- package/dist/reset-password-page-CufHz3h3.mjs +0 -3
- package/dist/runtime-6VZM878K.mjs.map +0 -1
- package/dist/saved-views.types-BMsz5mCy.d.mts.map +0 -1
- package/dist/server.d.mts.map +0 -1
- package/dist/server.mjs.map +0 -1
- package/dist/setup-page-BNNzt_Z6.mjs +0 -3
- package/dist/setup-page-YAP_fzqh.mjs.map +0 -1
- package/dist/shared.d.mts.map +0 -1
- package/dist/use-auth-BoLmWtmU.mjs.map +0 -1
|
@@ -0,0 +1,571 @@
|
|
|
1
|
+
import "../../i18n/types.mjs";
|
|
2
|
+
import { SelectOption as SelectOption$1 } from "../primitives/types.mjs";
|
|
3
|
+
import { RelationDisplayFields as RelationDisplayFields$1, RelationDisplayMode as RelationDisplayMode$1 } from "./relation/displays/types.mjs";
|
|
4
|
+
import { BooleanFieldProps } from "./boolean-field.mjs";
|
|
5
|
+
import "react";
|
|
6
|
+
import { Control } from "react-hook-form";
|
|
7
|
+
|
|
8
|
+
//#region src/client/components/fields/field-types.d.ts
|
|
9
|
+
|
|
10
|
+
type SelectOption<TValue = string> = SelectOption$1<TValue>;
|
|
11
|
+
/**
|
|
12
|
+
* Base props shared by all field components (runtime).
|
|
13
|
+
* These integrate with react-hook-form via Controller.
|
|
14
|
+
* I18nText values are resolved to plain strings before reaching components.
|
|
15
|
+
*/
|
|
16
|
+
type BaseFieldProps = {
|
|
17
|
+
/** Field name (path in form values) */
|
|
18
|
+
name: string;
|
|
19
|
+
/** Field label (resolved from I18nText) */
|
|
20
|
+
label?: string;
|
|
21
|
+
/** Helper text shown below the field (resolved from I18nText) */
|
|
22
|
+
description?: string;
|
|
23
|
+
/** Placeholder text (resolved from I18nText) */
|
|
24
|
+
placeholder?: string;
|
|
25
|
+
/** Mark field as required (visual indicator) */
|
|
26
|
+
required?: boolean;
|
|
27
|
+
/** Disable the field */
|
|
28
|
+
disabled?: boolean;
|
|
29
|
+
/** Show locale badge for localized fields */
|
|
30
|
+
localized?: boolean;
|
|
31
|
+
/** Current locale code for localized fields */
|
|
32
|
+
locale?: string;
|
|
33
|
+
/** Form control from react-hook-form (optional if using FormProvider) */
|
|
34
|
+
control?: Control<any>;
|
|
35
|
+
/** Additional className for the field wrapper */
|
|
36
|
+
className?: string;
|
|
37
|
+
};
|
|
38
|
+
/**
|
|
39
|
+
* Props for text-based fields
|
|
40
|
+
*/
|
|
41
|
+
type TextFieldProps = BaseFieldProps & {
|
|
42
|
+
type?: "text" | "email" | "password" | "url" | "tel" | "search";
|
|
43
|
+
minLength?: number;
|
|
44
|
+
maxLength?: number;
|
|
45
|
+
/** Regex pattern for validation (from server metadata) */
|
|
46
|
+
pattern?: string | RegExp;
|
|
47
|
+
autoComplete?: string;
|
|
48
|
+
};
|
|
49
|
+
/**
|
|
50
|
+
* Props for number field
|
|
51
|
+
*/
|
|
52
|
+
type NumberFieldProps = BaseFieldProps & {
|
|
53
|
+
min?: number;
|
|
54
|
+
max?: number;
|
|
55
|
+
step?: number;
|
|
56
|
+
showButtons?: boolean;
|
|
57
|
+
};
|
|
58
|
+
/**
|
|
59
|
+
* Props for textarea field
|
|
60
|
+
*/
|
|
61
|
+
type TextareaFieldProps = BaseFieldProps & {
|
|
62
|
+
rows?: number;
|
|
63
|
+
minLength?: number;
|
|
64
|
+
maxLength?: number;
|
|
65
|
+
autoResize?: boolean;
|
|
66
|
+
};
|
|
67
|
+
/**
|
|
68
|
+
* Props for select field
|
|
69
|
+
*/
|
|
70
|
+
type SelectFieldProps<TValue = string> = BaseFieldProps & {
|
|
71
|
+
options?: SelectOption<TValue>[];
|
|
72
|
+
loadOptions?: (search: string) => Promise<SelectOption<TValue>[]>;
|
|
73
|
+
multiple?: boolean;
|
|
74
|
+
clearable?: boolean;
|
|
75
|
+
maxSelections?: number;
|
|
76
|
+
emptyMessage?: string;
|
|
77
|
+
};
|
|
78
|
+
/**
|
|
79
|
+
* Props for date field
|
|
80
|
+
*/
|
|
81
|
+
type DateFieldProps = BaseFieldProps & {
|
|
82
|
+
minDate?: Date;
|
|
83
|
+
maxDate?: Date;
|
|
84
|
+
format?: string;
|
|
85
|
+
};
|
|
86
|
+
/**
|
|
87
|
+
* Props for datetime field
|
|
88
|
+
*/
|
|
89
|
+
type DateTimeFieldProps = DateFieldProps & {
|
|
90
|
+
precision?: "minute" | "second";
|
|
91
|
+
};
|
|
92
|
+
/**
|
|
93
|
+
* Props for time field (time-only, no date)
|
|
94
|
+
*/
|
|
95
|
+
type TimeFieldProps = BaseFieldProps & {
|
|
96
|
+
precision?: "minute" | "second";
|
|
97
|
+
};
|
|
98
|
+
/** Text field config */
|
|
99
|
+
type TextFieldConfig = Omit<TextFieldProps, keyof BaseFieldProps>;
|
|
100
|
+
/** Number field config */
|
|
101
|
+
type NumberFieldConfig = Omit<NumberFieldProps, keyof BaseFieldProps>;
|
|
102
|
+
/** Textarea field config */
|
|
103
|
+
type TextareaFieldConfig = Omit<TextareaFieldProps, keyof BaseFieldProps>;
|
|
104
|
+
/** Select field config */
|
|
105
|
+
type SelectFieldConfig<TValue = string> = Omit<SelectFieldProps<TValue>, keyof BaseFieldProps>;
|
|
106
|
+
/** Date field config */
|
|
107
|
+
type DateFieldConfig = Omit<DateFieldProps, keyof BaseFieldProps>;
|
|
108
|
+
/** DateTime field config */
|
|
109
|
+
type DateTimeFieldConfig = Omit<DateTimeFieldProps, keyof BaseFieldProps>;
|
|
110
|
+
/** Time field config */
|
|
111
|
+
type TimeFieldConfig = Omit<TimeFieldProps, keyof BaseFieldProps>;
|
|
112
|
+
/** Boolean (checkbox/switch) field config */
|
|
113
|
+
type BooleanFieldConfig = {
|
|
114
|
+
/**
|
|
115
|
+
* Display mode for the boolean field.
|
|
116
|
+
* @default "checkbox"
|
|
117
|
+
*/
|
|
118
|
+
displayAs?: "checkbox" | "switch";
|
|
119
|
+
};
|
|
120
|
+
type RelationDisplayMode = RelationDisplayMode$1;
|
|
121
|
+
type RelationDisplayFields = RelationDisplayFields$1;
|
|
122
|
+
/** Relation field config */
|
|
123
|
+
type RelationFieldConfig = {
|
|
124
|
+
/** Target collection name */
|
|
125
|
+
targetCollection: string;
|
|
126
|
+
/** Relation type: single (one-to-one) or multiple (one-to-many) */
|
|
127
|
+
type: "single" | "multiple";
|
|
128
|
+
/**
|
|
129
|
+
* Backend relation name for auto-expand in list views.
|
|
130
|
+
* Use this when the admin field name differs from the backend relation name.
|
|
131
|
+
*
|
|
132
|
+
* @example
|
|
133
|
+
* // Admin field: customerId, Backend relation: customer
|
|
134
|
+
* customerId: r.relation({
|
|
135
|
+
* targetCollection: "user",
|
|
136
|
+
* type: "single",
|
|
137
|
+
* relationName: "customer", // Will expand as { with: { customer: true } }
|
|
138
|
+
* })
|
|
139
|
+
*/
|
|
140
|
+
relationName?: string;
|
|
141
|
+
/** Filter options based on form values */
|
|
142
|
+
filter?: (formValues: any) => any;
|
|
143
|
+
/** Enable drag-and-drop reordering (only for multiple) */
|
|
144
|
+
orderable?: boolean;
|
|
145
|
+
/** Maximum number of items (only for multiple) */
|
|
146
|
+
maxItems?: number;
|
|
147
|
+
/**
|
|
148
|
+
* Display mode for selected items (only for multiple type)
|
|
149
|
+
* @default "list"
|
|
150
|
+
*/
|
|
151
|
+
display?: RelationDisplayMode;
|
|
152
|
+
/**
|
|
153
|
+
* Columns to show in table display mode (only for multiple type)
|
|
154
|
+
*/
|
|
155
|
+
columns?: string[];
|
|
156
|
+
/**
|
|
157
|
+
* Field mapping for cards/grid display modes (only for multiple type)
|
|
158
|
+
*/
|
|
159
|
+
fields?: RelationDisplayFields;
|
|
160
|
+
/**
|
|
161
|
+
* Number of columns for grid/cards layout (only for multiple type)
|
|
162
|
+
*/
|
|
163
|
+
gridColumns?: 1 | 2 | 3 | 4;
|
|
164
|
+
};
|
|
165
|
+
/**
|
|
166
|
+
* Upload field config.
|
|
167
|
+
*
|
|
168
|
+
* Handles both single and multiple file uploads based on `multiple` option.
|
|
169
|
+
* Maps to server's `upload` field type.
|
|
170
|
+
*
|
|
171
|
+
* @example Single upload (default)
|
|
172
|
+
* ```ts
|
|
173
|
+
* featuredImage: r.upload({
|
|
174
|
+
* accept: ["image/*"],
|
|
175
|
+
* maxSize: 5_000_000,
|
|
176
|
+
* })
|
|
177
|
+
* ```
|
|
178
|
+
*
|
|
179
|
+
* @example Multiple uploads
|
|
180
|
+
* ```ts
|
|
181
|
+
* gallery: r.upload({
|
|
182
|
+
* multiple: true,
|
|
183
|
+
* accept: ["image/*"],
|
|
184
|
+
* maxItems: 10,
|
|
185
|
+
* orderable: true,
|
|
186
|
+
* })
|
|
187
|
+
* ```
|
|
188
|
+
*/
|
|
189
|
+
type UploadFieldConfig = {
|
|
190
|
+
/** Target collection for uploads */
|
|
191
|
+
to?: string;
|
|
192
|
+
/** Accepted file types (MIME types or extensions) */
|
|
193
|
+
accept?: string[];
|
|
194
|
+
/** Maximum file size in bytes */
|
|
195
|
+
maxSize?: number;
|
|
196
|
+
/** Show image preview for uploaded files (default: true) */
|
|
197
|
+
showPreview?: boolean;
|
|
198
|
+
/** Allow editing alt/caption */
|
|
199
|
+
editable?: boolean;
|
|
200
|
+
/** Preview variant */
|
|
201
|
+
previewVariant?: "card" | "compact" | "thumbnail";
|
|
202
|
+
/**
|
|
203
|
+
* Enable multiple file uploads.
|
|
204
|
+
* When true, field value is an array of asset IDs.
|
|
205
|
+
* @default false
|
|
206
|
+
*/
|
|
207
|
+
multiple?: boolean;
|
|
208
|
+
/** Maximum number of files (only when multiple: true) */
|
|
209
|
+
maxItems?: number;
|
|
210
|
+
/** Enable drag-and-drop reordering (only when multiple: true) */
|
|
211
|
+
orderable?: boolean;
|
|
212
|
+
/** Layout for previews (only when multiple: true) */
|
|
213
|
+
layout?: "grid" | "list";
|
|
214
|
+
};
|
|
215
|
+
/**
|
|
216
|
+
* Nested field definition for object fields.
|
|
217
|
+
* Uses a callback pattern to allow access to the field registry.
|
|
218
|
+
*/
|
|
219
|
+
type NestedFieldsDefinition = Record<string, any>;
|
|
220
|
+
/**
|
|
221
|
+
* Object field layout options - controls how nested fields are arranged inside the container.
|
|
222
|
+
*
|
|
223
|
+
* @example Visual comparison:
|
|
224
|
+
* ```
|
|
225
|
+
* ┌─────────────────────────────────────────────────────────────┐
|
|
226
|
+
* │ "stack" (default) │ "inline" │
|
|
227
|
+
* │ │ │
|
|
228
|
+
* │ ┌─────────────────────────┐ │ ┌────────┐ ┌────────┐ ┌─────┐ │
|
|
229
|
+
* │ │ First Name │ │ │ First │ │ Last │ │ Age │ │
|
|
230
|
+
* │ └─────────────────────────┘ │ └────────┘ └────────┘ └─────┘ │
|
|
231
|
+
* │ ┌─────────────────────────┐ │ │
|
|
232
|
+
* │ │ Last Name │ │ Fields wrap to next line │
|
|
233
|
+
* │ └─────────────────────────┘ │ if space is limited │
|
|
234
|
+
* │ ┌─────────────────────────┐ │ │
|
|
235
|
+
* │ │ Age │ │ │
|
|
236
|
+
* │ └─────────────────────────┘ │ │
|
|
237
|
+
* └─────────────────────────────────────────────────────────────┘
|
|
238
|
+
*
|
|
239
|
+
* ┌─────────────────────────────────────────────────────────────┐
|
|
240
|
+
* │ "grid" (columns: 2) │
|
|
241
|
+
* │ │
|
|
242
|
+
* │ ┌─────────────────┐ ┌─────────────────┐ │
|
|
243
|
+
* │ │ First Name │ │ Last Name │ │
|
|
244
|
+
* │ └─────────────────┘ └─────────────────┘ │
|
|
245
|
+
* │ ┌─────────────────┐ ┌─────────────────┐ │
|
|
246
|
+
* │ │ Email │ │ Phone │ │
|
|
247
|
+
* │ └─────────────────┘ └─────────────────┘ │
|
|
248
|
+
* │ │
|
|
249
|
+
* │ Responsive: collapses to 1 column on mobile │
|
|
250
|
+
* └─────────────────────────────────────────────────────────────┘
|
|
251
|
+
* ```
|
|
252
|
+
*
|
|
253
|
+
* - `"stack"` - Vertical layout, each field on its own line. Best for forms with
|
|
254
|
+
* longer labels or when fields need full width (textareas, rich text).
|
|
255
|
+
*
|
|
256
|
+
* - `"inline"` - Horizontal layout using flexbox. Fields sit side-by-side and wrap
|
|
257
|
+
* when space runs out. Best for compact groups of small fields (e.g., time range:
|
|
258
|
+
* start + end, or address: city + zip).
|
|
259
|
+
*
|
|
260
|
+
* - `"grid"` - CSS Grid layout with configurable columns. Fields are evenly distributed.
|
|
261
|
+
* Best for forms with many similar-sized fields. Use `columns` prop to control
|
|
262
|
+
* column count (default: 2). Responsive breakpoints adjust columns automatically.
|
|
263
|
+
*/
|
|
264
|
+
type ObjectFieldLayout = "stack" | "inline" | "grid";
|
|
265
|
+
/**
|
|
266
|
+
* Object field wrapper options - controls the container's visual appearance and behavior.
|
|
267
|
+
*
|
|
268
|
+
* @example Visual comparison:
|
|
269
|
+
* ```
|
|
270
|
+
* ┌─────────────────────────────────────────────────────────────┐
|
|
271
|
+
* │ "flat" (default) │
|
|
272
|
+
* │ │
|
|
273
|
+
* │ No visual container - fields render directly. │
|
|
274
|
+
* │ Use when parent already provides structure (e.g., inside │
|
|
275
|
+
* │ a card, section, or another collapsible). │
|
|
276
|
+
* │ │
|
|
277
|
+
* │ ┌─────────────────────────┐ │
|
|
278
|
+
* │ │ Field 1 │ │
|
|
279
|
+
* │ └─────────────────────────┘ │
|
|
280
|
+
* │ ┌─────────────────────────┐ │
|
|
281
|
+
* │ │ Field 2 │ │
|
|
282
|
+
* │ └─────────────────────────┘ │
|
|
283
|
+
* └─────────────────────────────────────────────────────────────┘
|
|
284
|
+
*
|
|
285
|
+
* ┌─────────────────────────────────────────────────────────────┐
|
|
286
|
+
* │ "collapsible" │
|
|
287
|
+
* │ │
|
|
288
|
+
* │ ┌─────────────────────────────────────────────────────────┐ │
|
|
289
|
+
* │ │ ▶ Section Label [expand] │ │
|
|
290
|
+
* │ └─────────────────────────────────────────────────────────┘ │
|
|
291
|
+
* │ │
|
|
292
|
+
* │ When expanded: │
|
|
293
|
+
* │ ┌─────────────────────────────────────────────────────────┐ │
|
|
294
|
+
* │ │ ▼ Section Label [collapse] │ │
|
|
295
|
+
* │ ├─────────────────────────────────────────────────────────┤ │
|
|
296
|
+
* │ │ ┌─────────────────────────┐ │ │
|
|
297
|
+
* │ │ │ Field 1 │ │ │
|
|
298
|
+
* │ │ └─────────────────────────┘ │ │
|
|
299
|
+
* │ │ ┌─────────────────────────┐ │ │
|
|
300
|
+
* │ │ │ Field 2 │ │ │
|
|
301
|
+
* │ │ └─────────────────────────┘ │ │
|
|
302
|
+
* │ └─────────────────────────────────────────────────────────┘ │
|
|
303
|
+
* │ │
|
|
304
|
+
* │ Accordion-style with subtle background. Use for optional │
|
|
305
|
+
* │ or advanced sections to reduce visual clutter. │
|
|
306
|
+
* └─────────────────────────────────────────────────────────────┘
|
|
307
|
+
* ```
|
|
308
|
+
*
|
|
309
|
+
* - `"flat"` - No visual container. Fields render directly without any wrapper styling.
|
|
310
|
+
* Use when the parent element already provides visual structure.
|
|
311
|
+
*
|
|
312
|
+
* - `"collapsible"` - Accordion-style container with click-to-expand header.
|
|
313
|
+
* Has subtle background styling. Use `defaultCollapsed` to control initial state.
|
|
314
|
+
* Requires a `label` prop for the header text.
|
|
315
|
+
*/
|
|
316
|
+
type ObjectFieldWrapper = "flat" | "collapsible";
|
|
317
|
+
/**
|
|
318
|
+
* Object field config - for nested JSON structures.
|
|
319
|
+
*
|
|
320
|
+
* Combines `wrapper` (container behavior) with `layout` (field arrangement)
|
|
321
|
+
* to create flexible nested field groups.
|
|
322
|
+
*
|
|
323
|
+
* @example Collapsible section with grid layout
|
|
324
|
+
* ```ts
|
|
325
|
+
* address: r.object({
|
|
326
|
+
* label: "Shipping Address",
|
|
327
|
+
* wrapper: "collapsible", // Accordion-style expandable section
|
|
328
|
+
* layout: "grid", // Fields in 2-column grid
|
|
329
|
+
* columns: 2,
|
|
330
|
+
* defaultCollapsed: false,
|
|
331
|
+
* fields: ({ r }) => ({
|
|
332
|
+
* street: r.text({ label: "Street" }),
|
|
333
|
+
* city: r.text({ label: "City" }),
|
|
334
|
+
* zip: r.text({ label: "ZIP Code" }),
|
|
335
|
+
* country: r.text({ label: "Country" }),
|
|
336
|
+
* }),
|
|
337
|
+
* })
|
|
338
|
+
* ```
|
|
339
|
+
*
|
|
340
|
+
* @example Inline layout for compact field groups
|
|
341
|
+
* ```ts
|
|
342
|
+
* timeRange: r.object({
|
|
343
|
+
* label: "Working Hours",
|
|
344
|
+
* layout: "inline", // Fields side-by-side
|
|
345
|
+
* fields: ({ r }) => ({
|
|
346
|
+
* start: r.text({ label: "From", placeholder: "09:00" }),
|
|
347
|
+
* end: r.text({ label: "To", placeholder: "17:00" }),
|
|
348
|
+
* }),
|
|
349
|
+
* })
|
|
350
|
+
* ```
|
|
351
|
+
*
|
|
352
|
+
* @example Flat wrapper (no container) - for use inside sections
|
|
353
|
+
* ```ts
|
|
354
|
+
* seoSettings: r.object({
|
|
355
|
+
* // No label, no wrapper - parent section handles structure
|
|
356
|
+
* wrapper: "flat",
|
|
357
|
+
* layout: "stack",
|
|
358
|
+
* fields: ({ r }) => ({
|
|
359
|
+
* metaTitle: r.text({ label: "Meta Title" }),
|
|
360
|
+
* metaDescription: r.textarea({ label: "Meta Description" }),
|
|
361
|
+
* }),
|
|
362
|
+
* })
|
|
363
|
+
* ```
|
|
364
|
+
*/
|
|
365
|
+
type ObjectFieldConfig = {
|
|
366
|
+
/**
|
|
367
|
+
* Nested field definitions.
|
|
368
|
+
* Callback receives field registry for creating nested fields.
|
|
369
|
+
*
|
|
370
|
+
* The `r` parameter type is automatically inferred from your field registry
|
|
371
|
+
* when using the builder (e.g., `builder.collection(...).fields(({ r }) => ...)`).
|
|
372
|
+
* This provides full autocomplete for nested object/array fields.
|
|
373
|
+
*/
|
|
374
|
+
fields?: (ctx: {
|
|
375
|
+
r: any;
|
|
376
|
+
}) => NestedFieldsDefinition;
|
|
377
|
+
/**
|
|
378
|
+
* Wrapper mode for the container.
|
|
379
|
+
* Controls visual appearance and expand/collapse behavior.
|
|
380
|
+
*
|
|
381
|
+
* @default "flat"
|
|
382
|
+
* @see ObjectFieldWrapper for detailed visual examples
|
|
383
|
+
*/
|
|
384
|
+
wrapper?: ObjectFieldWrapper;
|
|
385
|
+
/**
|
|
386
|
+
* Layout mode for nested fields inside the container.
|
|
387
|
+
* Controls how fields are arranged spatially.
|
|
388
|
+
*
|
|
389
|
+
* @default "stack"
|
|
390
|
+
* @see ObjectFieldLayout for detailed visual examples
|
|
391
|
+
*/
|
|
392
|
+
layout?: ObjectFieldLayout;
|
|
393
|
+
/**
|
|
394
|
+
* Number of columns for grid layout.
|
|
395
|
+
* Only applies when `layout: "grid"`.
|
|
396
|
+
* Responsive: automatically reduces columns on smaller screens.
|
|
397
|
+
*
|
|
398
|
+
* @default 2
|
|
399
|
+
*/
|
|
400
|
+
columns?: number;
|
|
401
|
+
/**
|
|
402
|
+
* Default collapsed state for collapsible wrapper.
|
|
403
|
+
* Only applies when `wrapper: "collapsible"`.
|
|
404
|
+
*
|
|
405
|
+
* @default true
|
|
406
|
+
*/
|
|
407
|
+
defaultCollapsed?: boolean;
|
|
408
|
+
};
|
|
409
|
+
/**
|
|
410
|
+
* Primitive item types supported by array field
|
|
411
|
+
*/
|
|
412
|
+
type ArrayItemType = "text" | "number" | "email" | "textarea" | "select";
|
|
413
|
+
/**
|
|
414
|
+
* Array field config - for arrays of primitives or objects.
|
|
415
|
+
*
|
|
416
|
+
* @example Object array with inline layout
|
|
417
|
+
* ```ts
|
|
418
|
+
* socialLinks: r.array({
|
|
419
|
+
* label: "Social Links",
|
|
420
|
+
* mode: "inline", // Edit fields directly in list
|
|
421
|
+
* layout: "inline", // Fields side-by-side within each item
|
|
422
|
+
* orderable: true,
|
|
423
|
+
* item: ({ r }) => ({
|
|
424
|
+
* platform: r.select({ label: "Platform", options: [...] }),
|
|
425
|
+
* url: r.text({ label: "URL" }),
|
|
426
|
+
* }),
|
|
427
|
+
* })
|
|
428
|
+
* ```
|
|
429
|
+
*
|
|
430
|
+
* @example Object array with drawer editing and grid layout
|
|
431
|
+
* ```ts
|
|
432
|
+
* teamMembers: r.array({
|
|
433
|
+
* label: "Team Members",
|
|
434
|
+
* mode: "drawer", // Edit in side panel
|
|
435
|
+
* layout: "grid", // Fields in grid inside drawer
|
|
436
|
+
* columns: 2,
|
|
437
|
+
* itemLabel: (item) => item.name || "New Member",
|
|
438
|
+
* item: ({ r }) => ({
|
|
439
|
+
* name: r.text({ label: "Name" }),
|
|
440
|
+
* role: r.text({ label: "Role" }),
|
|
441
|
+
* email: r.text({ label: "Email" }),
|
|
442
|
+
* phone: r.text({ label: "Phone" }),
|
|
443
|
+
* bio: r.textarea({ label: "Bio" }),
|
|
444
|
+
* }),
|
|
445
|
+
* })
|
|
446
|
+
* ```
|
|
447
|
+
*
|
|
448
|
+
* @example Primitive array (simple tags)
|
|
449
|
+
* ```ts
|
|
450
|
+
* tags: r.array({
|
|
451
|
+
* label: "Tags",
|
|
452
|
+
* itemType: "text",
|
|
453
|
+
* orderable: true,
|
|
454
|
+
* maxItems: 10,
|
|
455
|
+
* })
|
|
456
|
+
* ```
|
|
457
|
+
*/
|
|
458
|
+
type ArrayFieldConfig = {
|
|
459
|
+
/**
|
|
460
|
+
* Item type for primitive arrays (without `item` callback).
|
|
461
|
+
* Each array element is a single value of this type.
|
|
462
|
+
*/
|
|
463
|
+
itemType?: ArrayItemType;
|
|
464
|
+
/** Options for select-type items */
|
|
465
|
+
options?: SelectOption[];
|
|
466
|
+
/**
|
|
467
|
+
* Item field definitions for object arrays.
|
|
468
|
+
* When provided, each array element is an object with these fields.
|
|
469
|
+
* Mutually exclusive with `itemType`.
|
|
470
|
+
*
|
|
471
|
+
* The `r` parameter type is automatically inferred from your field registry
|
|
472
|
+
* when using the builder. This provides full autocomplete for array item fields.
|
|
473
|
+
*/
|
|
474
|
+
item?: (ctx: {
|
|
475
|
+
r: any;
|
|
476
|
+
}) => NestedFieldsDefinition;
|
|
477
|
+
/**
|
|
478
|
+
* Display mode - controls WHERE fields are edited.
|
|
479
|
+
* Only applies to object arrays (when `item` is provided).
|
|
480
|
+
*
|
|
481
|
+
* @default "inline"
|
|
482
|
+
* @see ArrayFieldMode for detailed visual examples
|
|
483
|
+
*/
|
|
484
|
+
mode?: "inline" | "modal" | "drawer";
|
|
485
|
+
/**
|
|
486
|
+
* Layout for fields inside each item - controls HOW fields are arranged.
|
|
487
|
+
* Only applies to object arrays (when `item` is provided).
|
|
488
|
+
*
|
|
489
|
+
* @default "stack"
|
|
490
|
+
* @see ObjectFieldLayout for detailed visual examples
|
|
491
|
+
*/
|
|
492
|
+
layout?: ObjectFieldLayout;
|
|
493
|
+
/**
|
|
494
|
+
* Number of columns for grid layout.
|
|
495
|
+
* Only applies when `layout: "grid"`.
|
|
496
|
+
*
|
|
497
|
+
* @default 2
|
|
498
|
+
*/
|
|
499
|
+
columns?: number;
|
|
500
|
+
/**
|
|
501
|
+
* Label displayed in the item header.
|
|
502
|
+
* - String: Static label for all items
|
|
503
|
+
* - Function: Dynamic label based on item data (e.g., `(item) => item.name`)
|
|
504
|
+
*
|
|
505
|
+
* Falls back to checking `item.name`, `item.title`, `item.label`,
|
|
506
|
+
* then "Item {index}".
|
|
507
|
+
*/
|
|
508
|
+
itemLabel?: string | ((item: any, index: number) => string);
|
|
509
|
+
/** Enable drag-and-drop reordering */
|
|
510
|
+
orderable?: boolean;
|
|
511
|
+
/** Minimum number of items required */
|
|
512
|
+
minItems?: number;
|
|
513
|
+
/** Maximum number of items allowed */
|
|
514
|
+
maxItems?: number;
|
|
515
|
+
};
|
|
516
|
+
/**
|
|
517
|
+
* Rich text feature toggles
|
|
518
|
+
*/
|
|
519
|
+
type RichTextFeatures = {
|
|
520
|
+
toolbar?: boolean;
|
|
521
|
+
bubbleMenu?: boolean;
|
|
522
|
+
slashCommands?: boolean;
|
|
523
|
+
history?: boolean;
|
|
524
|
+
heading?: boolean;
|
|
525
|
+
bold?: boolean;
|
|
526
|
+
italic?: boolean;
|
|
527
|
+
underline?: boolean;
|
|
528
|
+
strike?: boolean;
|
|
529
|
+
code?: boolean;
|
|
530
|
+
codeBlock?: boolean;
|
|
531
|
+
blockquote?: boolean;
|
|
532
|
+
bulletList?: boolean;
|
|
533
|
+
orderedList?: boolean;
|
|
534
|
+
horizontalRule?: boolean;
|
|
535
|
+
align?: boolean;
|
|
536
|
+
link?: boolean;
|
|
537
|
+
image?: boolean;
|
|
538
|
+
table?: boolean;
|
|
539
|
+
tableControls?: boolean;
|
|
540
|
+
characterCount?: boolean;
|
|
541
|
+
};
|
|
542
|
+
/**
|
|
543
|
+
* Rich text field config
|
|
544
|
+
*
|
|
545
|
+
* @example
|
|
546
|
+
* ```ts
|
|
547
|
+
* content: r.richText({
|
|
548
|
+
* features: {
|
|
549
|
+
* image: true,
|
|
550
|
+
* table: true,
|
|
551
|
+
* },
|
|
552
|
+
* })
|
|
553
|
+
* ```
|
|
554
|
+
*/
|
|
555
|
+
type RichTextFieldConfig = {
|
|
556
|
+
/** Feature toggles */
|
|
557
|
+
features?: RichTextFeatures;
|
|
558
|
+
/** Show character count */
|
|
559
|
+
showCharacterCount?: boolean;
|
|
560
|
+
/** Max character limit */
|
|
561
|
+
maxCharacters?: number;
|
|
562
|
+
/** Enable image uploads */
|
|
563
|
+
enableImages?: boolean;
|
|
564
|
+
/** Target collection for image uploads */
|
|
565
|
+
imageCollection?: string;
|
|
566
|
+
/** Enable media library picker for images */
|
|
567
|
+
enableMediaLibrary?: boolean;
|
|
568
|
+
};
|
|
569
|
+
//#endregion
|
|
570
|
+
export { ArrayFieldConfig, ArrayItemType, BaseFieldProps, BooleanFieldConfig, DateFieldConfig, DateFieldProps, DateTimeFieldConfig, DateTimeFieldProps, NumberFieldConfig, NumberFieldProps, ObjectFieldConfig, ObjectFieldLayout, RelationFieldConfig, RichTextFieldConfig, SelectFieldConfig, SelectFieldProps, SelectOption, TextFieldConfig, TextFieldProps, TextareaFieldConfig, TextareaFieldProps, TimeFieldConfig, TimeFieldProps, UploadFieldConfig };
|
|
571
|
+
//# sourceMappingURL=field-types.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"field-types.d.mts","names":[],"sources":["../../../../src/client/components/fields/field-types.ts"],"sourcesContent":[],"mappings":";;;;;;;;;AA6BY,KARA,YAQc,CAAA,SAkBf,MAAA,CAAA,GA1BiC,cA0B1B,CA1BgD,MA0BhD,CAAA;AAkElB;AAUA;AAUA;;;AACW,KAzGC,cAAA,GAyGD;EAC6C;EAAb,IAAA,EAAA,MAAA;EAAR;EAAO,KAAA,CAAA,EAAA,MAAA;EAU9B;EAAiB,WAAA,CAAA,EAAA,MAAA;EAClB;EACA,WAAA,CAAA,EAAA,MAAA;EAAI;EAOH,QAAA,CAAA,EAAA,OAAA;EAOA;EA8CA,QAAA,CAAA,EAAA,OAAe;EAAQ;EAAsB,SAAA,CAAA,EAAA,OAAA;EAA3B;EAAI,MAAA,CAAA,EAAA,MAAA;EAGtB;EAAyB,OAAA,CAAA,EAnK1B,OAmK0B,CAAA,GAAA,CAAA;EAAwB;EAA7B,SAAA,CAAA,EAAA,MAAA;CAAI;AA2BpC;AAYA;AACA;AAGY,KAxJA,cAAA,GAAiB,cAoLlB,GAAA;EAuCC,IAAA,CAAA,EAAA,MAAA,GAAA,OAAiB,GAAA,UAAA,GAAA,KAAA,GAAA,KAAA,GAAA,QAAA;EAqCjB,SAAA,CAAA,EAAA,MAAA;EA8CA,SAAA,CAAA,EAAA,MAAA;EAqDA;EAkDA,OAAA,CAAA,EAAA,MAAA,GAhZQ,MAgZS;EASE,YAAA,CAAA,EAAA,MAAA;CAQpB;;;AAiCX;AA0MY,KAroBA,gBAAA,GAAmB,cAqoBH,GAAA;EAMhB,GAAA,CAAA,EAAA,MAAA;EAED,GAAA,CAAA,EAAA,MAAA;EAWkB,IAAA,CAAA,EAAA,MAAA;EAgBnB,WAAA,CAAA,EAAA,OAAA;CAAiB;AAkC3B;AAqCA;;KAruBY,kBAAA,GAAqB;;;;;;;;;KAUrB,oCAAoC;YACrC,aAAa;oCACW,QAAQ,aAAa;;;;;;;;;KAU5C,cAAA,GAAiB;YAClB;YACA;;;;;;KAOC,kBAAA,GAAqB;;;;;;KAOrB,cAAA,GAAiB;;;;KA8CjB,eAAA,GAAkB,KAAK,sBAAsB;;KAG7C,iBAAA,GAAoB,KAAK,wBAAwB;;KAGjD,mBAAA,GAAsB,KACjC,0BACM;;KAIK,qCAAqC,KAChD,iBAAiB,eACX;;KAIK,eAAA,GAAkB,KAAK,sBAAsB;;KAG7C,mBAAA,GAAsB,KACjC,0BACM;;KAIK,eAAA,GAAkB,KAAK,sBAAsB;;KAG7C,kBAAA;;;;;;;KAYA,mBAAA,GAAsB;KACtB,qBAAA,GAAwB;;KAGxB,mBAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;YA4BD;;;;;;;;WAQD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KA+BE,iBAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAqCA,sBAAA,GAAyB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KA8CzB,iBAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAqDA,kBAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAkDA,iBAAA;;;;;;;;;;;QASmB;;;;;;;;YAQpB;;;;;;;;WAQD;;;;;;;;;;;;;;;;;;;;KAyBE,aAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KA0MA,gBAAA;;;;;aAMA;;YAED;;;;;;;;;;;QAWkB;;;;;;;;;;;;;;;;WAgBnB;;;;;;;;;;;;;;;;;;;;;;;;;;;KAkCE,gBAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAqCA,mBAAA;;aAEA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import { Control } from "react-hook-form";
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import { useFormContext } from "react-hook-form";
|
|
2
|
+
|
|
3
|
+
//#region src/client/components/fields/field-utils.ts
|
|
4
|
+
function useResolvedControl(control) {
|
|
5
|
+
const form = useFormContext();
|
|
6
|
+
return control ?? form.control;
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* Sanitize filename for safe storage.
|
|
10
|
+
* Removes special characters, replaces spaces with hyphens.
|
|
11
|
+
*/
|
|
12
|
+
function sanitizeFilename(filename) {
|
|
13
|
+
const lastDot = filename.lastIndexOf(".");
|
|
14
|
+
const ext = lastDot > 0 ? filename.slice(lastDot) : "";
|
|
15
|
+
return ((lastDot > 0 ? filename.slice(0, lastDot) : filename).normalize("NFD").replace(/[\u0300-\u036f]/g, "").replace(/\s+/g, "-").replace(/[^a-zA-Z0-9._-]/g, "").replace(/-+/g, "-").replace(/^-|-$/g, "").toLowerCase() || "file") + ext.toLowerCase();
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* Extract columns from collection list config.
|
|
19
|
+
* Used by relation fields to auto-detect display columns.
|
|
20
|
+
*/
|
|
21
|
+
function getAutoColumns(collectionConfig) {
|
|
22
|
+
if (!collectionConfig?.list?.columns) return ["_title"];
|
|
23
|
+
const columns = collectionConfig.list.columns;
|
|
24
|
+
if (Array.isArray(columns)) return columns.map((col) => {
|
|
25
|
+
if (col && typeof col === "object" && col["~fieldName"]) return col["~fieldName"];
|
|
26
|
+
if (typeof col === "string") return col;
|
|
27
|
+
return null;
|
|
28
|
+
}).filter(Boolean).slice(0, 4);
|
|
29
|
+
return ["_title"];
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Grid column classes for responsive layouts.
|
|
33
|
+
* Uses standard responsive breakpoints (sm:, lg:, etc.)
|
|
34
|
+
*/
|
|
35
|
+
const gridColumnClasses = {
|
|
36
|
+
1: "grid-cols-1",
|
|
37
|
+
2: "grid-cols-1 sm:grid-cols-2",
|
|
38
|
+
3: "grid-cols-1 sm:grid-cols-2 lg:grid-cols-3",
|
|
39
|
+
4: "grid-cols-1 sm:grid-cols-2 md:grid-cols-3 xl:grid-cols-4"
|
|
40
|
+
};
|
|
41
|
+
/**
|
|
42
|
+
* Grid column classes using container queries.
|
|
43
|
+
* Parent must have @container class for these to work.
|
|
44
|
+
*/
|
|
45
|
+
const containerGridColumnClasses = {
|
|
46
|
+
1: "grid-cols-1",
|
|
47
|
+
2: "grid-cols-1 @sm:grid-cols-2",
|
|
48
|
+
3: "grid-cols-1 @sm:grid-cols-2 @lg:grid-cols-3",
|
|
49
|
+
4: "grid-cols-1 @sm:grid-cols-2 @md:grid-cols-3 @xl:grid-cols-4",
|
|
50
|
+
5: "grid-cols-1 @xs:grid-cols-2 @sm:grid-cols-3 @lg:grid-cols-4 @xl:grid-cols-5",
|
|
51
|
+
6: "grid-cols-1 @xs:grid-cols-2 @sm:grid-cols-3 @md:grid-cols-4 @lg:grid-cols-5 @xl:grid-cols-6"
|
|
52
|
+
};
|
|
53
|
+
/**
|
|
54
|
+
* Get grid columns class for a given column count.
|
|
55
|
+
* @param columns Number of columns
|
|
56
|
+
* @param useContainerQueries Use container query classes instead of viewport breakpoints
|
|
57
|
+
*/
|
|
58
|
+
function getGridColumnsClass(columns, useContainerQueries = false) {
|
|
59
|
+
if (!columns) return "";
|
|
60
|
+
return (useContainerQueries ? containerGridColumnClasses : gridColumnClasses)[columns] || "";
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
//#endregion
|
|
64
|
+
export { getAutoColumns, getGridColumnsClass, gridColumnClasses, sanitizeFilename, useResolvedControl };
|
|
65
|
+
//# sourceMappingURL=field-utils.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"field-utils.mjs","names":["gridColumnClasses: Record<number, string>","containerGridColumnClasses: Record<number, string>"],"sources":["../../../../src/client/components/fields/field-utils.ts"],"sourcesContent":["import { type Control, useFormContext } from \"react-hook-form\";\n\nexport function useResolvedControl(control?: Control<any>) {\n const form = useFormContext();\n return control ?? form.control;\n}\n\n/**\n * Sanitize filename for safe storage.\n * Removes special characters, replaces spaces with hyphens.\n */\nexport function sanitizeFilename(filename: string): string {\n // Get extension\n const lastDot = filename.lastIndexOf(\".\");\n const ext = lastDot > 0 ? filename.slice(lastDot) : \"\";\n const name = lastDot > 0 ? filename.slice(0, lastDot) : filename;\n\n // Normalize unicode, remove diacritics, replace spaces, remove invalid chars\n const sanitized = name\n .normalize(\"NFD\")\n .replace(/[\\u0300-\\u036f]/g, \"\") // Remove diacritics\n .replace(/\\s+/g, \"-\") // Replace spaces with hyphens\n .replace(/[^a-zA-Z0-9._-]/g, \"\") // Remove invalid chars\n .replace(/-+/g, \"-\") // Collapse multiple hyphens\n .replace(/^-|-$/g, \"\") // Remove leading/trailing hyphens\n .toLowerCase();\n\n return (sanitized || \"file\") + ext.toLowerCase();\n}\n\n/**\n * Extract columns from collection list config.\n * Used by relation fields to auto-detect display columns.\n */\nexport function getAutoColumns(collectionConfig: any): string[] {\n if (!collectionConfig?.list?.columns) return [\"_title\"];\n\n // List columns can be field references (f.fieldName) or strings\n const columns = collectionConfig.list.columns;\n if (Array.isArray(columns)) {\n return columns\n .map((col: any) => {\n // Handle field proxy objects\n if (col && typeof col === \"object\" && col[\"~fieldName\"]) {\n return col[\"~fieldName\"];\n }\n // Handle string field names\n if (typeof col === \"string\") {\n return col;\n }\n return null;\n })\n .filter(Boolean)\n .slice(0, 4); // Limit to 4 columns for relation display\n }\n\n return [\"_title\"];\n}\n\n/**\n * Grid column classes for responsive layouts.\n * Uses standard responsive breakpoints (sm:, lg:, etc.)\n */\nexport const gridColumnClasses: Record<number, string> = {\n 1: \"grid-cols-1\",\n 2: \"grid-cols-1 sm:grid-cols-2\",\n 3: \"grid-cols-1 sm:grid-cols-2 lg:grid-cols-3\",\n 4: \"grid-cols-1 sm:grid-cols-2 md:grid-cols-3 xl:grid-cols-4\",\n};\n\n/**\n * Grid column classes using container queries.\n * Parent must have @container class for these to work.\n */\nexport const containerGridColumnClasses: Record<number, string> = {\n 1: \"grid-cols-1\",\n 2: \"grid-cols-1 @sm:grid-cols-2\",\n 3: \"grid-cols-1 @sm:grid-cols-2 @lg:grid-cols-3\",\n 4: \"grid-cols-1 @sm:grid-cols-2 @md:grid-cols-3 @xl:grid-cols-4\",\n 5: \"grid-cols-1 @xs:grid-cols-2 @sm:grid-cols-3 @lg:grid-cols-4 @xl:grid-cols-5\",\n 6: \"grid-cols-1 @xs:grid-cols-2 @sm:grid-cols-3 @md:grid-cols-4 @lg:grid-cols-5 @xl:grid-cols-6\",\n};\n\n/**\n * Get grid columns class for a given column count.\n * @param columns Number of columns\n * @param useContainerQueries Use container query classes instead of viewport breakpoints\n */\nexport function getGridColumnsClass(\n columns?: number,\n useContainerQueries = false,\n): string {\n if (!columns) return \"\";\n const classes = useContainerQueries\n ? containerGridColumnClasses\n : gridColumnClasses;\n return classes[columns] || \"\";\n}\n"],"mappings":";;;AAEA,SAAgB,mBAAmB,SAAwB;CACzD,MAAM,OAAO,gBAAgB;AAC7B,QAAO,WAAW,KAAK;;;;;;AAOzB,SAAgB,iBAAiB,UAA0B;CAEzD,MAAM,UAAU,SAAS,YAAY,IAAI;CACzC,MAAM,MAAM,UAAU,IAAI,SAAS,MAAM,QAAQ,GAAG;AAapD,UAZa,UAAU,IAAI,SAAS,MAAM,GAAG,QAAQ,GAAG,UAIrD,UAAU,MAAM,CAChB,QAAQ,oBAAoB,GAAG,CAC/B,QAAQ,QAAQ,IAAI,CACpB,QAAQ,oBAAoB,GAAG,CAC/B,QAAQ,OAAO,IAAI,CACnB,QAAQ,UAAU,GAAG,CACrB,aAAa,IAEK,UAAU,IAAI,aAAa;;;;;;AAOlD,SAAgB,eAAe,kBAAiC;AAC9D,KAAI,CAAC,kBAAkB,MAAM,QAAS,QAAO,CAAC,SAAS;CAGvD,MAAM,UAAU,iBAAiB,KAAK;AACtC,KAAI,MAAM,QAAQ,QAAQ,CACxB,QAAO,QACJ,KAAK,QAAa;AAEjB,MAAI,OAAO,OAAO,QAAQ,YAAY,IAAI,cACxC,QAAO,IAAI;AAGb,MAAI,OAAO,QAAQ,SACjB,QAAO;AAET,SAAO;GACP,CACD,OAAO,QAAQ,CACf,MAAM,GAAG,EAAE;AAGhB,QAAO,CAAC,SAAS;;;;;;AAOnB,MAAaA,oBAA4C;CACvD,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACJ;;;;;AAMD,MAAaC,6BAAqD;CAChE,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACJ;;;;;;AAOD,SAAgB,oBACd,SACA,sBAAsB,OACd;AACR,KAAI,CAAC,QAAS,QAAO;AAIrB,SAHgB,sBACZ,6BACA,mBACW,YAAY"}
|