@powerhousedao/connect 1.0.0-dev.134 → 1.0.0-dev.135

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 (105) hide show
  1. package/dist/assets/{browser-BEEirMuO.js → browser-Bl9M96KQ.js} +4 -4
  2. package/dist/assets/{content-BA89BGTU.js.map → browser-Bl9M96KQ.js.map} +1 -1
  3. package/dist/assets/{ccip-6rlDGLkL-DLquEPm3-DsHnVs3R.js → ccip-6rlDGLkL-DLquEPm3-BAx7HjfJ.js} +2 -2
  4. package/dist/assets/ccip-6rlDGLkL-DLquEPm3-BAx7HjfJ.js.map +1 -0
  5. package/dist/assets/{ccip-D7jGecEM-BZhoTqQe.js → ccip-D7jGecEM-DVDlOqoI.js} +2 -2
  6. package/dist/assets/ccip-D7jGecEM-DVDlOqoI.js.map +1 -0
  7. package/dist/assets/{ccip-C90evIJH.js → ccip-bk1IJr0a.js} +2 -2
  8. package/dist/assets/ccip-bk1IJr0a.js.map +1 -0
  9. package/dist/assets/{content-BA89BGTU.js → content-TdogUNEo.js} +3 -3
  10. package/dist/assets/{browser-BEEirMuO.js.map → content-TdogUNEo.js.map} +1 -1
  11. package/dist/assets/{cssMode-DVq3LtHT-T-7Kj20A.js → cssMode-DVq3LtHT-CoUgr_4L.js} +2 -2
  12. package/dist/assets/cssMode-DVq3LtHT-CoUgr_4L.js.map +1 -0
  13. package/dist/assets/{editor-B8aF84QX.js → editor-Bat08LEU.js} +2 -2
  14. package/dist/assets/editor-Bat08LEU.js.map +1 -0
  15. package/dist/assets/{editor-D1liwP8t.js → editor-CIbZp8-c.js} +4 -4
  16. package/dist/assets/{editor-D1liwP8t.js.map → editor-CIbZp8-c.js.map} +1 -1
  17. package/dist/assets/{editor-C6Um7TKF.js → editor-Cxi1Bi4m.js} +2 -2
  18. package/dist/assets/editor-Cxi1Bi4m.js.map +1 -0
  19. package/dist/assets/{editor-ZZR7pxvt.js → editor-NPbexOjM.js} +2 -2
  20. package/dist/assets/editor-NPbexOjM.js.map +1 -0
  21. package/dist/assets/{editors-BvDPqtae.js → editors-DVrDEp-F.js} +7 -7
  22. package/dist/assets/{editors-BvDPqtae.js.map → editors-DVrDEp-F.js.map} +1 -1
  23. package/dist/assets/{freemarker2-B12auKfc-CV2bI2LT.js → freemarker2-B12auKfc-CY1f5BH_.js} +2 -2
  24. package/dist/assets/freemarker2-B12auKfc-CY1f5BH_.js.map +1 -0
  25. package/dist/assets/{handlebars-fup3rJ3C-CxSp7nNU.js → handlebars-fup3rJ3C-DIrFum2b.js} +2 -2
  26. package/dist/assets/handlebars-fup3rJ3C-DIrFum2b.js.map +1 -0
  27. package/dist/assets/{html-Bd7p9h1P-VHQCRfyo.js → html-Bd7p9h1P-DH0yLc_S.js} +2 -2
  28. package/dist/assets/html-Bd7p9h1P-DH0yLc_S.js.map +1 -0
  29. package/dist/assets/{htmlMode-D_EcT_ua-DeobOP5l.js → htmlMode-D_EcT_ua-BUl6Pr_e.js} +2 -2
  30. package/dist/assets/htmlMode-D_EcT_ua-BUl6Pr_e.js.map +1 -0
  31. package/dist/assets/{index-8PbnK2go-D-EdohcU.js → index-8PbnK2go-BoR1WEku.js} +2 -2
  32. package/dist/assets/index-8PbnK2go-BoR1WEku.js.map +1 -0
  33. package/dist/assets/{index-Dsh5c9Wv.js → index-CMnBdWsa.js} +2 -2
  34. package/dist/assets/{index-Dsh5c9Wv.js.map → index-CMnBdWsa.js.map} +1 -1
  35. package/dist/assets/{index-CnxM4IIa-CvFEW5IC.js → index-CnxM4IIa-CoekJPsT.js} +18 -18
  36. package/dist/assets/index-CnxM4IIa-CoekJPsT.js.map +1 -0
  37. package/dist/assets/{index-Dc3srWFp-Dj58lFaD.js → index-Dc3srWFp-DVPU56zP.js} +2 -2
  38. package/dist/assets/index-Dc3srWFp-DVPU56zP.js.map +1 -0
  39. package/dist/assets/{index-T6Et30Eh-Bk15VVSB.js → index-T6Et30Eh-B1ytNt1O.js} +2 -2
  40. package/dist/assets/index-T6Et30Eh-B1ytNt1O.js.map +1 -0
  41. package/dist/assets/{javascript-egJvx3xR-D5qg5jV7.js → javascript-egJvx3xR-CXu0MlTd.js} +2 -2
  42. package/dist/assets/javascript-egJvx3xR-CXu0MlTd.js.map +1 -0
  43. package/dist/assets/{jsonMode-CmFhZ-nO-Ct78-OTz.js → jsonMode-CmFhZ-nO-BJHj7Aq3.js} +2 -2
  44. package/dist/assets/jsonMode-CmFhZ-nO-BJHj7Aq3.js.map +1 -0
  45. package/dist/assets/{liquid-Bn94NRXM-D3xTeo2T.js → liquid-Bn94NRXM-DXR9Xdil.js} +2 -2
  46. package/dist/assets/liquid-Bn94NRXM-DXR9Xdil.js.map +1 -0
  47. package/dist/assets/{main.DHxrtmJK.js → main.9ezbfd1a.js} +5 -5
  48. package/dist/assets/{main.DHxrtmJK.js.map → main.9ezbfd1a.js.map} +1 -1
  49. package/dist/assets/{mdx-CUs5ly0Y-DxijAFif.js → mdx-CUs5ly0Y-PFSuKGqp.js} +2 -2
  50. package/dist/assets/mdx-CUs5ly0Y-PFSuKGqp.js.map +1 -0
  51. package/dist/assets/{python-CvQNUgbY-DBYmw6_9.js → python-CvQNUgbY-DKU7Nn90.js} +2 -2
  52. package/dist/assets/python-CvQNUgbY-DKU7Nn90.js.map +1 -0
  53. package/dist/assets/{razor-COKLAES4-BPYm69MZ.js → razor-COKLAES4-DVH5NG6J.js} +2 -2
  54. package/dist/assets/razor-COKLAES4-DVH5NG6J.js.map +1 -0
  55. package/dist/assets/{root-0NIp6wBQ.js → root-D5vIE4mi.js} +2 -2
  56. package/dist/assets/root-D5vIE4mi.js.map +1 -0
  57. package/dist/assets/{router-j5rEsdZ1.js → router-BLZPRKeS.js} +4 -4
  58. package/dist/assets/{router-j5rEsdZ1.js.map → router-BLZPRKeS.js.map} +1 -1
  59. package/dist/assets/{tsMode-Dj44YKby-CWl_rxwS.js → tsMode-Dj44YKby-BecbNaDB.js} +2 -2
  60. package/dist/assets/tsMode-Dj44YKby-BecbNaDB.js.map +1 -0
  61. package/dist/assets/{typescript-BGB8OuQj-CojMjzn1.js → typescript-BGB8OuQj-q21L76s7.js} +2 -2
  62. package/dist/assets/typescript-BGB8OuQj-q21L76s7.js.map +1 -0
  63. package/dist/assets/{typescript-e2Impz-Y-ZFE3ath_.js → typescript-e2Impz-Y-eyfqYqVi.js} +2 -2
  64. package/dist/assets/{typescript-e2Impz-Y-ZFE3ath_.js.map → typescript-e2Impz-Y-eyfqYqVi.js.map} +1 -1
  65. package/dist/assets/{useUiNodes-CFkBr3IB.js → useUiNodes-BpMMwQ0y.js} +2 -2
  66. package/dist/assets/{useUiNodes-CFkBr3IB.js.map → useUiNodes-BpMMwQ0y.js.map} +1 -1
  67. package/dist/assets/{visitor-jgO2GXVr-CpK_hqN0.js → visitor-jgO2GXVr-DtE61rfq.js} +2 -2
  68. package/dist/assets/visitor-jgO2GXVr-DtE61rfq.js.map +1 -0
  69. package/dist/assets/{xml-C95L75A3-DKw4cO1a.js → xml-C95L75A3-CktYugFs.js} +2 -2
  70. package/dist/assets/xml-C95L75A3-CktYugFs.js.map +1 -0
  71. package/dist/assets/{yaml-CBgf5N3D-Chtc7gtl.js → yaml-CBgf5N3D-DNYfpm9a.js} +2 -2
  72. package/dist/assets/yaml-CBgf5N3D-DNYfpm9a.js.map +1 -0
  73. package/dist/index.html +3 -3
  74. package/dist/service-worker.js +1 -1
  75. package/dist/swEnv.js +2 -2
  76. package/dist/vite-envs.sh +5 -5
  77. package/package/index.js +46 -8
  78. package/package.json +1 -1
  79. package/dist/assets/ccip-6rlDGLkL-DLquEPm3-DsHnVs3R.js.map +0 -1
  80. package/dist/assets/ccip-C90evIJH.js.map +0 -1
  81. package/dist/assets/ccip-D7jGecEM-BZhoTqQe.js.map +0 -1
  82. package/dist/assets/cssMode-DVq3LtHT-T-7Kj20A.js.map +0 -1
  83. package/dist/assets/editor-B8aF84QX.js.map +0 -1
  84. package/dist/assets/editor-C6Um7TKF.js.map +0 -1
  85. package/dist/assets/editor-ZZR7pxvt.js.map +0 -1
  86. package/dist/assets/freemarker2-B12auKfc-CV2bI2LT.js.map +0 -1
  87. package/dist/assets/handlebars-fup3rJ3C-CxSp7nNU.js.map +0 -1
  88. package/dist/assets/html-Bd7p9h1P-VHQCRfyo.js.map +0 -1
  89. package/dist/assets/htmlMode-D_EcT_ua-DeobOP5l.js.map +0 -1
  90. package/dist/assets/index-8PbnK2go-D-EdohcU.js.map +0 -1
  91. package/dist/assets/index-CnxM4IIa-CvFEW5IC.js.map +0 -1
  92. package/dist/assets/index-Dc3srWFp-Dj58lFaD.js.map +0 -1
  93. package/dist/assets/index-T6Et30Eh-Bk15VVSB.js.map +0 -1
  94. package/dist/assets/javascript-egJvx3xR-D5qg5jV7.js.map +0 -1
  95. package/dist/assets/jsonMode-CmFhZ-nO-Ct78-OTz.js.map +0 -1
  96. package/dist/assets/liquid-Bn94NRXM-D3xTeo2T.js.map +0 -1
  97. package/dist/assets/mdx-CUs5ly0Y-DxijAFif.js.map +0 -1
  98. package/dist/assets/python-CvQNUgbY-DBYmw6_9.js.map +0 -1
  99. package/dist/assets/razor-COKLAES4-BPYm69MZ.js.map +0 -1
  100. package/dist/assets/root-0NIp6wBQ.js.map +0 -1
  101. package/dist/assets/tsMode-Dj44YKby-CWl_rxwS.js.map +0 -1
  102. package/dist/assets/typescript-BGB8OuQj-CojMjzn1.js.map +0 -1
  103. package/dist/assets/visitor-jgO2GXVr-CpK_hqN0.js.map +0 -1
  104. package/dist/assets/xml-C95L75A3-DKw4cO1a.js.map +0 -1
  105. package/dist/assets/yaml-CBgf5N3D-Chtc7gtl.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"mappings":"","names":[],"ignoreList":[],"sources":[],"sourcesContent":[],"file":"assets/editor-D1liwP8t.js"}
1
+ {"version":3,"mappings":"","names":[],"ignoreList":[],"sources":[],"sourcesContent":[],"file":"assets/editor-CIbZp8-c.js"}
@@ -1,2 +1,2 @@
1
- import{r as d,d as e,B as a}from"./main.DHxrtmJK.js";import{D as h,E as u,T as n,a as x,b as j,J as b}from"./editors-BvDPqtae.js";function E({dispatch:s,document:o,context:r}){const[l,i]=d.useState(o.state.global);d.useEffect(()=>{i(o.state.global)},[o.state]);function c(t){s(a.loadState({state:{global:t,local:o.state.local},name:o.name},0))}const m=t=>{s(a.setName(t))};return e.jsxs(h,{mode:r.theme,children:[e.jsx(u,{center:[e.jsx(n,{onClick:()=>c(l),children:"Save"},"save")],left:[e.jsx(n,{onClick:()=>s(a.undo(1)),children:"↺ undo"},"undo"),e.jsx(n,{onClick:()=>s(a.redo(1)),children:"↻ redo"},"redo")],right:[e.jsx(n,{children:"revision history"},"rev")]},"toolbar"),e.jsxs(x,{children:[e.jsx("div",{style:{marginBottom:"1em"},children:e.jsx(j,{onSubmit:m,placeholder:"Document name",size:"medium",theme:r.theme,value:o.name},"doc-title")}),e.jsx(b,{onBlur:t=>c(t),onChange:t=>i(t||{}),theme:r.theme,value:l})]},"sheet")]})}export{E as default};
2
- //# sourceMappingURL=editor-C6Um7TKF.js.map
1
+ import{r as d,d as e,B as a}from"./main.9ezbfd1a.js";import{D as h,E as u,T as n,a as x,b as j,J as b}from"./editors-DVrDEp-F.js";function E({dispatch:s,document:o,context:r}){const[l,i]=d.useState(o.state.global);d.useEffect(()=>{i(o.state.global)},[o.state]);function c(t){s(a.loadState({state:{global:t,local:o.state.local},name:o.name},0))}const m=t=>{s(a.setName(t))};return e.jsxs(h,{mode:r.theme,children:[e.jsx(u,{center:[e.jsx(n,{onClick:()=>c(l),children:"Save"},"save")],left:[e.jsx(n,{onClick:()=>s(a.undo(1)),children:"↺ undo"},"undo"),e.jsx(n,{onClick:()=>s(a.redo(1)),children:"↻ redo"},"redo")],right:[e.jsx(n,{children:"revision history"},"rev")]},"toolbar"),e.jsxs(x,{children:[e.jsx("div",{style:{marginBottom:"1em"},children:e.jsx(j,{onSubmit:m,placeholder:"Document name",size:"medium",theme:r.theme,value:o.name},"doc-title")}),e.jsx(b,{onBlur:t=>c(t),onChange:t=>i(t||{}),theme:r.theme,value:l})]},"sheet")]})}export{E as default};
2
+ //# sourceMappingURL=editor-Cxi1Bi4m.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"editor-Cxi1Bi4m.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,2 +1,2 @@
1
- import{d as e,r as g,m}from"./main.DHxrtmJK.js";const b=({accounts:a,addAccount:s})=>{function c(d){d.preventDefault();const l=d.target,n=new FormData(l),t=Object.fromEntries(n.entries());s(t)}return e.jsxs("form",{method:"post",onSubmit:c,style:{maxWidth:300},children:[e.jsxs("label",{children:["Address: ",e.jsx("input",{name:"address",placeholder:"eth:0x..."})]}),e.jsx("pre",{}),e.jsxs("label",{children:["Name: ",e.jsx("input",{name:"name",placeholder:""})]}),e.jsx("pre",{}),e.jsx("button",{type:"submit",children:"Submit"})]},a.length)},x=new Intl.NumberFormat("en-US",{style:"currency",currency:"USD"}),f=({data:a,onDeleteAccount:s,onDeleteLineItem:c})=>{const d=a.accounts,l=g.useMemo(()=>d.map(({address:n,name:t,lineItems:r})=>{const{actuals:u,payments:o}=r.reduce((i,p)=>({actuals:i.actuals+(p.actual||0),payments:i.payments+(p.payment||0)}),{actuals:0,payments:0});return{address:n,name:t,actuals:u,payments:o}}),[d]);return e.jsxs("div",{children:[e.jsx("h2",{children:"Accounts:"}),e.jsxs("table",{style:{borderSpacing:12},children:[e.jsx("thead",{children:e.jsxs("tr",{children:[e.jsx("th",{align:"left",children:"Name"}),e.jsx("th",{align:"left",children:"Address"}),e.jsx("th",{align:"left",children:"Actuals"}),e.jsx("th",{align:"left",children:"Payments"})]})}),e.jsx("tbody",{children:l.map(n=>e.jsxs("tr",{children:[e.jsx("td",{children:n.name}),e.jsxs("td",{children:[n.address.slice(0,10),"..."]}),e.jsx("td",{children:x.format(n.actuals)}),e.jsx("td",{children:x.format(n.payments)}),s?e.jsx("td",{children:e.jsx("button",{onClick:()=>s(n.address),children:"Delete"})}):null]},n.address))})]})]})},h=[{ref:"makerdao/budget-category",id:"CompensationAndBenefits",title:"Compensation & Benefits",headcountExpense:!0},{ref:"makerdao/budget-category",id:"TravelAndEntertainment",title:"Travel & Entertainment",headcountExpense:!0},{ref:"makerdao/budget-category",id:"SoftwareDevelopmentExpense",title:"Software Development Expense",headcountExpense:!1},{ref:"makerdao/budget-category",id:"GasExpense",title:"Gas Expense",headcountExpense:!0}],j=[{ref:"makerdao/project",id:"Powerhouse",title:"Powerhouse",color:"purple"},{ref:"makerdao/project",id:"LegalResearch",title:"Legal Research",color:"red"},{ref:"makerdao/project",id:"MakerAcademy",title:"Maker Academy",color:"teal"}],y=({accounts:a,addLineItem:s})=>{var c;const[d,l]=g.useState(a.length?a[0].address:"");function n(t){t.preventDefault();const r=t.target,u=new FormData(r),o=Object.fromEntries(u.entries());s({accountId:u.get("account").toString(),budgetCap:parseFloat(o.budgetCap.toString()),actual:parseFloat(o.actual.toString()),payment:parseFloat(o.payment.toString()),category:h.find(i=>i.id===o.category.toString()),group:j.find(i=>i.id===o.group.toString())})}return e.jsxs("form",{method:"post",onSubmit:n,style:{maxWidth:300},children:[e.jsxs("label",{children:["Select account:"," ",e.jsx("select",{name:"account",onChange:t=>l(t.target.value),value:d??"",children:a.map(t=>e.jsx("option",{value:t.address,children:t.name},t.address))})]}),e.jsx("pre",{}),e.jsxs("label",{children:["Category:"," ",e.jsx("select",{name:"category",children:h.map(t=>e.jsx("option",{value:t.id,children:t.title},t.id))})]}),e.jsx("pre",{}),e.jsxs("label",{children:["Group:"," ",e.jsx("select",{name:"group",children:j.map(t=>e.jsx("option",{value:t.id,children:t.title},t.id))})]}),e.jsx("pre",{}),e.jsxs("label",{children:["Budget Cap:"," ",e.jsx("input",{name:"budgetCap",placeholder:"0",type:"number"})]}),e.jsx("pre",{}),e.jsxs("label",{children:["Payment: ",e.jsx("input",{name:"payment",placeholder:"0",type:"number"})]}),e.jsx("pre",{}),e.jsxs("label",{children:["Actual: ",e.jsx("input",{name:"actual",placeholder:"0",type:"number"})]}),e.jsx("pre",{}),e.jsx("button",{type:"submit",children:"Submit"})]},(c=a.find(t=>t.address===d))==null?void 0:c.lineItems.length)};function A({document:a,dispatch:s}){function c(r){s(m.addAccount(r))}function d(r){s(m.addLineItem(r))}function l(r){s(m.deleteAccount({account:r}))}function n(r){s(m.deleteLineItem(r))}const t=a.state.global.accounts;return e.jsxs("div",{children:[e.jsx(f,{data:a.state.global,onDeleteAccount:l,onDeleteLineItem:n}),e.jsx("hr",{}),e.jsxs("div",{children:[e.jsx("h3",{children:"Add account"}),e.jsx(b,{accounts:t,addAccount:c})]}),e.jsxs("div",{children:[e.jsx("h3",{children:"Add Line Item"}),e.jsx(y,{accounts:t,addLineItem:d})]})]})}export{A as default};
2
- //# sourceMappingURL=editor-ZZR7pxvt.js.map
1
+ import{d as e,r as g,m}from"./main.9ezbfd1a.js";const b=({accounts:a,addAccount:s})=>{function c(d){d.preventDefault();const l=d.target,n=new FormData(l),t=Object.fromEntries(n.entries());s(t)}return e.jsxs("form",{method:"post",onSubmit:c,style:{maxWidth:300},children:[e.jsxs("label",{children:["Address: ",e.jsx("input",{name:"address",placeholder:"eth:0x..."})]}),e.jsx("pre",{}),e.jsxs("label",{children:["Name: ",e.jsx("input",{name:"name",placeholder:""})]}),e.jsx("pre",{}),e.jsx("button",{type:"submit",children:"Submit"})]},a.length)},x=new Intl.NumberFormat("en-US",{style:"currency",currency:"USD"}),f=({data:a,onDeleteAccount:s,onDeleteLineItem:c})=>{const d=a.accounts,l=g.useMemo(()=>d.map(({address:n,name:t,lineItems:r})=>{const{actuals:u,payments:o}=r.reduce((i,p)=>({actuals:i.actuals+(p.actual||0),payments:i.payments+(p.payment||0)}),{actuals:0,payments:0});return{address:n,name:t,actuals:u,payments:o}}),[d]);return e.jsxs("div",{children:[e.jsx("h2",{children:"Accounts:"}),e.jsxs("table",{style:{borderSpacing:12},children:[e.jsx("thead",{children:e.jsxs("tr",{children:[e.jsx("th",{align:"left",children:"Name"}),e.jsx("th",{align:"left",children:"Address"}),e.jsx("th",{align:"left",children:"Actuals"}),e.jsx("th",{align:"left",children:"Payments"})]})}),e.jsx("tbody",{children:l.map(n=>e.jsxs("tr",{children:[e.jsx("td",{children:n.name}),e.jsxs("td",{children:[n.address.slice(0,10),"..."]}),e.jsx("td",{children:x.format(n.actuals)}),e.jsx("td",{children:x.format(n.payments)}),s?e.jsx("td",{children:e.jsx("button",{onClick:()=>s(n.address),children:"Delete"})}):null]},n.address))})]})]})},h=[{ref:"makerdao/budget-category",id:"CompensationAndBenefits",title:"Compensation & Benefits",headcountExpense:!0},{ref:"makerdao/budget-category",id:"TravelAndEntertainment",title:"Travel & Entertainment",headcountExpense:!0},{ref:"makerdao/budget-category",id:"SoftwareDevelopmentExpense",title:"Software Development Expense",headcountExpense:!1},{ref:"makerdao/budget-category",id:"GasExpense",title:"Gas Expense",headcountExpense:!0}],j=[{ref:"makerdao/project",id:"Powerhouse",title:"Powerhouse",color:"purple"},{ref:"makerdao/project",id:"LegalResearch",title:"Legal Research",color:"red"},{ref:"makerdao/project",id:"MakerAcademy",title:"Maker Academy",color:"teal"}],y=({accounts:a,addLineItem:s})=>{var c;const[d,l]=g.useState(a.length?a[0].address:"");function n(t){t.preventDefault();const r=t.target,u=new FormData(r),o=Object.fromEntries(u.entries());s({accountId:u.get("account").toString(),budgetCap:parseFloat(o.budgetCap.toString()),actual:parseFloat(o.actual.toString()),payment:parseFloat(o.payment.toString()),category:h.find(i=>i.id===o.category.toString()),group:j.find(i=>i.id===o.group.toString())})}return e.jsxs("form",{method:"post",onSubmit:n,style:{maxWidth:300},children:[e.jsxs("label",{children:["Select account:"," ",e.jsx("select",{name:"account",onChange:t=>l(t.target.value),value:d??"",children:a.map(t=>e.jsx("option",{value:t.address,children:t.name},t.address))})]}),e.jsx("pre",{}),e.jsxs("label",{children:["Category:"," ",e.jsx("select",{name:"category",children:h.map(t=>e.jsx("option",{value:t.id,children:t.title},t.id))})]}),e.jsx("pre",{}),e.jsxs("label",{children:["Group:"," ",e.jsx("select",{name:"group",children:j.map(t=>e.jsx("option",{value:t.id,children:t.title},t.id))})]}),e.jsx("pre",{}),e.jsxs("label",{children:["Budget Cap:"," ",e.jsx("input",{name:"budgetCap",placeholder:"0",type:"number"})]}),e.jsx("pre",{}),e.jsxs("label",{children:["Payment: ",e.jsx("input",{name:"payment",placeholder:"0",type:"number"})]}),e.jsx("pre",{}),e.jsxs("label",{children:["Actual: ",e.jsx("input",{name:"actual",placeholder:"0",type:"number"})]}),e.jsx("pre",{}),e.jsx("button",{type:"submit",children:"Submit"})]},(c=a.find(t=>t.address===d))==null?void 0:c.lineItems.length)};function A({document:a,dispatch:s}){function c(r){s(m.addAccount(r))}function d(r){s(m.addLineItem(r))}function l(r){s(m.deleteAccount({account:r}))}function n(r){s(m.deleteLineItem(r))}const t=a.state.global.accounts;return e.jsxs("div",{children:[e.jsx(f,{data:a.state.global,onDeleteAccount:l,onDeleteLineItem:n}),e.jsx("hr",{}),e.jsxs("div",{children:[e.jsx("h3",{children:"Add account"}),e.jsx(b,{accounts:t,addAccount:c})]}),e.jsxs("div",{children:[e.jsx("h3",{children:"Add Line Item"}),e.jsx(y,{accounts:t,addLineItem:d})]})]})}export{A as default};
2
+ //# sourceMappingURL=editor-NPbexOjM.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"editor-NPbexOjM.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1,5 +1,5 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index-T6Et30Eh-Bk15VVSB.js","assets/main.DHxrtmJK.js","assets/main-Bfrdc6YH.css","assets/index-CnxM4IIa-CvFEW5IC.js","assets/index-Dc3srWFp-Dj58lFaD.js","assets/visitor-jgO2GXVr-CpK_hqN0.js","assets/index-6e_WqBNj-CJvJXHul.js","assets/index-8PbnK2go-D-EdohcU.js","assets/_commonjs-dynamic-modules-BpilXLfW-DfYEAvWy.js","assets/typescript-e2Impz-Y-ZFE3ath_.js","assets/editor-C6Um7TKF.js","assets/editor-ZZR7pxvt.js","assets/editor-B8aF84QX.js","assets/editor-D1liwP8t.js"])))=>i.map(i=>d[i]);
2
- import{J as J$4,_ as __vitePreload,Z as Ze$1,ar as f$3,d as jsxRuntimeExports,r as reactExports,i as index,as as yx,at as actions}from"./main.DHxrtmJK.js";var a$3={};Object.defineProperty(a$3,"__esModule",{value:!0});var P$3=a$3.lazyWithPreload=void 0,r$3=J$4;function i$4(it){var ct=(0,r$3.lazy)(it),Ot,qt,Zn=(0,r$3.forwardRef)(function(oo,io){var ao=(0,r$3.useRef)(Ot??ct);return(0,r$3.createElement)(ao.current,Object.assign(io?{ref:io}:{},oo))}),no=Zn;return no.preload=function(){return qt||(qt=it().then(function(oo){return Ot=oo.default,Ot})),qt},no}P$3=a$3.lazyWithPreload=i$4;a$3.default=i$4;function _mergeNamespaces(it,ct){for(var Ot=0;Ot<ct.length;Ot++){const qt=ct[Ot];if(typeof qt!="string"&&!Array.isArray(qt)){for(const Zn in qt)if(Zn!=="default"&&!(Zn in it)){const no=Object.getOwnPropertyDescriptor(qt,Zn);no&&Object.defineProperty(it,Zn,no.get?no:{enumerable:!0,get:()=>qt[Zn]})}}}return Object.freeze(Object.defineProperty(it,Symbol.toStringTag,{value:"Module"}))}function DocumentEditor(it){const ct=["document-editor",`${it.mode}-mode`];return jsxRuntimeExports.jsx("div",{className:ct.join(" "),children:it.children})}function EditorToolbar(it){const ct=it.left||[],Ot=it.center||[],qt=it.right||[];return jsxRuntimeExports.jsxs("div",{className:"editor-toolbar",children:[jsxRuntimeExports.jsx("div",{className:"editor-toolbar--column editor-toolbar--left",children:ct}),jsxRuntimeExports.jsx("div",{className:"editor-toolbar--column editor-toolbar--center",children:Ot}),jsxRuntimeExports.jsx("div",{className:"editor-toolbar--column editor-toolbar--right",children:qt})]})}function EditorWorksheet(it){return jsxRuntimeExports.jsx("div",{className:"editor-worksheet",children:jsxRuntimeExports.jsx("div",{className:"editor-worksheet--page",children:it.children})})}const colorScheme$1={light:{color:"#222222",bgColor:"#FFFFFF",border:"#EEEEEE",shadow:"rgba(128,128,128,0.65)",inputColor:"#222222",inputBg:"#F6F6F6"},dark:{color:"#E6E6E6",bgColor:"#181818",border:"#181818",shadow:"rgba(0, 0, 0, 0.25)",inputColor:"#E6E6E6",inputBg:"#222222"}},typographySizes$1={huge:{fontSize:"36pt",fontWeight:"bold",padding:"6pt",margin:"30pt 0 0 0"},larger:{fontSize:"24pt",fontWeight:"bold",padding:"6pt",margin:"18pt 0 0 0"},large:{fontSize:"18pt",fontWeight:"bold",padding:"6pt",margin:"12pt 0 0 0"},medium:{fontSize:"11pt",fontWeight:"bold",padding:"6pt",margin:"5pt 0 0 0"},small:{fontSize:"10pt",fontWeight:"normal",padding:"6pt",margin:"0"},smaller:{fontSize:"9pt",fontWeight:"normal",padding:"6pt",margin:"0"},tiny:{fontSize:"8pt",fontWeight:"normal",padding:"6pt",margin:"0"}},inputStyle$1=(it="light",ct=!1)=>{const Ot=colorScheme$1[it];return{width:"100%",border:"none",boxSizing:"border-box",backgroundColor:ct?Ot.inputBg:Ot.bgColor,outline:"none",color:Ot.inputColor,resize:"none",fontFamily:"Roboto, sans-serif",overflow:"hidden",lineHeight:"1.5"}},styles=Object.freeze(Object.defineProperty({__proto__:null,colorScheme:colorScheme$1,inputStyle:inputStyle$1,typographySizes:typographySizes$1},Symbol.toStringTag,{value:"Module"})),colorScheme={light:{color:"#222222",bgColor:"#FFFFFF",border:"#EEEEEE",shadow:"rgba(128,128,128,0.65)",inputColor:"#222222",inputBg:"#F6F6F6"},dark:{color:"#CCCCCC",bgColor:"#0A0A0A",border:"#181818",shadow:"rgba(255, 255, 255, 0.25)",inputColor:"#CCCCCC",inputBg:"#1A1D1F"}},typographySizes={chapter:{fontSize:"64pt",fontWeight:"bold",padding:"6pt 24pt",margin:"0",lineHeight:1,textAlign:"right",borderLeft:"4px solid"},huge:{fontSize:"32pt",fontWeight:"normal",padding:"6pt",margin:"0 0 0 -6pt",lineHeight:1},larger:{fontSize:"24pt",fontWeight:"bold",padding:"6pt",margin:"-12pt 0 0 0"},large:{fontSize:"18pt",fontWeight:"bold",padding:"6pt",margin:"-10.5pt 0 0 0"},medium:{fontSize:"11pt",fontWeight:"bold",padding:"6pt",margin:"-8pt 0 0 0"},small:{fontSize:"10pt",fontWeight:"normal",padding:"6pt",margin:"-6pt 0 0 0"},smaller:{fontSize:"9pt",fontWeight:"normal",padding:"6pt",margin:"-5pt 0 0 0"},tiny:{fontSize:"8pt",fontWeight:"normal",padding:"6pt",margin:"-8pt 0 0 0"}},inputStyle=(it="light",ct=!1)=>{const Ot=colorScheme[it];return{width:"100%",border:"none",boxSizing:"border-box",backgroundColor:ct?Ot.inputBg:Ot.bgColor,outline:"none",color:Ot.inputColor,resize:"none",fontFamily:"Roboto, sans-serif",overflow:"hidden",lineHeight:"1.5"}},stylesVariant=Object.freeze(Object.defineProperty({__proto__:null,colorScheme,inputStyle,typographySizes},Symbol.toStringTag,{value:"Module"}));function TextInput(it){const[ct,Ot]=reactExports.useState({value:it.value||"",hasFocus:!1,pressingEnter:!1});reactExports.useEffect(()=>{Ot(so=>so.value!==it.value?{...so,value:it.value||""}:so)},[it.value]);const qt=so=>{so.key==="Enter"&&(Ot({...ct,pressingEnter:!0}),so.preventDefault())},Zn=so=>{so.key==="Enter"&&(so.target&&it.onSubmit&&it.onSubmit(so.target.value),it.clearOnSubmit?Ot({...ct,value:"",pressingEnter:!1}):Ot({...ct,pressingEnter:!1}),so.preventDefault()),(so.key==="Backspace"||so.key==="Delete")&&(it.onEmpty&&so.target.value.length<1&&it.onEmpty(it.id||""),so.preventDefault())},no=so=>{if(!ct.pressingEnter){const lo=so.target;Ot({...ct,value:lo.value}),lo.style.height="1px",lo.style.height=lo.scrollHeight+"px"}},oo=so=>{var lo;if(Ot(co=>({...co,hasFocus:so})),!so){const co=((lo=io.current)==null?void 0:lo.value)||"",uo=it.value||"";co!=uo&&it.onSubmit&&(it.onSubmit(co),it.clearOnSubmit&&Ot(po=>({...po,value:""})))}},io=reactExports.useRef(null);reactExports.useEffect(()=>{const so=()=>{io.current&&(io.current.style.height="1px",io.current.style.height=io.current.scrollHeight+"px")};return window.addEventListener("resize",so),so(),()=>{window.removeEventListener("resize",so)}});const ao={...inputStyle$1(it.theme,ct.hasFocus),...typographySizes$1[it.size||"small"]};return jsxRuntimeExports.jsxs("div",{children:[it.horizontalLine?jsxRuntimeExports.jsx("hr",{style:{borderColor:inputStyle$1(it.theme,!1).backgroundColor}},"line"):"",jsxRuntimeExports.jsx("textarea",{autoFocus:it.autoFocus||!1,onBlur:so=>oo(!1),onFocus:so=>oo(!0),onInput:no,onKeyDown:qt,onKeyUp:Zn,placeholder:it.placeholder||"",ref:io,style:ao,value:ct.value},"text")]})}function TextInputVariant(it){const[ct,Ot]=reactExports.useState({value:it.value||"",hasFocus:!1,pressingEnter:!1});reactExports.useEffect(()=>{Ot({...ct,value:it.value||""})},[it.value]);const qt=so=>{so.key==="Enter"&&(Ot({...ct,pressingEnter:!0}),so.preventDefault())},Zn=so=>{so.key==="Enter"&&(so.target&&it.onSubmit&&it.onSubmit(so.target.value),it.clearOnSubmit?Ot({...ct,value:"",pressingEnter:!1}):Ot({...ct,pressingEnter:!1}),so.preventDefault()),(so.key==="Backspace"||so.key==="Delete")&&(it.onEmpty&&so.target.value.length<1&&it.onEmpty(it.id||""),so.preventDefault())},no=so=>{if(!ct.pressingEnter){const lo=so.target;Ot({...ct,value:lo.value}),lo.style.height="1px",lo.style.height=lo.scrollHeight+"px"}},oo=so=>{var lo;if(Ot({...ct,hasFocus:so}),!so){const co=((lo=io.current)==null?void 0:lo.value)||"",uo=it.value||"";co!=uo&&it.onSubmit&&it.onSubmit(co)}},io=reactExports.useRef(null);reactExports.useEffect(()=>{const so=()=>{io.current&&(io.current.style.height="1px",io.current.style.height=io.current.scrollHeight+"px")};return window.addEventListener("resize",so),so(),()=>{window.removeEventListener("resize",so)}});const ao={...inputStyle(it.theme,ct.hasFocus),...typographySizes[it.size||"small"]};return it.labelStyle&&(ao.textAlign="center",ao.textTransform="uppercase",ao.backgroundColor="rgba(0, 0, 255, 0.05)",ao.borderRadius="8px",ao.padding="1px 0 4px 0",ao.margin="0",ao.fontWeight="bold",ao.fontSize="8pt",ao.color="#518EBE",ao.border="2px solid #518EBE",ao.cursor="pointer",ao.lineHeight="1.5"),jsxRuntimeExports.jsxs("div",{children:[it.horizontalLine?jsxRuntimeExports.jsx("hr",{style:{borderColor:inputStyle(it.theme,!1).backgroundColor}},"line"):"",jsxRuntimeExports.jsx("textarea",{autoFocus:it.autoFocus||!1,onBlur:so=>oo(!1),onFocus:so=>oo(!0),onInput:no,onKeyDown:qt,onKeyUp:Zn,placeholder:it.placeholder||"",ref:io,spellCheck:ct.hasFocus,style:ao,tabIndex:it.labelStyle?-1:1,value:ct.value},"text")]})}function ToolbarButton(it){const ct=it.onClick||(()=>{console.log("No onClick handler attached to button.")});return jsxRuntimeExports.jsx("div",{className:"toolbar-button",onClick:ct,style:{userSelect:"none"},children:it.children})}function wrapReducer(it,ct){return(Ot,qt)=>{try{return it(Ot,qt)}catch(Zn){return ct==null||ct(Zn),Ot}}}function createUseDocumentReducer(it,ct){return(Ot,qt)=>useDocumentReducer(it,ct(Ot),qt)}function useDocumentReducer(it,ct,Ot){const[qt,Zn]=reactExports.useState(ct);return[qt,(no,oo)=>{Zn(io=>{try{const ao=it(io,no),so=ao.operations[no.scope].slice(-1)[0];if(so.error){const lo=new Error(so.error);Ot==null||Ot(lo),oo==null||oo(lo)}return ao}catch(ao){return Ot==null||Ot(ao),oo==null||oo(ao),io}})}]}var u$2=Object.defineProperty,a$1=(it,ct)=>u$2(it,"name",{value:ct,configurable:!0}),y$1=(()=>{let it;return typeof window<"u"?it=window:typeof globalThis<"u"?it=globalThis:typeof global<"u"?it=global:typeof self<"u"?it=self:it={},it})(),{LOGLEVEL:b$3}=y$1,t$2={trace:1,debug:2,info:3,warn:4,error:5,silent:10},L$2=b$3,i$2=t$2[L$2]||t$2.info,s$1={trace:a$1((it,...ct)=>{i$2<=t$2.trace&&console.trace(it,...ct)},"trace"),debug:a$1((it,...ct)=>{i$2<=t$2.debug&&console.debug(it,...ct)},"debug"),info:a$1((it,...ct)=>{i$2<=t$2.info&&console.info(it,...ct)},"info"),warn:a$1((it,...ct)=>{i$2<=t$2.warn&&console.warn(it,...ct)},"warn"),error:a$1((it,...ct)=>{i$2<=t$2.error&&console.error(it,...ct)},"error"),log:a$1((it,...ct)=>{i$2<t$2.silent&&console.log(it,...ct)},"log")},c$1=new Set,n$1=a$1(it=>(ct,...Ot)=>{if(!c$1.has(ct))return c$1.add(ct),s$1[it](ct,...Ot)},"once");n$1.clear=()=>c$1.clear();n$1.trace=n$1("trace");n$1.debug=n$1("debug");n$1.info=n$1("info");n$1.warn=n$1("warn");n$1.error=n$1("error");n$1.log=n$1("log");var m$2=n$1("warn"),r$2=a$1(it=>(...ct)=>{let Ot=[];if(ct.length){let qt=/<span\s+style=(['"])([^'"]*)\1\s*>/gi,Zn=/<\/span>/gi,no;for(Ot.push(ct[0].replace(qt,"%c").replace(Zn,"%c"));no=qt.exec(ct[0]);)Ot.push(no[2]),Ot.push("");for(let oo=1;oo<ct.length;oo++)Ot.push(ct[oo])}s$1[it].apply(s$1,Ot)},"pretty");r$2.trace=r$2("trace");r$2.debug=r$2("debug");r$2.info=r$2("info");r$2.warn=r$2("warn");r$2.error=r$2("error");var R$2=(it=>(it.CHANNEL_WS_DISCONNECT="channelWSDisconnect",it.CHANNEL_CREATED="channelCreated",it.CONFIG_ERROR="configError",it.STORY_INDEX_INVALIDATED="storyIndexInvalidated",it.STORY_SPECIFIED="storySpecified",it.SET_CONFIG="setConfig",it.SET_STORIES="setStories",it.SET_INDEX="setIndex",it.SET_CURRENT_STORY="setCurrentStory",it.CURRENT_STORY_WAS_SET="currentStoryWasSet",it.FORCE_RE_RENDER="forceReRender",it.FORCE_REMOUNT="forceRemount",it.PRELOAD_ENTRIES="preloadStories",it.STORY_PREPARED="storyPrepared",it.DOCS_PREPARED="docsPrepared",it.STORY_CHANGED="storyChanged",it.STORY_UNCHANGED="storyUnchanged",it.STORY_RENDERED="storyRendered",it.STORY_MISSING="storyMissing",it.STORY_ERRORED="storyErrored",it.STORY_THREW_EXCEPTION="storyThrewException",it.STORY_RENDER_PHASE_CHANGED="storyRenderPhaseChanged",it.PLAY_FUNCTION_THREW_EXCEPTION="playFunctionThrewException",it.UNHANDLED_ERRORS_WHILE_PLAYING="unhandledErrorsWhilePlaying",it.UPDATE_STORY_ARGS="updateStoryArgs",it.STORY_ARGS_UPDATED="storyArgsUpdated",it.RESET_STORY_ARGS="resetStoryArgs",it.SET_FILTER="setFilter",it.SET_GLOBALS="setGlobals",it.UPDATE_GLOBALS="updateGlobals",it.GLOBALS_UPDATED="globalsUpdated",it.REGISTER_SUBSCRIPTION="registerSubscription",it.PREVIEW_KEYDOWN="previewKeydown",it.PREVIEW_BUILDER_PROGRESS="preview_builder_progress",it.SELECT_STORY="selectStory",it.STORIES_COLLAPSE_ALL="storiesCollapseAll",it.STORIES_EXPAND_ALL="storiesExpandAll",it.DOCS_RENDERED="docsRendered",it.SHARED_STATE_CHANGED="sharedStateChanged",it.SHARED_STATE_SET="sharedStateSet",it.NAVIGATE_URL="navigateUrl",it.UPDATE_QUERY_PARAMS="updateQueryParams",it.REQUEST_WHATS_NEW_DATA="requestWhatsNewData",it.RESULT_WHATS_NEW_DATA="resultWhatsNewData",it.SET_WHATS_NEW_CACHE="setWhatsNewCache",it.TOGGLE_WHATS_NEW_NOTIFICATIONS="toggleWhatsNewNotifications",it.TELEMETRY_ERROR="telemetryError",it.FILE_COMPONENT_SEARCH_REQUEST="fileComponentSearchRequest",it.FILE_COMPONENT_SEARCH_RESPONSE="fileComponentSearchResponse",it.SAVE_STORY_REQUEST="saveStoryRequest",it.SAVE_STORY_RESPONSE="saveStoryResponse",it.ARGTYPES_INFO_REQUEST="argtypesInfoRequest",it.ARGTYPES_INFO_RESPONSE="argtypesInfoResponse",it.CREATE_NEW_STORYFILE_REQUEST="createNewStoryfileRequest",it.CREATE_NEW_STORYFILE_RESPONSE="createNewStoryfileResponse",it))(R$2||{}),S$2=R$2,{CHANNEL_WS_DISCONNECT:_$1,CHANNEL_CREATED:T$1,CONFIG_ERROR:A$1,CREATE_NEW_STORYFILE_REQUEST:O$3,CREATE_NEW_STORYFILE_RESPONSE:N$2,CURRENT_STORY_WAS_SET:r$1,DOCS_PREPARED:D$2,DOCS_RENDERED:I$3,FILE_COMPONENT_SEARCH_REQUEST:C$3,FILE_COMPONENT_SEARCH_RESPONSE:o$2,FORCE_RE_RENDER:P$2,FORCE_REMOUNT:L$1,GLOBALS_UPDATED:a$2,NAVIGATE_URL:Y$1,PLAY_FUNCTION_THREW_EXCEPTION:U$2,UNHANDLED_ERRORS_WHILE_PLAYING:G$4,PRELOAD_ENTRIES:W$2,PREVIEW_BUILDER_PROGRESS:H$2,PREVIEW_KEYDOWN:d,REGISTER_SUBSCRIPTION:t$1,RESET_STORY_ARGS:p$2,SELECT_STORY:i$1,SET_CONFIG:l$1$1,SET_CURRENT_STORY:F$2,SET_FILTER:e,SET_GLOBALS:y,SET_INDEX:c,SET_STORIES:h$1,SHARED_STATE_CHANGED:f$2,SHARED_STATE_SET:g,STORIES_COLLAPSE_ALL:u$1,STORIES_EXPAND_ALL:s,STORY_ARGS_UPDATED:x$3,STORY_CHANGED:M$3,STORY_ERRORED:Q,STORY_INDEX_INVALIDATED:m$1,STORY_MISSING:V$2,STORY_PREPARED:w$2,STORY_RENDER_PHASE_CHANGED:B$2,STORY_RENDERED:X$1,STORY_SPECIFIED:b$2,STORY_THREW_EXCEPTION:q$2,STORY_UNCHANGED:K$1,UPDATE_GLOBALS:j$1,UPDATE_QUERY_PARAMS:k$4,UPDATE_STORY_ARGS:z$4,REQUEST_WHATS_NEW_DATA:J$3,RESULT_WHATS_NEW_DATA:Z,SET_WHATS_NEW_CACHE:$$3,TOGGLE_WHATS_NEW_NOTIFICATIONS:n,TELEMETRY_ERROR:v$2,SAVE_STORY_REQUEST:EE,SAVE_STORY_RESPONSE:RE,ARGTYPES_INFO_REQUEST:SE,ARGTYPES_INFO_RESPONSE:_E}=R$2;const Qn$1=Object.freeze(Object.defineProperty({__proto__:null,ARGTYPES_INFO_REQUEST:SE,ARGTYPES_INFO_RESPONSE:_E,CHANNEL_CREATED:T$1,CHANNEL_WS_DISCONNECT:_$1,CONFIG_ERROR:A$1,CREATE_NEW_STORYFILE_REQUEST:O$3,CREATE_NEW_STORYFILE_RESPONSE:N$2,CURRENT_STORY_WAS_SET:r$1,DOCS_PREPARED:D$2,DOCS_RENDERED:I$3,FILE_COMPONENT_SEARCH_REQUEST:C$3,FILE_COMPONENT_SEARCH_RESPONSE:o$2,FORCE_REMOUNT:L$1,FORCE_RE_RENDER:P$2,GLOBALS_UPDATED:a$2,NAVIGATE_URL:Y$1,PLAY_FUNCTION_THREW_EXCEPTION:U$2,PRELOAD_ENTRIES:W$2,PREVIEW_BUILDER_PROGRESS:H$2,PREVIEW_KEYDOWN:d,REGISTER_SUBSCRIPTION:t$1,REQUEST_WHATS_NEW_DATA:J$3,RESET_STORY_ARGS:p$2,RESULT_WHATS_NEW_DATA:Z,SAVE_STORY_REQUEST:EE,SAVE_STORY_RESPONSE:RE,SELECT_STORY:i$1,SET_CONFIG:l$1$1,SET_CURRENT_STORY:F$2,SET_FILTER:e,SET_GLOBALS:y,SET_INDEX:c,SET_STORIES:h$1,SET_WHATS_NEW_CACHE:$$3,SHARED_STATE_CHANGED:f$2,SHARED_STATE_SET:g,STORIES_COLLAPSE_ALL:u$1,STORIES_EXPAND_ALL:s,STORY_ARGS_UPDATED:x$3,STORY_CHANGED:M$3,STORY_ERRORED:Q,STORY_INDEX_INVALIDATED:m$1,STORY_MISSING:V$2,STORY_PREPARED:w$2,STORY_RENDERED:X$1,STORY_RENDER_PHASE_CHANGED:B$2,STORY_SPECIFIED:b$2,STORY_THREW_EXCEPTION:q$2,STORY_UNCHANGED:K$1,TELEMETRY_ERROR:v$2,TOGGLE_WHATS_NEW_NOTIFICATIONS:n,UNHANDLED_ERRORS_WHILE_PLAYING:G$4,UPDATE_GLOBALS:j$1,UPDATE_QUERY_PARAMS:k$4,UPDATE_STORY_ARGS:z$4,default:S$2},Symbol.toStringTag,{value:"Module"}));var Qt=Object.create,st=Object.defineProperty,te$1=Object.getOwnPropertyDescriptor,ee=Object.getOwnPropertyNames,re$1=Object.getPrototypeOf,ne$1=Object.prototype.hasOwnProperty,i$3=(it,ct)=>st(it,"name",{value:ct,configurable:!0}),U$1=(it=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(it,{get:(ct,Ot)=>(typeof require<"u"?require:ct)[Ot]}):it)(function(it){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+it+'" is not supported')}),oe$2=(it,ct)=>()=>(ct||it((ct={exports:{}}).exports,ct),ct.exports),ae=(it,ct,Ot,qt)=>{if(ct&&typeof ct=="object"||typeof ct=="function")for(let Zn of ee(ct))!ne$1.call(it,Zn)&&Zn!==Ot&&st(it,Zn,{get:()=>ct[Zn],enumerable:!(qt=te$1(ct,Zn))||qt.enumerable});return it},ie=(it,ct,Ot)=>(Ot=it!=null?Qt(re$1(it)):{},ae(st(Ot,"default",{value:it,enumerable:!0}),it)),At=oe$2((it,ct)=>{(function(Ot){if(typeof it=="object"&&typeof ct<"u")ct.exports=Ot();else if(typeof define=="function"&&define.amd)define([],Ot);else{var qt;typeof window<"u"?qt=window:typeof global<"u"?qt=global:typeof self<"u"?qt=self:qt=this,qt.memoizerific=Ot()}})(function(){return i$3(function Ot(qt,Zn,no){function oo(so,lo){if(!Zn[so]){if(!qt[so]){var co=typeof U$1=="function"&&U$1;if(!lo&&co)return co(so,!0);if(io)return io(so,!0);var uo=new Error("Cannot find module '"+so+"'");throw uo.code="MODULE_NOT_FOUND",uo}var po=Zn[so]={exports:{}};qt[so][0].call(po.exports,function(fo){var mo=qt[so][1][fo];return oo(mo||fo)},po,po.exports,Ot,qt,Zn,no)}return Zn[so].exports}i$3(oo,"s");for(var io=typeof U$1=="function"&&U$1,ao=0;ao<no.length;ao++)oo(no[ao]);return oo},"e")({1:[function(Ot,qt,Zn){qt.exports=function(no){if(typeof Map!="function"||no){var oo=Ot("./similar");return new oo}else return new Map}},{"./similar":2}],2:[function(Ot,qt,Zn){function no(){return this.list=[],this.lastItem=void 0,this.size=0,this}i$3(no,"Similar"),no.prototype.get=function(oo){var io;if(this.lastItem&&this.isEqual(this.lastItem.key,oo))return this.lastItem.val;if(io=this.indexOf(oo),io>=0)return this.lastItem=this.list[io],this.list[io].val},no.prototype.set=function(oo,io){var ao;return this.lastItem&&this.isEqual(this.lastItem.key,oo)?(this.lastItem.val=io,this):(ao=this.indexOf(oo),ao>=0?(this.lastItem=this.list[ao],this.list[ao].val=io,this):(this.lastItem={key:oo,val:io},this.list.push(this.lastItem),this.size++,this))},no.prototype.delete=function(oo){var io;if(this.lastItem&&this.isEqual(this.lastItem.key,oo)&&(this.lastItem=void 0),io=this.indexOf(oo),io>=0)return this.size--,this.list.splice(io,1)[0]},no.prototype.has=function(oo){var io;return this.lastItem&&this.isEqual(this.lastItem.key,oo)?!0:(io=this.indexOf(oo),io>=0?(this.lastItem=this.list[io],!0):!1)},no.prototype.forEach=function(oo,io){var ao;for(ao=0;ao<this.size;ao++)oo.call(io||this,this.list[ao].val,this.list[ao].key,this)},no.prototype.indexOf=function(oo){var io;for(io=0;io<this.size;io++)if(this.isEqual(this.list[io].key,oo))return io;return-1},no.prototype.isEqual=function(oo,io){return oo===io||oo!==oo&&io!==io},qt.exports=no},{}],3:[function(Ot,qt,Zn){var no=Ot("map-or-similar");qt.exports=function(so){var lo=new no(!1),co=[];return function(uo){var po=i$3(function(){var fo=lo,mo,So,ho=arguments.length-1,yo=Array(ho+1),go=!0,vo;if((po.numArgs||po.numArgs===0)&&po.numArgs!==ho+1)throw new Error("Memoizerific functions should always be called with the same number of arguments");for(vo=0;vo<ho;vo++){if(yo[vo]={cacheItem:fo,arg:arguments[vo]},fo.has(arguments[vo])){fo=fo.get(arguments[vo]);continue}go=!1,mo=new no(!1),fo.set(arguments[vo],mo),fo=mo}return go&&(fo.has(arguments[ho])?So=fo.get(arguments[ho]):go=!1),go||(So=uo.apply(null,arguments),fo.set(arguments[ho],So)),so>0&&(yo[ho]={cacheItem:fo,arg:arguments[ho]},go?oo(co,yo):co.push(yo),co.length>so&&io(co.shift())),po.wasMemoized=go,po.numArgs=ho+1,So},"memoizerific");return po.limit=so,po.wasMemoized=!1,po.cache=lo,po.lru=co,po}};function oo(so,lo){var co=so.length,uo=lo.length,po,fo,mo;for(fo=0;fo<co;fo++){for(po=!0,mo=0;mo<uo;mo++)if(!ao(so[fo][mo].arg,lo[mo].arg)){po=!1;break}if(po)break}so.push(so.splice(fo,1)[0])}i$3(oo,"moveToMostRecentLru");function io(so){var lo=so.length,co=so[lo-1],uo,po;for(co.cacheItem.delete(co.arg),po=lo-2;po>=0&&(co=so[po],uo=co.cacheItem.get(co.arg),!uo||!uo.size);po--)co.cacheItem.delete(co.arg)}i$3(io,"removeCachedResult");function ao(so,lo){return so===lo||so!==so&&lo!==lo}i$3(ao,"isEqual")},{"map-or-similar":1}]},{},[3])(3)})}),b$1=(()=>{let it;return typeof window<"u"?it=window:typeof globalThis<"u"?it=globalThis:typeof global<"u"?it=global:typeof self<"u"?it=self:it={},it})(),se=i$3(it=>it.transports!==void 0,"isMulti"),le=i$3(()=>Math.random().toString(16).slice(2),"generateRandomId"),lt=class{constructor(it={}){this.sender=le(),this.events={},this.data={},this.transports=[],this.isAsync=it.async||!1,se(it)?(this.transports=it.transports||[],this.transports.forEach(ct=>{ct.setHandler(Ot=>this.handleEvent(Ot))})):this.transports=it.transport?[it.transport]:[],this.transports.forEach(ct=>{ct.setHandler(Ot=>this.handleEvent(Ot))})}get hasTransport(){return this.transports.length>0}addListener(it,ct){this.events[it]=this.events[it]||[],this.events[it].push(ct)}emit(it,...ct){let Ot={type:it,args:ct,from:this.sender},qt={};ct.length>=1&&ct[0]&&ct[0].options&&(qt=ct[0].options);let Zn=i$3(()=>{this.transports.forEach(no=>{no.send(Ot,qt)}),this.handleEvent(Ot)},"handler");this.isAsync?setImmediate(Zn):Zn()}last(it){return this.data[it]}eventNames(){return Object.keys(this.events)}listenerCount(it){let ct=this.listeners(it);return ct?ct.length:0}listeners(it){return this.events[it]||void 0}once(it,ct){let Ot=this.onceListener(it,ct);this.addListener(it,Ot)}removeAllListeners(it){it?this.events[it]&&delete this.events[it]:this.events={}}removeListener(it,ct){let Ot=this.listeners(it);Ot&&(this.events[it]=Ot.filter(qt=>qt!==ct))}on(it,ct){this.addListener(it,ct)}off(it,ct){this.removeListener(it,ct)}handleEvent(it){let ct=this.listeners(it.type);ct&&ct.length&&ct.forEach(Ot=>{Ot.apply(it,it.args)}),this.data[it.type]=it.args}onceListener(it,ct){let Ot=i$3((...qt)=>(this.removeListener(it,Ot),ct(...qt)),"onceListener");return Ot}};i$3(lt,"Channel");var z$3=lt,ce=Object.create,St$1=Object.defineProperty,fe=Object.getOwnPropertyDescriptor,wt$1=Object.getOwnPropertyNames,ue$1=Object.getPrototypeOf,pe$1=Object.prototype.hasOwnProperty,x$2=i$3((it,ct)=>i$3(function(){return ct||(0,it[wt$1(it)[0]])((ct={exports:{}}).exports,ct),ct.exports},"__require"),"__commonJS"),ye$1=i$3((it,ct,Ot,qt)=>{if(ct&&typeof ct=="object"||typeof ct=="function")for(let Zn of wt$1(ct))!pe$1.call(it,Zn)&&Zn!==Ot&&St$1(it,Zn,{get:i$3(()=>ct[Zn],"get"),enumerable:!(qt=fe(ct,Zn))||qt.enumerable});return it},"__copyProps"),tt$1=i$3((it,ct,Ot)=>(Ot=it!=null?ce(ue$1(it)):{},ye$1(ct||!it||!it.__esModule?St$1(Ot,"default",{value:it,enumerable:!0}):Ot,it)),"__toESM"),de$1=["bubbles","cancelBubble","cancelable","composed","currentTarget","defaultPrevented","eventPhase","isTrusted","returnValue","srcElement","target","timeStamp","type"],he$1=["detail"];function Et(it){let ct=de$1.filter(Ot=>it[Ot]!==void 0).reduce((Ot,qt)=>({...Ot,[qt]:it[qt]}),{});return it instanceof CustomEvent&&he$1.filter(Ot=>it[Ot]!==void 0).forEach(Ot=>{ct[Ot]=it[Ot]}),ct}i$3(Et,"extractEventHiddenProperties");var Ut$1=ie(At()),Tt$1=x$2({"node_modules/has-symbols/shams.js"(it,ct){ct.exports=i$3(function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var Ot={},qt=Symbol("test"),Zn=Object(qt);if(typeof qt=="string"||Object.prototype.toString.call(qt)!=="[object Symbol]"||Object.prototype.toString.call(Zn)!=="[object Symbol]")return!1;var no=42;Ot[qt]=no;for(qt in Ot)return!1;if(typeof Object.keys=="function"&&Object.keys(Ot).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(Ot).length!==0)return!1;var oo=Object.getOwnPropertySymbols(Ot);if(oo.length!==1||oo[0]!==qt||!Object.prototype.propertyIsEnumerable.call(Ot,qt))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var io=Object.getOwnPropertyDescriptor(Ot,qt);if(io.value!==no||io.enumerable!==!0)return!1}return!0},"hasSymbols")}}),Ft=x$2({"node_modules/has-symbols/index.js"(it,ct){var Ot=typeof Symbol<"u"&&Symbol,qt=Tt$1();ct.exports=i$3(function(){return typeof Ot!="function"||typeof Symbol!="function"||typeof Ot("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:qt()},"hasNativeSymbols")}}),ge$1=x$2({"node_modules/function-bind/implementation.js"(it,ct){var Ot="Function.prototype.bind called on incompatible ",qt=Array.prototype.slice,Zn=Object.prototype.toString,no="[object Function]";ct.exports=i$3(function(oo){var io=this;if(typeof io!="function"||Zn.call(io)!==no)throw new TypeError(Ot+io);for(var ao=qt.call(arguments,1),so,lo=i$3(function(){if(this instanceof so){var mo=io.apply(this,ao.concat(qt.call(arguments)));return Object(mo)===mo?mo:this}else return io.apply(oo,ao.concat(qt.call(arguments)))},"binder"),co=Math.max(0,io.length-ao.length),uo=[],po=0;po<co;po++)uo.push("$"+po);if(so=Function("binder","return function ("+uo.join(",")+"){ return binder.apply(this,arguments); }")(lo),io.prototype){var fo=i$3(function(){},"Empty2");fo.prototype=io.prototype,so.prototype=new fo,fo.prototype=null}return so},"bind")}}),ut$1=x$2({"node_modules/function-bind/index.js"(it,ct){var Ot=ge$1();ct.exports=Function.prototype.bind||Ot}}),me$1=x$2({"node_modules/has/src/index.js"(it,ct){var Ot=ut$1();ct.exports=Ot.call(Function.call,Object.prototype.hasOwnProperty)}}),Nt$1=x$2({"node_modules/get-intrinsic/index.js"(it,ct){var Ot,qt=SyntaxError,Zn=Function,no=TypeError,oo=i$3(function(Ko){try{return Zn('"use strict"; return ('+Ko+").constructor;")()}catch{}},"getEvalledConstructor"),io=Object.getOwnPropertyDescriptor;if(io)try{io({},"")}catch{io=null}var ao=i$3(function(){throw new no},"throwTypeError"),so=io?function(){try{return arguments.callee,ao}catch{try{return io(arguments,"callee").get}catch{return ao}}}():ao,lo=Ft()(),co=Object.getPrototypeOf||function(Ko){return Ko.__proto__},uo={},po=typeof Uint8Array>"u"?Ot:co(Uint8Array),fo={"%AggregateError%":typeof AggregateError>"u"?Ot:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?Ot:ArrayBuffer,"%ArrayIteratorPrototype%":lo?co([][Symbol.iterator]()):Ot,"%AsyncFromSyncIteratorPrototype%":Ot,"%AsyncFunction%":uo,"%AsyncGenerator%":uo,"%AsyncGeneratorFunction%":uo,"%AsyncIteratorPrototype%":uo,"%Atomics%":typeof Atomics>"u"?Ot:Atomics,"%BigInt%":typeof BigInt>"u"?Ot:BigInt,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?Ot:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":typeof Float32Array>"u"?Ot:Float32Array,"%Float64Array%":typeof Float64Array>"u"?Ot:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?Ot:FinalizationRegistry,"%Function%":Zn,"%GeneratorFunction%":uo,"%Int8Array%":typeof Int8Array>"u"?Ot:Int8Array,"%Int16Array%":typeof Int16Array>"u"?Ot:Int16Array,"%Int32Array%":typeof Int32Array>"u"?Ot:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":lo?co(co([][Symbol.iterator]())):Ot,"%JSON%":typeof JSON=="object"?JSON:Ot,"%Map%":typeof Map>"u"?Ot:Map,"%MapIteratorPrototype%":typeof Map>"u"||!lo?Ot:co(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?Ot:Promise,"%Proxy%":typeof Proxy>"u"?Ot:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":typeof Reflect>"u"?Ot:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?Ot:Set,"%SetIteratorPrototype%":typeof Set>"u"||!lo?Ot:co(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?Ot:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":lo?co(""[Symbol.iterator]()):Ot,"%Symbol%":lo?Symbol:Ot,"%SyntaxError%":qt,"%ThrowTypeError%":so,"%TypedArray%":po,"%TypeError%":no,"%Uint8Array%":typeof Uint8Array>"u"?Ot:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?Ot:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?Ot:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?Ot:Uint32Array,"%URIError%":URIError,"%WeakMap%":typeof WeakMap>"u"?Ot:WeakMap,"%WeakRef%":typeof WeakRef>"u"?Ot:WeakRef,"%WeakSet%":typeof WeakSet>"u"?Ot:WeakSet},mo=i$3(function Ko(zo){var bo;if(zo==="%AsyncFunction%")bo=oo("async function () {}");else if(zo==="%GeneratorFunction%")bo=oo("function* () {}");else if(zo==="%AsyncGeneratorFunction%")bo=oo("async function* () {}");else if(zo==="%AsyncGenerator%"){var Io=Ko("%AsyncGeneratorFunction%");Io&&(bo=Io.prototype)}else if(zo==="%AsyncIteratorPrototype%"){var Qo=Ko("%AsyncGenerator%");Qo&&(bo=co(Qo.prototype))}return fo[zo]=bo,bo},"doEval2"),So={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},ho=ut$1(),yo=me$1(),go=ho.call(Function.call,Array.prototype.concat),vo=ho.call(Function.apply,Array.prototype.splice),xo=ho.call(Function.call,String.prototype.replace),Vo=ho.call(Function.call,String.prototype.slice),ti=ho.call(Function.call,RegExp.prototype.exec),ni=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,No=/\\(\\)?/g,ko=i$3(function(Ko){var zo=Vo(Ko,0,1),bo=Vo(Ko,-1);if(zo==="%"&&bo!=="%")throw new qt("invalid intrinsic syntax, expected closing `%`");if(bo==="%"&&zo!=="%")throw new qt("invalid intrinsic syntax, expected opening `%`");var Io=[];return xo(Ko,ni,function(Qo,Zo,ui,ai){Io[Io.length]=ui?xo(ai,No,"$1"):Zo||Qo}),Io},"stringToPath3"),wo=i$3(function(Ko,zo){var bo=Ko,Io;if(yo(So,bo)&&(Io=So[bo],bo="%"+Io[0]+"%"),yo(fo,bo)){var Qo=fo[bo];if(Qo===uo&&(Qo=mo(bo)),typeof Qo>"u"&&!zo)throw new no("intrinsic "+Ko+" exists, but is not available. Please file an issue!");return{alias:Io,name:bo,value:Qo}}throw new qt("intrinsic "+Ko+" does not exist!")},"getBaseIntrinsic2");ct.exports=i$3(function(Ko,zo){if(typeof Ko!="string"||Ko.length===0)throw new no("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof zo!="boolean")throw new no('"allowMissing" argument must be a boolean');if(ti(/^%?[^%]*%?$/,Ko)===null)throw new qt("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var bo=ko(Ko),Io=bo.length>0?bo[0]:"",Qo=wo("%"+Io+"%",zo),Zo=Qo.name,ui=Qo.value,ai=!1,si=Qo.alias;si&&(Io=si[0],vo(bo,go([0,1],si)));for(var di=1,Fo=!0;di<bo.length;di+=1){var oi=bo[di],ei=Vo(oi,0,1),ri=Vo(oi,-1);if((ei==='"'||ei==="'"||ei==="`"||ri==='"'||ri==="'"||ri==="`")&&ei!==ri)throw new qt("property names with quotes must have matching quotes");if((oi==="constructor"||!Fo)&&(ai=!0),Io+="."+oi,Zo="%"+Io+"%",yo(fo,Zo))ui=fo[Zo];else if(ui!=null){if(!(oi in ui)){if(!zo)throw new no("base intrinsic for "+Ko+" exists, but the property is not available.");return}if(io&&di+1>=bo.length){var ci=io(ui,oi);Fo=!!ci,Fo&&"get"in ci&&!("originalValue"in ci.get)?ui=ci.get:ui=ui[oi]}else Fo=yo(ui,oi),ui=ui[oi];Fo&&!ai&&(fo[Zo]=ui)}}return ui},"GetIntrinsic")}}),ve$1=x$2({"node_modules/call-bind/index.js"(it,ct){var Ot=ut$1(),qt=Nt$1(),Zn=qt("%Function.prototype.apply%"),no=qt("%Function.prototype.call%"),oo=qt("%Reflect.apply%",!0)||Ot.call(no,Zn),io=qt("%Object.getOwnPropertyDescriptor%",!0),ao=qt("%Object.defineProperty%",!0),so=qt("%Math.max%");if(ao)try{ao({},"a",{value:1})}catch{ao=null}ct.exports=i$3(function(co){var uo=oo(Ot,no,arguments);if(io&&ao){var po=io(uo,"length");po.configurable&&ao(uo,"length",{value:1+so(0,co.length-(arguments.length-1))})}return uo},"callBind");var lo=i$3(function(){return oo(Ot,Zn,arguments)},"applyBind2");ao?ao(ct.exports,"apply",{value:lo}):ct.exports.apply=lo}}),_e=x$2({"node_modules/call-bind/callBound.js"(it,ct){var Ot=Nt$1(),qt=ve$1(),Zn=qt(Ot("String.prototype.indexOf"));ct.exports=i$3(function(no,oo){var io=Ot(no,!!oo);return typeof io=="function"&&Zn(no,".prototype.")>-1?qt(io):io},"callBoundIntrinsic")}}),be=x$2({"node_modules/has-tostringtag/shams.js"(it,ct){var Ot=Tt$1();ct.exports=i$3(function(){return Ot()&&!!Symbol.toStringTag},"hasToStringTagShams")}}),Se=x$2({"node_modules/is-regex/index.js"(it,ct){var Ot=_e(),qt=be()(),Zn,no,oo,io;qt&&(Zn=Ot("Object.prototype.hasOwnProperty"),no=Ot("RegExp.prototype.exec"),oo={},ao=i$3(function(){throw oo},"throwRegexMarker"),io={toString:ao,valueOf:ao},typeof Symbol.toPrimitive=="symbol"&&(io[Symbol.toPrimitive]=ao));var ao,so=Ot("Object.prototype.toString"),lo=Object.getOwnPropertyDescriptor,co="[object RegExp]";ct.exports=i$3(qt?function(uo){if(!uo||typeof uo!="object")return!1;var po=lo(uo,"lastIndex"),fo=po&&Zn(po,"value");if(!fo)return!1;try{no(uo,io)}catch(mo){return mo===oo}}:function(uo){return!uo||typeof uo!="object"&&typeof uo!="function"?!1:so(uo)===co},"isRegex")}}),we=x$2({"node_modules/is-function/index.js"(it,ct){ct.exports=qt;var Ot=Object.prototype.toString;function qt(Zn){if(!Zn)return!1;var no=Ot.call(Zn);return no==="[object Function]"||typeof Zn=="function"&&no!=="[object RegExp]"||typeof window<"u"&&(Zn===window.setTimeout||Zn===window.alert||Zn===window.confirm||Zn===window.prompt)}i$3(qt,"isFunction3")}}),Ee$1=x$2({"node_modules/is-symbol/index.js"(it,ct){var Ot=Object.prototype.toString,qt=Ft()();qt?(Zn=Symbol.prototype.toString,no=/^Symbol\(.*\)$/,oo=i$3(function(io){return typeof io.valueOf()!="symbol"?!1:no.test(Zn.call(io))},"isRealSymbolObject"),ct.exports=i$3(function(io){if(typeof io=="symbol")return!0;if(Ot.call(io)!=="[object Symbol]")return!1;try{return oo(io)}catch{return!1}},"isSymbol3")):ct.exports=i$3(function(io){return!1},"isSymbol3");var Zn,no,oo}}),Oe=tt$1(Se()),Ae$1=tt$1(we()),Pe=tt$1(Ee$1());function xe$1(it){return it!=null&&typeof it=="object"&&Array.isArray(it)===!1}i$3(xe$1,"isObject");var Ce=typeof global=="object"&&global&&global.Object===Object&&global,Ie=Ce,je$1=typeof self=="object"&&self&&self.Object===Object&&self,Te=Ie||je$1||Function("return this")(),pt=Te,Fe=pt.Symbol,M$2=Fe,Rt=Object.prototype,Ne$1=Rt.hasOwnProperty,Re=Rt.toString,W$1=M$2?M$2.toStringTag:void 0;function Me$1(it){var ct=Ne$1.call(it,W$1),Ot=it[W$1];try{it[W$1]=void 0;var qt=!0}catch{}var Zn=Re.call(it);return qt&&(ct?it[W$1]=Ot:delete it[W$1]),Zn}i$3(Me$1,"getRawTag");var $e=Me$1,ke$1=Object.prototype,De$1=ke$1.toString;function Le$1(it){return De$1.call(it)}i$3(Le$1,"objectToString");var Ue$1=Le$1,ze="[object Null]",We="[object Undefined]",Pt=M$2?M$2.toStringTag:void 0;function Be$1(it){return it==null?it===void 0?We:ze:Pt&&Pt in Object(it)?$e(it):Ue$1(it)}i$3(Be$1,"baseGetTag");var Mt$1=Be$1;function He(it){return it!=null&&typeof it=="object"}i$3(He,"isObjectLike");var qe=He,Ge$1="[object Symbol]";function Je$1(it){return typeof it=="symbol"||qe(it)&&Mt$1(it)==Ge$1}i$3(Je$1,"isSymbol");var yt=Je$1;function Ve(it,ct){for(var Ot=-1,qt=it==null?0:it.length,Zn=Array(qt);++Ot<qt;)Zn[Ot]=ct(it[Ot],Ot,it);return Zn}i$3(Ve,"arrayMap");var Ke=Ve,Ye=Array.isArray,dt=Ye,Ze=1/0,xt=M$2?M$2.prototype:void 0,Ct=xt?xt.toString:void 0;function $t(it){if(typeof it=="string")return it;if(dt(it))return Ke(it,$t)+"";if(yt(it))return Ct?Ct.call(it):"";var ct=it+"";return ct=="0"&&1/it==-Ze?"-0":ct}i$3($t,"baseToString");var Xe=$t;function Qe$1(it){var ct=typeof it;return it!=null&&(ct=="object"||ct=="function")}i$3(Qe$1,"isObject2");var kt$1=Qe$1,tr$1="[object AsyncFunction]",er$1="[object Function]",rr="[object GeneratorFunction]",nr="[object Proxy]";function or(it){if(!kt$1(it))return!1;var ct=Mt$1(it);return ct==er$1||ct==rr||ct==tr$1||ct==nr}i$3(or,"isFunction");var ar=or,ir=pt["__core-js_shared__"],ft=ir,It$1=function(){var it=/[^.]+$/.exec(ft&&ft.keys&&ft.keys.IE_PROTO||"");return it?"Symbol(src)_1."+it:""}();function sr$1(it){return!!It$1&&It$1 in it}i$3(sr$1,"isMasked");var lr$1=sr$1,cr$1=Function.prototype,fr$1=cr$1.toString;function ur$1(it){if(it!=null){try{return fr$1.call(it)}catch{}try{return it+""}catch{}}return""}i$3(ur$1,"toSource");var pr$1=ur$1,yr$1=/[\\^$.*+?()[\]{}|]/g,dr$1=/^\[object .+?Constructor\]$/,hr$1=Function.prototype,gr$1=Object.prototype,mr$1=hr$1.toString,vr$1=gr$1.hasOwnProperty,_r$1=RegExp("^"+mr$1.call(vr$1).replace(yr$1,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function br$1(it){if(!kt$1(it)||lr$1(it))return!1;var ct=ar(it)?_r$1:dr$1;return ct.test(pr$1(it))}i$3(br$1,"baseIsNative");var Sr$1=br$1;function wr$1(it,ct){return it==null?void 0:it[ct]}i$3(wr$1,"getValue");var Er=wr$1;function Or(it,ct){var Ot=Er(it,ct);return Sr$1(Ot)?Ot:void 0}i$3(Or,"getNative");var Dt$1=Or;function Ar(it,ct){return it===ct||it!==it&&ct!==ct}i$3(Ar,"eq");var Pr=Ar,xr$1=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Cr=/^\w*$/;function Ir(it,ct){if(dt(it))return!1;var Ot=typeof it;return Ot=="number"||Ot=="symbol"||Ot=="boolean"||it==null||yt(it)?!0:Cr.test(it)||!xr$1.test(it)||ct!=null&&it in Object(ct)}i$3(Ir,"isKey");var jr$1=Ir,Tr$1=Dt$1(Object,"create"),B$1=Tr$1;function Fr$1(){this.__data__=B$1?B$1(null):{},this.size=0}i$3(Fr$1,"hashClear");var Nr$1=Fr$1;function Rr(it){var ct=this.has(it)&&delete this.__data__[it];return this.size-=ct?1:0,ct}i$3(Rr,"hashDelete");var Mr$1=Rr,$r$1="__lodash_hash_undefined__",kr$1=Object.prototype,Dr$1=kr$1.hasOwnProperty;function Lr$1(it){var ct=this.__data__;if(B$1){var Ot=ct[it];return Ot===$r$1?void 0:Ot}return Dr$1.call(ct,it)?ct[it]:void 0}i$3(Lr$1,"hashGet");var Ur$1=Lr$1,zr$1=Object.prototype,Wr$1=zr$1.hasOwnProperty;function Br(it){var ct=this.__data__;return B$1?ct[it]!==void 0:Wr$1.call(ct,it)}i$3(Br,"hashHas");var Hr=Br,qr$1="__lodash_hash_undefined__";function Gr$1(it,ct){var Ot=this.__data__;return this.size+=this.has(it)?0:1,Ot[it]=B$1&&ct===void 0?qr$1:ct,this}i$3(Gr$1,"hashSet");var Jr$1=Gr$1;function $$2(it){var ct=-1,Ot=it==null?0:it.length;for(this.clear();++ct<Ot;){var qt=it[ct];this.set(qt[0],qt[1])}}i$3($$2,"Hash");$$2.prototype.clear=Nr$1;$$2.prototype.delete=Mr$1;$$2.prototype.get=Ur$1;$$2.prototype.has=Hr;$$2.prototype.set=Jr$1;var jt$1=$$2;function Vr$1(){this.__data__=[],this.size=0}i$3(Vr$1,"listCacheClear");var Kr$1=Vr$1;function Yr$1(it,ct){for(var Ot=it.length;Ot--;)if(Pr(it[Ot][0],ct))return Ot;return-1}i$3(Yr$1,"assocIndexOf");var rt$1=Yr$1,Zr$1=Array.prototype,Xr$1=Zr$1.splice;function Qr$1(it){var ct=this.__data__,Ot=rt$1(ct,it);if(Ot<0)return!1;var qt=ct.length-1;return Ot==qt?ct.pop():Xr$1.call(ct,Ot,1),--this.size,!0}i$3(Qr$1,"listCacheDelete");var tn$1=Qr$1;function en$1(it){var ct=this.__data__,Ot=rt$1(ct,it);return Ot<0?void 0:ct[Ot][1]}i$3(en$1,"listCacheGet");var rn$1=en$1;function nn$1(it){return rt$1(this.__data__,it)>-1}i$3(nn$1,"listCacheHas");var on$1=nn$1;function an(it,ct){var Ot=this.__data__,qt=rt$1(Ot,it);return qt<0?(++this.size,Ot.push([it,ct])):Ot[qt][1]=ct,this}i$3(an,"listCacheSet");var sn$1=an;function k$3(it){var ct=-1,Ot=it==null?0:it.length;for(this.clear();++ct<Ot;){var qt=it[ct];this.set(qt[0],qt[1])}}i$3(k$3,"ListCache");k$3.prototype.clear=Kr$1;k$3.prototype.delete=tn$1;k$3.prototype.get=rn$1;k$3.prototype.has=on$1;k$3.prototype.set=sn$1;var ln$1=k$3,cn$1=Dt$1(pt,"Map"),fn=cn$1;function un(){this.size=0,this.__data__={hash:new jt$1,map:new(fn||ln$1),string:new jt$1}}i$3(un,"mapCacheClear");var pn=un;function yn(it){var ct=typeof it;return ct=="string"||ct=="number"||ct=="symbol"||ct=="boolean"?it!=="__proto__":it===null}i$3(yn,"isKeyable");var dn=yn;function hn(it,ct){var Ot=it.__data__;return dn(ct)?Ot[typeof ct=="string"?"string":"hash"]:Ot.map}i$3(hn,"getMapData");var nt$1=hn;function gn$1(it){var ct=nt$1(this,it).delete(it);return this.size-=ct?1:0,ct}i$3(gn$1,"mapCacheDelete");var mn$1=gn$1;function vn$1(it){return nt$1(this,it).get(it)}i$3(vn$1,"mapCacheGet");var _n$1=vn$1;function bn$1(it){return nt$1(this,it).has(it)}i$3(bn$1,"mapCacheHas");var Sn=bn$1;function wn$1(it,ct){var Ot=nt$1(this,it),qt=Ot.size;return Ot.set(it,ct),this.size+=Ot.size==qt?0:1,this}i$3(wn$1,"mapCacheSet");var En$1=wn$1;function D$1(it){var ct=-1,Ot=it==null?0:it.length;for(this.clear();++ct<Ot;){var qt=it[ct];this.set(qt[0],qt[1])}}i$3(D$1,"MapCache");D$1.prototype.clear=pn;D$1.prototype.delete=mn$1;D$1.prototype.get=_n$1;D$1.prototype.has=Sn;D$1.prototype.set=En$1;var Lt$1=D$1,On$1="Expected a function";function ht(it,ct){if(typeof it!="function"||ct!=null&&typeof ct!="function")throw new TypeError(On$1);var Ot=i$3(function(){var qt=arguments,Zn=ct?ct.apply(this,qt):qt[0],no=Ot.cache;if(no.has(Zn))return no.get(Zn);var oo=it.apply(this,qt);return Ot.cache=no.set(Zn,oo)||no,oo},"memoized");return Ot.cache=new(ht.Cache||Lt$1),Ot}i$3(ht,"memoize");ht.Cache=Lt$1;var An=ht,Pn$1=500;function xn$1(it){var ct=An(it,function(qt){return Ot.size===Pn$1&&Ot.clear(),qt}),Ot=ct.cache;return ct}i$3(xn$1,"memoizeCapped");var Cn=xn$1,In$1=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,jn$1=/\\(\\)?/g,Tn$1=Cn(function(it){var ct=[];return it.charCodeAt(0)===46&&ct.push(""),it.replace(In$1,function(Ot,qt,Zn,no){ct.push(Zn?no.replace(jn$1,"$1"):qt||Ot)}),ct}),Fn$1=Tn$1;function Nn$1(it){return it==null?"":Xe(it)}i$3(Nn$1,"toString");var Rn$1=Nn$1;function Mn$1(it,ct){return dt(it)?it:jr$1(it,ct)?[it]:Fn$1(Rn$1(it))}i$3(Mn$1,"castPath");var $n$1=Mn$1,kn$1=1/0;function Dn$1(it){if(typeof it=="string"||yt(it))return it;var ct=it+"";return ct=="0"&&1/it==-kn$1?"-0":ct}i$3(Dn$1,"toKey");var Ln$1=Dn$1;function Un$1(it,ct){ct=$n$1(ct,it);for(var Ot=0,qt=ct.length;it!=null&&Ot<qt;)it=it[Ln$1(ct[Ot++])];return Ot&&Ot==qt?it:void 0}i$3(Un$1,"baseGet");var zn$1=Un$1;function Wn$1(it,ct,Ot){var qt=it==null?void 0:zn$1(it,ct);return qt===void 0?Ot:qt}i$3(Wn$1,"get");var Bn$1=Wn$1,et$1=xe$1,Hn$1=i$3(it=>{let ct=null,Ot=!1,qt=!1,Zn=!1,no="";if(it.indexOf("//")>=0||it.indexOf("/*")>=0)for(let oo=0;oo<it.length;oo+=1)!ct&&!Ot&&!qt&&!Zn?it[oo]==='"'||it[oo]==="'"||it[oo]==="`"?ct=it[oo]:it[oo]==="/"&&it[oo+1]==="*"?Ot=!0:it[oo]==="/"&&it[oo+1]==="/"?qt=!0:it[oo]==="/"&&it[oo+1]!=="/"&&(Zn=!0):(ct&&(it[oo]===ct&&it[oo-1]!=="\\"||it[oo]===`
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index-T6Et30Eh-B1ytNt1O.js","assets/main.9ezbfd1a.js","assets/main-Bfrdc6YH.css","assets/index-CnxM4IIa-CoekJPsT.js","assets/index-Dc3srWFp-DVPU56zP.js","assets/visitor-jgO2GXVr-DtE61rfq.js","assets/index-6e_WqBNj-CJvJXHul.js","assets/index-8PbnK2go-BoR1WEku.js","assets/_commonjs-dynamic-modules-BpilXLfW-DfYEAvWy.js","assets/typescript-e2Impz-Y-eyfqYqVi.js","assets/editor-Cxi1Bi4m.js","assets/editor-NPbexOjM.js","assets/editor-Bat08LEU.js","assets/editor-CIbZp8-c.js"])))=>i.map(i=>d[i]);
2
+ import{J as J$4,_ as __vitePreload,Z as Ze$1,ar as f$3,d as jsxRuntimeExports,r as reactExports,i as index,as as yx,at as actions}from"./main.9ezbfd1a.js";var a$3={};Object.defineProperty(a$3,"__esModule",{value:!0});var P$3=a$3.lazyWithPreload=void 0,r$3=J$4;function i$4(it){var ct=(0,r$3.lazy)(it),Ot,qt,Zn=(0,r$3.forwardRef)(function(oo,io){var ao=(0,r$3.useRef)(Ot??ct);return(0,r$3.createElement)(ao.current,Object.assign(io?{ref:io}:{},oo))}),no=Zn;return no.preload=function(){return qt||(qt=it().then(function(oo){return Ot=oo.default,Ot})),qt},no}P$3=a$3.lazyWithPreload=i$4;a$3.default=i$4;function _mergeNamespaces(it,ct){for(var Ot=0;Ot<ct.length;Ot++){const qt=ct[Ot];if(typeof qt!="string"&&!Array.isArray(qt)){for(const Zn in qt)if(Zn!=="default"&&!(Zn in it)){const no=Object.getOwnPropertyDescriptor(qt,Zn);no&&Object.defineProperty(it,Zn,no.get?no:{enumerable:!0,get:()=>qt[Zn]})}}}return Object.freeze(Object.defineProperty(it,Symbol.toStringTag,{value:"Module"}))}function DocumentEditor(it){const ct=["document-editor",`${it.mode}-mode`];return jsxRuntimeExports.jsx("div",{className:ct.join(" "),children:it.children})}function EditorToolbar(it){const ct=it.left||[],Ot=it.center||[],qt=it.right||[];return jsxRuntimeExports.jsxs("div",{className:"editor-toolbar",children:[jsxRuntimeExports.jsx("div",{className:"editor-toolbar--column editor-toolbar--left",children:ct}),jsxRuntimeExports.jsx("div",{className:"editor-toolbar--column editor-toolbar--center",children:Ot}),jsxRuntimeExports.jsx("div",{className:"editor-toolbar--column editor-toolbar--right",children:qt})]})}function EditorWorksheet(it){return jsxRuntimeExports.jsx("div",{className:"editor-worksheet",children:jsxRuntimeExports.jsx("div",{className:"editor-worksheet--page",children:it.children})})}const colorScheme$1={light:{color:"#222222",bgColor:"#FFFFFF",border:"#EEEEEE",shadow:"rgba(128,128,128,0.65)",inputColor:"#222222",inputBg:"#F6F6F6"},dark:{color:"#E6E6E6",bgColor:"#181818",border:"#181818",shadow:"rgba(0, 0, 0, 0.25)",inputColor:"#E6E6E6",inputBg:"#222222"}},typographySizes$1={huge:{fontSize:"36pt",fontWeight:"bold",padding:"6pt",margin:"30pt 0 0 0"},larger:{fontSize:"24pt",fontWeight:"bold",padding:"6pt",margin:"18pt 0 0 0"},large:{fontSize:"18pt",fontWeight:"bold",padding:"6pt",margin:"12pt 0 0 0"},medium:{fontSize:"11pt",fontWeight:"bold",padding:"6pt",margin:"5pt 0 0 0"},small:{fontSize:"10pt",fontWeight:"normal",padding:"6pt",margin:"0"},smaller:{fontSize:"9pt",fontWeight:"normal",padding:"6pt",margin:"0"},tiny:{fontSize:"8pt",fontWeight:"normal",padding:"6pt",margin:"0"}},inputStyle$1=(it="light",ct=!1)=>{const Ot=colorScheme$1[it];return{width:"100%",border:"none",boxSizing:"border-box",backgroundColor:ct?Ot.inputBg:Ot.bgColor,outline:"none",color:Ot.inputColor,resize:"none",fontFamily:"Roboto, sans-serif",overflow:"hidden",lineHeight:"1.5"}},styles=Object.freeze(Object.defineProperty({__proto__:null,colorScheme:colorScheme$1,inputStyle:inputStyle$1,typographySizes:typographySizes$1},Symbol.toStringTag,{value:"Module"})),colorScheme={light:{color:"#222222",bgColor:"#FFFFFF",border:"#EEEEEE",shadow:"rgba(128,128,128,0.65)",inputColor:"#222222",inputBg:"#F6F6F6"},dark:{color:"#CCCCCC",bgColor:"#0A0A0A",border:"#181818",shadow:"rgba(255, 255, 255, 0.25)",inputColor:"#CCCCCC",inputBg:"#1A1D1F"}},typographySizes={chapter:{fontSize:"64pt",fontWeight:"bold",padding:"6pt 24pt",margin:"0",lineHeight:1,textAlign:"right",borderLeft:"4px solid"},huge:{fontSize:"32pt",fontWeight:"normal",padding:"6pt",margin:"0 0 0 -6pt",lineHeight:1},larger:{fontSize:"24pt",fontWeight:"bold",padding:"6pt",margin:"-12pt 0 0 0"},large:{fontSize:"18pt",fontWeight:"bold",padding:"6pt",margin:"-10.5pt 0 0 0"},medium:{fontSize:"11pt",fontWeight:"bold",padding:"6pt",margin:"-8pt 0 0 0"},small:{fontSize:"10pt",fontWeight:"normal",padding:"6pt",margin:"-6pt 0 0 0"},smaller:{fontSize:"9pt",fontWeight:"normal",padding:"6pt",margin:"-5pt 0 0 0"},tiny:{fontSize:"8pt",fontWeight:"normal",padding:"6pt",margin:"-8pt 0 0 0"}},inputStyle=(it="light",ct=!1)=>{const Ot=colorScheme[it];return{width:"100%",border:"none",boxSizing:"border-box",backgroundColor:ct?Ot.inputBg:Ot.bgColor,outline:"none",color:Ot.inputColor,resize:"none",fontFamily:"Roboto, sans-serif",overflow:"hidden",lineHeight:"1.5"}},stylesVariant=Object.freeze(Object.defineProperty({__proto__:null,colorScheme,inputStyle,typographySizes},Symbol.toStringTag,{value:"Module"}));function TextInput(it){const[ct,Ot]=reactExports.useState({value:it.value||"",hasFocus:!1,pressingEnter:!1});reactExports.useEffect(()=>{Ot(so=>so.value!==it.value?{...so,value:it.value||""}:so)},[it.value]);const qt=so=>{so.key==="Enter"&&(Ot({...ct,pressingEnter:!0}),so.preventDefault())},Zn=so=>{so.key==="Enter"&&(so.target&&it.onSubmit&&it.onSubmit(so.target.value),it.clearOnSubmit?Ot({...ct,value:"",pressingEnter:!1}):Ot({...ct,pressingEnter:!1}),so.preventDefault()),(so.key==="Backspace"||so.key==="Delete")&&(it.onEmpty&&so.target.value.length<1&&it.onEmpty(it.id||""),so.preventDefault())},no=so=>{if(!ct.pressingEnter){const lo=so.target;Ot({...ct,value:lo.value}),lo.style.height="1px",lo.style.height=lo.scrollHeight+"px"}},oo=so=>{var lo;if(Ot(co=>({...co,hasFocus:so})),!so){const co=((lo=io.current)==null?void 0:lo.value)||"",uo=it.value||"";co!=uo&&it.onSubmit&&(it.onSubmit(co),it.clearOnSubmit&&Ot(po=>({...po,value:""})))}},io=reactExports.useRef(null);reactExports.useEffect(()=>{const so=()=>{io.current&&(io.current.style.height="1px",io.current.style.height=io.current.scrollHeight+"px")};return window.addEventListener("resize",so),so(),()=>{window.removeEventListener("resize",so)}});const ao={...inputStyle$1(it.theme,ct.hasFocus),...typographySizes$1[it.size||"small"]};return jsxRuntimeExports.jsxs("div",{children:[it.horizontalLine?jsxRuntimeExports.jsx("hr",{style:{borderColor:inputStyle$1(it.theme,!1).backgroundColor}},"line"):"",jsxRuntimeExports.jsx("textarea",{autoFocus:it.autoFocus||!1,onBlur:so=>oo(!1),onFocus:so=>oo(!0),onInput:no,onKeyDown:qt,onKeyUp:Zn,placeholder:it.placeholder||"",ref:io,style:ao,value:ct.value},"text")]})}function TextInputVariant(it){const[ct,Ot]=reactExports.useState({value:it.value||"",hasFocus:!1,pressingEnter:!1});reactExports.useEffect(()=>{Ot({...ct,value:it.value||""})},[it.value]);const qt=so=>{so.key==="Enter"&&(Ot({...ct,pressingEnter:!0}),so.preventDefault())},Zn=so=>{so.key==="Enter"&&(so.target&&it.onSubmit&&it.onSubmit(so.target.value),it.clearOnSubmit?Ot({...ct,value:"",pressingEnter:!1}):Ot({...ct,pressingEnter:!1}),so.preventDefault()),(so.key==="Backspace"||so.key==="Delete")&&(it.onEmpty&&so.target.value.length<1&&it.onEmpty(it.id||""),so.preventDefault())},no=so=>{if(!ct.pressingEnter){const lo=so.target;Ot({...ct,value:lo.value}),lo.style.height="1px",lo.style.height=lo.scrollHeight+"px"}},oo=so=>{var lo;if(Ot({...ct,hasFocus:so}),!so){const co=((lo=io.current)==null?void 0:lo.value)||"",uo=it.value||"";co!=uo&&it.onSubmit&&it.onSubmit(co)}},io=reactExports.useRef(null);reactExports.useEffect(()=>{const so=()=>{io.current&&(io.current.style.height="1px",io.current.style.height=io.current.scrollHeight+"px")};return window.addEventListener("resize",so),so(),()=>{window.removeEventListener("resize",so)}});const ao={...inputStyle(it.theme,ct.hasFocus),...typographySizes[it.size||"small"]};return it.labelStyle&&(ao.textAlign="center",ao.textTransform="uppercase",ao.backgroundColor="rgba(0, 0, 255, 0.05)",ao.borderRadius="8px",ao.padding="1px 0 4px 0",ao.margin="0",ao.fontWeight="bold",ao.fontSize="8pt",ao.color="#518EBE",ao.border="2px solid #518EBE",ao.cursor="pointer",ao.lineHeight="1.5"),jsxRuntimeExports.jsxs("div",{children:[it.horizontalLine?jsxRuntimeExports.jsx("hr",{style:{borderColor:inputStyle(it.theme,!1).backgroundColor}},"line"):"",jsxRuntimeExports.jsx("textarea",{autoFocus:it.autoFocus||!1,onBlur:so=>oo(!1),onFocus:so=>oo(!0),onInput:no,onKeyDown:qt,onKeyUp:Zn,placeholder:it.placeholder||"",ref:io,spellCheck:ct.hasFocus,style:ao,tabIndex:it.labelStyle?-1:1,value:ct.value},"text")]})}function ToolbarButton(it){const ct=it.onClick||(()=>{console.log("No onClick handler attached to button.")});return jsxRuntimeExports.jsx("div",{className:"toolbar-button",onClick:ct,style:{userSelect:"none"},children:it.children})}function wrapReducer(it,ct){return(Ot,qt)=>{try{return it(Ot,qt)}catch(Zn){return ct==null||ct(Zn),Ot}}}function createUseDocumentReducer(it,ct){return(Ot,qt)=>useDocumentReducer(it,ct(Ot),qt)}function useDocumentReducer(it,ct,Ot){const[qt,Zn]=reactExports.useState(ct);return[qt,(no,oo)=>{Zn(io=>{try{const ao=it(io,no),so=ao.operations[no.scope].slice(-1)[0];if(so.error){const lo=new Error(so.error);Ot==null||Ot(lo),oo==null||oo(lo)}return ao}catch(ao){return Ot==null||Ot(ao),oo==null||oo(ao),io}})}]}var u$2=Object.defineProperty,a$1=(it,ct)=>u$2(it,"name",{value:ct,configurable:!0}),y$1=(()=>{let it;return typeof window<"u"?it=window:typeof globalThis<"u"?it=globalThis:typeof global<"u"?it=global:typeof self<"u"?it=self:it={},it})(),{LOGLEVEL:b$3}=y$1,t$2={trace:1,debug:2,info:3,warn:4,error:5,silent:10},L$2=b$3,i$2=t$2[L$2]||t$2.info,s$1={trace:a$1((it,...ct)=>{i$2<=t$2.trace&&console.trace(it,...ct)},"trace"),debug:a$1((it,...ct)=>{i$2<=t$2.debug&&console.debug(it,...ct)},"debug"),info:a$1((it,...ct)=>{i$2<=t$2.info&&console.info(it,...ct)},"info"),warn:a$1((it,...ct)=>{i$2<=t$2.warn&&console.warn(it,...ct)},"warn"),error:a$1((it,...ct)=>{i$2<=t$2.error&&console.error(it,...ct)},"error"),log:a$1((it,...ct)=>{i$2<t$2.silent&&console.log(it,...ct)},"log")},c$1=new Set,n$1=a$1(it=>(ct,...Ot)=>{if(!c$1.has(ct))return c$1.add(ct),s$1[it](ct,...Ot)},"once");n$1.clear=()=>c$1.clear();n$1.trace=n$1("trace");n$1.debug=n$1("debug");n$1.info=n$1("info");n$1.warn=n$1("warn");n$1.error=n$1("error");n$1.log=n$1("log");var m$2=n$1("warn"),r$2=a$1(it=>(...ct)=>{let Ot=[];if(ct.length){let qt=/<span\s+style=(['"])([^'"]*)\1\s*>/gi,Zn=/<\/span>/gi,no;for(Ot.push(ct[0].replace(qt,"%c").replace(Zn,"%c"));no=qt.exec(ct[0]);)Ot.push(no[2]),Ot.push("");for(let oo=1;oo<ct.length;oo++)Ot.push(ct[oo])}s$1[it].apply(s$1,Ot)},"pretty");r$2.trace=r$2("trace");r$2.debug=r$2("debug");r$2.info=r$2("info");r$2.warn=r$2("warn");r$2.error=r$2("error");var R$2=(it=>(it.CHANNEL_WS_DISCONNECT="channelWSDisconnect",it.CHANNEL_CREATED="channelCreated",it.CONFIG_ERROR="configError",it.STORY_INDEX_INVALIDATED="storyIndexInvalidated",it.STORY_SPECIFIED="storySpecified",it.SET_CONFIG="setConfig",it.SET_STORIES="setStories",it.SET_INDEX="setIndex",it.SET_CURRENT_STORY="setCurrentStory",it.CURRENT_STORY_WAS_SET="currentStoryWasSet",it.FORCE_RE_RENDER="forceReRender",it.FORCE_REMOUNT="forceRemount",it.PRELOAD_ENTRIES="preloadStories",it.STORY_PREPARED="storyPrepared",it.DOCS_PREPARED="docsPrepared",it.STORY_CHANGED="storyChanged",it.STORY_UNCHANGED="storyUnchanged",it.STORY_RENDERED="storyRendered",it.STORY_MISSING="storyMissing",it.STORY_ERRORED="storyErrored",it.STORY_THREW_EXCEPTION="storyThrewException",it.STORY_RENDER_PHASE_CHANGED="storyRenderPhaseChanged",it.PLAY_FUNCTION_THREW_EXCEPTION="playFunctionThrewException",it.UNHANDLED_ERRORS_WHILE_PLAYING="unhandledErrorsWhilePlaying",it.UPDATE_STORY_ARGS="updateStoryArgs",it.STORY_ARGS_UPDATED="storyArgsUpdated",it.RESET_STORY_ARGS="resetStoryArgs",it.SET_FILTER="setFilter",it.SET_GLOBALS="setGlobals",it.UPDATE_GLOBALS="updateGlobals",it.GLOBALS_UPDATED="globalsUpdated",it.REGISTER_SUBSCRIPTION="registerSubscription",it.PREVIEW_KEYDOWN="previewKeydown",it.PREVIEW_BUILDER_PROGRESS="preview_builder_progress",it.SELECT_STORY="selectStory",it.STORIES_COLLAPSE_ALL="storiesCollapseAll",it.STORIES_EXPAND_ALL="storiesExpandAll",it.DOCS_RENDERED="docsRendered",it.SHARED_STATE_CHANGED="sharedStateChanged",it.SHARED_STATE_SET="sharedStateSet",it.NAVIGATE_URL="navigateUrl",it.UPDATE_QUERY_PARAMS="updateQueryParams",it.REQUEST_WHATS_NEW_DATA="requestWhatsNewData",it.RESULT_WHATS_NEW_DATA="resultWhatsNewData",it.SET_WHATS_NEW_CACHE="setWhatsNewCache",it.TOGGLE_WHATS_NEW_NOTIFICATIONS="toggleWhatsNewNotifications",it.TELEMETRY_ERROR="telemetryError",it.FILE_COMPONENT_SEARCH_REQUEST="fileComponentSearchRequest",it.FILE_COMPONENT_SEARCH_RESPONSE="fileComponentSearchResponse",it.SAVE_STORY_REQUEST="saveStoryRequest",it.SAVE_STORY_RESPONSE="saveStoryResponse",it.ARGTYPES_INFO_REQUEST="argtypesInfoRequest",it.ARGTYPES_INFO_RESPONSE="argtypesInfoResponse",it.CREATE_NEW_STORYFILE_REQUEST="createNewStoryfileRequest",it.CREATE_NEW_STORYFILE_RESPONSE="createNewStoryfileResponse",it))(R$2||{}),S$2=R$2,{CHANNEL_WS_DISCONNECT:_$1,CHANNEL_CREATED:T$1,CONFIG_ERROR:A$1,CREATE_NEW_STORYFILE_REQUEST:O$3,CREATE_NEW_STORYFILE_RESPONSE:N$2,CURRENT_STORY_WAS_SET:r$1,DOCS_PREPARED:D$2,DOCS_RENDERED:I$3,FILE_COMPONENT_SEARCH_REQUEST:C$3,FILE_COMPONENT_SEARCH_RESPONSE:o$2,FORCE_RE_RENDER:P$2,FORCE_REMOUNT:L$1,GLOBALS_UPDATED:a$2,NAVIGATE_URL:Y$1,PLAY_FUNCTION_THREW_EXCEPTION:U$2,UNHANDLED_ERRORS_WHILE_PLAYING:G$4,PRELOAD_ENTRIES:W$2,PREVIEW_BUILDER_PROGRESS:H$2,PREVIEW_KEYDOWN:d,REGISTER_SUBSCRIPTION:t$1,RESET_STORY_ARGS:p$2,SELECT_STORY:i$1,SET_CONFIG:l$1$1,SET_CURRENT_STORY:F$2,SET_FILTER:e,SET_GLOBALS:y,SET_INDEX:c,SET_STORIES:h$1,SHARED_STATE_CHANGED:f$2,SHARED_STATE_SET:g,STORIES_COLLAPSE_ALL:u$1,STORIES_EXPAND_ALL:s,STORY_ARGS_UPDATED:x$3,STORY_CHANGED:M$3,STORY_ERRORED:Q,STORY_INDEX_INVALIDATED:m$1,STORY_MISSING:V$2,STORY_PREPARED:w$2,STORY_RENDER_PHASE_CHANGED:B$2,STORY_RENDERED:X$1,STORY_SPECIFIED:b$2,STORY_THREW_EXCEPTION:q$2,STORY_UNCHANGED:K$1,UPDATE_GLOBALS:j$1,UPDATE_QUERY_PARAMS:k$4,UPDATE_STORY_ARGS:z$4,REQUEST_WHATS_NEW_DATA:J$3,RESULT_WHATS_NEW_DATA:Z,SET_WHATS_NEW_CACHE:$$3,TOGGLE_WHATS_NEW_NOTIFICATIONS:n,TELEMETRY_ERROR:v$2,SAVE_STORY_REQUEST:EE,SAVE_STORY_RESPONSE:RE,ARGTYPES_INFO_REQUEST:SE,ARGTYPES_INFO_RESPONSE:_E}=R$2;const Qn$1=Object.freeze(Object.defineProperty({__proto__:null,ARGTYPES_INFO_REQUEST:SE,ARGTYPES_INFO_RESPONSE:_E,CHANNEL_CREATED:T$1,CHANNEL_WS_DISCONNECT:_$1,CONFIG_ERROR:A$1,CREATE_NEW_STORYFILE_REQUEST:O$3,CREATE_NEW_STORYFILE_RESPONSE:N$2,CURRENT_STORY_WAS_SET:r$1,DOCS_PREPARED:D$2,DOCS_RENDERED:I$3,FILE_COMPONENT_SEARCH_REQUEST:C$3,FILE_COMPONENT_SEARCH_RESPONSE:o$2,FORCE_REMOUNT:L$1,FORCE_RE_RENDER:P$2,GLOBALS_UPDATED:a$2,NAVIGATE_URL:Y$1,PLAY_FUNCTION_THREW_EXCEPTION:U$2,PRELOAD_ENTRIES:W$2,PREVIEW_BUILDER_PROGRESS:H$2,PREVIEW_KEYDOWN:d,REGISTER_SUBSCRIPTION:t$1,REQUEST_WHATS_NEW_DATA:J$3,RESET_STORY_ARGS:p$2,RESULT_WHATS_NEW_DATA:Z,SAVE_STORY_REQUEST:EE,SAVE_STORY_RESPONSE:RE,SELECT_STORY:i$1,SET_CONFIG:l$1$1,SET_CURRENT_STORY:F$2,SET_FILTER:e,SET_GLOBALS:y,SET_INDEX:c,SET_STORIES:h$1,SET_WHATS_NEW_CACHE:$$3,SHARED_STATE_CHANGED:f$2,SHARED_STATE_SET:g,STORIES_COLLAPSE_ALL:u$1,STORIES_EXPAND_ALL:s,STORY_ARGS_UPDATED:x$3,STORY_CHANGED:M$3,STORY_ERRORED:Q,STORY_INDEX_INVALIDATED:m$1,STORY_MISSING:V$2,STORY_PREPARED:w$2,STORY_RENDERED:X$1,STORY_RENDER_PHASE_CHANGED:B$2,STORY_SPECIFIED:b$2,STORY_THREW_EXCEPTION:q$2,STORY_UNCHANGED:K$1,TELEMETRY_ERROR:v$2,TOGGLE_WHATS_NEW_NOTIFICATIONS:n,UNHANDLED_ERRORS_WHILE_PLAYING:G$4,UPDATE_GLOBALS:j$1,UPDATE_QUERY_PARAMS:k$4,UPDATE_STORY_ARGS:z$4,default:S$2},Symbol.toStringTag,{value:"Module"}));var Qt=Object.create,st=Object.defineProperty,te$1=Object.getOwnPropertyDescriptor,ee=Object.getOwnPropertyNames,re$1=Object.getPrototypeOf,ne$1=Object.prototype.hasOwnProperty,i$3=(it,ct)=>st(it,"name",{value:ct,configurable:!0}),U$1=(it=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(it,{get:(ct,Ot)=>(typeof require<"u"?require:ct)[Ot]}):it)(function(it){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+it+'" is not supported')}),oe$2=(it,ct)=>()=>(ct||it((ct={exports:{}}).exports,ct),ct.exports),ae=(it,ct,Ot,qt)=>{if(ct&&typeof ct=="object"||typeof ct=="function")for(let Zn of ee(ct))!ne$1.call(it,Zn)&&Zn!==Ot&&st(it,Zn,{get:()=>ct[Zn],enumerable:!(qt=te$1(ct,Zn))||qt.enumerable});return it},ie=(it,ct,Ot)=>(Ot=it!=null?Qt(re$1(it)):{},ae(st(Ot,"default",{value:it,enumerable:!0}),it)),At=oe$2((it,ct)=>{(function(Ot){if(typeof it=="object"&&typeof ct<"u")ct.exports=Ot();else if(typeof define=="function"&&define.amd)define([],Ot);else{var qt;typeof window<"u"?qt=window:typeof global<"u"?qt=global:typeof self<"u"?qt=self:qt=this,qt.memoizerific=Ot()}})(function(){return i$3(function Ot(qt,Zn,no){function oo(so,lo){if(!Zn[so]){if(!qt[so]){var co=typeof U$1=="function"&&U$1;if(!lo&&co)return co(so,!0);if(io)return io(so,!0);var uo=new Error("Cannot find module '"+so+"'");throw uo.code="MODULE_NOT_FOUND",uo}var po=Zn[so]={exports:{}};qt[so][0].call(po.exports,function(fo){var mo=qt[so][1][fo];return oo(mo||fo)},po,po.exports,Ot,qt,Zn,no)}return Zn[so].exports}i$3(oo,"s");for(var io=typeof U$1=="function"&&U$1,ao=0;ao<no.length;ao++)oo(no[ao]);return oo},"e")({1:[function(Ot,qt,Zn){qt.exports=function(no){if(typeof Map!="function"||no){var oo=Ot("./similar");return new oo}else return new Map}},{"./similar":2}],2:[function(Ot,qt,Zn){function no(){return this.list=[],this.lastItem=void 0,this.size=0,this}i$3(no,"Similar"),no.prototype.get=function(oo){var io;if(this.lastItem&&this.isEqual(this.lastItem.key,oo))return this.lastItem.val;if(io=this.indexOf(oo),io>=0)return this.lastItem=this.list[io],this.list[io].val},no.prototype.set=function(oo,io){var ao;return this.lastItem&&this.isEqual(this.lastItem.key,oo)?(this.lastItem.val=io,this):(ao=this.indexOf(oo),ao>=0?(this.lastItem=this.list[ao],this.list[ao].val=io,this):(this.lastItem={key:oo,val:io},this.list.push(this.lastItem),this.size++,this))},no.prototype.delete=function(oo){var io;if(this.lastItem&&this.isEqual(this.lastItem.key,oo)&&(this.lastItem=void 0),io=this.indexOf(oo),io>=0)return this.size--,this.list.splice(io,1)[0]},no.prototype.has=function(oo){var io;return this.lastItem&&this.isEqual(this.lastItem.key,oo)?!0:(io=this.indexOf(oo),io>=0?(this.lastItem=this.list[io],!0):!1)},no.prototype.forEach=function(oo,io){var ao;for(ao=0;ao<this.size;ao++)oo.call(io||this,this.list[ao].val,this.list[ao].key,this)},no.prototype.indexOf=function(oo){var io;for(io=0;io<this.size;io++)if(this.isEqual(this.list[io].key,oo))return io;return-1},no.prototype.isEqual=function(oo,io){return oo===io||oo!==oo&&io!==io},qt.exports=no},{}],3:[function(Ot,qt,Zn){var no=Ot("map-or-similar");qt.exports=function(so){var lo=new no(!1),co=[];return function(uo){var po=i$3(function(){var fo=lo,mo,So,ho=arguments.length-1,yo=Array(ho+1),go=!0,vo;if((po.numArgs||po.numArgs===0)&&po.numArgs!==ho+1)throw new Error("Memoizerific functions should always be called with the same number of arguments");for(vo=0;vo<ho;vo++){if(yo[vo]={cacheItem:fo,arg:arguments[vo]},fo.has(arguments[vo])){fo=fo.get(arguments[vo]);continue}go=!1,mo=new no(!1),fo.set(arguments[vo],mo),fo=mo}return go&&(fo.has(arguments[ho])?So=fo.get(arguments[ho]):go=!1),go||(So=uo.apply(null,arguments),fo.set(arguments[ho],So)),so>0&&(yo[ho]={cacheItem:fo,arg:arguments[ho]},go?oo(co,yo):co.push(yo),co.length>so&&io(co.shift())),po.wasMemoized=go,po.numArgs=ho+1,So},"memoizerific");return po.limit=so,po.wasMemoized=!1,po.cache=lo,po.lru=co,po}};function oo(so,lo){var co=so.length,uo=lo.length,po,fo,mo;for(fo=0;fo<co;fo++){for(po=!0,mo=0;mo<uo;mo++)if(!ao(so[fo][mo].arg,lo[mo].arg)){po=!1;break}if(po)break}so.push(so.splice(fo,1)[0])}i$3(oo,"moveToMostRecentLru");function io(so){var lo=so.length,co=so[lo-1],uo,po;for(co.cacheItem.delete(co.arg),po=lo-2;po>=0&&(co=so[po],uo=co.cacheItem.get(co.arg),!uo||!uo.size);po--)co.cacheItem.delete(co.arg)}i$3(io,"removeCachedResult");function ao(so,lo){return so===lo||so!==so&&lo!==lo}i$3(ao,"isEqual")},{"map-or-similar":1}]},{},[3])(3)})}),b$1=(()=>{let it;return typeof window<"u"?it=window:typeof globalThis<"u"?it=globalThis:typeof global<"u"?it=global:typeof self<"u"?it=self:it={},it})(),se=i$3(it=>it.transports!==void 0,"isMulti"),le=i$3(()=>Math.random().toString(16).slice(2),"generateRandomId"),lt=class{constructor(it={}){this.sender=le(),this.events={},this.data={},this.transports=[],this.isAsync=it.async||!1,se(it)?(this.transports=it.transports||[],this.transports.forEach(ct=>{ct.setHandler(Ot=>this.handleEvent(Ot))})):this.transports=it.transport?[it.transport]:[],this.transports.forEach(ct=>{ct.setHandler(Ot=>this.handleEvent(Ot))})}get hasTransport(){return this.transports.length>0}addListener(it,ct){this.events[it]=this.events[it]||[],this.events[it].push(ct)}emit(it,...ct){let Ot={type:it,args:ct,from:this.sender},qt={};ct.length>=1&&ct[0]&&ct[0].options&&(qt=ct[0].options);let Zn=i$3(()=>{this.transports.forEach(no=>{no.send(Ot,qt)}),this.handleEvent(Ot)},"handler");this.isAsync?setImmediate(Zn):Zn()}last(it){return this.data[it]}eventNames(){return Object.keys(this.events)}listenerCount(it){let ct=this.listeners(it);return ct?ct.length:0}listeners(it){return this.events[it]||void 0}once(it,ct){let Ot=this.onceListener(it,ct);this.addListener(it,Ot)}removeAllListeners(it){it?this.events[it]&&delete this.events[it]:this.events={}}removeListener(it,ct){let Ot=this.listeners(it);Ot&&(this.events[it]=Ot.filter(qt=>qt!==ct))}on(it,ct){this.addListener(it,ct)}off(it,ct){this.removeListener(it,ct)}handleEvent(it){let ct=this.listeners(it.type);ct&&ct.length&&ct.forEach(Ot=>{Ot.apply(it,it.args)}),this.data[it.type]=it.args}onceListener(it,ct){let Ot=i$3((...qt)=>(this.removeListener(it,Ot),ct(...qt)),"onceListener");return Ot}};i$3(lt,"Channel");var z$3=lt,ce=Object.create,St$1=Object.defineProperty,fe=Object.getOwnPropertyDescriptor,wt$1=Object.getOwnPropertyNames,ue$1=Object.getPrototypeOf,pe$1=Object.prototype.hasOwnProperty,x$2=i$3((it,ct)=>i$3(function(){return ct||(0,it[wt$1(it)[0]])((ct={exports:{}}).exports,ct),ct.exports},"__require"),"__commonJS"),ye$1=i$3((it,ct,Ot,qt)=>{if(ct&&typeof ct=="object"||typeof ct=="function")for(let Zn of wt$1(ct))!pe$1.call(it,Zn)&&Zn!==Ot&&St$1(it,Zn,{get:i$3(()=>ct[Zn],"get"),enumerable:!(qt=fe(ct,Zn))||qt.enumerable});return it},"__copyProps"),tt$1=i$3((it,ct,Ot)=>(Ot=it!=null?ce(ue$1(it)):{},ye$1(ct||!it||!it.__esModule?St$1(Ot,"default",{value:it,enumerable:!0}):Ot,it)),"__toESM"),de$1=["bubbles","cancelBubble","cancelable","composed","currentTarget","defaultPrevented","eventPhase","isTrusted","returnValue","srcElement","target","timeStamp","type"],he$1=["detail"];function Et(it){let ct=de$1.filter(Ot=>it[Ot]!==void 0).reduce((Ot,qt)=>({...Ot,[qt]:it[qt]}),{});return it instanceof CustomEvent&&he$1.filter(Ot=>it[Ot]!==void 0).forEach(Ot=>{ct[Ot]=it[Ot]}),ct}i$3(Et,"extractEventHiddenProperties");var Ut$1=ie(At()),Tt$1=x$2({"node_modules/has-symbols/shams.js"(it,ct){ct.exports=i$3(function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var Ot={},qt=Symbol("test"),Zn=Object(qt);if(typeof qt=="string"||Object.prototype.toString.call(qt)!=="[object Symbol]"||Object.prototype.toString.call(Zn)!=="[object Symbol]")return!1;var no=42;Ot[qt]=no;for(qt in Ot)return!1;if(typeof Object.keys=="function"&&Object.keys(Ot).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(Ot).length!==0)return!1;var oo=Object.getOwnPropertySymbols(Ot);if(oo.length!==1||oo[0]!==qt||!Object.prototype.propertyIsEnumerable.call(Ot,qt))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var io=Object.getOwnPropertyDescriptor(Ot,qt);if(io.value!==no||io.enumerable!==!0)return!1}return!0},"hasSymbols")}}),Ft=x$2({"node_modules/has-symbols/index.js"(it,ct){var Ot=typeof Symbol<"u"&&Symbol,qt=Tt$1();ct.exports=i$3(function(){return typeof Ot!="function"||typeof Symbol!="function"||typeof Ot("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:qt()},"hasNativeSymbols")}}),ge$1=x$2({"node_modules/function-bind/implementation.js"(it,ct){var Ot="Function.prototype.bind called on incompatible ",qt=Array.prototype.slice,Zn=Object.prototype.toString,no="[object Function]";ct.exports=i$3(function(oo){var io=this;if(typeof io!="function"||Zn.call(io)!==no)throw new TypeError(Ot+io);for(var ao=qt.call(arguments,1),so,lo=i$3(function(){if(this instanceof so){var mo=io.apply(this,ao.concat(qt.call(arguments)));return Object(mo)===mo?mo:this}else return io.apply(oo,ao.concat(qt.call(arguments)))},"binder"),co=Math.max(0,io.length-ao.length),uo=[],po=0;po<co;po++)uo.push("$"+po);if(so=Function("binder","return function ("+uo.join(",")+"){ return binder.apply(this,arguments); }")(lo),io.prototype){var fo=i$3(function(){},"Empty2");fo.prototype=io.prototype,so.prototype=new fo,fo.prototype=null}return so},"bind")}}),ut$1=x$2({"node_modules/function-bind/index.js"(it,ct){var Ot=ge$1();ct.exports=Function.prototype.bind||Ot}}),me$1=x$2({"node_modules/has/src/index.js"(it,ct){var Ot=ut$1();ct.exports=Ot.call(Function.call,Object.prototype.hasOwnProperty)}}),Nt$1=x$2({"node_modules/get-intrinsic/index.js"(it,ct){var Ot,qt=SyntaxError,Zn=Function,no=TypeError,oo=i$3(function(Ko){try{return Zn('"use strict"; return ('+Ko+").constructor;")()}catch{}},"getEvalledConstructor"),io=Object.getOwnPropertyDescriptor;if(io)try{io({},"")}catch{io=null}var ao=i$3(function(){throw new no},"throwTypeError"),so=io?function(){try{return arguments.callee,ao}catch{try{return io(arguments,"callee").get}catch{return ao}}}():ao,lo=Ft()(),co=Object.getPrototypeOf||function(Ko){return Ko.__proto__},uo={},po=typeof Uint8Array>"u"?Ot:co(Uint8Array),fo={"%AggregateError%":typeof AggregateError>"u"?Ot:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?Ot:ArrayBuffer,"%ArrayIteratorPrototype%":lo?co([][Symbol.iterator]()):Ot,"%AsyncFromSyncIteratorPrototype%":Ot,"%AsyncFunction%":uo,"%AsyncGenerator%":uo,"%AsyncGeneratorFunction%":uo,"%AsyncIteratorPrototype%":uo,"%Atomics%":typeof Atomics>"u"?Ot:Atomics,"%BigInt%":typeof BigInt>"u"?Ot:BigInt,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?Ot:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":typeof Float32Array>"u"?Ot:Float32Array,"%Float64Array%":typeof Float64Array>"u"?Ot:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?Ot:FinalizationRegistry,"%Function%":Zn,"%GeneratorFunction%":uo,"%Int8Array%":typeof Int8Array>"u"?Ot:Int8Array,"%Int16Array%":typeof Int16Array>"u"?Ot:Int16Array,"%Int32Array%":typeof Int32Array>"u"?Ot:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":lo?co(co([][Symbol.iterator]())):Ot,"%JSON%":typeof JSON=="object"?JSON:Ot,"%Map%":typeof Map>"u"?Ot:Map,"%MapIteratorPrototype%":typeof Map>"u"||!lo?Ot:co(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?Ot:Promise,"%Proxy%":typeof Proxy>"u"?Ot:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":typeof Reflect>"u"?Ot:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?Ot:Set,"%SetIteratorPrototype%":typeof Set>"u"||!lo?Ot:co(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?Ot:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":lo?co(""[Symbol.iterator]()):Ot,"%Symbol%":lo?Symbol:Ot,"%SyntaxError%":qt,"%ThrowTypeError%":so,"%TypedArray%":po,"%TypeError%":no,"%Uint8Array%":typeof Uint8Array>"u"?Ot:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?Ot:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?Ot:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?Ot:Uint32Array,"%URIError%":URIError,"%WeakMap%":typeof WeakMap>"u"?Ot:WeakMap,"%WeakRef%":typeof WeakRef>"u"?Ot:WeakRef,"%WeakSet%":typeof WeakSet>"u"?Ot:WeakSet},mo=i$3(function Ko(zo){var bo;if(zo==="%AsyncFunction%")bo=oo("async function () {}");else if(zo==="%GeneratorFunction%")bo=oo("function* () {}");else if(zo==="%AsyncGeneratorFunction%")bo=oo("async function* () {}");else if(zo==="%AsyncGenerator%"){var Io=Ko("%AsyncGeneratorFunction%");Io&&(bo=Io.prototype)}else if(zo==="%AsyncIteratorPrototype%"){var Qo=Ko("%AsyncGenerator%");Qo&&(bo=co(Qo.prototype))}return fo[zo]=bo,bo},"doEval2"),So={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},ho=ut$1(),yo=me$1(),go=ho.call(Function.call,Array.prototype.concat),vo=ho.call(Function.apply,Array.prototype.splice),xo=ho.call(Function.call,String.prototype.replace),Vo=ho.call(Function.call,String.prototype.slice),ti=ho.call(Function.call,RegExp.prototype.exec),ni=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,No=/\\(\\)?/g,ko=i$3(function(Ko){var zo=Vo(Ko,0,1),bo=Vo(Ko,-1);if(zo==="%"&&bo!=="%")throw new qt("invalid intrinsic syntax, expected closing `%`");if(bo==="%"&&zo!=="%")throw new qt("invalid intrinsic syntax, expected opening `%`");var Io=[];return xo(Ko,ni,function(Qo,Zo,ui,ai){Io[Io.length]=ui?xo(ai,No,"$1"):Zo||Qo}),Io},"stringToPath3"),wo=i$3(function(Ko,zo){var bo=Ko,Io;if(yo(So,bo)&&(Io=So[bo],bo="%"+Io[0]+"%"),yo(fo,bo)){var Qo=fo[bo];if(Qo===uo&&(Qo=mo(bo)),typeof Qo>"u"&&!zo)throw new no("intrinsic "+Ko+" exists, but is not available. Please file an issue!");return{alias:Io,name:bo,value:Qo}}throw new qt("intrinsic "+Ko+" does not exist!")},"getBaseIntrinsic2");ct.exports=i$3(function(Ko,zo){if(typeof Ko!="string"||Ko.length===0)throw new no("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof zo!="boolean")throw new no('"allowMissing" argument must be a boolean');if(ti(/^%?[^%]*%?$/,Ko)===null)throw new qt("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var bo=ko(Ko),Io=bo.length>0?bo[0]:"",Qo=wo("%"+Io+"%",zo),Zo=Qo.name,ui=Qo.value,ai=!1,si=Qo.alias;si&&(Io=si[0],vo(bo,go([0,1],si)));for(var di=1,Fo=!0;di<bo.length;di+=1){var oi=bo[di],ei=Vo(oi,0,1),ri=Vo(oi,-1);if((ei==='"'||ei==="'"||ei==="`"||ri==='"'||ri==="'"||ri==="`")&&ei!==ri)throw new qt("property names with quotes must have matching quotes");if((oi==="constructor"||!Fo)&&(ai=!0),Io+="."+oi,Zo="%"+Io+"%",yo(fo,Zo))ui=fo[Zo];else if(ui!=null){if(!(oi in ui)){if(!zo)throw new no("base intrinsic for "+Ko+" exists, but the property is not available.");return}if(io&&di+1>=bo.length){var ci=io(ui,oi);Fo=!!ci,Fo&&"get"in ci&&!("originalValue"in ci.get)?ui=ci.get:ui=ui[oi]}else Fo=yo(ui,oi),ui=ui[oi];Fo&&!ai&&(fo[Zo]=ui)}}return ui},"GetIntrinsic")}}),ve$1=x$2({"node_modules/call-bind/index.js"(it,ct){var Ot=ut$1(),qt=Nt$1(),Zn=qt("%Function.prototype.apply%"),no=qt("%Function.prototype.call%"),oo=qt("%Reflect.apply%",!0)||Ot.call(no,Zn),io=qt("%Object.getOwnPropertyDescriptor%",!0),ao=qt("%Object.defineProperty%",!0),so=qt("%Math.max%");if(ao)try{ao({},"a",{value:1})}catch{ao=null}ct.exports=i$3(function(co){var uo=oo(Ot,no,arguments);if(io&&ao){var po=io(uo,"length");po.configurable&&ao(uo,"length",{value:1+so(0,co.length-(arguments.length-1))})}return uo},"callBind");var lo=i$3(function(){return oo(Ot,Zn,arguments)},"applyBind2");ao?ao(ct.exports,"apply",{value:lo}):ct.exports.apply=lo}}),_e=x$2({"node_modules/call-bind/callBound.js"(it,ct){var Ot=Nt$1(),qt=ve$1(),Zn=qt(Ot("String.prototype.indexOf"));ct.exports=i$3(function(no,oo){var io=Ot(no,!!oo);return typeof io=="function"&&Zn(no,".prototype.")>-1?qt(io):io},"callBoundIntrinsic")}}),be=x$2({"node_modules/has-tostringtag/shams.js"(it,ct){var Ot=Tt$1();ct.exports=i$3(function(){return Ot()&&!!Symbol.toStringTag},"hasToStringTagShams")}}),Se=x$2({"node_modules/is-regex/index.js"(it,ct){var Ot=_e(),qt=be()(),Zn,no,oo,io;qt&&(Zn=Ot("Object.prototype.hasOwnProperty"),no=Ot("RegExp.prototype.exec"),oo={},ao=i$3(function(){throw oo},"throwRegexMarker"),io={toString:ao,valueOf:ao},typeof Symbol.toPrimitive=="symbol"&&(io[Symbol.toPrimitive]=ao));var ao,so=Ot("Object.prototype.toString"),lo=Object.getOwnPropertyDescriptor,co="[object RegExp]";ct.exports=i$3(qt?function(uo){if(!uo||typeof uo!="object")return!1;var po=lo(uo,"lastIndex"),fo=po&&Zn(po,"value");if(!fo)return!1;try{no(uo,io)}catch(mo){return mo===oo}}:function(uo){return!uo||typeof uo!="object"&&typeof uo!="function"?!1:so(uo)===co},"isRegex")}}),we=x$2({"node_modules/is-function/index.js"(it,ct){ct.exports=qt;var Ot=Object.prototype.toString;function qt(Zn){if(!Zn)return!1;var no=Ot.call(Zn);return no==="[object Function]"||typeof Zn=="function"&&no!=="[object RegExp]"||typeof window<"u"&&(Zn===window.setTimeout||Zn===window.alert||Zn===window.confirm||Zn===window.prompt)}i$3(qt,"isFunction3")}}),Ee$1=x$2({"node_modules/is-symbol/index.js"(it,ct){var Ot=Object.prototype.toString,qt=Ft()();qt?(Zn=Symbol.prototype.toString,no=/^Symbol\(.*\)$/,oo=i$3(function(io){return typeof io.valueOf()!="symbol"?!1:no.test(Zn.call(io))},"isRealSymbolObject"),ct.exports=i$3(function(io){if(typeof io=="symbol")return!0;if(Ot.call(io)!=="[object Symbol]")return!1;try{return oo(io)}catch{return!1}},"isSymbol3")):ct.exports=i$3(function(io){return!1},"isSymbol3");var Zn,no,oo}}),Oe=tt$1(Se()),Ae$1=tt$1(we()),Pe=tt$1(Ee$1());function xe$1(it){return it!=null&&typeof it=="object"&&Array.isArray(it)===!1}i$3(xe$1,"isObject");var Ce=typeof global=="object"&&global&&global.Object===Object&&global,Ie=Ce,je$1=typeof self=="object"&&self&&self.Object===Object&&self,Te=Ie||je$1||Function("return this")(),pt=Te,Fe=pt.Symbol,M$2=Fe,Rt=Object.prototype,Ne$1=Rt.hasOwnProperty,Re=Rt.toString,W$1=M$2?M$2.toStringTag:void 0;function Me$1(it){var ct=Ne$1.call(it,W$1),Ot=it[W$1];try{it[W$1]=void 0;var qt=!0}catch{}var Zn=Re.call(it);return qt&&(ct?it[W$1]=Ot:delete it[W$1]),Zn}i$3(Me$1,"getRawTag");var $e=Me$1,ke$1=Object.prototype,De$1=ke$1.toString;function Le$1(it){return De$1.call(it)}i$3(Le$1,"objectToString");var Ue$1=Le$1,ze="[object Null]",We="[object Undefined]",Pt=M$2?M$2.toStringTag:void 0;function Be$1(it){return it==null?it===void 0?We:ze:Pt&&Pt in Object(it)?$e(it):Ue$1(it)}i$3(Be$1,"baseGetTag");var Mt$1=Be$1;function He(it){return it!=null&&typeof it=="object"}i$3(He,"isObjectLike");var qe=He,Ge$1="[object Symbol]";function Je$1(it){return typeof it=="symbol"||qe(it)&&Mt$1(it)==Ge$1}i$3(Je$1,"isSymbol");var yt=Je$1;function Ve(it,ct){for(var Ot=-1,qt=it==null?0:it.length,Zn=Array(qt);++Ot<qt;)Zn[Ot]=ct(it[Ot],Ot,it);return Zn}i$3(Ve,"arrayMap");var Ke=Ve,Ye=Array.isArray,dt=Ye,Ze=1/0,xt=M$2?M$2.prototype:void 0,Ct=xt?xt.toString:void 0;function $t(it){if(typeof it=="string")return it;if(dt(it))return Ke(it,$t)+"";if(yt(it))return Ct?Ct.call(it):"";var ct=it+"";return ct=="0"&&1/it==-Ze?"-0":ct}i$3($t,"baseToString");var Xe=$t;function Qe$1(it){var ct=typeof it;return it!=null&&(ct=="object"||ct=="function")}i$3(Qe$1,"isObject2");var kt$1=Qe$1,tr$1="[object AsyncFunction]",er$1="[object Function]",rr="[object GeneratorFunction]",nr="[object Proxy]";function or(it){if(!kt$1(it))return!1;var ct=Mt$1(it);return ct==er$1||ct==rr||ct==tr$1||ct==nr}i$3(or,"isFunction");var ar=or,ir=pt["__core-js_shared__"],ft=ir,It$1=function(){var it=/[^.]+$/.exec(ft&&ft.keys&&ft.keys.IE_PROTO||"");return it?"Symbol(src)_1."+it:""}();function sr$1(it){return!!It$1&&It$1 in it}i$3(sr$1,"isMasked");var lr$1=sr$1,cr$1=Function.prototype,fr$1=cr$1.toString;function ur$1(it){if(it!=null){try{return fr$1.call(it)}catch{}try{return it+""}catch{}}return""}i$3(ur$1,"toSource");var pr$1=ur$1,yr$1=/[\\^$.*+?()[\]{}|]/g,dr$1=/^\[object .+?Constructor\]$/,hr$1=Function.prototype,gr$1=Object.prototype,mr$1=hr$1.toString,vr$1=gr$1.hasOwnProperty,_r$1=RegExp("^"+mr$1.call(vr$1).replace(yr$1,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function br$1(it){if(!kt$1(it)||lr$1(it))return!1;var ct=ar(it)?_r$1:dr$1;return ct.test(pr$1(it))}i$3(br$1,"baseIsNative");var Sr$1=br$1;function wr$1(it,ct){return it==null?void 0:it[ct]}i$3(wr$1,"getValue");var Er=wr$1;function Or(it,ct){var Ot=Er(it,ct);return Sr$1(Ot)?Ot:void 0}i$3(Or,"getNative");var Dt$1=Or;function Ar(it,ct){return it===ct||it!==it&&ct!==ct}i$3(Ar,"eq");var Pr=Ar,xr$1=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Cr=/^\w*$/;function Ir(it,ct){if(dt(it))return!1;var Ot=typeof it;return Ot=="number"||Ot=="symbol"||Ot=="boolean"||it==null||yt(it)?!0:Cr.test(it)||!xr$1.test(it)||ct!=null&&it in Object(ct)}i$3(Ir,"isKey");var jr$1=Ir,Tr$1=Dt$1(Object,"create"),B$1=Tr$1;function Fr$1(){this.__data__=B$1?B$1(null):{},this.size=0}i$3(Fr$1,"hashClear");var Nr$1=Fr$1;function Rr(it){var ct=this.has(it)&&delete this.__data__[it];return this.size-=ct?1:0,ct}i$3(Rr,"hashDelete");var Mr$1=Rr,$r$1="__lodash_hash_undefined__",kr$1=Object.prototype,Dr$1=kr$1.hasOwnProperty;function Lr$1(it){var ct=this.__data__;if(B$1){var Ot=ct[it];return Ot===$r$1?void 0:Ot}return Dr$1.call(ct,it)?ct[it]:void 0}i$3(Lr$1,"hashGet");var Ur$1=Lr$1,zr$1=Object.prototype,Wr$1=zr$1.hasOwnProperty;function Br(it){var ct=this.__data__;return B$1?ct[it]!==void 0:Wr$1.call(ct,it)}i$3(Br,"hashHas");var Hr=Br,qr$1="__lodash_hash_undefined__";function Gr$1(it,ct){var Ot=this.__data__;return this.size+=this.has(it)?0:1,Ot[it]=B$1&&ct===void 0?qr$1:ct,this}i$3(Gr$1,"hashSet");var Jr$1=Gr$1;function $$2(it){var ct=-1,Ot=it==null?0:it.length;for(this.clear();++ct<Ot;){var qt=it[ct];this.set(qt[0],qt[1])}}i$3($$2,"Hash");$$2.prototype.clear=Nr$1;$$2.prototype.delete=Mr$1;$$2.prototype.get=Ur$1;$$2.prototype.has=Hr;$$2.prototype.set=Jr$1;var jt$1=$$2;function Vr$1(){this.__data__=[],this.size=0}i$3(Vr$1,"listCacheClear");var Kr$1=Vr$1;function Yr$1(it,ct){for(var Ot=it.length;Ot--;)if(Pr(it[Ot][0],ct))return Ot;return-1}i$3(Yr$1,"assocIndexOf");var rt$1=Yr$1,Zr$1=Array.prototype,Xr$1=Zr$1.splice;function Qr$1(it){var ct=this.__data__,Ot=rt$1(ct,it);if(Ot<0)return!1;var qt=ct.length-1;return Ot==qt?ct.pop():Xr$1.call(ct,Ot,1),--this.size,!0}i$3(Qr$1,"listCacheDelete");var tn$1=Qr$1;function en$1(it){var ct=this.__data__,Ot=rt$1(ct,it);return Ot<0?void 0:ct[Ot][1]}i$3(en$1,"listCacheGet");var rn$1=en$1;function nn$1(it){return rt$1(this.__data__,it)>-1}i$3(nn$1,"listCacheHas");var on$1=nn$1;function an(it,ct){var Ot=this.__data__,qt=rt$1(Ot,it);return qt<0?(++this.size,Ot.push([it,ct])):Ot[qt][1]=ct,this}i$3(an,"listCacheSet");var sn$1=an;function k$3(it){var ct=-1,Ot=it==null?0:it.length;for(this.clear();++ct<Ot;){var qt=it[ct];this.set(qt[0],qt[1])}}i$3(k$3,"ListCache");k$3.prototype.clear=Kr$1;k$3.prototype.delete=tn$1;k$3.prototype.get=rn$1;k$3.prototype.has=on$1;k$3.prototype.set=sn$1;var ln$1=k$3,cn$1=Dt$1(pt,"Map"),fn=cn$1;function un(){this.size=0,this.__data__={hash:new jt$1,map:new(fn||ln$1),string:new jt$1}}i$3(un,"mapCacheClear");var pn=un;function yn(it){var ct=typeof it;return ct=="string"||ct=="number"||ct=="symbol"||ct=="boolean"?it!=="__proto__":it===null}i$3(yn,"isKeyable");var dn=yn;function hn(it,ct){var Ot=it.__data__;return dn(ct)?Ot[typeof ct=="string"?"string":"hash"]:Ot.map}i$3(hn,"getMapData");var nt$1=hn;function gn$1(it){var ct=nt$1(this,it).delete(it);return this.size-=ct?1:0,ct}i$3(gn$1,"mapCacheDelete");var mn$1=gn$1;function vn$1(it){return nt$1(this,it).get(it)}i$3(vn$1,"mapCacheGet");var _n$1=vn$1;function bn$1(it){return nt$1(this,it).has(it)}i$3(bn$1,"mapCacheHas");var Sn=bn$1;function wn$1(it,ct){var Ot=nt$1(this,it),qt=Ot.size;return Ot.set(it,ct),this.size+=Ot.size==qt?0:1,this}i$3(wn$1,"mapCacheSet");var En$1=wn$1;function D$1(it){var ct=-1,Ot=it==null?0:it.length;for(this.clear();++ct<Ot;){var qt=it[ct];this.set(qt[0],qt[1])}}i$3(D$1,"MapCache");D$1.prototype.clear=pn;D$1.prototype.delete=mn$1;D$1.prototype.get=_n$1;D$1.prototype.has=Sn;D$1.prototype.set=En$1;var Lt$1=D$1,On$1="Expected a function";function ht(it,ct){if(typeof it!="function"||ct!=null&&typeof ct!="function")throw new TypeError(On$1);var Ot=i$3(function(){var qt=arguments,Zn=ct?ct.apply(this,qt):qt[0],no=Ot.cache;if(no.has(Zn))return no.get(Zn);var oo=it.apply(this,qt);return Ot.cache=no.set(Zn,oo)||no,oo},"memoized");return Ot.cache=new(ht.Cache||Lt$1),Ot}i$3(ht,"memoize");ht.Cache=Lt$1;var An=ht,Pn$1=500;function xn$1(it){var ct=An(it,function(qt){return Ot.size===Pn$1&&Ot.clear(),qt}),Ot=ct.cache;return ct}i$3(xn$1,"memoizeCapped");var Cn=xn$1,In$1=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,jn$1=/\\(\\)?/g,Tn$1=Cn(function(it){var ct=[];return it.charCodeAt(0)===46&&ct.push(""),it.replace(In$1,function(Ot,qt,Zn,no){ct.push(Zn?no.replace(jn$1,"$1"):qt||Ot)}),ct}),Fn$1=Tn$1;function Nn$1(it){return it==null?"":Xe(it)}i$3(Nn$1,"toString");var Rn$1=Nn$1;function Mn$1(it,ct){return dt(it)?it:jr$1(it,ct)?[it]:Fn$1(Rn$1(it))}i$3(Mn$1,"castPath");var $n$1=Mn$1,kn$1=1/0;function Dn$1(it){if(typeof it=="string"||yt(it))return it;var ct=it+"";return ct=="0"&&1/it==-kn$1?"-0":ct}i$3(Dn$1,"toKey");var Ln$1=Dn$1;function Un$1(it,ct){ct=$n$1(ct,it);for(var Ot=0,qt=ct.length;it!=null&&Ot<qt;)it=it[Ln$1(ct[Ot++])];return Ot&&Ot==qt?it:void 0}i$3(Un$1,"baseGet");var zn$1=Un$1;function Wn$1(it,ct,Ot){var qt=it==null?void 0:zn$1(it,ct);return qt===void 0?Ot:qt}i$3(Wn$1,"get");var Bn$1=Wn$1,et$1=xe$1,Hn$1=i$3(it=>{let ct=null,Ot=!1,qt=!1,Zn=!1,no="";if(it.indexOf("//")>=0||it.indexOf("/*")>=0)for(let oo=0;oo<it.length;oo+=1)!ct&&!Ot&&!qt&&!Zn?it[oo]==='"'||it[oo]==="'"||it[oo]==="`"?ct=it[oo]:it[oo]==="/"&&it[oo+1]==="*"?Ot=!0:it[oo]==="/"&&it[oo+1]==="/"?qt=!0:it[oo]==="/"&&it[oo+1]!=="/"&&(Zn=!0):(ct&&(it[oo]===ct&&it[oo-1]!=="\\"||it[oo]===`
3
3
  `&&ct!=="`")&&(ct=null),Zn&&(it[oo]==="/"&&it[oo-1]!=="\\"||it[oo]===`
4
4
  `)&&(Zn=!1),Ot&&it[oo-1]==="/"&&it[oo-2]==="*"&&(Ot=!1),qt&&it[oo]===`
5
5
  `&&(qt=!1)),!Ot&&!qt&&(no+=it[oo]);else no=it;return no},"removeCodeComments"),qn$1=(0,Ut$1.default)(1e4)(it=>Hn$1(it).replace(/\n\s*/g,"").trim()),Gn$1=i$3(function(it,ct){let Ot=ct.slice(0,ct.indexOf("{")),qt=ct.slice(ct.indexOf("{"));if(Ot.includes("=>")||Ot.includes("function"))return ct;let Zn=Ot;return Zn=Zn.replace(it,"function"),Zn+qt},"convertShorthandMethods2"),Jn=/^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d{3})?Z$/,H$1=i$3(it=>it.match(/^[\[\{\"\}].*[\]\}\"]$/),"isJSON");function zt$1(it){if(!et$1(it))return it;let ct=it,Ot=!1;return typeof Event<"u"&&it instanceof Event&&(ct=Et(ct),Ot=!0),ct=Object.keys(ct).reduce((qt,Zn)=>{try{ct[Zn]&&ct[Zn].toJSON,qt[Zn]=ct[Zn]}catch{Ot=!0}return qt},{}),Ot?ct:it}i$3(zt$1,"convertUnconventionalData");var Vn$1=i$3(function(it){let ct,Ot,qt,Zn;return i$3(function(no,oo){try{if(no==="")return Zn=[],ct=new Map([[oo,"[]"]]),Ot=new Map,qt=[],oo;let io=Ot.get(this)||this;for(;qt.length&&io!==qt[0];)qt.shift(),Zn.pop();if(typeof oo=="boolean")return oo;if(oo===void 0)return it.allowUndefined?"_undefined_":void 0;if(oo===null)return null;if(typeof oo=="number")return oo===-1/0?"_-Infinity_":oo===1/0?"_Infinity_":Number.isNaN(oo)?"_NaN_":oo;if(typeof oo=="bigint")return`_bigint_${oo.toString()}`;if(typeof oo=="string")return Jn.test(oo)?it.allowDate?`_date_${oo}`:void 0:oo;if((0,Oe.default)(oo))return it.allowRegExp?`_regexp_${oo.flags}|${oo.source}`:void 0;if((0,Ae$1.default)(oo)){if(!it.allowFunction)return;let{name:so}=oo,lo=oo.toString();return lo.match(/(\[native code\]|WEBPACK_IMPORTED_MODULE|__webpack_exports__|__webpack_require__)/)?`_function_${so}|${(()=>{}).toString()}`:`_function_${so}|${qn$1(Gn$1(no,lo))}`}if((0,Pe.default)(oo)){if(!it.allowSymbol)return;let so=Symbol.keyFor(oo);return so!==void 0?`_gsymbol_${so}`:`_symbol_${oo.toString().slice(7,-1)}`}if(qt.length>=it.maxDepth)return Array.isArray(oo)?`[Array(${oo.length})]`:"[Object]";if(oo===this)return`_duplicate_${JSON.stringify(Zn)}`;if(oo instanceof Error&&it.allowError)return{__isConvertedError__:!0,errorProperties:{...oo.cause?{cause:oo.cause}:{},...oo,name:oo.name,message:oo.message,stack:oo.stack,"_constructor-name_":oo.constructor.name}};if(oo.constructor&&oo.constructor.name&&oo.constructor.name!=="Object"&&!Array.isArray(oo)&&!it.allowClass)return;let ao=ct.get(oo);if(!ao){let so=Array.isArray(oo)?oo:zt$1(oo);if(oo.constructor&&oo.constructor.name&&oo.constructor.name!=="Object"&&!Array.isArray(oo)&&it.allowClass)try{Object.assign(so,{"_constructor-name_":oo.constructor.name})}catch{}return Zn.push(no),qt.unshift(so),ct.set(oo,JSON.stringify(Zn)),oo!==so&&Ot.set(oo,so),so}return`_duplicate_${ao}`}catch{return}},"replace")},"replacer2"),Kn=i$3(function reviver(options){let refs=[],root;return i$3(function revive(key,value){if(key===""&&(root=value,refs.forEach(({target:it,container:ct,replacement:Ot})=>{let qt=H$1(Ot)?JSON.parse(Ot):Ot.split(".");qt.length===0?ct[it]=root:ct[it]=Bn$1(root,qt)})),key==="_constructor-name_")return value;if(et$1(value)&&value.__isConvertedError__){let{message:it,...ct}=value.errorProperties,Ot=new Error(it);return Object.assign(Ot,ct),Ot}if(et$1(value)&&value["_constructor-name_"]&&options.allowFunction){let it=value["_constructor-name_"];if(it!=="Object"){let ct=new Function(`return function ${it.replace(/[^a-zA-Z0-9$_]+/g,"")}(){}`)();Object.setPrototypeOf(value,new ct)}return delete value["_constructor-name_"],value}if(typeof value=="string"&&value.startsWith("_function_")&&options.allowFunction){let[,name,source]=value.match(/_function_([^|]*)\|(.*)/)||[],sourceSanitized=source.replace(/[(\(\))|\\| |\]|`]*$/,"");if(!options.lazyEval)return eval(`(${sourceSanitized})`);let result=i$3((...args)=>{let f=eval(`(${sourceSanitized})`);return f(...args)},"result");return Object.defineProperty(result,"toString",{value:i$3(()=>sourceSanitized,"value")}),Object.defineProperty(result,"name",{value:name}),result}if(typeof value=="string"&&value.startsWith("_regexp_")&&options.allowRegExp){let[,it,ct]=value.match(/_regexp_([^|]*)\|(.*)/)||[];return new RegExp(ct,it)}return typeof value=="string"&&value.startsWith("_date_")&&options.allowDate?new Date(value.replace("_date_","")):typeof value=="string"&&value.startsWith("_duplicate_")?(refs.push({target:key,container:this,replacement:value.replace(/^_duplicate_/,"")}),null):typeof value=="string"&&value.startsWith("_symbol_")&&options.allowSymbol?Symbol(value.replace("_symbol_","")):typeof value=="string"&&value.startsWith("_gsymbol_")&&options.allowSymbol?Symbol.for(value.replace("_gsymbol_","")):typeof value=="string"&&value==="_-Infinity_"?-1/0:typeof value=="string"&&value==="_Infinity_"?1/0:typeof value=="string"&&value==="_NaN_"?NaN:typeof value=="string"&&value.startsWith("_bigint_")&&typeof BigInt=="function"?BigInt(value.replace("_bigint_","")):value},"revive")},"reviver"),Wt$1={maxDepth:10,space:void 0,allowFunction:!0,allowRegExp:!0,allowDate:!0,allowClass:!0,allowError:!0,allowUndefined:!0,allowSymbol:!0,lazyEval:!0},ot$1=i$3((it,ct={})=>{let Ot={...Wt$1,...ct};return JSON.stringify(zt$1(it),Vn$1(Ot),ct.space)},"stringify"),Yn$1=i$3(()=>{let it=new Map;return i$3(function ct(Ot){et$1(Ot)&&Object.entries(Ot).forEach(([qt,Zn])=>{Zn==="_undefined_"?Ot[qt]=void 0:it.get(Zn)||(it.set(Zn,!0),ct(Zn))}),Array.isArray(Ot)&&Ot.forEach((qt,Zn)=>{qt==="_undefined_"?(it.set(qt,!0),Ot[Zn]=void 0):it.get(qt)||(it.set(qt,!0),ct(qt))})},"mutateUndefined")},"mutator"),at$1=i$3((it,ct={})=>{let Ot={...Wt$1,...ct},qt=JSON.parse(it,Kn(Ot));return Yn$1()(qt),qt},"parse"),gt="Invariant failed";function q$1(it,ct){if(!it){var Ot=typeof ct=="function"?ct():ct,qt=Ot?"".concat(gt,": ").concat(Ot):gt;throw new Error(qt)}}i$3(q$1,"invariant");var Bt$1=i$3(it=>{let ct=Array.from(document.querySelectorAll("iframe[data-is-storybook]")),[Ot,...qt]=ct.filter(no=>{var oo,io;try{return((oo=no.contentWindow)==null?void 0:oo.location.origin)===it.source.location.origin&&((io=no.contentWindow)==null?void 0:io.location.pathname)===it.source.location.pathname}catch{}try{return no.contentWindow===it.source}catch{}let ao=no.getAttribute("src"),so;try{if(!ao)return!1;({origin:so}=new URL(ao,document.location.toString()))}catch{return!1}return so===it.origin}),Zn=Ot==null?void 0:Ot.getAttribute("src");if(Zn&&qt.length===0){let{protocol:no,host:oo,pathname:io}=new URL(Zn,document.location.toString());return`${no}//${oo}${io}`}return qt.length>0&&s$1.error("found multiple candidates for event source"),null},"getEventSourceUrl"),{document:mt,location:vt}=b$1,Gt$1="storybook-channel",to={allowFunction:!1,maxDepth:25},_t=class{constructor(it){if(this.config=it,this.connected=!1,this.buffer=[],typeof(b$1==null?void 0:b$1.addEventListener)=="function"&&b$1.addEventListener("message",this.handleEvent.bind(this),!1),it.page!=="manager"&&it.page!=="preview")throw new Error(`postmsg-channel: "config.page" cannot be "${it.page}"`)}setHandler(it){this.handler=(...ct)=>{it.apply(this,ct),!this.connected&&this.getLocalFrame().length&&(this.flush(),this.connected=!0)}}send(it,ct){let{target:Ot,allowRegExp:qt,allowFunction:Zn,allowSymbol:no,allowDate:oo,allowError:io,allowUndefined:ao,allowClass:so,maxDepth:lo,space:co,lazyEval:uo}=ct||{},po=Object.fromEntries(Object.entries({allowRegExp:qt,allowFunction:Zn,allowSymbol:no,allowDate:oo,allowError:io,allowUndefined:ao,allowClass:so,maxDepth:lo,space:co,lazyEval:uo}).filter(([yo,go])=>typeof go<"u")),fo={...to,...b$1.CHANNEL_OPTIONS||{},...po},mo=this.getFrames(Ot),So=new URLSearchParams((vt==null?void 0:vt.search)||""),ho=ot$1({key:Gt$1,event:it,refId:So.get("refId")},fo);return mo.length?(this.buffer.length&&this.flush(),mo.forEach(yo=>{try{yo.postMessage(ho,"*")}catch{s$1.error("sending over postmessage fail")}}),Promise.resolve(null)):new Promise((yo,go)=>{this.buffer.push({event:it,resolve:yo,reject:go})})}flush(){let{buffer:it}=this;this.buffer=[],it.forEach(ct=>{this.send(ct.event).then(ct.resolve).catch(ct.reject)})}getFrames(it){if(this.config.page==="manager"){let ct=Array.from(mt.querySelectorAll("iframe[data-is-storybook][data-is-loaded]")).flatMap(Ot=>{try{return Ot.contentWindow&&Ot.dataset.isStorybook!==void 0&&Ot.id===it?[Ot.contentWindow]:[]}catch{return[]}});return ct!=null&&ct.length?ct:this.getCurrentFrames()}return b$1&&b$1.parent&&b$1.parent!==b$1.self?[b$1.parent]:[]}getCurrentFrames(){return this.config.page==="manager"?Array.from(mt.querySelectorAll('[data-is-storybook="true"]')).flatMap(it=>it.contentWindow?[it.contentWindow]:[]):b$1&&b$1.parent?[b$1.parent]:[]}getLocalFrame(){return this.config.page==="manager"?Array.from(mt.querySelectorAll("#storybook-preview-iframe")).flatMap(it=>it.contentWindow?[it.contentWindow]:[]):b$1&&b$1.parent?[b$1.parent]:[]}handleEvent(it){try{let{data:ct}=it,{key:Ot,event:qt,refId:Zn}=typeof ct=="string"&&H$1(ct)?at$1(ct,b$1.CHANNEL_OPTIONS||{}):ct;if(Ot===Gt$1){let no=this.config.page==="manager"?'<span style="color: #37D5D3; background: black"> manager </span>':'<span style="color: #1EA7FD; background: black"> preview </span>',oo=Object.values(Qn$1).includes(qt.type)?`<span style="color: #FF4785">${qt.type}</span>`:`<span style="color: #FFAE00">${qt.type}</span>`;if(Zn&&(qt.refId=Zn),qt.source=this.config.page==="preview"?it.origin:Bt$1(it),!qt.source){r$2.error(`${no} received ${oo} but was unable to determine the source of the event`);return}let io=`${no} received ${oo} (${ct.length})`;r$2.debug(vt.origin!==qt.source?io:`${io} <span style="color: gray">(on ${vt.origin} from ${qt.source})</span>`,...qt.args),q$1(this.handler,"ChannelHandler should be set"),this.handler(qt)}}catch(ct){s$1.error(ct)}}};i$3(_t,"PostMessageTransport");var G$3=_t,{WebSocket:eo}=b$1,bt=class{constructor({url:it,onError:ct,page:Ot}){this.buffer=[],this.isReady=!1,this.socket=new eo(it),this.socket.onopen=()=>{this.isReady=!0,this.flush()},this.socket.onmessage=({data:qt})=>{let Zn=typeof qt=="string"&&H$1(qt)?at$1(qt):qt;q$1(this.handler,"WebsocketTransport handler should be set"),this.handler(Zn)},this.socket.onerror=qt=>{ct&&ct(qt)},this.socket.onclose=()=>{q$1(this.handler,"WebsocketTransport handler should be set"),this.handler({type:_$1,args:[],from:Ot||"preview"})}}setHandler(it){this.handler=it}send(it){this.isReady?this.sendNow(it):this.sendLater(it)}sendLater(it){this.buffer.push(it)}sendNow(it){let ct=ot$1(it,{maxDepth:15,allowFunction:!1,...b$1.CHANNEL_OPTIONS});this.socket.send(ct)}flush(){let{buffer:it}=this;this.buffer=[],it.forEach(ct=>this.send(ct))}};i$3(bt,"WebsocketTransport");var J$2=bt,{CONFIG_TYPE:ro$1}=b$1;function $o({page:it,extraTransports:ct=[]}){let Ot=[new G$3({page:it}),...ct];if(ro$1==="DEVELOPMENT"){let qt=window.location.protocol==="http:"?"ws":"wss",{hostname:Zn,port:no}=window.location,oo=`${qt}://${Zn}:${no}/storybook-server-channel`;Ot.push(new J$2({url:oo,onError:i$3(()=>{},"onError"),page:it}))}return new z$3({transports:Ot})}i$3($o,"createBrowserChannel");var oe$1=Object.defineProperty,t=(it,ct)=>oe$1(it,"name",{value:ct,configurable:!0});function r(it){for(var ct=[],Ot=1;Ot<arguments.length;Ot++)ct[Ot-1]=arguments[Ot];var qt=Array.from(typeof it=="string"?[it]:it);qt[qt.length-1]=qt[qt.length-1].replace(/\r?\n([\t ]*)$/,"");var Zn=qt.reduce(function(io,ao){var so=ao.match(/\n([\t ]+|(?!\s).)/g);return so?io.concat(so.map(function(lo){var co,uo;return(uo=(co=lo.match(/[\t ]/g))===null||co===void 0?void 0:co.length)!==null&&uo!==void 0?uo:0})):io},[]);if(Zn.length){var no=new RegExp(`
@@ -191,14 +191,14 @@ ${vo.description}`)},"showError"),showException:o(vo=>{throw vo},"showException"
191
191
  The possible options are: ${Object.keys(Do).join(", ")}, none.
192
192
  `)}showMode(it){clearTimeout(this.preparingTimeout),Object.keys(cf).forEach(ct=>{ct===it?k.body.classList.add(_o[ct]):k.body.classList.remove(_o[ct])})}showErrorDisplay({message:it="",stack:ct=""}){let Ot=it,qt=ct,Zn=it.split(`
193
193
  `);Zn.length>1&&([Ot]=Zn,qt=Zn.slice(1).join(`
194
- `).replace(/^\n/,"")),k.getElementById("error-message").innerHTML=af.toHtml(Ot),k.getElementById("error-stack").innerHTML=af.toHtml(qt),this.showMode("ERROR")}showNoPreview(){var it,ct;this.testing||(this.showMode("NOPREVIEW"),(it=this.storyRoot())==null||it.setAttribute("hidden","true"),(ct=this.docsRoot())==null||ct.setAttribute("hidden","true"))}showPreparingStory({immediate:it=!1}={}){clearTimeout(this.preparingTimeout),it?this.showMode("PREPARING_STORY"):this.preparingTimeout=setTimeout(()=>this.showMode("PREPARING_STORY"),of)}showPreparingDocs({immediate:it=!1}={}){clearTimeout(this.preparingTimeout),it?this.showMode("PREPARING_DOCS"):this.preparingTimeout=setTimeout(()=>this.showMode("PREPARING_DOCS"),of)}showMain(){this.showMode("MAIN")}showDocs(){this.storyRoot().setAttribute("hidden","true"),this.docsRoot().removeAttribute("hidden")}showStory(){this.docsRoot().setAttribute("hidden","true"),this.storyRoot().removeAttribute("hidden")}showStoryDuringRender(){k.body.classList.add(_o.MAIN)}};o(Mo,"WebView");var Je=Mo,Lo=class extends Be{constructor(it,ct){super(it,ct,new Qe,new Je),this.importFn=it,this.getProjectAnnotations=ct,C.__STORYBOOK_PREVIEW__=this}};o(Lo,"PreviewWeb");var{document:xe}=C,zE=["application/javascript","application/ecmascript","application/x-ecmascript","application/x-javascript","text/ecmascript","text/javascript","text/javascript1.0","text/javascript1.1","text/javascript1.2","text/javascript1.3","text/javascript1.4","text/javascript1.5","text/jscript","text/livescript","text/x-ecmascript","text/x-javascript","module"],VE="script",uf="scripts-root";function It(){let it=xe.createEvent("Event");it.initEvent("DOMContentLoaded",!0,!0),xe.dispatchEvent(it)}o(It,"simulateDOMContentLoaded");function $E(it,ct,Ot){let qt=xe.createElement("script");qt.type=it.type==="module"?"module":"text/javascript",it.src?(qt.onload=ct,qt.onerror=ct,qt.src=it.src):qt.textContent=it.innerText,Ot?Ot.appendChild(qt):xe.head.appendChild(qt),it.parentNode.removeChild(it),it.src||ct()}o($E,"insertScript");function pf(it,ct,Ot=0){it[Ot](()=>{Ot++,Ot===it.length?ct():pf(it,ct,Ot)})}o(pf,"insertScriptsSequentially");function df(it){let ct=xe.getElementById(uf);ct?ct.innerHTML="":(ct=xe.createElement("div"),ct.id=uf,xe.body.appendChild(ct));let Ot=Array.from(it.querySelectorAll(VE));if(Ot.length){let qt=[];Ot.forEach(Zn=>{let no=Zn.getAttribute("type");(!no||zE.includes(no))&&qt.push(oo=>$E(Zn,oo,ct))}),qt.length&&pf(qt,It,void 0)}else It()}o(df,"simulatePageLoad");function wrapEditor(it){return ct=>{const{theme:Ot,user:qt,...Zn}=ct;return jsxRuntimeExports.jsx(it,{...Zn,context:{theme:Ot,user:qt}})}}function createDocumentStory(it,ct,Ot){const qt={component:wrapEditor(it),render:()=>{const[no,oo]=Lf(),[io,ao]=reactExports.useState(),so=Df({}),[lo,co]=useDocumentReducer(ct,no.document,mo=>{console.error(mo),ao(mo)});function uo(mo){const So={};return no.user&&(So.signer={user:{address:no.user.address,networkId:no.user.networkId,chainId:no.user.chainId},app:{name:"storybook",key:"storybook"},signatures:[]}),co({...mo,context:So})}J$4.useEffect(()=>{lo&&(oo({document:lo}),so("DOCUMENT",lo)),ao(void 0)},[lo]);const po=no.theme==="dark",fo=wrapEditor(it);return jsxRuntimeExports.jsx("div",{style:{padding:"0",height:"100vh",color:po?"white":"black",backgroundColor:po?"#1A1D1F":"white"},children:jsxRuntimeExports.jsx(fo,{...no,dispatch:uo,error:io})})},argTypes:{document:{control:"object"},dispatch:{table:{disable:!0}},theme:{name:"Theme",options:["light","dark"],defaultValue:"light",control:"inline-radio"},user:{control:"object"}}},Zn={name:"New document",args:{document:index.createDocument(Ot),theme:"light",user:{address:"0xd8da6bf26964af9d7eed9e03e53415d37aa96045",networkId:"eip155",chainId:1,ens:{name:"vitalik.eth",avatarUrl:"https://ipfs.io/ipfs/QmSP4nq9fnN9dAiCj42ug9Wa79rqmQerZXZch82VqpiH7U/image.gif"}}}};return{meta:qt,CreateDocumentStory:Zn}}const CodeEditor=P$3(()=>__vitePreload(()=>import("./index-T6Et30Eh-Bk15VVSB.js"),__vite__mapDeps([0,1,2])));function isJSONEqual(it,ct){return JSON.stringify(it).replace(/\s/g,"")===ct.replace(/\s/g,"")}function JSONEditor({value:it,onChange:ct,theme:Ot,onBlur:qt,...Zn}){const[no,oo]=reactExports.useState(JSON.stringify(it,null,4));function io(ao){if(ao)try{const so=JSON.parse(ao);ct(so)}catch{}}return reactExports.useEffect(()=>{io(no)},[no]),reactExports.useEffect(()=>{isJSONEqual(it,no)||oo(JSON.stringify(it,null,4))},[it]),jsxRuntimeExports.jsx(CodeEditor,{height:"100%",language:"json",onChange:ao=>oo(ao??""),theme:`vs-${Ot}`,value:no,...Zn,onMount:ao=>{ao.onDidBlurEditorText(()=>{qt==null||qt(JSON.parse(ao.getValue()))})},options:{lineNumbers:"off",minimap:{enabled:!1},...Zn.options}})}const validators={initWith:function(it){const ct=document.createElement("div"),Ot=it.editor.create(ct),qt=Ot.constructor.name,Zn=Ot.getModel().constructor.name;return{isInstanceValid:function(no){return no.constructor.name===qt},isModelValid:function(no){return no.constructor.name===Zn},isRangesValid:function(no){return Array.isArray(no)?no.every(function(oo){return typeof oo=="object"&&oo.constructor.name==="Object"?!(!oo.hasOwnProperty("range")||!Array.isArray(oo.range)||oo.range.length!==4||!oo.range.every(io=>io>0&&parseInt(io)===io)||oo.hasOwnProperty("allowMultiline")&&typeof oo.allowMultiline!="boolean"||oo.hasOwnProperty("label")&&typeof oo.label!="string"||oo.hasOwnProperty("validate")&&typeof oo.validate!="function"):!1}):!1}}}},TypeMustBe=function(it,ct,Ot){return"The value for the "+ct+" should be of type "+(Array.isArray(it)?it.join(" | "):it)+". "+(Ot||"")},deepClone=function(){const it=function(oo,io){return typeof oo!="object"||oo===null?this.freeze?Object.freeze(oo):oo:oo instanceof Date?this.freeze?Object.freeze(new Date(oo)):new Date(oo):io.call(this,oo)},ct=function(oo,io){const ao=Object.keys(oo),so=new Array(ao.length);for(let lo=0;lo<ao.length;lo++)so[ao[lo]]=it.call(this,oo[ao[lo]],io);return so},Ot=function(oo){return it.call(this,oo,function(io){if(Array.isArray(io))return ct.call(this,io,Ot);const ao={};for(let so in io)!this.withProto&&Object.hasOwnProperty.call(io,so)===!1||(ao[so]=it.call(this,io[so],Ot));return ao})},qt=function(){const oo=function(ao){const so=["withProto","freeze"];this[ao]=so.reduce((function(lo,co){return(lo[co]=ao>=this[co])&&(ao-=this[co]),lo}).bind(this),{})},io=Object.create(Object.defineProperties({},{withProto:{value:1},freeze:{value:2}}));for(let ao=0;ao<=3;ao++)oo.call(io,ao);return io}(),Zn={withProto:Ot.bind(qt[1]),andFreeze:Ot.bind(qt[2]),withProtoAndFreeze:Ot.bind(qt[3])},no=Ot.bind(qt[0]);for(let oo in Zn)Object.defineProperty(no,oo,{enumerable:!1,writable:!1,configurable:!1,value:Zn[oo]});return no}(),enums={SINGLE_LINE_HIGHLIGHT_CLASS:"editableArea--single-line",MULTI_LINE_HIGHLIGHT_CLASS:"editableArea--multi-line"},constrainedModel=function(it,ct,Ot){const qt=Ot.Range,Zn=function(ko,wo){const Ko=ko.range,zo=wo.range;if(Ko[0]<zo[0]||Ko[0]===zo[0]&&Ko[3]<zo[1])return-1},no=function(ko,wo){const Ko=wo.split(`
194
+ `).replace(/^\n/,"")),k.getElementById("error-message").innerHTML=af.toHtml(Ot),k.getElementById("error-stack").innerHTML=af.toHtml(qt),this.showMode("ERROR")}showNoPreview(){var it,ct;this.testing||(this.showMode("NOPREVIEW"),(it=this.storyRoot())==null||it.setAttribute("hidden","true"),(ct=this.docsRoot())==null||ct.setAttribute("hidden","true"))}showPreparingStory({immediate:it=!1}={}){clearTimeout(this.preparingTimeout),it?this.showMode("PREPARING_STORY"):this.preparingTimeout=setTimeout(()=>this.showMode("PREPARING_STORY"),of)}showPreparingDocs({immediate:it=!1}={}){clearTimeout(this.preparingTimeout),it?this.showMode("PREPARING_DOCS"):this.preparingTimeout=setTimeout(()=>this.showMode("PREPARING_DOCS"),of)}showMain(){this.showMode("MAIN")}showDocs(){this.storyRoot().setAttribute("hidden","true"),this.docsRoot().removeAttribute("hidden")}showStory(){this.docsRoot().setAttribute("hidden","true"),this.storyRoot().removeAttribute("hidden")}showStoryDuringRender(){k.body.classList.add(_o.MAIN)}};o(Mo,"WebView");var Je=Mo,Lo=class extends Be{constructor(it,ct){super(it,ct,new Qe,new Je),this.importFn=it,this.getProjectAnnotations=ct,C.__STORYBOOK_PREVIEW__=this}};o(Lo,"PreviewWeb");var{document:xe}=C,zE=["application/javascript","application/ecmascript","application/x-ecmascript","application/x-javascript","text/ecmascript","text/javascript","text/javascript1.0","text/javascript1.1","text/javascript1.2","text/javascript1.3","text/javascript1.4","text/javascript1.5","text/jscript","text/livescript","text/x-ecmascript","text/x-javascript","module"],VE="script",uf="scripts-root";function It(){let it=xe.createEvent("Event");it.initEvent("DOMContentLoaded",!0,!0),xe.dispatchEvent(it)}o(It,"simulateDOMContentLoaded");function $E(it,ct,Ot){let qt=xe.createElement("script");qt.type=it.type==="module"?"module":"text/javascript",it.src?(qt.onload=ct,qt.onerror=ct,qt.src=it.src):qt.textContent=it.innerText,Ot?Ot.appendChild(qt):xe.head.appendChild(qt),it.parentNode.removeChild(it),it.src||ct()}o($E,"insertScript");function pf(it,ct,Ot=0){it[Ot](()=>{Ot++,Ot===it.length?ct():pf(it,ct,Ot)})}o(pf,"insertScriptsSequentially");function df(it){let ct=xe.getElementById(uf);ct?ct.innerHTML="":(ct=xe.createElement("div"),ct.id=uf,xe.body.appendChild(ct));let Ot=Array.from(it.querySelectorAll(VE));if(Ot.length){let qt=[];Ot.forEach(Zn=>{let no=Zn.getAttribute("type");(!no||zE.includes(no))&&qt.push(oo=>$E(Zn,oo,ct))}),qt.length&&pf(qt,It,void 0)}else It()}o(df,"simulatePageLoad");function wrapEditor(it){return ct=>{const{theme:Ot,user:qt,...Zn}=ct;return jsxRuntimeExports.jsx(it,{...Zn,context:{theme:Ot,user:qt}})}}function createDocumentStory(it,ct,Ot){const qt={component:wrapEditor(it),render:()=>{const[no,oo]=Lf(),[io,ao]=reactExports.useState(),so=Df({}),[lo,co]=useDocumentReducer(ct,no.document,mo=>{console.error(mo),ao(mo)});function uo(mo){const So={};return no.user&&(So.signer={user:{address:no.user.address,networkId:no.user.networkId,chainId:no.user.chainId},app:{name:"storybook",key:"storybook"},signatures:[]}),co({...mo,context:So})}J$4.useEffect(()=>{lo&&(oo({document:lo}),so("DOCUMENT",lo)),ao(void 0)},[lo]);const po=no.theme==="dark",fo=wrapEditor(it);return jsxRuntimeExports.jsx("div",{style:{padding:"0",height:"100vh",color:po?"white":"black",backgroundColor:po?"#1A1D1F":"white"},children:jsxRuntimeExports.jsx(fo,{...no,dispatch:uo,error:io})})},argTypes:{document:{control:"object"},dispatch:{table:{disable:!0}},theme:{name:"Theme",options:["light","dark"],defaultValue:"light",control:"inline-radio"},user:{control:"object"}}},Zn={name:"New document",args:{document:index.createDocument(Ot),theme:"light",user:{address:"0xd8da6bf26964af9d7eed9e03e53415d37aa96045",networkId:"eip155",chainId:1,ens:{name:"vitalik.eth",avatarUrl:"https://ipfs.io/ipfs/QmSP4nq9fnN9dAiCj42ug9Wa79rqmQerZXZch82VqpiH7U/image.gif"}}}};return{meta:qt,CreateDocumentStory:Zn}}const CodeEditor=P$3(()=>__vitePreload(()=>import("./index-T6Et30Eh-B1ytNt1O.js"),__vite__mapDeps([0,1,2])));function isJSONEqual(it,ct){return JSON.stringify(it).replace(/\s/g,"")===ct.replace(/\s/g,"")}function JSONEditor({value:it,onChange:ct,theme:Ot,onBlur:qt,...Zn}){const[no,oo]=reactExports.useState(JSON.stringify(it,null,4));function io(ao){if(ao)try{const so=JSON.parse(ao);ct(so)}catch{}}return reactExports.useEffect(()=>{io(no)},[no]),reactExports.useEffect(()=>{isJSONEqual(it,no)||oo(JSON.stringify(it,null,4))},[it]),jsxRuntimeExports.jsx(CodeEditor,{height:"100%",language:"json",onChange:ao=>oo(ao??""),theme:`vs-${Ot}`,value:no,...Zn,onMount:ao=>{ao.onDidBlurEditorText(()=>{qt==null||qt(JSON.parse(ao.getValue()))})},options:{lineNumbers:"off",minimap:{enabled:!1},...Zn.options}})}const validators={initWith:function(it){const ct=document.createElement("div"),Ot=it.editor.create(ct),qt=Ot.constructor.name,Zn=Ot.getModel().constructor.name;return{isInstanceValid:function(no){return no.constructor.name===qt},isModelValid:function(no){return no.constructor.name===Zn},isRangesValid:function(no){return Array.isArray(no)?no.every(function(oo){return typeof oo=="object"&&oo.constructor.name==="Object"?!(!oo.hasOwnProperty("range")||!Array.isArray(oo.range)||oo.range.length!==4||!oo.range.every(io=>io>0&&parseInt(io)===io)||oo.hasOwnProperty("allowMultiline")&&typeof oo.allowMultiline!="boolean"||oo.hasOwnProperty("label")&&typeof oo.label!="string"||oo.hasOwnProperty("validate")&&typeof oo.validate!="function"):!1}):!1}}}},TypeMustBe=function(it,ct,Ot){return"The value for the "+ct+" should be of type "+(Array.isArray(it)?it.join(" | "):it)+". "+(Ot||"")},deepClone=function(){const it=function(oo,io){return typeof oo!="object"||oo===null?this.freeze?Object.freeze(oo):oo:oo instanceof Date?this.freeze?Object.freeze(new Date(oo)):new Date(oo):io.call(this,oo)},ct=function(oo,io){const ao=Object.keys(oo),so=new Array(ao.length);for(let lo=0;lo<ao.length;lo++)so[ao[lo]]=it.call(this,oo[ao[lo]],io);return so},Ot=function(oo){return it.call(this,oo,function(io){if(Array.isArray(io))return ct.call(this,io,Ot);const ao={};for(let so in io)!this.withProto&&Object.hasOwnProperty.call(io,so)===!1||(ao[so]=it.call(this,io[so],Ot));return ao})},qt=function(){const oo=function(ao){const so=["withProto","freeze"];this[ao]=so.reduce((function(lo,co){return(lo[co]=ao>=this[co])&&(ao-=this[co]),lo}).bind(this),{})},io=Object.create(Object.defineProperties({},{withProto:{value:1},freeze:{value:2}}));for(let ao=0;ao<=3;ao++)oo.call(io,ao);return io}(),Zn={withProto:Ot.bind(qt[1]),andFreeze:Ot.bind(qt[2]),withProtoAndFreeze:Ot.bind(qt[3])},no=Ot.bind(qt[0]);for(let oo in Zn)Object.defineProperty(no,oo,{enumerable:!1,writable:!1,configurable:!1,value:Zn[oo]});return no}(),enums={SINGLE_LINE_HIGHLIGHT_CLASS:"editableArea--single-line",MULTI_LINE_HIGHLIGHT_CLASS:"editableArea--multi-line"},constrainedModel=function(it,ct,Ot){const qt=Ot.Range,Zn=function(ko,wo){const Ko=ko.range,zo=wo.range;if(Ko[0]<zo[0]||Ko[0]===zo[0]&&Ko[3]<zo[1])return-1},no=function(ko,wo){const Ko=wo.split(`
195
195
  `),zo=Ko.length,bo=[];return ko.forEach(function(Io,Qo){if(Io===0)throw new Error("Range values cannot be zero");switch(Qo){case 0:{if(Io<0)throw new Error("Start Line of Range cannot be negative");if(Io>zo)throw new Error("Provided Start Line("+Io+") is out of bounds. Max Lines in content is "+zo);bo[Qo]=Io}break;case 1:{let Zo=Io;const ui=bo[0],ai=Ko[ui-1].length;if(Zo<0){if(Zo=ai-Math.abs(Zo),Zo<0)throw new Error("Provided Start Column("+Io+") is out of bounds. Max Column in line "+ui+" is "+ai)}else if(Zo>ai+1)throw new Error("Provided Start Column("+Io+") is out of bounds. Max Column in line "+ui+" is "+ai);bo[Qo]=Zo}break;case 2:{let Zo=Io;if(Zo<0){if(Zo=zo-Math.abs(Io),Zo<0)throw new Error("Provided End Line("+Io+") is out of bounds. Max Lines in content is "+zo);Zo<bo[0]&&console.warn("Provided End Line("+Io+") is less than the start Line, the Restriction may not behave as expected")}else if(Io>zo)throw new Error("Provided End Line("+Io+") is out of bounds. Max Lines in content is "+zo);bo[Qo]=Zo}break;case 3:{let Zo=Io;const ui=bo[2],ai=Ko[ui-1].length;if(Zo<0){if(Zo=ai-Math.abs(Zo),Zo<0)throw new Error("Provided End Column("+Io+") is out of bounds. Max Column in line "+ui+" is "+ai)}else if(Zo>ai+1)throw new Error("Provided Start Column("+Io+") is out of bounds. Max Column in line "+ui+" is "+ai);bo[Qo]=Zo}break}}),bo};let oo=deepClone(ct).sort(Zn);const io=function(ko){const wo=it.getValue();ko.forEach(function(Ko,zo){const bo=no(Ko.range,wo),Io=bo[0],Qo=bo[1],Zo=bo[2],ui=bo[3];Ko._originalRange=bo.slice(),Ko.range=new qt(Io,Qo,Zo,ui),Ko.index=zo,Ko.allowMultiline||(Ko.allowMultiline=qt.spansMultipleLines(Ko.range)),Ko.label||(Ko.label=`[${Io},${Qo} -> ${Zo}${ui}]`)})},ao=function(){return oo.reduce(function(ko,wo){return ko[wo.label]={allowMultiline:wo.allowMultiline||!1,index:wo.index,range:Object.assign({},wo.range),originalRange:wo._originalRange.slice()},ko},{})},so=function(){return oo.reduce(function(ko,wo){return ko[wo.label]=it.getValueInRange(wo.range),ko},{})},lo=function(ko,wo){if(typeof ko=="object"&&!Array.isArray(ko)){wo=typeof wo=="boolean"?wo:!1;const Ko=oo.reduce(function(zo,bo){return bo.label&&(zo[bo.label]=bo),zo},{});for(let zo in ko){const bo=Ko[zo];if(bo){const Io=ko[zo];if(Vo(bo,Io))throw new Error("Multiline change is not allowed for "+zo);const Qo=deepClone(bo.range);if(Qo.endLine=Qo.startLine+Io.split(`
196
196
  `).length-1,Qo.endColumn=Io.split(`
197
197
  `).pop().length,ti(bo,Io,Qo))throw new Error("Change is invalidated by validate function of "+zo);it.applyEdits([{forceMoveMarkers:!!wo,range:bo.range,text:Io}])}else console.error("No restriction found for "+zo)}}else throw new Error("Value must be an object")},co=function(){return it._restrictionChangeListener.dispose(),window.removeEventListener("error",vo),delete it.editInRestrictedArea,delete it.disposeRestrictions,delete it.getValueInEditableRanges,delete it.updateValueInEditableRanges,delete it.updateRestrictions,delete it.getCurrentEditableRanges,delete it.toggleHighlightOfEditableAreas,delete it._hasHighlight,delete it._isRestrictedModel,delete it._isCursorAtCheckPoint,delete it._currentCursorPositions,delete it._editableRangeChangeListener,delete it._restrictionChangeListener,delete it._oldDecorations,delete it._oldDecorationsSource,it},uo=function(ko){ko.some(function(wo){const Ko=wo.lineNumber,zo=wo.column,bo=oo.length;for(let Io=0;Io<bo;Io++){const Qo=oo[Io].range;if(Qo.startLineNumber===Ko&&Qo.startColumn===zo||Qo.endLineNumber===Ko&&Qo.endColumn===zo)return it.pushStackElement(),!0}})},po=function(ko){typeof ko=="function"&&it._editableRangeChangeListener.push(ko)},fo=function(ko,wo){const Ko=ao();it._editableRangeChangeListener.forEach(function(zo){zo.call(it,ko,wo,Ko)})},mo=function(){return Promise.resolve().then(function(){it.editInRestrictedArea=!0,it.undo(),it.editInRestrictedArea=!1,it._hasHighlight&&it._oldDecorationsSource&&(it.deltaDecorations(it._oldDecorations,it._oldDecorationsSource),it._oldDecorationsSource.forEach(function(ko){ko.range=it.getDecorationRange(ko.id)}))})},So=function(ko,wo,Ko,zo,bo,Io){let Qo=wo.endLineNumber,Zo=wo.endColumn;ko.prevRange=wo,ko.range=wo.setEndPosition(Ko,zo);const ui=oo.length;let ai=bo.length;const si=zo-Zo,di=Ko-Qo,Fo=it._currentCursorPositions||[],oi=Fo.length;if(ai!==oi&&(bo=bo.filter(function(ei){const ri=ei.range;for(let ci=0;ci<oi;ci++){const hi=Fo[ci];if(ri.startLineNumber===hi.startLineNumber&&ri.endLineNumber===hi.endLineNumber&&ri.startColumn===hi.startColumn&&ri.endColumn===hi.endColumn)return!0}return!1}),ai=bo.length),di!==0){for(let ei=ko.index+1;ei<ui;ei++){const ri=oo[ei],ci=ri.range;Qo===ci.startLineNumber&&(ci.startColumn+=si),Qo===ci.endLineNumber&&(ci.endColumn+=si),ci.startLineNumber+=di,ci.endLineNumber+=di,ri.range=ci}for(let ei=Io+1;ei<ai;ei++){const ri=bo[ei],ci=ri.range,hi=ci.toString(),yi=rangeMap[hi];delete rangeMap[hi],Qo===ci.startLineNumber&&(ci.startColumn+=si),Qo===ci.endLineNumber&&(ci.endColumn+=si),ci.startLineNumber+=di,ci.endLineNumber+=di,ri.range=ci,rangeMap[ci.toString()]=yi}}else{for(let ei=ko.index+1;ei<ui;ei++){const ri=oo[ei],ci=ri.range;if(ci.startLineNumber>Qo)break;ci.startColumn+=si,ci.endColumn+=si,ri.range=ci}for(let ei=Io+1;ei<ai;ei++){const ri=bo[ei],ci=ri.range,hi=ci.toString(),yi=rangeMap[hi];if(delete rangeMap[hi],ci.startLineNumber>Qo){rangeMap[ci.toString()]=yi;break}else ci.startColumn+=si,ci.endColumn+=si,ri.range=ci,rangeMap[ci.toString()]=yi}}},ho=function(ko,wo){const Ko={},zo=ko.range;return ko.text===""?Ko.isDeletion=!0:zo.startLineNumber===zo.endLineNumber&&zo.startColumn===zo.endColumn?Ko.isAddition=!0:Ko.isReplacement=!0,Ko.startLineOfRange=zo.startLineNumber===wo.startLineNumber,Ko.startColumnOfRange=zo.startColumn===wo.startColumn,Ko.endLineOfRange=zo.endLineNumber===wo.endLineNumber,Ko.endColumnOfRange=zo.endColumn===wo.endColumn,Ko.middleLineOfRange=!Ko.startLineOfRange&&!Ko.endLineOfRange,wo.startLineNumber===wo.endLineNumber?Ko.rangeIsSingleLine=!0:Ko.rangeIsMultiLine=!0,Ko},yo=function(ko){oo=deepClone(ko).sort(Zn),io(oo)},go=function(){if(it._hasHighlight)it.deltaDecorations(it._oldDecorations,[]),delete it._oldDecorations,delete it._oldDecorationsSource,it._hasHighlight=!1;else{const ko=oo.map(function(wo){const Ko={range:wo.range,options:{className:wo.allowMultiline?enums.MULTI_LINE_HIGHLIGHT_CLASS:enums.SINGLE_LINE_HIGHLIGHT_CLASS}};return wo.label&&(Ko.hoverMessage=wo.label),Ko});it._oldDecorations=it.deltaDecorations([],ko),it._oldDecorationsSource=ko.map(function(wo,Ko){return Object.assign({},wo,{id:it._oldDecorations[Ko]})}),it._hasHighlight=!0}},vo=function(){console.debug("handler for unhandled promise rejection")},xo=function(ko){for(let wo in ko){const Ko=ko[wo];Ko.range=Ko.prevRange}},Vo=function(ko,wo){return!ko.allowMultiline&&wo.includes(`
198
198
  `)},ti=function(ko,wo,Ko){return ko.validate&&!ko.validate(wo,Ko,ko.lastInfo)},ni={_isRestrictedModel:!0,_isRestrictedValueValid:!0,_editableRangeChangeListener:[],_isCursorAtCheckPoint:uo,_currentCursorPositions:[]};io(oo),it._hasHighlight=!1,ni._restrictionChangeListener=it.onDidChangeContent(function(ko){const wo=ko.isUndoing;if(it._isRestrictedValueValid=!0,wo&&it.editInRestrictedArea)it.editInRestrictedArea&&(it._isRestrictedValueValid=!1);else{const Ko=ko.changes.sort(Zn),zo={},bo=oo.length;if(Ko.every(function(Io){const Qo=Io.range,Zo=Qo.toString();zo[Zo]=null;for(let ui=0;ui<bo;ui++){const ai=oo[ui];if(ai.range.containsRange(Qo))return Vo(ai,Io.text)?!1:(zo[Zo]=ai,!0)}return!1})){Ko.forEach(function(Zo,ui){const ai=Zo.range,si=zo[ai.toString()],di=si.range,Fo=Zo.text||"",oi=(Fo.match(/\n/g)||[]).length,ei=Fo.split(/\n/g).pop().length,ri=ai.endLineNumber-ai.startLineNumber,ci=ai.endColumn-ai.startColumn;let hi=di.endLineNumber,yi=di.endColumn,$i=0;(di.endLineNumber===ai.startLineNumber||di.endLineNumber===ai.endLineNumber)&&($i+=di.endColumn-ai.startColumn+1);const mi=ho(Zo,di);si.lastInfo=mi,(mi.isAddition||mi.isReplacement)&&(mi.rangeIsSingleLine&&(oi===0?yi+=ei:(hi+=oi,mi.startColumnOfRange?yi+=ei:mi.endColumnOfRange?yi=ei+1:yi=ei+$i)),mi.rangeIsMultiLine&&(hi+=oi,mi.endLineOfRange&&(oi===0?yi+=ei:yi=$i+ei))),(mi.isDeletion||mi.isReplacement)&&(mi.rangeIsSingleLine&&(yi-=ci),mi.rangeIsMultiLine&&(mi.endLineOfRange?(hi-=ri,yi-=ci):hi-=ri)),So(si,di,hi,yi,Ko,ui)});const Io=it.getValueInEditableRanges(),Qo={};for(let Zo in zo){const ui=zo[Zo],ai=ui.range,si=ui.label||ai.toString(),di=Io[si];if(ti(ui,di,ai)){xo(zo),mo();return}Qo[si]=di}it._hasHighlight&&it._oldDecorationsSource.forEach(function(Zo){Zo.range=it.getDecorationRange(Zo.id)}),fo(Qo,Io)}else mo()}}),window.onerror=vo;const No={editInRestrictedArea:!1,getCurrentEditableRanges:ao,getValueInEditableRanges:so,disposeRestrictions:co,onDidChangeContentInEditableRange:po,updateRestrictions:yo,updateValueInEditableRanges:lo,toggleHighlightOfEditableAreas:go};for(let ko in ni)Object.defineProperty(it,ko,{enumerable:!1,configurable:!0,writable:!0,value:ni[ko]});for(let ko in No)Object.defineProperty(it,ko,{enumerable:!1,configurable:!0,writable:!0,value:No[ko]});return it};function constrainedEditor(it){if(it===void 0)throw new Error(["Please pass the monaco global variable into function as","(eg:)constrainedEditor({ range : monaco.range });"].join(`
199
199
  `));const ct=function(fo){const mo=fo.getModel();if(mo._isCursorAtCheckPoint){const So=fo.getSelections(),ho=So.map(function(yo){return{lineNumber:yo.positionLineNumber,column:yo.positionColumn}});mo._isCursorAtCheckPoint(ho),mo._currentCursorPositions=So}},Ot={},{isInstanceValid:qt,isModelValid:Zn,isRangesValid:no}=validators.initWith(it),oo=function(fo){if(qt(fo)){let mo=fo.getDomNode();return co._listener=ct.bind(uo,fo),co._editorInstance=fo,co._editorInstance._isInDevMode=!1,mo.addEventListener("keydown",co._listener,!0),co._onChangeModelDisposable=fo.onDidChangeModel(function(){mo&&mo.removeEventListener("keydown",co._listener,!0);const So=fo.getDomNode();So&&So.addEventListener("keydown",co._listener,!0),mo=So}),!0}else throw new Error(TypeMustBe("ICodeEditor","editorInstance","This type interface can be found in monaco editor documentation"))},io=function(fo,mo){if(Zn(fo))if(no(mo)){const So=constrainedModel(fo,mo,it);return Ot[So.uri.toString()]=So,So}else throw new Error(TypeMustBe("Array<RangeRestrictionObject>","ranges","Please refer constrained editor documentation for proper structure"));else throw new Error(TypeMustBe("ICodeEditor","editorInstance","This type interface can be found in monaco editor documentation"))},ao=function(fo){if(Zn(fo)){const mo=fo.uri.toString(),So=Ot[mo];return So?So.disposeRestrictions():(console.warn("Current Model is not a restricted Model"),!1)}else throw new Error(TypeMustBe("ICodeEditor","editorInstance","This type interface can be found in monaco editor documentation"))},so=function(){if(co._editorInstance){const fo=co._editorInstance.getDomNode();fo&&fo.removeEventListener("keydown",co._listener),co._onChangeModelDisposable&&co._onChangeModelDisposable.dispose(),delete co._listener,delete co._editorInstance._isInDevMode,delete co._editorInstance._devModeAction,delete co._editorInstance,delete co._onChangeModelDisposable;for(let mo in Ot)delete Ot[mo];return!0}return!1},lo=function(){co._editorInstance._isInDevMode?(co._editorInstance._isInDevMode=!1,co._editorInstance._devModeAction.dispose(),delete co._editorInstance._devModeAction):(co._editorInstance._isInDevMode=!0,co._editorInstance._devModeAction=co._editorInstance.addAction({id:"showRange",label:"Show Range in console",contextMenuGroupId:"navigation",contextMenuOrder:1.5,run:function(fo){const mo=fo.getSelections().reduce(function(So,{startLineNumber:ho,endLineNumber:yo,startColumn:go,endColumn:vo}){return So.push("range : "+JSON.stringify([ho,go,yo,vo])),So},[]).join(`
200
200
  `);console.log(`Selected Ranges :
201
- `+JSON.stringify(mo,null,2))}}))},co={_listener:null,_editorInstance:null,_uriRestrictionMap:Ot,_injectedResources:it},uo=Object.create(co),po={initializeIn:oo,addRestrictionsTo:io,removeRestrictionsIn:ao,disposeConstrainer:so,toggleDevMode:lo};for(let fo in po)Object.defineProperty(uo,fo,{enumerable:!1,writable:!1,configurable:!1,value:po[fo]});return Object.freeze(uo)}const SchemaEditor=P$3(async()=>({default:(await __vitePreload(()=>import("./index-CnxM4IIa-CvFEW5IC.js"),__vite__mapDeps([3,1,2,0])).then(it=>it.i)).SchemaEditor})),GraphQLEditor=({schema:it,theme:ct,restrictions:Ot,...qt})=>jsxRuntimeExports.jsx(SchemaEditor,{defaultValue:it,height:100,line:2,schema:"type Test { name: String }",theme:`vs-${ct}`,...qt,onMount:(Zn,no)=>{if(!Ot)return;const oo=constrainedEditor(no),io=Zn.getModel();oo.initializeIn(Zn),oo.addRestrictionsTo(io,Ot)},options:{lineNumbers:"off",lineNumbersMinChars:0,minimap:{enabled:!1},automaticLayout:!0,...qt.options}}),SPLIT_LOWER_UPPER_RE=new RegExp("([\\p{Ll}\\d])(\\p{Lu})","gu"),SPLIT_UPPER_UPPER_RE=new RegExp("(\\p{Lu})([\\p{Lu}][\\p{Ll}])","gu"),SPLIT_SEPARATE_NUMBER_RE=new RegExp("(\\d)\\p{Ll}|(\\p{L})\\d","u"),DEFAULT_STRIP_REGEXP$1=/[^\p{L}\d]+/giu,SPLIT_REPLACE_VALUE="$1\0$2",DEFAULT_PREFIX_SUFFIX_CHARACTERS="";function split(it){let ct=it.trim();ct=ct.replace(SPLIT_LOWER_UPPER_RE,SPLIT_REPLACE_VALUE).replace(SPLIT_UPPER_UPPER_RE,SPLIT_REPLACE_VALUE),ct=ct.replace(DEFAULT_STRIP_REGEXP$1,"\0");let Ot=0,qt=ct.length;for(;ct.charAt(Ot)==="\0";)Ot++;if(Ot===qt)return[];for(;ct.charAt(qt-1)==="\0";)qt--;return ct.slice(Ot,qt).split(/\0/g)}function splitSeparateNumbers(it){const ct=split(it);for(let Ot=0;Ot<ct.length;Ot++){const qt=ct[Ot],Zn=SPLIT_SEPARATE_NUMBER_RE.exec(qt);if(Zn){const no=Zn.index+(Zn[1]??Zn[2]).length;ct.splice(Ot,1,qt.slice(0,no),qt.slice(no))}}return ct}function pascalCase$2(it,ct){const[Ot,qt,Zn]=splitPrefixSuffix(it,ct),no=lowerFactory(void 0),oo=upperFactory(void 0),io=pascalCaseTransformFactory(no,oo);return Ot+qt.map(io).join("")+Zn}function lowerFactory(it){return ct=>ct.toLocaleLowerCase(it)}function upperFactory(it){return ct=>ct.toLocaleUpperCase(it)}function pascalCaseTransformFactory(it,ct){return(Ot,qt)=>{const Zn=Ot[0];return(qt>0&&Zn>="0"&&Zn<="9"?"_"+Zn:ct(Zn))+it(Ot.slice(1))}}function splitPrefixSuffix(it,ct={}){const Ot=ct.split??(ct.separateNumbers?splitSeparateNumbers:split),qt=ct.prefixCharacters??DEFAULT_PREFIX_SUFFIX_CHARACTERS,Zn=ct.suffixCharacters??DEFAULT_PREFIX_SUFFIX_CHARACTERS;let no=0,oo=it.length;for(;no<it.length;){const io=it.charAt(no);if(!qt.includes(io))break;no++}for(;oo>no;){const io=oo-1,ao=it.charAt(io);if(!Zn.includes(ao))break;oo=io}return[it.slice(0,no),Ot(it.slice(no,oo)),it.slice(oo)]}const scopes=["global","local"],getSchemaAndRestrictions=(it,ct)=>{const Ot=`input ${pascalCase$2(ct||"")}Input {`;if(!it)return{restrictions:[{range:[1,1,1,1],allowMultiline:!0},{range:[2,1,6,1],allowMultiline:!0}],schema:`${Ot}
201
+ `+JSON.stringify(mo,null,2))}}))},co={_listener:null,_editorInstance:null,_uriRestrictionMap:Ot,_injectedResources:it},uo=Object.create(co),po={initializeIn:oo,addRestrictionsTo:io,removeRestrictionsIn:ao,disposeConstrainer:so,toggleDevMode:lo};for(let fo in po)Object.defineProperty(uo,fo,{enumerable:!1,writable:!1,configurable:!1,value:po[fo]});return Object.freeze(uo)}const SchemaEditor=P$3(async()=>({default:(await __vitePreload(()=>import("./index-CnxM4IIa-CoekJPsT.js"),__vite__mapDeps([3,1,2,0])).then(it=>it.i)).SchemaEditor})),GraphQLEditor=({schema:it,theme:ct,restrictions:Ot,...qt})=>jsxRuntimeExports.jsx(SchemaEditor,{defaultValue:it,height:100,line:2,schema:"type Test { name: String }",theme:`vs-${ct}`,...qt,onMount:(Zn,no)=>{if(!Ot)return;const oo=constrainedEditor(no),io=Zn.getModel();oo.initializeIn(Zn),oo.addRestrictionsTo(io,Ot)},options:{lineNumbers:"off",lineNumbersMinChars:0,minimap:{enabled:!1},automaticLayout:!0,...qt.options}}),SPLIT_LOWER_UPPER_RE=new RegExp("([\\p{Ll}\\d])(\\p{Lu})","gu"),SPLIT_UPPER_UPPER_RE=new RegExp("(\\p{Lu})([\\p{Lu}][\\p{Ll}])","gu"),SPLIT_SEPARATE_NUMBER_RE=new RegExp("(\\d)\\p{Ll}|(\\p{L})\\d","u"),DEFAULT_STRIP_REGEXP$1=/[^\p{L}\d]+/giu,SPLIT_REPLACE_VALUE="$1\0$2",DEFAULT_PREFIX_SUFFIX_CHARACTERS="";function split(it){let ct=it.trim();ct=ct.replace(SPLIT_LOWER_UPPER_RE,SPLIT_REPLACE_VALUE).replace(SPLIT_UPPER_UPPER_RE,SPLIT_REPLACE_VALUE),ct=ct.replace(DEFAULT_STRIP_REGEXP$1,"\0");let Ot=0,qt=ct.length;for(;ct.charAt(Ot)==="\0";)Ot++;if(Ot===qt)return[];for(;ct.charAt(qt-1)==="\0";)qt--;return ct.slice(Ot,qt).split(/\0/g)}function splitSeparateNumbers(it){const ct=split(it);for(let Ot=0;Ot<ct.length;Ot++){const qt=ct[Ot],Zn=SPLIT_SEPARATE_NUMBER_RE.exec(qt);if(Zn){const no=Zn.index+(Zn[1]??Zn[2]).length;ct.splice(Ot,1,qt.slice(0,no),qt.slice(no))}}return ct}function pascalCase$2(it,ct){const[Ot,qt,Zn]=splitPrefixSuffix(it,ct),no=lowerFactory(void 0),oo=upperFactory(void 0),io=pascalCaseTransformFactory(no,oo);return Ot+qt.map(io).join("")+Zn}function lowerFactory(it){return ct=>ct.toLocaleLowerCase(it)}function upperFactory(it){return ct=>ct.toLocaleUpperCase(it)}function pascalCaseTransformFactory(it,ct){return(Ot,qt)=>{const Zn=Ot[0];return(qt>0&&Zn>="0"&&Zn<="9"?"_"+Zn:ct(Zn))+it(Ot.slice(1))}}function splitPrefixSuffix(it,ct={}){const Ot=ct.split??(ct.separateNumbers?splitSeparateNumbers:split),qt=ct.prefixCharacters??DEFAULT_PREFIX_SUFFIX_CHARACTERS,Zn=ct.suffixCharacters??DEFAULT_PREFIX_SUFFIX_CHARACTERS;let no=0,oo=it.length;for(;no<it.length;){const io=it.charAt(no);if(!qt.includes(io))break;no++}for(;oo>no;){const io=oo-1,ao=it.charAt(io);if(!Zn.includes(ao))break;oo=io}return[it.slice(0,no),Ot(it.slice(no,oo)),it.slice(oo)]}const scopes=["global","local"],getSchemaAndRestrictions=(it,ct)=>{const Ot=`input ${pascalCase$2(ct||"")}Input {`;if(!it)return{restrictions:[{range:[1,1,1,1],allowMultiline:!0},{range:[2,1,6,1],allowMultiline:!0}],schema:`${Ot}
202
202
  # add your code here
203
203
  }
204
204
 
@@ -449,7 +449,7 @@ To disable this validator, use:
449
449
  `.trimEnd()).join(""),so=Zn.replace("Definition","").toLowerCase();throw new Error(`Not all ${so}s have an unique name: ${io.join(", ")}:
450
450
 
451
451
  ${ao}
452
- `)}}}typeof window<"u"&&(window.z=f$3,typeof process<"u"&&(process.hrtime=()=>[0,0]),window.process=window.process||{hrtime:()=>[0,0]},window.global=window);async function codegen(it){const ct=parse(it),Ot=await __vitePreload(()=>import("./index-Dc3srWFp-Dj58lFaD.js"),__vite__mapDeps([4,5,1,2,6])),qt=await __vitePreload(()=>import("./index-8PbnK2go-D-EdohcU.js"),__vite__mapDeps([7,5,1,2,6,8])),Zn=await __vitePreload(()=>import("./typescript-e2Impz-Y-ZFE3ath_.js"),__vite__mapDeps([9,1,2,8,6])).then(io=>io.t);let no=await codegen$1({schema:ct,filename:"types.ts",documents:[],config:{},plugins:[{typescript:{avoidOptionals:{field:!0},maybeValue:"T"}},{"typescript-validation-schema":{schema:"zod",withObjectType:!0}}],pluginMap:{typescript:Ot,"typescript-validation-schema":qt}});no=no.replace("import { z } from 'zod'","").replace("nullish","nullable"),console.log(no);const oo=Zn.transpileModule(no,{compilerOptions:{module:Zn.ModuleKind.ES2020}});return URL.createObjectURL(new Blob([String.raw({raw:oo.outputText})],{type:"text/javascript"}))}const typeRegexp=/^type (\S*State)( })?/g,normalizeSchema=(it,ct,Ot)=>{const qt=ct==="local"?"Local":"",Zn=ct==="global"?` {
452
+ `)}}}typeof window<"u"&&(window.z=f$3,typeof process<"u"&&(process.hrtime=()=>[0,0]),window.process=window.process||{hrtime:()=>[0,0]},window.global=window);async function codegen(it){const ct=parse(it),Ot=await __vitePreload(()=>import("./index-Dc3srWFp-DVPU56zP.js"),__vite__mapDeps([4,5,1,2,6])),qt=await __vitePreload(()=>import("./index-8PbnK2go-BoR1WEku.js"),__vite__mapDeps([7,5,1,2,6,8])),Zn=await __vitePreload(()=>import("./typescript-e2Impz-Y-eyfqYqVi.js"),__vite__mapDeps([9,1,2,8,6])).then(io=>io.t);let no=await codegen$1({schema:ct,filename:"types.ts",documents:[],config:{},plugins:[{typescript:{avoidOptionals:{field:!0},maybeValue:"T"}},{"typescript-validation-schema":{schema:"zod",withObjectType:!0}}],pluginMap:{typescript:Ot,"typescript-validation-schema":qt}});no=no.replace("import { z } from 'zod'","").replace("nullish","nullable"),console.log(no);const oo=Zn.transpileModule(no,{compilerOptions:{module:Zn.ModuleKind.ES2020}});return URL.createObjectURL(new Blob([String.raw({raw:oo.outputText})],{type:"text/javascript"}))}const typeRegexp=/^type (\S*State)( })?/g,normalizeSchema=(it,ct,Ot)=>{const qt=ct==="local"?"Local":"",Zn=ct==="global"?` {
453
453
 
454
- }`:"";return it?it.includes(`type ${pascalCase$2(Ot)}${qt}State {`)?it||"":it.replace(typeRegexp,(no,oo)=>no.replace(oo,`${pascalCase$2(Ot)}${qt}State`)):`type ${pascalCase$2(Ot)}${qt}State${Zn}`};function EditorSchema({name:it,onGenerate:ct,theme:Ot,scope:qt,value:Zn,...no}){const oo=reactExports.useRef(null),[io,ao]=reactExports.useState(Zn||"");reactExports.useEffect(()=>{const fo=normalizeSchema(Zn,qt,it);fo!==io&&ao(fo)},[Zn,it]);const[so,lo]=reactExports.useState(),[co,uo]=reactExports.useState();async function po(fo,mo){codegen(fo).then(So=>{import(So).then(ho=>{const yo=`${mo}StateSchema`,go=ho[yo];uo(go),ct({documentName:mo,schema:fo,validator:go})})})}return reactExports.useEffect(()=>{if(!oo.current)return;const fo=oo.current.onDidBlurEditorText(()=>{var mo;const So=(mo=oo.current)==null?void 0:mo.getValue();So&&po(So,it)});return()=>fo.dispose()},[it,oo.current]),jsxRuntimeExports.jsx("div",{children:jsxRuntimeExports.jsx(SchemaEditor,{height:"60vh",onSchemaChange:fo=>lo(fo),theme:`vs-${Ot}`,width:"100%",...no,onChange:fo=>ao(fo??""),onMount:(fo,mo)=>{var So;oo.current=fo,(So=no.onMount)==null||So.call(no,fo,mo)},options:{lineNumbers:"off",lineNumbersMinChars:0,minimap:{enabled:!1},automaticLayout:!0,...no.options},value:io})})}function EditorInitialState({validator:it,onCreate:ct,theme:Ot,setInitialValue:qt,...Zn}){const[no,oo]=reactExports.useState(Zn.value||"{}"),io=reactExports.useRef(null);reactExports.useEffect(()=>{io.current&&io.current.onDidBlurEditorText(lo=>{var co;const uo=((co=io.current)==null?void 0:co.getValue())??"{}";ct(uo)})},[io.current]),reactExports.useEffect(()=>{qt&&!isJSONEqual(JSON.parse(Zn.value||"{}"),no)&&oo(Zn.value||"{}")},[qt,Zn.value]);let ao="",so=!1;try{const lo=JSON.parse(no);it&&(so=it().strict().safeParse(lo).success,so||(ao="Invalid initial state"))}catch{ao="Invalid JSON"}return jsxRuntimeExports.jsxs("div",{children:[jsxRuntimeExports.jsx(CodeEditor,{height:"60vh",language:"json",onChange:lo=>oo(lo??""),theme:`vs-${Ot}`,width:"100%",...Zn,onMount:async(lo,co)=>{var uo;io.current=lo,(uo=Zn.onMount)==null||uo.call(Zn,lo,co),setTimeout(async()=>{var po;try{await((po=lo.getAction("editor.action.formatDocument"))==null?void 0:po.run())}catch(fo){console.error(fo)}},50)},options:{lineNumbers:"off",lineNumbersMinChars:0,minimap:{enabled:!1},automaticLayout:!0,...Zn.options},value:no}),jsxRuntimeExports.jsx("p",{style:{minHeight:20,marginTop:10,fontSize:"1.1rem",color:"red"},children:ao})]})}function EditorState(it){const{name:ct,theme:Ot,setStateSchema:qt,scope:Zn,schemaHandlers:no,latestOperation:oo}=it,{setInitialValue:io,setSchemaState:ao,schemaState:so,specification:lo}=no,co=Zn==="local"?"Local":"Global";return jsxRuntimeExports.jsxs("div",{style:{display:"flex",alignItems:"flex-start"},children:[jsxRuntimeExports.jsxs("div",{style:{width:"50%",display:"inline-block"},children:[jsxRuntimeExports.jsx("h4",{style:{marginBottom:"16px"},children:`${co} State Schema`}),jsxRuntimeExports.jsx(EditorSchema,{height:200,name:ct,onGenerate:uo=>{ao(po=>({...po,...uo})),uo.schema!==(lo==null?void 0:lo.state[Zn].schema)&&qt(uo.schema,Zn)},scope:Zn,theme:Ot,value:lo==null?void 0:lo.state[Zn].schema})]}),jsxRuntimeExports.jsxs("div",{style:{width:"50%",display:"inline-block"},children:[jsxRuntimeExports.jsx("h4",{style:{marginBottom:"16px"},children:`${co} Initial State`}),jsxRuntimeExports.jsx(EditorInitialState,{height:200,onCreate:uo=>{io(JSON.parse(uo))},setInitialValue:(oo==null?void 0:oo.type)==="SET_INITIAL_STATE"&&oo.scope===Zn,theme:Ot,validator:so==null?void 0:so.validator,value:lo==null?void 0:lo.state[Zn].initialValue})]})]})}function Editor(it){const ct=it.context.theme||"light",Ot=colorScheme$1[ct],qt={backgroundColor:Ot.bgColor,color:Ot.color,maxWidth:"60em",margin:"1em auto",padding:"6em",border:"2px solid "+Ot.border,boxShadow:"2px 2px 2px "+Ot.shadow,fontFamily:"Roboto, sans-serif",position:"relative"},{document:Zn,dispatch:no}=it,{state:oo}=Zn,io=Zn.operations.global[Zn.operations.global.length-1],ao=wo=>{no(actions.setModelId({id:wo}))},so=wo=>{no(actions.setModelDescription({description:wo}))},lo=wo=>{no(actions.setModelExtension({extension:wo}))},co=wo=>{no(actions.setModelName({name:wo})),no(actions.setName(wo))},uo=wo=>{no(actions.setAuthorName({authorName:wo}))},po=wo=>{no(actions.setAuthorWebsite({authorWebsite:wo}))},fo=(wo,Ko)=>{no(actions.setStateSchema({schema:wo,scope:Ko}))},mo=(wo,Ko)=>{no(actions.setInitialState({initialValue:wo,scope:Ko}))},So=wo=>{no(actions.addModule({id:index.hashKey(),name:wo}))},ho=(wo,Ko)=>{no(actions.setModuleName({id:wo,name:Ko}))},yo=(wo,Ko)=>{no(actions.setModuleDescription({id:wo,description:Ko}))},go=wo=>{no(actions.deleteModule({id:wo}))},vo=(wo,Ko)=>{no(actions.addOperation({id:index.hashKey(),moduleId:wo,name:Ko}))},xo=(wo,Ko)=>{no(actions.setOperationName({id:wo,name:Ko}))},Vo=(wo,Ko)=>{no(actions.setOperationSchema({id:wo,schema:Ko}))},ti=(wo,Ko)=>{no(actions.setOperationScope({id:wo,scope:Ko}))},ni=wo=>{no(actions.deleteOperation({id:wo}))},No=useSchemaEditor({state:oo,scope:"global",setInitialState:mo,latestOperation:io}),ko=useSchemaEditor({state:oo,scope:"local",setInitialState:mo,latestOperation:io});return jsxRuntimeExports.jsxs("div",{style:{...qt,minHeight:"70em"},children:[jsxRuntimeExports.jsx(TextInput,{autoFocus:!0,clearOnSubmit:!1,onSubmit:co,placeholder:"Document Model Name",size:"larger",theme:ct,value:oo.global.name},"modelName"),jsxRuntimeExports.jsx("div",{style:{width:"50%",display:"inline-block"},children:jsxRuntimeExports.jsx(TextInput,{autoFocus:!1,clearOnSubmit:!1,onSubmit:ao,placeholder:"Model Type",size:"small",theme:ct,value:oo.global.id},"modelId")}),jsxRuntimeExports.jsx(TextInput,{autoFocus:!1,clearOnSubmit:!1,onSubmit:so,placeholder:"Model Description",theme:ct,value:oo.global.description},"modelDescription"),jsxRuntimeExports.jsx("div",{style:{width:"50%",display:"inline-block"},children:jsxRuntimeExports.jsx(TextInput,{autoFocus:!1,clearOnSubmit:!1,onSubmit:lo,placeholder:"File Extension(s)",size:"small",theme:ct,value:oo.global.extension},"modelExtension")}),jsxRuntimeExports.jsxs("div",{children:[jsxRuntimeExports.jsx("p",{style:{...typographySizes$1.tiny},children:"Author"}),jsxRuntimeExports.jsx("div",{style:{width:"50%",display:"inline-block"},children:jsxRuntimeExports.jsx(TextInput,{autoFocus:!1,clearOnSubmit:!1,onSubmit:uo,placeholder:"Author Name",size:"small",theme:ct,value:oo.global.author.name},"authorName")}),jsxRuntimeExports.jsx("div",{style:{width:"50%",display:"inline-block"},children:jsxRuntimeExports.jsx(TextInput,{autoFocus:!1,clearOnSubmit:!1,onSubmit:po,placeholder:"https://",size:"small",theme:ct,value:oo.global.author.website||""},"authorWebsite")})]}),No.specification?jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(EditorState,{latestOperation:io,name:Zn.state.global.name,schemaHandlers:No,scope:"global",setStateSchema:fo,theme:ct}),jsxRuntimeExports.jsx(EditorState,{latestOperation:io,name:Zn.state.global.name,schemaHandlers:ko,scope:"local",setStateSchema:fo,theme:ct}),No.specification.modules.map(wo=>jsxRuntimeExports.jsxs("div",{children:[jsxRuntimeExports.jsx(TextInput,{autoFocus:!1,clearOnSubmit:!1,horizontalLine:!0,onEmpty:()=>go(wo.id),onSubmit:Ko=>ho(wo.id,Ko),placeholder:"Module Name",size:"large",theme:ct,value:wo.name},wo.id+"#name"),jsxRuntimeExports.jsx(TextInput,{autoFocus:!1,clearOnSubmit:!1,onSubmit:Ko=>yo(wo.id,Ko),placeholder:"Module "+wo.name+" description",size:"small",theme:ct,value:wo.description||""},wo.id+"#description"),wo.operations.map(Ko=>jsxRuntimeExports.jsx(EditorOperation,{id:Ko.id,name:Ko.name,onDelete:ni,onUpdateName:xo,onUpdateSchema:Vo,onUpdateScope:ti,schema:Ko.schema,scope:Ko.scope,theme:ct},Ko.id)),jsxRuntimeExports.jsx(TextInput,{autoFocus:!1,clearOnSubmit:!0,onSubmit:Ko=>vo(wo.id,Ko),placeholder:"Add operation...",size:"medium",theme:ct},wo.id+"#newOperation")]},wo.id))]}):null,jsxRuntimeExports.jsx(TextInput,{autoFocus:!1,clearOnSubmit:!0,horizontalLine:!0,onSubmit:So,placeholder:"Module Name",size:"large",theme:ct},"newModule")]})}const editor=Object.freeze(Object.defineProperty({__proto__:null,default:Editor},Symbol.toStringTag,{value:"Module"})),editor$1=Object.freeze(Object.defineProperty({__proto__:null,$:keysIn_1,A:specifiedRules,B:ExecutableDefinitionsRule,C:validate,D:DocumentEditor,E:EditorToolbar,F:NoDeprecatedCustomRule,G:GraphQLEnumType,H:GraphQLNonNull,I:removeFederation,J:JSONEditor,get K(){return Kind},L:extendSchema,M:getCachedDocumentNodeFromSchema,N:NoUnusedFragmentsRule,O:oldVisit,P:printIntrospectionSchema,Q:isObjectType,R:visitWithTypeInfo,S:SchemaMetaFieldDef,T:ToolbarButton,U:isIntrospectionType,V:TypeInfo,W:_isPrototype,X:_arrayLikeKeys,Y:isArrayLike_1,Z:_copyObject,_:_overArg,a:EditorWorksheet,a0:_getPrototype,a1:isArray_1,a2:_getNative,a3:_root,a4:_Map,a5:_baseGetTag,a6:require_toSource,a7:_cloneArrayBuffer,a8:_Symbol,a9:_cloneTypedArray,aA:specifiedScalarTypes,aB:buildSchema,aC:printSchema,aD:isInputObjectType,aE:isScalarType,get aF(){return pascalCase},aG:resolveExternalModuleAndFn,aH:isEnumType,aI:styles,aJ:stylesVariant,aK:wrapReducer,aL:createUseDocumentReducer,aM:useDocumentReducer,aN:createDocumentStory,aO:editor,aa:isObjectLike_1,ab:_nodeUtilExports,ac:_baseUnary,ad:_Stack,ae:_assignValue,af:_cloneBufferExports,ag:_copyArray,ah:_initCloneObject,ai:isBufferExports,aj:isObject_1,ak:_baseFor,al:identity_1,am:_MapCache,an:_Uint8Array,ao:eq_1,ap:isTypedArray_1,aq:isArguments_1,ar:_isIndex,as:isLength_1,at:_baseCreate,au:isFunction_1,av:_baseRest,aw:isArrayLikeObject_1,ax:requireConstant,ay:isSpecifiedScalarType,az:valueFromASTUntyped,b:TextInput,c:TextInputVariant,d:buildClientSchema,e:buildASTSchema,f:TypeMetaFieldDef,g:getIntrospectionQuery,h:TypeNameMetaFieldDef,i:isCompositeType,j:getNamedType,k:GraphQLBoolean,l:isInterfaceType,m:GraphQLInterfaceType,n:GraphQLObjectType,o:isAbstractType,p:assertAbstractType,q:doTypesOverlap,r:isInputType,get s(){return DirectiveLocation},t:parse,u:isListType,v:visit,w:isNonNullType,x:GraphQLInputObjectType,y:getNullableType,z:GraphQLList},Symbol.toStringTag,{value:"Module"})),l$1={Component:P$3(()=>__vitePreload(()=>import("./editor-C6Um7TKF.js"),__vite__mapDeps([10,1,2]))),documentTypes:["*"],config:{id:"json-editor",disableExternalControls:!1}},a={Component:P$3(()=>__vitePreload(()=>import("./editor-ZZR7pxvt.js"),__vite__mapDeps([11,1,2]))),documentTypes:["powerhouse/budget-statement"],config:{id:"budget-statement-editor",disableExternalControls:!1}},l={Component:P$3(()=>__vitePreload(()=>Promise.resolve().then(()=>editor$1),void 0).then(it=>it.aO)),documentTypes:["powerhouse/document-model"],config:{id:"document-model-editor",disableExternalControls:!1}},i={Component:P$3(()=>__vitePreload(()=>import("./editor-B8aF84QX.js"),__vite__mapDeps([12,1,2]))),documentTypes:["makerdao/scope-framework"],config:{id:"scope-framework-editor",disableExternalControls:!1}},p={Component:P$3(()=>__vitePreload(()=>import("./editor-D1liwP8t.js"),__vite__mapDeps([13,1,2])).then(it=>it.e)),documentTypes:["makerdao/rwa-portfolio"],config:{id:"rwa-editor",disableExternalControls:!0}},editors=Object.freeze(Object.defineProperty({__proto__:null,BudgetStatement:a,DocumentModel:l,Json:l$1,RealWorldAssets:p,ScopeFramework:i},Symbol.toStringTag,{value:"Module"}));export{isSpecifiedScalarType as $,isListType as A,isNonNullType as B,specifiedRules as C,DocumentEditor as D,EditorToolbar as E,NoUnusedFragmentsRule as F,GraphQLNonNull as G,ExecutableDefinitionsRule as H,oldVisit as I,JSONEditor as J,Kind as K,TypeInfo as L,printIntrospectionSchema as M,NoDeprecatedCustomRule as N,isObjectType as O,removeFederation as P,extendSchema as Q,getCachedDocumentNodeFromSchema as R,SchemaMetaFieldDef as S,ToolbarButton as T,visitWithTypeInfo as U,isIntrospectionType as V,requireConstant as W,isArray_1 as X,isFunction_1 as Y,buildSchema as Z,printSchema as _,EditorWorksheet as a,require_toSource as a0,_baseRest as a1,isArrayLikeObject_1 as a2,_Map as a3,_baseGetTag as a4,valueFromASTUntyped as a5,specifiedScalarTypes as a6,_arrayLikeKeys as a7,isArrayLike_1 as a8,_getNative as a9,_Uint8Array as aA,eq_1 as aB,_overArg as aC,isEnumType as aD,isInputObjectType as aE,isScalarType as aF,resolveExternalModuleAndFn as aG,pascalCase as aH,editors as aI,_root as aa,_nodeUtilExports as ab,_Stack as ac,_assignValue as ad,_cloneBufferExports as ae,_copyArray as af,_initCloneObject as ag,isBufferExports as ah,isObject_1 as ai,_baseFor as aj,isArguments_1 as ak,_isIndex as al,isLength_1 as am,identity_1 as an,_isPrototype as ao,isTypedArray_1 as ap,_baseCreate as aq,_getPrototype as ar,_Symbol as as,_copyObject as at,_cloneArrayBuffer as au,_cloneTypedArray as av,_baseUnary as aw,keysIn_1 as ax,_MapCache as ay,isObjectLike_1 as az,TextInput as b,TextInputVariant as c,GraphQLList as d,buildClientSchema as e,buildASTSchema as f,getIntrospectionQuery as g,getNamedType as h,isCompositeType as i,TypeNameMetaFieldDef as j,TypeMetaFieldDef as k,GraphQLEnumType as l,GraphQLBoolean as m,isInterfaceType as n,isAbstractType as o,parse as p,assertAbstractType as q,doTypesOverlap as r,isInputType as s,DirectiveLocation as t,GraphQLInputObjectType as u,visit as v,getNullableType as w,GraphQLObjectType as x,GraphQLInterfaceType as y,validate as z};
455
- //# sourceMappingURL=editors-BvDPqtae.js.map
454
+ }`:"";return it?it.includes(`type ${pascalCase$2(Ot)}${qt}State {`)?it||"":it.replace(typeRegexp,(no,oo)=>no.replace(oo,`${pascalCase$2(Ot)}${qt}State`)):`type ${pascalCase$2(Ot)}${qt}State${Zn}`};function EditorSchema({name:it,onGenerate:ct,theme:Ot,scope:qt,value:Zn,...no}){const oo=reactExports.useRef(null),[io,ao]=reactExports.useState(Zn||"");reactExports.useEffect(()=>{const fo=normalizeSchema(Zn,qt,it);fo!==io&&ao(fo)},[Zn,it]);const[so,lo]=reactExports.useState(),[co,uo]=reactExports.useState();async function po(fo,mo){codegen(fo).then(So=>{import(So).then(ho=>{const yo=`${mo}StateSchema`,go=ho[yo];uo(go),ct({documentName:mo,schema:fo,validator:go})})})}return reactExports.useEffect(()=>{if(!oo.current)return;const fo=oo.current.onDidBlurEditorText(()=>{var mo;const So=(mo=oo.current)==null?void 0:mo.getValue();So&&po(So,it)});return()=>fo.dispose()},[it,oo.current]),jsxRuntimeExports.jsx("div",{children:jsxRuntimeExports.jsx(SchemaEditor,{height:"60vh",onSchemaChange:fo=>lo(fo),theme:`vs-${Ot}`,width:"100%",...no,onChange:fo=>ao(fo??""),onMount:(fo,mo)=>{var So;oo.current=fo,(So=no.onMount)==null||So.call(no,fo,mo)},options:{lineNumbers:"off",lineNumbersMinChars:0,minimap:{enabled:!1},automaticLayout:!0,...no.options},value:io})})}function EditorInitialState({validator:it,onCreate:ct,theme:Ot,setInitialValue:qt,...Zn}){const[no,oo]=reactExports.useState(Zn.value||"{}"),io=reactExports.useRef(null);reactExports.useEffect(()=>{io.current&&io.current.onDidBlurEditorText(lo=>{var co;const uo=((co=io.current)==null?void 0:co.getValue())??"{}";ct(uo)})},[io.current]),reactExports.useEffect(()=>{qt&&!isJSONEqual(JSON.parse(Zn.value||"{}"),no)&&oo(Zn.value||"{}")},[qt,Zn.value]);let ao="",so=!1;try{const lo=JSON.parse(no);it&&(so=it().strict().safeParse(lo).success,so||(ao="Invalid initial state"))}catch{ao="Invalid JSON"}return jsxRuntimeExports.jsxs("div",{children:[jsxRuntimeExports.jsx(CodeEditor,{height:"60vh",language:"json",onChange:lo=>oo(lo??""),theme:`vs-${Ot}`,width:"100%",...Zn,onMount:async(lo,co)=>{var uo;io.current=lo,(uo=Zn.onMount)==null||uo.call(Zn,lo,co),setTimeout(async()=>{var po;try{await((po=lo.getAction("editor.action.formatDocument"))==null?void 0:po.run())}catch(fo){console.error(fo)}},50)},options:{lineNumbers:"off",lineNumbersMinChars:0,minimap:{enabled:!1},automaticLayout:!0,...Zn.options},value:no}),jsxRuntimeExports.jsx("p",{style:{minHeight:20,marginTop:10,fontSize:"1.1rem",color:"red"},children:ao})]})}function EditorState(it){const{name:ct,theme:Ot,setStateSchema:qt,scope:Zn,schemaHandlers:no,latestOperation:oo}=it,{setInitialValue:io,setSchemaState:ao,schemaState:so,specification:lo}=no,co=Zn==="local"?"Local":"Global";return jsxRuntimeExports.jsxs("div",{style:{display:"flex",alignItems:"flex-start"},children:[jsxRuntimeExports.jsxs("div",{style:{width:"50%",display:"inline-block"},children:[jsxRuntimeExports.jsx("h4",{style:{marginBottom:"16px"},children:`${co} State Schema`}),jsxRuntimeExports.jsx(EditorSchema,{height:200,name:ct,onGenerate:uo=>{ao(po=>({...po,...uo})),uo.schema!==(lo==null?void 0:lo.state[Zn].schema)&&qt(uo.schema,Zn)},scope:Zn,theme:Ot,value:lo==null?void 0:lo.state[Zn].schema})]}),jsxRuntimeExports.jsxs("div",{style:{width:"50%",display:"inline-block"},children:[jsxRuntimeExports.jsx("h4",{style:{marginBottom:"16px"},children:`${co} Initial State`}),jsxRuntimeExports.jsx(EditorInitialState,{height:200,onCreate:uo=>{io(JSON.parse(uo))},setInitialValue:(oo==null?void 0:oo.type)==="SET_INITIAL_STATE"&&oo.scope===Zn,theme:Ot,validator:so==null?void 0:so.validator,value:lo==null?void 0:lo.state[Zn].initialValue})]})]})}function Editor(it){const ct=it.context.theme||"light",Ot=colorScheme$1[ct],qt={backgroundColor:Ot.bgColor,color:Ot.color,maxWidth:"60em",margin:"1em auto",padding:"6em",border:"2px solid "+Ot.border,boxShadow:"2px 2px 2px "+Ot.shadow,fontFamily:"Roboto, sans-serif",position:"relative"},{document:Zn,dispatch:no}=it,{state:oo}=Zn,io=Zn.operations.global[Zn.operations.global.length-1],ao=wo=>{no(actions.setModelId({id:wo}))},so=wo=>{no(actions.setModelDescription({description:wo}))},lo=wo=>{no(actions.setModelExtension({extension:wo}))},co=wo=>{no(actions.setModelName({name:wo})),no(actions.setName(wo))},uo=wo=>{no(actions.setAuthorName({authorName:wo}))},po=wo=>{no(actions.setAuthorWebsite({authorWebsite:wo}))},fo=(wo,Ko)=>{no(actions.setStateSchema({schema:wo,scope:Ko}))},mo=(wo,Ko)=>{no(actions.setInitialState({initialValue:wo,scope:Ko}))},So=wo=>{no(actions.addModule({id:index.hashKey(),name:wo}))},ho=(wo,Ko)=>{no(actions.setModuleName({id:wo,name:Ko}))},yo=(wo,Ko)=>{no(actions.setModuleDescription({id:wo,description:Ko}))},go=wo=>{no(actions.deleteModule({id:wo}))},vo=(wo,Ko)=>{no(actions.addOperation({id:index.hashKey(),moduleId:wo,name:Ko}))},xo=(wo,Ko)=>{no(actions.setOperationName({id:wo,name:Ko}))},Vo=(wo,Ko)=>{no(actions.setOperationSchema({id:wo,schema:Ko}))},ti=(wo,Ko)=>{no(actions.setOperationScope({id:wo,scope:Ko}))},ni=wo=>{no(actions.deleteOperation({id:wo}))},No=useSchemaEditor({state:oo,scope:"global",setInitialState:mo,latestOperation:io}),ko=useSchemaEditor({state:oo,scope:"local",setInitialState:mo,latestOperation:io});return jsxRuntimeExports.jsxs("div",{style:{...qt,minHeight:"70em"},children:[jsxRuntimeExports.jsx(TextInput,{autoFocus:!0,clearOnSubmit:!1,onSubmit:co,placeholder:"Document Model Name",size:"larger",theme:ct,value:oo.global.name},"modelName"),jsxRuntimeExports.jsx("div",{style:{width:"50%",display:"inline-block"},children:jsxRuntimeExports.jsx(TextInput,{autoFocus:!1,clearOnSubmit:!1,onSubmit:ao,placeholder:"Model Type",size:"small",theme:ct,value:oo.global.id},"modelId")}),jsxRuntimeExports.jsx(TextInput,{autoFocus:!1,clearOnSubmit:!1,onSubmit:so,placeholder:"Model Description",theme:ct,value:oo.global.description},"modelDescription"),jsxRuntimeExports.jsx("div",{style:{width:"50%",display:"inline-block"},children:jsxRuntimeExports.jsx(TextInput,{autoFocus:!1,clearOnSubmit:!1,onSubmit:lo,placeholder:"File Extension(s)",size:"small",theme:ct,value:oo.global.extension},"modelExtension")}),jsxRuntimeExports.jsxs("div",{children:[jsxRuntimeExports.jsx("p",{style:{...typographySizes$1.tiny},children:"Author"}),jsxRuntimeExports.jsx("div",{style:{width:"50%",display:"inline-block"},children:jsxRuntimeExports.jsx(TextInput,{autoFocus:!1,clearOnSubmit:!1,onSubmit:uo,placeholder:"Author Name",size:"small",theme:ct,value:oo.global.author.name},"authorName")}),jsxRuntimeExports.jsx("div",{style:{width:"50%",display:"inline-block"},children:jsxRuntimeExports.jsx(TextInput,{autoFocus:!1,clearOnSubmit:!1,onSubmit:po,placeholder:"https://",size:"small",theme:ct,value:oo.global.author.website||""},"authorWebsite")})]}),No.specification?jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(EditorState,{latestOperation:io,name:Zn.state.global.name,schemaHandlers:No,scope:"global",setStateSchema:fo,theme:ct}),jsxRuntimeExports.jsx(EditorState,{latestOperation:io,name:Zn.state.global.name,schemaHandlers:ko,scope:"local",setStateSchema:fo,theme:ct}),No.specification.modules.map(wo=>jsxRuntimeExports.jsxs("div",{children:[jsxRuntimeExports.jsx(TextInput,{autoFocus:!1,clearOnSubmit:!1,horizontalLine:!0,onEmpty:()=>go(wo.id),onSubmit:Ko=>ho(wo.id,Ko),placeholder:"Module Name",size:"large",theme:ct,value:wo.name},wo.id+"#name"),jsxRuntimeExports.jsx(TextInput,{autoFocus:!1,clearOnSubmit:!1,onSubmit:Ko=>yo(wo.id,Ko),placeholder:"Module "+wo.name+" description",size:"small",theme:ct,value:wo.description||""},wo.id+"#description"),wo.operations.map(Ko=>jsxRuntimeExports.jsx(EditorOperation,{id:Ko.id,name:Ko.name,onDelete:ni,onUpdateName:xo,onUpdateSchema:Vo,onUpdateScope:ti,schema:Ko.schema,scope:Ko.scope,theme:ct},Ko.id)),jsxRuntimeExports.jsx(TextInput,{autoFocus:!1,clearOnSubmit:!0,onSubmit:Ko=>vo(wo.id,Ko),placeholder:"Add operation...",size:"medium",theme:ct},wo.id+"#newOperation")]},wo.id))]}):null,jsxRuntimeExports.jsx(TextInput,{autoFocus:!1,clearOnSubmit:!0,horizontalLine:!0,onSubmit:So,placeholder:"Module Name",size:"large",theme:ct},"newModule")]})}const editor=Object.freeze(Object.defineProperty({__proto__:null,default:Editor},Symbol.toStringTag,{value:"Module"})),editor$1=Object.freeze(Object.defineProperty({__proto__:null,$:keysIn_1,A:specifiedRules,B:ExecutableDefinitionsRule,C:validate,D:DocumentEditor,E:EditorToolbar,F:NoDeprecatedCustomRule,G:GraphQLEnumType,H:GraphQLNonNull,I:removeFederation,J:JSONEditor,get K(){return Kind},L:extendSchema,M:getCachedDocumentNodeFromSchema,N:NoUnusedFragmentsRule,O:oldVisit,P:printIntrospectionSchema,Q:isObjectType,R:visitWithTypeInfo,S:SchemaMetaFieldDef,T:ToolbarButton,U:isIntrospectionType,V:TypeInfo,W:_isPrototype,X:_arrayLikeKeys,Y:isArrayLike_1,Z:_copyObject,_:_overArg,a:EditorWorksheet,a0:_getPrototype,a1:isArray_1,a2:_getNative,a3:_root,a4:_Map,a5:_baseGetTag,a6:require_toSource,a7:_cloneArrayBuffer,a8:_Symbol,a9:_cloneTypedArray,aA:specifiedScalarTypes,aB:buildSchema,aC:printSchema,aD:isInputObjectType,aE:isScalarType,get aF(){return pascalCase},aG:resolveExternalModuleAndFn,aH:isEnumType,aI:styles,aJ:stylesVariant,aK:wrapReducer,aL:createUseDocumentReducer,aM:useDocumentReducer,aN:createDocumentStory,aO:editor,aa:isObjectLike_1,ab:_nodeUtilExports,ac:_baseUnary,ad:_Stack,ae:_assignValue,af:_cloneBufferExports,ag:_copyArray,ah:_initCloneObject,ai:isBufferExports,aj:isObject_1,ak:_baseFor,al:identity_1,am:_MapCache,an:_Uint8Array,ao:eq_1,ap:isTypedArray_1,aq:isArguments_1,ar:_isIndex,as:isLength_1,at:_baseCreate,au:isFunction_1,av:_baseRest,aw:isArrayLikeObject_1,ax:requireConstant,ay:isSpecifiedScalarType,az:valueFromASTUntyped,b:TextInput,c:TextInputVariant,d:buildClientSchema,e:buildASTSchema,f:TypeMetaFieldDef,g:getIntrospectionQuery,h:TypeNameMetaFieldDef,i:isCompositeType,j:getNamedType,k:GraphQLBoolean,l:isInterfaceType,m:GraphQLInterfaceType,n:GraphQLObjectType,o:isAbstractType,p:assertAbstractType,q:doTypesOverlap,r:isInputType,get s(){return DirectiveLocation},t:parse,u:isListType,v:visit,w:isNonNullType,x:GraphQLInputObjectType,y:getNullableType,z:GraphQLList},Symbol.toStringTag,{value:"Module"})),l$1={Component:P$3(()=>__vitePreload(()=>import("./editor-Cxi1Bi4m.js"),__vite__mapDeps([10,1,2]))),documentTypes:["*"],config:{id:"json-editor",disableExternalControls:!1}},a={Component:P$3(()=>__vitePreload(()=>import("./editor-NPbexOjM.js"),__vite__mapDeps([11,1,2]))),documentTypes:["powerhouse/budget-statement"],config:{id:"budget-statement-editor",disableExternalControls:!1}},l={Component:P$3(()=>__vitePreload(()=>Promise.resolve().then(()=>editor$1),void 0).then(it=>it.aO)),documentTypes:["powerhouse/document-model"],config:{id:"document-model-editor",disableExternalControls:!1}},i={Component:P$3(()=>__vitePreload(()=>import("./editor-Bat08LEU.js"),__vite__mapDeps([12,1,2]))),documentTypes:["makerdao/scope-framework"],config:{id:"scope-framework-editor",disableExternalControls:!1}},p={Component:P$3(()=>__vitePreload(()=>import("./editor-CIbZp8-c.js"),__vite__mapDeps([13,1,2])).then(it=>it.e)),documentTypes:["makerdao/rwa-portfolio"],config:{id:"rwa-editor",disableExternalControls:!0}},editors=Object.freeze(Object.defineProperty({__proto__:null,BudgetStatement:a,DocumentModel:l,Json:l$1,RealWorldAssets:p,ScopeFramework:i},Symbol.toStringTag,{value:"Module"}));export{isSpecifiedScalarType as $,isListType as A,isNonNullType as B,specifiedRules as C,DocumentEditor as D,EditorToolbar as E,NoUnusedFragmentsRule as F,GraphQLNonNull as G,ExecutableDefinitionsRule as H,oldVisit as I,JSONEditor as J,Kind as K,TypeInfo as L,printIntrospectionSchema as M,NoDeprecatedCustomRule as N,isObjectType as O,removeFederation as P,extendSchema as Q,getCachedDocumentNodeFromSchema as R,SchemaMetaFieldDef as S,ToolbarButton as T,visitWithTypeInfo as U,isIntrospectionType as V,requireConstant as W,isArray_1 as X,isFunction_1 as Y,buildSchema as Z,printSchema as _,EditorWorksheet as a,require_toSource as a0,_baseRest as a1,isArrayLikeObject_1 as a2,_Map as a3,_baseGetTag as a4,valueFromASTUntyped as a5,specifiedScalarTypes as a6,_arrayLikeKeys as a7,isArrayLike_1 as a8,_getNative as a9,_Uint8Array as aA,eq_1 as aB,_overArg as aC,isEnumType as aD,isInputObjectType as aE,isScalarType as aF,resolveExternalModuleAndFn as aG,pascalCase as aH,editors as aI,_root as aa,_nodeUtilExports as ab,_Stack as ac,_assignValue as ad,_cloneBufferExports as ae,_copyArray as af,_initCloneObject as ag,isBufferExports as ah,isObject_1 as ai,_baseFor as aj,isArguments_1 as ak,_isIndex as al,isLength_1 as am,identity_1 as an,_isPrototype as ao,isTypedArray_1 as ap,_baseCreate as aq,_getPrototype as ar,_Symbol as as,_copyObject as at,_cloneArrayBuffer as au,_cloneTypedArray as av,_baseUnary as aw,keysIn_1 as ax,_MapCache as ay,isObjectLike_1 as az,TextInput as b,TextInputVariant as c,GraphQLList as d,buildClientSchema as e,buildASTSchema as f,getIntrospectionQuery as g,getNamedType as h,isCompositeType as i,TypeNameMetaFieldDef as j,TypeMetaFieldDef as k,GraphQLEnumType as l,GraphQLBoolean as m,isInterfaceType as n,isAbstractType as o,parse as p,assertAbstractType as q,doTypesOverlap as r,isInputType as s,DirectiveLocation as t,GraphQLInputObjectType as u,visit as v,getNullableType as w,GraphQLObjectType as x,GraphQLInterfaceType as y,validate as z};
455
+ //# sourceMappingURL=editors-DVrDEp-F.js.map
@@ -1 +1 @@
1
- {"version":3,"mappings":"","names":[],"ignoreList":[],"sources":[],"sourcesContent":[],"file":"assets/editors-BvDPqtae.js"}
1
+ {"version":3,"mappings":"","names":[],"ignoreList":[],"sources":[],"sourcesContent":[],"file":"assets/editors-DVrDEp-F.js"}
@@ -1,4 +1,4 @@
1
- import{m as F}from"./index-CnxM4IIa-CvFEW5IC.js";import"./main.DHxrtmJK.js";import"./editors-BvDPqtae.js";import"./index-T6Et30Eh-Bk15VVSB.js";/*!-----------------------------------------------------------------------------
1
+ import{m as F}from"./index-CnxM4IIa-CoekJPsT.js";import"./main.9ezbfd1a.js";import"./editors-DVrDEp-F.js";import"./index-T6Et30Eh-B1ytNt1O.js";/*!-----------------------------------------------------------------------------
2
2
  * Copyright (c) Microsoft Corporation. All rights reserved.
3
3
  * Version: 0.45.0(5e5af013f8d295555a7210df0d5f2cea0bf5dd56)
4
4
  * Released under the MIT license
@@ -6,4 +6,4 @@ import{m as F}from"./index-CnxM4IIa-CvFEW5IC.js";import"./main.DHxrtmJK.js";impo
6
6
  *-----------------------------------------------------------------------------*/var f=Object.defineProperty,b=Object.getOwnPropertyDescriptor,x=Object.getOwnPropertyNames,$=Object.prototype.hasOwnProperty,D=(t,n,i,e)=>{if(n&&typeof n=="object"||typeof n=="function")for(let o of x(n))!$.call(t,o)&&o!==i&&f(t,o,{get:()=>n[o],enumerable:!(e=b(n,o))||e.enumerable});return t},E=(t,n,i)=>(D(t,n,"default"),i),r={};E(r,F);var c=["assign","flush","ftl","return","global","import","include","break","continue","local","nested","nt","setting","stop","t","lt","rt","fallback"],d=["attempt","autoesc","autoEsc","compress","comment","escape","noescape","function","if","list","items","sep","macro","noparse","noParse","noautoesc","noAutoEsc","outputformat","switch","visit","recurse"],a={close:">",id:"angle",open:"<"},s={close:"\\]",id:"bracket",open:"\\["},B={close:"[>\\]]",id:"auto",open:"[<\\[]"},k={close:"\\}",id:"dollar",open1:"\\$",open2:"\\{"},p={close:"\\]",id:"bracket",open1:"\\[",open2:"="};function l(t){return{brackets:[["<",">"],["[","]"],["(",")"],["{","}"]],comments:{blockComment:[`${t.open}--`,`--${t.close}`]},autoCloseBefore:`
7
7
  \r }]),.:;=`,autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string"]}],surroundingPairs:[{open:'"',close:'"'},{open:"'",close:"'"},{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"}],folding:{markers:{start:new RegExp(`${t.open}#(?:${d.join("|")})([^/${t.close}]*(?!/)${t.close})[^${t.open}]*$`),end:new RegExp(`${t.open}/#(?:${d.join("|")})[\\r\\n\\t ]*>`)}},onEnterRules:[{beforeText:new RegExp(`${t.open}#(?!(?:${c.join("|")}))([a-zA-Z_]+)([^/${t.close}]*(?!/)${t.close})[^${t.open}]*$`),afterText:new RegExp(`^${t.open}/#([a-zA-Z_]+)[\\r\\n\\t ]*${t.close}$`),action:{indentAction:r.languages.IndentAction.IndentOutdent}},{beforeText:new RegExp(`${t.open}#(?!(?:${c.join("|")}))([a-zA-Z_]+)([^/${t.close}]*(?!/)${t.close})[^${t.open}]*$`),action:{indentAction:r.languages.IndentAction.Indent}}]}}function g(){return{brackets:[["<",">"],["[","]"],["(",")"],["{","}"]],autoCloseBefore:`
8
8
  \r }]),.:;=`,autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string"]}],surroundingPairs:[{open:'"',close:'"'},{open:"'",close:"'"},{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"}],folding:{markers:{start:new RegExp(`[<\\[]#(?:${d.join("|")})([^/>\\]]*(?!/)[>\\]])[^<\\[]*$`),end:new RegExp(`[<\\[]/#(?:${d.join("|")})[\\r\\n\\t ]*>`)}},onEnterRules:[{beforeText:new RegExp(`[<\\[]#(?!(?:${c.join("|")}))([a-zA-Z_]+)([^/>\\]]*(?!/)[>\\]])[^[<\\[]]*$`),afterText:new RegExp("^[<\\[]/#([a-zA-Z_]+)[\\r\\n\\t ]*[>\\]]$"),action:{indentAction:r.languages.IndentAction.IndentOutdent}},{beforeText:new RegExp(`[<\\[]#(?!(?:${c.join("|")}))([a-zA-Z_]+)([^/>\\]]*(?!/)[>\\]])[^[<\\[]]*$`),action:{indentAction:r.languages.IndentAction.Indent}}]}}function _(t,n){const i=`_${t.id}_${n.id}`,e=u=>u.replace(/__id__/g,i),o=u=>{const m=u.source.replace(/__id__/g,i);return new RegExp(m,u.flags)};return{unicode:!0,includeLF:!1,start:e("default__id__"),ignoreCase:!1,defaultToken:"invalid",tokenPostfix:".freemarker2",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],[e("open__id__")]:new RegExp(t.open),[e("close__id__")]:new RegExp(t.close),[e("iOpen1__id__")]:new RegExp(n.open1),[e("iOpen2__id__")]:new RegExp(n.open2),[e("iClose__id__")]:new RegExp(n.close),[e("startTag__id__")]:o(/(@open__id__)(#)/),[e("endTag__id__")]:o(/(@open__id__)(\/#)/),[e("startOrEndTag__id__")]:o(/(@open__id__)(\/?#)/),[e("closeTag1__id__")]:o(/((?:@blank)*)(@close__id__)/),[e("closeTag2__id__")]:o(/((?:@blank)*\/?)(@close__id__)/),blank:/[ \t\n\r]/,keywords:["false","true","in","as","using"],directiveStartCloseTag1:/attempt|recover|sep|auto[eE]sc|no(?:autoe|AutoE)sc|compress|default|no[eE]scape|comment|no[pP]arse/,directiveStartCloseTag2:/else|break|continue|return|stop|flush|t|lt|rt|nt|nested|recurse|fallback|ftl/,directiveStartBlank:/if|else[iI]f|list|for[eE]ach|switch|case|assign|global|local|include|import|function|macro|transform|visit|stop|return|call|setting|output[fF]ormat|nested|recurse|escape|ftl|items/,directiveEndCloseTag1:/if|list|items|sep|recover|attempt|for[eE]ach|local|global|assign|function|macro|output[fF]ormat|auto[eE]sc|no(?:autoe|AutoE)sc|compress|transform|switch|escape|no[eE]scape/,escapedChar:/\\(?:[ntrfbgla\\'"\{=]|(?:x[0-9A-Fa-f]{1,4}))/,asciiDigit:/[0-9]/,integer:/[0-9]+/,nonEscapedIdStartChar:/[\$@-Z_a-z\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u1FFF\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183-\u2184\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005-\u3006\u3031-\u3035\u303B-\u303C\u3040-\u318F\u31A0-\u31BA\u31F0-\u31FF\u3300-\u337F\u3400-\u4DB5\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8D0-\uA8D9\uA8F2-\uA8F7\uA8FB\uA900-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF-\uA9D9\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA50-\uAA59\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5-\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uABC0-\uABE2\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40-\uFB41\uFB43-\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]/,escapedIdChar:/\\[\-\.:#]/,idStartChar:/(?:@nonEscapedIdStartChar)|(?:@escapedIdChar)/,id:/(?:@idStartChar)(?:(?:@idStartChar)|(?:@asciiDigit))*/,specialHashKeys:/\*\*|\*|false|true|in|as|using/,namedSymbols:/&lt;=|&gt;=|\\lte|\\lt|&lt;|\\gte|\\gt|&gt;|&amp;&amp;|\\and|-&gt;|->|==|!=|\+=|-=|\*=|\/=|%=|\+\+|--|<=|&&|\|\||:|\.\.\.|\.\.\*|\.\.<|\.\.!|\?\?|=|<|\+|-|\*|\/|%|\||\.\.|\?|!|&|\.|,|;/,arrows:["->","-&gt;"],delimiters:[";",":",",","."],stringOperators:["lte","lt","gte","gt"],noParseTags:["noparse","noParse","comment"],tokenizer:{[e("default__id__")]:[{include:e("@directive_token__id__")},{include:e("@interpolation_and_text_token__id__")}],[e("fmExpression__id__.directive")]:[{include:e("@blank_and_expression_comment_token__id__")},{include:e("@directive_end_token__id__")},{include:e("@expression_token__id__")}],[e("fmExpression__id__.interpolation")]:[{include:e("@blank_and_expression_comment_token__id__")},{include:e("@expression_token__id__")},{include:e("@greater_operators_token__id__")}],[e("inParen__id__.plain")]:[{include:e("@blank_and_expression_comment_token__id__")},{include:e("@directive_end_token__id__")},{include:e("@expression_token__id__")}],[e("inParen__id__.gt")]:[{include:e("@blank_and_expression_comment_token__id__")},{include:e("@expression_token__id__")},{include:e("@greater_operators_token__id__")}],[e("noSpaceExpression__id__")]:[{include:e("@no_space_expression_end_token__id__")},{include:e("@directive_end_token__id__")},{include:e("@expression_token__id__")}],[e("unifiedCall__id__")]:[{include:e("@unified_call_token__id__")}],[e("singleString__id__")]:[{include:e("@string_single_token__id__")}],[e("doubleString__id__")]:[{include:e("@string_double_token__id__")}],[e("rawSingleString__id__")]:[{include:e("@string_single_raw_token__id__")}],[e("rawDoubleString__id__")]:[{include:e("@string_double_raw_token__id__")}],[e("expressionComment__id__")]:[{include:e("@expression_comment_token__id__")}],[e("noParse__id__")]:[{include:e("@no_parse_token__id__")}],[e("terseComment__id__")]:[{include:e("@terse_comment_token__id__")}],[e("directive_token__id__")]:[[o(/(?:@startTag__id__)(@directiveStartCloseTag1)(?:@closeTag1__id__)/),t.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${n.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${n.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive"},{cases:{"@noParseTags":{token:"tag",next:e("@noParse__id__.$3")},"@default":{token:"tag"}}},{token:"delimiter.directive"},{token:"@brackets.directive"}]],[o(/(?:@startTag__id__)(@directiveStartCloseTag2)(?:@closeTag2__id__)/),t.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${n.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${n.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag"},{token:"delimiter.directive"},{token:"@brackets.directive"}]],[o(/(?:@startTag__id__)(@directiveStartBlank)(@blank)/),t.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${n.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${n.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag"},{token:"",next:e("@fmExpression__id__.directive")}]],[o(/(?:@endTag__id__)(@directiveEndCloseTag1)(?:@closeTag1__id__)/),t.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${n.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${n.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag"},{token:"delimiter.directive"},{token:"@brackets.directive"}]],[o(/(@open__id__)(@)/),t.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${n.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${n.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive",next:e("@unifiedCall__id__")}]],[o(/(@open__id__)(\/@)((?:(?:@id)(?:\.(?:@id))*)?)(?:@closeTag1__id__)/),[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag"},{token:"delimiter.directive"},{token:"@brackets.directive"}]],[o(/(@open__id__)#--/),t.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${n.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${n.id}`}}}:{token:"comment",next:e("@terseComment__id__")}],[o(/(?:@startOrEndTag__id__)([a-zA-Z_]+)/),t.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${n.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${n.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag.invalid",next:e("@fmExpression__id__.directive")}]]],[e("interpolation_and_text_token__id__")]:[[o(/(@iOpen1__id__)(@iOpen2__id__)/),[{token:n.id==="bracket"?"@brackets.interpolation":"delimiter.interpolation"},{token:n.id==="bracket"?"delimiter.interpolation":"@brackets.interpolation",next:e("@fmExpression__id__.interpolation")}]],[/[\$#<\[\{]|(?:@blank)+|[^\$<#\[\{\n\r\t ]+/,{token:"source"}]],[e("string_single_token__id__")]:[[/[^'\\]/,{token:"string"}],[/@escapedChar/,{token:"string.escape"}],[/'/,{token:"string",next:"@pop"}]],[e("string_double_token__id__")]:[[/[^"\\]/,{token:"string"}],[/@escapedChar/,{token:"string.escape"}],[/"/,{token:"string",next:"@pop"}]],[e("string_single_raw_token__id__")]:[[/[^']+/,{token:"string.raw"}],[/'/,{token:"string.raw",next:"@pop"}]],[e("string_double_raw_token__id__")]:[[/[^"]+/,{token:"string.raw"}],[/"/,{token:"string.raw",next:"@pop"}]],[e("expression_token__id__")]:[[/(r?)(['"])/,{cases:{"r'":[{token:"keyword"},{token:"string.raw",next:e("@rawSingleString__id__")}],'r"':[{token:"keyword"},{token:"string.raw",next:e("@rawDoubleString__id__")}],"'":[{token:"source"},{token:"string",next:e("@singleString__id__")}],'"':[{token:"source"},{token:"string",next:e("@doubleString__id__")}]}}],[/(?:@integer)(?:\.(?:@integer))?/,{cases:{"(?:@integer)":{token:"number"},"@default":{token:"number.float"}}}],[/(\.)(@blank*)(@specialHashKeys)/,[{token:"delimiter"},{token:""},{token:"identifier"}]],[/(?:@namedSymbols)/,{cases:{"@arrows":{token:"meta.arrow"},"@delimiters":{token:"delimiter"},"@default":{token:"operators"}}}],[/@id/,{cases:{"@keywords":{token:"keyword.$0"},"@stringOperators":{token:"operators"},"@default":{token:"identifier"}}}],[/[\[\]\(\)\{\}]/,{cases:{"\\[":{cases:{"$S2==gt":{token:"@brackets",next:e("@inParen__id__.gt")},"@default":{token:"@brackets",next:e("@inParen__id__.plain")}}},"\\]":{cases:{...n.id==="bracket"?{"$S2==interpolation":{token:"@brackets.interpolation",next:"@popall"}}:{},...t.id==="bracket"?{"$S2==directive":{token:"@brackets.directive",next:"@popall"}}:{},[e("$S1==inParen__id__")]:{token:"@brackets",next:"@pop"},"@default":{token:"@brackets"}}},"\\(":{token:"@brackets",next:e("@inParen__id__.gt")},"\\)":{cases:{[e("$S1==inParen__id__")]:{token:"@brackets",next:"@pop"},"@default":{token:"@brackets"}}},"\\{":{cases:{"$S2==gt":{token:"@brackets",next:e("@inParen__id__.gt")},"@default":{token:"@brackets",next:e("@inParen__id__.plain")}}},"\\}":{cases:{...n.id==="bracket"?{}:{"$S2==interpolation":{token:"@brackets.interpolation",next:"@popall"}},[e("$S1==inParen__id__")]:{token:"@brackets",next:"@pop"},"@default":{token:"@brackets"}}}}}],[/\$\{/,{token:"delimiter.invalid"}]],[e("blank_and_expression_comment_token__id__")]:[[/(?:@blank)+/,{token:""}],[/[<\[][#!]--/,{token:"comment",next:e("@expressionComment__id__")}]],[e("directive_end_token__id__")]:[[/>/,t.id==="bracket"?{token:"operators"}:{token:"@brackets.directive",next:"@popall"}],[o(/(\/)(@close__id__)/),[{token:"delimiter.directive"},{token:"@brackets.directive",next:"@popall"}]]],[e("greater_operators_token__id__")]:[[/>/,{token:"operators"}],[/>=/,{token:"operators"}]],[e("no_space_expression_end_token__id__")]:[[/(?:@blank)+/,{token:"",switchTo:e("@fmExpression__id__.directive")}]],[e("unified_call_token__id__")]:[[/(@id)((?:@blank)+)/,[{token:"tag"},{token:"",next:e("@fmExpression__id__.directive")}]],[o(/(@id)(\/?)(@close__id__)/),[{token:"tag"},{token:"delimiter.directive"},{token:"@brackets.directive",next:"@popall"}]],[/./,{token:"@rematch",next:e("@noSpaceExpression__id__")}]],[e("no_parse_token__id__")]:[[o(/(@open__id__)(\/#?)([a-zA-Z]+)((?:@blank)*)(@close__id__)/),{cases:{"$S2==$3":[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag"},{token:""},{token:"@brackets.directive",next:"@popall"}],"$S2==comment":[{token:"comment"},{token:"comment"},{token:"comment"},{token:"comment"},{token:"comment"}],"@default":[{token:"source"},{token:"source"},{token:"source"},{token:"source"},{token:"source"}]}}],[/[^<\[\-]+|[<\[\-]/,{cases:{"$S2==comment":{token:"comment"},"@default":{token:"source"}}}]],[e("expression_comment_token__id__")]:[[/--[>\]]/,{token:"comment",next:"@pop"}],[/[^\->\]]+|[>\]\-]/,{token:"comment"}]],[e("terse_comment_token__id__")]:[[o(/--(?:@close__id__)/),{token:"comment",next:"@popall"}],[/[^<\[\-]+|[<\[\-]/,{token:"comment"}]]}}}function A(t){const n=_(a,t),i=_(s,t),e=_(B,t);return{...n,...i,...e,unicode:!0,includeLF:!1,start:`default_auto_${t.id}`,ignoreCase:!1,defaultToken:"invalid",tokenPostfix:".freemarker2",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],tokenizer:{...n.tokenizer,...i.tokenizer,...e.tokenizer}}}var T={conf:l(a),language:_(a,k)},S={conf:l(s),language:_(s,k)},P={conf:l(a),language:_(a,p)},I={conf:l(s),language:_(s,p)},y={conf:g(),language:A(k)},R={conf:g(),language:A(p)};export{P as TagAngleInterpolationBracket,T as TagAngleInterpolationDollar,R as TagAutoInterpolationBracket,y as TagAutoInterpolationDollar,I as TagBracketInterpolationBracket,S as TagBracketInterpolationDollar};
9
- //# sourceMappingURL=freemarker2-B12auKfc-CV2bI2LT.js.map
9
+ //# sourceMappingURL=freemarker2-B12auKfc-CY1f5BH_.js.map