@edifice.io/react 2.0.0-develop-rc.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +661 -0
- package/README.md +110 -0
- package/dist/audience.js +16 -0
- package/dist/components/ActionBar/ActionBar.d.ts +10 -0
- package/dist/components/ActionBar/ActionBar.js +8 -0
- package/dist/components/ActionBar/index.d.ts +2 -0
- package/dist/components/Alert/Alert.d.ts +60 -0
- package/dist/components/Alert/Alert.js +78 -0
- package/dist/components/Alert/index.d.ts +2 -0
- package/dist/components/AppHeader/AppHeader.d.ts +17 -0
- package/dist/components/AppHeader/AppHeader.js +22 -0
- package/dist/components/AppHeader/index.d.ts +2 -0
- package/dist/components/AppIcon/AppIcon.d.ts +45 -0
- package/dist/components/AppIcon/AppIcon.js +49 -0
- package/dist/components/AppIcon/index.d.ts +1 -0
- package/dist/components/Attachment/Attachment.d.ts +14 -0
- package/dist/components/Attachment/Attachment.js +15 -0
- package/dist/components/Attachment/index.d.ts +2 -0
- package/dist/components/Avatar/Avatar.d.ts +32 -0
- package/dist/components/Avatar/Avatar.js +33 -0
- package/dist/components/Avatar/index.d.ts +2 -0
- package/dist/components/Badge/Badge.d.ts +47 -0
- package/dist/components/Badge/Badge.js +31 -0
- package/dist/components/Badge/index.d.ts +2 -0
- package/dist/components/Breadcrumb/Breadcrumb.d.ts +12 -0
- package/dist/components/Breadcrumb/Breadcrumb.js +28 -0
- package/dist/components/Breadcrumb/BreadcrumbItem.d.ts +13 -0
- package/dist/components/Breadcrumb/BreadcrumbItem.js +14 -0
- package/dist/components/Breadcrumb/BreadcrumbList.d.ts +13 -0
- package/dist/components/Breadcrumb/BreadcrumbList.js +13 -0
- package/dist/components/Breadcrumb/BreadcrumbNav.d.ts +18 -0
- package/dist/components/Breadcrumb/BreadcrumbNav.js +22 -0
- package/dist/components/Breadcrumb/index.d.ts +1 -0
- package/dist/components/Button/Button.d.ts +63 -0
- package/dist/components/Button/Button.js +35 -0
- package/dist/components/Button/IconButton.d.ts +11 -0
- package/dist/components/Button/IconButton.js +18 -0
- package/dist/components/Button/SearchButton.d.ts +21 -0
- package/dist/components/Button/SearchButton.js +17 -0
- package/dist/components/Button/index.d.ts +6 -0
- package/dist/components/Card/Card.d.ts +83 -0
- package/dist/components/Card/Card.js +51 -0
- package/dist/components/Card/CardBody.d.ts +10 -0
- package/dist/components/Card/CardBody.js +18 -0
- package/dist/components/Card/CardContext.d.ts +12 -0
- package/dist/components/Card/CardContext.js +11 -0
- package/dist/components/Card/CardFooter.d.ts +8 -0
- package/dist/components/Card/CardFooter.js +7 -0
- package/dist/components/Card/CardHeader.d.ts +5 -0
- package/dist/components/Card/CardHeader.js +19 -0
- package/dist/components/Card/CardImage.d.ts +9 -0
- package/dist/components/Card/CardImage.js +21 -0
- package/dist/components/Card/CardText.d.ts +9 -0
- package/dist/components/Card/CardText.js +12 -0
- package/dist/components/Card/CardTitle.d.ts +9 -0
- package/dist/components/Card/CardTitle.js +12 -0
- package/dist/components/Card/CardUser.d.ts +8 -0
- package/dist/components/Card/CardUser.js +10 -0
- package/dist/components/Card/index.d.ts +2 -0
- package/dist/components/Checkbox/Checkbox.d.ts +21 -0
- package/dist/components/Checkbox/Checkbox.js +35 -0
- package/dist/components/Checkbox/index.d.ts +2 -0
- package/dist/components/ColorPicker/ColorPalette.d.ts +46 -0
- package/dist/components/ColorPicker/ColorPalette.js +171 -0
- package/dist/components/ColorPicker/ColorPicker.d.ts +18 -0
- package/dist/components/ColorPicker/ColorPicker.js +37 -0
- package/dist/components/ColorPicker/ColorPickerItem.d.ts +20 -0
- package/dist/components/ColorPicker/ColorPickerItem.js +13 -0
- package/dist/components/ColorPicker/index.d.ts +5 -0
- package/dist/components/Combobox/Combobox.d.ts +31 -0
- package/dist/components/Combobox/Combobox.js +41 -0
- package/dist/components/Combobox/ComboboxTrigger.d.ts +9 -0
- package/dist/components/Combobox/ComboboxTrigger.js +30 -0
- package/dist/components/Combobox/index.d.ts +2 -0
- package/dist/components/Dropdown/Dropdown.d.ts +79 -0
- package/dist/components/Dropdown/Dropdown.js +60 -0
- package/dist/components/Dropdown/DropdownCheckboxItem.d.ts +24 -0
- package/dist/components/Dropdown/DropdownCheckboxItem.js +34 -0
- package/dist/components/Dropdown/DropdownContext.d.ts +8 -0
- package/dist/components/Dropdown/DropdownContext.js +11 -0
- package/dist/components/Dropdown/DropdownItem.d.ts +29 -0
- package/dist/components/Dropdown/DropdownItem.js +33 -0
- package/dist/components/Dropdown/DropdownMenu.d.ts +35 -0
- package/dist/components/Dropdown/DropdownMenu.js +26 -0
- package/dist/components/Dropdown/DropdownMenuGroup.d.ts +13 -0
- package/dist/components/Dropdown/DropdownMenuGroup.js +12 -0
- package/dist/components/Dropdown/DropdownRadioItem.d.ts +24 -0
- package/dist/components/Dropdown/DropdownRadioItem.js +34 -0
- package/dist/components/Dropdown/DropdownSeparator.d.ts +5 -0
- package/dist/components/Dropdown/DropdownSeparator.js +5 -0
- package/dist/components/Dropdown/DropdownTrigger.d.ts +38 -0
- package/dist/components/Dropdown/DropdownTrigger.js +34 -0
- package/dist/components/Dropdown/index.d.ts +2 -0
- package/dist/components/Dropzone/Dropzone.d.ts +28 -0
- package/dist/components/Dropzone/Dropzone.js +56 -0
- package/dist/components/Dropzone/DropzoneContext.d.ts +10 -0
- package/dist/components/Dropzone/DropzoneContext.js +12 -0
- package/dist/components/Dropzone/DropzoneDrag.d.ts +5 -0
- package/dist/components/Dropzone/DropzoneDrag.js +11 -0
- package/dist/components/Dropzone/DropzoneFile.d.ts +8 -0
- package/dist/components/Dropzone/DropzoneFile.js +32 -0
- package/dist/components/Dropzone/DropzoneImport.d.ts +5 -0
- package/dist/components/Dropzone/DropzoneImport.js +28 -0
- package/dist/components/Dropzone/index.d.ts +2 -0
- package/dist/components/EmptyScreen/EmptyScreen.d.ts +27 -0
- package/dist/components/EmptyScreen/EmptyScreen.js +20 -0
- package/dist/components/EmptyScreen/index.d.ts +2 -0
- package/dist/components/FileCard/FileCard.d.ts +13 -0
- package/dist/components/FileCard/FileCard.js +91 -0
- package/dist/components/FileCard/FileIcon.d.ts +6 -0
- package/dist/components/FileCard/FileIcon.js +15 -0
- package/dist/components/FileCard/index.d.ts +2 -0
- package/dist/components/Form/FormContext.d.ts +6 -0
- package/dist/components/Form/FormContext.js +11 -0
- package/dist/components/Form/FormControl.d.ts +42 -0
- package/dist/components/Form/FormControl.js +32 -0
- package/dist/components/Form/FormText.d.ts +8 -0
- package/dist/components/Form/FormText.js +17 -0
- package/dist/components/Form/index.d.ts +3 -0
- package/dist/components/Grid/Grid.d.ts +56 -0
- package/dist/components/Grid/Grid.js +32 -0
- package/dist/components/Grid/index.d.ts +1 -0
- package/dist/components/Heading/Heading.d.ts +27 -0
- package/dist/components/Heading/Heading.js +16 -0
- package/dist/components/Heading/index.d.ts +2 -0
- package/dist/components/Icon/Icon.d.ts +17 -0
- package/dist/components/Icon/Icon.js +10 -0
- package/dist/components/Icon/index.d.ts +1 -0
- package/dist/components/Image/Image.d.ts +29 -0
- package/dist/components/Image/Image.js +41 -0
- package/dist/components/Image/index.d.ts +2 -0
- package/dist/components/ImagePicker/ImagePicker.d.ts +38 -0
- package/dist/components/ImagePicker/ImagePicker.js +58 -0
- package/dist/components/ImagePicker/index.d.ts +1 -0
- package/dist/components/Input/Input.d.ts +33 -0
- package/dist/components/Input/Input.js +31 -0
- package/dist/components/Input/index.d.ts +2 -0
- package/dist/components/Label/Label.d.ts +26 -0
- package/dist/components/Label/Label.js +37 -0
- package/dist/components/Label/index.d.ts +2 -0
- package/dist/components/Loading/Loading.d.ts +29 -0
- package/dist/components/Loading/Loading.js +27 -0
- package/dist/components/Loading/index.d.ts +2 -0
- package/dist/components/LoadingScreen/LoadingScreen.d.ts +7 -0
- package/dist/components/LoadingScreen/LoadingScreen.js +25 -0
- package/dist/components/LoadingScreen/index.d.ts +1 -0
- package/dist/components/Logo/Logo.d.ts +8 -0
- package/dist/components/Logo/Logo.js +14 -0
- package/dist/components/Logo/index.d.ts +2 -0
- package/dist/components/Menu/Menu.d.ts +14 -0
- package/dist/components/Menu/Menu.js +58 -0
- package/dist/components/Menu/MenuButton.d.ts +5 -0
- package/dist/components/Menu/MenuButton.js +21 -0
- package/dist/components/Menu/MenuContext.d.ts +10 -0
- package/dist/components/Menu/MenuContext.js +12 -0
- package/dist/components/Menu/MenuItem.d.ts +4 -0
- package/dist/components/Menu/MenuItem.js +19 -0
- package/dist/components/Menu/index.d.ts +2 -0
- package/dist/components/Modal/Modal.d.ts +56 -0
- package/dist/components/Modal/Modal.js +72 -0
- package/dist/components/Modal/ModalBody.d.ts +19 -0
- package/dist/components/Modal/ModalBody.js +15 -0
- package/dist/components/Modal/ModalContext.d.ts +8 -0
- package/dist/components/Modal/ModalContext.js +15 -0
- package/dist/components/Modal/ModalFooter.d.ts +12 -0
- package/dist/components/Modal/ModalFooter.js +5 -0
- package/dist/components/Modal/ModalHeader.d.ts +19 -0
- package/dist/components/Modal/ModalHeader.js +27 -0
- package/dist/components/Modal/ModalSubtitle.d.ts +12 -0
- package/dist/components/Modal/ModalSubtitle.js +5 -0
- package/dist/components/Modal/index.d.ts +2 -0
- package/dist/components/Popover/Popover.d.ts +33 -0
- package/dist/components/Popover/Popover.js +51 -0
- package/dist/components/Popover/index.d.ts +1 -0
- package/dist/components/Radio/Radio.d.ts +25 -0
- package/dist/components/Radio/Radio.js +31 -0
- package/dist/components/Radio/index.d.ts +2 -0
- package/dist/components/SearchBar/SearchBar.d.ts +51 -0
- package/dist/components/SearchBar/SearchBar.js +36 -0
- package/dist/components/SearchBar/index.d.ts +2 -0
- package/dist/components/Select/Select.d.ts +39 -0
- package/dist/components/Select/Select.js +37 -0
- package/dist/components/Select/SelectTrigger.d.ts +8 -0
- package/dist/components/Select/SelectTrigger.js +6 -0
- package/dist/components/Select/index.d.ts +2 -0
- package/dist/components/Table/TableExplorer.d.ts +14 -0
- package/dist/components/Table/TableExplorer.js +8 -0
- package/dist/components/Table/index.d.ts +2 -0
- package/dist/components/Tabs/Tabs.d.ts +42 -0
- package/dist/components/Tabs/Tabs.js +75 -0
- package/dist/components/Tabs/TabsContext.d.ts +12 -0
- package/dist/components/Tabs/TabsContext.js +12 -0
- package/dist/components/Tabs/TabsItem.d.ts +26 -0
- package/dist/components/Tabs/TabsItem.js +26 -0
- package/dist/components/Tabs/TabsList.d.ts +6 -0
- package/dist/components/Tabs/TabsList.js +24 -0
- package/dist/components/Tabs/TabsPanel.d.ts +17 -0
- package/dist/components/Tabs/TabsPanel.js +14 -0
- package/dist/components/Tabs/index.d.ts +3 -0
- package/dist/components/TextArea/TextArea.d.ts +33 -0
- package/dist/components/TextArea/TextArea.js +34 -0
- package/dist/components/TextArea/TextareaCounter.d.ts +4 -0
- package/dist/components/TextArea/TextareaCounter.js +8 -0
- package/dist/components/TextArea/index.d.ts +2 -0
- package/dist/components/Toolbar/Toolbar.d.ts +76 -0
- package/dist/components/Toolbar/Toolbar.js +77 -0
- package/dist/components/Toolbar/index.d.ts +2 -0
- package/dist/components/Tooltip/Tooltip.d.ts +22 -0
- package/dist/components/Tooltip/Tooltip.js +40 -0
- package/dist/components/Tooltip/index.d.ts +2 -0
- package/dist/components/TreeView/TreeItem.d.ts +52 -0
- package/dist/components/TreeView/TreeItem.js +54 -0
- package/dist/components/TreeView/TreeNode.d.ts +22 -0
- package/dist/components/TreeView/TreeView.d.ts +40 -0
- package/dist/components/TreeView/TreeView.js +39 -0
- package/dist/components/TreeView/hooks/useTreeItemEvents.d.ts +8 -0
- package/dist/components/TreeView/hooks/useTreeItemEvents.js +28 -0
- package/dist/components/TreeView/index.d.ts +3 -0
- package/dist/components/UploadCard/UploadCard.d.ts +42 -0
- package/dist/components/UploadCard/UploadCard.js +72 -0
- package/dist/components/UploadCard/index.d.ts +1 -0
- package/dist/components/VisuallyHidden/VisuallyHidden.d.ts +6 -0
- package/dist/components/VisuallyHidden/VisuallyHidden.js +8 -0
- package/dist/components/VisuallyHidden/index.d.ts +1 -0
- package/dist/components/index.d.ts +42 -0
- package/dist/core/OdeClientProvider/OdeClientProvider.d.ts +28 -0
- package/dist/core/OdeClientProvider/OdeClientProvider.js +62 -0
- package/dist/core/OdeClientProvider/index.d.ts +1 -0
- package/dist/core/ThemeProvider/ThemeProvider.d.ts +11 -0
- package/dist/core/ThemeProvider/ThemeProvider.js +52 -0
- package/dist/core/ThemeProvider/index.d.ts +1 -0
- package/dist/core/index.d.ts +24 -0
- package/dist/core/useAvatar/index.d.ts +1 -0
- package/dist/core/useAvatar/useAvatar.d.ts +6 -0
- package/dist/core/useAvatar/useAvatar.js +30 -0
- package/dist/core/useBookmark/index.d.ts +1 -0
- package/dist/core/useBookmark/useBookmark.d.ts +2 -0
- package/dist/core/useBookmark/useBookmark.js +14 -0
- package/dist/core/useConf/index.d.ts +1 -0
- package/dist/core/useConf/useConf.d.ts +4 -0
- package/dist/core/useConf/useConf.js +13 -0
- package/dist/core/useConversation/index.d.ts +1 -0
- package/dist/core/useConversation/useConversation.d.ts +6 -0
- package/dist/core/useConversation/useConversation.js +43 -0
- package/dist/core/useCookiesConsent/index.d.ts +1 -0
- package/dist/core/useCookiesConsent/useCookiesConsent.d.ts +5 -0
- package/dist/core/useCookiesConsent/useCookiesConsent.js +29 -0
- package/dist/core/useDate/index.d.ts +2 -0
- package/dist/core/useDate/useDate.d.ts +13 -0
- package/dist/core/useDate/useDate.js +65 -0
- package/dist/core/useHasWorkflow/index.d.ts +1 -0
- package/dist/core/useHasWorkflow/useHasWorkflow.d.ts +1 -0
- package/dist/core/useHasWorkflow/useHasWorkflow.js +22 -0
- package/dist/core/useHeader/index.d.ts +1 -0
- package/dist/core/useHeader/useHeader.d.ts +5 -0
- package/dist/core/useHeader/useHeader.js +46 -0
- package/dist/core/useHttpErrorToast/index.d.ts +1 -0
- package/dist/core/useHttpErrorToast/useHttpErrorToast.d.ts +2 -0
- package/dist/core/useHttpErrorToast/useHttpErrorToast.js +21 -0
- package/dist/core/useIsAdml/index.d.ts +1 -0
- package/dist/core/useIsAdml/useIsAdml.d.ts +3 -0
- package/dist/core/useIsAdml/useIsAdml.js +18 -0
- package/dist/core/useLibraryUrl/index.d.ts +1 -0
- package/dist/core/useLibraryUrl/useLibraryUrl.d.ts +7 -0
- package/dist/core/useLibraryUrl/useLibraryUrl.js +21 -0
- package/dist/core/useMediaLibrary/index.d.ts +1 -0
- package/dist/core/useMediaLibrary/useMediaLibrary.d.ts +12 -0
- package/dist/core/useMediaLibrary/useMediaLibrary.js +58 -0
- package/dist/core/useOdeIcons/index.d.ts +1 -0
- package/dist/core/useOdeIcons/useOdeIcons.d.ts +9 -0
- package/dist/core/useOdeIcons/useOdeIcons.js +92 -0
- package/dist/core/usePaths/index.d.ts +1 -0
- package/dist/core/usePaths/usePaths.d.ts +1 -0
- package/dist/core/usePaths/usePaths.js +6 -0
- package/dist/core/usePreferences/index.d.ts +1 -0
- package/dist/core/usePreferences/usePreferences.d.ts +4 -0
- package/dist/core/usePreferences/usePreferences.js +10 -0
- package/dist/core/useResource/index.d.ts +1 -0
- package/dist/core/useResource/useResource.d.ts +3 -0
- package/dist/core/useResource/useResource.js +25 -0
- package/dist/core/useResourceSearch/index.d.ts +1 -0
- package/dist/core/useResourceSearch/useResourceSearch.d.ts +18 -0
- package/dist/core/useResourceSearch/useResourceSearch.js +34 -0
- package/dist/core/useSession/index.d.ts +1 -0
- package/dist/core/useSession/useSession.d.ts +1 -0
- package/dist/core/useSession/useSession.js +11 -0
- package/dist/core/useTrashedResource/index.d.ts +1 -0
- package/dist/core/useTrashedResource/useTrashedResource.d.ts +6 -0
- package/dist/core/useTrashedResource/useTrashedResource.js +27 -0
- package/dist/core/useUpload/index.d.ts +1 -0
- package/dist/core/useUpload/useUpload.d.ts +18 -0
- package/dist/core/useUpload/useUpload.js +106 -0
- package/dist/core/useUploadFiles/index.d.ts +1 -0
- package/dist/core/useUploadFiles/useUploadFiles.d.ts +25 -0
- package/dist/core/useUploadFiles/useUploadFiles.js +101 -0
- package/dist/core/useUser/index.d.ts +1 -0
- package/dist/core/useUser/useUser.d.ts +7 -0
- package/dist/core/useUser/useUser.js +22 -0
- package/dist/core/useWorkspaceFile/index.d.ts +1 -0
- package/dist/core/useWorkspaceFile/useWorkspaceFile.d.ts +21 -0
- package/dist/core/useWorkspaceFile/useWorkspaceFile.js +49 -0
- package/dist/core/useWorkspaceSearch/index.d.ts +1 -0
- package/dist/core/useWorkspaceSearch/useWorkspaceSearch.d.ts +9 -0
- package/dist/core/useWorkspaceSearch/useWorkspaceSearch.js +58 -0
- package/dist/core/useXitiTrackPageLoad/index.d.ts +1 -0
- package/dist/core/useXitiTrackPageLoad/useXitiTrackPageLoad.d.ts +4 -0
- package/dist/core/useXitiTrackPageLoad/useXitiTrackPageLoad.js +28 -0
- package/dist/core/useZendeskGuide/index.d.ts +1 -0
- package/dist/core/useZendeskGuide/useZendeskGuide.d.ts +2 -0
- package/dist/core/useZendeskGuide/useZendeskGuide.js +101 -0
- package/dist/editor.js +58 -0
- package/dist/hooks/index.d.ts +14 -0
- package/dist/hooks/useBrowserInfo/index.d.ts +1 -0
- package/dist/hooks/useBrowserInfo/useBrowserInfo.d.ts +9 -0
- package/dist/hooks/useBrowserInfo/useBrowserInfo.js +16 -0
- package/dist/hooks/useClickOutside/index.d.ts +1 -0
- package/dist/hooks/useClickOutside/useClickOutside.d.ts +2 -0
- package/dist/hooks/useClickOutside/useClickOutside.js +26 -0
- package/dist/hooks/useDebounce/index.d.ts +1 -0
- package/dist/hooks/useDebounce/useDebounce.d.ts +2 -0
- package/dist/hooks/useDebounce/useDebounce.js +15 -0
- package/dist/hooks/useDropdown/index.d.ts +1 -0
- package/dist/hooks/useDropdown/useDropdown.d.ts +32 -0
- package/dist/hooks/useDropdown/useDropdown.js +158 -0
- package/dist/hooks/useDropzone/index.d.ts +1 -0
- package/dist/hooks/useDropzone/useDropzone.d.ts +34 -0
- package/dist/hooks/useDropzone/useDropzone.js +76 -0
- package/dist/hooks/useHover/index.d.ts +1 -0
- package/dist/hooks/useHover/useHover.d.ts +2 -0
- package/dist/hooks/useHover/useHover.js +22 -0
- package/dist/hooks/useImage/index.d.ts +1 -0
- package/dist/hooks/useImage/useImage.d.ts +9 -0
- package/dist/hooks/useImage/useImage.js +18 -0
- package/dist/hooks/useImageResizer/index.d.ts +1 -0
- package/dist/hooks/useImageResizer/useImageResizer.d.ts +8 -0
- package/dist/hooks/useImageResizer/useImageResizer.js +42 -0
- package/dist/hooks/useKeyPress/index.d.ts +1 -0
- package/dist/hooks/useKeyPress/useKeyPress.d.ts +1 -0
- package/dist/hooks/useKeyPress/useKeyPress.js +14 -0
- package/dist/hooks/useScrollToTop/index.d.ts +1 -0
- package/dist/hooks/useScrollToTop/useScrollToTop.d.ts +1 -0
- package/dist/hooks/useScrollToTop/useScrollToTop.js +9 -0
- package/dist/hooks/useThumbnail/index.d.ts +1 -0
- package/dist/hooks/useThumbnail/useThumbnail.d.ts +14 -0
- package/dist/hooks/useThumbnail/useThumbnail.js +29 -0
- package/dist/hooks/useTitle/index.d.ts +1 -0
- package/dist/hooks/useTitle/useTitle.d.ts +1 -0
- package/dist/hooks/useTitle/useTitle.js +10 -0
- package/dist/hooks/useToast/index.d.ts +1 -0
- package/dist/hooks/useToast/useToast.d.ts +17 -0
- package/dist/hooks/useToast/useToast.js +34 -0
- package/dist/hooks/useToggle/index.d.ts +1 -0
- package/dist/hooks/useToggle/useToggle.d.ts +1 -0
- package/dist/hooks/useToggle/useToggle.js +10 -0
- package/dist/hooks/useTrapFocus/index.d.ts +1 -0
- package/dist/hooks/useTrapFocus/useTrapFocus.d.ts +2 -0
- package/dist/hooks/useTrapFocus/useTrapFocus.js +16 -0
- package/dist/index.d.ts +6 -0
- package/dist/index.js +227 -0
- package/dist/modals.js +18 -0
- package/dist/modules/audience/ReactionChoice.d.ts +11 -0
- package/dist/modules/audience/ReactionChoice.js +33 -0
- package/dist/modules/audience/ReactionModal.Card.d.ts +4 -0
- package/dist/modules/audience/ReactionModal.Card.js +34 -0
- package/dist/modules/audience/ReactionModal.d.ts +20 -0
- package/dist/modules/audience/ReactionModal.js +73 -0
- package/dist/modules/audience/ReactionSummary.d.ts +10 -0
- package/dist/modules/audience/ReactionSummary.js +27 -0
- package/dist/modules/audience/ViewsByProfileCard.d.ts +9 -0
- package/dist/modules/audience/ViewsByProfileCard.js +35 -0
- package/dist/modules/audience/ViewsCounter.d.ts +11 -0
- package/dist/modules/audience/ViewsCounter.js +18 -0
- package/dist/modules/audience/ViewsModal.d.ts +11 -0
- package/dist/modules/audience/ViewsModal.js +40 -0
- package/dist/modules/audience/hooks/useReactionIcons.d.ts +5 -0
- package/dist/modules/audience/hooks/useReactionIcons.js +37 -0
- package/dist/modules/audience/hooks/useReactions.d.ts +15 -0
- package/dist/modules/audience/hooks/useReactions.js +35 -0
- package/dist/modules/audience/hooks/useViews.d.ts +11 -0
- package/dist/modules/audience/index.d.ts +12 -0
- package/dist/modules/editor/components/BubbleMenuEditImage/BubbleMenuEditImage.d.ts +8 -0
- package/dist/modules/editor/components/BubbleMenuEditImage/BubbleMenuEditImage.js +132 -0
- package/dist/modules/editor/components/BubbleMenuEditImage/index.d.ts +1 -0
- package/dist/modules/editor/components/Editor/Editor.d.ts +45 -0
- package/dist/modules/editor/components/Editor/Editor.js +83 -0
- package/dist/modules/editor/components/Editor/MathsModal.d.ts +8 -0
- package/dist/modules/editor/components/Editor/MathsModal.js +50 -0
- package/dist/modules/editor/components/Editor/index.d.ts +2 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.DropdownMenu.d.ts +22 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.DropdownMenu.js +17 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.Emoji.d.ts +14 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.Emoji.js +54 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.HighlightColor.d.ts +14 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.HighlightColor.js +47 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.PlusMenu.d.ts +9 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.PlusMenu.js +18 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.TextColor.d.ts +14 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.TextColor.js +50 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.TextSize.d.ts +10 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.TextSize.js +62 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.Typography.d.ts +10 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.Typography.js +52 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.d.ts +10 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.js +319 -0
- package/dist/modules/editor/components/EditorToolbar/index.d.ts +1 -0
- package/dist/modules/editor/components/NodeView/AttachmentNodeView.d.ts +2 -0
- package/dist/modules/editor/components/NodeView/AttachmentNodeView.js +10 -0
- package/dist/modules/editor/components/NodeView/AudioNodeView.d.ts +2 -0
- package/dist/modules/editor/components/NodeView/AudioNodeView.js +10 -0
- package/dist/modules/editor/components/NodeView/ImageNodeView.d.ts +2 -0
- package/dist/modules/editor/components/NodeView/ImageNodeView.js +10 -0
- package/dist/modules/editor/components/NodeView/LinkerNodeView.d.ts +2 -0
- package/dist/modules/editor/components/NodeView/LinkerNodeView.js +10 -0
- package/dist/modules/editor/components/NodeView/VideoNodeView.d.ts +2 -0
- package/dist/modules/editor/components/NodeView/VideoNodeView.js +10 -0
- package/dist/modules/editor/components/NodeView/index.d.ts +5 -0
- package/dist/modules/editor/components/Renderer/AttachmentRenderer.d.ts +7 -0
- package/dist/modules/editor/components/Renderer/AttachmentRenderer.js +34 -0
- package/dist/modules/editor/components/Renderer/AudioRenderer.d.ts +7 -0
- package/dist/modules/editor/components/Renderer/AudioRenderer.js +11 -0
- package/dist/modules/editor/components/Renderer/LinkerRenderer.d.ts +9 -0
- package/dist/modules/editor/components/Renderer/LinkerRenderer.js +34 -0
- package/dist/modules/editor/components/Renderer/MediaRenderer.d.ts +2 -0
- package/dist/modules/editor/components/Renderer/MediaRenderer.js +69 -0
- package/dist/modules/editor/components/Renderer/index.d.ts +4 -0
- package/dist/modules/editor/components/Toolbar/LinkToolbar.TippyOptions.d.ts +2 -0
- package/dist/modules/editor/components/Toolbar/LinkToolbar.TippyOptions.js +8 -0
- package/dist/modules/editor/components/Toolbar/LinkToolbar.d.ts +15 -0
- package/dist/modules/editor/components/Toolbar/LinkToolbar.js +59 -0
- package/dist/modules/editor/components/Toolbar/TableToolbar.AddMenu.d.ts +9 -0
- package/dist/modules/editor/components/Toolbar/TableToolbar.AddMenu.js +28 -0
- package/dist/modules/editor/components/Toolbar/TableToolbar.CellColor.d.ts +13 -0
- package/dist/modules/editor/components/Toolbar/TableToolbar.CellColor.js +45 -0
- package/dist/modules/editor/components/Toolbar/TableToolbar.DelMenu.d.ts +9 -0
- package/dist/modules/editor/components/Toolbar/TableToolbar.DelMenu.js +27 -0
- package/dist/modules/editor/components/Toolbar/TableToolbar.d.ts +9 -0
- package/dist/modules/editor/components/Toolbar/TableToolbar.js +88 -0
- package/dist/modules/editor/components/Toolbar/index.d.ts +2 -0
- package/dist/modules/editor/components/index.d.ts +6 -0
- package/dist/modules/editor/hooks/index.d.ts +12 -0
- package/dist/modules/editor/hooks/useActionOptions.d.ts +5 -0
- package/dist/modules/editor/hooks/useActionOptions.js +75 -0
- package/dist/modules/editor/hooks/useCommentEditor.d.ts +13 -0
- package/dist/modules/editor/hooks/useCommentEditor.js +37 -0
- package/dist/modules/editor/hooks/useEditorContext.d.ts +37 -0
- package/dist/modules/editor/hooks/useEditorContext.js +12 -0
- package/dist/modules/editor/hooks/useImageModal.d.ts +31 -0
- package/dist/modules/editor/hooks/useImageModal.js +46 -0
- package/dist/modules/editor/hooks/useImageSelection.d.ts +21 -0
- package/dist/modules/editor/hooks/useImageSelection.js +46 -0
- package/dist/modules/editor/hooks/useLinkToolbar.d.ts +17 -0
- package/dist/modules/editor/hooks/useLinkToolbar.js +37 -0
- package/dist/modules/editor/hooks/useMathsModal.d.ts +17 -0
- package/dist/modules/editor/hooks/useMathsModal.js +17 -0
- package/dist/modules/editor/hooks/useMathsStyles.d.ts +1 -0
- package/dist/modules/editor/hooks/useMathsStyles.js +20 -0
- package/dist/modules/editor/hooks/useMediaLibraryEditor.d.ts +19 -0
- package/dist/modules/editor/hooks/useMediaLibraryEditor.js +152 -0
- package/dist/modules/editor/hooks/useResizeMedia.d.ts +10 -0
- package/dist/modules/editor/hooks/useResizeMedia.js +47 -0
- package/dist/modules/editor/hooks/useSpeechRecognition.d.ts +6 -0
- package/dist/modules/editor/hooks/useSpeechRecognition.js +21 -0
- package/dist/modules/editor/hooks/useSpeechSynthetisis.d.ts +12 -0
- package/dist/modules/editor/hooks/useSpeechSynthetisis.js +20 -0
- package/dist/modules/editor/hooks/useTipTapEditor.d.ts +15 -0
- package/dist/modules/editor/hooks/useTipTapEditor.js +75 -0
- package/dist/modules/editor/index.d.ts +3 -0
- package/dist/modules/editor/utils/has-extension.d.ts +2 -0
- package/dist/modules/editor/utils/has-extension.js +4 -0
- package/dist/modules/editor/utils/has-mark.d.ts +2 -0
- package/dist/modules/editor/utils/has-mark.js +4 -0
- package/dist/modules/editor/utils/has-text-style.d.ts +2 -0
- package/dist/modules/editor/utils/has-text-style.js +5 -0
- package/dist/modules/modals/OnboardingModal/OnboardingModal.d.ts +43 -0
- package/dist/modules/modals/OnboardingModal/OnboardingModal.js +59 -0
- package/dist/modules/modals/OnboardingModal/index.d.ts +1 -0
- package/dist/modules/modals/OnboardingModal/useOnboardingModal.d.ts +7 -0
- package/dist/modules/modals/OnboardingModal/useOnboardingModal.js +30 -0
- package/dist/modules/modals/PublishModal/PublishModal.d.ts +9 -0
- package/dist/modules/modals/PublishModal/PublishModal.js +120 -0
- package/dist/modules/modals/PublishModal/components/ActivitiesDropdown.d.ts +7 -0
- package/dist/modules/modals/PublishModal/components/ActivitiesDropdown.js +29 -0
- package/dist/modules/modals/PublishModal/components/AgeSelect.d.ts +8 -0
- package/dist/modules/modals/PublishModal/components/AgeSelect.js +20 -0
- package/dist/modules/modals/PublishModal/components/LangSelect.d.ts +5 -0
- package/dist/modules/modals/PublishModal/components/LangSelect.js +19 -0
- package/dist/modules/modals/PublishModal/components/PublishModalFooter.d.ts +1 -0
- package/dist/modules/modals/PublishModal/components/PublishModalFooter.js +23 -0
- package/dist/modules/modals/PublishModal/components/SubjectsDropdown.d.ts +7 -0
- package/dist/modules/modals/PublishModal/components/SubjectsDropdown.js +29 -0
- package/dist/modules/modals/PublishModal/components/ToastError.d.ts +5 -0
- package/dist/modules/modals/PublishModal/components/ToastError.js +24 -0
- package/dist/modules/modals/PublishModal/components/ToastSuccess.d.ts +4 -0
- package/dist/modules/modals/PublishModal/components/ToastSuccess.js +18 -0
- package/dist/modules/modals/PublishModal/constants/ageOptions.d.ts +1 -0
- package/dist/modules/modals/PublishModal/constants/ageOptions.js +4 -0
- package/dist/modules/modals/PublishModal/hooks/useActivitiesOptions.d.ts +4 -0
- package/dist/modules/modals/PublishModal/hooks/useActivitiesOptions.js +34 -0
- package/dist/modules/modals/PublishModal/hooks/useLanguageOptions.d.ts +4 -0
- package/dist/modules/modals/PublishModal/hooks/useLanguageOptions.js +43 -0
- package/dist/modules/modals/PublishModal/hooks/usePublishModal.d.ts +38 -0
- package/dist/modules/modals/PublishModal/hooks/usePublishModal.js +106 -0
- package/dist/modules/modals/PublishModal/hooks/useSubjectsOptions.d.ts +4 -0
- package/dist/modules/modals/PublishModal/hooks/useSubjectsOptions.js +118 -0
- package/dist/modules/modals/PublishModal/index.d.ts +1 -0
- package/dist/modules/modals/ResourceModal/ResourceModal.d.ts +30 -0
- package/dist/modules/modals/ResourceModal/ResourceModal.js +156 -0
- package/dist/modules/modals/ResourceModal/apps/BlogPublic.d.ts +13 -0
- package/dist/modules/modals/ResourceModal/apps/BlogPublic.js +62 -0
- package/dist/modules/modals/ResourceModal/hooks/useSlug.d.ts +17 -0
- package/dist/modules/modals/ResourceModal/hooks/useSlug.js +41 -0
- package/dist/modules/modals/ResourceModal/hooks/useThumb.d.ts +11 -0
- package/dist/modules/modals/ResourceModal/hooks/useThumb.js +17 -0
- package/dist/modules/modals/ResourceModal/hooks/useUpdateMutation.d.ts +7 -0
- package/dist/modules/modals/ResourceModal/hooks/useUpdateMutation.js +12 -0
- package/dist/modules/modals/ResourceModal/index.d.ts +3 -0
- package/dist/modules/modals/ShareModal/ShareBookmark.d.ts +8 -0
- package/dist/modules/modals/ShareModal/ShareBookmark.js +22 -0
- package/dist/modules/modals/ShareModal/ShareBookmarkLine.d.ts +9 -0
- package/dist/modules/modals/ShareModal/ShareBookmarkLine.js +42 -0
- package/dist/modules/modals/ShareModal/ShareModal.d.ts +41 -0
- package/dist/modules/modals/ShareModal/ShareModal.js +128 -0
- package/dist/modules/modals/ShareModal/apps/ShareBlog.d.ts +8 -0
- package/dist/modules/modals/ShareModal/apps/ShareBlog.js +42 -0
- package/dist/modules/modals/ShareModal/hooks/useSearch.d.ts +24 -0
- package/dist/modules/modals/ShareModal/hooks/useSearch.js +178 -0
- package/dist/modules/modals/ShareModal/hooks/useShare.d.ts +54 -0
- package/dist/modules/modals/ShareModal/hooks/useShare.js +192 -0
- package/dist/modules/modals/ShareModal/hooks/useShareBookmark.d.ts +23 -0
- package/dist/modules/modals/ShareModal/hooks/useShareBookmark.js +67 -0
- package/dist/modules/modals/ShareModal/hooks/useShareMutation.d.ts +13 -0
- package/dist/modules/modals/ShareModal/hooks/useShareMutation.js +15 -0
- package/dist/modules/modals/ShareModal/index.d.ts +3 -0
- package/dist/modules/modals/ShareModal/utils/hasRight.d.ts +2 -0
- package/dist/modules/modals/ShareModal/utils/hasRight.js +4 -0
- package/dist/modules/modals/ShareModal/utils/showShareRightLine.d.ts +2 -0
- package/dist/modules/modals/ShareModal/utils/showShareRightLine.js +4 -0
- package/dist/modules/modals/index.d.ts +4 -0
- package/dist/modules/multimedia/AudioRecorder/AudioRecorder.d.ts +12 -0
- package/dist/modules/multimedia/AudioRecorder/AudioRecorder.js +49 -0
- package/dist/modules/multimedia/AudioRecorder/AudioRecorderTimer.d.ts +10 -0
- package/dist/modules/multimedia/AudioRecorder/AudioRecorderTimer.js +24 -0
- package/dist/modules/multimedia/AudioRecorder/index.d.ts +1 -0
- package/dist/modules/multimedia/AudioRecorder/useAudioRecorder.d.ts +16 -0
- package/dist/modules/multimedia/AudioRecorder/useAudioRecorder.js +307 -0
- package/dist/modules/multimedia/Embed/Embed.d.ts +5 -0
- package/dist/modules/multimedia/Embed/Embed.js +32 -0
- package/dist/modules/multimedia/Embed/index.d.ts +2 -0
- package/dist/modules/multimedia/ImageEditor/components/ImageEditor.d.ts +27 -0
- package/dist/modules/multimedia/ImageEditor/components/ImageEditor.js +116 -0
- package/dist/modules/multimedia/ImageEditor/components/ImageEditorToolbar.d.ts +7 -0
- package/dist/modules/multimedia/ImageEditor/components/ImageEditorToolbar.js +69 -0
- package/dist/modules/multimedia/ImageEditor/effects/blur.d.ts +19 -0
- package/dist/modules/multimedia/ImageEditor/effects/blur.js +72 -0
- package/dist/modules/multimedia/ImageEditor/effects/crop.d.ts +28 -0
- package/dist/modules/multimedia/ImageEditor/effects/crop.js +155 -0
- package/dist/modules/multimedia/ImageEditor/effects/misc.d.ts +154 -0
- package/dist/modules/multimedia/ImageEditor/effects/misc.js +162 -0
- package/dist/modules/multimedia/ImageEditor/effects/resize.d.ts +25 -0
- package/dist/modules/multimedia/ImageEditor/effects/resize.js +157 -0
- package/dist/modules/multimedia/ImageEditor/effects/rotate.d.ts +8 -0
- package/dist/modules/multimedia/ImageEditor/effects/rotate.js +33 -0
- package/dist/modules/multimedia/ImageEditor/hooks/useHistoryTool.d.ts +32 -0
- package/dist/modules/multimedia/ImageEditor/hooks/useHistoryTool.js +66 -0
- package/dist/modules/multimedia/ImageEditor/hooks/useImageEditor.d.ts +30 -0
- package/dist/modules/multimedia/ImageEditor/hooks/useImageEditor.js +76 -0
- package/dist/modules/multimedia/ImageEditor/hooks/useImageEffects.d.ts +23 -0
- package/dist/modules/multimedia/ImageEditor/hooks/useImageEffects.js +52 -0
- package/dist/modules/multimedia/ImageEditor/index.d.ts +1 -0
- package/dist/modules/multimedia/ImageEditor/utils/aggregate.d.ts +9 -0
- package/dist/modules/multimedia/ImageEditor/utils/aggregate.js +13 -0
- package/dist/modules/multimedia/ImageEditor/utils/debounceAggregate.d.ts +10 -0
- package/dist/modules/multimedia/ImagePickerWorkspace/ImagePickerWorkspace.d.ts +46 -0
- package/dist/modules/multimedia/ImagePickerWorkspace/ImagePickerWorkspace.js +39 -0
- package/dist/modules/multimedia/ImagePickerWorkspace/index.d.ts +2 -0
- package/dist/modules/multimedia/Linker/ExternalLinker.d.ts +28 -0
- package/dist/modules/multimedia/Linker/ExternalLinker.js +45 -0
- package/dist/modules/multimedia/Linker/InternalLinker.d.ts +28 -0
- package/dist/modules/multimedia/Linker/InternalLinker.js +114 -0
- package/dist/modules/multimedia/Linker/index.d.ts +4 -0
- package/dist/modules/multimedia/LinkerCard/LinkerCard.d.ts +13 -0
- package/dist/modules/multimedia/LinkerCard/LinkerCard.js +38 -0
- package/dist/modules/multimedia/LinkerCard/index.d.ts +2 -0
- package/dist/modules/multimedia/MediaLibrary/MediaLibrary.d.ts +84 -0
- package/dist/modules/multimedia/MediaLibrary/MediaLibrary.js +211 -0
- package/dist/modules/multimedia/MediaLibrary/MediaLibraryContext.d.ts +60 -0
- package/dist/modules/multimedia/MediaLibrary/MediaLibraryContext.js +12 -0
- package/dist/modules/multimedia/MediaLibrary/index.d.ts +3 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/Audio.d.ts +1 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/Audio.js +19 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/ExternalLink.d.ts +6 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/ExternalLink.js +17 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/Iframe.d.ts +1 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/Iframe.js +14 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/InternalLink.d.ts +11 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/InternalLink.js +35 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/Upload.d.ts +1 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/Upload.js +34 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/Video.d.ts +1 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/Video.js +22 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/VideoEmbedder.d.ts +1 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/VideoEmbedder.js +14 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/Workspace.d.ts +1 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/Workspace.js +31 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/index.d.ts +10 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/index.js +21 -0
- package/dist/modules/multimedia/UploadFiles/UploadFiles.d.ts +9 -0
- package/dist/modules/multimedia/UploadFiles/UploadFiles.js +56 -0
- package/dist/modules/multimedia/UploadFiles/index.d.ts +2 -0
- package/dist/modules/multimedia/VideoEmbed/VideoEmbed.d.ts +5 -0
- package/dist/modules/multimedia/VideoEmbed/VideoEmbed.js +77 -0
- package/dist/modules/multimedia/VideoEmbed/index.d.ts +1 -0
- package/dist/modules/multimedia/VideoRecorder/VideoRecorder.d.ts +14 -0
- package/dist/modules/multimedia/VideoRecorder/VideoRecorder.js +259 -0
- package/dist/modules/multimedia/VideoRecorder/index.d.ts +1 -0
- package/dist/modules/multimedia/Workspace/Workspace.d.ts +33 -0
- package/dist/modules/multimedia/Workspace/Workspace.js +169 -0
- package/dist/modules/multimedia/Workspace/index.d.ts +2 -0
- package/dist/modules/multimedia/index.d.ts +8 -0
- package/dist/multimedia.js +20 -0
- package/dist/portal/Header/Badge.d.ts +5 -0
- package/dist/portal/Header/Badge.js +9 -0
- package/dist/portal/Header/Header.d.ts +9 -0
- package/dist/portal/Header/Header.js +170 -0
- package/dist/portal/Header/NavItem.d.ts +6 -0
- package/dist/portal/Header/NavItem.js +14 -0
- package/dist/portal/Header/NavLink.d.ts +24 -0
- package/dist/portal/Header/NavLink.js +19 -0
- package/dist/portal/Header/Navbar.d.ts +6 -0
- package/dist/portal/Header/Navbar.js +13 -0
- package/dist/portal/Header/NavbarNav.d.ts +6 -0
- package/dist/portal/Header/NavbarNav.js +13 -0
- package/dist/portal/Header/WidgetApps.d.ts +9 -0
- package/dist/portal/Header/WidgetApps.js +23 -0
- package/dist/portal/Header/index.d.ts +5 -0
- package/dist/portal/Help/Help.d.ts +9 -0
- package/dist/portal/Help/Help.js +25 -0
- package/dist/portal/Help/hooks/useHelp.d.ts +10 -0
- package/dist/portal/Help/hooks/useHelp.js +85 -0
- package/dist/portal/Help/index.d.ts +1 -0
- package/dist/portal/Layout/Layout.d.ts +12 -0
- package/dist/portal/Layout/Layout.js +42 -0
- package/dist/portal/Layout/index.d.ts +1 -0
- package/dist/portal/Main/Main.d.ts +16 -0
- package/dist/portal/Main/index.d.ts +2 -0
- package/dist/portal/SearchEngine/SearchEngine.d.ts +5 -0
- package/dist/portal/SearchEngine/SearchEngine.js +33 -0
- package/dist/portal/SearchEngine/index.d.ts +1 -0
- package/dist/portal/index.d.ts +1 -0
- package/dist/types/index.d.ts +2 -0
- package/dist/types/size.d.ts +1 -0
- package/dist/types/status.d.ts +1 -0
- package/dist/utils/MockedDataProvider/MockedDataProvider.d.ts +28 -0
- package/dist/utils/MockedDataProvider/MockedDataProvider.js +26 -0
- package/dist/utils/MockedDataProvider/index.d.ts +1 -0
- package/dist/utils/StringUtils.d.ts +5 -0
- package/dist/utils/StringUtils.js +14 -0
- package/dist/utils/addTimestampToUrl.d.ts +6 -0
- package/dist/utils/addTimestampToUrl.js +7 -0
- package/dist/utils/blob.d.ts +9 -0
- package/dist/utils/blob.js +15 -0
- package/dist/utils/checkUserRight.d.ts +11 -0
- package/dist/utils/checkUserRight.js +44 -0
- package/dist/utils/fileSize.d.ts +1 -0
- package/dist/utils/fileSize.js +8 -0
- package/dist/utils/findTreeNode.d.ts +9 -0
- package/dist/utils/findTreeNode.js +11 -0
- package/dist/utils/index.d.ts +14 -0
- package/dist/utils/isActionAvailable.d.ts +2 -0
- package/dist/utils/isActionAvailable.js +7 -0
- package/dist/utils/libraryMaps.d.ts +4 -0
- package/dist/utils/libraryMaps.js +12 -0
- package/dist/utils/noop.d.ts +4 -0
- package/dist/utils/noop.js +5 -0
- package/dist/utils/ref.d.ts +5 -0
- package/dist/utils/ref.js +14 -0
- package/dist/utils/thumbnail.d.ts +8 -0
- package/dist/utils/thumbnail.js +6 -0
- package/dist/utils/time.d.ts +2 -0
- package/dist/utils/time.js +11 -0
- package/dist/utils/treeview.d.ts +33 -0
- package/dist/utils/treeview.js +133 -0
- package/dist/utils/video.d.ts +1 -0
- package/dist/utils/video.js +4 -0
- package/dist/widgets/BookmarkedApps/BookmarkedApps.d.ts +8 -0
- package/dist/widgets/BookmarkedApps/BookmarkedApps.js +8 -0
- package/dist/widgets/BookmarkedApps/index.d.ts +2 -0
- package/dist/widgets/Widget/Widget.d.ts +17 -0
- package/dist/widgets/Widget/Widget.js +22 -0
- package/dist/widgets/Widget/index.d.ts +2 -0
- package/dist/widgets/index.d.ts +2 -0
- package/package.json +134 -0
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { ReactionType } from 'edifice-ts-client';
|
|
2
|
+
/**
|
|
3
|
+
* This hook implements some logic and provides functions to easily call "audience" backend endpoints.
|
|
4
|
+
* @param module application code, e.g. "blog"
|
|
5
|
+
* @param resourceType type of resource, e.g. "post"
|
|
6
|
+
* @returns functions to easily call "audience" backend endpoints
|
|
7
|
+
*/
|
|
8
|
+
export default function useReactions(module: string, resourceType: string): {
|
|
9
|
+
availableReactions: ("REACTION_1" | "REACTION_2" | "REACTION_3" | "REACTION_4")[];
|
|
10
|
+
loadReactionDetails: (resourceId: string, page: number, size?: number) => Promise<import('edifice-ts-client').ReactionDetailsData | undefined>;
|
|
11
|
+
loadReactionSummaries: (resourceIds: string[]) => Promise<{
|
|
12
|
+
[resourceId: string]: import('edifice-ts-client').ReactionSummaryData | undefined;
|
|
13
|
+
}>;
|
|
14
|
+
applyReaction: (resourceId: string, newReaction: ReactionType, oldReaction: ReactionType | null) => Promise<"-" | "+" | "=">;
|
|
15
|
+
};
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { useRef, useState, useCallback, useEffect } from "react";
|
|
2
|
+
import { odeServices, ERROR_CODE } from "edifice-ts-client";
|
|
3
|
+
function useReactions(module, resourceType) {
|
|
4
|
+
const {
|
|
5
|
+
reactions
|
|
6
|
+
} = useRef(odeServices.audience(module, resourceType)).current, [availableReactions, setAvailableReactions] = useState([]);
|
|
7
|
+
async function loadAvailableReactions() {
|
|
8
|
+
const results = await reactions.loadAvailableReactions();
|
|
9
|
+
results && setAvailableReactions(results);
|
|
10
|
+
}
|
|
11
|
+
async function loadReactionSummaries(resourceIds) {
|
|
12
|
+
return await reactions.loadReactionSummaries(resourceIds);
|
|
13
|
+
}
|
|
14
|
+
const loadReactionDetails = async (resourceId, page, size = 30) => await reactions.loadReactionDetails(resourceId, page, size), applyReaction = useCallback(
|
|
15
|
+
async (resourceId, newReaction, oldReaction) => {
|
|
16
|
+
if (newReaction !== oldReaction && availableReactions.indexOf(newReaction) < 0)
|
|
17
|
+
return Promise.reject(ERROR_CODE.MALFORMED_DATA);
|
|
18
|
+
let result = "+";
|
|
19
|
+
return oldReaction ? newReaction === oldReaction ? (await reactions.deleteReaction(resourceId), result = "-") : (await reactions.updateReaction(resourceId, newReaction), result = "=") : await reactions.createReaction(resourceId, newReaction), odeServices.http().isResponseError() ? Promise.reject(ERROR_CODE.UNKNOWN) : result;
|
|
20
|
+
},
|
|
21
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
22
|
+
[availableReactions]
|
|
23
|
+
);
|
|
24
|
+
return useEffect(() => {
|
|
25
|
+
loadAvailableReactions();
|
|
26
|
+
}, []), {
|
|
27
|
+
availableReactions,
|
|
28
|
+
loadReactionDetails,
|
|
29
|
+
loadReactionSummaries,
|
|
30
|
+
applyReaction
|
|
31
|
+
};
|
|
32
|
+
}
|
|
33
|
+
export {
|
|
34
|
+
useReactions as default
|
|
35
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This hook provides functions to easily call "audience" backend endpoints.
|
|
3
|
+
* @param module application code, e.g. "blog"
|
|
4
|
+
* @param resourceType type of resource, e.g. "post"
|
|
5
|
+
* @returns functions to easily call "audience" backend endpoints.
|
|
6
|
+
*/
|
|
7
|
+
export default function useViews(module: string, resourceType: string): {
|
|
8
|
+
getViewsCounter: (resourceIds: string[]) => Promise<import('edifice-ts-client').ViewsCounters>;
|
|
9
|
+
getViewsDetail: (resourceId: string) => Promise<import('edifice-ts-client').ViewsDetails | undefined>;
|
|
10
|
+
triggerView: (resourceId: string) => Promise<void>;
|
|
11
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export { default as ViewsCounter } from './ViewsCounter';
|
|
2
|
+
export * from './ViewsCounter';
|
|
3
|
+
export { default as ViewsModal } from './ViewsModal';
|
|
4
|
+
export * from './ViewsModal';
|
|
5
|
+
export { default as ReactionSummary } from './ReactionSummary';
|
|
6
|
+
export * from './ReactionSummary';
|
|
7
|
+
export { default as ReactionChoice } from './ReactionChoice';
|
|
8
|
+
export * from './ReactionChoice';
|
|
9
|
+
export { default as ReactionModal } from './ReactionModal';
|
|
10
|
+
export * from './ReactionModal';
|
|
11
|
+
export { default as useReactions } from './hooks/useReactions';
|
|
12
|
+
export { default as useReactionIcons } from './hooks/useReactionIcons';
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Editor } from '@tiptap/react';
|
|
2
|
+
declare const BubbleMenuEditImage: ({ editor, onEditImage, openEditImage, editable, }: {
|
|
3
|
+
editor: Editor;
|
|
4
|
+
onEditImage: () => void;
|
|
5
|
+
openEditImage: boolean;
|
|
6
|
+
editable: boolean;
|
|
7
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export default BubbleMenuEditImage;
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { useMemo } from "react";
|
|
3
|
+
import { BubbleMenu } from "@tiptap/react";
|
|
4
|
+
import { useTranslation } from "react-i18next";
|
|
5
|
+
import { Icon } from "../../../../components/Icon/Icon.js";
|
|
6
|
+
import Toolbar from "../../../../components/Toolbar/Toolbar.js";
|
|
7
|
+
const BubbleMenuEditImage = ({
|
|
8
|
+
editor,
|
|
9
|
+
onEditImage,
|
|
10
|
+
openEditImage,
|
|
11
|
+
editable
|
|
12
|
+
}) => {
|
|
13
|
+
const {
|
|
14
|
+
t
|
|
15
|
+
} = useTranslation(), {
|
|
16
|
+
selection
|
|
17
|
+
} = editor.view.state, selectedNode = editor.view.state.doc.nodeAt(selection.anchor), handleButtonClick = (buttonSize) => {
|
|
18
|
+
editor.chain().focus().setAttributes({
|
|
19
|
+
width: buttonSize.width,
|
|
20
|
+
height: buttonSize.height,
|
|
21
|
+
size: buttonSize.size
|
|
22
|
+
}).run();
|
|
23
|
+
}, ImageSizeItems = useMemo(() => {
|
|
24
|
+
var _a, _b, _c, _d, _e, _f;
|
|
25
|
+
return [{
|
|
26
|
+
type: "button",
|
|
27
|
+
name: "edit",
|
|
28
|
+
props: {
|
|
29
|
+
size: "lg",
|
|
30
|
+
color: "secondary",
|
|
31
|
+
leftIcon: /* @__PURE__ */ jsx(Icon, { name: "wand" }),
|
|
32
|
+
"aria-label": t("tiptap.tooltip.bubblemenu.image.edit"),
|
|
33
|
+
children: t("tiptap.bubblemenu.edit"),
|
|
34
|
+
onClick: onEditImage
|
|
35
|
+
},
|
|
36
|
+
tooltip: {
|
|
37
|
+
message: t("tiptap.tooltip.bubblemenu.image.edit"),
|
|
38
|
+
position: "top"
|
|
39
|
+
}
|
|
40
|
+
}, {
|
|
41
|
+
type: "divider",
|
|
42
|
+
name: "div-4"
|
|
43
|
+
}, {
|
|
44
|
+
type: "icon",
|
|
45
|
+
name: "small",
|
|
46
|
+
props: {
|
|
47
|
+
icon: /* @__PURE__ */ jsx(Icon, { name: "image-size-small" }),
|
|
48
|
+
"aria-label": t("tiptap.tooltip.bubblemenu.image.small"),
|
|
49
|
+
color: "tertiary",
|
|
50
|
+
className: ((_a = selectedNode == null ? void 0 : selectedNode.attrs) == null ? void 0 : _a.size) === "small" && ((_b = selectedNode == null ? void 0 : selectedNode.attrs) == null ? void 0 : _b.width) === 250 ? "is-selected" : "",
|
|
51
|
+
onClick: () => handleButtonClick({
|
|
52
|
+
size: "small",
|
|
53
|
+
width: 250,
|
|
54
|
+
height: "auto"
|
|
55
|
+
})
|
|
56
|
+
},
|
|
57
|
+
tooltip: {
|
|
58
|
+
message: t("tiptap.tooltip.bubblemenu.image.small"),
|
|
59
|
+
position: "top"
|
|
60
|
+
}
|
|
61
|
+
}, {
|
|
62
|
+
type: "icon",
|
|
63
|
+
name: "medium",
|
|
64
|
+
props: {
|
|
65
|
+
icon: /* @__PURE__ */ jsx(Icon, { name: "image-size-medium" }),
|
|
66
|
+
"aria-label": t("tiptap.tooltip.bubblemenu.image.medium"),
|
|
67
|
+
color: "tertiary",
|
|
68
|
+
className: ((_c = selectedNode == null ? void 0 : selectedNode.attrs) == null ? void 0 : _c.size) === "medium" && ((_d = selectedNode == null ? void 0 : selectedNode.attrs) == null ? void 0 : _d.width) === 350 ? "is-selected" : "",
|
|
69
|
+
onClick: () => handleButtonClick({
|
|
70
|
+
size: "medium",
|
|
71
|
+
width: 350,
|
|
72
|
+
height: "auto"
|
|
73
|
+
})
|
|
74
|
+
},
|
|
75
|
+
tooltip: {
|
|
76
|
+
message: t("tiptap.tooltip.bubblemenu.image.medium"),
|
|
77
|
+
position: "top"
|
|
78
|
+
}
|
|
79
|
+
}, {
|
|
80
|
+
type: "icon",
|
|
81
|
+
name: "large",
|
|
82
|
+
props: {
|
|
83
|
+
icon: /* @__PURE__ */ jsx(Icon, { name: "image-size-large" }),
|
|
84
|
+
"aria-label": t("tiptap.tooltip.bubblemenu.image.big"),
|
|
85
|
+
color: "tertiary",
|
|
86
|
+
className: ((_e = selectedNode == null ? void 0 : selectedNode.attrs) == null ? void 0 : _e.size) === "large" && ((_f = selectedNode == null ? void 0 : selectedNode.attrs) == null ? void 0 : _f.width) === 500 ? "is-selected" : "",
|
|
87
|
+
onClick: () => handleButtonClick({
|
|
88
|
+
size: "large",
|
|
89
|
+
width: 500,
|
|
90
|
+
height: "auto"
|
|
91
|
+
})
|
|
92
|
+
},
|
|
93
|
+
tooltip: {
|
|
94
|
+
message: t("tiptap.tooltip.bubblemenu.image.big"),
|
|
95
|
+
position: "top"
|
|
96
|
+
}
|
|
97
|
+
}];
|
|
98
|
+
}, [t, selectedNode]), tippyOptions = useMemo(() => {
|
|
99
|
+
function adjustRect(rect) {
|
|
100
|
+
let yOffset = 0;
|
|
101
|
+
if (window.visualViewport) {
|
|
102
|
+
const bottomScreen = window.innerHeight || document.documentElement.clientHeight;
|
|
103
|
+
rect.bottom >= bottomScreen && (yOffset += rect.bottom - bottomScreen - rect.height);
|
|
104
|
+
}
|
|
105
|
+
return new DOMRect(rect.x, rect.y - yOffset, rect.width, rect.height);
|
|
106
|
+
}
|
|
107
|
+
return {
|
|
108
|
+
placement: "bottom-start",
|
|
109
|
+
offset: [0, 0],
|
|
110
|
+
zIndex: 999,
|
|
111
|
+
duration: 100,
|
|
112
|
+
// Try to get the bounding rect of the table.
|
|
113
|
+
getReferenceClientRect: () => {
|
|
114
|
+
const parentDiv = editor != null && editor.isActive("custom-image") ? editor.state.selection.$anchor : null;
|
|
115
|
+
if (parentDiv) {
|
|
116
|
+
const parentDomNode = editor == null ? void 0 : editor.view.nodeDOM(parentDiv.pos);
|
|
117
|
+
if (parentDomNode) {
|
|
118
|
+
const childDomNode = parentDomNode.firstChild;
|
|
119
|
+
return adjustRect(childDomNode.getBoundingClientRect());
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
return new DOMRect(0, 0, 100, 100);
|
|
123
|
+
}
|
|
124
|
+
};
|
|
125
|
+
}, [editor]);
|
|
126
|
+
return /* @__PURE__ */ jsx(BubbleMenu, { className: openEditImage ? "d-none" : "", shouldShow: ({
|
|
127
|
+
editor: editor2
|
|
128
|
+
}) => editor2.isActive("custom-image") && !openEditImage, editor, tippyOptions, children: editable && /* @__PURE__ */ jsx(Toolbar, { className: "p-8", items: ImageSizeItems }) });
|
|
129
|
+
}, BubbleMenuEditImage$1 = BubbleMenuEditImage;
|
|
130
|
+
export {
|
|
131
|
+
BubbleMenuEditImage$1 as default
|
|
132
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as BubbleMenuEditImage } from './BubbleMenuEditImage';
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { Content, FocusPosition, JSONContent } from '@tiptap/react';
|
|
2
|
+
import { WorkspaceVisibility } from 'edifice-ts-client';
|
|
3
|
+
export interface EditorRef {
|
|
4
|
+
/** Get the current content. */
|
|
5
|
+
getContent: (as: 'html' | 'json' | 'plain') => undefined | string | JSONContent;
|
|
6
|
+
/** Get speech synthetisis current state */
|
|
7
|
+
isSpeeching: () => boolean;
|
|
8
|
+
/** [De]activate speech synthetisis */
|
|
9
|
+
toogleSpeechSynthetisis: () => boolean;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* Editor component properties
|
|
13
|
+
*/
|
|
14
|
+
export interface EditorProps {
|
|
15
|
+
/**
|
|
16
|
+
* (Optional) id of the HTML element.
|
|
17
|
+
* Useful with an external `<FormControl id=...><Label/>`.
|
|
18
|
+
*/
|
|
19
|
+
id?: string;
|
|
20
|
+
/** Rich content to render. */
|
|
21
|
+
content: Content;
|
|
22
|
+
/**
|
|
23
|
+
* Rendering mode : `edit` to allow content modifications, or `read` (default)
|
|
24
|
+
* Switching to `edit` mode will also render the toolbar
|
|
25
|
+
* (unless `toolbar` property is `none`).
|
|
26
|
+
*/
|
|
27
|
+
mode?: 'edit' | 'read';
|
|
28
|
+
/** Toolbar to display in `edit` mode. */
|
|
29
|
+
toolbar?: 'full' | 'none';
|
|
30
|
+
/** Display with or without a border */
|
|
31
|
+
variant?: 'outline' | 'ghost';
|
|
32
|
+
/** Set focus position to the editor */
|
|
33
|
+
focus?: FocusPosition;
|
|
34
|
+
/** Editor placeholder content */
|
|
35
|
+
placeholder?: string;
|
|
36
|
+
/** Visibility of the content created
|
|
37
|
+
* this will impact where the uploaded files will be upload and the availability of the public media files */
|
|
38
|
+
visibility?: WorkspaceVisibility;
|
|
39
|
+
/** Function to listen if content change */
|
|
40
|
+
onContentChange?: ({ editor }: {
|
|
41
|
+
editor: any;
|
|
42
|
+
}) => void;
|
|
43
|
+
}
|
|
44
|
+
declare const Editor: import('react').ForwardRefExoticComponent<EditorProps & import('react').RefAttributes<EditorRef>>;
|
|
45
|
+
export default Editor;
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef, useId, useImperativeHandle, Suspense, lazy } from "react";
|
|
3
|
+
import "@edifice.io/tiptap-extensions";
|
|
4
|
+
import { EditorContent } from "@tiptap/react";
|
|
5
|
+
import clsx from "clsx";
|
|
6
|
+
import { useMathsStyles } from "../../hooks/useMathsStyles.js";
|
|
7
|
+
import { useTipTapEditor } from "../../hooks/useTipTapEditor.js";
|
|
8
|
+
import { useMediaLibraryEditor } from "../../hooks/useMediaLibraryEditor.js";
|
|
9
|
+
import { useMathsModal } from "../../hooks/useMathsModal.js";
|
|
10
|
+
import { useImageModal } from "../../hooks/useImageModal.js";
|
|
11
|
+
import { useLinkToolbar } from "../../hooks/useLinkToolbar.js";
|
|
12
|
+
import { useSpeechSynthetisis } from "../../hooks/useSpeechSynthetisis.js";
|
|
13
|
+
import { EditorContext } from "../../hooks/useEditorContext.js";
|
|
14
|
+
import { EditorToolbar } from "../EditorToolbar/EditorToolbar.js";
|
|
15
|
+
import LinkToolbar from "../Toolbar/LinkToolbar.js";
|
|
16
|
+
import TableToolbar from "../Toolbar/TableToolbar.js";
|
|
17
|
+
import BubbleMenuEditImage from "../BubbleMenuEditImage/BubbleMenuEditImage.js";
|
|
18
|
+
import MediaLibrary from "../../../multimedia/MediaLibrary/MediaLibrary.js";
|
|
19
|
+
import { useOdeClient } from "../../../../core/OdeClientProvider/OdeClientProvider.js";
|
|
20
|
+
import LoadingScreen from "../../../../components/LoadingScreen/LoadingScreen.js";
|
|
21
|
+
const MathsModal = /* @__PURE__ */ lazy(async () => await import("./MathsModal.js")), ImageEditor = /* @__PURE__ */ lazy(async () => await import("../../../multimedia/ImageEditor/components/ImageEditor.js")), Editor = /* @__PURE__ */ forwardRef(({
|
|
22
|
+
id,
|
|
23
|
+
content,
|
|
24
|
+
mode = "read",
|
|
25
|
+
toolbar = "full",
|
|
26
|
+
variant = "outline",
|
|
27
|
+
focus = "start",
|
|
28
|
+
placeholder = "",
|
|
29
|
+
visibility = "protected",
|
|
30
|
+
onContentChange
|
|
31
|
+
}, ref) => {
|
|
32
|
+
const editorId = useId(), {
|
|
33
|
+
appCode
|
|
34
|
+
} = useOdeClient(), {
|
|
35
|
+
editor,
|
|
36
|
+
editable
|
|
37
|
+
} = useTipTapEditor(mode === "edit", content, focus, placeholder, onContentChange), {
|
|
38
|
+
ref: mediaLibraryModalRef,
|
|
39
|
+
...mediaLibraryModalHandlers
|
|
40
|
+
} = useMediaLibraryEditor(editor), {
|
|
41
|
+
toggle: toggleMathsModal,
|
|
42
|
+
...mathsModalHandlers
|
|
43
|
+
} = useMathsModal(editor), imageModal = useImageModal(editor, "media-library", visibility), linkToolbarHandlers = useLinkToolbar(editor, mediaLibraryModalRef), speechSynthetisis = useSpeechSynthetisis(editor);
|
|
44
|
+
if (useMathsStyles(), useImperativeHandle(ref, () => ({
|
|
45
|
+
getContent: (as) => {
|
|
46
|
+
switch (as) {
|
|
47
|
+
case "html":
|
|
48
|
+
return editor == null ? void 0 : editor.getHTML();
|
|
49
|
+
case "json":
|
|
50
|
+
return editor == null ? void 0 : editor.getJSON();
|
|
51
|
+
case "plain":
|
|
52
|
+
return editor == null ? void 0 : editor.getText();
|
|
53
|
+
default:
|
|
54
|
+
throw `[Editor] Unknown content format ${as}`;
|
|
55
|
+
}
|
|
56
|
+
},
|
|
57
|
+
toogleSpeechSynthetisis: speechSynthetisis.toggle,
|
|
58
|
+
isSpeeching: () => speechSynthetisis.isActivated
|
|
59
|
+
})), !editor) return null;
|
|
60
|
+
const borderClass = clsx(variant === "outline" && "border rounded-3"), contentClass = clsx(variant === "outline" && "py-12 px-16");
|
|
61
|
+
return /* @__PURE__ */ jsxs(EditorContext.Provider, { value: {
|
|
62
|
+
id: id ?? editorId,
|
|
63
|
+
appCode,
|
|
64
|
+
editor,
|
|
65
|
+
editable
|
|
66
|
+
}, children: [
|
|
67
|
+
/* @__PURE__ */ jsxs("div", { className: borderClass, children: [
|
|
68
|
+
toolbar !== "none" && editable && /* @__PURE__ */ jsx(EditorToolbar, { mediaLibraryRef: mediaLibraryModalRef, toggleMathsModal }),
|
|
69
|
+
/* @__PURE__ */ jsx(EditorContent, { id: id ?? editorId, editor, className: contentClass })
|
|
70
|
+
] }),
|
|
71
|
+
/* @__PURE__ */ jsx(LinkToolbar, { editor, ...linkToolbarHandlers }),
|
|
72
|
+
/* @__PURE__ */ jsx(TableToolbar, { editor }),
|
|
73
|
+
editor && /* @__PURE__ */ jsx(BubbleMenuEditImage, { editor, onEditImage: imageModal.handleEdit, openEditImage: imageModal.isOpen, editable }),
|
|
74
|
+
/* @__PURE__ */ jsxs(Suspense, { fallback: /* @__PURE__ */ jsx(LoadingScreen, {}), children: [
|
|
75
|
+
editable && /* @__PURE__ */ jsx(MediaLibrary, { appCode, visibility, multiple: !0, ref: mediaLibraryModalRef, ...mediaLibraryModalHandlers }),
|
|
76
|
+
editable && mathsModalHandlers.isOpen && /* @__PURE__ */ jsx(MathsModal, { ...mathsModalHandlers }),
|
|
77
|
+
editable && (imageModal == null ? void 0 : imageModal.isOpen) && (imageModal == null ? void 0 : imageModal.currentImage) && /* @__PURE__ */ jsx(ImageEditor, { altText: imageModal == null ? void 0 : imageModal.currentImage.alt, legend: imageModal == null ? void 0 : imageModal.currentImage.title, image: imageModal == null ? void 0 : imageModal.currentImage.src, isOpen: imageModal.isOpen, onCancel: imageModal.handleCancel, onSave: imageModal.handleSave, onError: console.error })
|
|
78
|
+
] })
|
|
79
|
+
] });
|
|
80
|
+
}), Editor$1 = Editor;
|
|
81
|
+
export {
|
|
82
|
+
Editor$1 as default
|
|
83
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
interface ModalProps {
|
|
3
|
+
isOpen: boolean;
|
|
4
|
+
onSuccess?: (formulaEditor: string) => void;
|
|
5
|
+
onCancel?: () => void;
|
|
6
|
+
}
|
|
7
|
+
declare const MathsModal: ({ isOpen, onSuccess, onCancel }: ModalProps) => import('react').ReactPortal;
|
|
8
|
+
export default MathsModal;
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
+
import { useState, useEffect } from "react";
|
|
3
|
+
import Mathematics from "@tiptap-pro/extension-mathematics";
|
|
4
|
+
import { useEditor, EditorContent } from "@tiptap/react";
|
|
5
|
+
import StarterKit from "@tiptap/starter-kit";
|
|
6
|
+
import { createPortal } from "react-dom";
|
|
7
|
+
import { useTranslation } from "react-i18next";
|
|
8
|
+
import Modal from "../../../../components/Modal/Modal.js";
|
|
9
|
+
import Button from "../../../../components/Button/Button.js";
|
|
10
|
+
const MathsModal = ({
|
|
11
|
+
isOpen,
|
|
12
|
+
onSuccess,
|
|
13
|
+
onCancel
|
|
14
|
+
}) => {
|
|
15
|
+
const FORMULA_PLACEHOLDER = "\\frac{-b + \\sqrt{b^2 - 4ac}}{2a}", [formulaEditor, setFormulaEditor] = useState(`$${FORMULA_PLACEHOLDER}$`), {
|
|
16
|
+
t
|
|
17
|
+
} = useTranslation(), editor = useEditor({
|
|
18
|
+
extensions: [StarterKit, Mathematics],
|
|
19
|
+
content: "",
|
|
20
|
+
editable: !1
|
|
21
|
+
});
|
|
22
|
+
useEffect(() => {
|
|
23
|
+
editor == null || editor.commands.setContent(formulaEditor), editor == null || editor.commands.enter();
|
|
24
|
+
}, [editor, formulaEditor]);
|
|
25
|
+
const handleChange = (event) => {
|
|
26
|
+
const newFormulaEditor = event.target.value.replaceAll(`
|
|
27
|
+
`, "$<br/>$");
|
|
28
|
+
newFormulaEditor ? (editor == null || editor.commands.setContent(`$${newFormulaEditor}$`), setFormulaEditor(`$${newFormulaEditor}$`)) : (editor == null || editor.commands.setContent(""), setFormulaEditor("")), editor == null || editor.commands.enter();
|
|
29
|
+
}, handleOnCancel = () => {
|
|
30
|
+
onCancel == null || onCancel();
|
|
31
|
+
};
|
|
32
|
+
return /* @__PURE__ */ createPortal(/* @__PURE__ */ jsxs(Modal, { id: "MathsModal", isOpen, onModalClose: handleOnCancel, children: [
|
|
33
|
+
/* @__PURE__ */ jsx(Modal.Header, { onModalClose: handleOnCancel, children: t("tiptap.maths.title") }),
|
|
34
|
+
/* @__PURE__ */ jsxs(Modal.Subtitle, { children: [
|
|
35
|
+
t("tiptap.maths.subtitle.1"),
|
|
36
|
+
/* @__PURE__ */ jsx("a", { href: t("https://fr.wikibooks.org/wiki/LaTeX/%C3%89crire_des_math%C3%A9matiques"), target: "_blank", children: t("tiptap.maths.subtitle.2") })
|
|
37
|
+
] }),
|
|
38
|
+
/* @__PURE__ */ jsxs(Modal.Body, { children: [
|
|
39
|
+
/* @__PURE__ */ jsx("textarea", { id: "formulaTextArea", name: "formula", rows: 4, cols: 50, onChange: handleChange, placeholder: `Exemple : ${FORMULA_PLACEHOLDER}`, className: "border rounded-3 w-100 px-16 py-12" }),
|
|
40
|
+
/* @__PURE__ */ jsx(EditorContent, { editor, className: "pt-24 pb-0 text-center fs-1" })
|
|
41
|
+
] }),
|
|
42
|
+
/* @__PURE__ */ jsxs(Modal.Footer, { children: [
|
|
43
|
+
/* @__PURE__ */ jsx(Button, { color: "tertiary", onClick: onCancel, type: "button", variant: "ghost", children: t("tiptap.maths.cancel") }),
|
|
44
|
+
/* @__PURE__ */ jsx(Button, { color: "primary", onClick: () => onSuccess == null ? void 0 : onSuccess(formulaEditor), type: "button", variant: "filled", children: t("tiptap.maths.add") })
|
|
45
|
+
] })
|
|
46
|
+
] }), document.getElementById("portal"));
|
|
47
|
+
};
|
|
48
|
+
export {
|
|
49
|
+
MathsModal as default
|
|
50
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { ReactNode, RefAttributes } from 'react';
|
|
2
|
+
import { DropdownMenuOptions, IconButtonProps } from '../../../..';
|
|
3
|
+
interface Props {
|
|
4
|
+
/**
|
|
5
|
+
* Props for the trigger
|
|
6
|
+
*/
|
|
7
|
+
triggerProps: JSX.IntrinsicAttributes & Omit<IconButtonProps, 'ref'> & RefAttributes<HTMLButtonElement>;
|
|
8
|
+
/**
|
|
9
|
+
* Menu icon
|
|
10
|
+
*/
|
|
11
|
+
icon: ReactNode;
|
|
12
|
+
/**
|
|
13
|
+
* Menu label (for accessibility)
|
|
14
|
+
*/
|
|
15
|
+
ariaLabel: string;
|
|
16
|
+
/**
|
|
17
|
+
* Options to display
|
|
18
|
+
*/
|
|
19
|
+
options: DropdownMenuOptions[];
|
|
20
|
+
}
|
|
21
|
+
export declare const EditorToolbarDropdownMenu: ({ triggerProps, icon, ariaLabel, options, }: Props) => import("react/jsx-runtime").JSX.Element;
|
|
22
|
+
export {};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { jsxs, Fragment, jsx } from "react/jsx-runtime";
|
|
2
|
+
import { Fragment as Fragment$1 } from "react";
|
|
3
|
+
import IconButton from "../../../../components/Button/IconButton.js";
|
|
4
|
+
import Tooltip from "../../../../components/Tooltip/Tooltip.js";
|
|
5
|
+
import Dropdown from "../../../../components/Dropdown/Dropdown.js";
|
|
6
|
+
const EditorToolbarDropdownMenu = ({
|
|
7
|
+
triggerProps,
|
|
8
|
+
icon,
|
|
9
|
+
ariaLabel,
|
|
10
|
+
options
|
|
11
|
+
}) => /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
12
|
+
/* @__PURE__ */ jsx(Tooltip, { message: ariaLabel, placement: "top", children: /* @__PURE__ */ jsx(IconButton, { ...triggerProps, type: "button", variant: "ghost", color: "tertiary", icon, "aria-label": ariaLabel }) }),
|
|
13
|
+
/* @__PURE__ */ jsx(Dropdown.Menu, { children: options.map((option, index) => /* @__PURE__ */ jsx(Fragment$1, { children: option.type === "divider" ? /* @__PURE__ */ jsx(Dropdown.Separator, {}) : /* @__PURE__ */ jsx(Dropdown.Item, { icon: option.icon, onClick: () => option.action(null), children: option.label }) }, index)) })
|
|
14
|
+
] });
|
|
15
|
+
export {
|
|
16
|
+
EditorToolbarDropdownMenu
|
|
17
|
+
};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { RefAttributes } from 'react';
|
|
2
|
+
import { IconButtonProps } from '../../../..';
|
|
3
|
+
interface Props {
|
|
4
|
+
/**
|
|
5
|
+
* Props for the trigger
|
|
6
|
+
*/
|
|
7
|
+
triggerProps: JSX.IntrinsicAttributes & Omit<IconButtonProps, 'ref'> & RefAttributes<HTMLButtonElement>;
|
|
8
|
+
/**
|
|
9
|
+
* Tracks refs on ColorPickers.
|
|
10
|
+
*/
|
|
11
|
+
itemRefs: any;
|
|
12
|
+
}
|
|
13
|
+
export declare const EditorToolbarEmoji: ({ triggerProps, itemRefs }: Props) => import("react/jsx-runtime").JSX.Element;
|
|
14
|
+
export {};
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { jsxs, Fragment, jsx } from "react/jsx-runtime";
|
|
2
|
+
import EmojiPicker, { Categories } from "emoji-picker-react";
|
|
3
|
+
import { useTranslation } from "react-i18next";
|
|
4
|
+
import { useEditorContext } from "../../hooks/useEditorContext.js";
|
|
5
|
+
import Tooltip from "../../../../components/Tooltip/Tooltip.js";
|
|
6
|
+
import IconButton from "../../../../components/Button/IconButton.js";
|
|
7
|
+
import { Icon } from "../../../../components/Icon/Icon.js";
|
|
8
|
+
import Dropdown from "../../../../components/Dropdown/Dropdown.js";
|
|
9
|
+
const EditorToolbarEmoji = ({
|
|
10
|
+
triggerProps,
|
|
11
|
+
itemRefs
|
|
12
|
+
}) => {
|
|
13
|
+
const {
|
|
14
|
+
t
|
|
15
|
+
} = useTranslation(), {
|
|
16
|
+
editor
|
|
17
|
+
} = useEditorContext();
|
|
18
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
19
|
+
/* @__PURE__ */ jsx(Tooltip, { message: t("tiptap.toolbar.emojisPicker"), placement: "top", children: /* @__PURE__ */ jsx(IconButton, { ...triggerProps, type: "button", variant: "ghost", color: "tertiary", icon: /* @__PURE__ */ jsx(Icon, { name: "smiley" }), "aria-label": t("tiptap.toolbar.emojisPicker") }) }),
|
|
20
|
+
/* @__PURE__ */ jsx(Dropdown.Menu, { children: /* @__PURE__ */ jsx("div", { ref: (el) => itemRefs.current["emoji-picker"] = el, children: /* @__PURE__ */ jsx(EmojiPicker, { height: 400, width: 316, onEmojiClick: (emoji) => editor == null ? void 0 : editor.commands.insertContentAt(editor.view.state.selection, emoji.emoji), previewConfig: {
|
|
21
|
+
showPreview: !1
|
|
22
|
+
}, searchDisabled: !0, categories: [{
|
|
23
|
+
category: Categories.SUGGESTED,
|
|
24
|
+
name: `${t("tiptap.toolbar.emojis.recentlyUsed")}`
|
|
25
|
+
}, {
|
|
26
|
+
category: Categories.SMILEYS_PEOPLE,
|
|
27
|
+
name: `${t("tiptap.toolbar.emojis.people")}`
|
|
28
|
+
}, {
|
|
29
|
+
category: Categories.ANIMALS_NATURE,
|
|
30
|
+
name: `${t("tiptap.toolbar.emojis.animalsNature")}`
|
|
31
|
+
}, {
|
|
32
|
+
category: Categories.FOOD_DRINK,
|
|
33
|
+
name: `${t("tiptap.toolbar.emojis.foodDrink")}`
|
|
34
|
+
}, {
|
|
35
|
+
category: Categories.TRAVEL_PLACES,
|
|
36
|
+
name: `${t("tiptap.toolbar.emojis.travelPlaces")}`
|
|
37
|
+
}, {
|
|
38
|
+
category: Categories.ACTIVITIES,
|
|
39
|
+
name: `${t("tiptap.toolbar.emojis.activities")}`
|
|
40
|
+
}, {
|
|
41
|
+
category: Categories.OBJECTS,
|
|
42
|
+
name: `${t("tiptap.toolbar.emojis.objects")}`
|
|
43
|
+
}, {
|
|
44
|
+
category: Categories.SYMBOLS,
|
|
45
|
+
name: `${t("tiptap.toolbar.emojis.symbols")}`
|
|
46
|
+
}, {
|
|
47
|
+
category: Categories.FLAGS,
|
|
48
|
+
name: `${t("tiptap.toolbar.emojis.flags")}`
|
|
49
|
+
}] }) }) })
|
|
50
|
+
] });
|
|
51
|
+
};
|
|
52
|
+
export {
|
|
53
|
+
EditorToolbarEmoji
|
|
54
|
+
};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { RefAttributes } from 'react';
|
|
2
|
+
import { IconButtonProps } from '../../../..';
|
|
3
|
+
interface Props {
|
|
4
|
+
/**
|
|
5
|
+
* Props for the trigger
|
|
6
|
+
*/
|
|
7
|
+
triggerProps: JSX.IntrinsicAttributes & Omit<IconButtonProps, 'ref'> & RefAttributes<HTMLButtonElement>;
|
|
8
|
+
/**
|
|
9
|
+
* Tracks refs on ColorPickers.
|
|
10
|
+
*/
|
|
11
|
+
itemRefs: any;
|
|
12
|
+
}
|
|
13
|
+
export declare const EditorToolbarHighlightColor: ({ triggerProps, itemRefs, }: Props) => import("react/jsx-runtime").JSX.Element;
|
|
14
|
+
export {};
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { jsxs, Fragment, jsx } from "react/jsx-runtime";
|
|
2
|
+
import { useState, useMemo, useCallback, useEffect } from "react";
|
|
3
|
+
import { useTranslation } from "react-i18next";
|
|
4
|
+
import { useEditorContext } from "../../hooks/useEditorContext.js";
|
|
5
|
+
import { DefaultPalette } from "../../../../components/ColorPicker/ColorPalette.js";
|
|
6
|
+
import ColorPicker from "../../../../components/ColorPicker/ColorPicker.js";
|
|
7
|
+
import Tooltip from "../../../../components/Tooltip/Tooltip.js";
|
|
8
|
+
import IconButton from "../../../../components/Button/IconButton.js";
|
|
9
|
+
import { Icon } from "../../../../components/Icon/Icon.js";
|
|
10
|
+
import Dropdown from "../../../../components/Dropdown/Dropdown.js";
|
|
11
|
+
const EditorToolbarHighlightColor = ({
|
|
12
|
+
triggerProps,
|
|
13
|
+
itemRefs
|
|
14
|
+
}) => {
|
|
15
|
+
const {
|
|
16
|
+
t
|
|
17
|
+
} = useTranslation(), {
|
|
18
|
+
editor
|
|
19
|
+
} = useEditorContext(), [color, setColor] = useState("#4A4A4A"), isActive = useMemo(
|
|
20
|
+
() => editor == null ? void 0 : editor.isActive("customHighlight", {
|
|
21
|
+
color: /^#([0-9a-f]{3}){1,2}$/i
|
|
22
|
+
}),
|
|
23
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
24
|
+
[editor, editor == null ? void 0 : editor.state]
|
|
25
|
+
), applyColor = useCallback((value) => {
|
|
26
|
+
value === color || value === "" ? (setColor(""), editor == null || editor.chain().focus().unsetHighlight().run()) : (setColor(value), editor == null || editor.chain().focus().setHighlight({
|
|
27
|
+
color: value
|
|
28
|
+
}).run());
|
|
29
|
+
}, [color, editor]);
|
|
30
|
+
useEffect(() => {
|
|
31
|
+
setColor((editor == null ? void 0 : editor.getAttributes("customHighlight").color) ?? "");
|
|
32
|
+
}, [editor, editor == null ? void 0 : editor.state]);
|
|
33
|
+
const palettes = [{
|
|
34
|
+
...DefaultPalette,
|
|
35
|
+
reset: {
|
|
36
|
+
value: "transparent",
|
|
37
|
+
description: t("tiptap.toolbar.highlight.none")
|
|
38
|
+
}
|
|
39
|
+
}];
|
|
40
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
41
|
+
/* @__PURE__ */ jsx(Tooltip, { message: t("tiptap.toolbar.highlight.back"), placement: "top", children: /* @__PURE__ */ jsx(IconButton, { ...triggerProps, type: "button", variant: "ghost", color: "tertiary", icon: /* @__PURE__ */ jsx(Icon, { name: "text-highlight" }), "aria-label": t("tiptap.toolbar.highlight.back"), className: isActive ? "selected" : "" }) }),
|
|
42
|
+
/* @__PURE__ */ jsx(Dropdown.Menu, { children: /* @__PURE__ */ jsx(ColorPicker, { ref: (el) => itemRefs.current["color-picker"] = el, palettes, model: color, onSuccess: (item) => applyColor(item.value) }) })
|
|
43
|
+
] });
|
|
44
|
+
};
|
|
45
|
+
export {
|
|
46
|
+
EditorToolbarHighlightColor
|
|
47
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { DropdownMenuOptions } from '../../../..';
|
|
2
|
+
interface Props {
|
|
3
|
+
/**
|
|
4
|
+
* Options to display
|
|
5
|
+
*/
|
|
6
|
+
options: DropdownMenuOptions[];
|
|
7
|
+
}
|
|
8
|
+
export declare const EditorToolbarPlusMenu: ({ options }: Props) => import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { jsxs, Fragment, jsx } from "react/jsx-runtime";
|
|
2
|
+
import { Fragment as Fragment$1 } from "react";
|
|
3
|
+
import { useTranslation } from "react-i18next";
|
|
4
|
+
import Dropdown from "../../../../components/Dropdown/Dropdown.js";
|
|
5
|
+
const EditorToolbarPlusMenu = ({
|
|
6
|
+
options
|
|
7
|
+
}) => {
|
|
8
|
+
const {
|
|
9
|
+
t
|
|
10
|
+
} = useTranslation();
|
|
11
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
12
|
+
/* @__PURE__ */ jsx(Dropdown.Trigger, { variant: "ghost", label: t("tiptap.toolbar.plus"), size: "md", tabIndex: -1 }),
|
|
13
|
+
/* @__PURE__ */ jsx(Dropdown.Menu, { children: options.map((option, index) => /* @__PURE__ */ jsx(Fragment$1, { children: option.type === "divider" ? /* @__PURE__ */ jsx(Dropdown.Separator, {}) : /* @__PURE__ */ jsx(Dropdown.Item, { icon: option.icon, onClick: () => option.action(null), children: option.label }) }, index)) })
|
|
14
|
+
] });
|
|
15
|
+
};
|
|
16
|
+
export {
|
|
17
|
+
EditorToolbarPlusMenu
|
|
18
|
+
};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { RefAttributes } from 'react';
|
|
2
|
+
import { IconButtonProps } from '../../../..';
|
|
3
|
+
interface Props {
|
|
4
|
+
/**
|
|
5
|
+
* Props for the trigger
|
|
6
|
+
*/
|
|
7
|
+
triggerProps: JSX.IntrinsicAttributes & Omit<IconButtonProps, 'ref'> & RefAttributes<HTMLButtonElement>;
|
|
8
|
+
/**
|
|
9
|
+
* Tracks refs on ColorPickers.
|
|
10
|
+
*/
|
|
11
|
+
itemRefs: any;
|
|
12
|
+
}
|
|
13
|
+
export declare const EditorToolbarTextColor: ({ triggerProps, itemRefs }: Props) => import("react/jsx-runtime").JSX.Element;
|
|
14
|
+
export {};
|