@edifice.io/react 2.0.0-develop-rc.4 → 2.0.0-develop-rc.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +17 -88
- package/dist/audience.js +15 -14
- package/dist/audience.js.map +1 -0
- package/dist/components/ActionBar/ActionBar.js +8 -7
- package/dist/components/ActionBar/ActionBar.js.map +1 -0
- package/dist/components/Alert/Alert.js +62 -61
- package/dist/components/Alert/Alert.js.map +1 -0
- package/dist/components/AppHeader/AppHeader.js +19 -18
- package/dist/components/AppHeader/AppHeader.js.map +1 -0
- package/dist/components/AppIcon/AppIcon.d.ts +1 -1
- package/dist/components/AppIcon/AppIcon.js +45 -44
- package/dist/components/AppIcon/AppIcon.js.map +1 -0
- package/dist/components/Attachment/Attachment.js +14 -13
- package/dist/components/Attachment/Attachment.js.map +1 -0
- package/dist/components/Avatar/Avatar.js +28 -27
- package/dist/components/Avatar/Avatar.js.map +1 -0
- package/dist/components/Badge/Badge.js +21 -20
- package/dist/components/Badge/Badge.js.map +1 -0
- package/dist/components/Breadcrumb/Breadcrumb.d.ts +1 -1
- package/dist/components/Breadcrumb/Breadcrumb.js +24 -23
- package/dist/components/Breadcrumb/Breadcrumb.js.map +1 -0
- package/dist/components/Breadcrumb/BreadcrumbItem.js +12 -11
- package/dist/components/Breadcrumb/BreadcrumbItem.js.map +1 -0
- package/dist/components/Breadcrumb/BreadcrumbList.js +11 -10
- package/dist/components/Breadcrumb/BreadcrumbList.js.map +1 -0
- package/dist/components/Breadcrumb/BreadcrumbNav.d.ts +1 -1
- package/dist/components/Breadcrumb/BreadcrumbNav.js +16 -15
- package/dist/components/Breadcrumb/BreadcrumbNav.js.map +1 -0
- package/dist/components/Button/Button.js +33 -32
- package/dist/components/Button/Button.js.map +1 -0
- package/dist/components/Button/IconButton.js +16 -15
- package/dist/components/Button/IconButton.js.map +1 -0
- package/dist/components/Button/SearchButton.js +16 -15
- package/dist/components/Button/SearchButton.js.map +1 -0
- package/dist/components/Card/Card.d.ts +1 -1
- package/dist/components/Card/Card.js +48 -47
- package/dist/components/Card/Card.js.map +1 -0
- package/dist/components/Card/CardBody.js +14 -13
- package/dist/components/Card/CardBody.js.map +1 -0
- package/dist/components/Card/CardContext.d.ts +1 -1
- package/dist/components/Card/CardContext.js +8 -7
- package/dist/components/Card/CardContext.js.map +1 -0
- package/dist/components/Card/CardFooter.js +6 -5
- package/dist/components/Card/CardFooter.js.map +1 -0
- package/dist/components/Card/CardHeader.js +15 -14
- package/dist/components/Card/CardHeader.js.map +1 -0
- package/dist/components/Card/CardImage.js +14 -13
- package/dist/components/Card/CardImage.js.map +1 -0
- package/dist/components/Card/CardText.js +9 -8
- package/dist/components/Card/CardText.js.map +1 -0
- package/dist/components/Card/CardTitle.js +9 -8
- package/dist/components/Card/CardTitle.js.map +1 -0
- package/dist/components/Card/CardUser.js +9 -8
- package/dist/components/Card/CardUser.js.map +1 -0
- package/dist/components/Checkbox/Checkbox.js +31 -30
- package/dist/components/Checkbox/Checkbox.js.map +1 -0
- package/dist/components/ColorPicker/ColorPalette.js +5 -4
- package/dist/components/ColorPicker/ColorPalette.js.map +1 -0
- package/dist/components/ColorPicker/ColorPicker.js +29 -28
- package/dist/components/ColorPicker/ColorPicker.js.map +1 -0
- package/dist/components/ColorPicker/ColorPickerItem.js +12 -11
- package/dist/components/ColorPicker/ColorPickerItem.js.map +1 -0
- package/dist/components/Combobox/Combobox.js +36 -35
- package/dist/components/Combobox/Combobox.js.map +1 -0
- package/dist/components/Combobox/ComboboxTrigger.js +22 -21
- package/dist/components/Combobox/ComboboxTrigger.js.map +1 -0
- package/dist/components/Dropdown/Dropdown.js +56 -55
- package/dist/components/Dropdown/Dropdown.js.map +1 -0
- package/dist/components/Dropdown/DropdownCheckboxItem.js +27 -26
- package/dist/components/Dropdown/DropdownCheckboxItem.js.map +1 -0
- package/dist/components/Dropdown/DropdownContext.js +8 -7
- package/dist/components/Dropdown/DropdownContext.js.map +1 -0
- package/dist/components/Dropdown/DropdownItem.js +28 -27
- package/dist/components/Dropdown/DropdownItem.js.map +1 -0
- package/dist/components/Dropdown/DropdownMenu.js +22 -21
- package/dist/components/Dropdown/DropdownMenu.js.map +1 -0
- package/dist/components/Dropdown/DropdownMenuGroup.js +10 -9
- package/dist/components/Dropdown/DropdownMenuGroup.js.map +1 -0
- package/dist/components/Dropdown/DropdownRadioItem.js +27 -26
- package/dist/components/Dropdown/DropdownRadioItem.js.map +1 -0
- package/dist/components/Dropdown/DropdownSeparator.js +4 -3
- package/dist/components/Dropdown/DropdownSeparator.js.map +1 -0
- package/dist/components/Dropdown/DropdownTrigger.js +29 -28
- package/dist/components/Dropdown/DropdownTrigger.js.map +1 -0
- package/dist/components/Dropzone/Dropzone.js +48 -47
- package/dist/components/Dropzone/Dropzone.js.map +1 -0
- package/dist/components/Dropzone/DropzoneContext.js +9 -8
- package/dist/components/Dropzone/DropzoneContext.js.map +1 -0
- package/dist/components/Dropzone/DropzoneDrag.js +8 -7
- package/dist/components/Dropzone/DropzoneDrag.js.map +1 -0
- package/dist/components/Dropzone/DropzoneFile.js +26 -25
- package/dist/components/Dropzone/DropzoneFile.js.map +1 -0
- package/dist/components/Dropzone/DropzoneImport.js +21 -20
- package/dist/components/Dropzone/DropzoneImport.js.map +1 -0
- package/dist/components/EmptyScreen/EmptyScreen.js +17 -16
- package/dist/components/EmptyScreen/EmptyScreen.js.map +1 -0
- package/dist/components/FileCard/FileCard.d.ts +1 -1
- package/dist/components/FileCard/FileCard.js +38 -37
- package/dist/components/FileCard/FileCard.js.map +1 -0
- package/dist/components/FileCard/FileIcon.d.ts +1 -1
- package/dist/components/FileCard/FileIcon.js +12 -11
- package/dist/components/FileCard/FileIcon.js.map +1 -0
- package/dist/components/Form/FormContext.js +8 -7
- package/dist/components/Form/FormContext.js.map +1 -0
- package/dist/components/Form/FormControl.js +31 -30
- package/dist/components/Form/FormControl.js.map +1 -0
- package/dist/components/Form/FormText.js +13 -12
- package/dist/components/Form/FormText.js.map +1 -0
- package/dist/components/Grid/Grid.js +28 -27
- package/dist/components/Grid/Grid.js.map +1 -0
- package/dist/components/Heading/Heading.js +15 -14
- package/dist/components/Heading/Heading.js.map +1 -0
- package/dist/components/Icon/Icon.js +9 -8
- package/dist/components/Icon/Icon.js.map +1 -0
- package/dist/components/Image/Image.js +40 -39
- package/dist/components/Image/Image.js.map +1 -0
- package/dist/components/ImagePicker/ImagePicker.d.ts +1 -1
- package/dist/components/ImagePicker/ImagePicker.js +52 -51
- package/dist/components/ImagePicker/ImagePicker.js.map +1 -0
- package/dist/components/Input/Input.js +29 -28
- package/dist/components/Input/Input.js.map +1 -0
- package/dist/components/Label/Label.js +31 -30
- package/dist/components/Label/Label.js.map +1 -0
- package/dist/components/Loading/Loading.js +24 -23
- package/dist/components/Loading/Loading.js.map +1 -0
- package/dist/components/LoadingScreen/LoadingScreen.js +21 -20
- package/dist/components/LoadingScreen/LoadingScreen.js.map +1 -0
- package/dist/components/Logo/Logo.js +13 -12
- package/dist/components/Logo/Logo.js.map +1 -0
- package/dist/components/Menu/Menu.js +40 -39
- package/dist/components/Menu/Menu.js.map +1 -0
- package/dist/components/Menu/MenuButton.js +18 -17
- package/dist/components/Menu/MenuButton.js.map +1 -0
- package/dist/components/Menu/MenuContext.js +9 -8
- package/dist/components/Menu/MenuContext.js.map +1 -0
- package/dist/components/Menu/MenuItem.js +15 -14
- package/dist/components/Menu/MenuItem.js.map +1 -0
- package/dist/components/Modal/Modal.js +50 -49
- package/dist/components/Modal/Modal.js.map +1 -0
- package/dist/components/Modal/ModalBody.js +12 -11
- package/dist/components/Modal/ModalBody.js.map +1 -0
- package/dist/components/Modal/ModalContext.js +9 -8
- package/dist/components/Modal/ModalContext.js.map +1 -0
- package/dist/components/Modal/ModalFooter.js +4 -3
- package/dist/components/Modal/ModalFooter.js.map +1 -0
- package/dist/components/Modal/ModalHeader.js +23 -22
- package/dist/components/Modal/ModalHeader.js.map +1 -0
- package/dist/components/Modal/ModalSubtitle.js +4 -3
- package/dist/components/Modal/ModalSubtitle.js.map +1 -0
- package/dist/components/Popover/Popover.js +34 -33
- package/dist/components/Popover/Popover.js.map +1 -0
- package/dist/components/Radio/Radio.js +27 -26
- package/dist/components/Radio/Radio.js.map +1 -0
- package/dist/components/SearchBar/SearchBar.js +30 -29
- package/dist/components/SearchBar/SearchBar.js.map +1 -0
- package/dist/components/Select/Select.js +32 -31
- package/dist/components/Select/Select.js.map +1 -0
- package/dist/components/Select/SelectTrigger.js +5 -4
- package/dist/components/Select/SelectTrigger.js.map +1 -0
- package/dist/components/Table/TableExplorer.js +8 -7
- package/dist/components/Table/TableExplorer.js.map +1 -0
- package/dist/components/Tabs/Tabs.js +59 -58
- package/dist/components/Tabs/Tabs.js.map +1 -0
- package/dist/components/Tabs/TabsContext.js +9 -8
- package/dist/components/Tabs/TabsContext.js.map +1 -0
- package/dist/components/Tabs/TabsItem.js +21 -20
- package/dist/components/Tabs/TabsItem.js.map +1 -0
- package/dist/components/Tabs/TabsList.js +19 -18
- package/dist/components/Tabs/TabsList.js.map +1 -0
- package/dist/components/Tabs/TabsPanel.js +10 -9
- package/dist/components/Tabs/TabsPanel.js.map +1 -0
- package/dist/components/TextArea/TextArea.js +32 -31
- package/dist/components/TextArea/TextArea.js.map +1 -0
- package/dist/components/TextArea/TextareaCounter.js +7 -6
- package/dist/components/TextArea/TextareaCounter.js.map +1 -0
- package/dist/components/Toolbar/Toolbar.js +61 -60
- package/dist/components/Toolbar/Toolbar.js.map +1 -0
- package/dist/components/Tooltip/Tooltip.js +29 -28
- package/dist/components/Tooltip/Tooltip.js.map +1 -0
- package/dist/components/TreeView/TreeItem.js +47 -46
- package/dist/components/TreeView/TreeItem.js.map +1 -0
- package/dist/components/TreeView/TreeView.js +34 -33
- package/dist/components/TreeView/TreeView.js.map +1 -0
- package/dist/components/TreeView/hooks/useTreeItemEvents.js +19 -18
- package/dist/components/TreeView/hooks/useTreeItemEvents.js.map +1 -0
- package/dist/components/UploadCard/UploadCard.js +53 -52
- package/dist/components/UploadCard/UploadCard.js.map +1 -0
- package/dist/components/VisuallyHidden/VisuallyHidden.js +8 -7
- package/dist/components/VisuallyHidden/VisuallyHidden.js.map +1 -0
- package/dist/core/OdeClientProvider/OdeClientProvider.d.ts +1 -1
- package/dist/core/OdeClientProvider/OdeClientProvider.js +45 -44
- package/dist/core/OdeClientProvider/OdeClientProvider.js.map +1 -0
- package/dist/core/ThemeProvider/ThemeProvider.d.ts +1 -1
- package/dist/core/ThemeProvider/ThemeProvider.js +36 -35
- package/dist/core/ThemeProvider/ThemeProvider.js.map +1 -0
- package/dist/core/useAvatar/useAvatar.d.ts +1 -1
- package/dist/core/useAvatar/useAvatar.js +22 -21
- package/dist/core/useAvatar/useAvatar.js.map +1 -0
- package/dist/core/useBookmark/useBookmark.d.ts +1 -1
- package/dist/core/useBookmark/useBookmark.js +10 -9
- package/dist/core/useBookmark/useBookmark.js.map +1 -0
- package/dist/core/useConf/useConf.d.ts +1 -1
- package/dist/core/useConf/useConf.js +8 -7
- package/dist/core/useConf/useConf.js.map +1 -0
- package/dist/core/useConversation/useConversation.js +30 -29
- package/dist/core/useConversation/useConversation.js.map +1 -0
- package/dist/core/useCookiesConsent/useCookiesConsent.js +17 -16
- package/dist/core/useCookiesConsent/useCookiesConsent.js.map +1 -0
- package/dist/core/useDate/useDate.js +36 -35
- package/dist/core/useDate/useDate.js.map +1 -0
- package/dist/core/useHasWorkflow/useHasWorkflow.js +16 -15
- package/dist/core/useHasWorkflow/useHasWorkflow.js.map +1 -0
- package/dist/core/useHeader/useHeader.d.ts +1 -1
- package/dist/core/useHeader/useHeader.js +42 -41
- package/dist/core/useHeader/useHeader.js.map +1 -0
- package/dist/core/useHttpErrorToast/useHttpErrorToast.js +18 -17
- package/dist/core/useHttpErrorToast/useHttpErrorToast.js.map +1 -0
- package/dist/core/useIsAdml/useIsAdml.js +12 -11
- package/dist/core/useIsAdml/useIsAdml.js.map +1 -0
- package/dist/core/useLibraryUrl/useLibraryUrl.js +17 -16
- package/dist/core/useLibraryUrl/useLibraryUrl.js.map +1 -0
- package/dist/core/useMediaLibrary/useMediaLibrary.d.ts +1 -1
- package/dist/core/useMediaLibrary/useMediaLibrary.js +33 -32
- package/dist/core/useMediaLibrary/useMediaLibrary.js.map +1 -0
- package/dist/core/useOdeIcons/useOdeIcons.d.ts +1 -1
- package/dist/core/useOdeIcons/useOdeIcons.js +38 -37
- package/dist/core/useOdeIcons/useOdeIcons.js.map +1 -0
- package/dist/core/usePaths/usePaths.js +3 -2
- package/dist/core/usePaths/usePaths.js.map +1 -0
- package/dist/core/usePreferences/usePreferences.js +6 -5
- package/dist/core/usePreferences/usePreferences.js.map +1 -0
- package/dist/core/useResource/useResource.d.ts +1 -1
- package/dist/core/useResource/useResource.js +15 -14
- package/dist/core/useResource/useResource.js.map +1 -0
- package/dist/core/useResourceSearch/useResourceSearch.d.ts +1 -1
- package/dist/core/useResourceSearch/useResourceSearch.js +23 -22
- package/dist/core/useResourceSearch/useResourceSearch.js.map +1 -0
- package/dist/core/useSession/useSession.js +7 -6
- package/dist/core/useSession/useSession.js.map +1 -0
- package/dist/core/useTrashedResource/useTrashedResource.js +19 -18
- package/dist/core/useTrashedResource/useTrashedResource.js.map +1 -0
- package/dist/core/useUpload/useUpload.d.ts +1 -1
- package/dist/core/useUpload/useUpload.js +69 -68
- package/dist/core/useUpload/useUpload.js.map +1 -0
- package/dist/core/useUploadFiles/useUploadFiles.d.ts +1 -1
- package/dist/core/useUploadFiles/useUploadFiles.js +83 -82
- package/dist/core/useUploadFiles/useUploadFiles.js.map +1 -0
- package/dist/core/useUser/useUser.d.ts +1 -1
- package/dist/core/useUser/useUser.js +16 -15
- package/dist/core/useUser/useUser.js.map +1 -0
- package/dist/core/useWorkspaceFile/useWorkspaceFile.d.ts +1 -1
- package/dist/core/useWorkspaceFile/useWorkspaceFile.js +32 -31
- package/dist/core/useWorkspaceFile/useWorkspaceFile.js.map +1 -0
- package/dist/core/useWorkspaceSearch/useWorkspaceSearch.d.ts +1 -1
- package/dist/core/useWorkspaceSearch/useWorkspaceSearch.js +42 -41
- package/dist/core/useWorkspaceSearch/useWorkspaceSearch.js.map +1 -0
- package/dist/core/useXitiTrackPageLoad/useXitiTrackPageLoad.js +18 -17
- package/dist/core/useXitiTrackPageLoad/useXitiTrackPageLoad.js.map +1 -0
- package/dist/core/useZendeskGuide/useZendeskGuide.js +47 -46
- package/dist/core/useZendeskGuide/useZendeskGuide.js.map +1 -0
- package/dist/editor.js +57 -56
- package/dist/editor.js.map +1 -0
- package/dist/hooks/useBrowserInfo/useBrowserInfo.js +12 -11
- package/dist/hooks/useBrowserInfo/useBrowserInfo.js.map +1 -0
- package/dist/hooks/useClickOutside/useClickOutside.js +19 -18
- package/dist/hooks/useClickOutside/useClickOutside.js.map +1 -0
- package/dist/hooks/useDebounce/useDebounce.js +11 -10
- package/dist/hooks/useDebounce/useDebounce.js.map +1 -0
- package/dist/hooks/useDropdown/useDropdown.d.ts +1 -1
- package/dist/hooks/useDropdown/useDropdown.js +97 -96
- package/dist/hooks/useDropdown/useDropdown.js.map +1 -0
- package/dist/hooks/useDropzone/useDropzone.js +54 -53
- package/dist/hooks/useDropzone/useDropzone.js.map +1 -0
- package/dist/hooks/useHover/useHover.js +15 -14
- package/dist/hooks/useHover/useHover.js.map +1 -0
- package/dist/hooks/useImage/useImage.js +14 -13
- package/dist/hooks/useImage/useImage.js.map +1 -0
- package/dist/hooks/useImageResizer/useImageResizer.js +32 -31
- package/dist/hooks/useImageResizer/useImageResizer.js.map +1 -0
- package/dist/hooks/useKeyPress/useKeyPress.js +11 -10
- package/dist/hooks/useKeyPress/useKeyPress.js.map +1 -0
- package/dist/hooks/useScrollToTop/useScrollToTop.js +5 -4
- package/dist/hooks/useScrollToTop/useScrollToTop.js.map +1 -0
- package/dist/hooks/useThumbnail/useThumbnail.js +22 -21
- package/dist/hooks/useThumbnail/useThumbnail.js.map +1 -0
- package/dist/hooks/useTitle/useTitle.js +8 -7
- package/dist/hooks/useTitle/useTitle.js.map +1 -0
- package/dist/hooks/useToast/useToast.js +26 -25
- package/dist/hooks/useToast/useToast.js.map +1 -0
- package/dist/hooks/useToggle/useToggle.js +7 -6
- package/dist/hooks/useToggle/useToggle.js.map +1 -0
- package/dist/hooks/useTrapFocus/useTrapFocus.js +12 -11
- package/dist/hooks/useTrapFocus/useTrapFocus.js.map +1 -0
- package/dist/index.js +226 -225
- package/dist/index.js.map +1 -0
- package/dist/modals.js +15 -14
- package/dist/modals.js.map +1 -0
- package/dist/modules/audience/ReactionChoice.d.ts +1 -1
- package/dist/modules/audience/ReactionChoice.js +25 -24
- package/dist/modules/audience/ReactionChoice.js.map +1 -0
- package/dist/modules/audience/ReactionModal.Card.d.ts +1 -1
- package/dist/modules/audience/ReactionModal.Card.js +26 -25
- package/dist/modules/audience/ReactionModal.Card.js.map +1 -0
- package/dist/modules/audience/ReactionModal.d.ts +1 -1
- package/dist/modules/audience/ReactionModal.js +59 -59
- package/dist/modules/audience/ReactionModal.js.map +1 -0
- package/dist/modules/audience/ReactionSummary.d.ts +1 -1
- package/dist/modules/audience/ReactionSummary.js +20 -19
- package/dist/modules/audience/ReactionSummary.js.map +1 -0
- package/dist/modules/audience/ViewsByProfileCard.d.ts +1 -1
- package/dist/modules/audience/ViewsByProfileCard.js +23 -22
- package/dist/modules/audience/ViewsByProfileCard.js.map +1 -0
- package/dist/modules/audience/ViewsCounter.js +15 -14
- package/dist/modules/audience/ViewsCounter.js.map +1 -0
- package/dist/modules/audience/ViewsModal.d.ts +1 -1
- package/dist/modules/audience/ViewsModal.js +33 -32
- package/dist/modules/audience/ViewsModal.js.map +1 -0
- package/dist/modules/audience/hooks/useReactionIcons.d.ts +1 -1
- package/dist/modules/audience/hooks/useReactionIcons.js +14 -13
- package/dist/modules/audience/hooks/useReactionIcons.js.map +1 -0
- package/dist/modules/audience/hooks/useReactions.d.ts +3 -3
- package/dist/modules/audience/hooks/useReactions.js +25 -24
- package/dist/modules/audience/hooks/useReactions.js.map +1 -0
- package/dist/modules/audience/hooks/useViews.d.ts +2 -2
- package/dist/modules/editor/components/BubbleMenuEditImage/BubbleMenuEditImage.js +60 -59
- package/dist/modules/editor/components/BubbleMenuEditImage/BubbleMenuEditImage.js.map +1 -0
- package/dist/modules/editor/components/Editor/Editor.d.ts +1 -1
- package/dist/modules/editor/components/Editor/Editor.js +71 -70
- package/dist/modules/editor/components/Editor/Editor.js.map +1 -0
- package/dist/modules/editor/components/Editor/MathsModal.d.ts +0 -1
- package/dist/modules/editor/components/Editor/MathsModal.js +38 -37
- package/dist/modules/editor/components/Editor/MathsModal.js.map +1 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.DropdownMenu.js +15 -14
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.DropdownMenu.js.map +1 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.Emoji.js +38 -37
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.Emoji.js.map +1 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.HighlightColor.js +34 -33
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.HighlightColor.js.map +1 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.PlusMenu.js +13 -12
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.PlusMenu.js.map +1 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.TextColor.js +37 -36
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.TextColor.js.map +1 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.TextSize.js +36 -35
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.TextSize.js.map +1 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.Typography.js +31 -30
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.Typography.js.map +1 -0
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.js +96 -95
- package/dist/modules/editor/components/EditorToolbar/EditorToolbar.js.map +1 -0
- package/dist/modules/editor/components/NodeView/AttachmentNodeView.js +7 -6
- package/dist/modules/editor/components/NodeView/AttachmentNodeView.js.map +1 -0
- package/dist/modules/editor/components/NodeView/AudioNodeView.js +7 -6
- package/dist/modules/editor/components/NodeView/AudioNodeView.js.map +1 -0
- package/dist/modules/editor/components/NodeView/ImageNodeView.js +7 -6
- package/dist/modules/editor/components/NodeView/ImageNodeView.js.map +1 -0
- package/dist/modules/editor/components/NodeView/LinkerNodeView.js +7 -6
- package/dist/modules/editor/components/NodeView/LinkerNodeView.js.map +1 -0
- package/dist/modules/editor/components/NodeView/VideoNodeView.js +7 -6
- package/dist/modules/editor/components/NodeView/VideoNodeView.js.map +1 -0
- package/dist/modules/editor/components/Renderer/AttachmentRenderer.js +25 -24
- package/dist/modules/editor/components/Renderer/AttachmentRenderer.js.map +1 -0
- package/dist/modules/editor/components/Renderer/AudioRenderer.js +8 -7
- package/dist/modules/editor/components/Renderer/AudioRenderer.js.map +1 -0
- package/dist/modules/editor/components/Renderer/LinkerRenderer.js +27 -26
- package/dist/modules/editor/components/Renderer/LinkerRenderer.js.map +1 -0
- package/dist/modules/editor/components/Renderer/MediaRenderer.js +38 -37
- package/dist/modules/editor/components/Renderer/MediaRenderer.js.map +1 -0
- package/dist/modules/editor/components/Toolbar/LinkToolbar.TippyOptions.js +3 -2
- package/dist/modules/editor/components/Toolbar/LinkToolbar.TippyOptions.js.map +1 -0
- package/dist/modules/editor/components/Toolbar/LinkToolbar.d.ts +1 -1
- package/dist/modules/editor/components/Toolbar/LinkToolbar.js +33 -32
- package/dist/modules/editor/components/Toolbar/LinkToolbar.js.map +1 -0
- package/dist/modules/editor/components/Toolbar/TableToolbar.AddMenu.js +22 -21
- package/dist/modules/editor/components/Toolbar/TableToolbar.AddMenu.js.map +1 -0
- package/dist/modules/editor/components/Toolbar/TableToolbar.CellColor.js +31 -30
- package/dist/modules/editor/components/Toolbar/TableToolbar.CellColor.js.map +1 -0
- package/dist/modules/editor/components/Toolbar/TableToolbar.DelMenu.js +21 -20
- package/dist/modules/editor/components/Toolbar/TableToolbar.DelMenu.js.map +1 -0
- package/dist/modules/editor/components/Toolbar/TableToolbar.d.ts +1 -1
- package/dist/modules/editor/components/Toolbar/TableToolbar.js +42 -41
- package/dist/modules/editor/components/Toolbar/TableToolbar.js.map +1 -0
- package/dist/modules/editor/hooks/useActionOptions.js +48 -47
- package/dist/modules/editor/hooks/useActionOptions.js.map +1 -0
- package/dist/modules/editor/hooks/useCommentEditor.js +28 -27
- package/dist/modules/editor/hooks/useCommentEditor.js.map +1 -0
- package/dist/modules/editor/hooks/useEditorContext.js +9 -8
- package/dist/modules/editor/hooks/useEditorContext.js.map +1 -0
- package/dist/modules/editor/hooks/useImageModal.d.ts +1 -1
- package/dist/modules/editor/hooks/useImageModal.js +33 -32
- package/dist/modules/editor/hooks/useImageModal.js.map +1 -0
- package/dist/modules/editor/hooks/useImageSelection.js +32 -31
- package/dist/modules/editor/hooks/useImageSelection.js.map +1 -0
- package/dist/modules/editor/hooks/useLinkToolbar.js +25 -24
- package/dist/modules/editor/hooks/useLinkToolbar.js.map +1 -0
- package/dist/modules/editor/hooks/useMathsModal.js +10 -9
- package/dist/modules/editor/hooks/useMathsModal.js.map +1 -0
- package/dist/modules/editor/hooks/useMathsStyles.js +14 -13
- package/dist/modules/editor/hooks/useMathsStyles.js.map +1 -0
- package/dist/modules/editor/hooks/useMediaLibraryEditor.d.ts +1 -1
- package/dist/modules/editor/hooks/useMediaLibraryEditor.js +97 -96
- package/dist/modules/editor/hooks/useMediaLibraryEditor.js.map +1 -0
- package/dist/modules/editor/hooks/useResizeMedia.js +32 -31
- package/dist/modules/editor/hooks/useResizeMedia.js.map +1 -0
- package/dist/modules/editor/hooks/useSpeechRecognition.js +13 -12
- package/dist/modules/editor/hooks/useSpeechRecognition.js.map +1 -0
- package/dist/modules/editor/hooks/useSpeechSynthetisis.js +14 -13
- package/dist/modules/editor/hooks/useSpeechSynthetisis.js.map +1 -0
- package/dist/modules/editor/hooks/useTipTapEditor.js +58 -57
- package/dist/modules/editor/hooks/useTipTapEditor.js.map +1 -0
- package/dist/modules/editor/utils/has-extension.js +3 -2
- package/dist/modules/editor/utils/has-extension.js.map +1 -0
- package/dist/modules/editor/utils/has-mark.js +3 -2
- package/dist/modules/editor/utils/has-mark.js.map +1 -0
- package/dist/modules/editor/utils/has-text-style.js +4 -3
- package/dist/modules/editor/utils/has-text-style.js.map +1 -0
- package/dist/modules/modals/OnboardingModal/OnboardingModal.d.ts +0 -1
- package/dist/modules/modals/OnboardingModal/OnboardingModal.js +50 -49
- package/dist/modules/modals/OnboardingModal/OnboardingModal.js.map +1 -0
- package/dist/modules/modals/OnboardingModal/useOnboardingModal.js +19 -18
- package/dist/modules/modals/OnboardingModal/useOnboardingModal.js.map +1 -0
- package/dist/modules/modals/PublishModal/PublishModal.d.ts +1 -1
- package/dist/modules/modals/PublishModal/PublishModal.js +98 -97
- package/dist/modules/modals/PublishModal/PublishModal.js.map +1 -0
- package/dist/modules/modals/PublishModal/components/ActivitiesDropdown.js +20 -19
- package/dist/modules/modals/PublishModal/components/ActivitiesDropdown.js.map +1 -0
- package/dist/modules/modals/PublishModal/components/AgeSelect.js +15 -14
- package/dist/modules/modals/PublishModal/components/AgeSelect.js.map +1 -0
- package/dist/modules/modals/PublishModal/components/LangSelect.js +12 -11
- package/dist/modules/modals/PublishModal/components/LangSelect.js.map +1 -0
- package/dist/modules/modals/PublishModal/components/PublishModalFooter.js +17 -16
- package/dist/modules/modals/PublishModal/components/PublishModalFooter.js.map +1 -0
- package/dist/modules/modals/PublishModal/components/SubjectsDropdown.js +20 -19
- package/dist/modules/modals/PublishModal/components/SubjectsDropdown.js.map +1 -0
- package/dist/modules/modals/PublishModal/components/ToastError.js +18 -17
- package/dist/modules/modals/PublishModal/components/ToastError.js.map +1 -0
- package/dist/modules/modals/PublishModal/components/ToastSuccess.d.ts +1 -1
- package/dist/modules/modals/PublishModal/components/ToastSuccess.js +13 -12
- package/dist/modules/modals/PublishModal/components/ToastSuccess.js.map +1 -0
- package/dist/modules/modals/PublishModal/constants/ageOptions.js +3 -2
- package/dist/modules/modals/PublishModal/constants/ageOptions.js.map +1 -0
- package/dist/modules/modals/PublishModal/hooks/useActivitiesOptions.js +5 -4
- package/dist/modules/modals/PublishModal/hooks/useActivitiesOptions.js.map +1 -0
- package/dist/modules/modals/PublishModal/hooks/useLanguageOptions.js +17 -16
- package/dist/modules/modals/PublishModal/hooks/useLanguageOptions.js.map +1 -0
- package/dist/modules/modals/PublishModal/hooks/usePublishModal.d.ts +1 -1
- package/dist/modules/modals/PublishModal/hooks/usePublishModal.js +80 -79
- package/dist/modules/modals/PublishModal/hooks/usePublishModal.js.map +1 -0
- package/dist/modules/modals/PublishModal/hooks/useSubjectsOptions.js +42 -41
- package/dist/modules/modals/PublishModal/hooks/useSubjectsOptions.js.map +1 -0
- package/dist/modules/modals/ResourceModal/ResourceModal.d.ts +1 -1
- package/dist/modules/modals/ResourceModal/ResourceModal.js +116 -115
- package/dist/modules/modals/ResourceModal/ResourceModal.js.map +1 -0
- package/dist/modules/modals/ResourceModal/apps/BlogPublic.d.ts +1 -1
- package/dist/modules/modals/ResourceModal/apps/BlogPublic.js +48 -47
- package/dist/modules/modals/ResourceModal/apps/BlogPublic.js.map +1 -0
- package/dist/modules/modals/ResourceModal/hooks/useSlug.d.ts +1 -1
- package/dist/modules/modals/ResourceModal/hooks/useSlug.js +33 -32
- package/dist/modules/modals/ResourceModal/hooks/useSlug.js.map +1 -0
- package/dist/modules/modals/ResourceModal/hooks/useThumb.d.ts +1 -1
- package/dist/modules/modals/ResourceModal/hooks/useThumb.js +13 -12
- package/dist/modules/modals/ResourceModal/hooks/useThumb.js.map +1 -0
- package/dist/modules/modals/ResourceModal/hooks/useUpdateMutation.d.ts +1 -1
- package/dist/modules/modals/ResourceModal/hooks/useUpdateMutation.js +11 -10
- package/dist/modules/modals/ResourceModal/hooks/useUpdateMutation.js.map +1 -0
- package/dist/modules/modals/ShareModal/ShareBookmarkLine.d.ts +1 -1
- package/dist/modules/modals/ShareModal/ShareModal.d.ts +1 -1
- package/dist/modules/modals/ShareModal/apps/ShareBlog.d.ts +1 -1
- package/dist/modules/modals/ShareModal/apps/ShareBlog.js +34 -33
- package/dist/modules/modals/ShareModal/apps/ShareBlog.js.map +1 -0
- package/dist/modules/modals/ShareModal/hooks/useSearch.d.ts +1 -1
- package/dist/modules/modals/ShareModal/hooks/useShare.d.ts +1 -1
- package/dist/modules/modals/ShareModal/hooks/useShareBookmark.d.ts +1 -1
- package/dist/modules/modals/ShareModal/hooks/useShareMutation.d.ts +1 -1
- package/dist/modules/modals/ShareModal/hooks/useShareMutation.js +13 -12
- package/dist/modules/modals/ShareModal/hooks/useShareMutation.js.map +1 -0
- package/dist/modules/modals/ShareModal/utils/hasRight.d.ts +1 -1
- package/dist/modules/modals/ShareModal/utils/showShareRightLine.d.ts +1 -1
- package/dist/modules/multimedia/AudioRecorder/AudioRecorder.d.ts +1 -1
- package/dist/modules/multimedia/AudioRecorder/AudioRecorder.js +44 -43
- package/dist/modules/multimedia/AudioRecorder/AudioRecorder.js.map +1 -0
- package/dist/modules/multimedia/AudioRecorder/AudioRecorderTimer.js +19 -18
- package/dist/modules/multimedia/AudioRecorder/AudioRecorderTimer.js.map +1 -0
- package/dist/modules/multimedia/AudioRecorder/useAudioRecorder.d.ts +1 -1
- package/dist/modules/multimedia/AudioRecorder/useAudioRecorder.js +158 -157
- package/dist/modules/multimedia/AudioRecorder/useAudioRecorder.js.map +1 -0
- package/dist/modules/multimedia/Embed/Embed.js +23 -22
- package/dist/modules/multimedia/Embed/Embed.js.map +1 -0
- package/dist/modules/multimedia/ImageEditor/components/ImageEditor.js +80 -79
- package/dist/modules/multimedia/ImageEditor/components/ImageEditor.js.map +1 -0
- package/dist/modules/multimedia/ImageEditor/components/ImageEditorToolbar.js +38 -37
- package/dist/modules/multimedia/ImageEditor/components/ImageEditorToolbar.js.map +1 -0
- package/dist/modules/multimedia/ImageEditor/effects/blur.js +50 -49
- package/dist/modules/multimedia/ImageEditor/effects/blur.js.map +1 -0
- package/dist/modules/multimedia/ImageEditor/effects/crop.js +100 -99
- package/dist/modules/multimedia/ImageEditor/effects/crop.js.map +1 -0
- package/dist/modules/multimedia/ImageEditor/effects/misc.js +108 -107
- package/dist/modules/multimedia/ImageEditor/effects/misc.js.map +1 -0
- package/dist/modules/multimedia/ImageEditor/effects/resize.js +97 -96
- package/dist/modules/multimedia/ImageEditor/effects/resize.js.map +1 -0
- package/dist/modules/multimedia/ImageEditor/effects/rotate.js +26 -25
- package/dist/modules/multimedia/ImageEditor/effects/rotate.js.map +1 -0
- package/dist/modules/multimedia/ImageEditor/hooks/useHistoryTool.js +56 -57
- package/dist/modules/multimedia/ImageEditor/hooks/useHistoryTool.js.map +1 -0
- package/dist/modules/multimedia/ImageEditor/hooks/useImageEditor.js +57 -56
- package/dist/modules/multimedia/ImageEditor/hooks/useImageEditor.js.map +1 -0
- package/dist/modules/multimedia/ImageEditor/hooks/useImageEffects.js +29 -28
- package/dist/modules/multimedia/ImageEditor/hooks/useImageEffects.js.map +1 -0
- package/dist/modules/multimedia/ImageEditor/utils/aggregate.js +10 -9
- package/dist/modules/multimedia/ImageEditor/utils/aggregate.js.map +1 -0
- package/dist/modules/multimedia/ImagePickerWorkspace/ImagePickerWorkspace.d.ts +1 -1
- package/dist/modules/multimedia/ImagePickerWorkspace/ImagePickerWorkspace.js +34 -33
- package/dist/modules/multimedia/ImagePickerWorkspace/ImagePickerWorkspace.js.map +1 -0
- package/dist/modules/multimedia/Linker/ExternalLinker.js +37 -36
- package/dist/modules/multimedia/Linker/ExternalLinker.js.map +1 -0
- package/dist/modules/multimedia/Linker/InternalLinker.d.ts +1 -1
- package/dist/modules/multimedia/Linker/InternalLinker.js +89 -88
- package/dist/modules/multimedia/Linker/InternalLinker.js.map +1 -0
- package/dist/modules/multimedia/LinkerCard/LinkerCard.d.ts +1 -1
- package/dist/modules/multimedia/LinkerCard/LinkerCard.js +32 -31
- package/dist/modules/multimedia/LinkerCard/LinkerCard.js.map +1 -0
- package/dist/modules/multimedia/MediaLibrary/MediaLibrary.d.ts +1 -1
- package/dist/modules/multimedia/MediaLibrary/MediaLibrary.js +119 -118
- package/dist/modules/multimedia/MediaLibrary/MediaLibrary.js.map +1 -0
- package/dist/modules/multimedia/MediaLibrary/MediaLibraryContext.d.ts +2 -2
- package/dist/modules/multimedia/MediaLibrary/MediaLibraryContext.js +9 -8
- package/dist/modules/multimedia/MediaLibrary/MediaLibraryContext.js.map +1 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/Audio.js +16 -15
- package/dist/modules/multimedia/MediaLibrary/innertabs/Audio.js.map +1 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/ExternalLink.js +13 -12
- package/dist/modules/multimedia/MediaLibrary/innertabs/ExternalLink.js.map +1 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/Iframe.js +10 -9
- package/dist/modules/multimedia/MediaLibrary/innertabs/Iframe.js.map +1 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/InternalLink.d.ts +1 -1
- package/dist/modules/multimedia/MediaLibrary/innertabs/InternalLink.js +29 -28
- package/dist/modules/multimedia/MediaLibrary/innertabs/InternalLink.js.map +1 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/Upload.js +23 -22
- package/dist/modules/multimedia/MediaLibrary/innertabs/Upload.js.map +1 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/Video.js +18 -17
- package/dist/modules/multimedia/MediaLibrary/innertabs/Video.js.map +1 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/VideoEmbedder.js +10 -9
- package/dist/modules/multimedia/MediaLibrary/innertabs/VideoEmbedder.js.map +1 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/Workspace.js +17 -16
- package/dist/modules/multimedia/MediaLibrary/innertabs/Workspace.js.map +1 -0
- package/dist/modules/multimedia/MediaLibrary/innertabs/index.js +19 -18
- package/dist/modules/multimedia/MediaLibrary/innertabs/index.js.map +1 -0
- package/dist/modules/multimedia/UploadFiles/UploadFiles.d.ts +1 -1
- package/dist/modules/multimedia/UploadFiles/UploadFiles.js +42 -41
- package/dist/modules/multimedia/UploadFiles/UploadFiles.js.map +1 -0
- package/dist/modules/multimedia/VideoEmbed/VideoEmbed.js +60 -59
- package/dist/modules/multimedia/VideoEmbed/VideoEmbed.js.map +1 -0
- package/dist/modules/multimedia/VideoRecorder/VideoRecorder.d.ts +1 -1
- package/dist/modules/multimedia/VideoRecorder/VideoRecorder.js +154 -153
- package/dist/modules/multimedia/VideoRecorder/VideoRecorder.js.map +1 -0
- package/dist/modules/multimedia/Workspace/Workspace.d.ts +1 -1
- package/dist/modules/multimedia/Workspace/Workspace.js +113 -112
- package/dist/modules/multimedia/Workspace/Workspace.js.map +1 -0
- package/dist/multimedia.js +19 -18
- package/dist/multimedia.js.map +1 -0
- package/dist/portal/Header/Badge.js +6 -5
- package/dist/portal/Header/Badge.js.map +1 -0
- package/dist/portal/Header/Header.js +138 -137
- package/dist/portal/Header/Header.js.map +1 -0
- package/dist/portal/Header/NavItem.js +12 -11
- package/dist/portal/Header/NavItem.js.map +1 -0
- package/dist/portal/Header/NavLink.js +15 -14
- package/dist/portal/Header/NavLink.js.map +1 -0
- package/dist/portal/Header/Navbar.js +10 -9
- package/dist/portal/Header/Navbar.js.map +1 -0
- package/dist/portal/Header/NavbarNav.js +10 -9
- package/dist/portal/Header/NavbarNav.js.map +1 -0
- package/dist/portal/Header/WidgetApps.d.ts +1 -1
- package/dist/portal/Header/WidgetApps.js +17 -16
- package/dist/portal/Header/WidgetApps.js.map +1 -0
- package/dist/portal/Help/Help.d.ts +0 -1
- package/dist/portal/Help/Help.js +19 -18
- package/dist/portal/Help/Help.js.map +1 -0
- package/dist/portal/Help/hooks/useHelp.js +64 -63
- package/dist/portal/Help/hooks/useHelp.js.map +1 -0
- package/dist/portal/Layout/Layout.js +36 -35
- package/dist/portal/Layout/Layout.js.map +1 -0
- package/dist/portal/SearchEngine/SearchEngine.js +26 -25
- package/dist/portal/SearchEngine/SearchEngine.js.map +1 -0
- package/dist/utils/MockedDataProvider/MockedDataProvider.d.ts +1 -1
- package/dist/utils/MockedDataProvider/MockedDataProvider.js +22 -21
- package/dist/utils/MockedDataProvider/MockedDataProvider.js.map +1 -0
- package/dist/utils/StringUtils.js +9 -8
- package/dist/utils/StringUtils.js.map +1 -0
- package/dist/utils/addTimestampToUrl.js +5 -4
- package/dist/utils/addTimestampToUrl.js.map +1 -0
- package/dist/utils/blob.js +10 -9
- package/dist/utils/blob.js.map +1 -0
- package/dist/utils/checkUserRight.d.ts +1 -1
- package/dist/utils/checkUserRight.js +28 -27
- package/dist/utils/checkUserRight.js.map +1 -0
- package/dist/utils/fileSize.js +6 -5
- package/dist/utils/fileSize.js.map +1 -0
- package/dist/utils/findTreeNode.js +8 -7
- package/dist/utils/findTreeNode.js.map +1 -0
- package/dist/utils/isActionAvailable.d.ts +1 -1
- package/dist/utils/isActionAvailable.js +5 -4
- package/dist/utils/isActionAvailable.js.map +1 -0
- package/dist/utils/libraryMaps.js +3 -2
- package/dist/utils/libraryMaps.js.map +1 -0
- package/dist/utils/noop.js +3 -2
- package/dist/utils/noop.js.map +1 -0
- package/dist/utils/ref.js +9 -8
- package/dist/utils/ref.js.map +1 -0
- package/dist/utils/thumbnail.js +4 -3
- package/dist/utils/thumbnail.js.map +1 -0
- package/dist/utils/time.js +8 -7
- package/dist/utils/time.js.map +1 -0
- package/dist/utils/treeview.d.ts +1 -1
- package/dist/utils/treeview.js +97 -96
- package/dist/utils/treeview.js.map +1 -0
- package/dist/utils/video.js +3 -2
- package/dist/utils/video.js.map +1 -0
- package/dist/widgets/BookmarkedApps/BookmarkedApps.d.ts +1 -1
- package/dist/widgets/BookmarkedApps/BookmarkedApps.js +7 -6
- package/dist/widgets/BookmarkedApps/BookmarkedApps.js.map +1 -0
- package/dist/widgets/Widget/Widget.js +19 -18
- package/dist/widgets/Widget/Widget.js.map +1 -0
- package/package.json +19 -28
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Edifice React
|
|
1
|
+
# Edifice React Library
|
|
2
2
|
|
|
3
3
|

|
|
4
4
|

|
|
@@ -7,104 +7,33 @@
|
|
|
7
7
|
|
|
8
8
|
We follow [WAI ARIA](https://www.w3.org/WAI/ARIA/apg/patterns/) rules and [Bootstrap 5](https://getbootstrap.com/docs/5.0/components/accordion/) guidelines when making our components
|
|
9
9
|
|
|
10
|
-
###
|
|
10
|
+
### Install
|
|
11
11
|
|
|
12
|
-
```bash
|
|
13
|
-
pnpm run build
|
|
14
12
|
```
|
|
15
|
-
|
|
16
|
-
### Lint
|
|
17
|
-
|
|
18
|
-
```bash
|
|
19
|
-
pnpm run lint
|
|
13
|
+
pnpm add @edifice.io/react
|
|
20
14
|
```
|
|
21
15
|
|
|
22
|
-
|
|
16
|
+
### Modules
|
|
23
17
|
|
|
24
|
-
|
|
25
|
-
pnpm run fix
|
|
26
|
-
```
|
|
18
|
+
Optional modules are available as `sub-imports`. You can use them in specific applications:
|
|
27
19
|
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
```bash
|
|
31
|
-
pnpm run format
|
|
32
|
-
```
|
|
20
|
+
#### Audience
|
|
33
21
|
|
|
34
|
-
|
|
22
|
+
Module to track views or reactions on a resource in a specific application (e.g: Blog)
|
|
35
23
|
|
|
36
|
-
|
|
24
|
+
#### Editor
|
|
37
25
|
|
|
38
|
-
|
|
39
|
-
- Component file in PascalCase: `Button.tsx`
|
|
40
|
-
- Export types & interfaces inside Component file
|
|
41
|
-
- Stories file in PascalCase + `*.stories.tsx` : `Button.stories.tsx`
|
|
26
|
+
Rich Text Editor using Tiptap and our `multimedia` module.
|
|
42
27
|
|
|
43
|
-
|
|
44
|
-
src
|
|
45
|
-
-- ComponentFolder
|
|
46
|
-
-- Component.tsx
|
|
47
|
-
-- Component.stories.tsx
|
|
48
|
-
-- index.ts
|
|
49
|
-
```
|
|
50
|
-
|
|
51
|
-
- Re-export the Component inside his own `index` file: `index.ts`
|
|
52
|
-
- Export everything if Component has types & interfaces
|
|
53
|
-
|
|
54
|
-
```jsx
|
|
55
|
-
export { default as Component } from './Component';
|
|
56
|
-
export * from './Component';
|
|
57
|
-
```
|
|
28
|
+
#### Modals
|
|
58
29
|
|
|
59
|
-
|
|
30
|
+
- Onboarding Modal to greet user and give him some useful informations about an application.
|
|
31
|
+
- Publish Modal to publish a resource to the BPR application.
|
|
32
|
+
- Resource Modal can be used to create or edit information about a resource
|
|
33
|
+
- Share Modal allows a user to share one of his resource with specific roles to users
|
|
60
34
|
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
```jsx
|
|
64
|
-
/**
|
|
65
|
-
* Primary UI component for user interaction
|
|
66
|
-
*/
|
|
67
|
-
```
|
|
68
|
-
|
|
69
|
-
### Interface description
|
|
70
|
-
|
|
71
|
-
- Always document typescript types and interface with JSDoc syntax. Used by Storybook to generate documentation.
|
|
72
|
-
|
|
73
|
-
```jsx
|
|
74
|
-
// Interface description (e.g: TreeViewProps.tsx)
|
|
75
|
-
export interface ButtonProps {
|
|
76
|
-
/**
|
|
77
|
-
* Is this the principal call to action on the page?
|
|
78
|
-
*/
|
|
79
|
-
primary?: boolean;
|
|
80
|
-
/**
|
|
81
|
-
* What background color to use
|
|
82
|
-
*/
|
|
83
|
-
backgroundColor?: string;
|
|
84
|
-
/**
|
|
85
|
-
* How large should the button be?
|
|
86
|
-
*/
|
|
87
|
-
size?: "small" | "medium" | "large";
|
|
88
|
-
/**
|
|
89
|
-
* Button contents
|
|
90
|
-
*/
|
|
91
|
-
label: string;
|
|
92
|
-
/**
|
|
93
|
-
* Optional click handler
|
|
94
|
-
*/
|
|
95
|
-
onClick?: () => void;
|
|
96
|
-
}
|
|
97
|
-
```
|
|
98
|
-
|
|
99
|
-
### Index file inside `src` folder
|
|
100
|
-
|
|
101
|
-
- Entry point of this React Library.
|
|
102
|
-
- Import your component inside `index.ts` file.
|
|
103
|
-
|
|
104
|
-
```jsx
|
|
105
|
-
export * from './Button';
|
|
106
|
-
```
|
|
35
|
+
#### Multimedia
|
|
107
36
|
|
|
108
|
-
|
|
37
|
+
All our multimedia components to use in applications or in modules.
|
|
109
38
|
|
|
110
|
-
|
|
39
|
+
- Linker, AudioRecorder, VideoRecorder, Iframe, Embed component, ...
|
package/dist/audience.js
CHANGED
|
@@ -1,16 +1,17 @@
|
|
|
1
|
-
import { default as
|
|
2
|
-
import { default as
|
|
3
|
-
import { default as
|
|
4
|
-
import { default as
|
|
5
|
-
import { default as
|
|
6
|
-
import { default as
|
|
7
|
-
import { default as
|
|
1
|
+
import { default as a } from "./modules/audience/ViewsCounter.js";
|
|
2
|
+
import { default as r } from "./modules/audience/ViewsModal.js";
|
|
3
|
+
import { default as s } from "./modules/audience/ReactionSummary.js";
|
|
4
|
+
import { default as d } from "./modules/audience/ReactionChoice.js";
|
|
5
|
+
import { default as m } from "./modules/audience/ReactionModal.js";
|
|
6
|
+
import { default as c } from "./modules/audience/hooks/useReactions.js";
|
|
7
|
+
import { default as p } from "./modules/audience/hooks/useReactionIcons.js";
|
|
8
8
|
export {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
9
|
+
d as ReactionChoice,
|
|
10
|
+
m as ReactionModal,
|
|
11
|
+
s as ReactionSummary,
|
|
12
|
+
a as ViewsCounter,
|
|
13
|
+
r as ViewsModal,
|
|
14
|
+
p as useReactionIcons,
|
|
15
|
+
c as useReactions
|
|
16
16
|
};
|
|
17
|
+
//# sourceMappingURL=audience.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"audience.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;"}
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import { jsx } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef } from "react";
|
|
3
|
-
const
|
|
4
|
-
children
|
|
5
|
-
},
|
|
1
|
+
import { jsx as a } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as t } from "react";
|
|
3
|
+
const i = /* @__PURE__ */ t(({
|
|
4
|
+
children: r
|
|
5
|
+
}, o) => /* @__PURE__ */ a("div", { ref: o, className: "actionbar", children: r }));
|
|
6
6
|
export {
|
|
7
|
-
ActionBar,
|
|
8
|
-
|
|
7
|
+
i as ActionBar,
|
|
8
|
+
i as default
|
|
9
9
|
};
|
|
10
|
+
//# sourceMappingURL=ActionBar.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ActionBar.js","sources":["../../../src/components/ActionBar/ActionBar.tsx"],"sourcesContent":["import { forwardRef, Ref } from 'react';\n\nexport interface ActionBarProps {\n /**\n * Add Buttons To Actions bar\n */\n children: React.ReactNode;\n}\n\nexport type ActionBarType = React.FC<ActionBarProps>;\n\nexport const ActionBar = forwardRef(\n ({ children }: ActionBarProps, ref: Ref<HTMLDivElement>) => {\n return (\n <div ref={ref} className=\"actionbar\">\n {children}\n </div>\n );\n },\n);\n\nActionBar.displayName = 'ActionBar';\nexport default ActionBar;\n"],"names":["ActionBar","children","ref","jsx"],"mappings":";;AAWaA,MAAAA,sBACX,CAAC;AAAA,EAAEC,UAAAA;AAAyB,GAAGC,MAE1B,gBAAAC,EAAA,OAAA,EAAI,KAAAD,GAAU,WAAU,aACtBD,UAAAA,EACH,CAAA,CAGN;"}
|
|
@@ -1,79 +1,80 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { forwardRef, useState, useRef, useCallback, useImperativeHandle, useLayoutEffect, useEffect } from "react";
|
|
3
|
-
import
|
|
4
|
-
import { useTranslation } from "react-i18next";
|
|
5
|
-
import { Button } from "../Button/Button.js";
|
|
6
|
-
import { Icon } from "../Icon/Icon.js";
|
|
7
|
-
const
|
|
8
|
-
type = "success",
|
|
9
|
-
className = "",
|
|
10
|
-
children,
|
|
11
|
-
button,
|
|
12
|
-
isDismissible = !1,
|
|
13
|
-
isToast = !1,
|
|
14
|
-
isConfirm = !1,
|
|
15
|
-
position = "none",
|
|
16
|
-
autoClose = !1,
|
|
17
|
-
autoCloseDelay = 3e3,
|
|
18
|
-
onClose,
|
|
19
|
-
onVisibilityChange
|
|
20
|
-
},
|
|
21
|
-
const [
|
|
22
|
-
t
|
|
23
|
-
} =
|
|
24
|
-
|
|
25
|
-
}, [
|
|
26
|
-
|
|
27
|
-
show,
|
|
28
|
-
hide,
|
|
29
|
-
...
|
|
30
|
-
})),
|
|
31
|
-
|
|
32
|
-
}, [
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
},
|
|
36
|
-
}, [
|
|
37
|
-
const
|
|
38
|
-
|
|
39
|
-
},
|
|
1
|
+
import { jsxs as N, jsx as s } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as I, useState as R, useRef as S, useCallback as T, useImperativeHandle as h, useLayoutEffect as B, useEffect as H } from "react";
|
|
3
|
+
import L from "clsx";
|
|
4
|
+
import { useTranslation as X } from "react-i18next";
|
|
5
|
+
import { Button as q } from "../Button/Button.js";
|
|
6
|
+
import { Icon as l } from "../Icon/Icon.js";
|
|
7
|
+
const P = /* @__PURE__ */ I(({
|
|
8
|
+
type: o = "success",
|
|
9
|
+
className: M = "",
|
|
10
|
+
children: w,
|
|
11
|
+
button: i,
|
|
12
|
+
isDismissible: f = !1,
|
|
13
|
+
isToast: x = !1,
|
|
14
|
+
isConfirm: a = !1,
|
|
15
|
+
position: b = "none",
|
|
16
|
+
autoClose: n = !1,
|
|
17
|
+
autoCloseDelay: m = 3e3,
|
|
18
|
+
onClose: c,
|
|
19
|
+
onVisibilityChange: t
|
|
20
|
+
}, k) => {
|
|
21
|
+
const [e, d] = R(!0), u = S(null), {
|
|
22
|
+
t: p
|
|
23
|
+
} = X(), r = T(() => {
|
|
24
|
+
d(!1), c == null || c();
|
|
25
|
+
}, [c]);
|
|
26
|
+
h(k, () => ({
|
|
27
|
+
show: g,
|
|
28
|
+
hide: r,
|
|
29
|
+
...u.current
|
|
30
|
+
})), B(() => {
|
|
31
|
+
t == null || t(e);
|
|
32
|
+
}, [e, t]), H(() => {
|
|
33
|
+
n && e && setTimeout(() => {
|
|
34
|
+
r();
|
|
35
|
+
}, m);
|
|
36
|
+
}, [n, m, r, e]);
|
|
37
|
+
const g = () => {
|
|
38
|
+
d(!0);
|
|
39
|
+
}, v = {
|
|
40
40
|
success: {
|
|
41
|
-
icon: /* @__PURE__ */
|
|
41
|
+
icon: /* @__PURE__ */ s(l, { name: "success-outline" }),
|
|
42
42
|
classModifier: "alert-success"
|
|
43
43
|
},
|
|
44
44
|
warning: {
|
|
45
|
-
icon: /* @__PURE__ */
|
|
45
|
+
icon: /* @__PURE__ */ s(l, { name: "alert-circle" }),
|
|
46
46
|
classModifier: "alert-warning"
|
|
47
47
|
},
|
|
48
48
|
info: {
|
|
49
|
-
icon: /* @__PURE__ */
|
|
49
|
+
icon: /* @__PURE__ */ s(l, { name: "info-circle" }),
|
|
50
50
|
classModifier: "alert-info"
|
|
51
51
|
},
|
|
52
52
|
danger: {
|
|
53
|
-
icon: /* @__PURE__ */
|
|
53
|
+
icon: /* @__PURE__ */ s(l, { name: "error" }),
|
|
54
54
|
classModifier: "alert-danger"
|
|
55
55
|
}
|
|
56
|
-
},
|
|
57
|
-
"is-dismissible":
|
|
58
|
-
"is-toast ":
|
|
59
|
-
},
|
|
60
|
-
"is-confirm":
|
|
61
|
-
},
|
|
62
|
-
return
|
|
63
|
-
!
|
|
64
|
-
/* @__PURE__ */
|
|
65
|
-
|
|
66
|
-
|
|
56
|
+
}, j = {
|
|
57
|
+
"is-dismissible": f,
|
|
58
|
+
"is-toast ": x
|
|
59
|
+
}, A = {
|
|
60
|
+
"is-confirm": a
|
|
61
|
+
}, E = L("alert gap-12", v[o].classModifier, j, A, b, M);
|
|
62
|
+
return e ? /* @__PURE__ */ N("div", { ref: u, className: E, role: "alert", children: [
|
|
63
|
+
!a && v[o].icon,
|
|
64
|
+
/* @__PURE__ */ s("div", { className: "alert-content small", children: w }),
|
|
65
|
+
i && /* @__PURE__ */ N("div", { className: "ms-12", children: [
|
|
66
|
+
i,
|
|
67
67
|
" ",
|
|
68
|
-
|
|
68
|
+
a && /* @__PURE__ */ s(q, { onClick: r, children: p("close") })
|
|
69
69
|
] }),
|
|
70
|
-
(
|
|
71
|
-
|
|
70
|
+
(f || a) && /* @__PURE__ */ s("div", { className: "btn-close-container", children: /* @__PURE__ */ s("button", { type: "button", className: "btn-close", "data-bs-dismiss": "alert", "aria-label": p("close"), onClick: r }) }),
|
|
71
|
+
n && /* @__PURE__ */ s("div", { className: "alert-progress", style: {
|
|
72
72
|
transform: "scaleX(0)"
|
|
73
73
|
} })
|
|
74
|
-
] }) : null
|
|
75
|
-
})
|
|
74
|
+
] }) : null;
|
|
75
|
+
});
|
|
76
76
|
export {
|
|
77
|
-
Alert,
|
|
78
|
-
|
|
77
|
+
P as Alert,
|
|
78
|
+
P as default
|
|
79
79
|
};
|
|
80
|
+
//# sourceMappingURL=Alert.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Alert.js","sources":["../../../src/components/Alert/Alert.tsx"],"sourcesContent":["import {\n ComponentPropsWithRef,\n forwardRef,\n ReactNode,\n Ref,\n useCallback,\n useEffect,\n useImperativeHandle,\n useLayoutEffect,\n useRef,\n useState,\n} from 'react';\n\nimport clsx from 'clsx';\nimport { useTranslation } from 'react-i18next';\n\nimport { Icon } from '..';\nimport { Button } from '../Button';\n\nexport interface AlertRef {\n show: () => void;\n hide: () => void;\n}\n\nexport type AlertTypes = 'success' | 'warning' | 'info' | 'danger';\n\nexport type AlertPosition =\n | 'none'\n | 'top-left'\n | 'top-right'\n | 'bottom-left'\n | 'bottom-right';\n\nexport interface AlertProps extends ComponentPropsWithRef<'div'> {\n /**\n * Type of alert\n */\n type?: AlertTypes;\n\n /**\n * Alert can be closed with a button ?\n */\n isDismissible?: boolean;\n\n /**\n * Alert is displayed as Toast\n */\n isToast?: boolean;\n\n /**\n * Alert is displayed as a confirm box (cancel button and confirm button)\n */\n isConfirm?: boolean;\n\n /**\n * Alert poistion.\n */\n position?: AlertPosition;\n\n /**\n * Alert must close after delay\n */\n autoClose?: boolean;\n\n /**\n * If autoClose if activated, set the delay\n * Défault : 3000\n */\n autoCloseDelay?: number;\n\n /**\n * Alert box content\n */\n children: ReactNode;\n\n /**\n * Alert box action\n */\n button?: ReactNode;\n\n /**\n * Callback when alert is closed\n */\n onClose?: () => void;\n\n /**\n * Callback when alert is closed\n */\n onVisibilityChange?: (isVisible: boolean) => void;\n\n /**\n * Optional class for styling purpose\n */\n className?: string;\n}\n\nexport const Alert = forwardRef(\n (\n {\n type = 'success',\n className = '',\n children,\n button,\n isDismissible = false,\n isToast = false,\n isConfirm = false,\n position = 'none',\n autoClose = false,\n autoCloseDelay = 3000,\n onClose,\n onVisibilityChange,\n }: AlertProps,\n ref: Ref<AlertRef>,\n ) => {\n const [isVisible, setVisibleStatus] = useState<boolean>(true);\n\n // Local ref will be merged with forwardRef in useImperativeHandle below\n const refAlert = useRef<HTMLDivElement>(null);\n\n const { t } = useTranslation();\n\n // Method to hide alert\n const hide = useCallback(() => {\n setVisibleStatus(false);\n // The parent component can execute function when alert is closed\n onClose?.();\n }, [onClose]);\n\n // We add two methods to control the alert from parent component\n useImperativeHandle(ref, () => ({\n show,\n hide,\n ...(refAlert.current as HTMLDivElement),\n }));\n\n // The parent component can get alert visible state\n useLayoutEffect(() => {\n onVisibilityChange?.(isVisible);\n }, [isVisible, onVisibilityChange]);\n\n useEffect(() => {\n if (autoClose && isVisible) {\n setTimeout(() => {\n hide();\n }, autoCloseDelay);\n }\n }, [autoClose, autoCloseDelay, hide, isVisible]);\n\n // Method to show alert\n const show = () => {\n setVisibleStatus(true);\n };\n\n // Here we are mapping alert type with icon Component and bootstrap class\n // https://getbootstrap.com/docs/5.2/components/alerts/\n const mapping = {\n success: {\n icon: <Icon name=\"success-outline\" />,\n classModifier: 'alert-success',\n },\n warning: {\n icon: <Icon name=\"alert-circle\" />,\n classModifier: 'alert-warning',\n },\n info: { icon: <Icon name=\"info-circle\" />, classModifier: 'alert-info' },\n danger: { icon: <Icon name=\"error\" />, classModifier: 'alert-danger' },\n };\n\n // Create className Attribute from component parameters\n const toastClasses = {\n 'is-dismissible': isDismissible,\n 'is-toast ': isToast,\n };\n // class for Confirm box style\n const confirmClasses = {\n 'is-confirm': isConfirm,\n };\n\n const divContainerClasses = clsx(\n 'alert gap-12',\n mapping[type].classModifier,\n toastClasses,\n confirmClasses,\n position,\n className,\n );\n\n return isVisible ? (\n <div ref={refAlert} className={divContainerClasses} role=\"alert\">\n {!isConfirm && mapping[type].icon}\n <div className=\"alert-content small\">{children}</div>\n {button && (\n <div className=\"ms-12\">\n {button} {isConfirm && <Button onClick={hide}>{t('close')}</Button>}\n </div>\n )}\n {(isDismissible || isConfirm) && (\n <div className=\"btn-close-container\">\n <button\n type=\"button\"\n className=\"btn-close\"\n data-bs-dismiss=\"alert\"\n aria-label={t('close')}\n onClick={hide}\n ></button>\n </div>\n )}\n {/* Waiting animation library */}\n {autoClose && (\n <div\n className=\"alert-progress\"\n style={{\n transform: `scaleX(0)`,\n }}\n ></div>\n )}\n </div>\n ) : null;\n },\n);\n\nAlert.displayName = 'Alert';\n\nexport default Alert;\n"],"names":["Alert","type","className","children","button","isDismissible","isToast","isConfirm","position","autoClose","autoCloseDelay","onClose","onVisibilityChange","ref","isVisible","setVisibleStatus","useState","refAlert","useRef","t","useTranslation","hide","useCallback","useImperativeHandle","show","current","useLayoutEffect","useEffect","setTimeout","mapping","success","icon","jsx","Icon","classModifier","warning","info","danger","toastClasses","confirmClasses","divContainerClasses","clsx","jsxs","Button","transform"],"mappings":";;;;;;AAgGaA,MAAAA,sBACX,CACE;AAAA,EACEC,MAAAA,IAAO;AAAA,EACPC,WAAAA,IAAY;AAAA,EACZC,UAAAA;AAAAA,EACAC,QAAAA;AAAAA,EACAC,eAAAA,IAAgB;AAAA,EAChBC,SAAAA,IAAU;AAAA,EACVC,WAAAA,IAAY;AAAA,EACZC,UAAAA,IAAW;AAAA,EACXC,WAAAA,IAAY;AAAA,EACZC,gBAAAA,IAAiB;AAAA,EACjBC,SAAAA;AAAAA,EACAC,oBAAAA;AACU,GACZC,MACG;AACH,QAAM,CAACC,GAAWC,CAAgB,IAAIC,EAAkB,EAAI,GAGtDC,IAAWC,EAAuB,IAAI,GAEtC;AAAA,IAAEC,GAAAA;AAAAA,MAAMC,EAAe,GAGvBC,IAAOC,EAAY,MAAM;AAC7BP,IAAAA,EAAiB,EAAK,GAEZJ,KAAA,QAAAA;AAAA,EAAA,GACT,CAACA,CAAO,CAAC;AAGZY,EAAAA,EAAoBV,GAAK,OAAO;AAAA,IAC9BW,MAAAA;AAAAA,IACAH,MAAAA;AAAAA,IACA,GAAIJ,EAASQ;AAAAA,EACb,EAAA,GAGFC,EAAgB,MAAM;AACpBd,IAAAA,KAAAA,QAAAA,EAAqBE;AAAAA,EAAS,GAC7B,CAACA,GAAWF,CAAkB,CAAC,GAElCe,EAAU,MAAM;AACd,IAAIlB,KAAaK,KACfc,WAAW,MAAM;AACV,MAAAP;OACJX,CAAc;AAAA,KAElB,CAACD,GAAWC,GAAgBW,GAAMP,CAAS,CAAC;AAG/C,QAAMU,IAAOA,MAAM;AACjBT,IAAAA,EAAiB,EAAI;AAAA,EAAA,GAKjBc,IAAU;AAAA,IACdC,SAAS;AAAA,MACPC,MAAM,gBAAAC,EAACC,GAAK,EAAA,MAAK,kBAAoB,CAAA;AAAA,MACrCC,eAAe;AAAA,IACjB;AAAA,IACAC,SAAS;AAAA,MACPJ,MAAM,gBAAAC,EAACC,GAAK,EAAA,MAAK,eAAiB,CAAA;AAAA,MAClCC,eAAe;AAAA,IACjB;AAAA,IACAE,MAAM;AAAA,MAAEL,MAAM,gBAAAC,EAACC,GAAK,EAAA,MAAK,cAAgB,CAAA;AAAA,MAAEC,eAAe;AAAA,IAAa;AAAA,IACvEG,QAAQ;AAAA,MAAEN,MAAM,gBAAAC,EAACC,GAAK,EAAA,MAAK,QAAU,CAAA;AAAA,MAAEC,eAAe;AAAA,IAAe;AAAA,EAAA,GAIjEI,IAAe;AAAA,IACnB,kBAAkBjC;AAAAA,IAClB,aAAaC;AAAAA,EAAAA,GAGTiC,IAAiB;AAAA,IACrB,cAAchC;AAAAA,EAAAA,GAGViC,IAAsBC,EAC1B,gBACAZ,EAAQ5B,CAAI,EAAEiC,eACdI,GACAC,GACA/B,GACAN,CACF;AAEOY,SAAAA,sBACJ,OAAI,EAAA,KAAKG,GAAU,WAAWuB,GAAqB,MAAK,SACtD,UAAA;AAAA,IAACjC,CAAAA,KAAasB,EAAQ5B,CAAI,EAAE8B;AAAAA,IAC5B,gBAAAC,EAAA,OAAA,EAAI,WAAU,uBAAuB7B,UAAAA,EAAS,CAAA;AAAA,IAC9CC,KACC,gBAAAsC,EAAC,OAAI,EAAA,WAAU,SACZtC,UAAAA;AAAAA,MAAAA;AAAAA,MAAO;AAAA,MAAEG,KAAc,gBAAAyB,EAAAW,GAAA,EAAO,SAAStB,GAAOF,UAAAA,EAAE,OAAO,GAAE;AAAA,IAAA,GAC5D;AAAA,KAEAd,KAAiBE,MAChB,gBAAAyB,EAAA,OAAA,EAAI,WAAU,uBACb,UAAA,gBAAAA,EAAC,YACC,MAAK,UACL,WAAU,aACV,mBAAgB,SAChB,cAAYb,EAAE,OAAO,GACrB,SAASE,GACV,EACH,CAAA;AAAA,IAGDZ,KACC,gBAAAuB,EAAC,OACC,EAAA,WAAU,kBACV,OAAO;AAAA,MACLY,WAAW;AAAA,IAAA,GAEd;AAAA,EAAA,EAEL,CAAA,IACE;AACN,CACF;"}
|
|
@@ -1,23 +1,24 @@
|
|
|
1
|
-
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef } from "react";
|
|
3
|
-
import
|
|
4
|
-
const
|
|
5
|
-
children,
|
|
6
|
-
render,
|
|
7
|
-
isFullscreen = !1,
|
|
8
|
-
...
|
|
9
|
-
},
|
|
10
|
-
const
|
|
11
|
-
"justify-content-between":
|
|
12
|
-
"mx-n16": !
|
|
13
|
-
"z-3 top-0 start-0 end-0":
|
|
1
|
+
import { jsxs as l, jsx as m } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as f } from "react";
|
|
3
|
+
import p from "clsx";
|
|
4
|
+
const d = /* @__PURE__ */ f(({
|
|
5
|
+
children: s,
|
|
6
|
+
render: t,
|
|
7
|
+
isFullscreen: e = !1,
|
|
8
|
+
...a
|
|
9
|
+
}, o) => {
|
|
10
|
+
const r = p("d-flex flex-wrap p-16 gap-8 border-bottom bg-white", {
|
|
11
|
+
"justify-content-between": t,
|
|
12
|
+
"mx-n16": !e,
|
|
13
|
+
"z-3 top-0 start-0 end-0": e
|
|
14
14
|
});
|
|
15
|
-
return /* @__PURE__ */
|
|
16
|
-
|
|
17
|
-
|
|
15
|
+
return /* @__PURE__ */ l("div", { ref: o, className: r, ...a, children: [
|
|
16
|
+
s,
|
|
17
|
+
t ? /* @__PURE__ */ m("div", { className: "d-flex align-items-center ms-auto gap-8", children: t() }) : null
|
|
18
18
|
] });
|
|
19
19
|
});
|
|
20
20
|
export {
|
|
21
|
-
AppHeader,
|
|
22
|
-
|
|
21
|
+
d as AppHeader,
|
|
22
|
+
d as default
|
|
23
23
|
};
|
|
24
|
+
//# sourceMappingURL=AppHeader.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AppHeader.js","sources":["../../../src/components/AppHeader/AppHeader.tsx"],"sourcesContent":["import { ComponentPropsWithRef, forwardRef, ReactNode, Ref } from 'react';\n\nimport clsx from 'clsx';\n\nexport interface AppHeaderProps extends ComponentPropsWithRef<'div'> {\n /**\n * Accept Breadcrumb Component\n */\n children: ReactNode;\n /**\n * Actions\n */\n render?: () => JSX.Element | null;\n /**\n * When no layout is used\n */\n isFullscreen?: boolean;\n}\n\nexport const AppHeader = forwardRef(\n (\n { children, render, isFullscreen = false, ...restProps }: AppHeaderProps,\n ref: Ref<HTMLDivElement>,\n ) => {\n const classes = clsx('d-flex flex-wrap p-16 gap-8 border-bottom bg-white', {\n 'justify-content-between': render,\n 'mx-n16': !isFullscreen,\n 'z-3 top-0 start-0 end-0': isFullscreen,\n });\n\n return (\n <div ref={ref} className={classes} {...restProps}>\n {children}\n {render ? (\n <div className=\"d-flex align-items-center ms-auto gap-8\">\n {render()}\n </div>\n ) : null}\n </div>\n );\n },\n);\n\nAppHeader.displayName = 'AppHeader';\n\nexport default AppHeader;\n"],"names":["AppHeader","children","render","isFullscreen","restProps","ref","classes","clsx","jsx"],"mappings":";;;AAmBaA,MAAAA,sBACX,CACE;AAAA,EAAEC,UAAAA;AAAAA,EAAUC,QAAAA;AAAAA,EAAQC,cAAAA,IAAe;AAAA,EAAO,GAAGC;AAA0B,GACvEC,MACG;AACGC,QAAAA,IAAUC,EAAK,sDAAsD;AAAA,IACzE,2BAA2BL;AAAAA,IAC3B,UAAU,CAACC;AAAAA,IACX,2BAA2BA;AAAAA,EAAAA,CAC5B;AAED,2BACG,OAAI,EAAA,KAAAE,GAAU,WAAWC,GAAS,GAAIF,GACpCH,UAAAA;AAAAA,IAAAA;AAAAA,IACAC,IACE,gBAAAM,EAAA,OAAA,EAAI,WAAU,2CACZN,UAAAA,IACH,CAAA,IACE;AAAA,EACN,EAAA,CAAA;AAEJ,CACF;"}
|
|
@@ -1,49 +1,50 @@
|
|
|
1
|
-
import { jsx } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef } from "react";
|
|
3
|
-
import
|
|
4
|
-
import { Image } from "../Image/Image.js";
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
const
|
|
8
|
-
app,
|
|
9
|
-
size = "24",
|
|
10
|
-
iconFit = "contain",
|
|
11
|
-
variant = "square",
|
|
12
|
-
className = ""
|
|
13
|
-
},
|
|
1
|
+
import { jsx as t } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as b } from "react";
|
|
3
|
+
import d from "clsx";
|
|
4
|
+
import { Image as j } from "../Image/Image.js";
|
|
5
|
+
import P from "../../core/useOdeIcons/useOdeIcons.js";
|
|
6
|
+
import S from "../../core/usePaths/usePaths.js";
|
|
7
|
+
const O = /* @__PURE__ */ b(({
|
|
8
|
+
app: o,
|
|
9
|
+
size: n = "24",
|
|
10
|
+
iconFit: s = "contain",
|
|
11
|
+
variant: i = "square",
|
|
12
|
+
className: r = ""
|
|
13
|
+
}, m) => {
|
|
14
14
|
const {
|
|
15
|
-
isIconUrl,
|
|
16
|
-
getIconCode
|
|
17
|
-
} =
|
|
18
|
-
"icon-xs":
|
|
19
|
-
"icon-sm":
|
|
20
|
-
"icon-md":
|
|
21
|
-
"icon-lg":
|
|
22
|
-
"icon-xl":
|
|
23
|
-
},
|
|
24
|
-
square:
|
|
25
|
-
rounded:
|
|
26
|
-
"rounded-circle":
|
|
27
|
-
},
|
|
28
|
-
"icon-contain":
|
|
29
|
-
"icon-ratio":
|
|
30
|
-
},
|
|
31
|
-
if (
|
|
32
|
-
const
|
|
33
|
-
return /* @__PURE__ */
|
|
15
|
+
isIconUrl: h,
|
|
16
|
+
getIconCode: a
|
|
17
|
+
} = P(), [, u] = S(), g = i === "square", f = i === "rounded", x = i === "circle", e = s === "contain", w = s === "ratio", y = {
|
|
18
|
+
"icon-xs": n === "24",
|
|
19
|
+
"icon-sm": n === "40",
|
|
20
|
+
"icon-md": n === "48",
|
|
21
|
+
"icon-lg": n === "80",
|
|
22
|
+
"icon-xl": n === "160"
|
|
23
|
+
}, I = {
|
|
24
|
+
square: g,
|
|
25
|
+
rounded: f,
|
|
26
|
+
"rounded-circle": x
|
|
27
|
+
}, C = {
|
|
28
|
+
"icon-contain": e,
|
|
29
|
+
"icon-ratio": w
|
|
30
|
+
}, l = typeof o == "string" ? o : (o == null ? void 0 : o.icon) !== void 0 ? o.icon : "placeholder", q = typeof o != "string" && (o == null ? void 0 : o.displayName) !== void 0 ? o.displayName : "", v = o ? a(o) : "", N = h(l), c = v || "placeholder";
|
|
31
|
+
if (N) {
|
|
32
|
+
const $ = d("h-full", r);
|
|
33
|
+
return /* @__PURE__ */ t(j, { src: l, alt: q, objectFit: "contain", width: n, height: n, className: $ });
|
|
34
34
|
}
|
|
35
|
-
const
|
|
36
|
-
...
|
|
37
|
-
...
|
|
38
|
-
...
|
|
39
|
-
[`bg-light-${
|
|
40
|
-
[`color-app-${
|
|
41
|
-
},
|
|
42
|
-
return /* @__PURE__ */
|
|
43
|
-
width:
|
|
44
|
-
height:
|
|
45
|
-
}, children: /* @__PURE__ */
|
|
35
|
+
const R = d("app-icon", {
|
|
36
|
+
...y,
|
|
37
|
+
...I,
|
|
38
|
+
...C,
|
|
39
|
+
[`bg-light-${c}`]: c && !e,
|
|
40
|
+
[`color-app-${c}`]: c
|
|
41
|
+
}, r);
|
|
42
|
+
return /* @__PURE__ */ t("div", { className: R, style: {
|
|
43
|
+
width: n + "px",
|
|
44
|
+
height: n + "px"
|
|
45
|
+
}, children: /* @__PURE__ */ t("svg", { ref: m, width: n, height: n, role: "img", fill: "currentColor", xmlns: "http://www.w3.org/2000/svg", "aria-hidden": "true", children: /* @__PURE__ */ t("use", { xlinkHref: `${u}/apps.svg#${c}` }) }) });
|
|
46
46
|
});
|
|
47
47
|
export {
|
|
48
|
-
AppIcon
|
|
48
|
+
O as AppIcon
|
|
49
49
|
};
|
|
50
|
+
//# sourceMappingURL=AppIcon.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AppIcon.js","sources":["../../../src/components/AppIcon/AppIcon.tsx"],"sourcesContent":["import { forwardRef, Ref } from 'react';\n\nimport { IWebApp } from '@edifice.io/ts-client';\nimport clsx from 'clsx';\n\nimport { useOdeIcons, usePaths } from '../../core';\nimport { Image } from '../Image';\n\nexport type AppIconSize = '24' | '32' | '40' | '48' | '80' | '160';\n\nexport interface AppIconBaseProps {\n /**\n * Define icon size\n */\n size?: AppIconSize;\n /**\n * App information to get code and name\n */\n app?: IWebApp | string;\n /**\n * Custom class name\n */\n className?: string;\n}\n\ntype AppVariants = 'square' | 'circle' | 'rounded';\ntype SquareVariant = Extract<AppVariants, 'square'>;\n\ntype SquareIcon = {\n /**\n * Show icon full width\n */\n iconFit?: 'contain';\n /**\n * Square variant\n */\n variant?: SquareVariant;\n};\n\ntype VariantsIcon = {\n /**\n * Add padding around icon\n */\n iconFit: 'ratio';\n /**\n * Rounded or Circle variant\n */\n variant: AppVariants;\n};\n\nexport type AppIconVariants = SquareIcon | VariantsIcon;\nexport type AppIconProps = AppIconBaseProps & AppIconVariants;\n\n/**\n * Icon Component used to display the icon of an application\n */\nexport const AppIcon = forwardRef(\n (\n {\n app,\n size = '24',\n iconFit = 'contain',\n variant = 'square',\n className = '',\n }: AppIconProps,\n ref: Ref<SVGSVGElement>,\n ) => {\n const { isIconUrl, getIconCode } = useOdeIcons();\n const [, iconPath] = usePaths();\n\n const isSquare = variant === 'square';\n const isRounded = variant === 'rounded';\n const isCircle = variant === 'circle';\n const isContain = iconFit === 'contain';\n const isRatio = iconFit === 'ratio';\n\n const iconSizes = {\n 'icon-xs': size === '24',\n 'icon-sm': size === '40',\n 'icon-md': size === '48',\n 'icon-lg': size === '80',\n 'icon-xl': size === '160',\n };\n\n const iconVariant = {\n square: isSquare,\n rounded: isRounded,\n 'rounded-circle': isCircle,\n };\n\n const iconFits = {\n 'icon-contain': isContain,\n 'icon-ratio': isRatio,\n };\n\n const icon =\n typeof app === 'string'\n ? app\n : app?.icon !== undefined\n ? app.icon\n : 'placeholder';\n const displayName =\n typeof app !== 'string' && app?.displayName !== undefined\n ? app.displayName\n : '';\n const code = app ? getIconCode(app) : '';\n const isIconURL = isIconUrl(icon);\n\n const appCode = code || 'placeholder';\n\n if (isIconURL) {\n const classes = clsx('h-full', className);\n return (\n <Image\n src={icon}\n alt={displayName}\n objectFit=\"contain\"\n width={size}\n height={size}\n className={classes}\n />\n );\n }\n\n const classes = clsx(\n 'app-icon',\n {\n ...iconSizes,\n ...iconVariant,\n ...iconFits,\n [`bg-light-${appCode}`]: appCode && !isContain,\n [`color-app-${appCode}`]: appCode,\n },\n className,\n );\n\n return (\n <div\n className={classes}\n style={{ width: size + 'px', height: size + 'px' }}\n >\n <svg\n ref={ref}\n width={size}\n height={size}\n role=\"img\"\n fill=\"currentColor\"\n xmlns=\"http://www.w3.org/2000/svg\"\n aria-hidden=\"true\"\n >\n <use xlinkHref={`${iconPath}/apps.svg#${appCode}`} />\n </svg>\n </div>\n );\n },\n);\n\nAppIcon.displayName = 'AppIcon';\n"],"names":["AppIcon","app","size","iconFit","variant","className","ref","isIconUrl","getIconCode","useOdeIcons","iconPath","usePaths","isSquare","isRounded","isCircle","isContain","isRatio","iconSizes","iconVariant","square","rounded","iconFits","icon","undefined","displayName","code","isIconURL","appCode","classes","clsx","jsx","Image","width","height"],"mappings":";;;;;;AAwDaA,MAAAA,sBACX,CACE;AAAA,EACEC,KAAAA;AAAAA,EACAC,MAAAA,IAAO;AAAA,EACPC,SAAAA,IAAU;AAAA,EACVC,SAAAA,IAAU;AAAA,EACVC,WAAAA,IAAY;AACA,GACdC,MACG;AACG,QAAA;AAAA,IAAEC,WAAAA;AAAAA,IAAWC,aAAAA;AAAAA,MAAgBC,EAAY,GACzC,CAAGC,EAAAA,CAAQ,IAAIC,KAEfC,IAAWR,MAAY,UACvBS,IAAYT,MAAY,WACxBU,IAAWV,MAAY,UACvBW,IAAYZ,MAAY,WACxBa,IAAUb,MAAY,SAEtBc,IAAY;AAAA,IAChB,WAAWf,MAAS;AAAA,IACpB,WAAWA,MAAS;AAAA,IACpB,WAAWA,MAAS;AAAA,IACpB,WAAWA,MAAS;AAAA,IACpB,WAAWA,MAAS;AAAA,EAAA,GAGhBgB,IAAc;AAAA,IAClBC,QAAQP;AAAAA,IACRQ,SAASP;AAAAA,IACT,kBAAkBC;AAAAA,EAAAA,GAGdO,IAAW;AAAA,IACf,gBAAgBN;AAAAA,IAChB,cAAcC;AAAAA,EAAAA,GAGVM,IACJ,OAAOrB,KAAQ,WACXA,KACAA,KAAAA,gBAAAA,EAAKqB,UAASC,SACZtB,EAAIqB,OACJ,eACFE,IACJ,OAAOvB,KAAQ,aAAYA,KAAAA,gBAAAA,EAAKuB,iBAAgBD,SAC5CtB,EAAIuB,cACJ,IACAC,IAAOxB,IAAMO,EAAYP,CAAG,IAAI,IAChCyB,IAAYnB,EAAUe,CAAI,GAE1BK,IAAUF,KAAQ;AAExB,MAAIC,GAAW;AACPE,UAAAA,IAAUC,EAAK,UAAUxB,CAAS;AACxC,WACG,gBAAAyB,EAAAC,GAAA,EACC,KAAKT,GACL,KAAKE,GACL,WAAU,WACV,OAAOtB,GACP,QAAQA,GACR,WAAW0B,EACX,CAAA;AAAA,EAEN;AAEMA,QAAAA,IAAUC,EACd,YACA;AAAA,IACE,GAAGZ;AAAAA,IACH,GAAGC;AAAAA,IACH,GAAGG;AAAAA,IACH,CAAC,YAAYM,CAAO,EAAE,GAAGA,KAAW,CAACZ;AAAAA,IACrC,CAAC,aAAaY,CAAO,EAAE,GAAGA;AAAAA,KAE5BtB,CACF;AAEA,SACG,gBAAAyB,EAAA,OAAA,EACC,WAAWF,GACX,OAAO;AAAA,IAAEI,OAAO9B,IAAO;AAAA,IAAM+B,QAAQ/B,IAAO;AAAA,EAAK,GAEjD,UAAC,gBAAA4B,EAAA,OAAA,EACC,KAAAxB,GACA,OAAOJ,GACP,QAAQA,GACR,MAAK,OACL,MAAK,gBACL,OAAM,8BACN,eAAY,QAEZ,UAAA,gBAAA4B,EAAC,OAAI,EAAA,WAAW,GAAGpB,CAAQ,aAAaiB,CAAO,GAAG,CAAA,EACpD,CAAA,EACF,CAAA;AAEJ,CACF;"}
|
|
@@ -1,16 +1,17 @@
|
|
|
1
|
-
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef } from "react";
|
|
3
|
-
import { Icon } from "../Icon/Icon.js";
|
|
4
|
-
const
|
|
5
|
-
name = "Attachment Name",
|
|
6
|
-
options,
|
|
7
|
-
...
|
|
8
|
-
},
|
|
9
|
-
/* @__PURE__ */
|
|
10
|
-
/* @__PURE__ */
|
|
11
|
-
|
|
1
|
+
import { jsxs as c, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as s } from "react";
|
|
3
|
+
import { Icon as i } from "../Icon/Icon.js";
|
|
4
|
+
const l = /* @__PURE__ */ s(({
|
|
5
|
+
name: a = "Attachment Name",
|
|
6
|
+
options: t,
|
|
7
|
+
...r
|
|
8
|
+
}, m) => /* @__PURE__ */ c("div", { ref: m, className: "attachment px-12 py-8", ...r, children: [
|
|
9
|
+
/* @__PURE__ */ e(i, { name: "paperclip", size: "22" }),
|
|
10
|
+
/* @__PURE__ */ e("div", { className: "filename text-truncate", children: a }),
|
|
11
|
+
t && /* @__PURE__ */ e("div", { className: "options ps-12", children: t })
|
|
12
12
|
] }));
|
|
13
13
|
export {
|
|
14
|
-
Attachment,
|
|
15
|
-
|
|
14
|
+
l as Attachment,
|
|
15
|
+
l as default
|
|
16
16
|
};
|
|
17
|
+
//# sourceMappingURL=Attachment.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Attachment.js","sources":["../../../src/components/Attachment/Attachment.tsx"],"sourcesContent":["import { ComponentPropsWithRef, forwardRef, ReactNode, Ref } from 'react';\nimport { Icon } from '..';\n\nexport interface AttachmentProps extends ComponentPropsWithRef<'div'> {\n /**\n * Name of resource or Folder\n * */\n name?: string;\n /**\n * Actions attachment\n * */\n options: ReactNode | undefined;\n}\n\nexport type AttachmentType = AttachmentProps;\n\nexport const Attachment = forwardRef(\n (\n { name = 'Attachment Name', options, ...restProps }: AttachmentProps,\n ref: Ref<HTMLDivElement>,\n ) => {\n return (\n <div ref={ref} className=\"attachment px-12 py-8\" {...restProps}>\n <Icon name=\"paperclip\" size=\"22\" />\n <div className=\"filename text-truncate\">{name}</div>\n {options && <div className=\"options ps-12\">{options}</div>}\n </div>\n );\n },\n);\n\nAttachment.displayName = 'Attachment';\n\nexport default Attachment;\n"],"names":["Attachment","name","options","restProps","ref","jsx","Icon"],"mappings":";;;AAgBaA,MAAAA,sBACX,CACE;AAAA,EAAEC,MAAAA,IAAO;AAAA,EAAmBC,SAAAA;AAAAA,EAAS,GAAGC;AAA2B,GACnEC,wBAGG,OAAI,EAAA,KAAAA,GAAU,WAAU,yBAAwB,GAAID,GACnD,UAAA;AAAA,EAAA,gBAAAE,EAACC,GAAK,EAAA,MAAK,aAAY,MAAK,MAAI;AAAA,EAC/B,gBAAAD,EAAA,OAAA,EAAI,WAAU,0BAA0BJ,UAAKA,GAAA;AAAA,EAC7CC,KAAW,gBAAAG,EAAC,OAAI,EAAA,WAAU,iBAAiBH,UAAQA,GAAA;AACtD,EAAA,CAAA,CAGN;"}
|
|
@@ -1,34 +1,35 @@
|
|
|
1
|
-
import { jsx } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef } from "react";
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import { Image } from "../Image/Image.js";
|
|
6
|
-
const
|
|
7
|
-
variant = "square",
|
|
8
|
-
size = "md",
|
|
9
|
-
alt,
|
|
10
|
-
src,
|
|
11
|
-
imgPlaceholder,
|
|
12
|
-
className,
|
|
13
|
-
...
|
|
14
|
-
},
|
|
15
|
-
const [
|
|
1
|
+
import { jsx as t } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as u } from "react";
|
|
3
|
+
import v from "clsx";
|
|
4
|
+
import f from "../../core/usePaths/usePaths.js";
|
|
5
|
+
import { Image as p } from "../Image/Image.js";
|
|
6
|
+
const w = /* @__PURE__ */ u(({
|
|
7
|
+
variant: r = "square",
|
|
8
|
+
size: a = "md",
|
|
9
|
+
alt: o,
|
|
10
|
+
src: e,
|
|
11
|
+
imgPlaceholder: c,
|
|
12
|
+
className: d,
|
|
13
|
+
...m
|
|
14
|
+
}, i) => {
|
|
15
|
+
const [l] = f(), s = c || `${l}/avatar/no-avatar.svg`, n = v("avatar", {
|
|
16
16
|
...{
|
|
17
|
-
"avatar-xs":
|
|
18
|
-
"avatar-sm":
|
|
19
|
-
"avatar-md":
|
|
20
|
-
"avatar-lg":
|
|
21
|
-
"avatar-xl":
|
|
17
|
+
"avatar-xs": a === "xs",
|
|
18
|
+
"avatar-sm": a === "sm",
|
|
19
|
+
"avatar-md": a === "md",
|
|
20
|
+
"avatar-lg": a === "lg",
|
|
21
|
+
"avatar-xl": a === "xl"
|
|
22
22
|
},
|
|
23
23
|
...{
|
|
24
|
-
square:
|
|
25
|
-
rounded:
|
|
26
|
-
"rounded-circle":
|
|
24
|
+
square: r === "square",
|
|
25
|
+
rounded: r === "rounded",
|
|
26
|
+
"rounded-circle": r === "circle"
|
|
27
27
|
}
|
|
28
|
-
},
|
|
29
|
-
return /* @__PURE__ */
|
|
28
|
+
}, d);
|
|
29
|
+
return /* @__PURE__ */ t("div", { ref: i, className: n, children: /* @__PURE__ */ t(p, { src: e || s, alt: o, imgPlaceholder: s, ...m }) });
|
|
30
30
|
});
|
|
31
31
|
export {
|
|
32
|
-
Avatar,
|
|
33
|
-
|
|
32
|
+
w as Avatar,
|
|
33
|
+
w as default
|
|
34
34
|
};
|
|
35
|
+
//# sourceMappingURL=Avatar.js.map
|