@ant-design/agentic-ui 2.29.5 → 2.29.7

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 (308) hide show
  1. package/dist/AILabel/index.js +17 -8
  2. package/dist/AgenticLayout/index.js +3 -5
  3. package/dist/BackTo/BackBottom.js +17 -8
  4. package/dist/BackTo/BackTop.js +17 -8
  5. package/dist/BackTo/ScrollVisibleButton.js +75 -11
  6. package/dist/Bubble/AIBubble.js +131 -121
  7. package/dist/Bubble/Avatar/index.js +19 -10
  8. package/dist/Bubble/FileView.js +2 -2
  9. package/dist/Bubble/List/PureBubbleList.js +4 -5
  10. package/dist/Bubble/List/index.js +4 -5
  11. package/dist/Bubble/List/style.js +3 -0
  12. package/dist/Bubble/MessagesContent/BubbleExtra.js +108 -93
  13. package/dist/Bubble/MessagesContent/CopyButton/index.js +36 -26
  14. package/dist/Bubble/MessagesContent/DocInfo.js +19 -10
  15. package/dist/Bubble/MessagesContent/MarkdownPreview.js +2 -2
  16. package/dist/Bubble/MessagesContent/index.js +149 -130
  17. package/dist/Bubble/PureBubble.js +151 -133
  18. package/dist/Bubble/UserBubble.js +1 -1
  19. package/dist/Bubble/style.js +2 -2
  20. package/dist/Bubble/types/BubbleExtra.js +4 -1
  21. package/dist/Bubble/types/DocInfo.js +9 -1
  22. package/dist/ChatLayout/components/FooterBackgroundLottie/images/img_0.png +0 -0
  23. package/dist/ChatLayout/components/FooterBackgroundLottie/images/img_1.png +0 -0
  24. package/dist/ChatLayout/components/FooterBackgroundLottie/images/img_2.png +0 -0
  25. package/dist/ChatLayout/components/FooterBackgroundLottie/index.d.ts +51 -0
  26. package/dist/ChatLayout/components/FooterBackgroundLottie/index.js +45 -0
  27. package/dist/ChatLayout/components/FooterBackgroundLottie/lottie.d.ts +85 -0
  28. package/dist/ChatLayout/components/FooterBackgroundLottie/lottie.js +382 -0
  29. package/dist/ChatLayout/index.js +52 -14
  30. package/dist/ChatLayout/style.js +11 -0
  31. package/dist/ChatLayout/types.d.ts +28 -0
  32. package/dist/Components/ActionIconBox/index.js +30 -38
  33. package/dist/Components/ActionItemBox/ActionItemBox.js +1 -1
  34. package/dist/Components/Button/SwitchButton/index.js +18 -17
  35. package/dist/Components/LayoutHeader/index.js +5 -3
  36. package/dist/Components/LayoutHeader/style.js +5 -0
  37. package/dist/Components/Loading/CreativeRecommendationLoading.js +2 -2
  38. package/dist/Components/Loading/CreativeSparkLoading.js +2 -2
  39. package/dist/Components/SuggestionList/index.js +20 -19
  40. package/dist/Components/TextAnimate/index.js +19 -10
  41. package/dist/Components/TypingAnimation/index.js +19 -10
  42. package/dist/Components/effects/EffectPlayer.js +20 -11
  43. package/dist/Components/icons/LoadingSpinnerIcon.js +19 -10
  44. package/dist/History/components/HistoryActionsBox.js +21 -23
  45. package/dist/History/components/HistoryItem.js +61 -53
  46. package/dist/History/components/HistoryRunningIcon.js +19 -10
  47. package/dist/History/components/LoadMoreComponent.js +61 -55
  48. package/dist/History/components/NewChatComponent.js +53 -47
  49. package/dist/History/components/SearchComponent.js +24 -26
  50. package/dist/History/hooks/useHistory.js +80 -73
  51. package/dist/History/index.js +17 -16
  52. package/dist/History/menu.js +17 -8
  53. package/dist/Hooks/useAutoScroll.js +19 -19
  54. package/dist/Hooks/useDebounceFn/index.js +51 -45
  55. package/dist/Hooks/useElementSize.d.ts +5 -0
  56. package/dist/Hooks/useElementSize.js +71 -0
  57. package/dist/Hooks/useIntersectionOnce.js +17 -8
  58. package/dist/Hooks/useLanguage.d.ts +3 -0
  59. package/dist/I18n/locales.d.ts +3 -0
  60. package/dist/I18n/locales.js +8 -0
  61. package/dist/MarkdownEditor/BaseMarkdownEditor.js +22 -12
  62. package/dist/MarkdownEditor/editor/Editor.js +31 -39
  63. package/dist/MarkdownEditor/editor/components/CommentList/index.js +29 -37
  64. package/dist/MarkdownEditor/editor/elements/Image/index.js +86 -71
  65. package/dist/MarkdownEditor/editor/elements/List/ListItem.js +17 -16
  66. package/dist/MarkdownEditor/editor/elements/Media/index.js +107 -92
  67. package/dist/MarkdownEditor/editor/elements/Table/Table.js +19 -10
  68. package/dist/MarkdownEditor/editor/elements/TagPopup/index.js +17 -16
  69. package/dist/MarkdownEditor/editor/parser/parse/parseBlockElements.js +1 -1
  70. package/dist/MarkdownEditor/editor/parser/parse/parseCode.js +1 -1
  71. package/dist/MarkdownEditor/editor/parser/parse/parseEmptyLines.js +1 -1
  72. package/dist/MarkdownEditor/editor/parser/parse/parseTable.js +4 -1
  73. package/dist/MarkdownEditor/editor/parser/parserSlateNodeToMarkdown.js +2 -2
  74. package/dist/MarkdownEditor/editor/parser/remarkParse.js +3 -1
  75. package/dist/MarkdownEditor/editor/plugins/handlePaste.js +25 -30
  76. package/dist/MarkdownEditor/editor/plugins/hotKeyCommands/arrow.js +0 -1
  77. package/dist/MarkdownEditor/editor/plugins/hotKeyCommands/enter.js +0 -1
  78. package/dist/MarkdownEditor/editor/plugins/hotKeyCommands/match.js +0 -1
  79. package/dist/MarkdownEditor/editor/plugins/hotKeyCommands/tab.js +0 -1
  80. package/dist/MarkdownEditor/editor/plugins/insertParsedHtmlNodes.js +39 -53
  81. package/dist/MarkdownEditor/editor/plugins/useKeyboard.js +1 -1
  82. package/dist/MarkdownEditor/editor/plugins/useOnchange.js +28 -22
  83. package/dist/MarkdownEditor/editor/plugins/withMarkdown.js +1 -1
  84. package/dist/MarkdownEditor/editor/store.js +17 -13
  85. package/dist/MarkdownEditor/editor/tools/InsertAutocomplete.js +202 -197
  86. package/dist/MarkdownEditor/editor/tools/InsertLink.js +2 -2
  87. package/dist/MarkdownEditor/editor/tools/ToolBar/ReadonlyBaseBar.js +142 -134
  88. package/dist/MarkdownEditor/editor/utils/ace.js +61 -61
  89. package/dist/MarkdownEditor/editor/utils/editorUtils.js +11 -4
  90. package/dist/MarkdownEditor/editor/utils/index.js +8 -2
  91. package/dist/MarkdownEditor/editor/utils/keyboard.js +31 -35
  92. package/dist/MarkdownEditor/editor/utils/markdownToHtml.js +23 -17
  93. package/dist/MarkdownEditor/editor/utils/media.js +21 -23
  94. package/dist/MarkdownEditor/editor/utils/performanceMonitor.js +55 -50
  95. package/dist/MarkdownEditor/editor/utils/useLocalState.js +11 -4
  96. package/dist/MarkdownEditor/types.d.ts +1 -0
  97. package/dist/MarkdownEditor/types.js +4 -1
  98. package/dist/MarkdownEditor/utils/native-table/native-table-editor.js +14 -14
  99. package/dist/MarkdownEditor/utils/native-table/native-table-keyboard.js +2 -2
  100. package/dist/MarkdownInputField/AttachmentButton/AttachmentFileList/style.js +1 -0
  101. package/dist/MarkdownInputField/AttachmentButton/index.js +33 -31
  102. package/dist/MarkdownInputField/BeforeToolContainer/BeforeToolContainer.js +14 -7
  103. package/dist/MarkdownInputField/FileMapView/FileMapViewItem.js +2 -2
  104. package/dist/MarkdownInputField/FileMapView/index.js +17 -16
  105. package/dist/MarkdownInputField/FilePaste/index.js +25 -30
  106. package/dist/MarkdownInputField/FileUploadManager/index.js +39 -40
  107. package/dist/MarkdownInputField/MarkdownInputField.js +38 -29
  108. package/dist/MarkdownInputField/QuickActions/index.js +66 -60
  109. package/dist/MarkdownInputField/SendButton/index.js +22 -13
  110. package/dist/MarkdownInputField/Suggestion/index.js +17 -16
  111. package/dist/MarkdownInputField/VoiceInput/index.js +51 -45
  112. package/dist/MarkdownInputField/VoiceInputManager/index.js +133 -125
  113. package/dist/MarkdownInputField/hooks/useMarkdownInputFieldHandlers.js +103 -101
  114. package/dist/MarkdownInputField/hooks/useMarkdownInputFieldStyles.js +1 -1
  115. package/dist/MarkdownInputField/style.js +1 -2
  116. package/dist/MarkdownInputField/types/MarkdownInputFieldProps.js +14 -1
  117. package/dist/Plugins/chart/BarChart/index.js +8 -8
  118. package/dist/Plugins/chart/ChartRender.js +52 -46
  119. package/dist/Plugins/chart/DonutChart/index.js +26 -17
  120. package/dist/Plugins/chart/DonutChart/plugins.js +1 -1
  121. package/dist/Plugins/chart/DonutChart/types.js +1 -1
  122. package/dist/Plugins/chart/FunnelChart/index.js +31 -28
  123. package/dist/Plugins/chart/LineChart/index.js +19 -10
  124. package/dist/Plugins/chart/RadarChart/index.js +19 -10
  125. package/dist/Plugins/chart/ScatterChart/index.js +19 -10
  126. package/dist/Plugins/chart/components/ChartContainer/ChartContainer.js +20 -11
  127. package/dist/Plugins/chart/index.js +31 -13
  128. package/dist/Plugins/chart/loadChartRuntime.js +17 -16
  129. package/dist/Plugins/chart/types/classNames.js +4 -1
  130. package/dist/Plugins/chart/utils.js +20 -20
  131. package/dist/Plugins/code/CodeUI/Katex/Katex.js +52 -46
  132. package/dist/Plugins/code/components/AceEditor.js +149 -133
  133. package/dist/Plugins/code/components/CodeRenderer.js +7 -7
  134. package/dist/Plugins/code/components/CodeToolbar.js +2 -2
  135. package/dist/Plugins/code/components/LanguageSelector.js +6 -6
  136. package/dist/Plugins/code/components/LoadImage.js +5 -5
  137. package/dist/Plugins/code/components/ThinkBlock.js +8 -8
  138. package/dist/Plugins/code/hooks/useCodeEditorState.js +5 -5
  139. package/dist/Plugins/code/index.js +6 -6
  140. package/dist/Plugins/code/langIconMap.js +0 -1
  141. package/dist/Plugins/code/langIcons/AbapIcon.js +19 -10
  142. package/dist/Plugins/code/langIcons/ActionscriptIcon.js +19 -10
  143. package/dist/Plugins/code/langIcons/AdaIcon.js +19 -10
  144. package/dist/Plugins/code/langIcons/ApacheIcon.js +19 -10
  145. package/dist/Plugins/code/langIcons/ApexIcon.js +19 -10
  146. package/dist/Plugins/code/langIcons/AplIcon.js +19 -10
  147. package/dist/Plugins/code/langIcons/ApplescriptIcon.js +19 -10
  148. package/dist/Plugins/code/langIcons/AstroIcon.js +19 -10
  149. package/dist/Plugins/code/langIcons/AwkIcon.js +19 -10
  150. package/dist/Plugins/code/langIcons/BallerinaIcon.js +19 -10
  151. package/dist/Plugins/code/langIcons/BatIcon.js +19 -10
  152. package/dist/Plugins/code/langIcons/BicepIcon.js +19 -10
  153. package/dist/Plugins/code/langIcons/BladeIcon.js +19 -10
  154. package/dist/Plugins/code/langIcons/CIcon.js +19 -10
  155. package/dist/Plugins/code/langIcons/CadenceIcon.js +19 -10
  156. package/dist/Plugins/code/langIcons/ClojureIcon.js +19 -10
  157. package/dist/Plugins/code/langIcons/CmakeIcon.js +19 -10
  158. package/dist/Plugins/code/langIcons/CobolIcon.js +19 -10
  159. package/dist/Plugins/code/langIcons/CodeqlIcon.js +19 -10
  160. package/dist/Plugins/code/langIcons/CoffeeIcon.js +19 -10
  161. package/dist/Plugins/code/langIcons/ConsoleIcon.js +19 -10
  162. package/dist/Plugins/code/langIcons/CppIcon.js +19 -10
  163. package/dist/Plugins/code/langIcons/CrystalIcon.js +19 -10
  164. package/dist/Plugins/code/langIcons/CsharpIcon.js +19 -10
  165. package/dist/Plugins/code/langIcons/CssIcon.js +19 -10
  166. package/dist/Plugins/code/langIcons/DIcon.js +19 -10
  167. package/dist/Plugins/code/langIcons/DartIcon.js +19 -10
  168. package/dist/Plugins/code/langIcons/DatabaseIcon.js +19 -10
  169. package/dist/Plugins/code/langIcons/DiffIcon.js +19 -10
  170. package/dist/Plugins/code/langIcons/DockerIcon.js +19 -10
  171. package/dist/Plugins/code/langIcons/DotenvIcon.js +19 -10
  172. package/dist/Plugins/code/langIcons/ElixirIcon.js +19 -10
  173. package/dist/Plugins/code/langIcons/ElmIcon.js +19 -10
  174. package/dist/Plugins/code/langIcons/ErbIcon.js +19 -10
  175. package/dist/Plugins/code/langIcons/ErlangIcon.js +19 -10
  176. package/dist/Plugins/code/langIcons/FsharpIcon.js +19 -10
  177. package/dist/Plugins/code/langIcons/GdscriptIcon.js +19 -10
  178. package/dist/Plugins/code/langIcons/GlslIcon.js +19 -10
  179. package/dist/Plugins/code/langIcons/GnuplotIcon.js +19 -10
  180. package/dist/Plugins/code/langIcons/GoIcon.js +19 -10
  181. package/dist/Plugins/code/langIcons/GraphqlIcon.js +19 -10
  182. package/dist/Plugins/code/langIcons/GroovyIcon.js +19 -10
  183. package/dist/Plugins/code/langIcons/HackIcon.js +19 -10
  184. package/dist/Plugins/code/langIcons/HamlIcon.js +19 -10
  185. package/dist/Plugins/code/langIcons/HandlebarsIcon.js +19 -10
  186. package/dist/Plugins/code/langIcons/HaskellIcon.js +19 -10
  187. package/dist/Plugins/code/langIcons/HclIcon.js +19 -10
  188. package/dist/Plugins/code/langIcons/HclLightIcon.js +19 -10
  189. package/dist/Plugins/code/langIcons/HjsonIcon.js +19 -10
  190. package/dist/Plugins/code/langIcons/HlslIcon.js +19 -10
  191. package/dist/Plugins/code/langIcons/HtmlIcon.js +19 -10
  192. package/dist/Plugins/code/langIcons/HttpIcon.js +19 -10
  193. package/dist/Plugins/code/langIcons/ImbaIcon.js +19 -10
  194. package/dist/Plugins/code/langIcons/IniIcon.js +19 -10
  195. package/dist/Plugins/code/langIcons/JavaIcon.js +19 -10
  196. package/dist/Plugins/code/langIcons/JavascriptIcon.js +19 -10
  197. package/dist/Plugins/code/langIcons/JinjaIcon.js +19 -10
  198. package/dist/Plugins/code/langIcons/Json5Icon.js +19 -10
  199. package/dist/Plugins/code/langIcons/JsonIcon.js +19 -10
  200. package/dist/Plugins/code/langIcons/JsonnetIcon.js +19 -10
  201. package/dist/Plugins/code/langIcons/JuliaIcon.js +19 -10
  202. package/dist/Plugins/code/langIcons/KotlinIcon.js +19 -10
  203. package/dist/Plugins/code/langIcons/KustoIcon.js +19 -10
  204. package/dist/Plugins/code/langIcons/LessIcon.js +19 -10
  205. package/dist/Plugins/code/langIcons/LiquidIcon.js +19 -10
  206. package/dist/Plugins/code/langIcons/LispIcon.js +19 -10
  207. package/dist/Plugins/code/langIcons/LuaIcon.js +19 -10
  208. package/dist/Plugins/code/langIcons/MakefileIcon.js +19 -10
  209. package/dist/Plugins/code/langIcons/MarkdownIcon.js +19 -10
  210. package/dist/Plugins/code/langIcons/MarkojsIcon.js +19 -10
  211. package/dist/Plugins/code/langIcons/MatlabIcon.js +19 -10
  212. package/dist/Plugins/code/langIcons/MdxIcon.js +19 -10
  213. package/dist/Plugins/code/langIcons/MermaidIcon.js +19 -10
  214. package/dist/Plugins/code/langIcons/MojoIcon.js +19 -10
  215. package/dist/Plugins/code/langIcons/NginxIcon.js +19 -10
  216. package/dist/Plugins/code/langIcons/NimIcon.js +19 -10
  217. package/dist/Plugins/code/langIcons/NixIcon.js +19 -10
  218. package/dist/Plugins/code/langIcons/ObjectiveCIcon.js +19 -10
  219. package/dist/Plugins/code/langIcons/ObjectiveCppIcon.js +19 -10
  220. package/dist/Plugins/code/langIcons/OcamlIcon.js +19 -10
  221. package/dist/Plugins/code/langIcons/PascalIcon.js +19 -10
  222. package/dist/Plugins/code/langIcons/Perl6Icon.js +19 -10
  223. package/dist/Plugins/code/langIcons/PerlIcon.js +19 -10
  224. package/dist/Plugins/code/langIcons/PhpIcon.js +19 -10
  225. package/dist/Plugins/code/langIcons/PostcssIcon.js +19 -10
  226. package/dist/Plugins/code/langIcons/PowershellIcon.js +19 -10
  227. package/dist/Plugins/code/langIcons/PrismaIcon.js +19 -10
  228. package/dist/Plugins/code/langIcons/PrologIcon.js +19 -10
  229. package/dist/Plugins/code/langIcons/ProtoIcon.js +19 -10
  230. package/dist/Plugins/code/langIcons/PugIcon.js +19 -10
  231. package/dist/Plugins/code/langIcons/PuppetIcon.js +19 -10
  232. package/dist/Plugins/code/langIcons/PurescriptIcon.js +19 -10
  233. package/dist/Plugins/code/langIcons/PythonIcon.js +19 -10
  234. package/dist/Plugins/code/langIcons/RIcon.js +19 -10
  235. package/dist/Plugins/code/langIcons/RazorIcon.js +19 -10
  236. package/dist/Plugins/code/langIcons/ReactIcon.js +19 -10
  237. package/dist/Plugins/code/langIcons/ReactTsIcon.js +19 -10
  238. package/dist/Plugins/code/langIcons/RubyIcon.js +19 -10
  239. package/dist/Plugins/code/langIcons/RustIcon.js +19 -10
  240. package/dist/Plugins/code/langIcons/SasIcon.js +19 -10
  241. package/dist/Plugins/code/langIcons/SassIcon.js +19 -10
  242. package/dist/Plugins/code/langIcons/ScalaIcon.js +19 -10
  243. package/dist/Plugins/code/langIcons/SchemeIcon.js +19 -10
  244. package/dist/Plugins/code/langIcons/ShaderlabIcon.js +19 -10
  245. package/dist/Plugins/code/langIcons/SolidityIcon.js +19 -10
  246. package/dist/Plugins/code/langIcons/SparqlIcon.js +19 -10
  247. package/dist/Plugins/code/langIcons/StataIcon.js +19 -10
  248. package/dist/Plugins/code/langIcons/StylusIcon.js +19 -10
  249. package/dist/Plugins/code/langIcons/SvelteIcon.js +19 -10
  250. package/dist/Plugins/code/langIcons/SwiftIcon.js +19 -10
  251. package/dist/Plugins/code/langIcons/SystemverilogIcon.js +19 -10
  252. package/dist/Plugins/code/langIcons/TclIcon.js +19 -10
  253. package/dist/Plugins/code/langIcons/TexIcon.js +19 -10
  254. package/dist/Plugins/code/langIcons/TomlIcon.js +19 -10
  255. package/dist/Plugins/code/langIcons/TwigIcon.js +19 -10
  256. package/dist/Plugins/code/langIcons/TypescriptIcon.js +19 -10
  257. package/dist/Plugins/code/langIcons/VerilogIcon.js +19 -10
  258. package/dist/Plugins/code/langIcons/VhdlIcon.js +19 -10
  259. package/dist/Plugins/code/langIcons/VimIcon.js +19 -10
  260. package/dist/Plugins/code/langIcons/VueIcon.js +19 -10
  261. package/dist/Plugins/code/langIcons/WebassemblyIcon.js +19 -10
  262. package/dist/Plugins/code/langIcons/WenyanIcon.js +19 -10
  263. package/dist/Plugins/code/langIcons/WgslIcon.js +19 -10
  264. package/dist/Plugins/code/langIcons/WolframlanguageIcon.js +19 -10
  265. package/dist/Plugins/code/langIcons/XmlIcon.js +19 -10
  266. package/dist/Plugins/code/langIcons/XslIcon.js +19 -10
  267. package/dist/Plugins/code/langIcons/YamlIcon.js +19 -10
  268. package/dist/Plugins/code/langIcons/ZigIcon.js +19 -10
  269. package/dist/Plugins/code/loadAceEditor.js +21 -23
  270. package/dist/Plugins/code/utils/langOptions.js +6 -6
  271. package/dist/Plugins/formatter/index.js +6 -6
  272. package/dist/Plugins/katex/InlineKatex.js +52 -46
  273. package/dist/Plugins/katex/Katex.js +53 -47
  274. package/dist/Plugins/katex/index.js +6 -6
  275. package/dist/Plugins/katex/loadKatex.js +27 -29
  276. package/dist/Plugins/mermaid/Mermaid.js +34 -28
  277. package/dist/Plugins/mermaid/useMermaidRender.js +103 -97
  278. package/dist/Plugins/mermaid/utils.js +25 -17
  279. package/dist/Schema/SchemaEditor/AceEditorWrapper.js +162 -150
  280. package/dist/Schema/SchemaEditor/index.js +8 -1
  281. package/dist/Schema/SchemaForm/index.js +2 -2
  282. package/dist/Schema/SchemaRenderer/index.js +45 -46
  283. package/dist/ThoughtChainList/index.js +22 -13
  284. package/dist/ToolUseBar/BarItem/Content.js +3 -3
  285. package/dist/ToolUseBar/BarItem/index.js +10 -3
  286. package/dist/ToolUseBar/index.js +19 -10
  287. package/dist/ToolUseBar/style.js +4 -4
  288. package/dist/Types/common.js +4 -1
  289. package/dist/Types/message.js +4 -1
  290. package/dist/Utils/debugUtils.js +8 -8
  291. package/dist/Utils/getScroll.js +12 -5
  292. package/dist/Utils/loadCSS.js +23 -22
  293. package/dist/Utils/proxySandbox/ProxySandbox.js +42 -34
  294. package/dist/Utils/proxySandbox/SecurityContextManager.js +54 -54
  295. package/dist/Utils/proxySandbox/index.js +25 -22
  296. package/dist/Utils/proxySandbox/types.js +11 -11
  297. package/dist/Utils/scrollTo.js +8 -1
  298. package/dist/WelcomeMessage/index.js +1 -1
  299. package/dist/Workspace/File/FileComponent.js +91 -66
  300. package/dist/Workspace/File/PreviewComponent.js +15 -8
  301. package/dist/Workspace/File/index.d.ts +1 -1
  302. package/dist/Workspace/File/style.js +7 -0
  303. package/dist/Workspace/RealtimeFollow/index.js +1 -2
  304. package/dist/Workspace/index.js +13 -11
  305. package/dist/Workspace/style.js +8 -14
  306. package/dist/Workspace/types.d.ts +50 -0
  307. package/dist/Workspace/types.js +0 -1
  308. package/package.json +25 -25
@@ -52,12 +52,22 @@ function _object_spread_props(target, source) {
52
52
  }
53
53
  function _object_without_properties(source, excluded) {
54
54
  if (source == null) return {};
55
- var target = _object_without_properties_loose(source, excluded);
56
- var key, i;
55
+ var target = {}, sourceKeys, key, i;
56
+ if (typeof Reflect !== "undefined" && Reflect.ownKeys) {
57
+ sourceKeys = Reflect.ownKeys(source);
58
+ for(i = 0; i < sourceKeys.length; i++){
59
+ key = sourceKeys[i];
60
+ if (excluded.indexOf(key) >= 0) continue;
61
+ if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
62
+ target[key] = source[key];
63
+ }
64
+ return target;
65
+ }
66
+ target = _object_without_properties_loose(source, excluded);
57
67
  if (Object.getOwnPropertySymbols) {
58
- var sourceSymbolKeys = Object.getOwnPropertySymbols(source);
59
- for(i = 0; i < sourceSymbolKeys.length; i++){
60
- key = sourceSymbolKeys[i];
68
+ sourceKeys = Object.getOwnPropertySymbols(source);
69
+ for(i = 0; i < sourceKeys.length; i++){
70
+ key = sourceKeys[i];
61
71
  if (excluded.indexOf(key) >= 0) continue;
62
72
  if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
63
73
  target[key] = source[key];
@@ -67,19 +77,18 @@ function _object_without_properties(source, excluded) {
67
77
  }
68
78
  function _object_without_properties_loose(source, excluded) {
69
79
  if (source == null) return {};
70
- var target = {};
71
- var sourceKeys = Object.keys(source);
72
- var key, i;
80
+ var target = {}, sourceKeys = Object.getOwnPropertyNames(source), key, i;
73
81
  for(i = 0; i < sourceKeys.length; i++){
74
82
  key = sourceKeys[i];
75
83
  if (excluded.indexOf(key) >= 0) continue;
84
+ if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
76
85
  target[key] = source[key];
77
86
  }
78
87
  return target;
79
88
  }
80
89
  import React from "react";
81
- export var WenyanIcon = function(_param) {
82
- var _param_size = _param.size, size = _param_size === void 0 ? 24 : _param_size, props = _object_without_properties(_param, [
90
+ export var WenyanIcon = function(_0) {
91
+ var _0_size = _0.size, size = _0_size === void 0 ? 24 : _0_size, props = _object_without_properties(_0, [
83
92
  "size"
84
93
  ]);
85
94
  return /*#__PURE__*/ React.createElement("svg", _object_spread_props(_object_spread({
@@ -52,12 +52,22 @@ function _object_spread_props(target, source) {
52
52
  }
53
53
  function _object_without_properties(source, excluded) {
54
54
  if (source == null) return {};
55
- var target = _object_without_properties_loose(source, excluded);
56
- var key, i;
55
+ var target = {}, sourceKeys, key, i;
56
+ if (typeof Reflect !== "undefined" && Reflect.ownKeys) {
57
+ sourceKeys = Reflect.ownKeys(source);
58
+ for(i = 0; i < sourceKeys.length; i++){
59
+ key = sourceKeys[i];
60
+ if (excluded.indexOf(key) >= 0) continue;
61
+ if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
62
+ target[key] = source[key];
63
+ }
64
+ return target;
65
+ }
66
+ target = _object_without_properties_loose(source, excluded);
57
67
  if (Object.getOwnPropertySymbols) {
58
- var sourceSymbolKeys = Object.getOwnPropertySymbols(source);
59
- for(i = 0; i < sourceSymbolKeys.length; i++){
60
- key = sourceSymbolKeys[i];
68
+ sourceKeys = Object.getOwnPropertySymbols(source);
69
+ for(i = 0; i < sourceKeys.length; i++){
70
+ key = sourceKeys[i];
61
71
  if (excluded.indexOf(key) >= 0) continue;
62
72
  if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
63
73
  target[key] = source[key];
@@ -67,19 +77,18 @@ function _object_without_properties(source, excluded) {
67
77
  }
68
78
  function _object_without_properties_loose(source, excluded) {
69
79
  if (source == null) return {};
70
- var target = {};
71
- var sourceKeys = Object.keys(source);
72
- var key, i;
80
+ var target = {}, sourceKeys = Object.getOwnPropertyNames(source), key, i;
73
81
  for(i = 0; i < sourceKeys.length; i++){
74
82
  key = sourceKeys[i];
75
83
  if (excluded.indexOf(key) >= 0) continue;
84
+ if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
76
85
  target[key] = source[key];
77
86
  }
78
87
  return target;
79
88
  }
80
89
  import React from "react";
81
- export var WgslIcon = function(_param) {
82
- var _param_size = _param.size, size = _param_size === void 0 ? '1em' : _param_size, props = _object_without_properties(_param, [
90
+ export var WgslIcon = function(_0) {
91
+ var _0_size = _0.size, size = _0_size === void 0 ? '1em' : _0_size, props = _object_without_properties(_0, [
83
92
  "size"
84
93
  ]);
85
94
  return /*#__PURE__*/ React.createElement("svg", _object_spread_props(_object_spread({
@@ -52,12 +52,22 @@ function _object_spread_props(target, source) {
52
52
  }
53
53
  function _object_without_properties(source, excluded) {
54
54
  if (source == null) return {};
55
- var target = _object_without_properties_loose(source, excluded);
56
- var key, i;
55
+ var target = {}, sourceKeys, key, i;
56
+ if (typeof Reflect !== "undefined" && Reflect.ownKeys) {
57
+ sourceKeys = Reflect.ownKeys(source);
58
+ for(i = 0; i < sourceKeys.length; i++){
59
+ key = sourceKeys[i];
60
+ if (excluded.indexOf(key) >= 0) continue;
61
+ if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
62
+ target[key] = source[key];
63
+ }
64
+ return target;
65
+ }
66
+ target = _object_without_properties_loose(source, excluded);
57
67
  if (Object.getOwnPropertySymbols) {
58
- var sourceSymbolKeys = Object.getOwnPropertySymbols(source);
59
- for(i = 0; i < sourceSymbolKeys.length; i++){
60
- key = sourceSymbolKeys[i];
68
+ sourceKeys = Object.getOwnPropertySymbols(source);
69
+ for(i = 0; i < sourceKeys.length; i++){
70
+ key = sourceKeys[i];
61
71
  if (excluded.indexOf(key) >= 0) continue;
62
72
  if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
63
73
  target[key] = source[key];
@@ -67,19 +77,18 @@ function _object_without_properties(source, excluded) {
67
77
  }
68
78
  function _object_without_properties_loose(source, excluded) {
69
79
  if (source == null) return {};
70
- var target = {};
71
- var sourceKeys = Object.keys(source);
72
- var key, i;
80
+ var target = {}, sourceKeys = Object.getOwnPropertyNames(source), key, i;
73
81
  for(i = 0; i < sourceKeys.length; i++){
74
82
  key = sourceKeys[i];
75
83
  if (excluded.indexOf(key) >= 0) continue;
84
+ if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
76
85
  target[key] = source[key];
77
86
  }
78
87
  return target;
79
88
  }
80
89
  import React from "react";
81
- export var WolframlanguageIcon = function(_param) {
82
- var _param_size = _param.size, size = _param_size === void 0 ? 24 : _param_size, props = _object_without_properties(_param, [
90
+ export var WolframlanguageIcon = function(_0) {
91
+ var _0_size = _0.size, size = _0_size === void 0 ? 24 : _0_size, props = _object_without_properties(_0, [
83
92
  "size"
84
93
  ]);
85
94
  return /*#__PURE__*/ React.createElement("svg", _object_spread_props(_object_spread({
@@ -52,12 +52,22 @@ function _object_spread_props(target, source) {
52
52
  }
53
53
  function _object_without_properties(source, excluded) {
54
54
  if (source == null) return {};
55
- var target = _object_without_properties_loose(source, excluded);
56
- var key, i;
55
+ var target = {}, sourceKeys, key, i;
56
+ if (typeof Reflect !== "undefined" && Reflect.ownKeys) {
57
+ sourceKeys = Reflect.ownKeys(source);
58
+ for(i = 0; i < sourceKeys.length; i++){
59
+ key = sourceKeys[i];
60
+ if (excluded.indexOf(key) >= 0) continue;
61
+ if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
62
+ target[key] = source[key];
63
+ }
64
+ return target;
65
+ }
66
+ target = _object_without_properties_loose(source, excluded);
57
67
  if (Object.getOwnPropertySymbols) {
58
- var sourceSymbolKeys = Object.getOwnPropertySymbols(source);
59
- for(i = 0; i < sourceSymbolKeys.length; i++){
60
- key = sourceSymbolKeys[i];
68
+ sourceKeys = Object.getOwnPropertySymbols(source);
69
+ for(i = 0; i < sourceKeys.length; i++){
70
+ key = sourceKeys[i];
61
71
  if (excluded.indexOf(key) >= 0) continue;
62
72
  if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
63
73
  target[key] = source[key];
@@ -67,19 +77,18 @@ function _object_without_properties(source, excluded) {
67
77
  }
68
78
  function _object_without_properties_loose(source, excluded) {
69
79
  if (source == null) return {};
70
- var target = {};
71
- var sourceKeys = Object.keys(source);
72
- var key, i;
80
+ var target = {}, sourceKeys = Object.getOwnPropertyNames(source), key, i;
73
81
  for(i = 0; i < sourceKeys.length; i++){
74
82
  key = sourceKeys[i];
75
83
  if (excluded.indexOf(key) >= 0) continue;
84
+ if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
76
85
  target[key] = source[key];
77
86
  }
78
87
  return target;
79
88
  }
80
89
  import React from "react";
81
- export var XmlIcon = function(_param) {
82
- var _param_size = _param.size, size = _param_size === void 0 ? '1em' : _param_size, props = _object_without_properties(_param, [
90
+ export var XmlIcon = function(_0) {
91
+ var _0_size = _0.size, size = _0_size === void 0 ? '1em' : _0_size, props = _object_without_properties(_0, [
83
92
  "size"
84
93
  ]);
85
94
  return /*#__PURE__*/ React.createElement("svg", _object_spread_props(_object_spread({
@@ -52,12 +52,22 @@ function _object_spread_props(target, source) {
52
52
  }
53
53
  function _object_without_properties(source, excluded) {
54
54
  if (source == null) return {};
55
- var target = _object_without_properties_loose(source, excluded);
56
- var key, i;
55
+ var target = {}, sourceKeys, key, i;
56
+ if (typeof Reflect !== "undefined" && Reflect.ownKeys) {
57
+ sourceKeys = Reflect.ownKeys(source);
58
+ for(i = 0; i < sourceKeys.length; i++){
59
+ key = sourceKeys[i];
60
+ if (excluded.indexOf(key) >= 0) continue;
61
+ if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
62
+ target[key] = source[key];
63
+ }
64
+ return target;
65
+ }
66
+ target = _object_without_properties_loose(source, excluded);
57
67
  if (Object.getOwnPropertySymbols) {
58
- var sourceSymbolKeys = Object.getOwnPropertySymbols(source);
59
- for(i = 0; i < sourceSymbolKeys.length; i++){
60
- key = sourceSymbolKeys[i];
68
+ sourceKeys = Object.getOwnPropertySymbols(source);
69
+ for(i = 0; i < sourceKeys.length; i++){
70
+ key = sourceKeys[i];
61
71
  if (excluded.indexOf(key) >= 0) continue;
62
72
  if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
63
73
  target[key] = source[key];
@@ -67,19 +77,18 @@ function _object_without_properties(source, excluded) {
67
77
  }
68
78
  function _object_without_properties_loose(source, excluded) {
69
79
  if (source == null) return {};
70
- var target = {};
71
- var sourceKeys = Object.keys(source);
72
- var key, i;
80
+ var target = {}, sourceKeys = Object.getOwnPropertyNames(source), key, i;
73
81
  for(i = 0; i < sourceKeys.length; i++){
74
82
  key = sourceKeys[i];
75
83
  if (excluded.indexOf(key) >= 0) continue;
84
+ if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
76
85
  target[key] = source[key];
77
86
  }
78
87
  return target;
79
88
  }
80
89
  import React from "react";
81
- export var XslIcon = function(_param) {
82
- var _param_size = _param.size, size = _param_size === void 0 ? '1em' : _param_size, props = _object_without_properties(_param, [
90
+ export var XslIcon = function(_0) {
91
+ var _0_size = _0.size, size = _0_size === void 0 ? '1em' : _0_size, props = _object_without_properties(_0, [
83
92
  "size"
84
93
  ]);
85
94
  return /*#__PURE__*/ React.createElement("svg", _object_spread_props(_object_spread({
@@ -52,12 +52,22 @@ function _object_spread_props(target, source) {
52
52
  }
53
53
  function _object_without_properties(source, excluded) {
54
54
  if (source == null) return {};
55
- var target = _object_without_properties_loose(source, excluded);
56
- var key, i;
55
+ var target = {}, sourceKeys, key, i;
56
+ if (typeof Reflect !== "undefined" && Reflect.ownKeys) {
57
+ sourceKeys = Reflect.ownKeys(source);
58
+ for(i = 0; i < sourceKeys.length; i++){
59
+ key = sourceKeys[i];
60
+ if (excluded.indexOf(key) >= 0) continue;
61
+ if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
62
+ target[key] = source[key];
63
+ }
64
+ return target;
65
+ }
66
+ target = _object_without_properties_loose(source, excluded);
57
67
  if (Object.getOwnPropertySymbols) {
58
- var sourceSymbolKeys = Object.getOwnPropertySymbols(source);
59
- for(i = 0; i < sourceSymbolKeys.length; i++){
60
- key = sourceSymbolKeys[i];
68
+ sourceKeys = Object.getOwnPropertySymbols(source);
69
+ for(i = 0; i < sourceKeys.length; i++){
70
+ key = sourceKeys[i];
61
71
  if (excluded.indexOf(key) >= 0) continue;
62
72
  if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
63
73
  target[key] = source[key];
@@ -67,19 +77,18 @@ function _object_without_properties(source, excluded) {
67
77
  }
68
78
  function _object_without_properties_loose(source, excluded) {
69
79
  if (source == null) return {};
70
- var target = {};
71
- var sourceKeys = Object.keys(source);
72
- var key, i;
80
+ var target = {}, sourceKeys = Object.getOwnPropertyNames(source), key, i;
73
81
  for(i = 0; i < sourceKeys.length; i++){
74
82
  key = sourceKeys[i];
75
83
  if (excluded.indexOf(key) >= 0) continue;
84
+ if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
76
85
  target[key] = source[key];
77
86
  }
78
87
  return target;
79
88
  }
80
89
  import React from "react";
81
- export var YamlIcon = function(_param) {
82
- var _param_size = _param.size, size = _param_size === void 0 ? '1em' : _param_size, props = _object_without_properties(_param, [
90
+ export var YamlIcon = function(_0) {
91
+ var _0_size = _0.size, size = _0_size === void 0 ? '1em' : _0_size, props = _object_without_properties(_0, [
83
92
  "size"
84
93
  ]);
85
94
  return /*#__PURE__*/ React.createElement("svg", _object_spread_props(_object_spread({
@@ -52,12 +52,22 @@ function _object_spread_props(target, source) {
52
52
  }
53
53
  function _object_without_properties(source, excluded) {
54
54
  if (source == null) return {};
55
- var target = _object_without_properties_loose(source, excluded);
56
- var key, i;
55
+ var target = {}, sourceKeys, key, i;
56
+ if (typeof Reflect !== "undefined" && Reflect.ownKeys) {
57
+ sourceKeys = Reflect.ownKeys(source);
58
+ for(i = 0; i < sourceKeys.length; i++){
59
+ key = sourceKeys[i];
60
+ if (excluded.indexOf(key) >= 0) continue;
61
+ if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
62
+ target[key] = source[key];
63
+ }
64
+ return target;
65
+ }
66
+ target = _object_without_properties_loose(source, excluded);
57
67
  if (Object.getOwnPropertySymbols) {
58
- var sourceSymbolKeys = Object.getOwnPropertySymbols(source);
59
- for(i = 0; i < sourceSymbolKeys.length; i++){
60
- key = sourceSymbolKeys[i];
68
+ sourceKeys = Object.getOwnPropertySymbols(source);
69
+ for(i = 0; i < sourceKeys.length; i++){
70
+ key = sourceKeys[i];
61
71
  if (excluded.indexOf(key) >= 0) continue;
62
72
  if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
63
73
  target[key] = source[key];
@@ -67,19 +77,18 @@ function _object_without_properties(source, excluded) {
67
77
  }
68
78
  function _object_without_properties_loose(source, excluded) {
69
79
  if (source == null) return {};
70
- var target = {};
71
- var sourceKeys = Object.keys(source);
72
- var key, i;
80
+ var target = {}, sourceKeys = Object.getOwnPropertyNames(source), key, i;
73
81
  for(i = 0; i < sourceKeys.length; i++){
74
82
  key = sourceKeys[i];
75
83
  if (excluded.indexOf(key) >= 0) continue;
84
+ if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
76
85
  target[key] = source[key];
77
86
  }
78
87
  return target;
79
88
  }
80
89
  import React from "react";
81
- export var ZigIcon = function(_param) {
82
- var _param_size = _param.size, size = _param_size === void 0 ? '1em' : _param_size, props = _object_without_properties(_param, [
90
+ export var ZigIcon = function(_0) {
91
+ var _0_size = _0.size, size = _0_size === void 0 ? '1em' : _0_size, props = _object_without_properties(_0, [
83
92
  "size"
84
93
  ]);
85
94
  return /*#__PURE__*/ React.createElement("svg", _object_spread_props(_object_spread({
@@ -34,7 +34,7 @@ function _async_to_generator(fn) {
34
34
  };
35
35
  }
36
36
  function _ts_generator(thisArg, body) {
37
- var f, y, t, g, _ = {
37
+ var f, y, t, _ = {
38
38
  label: 0,
39
39
  sent: function() {
40
40
  if (t[0] & 1) throw t[1];
@@ -42,13 +42,17 @@ function _ts_generator(thisArg, body) {
42
42
  },
43
43
  trys: [],
44
44
  ops: []
45
- };
46
- return g = {
47
- next: verb(0),
48
- "throw": verb(1),
49
- "return": verb(2)
50
- }, typeof Symbol === "function" && (g[Symbol.iterator] = function() {
51
- return this;
45
+ }, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype), d = Object.defineProperty;
46
+ return d(g, "next", {
47
+ value: verb(0)
48
+ }), d(g, "throw", {
49
+ value: verb(1)
50
+ }), d(g, "return", {
51
+ value: verb(2)
52
+ }), typeof Symbol === "function" && d(g, Symbol.iterator, {
53
+ value: function() {
54
+ return this;
55
+ }
52
56
  }), g;
53
57
  function verb(n) {
54
58
  return function(v) {
@@ -60,7 +64,7 @@ function _ts_generator(thisArg, body) {
60
64
  }
61
65
  function step(op) {
62
66
  if (f) throw new TypeError("Generator is already executing.");
63
- while(_)try {
67
+ while(g && (g = 0, op[0] && (_ = 0)), _)try {
64
68
  if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
65
69
  if (y = 0, t) op = [
66
70
  op[0] & 2,
@@ -132,8 +136,8 @@ var aceEditorLoader = null;
132
136
  /**
133
137
  * 加载 Ace Editor 核心库
134
138
  * 使用单例模式确保只加载一次
135
- */ export var loadAceEditor = /*#__PURE__*/ function() {
136
- var _ref = _async_to_generator(function() {
139
+ */ export var loadAceEditor = function() {
140
+ return _async_to_generator(function() {
137
141
  return _ts_generator(this, function(_state) {
138
142
  if (typeof window === 'undefined') {
139
143
  throw new Error('Ace Editor 仅在浏览器环境中可用');
@@ -152,16 +156,13 @@ var aceEditorLoader = null;
152
156
  aceEditorLoader
153
157
  ];
154
158
  });
155
- });
156
- return function loadAceEditor() {
157
- return _ref.apply(this, arguments);
158
- };
159
- }();
159
+ })();
160
+ };
160
161
  /**
161
162
  * 加载 Ace Editor 主题
162
163
  * 支持按需加载主题和对应的 CSS,减少初始 bundle 大小
163
- */ export var loadAceTheme = /*#__PURE__*/ function() {
164
- var _ref = _async_to_generator(function(themeName) {
164
+ */ export var loadAceTheme = function(themeName) {
165
+ return _async_to_generator(function() {
165
166
  var error;
166
167
  return _ts_generator(this, function(_state) {
167
168
  switch(_state.label){
@@ -244,11 +245,8 @@ var aceEditorLoader = null;
244
245
  ];
245
246
  }
246
247
  });
247
- });
248
- return function loadAceTheme(themeName) {
249
- return _ref.apply(this, arguments);
250
- };
251
- }();
248
+ })();
249
+ };
252
250
  /**
253
251
  * 预加载 Ace Editor 资源
254
252
  * 使用动态 import 提前开始加载,但不阻塞当前执行
@@ -1,8 +1,4 @@
1
- /**
2
- * @fileoverview 语言选项配置工具
3
- * 生成用于语言选择器的选项数据
4
- * @author Code Plugin Team
5
- */ function _array_like_to_array(arr, len) {
1
+ function _array_like_to_array(arr, len) {
6
2
  if (len == null || len > arr.length) len = arr.length;
7
3
  for(var i = 0, arr2 = new Array(len); i < len; i++)arr2[i] = arr[i];
8
4
  return arr2;
@@ -48,7 +44,11 @@ function _unsupported_iterable_to_array(o, minLen) {
48
44
  if (n === "Map" || n === "Set") return Array.from(n);
49
45
  if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
50
46
  }
51
- import React from "react";
47
+ /**
48
+ * @fileoverview 语言选项配置工具
49
+ * 生成用于语言选择器的选项数据
50
+ * @author Code Plugin Team
51
+ */ import React from "react";
52
52
  import { langIconMap } from "../langIconMap";
53
53
  /**
54
54
  * 语言选择器的选项配置
@@ -1,8 +1,4 @@
1
- /* eslint-disable no-useless-escape */ /**
2
- * 格式化 Markdown 文本
3
- * 1. 规范化段落之间的换行符(确保段落之间只有两个换行符)
4
- * 2. 添加盘古之白(中英文之间添加空格)
5
- */ function _array_like_to_array(arr, len) {
1
+ function _array_like_to_array(arr, len) {
6
2
  if (len == null || len > arr.length) len = arr.length;
7
3
  for(var i = 0, arr2 = new Array(len); i < len; i++)arr2[i] = arr[i];
8
4
  return arr2;
@@ -67,7 +63,11 @@ function _unsupported_iterable_to_array(o, minLen) {
67
63
  if (n === "Map" || n === "Set") return Array.from(n);
68
64
  if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
69
65
  }
70
- export var MarkdownFormatter = /*#__PURE__*/ function() {
66
+ /* eslint-disable no-useless-escape */ /**
67
+ * 格式化 Markdown 文本
68
+ * 1. 规范化段落之间的换行符(确保段落之间只有两个换行符)
69
+ * 2. 添加盘古之白(中英文之间添加空格)
70
+ */ export var MarkdownFormatter = /*#__PURE__*/ function() {
71
71
  "use strict";
72
72
  function MarkdownFormatter() {
73
73
  _class_call_check(this, MarkdownFormatter);
@@ -126,7 +126,7 @@ function _unsupported_iterable_to_array(o, minLen) {
126
126
  if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
127
127
  }
128
128
  function _ts_generator(thisArg, body) {
129
- var f, y, t, g, _ = {
129
+ var f, y, t, _ = {
130
130
  label: 0,
131
131
  sent: function() {
132
132
  if (t[0] & 1) throw t[1];
@@ -134,13 +134,17 @@ function _ts_generator(thisArg, body) {
134
134
  },
135
135
  trys: [],
136
136
  ops: []
137
- };
138
- return g = {
139
- next: verb(0),
140
- "throw": verb(1),
141
- "return": verb(2)
142
- }, typeof Symbol === "function" && (g[Symbol.iterator] = function() {
143
- return this;
137
+ }, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype), d = Object.defineProperty;
138
+ return d(g, "next", {
139
+ value: verb(0)
140
+ }), d(g, "throw", {
141
+ value: verb(1)
142
+ }), d(g, "return", {
143
+ value: verb(2)
144
+ }), typeof Symbol === "function" && d(g, Symbol.iterator, {
145
+ value: function() {
146
+ return this;
147
+ }
144
148
  }), g;
145
149
  function verb(n) {
146
150
  return function(v) {
@@ -152,7 +156,7 @@ function _ts_generator(thisArg, body) {
152
156
  }
153
157
  function step(op) {
154
158
  if (f) throw new TypeError("Generator is already executing.");
155
- while(_)try {
159
+ while(g && (g = 0, op[0] && (_ = 0)), _)try {
156
160
  if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
157
161
  if (y = 0, t) op = [
158
162
  op[0] & 2,
@@ -277,43 +281,45 @@ import { loadKatex } from "./loadKatex";
277
281
  }
278
282
  startTransition(function() {
279
283
  // 异步加载在 startTransition 外部执行
280
- _async_to_generator(function() {
281
- var katexModule, error;
282
- return _ts_generator(this, function(_state) {
283
- switch(_state.label){
284
- case 0:
285
- _state.trys.push([
286
- 0,
287
- 2,
288
- ,
289
- 3
290
- ]);
291
- return [
292
- 4,
293
- loadKatex()
294
- ];
295
- case 1:
296
- katexModule = _state.sent();
297
- katexRef.current = katexModule.default;
298
- setKatexLoaded(true);
299
- return [
300
- 3,
301
- 3
302
- ];
303
- case 2:
304
- error = _state.sent();
305
- console.error('Failed to load Katex:', error);
306
- setKatexLoaded(true);
307
- return [
308
- 3,
309
- 3
310
- ];
311
- case 3:
312
- return [
313
- 2
314
- ];
315
- }
316
- });
284
+ (function() {
285
+ return _async_to_generator(function() {
286
+ var katexModule, error;
287
+ return _ts_generator(this, function(_state) {
288
+ switch(_state.label){
289
+ case 0:
290
+ _state.trys.push([
291
+ 0,
292
+ 2,
293
+ ,
294
+ 3
295
+ ]);
296
+ return [
297
+ 4,
298
+ loadKatex()
299
+ ];
300
+ case 1:
301
+ katexModule = _state.sent();
302
+ katexRef.current = katexModule.default;
303
+ setKatexLoaded(true);
304
+ return [
305
+ 3,
306
+ 3
307
+ ];
308
+ case 2:
309
+ error = _state.sent();
310
+ console.error('Failed to load Katex:', error);
311
+ setKatexLoaded(true);
312
+ return [
313
+ 3,
314
+ 3
315
+ ];
316
+ case 3:
317
+ return [
318
+ 2
319
+ ];
320
+ }
321
+ });
322
+ })();
317
323
  })();
318
324
  });
319
325
  }, []);