@intent-hq/web 2.341.2 → 2.341.4

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 (142) hide show
  1. package/package.json +1 -1
  2. package/web/app/immutable/chunks/{CL51sD2J.js → 03H0Rain.js} +1 -1
  3. package/web/app/immutable/chunks/{BgrWRL30.js → 2rzjJeJ2.js} +1 -1
  4. package/web/app/immutable/chunks/{C-rIyhbi.js → 63wzgq2y.js} +1 -1
  5. package/web/app/immutable/chunks/{B6qmQARR.js → 6X5anZSR.js} +1 -1
  6. package/web/app/immutable/chunks/{BWkUdpvz.js → 6sAa0Op8.js} +4 -4
  7. package/web/app/immutable/chunks/{alm18JsE.js → 8oeIoGAG.js} +3 -3
  8. package/web/app/immutable/chunks/{DtgKDhuM.js → 9CKhw0O4.js} +1 -1
  9. package/web/app/immutable/chunks/{DrpsA4Ly.js → 9Q1iR9sq.js} +2 -2
  10. package/web/app/immutable/chunks/{5y55aTrU.js → B1JfbHKW.js} +1 -1
  11. package/web/app/immutable/chunks/{DEJKGaFk.js → B1aiVw0D.js} +1 -1
  12. package/web/app/immutable/chunks/{DtZ0s0DW.js → B25g1SEU.js} +1 -1
  13. package/web/app/immutable/chunks/{FODk8jOy.js → B3OpKY8A.js} +1 -1
  14. package/web/app/immutable/chunks/{BB_HEKX3.js → B48zVP7m.js} +1 -1
  15. package/web/app/immutable/chunks/{DACVGRAe.js → B4JblUQ_.js} +2 -2
  16. package/web/app/immutable/chunks/{Cih9Zs2a.js → B7Q4hJJ8.js} +1 -1
  17. package/web/app/immutable/chunks/{kYL_f4ep.js → B9vKot9Y.js} +1 -1
  18. package/web/app/immutable/chunks/{DLBq5-aC.js → BD3qDOqH.js} +1 -1
  19. package/web/app/immutable/chunks/{B5NMwDr1.js → BFGq-_ll.js} +1 -1
  20. package/web/app/immutable/chunks/{eq3yiGc9.js → BFTlNJv7.js} +4 -4
  21. package/web/app/immutable/chunks/{BnlWUiku.js → BKAobQX_.js} +2 -2
  22. package/web/app/immutable/chunks/{BeqvtwUo.js → BKTf-Gsl.js} +1 -1
  23. package/web/app/immutable/chunks/{D7RDU4oX.js → BPlA_F0H.js} +1 -1
  24. package/web/app/immutable/chunks/{niGffMj9.js → BSmS0SHR.js} +1 -1
  25. package/web/app/immutable/chunks/{C2qzWhM3.js → BSw3ndv2.js} +1 -1
  26. package/web/app/immutable/chunks/{D34VXx0H.js → BUnKtOZ7.js} +1 -1
  27. package/web/app/immutable/chunks/{BhaAu9oc.js → BXjVUZ2B.js} +1 -1
  28. package/web/app/immutable/chunks/{jRKGXRXm.js → BYblxwo5.js} +1 -1
  29. package/web/app/immutable/chunks/{B2Km94Qz.js → BYfly9_3.js} +1 -1
  30. package/web/app/immutable/chunks/{Bn7L4PAr.js → BYvg_ZGg.js} +1 -1
  31. package/web/app/immutable/chunks/{DRK9fuuL.js → BZaP4TlW.js} +1 -1
  32. package/web/app/immutable/chunks/{CifnfNKw.js → Ba2fyjC_.js} +1 -1
  33. package/web/app/immutable/chunks/{BZ3ZUgHl.js → Bg4ZIRgI.js} +1 -1
  34. package/web/app/immutable/chunks/{BJwhTMNH.js → BgE6o4ts.js} +1 -1
  35. package/web/app/immutable/chunks/{CIo5jCu0.js → Bh6tU9zC.js} +1 -1
  36. package/web/app/immutable/chunks/{BipW4sR9.js → BnXZPw_-.js} +1 -1
  37. package/web/app/immutable/chunks/{DWYjcnCC.js → BpdOSZ3K.js} +1 -1
  38. package/web/app/immutable/chunks/{9IpLdHiv.js → BpvizIhe.js} +1 -1
  39. package/web/app/immutable/chunks/{jsqrFryE.js → BrvGK9gp.js} +1 -1
  40. package/web/app/immutable/chunks/{DMfRTAkK.js → C-WCUKNv.js} +1 -1
  41. package/web/app/immutable/chunks/{BrtFGrrQ.js → C-mvxH3E.js} +1 -1
  42. package/web/app/immutable/chunks/{CdEZnV89.js → C2Jv33-s.js} +1 -1
  43. package/web/app/immutable/chunks/{Q7iXJPU-.js → C6bGz2wI.js} +1 -1
  44. package/web/app/immutable/chunks/{B03kA1R2.js → C6h_aLcl.js} +1 -1
  45. package/web/app/immutable/chunks/{BwUyq-_g.js → C76ZPk79.js} +1 -1
  46. package/web/app/immutable/chunks/{DiaGgCHr.js → C80hd_K2.js} +1 -1
  47. package/web/app/immutable/chunks/{C6CAte5a.js → CBTFFv-q.js} +1 -1
  48. package/web/app/immutable/chunks/{DhvbLTQy.js → CHD1Bdm7.js} +1 -1
  49. package/web/app/immutable/chunks/{8FNKiReg.js → CIh5DTsk.js} +1 -1
  50. package/web/app/immutable/chunks/{Buh_qAzZ.js → CJ-QJuBK.js} +1 -1
  51. package/web/app/immutable/chunks/{D1jOGOLo.js → CNdZoHmu.js} +1 -1
  52. package/web/app/immutable/chunks/{D8ulYjLF.js → CNqHpwXg.js} +1 -1
  53. package/web/app/immutable/chunks/{BxygHVc0.js → CPVhDNvb.js} +1 -1
  54. package/web/app/immutable/chunks/{BVWcbZYZ.js → CT19p5Qn.js} +1 -1
  55. package/web/app/immutable/chunks/{BcbwK1ES.js → CVVvQr4v.js} +1 -1
  56. package/web/app/immutable/chunks/{CDmGTSwM.js → CVjCdQzl.js} +1 -1
  57. package/web/app/immutable/chunks/{BvAoeVAO.js → CWIpVcE8.js} +1 -1
  58. package/web/app/immutable/chunks/{MDtuP-Z1.js → CbMd5I0J.js} +1 -1
  59. package/web/app/immutable/chunks/{BjtbuSfg.js → CfkA_MJ6.js} +1 -1
  60. package/web/app/immutable/chunks/{BWqChnH3.js → Ch2CU2jj.js} +2 -2
  61. package/web/app/immutable/chunks/{CaEO1WOw.js → Cj-mnOKC.js} +1 -1
  62. package/web/app/immutable/chunks/{BGjYxu3b.js → CjFks5qN.js} +1 -1
  63. package/web/app/immutable/chunks/{DFYnEvjJ.js → CkjDXBNK.js} +1 -1
  64. package/web/app/immutable/chunks/{qReongxq.js → CmWFbIXS.js} +1 -1
  65. package/web/app/immutable/chunks/{CY_U0FqG.js → CnItH7Qd.js} +1 -1
  66. package/web/app/immutable/chunks/{C9kFd-ow.js → Cr4ui72l.js} +2 -2
  67. package/web/app/immutable/chunks/{DLItSYgF.js → Cr6-fUqV.js} +1 -1
  68. package/web/app/immutable/chunks/{C4igGWED.js → CsgGOYLg.js} +1 -1
  69. package/web/app/immutable/chunks/{IZ0jBMf8.js → CuIUKxl_.js} +3 -3
  70. package/web/app/immutable/chunks/{C96eSOju.js → Cvh8IgDm.js} +4 -4
  71. package/web/app/immutable/chunks/{BRlTfYVq.js → CvmQNR5A.js} +1 -1
  72. package/web/app/immutable/chunks/{BkZ_IlDM.js → CxlOdKlx.js} +3 -3
  73. package/web/app/immutable/chunks/{B8mTuhzO.js → D0NH0wJe.js} +1 -1
  74. package/web/app/immutable/chunks/{kLefAR3d.js → D37vxI2K.js} +1 -1
  75. package/web/app/immutable/chunks/{DmfDK5sO.js → D6pin7kj.js} +1 -1
  76. package/web/app/immutable/chunks/{B9R98FZz.js → D71nrcX6.js} +1 -1
  77. package/web/app/immutable/chunks/{CbIjL5rO.js → D7Xt1SkT.js} +1 -1
  78. package/web/app/immutable/chunks/{0wIIYnxr.js → D8jne4Jc.js} +1 -1
  79. package/web/app/immutable/chunks/{j3Ayt40n.js → D9bKP3Hx.js} +1 -1
  80. package/web/app/immutable/chunks/{1-j6WuPc.js → DDAmTTDv.js} +1 -1
  81. package/web/app/immutable/chunks/{H2_zVpjq.js → DDpwkz_y.js} +1 -1
  82. package/web/app/immutable/chunks/{Bi3gb3vy.js → DGYTxb3X.js} +12 -12
  83. package/web/app/immutable/chunks/{B1Fu6T0M.js → DNeS4bH4.js} +2 -2
  84. package/web/app/immutable/chunks/{B_wqGXO8.js → DR517ZLh.js} +1 -1
  85. package/web/app/immutable/chunks/{DUATm_LT.js → DS-AVMuy.js} +1 -1
  86. package/web/app/immutable/chunks/{Cr9jYHoz.js → DaNy32PK.js} +1 -1
  87. package/web/app/immutable/chunks/{DGm9BQVB.js → DbQ0TH44.js} +4 -4
  88. package/web/app/immutable/chunks/{CriDtN0a.js → DbrJb8q7.js} +1 -1
  89. package/web/app/immutable/chunks/{fqryZMo8.js → DciyEdyK.js} +1 -1
  90. package/web/app/immutable/chunks/{D9XMFsak.js → DgZippXc.js} +1 -1
  91. package/web/app/immutable/chunks/{DP2mFyqQ.js → Dhc0zLXE.js} +1 -1
  92. package/web/app/immutable/chunks/{CjMZRWVT.js → DllksLOW.js} +2 -2
  93. package/web/app/immutable/chunks/{CrLZNk77.js → Do2s1-ZW.js} +1 -1
  94. package/web/app/immutable/chunks/{DqP8lgeh.js → DpJ5Wccc.js} +1 -1
  95. package/web/app/immutable/chunks/{A8KQJd5d.js → DxHob-bh.js} +2 -2
  96. package/web/app/immutable/chunks/{Ctqq_Hm-.js → Dz0jv9u2.js} +1 -1
  97. package/web/app/immutable/chunks/{BvZxg4g7.js → IrFjVNUS.js} +1 -1
  98. package/web/app/immutable/chunks/{BY4GwAft.js → JmJV-qA7.js} +1 -1
  99. package/web/app/immutable/chunks/{BfpUcUyv.js → JumZ6iI0.js} +1 -1
  100. package/web/app/immutable/chunks/{CkgZ-o6m.js → JvJIKXgZ.js} +3 -3
  101. package/web/app/immutable/chunks/{B-t0Hiim.js → PjzNbVbY.js} +1 -1
  102. package/web/app/immutable/chunks/{DzHDJT7q.js → Qgve2nLc.js} +1 -1
  103. package/web/app/immutable/chunks/{BOp-xgUY.js → RLDKXce3.js} +1 -1
  104. package/web/app/immutable/chunks/{Bjxr6-oA.js → Rx3qJQkm.js} +1 -1
  105. package/web/app/immutable/chunks/{B5sVEway.js → S-y_pRxX.js} +3 -3
  106. package/web/app/immutable/chunks/{0WuPrU1r.js → SP14gC8P.js} +1 -1
  107. package/web/app/immutable/chunks/{BVo9Fayv.js → Sk5RmV-P.js} +1 -1
  108. package/web/app/immutable/chunks/{CTd6owPM.js → X51JKYQ1.js} +1 -1
  109. package/web/app/immutable/chunks/{CL6Jm56o.js → _ZyJx2QH.js} +1 -1
  110. package/web/app/immutable/chunks/{D70Wuc8a.js → bgYBbNkU.js} +1 -1
  111. package/web/app/immutable/chunks/{D-wkRpKs.js → eNDBh2Xw.js} +1 -1
  112. package/web/app/immutable/chunks/{DSDDKy6s.js → fejC11c0.js} +1 -1
  113. package/web/app/immutable/chunks/{Iv7jZvFC.js → hiKOhYfu.js} +1 -1
  114. package/web/app/immutable/chunks/{C56SKTiE.js → hpoN7Rk0.js} +2 -2
  115. package/web/app/immutable/chunks/{Ds-0wg5K.js → iQQWMpAQ.js} +1 -1
  116. package/web/app/immutable/chunks/{Bf0Zh6Mw.js → jBI7gIvH.js} +1 -1
  117. package/web/app/immutable/chunks/{DAvxjdg4.js → nGCgKKFL.js} +1 -1
  118. package/web/app/immutable/chunks/{urUnkHMR.js → o2F0F4IJ.js} +1 -1
  119. package/web/app/immutable/chunks/{BIPVAS3s.js → osdRNRcE.js} +1 -1
  120. package/web/app/immutable/chunks/{BgS9mR9A.js → sxefbKie.js} +1 -1
  121. package/web/app/immutable/chunks/{DLAO6H8J.js → tc7ktccF.js} +1 -1
  122. package/web/app/immutable/chunks/{Cln842Nh.js → xf7slqST.js} +1 -1
  123. package/web/app/immutable/chunks/{Dul4sOUW.js → yEA-_XFs.js} +1 -1
  124. package/web/app/immutable/chunks/{Dw2h3dcZ.js → yfYdt-hl.js} +1 -1
  125. package/web/app/immutable/entry/{app.soTIQVal.js → app.YWMiN_f6.js} +2 -2
  126. package/web/app/immutable/entry/start.D0ehuxeh.js +1 -0
  127. package/web/app/immutable/nodes/{0.r0ulDrwu.js → 0.DX1WooqV.js} +1 -1
  128. package/web/app/immutable/nodes/{1.A8v1n0qj.js → 1.DDJBAwnQ.js} +1 -1
  129. package/web/app/immutable/nodes/{10.yOzUfegC.js → 10.DOWDpKqR.js} +1 -1
  130. package/web/app/immutable/nodes/{14.3B0XUkw_.js → 14.Bl2G62xL.js} +1 -1
  131. package/web/app/immutable/nodes/{17.DxRLAlw9.js → 17.Dk70Srbz.js} +2 -2
  132. package/web/app/immutable/nodes/{2.Be1Ga7Wd.js → 2.CCtsAAdD.js} +4 -4
  133. package/web/app/immutable/nodes/{3.C16OjbRR.js → 3.q5Utpq42.js} +1 -1
  134. package/web/app/immutable/nodes/{4.DBcE2UNc.js → 4.C4vEG10b.js} +1 -1
  135. package/web/app/immutable/nodes/{5.CJRPdyCh.js → 5.Bwi1S2uy.js} +1 -1
  136. package/web/app/immutable/nodes/{6.BSMzZH-3.js → 6.Cbzw4k4E.js} +1 -1
  137. package/web/app/immutable/nodes/{7.AlZl2_PU.js → 7.ChPE7n_q.js} +1 -1
  138. package/web/app/immutable/nodes/{8.WS_XHrBt.js → 8.Dh22eEQw.js} +4 -4
  139. package/web/app/immutable/nodes/{9.B3dVA_xP.js → 9.CXLjTth1.js} +4 -4
  140. package/web/app/version.json +1 -1
  141. package/web/index.html +9 -9
  142. package/web/app/immutable/entry/start.BP3fu5vG.js +0 -1
@@ -1,4 +1,4 @@
1
- import{g as k1}from"./DFYnEvjJ.js";import{g as E1}from"./CbIjL5rO.js";import{s as C1}from"./D7RDU4oX.js";import{b as k,a$ as t1,ay as oe,X as Ce,a1 as S1,aP as x1,bh as Gt,a_ as T1,aZ as D1,b0 as _1,V as v1,U as F1,Y as V1,z as I1,ax as s1,J as i1,as as L1,$ as Rt,aW as Ot,r as B1,N as M1,am as y1,aU as w1,ab as N1,x as R1,aT as O1,p as P1}from"./eq3yiGc9.js";import{c as G1}from"./Dw2h3dcZ.js";import{aP as U1}from"./DmfDK5sO.js";var tt={SHAPE_UNSUPPORTED:"SHAPE_UNSUPPORTED",SHAPE_REMOVED:"SHAPE_REMOVED",EDGE_OPERATOR_UNSUPPORTED:"EDGE_OPERATOR_UNSUPPORTED",REFERENCE_EDGE_LABEL_REJECTED:"REFERENCE_EDGE_LABEL_REJECTED",CONNECTOR_REF_UNRESOLVED:"CONNECTOR_REF_UNRESOLVED",CONNECTOR_REF_NOT_A_CONNECTOR:"CONNECTOR_REF_NOT_A_CONNECTOR",METADATA_KEY_MISAPPLIED:"METADATA_KEY_MISAPPLIED",DUPLICATE_ID_NODE:"DUPLICATE_ID_NODE",RESERVED_SYNTHETIC_ID:"RESERVED_SYNTHETIC_ID",CONTAINMENT_VIOLATION:"CONTAINMENT_VIOLATION",EDGE_SEMANTIC_CONTRADICTION:"EDGE_SEMANTIC_CONTRADICTION",FLOW_NO_INPUT:"FLOW_NO_INPUT"},j1=new Set([tt.SHAPE_UNSUPPORTED,tt.SHAPE_REMOVED,tt.CONTAINMENT_VIOLATION]);new Set(Object.values(tt).filter(s=>!j1.has(s)));var z1=new Map([["task","roundedRect"],["tool","subroutine"],["input","lean-right"],["lean_right","lean-right"],["decision","diamond"],["refdoc","lin-doc"],["action","hexagon"],["round","rect"]]),W1=new Set(["doc","stadium","terminal","circle","trapezoid","inv_trapezoid","inv-trapezoid","doublecircle","double-circle","typeDeclaration","procs","lean_left","lean-left","in-out","cylinder","ellipse","odd","tag-rect","tagged-rectangle","delay","half-rounded-rectangle","lin-rect","lined-rectangle","win-pane","window-pane","curv-trap","curved-trapezoid"]),K1=new Set(["roundedRect","subroutine","subprocess","subproc","framed-rectangle","lean-right","diamond","lin-doc","lined-document","hexagon","hex","connector","collapsedGroup"]),$e="roundedRect";function et(s){return s&&(z1.get(s)??s)}k(et,"resolveShapeAlias");function r1(s,i){for(const n of s)if(!n.isGroup){if((!n.shape||n.shape==="squareRect"||n.shape==="rect")&&(n.shape=$e),W1.has(n.shape)){const r=`shape "${n.shape}" was removed in v0.8.1, using "${$e}"`;i?.emitError?i.emitError("SHAPE_REMOVED",r,{nodeId:n.id}):oe.warn(`agentflow: ${r}`),n.shape=$e;continue}if(!K1.has(n.shape)){const r=`shape "${n.shape}" is not supported, using "${$e}"`;i?.emitWarning?i.emitWarning("SHAPE_UNSUPPORTED",r,{nodeId:n.id}):oe.warn(`agentflow: ${r}`),n.shape=$e}}}k(r1,"normaliseNodeShapes");var Lt=new Map([["tool",0],["task",1],["decision",2],["input",3],["refdoc",4],["connector",5],["action",6]]),a1=Lt.size,o1=k(s=>`af-kind-${s}`,"kindClass"),H1=[...Lt.keys()],u1=k(s=>Math.max(1,s-a1),"containerSlotCount"),l1=k((s,i)=>{const n=a1+s%u1(i);return i>0?n%i:n},"containerSlot");function c1(s,i,n){const r=Ce().themeVariables?.borderColorArray,u=Array.isArray(r)?r.length:0;let l=n.size;for(const c of s??[]){if(c.isGroup||c.shape==="collapsedGroup"){const h=n.get(String(c.id))??l++;c.colorIndex=l1(h,u);continue}const a=i(String(c.id));a&&Lt.has(a)&&(c.cssClasses=`${c.cssClasses??""} ${o1(a)}`.replace(/\s+/g," ").trim())}}k(c1,"assignColorSlots");var n1="agentflow-",Pt=new Set(["shape","view","icon","img","form","pos","w","h","class","style","labelType"]),Y1=new Set(["subroutine","subprocess","subproc","framed-rectangle","tool"]),q1={flow:"flowGroup"};function It(s){if(Array.isArray(s))return s.map(n=>It(n));if(s===null||typeof s!="object")return s;const i={};for(const n of Object.keys(s))n==="__proto__"||n==="constructor"||n==="prototype"||(i[n]=It(s[n]));return i}k(It,"stripPrototypeKeys");function d1(s){let i=!1,n=!1,r=0,u;const l=[];for(const c of s.split(`
1
+ import{g as k1}from"./CkjDXBNK.js";import{g as E1}from"./D7Xt1SkT.js";import{s as C1}from"./BPlA_F0H.js";import{b as k,a$ as t1,ay as oe,X as Ce,a1 as S1,aP as x1,bh as Gt,a_ as T1,aZ as D1,b0 as _1,V as v1,U as F1,Y as V1,z as I1,ax as s1,J as i1,as as L1,$ as Rt,aW as Ot,r as B1,N as M1,am as y1,aU as w1,ab as N1,x as R1,aT as O1,p as P1}from"./BFTlNJv7.js";import{c as G1}from"./yfYdt-hl.js";import{aP as U1}from"./D6pin7kj.js";var tt={SHAPE_UNSUPPORTED:"SHAPE_UNSUPPORTED",SHAPE_REMOVED:"SHAPE_REMOVED",EDGE_OPERATOR_UNSUPPORTED:"EDGE_OPERATOR_UNSUPPORTED",REFERENCE_EDGE_LABEL_REJECTED:"REFERENCE_EDGE_LABEL_REJECTED",CONNECTOR_REF_UNRESOLVED:"CONNECTOR_REF_UNRESOLVED",CONNECTOR_REF_NOT_A_CONNECTOR:"CONNECTOR_REF_NOT_A_CONNECTOR",METADATA_KEY_MISAPPLIED:"METADATA_KEY_MISAPPLIED",DUPLICATE_ID_NODE:"DUPLICATE_ID_NODE",RESERVED_SYNTHETIC_ID:"RESERVED_SYNTHETIC_ID",CONTAINMENT_VIOLATION:"CONTAINMENT_VIOLATION",EDGE_SEMANTIC_CONTRADICTION:"EDGE_SEMANTIC_CONTRADICTION",FLOW_NO_INPUT:"FLOW_NO_INPUT"},j1=new Set([tt.SHAPE_UNSUPPORTED,tt.SHAPE_REMOVED,tt.CONTAINMENT_VIOLATION]);new Set(Object.values(tt).filter(s=>!j1.has(s)));var z1=new Map([["task","roundedRect"],["tool","subroutine"],["input","lean-right"],["lean_right","lean-right"],["decision","diamond"],["refdoc","lin-doc"],["action","hexagon"],["round","rect"]]),W1=new Set(["doc","stadium","terminal","circle","trapezoid","inv_trapezoid","inv-trapezoid","doublecircle","double-circle","typeDeclaration","procs","lean_left","lean-left","in-out","cylinder","ellipse","odd","tag-rect","tagged-rectangle","delay","half-rounded-rectangle","lin-rect","lined-rectangle","win-pane","window-pane","curv-trap","curved-trapezoid"]),K1=new Set(["roundedRect","subroutine","subprocess","subproc","framed-rectangle","lean-right","diamond","lin-doc","lined-document","hexagon","hex","connector","collapsedGroup"]),$e="roundedRect";function et(s){return s&&(z1.get(s)??s)}k(et,"resolveShapeAlias");function r1(s,i){for(const n of s)if(!n.isGroup){if((!n.shape||n.shape==="squareRect"||n.shape==="rect")&&(n.shape=$e),W1.has(n.shape)){const r=`shape "${n.shape}" was removed in v0.8.1, using "${$e}"`;i?.emitError?i.emitError("SHAPE_REMOVED",r,{nodeId:n.id}):oe.warn(`agentflow: ${r}`),n.shape=$e;continue}if(!K1.has(n.shape)){const r=`shape "${n.shape}" is not supported, using "${$e}"`;i?.emitWarning?i.emitWarning("SHAPE_UNSUPPORTED",r,{nodeId:n.id}):oe.warn(`agentflow: ${r}`),n.shape=$e}}}k(r1,"normaliseNodeShapes");var Lt=new Map([["tool",0],["task",1],["decision",2],["input",3],["refdoc",4],["connector",5],["action",6]]),a1=Lt.size,o1=k(s=>`af-kind-${s}`,"kindClass"),H1=[...Lt.keys()],u1=k(s=>Math.max(1,s-a1),"containerSlotCount"),l1=k((s,i)=>{const n=a1+s%u1(i);return i>0?n%i:n},"containerSlot");function c1(s,i,n){const r=Ce().themeVariables?.borderColorArray,u=Array.isArray(r)?r.length:0;let l=n.size;for(const c of s??[]){if(c.isGroup||c.shape==="collapsedGroup"){const h=n.get(String(c.id))??l++;c.colorIndex=l1(h,u);continue}const a=i(String(c.id));a&&Lt.has(a)&&(c.cssClasses=`${c.cssClasses??""} ${o1(a)}`.replace(/\s+/g," ").trim())}}k(c1,"assignColorSlots");var n1="agentflow-",Pt=new Set(["shape","view","icon","img","form","pos","w","h","class","style","labelType"]),Y1=new Set(["subroutine","subprocess","subproc","framed-rectangle","tool"]),q1={flow:"flowGroup"};function It(s){if(Array.isArray(s))return s.map(n=>It(n));if(s===null||typeof s!="object")return s;const i={};for(const n of Object.keys(s))n==="__proto__"||n==="constructor"||n==="prototype"||(i[n]=It(s[n]));return i}k(It,"stripPrototypeKeys");function d1(s){let i=!1,n=!1,r=0,u;const l=[];for(const c of s.split(`
2
2
  `)){if(u!==void 0){const p=c.length-c.trimStart().length;if(c.trim()===""||p>u){l.push(c);continue}u=void 0}let a=-1;for(let p=0;p<c.length;p++){const A=c[p];if(n)A==="\\"?p++:A==='"'&&(n=!1);else if(i)A==="'"&&(i=!1);else if(A==='"')n=!0;else if(A==="'")i=!0;else if(A==="#"&&(p===0||c[p-1]===" "||c[p-1]===" ")){a=p;break}else A==="["||A==="{"?r++:(A==="]"||A==="}")&&(r=Math.max(0,r-1))}if(i||n||r>0){l.push(c);continue}const h=a>=0?c.slice(0,a):c,g=a>=0?c.slice(a):"";if(/:\s*[>|][\d+-]*\s*$/.test(h)){u=c.length-c.trimStart().length,l.push(c);continue}l.push(h.replace(/,([\t ]*)$/,"$1")+g)}return l.join(`
3
3
  `)}k(d1,"stripLineTrailingCommas");var Ze,X1=(Ze=class{constructor(){this.vertexCounter=0,this.config=Ce(),this.vertices=new Map,this.edges=[],this.classes=new Map,this.subGraphs=[],this.subGraphLookup=new Map,this.globalNodes=new Set,this.connectors=new Map,this.tooltips=new Map,this.subCount=0,this.firstGraphFlag=!0,this.secCount=-1,this.posCrossRef=[],this.diagramId="",this.preserveCommentsWhenParsing=!0,this.frontmatterLineOffset=0,this.elementMappings=[],this.bareVertexMappings=new WeakSet,this.diagnostics=[],this.postParseValidationRun=!1,this.funs=[],this.setAccTitle=T1,this.setAccDescription=D1,this.setDiagramTitle=_1,this.getAccTitle=v1,this.getAccDescription=F1,this.getDiagramTitle=V1,this.funs.push(this.setupToolTips.bind(this)),this.addVertex=this.addVertex.bind(this),this.firstGraph=this.firstGraph.bind(this),this.setDirection=this.setDirection.bind(this),this.addSubGraph=this.addSubGraph.bind(this),this.addGlobal=this.addGlobal.bind(this),this.addConnector=this.addConnector.bind(this),this.addConnectorMapping=this.addConnectorMapping.bind(this),this.addLink=this.addLink.bind(this),this.setLink=this.setLink.bind(this),this.updateLink=this.updateLink.bind(this),this.addClass=this.addClass.bind(this),this.setClass=this.setClass.bind(this),this.destructLink=this.destructLink.bind(this),this.setClickEvent=this.setClickEvent.bind(this),this.setTooltip=this.setTooltip.bind(this),this.updateLinkInterpolate=this.updateLinkInterpolate.bind(this),this.setClickFun=this.setClickFun.bind(this),this.bindFunctions=this.bindFunctions.bind(this),this.setFrontmatterLineOffset=this.setFrontmatterLineOffset.bind(this),this.addVertexMapping=this.addVertexMapping.bind(this),this.extendVertexMapping=this.extendVertexMapping.bind(this),this.addEdgeMapping=this.addEdgeMapping.bind(this),this.addSubgraphMapping=this.addSubgraphMapping.bind(this),this.emitWarning=this.emitWarning.bind(this),this.emitError=this.emitError.bind(this),this.getDiagnostics=this.getDiagnostics.bind(this),this.lex={firstGraph:this.firstGraph.bind(this)},this.clear(),this.setGen("gen-2")}sanitizeText(i){return I1.sanitizeText(i,this.config)}sanitizeNodeLabelType(i){switch(i){case"markdown":case"string":case"text":return i;default:return"markdown"}}setDiagramId(i){this.diagramId=i}lookUpDomId(i){for(const n of this.vertices.values())if(n.id===i)return this.diagramId?`${this.diagramId}-${n.domId}`:n.domId;return this.diagramId?`${this.diagramId}-${i}`:i}addVertex(i,n,r,u,l,c,a={},h,g){if(!i||i.trim().length===0)return;let p;if(h!==void 0){let m;h.includes(`
4
4
  `)?m=h+`
@@ -1,4 +1,4 @@
1
- import{g as fe}from"./DFYnEvjJ.js";import{b as o,ay as te,X as U,aX as ye,ad as be,ah as me,aL as ke,b3 as Ee,O as K,aV as F,ax as _e,J as Se,an as Ne,au as ce,H as le}from"./eq3yiGc9.js";var $=(function(){var e=o(function(O,s,n,r){for(n=n||{},r=O.length;r--;n[O[r]]=s);return n},"o"),h=[1,4],p=[1,13],i=[1,12],d=[1,15],k=[1,16],m=[1,20],l=[1,19],D=[6,7,8],I=[1,26],g=[1,24],w=[1,25],E=[6,7,11],G=[1,31],N=[6,7,11,24],V=[1,6,13,16,17,20,23],f=[1,35],A=[1,36],L=[1,6,7,11,13,16,17,20,23],H=[1,38],T={trace:o(function(){},"trace"),yy:{},symbols_:{error:2,start:3,mindMap:4,spaceLines:5,SPACELINE:6,NL:7,KANBAN:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,node:14,shapeData:15,ICON:16,CLASS:17,nodeWithId:18,nodeWithoutId:19,NODE_DSTART:20,NODE_DESCR:21,NODE_DEND:22,NODE_ID:23,SHAPE_DATA:24,$accept:0,$end:1},terminals_:{2:"error",6:"SPACELINE",7:"NL",8:"KANBAN",11:"EOF",13:"SPACELIST",16:"ICON",17:"CLASS",20:"NODE_DSTART",21:"NODE_DESCR",22:"NODE_DEND",23:"NODE_ID",24:"SHAPE_DATA"},productions_:[0,[3,1],[3,2],[5,1],[5,2],[5,2],[4,2],[4,3],[10,1],[10,1],[10,1],[10,2],[10,2],[9,3],[9,2],[12,3],[12,2],[12,2],[12,2],[12,1],[12,2],[12,1],[12,1],[12,1],[12,1],[14,1],[14,1],[19,3],[18,1],[18,4],[15,2],[15,1]],performAction:o(function(s,n,r,a,u,t,M){var c=t.length-1;switch(u){case 6:case 7:return a;case 8:a.getLogger().trace("Stop NL ");break;case 9:a.getLogger().trace("Stop EOF ");break;case 11:a.getLogger().trace("Stop NL2 ");break;case 12:a.getLogger().trace("Stop EOF2 ");break;case 15:a.getLogger().info("Node: ",t[c-1].id),a.addNode(t[c-2].length,t[c-1].id,t[c-1].descr,t[c-1].type,t[c]);break;case 16:a.getLogger().info("Node: ",t[c].id),a.addNode(t[c-1].length,t[c].id,t[c].descr,t[c].type);break;case 17:a.getLogger().trace("Icon: ",t[c]),a.decorateNode({icon:t[c]});break;case 18:case 23:a.decorateNode({class:t[c]});break;case 19:a.getLogger().trace("SPACELIST");break;case 20:a.getLogger().trace("Node: ",t[c-1].id),a.addNode(0,t[c-1].id,t[c-1].descr,t[c-1].type,t[c]);break;case 21:a.getLogger().trace("Node: ",t[c].id),a.addNode(0,t[c].id,t[c].descr,t[c].type);break;case 22:a.decorateNode({icon:t[c]});break;case 27:a.getLogger().trace("node found ..",t[c-2]),this.$={id:t[c-1],descr:t[c-1],type:a.getType(t[c-2],t[c])};break;case 28:this.$={id:t[c],descr:t[c],type:0};break;case 29:a.getLogger().trace("node found ..",t[c-3]),this.$={id:t[c-3],descr:t[c-1],type:a.getType(t[c-2],t[c])};break;case 30:this.$=t[c-1]+t[c];break;case 31:this.$=t[c];break}},"anonymous"),table:[{3:1,4:2,5:3,6:[1,5],8:h},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:h},{6:p,7:[1,10],9:9,12:11,13:i,14:14,16:d,17:k,18:17,19:18,20:m,23:l},e(D,[2,3]),{1:[2,2]},e(D,[2,4]),e(D,[2,5]),{1:[2,6],6:p,12:21,13:i,14:14,16:d,17:k,18:17,19:18,20:m,23:l},{6:p,9:22,12:11,13:i,14:14,16:d,17:k,18:17,19:18,20:m,23:l},{6:I,7:g,10:23,11:w},e(E,[2,24],{18:17,19:18,14:27,16:[1,28],17:[1,29],20:m,23:l}),e(E,[2,19]),e(E,[2,21],{15:30,24:G}),e(E,[2,22]),e(E,[2,23]),e(N,[2,25]),e(N,[2,26]),e(N,[2,28],{20:[1,32]}),{21:[1,33]},{6:I,7:g,10:34,11:w},{1:[2,7],6:p,12:21,13:i,14:14,16:d,17:k,18:17,19:18,20:m,23:l},e(V,[2,14],{7:f,11:A}),e(L,[2,8]),e(L,[2,9]),e(L,[2,10]),e(E,[2,16],{15:37,24:G}),e(E,[2,17]),e(E,[2,18]),e(E,[2,20],{24:H}),e(N,[2,31]),{21:[1,39]},{22:[1,40]},e(V,[2,13],{7:f,11:A}),e(L,[2,11]),e(L,[2,12]),e(E,[2,15],{24:H}),e(N,[2,30]),{22:[1,41]},e(N,[2,27]),e(N,[2,29])],defaultActions:{2:[2,1],6:[2,2]},parseError:o(function(s,n){if(n.recoverable)this.trace(s);else{var r=new Error(s);throw r.hash=n,r}},"parseError"),parse:o(function(s){var n=this,r=[0],a=[],u=[null],t=[],M=this.table,c="",W=0,ie=0,ue=2,re=1,ge=t.slice.call(arguments,1),b=Object.create(this.lexer),R={yy:{}};for(var J in this.yy)Object.prototype.hasOwnProperty.call(this.yy,J)&&(R.yy[J]=this.yy[J]);b.setInput(s,R.yy),R.yy.lexer=b,R.yy.parser=this,typeof b.yylloc>"u"&&(b.yylloc={});var q=b.yylloc;t.push(q);var de=b.options&&b.options.ranges;typeof R.yy.parseError=="function"?this.parseError=R.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function pe(S){r.length=r.length-2*S,u.length=u.length-S,t.length=t.length-S}o(pe,"popStack");function ae(){var S;return S=a.pop()||b.lex()||re,typeof S!="number"&&(S instanceof Array&&(a=S,S=a.pop()),S=n.symbols_[S]||S),S}o(ae,"lex");for(var _,P,x,Q,j={},z,C,oe,X;;){if(P=r[r.length-1],this.defaultActions[P]?x=this.defaultActions[P]:((_===null||typeof _>"u")&&(_=ae()),x=M[P]&&M[P][_]),typeof x>"u"||!x.length||!x[0]){var Z="";X=[];for(z in M[P])this.terminals_[z]&&z>ue&&X.push("'"+this.terminals_[z]+"'");b.showPosition?Z="Parse error on line "+(W+1)+`:
1
+ import{g as fe}from"./CkjDXBNK.js";import{b as o,ay as te,X as U,aX as ye,ad as be,ah as me,aL as ke,b3 as Ee,O as K,aV as F,ax as _e,J as Se,an as Ne,au as ce,H as le}from"./BFTlNJv7.js";var $=(function(){var e=o(function(O,s,n,r){for(n=n||{},r=O.length;r--;n[O[r]]=s);return n},"o"),h=[1,4],p=[1,13],i=[1,12],d=[1,15],k=[1,16],m=[1,20],l=[1,19],D=[6,7,8],I=[1,26],g=[1,24],w=[1,25],E=[6,7,11],G=[1,31],N=[6,7,11,24],V=[1,6,13,16,17,20,23],f=[1,35],A=[1,36],L=[1,6,7,11,13,16,17,20,23],H=[1,38],T={trace:o(function(){},"trace"),yy:{},symbols_:{error:2,start:3,mindMap:4,spaceLines:5,SPACELINE:6,NL:7,KANBAN:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,node:14,shapeData:15,ICON:16,CLASS:17,nodeWithId:18,nodeWithoutId:19,NODE_DSTART:20,NODE_DESCR:21,NODE_DEND:22,NODE_ID:23,SHAPE_DATA:24,$accept:0,$end:1},terminals_:{2:"error",6:"SPACELINE",7:"NL",8:"KANBAN",11:"EOF",13:"SPACELIST",16:"ICON",17:"CLASS",20:"NODE_DSTART",21:"NODE_DESCR",22:"NODE_DEND",23:"NODE_ID",24:"SHAPE_DATA"},productions_:[0,[3,1],[3,2],[5,1],[5,2],[5,2],[4,2],[4,3],[10,1],[10,1],[10,1],[10,2],[10,2],[9,3],[9,2],[12,3],[12,2],[12,2],[12,2],[12,1],[12,2],[12,1],[12,1],[12,1],[12,1],[14,1],[14,1],[19,3],[18,1],[18,4],[15,2],[15,1]],performAction:o(function(s,n,r,a,u,t,M){var c=t.length-1;switch(u){case 6:case 7:return a;case 8:a.getLogger().trace("Stop NL ");break;case 9:a.getLogger().trace("Stop EOF ");break;case 11:a.getLogger().trace("Stop NL2 ");break;case 12:a.getLogger().trace("Stop EOF2 ");break;case 15:a.getLogger().info("Node: ",t[c-1].id),a.addNode(t[c-2].length,t[c-1].id,t[c-1].descr,t[c-1].type,t[c]);break;case 16:a.getLogger().info("Node: ",t[c].id),a.addNode(t[c-1].length,t[c].id,t[c].descr,t[c].type);break;case 17:a.getLogger().trace("Icon: ",t[c]),a.decorateNode({icon:t[c]});break;case 18:case 23:a.decorateNode({class:t[c]});break;case 19:a.getLogger().trace("SPACELIST");break;case 20:a.getLogger().trace("Node: ",t[c-1].id),a.addNode(0,t[c-1].id,t[c-1].descr,t[c-1].type,t[c]);break;case 21:a.getLogger().trace("Node: ",t[c].id),a.addNode(0,t[c].id,t[c].descr,t[c].type);break;case 22:a.decorateNode({icon:t[c]});break;case 27:a.getLogger().trace("node found ..",t[c-2]),this.$={id:t[c-1],descr:t[c-1],type:a.getType(t[c-2],t[c])};break;case 28:this.$={id:t[c],descr:t[c],type:0};break;case 29:a.getLogger().trace("node found ..",t[c-3]),this.$={id:t[c-3],descr:t[c-1],type:a.getType(t[c-2],t[c])};break;case 30:this.$=t[c-1]+t[c];break;case 31:this.$=t[c];break}},"anonymous"),table:[{3:1,4:2,5:3,6:[1,5],8:h},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:h},{6:p,7:[1,10],9:9,12:11,13:i,14:14,16:d,17:k,18:17,19:18,20:m,23:l},e(D,[2,3]),{1:[2,2]},e(D,[2,4]),e(D,[2,5]),{1:[2,6],6:p,12:21,13:i,14:14,16:d,17:k,18:17,19:18,20:m,23:l},{6:p,9:22,12:11,13:i,14:14,16:d,17:k,18:17,19:18,20:m,23:l},{6:I,7:g,10:23,11:w},e(E,[2,24],{18:17,19:18,14:27,16:[1,28],17:[1,29],20:m,23:l}),e(E,[2,19]),e(E,[2,21],{15:30,24:G}),e(E,[2,22]),e(E,[2,23]),e(N,[2,25]),e(N,[2,26]),e(N,[2,28],{20:[1,32]}),{21:[1,33]},{6:I,7:g,10:34,11:w},{1:[2,7],6:p,12:21,13:i,14:14,16:d,17:k,18:17,19:18,20:m,23:l},e(V,[2,14],{7:f,11:A}),e(L,[2,8]),e(L,[2,9]),e(L,[2,10]),e(E,[2,16],{15:37,24:G}),e(E,[2,17]),e(E,[2,18]),e(E,[2,20],{24:H}),e(N,[2,31]),{21:[1,39]},{22:[1,40]},e(V,[2,13],{7:f,11:A}),e(L,[2,11]),e(L,[2,12]),e(E,[2,15],{24:H}),e(N,[2,30]),{22:[1,41]},e(N,[2,27]),e(N,[2,29])],defaultActions:{2:[2,1],6:[2,2]},parseError:o(function(s,n){if(n.recoverable)this.trace(s);else{var r=new Error(s);throw r.hash=n,r}},"parseError"),parse:o(function(s){var n=this,r=[0],a=[],u=[null],t=[],M=this.table,c="",W=0,ie=0,ue=2,re=1,ge=t.slice.call(arguments,1),b=Object.create(this.lexer),R={yy:{}};for(var J in this.yy)Object.prototype.hasOwnProperty.call(this.yy,J)&&(R.yy[J]=this.yy[J]);b.setInput(s,R.yy),R.yy.lexer=b,R.yy.parser=this,typeof b.yylloc>"u"&&(b.yylloc={});var q=b.yylloc;t.push(q);var de=b.options&&b.options.ranges;typeof R.yy.parseError=="function"?this.parseError=R.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function pe(S){r.length=r.length-2*S,u.length=u.length-S,t.length=t.length-S}o(pe,"popStack");function ae(){var S;return S=a.pop()||b.lex()||re,typeof S!="number"&&(S instanceof Array&&(a=S,S=a.pop()),S=n.symbols_[S]||S),S}o(ae,"lex");for(var _,P,x,Q,j={},z,C,oe,X;;){if(P=r[r.length-1],this.defaultActions[P]?x=this.defaultActions[P]:((_===null||typeof _>"u")&&(_=ae()),x=M[P]&&M[P][_]),typeof x>"u"||!x.length||!x[0]){var Z="";X=[];for(z in M[P])this.terminals_[z]&&z>ue&&X.push("'"+this.terminals_[z]+"'");b.showPosition?Z="Parse error on line "+(W+1)+`:
2
2
  `+b.showPosition()+`
3
3
  Expecting `+X.join(", ")+", got '"+(this.terminals_[_]||_)+"'":Z="Parse error on line "+(W+1)+": Unexpected "+(_==re?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(Z,{text:b.match,token:this.terminals_[_]||_,line:b.yylineno,loc:q,expected:X})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+P+", token: "+_);switch(x[0]){case 1:r.push(_),u.push(b.yytext),t.push(b.yylloc),r.push(x[1]),_=null,ie=b.yyleng,c=b.yytext,W=b.yylineno,q=b.yylloc;break;case 2:if(C=this.productions_[x[1]][1],j.$=u[u.length-C],j._$={first_line:t[t.length-(C||1)].first_line,last_line:t[t.length-1].last_line,first_column:t[t.length-(C||1)].first_column,last_column:t[t.length-1].last_column},de&&(j._$.range=[t[t.length-(C||1)].range[0],t[t.length-1].range[1]]),Q=this.performAction.apply(j,[c,ie,W,R.yy,x[1],u,t].concat(ge)),typeof Q<"u")return Q;C&&(r=r.slice(0,-1*C*2),u=u.slice(0,-1*C),t=t.slice(0,-1*C)),r.push(this.productions_[x[1]][0]),u.push(j.$),t.push(j._$),oe=M[r[r.length-2]][r[r.length-1]],r.push(oe);break;case 3:return!0}}return!0},"parse")},Y=(function(){var O={EOF:1,parseError:o(function(n,r){if(this.yy.parser)this.yy.parser.parseError(n,r);else throw new Error(n)},"parseError"),setInput:o(function(s,n){return this.yy=n||this.yy||{},this._input=s,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:o(function(){var s=this._input[0];this.yytext+=s,this.yyleng++,this.offset++,this.match+=s,this.matched+=s;var n=s.match(/(?:\r\n?|\n).*/g);return n?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),s},"input"),unput:o(function(s){var n=s.length,r=s.split(/(?:\r\n?|\n)/g);this._input=s+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-n),this.offset-=n;var a=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),r.length-1&&(this.yylineno-=r.length-1);var u=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:r?(r.length===a.length?this.yylloc.first_column:0)+a[a.length-r.length].length-r[0].length:this.yylloc.first_column-n},this.options.ranges&&(this.yylloc.range=[u[0],u[0]+this.yyleng-n]),this.yyleng=this.yytext.length,this},"unput"),more:o(function(){return this._more=!0,this},"more"),reject:o(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
4
4
  `+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:o(function(s){this.unput(this.match.slice(s))},"less"),pastInput:o(function(){var s=this.matched.substr(0,this.matched.length-this.match.length);return(s.length>20?"...":"")+s.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:o(function(){var s=this.match;return s.length<20&&(s+=this._input.substr(0,20-s.length)),(s.substr(0,20)+(s.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:o(function(){var s=this.pastInput(),n=new Array(s.length+1).join("-");return s+this.upcomingInput()+`
@@ -1 +1 @@
1
- import{g as p,r as u,d as n}from"./DqP8lgeh.js";import{p as f}from"./B2Km94Qz.js";import{b as a,ay as o}from"./eq3yiGc9.js";import{M as c,c as d}from"./ltO9jYXn.js";var v=d().RailroadAbnf.parser.LangiumParser,i=a(e=>{const r=e.alternatives.map(g);return r.length===1?r[0]:{type:"choice",alternatives:r}},"transformAlternation"),g=a(e=>{const r=e.elements.map(y);return r.length===1?r[0]:{type:"sequence",elements:r}},"transformConcatenation"),b=a(e=>{if(e.includes("*")){const[t,s]=e.split("*"),l=t?parseInt(t,10):0,m=s?parseInt(s,10):1/0;return{min:l,max:m}}const r=parseInt(e,10);return{min:r,max:r}},"parseRepeat"),y=a(e=>{const r=A(e.primary);if(!e.repeat)return r;const{min:t,max:s}=b(e.repeat);return t===0&&s===1?{type:"optional",element:r}:{type:"repetition",element:r,min:t,max:s}},"transformElement"),A=a(e=>{switch(e.$type){case"AbnfStringLiteral":return{type:"terminal",value:e.value};case"AbnfNumVal":return{type:"terminal",value:e.value};case"AbnfRuleName":return{type:"nonterminal",name:e.name};case"AbnfGroup":return i(e.element);case"AbnfOptionalGroup":return{type:"optional",element:i(e.element)};default:throw new Error(`Unsupported ABNF primary node: ${e.$type}`)}},"transformPrimary"),P=a(e=>({name:e.name,definition:i(e.definition)}),"transformRule"),h=a(e=>{f(e,n),e.title&&n.setTitle(e.title),e.rules.map(r=>n.addRule(P(r)))},"populateDb"),R={parse:a(e=>{n.clear(),o.debug("[ABNF Parser] Starting Langium parse");const r=v.parse(e);if(r.lexerErrors.length>0||r.parserErrors.length>0)throw new c(r);const t=r.value;o.debug("[ABNF Parser] Parsed rules:",t.rules.length),h(t),o.debug("[ABNF Parser] Parse complete")},"parse"),parser:{yy:n}},w={parser:R,db:n,renderer:u,styles:p};export{w as diagram};
1
+ import{g as p,r as u,d as n}from"./DpJ5Wccc.js";import{p as f}from"./BYfly9_3.js";import{b as a,ay as o}from"./BFTlNJv7.js";import{M as c,c as d}from"./ltO9jYXn.js";var v=d().RailroadAbnf.parser.LangiumParser,i=a(e=>{const r=e.alternatives.map(g);return r.length===1?r[0]:{type:"choice",alternatives:r}},"transformAlternation"),g=a(e=>{const r=e.elements.map(y);return r.length===1?r[0]:{type:"sequence",elements:r}},"transformConcatenation"),b=a(e=>{if(e.includes("*")){const[t,s]=e.split("*"),l=t?parseInt(t,10):0,m=s?parseInt(s,10):1/0;return{min:l,max:m}}const r=parseInt(e,10);return{min:r,max:r}},"parseRepeat"),y=a(e=>{const r=A(e.primary);if(!e.repeat)return r;const{min:t,max:s}=b(e.repeat);return t===0&&s===1?{type:"optional",element:r}:{type:"repetition",element:r,min:t,max:s}},"transformElement"),A=a(e=>{switch(e.$type){case"AbnfStringLiteral":return{type:"terminal",value:e.value};case"AbnfNumVal":return{type:"terminal",value:e.value};case"AbnfRuleName":return{type:"nonterminal",name:e.name};case"AbnfGroup":return i(e.element);case"AbnfOptionalGroup":return{type:"optional",element:i(e.element)};default:throw new Error(`Unsupported ABNF primary node: ${e.$type}`)}},"transformPrimary"),P=a(e=>({name:e.name,definition:i(e.definition)}),"transformRule"),h=a(e=>{f(e,n),e.title&&n.setTitle(e.title),e.rules.map(r=>n.addRule(P(r)))},"populateDb"),R={parse:a(e=>{n.clear(),o.debug("[ABNF Parser] Starting Langium parse");const r=v.parse(e);if(r.lexerErrors.length>0||r.parserErrors.length>0)throw new c(r);const t=r.value;o.debug("[ABNF Parser] Parsed rules:",t.rules.length),h(t),o.debug("[ABNF Parser] Parse complete")},"parse"),parser:{yy:n}},w={parser:R,db:n,renderer:u,styles:p};export{w as diagram};