@antscorp/antsomi-ui 2.0.110 → 2.0.112
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/es/assets/css/main.scss +2 -0
- package/es/components/atoms/Eyedropper/Eyedropper.d.ts +2 -0
- package/es/components/atoms/Eyedropper/Eyedropper.js +53 -0
- package/es/components/atoms/Eyedropper/index.d.ts +0 -0
- package/es/components/atoms/Eyedropper/index.js +1 -0
- package/es/components/atoms/Eyedropper/styled.d.ts +9 -0
- package/es/components/atoms/Eyedropper/styled.js +45 -0
- package/es/components/atoms/Eyedropper/types.d.ts +5 -0
- package/es/components/atoms/Eyedropper/types.js +1 -0
- package/es/components/icons/ALignRightIcon.d.ts +3 -0
- package/es/components/icons/ALignRightIcon.js +7 -0
- package/es/components/icons/AlignCenterIcon.d.ts +3 -0
- package/es/components/icons/AlignCenterIcon.js +7 -0
- package/es/components/icons/AlignJustifyIcon.d.ts +3 -0
- package/es/components/icons/AlignJustifyIcon.js +7 -0
- package/es/components/icons/AlignLeftIcon.d.ts +3 -0
- package/es/components/icons/AlignLeftIcon.js +7 -0
- package/es/components/icons/ArrowDropDownIcon.d.ts +3 -0
- package/es/components/icons/ArrowDropDownIcon.js +7 -0
- package/es/components/icons/ChevronRightIcon.d.ts +3 -0
- package/es/components/icons/ChevronRightIcon.js +7 -0
- package/es/components/icons/ColorizeIcon.d.ts +3 -0
- package/es/components/icons/ColorizeIcon.js +7 -0
- package/es/components/icons/LazyIcon/LazyIcon.d.ts +9 -0
- package/es/components/icons/LazyIcon/LazyIcon.js +9 -0
- package/es/components/icons/LinkOffIcon.d.ts +3 -0
- package/es/components/icons/LinkOffIcon.js +7 -0
- package/es/components/icons/MinusIcon.d.ts +3 -0
- package/es/components/icons/MinusIcon.js +7 -0
- package/es/components/icons/index.d.ts +9 -0
- package/es/components/icons/index.js +9 -0
- package/es/components/index.scss +1 -0
- package/es/components/molecules/EmojiCollections/CommonCollection/index.js +2 -2
- package/es/components/molecules/EmojiCollections/types.d.ts +1 -0
- package/es/components/molecules/EmojiPopover/EmojiPopover.d.ts +2 -0
- package/es/components/molecules/EmojiPopover/EmojiPopover.js +10 -6
- package/es/components/molecules/EmojiPopover/styled.js +1 -1
- package/es/components/molecules/EyedropperButton/EyedropperButton.d.ts +11 -0
- package/es/components/molecules/EyedropperButton/EyedropperButton.js +34 -0
- package/es/components/molecules/EyedropperButton/index.d.ts +0 -0
- package/es/components/molecules/EyedropperButton/index.js +1 -0
- package/es/components/molecules/EyedropperButton/styled.d.ts +7 -0
- package/es/components/molecules/EyedropperButton/styled.js +23 -0
- package/es/components/molecules/FontSizeInput/FontSizeInput.d.ts +3 -0
- package/es/components/molecules/FontSizeInput/FontSizeInput.js +134 -0
- package/es/components/molecules/FontSizeInput/components/FontSizeControl.d.ts +8 -0
- package/es/components/molecules/FontSizeInput/components/FontSizeControl.js +14 -0
- package/es/components/molecules/FontSizeInput/components/FontSizeDropdown.d.ts +21 -0
- package/es/components/molecules/FontSizeInput/components/FontSizeDropdown.js +19 -0
- package/es/components/molecules/FontSizeInput/constants.d.ts +2 -0
- package/es/components/molecules/FontSizeInput/constants.js +5 -0
- package/es/components/molecules/FontSizeInput/index.d.ts +2 -0
- package/es/components/molecules/FontSizeInput/index.js +1 -0
- package/es/components/molecules/FontSizeInput/styled.d.ts +7 -0
- package/es/components/molecules/FontSizeInput/styled.js +39 -0
- package/es/components/molecules/FontSizeInput/types.d.ts +23 -0
- package/es/components/molecules/FontSizeInput/types.js +1 -0
- package/es/components/molecules/FontSizeInput/utils.d.ts +7 -0
- package/es/components/molecules/FontSizeInput/utils.js +9 -0
- package/es/components/molecules/SearchPopover/SearchPopover.d.ts +2 -1
- package/es/components/molecules/SearchPopover/SearchPopover.js +3 -3
- package/es/components/molecules/SearchPopover/styled.d.ts +12 -1
- package/es/components/molecules/SearchPopover/styled.js +1 -2
- package/es/components/molecules/SearchPopover/types.d.ts +4 -3
- package/es/components/molecules/VirtualizedMenu/VirtualizedMenu.d.ts +1 -0
- package/es/components/molecules/VirtualizedMenu/components/Item/Item.js +6 -8
- package/es/components/molecules/VirtualizedMenu/components/MenuInline/MenuInline.d.ts +10 -10
- package/es/components/molecules/VirtualizedMenu/components/MenuInline/MenuInline.js +49 -289
- package/es/components/molecules/VirtualizedMenu/components/MenuInline/hooks/index.d.ts +9 -0
- package/es/components/molecules/VirtualizedMenu/components/MenuInline/hooks/index.js +5 -0
- package/es/components/molecules/VirtualizedMenu/components/MenuInline/hooks/useFocusManagement.d.ts +23 -0
- package/es/components/molecules/VirtualizedMenu/components/MenuInline/hooks/useFocusManagement.js +81 -0
- package/es/components/molecules/VirtualizedMenu/components/MenuInline/hooks/useItemInteraction.d.ts +24 -0
- package/es/components/molecules/VirtualizedMenu/components/MenuInline/hooks/useItemInteraction.js +32 -0
- package/es/components/molecules/VirtualizedMenu/components/MenuInline/hooks/useKeyboardNavigation.d.ts +26 -0
- package/es/components/molecules/VirtualizedMenu/components/MenuInline/hooks/useKeyboardNavigation.js +93 -0
- package/es/components/molecules/VirtualizedMenu/components/MenuInline/hooks/useTreeState.d.ts +24 -0
- package/es/components/molecules/VirtualizedMenu/components/MenuInline/hooks/useTreeState.js +94 -0
- package/es/components/molecules/VirtualizedMenu/components/MenuInline/hooks/useVisibleItems.d.ts +7 -0
- package/es/components/molecules/VirtualizedMenu/components/MenuInline/hooks/useVisibleItems.js +132 -0
- package/es/components/molecules/VirtualizedMenu/styled.js +24 -3
- package/es/components/molecules/VirtualizedMenu/types.d.ts +2 -0
- package/es/components/molecules/VirtualizedMenu/utils.d.ts +2 -0
- package/es/components/molecules/VirtualizedMenu/utils.js +2 -0
- package/es/components/molecules/index.d.ts +1 -0
- package/es/components/molecules/index.js +1 -0
- package/es/components/molecules/index.scss +1 -0
- package/es/components/organism/TextEditor/TextEditor.d.ts +10 -0
- package/es/components/organism/TextEditor/TextEditor.js +403 -0
- package/es/components/organism/TextEditor/__mocks__/text-block.settings.json +320 -0
- package/es/components/organism/TextEditor/__mocks__/text-contennt.d.ts +1 -0
- package/es/components/organism/TextEditor/__mocks__/text-contennt.js +47 -0
- package/es/components/organism/TextEditor/constants.d.ts +196 -0
- package/es/components/organism/TextEditor/constants.js +398 -0
- package/es/components/organism/TextEditor/extensions/BackgroundColor.d.ts +25 -0
- package/es/components/organism/TextEditor/extensions/BackgroundColor.js +43 -0
- package/es/components/organism/TextEditor/extensions/BubbleMenu/bubble-menu-plugin.d.ts +18 -0
- package/es/components/organism/TextEditor/extensions/BubbleMenu/bubble-menu-plugin.js +81 -0
- package/es/components/organism/TextEditor/extensions/BubbleMenu/bubble-menu.d.ts +15 -0
- package/es/components/organism/TextEditor/extensions/BubbleMenu/bubble-menu.js +35 -0
- package/es/components/organism/TextEditor/extensions/BubbleMenu/index.d.ts +2 -0
- package/es/components/organism/TextEditor/extensions/BubbleMenu/index.js +2 -0
- package/es/components/organism/TextEditor/extensions/ClearFormatting.d.ts +16 -0
- package/es/components/organism/TextEditor/extensions/ClearFormatting.js +30 -0
- package/es/components/organism/TextEditor/extensions/Color.d.ts +6 -0
- package/es/components/organism/TextEditor/extensions/Color.js +34 -0
- package/es/components/organism/TextEditor/extensions/Emoji.d.ts +57 -0
- package/es/components/organism/TextEditor/extensions/Emoji.js +184 -0
- package/es/components/organism/TextEditor/extensions/FontFamily.d.ts +6 -0
- package/es/components/organism/TextEditor/extensions/FontFamily.js +36 -0
- package/es/components/organism/TextEditor/extensions/FontSize.d.ts +31 -0
- package/es/components/organism/TextEditor/extensions/FontSize.js +46 -0
- package/es/components/organism/TextEditor/extensions/FontWeight.d.ts +23 -0
- package/es/components/organism/TextEditor/extensions/FontWeight.js +41 -0
- package/es/components/organism/TextEditor/extensions/Indent.d.ts +21 -0
- package/es/components/organism/TextEditor/extensions/Indent.js +63 -0
- package/es/components/organism/TextEditor/extensions/LetterSpacing.d.ts +32 -0
- package/es/components/organism/TextEditor/extensions/LetterSpacing.js +48 -0
- package/es/components/organism/TextEditor/extensions/LineHeight.d.ts +20 -0
- package/es/components/organism/TextEditor/extensions/LineHeight.js +101 -0
- package/es/components/organism/TextEditor/extensions/Link.d.ts +22 -0
- package/es/components/organism/TextEditor/extensions/Link.js +197 -0
- package/es/components/organism/TextEditor/extensions/ListItem.d.ts +10 -0
- package/es/components/organism/TextEditor/extensions/ListItem.js +93 -0
- package/es/components/organism/TextEditor/extensions/ListItemMarker.d.ts +13 -0
- package/es/components/organism/TextEditor/extensions/ListItemMarker.js +174 -0
- package/es/components/organism/TextEditor/extensions/OrderedList.d.ts +56 -0
- package/es/components/organism/TextEditor/extensions/OrderedList.js +187 -0
- package/es/components/organism/TextEditor/extensions/SmartTag.d.ts +33 -0
- package/es/components/organism/TextEditor/extensions/SmartTag.js +194 -0
- package/es/components/organism/TextEditor/extensions/StyleMemory.d.ts +36 -0
- package/es/components/organism/TextEditor/extensions/StyleMemory.js +163 -0
- package/es/components/organism/TextEditor/extensions/TextTransform.d.ts +30 -0
- package/es/components/organism/TextEditor/extensions/TextTransform.js +36 -0
- package/es/components/organism/TextEditor/extensions/UnorderedList.d.ts +55 -0
- package/es/components/organism/TextEditor/extensions/UnorderedList.js +176 -0
- package/es/components/organism/TextEditor/hooks/index.d.ts +6 -0
- package/es/components/organism/TextEditor/hooks/index.js +6 -0
- package/es/components/organism/TextEditor/hooks/useColorSet.d.ts +4 -0
- package/es/components/organism/TextEditor/hooks/useColorSet.js +29 -0
- package/es/components/organism/TextEditor/hooks/useDocumentState.d.ts +18 -0
- package/es/components/organism/TextEditor/hooks/useDocumentState.js +42 -0
- package/es/components/organism/TextEditor/hooks/useMarkTracking.d.ts +26 -0
- package/es/components/organism/TextEditor/hooks/useMarkTracking.js +69 -0
- package/es/components/organism/TextEditor/hooks/usePersistence.d.ts +31 -0
- package/es/components/organism/TextEditor/hooks/usePersistence.js +169 -0
- package/es/components/organism/TextEditor/hooks/useStyleMemory.d.ts +6 -0
- package/es/components/organism/TextEditor/hooks/useStyleMemory.js +42 -0
- package/es/components/organism/TextEditor/hooks/useStylePresets.d.ts +34 -0
- package/es/components/organism/TextEditor/hooks/useStylePresets.js +83 -0
- package/es/components/organism/TextEditor/index.d.ts +18 -0
- package/es/components/organism/TextEditor/index.js +8 -0
- package/es/components/organism/TextEditor/index.scss +65 -0
- package/es/components/organism/TextEditor/provider.d.ts +15 -0
- package/es/components/organism/TextEditor/provider.js +36 -0
- package/es/components/organism/TextEditor/store.d.ts +20 -0
- package/es/components/organism/TextEditor/store.js +40 -0
- package/es/components/organism/TextEditor/stories/WithOldDynAndLink/froala-legacy-format.settings.json +95 -0
- package/es/components/organism/TextEditor/stories/WithOldDynAndLink/shared.d.ts +111 -0
- package/es/components/organism/TextEditor/stories/WithOldDynAndLink/shared.js +82 -0
- package/es/components/organism/TextEditor/stories/shared.d.ts +64 -0
- package/es/components/organism/TextEditor/stories/shared.js +57 -0
- package/es/components/organism/TextEditor/styled.d.ts +9 -0
- package/es/components/organism/TextEditor/styled.js +61 -0
- package/es/components/organism/TextEditor/types.d.ts +324 -0
- package/es/components/organism/TextEditor/types.js +6 -0
- package/es/components/organism/TextEditor/ui/BubbleMenu/BubbleMenu.d.ts +3 -0
- package/es/components/organism/TextEditor/ui/BubbleMenu/BubbleMenu.js +114 -0
- package/es/components/organism/TextEditor/ui/BubbleMenu/index.d.ts +1 -0
- package/es/components/organism/TextEditor/ui/BubbleMenu/index.js +1 -0
- package/es/components/organism/TextEditor/ui/Button/Button.d.ts +9 -0
- package/es/components/organism/TextEditor/ui/Button/Button.js +35 -0
- package/es/components/organism/TextEditor/ui/Button/index.d.ts +2 -0
- package/es/components/organism/TextEditor/ui/Button/index.js +1 -0
- package/es/components/organism/TextEditor/ui/Button/types.d.ts +10 -0
- package/es/components/organism/TextEditor/ui/Button/types.js +1 -0
- package/es/components/organism/TextEditor/ui/ColorPicker/ColorPicker.d.ts +39 -0
- package/es/components/organism/TextEditor/ui/ColorPicker/ColorPicker.js +131 -0
- package/es/components/organism/TextEditor/ui/ColorPicker/index.d.ts +1 -0
- package/es/components/organism/TextEditor/ui/ColorPicker/index.js +1 -0
- package/es/components/organism/TextEditor/ui/DropdownButton/DropdownButton.d.ts +17 -0
- package/es/components/organism/TextEditor/ui/DropdownButton/DropdownButton.js +51 -0
- package/es/components/organism/TextEditor/ui/DropdownButton/index.d.ts +1 -0
- package/es/components/organism/TextEditor/ui/DropdownButton/index.js +1 -0
- package/es/components/organism/TextEditor/ui/Emoji/EmojiList.d.ts +11 -0
- package/es/components/organism/TextEditor/ui/Emoji/EmojiList.js +66 -0
- package/es/components/organism/TextEditor/ui/Emoji/index.d.ts +2 -0
- package/es/components/organism/TextEditor/ui/Emoji/index.js +2 -0
- package/es/components/organism/TextEditor/ui/Emoji/suggestion.d.ts +4 -0
- package/es/components/organism/TextEditor/ui/Emoji/suggestion.js +71 -0
- package/es/components/organism/TextEditor/ui/FontPopover/FontItem.d.ts +2 -0
- package/es/components/organism/TextEditor/ui/FontPopover/FontItem.js +27 -0
- package/es/components/organism/TextEditor/ui/FontPopover/FontPopover.d.ts +16 -0
- package/es/components/organism/TextEditor/ui/FontPopover/FontPopover.js +102 -0
- package/es/components/organism/TextEditor/ui/FontPopover/styled.d.ts +2 -0
- package/es/components/organism/TextEditor/ui/FontPopover/styled.js +36 -0
- package/es/components/organism/TextEditor/ui/FontPopover/types.d.ts +35 -0
- package/es/components/organism/TextEditor/ui/FontPopover/types.js +1 -0
- package/es/components/organism/TextEditor/ui/LinkInsertForm/LinkInsertForm.d.ts +16 -0
- package/es/components/organism/TextEditor/ui/LinkInsertForm/LinkInsertForm.js +61 -0
- package/es/components/organism/TextEditor/ui/LinkInsertForm/index.d.ts +2 -0
- package/es/components/organism/TextEditor/ui/LinkInsertForm/index.js +1 -0
- package/es/components/organism/TextEditor/ui/LinkPopover/LinkPopover.d.ts +9 -0
- package/es/components/organism/TextEditor/ui/LinkPopover/LinkPopover.js +126 -0
- package/es/components/organism/TextEditor/ui/LinkPopover/index.d.ts +2 -0
- package/es/components/organism/TextEditor/ui/LinkPopover/index.js +1 -0
- package/es/components/organism/TextEditor/ui/Popover/Popover.d.ts +6 -0
- package/es/components/organism/TextEditor/ui/Popover/Popover.js +9 -0
- package/es/components/organism/TextEditor/ui/Popover/index.d.ts +1 -0
- package/es/components/organism/TextEditor/ui/Popover/index.js +1 -0
- package/es/components/organism/TextEditor/ui/Select/Select.d.ts +4 -0
- package/es/components/organism/TextEditor/ui/Select/Select.js +7 -0
- package/es/components/organism/TextEditor/ui/Select/index.d.ts +1 -0
- package/es/components/organism/TextEditor/ui/Select/index.js +1 -0
- package/es/components/organism/TextEditor/ui/SplitButtonDropdown/SplitButtonDropdown.d.ts +2 -0
- package/es/components/organism/TextEditor/ui/SplitButtonDropdown/SplitButtonDropdown.js +44 -0
- package/es/components/organism/TextEditor/ui/SplitButtonDropdown/index.d.ts +1 -0
- package/es/components/organism/TextEditor/ui/SplitButtonDropdown/index.js +1 -0
- package/es/components/organism/TextEditor/ui/SplitButtonDropdown/styled.d.ts +2 -0
- package/es/components/organism/TextEditor/ui/SplitButtonDropdown/styled.js +58 -0
- package/es/components/organism/TextEditor/ui/SplitButtonDropdown/types.d.ts +19 -0
- package/es/components/organism/TextEditor/ui/SplitButtonDropdown/types.js +1 -0
- package/es/components/organism/TextEditor/ui/TextAlignSelect/TextAlignSelect.d.ts +30 -0
- package/es/components/organism/TextEditor/ui/TextAlignSelect/TextAlignSelect.js +75 -0
- package/es/components/organism/TextEditor/ui/TextAlignSelect/index.d.ts +1 -0
- package/es/components/organism/TextEditor/ui/TextAlignSelect/index.js +1 -0
- package/es/components/organism/TextEditor/ui/Toolbar/FormattingToolbar.d.ts +19 -0
- package/es/components/organism/TextEditor/ui/Toolbar/FormattingToolbar.js +85 -0
- package/es/components/organism/TextEditor/ui/Toolbar/LinkPreviewToolbar.d.ts +10 -0
- package/es/components/organism/TextEditor/ui/Toolbar/LinkPreviewToolbar.js +39 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/BoldAction.d.ts +6 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/BoldAction.js +19 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/BulletListAction.d.ts +6 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/BulletListAction.js +93 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/ClearFormattingAction.d.ts +5 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/ClearFormattingAction.js +20 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/EmojiAction.d.ts +4 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/EmojiAction.js +32 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/FontFamilyAction.d.ts +19 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/FontFamilyAction.js +41 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/FontSizeAction.d.ts +8 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/FontSizeAction.js +51 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/HistoryAction.d.ts +5 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/HistoryAction.js +21 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/IndentAction.d.ts +5 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/IndentAction.js +17 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/ItalicAction.d.ts +5 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/ItalicAction.js +18 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/LetterSpacing.d.ts +5 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/LetterSpacing.js +28 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/LineSpacingAction.d.ts +10 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/LineSpacingAction.js +45 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/LinkAction.d.ts +6 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/LinkAction.js +17 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/OrderedListAction.d.ts +5 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/OrderedListAction.js +67 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/OutdentAction.d.ts +5 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/OutdentAction.js +17 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/SmartTagAction.d.ts +7 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/SmartTagAction.js +18 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/StrikeAction.d.ts +5 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/StrikeAction.js +18 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/SubscriptAction.d.ts +5 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/SubscriptAction.js +26 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/SuperscriptAction.d.ts +5 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/SuperscriptAction.js +26 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/TextAlignAction.d.ts +5 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/TextAlignAction.js +3 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/TextBackgroundColorAction.d.ts +5 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/TextBackgroundColorAction.js +29 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/TextColorAction.d.ts +14 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/TextColorAction.js +22 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/TextTransformAction.d.ts +5 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/TextTransformAction.js +36 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/UnderlineAction.d.ts +5 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/UnderlineAction.js +18 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/UnsetLink.d.ts +7 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/UnsetLink.js +18 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/index.d.ts +24 -0
- package/es/components/organism/TextEditor/ui/Toolbar/actions/index.js +24 -0
- package/es/components/organism/TextEditor/ui/Toolbar/index.d.ts +2 -0
- package/es/components/organism/TextEditor/ui/Toolbar/index.js +2 -0
- package/es/components/organism/TextEditor/utils/documentState.d.ts +73 -0
- package/es/components/organism/TextEditor/utils/documentState.js +149 -0
- package/es/components/organism/TextEditor/utils/font.d.ts +74 -0
- package/es/components/organism/TextEditor/utils/font.js +147 -0
- package/es/components/organism/TextEditor/utils/htmlProcessing.d.ts +87 -0
- package/es/components/organism/TextEditor/utils/htmlProcessing.js +460 -0
- package/es/components/organism/TextEditor/utils/indent.d.ts +11 -0
- package/es/components/organism/TextEditor/utils/indent.js +56 -0
- package/es/components/organism/TextEditor/utils/index.d.ts +8 -0
- package/es/components/organism/TextEditor/utils/index.js +16 -0
- package/es/components/organism/TextEditor/utils/link.d.ts +116 -0
- package/es/components/organism/TextEditor/utils/link.js +304 -0
- package/es/components/organism/TextEditor/utils/menu.d.ts +134 -0
- package/es/components/organism/TextEditor/utils/menu.js +321 -0
- package/es/components/organism/TextEditor/utils/selection.d.ts +25 -0
- package/es/components/organism/TextEditor/utils/selection.js +58 -0
- package/es/components/organism/TextEditor/utils/shared.d.ts +13 -0
- package/es/components/organism/TextEditor/utils/shared.js +52 -0
- package/es/components/organism/TextEditor/utils/smartTag.d.ts +49 -0
- package/es/components/organism/TextEditor/utils/smartTag.js +90 -0
- package/es/components/organism/TextEditor/utils/style.d.ts +78 -0
- package/es/components/organism/TextEditor/utils/style.js +193 -0
- package/es/components/organism/index.d.ts +1 -0
- package/es/components/organism/index.js +1 -0
- package/es/components/organism/index.scss +1 -0
- package/es/constants/index.d.ts +1 -0
- package/es/constants/index.js +1 -0
- package/es/constants/web.d.ts +8 -0
- package/es/constants/web.js +57 -0
- package/es/hooks/index.d.ts +4 -0
- package/es/hooks/index.js +4 -0
- package/es/hooks/useBroadcastedLocalStorage.d.ts +5 -0
- package/es/hooks/useBroadcastedLocalStorage.js +71 -0
- package/es/hooks/useElementSize.d.ts +7 -0
- package/es/hooks/useElementSize.js +56 -0
- package/es/hooks/useEyedropper/attach.d.ts +4 -0
- package/es/hooks/useEyedropper/attach.js +9 -0
- package/es/hooks/useEyedropper/eyedropper.d.ts +69 -0
- package/es/hooks/useEyedropper/eyedropper.js +205 -0
- package/es/hooks/useEyedropper/index.d.ts +2 -0
- package/es/hooks/useEyedropper/index.js +7 -0
- package/es/hooks/useEyedropper/support.d.ts +1 -0
- package/es/hooks/useEyedropper/support.js +3 -0
- package/es/hooks/useEyedropper/types.d.ts +9 -0
- package/es/hooks/useEyedropper/types.js +1 -0
- package/es/hooks/useEyedropper/useEyedropper.d.ts +8 -0
- package/es/hooks/useEyedropper/useEyedropper.js +50 -0
- package/es/hooks/useEyedropper/utils.d.ts +11 -0
- package/es/hooks/useEyedropper/utils.js +17 -0
- package/es/hooks/useIsMounted.d.ts +1 -0
- package/es/hooks/useIsMounted.js +11 -0
- package/es/index.d.ts +1 -1
- package/es/index.js +1 -1
- package/es/locales/i18n.d.ts +1 -1
- package/es/types/index.d.ts +9 -0
- package/es/utils/common.d.ts +15 -9
- package/es/utils/common.js +62 -24
- package/es/utils/index.d.ts +1 -0
- package/es/utils/index.js +1 -0
- package/es/utils/web.d.ts +80 -0
- package/es/utils/web.js +226 -0
- package/package.json +26 -17
package/es/assets/css/main.scss
CHANGED
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { useEffect, useState } from 'react';
|
|
3
|
+
import { Typography, message } from 'antd';
|
|
4
|
+
import { BgColorsOutlined } from '@ant-design/icons'; // Icon hình giọt nước
|
|
5
|
+
import { ColorSwatch, StyledButton, StyledColorTag, StyledEyedropperContainer } from './styled';
|
|
6
|
+
import tinycolor from 'tinycolor2';
|
|
7
|
+
import clsx from 'clsx';
|
|
8
|
+
const { Text } = Typography;
|
|
9
|
+
export const Eyedropper = (props) => {
|
|
10
|
+
const { defaultColor, onColorPick, className } = props;
|
|
11
|
+
const [pickedColor, setPickedColor] = useState(defaultColor);
|
|
12
|
+
const [isLoading, setIsLoading] = useState(false);
|
|
13
|
+
const apiSupported = 'EyeDropper' in window;
|
|
14
|
+
// Cập nhật màu mặc định nếu prop thay đổi
|
|
15
|
+
useEffect(() => {
|
|
16
|
+
setPickedColor(defaultColor);
|
|
17
|
+
}, [defaultColor]);
|
|
18
|
+
const handlePickColor = async () => {
|
|
19
|
+
if (!apiSupported) {
|
|
20
|
+
message.error('Trình duyệt của bạn không hỗ trợ EyeDropper API.');
|
|
21
|
+
return;
|
|
22
|
+
}
|
|
23
|
+
setIsLoading(true);
|
|
24
|
+
try {
|
|
25
|
+
const eyeDropper = new window.EyeDropper();
|
|
26
|
+
const { sRGBHex } = await eyeDropper.open();
|
|
27
|
+
setPickedColor(sRGBHex);
|
|
28
|
+
message.success(`Đã chọn màu: ${sRGBHex}`);
|
|
29
|
+
onColorPick?.(sRGBHex);
|
|
30
|
+
}
|
|
31
|
+
catch (e) {
|
|
32
|
+
if (e instanceof Error && e.name === 'AbortError') {
|
|
33
|
+
message.info('Người dùng đã hủy chọn màu.');
|
|
34
|
+
}
|
|
35
|
+
else if (e instanceof Error) {
|
|
36
|
+
message.error(`Đã xảy ra lỗi khi chọn màu: ${e.message}`);
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
finally {
|
|
40
|
+
setIsLoading(false);
|
|
41
|
+
}
|
|
42
|
+
};
|
|
43
|
+
const isCurrentColorLight = tinycolor(pickedColor).isLight();
|
|
44
|
+
return (_jsxs(StyledEyedropperContainer, { className: className, children: [_jsxs(Typography.Title, { level: 4, children: [_jsx(BgColorsOutlined, {}), " C\u00F4ng c\u1EE5 tr\u00EDch xu\u1EA5t m\u00E0u"] }), _jsx(Text, { type: "secondary", children: "B\u1EA5m n\u00FAt b\u00EAn d\u01B0\u1EDBi \u0111\u1EC3 k\u00EDch ho\u1EA1t c\u00F4ng c\u1EE5 Eyedropper c\u1EE7a tr\u00ECnh duy\u1EC7t v\u00E0 ch\u1ECDn m\u00E0u t\u1EEB b\u1EA5t k\u1EF3 \u0111\u00E2u tr\u00EAn m\u00E0n h\u00ECnh." }), _jsx(StyledButton, { type: "primary", icon: _jsx(BgColorsOutlined, {}), onClick: handlePickColor, loading: isLoading, disabled: isLoading || !apiSupported, size: "large", children: "Ch\u1ECDn M\u00E0u" }), pickedColor && (_jsxs("div", { style: {
|
|
45
|
+
marginTop: '20px',
|
|
46
|
+
display: 'flex',
|
|
47
|
+
justifyContent: 'center',
|
|
48
|
+
alignItems: 'center',
|
|
49
|
+
gap: '10px',
|
|
50
|
+
}, children: [_jsx(Text, { children: "M\u00E0u \u0111\u00E3 ch\u1ECDn:" }), _jsx(StyledColorTag, { color: pickedColor, className: clsx({
|
|
51
|
+
'is-lightcolor': isCurrentColorLight,
|
|
52
|
+
}), children: pickedColor }), _jsx(ColorSwatch, { "$color": pickedColor })] })), !apiSupported && (_jsx(Text, { type: "danger", style: { marginTop: '15px', display: 'block' }, children: "Tr\u00ECnh duy\u1EC7t hi\u1EC7n t\u1EA1i kh\u00F4ng h\u1ED7 tr\u1EE3 EyeDropper API. Vui l\u00F2ng s\u1EED d\u1EE5ng Chrome, Edge ho\u1EB7c c\u00E1c tr\u00ECnh duy\u1EC7t d\u1EF1a tr\u00EAn Chromium." }))] }));
|
|
53
|
+
};
|
|
File without changes
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare const StyledEyedropperContainer: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
3
|
+
export declare const StyledButton: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<import("antd").ButtonProps & import("react").RefAttributes<HTMLElement>> & {
|
|
4
|
+
Group: import("react").FC<import("antd/es/button").ButtonGroupProps>;
|
|
5
|
+
}, any, {}, never>;
|
|
6
|
+
export declare const StyledColorTag: import("styled-components").StyledComponent<import("antd").TagType, any, {}, never>;
|
|
7
|
+
export declare const ColorSwatch: import("styled-components").StyledComponent<"div", any, {
|
|
8
|
+
$color: string;
|
|
9
|
+
}, never>;
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { Button, Tag } from 'antd';
|
|
2
|
+
import styled from 'styled-components';
|
|
3
|
+
export const StyledEyedropperContainer = styled.div `
|
|
4
|
+
padding: 20px;
|
|
5
|
+
border: 1px solid #e8e8e8;
|
|
6
|
+
border-radius: 8px;
|
|
7
|
+
max-width: 450px;
|
|
8
|
+
margin: 20px auto;
|
|
9
|
+
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.09);
|
|
10
|
+
text-align: center; /* Căn giữa nội dung */
|
|
11
|
+
|
|
12
|
+
h4 {
|
|
13
|
+
margin-bottom: 15px;
|
|
14
|
+
color: #333;
|
|
15
|
+
display: flex;
|
|
16
|
+
align-items: center;
|
|
17
|
+
justify-content: center; /* Căn giữa icon và tiêu đề */
|
|
18
|
+
gap: 8px; /* Khoảng cách giữa icon và chữ */
|
|
19
|
+
}
|
|
20
|
+
`;
|
|
21
|
+
export const StyledButton = styled(Button) `
|
|
22
|
+
margin-top: 20px;
|
|
23
|
+
width: auto; /* Để nút không bị giãn full chiều rộng */
|
|
24
|
+
`;
|
|
25
|
+
export const StyledColorTag = styled(Tag) `
|
|
26
|
+
padding: 4px 8px;
|
|
27
|
+
font-size: 1em;
|
|
28
|
+
font-weight: bold;
|
|
29
|
+
min-width: 100px;
|
|
30
|
+
text-align: center;
|
|
31
|
+
border: none;
|
|
32
|
+
color: white;
|
|
33
|
+
|
|
34
|
+
&.is-lightcolor {
|
|
35
|
+
border: 1px solid #d9d9d9;
|
|
36
|
+
color: #333;
|
|
37
|
+
}
|
|
38
|
+
`;
|
|
39
|
+
export const ColorSwatch = styled.div `
|
|
40
|
+
width: 30px;
|
|
41
|
+
height: 30px;
|
|
42
|
+
background-color: ${props => props.$color || 'transparent'}; /* Nhận prop $color */
|
|
43
|
+
border: 1px solid #d9d9d9;
|
|
44
|
+
border-radius: 4px;
|
|
45
|
+
`;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef } from 'react';
|
|
3
|
+
import { useIcon } from './hooks/useIcon';
|
|
4
|
+
export const ALignRightIcon = forwardRef((props, ref) => {
|
|
5
|
+
const { width, height } = useIcon(props);
|
|
6
|
+
return (_jsx("svg", { viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...props, ref: ref, width: width, height: height, children: _jsx("path", { d: "M3 21H21V19H3V21ZM9 17H21V15H9V17ZM3 13H21V11H3V13ZM9 9H21V7H9V9ZM3 3V5H21V3H3Z", fill: "currentColor" }) }));
|
|
7
|
+
});
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef } from 'react';
|
|
3
|
+
import { useIcon } from './hooks/useIcon';
|
|
4
|
+
export const AlignCenterIcon = forwardRef((props, ref) => {
|
|
5
|
+
const { width, height } = useIcon(props);
|
|
6
|
+
return (_jsx("svg", { viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...props, ref: ref, width: width, height: height, children: _jsx("path", { d: "M7 15V17H17V15H7ZM3 21H21V19H3V21ZM3 13H21V11H3V13ZM7 7V9H17V7H7ZM3 3V5H21V3H3Z", fill: "currentColor" }) }));
|
|
7
|
+
});
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef } from 'react';
|
|
3
|
+
import { useIcon } from './hooks/useIcon';
|
|
4
|
+
export const AlignJustifyIcon = forwardRef((props, ref) => {
|
|
5
|
+
const { width, height } = useIcon(props);
|
|
6
|
+
return (_jsx("svg", { viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...props, ref: ref, width: width, height: height, children: _jsx("path", { d: "M3 21H21V19H3V21ZM3 17H21V15H3V17ZM3 13H21V11H3V13ZM3 9H21V7H3V9ZM3 3V5H21V3H3Z", fill: "currentColor" }) }));
|
|
7
|
+
});
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef } from 'react';
|
|
3
|
+
import { useIcon } from './hooks/useIcon';
|
|
4
|
+
export const AlignLeftIcon = forwardRef((props, ref) => {
|
|
5
|
+
const { width, height } = useIcon(props);
|
|
6
|
+
return (_jsx("svg", { viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...props, ref: ref, width: width, height: height, children: _jsx("path", { d: "M15 15H3V17H15V15ZM15 7H3V9H15V7ZM3 13H21V11H3V13ZM3 21H21V19H3V21ZM3 3V5H21V3H3Z", fill: "currentColor" }) }));
|
|
7
|
+
});
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef } from 'react';
|
|
3
|
+
import { useIcon } from './hooks/useIcon';
|
|
4
|
+
export const ArrowDropDownIcon = forwardRef((props, ref) => {
|
|
5
|
+
const { width, height } = useIcon(props);
|
|
6
|
+
return (_jsx("svg", { viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...props, ref: ref, width: width, height: height, children: _jsx("path", { d: "M7 10L12 15L17 10H7Z", fill: "black" }) }));
|
|
7
|
+
});
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef } from 'react';
|
|
3
|
+
import { useIcon } from './hooks/useIcon';
|
|
4
|
+
export const ChevronRightIcon = forwardRef((props, ref) => {
|
|
5
|
+
const { width, height } = useIcon(props);
|
|
6
|
+
return (_jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", ...props, ref: ref, width: width, height: height, children: _jsx("path", { d: "m9 18 6-6-6-6" }) }));
|
|
7
|
+
});
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef } from 'react';
|
|
3
|
+
import { useIcon } from './hooks/useIcon';
|
|
4
|
+
export const ColorizeIcon = forwardRef((props, ref) => {
|
|
5
|
+
const { width, height } = useIcon(props);
|
|
6
|
+
return (_jsx("svg", { viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...props, ref: ref, width: width, height: height, children: _jsx("path", { d: "M21.6764 4.92454L19.0766 2.32489C18.9738 2.2219 18.8517 2.1402 18.7173 2.08445C18.5829 2.0287 18.4388 2 18.2933 2C18.1478 2 18.0037 2.0287 17.8693 2.08445C17.7349 2.1402 17.6128 2.2219 17.51 2.32489L14.0436 5.79109L11.8993 3.66916L10.3327 5.23561L11.9104 6.81317L2 16.7229V22H7.27741L17.1878 12.0902L18.7655 13.6678L20.332 12.1013L18.1989 9.9683L21.6653 6.50211C22.1097 6.05772 22.1097 5.35782 21.6764 4.92454ZM6.35525 19.7781L4.22207 17.645L13.177 8.6907L15.3102 10.8237L6.35525 19.7781Z", fill: "black" }) }));
|
|
7
|
+
});
|
|
@@ -12,6 +12,10 @@ export declare const LazyIcon: {
|
|
|
12
12
|
AddRadiusIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
13
13
|
AddShoppingCartIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
14
14
|
AdjustIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
15
|
+
AlignCenterIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
16
|
+
AlignJustifyIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
17
|
+
AlignLeftIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
18
|
+
ALignRightIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
15
19
|
AllDevicesIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
16
20
|
AllJourneyChannelsIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
17
21
|
AnalyticModels30Icon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
@@ -21,6 +25,7 @@ export declare const LazyIcon: {
|
|
|
21
25
|
AnlysisIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
22
26
|
AnlyticModelsIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
23
27
|
AntsomiAIIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
28
|
+
ArrowDropDownIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
24
29
|
ArrowGrowIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
25
30
|
ArrowLineIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
26
31
|
ArticleIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
@@ -63,12 +68,14 @@ export declare const LazyIcon: {
|
|
|
63
68
|
CheckboxUncheckedIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
64
69
|
ChecklistRtlIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
65
70
|
CheckSlimIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
71
|
+
ChevronRightIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
66
72
|
CircleAddElementIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
67
73
|
CircleInfoIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
68
74
|
CircleNotificationsIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
69
75
|
CloseIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
70
76
|
CodeIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
71
77
|
Collection30Icon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
78
|
+
ColorizeIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
72
79
|
ColorProfileStyleThemeIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
73
80
|
ColumnIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
74
81
|
CommentIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
@@ -232,6 +239,7 @@ export declare const LazyIcon: {
|
|
|
232
239
|
LineIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
233
240
|
LinkManagement30Icon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
234
241
|
LinkManagementIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
242
|
+
LinkOffIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
235
243
|
ListIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
236
244
|
LoadingIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & {
|
|
237
245
|
backgroundColor?: string | undefined;
|
|
@@ -251,6 +259,7 @@ export declare const LazyIcon: {
|
|
|
251
259
|
MenuImageMultiIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
252
260
|
MenuImageSingleIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
253
261
|
MergeIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
262
|
+
MinusIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
254
263
|
MobileFriendlyIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
255
264
|
MobilePhoneIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
256
265
|
MonitorAppIcon: import("react").LazyExoticComponent<import("react").ForwardRefExoticComponent<import("../types").IconProps & import("react").RefAttributes<SVGSVGElement>>>;
|
|
@@ -12,6 +12,10 @@ export const LazyIcon = {
|
|
|
12
12
|
AddRadiusIcon: lazy(() => import('../AddRadiusIcon').then(m => ({ default: m.AddRadiusIcon }))),
|
|
13
13
|
AddShoppingCartIcon: lazy(() => import('../AddShoppingCartIcon').then(m => ({ default: m.AddShoppingCartIcon }))),
|
|
14
14
|
AdjustIcon: lazy(() => import('../AdjustIcon').then(m => ({ default: m.AdjustIcon }))),
|
|
15
|
+
AlignCenterIcon: lazy(() => import('../AlignCenterIcon').then(m => ({ default: m.AlignCenterIcon }))),
|
|
16
|
+
AlignJustifyIcon: lazy(() => import('../AlignJustifyIcon').then(m => ({ default: m.AlignJustifyIcon }))),
|
|
17
|
+
AlignLeftIcon: lazy(() => import('../AlignLeftIcon').then(m => ({ default: m.AlignLeftIcon }))),
|
|
18
|
+
ALignRightIcon: lazy(() => import('../ALignRightIcon').then(m => ({ default: m.ALignRightIcon }))),
|
|
15
19
|
AllDevicesIcon: lazy(() => import('../AllDevicesIcon').then(m => ({ default: m.AllDevicesIcon }))),
|
|
16
20
|
AllJourneyChannelsIcon: lazy(() => import('../AllJourneyChannelsIcon').then(m => ({ default: m.AllJourneyChannelsIcon }))),
|
|
17
21
|
AnalyticModels30Icon: lazy(() => import('../AnalyticModels30Icon').then(m => ({ default: m.AnalyticModels30Icon }))),
|
|
@@ -21,6 +25,7 @@ export const LazyIcon = {
|
|
|
21
25
|
AnlysisIcon: lazy(() => import('../AnlysisIcon').then(m => ({ default: m.AnlysisIcon }))),
|
|
22
26
|
AnlyticModelsIcon: lazy(() => import('../AnlyticModelsIcon').then(m => ({ default: m.AnlyticModelsIcon }))),
|
|
23
27
|
AntsomiAIIcon: lazy(() => import('../AntsomiAIIcon').then(m => ({ default: m.AntsomiAIIcon }))),
|
|
28
|
+
ArrowDropDownIcon: lazy(() => import('../ArrowDropDownIcon').then(m => ({ default: m.ArrowDropDownIcon }))),
|
|
24
29
|
ArrowGrowIcon: lazy(() => import('../ArrowGrowIcon').then(m => ({ default: m.ArrowGrowIcon }))),
|
|
25
30
|
ArrowLineIcon: lazy(() => import('../ArrowLineIcon').then(m => ({ default: m.ArrowLineIcon }))),
|
|
26
31
|
ArticleIcon: lazy(() => import('../ArticleIcon').then(m => ({ default: m.ArticleIcon }))),
|
|
@@ -69,12 +74,14 @@ export const LazyIcon = {
|
|
|
69
74
|
CheckboxUncheckedIcon: lazy(() => import('../CheckboxUncheckedIcon').then(m => ({ default: m.CheckboxUncheckedIcon }))),
|
|
70
75
|
ChecklistRtlIcon: lazy(() => import('../ChecklistRtlIcon').then(m => ({ default: m.ChecklistRtlIcon }))),
|
|
71
76
|
CheckSlimIcon: lazy(() => import('../CheckSlimIcon').then(m => ({ default: m.CheckSlimIcon }))),
|
|
77
|
+
ChevronRightIcon: lazy(() => import('../ChevronRightIcon').then(m => ({ default: m.ChevronRightIcon }))),
|
|
72
78
|
CircleAddElementIcon: lazy(() => import('../CircleAddElementIcon').then(m => ({ default: m.CircleAddElementIcon }))),
|
|
73
79
|
CircleInfoIcon: lazy(() => import('../CircleInfoIcon').then(m => ({ default: m.CircleInfoIcon }))),
|
|
74
80
|
CircleNotificationsIcon: lazy(() => import('../CircleNotificationsIcon').then(m => ({ default: m.CircleNotificationsIcon }))),
|
|
75
81
|
CloseIcon: lazy(() => import('../CloseIcon').then(m => ({ default: m.CloseIcon }))),
|
|
76
82
|
CodeIcon: lazy(() => import('../CodeIcon').then(m => ({ default: m.CodeIcon }))),
|
|
77
83
|
Collection30Icon: lazy(() => import('../Collection30Icon').then(m => ({ default: m.Collection30Icon }))),
|
|
84
|
+
ColorizeIcon: lazy(() => import('../ColorizeIcon').then(m => ({ default: m.ColorizeIcon }))),
|
|
78
85
|
ColorProfileStyleThemeIcon: lazy(() => import('../ColorProfileStyleThemeIcon').then(m => ({ default: m.ColorProfileStyleThemeIcon }))),
|
|
79
86
|
ColumnIcon: lazy(() => import('../ColumnIcon').then(m => ({ default: m.ColumnIcon }))),
|
|
80
87
|
CommentIcon: lazy(() => import('../CommentIcon').then(m => ({ default: m.CommentIcon }))),
|
|
@@ -235,6 +242,7 @@ export const LazyIcon = {
|
|
|
235
242
|
LineIcon: lazy(() => import('../LineIcon').then(m => ({ default: m.LineIcon }))),
|
|
236
243
|
LinkManagement30Icon: lazy(() => import('../LinkManagement30Icon').then(m => ({ default: m.LinkManagement30Icon }))),
|
|
237
244
|
LinkManagementIcon: lazy(() => import('../LinkManagementIcon').then(m => ({ default: m.LinkManagementIcon }))),
|
|
245
|
+
LinkOffIcon: lazy(() => import('../LinkOffIcon').then(m => ({ default: m.LinkOffIcon }))),
|
|
238
246
|
ListIcon: lazy(() => import('../ListIcon').then(m => ({ default: m.ListIcon }))),
|
|
239
247
|
LoadingIcon: lazy(() => import('../LoadingIcon').then(m => ({ default: m.LoadingIcon }))),
|
|
240
248
|
LocalMallIcon: lazy(() => import('../LocalMallIcon').then(m => ({ default: m.LocalMallIcon }))),
|
|
@@ -252,6 +260,7 @@ export const LazyIcon = {
|
|
|
252
260
|
MenuImageMultiIcon: lazy(() => import('../MenuImageMultiIcon').then(m => ({ default: m.MenuImageMultiIcon }))),
|
|
253
261
|
MenuImageSingleIcon: lazy(() => import('../MenuImageSingleIcon').then(m => ({ default: m.MenuImageSingleIcon }))),
|
|
254
262
|
MergeIcon: lazy(() => import('../MergeIcon').then(m => ({ default: m.MergeIcon }))),
|
|
263
|
+
MinusIcon: lazy(() => import('../MinusIcon').then(m => ({ default: m.MinusIcon }))),
|
|
255
264
|
MobileFriendlyIcon: lazy(() => import('../MobileFriendlyIcon').then(m => ({ default: m.MobileFriendlyIcon }))),
|
|
256
265
|
MobilePhoneIcon: lazy(() => import('../MobilePhoneIcon').then(m => ({ default: m.MobilePhoneIcon }))),
|
|
257
266
|
MonitorAppIcon: lazy(() => import('../MonitorAppIcon').then(m => ({ default: m.MonitorAppIcon }))),
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef } from 'react';
|
|
3
|
+
import { useIcon } from './hooks/useIcon';
|
|
4
|
+
export const LinkOffIcon = forwardRef((props, ref) => {
|
|
5
|
+
const { width, height } = useIcon(props);
|
|
6
|
+
return (_jsx("svg", { viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...props, ref: ref, width: width, height: height, children: _jsx("path", { d: "M21.7338 20.4488C22.0886 20.8038 22.0888 21.3789 21.7338 21.7338C21.3789 22.0888 20.8038 22.0886 20.4488 21.7338L21.7338 20.4488ZM2 12.0006C2 10.554 2.57508 9.16568 3.59799 8.14276C4.16642 7.57438 4.8477 7.14486 5.58882 6.875L2.26633 3.55247L2.15048 3.40998C1.91716 3.05707 1.95555 2.57685 2.26633 2.26607C2.57711 1.95529 3.05732 1.91689 3.41023 2.15021L3.55271 2.26607L21.7338 20.4488L21.0907 21.0906L20.4488 21.7338L11.6239 12.9088H8.364C7.86207 12.9088 7.45471 12.5025 7.45447 12.0006C7.45447 11.4985 7.86193 11.0911 8.364 11.0911H9.80485L7.09493 8.37979C6.26264 8.46253 5.47964 8.83254 4.88304 9.42915C4.20138 10.1111 3.81905 11.0364 3.81905 12.0006C3.81916 12.9649 4.2012 13.8902 4.88304 14.5721C5.56488 15.2539 6.49022 15.636 7.45447 15.6361H9.27352L9.45596 15.6547C9.87039 15.7394 10.1817 16.1062 10.1817 16.5456C10.1817 16.9851 9.87039 17.3519 9.45596 17.4365L9.27352 17.4552H7.45447C6.00802 17.455 4.6208 16.88 3.59799 15.8572C2.57518 14.8343 2.00012 13.4471 2 12.0006ZM16.5457 6.54608C17.5584 6.54608 18.5512 6.82743 19.4128 7.35973C20.2744 7.89228 20.9719 8.65496 21.4249 9.56099C21.8778 10.4669 22.0685 11.4819 21.9775 12.4907C21.8865 13.4992 21.517 14.4624 20.9096 15.2725L20.7844 15.4084C20.468 15.6888 19.9879 15.7185 19.6365 15.455C19.2348 15.1537 19.1541 14.5836 19.4554 14.1819L19.5992 13.9742C19.9185 13.4802 20.1148 12.9152 20.1678 12.3269C20.2285 11.6543 20.0996 10.9773 19.7976 10.3733C19.4957 9.76978 19.032 9.26202 18.458 8.90714C17.8835 8.5521 17.221 8.36381 16.5457 8.36381H14.728C14.2259 8.36381 13.8185 7.95636 13.8185 7.45428C13.8187 6.95241 14.2261 6.54608 14.728 6.54608H16.5457Z", fill: "currentColor" }) }));
|
|
7
|
+
});
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef } from 'react';
|
|
3
|
+
import { useIcon } from './hooks/useIcon';
|
|
4
|
+
export const MinusIcon = forwardRef((props, ref) => {
|
|
5
|
+
const { width, height } = useIcon(props);
|
|
6
|
+
return (_jsx("svg", { viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...props, ref: ref, width: width, height: height, children: _jsx("path", { d: "M19 13H5V11H19V13Z", fill: "currentColor" }) }));
|
|
7
|
+
});
|
|
@@ -10,6 +10,10 @@ export { AddIcon } from './AddIcon';
|
|
|
10
10
|
export { AddRadiusIcon } from './AddRadiusIcon';
|
|
11
11
|
export { AddShoppingCartIcon } from './AddShoppingCartIcon';
|
|
12
12
|
export { AdjustIcon } from './AdjustIcon';
|
|
13
|
+
export { AlignCenterIcon } from './AlignCenterIcon';
|
|
14
|
+
export { AlignJustifyIcon } from './AlignJustifyIcon';
|
|
15
|
+
export { AlignLeftIcon } from './AlignLeftIcon';
|
|
16
|
+
export { ALignRightIcon } from './ALignRightIcon';
|
|
13
17
|
export { AllDevicesIcon } from './AllDevicesIcon';
|
|
14
18
|
export { AllJourneyChannelsIcon } from './AllJourneyChannelsIcon';
|
|
15
19
|
export { AnalyticModels30Icon } from './AnalyticModels30Icon';
|
|
@@ -19,6 +23,7 @@ export { AnalyticsIcon } from './AnalyticsIcon';
|
|
|
19
23
|
export { AnlysisIcon } from './AnlysisIcon';
|
|
20
24
|
export { AnlyticModelsIcon } from './AnlyticModelsIcon';
|
|
21
25
|
export { AntsomiAIIcon } from './AntsomiAIIcon';
|
|
26
|
+
export { ArrowDropDownIcon } from './ArrowDropDownIcon';
|
|
22
27
|
export { ArrowGrowIcon } from './ArrowGrowIcon';
|
|
23
28
|
export { ArrowLineIcon } from './ArrowLineIcon';
|
|
24
29
|
export { ArticleIcon } from './ArticleIcon';
|
|
@@ -61,12 +66,14 @@ export { CheckboxUnchecked5RadiusIcon } from './CheckboxUnchecked5RadiusIcon';
|
|
|
61
66
|
export { CheckboxUncheckedIcon } from './CheckboxUncheckedIcon';
|
|
62
67
|
export { ChecklistRtlIcon } from './ChecklistRtlIcon';
|
|
63
68
|
export { CheckSlimIcon } from './CheckSlimIcon';
|
|
69
|
+
export { ChevronRightIcon } from './ChevronRightIcon';
|
|
64
70
|
export { CircleAddElementIcon } from './CircleAddElementIcon';
|
|
65
71
|
export { CircleInfoIcon } from './CircleInfoIcon';
|
|
66
72
|
export { CircleNotificationsIcon } from './CircleNotificationsIcon';
|
|
67
73
|
export { CloseIcon } from './CloseIcon';
|
|
68
74
|
export { CodeIcon } from './CodeIcon';
|
|
69
75
|
export { Collection30Icon } from './Collection30Icon';
|
|
76
|
+
export { ColorizeIcon } from './ColorizeIcon';
|
|
70
77
|
export { ColorProfileStyleThemeIcon } from './ColorProfileStyleThemeIcon';
|
|
71
78
|
export { ColumnIcon } from './ColumnIcon';
|
|
72
79
|
export { CommentIcon } from './CommentIcon';
|
|
@@ -227,6 +234,7 @@ export { LibraryIcon } from './LibraryIcon';
|
|
|
227
234
|
export { LineIcon } from './LineIcon';
|
|
228
235
|
export { LinkManagement30Icon } from './LinkManagement30Icon';
|
|
229
236
|
export { LinkManagementIcon } from './LinkManagementIcon';
|
|
237
|
+
export { LinkOffIcon } from './LinkOffIcon';
|
|
230
238
|
export { ListIcon } from './ListIcon';
|
|
231
239
|
export { LoadingIcon } from './LoadingIcon';
|
|
232
240
|
export { LocalMallIcon } from './LocalMallIcon';
|
|
@@ -244,6 +252,7 @@ export { MenuExpandIcon } from './MenuExpandIcon';
|
|
|
244
252
|
export { MenuImageMultiIcon } from './MenuImageMultiIcon';
|
|
245
253
|
export { MenuImageSingleIcon } from './MenuImageSingleIcon';
|
|
246
254
|
export { MergeIcon } from './MergeIcon';
|
|
255
|
+
export { MinusIcon } from './MinusIcon';
|
|
247
256
|
export { MobileFriendlyIcon } from './MobileFriendlyIcon';
|
|
248
257
|
export { MobilePhoneIcon } from './MobilePhoneIcon';
|
|
249
258
|
export { MonitorAppIcon } from './MonitorAppIcon';
|
|
@@ -10,6 +10,10 @@ export { AddIcon } from './AddIcon';
|
|
|
10
10
|
export { AddRadiusIcon } from './AddRadiusIcon';
|
|
11
11
|
export { AddShoppingCartIcon } from './AddShoppingCartIcon';
|
|
12
12
|
export { AdjustIcon } from './AdjustIcon';
|
|
13
|
+
export { AlignCenterIcon } from './AlignCenterIcon';
|
|
14
|
+
export { AlignJustifyIcon } from './AlignJustifyIcon';
|
|
15
|
+
export { AlignLeftIcon } from './AlignLeftIcon';
|
|
16
|
+
export { ALignRightIcon } from './ALignRightIcon';
|
|
13
17
|
export { AllDevicesIcon } from './AllDevicesIcon';
|
|
14
18
|
export { AllJourneyChannelsIcon } from './AllJourneyChannelsIcon';
|
|
15
19
|
export { AnalyticModels30Icon } from './AnalyticModels30Icon';
|
|
@@ -19,6 +23,7 @@ export { AnalyticsIcon } from './AnalyticsIcon';
|
|
|
19
23
|
export { AnlysisIcon } from './AnlysisIcon';
|
|
20
24
|
export { AnlyticModelsIcon } from './AnlyticModelsIcon';
|
|
21
25
|
export { AntsomiAIIcon } from './AntsomiAIIcon';
|
|
26
|
+
export { ArrowDropDownIcon } from './ArrowDropDownIcon';
|
|
22
27
|
export { ArrowGrowIcon } from './ArrowGrowIcon';
|
|
23
28
|
export { ArrowLineIcon } from './ArrowLineIcon';
|
|
24
29
|
export { ArticleIcon } from './ArticleIcon';
|
|
@@ -61,12 +66,14 @@ export { CheckboxUnchecked5RadiusIcon } from './CheckboxUnchecked5RadiusIcon';
|
|
|
61
66
|
export { CheckboxUncheckedIcon } from './CheckboxUncheckedIcon';
|
|
62
67
|
export { ChecklistRtlIcon } from './ChecklistRtlIcon';
|
|
63
68
|
export { CheckSlimIcon } from './CheckSlimIcon';
|
|
69
|
+
export { ChevronRightIcon } from './ChevronRightIcon';
|
|
64
70
|
export { CircleAddElementIcon } from './CircleAddElementIcon';
|
|
65
71
|
export { CircleInfoIcon } from './CircleInfoIcon';
|
|
66
72
|
export { CircleNotificationsIcon } from './CircleNotificationsIcon';
|
|
67
73
|
export { CloseIcon } from './CloseIcon';
|
|
68
74
|
export { CodeIcon } from './CodeIcon';
|
|
69
75
|
export { Collection30Icon } from './Collection30Icon';
|
|
76
|
+
export { ColorizeIcon } from './ColorizeIcon';
|
|
70
77
|
export { ColorProfileStyleThemeIcon } from './ColorProfileStyleThemeIcon';
|
|
71
78
|
export { ColumnIcon } from './ColumnIcon';
|
|
72
79
|
export { CommentIcon } from './CommentIcon';
|
|
@@ -227,6 +234,7 @@ export { LibraryIcon } from './LibraryIcon';
|
|
|
227
234
|
export { LineIcon } from './LineIcon';
|
|
228
235
|
export { LinkManagement30Icon } from './LinkManagement30Icon';
|
|
229
236
|
export { LinkManagementIcon } from './LinkManagementIcon';
|
|
237
|
+
export { LinkOffIcon } from './LinkOffIcon';
|
|
230
238
|
export { ListIcon } from './ListIcon';
|
|
231
239
|
export { LoadingIcon } from './LoadingIcon';
|
|
232
240
|
export { LocalMallIcon } from './LocalMallIcon';
|
|
@@ -244,6 +252,7 @@ export { MenuExpandIcon } from './MenuExpandIcon';
|
|
|
244
252
|
export { MenuImageMultiIcon } from './MenuImageMultiIcon';
|
|
245
253
|
export { MenuImageSingleIcon } from './MenuImageSingleIcon';
|
|
246
254
|
export { MergeIcon } from './MergeIcon';
|
|
255
|
+
export { MinusIcon } from './MinusIcon';
|
|
247
256
|
export { MobileFriendlyIcon } from './MobileFriendlyIcon';
|
|
248
257
|
export { MobilePhoneIcon } from './MobilePhoneIcon';
|
|
249
258
|
export { MonitorAppIcon } from './MonitorAppIcon';
|
package/es/components/index.scss
CHANGED
|
@@ -16,7 +16,7 @@ import { COMMON_TAB_COLLECTION, MIN_VISIBLE_COUNT, SMILEYS_BODY } from './consta
|
|
|
16
16
|
import { globalToken } from '@antscorp/antsomi-ui/es/constants';
|
|
17
17
|
const { Text } = Typography;
|
|
18
18
|
const emojiListParsed = JSON.parse(JSON.stringify(ICON_EMOJI_COMMON));
|
|
19
|
-
const CommonCollection = ({ onEmojiClick }) => {
|
|
19
|
+
const CommonCollection = ({ onEmojiClick, getPopupContainer }) => {
|
|
20
20
|
// States
|
|
21
21
|
const [visibleCount, setVisibleCount] = useState(MIN_VISIBLE_COUNT);
|
|
22
22
|
const [state, setState] = useImmer({
|
|
@@ -93,7 +93,7 @@ const CommonCollection = ({ onEmojiClick }) => {
|
|
|
93
93
|
});
|
|
94
94
|
return (_jsx(Scrollbars, { autoHeight: true, autoHeightMax: 150, onScroll: e => onScroll(e, emojiCollection.length), children: _jsx(Flex, { wrap: "wrap", children: content }) }));
|
|
95
95
|
}, [emojiCollection, visibleCount, onScroll, onEmojiClick]);
|
|
96
|
-
return (_jsxs(WrapperCollection, { children: [_jsxs(Flex, { gap: 20, justify: "space-between", align: "flex-end", children: [_jsx(Input, { placeholder: "Search...", suffix: _jsx(SearchIcon, { color: globalToken?.bw8 }), styles: { affixWrapper: { minWidth: 280 } }, onChange: handleChangeInput }), _jsx(Select, { placeholder: "Select collection", value: state.collectionActive, style: { width: 200 }, options: collectionOptions, optionRender: renderOption, onChange: handleChangeSelect })] }), _jsx(EmojiList, { children: renderCommonCollection() })] }));
|
|
96
|
+
return (_jsxs(WrapperCollection, { children: [_jsxs(Flex, { gap: 20, justify: "space-between", align: "flex-end", children: [_jsx(Input, { placeholder: "Search...", suffix: _jsx(SearchIcon, { color: globalToken?.bw8 }), styles: { affixWrapper: { minWidth: 280 } }, onChange: handleChangeInput }), _jsx(Select, { placeholder: "Select collection", value: state.collectionActive, style: { width: 200 }, options: collectionOptions, optionRender: renderOption, onChange: handleChangeSelect, getPopupContainer: getPopupContainer })] }), _jsx(EmojiList, { children: renderCommonCollection() })] }));
|
|
97
97
|
};
|
|
98
98
|
CommonCollection.defaultProps = {
|
|
99
99
|
onEmojiClick: () => { },
|
|
@@ -9,7 +9,9 @@ interface EmojiPopoverProps {
|
|
|
9
9
|
collections?: CollectionItemProps[];
|
|
10
10
|
isForceHide?: boolean;
|
|
11
11
|
children?: React.ReactNode;
|
|
12
|
+
destroyTooltipOnHide?: boolean;
|
|
12
13
|
onEmojiClick?: (emoji: string | TagDataCustomize) => void;
|
|
14
|
+
getPopupContainer?: (triggerNode: HTMLElement) => HTMLElement;
|
|
13
15
|
}
|
|
14
16
|
declare const _default: React.NamedExoticComponent<EmojiPopoverProps>;
|
|
15
17
|
export default _default;
|
|
@@ -11,7 +11,7 @@ import { EMOJI_COLLECTIONS, } from '@antscorp/antsomi-ui/es/components/molecules
|
|
|
11
11
|
import { EmojiTabs, EmojiPopoverStyled } from './styled';
|
|
12
12
|
// Utils
|
|
13
13
|
import { handleGetTextToReplace } from './utils';
|
|
14
|
-
const EmojiPopover = ({ disabled, collections, isForceHide, children, onEmojiClick, }) => {
|
|
14
|
+
const EmojiPopover = ({ disabled, collections, isForceHide, children, destroyTooltipOnHide, onEmojiClick, getPopupContainer, }) => {
|
|
15
15
|
const [state, setState] = useImmer({
|
|
16
16
|
isOpen: false,
|
|
17
17
|
collectionActive: collections ? collections[0]?.key : EMOJI_COLLECTIONS.COMMON,
|
|
@@ -47,16 +47,16 @@ const EmojiPopover = ({ disabled, collections, isForceHide, children, onEmojiCli
|
|
|
47
47
|
const renderCollection = useCallback((collectionCurrent = '') => {
|
|
48
48
|
switch (collectionCurrent) {
|
|
49
49
|
case EMOJI_COLLECTIONS.VIBER: {
|
|
50
|
-
return _jsx(ViberCollection, { onEmojiClick: handleGetCodeEmoji });
|
|
50
|
+
return (_jsx(ViberCollection, { onEmojiClick: handleGetCodeEmoji, getPopupContainer: getPopupContainer }));
|
|
51
51
|
}
|
|
52
52
|
case EMOJI_COLLECTIONS.LINE: {
|
|
53
|
-
return _jsx(LineCollection, { onEmojiClick: handleGetCodeEmoji });
|
|
53
|
+
return (_jsx(LineCollection, { onEmojiClick: handleGetCodeEmoji, getPopupContainer: getPopupContainer }));
|
|
54
54
|
}
|
|
55
55
|
default: {
|
|
56
|
-
return _jsx(CommonCollection, { onEmojiClick: handleGetCodeEmoji });
|
|
56
|
+
return (_jsx(CommonCollection, { onEmojiClick: handleGetCodeEmoji, getPopupContainer: getPopupContainer }));
|
|
57
57
|
}
|
|
58
58
|
}
|
|
59
|
-
}, [handleGetCodeEmoji]);
|
|
59
|
+
}, [handleGetCodeEmoji, getPopupContainer]);
|
|
60
60
|
const emojiCollections = useMemo(() => {
|
|
61
61
|
if (!collections)
|
|
62
62
|
return [];
|
|
@@ -66,7 +66,11 @@ const EmojiPopover = ({ disabled, collections, isForceHide, children, onEmojiCli
|
|
|
66
66
|
children: renderCollection(collection.key),
|
|
67
67
|
}));
|
|
68
68
|
}, [collections, renderCollection]);
|
|
69
|
-
|
|
69
|
+
let content = (_jsx(EmojiTabs, { activeKey: state.collectionActive, onTabClick: handleClickCollection, items: emojiCollections }));
|
|
70
|
+
if (emojiCollections.length <= 1) {
|
|
71
|
+
content = emojiCollections.at(0)?.children;
|
|
72
|
+
}
|
|
73
|
+
return (_jsx(EmojiPopoverStyled, { content: content, placement: "topLeft", destroyTooltipOnHide: destroyTooltipOnHide, trigger: "click", fresh: false, style: { padding: 15 }, arrow: false, rootClassName: "antsomi-emoji-popover", open: state.isOpen, onOpenChange: handleOpenChange, getPopupContainer: getPopupContainer, children: children || (_jsx(Button, { type: "link", icon: _jsx(EmojiSmileIcon, {}), disabled: disabled, onClick: () => handleOpenChange(true) })) }));
|
|
70
74
|
};
|
|
71
75
|
EmojiPopover.defaultProps = {
|
|
72
76
|
disabled: false,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
// Libraries
|
|
2
2
|
import styled from 'styled-components';
|
|
3
3
|
// Components
|
|
4
|
-
import { Popover } from '@antscorp/antsomi-ui/es/components/atoms';
|
|
5
4
|
import { Tabs as TabsUI } from '@antscorp/antsomi-ui/es/components/molecules';
|
|
5
|
+
import { Popover } from '../../atoms/Popover';
|
|
6
6
|
export const EmojiTabs = styled(TabsUI) `
|
|
7
7
|
.antsomi-tabs-tab {
|
|
8
8
|
padding: 5.5px 20px !important;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
interface EyedropperButtonProps {
|
|
3
|
+
onColorPick?: (color: string) => void;
|
|
4
|
+
size?: 'small' | 'middle' | 'large';
|
|
5
|
+
type?: 'primary' | 'default' | 'dashed' | 'link' | 'text';
|
|
6
|
+
disabled?: boolean;
|
|
7
|
+
className?: string;
|
|
8
|
+
showIcon?: boolean;
|
|
9
|
+
}
|
|
10
|
+
export declare const EyedropperButton: React.FC<EyedropperButtonProps>;
|
|
11
|
+
export {};
|