@conloca/cms-spa 0.1.16 → 0.2.1
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 +1 -1
- package/dist/spa/main.css +3725 -3781
- package/dist/ts/App.d.ts +35 -0
- package/dist/ts/App.d.ts.map +1 -0
- package/dist/ts/App.js +53 -0
- package/dist/ts/App.js.map +1 -0
- package/dist/ts/CmsSpaApp.d.ts +13 -0
- package/dist/ts/CmsSpaApp.d.ts.map +1 -0
- package/dist/ts/CmsSpaApp.js +50 -0
- package/dist/ts/CmsSpaApp.js.map +1 -0
- package/dist/ts/components/CMSDashboard.d.ts +2 -0
- package/dist/ts/components/CMSDashboard.d.ts.map +1 -0
- package/dist/ts/components/CMSDashboard.js +21 -0
- package/dist/ts/components/CMSDashboard.js.map +1 -0
- package/dist/ts/components/CMSLayout.d.ts +2 -0
- package/dist/ts/components/CMSLayout.d.ts.map +1 -0
- package/dist/ts/components/CMSLayout.js +15 -0
- package/dist/ts/components/CMSLayout.js.map +1 -0
- package/dist/ts/components/ConlocaLogo.d.ts +2 -0
- package/dist/ts/components/ConlocaLogo.d.ts.map +1 -0
- package/dist/ts/components/ConlocaLogo.js +5 -0
- package/dist/ts/components/ConlocaLogo.js.map +1 -0
- package/dist/ts/components/GitStatusPanel.d.ts +21 -0
- package/dist/ts/components/GitStatusPanel.d.ts.map +1 -0
- package/dist/ts/components/GitStatusPanel.js +74 -0
- package/dist/ts/components/GitStatusPanel.js.map +1 -0
- package/dist/ts/components/MobileTopBar.d.ts +6 -0
- package/dist/ts/components/MobileTopBar.d.ts.map +1 -0
- package/dist/ts/components/MobileTopBar.js +7 -0
- package/dist/ts/components/MobileTopBar.js.map +1 -0
- package/dist/ts/components/Sidebar.d.ts +8 -0
- package/dist/ts/components/Sidebar.d.ts.map +1 -0
- package/dist/ts/components/Sidebar.js +41 -0
- package/dist/ts/components/Sidebar.js.map +1 -0
- package/dist/ts/components/UserAvatar.d.ts +2 -0
- package/dist/ts/components/UserAvatar.d.ts.map +1 -0
- package/dist/ts/components/UserAvatar.js +15 -0
- package/dist/ts/components/UserAvatar.js.map +1 -0
- package/dist/ts/components/cards/DataEntryCard.d.ts +14 -0
- package/dist/ts/components/cards/DataEntryCard.d.ts.map +1 -0
- package/dist/ts/components/cards/DataEntryCard.js +39 -0
- package/dist/ts/components/cards/DataEntryCard.js.map +1 -0
- package/dist/ts/components/cards/SectionCard.d.ts +15 -0
- package/dist/ts/components/cards/SectionCard.d.ts.map +1 -0
- package/dist/ts/components/cards/SectionCard.js +11 -0
- package/dist/ts/components/cards/SectionCard.js.map +1 -0
- package/dist/ts/components/cards/index.d.ts +2 -0
- package/dist/ts/components/cards/index.d.ts.map +1 -0
- package/dist/ts/components/cards/index.js +2 -0
- package/dist/ts/components/cards/index.js.map +1 -0
- package/dist/ts/components/dashboard/RecentActivity.d.ts +2 -0
- package/dist/ts/components/dashboard/RecentActivity.d.ts.map +1 -0
- package/dist/ts/components/dashboard/RecentActivity.js +58 -0
- package/dist/ts/components/dashboard/RecentActivity.js.map +1 -0
- package/dist/ts/components/dialog.d.ts +53 -0
- package/dist/ts/components/dialog.d.ts.map +1 -0
- package/dist/ts/components/dialog.js +57 -0
- package/dist/ts/components/dialog.js.map +1 -0
- package/dist/ts/components/dialogs/ConflictDialog.d.ts +10 -0
- package/dist/ts/components/dialogs/ConflictDialog.d.ts.map +1 -0
- package/dist/ts/components/dialogs/ConflictDialog.js +28 -0
- package/dist/ts/components/dialogs/ConflictDialog.js.map +1 -0
- package/dist/ts/components/dialogs/CreateDataDialog.d.ts +9 -0
- package/dist/ts/components/dialogs/CreateDataDialog.d.ts.map +1 -0
- package/dist/ts/components/dialogs/CreateDataDialog.js +21 -0
- package/dist/ts/components/dialogs/CreateDataDialog.js.map +1 -0
- package/dist/ts/components/dialogs/CreateFolderDialog.d.ts +11 -0
- package/dist/ts/components/dialogs/CreateFolderDialog.d.ts.map +1 -0
- package/dist/ts/components/dialogs/CreateFolderDialog.js +39 -0
- package/dist/ts/components/dialogs/CreateFolderDialog.js.map +1 -0
- package/dist/ts/components/dialogs/CreatePageDialog.d.ts +11 -0
- package/dist/ts/components/dialogs/CreatePageDialog.d.ts.map +1 -0
- package/dist/ts/components/dialogs/CreatePageDialog.js +237 -0
- package/dist/ts/components/dialogs/CreatePageDialog.js.map +1 -0
- package/dist/ts/components/dialogs/DataPropertiesDialog.d.ts +10 -0
- package/dist/ts/components/dialogs/DataPropertiesDialog.d.ts.map +1 -0
- package/dist/ts/components/dialogs/DataPropertiesDialog.js +39 -0
- package/dist/ts/components/dialogs/DataPropertiesDialog.js.map +1 -0
- package/dist/ts/components/dialogs/DeleteConfirmDialog.d.ts +12 -0
- package/dist/ts/components/dialogs/DeleteConfirmDialog.d.ts.map +1 -0
- package/dist/ts/components/dialogs/DeleteConfirmDialog.js +8 -0
- package/dist/ts/components/dialogs/DeleteConfirmDialog.js.map +1 -0
- package/dist/ts/components/dialogs/ErrorModal.d.ts +14 -0
- package/dist/ts/components/dialogs/ErrorModal.d.ts.map +1 -0
- package/dist/ts/components/dialogs/ErrorModal.js +43 -0
- package/dist/ts/components/dialogs/ErrorModal.js.map +1 -0
- package/dist/ts/components/dialogs/FragmentPropertiesDialog.d.ts +12 -0
- package/dist/ts/components/dialogs/FragmentPropertiesDialog.d.ts.map +1 -0
- package/dist/ts/components/dialogs/FragmentPropertiesDialog.js +43 -0
- package/dist/ts/components/dialogs/FragmentPropertiesDialog.js.map +1 -0
- package/dist/ts/components/dialogs/MoveFolderDialog.d.ts +12 -0
- package/dist/ts/components/dialogs/MoveFolderDialog.d.ts.map +1 -0
- package/dist/ts/components/dialogs/MoveFolderDialog.js +69 -0
- package/dist/ts/components/dialogs/MoveFolderDialog.js.map +1 -0
- package/dist/ts/components/dialogs/PageMetadataDialog.d.ts +31 -0
- package/dist/ts/components/dialogs/PageMetadataDialog.d.ts.map +1 -0
- package/dist/ts/components/dialogs/PageMetadataDialog.js +154 -0
- package/dist/ts/components/dialogs/PageMetadataDialog.js.map +1 -0
- package/dist/ts/components/dialogs/UnsavedChangesDialog.d.ts +8 -0
- package/dist/ts/components/dialogs/UnsavedChangesDialog.d.ts.map +1 -0
- package/dist/ts/components/dialogs/UnsavedChangesDialog.js +7 -0
- package/dist/ts/components/dialogs/UnsavedChangesDialog.js.map +1 -0
- package/dist/ts/components/dialogs/index.d.ts +9 -0
- package/dist/ts/components/dialogs/index.d.ts.map +1 -0
- package/dist/ts/components/dialogs/index.js +9 -0
- package/dist/ts/components/dialogs/index.js.map +1 -0
- package/dist/ts/components/editor/CMSMDXEditor.d.ts +14 -0
- package/dist/ts/components/editor/CMSMDXEditor.d.ts.map +1 -0
- package/dist/ts/components/editor/CMSMDXEditor.js +209 -0
- package/dist/ts/components/editor/CMSMDXEditor.js.map +1 -0
- package/dist/ts/components/editor/ContentDiff.d.ts +10 -0
- package/dist/ts/components/editor/ContentDiff.d.ts.map +1 -0
- package/dist/ts/components/editor/ContentDiff.js +52 -0
- package/dist/ts/components/editor/ContentDiff.js.map +1 -0
- package/dist/ts/components/editor/CreateFragmentDialog.d.ts +26 -0
- package/dist/ts/components/editor/CreateFragmentDialog.d.ts.map +1 -0
- package/dist/ts/components/editor/CreateFragmentDialog.js +159 -0
- package/dist/ts/components/editor/CreateFragmentDialog.js.map +1 -0
- package/dist/ts/components/editor/DrawerItemOverride.d.ts +8 -0
- package/dist/ts/components/editor/DrawerItemOverride.d.ts.map +1 -0
- package/dist/ts/components/editor/DrawerItemOverride.js +37 -0
- package/dist/ts/components/editor/DrawerItemOverride.js.map +1 -0
- package/dist/ts/components/editor/EditorChromeToggles.d.ts +16 -0
- package/dist/ts/components/editor/EditorChromeToggles.d.ts.map +1 -0
- package/dist/ts/components/editor/EditorChromeToggles.js +17 -0
- package/dist/ts/components/editor/EditorChromeToggles.js.map +1 -0
- package/dist/ts/components/editor/FragmentEditor.d.ts +15 -0
- package/dist/ts/components/editor/FragmentEditor.d.ts.map +1 -0
- package/dist/ts/components/editor/FragmentEditor.js +322 -0
- package/dist/ts/components/editor/FragmentEditor.js.map +1 -0
- package/dist/ts/components/editor/FragmentWrappers.d.ts +20 -0
- package/dist/ts/components/editor/FragmentWrappers.d.ts.map +1 -0
- package/dist/ts/components/editor/FragmentWrappers.js +44 -0
- package/dist/ts/components/editor/FragmentWrappers.js.map +1 -0
- package/dist/ts/components/editor/GenericBlock.d.ts +3 -0
- package/dist/ts/components/editor/GenericBlock.d.ts.map +1 -0
- package/dist/ts/components/editor/GenericBlock.js +1124 -0
- package/dist/ts/components/editor/GenericBlock.js.map +1 -0
- package/dist/ts/components/editor/ImagePickerDialog.d.ts +6 -0
- package/dist/ts/components/editor/ImagePickerDialog.d.ts.map +1 -0
- package/dist/ts/components/editor/ImagePickerDialog.js +23 -0
- package/dist/ts/components/editor/ImagePickerDialog.js.map +1 -0
- package/dist/ts/components/editor/JsxPropsPanel.d.ts +16 -0
- package/dist/ts/components/editor/JsxPropsPanel.d.ts.map +1 -0
- package/dist/ts/components/editor/JsxPropsPanel.js +146 -0
- package/dist/ts/components/editor/JsxPropsPanel.js.map +1 -0
- package/dist/ts/components/editor/LocaleSelector.d.ts +9 -0
- package/dist/ts/components/editor/LocaleSelector.d.ts.map +1 -0
- package/dist/ts/components/editor/LocaleSelector.js +14 -0
- package/dist/ts/components/editor/LocaleSelector.js.map +1 -0
- package/dist/ts/components/editor/MDXLivePreview.d.ts +15 -0
- package/dist/ts/components/editor/MDXLivePreview.d.ts.map +1 -0
- package/dist/ts/components/editor/MDXLivePreview.js +111 -0
- package/dist/ts/components/editor/MDXLivePreview.js.map +1 -0
- package/dist/ts/components/editor/MdxPageEditor.d.ts +10 -0
- package/dist/ts/components/editor/MdxPageEditor.d.ts.map +1 -0
- package/dist/ts/components/editor/MdxPageEditor.js +353 -0
- package/dist/ts/components/editor/MdxPageEditor.js.map +1 -0
- package/dist/ts/components/editor/PageEditor.d.ts +54 -0
- package/dist/ts/components/editor/PageEditor.d.ts.map +1 -0
- package/dist/ts/components/editor/PageEditor.js +399 -0
- package/dist/ts/components/editor/PageEditor.js.map +1 -0
- package/dist/ts/components/editor/PageEditorHeaderActions.d.ts +22 -0
- package/dist/ts/components/editor/PageEditorHeaderActions.d.ts.map +1 -0
- package/dist/ts/components/editor/PageEditorHeaderActions.js +24 -0
- package/dist/ts/components/editor/PageEditorHeaderActions.js.map +1 -0
- package/dist/ts/components/editor/PageEditorWrapper.d.ts +38 -0
- package/dist/ts/components/editor/PageEditorWrapper.d.ts.map +1 -0
- package/dist/ts/components/editor/PageEditorWrapper.js +360 -0
- package/dist/ts/components/editor/PageEditorWrapper.js.map +1 -0
- package/dist/ts/components/editor/PuckWithUntouchedMetadata.d.ts +5 -0
- package/dist/ts/components/editor/PuckWithUntouchedMetadata.d.ts.map +1 -0
- package/dist/ts/components/editor/PuckWithUntouchedMetadata.js +53 -0
- package/dist/ts/components/editor/PuckWithUntouchedMetadata.js.map +1 -0
- package/dist/ts/components/editor/SearchableSelect.d.ts +34 -0
- package/dist/ts/components/editor/SearchableSelect.d.ts.map +1 -0
- package/dist/ts/components/editor/SearchableSelect.js +116 -0
- package/dist/ts/components/editor/SearchableSelect.js.map +1 -0
- package/dist/ts/components/editor/host-wrapper-plugin.d.ts.map +1 -0
- package/dist/ts/components/editor/host-wrapper-plugin.js +38 -0
- package/dist/ts/components/editor/host-wrapper-plugin.js.map +1 -0
- package/dist/ts/components/editor/index.d.ts +9 -0
- package/dist/ts/components/editor/index.d.ts.map +1 -0
- package/dist/ts/components/editor/index.js +8 -0
- package/dist/ts/components/editor/index.js.map +1 -0
- package/dist/ts/components/editor/insert-menu/InsertMdxComponentButton.d.ts +15 -0
- package/dist/ts/components/editor/insert-menu/InsertMdxComponentButton.d.ts.map +1 -0
- package/dist/ts/components/editor/insert-menu/InsertMdxComponentButton.js +91 -0
- package/dist/ts/components/editor/insert-menu/InsertMdxComponentButton.js.map +1 -0
- package/dist/ts/components/editor/insert-menu/SlashMenuPlugin.d.ts +12 -0
- package/dist/ts/components/editor/insert-menu/SlashMenuPlugin.d.ts.map +1 -0
- package/dist/ts/components/editor/insert-menu/SlashMenuPlugin.js +107 -0
- package/dist/ts/components/editor/insert-menu/SlashMenuPlugin.js.map +1 -0
- package/dist/ts/components/editor/insert-menu/insert-payload.d.ts +76 -0
- package/dist/ts/components/editor/insert-menu/insert-payload.d.ts.map +1 -0
- package/dist/ts/components/editor/insert-menu/insert-payload.js +95 -0
- package/dist/ts/components/editor/insert-menu/insert-payload.js.map +1 -0
- package/dist/ts/components/editor/insert-menu/mdx-components-plugin.d.ts.map +1 -0
- package/dist/ts/components/editor/insert-menu/mdx-components-plugin.js +14 -0
- package/dist/ts/components/editor/insert-menu/mdx-components-plugin.js.map +1 -0
- package/dist/ts/components/editor/page-setting-targets.d.ts +24 -0
- package/dist/ts/components/editor/page-setting-targets.d.ts.map +1 -0
- package/dist/ts/components/editor/page-setting-targets.js +124 -0
- package/dist/ts/components/editor/page-setting-targets.js.map +1 -0
- package/dist/ts/components/editor/preview-availability.d.ts +18 -0
- package/dist/ts/components/editor/preview-availability.d.ts.map +1 -0
- package/dist/ts/components/editor/preview-availability.js +18 -0
- package/dist/ts/components/editor/preview-availability.js.map +1 -0
- package/dist/ts/components/editors/DataEditor.d.ts +18 -0
- package/dist/ts/components/editors/DataEditor.d.ts.map +1 -0
- package/dist/ts/components/editors/DataEditor.js +140 -0
- package/dist/ts/components/editors/DataEditor.js.map +1 -0
- package/dist/ts/components/fields/ContentFragmentSelectorField.d.ts +14 -0
- package/dist/ts/components/fields/ContentFragmentSelectorField.d.ts.map +1 -0
- package/dist/ts/components/fields/ContentFragmentSelectorField.js +108 -0
- package/dist/ts/components/fields/ContentFragmentSelectorField.js.map +1 -0
- package/dist/ts/components/fields/ImageField.d.ts +17 -0
- package/dist/ts/components/fields/ImageField.d.ts.map +1 -0
- package/dist/ts/components/fields/ImageField.js +39 -0
- package/dist/ts/components/fields/ImageField.js.map +1 -0
- package/dist/ts/components/fields/MDXEditField.d.ts +17 -0
- package/dist/ts/components/fields/MDXEditField.d.ts.map +1 -0
- package/dist/ts/components/fields/MDXEditField.js +29 -0
- package/dist/ts/components/fields/MDXEditField.js.map +1 -0
- package/dist/ts/components/forms/ChipArrayField.d.ts +12 -0
- package/dist/ts/components/forms/ChipArrayField.d.ts.map +1 -0
- package/dist/ts/components/forms/ChipArrayField.js +39 -0
- package/dist/ts/components/forms/ChipArrayField.js.map +1 -0
- package/dist/ts/components/forms/HintForm.d.ts +22 -0
- package/dist/ts/components/forms/HintForm.d.ts.map +1 -0
- package/dist/ts/components/forms/HintForm.js +195 -0
- package/dist/ts/components/forms/HintForm.js.map +1 -0
- package/dist/ts/components/forms/SchemaForm.d.ts +15 -0
- package/dist/ts/components/forms/SchemaForm.d.ts.map +1 -0
- package/dist/ts/components/forms/SchemaForm.js +103 -0
- package/dist/ts/components/forms/SchemaForm.js.map +1 -0
- package/dist/ts/components/index.d.ts +8 -0
- package/dist/ts/components/index.d.ts.map +1 -0
- package/dist/ts/components/index.js +14 -0
- package/dist/ts/components/index.js.map +1 -0
- package/dist/ts/components/media/AssetCard.d.ts +14 -0
- package/dist/ts/components/media/AssetCard.d.ts.map +1 -0
- package/dist/ts/components/media/AssetCard.js +26 -0
- package/dist/ts/components/media/AssetCard.js.map +1 -0
- package/dist/ts/components/media/AssetDetailSidebar.d.ts +15 -0
- package/dist/ts/components/media/AssetDetailSidebar.d.ts.map +1 -0
- package/dist/ts/components/media/AssetDetailSidebar.js +122 -0
- package/dist/ts/components/media/AssetDetailSidebar.js.map +1 -0
- package/dist/ts/components/media/BulkActionBar.d.ts +9 -0
- package/dist/ts/components/media/BulkActionBar.d.ts.map +1 -0
- package/dist/ts/components/media/BulkActionBar.js +9 -0
- package/dist/ts/components/media/BulkActionBar.js.map +1 -0
- package/dist/ts/components/media/FolderNav.d.ts +7 -0
- package/dist/ts/components/media/FolderNav.d.ts.map +1 -0
- package/dist/ts/components/media/FolderNav.js +13 -0
- package/dist/ts/components/media/FolderNav.js.map +1 -0
- package/dist/ts/components/media/FolderTreeSidebar.d.ts +9 -0
- package/dist/ts/components/media/FolderTreeSidebar.d.ts.map +1 -0
- package/dist/ts/components/media/FolderTreeSidebar.js +46 -0
- package/dist/ts/components/media/FolderTreeSidebar.js.map +1 -0
- package/dist/ts/components/media/ImagePicker.d.ts +14 -0
- package/dist/ts/components/media/ImagePicker.d.ts.map +1 -0
- package/dist/ts/components/media/ImagePicker.js +44 -0
- package/dist/ts/components/media/ImagePicker.js.map +1 -0
- package/dist/ts/components/media/MediaLibrary.d.ts +31 -0
- package/dist/ts/components/media/MediaLibrary.d.ts.map +1 -0
- package/dist/ts/components/media/MediaLibrary.js +87 -0
- package/dist/ts/components/media/MediaLibrary.js.map +1 -0
- package/dist/ts/components/media/MediaToolbar.d.ts +21 -0
- package/dist/ts/components/media/MediaToolbar.d.ts.map +1 -0
- package/dist/ts/components/media/MediaToolbar.js +7 -0
- package/dist/ts/components/media/MediaToolbar.js.map +1 -0
- package/dist/ts/components/media/UploadModal.d.ts +9 -0
- package/dist/ts/components/media/UploadModal.d.ts.map +1 -0
- package/dist/ts/components/media/UploadModal.js +36 -0
- package/dist/ts/components/media/UploadModal.js.map +1 -0
- package/dist/ts/components/media/index.d.ts +10 -0
- package/dist/ts/components/media/index.d.ts.map +1 -0
- package/dist/ts/components/media/index.js +10 -0
- package/dist/ts/components/media/index.js.map +1 -0
- package/dist/ts/components/pages/DataList.d.ts +7 -0
- package/dist/ts/components/pages/DataList.d.ts.map +1 -0
- package/dist/ts/components/pages/DataList.js +269 -0
- package/dist/ts/components/pages/DataList.js.map +1 -0
- package/dist/ts/components/pages/FragmentList.d.ts +2 -0
- package/dist/ts/components/pages/FragmentList.d.ts.map +1 -0
- package/dist/ts/components/pages/FragmentList.js +281 -0
- package/dist/ts/components/pages/FragmentList.js.map +1 -0
- package/dist/ts/components/pages/MediaPage.d.ts +8 -0
- package/dist/ts/components/pages/MediaPage.d.ts.map +1 -0
- package/dist/ts/components/pages/MediaPage.js +146 -0
- package/dist/ts/components/pages/MediaPage.js.map +1 -0
- package/dist/ts/components/pages/PageList.d.ts +7 -0
- package/dist/ts/components/pages/PageList.d.ts.map +1 -0
- package/dist/ts/components/pages/PageList.js +299 -0
- package/dist/ts/components/pages/PageList.js.map +1 -0
- package/dist/ts/components/pages/index.d.ts +3 -0
- package/dist/ts/components/pages/index.d.ts.map +1 -0
- package/dist/ts/components/pages/index.js +3 -0
- package/dist/ts/components/pages/index.js.map +1 -0
- package/dist/ts/components/puck/MDXContent.d.ts +19 -0
- package/dist/ts/components/puck/MDXContent.d.ts.map +1 -0
- package/dist/ts/components/puck/MDXContent.js +110 -0
- package/dist/ts/components/puck/MDXContent.js.map +1 -0
- package/dist/ts/components/puck/index.d.ts +2 -0
- package/dist/ts/components/puck/index.d.ts.map +1 -0
- package/dist/ts/components/puck/index.js +2 -0
- package/dist/ts/components/puck/index.js.map +1 -0
- package/dist/ts/components/sandbox/ContentSandbox.d.ts +31 -0
- package/dist/ts/components/sandbox/ContentSandbox.d.ts.map +1 -0
- package/dist/ts/components/sandbox/ContentSandbox.js +148 -0
- package/dist/ts/components/sandbox/ContentSandbox.js.map +1 -0
- package/dist/ts/components/sandbox/frame-runtime.d.ts +7 -0
- package/dist/ts/components/sandbox/frame-runtime.d.ts.map +1 -0
- package/dist/ts/components/sandbox/frame-runtime.js +7 -0
- package/dist/ts/components/sandbox/frame-runtime.js.map +1 -0
- package/dist/ts/components/toast.d.ts +44 -0
- package/dist/ts/components/toast.d.ts.map +1 -0
- package/dist/ts/components/toast.js +8 -0
- package/dist/ts/components/toast.js.map +1 -0
- package/dist/ts/components/ui/Banner.d.ts +76 -0
- package/dist/ts/components/ui/Banner.d.ts.map +1 -0
- package/dist/ts/components/ui/Banner.js +50 -0
- package/dist/ts/components/ui/Banner.js.map +1 -0
- package/dist/ts/components/ui/Button.d.ts +25 -0
- package/dist/ts/components/ui/Button.d.ts.map +1 -0
- package/dist/ts/components/ui/Button.js +34 -0
- package/dist/ts/components/ui/Button.js.map +1 -0
- package/dist/ts/components/ui/Card.d.ts +72 -0
- package/dist/ts/components/ui/Card.d.ts.map +1 -0
- package/dist/ts/components/ui/Card.js +50 -0
- package/dist/ts/components/ui/Card.js.map +1 -0
- package/dist/ts/components/ui/FieldError.d.ts +24 -0
- package/dist/ts/components/ui/FieldError.d.ts.map +1 -0
- package/dist/ts/components/ui/FieldError.js +18 -0
- package/dist/ts/components/ui/FieldError.js.map +1 -0
- package/dist/ts/components/ui/IconButton.d.ts +13 -0
- package/dist/ts/components/ui/IconButton.d.ts.map +1 -0
- package/dist/ts/components/ui/IconButton.js +11 -0
- package/dist/ts/components/ui/IconButton.js.map +1 -0
- package/dist/ts/components/ui/Input.d.ts +37 -0
- package/dist/ts/components/ui/Input.d.ts.map +1 -0
- package/dist/ts/components/ui/Input.js +10 -0
- package/dist/ts/components/ui/Input.js.map +1 -0
- package/dist/ts/components/ui/SaveIndicator.d.ts +8 -0
- package/dist/ts/components/ui/SaveIndicator.d.ts.map +1 -0
- package/dist/ts/components/ui/SaveIndicator.js +33 -0
- package/dist/ts/components/ui/SaveIndicator.js.map +1 -0
- package/dist/ts/components/ui/Select.d.ts +8 -0
- package/dist/ts/components/ui/Select.d.ts.map +1 -0
- package/dist/ts/components/ui/Select.js +10 -0
- package/dist/ts/components/ui/Select.js.map +1 -0
- package/dist/ts/components/ui/Separator.d.ts +7 -0
- package/dist/ts/components/ui/Separator.d.ts.map +1 -0
- package/dist/ts/components/ui/Separator.js +9 -0
- package/dist/ts/components/ui/Separator.js.map +1 -0
- package/dist/ts/components/ui/Textarea.d.ts +8 -0
- package/dist/ts/components/ui/Textarea.d.ts.map +1 -0
- package/dist/ts/components/ui/Textarea.js +6 -0
- package/dist/ts/components/ui/Textarea.js.map +1 -0
- package/dist/ts/components/ui/Tooltip.d.ts +9 -0
- package/dist/ts/components/ui/Tooltip.d.ts.map +1 -0
- package/dist/ts/components/ui/Tooltip.js +6 -0
- package/dist/ts/components/ui/Tooltip.js.map +1 -0
- package/dist/ts/components/ui/index.d.ts +14 -0
- package/dist/ts/components/ui/index.d.ts.map +1 -0
- package/dist/ts/components/ui/index.js +18 -0
- package/dist/ts/components/ui/index.js.map +1 -0
- package/dist/ts/data-schemas.d.ts +36 -0
- package/dist/ts/data-schemas.d.ts.map +1 -0
- package/dist/ts/data-schemas.js +52 -0
- package/dist/ts/data-schemas.js.map +1 -0
- package/dist/ts/dev-entry.d.ts +2 -0
- package/dist/ts/dev-entry.d.ts.map +1 -0
- package/dist/ts/dev-entry.js +23 -0
- package/dist/ts/dev-entry.js.map +1 -0
- package/dist/ts/editor-flush.d.ts +26 -0
- package/dist/ts/editor-flush.d.ts.map +1 -0
- package/dist/ts/editor-flush.js +40 -0
- package/dist/ts/editor-flush.js.map +1 -0
- package/dist/ts/hooks/index.d.ts +10 -0
- package/dist/ts/hooks/index.d.ts.map +1 -0
- package/dist/ts/hooks/index.js +8 -0
- package/dist/ts/hooks/index.js.map +1 -0
- package/dist/ts/hooks/useCanvasTheme.d.ts +12 -0
- package/dist/ts/hooks/useCanvasTheme.d.ts.map +1 -0
- package/dist/ts/hooks/useCanvasTheme.js +34 -0
- package/dist/ts/hooks/useCanvasTheme.js.map +1 -0
- package/dist/ts/hooks/useClickOutside.d.ts.map +1 -0
- package/dist/ts/hooks/useClickOutside.js +19 -0
- package/dist/ts/hooks/useClickOutside.js.map +1 -0
- package/dist/ts/hooks/useDialogState.d.ts.map +1 -0
- package/dist/ts/hooks/useDialogState.js +32 -0
- package/dist/ts/hooks/useDialogState.js.map +1 -0
- package/dist/ts/hooks/useEditorPref.d.ts.map +1 -0
- package/dist/ts/hooks/useEditorPref.js +50 -0
- package/dist/ts/hooks/useEditorPref.js.map +1 -0
- package/dist/ts/hooks/useErrorModal.d.ts +15 -0
- package/dist/ts/hooks/useErrorModal.d.ts.map +1 -0
- package/dist/ts/hooks/useErrorModal.js +36 -0
- package/dist/ts/hooks/useErrorModal.js.map +1 -0
- package/dist/ts/hooks/useSiteBaseUrl.d.ts +10 -0
- package/dist/ts/hooks/useSiteBaseUrl.d.ts.map +1 -0
- package/dist/ts/hooks/useSiteBaseUrl.js +15 -0
- package/dist/ts/hooks/useSiteBaseUrl.js.map +1 -0
- package/dist/ts/hooks/useTheme.d.ts +12 -0
- package/dist/ts/hooks/useTheme.d.ts.map +1 -0
- package/dist/ts/hooks/useTheme.js +55 -0
- package/dist/ts/hooks/useTheme.js.map +1 -0
- package/dist/ts/hooks/useUnsavedChangesGuard.d.ts.map +1 -0
- package/dist/ts/hooks/useUnsavedChangesGuard.js +30 -0
- package/dist/ts/hooks/useUnsavedChangesGuard.js.map +1 -0
- package/dist/ts/hooks/useUpload.d.ts +5 -0
- package/dist/ts/hooks/useUpload.d.ts.map +1 -0
- package/dist/ts/hooks/useUpload.js +15 -0
- package/dist/ts/hooks/useUpload.js.map +1 -0
- package/dist/ts/hooks/useUploadFlow.d.ts +47 -0
- package/dist/ts/hooks/useUploadFlow.d.ts.map +1 -0
- package/dist/ts/hooks/useUploadFlow.js +154 -0
- package/dist/ts/hooks/useUploadFlow.js.map +1 -0
- package/dist/ts/host-discovery.d.ts +40 -0
- package/dist/ts/host-discovery.d.ts.map +1 -0
- package/dist/ts/host-discovery.js +39 -0
- package/dist/ts/host-discovery.js.map +1 -0
- package/dist/ts/host-style-probe.d.ts +81 -0
- package/dist/ts/host-style-probe.d.ts.map +1 -0
- package/dist/ts/host-style-probe.js +638 -0
- package/dist/ts/host-style-probe.js.map +1 -0
- package/dist/ts/index.d.ts +13 -0
- package/dist/ts/index.d.ts.map +1 -0
- package/dist/ts/index.js +17 -0
- package/dist/ts/index.js.map +1 -0
- package/dist/ts/lib/utils.d.ts.map +1 -0
- package/dist/ts/lib/utils.js +48 -0
- package/dist/ts/lib/utils.js.map +1 -0
- package/dist/ts/main-spa.d.ts.map +1 -0
- package/dist/ts/main-spa.js +57 -0
- package/dist/ts/main-spa.js.map +1 -0
- package/dist/ts/main.d.ts.map +1 -0
- package/dist/ts/main.js +16 -0
- package/dist/ts/main.js.map +1 -0
- package/dist/ts/mdx-components-define.d.ts +185 -0
- package/dist/ts/mdx-components-define.d.ts.map +1 -0
- package/dist/ts/mdx-components-define.js +140 -0
- package/dist/ts/mdx-components-define.js.map +1 -0
- package/dist/ts/mdx-components.d.ts +63 -0
- package/dist/ts/mdx-components.d.ts.map +1 -0
- package/dist/ts/mdx-components.js +129 -0
- package/dist/ts/mdx-components.js.map +1 -0
- package/dist/ts/media/AssetScopePill.d.ts +30 -0
- package/dist/ts/media/AssetScopePill.d.ts.map +1 -0
- package/dist/ts/media/AssetScopePill.js +31 -0
- package/dist/ts/media/AssetScopePill.js.map +1 -0
- package/dist/ts/media/MediaIssueBadge.d.ts +33 -0
- package/dist/ts/media/MediaIssueBadge.d.ts.map +1 -0
- package/dist/ts/media/MediaIssueBadge.js +55 -0
- package/dist/ts/media/MediaIssueBadge.js.map +1 -0
- package/dist/ts/media/types.d.ts +108 -0
- package/dist/ts/media/types.d.ts.map +1 -0
- package/dist/ts/media/types.js +2 -0
- package/dist/ts/media/types.js.map +1 -0
- package/dist/ts/media/use-asset-scope.d.ts +24 -0
- package/dist/ts/media/use-asset-scope.d.ts.map +1 -0
- package/dist/ts/media/use-asset-scope.js +57 -0
- package/dist/ts/media/use-asset-scope.js.map +1 -0
- package/dist/ts/media/use-media-issue.d.ts +24 -0
- package/dist/ts/media/use-media-issue.d.ts.map +1 -0
- package/dist/ts/media/use-media-issue.js +52 -0
- package/dist/ts/media/use-media-issue.js.map +1 -0
- package/dist/ts/merge-default-props.d.ts +23 -0
- package/dist/ts/merge-default-props.d.ts.map +1 -0
- package/dist/ts/merge-default-props.js +51 -0
- package/dist/ts/merge-default-props.js.map +1 -0
- package/dist/ts/mock-puck-config.d.ts.map +1 -0
- package/dist/ts/mock-puck-config.js +74 -0
- package/dist/ts/mock-puck-config.js.map +1 -0
- package/dist/ts/page-schema-define.d.ts +134 -0
- package/dist/ts/page-schema-define.d.ts.map +1 -0
- package/dist/ts/page-schema-define.js +60 -0
- package/dist/ts/page-schema-define.js.map +1 -0
- package/dist/ts/page-schemas.d.ts +31 -0
- package/dist/ts/page-schemas.d.ts.map +1 -0
- package/dist/ts/page-schemas.js +56 -0
- package/dist/ts/page-schemas.js.map +1 -0
- package/dist/ts/page-setting-attributes.d.ts +27 -0
- package/dist/ts/page-setting-attributes.d.ts.map +1 -0
- package/dist/ts/page-setting-attributes.js +11 -0
- package/dist/ts/page-setting-attributes.js.map +1 -0
- package/dist/ts/prose-surface-css.d.ts +92 -0
- package/dist/ts/prose-surface-css.d.ts.map +1 -0
- package/dist/ts/prose-surface-css.js +349 -0
- package/dist/ts/prose-surface-css.js.map +1 -0
- package/dist/ts/puck-config.d.ts.map +1 -0
- package/dist/ts/puck-config.js +51 -0
- package/dist/ts/puck-config.js.map +1 -0
- package/dist/ts/sandbox-preview-styles.d.ts +63 -0
- package/dist/ts/sandbox-preview-styles.d.ts.map +1 -0
- package/dist/ts/sandbox-preview-styles.js +169 -0
- package/dist/ts/sandbox-preview-styles.js.map +1 -0
- package/dist/ts/selected-block.d.ts +61 -0
- package/dist/ts/selected-block.d.ts.map +1 -0
- package/dist/ts/selected-block.js +65 -0
- package/dist/ts/selected-block.js.map +1 -0
- package/dist/ts/site-css-layer.d.ts +40 -0
- package/dist/ts/site-css-layer.d.ts.map +1 -0
- package/dist/ts/site-css-layer.js +110 -0
- package/dist/ts/site-css-layer.js.map +1 -0
- package/dist/ts/site-styles.d.ts +142 -0
- package/dist/ts/site-styles.d.ts.map +1 -0
- package/dist/ts/site-styles.js +428 -0
- package/dist/ts/site-styles.js.map +1 -0
- package/dist/ts/theme.d.ts +46 -0
- package/dist/ts/theme.d.ts.map +1 -0
- package/dist/ts/theme.js +96 -0
- package/dist/ts/theme.js.map +1 -0
- package/dist/ts/types.d.ts +58 -0
- package/dist/ts/types.d.ts.map +1 -0
- package/dist/ts/types.js +2 -0
- package/dist/ts/types.js.map +1 -0
- package/dist/ts/ui-config.d.ts +256 -0
- package/dist/ts/ui-config.d.ts.map +1 -0
- package/dist/ts/ui-config.js +151 -0
- package/dist/ts/ui-config.js.map +1 -0
- package/dist/ts/utils/asset-url.d.ts +9 -0
- package/dist/ts/utils/asset-url.d.ts.map +1 -0
- package/dist/ts/utils/asset-url.js +19 -0
- package/dist/ts/utils/asset-url.js.map +1 -0
- package/dist/ts/utils/cn.d.ts.map +1 -0
- package/dist/ts/utils/cn.js +6 -0
- package/dist/ts/utils/cn.js.map +1 -0
- package/dist/ts/utils/content-failure.d.ts +32 -0
- package/dist/ts/utils/content-failure.d.ts.map +1 -0
- package/dist/ts/utils/content-failure.js +67 -0
- package/dist/ts/utils/content-failure.js.map +1 -0
- package/dist/ts/utils/entry-meta.d.ts +29 -0
- package/dist/ts/utils/entry-meta.d.ts.map +1 -0
- package/dist/ts/utils/entry-meta.js +38 -0
- package/dist/ts/utils/entry-meta.js.map +1 -0
- package/dist/ts/utils/entry-name.d.ts +11 -0
- package/dist/ts/utils/entry-name.d.ts.map +1 -0
- package/dist/ts/utils/entry-name.js +19 -0
- package/dist/ts/utils/entry-name.js.map +1 -0
- package/dist/ts/utils/format-date.d.ts.map +1 -0
- package/dist/ts/utils/format-date.js +38 -0
- package/dist/ts/utils/format-date.js.map +1 -0
- package/dist/ts/utils/mdast-to-html.d.ts.map +1 -0
- package/dist/ts/utils/mdast-to-html.js +235 -0
- package/dist/ts/utils/mdast-to-html.js.map +1 -0
- package/dist/ts/utils/mdast-tree.d.ts.map +1 -0
- package/dist/ts/utils/mdast-tree.js +286 -0
- package/dist/ts/utils/mdast-tree.js.map +1 -0
- package/dist/ts/utils/menu-placement.d.ts +8 -0
- package/dist/ts/utils/menu-placement.d.ts.map +1 -0
- package/dist/ts/utils/menu-placement.js +10 -0
- package/dist/ts/utils/menu-placement.js.map +1 -0
- package/dist/ts/utils/pageMetadata.d.ts +80 -0
- package/dist/ts/utils/pageMetadata.d.ts.map +1 -0
- package/dist/ts/utils/pageMetadata.js +249 -0
- package/dist/ts/utils/pageMetadata.js.map +1 -0
- package/dist/ts/utils/sanitize-html.d.ts +31 -0
- package/dist/ts/utils/sanitize-html.d.ts.map +1 -0
- package/dist/ts/utils/sanitize-html.js +84 -0
- package/dist/ts/utils/sanitize-html.js.map +1 -0
- package/dist/ts/utils/slugify.d.ts +14 -0
- package/dist/ts/utils/slugify.d.ts.map +1 -0
- package/dist/ts/utils/slugify.js +22 -0
- package/dist/ts/utils/slugify.js.map +1 -0
- package/dist/ts/utils/zodIntrospect.d.ts +19 -0
- package/dist/ts/utils/zodIntrospect.d.ts.map +1 -0
- package/dist/ts/utils/zodIntrospect.js +95 -0
- package/dist/ts/utils/zodIntrospect.js.map +1 -0
- package/dist/ts/write-access.d.ts +48 -0
- package/dist/ts/write-access.d.ts.map +1 -0
- package/dist/ts/write-access.js +140 -0
- package/dist/ts/write-access.js.map +1 -0
- package/package.json +145 -98
- package/src/App.tsx +78 -0
- package/src/CmsSpaApp.tsx +63 -0
- package/src/components/CMSDashboard.tsx +118 -0
- package/src/components/CMSLayout.tsx +25 -0
- package/src/components/ConlocaLogo.tsx +10 -0
- package/src/components/GitStatusPanel.tsx +188 -0
- package/src/components/MobileTopBar.tsx +22 -0
- package/src/components/Sidebar.tsx +146 -0
- package/src/components/UserAvatar.tsx +28 -0
- package/src/components/cards/DataEntryCard.tsx +163 -0
- package/src/components/cards/SectionCard.tsx +103 -0
- package/src/components/cards/index.ts +1 -0
- package/src/components/dashboard/RecentActivity.tsx +114 -0
- package/src/components/dialog.tsx +78 -0
- package/src/components/dialogs/ConflictDialog.tsx +139 -0
- package/src/components/dialogs/CreateDataDialog.tsx +70 -0
- package/src/components/dialogs/CreateFolderDialog.tsx +94 -0
- package/src/components/dialogs/CreatePageDialog.tsx +465 -0
- package/src/components/dialogs/DataPropertiesDialog.tsx +84 -0
- package/src/components/dialogs/DeleteConfirmDialog.tsx +61 -0
- package/src/components/dialogs/ErrorModal.tsx +109 -0
- package/src/components/dialogs/FragmentPropertiesDialog.tsx +97 -0
- package/src/components/dialogs/MoveFolderDialog.tsx +205 -0
- package/src/components/dialogs/PageMetadataDialog.tsx +311 -0
- package/src/components/dialogs/UnsavedChangesDialog.tsx +43 -0
- package/src/components/dialogs/index.ts +8 -0
- package/src/components/editor/CMSMDXEditor.tsx +281 -0
- package/src/components/editor/ContentDiff.tsx +251 -0
- package/src/components/editor/CreateFragmentDialog.tsx +227 -0
- package/src/components/editor/DrawerItemOverride.tsx +62 -0
- package/src/components/editor/EditorChromeToggles.tsx +35 -0
- package/src/components/editor/FragmentEditor.tsx +506 -0
- package/src/components/editor/FragmentWrappers.tsx +72 -0
- package/src/components/editor/GenericBlock.tsx +1361 -0
- package/src/components/editor/ImagePickerDialog.tsx +25 -0
- package/src/components/editor/JsxPropsPanel.tsx +293 -0
- package/src/components/editor/LocaleSelector.tsx +60 -0
- package/src/components/editor/MDXLivePreview.tsx +179 -0
- package/src/components/editor/MdxPageEditor.tsx +546 -0
- package/src/components/editor/PageEditor.tsx +529 -0
- package/src/components/editor/PageEditorHeaderActions.tsx +160 -0
- package/src/components/editor/PageEditorWrapper.tsx +502 -0
- package/src/components/editor/PuckWithUntouchedMetadata.tsx +65 -0
- package/src/components/editor/SearchableSelect.tsx +186 -0
- package/src/components/editor/host-wrapper-plugin.ts +91 -0
- package/src/components/editor/index.ts +8 -0
- package/src/components/editor/insert-menu/InsertMdxComponentButton.tsx +149 -0
- package/src/components/editor/insert-menu/SlashMenuPlugin.tsx +152 -0
- package/src/components/editor/insert-menu/insert-payload.ts +150 -0
- package/src/components/editor/insert-menu/mdx-components-plugin.ts +14 -0
- package/src/components/editor/page-setting-targets.tsx +154 -0
- package/src/components/editor/preview-availability.ts +20 -0
- package/src/components/editors/DataEditor.tsx +270 -0
- package/src/components/fields/ContentFragmentSelectorField.tsx +290 -0
- package/src/components/fields/ImageField.tsx +75 -0
- package/src/components/fields/MDXEditField.tsx +54 -0
- package/src/components/forms/ChipArrayField.tsx +81 -0
- package/src/components/forms/HintForm.tsx +437 -0
- package/src/components/forms/SchemaForm.tsx +307 -0
- package/src/components/index.ts +14 -0
- package/src/components/media/AssetCard.tsx +84 -0
- package/src/components/media/AssetDetailSidebar.tsx +335 -0
- package/src/components/media/BulkActionBar.tsx +33 -0
- package/src/components/media/FolderNav.tsx +44 -0
- package/src/components/media/FolderTreeSidebar.tsx +171 -0
- package/src/components/media/ImagePicker.tsx +102 -0
- package/src/components/media/MediaLibrary.tsx +183 -0
- package/src/components/media/MediaToolbar.tsx +100 -0
- package/src/components/media/UploadModal.tsx +266 -0
- package/src/components/media/index.ts +9 -0
- package/src/components/pages/DataList.tsx +498 -0
- package/src/components/pages/FragmentList.tsx +592 -0
- package/src/components/pages/MediaPage.tsx +284 -0
- package/src/components/pages/PageList.tsx +683 -0
- package/src/components/pages/index.ts +2 -0
- package/src/components/puck/MDXContent.tsx +199 -0
- package/src/components/puck/index.ts +1 -0
- package/src/components/sandbox/ContentSandbox.tsx +191 -0
- package/src/components/sandbox/frame-runtime.ts +15 -0
- package/src/components/toast.tsx +48 -0
- package/src/components/ui/Banner.tsx +108 -0
- package/src/components/ui/Button.tsx +51 -0
- package/src/components/ui/Card.tsx +124 -0
- package/src/components/ui/FieldError.tsx +37 -0
- package/src/components/ui/IconButton.tsx +40 -0
- package/src/components/ui/Input.tsx +66 -0
- package/src/components/ui/SaveIndicator.tsx +44 -0
- package/src/components/ui/Select.tsx +29 -0
- package/src/components/ui/Separator.tsx +14 -0
- package/src/components/ui/Textarea.tsx +22 -0
- package/src/components/ui/Tooltip.tsx +25 -0
- package/src/components/ui/index.ts +18 -0
- package/src/data-schemas.ts +82 -0
- package/src/dev-entry.tsx +25 -0
- package/src/dev.html +36 -0
- package/src/editor-flush.ts +47 -0
- package/src/hooks/index.ts +22 -0
- package/src/hooks/useCanvasTheme.tsx +52 -0
- package/src/hooks/useClickOutside.ts +24 -0
- package/src/hooks/useDialogState.ts +40 -0
- package/src/hooks/useEditorPref.ts +58 -0
- package/src/hooks/useErrorModal.tsx +63 -0
- package/src/hooks/useSiteBaseUrl.ts +16 -0
- package/src/hooks/useTheme.tsx +76 -0
- package/src/hooks/useUnsavedChangesGuard.ts +32 -0
- package/src/hooks/useUpload.ts +19 -0
- package/src/hooks/useUploadFlow.ts +227 -0
- package/src/host-discovery.ts +77 -0
- package/src/host-style-probe.ts +684 -0
- package/src/index.ts +42 -0
- package/src/lib/utils.ts +56 -0
- package/src/main-spa.tsx +68 -0
- package/src/main.css +1095 -0
- package/src/main.html +43 -0
- package/src/main.tsx +16 -0
- package/src/mdx-components-define.ts +296 -0
- package/src/mdx-components.ts +154 -0
- package/src/media/AssetScopePill.tsx +56 -0
- package/src/media/MediaIssueBadge.tsx +86 -0
- package/src/media/types.ts +96 -0
- package/src/media/use-asset-scope.ts +58 -0
- package/src/media/use-media-issue.ts +53 -0
- package/src/merge-default-props.ts +58 -0
- package/src/mock-puck-config.tsx +115 -0
- package/src/page-schema-define.ts +176 -0
- package/src/page-schemas.ts +80 -0
- package/src/page-setting-attributes.ts +40 -0
- package/src/prose-surface-css.ts +359 -0
- package/src/puck-config.ts +77 -0
- package/src/sandbox-preview-styles.ts +166 -0
- package/src/selected-block.ts +121 -0
- package/src/site-css-layer.ts +109 -0
- package/src/site-styles.ts +526 -0
- package/src/theme.ts +102 -0
- package/src/types.ts +63 -0
- package/src/ui-config.ts +344 -0
- package/src/utils/asset-url.ts +22 -0
- package/src/utils/cn.ts +6 -0
- package/src/utils/content-failure.ts +74 -0
- package/src/utils/entry-meta.ts +47 -0
- package/src/utils/entry-name.ts +21 -0
- package/src/utils/format-date.ts +34 -0
- package/src/utils/mdast-to-html.ts +247 -0
- package/src/utils/mdast-tree.ts +292 -0
- package/src/utils/menu-placement.ts +13 -0
- package/src/utils/pageMetadata.ts +285 -0
- package/src/utils/sanitize-html.ts +84 -0
- package/src/utils/slugify.ts +21 -0
- package/src/utils/zodIntrospect.ts +136 -0
- package/src/vite-env.d.ts +10 -0
- package/src/write-access.ts +147 -0
- package/styles/stylesheet.d.ts +6 -0
- package/styles/tailwind-theme.css +7 -5
- package/dist/App-Bk1LNxbS.mjs +0 -10851
- package/dist/App-Bk1LNxbS.mjs.map +0 -1
- package/dist/App.d.ts +0 -35
- package/dist/App.d.ts.map +0 -1
- package/dist/App.js +0 -52
- package/dist/CmsSpaApp.d.ts +0 -13
- package/dist/CmsSpaApp.d.ts.map +0 -1
- package/dist/CmsSpaApp.js +0 -33
- package/dist/cn-dlASUkDY.mjs +0 -10
- package/dist/cn-dlASUkDY.mjs.map +0 -1
- package/dist/components/CMSDashboard.d.ts +0 -2
- package/dist/components/CMSDashboard.d.ts.map +0 -1
- package/dist/components/CMSDashboard.js +0 -20
- package/dist/components/CMSLayout.d.ts +0 -2
- package/dist/components/CMSLayout.d.ts.map +0 -1
- package/dist/components/CMSLayout.js +0 -15
- package/dist/components/ConlocaLogo.d.ts +0 -2
- package/dist/components/ConlocaLogo.d.ts.map +0 -1
- package/dist/components/ConlocaLogo.js +0 -4
- package/dist/components/GitStatusPanel.d.ts +0 -25
- package/dist/components/GitStatusPanel.d.ts.map +0 -1
- package/dist/components/GitStatusPanel.js +0 -77
- package/dist/components/MobileTopBar.d.ts +0 -6
- package/dist/components/MobileTopBar.d.ts.map +0 -1
- package/dist/components/MobileTopBar.js +0 -6
- package/dist/components/Sidebar.d.ts +0 -8
- package/dist/components/Sidebar.d.ts.map +0 -1
- package/dist/components/Sidebar.js +0 -40
- package/dist/components/UserAvatar.d.ts +0 -2
- package/dist/components/UserAvatar.d.ts.map +0 -1
- package/dist/components/UserAvatar.js +0 -14
- package/dist/components/cards/DataEntryCard.d.ts +0 -14
- package/dist/components/cards/DataEntryCard.d.ts.map +0 -1
- package/dist/components/cards/DataEntryCard.js +0 -32
- package/dist/components/cards/SectionCard.d.ts +0 -15
- package/dist/components/cards/SectionCard.d.ts.map +0 -1
- package/dist/components/cards/SectionCard.js +0 -10
- package/dist/components/cards/index.d.ts +0 -2
- package/dist/components/cards/index.d.ts.map +0 -1
- package/dist/components/cards/index.js +0 -1
- package/dist/components/dashboard/RecentActivity.d.ts +0 -2
- package/dist/components/dashboard/RecentActivity.d.ts.map +0 -1
- package/dist/components/dashboard/RecentActivity.js +0 -58
- package/dist/components/dialog.d.ts +0 -53
- package/dist/components/dialog.d.ts.map +0 -1
- package/dist/components/dialog.js +0 -56
- package/dist/components/dialogs/BlockPropertiesDialog.d.ts +0 -12
- package/dist/components/dialogs/BlockPropertiesDialog.d.ts.map +0 -1
- package/dist/components/dialogs/BlockPropertiesDialog.js +0 -42
- package/dist/components/dialogs/ConflictDialog.d.ts +0 -10
- package/dist/components/dialogs/ConflictDialog.d.ts.map +0 -1
- package/dist/components/dialogs/ConflictDialog.js +0 -29
- package/dist/components/dialogs/CreateDataDialog.d.ts +0 -9
- package/dist/components/dialogs/CreateDataDialog.d.ts.map +0 -1
- package/dist/components/dialogs/CreateDataDialog.js +0 -20
- package/dist/components/dialogs/CreateFolderDialog.d.ts +0 -9
- package/dist/components/dialogs/CreateFolderDialog.d.ts.map +0 -1
- package/dist/components/dialogs/CreateFolderDialog.js +0 -33
- package/dist/components/dialogs/CreatePageDialog.d.ts +0 -10
- package/dist/components/dialogs/CreatePageDialog.d.ts.map +0 -1
- package/dist/components/dialogs/CreatePageDialog.js +0 -155
- package/dist/components/dialogs/DataPropertiesDialog.d.ts +0 -10
- package/dist/components/dialogs/DataPropertiesDialog.d.ts.map +0 -1
- package/dist/components/dialogs/DataPropertiesDialog.js +0 -38
- package/dist/components/dialogs/DeleteConfirmDialog.d.ts +0 -12
- package/dist/components/dialogs/DeleteConfirmDialog.d.ts.map +0 -1
- package/dist/components/dialogs/DeleteConfirmDialog.js +0 -7
- package/dist/components/dialogs/ErrorModal.d.ts +0 -14
- package/dist/components/dialogs/ErrorModal.d.ts.map +0 -1
- package/dist/components/dialogs/ErrorModal.js +0 -38
- package/dist/components/dialogs/MoveFolderDialog.d.ts +0 -11
- package/dist/components/dialogs/MoveFolderDialog.d.ts.map +0 -1
- package/dist/components/dialogs/MoveFolderDialog.js +0 -45
- package/dist/components/dialogs/PageMetadataDialog.d.ts +0 -10
- package/dist/components/dialogs/PageMetadataDialog.d.ts.map +0 -1
- package/dist/components/dialogs/PageMetadataDialog.js +0 -85
- package/dist/components/dialogs/UnsavedChangesDialog.d.ts +0 -8
- package/dist/components/dialogs/UnsavedChangesDialog.d.ts.map +0 -1
- package/dist/components/dialogs/UnsavedChangesDialog.js +0 -6
- package/dist/components/dialogs/index.d.ts +0 -9
- package/dist/components/dialogs/index.d.ts.map +0 -1
- package/dist/components/dialogs/index.js +0 -8
- package/dist/components/editor/BlockEditor.d.ts +0 -8
- package/dist/components/editor/BlockEditor.d.ts.map +0 -1
- package/dist/components/editor/BlockEditor.js +0 -262
- package/dist/components/editor/BlockWrappers.d.ts +0 -15
- package/dist/components/editor/BlockWrappers.d.ts.map +0 -1
- package/dist/components/editor/BlockWrappers.js +0 -29
- package/dist/components/editor/CMSMDXEditor.d.ts +0 -13
- package/dist/components/editor/CMSMDXEditor.d.ts.map +0 -1
- package/dist/components/editor/CMSMDXEditor.js +0 -123
- package/dist/components/editor/ContentDiff.d.ts +0 -10
- package/dist/components/editor/ContentDiff.d.ts.map +0 -1
- package/dist/components/editor/ContentDiff.js +0 -51
- package/dist/components/editor/CreateBlockDialog.d.ts +0 -26
- package/dist/components/editor/CreateBlockDialog.d.ts.map +0 -1
- package/dist/components/editor/CreateBlockDialog.js +0 -131
- package/dist/components/editor/DrawerItemOverride.d.ts +0 -8
- package/dist/components/editor/DrawerItemOverride.d.ts.map +0 -1
- package/dist/components/editor/DrawerItemOverride.js +0 -41
- package/dist/components/editor/EditorChromeToggles.d.ts +0 -16
- package/dist/components/editor/EditorChromeToggles.d.ts.map +0 -1
- package/dist/components/editor/EditorChromeToggles.js +0 -16
- package/dist/components/editor/GenericBlock.d.ts +0 -3
- package/dist/components/editor/GenericBlock.d.ts.map +0 -1
- package/dist/components/editor/GenericBlock.js +0 -1067
- package/dist/components/editor/ImagePickerDialog.d.ts +0 -6
- package/dist/components/editor/ImagePickerDialog.d.ts.map +0 -1
- package/dist/components/editor/ImagePickerDialog.js +0 -24
- package/dist/components/editor/JsxPropsPanel.d.ts +0 -16
- package/dist/components/editor/JsxPropsPanel.d.ts.map +0 -1
- package/dist/components/editor/JsxPropsPanel.js +0 -145
- package/dist/components/editor/LocaleSelector.d.ts +0 -9
- package/dist/components/editor/LocaleSelector.d.ts.map +0 -1
- package/dist/components/editor/LocaleSelector.js +0 -13
- package/dist/components/editor/MDXLivePreview.d.ts +0 -14
- package/dist/components/editor/MDXLivePreview.d.ts.map +0 -1
- package/dist/components/editor/MDXLivePreview.js +0 -103
- package/dist/components/editor/MdxPageEditor.d.ts +0 -10
- package/dist/components/editor/MdxPageEditor.d.ts.map +0 -1
- package/dist/components/editor/MdxPageEditor.js +0 -297
- package/dist/components/editor/PageEditor.d.ts +0 -18
- package/dist/components/editor/PageEditor.d.ts.map +0 -1
- package/dist/components/editor/PageEditor.js +0 -288
- package/dist/components/editor/PageEditorHeaderActions.d.ts +0 -16
- package/dist/components/editor/PageEditorHeaderActions.d.ts.map +0 -1
- package/dist/components/editor/PageEditorHeaderActions.js +0 -19
- package/dist/components/editor/PageEditorWrapper.d.ts +0 -7
- package/dist/components/editor/PageEditorWrapper.d.ts.map +0 -1
- package/dist/components/editor/PageEditorWrapper.js +0 -319
- package/dist/components/editor/SearchableSelect.d.ts +0 -34
- package/dist/components/editor/SearchableSelect.d.ts.map +0 -1
- package/dist/components/editor/SearchableSelect.js +0 -116
- package/dist/components/editor/host-wrapper-plugin.d.ts.map +0 -1
- package/dist/components/editor/host-wrapper-plugin.js +0 -37
- package/dist/components/editor/index.d.ts +0 -9
- package/dist/components/editor/index.d.ts.map +0 -1
- package/dist/components/editor/index.js +0 -7
- package/dist/components/editor/insert-menu/InsertMdxComponentButton.d.ts +0 -15
- package/dist/components/editor/insert-menu/InsertMdxComponentButton.d.ts.map +0 -1
- package/dist/components/editor/insert-menu/InsertMdxComponentButton.js +0 -90
- package/dist/components/editor/insert-menu/SlashMenuPlugin.d.ts +0 -12
- package/dist/components/editor/insert-menu/SlashMenuPlugin.d.ts.map +0 -1
- package/dist/components/editor/insert-menu/SlashMenuPlugin.js +0 -106
- package/dist/components/editor/insert-menu/insert-payload.d.ts +0 -76
- package/dist/components/editor/insert-menu/insert-payload.d.ts.map +0 -1
- package/dist/components/editor/insert-menu/insert-payload.js +0 -94
- package/dist/components/editor/insert-menu/mdx-components-plugin.d.ts.map +0 -1
- package/dist/components/editor/insert-menu/mdx-components-plugin.js +0 -13
- package/dist/components/editors/DataEditor.d.ts +0 -19
- package/dist/components/editors/DataEditor.d.ts.map +0 -1
- package/dist/components/editors/DataEditor.js +0 -139
- package/dist/components/fields/ContentBlockSelectorField.d.ts +0 -14
- package/dist/components/fields/ContentBlockSelectorField.d.ts.map +0 -1
- package/dist/components/fields/ContentBlockSelectorField.js +0 -105
- package/dist/components/fields/ImageField.d.ts +0 -16
- package/dist/components/fields/ImageField.d.ts.map +0 -1
- package/dist/components/fields/ImageField.js +0 -39
- package/dist/components/fields/MDXEditField.d.ts +0 -17
- package/dist/components/fields/MDXEditField.d.ts.map +0 -1
- package/dist/components/fields/MDXEditField.js +0 -28
- package/dist/components/forms/ChipArrayField.d.ts +0 -12
- package/dist/components/forms/ChipArrayField.d.ts.map +0 -1
- package/dist/components/forms/ChipArrayField.js +0 -40
- package/dist/components/forms/HintForm.d.ts +0 -22
- package/dist/components/forms/HintForm.d.ts.map +0 -1
- package/dist/components/forms/HintForm.js +0 -162
- package/dist/components/forms/SchemaForm.d.ts +0 -15
- package/dist/components/forms/SchemaForm.d.ts.map +0 -1
- package/dist/components/forms/SchemaForm.js +0 -106
- package/dist/components/index.d.ts +0 -8
- package/dist/components/index.d.ts.map +0 -1
- package/dist/components/index.js +0 -13
- package/dist/components/media/AssetCard.d.ts +0 -14
- package/dist/components/media/AssetCard.d.ts.map +0 -1
- package/dist/components/media/AssetCard.js +0 -31
- package/dist/components/media/AssetDetailSidebar.d.ts +0 -11
- package/dist/components/media/AssetDetailSidebar.d.ts.map +0 -1
- package/dist/components/media/AssetDetailSidebar.js +0 -101
- package/dist/components/media/BulkActionBar.d.ts +0 -9
- package/dist/components/media/BulkActionBar.d.ts.map +0 -1
- package/dist/components/media/BulkActionBar.js +0 -8
- package/dist/components/media/FolderNav.d.ts +0 -7
- package/dist/components/media/FolderNav.d.ts.map +0 -1
- package/dist/components/media/FolderNav.js +0 -12
- package/dist/components/media/FolderTreeSidebar.d.ts +0 -9
- package/dist/components/media/FolderTreeSidebar.d.ts.map +0 -1
- package/dist/components/media/FolderTreeSidebar.js +0 -41
- package/dist/components/media/ImagePicker.d.ts +0 -14
- package/dist/components/media/ImagePicker.d.ts.map +0 -1
- package/dist/components/media/ImagePicker.js +0 -45
- package/dist/components/media/MediaLibrary.d.ts +0 -35
- package/dist/components/media/MediaLibrary.d.ts.map +0 -1
- package/dist/components/media/MediaLibrary.js +0 -100
- package/dist/components/media/MediaToolbar.d.ts +0 -21
- package/dist/components/media/MediaToolbar.d.ts.map +0 -1
- package/dist/components/media/MediaToolbar.js +0 -6
- package/dist/components/media/UploadModal.d.ts +0 -9
- package/dist/components/media/UploadModal.d.ts.map +0 -1
- package/dist/components/media/UploadModal.js +0 -42
- package/dist/components/media/UploadZone.d.ts +0 -8
- package/dist/components/media/UploadZone.d.ts.map +0 -1
- package/dist/components/media/UploadZone.js +0 -22
- package/dist/components/media/index.d.ts +0 -11
- package/dist/components/media/index.d.ts.map +0 -1
- package/dist/components/media/index.js +0 -10
- package/dist/components/pages/BlockList.d.ts +0 -2
- package/dist/components/pages/BlockList.d.ts.map +0 -1
- package/dist/components/pages/BlockList.js +0 -280
- package/dist/components/pages/DataList.d.ts +0 -7
- package/dist/components/pages/DataList.d.ts.map +0 -1
- package/dist/components/pages/DataList.js +0 -244
- package/dist/components/pages/MediaPage.d.ts +0 -8
- package/dist/components/pages/MediaPage.d.ts.map +0 -1
- package/dist/components/pages/MediaPage.js +0 -107
- package/dist/components/pages/PageList.d.ts +0 -7
- package/dist/components/pages/PageList.d.ts.map +0 -1
- package/dist/components/pages/PageList.js +0 -308
- package/dist/components/pages/index.d.ts +0 -3
- package/dist/components/pages/index.d.ts.map +0 -1
- package/dist/components/pages/index.js +0 -2
- package/dist/components/puck/MDXContent.d.ts +0 -10
- package/dist/components/puck/MDXContent.d.ts.map +0 -1
- package/dist/components/puck/MDXContent.js +0 -80
- package/dist/components/puck/index.d.ts +0 -2
- package/dist/components/puck/index.d.ts.map +0 -1
- package/dist/components/puck/index.js +0 -1
- package/dist/components/toast.d.ts +0 -44
- package/dist/components/toast.d.ts.map +0 -1
- package/dist/components/toast.js +0 -7
- package/dist/components/ui/Banner.d.ts +0 -76
- package/dist/components/ui/Banner.d.ts.map +0 -1
- package/dist/components/ui/Banner.js +0 -49
- package/dist/components/ui/Button.d.ts +0 -25
- package/dist/components/ui/Button.d.ts.map +0 -1
- package/dist/components/ui/Button.js +0 -33
- package/dist/components/ui/Card.d.ts +0 -72
- package/dist/components/ui/Card.d.ts.map +0 -1
- package/dist/components/ui/Card.js +0 -49
- package/dist/components/ui/FieldError.d.ts +0 -24
- package/dist/components/ui/FieldError.d.ts.map +0 -1
- package/dist/components/ui/FieldError.js +0 -17
- package/dist/components/ui/IconButton.d.ts +0 -13
- package/dist/components/ui/IconButton.d.ts.map +0 -1
- package/dist/components/ui/IconButton.js +0 -10
- package/dist/components/ui/Input.d.ts +0 -37
- package/dist/components/ui/Input.d.ts.map +0 -1
- package/dist/components/ui/Input.js +0 -9
- package/dist/components/ui/SaveIndicator.d.ts +0 -8
- package/dist/components/ui/SaveIndicator.d.ts.map +0 -1
- package/dist/components/ui/SaveIndicator.js +0 -32
- package/dist/components/ui/Select.d.ts +0 -8
- package/dist/components/ui/Select.d.ts.map +0 -1
- package/dist/components/ui/Select.js +0 -9
- package/dist/components/ui/Separator.d.ts +0 -7
- package/dist/components/ui/Separator.d.ts.map +0 -1
- package/dist/components/ui/Separator.js +0 -8
- package/dist/components/ui/Textarea.d.ts +0 -8
- package/dist/components/ui/Textarea.d.ts.map +0 -1
- package/dist/components/ui/Textarea.js +0 -5
- package/dist/components/ui/Tooltip.d.ts +0 -9
- package/dist/components/ui/Tooltip.d.ts.map +0 -1
- package/dist/components/ui/Tooltip.js +0 -7
- package/dist/components/ui/index.d.ts +0 -14
- package/dist/components/ui/index.d.ts.map +0 -1
- package/dist/components/ui/index.js +0 -17
- package/dist/data-schemas.d.mts +0 -25
- package/dist/data-schemas.d.mts.map +0 -1
- package/dist/data-schemas.d.ts +0 -22
- package/dist/data-schemas.d.ts.map +0 -1
- package/dist/data-schemas.js +0 -51
- package/dist/data-schemas.mjs +0 -51
- package/dist/data-schemas.mjs.map +0 -1
- package/dist/dev-entry.d.ts +0 -2
- package/dist/dev-entry.d.ts.map +0 -1
- package/dist/dev-entry.js +0 -19
- package/dist/dialog.d.mts +0 -56
- package/dist/dialog.d.mts.map +0 -1
- package/dist/dialog.mjs +0 -67
- package/dist/dialog.mjs.map +0 -1
- package/dist/hooks/index.d.ts +0 -10
- package/dist/hooks/index.d.ts.map +0 -1
- package/dist/hooks/index.js +0 -7
- package/dist/hooks/useCanvasTheme.d.ts +0 -12
- package/dist/hooks/useCanvasTheme.d.ts.map +0 -1
- package/dist/hooks/useCanvasTheme.js +0 -33
- package/dist/hooks/useClickOutside.d.ts.map +0 -1
- package/dist/hooks/useClickOutside.js +0 -18
- package/dist/hooks/useDialogState.d.ts.map +0 -1
- package/dist/hooks/useDialogState.js +0 -31
- package/dist/hooks/useEditorPref.d.ts.map +0 -1
- package/dist/hooks/useEditorPref.js +0 -49
- package/dist/hooks/useErrorModal.d.ts +0 -15
- package/dist/hooks/useErrorModal.d.ts.map +0 -1
- package/dist/hooks/useErrorModal.js +0 -35
- package/dist/hooks/useSiteBaseUrl.d.ts +0 -10
- package/dist/hooks/useSiteBaseUrl.d.ts.map +0 -1
- package/dist/hooks/useSiteBaseUrl.js +0 -14
- package/dist/hooks/useTheme.d.ts +0 -13
- package/dist/hooks/useTheme.d.ts.map +0 -1
- package/dist/hooks/useTheme.js +0 -69
- package/dist/hooks/useUnsavedChangesGuard.d.ts.map +0 -1
- package/dist/hooks/useUnsavedChangesGuard.js +0 -29
- package/dist/hooks/useUpload.d.ts +0 -10
- package/dist/hooks/useUpload.d.ts.map +0 -1
- package/dist/hooks/useUpload.js +0 -42
- package/dist/hooks/useUploadFlow.d.ts +0 -42
- package/dist/hooks/useUploadFlow.d.ts.map +0 -1
- package/dist/hooks/useUploadFlow.js +0 -148
- package/dist/host-style-probe.d.ts +0 -22
- package/dist/host-style-probe.d.ts.map +0 -1
- package/dist/host-style-probe.js +0 -508
- package/dist/index.d.mts +0 -253
- package/dist/index.d.mts.map +0 -1
- package/dist/index.d.ts +0 -10
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js +0 -12
- package/dist/index.mjs +0 -38
- package/dist/index.mjs.map +0 -1
- package/dist/lib/utils.d.ts.map +0 -1
- package/dist/lib/utils.js +0 -47
- package/dist/main-spa-781YUplS.mjs +0 -46
- package/dist/main-spa-781YUplS.mjs.map +0 -1
- package/dist/main-spa.d.ts.map +0 -1
- package/dist/main-spa.js +0 -61
- package/dist/main.d.mts +0 -1
- package/dist/main.d.ts.map +0 -1
- package/dist/main.js +0 -13
- package/dist/main.mjs +0 -17
- package/dist/main.mjs.map +0 -1
- package/dist/mdx-components.d.mts +0 -207
- package/dist/mdx-components.d.mts.map +0 -1
- package/dist/mdx-components.d.ts +0 -204
- package/dist/mdx-components.d.ts.map +0 -1
- package/dist/mdx-components.js +0 -217
- package/dist/mdx-components.mjs +0 -208
- package/dist/mdx-components.mjs.map +0 -1
- package/dist/media/AssetScopePill.d.ts +0 -30
- package/dist/media/AssetScopePill.d.ts.map +0 -1
- package/dist/media/AssetScopePill.js +0 -30
- package/dist/media/MediaIssueBadge.d.ts +0 -33
- package/dist/media/MediaIssueBadge.d.ts.map +0 -1
- package/dist/media/MediaIssueBadge.js +0 -54
- package/dist/media/types.d.ts +0 -101
- package/dist/media/types.d.ts.map +0 -1
- package/dist/media/types.js +0 -1
- package/dist/media/use-asset-scope.d.ts +0 -25
- package/dist/media/use-asset-scope.d.ts.map +0 -1
- package/dist/media/use-asset-scope.js +0 -54
- package/dist/media/use-media-issue.d.ts +0 -24
- package/dist/media/use-media-issue.d.ts.map +0 -1
- package/dist/media/use-media-issue.js +0 -49
- package/dist/mock-puck-config.d.mts +0 -23
- package/dist/mock-puck-config.d.mts.map +0 -1
- package/dist/mock-puck-config.d.ts.map +0 -1
- package/dist/mock-puck-config.js +0 -73
- package/dist/mock-puck-config.mjs +0 -125
- package/dist/mock-puck-config.mjs.map +0 -1
- package/dist/page-schemas.d.mts +0 -159
- package/dist/page-schemas.d.mts.map +0 -1
- package/dist/page-schemas.d.ts +0 -156
- package/dist/page-schemas.d.ts.map +0 -1
- package/dist/page-schemas.js +0 -118
- package/dist/page-schemas.mjs +0 -120
- package/dist/page-schemas.mjs.map +0 -1
- package/dist/puck-config.d.mts +0 -33
- package/dist/puck-config.d.mts.map +0 -1
- package/dist/puck-config.d.ts.map +0 -1
- package/dist/puck-config.js +0 -50
- package/dist/puck-config.mjs +0 -50
- package/dist/puck-config.mjs.map +0 -1
- package/dist/selected-block.d.ts +0 -61
- package/dist/selected-block.d.ts.map +0 -1
- package/dist/selected-block.js +0 -64
- package/dist/site-styles.d.mts +0 -123
- package/dist/site-styles.d.mts.map +0 -1
- package/dist/site-styles.d.ts +0 -121
- package/dist/site-styles.d.ts.map +0 -1
- package/dist/site-styles.js +0 -253
- package/dist/site-styles.mjs +0 -234
- package/dist/site-styles.mjs.map +0 -1
- package/dist/toast.d.mts +0 -7
- package/dist/toast.d.mts.map +0 -1
- package/dist/toast.mjs +0 -16
- package/dist/toast.mjs.map +0 -1
- package/dist/types.d.ts +0 -57
- package/dist/types.d.ts.map +0 -1
- package/dist/types.js +0 -1
- package/dist/ui-CIacC6Mv.mjs +0 -318
- package/dist/ui-CIacC6Mv.mjs.map +0 -1
- package/dist/ui-config.d.ts +0 -70
- package/dist/ui-config.d.ts.map +0 -1
- package/dist/ui-config.js +0 -44
- package/dist/ui.d.mts +0 -290
- package/dist/ui.d.mts.map +0 -1
- package/dist/ui.mjs +0 -2
- package/dist/utils/asset-url.d.ts +0 -3
- package/dist/utils/asset-url.d.ts.map +0 -1
- package/dist/utils/asset-url.js +0 -7
- package/dist/utils/cn.d.ts.map +0 -1
- package/dist/utils/cn.js +0 -5
- package/dist/utils/format-date.d.ts.map +0 -1
- package/dist/utils/format-date.js +0 -37
- package/dist/utils/mdast-to-html.d.ts.map +0 -1
- package/dist/utils/mdast-to-html.js +0 -206
- package/dist/utils/mdast-tree.d.ts.map +0 -1
- package/dist/utils/mdast-tree.js +0 -285
- package/dist/utils/pageMetadata.d.ts +0 -67
- package/dist/utils/pageMetadata.d.ts.map +0 -1
- package/dist/utils/pageMetadata.js +0 -161
- package/dist/utils/slugify.d.ts +0 -12
- package/dist/utils/slugify.d.ts.map +0 -1
- package/dist/utils/slugify.js +0 -17
- package/dist/utils/zodIntrospect.d.ts +0 -24
- package/dist/utils/zodIntrospect.d.ts.map +0 -1
- package/dist/utils/zodIntrospect.js +0 -88
- package/styles/styles.css.d.ts +0 -2
- package/styles/tailwind-theme.css.d.ts +0 -2
- /package/dist/{components → ts/components}/editor/host-wrapper-plugin.d.ts +0 -0
- /package/dist/{components → ts/components}/editor/insert-menu/mdx-components-plugin.d.ts +0 -0
- /package/dist/{hooks → ts/hooks}/useClickOutside.d.ts +0 -0
- /package/dist/{hooks → ts/hooks}/useDialogState.d.ts +0 -0
- /package/dist/{hooks → ts/hooks}/useEditorPref.d.ts +0 -0
- /package/dist/{hooks → ts/hooks}/useUnsavedChangesGuard.d.ts +0 -0
- /package/dist/{lib → ts/lib}/utils.d.ts +0 -0
- /package/dist/{main-spa.d.ts → ts/main-spa.d.ts} +0 -0
- /package/dist/{main.d.ts → ts/main.d.ts} +0 -0
- /package/dist/{mock-puck-config.d.ts → ts/mock-puck-config.d.ts} +0 -0
- /package/dist/{puck-config.d.ts → ts/puck-config.d.ts} +0 -0
- /package/dist/{utils → ts/utils}/cn.d.ts +0 -0
- /package/dist/{utils → ts/utils}/format-date.d.ts +0 -0
- /package/dist/{utils → ts/utils}/mdast-to-html.d.ts +0 -0
- /package/dist/{utils → ts/utils}/mdast-tree.d.ts +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pageMetadata.js","sourceRoot":"","sources":["../../../src/utils/pageMetadata.ts"],"names":[],"mappings":"AAAA,OAAO,EAA2C,UAAU,EAAqB,MAAM,6BAA6B,CAAC;AACrH,OAAO,EAAE,cAAc,EAA6B,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAEvG,OAAO,EAAE,qBAAqB,EAAE,MAAM,sBAAsB,CAAC;AAe7D;;;;;GAKG;AACH,MAAM,mBAAmB,GAAG,IAAI,GAAG,CAAC;IAClC,OAAO;IACP,aAAa;IACb,QAAQ;IACR,WAAW;IACX,UAAU;IACV,SAAS;IACT,eAAe;IACf,SAAS;CACV,CAAC,CAAC;AAEH,SAAS,WAAW,CAAC,UAAuC;IAC1D,MAAM,IAAI,GAAG,UAAU,EAAE,UAAU,EAAE,IAAI,IAAI,MAAM,CAAC;IACpD,wEAAwE;IACxE,uEAAuE;IACvE,sEAAsE;IACtE,IAAI,IAAI,KAAK,SAAS,IAAI,IAAI,KAAK,MAAM;QAAE,OAAO,IAAI,GAAG,EAAE,CAAC;IAC5D,OAAO,mBAAmB,CAAC;AAC7B,CAAC;AAED,MAAM,IAAI,GAAG,CAAC,CAAS,EAAE,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC;AAEvD;;;GAGG;AACH,MAAM,UAAU,oBAAoB,CAAC,IAA6B;IAChE,IAAI,CAAC,IAAI,IAAI,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,OAAO,EAAE,CAAC;QAAE,OAAO,EAAE,C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EAAE,CAAC;QACjC,IAAI,CAAC,GAAG,CAAC,QAAQ,CAAC,GAAG,CAAC;YAAE,GAAG,CAAC,GAAG,CAAC,GAAG,GAAG,CAAC;IACzC,CAAC;IAED,KAAK,MAAM,CAAC,GAAG,EAAE,GAAG,CAAC,IAAI,OAAO,EAAE,CAAC;QACjC,IAAI,CAAC,GAAG,CAAC,QAAQ,CAAC,GAAG,CAAC;YAAE,SAAS;QACjC,MAAM,QAAQ,GAAG,GAAG,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;QAChC,IAAI,MAAM,GAAG,GAAG,CAAC;QACjB,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,QAAQ,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC;YAC7C,MAAM,GAAG,GAAG,QAAQ,CAAC,CAAC,CAAC,CAAC;YACxB,MAAM,QAAQ,GAAG,MAAM,CAAC,GAAG,CAAC,CAAC;YAC7B,IAAI,CAAC,QAAQ,IAAI,OAAO,QAAQ,KAAK,QAAQ,EAAE,CAAC;gBAC9C,MAAM,CAAC,GAAG,CAAC,GAAG,EAAE,CAAC;YACnB,CAAC;YACD,MAAM,GAAG,MAAM,CAAC,GAAG,CAA4B,CAAC;QAClD,CAAC;QACD,MAAM,CAAC,QAAQ,CAAC,QAAQ,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,GAAG,GAAG,CAAC;IAC9C,CAAC;IACD,OAAO,GAAG,CAAC;AACb,CAAC"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Allowlist-sanitize author-controlled HTML before it reaches any innerHTML /
|
|
3
|
+
* `dangerouslySetInnerHTML` sink in the editor.
|
|
4
|
+
*
|
|
5
|
+
* The editor serializes author-controlled mdast (raw `<div>`/`<details>`
|
|
6
|
+
* tag soup, JSX-written lowercase elements) to HTML and injects it into the
|
|
7
|
+
* privileged admin document. Without sanitization an `<img onerror>`, a
|
|
8
|
+
* `<script>`, a `javascript:` href, or a CSS `url()` beacon would run with the
|
|
9
|
+
* signed-in editor's ambient authority. DOMPurify strips
|
|
10
|
+
* scripts, event-handler attributes, and dangerous URL schemes; the module hook
|
|
11
|
+
* strips CSS `url()` beacons while keeping the benign structural markup authors
|
|
12
|
+
* legitimately write.
|
|
13
|
+
*
|
|
14
|
+
* `conloca-slot` is added to the tag allowlist because the inline-editing
|
|
15
|
+
* machinery portals Lexical editors into `<conloca-slot data-slot-id>`
|
|
16
|
+
* elements in the rendered preview; DOMPurify keeps `data-*` attributes by
|
|
17
|
+
* default, so the slot ids survive.
|
|
18
|
+
*/
|
|
19
|
+
export declare function sanitizeHtml(html: string): string;
|
|
20
|
+
/**
|
|
21
|
+
* Sanitize the render-endpoint RESPONSE before GenericBlock's privileged
|
|
22
|
+
* innerHTML sink. Unlike author input, the response is our OWN registered-
|
|
23
|
+
* component output (VideoEmbed's `<iframe>`, icon `<svg><use>`, …) reacting to
|
|
24
|
+
* already-sanitized author props — so it is structurally generous (keeps the
|
|
25
|
+
* `iframe`/`use` that the strict author allowlist drops) but stays strict on
|
|
26
|
+
* execution and egress: DOMPurify still strips `<script>`, `on*` handlers, and
|
|
27
|
+
* `javascript:`/`data:text/html` URLs, the module hook strips CSS `url()`
|
|
28
|
+
* beacons, and iframe sources are clamped to `https:`.
|
|
29
|
+
*/
|
|
30
|
+
export declare function sanitizeComponentHtml(html: string): string;
|
|
31
|
+
//# sourceMappingURL=sanitize-html.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sanitize-html.d.ts","sourceRoot":"","sources":["../../../src/utils/sanitize-html.ts"],"names":[],"mappings":"AA8CA;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAgB,YAAY,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAEjD;AAED;;;;;;;;;GASG;AACH,wBAAgB,qBAAqB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAK1D"}
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
import createDOMPurify from 'dompurify';
|
|
2
|
+
/** CSS that fetches a URL or (legacy) executes script. `url()`/`image-set()`
|
|
3
|
+
* beacon an external host; `expression()` ran JS in old IE. DOMPurify allowlists
|
|
4
|
+
* the `style` attribute NAME but never inspects its VALUE, so these survive the
|
|
5
|
+
* sanitize pass and fire from whatever document renders the result — including
|
|
6
|
+
* the privileged editor document. */
|
|
7
|
+
const NETWORKING_CSS = /url\s*\(|image-set\s*\(|expression\s*\(/i;
|
|
8
|
+
/**
|
|
9
|
+
* Lazily bind DOMPurify to the ambient window. DOMPurify's default export is
|
|
10
|
+
* both an instance and a factory; binding at first call (rather than import)
|
|
11
|
+
* keeps it correct when the DOM isn't present at module-evaluation time (test
|
|
12
|
+
* runners register happy-dom after imports resolve).
|
|
13
|
+
*
|
|
14
|
+
* The instance carries a hook that strips network-triggering CSS from inline
|
|
15
|
+
* `style` values and clamps `iframe` sources to `https:` — both apply to every
|
|
16
|
+
* sanitize call this module makes.
|
|
17
|
+
*/
|
|
18
|
+
let purify = null;
|
|
19
|
+
function getPurify() {
|
|
20
|
+
if (!purify) {
|
|
21
|
+
purify = createDOMPurify(window);
|
|
22
|
+
purify.addHook('afterSanitizeAttributes', (node) => {
|
|
23
|
+
const el = node;
|
|
24
|
+
const style = el.getAttribute?.('style');
|
|
25
|
+
if (style && NETWORKING_CSS.test(style)) {
|
|
26
|
+
const cleaned = style
|
|
27
|
+
.split(';')
|
|
28
|
+
.filter((decl) => !NETWORKING_CSS.test(decl))
|
|
29
|
+
.join(';');
|
|
30
|
+
if (cleaned.trim())
|
|
31
|
+
el.setAttribute('style', cleaned);
|
|
32
|
+
else
|
|
33
|
+
el.removeAttribute('style');
|
|
34
|
+
}
|
|
35
|
+
// Embeds are always https:; anything else on an iframe src is dropped.
|
|
36
|
+
// (DOMPurify already blocks javascript:/data: schemes; this additionally
|
|
37
|
+
// drops http: and protocol-relative srcs, leaving only real https embeds.)
|
|
38
|
+
if (el.tagName === 'IFRAME') {
|
|
39
|
+
const src = el.getAttribute?.('src');
|
|
40
|
+
if (src && !/^https:\/\//i.test(src.trim()))
|
|
41
|
+
el.removeAttribute('src');
|
|
42
|
+
}
|
|
43
|
+
});
|
|
44
|
+
}
|
|
45
|
+
return purify;
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* Allowlist-sanitize author-controlled HTML before it reaches any innerHTML /
|
|
49
|
+
* `dangerouslySetInnerHTML` sink in the editor.
|
|
50
|
+
*
|
|
51
|
+
* The editor serializes author-controlled mdast (raw `<div>`/`<details>`
|
|
52
|
+
* tag soup, JSX-written lowercase elements) to HTML and injects it into the
|
|
53
|
+
* privileged admin document. Without sanitization an `<img onerror>`, a
|
|
54
|
+
* `<script>`, a `javascript:` href, or a CSS `url()` beacon would run with the
|
|
55
|
+
* signed-in editor's ambient authority. DOMPurify strips
|
|
56
|
+
* scripts, event-handler attributes, and dangerous URL schemes; the module hook
|
|
57
|
+
* strips CSS `url()` beacons while keeping the benign structural markup authors
|
|
58
|
+
* legitimately write.
|
|
59
|
+
*
|
|
60
|
+
* `conloca-slot` is added to the tag allowlist because the inline-editing
|
|
61
|
+
* machinery portals Lexical editors into `<conloca-slot data-slot-id>`
|
|
62
|
+
* elements in the rendered preview; DOMPurify keeps `data-*` attributes by
|
|
63
|
+
* default, so the slot ids survive.
|
|
64
|
+
*/
|
|
65
|
+
export function sanitizeHtml(html) {
|
|
66
|
+
return getPurify().sanitize(html, { ADD_TAGS: ['conloca-slot'] });
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* Sanitize the render-endpoint RESPONSE before GenericBlock's privileged
|
|
70
|
+
* innerHTML sink. Unlike author input, the response is our OWN registered-
|
|
71
|
+
* component output (VideoEmbed's `<iframe>`, icon `<svg><use>`, …) reacting to
|
|
72
|
+
* already-sanitized author props — so it is structurally generous (keeps the
|
|
73
|
+
* `iframe`/`use` that the strict author allowlist drops) but stays strict on
|
|
74
|
+
* execution and egress: DOMPurify still strips `<script>`, `on*` handlers, and
|
|
75
|
+
* `javascript:`/`data:text/html` URLs, the module hook strips CSS `url()`
|
|
76
|
+
* beacons, and iframe sources are clamped to `https:`.
|
|
77
|
+
*/
|
|
78
|
+
export function sanitizeComponentHtml(html) {
|
|
79
|
+
return getPurify().sanitize(html, {
|
|
80
|
+
ADD_TAGS: ['conloca-slot', 'iframe', 'use'],
|
|
81
|
+
ADD_ATTR: ['allow', 'allowfullscreen', 'frameborder', 'loading', 'referrerpolicy', 'href', 'xlink:href'],
|
|
82
|
+
});
|
|
83
|
+
}
|
|
84
|
+
//# sourceMappingURL=sanitize-html.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sanitize-html.js","sourceRoot":"","sources":["../../../src/utils/sanitize-html.ts"],"names":[],"mappings":"AAAA,OAAO,eAAe,MAAM,WAAW,CAAC;AAExC;;;;qCAIqC;AACrC,MAAM,cAAc,GAAG,0CAA0C,CAAC;AAElE;;;;;;;;;GASG;AACH,IAAI,MAAM,GAA8C,IAAI,CAAC;AAC7D,SAAS,SAAS;IAChB,IAAI,CAAC,MAAM,EAAE,CAAC;QACZ,MAAM,GAAG,eAAe,CAAC,MAAM,CAAC,CAAC;QACjC,MAAM,CAAC,OAAO,CAAC,yBAAyB,EAAE,CAAC,IAAI,EAAE,EAAE;YACjD,MAAM,EAAE,GAAG,IAAe,CAAC;YAC3B,MAAM,KAAK,GAAG,EAAE,CAAC,YAAY,EAAE,CAAC,OAAO,CAAC,CAAC;YACzC,IAAI,KAAK,IAAI,cAAc,CAAC,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC;gBACxC,MAAM,OAAO,GAAG,KAAK;qBAClB,KAAK,CAAC,GAAG,CAAC;qBACV,MAAM,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;qBAC5C,IAAI,CAAC,GAAG,CAAC,CAAC;gBACb,IAAI,OAAO,CAAC,IAAI,EAAE;oBAAE,EAAE,CAAC,YAAY,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;;oBACjD,EAAE,CAAC,eAAe,CAAC,OAAO,CAAC,CAAC;YACnC,CAAC;YACD,uEAAuE;YACvE,yEAAyE;YACzE,2EAA2E;YAC3E,IAAI,EAAE,CAAC,OAAO,KAAK,QAAQ,EAAE,CAAC;gBAC5B,MAAM,GAAG,GAAG,EAAE,CAAC,YAAY,EAAE,CAAC,KAAK,CAAC,CAAC;gBACrC,IAAI,GAAG,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC;oBAAE,EAAE,CAAC,eAAe,CAAC,KAAK,CAAC,CAAC;YACzE,CAAC;QACH,CAAC,CAAC,CAAC;IACL,CAAC;IACD,OAAO,MAAM,CAAC;AAChB,CAAC;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,UAAU,YAAY,CAAC,IAAY;IACvC,OAAO,SAAS,EAAE,CAAC,QAAQ,CAAC,IAAI,EAAE,EAAE,QAAQ,EAAE,CAAC,cAAc,CAAC,EAAE,CAAC,CAAC;AACpE,CAAC;AAED;;;;;;;;;GASG;AACH,MAAM,UAAU,qBAAqB,CAAC,IAAY;IAChD,OAAO,SAAS,EAAE,CAAC,QAAQ,CAAC,IAAI,EAAE;QAChC,QAAQ,EAAE,CAAC,cAAc,EAAE,QAAQ,EAAE,KAAK,CAAC;QAC3C,QAAQ,EAAE,CAAC,OAAO,EAAE,iBAAiB,EAAE,aAAa,EAAE,SAAS,EAAE,gBAAgB,EAAE,MAAM,EAAE,YAAY,CAAC;KACzG,CAAC,CAAC;AACL,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Convert text to a URL/filename-safe slug.
|
|
3
|
+
* - Keeps the base letter of an accented letter (Ü → u, é → e)
|
|
4
|
+
* - Converts to lowercase
|
|
5
|
+
* - Replaces spaces and special chars with hyphens
|
|
6
|
+
* - Removes consecutive hyphens
|
|
7
|
+
* - Trims hyphens from start/end
|
|
8
|
+
*
|
|
9
|
+
* @example slugify("My Fragment Name!") // "my-fragment-name"
|
|
10
|
+
* @example slugify(" Hello World ") // "hello-world"
|
|
11
|
+
* @example slugify("Über uns") // "uber-uns"
|
|
12
|
+
*/
|
|
13
|
+
export declare function slugify(text: string): string;
|
|
14
|
+
//# sourceMappingURL=slugify.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"slugify.d.ts","sourceRoot":"","sources":["../../../src/utils/slugify.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AACH,wBAAgB,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAQ5C"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Convert text to a URL/filename-safe slug.
|
|
3
|
+
* - Keeps the base letter of an accented letter (Ü → u, é → e)
|
|
4
|
+
* - Converts to lowercase
|
|
5
|
+
* - Replaces spaces and special chars with hyphens
|
|
6
|
+
* - Removes consecutive hyphens
|
|
7
|
+
* - Trims hyphens from start/end
|
|
8
|
+
*
|
|
9
|
+
* @example slugify("My Fragment Name!") // "my-fragment-name"
|
|
10
|
+
* @example slugify(" Hello World ") // "hello-world"
|
|
11
|
+
* @example slugify("Über uns") // "uber-uns"
|
|
12
|
+
*/
|
|
13
|
+
export function slugify(text) {
|
|
14
|
+
return text
|
|
15
|
+
.normalize('NFKD')
|
|
16
|
+
.replace(/\p{M}/gu, '')
|
|
17
|
+
.toLowerCase()
|
|
18
|
+
.trim()
|
|
19
|
+
.replace(/[^a-z0-9]+/g, '-')
|
|
20
|
+
.replace(/^-|-$/g, '');
|
|
21
|
+
}
|
|
22
|
+
//# sourceMappingURL=slugify.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"slugify.js","sourceRoot":"","sources":["../../../src/utils/slugify.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AACH,MAAM,UAAU,OAAO,CAAC,IAAY;IAClC,OAAO,IAAI;SACR,SAAS,CAAC,MAAM,CAAC;SACjB,OAAO,CAAC,SAAS,EAAE,EAAE,CAAC;SACtB,WAAW,EAAE;SACb,IAAI,EAAE;SACN,OAAO,CAAC,aAAa,EAAE,GAAG,CAAC;SAC3B,OAAO,CAAC,QAAQ,EAAE,EAAE,CAAC,CAAC;AAC3B,CAAC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { z } from 'zod';
|
|
2
|
+
export interface FieldInfo {
|
|
3
|
+
type: 'string' | 'number' | 'boolean' | 'date' | 'array' | 'enum';
|
|
4
|
+
format?: 'url' | 'email' | 'date-time';
|
|
5
|
+
/** Help text the schema gives the field, from .describe() or .meta({ description }). */
|
|
6
|
+
description?: string;
|
|
7
|
+
isOptional: boolean;
|
|
8
|
+
isNullable: boolean;
|
|
9
|
+
enumValues?: string[];
|
|
10
|
+
maxLength?: number;
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* Introspects the subset of Zod 3/4 internals required to render form hints.
|
|
14
|
+
* The single assertion is the compatibility boundary; every field read after
|
|
15
|
+
* it is represented explicitly by ZodCompat/ZodDef.
|
|
16
|
+
*/
|
|
17
|
+
export declare function getZodFieldInfo(field: z.ZodRawShape[string]): FieldInfo;
|
|
18
|
+
export declare function getZodShape(schema: z.ZodObject<z.ZodRawShape>): Record<string, FieldInfo>;
|
|
19
|
+
//# sourceMappingURL=zodIntrospect.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"zodIntrospect.d.ts","sourceRoot":"","sources":["../../../src/utils/zodIntrospect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAE7B,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE,QAAQ,GAAG,QAAQ,GAAG,SAAS,GAAG,MAAM,GAAG,OAAO,GAAG,MAAM,CAAC;IAClE,MAAM,CAAC,EAAE,KAAK,GAAG,OAAO,GAAG,WAAW,CAAC;IACvC,wFAAwF;IACxF,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,OAAO,CAAC;IACpB,UAAU,EAAE,OAAO,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;IACtB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AA6CD;;;;GAIG;AACH,wBAAgB,eAAe,CAAC,KAAK,EAAE,CAAC,CAAC,WAAW,CAAC,MAAM,CAAC,GAAG,SAAS,CAoEvE;AAED,wBAAgB,WAAW,CAAC,MAAM,EAAE,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,WAAW,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,CAIzF"}
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
function definition(schema) {
|
|
2
|
+
return schema._def ?? schema._zod?.def;
|
|
3
|
+
}
|
|
4
|
+
function getZodTypeName(def) {
|
|
5
|
+
if (typeof def.typeName === 'string')
|
|
6
|
+
return def.typeName;
|
|
7
|
+
return typeof def.type === 'string' ? def.type : '';
|
|
8
|
+
}
|
|
9
|
+
function readStringCheck(def) {
|
|
10
|
+
const format = def.check === 'string_format' ? def.format : def.kind;
|
|
11
|
+
if (format === 'url' || format === 'email')
|
|
12
|
+
return { format };
|
|
13
|
+
if (def.check === 'max_length' && typeof def.maximum === 'number')
|
|
14
|
+
return { maxLength: def.maximum };
|
|
15
|
+
if (def.kind === 'max' && typeof def.value === 'number')
|
|
16
|
+
return { maxLength: def.value };
|
|
17
|
+
return {};
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* Introspects the subset of Zod 3/4 internals required to render form hints.
|
|
21
|
+
* The single assertion is the compatibility boundary; every field read after
|
|
22
|
+
* it is represented explicitly by ZodCompat/ZodDef.
|
|
23
|
+
*/
|
|
24
|
+
export function getZodFieldInfo(field) {
|
|
25
|
+
// SAFETY: both supported Zod generations expose either _def or _zod.def;
|
|
26
|
+
// ZodCompat contains only optional fields read by this compatibility adapter.
|
|
27
|
+
// oxlint-disable-next-line typescript/no-unsafe-type-assertion -- documented third-party compatibility boundary
|
|
28
|
+
let current = field;
|
|
29
|
+
let isOptional = false;
|
|
30
|
+
let isNullable = false;
|
|
31
|
+
let helpText;
|
|
32
|
+
while (true) {
|
|
33
|
+
helpText ??= current.description;
|
|
34
|
+
const def = definition(current);
|
|
35
|
+
if (!def)
|
|
36
|
+
break;
|
|
37
|
+
const typeName = getZodTypeName(def);
|
|
38
|
+
if (typeName === 'ZodOptional' || typeName === 'optional') {
|
|
39
|
+
isOptional = true;
|
|
40
|
+
}
|
|
41
|
+
else if (typeName === 'ZodNullable' || typeName === 'nullable') {
|
|
42
|
+
isNullable = true;
|
|
43
|
+
}
|
|
44
|
+
else if (typeName !== 'ZodDefault' && typeName !== 'default') {
|
|
45
|
+
break;
|
|
46
|
+
}
|
|
47
|
+
if (!def.innerType)
|
|
48
|
+
break;
|
|
49
|
+
current = def.innerType;
|
|
50
|
+
}
|
|
51
|
+
const def = definition(current);
|
|
52
|
+
const typeName = def ? getZodTypeName(def) : '';
|
|
53
|
+
if (typeName === 'ZodEnum' || typeName === 'enum') {
|
|
54
|
+
const enumValues = Array.isArray(def?.values)
|
|
55
|
+
? def.values.filter((value) => typeof value === 'string')
|
|
56
|
+
: (current.options ?? []);
|
|
57
|
+
return { type: 'enum', enumValues, description: helpText, isOptional, isNullable };
|
|
58
|
+
}
|
|
59
|
+
if (typeName === 'ZodNativeEnum' || typeName === 'nativeEnum') {
|
|
60
|
+
const values = def?.values;
|
|
61
|
+
const enumValues = values && !Array.isArray(values)
|
|
62
|
+
? Object.values(values).filter((value) => typeof value === 'string')
|
|
63
|
+
: [];
|
|
64
|
+
return { type: 'enum', enumValues, description: helpText, isOptional, isNullable };
|
|
65
|
+
}
|
|
66
|
+
if (typeName === 'ZodDate' || typeName === 'date') {
|
|
67
|
+
return { type: 'date', format: 'date-time', description: helpText, isOptional, isNullable };
|
|
68
|
+
}
|
|
69
|
+
if (typeName === 'ZodBoolean' || typeName === 'boolean') {
|
|
70
|
+
return { type: 'boolean', description: helpText, isOptional, isNullable };
|
|
71
|
+
}
|
|
72
|
+
if (typeName === 'ZodNumber' || typeName === 'number') {
|
|
73
|
+
return { type: 'number', description: helpText, isOptional, isNullable };
|
|
74
|
+
}
|
|
75
|
+
if (typeName === 'ZodArray' || typeName === 'array') {
|
|
76
|
+
return { type: 'array', description: helpText, isOptional, isNullable };
|
|
77
|
+
}
|
|
78
|
+
if (typeName === 'ZodString' || typeName === 'string') {
|
|
79
|
+
const checks = def?.checks ?? [];
|
|
80
|
+
const constraints = [def, ...checks.map((check) => check._zod?.def ?? check)]
|
|
81
|
+
.filter((check) => check !== undefined)
|
|
82
|
+
.map(readStringCheck);
|
|
83
|
+
const format = constraints.find((constraint) => constraint.format)?.format;
|
|
84
|
+
const maxLength = constraints.find((constraint) => constraint.maxLength !== undefined)?.maxLength;
|
|
85
|
+
return { type: 'string', format, description: helpText, isOptional, isNullable, maxLength };
|
|
86
|
+
}
|
|
87
|
+
return { type: 'string', description: helpText, isOptional, isNullable };
|
|
88
|
+
}
|
|
89
|
+
export function getZodShape(schema) {
|
|
90
|
+
const result = {};
|
|
91
|
+
for (const [key, field] of Object.entries(schema.shape))
|
|
92
|
+
result[key] = getZodFieldInfo(field);
|
|
93
|
+
return result;
|
|
94
|
+
}
|
|
95
|
+
//# sourceMappingURL=zodIntrospect.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"zodIntrospect.js","sourceRoot":"","sources":["../../../src/utils/zodIntrospect.ts"],"names":[],"mappings":"AAuCA,SAAS,UAAU,CAAC,MAAiB;IACnC,OAAO,MAAM,CAAC,IAAI,IAAI,MAAM,CAAC,IAAI,EAAE,GAAG,CAAC;AACzC,CAAC;AAED,SAAS,cAAc,CAAC,GAAW;IACjC,IAAI,OAAO,GAAG,CAAC,QAAQ,KAAK,QAAQ;Q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GAAG,IAAI,KAAK,CAAC,CAAC;aAC1E,MAAM,CAAC,CAAC,KAAK,EAAmB,EAAE,CAAC,KAAK,KAAK,SAAS,CAAC;aACvD,GAAG,CAAC,eAAe,CAAC,CAAC;QACxB,MAAM,MAAM,GAAG,WAAW,CAAC,IAAI,CAAC,CAAC,UAAU,EAAE,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC;QAC3E,MAAM,SAAS,GAAG,WAAW,CAAC,IAAI,CAAC,CAAC,UAAU,EAAE,EAAE,CAAC,UAAU,CAAC,SAAS,KAAK,SAAS,CAAC,EAAE,SAAS,CAAC;QAClG,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,EAAE,WAAW,EAAE,QAAQ,EAAE,UAAU,EAAE,UAAU,EAAE,SAAS,EAAE,CAAC;IAC9F,CAAC;IAED,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,QAAQ,EAAE,UAAU,EAAE,UAAU,EAAE,CAAC;AAC3E,CAAC;AAED,MAAM,UAAU,WAAW,CAAC,MAAkC;IAC5D,MAAM,MAAM,GAA8B,EAAE,CAAC;IAC7C,KAAK,MAAM,CAAC,GAAG,EAAE,KAAK,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC;QAAE,MAAM,CAAC,GAAG,CAAC,GAAG,eAAe,CAAC,KAAK,CAAC,CAAC;IAC9F,OAAO,MAAM,CAAC;AAChB,CAAC"}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import type { ContentAPIClient } from '@conloca/content-api-client';
|
|
2
|
+
import { type EditorWriteAccess, type EditorWriteRefusal, type UIConfig } from './ui-config.js';
|
|
3
|
+
/** Does a content-API method observe the workspace, or change it? */
|
|
4
|
+
export type ContentMethodAccess = 'read' | 'write';
|
|
5
|
+
/** The classification above, for anything that needs to enumerate it (the tests do). */
|
|
6
|
+
export declare const CONTENT_METHOD_CLASSIFICATION: Readonly<Record<string, ContentMethodAccess>>;
|
|
7
|
+
/**
|
|
8
|
+
* A write the editor refused because the account may not write right now.
|
|
9
|
+
*
|
|
10
|
+
* Carries the refusal rather than a bare string so a surface that catches it
|
|
11
|
+
* can show the reader the same sentence the host wrote, instead of inventing
|
|
12
|
+
* its own guess at what went wrong.
|
|
13
|
+
*/
|
|
14
|
+
export declare class ContentWriteRefusedError extends Error {
|
|
15
|
+
/** The content-API method that was refused, for logs. */
|
|
16
|
+
readonly method: string;
|
|
17
|
+
readonly refusal: EditorWriteRefusal;
|
|
18
|
+
constructor(method: string, refusal: EditorWriteRefusal);
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* What the editor may do to content right now.
|
|
22
|
+
*
|
|
23
|
+
* Absence of {@link UIConfig.readOnly} is the ONLY writable answer, so a host
|
|
24
|
+
* that never learned about this seam gets today's behaviour exactly, and a
|
|
25
|
+
* host that sets it cannot set it without a reason.
|
|
26
|
+
*/
|
|
27
|
+
export declare function editorWriteAccess(config?: UIConfig): EditorWriteAccess;
|
|
28
|
+
/**
|
|
29
|
+
* Wrap the content client so every write consults {@link editorWriteAccess}
|
|
30
|
+
* and every read goes straight through.
|
|
31
|
+
*
|
|
32
|
+
* This is the whole enforcement, in one place. The alternative — teaching
|
|
33
|
+
* each of the dozen mutating surfaces to check first — leaves the next
|
|
34
|
+
* surface someone writes ungated by default, and a gate you have to remember
|
|
35
|
+
* is not a gate. Editing surfaces still MOUNT and still render their content:
|
|
36
|
+
* the person editing still sees everything they would get back by regaining
|
|
37
|
+
* write access, and the published site is unaffected by any of this.
|
|
38
|
+
*
|
|
39
|
+
* The access is read at CALL time, not at wrap time: the host app's answer
|
|
40
|
+
* can land over the network long after the editor mounts, and a write
|
|
41
|
+
* attempted one second after the account was restricted must be refused, not
|
|
42
|
+
* waved through by a stale snapshot.
|
|
43
|
+
*
|
|
44
|
+
* The wrapper delegates through the prototype chain, so it stays an
|
|
45
|
+
* `instanceof ContentAPIClient` and reads cost one extra property lookup.
|
|
46
|
+
*/
|
|
47
|
+
export declare function guardContentWrites(client: ContentAPIClient): ContentAPIClient;
|
|
48
|
+
//# sourceMappingURL=write-access.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"write-access.d.ts","sourceRoot":"","sources":["../../src/write-access.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAC;AACpE,OAAO,EAAE,KAAK,iBAAiB,EAAE,KAAK,kBAAkB,EAAe,KAAK,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAE7G,qEAAqE;AACrE,MAAM,MAAM,mBAAmB,GAAG,MAAM,GAAG,OAAO,CAAC;AA4DnD,wFAAwF;AACxF,eAAO,MAAM,6BAA6B,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,mBAAmB,CAAC,CAAyB,CAAC;AAElH;;;;;;GAMG;AACH,qBAAa,wBAAyB,SAAQ,KAAK;IACjD,yDAAyD;IACzD,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,OAAO,EAAE,kBAAkB,CAAC;IAErC,YAAY,MAAM,EAAE,MAAM,EAAE,OAAO,EAAE,kBAAkB,EAKtD;CACF;AAID;;;;;;GAMG;AACH,wBAAgB,iBAAiB,CAAC,MAAM,GAAE,QAAwB,GAAG,iBAAiB,CAGrF;AAED;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,gBAAgB,GAAG,gBAAgB,CA0B7E"}
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
import { getUIConfig } from './ui-config.js';
|
|
2
|
+
/**
|
|
3
|
+
* Every public method of `ContentAPIClient`, classified.
|
|
4
|
+
*
|
|
5
|
+
* The `satisfies` is the load-bearing part. `Record<keyof ContentAPIClient,
|
|
6
|
+
* ContentMethodAccess>` is TOTAL, so the day the content API grows a method,
|
|
7
|
+
* this object stops compiling until somebody says which kind it is. Without
|
|
8
|
+
* that, a new write would join the client and slip past the gate in silence
|
|
9
|
+
* — and a silently-ungated write against a refused account is precisely the
|
|
10
|
+
* bug this module exists to make impossible.
|
|
11
|
+
* Removed client methods must also be removed from this classification;
|
|
12
|
+
* browser-side helpers are not part of the content API's access boundary.
|
|
13
|
+
*
|
|
14
|
+
* `compileMDX` is a POST and still a read: it renders a preview of content
|
|
15
|
+
* the caller already holds and persists nothing.
|
|
16
|
+
*
|
|
17
|
+
* `pullChanges` is a write. It rewrites the workspace tree from the remote;
|
|
18
|
+
* that it destroys rather than creates does not make it an observation.
|
|
19
|
+
*/
|
|
20
|
+
const CONTENT_METHOD_ACCESS = {
|
|
21
|
+
getContent: 'read',
|
|
22
|
+
getLocalized: 'read',
|
|
23
|
+
createContent: 'write',
|
|
24
|
+
updateLocalized: 'write',
|
|
25
|
+
deleteContent: 'write',
|
|
26
|
+
deleteLocalized: 'write',
|
|
27
|
+
getSitePages: 'read',
|
|
28
|
+
getPageByPathname: 'read',
|
|
29
|
+
isPathnameAvailable: 'read',
|
|
30
|
+
movePage: 'write',
|
|
31
|
+
getFragments: 'read',
|
|
32
|
+
getFragmentByName: 'read',
|
|
33
|
+
compileMDX: 'read',
|
|
34
|
+
getData: 'read',
|
|
35
|
+
getDataByName: 'read',
|
|
36
|
+
isDataNameAvailable: 'read',
|
|
37
|
+
getDataCollections: 'read',
|
|
38
|
+
listAllContent: 'read',
|
|
39
|
+
findUntranslatedContent: 'read',
|
|
40
|
+
getSitesConfig: 'read',
|
|
41
|
+
batchUpdate: 'write',
|
|
42
|
+
getGitStatus: 'read',
|
|
43
|
+
commitChanges: 'write',
|
|
44
|
+
pushChanges: 'write',
|
|
45
|
+
pullChanges: 'write',
|
|
46
|
+
listAssets: 'read',
|
|
47
|
+
getAsset: 'read',
|
|
48
|
+
uploadAsset: 'write',
|
|
49
|
+
importAssetUrl: 'write',
|
|
50
|
+
deleteAsset: 'write',
|
|
51
|
+
listFolder: 'read',
|
|
52
|
+
createFolder: 'write',
|
|
53
|
+
updateAssetMetadata: 'write',
|
|
54
|
+
getAssetUsage: 'read',
|
|
55
|
+
moveAssets: 'write',
|
|
56
|
+
getFolderTree: 'read',
|
|
57
|
+
getCurrentUser: 'read',
|
|
58
|
+
};
|
|
59
|
+
/** The classification above, for anything that needs to enumerate it (the tests do). */
|
|
60
|
+
export const CONTENT_METHOD_CLASSIFICATION = CONTENT_METHOD_ACCESS;
|
|
61
|
+
/**
|
|
62
|
+
* A write the editor refused because the account may not write right now.
|
|
63
|
+
*
|
|
64
|
+
* Carries the refusal rather than a bare string so a surface that catches it
|
|
65
|
+
* can show the reader the same sentence the host wrote, instead of inventing
|
|
66
|
+
* its own guess at what went wrong.
|
|
67
|
+
*/
|
|
68
|
+
export class ContentWriteRefusedError extends Error {
|
|
69
|
+
/** The content-API method that was refused, for logs. */
|
|
70
|
+
method;
|
|
71
|
+
refusal;
|
|
72
|
+
constructor(method, refusal) {
|
|
73
|
+
super(refusal.reason);
|
|
74
|
+
this.name = 'ContentWriteRefusedError';
|
|
75
|
+
this.method = method;
|
|
76
|
+
this.refusal = refusal;
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
const WRITABLE = Object.freeze({ writable: true });
|
|
80
|
+
/**
|
|
81
|
+
* What the editor may do to content right now.
|
|
82
|
+
*
|
|
83
|
+
* Absence of {@link UIConfig.readOnly} is the ONLY writable answer, so a host
|
|
84
|
+
* that never learned about this seam gets today's behaviour exactly, and a
|
|
85
|
+
* host that sets it cannot set it without a reason.
|
|
86
|
+
*/
|
|
87
|
+
export function editorWriteAccess(config = getUIConfig()) {
|
|
88
|
+
const refusal = config.readOnly;
|
|
89
|
+
return refusal === undefined ? WRITABLE : { writable: false, refusal };
|
|
90
|
+
}
|
|
91
|
+
/**
|
|
92
|
+
* Wrap the content client so every write consults {@link editorWriteAccess}
|
|
93
|
+
* and every read goes straight through.
|
|
94
|
+
*
|
|
95
|
+
* This is the whole enforcement, in one place. The alternative — teaching
|
|
96
|
+
* each of the dozen mutating surfaces to check first — leaves the next
|
|
97
|
+
* surface someone writes ungated by default, and a gate you have to remember
|
|
98
|
+
* is not a gate. Editing surfaces still MOUNT and still render their content:
|
|
99
|
+
* the person editing still sees everything they would get back by regaining
|
|
100
|
+
* write access, and the published site is unaffected by any of this.
|
|
101
|
+
*
|
|
102
|
+
* The access is read at CALL time, not at wrap time: the host app's answer
|
|
103
|
+
* can land over the network long after the editor mounts, and a write
|
|
104
|
+
* attempted one second after the account was restricted must be refused, not
|
|
105
|
+
* waved through by a stale snapshot.
|
|
106
|
+
*
|
|
107
|
+
* The wrapper delegates through the prototype chain, so it stays an
|
|
108
|
+
* `instanceof ContentAPIClient` and reads cost one extra property lookup.
|
|
109
|
+
*/
|
|
110
|
+
export function guardContentWrites(client) {
|
|
111
|
+
const guarded = Object.create(client);
|
|
112
|
+
for (const [method, classification] of Object.entries(CONTENT_METHOD_ACCESS)) {
|
|
113
|
+
if (classification !== 'write')
|
|
114
|
+
continue;
|
|
115
|
+
const original = Reflect.get(client, method);
|
|
116
|
+
// A method the client does not have cannot be called, so there is nothing
|
|
117
|
+
// to refuse — this is a total answer, not a tolerated gap. Hosts hand in
|
|
118
|
+
// their own `contentClient` (`UIConfig.contentClient`), and a narrower one
|
|
119
|
+
// than the full surface is ordinary: crashing the editor mount over a
|
|
120
|
+
// method nobody can reach would take the whole editor away from the
|
|
121
|
+
// reader this gate exists to keep reading. The exhaustive
|
|
122
|
+
// classification above is what guarantees no REACHABLE write is
|
|
123
|
+
// unclassified.
|
|
124
|
+
if (typeof original !== 'function')
|
|
125
|
+
continue;
|
|
126
|
+
Object.defineProperty(guarded, method, {
|
|
127
|
+
value: (...args) => {
|
|
128
|
+
const access = editorWriteAccess();
|
|
129
|
+
if (access.writable)
|
|
130
|
+
return original.apply(client, args);
|
|
131
|
+
return Promise.reject(new ContentWriteRefusedError(method, access.refusal));
|
|
132
|
+
},
|
|
133
|
+
writable: false,
|
|
134
|
+
enumerable: false,
|
|
135
|
+
configurable: false,
|
|
136
|
+
});
|
|
137
|
+
}
|
|
138
|
+
return guarded;
|
|
139
|
+
}
|
|
140
|
+
//# sourceMappingURL=write-access.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"write-access.js","sourceRoot":"","sources":["../../src/write-access.ts"],"names":[],"mappings":"AACA,OAAO,EAAmD,WAAW,EAAiB,MAAM,gBAAgB,CAAC;AAK7G;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,qBAAqB,GAAG;IAC5B,UAAU,EAAE,MAAM;IAClB,YAAY,EAAE,MAAM;IACpB,aAAa,EAAE,OAAO;IACtB,eAAe,EAAE,OAAO;IACxB,aAAa,EAAE,OAAO;IACtB,eAAe,EAAE,OAAO;IACxB,YAAY,EAAE,MAAM;IACpB,iBAAiB,EAAE,MAAM;IACzB,mBAAmB,EAAE,MAAM;IAC3B,QAAQ,EAAE,OAAO;IACjB,YAAY,EAAE,MAAM;IACpB,iBAAiB,EAAE,MAAM;IACzB,UAAU,EAAE,MAAM;IAClB,OAAO,EAAE,MAAM;IACf,aAAa,EAAE,MAAM;IACrB,mBAAmB,EAAE,MAAM;IAC3B,kBAAkB,EAAE,MAAM;IAC1B,cAAc,EAAE,MAAM;IACtB,uBAAuB,EAAE,MAAM;IAC/B,cAAc,EAAE,MAAM;IACtB,WAAW,EAAE,OAAO;IACpB,YAAY,EAAE,MAAM;IACpB,aAAa,EAAE,OAAO;IACtB,WAAW,EAAE,OAAO;IACpB,WAAW,EAAE,OAAO;IACpB,UAAU,EAAE,MAAM;IAClB,QAAQ,EAAE,MAAM;IAChB,WAAW,EAAE,OAAO;IACpB,cAAc,EAAE,OAAO;IACvB,WAAW,EAAE,OAAO;IACpB,UAAU,EAAE,MAAM;IAClB,YAAY,EAAE,OAAO;IACrB,mBAAmB,EAAE,OAAO;IAC5B,aAAa,EAAE,MAAM;IACrB,UAAU,EAAE,OAAO;IACnB,aAAa,EAAE,MAAM;IACrB,cAAc,EAAE,M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