@lobehub/ui 5.5.2 → 5.6.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 (198) 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/CopyButton/CopyButton.d.mts +2 -2
  14. package/es/DatePicker/DatePicker.d.mts +2 -2
  15. package/es/DraggablePanel/components/DraggablePanelBody.d.mts +2 -2
  16. package/es/DraggablePanel/components/DraggablePanelContainer.d.mts +2 -2
  17. package/es/DraggablePanel/components/DraggablePanelFooter.d.mts +2 -2
  18. package/es/DraggablePanel/components/DraggablePanelHeader.d.mts +2 -2
  19. package/es/DraggableSideNav/DraggableSideNav.d.mts +2 -2
  20. package/es/Drawer/Drawer.d.mts +2 -2
  21. package/es/Dropdown/Dropdown.d.mts +2 -2
  22. package/es/EditableText/EditableText.d.mts +2 -2
  23. package/es/EmojiPicker/EmojiPicker.d.mts +2 -2
  24. package/es/Flex/FlexBasic.d.mts +2 -2
  25. package/es/FontLoader/index.d.mts +2 -2
  26. package/es/Footer/Footer.d.mts +2 -2
  27. package/es/Form/components/FormGroup.d.mts +2 -2
  28. package/es/Form/components/FormItem.d.mts +2 -2
  29. package/es/Form/components/FormSubmitFooter.d.mts +2 -2
  30. package/es/FormModal/FormModal.d.mts +2 -2
  31. package/es/GuideCard/GuideCard.d.mts +2 -2
  32. package/es/Header/Header.d.mts +2 -2
  33. package/es/Highlighter/Highlighter.d.mts +2 -2
  34. package/es/Highlighter/SyntaxHighlighter/index.d.mts +2 -2
  35. package/es/Hotkey/Hotkey.d.mts +2 -2
  36. package/es/HotkeyInput/HotkeyInput.d.mts +2 -2
  37. package/es/Icon/Icon.d.mts +2 -2
  38. package/es/Icon/components/IconProvider.d.mts +3 -3
  39. package/es/Image/PreviewGroup.d.mts +2 -2
  40. package/es/Input/Input.d.mts +2 -2
  41. package/es/Input/InputNumber.d.mts +2 -2
  42. package/es/Input/InputOPT.d.mts +2 -2
  43. package/es/Input/InputPassword.d.mts +2 -2
  44. package/es/Input/TextArea.d.mts +2 -2
  45. package/es/Layout/components/LayoutFooter.d.mts +2 -2
  46. package/es/Layout/components/LayoutHeader.d.mts +2 -2
  47. package/es/Layout/components/LayoutMain.d.mts +2 -2
  48. package/es/Layout/components/LayoutSidebar.d.mts +2 -2
  49. package/es/Layout/components/LayoutSidebarInner.d.mts +2 -2
  50. package/es/Layout/components/LayoutToc.d.mts +2 -2
  51. package/es/List/ListItem/index.d.mts +2 -2
  52. package/es/Markdown/Markdown.d.mts +2 -2
  53. package/es/Markdown/Typography.d.mts +2 -2
  54. package/es/Markdown/components/SearchResultCards/index.d.mts +2 -2
  55. package/es/MaskShadow/MaskShadow.d.mts +2 -2
  56. package/es/Menu/Menu.d.mts +2 -2
  57. package/es/Mermaid/Mermaid.d.mts +2 -2
  58. package/es/Mermaid/SyntaxMermaid/StaticMermaid.mjs +11 -11
  59. package/es/Mermaid/SyntaxMermaid/StaticMermaid.mjs.map +1 -1
  60. package/es/Mermaid/SyntaxMermaid/StreamMermaid.mjs +11 -11
  61. package/es/Mermaid/SyntaxMermaid/StreamMermaid.mjs.map +1 -1
  62. package/es/Mermaid/SyntaxMermaid/index.d.mts +2 -2
  63. package/es/Modal/Modal.d.mts +2 -2
  64. package/es/Modal/ModalProvider.d.mts +2 -2
  65. package/es/MotionProvider/index.d.mts +2 -2
  66. package/es/SearchBar/SearchBar.d.mts +2 -2
  67. package/es/Segmented/Segmented.d.mts +2 -2
  68. package/es/Select/Select.d.mts +2 -2
  69. package/es/SideNav/SideNav.d.mts +2 -2
  70. package/es/SliderWithInput/SliderWithInput.d.mts +2 -2
  71. package/es/ThemeProvider/ThemeProvider.d.mts +2 -2
  72. package/es/Toc/Toc.d.mts +2 -2
  73. package/es/Video/index.d.mts +2 -2
  74. package/es/awesome/AuroraBackground/AuroraBackground.d.mts +2 -2
  75. package/es/awesome/BottomGradientButton/BottomGradientButton.d.mts +2 -2
  76. package/es/awesome/Features/Features.d.mts +2 -2
  77. package/es/awesome/Giscus/Giscus.d.mts +2 -2
  78. package/es/awesome/GradientButton/GradientButton.d.mts +2 -2
  79. package/es/awesome/GridBackground/GridBackground.d.mts +2 -2
  80. package/es/awesome/GridBackground/GridShowcase.d.mts +2 -2
  81. package/es/awesome/Hero/Hero.d.mts +2 -2
  82. package/es/awesome/Spline/Spine.d.mts +2 -2
  83. package/es/awesome/Spotlight/Spotlight.d.mts +2 -2
  84. package/es/awesome/SpotlightCard/SpotlightCard.d.mts +2 -2
  85. package/es/awesome/TypewriterEffect/TypewriterEffect.d.mts +2 -2
  86. package/es/base-ui/ContextMenu/ContextMenuHost.d.mts +2 -2
  87. package/es/base-ui/DropdownMenu/DropdownMenu.d.mts +2 -2
  88. package/es/base-ui/DropdownMenu/atoms.d.mts +18 -18
  89. package/es/base-ui/Modal/atoms.d.mts +12 -12
  90. package/es/base-ui/Modal/context.d.mts +2 -2
  91. package/es/base-ui/Modal/imperative.d.mts +2 -2
  92. package/es/base-ui/Popover/ArrowIcon.d.mts +2 -2
  93. package/es/base-ui/Popover/atoms.d.mts +9 -9
  94. package/es/base-ui/Popover/context.d.mts +2 -2
  95. package/es/base-ui/Select/Select.d.mts +2 -2
  96. package/es/base-ui/Select/atoms.d.mts +19 -19
  97. package/es/base-ui/Switch/Switch.d.mts +2 -2
  98. package/es/base-ui/Switch/atoms.d.mts +4 -4
  99. package/es/base-ui/Toast/imperative.d.mts +2 -2
  100. package/es/brand/LobeChat/index.d.mts +2 -2
  101. package/es/brand/LobeHub/index.d.mts +2 -2
  102. package/es/brand/LogoThree/LogoSpline.d.mts +2 -2
  103. package/es/brand/LogoThree/index.d.mts +2 -2
  104. package/es/chat/BackBottom/BackBottom.d.mts +2 -2
  105. package/es/chat/ChatInputArea/components/ChatInputAreaInner.d.mts +2 -2
  106. package/es/chat/ChatItem/ChatItem.d.mts +2 -2
  107. package/es/chat/ChatList/ChatList.d.mts +2 -2
  108. package/es/chat/EditableMessage/EditableMessage.d.mts +2 -2
  109. package/es/chat/EditableMessageList/EditableMessageList.d.mts +2 -2
  110. package/es/chat/MessageInput/MessageInput.d.mts +2 -2
  111. package/es/chat/MessageModal/MessageModal.d.mts +2 -2
  112. package/es/color/ColorScales/index.d.mts +2 -2
  113. package/es/color/CssVar/index.d.mts +2 -2
  114. package/es/i18n/context.d.mts +2 -2
  115. package/es/icons/index.d.mts +20 -1
  116. package/es/icons/index.mjs +20 -1
  117. package/es/icons/lucideExtra/AndroidIcon.d.mts +8 -0
  118. package/es/icons/lucideExtra/AndroidIcon.mjs +13 -0
  119. package/es/icons/lucideExtra/AndroidIcon.mjs.map +1 -0
  120. package/es/icons/lucideExtra/AppleIcon.d.mts +8 -0
  121. package/es/icons/lucideExtra/AppleIcon.mjs +13 -0
  122. package/es/icons/lucideExtra/AppleIcon.mjs.map +1 -0
  123. package/es/icons/lucideExtra/AppstoreIcon.d.mts +8 -0
  124. package/es/icons/lucideExtra/AppstoreIcon.mjs +13 -0
  125. package/es/icons/lucideExtra/AppstoreIcon.mjs.map +1 -0
  126. package/es/icons/lucideExtra/BotPromptIcon.d.mts +3 -3
  127. package/es/icons/lucideExtra/BrainOffIcon.d.mts +3 -3
  128. package/es/icons/lucideExtra/ChromeIcon.d.mts +8 -0
  129. package/es/icons/lucideExtra/ChromeIcon.mjs +13 -0
  130. package/es/icons/lucideExtra/ChromeIcon.mjs.map +1 -0
  131. package/es/icons/lucideExtra/CodepenIcon.d.mts +8 -0
  132. package/es/icons/lucideExtra/CodepenIcon.mjs +13 -0
  133. package/es/icons/lucideExtra/CodepenIcon.mjs.map +1 -0
  134. package/es/icons/lucideExtra/CodesandboxIcon.d.mts +8 -0
  135. package/es/icons/lucideExtra/CodesandboxIcon.mjs +13 -0
  136. package/es/icons/lucideExtra/CodesandboxIcon.mjs.map +1 -0
  137. package/es/icons/lucideExtra/CreateBotIcon.d.mts +3 -3
  138. package/es/icons/lucideExtra/DiscordIcon.d.mts +3 -3
  139. package/es/icons/lucideExtra/FacebookIcon.d.mts +8 -0
  140. package/es/icons/lucideExtra/FacebookIcon.mjs +13 -0
  141. package/es/icons/lucideExtra/FacebookIcon.mjs.map +1 -0
  142. package/es/icons/lucideExtra/FigmaIcon.d.mts +8 -0
  143. package/es/icons/lucideExtra/FigmaIcon.mjs +13 -0
  144. package/es/icons/lucideExtra/FigmaIcon.mjs.map +1 -0
  145. package/es/icons/lucideExtra/FramerIcon.d.mts +8 -0
  146. package/es/icons/lucideExtra/FramerIcon.mjs +13 -0
  147. package/es/icons/lucideExtra/FramerIcon.mjs.map +1 -0
  148. package/es/icons/lucideExtra/GithubIcon.d.mts +8 -0
  149. package/es/icons/lucideExtra/GithubIcon.mjs +13 -0
  150. package/es/icons/lucideExtra/GithubIcon.mjs.map +1 -0
  151. package/es/icons/lucideExtra/GitlabIcon.d.mts +8 -0
  152. package/es/icons/lucideExtra/GitlabIcon.mjs +13 -0
  153. package/es/icons/lucideExtra/GitlabIcon.mjs.map +1 -0
  154. package/es/icons/lucideExtra/GlobeOffIcon.d.mts +3 -3
  155. package/es/icons/lucideExtra/GooglePlayIcon.d.mts +8 -0
  156. package/es/icons/lucideExtra/GooglePlayIcon.mjs +13 -0
  157. package/es/icons/lucideExtra/GooglePlayIcon.mjs.map +1 -0
  158. package/es/icons/lucideExtra/GroupBotIcon.d.mts +3 -3
  159. package/es/icons/lucideExtra/GroupBotSquareIcon.d.mts +3 -3
  160. package/es/icons/lucideExtra/InstagramIcon.d.mts +8 -0
  161. package/es/icons/lucideExtra/InstagramIcon.mjs +13 -0
  162. package/es/icons/lucideExtra/InstagramIcon.mjs.map +1 -0
  163. package/es/icons/lucideExtra/LeftClickIcon.d.mts +3 -3
  164. package/es/icons/lucideExtra/LeftDoubleClickIcon.d.mts +3 -3
  165. package/es/icons/lucideExtra/LinkedinIcon.d.mts +8 -0
  166. package/es/icons/lucideExtra/LinkedinIcon.mjs +13 -0
  167. package/es/icons/lucideExtra/LinkedinIcon.mjs.map +1 -0
  168. package/es/icons/lucideExtra/McpIcon.d.mts +3 -3
  169. package/es/icons/lucideExtra/NotionIcon.d.mts +8 -0
  170. package/es/icons/lucideExtra/NotionIcon.mjs +23 -0
  171. package/es/icons/lucideExtra/NotionIcon.mjs.map +1 -0
  172. package/es/icons/lucideExtra/PocketIcon.d.mts +8 -0
  173. package/es/icons/lucideExtra/PocketIcon.mjs +13 -0
  174. package/es/icons/lucideExtra/PocketIcon.mjs.map +1 -0
  175. package/es/icons/lucideExtra/ProviderIcon.d.mts +3 -3
  176. package/es/icons/lucideExtra/RailSymbolIcon.d.mts +8 -0
  177. package/es/icons/lucideExtra/RailSymbolIcon.mjs +13 -0
  178. package/es/icons/lucideExtra/RailSymbolIcon.mjs.map +1 -0
  179. package/es/icons/lucideExtra/RedditIcon.d.mts +8 -0
  180. package/es/icons/lucideExtra/RedditIcon.mjs +27 -0
  181. package/es/icons/lucideExtra/RedditIcon.mjs.map +1 -0
  182. package/es/icons/lucideExtra/RightClickIcon.d.mts +3 -3
  183. package/es/icons/lucideExtra/RightDoubleClickIcon.d.mts +3 -3
  184. package/es/icons/lucideExtra/ShapesUploadIcon.d.mts +3 -3
  185. package/es/icons/lucideExtra/SkillsIcon.d.mts +3 -3
  186. package/es/icons/lucideExtra/SlackIcon.d.mts +8 -0
  187. package/es/icons/lucideExtra/SlackIcon.mjs +13 -0
  188. package/es/icons/lucideExtra/SlackIcon.mjs.map +1 -0
  189. package/es/icons/lucideExtra/ThinkIcon.d.mts +3 -3
  190. package/es/icons/lucideExtra/TreeDownRightIcon.d.mts +3 -3
  191. package/es/icons/lucideExtra/TreeUpDownRightIcon.d.mts +3 -3
  192. package/es/icons/lucideExtra/index.d.mts +19 -0
  193. package/es/mdx/Mdx/index.d.mts +2 -2
  194. package/es/mobile/ChatHeader/ChatHeaderTitle.d.mts +2 -2
  195. package/es/mobile/ChatInputArea/components/ChatSendButton.d.mts +2 -2
  196. package/es/mobile/TabBar/TabBar.d.mts +2 -2
  197. package/es/storybook/StoryBook/index.d.mts +2 -2
  198. package/package.json +1 -1
@@ -1,8 +1,8 @@
1
1
  import { LayoutTocProps } from "../type.mjs";
2
- import * as react55 from "react";
2
+ import * as react31 from "react";
3
3
 
4
4
  //#region src/Layout/components/LayoutToc.d.ts
5
- declare const LayoutToc: react55.NamedExoticComponent<LayoutTocProps>;
5
+ declare const LayoutToc: react31.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 react59 from "react";
2
+ import * as react27 from "react";
3
3
 
4
4
  //#region src/List/ListItem/index.d.ts
5
- declare const ListItem: react59.NamedExoticComponent<ListItemProps>;
5
+ declare const ListItem: react27.NamedExoticComponent<ListItemProps>;
6
6
  //#endregion
7
7
  export { ListItem };
8
8
  //# sourceMappingURL=index.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { MarkdownProps } from "./type.mjs";
2
- import * as react41 from "react";
2
+ import * as react26 from "react";
3
3
 
4
4
  //#region src/Markdown/Markdown.d.ts
5
- declare const Markdown: react41.NamedExoticComponent<MarkdownProps>;
5
+ declare const Markdown: react26.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 react42 from "react";
2
+ import * as react25 from "react";
3
3
 
4
4
  //#region src/Markdown/Typography.d.ts
5
- declare const Typography: react42.NamedExoticComponent<TypographyProps>;
5
+ declare const Typography: react25.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 react39 from "react";
3
+ import * as react70 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: react39.NamedExoticComponent<SearchResultCardsProps>;
17
+ declare const SearchResultCards: react70.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 react46 from "react";
2
+ import * as react44 from "react";
3
3
 
4
4
  //#region src/MaskShadow/MaskShadow.d.ts
5
- declare const MaskShadow: react46.NamedExoticComponent<MaskShadowProps>;
5
+ declare const MaskShadow: react44.NamedExoticComponent<MaskShadowProps>;
6
6
  //#endregion
7
7
  export { MaskShadow };
8
8
  //# sourceMappingURL=MaskShadow.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { MenuProps } from "./type.mjs";
2
- import * as react1 from "react";
2
+ import * as react38 from "react";
3
3
 
4
4
  //#region src/Menu/Menu.d.ts
5
- declare const Menu: react1.NamedExoticComponent<MenuProps<unknown>>;
5
+ declare const Menu: react38.NamedExoticComponent<MenuProps<unknown>>;
6
6
  //#endregion
7
7
  export { Menu };
8
8
  //# sourceMappingURL=Menu.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { MermaidProps } from "./type.mjs";
2
- import * as react21 from "react";
2
+ import * as react40 from "react";
3
3
 
4
4
  //#region src/Mermaid/Mermaid.d.ts
5
- declare const Mermaid: react21.NamedExoticComponent<MermaidProps>;
5
+ declare const Mermaid: react40.NamedExoticComponent<MermaidProps>;
6
6
  //#endregion
7
7
  export { Mermaid };
8
8
  //# sourceMappingURL=Mermaid.d.mts.map
@@ -44,6 +44,15 @@ const StaticMermaid = memo(({ children, className, fallbackClassName, ref, style
44
44
  const svgBlob = new Blob([finalSvgString], { type: "image/svg+xml" });
45
45
  setBlobUrl(URL.createObjectURL(svgBlob));
46
46
  }, [isLoading, data]);
47
+ const containerStyle = {
48
+ background: variant === "filled" ? background : void 0,
49
+ margin: 0,
50
+ minWidth: 300,
51
+ padding: variant === "borderless" ? 0 : 16,
52
+ position: "relative",
53
+ width: "100%",
54
+ ...style
55
+ };
47
56
  if (!blobUrl) return /* @__PURE__ */ jsx("div", {
48
57
  className: fallbackClassName,
49
58
  style,
@@ -60,18 +69,9 @@ const StaticMermaid = memo(({ children, className, fallbackClassName, ref, style
60
69
  objectFit: "contain",
61
70
  ref,
62
71
  src: blobUrl,
72
+ style: containerStyle,
63
73
  variant: "borderless",
64
- width: "100%",
65
- style: {
66
- background: variant === "filled" ? background : void 0,
67
- borderRadius: 0,
68
- margin: 0,
69
- minWidth: 300,
70
- padding: variant === "borderless" ? 0 : 16,
71
- position: "relative",
72
- width: "100%",
73
- ...style
74
- }
74
+ width: "100%"
75
75
  });
76
76
  });
77
77
  StaticMermaid.displayName = "StaticMermaid";
@@ -1 +1 @@
1
- {"version":3,"file":"StaticMermaid.mjs","names":["Image"],"sources":["../../../src/Mermaid/SyntaxMermaid/StaticMermaid.tsx"],"sourcesContent":["'use client';\n\nimport { kebabCase } from 'es-toolkit/compat';\nimport { type Ref } from 'react';\nimport { memo, useEffect, useId, useMemo, useState } from 'react';\n\nimport { useMermaid } from '@/hooks/useMermaid';\nimport Image from '@/Image';\n\nimport { mermaidThemes } from '../const';\nimport { type SyntaxMermaidProps } from '../type';\n\ninterface StaticMermaidProps {\n children: string;\n className?: string;\n fallbackClassName?: string;\n ref?: Ref<HTMLDivElement>;\n style?: SyntaxMermaidProps['style'];\n theme?: SyntaxMermaidProps['theme'];\n variant?: SyntaxMermaidProps['variant'];\n}\n\nconst StaticMermaid = memo<StaticMermaidProps>(\n ({ children, className, fallbackClassName, ref, style, theme: customTheme, variant }) => {\n const safeChildren = children ?? '';\n const isDefaultTheme = customTheme === 'lobe-theme' || !customTheme;\n\n const background = useMemo(() => {\n if (isDefaultTheme) return;\n return mermaidThemes.find((item) => item.id === customTheme)?.background;\n }, [isDefaultTheme, customTheme]);\n\n const id = useId();\n const mermaidId = kebabCase(`mermaid-${id}`);\n const data = useMermaid(safeChildren, {\n id: mermaidId,\n theme: isDefaultTheme ? undefined : customTheme,\n });\n const isLoading = !data;\n const [blobUrl, setBlobUrl] = useState<string>();\n\n // 组件卸载时清理 Blob URL,避免内存泄漏\n useEffect(() => {\n return () => {\n if (blobUrl) URL.revokeObjectURL(blobUrl);\n };\n }, [blobUrl]);\n\n useEffect(() => {\n if (isLoading || !data) return;\n let finalSvgString = data;\n\n // 修复Firefox点击预览mermaid图时宽高为0导致不显示的异常\n if (\n typeof window !== 'undefined' &&\n typeof navigator !== 'undefined' &&\n navigator.userAgent.includes('Firefox')\n ) {\n const parser = new DOMParser();\n const svgDoc = parser.parseFromString(data, 'image/svg+xml');\n const svgElement = svgDoc.documentElement;\n if (svgElement && svgElement.hasAttribute('viewBox')) {\n const viewBox = svgElement.getAttribute('viewBox')!;\n const viewBoxParts = viewBox.split(' ');\n if (Array.isArray(viewBoxParts) && viewBoxParts.length === 4) {\n svgElement.setAttribute('width', viewBoxParts[2]);\n svgElement.setAttribute('height', viewBoxParts[3]);\n }\n finalSvgString = new XMLSerializer().serializeToString(svgDoc);\n }\n }\n\n // 创建Blob对象\n const svgBlob = new Blob([finalSvgString], { type: 'image/svg+xml' });\n // 创建并保存Blob URL\n const url = URL.createObjectURL(svgBlob);\n setBlobUrl(url);\n }, [isLoading, data]);\n\n if (!blobUrl) {\n return (\n <div className={fallbackClassName} style={style}>\n <div style={{ padding: 16 }}>Loading...</div>\n </div>\n );\n }\n\n return (\n <Image\n alt={'mermaid'}\n className={className}\n maxHeight={480}\n minWidth={300}\n objectFit={'contain'}\n ref={ref}\n src={blobUrl}\n variant={'borderless'}\n width={'100%'}\n style={{\n background: variant === 'filled' ? background : undefined,\n borderRadius: 0,\n margin: 0,\n minWidth: 300,\n padding: variant === 'borderless' ? 0 : 16,\n position: 'relative',\n width: '100%',\n ...style,\n }}\n />\n );\n },\n);\n\nStaticMermaid.displayName = 'StaticMermaid';\n\nexport default StaticMermaid;\n"],"mappings":";;;;;;;;;;AAsBA,MAAM,gBAAgB,MACnB,EAAE,UAAU,WAAW,mBAAmB,KAAK,OAAO,OAAO,aAAa,cAAc;CACvF,MAAM,eAAe,YAAY;CACjC,MAAM,iBAAiB,gBAAgB,gBAAgB,CAAC;CAExD,MAAM,aAAa,cAAc;AAC/B,MAAI,eAAgB;AACpB,SAAO,cAAc,MAAM,SAAS,KAAK,OAAO,YAAY,EAAE;IAC7D,CAAC,gBAAgB,YAAY,CAAC;CAIjC,MAAM,OAAO,WAAW,cAAc;EACpC,IAFgB,UAAU,WADjB,OAAO,GAC0B;EAG1C,OAAO,iBAAiB,SAAY;EACrC,CAAC;CACF,MAAM,YAAY,CAAC;CACnB,MAAM,CAAC,SAAS,cAAc,UAAkB;AAGhD,iBAAgB;AACd,eAAa;AACX,OAAI,QAAS,KAAI,gBAAgB,QAAQ;;IAE1C,CAAC,QAAQ,CAAC;AAEb,iBAAgB;AACd,MAAI,aAAa,CAAC,KAAM;EACxB,IAAI,iBAAiB;AAGrB,MACE,OAAO,WAAW,eAClB,OAAO,cAAc,eACrB,UAAU,UAAU,SAAS,UAAU,EACvC;GAEA,MAAM,SADS,IAAI,WAAW,CACR,gBAAgB,MAAM,gBAAgB;GAC5D,MAAM,aAAa,OAAO;AAC1B,OAAI,cAAc,WAAW,aAAa,UAAU,EAAE;IAEpD,MAAM,eADU,WAAW,aAAa,UAAU,CACrB,MAAM,IAAI;AACvC,QAAI,MAAM,QAAQ,aAAa,IAAI,aAAa,WAAW,GAAG;AAC5D,gBAAW,aAAa,SAAS,aAAa,GAAG;AACjD,gBAAW,aAAa,UAAU,aAAa,GAAG;;AAEpD,qBAAiB,IAAI,eAAe,CAAC,kBAAkB,OAAO;;;EAKlE,MAAM,UAAU,IAAI,KAAK,CAAC,eAAe,EAAE,EAAE,MAAM,iBAAiB,CAAC;AAGrE,aADY,IAAI,gBAAgB,QAAQ,CACzB;IACd,CAAC,WAAW,KAAK,CAAC;AAErB,KAAI,CAAC,QACH,QACE,oBAAC;EAAI,WAAW;EAA0B;YACxC,oBAAC;GAAI,OAAO,EAAE,SAAS,IAAI;aAAE;IAAgB;GACzC;AAIV,QACE,oBAACA;EACC,KAAK;EACM;EACX,WAAW;EACX,UAAU;EACV,WAAW;EACN;EACL,KAAK;EACL,SAAS;EACT,OAAO;EACP,OAAO;GACL,YAAY,YAAY,WAAW,aAAa;GAChD,cAAc;GACd,QAAQ;GACR,UAAU;GACV,SAAS,YAAY,eAAe,IAAI;GACxC,UAAU;GACV,OAAO;GACP,GAAG;GACJ;GACD;EAGP;AAED,cAAc,cAAc;AAE5B,4BAAe"}
1
+ {"version":3,"file":"StaticMermaid.mjs","names":["Image"],"sources":["../../../src/Mermaid/SyntaxMermaid/StaticMermaid.tsx"],"sourcesContent":["'use client';\n\nimport { kebabCase } from 'es-toolkit/compat';\nimport { type Ref } from 'react';\nimport { memo, useEffect, useId, useMemo, useState } from 'react';\n\nimport { useMermaid } from '@/hooks/useMermaid';\nimport Image from '@/Image';\n\nimport { mermaidThemes } from '../const';\nimport { type SyntaxMermaidProps } from '../type';\n\ninterface StaticMermaidProps {\n children: string;\n className?: string;\n fallbackClassName?: string;\n ref?: Ref<HTMLDivElement>;\n style?: SyntaxMermaidProps['style'];\n theme?: SyntaxMermaidProps['theme'];\n variant?: SyntaxMermaidProps['variant'];\n}\n\nconst StaticMermaid = memo<StaticMermaidProps>(\n ({ children, className, fallbackClassName, ref, style, theme: customTheme, variant }) => {\n const safeChildren = children ?? '';\n const isDefaultTheme = customTheme === 'lobe-theme' || !customTheme;\n\n const background = useMemo(() => {\n if (isDefaultTheme) return;\n return mermaidThemes.find((item) => item.id === customTheme)?.background;\n }, [isDefaultTheme, customTheme]);\n\n const id = useId();\n const mermaidId = kebabCase(`mermaid-${id}`);\n const data = useMermaid(safeChildren, {\n id: mermaidId,\n theme: isDefaultTheme ? undefined : customTheme,\n });\n const isLoading = !data;\n const [blobUrl, setBlobUrl] = useState<string>();\n\n // 组件卸载时清理 Blob URL,避免内存泄漏\n useEffect(() => {\n return () => {\n if (blobUrl) URL.revokeObjectURL(blobUrl);\n };\n }, [blobUrl]);\n\n useEffect(() => {\n if (isLoading || !data) return;\n let finalSvgString = data;\n\n // 修复Firefox点击预览mermaid图时宽高为0导致不显示的异常\n if (\n typeof window !== 'undefined' &&\n typeof navigator !== 'undefined' &&\n navigator.userAgent.includes('Firefox')\n ) {\n const parser = new DOMParser();\n const svgDoc = parser.parseFromString(data, 'image/svg+xml');\n const svgElement = svgDoc.documentElement;\n if (svgElement && svgElement.hasAttribute('viewBox')) {\n const viewBox = svgElement.getAttribute('viewBox')!;\n const viewBoxParts = viewBox.split(' ');\n if (Array.isArray(viewBoxParts) && viewBoxParts.length === 4) {\n svgElement.setAttribute('width', viewBoxParts[2]);\n svgElement.setAttribute('height', viewBoxParts[3]);\n }\n finalSvgString = new XMLSerializer().serializeToString(svgDoc);\n }\n }\n\n // 创建Blob对象\n const svgBlob = new Blob([finalSvgString], { type: 'image/svg+xml' });\n // 创建并保存Blob URL\n const url = URL.createObjectURL(svgBlob);\n setBlobUrl(url);\n }, [isLoading, data]);\n\n const containerStyle = {\n background: variant === 'filled' ? background : undefined,\n margin: 0,\n minWidth: 300,\n padding: variant === 'borderless' ? 0 : 16,\n position: 'relative' as const,\n width: '100%',\n ...style,\n };\n\n if (!blobUrl) {\n return (\n <div className={fallbackClassName} style={style}>\n <div style={{ padding: 16 }}>Loading...</div>\n </div>\n );\n }\n\n return (\n <Image\n alt={'mermaid'}\n className={className}\n maxHeight={480}\n minWidth={300}\n objectFit={'contain'}\n ref={ref}\n src={blobUrl}\n style={containerStyle}\n variant={'borderless'}\n width={'100%'}\n />\n );\n },\n);\n\nStaticMermaid.displayName = 'StaticMermaid';\n\nexport default StaticMermaid;\n"],"mappings":";;;;;;;;;;AAsBA,MAAM,gBAAgB,MACnB,EAAE,UAAU,WAAW,mBAAmB,KAAK,OAAO,OAAO,aAAa,cAAc;CACvF,MAAM,eAAe,YAAY;CACjC,MAAM,iBAAiB,gBAAgB,gBAAgB,CAAC;CAExD,MAAM,aAAa,cAAc;AAC/B,MAAI,eAAgB;AACpB,SAAO,cAAc,MAAM,SAAS,KAAK,OAAO,YAAY,EAAE;IAC7D,CAAC,gBAAgB,YAAY,CAAC;CAIjC,MAAM,OAAO,WAAW,cAAc;EACpC,IAFgB,UAAU,WADjB,OAAO,GAC0B;EAG1C,OAAO,iBAAiB,SAAY;EACrC,CAAC;CACF,MAAM,YAAY,CAAC;CACnB,MAAM,CAAC,SAAS,cAAc,UAAkB;AAGhD,iBAAgB;AACd,eAAa;AACX,OAAI,QAAS,KAAI,gBAAgB,QAAQ;;IAE1C,CAAC,QAAQ,CAAC;AAEb,iBAAgB;AACd,MAAI,aAAa,CAAC,KAAM;EACxB,IAAI,iBAAiB;AAGrB,MACE,OAAO,WAAW,eAClB,OAAO,cAAc,eACrB,UAAU,UAAU,SAAS,UAAU,EACvC;GAEA,MAAM,SADS,IAAI,WAAW,CACR,gBAAgB,MAAM,gBAAgB;GAC5D,MAAM,aAAa,OAAO;AAC1B,OAAI,cAAc,WAAW,aAAa,UAAU,EAAE;IAEpD,MAAM,eADU,WAAW,aAAa,UAAU,CACrB,MAAM,IAAI;AACvC,QAAI,MAAM,QAAQ,aAAa,IAAI,aAAa,WAAW,GAAG;AAC5D,gBAAW,aAAa,SAAS,aAAa,GAAG;AACjD,gBAAW,aAAa,UAAU,aAAa,GAAG;;AAEpD,qBAAiB,IAAI,eAAe,CAAC,kBAAkB,OAAO;;;EAKlE,MAAM,UAAU,IAAI,KAAK,CAAC,eAAe,EAAE,EAAE,MAAM,iBAAiB,CAAC;AAGrE,aADY,IAAI,gBAAgB,QAAQ,CACzB;IACd,CAAC,WAAW,KAAK,CAAC;CAErB,MAAM,iBAAiB;EACrB,YAAY,YAAY,WAAW,aAAa;EAChD,QAAQ;EACR,UAAU;EACV,SAAS,YAAY,eAAe,IAAI;EACxC,UAAU;EACV,OAAO;EACP,GAAG;EACJ;AAED,KAAI,CAAC,QACH,QACE,oBAAC;EAAI,WAAW;EAA0B;YACxC,oBAAC;GAAI,OAAO,EAAE,SAAS,IAAI;aAAE;IAAgB;GACzC;AAIV,QACE,oBAACA;EACC,KAAK;EACM;EACX,WAAW;EACX,UAAU;EACV,WAAW;EACN;EACL,KAAK;EACL,OAAO;EACP,SAAS;EACT,OAAO;GACP;EAGP;AAED,cAAc,cAAc;AAE5B,4BAAe"}
@@ -48,6 +48,15 @@ const StreamMermaid = memo(({ children, className, fallbackClassName, ref, style
48
48
  const svgBlob = new Blob([finalSvgString], { type: "image/svg+xml" });
49
49
  setBlobUrl(URL.createObjectURL(svgBlob));
50
50
  }, [isLoading, data]);
51
+ const containerStyle = {
52
+ background: variant === "filled" ? background : void 0,
53
+ margin: 0,
54
+ minWidth: 300,
55
+ padding: variant === "borderless" ? 0 : 16,
56
+ position: "relative",
57
+ width: "100%",
58
+ ...style
59
+ };
51
60
  if (!blobUrl) return /* @__PURE__ */ jsx("div", {
52
61
  className: fallbackClassName,
53
62
  style,
@@ -64,18 +73,9 @@ const StreamMermaid = memo(({ children, className, fallbackClassName, ref, style
64
73
  objectFit: "contain",
65
74
  ref,
66
75
  src: blobUrl,
76
+ style: containerStyle,
67
77
  variant: "borderless",
68
- width: "100%",
69
- style: {
70
- background: variant === "filled" ? background : void 0,
71
- borderRadius: 0,
72
- margin: 0,
73
- minWidth: 300,
74
- padding: variant === "borderless" ? 0 : 16,
75
- position: "relative",
76
- width: "100%",
77
- ...style
78
- }
78
+ width: "100%"
79
79
  });
80
80
  });
81
81
  StreamMermaid.displayName = "StreamMermaid";
@@ -1 +1 @@
1
- {"version":3,"file":"StreamMermaid.mjs","names":["Image"],"sources":["../../../src/Mermaid/SyntaxMermaid/StreamMermaid.tsx"],"sourcesContent":["'use client';\n\nimport { kebabCase } from 'es-toolkit/compat';\nimport { type Ref } from 'react';\nimport { memo, useEffect, useId, useMemo, useState } from 'react';\n\nimport { useStreamMermaid } from '@/hooks/useStreamMermaid';\nimport Image from '@/Image';\n\nimport { mermaidThemes } from '../const';\nimport { type SyntaxMermaidProps } from '../type';\n\ninterface StreamMermaidProps {\n children: string;\n className?: string;\n fallbackClassName?: string;\n ref?: Ref<HTMLDivElement>;\n style?: SyntaxMermaidProps['style'];\n theme?: SyntaxMermaidProps['theme'];\n variant?: SyntaxMermaidProps['variant'];\n}\n\nconst StreamMermaid = memo<StreamMermaidProps>(\n ({ children, className, fallbackClassName, ref, style, theme: customTheme, variant }) => {\n const safeChildren = children ?? '';\n const isDefaultTheme = customTheme === 'lobe-theme' || !customTheme;\n\n const background = useMemo(() => {\n if (isDefaultTheme) return;\n return mermaidThemes.find((item) => item.id === customTheme)?.background;\n }, [isDefaultTheme, customTheme]);\n\n const id = useId();\n const mermaidId = kebabCase(`mermaid-${id}`);\n const data = useStreamMermaid(safeChildren, {\n enabled: true,\n id: mermaidId,\n theme: isDefaultTheme ? undefined : customTheme,\n });\n const isLoading = !data;\n const [blobUrl, setBlobUrl] = useState<string>();\n\n // 组件卸载时清理 Blob URL,避免内存泄漏\n useEffect(() => {\n return () => {\n if (blobUrl) URL.revokeObjectURL(blobUrl);\n };\n }, [blobUrl]);\n\n useEffect(() => {\n if (isLoading || !data) {\n // Clear blob URL when loading or no data\n setBlobUrl(undefined);\n return;\n }\n\n let finalSvgString = data;\n\n // 修复Firefox点击预览mermaid图时宽高为0导致不显示的异常\n if (\n typeof window !== 'undefined' &&\n typeof navigator !== 'undefined' &&\n navigator.userAgent.includes('Firefox')\n ) {\n const parser = new DOMParser();\n const svgDoc = parser.parseFromString(data, 'image/svg+xml');\n const svgElement = svgDoc.documentElement;\n if (svgElement && svgElement.hasAttribute('viewBox')) {\n const viewBox = svgElement.getAttribute('viewBox')!;\n const viewBoxParts = viewBox.split(' ');\n if (Array.isArray(viewBoxParts) && viewBoxParts.length === 4) {\n svgElement.setAttribute('width', viewBoxParts[2]);\n svgElement.setAttribute('height', viewBoxParts[3]);\n }\n finalSvgString = new XMLSerializer().serializeToString(svgDoc);\n }\n }\n\n // 创建Blob对象\n const svgBlob = new Blob([finalSvgString], { type: 'image/svg+xml' });\n // 创建并保存Blob URL\n const url = URL.createObjectURL(svgBlob);\n setBlobUrl(url);\n }, [isLoading, data]);\n\n if (!blobUrl) {\n return (\n <div className={fallbackClassName} style={style}>\n <div style={{ padding: 16 }}>Rendering...</div>\n </div>\n );\n }\n\n return (\n <Image\n alt={'mermaid'}\n className={className}\n maxHeight={480}\n minWidth={300}\n objectFit={'contain'}\n ref={ref}\n src={blobUrl}\n variant={'borderless'}\n width={'100%'}\n style={{\n background: variant === 'filled' ? background : undefined,\n borderRadius: 0,\n margin: 0,\n minWidth: 300,\n padding: variant === 'borderless' ? 0 : 16,\n position: 'relative',\n width: '100%',\n ...style,\n }}\n />\n );\n },\n);\n\nStreamMermaid.displayName = 'StreamMermaid';\n\nexport default StreamMermaid;\n"],"mappings":";;;;;;;;;;AAsBA,MAAM,gBAAgB,MACnB,EAAE,UAAU,WAAW,mBAAmB,KAAK,OAAO,OAAO,aAAa,cAAc;CACvF,MAAM,eAAe,YAAY;CACjC,MAAM,iBAAiB,gBAAgB,gBAAgB,CAAC;CAExD,MAAM,aAAa,cAAc;AAC/B,MAAI,eAAgB;AACpB,SAAO,cAAc,MAAM,SAAS,KAAK,OAAO,YAAY,EAAE;IAC7D,CAAC,gBAAgB,YAAY,CAAC;CAIjC,MAAM,OAAO,iBAAiB,cAAc;EAC1C,SAAS;EACT,IAHgB,UAAU,WADjB,OAAO,GAC0B;EAI1C,OAAO,iBAAiB,SAAY;EACrC,CAAC;CACF,MAAM,YAAY,CAAC;CACnB,MAAM,CAAC,SAAS,cAAc,UAAkB;AAGhD,iBAAgB;AACd,eAAa;AACX,OAAI,QAAS,KAAI,gBAAgB,QAAQ;;IAE1C,CAAC,QAAQ,CAAC;AAEb,iBAAgB;AACd,MAAI,aAAa,CAAC,MAAM;AAEtB,cAAW,OAAU;AACrB;;EAGF,IAAI,iBAAiB;AAGrB,MACE,OAAO,WAAW,eAClB,OAAO,cAAc,eACrB,UAAU,UAAU,SAAS,UAAU,EACvC;GAEA,MAAM,SADS,IAAI,WAAW,CACR,gBAAgB,MAAM,gBAAgB;GAC5D,MAAM,aAAa,OAAO;AAC1B,OAAI,cAAc,WAAW,aAAa,UAAU,EAAE;IAEpD,MAAM,eADU,WAAW,aAAa,UAAU,CACrB,MAAM,IAAI;AACvC,QAAI,MAAM,QAAQ,aAAa,IAAI,aAAa,WAAW,GAAG;AAC5D,gBAAW,aAAa,SAAS,aAAa,GAAG;AACjD,gBAAW,aAAa,UAAU,aAAa,GAAG;;AAEpD,qBAAiB,IAAI,eAAe,CAAC,kBAAkB,OAAO;;;EAKlE,MAAM,UAAU,IAAI,KAAK,CAAC,eAAe,EAAE,EAAE,MAAM,iBAAiB,CAAC;AAGrE,aADY,IAAI,gBAAgB,QAAQ,CACzB;IACd,CAAC,WAAW,KAAK,CAAC;AAErB,KAAI,CAAC,QACH,QACE,oBAAC;EAAI,WAAW;EAA0B;YACxC,oBAAC;GAAI,OAAO,EAAE,SAAS,IAAI;aAAE;IAAkB;GAC3C;AAIV,QACE,oBAACA;EACC,KAAK;EACM;EACX,WAAW;EACX,UAAU;EACV,WAAW;EACN;EACL,KAAK;EACL,SAAS;EACT,OAAO;EACP,OAAO;GACL,YAAY,YAAY,WAAW,aAAa;GAChD,cAAc;GACd,QAAQ;GACR,UAAU;GACV,SAAS,YAAY,eAAe,IAAI;GACxC,UAAU;GACV,OAAO;GACP,GAAG;GACJ;GACD;EAGP;AAED,cAAc,cAAc;AAE5B,4BAAe"}
1
+ {"version":3,"file":"StreamMermaid.mjs","names":["Image"],"sources":["../../../src/Mermaid/SyntaxMermaid/StreamMermaid.tsx"],"sourcesContent":["'use client';\n\nimport { kebabCase } from 'es-toolkit/compat';\nimport { type Ref } from 'react';\nimport { memo, useEffect, useId, useMemo, useState } from 'react';\n\nimport { useStreamMermaid } from '@/hooks/useStreamMermaid';\nimport Image from '@/Image';\n\nimport { mermaidThemes } from '../const';\nimport { type SyntaxMermaidProps } from '../type';\n\ninterface StreamMermaidProps {\n children: string;\n className?: string;\n fallbackClassName?: string;\n ref?: Ref<HTMLDivElement>;\n style?: SyntaxMermaidProps['style'];\n theme?: SyntaxMermaidProps['theme'];\n variant?: SyntaxMermaidProps['variant'];\n}\n\nconst StreamMermaid = memo<StreamMermaidProps>(\n ({ children, className, fallbackClassName, ref, style, theme: customTheme, variant }) => {\n const safeChildren = children ?? '';\n const isDefaultTheme = customTheme === 'lobe-theme' || !customTheme;\n\n const background = useMemo(() => {\n if (isDefaultTheme) return;\n return mermaidThemes.find((item) => item.id === customTheme)?.background;\n }, [isDefaultTheme, customTheme]);\n\n const id = useId();\n const mermaidId = kebabCase(`mermaid-${id}`);\n const data = useStreamMermaid(safeChildren, {\n enabled: true,\n id: mermaidId,\n theme: isDefaultTheme ? undefined : customTheme,\n });\n const isLoading = !data;\n const [blobUrl, setBlobUrl] = useState<string>();\n\n // 组件卸载时清理 Blob URL,避免内存泄漏\n useEffect(() => {\n return () => {\n if (blobUrl) URL.revokeObjectURL(blobUrl);\n };\n }, [blobUrl]);\n\n useEffect(() => {\n if (isLoading || !data) {\n // Clear blob URL when loading or no data\n setBlobUrl(undefined);\n return;\n }\n\n let finalSvgString = data;\n\n // 修复Firefox点击预览mermaid图时宽高为0导致不显示的异常\n if (\n typeof window !== 'undefined' &&\n typeof navigator !== 'undefined' &&\n navigator.userAgent.includes('Firefox')\n ) {\n const parser = new DOMParser();\n const svgDoc = parser.parseFromString(data, 'image/svg+xml');\n const svgElement = svgDoc.documentElement;\n if (svgElement && svgElement.hasAttribute('viewBox')) {\n const viewBox = svgElement.getAttribute('viewBox')!;\n const viewBoxParts = viewBox.split(' ');\n if (Array.isArray(viewBoxParts) && viewBoxParts.length === 4) {\n svgElement.setAttribute('width', viewBoxParts[2]);\n svgElement.setAttribute('height', viewBoxParts[3]);\n }\n finalSvgString = new XMLSerializer().serializeToString(svgDoc);\n }\n }\n\n // 创建Blob对象\n const svgBlob = new Blob([finalSvgString], { type: 'image/svg+xml' });\n // 创建并保存Blob URL\n const url = URL.createObjectURL(svgBlob);\n setBlobUrl(url);\n }, [isLoading, data]);\n\n const containerStyle = {\n background: variant === 'filled' ? background : undefined,\n margin: 0,\n minWidth: 300,\n padding: variant === 'borderless' ? 0 : 16,\n position: 'relative' as const,\n width: '100%',\n ...style,\n };\n\n if (!blobUrl) {\n return (\n <div className={fallbackClassName} style={style}>\n <div style={{ padding: 16 }}>Rendering...</div>\n </div>\n );\n }\n\n return (\n <Image\n alt={'mermaid'}\n className={className}\n maxHeight={480}\n minWidth={300}\n objectFit={'contain'}\n ref={ref}\n src={blobUrl}\n style={containerStyle}\n variant={'borderless'}\n width={'100%'}\n />\n );\n },\n);\n\nStreamMermaid.displayName = 'StreamMermaid';\n\nexport default StreamMermaid;\n"],"mappings":";;;;;;;;;;AAsBA,MAAM,gBAAgB,MACnB,EAAE,UAAU,WAAW,mBAAmB,KAAK,OAAO,OAAO,aAAa,cAAc;CACvF,MAAM,eAAe,YAAY;CACjC,MAAM,iBAAiB,gBAAgB,gBAAgB,CAAC;CAExD,MAAM,aAAa,cAAc;AAC/B,MAAI,eAAgB;AACpB,SAAO,cAAc,MAAM,SAAS,KAAK,OAAO,YAAY,EAAE;IAC7D,CAAC,gBAAgB,YAAY,CAAC;CAIjC,MAAM,OAAO,iBAAiB,cAAc;EAC1C,SAAS;EACT,IAHgB,UAAU,WADjB,OAAO,GAC0B;EAI1C,OAAO,iBAAiB,SAAY;EACrC,CAAC;CACF,MAAM,YAAY,CAAC;CACnB,MAAM,CAAC,SAAS,cAAc,UAAkB;AAGhD,iBAAgB;AACd,eAAa;AACX,OAAI,QAAS,KAAI,gBAAgB,QAAQ;;IAE1C,CAAC,QAAQ,CAAC;AAEb,iBAAgB;AACd,MAAI,aAAa,CAAC,MAAM;AAEtB,cAAW,OAAU;AACrB;;EAGF,IAAI,iBAAiB;AAGrB,MACE,OAAO,WAAW,eAClB,OAAO,cAAc,eACrB,UAAU,UAAU,SAAS,UAAU,EACvC;GAEA,MAAM,SADS,IAAI,WAAW,CACR,gBAAgB,MAAM,gBAAgB;GAC5D,MAAM,aAAa,OAAO;AAC1B,OAAI,cAAc,WAAW,aAAa,UAAU,EAAE;IAEpD,MAAM,eADU,WAAW,aAAa,UAAU,CACrB,MAAM,IAAI;AACvC,QAAI,MAAM,QAAQ,aAAa,IAAI,aAAa,WAAW,GAAG;AAC5D,gBAAW,aAAa,SAAS,aAAa,GAAG;AACjD,gBAAW,aAAa,UAAU,aAAa,GAAG;;AAEpD,qBAAiB,IAAI,eAAe,CAAC,kBAAkB,OAAO;;;EAKlE,MAAM,UAAU,IAAI,KAAK,CAAC,eAAe,EAAE,EAAE,MAAM,iBAAiB,CAAC;AAGrE,aADY,IAAI,gBAAgB,QAAQ,CACzB;IACd,CAAC,WAAW,KAAK,CAAC;CAErB,MAAM,iBAAiB;EACrB,YAAY,YAAY,WAAW,aAAa;EAChD,QAAQ;EACR,UAAU;EACV,SAAS,YAAY,eAAe,IAAI;EACxC,UAAU;EACV,OAAO;EACP,GAAG;EACJ;AAED,KAAI,CAAC,QACH,QACE,oBAAC;EAAI,WAAW;EAA0B;YACxC,oBAAC;GAAI,OAAO,EAAE,SAAS,IAAI;aAAE;IAAkB;GAC3C;AAIV,QACE,oBAACA;EACC,KAAK;EACM;EACX,WAAW;EACX,UAAU;EACV,WAAW;EACN;EACL,KAAK;EACL,OAAO;EACP,SAAS;EACT,OAAO;GACP;EAGP;AAED,cAAc,cAAc;AAE5B,4BAAe"}
@@ -1,8 +1,8 @@
1
1
  import { SyntaxMermaidProps } from "../type.mjs";
2
- import * as react22 from "react";
2
+ import * as react39 from "react";
3
3
 
4
4
  //#region src/Mermaid/SyntaxMermaid/index.d.ts
5
- declare const SyntaxMermaid: react22.NamedExoticComponent<SyntaxMermaidProps>;
5
+ declare const SyntaxMermaid: react39.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 react8 from "react";
2
+ import * as react22 from "react";
3
3
 
4
4
  //#region src/Modal/Modal.d.ts
5
- declare const Modal: react8.NamedExoticComponent<ModalProps>;
5
+ declare const Modal: react22.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 react9 from "react";
2
+ import * as react23 from "react";
3
3
  import { ReactNode } from "react";
4
4
 
5
5
  //#region src/Modal/ModalProvider.d.ts
6
- declare const ModalProvider: react9.NamedExoticComponent<{
6
+ declare const ModalProvider: react23.NamedExoticComponent<{
7
7
  children: ReactNode;
8
8
  value: ModalContextValue;
9
9
  }>;
@@ -1,4 +1,4 @@
1
- import * as react37 from "react";
1
+ import * as react71 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: react37.NamedExoticComponent<{
9
+ declare const MotionProvider: react71.NamedExoticComponent<{
10
10
  children: ReactNode;
11
11
  motion: MotionComponentType;
12
12
  }>;
@@ -1,8 +1,8 @@
1
1
  import { SearchBarProps } from "./type.mjs";
2
- import * as react7 from "react";
2
+ import * as react21 from "react";
3
3
 
4
4
  //#region src/SearchBar/SearchBar.d.ts
5
- declare const SearchBar: react7.NamedExoticComponent<SearchBarProps>;
5
+ declare const SearchBar: react21.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 react6 from "react";
2
+ import * as react20 from "react";
3
3
 
4
4
  //#region src/Segmented/Segmented.d.ts
5
- declare const Segmented: react6.NamedExoticComponent<SegmentedProps>;
5
+ declare const Segmented: react20.NamedExoticComponent<SegmentedProps>;
6
6
  //#endregion
7
7
  export { Segmented };
8
8
  //# sourceMappingURL=Segmented.d.mts.map
@@ -1,11 +1,11 @@
1
1
  import { SelectProps } from "./type.mjs";
2
- import * as react72 from "react";
2
+ import * as react19 from "react";
3
3
 
4
4
  //#region src/Select/Select.d.ts
5
5
  /**
6
6
  * @deprecated Use `Select` from `@lobehub/ui/base-ui` instead.
7
7
  */
8
- declare const Select: react72.NamedExoticComponent<SelectProps>;
8
+ declare const Select: react19.NamedExoticComponent<SelectProps>;
9
9
  //#endregion
10
10
  export { Select };
11
11
  //# sourceMappingURL=Select.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { SideNavProps } from "./type.mjs";
2
- import * as react5 from "react";
2
+ import * as react18 from "react";
3
3
 
4
4
  //#region src/SideNav/SideNav.d.ts
5
- declare const SideNav: react5.NamedExoticComponent<SideNavProps>;
5
+ declare const SideNav: react18.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 react65 from "react";
2
+ import * as react17 from "react";
3
3
 
4
4
  //#region src/SliderWithInput/SliderWithInput.d.ts
5
- declare const SliderWithInput: react65.NamedExoticComponent<SliderWithInputProps>;
5
+ declare const SliderWithInput: react17.NamedExoticComponent<SliderWithInputProps>;
6
6
  //#endregion
7
7
  export { SliderWithInput };
8
8
  //# sourceMappingURL=SliderWithInput.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { ThemeProviderProps } from "./type.mjs";
2
- import * as react71 from "react";
2
+ import * as react16 from "react";
3
3
 
4
4
  //#region src/ThemeProvider/ThemeProvider.d.ts
5
- declare const ThemeProvider: react71.NamedExoticComponent<ThemeProviderProps>;
5
+ declare const ThemeProvider: react16.NamedExoticComponent<ThemeProviderProps>;
6
6
  //#endregion
7
7
  export { ThemeProvider };
8
8
  //# sourceMappingURL=ThemeProvider.d.mts.map
package/es/Toc/Toc.d.mts CHANGED
@@ -1,8 +1,8 @@
1
1
  import { TocProps } from "./type.mjs";
2
- import * as react66 from "react";
2
+ import * as react13 from "react";
3
3
 
4
4
  //#region src/Toc/Toc.d.ts
5
- declare const Toc: react66.NamedExoticComponent<TocProps>;
5
+ declare const Toc: react13.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 react38 from "react";
4
+ import * as react72 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: react38.NamedExoticComponent<VideoProps>;
42
+ declare const Video: react72.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 react141 from "react";
2
+ import * as react164 from "react";
3
3
 
4
4
  //#region src/awesome/AuroraBackground/AuroraBackground.d.ts
5
- declare const AuroraBackground: react141.NamedExoticComponent<AuroraBackgroundProps>;
5
+ declare const AuroraBackground: react164.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 react140 from "react";
3
+ import * as react163 from "react";
4
4
 
5
5
  //#region src/awesome/BottomGradientButton/BottomGradientButton.d.ts
6
- declare const BottomGradientButton: react140.NamedExoticComponent<ButtonProps>;
6
+ declare const BottomGradientButton: react163.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 react142 from "react";
2
+ import * as react165 from "react";
3
3
 
4
4
  //#region src/awesome/Features/Features.d.ts
5
- declare const Features: react142.NamedExoticComponent<FeaturesProps>;
5
+ declare const Features: react165.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 react143 from "react";
2
+ import * as react166 from "react";
3
3
 
4
4
  //#region src/awesome/Giscus/Giscus.d.ts
5
- declare const Giscus: react143.NamedExoticComponent<GiscusProps>;
5
+ declare const Giscus: react166.NamedExoticComponent<GiscusProps>;
6
6
  //#endregion
7
7
  export { Giscus };
8
8
  //# sourceMappingURL=Giscus.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { GradientButtonProps } from "./type.mjs";
2
- import * as react144 from "react";
2
+ import * as react173 from "react";
3
3
 
4
4
  //#region src/awesome/GradientButton/GradientButton.d.ts
5
- declare const GradientButton: react144.NamedExoticComponent<GradientButtonProps>;
5
+ declare const GradientButton: react173.NamedExoticComponent<GradientButtonProps>;
6
6
  //#endregion
7
7
  export { GradientButton };
8
8
  //# sourceMappingURL=GradientButton.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { GridBackgroundProps } from "./type.mjs";
2
- import * as react145 from "react";
2
+ import * as react167 from "react";
3
3
 
4
4
  //#region src/awesome/GridBackground/GridBackground.d.ts
5
- declare const GridBackground: react145.NamedExoticComponent<GridBackgroundProps>;
5
+ declare const GridBackground: react167.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 react146 from "react";
2
+ import * as react168 from "react";
3
3
 
4
4
  //#region src/awesome/GridBackground/GridShowcase.d.ts
5
- declare const GridShowcase: react146.NamedExoticComponent<GridShowcaseProps>;
5
+ declare const GridShowcase: react168.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 react147 from "react";
2
+ import * as react175 from "react";
3
3
 
4
4
  //#region src/awesome/Hero/Hero.d.ts
5
- declare const Hero: react147.NamedExoticComponent<HeroProps>;
5
+ declare const Hero: react175.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 react148 from "react";
2
+ import * as react170 from "react";
3
3
  import "@splinetool/runtime";
4
4
 
5
5
  //#region src/awesome/Spline/Spine.d.ts
6
- declare const Spline: react148.NamedExoticComponent<SplineProps>;
6
+ declare const Spline: react170.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 react149 from "react";
2
+ import * as react172 from "react";
3
3
 
4
4
  //#region src/awesome/Spotlight/Spotlight.d.ts
5
- declare const Spotlight: react149.NamedExoticComponent<SpotlightProps>;
5
+ declare const Spotlight: react172.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 react150 from "react";
2
+ import * as react174 from "react";
3
3
 
4
4
  //#region src/awesome/SpotlightCard/SpotlightCard.d.ts
5
- declare const SpotlightCard: react150.NamedExoticComponent<SpotlightCardProps<any>>;
5
+ declare const SpotlightCard: react174.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 react139 from "react";
2
+ import * as react169 from "react";
3
3
 
4
4
  //#region src/awesome/TypewriterEffect/TypewriterEffect.d.ts
5
- declare const TypewriterEffect: react139.NamedExoticComponent<TypewriterEffectProps>;
5
+ declare const TypewriterEffect: react169.NamedExoticComponent<TypewriterEffectProps>;
6
6
  //#endregion
7
7
  export { TypewriterEffect };
8
8
  //# sourceMappingURL=TypewriterEffect.d.mts.map
@@ -1,8 +1,8 @@
1
- import * as react162 from "react";
1
+ import * as react198 from "react";
2
2
  import * as react_jsx_runtime72 from "react/jsx-runtime";
3
3
 
4
4
  //#region src/base-ui/ContextMenu/ContextMenuHost.d.ts
5
- declare const ContextMenuHost: react162.MemoExoticComponent<() => react_jsx_runtime72.JSX.Element | null>;
5
+ declare const ContextMenuHost: react198.MemoExoticComponent<() => react_jsx_runtime72.JSX.Element | null>;
6
6
  //#endregion
7
7
  export { ContextMenuHost };
8
8
  //# sourceMappingURL=ContextMenuHost.d.mts.map
@@ -1,8 +1,8 @@
1
1
  import { DropdownMenuProps } from "./type.mjs";
2
- import * as react132 from "react";
2
+ import * as react176 from "react";
3
3
 
4
4
  //#region src/base-ui/DropdownMenu/DropdownMenu.d.ts
5
- declare const DropdownMenu: react132.NamedExoticComponent<DropdownMenuProps<unknown>>;
5
+ declare const DropdownMenu: react176.NamedExoticComponent<DropdownMenuProps<unknown>>;
6
6
  //#endregion
7
7
  export { DropdownMenu };
8
8
  //# sourceMappingURL=DropdownMenu.d.mts.map