@nodehive/nextjs 0.1.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/LICENSE +21 -0
- package/README.md +102 -0
- package/dist/auth/index.d.ts +6 -0
- package/dist/auth/index.d.ts.map +1 -0
- package/dist/auth/index.js +7 -0
- package/dist/auth/index.js.map +1 -0
- package/dist/auth/internal/config.d.ts +24 -0
- package/dist/auth/internal/config.d.ts.map +1 -0
- package/dist/auth/internal/config.js +2 -0
- package/dist/auth/internal/config.js.map +1 -0
- package/dist/auth/internal/draft-mode.d.ts +17 -0
- package/dist/auth/internal/draft-mode.d.ts.map +1 -0
- package/dist/auth/internal/draft-mode.js +73 -0
- package/dist/auth/internal/draft-mode.js.map +1 -0
- package/dist/auth/internal/editor-locale.d.ts +4 -0
- package/dist/auth/internal/editor-locale.d.ts.map +1 -0
- package/dist/auth/internal/editor-locale.js +14 -0
- package/dist/auth/internal/editor-locale.js.map +1 -0
- package/dist/auth/internal/handoff.d.ts +11 -0
- package/dist/auth/internal/handoff.d.ts.map +1 -0
- package/dist/auth/internal/handoff.js +44 -0
- package/dist/auth/internal/handoff.js.map +1 -0
- package/dist/auth/internal/has-session.d.ts +7 -0
- package/dist/auth/internal/has-session.d.ts.map +1 -0
- package/dist/auth/internal/has-session.js +11 -0
- package/dist/auth/internal/has-session.js.map +1 -0
- package/dist/auth/internal/logout.d.ts +12 -0
- package/dist/auth/internal/logout.d.ts.map +1 -0
- package/dist/auth/internal/logout.js +48 -0
- package/dist/auth/internal/logout.js.map +1 -0
- package/dist/auth/internal/next-cookie-storage.d.ts +28 -0
- package/dist/auth/internal/next-cookie-storage.d.ts.map +1 -0
- package/dist/auth/internal/next-cookie-storage.js +103 -0
- package/dist/auth/internal/next-cookie-storage.js.map +1 -0
- package/dist/auth/internal/nodehive-client.d.ts +6 -0
- package/dist/auth/internal/nodehive-client.d.ts.map +1 -0
- package/dist/auth/internal/nodehive-client.js +64 -0
- package/dist/auth/internal/nodehive-client.js.map +1 -0
- package/dist/auth/internal/oauth-config.d.ts +37 -0
- package/dist/auth/internal/oauth-config.d.ts.map +1 -0
- package/dist/auth/internal/oauth-config.js +70 -0
- package/dist/auth/internal/oauth-config.js.map +1 -0
- package/dist/auth/internal/proxy-helpers.d.ts +15 -0
- package/dist/auth/internal/proxy-helpers.d.ts.map +1 -0
- package/dist/auth/internal/proxy-helpers.js +43 -0
- package/dist/auth/internal/proxy-helpers.js.map +1 -0
- package/dist/auth/internal/refresh.d.ts +13 -0
- package/dist/auth/internal/refresh.d.ts.map +1 -0
- package/dist/auth/internal/refresh.js +170 -0
- package/dist/auth/internal/refresh.js.map +1 -0
- package/dist/auth/internal/require-auth.d.ts +2 -0
- package/dist/auth/internal/require-auth.d.ts.map +1 -0
- package/dist/auth/internal/require-auth.js +11 -0
- package/dist/auth/internal/require-auth.js.map +1 -0
- package/dist/auth/internal/return-to.d.ts +16 -0
- package/dist/auth/internal/return-to.d.ts.map +1 -0
- package/dist/auth/internal/return-to.js +31 -0
- package/dist/auth/internal/return-to.js.map +1 -0
- package/dist/auth/internal/routes/callback.d.ts +11 -0
- package/dist/auth/internal/routes/callback.d.ts.map +1 -0
- package/dist/auth/internal/routes/callback.js +93 -0
- package/dist/auth/internal/routes/callback.js.map +1 -0
- package/dist/auth/internal/routes/chips-exchange.d.ts +4 -0
- package/dist/auth/internal/routes/chips-exchange.d.ts.map +1 -0
- package/dist/auth/internal/routes/chips-exchange.js +64 -0
- package/dist/auth/internal/routes/chips-exchange.js.map +1 -0
- package/dist/auth/internal/routes/draft.d.ts +4 -0
- package/dist/auth/internal/routes/draft.d.ts.map +1 -0
- package/dist/auth/internal/routes/draft.js +34 -0
- package/dist/auth/internal/routes/draft.js.map +1 -0
- package/dist/auth/internal/routes/index.d.ts +25 -0
- package/dist/auth/internal/routes/index.d.ts.map +1 -0
- package/dist/auth/internal/routes/index.js +66 -0
- package/dist/auth/internal/routes/index.js.map +1 -0
- package/dist/auth/internal/routes/login.d.ts +3 -0
- package/dist/auth/internal/routes/login.d.ts.map +1 -0
- package/dist/auth/internal/routes/login.js +47 -0
- package/dist/auth/internal/routes/login.js.map +1 -0
- package/dist/auth/internal/routes/popup-done.d.ts +3 -0
- package/dist/auth/internal/routes/popup-done.d.ts.map +1 -0
- package/dist/auth/internal/routes/popup-done.js +24 -0
- package/dist/auth/internal/routes/popup-done.js.map +1 -0
- package/dist/auth/internal/routes/refresh.d.ts +6 -0
- package/dist/auth/internal/routes/refresh.d.ts.map +1 -0
- package/dist/auth/internal/routes/refresh.js +44 -0
- package/dist/auth/internal/routes/refresh.js.map +1 -0
- package/dist/auth/internal/same-origin.d.ts +8 -0
- package/dist/auth/internal/same-origin.d.ts.map +1 -0
- package/dist/auth/internal/same-origin.js +9 -0
- package/dist/auth/internal/same-origin.js.map +1 -0
- package/dist/auth/internal/session-gates.d.ts +7 -0
- package/dist/auth/internal/session-gates.d.ts.map +1 -0
- package/dist/auth/internal/session-gates.js +12 -0
- package/dist/auth/internal/session-gates.js.map +1 -0
- package/dist/auth/internal/update-session.d.ts +17 -0
- package/dist/auth/internal/update-session.d.ts.map +1 -0
- package/dist/auth/internal/update-session.js +39 -0
- package/dist/auth/internal/update-session.js.map +1 -0
- package/dist/auth/internal/use-editor-login.d.ts +33 -0
- package/dist/auth/internal/use-editor-login.d.ts.map +1 -0
- package/dist/auth/internal/use-editor-login.js +143 -0
- package/dist/auth/internal/use-editor-login.js.map +1 -0
- package/dist/auth/proxy.d.ts +8 -0
- package/dist/auth/proxy.d.ts.map +1 -0
- package/dist/auth/proxy.js +8 -0
- package/dist/auth/proxy.js.map +1 -0
- package/dist/auth/react.d.ts +2 -0
- package/dist/auth/react.d.ts.map +1 -0
- package/dist/auth/react.js +3 -0
- package/dist/auth/react.js.map +1 -0
- package/dist/auth/routes.d.ts +3 -0
- package/dist/auth/routes.d.ts.map +1 -0
- package/dist/auth/routes.js +3 -0
- package/dist/auth/routes.js.map +1 -0
- package/dist/auth/server.d.ts +23 -0
- package/dist/auth/server.d.ts.map +1 -0
- package/dist/auth/server.js +61 -0
- package/dist/auth/server.js.map +1 -0
- package/dist/puck-editor/fields.d.ts +7 -0
- package/dist/puck-editor/fields.d.ts.map +1 -0
- package/dist/puck-editor/fields.js +4 -0
- package/dist/puck-editor/fields.js.map +1 -0
- package/dist/puck-editor/index.d.ts +14 -0
- package/dist/puck-editor/index.d.ts.map +1 -0
- package/dist/puck-editor/index.js +12 -0
- package/dist/puck-editor/index.js.map +1 -0
- package/dist/puck-editor/internal/api/client.d.ts +32 -0
- package/dist/puck-editor/internal/api/client.d.ts.map +1 -0
- package/dist/puck-editor/internal/api/client.js +128 -0
- package/dist/puck-editor/internal/api/client.js.map +1 -0
- package/dist/puck-editor/internal/api/config.d.ts +29 -0
- package/dist/puck-editor/internal/api/config.d.ts.map +1 -0
- package/dist/puck-editor/internal/api/config.js +2 -0
- package/dist/puck-editor/internal/api/config.js.map +1 -0
- package/dist/puck-editor/internal/api/create-puck-api.d.ts +26 -0
- package/dist/puck-editor/internal/api/create-puck-api.d.ts.map +1 -0
- package/dist/puck-editor/internal/api/create-puck-api.js +124 -0
- package/dist/puck-editor/internal/api/create-puck-api.js.map +1 -0
- package/dist/puck-editor/internal/api/handlers/create-page.d.ts +13 -0
- package/dist/puck-editor/internal/api/handlers/create-page.d.ts.map +1 -0
- package/dist/puck-editor/internal/api/handlers/create-page.js +125 -0
- package/dist/puck-editor/internal/api/handlers/create-page.js.map +1 -0
- package/dist/puck-editor/internal/api/handlers/entities.d.ts +17 -0
- package/dist/puck-editor/internal/api/handlers/entities.d.ts.map +1 -0
- package/dist/puck-editor/internal/api/handlers/entities.js +166 -0
- package/dist/puck-editor/internal/api/handlers/entities.js.map +1 -0
- package/dist/puck-editor/internal/api/handlers/publish.d.ts +6 -0
- package/dist/puck-editor/internal/api/handlers/publish.d.ts.map +1 -0
- package/dist/puck-editor/internal/api/handlers/publish.js +115 -0
- package/dist/puck-editor/internal/api/handlers/publish.js.map +1 -0
- package/dist/puck-editor/internal/api/handlers/template.d.ts +15 -0
- package/dist/puck-editor/internal/api/handlers/template.d.ts.map +1 -0
- package/dist/puck-editor/internal/api/handlers/template.js +222 -0
- package/dist/puck-editor/internal/api/handlers/template.js.map +1 -0
- package/dist/puck-editor/internal/api/handlers/upload.d.ts +13 -0
- package/dist/puck-editor/internal/api/handlers/upload.d.ts.map +1 -0
- package/dist/puck-editor/internal/api/handlers/upload.js +129 -0
- package/dist/puck-editor/internal/api/handlers/upload.js.map +1 -0
- package/dist/puck-editor/internal/api/media-params.d.ts +4 -0
- package/dist/puck-editor/internal/api/media-params.d.ts.map +1 -0
- package/dist/puck-editor/internal/api/media-params.js +38 -0
- package/dist/puck-editor/internal/api/media-params.js.map +1 -0
- package/dist/puck-editor/internal/api/media-upload.d.ts +24 -0
- package/dist/puck-editor/internal/api/media-upload.d.ts.map +1 -0
- package/dist/puck-editor/internal/api/media-upload.js +171 -0
- package/dist/puck-editor/internal/api/media-upload.js.map +1 -0
- package/dist/puck-editor/internal/api/space.d.ts +4 -0
- package/dist/puck-editor/internal/api/space.d.ts.map +1 -0
- package/dist/puck-editor/internal/api/space.js +11 -0
- package/dist/puck-editor/internal/api/space.js.map +1 -0
- package/dist/puck-editor/internal/content-model.d.ts +55 -0
- package/dist/puck-editor/internal/content-model.d.ts.map +1 -0
- package/dist/puck-editor/internal/content-model.js +73 -0
- package/dist/puck-editor/internal/content-model.js.map +1 -0
- package/dist/puck-editor/internal/editor/allowed-types.d.ts +4 -0
- package/dist/puck-editor/internal/editor/allowed-types.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor/allowed-types.js +6 -0
- package/dist/puck-editor/internal/editor/allowed-types.js.map +1 -0
- package/dist/puck-editor/internal/editor/canvas-add-picker.d.ts +9 -0
- package/dist/puck-editor/internal/editor/canvas-add-picker.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor/canvas-add-picker.js +231 -0
- package/dist/puck-editor/internal/editor/canvas-add-picker.js.map +1 -0
- package/dist/puck-editor/internal/editor/canvas-empty-state.d.ts +6 -0
- package/dist/puck-editor/internal/editor/canvas-empty-state.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor/canvas-empty-state.js +85 -0
- package/dist/puck-editor/internal/editor/canvas-empty-state.js.map +1 -0
- package/dist/puck-editor/internal/editor/canvas-quick-add.d.ts +2 -0
- package/dist/puck-editor/internal/editor/canvas-quick-add.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor/canvas-quick-add.js +844 -0
- package/dist/puck-editor/internal/editor/canvas-quick-add.js.map +1 -0
- package/dist/puck-editor/internal/editor/canvas-scroll.d.ts +3 -0
- package/dist/puck-editor/internal/editor/canvas-scroll.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor/canvas-scroll.js +16 -0
- package/dist/puck-editor/internal/editor/canvas-scroll.js.map +1 -0
- package/dist/puck-editor/internal/editor/component-icons.d.ts +14 -0
- package/dist/puck-editor/internal/editor/component-icons.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor/component-icons.js +35 -0
- package/dist/puck-editor/internal/editor/component-icons.js.map +1 -0
- package/dist/puck-editor/internal/editor/component-item.d.ts +6 -0
- package/dist/puck-editor/internal/editor/component-item.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor/component-item.js +42 -0
- package/dist/puck-editor/internal/editor/component-item.js.map +1 -0
- package/dist/puck-editor/internal/editor/editor-action-bar.d.ts +6 -0
- package/dist/puck-editor/internal/editor/editor-action-bar.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor/editor-action-bar.js +249 -0
- package/dist/puck-editor/internal/editor/editor-action-bar.js.map +1 -0
- package/dist/puck-editor/internal/editor/editor-header-actions.d.ts +7 -0
- package/dist/puck-editor/internal/editor/editor-header-actions.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor/editor-header-actions.js +120 -0
- package/dist/puck-editor/internal/editor/editor-header-actions.js.map +1 -0
- package/dist/puck-editor/internal/editor/find-missing-required-fields.d.ts +15 -0
- package/dist/puck-editor/internal/editor/find-missing-required-fields.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor/find-missing-required-fields.js +61 -0
- package/dist/puck-editor/internal/editor/find-missing-required-fields.js.map +1 -0
- package/dist/puck-editor/internal/editor/grouped-drawer-panel.d.ts +15 -0
- package/dist/puck-editor/internal/editor/grouped-drawer-panel.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor/grouped-drawer-panel.js +147 -0
- package/dist/puck-editor/internal/editor/grouped-drawer-panel.js.map +1 -0
- package/dist/puck-editor/internal/editor/grouped-entry-list.d.ts +17 -0
- package/dist/puck-editor/internal/editor/grouped-entry-list.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor/grouped-entry-list.js +125 -0
- package/dist/puck-editor/internal/editor/grouped-entry-list.js.map +1 -0
- package/dist/puck-editor/internal/editor/header-save-button.d.ts +5 -0
- package/dist/puck-editor/internal/editor/header-save-button.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor/header-save-button.js +60 -0
- package/dist/puck-editor/internal/editor/header-save-button.js.map +1 -0
- package/dist/puck-editor/internal/editor/page-template-picker.d.ts +4 -0
- package/dist/puck-editor/internal/editor/page-template-picker.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor/page-template-picker.js +140 -0
- package/dist/puck-editor/internal/editor/page-template-picker.js.map +1 -0
- package/dist/puck-editor/internal/editor/picker-entry-item.d.ts +6 -0
- package/dist/puck-editor/internal/editor/picker-entry-item.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor/picker-entry-item.js +79 -0
- package/dist/puck-editor/internal/editor/picker-entry-item.js.map +1 -0
- package/dist/puck-editor/internal/editor/picker-model.d.ts +62 -0
- package/dist/puck-editor/internal/editor/picker-model.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor/picker-model.js +489 -0
- package/dist/puck-editor/internal/editor/picker-model.js.map +1 -0
- package/dist/puck-editor/internal/editor/publish-puck-data.d.ts +30 -0
- package/dist/puck-editor/internal/editor/publish-puck-data.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor/publish-puck-data.js +30 -0
- package/dist/puck-editor/internal/editor/publish-puck-data.js.map +1 -0
- package/dist/puck-editor/internal/editor/puck-editor.d.ts +15 -0
- package/dist/puck-editor/internal/editor/puck-editor.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor/puck-editor.js +333 -0
- package/dist/puck-editor/internal/editor/puck-editor.js.map +1 -0
- package/dist/puck-editor/internal/editor/section-template-modal.d.ts +4 -0
- package/dist/puck-editor/internal/editor/section-template-modal.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor/section-template-modal.js +71 -0
- package/dist/puck-editor/internal/editor/section-template-modal.js.map +1 -0
- package/dist/puck-editor/internal/editor/use-scroll-lock-outside.d.ts +15 -0
- package/dist/puck-editor/internal/editor/use-scroll-lock-outside.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor/use-scroll-lock-outside.js +93 -0
- package/dist/puck-editor/internal/editor/use-scroll-lock-outside.js.map +1 -0
- package/dist/puck-editor/internal/editor-config.d.ts +30 -0
- package/dist/puck-editor/internal/editor-config.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor-config.js +57 -0
- package/dist/puck-editor/internal/editor-config.js.map +1 -0
- package/dist/puck-editor/internal/editor-query-client.d.ts +4 -0
- package/dist/puck-editor/internal/editor-query-client.d.ts.map +1 -0
- package/dist/puck-editor/internal/editor-query-client.js +8 -0
- package/dist/puck-editor/internal/editor-query-client.js.map +1 -0
- package/dist/puck-editor/internal/fields/checkbox-group/checkbox-group-field.d.ts +14 -0
- package/dist/puck-editor/internal/fields/checkbox-group/checkbox-group-field.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/checkbox-group/checkbox-group-field.js +120 -0
- package/dist/puck-editor/internal/fields/checkbox-group/checkbox-group-field.js.map +1 -0
- package/dist/puck-editor/internal/fields/checkbox-group/create-checkbox-group-field.d.ts +21 -0
- package/dist/puck-editor/internal/fields/checkbox-group/create-checkbox-group-field.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/checkbox-group/create-checkbox-group-field.js +24 -0
- package/dist/puck-editor/internal/fields/checkbox-group/create-checkbox-group-field.js.map +1 -0
- package/dist/puck-editor/internal/fields/date-picker/create-date-picker-field.d.ts +16 -0
- package/dist/puck-editor/internal/fields/date-picker/create-date-picker-field.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/date-picker/create-date-picker-field.js +20 -0
- package/dist/puck-editor/internal/fields/date-picker/create-date-picker-field.js.map +1 -0
- package/dist/puck-editor/internal/fields/date-picker/date-picker.d.ts +8 -0
- package/dist/puck-editor/internal/fields/date-picker/date-picker.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/date-picker/date-picker.js +151 -0
- package/dist/puck-editor/internal/fields/date-picker/date-picker.js.map +1 -0
- package/dist/puck-editor/internal/fields/index.d.ts +10 -0
- package/dist/puck-editor/internal/fields/index.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/index.js +10 -0
- package/dist/puck-editor/internal/fields/index.js.map +1 -0
- package/dist/puck-editor/internal/fields/link-picker/anchor.d.ts +33 -0
- package/dist/puck-editor/internal/fields/link-picker/anchor.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/link-picker/anchor.js +83 -0
- package/dist/puck-editor/internal/fields/link-picker/anchor.js.map +1 -0
- package/dist/puck-editor/internal/fields/link-picker/create-link-field.d.ts +24 -0
- package/dist/puck-editor/internal/fields/link-picker/create-link-field.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/link-picker/create-link-field.js +31 -0
- package/dist/puck-editor/internal/fields/link-picker/create-link-field.js.map +1 -0
- package/dist/puck-editor/internal/fields/link-picker/humanize.d.ts +2 -0
- package/dist/puck-editor/internal/fields/link-picker/humanize.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/link-picker/humanize.js +4 -0
- package/dist/puck-editor/internal/fields/link-picker/humanize.js.map +1 -0
- package/dist/puck-editor/internal/fields/link-picker/link-picker-control.d.ts +27 -0
- package/dist/puck-editor/internal/fields/link-picker/link-picker-control.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/link-picker/link-picker-control.js +564 -0
- package/dist/puck-editor/internal/fields/link-picker/link-picker-control.js.map +1 -0
- package/dist/puck-editor/internal/fields/link-picker/link-picker-field.d.ts +9 -0
- package/dist/puck-editor/internal/fields/link-picker/link-picker-field.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/link-picker/link-picker-field.js +189 -0
- package/dist/puck-editor/internal/fields/link-picker/link-picker-field.js.map +1 -0
- package/dist/puck-editor/internal/fields/link-picker/link-value.d.ts +72 -0
- package/dist/puck-editor/internal/fields/link-picker/link-value.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/link-picker/link-value.js +114 -0
- package/dist/puck-editor/internal/fields/link-picker/link-value.js.map +1 -0
- package/dist/puck-editor/internal/fields/link-picker/rich-text-link-button.d.ts +14 -0
- package/dist/puck-editor/internal/fields/link-picker/rich-text-link-button.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/link-picker/rich-text-link-button.js +667 -0
- package/dist/puck-editor/internal/fields/link-picker/rich-text-link-button.js.map +1 -0
- package/dist/puck-editor/internal/fields/link-picker/richtext-extensions.d.ts +11 -0
- package/dist/puck-editor/internal/fields/link-picker/richtext-extensions.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/link-picker/richtext-extensions.js +34 -0
- package/dist/puck-editor/internal/fields/link-picker/richtext-extensions.js.map +1 -0
- package/dist/puck-editor/internal/fields/link-picker/segmented-control.d.ts +40 -0
- package/dist/puck-editor/internal/fields/link-picker/segmented-control.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/link-picker/segmented-control.js +146 -0
- package/dist/puck-editor/internal/fields/link-picker/segmented-control.js.map +1 -0
- package/dist/puck-editor/internal/fields/link-picker/types.d.ts +34 -0
- package/dist/puck-editor/internal/fields/link-picker/types.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/link-picker/types.js +2 -0
- package/dist/puck-editor/internal/fields/link-picker/types.js.map +1 -0
- package/dist/puck-editor/internal/fields/media-array/create-media-array-field.d.ts +27 -0
- package/dist/puck-editor/internal/fields/media-array/create-media-array-field.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/media-array/create-media-array-field.js +32 -0
- package/dist/puck-editor/internal/fields/media-array/create-media-array-field.js.map +1 -0
- package/dist/puck-editor/internal/fields/media-array/media-array-field.d.ts +13 -0
- package/dist/puck-editor/internal/fields/media-array/media-array-field.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/media-array/media-array-field.js +372 -0
- package/dist/puck-editor/internal/fields/media-array/media-array-field.js.map +1 -0
- package/dist/puck-editor/internal/fields/media-array/reorder.d.ts +2 -0
- package/dist/puck-editor/internal/fields/media-array/reorder.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/media-array/reorder.js +8 -0
- package/dist/puck-editor/internal/fields/media-array/reorder.js.map +1 -0
- package/dist/puck-editor/internal/fields/media-selector/create-media-selector-field.d.ts +27 -0
- package/dist/puck-editor/internal/fields/media-selector/create-media-selector-field.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/media-selector/create-media-selector-field.js +32 -0
- package/dist/puck-editor/internal/fields/media-selector/create-media-selector-field.js.map +1 -0
- package/dist/puck-editor/internal/fields/media-selector/crop-editor-dialog.d.ts +11 -0
- package/dist/puck-editor/internal/fields/media-selector/crop-editor-dialog.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/media-selector/crop-editor-dialog.js +219 -0
- package/dist/puck-editor/internal/fields/media-selector/crop-editor-dialog.js.map +1 -0
- package/dist/puck-editor/internal/fields/media-selector/crop-types.d.ts +24 -0
- package/dist/puck-editor/internal/fields/media-selector/crop-types.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/media-selector/crop-types.js +8 -0
- package/dist/puck-editor/internal/fields/media-selector/crop-types.js.map +1 -0
- package/dist/puck-editor/internal/fields/media-selector/extract-fields.d.ts +8 -0
- package/dist/puck-editor/internal/fields/media-selector/extract-fields.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/media-selector/extract-fields.js +51 -0
- package/dist/puck-editor/internal/fields/media-selector/extract-fields.js.map +1 -0
- package/dist/puck-editor/internal/fields/media-selector/image-upload-form.d.ts +7 -0
- package/dist/puck-editor/internal/fields/media-selector/image-upload-form.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/media-selector/image-upload-form.js +147 -0
- package/dist/puck-editor/internal/fields/media-selector/image-upload-form.js.map +1 -0
- package/dist/puck-editor/internal/fields/media-selector/media-selector-field.d.ts +30 -0
- package/dist/puck-editor/internal/fields/media-selector/media-selector-field.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/media-selector/media-selector-field.js +358 -0
- package/dist/puck-editor/internal/fields/media-selector/media-selector-field.js.map +1 -0
- package/dist/puck-editor/internal/fields/media-selector/media-selector-modal.d.ts +14 -0
- package/dist/puck-editor/internal/fields/media-selector/media-selector-modal.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/media-selector/media-selector-modal.js +355 -0
- package/dist/puck-editor/internal/fields/media-selector/media-selector-modal.js.map +1 -0
- package/dist/puck-editor/internal/fields/media-selector/use-debounced-value.d.ts +2 -0
- package/dist/puck-editor/internal/fields/media-selector/use-debounced-value.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/media-selector/use-debounced-value.js +55 -0
- package/dist/puck-editor/internal/fields/media-selector/use-debounced-value.js.map +1 -0
- package/dist/puck-editor/internal/fields/media-selector/use-media-library.d.ts +24 -0
- package/dist/puck-editor/internal/fields/media-selector/use-media-library.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/media-selector/use-media-library.js +229 -0
- package/dist/puck-editor/internal/fields/media-selector/use-media-library.js.map +1 -0
- package/dist/puck-editor/internal/fields/media-selector/video-upload-form.d.ts +7 -0
- package/dist/puck-editor/internal/fields/media-selector/video-upload-form.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/media-selector/video-upload-form.js +120 -0
- package/dist/puck-editor/internal/fields/media-selector/video-upload-form.js.map +1 -0
- package/dist/puck-editor/internal/fields/node-selector/create-node-selector-field.d.ts +31 -0
- package/dist/puck-editor/internal/fields/node-selector/create-node-selector-field.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/node-selector/create-node-selector-field.js +39 -0
- package/dist/puck-editor/internal/fields/node-selector/create-node-selector-field.js.map +1 -0
- package/dist/puck-editor/internal/fields/required-field-label.d.ts +16 -0
- package/dist/puck-editor/internal/fields/required-field-label.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/required-field-label.js +89 -0
- package/dist/puck-editor/internal/fields/required-field-label.js.map +1 -0
- package/dist/puck-editor/internal/fields/required.d.ts +19 -0
- package/dist/puck-editor/internal/fields/required.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/required.js +20 -0
- package/dist/puck-editor/internal/fields/required.js.map +1 -0
- package/dist/puck-editor/internal/fields/rich-text/create-rich-text-field.d.ts +37 -0
- package/dist/puck-editor/internal/fields/rich-text/create-rich-text-field.d.ts.map +1 -0
- package/dist/puck-editor/internal/fields/rich-text/create-rich-text-field.js +26 -0
- package/dist/puck-editor/internal/fields/rich-text/create-rich-text-field.js.map +1 -0
- package/dist/puck-editor/internal/i18n.d.ts +188 -0
- package/dist/puck-editor/internal/i18n.d.ts.map +1 -0
- package/dist/puck-editor/internal/i18n.js +414 -0
- package/dist/puck-editor/internal/i18n.js.map +1 -0
- package/dist/puck-editor/internal/locale.d.ts +13 -0
- package/dist/puck-editor/internal/locale.d.ts.map +1 -0
- package/dist/puck-editor/internal/locale.js +20 -0
- package/dist/puck-editor/internal/locale.js.map +1 -0
- package/dist/puck-editor/internal/localize.d.ts +11 -0
- package/dist/puck-editor/internal/localize.d.ts.map +1 -0
- package/dist/puck-editor/internal/localize.js +42 -0
- package/dist/puck-editor/internal/localize.js.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/agent-bridge.d.ts +21 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/agent-bridge.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/agent-bridge.js +197 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/agent-bridge.js.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/agent-info-panel.d.ts +2 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/agent-info-panel.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/agent-info-panel.js +131 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/agent-info-panel.js.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/agent-plugin.d.ts +20 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/agent-plugin.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/agent-plugin.js +46 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/agent-plugin.js.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/apply-patch-to-puck.d.ts +46 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/apply-patch-to-puck.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/apply-patch-to-puck.js +176 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/apply-patch-to-puck.js.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/catalog.d.ts +20 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/catalog.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/catalog.js +39 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/catalog.js.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/constants.d.ts +5 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/constants.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/constants.js +3 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/constants.js.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/create-page.d.ts +17 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/create-page.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/create-page.js +35 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/create-page.js.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/find-component-location.d.ts +19 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/find-component-location.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/find-component-location.js +79 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/find-component-location.js.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/help.d.ts +2 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/help.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/help.js +243 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/help.js.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/index.d.ts +2 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/index.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/index.js +2 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/index.js.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/list-media.d.ts +19 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/list-media.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/list-media.js +31 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/list-media.js.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/templates.d.ts +23 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/templates.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/templates.js +72 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/templates.js.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/upload-media.d.ts +20 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/upload-media.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/upload-media.js +34 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/upload-media.js.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/use-agent-handle.d.ts +17 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/use-agent-handle.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/use-agent-handle.js +70 -0
- package/dist/puck-editor/internal/plugins/agent-plugin/use-agent-handle.js.map +1 -0
- package/dist/puck-editor/internal/plugins/blocks-plugin/blocks-panel.d.ts +2 -0
- package/dist/puck-editor/internal/plugins/blocks-plugin/blocks-panel.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/blocks-plugin/blocks-panel.js +37 -0
- package/dist/puck-editor/internal/plugins/blocks-plugin/blocks-panel.js.map +1 -0
- package/dist/puck-editor/internal/plugins/blocks-plugin/blocks-plugin.d.ts +7 -0
- package/dist/puck-editor/internal/plugins/blocks-plugin/blocks-plugin.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/blocks-plugin/blocks-plugin.js +18 -0
- package/dist/puck-editor/internal/plugins/blocks-plugin/blocks-plugin.js.map +1 -0
- package/dist/puck-editor/internal/plugins/blocks-plugin/index.d.ts +2 -0
- package/dist/puck-editor/internal/plugins/blocks-plugin/index.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/blocks-plugin/index.js +2 -0
- package/dist/puck-editor/internal/plugins/blocks-plugin/index.js.map +1 -0
- package/dist/puck-editor/internal/plugins/outline-plugin/index.d.ts +2 -0
- package/dist/puck-editor/internal/plugins/outline-plugin/index.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/outline-plugin/index.js +2 -0
- package/dist/puck-editor/internal/plugins/outline-plugin/index.js.map +1 -0
- package/dist/puck-editor/internal/plugins/outline-plugin/outline-panel.d.ts +2 -0
- package/dist/puck-editor/internal/plugins/outline-plugin/outline-panel.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/outline-plugin/outline-panel.js +861 -0
- package/dist/puck-editor/internal/plugins/outline-plugin/outline-panel.js.map +1 -0
- package/dist/puck-editor/internal/plugins/outline-plugin/outline-plugin.d.ts +5 -0
- package/dist/puck-editor/internal/plugins/outline-plugin/outline-plugin.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/outline-plugin/outline-plugin.js +16 -0
- package/dist/puck-editor/internal/plugins/outline-plugin/outline-plugin.js.map +1 -0
- package/dist/puck-editor/internal/plugins/outline-plugin/outline-tree.d.ts +53 -0
- package/dist/puck-editor/internal/plugins/outline-plugin/outline-tree.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/outline-plugin/outline-tree.js +145 -0
- package/dist/puck-editor/internal/plugins/outline-plugin/outline-tree.js.map +1 -0
- package/dist/puck-editor/internal/plugins/sections-plugin/index.d.ts +2 -0
- package/dist/puck-editor/internal/plugins/sections-plugin/index.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/sections-plugin/index.js +2 -0
- package/dist/puck-editor/internal/plugins/sections-plugin/index.js.map +1 -0
- package/dist/puck-editor/internal/plugins/sections-plugin/sections-panel.d.ts +2 -0
- package/dist/puck-editor/internal/plugins/sections-plugin/sections-panel.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/sections-plugin/sections-panel.js +69 -0
- package/dist/puck-editor/internal/plugins/sections-plugin/sections-panel.js.map +1 -0
- package/dist/puck-editor/internal/plugins/sections-plugin/sections-plugin.d.ts +7 -0
- package/dist/puck-editor/internal/plugins/sections-plugin/sections-plugin.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/sections-plugin/sections-plugin.js +18 -0
- package/dist/puck-editor/internal/plugins/sections-plugin/sections-plugin.js.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/ai-options-fields.d.ts +6 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/ai-options-fields.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/ai-options-fields.js +178 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/ai-options-fields.js.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/apply-vehicle-slot-constraints.d.ts +3 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/apply-vehicle-slot-constraints.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/apply-vehicle-slot-constraints.js +55 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/apply-vehicle-slot-constraints.js.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/component-template-modal.d.ts +12 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/component-template-modal.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/component-template-modal.js +125 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/component-template-modal.js.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/custom-template-list.d.ts +8 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/custom-template-list.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/custom-template-list.js +582 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/custom-template-list.js.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/index.d.ts +6 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/index.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/index.js +6 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/index.js.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/root-drop-zone.d.ts +4 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/root-drop-zone.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/root-drop-zone.js +54 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/root-drop-zone.js.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/template-form.d.ts +11 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/template-form.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/template-form.js +92 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/template-form.js.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/template-vehicles.d.ts +7 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/template-vehicles.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/template-vehicles.js +30 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/template-vehicles.js.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/templates-panel.d.ts +2 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/templates-panel.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/templates-panel.js +471 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/templates-panel.js.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/templates-plugin.d.ts +5 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/templates-plugin.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/templates-plugin.js +16 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/templates-plugin.js.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/templates.d.ts +43 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/templates.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/templates.js +115 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/templates.js.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/use-template-dnd.d.ts +9 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/use-template-dnd.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/use-template-dnd.js +152 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/use-template-dnd.js.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/use-templates.d.ts +16 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/use-templates.d.ts.map +1 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/use-templates.js +134 -0
- package/dist/puck-editor/internal/plugins/templates-plugin/use-templates.js.map +1 -0
- package/dist/puck-editor/internal/puck-augmentation.d.ts +28 -0
- package/dist/puck-editor/internal/puck-augmentation.d.ts.map +1 -0
- package/dist/puck-editor/internal/puck-augmentation.js +7 -0
- package/dist/puck-editor/internal/puck-augmentation.js.map +1 -0
- package/dist/puck-editor/internal/puck-editor-provider.d.ts +12 -0
- package/dist/puck-editor/internal/puck-editor-provider.d.ts.map +1 -0
- package/dist/puck-editor/internal/puck-editor-provider.js +69 -0
- package/dist/puck-editor/internal/puck-editor-provider.js.map +1 -0
- package/dist/puck-editor/internal/puck-node.d.ts +29 -0
- package/dist/puck-editor/internal/puck-node.d.ts.map +1 -0
- package/dist/puck-editor/internal/puck-node.js +2 -0
- package/dist/puck-editor/internal/puck-node.js.map +1 -0
- package/dist/puck-editor/internal/puck-wrapper.d.ts +19 -0
- package/dist/puck-editor/internal/puck-wrapper.d.ts.map +1 -0
- package/dist/puck-editor/internal/puck-wrapper.js +270 -0
- package/dist/puck-editor/internal/puck-wrapper.js.map +1 -0
- package/dist/puck-editor/internal/render/cropped-image.d.ts +19 -0
- package/dist/puck-editor/internal/render/cropped-image.d.ts.map +1 -0
- package/dist/puck-editor/internal/render/cropped-image.js +126 -0
- package/dist/puck-editor/internal/render/cropped-image.js.map +1 -0
- package/dist/puck-editor/internal/smart-actions/index.d.ts +13 -0
- package/dist/puck-editor/internal/smart-actions/index.d.ts.map +1 -0
- package/dist/puck-editor/internal/smart-actions/index.js +29 -0
- package/dist/puck-editor/internal/smart-actions/index.js.map +1 -0
- package/dist/puck-editor/internal/smart-actions/new-page.d.ts +13 -0
- package/dist/puck-editor/internal/smart-actions/new-page.d.ts.map +1 -0
- package/dist/puck-editor/internal/smart-actions/new-page.js +80 -0
- package/dist/puck-editor/internal/smart-actions/new-page.js.map +1 -0
- package/dist/puck-editor/internal/smart-actions/open-puck-editor.d.ts +2 -0
- package/dist/puck-editor/internal/smart-actions/open-puck-editor.d.ts.map +1 -0
- package/dist/puck-editor/internal/smart-actions/open-puck-editor.js +65 -0
- package/dist/puck-editor/internal/smart-actions/open-puck-editor.js.map +1 -0
- package/dist/puck-editor/internal/ui/calendar.d.ts +9 -0
- package/dist/puck-editor/internal/ui/calendar.d.ts.map +1 -0
- package/dist/puck-editor/internal/ui/calendar.js +147 -0
- package/dist/puck-editor/internal/ui/calendar.js.map +1 -0
- package/dist/puck-editor/internal/ui/component-list-accordion.d.ts +13 -0
- package/dist/puck-editor/internal/ui/component-list-accordion.d.ts.map +1 -0
- package/dist/puck-editor/internal/ui/component-list-accordion.js +93 -0
- package/dist/puck-editor/internal/ui/component-list-accordion.js.map +1 -0
- package/dist/puck-editor/internal/ui/dialog.d.ts +20 -0
- package/dist/puck-editor/internal/ui/dialog.d.ts.map +1 -0
- package/dist/puck-editor/internal/ui/dialog.js +286 -0
- package/dist/puck-editor/internal/ui/dialog.js.map +1 -0
- package/dist/puck-editor/internal/ui/drawer-item-content.d.ts +11 -0
- package/dist/puck-editor/internal/ui/drawer-item-content.d.ts.map +1 -0
- package/dist/puck-editor/internal/ui/drawer-item-content.js +109 -0
- package/dist/puck-editor/internal/ui/drawer-item-content.js.map +1 -0
- package/dist/puck-editor/internal/ui/icon-button.d.ts +10 -0
- package/dist/puck-editor/internal/ui/icon-button.d.ts.map +1 -0
- package/dist/puck-editor/internal/ui/icon-button.js +72 -0
- package/dist/puck-editor/internal/ui/icon-button.js.map +1 -0
- package/dist/puck-editor/internal/ui/popover.d.ts +9 -0
- package/dist/puck-editor/internal/ui/popover.d.ts.map +1 -0
- package/dist/puck-editor/internal/ui/popover.js +165 -0
- package/dist/puck-editor/internal/ui/popover.js.map +1 -0
- package/dist/puck-editor/internal/ui/required-mark.d.ts +2 -0
- package/dist/puck-editor/internal/ui/required-mark.d.ts.map +1 -0
- package/dist/puck-editor/internal/ui/required-mark.js +12 -0
- package/dist/puck-editor/internal/ui/required-mark.js.map +1 -0
- package/dist/puck-editor/internal/ui/search-control.d.ts +20 -0
- package/dist/puck-editor/internal/ui/search-control.d.ts.map +1 -0
- package/dist/puck-editor/internal/ui/search-control.js +156 -0
- package/dist/puck-editor/internal/ui/search-control.js.map +1 -0
- package/dist/puck-editor/internal/ui/use-panel-search-focus.d.ts +2 -0
- package/dist/puck-editor/internal/ui/use-panel-search-focus.d.ts.map +1 -0
- package/dist/puck-editor/internal/ui/use-panel-search-focus.js +40 -0
- package/dist/puck-editor/internal/ui/use-panel-search-focus.js.map +1 -0
- package/dist/puck-editor/internal/use-puck-overlay.d.ts +16 -0
- package/dist/puck-editor/internal/use-puck-overlay.d.ts.map +1 -0
- package/dist/puck-editor/internal/use-puck-overlay.js +121 -0
- package/dist/puck-editor/internal/use-puck-overlay.js.map +1 -0
- package/dist/puck-editor/internal/utils.d.ts +6 -0
- package/dist/puck-editor/internal/utils.d.ts.map +1 -0
- package/dist/puck-editor/internal/utils.js +57 -0
- package/dist/puck-editor/internal/utils.js.map +1 -0
- package/dist/puck-editor/puck-theme.css +110 -0
- package/dist/puck-editor/render.d.ts +3 -0
- package/dist/puck-editor/render.d.ts.map +1 -0
- package/dist/puck-editor/render.js +2 -0
- package/dist/puck-editor/render.js.map +1 -0
- package/dist/puck-editor/server.d.ts +4 -0
- package/dist/puck-editor/server.d.ts.map +1 -0
- package/dist/puck-editor/server.js +4 -0
- package/dist/puck-editor/server.js.map +1 -0
- package/dist/puck-editor/smart-actions.d.ts +2 -0
- package/dist/puck-editor/smart-actions.d.ts.map +1 -0
- package/dist/puck-editor/smart-actions.js +2 -0
- package/dist/puck-editor/smart-actions.js.map +1 -0
- package/dist/shared/cn.d.ts +3 -0
- package/dist/shared/cn.d.ts.map +1 -0
- package/dist/shared/cn.js +9 -0
- package/dist/shared/cn.js.map +1 -0
- package/dist/shared/i18n.d.ts +5 -0
- package/dist/shared/i18n.d.ts.map +1 -0
- package/dist/shared/i18n.js +18 -0
- package/dist/shared/i18n.js.map +1 -0
- package/dist/shared/toolbar-action.d.ts +9 -0
- package/dist/shared/toolbar-action.d.ts.map +1 -0
- package/dist/shared/toolbar-action.js +2 -0
- package/dist/shared/toolbar-action.js.map +1 -0
- package/dist/smart-actions/internal/get-smart-actions-context.d.ts +19 -0
- package/dist/smart-actions/internal/get-smart-actions-context.d.ts.map +1 -0
- package/dist/smart-actions/internal/get-smart-actions-context.js +24 -0
- package/dist/smart-actions/internal/get-smart-actions-context.js.map +1 -0
- package/dist/smart-actions/internal/i18n.d.ts +20 -0
- package/dist/smart-actions/internal/i18n.d.ts.map +1 -0
- package/dist/smart-actions/internal/i18n.js +35 -0
- package/dist/smart-actions/internal/i18n.js.map +1 -0
- package/dist/smart-actions/internal/logout-form.d.ts +8 -0
- package/dist/smart-actions/internal/logout-form.d.ts.map +1 -0
- package/dist/smart-actions/internal/logout-form.js +88 -0
- package/dist/smart-actions/internal/logout-form.js.map +1 -0
- package/dist/smart-actions/internal/refresh-page.d.ts +2 -0
- package/dist/smart-actions/internal/refresh-page.d.ts.map +1 -0
- package/dist/smart-actions/internal/refresh-page.js +126 -0
- package/dist/smart-actions/internal/refresh-page.js.map +1 -0
- package/dist/smart-actions/internal/smart-actions-button.d.ts +24 -0
- package/dist/smart-actions/internal/smart-actions-button.d.ts.map +1 -0
- package/dist/smart-actions/internal/smart-actions-button.js +41 -0
- package/dist/smart-actions/internal/smart-actions-button.js.map +1 -0
- package/dist/smart-actions/internal/smart-actions-config.d.ts +13 -0
- package/dist/smart-actions/internal/smart-actions-config.d.ts.map +1 -0
- package/dist/smart-actions/internal/smart-actions-config.js +101 -0
- package/dist/smart-actions/internal/smart-actions-config.js.map +1 -0
- package/dist/smart-actions/internal/smart-actions-toolbar-client.d.ts +15 -0
- package/dist/smart-actions/internal/smart-actions-toolbar-client.d.ts.map +1 -0
- package/dist/smart-actions/internal/smart-actions-toolbar-client.js +71 -0
- package/dist/smart-actions/internal/smart-actions-toolbar-client.js.map +1 -0
- package/dist/smart-actions/internal/toolbar/smart-actions-toolbar.d.ts +13 -0
- package/dist/smart-actions/internal/toolbar/smart-actions-toolbar.d.ts.map +1 -0
- package/dist/smart-actions/internal/toolbar/smart-actions-toolbar.js +323 -0
- package/dist/smart-actions/internal/toolbar/smart-actions-toolbar.js.map +1 -0
- package/dist/smart-actions/internal/toolbar/storage.d.ts +7 -0
- package/dist/smart-actions/internal/toolbar/storage.d.ts.map +1 -0
- package/dist/smart-actions/internal/toolbar/storage.js +29 -0
- package/dist/smart-actions/internal/toolbar/storage.js.map +1 -0
- package/dist/smart-actions/internal/toolbar/types.d.ts +4 -0
- package/dist/smart-actions/internal/toolbar/types.d.ts.map +1 -0
- package/dist/smart-actions/internal/toolbar/types.js +2 -0
- package/dist/smart-actions/internal/toolbar/types.js.map +1 -0
- package/dist/smart-actions/internal/toolbar/use-smart-actions-toolbar-mode.d.ts +6 -0
- package/dist/smart-actions/internal/toolbar/use-smart-actions-toolbar-mode.d.ts.map +1 -0
- package/dist/smart-actions/internal/toolbar/use-smart-actions-toolbar-mode.js +43 -0
- package/dist/smart-actions/internal/toolbar/use-smart-actions-toolbar-mode.js.map +1 -0
- package/dist/smart-actions/internal/ui/tooltip.d.ts +8 -0
- package/dist/smart-actions/internal/ui/tooltip.d.ts.map +1 -0
- package/dist/smart-actions/internal/ui/tooltip.js +156 -0
- package/dist/smart-actions/internal/ui/tooltip.js.map +1 -0
- package/dist/smart-actions/internal/user-profile.d.ts +8 -0
- package/dist/smart-actions/internal/user-profile.d.ts.map +1 -0
- package/dist/smart-actions/internal/user-profile.js +30 -0
- package/dist/smart-actions/internal/user-profile.js.map +1 -0
- package/dist/smart-actions/server.d.ts +4 -0
- package/dist/smart-actions/server.d.ts.map +1 -0
- package/dist/smart-actions/server.js +4 -0
- package/dist/smart-actions/server.js.map +1 -0
- package/dist/theme.css +2 -0
- package/dist/visual-editor/index.d.ts +4 -0
- package/dist/visual-editor/index.d.ts.map +1 -0
- package/dist/visual-editor/index.js +4 -0
- package/dist/visual-editor/index.js.map +1 -0
- package/dist/visual-editor/internal/bridge/connector.d.ts +7 -0
- package/dist/visual-editor/internal/bridge/connector.d.ts.map +1 -0
- package/dist/visual-editor/internal/bridge/connector.js +72 -0
- package/dist/visual-editor/internal/bridge/connector.js.map +1 -0
- package/dist/visual-editor/internal/bridge/draft-mode-self-heal.d.ts +8 -0
- package/dist/visual-editor/internal/bridge/draft-mode-self-heal.d.ts.map +1 -0
- package/dist/visual-editor/internal/bridge/draft-mode-self-heal.js +44 -0
- package/dist/visual-editor/internal/bridge/draft-mode-self-heal.js.map +1 -0
- package/dist/visual-editor/internal/bridge/editor-auth-gate-server.d.ts +16 -0
- package/dist/visual-editor/internal/bridge/editor-auth-gate-server.d.ts.map +1 -0
- package/dist/visual-editor/internal/bridge/editor-auth-gate-server.js +43 -0
- package/dist/visual-editor/internal/bridge/editor-auth-gate-server.js.map +1 -0
- package/dist/visual-editor/internal/bridge/editor-auth-gate.d.ts +15 -0
- package/dist/visual-editor/internal/bridge/editor-auth-gate.d.ts.map +1 -0
- package/dist/visual-editor/internal/bridge/editor-auth-gate.js +146 -0
- package/dist/visual-editor/internal/bridge/editor-auth-gate.js.map +1 -0
- package/dist/visual-editor/internal/i18n.d.ts +29 -0
- package/dist/visual-editor/internal/i18n.d.ts.map +1 -0
- package/dist/visual-editor/internal/i18n.js +51 -0
- package/dist/visual-editor/internal/i18n.js.map +1 -0
- package/dist/visual-editor/internal/overlays/drupal-origin.d.ts +7 -0
- package/dist/visual-editor/internal/overlays/drupal-origin.d.ts.map +1 -0
- package/dist/visual-editor/internal/overlays/drupal-origin.js +15 -0
- package/dist/visual-editor/internal/overlays/drupal-origin.js.map +1 -0
- package/dist/visual-editor/internal/overlays/edit-button.d.ts +10 -0
- package/dist/visual-editor/internal/overlays/edit-button.d.ts.map +1 -0
- package/dist/visual-editor/internal/overlays/edit-button.js +138 -0
- package/dist/visual-editor/internal/overlays/edit-button.js.map +1 -0
- package/dist/visual-editor/internal/overlays/edit-icon.d.ts +3 -0
- package/dist/visual-editor/internal/overlays/edit-icon.d.ts.map +1 -0
- package/dist/visual-editor/internal/overlays/edit-icon.js +19 -0
- package/dist/visual-editor/internal/overlays/edit-icon.js.map +1 -0
- package/dist/visual-editor/internal/overlays/fragment/fragment-wrapper.d.ts +15 -0
- package/dist/visual-editor/internal/overlays/fragment/fragment-wrapper.d.ts.map +1 -0
- package/dist/visual-editor/internal/overlays/fragment/fragment-wrapper.js +52 -0
- package/dist/visual-editor/internal/overlays/fragment/fragment-wrapper.js.map +1 -0
- package/dist/visual-editor/internal/overlays/iframe-wrapper.d.ts +6 -0
- package/dist/visual-editor/internal/overlays/iframe-wrapper.d.ts.map +1 -0
- package/dist/visual-editor/internal/overlays/iframe-wrapper.js +42 -0
- package/dist/visual-editor/internal/overlays/iframe-wrapper.js.map +1 -0
- package/dist/visual-editor/internal/overlays/menu/menu-wrapper.d.ts +9 -0
- package/dist/visual-editor/internal/overlays/menu/menu-wrapper.d.ts.map +1 -0
- package/dist/visual-editor/internal/overlays/menu/menu-wrapper.js +33 -0
- package/dist/visual-editor/internal/overlays/menu/menu-wrapper.js.map +1 -0
- package/dist/visual-editor/internal/overlays/node/node-metadata.d.ts +13 -0
- package/dist/visual-editor/internal/overlays/node/node-metadata.d.ts.map +1 -0
- package/dist/visual-editor/internal/overlays/node/node-metadata.js +17 -0
- package/dist/visual-editor/internal/overlays/node/node-metadata.js.map +1 -0
- package/dist/visual-editor/internal/overlays/node/node-wrapper.d.ts +8 -0
- package/dist/visual-editor/internal/overlays/node/node-wrapper.d.ts.map +1 -0
- package/dist/visual-editor/internal/overlays/node/node-wrapper.js +25 -0
- package/dist/visual-editor/internal/overlays/node/node-wrapper.js.map +1 -0
- package/dist/visual-editor/internal/overlays/paragraph/paragraph-wrapper.d.ts +18 -0
- package/dist/visual-editor/internal/overlays/paragraph/paragraph-wrapper.d.ts.map +1 -0
- package/dist/visual-editor/internal/overlays/paragraph/paragraph-wrapper.js +58 -0
- package/dist/visual-editor/internal/overlays/paragraph/paragraph-wrapper.js.map +1 -0
- package/dist/visual-editor/internal/revalidate-route.d.ts +19 -0
- package/dist/visual-editor/internal/revalidate-route.d.ts.map +1 -0
- package/dist/visual-editor/internal/revalidate-route.js +51 -0
- package/dist/visual-editor/internal/revalidate-route.js.map +1 -0
- package/dist/visual-editor/server.d.ts +7 -0
- package/dist/visual-editor/server.d.ts.map +1 -0
- package/dist/visual-editor/server.js +8 -0
- package/dist/visual-editor/server.js.map +1 -0
- package/package.json +154 -0
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import { c as _c } from "react/compiler-runtime";
|
|
4
|
+
import * as React from 'react';
|
|
5
|
+
import * as PopoverPrimitive from '@radix-ui/react-popover';
|
|
6
|
+
import { cn } from '../../../shared/cn';
|
|
7
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
8
|
+
function Popover(t0) {
|
|
9
|
+
const $ = _c(4);
|
|
10
|
+
let props;
|
|
11
|
+
if ($[0] !== t0) {
|
|
12
|
+
({
|
|
13
|
+
...props
|
|
14
|
+
} = t0);
|
|
15
|
+
$[0] = t0;
|
|
16
|
+
$[1] = props;
|
|
17
|
+
} else {
|
|
18
|
+
props = $[1];
|
|
19
|
+
}
|
|
20
|
+
let t1;
|
|
21
|
+
if ($[2] !== props) {
|
|
22
|
+
t1 = /*#__PURE__*/_jsx(PopoverPrimitive.Root, {
|
|
23
|
+
"data-slot": "popover",
|
|
24
|
+
...props
|
|
25
|
+
});
|
|
26
|
+
$[2] = props;
|
|
27
|
+
$[3] = t1;
|
|
28
|
+
} else {
|
|
29
|
+
t1 = $[3];
|
|
30
|
+
}
|
|
31
|
+
return t1;
|
|
32
|
+
}
|
|
33
|
+
function PopoverTrigger(t0) {
|
|
34
|
+
const $ = _c(4);
|
|
35
|
+
let props;
|
|
36
|
+
if ($[0] !== t0) {
|
|
37
|
+
({
|
|
38
|
+
...props
|
|
39
|
+
} = t0);
|
|
40
|
+
$[0] = t0;
|
|
41
|
+
$[1] = props;
|
|
42
|
+
} else {
|
|
43
|
+
props = $[1];
|
|
44
|
+
}
|
|
45
|
+
let t1;
|
|
46
|
+
if ($[2] !== props) {
|
|
47
|
+
t1 = /*#__PURE__*/_jsx(PopoverPrimitive.Trigger, {
|
|
48
|
+
"data-slot": "popover-trigger",
|
|
49
|
+
...props
|
|
50
|
+
});
|
|
51
|
+
$[2] = props;
|
|
52
|
+
$[3] = t1;
|
|
53
|
+
} else {
|
|
54
|
+
t1 = $[3];
|
|
55
|
+
}
|
|
56
|
+
return t1;
|
|
57
|
+
}
|
|
58
|
+
function PopoverContent(t0) {
|
|
59
|
+
const $ = _c(12);
|
|
60
|
+
let className;
|
|
61
|
+
let props;
|
|
62
|
+
let t1;
|
|
63
|
+
let t2;
|
|
64
|
+
if ($[0] !== t0) {
|
|
65
|
+
({
|
|
66
|
+
className,
|
|
67
|
+
align: t1,
|
|
68
|
+
sideOffset: t2,
|
|
69
|
+
...props
|
|
70
|
+
} = t0);
|
|
71
|
+
$[0] = t0;
|
|
72
|
+
$[1] = className;
|
|
73
|
+
$[2] = props;
|
|
74
|
+
$[3] = t1;
|
|
75
|
+
$[4] = t2;
|
|
76
|
+
} else {
|
|
77
|
+
className = $[1];
|
|
78
|
+
props = $[2];
|
|
79
|
+
t1 = $[3];
|
|
80
|
+
t2 = $[4];
|
|
81
|
+
}
|
|
82
|
+
const align = t1 === undefined ? "center" : t1;
|
|
83
|
+
const sideOffset = t2 === undefined ? 4 : t2;
|
|
84
|
+
let t3;
|
|
85
|
+
if ($[5] !== className) {
|
|
86
|
+
t3 = cn("nh-root nh:data-[state=open]:animate-in nh:data-[state=closed]:animate-out nh:data-[state=closed]:fade-out-0 nh:data-[state=open]:fade-in-0 nh:data-[state=closed]:zoom-out-95 nh:data-[state=open]:zoom-in-95 nh:data-[side=bottom]:slide-in-from-top-2 nh:data-[side=left]:slide-in-from-right-2 nh:data-[side=right]:slide-in-from-left-2 nh:data-[side=top]:slide-in-from-bottom-2 nh:z-50 nh:w-72 nh:origin-(--radix-popover-content-transform-origin) nh:rounded-md nh:border nh:border-(--nh-border) nh:bg-(--nh-bg) nh:p-4 nh:shadow-md nh:outline-hidden", className);
|
|
87
|
+
$[5] = className;
|
|
88
|
+
$[6] = t3;
|
|
89
|
+
} else {
|
|
90
|
+
t3 = $[6];
|
|
91
|
+
}
|
|
92
|
+
let t4;
|
|
93
|
+
if ($[7] !== align || $[8] !== props || $[9] !== sideOffset || $[10] !== t3) {
|
|
94
|
+
t4 = /*#__PURE__*/_jsx(PopoverPrimitive.Portal, {
|
|
95
|
+
children: /*#__PURE__*/_jsx(PopoverPrimitive.Content, {
|
|
96
|
+
"data-slot": "popover-content",
|
|
97
|
+
"data-puck-editor-overlay": true,
|
|
98
|
+
align: align,
|
|
99
|
+
sideOffset: sideOffset,
|
|
100
|
+
className: t3,
|
|
101
|
+
...props
|
|
102
|
+
})
|
|
103
|
+
});
|
|
104
|
+
$[7] = align;
|
|
105
|
+
$[8] = props;
|
|
106
|
+
$[9] = sideOffset;
|
|
107
|
+
$[10] = t3;
|
|
108
|
+
$[11] = t4;
|
|
109
|
+
} else {
|
|
110
|
+
t4 = $[11];
|
|
111
|
+
}
|
|
112
|
+
return t4;
|
|
113
|
+
}
|
|
114
|
+
function PopoverAnchor(t0) {
|
|
115
|
+
const $ = _c(4);
|
|
116
|
+
let props;
|
|
117
|
+
if ($[0] !== t0) {
|
|
118
|
+
({
|
|
119
|
+
...props
|
|
120
|
+
} = t0);
|
|
121
|
+
$[0] = t0;
|
|
122
|
+
$[1] = props;
|
|
123
|
+
} else {
|
|
124
|
+
props = $[1];
|
|
125
|
+
}
|
|
126
|
+
let t1;
|
|
127
|
+
if ($[2] !== props) {
|
|
128
|
+
t1 = /*#__PURE__*/_jsx(PopoverPrimitive.Anchor, {
|
|
129
|
+
"data-slot": "popover-anchor",
|
|
130
|
+
...props
|
|
131
|
+
});
|
|
132
|
+
$[2] = props;
|
|
133
|
+
$[3] = t1;
|
|
134
|
+
} else {
|
|
135
|
+
t1 = $[3];
|
|
136
|
+
}
|
|
137
|
+
return t1;
|
|
138
|
+
}
|
|
139
|
+
function PopoverClose(t0) {
|
|
140
|
+
const $ = _c(4);
|
|
141
|
+
let props;
|
|
142
|
+
if ($[0] !== t0) {
|
|
143
|
+
({
|
|
144
|
+
...props
|
|
145
|
+
} = t0);
|
|
146
|
+
$[0] = t0;
|
|
147
|
+
$[1] = props;
|
|
148
|
+
} else {
|
|
149
|
+
props = $[1];
|
|
150
|
+
}
|
|
151
|
+
let t1;
|
|
152
|
+
if ($[2] !== props) {
|
|
153
|
+
t1 = /*#__PURE__*/_jsx(PopoverPrimitive.Close, {
|
|
154
|
+
"data-slot": "popover-close",
|
|
155
|
+
...props
|
|
156
|
+
});
|
|
157
|
+
$[2] = props;
|
|
158
|
+
$[3] = t1;
|
|
159
|
+
} else {
|
|
160
|
+
t1 = $[3];
|
|
161
|
+
}
|
|
162
|
+
return t1;
|
|
163
|
+
}
|
|
164
|
+
export { Popover, PopoverTrigger, PopoverContent, PopoverAnchor, PopoverClose };
|
|
165
|
+
//# sourceMappingURL=popover.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"popover.js","names":["c","_c","React","PopoverPrimitive","cn","jsx","_jsx","Popover","t0","$","props","t1","Root","PopoverTrigger","Trigger","PopoverContent","className","t2","align","sideOffset","undefined","t3","t4","Portal","children","Content","PopoverAnchor","Anchor","PopoverClose","Close"],"sources":["../../../../src/puck-editor/internal/ui/popover.tsx"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport * as PopoverPrimitive from '@radix-ui/react-popover';\n\nimport { cn } from '../../../shared/cn';\n\nfunction Popover({\n ...props\n}: React.ComponentProps<typeof PopoverPrimitive.Root>) {\n return <PopoverPrimitive.Root data-slot=\"popover\" {...props} />;\n}\n\nfunction PopoverTrigger({\n ...props\n}: React.ComponentProps<typeof PopoverPrimitive.Trigger>) {\n return <PopoverPrimitive.Trigger data-slot=\"popover-trigger\" {...props} />;\n}\n\nfunction PopoverContent({\n className,\n align = 'center',\n sideOffset = 4,\n ...props\n}: React.ComponentProps<typeof PopoverPrimitive.Content>) {\n return (\n <PopoverPrimitive.Portal>\n <PopoverPrimitive.Content\n data-slot=\"popover-content\"\n data-puck-editor-overlay\n align={align}\n sideOffset={sideOffset}\n className={cn(\n 'nh-root nh:data-[state=open]:animate-in nh:data-[state=closed]:animate-out nh:data-[state=closed]:fade-out-0 nh:data-[state=open]:fade-in-0 nh:data-[state=closed]:zoom-out-95 nh:data-[state=open]:zoom-in-95 nh:data-[side=bottom]:slide-in-from-top-2 nh:data-[side=left]:slide-in-from-right-2 nh:data-[side=right]:slide-in-from-left-2 nh:data-[side=top]:slide-in-from-bottom-2 nh:z-50 nh:w-72 nh:origin-(--radix-popover-content-transform-origin) nh:rounded-md nh:border nh:border-(--nh-border) nh:bg-(--nh-bg) nh:p-4 nh:shadow-md nh:outline-hidden',\n className\n )}\n {...props}\n />\n </PopoverPrimitive.Portal>\n );\n}\n\nfunction PopoverAnchor({\n ...props\n}: React.ComponentProps<typeof PopoverPrimitive.Anchor>) {\n return <PopoverPrimitive.Anchor data-slot=\"popover-anchor\" {...props} />;\n}\n\nfunction PopoverClose({\n ...props\n}: React.ComponentProps<typeof PopoverPrimitive.Close>) {\n return <PopoverPrimitive.Close data-slot=\"popover-close\" {...props} />;\n}\n\nexport { Popover, PopoverTrigger, PopoverContent, PopoverAnchor, PopoverClose };\n"],"mappings":"AAAA,YAAY;;AAAC,SAAAA,CAAA,IAAAC,EAAA;AAEb,OAAO,KAAKC,KAAK,MAAM,OAAO;AAC9B,OAAO,KAAKC,gBAAgB,MAAM,yBAAyB;AAE3D,SAASC,EAAE,QAAQ,oBAAoB;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAExC,SAAAC,QAAAC,EAAA;EAAA,MAAAC,CAAA,GAAAR,EAAA;EAAA,IAAAS,KAAA;EAAA,IAAAD,CAAA,QAAAD,EAAA;IAAiB;MAAA,GAAAE;IAAA,IAAAF,EAEoC;IAAAC,CAAA,MAAAD,EAAA;IAAAC,CAAA,MAAAC,KAAA;EAAA;IAAAA,KAAA,GAAAD,CAAA;EAAA;EAAA,IAAAE,EAAA;EAAA,IAAAF,CAAA,QAAAC,KAAA;IAC5CC,EAAA,gBAAAL,IAAA,CAAAH,gBAAA,CAAAS,IAAA;MAAiC,sBAAS;MAAA,GAAKF;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AAAH,gBAAA,CAAAwB,MAAA;MAAmC,6BAAgB;MAAA,GAAKjB;IAAK,CAAG,CAAC;IAAAD,CAAA,MAAAC,KAAA;IAAAD,CAAA,MAAAE,EAAA;EAAA;IAAAA,EAAA,GAAAF,CAAA;EAAA;EAAA,OAAjEE,EAAiE;AAAA;AAG1E,SAAAiB,aAAApB,EAAA;EAAA,MAAAC,CAAA,GAAAR,EAAA;EAAA,IAAAS,KAAA;EAAA,IAAAD,CAAA,QAAAD,EAAA;IAAsB;MAAA,GAAAE;IAAA,IAAAF,EAEgC;IAAAC,CAAA,MAAAD,EAAA;IAAAC,CAAA,MAAAC,KAAA;EAAA;IAAAA,KAAA,GAAAD,CAAA;EAAA;EAAA,IAAAE,EAAA;EAAA,IAAAF,CAAA,QAAAC,KAAA;IAC7CC,EAAA,gBAAAL,IAAA,CAAAH,gBAAA,CAAA0B,KAAA;MAAkC,4BAAe;MAAA,GAAKnB;IAAK,CAAG,CAAC;IAAAD,CAAA,MAAAC,KAAA;IAAAD,CAAA,MAAAE,EAAA;EAAA;IAAAA,EAAA,GAAAF,CAAA;EAAA;EAAA,OAA/DE,EAA+D;AAAA;AAGxE,SAASJ,OAAO,EAAEM,cAAc,EAAEE,cAAc,EAAEW,aAAa,EAAEE,YAAY","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"required-mark.d.ts","sourceRoot":"","sources":["../../../../src/puck-editor/internal/ui/required-mark.tsx"],"names":[],"mappings":"AAGA,wBAAgB,YAAY,gCAO3B"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
// Decorative required-field marker for markup we control (e.g. HTML forms).
|
|
3
|
+
// The input's `required` attribute conveys the requirement to assistive tech.
|
|
4
|
+
// Note: Puck field labels are plain strings, so wrap fields with `required()` there.
|
|
5
|
+
export function RequiredMark() {
|
|
6
|
+
return /*#__PURE__*/_jsxs("span", {
|
|
7
|
+
className: "text-red-500",
|
|
8
|
+
"aria-hidden": "true",
|
|
9
|
+
children: [' ', "*"]
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
//# sourceMappingURL=required-mark.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"required-mark.js","names":["RequiredMark","_jsxs","className","children"],"sources":["../../../../src/puck-editor/internal/ui/required-mark.tsx"],"sourcesContent":["// Decorative required-field marker for markup we control (e.g. HTML forms).\n// The input's `required` attribute conveys the requirement to assistive tech.\n// Note: Puck field labels are plain strings, so wrap fields with `required()` there.\nexport function RequiredMark() {\n return (\n <span className=\"text-red-500\" aria-hidden=\"true\">\n {' '}\n *\n </span>\n );\n}\n"],"mappings":";AAAA;AACA;AACA;AACA,OAAO,SAASA,YAAYA,CAAA,EAAG;EAC7B,oBACEC,KAAA;IAAMC,SAAS,EAAC,cAAc;IAAC,eAAY,MAAM;IAAAC,QAAA,GAC9C,GAAG,EAAC,GAEP;EAAA,CAAM,CAAC;AAEX","ignoreList":[]}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { ReactNode, RefObject } from 'react';
|
|
2
|
+
type SearchControlProps = {
|
|
3
|
+
value: string;
|
|
4
|
+
onChange: (value: string) => void;
|
|
5
|
+
placeholder: string;
|
|
6
|
+
clearLabel?: string;
|
|
7
|
+
autoFocus?: boolean;
|
|
8
|
+
compact?: boolean;
|
|
9
|
+
className?: string;
|
|
10
|
+
inputRef?: RefObject<HTMLInputElement | null>;
|
|
11
|
+
};
|
|
12
|
+
export declare function SearchControl({ value, onChange, placeholder, clearLabel, autoFocus, compact, className, inputRef, }: SearchControlProps): import("react").JSX.Element;
|
|
13
|
+
type EmptyStateProps = {
|
|
14
|
+
children: ReactNode;
|
|
15
|
+
compact?: boolean;
|
|
16
|
+
className?: string;
|
|
17
|
+
};
|
|
18
|
+
export declare function SearchEmptyState({ children, compact, className, }: EmptyStateProps): import("react").JSX.Element;
|
|
19
|
+
export {};
|
|
20
|
+
//# sourceMappingURL=search-control.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"search-control.d.ts","sourceRoot":"","sources":["../../../../src/puck-editor/internal/ui/search-control.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAOlD,KAAK,kBAAkB,GAAG;IACxB,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAClC,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,SAAS,CAAC,gBAAgB,GAAG,IAAI,CAAC,CAAC;CAC/C,CAAC;AAEF,wBAAgB,aAAa,CAAC,EAC5B,KAAK,EACL,QAAQ,EACR,WAAW,EACX,UAAU,EACV,SAAS,EACT,OAAO,EACP,SAAS,EACT,QAAQ,GACT,EAAE,kBAAkB,+BAuCpB;AAED,KAAK,eAAe,GAAG;IACrB,QAAQ,EAAE,SAAS,CAAC;IACpB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB,CAAC;AAEF,wBAAgB,gBAAgB,CAAC,EAC/B,QAAQ,EACR,OAAO,EACP,SAAS,GACV,EAAE,eAAe,+BAYjB"}
|
|
@@ -0,0 +1,156 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import { c as _c } from "react/compiler-runtime";
|
|
4
|
+
import { SearchIcon, XIcon } from 'lucide-react';
|
|
5
|
+
import { cn } from '../../../shared/cn';
|
|
6
|
+
import { usePuckDictionary } from '../i18n';
|
|
7
|
+
import { IconButton } from './icon-button';
|
|
8
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
9
|
+
export function SearchControl(t0) {
|
|
10
|
+
const $ = _c(27);
|
|
11
|
+
const {
|
|
12
|
+
value,
|
|
13
|
+
onChange,
|
|
14
|
+
placeholder,
|
|
15
|
+
clearLabel,
|
|
16
|
+
autoFocus,
|
|
17
|
+
compact,
|
|
18
|
+
className,
|
|
19
|
+
inputRef
|
|
20
|
+
} = t0;
|
|
21
|
+
const {
|
|
22
|
+
clearSearch
|
|
23
|
+
} = usePuckDictionary().common;
|
|
24
|
+
const resolvedClearLabel = clearLabel ?? clearSearch;
|
|
25
|
+
let t1;
|
|
26
|
+
if ($[0] !== className) {
|
|
27
|
+
t1 = cn("nh:relative", className);
|
|
28
|
+
$[0] = className;
|
|
29
|
+
$[1] = t1;
|
|
30
|
+
} else {
|
|
31
|
+
t1 = $[1];
|
|
32
|
+
}
|
|
33
|
+
const t2 = compact ? "nh:left-2 nh:size-3.5" : "nh:left-2.5 nh:h-4 nh:w-4";
|
|
34
|
+
let t3;
|
|
35
|
+
if ($[2] !== t2) {
|
|
36
|
+
t3 = cn("nh:absolute nh:top-1/2 nh:-translate-y-1/2 nh:text-gray-400", t2);
|
|
37
|
+
$[2] = t2;
|
|
38
|
+
$[3] = t3;
|
|
39
|
+
} else {
|
|
40
|
+
t3 = $[3];
|
|
41
|
+
}
|
|
42
|
+
let t4;
|
|
43
|
+
if ($[4] !== t3) {
|
|
44
|
+
t4 = /*#__PURE__*/_jsx(SearchIcon, {
|
|
45
|
+
className: t3
|
|
46
|
+
});
|
|
47
|
+
$[4] = t3;
|
|
48
|
+
$[5] = t4;
|
|
49
|
+
} else {
|
|
50
|
+
t4 = $[5];
|
|
51
|
+
}
|
|
52
|
+
let t5;
|
|
53
|
+
if ($[6] !== onChange) {
|
|
54
|
+
t5 = e => onChange(e.target.value);
|
|
55
|
+
$[6] = onChange;
|
|
56
|
+
$[7] = t5;
|
|
57
|
+
} else {
|
|
58
|
+
t5 = $[7];
|
|
59
|
+
}
|
|
60
|
+
const t6 = compact ? "nh:py-1 nh:pr-8 nh:pl-7" : "nh:py-1.5 nh:pr-8 nh:pl-8";
|
|
61
|
+
let t7;
|
|
62
|
+
if ($[8] !== t6) {
|
|
63
|
+
t7 = cn("nh:w-full nh:rounded-md nh:border nh:border-gray-200 nh:text-sm nh:focus:outline-none", t6);
|
|
64
|
+
$[8] = t6;
|
|
65
|
+
$[9] = t7;
|
|
66
|
+
} else {
|
|
67
|
+
t7 = $[9];
|
|
68
|
+
}
|
|
69
|
+
let t8;
|
|
70
|
+
if ($[10] !== autoFocus || $[11] !== inputRef || $[12] !== placeholder || $[13] !== t5 || $[14] !== t7 || $[15] !== value) {
|
|
71
|
+
t8 = /*#__PURE__*/_jsx("input", {
|
|
72
|
+
ref: inputRef,
|
|
73
|
+
autoFocus: autoFocus,
|
|
74
|
+
type: "text",
|
|
75
|
+
value: value,
|
|
76
|
+
onChange: t5,
|
|
77
|
+
placeholder: placeholder,
|
|
78
|
+
className: t7
|
|
79
|
+
});
|
|
80
|
+
$[10] = autoFocus;
|
|
81
|
+
$[11] = inputRef;
|
|
82
|
+
$[12] = placeholder;
|
|
83
|
+
$[13] = t5;
|
|
84
|
+
$[14] = t7;
|
|
85
|
+
$[15] = value;
|
|
86
|
+
$[16] = t8;
|
|
87
|
+
} else {
|
|
88
|
+
t8 = $[16];
|
|
89
|
+
}
|
|
90
|
+
let t9;
|
|
91
|
+
if ($[17] !== compact || $[18] !== onChange || $[19] !== resolvedClearLabel || $[20] !== value) {
|
|
92
|
+
t9 = value && /*#__PURE__*/_jsx(IconButton, {
|
|
93
|
+
"aria-label": resolvedClearLabel,
|
|
94
|
+
title: resolvedClearLabel,
|
|
95
|
+
onClick: () => onChange(""),
|
|
96
|
+
className: cn("nh:absolute nh:top-1/2 nh:-translate-y-1/2", compact ? "nh:right-1.5" : "nh:right-2"),
|
|
97
|
+
children: /*#__PURE__*/_jsx(XIcon, {
|
|
98
|
+
className: "nh:h-4 nh:w-4"
|
|
99
|
+
})
|
|
100
|
+
});
|
|
101
|
+
$[17] = compact;
|
|
102
|
+
$[18] = onChange;
|
|
103
|
+
$[19] = resolvedClearLabel;
|
|
104
|
+
$[20] = value;
|
|
105
|
+
$[21] = t9;
|
|
106
|
+
} else {
|
|
107
|
+
t9 = $[21];
|
|
108
|
+
}
|
|
109
|
+
let t10;
|
|
110
|
+
if ($[22] !== t1 || $[23] !== t4 || $[24] !== t8 || $[25] !== t9) {
|
|
111
|
+
t10 = /*#__PURE__*/_jsxs("div", {
|
|
112
|
+
className: t1,
|
|
113
|
+
children: [t4, t8, t9]
|
|
114
|
+
});
|
|
115
|
+
$[22] = t1;
|
|
116
|
+
$[23] = t4;
|
|
117
|
+
$[24] = t8;
|
|
118
|
+
$[25] = t9;
|
|
119
|
+
$[26] = t10;
|
|
120
|
+
} else {
|
|
121
|
+
t10 = $[26];
|
|
122
|
+
}
|
|
123
|
+
return t10;
|
|
124
|
+
}
|
|
125
|
+
export function SearchEmptyState(t0) {
|
|
126
|
+
const $ = _c(6);
|
|
127
|
+
const {
|
|
128
|
+
children,
|
|
129
|
+
compact,
|
|
130
|
+
className
|
|
131
|
+
} = t0;
|
|
132
|
+
const t1 = compact ? "nh:px-2 nh:py-3 nh:text-xs" : "nh:px-3 nh:py-8 nh:text-sm";
|
|
133
|
+
let t2;
|
|
134
|
+
if ($[0] !== className || $[1] !== t1) {
|
|
135
|
+
t2 = cn("nh:text-center nh:text-gray-500", t1, className);
|
|
136
|
+
$[0] = className;
|
|
137
|
+
$[1] = t1;
|
|
138
|
+
$[2] = t2;
|
|
139
|
+
} else {
|
|
140
|
+
t2 = $[2];
|
|
141
|
+
}
|
|
142
|
+
let t3;
|
|
143
|
+
if ($[3] !== children || $[4] !== t2) {
|
|
144
|
+
t3 = /*#__PURE__*/_jsx("div", {
|
|
145
|
+
className: t2,
|
|
146
|
+
children: children
|
|
147
|
+
});
|
|
148
|
+
$[3] = children;
|
|
149
|
+
$[4] = t2;
|
|
150
|
+
$[5] = t3;
|
|
151
|
+
} else {
|
|
152
|
+
t3 = $[5];
|
|
153
|
+
}
|
|
154
|
+
return t3;
|
|
155
|
+
}
|
|
156
|
+
//# sourceMappingURL=search-control.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"search-control.js","names":["c","_c","SearchIcon","XIcon","cn","usePuckDictionary","IconButton","jsx","_jsx","jsxs","_jsxs","SearchControl","t0","$","value","onChange","placeholder","clearLabel","autoFocus","compact","className","inputRef","clearSearch","common","resolvedClearLabel","t1","t2","t3","t4","t5","e","target","t6","t7","t8","type","t9","onClick","children","t10","SearchEmptyState"],"sources":["../../../../src/puck-editor/internal/ui/search-control.tsx"],"sourcesContent":["'use client';\n\nimport type { ReactNode, RefObject } from 'react';\nimport { SearchIcon, XIcon } from 'lucide-react';\n\nimport { cn } from '../../../shared/cn';\nimport { usePuckDictionary } from '../i18n';\nimport { IconButton } from './icon-button';\n\ntype SearchControlProps = {\n value: string;\n onChange: (value: string) => void;\n placeholder: string;\n clearLabel?: string;\n autoFocus?: boolean;\n compact?: boolean;\n className?: string;\n inputRef?: RefObject<HTMLInputElement | null>;\n};\n\nexport function SearchControl({\n value,\n onChange,\n placeholder,\n clearLabel,\n autoFocus,\n compact,\n className,\n inputRef,\n}: SearchControlProps) {\n const { clearSearch } = usePuckDictionary().common;\n const resolvedClearLabel = clearLabel ?? clearSearch;\n\n return (\n <div className={cn('nh:relative', className)}>\n <SearchIcon\n className={cn(\n 'nh:absolute nh:top-1/2 nh:-translate-y-1/2 nh:text-gray-400',\n compact ? 'nh:left-2 nh:size-3.5' : 'nh:left-2.5 nh:h-4 nh:w-4'\n )}\n />\n <input\n ref={inputRef}\n autoFocus={autoFocus}\n type=\"text\"\n value={value}\n onChange={(e) => onChange(e.target.value)}\n placeholder={placeholder}\n className={cn(\n 'nh:w-full nh:rounded-md nh:border nh:border-gray-200 nh:text-sm nh:focus:outline-none',\n compact ? 'nh:py-1 nh:pr-8 nh:pl-7' : 'nh:py-1.5 nh:pr-8 nh:pl-8'\n )}\n />\n {value && (\n <IconButton\n aria-label={resolvedClearLabel}\n title={resolvedClearLabel}\n onClick={() => onChange('')}\n className={cn(\n 'nh:absolute nh:top-1/2 nh:-translate-y-1/2',\n compact ? 'nh:right-1.5' : 'nh:right-2'\n )}\n >\n <XIcon className=\"nh:h-4 nh:w-4\" />\n </IconButton>\n )}\n </div>\n );\n}\n\ntype EmptyStateProps = {\n children: ReactNode;\n compact?: boolean;\n className?: string;\n};\n\nexport function SearchEmptyState({\n children,\n compact,\n className,\n}: EmptyStateProps) {\n return (\n <div\n className={cn(\n 'nh:text-center nh:text-gray-500',\n compact ? 'nh:px-2 nh:py-3 nh:text-xs' : 'nh:px-3 nh:py-8 nh:text-sm',\n className\n )}\n >\n {children}\n </div>\n );\n}\n"],"mappings":"AAAA,YAAY;;AAAC,SAAAA,CAAA,IAAAC,EAAA;AAGb,SAASC,UAAU,EAAEC,KAAK,QAAQ,cAAc;AAEhD,SAASC,EAAE,QAAQ,oBAAoB;AACvC,SAASC,iBAAiB,QAAQ,SAAS;AAC3C,SAASC,UAAU,QAAQ,eAAe;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAa3C,OAAO,SAAAC,cAAAC,EAAA;EAAA,MAAAC,CAAA,GAAAZ,EAAA;EAAuB;IAAAa,KAAA;IAAAC,QAAA;IAAAC,WAAA;IAAAC,UAAA;IAAAC,SAAA;IAAAC,OAAA;IAAAC,SAAA;IAAAC;EAAA,IAAAT,EAST;EACnB;IAAAU;EAAA,IAAwBjB,iBAAiB,CAAC,CAAC,CAAAkB,MAAO;EAClD,MAAAC,kBAAA,GAA2BP,UAAyB,IAAzBK,WAAyB;EAAC,IAAAG,EAAA;EAAA,IAAAZ,CAAA,QAAAO,SAAA;IAGnCK,EAAA,GAAArB,EAAE,CAAC,aAAa,EAAEgB,SAAS,CAAC;IAAAP,CAAA,MAAAO,SAAA;IAAAP,CAAA,MAAAY,E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Root":"","sources":["../../../../src/puck-editor/internal/ui/use-panel-search-focus.ts"],"names":[],"mappings":"AAWA,wBAAgB,mBAAmB,CAAC,UAAU,EAAE,MAAM,sDAarD"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import { c as _c } from "react/compiler-runtime";
|
|
4
|
+
import { useEffect, useRef } from 'react';
|
|
5
|
+
import { createUsePuck } from '@puckeditor/core';
|
|
6
|
+
const usePuck = createUsePuck();
|
|
7
|
+
// Puck keeps every plugin panel mounted and only toggles visibility, so an
|
|
8
|
+
// autoFocus on the input fires once at editor mount, not when the panel opens.
|
|
9
|
+
export function usePanelSearchFocus(pluginName) {
|
|
10
|
+
const $ = _c(3);
|
|
11
|
+
const inputRef = useRef(null);
|
|
12
|
+
const currentPlugin = usePuck(_temp);
|
|
13
|
+
const sidebarVisible = usePuck(_temp2);
|
|
14
|
+
const open = currentPlugin === pluginName && sidebarVisible !== false;
|
|
15
|
+
let t0;
|
|
16
|
+
let t1;
|
|
17
|
+
if ($[0] !== open) {
|
|
18
|
+
t0 = () => {
|
|
19
|
+
if (open) {
|
|
20
|
+
inputRef.current?.focus();
|
|
21
|
+
}
|
|
22
|
+
};
|
|
23
|
+
t1 = [open];
|
|
24
|
+
$[0] = open;
|
|
25
|
+
$[1] = t0;
|
|
26
|
+
$[2] = t1;
|
|
27
|
+
} else {
|
|
28
|
+
t0 = $[1];
|
|
29
|
+
t1 = $[2];
|
|
30
|
+
}
|
|
31
|
+
useEffect(t0, t1);
|
|
32
|
+
return inputRef;
|
|
33
|
+
}
|
|
34
|
+
function _temp2(s_0) {
|
|
35
|
+
return s_0.appState.ui.leftSideBarVisible;
|
|
36
|
+
}
|
|
37
|
+
function _temp(s) {
|
|
38
|
+
return s.appState.ui.plugin?.current;
|
|
39
|
+
}
|
|
40
|
+
//# sourceMappingURL=use-panel-search-focus.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-panel-search-focus.js","names":["c","_c","useEffect","useRef","createUsePuck","usePuck","usePanelSearchFocus","pluginName","$","inputRef","currentPlugin","_temp","sidebarVisible","_temp2","open","t0","t1","current","focus","s_0","s","appState","ui","leftSideBarVisible","plugin"],"sources":["../../../../src/puck-editor/internal/ui/use-panel-search-focus.ts"],"sourcesContent":["'use client';\n\nimport { useEffect, useRef } from 'react';\nimport { createUsePuck } from '@puckeditor/core';\n\nconst usePuck = createUsePuck();\n\ntype PluginUi = { plugin?: { current?: string } };\n\n// Puck keeps every plugin panel mounted and only toggles visibility, so an\n// autoFocus on the input fires once at editor mount, not when the panel opens.\nexport function usePanelSearchFocus(pluginName: string) {\n const inputRef = useRef<HTMLInputElement>(null);\n const currentPlugin = usePuck(\n (s) => (s.appState.ui as PluginUi).plugin?.current\n );\n const sidebarVisible = usePuck((s) => s.appState.ui.leftSideBarVisible);\n const open = currentPlugin === pluginName && sidebarVisible !== false;\n\n useEffect(() => {\n if (open) inputRef.current?.focus();\n }, [open]);\n\n return inputRef;\n}\n"],"mappings":"AAAA,YAAY;;AAAC,SAAAA,CAAA,IAAAC,EAAA;AAEb,SAASC,SAAS,EAAEC,MAAM,QAAQ,OAAO;AACzC,SAASC,aAAa,QAAQ,kBAAkB;AAEhD,MAAMC,OAAO,GAAGD,aAAa,CAAC,CAAC;AAI/B;AACA;AACA,OAAO,SAAAE,oBAAAC,UAAA;EAAA,MAAAC,CAAA,GAAAP,EAAA;EACL,MAAAQ,QAAA,GAAiBN,MAAM,CAAmB,IAAI,CAAC;EAC/C,MAAAO,aAAA,GAAsBL,OAAO,CAC3BM,KACF,CAAC;EACD,MAAAC,cAAA,GAAuBP,OAAO,CAACQ,MAAuC,CAAC;EACvE,MAAAC,IAAA,GAAaJ,aAAa,KAAKH,UAAsC,IAAxBK,cAAc,KAAK,KAAK;EAAC,IAAAG,EAAA;EAAA,IAAAC,EAAA;EAAA,IAAAR,CAAA,QAAAM,IAAA;IAE5DC,EAAA,GAAAA,CAAA;MACR,IAAID,IAAI;QAAEL,QAAQ,CAAAQ,OAAe,EAAAC,KAAE,CAAD,CAAC;MAAA;IAAC,CACrC;IAAEF,EAAA,IAACF,IAAI,CAAC;IAAAN,CAAA,MAAAM,IAAA;IAAAN,CAAA,MAAAO,EAAA;IAAAP,CAAA,MAAAQ,EAAA;EAAA;IAAAD,EAAA,GAAAP,CAAA;IAAAQ,EAAA,GAAAR,CAAA;EAAA;EAFTN,SAAS,CAACa,EAET,EAAEC,EAAM,CAAC;EAAA,OAEHP,QAAQ;AAAA;AAZV,SAAAI,OAAAM,GAAA;EAAA,OAKiCC,GAAC,CAAAC,QAAS,CAAAC,EAAG,CAAAC,kBAAmB;AAAA;AALjE,SAAAZ,MAAAS,CAAA;EAAA,OAGKA,CAAC,CAAAC,QAAS,CAAAC,EAAG,CAAAE,MAA6B,EAAAP,OAAA;AAAA","ignoreList":[]}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { PuckNode } from './puck-node';
|
|
2
|
+
type UsePuckOverlayOptions = {
|
|
3
|
+
node: PuckNode;
|
|
4
|
+
fieldName: string;
|
|
5
|
+
isLoggedIn: boolean;
|
|
6
|
+
};
|
|
7
|
+
export declare function usePuckOverlay({ node, fieldName, isLoggedIn, }: UsePuckOverlayOptions): {
|
|
8
|
+
isEditMode: boolean;
|
|
9
|
+
isEditorReady: boolean;
|
|
10
|
+
setIsEditorReady: import("react").Dispatch<import("react").SetStateAction<boolean>>;
|
|
11
|
+
openEditor: () => void;
|
|
12
|
+
closeEditor: () => Promise<void>;
|
|
13
|
+
isHighlighted: boolean;
|
|
14
|
+
};
|
|
15
|
+
export {};
|
|
16
|
+
//# sourceMappingURL=use-puck-overlay.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-puck-overlay.d.ts","sourceRoot":"","sources":["../../../src/puck-editor/internal/use-puck-overlay.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAEvC,KAAK,qBAAqB,GAAG;IAC3B,IAAI,EAAE,QAAQ,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,OAAO,CAAC;CACrB,CAAC;AAEF,wBAAgB,cAAc,CAAC,EAC7B,IAAI,EACJ,SAAS,EACT,UAAU,GACX,EAAE,qBAAqB;;;;;;;EAiDvB"}
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import { c as _c } from "react/compiler-runtime";
|
|
4
|
+
import { useEffect, useState } from 'react';
|
|
5
|
+
import { usePathname, useRouter, useSearchParams } from 'next/navigation';
|
|
6
|
+
import { useScrollLockOutside } from './editor/use-scroll-lock-outside';
|
|
7
|
+
import { useAgentHandle } from './plugins/agent-plugin/use-agent-handle';
|
|
8
|
+
import { usePuckEditor } from './puck-editor-provider';
|
|
9
|
+
export function usePuckOverlay(t0) {
|
|
10
|
+
const $ = _c(22);
|
|
11
|
+
const {
|
|
12
|
+
node,
|
|
13
|
+
fieldName,
|
|
14
|
+
isLoggedIn
|
|
15
|
+
} = t0;
|
|
16
|
+
const searchParams = useSearchParams();
|
|
17
|
+
const router = useRouter();
|
|
18
|
+
const pathName = usePathname();
|
|
19
|
+
let t1;
|
|
20
|
+
if ($[0] !== searchParams) {
|
|
21
|
+
t1 = searchParams.get("puckeditor");
|
|
22
|
+
$[0] = searchParams;
|
|
23
|
+
$[1] = t1;
|
|
24
|
+
} else {
|
|
25
|
+
t1 = $[1];
|
|
26
|
+
}
|
|
27
|
+
const puckDataParams = t1;
|
|
28
|
+
const [isEditMode, setIsEditMode] = useState(puckDataParams === fieldName);
|
|
29
|
+
const [isEditorReady, setIsEditorReady] = useState(puckDataParams === fieldName);
|
|
30
|
+
const {
|
|
31
|
+
registerEditor,
|
|
32
|
+
isHighlighted
|
|
33
|
+
} = usePuckEditor();
|
|
34
|
+
let t2;
|
|
35
|
+
let t3;
|
|
36
|
+
if ($[2] !== registerEditor) {
|
|
37
|
+
t2 = () => {
|
|
38
|
+
registerEditor(() => setIsEditMode(true));
|
|
39
|
+
};
|
|
40
|
+
t3 = [registerEditor];
|
|
41
|
+
$[2] = registerEditor;
|
|
42
|
+
$[3] = t2;
|
|
43
|
+
$[4] = t3;
|
|
44
|
+
} else {
|
|
45
|
+
t2 = $[3];
|
|
46
|
+
t3 = $[4];
|
|
47
|
+
}
|
|
48
|
+
useEffect(t2, t3);
|
|
49
|
+
useScrollLockOutside(isEditMode, "[data-puck-editor-overlay]");
|
|
50
|
+
let t4;
|
|
51
|
+
if ($[5] === Symbol.for("react.memo_cache_sentinel")) {
|
|
52
|
+
t4 = () => setIsEditMode(true);
|
|
53
|
+
$[5] = t4;
|
|
54
|
+
} else {
|
|
55
|
+
t4 = $[5];
|
|
56
|
+
}
|
|
57
|
+
const openEditor = t4;
|
|
58
|
+
let t5;
|
|
59
|
+
if ($[6] !== pathName || $[7] !== router || $[8] !== searchParams) {
|
|
60
|
+
t5 = async () => {
|
|
61
|
+
setIsEditMode(false);
|
|
62
|
+
if (searchParams.has("puckeditor")) {
|
|
63
|
+
const newSearchParams = new URLSearchParams(searchParams.toString());
|
|
64
|
+
newSearchParams.delete("puckeditor");
|
|
65
|
+
router.replace(`${pathName}?${newSearchParams.toString()}`, {
|
|
66
|
+
scroll: true
|
|
67
|
+
});
|
|
68
|
+
}
|
|
69
|
+
router.refresh();
|
|
70
|
+
};
|
|
71
|
+
$[6] = pathName;
|
|
72
|
+
$[7] = router;
|
|
73
|
+
$[8] = searchParams;
|
|
74
|
+
$[9] = t5;
|
|
75
|
+
} else {
|
|
76
|
+
t5 = $[9];
|
|
77
|
+
}
|
|
78
|
+
const closeEditor = t5;
|
|
79
|
+
let t6;
|
|
80
|
+
if ($[10] !== closeEditor || $[11] !== fieldName || $[12] !== isEditMode || $[13] !== isLoggedIn || $[14] !== node.langcode || $[15] !== node.type) {
|
|
81
|
+
t6 = {
|
|
82
|
+
isLoggedIn,
|
|
83
|
+
open: openEditor,
|
|
84
|
+
close: closeEditor,
|
|
85
|
+
isEditMode,
|
|
86
|
+
type: node.type,
|
|
87
|
+
fieldName,
|
|
88
|
+
lang: node.langcode
|
|
89
|
+
};
|
|
90
|
+
$[10] = closeEditor;
|
|
91
|
+
$[11] = fieldName;
|
|
92
|
+
$[12] = isEditMode;
|
|
93
|
+
$[13] = isLoggedIn;
|
|
94
|
+
$[14] = node.langcode;
|
|
95
|
+
$[15] = node.type;
|
|
96
|
+
$[16] = t6;
|
|
97
|
+
} else {
|
|
98
|
+
t6 = $[16];
|
|
99
|
+
}
|
|
100
|
+
useAgentHandle(t6);
|
|
101
|
+
let t7;
|
|
102
|
+
if ($[17] !== closeEditor || $[18] !== isEditMode || $[19] !== isEditorReady || $[20] !== isHighlighted) {
|
|
103
|
+
t7 = {
|
|
104
|
+
isEditMode,
|
|
105
|
+
isEditorReady,
|
|
106
|
+
setIsEditorReady,
|
|
107
|
+
openEditor,
|
|
108
|
+
closeEditor,
|
|
109
|
+
isHighlighted
|
|
110
|
+
};
|
|
111
|
+
$[17] = closeEditor;
|
|
112
|
+
$[18] = isEditMode;
|
|
113
|
+
$[19] = isEditorReady;
|
|
114
|
+
$[20] = isHighlighted;
|
|
115
|
+
$[21] = t7;
|
|
116
|
+
} else {
|
|
117
|
+
t7 = $[21];
|
|
118
|
+
}
|
|
119
|
+
return t7;
|
|
120
|
+
}
|
|
121
|
+
//# sourceMappingURL=use-puck-overlay.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-puck-overlay.js","names":["c","_c","useEffect","useState","usePathname","useRouter","useSearchParams","useScrollLockOutside","useAgentHandle","usePuckEditor","usePuckOverlay","t0","$","node","fieldName","isLoggedIn","searchParams","router","pathName","t1","get","puckDataParams","isEditMode","setIsEditMode","isEditorReady","setIsEditorReady","registerEditor","isHighlighted","t2","t3","t4","Symbol","for","openEditor","t5","has","newSearchParams","URLSearchParams","toString","delete","replace","scroll","refresh","closeEditor","t6","langcode","type","open","close","lang","t7"],"sources":["../../../src/puck-editor/internal/use-puck-overlay.ts"],"sourcesContent":["'use client';\n\nimport { useEffect, useState } from 'react';\nimport { usePathname, useRouter, useSearchParams } from 'next/navigation';\n\nimport { useScrollLockOutside } from './editor/use-scroll-lock-outside';\nimport { useAgentHandle } from './plugins/agent-plugin/use-agent-handle';\nimport { usePuckEditor } from './puck-editor-provider';\nimport { PuckNode } from './puck-node';\n\ntype UsePuckOverlayOptions = {\n node: PuckNode;\n fieldName: string;\n isLoggedIn: boolean;\n};\n\nexport function usePuckOverlay({\n node,\n fieldName,\n isLoggedIn,\n}: UsePuckOverlayOptions) {\n const searchParams = useSearchParams();\n const router = useRouter();\n const pathName = usePathname();\n const puckDataParams = searchParams.get('puckeditor');\n const [isEditMode, setIsEditMode] = useState(puckDataParams === fieldName);\n const [isEditorReady, setIsEditorReady] = useState(\n puckDataParams === fieldName\n );\n const { registerEditor, isHighlighted } = usePuckEditor();\n\n useEffect(() => {\n registerEditor(() => setIsEditMode(true));\n }, [registerEditor]);\n\n useScrollLockOutside(isEditMode, '[data-puck-editor-overlay]');\n\n const openEditor = () => setIsEditMode(true);\n\n const closeEditor = async () => {\n setIsEditMode(false);\n if (searchParams.has('puckeditor')) {\n const newSearchParams = new URLSearchParams(searchParams.toString());\n newSearchParams.delete('puckeditor');\n router.replace(`${pathName}?${newSearchParams.toString()}`, {\n scroll: true,\n });\n }\n router.refresh();\n };\n\n useAgentHandle({\n isLoggedIn,\n open: openEditor,\n close: closeEditor,\n isEditMode,\n type: node.type,\n fieldName,\n lang: node.langcode,\n });\n\n return {\n isEditMode,\n isEditorReady,\n setIsEditorReady,\n openEditor,\n closeEditor,\n isHighlighted,\n };\n}\n"],"mappings":"AAAA,YAAY;;AAAC,SAAAA,CAAA,IAAAC,EAAA;AAEb,SAASC,SAAS,EAAEC,QAAQ,QAAQ,OAAO;AAC3C,SAASC,WAAW,EAAEC,SAAS,EAAEC,eAAe,QAAQ,iBAAiB;AAEzE,SAASC,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;MAAA7B,UAAA;MAAAgC,IAAA,EAEPd,UAAU;MAAAe,KAAA,EACTL,WAAW;MAAArB,UAAA;MAAAwB,IAAA,EAEZjC,IAAI,CAAAiC,IAAK;MAAAhC,SAAA;MAAAmC,IAAA,EAETpC,IAAI,CAAAgC;IACZ,CAAC;IAAAjC,CAAA,OAAA+B,WAAA;IAAA/B,CAAA,OAAAE,SAAA;IAAAF,CAAA,OAAAU,UAAA;IAAAV,CAAA,OAAAG,UAAA;IAAAH,CAAA,OAAAC,IAAA,CAAAgC,QAAA;IAAAjC,CAAA,OAAAC,IAAA,CAAAiC,IAAA;IAAAlC,CAAA,OAAAgC,EAAA;EAAA;IAAAA,EAAA,GAAAhC,CAAA;EAAA;EARDJ,cAAc,CAACoC,EAQd,CAAC;EAAA,IAAAM,EAAA;EAAA,IAAAtC,CAAA,SAAA+B,WAAA,IAAA/B,CAAA,SAAAU,UAAA,IAAAV,CAAA,SAAAY,aAAA,IAAAZ,CAAA,SAAAe,aAAA;IAEKuB,EAAA;MAAA5B,UAAA;MAAAE,aAAA;MAAAC,gBAAA;MAAAQ,UAAA;MAAAU,WAAA;MAAAhB;IAOP,CAAC;IAAAf,CAAA,OAAA+B,WAAA;IAAA/B,CAAA,OAAAU,UAAA;IAAAV,CAAA,OAAAY,aAAA;IAAAZ,CAAA,OAAAe,aAAA;IAAAf,CAAA,OAAAsC,EAAA;EAAA;IAAAA,EAAA,GAAAtC,CAAA;EAAA;EAAA,OAPMsC,EAON;AAAA","ignoreList":[]}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { ComponentData, Config, Data, PuckAction } from '@puckeditor/core';
|
|
2
|
+
export declare const stripInstanceNames: (data: Data, config: Config) => Data;
|
|
3
|
+
export declare const generateId: (type?: string | number) => string;
|
|
4
|
+
export declare const appendComponents: (dispatch: (action: PuckAction) => void, zone: string, startIndex: number, content: ComponentData[]) => void;
|
|
5
|
+
export declare const generateTemplateIds: (template: ComponentData[], config: Config) => ComponentData[];
|
|
6
|
+
//# sourceMappingURL=utils.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../src/puck-editor/internal/utils.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAMhF,eAAO,MAAM,kBAAkB,GAAI,MAAM,IAAI,EAAE,QAAQ,MAAM,KAAG,IAUrD,CAAC;AAEZ,eAAO,MAAM,UAAU,GAAI,OAAO,MAAM,GAAG,MAAM,WAEhD,CAAC;AAEF,eAAO,MAAM,gBAAgB,GAC3B,UAAU,CAAC,MAAM,EAAE,UAAU,KAAK,IAAI,EACtC,MAAM,MAAM,EACZ,YAAY,MAAM,EAClB,SAAS,aAAa,EAAE,SAkBzB,CAAC;AAEF,eAAO,MAAM,mBAAmB,GAC9B,UAAU,aAAa,EAAE,EACzB,QAAQ,MAAM,oBAmBf,CAAC"}
|