sparkdesign 0.4.5 → 0.4.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 (377) hide show
  1. package/AI_README.md +60 -0
  2. package/README.md +74 -22
  3. package/cli/dist/commands/add.js +23 -13
  4. package/cli/dist/commands/diff.js +8 -4
  5. package/cli/dist/commands/init.js +85 -10
  6. package/cli/dist/commands/list.js +8 -4
  7. package/cli/dist/index.js +9 -6
  8. package/cli/dist/utils/config.js +16 -8
  9. package/cli/dist/utils/package-manager.js +75 -0
  10. package/cli/dist/utils/registry.js +8 -4
  11. package/cli/dist/utils/tokens.js +33 -25
  12. package/cli/dist/utils/transform.js +9 -5
  13. package/cli/dist/utils/tsconfig.js +182 -0
  14. package/cli/registry/AGENTS.md +25 -0
  15. package/cli/registry/__tests__/chat/thinking-indicator.test.tsx +2 -2
  16. package/cli/registry/agent-manifest.json +794 -0
  17. package/cli/registry/basic/alert.tsx +76 -0
  18. package/cli/registry/basic/aspect-ratio.tsx +8 -0
  19. package/cli/registry/basic/breadcrumb.tsx +117 -0
  20. package/cli/registry/basic/button-group.tsx +79 -0
  21. package/cli/registry/basic/button.tsx +1 -1
  22. package/cli/registry/basic/calendar.tsx +221 -0
  23. package/cli/registry/basic/card.tsx +103 -0
  24. package/cli/registry/basic/carousel.tsx +241 -0
  25. package/cli/registry/basic/chart.tsx +372 -0
  26. package/cli/registry/basic/checkbox.tsx +42 -0
  27. package/cli/registry/basic/collapsible-card.tsx +2 -2
  28. package/cli/registry/basic/combobox.tsx +75 -0
  29. package/cli/registry/basic/command.tsx +184 -0
  30. package/cli/registry/basic/context-menu.tsx +239 -0
  31. package/cli/registry/basic/data-table.tsx +73 -0
  32. package/cli/registry/basic/date-picker.tsx +13 -0
  33. package/cli/registry/basic/dialog.tsx +169 -0
  34. package/cli/registry/basic/direction.tsx +25 -0
  35. package/cli/registry/basic/drawer.tsx +164 -0
  36. package/cli/registry/basic/dropdown-menu.tsx +0 -4
  37. package/cli/registry/basic/empty.tsx +104 -0
  38. package/cli/registry/basic/field.tsx +248 -0
  39. package/cli/registry/basic/hover-card.tsx +58 -0
  40. package/cli/registry/basic/input-group.tsx +168 -0
  41. package/cli/registry/basic/input-otp.tsx +75 -0
  42. package/cli/registry/basic/input.tsx +27 -0
  43. package/cli/registry/basic/item.tsx +204 -0
  44. package/cli/registry/basic/label.tsx +24 -0
  45. package/cli/registry/basic/menubar.tsx +274 -0
  46. package/cli/registry/basic/native-select.tsx +62 -0
  47. package/cli/registry/basic/navigation-menu.tsx +168 -0
  48. package/cli/registry/basic/popover.tsx +59 -0
  49. package/cli/registry/basic/scroll-area.tsx +58 -0
  50. package/cli/registry/basic/select.tsx +2 -1
  51. package/cli/registry/basic/separator.tsx +26 -0
  52. package/cli/registry/basic/sheet.tsx +18 -0
  53. package/cli/registry/basic/textarea.tsx +25 -0
  54. package/cli/registry/basic/toggle.tsx +1 -1
  55. package/cli/registry/basic/typography.tsx +1 -1
  56. package/cli/registry/chat/chat-input/chat-input-folder-selector.tsx +1 -1
  57. package/cli/registry/chat/chat-input/chat-input-textarea.tsx +1 -1
  58. package/cli/registry/chat/chat-input/compound.tsx +4 -3
  59. package/cli/registry/chat/chat-input/context.tsx +4 -1
  60. package/cli/registry/chat/chat-input/folder-permission-dialog.tsx +2 -2
  61. package/cli/registry/chat/code-block-part.tsx +1 -1
  62. package/cli/registry/chat/conversation-anchor-nav.tsx +349 -0
  63. package/cli/registry/chat/file-attachment.tsx +2 -1
  64. package/cli/registry/chat/file-review-part.tsx +21 -21
  65. package/cli/registry/chat/image-generating.tsx +1 -1
  66. package/cli/registry/chat/markdown.tsx +2 -2
  67. package/cli/registry/chat/queue-indicator.tsx +1 -0
  68. package/cli/registry/chat/response/context.tsx +1 -1
  69. package/cli/registry/chat/streaming-markdown-block.tsx +12 -8
  70. package/cli/registry/chat/thinking-indicator.tsx +1 -1
  71. package/cli/registry/chat/tool-invocation-card.tsx +4 -1
  72. package/cli/registry/lib/file-icon-maps.ts +22 -22
  73. package/cli/registry/meta.json +518 -0
  74. package/cli/registry/tokens/index.css +8 -5
  75. package/cli/registry/tokens/ontology.json +404 -0
  76. package/cli/registry/tokens/scale/presets/compact.css +16 -5
  77. package/cli/registry/tokens/scale/presets/dense.css +13 -2
  78. package/cli/registry/tokens/scale/presets/sharp.css +18 -6
  79. package/cli/registry/tokens/scale/presets/soft.css +23 -1
  80. package/cli/registry/tokens/theme-base.css +235 -0
  81. package/{dist/tokens/themes/dark-qoder.css → cli/registry/tokens/themes/dark-mint.css} +1 -1
  82. package/cli/registry/tokens/themes/dark-parchment.css +104 -103
  83. package/{dist/tokens/themes/light-qoder.css → cli/registry/tokens/themes/light-mint.css} +1 -1
  84. package/cli/registry/tokens/themes/light-parchment.css +103 -102
  85. package/dist/registry/basic/alert-dialog.d.ts +7 -5
  86. package/dist/registry/basic/alert.d.ts +24 -0
  87. package/dist/registry/basic/aspect-ratio.d.ts +16 -0
  88. package/dist/registry/basic/avatar.d.ts +7 -5
  89. package/dist/registry/basic/breadcrumb.d.ts +24 -0
  90. package/dist/registry/basic/button-group.d.ts +26 -0
  91. package/dist/registry/basic/button.d.ts +1 -1
  92. package/dist/registry/basic/calendar.d.ts +22 -0
  93. package/dist/registry/basic/card.d.ts +27 -0
  94. package/dist/registry/basic/carousel.d.ts +19 -0
  95. package/dist/registry/basic/chart.d.ts +55 -0
  96. package/dist/registry/basic/checkbox.d.ts +21 -0
  97. package/dist/registry/basic/collapse.d.ts +7 -5
  98. package/dist/registry/basic/collapsible-card.d.ts +7 -6
  99. package/dist/registry/basic/collapsible.d.ts +7 -5
  100. package/dist/registry/basic/combobox.d.ts +26 -0
  101. package/dist/registry/basic/command.d.ts +18 -0
  102. package/dist/registry/basic/context-menu.d.ts +44 -0
  103. package/dist/registry/basic/data-table.d.ts +26 -0
  104. package/dist/registry/basic/date-picker.d.ts +18 -0
  105. package/dist/registry/basic/dialog.d.ts +39 -0
  106. package/dist/registry/basic/direction.d.ts +19 -0
  107. package/dist/registry/basic/drawer.d.ts +37 -0
  108. package/dist/registry/basic/dropdown-menu.d.ts +7 -5
  109. package/dist/registry/basic/empty.d.ts +22 -0
  110. package/dist/registry/basic/field.d.ts +24 -0
  111. package/dist/registry/basic/hover-card.d.ts +22 -0
  112. package/dist/registry/basic/icons-inline.d.ts +7 -5
  113. package/dist/registry/basic/input-group.d.ts +27 -0
  114. package/dist/registry/basic/input-otp.d.ts +22 -0
  115. package/dist/registry/basic/input.d.ts +15 -0
  116. package/dist/registry/basic/item.d.ts +34 -0
  117. package/dist/registry/basic/kbd.d.ts +7 -5
  118. package/dist/registry/basic/label.d.ts +16 -0
  119. package/dist/registry/basic/menubar.d.ts +37 -0
  120. package/dist/registry/basic/native-select.d.ts +18 -0
  121. package/dist/registry/basic/navigation-menu.d.ts +25 -0
  122. package/dist/registry/basic/pagination.d.ts +7 -5
  123. package/dist/registry/basic/popover.d.ts +23 -0
  124. package/dist/registry/basic/progress.d.ts +7 -5
  125. package/dist/registry/basic/radio-group.d.ts +7 -5
  126. package/dist/registry/basic/resizable.d.ts +7 -5
  127. package/dist/registry/basic/scroll-area.d.ts +5 -0
  128. package/dist/registry/basic/select.d.ts +7 -5
  129. package/dist/registry/basic/separator.d.ts +16 -0
  130. package/dist/registry/basic/sheet.d.ts +13 -0
  131. package/dist/registry/basic/slider.d.ts +7 -5
  132. package/dist/registry/basic/sonner.d.ts +7 -5
  133. package/dist/registry/basic/switch.d.ts +7 -5
  134. package/dist/registry/basic/tabs.d.ts +7 -5
  135. package/dist/registry/basic/tag.d.ts +7 -5
  136. package/dist/registry/basic/textarea.d.ts +15 -0
  137. package/dist/registry/basic/theme-from-document.d.ts +7 -5
  138. package/dist/registry/basic/toggle.d.ts +1 -1
  139. package/dist/registry/basic/tooltip.d.ts +7 -5
  140. package/dist/registry/basic/typography.d.ts +7 -5
  141. package/dist/registry/chat/ask-user-part.d.ts +9 -3
  142. package/dist/registry/chat/browser-action-part.d.ts +9 -3
  143. package/dist/registry/chat/chat-input/compound.d.ts +7 -5
  144. package/dist/registry/chat/chat-input/context.d.ts +10 -6
  145. package/dist/registry/chat/chat-input/index.d.ts +7 -5
  146. package/dist/registry/chat/chat-input/types.d.ts +9 -3
  147. package/dist/registry/chat/chat-input/useAutoResizeTextarea.d.ts +9 -3
  148. package/dist/registry/chat/code-block-part.d.ts +9 -3
  149. package/dist/registry/chat/conversation-anchor-nav.d.ts +72 -0
  150. package/dist/registry/chat/file-attachment.d.ts +7 -5
  151. package/dist/registry/chat/file-review-part.d.ts +9 -4
  152. package/dist/registry/chat/generated-images-grid.d.ts +9 -3
  153. package/dist/registry/chat/generation-status-bar.d.ts +8 -4
  154. package/dist/registry/chat/hint-banner.d.ts +9 -3
  155. package/dist/registry/chat/mermaid-part.d.ts +9 -3
  156. package/dist/registry/chat/plan-part.d.ts +9 -3
  157. package/dist/registry/chat/reasoning-step/index.d.ts +8 -6
  158. package/dist/registry/chat/reasoning-step/types.d.ts +9 -3
  159. package/dist/registry/chat/related-prompts.d.ts +9 -3
  160. package/dist/registry/chat/response/index.d.ts +8 -6
  161. package/dist/registry/chat/response/types.d.ts +9 -3
  162. package/dist/registry/chat/task-part.d.ts +9 -3
  163. package/dist/registry/chat/terminal-code-block-part.d.ts +9 -3
  164. package/dist/registry/chat/tool-invocation-card.d.ts +2 -0
  165. package/dist/registry/chat/user-question/UserQuestionCard.d.ts +9 -3
  166. package/dist/registry/chat/user-question/UserQuestionFooter.d.ts +9 -3
  167. package/dist/registry/chat/user-question/UserQuestionHeader.d.ts +9 -3
  168. package/dist/registry/chat/user-question/types.d.ts +8 -5
  169. package/dist/registry/lib/file-icon-maps.d.ts +7 -7
  170. package/dist/registry/lib/utils.d.ts +8 -6
  171. package/dist/scale/presets/compact.css +16 -5
  172. package/dist/scale/presets/dense.css +13 -2
  173. package/dist/scale/presets/sharp.css +18 -6
  174. package/dist/scale/presets/soft.css +23 -1
  175. package/dist/spark-design.cjs.js +40 -36
  176. package/dist/spark-design.es.js +8653 -8663
  177. package/dist/sparkdesign.css +2 -0
  178. package/dist/src/components/basic/Alert/index.d.ts +13 -0
  179. package/dist/src/components/basic/AlertDialog/index.d.ts +7 -5
  180. package/dist/src/components/basic/AspectRatio/index.d.ts +13 -0
  181. package/dist/src/components/basic/Avatar/index.d.ts +9 -3
  182. package/dist/src/components/basic/Breadcrumb/index.d.ts +12 -0
  183. package/dist/src/components/basic/Button/index.d.ts +9 -3
  184. package/dist/src/components/basic/ButtonGroup/index.d.ts +13 -0
  185. package/dist/src/components/basic/Calendar/index.d.ts +13 -0
  186. package/dist/src/components/basic/Card/index.d.ts +13 -0
  187. package/dist/src/components/basic/Carousel/index.d.ts +12 -0
  188. package/dist/src/components/basic/Chart/index.d.ts +13 -0
  189. package/dist/src/components/basic/Checkbox/index.d.ts +13 -0
  190. package/dist/src/components/basic/Collapse/index.d.ts +7 -4
  191. package/dist/src/components/basic/Collapsible/index.d.ts +9 -4
  192. package/dist/src/components/basic/CollapsibleCard/index.d.ts +9 -3
  193. package/dist/src/components/basic/CollapsibleSection/index.d.ts +7 -7
  194. package/dist/src/components/basic/Combobox/index.d.ts +13 -0
  195. package/dist/src/components/basic/Command/index.d.ts +12 -0
  196. package/dist/src/components/basic/ContextMenu/index.d.ts +19 -0
  197. package/dist/src/components/basic/DataTable/index.d.ts +13 -0
  198. package/dist/src/components/basic/DatePicker/index.d.ts +13 -0
  199. package/dist/src/components/basic/Dialog/index.d.ts +16 -0
  200. package/dist/src/components/basic/Direction/index.d.ts +13 -0
  201. package/dist/src/components/basic/Drawer/index.d.ts +16 -0
  202. package/dist/src/components/basic/DropdownMenu/index.d.ts +7 -5
  203. package/dist/src/components/basic/EllipsisText/index.d.ts +7 -15
  204. package/dist/src/components/basic/Empty/index.d.ts +12 -0
  205. package/dist/src/components/basic/Field/index.d.ts +12 -0
  206. package/dist/src/components/basic/HoverCard/index.d.ts +16 -0
  207. package/dist/src/components/basic/IconButton/index.d.ts +9 -3
  208. package/dist/src/components/basic/Input/index.d.ts +13 -0
  209. package/dist/src/components/basic/InputGroup/index.d.ts +12 -0
  210. package/dist/src/components/basic/InputOTP/index.d.ts +12 -0
  211. package/dist/src/components/basic/Item/index.d.ts +12 -0
  212. package/dist/src/components/basic/Kbd/index.d.ts +9 -3
  213. package/dist/src/components/basic/Label/index.d.ts +13 -0
  214. package/dist/src/components/basic/Menubar/index.d.ts +12 -0
  215. package/dist/src/components/basic/NativeSelect/index.d.ts +12 -0
  216. package/dist/src/components/basic/NavigationMenu/index.d.ts +12 -0
  217. package/dist/src/components/basic/OptionList/index.d.ts +9 -3
  218. package/dist/src/components/basic/Pagination/index.d.ts +9 -3
  219. package/dist/src/components/basic/Popover/index.d.ts +16 -0
  220. package/dist/src/components/basic/Progress/index.d.ts +9 -3
  221. package/dist/src/components/basic/RadioGroup/index.d.ts +9 -3
  222. package/dist/src/components/basic/Resizable/index.d.ts +9 -3
  223. package/dist/src/components/basic/ScrollArea/index.d.ts +12 -0
  224. package/dist/src/components/basic/Scrollbar/index.d.ts +9 -3
  225. package/dist/src/components/basic/Select/index.d.ts +7 -4
  226. package/dist/src/components/basic/Separator/index.d.ts +13 -0
  227. package/dist/src/components/basic/Sheet/index.d.ts +13 -0
  228. package/dist/src/components/basic/ShimmeringText/index.d.ts +9 -3
  229. package/dist/src/components/basic/Skeleton/index.d.ts +9 -3
  230. package/dist/src/components/basic/Slider/index.d.ts +9 -3
  231. package/dist/src/components/basic/Spinner/index.d.ts +9 -3
  232. package/dist/src/components/basic/Switch/index.d.ts +8 -5
  233. package/dist/src/components/basic/Table/index.d.ts +9 -3
  234. package/dist/src/components/basic/Tabs/index.d.ts +9 -3
  235. package/dist/src/components/basic/Tag/index.d.ts +7 -4
  236. package/dist/src/components/basic/Textarea/index.d.ts +13 -0
  237. package/dist/src/components/basic/Toggle/index.d.ts +9 -3
  238. package/dist/src/components/basic/Tooltip/index.d.ts +7 -4
  239. package/dist/src/components/basic/Typography/index.d.ts +9 -3
  240. package/dist/src/components/chat/ConversationAnchorNav/index.d.ts +13 -0
  241. package/dist/src/components/chat/GeneratedImagesGrid/index.d.ts +9 -3
  242. package/dist/src/components/chat/GenerationStatusBar/index.d.ts +9 -3
  243. package/dist/src/components/chat/Markdown/demo-content.d.ts +1 -1
  244. package/dist/src/components/chat/Markdown/index.d.ts +9 -3
  245. package/dist/src/components/chat/Response/StreamingMarkdownBlock.d.ts +9 -3
  246. package/dist/src/components/chat/Response/index.d.ts +8 -6
  247. package/dist/src/components/chat/StreamingMarkdownBlock/index.d.ts +13 -0
  248. package/dist/src/components/chat/UserMessage/index.d.ts +9 -3
  249. package/dist/src/components/index.d.ts +64 -9
  250. package/dist/src/icons/context.d.ts +7 -6
  251. package/dist/src/icons/types.d.ts +7 -5
  252. package/dist/src/lib/ThemeStyleContext.d.ts +9 -9
  253. package/dist/src/lib/file-icon.d.ts +7 -6
  254. package/dist/src/lib/i18n.d.ts +7 -6
  255. package/dist/src/lib/index.d.ts +9 -3
  256. package/dist/src/lib/utils.d.ts +7 -5
  257. package/dist/theme-base.css +7 -8
  258. package/dist/theme.css +2 -2
  259. package/dist/themes/{dark-qoder.css → dark-mint.css} +1 -1
  260. package/dist/themes/{light-qoder.css → light-mint.css} +1 -1
  261. package/dist/tokens/AGENTS.md +48 -0
  262. package/dist/tokens/index.css +10 -19
  263. package/dist/tokens/scale/presets/compact.css +16 -5
  264. package/dist/tokens/scale/presets/dense.css +13 -2
  265. package/dist/tokens/scale/presets/sharp.css +18 -6
  266. package/dist/tokens/scale/presets/soft.css +23 -1
  267. package/dist/tokens/theme-base.css +7 -8
  268. package/dist/tokens/theme.css +2 -2
  269. package/dist/tokens/themes/dark-mint.css +133 -0
  270. package/dist/tokens/themes/light-mint.css +132 -0
  271. package/docs/agent/component-selection.md +60 -0
  272. package/docs/agent/token-ontology.md +37 -0
  273. package/package.json +41 -9
  274. package/registry/agent-manifest.json +794 -0
  275. package/registry/tokens/ontology.json +404 -0
  276. package/cli/registry/tokens/themes/dark-qoder.css +0 -132
  277. package/cli/registry/tokens/themes/light-qoder.css +0 -131
  278. package/dist/_basePickBy-DnQN8w3y.js +0 -151
  279. package/dist/_basePickBy-a-kPMlkg.cjs +0 -1
  280. package/dist/_baseUniq-B-N2NQ50.js +0 -614
  281. package/dist/_baseUniq-Cc_zbSif.cjs +0 -1
  282. package/dist/arc-BQBhijZ6.js +0 -83
  283. package/dist/arc-mWQt0Yph.cjs +0 -1
  284. package/dist/architectureDiagram-VXUJARFQ-BMZEucno.cjs +0 -36
  285. package/dist/architectureDiagram-VXUJARFQ-DTdjD3Bp.js +0 -4661
  286. package/dist/blockDiagram-VD42YOAC-CzHn0yob.js +0 -2256
  287. package/dist/blockDiagram-VD42YOAC-DDxdHAlz.cjs +0 -122
  288. package/dist/c4Diagram-YG6GDRKO-4Gz0I4gj.cjs +0 -10
  289. package/dist/c4Diagram-YG6GDRKO-BIy--yVN.js +0 -1580
  290. package/dist/channel-BQn0o8bs.js +0 -5
  291. package/dist/channel-DaN7XniJ.cjs +0 -1
  292. package/dist/chunk-4BX2VUAB-BlQFTQqz.cjs +0 -1
  293. package/dist/chunk-4BX2VUAB-Czitj3Kc.js +0 -8
  294. package/dist/chunk-55IACEB6-DXacNZbO.js +0 -8
  295. package/dist/chunk-55IACEB6-DnDxpye9.cjs +0 -1
  296. package/dist/chunk-B4BG7PRW-CBdN0q_V.js +0 -1375
  297. package/dist/chunk-B4BG7PRW-DbGvUkGO.cjs +0 -165
  298. package/dist/chunk-DI55MBZ5-D1YJMs6x.cjs +0 -220
  299. package/dist/chunk-DI55MBZ5-NCQTvayw.js +0 -1370
  300. package/dist/chunk-FMBD7UC4-CsGMbrtr.js +0 -19
  301. package/dist/chunk-FMBD7UC4-Di7cUUh5.cjs +0 -15
  302. package/dist/chunk-QN33PNHL-0j5LC8Lm.cjs +0 -1
  303. package/dist/chunk-QN33PNHL-3GERZBRm.js +0 -19
  304. package/dist/chunk-QZHKN3VN-AVEY9ImQ.js +0 -15
  305. package/dist/chunk-QZHKN3VN-s8Z0a8mc.cjs +0 -1
  306. package/dist/chunk-TZMSLE5B-CAf87HPt.cjs +0 -1
  307. package/dist/chunk-TZMSLE5B-sbiflal0.js +0 -64
  308. package/dist/classDiagram-2ON5EDUG-Ct9JLIN2.cjs +0 -1
  309. package/dist/classDiagram-2ON5EDUG-Dzfrft3a.js +0 -16
  310. package/dist/classDiagram-v2-WZHVMYZB-Ct9JLIN2.cjs +0 -1
  311. package/dist/classDiagram-v2-WZHVMYZB-Dzfrft3a.js +0 -16
  312. package/dist/clone-Cde_NQ8V.js +0 -8
  313. package/dist/clone-DCNjWuM2.cjs +0 -1
  314. package/dist/cose-bilkent-S5V4N54A-0uLijMro.cjs +0 -1
  315. package/dist/cose-bilkent-S5V4N54A-Bb08N431.js +0 -2608
  316. package/dist/cytoscape.esm-CNUX3VTg.cjs +0 -321
  317. package/dist/cytoscape.esm-Cvf3sx9F.js +0 -18704
  318. package/dist/dagre-6UL2VRFP-CY_Wz5Zd.js +0 -444
  319. package/dist/dagre-6UL2VRFP-Dxe7_qZc.cjs +0 -4
  320. package/dist/defaultLocale-BgPVtth8.js +0 -171
  321. package/dist/defaultLocale-C4wbwF1n.cjs +0 -1
  322. package/dist/diagram-PSM6KHXK-D2bdb7MT.js +0 -531
  323. package/dist/diagram-PSM6KHXK-YF69SUjY.cjs +0 -24
  324. package/dist/diagram-QEK2KX5R-BpUSoh0-.js +0 -217
  325. package/dist/diagram-QEK2KX5R-DZPGteon.cjs +0 -43
  326. package/dist/diagram-S2PKOQOG-ht-zdvFG.cjs +0 -24
  327. package/dist/diagram-S2PKOQOG-zFeLJ50Z.js +0 -142
  328. package/dist/erDiagram-Q2GNP2WA-B38iJ6ts.js +0 -841
  329. package/dist/erDiagram-Q2GNP2WA-RgS80DDU.cjs +0 -60
  330. package/dist/flowDiagram-NV44I4VS-BHilOs2p.cjs +0 -162
  331. package/dist/flowDiagram-NV44I4VS-BrBJcoce.js +0 -1620
  332. package/dist/ganttDiagram-JELNMOA3-pZiJeFio.cjs +0 -267
  333. package/dist/ganttDiagram-JELNMOA3-tw6FhkWJ.js +0 -2670
  334. package/dist/gitGraphDiagram-V2S2FVAM-BWn5uIK5.js +0 -699
  335. package/dist/gitGraphDiagram-V2S2FVAM-DKKeG-9R.cjs +0 -65
  336. package/dist/graph-DIbblrZP.cjs +0 -1
  337. package/dist/graph-DPcK91G3.js +0 -247
  338. package/dist/infoDiagram-HS3SLOUP-B8gwwhct.cjs +0 -2
  339. package/dist/infoDiagram-HS3SLOUP-D47PNcP_.js +0 -24
  340. package/dist/init-CHZsXQcr.cjs +0 -1
  341. package/dist/init-DjUOC4st.js +0 -16
  342. package/dist/journeyDiagram-XKPGCS4Q-BG3cfhyU.js +0 -834
  343. package/dist/journeyDiagram-XKPGCS4Q-D8DVLJof.cjs +0 -139
  344. package/dist/kanban-definition-3W4ZIXB7-4OCnEouP.cjs +0 -89
  345. package/dist/kanban-definition-3W4ZIXB7-CWi_ssF9.js +0 -719
  346. package/dist/layout-Byuh8f-J.cjs +0 -1
  347. package/dist/layout-CdLdvj1j.js +0 -1335
  348. package/dist/linear-C2Q_PI9B.js +0 -259
  349. package/dist/linear-C69aPBW1.cjs +0 -1
  350. package/dist/mermaid.core-DBwAx_jp.cjs +0 -249
  351. package/dist/mermaid.core-gFR0XUlD.js +0 -15300
  352. package/dist/mindmap-definition-VGOIOE7T-8P7obVV4.cjs +0 -68
  353. package/dist/mindmap-definition-VGOIOE7T-DnOa7WJ9.js +0 -784
  354. package/dist/ordinal-B6-f3MAq.js +0 -61
  355. package/dist/ordinal-CagbB1m8.cjs +0 -1
  356. package/dist/pieDiagram-ADFJNKIX-5NAlvhMo.js +0 -161
  357. package/dist/pieDiagram-ADFJNKIX-CQBG4yR9.cjs +0 -30
  358. package/dist/qoder-design.css +0 -2
  359. package/dist/quadrantDiagram-AYHSOK5B-Oe4y7RZ0.cjs +0 -7
  360. package/dist/quadrantDiagram-AYHSOK5B-rh2DPEP1.js +0 -1022
  361. package/dist/requirementDiagram-UZGBJVZJ-DcWaCuXr.js +0 -850
  362. package/dist/requirementDiagram-UZGBJVZJ-gfdlrFiq.cjs +0 -64
  363. package/dist/sankeyDiagram-TZEHDZUN-CQIKFwD0.js +0 -810
  364. package/dist/sankeyDiagram-TZEHDZUN-DvPtzQvC.cjs +0 -10
  365. package/dist/sequenceDiagram-WL72ISMW-BNrsMagL.cjs +0 -145
  366. package/dist/sequenceDiagram-WL72ISMW-iCX3ckKx.js +0 -2511
  367. package/dist/stateDiagram-FKZM4ZOC-DBvJ_eeL.cjs +0 -1
  368. package/dist/stateDiagram-FKZM4ZOC-ZVsJlaHJ.js +0 -263
  369. package/dist/stateDiagram-v2-4FDKWEC3-CB_nTHcE.js +0 -16
  370. package/dist/stateDiagram-v2-4FDKWEC3-Xkx17v6T.cjs +0 -1
  371. package/dist/timeline-definition-IT6M3QCI-BmGkYQiz.cjs +0 -61
  372. package/dist/timeline-definition-IT6M3QCI-Ck8zTt6w.js +0 -795
  373. package/dist/tokens/CLAUDE.md +0 -305
  374. package/dist/treemap-GDKQZRPO-B9sfERx8.js +0 -17922
  375. package/dist/treemap-GDKQZRPO-BVfJRs0Z.cjs +0 -160
  376. package/dist/xychartDiagram-PRI3JC2R-By_S8NzN.js +0 -1340
  377. package/dist/xychartDiagram-PRI3JC2R-CNfDrGxM.cjs +0 -7
@@ -1,65 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const W=require("./chunk-4BX2VUAB-BlQFTQqz.cjs"),j=require("./chunk-QZHKN3VN-s8Z0a8mc.cjs"),s=require("./mermaid.core-DBwAx_jp.cjs"),K=require("./treemap-GDKQZRPO-BVfJRs0Z.cjs");var x={NORMAL:0,REVERSE:1,HIGHLIGHT:2,MERGE:3,CHERRY_PICK:4},U=s.defaultConfig_default.gitGraph,L=s.__name(()=>s.cleanAndMerge({...U,...s.getConfig().gitGraph}),"getConfig"),i=new j.ImperativeState(()=>{const t=L(),e=t.mainBranchName,n=t.mainBranchOrder;return{mainBranchName:e,commits:new Map,head:null,branchConfig:new Map([[e,{name:e,order:n}]]),branches:new Map([[e,null]]),currBranch:e,direction:"LR",seq:0,options:{}}});function G(){return s.random({length:7})}s.__name(G,"getID");function H(t,e){const n=Object.create(null);return t.reduce((o,r)=>{const a=e(r);return n[a]||(n[a]=!0,o.push(r)),o},[])}s.__name(H,"uniqBy");var Y=s.__name(function(t){i.records.direction=t},"setDirection"),V=s.__name(function(t){s.log.debug("options str",t),t=t?.trim(),t=t||"{}";try{i.records.options=JSON.parse(t)}catch(e){s.log.error("error while parsing gitGraph options",e.message)}},"setOptions"),Q=s.__name(function(){return i.records.options},"getOptions"),X=s.__name(function(t){let e=t.msg,n=t.id;const o=t.type;let r=t.tags;s.log.info("commit",e,n,o,r),s.log.debug("Entering commit:",e,n,o,r);const a=L();n=s.common_default.sanitizeText(n,a),e=s.common_default.sanitizeText(e,a),r=r?.map(c=>s.common_default.sanitizeText(c,a));const l={id:n||i.records.seq+"-"+G(),message:e,seq:i.records.seq++,type:o??x.NORMAL,tags:r??[],parents:i.records.head==null?[]:[i.records.head.id],branch:i.records.currBranch};i.records.head=l,s.log.info("main branch",a.mainBranchName),i.records.commits.has(l.id)&&s.log.warn(`Commit ID ${l.id} already exists`),i.records.commits.set(l.id,l),i.records.branches.set(i.records.currBranch,l.id),s.log.debug("in pushCommit "+l.id)},"commit"),Z=s.__name(function(t){let e=t.name;const n=t.order;if(e=s.common_default.sanitizeText(e,L()),i.records.branches.has(e))throw new Error(`Trying to create an existing branch. (Help: Either use a new name if you want create a new branch or try using "checkout ${e}")`);i.records.branches.set(e,i.records.head!=null?i.records.head.id:null),i.records.branchConfig.set(e,{name:e,order:n}),D(e),s.log.debug("in createBranch")},"branch"),J=s.__name(t=>{let e=t.branch,n=t.id;const o=t.type,r=t.tags,a=L();e=s.common_default.sanitizeText(e,a),n&&(n=s.common_default.sanitizeText(n,a));const l=i.records.branches.get(i.records.currBranch),c=i.records.branches.get(e),f=l?i.records.commits.get(l):void 0,h=c?i.records.commits.get(c):void 0;if(f&&h&&f.branch===e)throw new Error(`Cannot merge branch '${e}' into itself.`);if(i.records.currBranch===e){const d=new Error('Incorrect usage of "merge". Cannot merge a branch to itself');throw d.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["branch abc"]},d}if(f===void 0||!f){const d=new Error(`Incorrect usage of "merge". Current branch (${i.records.currBranch})has no commits`);throw d.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["commit"]},d}if(!i.records.branches.has(e)){const d=new Error('Incorrect usage of "merge". Branch to be merged ('+e+") does not exist");throw d.hash={text:`merge ${e}`,token:`merge ${e}`,expected:[`branch ${e}`]},d}if(h===void 0||!h){const d=new Error('Incorrect usage of "merge". Branch to be merged ('+e+") has no commits");throw d.hash={text:`merge ${e}`,token:`merge ${e}`,expected:['"commit"']},d}if(f===h){const d=new Error('Incorrect usage of "merge". Both branches have same head');throw d.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["branch abc"]},d}if(n&&i.records.commits.has(n)){const d=new Error('Incorrect usage of "merge". Commit with id:'+n+" already exists, use different custom id");throw d.hash={text:`merge ${e} ${n} ${o} ${r?.join(" ")}`,token:`merge ${e} ${n} ${o} ${r?.join(" ")}`,expected:[`merge ${e} ${n}_UNIQUE ${o} ${r?.join(" ")}`]},d}const $=c||"",g={id:n||`${i.records.seq}-${G()}`,message:`merged branch ${e} into ${i.records.currBranch}`,seq:i.records.seq++,parents:i.records.head==null?[]:[i.records.head.id,$],branch:i.records.currBranch,type:x.MERGE,customType:o,customId:!!n,tags:r??[]};i.records.head=g,i.records.commits.set(g.id,g),i.records.branches.set(i.records.currBranch,g.id),s.log.debug(i.records.branches),s.log.debug("in mergeBranch")},"merge"),ee=s.__name(function(t){let e=t.id,n=t.targetId,o=t.tags,r=t.parent;s.log.debug("Entering cherryPick:",e,n,o);const a=L();if(e=s.common_default.sanitizeText(e,a),n=s.common_default.sanitizeText(n,a),o=o?.map(f=>s.common_default.sanitizeText(f,a)),r=s.common_default.sanitizeText(r,a),!e||!i.records.commits.has(e)){const f=new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');throw f.hash={text:`cherryPick ${e} ${n}`,token:`cherryPick ${e} ${n}`,expected:["cherry-pick abc"]},f}const l=i.records.commits.get(e);if(l===void 0||!l)throw new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');if(r&&!(Array.isArray(l.parents)&&l.parents.includes(r)))throw new Error("Invalid operation: The specified parent commit is not an immediate parent of the cherry-picked commit.");const c=l.branch;if(l.type===x.MERGE&&!r)throw new Error("Incorrect usage of cherry-pick: If the source commit is a merge commit, an immediate parent commit must be specified.");if(!n||!i.records.commits.has(n)){if(c===i.records.currBranch){const g=new Error('Incorrect usage of "cherryPick". Source commit is already on current branch');throw g.hash={text:`cherryPick ${e} ${n}`,token:`cherryPick ${e} ${n}`,expected:["cherry-pick abc"]},g}const f=i.records.branches.get(i.records.currBranch);if(f===void 0||!f){const g=new Error(`Incorrect usage of "cherry-pick". Current branch (${i.records.currBranch})has no commits`);throw g.hash={text:`cherryPick ${e} ${n}`,token:`cherryPick ${e} ${n}`,expected:["cherry-pick abc"]},g}const h=i.records.commits.get(f);if(h===void 0||!h){const g=new Error(`Incorrect usage of "cherry-pick". Current branch (${i.records.currBranch})has no commits`);throw g.hash={text:`cherryPick ${e} ${n}`,token:`cherryPick ${e} ${n}`,expected:["cherry-pick abc"]},g}const $={id:i.records.seq+"-"+G(),message:`cherry-picked ${l?.message} into ${i.records.currBranch}`,seq:i.records.seq++,parents:i.records.head==null?[]:[i.records.head.id,l.id],branch:i.records.currBranch,type:x.CHERRY_PICK,tags:o?o.filter(Boolean):[`cherry-pick:${l.id}${l.type===x.MERGE?`|parent:${r}`:""}`]};i.records.head=$,i.records.commits.set($.id,$),i.records.branches.set(i.records.currBranch,$.id),s.log.debug(i.records.branches),s.log.debug("in cherryPick")}},"cherryPick"),D=s.__name(function(t){if(t=s.common_default.sanitizeText(t,L()),i.records.branches.has(t)){i.records.currBranch=t;const e=i.records.branches.get(i.records.currBranch);e===void 0||!e?i.records.head=null:i.records.head=i.records.commits.get(e)??null}else{const e=new Error(`Trying to checkout branch which is not yet created. (Help try using "branch ${t}")`);throw e.hash={text:`checkout ${t}`,token:`checkout ${t}`,expected:[`branch ${t}`]},e}},"checkout");function A(t,e,n){const o=t.indexOf(e);o===-1?t.push(n):t.splice(o,1,n)}s.__name(A,"upsert");function q(t){const e=t.reduce((r,a)=>r.seq>a.seq?r:a,t[0]);let n="";t.forEach(function(r){r===e?n+=" *":n+=" |"});const o=[n,e.id,e.seq];for(const r in i.records.branches)i.records.branches.get(r)===e.id&&o.push(r);if(s.log.debug(o.join(" ")),e.parents&&e.parents.length==2&&e.parents[0]&&e.parents[1]){const r=i.records.commits.get(e.parents[0]);A(t,e,r),e.parents[1]&&t.push(i.records.commits.get(e.parents[1]))}else{if(e.parents.length==0)return;if(e.parents[0]){const r=i.records.commits.get(e.parents[0]);A(t,e,r)}}t=H(t,r=>r.id),q(t)}s.__name(q,"prettyPrintCommitHistory");var re=s.__name(function(){s.log.debug(i.records.commits);const t=N()[0];q([t])},"prettyPrint"),te=s.__name(function(){i.reset(),s.clear()},"clear"),ae=s.__name(function(){return[...i.records.branchConfig.values()].map((e,n)=>e.order!==null&&e.order!==void 0?e:{...e,order:parseFloat(`0.${n}`)}).sort((e,n)=>(e.order??0)-(n.order??0)).map(({name:e})=>({name:e}))},"getBranchesAsObjArray"),ne=s.__name(function(){return i.records.branches},"getBranches"),se=s.__name(function(){return i.records.commits},"getCommits"),N=s.__name(function(){const t=[...i.records.commits.values()];return t.forEach(function(e){s.log.debug(e.id)}),t.sort((e,n)=>e.seq-n.seq),t},"getCommitsArray"),oe=s.__name(function(){return i.records.currBranch},"getCurrentBranch"),ce=s.__name(function(){return i.records.direction},"getDirection"),ie=s.__name(function(){return i.records.head},"getHead"),z={commitType:x,getConfig:L,setDirection:Y,setOptions:V,getOptions:Q,commit:X,branch:Z,merge:J,cherryPick:ee,checkout:D,prettyPrint:re,clear:te,getBranchesAsObjArray:ae,getBranches:ne,getCommits:se,getCommitsArray:N,getCurrentBranch:oe,getDirection:ce,getHead:ie,setAccTitle:s.setAccTitle,getAccTitle:s.getAccTitle,getAccDescription:s.getAccDescription,setAccDescription:s.setAccDescription,setDiagramTitle:s.setDiagramTitle,getDiagramTitle:s.getDiagramTitle},de=s.__name((t,e)=>{W.populateCommonDb(t,e),t.dir&&e.setDirection(t.dir);for(const n of t.statements)le(n,e)},"populate"),le=s.__name((t,e)=>{const o={Commit:s.__name(r=>e.commit(he(r)),"Commit"),Branch:s.__name(r=>e.branch($e(r)),"Branch"),Merge:s.__name(r=>e.merge(fe(r)),"Merge"),Checkout:s.__name(r=>e.checkout(ge(r)),"Checkout"),CherryPicking:s.__name(r=>e.cherryPick(ye(r)),"CherryPicking")}[t.$type];o?o(t):s.log.error(`Unknown statement type: ${t.$type}`)},"parseStatement"),he=s.__name(t=>({id:t.id,msg:t.message??"",type:t.type!==void 0?x[t.type]:x.NORMAL,tags:t.tags??void 0}),"parseCommit"),$e=s.__name(t=>({name:t.name,order:t.order??0}),"parseBranch"),fe=s.__name(t=>({branch:t.branch,id:t.id??"",type:t.type!==void 0?x[t.type]:void 0,tags:t.tags??void 0}),"parseMerge"),ge=s.__name(t=>t.branch,"parseCheckout"),ye=s.__name(t=>({id:t.id,targetId:"",tags:t.tags?.length===0?void 0:t.tags,parent:t.parent}),"parseCherryPicking"),ue={parse:s.__name(async t=>{const e=await K.parse("gitGraph",t);s.log.debug(e),de(e,z)},"parse")},me=s.getConfig2(),_=me?.gitGraph,E=10,T=40,w=4,v=2,B=8,p=new Map,b=new Map,I=30,k=new Map,R=[],C=0,u="LR",xe=s.__name(()=>{p.clear(),b.clear(),k.clear(),C=0,R=[],u="LR"},"clear"),F=s.__name(t=>{const e=document.createElementNS("http://www.w3.org/2000/svg","text");return(typeof t=="string"?t.split(/\\n|\n|<br\s*\/?>/gi):t).forEach(o=>{const r=document.createElementNS("http://www.w3.org/2000/svg","tspan");r.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.setAttribute("dy","1em"),r.setAttribute("x","0"),r.setAttribute("class","row"),r.textContent=o.trim(),e.appendChild(r)}),e},"drawText"),S=s.__name(t=>{let e,n,o;return u==="BT"?(n=s.__name((r,a)=>r<=a,"comparisonFunc"),o=1/0):(n=s.__name((r,a)=>r>=a,"comparisonFunc"),o=0),t.forEach(r=>{const a=u==="TB"||u=="BT"?b.get(r)?.y:b.get(r)?.x;a!==void 0&&n(a,o)&&(e=r,o=a)}),e},"findClosestParent"),pe=s.__name(t=>{let e="",n=1/0;return t.forEach(o=>{const r=b.get(o).y;r<=n&&(e=o,n=r)}),e||void 0},"findClosestParentBT"),be=s.__name((t,e,n)=>{let o=n,r=n;const a=[];t.forEach(l=>{const c=e.get(l);if(!c)throw new Error(`Commit not found for key ${l}`);c.parents.length?(o=we(c),r=Math.max(o,r)):a.push(c),ve(c,o)}),o=r,a.forEach(l=>{Ce(l,o,n)}),t.forEach(l=>{const c=e.get(l);if(c?.parents.length){const f=pe(c.parents);o=b.get(f).y-T,o<=r&&(r=o);const h=p.get(c.branch).pos,$=o-E;b.set(c.id,{x:h,y:$})}})},"setParallelBTPos"),_e=s.__name(t=>{const e=S(t.parents.filter(o=>o!==null));if(!e)throw new Error(`Closest parent not found for commit ${t.id}`);const n=b.get(e)?.y;if(n===void 0)throw new Error(`Closest parent position not found for commit ${t.id}`);return n},"findClosestParentPos"),we=s.__name(t=>_e(t)+T,"calculateCommitPosition"),ve=s.__name((t,e)=>{const n=p.get(t.branch);if(!n)throw new Error(`Branch not found for commit ${t.id}`);const o=n.pos,r=e+E;return b.set(t.id,{x:o,y:r}),{x:o,y:r}},"setCommitPosition"),Ce=s.__name((t,e,n)=>{const o=p.get(t.branch);if(!o)throw new Error(`Branch not found for commit ${t.id}`);const r=e+n,a=o.pos;b.set(t.id,{x:a,y:r})},"setRootPosition"),Ee=s.__name((t,e,n,o,r,a)=>{if(a===x.HIGHLIGHT)t.append("rect").attr("x",n.x-10).attr("y",n.y-10).attr("width",20).attr("height",20).attr("class",`commit ${e.id} commit-highlight${r%B} ${o}-outer`),t.append("rect").attr("x",n.x-6).attr("y",n.y-6).attr("width",12).attr("height",12).attr("class",`commit ${e.id} commit${r%B} ${o}-inner`);else if(a===x.CHERRY_PICK)t.append("circle").attr("cx",n.x).attr("cy",n.y).attr("r",10).attr("class",`commit ${e.id} ${o}`),t.append("circle").attr("cx",n.x-3).attr("cy",n.y+2).attr("r",2.75).attr("fill","#fff").attr("class",`commit ${e.id} ${o}`),t.append("circle").attr("cx",n.x+3).attr("cy",n.y+2).attr("r",2.75).attr("fill","#fff").attr("class",`commit ${e.id} ${o}`),t.append("line").attr("x1",n.x+3).attr("y1",n.y+1).attr("x2",n.x).attr("y2",n.y-5).attr("stroke","#fff").attr("class",`commit ${e.id} ${o}`),t.append("line").attr("x1",n.x-3).attr("y1",n.y+1).attr("x2",n.x).attr("y2",n.y-5).attr("stroke","#fff").attr("class",`commit ${e.id} ${o}`);else{const l=t.append("circle");if(l.attr("cx",n.x),l.attr("cy",n.y),l.attr("r",e.type===x.MERGE?9:10),l.attr("class",`commit ${e.id} commit${r%B}`),a===x.MERGE){const c=t.append("circle");c.attr("cx",n.x),c.attr("cy",n.y),c.attr("r",6),c.attr("class",`commit ${o} ${e.id} commit${r%B}`)}a===x.REVERSE&&t.append("path").attr("d",`M ${n.x-5},${n.y-5}L${n.x+5},${n.y+5}M${n.x-5},${n.y+5}L${n.x+5},${n.y-5}`).attr("class",`commit ${o} ${e.id} commit${r%B}`)}},"drawCommitBullet"),Te=s.__name((t,e,n,o)=>{if(e.type!==x.CHERRY_PICK&&(e.customId&&e.type===x.MERGE||e.type!==x.MERGE)&&_?.showCommitLabel){const r=t.append("g"),a=r.insert("rect").attr("class","commit-label-bkg"),l=r.append("text").attr("x",o).attr("y",n.y+25).attr("class","commit-label").text(e.id),c=l.node()?.getBBox();if(c&&(a.attr("x",n.posWithOffset-c.width/2-v).attr("y",n.y+13.5).attr("width",c.width+2*v).attr("height",c.height+2*v),u==="TB"||u==="BT"?(a.attr("x",n.x-(c.width+4*w+5)).attr("y",n.y-12),l.attr("x",n.x-(c.width+4*w)).attr("y",n.y+c.height-12)):l.attr("x",n.posWithOffset-c.width/2),_.rotateCommitLabel))if(u==="TB"||u==="BT")l.attr("transform","rotate(-45, "+n.x+", "+n.y+")"),a.attr("transform","rotate(-45, "+n.x+", "+n.y+")");else{const f=-7.5-(c.width+10)/25*9.5,h=10+c.width/25*8.5;r.attr("transform","translate("+f+", "+h+") rotate(-45, "+o+", "+n.y+")")}}},"drawCommitLabel"),Be=s.__name((t,e,n,o)=>{if(e.tags.length>0){let r=0,a=0,l=0;const c=[];for(const f of e.tags.reverse()){const h=t.insert("polygon"),$=t.append("circle"),g=t.append("text").attr("y",n.y-16-r).attr("class","tag-label").text(f),d=g.node()?.getBBox();if(!d)throw new Error("Tag bbox not found");a=Math.max(a,d.width),l=Math.max(l,d.height),g.attr("x",n.posWithOffset-d.width/2),c.push({tag:g,hole:$,rect:h,yOffset:r}),r+=20}for(const{tag:f,hole:h,rect:$,yOffset:g}of c){const d=l/2,y=n.y-19.2-g;if($.attr("class","tag-label-bkg").attr("points",`
2
- ${o-a/2-w/2},${y+v}
3
- ${o-a/2-w/2},${y-v}
4
- ${n.posWithOffset-a/2-w},${y-d-v}
5
- ${n.posWithOffset+a/2+w},${y-d-v}
6
- ${n.posWithOffset+a/2+w},${y+d+v}
7
- ${n.posWithOffset-a/2-w},${y+d+v}`),h.attr("cy",y).attr("cx",o-a/2+w/2).attr("r",1.5).attr("class","tag-hole"),u==="TB"||u==="BT"){const m=o+g;$.attr("class","tag-label-bkg").attr("points",`
8
- ${n.x},${m+2}
9
- ${n.x},${m-2}
10
- ${n.x+E},${m-d-2}
11
- ${n.x+E+a+4},${m-d-2}
12
- ${n.x+E+a+4},${m+d+2}
13
- ${n.x+E},${m+d+2}`).attr("transform","translate(12,12) rotate(45, "+n.x+","+o+")"),h.attr("cx",n.x+w/2).attr("cy",m).attr("transform","translate(12,12) rotate(45, "+n.x+","+o+")"),f.attr("x",n.x+5).attr("y",m+3).attr("transform","translate(14,14) rotate(45, "+n.x+","+o+")")}}}},"drawCommitTags"),Le=s.__name(t=>{switch(t.customType??t.type){case x.NORMAL:return"commit-normal";case x.REVERSE:return"commit-reverse";case x.HIGHLIGHT:return"commit-highlight";case x.MERGE:return"commit-merge";case x.CHERRY_PICK:return"commit-cherry-pick";default:return"commit-normal"}},"getCommitClassType"),ke=s.__name((t,e,n,o)=>{const r={x:0,y:0};if(t.parents.length>0){const a=S(t.parents);if(a){const l=o.get(a)??r;return e==="TB"?l.y+T:e==="BT"?(o.get(t.id)??r).y-T:l.x+T}}else return e==="TB"?I:e==="BT"?(o.get(t.id)??r).y-T:0;return 0},"calculatePosition"),Me=s.__name((t,e,n)=>{const o=u==="BT"&&n?e:e+E,r=u==="TB"||u==="BT"?o:p.get(t.branch)?.pos,a=u==="TB"||u==="BT"?p.get(t.branch)?.pos:o;if(a===void 0||r===void 0)throw new Error(`Position were undefined for commit ${t.id}`);return{x:a,y:r,posWithOffset:o}},"getCommitPosition"),P=s.__name((t,e,n)=>{if(!_)throw new Error("GitGraph config not found");const o=t.append("g").attr("class","commit-bullets"),r=t.append("g").attr("class","commit-labels");let a=u==="TB"||u==="BT"?I:0;const l=[...e.keys()],c=_?.parallelCommits??!1,f=s.__name(($,g)=>{const d=e.get($)?.seq,y=e.get(g)?.seq;return d!==void 0&&y!==void 0?d-y:0},"sortKeys");let h=l.sort(f);u==="BT"&&(c&&be(h,e,a),h=h.reverse()),h.forEach($=>{const g=e.get($);if(!g)throw new Error(`Commit not found for key ${$}`);c&&(a=ke(g,u,a,b));const d=Me(g,a,c);if(n){const y=Le(g),m=g.customType??g.type,O=p.get(g.branch)?.index??0;Ee(o,g,d,y,O,m),Te(r,g,d,a),Be(r,g,d,a)}u==="TB"||u==="BT"?b.set(g.id,{x:d.x,y:d.posWithOffset}):b.set(g.id,{x:d.posWithOffset,y:d.y}),a=u==="BT"&&c?a+T:a+T+E,a>C&&(C=a)})},"drawCommits"),Ie=s.__name((t,e,n,o,r)=>{const l=(u==="TB"||u==="BT"?n.x<o.x:n.y<o.y)?e.branch:t.branch,c=s.__name(h=>h.branch===l,"isOnBranchToGetCurve"),f=s.__name(h=>h.seq>t.seq&&h.seq<e.seq,"isBetweenCommits");return[...r.values()].some(h=>f(h)&&c(h))},"shouldRerouteArrow"),M=s.__name((t,e,n=0)=>{const o=t+Math.abs(t-e)/2;if(n>5)return o;if(R.every(l=>Math.abs(l-o)>=10))return R.push(o),o;const a=Math.abs(t-e);return M(t,e-a/5,n+1)},"findLane"),Re=s.__name((t,e,n,o)=>{const r=b.get(e.id),a=b.get(n.id);if(r===void 0||a===void 0)throw new Error(`Commit positions not found for commits ${e.id} and ${n.id}`);const l=Ie(e,n,r,a,o);let c="",f="",h=0,$=0,g=p.get(n.branch)?.index;n.type===x.MERGE&&e.id!==n.parents[0]&&(g=p.get(e.branch)?.index);let d;if(l){c="A 10 10, 0, 0, 0,",f="A 10 10, 0, 0, 1,",h=10,$=10;const y=r.y<a.y?M(r.y,a.y):M(a.y,r.y),m=r.x<a.x?M(r.x,a.x):M(a.x,r.x);u==="TB"?r.x<a.x?d=`M ${r.x} ${r.y} L ${m-h} ${r.y} ${f} ${m} ${r.y+$} L ${m} ${a.y-h} ${c} ${m+$} ${a.y} L ${a.x} ${a.y}`:(g=p.get(e.branch)?.index,d=`M ${r.x} ${r.y} L ${m+h} ${r.y} ${c} ${m} ${r.y+$} L ${m} ${a.y-h} ${f} ${m-$} ${a.y} L ${a.x} ${a.y}`):u==="BT"?r.x<a.x?d=`M ${r.x} ${r.y} L ${m-h} ${r.y} ${c} ${m} ${r.y-$} L ${m} ${a.y+h} ${f} ${m+$} ${a.y} L ${a.x} ${a.y}`:(g=p.get(e.branch)?.index,d=`M ${r.x} ${r.y} L ${m+h} ${r.y} ${f} ${m} ${r.y-$} L ${m} ${a.y+h} ${c} ${m-$} ${a.y} L ${a.x} ${a.y}`):r.y<a.y?d=`M ${r.x} ${r.y} L ${r.x} ${y-h} ${c} ${r.x+$} ${y} L ${a.x-h} ${y} ${f} ${a.x} ${y+$} L ${a.x} ${a.y}`:(g=p.get(e.branch)?.index,d=`M ${r.x} ${r.y} L ${r.x} ${y+h} ${f} ${r.x+$} ${y} L ${a.x-h} ${y} ${c} ${a.x} ${y-$} L ${a.x} ${a.y}`)}else c="A 20 20, 0, 0, 0,",f="A 20 20, 0, 0, 1,",h=20,$=20,u==="TB"?(r.x<a.x&&(n.type===x.MERGE&&e.id!==n.parents[0]?d=`M ${r.x} ${r.y} L ${r.x} ${a.y-h} ${c} ${r.x+$} ${a.y} L ${a.x} ${a.y}`:d=`M ${r.x} ${r.y} L ${a.x-h} ${r.y} ${f} ${a.x} ${r.y+$} L ${a.x} ${a.y}`),r.x>a.x&&(c="A 20 20, 0, 0, 0,",f="A 20 20, 0, 0, 1,",h=20,$=20,n.type===x.MERGE&&e.id!==n.parents[0]?d=`M ${r.x} ${r.y} L ${r.x} ${a.y-h} ${f} ${r.x-$} ${a.y} L ${a.x} ${a.y}`:d=`M ${r.x} ${r.y} L ${a.x+h} ${r.y} ${c} ${a.x} ${r.y+$} L ${a.x} ${a.y}`),r.x===a.x&&(d=`M ${r.x} ${r.y} L ${a.x} ${a.y}`)):u==="BT"?(r.x<a.x&&(n.type===x.MERGE&&e.id!==n.parents[0]?d=`M ${r.x} ${r.y} L ${r.x} ${a.y+h} ${f} ${r.x+$} ${a.y} L ${a.x} ${a.y}`:d=`M ${r.x} ${r.y} L ${a.x-h} ${r.y} ${c} ${a.x} ${r.y-$} L ${a.x} ${a.y}`),r.x>a.x&&(c="A 20 20, 0, 0, 0,",f="A 20 20, 0, 0, 1,",h=20,$=20,n.type===x.MERGE&&e.id!==n.parents[0]?d=`M ${r.x} ${r.y} L ${r.x} ${a.y+h} ${c} ${r.x-$} ${a.y} L ${a.x} ${a.y}`:d=`M ${r.x} ${r.y} L ${a.x-h} ${r.y} ${c} ${a.x} ${r.y-$} L ${a.x} ${a.y}`),r.x===a.x&&(d=`M ${r.x} ${r.y} L ${a.x} ${a.y}`)):(r.y<a.y&&(n.type===x.MERGE&&e.id!==n.parents[0]?d=`M ${r.x} ${r.y} L ${a.x-h} ${r.y} ${f} ${a.x} ${r.y+$} L ${a.x} ${a.y}`:d=`M ${r.x} ${r.y} L ${r.x} ${a.y-h} ${c} ${r.x+$} ${a.y} L ${a.x} ${a.y}`),r.y>a.y&&(n.type===x.MERGE&&e.id!==n.parents[0]?d=`M ${r.x} ${r.y} L ${a.x-h} ${r.y} ${c} ${a.x} ${r.y-$} L ${a.x} ${a.y}`:d=`M ${r.x} ${r.y} L ${r.x} ${a.y+h} ${f} ${r.x+$} ${a.y} L ${a.x} ${a.y}`),r.y===a.y&&(d=`M ${r.x} ${r.y} L ${a.x} ${a.y}`));if(d===void 0)throw new Error("Line definition not found");t.append("path").attr("d",d).attr("class","arrow arrow"+g%B)},"drawArrow"),Ge=s.__name((t,e)=>{const n=t.append("g").attr("class","commit-arrows");[...e.keys()].forEach(o=>{const r=e.get(o);r.parents&&r.parents.length>0&&r.parents.forEach(a=>{Re(n,e.get(a),r,e)})})},"drawArrows"),Oe=s.__name((t,e)=>{const n=t.append("g");e.forEach((o,r)=>{const a=r%B,l=p.get(o.name)?.pos;if(l===void 0)throw new Error(`Position not found for branch ${o.name}`);const c=n.append("line");c.attr("x1",0),c.attr("y1",l),c.attr("x2",C),c.attr("y2",l),c.attr("class","branch branch"+a),u==="TB"?(c.attr("y1",I),c.attr("x1",l),c.attr("y2",C),c.attr("x2",l)):u==="BT"&&(c.attr("y1",C),c.attr("x1",l),c.attr("y2",I),c.attr("x2",l)),R.push(l);const f=o.name,h=F(f),$=n.insert("rect"),d=n.insert("g").attr("class","branchLabel").insert("g").attr("class","label branch-label"+a);d.node().appendChild(h);const y=h.getBBox();$.attr("class","branchLabelBkg label"+a).attr("rx",4).attr("ry",4).attr("x",-y.width-4-(_?.rotateCommitLabel===!0?30:0)).attr("y",-y.height/2+8).attr("width",y.width+18).attr("height",y.height+4),d.attr("transform","translate("+(-y.width-14-(_?.rotateCommitLabel===!0?30:0))+", "+(l-y.height/2-1)+")"),u==="TB"?($.attr("x",l-y.width/2-10).attr("y",0),d.attr("transform","translate("+(l-y.width/2-5)+", 0)")):u==="BT"?($.attr("x",l-y.width/2-10).attr("y",C),d.attr("transform","translate("+(l-y.width/2-5)+", "+C+")")):$.attr("transform","translate(-19, "+(l-y.height/2)+")")})},"drawBranches"),Ae=s.__name(function(t,e,n,o,r){return p.set(t,{pos:e,index:n}),e+=50+(r?40:0)+(u==="TB"||u==="BT"?o.width/2:0),e},"setBranchPosition"),qe=s.__name(function(t,e,n,o){if(xe(),s.log.debug("in gitgraph renderer",t+`
14
- `,"id:",e,n),!_)throw new Error("GitGraph config not found");const r=_.rotateCommitLabel??!1,a=o.db;k=a.getCommits();const l=a.getBranchesAsObjArray();u=a.getDirection();const c=s.select(`[id="${e}"]`);let f=0;l.forEach((h,$)=>{const g=F(h.name),d=c.append("g"),y=d.insert("g").attr("class","branchLabel"),m=y.insert("g").attr("class","label branch-label");m.node()?.appendChild(g);const O=g.getBBox();f=Ae(h.name,f,$,O,r),m.remove(),y.remove(),d.remove()}),P(c,k,!1),_.showBranches&&Oe(c,l),Ge(c,k),P(c,k,!0),s.utils_default.insertTitle(c,"gitTitleText",_.titleTopMargin??0,a.getDiagramTitle()),s.setupGraphViewbox2(void 0,c,_.diagramPadding,_.useMaxWidth)},"draw"),Pe={draw:qe},He=s.__name(t=>`
15
- .commit-id,
16
- .commit-msg,
17
- .branch-label {
18
- fill: lightgrey;
19
- color: lightgrey;
20
- font-family: 'trebuchet ms', verdana, arial, sans-serif;
21
- font-family: var(--mermaid-font-family);
22
- }
23
- ${[0,1,2,3,4,5,6,7].map(e=>`
24
- .branch-label${e} { fill: ${t["gitBranchLabel"+e]}; }
25
- .commit${e} { stroke: ${t["git"+e]}; fill: ${t["git"+e]}; }
26
- .commit-highlight${e} { stroke: ${t["gitInv"+e]}; fill: ${t["gitInv"+e]}; }
27
- .label${e} { fill: ${t["git"+e]}; }
28
- .arrow${e} { stroke: ${t["git"+e]}; }
29
- `).join(`
30
- `)}
31
-
32
- .branch {
33
- stroke-width: 1;
34
- stroke: ${t.lineColor};
35
- stroke-dasharray: 2;
36
- }
37
- .commit-label { font-size: ${t.commitLabelFontSize}; fill: ${t.commitLabelColor};}
38
- .commit-label-bkg { font-size: ${t.commitLabelFontSize}; fill: ${t.commitLabelBackground}; opacity: 0.5; }
39
- .tag-label { font-size: ${t.tagLabelFontSize}; fill: ${t.tagLabelColor};}
40
- .tag-label-bkg { fill: ${t.tagLabelBackground}; stroke: ${t.tagLabelBorder}; }
41
- .tag-hole { fill: ${t.textColor}; }
42
-
43
- .commit-merge {
44
- stroke: ${t.primaryColor};
45
- fill: ${t.primaryColor};
46
- }
47
- .commit-reverse {
48
- stroke: ${t.primaryColor};
49
- fill: ${t.primaryColor};
50
- stroke-width: 3;
51
- }
52
- .commit-highlight-outer {
53
- }
54
- .commit-highlight-inner {
55
- stroke: ${t.primaryColor};
56
- fill: ${t.primaryColor};
57
- }
58
-
59
- .arrow { stroke-width: 8; stroke-linecap: round; fill: none}
60
- .gitTitleText {
61
- text-anchor: middle;
62
- font-size: 18px;
63
- fill: ${t.textColor};
64
- }
65
- `,"getStyles"),De=He,Ne={parser:ue,db:z,renderer:Pe,styles:De};exports.diagram=Ne;
@@ -1 +0,0 @@
1
- "use strict";const a=require("./mermaid.core-DBwAx_jp.cjs"),n=require("./_baseUniq-Cc_zbSif.cjs");var b=a.baseRest(function(o){return n.baseUniq(n.baseFlatten(o,1,a.isArrayLikeObject,!0))}),E="\0",u="\0",g="";class f{constructor(e={}){this._isDirected=Object.prototype.hasOwnProperty.call(e,"directed")?e.directed:!0,this._isMultigraph=Object.prototype.hasOwnProperty.call(e,"multigraph")?e.multigraph:!1,this._isCompound=Object.prototype.hasOwnProperty.call(e,"compound")?e.compound:!1,this._label=void 0,this._defaultNodeLabelFn=a.constant$1(void 0),this._defaultEdgeLabelFn=a.constant$1(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[u]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}isDirected(){return this._isDirected}isMultigraph(){return this._isMultigraph}isCompound(){return this._isCompound}setGraph(e){return this._label=e,this}graph(){return this._label}setDefaultNodeLabel(e){return a.isFunction(e)||(e=a.constant$1(e)),this._defaultNodeLabelFn=e,this}nodeCount(){return this._nodeCount}nodes(){return n.keys(this._nodes)}sources(){var e=this;return n.filter(this.nodes(),function(t){return a.isEmpty(e._in[t])})}sinks(){var e=this;return n.filter(this.nodes(),function(t){return a.isEmpty(e._out[t])})}setNodes(e,t){var s=arguments,i=this;return n.forEach(e,function(r){s.length>1?i.setNode(r,t):i.setNode(r)}),this}setNode(e,t){return Object.prototype.hasOwnProperty.call(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=t),this):(this._nodes[e]=arguments.length>1?t:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=u,this._children[e]={},this._children[u][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)}node(e){return this._nodes[e]}hasNode(e){return Object.prototype.hasOwnProperty.call(this._nodes,e)}removeNode(e){if(Object.prototype.hasOwnProperty.call(this._nodes,e)){var t=s=>this.removeEdge(this._edgeObjs[s]);delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],n.forEach(this.children(e),s=>{this.setParent(s)}),delete this._children[e]),n.forEach(n.keys(this._in[e]),t),delete this._in[e],delete this._preds[e],n.forEach(n.keys(this._out[e]),t),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this}setParent(e,t){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(n.isUndefined(t))t=u;else{t+="";for(var s=t;!n.isUndefined(s);s=this.parent(s))if(s===e)throw new Error("Setting "+t+" as parent of "+e+" would create a cycle");this.setNode(t)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=t,this._children[t][e]=!0,this}_removeFromParentsChildList(e){delete this._children[this._parent[e]][e]}parent(e){if(this._isCompound){var t=this._parent[e];if(t!==u)return t}}children(e){if(n.isUndefined(e)&&(e=u),this._isCompound){var t=this._children[e];if(t)return n.keys(t)}else{if(e===u)return this.nodes();if(this.hasNode(e))return[]}}predecessors(e){var t=this._preds[e];if(t)return n.keys(t)}successors(e){var t=this._sucs[e];if(t)return n.keys(t)}neighbors(e){var t=this.predecessors(e);if(t)return b(t,this.successors(e))}isLeaf(e){var t;return this.isDirected()?t=this.successors(e):t=this.neighbors(e),t.length===0}filterNodes(e){var t=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});t.setGraph(this.graph());var s=this;n.forEach(this._nodes,function(h,d){e(d)&&t.setNode(d,h)}),n.forEach(this._edgeObjs,function(h){t.hasNode(h.v)&&t.hasNode(h.w)&&t.setEdge(h,s.edge(h))});var i={};function r(h){var d=s.parent(h);return d===void 0||t.hasNode(d)?(i[h]=d,d):d in i?i[d]:r(d)}return this._isCompound&&n.forEach(t.nodes(),function(h){t.setParent(h,r(h))}),t}setDefaultEdgeLabel(e){return a.isFunction(e)||(e=a.constant$1(e)),this._defaultEdgeLabelFn=e,this}edgeCount(){return this._edgeCount}edges(){return n.values(this._edgeObjs)}setPath(e,t){var s=this,i=arguments;return n.reduce(e,function(r,h){return i.length>1?s.setEdge(r,h,t):s.setEdge(r,h),h}),this}setEdge(){var e,t,s,i,r=!1,h=arguments[0];typeof h=="object"&&h!==null&&"v"in h?(e=h.v,t=h.w,s=h.name,arguments.length===2&&(i=arguments[1],r=!0)):(e=h,t=arguments[1],s=arguments[3],arguments.length>2&&(i=arguments[2],r=!0)),e=""+e,t=""+t,n.isUndefined(s)||(s=""+s);var d=l(this._isDirected,e,t,s);if(Object.prototype.hasOwnProperty.call(this._edgeLabels,d))return r&&(this._edgeLabels[d]=i),this;if(!n.isUndefined(s)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(e),this.setNode(t),this._edgeLabels[d]=r?i:this._defaultEdgeLabelFn(e,t,s);var _=y(this._isDirected,e,t,s);return e=_.v,t=_.w,Object.freeze(_),this._edgeObjs[d]=_,p(this._preds[t],e),p(this._sucs[e],t),this._in[t][d]=_,this._out[e][d]=_,this._edgeCount++,this}edge(e,t,s){var i=arguments.length===1?c(this._isDirected,arguments[0]):l(this._isDirected,e,t,s);return this._edgeLabels[i]}hasEdge(e,t,s){var i=arguments.length===1?c(this._isDirected,arguments[0]):l(this._isDirected,e,t,s);return Object.prototype.hasOwnProperty.call(this._edgeLabels,i)}removeEdge(e,t,s){var i=arguments.length===1?c(this._isDirected,arguments[0]):l(this._isDirected,e,t,s),r=this._edgeObjs[i];return r&&(e=r.v,t=r.w,delete this._edgeLabels[i],delete this._edgeObjs[i],m(this._preds[t],e),m(this._sucs[e],t),delete this._in[t][i],delete this._out[e][i],this._edgeCount--),this}inEdges(e,t){var s=this._in[e];if(s){var i=n.values(s);return t?n.filter(i,function(r){return r.v===t}):i}}outEdges(e,t){var s=this._out[e];if(s){var i=n.values(s);return t?n.filter(i,function(r){return r.w===t}):i}}nodeEdges(e,t){var s=this.inEdges(e,t);if(s)return s.concat(this.outEdges(e,t))}}f.prototype._nodeCount=0;f.prototype._edgeCount=0;function p(o,e){o[e]?o[e]++:o[e]=1}function m(o,e){--o[e]||delete o[e]}function l(o,e,t,s){var i=""+e,r=""+t;if(!o&&i>r){var h=i;i=r,r=h}return i+g+r+g+(n.isUndefined(s)?E:s)}function y(o,e,t,s){var i=""+e,r=""+t;if(!o&&i>r){var h=i;i=r,r=h}var d={v:i,w:r};return s&&(d.name=s),d}function c(o,e){return l(o,e.v,e.w,e.name)}exports.Graph=f;
@@ -1,247 +0,0 @@
1
- import { aA as N, aB as j, aC as f, aD as b, aE as E } from "./mermaid.core-gFR0XUlD.js";
2
- import { a as v, c as P, k as _, f as g, d, i as l, v as p, r as D } from "./_baseUniq-B-N2NQ50.js";
3
- var w = N(function(o) {
4
- return v(P(o, 1, j, !0));
5
- }), F = "\0", a = "\0", O = "";
6
- class L {
7
- constructor(e = {}) {
8
- this._isDirected = Object.prototype.hasOwnProperty.call(e, "directed") ? e.directed : !0, this._isMultigraph = Object.prototype.hasOwnProperty.call(e, "multigraph") ? e.multigraph : !1, this._isCompound = Object.prototype.hasOwnProperty.call(e, "compound") ? e.compound : !1, this._label = void 0, this._defaultNodeLabelFn = f(void 0), this._defaultEdgeLabelFn = f(void 0), this._nodes = {}, this._isCompound && (this._parent = {}, this._children = {}, this._children[a] = {}), this._in = {}, this._preds = {}, this._out = {}, this._sucs = {}, this._edgeObjs = {}, this._edgeLabels = {};
9
- }
10
- /* === Graph functions ========= */
11
- isDirected() {
12
- return this._isDirected;
13
- }
14
- isMultigraph() {
15
- return this._isMultigraph;
16
- }
17
- isCompound() {
18
- return this._isCompound;
19
- }
20
- setGraph(e) {
21
- return this._label = e, this;
22
- }
23
- graph() {
24
- return this._label;
25
- }
26
- /* === Node functions ========== */
27
- setDefaultNodeLabel(e) {
28
- return b(e) || (e = f(e)), this._defaultNodeLabelFn = e, this;
29
- }
30
- nodeCount() {
31
- return this._nodeCount;
32
- }
33
- nodes() {
34
- return _(this._nodes);
35
- }
36
- sources() {
37
- var e = this;
38
- return g(this.nodes(), function(t) {
39
- return E(e._in[t]);
40
- });
41
- }
42
- sinks() {
43
- var e = this;
44
- return g(this.nodes(), function(t) {
45
- return E(e._out[t]);
46
- });
47
- }
48
- setNodes(e, t) {
49
- var s = arguments, i = this;
50
- return d(e, function(r) {
51
- s.length > 1 ? i.setNode(r, t) : i.setNode(r);
52
- }), this;
53
- }
54
- setNode(e, t) {
55
- return Object.prototype.hasOwnProperty.call(this._nodes, e) ? (arguments.length > 1 && (this._nodes[e] = t), this) : (this._nodes[e] = arguments.length > 1 ? t : this._defaultNodeLabelFn(e), this._isCompound && (this._parent[e] = a, this._children[e] = {}, this._children[a][e] = !0), this._in[e] = {}, this._preds[e] = {}, this._out[e] = {}, this._sucs[e] = {}, ++this._nodeCount, this);
56
- }
57
- node(e) {
58
- return this._nodes[e];
59
- }
60
- hasNode(e) {
61
- return Object.prototype.hasOwnProperty.call(this._nodes, e);
62
- }
63
- removeNode(e) {
64
- if (Object.prototype.hasOwnProperty.call(this._nodes, e)) {
65
- var t = (s) => this.removeEdge(this._edgeObjs[s]);
66
- delete this._nodes[e], this._isCompound && (this._removeFromParentsChildList(e), delete this._parent[e], d(this.children(e), (s) => {
67
- this.setParent(s);
68
- }), delete this._children[e]), d(_(this._in[e]), t), delete this._in[e], delete this._preds[e], d(_(this._out[e]), t), delete this._out[e], delete this._sucs[e], --this._nodeCount;
69
- }
70
- return this;
71
- }
72
- setParent(e, t) {
73
- if (!this._isCompound)
74
- throw new Error("Cannot set parent in a non-compound graph");
75
- if (l(t))
76
- t = a;
77
- else {
78
- t += "";
79
- for (var s = t; !l(s); s = this.parent(s))
80
- if (s === e)
81
- throw new Error("Setting " + t + " as parent of " + e + " would create a cycle");
82
- this.setNode(t);
83
- }
84
- return this.setNode(e), this._removeFromParentsChildList(e), this._parent[e] = t, this._children[t][e] = !0, this;
85
- }
86
- _removeFromParentsChildList(e) {
87
- delete this._children[this._parent[e]][e];
88
- }
89
- parent(e) {
90
- if (this._isCompound) {
91
- var t = this._parent[e];
92
- if (t !== a)
93
- return t;
94
- }
95
- }
96
- children(e) {
97
- if (l(e) && (e = a), this._isCompound) {
98
- var t = this._children[e];
99
- if (t)
100
- return _(t);
101
- } else {
102
- if (e === a)
103
- return this.nodes();
104
- if (this.hasNode(e))
105
- return [];
106
- }
107
- }
108
- predecessors(e) {
109
- var t = this._preds[e];
110
- if (t)
111
- return _(t);
112
- }
113
- successors(e) {
114
- var t = this._sucs[e];
115
- if (t)
116
- return _(t);
117
- }
118
- neighbors(e) {
119
- var t = this.predecessors(e);
120
- if (t)
121
- return w(t, this.successors(e));
122
- }
123
- isLeaf(e) {
124
- var t;
125
- return this.isDirected() ? t = this.successors(e) : t = this.neighbors(e), t.length === 0;
126
- }
127
- filterNodes(e) {
128
- var t = new this.constructor({
129
- directed: this._isDirected,
130
- multigraph: this._isMultigraph,
131
- compound: this._isCompound
132
- });
133
- t.setGraph(this.graph());
134
- var s = this;
135
- d(this._nodes, function(n, h) {
136
- e(h) && t.setNode(h, n);
137
- }), d(this._edgeObjs, function(n) {
138
- t.hasNode(n.v) && t.hasNode(n.w) && t.setEdge(n, s.edge(n));
139
- });
140
- var i = {};
141
- function r(n) {
142
- var h = s.parent(n);
143
- return h === void 0 || t.hasNode(h) ? (i[n] = h, h) : h in i ? i[h] : r(h);
144
- }
145
- return this._isCompound && d(t.nodes(), function(n) {
146
- t.setParent(n, r(n));
147
- }), t;
148
- }
149
- /* === Edge functions ========== */
150
- setDefaultEdgeLabel(e) {
151
- return b(e) || (e = f(e)), this._defaultEdgeLabelFn = e, this;
152
- }
153
- edgeCount() {
154
- return this._edgeCount;
155
- }
156
- edges() {
157
- return p(this._edgeObjs);
158
- }
159
- setPath(e, t) {
160
- var s = this, i = arguments;
161
- return D(e, function(r, n) {
162
- return i.length > 1 ? s.setEdge(r, n, t) : s.setEdge(r, n), n;
163
- }), this;
164
- }
165
- /*
166
- * setEdge(v, w, [value, [name]])
167
- * setEdge({ v, w, [name] }, [value])
168
- */
169
- setEdge() {
170
- var e, t, s, i, r = !1, n = arguments[0];
171
- typeof n == "object" && n !== null && "v" in n ? (e = n.v, t = n.w, s = n.name, arguments.length === 2 && (i = arguments[1], r = !0)) : (e = n, t = arguments[1], s = arguments[3], arguments.length > 2 && (i = arguments[2], r = !0)), e = "" + e, t = "" + t, l(s) || (s = "" + s);
172
- var h = c(this._isDirected, e, t, s);
173
- if (Object.prototype.hasOwnProperty.call(this._edgeLabels, h))
174
- return r && (this._edgeLabels[h] = i), this;
175
- if (!l(s) && !this._isMultigraph)
176
- throw new Error("Cannot set a named edge when isMultigraph = false");
177
- this.setNode(e), this.setNode(t), this._edgeLabels[h] = r ? i : this._defaultEdgeLabelFn(e, t, s);
178
- var u = M(this._isDirected, e, t, s);
179
- return e = u.v, t = u.w, Object.freeze(u), this._edgeObjs[h] = u, C(this._preds[t], e), C(this._sucs[e], t), this._in[t][h] = u, this._out[e][h] = u, this._edgeCount++, this;
180
- }
181
- edge(e, t, s) {
182
- var i = arguments.length === 1 ? m(this._isDirected, arguments[0]) : c(this._isDirected, e, t, s);
183
- return this._edgeLabels[i];
184
- }
185
- hasEdge(e, t, s) {
186
- var i = arguments.length === 1 ? m(this._isDirected, arguments[0]) : c(this._isDirected, e, t, s);
187
- return Object.prototype.hasOwnProperty.call(this._edgeLabels, i);
188
- }
189
- removeEdge(e, t, s) {
190
- var i = arguments.length === 1 ? m(this._isDirected, arguments[0]) : c(this._isDirected, e, t, s), r = this._edgeObjs[i];
191
- return r && (e = r.v, t = r.w, delete this._edgeLabels[i], delete this._edgeObjs[i], y(this._preds[t], e), y(this._sucs[e], t), delete this._in[t][i], delete this._out[e][i], this._edgeCount--), this;
192
- }
193
- inEdges(e, t) {
194
- var s = this._in[e];
195
- if (s) {
196
- var i = p(s);
197
- return t ? g(i, function(r) {
198
- return r.v === t;
199
- }) : i;
200
- }
201
- }
202
- outEdges(e, t) {
203
- var s = this._out[e];
204
- if (s) {
205
- var i = p(s);
206
- return t ? g(i, function(r) {
207
- return r.w === t;
208
- }) : i;
209
- }
210
- }
211
- nodeEdges(e, t) {
212
- var s = this.inEdges(e, t);
213
- if (s)
214
- return s.concat(this.outEdges(e, t));
215
- }
216
- }
217
- L.prototype._nodeCount = 0;
218
- L.prototype._edgeCount = 0;
219
- function C(o, e) {
220
- o[e] ? o[e]++ : o[e] = 1;
221
- }
222
- function y(o, e) {
223
- --o[e] || delete o[e];
224
- }
225
- function c(o, e, t, s) {
226
- var i = "" + e, r = "" + t;
227
- if (!o && i > r) {
228
- var n = i;
229
- i = r, r = n;
230
- }
231
- return i + O + r + O + (l(s) ? F : s);
232
- }
233
- function M(o, e, t, s) {
234
- var i = "" + e, r = "" + t;
235
- if (!o && i > r) {
236
- var n = i;
237
- i = r, r = n;
238
- }
239
- var h = { v: i, w: r };
240
- return s && (h.name = s), h;
241
- }
242
- function m(o, e) {
243
- return c(o, e.v, e.w, e.name);
244
- }
245
- export {
246
- L as G
247
- };
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./mermaid.core-DBwAx_jp.cjs"),o=require("./treemap-GDKQZRPO-BVfJRs0Z.cjs");var s={parse:e.__name(async r=>{const a=await o.parse("info",r);e.log.debug(a)},"parse")},i={version:e.package_default.version+""},g=e.__name(()=>i.version,"getVersion"),d={getVersion:g},v=e.__name((r,a,n)=>{e.log.debug(`rendering info diagram
2
- `+r);const t=e.selectSvgElement(a);e.configureSvgSize(t,100,400,!0),t.append("g").append("text").attr("x",100).attr("y",40).attr("class","version").attr("font-size",32).style("text-anchor","middle").text(`v${n}`)},"draw"),c={draw:v},p={parser:s,db:d,renderer:c};exports.diagram=p;
@@ -1,24 +0,0 @@
1
- import { _ as e, l as s, H as o, e as i, I as g } from "./mermaid.core-gFR0XUlD.js";
2
- import { p } from "./treemap-GDKQZRPO-B9sfERx8.js";
3
- var v = {
4
- parse: /* @__PURE__ */ e(async (r) => {
5
- const a = await p("info", r);
6
- s.debug(a);
7
- }, "parse")
8
- }, d = {
9
- version: g.version + ""
10
- }, c = /* @__PURE__ */ e(() => d.version, "getVersion"), m = {
11
- getVersion: c
12
- }, l = /* @__PURE__ */ e((r, a, n) => {
13
- s.debug(`rendering info diagram
14
- ` + r);
15
- const t = o(a);
16
- i(t, 100, 400, !0), t.append("g").append("text").attr("x", 100).attr("y", 40).attr("class", "version").attr("font-size", 32).style("text-anchor", "middle").text(`v${n}`);
17
- }, "draw"), f = { draw: l }, b = {
18
- parser: v,
19
- db: m,
20
- renderer: f
21
- };
22
- export {
23
- b as diagram
24
- };
@@ -1 +0,0 @@
1
- "use strict";function a(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}exports.initRange=a;
@@ -1,16 +0,0 @@
1
- function t(e, a) {
2
- switch (arguments.length) {
3
- case 0:
4
- break;
5
- case 1:
6
- this.range(e);
7
- break;
8
- default:
9
- this.range(a).domain(e);
10
- break;
11
- }
12
- return this;
13
- }
14
- export {
15
- t as i
16
- };