@conloca/cms-spa 0.1.15 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/spa/main.css +4078 -3571
- 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 +51 -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 +8 -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 +267 -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 +7 -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 +23 -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 +2 -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 +16 -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 +13 -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 +8 -0
- package/dist/ts/main-spa.d.ts.map +1 -0
- package/dist/ts/main-spa.js +58 -0
- package/dist/ts/main-spa.js.map +1 -0
- package/dist/ts/main.d.ts +2 -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 +21 -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/{puck-config.d.mts → ts/puck-config.d.ts} +11 -14
- 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 +141 -0
- package/dist/ts/site-styles.d.ts.map +1 -0
- package/dist/ts/site-styles.js +426 -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 +249 -0
- package/dist/ts/ui-config.d.ts.map +1 -0
- package/dist/ts/ui-config.js +142 -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 +3 -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 +15 -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 +55 -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 +104 -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 +217 -57
- 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 +496 -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 +69 -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 +524 -0
- package/src/theme.ts +102 -0
- package/src/types.ts +63 -0
- package/src/ui-config.ts +334 -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 +128 -0
- package/dist/data-schemas.d.mts +0 -26
- package/dist/data-schemas.d.mts.map +0 -1
- package/dist/data-schemas.mjs +0 -52
- package/dist/data-schemas.mjs.map +0 -1
- package/dist/index.d.mts +0 -125
- package/dist/index.d.mts.map +0 -1
- package/dist/index.mjs +0 -4
- package/dist/main.d.mts +0 -1
- package/dist/main.mjs +0 -5687
- package/dist/main.mjs.map +0 -1
- package/dist/page-schemas.d.mts +0 -26
- package/dist/page-schemas.d.mts.map +0 -1
- package/dist/page-schemas.mjs +0 -52
- package/dist/page-schemas.mjs.map +0 -1
- package/dist/puck-C9_F3_cJ.mjs +0 -1589
- package/dist/puck-C9_F3_cJ.mjs.map +0 -1
- package/dist/puck-config.d.mts.map +0 -1
- package/dist/puck-config.mjs +0 -51
- package/dist/puck-config.mjs.map +0 -1
- package/dist/site-styles.d.mts +0 -41
- package/dist/site-styles.d.mts.map +0 -1
- package/dist/site-styles.mjs +0 -52
- package/dist/site-styles.mjs.map +0 -1
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
import type { ComponentProps } from 'react';
|
|
2
|
+
import { cn } from '../../utils/cn.js';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Surface vocabulary shared with `Dialog.Content` so any host
|
|
6
|
+
* app that mixes plain cards and dialog panels reads as one
|
|
7
|
+
* design system rather than two.
|
|
8
|
+
*
|
|
9
|
+
* - `panel` — opaque-white-on-light, opaque-grey-on-dark, with a
|
|
10
|
+
* border. The default for sign-in screens, account menus, and
|
|
11
|
+
* any anchored popover. Matches `Dialog.Content surface="panel"`
|
|
12
|
+
* verbatim so a panel that turns into a dialog (or vice versa)
|
|
13
|
+
* doesn't visually jump.
|
|
14
|
+
* - `elevated` — borderless white-on-light, near-black-on-dark.
|
|
15
|
+
* For floating surfaces that read as "lifted off the page"
|
|
16
|
+
* (think menu portals); kept as a separate variant rather than
|
|
17
|
+
* folding into `panel` so the absence of a border is explicit.
|
|
18
|
+
*/
|
|
19
|
+
export type CardSurface = 'panel' | 'elevated';
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* Inner padding scale. The largest card (e.g. a sign-in screen) uses `xl`;
|
|
23
|
+
* tight popovers (account menu) use `sm`; the default `md` covers
|
|
24
|
+
* most cases. `none` exists for callers that want to manage
|
|
25
|
+
* padding internally (e.g. a header row + body split where the
|
|
26
|
+
* dividing line should extend to the card edge).
|
|
27
|
+
*/
|
|
28
|
+
export type CardPadding = 'none' | 'sm' | 'md' | 'lg' | 'xl';
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Border radius. `md` is the conventional Conloca card radius and
|
|
32
|
+
* matches `Dialog.Content surface="panel"`. `lg` is reserved for
|
|
33
|
+
* overlay-style surfaces; `sm` for tight chips that have card
|
|
34
|
+
* affordances (rare).
|
|
35
|
+
*/
|
|
36
|
+
export type CardRadius = 'sm' | 'md' | 'lg';
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* Drop-shadow scale. `sm` is the default for resting cards; `lg`
|
|
40
|
+
* matches the dialog overlay treatment. `none` exists so callers
|
|
41
|
+
* can stack cards inside larger surfaces without a double shadow.
|
|
42
|
+
*/
|
|
43
|
+
export type CardShadow = 'none' | 'sm' | 'md' | 'lg';
|
|
44
|
+
|
|
45
|
+
const SURFACE_CLASS: Record<CardSurface, string> = {
|
|
46
|
+
panel: 'bg-white dark:bg-grey-02 border border-grey-09 dark:border-grey-03',
|
|
47
|
+
elevated: 'bg-white dark:bg-grey-01',
|
|
48
|
+
};
|
|
49
|
+
|
|
50
|
+
const PADDING_CLASS: Record<CardPadding, string> = {
|
|
51
|
+
none: '',
|
|
52
|
+
sm: 'p-2',
|
|
53
|
+
md: 'p-4',
|
|
54
|
+
lg: 'p-6',
|
|
55
|
+
xl: 'px-8 py-10',
|
|
56
|
+
};
|
|
57
|
+
|
|
58
|
+
const RADIUS_CLASS: Record<CardRadius, string> = {
|
|
59
|
+
sm: 'rounded-sm',
|
|
60
|
+
md: 'rounded-md',
|
|
61
|
+
lg: 'rounded-lg',
|
|
62
|
+
};
|
|
63
|
+
|
|
64
|
+
const SHADOW_CLASS: Record<CardShadow, string> = {
|
|
65
|
+
none: '',
|
|
66
|
+
sm: 'shadow-sm',
|
|
67
|
+
md: 'shadow-md',
|
|
68
|
+
lg: 'shadow-lg',
|
|
69
|
+
};
|
|
70
|
+
|
|
71
|
+
export interface CardProps extends ComponentProps<'div'> {
|
|
72
|
+
/** Visual surface treatment. Default `panel`. */
|
|
73
|
+
surface?: CardSurface;
|
|
74
|
+
/** Inner padding scale. Default `md`. */
|
|
75
|
+
padding?: CardPadding;
|
|
76
|
+
/** Corner radius. Default `md`. */
|
|
77
|
+
radius?: CardRadius;
|
|
78
|
+
/** Drop shadow scale. Default `sm`. */
|
|
79
|
+
shadow?: CardShadow;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
/**
|
|
83
|
+
* Generic card surface primitive.
|
|
84
|
+
*
|
|
85
|
+
* Host apps (sign-in screens, account menus, banner panels,
|
|
86
|
+
* etc.) compose this rather than restating
|
|
87
|
+
* `bg-white dark:bg-grey-02 border border-grey-09 ... rounded-md
|
|
88
|
+
* shadow-sm` at every call site. Centralising the surface here:
|
|
89
|
+
*
|
|
90
|
+
* - keeps the visual vocabulary aligned with `Dialog.Content`
|
|
91
|
+
* (same `panel` classes — see `SURFACE_CLASS`)
|
|
92
|
+
* - prevents drift (no more "this screen has px-8 py-10, that one
|
|
93
|
+
* has px-6 py-8 and nobody noticed")
|
|
94
|
+
* - dodges the CSS cascade-layer fight that bites raw Tailwind
|
|
95
|
+
* `px-*` / `py-*` classes on consumers outside cms-spa. Card's
|
|
96
|
+
* classes are compiled into cms-spa's bundle alongside the
|
|
97
|
+
* Tailwind preflight reset, so they resolve in the same layer
|
|
98
|
+
* and the reset's `* { padding: 0 }` doesn't win.
|
|
99
|
+
*
|
|
100
|
+
* Layout (`flex`, `gap-*`, `max-w-*`, alignment) stays on the
|
|
101
|
+
* caller via `className` — Card owns the surface; the caller owns
|
|
102
|
+
* what's inside and how the card sits on the page.
|
|
103
|
+
*/
|
|
104
|
+
export function Card({
|
|
105
|
+
surface = 'panel',
|
|
106
|
+
padding = 'md',
|
|
107
|
+
radius = 'md',
|
|
108
|
+
shadow = 'sm',
|
|
109
|
+
className,
|
|
110
|
+
...rest
|
|
111
|
+
}: CardProps) {
|
|
112
|
+
return (
|
|
113
|
+
<div
|
|
114
|
+
className={cn(
|
|
115
|
+
SURFACE_CLASS[surface],
|
|
116
|
+
PADDING_CLASS[padding],
|
|
117
|
+
RADIUS_CLASS[radius],
|
|
118
|
+
SHADOW_CLASS[shadow],
|
|
119
|
+
className,
|
|
120
|
+
)}
|
|
121
|
+
{...rest}
|
|
122
|
+
/>
|
|
123
|
+
);
|
|
124
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { AlertCircle } from 'lucide-react';
|
|
2
|
+
import type { ReactNode } from 'react';
|
|
3
|
+
import { cn } from '../../utils/cn.js';
|
|
4
|
+
|
|
5
|
+
interface FieldErrorProps {
|
|
6
|
+
/**
|
|
7
|
+
* Optional id so the form field can wire `aria-describedby` to the
|
|
8
|
+
* error message for assistive tech.
|
|
9
|
+
*/
|
|
10
|
+
id?: string;
|
|
11
|
+
className?: string;
|
|
12
|
+
children: ReactNode;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* Inline form-error message: small alert-circle icon + red text-xs body.
|
|
17
|
+
*
|
|
18
|
+
* Renders with `role="alert"` so the browser surfaces the message to
|
|
19
|
+
* assistive tech the moment it appears. Pair with `aria-invalid` on
|
|
20
|
+
* the field and `aria-describedby` pointing at this element's id.
|
|
21
|
+
*
|
|
22
|
+
* Layout: `inline-flex items-center gap-2`. Drop-in replacement for the
|
|
23
|
+
* `<AlertCircle h-3 w-3 /> + text-xs text-red-04` pattern that was
|
|
24
|
+
* being hand-rolled across host app form fields.
|
|
25
|
+
*/
|
|
26
|
+
export function FieldError({ id, className, children }: FieldErrorProps) {
|
|
27
|
+
return (
|
|
28
|
+
<span
|
|
29
|
+
id={id}
|
|
30
|
+
role="alert"
|
|
31
|
+
className={cn('inline-flex items-center gap-2 text-xs text-red-04 dark:text-red-08', className)}
|
|
32
|
+
>
|
|
33
|
+
<AlertCircle aria-hidden className="h-3 w-3 flex-shrink-0" />
|
|
34
|
+
<span>{children}</span>
|
|
35
|
+
</span>
|
|
36
|
+
);
|
|
37
|
+
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import type { LucideIcon } from 'lucide-react';
|
|
2
|
+
import { cn } from '../../utils/cn.js';
|
|
3
|
+
|
|
4
|
+
interface IconButtonProps {
|
|
5
|
+
icon: LucideIcon;
|
|
6
|
+
onClick?: () => void;
|
|
7
|
+
ariaLabel: string;
|
|
8
|
+
title?: string;
|
|
9
|
+
className?: string;
|
|
10
|
+
iconSize?: string;
|
|
11
|
+
variant?: 'default' | 'ghost';
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
export function IconButton({
|
|
15
|
+
icon: Icon,
|
|
16
|
+
onClick,
|
|
17
|
+
ariaLabel,
|
|
18
|
+
title,
|
|
19
|
+
className,
|
|
20
|
+
iconSize = 'h-4 w-4',
|
|
21
|
+
variant = 'default',
|
|
22
|
+
}: IconButtonProps) {
|
|
23
|
+
const baseClasses = 'p-2 rounded-md transition-all duration-150 cursor-pointer';
|
|
24
|
+
const variantClasses = {
|
|
25
|
+
default: 'text-grey-03 dark:text-grey-09 hover:bg-hover hover:text-grey-01 dark:hover:text-grey-12',
|
|
26
|
+
ghost: 'text-grey-04 dark:text-grey-07 hover:bg-hover hover:text-grey-01 dark:hover:text-grey-12',
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
return (
|
|
30
|
+
<button
|
|
31
|
+
type="button"
|
|
32
|
+
onClick={onClick}
|
|
33
|
+
className={cn(baseClasses, variantClasses[variant], className)}
|
|
34
|
+
aria-label={ariaLabel}
|
|
35
|
+
title={title || ariaLabel}
|
|
36
|
+
>
|
|
37
|
+
<Icon className={iconSize} />
|
|
38
|
+
</button>
|
|
39
|
+
);
|
|
40
|
+
}
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import type { InputHTMLAttributes, Ref } from 'react';
|
|
2
|
+
import { cn } from '../../utils/cn.js';
|
|
3
|
+
|
|
4
|
+
interface InputProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size'> {
|
|
5
|
+
/**
|
|
6
|
+
* Visual size:
|
|
7
|
+
* - `default` — comfortable padding, body type.
|
|
8
|
+
* - `sm` — same padding, smaller (text-sm) type. Width-flexible.
|
|
9
|
+
* - `xs` — height-locked at `h-8` with `text-sm`. The chrome-strip
|
|
10
|
+
* size; pairs with `Button size="sm"` so toolbars and inline form
|
|
11
|
+
* rows align cleanly.
|
|
12
|
+
*/
|
|
13
|
+
size?: 'default' | 'sm' | 'xs';
|
|
14
|
+
/**
|
|
15
|
+
* Surface the input sits on:
|
|
16
|
+
* - `panel` (default) — `bg-panel` / `border-line`. Use inside
|
|
17
|
+
* panel-tone surfaces (cms-spa dialogs and side panels) where
|
|
18
|
+
* the input should read recessed against the panel.
|
|
19
|
+
* - `elevated` — `bg-white dark:bg-grey-01`, explicit grey border.
|
|
20
|
+
* Use inside chrome surfaces (host app top bars, panel-toned dialogs)
|
|
21
|
+
* where `bg-panel` (which collapses to `grey-02` in dark mode)
|
|
22
|
+
* would blend with the surface itself. The elevated bg is
|
|
23
|
+
* blacker than the strip's grey-02 in dark mode, restoring the
|
|
24
|
+
* contrast that the panel surface erases.
|
|
25
|
+
*/
|
|
26
|
+
surface?: 'panel' | 'elevated';
|
|
27
|
+
/**
|
|
28
|
+
* When true, drops the default `w-full` so the input is laid out at
|
|
29
|
+
* its native intrinsic width (driven by the HTML `size` attribute
|
|
30
|
+
* or any `min-w-*` className). Use inside inline-flex form rows or
|
|
31
|
+
* flex columns where the input shouldn't dominate the row width.
|
|
32
|
+
*/
|
|
33
|
+
intrinsic?: boolean;
|
|
34
|
+
error?: boolean;
|
|
35
|
+
ref?: Ref<HTMLInputElement>;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export function Input({
|
|
39
|
+
size = 'default',
|
|
40
|
+
surface = 'panel',
|
|
41
|
+
intrinsic = false,
|
|
42
|
+
error,
|
|
43
|
+
className,
|
|
44
|
+
ref,
|
|
45
|
+
...props
|
|
46
|
+
}: InputProps) {
|
|
47
|
+
return (
|
|
48
|
+
<input
|
|
49
|
+
ref={ref}
|
|
50
|
+
className={cn(
|
|
51
|
+
intrinsic ? null : 'w-full',
|
|
52
|
+
'rounded-md border text-grey-01 dark:text-grey-12',
|
|
53
|
+
'focus:outline-none focus:ring-2 focus:ring-azure-04',
|
|
54
|
+
size === 'xs' ? 'h-8 px-3 text-sm' : size === 'sm' ? 'px-3 py-2 text-sm' : 'px-3 py-2',
|
|
55
|
+
surface === 'elevated' ? 'bg-white dark:bg-grey-01' : 'bg-panel',
|
|
56
|
+
error
|
|
57
|
+
? 'border-red-04 focus:ring-red-04'
|
|
58
|
+
: surface === 'elevated'
|
|
59
|
+
? 'border-grey-09 dark:border-grey-04'
|
|
60
|
+
: 'border-line',
|
|
61
|
+
className,
|
|
62
|
+
)}
|
|
63
|
+
{...props}
|
|
64
|
+
/>
|
|
65
|
+
);
|
|
66
|
+
}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { AlertTriangle, Check, Loader2, X } from 'lucide-react';
|
|
2
|
+
import type { SaveState } from '../../types.js';
|
|
3
|
+
import { cn } from '../../utils/cn.js';
|
|
4
|
+
|
|
5
|
+
interface SaveIndicatorProps {
|
|
6
|
+
state: SaveState;
|
|
7
|
+
className?: string;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
export function SaveIndicator({ state, className }: SaveIndicatorProps) {
|
|
11
|
+
const stateConfig = {
|
|
12
|
+
idle: null,
|
|
13
|
+
saving: {
|
|
14
|
+
icon: <Loader2 className="lucide lucide-loader-2 h-4 w-4 animate-spin" />,
|
|
15
|
+
text: 'Saving...',
|
|
16
|
+
className: 'text-grey-04',
|
|
17
|
+
},
|
|
18
|
+
saved: {
|
|
19
|
+
icon: <Check className="lucide lucide-check h-4 w-4" />,
|
|
20
|
+
text: 'Saved',
|
|
21
|
+
className: 'text-green-06',
|
|
22
|
+
},
|
|
23
|
+
error: {
|
|
24
|
+
icon: <X className="lucide lucide-x h-4 w-4" />,
|
|
25
|
+
text: 'Error',
|
|
26
|
+
className: 'text-red-04 dark:text-red-08',
|
|
27
|
+
},
|
|
28
|
+
conflict: {
|
|
29
|
+
icon: <AlertTriangle className="lucide lucide-alert-triangle h-4 w-4" />,
|
|
30
|
+
text: 'Conflict',
|
|
31
|
+
className: 'text-yellow-06',
|
|
32
|
+
},
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
const config = stateConfig[state];
|
|
36
|
+
if (!config) return null;
|
|
37
|
+
|
|
38
|
+
return (
|
|
39
|
+
<div className={cn('flex items-center gap-2', config.className, className)} data-testid={`save-indicator-${state}`}>
|
|
40
|
+
{config.icon}
|
|
41
|
+
<span className="text-sm">{config.text}</span>
|
|
42
|
+
</div>
|
|
43
|
+
);
|
|
44
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import type { Ref, SelectHTMLAttributes } from 'react';
|
|
2
|
+
import { cn } from '../../utils/cn.js';
|
|
3
|
+
|
|
4
|
+
interface SelectProps extends Omit<SelectHTMLAttributes<HTMLSelectElement>, 'size'> {
|
|
5
|
+
size?: 'default' | 'sm';
|
|
6
|
+
ref?: Ref<HTMLSelectElement>;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
export function Select({ size = 'default', className, children, ref, ...props }: SelectProps) {
|
|
10
|
+
return (
|
|
11
|
+
<select
|
|
12
|
+
ref={ref}
|
|
13
|
+
className={cn(
|
|
14
|
+
// appearance-none removes the native OS chrome (white box on dark themes,
|
|
15
|
+
// platform-default fonts). The custom chevron is painted via background-image
|
|
16
|
+
// so the select still looks like a dropdown without the cross-OS inconsistency.
|
|
17
|
+
'w-full appearance-none rounded-md border bg-panel border-line text-grey-01 dark:text-grey-12',
|
|
18
|
+
'pr-8 bg-no-repeat bg-[length:1.25rem_1.25rem] bg-[right_0.5rem_center]',
|
|
19
|
+
"bg-[url(\"data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='20' height='20' fill='none' viewBox='0 0 20 20'><path stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/></svg>\")]",
|
|
20
|
+
'focus:outline-none focus:ring-2 focus:ring-azure-04',
|
|
21
|
+
size === 'sm' ? 'px-3 py-1.5 text-sm' : 'px-3 py-2',
|
|
22
|
+
className,
|
|
23
|
+
)}
|
|
24
|
+
{...props}
|
|
25
|
+
>
|
|
26
|
+
{children}
|
|
27
|
+
</select>
|
|
28
|
+
);
|
|
29
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { cn } from '../../utils/cn.js';
|
|
2
|
+
|
|
3
|
+
interface SeparatorProps {
|
|
4
|
+
className?: string;
|
|
5
|
+
orientation?: 'vertical' | 'horizontal';
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
export function Separator({ className, orientation = 'vertical' }: SeparatorProps) {
|
|
9
|
+
if (orientation === 'horizontal') {
|
|
10
|
+
return <hr className={cn('w-full h-px border-0 bg-grey-09 dark:bg-grey-04', className)} />;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
return <hr aria-orientation="vertical" className={cn('h-5 w-px border-0 bg-grey-09 dark:bg-grey-04', className)} />;
|
|
14
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { Ref, TextareaHTMLAttributes } from 'react';
|
|
2
|
+
import { cn } from '../../utils/cn.js';
|
|
3
|
+
|
|
4
|
+
interface TextareaProps extends TextareaHTMLAttributes<HTMLTextAreaElement> {
|
|
5
|
+
error?: boolean;
|
|
6
|
+
ref?: Ref<HTMLTextAreaElement>;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
export function Textarea({ error, className, ref, ...props }: TextareaProps) {
|
|
10
|
+
return (
|
|
11
|
+
<textarea
|
|
12
|
+
ref={ref}
|
|
13
|
+
className={cn(
|
|
14
|
+
'w-full px-3 py-2 rounded-md border bg-panel text-grey-01 dark:text-grey-12',
|
|
15
|
+
'focus:outline-none focus:ring-2 focus:ring-azure-04',
|
|
16
|
+
error ? 'border-red-04 focus:ring-red-04' : 'border-line',
|
|
17
|
+
className,
|
|
18
|
+
)}
|
|
19
|
+
{...props}
|
|
20
|
+
/>
|
|
21
|
+
);
|
|
22
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
|
|
3
|
+
interface TooltipProps {
|
|
4
|
+
content: string;
|
|
5
|
+
children: ReactNode;
|
|
6
|
+
className?: string;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
export function Tooltip({ content, children, className = '' }: TooltipProps) {
|
|
10
|
+
return (
|
|
11
|
+
<div className="relative inline-block group/tooltip">
|
|
12
|
+
{children}
|
|
13
|
+
<div
|
|
14
|
+
role="tooltip"
|
|
15
|
+
className={`invisible group-hover/tooltip:visible group-focus-within/tooltip:visible pointer-events-none absolute z-10 px-3 py-2 text-sm text-white bg-grey-01 rounded-lg shadow-sm
|
|
16
|
+
bottom-full left-1/2 transform -translate-x-1/2 mb-2 whitespace-nowrap ${className}`}
|
|
17
|
+
>
|
|
18
|
+
{content}
|
|
19
|
+
<div className="absolute top-full left-1/2 transform -translate-x-1/2 -mt-1">
|
|
20
|
+
<div className="w-0 h-0 border-l-4 border-r-4 border-t-4 border-l-transparent border-r-transparent border-t-grey-01" />
|
|
21
|
+
</div>
|
|
22
|
+
</div>
|
|
23
|
+
</div>
|
|
24
|
+
);
|
|
25
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
// Conloca brand mark — used by host apps that render their own
|
|
2
|
+
// sign-in surfaces (e.g. a host app's sign-in screen). Lives in the `/ui`
|
|
3
|
+
// subpath so consumers can import it without pulling the heavy main
|
|
4
|
+
// barrel (which imports the MDX editor + sandpack-react), mirroring
|
|
5
|
+
// the existing precedent for thin per-piece imports.
|
|
6
|
+
export { ConlocaLogo } from '../ConlocaLogo.js';
|
|
7
|
+
export type { BannerProps, BannerVariant } from './Banner.js';
|
|
8
|
+
export { Banner } from './Banner.js';
|
|
9
|
+
export { Button } from './Button.js';
|
|
10
|
+
export { Card } from './Card.js';
|
|
11
|
+
export { FieldError } from './FieldError.js';
|
|
12
|
+
export { IconButton } from './IconButton.js';
|
|
13
|
+
export { Input } from './Input.js';
|
|
14
|
+
export { SaveIndicator } from './SaveIndicator.js';
|
|
15
|
+
export { Select } from './Select.js';
|
|
16
|
+
export { Separator } from './Separator.js';
|
|
17
|
+
export { Textarea } from './Textarea.js';
|
|
18
|
+
export { Tooltip } from './Tooltip.js';
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
import { useEffect, useState } from 'react';
|
|
2
|
+
import type { z } from 'zod';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Type for a collection of data schemas.
|
|
6
|
+
* Each key is a collection name, value is the Zod schema for that collection's data.
|
|
7
|
+
*/
|
|
8
|
+
export type DataSchemas = Record<string, z.ZodObject<z.ZodRawShape>>;
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* Shared state for data schemas across module instances.
|
|
12
|
+
* Uses window to ensure virtual modules and bundled code share the same state.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
interface SharedDataState {
|
|
16
|
+
schemas: DataSchemas;
|
|
17
|
+
subscribers: Set<(schemas: DataSchemas) => void>;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
declare global {
|
|
21
|
+
interface Window {
|
|
22
|
+
__DATA_SCHEMAS_STATE__?: SharedDataState;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
const getSharedState = (): SharedDataState => {
|
|
27
|
+
if (typeof window !== 'undefined') {
|
|
28
|
+
if (!window.__DATA_SCHEMAS_STATE__) {
|
|
29
|
+
window.__DATA_SCHEMAS_STATE__ = {
|
|
30
|
+
schemas: {},
|
|
31
|
+
subscribers: new Set(),
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
return window.__DATA_SCHEMAS_STATE__;
|
|
35
|
+
}
|
|
36
|
+
// SSR fallback
|
|
37
|
+
return { schemas: {}, subscribers: new Set() };
|
|
38
|
+
};
|
|
39
|
+
|
|
40
|
+
/**
|
|
41
|
+
* Set the data schemas for all collections.
|
|
42
|
+
* Called by the virtual module that loads user's schema definitions.
|
|
43
|
+
* Notifies all subscribers of the change (enables HMR).
|
|
44
|
+
*/
|
|
45
|
+
export function setDataSchemas(schemas: DataSchemas): void {
|
|
46
|
+
const state = getSharedState();
|
|
47
|
+
state.schemas = schemas;
|
|
48
|
+
state.subscribers.forEach((fn) => {
|
|
49
|
+
fn(schemas);
|
|
50
|
+
});
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* Get the current data schemas synchronously.
|
|
55
|
+
*/
|
|
56
|
+
export function getDataSchemas(): DataSchemas {
|
|
57
|
+
return getSharedState().schemas;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
/**
|
|
61
|
+
* React hook to subscribe to data schema changes.
|
|
62
|
+
* Returns the current schemas and updates when they change (HMR support).
|
|
63
|
+
*/
|
|
64
|
+
export function useDataSchemas(): DataSchemas {
|
|
65
|
+
const [schemas, setSchemas] = useState(() => getSharedState().schemas);
|
|
66
|
+
|
|
67
|
+
useEffect(() => {
|
|
68
|
+
const state = getSharedState();
|
|
69
|
+
|
|
70
|
+
// Update immediately in case schemas changed between render and effect
|
|
71
|
+
if (state.schemas !== schemas) {
|
|
72
|
+
setSchemas(state.schemas);
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
state.subscribers.add(setSchemas);
|
|
76
|
+
return () => {
|
|
77
|
+
state.subscribers.delete(setSchemas);
|
|
78
|
+
};
|
|
79
|
+
}, [schemas]);
|
|
80
|
+
|
|
81
|
+
return schemas;
|
|
82
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { mockPuckConfig } from './mock-puck-config.js';
|
|
2
|
+
import { setPuckConfig } from './puck-config.js';
|
|
3
|
+
import { configureUI } from './ui-config.js';
|
|
4
|
+
|
|
5
|
+
// Configure UI for development - this must happen before main.tsx runs
|
|
6
|
+
configureUI({
|
|
7
|
+
basename: '/',
|
|
8
|
+
enableDevtools: true,
|
|
9
|
+
queryClientOptions: {
|
|
10
|
+
defaultOptions: {
|
|
11
|
+
queries: {
|
|
12
|
+
staleTime: 1000 * 60 * 5, // 5 minutes
|
|
13
|
+
retry: 1,
|
|
14
|
+
},
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
});
|
|
18
|
+
|
|
19
|
+
// Install the mock components. The editor reads its config through
|
|
20
|
+
// `getPuckConfig()`, so assigning a bare `window.__PUCK_CONFIG__` here — as this
|
|
21
|
+
// did — left the dev palette empty.
|
|
22
|
+
setPuckConfig(mockPuckConfig);
|
|
23
|
+
|
|
24
|
+
// Import main synchronously
|
|
25
|
+
import './main.js';
|
package/src/dev.html
ADDED
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
<!doctype html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="UTF-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
6
|
+
<title>Conloca CMS Dev</title>
|
|
7
|
+
<link rel="stylesheet" href="./main.processed.css" />
|
|
8
|
+
</head>
|
|
9
|
+
<body>
|
|
10
|
+
<!--
|
|
11
|
+
Paint the theme on <html> before React mounts, exactly like the shipped
|
|
12
|
+
entry does — see `main.html` for why this copy cannot import `./theme`.
|
|
13
|
+
The canonical text lives there as `PRE_PAINT_THEME_SCRIPT`;
|
|
14
|
+
`src/pre-paint-theme.test.ts` discovers this file by glob too and fails
|
|
15
|
+
the build if it drifts.
|
|
16
|
+
-->
|
|
17
|
+
<script>
|
|
18
|
+
(() => {
|
|
19
|
+
try {
|
|
20
|
+
const stored = localStorage.getItem('conloca-theme');
|
|
21
|
+
const pref = stored === 'light' || stored === 'dark' || stored === 'system' ? stored : 'system';
|
|
22
|
+
const resolved =
|
|
23
|
+
pref === 'system' ? (window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light') : pref;
|
|
24
|
+
if (resolved === 'dark') document.documentElement.classList.add('dark');
|
|
25
|
+
document.documentElement.setAttribute('data-theme', resolved);
|
|
26
|
+
document.documentElement.style.colorScheme = resolved;
|
|
27
|
+
} catch (_e) {
|
|
28
|
+
// localStorage / matchMedia unavailable (private mode,
|
|
29
|
+
// ancient browser) — fall back to the light default.
|
|
30
|
+
}
|
|
31
|
+
})();
|
|
32
|
+
</script>
|
|
33
|
+
<div id="root"></div>
|
|
34
|
+
<script type="module" src="./dev-entry.tsx"></script>
|
|
35
|
+
</body>
|
|
36
|
+
</html>
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
export type EditorFlushResult = { ok: true } | { ok: false; message: string };
|
|
2
|
+
|
|
3
|
+
type FlushHandler = () => Promise<EditorFlushResult>;
|
|
4
|
+
type DirtyGetter = () => boolean;
|
|
5
|
+
|
|
6
|
+
let handler: FlushHandler | null = null;
|
|
7
|
+
let dirtyGetter: DirtyGetter | null = null;
|
|
8
|
+
|
|
9
|
+
/** A host's save control and its Cmd+S handler listen for this to re-read {@link isOpenEditorDirty}. */
|
|
10
|
+
export const EDITOR_DIRTY_CHANGED_EVENT = 'conloca:editor-dirty-changed';
|
|
11
|
+
|
|
12
|
+
export function notifyEditorDirtyChanged(): void {
|
|
13
|
+
if (typeof window === 'undefined') return;
|
|
14
|
+
window.dispatchEvent(new Event(EDITOR_DIRTY_CHANGED_EVENT));
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* Register the open document editor's flush callback (and optional live dirty
|
|
19
|
+
* getter). A host's save control arms when {@link isOpenEditorDirty} is true,
|
|
20
|
+
* even if the host's own view of saved changes still reads clean. Returns
|
|
21
|
+
* unregister.
|
|
22
|
+
*/
|
|
23
|
+
export function registerEditorFlushHandler(fn: FlushHandler, options?: { isDirty?: DirtyGetter }): () => void {
|
|
24
|
+
handler = fn;
|
|
25
|
+
dirtyGetter = options?.isDirty ?? null;
|
|
26
|
+
notifyEditorDirtyChanged();
|
|
27
|
+
return () => {
|
|
28
|
+
if (handler === fn) {
|
|
29
|
+
handler = null;
|
|
30
|
+
dirtyGetter = null;
|
|
31
|
+
notifyEditorDirtyChanged();
|
|
32
|
+
}
|
|
33
|
+
};
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
/** True when the mounted editor has in-memory edits not yet flushed. */
|
|
37
|
+
export function isOpenEditorDirty(): boolean {
|
|
38
|
+
return dirtyGetter?.() === true;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
/** Host calls before commit. No editor open → success no-op. */
|
|
42
|
+
export async function flushOpenEditor(): Promise<EditorFlushResult> {
|
|
43
|
+
if (!handler) return { ok: true };
|
|
44
|
+
const result = await handler();
|
|
45
|
+
notifyEditorDirtyChanged();
|
|
46
|
+
return result;
|
|
47
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export type { AssetEntry, AssetUsage, FolderListing, FolderTreeNode } from '@conloca/content-api-client';
|
|
2
|
+
export {
|
|
3
|
+
useAsset,
|
|
4
|
+
useAssetFolders,
|
|
5
|
+
useAssets,
|
|
6
|
+
useAssetUsage,
|
|
7
|
+
useBulkDeleteAssets,
|
|
8
|
+
useCreateFolder,
|
|
9
|
+
useDeleteAsset,
|
|
10
|
+
useFolderTree,
|
|
11
|
+
useImportAssetUrl,
|
|
12
|
+
useMoveAssets,
|
|
13
|
+
useUpdateAssetMetadata,
|
|
14
|
+
useUploadAsset,
|
|
15
|
+
} from '@conloca/content-api-client';
|
|
16
|
+
export { useClickOutside } from './useClickOutside.js';
|
|
17
|
+
export { useDialogState } from './useDialogState.js';
|
|
18
|
+
export { useErrorModal } from './useErrorModal.js';
|
|
19
|
+
export { useSiteBaseUrl } from './useSiteBaseUrl.js';
|
|
20
|
+
export { buildUploadFormData, useImportUrl, useUpload } from './useUpload.js';
|
|
21
|
+
export type { UploadProgress, UseUploadFlowReturn } from './useUploadFlow.js';
|
|
22
|
+
export { ACCEPTED_TYPES, useUploadFlow } from './useUploadFlow.js';
|