@alpaca-editor/core 1.0.3762-mono
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/.prettierrc +3 -0
- package/dist/client-components/api.js +6 -0
- package/dist/client-components/index.js +36 -0
- package/dist/components/ActionButton.js +9 -0
- package/dist/components/Error.js +28 -0
- package/dist/config/config.js +654 -0
- package/dist/config/types.js +2 -0
- package/dist/editor/ComponentInfo.js +31 -0
- package/dist/editor/ConfirmationDialog.js +32 -0
- package/dist/editor/ContentTree.js +406 -0
- package/dist/editor/ContextMenu.js +117 -0
- package/dist/editor/Editor.js +55 -0
- package/dist/editor/EditorWarning.js +13 -0
- package/dist/editor/EditorWarnings.js +24 -0
- package/dist/editor/FieldEditorPopup.js +24 -0
- package/dist/editor/FieldHistory.js +40 -0
- package/dist/editor/FieldList.js +63 -0
- package/dist/editor/FieldListField.js +164 -0
- package/dist/editor/FieldListFieldWithFallbacks.js +114 -0
- package/dist/editor/FloatingToolbar.js +92 -0
- package/dist/editor/ImageEditor.js +55 -0
- package/dist/editor/InsertMenu.js +164 -0
- package/dist/editor/ItemInfo.js +30 -0
- package/dist/editor/LinkEditorDialog.js +89 -0
- package/dist/editor/MainLayout.js +46 -0
- package/dist/editor/NewEditorClient.js +9 -0
- package/dist/editor/PictureCropper.js +332 -0
- package/dist/editor/PictureEditor.js +104 -0
- package/dist/editor/PictureEditorDialog.js +194 -0
- package/dist/editor/ScrollingContentTree.js +30 -0
- package/dist/editor/Terminal.js +109 -0
- package/dist/editor/Titlebar.js +11 -0
- package/dist/editor/ai/AiPopup.js +25 -0
- package/dist/editor/ai/AiResponseMessage.js +24 -0
- package/dist/editor/ai/AiTerminal.js +241 -0
- package/dist/editor/ai/AiToolCall.js +18 -0
- package/dist/editor/ai/EditorAiTerminal.js +9 -0
- package/dist/editor/ai/editorAiContext.js +14 -0
- package/dist/editor/client/DialogContext.js +29 -0
- package/dist/editor/client/EditorClient.js +1336 -0
- package/dist/editor/client/GenericDialog.js +27 -0
- package/dist/editor/client/editContext.js +59 -0
- package/dist/editor/client/helpers.js +31 -0
- package/dist/editor/client/itemsRepository.js +255 -0
- package/dist/editor/client/operations.js +398 -0
- package/dist/editor/client/pageModelBuilder.js +129 -0
- package/dist/editor/commands/commands.js +2 -0
- package/dist/editor/commands/componentCommands.js +277 -0
- package/dist/editor/commands/createVersionCommand.js +26 -0
- package/dist/editor/commands/deleteVersionCommand.js +55 -0
- package/dist/editor/commands/itemCommands.js +134 -0
- package/dist/editor/commands/localizeItem/LocalizeItemDialog.js +94 -0
- package/dist/editor/commands/undo.js +32 -0
- package/dist/editor/component-designer/ComponentDesigner.js +58 -0
- package/dist/editor/component-designer/ComponentDesignerAiTerminal.js +9 -0
- package/dist/editor/component-designer/ComponentDesignerMenu.js +67 -0
- package/dist/editor/component-designer/ComponentEditor.js +59 -0
- package/dist/editor/component-designer/ComponentRenderingCodeEditor.js +16 -0
- package/dist/editor/component-designer/ComponentRenderingEditor.js +71 -0
- package/dist/editor/component-designer/ComponentsDropdown.js +22 -0
- package/dist/editor/component-designer/PlaceholdersEditor.js +70 -0
- package/dist/editor/component-designer/RenderingsDropdown.js +25 -0
- package/dist/editor/component-designer/TemplateEditor.js +144 -0
- package/dist/editor/component-designer/aiContext.js +18 -0
- package/dist/editor/componentTreeHelper.js +97 -0
- package/dist/editor/control-center/ControlCenterMenu.js +59 -0
- package/dist/editor/control-center/IndexOverview.js +27 -0
- package/dist/editor/control-center/IndexSettings.js +106 -0
- package/dist/editor/control-center/Status.js +7 -0
- package/dist/editor/editor-warnings/ItemLocked.js +40 -0
- package/dist/editor/editor-warnings/NoLanguageWriteAccess.js +16 -0
- package/dist/editor/editor-warnings/NoWorkflowWriteAccess.js +16 -0
- package/dist/editor/editor-warnings/NoWriteAccess.js +14 -0
- package/dist/editor/editor-warnings/ValidationErrors.js +27 -0
- package/dist/editor/field-types/AttachmentEditor.js +7 -0
- package/dist/editor/field-types/CheckboxEditor.js +32 -0
- package/dist/editor/field-types/DropLinkEditor.js +51 -0
- package/dist/editor/field-types/DropListEditor.js +58 -0
- package/dist/editor/field-types/ImageFieldEditor.js +36 -0
- package/dist/editor/field-types/InternalLinkFieldEditor.js +64 -0
- package/dist/editor/field-types/LinkFieldEditor.js +58 -0
- package/dist/editor/field-types/MultiLineText.js +35 -0
- package/dist/editor/field-types/PictureFieldEditor.js +59 -0
- package/dist/editor/field-types/RawEditor.js +33 -0
- package/dist/editor/field-types/ReactQuill.js +366 -0
- package/dist/editor/field-types/RichTextEditor.js +46 -0
- package/dist/editor/field-types/RichTextEditorComponent.js +72 -0
- package/dist/editor/field-types/SingleLineText.js +92 -0
- package/dist/editor/field-types/TreeListEditor.js +137 -0
- package/dist/editor/fieldTypes.js +2 -0
- package/dist/editor/media-selector/AiImageSearch.js +110 -0
- package/dist/editor/media-selector/AiImageSearchPrompt.js +58 -0
- package/dist/editor/media-selector/MediaSelector.js +11 -0
- package/dist/editor/media-selector/Preview.js +9 -0
- package/dist/editor/media-selector/Thumbnails.js +11 -0
- package/dist/editor/media-selector/TreeSelector.js +171 -0
- package/dist/editor/media-selector/UploadZone.js +80 -0
- package/dist/editor/menubar/ActionsMenu.js +33 -0
- package/dist/editor/menubar/ActiveUsers.js +13 -0
- package/dist/editor/menubar/ApproveAndPublish.js +13 -0
- package/dist/editor/menubar/BrowseHistory.js +14 -0
- package/dist/editor/menubar/ItemLanguageVersion.js +36 -0
- package/dist/editor/menubar/LanguageSelector.js +33 -0
- package/dist/editor/menubar/Menu.js +65 -0
- package/dist/editor/menubar/NavButtons.js +43 -0
- package/dist/editor/menubar/PageSelector.js +50 -0
- package/dist/editor/menubar/PageViewerControls.js +37 -0
- package/dist/editor/menubar/Separator.js +8 -0
- package/dist/editor/menubar/SiteInfo.js +26 -0
- package/dist/editor/menubar/User.js +18 -0
- package/dist/editor/menubar/VersionSelector.js +49 -0
- package/dist/editor/page-editor-chrome/CommentHighlighting.js +214 -0
- package/dist/editor/page-editor-chrome/CommentHighlightings.js +17 -0
- package/dist/editor/page-editor-chrome/FieldActionIndicator.js +27 -0
- package/dist/editor/page-editor-chrome/FieldActionIndicators.js +15 -0
- package/dist/editor/page-editor-chrome/FieldEditedIndicator.js +27 -0
- package/dist/editor/page-editor-chrome/FieldEditedIndicators.js +15 -0
- package/dist/editor/page-editor-chrome/FrameMenu.js +178 -0
- package/dist/editor/page-editor-chrome/FrameMenus.js +24 -0
- package/dist/editor/page-editor-chrome/InlineEditor.js +101 -0
- package/dist/editor/page-editor-chrome/LockedFieldIndicator.js +35 -0
- package/dist/editor/page-editor-chrome/NoLayout.js +21 -0
- package/dist/editor/page-editor-chrome/PageEditorChrome.js +65 -0
- package/dist/editor/page-editor-chrome/PictureEditorOverlay.js +109 -0
- package/dist/editor/page-editor-chrome/PlaceholderDropZone.js +82 -0
- package/dist/editor/page-editor-chrome/PlaceholderDropZones.js +147 -0
- package/dist/editor/page-viewer/DeviceToolbar.js +21 -0
- package/dist/editor/page-viewer/EditorForm.js +130 -0
- package/dist/editor/page-viewer/MiniMap.js +257 -0
- package/dist/editor/page-viewer/PageViewer.js +64 -0
- package/dist/editor/page-viewer/PageViewerFrame.js +696 -0
- package/dist/editor/page-viewer/pageViewContext.js +117 -0
- package/dist/editor/pageModel.js +2 -0
- package/dist/editor/picture-shared.js +28 -0
- package/dist/editor/reviews/Comment.js +112 -0
- package/dist/editor/reviews/Comments.js +24 -0
- package/dist/editor/reviews/PreviewInfo.js +13 -0
- package/dist/editor/reviews/Reviews.js +165 -0
- package/dist/editor/reviews/reviewCommands.js +44 -0
- package/dist/editor/reviews/useReviews.js +48 -0
- package/dist/editor/services/aiService.js +99 -0
- package/dist/editor/services/componentDesignerService.js +79 -0
- package/dist/editor/services/contentService.js +104 -0
- package/dist/editor/services/editService.js +322 -0
- package/dist/editor/services/indexService.js +25 -0
- package/dist/editor/services/reviewsService.js +43 -0
- package/dist/editor/services/serviceHelper.js +67 -0
- package/dist/editor/services/systemService.js +7 -0
- package/dist/editor/services/translationService.js +15 -0
- package/dist/editor/services-server/api.js +119 -0
- package/dist/editor/services-server/graphQL.js +56 -0
- package/dist/editor/sidebar/ComponentPalette.js +55 -0
- package/dist/editor/sidebar/ComponentTree.js +362 -0
- package/dist/editor/sidebar/Debug.js +60 -0
- package/dist/editor/sidebar/DictionaryEditor.js +160 -0
- package/dist/editor/sidebar/EditHistory.js +74 -0
- package/dist/editor/sidebar/GraphQL.js +115 -0
- package/dist/editor/sidebar/Insert.js +24 -0
- package/dist/editor/sidebar/MainContentTree.js +52 -0
- package/dist/editor/sidebar/Performance.js +34 -0
- package/dist/editor/sidebar/Sessions.js +31 -0
- package/dist/editor/sidebar/Sidebar.js +15 -0
- package/dist/editor/sidebar/SidebarView.js +76 -0
- package/dist/editor/sidebar/Translations.js +160 -0
- package/dist/editor/sidebar/Validation.js +52 -0
- package/dist/editor/sidebar/ViewSelector.js +15 -0
- package/dist/editor/sidebar/Workbox.js +80 -0
- package/dist/editor/ui/CenteredMessage.js +7 -0
- package/dist/editor/ui/CopyToClipboardButton.js +17 -0
- package/dist/editor/ui/DialogButtons.js +7 -0
- package/dist/editor/ui/Icons.js +75 -0
- package/dist/editor/ui/ItemNameDialog.js +45 -0
- package/dist/editor/ui/ItemNameDialogNew.js +61 -0
- package/dist/editor/ui/ItemSearch.js +93 -0
- package/dist/editor/ui/PerfectTree.js +223 -0
- package/dist/editor/ui/Section.js +12 -0
- package/dist/editor/ui/SimpleIconButton.js +11 -0
- package/dist/editor/ui/SimpleMenu.js +9 -0
- package/dist/editor/ui/SimpleTable.js +11 -0
- package/dist/editor/ui/SimpleTabs.js +21 -0
- package/dist/editor/ui/SimpleToolbar.js +7 -0
- package/dist/editor/ui/Spinner.js +7 -0
- package/dist/editor/ui/Splitter.js +187 -0
- package/dist/editor/ui/StackedPanels.js +69 -0
- package/dist/editor/ui/Toolbar.js +7 -0
- package/dist/editor/utils/id-helper.js +7 -0
- package/dist/editor/utils/insertOptions.js +45 -0
- package/dist/editor/utils/itemutils.js +25 -0
- package/dist/editor/utils/useMemoDebug.js +20 -0
- package/dist/editor/utils.js +328 -0
- package/dist/editor/views/CompareView.js +147 -0
- package/dist/editor/views/EditView.js +17 -0
- package/dist/editor/views/ItemEditor.js +24 -0
- package/dist/editor/views/SingleEditView.js +25 -0
- package/dist/index.js +22 -0
- package/dist/page-wizard/PageWizard.js +62 -0
- package/dist/page-wizard/SelectWizard.js +43 -0
- package/dist/page-wizard/WizardSteps.js +71 -0
- package/dist/page-wizard/service.js +26 -0
- package/dist/page-wizard/startPageWizardCommand.js +23 -0
- package/dist/page-wizard/steps/BuildPageStep.js +138 -0
- package/dist/page-wizard/steps/CollectStep.js +124 -0
- package/dist/page-wizard/steps/ComponentTypesSelector.js +211 -0
- package/dist/page-wizard/steps/Components.js +94 -0
- package/dist/page-wizard/steps/CreatePage.js +142 -0
- package/dist/page-wizard/steps/CreatePageAndLayoutStep.js +230 -0
- package/dist/page-wizard/steps/EditButton.js +7 -0
- package/dist/page-wizard/steps/FieldEditor.js +30 -0
- package/dist/page-wizard/steps/Generate.js +11 -0
- package/dist/page-wizard/steps/ImagesStep.js +159 -0
- package/dist/page-wizard/steps/LayoutStep.js +120 -0
- package/dist/page-wizard/steps/SelectStep.js +150 -0
- package/dist/page-wizard/steps/schema.js +140 -0
- package/dist/page-wizard/steps/usePageCreator.js +194 -0
- package/dist/splash-screen/NewPage.js +131 -0
- package/dist/splash-screen/SectionHeadline.js +9 -0
- package/dist/splash-screen/SplashScreen.js +81 -0
- package/dist/tour/Tour.js +321 -0
- package/dist/tour/default-tour.js +231 -0
- package/dist/tour/preview-tour.js +93 -0
- package/dist/tsconfig.build.tsbuildinfo +1 -0
- package/dist/types.js +2 -0
- package/eslint.config.mjs +4 -0
- package/images/bg-shape-black.webp +0 -0
- package/package.json +52 -0
- package/src/client-components/api.ts +6 -0
- package/src/client-components/index.ts +19 -0
- package/src/components/ActionButton.tsx +43 -0
- package/src/components/Error.tsx +57 -0
- package/src/config/config.tsx +737 -0
- package/src/config/types.ts +263 -0
- package/src/editor/ComponentInfo.tsx +77 -0
- package/src/editor/ConfirmationDialog.tsx +103 -0
- package/src/editor/ContentTree.tsx +654 -0
- package/src/editor/ContextMenu.tsx +155 -0
- package/src/editor/Editor.tsx +91 -0
- package/src/editor/EditorWarning.tsx +34 -0
- package/src/editor/EditorWarnings.tsx +33 -0
- package/src/editor/FieldEditorPopup.tsx +65 -0
- package/src/editor/FieldHistory.tsx +74 -0
- package/src/editor/FieldList.tsx +190 -0
- package/src/editor/FieldListField.tsx +387 -0
- package/src/editor/FieldListFieldWithFallbacks.tsx +211 -0
- package/src/editor/FloatingToolbar.tsx +163 -0
- package/src/editor/ImageEditor.tsx +129 -0
- package/src/editor/InsertMenu.tsx +332 -0
- package/src/editor/ItemInfo.tsx +90 -0
- package/src/editor/LinkEditorDialog.tsx +192 -0
- package/src/editor/MainLayout.tsx +94 -0
- package/src/editor/NewEditorClient.tsx +11 -0
- package/src/editor/PictureCropper.tsx +505 -0
- package/src/editor/PictureEditor.tsx +206 -0
- package/src/editor/PictureEditorDialog.tsx +381 -0
- package/src/editor/PublishDialog.ignore +74 -0
- package/src/editor/ScrollingContentTree.tsx +47 -0
- package/src/editor/Terminal.tsx +215 -0
- package/src/editor/Titlebar.tsx +23 -0
- package/src/editor/ai/AiPopup.tsx +59 -0
- package/src/editor/ai/AiResponseMessage.tsx +82 -0
- package/src/editor/ai/AiTerminal.tsx +450 -0
- package/src/editor/ai/AiToolCall.tsx +46 -0
- package/src/editor/ai/EditorAiTerminal.tsx +20 -0
- package/src/editor/ai/editorAiContext.ts +18 -0
- package/src/editor/client/DialogContext.tsx +49 -0
- package/src/editor/client/EditorClient.tsx +1831 -0
- package/src/editor/client/GenericDialog.tsx +50 -0
- package/src/editor/client/editContext.ts +330 -0
- package/src/editor/client/helpers.ts +44 -0
- package/src/editor/client/itemsRepository.ts +391 -0
- package/src/editor/client/operations.ts +610 -0
- package/src/editor/client/pageModelBuilder.ts +182 -0
- package/src/editor/commands/commands.ts +23 -0
- package/src/editor/commands/componentCommands.tsx +408 -0
- package/src/editor/commands/createVersionCommand.ts +33 -0
- package/src/editor/commands/deleteVersionCommand.ts +71 -0
- package/src/editor/commands/itemCommands.tsx +186 -0
- package/src/editor/commands/localizeItem/LocalizeItemDialog.tsx +201 -0
- package/src/editor/commands/undo.ts +39 -0
- package/src/editor/component-designer/ComponentDesigner.tsx +70 -0
- package/src/editor/component-designer/ComponentDesignerAiTerminal.tsx +11 -0
- package/src/editor/component-designer/ComponentDesignerMenu.tsx +91 -0
- package/src/editor/component-designer/ComponentEditor.tsx +97 -0
- package/src/editor/component-designer/ComponentRenderingCodeEditor.tsx +31 -0
- package/src/editor/component-designer/ComponentRenderingEditor.tsx +104 -0
- package/src/editor/component-designer/ComponentsDropdown.tsx +39 -0
- package/src/editor/component-designer/PlaceholdersEditor.tsx +183 -0
- package/src/editor/component-designer/RenderingsDropdown.tsx +36 -0
- package/src/editor/component-designer/TemplateEditor.tsx +236 -0
- package/src/editor/component-designer/aiContext.ts +23 -0
- package/src/editor/componentTreeHelper.tsx +114 -0
- package/src/editor/control-center/ControlCenterMenu.tsx +71 -0
- package/src/editor/control-center/IndexOverview.tsx +50 -0
- package/src/editor/control-center/IndexSettings.tsx +266 -0
- package/src/editor/control-center/Status.tsx +7 -0
- package/src/editor/editor-warnings/ItemLocked.tsx +63 -0
- package/src/editor/editor-warnings/NoLanguageWriteAccess.tsx +22 -0
- package/src/editor/editor-warnings/NoWorkflowWriteAccess.tsx +23 -0
- package/src/editor/editor-warnings/NoWriteAccess.tsx +15 -0
- package/src/editor/editor-warnings/ValidationErrors.tsx +54 -0
- package/src/editor/field-types/AttachmentEditor.tsx +9 -0
- package/src/editor/field-types/CheckboxEditor.tsx +47 -0
- package/src/editor/field-types/DropLinkEditor.tsx +75 -0
- package/src/editor/field-types/DropListEditor.tsx +84 -0
- package/src/editor/field-types/ImageFieldEditor.tsx +65 -0
- package/src/editor/field-types/InternalLinkFieldEditor.tsx +112 -0
- package/src/editor/field-types/LinkFieldEditor.tsx +85 -0
- package/src/editor/field-types/MultiLineText.tsx +63 -0
- package/src/editor/field-types/PictureFieldEditor.tsx +121 -0
- package/src/editor/field-types/RawEditor.tsx +53 -0
- package/src/editor/field-types/ReactQuill.tsx +580 -0
- package/src/editor/field-types/RichTextEditor.tsx +22 -0
- package/src/editor/field-types/RichTextEditorComponent.tsx +108 -0
- package/src/editor/field-types/SingleLineText.tsx +150 -0
- package/src/editor/field-types/TreeListEditor.tsx +261 -0
- package/src/editor/fieldTypes.ts +140 -0
- package/src/editor/media-selector/AiImageSearch.tsx +186 -0
- package/src/editor/media-selector/AiImageSearchPrompt.tsx +95 -0
- package/src/editor/media-selector/MediaSelector.tsx +42 -0
- package/src/editor/media-selector/Preview.tsx +14 -0
- package/src/editor/media-selector/Thumbnails.tsx +48 -0
- package/src/editor/media-selector/TreeSelector.tsx +292 -0
- package/src/editor/media-selector/UploadZone.tsx +137 -0
- package/src/editor/menubar/ActionsMenu.tsx +47 -0
- package/src/editor/menubar/ActiveUsers.tsx +17 -0
- package/src/editor/menubar/ApproveAndPublish.tsx +18 -0
- package/src/editor/menubar/BrowseHistory.tsx +37 -0
- package/src/editor/menubar/ItemLanguageVersion.tsx +52 -0
- package/src/editor/menubar/LanguageSelector.tsx +152 -0
- package/src/editor/menubar/Menu.tsx +83 -0
- package/src/editor/menubar/NavButtons.tsx +74 -0
- package/src/editor/menubar/PageSelector.tsx +139 -0
- package/src/editor/menubar/PageViewerControls.tsx +99 -0
- package/src/editor/menubar/Separator.tsx +12 -0
- package/src/editor/menubar/SiteInfo.tsx +53 -0
- package/src/editor/menubar/User.tsx +27 -0
- package/src/editor/menubar/VersionSelector.tsx +143 -0
- package/src/editor/page-editor-chrome/CommentHighlighting.tsx +287 -0
- package/src/editor/page-editor-chrome/CommentHighlightings.tsx +35 -0
- package/src/editor/page-editor-chrome/FieldActionIndicator.tsx +44 -0
- package/src/editor/page-editor-chrome/FieldActionIndicators.tsx +23 -0
- package/src/editor/page-editor-chrome/FieldEditedIndicator.tsx +64 -0
- package/src/editor/page-editor-chrome/FieldEditedIndicators.tsx +35 -0
- package/src/editor/page-editor-chrome/FrameMenu.tsx +263 -0
- package/src/editor/page-editor-chrome/FrameMenus.tsx +48 -0
- package/src/editor/page-editor-chrome/InlineEditor.tsx +147 -0
- package/src/editor/page-editor-chrome/LockedFieldIndicator.tsx +61 -0
- package/src/editor/page-editor-chrome/NoLayout.tsx +36 -0
- package/src/editor/page-editor-chrome/PageEditorChrome.tsx +119 -0
- package/src/editor/page-editor-chrome/PictureEditorOverlay.tsx +154 -0
- package/src/editor/page-editor-chrome/PlaceholderDropZone.tsx +171 -0
- package/src/editor/page-editor-chrome/PlaceholderDropZones.tsx +233 -0
- package/src/editor/page-viewer/DeviceToolbar.tsx +70 -0
- package/src/editor/page-viewer/EditorForm.tsx +247 -0
- package/src/editor/page-viewer/MiniMap.tsx +351 -0
- package/src/editor/page-viewer/PageViewer.tsx +127 -0
- package/src/editor/page-viewer/PageViewerFrame.tsx +1030 -0
- package/src/editor/page-viewer/pageViewContext.ts +186 -0
- package/src/editor/pageModel.ts +191 -0
- package/src/editor/picture-shared.tsx +53 -0
- package/src/editor/reviews/Comment.tsx +265 -0
- package/src/editor/reviews/Comments.tsx +50 -0
- package/src/editor/reviews/PreviewInfo.tsx +35 -0
- package/src/editor/reviews/Reviews.tsx +280 -0
- package/src/editor/reviews/reviewCommands.tsx +47 -0
- package/src/editor/reviews/useReviews.tsx +70 -0
- package/src/editor/services/aiService.ts +155 -0
- package/src/editor/services/componentDesignerService.ts +151 -0
- package/src/editor/services/contentService.ts +159 -0
- package/src/editor/services/editService.ts +462 -0
- package/src/editor/services/indexService.ts +24 -0
- package/src/editor/services/reviewsService.ts +45 -0
- package/src/editor/services/serviceHelper.ts +95 -0
- package/src/editor/services/systemService.ts +5 -0
- package/src/editor/services/translationService.ts +21 -0
- package/src/editor/services-server/api.ts +150 -0
- package/src/editor/services-server/graphQL.ts +106 -0
- package/src/editor/sidebar/ComponentPalette.tsx +146 -0
- package/src/editor/sidebar/ComponentTree.tsx +512 -0
- package/src/editor/sidebar/ComponentTree2.tsxx +490 -0
- package/src/editor/sidebar/Debug.tsx +105 -0
- package/src/editor/sidebar/DictionaryEditor.tsx +261 -0
- package/src/editor/sidebar/EditHistory.tsx +134 -0
- package/src/editor/sidebar/GraphQL.tsx +164 -0
- package/src/editor/sidebar/Insert.tsx +35 -0
- package/src/editor/sidebar/MainContentTree.tsx +95 -0
- package/src/editor/sidebar/Performance.tsx +53 -0
- package/src/editor/sidebar/Sessions.tsx +35 -0
- package/src/editor/sidebar/Sidebar.tsx +20 -0
- package/src/editor/sidebar/SidebarView.tsx +150 -0
- package/src/editor/sidebar/Translations.tsx +276 -0
- package/src/editor/sidebar/Validation.tsx +102 -0
- package/src/editor/sidebar/ViewSelector.tsx +49 -0
- package/src/editor/sidebar/Workbox.tsx +209 -0
- package/src/editor/ui/CenteredMessage.tsx +7 -0
- package/src/editor/ui/CopyToClipboardButton.tsx +23 -0
- package/src/editor/ui/DialogButtons.tsx +11 -0
- package/src/editor/ui/Icons.tsx +585 -0
- package/src/editor/ui/ItemNameDialog.tsx +94 -0
- package/src/editor/ui/ItemNameDialogNew.tsx +118 -0
- package/src/editor/ui/ItemSearch.tsx +173 -0
- package/src/editor/ui/PerfectTree.tsx +550 -0
- package/src/editor/ui/Section.tsx +35 -0
- package/src/editor/ui/SimpleIconButton.tsx +43 -0
- package/src/editor/ui/SimpleMenu.tsx +48 -0
- package/src/editor/ui/SimpleTable.tsx +63 -0
- package/src/editor/ui/SimpleTabs.tsx +55 -0
- package/src/editor/ui/SimpleToolbar.tsx +7 -0
- package/src/editor/ui/Spinner.tsx +7 -0
- package/src/editor/ui/Splitter.tsx +247 -0
- package/src/editor/ui/StackedPanels.tsx +134 -0
- package/src/editor/ui/Toolbar.tsx +7 -0
- package/src/editor/utils/id-helper.ts +3 -0
- package/src/editor/utils/insertOptions.ts +69 -0
- package/src/editor/utils/itemutils.ts +29 -0
- package/src/editor/utils/useMemoDebug.ts +28 -0
- package/src/editor/utils.ts +435 -0
- package/src/editor/views/CompareView.tsx +256 -0
- package/src/editor/views/EditView.tsx +27 -0
- package/src/editor/views/ItemEditor.tsx +58 -0
- package/src/editor/views/SingleEditView.tsx +44 -0
- package/src/fonts/Geist-Black.woff2 +0 -0
- package/src/fonts/Geist-Bold.woff2 +0 -0
- package/src/fonts/Geist-ExtraBold.woff2 +0 -0
- package/src/fonts/Geist-ExtraLight.woff2 +0 -0
- package/src/fonts/Geist-Light.woff2 +0 -0
- package/src/fonts/Geist-Medium.woff2 +0 -0
- package/src/fonts/Geist-Regular.woff2 +0 -0
- package/src/fonts/Geist-SemiBold.woff2 +0 -0
- package/src/fonts/Geist-Thin.woff2 +0 -0
- package/src/fonts/Geist[wght].woff2 +0 -0
- package/src/index.ts +7 -0
- package/src/page-wizard/PageWizard.tsx +163 -0
- package/src/page-wizard/SelectWizard.tsx +109 -0
- package/src/page-wizard/WizardSteps.tsx +207 -0
- package/src/page-wizard/service.ts +35 -0
- package/src/page-wizard/startPageWizardCommand.ts +27 -0
- package/src/page-wizard/steps/BuildPageStep.tsx +266 -0
- package/src/page-wizard/steps/CollectStep.tsx +233 -0
- package/src/page-wizard/steps/ComponentTypesSelector.tsx +443 -0
- package/src/page-wizard/steps/Components.tsx +193 -0
- package/src/page-wizard/steps/CreatePage.tsx +285 -0
- package/src/page-wizard/steps/CreatePageAndLayoutStep.tsx +384 -0
- package/src/page-wizard/steps/EditButton.tsx +34 -0
- package/src/page-wizard/steps/FieldEditor.tsx +102 -0
- package/src/page-wizard/steps/Generate.tsx +32 -0
- package/src/page-wizard/steps/ImagesStep.tsx +318 -0
- package/src/page-wizard/steps/LayoutStep.tsx +228 -0
- package/src/page-wizard/steps/SelectStep.tsx +256 -0
- package/src/page-wizard/steps/schema.ts +180 -0
- package/src/page-wizard/steps/usePageCreator.ts +279 -0
- package/src/splash-screen/NewPage.tsx +232 -0
- package/src/splash-screen/SectionHeadline.tsx +21 -0
- package/src/splash-screen/SplashScreen.tsx +156 -0
- package/src/tour/Tour.tsx +558 -0
- package/src/tour/default-tour.tsx +300 -0
- package/src/tour/preview-tour.tsx +127 -0
- package/src/types.ts +302 -0
- package/styles.css +476 -0
- package/tsconfig.build.json +21 -0
- package/tsconfig.json +11 -0
|
@@ -0,0 +1,300 @@
|
|
|
1
|
+
import { GetEditorTourStepsParams, TourStep } from "../config/types";
|
|
2
|
+
|
|
3
|
+
export function getDefaultTourSteps(
|
|
4
|
+
{
|
|
5
|
+
editContext,
|
|
6
|
+
nextStep,
|
|
7
|
+
stopTour,
|
|
8
|
+
waitForElement,
|
|
9
|
+
waitForElementToDisappear,
|
|
10
|
+
setFocusRect,
|
|
11
|
+
delay,
|
|
12
|
+
waitForInput,
|
|
13
|
+
simulateTyping,
|
|
14
|
+
}: GetEditorTourStepsParams,
|
|
15
|
+
config: {
|
|
16
|
+
firstComponentTemplateId: string;
|
|
17
|
+
firstComponentTemplateName: string;
|
|
18
|
+
firstComponentTextFieldName: string;
|
|
19
|
+
firstComponentTextFieldId: string;
|
|
20
|
+
firstComponentRichTextFieldName: string;
|
|
21
|
+
firstComponentRichTextFieldId: string;
|
|
22
|
+
}
|
|
23
|
+
) {
|
|
24
|
+
const tourSteps: Record<string, TourStep> = {
|
|
25
|
+
"start-tour": {
|
|
26
|
+
title: "Welcome to the AI Editor Tour!",
|
|
27
|
+
description:
|
|
28
|
+
"I will show you around the editor and how to use the most important features.",
|
|
29
|
+
prepareAction: async () => {
|
|
30
|
+
editContext?.openSplashScreen();
|
|
31
|
+
},
|
|
32
|
+
buttons: [
|
|
33
|
+
{
|
|
34
|
+
label: (
|
|
35
|
+
<div className="flex items-center gap-2">
|
|
36
|
+
<i className="pi pi-play" /> Start Tour
|
|
37
|
+
</div>
|
|
38
|
+
),
|
|
39
|
+
onClick: () => {
|
|
40
|
+
nextStep("new-page");
|
|
41
|
+
},
|
|
42
|
+
className: "button button-primary mt-2",
|
|
43
|
+
},
|
|
44
|
+
{
|
|
45
|
+
label: (
|
|
46
|
+
<div className="flex items-center gap-2">
|
|
47
|
+
<i className="pi pi-times" /> No thanks
|
|
48
|
+
</div>
|
|
49
|
+
),
|
|
50
|
+
onClick: () => {
|
|
51
|
+
stopTour();
|
|
52
|
+
},
|
|
53
|
+
className: "button button-secondary mt-2",
|
|
54
|
+
},
|
|
55
|
+
],
|
|
56
|
+
},
|
|
57
|
+
"new-page": {
|
|
58
|
+
description: (
|
|
59
|
+
<>
|
|
60
|
+
Click on the <b>New Page</b> tab to create a new page
|
|
61
|
+
</>
|
|
62
|
+
),
|
|
63
|
+
focusElement: "#new-page-tab",
|
|
64
|
+
waitForUserInput: async () => {
|
|
65
|
+
await waitForElement("#new-page-tab.active-tab");
|
|
66
|
+
},
|
|
67
|
+
nextStep: "pick-location",
|
|
68
|
+
},
|
|
69
|
+
"pick-location": {
|
|
70
|
+
description: (
|
|
71
|
+
<>
|
|
72
|
+
Select the <b>Playground</b> folder as the parent for your new page
|
|
73
|
+
</>
|
|
74
|
+
),
|
|
75
|
+
focusElement: ".tour-pick-location",
|
|
76
|
+
waitForUserInput: async () => {
|
|
77
|
+
await new Promise<void>((resolve) => {
|
|
78
|
+
const checkForElement = () => {
|
|
79
|
+
const elements = document.querySelectorAll(".p-highlight");
|
|
80
|
+
for (const element of elements) {
|
|
81
|
+
if (element.textContent?.trim() === "Playground") {
|
|
82
|
+
setFocusRect(element.getBoundingClientRect());
|
|
83
|
+
resolve();
|
|
84
|
+
return;
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
requestAnimationFrame(checkForElement);
|
|
88
|
+
};
|
|
89
|
+
checkForElement();
|
|
90
|
+
});
|
|
91
|
+
},
|
|
92
|
+
getPointTo: () => {
|
|
93
|
+
const elements = document.querySelectorAll(".p-treenode-label");
|
|
94
|
+
for (const element of elements) {
|
|
95
|
+
if (element.textContent?.trim() === "Playground") {
|
|
96
|
+
return element.getBoundingClientRect();
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
return undefined;
|
|
100
|
+
},
|
|
101
|
+
nextStep: "choose-template",
|
|
102
|
+
},
|
|
103
|
+
"choose-template": {
|
|
104
|
+
description: "Select a template for your page",
|
|
105
|
+
focusElement: ".tour-choose-template",
|
|
106
|
+
waitForUserInput: async () => {
|
|
107
|
+
await waitForElement(".tour-selected-template");
|
|
108
|
+
},
|
|
109
|
+
bubblePosition: "left",
|
|
110
|
+
nextStep: "enter-name",
|
|
111
|
+
},
|
|
112
|
+
"enter-name": {
|
|
113
|
+
description: "Enter a name for your page",
|
|
114
|
+
focusElement: "#new-page-name",
|
|
115
|
+
bubblePosition: "left",
|
|
116
|
+
waitForUserInput: async () => {
|
|
117
|
+
await waitForElement("#create-new-page-button:not(.p-disabled)");
|
|
118
|
+
},
|
|
119
|
+
nextStep: "create-page",
|
|
120
|
+
},
|
|
121
|
+
"create-page": {
|
|
122
|
+
description: "Click the Create button",
|
|
123
|
+
focusElement: "#create-new-page-button",
|
|
124
|
+
waitForUserInput: async () => {
|
|
125
|
+
await waitForElement("#insert-component-button");
|
|
126
|
+
},
|
|
127
|
+
nextStep: "ready-to-add-component",
|
|
128
|
+
},
|
|
129
|
+
"ready-to-add-component": {
|
|
130
|
+
description: "Wanna add a component to your beautiful empty page?",
|
|
131
|
+
buttons: [
|
|
132
|
+
{
|
|
133
|
+
label: (
|
|
134
|
+
<>
|
|
135
|
+
<i className="pi pi-arrow-right" /> I'm ready, lets go!
|
|
136
|
+
</>
|
|
137
|
+
),
|
|
138
|
+
onClick: () => nextStep("insert-component"),
|
|
139
|
+
},
|
|
140
|
+
],
|
|
141
|
+
},
|
|
142
|
+
"insert-component": {
|
|
143
|
+
description: "Excellent, click on the plus button to insert a component.",
|
|
144
|
+
focusElement: "#insert-component-button",
|
|
145
|
+
waitForUserInput: async () => {
|
|
146
|
+
await waitForElement(".tour-component-palette");
|
|
147
|
+
},
|
|
148
|
+
nextStep: "drag-component",
|
|
149
|
+
},
|
|
150
|
+
"drag-component": {
|
|
151
|
+
description: `Drag and drop a ${config.firstComponentTemplateName} component to your page.`,
|
|
152
|
+
focusElement: `#insert-component-${config.firstComponentTemplateId}`,
|
|
153
|
+
waitForUserInput: async () => {
|
|
154
|
+
await waitForElement(".tour-placeholder-dropzone");
|
|
155
|
+
},
|
|
156
|
+
nextStep: "drop-component-on-placeholder",
|
|
157
|
+
},
|
|
158
|
+
"drop-component-on-placeholder": {
|
|
159
|
+
description: "Drop the component onto this placeholder!",
|
|
160
|
+
focusElement: ".tour-placeholder-dropzone",
|
|
161
|
+
bubblePosition: "left",
|
|
162
|
+
extendFocus: 70,
|
|
163
|
+
waitForUserInput: async () => {
|
|
164
|
+
await waitForElementToDisappear(".tour-placeholder-dropzone");
|
|
165
|
+
await delay(400);
|
|
166
|
+
if (!document.querySelector(".tour-component-palette")) {
|
|
167
|
+
return "enter-title";
|
|
168
|
+
}
|
|
169
|
+
return "drag-component";
|
|
170
|
+
},
|
|
171
|
+
nextStep: "enter-title",
|
|
172
|
+
},
|
|
173
|
+
"enter-title": {
|
|
174
|
+
description: `Excellent! Now lets fill in the fields. First enter a ${config.firstComponentTextFieldName}`,
|
|
175
|
+
focusElement: `[data-field-id='${config.firstComponentTextFieldId}']`,
|
|
176
|
+
waitForUserInput: async () => {
|
|
177
|
+
await delay(5000);
|
|
178
|
+
await waitForInput(
|
|
179
|
+
`[data-field-id='${config.firstComponentTextFieldId}'] input`,
|
|
180
|
+
5
|
|
181
|
+
);
|
|
182
|
+
},
|
|
183
|
+
nextStep: "see-content-update",
|
|
184
|
+
},
|
|
185
|
+
"see-content-update": {
|
|
186
|
+
description:
|
|
187
|
+
"See how the content is automatically updating on your page?",
|
|
188
|
+
focusElement: `[data-field-id='${config.firstComponentTextFieldId}']`,
|
|
189
|
+
pointToElement: `iframe:[data-fieldid='${config.firstComponentTextFieldId}']`,
|
|
190
|
+
bubblePosition: "bottom",
|
|
191
|
+
flipArrow: true,
|
|
192
|
+
waitForUserInput: async () => {
|
|
193
|
+
await delay(5000);
|
|
194
|
+
await waitForInput(
|
|
195
|
+
`[data-field-id='${config.firstComponentTextFieldId}'] input`,
|
|
196
|
+
5
|
|
197
|
+
);
|
|
198
|
+
},
|
|
199
|
+
nextStep: "edit-content-inline",
|
|
200
|
+
},
|
|
201
|
+
"edit-content-inline": {
|
|
202
|
+
description:
|
|
203
|
+
"You can also directly edit the content on the page. Click on the [Introduction] placeholder here and start typing!",
|
|
204
|
+
focusElement: `iframe:[data-fieldid='${config.firstComponentRichTextFieldId}']`,
|
|
205
|
+
bubblePosition: "bottom",
|
|
206
|
+
flipArrow: true,
|
|
207
|
+
waitForUserInput: async () => {
|
|
208
|
+
await delay(5000);
|
|
209
|
+
await waitForInput(
|
|
210
|
+
`[data-field-id='${config.firstComponentRichTextFieldId}'] [contenteditable]`,
|
|
211
|
+
5
|
|
212
|
+
);
|
|
213
|
+
},
|
|
214
|
+
nextStep: "ai-intro",
|
|
215
|
+
},
|
|
216
|
+
"ai-intro": {
|
|
217
|
+
description:
|
|
218
|
+
"But hey, this is an AI editor, so why not let the AI do some of the work for you?",
|
|
219
|
+
buttons: [
|
|
220
|
+
{
|
|
221
|
+
label: (
|
|
222
|
+
<>
|
|
223
|
+
<i className="pi pi-arrow-right" /> Great, show me!
|
|
224
|
+
</>
|
|
225
|
+
),
|
|
226
|
+
onClick: () => nextStep("ai-sidebar"),
|
|
227
|
+
},
|
|
228
|
+
],
|
|
229
|
+
},
|
|
230
|
+
"ai-sidebar": {
|
|
231
|
+
description: "Click on the AI sidebar to open the AI chat.",
|
|
232
|
+
focusElement: `[data-sidebarview-name='ai']`,
|
|
233
|
+
nextStep: "ai-terminal",
|
|
234
|
+
waitForElement: "[data-sidebarview-name='ai'].a-active",
|
|
235
|
+
},
|
|
236
|
+
"ai-terminal": {
|
|
237
|
+
description:
|
|
238
|
+
"Let me take control and add tell the AI to add some more components.",
|
|
239
|
+
focusElement: `.tour-ai-terminal textarea`,
|
|
240
|
+
waitForUserInput: async () => {
|
|
241
|
+
await delay(1000);
|
|
242
|
+
const aiTerminal = document.querySelector(".tour-ai-terminal textarea");
|
|
243
|
+
if (aiTerminal) {
|
|
244
|
+
(aiTerminal as HTMLTextAreaElement).focus();
|
|
245
|
+
await simulateTyping(
|
|
246
|
+
aiTerminal as HTMLTextAreaElement,
|
|
247
|
+
`Plase add three components of type ${config.firstComponentTemplateName} with some funny dummy content to the page.`
|
|
248
|
+
);
|
|
249
|
+
}
|
|
250
|
+
},
|
|
251
|
+
bubblePosition: "top-right",
|
|
252
|
+
nextStep: "ai-submit",
|
|
253
|
+
},
|
|
254
|
+
"ai-submit": {
|
|
255
|
+
description: "Click on the Send button to submit the prompt to the AI.",
|
|
256
|
+
focusElement: ".tour-ai-terminal .tour-send-button",
|
|
257
|
+
bubblePosition: "top-right",
|
|
258
|
+
nextStep: "ai-watch-components-added",
|
|
259
|
+
waitForElement: ".tour-ai-terminal .a-prompt",
|
|
260
|
+
},
|
|
261
|
+
"ai-watch-components-added": {
|
|
262
|
+
description:
|
|
263
|
+
"Watch how the AI adds the components to the page. This can take a few seconds.",
|
|
264
|
+
focusElement: ".tour-ai-terminal",
|
|
265
|
+
pointToElement: ".tour-ai-terminal .a-prompt",
|
|
266
|
+
waitForElement: ".tour-ai-response-message-changes",
|
|
267
|
+
nextStep: "congratulations",
|
|
268
|
+
},
|
|
269
|
+
congratulations: {
|
|
270
|
+
title: "Congratulations!",
|
|
271
|
+
description: "You have completed the tour and are now an AI Editor Pro!",
|
|
272
|
+
buttons: [
|
|
273
|
+
{
|
|
274
|
+
label: (
|
|
275
|
+
<>
|
|
276
|
+
<i className="pi pi-check" /> Finish Tour
|
|
277
|
+
</>
|
|
278
|
+
),
|
|
279
|
+
onClick: () => stopTour(),
|
|
280
|
+
className: "button button-primary mt-2",
|
|
281
|
+
},
|
|
282
|
+
],
|
|
283
|
+
},
|
|
284
|
+
error: {
|
|
285
|
+
description: "Oops, something went wrong.",
|
|
286
|
+
buttons: [
|
|
287
|
+
{
|
|
288
|
+
label: (
|
|
289
|
+
<>
|
|
290
|
+
<i className="pi pi-check" /> Close
|
|
291
|
+
</>
|
|
292
|
+
),
|
|
293
|
+
onClick: () => stopTour(),
|
|
294
|
+
},
|
|
295
|
+
],
|
|
296
|
+
},
|
|
297
|
+
};
|
|
298
|
+
|
|
299
|
+
return tourSteps;
|
|
300
|
+
}
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
import { GetEditorTourStepsParams, TourStep } from "../config/types";
|
|
2
|
+
|
|
3
|
+
export function getPreviewTourSteps({
|
|
4
|
+
editContext,
|
|
5
|
+
nextStep,
|
|
6
|
+
stopTour,
|
|
7
|
+
waitForElement,
|
|
8
|
+
delay,
|
|
9
|
+
}: GetEditorTourStepsParams) {
|
|
10
|
+
const tourSteps: Record<string, TourStep> = {
|
|
11
|
+
"start-tour": {
|
|
12
|
+
title: "Welcome to the Preview Tour!",
|
|
13
|
+
description:
|
|
14
|
+
"I'll guide you through the preview and explain how to use its essential features.",
|
|
15
|
+
prepareAction: async () => {
|
|
16
|
+
editContext?.openSplashScreen();
|
|
17
|
+
},
|
|
18
|
+
buttons: [
|
|
19
|
+
{
|
|
20
|
+
label: (
|
|
21
|
+
<div className="flex items-center gap-2">
|
|
22
|
+
<i className="pi pi-play" /> Start Tour
|
|
23
|
+
</div>
|
|
24
|
+
),
|
|
25
|
+
onClick: () => {
|
|
26
|
+
nextStep("comment");
|
|
27
|
+
},
|
|
28
|
+
className: "button button-primary mt-2",
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
label: (
|
|
32
|
+
<div className="flex items-center gap-2">
|
|
33
|
+
<i className="pi pi-times" /> No thanks
|
|
34
|
+
</div>
|
|
35
|
+
),
|
|
36
|
+
onClick: () => {
|
|
37
|
+
stopTour();
|
|
38
|
+
},
|
|
39
|
+
className: "button button-secondary mt-2",
|
|
40
|
+
},
|
|
41
|
+
],
|
|
42
|
+
},
|
|
43
|
+
comment: {
|
|
44
|
+
description: <>Click here to add a comment to the page</>,
|
|
45
|
+
focusElement: "#add-comment",
|
|
46
|
+
nextStep: "commentContextMenu",
|
|
47
|
+
buttons: [
|
|
48
|
+
{
|
|
49
|
+
label: (
|
|
50
|
+
<>
|
|
51
|
+
<i className="pi pi-arrow-right" /> Next
|
|
52
|
+
</>
|
|
53
|
+
),
|
|
54
|
+
onClick: () => nextStep("commentContextMenu"),
|
|
55
|
+
},
|
|
56
|
+
],
|
|
57
|
+
},
|
|
58
|
+
commentContextMenu: {
|
|
59
|
+
description: (
|
|
60
|
+
<>You can also select text and add a comment from the context menu </>
|
|
61
|
+
),
|
|
62
|
+
focusElement: "[data-testid='pageEditoriframe']",
|
|
63
|
+
waitForUserInput: async () => {
|
|
64
|
+
await waitForElement(".p-contextmenu-enter-done");
|
|
65
|
+
await delay(1000);
|
|
66
|
+
},
|
|
67
|
+
nextStep: "approveMenu",
|
|
68
|
+
bubblePosition: "left",
|
|
69
|
+
},
|
|
70
|
+
approveMenu: {
|
|
71
|
+
description: <>Approve or reject the page here </>,
|
|
72
|
+
focusElement: "#actions-menu",
|
|
73
|
+
waitForUserInput: async () => {
|
|
74
|
+
await waitForElement("#approveReview");
|
|
75
|
+
await delay(2000);
|
|
76
|
+
},
|
|
77
|
+
nextStep: "closeTour",
|
|
78
|
+
bubblePosition: "left",
|
|
79
|
+
},
|
|
80
|
+
closeTour: {
|
|
81
|
+
description: <>Congratulations! You have completed the tour.</>,
|
|
82
|
+
buttons: [
|
|
83
|
+
{
|
|
84
|
+
label: (
|
|
85
|
+
<>
|
|
86
|
+
<i className="pi pi-check" /> Finish Tour
|
|
87
|
+
</>
|
|
88
|
+
),
|
|
89
|
+
onClick: () => stopTour(),
|
|
90
|
+
className: "button button-primary mt-2",
|
|
91
|
+
},
|
|
92
|
+
],
|
|
93
|
+
},
|
|
94
|
+
congratulations: {
|
|
95
|
+
title: "Congratulations!",
|
|
96
|
+
description:
|
|
97
|
+
"You have completed the tour and are ready to start editing!",
|
|
98
|
+
buttons: [
|
|
99
|
+
{
|
|
100
|
+
label: (
|
|
101
|
+
<>
|
|
102
|
+
<i className="pi pi-check" /> Finish Tour
|
|
103
|
+
</>
|
|
104
|
+
),
|
|
105
|
+
onClick: () => stopTour(),
|
|
106
|
+
className: "button button-primary mt-2",
|
|
107
|
+
},
|
|
108
|
+
],
|
|
109
|
+
},
|
|
110
|
+
|
|
111
|
+
error: {
|
|
112
|
+
description: "Oops, something went wrong.",
|
|
113
|
+
buttons: [
|
|
114
|
+
{
|
|
115
|
+
label: (
|
|
116
|
+
<>
|
|
117
|
+
<i className="pi pi-check" /> Close
|
|
118
|
+
</>
|
|
119
|
+
),
|
|
120
|
+
onClick: () => stopTour(),
|
|
121
|
+
},
|
|
122
|
+
],
|
|
123
|
+
},
|
|
124
|
+
};
|
|
125
|
+
|
|
126
|
+
return tourSteps;
|
|
127
|
+
}
|