@lobehub/ui 1.170.8 → 2.0.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 (956) hide show
  1. package/es/A/index.d.ts +5 -3
  2. package/es/A/index.js +7 -10
  3. package/es/ActionIcon/ActionIcon.d.ts +4 -0
  4. package/es/ActionIcon/ActionIcon.js +158 -0
  5. package/es/ActionIcon/components/utils.d.ts +5 -0
  6. package/es/ActionIcon/components/utils.js +47 -0
  7. package/es/ActionIcon/index.d.ts +2 -66
  8. package/es/ActionIcon/index.js +1 -128
  9. package/es/ActionIcon/style.d.ts +13 -9
  10. package/es/ActionIcon/style.js +17 -14
  11. package/es/ActionIcon/type.d.ts +25 -0
  12. package/es/ActionIconGroup/ActionIconGroup.d.ts +4 -0
  13. package/es/ActionIconGroup/ActionIconGroup.js +135 -0
  14. package/es/ActionIconGroup/index.d.ts +2 -57
  15. package/es/ActionIconGroup/index.js +1 -88
  16. package/es/ActionIconGroup/style.d.ts +8 -4
  17. package/es/ActionIconGroup/style.js +10 -6
  18. package/es/ActionIconGroup/type.d.ts +19 -0
  19. package/es/Alert/Alert.d.ts +4 -0
  20. package/es/Alert/Alert.js +244 -0
  21. package/es/Alert/index.d.ts +2 -18
  22. package/es/Alert/index.js +1 -146
  23. package/es/Alert/style.d.ts +6 -5
  24. package/es/Alert/style.js +15 -13
  25. package/es/Alert/type.d.ts +22 -0
  26. package/es/AutoComplete/Select.d.ts +4 -0
  27. package/es/AutoComplete/Select.js +56 -0
  28. package/es/AutoComplete/index.d.ts +2 -0
  29. package/es/AutoComplete/index.js +1 -0
  30. package/es/AutoComplete/style.d.ts +7 -0
  31. package/es/AutoComplete/style.js +15 -0
  32. package/es/AutoComplete/type.d.ts +4 -0
  33. package/es/AutoComplete/type.js +1 -0
  34. package/es/Avatar/Avatar.d.ts +4 -0
  35. package/es/Avatar/Avatar.js +136 -0
  36. package/es/Avatar/AvatarGroup/index.d.ts +4 -0
  37. package/es/Avatar/AvatarGroup/index.js +92 -0
  38. package/es/Avatar/AvatarGroup/style.d.ts +4 -0
  39. package/es/Avatar/AvatarGroup/style.js +12 -0
  40. package/es/Avatar/index.d.ts +9 -28
  41. package/es/Avatar/index.js +6 -80
  42. package/es/Avatar/style.d.ts +7 -6
  43. package/es/Avatar/style.js +10 -10
  44. package/es/Avatar/type.d.ts +41 -0
  45. package/es/Avatar/type.js +1 -0
  46. package/es/Block/Block.d.ts +4 -0
  47. package/es/Block/Block.js +87 -0
  48. package/es/Block/index.d.ts +2 -0
  49. package/es/Block/index.js +1 -0
  50. package/es/Block/style.d.ts +12 -0
  51. package/es/Block/style.js +20 -0
  52. package/es/Block/type.d.ts +9 -0
  53. package/es/Block/type.js +1 -0
  54. package/es/Burger/Burger.d.ts +4 -0
  55. package/es/Burger/Burger.js +83 -0
  56. package/es/Burger/index.d.ts +2 -39
  57. package/es/Burger/index.js +1 -79
  58. package/es/Burger/type.d.ts +21 -0
  59. package/es/Burger/type.js +1 -0
  60. package/es/Button/Button.d.ts +4 -0
  61. package/es/Button/Button.js +99 -0
  62. package/es/Button/index.d.ts +2 -0
  63. package/es/Button/index.js +1 -0
  64. package/es/Button/style.d.ts +7 -0
  65. package/es/Button/style.js +16 -0
  66. package/es/Button/type.d.ts +10 -0
  67. package/es/Button/type.js +1 -0
  68. package/es/CodeEditor/CodeEditor.d.ts +4 -0
  69. package/es/CodeEditor/CodeEditor.js +114 -0
  70. package/es/CodeEditor/index.d.ts +2 -52
  71. package/es/CodeEditor/index.js +1 -429
  72. package/es/CodeEditor/style.d.ts +5 -6
  73. package/es/CodeEditor/style.js +10 -12
  74. package/es/CodeEditor/type.d.ts +21 -0
  75. package/es/CodeEditor/type.js +1 -0
  76. package/es/Collapse/Collapse.d.ts +4 -0
  77. package/es/Collapse/Collapse.js +152 -0
  78. package/es/Collapse/index.d.ts +2 -14
  79. package/es/Collapse/index.js +2 -61
  80. package/es/Collapse/style.d.ts +11 -11
  81. package/es/Collapse/style.js +19 -22
  82. package/es/Collapse/type.d.ts +29 -0
  83. package/es/Collapse/type.js +1 -0
  84. package/es/ColorSwatches/ColorSwatches.d.ts +4 -0
  85. package/es/ColorSwatches/ColorSwatches.js +129 -0
  86. package/es/ColorSwatches/index.d.ts +2 -22
  87. package/es/ColorSwatches/index.js +2 -140
  88. package/es/ColorSwatches/type.d.ts +23 -0
  89. package/es/ColorSwatches/type.js +1 -0
  90. package/es/ConfigProvider/index.js +3 -19
  91. package/es/CopyButton/CopyButton.d.ts +4 -0
  92. package/es/CopyButton/CopyButton.js +64 -0
  93. package/es/CopyButton/index.d.ts +2 -10
  94. package/es/CopyButton/index.js +2 -67
  95. package/es/CopyButton/type.d.ts +4 -0
  96. package/es/CopyButton/type.js +1 -0
  97. package/es/DatePicker/DatePicker.d.ts +4 -0
  98. package/es/DatePicker/DatePicker.js +56 -0
  99. package/es/DatePicker/index.d.ts +2 -0
  100. package/es/DatePicker/index.js +1 -0
  101. package/es/DatePicker/style.d.ts +7 -0
  102. package/es/DatePicker/style.js +14 -0
  103. package/es/DatePicker/type.d.ts +4 -0
  104. package/es/DatePicker/type.js +1 -0
  105. package/es/DraggablePanel/DraggablePanel.d.ts +4 -0
  106. package/es/DraggablePanel/DraggablePanel.js +340 -0
  107. package/es/DraggablePanel/components/DraggablePanelBody.js +1 -0
  108. package/es/DraggablePanel/components/DraggablePanelContainer.js +1 -0
  109. package/es/DraggablePanel/components/DraggablePanelFooter.js +1 -0
  110. package/es/DraggablePanel/components/DraggablePanelHeader.js +3 -8
  111. package/es/DraggablePanel/components/style.d.ts +1 -0
  112. package/es/DraggablePanel/components/style.js +6 -5
  113. package/es/DraggablePanel/index.d.ts +18 -98
  114. package/es/DraggablePanel/index.js +15 -250
  115. package/es/DraggablePanel/style.d.ts +15 -9
  116. package/es/DraggablePanel/style.js +65 -28
  117. package/es/DraggablePanel/type.d.ts +37 -0
  118. package/es/DraggablePanel/type.js +1 -0
  119. package/es/DraggablePanel/utils.d.ts +2 -2
  120. package/es/Drawer/Drawer.d.ts +4 -0
  121. package/es/Drawer/Drawer.js +176 -0
  122. package/es/Drawer/index.d.ts +2 -26
  123. package/es/Drawer/index.js +1 -174
  124. package/es/Drawer/type.d.ts +25 -0
  125. package/es/Drawer/type.js +1 -0
  126. package/es/Dropdown/Dropdown.d.ts +4 -0
  127. package/es/Dropdown/Dropdown.js +44 -0
  128. package/es/Dropdown/index.d.ts +2 -0
  129. package/es/Dropdown/index.js +1 -0
  130. package/es/Dropdown/type.d.ts +8 -0
  131. package/es/Dropdown/type.js +1 -0
  132. package/es/EditableText/ControlInput.d.ts +16 -0
  133. package/es/{components → EditableText}/ControlInput.js +56 -43
  134. package/es/EditableText/EditableText.d.ts +4 -0
  135. package/es/EditableText/EditableText.js +126 -0
  136. package/es/EditableText/index.d.ts +2 -9
  137. package/es/EditableText/index.js +1 -61
  138. package/es/EditableText/type.d.ts +19 -0
  139. package/es/EditableText/type.js +1 -0
  140. package/es/EmojiPicker/AvatarUploader.js +14 -17
  141. package/es/EmojiPicker/EmojiPicker.d.ts +4 -0
  142. package/es/EmojiPicker/EmojiPicker.js +212 -0
  143. package/es/EmojiPicker/index.d.ts +2 -47
  144. package/es/EmojiPicker/index.js +1 -264
  145. package/es/EmojiPicker/style.d.ts +1 -2
  146. package/es/EmojiPicker/style.js +5 -6
  147. package/es/EmojiPicker/type.d.ts +44 -0
  148. package/es/EmojiPicker/type.js +1 -0
  149. package/es/FileTypeIcon/FileTypeIcon.d.ts +4 -0
  150. package/es/FileTypeIcon/FileTypeIcon.js +84 -0
  151. package/es/FileTypeIcon/components/FileIcon.d.ts +12 -0
  152. package/es/{Swatches/index.js → FileTypeIcon/components/FileIcon.js} +40 -50
  153. package/es/FileTypeIcon/components/FolderIcon.d.ts +12 -0
  154. package/es/FileTypeIcon/components/FolderIcon.js +52 -0
  155. package/es/FileTypeIcon/index.d.ts +2 -13
  156. package/es/FileTypeIcon/index.js +1 -123
  157. package/es/{mobile/MobileNavBar → FileTypeIcon}/style.d.ts +1 -3
  158. package/es/FileTypeIcon/style.js +11 -0
  159. package/es/FileTypeIcon/type.d.ts +13 -0
  160. package/es/FileTypeIcon/type.js +1 -0
  161. package/es/FluentEmoji/FluentEmoji.d.ts +4 -0
  162. package/es/FluentEmoji/FluentEmoji.js +78 -0
  163. package/es/FluentEmoji/index.d.ts +2 -22
  164. package/es/FluentEmoji/index.js +1 -68
  165. package/es/FluentEmoji/type.d.ts +10 -0
  166. package/es/FluentEmoji/type.js +1 -0
  167. package/es/FluentEmoji/utils.d.ts +1 -1
  168. package/es/FluentEmoji/utils.js +1 -1
  169. package/es/FontLoader/index.d.ts +0 -3
  170. package/es/FontLoader/index.js +19 -4
  171. package/es/Footer/Footer.d.ts +4 -0
  172. package/es/Footer/Footer.js +46 -0
  173. package/es/Footer/index.d.ts +2 -24
  174. package/es/Footer/index.js +1 -29
  175. package/es/Footer/style.d.ts +1 -1
  176. package/es/Footer/style.js +2 -2
  177. package/es/Footer/type.d.ts +9 -0
  178. package/es/Footer/type.js +1 -0
  179. package/es/Form/Form.d.ts +4 -0
  180. package/es/Form/Form.js +184 -0
  181. package/es/Form/components/FormDivider.d.ts +3 -4
  182. package/es/Form/components/FormDivider.js +23 -7
  183. package/es/Form/components/FormFlatGroup.d.ts +1 -5
  184. package/es/Form/components/FormFlatGroup.js +26 -13
  185. package/es/Form/components/FormFooter.d.ts +1 -3
  186. package/es/Form/components/FormFooter.js +7 -16
  187. package/es/Form/components/FormGroup.d.ts +2 -42
  188. package/es/Form/components/FormGroup.js +56 -54
  189. package/es/Form/components/FormItem.d.ts +1 -20
  190. package/es/Form/components/FormItem.js +47 -34
  191. package/es/Form/components/FormProvider.js +5 -3
  192. package/es/Form/components/FormSubmitFooter.d.ts +2 -19
  193. package/es/Form/components/FormSubmitFooter.js +35 -39
  194. package/es/Form/components/FormTitle.d.ts +2 -11
  195. package/es/Form/components/FormTitle.js +43 -40
  196. package/es/Form/components/merge.d.ts +19 -0
  197. package/es/Form/components/merge.js +112 -0
  198. package/es/Form/index.d.ts +12 -18
  199. package/es/Form/index.js +8 -142
  200. package/es/Form/style.d.ts +35 -2
  201. package/es/Form/style.js +67 -4
  202. package/es/Form/type.d.ts +110 -0
  203. package/es/Form/type.js +1 -0
  204. package/es/FormModal/FormModal.d.ts +4 -0
  205. package/es/FormModal/FormModal.js +143 -0
  206. package/es/FormModal/index.d.ts +2 -19
  207. package/es/FormModal/index.js +1 -138
  208. package/es/FormModal/type.d.ts +20 -0
  209. package/es/FormModal/type.js +1 -0
  210. package/es/Grid/Grid.d.ts +4 -0
  211. package/es/Grid/Grid.js +43 -0
  212. package/es/Grid/index.d.ts +2 -16
  213. package/es/Grid/index.js +1 -53
  214. package/es/Grid/style.d.ts +5 -0
  215. package/es/Grid/style.js +11 -0
  216. package/es/Grid/type.d.ts +8 -0
  217. package/es/Grid/type.js +1 -0
  218. package/es/GuideCard/GuideCard.d.ts +4 -0
  219. package/es/GuideCard/GuideCard.js +116 -0
  220. package/es/GuideCard/index.d.ts +2 -0
  221. package/es/GuideCard/index.js +1 -0
  222. package/es/{EmptyCard → GuideCard}/style.d.ts +7 -2
  223. package/es/GuideCard/style.js +22 -0
  224. package/es/GuideCard/type.d.ts +31 -0
  225. package/es/GuideCard/type.js +1 -0
  226. package/es/Header/Header.d.ts +4 -0
  227. package/es/Header/Header.js +102 -0
  228. package/es/Header/index.d.ts +2 -42
  229. package/es/Header/index.js +1 -100
  230. package/es/Header/style.d.ts +1 -2
  231. package/es/Header/style.js +5 -7
  232. package/es/Header/type.d.ts +14 -0
  233. package/es/Header/type.js +1 -0
  234. package/es/Highlighter/FullFeatured.d.ts +5 -3
  235. package/es/Highlighter/FullFeatured.js +90 -47
  236. package/es/Highlighter/Highlighter.d.ts +4 -0
  237. package/es/Highlighter/Highlighter.js +130 -0
  238. package/es/Highlighter/SyntaxHighlighter/index.d.ts +1 -6
  239. package/es/Highlighter/SyntaxHighlighter/index.js +61 -31
  240. package/es/Highlighter/SyntaxHighlighter/style.d.ts +4 -1
  241. package/es/Highlighter/SyntaxHighlighter/style.js +8 -7
  242. package/es/Highlighter/const.d.ts +7 -0
  243. package/es/Highlighter/const.js +17 -0
  244. package/es/Highlighter/index.d.ts +4 -6
  245. package/es/Highlighter/index.js +2 -99
  246. package/es/Highlighter/style.d.ts +15 -5
  247. package/es/Highlighter/style.js +22 -12
  248. package/es/Highlighter/type.d.ts +18 -34
  249. package/es/Hotkey/Hotkey.d.ts +4 -0
  250. package/es/Hotkey/Hotkey.js +197 -0
  251. package/es/Hotkey/const.d.ts +34 -0
  252. package/es/Hotkey/const.js +49 -0
  253. package/es/Hotkey/index.d.ts +3 -20
  254. package/es/Hotkey/index.js +2 -165
  255. package/es/Hotkey/style.d.ts +7 -1
  256. package/es/Hotkey/style.js +14 -5
  257. package/es/Hotkey/type.d.ts +15 -34
  258. package/es/Hotkey/type.js +1 -49
  259. package/es/Hotkey/utils.js +1 -1
  260. package/es/HotkeyInput/HotkeyInput.d.ts +4 -0
  261. package/es/HotkeyInput/HotkeyInput.js +322 -0
  262. package/es/HotkeyInput/index.d.ts +2 -27
  263. package/es/HotkeyInput/index.js +2 -282
  264. package/es/HotkeyInput/style.d.ts +9 -7
  265. package/es/HotkeyInput/style.js +15 -14
  266. package/es/HotkeyInput/type.d.ts +26 -0
  267. package/es/HotkeyInput/type.js +1 -0
  268. package/es/Icon/Icon.d.ts +4 -0
  269. package/es/Icon/Icon.js +86 -0
  270. package/es/Icon/components/IconProvider.d.ts +9 -0
  271. package/es/Icon/components/IconProvider.js +17 -0
  272. package/es/Icon/components/utils.d.ts +8 -0
  273. package/es/Icon/components/utils.js +45 -0
  274. package/es/Icon/index.d.ts +3 -28
  275. package/es/Icon/index.js +2 -55
  276. package/es/Icon/type.d.ts +15 -0
  277. package/es/Icon/type.js +1 -0
  278. package/es/Image/Image.d.ts +4 -0
  279. package/es/Image/Image.js +122 -0
  280. package/es/Image/PreviewGroup.d.ts +4 -0
  281. package/es/Image/{ImageGallery.js → PreviewGroup.js} +7 -6
  282. package/es/Image/{Preview.d.ts → components/Preview.d.ts} +1 -1
  283. package/es/Image/components/Toolbar.d.ts +10 -0
  284. package/es/Image/components/Toolbar.js +56 -0
  285. package/es/Image/components/usePreview.d.ts +4 -0
  286. package/es/Image/components/usePreview.js +84 -0
  287. package/es/Image/components/usePreviewGroup.d.ts +4 -0
  288. package/es/Image/components/usePreviewGroup.js +84 -0
  289. package/es/Image/index.d.ts +9 -19
  290. package/es/Image/index.js +6 -95
  291. package/es/Image/style.d.ts +10 -4
  292. package/es/Image/style.js +21 -12
  293. package/es/Image/type.d.ts +38 -0
  294. package/es/Image/type.js +1 -0
  295. package/es/ImageSelect/ImageSelect.d.ts +4 -0
  296. package/es/{SelectWithImg/index.js → ImageSelect/ImageSelect.js} +25 -24
  297. package/es/ImageSelect/index.d.ts +2 -0
  298. package/es/ImageSelect/index.js +2 -0
  299. package/es/{SelectWithImg → ImageSelect}/styles.d.ts +1 -2
  300. package/es/ImageSelect/styles.js +15 -0
  301. package/es/{SelectWithImg/index.d.ts → ImageSelect/type.d.ts} +9 -9
  302. package/es/ImageSelect/type.js +1 -0
  303. package/es/Img/index.d.ts +6 -5
  304. package/es/Img/index.js +11 -13
  305. package/es/Input/Input.d.ts +4 -0
  306. package/es/Input/Input.js +58 -0
  307. package/es/Input/InputNumber.d.ts +4 -0
  308. package/es/Input/InputNumber.js +58 -0
  309. package/es/Input/InputOPT.d.ts +4 -0
  310. package/es/Input/InputOPT.js +58 -0
  311. package/es/Input/InputPassword.d.ts +4 -0
  312. package/es/Input/InputPassword.js +58 -0
  313. package/es/Input/TextArea.d.ts +4 -0
  314. package/es/Input/TextArea.js +64 -0
  315. package/es/Input/index.d.ts +6 -24
  316. package/es/Input/index.js +5 -54
  317. package/es/Input/style.d.ts +11 -5
  318. package/es/Input/style.js +14 -7
  319. package/es/Input/type.d.ts +26 -0
  320. package/es/Input/type.js +1 -0
  321. package/es/Layout/Layout.d.ts +4 -0
  322. package/es/Layout/Layout.js +80 -0
  323. package/es/Layout/components/LayoutFooter.d.ts +3 -0
  324. package/es/Layout/components/LayoutFooter.js +29 -0
  325. package/es/Layout/components/LayoutHeader.d.ts +4 -0
  326. package/es/Layout/components/LayoutHeader.js +34 -0
  327. package/es/Layout/components/LayoutMain.d.ts +3 -0
  328. package/es/{TabsNav/index.js → Layout/components/LayoutMain.js} +14 -12
  329. package/es/Layout/components/LayoutSidebar.d.ts +4 -0
  330. package/es/Layout/components/LayoutSidebar.js +34 -0
  331. package/es/Layout/components/LayoutSidebarInner.d.ts +4 -0
  332. package/es/Layout/components/LayoutSidebarInner.js +30 -0
  333. package/es/Layout/components/LayoutToc.d.ts +4 -0
  334. package/es/Layout/components/LayoutToc.js +34 -0
  335. package/es/Layout/index.d.ts +24 -65
  336. package/es/Layout/index.js +21 -184
  337. package/es/Layout/style.d.ts +1 -2
  338. package/es/Layout/style.js +12 -14
  339. package/es/Layout/type.d.ts +28 -0
  340. package/es/Layout/type.js +1 -0
  341. package/es/List/List.d.ts +4 -0
  342. package/es/List/List.js +63 -0
  343. package/es/List/ListItem/index.d.ts +3 -20
  344. package/es/List/ListItem/index.js +51 -39
  345. package/es/List/ListItem/style.d.ts +3 -3
  346. package/es/List/ListItem/style.js +14 -11
  347. package/es/List/index.d.ts +10 -5
  348. package/es/List/index.js +5 -6
  349. package/es/List/type.d.ts +50 -0
  350. package/es/List/type.js +1 -0
  351. package/es/Markdown/Markdown.d.ts +4 -0
  352. package/es/Markdown/Markdown.js +202 -0
  353. package/es/Markdown/Typography.d.ts +3 -9
  354. package/es/Markdown/Typography.js +9 -5
  355. package/es/Markdown/index.d.ts +3 -44
  356. package/es/Markdown/index.js +2 -234
  357. package/es/Markdown/markdown.style.d.ts +4 -1
  358. package/es/Markdown/markdown.style.js +5 -2
  359. package/es/Markdown/type.d.ts +49 -0
  360. package/es/Markdown/type.js +1 -0
  361. package/es/Markdown/utils.d.ts +15 -0
  362. package/es/Markdown/utils.js +55 -0
  363. package/es/MaskShadow/MaskShadow.d.ts +4 -0
  364. package/es/MaskShadow/MaskShadow.js +54 -0
  365. package/es/MaskShadow/index.d.ts +2 -0
  366. package/es/MaskShadow/index.js +1 -0
  367. package/es/MaskShadow/style.d.ts +7 -0
  368. package/es/MaskShadow/style.js +14 -0
  369. package/es/MaskShadow/type.d.ts +6 -0
  370. package/es/MaskShadow/type.js +1 -0
  371. package/es/MaterialFileTypeIcon/MaterialFileTypeIcon.d.ts +4 -0
  372. package/es/MaterialFileTypeIcon/MaterialFileTypeIcon.js +86 -0
  373. package/es/MaterialFileTypeIcon/icon-map.json +1 -3713
  374. package/es/MaterialFileTypeIcon/index.d.ts +2 -12
  375. package/es/MaterialFileTypeIcon/index.js +1 -85
  376. package/es/MaterialFileTypeIcon/type.d.ts +13 -0
  377. package/es/MaterialFileTypeIcon/type.js +1 -0
  378. package/es/MaterialFileTypeIcon/utils.d.ts +5 -6
  379. package/es/Menu/Menu.d.ts +4 -0
  380. package/es/Menu/Menu.js +102 -0
  381. package/es/Menu/index.d.ts +3 -0
  382. package/es/Menu/index.js +2 -0
  383. package/es/{TabsNav → Menu}/style.d.ts +5 -1
  384. package/es/Menu/style.js +18 -0
  385. package/es/Menu/type.d.ts +32 -0
  386. package/es/Menu/type.js +1 -0
  387. package/es/Menu/utils.d.ts +3 -0
  388. package/es/Menu/utils.js +47 -0
  389. package/es/Mermaid/FullFeatured.js +80 -29
  390. package/es/Mermaid/Mermaid.d.ts +5 -0
  391. package/es/Mermaid/Mermaid.js +130 -0
  392. package/es/Mermaid/SyntaxMermaid/index.d.ts +4 -0
  393. package/es/Mermaid/SyntaxMermaid/index.js +87 -0
  394. package/es/Mermaid/const.d.ts +7 -0
  395. package/es/Mermaid/const.js +24 -0
  396. package/es/Mermaid/index.d.ts +4 -5
  397. package/es/Mermaid/index.js +3 -96
  398. package/es/Mermaid/type.d.ts +16 -5
  399. package/es/Modal/Modal.d.ts +4 -0
  400. package/es/Modal/Modal.js +173 -0
  401. package/es/Modal/index.d.ts +2 -13
  402. package/es/Modal/index.js +1 -168
  403. package/es/Modal/style.d.ts +2 -4
  404. package/es/Modal/style.js +6 -8
  405. package/es/Modal/type.d.ts +9 -0
  406. package/es/Modal/type.js +1 -0
  407. package/es/ScrollShadow/ScrollShadow.d.ts +4 -0
  408. package/es/ScrollShadow/ScrollShadow.js +153 -0
  409. package/es/ScrollShadow/index.d.ts +2 -0
  410. package/es/ScrollShadow/index.js +1 -0
  411. package/es/ScrollShadow/style.d.ts +12 -0
  412. package/es/ScrollShadow/style.js +21 -0
  413. package/es/ScrollShadow/type.d.ts +15 -0
  414. package/es/ScrollShadow/type.js +1 -0
  415. package/es/ScrollShadow/useScrollOverflow.d.ts +21 -0
  416. package/es/ScrollShadow/useScrollOverflow.js +83 -0
  417. package/es/SearchBar/SearchBar.d.ts +4 -0
  418. package/es/SearchBar/SearchBar.js +126 -0
  419. package/es/{SearchResultCard → SearchBar/components/SearchResultCard}/index.d.ts +1 -5
  420. package/es/{EmptyCard → SearchBar/components/SearchResultCard}/index.js +54 -52
  421. package/es/SearchBar/components/SearchResultCard/style.d.ts +5 -0
  422. package/es/SearchBar/components/SearchResultCard/style.js +12 -0
  423. package/es/SearchBar/components/SearchResultCards/index.d.ts +4 -0
  424. package/es/SearchBar/components/SearchResultCards/index.js +39 -0
  425. package/es/SearchBar/index.d.ts +3 -34
  426. package/es/SearchBar/index.js +2 -132
  427. package/es/SearchBar/style.d.ts +0 -1
  428. package/es/SearchBar/style.js +3 -4
  429. package/es/SearchBar/type.d.ts +38 -0
  430. package/es/SearchBar/type.js +1 -0
  431. package/es/Segmented/Segmented.d.ts +4 -0
  432. package/es/Segmented/Segmented.js +69 -0
  433. package/es/Segmented/index.d.ts +2 -0
  434. package/es/Segmented/index.js +1 -0
  435. package/es/Segmented/style.d.ts +8 -0
  436. package/es/Segmented/style.js +16 -0
  437. package/es/Segmented/type.d.ts +11 -0
  438. package/es/Segmented/type.js +1 -0
  439. package/es/Select/Select.d.ts +4 -0
  440. package/es/Select/Select.js +70 -0
  441. package/es/Select/index.d.ts +2 -0
  442. package/es/Select/index.js +1 -0
  443. package/es/Select/style.d.ts +7 -0
  444. package/es/Select/style.js +16 -0
  445. package/es/Select/type.d.ts +9 -0
  446. package/es/Select/type.js +1 -0
  447. package/es/SideNav/SideNav.d.ts +4 -0
  448. package/es/SideNav/SideNav.js +51 -0
  449. package/es/SideNav/index.d.ts +2 -18
  450. package/es/SideNav/index.js +1 -50
  451. package/es/SideNav/style.js +1 -1
  452. package/es/SideNav/type.d.ts +7 -0
  453. package/es/SideNav/type.js +1 -0
  454. package/es/SliderWithInput/SliderWithInput.d.ts +4 -0
  455. package/es/SliderWithInput/SliderWithInput.js +95 -0
  456. package/es/SliderWithInput/index.d.ts +2 -11
  457. package/es/SliderWithInput/index.js +1 -77
  458. package/es/SliderWithInput/type.d.ts +18 -0
  459. package/es/SliderWithInput/type.js +1 -0
  460. package/es/Snippet/Snippet.d.ts +4 -0
  461. package/es/Snippet/Snippet.js +82 -0
  462. package/es/Snippet/index.d.ts +2 -34
  463. package/es/Snippet/index.js +1 -54
  464. package/es/Snippet/style.d.ts +7 -2
  465. package/es/Snippet/style.js +8 -5
  466. package/es/Snippet/type.d.ts +12 -0
  467. package/es/Snippet/type.js +1 -0
  468. package/es/SortableList/SortableList.d.ts +11 -0
  469. package/es/{Image/usePreview.js → SortableList/SortableList.js} +76 -86
  470. package/es/SortableList/components/DragHandle.d.ts +4 -0
  471. package/es/SortableList/{DragHandle.js → components/DragHandle.js} +9 -6
  472. package/es/SortableList/{SortableItem.d.ts → components/SortableItem.d.ts} +1 -0
  473. package/es/SortableList/{SortableItem.js → components/SortableItem.js} +39 -5
  474. package/es/SortableList/{SortableOverlay.js → components/SortableOverlay.js} +3 -0
  475. package/es/SortableList/index.d.ts +2 -20
  476. package/es/SortableList/index.js +1 -98
  477. package/es/SortableList/style.d.ts +4 -0
  478. package/es/SortableList/style.js +9 -3
  479. package/es/SortableList/type.d.ts +12 -0
  480. package/es/SortableList/type.js +1 -0
  481. package/es/Tabs/Tabs.d.ts +4 -0
  482. package/es/Tabs/Tabs.js +74 -0
  483. package/es/Tabs/index.d.ts +2 -0
  484. package/es/Tabs/index.js +1 -0
  485. package/es/Tabs/style.d.ts +9 -0
  486. package/es/Tabs/style.js +17 -0
  487. package/es/Tabs/type.d.ts +5 -0
  488. package/es/Tabs/type.js +1 -0
  489. package/es/Tag/Tag.d.ts +4 -0
  490. package/es/Tag/Tag.js +104 -0
  491. package/es/Tag/index.d.ts +2 -8
  492. package/es/Tag/index.js +1 -50
  493. package/es/Tag/styles.d.ts +8 -0
  494. package/es/Tag/styles.js +17 -0
  495. package/es/Tag/type.d.ts +8 -0
  496. package/es/Tag/type.js +1 -0
  497. package/es/Tag/utils.d.ts +4 -0
  498. package/es/Tag/utils.js +15 -0
  499. package/es/ThemeProvider/GlobalStyle/antdOverride.js +1 -1
  500. package/es/ThemeProvider/Meta.d.ts +1 -5
  501. package/es/ThemeProvider/ThemeProvider.d.ts +4 -0
  502. package/es/ThemeProvider/ThemeProvider.js +91 -0
  503. package/es/ThemeProvider/index.d.ts +3 -28
  504. package/es/ThemeProvider/index.js +2 -91
  505. package/es/ThemeProvider/type.d.ts +25 -0
  506. package/es/ThemeProvider/type.js +1 -0
  507. package/es/ThemeSwitch/ThemeSwitch.d.ts +4 -0
  508. package/es/ThemeSwitch/ThemeSwitch.js +85 -0
  509. package/es/ThemeSwitch/index.d.ts +2 -33
  510. package/es/ThemeSwitch/index.js +1 -91
  511. package/es/ThemeSwitch/type.d.ts +15 -0
  512. package/es/ThemeSwitch/type.js +1 -0
  513. package/es/Toc/Toc.d.ts +4 -0
  514. package/es/Toc/Toc.js +43 -0
  515. package/es/Toc/TocMobile.d.ts +1 -54
  516. package/es/Toc/TocMobile.js +12 -35
  517. package/es/Toc/index.d.ts +2 -11
  518. package/es/Toc/index.js +1 -41
  519. package/es/Toc/style.js +1 -1
  520. package/es/Toc/type.d.ts +17 -0
  521. package/es/Toc/type.js +1 -0
  522. package/es/Toc/utils.d.ts +11 -0
  523. package/es/Toc/utils.js +17 -0
  524. package/es/Tooltip/Tooltip.d.ts +4 -0
  525. package/es/Tooltip/Tooltip.js +52 -0
  526. package/es/Tooltip/index.d.ts +2 -10
  527. package/es/Tooltip/index.js +1 -49
  528. package/es/Tooltip/type.d.ts +10 -0
  529. package/es/Tooltip/type.js +1 -0
  530. package/es/Video/index.d.ts +24 -9
  531. package/es/Video/index.js +82 -45
  532. package/es/Video/style.d.ts +9 -5
  533. package/es/Video/style.js +18 -11
  534. package/es/awesome/AuroraBackground/AuroraBackground.d.ts +4 -0
  535. package/es/awesome/{GaussianBackground/index.js → AuroraBackground/AuroraBackground.js} +22 -29
  536. package/es/awesome/AuroraBackground/index.d.ts +2 -4
  537. package/es/awesome/AuroraBackground/index.js +1 -38
  538. package/es/awesome/AuroraBackground/style.js +2 -2
  539. package/es/awesome/AuroraBackground/type.d.ts +13 -0
  540. package/es/awesome/AuroraBackground/type.js +1 -0
  541. package/es/awesome/BottomGradientButton/BottomGradientButton.d.ts +3 -0
  542. package/es/awesome/BottomGradientButton/BottomGradientButton.js +39 -0
  543. package/es/awesome/BottomGradientButton/index.d.ts +2 -0
  544. package/es/awesome/BottomGradientButton/index.js +1 -0
  545. package/es/awesome/BottomGradientButton/style.d.ts +1 -0
  546. package/es/awesome/BottomGradientButton/style.js +10 -0
  547. package/es/awesome/BottomGradientButton/type.d.ts +2 -0
  548. package/es/awesome/BottomGradientButton/type.js +1 -0
  549. package/es/awesome/Features/FeatureItem.d.ts +4 -0
  550. package/es/awesome/Features/{Item.js → FeatureItem.js} +9 -6
  551. package/es/awesome/Features/Features.d.ts +4 -0
  552. package/es/awesome/Features/Features.js +41 -0
  553. package/es/awesome/Features/index.d.ts +2 -24
  554. package/es/awesome/Features/index.js +1 -40
  555. package/es/awesome/Features/type.d.ts +27 -0
  556. package/es/awesome/Features/type.js +1 -0
  557. package/es/awesome/Giscus/Giscus.d.ts +4 -0
  558. package/es/awesome/Giscus/Giscus.js +51 -0
  559. package/es/awesome/Giscus/index.d.ts +2 -8
  560. package/es/awesome/Giscus/index.js +1 -50
  561. package/es/awesome/Giscus/type.d.ts +6 -0
  562. package/es/awesome/Giscus/type.js +1 -0
  563. package/es/awesome/GradientButton/GradientButton.d.ts +4 -0
  564. package/es/awesome/GradientButton/GradientButton.js +40 -0
  565. package/es/awesome/GradientButton/index.d.ts +2 -7
  566. package/es/awesome/GradientButton/index.js +1 -37
  567. package/es/awesome/GradientButton/style.d.ts +2 -2
  568. package/es/awesome/GradientButton/style.js +5 -4
  569. package/es/awesome/GradientButton/type.d.ts +4 -0
  570. package/es/awesome/GradientButton/type.js +1 -0
  571. package/es/awesome/GridBackground/GridBackground.d.ts +4 -0
  572. package/es/awesome/GridBackground/GridBackground.js +108 -0
  573. package/es/awesome/GridBackground/GridShowcase.d.ts +1 -6
  574. package/es/awesome/GridBackground/GridShowcase.js +2 -1
  575. package/es/awesome/GridBackground/{Grid.d.ts → components/Grid.d.ts} +2 -2
  576. package/es/awesome/GridBackground/{Grid.js → components/Grid.js} +14 -14
  577. package/es/awesome/GridBackground/index.d.ts +3 -16
  578. package/es/awesome/GridBackground/index.js +2 -107
  579. package/es/awesome/GridBackground/type.d.ts +18 -0
  580. package/es/awesome/GridBackground/type.js +1 -0
  581. package/es/awesome/Hero/Hero.d.ts +4 -0
  582. package/es/awesome/Hero/Hero.js +100 -0
  583. package/es/awesome/Hero/index.d.ts +2 -43
  584. package/es/awesome/Hero/index.js +1 -103
  585. package/es/awesome/Hero/type.d.ts +14 -0
  586. package/es/awesome/Hero/type.js +1 -0
  587. package/es/awesome/Spline/ParentSize.d.ts +6 -5
  588. package/es/awesome/Spline/ParentSize.js +7 -5
  589. package/es/awesome/Spline/Spine.d.ts +6 -0
  590. package/es/awesome/Spline/Spine.js +148 -0
  591. package/es/awesome/Spline/index.d.ts +2 -20
  592. package/es/awesome/Spline/index.js +1 -146
  593. package/es/awesome/Spline/type.d.ts +17 -0
  594. package/es/awesome/Spline/type.js +1 -0
  595. package/es/awesome/Spotlight/Spotlight.d.ts +4 -0
  596. package/es/awesome/Spotlight/Spotlight.js +45 -0
  597. package/es/awesome/Spotlight/index.d.ts +2 -11
  598. package/es/awesome/Spotlight/index.js +1 -79
  599. package/es/awesome/Spotlight/type.d.ts +4 -0
  600. package/es/awesome/Spotlight/type.js +1 -0
  601. package/es/awesome/Spotlight/useMouseOffset.d.ts +1 -0
  602. package/es/awesome/{GaussianBackground/useGaussianBackground.js → Spotlight/useMouseOffset.js} +32 -13
  603. package/es/awesome/SpotlightCard/SpotlightCard.d.ts +4 -0
  604. package/es/awesome/SpotlightCard/SpotlightCard.js +90 -0
  605. package/es/awesome/SpotlightCard/SpotlightCardItem.d.ts +1 -5
  606. package/es/awesome/SpotlightCard/SpotlightCardItem.js +3 -0
  607. package/es/awesome/SpotlightCard/index.d.ts +2 -14
  608. package/es/awesome/SpotlightCard/index.js +1 -89
  609. package/es/awesome/SpotlightCard/type.d.ts +16 -0
  610. package/es/awesome/SpotlightCard/type.js +1 -0
  611. package/es/awesome/index.d.ts +4 -5
  612. package/es/awesome/index.js +2 -3
  613. package/es/brand/BrandLoading/index.js +1 -0
  614. package/es/brand/LobeChat/index.d.ts +0 -11
  615. package/es/brand/LobeChat/index.js +1 -0
  616. package/es/brand/LobeChatText/index.js +1 -0
  617. package/es/brand/LobeHub/index.d.ts +0 -11
  618. package/es/brand/LobeHub/index.js +1 -0
  619. package/es/brand/LobeHubText/index.js +1 -0
  620. package/es/brand/Logo3d/index.js +3 -0
  621. package/es/brand/LogoFlat/index.d.ts +3 -3
  622. package/es/brand/LogoFlat/index.js +5 -5
  623. package/es/brand/LogoMono/index.d.ts +3 -3
  624. package/es/brand/LogoMono/index.js +5 -5
  625. package/es/brand/LogoThree/Loading.js +1 -3
  626. package/es/brand/LogoThree/index.js +1 -0
  627. package/es/chat/BackBottom/BackBottom.d.ts +4 -0
  628. package/es/chat/BackBottom/BackBottom.js +63 -0
  629. package/es/chat/BackBottom/index.d.ts +2 -13
  630. package/es/chat/BackBottom/index.js +1 -62
  631. package/es/chat/BackBottom/style.d.ts +1 -1
  632. package/es/chat/BackBottom/style.js +2 -6
  633. package/es/chat/BackBottom/type.d.ts +11 -0
  634. package/es/chat/BackBottom/type.js +1 -0
  635. package/es/chat/Bubble/Bubble.d.ts +4 -0
  636. package/es/chat/Bubble/Bubble.js +60 -0
  637. package/es/chat/Bubble/index.d.ts +2 -0
  638. package/es/chat/Bubble/index.js +1 -0
  639. package/es/chat/Bubble/style.d.ts +7 -0
  640. package/es/chat/Bubble/style.js +16 -0
  641. package/es/chat/Bubble/type.d.ts +7 -0
  642. package/es/chat/Bubble/type.js +1 -0
  643. package/es/chat/ChatHeader/ChatHeader.d.ts +4 -0
  644. package/es/chat/ChatHeader/ChatHeader.js +79 -0
  645. package/es/chat/ChatHeader/ChatHeaderTitle.d.ts +2 -6
  646. package/es/chat/ChatHeader/ChatHeaderTitle.js +5 -19
  647. package/es/chat/ChatHeader/index.d.ts +9 -23
  648. package/es/chat/ChatHeader/index.js +6 -81
  649. package/es/chat/ChatHeader/style.d.ts +9 -1
  650. package/es/chat/ChatHeader/style.js +16 -7
  651. package/es/{mobile/MobileNavBar/index.d.ts → chat/ChatHeader/type.d.ts} +13 -13
  652. package/es/chat/ChatHeader/type.js +1 -0
  653. package/es/chat/ChatInputArea/ChatInputArea.d.ts +4 -20
  654. package/es/chat/ChatInputArea/ChatInputArea.js +20 -30
  655. package/es/chat/ChatInputArea/components/ChatInputActionBar.d.ts +4 -0
  656. package/es/chat/ChatInputArea/components/ChatInputActionBar.js +57 -0
  657. package/es/chat/ChatInputArea/components/ChatInputAreaInner.d.ts +4 -0
  658. package/es/chat/ChatInputArea/{ChatInputAreaInner.js → components/ChatInputAreaInner.js} +9 -7
  659. package/es/chat/ChatInputArea/components/ChatSendButton.d.ts +4 -0
  660. package/es/chat/ChatInputArea/components/ChatSendButton.js +83 -0
  661. package/es/chat/ChatInputArea/index.d.ts +17 -4
  662. package/es/chat/ChatInputArea/index.js +12 -4
  663. package/es/chat/ChatInputArea/style.d.ts +10 -0
  664. package/es/chat/ChatInputArea/style.js +21 -0
  665. package/es/chat/ChatInputArea/type.d.ts +50 -0
  666. package/es/chat/ChatInputArea/type.js +1 -0
  667. package/es/chat/ChatItem/ChatItem.d.ts +5 -0
  668. package/es/chat/ChatItem/ChatItem.js +183 -0
  669. package/es/chat/ChatItem/components/Actions.d.ts +2 -2
  670. package/es/chat/ChatItem/components/Actions.js +2 -2
  671. package/es/chat/ChatItem/components/Avatar.d.ts +2 -1
  672. package/es/chat/ChatItem/components/Avatar.js +2 -0
  673. package/es/chat/ChatItem/components/Loading.js +1 -1
  674. package/es/chat/ChatItem/components/MessageContent.d.ts +1 -1
  675. package/es/chat/ChatItem/components/MessageContent.js +2 -2
  676. package/es/chat/ChatItem/index.d.ts +2 -5
  677. package/es/chat/ChatItem/index.js +1 -180
  678. package/es/chat/ChatItem/style.d.ts +1 -1
  679. package/es/chat/ChatItem/style.js +9 -9
  680. package/es/chat/ChatItem/type.d.ts +5 -4
  681. package/es/chat/ChatList/ChatList.d.ts +4 -0
  682. package/es/chat/ChatList/ChatList.js +70 -0
  683. package/es/chat/ChatList/components/ChatActionsBar.d.ts +4 -0
  684. package/es/chat/ChatList/{ActionsBar.js → components/ChatActionsBar.js} +10 -7
  685. package/es/chat/ChatList/components/ChatListItem.d.ts +4 -0
  686. package/es/chat/ChatList/{Item.js → components/ChatListItem.js} +11 -10
  687. package/es/chat/ChatList/{HistoryDivider.js → components/HistoryDivider.js} +2 -2
  688. package/es/{hooks → chat/ChatList/components}/useChatListActionsBar.d.ts +5 -5
  689. package/es/chat/ChatList/index.d.ts +3 -15
  690. package/es/chat/ChatList/index.js +2 -70
  691. package/es/chat/ChatList/{Item.d.ts → type.d.ts} +22 -11
  692. package/es/chat/ChatList/type.js +1 -0
  693. package/es/chat/EditableMessage/EditableMessage.d.ts +4 -0
  694. package/es/chat/EditableMessage/EditableMessage.js +113 -0
  695. package/es/chat/EditableMessage/index.d.ts +2 -78
  696. package/es/chat/EditableMessage/index.js +1 -111
  697. package/es/chat/EditableMessage/type.d.ts +36 -0
  698. package/es/chat/EditableMessage/type.js +1 -0
  699. package/es/chat/EditableMessageList/EditableMessageList.d.ts +4 -0
  700. package/es/chat/EditableMessageList/EditableMessageList.js +109 -0
  701. package/es/chat/EditableMessageList/index.d.ts +2 -20
  702. package/es/chat/EditableMessageList/index.js +1 -113
  703. package/es/chat/EditableMessageList/messageReducer.d.ts +1 -2
  704. package/es/chat/EditableMessageList/type.d.ts +6 -0
  705. package/es/chat/EditableMessageList/type.js +1 -0
  706. package/es/chat/MessageInput/MessageInput.d.ts +4 -0
  707. package/es/chat/MessageInput/MessageInput.js +123 -0
  708. package/es/chat/MessageInput/index.d.ts +2 -45
  709. package/es/chat/MessageInput/index.js +1 -131
  710. package/es/chat/MessageInput/type.d.ts +24 -0
  711. package/es/chat/MessageInput/type.js +1 -0
  712. package/es/chat/MessageModal/MessageModal.d.ts +4 -0
  713. package/es/chat/MessageModal/MessageModal.js +110 -0
  714. package/es/chat/MessageModal/TextArea.d.ts +1 -1
  715. package/es/chat/MessageModal/index.d.ts +2 -41
  716. package/es/chat/MessageModal/index.js +1 -129
  717. package/es/chat/MessageModal/type.d.ts +22 -0
  718. package/es/chat/MessageModal/type.js +1 -0
  719. package/es/chat/TokenTag/TokenTag.d.ts +4 -0
  720. package/es/chat/TokenTag/TokenTag.js +95 -0
  721. package/es/chat/TokenTag/index.d.ts +2 -25
  722. package/es/chat/TokenTag/index.js +1 -71
  723. package/es/chat/TokenTag/style.d.ts +5 -6
  724. package/es/chat/TokenTag/style.js +8 -30
  725. package/es/chat/TokenTag/type.d.ts +15 -0
  726. package/es/chat/TokenTag/type.js +1 -0
  727. package/es/chat/index.d.ts +4 -5
  728. package/es/chat/index.js +5 -6
  729. package/es/chat/types/chatMessage.js +1 -0
  730. package/es/chat/types/index.d.ts +4 -0
  731. package/es/chat/types/index.js +4 -0
  732. package/es/chat/types/meta.js +1 -0
  733. package/es/color/colors/gold.js +2 -2
  734. package/es/color/colors/gray.js +1 -1
  735. package/es/color/colors/green.js +3 -3
  736. package/es/color/colors/orange.js +2 -2
  737. package/es/color/colors/purple.js +1 -1
  738. package/es/color/colors/volcano.js +1 -1
  739. package/es/hooks/useCopied.js +2 -0
  740. package/es/hooks/useHighlight.d.ts +9 -4
  741. package/es/hooks/useHighlight.js +42 -24
  742. package/es/hooks/useMermaid.d.ts +5 -1
  743. package/es/hooks/useMermaid.js +10 -6
  744. package/es/icons/Auth0/components/Mono.js +2 -3
  745. package/es/icons/Authelia/components/Color.js +2 -3
  746. package/es/icons/Authelia/components/Mono.js +2 -3
  747. package/es/icons/Authentik/components/Color.js +2 -3
  748. package/es/icons/Authentik/components/Mono.js +2 -3
  749. package/es/icons/Casdoor/components/Color.js +2 -3
  750. package/es/icons/Casdoor/components/Mono.js +2 -3
  751. package/es/icons/Clerk/components/Color.js +2 -3
  752. package/es/icons/Clerk/components/Mono.js +2 -3
  753. package/es/icons/Logto/components/Color.js +2 -3
  754. package/es/icons/Logto/components/Mono.js +2 -3
  755. package/es/icons/MicrosoftEntra/components/Color.js +2 -3
  756. package/es/icons/MicrosoftEntra/components/Mono.js +2 -3
  757. package/es/icons/NextAuth/components/Color.js +2 -3
  758. package/es/icons/NextAuth/components/Mono.js +2 -3
  759. package/es/icons/Zitadel/components/Color.js +2 -3
  760. package/es/icons/Zitadel/components/Mono.js +2 -3
  761. package/es/icons/index.d.ts +1 -0
  762. package/es/icons/index.js +1 -0
  763. package/es/icons/lucideExtra/DiscordIcon.d.ts +3 -0
  764. package/es/icons/lucideExtra/DiscordIcon.js +17 -0
  765. package/es/icons/lucideExtra/GlobeOffIcon.d.ts +3 -0
  766. package/es/icons/lucideExtra/GlobeOffIcon.js +25 -0
  767. package/es/icons/lucideExtra/LeftClickIcon.d.ts +3 -0
  768. package/es/icons/lucideExtra/LeftClickIcon.js +11 -0
  769. package/es/icons/lucideExtra/LeftDoubleClickIcon.d.ts +3 -0
  770. package/es/{Hotkey/components → icons/lucideExtra}/LeftDoubleClickIcon.js +4 -3
  771. package/es/icons/lucideExtra/RightClickIcon.d.ts +3 -0
  772. package/es/icons/lucideExtra/RightClickIcon.js +11 -0
  773. package/es/icons/lucideExtra/RightDoubleClickIcon.d.ts +3 -0
  774. package/es/{Hotkey/components → icons/lucideExtra}/RightDoubleClickIcon.js +4 -3
  775. package/es/icons/lucideExtra/index.d.ts +6 -0
  776. package/es/icons/lucideExtra/index.js +6 -0
  777. package/es/index.d.ts +63 -7
  778. package/es/index.js +62 -7
  779. package/es/mdx/Callout/index.js +44 -45
  780. package/es/{awesome/GaussianBackground → mdx/Callout}/style.d.ts +1 -1
  781. package/es/mdx/Callout/style.js +11 -0
  782. package/es/mdx/Cards/Card.d.ts +3 -3
  783. package/es/mdx/Cards/Card.js +12 -7
  784. package/es/mdx/Cards/index.d.ts +1 -1
  785. package/es/mdx/Cards/index.js +10 -17
  786. package/es/{Mermaid/components → mdx/Cards}/style.d.ts +1 -1
  787. package/es/mdx/Cards/style.js +9 -0
  788. package/es/mdx/FileTree/File.js +1 -0
  789. package/es/mdx/FileTree/Folder.js +1 -0
  790. package/es/mdx/FileTree/index.js +6 -14
  791. package/es/mdx/FileTree/style.d.ts +3 -0
  792. package/es/mdx/FileTree/style.js +10 -0
  793. package/es/mdx/Mdx/index.d.ts +1 -1
  794. package/es/mdx/Mdx/index.js +4 -3
  795. package/es/mdx/Steps/index.js +6 -14
  796. package/es/mdx/Steps/style.d.ts +3 -0
  797. package/es/mdx/Steps/style.js +10 -0
  798. package/es/mdx/Tabs/Tab.js +1 -0
  799. package/es/mdx/Tabs/index.d.ts +2 -2
  800. package/es/mdx/Tabs/index.js +14 -25
  801. package/es/mdx/Tabs/style.d.ts +4 -0
  802. package/es/mdx/Tabs/style.js +12 -0
  803. package/es/mdx/mdxComponents/Citation/PopoverPanel.d.ts +2 -2
  804. package/es/mdx/mdxComponents/Citation/PopoverPanel.js +4 -3
  805. package/es/mdx/mdxComponents/Citation/index.d.ts +2 -2
  806. package/es/mdx/mdxComponents/Citation/index.js +4 -4
  807. package/es/mdx/mdxComponents/CodeBlock.d.ts +1 -1
  808. package/es/mdx/mdxComponents/CodeBlock.js +1 -0
  809. package/es/mdx/mdxComponents/Footnotes.d.ts +2 -2
  810. package/es/mdx/mdxComponents/Footnotes.js +5 -2
  811. package/es/mdx/mdxComponents/Image.d.ts +2 -5
  812. package/es/mdx/mdxComponents/Image.js +4 -20
  813. package/es/mdx/mdxComponents/Link.d.ts +3 -3
  814. package/es/mdx/mdxComponents/Link.js +3 -0
  815. package/es/mdx/mdxComponents/Pre.d.ts +1 -1
  816. package/es/mdx/mdxComponents/Pre.js +13 -15
  817. package/es/mdx/mdxComponents/Section.d.ts +2 -2
  818. package/es/mdx/mdxComponents/Section.js +16 -4
  819. package/es/mdx/mdxComponents/Video.d.ts +2 -5
  820. package/es/mdx/mdxComponents/Video.js +3 -19
  821. package/es/mobile/ChatHeader/ChatHeader.d.ts +4 -0
  822. package/es/mobile/ChatHeader/ChatHeader.js +88 -0
  823. package/es/mobile/ChatHeader/ChatHeaderTitle.d.ts +4 -0
  824. package/es/mobile/ChatHeader/ChatHeaderTitle.js +58 -0
  825. package/es/mobile/ChatHeader/index.d.ts +11 -0
  826. package/es/mobile/ChatHeader/index.js +6 -0
  827. package/es/mobile/ChatHeader/style.d.ts +14 -0
  828. package/es/mobile/{MobileNavBar → ChatHeader}/style.js +12 -1
  829. package/es/mobile/ChatHeader/type.d.ts +31 -0
  830. package/es/mobile/ChatHeader/type.js +1 -0
  831. package/es/mobile/ChatInputArea/ChatInputArea.d.ts +4 -0
  832. package/es/mobile/{MobileChatInputArea/index.js → ChatInputArea/ChatInputArea.js} +29 -41
  833. package/es/mobile/ChatInputArea/components/ChatSendButton.d.ts +4 -0
  834. package/es/mobile/{MobileChatInputArea/SendButton.js → ChatInputArea/components/ChatSendButton.js} +20 -27
  835. package/es/mobile/ChatInputArea/index.d.ts +11 -0
  836. package/es/mobile/ChatInputArea/index.js +6 -0
  837. package/es/mobile/ChatInputArea/style.d.ts +7 -0
  838. package/es/mobile/ChatInputArea/style.js +14 -0
  839. package/es/mobile/ChatInputArea/type.d.ts +19 -0
  840. package/es/mobile/ChatInputArea/type.js +1 -0
  841. package/es/mobile/SafeArea/SafeArea.d.ts +4 -0
  842. package/es/mobile/{MobileSafeArea/index.js → SafeArea/SafeArea.js} +4 -3
  843. package/es/mobile/SafeArea/index.d.ts +2 -0
  844. package/es/mobile/SafeArea/index.js +1 -0
  845. package/es/mobile/SafeArea/type.d.ts +4 -0
  846. package/es/mobile/SafeArea/type.js +1 -0
  847. package/es/mobile/TabBar/TabBar.d.ts +4 -0
  848. package/es/mobile/TabBar/TabBar.js +84 -0
  849. package/es/mobile/TabBar/index.d.ts +2 -0
  850. package/es/mobile/TabBar/index.js +1 -0
  851. package/es/mobile/{MobileTabBar → TabBar}/style.js +1 -2
  852. package/es/mobile/TabBar/type.d.ts +16 -0
  853. package/es/mobile/TabBar/type.js +1 -0
  854. package/es/mobile/index.d.ts +4 -6
  855. package/es/mobile/index.js +4 -6
  856. package/es/storybook/StoryBook/index.d.ts +3 -9
  857. package/es/storybook/StoryBook/index.js +14 -14
  858. package/es/styles/theme/antdTheme.js +28 -0
  859. package/es/styles/theme/customStylish.js +19 -8
  860. package/es/styles/theme/customToken.d.ts +1 -1
  861. package/es/styles/theme/customToken.js +2 -1
  862. package/es/styles/theme/generateColorPalette.js +2 -1
  863. package/es/styles/theme/token/base.js +3 -3
  864. package/es/styles/theme/token/light.js +2 -2
  865. package/es/types/customStylish.d.ts +12 -1
  866. package/es/types/customToken.d.ts +9 -2
  867. package/es/types/customToken.js +1 -0
  868. package/es/types/index.d.ts +1 -3
  869. package/es/types/index.js +0 -3
  870. package/es/utils/genCdnUrl.js +0 -23
  871. package/package.json +8 -4
  872. package/es/ActionIcon/calcSize.d.ts +0 -5
  873. package/es/ActionIcon/calcSize.js +0 -40
  874. package/es/ContextMenu/index.d.ts +0 -5
  875. package/es/ContextMenu/index.js +0 -17
  876. package/es/EmptyCard/index.d.ts +0 -19
  877. package/es/EmptyCard/style.js +0 -15
  878. package/es/Hotkey/components/LeftClickIcon.d.ts +0 -3
  879. package/es/Hotkey/components/LeftClickIcon.js +0 -10
  880. package/es/Hotkey/components/LeftDoubleClickIcon.d.ts +0 -3
  881. package/es/Hotkey/components/RightClickIcon.d.ts +0 -3
  882. package/es/Hotkey/components/RightClickIcon.js +0 -10
  883. package/es/Hotkey/components/RightDoubleClickIcon.d.ts +0 -3
  884. package/es/Icon/calcSize.d.ts +0 -5
  885. package/es/Icon/calcSize.js +0 -39
  886. package/es/Icon/icons/DiscordIcon.d.ts +0 -3
  887. package/es/Icon/icons/DiscordIcon.js +0 -20
  888. package/es/Icon/icons/index.d.ts +0 -1
  889. package/es/Icon/icons/index.js +0 -1
  890. package/es/Image/ImageGallery.d.ts +0 -11
  891. package/es/Image/usePreview.d.ts +0 -7
  892. package/es/MaterialFileTypeIcon/types.d.ts +0 -5
  893. package/es/Mermaid/components/Controls.d.ts +0 -3
  894. package/es/Mermaid/components/Controls.js +0 -49
  895. package/es/Mermaid/components/MermaidContainer.d.ts +0 -5
  896. package/es/Mermaid/components/MermaidContainer.js +0 -42
  897. package/es/Mermaid/components/MermaidZoomableContainer.d.ts +0 -5
  898. package/es/Mermaid/components/MermaidZoomableContainer.js +0 -21
  899. package/es/Mermaid/components/style.js +0 -12
  900. package/es/Mermaid/style.d.ts +0 -8
  901. package/es/Mermaid/style.js +0 -22
  902. package/es/SearchResultCard/index.js +0 -79
  903. package/es/SearchResultCards/index.d.ts +0 -12
  904. package/es/SearchResultCards/index.js +0 -30
  905. package/es/SelectWithImg/styles.js +0 -17
  906. package/es/SortableList/DragHandle.d.ts +0 -4
  907. package/es/Swatches/index.d.ts +0 -25
  908. package/es/Swatches/style.d.ts +0 -4
  909. package/es/Swatches/style.js +0 -11
  910. package/es/TabsNav/index.d.ts +0 -7
  911. package/es/TabsNav/style.js +0 -15
  912. package/es/awesome/Features/Item.d.ts +0 -55
  913. package/es/awesome/GaussianBackground/index.d.ts +0 -17
  914. package/es/awesome/GaussianBackground/style.js +0 -11
  915. package/es/awesome/GaussianBackground/useGaussianBackground.d.ts +0 -7
  916. package/es/awesome/GaussianBackground/vendor/gaussianBackground.d.ts +0 -38
  917. package/es/awesome/GaussianBackground/vendor/gaussianBackground.js +0 -226
  918. package/es/awesome/GaussianBackground/vendor/stackBlur.d.ts +0 -1
  919. package/es/awesome/GaussianBackground/vendor/stackBlur.js +0 -188
  920. package/es/awesome/GaussianBackground/vendor/stackBlurTable.d.ts +0 -2
  921. package/es/awesome/GaussianBackground/vendor/stackBlurTable.js +0 -2
  922. package/es/chat/ChatInputArea/ChatInputActionBar.d.ts +0 -9
  923. package/es/chat/ChatInputArea/ChatInputActionBar.js +0 -54
  924. package/es/chat/ChatInputArea/ChatInputAreaInner.d.ts +0 -12
  925. package/es/chat/ChatInputArea/SendButton.d.ts +0 -17
  926. package/es/chat/ChatInputArea/SendButton.js +0 -76
  927. package/es/chat/ChatList/ActionsBar.d.ts +0 -12
  928. package/es/components/ControlInput.d.ts +0 -22
  929. package/es/components.d.ts +0 -71
  930. package/es/components.js +0 -69
  931. package/es/hooks/languageMap.d.ts +0 -2
  932. package/es/hooks/languageMap.js +0 -1
  933. package/es/mobile/MobileChatInputArea/SendButton.d.ts +0 -9
  934. package/es/mobile/MobileChatInputArea/index.d.ts +0 -15
  935. package/es/mobile/MobileNavBar/MobileNavBarTitle.d.ts +0 -8
  936. package/es/mobile/MobileNavBar/MobileNavBarTitle.js +0 -70
  937. package/es/mobile/MobileNavBar/index.js +0 -75
  938. package/es/mobile/MobileSafeArea/index.d.ts +0 -7
  939. package/es/mobile/MobileTabBar/index.d.ts +0 -18
  940. package/es/mobile/MobileTabBar/index.js +0 -71
  941. /package/es/{MaterialFileTypeIcon/types.js → ActionIcon/type.js} +0 -0
  942. /package/es/{types/chatMessage.js → ActionIconGroup/type.js} +0 -0
  943. /package/es/{types/meta.js → Alert/type.js} +0 -0
  944. /package/es/Image/{Preview.js → components/Preview.js} +0 -0
  945. /package/es/SortableList/{SortableOverlay.d.ts → components/SortableOverlay.d.ts} +0 -0
  946. /package/es/chat/ChatList/{HistoryDivider.d.ts → components/HistoryDivider.d.ts} +0 -0
  947. /package/es/{hooks → chat/ChatList/components}/useChatListActionsBar.js +0 -0
  948. /package/es/{types → chat/types}/chatMessage.d.ts +0 -0
  949. /package/es/{types → chat/types}/error.d.ts +0 -0
  950. /package/es/{types → chat/types}/error.js +0 -0
  951. /package/es/{types → chat/types}/llm.d.ts +0 -0
  952. /package/es/{types → chat/types}/llm.js +0 -0
  953. /package/es/{types → chat/types}/meta.d.ts +0 -0
  954. /package/es/mobile/{MobileSafeArea → SafeArea}/style.d.ts +0 -0
  955. /package/es/mobile/{MobileSafeArea → SafeArea}/style.js +0 -0
  956. /package/es/mobile/{MobileTabBar → TabBar}/style.d.ts +0 -0
@@ -1,129 +1 @@
1
- 'use client';
2
-
3
- function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
4
- function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
5
- function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
6
- function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
7
- function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
8
- function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
9
- function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
10
- function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
11
- function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
12
- function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
13
- function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
14
- function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
15
- import { Button } from 'antd';
16
- import { useResponsive } from 'antd-style';
17
- import { memo, useState } from 'react';
18
- import { Flexbox } from 'react-layout-kit';
19
- import useControlledState from 'use-merge-value';
20
- import Markdown from "../../Markdown";
21
- import Modal from "../../Modal";
22
- import { useStyles as useTextStyles } from "../MessageInput/style";
23
- import MessageTextArea from "./TextArea";
24
- import { jsx as _jsx } from "react/jsx-runtime";
25
- import { jsxs as _jsxs } from "react/jsx-runtime";
26
- import { Fragment as _Fragment } from "react/jsx-runtime";
27
- var MessageModal = /*#__PURE__*/memo(function (_ref) {
28
- var editing = _ref.editing,
29
- open = _ref.open,
30
- _ref$height = _ref.height,
31
- height = _ref$height === void 0 ? 'auto' : _ref$height,
32
- onOpenChange = _ref.onOpenChange,
33
- onEditingChange = _ref.onEditingChange,
34
- placeholder = _ref.placeholder,
35
- value = _ref.value,
36
- onChange = _ref.onChange,
37
- text = _ref.text,
38
- footer = _ref.footer,
39
- extra = _ref.extra;
40
- var _useResponsive = useResponsive(),
41
- mobile = _useResponsive.mobile;
42
- var _useTextStyles = useTextStyles(),
43
- textStyles = _useTextStyles.styles;
44
- var _useControlledState = useControlledState(false, {
45
- onChange: onEditingChange,
46
- value: editing
47
- }),
48
- _useControlledState2 = _slicedToArray(_useControlledState, 2),
49
- isEdit = _useControlledState2[0],
50
- setTyping = _useControlledState2[1];
51
- var _useControlledState3 = useControlledState(false, {
52
- onChange: onOpenChange,
53
- value: open
54
- }),
55
- _useControlledState4 = _slicedToArray(_useControlledState3, 2),
56
- showModal = _useControlledState4[0],
57
- setShowModal = _useControlledState4[1];
58
- var _useState = useState(value),
59
- _useState2 = _slicedToArray(_useState, 2),
60
- temporaryValue = _useState2[0],
61
- setMessage = _useState2[1];
62
- var isAutoSize = height === 'auto';
63
- var markdownStyle = {
64
- height: isAutoSize ? 'unset' : height,
65
- overflowX: 'hidden',
66
- overflowY: 'auto'
67
- };
68
- var modalFooter = isEdit ? /*#__PURE__*/_jsxs(Flexbox, {
69
- direction: 'horizontal-reverse',
70
- gap: 8,
71
- children: [/*#__PURE__*/_jsx(Button, {
72
- onClick: function onClick() {
73
- setTyping(false);
74
- onChange === null || onChange === void 0 || onChange(temporaryValue);
75
- setMessage(value);
76
- },
77
- type: "primary",
78
- children: (text === null || text === void 0 ? void 0 : text.confirm) || 'Confirm'
79
- }), /*#__PURE__*/_jsx(Button, {
80
- onClick: function onClick() {
81
- setTyping(false);
82
- setMessage(value);
83
- },
84
- children: (text === null || text === void 0 ? void 0 : text.cancel) || 'Cancel'
85
- })]
86
- }) : footer;
87
- return /*#__PURE__*/_jsx(Modal, {
88
- allowFullscreen: true,
89
- cancelText: (text === null || text === void 0 ? void 0 : text.cancel) || 'Cancel',
90
- destroyOnClose: true,
91
- footer: modalFooter,
92
- okText: (text === null || text === void 0 ? void 0 : text.edit) || 'Edit',
93
- onCancel: function onCancel() {
94
- setShowModal(false);
95
- setTyping(false);
96
- setMessage(value);
97
- },
98
- onOk: function onOk() {
99
- return setTyping(true);
100
- },
101
- open: showModal,
102
- title: text === null || text === void 0 ? void 0 : text.title,
103
- children: isEdit ? /*#__PURE__*/_jsx(MessageTextArea, {
104
- autoSize: isAutoSize,
105
- className: textStyles,
106
- defaultValue: value,
107
- onChange: function onChange(value) {
108
- return setMessage(value);
109
- },
110
- placeholder: placeholder,
111
- resize: false,
112
- style: {
113
- flex: mobile ? 1 : undefined,
114
- height: isAutoSize ? 'unset' : height,
115
- minHeight: mobile ? 'unset' : '100%'
116
- },
117
- type: mobile ? 'pure' : 'block'
118
- }) : /*#__PURE__*/_jsxs(_Fragment, {
119
- children: [extra, /*#__PURE__*/_jsx(Markdown, {
120
- style: value ? markdownStyle : _objectSpread(_objectSpread({}, markdownStyle), {}, {
121
- opacity: 0.5
122
- }),
123
- variant: 'chat',
124
- children: String(value || placeholder)
125
- })]
126
- })
127
- });
128
- });
129
- export default MessageModal;
1
+ export { default } from "./MessageModal";
@@ -0,0 +1,22 @@
1
+ import type { ReactNode } from 'react';
2
+ import type { ModalProps } from "../../Modal";
3
+ import type { MessageInputProps } from "../MessageInput";
4
+ export interface MessageModalProps extends Pick<ModalProps, 'open' | 'footer' | 'panelRef'> {
5
+ editing?: boolean;
6
+ extra?: ReactNode;
7
+ height?: MessageInputProps['height'];
8
+ onChange?: (text: string) => void;
9
+ onEditingChange?: (editing: boolean) => void;
10
+ onOpenChange?: (open: boolean) => void;
11
+ placeholder?: string;
12
+ text?: {
13
+ cancel?: string;
14
+ confirm?: string;
15
+ edit?: string;
16
+ title?: string;
17
+ };
18
+ /**
19
+ * @description The value of the message content
20
+ */
21
+ value: string;
22
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,4 @@
1
+ /// <reference types="react" />
2
+ import type { TokenTagProps } from './type';
3
+ declare const TokenTag: import("react").NamedExoticComponent<TokenTagProps>;
4
+ export default TokenTag;
@@ -0,0 +1,95 @@
1
+ 'use client';
2
+
3
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
4
+ var _excluded = ["className", "shape", "mode", "maxValue", "value", "text", "unoptimized", "hideText", "ref"];
5
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
6
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
7
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
8
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
9
+ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
10
+ function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
11
+ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
12
+ import { useResponsive } from 'antd-style';
13
+ import { cva } from 'class-variance-authority';
14
+ import numeral from 'numeral';
15
+ import { memo, useMemo } from 'react';
16
+ import Button from "../../Button";
17
+ import FluentEmoji from "../../FluentEmoji";
18
+ import { useStyles } from "./style";
19
+ import { jsx as _jsx } from "react/jsx-runtime";
20
+ import { jsxs as _jsxs } from "react/jsx-runtime";
21
+ var format = function format(number) {
22
+ return numeral(number).format('0,0');
23
+ };
24
+ var TokenTag = /*#__PURE__*/memo(function (_ref) {
25
+ var className = _ref.className,
26
+ _ref$shape = _ref.shape,
27
+ shape = _ref$shape === void 0 ? 'round' : _ref$shape,
28
+ _ref$mode = _ref.mode,
29
+ mode = _ref$mode === void 0 ? 'remained' : _ref$mode,
30
+ maxValue = _ref.maxValue,
31
+ value = _ref.value,
32
+ text = _ref.text,
33
+ unoptimized = _ref.unoptimized,
34
+ hideText = _ref.hideText,
35
+ ref = _ref.ref,
36
+ rest = _objectWithoutProperties(_ref, _excluded);
37
+ var _useResponsive = useResponsive(),
38
+ mobile = _useResponsive.mobile;
39
+ var valueLeft = maxValue - value;
40
+ var percent = valueLeft / maxValue;
41
+ var showText = !hideText && !mobile;
42
+ var data = useMemo(function () {
43
+ var type;
44
+ var emoji;
45
+ if (percent > 0.3) {
46
+ type = 'normal';
47
+ emoji = '😀';
48
+ } else if (percent > 0) {
49
+ type = 'low';
50
+ emoji = '😅';
51
+ } else {
52
+ type = 'overload';
53
+ emoji = '🤯';
54
+ }
55
+ return {
56
+ emoji: emoji,
57
+ type: type
58
+ };
59
+ }, [percent]);
60
+ var _useStyles = useStyles(),
61
+ styles = _useStyles.styles,
62
+ cx = _useStyles.cx;
63
+ var variants = useMemo(function () {
64
+ return cva(styles.root, {
65
+ defaultVariants: {
66
+ type: 'normal'
67
+ },
68
+ /* eslint-disable sort-keys-fix/sort-keys-fix */
69
+ variants: {
70
+ type: {
71
+ normal: styles.normal,
72
+ low: styles.low,
73
+ overload: styles.overload
74
+ }
75
+ }
76
+ /* eslint-enable sort-keys-fix/sort-keys-fix */
77
+ });
78
+ }, [styles]);
79
+ return /*#__PURE__*/_jsxs(Button, _objectSpread(_objectSpread({
80
+ className: cx(variants({
81
+ type: data.type
82
+ }), className),
83
+ ref: ref,
84
+ shape: shape,
85
+ variant: 'filled'
86
+ }, rest), {}, {
87
+ children: [/*#__PURE__*/_jsx(FluentEmoji, {
88
+ emoji: data.emoji,
89
+ size: 18,
90
+ unoptimized: unoptimized
91
+ }), valueLeft > 0 ? [showText ? mode === 'remained' ? (text === null || text === void 0 ? void 0 : text.remained) || 'Remained' : (text === null || text === void 0 ? void 0 : text.used) || 'Used' : '', mode === 'remained' ? format(valueLeft) : format(value)].join(' ') : (text === null || text === void 0 ? void 0 : text.overload) || 'Overload']
92
+ }));
93
+ });
94
+ TokenTag.displayName = 'TokenTag';
95
+ export default TokenTag;
@@ -1,25 +1,2 @@
1
- /// <reference types="react" />
2
- import { DivProps } from "../../types";
3
- export interface TokenTagProps extends DivProps {
4
- /**
5
- * @default 'left'
6
- */
7
- displayMode?: 'remained' | 'used';
8
- /**
9
- * @description Maximum value for the token
10
- */
11
- maxValue: number;
12
- shape?: 'round' | 'square';
13
- text?: {
14
- overload?: string;
15
- remained?: string;
16
- used?: string;
17
- };
18
- unoptimized?: boolean;
19
- /**
20
- * @description Current value of the token
21
- */
22
- value: number;
23
- }
24
- declare const TokenTag: import("react").ForwardRefExoticComponent<TokenTagProps & import("react").RefAttributes<HTMLDivElement>>;
25
- export default TokenTag;
1
+ export { default } from './TokenTag';
2
+ export type * from './type';
@@ -1,71 +1 @@
1
- 'use client';
2
-
3
- function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
4
- var _excluded = ["className", "displayMode", "maxValue", "value", "text", "shape", "unoptimized"];
5
- function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
6
- function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
7
- function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
8
- function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
9
- function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
10
- function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
11
- function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
12
- import { useResponsive } from 'antd-style';
13
- import numeral from 'numeral';
14
- import { forwardRef } from 'react';
15
- import { Flexbox } from 'react-layout-kit';
16
- import FluentEmoji from "../../FluentEmoji";
17
- import { ICON_SIZE, useStyles } from "./style";
18
- import { jsx as _jsx } from "react/jsx-runtime";
19
- import { jsxs as _jsxs } from "react/jsx-runtime";
20
- var format = function format(number) {
21
- return numeral(number).format('0,0');
22
- };
23
- var TokenTag = /*#__PURE__*/forwardRef(function (_ref, ref) {
24
- var className = _ref.className,
25
- _ref$displayMode = _ref.displayMode,
26
- displayMode = _ref$displayMode === void 0 ? 'remained' : _ref$displayMode,
27
- maxValue = _ref.maxValue,
28
- value = _ref.value,
29
- text = _ref.text,
30
- _ref$shape = _ref.shape,
31
- shape = _ref$shape === void 0 ? 'round' : _ref$shape,
32
- unoptimized = _ref.unoptimized,
33
- rest = _objectWithoutProperties(_ref, _excluded);
34
- var _useResponsive = useResponsive(),
35
- mobile = _useResponsive.mobile;
36
- var valueLeft = maxValue - value;
37
- var percent = valueLeft / maxValue;
38
- var type;
39
- var emoji;
40
- if (percent > 0.3) {
41
- type = 'normal';
42
- emoji = '😀';
43
- } else if (percent > 0) {
44
- type = 'low';
45
- emoji = '😅';
46
- } else {
47
- type = 'overload';
48
- emoji = '🤯';
49
- }
50
- var _useStyles = useStyles({
51
- shape: shape,
52
- type: type
53
- }),
54
- styles = _useStyles.styles,
55
- cx = _useStyles.cx;
56
- return /*#__PURE__*/_jsxs(Flexbox, _objectSpread(_objectSpread({
57
- align: 'center',
58
- className: cx(styles.container, className),
59
- flex: 'none',
60
- gap: 4,
61
- horizontal: true,
62
- ref: ref
63
- }, rest), {}, {
64
- children: [/*#__PURE__*/_jsx(FluentEmoji, {
65
- emoji: emoji,
66
- size: ICON_SIZE,
67
- unoptimized: unoptimized
68
- }), valueLeft > 0 ? [mobile ? '' : displayMode === 'remained' ? (text === null || text === void 0 ? void 0 : text.remained) || 'Remained' : (text === null || text === void 0 ? void 0 : text.used) || 'Used', displayMode === 'remained' ? format(valueLeft) : format(value)].join(' ') : (text === null || text === void 0 ? void 0 : text.overload) || 'Overload']
69
- }));
70
- });
71
- export default TokenTag;
1
+ export { default } from "./TokenTag";
@@ -1,7 +1,6 @@
1
- export declare const ICON_SIZE = 20;
2
- export declare const useStyles: (props?: {
3
- shape: 'round' | 'square';
4
- type: 'normal' | 'low' | 'overload';
5
- } | undefined) => import("antd-style").ReturnStyles<{
6
- container: string;
1
+ export declare const useStyles: (props?: unknown) => import("antd-style").ReturnStyles<{
2
+ low: import("antd-style").SerializedStyles;
3
+ normal: import("antd-style").SerializedStyles;
4
+ overload: import("antd-style").SerializedStyles;
5
+ root: import("antd-style").SerializedStyles;
7
6
  }>;
@@ -1,36 +1,14 @@
1
- var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6;
1
+ var _templateObject, _templateObject2, _templateObject3, _templateObject4;
2
2
  function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
3
3
  import { createStyles } from 'antd-style';
4
- var HEIGHT = 28;
5
- export var ICON_SIZE = 20;
6
- export var useStyles = createStyles(function (_ref, _ref2) {
7
- var cx = _ref.cx,
4
+ export var useStyles = createStyles(function (_ref) {
5
+ var prefixCls = _ref.prefixCls,
8
6
  css = _ref.css,
9
- token = _ref.token,
10
- isDarkMode = _ref.isDarkMode;
11
- var type = _ref2.type,
12
- shape = _ref2.shape;
13
- var percentStyle;
14
- switch (type) {
15
- case 'normal':
16
- {
17
- percentStyle = css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n color: ", ";\n "])), token.colorSuccessText);
18
- break;
19
- }
20
- case 'low':
21
- {
22
- percentStyle = css(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n color: ", ";\n "])), token.colorWarningText);
23
- break;
24
- }
25
- case 'overload':
26
- {
27
- percentStyle = css(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n color: ", ";\n "])), token.colorErrorText);
28
- break;
29
- }
30
- }
31
- var roundStylish = css(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n padding-block: 0;\n padding-inline: ", "px ", "px;\n background: ", ";\n border-radius: ", "px;\n "])), (HEIGHT - ICON_SIZE) / 2, (HEIGHT - ICON_SIZE) * 1.2, isDarkMode ? token.colorFillSecondary : token.colorFillTertiary, HEIGHT / 2);
32
- var squareStylish = css(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["\n border-radius: ", "px;\n "])), token.borderRadiusSM);
7
+ token = _ref.token;
33
8
  return {
34
- container: cx(percentStyle, shape === 'round' ? roundStylish : squareStylish, css(_templateObject6 || (_templateObject6 = _taggedTemplateLiteral(["\n user-select: none;\n\n overflow: hidden;\n\n min-width: fit-content;\n height: ", "px;\n\n font-size: 13px;\n line-height: 1;\n "])), HEIGHT))
9
+ low: css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n color: ", ";\n "])), token.colorWarningText),
10
+ normal: css(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n color: ", ";\n "])), token.colorSuccessText),
11
+ overload: css(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n color: ", ";\n "])), token.colorErrorText),
12
+ root: css(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n user-select: none;\n min-width: fit-content;\n height: 28px;\n &.", "-btn {\n padding-block: 12px;\n &.", "-btn-round {\n padding-inline: 6px 12px;\n }\n &.", "-btn-square {\n padding-inline: 6px 12px;\n }\n }\n "])), prefixCls, prefixCls, prefixCls)
35
13
  };
36
14
  });
@@ -0,0 +1,15 @@
1
+ import type { Ref } from 'react';
2
+ import type { ButtonProps } from "../../Button";
3
+ export interface TokenTagProps extends ButtonProps {
4
+ hideText?: boolean;
5
+ maxValue: number;
6
+ mode?: 'remained' | 'used';
7
+ ref?: Ref<HTMLButtonElement>;
8
+ text?: {
9
+ overload?: string;
10
+ remained?: string;
11
+ used?: string;
12
+ };
13
+ unoptimized?: boolean;
14
+ value: number;
15
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -1,12 +1,11 @@
1
1
  export { default as BackBottom, type BackBottomProps } from './BackBottom';
2
- export { default as ChatHeader, type ChatHeaderProps } from './ChatHeader';
3
- export { default as ChatHeaderTitle, type ChatHeaderTitleProps, } from './ChatHeader/ChatHeaderTitle';
4
- export * from './ChatInputArea';
2
+ export { default as ChatHeader, type ChatHeaderProps, ChatHeaderTitle, type ChatHeaderTitleProps, } from './ChatHeader';
3
+ export { ChatInputActionBar, type ChatInputActionBarProps, default as ChatInputArea, ChatInputAreaInner, type ChatInputAreaInnerProps, type ChatInputAreaProps, ChatSendButton, type ChatSendButtonProps, } from './ChatInputArea';
5
4
  export { default as ChatItem, type ChatItemProps } from './ChatItem';
6
- export { default as ChatList, type ChatListProps, type OnActionsClick, type OnAvatatsClick, type OnMessageChange, type RenderAction, type RenderErrorMessage, type RenderItem, type RenderMessage, type RenderMessageExtra, } from './ChatList';
7
- export { default as ActionsBar, type ActionsBarProps } from './ChatList/ActionsBar';
5
+ export { ChatActionsBar, type ChatActionsBarProps, default as ChatList, type ChatListProps, type OnActionsClick, type OnAvatatsClick, type OnMessageChange, type RenderAction, type RenderErrorMessage, type RenderItem, type RenderMessage, type RenderMessageExtra, } from './ChatList';
8
6
  export { default as EditableMessage, type EditableMessageProps } from './EditableMessage';
9
7
  export { default as EditableMessageList, type EditableMessageListProps, } from './EditableMessageList';
10
8
  export { default as MessageInput, type MessageInputProps } from './MessageInput';
11
9
  export { default as MessageModal, type MessageModalProps } from './MessageModal';
12
10
  export { default as TokenTag, type TokenTagProps } from './TokenTag';
11
+ export * from './types';
package/es/chat/index.js CHANGED
@@ -1,12 +1,11 @@
1
1
  export { default as BackBottom } from "./BackBottom";
2
- export { default as ChatHeader } from "./ChatHeader";
3
- export { default as ChatHeaderTitle } from "./ChatHeader/ChatHeaderTitle";
4
- export * from "./ChatInputArea";
2
+ export { default as ChatHeader, ChatHeaderTitle } from "./ChatHeader";
3
+ export { ChatInputActionBar, default as ChatInputArea, ChatInputAreaInner, ChatSendButton } from "./ChatInputArea";
5
4
  export { default as ChatItem } from "./ChatItem";
6
- export { default as ChatList } from "./ChatList";
7
- export { default as ActionsBar } from "./ChatList/ActionsBar";
5
+ export { ChatActionsBar, default as ChatList } from "./ChatList";
8
6
  export { default as EditableMessage } from "./EditableMessage";
9
7
  export { default as EditableMessageList } from "./EditableMessageList";
10
8
  export { default as MessageInput } from "./MessageInput";
11
9
  export { default as MessageModal } from "./MessageModal";
12
- export { default as TokenTag } from "./TokenTag";
10
+ export { default as TokenTag } from "./TokenTag";
11
+ export * from "./types";
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,4 @@
1
+ export * from './chatMessage';
2
+ export * from './error';
3
+ export * from './llm';
4
+ export * from './meta';
@@ -0,0 +1,4 @@
1
+ export * from "./chatMessage";
2
+ export * from "./error";
3
+ export * from "./llm";
4
+ export * from "./meta";
@@ -0,0 +1 @@
1
+ export {};
@@ -1,7 +1,7 @@
1
1
  var gold = {
2
2
  dark: ['#070300', '#2a1b00', '#483000', '#6a4900', '#916400', '#b77e00', '#d59300', '#eaa100', '#f8aa00', '#ffb224', '#ffdcaf', '#fff4eb', '#ffffff'],
3
3
  darkA: ['rgba(233, 100, 0, 0.03)', 'rgba(247, 159, 0, 0.17)', 'rgba(248, 166, 0, 0.29)', 'rgba(252, 174, 0, 0.42)', 'rgba(254, 175, 0, 0.57)', 'rgba(254, 175, 0, 0.72)', 'rgba(254, 175, 0, 0.84)', 'rgba(254, 175, 0, 0.92)', 'rgba(253, 173, 0, 0.98)', '#ffb224', '#ffdcaf', '#fff4eb', '#ffffff'],
4
- light: ['#ffffff', '#fffdff', '#fff9f7', '#fff4eb', '#ffeedc', '#ffe6c8', '#ffdcaf', '#ffd190', '#ffc368', '#ffb224', '#d59300', '#6a4900', '#070300'],
5
- lightA: ['rgba(255, 255, 255, 0.01)', 'rgba(255, 55, 255, 0.01)', 'rgba(255, 105, 55, 0.04)', 'rgba(255, 117, 5, 0.08)', 'rgba(255, 134, 5, 0.14)', 'rgba(255, 141, 5, 0.22)', 'rgba(255, 146, 5, 0.32)', 'rgba(255, 150, 3, 0.44)', 'rgba(255, 155, 3, 0.6)', 'rgba(255, 165, 0, 0.86)', '#d59300', '#6a4900', '#070300']
4
+ light: ['#ffffff', '#fffdff', '#fff9f7', '#fff4eb', '#ffeedc', '#ffe6c8', '#ffdcaf', '#ffd190', '#ffc368', '#ee9e0b', '#d59300', '#6a4900', '#070300'],
5
+ lightA: ['rgba(255, 255, 255, 0.02)', 'rgba(255,145,55,0.04)', 'rgba(255,155,55,0.08)', 'rgba(255, 117, 5, 0.16)', 'rgba(255, 134, 5, 0.20)', 'rgba(255, 141, 5, 0.26)', 'rgba(255, 146, 5, 0.32)', 'rgba(255, 150, 3, 0.44)', 'rgba(255, 155, 3, 0.6)', 'rgba(255, 165, 0, 0.86)', '#d59300', '#6a4900', '#070300']
6
6
  };
7
7
  export default gold;
@@ -1,5 +1,5 @@
1
1
  var gray = {
2
- dark: ['#000000', '#111111', '#1a1a1a', '#222222', '#2d2d2d', '#444444', '#555555', '#666666', '#6f6f6f', '#777777', '#aaaaaa', '#dddddd', '#ffffff'],
2
+ dark: ['#000000', '#0d0d0d', '#1a1a1a', '#202020', '#2d2d2d', '#444444', '#555555', '#666666', '#6f6f6f', '#777777', '#aaaaaa', '#dddddd', '#ffffff'],
3
3
  darkA: ['rgba(255, 255, 255, 0.02)', 'rgba(255, 255, 255, 0.06)', 'rgba(255, 255, 255, 0.10)', 'rgba(255, 255, 255, 0.16)', 'rgba(255, 255, 255, 0.24)', 'rgba(255, 255, 255, 0.28)', 'rgba(255, 255, 255, 0.32)', 'rgba(255, 255, 255, 0.38)', 'rgba(255, 255, 255, 0.44)', 'rgba(255, 255, 255, 0.5)', 'rgba(255, 255, 255, 0.66)', 'rgba(255, 255, 255, 0.84)', '#ffffff'],
4
4
  light: ['#ffffff', '#f8f8f8', '#eeeeee', '#e3e3e3', '#dddddd', '#cccccc', '#bbbbbb', '#aaaaaa', '#999999', '#888888', '#666666', '#333333', '#080808'],
5
5
  lightA: ['rgba(0, 0, 0, 0.015)', 'rgba(0, 0, 0, 0.03)', 'rgba(0, 0, 0, 0.06)', 'rgba(0, 0, 0, 0.12)', 'rgba(0, 0, 0, 0.18)', 'rgba(0, 0, 0, 0.24)', 'rgba(0, 0, 0, 0.32)', 'rgba(0, 0, 0, 0.38)', 'rgba(0, 0, 0, 0.44)', 'rgba(0, 0, 0, 0.5)', 'rgba(0, 0, 0, 0.68)', 'rgba(0, 0, 0, 0.84)', 'rgba(0, 0, 0, 0.98)']
@@ -1,7 +1,7 @@
1
1
  var green = {
2
- dark: ['#000503', '#001d12', '#002d1d', '#003f28', '#005232', '#00653c', '#007944', '#1b8d4d', '#3ba05a', '#55b467', '#96cd92', '#cde6c3', '#ffffff'],
2
+ dark: ['#000503', '#001d12', '#002d1d', '#003f28', '#005232', '#00653c', '#007944', '#1b8d4d', '#3ba05a', '#62c473', '#96cd92', '#cde6c3', '#ffffff'],
3
3
  darkA: ['rgba(0, 250, 150, 0.02)', 'rgba(0, 242, 150, 0.12)', 'rgba(0, 250, 161, 0.18)', 'rgba(0, 252, 160, 0.25)', 'rgba(0, 248, 152, 0.33)', 'rgba(0, 252, 150, 0.4)', 'rgba(0, 252, 142, 0.48)', 'rgba(48, 252, 137, 0.56)', 'rgba(94, 254, 143, 0.63)', 'rgba(120, 254, 145, 0.71)', 'rgba(185, 253, 180, 0.81)', 'rgba(225, 253, 214, 0.91)', '#ffffff'],
4
- light: ['#ffffff', '#f4fdeb', '#e7f8dd', '#d8f2ce', '#c7eabd', '#b4e1ac', '#a0d79b', '#89cc8a', '#71c179', '#55b467', '#007944', '#003f28', '#000503'],
5
- lightA: ['rgba(255, 255, 255, 0.01)', 'rgba(117, 230, 5, 0.08)', 'rgba(84, 205, 12, 0.14)', 'rgba(60, 190, 10, 0.2)', 'rgba(40, 174, 1, 0.26)', 'rgba(28, 164, 3, 0.33)', 'rgba(18, 155, 5, 0.4)', 'rgba(4, 146, 6, 0.47)', 'rgba(1, 144, 16, 0.56)', 'rgba(1, 143, 28, 0.67)', '#007944', '#003f28', '#000503']
4
+ light: ['#ffffff', '#f4fdeb', '#e7f8dd', '#d8f2ce', '#c7eabd', '#b4e1ac', '#a0d79b', '#89cc8a', '#71c179', '#379d4a', '#007944', '#003f28', '#000503'],
5
+ lightA: ['rgba(255, 255, 255, 0.02)', 'rgba(117, 230, 5, 0.06)', 'rgba(84, 205, 12, 0.10)', 'rgba(60, 190, 10, 0.14)', 'rgba(40, 174, 1, 0.26)', 'rgba(28, 164, 3, 0.33)', 'rgba(18, 155, 5, 0.4)', 'rgba(4, 146, 6, 0.47)', 'rgba(1, 144, 16, 0.56)', 'rgba(1, 143, 28, 0.67)', '#007944', '#003f28', '#000503']
6
6
  };
7
7
  export default green;
@@ -1,7 +1,7 @@
1
1
  var orange = {
2
2
  dark: ['#070300', '#291900', '#462b00', '#684100', '#8e5900', '#b36f00', '#d18000', '#e88b00', '#f89200', '#ff9927', '#ffd1b1', '#fff1eb', '#ffffff'],
3
3
  darkA: ['rgba(233, 100, 0, 0.03)', 'rgba(241, 147, 0, 0.17)', 'rgba(250, 154, 0, 0.28)', 'rgba(254, 159, 0, 0.41)', 'rgba(254, 159, 0, 0.56)', 'rgba(252, 156, 0, 0.71)', 'rgba(255, 156, 0, 0.82)', 'rgba(255, 153, 0, 0.91)', 'rgba(253, 149, 0, 0.98)', '#ff9927', '#ffd1b1', '#fff1eb', '#ffffff'],
4
- light: ['#ffffff', '#fffcff', '#fff8f6', '#fff1eb', '#ffe9dd', '#ffdeca', '#ffd1b1', '#ffc293', '#ffb06a', '#ff9927', '#d18000', '#684100', '#070300'],
5
- lightA: ['rgba(255, 255, 255, 0.01)', 'rgba(255, 105, 255, 0.02)', 'rgba(255, 80, 30, 0.04)', 'rgba(255, 80, 5, 0.08)', 'rgba(255, 98, 12, 0.14)', 'rgba(255, 98, 3, 0.21)', 'rgba(255, 107, 3, 0.31)', 'rgba(255, 113, 4, 0.43)', 'rgba(255, 121, 2, 0.59)', 'rgba(255, 135, 1, 0.85)', '#d18000', '#684100', '#070300']
4
+ light: ['#ffffff', '#fffcff', '#fff8f6', '#fff1eb', '#ffe9dd', '#ffdeca', '#ffd1b1', '#ffc293', '#ffb06a', '#f88c13', '#d18000', '#684100', '#070300'],
5
+ lightA: ['rgba(255, 255, 255, 0.02)', 'rgba(255, 105, 255, 0.03)', 'rgba(255, 80, 30, 0.08)', 'rgba(255, 80, 5, 0.12)', 'rgba(255, 98, 12, 0.16)', 'rgba(255, 98, 3, 0.21)', 'rgba(255, 107, 3, 0.31)', 'rgba(255, 113, 4, 0.43)', 'rgba(255, 121, 2, 0.59)', 'rgba(255, 135, 1, 0.85)', '#d18000', '#684100', '#070300']
6
6
  };
7
7
  export default orange;
@@ -2,6 +2,6 @@ var purple = {
2
2
  dark: ['#0d000b', '#2e002a', '#42003e', '#560053', '#670e66', '#781e78', '#892b8a', '#9a399e', '#ab46b2', '#bd54c6', '#d590da', '#edc7ee', '#ffffff'],
3
3
  darkA: ['rgba(217, 0, 183, 0.06)', 'rgba(242, 0, 221, 0.19)', 'rgba(254, 0, 238, 0.26)', 'rgba(253, 0, 244, 0.34)', 'rgba(251, 34, 249, 0.41)', 'rgba(255, 64, 255, 0.47)', 'rgba(249, 78, 251, 0.55)', 'rgba(248, 92, 255, 0.62)', 'rgba(244, 100, 254, 0.7)', 'rgba(242, 108, 254, 0.78)', 'rgba(248, 167, 253, 0.86)', 'rgba(252, 212, 253, 0.94)', '#ffffff'],
4
4
  light: ['#ffffff', '#fff6fb', '#ffe7fd', '#fdd6fe', '#f6c4f8', '#eeb1f1', '#e49ce8', '#d886de', '#cb6ed2', '#bd54c6', '#892b8a', '#560053', '#0d000b'],
5
- lightA: ['rgba(255, 255, 255, 0.01)', 'rgba(255, 30, 155, 0.04)', 'rgba(255, 15, 235, 0.1)', 'rgba(243, 14, 249, 0.17)', 'rgba(218, 9, 226, 0.24)', 'rgba(200, 3, 210, 0.31)', 'rgba(186, 1, 196, 0.39)', 'rgba(174, 3, 186, 0.48)', 'rgba(164, 1, 176, 0.57)', 'rgba(156, 0, 170, 0.67)', 'rgba(113, 0, 114, 0.83)', '#560053', '#0d000b']
5
+ lightA: ['rgba(255, 255, 255, 0.01)', 'rgba(255, 30, 155, 0.04)', 'rgba(255, 15, 235, 0.08)', 'rgba(243, 14, 249, 0.16)', 'rgba(218, 9, 226, 0.24)', 'rgba(200, 3, 210, 0.31)', 'rgba(186, 1, 196, 0.39)', 'rgba(174, 3, 186, 0.48)', 'rgba(164, 1, 176, 0.57)', 'rgba(156, 0, 170, 0.67)', 'rgba(113, 0, 114, 0.83)', '#560053', '#0d000b']
6
6
  };
7
7
  export default purple;
@@ -2,6 +2,6 @@ var volcano = {
2
2
  dark: ['#0c0100', '#2f0a00', '#451200', '#5d1900', '#762000', '#8e2a07', '#a53716', '#bc4424', '#d45132', '#ec5e41', '#ff9480', '#ffcbc3', '#ffffff'],
3
3
  darkA: ['rgba(240, 20, 0, 0.05)', 'rgba(247, 53, 0, 0.19)', 'rgba(246, 64, 0, 0.28)', 'rgba(251, 68, 0, 0.37)', 'rgba(251, 68, 0, 0.47)', 'rgba(254, 75, 12, 0.56)', 'rgba(254, 85, 34, 0.65)', 'rgba(254, 92, 49, 0.74)', 'rgba(255, 98, 60, 0.83)', 'rgba(254, 101, 70, 0.93)', '#ff9480', '#ffcbc3', '#ffffff'],
4
4
  light: ['#ffffff', '#fff7f6', '#ffece9', '#ffded9', '#ffcec5', '#ffbbaf', '#ffa695', '#ff8e78', '#fb745a', '#ec5e41', '#a53716', '#5d1900', '#0c0100'],
5
- lightA: ['rgba(255, 255, 255, 0.01)', 'rgba(255, 55, 30, 0.04)', 'rgba(255, 44, 11, 0.09)', 'rgba(255, 35, 2, 0.15)', 'rgba(255, 42, 3, 0.23)', 'rgba(255, 43, 5, 0.32)', 'rgba(255, 43, 3, 0.42)', 'rgba(255, 42, 0, 0.53)', 'rgba(249, 41, 1, 0.65)', 'rgba(230, 40, 2, 0.75)', 'rgba(157, 38, 2, 0.92)', '#5d1900', '#0c0100']
5
+ lightA: ['rgba(255, 255, 255, 0.01)', 'rgba(255, 55, 30, 0.04)', 'rgba(255, 44, 11, 0.06)', 'rgba(255, 35, 2, 0.12)', 'rgba(255, 42, 3, 0.20)', 'rgba(255, 43, 5, 0.32)', 'rgba(255, 43, 3, 0.42)', 'rgba(255, 42, 0, 0.53)', 'rgba(249, 41, 1, 0.65)', 'rgba(230, 40, 2, 0.75)', 'rgba(157, 38, 2, 0.92)', '#5d1900', '#0c0100']
6
6
  };
7
7
  export default volcano;
@@ -1,3 +1,5 @@
1
+ 'use client';
2
+
1
3
  function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
2
4
  function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
3
5
  function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
@@ -1,9 +1,14 @@
1
+ import type { BuiltinTheme, CodeToHastOptions } from 'shiki';
1
2
  import { SWRResponse } from 'swr';
2
3
  export declare const FALLBACK_LANG = "txt";
3
4
  declare const MD5_LENGTH_THRESHOLD = 10000;
4
- declare const loadShiki: () => Promise<(code: string, options: import("@shikijs/types").CodeToHastOptions<import("shiki/dist/langs.mjs").BundledLanguage, import("shiki/dist/themes.mjs").BundledTheme>) => Promise<string>>;
5
- declare const shikiPromise: Promise<(code: string, options: import("@shikijs/types").CodeToHastOptions<import("shiki/dist/langs.mjs").BundledLanguage, import("shiki/dist/themes.mjs").BundledTheme>) => Promise<string>>;
5
+ type ICodeToHtml = (code: string, options: CodeToHastOptions) => Promise<string>;
6
+ declare const loadShiki: () => Promise<ICodeToHtml | null>;
7
+ declare const shikiPromise: Promise<ICodeToHtml | null>;
6
8
  declare const escapeHtml: (str: string) => string;
7
- export declare const useHighlight: (text: string, lang: string, enableTransformer?: boolean) => SWRResponse<string, Error>;
8
- export { default as languageMap } from './languageMap';
9
+ export declare const useHighlight: (text: string, { language, enableTransformer, theme: builtinTheme, }: {
10
+ enableTransformer?: boolean | undefined;
11
+ language: string;
12
+ theme?: import("shiki/dist/themes.mjs").BundledTheme | undefined;
13
+ }) => SWRResponse<string, Error>;
9
14
  export { escapeHtml, loadShiki, MD5_LENGTH_THRESHOLD, shikiPromise };