@lobehub/ui 4.1.9 → 4.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (151) hide show
  1. package/es/Accordion/Accordion.d.mts +2 -2
  2. package/es/Accordion/Accordion.mjs +2 -2
  3. package/es/Accordion/Accordion.mjs.map +1 -1
  4. package/es/Accordion/AccordionItem.d.mts +2 -2
  5. package/es/ActionIcon/ActionIcon.d.mts +2 -2
  6. package/es/Alert/Alert.d.mts +2 -2
  7. package/es/AutoComplete/Select.d.mts +2 -2
  8. package/es/Avatar/AvatarGroup/index.d.mts +2 -2
  9. package/es/Burger/Burger.d.mts +2 -2
  10. package/es/Checkbox/Checkbox.d.mts +8 -0
  11. package/es/Checkbox/Checkbox.mjs +63 -0
  12. package/es/Checkbox/Checkbox.mjs.map +1 -0
  13. package/es/Checkbox/index.d.mts +3 -0
  14. package/es/Checkbox/index.d.ts +1 -0
  15. package/es/Checkbox/index.js +1 -0
  16. package/es/Checkbox/index.mjs +3 -0
  17. package/es/Checkbox/style.mjs +21 -0
  18. package/es/Checkbox/style.mjs.map +1 -0
  19. package/es/Checkbox/type.d.mts +31 -0
  20. package/es/CodeEditor/CodeEditor.d.mts +2 -2
  21. package/es/CodeEditor/CodeEditor.mjs +2 -2
  22. package/es/CodeEditor/CodeEditor.mjs.map +1 -1
  23. package/es/Collapse/Collapse.d.mts +2 -2
  24. package/es/ColorSwatches/ColorSwatches.mjs +2 -2
  25. package/es/ColorSwatches/ColorSwatches.mjs.map +1 -1
  26. package/es/ConfigProvider/index.d.mts +2 -2
  27. package/es/CopyButton/CopyButton.d.mts +2 -2
  28. package/es/DatePicker/DatePicker.d.mts +2 -2
  29. package/es/DraggablePanel/DraggablePanel.mjs +2 -2
  30. package/es/DraggablePanel/DraggablePanel.mjs.map +1 -1
  31. package/es/DraggablePanel/components/DraggablePanelBody.d.mts +2 -2
  32. package/es/DraggablePanel/components/DraggablePanelContainer.d.mts +2 -2
  33. package/es/DraggablePanel/components/DraggablePanelFooter.d.mts +2 -2
  34. package/es/DraggablePanel/components/DraggablePanelHeader.d.mts +2 -2
  35. package/es/DraggablePanel/components/DraggablePanelHeader.mjs +2 -2
  36. package/es/DraggablePanel/components/DraggablePanelHeader.mjs.map +1 -1
  37. package/es/DraggableSideNav/DraggableSideNav.d.mts +2 -2
  38. package/es/DraggableSideNav/DraggableSideNav.mjs +2 -2
  39. package/es/DraggableSideNav/DraggableSideNav.mjs.map +1 -1
  40. package/es/Drawer/Drawer.d.mts +2 -2
  41. package/es/Dropdown/Dropdown.d.mts +2 -2
  42. package/es/EditableText/EditableText.d.mts +2 -2
  43. package/es/EditableText/EditableText.mjs +2 -2
  44. package/es/EditableText/EditableText.mjs.map +1 -1
  45. package/es/EmojiPicker/EmojiPicker.d.mts +2 -2
  46. package/es/EmojiPicker/EmojiPicker.mjs +3 -3
  47. package/es/EmojiPicker/EmojiPicker.mjs.map +1 -1
  48. package/es/Flex/FlexBasic.d.mts +2 -2
  49. package/es/FontLoader/index.d.mts +2 -2
  50. package/es/Footer/Footer.d.mts +2 -2
  51. package/es/Form/components/FormGroup.d.mts +2 -2
  52. package/es/Form/components/FormItem.d.mts +2 -2
  53. package/es/Form/components/FormSubmitFooter.d.mts +2 -2
  54. package/es/FormModal/FormModal.d.mts +2 -2
  55. package/es/Header/Header.d.mts +2 -2
  56. package/es/Hotkey/Hotkey.d.mts +2 -2
  57. package/es/HotkeyInput/HotkeyInput.d.mts +2 -2
  58. package/es/HotkeyInput/HotkeyInput.mjs +2 -2
  59. package/es/HotkeyInput/HotkeyInput.mjs.map +1 -1
  60. package/es/Icon/Icon.d.mts +2 -2
  61. package/es/Icon/components/IconProvider.d.mts +3 -3
  62. package/es/Image/PreviewGroup.d.mts +2 -2
  63. package/es/ImageSelect/ImageSelect.mjs +2 -2
  64. package/es/ImageSelect/ImageSelect.mjs.map +1 -1
  65. package/es/Input/Input.d.mts +2 -2
  66. package/es/Input/InputNumber.d.mts +2 -2
  67. package/es/Input/InputOPT.d.mts +2 -2
  68. package/es/Input/InputPassword.d.mts +2 -2
  69. package/es/Input/TextArea.d.mts +2 -2
  70. package/es/Layout/components/LayoutFooter.d.mts +2 -2
  71. package/es/Layout/components/LayoutHeader.d.mts +2 -2
  72. package/es/Layout/components/LayoutMain.d.mts +2 -2
  73. package/es/Layout/components/LayoutSidebar.d.mts +2 -2
  74. package/es/Layout/components/LayoutSidebarInner.d.mts +2 -2
  75. package/es/Layout/components/LayoutToc.d.mts +2 -2
  76. package/es/List/ListItem/index.d.mts +2 -2
  77. package/es/Markdown/Markdown.d.mts +2 -2
  78. package/es/Markdown/Typography.d.mts +2 -2
  79. package/es/Markdown/components/SearchResultCards/index.d.mts +2 -2
  80. package/es/MaskShadow/MaskShadow.d.mts +2 -2
  81. package/es/Menu/Menu.d.mts +2 -2
  82. package/es/Mermaid/Mermaid.d.mts +2 -2
  83. package/es/Mermaid/SyntaxMermaid/index.d.mts +2 -2
  84. package/es/Modal/Modal.d.mts +2 -2
  85. package/es/MotionProvider/index.d.mts +2 -2
  86. package/es/SearchBar/SearchBar.d.mts +2 -2
  87. package/es/SearchBar/SearchBar.mjs +2 -2
  88. package/es/SearchBar/SearchBar.mjs.map +1 -1
  89. package/es/Segmented/Segmented.d.mts +2 -2
  90. package/es/Select/Select.d.mts +2 -2
  91. package/es/SideNav/SideNav.d.mts +2 -2
  92. package/es/SliderWithInput/SliderWithInput.d.mts +2 -2
  93. package/es/ThemeProvider/ThemeProvider.d.mts +2 -2
  94. package/es/Toc/Toc.d.mts +2 -2
  95. package/es/Toc/TocMobile.mjs +2 -2
  96. package/es/Toc/TocMobile.mjs.map +1 -1
  97. package/es/Video/index.d.mts +2 -2
  98. package/es/awesome/AuroraBackground/AuroraBackground.d.mts +2 -2
  99. package/es/awesome/BottomGradientButton/BottomGradientButton.d.mts +2 -2
  100. package/es/awesome/Features/Features.d.mts +2 -2
  101. package/es/awesome/Giscus/Giscus.d.mts +2 -2
  102. package/es/awesome/GradientButton/GradientButton.d.mts +2 -2
  103. package/es/awesome/GridBackground/GridBackground.d.mts +2 -2
  104. package/es/awesome/GridBackground/GridShowcase.d.mts +2 -2
  105. package/es/awesome/Hero/Hero.d.mts +2 -2
  106. package/es/awesome/Spline/Spine.d.mts +2 -2
  107. package/es/awesome/Spotlight/Spotlight.d.mts +2 -2
  108. package/es/awesome/SpotlightCard/SpotlightCard.d.mts +2 -2
  109. package/es/awesome/TypewriterEffect/TypewriterEffect.d.mts +2 -2
  110. package/es/brand/BrandLoading/{style-Cof4dJBw.css → style-Ci5ZSi4a.css} +1 -1
  111. package/es/brand/BrandLoading/{style-Cof4dJBw.css.map → style-Ci5ZSi4a.css.map} +1 -1
  112. package/es/brand/LobeChat/index.d.mts +2 -2
  113. package/es/brand/LobeHub/index.d.mts +2 -2
  114. package/es/brand/LogoThree/LogoSpline.d.mts +2 -2
  115. package/es/brand/LogoThree/index.d.mts +2 -2
  116. package/es/chat/BackBottom/BackBottom.d.mts +2 -2
  117. package/es/chat/ChatInputArea/components/ChatInputAreaInner.d.mts +2 -2
  118. package/es/chat/ChatItem/ChatItem.d.mts +2 -2
  119. package/es/chat/ChatList/ChatList.d.mts +2 -2
  120. package/es/chat/EditableMessage/EditableMessage.d.mts +2 -2
  121. package/es/chat/EditableMessage/EditableMessage.mjs +3 -3
  122. package/es/chat/EditableMessage/EditableMessage.mjs.map +1 -1
  123. package/es/chat/EditableMessageList/EditableMessageList.d.mts +2 -2
  124. package/es/chat/MessageInput/MessageInput.d.mts +2 -2
  125. package/es/chat/MessageModal/MessageModal.d.mts +2 -2
  126. package/es/chat/MessageModal/MessageModal.mjs +3 -3
  127. package/es/chat/MessageModal/MessageModal.mjs.map +1 -1
  128. package/es/color/ColorScales/index.d.mts +2 -2
  129. package/es/i18n/context.d.mts +2 -2
  130. package/es/icons/lucideExtra/DiscordIcon.d.mts +3 -3
  131. package/es/icons/lucideExtra/GlobeOffIcon.d.mts +3 -3
  132. package/es/icons/lucideExtra/GroupBotIcon.d.mts +3 -3
  133. package/es/icons/lucideExtra/GroupBotSquareIcon.d.mts +3 -3
  134. package/es/icons/lucideExtra/LeftClickIcon.d.mts +3 -3
  135. package/es/icons/lucideExtra/LeftDoubleClickIcon.d.mts +3 -3
  136. package/es/icons/lucideExtra/McpIcon.d.mts +3 -3
  137. package/es/icons/lucideExtra/ProviderIcon.d.mts +3 -3
  138. package/es/icons/lucideExtra/RightClickIcon.d.mts +3 -3
  139. package/es/icons/lucideExtra/RightDoubleClickIcon.d.mts +3 -3
  140. package/es/icons/lucideExtra/ShapesUploadIcon.d.mts +3 -3
  141. package/es/icons/lucideExtra/TreeUpDownRightIcon.d.mts +3 -3
  142. package/es/index.d.mts +7 -4
  143. package/es/index.mjs +2 -1
  144. package/es/mdx/Mdx/index.d.mts +2 -2
  145. package/es/mobile/ChatHeader/ChatHeaderTitle.d.mts +2 -2
  146. package/es/mobile/ChatInputArea/components/ChatSendButton.d.mts +2 -2
  147. package/es/mobile/TabBar/TabBar.d.mts +2 -2
  148. package/es/mobile/TabBar/TabBar.mjs +2 -2
  149. package/es/mobile/TabBar/TabBar.mjs.map +1 -1
  150. package/es/storybook/StoryBook/index.d.mts +2 -2
  151. package/package.json +1 -1
@@ -1,8 +1,8 @@
1
1
  import { AccordionProps } from "./type.mjs";
2
- import * as react25 from "react";
2
+ import * as react13 from "react";
3
3
 
4
4
  //#region src/Accordion/Accordion.d.ts
5
- declare const Accordion: react25.NamedExoticComponent<AccordionProps>;
5
+ declare const Accordion: react13.NamedExoticComponent<AccordionProps>;
6
6
  //#endregion
7
7
  export { Accordion };
8
8
  //# sourceMappingURL=Accordion.d.mts.map
@@ -6,14 +6,14 @@ import { Children, Fragment, isValidElement, memo, useCallback } from "react";
6
6
  import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
7
7
  import { Divider } from "antd";
8
8
  import { LayoutGroup } from "motion/react";
9
- import useControlledState from "use-merge-value";
9
+ import useMergeState from "use-merge-value";
10
10
 
11
11
  //#region src/Accordion/Accordion.tsx
12
12
  const Accordion = memo(({ children, className: userClassName, style: userStyle, accordion = false, defaultExpandedKeys, expandedKeys: expandedKeysProp, onExpandedChange, variant = "borderless", gap, showDivider = false, disableAnimation = false, hideIndicator = false, indicatorPlacement = "start", keepContentMounted = true, classNames, styles: customStyles, motionProps, ref, ...rest }) => {
13
13
  const { cx, styles } = useStyles();
14
14
  const validChildren = Children.toArray(children).filter(isValidElement);
15
15
  const allItemKeys = validChildren.map((child, index) => child.props.itemKey || index);
16
- const [expandedKeys, setExpandedKeys] = useControlledState(defaultExpandedKeys ?? allItemKeys, {
16
+ const [expandedKeys, setExpandedKeys] = useMergeState(defaultExpandedKeys ?? allItemKeys, {
17
17
  onChange: onExpandedChange,
18
18
  value: expandedKeysProp
19
19
  });
@@ -1 +1 @@
1
- {"version":3,"file":"Accordion.mjs","names":["useMergeState","newKeys: Key[]"],"sources":["../../src/Accordion/Accordion.tsx"],"sourcesContent":["'use client';\n\nimport { Divider } from 'antd';\nimport { LayoutGroup } from 'motion/react';\nimport { Children, Fragment, isValidElement, memo, useCallback } from 'react';\nimport type { Key } from 'react';\nimport useMergeState from 'use-merge-value';\n\nimport { AccordionContext } from './context';\nimport { useStyles } from './style';\nimport type { AccordionProps } from './type';\n\nconst Accordion = memo<AccordionProps>(\n ({\n children,\n className: userClassName,\n style: userStyle,\n accordion = false,\n defaultExpandedKeys,\n expandedKeys: expandedKeysProp,\n onExpandedChange,\n variant = 'borderless',\n gap,\n showDivider = false,\n disableAnimation = false,\n hideIndicator = false,\n indicatorPlacement = 'start',\n keepContentMounted = true,\n classNames,\n styles: customStyles,\n motionProps,\n ref,\n ...rest\n }) => {\n const { cx, styles } = useStyles();\n\n // Convert children to array and filter valid elements\n const validChildren = Children.toArray(children).filter(isValidElement);\n\n // Collect all item keys\n const allItemKeys = validChildren.map((child, index) => (child.props as any).itemKey || index);\n\n // If defaultExpandedKeys or expandedKeys is undefined, expand all items by default\n const initialExpandedKeys = defaultExpandedKeys ?? allItemKeys;\n\n const [expandedKeys, setExpandedKeys] = useMergeState<Key[]>(initialExpandedKeys, {\n onChange: onExpandedChange,\n value: expandedKeysProp,\n });\n\n const toggleExpand = useCallback(\n (key: Key) => {\n const prev = expandedKeys;\n let newKeys: Key[];\n\n if (accordion) {\n newKeys = prev.includes(key) ? [] : [key];\n } else {\n newKeys = prev.includes(key) ? prev.filter((k: Key) => k !== key) : [...prev, key];\n }\n\n setExpandedKeys(newKeys);\n },\n [accordion, expandedKeys, setExpandedKeys],\n );\n\n const isExpanded = useCallback(\n (key: Key) => {\n return expandedKeys.includes(key);\n },\n [expandedKeys],\n );\n\n const contextValue = {\n disableAnimation,\n expandedKeys,\n hideIndicator,\n indicatorPlacement,\n isExpanded,\n keepContentMounted,\n motionProps,\n onToggle: toggleExpand,\n showDivider,\n variant,\n };\n\n const content = (\n <>\n {validChildren.map((child, index) => {\n // Extract itemKey from child props to use as React key\n const childKey = (child.props as any).itemKey || index;\n return (\n <Fragment key={childKey}>\n {child}\n {showDivider && index < validChildren.length - 1 && (\n <Divider className={styles.divider} />\n )}\n </Fragment>\n );\n })}\n </>\n );\n\n return (\n <AccordionContext.Provider value={contextValue}>\n <div\n className={cx(styles.base, classNames?.base, userClassName)}\n ref={ref}\n style={{\n gap: gap,\n ...customStyles?.base,\n ...userStyle,\n }}\n {...rest}\n >\n {disableAnimation ? content : <LayoutGroup>{content}</LayoutGroup>}\n </div>\n </AccordionContext.Provider>\n );\n },\n);\n\nAccordion.displayName = 'Accordion';\n\nexport default Accordion;\n"],"mappings":";;;;;;;;;;;AAYA,MAAM,YAAY,MACf,EACC,UACA,WAAW,eACX,OAAO,WACP,YAAY,OACZ,qBACA,cAAc,kBACd,kBACA,UAAU,cACV,KACA,cAAc,OACd,mBAAmB,OACnB,gBAAgB,OAChB,qBAAqB,SACrB,qBAAqB,MACrB,YACA,QAAQ,cACR,aACA,KACA,GAAG,WACC;CACJ,MAAM,EAAE,IAAI,WAAW,WAAW;CAGlC,MAAM,gBAAgB,SAAS,QAAQ,SAAS,CAAC,OAAO,eAAe;CAGvE,MAAM,cAAc,cAAc,KAAK,OAAO,UAAW,MAAM,MAAc,WAAW,MAAM;CAK9F,MAAM,CAAC,cAAc,mBAAmBA,mBAFZ,uBAAuB,aAE+B;EAChF,UAAU;EACV,OAAO;EACR,CAAC;CAEF,MAAM,eAAe,aAClB,QAAa;EACZ,MAAM,OAAO;EACb,IAAIC;AAEJ,MAAI,UACF,WAAU,KAAK,SAAS,IAAI,GAAG,EAAE,GAAG,CAAC,IAAI;MAEzC,WAAU,KAAK,SAAS,IAAI,GAAG,KAAK,QAAQ,MAAW,MAAM,IAAI,GAAG,CAAC,GAAG,MAAM,IAAI;AAGpF,kBAAgB,QAAQ;IAE1B;EAAC;EAAW;EAAc;EAAgB,CAC3C;CASD,MAAM,eAAe;EACnB;EACA;EACA;EACA;EACA,YAZiB,aAChB,QAAa;AACZ,UAAO,aAAa,SAAS,IAAI;KAEnC,CAAC,aAAa,CACf;EAQC;EACA;EACA,UAAU;EACV;EACA;EACD;CAED,MAAM,UACJ,4CACG,cAAc,KAAK,OAAO,UAAU;EAEnC,MAAM,WAAY,MAAM,MAAc,WAAW;AACjD,SACE,qBAAC,uBACE,OACA,eAAe,QAAQ,cAAc,SAAS,KAC7C,oBAAC,WAAQ,WAAW,OAAO,UAAW,KAH3B,SAKJ;GAEb,GACD;AAGL,QACE,oBAAC,iBAAiB;EAAS,OAAO;YAChC,oBAAC;GACC,WAAW,GAAG,OAAO,MAAM,YAAY,MAAM,cAAc;GACtD;GACL,OAAO;IACA;IACL,GAAG,cAAc;IACjB,GAAG;IACJ;GACD,GAAI;aAEH,mBAAmB,UAAU,oBAAC,yBAAa,UAAsB;IAC9D;GACoB;EAGjC;AAED,UAAU,cAAc;AAExB,wBAAe"}
1
+ {"version":3,"file":"Accordion.mjs","names":["newKeys: Key[]"],"sources":["../../src/Accordion/Accordion.tsx"],"sourcesContent":["'use client';\n\nimport { Divider } from 'antd';\nimport { LayoutGroup } from 'motion/react';\nimport { Children, Fragment, isValidElement, memo, useCallback } from 'react';\nimport type { Key } from 'react';\nimport useMergeState from 'use-merge-value';\n\nimport { AccordionContext } from './context';\nimport { useStyles } from './style';\nimport type { AccordionProps } from './type';\n\nconst Accordion = memo<AccordionProps>(\n ({\n children,\n className: userClassName,\n style: userStyle,\n accordion = false,\n defaultExpandedKeys,\n expandedKeys: expandedKeysProp,\n onExpandedChange,\n variant = 'borderless',\n gap,\n showDivider = false,\n disableAnimation = false,\n hideIndicator = false,\n indicatorPlacement = 'start',\n keepContentMounted = true,\n classNames,\n styles: customStyles,\n motionProps,\n ref,\n ...rest\n }) => {\n const { cx, styles } = useStyles();\n\n // Convert children to array and filter valid elements\n const validChildren = Children.toArray(children).filter(isValidElement);\n\n // Collect all item keys\n const allItemKeys = validChildren.map((child, index) => (child.props as any).itemKey || index);\n\n // If defaultExpandedKeys or expandedKeys is undefined, expand all items by default\n const initialExpandedKeys = defaultExpandedKeys ?? allItemKeys;\n\n const [expandedKeys, setExpandedKeys] = useMergeState<Key[]>(initialExpandedKeys, {\n onChange: onExpandedChange,\n value: expandedKeysProp,\n });\n\n const toggleExpand = useCallback(\n (key: Key) => {\n const prev = expandedKeys;\n let newKeys: Key[];\n\n if (accordion) {\n newKeys = prev.includes(key) ? [] : [key];\n } else {\n newKeys = prev.includes(key) ? prev.filter((k: Key) => k !== key) : [...prev, key];\n }\n\n setExpandedKeys(newKeys);\n },\n [accordion, expandedKeys, setExpandedKeys],\n );\n\n const isExpanded = useCallback(\n (key: Key) => {\n return expandedKeys.includes(key);\n },\n [expandedKeys],\n );\n\n const contextValue = {\n disableAnimation,\n expandedKeys,\n hideIndicator,\n indicatorPlacement,\n isExpanded,\n keepContentMounted,\n motionProps,\n onToggle: toggleExpand,\n showDivider,\n variant,\n };\n\n const content = (\n <>\n {validChildren.map((child, index) => {\n // Extract itemKey from child props to use as React key\n const childKey = (child.props as any).itemKey || index;\n return (\n <Fragment key={childKey}>\n {child}\n {showDivider && index < validChildren.length - 1 && (\n <Divider className={styles.divider} />\n )}\n </Fragment>\n );\n })}\n </>\n );\n\n return (\n <AccordionContext.Provider value={contextValue}>\n <div\n className={cx(styles.base, classNames?.base, userClassName)}\n ref={ref}\n style={{\n gap: gap,\n ...customStyles?.base,\n ...userStyle,\n }}\n {...rest}\n >\n {disableAnimation ? content : <LayoutGroup>{content}</LayoutGroup>}\n </div>\n </AccordionContext.Provider>\n );\n },\n);\n\nAccordion.displayName = 'Accordion';\n\nexport default Accordion;\n"],"mappings":";;;;;;;;;;;AAYA,MAAM,YAAY,MACf,EACC,UACA,WAAW,eACX,OAAO,WACP,YAAY,OACZ,qBACA,cAAc,kBACd,kBACA,UAAU,cACV,KACA,cAAc,OACd,mBAAmB,OACnB,gBAAgB,OAChB,qBAAqB,SACrB,qBAAqB,MACrB,YACA,QAAQ,cACR,aACA,KACA,GAAG,WACC;CACJ,MAAM,EAAE,IAAI,WAAW,WAAW;CAGlC,MAAM,gBAAgB,SAAS,QAAQ,SAAS,CAAC,OAAO,eAAe;CAGvE,MAAM,cAAc,cAAc,KAAK,OAAO,UAAW,MAAM,MAAc,WAAW,MAAM;CAK9F,MAAM,CAAC,cAAc,mBAAmB,cAFZ,uBAAuB,aAE+B;EAChF,UAAU;EACV,OAAO;EACR,CAAC;CAEF,MAAM,eAAe,aAClB,QAAa;EACZ,MAAM,OAAO;EACb,IAAIA;AAEJ,MAAI,UACF,WAAU,KAAK,SAAS,IAAI,GAAG,EAAE,GAAG,CAAC,IAAI;MAEzC,WAAU,KAAK,SAAS,IAAI,GAAG,KAAK,QAAQ,MAAW,MAAM,IAAI,GAAG,CAAC,GAAG,MAAM,IAAI;AAGpF,kBAAgB,QAAQ;IAE1B;EAAC;EAAW;EAAc;EAAgB,CAC3C;CASD,MAAM,eAAe;EACnB;EACA;EACA;EACA;EACA,YAZiB,aAChB,QAAa;AACZ,UAAO,aAAa,SAAS,IAAI;KAEnC,CAAC,aAAa,CACf;EAQC;EACA;EACA,UAAU;EACV;EACA;EACD;CAED,MAAM,UACJ,4CACG,cAAc,KAAK,OAAO,UAAU;EAEnC,MAAM,WAAY,MAAM,MAAc,WAAW;AACjD,SACE,qBAAC,uBACE,OACA,eAAe,QAAQ,cAAc,SAAS,KAC7C,oBAAC,WAAQ,WAAW,OAAO,UAAW,KAH3B,SAKJ;GAEb,GACD;AAGL,QACE,oBAAC,iBAAiB;EAAS,OAAO;YAChC,oBAAC;GACC,WAAW,GAAG,OAAO,MAAM,YAAY,MAAM,cAAc;GACtD;GACL,OAAO;IACA;IACL,GAAG,cAAc;IACjB,GAAG;IACJ;GACD,GAAI;aAEH,mBAAmB,UAAU,oBAAC,yBAAa,UAAsB;IAC9D;GACoB;EAGjC;AAED,UAAU,cAAc;AAExB,wBAAe"}
@@ -1,8 +1,8 @@
1
1
  import { AccordionItemProps } from "./type.mjs";
2
- import * as react26 from "react";
2
+ import * as react14 from "react";
3
3
 
4
4
  //#region src/Accordion/AccordionItem.d.ts
5
- declare const AccordionItem: react26.NamedExoticComponent<AccordionItemProps>;
5
+ declare const AccordionItem: react14.NamedExoticComponent<AccordionItemProps>;
6
6
  //#endregion
7
7
  export { AccordionItem };
8
8
  //# sourceMappingURL=AccordionItem.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { ActionIconProps } from "./type.mjs";
2
- import * as react30 from "react";
2
+ import * as react12 from "react";
3
3
 
4
4
  //#region src/ActionIcon/ActionIcon.d.ts
5
- declare const ActionIcon: react30.NamedExoticComponent<ActionIconProps>;
5
+ declare const ActionIcon: react12.NamedExoticComponent<ActionIconProps>;
6
6
  //#endregion
7
7
  export { ActionIcon };
8
8
  //# sourceMappingURL=ActionIcon.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { AlertProps } from "./type.mjs";
2
- import * as react28 from "react";
2
+ import * as react11 from "react";
3
3
 
4
4
  //#region src/Alert/Alert.d.ts
5
- declare const Alert: react28.NamedExoticComponent<AlertProps>;
5
+ declare const Alert: react11.NamedExoticComponent<AlertProps>;
6
6
  //#endregion
7
7
  export { Alert };
8
8
  //# sourceMappingURL=Alert.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { AutoCompleteProps } from "./type.mjs";
2
- import * as react13 from "react";
2
+ import * as react0 from "react";
3
3
 
4
4
  //#region src/AutoComplete/Select.d.ts
5
- declare const AutoComplete: react13.NamedExoticComponent<AutoCompleteProps>;
5
+ declare const AutoComplete: react0.NamedExoticComponent<AutoCompleteProps>;
6
6
  //#endregion
7
7
  export { AutoComplete };
8
8
  //# sourceMappingURL=Select.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { AvatarGroupProps } from "../type.mjs";
2
- import * as react69 from "react";
2
+ import * as react8 from "react";
3
3
 
4
4
  //#region src/Avatar/AvatarGroup/index.d.ts
5
- declare const AvatarGroup: react69.NamedExoticComponent<AvatarGroupProps>;
5
+ declare const AvatarGroup: react8.NamedExoticComponent<AvatarGroupProps>;
6
6
  //#endregion
7
7
  export { AvatarGroup };
8
8
  //# sourceMappingURL=index.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { BurgerProps } from "./type.mjs";
2
- import * as react14 from "react";
2
+ import * as react7 from "react";
3
3
 
4
4
  //#region src/Burger/Burger.d.ts
5
- declare const Burger: react14.NamedExoticComponent<BurgerProps>;
5
+ declare const Burger: react7.NamedExoticComponent<BurgerProps>;
6
6
  //#endregion
7
7
  export { Burger };
8
8
  //# sourceMappingURL=Burger.d.mts.map
@@ -0,0 +1,8 @@
1
+ import { CheckboxProps } from "./type.mjs";
2
+ import { FC } from "react";
3
+
4
+ //#region src/Checkbox/Checkbox.d.ts
5
+ declare const Checkbox: FC<CheckboxProps>;
6
+ //#endregion
7
+ export { Checkbox };
8
+ //# sourceMappingURL=Checkbox.d.mts.map
@@ -0,0 +1,63 @@
1
+ import FlexBasic_default from "../Flex/FlexBasic.mjs";
2
+ import Block_default from "../Block/Block.mjs";
3
+ import Text_default from "../Text/Text.mjs";
4
+ import { useStyles } from "./style.mjs";
5
+ import { jsx, jsxs } from "react/jsx-runtime";
6
+ import useMergeState from "use-merge-value";
7
+ import { CheckIcon } from "lucide-react";
8
+
9
+ //#region src/Checkbox/Checkbox.tsx
10
+ const Checkbox = ({ checked, defaultChecked, onChange, size = 16, className, style, children, textProps, backgroundColor, classNames, styles: customStyles, shape = "square" }) => {
11
+ const { styles, cx } = useStyles();
12
+ const [value, setValue] = useMergeState(defaultChecked || false, {
13
+ defaultValue: defaultChecked,
14
+ onChange,
15
+ value: checked
16
+ });
17
+ const checkboxStyles = {
18
+ borderRadius: shape === "square" ? `max(4px, ${Math.round(size / 4)}px)` : "50%",
19
+ ...style,
20
+ ...customStyles?.checkbox
21
+ };
22
+ const checkIcon = /* @__PURE__ */ jsx(Block_default, {
23
+ align: "center",
24
+ className: cx(styles.root, value && styles.checked, className, classNames?.checkbox),
25
+ flex: "none",
26
+ height: size,
27
+ justify: "center",
28
+ onClick: () => setValue(!value),
29
+ style: backgroundColor && value ? {
30
+ backgroundColor,
31
+ borderColor: backgroundColor,
32
+ ...checkboxStyles
33
+ } : { ...checkboxStyles },
34
+ variant: "outlined",
35
+ width: size,
36
+ children: value ? /* @__PURE__ */ jsx(CheckIcon, {
37
+ size,
38
+ strokeWidth: 3,
39
+ style: { transform: `scale(${shape === "square" ? .75 : .66})` }
40
+ }) : null
41
+ });
42
+ if (!children) return checkIcon;
43
+ return /* @__PURE__ */ jsxs(FlexBasic_default, {
44
+ align: "center",
45
+ className: classNames?.wrapper,
46
+ gap: Math.floor(size / 2),
47
+ horizontal: true,
48
+ style: customStyles?.wrapper,
49
+ children: [checkIcon, /* @__PURE__ */ jsx(Text_default, {
50
+ as: "span",
51
+ className: cx(classNames?.text),
52
+ style: customStyles?.text,
53
+ ...textProps,
54
+ children
55
+ })]
56
+ });
57
+ };
58
+ Checkbox.displayName = "Checkbox";
59
+ var Checkbox_default = Checkbox;
60
+
61
+ //#endregion
62
+ export { Checkbox_default as default };
63
+ //# sourceMappingURL=Checkbox.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Checkbox.mjs","names":["Checkbox: FC<CheckboxProps>","checkboxStyles: CSSProperties","Block","Flexbox","Text"],"sources":["../../src/Checkbox/Checkbox.tsx"],"sourcesContent":["import { CheckIcon } from 'lucide-react';\nimport type { CSSProperties, FC } from 'react';\nimport useMergeState from 'use-merge-value';\n\nimport Block from '@/Block';\nimport { Flexbox } from '@/Flex';\nimport Text from '@/Text';\n\nimport { useStyles } from './style';\nimport type { CheckboxProps } from './type';\n\nconst Checkbox: FC<CheckboxProps> = ({\n checked,\n defaultChecked,\n onChange,\n size = 16,\n className,\n style,\n children,\n textProps,\n backgroundColor,\n classNames,\n styles: customStyles,\n shape = 'square',\n}) => {\n const { styles, cx } = useStyles();\n const [value, setValue] = useMergeState(defaultChecked || false, {\n defaultValue: defaultChecked,\n onChange,\n value: checked,\n });\n\n const checkboxStyles: CSSProperties = {\n borderRadius: shape === 'square' ? `max(4px, ${Math.round(size / 4)}px)` : '50%',\n ...style,\n ...customStyles?.checkbox,\n };\n\n const checkIcon = (\n <Block\n align={'center'}\n className={cx(styles.root, value && styles.checked, className, classNames?.checkbox)}\n flex={'none'}\n height={size}\n justify={'center'}\n onClick={() => setValue(!value)}\n style={\n backgroundColor && value\n ? { backgroundColor, borderColor: backgroundColor, ...checkboxStyles }\n : { ...checkboxStyles }\n }\n variant={'outlined'}\n width={size}\n >\n {value ? (\n <CheckIcon\n size={size}\n strokeWidth={3}\n style={{\n transform: `scale(${shape === 'square' ? 0.75 : 0.66})`,\n }}\n />\n ) : null}\n </Block>\n );\n\n if (!children) return checkIcon;\n\n return (\n <Flexbox\n align={'center'}\n className={classNames?.wrapper}\n gap={Math.floor(size / 2)}\n horizontal\n style={customStyles?.wrapper}\n >\n {checkIcon}\n <Text as={'span'} className={cx(classNames?.text)} style={customStyles?.text} {...textProps}>\n {children}\n </Text>\n </Flexbox>\n );\n};\n\nCheckbox.displayName = 'Checkbox';\n\nexport default Checkbox;\n"],"mappings":";;;;;;;;;AAWA,MAAMA,YAA+B,EACnC,SACA,gBACA,UACA,OAAO,IACP,WACA,OACA,UACA,WACA,iBACA,YACA,QAAQ,cACR,QAAQ,eACJ;CACJ,MAAM,EAAE,QAAQ,OAAO,WAAW;CAClC,MAAM,CAAC,OAAO,YAAY,cAAc,kBAAkB,OAAO;EAC/D,cAAc;EACd;EACA,OAAO;EACR,CAAC;CAEF,MAAMC,iBAAgC;EACpC,cAAc,UAAU,WAAW,YAAY,KAAK,MAAM,OAAO,EAAE,CAAC,OAAO;EAC3E,GAAG;EACH,GAAG,cAAc;EAClB;CAED,MAAM,YACJ,oBAACC;EACC,OAAO;EACP,WAAW,GAAG,OAAO,MAAM,SAAS,OAAO,SAAS,WAAW,YAAY,SAAS;EACpF,MAAM;EACN,QAAQ;EACR,SAAS;EACT,eAAe,SAAS,CAAC,MAAM;EAC/B,OACE,mBAAmB,QACf;GAAE;GAAiB,aAAa;GAAiB,GAAG;GAAgB,GACpE,EAAE,GAAG,gBAAgB;EAE3B,SAAS;EACT,OAAO;YAEN,QACC,oBAAC;GACO;GACN,aAAa;GACb,OAAO,EACL,WAAW,SAAS,UAAU,WAAW,MAAO,IAAK,IACtD;IACD,GACA;GACE;AAGV,KAAI,CAAC,SAAU,QAAO;AAEtB,QACE,qBAACC;EACC,OAAO;EACP,WAAW,YAAY;EACvB,KAAK,KAAK,MAAM,OAAO,EAAE;EACzB;EACA,OAAO,cAAc;aAEpB,WACD,oBAACC;GAAK,IAAI;GAAQ,WAAW,GAAG,YAAY,KAAK;GAAE,OAAO,cAAc;GAAM,GAAI;GAC/E;IACI;GACC;;AAId,SAAS,cAAc;AAEvB,uBAAe"}
@@ -0,0 +1,3 @@
1
+ import { CheckboxProps } from "./type.mjs";
2
+ import { Checkbox } from "./Checkbox.mjs";
3
+ export { CheckboxProps, Checkbox as default };
@@ -0,0 +1 @@
1
+ export * from './index.d.mts';
@@ -0,0 +1 @@
1
+ export * from './index.mjs';
@@ -0,0 +1,3 @@
1
+ import Checkbox_default from "./Checkbox.mjs";
2
+
3
+ export { Checkbox_default as default };
@@ -0,0 +1,21 @@
1
+ import { createStyles } from "antd-style";
2
+ import { readableColor } from "polished";
3
+
4
+ //#region src/Checkbox/style.ts
5
+ const useStyles = createStyles(({ css: css$1, token }) => {
6
+ return {
7
+ checked: css$1`
8
+ border-color: ${token.colorPrimary};
9
+ color: ${readableColor(token.colorPrimary)};
10
+ background-color: ${token.colorPrimary};
11
+ `,
12
+ root: css$1`
13
+ cursor: pointer;
14
+ display: inline-flex;
15
+ `
16
+ };
17
+ });
18
+
19
+ //#endregion
20
+ export { useStyles };
21
+ //# sourceMappingURL=style.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"style.mjs","names":[],"sources":["../../src/Checkbox/style.ts"],"sourcesContent":["import { createStyles } from 'antd-style';\nimport { readableColor } from 'polished';\n\nexport const useStyles = createStyles(({ css, token }) => {\n return {\n checked: css`\n border-color: ${token.colorPrimary};\n color: ${readableColor(token.colorPrimary)};\n background-color: ${token.colorPrimary};\n `,\n root: css`\n cursor: pointer;\n display: inline-flex;\n `,\n };\n});\n"],"mappings":";;;;AAGA,MAAa,YAAY,cAAc,EAAE,YAAK,YAAY;AACxD,QAAO;EACL,SAAS,KAAG;sBACM,MAAM,aAAa;eAC1B,cAAc,MAAM,aAAa,CAAC;0BACvB,MAAM,aAAa;;EAEzC,MAAM,KAAG;;;;EAIV;EACD"}
@@ -0,0 +1,31 @@
1
+ import { TextProps } from "../Text/type.mjs";
2
+ import "../Text/index.mjs";
3
+ import { CSSProperties, ReactNode } from "react";
4
+
5
+ //#region src/Checkbox/type.d.ts
6
+ interface CheckboxProps {
7
+ backgroundColor?: string;
8
+ checked?: boolean;
9
+ children?: ReactNode;
10
+ className?: string;
11
+ classNames?: {
12
+ checkbox?: string;
13
+ text?: string;
14
+ wrapper?: string;
15
+ };
16
+ defaultChecked?: boolean;
17
+ disabled?: boolean;
18
+ onChange?: (checked: boolean) => void;
19
+ shape?: 'square' | 'circle';
20
+ size?: number;
21
+ style?: CSSProperties;
22
+ styles?: {
23
+ checkbox?: CSSProperties;
24
+ text?: CSSProperties;
25
+ wrapper?: CSSProperties;
26
+ };
27
+ textProps?: Omit<TextProps, 'children' | 'className' | 'style'>;
28
+ }
29
+ //#endregion
30
+ export { CheckboxProps };
31
+ //# sourceMappingURL=type.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { CodeEditorProps } from "./type.mjs";
2
- import * as react24 from "react";
2
+ import * as react6 from "react";
3
3
 
4
4
  //#region src/CodeEditor/CodeEditor.d.ts
5
- declare const CodeEditor: react24.NamedExoticComponent<CodeEditorProps>;
5
+ declare const CodeEditor: react6.NamedExoticComponent<CodeEditorProps>;
6
6
  //#endregion
7
7
  export { CodeEditor };
8
8
  //# sourceMappingURL=CodeEditor.d.mts.map
@@ -5,13 +5,13 @@ import { useStyles } from "./style.mjs";
5
5
  import SyntaxHighlighter_default from "../Highlighter/SyntaxHighlighter/index.mjs";
6
6
  import { memo, useMemo } from "react";
7
7
  import { jsx, jsxs } from "react/jsx-runtime";
8
- import useControlledState from "use-merge-value";
8
+ import useMergeState from "use-merge-value";
9
9
  import { cva } from "class-variance-authority";
10
10
 
11
11
  //#region src/CodeEditor/CodeEditor.tsx
12
12
  const CodeEditor = memo(({ autoFocus, classNames, styles: customStyles, defaultValue = "", onChange, placeholder = "", style, className, onValueChange, value, language = "markdown", variant = "borderless", width, height, flex, ref, ...rest }) => {
13
13
  const { styles, cx, theme } = useStyles();
14
- const [code, setCode] = useControlledState(defaultValue, {
14
+ const [code, setCode] = useMergeState(defaultValue, {
15
15
  defaultValue,
16
16
  onChange: onValueChange,
17
17
  value
@@ -1 +1 @@
1
- {"version":3,"file":"CodeEditor.mjs","names":["useMergeState","Flexbox","SyntaxHighlighter"],"sources":["../../src/CodeEditor/CodeEditor.tsx"],"sourcesContent":["'use client';\n\nimport { cva } from 'class-variance-authority';\nimport { memo, useMemo } from 'react';\nimport useMergeState from 'use-merge-value';\n\nimport { useStyles } from '@/CodeEditor/style';\nimport { Flexbox } from '@/Flex';\nimport SyntaxHighlighter from '@/Highlighter/SyntaxHighlighter';\n\nimport { CodeEditorProps } from './type';\n\nconst CodeEditor = memo<CodeEditorProps>(\n ({\n autoFocus,\n classNames,\n styles: customStyles,\n defaultValue = '',\n onChange,\n placeholder = '',\n style,\n className,\n onValueChange,\n value,\n language = 'markdown',\n variant = 'borderless',\n width,\n height,\n flex,\n ref,\n ...rest\n }) => {\n const { styles, cx, theme } = useStyles();\n const [code, setCode] = useMergeState(defaultValue, {\n defaultValue,\n onChange: onValueChange,\n value,\n });\n\n const variants = useMemo(\n () =>\n cva(styles.root, {\n defaultVariants: {\n variant: 'borderless',\n },\n /* eslint-disable sort-keys-fix/sort-keys-fix */\n variants: {\n variant: {\n filled: styles.filled,\n outlined: styles.outlined,\n borderless: styles.borderless,\n },\n },\n /* eslint-enable sort-keys-fix/sort-keys-fix */\n }),\n [styles],\n );\n\n return (\n <Flexbox\n className={cx(variants({ variant }), className)}\n flex={flex}\n height={height}\n style={style}\n width={width}\n >\n {value ? (\n <SyntaxHighlighter\n className={cx(styles.highlight, classNames?.highlight)}\n language={language}\n style={customStyles?.highlight}\n variant={variant}\n >\n {value}\n </SyntaxHighlighter>\n ) : (\n <pre\n className={cx(styles.highlight, classNames?.highlight)}\n style={{\n color: theme.colorTextDescription,\n }}\n >\n {placeholder || ' '}\n </pre>\n )}\n\n <textarea\n autoCapitalize=\"off\"\n autoComplete=\"off\"\n autoCorrect=\"off\"\n autoFocus={autoFocus}\n className={cx(styles.textarea, classNames?.textarea)}\n data-gramm={false}\n onChange={(e) => {\n onChange?.(e);\n setCode(e.target.value);\n }}\n ref={ref}\n style={customStyles?.textarea}\n value={code}\n {...rest}\n />\n </Flexbox>\n );\n },\n);\n\nCodeEditor.displayName = 'CodeEditor';\n\nexport default CodeEditor;\n"],"mappings":";;;;;;;;;;;AAYA,MAAM,aAAa,MAChB,EACC,WACA,YACA,QAAQ,cACR,eAAe,IACf,UACA,cAAc,IACd,OACA,WACA,eACA,OACA,WAAW,YACX,UAAU,cACV,OACA,QACA,MACA,KACA,GAAG,WACC;CACJ,MAAM,EAAE,QAAQ,IAAI,UAAU,WAAW;CACzC,MAAM,CAAC,MAAM,WAAWA,mBAAc,cAAc;EAClD;EACA,UAAU;EACV;EACD,CAAC;AAqBF,QACE,qBAACC;EACC,WAAW,GArBE,cAEb,IAAI,OAAO,MAAM;GACf,iBAAiB,EACf,SAAS,cACV;GAED,UAAU,EACR,SAAS;IACP,QAAQ,OAAO;IACf,UAAU,OAAO;IACjB,YAAY,OAAO;IACpB,EACF;GAEF,CAAC,EACJ,CAAC,OAAO,CACT,CAI0B,EAAE,SAAS,CAAC,EAAE,UAAU;EACzC;EACE;EACD;EACA;aAEN,QACC,oBAACC;GACC,WAAW,GAAG,OAAO,WAAW,YAAY,UAAU;GAC5C;GACV,OAAO,cAAc;GACZ;aAER;IACiB,GAEpB,oBAAC;GACC,WAAW,GAAG,OAAO,WAAW,YAAY,UAAU;GACtD,OAAO,EACL,OAAO,MAAM,sBACd;aAEA,eAAe;IACZ,EAGR,oBAAC;GACC,gBAAe;GACf,cAAa;GACb,aAAY;GACD;GACX,WAAW,GAAG,OAAO,UAAU,YAAY,SAAS;GACpD,cAAY;GACZ,WAAW,MAAM;AACf,eAAW,EAAE;AACb,YAAQ,EAAE,OAAO,MAAM;;GAEpB;GACL,OAAO,cAAc;GACrB,OAAO;GACP,GAAI;IACJ;GACM;EAGf;AAED,WAAW,cAAc;AAEzB,yBAAe"}
1
+ {"version":3,"file":"CodeEditor.mjs","names":["Flexbox","SyntaxHighlighter"],"sources":["../../src/CodeEditor/CodeEditor.tsx"],"sourcesContent":["'use client';\n\nimport { cva } from 'class-variance-authority';\nimport { memo, useMemo } from 'react';\nimport useMergeState from 'use-merge-value';\n\nimport { useStyles } from '@/CodeEditor/style';\nimport { Flexbox } from '@/Flex';\nimport SyntaxHighlighter from '@/Highlighter/SyntaxHighlighter';\n\nimport { CodeEditorProps } from './type';\n\nconst CodeEditor = memo<CodeEditorProps>(\n ({\n autoFocus,\n classNames,\n styles: customStyles,\n defaultValue = '',\n onChange,\n placeholder = '',\n style,\n className,\n onValueChange,\n value,\n language = 'markdown',\n variant = 'borderless',\n width,\n height,\n flex,\n ref,\n ...rest\n }) => {\n const { styles, cx, theme } = useStyles();\n const [code, setCode] = useMergeState(defaultValue, {\n defaultValue,\n onChange: onValueChange,\n value,\n });\n\n const variants = useMemo(\n () =>\n cva(styles.root, {\n defaultVariants: {\n variant: 'borderless',\n },\n /* eslint-disable sort-keys-fix/sort-keys-fix */\n variants: {\n variant: {\n filled: styles.filled,\n outlined: styles.outlined,\n borderless: styles.borderless,\n },\n },\n /* eslint-enable sort-keys-fix/sort-keys-fix */\n }),\n [styles],\n );\n\n return (\n <Flexbox\n className={cx(variants({ variant }), className)}\n flex={flex}\n height={height}\n style={style}\n width={width}\n >\n {value ? (\n <SyntaxHighlighter\n className={cx(styles.highlight, classNames?.highlight)}\n language={language}\n style={customStyles?.highlight}\n variant={variant}\n >\n {value}\n </SyntaxHighlighter>\n ) : (\n <pre\n className={cx(styles.highlight, classNames?.highlight)}\n style={{\n color: theme.colorTextDescription,\n }}\n >\n {placeholder || ' '}\n </pre>\n )}\n\n <textarea\n autoCapitalize=\"off\"\n autoComplete=\"off\"\n autoCorrect=\"off\"\n autoFocus={autoFocus}\n className={cx(styles.textarea, classNames?.textarea)}\n data-gramm={false}\n onChange={(e) => {\n onChange?.(e);\n setCode(e.target.value);\n }}\n ref={ref}\n style={customStyles?.textarea}\n value={code}\n {...rest}\n />\n </Flexbox>\n );\n },\n);\n\nCodeEditor.displayName = 'CodeEditor';\n\nexport default CodeEditor;\n"],"mappings":";;;;;;;;;;;AAYA,MAAM,aAAa,MAChB,EACC,WACA,YACA,QAAQ,cACR,eAAe,IACf,UACA,cAAc,IACd,OACA,WACA,eACA,OACA,WAAW,YACX,UAAU,cACV,OACA,QACA,MACA,KACA,GAAG,WACC;CACJ,MAAM,EAAE,QAAQ,IAAI,UAAU,WAAW;CACzC,MAAM,CAAC,MAAM,WAAW,cAAc,cAAc;EAClD;EACA,UAAU;EACV;EACD,CAAC;AAqBF,QACE,qBAACA;EACC,WAAW,GArBE,cAEb,IAAI,OAAO,MAAM;GACf,iBAAiB,EACf,SAAS,cACV;GAED,UAAU,EACR,SAAS;IACP,QAAQ,OAAO;IACf,UAAU,OAAO;IACjB,YAAY,OAAO;IACpB,EACF;GAEF,CAAC,EACJ,CAAC,OAAO,CACT,CAI0B,EAAE,SAAS,CAAC,EAAE,UAAU;EACzC;EACE;EACD;EACA;aAEN,QACC,oBAACC;GACC,WAAW,GAAG,OAAO,WAAW,YAAY,UAAU;GAC5C;GACV,OAAO,cAAc;GACZ;aAER;IACiB,GAEpB,oBAAC;GACC,WAAW,GAAG,OAAO,WAAW,YAAY,UAAU;GACtD,OAAO,EACL,OAAO,MAAM,sBACd;aAEA,eAAe;IACZ,EAGR,oBAAC;GACC,gBAAe;GACf,cAAa;GACb,aAAY;GACD;GACX,WAAW,GAAG,OAAO,UAAU,YAAY,SAAS;GACpD,cAAY;GACZ,WAAW,MAAM;AACf,eAAW,EAAE;AACb,YAAQ,EAAE,OAAO,MAAM;;GAEpB;GACL,OAAO,cAAc;GACrB,OAAO;GACP,GAAI;IACJ;GACM;EAGf;AAED,WAAW,cAAc;AAEzB,yBAAe"}
@@ -1,8 +1,8 @@
1
1
  import { CollapseProps } from "./type.mjs";
2
- import * as react23 from "react";
2
+ import * as react5 from "react";
3
3
 
4
4
  //#region src/Collapse/Collapse.d.ts
5
- declare const Collapse: react23.NamedExoticComponent<CollapseProps>;
5
+ declare const Collapse: react5.NamedExoticComponent<CollapseProps>;
6
6
  //#endregion
7
7
  export { Collapse };
8
8
  //# sourceMappingURL=Collapse.d.mts.map
@@ -8,14 +8,14 @@ import { useStyles } from "./style.mjs";
8
8
  import { useMemo } from "react";
9
9
  import { jsx, jsxs } from "react/jsx-runtime";
10
10
  import { ColorPicker } from "antd";
11
- import useControlledState from "use-merge-value";
11
+ import useMergeState from "use-merge-value";
12
12
  import { CheckIcon } from "lucide-react";
13
13
  import { readableColor, rgba } from "polished";
14
14
  import chroma from "chroma-js";
15
15
 
16
16
  //#region src/ColorSwatches/ColorSwatches.tsx
17
17
  const ColorSwatches = ({ enableColorPicker, enableColorSwatches = true, defaultValue, value, style, colors, onChange, size = 24, shape = "circle", texts, ref, ...rest }) => {
18
- const [active, setActive] = useControlledState(defaultValue, {
18
+ const [active, setActive] = useMergeState(defaultValue, {
19
19
  defaultValue,
20
20
  onChange,
21
21
  value
@@ -1 +1 @@
1
- {"version":3,"file":"ColorSwatches.mjs","names":["ColorSwatches: FC<ColorSwatchesProps>","useMergeState","Flexbox","Tooltip","Center","Icon"],"sources":["../../src/ColorSwatches/ColorSwatches.tsx"],"sourcesContent":["'use client';\n\nimport { ColorPicker } from 'antd';\nimport chroma from 'chroma-js';\nimport { CheckIcon } from 'lucide-react';\nimport { readableColor, rgba } from 'polished';\nimport { type FC, useMemo } from 'react';\nimport useMergeState from 'use-merge-value';\n\nimport { Center, Flexbox } from '@/Flex';\nimport Icon from '@/Icon';\nimport Tooltip from '@/Tooltip';\n\nimport { useStyles } from './style';\nimport type { ColorSwatchesProps } from './type';\n\nconst ColorSwatches: FC<ColorSwatchesProps> = ({\n enableColorPicker,\n enableColorSwatches = true,\n defaultValue,\n value,\n style,\n colors,\n onChange,\n size = 24,\n shape = 'circle',\n texts,\n ref,\n ...rest\n}) => {\n const [active, setActive] = useMergeState(defaultValue, {\n defaultValue,\n onChange,\n value,\n });\n const { cx, styles, theme } = useStyles(size);\n\n const isCustomActive = useMemo(\n () => active && active !== theme.colorPrimary && !colors.some((c) => c.color === active),\n [active, colors, theme.colorPrimary],\n );\n\n return (\n <Flexbox gap={6} horizontal ref={ref} style={{ flexWrap: 'wrap', ...style }} {...rest}>\n {enableColorSwatches &&\n colors.map((c, i) => {\n const color = c.color || theme.colorPrimary;\n const isActive = (!active && !c.color) || color === active;\n const isTransparent = c.color === 'transparent' || chroma(c.color).alpha() === 0;\n return (\n <Tooltip key={c?.key || i} title={c.title}>\n <Center\n className={cx(\n styles.container,\n isTransparent && styles.transparent,\n isActive && styles.active,\n )}\n onClick={() => setActive(c.color || undefined)}\n style={{\n background: isTransparent ? undefined : color,\n borderRadius: shape === 'circle' ? '50%' : theme.borderRadius,\n }}\n >\n {isActive && (\n <Icon\n color={rgba(readableColor(color), 0.33)}\n icon={CheckIcon}\n size={{ size: 14, strokeWidth: 4 }}\n style={{\n pointerEvents: 'none',\n }}\n />\n )}\n </Center>\n </Tooltip>\n );\n })}\n {enableColorPicker && (\n <Tooltip title={texts?.custom || 'Custom'}>\n <ColorPicker\n arrow={false}\n className={cx(\n styles.picker,\n enableColorSwatches && styles.conic,\n isCustomActive && styles.active,\n )}\n defaultValue={theme.colorPrimary}\n disabledAlpha\n format={'hex'}\n onChangeComplete={(c) => {\n if (c.toHexString() === theme.colorPrimary) {\n setActive('');\n } else {\n setActive(c.toHexString());\n }\n }}\n presets={\n enableColorSwatches\n ? undefined\n : [\n {\n colors: colors.map((c) => c.color),\n label: texts?.presets || 'Presets',\n },\n ]\n }\n style={{\n borderRadius: shape === 'circle' ? '50%' : theme.borderRadius,\n }}\n value={enableColorSwatches ? undefined : active}\n />\n </Tooltip>\n )}\n </Flexbox>\n );\n};\n\nColorSwatches.displayName = 'ColorSwatches';\n\nexport default ColorSwatches;\n"],"mappings":";;;;;;;;;;;;;;;;AAgBA,MAAMA,iBAAyC,EAC7C,mBACA,sBAAsB,MACtB,cACA,OACA,OACA,QACA,UACA,OAAO,IACP,QAAQ,UACR,OACA,KACA,GAAG,WACC;CACJ,MAAM,CAAC,QAAQ,aAAaC,mBAAc,cAAc;EACtD;EACA;EACA;EACD,CAAC;CACF,MAAM,EAAE,IAAI,QAAQ,UAAU,UAAU,KAAK;CAE7C,MAAM,iBAAiB,cACf,UAAU,WAAW,MAAM,gBAAgB,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AAQ,MAAM,cAClD;IACD,OAAO,sBAAsB,SAAY;KACzC;IACM;GAEJ;;AAId,cAAc,cAAc;AAE5B,4BAAe"}
1
+ {"version":3,"file":"ColorSwatches.mjs","names":["ColorSwatches: FC<ColorSwatchesProps>","Flexbox","Tooltip","Center","Icon"],"sources":["../../src/ColorSwatches/ColorSwatches.tsx"],"sourcesContent":["'use client';\n\nimport { ColorPicker } from 'antd';\nimport chroma from 'chroma-js';\nimport { CheckIcon } from 'lucide-react';\nimport { readableColor, rgba } from 'polished';\nimport { type FC, useMemo } from 'react';\nimport useMergeState from 'use-merge-value';\n\nimport { Center, Flexbox } from '@/Flex';\nimport Icon from '@/Icon';\nimport Tooltip from '@/Tooltip';\n\nimport { useStyles } from './style';\nimport type { ColorSwatchesProps } from './type';\n\nconst ColorSwatches: FC<ColorSwatchesProps> = ({\n enableColorPicker,\n enableColorSwatches = true,\n defaultValue,\n value,\n style,\n colors,\n onChange,\n size = 24,\n shape = 'circle',\n texts,\n ref,\n ...rest\n}) => {\n const [active, setActive] = useMergeState(defaultValue, {\n defaultValue,\n onChange,\n value,\n });\n const { cx, styles, theme } = useStyles(size);\n\n const isCustomActive = useMemo(\n () => active && active !== theme.colorPrimary && !colors.some((c) => c.color === active),\n [active, colors, theme.colorPrimary],\n );\n\n return (\n <Flexbox gap={6} horizontal ref={ref} style={{ flexWrap: 'wrap', ...style }} {...rest}>\n {enableColorSwatches &&\n colors.map((c, i) => {\n const color = c.color || theme.colorPrimary;\n const isActive = (!active && !c.color) || color === active;\n const isTransparent = c.color === 'transparent' || chroma(c.color).alpha() === 0;\n return (\n <Tooltip key={c?.key || i} title={c.title}>\n <Center\n className={cx(\n styles.container,\n isTransparent && styles.transparent,\n isActive && styles.active,\n )}\n onClick={() => setActive(c.color || undefined)}\n style={{\n background: isTransparent ? undefined : color,\n borderRadius: shape === 'circle' ? '50%' : theme.borderRadius,\n }}\n >\n {isActive && (\n <Icon\n color={rgba(readableColor(color), 0.33)}\n icon={CheckIcon}\n size={{ size: 14, strokeWidth: 4 }}\n style={{\n pointerEvents: 'none',\n }}\n />\n )}\n </Center>\n </Tooltip>\n );\n })}\n {enableColorPicker && (\n <Tooltip title={texts?.custom || 'Custom'}>\n <ColorPicker\n arrow={false}\n className={cx(\n styles.picker,\n enableColorSwatches && styles.conic,\n isCustomActive && styles.active,\n )}\n defaultValue={theme.colorPrimary}\n disabledAlpha\n format={'hex'}\n onChangeComplete={(c) => {\n if (c.toHexString() === theme.colorPrimary) {\n setActive('');\n } else {\n setActive(c.toHexString());\n }\n }}\n presets={\n enableColorSwatches\n ? undefined\n : [\n {\n colors: colors.map((c) => c.color),\n label: texts?.presets || 'Presets',\n },\n ]\n }\n style={{\n borderRadius: shape === 'circle' ? '50%' : theme.borderRadius,\n }}\n value={enableColorSwatches ? undefined : active}\n />\n </Tooltip>\n )}\n </Flexbox>\n );\n};\n\nColorSwatches.displayName = 'ColorSwatches';\n\nexport default ColorSwatches;\n"],"mappings":";;;;;;;;;;;;;;;;AAgBA,MAAMA,iBAAyC,EAC7C,mBACA,sBAAsB,MACtB,cACA,OACA,OACA,QACA,UACA,OAAO,IACP,QAAQ,UACR,OACA,KACA,GAAG,WACC;CACJ,MAAM,CAAC,QAAQ,aAAa,cAAc,cAAc;EACtD;EACA;EACA;EACD,CAAC;CACF,MAAM,EAAE,IAAI,QAAQ,UAAU,UAAU,KAAK;CAE7C,MAAM,iBAAiB,cACf,UAAU,WAAW,MAAM,gBAAgB,CAAC,OAAO,MAAM,MAAM,EAAE,UAAU,OAAO,EACxF;EAAC;EAAQ;EAAQ,MAAM;EAAa,CACrC;AAED,QACE,qBAACC;EAAQ,KAAK;EAAG;EAAgB;EAAK,OAAO;GAAE,UAAU;GAAQ,GAAG;GAAO;EAAE,GAAI;aAC9E,uBACC,OAAO,KAAK,GAAG,MAAM;GACnB,MAAM,QAAQ,EAAE,SAAS,MAAM;GAC/B,MAAM,WAAY,CAAC,UAAU,CAAC,EAAE,SAAU,UAAU;GACpD,MAAM,gBAAgB,EAAE,UAAU,iBAAiB,OAAO,EAAE,MAAM,CAAC,OAAO,KAAK;AAC/E,UACE,oBAACC;IAA0B,OAAO,EAAE;cAClC,oBAACC;KACC,WAAW,GACT,OAAO,WACP,iBAAiB,OAAO,aACxB,YAAY,OAAO,OACpB;KACD,eAAe,UAAU,EAAE,SAAS,OAAU;KAC9C,OAAO;MACL,YAAY,gBAAgB,SAAY;MACxC,cAAc,UAAU,WAAW,QAAQ,MAAM;MAClD;eAEA,YACC,oBAACC;MACC,OAAO,KAAK,cAAc,MAAM,EAAE,IAAK;MACvC,MAAM;MACN,MAAM;OAAE,MAAM;OAAI,aAAa;OAAG;MAClC,OAAO,EACL,eAAe,QAChB;OACD;MAEG;MAvBG,GAAG,OAAO,EAwBd;IAEZ,EACH,qBACC,oBAACF;GAAQ,OAAO,OAAO,UAAU;aAC/B,oBAAC;IACC,OAAO;IACP,WAAW,GACT,OAAO,QACP,uBAAuB,OAAO,OAC9B,kBAAkB,OAAO,OAC1B;IACD,cAAc,MAAM;IACpB;IACA,QAAQ;IACR,mBAAmB,MAAM;AACvB,SAAI,EAAE,aAAa,KAAK,MAAM,aAC5B,WAAU,GAAG;SAEb,WAAU,EAAE,aAAa,CAAC;;IAG9B,SACE,sBACI,SACA,CACE;KACE,QAAQ,OAAO,KAAK,MAAM,EAAE,MAAM;KAClC,OAAO,OAAO,WAAW;KAC1B,CACF;IAEP,OAAO,EACL,cAAc,UAAU,WAAW,QAAQ,MAAM,cAClD;IACD,OAAO,sBAAsB,SAAY;KACzC;IACM;GAEJ;;AAId,cAAc,cAAc;AAE5B,4BAAe"}
@@ -1,7 +1,7 @@
1
1
  import { MotionComponentType } from "../MotionProvider/index.mjs";
2
2
  import { TranslationResourcesInput } from "../i18n/types.mjs";
3
3
  import { CDN, CdnApi } from "../utils/genCdnUrl.mjs";
4
- import * as react59 from "react";
4
+ import * as react28 from "react";
5
5
  import { ElementType, ReactNode } from "react";
6
6
 
7
7
  //#region src/ConfigProvider/index.d.ts
@@ -19,7 +19,7 @@ interface ConfigProviderProps {
19
19
  motion: MotionComponentType;
20
20
  resources?: TranslationResourcesInput;
21
21
  }
22
- declare const ConfigProvider: react59.NamedExoticComponent<ConfigProviderProps>;
22
+ declare const ConfigProvider: react28.NamedExoticComponent<ConfigProviderProps>;
23
23
  type CdnFn = ({
24
24
  pkg,
25
25
  version,
@@ -1,8 +1,8 @@
1
1
  import { CopyButtonProps } from "./type.mjs";
2
- import * as react15 from "react";
2
+ import * as react4 from "react";
3
3
 
4
4
  //#region src/CopyButton/CopyButton.d.ts
5
- declare const CopyButton: react15.NamedExoticComponent<CopyButtonProps>;
5
+ declare const CopyButton: react4.NamedExoticComponent<CopyButtonProps>;
6
6
  //#endregion
7
7
  export { CopyButton };
8
8
  //# sourceMappingURL=CopyButton.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { DatePickerProps } from "./type.mjs";
2
- import * as react22 from "react";
2
+ import * as react67 from "react";
3
3
 
4
4
  //#region src/DatePicker/DatePicker.d.ts
5
- declare const DatePicker: react22.NamedExoticComponent<DatePickerProps>;
5
+ declare const DatePicker: react67.NamedExoticComponent<DatePickerProps>;
6
6
  //#endregion
7
7
  export { DatePicker };
8
8
  //# sourceMappingURL=DatePicker.d.mts.map
@@ -7,7 +7,7 @@ import { reversePlacement } from "./utils.mjs";
7
7
  import { memo, use, useCallback, useEffect, useMemo, useReducer, useRef, useTransition } from "react";
8
8
  import { jsx, jsxs } from "react/jsx-runtime";
9
9
  import { ConfigProvider } from "antd";
10
- import useControlledState from "use-merge-value";
10
+ import useMergeState from "use-merge-value";
11
11
  import { cva } from "class-variance-authority";
12
12
  import { useHover } from "ahooks";
13
13
  import { ChevronDown, ChevronLeft, ChevronRight, ChevronUp } from "lucide-react";
@@ -58,7 +58,7 @@ const DraggablePanel = memo(({ headerHeight = DEFAULT_HEADER_HEIGHT, fullscreen,
58
58
  showBorder,
59
59
  showHandleWideArea
60
60
  });
61
- const [isExpand, setIsExpand] = useControlledState(defaultExpand, {
61
+ const [isExpand, setIsExpand] = useMergeState(defaultExpand, {
62
62
  onChange: onExpandChange,
63
63
  value: expand
64
64
  });
@@ -1 +1 @@
1
- {"version":3,"file":"DraggablePanel.mjs","names":["defaultSize: Size","Center","Icon"],"sources":["../../src/DraggablePanel/DraggablePanel.tsx"],"sourcesContent":["'use client';\n\nimport { useHover } from 'ahooks';\nimport { ConfigProvider } from 'antd';\nimport { cva } from 'class-variance-authority';\nimport { ChevronDown, ChevronLeft, ChevronRight, ChevronUp } from 'lucide-react';\nimport type { Enable, NumberSize, Size } from 're-resizable';\nimport { Resizable } from 're-resizable';\nimport {\n memo,\n use,\n useCallback,\n useEffect,\n useMemo,\n useReducer,\n useRef,\n useTransition,\n} from 'react';\nimport useControlledState from 'use-merge-value';\n\nimport { Center } from '@/Flex';\nimport Icon from '@/Icon';\n\nimport { useStyles } from './style';\nimport type { DraggablePanelProps } from './type';\nimport { reversePlacement } from './utils';\n\n// Constants\nconst DEFAULT_HEIGHT = 180;\nconst DEFAULT_WIDTH = 280;\nconst DEFAULT_HEADER_HEIGHT = 0;\nconst DEFAULT_PIN = true;\nconst DEFAULT_MODE = 'fixed';\nconst DEFAULT_EXPANDABLE = true;\nconst DEFAULT_EXPAND = true;\nconst DEFAULT_SHOW_HANDLE_WIDE_AREA = true;\n\n// State reducer for better state management\ninterface DraggablePanelState {\n isResizing: boolean;\n showExpand: boolean;\n}\n\ntype DraggablePanelAction =\n | { type: 'START_RESIZE' }\n | { type: 'STOP_RESIZE' }\n | { payload: boolean; type: 'SET_SHOW_EXPAND' };\n\nfunction draggablePanelReducer(\n state: DraggablePanelState,\n action: DraggablePanelAction,\n): DraggablePanelState {\n switch (action.type) {\n case 'START_RESIZE': {\n return { ...state, isResizing: true, showExpand: false };\n }\n case 'STOP_RESIZE': {\n return { ...state, isResizing: false, showExpand: true };\n }\n case 'SET_SHOW_EXPAND': {\n return { ...state, showExpand: action.payload };\n }\n default: {\n return state;\n }\n }\n}\n\nconst DraggablePanel = memo<DraggablePanelProps>(\n ({\n headerHeight = DEFAULT_HEADER_HEIGHT,\n fullscreen,\n maxHeight,\n pin = DEFAULT_PIN,\n mode = DEFAULT_MODE,\n children,\n placement = 'right',\n resize,\n style,\n showBorder = true,\n showHandleHighlight = false,\n showHandleWideArea = DEFAULT_SHOW_HANDLE_WIDE_AREA,\n backgroundColor,\n size,\n defaultSize: customizeDefaultSize,\n minWidth,\n minHeight,\n maxWidth,\n onSizeChange,\n onSizeDragging,\n expandable = DEFAULT_EXPANDABLE,\n expand,\n defaultExpand = DEFAULT_EXPAND,\n onExpandChange,\n className,\n showHandleWhenCollapsed,\n destroyOnClose,\n styles: customStyles,\n classNames,\n dir,\n }) => {\n const ref = useRef<HTMLDivElement>(null);\n const isHovering = useHover(ref);\n const isVertical = placement === 'top' || placement === 'bottom';\n const [isPending, startTransition] = useTransition();\n\n // Use ref for hover timeout to avoid memory leaks\n const hoverTimeoutRef = useRef<any>(undefined);\n\n // inherit direction from Ant Design ConfigProvider\n const { direction: antdDirection } = use(ConfigProvider.ConfigContext);\n const direction = dir ?? antdDirection;\n\n // Handle RTL direction\n const internalPlacement = useMemo(() => {\n return direction === 'rtl' && ['left', 'right'].includes(placement)\n ? placement === 'left'\n ? 'right'\n : 'left'\n : placement;\n }, [direction, placement]);\n\n const { styles, cx } = useStyles({\n backgroundColor,\n headerHeight,\n showBorder,\n showHandleWideArea,\n });\n\n const [isExpand, setIsExpand] = useControlledState(defaultExpand, {\n onChange: onExpandChange,\n value: expand,\n });\n\n // Initialize state with useReducer for better performance\n const initialState: DraggablePanelState = {\n isResizing: false,\n showExpand: true,\n };\n\n const [state, dispatch] = useReducer(draggablePanelReducer, initialState);\n\n // Auto-expand on hover if not pinned with optimized transition\n useEffect(() => {\n if (pin) return;\n\n // Clear previous timeout\n if (hoverTimeoutRef.current) {\n clearTimeout(hoverTimeoutRef.current);\n }\n\n if (isHovering && !isExpand) {\n startTransition(() => {\n setIsExpand(true);\n });\n } else if (!isHovering && isExpand) {\n // Add a small delay before collapsing to prevent flickering\n hoverTimeoutRef.current = setTimeout(() => {\n startTransition(() => {\n setIsExpand(false);\n });\n }, 150);\n }\n }, [pin, isHovering, isExpand, setIsExpand]);\n\n // Cleanup timeout on unmount\n useEffect(() => {\n return () => {\n if (hoverTimeoutRef.current) {\n clearTimeout(hoverTimeoutRef.current);\n }\n };\n }, []);\n\n const canResizing = resize !== false && isExpand;\n\n // Style variants for the panel\n const variants = useMemo(\n () =>\n cva(styles.root, {\n compoundVariants: [\n {\n class: styles.bottomFloat,\n mode: 'float',\n placement: 'bottom',\n },\n {\n class: styles.topFloat,\n mode: 'float',\n placement: 'top',\n },\n {\n class: styles.leftFloat,\n mode: 'float',\n placement: 'left',\n },\n {\n class: styles.rightFloat,\n mode: 'float',\n placement: 'right',\n },\n ],\n /* eslint-disable sort-keys-fix/sort-keys-fix */\n variants: {\n placement: {\n top: isExpand && styles.borderBottom,\n right: isExpand && styles.borderLeft,\n bottom: isExpand && styles.borderTop,\n left: isExpand && styles.borderRight,\n },\n mode: {\n fixed: styles.fixed,\n float: null,\n },\n },\n /* eslint-enable sort-keys-fix/sort-keys-fix */\n }),\n [styles, isExpand],\n );\n\n // Style variants for the handle\n const handleVariants = useMemo(\n () =>\n cva(styles.handleRoot, {\n variants: {\n placement: {\n bottom: styles.handleBottom,\n left: styles.handleLeft,\n right: styles.handleRight,\n top: styles.handleTop,\n },\n },\n }),\n [styles],\n );\n\n // Style variants for the toggle button\n const toggleVariants = useMemo(\n () =>\n cva(styles.toggleRoot, {\n variants: {\n placement: {\n bottom: styles.toggleTop,\n left: styles.toggleRight,\n right: styles.toggleLeft,\n top: styles.toggleBottom,\n },\n },\n }),\n [styles],\n );\n\n // Configure resizing handles\n const resizing = useMemo(\n () => ({\n bottom: false,\n bottomLeft: false,\n bottomRight: false,\n left: false,\n right: false,\n top: false,\n topLeft: false,\n topRight: false,\n [reversePlacement(internalPlacement)]: true,\n ...(resize as Enable),\n }),\n [internalPlacement, resize],\n );\n\n // Calculate default size based on orientation\n const defaultSize: Size = useMemo(() => {\n if (isVertical)\n return {\n height: DEFAULT_HEIGHT,\n width: '100%',\n ...customizeDefaultSize,\n };\n\n return {\n height: '100%',\n width: DEFAULT_WIDTH,\n ...customizeDefaultSize,\n };\n }, [isVertical, customizeDefaultSize]);\n\n // Determine appropriate size props based on expand state\n const sizeProps = useMemo(() => {\n if (!isExpand) {\n return isVertical\n ? { minHeight: 0, size: { height: 0 } }\n : { minWidth: 0, size: { width: 0 } };\n }\n\n return {\n defaultSize,\n maxHeight: typeof maxHeight === 'number' ? Math.max(maxHeight, 0) : maxHeight,\n maxWidth: typeof maxWidth === 'number' ? Math.max(maxWidth, 0) : maxWidth,\n minHeight: typeof minHeight === 'number' ? Math.max(minHeight, 0) : minHeight,\n minWidth: typeof minWidth === 'number' ? Math.max(minWidth, 0) : minWidth,\n size: size as Size,\n };\n }, [isExpand, isVertical, defaultSize, maxHeight, maxWidth, minHeight, minWidth, size]);\n\n // Determine the appropriate arrow icon based on placement\n const Arrow = useMemo(() => {\n switch (internalPlacement) {\n case 'top': {\n return ChevronDown;\n }\n case 'bottom': {\n return ChevronUp;\n }\n case 'right': {\n return ChevronLeft;\n }\n case 'left': {\n return ChevronRight;\n }\n default: {\n return ChevronLeft;\n }\n }\n }, [internalPlacement]);\n\n // Toggle expand state with transition for better performance\n const toggleExpand = useCallback(() => {\n if (!expandable) return;\n\n startTransition(() => {\n setIsExpand(!isExpand);\n });\n }, [expandable, isExpand, setIsExpand]);\n\n // Toggle handle component\n const handle = useMemo(\n () => (\n <Center\n className={toggleVariants({ placement: internalPlacement })}\n style={{ opacity: isExpand ? (pin ? undefined : 0) : showHandleWhenCollapsed ? 1 : 0 }}\n >\n <Center\n className={classNames?.handle}\n onClick={toggleExpand}\n style={customStyles?.handle}\n >\n <Icon\n className={styles.handlerIcon}\n icon={Arrow}\n size={16}\n style={{\n marginBottom: internalPlacement === 'top' ? 4 : 0,\n marginLeft: internalPlacement === 'right' ? 4 : 0,\n marginRight: internalPlacement === 'left' ? 4 : 0,\n marginTop: internalPlacement === 'bottom' ? 4 : 0,\n transform: `rotate(${isExpand ? 180 : 0}deg)`,\n transition: 'transform 0.3s ease',\n }}\n />\n </Center>\n </Center>\n ),\n [\n toggleVariants,\n internalPlacement,\n isExpand,\n pin,\n showHandleWhenCollapsed,\n classNames?.handle,\n toggleExpand,\n customStyles?.handle,\n styles.handlerIcon,\n Arrow,\n ],\n );\n\n // Handle resize events with memoization\n const handleResize = useCallback(\n (_: unknown, _direction: unknown, reference_: HTMLElement, delta: NumberSize) => {\n onSizeDragging?.(delta, {\n height: reference_.style.height,\n width: reference_.style.width,\n });\n },\n [onSizeDragging],\n );\n\n const handleResizeStart = useCallback(() => {\n dispatch({ type: 'START_RESIZE' });\n }, []);\n\n const handleResizeStop = useCallback(\n (e: unknown, direction: unknown, reference_: HTMLElement, delta: NumberSize) => {\n dispatch({ type: 'STOP_RESIZE' });\n onSizeChange?.(delta, {\n height: reference_.style.height,\n width: reference_.style.width,\n });\n },\n [onSizeChange],\n );\n\n // Main panel content\n const inner = useMemo(\n () => (\n <Resizable\n {...sizeProps}\n className={cx(styles.panel, classNames?.content)}\n enable={canResizing ? (resizing as Enable) : undefined}\n handleClasses={\n canResizing\n ? {\n [reversePlacement(internalPlacement)]: cx(\n handleVariants({\n placement: reversePlacement(internalPlacement),\n }),\n showHandleHighlight && styles.handleHighlight,\n ),\n }\n : {}\n }\n onResize={handleResize}\n onResizeStart={handleResizeStart}\n onResizeStop={handleResizeStop}\n style={{\n opacity: isPending ? 0.95 : 1,\n transition: state.isResizing ? 'unset' : undefined,\n ...style,\n }}\n >\n {children}\n </Resizable>\n ),\n [\n sizeProps,\n styles.panel,\n classNames?.content,\n canResizing,\n resizing,\n internalPlacement,\n handleVariants,\n showHandleHighlight,\n styles.handleHighlight,\n handleResize,\n handleResizeStart,\n handleResizeStop,\n state.isResizing,\n isPending,\n style,\n children,\n cx,\n ],\n );\n\n // For fullscreen mode, return a simpler layout\n if (fullscreen) {\n return <div className={cx(styles.fullscreen, className)}>{children}</div>;\n }\n\n return (\n <aside\n className={cx(variants({ mode, placement: internalPlacement }), className)}\n dir={dir}\n ref={ref}\n >\n {expandable && state.showExpand && handle}\n {destroyOnClose ? isExpand && inner : inner}\n </aside>\n );\n },\n // Custom comparison function to avoid unnecessary re-renders\n (prevProps, nextProps) => {\n // Only re-render if critical props change\n return (\n prevProps.placement === nextProps.placement &&\n prevProps.mode === nextProps.mode &&\n prevProps.expand === nextProps.expand &&\n prevProps.pin === nextProps.pin &&\n prevProps.fullscreen === nextProps.fullscreen &&\n prevProps.size === nextProps.size &&\n prevProps.defaultSize === nextProps.defaultSize &&\n prevProps.minWidth === nextProps.minWidth &&\n prevProps.minHeight === nextProps.minHeight &&\n prevProps.maxWidth === nextProps.maxWidth &&\n prevProps.maxHeight === nextProps.maxHeight &&\n prevProps.expandable === nextProps.expandable &&\n prevProps.resize === nextProps.resize &&\n prevProps.showHandleWhenCollapsed === nextProps.showHandleWhenCollapsed &&\n prevProps.destroyOnClose === nextProps.destroyOnClose &&\n prevProps.showBorder === nextProps.showBorder &&\n prevProps.showHandleHighlight === nextProps.showHandleHighlight &&\n prevProps.showHandleWideArea === nextProps.showHandleWideArea &&\n prevProps.backgroundColor === nextProps.backgroundColor &&\n prevProps.className === nextProps.className &&\n prevProps.dir === nextProps.dir &&\n prevProps.headerHeight === nextProps.headerHeight &&\n prevProps.onSizeChange === nextProps.onSizeChange &&\n prevProps.onSizeDragging === nextProps.onSizeDragging &&\n prevProps.onExpandChange === nextProps.onExpandChange &&\n prevProps.children === nextProps.children\n );\n },\n);\n\nDraggablePanel.displayName = 'DraggablePanel';\n\nexport default DraggablePanel;\n"],"mappings":";;;;;;;;;;;;;;;;AA4BA,MAAM,iBAAiB;AACvB,MAAM,gBAAgB;AACtB,MAAM,wBAAwB;AAC9B,MAAM,cAAc;AACpB,MAAM,eAAe;AACrB,MAAM,qBAAqB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5B,YAAY,MAAM,aAAa,UAAU;GACzC,GAAG;GACJ;EAEA;GACS,EAEd;EACE;EACA,OAAO;EACP,YAAY;EACZ;EACA;EACA;EACA;EACA;EACA,OAAO;EACP;EACA;EACA;EACA,MAAM;EACN;EACA;EACA;EACA;EACD,CACF;AAGD,KAAI,WACF,QAAO,oBAAC;EAAI,WAAW,GAAG,OAAO,YAAY,UAAU;EAAG;GAAe;AAG3E,QACE,qBAAC;EACC,WAAW,GAAG,SAAS;GAAE;GAAM,WAAW;GAAmB,CAAC,EAAE,UAAU;EACrE;EACA;aAEJ,cAAc,MAAM,cAAc,QAClC,iBAAiB,YAAY,QAAQ;GAChC;IAIX,WAAW,cAAc;AAExB,QACE,UAAU,cAAc,UAAU,aAClC,UAAU,SAAS,UAAU,QAC7B,UAAU,WAAW,UAAU,UAC/B,UAAU,QAAQ,UAAU,OAC5B,UAAU,eAAe,UAAU,cACnC,UAAU,SAAS,UAAU,QAC7B,UAAU,gBAAgB,UAAU,eACpC,UAAU,aAAa,UAAU,YACjC,UAAU,cAAc,UAAU,aAClC,UAAU,aAAa,UAAU,YACjC,UAAU,cAAc,UAAU,aAClC,UAAU,eAAe,UAAU,cACnC,UAAU,WAAW,UAAU,UAC/B,UAAU,4BAA4B,UAAU,2BAChD,UAAU,mBAAmB,UAAU,kBACvC,UAAU,eAAe,UAAU,cACnC,UAAU,wBAAwB,UAAU,uBAC5C,UAAU,uBAAuB,UAAU,sBAC3C,UAAU,oBAAoB,UAAU,mBACxC,UAAU,cAAc,UAAU,aAClC,UAAU,QAAQ,UAAU,OAC5B,UAAU,iBAAiB,UAAU,gBACrC,UAAU,iBAAiB,UAAU,gBACrC,UAAU,mBAAmB,UAAU,kBACvC,UAAU,mBAAmB,UAAU,kBACvC,UAAU,aAAa,UAAU;EAGtC;AAED,eAAe,cAAc;AAE7B,6BAAe"}
1
+ {"version":3,"file":"DraggablePanel.mjs","names":["useControlledState","defaultSize: Size","Center","Icon"],"sources":["../../src/DraggablePanel/DraggablePanel.tsx"],"sourcesContent":["'use client';\n\nimport { useHover } from 'ahooks';\nimport { ConfigProvider } from 'antd';\nimport { cva } from 'class-variance-authority';\nimport { ChevronDown, ChevronLeft, ChevronRight, ChevronUp } from 'lucide-react';\nimport type { Enable, NumberSize, Size } from 're-resizable';\nimport { Resizable } from 're-resizable';\nimport {\n memo,\n use,\n useCallback,\n useEffect,\n useMemo,\n useReducer,\n useRef,\n useTransition,\n} from 'react';\nimport useControlledState from 'use-merge-value';\n\nimport { Center } from '@/Flex';\nimport Icon from '@/Icon';\n\nimport { useStyles } from './style';\nimport type { DraggablePanelProps } from './type';\nimport { reversePlacement } from './utils';\n\n// Constants\nconst DEFAULT_HEIGHT = 180;\nconst DEFAULT_WIDTH = 280;\nconst DEFAULT_HEADER_HEIGHT = 0;\nconst DEFAULT_PIN = true;\nconst DEFAULT_MODE = 'fixed';\nconst DEFAULT_EXPANDABLE = true;\nconst DEFAULT_EXPAND = true;\nconst DEFAULT_SHOW_HANDLE_WIDE_AREA = true;\n\n// State reducer for better state management\ninterface DraggablePanelState {\n isResizing: boolean;\n showExpand: boolean;\n}\n\ntype DraggablePanelAction =\n | { type: 'START_RESIZE' }\n | { type: 'STOP_RESIZE' }\n | { payload: boolean; type: 'SET_SHOW_EXPAND' };\n\nfunction draggablePanelReducer(\n state: DraggablePanelState,\n action: DraggablePanelAction,\n): DraggablePanelState {\n switch (action.type) {\n case 'START_RESIZE': {\n return { ...state, isResizing: true, showExpand: false };\n }\n case 'STOP_RESIZE': {\n return { ...state, isResizing: false, showExpand: true };\n }\n case 'SET_SHOW_EXPAND': {\n return { ...state, showExpand: action.payload };\n }\n default: {\n return state;\n }\n }\n}\n\nconst DraggablePanel = memo<DraggablePanelProps>(\n ({\n headerHeight = DEFAULT_HEADER_HEIGHT,\n fullscreen,\n maxHeight,\n pin = DEFAULT_PIN,\n mode = DEFAULT_MODE,\n children,\n placement = 'right',\n resize,\n style,\n showBorder = true,\n showHandleHighlight = false,\n showHandleWideArea = DEFAULT_SHOW_HANDLE_WIDE_AREA,\n backgroundColor,\n size,\n defaultSize: customizeDefaultSize,\n minWidth,\n minHeight,\n maxWidth,\n onSizeChange,\n onSizeDragging,\n expandable = DEFAULT_EXPANDABLE,\n expand,\n defaultExpand = DEFAULT_EXPAND,\n onExpandChange,\n className,\n showHandleWhenCollapsed,\n destroyOnClose,\n styles: customStyles,\n classNames,\n dir,\n }) => {\n const ref = useRef<HTMLDivElement>(null);\n const isHovering = useHover(ref);\n const isVertical = placement === 'top' || placement === 'bottom';\n const [isPending, startTransition] = useTransition();\n\n // Use ref for hover timeout to avoid memory leaks\n const hoverTimeoutRef = useRef<any>(undefined);\n\n // inherit direction from Ant Design ConfigProvider\n const { direction: antdDirection } = use(ConfigProvider.ConfigContext);\n const direction = dir ?? antdDirection;\n\n // Handle RTL direction\n const internalPlacement = useMemo(() => {\n return direction === 'rtl' && ['left', 'right'].includes(placement)\n ? placement === 'left'\n ? 'right'\n : 'left'\n : placement;\n }, [direction, placement]);\n\n const { styles, cx } = useStyles({\n backgroundColor,\n headerHeight,\n showBorder,\n showHandleWideArea,\n });\n\n const [isExpand, setIsExpand] = useControlledState(defaultExpand, {\n onChange: onExpandChange,\n value: expand,\n });\n\n // Initialize state with useReducer for better performance\n const initialState: DraggablePanelState = {\n isResizing: false,\n showExpand: true,\n };\n\n const [state, dispatch] = useReducer(draggablePanelReducer, initialState);\n\n // Auto-expand on hover if not pinned with optimized transition\n useEffect(() => {\n if (pin) return;\n\n // Clear previous timeout\n if (hoverTimeoutRef.current) {\n clearTimeout(hoverTimeoutRef.current);\n }\n\n if (isHovering && !isExpand) {\n startTransition(() => {\n setIsExpand(true);\n });\n } else if (!isHovering && isExpand) {\n // Add a small delay before collapsing to prevent flickering\n hoverTimeoutRef.current = setTimeout(() => {\n startTransition(() => {\n setIsExpand(false);\n });\n }, 150);\n }\n }, [pin, isHovering, isExpand, setIsExpand]);\n\n // Cleanup timeout on unmount\n useEffect(() => {\n return () => {\n if (hoverTimeoutRef.current) {\n clearTimeout(hoverTimeoutRef.current);\n }\n };\n }, []);\n\n const canResizing = resize !== false && isExpand;\n\n // Style variants for the panel\n const variants = useMemo(\n () =>\n cva(styles.root, {\n compoundVariants: [\n {\n class: styles.bottomFloat,\n mode: 'float',\n placement: 'bottom',\n },\n {\n class: styles.topFloat,\n mode: 'float',\n placement: 'top',\n },\n {\n class: styles.leftFloat,\n mode: 'float',\n placement: 'left',\n },\n {\n class: styles.rightFloat,\n mode: 'float',\n placement: 'right',\n },\n ],\n /* eslint-disable sort-keys-fix/sort-keys-fix */\n variants: {\n placement: {\n top: isExpand && styles.borderBottom,\n right: isExpand && styles.borderLeft,\n bottom: isExpand && styles.borderTop,\n left: isExpand && styles.borderRight,\n },\n mode: {\n fixed: styles.fixed,\n float: null,\n },\n },\n /* eslint-enable sort-keys-fix/sort-keys-fix */\n }),\n [styles, isExpand],\n );\n\n // Style variants for the handle\n const handleVariants = useMemo(\n () =>\n cva(styles.handleRoot, {\n variants: {\n placement: {\n bottom: styles.handleBottom,\n left: styles.handleLeft,\n right: styles.handleRight,\n top: styles.handleTop,\n },\n },\n }),\n [styles],\n );\n\n // Style variants for the toggle button\n const toggleVariants = useMemo(\n () =>\n cva(styles.toggleRoot, {\n variants: {\n placement: {\n bottom: styles.toggleTop,\n left: styles.toggleRight,\n right: styles.toggleLeft,\n top: styles.toggleBottom,\n },\n },\n }),\n [styles],\n );\n\n // Configure resizing handles\n const resizing = useMemo(\n () => ({\n bottom: false,\n bottomLeft: false,\n bottomRight: false,\n left: false,\n right: false,\n top: false,\n topLeft: false,\n topRight: false,\n [reversePlacement(internalPlacement)]: true,\n ...(resize as Enable),\n }),\n [internalPlacement, resize],\n );\n\n // Calculate default size based on orientation\n const defaultSize: Size = useMemo(() => {\n if (isVertical)\n return {\n height: DEFAULT_HEIGHT,\n width: '100%',\n ...customizeDefaultSize,\n };\n\n return {\n height: '100%',\n width: DEFAULT_WIDTH,\n ...customizeDefaultSize,\n };\n }, [isVertical, customizeDefaultSize]);\n\n // Determine appropriate size props based on expand state\n const sizeProps = useMemo(() => {\n if (!isExpand) {\n return isVertical\n ? { minHeight: 0, size: { height: 0 } }\n : { minWidth: 0, size: { width: 0 } };\n }\n\n return {\n defaultSize,\n maxHeight: typeof maxHeight === 'number' ? Math.max(maxHeight, 0) : maxHeight,\n maxWidth: typeof maxWidth === 'number' ? Math.max(maxWidth, 0) : maxWidth,\n minHeight: typeof minHeight === 'number' ? Math.max(minHeight, 0) : minHeight,\n minWidth: typeof minWidth === 'number' ? Math.max(minWidth, 0) : minWidth,\n size: size as Size,\n };\n }, [isExpand, isVertical, defaultSize, maxHeight, maxWidth, minHeight, minWidth, size]);\n\n // Determine the appropriate arrow icon based on placement\n const Arrow = useMemo(() => {\n switch (internalPlacement) {\n case 'top': {\n return ChevronDown;\n }\n case 'bottom': {\n return ChevronUp;\n }\n case 'right': {\n return ChevronLeft;\n }\n case 'left': {\n return ChevronRight;\n }\n default: {\n return ChevronLeft;\n }\n }\n }, [internalPlacement]);\n\n // Toggle expand state with transition for better performance\n const toggleExpand = useCallback(() => {\n if (!expandable) return;\n\n startTransition(() => {\n setIsExpand(!isExpand);\n });\n }, [expandable, isExpand, setIsExpand]);\n\n // Toggle handle component\n const handle = useMemo(\n () => (\n <Center\n className={toggleVariants({ placement: internalPlacement })}\n style={{ opacity: isExpand ? (pin ? undefined : 0) : showHandleWhenCollapsed ? 1 : 0 }}\n >\n <Center\n className={classNames?.handle}\n onClick={toggleExpand}\n style={customStyles?.handle}\n >\n <Icon\n className={styles.handlerIcon}\n icon={Arrow}\n size={16}\n style={{\n marginBottom: internalPlacement === 'top' ? 4 : 0,\n marginLeft: internalPlacement === 'right' ? 4 : 0,\n marginRight: internalPlacement === 'left' ? 4 : 0,\n marginTop: internalPlacement === 'bottom' ? 4 : 0,\n transform: `rotate(${isExpand ? 180 : 0}deg)`,\n transition: 'transform 0.3s ease',\n }}\n />\n </Center>\n </Center>\n ),\n [\n toggleVariants,\n internalPlacement,\n isExpand,\n pin,\n showHandleWhenCollapsed,\n classNames?.handle,\n toggleExpand,\n customStyles?.handle,\n styles.handlerIcon,\n Arrow,\n ],\n );\n\n // Handle resize events with memoization\n const handleResize = useCallback(\n (_: unknown, _direction: unknown, reference_: HTMLElement, delta: NumberSize) => {\n onSizeDragging?.(delta, {\n height: reference_.style.height,\n width: reference_.style.width,\n });\n },\n [onSizeDragging],\n );\n\n const handleResizeStart = useCallback(() => {\n dispatch({ type: 'START_RESIZE' });\n }, []);\n\n const handleResizeStop = useCallback(\n (e: unknown, direction: unknown, reference_: HTMLElement, delta: NumberSize) => {\n dispatch({ type: 'STOP_RESIZE' });\n onSizeChange?.(delta, {\n height: reference_.style.height,\n width: reference_.style.width,\n });\n },\n [onSizeChange],\n );\n\n // Main panel content\n const inner = useMemo(\n () => (\n <Resizable\n {...sizeProps}\n className={cx(styles.panel, classNames?.content)}\n enable={canResizing ? (resizing as Enable) : undefined}\n handleClasses={\n canResizing\n ? {\n [reversePlacement(internalPlacement)]: cx(\n handleVariants({\n placement: reversePlacement(internalPlacement),\n }),\n showHandleHighlight && styles.handleHighlight,\n ),\n }\n : {}\n }\n onResize={handleResize}\n onResizeStart={handleResizeStart}\n onResizeStop={handleResizeStop}\n style={{\n opacity: isPending ? 0.95 : 1,\n transition: state.isResizing ? 'unset' : undefined,\n ...style,\n }}\n >\n {children}\n </Resizable>\n ),\n [\n sizeProps,\n styles.panel,\n classNames?.content,\n canResizing,\n resizing,\n internalPlacement,\n handleVariants,\n showHandleHighlight,\n styles.handleHighlight,\n handleResize,\n handleResizeStart,\n handleResizeStop,\n state.isResizing,\n isPending,\n style,\n children,\n cx,\n ],\n );\n\n // For fullscreen mode, return a simpler layout\n if (fullscreen) {\n return <div className={cx(styles.fullscreen, className)}>{children}</div>;\n }\n\n return (\n <aside\n className={cx(variants({ mode, placement: internalPlacement }), className)}\n dir={dir}\n ref={ref}\n >\n {expandable && state.showExpand && handle}\n {destroyOnClose ? isExpand && inner : inner}\n </aside>\n );\n },\n // Custom comparison function to avoid unnecessary re-renders\n (prevProps, nextProps) => {\n // Only re-render if critical props change\n return (\n prevProps.placement === nextProps.placement &&\n prevProps.mode === nextProps.mode &&\n prevProps.expand === nextProps.expand &&\n prevProps.pin === nextProps.pin &&\n prevProps.fullscreen === nextProps.fullscreen &&\n prevProps.size === nextProps.size &&\n prevProps.defaultSize === nextProps.defaultSize &&\n prevProps.minWidth === nextProps.minWidth &&\n prevProps.minHeight === nextProps.minHeight &&\n prevProps.maxWidth === nextProps.maxWidth &&\n prevProps.maxHeight === nextProps.maxHeight &&\n prevProps.expandable === nextProps.expandable &&\n prevProps.resize === nextProps.resize &&\n prevProps.showHandleWhenCollapsed === nextProps.showHandleWhenCollapsed &&\n prevProps.destroyOnClose === nextProps.destroyOnClose &&\n prevProps.showBorder === nextProps.showBorder &&\n prevProps.showHandleHighlight === nextProps.showHandleHighlight &&\n prevProps.showHandleWideArea === nextProps.showHandleWideArea &&\n prevProps.backgroundColor === nextProps.backgroundColor &&\n prevProps.className === nextProps.className &&\n prevProps.dir === nextProps.dir &&\n prevProps.headerHeight === nextProps.headerHeight &&\n prevProps.onSizeChange === nextProps.onSizeChange &&\n prevProps.onSizeDragging === nextProps.onSizeDragging &&\n prevProps.onExpandChange === nextProps.onExpandChange &&\n prevProps.children === nextProps.children\n );\n },\n);\n\nDraggablePanel.displayName = 'DraggablePanel';\n\nexport default DraggablePanel;\n"],"mappings":";;;;;;;;;;;;;;;;AA4BA,MAAM,iBAAiB;AACvB,MAAM,gBAAgB;AACtB,MAAM,wBAAwB;AAC9B,MAAM,cAAc;AACpB,MAAM,eAAe;AACrB,MAAM,qBAAqB;AAC3B,MAAM,iBAAiB;AACvB,MAAM,gCAAgC;AAatC,SAAS,sBACP,OACA,QACqB;AACrB,SAAQ,OAAO,MAAf;EACE,KAAK,eACH,QAAO;GAAE,GAAG;GAAO,YAAY;GAAM,YAAY;GAAO;EAE1D,KAAK,cACH,QAAO;GAAE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,WACF,QAAO,oBAAC;EAAI,WAAW,GAAG,OAAO,YAAY,UAAU;EAAG;GAAe;AAG3E,QACE,qBAAC;EACC,WAAW,GAAG,SAAS;GAAE;GAAM,WAAW;GAAmB,CAAC,EAAE,UAAU;EACrE;EACA;aAEJ,cAAc,MAAM,cAAc,QAClC,iBAAiB,YAAY,QAAQ;GAChC;IAIX,WAAW,cAAc;AAExB,QACE,UAAU,cAAc,UAAU,aAClC,UAAU,SAAS,UAAU,QAC7B,UAAU,WAAW,UAAU,UAC/B,UAAU,QAAQ,UAAU,OAC5B,UAAU,eAAe,UAAU,cACnC,UAAU,SAAS,UAAU,QAC7B,UAAU,gBAAgB,UAAU,eACpC,UAAU,aAAa,UAAU,YACjC,UAAU,cAAc,UAAU,aAClC,UAAU,aAAa,UAAU,YACjC,UAAU,cAAc,UAAU,aAClC,UAAU,eAAe,UAAU,cACnC,UAAU,WAAW,UAAU,UAC/B,UAAU,4BAA4B,UAAU,2BAChD,UAAU,mBAAmB,UAAU,kBACvC,UAAU,eAAe,UAAU,cACnC,UAAU,wBAAwB,UAAU,uBAC5C,UAAU,uBAAuB,UAAU,sBAC3C,UAAU,oBAAoB,UAAU,mBACxC,UAAU,cAAc,UAAU,aAClC,UAAU,QAAQ,UAAU,OAC5B,UAAU,iBAAiB,UAAU,gBACrC,UAAU,iBAAiB,UAAU,gBACrC,UAAU,mBAAmB,UAAU,kBACvC,UAAU,mBAAmB,UAAU,kBACvC,UAAU,aAAa,UAAU;EAGtC;AAED,eAAe,cAAc;AAE7B,6BAAe"}
@@ -1,9 +1,9 @@
1
1
  import { DivProps } from "../../types/index.mjs";
2
- import * as react16 from "react";
2
+ import * as react61 from "react";
3
3
 
4
4
  //#region src/DraggablePanel/components/DraggablePanelBody.d.ts
5
5
  type DraggablePanelBodyProps = DivProps;
6
- declare const DraggablePanelBody: react16.NamedExoticComponent<DivProps>;
6
+ declare const DraggablePanelBody: react61.NamedExoticComponent<DivProps>;
7
7
  //#endregion
8
8
  export { DraggablePanelBody, DraggablePanelBodyProps };
9
9
  //# sourceMappingURL=DraggablePanelBody.d.mts.map
@@ -1,9 +1,9 @@
1
1
  import { DivProps } from "../../types/index.mjs";
2
- import * as react17 from "react";
2
+ import * as react63 from "react";
3
3
 
4
4
  //#region src/DraggablePanel/components/DraggablePanelContainer.d.ts
5
5
  type DraggablePanelContainerProps = DivProps;
6
- declare const DraggablePanelContainer: react17.NamedExoticComponent<DivProps>;
6
+ declare const DraggablePanelContainer: react63.NamedExoticComponent<DivProps>;
7
7
  //#endregion
8
8
  export { DraggablePanelContainer, DraggablePanelContainerProps };
9
9
  //# sourceMappingURL=DraggablePanelContainer.d.mts.map
@@ -1,9 +1,9 @@
1
1
  import { DivProps } from "../../types/index.mjs";
2
- import * as react18 from "react";
2
+ import * as react58 from "react";
3
3
 
4
4
  //#region src/DraggablePanel/components/DraggablePanelFooter.d.ts
5
5
  type DraggablePanelFooterProps = DivProps;
6
- declare const DraggablePanelFooter: react18.NamedExoticComponent<DivProps>;
6
+ declare const DraggablePanelFooter: react58.NamedExoticComponent<DivProps>;
7
7
  //#endregion
8
8
  export { DraggablePanelFooter, DraggablePanelFooterProps };
9
9
  //# sourceMappingURL=DraggablePanelFooter.d.mts.map