@instructure/platform-block-content-editor 0.3.1 → 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +187 -0
- package/dist/components/MediaPlaceholder/MediaPlaceholder.d.ts.map +1 -1
- package/dist/components/RichText/RichText.d.ts +20 -0
- package/dist/components/RichText/RichText.d.ts.map +1 -0
- package/dist/components/RichText/index.d.ts +2 -0
- package/dist/components/RichText/index.d.ts.map +1 -0
- package/dist/components/blocks/Accordion/Accordion.d.ts.map +1 -1
- package/dist/components/blocks/Accordion/accordionTranslations.d.ts +15 -0
- package/dist/components/blocks/Accordion/accordionTranslations.d.ts.map +1 -0
- package/dist/components/blocks/Accordion/createAccordionBlock.d.ts +22 -0
- package/dist/components/blocks/Accordion/createAccordionBlock.d.ts.map +1 -0
- package/dist/components/blocks/Accordion/index.d.ts +2 -0
- package/dist/components/blocks/Accordion/index.d.ts.map +1 -1
- package/dist/components/blocks/Banner/Banner.d.ts.map +1 -1
- package/dist/components/blocks/Banner/bannerPropsSchema.d.ts +0 -2
- package/dist/components/blocks/Banner/bannerPropsSchema.d.ts.map +1 -1
- package/dist/components/blocks/Banner/bannerTranslations.d.ts +13 -0
- package/dist/components/blocks/Banner/bannerTranslations.d.ts.map +1 -0
- package/dist/components/blocks/Banner/createBannerBlock.d.ts +14 -0
- package/dist/components/blocks/Banner/createBannerBlock.d.ts.map +1 -0
- package/dist/components/blocks/Banner/getBannerViewProps.d.ts +2 -3
- package/dist/components/blocks/Banner/getBannerViewProps.d.ts.map +1 -1
- package/dist/components/blocks/Banner/index.d.ts +2 -0
- package/dist/components/blocks/Banner/index.d.ts.map +1 -1
- package/dist/components/blocks/CodeBlock/CodeBlock.d.ts.map +1 -1
- package/dist/components/blocks/CodeBlock/codeBlockPropsSchema.d.ts +2 -2
- package/dist/components/blocks/CodeBlock/codeBlockTranslations.d.ts +11 -0
- package/dist/components/blocks/CodeBlock/codeBlockTranslations.d.ts.map +1 -0
- package/dist/components/blocks/CodeBlock/createCodeBlock.d.ts +12 -0
- package/dist/components/blocks/CodeBlock/createCodeBlock.d.ts.map +1 -0
- package/dist/components/blocks/CodeBlock/index.d.ts +2 -0
- package/dist/components/blocks/CodeBlock/index.d.ts.map +1 -1
- package/dist/components/blocks/FlashCards/FlashCard.d.ts +21 -0
- package/dist/components/blocks/FlashCards/FlashCard.d.ts.map +1 -0
- package/dist/components/blocks/FlashCards/FlashCards.d.ts +4 -0
- package/dist/components/blocks/FlashCards/FlashCards.d.ts.map +1 -0
- package/dist/components/blocks/FlashCards/createFlashCardsBlock.d.ts +15 -0
- package/dist/components/blocks/FlashCards/createFlashCardsBlock.d.ts.map +1 -0
- package/dist/components/blocks/FlashCards/flashCardsPropsSchema.d.ts +60 -0
- package/dist/components/blocks/FlashCards/flashCardsPropsSchema.d.ts.map +1 -0
- package/dist/components/blocks/FlashCards/flashCardsStyles.d.ts +43 -0
- package/dist/components/blocks/FlashCards/flashCardsStyles.d.ts.map +1 -0
- package/dist/components/blocks/FlashCards/flashCardsTranslations.d.ts +34 -0
- package/dist/components/blocks/FlashCards/flashCardsTranslations.d.ts.map +1 -0
- package/dist/components/blocks/FlashCards/getFlashCardsViewProps.d.ts +23 -0
- package/dist/components/blocks/FlashCards/getFlashCardsViewProps.d.ts.map +1 -0
- package/dist/components/blocks/FlashCards/index.d.ts +5 -0
- package/dist/components/blocks/FlashCards/index.d.ts.map +1 -0
- package/dist/components/blocks/ImageBlock/ImageBlock.d.ts.map +1 -1
- package/dist/components/blocks/ImageBlock/createImageBlock.d.ts +15 -0
- package/dist/components/blocks/ImageBlock/createImageBlock.d.ts.map +1 -0
- package/dist/components/blocks/ImageBlock/getImageBlockViewProps.d.ts +3 -1
- package/dist/components/blocks/ImageBlock/getImageBlockViewProps.d.ts.map +1 -1
- package/dist/components/blocks/ImageBlock/imageBlockTranslations.d.ts +15 -0
- package/dist/components/blocks/ImageBlock/imageBlockTranslations.d.ts.map +1 -0
- package/dist/components/blocks/ImageBlock/index.d.ts +2 -0
- package/dist/components/blocks/ImageBlock/index.d.ts.map +1 -1
- package/dist/components/blocks/KnowledgeCheck/AnswerCard.d.ts +19 -0
- package/dist/components/blocks/KnowledgeCheck/AnswerCard.d.ts.map +1 -0
- package/dist/components/blocks/KnowledgeCheck/KnowledgeCheck.d.ts +4 -0
- package/dist/components/blocks/KnowledgeCheck/KnowledgeCheck.d.ts.map +1 -0
- package/dist/components/blocks/KnowledgeCheck/createKnowledgeCheckBlock.d.ts +18 -0
- package/dist/components/blocks/KnowledgeCheck/createKnowledgeCheckBlock.d.ts.map +1 -0
- package/dist/components/blocks/KnowledgeCheck/getKnowledgeCheckViewProps.d.ts +34 -0
- package/dist/components/blocks/KnowledgeCheck/getKnowledgeCheckViewProps.d.ts.map +1 -0
- package/dist/components/blocks/KnowledgeCheck/index.d.ts +5 -0
- package/dist/components/blocks/KnowledgeCheck/index.d.ts.map +1 -0
- package/dist/components/blocks/KnowledgeCheck/knowledgeCheckPropsSchema.d.ts +87 -0
- package/dist/components/blocks/KnowledgeCheck/knowledgeCheckPropsSchema.d.ts.map +1 -0
- package/dist/components/blocks/KnowledgeCheck/knowledgeCheckTranslations.d.ts +35 -0
- package/dist/components/blocks/KnowledgeCheck/knowledgeCheckTranslations.d.ts.map +1 -0
- package/dist/components/blocks/LayoutContainer/LayoutContainer.d.ts +3 -0
- package/dist/components/blocks/LayoutContainer/LayoutContainer.d.ts.map +1 -0
- package/dist/components/blocks/LayoutContainer/createLayoutContainerBlock.d.ts +22 -0
- package/dist/components/blocks/LayoutContainer/createLayoutContainerBlock.d.ts.map +1 -0
- package/dist/components/blocks/LayoutContainer/getLayoutContainerViewProps.d.ts +32 -0
- package/dist/components/blocks/LayoutContainer/getLayoutContainerViewProps.d.ts.map +1 -0
- package/dist/components/blocks/LayoutContainer/index.d.ts +5 -0
- package/dist/components/blocks/LayoutContainer/index.d.ts.map +1 -0
- package/dist/components/blocks/LayoutContainer/layoutContainerPropsSchema.d.ts +118 -0
- package/dist/components/blocks/LayoutContainer/layoutContainerPropsSchema.d.ts.map +1 -0
- package/dist/components/blocks/MixAndMatch/MatchCard.d.ts +21 -0
- package/dist/components/blocks/MixAndMatch/MatchCard.d.ts.map +1 -0
- package/dist/components/blocks/MixAndMatch/MixAndMatch.d.ts +4 -0
- package/dist/components/blocks/MixAndMatch/MixAndMatch.d.ts.map +1 -0
- package/dist/components/blocks/MixAndMatch/createMixAndMatchBlock.d.ts +15 -0
- package/dist/components/blocks/MixAndMatch/createMixAndMatchBlock.d.ts.map +1 -0
- package/dist/components/blocks/MixAndMatch/getMixAndMatchViewProps.d.ts +43 -0
- package/dist/components/blocks/MixAndMatch/getMixAndMatchViewProps.d.ts.map +1 -0
- package/dist/components/blocks/MixAndMatch/index.d.ts +5 -0
- package/dist/components/blocks/MixAndMatch/index.d.ts.map +1 -0
- package/dist/components/blocks/MixAndMatch/mixAndMatchPropsSchema.d.ts +74 -0
- package/dist/components/blocks/MixAndMatch/mixAndMatchPropsSchema.d.ts.map +1 -0
- package/dist/components/blocks/MixAndMatch/mixAndMatchStyles.d.ts +21 -0
- package/dist/components/blocks/MixAndMatch/mixAndMatchStyles.d.ts.map +1 -0
- package/dist/components/blocks/MixAndMatch/mixAndMatchTranslations.d.ts +37 -0
- package/dist/components/blocks/MixAndMatch/mixAndMatchTranslations.d.ts.map +1 -0
- package/dist/components/blocks/Quote/Quote.d.ts.map +1 -1
- package/dist/components/blocks/Quote/createQuoteBlock.d.ts +12 -0
- package/dist/components/blocks/Quote/createQuoteBlock.d.ts.map +1 -0
- package/dist/components/blocks/Quote/index.d.ts +2 -0
- package/dist/components/blocks/Quote/index.d.ts.map +1 -1
- package/dist/components/blocks/Quote/quoteTranslations.d.ts +13 -0
- package/dist/components/blocks/Quote/quoteTranslations.d.ts.map +1 -0
- package/dist/components/blocks/TabsBlock/TabsBlock.d.ts +4 -0
- package/dist/components/blocks/TabsBlock/TabsBlock.d.ts.map +1 -0
- package/dist/components/blocks/TabsBlock/createTabsBlock.d.ts +25 -0
- package/dist/components/blocks/TabsBlock/createTabsBlock.d.ts.map +1 -0
- package/dist/components/blocks/TabsBlock/getTabsBlockViewProps.d.ts +55 -0
- package/dist/components/blocks/TabsBlock/getTabsBlockViewProps.d.ts.map +1 -0
- package/dist/components/blocks/TabsBlock/index.d.ts +6 -0
- package/dist/components/blocks/TabsBlock/index.d.ts.map +1 -0
- package/dist/components/blocks/TabsBlock/tabsBlockPropsSchema.d.ts +127 -0
- package/dist/components/blocks/TabsBlock/tabsBlockPropsSchema.d.ts.map +1 -0
- package/dist/components/blocks/TabsBlock/tabsBlockTranslations.d.ts +13 -0
- package/dist/components/blocks/TabsBlock/tabsBlockTranslations.d.ts.map +1 -0
- package/dist/components/blocks/TabsBlock/useRovingTabIndex.d.ts +20 -0
- package/dist/components/blocks/TabsBlock/useRovingTabIndex.d.ts.map +1 -0
- package/dist/components/blocks/Text/Text.d.ts.map +1 -1
- package/dist/components/blocks/Text/createTextBlock.d.ts +12 -0
- package/dist/components/blocks/Text/createTextBlock.d.ts.map +1 -0
- package/dist/components/blocks/Text/index.d.ts +2 -0
- package/dist/components/blocks/Text/index.d.ts.map +1 -1
- package/dist/components/blocks/Text/textPropsSchema.d.ts +3 -3
- package/dist/components/blocks/Text/textTranslations.d.ts +11 -0
- package/dist/components/blocks/Text/textTranslations.d.ts.map +1 -0
- package/dist/components/blocks/TwoColumn/TwoColumn.d.ts +3 -0
- package/dist/components/blocks/TwoColumn/TwoColumn.d.ts.map +1 -0
- package/dist/components/blocks/TwoColumn/createTwoColumnBlock.d.ts +14 -0
- package/dist/components/blocks/TwoColumn/createTwoColumnBlock.d.ts.map +1 -0
- package/dist/components/blocks/TwoColumn/getTwoColumnViewProps.d.ts +17 -0
- package/dist/components/blocks/TwoColumn/getTwoColumnViewProps.d.ts.map +1 -0
- package/dist/components/blocks/TwoColumn/index.d.ts +5 -0
- package/dist/components/blocks/TwoColumn/index.d.ts.map +1 -0
- package/dist/components/blocks/TwoColumn/twoColumnPropsSchema.d.ts +60 -0
- package/dist/components/blocks/TwoColumn/twoColumnPropsSchema.d.ts.map +1 -0
- package/dist/components/blocks/TwoColumn/twoColumnStyles.d.ts +13 -0
- package/dist/components/blocks/TwoColumn/twoColumnStyles.d.ts.map +1 -0
- package/dist/components/blocks/VideoBlock/VideoBlock.d.ts.map +1 -1
- package/dist/components/blocks/VideoBlock/createVideoBlock.d.ts +15 -0
- package/dist/components/blocks/VideoBlock/createVideoBlock.d.ts.map +1 -0
- package/dist/components/blocks/VideoBlock/index.d.ts +3 -1
- package/dist/components/blocks/VideoBlock/index.d.ts.map +1 -1
- package/dist/components/blocks/VideoBlock/videoBlockTranslations.d.ts +23 -0
- package/dist/components/blocks/VideoBlock/videoBlockTranslations.d.ts.map +1 -0
- package/dist/components/blocks/WidgetBlock/WidgetBlock.d.ts +8 -0
- package/dist/components/blocks/WidgetBlock/WidgetBlock.d.ts.map +1 -0
- package/dist/components/blocks/WidgetBlock/WidgetErrorBoundary.d.ts +36 -0
- package/dist/components/blocks/WidgetBlock/WidgetErrorBoundary.d.ts.map +1 -0
- package/dist/components/blocks/WidgetBlock/createWidgetBlock.d.ts +14 -0
- package/dist/components/blocks/WidgetBlock/createWidgetBlock.d.ts.map +1 -0
- package/dist/components/blocks/WidgetBlock/index.d.ts +5 -0
- package/dist/components/blocks/WidgetBlock/index.d.ts.map +1 -0
- package/dist/components/blocks/WidgetBlock/widgetBlockPropsSchema.d.ts +26 -0
- package/dist/components/blocks/WidgetBlock/widgetBlockPropsSchema.d.ts.map +1 -0
- package/dist/components/blocks/WidgetBlock/widgetBlockTranslations.d.ts +18 -0
- package/dist/components/blocks/WidgetBlock/widgetBlockTranslations.d.ts.map +1 -0
- package/dist/components/blocks/commonSchemas.d.ts +13 -0
- package/dist/components/blocks/commonSchemas.d.ts.map +1 -1
- package/dist/components/blocks/commonViewProps.d.ts +23 -1
- package/dist/components/blocks/commonViewProps.d.ts.map +1 -1
- package/dist/components/blocks/richTextTableStyles.d.ts +10 -0
- package/dist/components/blocks/richTextTableStyles.d.ts.map +1 -0
- package/dist/contexts/AIActionContext.d.ts +38 -0
- package/dist/contexts/AIActionContext.d.ts.map +1 -0
- package/dist/contexts/BlockEditorApiContext.d.ts +139 -4
- package/dist/contexts/BlockEditorApiContext.d.ts.map +1 -1
- package/dist/contexts/BlockTranslationsContext.d.ts +47 -0
- package/dist/contexts/BlockTranslationsContext.d.ts.map +1 -0
- package/dist/contexts/RichTextEditorContext.d.ts +28 -0
- package/dist/contexts/RichTextEditorContext.d.ts.map +1 -0
- package/dist/contexts/RichTextRendererContext.d.ts +21 -0
- package/dist/contexts/RichTextRendererContext.d.ts.map +1 -0
- package/dist/editor/BlockContentEditor.d.ts +40 -0
- package/dist/editor/BlockContentEditor.d.ts.map +1 -0
- package/dist/editor/ai/BlockAIMenu.d.ts +17 -0
- package/dist/editor/ai/BlockAIMenu.d.ts.map +1 -0
- package/dist/editor/ai/BlockAIMenuContent.d.ts +17 -0
- package/dist/editor/ai/BlockAIMenuContent.d.ts.map +1 -0
- package/dist/editor/ai/PreviewBlockModal.d.ts +29 -0
- package/dist/editor/ai/PreviewBlockModal.d.ts.map +1 -0
- package/dist/editor/ai/aiMenuStyles.d.ts +23 -0
- package/dist/editor/ai/aiMenuStyles.d.ts.map +1 -0
- package/dist/editor/ai/aiTranslations.d.ts +79 -0
- package/dist/editor/ai/aiTranslations.d.ts.map +1 -0
- package/dist/editor/ai/aiTypes.d.ts +13 -0
- package/dist/editor/ai/aiTypes.d.ts.map +1 -0
- package/dist/editor/ai/constants.d.ts +8 -0
- package/dist/editor/ai/constants.d.ts.map +1 -0
- package/dist/editor/ai/index.d.ts +7 -0
- package/dist/editor/ai/index.d.ts.map +1 -0
- package/dist/editor/ai/useBlockAIPopover.d.ts +30 -0
- package/dist/editor/ai/useBlockAIPopover.d.ts.map +1 -0
- package/dist/editor/ai/useGenerateAltText.d.ts +11 -0
- package/dist/editor/ai/useGenerateAltText.d.ts.map +1 -0
- package/dist/editor/canvas/DesignerArea.d.ts +38 -0
- package/dist/editor/canvas/DesignerArea.d.ts.map +1 -0
- package/dist/editor/canvas/DesignerCanvas.d.ts +35 -0
- package/dist/editor/canvas/DesignerCanvas.d.ts.map +1 -0
- package/dist/editor/canvas/DropGridOverlay.d.ts +24 -0
- package/dist/editor/canvas/DropGridOverlay.d.ts.map +1 -0
- package/dist/editor/canvas/GridDndContext.d.ts +11 -0
- package/dist/editor/canvas/GridDndContext.d.ts.map +1 -0
- package/dist/editor/canvas/GridDndProvider.d.ts +17 -0
- package/dist/editor/canvas/GridDndProvider.d.ts.map +1 -0
- package/dist/editor/canvas/GridItemChild.d.ts +44 -0
- package/dist/editor/canvas/GridItemChild.d.ts.map +1 -0
- package/dist/editor/canvas/GridItemContainer.d.ts +49 -0
- package/dist/editor/canvas/GridItemContainer.d.ts.map +1 -0
- package/dist/editor/canvas/GridViewer.d.ts +114 -0
- package/dist/editor/canvas/GridViewer.d.ts.map +1 -0
- package/dist/editor/canvas/TwoColumnDesigner.d.ts +34 -0
- package/dist/editor/canvas/TwoColumnDesigner.d.ts.map +1 -0
- package/dist/editor/canvas/canvasStyles.d.ts +36 -0
- package/dist/editor/canvas/canvasStyles.d.ts.map +1 -0
- package/dist/editor/canvas/canvasTranslations.d.ts +64 -0
- package/dist/editor/canvas/canvasTranslations.d.ts.map +1 -0
- package/dist/editor/canvas/index.d.ts +5 -0
- package/dist/editor/canvas/index.d.ts.map +1 -0
- package/dist/editor/document/constants.d.ts +23 -0
- package/dist/editor/document/constants.d.ts.map +1 -0
- package/dist/editor/document/designerItemAction.d.ts +16 -0
- package/dist/editor/document/designerItemAction.d.ts.map +1 -0
- package/dist/editor/document/utils.d.ts +172 -0
- package/dist/editor/document/utils.d.ts.map +1 -0
- package/dist/editor/document/utils.test.d.ts +2 -0
- package/dist/editor/document/utils.test.d.ts.map +1 -0
- package/dist/editor/history/types.d.ts +25 -0
- package/dist/editor/history/types.d.ts.map +1 -0
- package/dist/editor/history/undoRedoManager.d.ts +3 -0
- package/dist/editor/history/undoRedoManager.d.ts.map +1 -0
- package/dist/editor/history/undoRedoManager.test.d.ts +2 -0
- package/dist/editor/history/undoRedoManager.test.d.ts.map +1 -0
- package/dist/editor/history/useUndoRedo.d.ts +11 -0
- package/dist/editor/history/useUndoRedo.d.ts.map +1 -0
- package/dist/editor/history/useUndoRedo.test.d.ts +2 -0
- package/dist/editor/history/useUndoRedo.test.d.ts.map +1 -0
- package/dist/editor/index.d.ts +16 -0
- package/dist/editor/index.d.ts.map +1 -0
- package/dist/editor/preview/PreviewArea.d.ts +31 -0
- package/dist/editor/preview/PreviewArea.d.ts.map +1 -0
- package/dist/editor/preview/constants.d.ts +9 -0
- package/dist/editor/preview/constants.d.ts.map +1 -0
- package/dist/editor/preview/index.d.ts +4 -0
- package/dist/editor/preview/index.d.ts.map +1 -0
- package/dist/editor/preview/previewStyles.d.ts +20 -0
- package/dist/editor/preview/previewStyles.d.ts.map +1 -0
- package/dist/editor/preview/previewTranslations.d.ts +18 -0
- package/dist/editor/preview/previewTranslations.d.ts.map +1 -0
- package/dist/editor/sidebar/DesignerNav.d.ts +28 -0
- package/dist/editor/sidebar/DesignerNav.d.ts.map +1 -0
- package/dist/editor/sidebar/form/ComponentEditorForm.d.ts +12 -0
- package/dist/editor/sidebar/form/ComponentEditorForm.d.ts.map +1 -0
- package/dist/editor/sidebar/form/FormFieldWrapper.d.ts +13 -0
- package/dist/editor/sidebar/form/FormFieldWrapper.d.ts.map +1 -0
- package/dist/editor/sidebar/form/fieldRendererUtils.d.ts +24 -0
- package/dist/editor/sidebar/form/fieldRendererUtils.d.ts.map +1 -0
- package/dist/editor/sidebar/form/fieldRenderers.d.ts +6 -0
- package/dist/editor/sidebar/form/fieldRenderers.d.ts.map +1 -0
- package/dist/editor/sidebar/form/formTranslations.d.ts +92 -0
- package/dist/editor/sidebar/form/formTranslations.d.ts.map +1 -0
- package/dist/editor/sidebar/form/formUtils.d.ts +7 -0
- package/dist/editor/sidebar/form/formUtils.d.ts.map +1 -0
- package/dist/editor/sidebar/form/index.d.ts +7 -0
- package/dist/editor/sidebar/form/index.d.ts.map +1 -0
- package/dist/editor/sidebar/form/knowledgeCheckEditor.d.ts +10 -0
- package/dist/editor/sidebar/form/knowledgeCheckEditor.d.ts.map +1 -0
- package/dist/editor/sidebar/form/renderers/AltTextFieldRenderer.d.ts +4 -0
- package/dist/editor/sidebar/form/renderers/AltTextFieldRenderer.d.ts.map +1 -0
- package/dist/editor/sidebar/form/renderers/AnswerArrayFieldRenderer.d.ts +4 -0
- package/dist/editor/sidebar/form/renderers/AnswerArrayFieldRenderer.d.ts.map +1 -0
- package/dist/editor/sidebar/form/renderers/ObjectArrayFieldRenderer.d.ts +4 -0
- package/dist/editor/sidebar/form/renderers/ObjectArrayFieldRenderer.d.ts.map +1 -0
- package/dist/editor/sidebar/form/uploaders/FileUploader.d.ts +24 -0
- package/dist/editor/sidebar/form/uploaders/FileUploader.d.ts.map +1 -0
- package/dist/editor/sidebar/form/uploaders/ImageUploader.d.ts +8 -0
- package/dist/editor/sidebar/form/uploaders/ImageUploader.d.ts.map +1 -0
- package/dist/editor/sidebar/form/uploaders/VideoUploader.d.ts +8 -0
- package/dist/editor/sidebar/form/uploaders/VideoUploader.d.ts.map +1 -0
- package/dist/editor/sidebar/panel/DesignerSideBar.d.ts +18 -0
- package/dist/editor/sidebar/panel/DesignerSideBar.d.ts.map +1 -0
- package/dist/editor/sidebar/panel/MobileToolOverlay.d.ts +13 -0
- package/dist/editor/sidebar/panel/MobileToolOverlay.d.ts.map +1 -0
- package/dist/editor/sidebar/panel/MobileToolbar.d.ts +10 -0
- package/dist/editor/sidebar/panel/MobileToolbar.d.ts.map +1 -0
- package/dist/editor/sidebar/panel/ToolBody.d.ts +11 -0
- package/dist/editor/sidebar/panel/ToolBody.d.ts.map +1 -0
- package/dist/editor/sidebar/panel/ToolContentContainer.d.ts +27 -0
- package/dist/editor/sidebar/panel/ToolContentContainer.d.ts.map +1 -0
- package/dist/editor/sidebar/panel/ToolHeader.d.ts +24 -0
- package/dist/editor/sidebar/panel/ToolHeader.d.ts.map +1 -0
- package/dist/editor/sidebar/panel/ToolHeaderActionsContext.d.ts +8 -0
- package/dist/editor/sidebar/panel/ToolHeaderActionsContext.d.ts.map +1 -0
- package/dist/editor/sidebar/panel/ToolIconButtons.d.ts +19 -0
- package/dist/editor/sidebar/panel/ToolIconButtons.d.ts.map +1 -0
- package/dist/editor/sidebar/panel/ToolWrapper.d.ts +16 -0
- package/dist/editor/sidebar/panel/ToolWrapper.d.ts.map +1 -0
- package/dist/editor/sidebar/panel/constants.d.ts +23 -0
- package/dist/editor/sidebar/panel/constants.d.ts.map +1 -0
- package/dist/editor/sidebar/panel/index.d.ts +5 -0
- package/dist/editor/sidebar/panel/index.d.ts.map +1 -0
- package/dist/editor/sidebar/panel/panelStyles.d.ts +29 -0
- package/dist/editor/sidebar/panel/panelStyles.d.ts.map +1 -0
- package/dist/editor/sidebar/panel/types.d.ts +80 -0
- package/dist/editor/sidebar/panel/types.d.ts.map +1 -0
- package/dist/editor/sidebar/panel/useFocusReturn.d.ts +8 -0
- package/dist/editor/sidebar/panel/useFocusReturn.d.ts.map +1 -0
- package/dist/editor/sidebar/sidebarTranslations.d.ts +53 -0
- package/dist/editor/sidebar/sidebarTranslations.d.ts.map +1 -0
- package/dist/editor/sidebar/tray/BlockTray.d.ts +30 -0
- package/dist/editor/sidebar/tray/BlockTray.d.ts.map +1 -0
- package/dist/editor/sidebar/tray/ComponentsTray.d.ts +4 -0
- package/dist/editor/sidebar/tray/ComponentsTray.d.ts.map +1 -0
- package/dist/editor/sidebar/tray/InteractiveTray.d.ts +4 -0
- package/dist/editor/sidebar/tray/InteractiveTray.d.ts.map +1 -0
- package/dist/editor/sidebar/tray/LayoutTray.d.ts +4 -0
- package/dist/editor/sidebar/tray/LayoutTray.d.ts.map +1 -0
- package/dist/editor/sidebar/tray/SharedTrayComponents.d.ts +64 -0
- package/dist/editor/sidebar/tray/SharedTrayComponents.d.ts.map +1 -0
- package/dist/editor/sidebar/tray/TemplatesPanel.d.ts +4 -0
- package/dist/editor/sidebar/tray/TemplatesPanel.d.ts.map +1 -0
- package/dist/editor/sidebar/tray/TrayDragLayer.d.ts +14 -0
- package/dist/editor/sidebar/tray/TrayDragLayer.d.ts.map +1 -0
- package/dist/editor/sidebar/tray/blockDefinitions.d.ts +11 -0
- package/dist/editor/sidebar/tray/blockDefinitions.d.ts.map +1 -0
- package/dist/editor/sidebar/tray/index.d.ts +9 -0
- package/dist/editor/sidebar/tray/index.d.ts.map +1 -0
- package/dist/editor/sidebar/tray/trayStyles.d.ts +20 -0
- package/dist/editor/sidebar/tray/trayStyles.d.ts.map +1 -0
- package/dist/editor/sidebar/useDesignerSelectionFocus.d.ts +51 -0
- package/dist/editor/sidebar/useDesignerSelectionFocus.d.ts.map +1 -0
- package/dist/editor/state/applyTemplatePatch.d.ts +46 -0
- package/dist/editor/state/applyTemplatePatch.d.ts.map +1 -0
- package/dist/editor/state/applyTemplatePatch.test.d.ts +2 -0
- package/dist/editor/state/applyTemplatePatch.test.d.ts.map +1 -0
- package/dist/editor/state/useBlockEditorState.d.ts +57 -0
- package/dist/editor/state/useBlockEditorState.d.ts.map +1 -0
- package/dist/editor/state/useBlockEditorState.test.d.ts +2 -0
- package/dist/editor/state/useBlockEditorState.test.d.ts.map +1 -0
- package/dist/editor/validation/templateDataValidator.d.ts +48 -0
- package/dist/editor/validation/templateDataValidator.d.ts.map +1 -0
- package/dist/editor/validation/templateDataValidator.test.d.ts +2 -0
- package/dist/editor/validation/templateDataValidator.test.d.ts.map +1 -0
- package/dist/index.d.ts +16 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +15561 -767
- package/dist/registry/blockCatalogue.d.ts +108 -0
- package/dist/registry/blockCatalogue.d.ts.map +1 -0
- package/dist/registry/blockRegistry.d.ts +75 -0
- package/dist/registry/blockRegistry.d.ts.map +1 -0
- package/dist/registry/defineBlock.d.ts +60 -0
- package/dist/registry/defineBlock.d.ts.map +1 -0
- package/dist/registry/getMergedProps.d.ts +18 -0
- package/dist/registry/getMergedProps.d.ts.map +1 -0
- package/dist/registry/index.d.ts +7 -0
- package/dist/registry/index.d.ts.map +1 -0
- package/dist/registry/registryTypes.test.d.ts +1 -0
- package/dist/registry/registryTypes.test.d.ts.map +1 -0
- package/dist/registry/resolveBlockEntry.d.ts +16 -0
- package/dist/registry/resolveBlockEntry.d.ts.map +1 -0
- package/dist/registry/templateTypes.d.ts +61 -0
- package/dist/registry/templateTypes.d.ts.map +1 -0
- package/dist/schema/index.d.ts +1 -1
- package/dist/schema/index.d.ts.map +1 -1
- package/dist/schema/zodExtensions.d.ts +17 -0
- package/dist/schema/zodExtensions.d.ts.map +1 -1
- package/dist/utils/shuffleCards.d.ts +6 -0
- package/dist/utils/shuffleCards.d.ts.map +1 -0
- package/dist/utils/useMediaQuery.d.ts +7 -0
- package/dist/utils/useMediaQuery.d.ts.map +1 -0
- package/dist/utils/useMotionEnabled.d.ts +11 -0
- package/dist/utils/useMotionEnabled.d.ts.map +1 -0
- package/dist/viewer/Viewer.d.ts +27 -0
- package/dist/viewer/Viewer.d.ts.map +1 -0
- package/dist/viewer/index.d.ts +2 -0
- package/dist/viewer/index.d.ts.map +1 -0
- package/locales/en.json +169 -1
- package/package.json +72 -24
- package/dist/contexts/TranslationsContext.d.ts +0 -70
- package/dist/contexts/TranslationsContext.d.ts.map +0 -1
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export { ComponentEditorForm, type ComponentEditorFormProps } from './ComponentEditorForm';
|
|
2
|
+
export { FormFieldWrapper } from './FormFieldWrapper';
|
|
3
|
+
export { fieldRendererRegistry, getFieldRenderer } from './fieldRenderers';
|
|
4
|
+
export type { FieldRenderFn, FieldRenderProps } from './fieldRendererUtils';
|
|
5
|
+
export { getItemSubtitle } from './formUtils';
|
|
6
|
+
export { DesignerFormEnglish, type DesignerFormTranslations } from './formTranslations';
|
|
7
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/editor/sidebar/form/index.ts"],"names":[],"mappings":"AAkBA,OAAO,EAAE,mBAAmB,EAAE,KAAK,wBAAwB,EAAE,MAAM,uBAAuB,CAAA;AAC1F,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AACrD,OAAO,EAAE,qBAAqB,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAA;AAC1E,YAAY,EAAE,aAAa,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAA;AAC3E,OAAO,EAAE,eAAe,EAAE,MAAM,aAAa,CAAA;AAC7C,OAAO,EAAE,mBAAmB,EAAE,KAAK,wBAAwB,EAAE,MAAM,oBAAoB,CAAA"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { KnowledgeCheckAnswer, QuestionType } from '../../../components/blocks/KnowledgeCheck';
|
|
2
|
+
export type { KnowledgeCheckAnswer, QuestionType };
|
|
3
|
+
/** Question type: Multiple choice or True/False. */
|
|
4
|
+
export declare const QuestionTypeEnum: {
|
|
5
|
+
readonly MULTIPLE_CHOICE: "Multiple choice";
|
|
6
|
+
readonly TRUE_FALSE: "True or false";
|
|
7
|
+
};
|
|
8
|
+
/** Default answers for a new multiple-choice question in the editor. */
|
|
9
|
+
export declare const DEFAULT_MULTIPLE_CHOICE_ANSWERS: KnowledgeCheckAnswer[];
|
|
10
|
+
//# sourceMappingURL=knowledgeCheckEditor.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"knowledgeCheckEditor.d.ts","sourceRoot":"","sources":["../../../../src/editor/sidebar/form/knowledgeCheckEditor.ts"],"names":[],"mappings":"AAkBA;;;;;GAKG;AAEH,OAAO,KAAK,EAAE,oBAAoB,EAAE,YAAY,EAAE,MAAM,2CAA2C,CAAA;AAEnG,YAAY,EAAE,oBAAoB,EAAE,YAAY,EAAE,CAAA;AAElD,oDAAoD;AACpD,eAAO,MAAM,gBAAgB;;;CAGoB,CAAA;AAEjD,wEAAwE;AACxE,eAAO,MAAM,+BAA+B,EAAE,oBAAoB,EAIjE,CAAA"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import { FieldRenderProps } from '../fieldRendererUtils';
|
|
3
|
+
export declare function AltTextFieldRenderer({ metadata, control, fieldError, onFieldChange, setValue, disabled, }: FieldRenderProps): ReactElement;
|
|
4
|
+
//# sourceMappingURL=AltTextFieldRenderer.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AltTextFieldRenderer.d.ts","sourceRoot":"","sources":["../../../../../src/editor/sidebar/form/renderers/AltTextFieldRenderer.tsx"],"names":[],"mappings":"AAyBA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,OAAO,CAAA;AASzC,OAAO,EAAE,KAAK,gBAAgB,EAAoB,MAAM,uBAAuB,CAAA;AAE/E,wBAAgB,oBAAoB,CAAC,EACnC,QAAQ,EACR,OAAO,EACP,UAAU,EACV,aAAa,EACb,QAAQ,EACR,QAAQ,GACT,EAAE,gBAAgB,GAAG,YAAY,CAuGjC"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import { FieldRenderProps } from '../fieldRendererUtils';
|
|
3
|
+
export declare function AnswerArrayFieldRenderer({ metadata, control, fieldError, onFieldChange, }: FieldRenderProps): ReactElement;
|
|
4
|
+
//# sourceMappingURL=AnswerArrayFieldRenderer.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AnswerArrayFieldRenderer.d.ts","sourceRoot":"","sources":["../../../../../src/editor/sidebar/form/renderers/AnswerArrayFieldRenderer.tsx"],"names":[],"mappings":"AA2BA,OAAO,EAAE,KAAK,YAAY,EAA4B,MAAM,OAAO,CAAA;AAQnE,OAAO,EAAE,KAAK,gBAAgB,EAAgC,MAAM,uBAAuB,CAAA;AAU3F,wBAAgB,wBAAwB,CAAC,EACvC,QAAQ,EACR,OAAO,EACP,UAAU,EACV,aAAa,GACd,EAAE,gBAAgB,GAAG,YAAY,CAmLjC"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
2
|
+
import { FieldRenderProps } from '../fieldRendererUtils';
|
|
3
|
+
export declare function ObjectArrayFieldRenderer({ metadata, control, fieldError, onFieldChange, isManageLayer, }: FieldRenderProps): ReactElement;
|
|
4
|
+
//# sourceMappingURL=ObjectArrayFieldRenderer.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ObjectArrayFieldRenderer.d.ts","sourceRoot":"","sources":["../../../../../src/editor/sidebar/form/renderers/ObjectArrayFieldRenderer.tsx"],"names":[],"mappings":"AAyCA,OAAO,EAAsB,KAAK,YAAY,EAAwB,MAAM,OAAO,CAAA;AAWnF,OAAO,EAAE,KAAK,gBAAgB,EAAgC,MAAM,uBAAuB,CAAA;AAuG3F,wBAAgB,wBAAwB,CAAC,EACvC,QAAQ,EACR,OAAO,EACP,UAAU,EACV,aAAa,EACb,aAAa,GACd,EAAE,gBAAgB,GAAG,YAAY,CAwIjC"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { Control, FieldValues } from 'react-hook-form';
|
|
3
|
+
import { ResolvedUploadedFile } from '../../../../contexts/BlockEditorApiContext';
|
|
4
|
+
export interface FileUploaderConfig {
|
|
5
|
+
acceptedExtensions: string[];
|
|
6
|
+
maxFileSizeBytes: number;
|
|
7
|
+
uploadLabel: string;
|
|
8
|
+
acceptedTypesLabel: string;
|
|
9
|
+
maxSizeLabel: string;
|
|
10
|
+
replaceScreenReaderLabel: string;
|
|
11
|
+
uploadingLabel: string;
|
|
12
|
+
sizeErrorLabel: string;
|
|
13
|
+
}
|
|
14
|
+
export type FileUploaderMediaType = 'image' | 'video';
|
|
15
|
+
export interface FileUploaderProps {
|
|
16
|
+
control: Control<FieldValues>;
|
|
17
|
+
onFieldChange: () => void;
|
|
18
|
+
config: FileUploaderConfig;
|
|
19
|
+
renderPreview: (file: ResolvedUploadedFile) => ReactNode;
|
|
20
|
+
header?: ReactNode;
|
|
21
|
+
mediaType?: FileUploaderMediaType;
|
|
22
|
+
}
|
|
23
|
+
export declare function FileUploader({ control, onFieldChange, config, renderPreview, header, mediaType, }: FileUploaderProps): import("react/jsx-runtime").JSX.Element;
|
|
24
|
+
//# sourceMappingURL=FileUploader.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"FileUploader.d.ts","sourceRoot":"","sources":["../../../../../src/editor/sidebar/form/uploaders/FileUploader.tsx"],"names":[],"mappings":"AAyBA,OAAO,EAAE,KAAK,SAAS,EAAoB,MAAM,OAAO,CAAA;AACxD,OAAO,EAAE,KAAK,OAAO,EAAE,KAAK,WAAW,EAAiB,MAAM,iBAAiB,CAAA;AAE/E,OAAO,EACL,KAAK,oBAAoB,EAG1B,MAAM,4CAA4C,CAAA;AAGnD,MAAM,WAAW,kBAAkB;IACjC,kBAAkB,EAAE,MAAM,EAAE,CAAA;IAC5B,gBAAgB,EAAE,MAAM,CAAA;IACxB,WAAW,EAAE,MAAM,CAAA;IACnB,kBAAkB,EAAE,MAAM,CAAA;IAC1B,YAAY,EAAE,MAAM,CAAA;IACpB,wBAAwB,EAAE,MAAM,CAAA;IAChC,cAAc,EAAE,MAAM,CAAA;IACtB,cAAc,EAAE,MAAM,CAAA;CACvB;AAED,MAAM,MAAM,qBAAqB,GAAG,OAAO,GAAG,OAAO,CAAA;AAErD,MAAM,WAAW,iBAAiB;IAChC,OAAO,EAAE,OAAO,CAAC,WAAW,CAAC,CAAA;IAC7B,aAAa,EAAE,MAAM,IAAI,CAAA;IACzB,MAAM,EAAE,kBAAkB,CAAA;IAC1B,aAAa,EAAE,CAAC,IAAI,EAAE,oBAAoB,KAAK,SAAS,CAAA;IACxD,MAAM,CAAC,EAAE,SAAS,CAAA;IAClB,SAAS,CAAC,EAAE,qBAAqB,CAAA;CAClC;AAOD,wBAAgB,YAAY,CAAC,EAC3B,OAAO,EACP,aAAa,EACb,MAAM,EACN,aAAa,EACb,MAAM,EACN,SAAmB,GACpB,EAAE,iBAAiB,2CAgInB"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Control, FieldValues } from 'react-hook-form';
|
|
2
|
+
interface ImageUploaderProps {
|
|
3
|
+
control: Control<FieldValues>;
|
|
4
|
+
onFieldChange: () => void;
|
|
5
|
+
}
|
|
6
|
+
export declare function ImageUploader({ control, onFieldChange }: ImageUploaderProps): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export {};
|
|
8
|
+
//# sourceMappingURL=ImageUploader.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ImageUploader.d.ts","sourceRoot":"","sources":["../../../../../src/editor/sidebar/form/uploaders/ImageUploader.tsx"],"names":[],"mappings":"AAqBA,OAAO,KAAK,EAAE,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAA;AAQ3D,UAAU,kBAAkB;IAC1B,OAAO,EAAE,OAAO,CAAC,WAAW,CAAC,CAAA;IAC7B,aAAa,EAAE,MAAM,IAAI,CAAA;CAC1B;AAED,wBAAgB,aAAa,CAAC,EAAE,OAAO,EAAE,aAAa,EAAE,EAAE,kBAAkB,2CA2C3E"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Control, FieldValues } from 'react-hook-form';
|
|
2
|
+
interface VideoUploaderProps {
|
|
3
|
+
control: Control<FieldValues>;
|
|
4
|
+
onFieldChange: () => void;
|
|
5
|
+
}
|
|
6
|
+
export declare function VideoUploader({ control, onFieldChange }: VideoUploaderProps): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export {};
|
|
8
|
+
//# sourceMappingURL=VideoUploader.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"VideoUploader.d.ts","sourceRoot":"","sources":["../../../../../src/editor/sidebar/form/uploaders/VideoUploader.tsx"],"names":[],"mappings":"AAwBA,OAAO,EAAE,KAAK,OAAO,EAAc,KAAK,WAAW,EAAiB,MAAM,iBAAiB,CAAA;AAS3F,UAAU,kBAAkB;IAC1B,OAAO,EAAE,OAAO,CAAC,WAAW,CAAC,CAAA;IAC7B,aAAa,EAAE,MAAM,IAAI,CAAA;CAC1B;AAED,wBAAgB,aAAa,CAAC,EAAE,OAAO,EAAE,aAAa,EAAE,EAAE,kBAAkB,2CAsF3E"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { Ref } from 'react';
|
|
2
|
+
import { DesignerSideBarProps, ToolPanelHandle } from './types';
|
|
3
|
+
/**
|
|
4
|
+
* The designer sidebar: a collapsible tool panel on desktop (icon rail + resizable content)
|
|
5
|
+
* and a slide-up overlay + bottom toolbar on mobile. Built-in trays and any host tools are
|
|
6
|
+
* supplied through `tools`. Each open tool gets its own `DesignerNavProvider` (keyed by tool
|
|
7
|
+
* id, so switching tools resets navigation) and `ToolHeaderActionsProvider`.
|
|
8
|
+
*/
|
|
9
|
+
declare function DesignerSideBarInner<ID extends string>({ tools, initialSelectedToolId, height, toolStyle, isFullScreenMode, hasExpandPanelButton, onToolChange, onFullWidthChange, isPanelResizeEnabled, selectedToolId: controlledSelectedToolId, onSelectedToolIdChange, view, onViewChange, renderContentInActiveLayoutOnly, controlledExpandedWidth, contentKey, onBack, }: DesignerSideBarProps<ID>, ref: Ref<ToolPanelHandle<ID>>): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
/**
|
|
11
|
+
* `forwardRef` erases the generic, so re-assert it on the exported component: callers keep
|
|
12
|
+
* `Tool<ID>` inference and a typed imperative handle.
|
|
13
|
+
*/
|
|
14
|
+
export declare const DesignerSideBar: <ID extends string>(props: DesignerSideBarProps<ID> & {
|
|
15
|
+
ref?: Ref<ToolPanelHandle<ID>>;
|
|
16
|
+
}) => ReturnType<typeof DesignerSideBarInner>;
|
|
17
|
+
export {};
|
|
18
|
+
//# sourceMappingURL=DesignerSideBar.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DesignerSideBar.d.ts","sourceRoot":"","sources":["../../../../src/editor/sidebar/panel/DesignerSideBar.tsx"],"names":[],"mappings":"AAuBA,OAAO,EAIL,KAAK,GAAG,EAOT,MAAM,OAAO,CAAA;AAYd,OAAO,KAAK,EAAE,oBAAoB,EAAQ,eAAe,EAAE,MAAM,SAAS,CAAA;AA6C1E;;;;;GAKG;AACH,iBAAS,oBAAoB,CAAC,EAAE,SAAS,MAAM,EAC7C,EACE,KAAK,EACL,qBAAqB,EACrB,MAAM,EACN,SAAS,EACT,gBAAgB,EAChB,oBAAoB,EACpB,YAAY,EACZ,iBAAiB,EACjB,oBAA2B,EAC3B,cAAc,EAAE,wBAAwB,EACxC,sBAAsB,EACtB,IAAI,EACJ,YAAY,EACZ,+BAAsC,EACtC,uBAAuB,EACvB,UAAU,EACV,MAAM,GACP,EAAE,oBAAoB,CAAC,EAAE,CAAC,EAC3B,GAAG,EAAE,GAAG,CAAC,eAAe,CAAC,EAAE,CAAC,CAAC,2CA+V9B;AAED;;;GAGG;AACH,eAAO,MAAM,eAAe,EAAuC,CAAC,EAAE,SAAS,MAAM,EACnF,KAAK,EAAE,oBAAoB,CAAC,EAAE,CAAC,GAAG;IAAE,GAAG,CAAC,EAAE,GAAG,CAAC,eAAe,CAAC,EAAE,CAAC,CAAC,CAAA;CAAE,KACjE,UAAU,CAAC,OAAO,oBAAoB,CAAC,CAAA"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
interface MobileToolOverlayProps {
|
|
3
|
+
isOpen: boolean;
|
|
4
|
+
children: ReactNode;
|
|
5
|
+
}
|
|
6
|
+
/**
|
|
7
|
+
* The compact-viewport slide-up sheet holding a tool's content. Carries the
|
|
8
|
+
* `data-tool-panel` marker so the canvas↔panel focus coordination treats focus moving into
|
|
9
|
+
* it as staying "in the panel" (see `useDesignerSelectionFocus`).
|
|
10
|
+
*/
|
|
11
|
+
export declare function MobileToolOverlay({ isOpen, children }: MobileToolOverlayProps): import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
export {};
|
|
13
|
+
//# sourceMappingURL=MobileToolOverlay.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MobileToolOverlay.d.ts","sourceRoot":"","sources":["../../../../src/editor/sidebar/panel/MobileToolOverlay.tsx"],"names":[],"mappings":"AAkBA,OAAO,KAAK,EAAiB,SAAS,EAAE,MAAM,OAAO,CAAA;AAUrD,UAAU,sBAAsB;IAC9B,MAAM,EAAE,OAAO,CAAA;IACf,QAAQ,EAAE,SAAS,CAAA;CACpB;AAED;;;;GAIG;AACH,wBAAgB,iBAAiB,CAAC,EAAE,MAAM,EAAE,QAAQ,EAAE,EAAE,sBAAsB,2CAU7E"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Tool } from './types';
|
|
2
|
+
interface MobileToolbarProps<ID extends string> {
|
|
3
|
+
tools: Tool<ID>[];
|
|
4
|
+
selectedToolId: string | null;
|
|
5
|
+
onToolClick: (toolId: string) => void;
|
|
6
|
+
}
|
|
7
|
+
/** The fixed bottom toolbar shown on compact viewports in place of the desktop rail. */
|
|
8
|
+
export declare function MobileToolbar<ID extends string>({ tools, selectedToolId, onToolClick, }: MobileToolbarProps<ID>): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
export {};
|
|
10
|
+
//# sourceMappingURL=MobileToolbar.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MobileToolbar.d.ts","sourceRoot":"","sources":["../../../../src/editor/sidebar/panel/MobileToolbar.tsx"],"names":[],"mappings":"AAoBA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,SAAS,CAAA;AAEnC,UAAU,kBAAkB,CAAC,EAAE,SAAS,MAAM;IAC5C,KAAK,EAAE,IAAI,CAAC,EAAE,CAAC,EAAE,CAAA;IACjB,cAAc,EAAE,MAAM,GAAG,IAAI,CAAA;IAC7B,WAAW,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAA;CACtC;AAED,wFAAwF;AACxF,wBAAgB,aAAa,CAAC,EAAE,SAAS,MAAM,EAAE,EAC/C,KAAK,EACL,cAAc,EACd,WAAW,GACZ,EAAE,kBAAkB,CAAC,EAAE,CAAC,2CAWxB"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { ToolStyle } from './types';
|
|
3
|
+
interface ToolBodyProps {
|
|
4
|
+
children: ReactNode;
|
|
5
|
+
darkSurface?: boolean;
|
|
6
|
+
toolStyle?: ToolStyle;
|
|
7
|
+
}
|
|
8
|
+
/** The scrollable content region below the header. */
|
|
9
|
+
export declare function ToolBody({ children, darkSurface, toolStyle }: ToolBodyProps): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
export {};
|
|
11
|
+
//# sourceMappingURL=ToolBody.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ToolBody.d.ts","sourceRoot":"","sources":["../../../../src/editor/sidebar/panel/ToolBody.tsx"],"names":[],"mappings":"AAkBA,OAAO,KAAK,EAAiB,SAAS,EAAE,MAAM,OAAO,CAAA;AAErD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAA;AAExC,UAAU,aAAa;IACrB,QAAQ,EAAE,SAAS,CAAA;IACnB,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB,SAAS,CAAC,EAAE,SAAS,CAAA;CACtB;AAED,sDAAsD;AACtD,wBAAgB,QAAQ,CAAC,EAAE,QAAQ,EAAE,WAAmB,EAAE,SAAS,EAAE,EAAE,aAAa,2CAanF"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { ToolStyle, ToolVariant } from './types';
|
|
3
|
+
interface ToolContentContainerProps {
|
|
4
|
+
id?: string;
|
|
5
|
+
headingId?: string;
|
|
6
|
+
icon: ReactNode;
|
|
7
|
+
title: string;
|
|
8
|
+
variant?: ToolVariant;
|
|
9
|
+
onClose?: () => void;
|
|
10
|
+
onBack?: () => void;
|
|
11
|
+
onToggleFullWidth?: () => void;
|
|
12
|
+
isFullWidth?: boolean;
|
|
13
|
+
isFullScreen?: boolean;
|
|
14
|
+
toolStyle?: ToolStyle;
|
|
15
|
+
skipInitialFocus?: boolean;
|
|
16
|
+
onAfterInitialFocus?: () => void;
|
|
17
|
+
children: ReactNode;
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* Wraps a tool's content with the header and scrollable body, and owns focus lifecycle:
|
|
21
|
+
* focus the close button on open (or the container when there is none), the back button on
|
|
22
|
+
* forward navigation, the close button on backward navigation. Escape closes the tool
|
|
23
|
+
* (ignoring Escape bubbling up from portaled descendants like popovers).
|
|
24
|
+
*/
|
|
25
|
+
export declare function ToolContentContainer({ id, headingId, icon, title, variant, onClose, onBack, onToggleFullWidth, isFullWidth, isFullScreen, toolStyle, skipInitialFocus, onAfterInitialFocus, children, }: ToolContentContainerProps): import("react/jsx-runtime").JSX.Element;
|
|
26
|
+
export {};
|
|
27
|
+
//# sourceMappingURL=ToolContentContainer.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ToolContentContainer.d.ts","sourceRoot":"","sources":["../../../../src/editor/sidebar/panel/ToolContentContainer.tsx"],"names":[],"mappings":"AAkBA,OAAO,EAAE,KAAK,SAAS,EAAkC,MAAM,OAAO,CAAA;AAMtE,OAAO,KAAK,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,SAAS,CAAA;AAErD,UAAU,yBAAyB;IACjC,EAAE,CAAC,EAAE,MAAM,CAAA;IACX,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,IAAI,EAAE,SAAS,CAAA;IACf,KAAK,EAAE,MAAM,CAAA;IACb,OAAO,CAAC,EAAE,WAAW,CAAA;IACrB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;IACpB,MAAM,CAAC,EAAE,MAAM,IAAI,CAAA;IACnB,iBAAiB,CAAC,EAAE,MAAM,IAAI,CAAA;IAC9B,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,SAAS,CAAC,EAAE,SAAS,CAAA;IACrB,gBAAgB,CAAC,EAAE,OAAO,CAAA;IAC1B,mBAAmB,CAAC,EAAE,MAAM,IAAI,CAAA;IAChC,QAAQ,EAAE,SAAS,CAAA;CACpB;AAED;;;;;GAKG;AACH,wBAAgB,oBAAoB,CAAC,EACnC,EAAE,EACF,SAAS,EACT,IAAI,EACJ,KAAK,EACL,OAAmB,EACnB,OAAO,EACP,MAAM,EACN,iBAAiB,EACjB,WAAmB,EACnB,YAAoB,EACpB,SAAS,EACT,gBAAwB,EACxB,mBAAmB,EACnB,QAAQ,GACT,EAAE,yBAAyB,2CA+G3B"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
interface ToolHeaderProps {
|
|
3
|
+
headingId?: string;
|
|
4
|
+
icon: ReactNode;
|
|
5
|
+
title: string;
|
|
6
|
+
subtitle?: string;
|
|
7
|
+
showBackButton?: boolean;
|
|
8
|
+
onBack?: () => void;
|
|
9
|
+
onClose?: () => void;
|
|
10
|
+
onToggleFullWidth?: () => void;
|
|
11
|
+
isFullWidth?: boolean;
|
|
12
|
+
headerActions?: ReactNode;
|
|
13
|
+
darkSurface?: boolean;
|
|
14
|
+
closeButtonElementRef?: (el: Element | null) => void;
|
|
15
|
+
backButtonElementRef?: (el: Element | null) => void;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* The tool header: a back button (or the tool icon) beside the title, and a right cluster
|
|
19
|
+
* of host-injected `headerActions`, the full-width toggle, and the close button. The title
|
|
20
|
+
* shows `subtitle` when navigated into a sub-view, otherwise the tool `title`.
|
|
21
|
+
*/
|
|
22
|
+
export declare function ToolHeader({ headingId, icon, title, subtitle, showBackButton, onBack, onClose, onToggleFullWidth, isFullWidth, headerActions, darkSurface, closeButtonElementRef, backButtonElementRef, }: ToolHeaderProps): import("react/jsx-runtime").JSX.Element;
|
|
23
|
+
export {};
|
|
24
|
+
//# sourceMappingURL=ToolHeader.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ToolHeader.d.ts","sourceRoot":"","sources":["../../../../src/editor/sidebar/panel/ToolHeader.tsx"],"names":[],"mappings":"AA4BA,OAAO,KAAK,EAAiB,SAAS,EAAE,MAAM,OAAO,CAAA;AAYrD,UAAU,eAAe;IACvB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,IAAI,EAAE,SAAS,CAAA;IACf,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,cAAc,CAAC,EAAE,OAAO,CAAA;IACxB,MAAM,CAAC,EAAE,MAAM,IAAI,CAAA;IACnB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;IACpB,iBAAiB,CAAC,EAAE,MAAM,IAAI,CAAA;IAC9B,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB,aAAa,CAAC,EAAE,SAAS,CAAA;IACzB,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB,qBAAqB,CAAC,EAAE,CAAC,EAAE,EAAE,OAAO,GAAG,IAAI,KAAK,IAAI,CAAA;IACpD,oBAAoB,CAAC,EAAE,CAAC,EAAE,EAAE,OAAO,GAAG,IAAI,KAAK,IAAI,CAAA;CACpD;AAED;;;;GAIG;AACH,wBAAgB,UAAU,CAAC,EACzB,SAAS,EACT,IAAI,EACJ,KAAK,EACL,QAAQ,EACR,cAAc,EACd,MAAM,EACN,OAAO,EACP,iBAAiB,EACjB,WAAmB,EACnB,aAAa,EACb,WAAmB,EACnB,qBAAqB,EACrB,oBAAoB,GACrB,EAAE,eAAe,2CA2EjB"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { ToolHeaderActionsContextValue } from './types';
|
|
3
|
+
export declare function ToolHeaderActionsProvider({ children }: {
|
|
4
|
+
children: ReactNode;
|
|
5
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
/** Access the header-action slot. Throws outside a `ToolHeaderActionsProvider`. */
|
|
7
|
+
export declare function useToolHeaderActions(): ToolHeaderActionsContextValue;
|
|
8
|
+
//# sourceMappingURL=ToolHeaderActionsContext.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ToolHeaderActionsContext.d.ts","sourceRoot":"","sources":["../../../../src/editor/sidebar/panel/ToolHeaderActionsContext.tsx"],"names":[],"mappings":"AAkBA;;;;;;GAMG;AAEH,OAAO,EAAiB,KAAK,SAAS,EAAiC,MAAM,OAAO,CAAA;AACpF,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,SAAS,CAAA;AAI5D,wBAAgB,yBAAyB,CAAC,EAAE,QAAQ,EAAE,EAAE;IAAE,QAAQ,EAAE,SAAS,CAAA;CAAE,2CAS9E;AAED,mFAAmF;AACnF,wBAAgB,oBAAoB,IAAI,6BAA6B,CAMpE"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Tool } from './types';
|
|
2
|
+
interface ToolIconButtonsProps<ID extends string> {
|
|
3
|
+
tools: Tool<ID>[];
|
|
4
|
+
selectedToolId: string | null;
|
|
5
|
+
onToolClick: (toolId: string) => void;
|
|
6
|
+
direction?: 'column' | 'row';
|
|
7
|
+
contentId?: string;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* The rail of tool icon buttons, shared by the desktop panel and the mobile toolbar. The
|
|
11
|
+
* active tool reads as a filled button; the rest are ghost. Only the active tool carries
|
|
12
|
+
* `aria-controls`, tying it to the open content region — that region only exists while a tool
|
|
13
|
+
* is open, so a collapsed button must not reference a missing id. (`aria-expanded` is passed
|
|
14
|
+
* too, but the wrapping `Tooltip` strips it from the trigger, so `aria-controls` is what
|
|
15
|
+
* actually lands.)
|
|
16
|
+
*/
|
|
17
|
+
export declare function ToolIconButtons<ID extends string>({ tools, selectedToolId, onToolClick, direction, contentId, }: ToolIconButtonsProps<ID>): import("react/jsx-runtime").JSX.Element;
|
|
18
|
+
export {};
|
|
19
|
+
//# sourceMappingURL=ToolIconButtons.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ToolIconButtons.d.ts","sourceRoot":"","sources":["../../../../src/editor/sidebar/panel/ToolIconButtons.tsx"],"names":[],"mappings":"AAqBA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,SAAS,CAAA;AAEnC,UAAU,oBAAoB,CAAC,EAAE,SAAS,MAAM;IAC9C,KAAK,EAAE,IAAI,CAAC,EAAE,CAAC,EAAE,CAAA;IACjB,cAAc,EAAE,MAAM,GAAG,IAAI,CAAA;IAC7B,WAAW,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAA;IACrC,SAAS,CAAC,EAAE,QAAQ,GAAG,KAAK,CAAA;IAC5B,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAED;;;;;;;GAOG;AACH,wBAAgB,eAAe,CAAC,EAAE,SAAS,MAAM,EAAE,EACjD,KAAK,EACL,cAAc,EACd,WAAW,EACX,SAAoB,EACpB,SAAS,GACV,EAAE,oBAAoB,CAAC,EAAE,CAAC,2CAgC1B"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
interface ToolWrapperProps {
|
|
3
|
+
isOpen: boolean;
|
|
4
|
+
contentWidth: number;
|
|
5
|
+
isResizing: boolean;
|
|
6
|
+
isFullWidth: boolean;
|
|
7
|
+
children: ReactNode;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Animates the tool content area open/closed beside the icon rail. Width is applied inline
|
|
11
|
+
* (it varies per render); the resizing/full-width states toggle modifier classes so the
|
|
12
|
+
* transition and flex-fill come from the stylesheet.
|
|
13
|
+
*/
|
|
14
|
+
export declare function ToolWrapper({ isOpen, contentWidth, isResizing, isFullWidth, children, }: ToolWrapperProps): import("react/jsx-runtime").JSX.Element;
|
|
15
|
+
export {};
|
|
16
|
+
//# sourceMappingURL=ToolWrapper.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ToolWrapper.d.ts","sourceRoot":"","sources":["../../../../src/editor/sidebar/panel/ToolWrapper.tsx"],"names":[],"mappings":"AAkBA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAGtC,UAAU,gBAAgB;IACxB,MAAM,EAAE,OAAO,CAAA;IACf,YAAY,EAAE,MAAM,CAAA;IACpB,UAAU,EAAE,OAAO,CAAA;IACnB,WAAW,EAAE,OAAO,CAAA;IACpB,QAAQ,EAAE,SAAS,CAAA;CACpB;AAED;;;;GAIG;AACH,wBAAgB,WAAW,CAAC,EAC1B,MAAM,EACN,YAAY,EACZ,UAAU,EACV,WAAW,EACX,QAAQ,GACT,EAAE,gBAAgB,2CAgBlB"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/** Surface treatments a tool's content can request. `dark-surface` lets a host tool (e.g. an
|
|
2
|
+
* AI assistant, added in a later step) render light-on-dark; built-in trays use `default`. */
|
|
3
|
+
export declare const TOOL_VARIANTS: {
|
|
4
|
+
readonly DEFAULT: "default";
|
|
5
|
+
readonly DARK_SURFACE: "dark-surface";
|
|
6
|
+
};
|
|
7
|
+
/** Panel widths (px). The icon rail is always visible; the content area expands beside it. */
|
|
8
|
+
export declare const TOOL_PANEL_DIMENSIONS: {
|
|
9
|
+
readonly COLLAPSED_WIDTH: 48;
|
|
10
|
+
readonly EXPANDED_WIDTH: 368;
|
|
11
|
+
readonly ICON_BAR_WIDTH: 48;
|
|
12
|
+
readonly MIN_EXPANDED_WIDTH: 280;
|
|
13
|
+
readonly MAX_EXPANDED_WIDTH: 800;
|
|
14
|
+
};
|
|
15
|
+
/**
|
|
16
|
+
* Below this viewport width the panel drops its desktop rail for the mobile slide-up
|
|
17
|
+
* overlay + bottom toolbar. The panel is editor *chrome*, not a block, so a viewport query
|
|
18
|
+
* is correct here (blocks size to their container instead). Mirrors canvas-horizon's
|
|
19
|
+
* `breakpoints.medium`.
|
|
20
|
+
*/
|
|
21
|
+
export declare const FULL_LAYOUT_MIN_WIDTH = "768px";
|
|
22
|
+
export declare const FULL_LAYOUT_MQ = "(min-width: 768px)";
|
|
23
|
+
//# sourceMappingURL=constants.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../src/editor/sidebar/panel/constants.ts"],"names":[],"mappings":"AAkBA;8FAC8F;AAC9F,eAAO,MAAM,aAAa;;;CAGhB,CAAA;AAEV,8FAA8F;AAC9F,eAAO,MAAM,qBAAqB;;;;;;CAMxB,CAAA;AAEV;;;;;GAKG;AACH,eAAO,MAAM,qBAAqB,UAAU,CAAA;AAC5C,eAAO,MAAM,cAAc,uBAA0C,CAAA"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export { DesignerSideBar } from './DesignerSideBar';
|
|
2
|
+
export { TOOL_PANEL_DIMENSIONS, TOOL_VARIANTS } from './constants';
|
|
3
|
+
export { ToolHeaderActionsProvider, useToolHeaderActions, } from './ToolHeaderActionsContext';
|
|
4
|
+
export type { DesignerSideBarProps, Tool, ToolPanelHandle, ToolStyle, ToolVariant, } from './types';
|
|
5
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/editor/sidebar/panel/index.ts"],"names":[],"mappings":"AAkBA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAA;AACnD,OAAO,EAAE,qBAAqB,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAClE,OAAO,EACL,yBAAyB,EACzB,oBAAoB,GACrB,MAAM,4BAA4B,CAAA;AACnC,YAAY,EACV,oBAAoB,EACpB,IAAI,EACJ,eAAe,EACf,SAAS,EACT,WAAW,GACZ,MAAM,SAAS,CAAA"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The sidebar tool panel's chrome CSS: the desktop wrapper + resize handle, the animated
|
|
3
|
+
* content wrapper, the content/body surfaces, and the mobile slide-up overlay + bottom
|
|
4
|
+
* toolbar. None of it is expressible in InstUI props — it needs media queries,
|
|
5
|
+
* `:focus-visible`, reduced-motion and animated widths — so, like the canvas chrome, it is
|
|
6
|
+
* injected once as a global stylesheet keyed by stable class names. Widths and transforms
|
|
7
|
+
* that vary per render are applied inline; the `--resizing`/`--full-width`/`--open`
|
|
8
|
+
* modifier classes toggle the rest.
|
|
9
|
+
*/
|
|
10
|
+
export declare const PANEL_CLASS: {
|
|
11
|
+
readonly panel: "bce-tool-panel";
|
|
12
|
+
readonly panelResizing: "bce-tool-panel--resizing";
|
|
13
|
+
readonly panelFullWidth: "bce-tool-panel--full-width";
|
|
14
|
+
readonly dragHandle: "bce-tool-drag-handle";
|
|
15
|
+
readonly wrapper: "bce-tool-wrapper";
|
|
16
|
+
readonly wrapperResizing: "bce-tool-wrapper--resizing";
|
|
17
|
+
readonly wrapperFullWidth: "bce-tool-wrapper--full-width";
|
|
18
|
+
readonly content: "bce-tool-content";
|
|
19
|
+
readonly contentDark: "bce-tool-content--dark";
|
|
20
|
+
readonly contentFullScreen: "bce-tool-content--full-screen";
|
|
21
|
+
readonly body: "bce-tool-body";
|
|
22
|
+
readonly bodyDark: "bce-tool-body--dark";
|
|
23
|
+
readonly mobileOverlay: "bce-tool-mobile-overlay";
|
|
24
|
+
readonly mobileOverlayOpen: "bce-tool-mobile-overlay--open";
|
|
25
|
+
readonly mobileToolbar: "bce-tool-mobile-toolbar";
|
|
26
|
+
};
|
|
27
|
+
/** Mounts the tool-panel chrome stylesheet once, under the sidebar. */
|
|
28
|
+
export declare function PanelChromeStyles(): import("react/jsx-runtime").JSX.Element;
|
|
29
|
+
//# sourceMappingURL=panelStyles.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"panelStyles.d.ts","sourceRoot":"","sources":["../../../../src/editor/sidebar/panel/panelStyles.tsx"],"names":[],"mappings":"AAqBA;;;;;;;;GAQG;AAEH,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;CAgBd,CAAA;AAsBV,uEAAuE;AACvE,wBAAgB,iBAAiB,4CA6JhC"}
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { DesignerNavState } from '../DesignerNav';
|
|
3
|
+
import { TOOL_VARIANTS } from './constants';
|
|
4
|
+
export type ToolVariant = (typeof TOOL_VARIANTS)[keyof typeof TOOL_VARIANTS];
|
|
5
|
+
/**
|
|
6
|
+
* One entry in the sidebar's icon rail. The built-in trays are supplied as tools by the
|
|
7
|
+
* package; a host appends its own (an AI assistant, a widget tray) through the same array —
|
|
8
|
+
* this is the sidebar's host-tool slot.
|
|
9
|
+
*
|
|
10
|
+
* `icon`/`activeIcon` are `@instructure/ui-icons` elements (InstUI icons are components, not
|
|
11
|
+
* string names), matching the tray's `BlockDefinition.icon`.
|
|
12
|
+
*/
|
|
13
|
+
export interface Tool<ID extends string> {
|
|
14
|
+
id: ID;
|
|
15
|
+
/** Rail tooltip + header title, already translated. */
|
|
16
|
+
title: string;
|
|
17
|
+
icon: ReactNode;
|
|
18
|
+
/** Shown in the rail while this tool is active; falls back to `icon`. */
|
|
19
|
+
activeIcon?: ReactNode;
|
|
20
|
+
/** Surface treatment for the content area. Defaults to `default`. */
|
|
21
|
+
variant?: ToolVariant;
|
|
22
|
+
/** Background override for the content surface (e.g. a host tool's branded panel). */
|
|
23
|
+
background?: string;
|
|
24
|
+
/** Seed width (px) when this tool opens; clamped to min/max, overridden once the user resizes. */
|
|
25
|
+
expandedWidth?: number;
|
|
26
|
+
content?: ReactNode;
|
|
27
|
+
/** Root view this tool's navigation starts at. Defaults to `main`. */
|
|
28
|
+
defaultView?: string;
|
|
29
|
+
/** Set `false` to hide the header close button (e.g. a permanently docked tool). */
|
|
30
|
+
hasCloseButton?: boolean;
|
|
31
|
+
}
|
|
32
|
+
/** Imperative handle for opening a tool from outside (e.g. a host toolbar button). */
|
|
33
|
+
export interface ToolPanelHandle<ID extends string> {
|
|
34
|
+
openTool: (toolId: ID) => void;
|
|
35
|
+
}
|
|
36
|
+
export interface DesignerSideBarProps<ID extends string> {
|
|
37
|
+
tools: Tool<ID>[];
|
|
38
|
+
/** Uncontrolled: the tool open on first render. Ignored when `selectedToolId` is set. */
|
|
39
|
+
initialSelectedToolId?: ID;
|
|
40
|
+
/** Panel height; defaults to `100%`. */
|
|
41
|
+
height?: number | string;
|
|
42
|
+
/** Padding/overflow overrides for the content body. */
|
|
43
|
+
toolStyle?: ToolStyle;
|
|
44
|
+
/** Renders the active tool's content full-screen (fixed overlay). */
|
|
45
|
+
isFullScreenMode?: boolean;
|
|
46
|
+
/** Shows the rail collapse/expand toggle once a tool has been opened. */
|
|
47
|
+
hasExpandPanelButton?: boolean;
|
|
48
|
+
onToolChange?: (toolId: ID | null) => void;
|
|
49
|
+
onFullWidthChange?: (isFullWidth: boolean) => void;
|
|
50
|
+
/** Enables the drag-to-resize handle + full-width toggle. Defaults to `true`. */
|
|
51
|
+
isPanelResizeEnabled?: boolean;
|
|
52
|
+
/** Controlled: the open tool (or `null`). Parent owns selection when provided. */
|
|
53
|
+
selectedToolId?: ID | null;
|
|
54
|
+
onSelectedToolIdChange?: (toolId: ID | null) => void;
|
|
55
|
+
/** Controlled navigation view within the open tool. Parent owns it when provided. */
|
|
56
|
+
view?: DesignerNavState;
|
|
57
|
+
onViewChange?: (view: DesignerNavState) => void;
|
|
58
|
+
/** Render content only in the active layout (desktop XOR mobile) so a singleton like an
|
|
59
|
+
* RCE field does not double-mount across the two layouts. Defaults to `true`. */
|
|
60
|
+
renderContentInActiveLayoutOnly?: boolean;
|
|
61
|
+
/** Overrides the expanded width while set (e.g. widen for an RCE field); restores the
|
|
62
|
+
* user's width when cleared. */
|
|
63
|
+
controlledExpandedWidth?: number;
|
|
64
|
+
/** Extra key mixed into the open tool's content remount — pass the id of the entity being
|
|
65
|
+
* edited (e.g. the selected block) so navigation history resets when it changes, instead of
|
|
66
|
+
* leaking a previous block's sub-view into the Back button. */
|
|
67
|
+
contentKey?: string;
|
|
68
|
+
/** Fired when the header back button returns to the root view (no navigation history left). */
|
|
69
|
+
onBack?: () => void;
|
|
70
|
+
}
|
|
71
|
+
export interface ToolStyle {
|
|
72
|
+
padding?: number | string;
|
|
73
|
+
overflow?: 'auto' | 'scroll' | 'hidden' | 'visible';
|
|
74
|
+
}
|
|
75
|
+
/** Header-action slot: a tool's content injects buttons into the panel header via this. */
|
|
76
|
+
export interface ToolHeaderActionsContextValue {
|
|
77
|
+
setHeaderActions: (actions: ReactNode) => void;
|
|
78
|
+
headerActions: ReactNode;
|
|
79
|
+
}
|
|
80
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/editor/sidebar/panel/types.ts"],"names":[],"mappings":"AAkBA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AACtC,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAA;AACtD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAEhD,MAAM,MAAM,WAAW,GAAG,CAAC,OAAO,aAAa,CAAC,CAAC,MAAM,OAAO,aAAa,CAAC,CAAA;AAE5E;;;;;;;GAOG;AACH,MAAM,WAAW,IAAI,CAAC,EAAE,SAAS,MAAM;IACrC,EAAE,EAAE,EAAE,CAAA;IACN,uDAAuD;IACvD,KAAK,EAAE,MAAM,CAAA;IACb,IAAI,EAAE,SAAS,CAAA;IACf,yEAAyE;IACzE,UAAU,CAAC,EAAE,SAAS,CAAA;IACtB,qEAAqE;IACrE,OAAO,CAAC,EAAE,WAAW,CAAA;IACrB,sFAAsF;IACtF,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,kGAAkG;IAClG,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,OAAO,CAAC,EAAE,SAAS,CAAA;IACnB,sEAAsE;IACtE,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,oFAAoF;IACpF,cAAc,CAAC,EAAE,OAAO,CAAA;CACzB;AAED,sFAAsF;AACtF,MAAM,WAAW,eAAe,CAAC,EAAE,SAAS,MAAM;IAChD,QAAQ,EAAE,CAAC,MAAM,EAAE,EAAE,KAAK,IAAI,CAAA;CAC/B;AAED,MAAM,WAAW,oBAAoB,CAAC,EAAE,SAAS,MAAM;IACrD,KAAK,EAAE,IAAI,CAAC,EAAE,CAAC,EAAE,CAAA;IACjB,yFAAyF;IACzF,qBAAqB,CAAC,EAAE,EAAE,CAAA;IAC1B,wCAAwC;IACxC,MAAM,CAAC,EAAE,MAAM,GAAG,MAAM,CAAA;IACxB,uDAAuD;IACvD,SAAS,CAAC,EAAE,SAAS,CAAA;IACrB,qEAAqE;IACrE,gBAAgB,CAAC,EAAE,OAAO,CAAA;IAC1B,yEAAyE;IACzE,oBAAoB,CAAC,EAAE,OAAO,CAAA;IAC9B,YAAY,CAAC,EAAE,CAAC,MAAM,EAAE,EAAE,GAAG,IAAI,KAAK,IAAI,CAAA;IAC1C,iBAAiB,CAAC,EAAE,CAAC,WAAW,EAAE,OAAO,KAAK,IAAI,CAAA;IAClD,iFAAiF;IACjF,oBAAoB,CAAC,EAAE,OAAO,CAAA;IAC9B,kFAAkF;IAClF,cAAc,CAAC,EAAE,EAAE,GAAG,IAAI,CAAA;IAC1B,sBAAsB,CAAC,EAAE,CAAC,MAAM,EAAE,EAAE,GAAG,IAAI,KAAK,IAAI,CAAA;IACpD,qFAAqF;IACrF,IAAI,CAAC,EAAE,gBAAgB,CAAA;IACvB,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE,gBAAgB,KAAK,IAAI,CAAA;IAC/C;qFACiF;IACjF,+BAA+B,CAAC,EAAE,OAAO,CAAA;IACzC;oCACgC;IAChC,uBAAuB,CAAC,EAAE,MAAM,CAAA;IAChC;;mEAE+D;IAC/D,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,+FAA+F;IAC/F,MAAM,CAAC,EAAE,MAAM,IAAI,CAAA;CACpB;AAED,MAAM,WAAW,SAAS;IACxB,OAAO,CAAC,EAAE,MAAM,GAAG,MAAM,CAAA;IACzB,QAAQ,CAAC,EAAE,MAAM,GAAG,QAAQ,GAAG,QAAQ,GAAG,SAAS,CAAA;CACpD;AAED,2FAA2F;AAC3F,MAAM,WAAW,6BAA6B;IAC5C,gBAAgB,EAAE,CAAC,OAAO,EAAE,SAAS,KAAK,IAAI,CAAA;IAC9C,aAAa,EAAE,SAAS,CAAA;CACzB"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { RefObject } from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* Returns focus to `returnRef` when `active` goes from true to false — i.e. when the panel
|
|
4
|
+
* closes, focus goes back to whatever opened it (the rail button captured in `returnRef`).
|
|
5
|
+
* Does nothing on open, or when the ref is empty.
|
|
6
|
+
*/
|
|
7
|
+
export declare function useFocusReturn(active: boolean, returnRef: RefObject<HTMLElement | null>): void;
|
|
8
|
+
//# sourceMappingURL=useFocusReturn.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useFocusReturn.d.ts","sourceRoot":"","sources":["../../../../src/editor/sidebar/panel/useFocusReturn.ts"],"names":[],"mappings":"AAkBA,OAAO,EAAE,KAAK,SAAS,EAAqB,MAAM,OAAO,CAAA;AAEzD;;;;GAIG;AACH,wBAAgB,cAAc,CAAC,MAAM,EAAE,OAAO,EAAE,SAAS,EAAE,SAAS,CAAC,WAAW,GAAG,IAAI,CAAC,GAAG,IAAI,CAQ9F"}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Strings the package owns for the designer **sidebar** — the tool panel chrome (icon
|
|
3
|
+
* rail, header, resize/full-width controls) and the insertion trays that list blocks.
|
|
4
|
+
* Consumed via `useBlockTranslations(DesignerSidebarEnglish)`, the same mechanism blocks
|
|
5
|
+
* and the canvas chrome use; there is deliberately no second translation context. The
|
|
6
|
+
* host overrides by placing a `BlockTranslationsProvider` above the designer; anything it
|
|
7
|
+
* omits falls back to the English below.
|
|
8
|
+
*
|
|
9
|
+
* `%{name}` markers are interpolated by `translate('<key>', { … })`.
|
|
10
|
+
*/
|
|
11
|
+
export interface DesignerSidebarTranslations {
|
|
12
|
+
/** Suspense fallback while a tool's content loads. */
|
|
13
|
+
loading: string;
|
|
14
|
+
/** Rail button tooltip/label to collapse the expanded panel. */
|
|
15
|
+
collapse: string;
|
|
16
|
+
/** Rail button tooltip/label to expand the collapsed panel. */
|
|
17
|
+
expand: string;
|
|
18
|
+
/** Header tooltip to restore a full-width panel to its normal width. */
|
|
19
|
+
minimize: string;
|
|
20
|
+
/** Header full-width toggle screen-reader label (collapsed → full width). */
|
|
21
|
+
expandPanel: string;
|
|
22
|
+
/** Header full-width toggle screen-reader label (full width → normal). */
|
|
23
|
+
minimizePanel: string;
|
|
24
|
+
/** Header back-button screen-reader label. */
|
|
25
|
+
back: string;
|
|
26
|
+
/** Header close-button screen-reader label; `%{panelName}` is the active tool title. */
|
|
27
|
+
closePanel: string;
|
|
28
|
+
/** Resize drag-handle screen-reader label. */
|
|
29
|
+
resizeToolPanel: string;
|
|
30
|
+
/** Icon-rail title for the basic/activity-content blocks tray. */
|
|
31
|
+
basicBlocksTool: string;
|
|
32
|
+
/** Icon-rail title for the interactive blocks tray. */
|
|
33
|
+
interactiveBlocksTool: string;
|
|
34
|
+
/** Icon-rail title for the layout blocks tray. */
|
|
35
|
+
layoutBlocksTool: string;
|
|
36
|
+
/** Icon-rail title for the templates panel. */
|
|
37
|
+
templatesTool: string;
|
|
38
|
+
/** Intro copy above the basic-blocks list. */
|
|
39
|
+
basicBlocksIntro: string;
|
|
40
|
+
/** Intro copy above the layout-blocks list. */
|
|
41
|
+
layoutBlocksIntro: string;
|
|
42
|
+
/** Intro copy above the interactive-blocks list. */
|
|
43
|
+
interactiveBlocksIntro: string;
|
|
44
|
+
/** Block-row add-button screen-reader label; `%{name}` is the block's label. */
|
|
45
|
+
addBlock: string;
|
|
46
|
+
/** Skip link that jumps focus to the selected block on the canvas. */
|
|
47
|
+
skipToSelectedComponent: string;
|
|
48
|
+
/** Placeholder copy in the (not yet built) templates tray panel. */
|
|
49
|
+
templatesComingSoon: string;
|
|
50
|
+
}
|
|
51
|
+
/** English bundled with this package — also the source for `locales/en.json`. */
|
|
52
|
+
export declare const DesignerSidebarEnglish: DesignerSidebarTranslations;
|
|
53
|
+
//# sourceMappingURL=sidebarTranslations.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sidebarTranslations.d.ts","sourceRoot":"","sources":["../../../src/editor/sidebar/sidebarTranslations.ts"],"names":[],"mappings":"AAkBA;;;;;;;;;GASG;AACH,MAAM,WAAW,2BAA2B;IAC1C,sDAAsD;IACtD,OAAO,EAAE,MAAM,CAAA;IACf,gEAAgE;IAChE,QAAQ,EAAE,MAAM,CAAA;IAChB,+DAA+D;IAC/D,MAAM,EAAE,MAAM,CAAA;IACd,wEAAwE;IACxE,QAAQ,EAAE,MAAM,CAAA;IAChB,6EAA6E;IAC7E,WAAW,EAAE,MAAM,CAAA;IACnB,0EAA0E;IAC1E,aAAa,EAAE,MAAM,CAAA;IACrB,8CAA8C;IAC9C,IAAI,EAAE,MAAM,CAAA;IACZ,wFAAwF;IACxF,UAAU,EAAE,MAAM,CAAA;IAClB,8CAA8C;IAC9C,eAAe,EAAE,MAAM,CAAA;IACvB,kEAAkE;IAClE,eAAe,EAAE,MAAM,CAAA;IACvB,uDAAuD;IACvD,qBAAqB,EAAE,MAAM,CAAA;IAC7B,kDAAkD;IAClD,gBAAgB,EAAE,MAAM,CAAA;IACxB,+CAA+C;IAC/C,aAAa,EAAE,MAAM,CAAA;IACrB,8CAA8C;IAC9C,gBAAgB,EAAE,MAAM,CAAA;IACxB,+CAA+C;IAC/C,iBAAiB,EAAE,MAAM,CAAA;IACzB,oDAAoD;IACpD,sBAAsB,EAAE,MAAM,CAAA;IAC9B,gFAAgF;IAChF,QAAQ,EAAE,MAAM,CAAA;IAChB,sEAAsE;IACtE,uBAAuB,EAAE,MAAM,CAAA;IAC/B,oEAAoE;IACpE,mBAAmB,EAAE,MAAM,CAAA;CAC5B;AAED,iFAAiF;AACjF,eAAO,MAAM,sBAAsB,EAAE,2BAoBpC,CAAA"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { BlockCategory } from '../../../registry/blockCatalogue';
|
|
2
|
+
import { BlockRegistry } from '../../../registry/blockRegistry';
|
|
3
|
+
/**
|
|
4
|
+
* Props shared by every insertion tray. The three named trays (`ComponentsTray`,
|
|
5
|
+
* `LayoutTray`, `InteractiveTray`) differ only by category + intro copy, so they wrap this.
|
|
6
|
+
*/
|
|
7
|
+
export interface BlockTrayProps {
|
|
8
|
+
/** The host registry the tray lists blocks from and the form resolves against. */
|
|
9
|
+
registry: BlockRegistry;
|
|
10
|
+
/** Insert a block by wire name (click-to-add; drag-and-drop goes through the DnD context). */
|
|
11
|
+
onAddComponent: (componentName: string) => void;
|
|
12
|
+
/** The selected block's type — when set with an id and a non-`main` view, shows the form. */
|
|
13
|
+
selectedComponentType?: string;
|
|
14
|
+
selectedComponentId?: string | null;
|
|
15
|
+
selectedComponentData?: Record<string, unknown> | null;
|
|
16
|
+
onComponentChange?: (props: Record<string, unknown>, nodeId?: string) => void;
|
|
17
|
+
}
|
|
18
|
+
interface BlockTrayInternalProps extends BlockTrayProps {
|
|
19
|
+
category: BlockCategory;
|
|
20
|
+
intro: string;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* A tray: the list of insertable blocks for a category, or — once a block of a matching type
|
|
24
|
+
* is selected and navigation has left the `main` view — the settings form for it. The form
|
|
25
|
+
* stays mounted across its own sub-navigations (item edit, manage layer), which is why the
|
|
26
|
+
* swap keys on `selectedComponentId` and hinges on the nav view rather than remounting.
|
|
27
|
+
*/
|
|
28
|
+
export declare function BlockTray({ registry, onAddComponent, selectedComponentType, selectedComponentId, selectedComponentData, onComponentChange, category, intro, }: BlockTrayInternalProps): import("react/jsx-runtime").JSX.Element;
|
|
29
|
+
export {};
|
|
30
|
+
//# sourceMappingURL=BlockTray.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BlockTray.d.ts","sourceRoot":"","sources":["../../../../src/editor/sidebar/tray/BlockTray.tsx"],"names":[],"mappings":"AAoBA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,kCAAkC,CAAA;AACrE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,iCAAiC,CAAA;AAMpE;;;GAGG;AACH,MAAM,WAAW,cAAc;IAC7B,kFAAkF;IAClF,QAAQ,EAAE,aAAa,CAAA;IACvB,8FAA8F;IAC9F,cAAc,EAAE,CAAC,aAAa,EAAE,MAAM,KAAK,IAAI,CAAA;IAC/C,6FAA6F;IAC7F,qBAAqB,CAAC,EAAE,MAAM,CAAA;IAC9B,mBAAmB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IACnC,qBAAqB,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,CAAA;IACtD,iBAAiB,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAAE,MAAM,CAAC,EAAE,MAAM,KAAK,IAAI,CAAA;CAC9E;AAED,UAAU,sBAAuB,SAAQ,cAAc;IACrD,QAAQ,EAAE,aAAa,CAAA;IACvB,KAAK,EAAE,MAAM,CAAA;CACd;AAED;;;;;GAKG;AACH,wBAAgB,SAAS,CAAC,EACxB,QAAQ,EACR,cAAc,EACd,qBAAqB,EACrB,mBAAmB,EACnB,qBAAqB,EACrB,iBAAiB,EACjB,QAAQ,EACR,KAAK,GACN,EAAE,sBAAsB,2CAkCxB"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { BlockTrayProps } from './BlockTray';
|
|
2
|
+
/** The basic / activity-content blocks tray (Banner, Text, Quote, Code, Image, Video). */
|
|
3
|
+
export declare function ComponentsTray(props: BlockTrayProps): import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
//# sourceMappingURL=ComponentsTray.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ComponentsTray.d.ts","sourceRoot":"","sources":["../../../../src/editor/sidebar/tray/ComponentsTray.tsx"],"names":[],"mappings":"AAoBA,OAAO,EAAa,KAAK,cAAc,EAAE,MAAM,aAAa,CAAA;AAE5D,0FAA0F;AAC1F,wBAAgB,cAAc,CAAC,KAAK,EAAE,cAAc,2CAGnD"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { BlockTrayProps } from './BlockTray';
|
|
2
|
+
/** The interactive blocks tray (Accordion, Tabs, Knowledge check, Flashcards, Mix and match). */
|
|
3
|
+
export declare function InteractiveTray(props: BlockTrayProps): import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
//# sourceMappingURL=InteractiveTray.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"InteractiveTray.d.ts","sourceRoot":"","sources":["../../../../src/editor/sidebar/tray/InteractiveTray.tsx"],"names":[],"mappings":"AAoBA,OAAO,EAAa,KAAK,cAAc,EAAE,MAAM,aAAa,CAAA;AAE5D,iGAAiG;AACjG,wBAAgB,eAAe,CAAC,KAAK,EAAE,cAAc,2CASpD"}
|