@lobehub/ui 4.27.5 → 4.28.1

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 (127) hide show
  1. package/es/Accordion/Accordion.d.mts +2 -2
  2. package/es/Accordion/AccordionItem.d.mts +2 -2
  3. package/es/ActionIcon/ActionIcon.d.mts +2 -2
  4. package/es/Alert/Alert.d.mts +2 -2
  5. package/es/AutoComplete/Select.d.mts +2 -2
  6. package/es/Avatar/AvatarGroup/index.d.mts +2 -2
  7. package/es/Burger/Burger.d.mts +2 -2
  8. package/es/CodeDiff/CodeDiff.d.mts +2 -2
  9. package/es/CodeDiff/PatchDiff.d.mts +2 -2
  10. package/es/CodeEditor/CodeEditor.d.mts +2 -2
  11. package/es/Collapse/Collapse.d.mts +2 -2
  12. package/es/ConfigProvider/index.d.mts +2 -2
  13. package/es/ContextMenu/ContextMenuHost.d.mts +2 -2
  14. package/es/CopyButton/CopyButton.d.mts +2 -2
  15. package/es/DatePicker/DatePicker.d.mts +2 -2
  16. package/es/DraggablePanel/components/DraggablePanelBody.d.mts +2 -2
  17. package/es/DraggablePanel/components/DraggablePanelContainer.d.mts +2 -2
  18. package/es/DraggablePanel/components/DraggablePanelFooter.d.mts +2 -2
  19. package/es/DraggablePanel/components/DraggablePanelHeader.d.mts +2 -2
  20. package/es/DraggableSideNav/DraggableSideNav.d.mts +2 -2
  21. package/es/Drawer/Drawer.d.mts +2 -2
  22. package/es/Dropdown/Dropdown.d.mts +2 -2
  23. package/es/DropdownMenu/DropdownMenu.d.mts +2 -2
  24. package/es/DropdownMenu/DropdownMenu.mjs +1 -0
  25. package/es/DropdownMenu/DropdownMenu.mjs.map +1 -1
  26. package/es/EditableText/EditableText.d.mts +2 -2
  27. package/es/EmojiPicker/EmojiPicker.d.mts +2 -2
  28. package/es/Flex/FlexBasic.d.mts +2 -2
  29. package/es/FontLoader/index.d.mts +2 -2
  30. package/es/Footer/Footer.d.mts +2 -2
  31. package/es/Form/components/FormGroup.d.mts +2 -2
  32. package/es/Form/components/FormItem.d.mts +2 -2
  33. package/es/Form/components/FormSubmitFooter.d.mts +2 -2
  34. package/es/FormModal/FormModal.d.mts +2 -2
  35. package/es/GuideCard/GuideCard.d.mts +2 -2
  36. package/es/Header/Header.d.mts +2 -2
  37. package/es/Highlighter/Highlighter.d.mts +2 -2
  38. package/es/Highlighter/SyntaxHighlighter/index.d.mts +2 -2
  39. package/es/Hotkey/Hotkey.d.mts +2 -2
  40. package/es/HotkeyInput/HotkeyInput.d.mts +2 -2
  41. package/es/Icon/Icon.d.mts +2 -2
  42. package/es/Icon/components/IconProvider.d.mts +3 -3
  43. package/es/Image/PreviewGroup.d.mts +2 -2
  44. package/es/ImageSelect/ImageSelect.d.mts +2 -2
  45. package/es/Input/Input.d.mts +2 -2
  46. package/es/Input/InputNumber.d.mts +2 -2
  47. package/es/Input/InputOPT.d.mts +2 -2
  48. package/es/Input/InputPassword.d.mts +2 -2
  49. package/es/Input/TextArea.d.mts +2 -2
  50. package/es/Layout/components/LayoutFooter.d.mts +2 -2
  51. package/es/Layout/components/LayoutHeader.d.mts +2 -2
  52. package/es/Layout/components/LayoutMain.d.mts +2 -2
  53. package/es/Layout/components/LayoutSidebar.d.mts +2 -2
  54. package/es/Layout/components/LayoutSidebarInner.d.mts +2 -2
  55. package/es/Layout/components/LayoutToc.d.mts +2 -2
  56. package/es/List/ListItem/index.d.mts +2 -2
  57. package/es/LobeSelect/LobeSelect.d.mts +2 -2
  58. package/es/LobeSelect/atoms.d.mts +3 -3
  59. package/es/LobeSwitch/LobeSwitch.d.mts +2 -2
  60. package/es/Markdown/Markdown.d.mts +2 -2
  61. package/es/Markdown/Typography.d.mts +2 -2
  62. package/es/Markdown/components/SearchResultCards/index.d.mts +2 -2
  63. package/es/MaskShadow/MaskShadow.d.mts +2 -2
  64. package/es/Mermaid/Mermaid.d.mts +2 -2
  65. package/es/Mermaid/SyntaxMermaid/index.d.mts +2 -2
  66. package/es/Modal/Modal.d.mts +2 -2
  67. package/es/Modal/ModalProvider.d.mts +2 -2
  68. package/es/MotionProvider/index.d.mts +2 -2
  69. package/es/Popover/atoms.d.mts +2 -2
  70. package/es/Popover/context.d.mts +2 -2
  71. package/es/SearchBar/SearchBar.d.mts +2 -2
  72. package/es/Segmented/Segmented.d.mts +2 -2
  73. package/es/Select/Select.d.mts +2 -2
  74. package/es/SideNav/SideNav.d.mts +2 -2
  75. package/es/SliderWithInput/SliderWithInput.d.mts +2 -2
  76. package/es/Text/Text.mjs +7 -0
  77. package/es/Text/Text.mjs.map +1 -1
  78. package/es/Text/type.d.mts +1 -0
  79. package/es/ThemeProvider/ThemeProvider.d.mts +2 -2
  80. package/es/Toast/imperative.d.mts +3 -3
  81. package/es/Toc/Toc.d.mts +2 -2
  82. package/es/Video/index.d.mts +2 -2
  83. package/es/awesome/AuroraBackground/AuroraBackground.d.mts +2 -2
  84. package/es/awesome/BottomGradientButton/BottomGradientButton.d.mts +2 -2
  85. package/es/awesome/Features/Features.d.mts +2 -2
  86. package/es/awesome/Giscus/Giscus.d.mts +2 -2
  87. package/es/awesome/GridBackground/GridBackground.d.mts +2 -2
  88. package/es/awesome/GridBackground/GridShowcase.d.mts +2 -2
  89. package/es/awesome/Hero/Hero.d.mts +2 -2
  90. package/es/awesome/Spline/Spine.d.mts +2 -2
  91. package/es/awesome/Spotlight/Spotlight.d.mts +2 -2
  92. package/es/awesome/SpotlightCard/SpotlightCard.d.mts +2 -2
  93. package/es/awesome/TypewriterEffect/TypewriterEffect.d.mts +2 -2
  94. package/es/brand/LobeChat/index.d.mts +2 -2
  95. package/es/brand/LobeHub/index.d.mts +2 -2
  96. package/es/brand/LogoThree/LogoSpline.d.mts +2 -2
  97. package/es/brand/LogoThree/index.d.mts +2 -2
  98. package/es/chat/BackBottom/BackBottom.d.mts +2 -2
  99. package/es/chat/ChatInputArea/components/ChatInputAreaInner.d.mts +2 -2
  100. package/es/chat/ChatItem/ChatItem.d.mts +2 -2
  101. package/es/chat/ChatList/ChatList.d.mts +2 -2
  102. package/es/chat/EditableMessage/EditableMessage.d.mts +2 -2
  103. package/es/chat/EditableMessageList/EditableMessageList.d.mts +2 -2
  104. package/es/chat/MessageInput/MessageInput.d.mts +2 -2
  105. package/es/chat/MessageModal/MessageModal.d.mts +2 -2
  106. package/es/hooks/useTextOverflow.mjs +31 -0
  107. package/es/hooks/useTextOverflow.mjs.map +1 -0
  108. package/es/i18n/context.d.mts +2 -2
  109. package/es/icons/lucideExtra/CreateBotIcon.d.mts +2 -2
  110. package/es/icons/lucideExtra/DiscordIcon.d.mts +2 -2
  111. package/es/icons/lucideExtra/GlobeOffIcon.d.mts +3 -3
  112. package/es/icons/lucideExtra/GroupBotIcon.d.mts +2 -2
  113. package/es/icons/lucideExtra/GroupBotSquareIcon.d.mts +3 -3
  114. package/es/icons/lucideExtra/LeftClickIcon.d.mts +2 -2
  115. package/es/icons/lucideExtra/LeftDoubleClickIcon.d.mts +2 -2
  116. package/es/icons/lucideExtra/McpIcon.d.mts +2 -2
  117. package/es/icons/lucideExtra/ProviderIcon.d.mts +2 -2
  118. package/es/icons/lucideExtra/RightClickIcon.d.mts +3 -3
  119. package/es/icons/lucideExtra/RightDoubleClickIcon.d.mts +2 -2
  120. package/es/icons/lucideExtra/ShapesUploadIcon.d.mts +3 -3
  121. package/es/icons/lucideExtra/TreeDownRightIcon.d.mts +3 -3
  122. package/es/icons/lucideExtra/TreeUpDownRightIcon.d.mts +2 -2
  123. package/es/mobile/ChatHeader/ChatHeaderTitle.d.mts +2 -2
  124. package/es/mobile/ChatInputArea/components/ChatSendButton.d.mts +2 -2
  125. package/es/mobile/TabBar/TabBar.d.mts +2 -2
  126. package/es/storybook/StoryBook/index.d.mts +2 -2
  127. package/package.json +1 -1
@@ -1,8 +1,8 @@
1
1
  import { TextAreaProps } from "./type.mjs";
2
- import * as react132 from "react";
2
+ import * as react154 from "react";
3
3
 
4
4
  //#region src/Input/TextArea.d.ts
5
- declare const TextArea: react132.NamedExoticComponent<TextAreaProps>;
5
+ declare const TextArea: react154.NamedExoticComponent<TextAreaProps>;
6
6
  //#endregion
7
7
  export { TextArea };
8
8
  //# sourceMappingURL=TextArea.d.mts.map
@@ -1,9 +1,9 @@
1
1
  import { DivProps } from "../../types/index.mjs";
2
2
  import "../../index.mjs";
3
- import * as react38 from "react";
3
+ import * as react62 from "react";
4
4
 
5
5
  //#region src/Layout/components/LayoutFooter.d.ts
6
- declare const LayoutFooter: react38.NamedExoticComponent<DivProps>;
6
+ declare const LayoutFooter: react62.NamedExoticComponent<DivProps>;
7
7
  //#endregion
8
8
  export { LayoutFooter };
9
9
  //# sourceMappingURL=LayoutFooter.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { LayoutHeaderProps } from "../type.mjs";
2
- import * as react39 from "react";
2
+ import * as react66 from "react";
3
3
 
4
4
  //#region src/Layout/components/LayoutHeader.d.ts
5
- declare const LayoutHeader: react39.NamedExoticComponent<LayoutHeaderProps>;
5
+ declare const LayoutHeader: react66.NamedExoticComponent<LayoutHeaderProps>;
6
6
  //#endregion
7
7
  export { LayoutHeader };
8
8
  //# sourceMappingURL=LayoutHeader.d.mts.map
@@ -1,9 +1,9 @@
1
1
  import { DivProps } from "../../types/index.mjs";
2
2
  import "../../index.mjs";
3
- import * as react40 from "react";
3
+ import * as react67 from "react";
4
4
 
5
5
  //#region src/Layout/components/LayoutMain.d.ts
6
- declare const LayoutMain: react40.NamedExoticComponent<DivProps>;
6
+ declare const LayoutMain: react67.NamedExoticComponent<DivProps>;
7
7
  //#endregion
8
8
  export { LayoutMain };
9
9
  //# sourceMappingURL=LayoutMain.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { LayoutSidebarProps } from "../type.mjs";
2
- import * as react42 from "react";
2
+ import * as react64 from "react";
3
3
 
4
4
  //#region src/Layout/components/LayoutSidebar.d.ts
5
- declare const LayoutSidebar: react42.NamedExoticComponent<LayoutSidebarProps>;
5
+ declare const LayoutSidebar: react64.NamedExoticComponent<LayoutSidebarProps>;
6
6
  //#endregion
7
7
  export { LayoutSidebar };
8
8
  //# sourceMappingURL=LayoutSidebar.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { LayoutSidebarInnerProps } from "../type.mjs";
2
- import * as react41 from "react";
2
+ import * as react63 from "react";
3
3
 
4
4
  //#region src/Layout/components/LayoutSidebarInner.d.ts
5
- declare const LayoutSidebarInner: react41.NamedExoticComponent<LayoutSidebarInnerProps>;
5
+ declare const LayoutSidebarInner: react63.NamedExoticComponent<LayoutSidebarInnerProps>;
6
6
  //#endregion
7
7
  export { LayoutSidebarInner };
8
8
  //# sourceMappingURL=LayoutSidebarInner.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { LayoutTocProps } from "../type.mjs";
2
- import * as react43 from "react";
2
+ import * as react65 from "react";
3
3
 
4
4
  //#region src/Layout/components/LayoutToc.d.ts
5
- declare const LayoutToc: react43.NamedExoticComponent<LayoutTocProps>;
5
+ declare const LayoutToc: react65.NamedExoticComponent<LayoutTocProps>;
6
6
  //#endregion
7
7
  export { LayoutToc };
8
8
  //# sourceMappingURL=LayoutToc.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { ListItemProps } from "../type.mjs";
2
- import * as react74 from "react";
2
+ import * as react60 from "react";
3
3
 
4
4
  //#region src/List/ListItem/index.d.ts
5
- declare const ListItem: react74.NamedExoticComponent<ListItemProps>;
5
+ declare const ListItem: react60.NamedExoticComponent<ListItemProps>;
6
6
  //#endregion
7
7
  export { ListItem };
8
8
  //# sourceMappingURL=index.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { LobeSelectProps } from "./type.mjs";
2
- import * as react73 from "react";
2
+ import * as react59 from "react";
3
3
 
4
4
  //#region src/LobeSelect/LobeSelect.d.ts
5
- declare const LobeSelect: react73.NamedExoticComponent<LobeSelectProps<any>>;
5
+ declare const LobeSelect: react59.NamedExoticComponent<LobeSelectProps<any>>;
6
6
  //#endregion
7
7
  export { LobeSelect };
8
8
  //# sourceMappingURL=LobeSelect.d.mts.map
@@ -1,6 +1,6 @@
1
1
  import { LobeSelectSize, LobeSelectVariant } from "./type.mjs";
2
2
  import { LOBE_SELECT_CONTAINER_ATTR } from "./constants.mjs";
3
- import * as react69 from "react";
3
+ import * as react55 from "react";
4
4
  import { ComponentProps, ComponentPropsWithRef } from "react";
5
5
  import * as react_jsx_runtime36 from "react/jsx-runtime";
6
6
  import * as _base_ui_react_select0 from "@base-ui/react/select";
@@ -9,8 +9,8 @@ import * as node_modules__base_ui_react_esm_separator_Separator0 from "node_modu
9
9
 
10
10
  //#region src/LobeSelect/atoms.d.ts
11
11
  declare const LobeSelectRoot: typeof Select.Root;
12
- declare const LobeSelectBackdrop: react69.ForwardRefExoticComponent<_base_ui_react_select0.SelectBackdropProps & react69.RefAttributes<HTMLDivElement>>;
13
- declare const LobeSelectSeparator: react69.ForwardRefExoticComponent<node_modules__base_ui_react_esm_separator_Separator0.SeparatorProps & react69.RefAttributes<HTMLDivElement>>;
12
+ declare const LobeSelectBackdrop: react55.ForwardRefExoticComponent<_base_ui_react_select0.SelectBackdropProps & react55.RefAttributes<HTMLDivElement>>;
13
+ declare const LobeSelectSeparator: react55.ForwardRefExoticComponent<node_modules__base_ui_react_esm_separator_Separator0.SeparatorProps & react55.RefAttributes<HTMLDivElement>>;
14
14
  type LobeSelectTriggerProps = Omit<ComponentPropsWithRef<typeof Select.Trigger>, 'children' | 'render'> & {
15
15
  children: ComponentProps<typeof Select.Trigger>['children'];
16
16
  shadow?: boolean;
@@ -1,8 +1,8 @@
1
1
  import { LobeSwitchProps } from "./type.mjs";
2
- import * as react50 from "react";
2
+ import * as react52 from "react";
3
3
 
4
4
  //#region src/LobeSwitch/LobeSwitch.d.ts
5
- declare const LobeSwitch: react50.NamedExoticComponent<LobeSwitchProps>;
5
+ declare const LobeSwitch: react52.NamedExoticComponent<LobeSwitchProps>;
6
6
  //#endregion
7
7
  export { LobeSwitch };
8
8
  //# sourceMappingURL=LobeSwitch.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { MarkdownProps } from "./type.mjs";
2
- import * as react63 from "react";
2
+ import * as react54 from "react";
3
3
 
4
4
  //#region src/Markdown/Markdown.d.ts
5
- declare const Markdown: react63.NamedExoticComponent<MarkdownProps>;
5
+ declare const Markdown: react54.NamedExoticComponent<MarkdownProps>;
6
6
  //#endregion
7
7
  export { Markdown };
8
8
  //# sourceMappingURL=Markdown.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { TypographyProps } from "./type.mjs";
2
- import * as react62 from "react";
2
+ import * as react53 from "react";
3
3
 
4
4
  //#region src/Markdown/Typography.d.ts
5
- declare const Typography: react62.NamedExoticComponent<TypographyProps>;
5
+ declare const Typography: react53.NamedExoticComponent<TypographyProps>;
6
6
  //#endregion
7
7
  export { Typography };
8
8
  //# sourceMappingURL=Typography.d.mts.map
@@ -1,6 +1,6 @@
1
1
  import { FlexboxProps } from "../../../Flex/type.mjs";
2
2
  import "../../../Flex/index.mjs";
3
- import * as react3 from "react";
3
+ import * as react85 from "react";
4
4
  import { Ref } from "react";
5
5
 
6
6
  //#region src/Markdown/components/SearchResultCards/index.d.ts
@@ -14,7 +14,7 @@ interface SearchResultCardsProps extends FlexboxProps {
14
14
  dataSource: string[] | SearchResultItem[];
15
15
  ref?: Ref<HTMLDivElement>;
16
16
  }
17
- declare const SearchResultCards: react3.NamedExoticComponent<SearchResultCardsProps>;
17
+ declare const SearchResultCards: react85.NamedExoticComponent<SearchResultCardsProps>;
18
18
  //#endregion
19
19
  export { SearchResultCards, SearchResultCardsProps };
20
20
  //# sourceMappingURL=index.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { MaskShadowProps } from "./type.mjs";
2
- import * as react60 from "react";
2
+ import * as react79 from "react";
3
3
 
4
4
  //#region src/MaskShadow/MaskShadow.d.ts
5
- declare const MaskShadow: react60.NamedExoticComponent<MaskShadowProps>;
5
+ declare const MaskShadow: react79.NamedExoticComponent<MaskShadowProps>;
6
6
  //#endregion
7
7
  export { MaskShadow };
8
8
  //# sourceMappingURL=MaskShadow.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { MermaidProps } from "./type.mjs";
2
- import * as react48 from "react";
2
+ import * as react46 from "react";
3
3
 
4
4
  //#region src/Mermaid/Mermaid.d.ts
5
- declare const Mermaid: react48.NamedExoticComponent<MermaidProps>;
5
+ declare const Mermaid: react46.NamedExoticComponent<MermaidProps>;
6
6
  //#endregion
7
7
  export { Mermaid };
8
8
  //# sourceMappingURL=Mermaid.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { SyntaxMermaidProps } from "../type.mjs";
2
- import * as react49 from "react";
2
+ import * as react47 from "react";
3
3
 
4
4
  //#region src/Mermaid/SyntaxMermaid/index.d.ts
5
- declare const SyntaxMermaid: react49.NamedExoticComponent<SyntaxMermaidProps>;
5
+ declare const SyntaxMermaid: react47.NamedExoticComponent<SyntaxMermaidProps>;
6
6
  //#endregion
7
7
  export { SyntaxMermaid };
8
8
  //# sourceMappingURL=index.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { ModalProps } from "./type.mjs";
2
- import * as react47 from "react";
2
+ import * as react50 from "react";
3
3
 
4
4
  //#region src/Modal/Modal.d.ts
5
- declare const Modal: react47.NamedExoticComponent<ModalProps>;
5
+ declare const Modal: react50.NamedExoticComponent<ModalProps>;
6
6
  //#endregion
7
7
  export { Modal };
8
8
  //# sourceMappingURL=Modal.d.mts.map
@@ -1,9 +1,9 @@
1
1
  import { ModalContextValue } from "./type.mjs";
2
- import * as react45 from "react";
2
+ import * as react48 from "react";
3
3
  import { ReactNode } from "react";
4
4
 
5
5
  //#region src/Modal/ModalProvider.d.ts
6
- declare const ModalProvider: react45.NamedExoticComponent<{
6
+ declare const ModalProvider: react48.NamedExoticComponent<{
7
7
  children: ReactNode;
8
8
  value: ModalContextValue;
9
9
  }>;
@@ -1,4 +1,4 @@
1
- import * as react5 from "react";
1
+ import * as react86 from "react";
2
2
  import { Context, ReactNode } from "react";
3
3
  import * as motion_react0 from "motion/react";
4
4
  import * as m from "motion/react-m";
@@ -6,7 +6,7 @@ import * as m from "motion/react-m";
6
6
  //#region src/MotionProvider/index.d.ts
7
7
  type MotionComponentType = typeof motion_react0.motion | typeof m;
8
8
  declare const MotionComponent: Context<MotionComponentType>;
9
- declare const MotionProvider: react5.NamedExoticComponent<{
9
+ declare const MotionProvider: react86.NamedExoticComponent<{
10
10
  children: ReactNode;
11
11
  motion: MotionComponentType;
12
12
  }>;
@@ -1,5 +1,5 @@
1
1
  import { PopoverPlacement } from "./type.mjs";
2
- import * as react36 from "react";
2
+ import * as react42 from "react";
3
3
  import { ComponentProps, ComponentPropsWithRef } from "react";
4
4
  import * as react_jsx_runtime26 from "react/jsx-runtime";
5
5
  import * as _base_ui_react_popover0 from "@base-ui/react/popover";
@@ -7,7 +7,7 @@ import { Popover } from "@base-ui/react/popover";
7
7
 
8
8
  //#region src/Popover/atoms.d.ts
9
9
  declare const PopoverRoot: typeof Popover.Root;
10
- declare const PopoverBackdrop: react36.ForwardRefExoticComponent<_base_ui_react_popover0.PopoverBackdropProps & react36.RefAttributes<HTMLDivElement>>;
10
+ declare const PopoverBackdrop: react42.ForwardRefExoticComponent<_base_ui_react_popover0.PopoverBackdropProps & react42.RefAttributes<HTMLDivElement>>;
11
11
  type PopoverTriggerElementProps = Omit<ComponentPropsWithRef<typeof Popover.Trigger>, 'children' | 'render'> & {
12
12
  children: ComponentProps<typeof Popover.Trigger>['children'];
13
13
  };
@@ -1,11 +1,11 @@
1
- import * as react34 from "react";
1
+ import * as react44 from "react";
2
2
  import { ReactNode } from "react";
3
3
 
4
4
  //#region src/Popover/context.d.ts
5
5
  type PopoverContextValue = {
6
6
  close: () => void;
7
7
  };
8
- declare const PopoverProvider: react34.NamedExoticComponent<{
8
+ declare const PopoverProvider: react44.NamedExoticComponent<{
9
9
  children: ReactNode;
10
10
  value: PopoverContextValue;
11
11
  }>;
@@ -1,8 +1,8 @@
1
1
  import { SearchBarProps } from "./type.mjs";
2
- import * as react32 from "react";
2
+ import * as react38 from "react";
3
3
 
4
4
  //#region src/SearchBar/SearchBar.d.ts
5
- declare const SearchBar: react32.NamedExoticComponent<SearchBarProps>;
5
+ declare const SearchBar: react38.NamedExoticComponent<SearchBarProps>;
6
6
  //#endregion
7
7
  export { SearchBar };
8
8
  //# sourceMappingURL=SearchBar.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { SegmentedProps } from "./type.mjs";
2
- import * as react31 from "react";
2
+ import * as react37 from "react";
3
3
 
4
4
  //#region src/Segmented/Segmented.d.ts
5
- declare const Segmented: react31.NamedExoticComponent<SegmentedProps>;
5
+ declare const Segmented: react37.NamedExoticComponent<SegmentedProps>;
6
6
  //#endregion
7
7
  export { Segmented };
8
8
  //# sourceMappingURL=Segmented.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { SelectProps } from "./type.mjs";
2
- import * as react33 from "react";
2
+ import * as react41 from "react";
3
3
 
4
4
  //#region src/Select/Select.d.ts
5
- declare const Input: react33.NamedExoticComponent<SelectProps>;
5
+ declare const Input: react41.NamedExoticComponent<SelectProps>;
6
6
  //#endregion
7
7
  export { Input };
8
8
  //# sourceMappingURL=Select.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { SideNavProps } from "./type.mjs";
2
- import * as react44 from "react";
2
+ import * as react40 from "react";
3
3
 
4
4
  //#region src/SideNav/SideNav.d.ts
5
- declare const SideNav: react44.NamedExoticComponent<SideNavProps>;
5
+ declare const SideNav: react40.NamedExoticComponent<SideNavProps>;
6
6
  //#endregion
7
7
  export { SideNav };
8
8
  //# sourceMappingURL=SideNav.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { SliderWithInputProps } from "./type.mjs";
2
- import * as react30 from "react";
2
+ import * as react39 from "react";
3
3
 
4
4
  //#region src/SliderWithInput/SliderWithInput.d.ts
5
- declare const SliderWithInput: react30.NamedExoticComponent<SliderWithInputProps>;
5
+ declare const SliderWithInput: react39.NamedExoticComponent<SliderWithInputProps>;
6
6
  //#endregion
7
7
  export { SliderWithInput };
8
8
  //# sourceMappingURL=SliderWithInput.d.mts.map
package/es/Text/Text.mjs CHANGED
@@ -1,12 +1,17 @@
1
1
  'use client';
2
2
 
3
3
  import Tooltip_default from "../Tooltip/Tooltip.mjs";
4
+ import { useTextOverflow } from "../hooks/useTextOverflow.mjs";
4
5
  import { variants } from "./styles.mjs";
6
+ import { useRef } from "react";
5
7
  import { jsx } from "react/jsx-runtime";
6
8
  import { cx } from "antd-style";
7
9
 
8
10
  //#region src/Text/Text.tsx
9
11
  const Text = ({ as: Container = "div", align, className, children, style, type, disabled, strong, italic, underline, delete: deleteStyle, fontSize, mark, code, color, weight, ellipsis, ...rest }) => {
12
+ const textRef = useRef(null);
13
+ const isOverflow = useTextOverflow(textRef, ellipsis, children);
14
+ const tooltipWhenOverflow = typeof ellipsis === "object" && ellipsis.tooltipWhenOverflow;
10
15
  const textStyle = {
11
16
  ...color && { color },
12
17
  ...weight && { fontWeight: weight },
@@ -35,11 +40,13 @@ const Text = ({ as: Container = "div", align, className, children, style, type,
35
40
  type,
36
41
  underline
37
42
  }), className),
43
+ ref: textRef,
38
44
  style: textStyle,
39
45
  ...rest,
40
46
  children
41
47
  });
42
48
  if (ellipsis && typeof ellipsis === "object" && ellipsis.tooltip) {
49
+ if (tooltipWhenOverflow && !isOverflow) return content;
43
50
  const title = typeof ellipsis.tooltip === "string" ? ellipsis.tooltip : children;
44
51
  if (typeof ellipsis.tooltip === "object") return /* @__PURE__ */ jsx(Tooltip_default, {
45
52
  ...ellipsis.tooltip,
@@ -1 +1 @@
1
- {"version":3,"file":"Text.mjs","names":["Text: FC<TextProps>","Tooltip"],"sources":["../../src/Text/Text.tsx"],"sourcesContent":["'use client';\n\nimport { cx } from 'antd-style';\nimport { type FC } from 'react';\n\nimport Tooltip from '@/Tooltip';\n\nimport { variants } from './styles';\nimport type { TextProps } from './type';\n\nconst Text: FC<TextProps> = ({\n as: Container = 'div',\n align,\n className,\n children,\n style,\n type,\n disabled,\n strong,\n italic,\n underline,\n delete: deleteStyle,\n fontSize,\n mark,\n code,\n color,\n weight,\n ellipsis,\n ...rest\n}) => {\n const textStyle = {\n ...(color && { color }),\n ...(weight && { fontWeight: weight }),\n ...(typeof ellipsis === 'object' &&\n ellipsis.rows && {\n WebkitLineClamp: ellipsis.rows,\n }),\n ...(fontSize && { fontSize }),\n ...(align && { textAlign: align }),\n ...style,\n };\n\n const content = (\n <Container\n className={cx(\n variants({\n as: ['h1', 'h2', 'h3', 'h4', 'h5', 'p'].includes(Container as string)\n ? (Container as any)\n : undefined,\n code,\n delete: deleteStyle,\n disabled,\n ellipsis: ellipsis\n ? typeof ellipsis === 'object' && ellipsis.rows\n ? 'multi'\n : true\n : undefined,\n italic,\n mark,\n strong,\n type,\n underline,\n }),\n className,\n )}\n style={textStyle}\n {...rest}\n >\n {children}\n </Container>\n );\n\n // 处理带有 tooltip 的省略\n if (ellipsis && typeof ellipsis === 'object' && ellipsis.tooltip) {\n const title = typeof ellipsis.tooltip === 'string' ? ellipsis.tooltip : children;\n if (typeof ellipsis.tooltip === 'object')\n return (\n <Tooltip {...ellipsis.tooltip} title={ellipsis.tooltip?.title || title}>\n {content}\n </Tooltip>\n );\n return <Tooltip title={title}>{content}</Tooltip>;\n }\n\n return content;\n};\n\nText.displayName = 'Text';\n\nexport default Text;\n"],"mappings":";;;;;;;;AAUA,MAAMA,QAAuB,EAC3B,IAAI,YAAY,OAChB,OACA,WACA,UACA,OACA,MACA,UACA,QACA,QACA,WACA,QAAQ,aACR,UACA,MACA,MACA,OACA,QACA,UACA,GAAG,WACC;CACJ,MAAM,YAAY;EAChB,GAAI,SAAS,EAAE,OAAO;EACtB,GAAI,UAAU,EAAE,YAAY,QAAQ;EACpC,GAAI,OAAO,aAAa,YACtB,SAAS,QAAQ,EACf,iBAAiB,SAAS,MAC3B;EACH,GAAI,YAAY,EAAE,UAAU;EAC5B,GAAI,SAAS,EAAE,WAAW,OAAO;EACjC,GAAG;EACJ;CAED,MAAM,UACJ,oBAAC;EACC,WAAW,GACT,SAAS;GACP,IAAI;IAAC;IAAM;IAAM;IAAM;IAAM;IAAM;IAAI,CAAC,SAAS,UAAoB,GAChE,YACD;GACJ;GACA,QAAQ;GACR;GACA,UAAU,WACN,OAAO,aAAa,YAAY,SAAS,OACvC,UACA,OACF;GACJ;GACA;GACA;GACA;GACA;GACD,CAAC,EACF,UACD;EACD,OAAO;EACP,GAAI;EAEH;GACS;AAId,KAAI,YAAY,OAAO,aAAa,YAAY,SAAS,SAAS;EAChE,MAAM,QAAQ,OAAO,SAAS,YAAY,WAAW,SAAS,UAAU;AACxE,MAAI,OAAO,SAAS,YAAY,SAC9B,QACE,oBAACC;GAAQ,GAAI,SAAS;GAAS,OAAO,SAAS,SAAS,SAAS;aAC9D;IACO;AAEd,SAAO,oBAACA;GAAe;aAAQ;IAAkB;;AAGnD,QAAO;;AAGT,KAAK,cAAc;AAEnB,mBAAe"}
1
+ {"version":3,"file":"Text.mjs","names":["Text: FC<TextProps>","Tooltip"],"sources":["../../src/Text/Text.tsx"],"sourcesContent":["'use client';\n\nimport { cx } from 'antd-style';\nimport { type FC, useRef } from 'react';\n\nimport Tooltip from '@/Tooltip';\nimport { useTextOverflow } from '@/hooks/useTextOverflow';\n\nimport { variants } from './styles';\nimport type { TextProps } from './type';\n\nconst Text: FC<TextProps> = ({\n as: Container = 'div',\n align,\n className,\n children,\n style,\n type,\n disabled,\n strong,\n italic,\n underline,\n delete: deleteStyle,\n fontSize,\n mark,\n code,\n color,\n weight,\n ellipsis,\n ...rest\n}) => {\n const textRef = useRef<HTMLElement>(null);\n const isOverflow = useTextOverflow(textRef, ellipsis, children);\n\n const tooltipWhenOverflow = typeof ellipsis === 'object' && ellipsis.tooltipWhenOverflow;\n\n const textStyle = {\n ...(color && { color }),\n ...(weight && { fontWeight: weight }),\n ...(typeof ellipsis === 'object' &&\n ellipsis.rows && {\n WebkitLineClamp: ellipsis.rows,\n }),\n ...(fontSize && { fontSize }),\n ...(align && { textAlign: align }),\n ...style,\n };\n\n const content = (\n <Container\n className={cx(\n variants({\n as: ['h1', 'h2', 'h3', 'h4', 'h5', 'p'].includes(Container as string)\n ? (Container as any)\n : undefined,\n code,\n delete: deleteStyle,\n disabled,\n ellipsis: ellipsis\n ? typeof ellipsis === 'object' && ellipsis.rows\n ? 'multi'\n : true\n : undefined,\n italic,\n mark,\n strong,\n type,\n underline,\n }),\n className,\n )}\n ref={textRef}\n style={textStyle}\n {...rest}\n >\n {children}\n </Container>\n );\n\n // 处理带有 tooltip 的省略\n if (ellipsis && typeof ellipsis === 'object' && ellipsis.tooltip) {\n // 如果设置了 tooltipWhenOverflow,只在溢出时显示 tooltip\n if (tooltipWhenOverflow && !isOverflow) {\n return content;\n }\n\n const title = typeof ellipsis.tooltip === 'string' ? ellipsis.tooltip : children;\n if (typeof ellipsis.tooltip === 'object')\n return (\n <Tooltip {...ellipsis.tooltip} title={ellipsis.tooltip?.title || title}>\n {content}\n </Tooltip>\n );\n return <Tooltip title={title}>{content}</Tooltip>;\n }\n\n return content;\n};\n\nText.displayName = 'Text';\n\nexport default Text;\n"],"mappings":";;;;;;;;;;AAWA,MAAMA,QAAuB,EAC3B,IAAI,YAAY,OAChB,OACA,WACA,UACA,OACA,MACA,UACA,QACA,QACA,WACA,QAAQ,aACR,UACA,MACA,MACA,OACA,QACA,UACA,GAAG,WACC;CACJ,MAAM,UAAU,OAAoB,KAAK;CACzC,MAAM,aAAa,gBAAgB,SAAS,UAAU,SAAS;CAE/D,MAAM,sBAAsB,OAAO,aAAa,YAAY,SAAS;CAErE,MAAM,YAAY;EAChB,GAAI,SAAS,EAAE,OAAO;EACtB,GAAI,UAAU,EAAE,YAAY,QAAQ;EACpC,GAAI,OAAO,aAAa,YACtB,SAAS,QAAQ,EACf,iBAAiB,SAAS,MAC3B;EACH,GAAI,YAAY,EAAE,UAAU;EAC5B,GAAI,SAAS,EAAE,WAAW,OAAO;EACjC,GAAG;EACJ;CAED,MAAM,UACJ,oBAAC;EACC,WAAW,GACT,SAAS;GACP,IAAI;IAAC;IAAM;IAAM;IAAM;IAAM;IAAM;IAAI,CAAC,SAAS,UAAoB,GAChE,YACD;GACJ;GACA,QAAQ;GACR;GACA,UAAU,WACN,OAAO,aAAa,YAAY,SAAS,OACvC,UACA,OACF;GACJ;GACA;GACA;GACA;GACA;GACD,CAAC,EACF,UACD;EACD,KAAK;EACL,OAAO;EACP,GAAI;EAEH;GACS;AAId,KAAI,YAAY,OAAO,aAAa,YAAY,SAAS,SAAS;AAEhE,MAAI,uBAAuB,CAAC,WAC1B,QAAO;EAGT,MAAM,QAAQ,OAAO,SAAS,YAAY,WAAW,SAAS,UAAU;AACxE,MAAI,OAAO,SAAS,YAAY,SAC9B,QACE,oBAACC;GAAQ,GAAI,SAAS;GAAS,OAAO,SAAS,SAAS,SAAS;aAC9D;IACO;AAEd,SAAO,oBAACA;GAAe;aAAQ;IAAkB;;AAGnD,QAAO;;AAGT,KAAK,cAAc;AAEnB,mBAAe"}
@@ -14,6 +14,7 @@ interface TextProps extends DivProps {
14
14
  ellipsis?: boolean | {
15
15
  rows?: number;
16
16
  tooltip?: boolean | string | TooltipProps;
17
+ tooltipWhenOverflow?: boolean;
17
18
  };
18
19
  fontSize?: number | string;
19
20
  italic?: boolean;
@@ -1,8 +1,8 @@
1
1
  import { ThemeProviderProps } from "./type.mjs";
2
- import * as react24 from "react";
2
+ import * as react17 from "react";
3
3
 
4
4
  //#region src/ThemeProvider/ThemeProvider.d.ts
5
- declare const ThemeProvider: react24.NamedExoticComponent<ThemeProviderProps>;
5
+ declare const ThemeProvider: react17.NamedExoticComponent<ThemeProviderProps>;
6
6
  //#endregion
7
7
  export { ThemeProvider };
8
8
  //# sourceMappingURL=ThemeProvider.d.mts.map
@@ -1,5 +1,5 @@
1
1
  import { ToastAPI, ToastPosition } from "./type.mjs";
2
- import * as react20 from "react";
2
+ import * as react15 from "react";
3
3
 
4
4
  //#region src/Toast/imperative.d.ts
5
5
  declare const toast: ToastAPI;
@@ -31,14 +31,14 @@ interface ToastHostProps {
31
31
  */
32
32
  swipeDirection?: ('left' | 'right' | 'up' | 'down') | ('left' | 'right' | 'up' | 'down')[];
33
33
  }
34
- declare const ToastHost: react20.MemoExoticComponent<({
34
+ declare const ToastHost: react15.MemoExoticComponent<({
35
35
  root,
36
36
  className,
37
37
  duration,
38
38
  limit,
39
39
  position,
40
40
  swipeDirection
41
- }: ToastHostProps) => react20.ReactPortal | null>;
41
+ }: ToastHostProps) => react15.ReactPortal | null>;
42
42
  declare const useToast: () => ToastAPI;
43
43
  //#endregion
44
44
  export { TOAST_CONTAINER_ATTR, ToastHost, ToastHostProps, toast, useToast };
package/es/Toc/Toc.d.mts CHANGED
@@ -1,8 +1,8 @@
1
1
  import { TocProps } from "./type.mjs";
2
- import * as react22 from "react";
2
+ import * as react14 from "react";
3
3
 
4
4
  //#region src/Toc/Toc.d.ts
5
- declare const Toc: react22.NamedExoticComponent<TocProps>;
5
+ declare const Toc: react14.NamedExoticComponent<TocProps>;
6
6
  //#endregion
7
7
  export { Toc };
8
8
  //# sourceMappingURL=Toc.d.mts.map
@@ -1,7 +1,7 @@
1
1
  import { FlexboxProps } from "../Flex/type.mjs";
2
2
  import "../Flex/index.mjs";
3
3
  import { VideoProps as VideoProps$1 } from "../types/index.mjs";
4
- import * as react4 from "react";
4
+ import * as react87 from "react";
5
5
  import { CSSProperties, Ref } from "react";
6
6
 
7
7
  //#region src/Video/index.d.ts
@@ -39,7 +39,7 @@ interface VideoProps extends VideoProps$1, Pick<FlexboxProps, 'width' | 'height'
39
39
  };
40
40
  variant?: 'borderless' | 'filled' | 'outlined';
41
41
  }
42
- declare const Video: react4.NamedExoticComponent<VideoProps>;
42
+ declare const Video: react87.NamedExoticComponent<VideoProps>;
43
43
  //#endregion
44
44
  export { Video, VideoProps };
45
45
  //# sourceMappingURL=index.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { AuroraBackgroundProps } from "./type.mjs";
2
- import * as react135 from "react";
2
+ import * as react137 from "react";
3
3
 
4
4
  //#region src/awesome/AuroraBackground/AuroraBackground.d.ts
5
- declare const AuroraBackground: react135.NamedExoticComponent<AuroraBackgroundProps>;
5
+ declare const AuroraBackground: react137.NamedExoticComponent<AuroraBackgroundProps>;
6
6
  //#endregion
7
7
  export { AuroraBackground };
8
8
  //# sourceMappingURL=AuroraBackground.d.mts.map
@@ -1,9 +1,9 @@
1
1
  import { ButtonProps } from "../../Button/type.mjs";
2
2
  import "../../Button/index.mjs";
3
- import * as react137 from "react";
3
+ import * as react139 from "react";
4
4
 
5
5
  //#region src/awesome/BottomGradientButton/BottomGradientButton.d.ts
6
- declare const BottomGradientButton: react137.NamedExoticComponent<ButtonProps>;
6
+ declare const BottomGradientButton: react139.NamedExoticComponent<ButtonProps>;
7
7
  //#endregion
8
8
  export { BottomGradientButton };
9
9
  //# sourceMappingURL=BottomGradientButton.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { FeaturesProps } from "./type.mjs";
2
- import * as react136 from "react";
2
+ import * as react138 from "react";
3
3
 
4
4
  //#region src/awesome/Features/Features.d.ts
5
- declare const Features: react136.NamedExoticComponent<FeaturesProps>;
5
+ declare const Features: react138.NamedExoticComponent<FeaturesProps>;
6
6
  //#endregion
7
7
  export { Features };
8
8
  //# sourceMappingURL=Features.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { GiscusProps } from "./type.mjs";
2
- import * as react138 from "react";
2
+ import * as react140 from "react";
3
3
 
4
4
  //#region src/awesome/Giscus/Giscus.d.ts
5
- declare const Giscus: react138.NamedExoticComponent<GiscusProps>;
5
+ declare const Giscus: react140.NamedExoticComponent<GiscusProps>;
6
6
  //#endregion
7
7
  export { Giscus };
8
8
  //# sourceMappingURL=Giscus.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { GridBackgroundProps } from "./type.mjs";
2
- import * as react139 from "react";
2
+ import * as react143 from "react";
3
3
 
4
4
  //#region src/awesome/GridBackground/GridBackground.d.ts
5
- declare const GridBackground: react139.NamedExoticComponent<GridBackgroundProps>;
5
+ declare const GridBackground: react143.NamedExoticComponent<GridBackgroundProps>;
6
6
  //#endregion
7
7
  export { GridBackground };
8
8
  //# sourceMappingURL=GridBackground.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { GridShowcaseProps } from "./type.mjs";
2
- import * as react140 from "react";
2
+ import * as react144 from "react";
3
3
 
4
4
  //#region src/awesome/GridBackground/GridShowcase.d.ts
5
- declare const GridShowcase: react140.NamedExoticComponent<GridShowcaseProps>;
5
+ declare const GridShowcase: react144.NamedExoticComponent<GridShowcaseProps>;
6
6
  //#endregion
7
7
  export { GridShowcase };
8
8
  //# sourceMappingURL=GridShowcase.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { HeroProps } from "./type.mjs";
2
- import * as react143 from "react";
2
+ import * as react142 from "react";
3
3
 
4
4
  //#region src/awesome/Hero/Hero.d.ts
5
- declare const Hero: react143.NamedExoticComponent<HeroProps>;
5
+ declare const Hero: react142.NamedExoticComponent<HeroProps>;
6
6
  //#endregion
7
7
  export { Hero };
8
8
  //# sourceMappingURL=Hero.d.mts.map
@@ -1,9 +1,9 @@
1
1
  import { SplineProps } from "./type.mjs";
2
- import * as react142 from "react";
2
+ import * as react145 from "react";
3
3
  import "@splinetool/runtime";
4
4
 
5
5
  //#region src/awesome/Spline/Spine.d.ts
6
- declare const Spline: react142.NamedExoticComponent<SplineProps>;
6
+ declare const Spline: react145.NamedExoticComponent<SplineProps>;
7
7
  //#endregion
8
8
  export { Spline };
9
9
  //# sourceMappingURL=Spine.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { SpotlightProps } from "./type.mjs";
2
- import * as react144 from "react";
2
+ import * as react147 from "react";
3
3
 
4
4
  //#region src/awesome/Spotlight/Spotlight.d.ts
5
- declare const Spotlight: react144.NamedExoticComponent<SpotlightProps>;
5
+ declare const Spotlight: react147.NamedExoticComponent<SpotlightProps>;
6
6
  //#endregion
7
7
  export { Spotlight };
8
8
  //# sourceMappingURL=Spotlight.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { SpotlightCardProps } from "./type.mjs";
2
- import * as react145 from "react";
2
+ import * as react146 from "react";
3
3
 
4
4
  //#region src/awesome/SpotlightCard/SpotlightCard.d.ts
5
- declare const SpotlightCard: react145.NamedExoticComponent<SpotlightCardProps<any>>;
5
+ declare const SpotlightCard: react146.NamedExoticComponent<SpotlightCardProps<any>>;
6
6
  //#endregion
7
7
  export { SpotlightCard };
8
8
  //# sourceMappingURL=SpotlightCard.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { TypewriterEffectProps } from "./type.mjs";
2
- import * as react146 from "react";
2
+ import * as react148 from "react";
3
3
 
4
4
  //#region src/awesome/TypewriterEffect/TypewriterEffect.d.ts
5
- declare const TypewriterEffect: react146.NamedExoticComponent<TypewriterEffectProps>;
5
+ declare const TypewriterEffect: react148.NamedExoticComponent<TypewriterEffectProps>;
6
6
  //#endregion
7
7
  export { TypewriterEffect };
8
8
  //# sourceMappingURL=TypewriterEffect.d.mts.map