@runfusion/fusion 0.77.0-beta.4 → 0.77.0-beta.6

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 (161) hide show
  1. package/dist/bin.js +4459 -4221
  2. package/dist/child-process-worker.js +3012 -1779
  3. package/dist/client/.vite/manifest.json +269 -269
  4. package/dist/client/assets/{AgentDetailView-CH6GtXl9.js → AgentDetailView-oyY72uSo.js} +1 -1
  5. package/dist/client/assets/{AgentPermissionPolicyEditor-YTEpMhUx.js → AgentPermissionPolicyEditor-C3Qo9p1M.js} +1 -1
  6. package/dist/client/assets/{AgentsView-XOHHDo4a.js → AgentsView-M2MhTIGW.js} +3 -3
  7. package/dist/client/assets/ChatView-zKrUSqiQ.js +13 -0
  8. package/dist/client/assets/{CommandCenter-BsH-R15f.js → CommandCenter-CpcAt6jt.js} +27 -27
  9. package/dist/client/assets/{DevServerView-CKOa-lkc.js → DevServerView-CjTneoG7.js} +1 -1
  10. package/dist/client/assets/{DirectoryPicker-DHUYTE-j.js → DirectoryPicker-BY6V5HLV.js} +1 -1
  11. package/dist/client/assets/{DocumentsView-BPzrxeP-.js → DocumentsView-RDK56-qg.js} +1 -1
  12. package/dist/client/assets/{EvalsView-DojCiv47.js → EvalsView-DKK4ceUW.js} +1 -1
  13. package/dist/client/assets/{ExperimentalAgentOnboardingModal-DuurZ8qe.js → ExperimentalAgentOnboardingModal-DiBPZVwC.js} +1 -1
  14. package/dist/client/assets/{GoalsView-DDWPXcG1.js → GoalsView-DPj59B3l.js} +1 -1
  15. package/dist/client/assets/{InsightsView-CgkMOD1A.js → InsightsView-QLJNkKJp.js} +1 -1
  16. package/dist/client/assets/{MemoryView-Cj49_z7O.js → MemoryView-CDCS-1ig.js} +1 -1
  17. package/dist/client/assets/{PiExtensionsManager-B_rRJiOd.js → PiExtensionsManager-DktXXrmF.js} +1 -1
  18. package/dist/client/assets/{PluginManager-Dxwi88oY.js → PluginManager-CQ3iEFMq.js} +1 -1
  19. package/dist/client/assets/{PullRequestView-z-5v2hQT.js → PullRequestView-CkObT6e3.js} +1 -1
  20. package/dist/client/assets/{ReportModal-DmOPEYWp.js → ReportModal-B5LTdDgi.js} +1 -1
  21. package/dist/client/assets/{ResearchView-D90Jbzbx.js → ResearchView-CryFrV8l.js} +1 -1
  22. package/dist/client/assets/{SecretsView-CSyjZl5L.js → SecretsView-9YcNW_fo.js} +1 -1
  23. package/dist/client/assets/{SessionTerminal-Bwb8nGmU.js → SessionTerminal-BWsA9puD.js} +1 -1
  24. package/dist/client/assets/SettingsModal-CL6aiXiI.js +21 -0
  25. package/dist/client/assets/{SettingsModal-CJof1Ett.js → SettingsModal-llkoaJev.js} +1 -1
  26. package/dist/client/assets/{SettingsTextareaRow-BYchnHfW.js → SettingsTextareaRow-B_Legu-A.js} +1 -1
  27. package/dist/client/assets/{SetupWizardModal-NqV-erVf.js → SetupWizardModal-DLA4UAGp.js} +2 -2
  28. package/dist/client/assets/{SkillsView-BUrkIJ-p.js → SkillsView-CSeauwIw.js} +1 -1
  29. package/dist/client/assets/{WorkflowNodeEditor-DcPk2A1Z.js → WorkflowNodeEditor-CGgMiiWy.js} +2 -2
  30. package/dist/client/assets/{agent-import-generation-X16OLfrL.js → agent-import-generation-CttglSmZ.js} +1 -1
  31. package/dist/client/assets/{agentsOrgChartLayout-BhPIXckU.js → agentsOrgChartLayout-f-9mwRbD.js} +1 -1
  32. package/dist/client/assets/app-BBSLJDbV.js +13 -0
  33. package/dist/client/assets/app-BKwOvuxE.js +5 -0
  34. package/dist/client/assets/app-Bvr57EZQ.js +5 -0
  35. package/dist/client/assets/app-C_PTWuI1.js +13 -0
  36. package/dist/client/assets/app-DKx18PHE.js +13 -0
  37. package/dist/client/assets/app-DRW5hIgr.js +13 -0
  38. package/dist/client/assets/app-DwvelD-n.js +13 -0
  39. package/dist/client/assets/{architectureDiagram-3BPJPVTR-WArMtdqy.js → architectureDiagram-3BPJPVTR-DA_Hm_di.js} +1 -1
  40. package/dist/client/assets/{blockDiagram-GPEHLZMM-emScogdV.js → blockDiagram-GPEHLZMM-JF7K8CcV.js} +1 -1
  41. package/dist/client/assets/{c4Diagram-AAUBKEIU-CBY7-E0T.js → c4Diagram-AAUBKEIU-DN-wklCP.js} +1 -1
  42. package/dist/client/assets/channel-CwFfFSI9.js +1 -0
  43. package/dist/client/assets/{chunk-2J33WTMH-Bcai1sOm.js → chunk-2J33WTMH-ChtjU8Cu.js} +1 -1
  44. package/dist/client/assets/{chunk-4BX2VUAB-hjiKRusj.js → chunk-4BX2VUAB-dJL0n3nn.js} +1 -1
  45. package/dist/client/assets/{chunk-55IACEB6-DpO9nIb0.js → chunk-55IACEB6-Bfg-QB9A.js} +1 -1
  46. package/dist/client/assets/{chunk-727SXJPM-B9JanA0o.js → chunk-727SXJPM-BHPPwYUS.js} +1 -1
  47. package/dist/client/assets/{chunk-AQP2D5EJ-D6zdnEUE.js → chunk-AQP2D5EJ-DIIpPUQN.js} +1 -1
  48. package/dist/client/assets/{chunk-FMBD7UC4-CRkrJ51d.js → chunk-FMBD7UC4-D230R32b.js} +1 -1
  49. package/dist/client/assets/{chunk-ND2GUHAM-BLQsKt7a.js → chunk-ND2GUHAM-0Lhp5CRv.js} +1 -1
  50. package/dist/client/assets/{chunk-QZHKN3VN-MCOlJ723.js → chunk-QZHKN3VN-BxbHBfKJ.js} +1 -1
  51. package/dist/client/assets/classDiagram-4FO5ZUOK-C8dZsxxX.js +1 -0
  52. package/dist/client/assets/classDiagram-v2-Q7XG4LA2-C8dZsxxX.js +1 -0
  53. package/dist/client/assets/{cose-bilkent-S5V4N54A-Cv1XmKKG.js → cose-bilkent-S5V4N54A-3vEwhfYz.js} +1 -1
  54. package/dist/client/assets/{dagre-BM42HDAG-flnNS_RW.js → dagre-BM42HDAG-Br44UsdY.js} +1 -1
  55. package/dist/client/assets/{dashboard-view-Dz7kqcJc.js → dashboard-view-B0OM3KYC.js} +1 -1
  56. package/dist/client/assets/{dashboard-view-CC1aH-lp.js → dashboard-view-BldxxYfz.js} +1 -1
  57. package/dist/client/assets/{dashboard-view-DEAYb_TZ.js → dashboard-view-CcPcELPx.js} +1 -1
  58. package/dist/client/assets/{dashboard-view-CrV-rL9Q.js → dashboard-view-_EglxMDl.js} +1 -1
  59. package/dist/client/assets/{diagram-2AECGRRQ-Z3S7b_6_.js → diagram-2AECGRRQ-CLNxbHUP.js} +1 -1
  60. package/dist/client/assets/{diagram-5GNKFQAL-BAZHdMFq.js → diagram-5GNKFQAL-D3cNAeQH.js} +1 -1
  61. package/dist/client/assets/{diagram-KO2AKTUF-C2y3S8F0.js → diagram-KO2AKTUF-DkX7h6to.js} +1 -1
  62. package/dist/client/assets/{diagram-LMA3HP47-Bfz0_IvT.js → diagram-LMA3HP47-6iQIiYUr.js} +1 -1
  63. package/dist/client/assets/{diagram-OG6HWLK6-BBmSQsTI.js → diagram-OG6HWLK6-Caje3229.js} +1 -1
  64. package/dist/client/assets/{erDiagram-TEJ5UH35-DnpdQi66.js → erDiagram-TEJ5UH35-BkU-1HB1.js} +1 -1
  65. package/dist/client/assets/{flowDiagram-I6XJVG4X-IybTR_zf.js → flowDiagram-I6XJVG4X-BRx3V6RE.js} +1 -1
  66. package/dist/client/assets/{folder-open-Dntm63x4.js → folder-open-BaSOBfk2.js} +1 -1
  67. package/dist/client/assets/{ganttDiagram-6RSMTGT7-DEQOe2E9.js → ganttDiagram-6RSMTGT7-D9f1kH3t.js} +1 -1
  68. package/dist/client/assets/{gitGraphDiagram-PVQCEYII-BOKc-h63.js → gitGraphDiagram-PVQCEYII-CQwmZcRd.js} +1 -1
  69. package/dist/client/assets/index-B8PcG8AJ.js +2774 -0
  70. package/dist/client/assets/index-Dki2LBAp.css +1 -0
  71. package/dist/client/assets/{infoDiagram-5YYISTIA-LqaYIdbj.js → infoDiagram-5YYISTIA-DYWBkGjG.js} +1 -1
  72. package/dist/client/assets/{ishikawaDiagram-YF4QCWOH-a8qd512s.js → ishikawaDiagram-YF4QCWOH-Df0Nzvh4.js} +1 -1
  73. package/dist/client/assets/{journeyDiagram-JHISSGLW-BgoNyeiy.js → journeyDiagram-JHISSGLW-bSvrZSyZ.js} +1 -1
  74. package/dist/client/assets/{kanban-definition-UN3LZRKU-Bqwow7D3.js → kanban-definition-UN3LZRKU-yHJ101M8.js} +1 -1
  75. package/dist/client/assets/{mermaid.core-B2zD934i.js → mermaid.core-Bc_0VLJw.js} +4 -4
  76. package/dist/client/assets/{mindmap-definition-RKZ34NQL-CCTOigWu.js → mindmap-definition-RKZ34NQL-DWRnMguM.js} +1 -1
  77. package/dist/client/assets/{pieDiagram-4H26LBE5-Bq5DtXKR.js → pieDiagram-4H26LBE5-Ds-DEOqr.js} +1 -1
  78. package/dist/client/assets/{puzzle-VhTPiCit.js → puzzle-CdYF81IT.js} +1 -1
  79. package/dist/client/assets/{quadrantDiagram-W4KKPZXB-CGMP3nUx.js → quadrantDiagram-W4KKPZXB-Bz-j2fkf.js} +1 -1
  80. package/dist/client/assets/{requirementDiagram-4Y6WPE33-Ckeu_szu.js → requirementDiagram-4Y6WPE33-BaQ_PaZ-.js} +1 -1
  81. package/dist/client/assets/{sankeyDiagram-5OEKKPKP-SWbBDD4d.js → sankeyDiagram-5OEKKPKP-pUCz8V4-.js} +1 -1
  82. package/dist/client/assets/{sequenceDiagram-3UESZ5HK-CiJrmL_G.js → sequenceDiagram-3UESZ5HK-CFwUMspe.js} +1 -1
  83. package/dist/client/assets/{shield-alert-BBDlP6A5.js → shield-alert-4qeU3_Rm.js} +1 -1
  84. package/dist/client/assets/{standing-instructions-template-viu_kgDX.js → standing-instructions-template-Crocrob7.js} +1 -1
  85. package/dist/client/assets/{stateDiagram-AJRCARHV-DTCzK5Gt.js → stateDiagram-AJRCARHV-CHZwo-vd.js} +1 -1
  86. package/dist/client/assets/{stateDiagram-v2-BHNVJYJU-BIGAwFTT.js → stateDiagram-v2-BHNVJYJU-BTvKaIZR.js} +1 -1
  87. package/dist/client/assets/{timeline-definition-PNZ67QCA-BQZEFEug.js → timeline-definition-PNZ67QCA-Cn3XIoz2.js} +1 -1
  88. package/dist/client/assets/{upload-D5w3Ehwp.js → upload--GqImz6h.js} +1 -1
  89. package/dist/client/assets/{useDiscoveredSkillsCache-D6zMSIaS.js → useDiscoveredSkillsCache-BEHgTFai.js} +1 -1
  90. package/dist/client/assets/{users-Bohihi_o.js → users-B0h1q4x6.js} +1 -1
  91. package/dist/client/assets/{vennDiagram-CIIHVFJN-DnHguEv8.js → vennDiagram-CIIHVFJN-CS0FNVU_.js} +1 -1
  92. package/dist/client/assets/{wardley-L42UT6IY-BOqYltGN.js → wardley-L42UT6IY-DdYkfF5d.js} +1 -1
  93. package/dist/client/assets/{wardleyDiagram-YWT4CUSO-Re0Ery2M.js → wardleyDiagram-YWT4CUSO-B_rFmPCh.js} +1 -1
  94. package/dist/client/assets/{xychartDiagram-2RQKCTM6-CnVq21b2.js → xychartDiagram-2RQKCTM6-CCoaCgmc.js} +1 -1
  95. package/dist/client/index.html +2 -2
  96. package/dist/client/version.json +1 -1
  97. package/dist/droid-cli/package.json +1 -1
  98. package/dist/extension.js +3444 -2195
  99. package/dist/migrations/0000_initial.sql +3 -0
  100. package/dist/migrations/0061_fn_066_activity_log_task_id_index.sql +7 -0
  101. package/dist/migrations/0062_remove_task_subtask_splitting.sql +2 -0
  102. package/dist/migrations/0063_fn_090_ai_merge_review_reconciliation.sql +2 -0
  103. package/dist/migrations/0064_fn_094_task_repository_scope.sql +2 -0
  104. package/dist/pi-claude-cli/package.json +1 -1
  105. package/dist/plugin-sdk/index.d.ts +285 -186
  106. package/dist/plugin-sdk/index.js +35 -104
  107. package/dist/plugins/fusion-plugin-acp-runtime/bundled.js +35 -104
  108. package/dist/plugins/fusion-plugin-acp-runtime/package.json +1 -1
  109. package/dist/plugins/fusion-plugin-claude-runtime/bundled.js +35 -104
  110. package/dist/plugins/fusion-plugin-claude-runtime/package.json +1 -1
  111. package/dist/plugins/fusion-plugin-cli-printing-press/bundled.js +35 -104
  112. package/dist/plugins/fusion-plugin-cli-printing-press/package.json +1 -1
  113. package/dist/plugins/fusion-plugin-compound-engineering/bundled.js +35 -104
  114. package/dist/plugins/fusion-plugin-compound-engineering/package.json +1 -1
  115. package/dist/plugins/fusion-plugin-cursor-runtime/bundled.js +35 -104
  116. package/dist/plugins/fusion-plugin-cursor-runtime/package.json +1 -1
  117. package/dist/plugins/fusion-plugin-dependency-graph/bundled.js +35 -104
  118. package/dist/plugins/fusion-plugin-dependency-graph/package.json +1 -1
  119. package/dist/plugins/fusion-plugin-droid-runtime/bundled.js +35 -104
  120. package/dist/plugins/fusion-plugin-droid-runtime/package.json +1 -1
  121. package/dist/plugins/fusion-plugin-grok-runtime/bundled.js +35 -104
  122. package/dist/plugins/fusion-plugin-grok-runtime/package.json +1 -1
  123. package/dist/plugins/fusion-plugin-hermes-runtime/bundled.js +35 -104
  124. package/dist/plugins/fusion-plugin-hermes-runtime/package.json +1 -1
  125. package/dist/plugins/fusion-plugin-linear-import/bundled.js +35 -104
  126. package/dist/plugins/fusion-plugin-linear-import/package.json +1 -1
  127. package/dist/plugins/fusion-plugin-omp-runtime/bundled.js +35 -104
  128. package/dist/plugins/fusion-plugin-omp-runtime/package.json +1 -1
  129. package/dist/plugins/fusion-plugin-openclaw-runtime/bundled.js +35 -104
  130. package/dist/plugins/fusion-plugin-openclaw-runtime/package.json +1 -1
  131. package/dist/plugins/fusion-plugin-paperclip-runtime/bundled.js +35 -104
  132. package/dist/plugins/fusion-plugin-paperclip-runtime/package.json +1 -1
  133. package/dist/plugins/fusion-plugin-quality/bundled.js +35 -104
  134. package/dist/plugins/fusion-plugin-quality/package.json +1 -1
  135. package/dist/plugins/fusion-plugin-reports/bundled.js +35 -104
  136. package/dist/plugins/fusion-plugin-reports/package.json +1 -1
  137. package/dist/plugins/fusion-plugin-roadmap/bundled.js +35 -104
  138. package/dist/plugins/fusion-plugin-roadmap/package.json +1 -1
  139. package/dist/plugins/fusion-plugin-todos/bundled.js +35 -104
  140. package/dist/plugins/fusion-plugin-todos/package.json +1 -1
  141. package/dist/plugins/fusion-plugin-whatsapp-chat/bundled.js +35 -104
  142. package/dist/plugins/fusion-plugin-whatsapp-chat/package.json +1 -1
  143. package/package.json +1 -1
  144. package/skill/fusion/references/extension-tools.md +2 -1
  145. package/skill/fusion/references/fusion-capabilities.md +1 -1
  146. package/skill/fusion/references/task-structure.md +1 -1
  147. package/skill/fusion/workflows/specifications.md +2 -2
  148. package/dist/client/assets/ChatView-gH7QX3TI.js +0 -13
  149. package/dist/client/assets/SettingsModal-BAzmMjr9.js +0 -21
  150. package/dist/client/assets/app-B-TfWH9b.js +0 -5
  151. package/dist/client/assets/app-B2RDV_-t.js +0 -13
  152. package/dist/client/assets/app-CDo0mF2S.js +0 -5
  153. package/dist/client/assets/app-Cc18kAQS.js +0 -13
  154. package/dist/client/assets/app-DFF79EUn.js +0 -13
  155. package/dist/client/assets/app-DSeFHxgj.js +0 -13
  156. package/dist/client/assets/app-Ducr0y6r.js +0 -13
  157. package/dist/client/assets/channel-CP2ySYs0.js +0 -1
  158. package/dist/client/assets/classDiagram-4FO5ZUOK-DKkOBtzM.js +0 -1
  159. package/dist/client/assets/classDiagram-v2-Q7XG4LA2-DKkOBtzM.js +0 -1
  160. package/dist/client/assets/index-DXpztECA.css +0 -1
  161. package/dist/client/assets/index-I32FijPT.js +0 -2821
@@ -1,4 +1,4 @@
1
- import{p as lr}from"./chunk-4BX2VUAB-hjiKRusj.js";import{I as hr}from"./chunk-QZHKN3VN-MCOlJ723.js";import{q as $r,p as fr,s as gr,g as ur,a as yr,b as xr,_ as h,E as J,l as w,c as W,u as mr,F as pr,z as br,j as B,G as wr,H as kr,I as vr}from"./mermaid.core-B2zD934i.js";import{p as Cr}from"./wardley-L42UT6IY-BOqYltGN.js";import{s as Er}from"./vendor-reactflow-BlIeoTu4.js";import"./index-I32FijPT.js";import"./vendor-react-SZ_qB27O.js";import"./vendor-i18n-Duky4gdQ.js";import"./vendor-codemirror-CcrtqoCy.js";import"./vendor-xterm-BNq00GSj.js";import"./step-yuy0qJer.js";var m={NORMAL:0,REVERSE:1,HIGHLIGHT:2,MERGE:3,CHERRY_PICK:4},Br=kr.gitGraph,S=h(()=>wr({...Br,...J().gitGraph}),"getConfig"),d=new hr(()=>{const r=S(),e=r.mainBranchName,t=r.mainBranchOrder;return{mainBranchName:e,commits:new Map,head:null,branchConfig:new Map([[e,{name:e,order:t}]]),branches:new Map([[e,null]]),currBranch:e,direction:"LR",seq:0,options:{}}});function Y(){return vr({length:7})}h(Y,"getID");function tr(r,e){const t=Object.create(null);return r.reduce((s,o)=>{const i=e(o);return t[i]||(t[i]=!0,s.push(o)),s},[])}h(tr,"uniqBy");var Tr=h(function(r){d.records.direction=r},"setDirection"),Lr=h(function(r){w.debug("options str",r),r=r?.trim(),r=r||"{}";try{d.records.options=JSON.parse(r)}catch(e){w.error("error while parsing gitGraph options",e.message)}},"setOptions"),Mr=h(function(){return d.records.options},"getOptions"),Ir=h(function(r){let e=r.msg,t=r.id;const s=r.type;let o=r.tags;w.info("commit",e,t,s,o),w.debug("Entering commit:",e,t,s,o);const i=S();t=B.sanitizeText(t,i),e=B.sanitizeText(e,i),o=o?.map(a=>B.sanitizeText(a,i));const n={id:t||d.records.seq+"-"+Y(),message:e,seq:d.records.seq++,type:s??m.NORMAL,tags:o??[],parents:d.records.head==null?[]:[d.records.head.id],branch:d.records.currBranch};d.records.head=n,w.info("main branch",i.mainBranchName),d.records.commits.has(n.id)&&w.warn(`Commit ID ${n.id} already exists`),d.records.commits.set(n.id,n),d.records.branches.set(d.records.currBranch,n.id),w.debug("in pushCommit "+n.id)},"commit"),Rr=h(function(r){let e=r.name;const t=r.order;if(e=B.sanitizeText(e,S()),d.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}")`);d.records.branches.set(e,d.records.head!=null?d.records.head.id:null),d.records.branchConfig.set(e,{name:e,order:t}),ar(e),w.debug("in createBranch")},"branch"),Or=h(r=>{let e=r.branch,t=r.id;const s=r.type,o=r.tags,i=S();e=B.sanitizeText(e,i),t&&(t=B.sanitizeText(t,i));const n=d.records.branches.get(d.records.currBranch),a=d.records.branches.get(e),l=n?d.records.commits.get(n):void 0,f=a?d.records.commits.get(a):void 0;if(l&&f&&l.branch===e)throw new Error(`Cannot merge branch '${e}' into itself.`);if(d.records.currBranch===e){const c=new Error('Incorrect usage of "merge". Cannot merge a branch to itself');throw c.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["branch abc"]},c}if(l===void 0||!l){const c=new Error(`Incorrect usage of "merge". Current branch (${d.records.currBranch})has no commits`);throw c.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["commit"]},c}if(!d.records.branches.has(e)){const c=new Error('Incorrect usage of "merge". Branch to be merged ('+e+") does not exist");throw c.hash={text:`merge ${e}`,token:`merge ${e}`,expected:[`branch ${e}`]},c}if(f===void 0||!f){const c=new Error('Incorrect usage of "merge". Branch to be merged ('+e+") has no commits");throw c.hash={text:`merge ${e}`,token:`merge ${e}`,expected:['"commit"']},c}if(l===f){const c=new Error('Incorrect usage of "merge". Both branches have same head');throw c.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["branch abc"]},c}if(t&&d.records.commits.has(t)){const c=new Error('Incorrect usage of "merge". Commit with id:'+t+" already exists, use different custom id");throw c.hash={text:`merge ${e} ${t} ${s} ${o?.join(" ")}`,token:`merge ${e} ${t} ${s} ${o?.join(" ")}`,expected:[`merge ${e} ${t}_UNIQUE ${s} ${o?.join(" ")}`]},c}const g=a||"",$={id:t||`${d.records.seq}-${Y()}`,message:`merged branch ${e} into ${d.records.currBranch}`,seq:d.records.seq++,parents:d.records.head==null?[]:[d.records.head.id,g],branch:d.records.currBranch,type:m.MERGE,customType:s,customId:!!t,tags:o??[]};d.records.head=$,d.records.commits.set($.id,$),d.records.branches.set(d.records.currBranch,$.id),w.debug(d.records.branches),w.debug("in mergeBranch")},"merge"),_r=h(function(r){let e=r.id,t=r.targetId,s=r.tags,o=r.parent;w.debug("Entering cherryPick:",e,t,s);const i=S();if(e=B.sanitizeText(e,i),t=B.sanitizeText(t,i),s=s?.map(l=>B.sanitizeText(l,i)),o=B.sanitizeText(o,i),!e||!d.records.commits.has(e)){const l=new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');throw l.hash={text:`cherryPick ${e} ${t}`,token:`cherryPick ${e} ${t}`,expected:["cherry-pick abc"]},l}const n=d.records.commits.get(e);if(n===void 0||!n)throw new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');if(o&&!(Array.isArray(n.parents)&&n.parents.includes(o)))throw new Error("Invalid operation: The specified parent commit is not an immediate parent of the cherry-picked commit.");const a=n.branch;if(n.type===m.MERGE&&!o)throw new Error("Incorrect usage of cherry-pick: If the source commit is a merge commit, an immediate parent commit must be specified.");if(!t||!d.records.commits.has(t)){if(a===d.records.currBranch){const $=new Error('Incorrect usage of "cherryPick". Source commit is already on current branch');throw $.hash={text:`cherryPick ${e} ${t}`,token:`cherryPick ${e} ${t}`,expected:["cherry-pick abc"]},$}const l=d.records.branches.get(d.records.currBranch);if(l===void 0||!l){const $=new Error(`Incorrect usage of "cherry-pick". Current branch (${d.records.currBranch})has no commits`);throw $.hash={text:`cherryPick ${e} ${t}`,token:`cherryPick ${e} ${t}`,expected:["cherry-pick abc"]},$}const f=d.records.commits.get(l);if(f===void 0||!f){const $=new Error(`Incorrect usage of "cherry-pick". Current branch (${d.records.currBranch})has no commits`);throw $.hash={text:`cherryPick ${e} ${t}`,token:`cherryPick ${e} ${t}`,expected:["cherry-pick abc"]},$}const g={id:d.records.seq+"-"+Y(),message:`cherry-picked ${n?.message} into ${d.records.currBranch}`,seq:d.records.seq++,parents:d.records.head==null?[]:[d.records.head.id,n.id],branch:d.records.currBranch,type:m.CHERRY_PICK,tags:s?s.filter(Boolean):[`cherry-pick:${n.id}${n.type===m.MERGE?`|parent:${o}`:""}`]};d.records.head=g,d.records.commits.set(g.id,g),d.records.branches.set(d.records.currBranch,g.id),w.debug(d.records.branches),w.debug("in cherryPick")}},"cherryPick"),ar=h(function(r){if(r=B.sanitizeText(r,S()),d.records.branches.has(r)){d.records.currBranch=r;const e=d.records.branches.get(d.records.currBranch);e===void 0||!e?d.records.head=null:d.records.head=d.records.commits.get(e)??null}else{const e=new Error(`Trying to checkout branch which is not yet created. (Help try using "branch ${r}")`);throw e.hash={text:`checkout ${r}`,token:`checkout ${r}`,expected:[`branch ${r}`]},e}},"checkout");function V(r,e,t){const s=r.indexOf(e);s===-1?r.push(t):r.splice(s,1,t)}h(V,"upsert");function Q(r){const e=r.reduce((o,i)=>o.seq>i.seq?o:i,r[0]);let t="";r.forEach(function(o){o===e?t+=" *":t+=" |"});const s=[t,e.id,e.seq];for(const o in d.records.branches)d.records.branches.get(o)===e.id&&s.push(o);if(w.debug(s.join(" ")),e.parents&&e.parents.length==2&&e.parents[0]&&e.parents[1]){const o=d.records.commits.get(e.parents[0]);V(r,e,o),e.parents[1]&&r.push(d.records.commits.get(e.parents[1]))}else{if(e.parents.length==0)return;if(e.parents[0]){const o=d.records.commits.get(e.parents[0]);V(r,e,o)}}r=tr(r,o=>o.id),Q(r)}h(Q,"prettyPrintCommitHistory");var Gr=h(function(){w.debug(d.records.commits);const r=nr()[0];Q([r])},"prettyPrint"),Hr=h(function(){d.reset(),br()},"clear"),Sr=h(function(){return[...d.records.branchConfig.values()].map((e,t)=>e.order!==null&&e.order!==void 0?e:{...e,order:parseFloat(`0.${t}`)}).sort((e,t)=>(e.order??0)-(t.order??0)).map(({name:e})=>({name:e}))},"getBranchesAsObjArray"),Ar=h(function(){return d.records.branches},"getBranches"),Dr=h(function(){return d.records.commits},"getCommits"),nr=h(function(){const r=[...d.records.commits.values()];return r.forEach(function(e){w.debug(e.id)}),r.sort((e,t)=>e.seq-t.seq),r},"getCommitsArray"),qr=h(function(){return d.records.currBranch},"getCurrentBranch"),Pr=h(function(){return d.records.direction},"getDirection"),Wr=h(function(){return d.records.head},"getHead"),sr={commitType:m,getConfig:S,setDirection:Tr,setOptions:Lr,getOptions:Mr,commit:Ir,branch:Rr,merge:Or,cherryPick:_r,checkout:ar,prettyPrint:Gr,clear:Hr,getBranchesAsObjArray:Sr,getBranches:Ar,getCommits:Dr,getCommitsArray:nr,getCurrentBranch:qr,getDirection:Pr,getHead:Wr,setAccTitle:xr,getAccTitle:yr,getAccDescription:ur,setAccDescription:gr,setDiagramTitle:fr,getDiagramTitle:$r},Nr=h((r,e)=>{lr(r,e),r.dir&&e.setDirection(r.dir);for(const t of r.statements)Fr(t,e)},"populate"),Fr=h((r,e)=>{const s={Commit:h(o=>e.commit(zr(o)),"Commit"),Branch:h(o=>e.branch(Yr(o)),"Branch"),Merge:h(o=>e.merge(jr(o)),"Merge"),Checkout:h(o=>e.checkout(Ur(o)),"Checkout"),CherryPicking:h(o=>e.cherryPick(Kr(o)),"CherryPicking")}[r.$type];s?s(r):w.error(`Unknown statement type: ${r.$type}`)},"parseStatement"),zr=h(r=>({id:r.id,msg:r.message??"",type:r.type!==void 0?m[r.type]:m.NORMAL,tags:r.tags??void 0}),"parseCommit"),Yr=h(r=>({name:r.name,order:r.order??0}),"parseBranch"),jr=h(r=>({branch:r.branch,id:r.id??"",type:r.type!==void 0?m[r.type]:void 0,tags:r.tags??void 0}),"parseMerge"),Ur=h(r=>r.branch,"parseCheckout"),Kr=h(r=>({id:r.id,targetId:"",tags:r.tags?.length===0?void 0:r.tags,parent:r.parent}),"parseCherryPicking"),Vr={parse:h(async r=>{const e=await Cr("gitGraph",r);w.debug(e),Nr(e,sr)},"parse")},O=10,_=40,L=4,I=2,G=8,j=new Set(["redux","redux-dark","redux-color","redux-dark-color"]),X=12,Z=new Set(["redux-color","redux-dark-color"]),Xr=new Set(["dark","redux-dark","redux-dark-color","neo-dark"]),H=h((r,e,t=!1)=>t&&r>0?(r-1)%(e-1)+1:r%e,"calcColorIndex"),C=new Map,E=new Map,F=30,q=new Map,z=[],R=0,y="LR",Jr=h(()=>{C.clear(),E.clear(),q.clear(),R=0,z=[],y="LR"},"clear"),or=h(r=>{const e=document.createElementNS("http://www.w3.org/2000/svg","text");return(typeof r=="string"?r.split(/\\n|\n|<br\s*\/?>/gi):r).forEach(s=>{const o=document.createElementNS("http://www.w3.org/2000/svg","tspan");o.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),o.setAttribute("dy","1em"),o.setAttribute("x","0"),o.setAttribute("class","row"),o.textContent=s.trim(),e.appendChild(o)}),e},"drawText"),cr=h(r=>{let e,t,s;return y==="BT"?(t=h((o,i)=>o<=i,"comparisonFunc"),s=1/0):(t=h((o,i)=>o>=i,"comparisonFunc"),s=0),r.forEach(o=>{const i=y==="TB"||y=="BT"?E.get(o)?.y:E.get(o)?.x;i!==void 0&&t(i,s)&&(e=o,s=i)}),e},"findClosestParent"),Qr=h(r=>{let e="",t=1/0;return r.forEach(s=>{const o=E.get(s).y;o<=t&&(e=s,t=o)}),e||void 0},"findClosestParentBT"),Zr=h((r,e,t)=>{let s=t,o=t;const i=[];r.forEach(n=>{const a=e.get(n);if(!a)throw new Error(`Commit not found for key ${n}`);a.parents.length?(s=ee(a),o=Math.max(s,o)):i.push(a),te(a,s)}),s=o,i.forEach(n=>{ae(n,s,t)}),r.forEach(n=>{const a=e.get(n);if(a?.parents.length){const l=Qr(a.parents);s=E.get(l).y-_,s<=o&&(o=s);const f=C.get(a.branch).pos,g=s-O;E.set(a.id,{x:f,y:g})}})},"setParallelBTPos"),re=h(r=>{const e=cr(r.parents.filter(s=>s!==null));if(!e)throw new Error(`Closest parent not found for commit ${r.id}`);const t=E.get(e)?.y;if(t===void 0)throw new Error(`Closest parent position not found for commit ${r.id}`);return t},"findClosestParentPos"),ee=h(r=>re(r)+_,"calculateCommitPosition"),te=h((r,e)=>{const t=C.get(r.branch);if(!t)throw new Error(`Branch not found for commit ${r.id}`);const s=t.pos,o=e+O;return E.set(r.id,{x:s,y:o}),{x:s,y:o}},"setCommitPosition"),ae=h((r,e,t)=>{const s=C.get(r.branch);if(!s)throw new Error(`Branch not found for commit ${r.id}`);const o=e+t,i=s.pos;E.set(r.id,{x:i,y:o})},"setRootPosition"),ne=h((r,e,t,s,o,i)=>{const{theme:n}=W(),a=j.has(n??""),l=Z.has(n??""),f=Xr.has(n??"");if(i===m.HIGHLIGHT)r.append("rect").attr("x",t.x-10+(a?3:0)).attr("y",t.y-10+(a?3:0)).attr("width",a?14:20).attr("height",a?14:20).attr("class",`commit ${e.id} commit-highlight${H(o,G,l)} ${s}-outer`),r.append("rect").attr("x",t.x-6+(a?2:0)).attr("y",t.y-6+(a?2:0)).attr("width",a?8:12).attr("height",a?8:12).attr("class",`commit ${e.id} commit${H(o,G,l)} ${s}-inner`);else if(i===m.CHERRY_PICK)r.append("circle").attr("cx",t.x).attr("cy",t.y).attr("r",a?7:10).attr("class",`commit ${e.id} ${s}`),r.append("circle").attr("cx",t.x-3).attr("cy",t.y+2).attr("r",a?2.5:2.75).attr("fill",f?"#000000":"#fff").attr("class",`commit ${e.id} ${s}`),r.append("circle").attr("cx",t.x+3).attr("cy",t.y+2).attr("r",a?2.5:2.75).attr("fill",f?"#000000":"#fff").attr("class",`commit ${e.id} ${s}`),r.append("line").attr("x1",t.x+3).attr("y1",t.y+1).attr("x2",t.x).attr("y2",t.y-5).attr("stroke",f?"#000000":"#fff").attr("class",`commit ${e.id} ${s}`),r.append("line").attr("x1",t.x-3).attr("y1",t.y+1).attr("x2",t.x).attr("y2",t.y-5).attr("stroke",f?"#000000":"#fff").attr("class",`commit ${e.id} ${s}`);else{const g=r.append("circle");if(g.attr("cx",t.x),g.attr("cy",t.y),g.attr("r",a?7:10),g.attr("class",`commit ${e.id} commit${H(o,G,l)}`),i===m.MERGE){const $=r.append("circle");$.attr("cx",t.x),$.attr("cy",t.y),$.attr("r",a?5:6),$.attr("class",`commit ${s} ${e.id} commit${H(o,G,l)}`)}if(i===m.REVERSE){const $=r.append("path"),c=a?4:5;$.attr("d",`M ${t.x-c},${t.y-c}L${t.x+c},${t.y+c}M${t.x-c},${t.y+c}L${t.x+c},${t.y-c}`).attr("class",`commit ${s} ${e.id} commit${H(o,G,l)}`)}}},"drawCommitBullet"),se=h((r,e,t,s,o)=>{if(e.type!==m.CHERRY_PICK&&(e.customId&&e.type===m.MERGE||e.type!==m.MERGE)&&o.showCommitLabel){const i=r.append("g"),n=i.insert("rect").attr("class","commit-label-bkg"),a=i.append("text").attr("x",s).attr("y",t.y+25).attr("class","commit-label").text(e.id),l=a.node()?.getBBox();if(l&&(n.attr("x",t.posWithOffset-l.width/2-I).attr("y",t.y+13.5).attr("width",l.width+2*I).attr("height",l.height+2*I),y==="TB"||y==="BT"?(n.attr("x",t.x-(l.width+4*L+5)).attr("y",t.y-12),a.attr("x",t.x-(l.width+4*L)).attr("y",t.y+l.height-12)):a.attr("x",t.posWithOffset-l.width/2),o.rotateCommitLabel))if(y==="TB"||y==="BT")a.attr("transform","rotate(-45, "+t.x+", "+t.y+")"),n.attr("transform","rotate(-45, "+t.x+", "+t.y+")");else{const f=-7.5-(l.width+10)/25*9.5,g=10+l.width/25*8.5;i.attr("transform","translate("+f+", "+g+") rotate(-45, "+s+", "+t.y+")")}}},"drawCommitLabel"),oe=h((r,e,t,s)=>{if(e.tags.length>0){let o=0,i=0,n=0;const a=[];for(const l of e.tags.reverse()){const f=r.insert("polygon"),g=r.append("circle"),$=r.append("text").attr("y",t.y-16-o).attr("class","tag-label").text(l),c=$.node()?.getBBox();if(!c)throw new Error("Tag bbox not found");i=Math.max(i,c.width),n=Math.max(n,c.height),$.attr("x",t.posWithOffset-c.width/2),a.push({tag:$,hole:g,rect:f,yOffset:o}),o+=20}for(const{tag:l,hole:f,rect:g,yOffset:$}of a){const c=n/2,x=t.y-19.2-$;if(g.attr("class","tag-label-bkg").attr("points",`
1
+ import{p as lr}from"./chunk-4BX2VUAB-dJL0n3nn.js";import{I as hr}from"./chunk-QZHKN3VN-BxbHBfKJ.js";import{q as $r,p as fr,s as gr,g as ur,a as yr,b as xr,_ as h,E as J,l as w,c as W,u as mr,F as pr,z as br,j as B,G as wr,H as kr,I as vr}from"./mermaid.core-Bc_0VLJw.js";import{p as Cr}from"./wardley-L42UT6IY-DdYkfF5d.js";import{s as Er}from"./vendor-reactflow-BlIeoTu4.js";import"./index-B8PcG8AJ.js";import"./vendor-react-SZ_qB27O.js";import"./vendor-i18n-Duky4gdQ.js";import"./vendor-codemirror-CcrtqoCy.js";import"./vendor-xterm-BNq00GSj.js";import"./step-yuy0qJer.js";var m={NORMAL:0,REVERSE:1,HIGHLIGHT:2,MERGE:3,CHERRY_PICK:4},Br=kr.gitGraph,S=h(()=>wr({...Br,...J().gitGraph}),"getConfig"),d=new hr(()=>{const r=S(),e=r.mainBranchName,t=r.mainBranchOrder;return{mainBranchName:e,commits:new Map,head:null,branchConfig:new Map([[e,{name:e,order:t}]]),branches:new Map([[e,null]]),currBranch:e,direction:"LR",seq:0,options:{}}});function Y(){return vr({length:7})}h(Y,"getID");function tr(r,e){const t=Object.create(null);return r.reduce((s,o)=>{const i=e(o);return t[i]||(t[i]=!0,s.push(o)),s},[])}h(tr,"uniqBy");var Tr=h(function(r){d.records.direction=r},"setDirection"),Lr=h(function(r){w.debug("options str",r),r=r?.trim(),r=r||"{}";try{d.records.options=JSON.parse(r)}catch(e){w.error("error while parsing gitGraph options",e.message)}},"setOptions"),Mr=h(function(){return d.records.options},"getOptions"),Ir=h(function(r){let e=r.msg,t=r.id;const s=r.type;let o=r.tags;w.info("commit",e,t,s,o),w.debug("Entering commit:",e,t,s,o);const i=S();t=B.sanitizeText(t,i),e=B.sanitizeText(e,i),o=o?.map(a=>B.sanitizeText(a,i));const n={id:t||d.records.seq+"-"+Y(),message:e,seq:d.records.seq++,type:s??m.NORMAL,tags:o??[],parents:d.records.head==null?[]:[d.records.head.id],branch:d.records.currBranch};d.records.head=n,w.info("main branch",i.mainBranchName),d.records.commits.has(n.id)&&w.warn(`Commit ID ${n.id} already exists`),d.records.commits.set(n.id,n),d.records.branches.set(d.records.currBranch,n.id),w.debug("in pushCommit "+n.id)},"commit"),Rr=h(function(r){let e=r.name;const t=r.order;if(e=B.sanitizeText(e,S()),d.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}")`);d.records.branches.set(e,d.records.head!=null?d.records.head.id:null),d.records.branchConfig.set(e,{name:e,order:t}),ar(e),w.debug("in createBranch")},"branch"),Or=h(r=>{let e=r.branch,t=r.id;const s=r.type,o=r.tags,i=S();e=B.sanitizeText(e,i),t&&(t=B.sanitizeText(t,i));const n=d.records.branches.get(d.records.currBranch),a=d.records.branches.get(e),l=n?d.records.commits.get(n):void 0,f=a?d.records.commits.get(a):void 0;if(l&&f&&l.branch===e)throw new Error(`Cannot merge branch '${e}' into itself.`);if(d.records.currBranch===e){const c=new Error('Incorrect usage of "merge". Cannot merge a branch to itself');throw c.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["branch abc"]},c}if(l===void 0||!l){const c=new Error(`Incorrect usage of "merge". Current branch (${d.records.currBranch})has no commits`);throw c.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["commit"]},c}if(!d.records.branches.has(e)){const c=new Error('Incorrect usage of "merge". Branch to be merged ('+e+") does not exist");throw c.hash={text:`merge ${e}`,token:`merge ${e}`,expected:[`branch ${e}`]},c}if(f===void 0||!f){const c=new Error('Incorrect usage of "merge". Branch to be merged ('+e+") has no commits");throw c.hash={text:`merge ${e}`,token:`merge ${e}`,expected:['"commit"']},c}if(l===f){const c=new Error('Incorrect usage of "merge". Both branches have same head');throw c.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["branch abc"]},c}if(t&&d.records.commits.has(t)){const c=new Error('Incorrect usage of "merge". Commit with id:'+t+" already exists, use different custom id");throw c.hash={text:`merge ${e} ${t} ${s} ${o?.join(" ")}`,token:`merge ${e} ${t} ${s} ${o?.join(" ")}`,expected:[`merge ${e} ${t}_UNIQUE ${s} ${o?.join(" ")}`]},c}const g=a||"",$={id:t||`${d.records.seq}-${Y()}`,message:`merged branch ${e} into ${d.records.currBranch}`,seq:d.records.seq++,parents:d.records.head==null?[]:[d.records.head.id,g],branch:d.records.currBranch,type:m.MERGE,customType:s,customId:!!t,tags:o??[]};d.records.head=$,d.records.commits.set($.id,$),d.records.branches.set(d.records.currBranch,$.id),w.debug(d.records.branches),w.debug("in mergeBranch")},"merge"),_r=h(function(r){let e=r.id,t=r.targetId,s=r.tags,o=r.parent;w.debug("Entering cherryPick:",e,t,s);const i=S();if(e=B.sanitizeText(e,i),t=B.sanitizeText(t,i),s=s?.map(l=>B.sanitizeText(l,i)),o=B.sanitizeText(o,i),!e||!d.records.commits.has(e)){const l=new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');throw l.hash={text:`cherryPick ${e} ${t}`,token:`cherryPick ${e} ${t}`,expected:["cherry-pick abc"]},l}const n=d.records.commits.get(e);if(n===void 0||!n)throw new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');if(o&&!(Array.isArray(n.parents)&&n.parents.includes(o)))throw new Error("Invalid operation: The specified parent commit is not an immediate parent of the cherry-picked commit.");const a=n.branch;if(n.type===m.MERGE&&!o)throw new Error("Incorrect usage of cherry-pick: If the source commit is a merge commit, an immediate parent commit must be specified.");if(!t||!d.records.commits.has(t)){if(a===d.records.currBranch){const $=new Error('Incorrect usage of "cherryPick". Source commit is already on current branch');throw $.hash={text:`cherryPick ${e} ${t}`,token:`cherryPick ${e} ${t}`,expected:["cherry-pick abc"]},$}const l=d.records.branches.get(d.records.currBranch);if(l===void 0||!l){const $=new Error(`Incorrect usage of "cherry-pick". Current branch (${d.records.currBranch})has no commits`);throw $.hash={text:`cherryPick ${e} ${t}`,token:`cherryPick ${e} ${t}`,expected:["cherry-pick abc"]},$}const f=d.records.commits.get(l);if(f===void 0||!f){const $=new Error(`Incorrect usage of "cherry-pick". Current branch (${d.records.currBranch})has no commits`);throw $.hash={text:`cherryPick ${e} ${t}`,token:`cherryPick ${e} ${t}`,expected:["cherry-pick abc"]},$}const g={id:d.records.seq+"-"+Y(),message:`cherry-picked ${n?.message} into ${d.records.currBranch}`,seq:d.records.seq++,parents:d.records.head==null?[]:[d.records.head.id,n.id],branch:d.records.currBranch,type:m.CHERRY_PICK,tags:s?s.filter(Boolean):[`cherry-pick:${n.id}${n.type===m.MERGE?`|parent:${o}`:""}`]};d.records.head=g,d.records.commits.set(g.id,g),d.records.branches.set(d.records.currBranch,g.id),w.debug(d.records.branches),w.debug("in cherryPick")}},"cherryPick"),ar=h(function(r){if(r=B.sanitizeText(r,S()),d.records.branches.has(r)){d.records.currBranch=r;const e=d.records.branches.get(d.records.currBranch);e===void 0||!e?d.records.head=null:d.records.head=d.records.commits.get(e)??null}else{const e=new Error(`Trying to checkout branch which is not yet created. (Help try using "branch ${r}")`);throw e.hash={text:`checkout ${r}`,token:`checkout ${r}`,expected:[`branch ${r}`]},e}},"checkout");function V(r,e,t){const s=r.indexOf(e);s===-1?r.push(t):r.splice(s,1,t)}h(V,"upsert");function Q(r){const e=r.reduce((o,i)=>o.seq>i.seq?o:i,r[0]);let t="";r.forEach(function(o){o===e?t+=" *":t+=" |"});const s=[t,e.id,e.seq];for(const o in d.records.branches)d.records.branches.get(o)===e.id&&s.push(o);if(w.debug(s.join(" ")),e.parents&&e.parents.length==2&&e.parents[0]&&e.parents[1]){const o=d.records.commits.get(e.parents[0]);V(r,e,o),e.parents[1]&&r.push(d.records.commits.get(e.parents[1]))}else{if(e.parents.length==0)return;if(e.parents[0]){const o=d.records.commits.get(e.parents[0]);V(r,e,o)}}r=tr(r,o=>o.id),Q(r)}h(Q,"prettyPrintCommitHistory");var Gr=h(function(){w.debug(d.records.commits);const r=nr()[0];Q([r])},"prettyPrint"),Hr=h(function(){d.reset(),br()},"clear"),Sr=h(function(){return[...d.records.branchConfig.values()].map((e,t)=>e.order!==null&&e.order!==void 0?e:{...e,order:parseFloat(`0.${t}`)}).sort((e,t)=>(e.order??0)-(t.order??0)).map(({name:e})=>({name:e}))},"getBranchesAsObjArray"),Ar=h(function(){return d.records.branches},"getBranches"),Dr=h(function(){return d.records.commits},"getCommits"),nr=h(function(){const r=[...d.records.commits.values()];return r.forEach(function(e){w.debug(e.id)}),r.sort((e,t)=>e.seq-t.seq),r},"getCommitsArray"),qr=h(function(){return d.records.currBranch},"getCurrentBranch"),Pr=h(function(){return d.records.direction},"getDirection"),Wr=h(function(){return d.records.head},"getHead"),sr={commitType:m,getConfig:S,setDirection:Tr,setOptions:Lr,getOptions:Mr,commit:Ir,branch:Rr,merge:Or,cherryPick:_r,checkout:ar,prettyPrint:Gr,clear:Hr,getBranchesAsObjArray:Sr,getBranches:Ar,getCommits:Dr,getCommitsArray:nr,getCurrentBranch:qr,getDirection:Pr,getHead:Wr,setAccTitle:xr,getAccTitle:yr,getAccDescription:ur,setAccDescription:gr,setDiagramTitle:fr,getDiagramTitle:$r},Nr=h((r,e)=>{lr(r,e),r.dir&&e.setDirection(r.dir);for(const t of r.statements)Fr(t,e)},"populate"),Fr=h((r,e)=>{const s={Commit:h(o=>e.commit(zr(o)),"Commit"),Branch:h(o=>e.branch(Yr(o)),"Branch"),Merge:h(o=>e.merge(jr(o)),"Merge"),Checkout:h(o=>e.checkout(Ur(o)),"Checkout"),CherryPicking:h(o=>e.cherryPick(Kr(o)),"CherryPicking")}[r.$type];s?s(r):w.error(`Unknown statement type: ${r.$type}`)},"parseStatement"),zr=h(r=>({id:r.id,msg:r.message??"",type:r.type!==void 0?m[r.type]:m.NORMAL,tags:r.tags??void 0}),"parseCommit"),Yr=h(r=>({name:r.name,order:r.order??0}),"parseBranch"),jr=h(r=>({branch:r.branch,id:r.id??"",type:r.type!==void 0?m[r.type]:void 0,tags:r.tags??void 0}),"parseMerge"),Ur=h(r=>r.branch,"parseCheckout"),Kr=h(r=>({id:r.id,targetId:"",tags:r.tags?.length===0?void 0:r.tags,parent:r.parent}),"parseCherryPicking"),Vr={parse:h(async r=>{const e=await Cr("gitGraph",r);w.debug(e),Nr(e,sr)},"parse")},O=10,_=40,L=4,I=2,G=8,j=new Set(["redux","redux-dark","redux-color","redux-dark-color"]),X=12,Z=new Set(["redux-color","redux-dark-color"]),Xr=new Set(["dark","redux-dark","redux-dark-color","neo-dark"]),H=h((r,e,t=!1)=>t&&r>0?(r-1)%(e-1)+1:r%e,"calcColorIndex"),C=new Map,E=new Map,F=30,q=new Map,z=[],R=0,y="LR",Jr=h(()=>{C.clear(),E.clear(),q.clear(),R=0,z=[],y="LR"},"clear"),or=h(r=>{const e=document.createElementNS("http://www.w3.org/2000/svg","text");return(typeof r=="string"?r.split(/\\n|\n|<br\s*\/?>/gi):r).forEach(s=>{const o=document.createElementNS("http://www.w3.org/2000/svg","tspan");o.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),o.setAttribute("dy","1em"),o.setAttribute("x","0"),o.setAttribute("class","row"),o.textContent=s.trim(),e.appendChild(o)}),e},"drawText"),cr=h(r=>{let e,t,s;return y==="BT"?(t=h((o,i)=>o<=i,"comparisonFunc"),s=1/0):(t=h((o,i)=>o>=i,"comparisonFunc"),s=0),r.forEach(o=>{const i=y==="TB"||y=="BT"?E.get(o)?.y:E.get(o)?.x;i!==void 0&&t(i,s)&&(e=o,s=i)}),e},"findClosestParent"),Qr=h(r=>{let e="",t=1/0;return r.forEach(s=>{const o=E.get(s).y;o<=t&&(e=s,t=o)}),e||void 0},"findClosestParentBT"),Zr=h((r,e,t)=>{let s=t,o=t;const i=[];r.forEach(n=>{const a=e.get(n);if(!a)throw new Error(`Commit not found for key ${n}`);a.parents.length?(s=ee(a),o=Math.max(s,o)):i.push(a),te(a,s)}),s=o,i.forEach(n=>{ae(n,s,t)}),r.forEach(n=>{const a=e.get(n);if(a?.parents.length){const l=Qr(a.parents);s=E.get(l).y-_,s<=o&&(o=s);const f=C.get(a.branch).pos,g=s-O;E.set(a.id,{x:f,y:g})}})},"setParallelBTPos"),re=h(r=>{const e=cr(r.parents.filter(s=>s!==null));if(!e)throw new Error(`Closest parent not found for commit ${r.id}`);const t=E.get(e)?.y;if(t===void 0)throw new Error(`Closest parent position not found for commit ${r.id}`);return t},"findClosestParentPos"),ee=h(r=>re(r)+_,"calculateCommitPosition"),te=h((r,e)=>{const t=C.get(r.branch);if(!t)throw new Error(`Branch not found for commit ${r.id}`);const s=t.pos,o=e+O;return E.set(r.id,{x:s,y:o}),{x:s,y:o}},"setCommitPosition"),ae=h((r,e,t)=>{const s=C.get(r.branch);if(!s)throw new Error(`Branch not found for commit ${r.id}`);const o=e+t,i=s.pos;E.set(r.id,{x:i,y:o})},"setRootPosition"),ne=h((r,e,t,s,o,i)=>{const{theme:n}=W(),a=j.has(n??""),l=Z.has(n??""),f=Xr.has(n??"");if(i===m.HIGHLIGHT)r.append("rect").attr("x",t.x-10+(a?3:0)).attr("y",t.y-10+(a?3:0)).attr("width",a?14:20).attr("height",a?14:20).attr("class",`commit ${e.id} commit-highlight${H(o,G,l)} ${s}-outer`),r.append("rect").attr("x",t.x-6+(a?2:0)).attr("y",t.y-6+(a?2:0)).attr("width",a?8:12).attr("height",a?8:12).attr("class",`commit ${e.id} commit${H(o,G,l)} ${s}-inner`);else if(i===m.CHERRY_PICK)r.append("circle").attr("cx",t.x).attr("cy",t.y).attr("r",a?7:10).attr("class",`commit ${e.id} ${s}`),r.append("circle").attr("cx",t.x-3).attr("cy",t.y+2).attr("r",a?2.5:2.75).attr("fill",f?"#000000":"#fff").attr("class",`commit ${e.id} ${s}`),r.append("circle").attr("cx",t.x+3).attr("cy",t.y+2).attr("r",a?2.5:2.75).attr("fill",f?"#000000":"#fff").attr("class",`commit ${e.id} ${s}`),r.append("line").attr("x1",t.x+3).attr("y1",t.y+1).attr("x2",t.x).attr("y2",t.y-5).attr("stroke",f?"#000000":"#fff").attr("class",`commit ${e.id} ${s}`),r.append("line").attr("x1",t.x-3).attr("y1",t.y+1).attr("x2",t.x).attr("y2",t.y-5).attr("stroke",f?"#000000":"#fff").attr("class",`commit ${e.id} ${s}`);else{const g=r.append("circle");if(g.attr("cx",t.x),g.attr("cy",t.y),g.attr("r",a?7:10),g.attr("class",`commit ${e.id} commit${H(o,G,l)}`),i===m.MERGE){const $=r.append("circle");$.attr("cx",t.x),$.attr("cy",t.y),$.attr("r",a?5:6),$.attr("class",`commit ${s} ${e.id} commit${H(o,G,l)}`)}if(i===m.REVERSE){const $=r.append("path"),c=a?4:5;$.attr("d",`M ${t.x-c},${t.y-c}L${t.x+c},${t.y+c}M${t.x-c},${t.y+c}L${t.x+c},${t.y-c}`).attr("class",`commit ${s} ${e.id} commit${H(o,G,l)}`)}}},"drawCommitBullet"),se=h((r,e,t,s,o)=>{if(e.type!==m.CHERRY_PICK&&(e.customId&&e.type===m.MERGE||e.type!==m.MERGE)&&o.showCommitLabel){const i=r.append("g"),n=i.insert("rect").attr("class","commit-label-bkg"),a=i.append("text").attr("x",s).attr("y",t.y+25).attr("class","commit-label").text(e.id),l=a.node()?.getBBox();if(l&&(n.attr("x",t.posWithOffset-l.width/2-I).attr("y",t.y+13.5).attr("width",l.width+2*I).attr("height",l.height+2*I),y==="TB"||y==="BT"?(n.attr("x",t.x-(l.width+4*L+5)).attr("y",t.y-12),a.attr("x",t.x-(l.width+4*L)).attr("y",t.y+l.height-12)):a.attr("x",t.posWithOffset-l.width/2),o.rotateCommitLabel))if(y==="TB"||y==="BT")a.attr("transform","rotate(-45, "+t.x+", "+t.y+")"),n.attr("transform","rotate(-45, "+t.x+", "+t.y+")");else{const f=-7.5-(l.width+10)/25*9.5,g=10+l.width/25*8.5;i.attr("transform","translate("+f+", "+g+") rotate(-45, "+s+", "+t.y+")")}}},"drawCommitLabel"),oe=h((r,e,t,s)=>{if(e.tags.length>0){let o=0,i=0,n=0;const a=[];for(const l of e.tags.reverse()){const f=r.insert("polygon"),g=r.append("circle"),$=r.append("text").attr("y",t.y-16-o).attr("class","tag-label").text(l),c=$.node()?.getBBox();if(!c)throw new Error("Tag bbox not found");i=Math.max(i,c.width),n=Math.max(n,c.height),$.attr("x",t.posWithOffset-c.width/2),a.push({tag:$,hole:g,rect:f,yOffset:o}),o+=20}for(const{tag:l,hole:f,rect:g,yOffset:$}of a){const c=n/2,x=t.y-19.2-$;if(g.attr("class","tag-label-bkg").attr("points",`
2
2
  ${s-i/2-L/2},${x+I}
3
3
  ${s-i/2-L/2},${x-I}
4
4
  ${t.posWithOffset-i/2-L},${x-c-I}