@nodefony/studio 10.0.0-alpha.1 → 10.0.0-alpha.2
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.
- package/README.md +1 -1
- package/package.json +11 -11
- package/public/dist/.vite/manifest.json +0 -2621
- package/public/dist/assets/Accordion-BXP1kR9X.js +0 -1
- package/public/dist/assets/ActionsLiveGraph-TMN9owkt.js +0 -1
- package/public/dist/assets/ApiKeys-DLi1f_xy.js +0 -2
- package/public/dist/assets/ArchitectureLiveGraph-CUKQJFEi.js +0 -1
- package/public/dist/assets/Audit-BiVfGgSA.js +0 -1
- package/public/dist/assets/BackplaneLiveGraph-CFLvQmEL.js +0 -1
- package/public/dist/assets/Breadcrumbs-JSpsPPlF.js +0 -1
- package/public/dist/assets/BrickStoreChip-C7F6Q4ig.js +0 -1
- package/public/dist/assets/Chat-DbIOM5Wa.js +0 -1
- package/public/dist/assets/Chip-VZhBMG0_.js +0 -1
- package/public/dist/assets/Cluster-cOE0OxW0.js +0 -1
- package/public/dist/assets/Collapse-CgNJKcgq.js +0 -1
- package/public/dist/assets/ConfigPage-BtigihuA.js +0 -1
- package/public/dist/assets/ConnectorCard-CGhp9F2i.js +0 -11
- package/public/dist/assets/Create-19VdxmZH.js +0 -2
- package/public/dist/assets/DashboardSupervision-D59WlOuD.js +0 -1
- package/public/dist/assets/Database-fZHaPnFp.js +0 -1
- package/public/dist/assets/DbLogo-BoReNymx.js +0 -4
- package/public/dist/assets/Documentation-CZa2qx7I.js +0 -1
- package/public/dist/assets/FanOutLiveGraph-Bijim5jw.js +0 -1
- package/public/dist/assets/Firewall-Bu4kcT-c.js +0 -1
- package/public/dist/assets/IconAdjustments-Cm5pohyR.js +0 -1
- package/public/dist/assets/IconAdjustmentsHorizontal-B_ezBB_l.js +0 -1
- package/public/dist/assets/IconApps-BlTe4PPI.js +0 -1
- package/public/dist/assets/IconArrowDown-9GueidaS.js +0 -1
- package/public/dist/assets/IconArrowLeft-DJDG7Smo.js +0 -1
- package/public/dist/assets/IconArrowUp-C_9hl3Nb.js +0 -1
- package/public/dist/assets/IconArrowsSplit2--SYoYsTA.js +0 -1
- package/public/dist/assets/IconBan-Dq9wsaIv.js +0 -1
- package/public/dist/assets/IconBook-BDi1pADX.js +0 -1
- package/public/dist/assets/IconCircleCheck-DXO4-GVV.js +0 -1
- package/public/dist/assets/IconCircleDot-CkED5AFm.js +0 -1
- package/public/dist/assets/IconCircuitResistor-BKvBhegV.js +0 -1
- package/public/dist/assets/IconCode-CbpS0CnX.js +0 -1
- package/public/dist/assets/IconDeviceDesktop-DEpLd6M3.js +0 -1
- package/public/dist/assets/IconDots-BTUB3iLa.js +0 -1
- package/public/dist/assets/IconDownload-LsVuncWt.js +0 -1
- package/public/dist/assets/IconEye-DolbrZfe.js +0 -1
- package/public/dist/assets/IconFile-CtwrsnXi.js +0 -1
- package/public/dist/assets/IconFolder-Cmbw6D4Y.js +0 -1
- package/public/dist/assets/IconGitBranch-B4mq3lBf.js +0 -1
- package/public/dist/assets/IconHeartRateMonitor-BAe0rtlb.js +0 -1
- package/public/dist/assets/IconHelpCircle-BnRVNOzn.js +0 -1
- package/public/dist/assets/IconLayoutGrid-DHHhmYY7.js +0 -1
- package/public/dist/assets/IconPackages-BAI9M0jz.js +0 -1
- package/public/dist/assets/IconPencil-D0t63JY0.js +0 -1
- package/public/dist/assets/IconPlayerPause-CAaHo_2D.js +0 -1
- package/public/dist/assets/IconPlayerPlay-ByPFNa8B.js +0 -1
- package/public/dist/assets/IconPlus-DPFeNXdo.js +0 -1
- package/public/dist/assets/IconPuzzle-BIwo-K6E.js +0 -1
- package/public/dist/assets/IconRecycle-DCJ_qNCS.js +0 -1
- package/public/dist/assets/IconSend-BpQTFlYO.js +0 -1
- package/public/dist/assets/IconServer2-Ws6qHZ8A.js +0 -1
- package/public/dist/assets/IconShieldOff-CTGOUl2X.js +0 -1
- package/public/dist/assets/IconSitemap-BNiE2mWt.js +0 -1
- package/public/dist/assets/IconStack2-BZL8dJr1.js +0 -1
- package/public/dist/assets/IconTerminal2-BtI4ujHY.js +0 -1
- package/public/dist/assets/IconUserOff-BVatVNGb.js +0 -1
- package/public/dist/assets/IconWorld-v1UEZOxv.js +0 -1
- package/public/dist/assets/List-BnAY10IA.js +0 -1
- package/public/dist/assets/LogVisuals-BalQ75XP.js +0 -1
- package/public/dist/assets/Logs-COCegPHD.js +0 -1
- package/public/dist/assets/Migrations-CQcD9RjE.js +0 -3
- package/public/dist/assets/ModuleDetail-B0FWuc5T.js +0 -1
- package/public/dist/assets/Modules-7rCMj8R5.js +0 -1
- package/public/dist/assets/OrmEntity-Dim-e9EU.js +0 -1
- package/public/dist/assets/OrmOverview-Do9gZyXp.js +0 -1
- package/public/dist/assets/OrmWorker-CbMqo75N.js +0 -1
- package/public/dist/assets/Playground-Du-N1MUE.js +0 -1
- package/public/dist/assets/Profile-C5Ud1fuL.js +0 -2
- package/public/dist/assets/ProfileFields-DLOf6Qq0.js +0 -1
- package/public/dist/assets/Progress-CkIje-DQ.js +0 -1
- package/public/dist/assets/ProtocoleLiveGraph-Bshj1S3B.js +0 -1
- package/public/dist/assets/RealtimeConsole-C4CXeZZq.js +0 -1
- package/public/dist/assets/RingProgress-DeqkAVRv.js +0 -1
- package/public/dist/assets/RoleSwitch-BU7I1PPE.js +0 -1
- package/public/dist/assets/Roles-BWTctZs3.js +0 -1
- package/public/dist/assets/RoutesView-CR1UWe8B.js +0 -1
- package/public/dist/assets/Runtime-BHtf4TBU.js +0 -1
- package/public/dist/assets/Sessions-i2glvWc8.js +0 -1
- package/public/dist/assets/Skeleton-NxOTiVuM.js +0 -1
- package/public/dist/assets/Slider-y-O2hL1n.js +0 -1
- package/public/dist/assets/SondesLiveGraph-CV9As2oy.js +0 -1
- package/public/dist/assets/StoresView-B8S9lM2H.js +0 -1
- package/public/dist/assets/System--FzwVXGj.js +0 -1
- package/public/dist/assets/TagsInput-DvuBAi_b.js +0 -1
- package/public/dist/assets/Textarea-0nHULhaH.js +0 -1
- package/public/dist/assets/TraceView-xXewV_6u.js +0 -1
- package/public/dist/assets/Twin-BWXQlC2m.js +0 -19
- package/public/dist/assets/UserProfile-DPBWzlKz.js +0 -1
- package/public/dist/assets/Users-Q5OAmkhn.js +0 -1
- package/public/dist/assets/Webhooks-5TK8orJW.js +0 -1
- package/public/dist/assets/Workspace-DQFBpHtP.js +0 -1
- package/public/dist/assets/abnfDiagram-VCTEODGH-WkBbNL1D.js +0 -1
- package/public/dist/assets/apiKeysModel-D8T2auMK.js +0 -1
- package/public/dist/assets/arc-C7rN-mtx.js +0 -1
- package/public/dist/assets/architecture-7GRP2DOG-BUO4SOD5.js +0 -1
- package/public/dist/assets/architectureDiagram-5GKGNRK7-kgC6CT3l.js +0 -36
- package/public/dist/assets/array-BifhSqXX.js +0 -1
- package/public/dist/assets/auditFormat-DB8Rmevs.js +0 -1
- package/public/dist/assets/auditModel-BkLmFpDO.js +0 -1
- package/public/dist/assets/blockDiagram-I7D4REHJ-CmCsndSp.js +0 -129
- package/public/dist/assets/c4Diagram-7LVT6UL2-CVH6KZez.js +0 -38
- package/public/dist/assets/channel-B-6Trloh.js +0 -1
- package/public/dist/assets/chunk-2Q5K7J3B-C1jixKkw.js +0 -1
- package/public/dist/assets/chunk-4HAMMTFA-HrONVGii.js +0 -62
- package/public/dist/assets/chunk-5VM5RSS4-ZNzvKenW.js +0 -15
- package/public/dist/assets/chunk-75Z2AOVW-CNnr4_ra.js +0 -2
- package/public/dist/assets/chunk-DU6HZSFF-CLH64LYR.js +0 -127
- package/public/dist/assets/chunk-F27PBJKO-4Quz7TPv.js +0 -1
- package/public/dist/assets/chunk-FOHPRMQF-DHwB1DNv.js +0 -161
- package/public/dist/assets/chunk-GMAD6QVW-CTlRZ0-6.js +0 -72
- package/public/dist/assets/chunk-GVQU2GXP-_HjK1E2o.js +0 -1
- package/public/dist/assets/chunk-IMKFNOWR-Dk1yVJ9G.js +0 -231
- package/public/dist/assets/chunk-JWPE2WC7-DVXcaiue.js +0 -1
- package/public/dist/assets/chunk-L3NEJ4N5-BixACwUV.js +0 -1
- package/public/dist/assets/chunk-OSK3NFVY-BN1YkLED.js +0 -10
- package/public/dist/assets/chunk-P2QGCYS3-Dj7o6b6U.js +0 -1
- package/public/dist/assets/chunk-POPQ4Y6H-CBfRSTyU.js +0 -1
- package/public/dist/assets/chunk-PWAF6VOD-CkStCV2F.js +0 -1
- package/public/dist/assets/chunk-SHT3W25Y-CuJZSeHY.js +0 -168
- package/public/dist/assets/chunk-SVP7TREG-D7LG2uhU.js +0 -88
- package/public/dist/assets/chunk-TICWLB2K-CzB0UEgE.js +0 -206
- package/public/dist/assets/chunk-XXDRQBXY-IULPM7G2.js +0 -1
- package/public/dist/assets/chunk-Y2CYZVJY-DsF7k-Jl.js +0 -1
- package/public/dist/assets/classDiagram-ZZMXUADV-DV01XIvE.js +0 -1
- package/public/dist/assets/classDiagram-v2-VYDZK3BY-DV01XIvE.js +0 -1
- package/public/dist/assets/configModel-DBaUEvVw.js +0 -1
- package/public/dist/assets/cose-bilkent-JH36ORCC-Ce9VXEHd.js +0 -1
- package/public/dist/assets/cynefin-OW5HDTMX-C8wqLTsP.js +0 -1
- package/public/dist/assets/cynefinDiagram-5FMLGOSQ-B5Cin1Ci.js +0 -62
- package/public/dist/assets/cytoscape.esm-B-NFISlW.js +0 -321
- package/public/dist/assets/dagre-GXQ25YYZ-DvviZyEx.js +0 -4
- package/public/dist/assets/dagre-PrKaheQc.js +0 -1
- package/public/dist/assets/dayjs.min-G0uPySEd.js +0 -1
- package/public/dist/assets/defaultLocale-BFoDCU3G.js +0 -1
- package/public/dist/assets/diagram-S7CK7UJ4-C5JqsYNe.js +0 -30
- package/public/dist/assets/diagram-UQ7AKVKN-Db-WcYU3.js +0 -41
- package/public/dist/assets/diagram-VSXAHHWV-DLYOaf-U.js +0 -3
- package/public/dist/assets/diagram-VX7I27RA-DG1vwq_Z.js +0 -24
- package/public/dist/assets/diagram-Z3DM3KII-COOALIpz.js +0 -24
- package/public/dist/assets/dist-B9M-KAS4.js +0 -1
- package/public/dist/assets/ebnfDiagram-PWID7BFC-Cz2U9-CT.js +0 -1
- package/public/dist/assets/erDiagram-RLTQ6QDP-5s6s_K8-.js +0 -99
- package/public/dist/assets/eventFlow-BxbkeiAi.js +0 -1
- package/public/dist/assets/eventmodeling-NTZA5JFV-C9KM6bIl.js +0 -1
- package/public/dist/assets/firewallModel-DKOWcjIb.js +0 -1
- package/public/dist/assets/flowDiagram-HODETNUW-BIiGRZR1.js +0 -1
- package/public/dist/assets/ganttDiagram-EL5Y4UJY-DzRPEEeY.js +0 -292
- package/public/dist/assets/gitGraph-4MIJSDKK-nyJE_tIp.js +0 -1
- package/public/dist/assets/gitGraphDiagram-WWUBYQGX-C-eZWduS.js +0 -106
- package/public/dist/assets/graphlib-DS17s2tU.js +0 -1
- package/public/dist/assets/health-D8eXYj6Q.js +0 -1
- package/public/dist/assets/hooks-B7-tCb-b.js +0 -1
- package/public/dist/assets/info-A6RAGUB7-wKJToYPK.js +0 -1
- package/public/dist/assets/infoDiagram-27XIBGKW-DDljhPf-.js +0 -2
- package/public/dist/assets/init-C-OQMol4.js +0 -1
- package/public/dist/assets/ishikawaDiagram-5VMMS53U-lv5AIy32.js +0 -70
- package/public/dist/assets/journeyDiagram-3NMN7TZE-JGB_kL7G.js +0 -139
- package/public/dist/assets/kanban-definition-UXKFOSKX-Dh9QRXsf.js +0 -89
- package/public/dist/assets/katex-CXMH3UgJ.js +0 -257
- package/public/dist/assets/line-y6RZraoR.js +0 -1
- package/public/dist/assets/linear-B15ppzAf.js +0 -1
- package/public/dist/assets/mermaid-parser.core-BUBZKecf.js +0 -7
- package/public/dist/assets/mermaid.core-BmHyJa2W.js +0 -44
- package/public/dist/assets/mindmap-definition-YA3MSWOX-iPmbv5ia.js +0 -96
- package/public/dist/assets/ordinal-BDEzSJ7C.js +0 -1
- package/public/dist/assets/orm-CL-WJRcX.js +0 -1
- package/public/dist/assets/packet-AYTQ26CC-B0In6653.js +0 -1
- package/public/dist/assets/pageQuery-yJh2-jSv.js +0 -1
- package/public/dist/assets/path-fybaL0A-.js +0 -1
- package/public/dist/assets/pegDiagram-XKGWAZYB-eBxgvyfm.js +0 -1
- package/public/dist/assets/pie-WAS4IAKB-HXctBHyn.js +0 -1
- package/public/dist/assets/pieDiagram-E7YTZNPT-DPJZesoc.js +0 -39
- package/public/dist/assets/preload-helper-DqwykoZ_.js +0 -1
- package/public/dist/assets/profileVisuals-BgkBVLds.js +0 -1
- package/public/dist/assets/quadrantDiagram-AXDQQJYC-CGAwWfTf.js +0 -7
- package/public/dist/assets/radar-RG4KPBEZ-DxefsHHZ.js +0 -1
- package/public/dist/assets/railroad-74A4TZTK-BzDNMT-i.js +0 -1
- package/public/dist/assets/railroad-abnf-HS5TGJTU-NF34mUF2.js +0 -1
- package/public/dist/assets/railroad-ebnf-LZEXJU2U-D76bUqHC.js +0 -1
- package/public/dist/assets/railroad-peg-WCYAUIDC-DZecRsnp.js +0 -1
- package/public/dist/assets/railroadDiagram-O6MQD6OU-BddmTjGI.js +0 -1
- package/public/dist/assets/realtimeHealth-CEJDxl45.js +0 -1
- package/public/dist/assets/requirementDiagram-BXWQKSXE-Dk5fuOKt.js +0 -84
- package/public/dist/assets/rough.esm-Dy-Kn_BL.js +0 -1
- package/public/dist/assets/sankeyDiagram-P5KCCOFB-Do-pVyXW.js +0 -40
- package/public/dist/assets/sequenceDiagram-WJ2MYXX4-CpJ9IHo7.js +0 -162
- package/public/dist/assets/sizeCapture-INFHLROL-B0uUizjq.js +0 -1
- package/public/dist/assets/src-CmaQbKwl.js +0 -1
- package/public/dist/assets/src-Dvwdl2PF.js +0 -1
- package/public/dist/assets/stateDiagram-D77RDMKH-BAekZ4Ys.js +0 -1
- package/public/dist/assets/stateDiagram-v2-MP3YSRHH-q5CT9Q8p.js +0 -1
- package/public/dist/assets/stores-Bu1klAcv.js +0 -1
- package/public/dist/assets/storesModel-B7ZpgdOv.js +0 -1
- package/public/dist/assets/studio-BZmdX49T.css +0 -1
- package/public/dist/assets/studio-Vg_SkMIH.js +0 -28
- package/public/dist/assets/swimlanes-42K2YHIH-SkWPea07.js +0 -1
- package/public/dist/assets/swimlanesDiagram-VR7AAH4N-pm8r801G.js +0 -8
- package/public/dist/assets/timeline-definition-24CTP7MA-DoJt0xLz.js +0 -120
- package/public/dist/assets/treeView-Q6P3EWNA-C22UvP1Q.js +0 -1
- package/public/dist/assets/treemap-WGGIJYW6-DZhfmqd3.js +0 -1
- package/public/dist/assets/ui-Cftpc0m_.js +0 -296
- package/public/dist/assets/ui-DLioOiRN.css +0 -1
- package/public/dist/assets/useBlockSource-B_wJJBrV.js +0 -1
- package/public/dist/assets/useSocketLiveData-Be_WNbY1.js +0 -1
- package/public/dist/assets/usersFormat-BIENYgUO.js +0 -1
- package/public/dist/assets/value-B7TObl0n.js +0 -1
- package/public/dist/assets/vennDiagram-4TSXK5OY-CYY4Bogj.js +0 -34
- package/public/dist/assets/wardley-WFR3VGLG-C6XRVR6T.js +0 -1
- package/public/dist/assets/wardleyDiagram-VM6X3IG4-jl02g9S_.js +0 -78
- package/public/dist/assets/xychartDiagram-S5SC5T6Z-CeDhSaVJ.js +0 -7
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var e=typeof global==`object`&&global&&global.Object===Object&&global,t=typeof self==`object`&&self&&self.Object===Object&&self,n=e||t||Function(`return this`)(),r=n.Symbol,i=Object.prototype,a=i.hasOwnProperty,o=i.toString,s=r?r.toStringTag:void 0;function c(e){var t=a.call(e,s),n=e[s];try{e[s]=void 0;var r=!0}catch{}var i=o.call(e);return r&&(t?e[s]=n:delete e[s]),i}var l=Object.prototype.toString;function u(e){return l.call(e)}var d=`[object Null]`,f=`[object Undefined]`,p=r?r.toStringTag:void 0;function m(e){return e==null?e===void 0?f:d:p&&p in Object(e)?c(e):u(e)}function h(e){return typeof e==`object`&&!!e}var g=`[object Symbol]`;function _(e){return typeof e==`symbol`||h(e)&&m(e)==g}function v(e,t){for(var n=-1,r=e==null?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}var y=Array.isArray,ee=1/0,te=r?r.prototype:void 0,ne=te?te.toString:void 0;function re(e){if(typeof e==`string`)return e;if(y(e))return v(e,re)+``;if(_(e))return ne?ne.call(e):``;var t=e+``;return t==`0`&&1/e==-ee?`-0`:t}function b(e){var t=typeof e;return e!=null&&(t==`object`||t==`function`)}function x(e){return e}var ie=`[object AsyncFunction]`,ae=`[object Function]`,oe=`[object GeneratorFunction]`,se=`[object Proxy]`;function S(e){if(!b(e))return!1;var t=m(e);return t==ae||t==oe||t==ie||t==se}var ce=n[`__core-js_shared__`],le=function(){var e=/[^.]+$/.exec(ce&&ce.keys&&ce.keys.IE_PROTO||``);return e?`Symbol(src)_1.`+e:``}();function ue(e){return!!le&&le in e}var de=Function.prototype.toString;function C(e){if(e!=null){try{return de.call(e)}catch{}try{return e+``}catch{}}return``}var fe=/[\\^$.*+?()[\]{}|]/g,pe=/^\[object .+?Constructor\]$/,me=Function.prototype,he=Object.prototype,ge=me.toString,_e=he.hasOwnProperty,ve=RegExp(`^`+ge.call(_e).replace(fe,`\\$&`).replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,`$1.*?`)+`$`);function ye(e){return!b(e)||ue(e)?!1:(S(e)?ve:pe).test(C(e))}function be(e,t){return e?.[t]}function w(e,t){var n=be(e,t);return ye(n)?n:void 0}var xe=w(n,`WeakMap`);function Se(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function Ce(){}var we=800,Te=16,Ee=Date.now;function De(e){var t=0,n=0;return function(){var r=Ee(),i=Te-(r-n);if(n=r,i>0){if(++t>=we)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function T(e){return function(){return e}}var Oe=function(){try{var e=w(Object,`defineProperty`);return e({},``,{}),e}catch{}}(),ke=De(Oe?function(e,t){return Oe(e,`toString`,{configurable:!0,enumerable:!1,value:T(t),writable:!0})}:x);function Ae(e,t){for(var n=-1,r=e==null?0:e.length;++n<r&&t(e[n],n,e)!==!1;);return e}function je(e,t,n,r){for(var i=e.length,a=n+(r?1:-1);r?a--:++a<i;)if(t(e[a],a,e))return a;return-1}function Me(e){return e!==e}function Ne(e,t,n){for(var r=n-1,i=e.length;++r<i;)if(e[r]===t)return r;return-1}function Pe(e,t,n){return t===t?Ne(e,t,n):je(e,Me,n)}function Fe(e,t){return!!(e!=null&&e.length)&&Pe(e,t,0)>-1}var Ie=9007199254740991,Le=/^(?:0|[1-9]\d*)$/;function Re(e,t){var n=typeof e;return t??=Ie,!!t&&(n==`number`||n!=`symbol`&&Le.test(e))&&e>-1&&e%1==0&&e<t}function ze(e,t){return e===t||e!==e&&t!==t}var Be=Math.max;function Ve(e,t,n){return t=Be(t===void 0?e.length-1:t,0),function(){for(var r=arguments,i=-1,a=Be(r.length-t,0),o=Array(a);++i<a;)o[i]=r[t+i];i=-1;for(var s=Array(t+1);++i<t;)s[i]=r[i];return s[t]=n(o),Se(e,this,s)}}function He(e,t){return ke(Ve(e,t,x),e+``)}var Ue=9007199254740991;function We(e){return typeof e==`number`&&e>-1&&e%1==0&&e<=Ue}function E(e){return e!=null&&We(e.length)&&!S(e)}var Ge=Object.prototype;function Ke(e){var t=e&&e.constructor;return e===(typeof t==`function`&&t.prototype||Ge)}function qe(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}var Je=`[object Arguments]`;function Ye(e){return h(e)&&m(e)==Je}var Xe=Object.prototype,Ze=Xe.hasOwnProperty,Qe=Xe.propertyIsEnumerable,D=Ye(function(){return arguments}())?Ye:function(e){return h(e)&&Ze.call(e,`callee`)&&!Qe.call(e,`callee`)};function $e(){return!1}var et=typeof exports==`object`&&exports&&!exports.nodeType&&exports,tt=et&&typeof module==`object`&&module&&!module.nodeType&&module,nt=tt&&tt.exports===et?n.Buffer:void 0,O=(nt?nt.isBuffer:void 0)||$e,rt=`[object Arguments]`,it=`[object Array]`,at=`[object Boolean]`,ot=`[object Date]`,st=`[object Error]`,ct=`[object Function]`,lt=`[object Map]`,ut=`[object Number]`,dt=`[object Object]`,ft=`[object RegExp]`,pt=`[object Set]`,mt=`[object String]`,ht=`[object WeakMap]`,gt=`[object ArrayBuffer]`,_t=`[object DataView]`,vt=`[object Float32Array]`,yt=`[object Float64Array]`,bt=`[object Int8Array]`,xt=`[object Int16Array]`,St=`[object Int32Array]`,Ct=`[object Uint8Array]`,wt=`[object Uint8ClampedArray]`,Tt=`[object Uint16Array]`,Et=`[object Uint32Array]`,k={};k[vt]=k[yt]=k[bt]=k[xt]=k[St]=k[Ct]=k[wt]=k[Tt]=k[Et]=!0,k[rt]=k[it]=k[gt]=k[at]=k[_t]=k[ot]=k[st]=k[ct]=k[lt]=k[ut]=k[dt]=k[ft]=k[pt]=k[mt]=k[ht]=!1;function Dt(e){return h(e)&&We(e.length)&&!!k[m(e)]}function Ot(e){return function(t){return e(t)}}var kt=typeof exports==`object`&&exports&&!exports.nodeType&&exports,A=kt&&typeof module==`object`&&module&&!module.nodeType&&module,At=A&&A.exports===kt&&e.process,jt=function(){try{return A&&A.require&&A.require(`util`).types||At&&At.binding&&At.binding(`util`)}catch{}}(),Mt=jt&&jt.isTypedArray,j=Mt?Ot(Mt):Dt,Nt=Object.prototype.hasOwnProperty;function Pt(e,t){var n=y(e),r=!n&&D(e),i=!n&&!r&&O(e),a=!n&&!r&&!i&&j(e),o=n||r||i||a,s=o?qe(e.length,String):[],c=s.length;for(var l in e)(t||Nt.call(e,l))&&!(o&&(l==`length`||i&&(l==`offset`||l==`parent`)||a&&(l==`buffer`||l==`byteLength`||l==`byteOffset`)||Re(l,c)))&&s.push(l);return s}function Ft(e,t){return function(n){return e(t(n))}}var It=Ft(Object.keys,Object),Lt=Object.prototype.hasOwnProperty;function Rt(e){if(!Ke(e))return It(e);var t=[];for(var n in Object(e))Lt.call(e,n)&&n!=`constructor`&&t.push(n);return t}function M(e){return E(e)?Pt(e):Rt(e)}var zt=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Bt=/^\w*$/;function Vt(e,t){if(y(e))return!1;var n=typeof e;return n==`number`||n==`symbol`||n==`boolean`||e==null||_(e)?!0:Bt.test(e)||!zt.test(e)||t!=null&&e in Object(t)}var N=w(Object,`create`);function Ht(){this.__data__=N?N(null):{},this.size=0}function Ut(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=+!!t,t}var Wt=`__lodash_hash_undefined__`,Gt=Object.prototype.hasOwnProperty;function Kt(e){var t=this.__data__;if(N){var n=t[e];return n===Wt?void 0:n}return Gt.call(t,e)?t[e]:void 0}var qt=Object.prototype.hasOwnProperty;function Jt(e){var t=this.__data__;return N?t[e]!==void 0:qt.call(t,e)}var Yt=`__lodash_hash_undefined__`;function Xt(e,t){var n=this.__data__;return this.size+=+!this.has(e),n[e]=N&&t===void 0?Yt:t,this}function P(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}P.prototype.clear=Ht,P.prototype.delete=Ut,P.prototype.get=Kt,P.prototype.has=Jt,P.prototype.set=Xt;function Zt(){this.__data__=[],this.size=0}function F(e,t){for(var n=e.length;n--;)if(ze(e[n][0],t))return n;return-1}var Qt=Array.prototype.splice;function $t(e){var t=this.__data__,n=F(t,e);return n<0?!1:(n==t.length-1?t.pop():Qt.call(t,n,1),--this.size,!0)}function en(e){var t=this.__data__,n=F(t,e);return n<0?void 0:t[n][1]}function tn(e){return F(this.__data__,e)>-1}function nn(e,t){var n=this.__data__,r=F(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}function I(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}I.prototype.clear=Zt,I.prototype.delete=$t,I.prototype.get=en,I.prototype.has=tn,I.prototype.set=nn;var L=w(n,`Map`);function rn(){this.size=0,this.__data__={hash:new P,map:new(L||I),string:new P}}function an(e){var t=typeof e;return t==`string`||t==`number`||t==`symbol`||t==`boolean`?e!==`__proto__`:e===null}function R(e,t){var n=e.__data__;return an(t)?n[typeof t==`string`?`string`:`hash`]:n.map}function on(e){var t=R(this,e).delete(e);return this.size-=+!!t,t}function sn(e){return R(this,e).get(e)}function cn(e){return R(this,e).has(e)}function ln(e,t){var n=R(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}function z(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}z.prototype.clear=rn,z.prototype.delete=on,z.prototype.get=sn,z.prototype.has=cn,z.prototype.set=ln;var un=`Expected a function`;function dn(e,t){if(typeof e!=`function`||t!=null&&typeof t!=`function`)throw TypeError(un);var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],a=n.cache;if(a.has(i))return a.get(i);var o=e.apply(this,r);return n.cache=a.set(i,o)||a,o};return n.cache=new(dn.Cache||z),n}dn.Cache=z;var fn=500;function pn(e){var t=dn(e,function(e){return n.size===fn&&n.clear(),e}),n=t.cache;return t}var mn=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,hn=/\\(\\)?/g,gn=pn(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(``),e.replace(mn,function(e,n,r,i){t.push(r?i.replace(hn,`$1`):n||e)}),t});function _n(e){return e==null?``:re(e)}function vn(e,t){return y(e)?e:Vt(e,t)?[e]:gn(_n(e))}var yn=1/0;function B(e){if(typeof e==`string`||_(e))return e;var t=e+``;return t==`0`&&1/e==-yn?`-0`:t}function bn(e,t){t=vn(t,e);for(var n=0,r=t.length;e!=null&&n<r;)e=e[B(t[n++])];return n&&n==r?e:void 0}function xn(e,t,n){var r=e==null?void 0:bn(e,t);return r===void 0?n:r}function Sn(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}var Cn=r?r.isConcatSpreadable:void 0;function wn(e){return y(e)||D(e)||!!(Cn&&e&&e[Cn])}function Tn(e,t,n,r,i){var a=-1,o=e.length;for(n||=wn,i||=[];++a<o;){var s=e[a];t>0&&n(s)?t>1?Tn(s,t-1,n,r,i):Sn(i,s):r||(i[i.length]=s)}return i}function En(e,t,n,r){var i=-1,a=e==null?0:e.length;for(r&&a&&(n=e[++i]);++i<a;)n=t(n,e[i],i,e);return n}function Dn(){this.__data__=new I,this.size=0}function On(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}function kn(e){return this.__data__.get(e)}function An(e){return this.__data__.has(e)}var jn=200;function Mn(e,t){var n=this.__data__;if(n instanceof I){var r=n.__data__;if(!L||r.length<jn-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new z(r)}return n.set(e,t),this.size=n.size,this}function V(e){var t=this.__data__=new I(e);this.size=t.size}V.prototype.clear=Dn,V.prototype.delete=On,V.prototype.get=kn,V.prototype.has=An,V.prototype.set=Mn;function Nn(e,t){for(var n=-1,r=e==null?0:e.length,i=0,a=[];++n<r;){var o=e[n];t(o,n,e)&&(a[i++]=o)}return a}function Pn(){return[]}var Fn=Object.prototype.propertyIsEnumerable,In=Object.getOwnPropertySymbols,Ln=In?function(e){return e==null?[]:(e=Object(e),Nn(In(e),function(t){return Fn.call(e,t)}))}:Pn;function Rn(e,t,n){var r=t(e);return y(e)?r:Sn(r,n(e))}function zn(e){return Rn(e,M,Ln)}var Bn=w(n,`DataView`),Vn=w(n,`Promise`),H=w(n,`Set`),Hn=`[object Map]`,Un=`[object Object]`,Wn=`[object Promise]`,Gn=`[object Set]`,Kn=`[object WeakMap]`,qn=`[object DataView]`,Jn=C(Bn),Yn=C(L),Xn=C(Vn),Zn=C(H),Qn=C(xe),U=m;(Bn&&U(new Bn(new ArrayBuffer(1)))!=qn||L&&U(new L)!=Hn||Vn&&U(Vn.resolve())!=Wn||H&&U(new H)!=Gn||xe&&U(new xe)!=Kn)&&(U=function(e){var t=m(e),n=t==Un?e.constructor:void 0,r=n?C(n):``;if(r)switch(r){case Jn:return qn;case Yn:return Hn;case Xn:return Wn;case Zn:return Gn;case Qn:return Kn}return t});var W=U,$n=n.Uint8Array,er=`__lodash_hash_undefined__`;function tr(e){return this.__data__.set(e,er),this}function nr(e){return this.__data__.has(e)}function G(e){var t=-1,n=e==null?0:e.length;for(this.__data__=new z;++t<n;)this.add(e[t])}G.prototype.add=G.prototype.push=tr,G.prototype.has=nr;function rr(e,t){for(var n=-1,r=e==null?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}function ir(e,t){return e.has(t)}var ar=1,or=2;function sr(e,t,n,r,i,a){var o=n&ar,s=e.length,c=t.length;if(s!=c&&!(o&&c>s))return!1;var l=a.get(e),u=a.get(t);if(l&&u)return l==t&&u==e;var d=-1,f=!0,p=n&or?new G:void 0;for(a.set(e,t),a.set(t,e);++d<s;){var m=e[d],h=t[d];if(r)var g=o?r(h,m,d,t,e,a):r(m,h,d,e,t,a);if(g!==void 0){if(g)continue;f=!1;break}if(p){if(!rr(t,function(e,t){if(!ir(p,t)&&(m===e||i(m,e,n,r,a)))return p.push(t)})){f=!1;break}}else if(!(m===h||i(m,h,n,r,a))){f=!1;break}}return a.delete(e),a.delete(t),f}function cr(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}function lr(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}var ur=1,dr=2,fr=`[object Boolean]`,pr=`[object Date]`,mr=`[object Error]`,hr=`[object Map]`,gr=`[object Number]`,_r=`[object RegExp]`,vr=`[object Set]`,yr=`[object String]`,br=`[object Symbol]`,xr=`[object ArrayBuffer]`,Sr=`[object DataView]`,Cr=r?r.prototype:void 0,wr=Cr?Cr.valueOf:void 0;function Tr(e,t,n,r,i,a,o){switch(n){case Sr:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case xr:return!(e.byteLength!=t.byteLength||!a(new $n(e),new $n(t)));case fr:case pr:case gr:return ze(+e,+t);case mr:return e.name==t.name&&e.message==t.message;case _r:case yr:return e==t+``;case hr:var s=cr;case vr:var c=r&ur;if(s||=lr,e.size!=t.size&&!c)return!1;var l=o.get(e);if(l)return l==t;r|=dr,o.set(e,t);var u=sr(s(e),s(t),r,i,a,o);return o.delete(e),u;case br:if(wr)return wr.call(e)==wr.call(t)}return!1}var Er=1,Dr=Object.prototype.hasOwnProperty;function Or(e,t,n,r,i,a){var o=n&Er,s=zn(e),c=s.length;if(c!=zn(t).length&&!o)return!1;for(var l=c;l--;){var u=s[l];if(!(o?u in t:Dr.call(t,u)))return!1}var d=a.get(e),f=a.get(t);if(d&&f)return d==t&&f==e;var p=!0;a.set(e,t),a.set(t,e);for(var m=o;++l<c;){u=s[l];var h=e[u],g=t[u];if(r)var _=o?r(g,h,u,t,e,a):r(h,g,u,e,t,a);if(!(_===void 0?h===g||i(h,g,n,r,a):_)){p=!1;break}m||=u==`constructor`}if(p&&!m){var v=e.constructor,y=t.constructor;v!=y&&`constructor`in e&&`constructor`in t&&!(typeof v==`function`&&v instanceof v&&typeof y==`function`&&y instanceof y)&&(p=!1)}return a.delete(e),a.delete(t),p}var kr=1,Ar=`[object Arguments]`,jr=`[object Array]`,K=`[object Object]`,Mr=Object.prototype.hasOwnProperty;function Nr(e,t,n,r,i,a){var o=y(e),s=y(t),c=o?jr:W(e),l=s?jr:W(t);c=c==Ar?K:c,l=l==Ar?K:l;var u=c==K,d=l==K,f=c==l;if(f&&O(e)){if(!O(t))return!1;o=!0,u=!1}if(f&&!u)return a||=new V,o||j(e)?sr(e,t,n,r,i,a):Tr(e,t,c,n,r,i,a);if(!(n&kr)){var p=u&&Mr.call(e,`__wrapped__`),m=d&&Mr.call(t,`__wrapped__`);if(p||m){var h=p?e.value():e,g=m?t.value():t;return a||=new V,i(h,g,n,r,a)}}return f?(a||=new V,Or(e,t,n,r,i,a)):!1}function Pr(e,t,n,r,i){return e===t?!0:e==null||t==null||!h(e)&&!h(t)?e!==e&&t!==t:Nr(e,t,n,r,Pr,i)}var Fr=1,Ir=2;function Lr(e,t,n,r){var i=n.length,a=i,o=!r;if(e==null)return!a;for(e=Object(e);i--;){var s=n[i];if(o&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++i<a;){s=n[i];var c=s[0],l=e[c],u=s[1];if(o&&s[2]){if(l===void 0&&!(c in e))return!1}else{var d=new V;if(r)var f=r(l,u,c,e,t,d);if(!(f===void 0?Pr(u,l,Fr|Ir,r,d):f))return!1}}return!0}function Rr(e){return e===e&&!b(e)}function zr(e){for(var t=M(e),n=t.length;n--;){var r=t[n],i=e[r];t[n]=[r,i,Rr(i)]}return t}function Br(e,t){return function(n){return n!=null&&n[e]===t&&(t!==void 0||e in Object(n))}}function Vr(e){var t=zr(e);return t.length==1&&t[0][2]?Br(t[0][0],t[0][1]):function(n){return n===e||Lr(n,e,t)}}function Hr(e,t){return e!=null&&t in Object(e)}function Ur(e,t,n){t=vn(t,e);for(var r=-1,i=t.length,a=!1;++r<i;){var o=B(t[r]);if(!(a=e!=null&&n(e,o)))break;e=e[o]}return a||++r!=i?a:(i=e==null?0:e.length,!!i&&We(i)&&Re(o,i)&&(y(e)||D(e)))}function Wr(e,t){return e!=null&&Ur(e,t,Hr)}var Gr=1,Kr=2;function qr(e,t){return Vt(e)&&Rr(t)?Br(B(e),t):function(n){var r=xn(n,e);return r===void 0&&r===t?Wr(n,e):Pr(t,r,Gr|Kr)}}function Jr(e){return function(t){return t?.[e]}}function Yr(e){return function(t){return bn(t,e)}}function Xr(e){return Vt(e)?Jr(B(e)):Yr(e)}function Zr(e){return typeof e==`function`?e:e==null?x:typeof e==`object`?y(e)?qr(e[0],e[1]):Vr(e):Xr(e)}function Qr(e){return function(t,n,r){for(var i=-1,a=Object(t),o=r(t),s=o.length;s--;){var c=o[e?s:++i];if(n(a[c],c,a)===!1)break}return t}}var $r=Qr();function ei(e,t){return e&&$r(e,t,M)}function ti(e,t){return function(n,r){if(n==null)return n;if(!E(n))return e(n,r);for(var i=n.length,a=t?i:-1,o=Object(n);(t?a--:++a<i)&&r(o[a],a,o)!==!1;);return n}}var q=ti(ei);function ni(e){return h(e)&&E(e)}function ri(e,t,n){for(var r=-1,i=e==null?0:e.length;++r<i;)if(n(t,e[r]))return!0;return!1}function ii(e){return typeof e==`function`?e:x}function J(e,t){return(y(e)?Ae:q)(e,ii(t))}function ai(e,t){var n=[];return q(e,function(e,r,i){t(e,r,i)&&n.push(e)}),n}function Y(e,t){return(y(e)?Nn:ai)(e,Zr(t,3))}function oi(e,t){return v(t,function(t){return e[t]})}function X(e){return e==null?[]:oi(e,M(e))}var si=`[object Map]`,ci=`[object Set]`,li=Object.prototype.hasOwnProperty;function ui(e){if(e==null)return!0;if(E(e)&&(y(e)||typeof e==`string`||typeof e.splice==`function`||O(e)||j(e)||D(e)))return!e.length;var t=W(e);if(t==si||t==ci)return!e.size;if(Ke(e))return!Rt(e).length;for(var n in e)if(li.call(e,n))return!1;return!0}function Z(e){return e===void 0}function di(e,t,n,r,i){return i(e,function(e,i,a){n=r?(r=!1,e):t(n,e,i,a)}),n}function fi(e,t,n){var r=y(e)?En:di,i=arguments.length<3;return r(e,Zr(t,4),n,i,q)}var pi=H&&1/lr(new H([,-0]))[1]==1/0?function(e){return new H(e)}:Ce,mi=200;function hi(e,t,n){var r=-1,i=Fe,a=e.length,o=!0,s=[],c=s;if(n)o=!1,i=ri;else if(a>=mi){var l=t?null:pi(e);if(l)return lr(l);o=!1,i=ir,c=new G}else c=t?[]:s;outer:for(;++r<a;){var u=e[r],d=t?t(u):u;if(u=n||u!==0?u:0,o&&d===d){for(var f=c.length;f--;)if(c[f]===d)continue outer;t&&c.push(d),s.push(u)}else i(c,d,n)||(c!==s&&c.push(d),s.push(u))}return s}var gi=He(function(e){return hi(Tn(e,1,ni,!0))}),_i=`\0`,Q=`\0`,vi=``,yi=class{constructor(e={}){this._isDirected=!Object.prototype.hasOwnProperty.call(e,`directed`)||e.directed,this._isMultigraph=Object.prototype.hasOwnProperty.call(e,`multigraph`)?e.multigraph:!1,this._isCompound=Object.prototype.hasOwnProperty.call(e,`compound`)?e.compound:!1,this._label=void 0,this._defaultNodeLabelFn=T(void 0),this._defaultEdgeLabelFn=T(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[Q]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}isDirected(){return this._isDirected}isMultigraph(){return this._isMultigraph}isCompound(){return this._isCompound}setGraph(e){return this._label=e,this}graph(){return this._label}setDefaultNodeLabel(e){return S(e)||(e=T(e)),this._defaultNodeLabelFn=e,this}nodeCount(){return this._nodeCount}nodes(){return M(this._nodes)}sources(){var e=this;return Y(this.nodes(),function(t){return ui(e._in[t])})}sinks(){var e=this;return Y(this.nodes(),function(t){return ui(e._out[t])})}setNodes(e,t){var n=arguments,r=this;return J(e,function(e){n.length>1?r.setNode(e,t):r.setNode(e)}),this}setNode(e,t){return Object.prototype.hasOwnProperty.call(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=t),this):(this._nodes[e]=arguments.length>1?t:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=Q,this._children[e]={},this._children[Q][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)}node(e){return this._nodes[e]}hasNode(e){return Object.prototype.hasOwnProperty.call(this._nodes,e)}removeNode(e){if(Object.prototype.hasOwnProperty.call(this._nodes,e)){var t=e=>this.removeEdge(this._edgeObjs[e]);delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],J(this.children(e),e=>{this.setParent(e)}),delete this._children[e]),J(M(this._in[e]),t),delete this._in[e],delete this._preds[e],J(M(this._out[e]),t),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this}setParent(e,t){if(!this._isCompound)throw Error(`Cannot set parent in a non-compound graph`);if(Z(t))t=Q;else{t+=``;for(var n=t;!Z(n);n=this.parent(n))if(n===e)throw Error(`Setting `+t+` as parent of `+e+` would create a cycle`);this.setNode(t)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=t,this._children[t][e]=!0,this}_removeFromParentsChildList(e){delete this._children[this._parent[e]][e]}parent(e){if(this._isCompound){var t=this._parent[e];if(t!==Q)return t}}children(e){if(Z(e)&&(e=Q),this._isCompound){var t=this._children[e];if(t)return M(t)}else if(e===Q)return this.nodes();else if(this.hasNode(e))return[]}predecessors(e){var t=this._preds[e];if(t)return M(t)}successors(e){var t=this._sucs[e];if(t)return M(t)}neighbors(e){var t=this.predecessors(e);if(t)return gi(t,this.successors(e))}isLeaf(e){return(this.isDirected()?this.successors(e):this.neighbors(e)).length===0}filterNodes(e){var t=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});t.setGraph(this.graph());var n=this;J(this._nodes,function(n,r){e(r)&&t.setNode(r,n)}),J(this._edgeObjs,function(e){t.hasNode(e.v)&&t.hasNode(e.w)&&t.setEdge(e,n.edge(e))});var r={};function i(e){var a=n.parent(e);return a===void 0||t.hasNode(a)?(r[e]=a,a):a in r?r[a]:i(a)}return this._isCompound&&J(t.nodes(),function(e){t.setParent(e,i(e))}),t}setDefaultEdgeLabel(e){return S(e)||(e=T(e)),this._defaultEdgeLabelFn=e,this}edgeCount(){return this._edgeCount}edges(){return X(this._edgeObjs)}setPath(e,t){var n=this,r=arguments;return fi(e,function(e,i){return r.length>1?n.setEdge(e,i,t):n.setEdge(e,i),i}),this}setEdge(){var e,t,n,r,i=!1,a=arguments[0];typeof a==`object`&&a&&`v`in a?(e=a.v,t=a.w,n=a.name,arguments.length===2&&(r=arguments[1],i=!0)):(e=a,t=arguments[1],n=arguments[3],arguments.length>2&&(r=arguments[2],i=!0)),e=``+e,t=``+t,Z(n)||(n=``+n);var o=$(this._isDirected,e,t,n);if(Object.prototype.hasOwnProperty.call(this._edgeLabels,o))return i&&(this._edgeLabels[o]=r),this;if(!Z(n)&&!this._isMultigraph)throw Error(`Cannot set a named edge when isMultigraph = false`);this.setNode(e),this.setNode(t),this._edgeLabels[o]=i?r:this._defaultEdgeLabelFn(e,t,n);var s=Si(this._isDirected,e,t,n);return e=s.v,t=s.w,Object.freeze(s),this._edgeObjs[o]=s,bi(this._preds[t],e),bi(this._sucs[e],t),this._in[t][o]=s,this._out[e][o]=s,this._edgeCount++,this}edge(e,t,n){var r=arguments.length===1?Ci(this._isDirected,arguments[0]):$(this._isDirected,e,t,n);return this._edgeLabels[r]}hasEdge(e,t,n){var r=arguments.length===1?Ci(this._isDirected,arguments[0]):$(this._isDirected,e,t,n);return Object.prototype.hasOwnProperty.call(this._edgeLabels,r)}removeEdge(e,t,n){var r=arguments.length===1?Ci(this._isDirected,arguments[0]):$(this._isDirected,e,t,n),i=this._edgeObjs[r];return i&&(e=i.v,t=i.w,delete this._edgeLabels[r],delete this._edgeObjs[r],xi(this._preds[t],e),xi(this._sucs[e],t),delete this._in[t][r],delete this._out[e][r],this._edgeCount--),this}inEdges(e,t){var n=this._in[e];if(n){var r=X(n);return t?Y(r,function(e){return e.v===t}):r}}outEdges(e,t){var n=this._out[e];if(n){var r=X(n);return t?Y(r,function(e){return e.w===t}):r}}nodeEdges(e,t){var n=this.inEdges(e,t);if(n)return n.concat(this.outEdges(e,t))}};yi.prototype._nodeCount=0,yi.prototype._edgeCount=0;function bi(e,t){e[t]?e[t]++:e[t]=1}function xi(e,t){--e[t]||delete e[t]}function $(e,t,n,r){var i=``+t,a=``+n;if(!e&&i>a){var o=i;i=a,a=o}return i+vi+a+vi+(Z(r)?_i:r)}function Si(e,t,n,r){var i=``+t,a=``+n;if(!e&&i>a){var o=i;i=a,a=o}var s={v:i,w:a};return r&&(s.name=r),s}function Ci(e,t){return $(e,t.v,t.w,t.name)}export{v as $,Rt as A,He as B,Tn as C,vn as D,B as E,Ot as F,Ae as G,ze as H,O as I,T as J,ke as K,D as L,Pt as M,j as N,_n as O,jt as P,y as Q,Ke as R,V as S,bn as T,Re as U,Ve as V,je as W,x as X,S as Y,b as Z,W as _,Y as a,Ln as b,ni as c,$r as d,_ as et,Zr as f,$n as g,Ur as h,X as i,n as it,Ft as j,M as k,q as l,Wr as m,fi as n,m as nt,J as o,Jr as p,Oe as q,Z as r,r as rt,ii as s,yi as t,h as tt,ei as u,zn as v,Sn as w,Pn as x,Rn as y,E as z};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var e=`nf.supervision.weights`,t={CPU:1,"Saturation (ELU)":1.5,"Event-loop":1.5,"Mémoire (heap)":1,"GC overhead":.8,Erreurs:1.2,Connecteurs:1,"Temps réel":.5};function n(e,t,n){return n<=t?+(e<=t):e<=t?1:e>=n?0:(n-e)/(n-t)}function r(e){let t=e.filter(e=>e.value!=null&&e.weight>0);if(!t.length)return{score:null,label:`—`,color:`gray`,worst:null,parts:[]};let r=!1,i=0,a=0,o=null,s=2,c=[];for(let e of t){let t=n(e.value,e.good,e.crit),l=Math.max(t,e.floor??0);c.push({label:e.label,score:Math.round(l*100),weight:e.weight,kind:e.critical?`fail`:`sat`}),l<s&&(s=l,o=e),e.critical&&t<=0&&(r=!0),i+=e.weight,a+=e.weight*Math.log(Math.max(l,1e-9))}let l=r?0:Math.exp(a/i),u=Math.round(l*100),[d,f]=u>=90?[`Excellent`,`teal`]:u>=75?[`Bon`,`green`]:u>=50?[`À surveiller`,`yellow`]:u>=25?[`Dégradé`,`orange`]:[`Critique`,`red`];return{score:u,label:d,color:f,worst:o?.label??null,parts:c}}function i(){try{let n=typeof localStorage<`u`?localStorage.getItem(e):null;if(n){let e=JSON.parse(n);if(e&&typeof e==`object`)return{...t,...e}}}catch{}return{...t}}export{i,e as n,r,t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{k as e}from"./src-Dvwdl2PF.js";import{di as t}from"./ui-Cftpc0m_.js";var n=/^(?:[a-z][a-z0-9+.-]*:|[\\/]{2})/i,r=/^[\\/]{2}/;function i(e,t){return t+e.replace(/\\/g,`/`)}var a=`popstate`;function o(e){return typeof e==`object`&&!!e&&`pathname`in e&&`search`in e&&`hash`in e&&`state`in e&&`key`in e}function s(e={}){function t(e,t){let n=t.state?.masked,{pathname:r,search:i,hash:a}=n||e.location;return f(``,{pathname:r,search:i,hash:a},t.state&&t.state.usr||null,t.state&&t.state.key||`default`,n?{pathname:e.location.pathname,search:e.location.search,hash:e.location.hash}:void 0)}function n(e,t){return typeof t==`string`?t:p(t)}return h(t,n,null,e)}function c(e,t){if(e===!1||e==null)throw Error(t)}function l(e,t){if(!e){typeof console<`u`&&console.warn(t);try{throw Error(t)}catch{}}}function u(){return Math.random().toString(36).substring(2,10)}function d(e,t){return{usr:e.state,key:e.key,idx:t,masked:e.mask?{pathname:e.pathname,search:e.search,hash:e.hash}:void 0}}function f(e,t,n=null,r,i){return{pathname:typeof e==`string`?e:e.pathname,search:``,hash:``,...typeof t==`string`?m(t):t,state:n,key:t&&t.key||r||u(),mask:i}}function p({pathname:e=`/`,search:t=``,hash:n=``}){return t&&t!==`?`&&(e+=t.charAt(0)===`?`?t:`?`+t),n&&n!==`#`&&(e+=n.charAt(0)===`#`?n:`#`+n),e}function m(e){let t={};if(e){let n=e.indexOf(`#`);n>=0&&(t.hash=e.substring(n),e=e.substring(0,n));let r=e.indexOf(`?`);r>=0&&(t.search=e.substring(r),e=e.substring(0,r)),e&&(t.pathname=e)}return t}function h(e,t,n,r={}){let{window:i=document.defaultView,v5Compat:s=!1}=r,c=i.history,l=`POP`,u=null,p=m();p??(p=0,c.replaceState({...c.state,idx:p},``));function m(){return(c.state||{idx:null}).idx}function h(){l=`POP`;let e=m(),t=e==null?null:e-p;p=e,u&&u({action:l,location:b.location,delta:t})}function _(e,t){l=`PUSH`;let r=o(e)?e:f(b.location,e,t);n&&n(r,e),p=m()+1;let a=d(r,p),h=b.createHref(r.mask||r);try{c.pushState(a,``,h)}catch(e){if(e instanceof DOMException&&e.name===`DataCloneError`)throw e;i.location.assign(h)}s&&u&&u({action:l,location:b.location,delta:1})}function v(e,t){l=`REPLACE`;let r=o(e)?e:f(b.location,e,t);n&&n(r,e),p=m();let i=d(r,p),a=b.createHref(r.mask||r);c.replaceState(i,``,a),s&&u&&u({action:l,location:b.location,delta:0})}function y(e){return g(i,e)}let b={get action(){return l},get location(){return e(i,c)},listen(e){if(u)throw Error(`A history only accepts one active listener`);return i.addEventListener(a,h),u=e,()=>{i.removeEventListener(a,h),u=null}},createHref(e){return t(i,e)},createURL:y,encodeLocation(e){let t=y(e);return{pathname:t.pathname,search:t.search,hash:t.hash}},push:_,replace:v,go(e){return c.go(e)}};return b}function g(e,t,n=!1){let i=`http://localhost`;e&&(i=e.location.origin===`null`?e.location.href:e.location.origin),c(i,`No window.location.(origin|href) available to create URL`);let a=typeof t==`string`?t:p(t);return a=a.replace(/ $/,`%20`),!n&&r.test(a)&&(a=i+a),new URL(a,i)}var _=e(t(),1),v=class{#e=new Map;constructor(e){if(e)for(let[t,n]of e)this.set(t,n)}get(e){if(this.#e.has(e))return this.#e.get(e);if(e.defaultValue!==void 0)return e.defaultValue;throw Error(`No value found for context`)}set(e,t){this.#e.set(e,t)}},y=new Set([`lazy`,`caseSensitive`,`path`,`id`,`index`,`children`]);function b(e){return y.has(e)}var x=new Set([`lazy`,`caseSensitive`,`path`,`id`,`index`,`middleware`,`children`]);function S(e){return x.has(e)}function C(e){return e.index===!0}function w(e){let t={};return e.Component&&Object.assign(t,{element:_.createElement(e.Component),Component:void 0}),e.HydrateFallback&&Object.assign(t,{hydrateFallbackElement:_.createElement(e.HydrateFallback),HydrateFallback:void 0}),e.ErrorBoundary&&Object.assign(t,{errorElement:_.createElement(e.ErrorBoundary),ErrorBoundary:void 0}),t}function T(e,t=w,n=[],r={},i=!1){return e.map((e,a)=>{let o=[...n,String(a)],s=typeof e.id==`string`?e.id:o.join(`-`);if(c(e.index!==!0||!e.children,`Cannot specify children on an index route`),c(i||!r[s],`Found a route id collision on id "${s}". Route id's must be globally unique within Data Router usages`),C(e)){let n={...e,id:s};return r[s]=E(n,t(n)),n}{let n={...e,id:s,children:void 0};return r[s]=E(n,t(n)),e.children&&(n.children=T(e.children,t,o,r,i)),n}})}function E(e,t){return Object.assign(e,{...t,...typeof t.lazy==`object`&&t.lazy!=null?{lazy:{...e.lazy,...t.lazy}}:{}})}function D(e,t,n=`/`){return O(e,t,n,!1)}function O(e,t,n,r,i){let a=z((typeof t==`string`?m(t):t).pathname||`/`,n);if(a==null)return null;let o=i??A(e),s=null,c=ue(a);for(let e=0;s==null&&e<o.length;++e)s=se(o[e],c,r);return s}function k(e,t){let{route:n,pathname:r,params:i}=e;return{id:n.id,pathname:r,params:i,loaderData:t[n.id],handle:n.handle}}function A(e){let t=j(e);return N(t),t}function j(e,t=[],n=[],r=``,i=!1){let a=(e,a,o=i,s)=>{let l={relativePath:s===void 0?e.path||``:s,caseSensitive:e.caseSensitive===!0,childrenIndex:a,route:e};if(l.relativePath.startsWith(`/`)){if(!l.relativePath.startsWith(r)&&o)return;c(l.relativePath.startsWith(r),`Absolute route path "${l.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),l.relativePath=l.relativePath.slice(r.length)}let u=U([r,l.relativePath]),d=n.concat(l);e.children&&e.children.length>0&&(c(e.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${u}".`),j(e.children,t,d,u,o)),!(e.path==null&&!e.index)&&t.push({path:u,score:oe(u,e.index),routesMeta:d.map((e,t)=>{let[n,r]=R(e.relativePath,e.caseSensitive,t===d.length-1);return{...e,matcher:n,compiledParams:r}})})};return e.forEach((e,t)=>{if(e.path===``||!e.path?.includes(`?`))a(e,t);else for(let n of M(e.path))a(e,t,!0,n)}),t}function M(e){let t=e.split(`/`);if(t.length===0)return[];let[n,...r]=t,i=n.endsWith(`?`),a=n.replace(/\?$/,``);if(r.length===0)return i?[a,``]:[a];let o=M(r.join(`/`)),s=[];return s.push(...o.map(e=>e===``?a:[a,e].join(`/`))),i&&s.push(...o),s.map(t=>e.startsWith(`/`)&&t===``?`/`:t)}function N(e){e.sort((e,t)=>e.score===t.score?L(e.routesMeta.map(e=>e.childrenIndex),t.routesMeta.map(e=>e.childrenIndex)):t.score-e.score)}var P=/^:[\w-]+$/,F=/^:[\w-]+/,ee=3.5,I=3,te=2,ne=1,re=10,ie=-2,ae=e=>e===`*`;function oe(e,t){let n=e.split(`/`),r=n.length;return n.some(ae)&&(r+=ie),t&&(r+=te),n.filter(e=>!ae(e)).reduce((e,t)=>e+(P.test(t)?I:F.test(t)?ee:t===``?ne:re),r)}function L(e,t){return e.length===t.length&&e.slice(0,-1).every((e,n)=>e===t[n])?e[e.length-1]-t[t.length-1]:0}function se(e,t,n=!1){let{routesMeta:r}=e,i={},a=`/`,o=[];for(let e=0;e<r.length;++e){let s=r[e],c=e===r.length-1,l=a===`/`?t:t.slice(a.length)||`/`,u={path:s.relativePath,caseSensitive:s.caseSensitive,end:c},d=s.matcher&&s.compiledParams?le(u,l,s.matcher,s.compiledParams):ce(u,l),f=s.route;if(!d&&c&&n&&!r[r.length-1].route.index&&(d=ce({path:s.relativePath,caseSensitive:s.caseSensitive,end:!1},l)),!d)return null;Object.assign(i,d.params),o.push({params:i,pathname:U([a,d.pathname]),pathnameBase:ve(U([a,d.pathnameBase])),route:f}),d.pathnameBase!==`/`&&(a=U([a,d.pathnameBase]))}return o}function ce(e,t){typeof e==`string`&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=R(e.path,e.caseSensitive,e.end);return le(e,t,n,r)}function le(e,t,n,r){let i=t.match(n);if(!i)return null;let a=i[0],o=a.replace(/(.)\/+$/,`$1`),s=i.slice(1);return{params:r.reduce((e,{paramName:t,isOptional:n},r)=>{if(t===`*`){let e=s[r]||``;o=a.slice(0,a.length-e.length).replace(/(.)\/+$/,`$1`)}let i=s[r];return e[t]=n&&!i?void 0:(i||``).replace(/%2F/g,`/`),e},{}),pathname:a,pathnameBase:o,pattern:e}}function R(e,t=!1,n=!0){l(e===`*`||!e.endsWith(`*`)||e.endsWith(`/*`),`Route path "${e}" will be treated as if it were "${e.replace(/\*$/,`/*`)}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${e.replace(/\*$/,`/*`)}".`);let r=[],i=`^`+e.replace(/\/*\*?$/,``).replace(/^\/*/,`/`).replace(/[\\.*+^${}|()[\]]/g,`\\$&`).replace(/\/:([\w-]+)(\?)?/g,(e,t,n,i,a)=>{if(r.push({paramName:t,isOptional:n!=null}),n){let t=a.charAt(i+e.length);return t&&t!==`/`?`/([^\\/]*)`:`(?:/([^\\/]*))?`}return`/([^\\/]+)`}).replace(/\/([\w-]+)\?(?=\/|$|\()/g,`(?:/$1)?`);return e.endsWith(`*`)?(r.push({paramName:`*`}),i+=e===`*`||e===`/*`?`(.*)$`:`(?:\\/(.+)|\\/*)$`):n?i+=`\\/*$`:e!==``&&e!==`/`&&(i+=`(?:(?=\\/|$))`),[new RegExp(i,t?void 0:`i`),r]}function ue(e){try{return e.split(`/`).map(e=>decodeURIComponent(e).replace(/\//g,`%2F`)).join(`/`)}catch(t){return l(!1,`The URL path "${e}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${t}).`),e}}function z(e,t){if(t===`/`)return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith(`/`)?t.length-1:t.length,r=e.charAt(n);return r&&r!==`/`?null:e.slice(n)||`/`}function B({basename:e,pathname:t}){return t===`/`?e:U([e,t])}var de=e=>n.test(e);function V(e,t=`/`){let{pathname:n,search:r=``,hash:i=``}=typeof e==`string`?m(e):e,a;return n?(n=ge(n),a=n.startsWith(`/`)?H(n.substring(1),`/`):H(n,t)):a=t,{pathname:a,search:ye(r),hash:be(i)}}function H(e,t){let n=_e(t).split(`/`);return e.split(`/`).forEach(e=>{e===`..`?n.length>1&&n.pop():e!==`.`&&n.push(e)}),n.length>1?n.join(`/`):`/`}function fe(e,t,n,r){return`Cannot include a '${e}' character in a manually specified \`to.${t}\` field [${JSON.stringify(r)}]. Please separate it out to the \`to.${n}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function pe(e){return e.filter((e,t)=>t===0||e.route.path&&e.route.path.length>0)}function me(e){let t=pe(e);return t.map((e,n)=>n===t.length-1?e.pathname:e.pathnameBase)}function he(e,t,n,r=!1){let i;typeof e==`string`?i=m(e):(i={...e},c(!i.pathname||!i.pathname.includes(`?`),fe(`?`,`pathname`,`search`,i)),c(!i.pathname||!i.pathname.includes(`#`),fe(`#`,`pathname`,`hash`,i)),c(!i.search||!i.search.includes(`#`),fe(`#`,`search`,`hash`,i)));let a=e===``||i.pathname===``,o=a?`/`:i.pathname,s;if(o==null)s=n;else{let e=t.length-1;if(!r&&o.startsWith(`..`)){let t=o.split(`/`);for(;t[0]===`..`;)t.shift(),--e;i.pathname=t.join(`/`)}s=e>=0?t[e]:`/`}let l=V(i,s),u=o&&o!==`/`&&o.endsWith(`/`),d=(a||o===`.`)&&n.endsWith(`/`);return!l.pathname.endsWith(`/`)&&(u||d)&&(l.pathname+=`/`),l}var ge=e=>e.replace(/[\\/]{2,}/g,`/`),U=e=>ge(e.join(`/`)),_e=e=>e.replace(/\/+$/,``),ve=e=>_e(e).replace(/^\/*/,`/`),ye=e=>!e||e===`?`?``:e.startsWith(`?`)?e:`?`+e,be=e=>!e||e===`#`?``:e.startsWith(`#`)?e:`#`+e,xe=[`EvalError`,`RangeError`,`ReferenceError`,`SyntaxError`,`TypeError`,`URIError`],Se=class{status;statusText;data;error;internal;constructor(e,t,n,r=!1){this.status=e,this.statusText=t||``,this.internal=r,n instanceof Error?(this.data=n.toString(),this.error=n):this.data=n}};function Ce(e){return e!=null&&typeof e.status==`number`&&typeof e.statusText==`string`&&typeof e.internal==`boolean`&&`data`in e}function we(e){return U(e.map(e=>e.route.path).filter(Boolean))||`/`}function Te(e,t){let n=new URL(typeof e==`string`||e instanceof URL?e:e.url),r=typeof t==`string`?m(t):t;if(n.pathname=r.pathname||`/`,r.search){let e=new URLSearchParams(r.search),t=e.getAll(`index`);e.delete(`index`);for(let n of t.filter(Boolean))e.append(`index`,n);let i=e.toString();n.search=i?`?${i}`:``}else n.search=``;return n.hash=r.hash||``,n}var Ee=typeof window<`u`&&window.document!==void 0&&window.document.createElement!==void 0;function De(e,t){let a=e;if(typeof a!=`string`||!n.test(a))return{absoluteURL:void 0,isExternal:!1,to:a};let o=a,s=!1;if(Ee)try{let e=new URL(window.location.href),n=r.test(a)?new URL(i(a,e.protocol)):new URL(a),o=z(n.pathname,t);n.origin===e.origin&&o!=null?a=o+n.search+n.hash:s=!0}catch{l(!1,`<Link to="${a}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:o,isExternal:s,to:a}}var Oe=Symbol(`Uninstrumented`),W=new WeakMap;function ke(e,t){let n={lazy:[],"lazy.loader":[],"lazy.action":[],"lazy.middleware":[],middleware:[],loader:[],action:[]};e.forEach(e=>e({id:t.id,index:t.index,path:t.path,instrument(e){e.lazy!=null&&n.lazy.push(e.lazy),e[`lazy.loader`]!=null&&n[`lazy.loader`].push(e[`lazy.loader`]),e[`lazy.action`]!=null&&n[`lazy.action`].push(e[`lazy.action`]),e[`lazy.middleware`]!=null&&n[`lazy.middleware`].push(e[`lazy.middleware`]),e.middleware!=null&&n.middleware.push(e.middleware),e.loader!=null&&n.loader.push(e.loader),e.action!=null&&n.action.push(e.action)}}));let r={};if(typeof t.lazy==`function`&&n.lazy.length>0){let e=t.lazy;r.lazy=async(...t)=>K(await q(n.lazy,void 0,()=>e(...t),J))}if(typeof t.lazy==`object`){let e=t.lazy;if(typeof e.middleware==`function`&&n[`lazy.middleware`].length>0){let t=e.middleware;r.lazy=Object.assign(r.lazy||{},{middleware:async(...e)=>K(await q(n[`lazy.middleware`],void 0,()=>t(...e),J))})}if(typeof e.loader==`function`&&n[`lazy.loader`].length>0){let t=e.loader;r.lazy=Object.assign(r.lazy||{},{loader:async(...e)=>K(await q(n[`lazy.loader`],void 0,()=>t(...e),J))})}if(typeof e.action==`function`&&n[`lazy.action`].length>0){let t=e.action;r.lazy=Object.assign(r.lazy||{},{action:async(...e)=>K(await q(n[`lazy.action`],void 0,()=>t(...e),J))})}}if(typeof t.loader==`function`&&n.loader.length>0){let e=G(t.loader),i=async(...t)=>K(await q(n.loader,Pe(t[0]),()=>e(...t),J));e.hydrate===!0&&(i.hydrate=!0),je(i,e),r.loader=i}if(typeof t.action==`function`&&n.action.length>0){let e=G(t.action),i=async(...t)=>K(await q(n.action,Pe(t[0]),()=>e(...t),J));je(i,e),r.action=i}return t.middleware&&t.middleware.length>0&&n.middleware.length>0&&(r.middleware=t.middleware.map(e=>{let t=G(e),r=async(...e)=>K(await q(n.middleware,Pe(e[0]),()=>t(...e),J));return je(r,t),r})),r}function Ae(e,t){let n={navigate:[],fetch:[]};if(t.forEach(e=>e({instrument(e){e.navigate!=null&&n.navigate.push(e.navigate),e.fetch!=null&&n.fetch.push(e.fetch)}})),n.navigate.length>0){let t=G(e.navigate),r=async(...r)=>{let[i,a]=r,o,s={to:typeof i==`number`||typeof i==`string`?i:i?p(i):`.`,...Fe(e,a??{})};return K(await q(n.navigate,s,async()=>{if(typeof i==`number`)return await t(...r);let n=Me(e,e=>{o=e});try{return await t(...r)}finally{n()}},e=>({...J(e),meta:o})))};je(r,t),e.navigate=r}if(n.fetch.length>0){let t=G(e.fetch),r=async(...r)=>{let[i,a,o,s]=r,c;return K(await q(n.fetch,{href:o??`.`,fetcherKey:i,...Fe(e,s??{})},async()=>{let n=Me(e,e=>{c=e});try{return await t(...r)}finally{n()}},e=>({...J(e),meta:c})))};je(r,t),e.fetch=r}return e}function G(e){return e[Oe]??e}function je(e,t){e[Oe]=t}function Me(e,t){return W.set(e,t),()=>{W.get(e)===t&&W.delete(e)}}function Ne(e){let t=W.get(e);return W.delete(e),t}function K(e){if(e.type===`error`)throw e.value;return e.value}async function q(e,t,n,r,i={result:null,innerResult:null},a=e.length-1){let o=e[a];if(o){let s,l=async()=>(s?console.error(`You cannot call instrumented handlers more than once`):s=q(e,t,n,r,i,a-1),await s,c(i.innerResult,`Expected an inner result`),i.innerResult);try{await o(l,t)}catch(e){console.error(`An instrumentation function threw an error:`,e)}s||await l(),await s}else{try{i.result={type:`success`,value:await n()}}catch(e){i.result={type:`error`,value:e}}i.innerResult=r(i.result,t)}return i.result?i.result:(i.result={type:`error`,value:Error(`No result assigned in instrumentation chain.`)},i.innerResult=r(i.result,t),i.result)}function J(e){return e.type===`error`&&e.value instanceof Error?{status:`error`,error:e.value}:{status:`success`,error:void 0}}function Pe(e){let{request:t,context:n,params:r}=e;return{...e,request:Ie(t),params:{...r},context:Y(n)}}function Fe(e,t){return{currentUrl:p(e.state.location),...`formMethod`in t?{formMethod:t.formMethod}:{},...`formEncType`in t?{formEncType:t.formEncType}:{},...`formData`in t?{formData:t.formData}:{},...`body`in t?{body:t.body}:{}}}function Ie(e){return{method:e.method,url:e.url,headers:{get:(...t)=>e.headers.get(...t)}}}function Y(e){return{get:t=>e.get(t)}}var Le=[`POST`,`PUT`,`PATCH`,`DELETE`],Re=new Set(Le),ze=[`GET`,...Le],Be=new Set(ze),Ve=new Set([301,302,303,307,308]),He=new Set([307,308]),Ue={state:`idle`,location:void 0,matches:void 0,historyAction:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},We={state:`idle`,data:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},Ge={state:`unblocked`,proceed:void 0,reset:void 0,location:void 0},Ke=`remix-router-transitions`,qe=Symbol(`ResetLoaderData`),Je=class{#e;#t;#n;#r;constructor(e){this.#e=e,this.#t=A(e)}get stableRoutes(){return this.#e}get activeRoutes(){return this.#n??this.#e}get branches(){return this.#r??this.#t}get hasHMRRoutes(){return this.#n!=null}setRoutes(e){this.#e=e,this.#t=A(e)}setHmrRoutes(e){this.#n=e,this.#r=A(e)}commitHmrRoutes(){this.#n&&(this.#e=this.#n,this.#t=this.#r,this.#n=void 0,this.#r=void 0)}};function Ye(e){let t=e.window?e.window:typeof window<`u`?window:void 0,n=t!==void 0&&t.document!==void 0&&t.document.createElement!==void 0;c(e.routes.length>0,`You must provide a non-empty routes array to createRouter`);let r=e.hydrationRouteProperties||[],i=e.mapRouteProperties,a=i||(()=>({}));if(e.instrumentations){let t=e.instrumentations;a=e=>({...i?.(e),...ke(t.map(e=>e.route).filter(Boolean),e)})}let o={},s=new Je(T(e.routes,a,void 0,o)),u=e.basename||`/`;u.startsWith(`/`)||(u=`/${u}`);let d=e.dataStrategy||ft,p={...e.future},h=null,_=new Set,y=null,b=null,x=null,S=null,C=e.hydrationData!=null,w=O(s.activeRoutes,e.history.location,u,!1,s.branches),E=!1,D=null,A,j;if(w==null&&!e.patchRoutesOnNavigation){let t=X(404,{pathname:e.history.location.pathname}),{matches:n,route:r}=Ft(s.activeRoutes);A=!0,j=!A,w=n,D={[r.id]:t}}else if(w&&!e.hydrationData&&ot(w,s.activeRoutes,e.history.location.pathname).active&&(w=null),!w){A=!1,j=!A,w=[];let t=ot(null,s.activeRoutes,e.history.location.pathname);t.active&&t.matches&&(E=!0,w=t.matches)}else if(w.some(e=>e.route.lazy))A=!1,j=!A;else if(!w.some(e=>et(e.route)))A=!0,j=!A;else{let t=e.hydrationData?e.hydrationData.loaderData:null,n=e.hydrationData?e.hydrationData.errors:null,r=w;if(n){let e=w.findIndex(e=>n[e.route.id]!==void 0);r=r.slice(0,e+1)}j=!1,A=!0,r.forEach(e=>{let r=tt(e.route,t,n);j||=r.renderFallback,A&&=!r.shouldLoad})}let M,N={historyAction:e.history.action,location:e.history.location,matches:w,initialized:A,renderFallback:j,navigation:Ue,restoreScrollPosition:e.hydrationData==null&&null,preventScrollReset:!1,revalidation:`idle`,loaderData:e.hydrationData&&e.hydrationData.loaderData||{},actionData:e.hydrationData&&e.hydrationData.actionData||null,errors:e.hydrationData&&e.hydrationData.errors||D,fetchers:new Map,blockers:new Map},P=`POP`,F=null,ee=!1,I,te=!1,ne=new Map,re=null,ie=!1,ae=!1,oe=new Set,L=new Map,se=0,ce=-1,le=new Map,R=new Set,ue=new Map,B=new Map,V=new Set,H=new Map,fe,pe=null;function me(){if(h=e.history.listen(({action:t,location:n,delta:r})=>{if(fe){fe(),fe=void 0;return}l(H.size===0||r!=null,"You are trying to use a blocker on a POP navigation to a location that was not created by @remix-run/router. This will fail silently in production. This can happen if you are navigating outside the router via `window.history.pushState`/`window.location.hash` instead of using router navigation APIs. This can also happen if you are using createHashRouter and the user manually changes the URL.");let i=qe({currentLocation:N.location,nextLocation:n,historyAction:t});if(i&&r!=null){let t=new Promise(e=>{fe=e});e.history.go(r*-1),Ke(i,{state:`blocked`,location:n,proceed(){Ke(i,{state:`proceeding`,proceed:void 0,reset:void 0,location:n}),t.then(()=>e.history.go(r))},reset(){let e=new Map(N.blockers);e.set(i,Ge),U({blockers:e})}}),F?.resolve(),F=null;return}return be(t,n)}),n){an(t,ne);let e=()=>on(t,ne);t.addEventListener(`pagehide`,e),re=()=>t.removeEventListener(`pagehide`,e)}return N.initialized||be(`POP`,N.location,{initialHydration:!0}),M}function he(){h&&h(),re&&re(),_.clear(),I&&I.abort(),N.fetchers.forEach((e,t)=>Fe(N.fetchers,t)),N.blockers.forEach((e,t)=>Ve(t))}function ge(e){if(_.add(e),y){let{newErrors:t}=y;y=null,e(N,{deletedFetchers:[],newErrors:t,viewTransitionOpts:void 0,flushSync:!1})}return()=>_.delete(e)}function U(e,t={}){e.matches&&=e.matches.map(e=>{let t=o[e.route.id],n=e.route;return n.element!==t.element||n.errorElement!==t.errorElement||n.hydrateFallbackElement!==t.hydrateFallbackElement?{...e,route:t}:e}),N={...N,...e};let n=[],r=[];N.fetchers.forEach((e,t)=>{e.state===`idle`&&(V.has(t)?n.push(t):r.push(t))}),V.forEach(e=>{!N.fetchers.has(e)&&!L.has(e)&&n.push(e)}),_.size===0&&(y={newErrors:e.errors??null}),[..._].forEach(r=>r(N,{deletedFetchers:n,newErrors:e.errors??null,viewTransitionOpts:t.viewTransitionOpts,flushSync:t.flushSync===!0})),n.forEach(e=>Fe(N.fetchers,e)),r.forEach(e=>N.fetchers.delete(e))}function _e(t,n,{flushSync:r}={}){let i=N.actionData!=null&&N.navigation.formMethod!=null&&Q(N.navigation.formMethod)&&N.navigation.state===`loading`&&t.state?._isRedirect!==!0,a;a=n.actionData?Object.keys(n.actionData).length>0?n.actionData:null:i?N.actionData:null;let o=n.loaderData?Mt(N.loaderData,n.loaderData,n.matches||[],n.errors):N.loaderData,c=N.blockers;c.size>0&&!ie&&(c=new Map(c),c.forEach((e,t)=>c.set(t,Ge)));let l=!ie&&it(t,n.matches||N.matches),u=ee===!0||N.navigation.formMethod!=null&&Q(N.navigation.formMethod)&&t.state?._isRedirect!==!0;s.commitHmrRoutes(),ie||P===`POP`||(P===`PUSH`?e.history.push(t,t.state):P===`REPLACE`&&e.history.replace(t,t.state));let d;if(P===`POP`){let e=ne.get(N.location.pathname);e&&e.has(t.pathname)?d={currentLocation:N.location,nextLocation:t}:ne.has(t.pathname)&&(d={currentLocation:t,nextLocation:N.location})}else if(te){let e=ne.get(N.location.pathname);e?e.add(t.pathname):(e=new Set([t.pathname]),ne.set(N.location.pathname,e)),d={currentLocation:N.location,nextLocation:t}}U({...n,actionData:a,loaderData:o,historyAction:P,location:t,initialized:!0,renderFallback:!1,navigation:Ue,revalidation:`idle`,restoreScrollPosition:l,preventScrollReset:u,blockers:c},{viewTransitionOpts:d,flushSync:r===!0}),P=`POP`,ee=!1,te=!1,ie=!1,ae=!1,F?.resolve(),F=null,pe?.resolve(),pe=null}async function ve(t,n){if(F?.resolve(),F=null,typeof t==`number`){F||=sn();let n=F.promise;return e.history.go(t),n}let r=Ne(M),{path:i,submission:a,error:o}=Qe(!1,Ze(N.location,N.matches,u,t,n?.fromRouteId,n?.relative),n),s;n?.mask&&(s={pathname:``,search:``,hash:``,...typeof n.mask==`string`?m(n.mask):{...N.location.mask,...n.mask}});let c=N.location,l=f(c,i,n&&n.state,void 0,s);l={...l,...e.history.encodeLocation(l)};let d=n&&n.replace!=null?n.replace:void 0,p=`PUSH`;d===!0?p=`REPLACE`:d===!1||a!=null&&Q(a.formMethod)&&a.formAction===N.location.pathname+N.location.search&&(p=`REPLACE`);let h=n&&`preventScrollReset`in n?n.preventScrollReset===!0:void 0,g=(n&&n.flushSync)===!0,_=qe({currentLocation:c,nextLocation:l,historyAction:p});if(_){Ke(_,{state:`blocked`,location:l,proceed(){Ke(_,{state:`proceeding`,proceed:void 0,reset:void 0,location:l}),ve(t,n)},reset(){let e=new Map(N.blockers);e.set(_,Ge),U({blockers:e})}});return}await be(p,l,{submission:a,pendingError:o,preventScrollReset:h,replace:n&&n.replace,enableViewTransition:n&&n.viewTransition,flushSync:g,callSiteDefaultShouldRevalidate:n&&n.defaultShouldRevalidate,instrumentationNavigateMetaReceiver:r})}function ye(){pe||=sn(),Me(),U({revalidation:`loading`});let e=pe.promise;return N.navigation.state===`submitting`?e:N.navigation.state===`idle`?(be(N.historyAction,N.location,{startUninterruptedRevalidation:!0}),e):(be(P||N.historyAction,N.navigation.location,{overrideNavigation:N.navigation,enableViewTransition:te===!0}),e)}async function be(t,n,r){I&&I.abort(),I=null,P=t,ie=(r&&r.startUninterruptedRevalidation)===!0,rt(N.location,N.matches),ee=(r&&r.preventScrollReset)===!0,te=(r&&r.enableViewTransition)===!0;let i=s.activeRoutes,a=r?.initialHydration&&N.matches&&N.matches.length>0&&!E?N.matches:O(i,n,u,!1,s.branches),o=(r&&r.flushSync)===!0;if(a&&N.initialized&&!ae&&Rt(N.location,n)&&!(r&&r.submission&&Q(r.submission.formMethod))){_e(n,{matches:a},{flushSync:o});return}let c=ot(a,i,n.pathname);if(c.active&&c.matches&&(a=c.matches),r?.instrumentationNavigateMetaReceiver){let t=Zt(e.history,n,a);r.instrumentationNavigateMetaReceiver(t)}if(!a){let{error:e,notFoundMatches:t,route:r}=Ye(n.pathname);_e(n,{matches:t,loaderData:{},errors:{[r.id]:e}},{flushSync:o});return}let l=r&&r.overrideNavigation?{...r.overrideNavigation,matches:a,historyAction:t}:void 0;I=new AbortController;let d=Dt(e.history,n,I.signal,r&&r.submission),f=e.getContext?await e.getContext():new v,p;if(r&&r.pendingError)p=[Pt(a).route.id,{type:`error`,error:r.pendingError}];else if(r&&r.submission&&Q(r.submission.formMethod)){let i=await xe(d,n,r.submission,a,t,f,c.active,r&&r.initialHydration===!0,{replace:r.replace,flushSync:o});if(i.shortCircuited)return;if(i.pendingActionResult){let[e,t]=i.pendingActionResult;if(Z(t)&&Ce(t.error)&&t.error.status===404){I=null,_e(n,{matches:i.matches,loaderData:{},errors:{[e]:t.error}});return}}a=i.matches||a,p=i.pendingActionResult,l=$t(n,a,t,r.submission),o=!1,c.active=!1,d=Dt(e.history,d.url,d.signal)}let{shortCircuited:m,matches:h,loaderData:g,errors:_,workingFetchers:y}=await Se(d,n,a,t,f,c.active,l,r&&r.submission,r&&r.fetcherSubmission,r&&r.replace,r&&r.initialHydration===!0,o,p,r&&r.callSiteDefaultShouldRevalidate);m||(I=null,_e(n,{matches:h||a,...Nt(p),loaderData:g,errors:_,...y?{fetchers:y}:{}}))}async function xe(t,n,i,c,l,d,f,p,m={}){if(Me(),U({navigation:en(n,c,l,i)},{flushSync:m.flushSync===!0}),f){let e=await st(c,n.pathname,t.signal);if(e.type===`aborted`)return{shortCircuited:!0};if(e.type===`error`){if(e.partialMatches.length===0){let{matches:t,route:n}=Ft(s.activeRoutes);return{matches:t,pendingActionResult:[n.id,{type:`error`,error:e.error}]}}let t=Pt(e.partialMatches).route.id;return{matches:e.partialMatches,pendingActionResult:[t,{type:`error`,error:e.error}]}}if(e.matches)c=e.matches;else{let{notFoundMatches:e,error:t,route:r}=Ye(n.pathname);return{matches:e,pendingActionResult:[r.id,{type:`error`,error:t}]}}}let h,g=Xt(c,n);if(!g.route.action&&!g.route.lazy)h={type:`error`,error:X(405,{method:t.method,pathname:n.pathname,routeId:g.route.id})};else{let e=await G(t,n,vt(a,o,t,n,c,g,p?[]:r,d),d,null);if(h=e[g.route.id],!h){for(let t of c)if(e[t.route.id]){h=e[t.route.id];break}}if(t.signal.aborted)return{shortCircuited:!0}}if(Ut(h)){let n;return n=m&&m.replace!=null?m.replace:Et(h.response.headers.get(`Location`),new URL(t.url),u,e.history)===N.location.pathname+N.location.search,await W(t,h,!0,{submission:i,replace:n}),{shortCircuited:!0}}if(Z(h)){let e=Pt(c,g.route.id);return(m&&m.replace)!==!0&&(P=`PUSH`),{matches:c,pendingActionResult:[e.route.id,h,g.route.id]}}return{matches:c,pendingActionResult:[g.route.id,h]}}async function Se(t,n,i,c,l,d,f,p,m,h,g,_,v,y){let b=f||$t(n,i,c,p),x=p||m||Qt(b),S=!ie&&!g;if(d){if(S){let e=we(v);U({navigation:b,...e===void 0?{}:{actionData:e}},{flushSync:_})}let e=await st(i,n.pathname,t.signal);if(e.type===`aborted`)return{shortCircuited:!0};if(e.type===`error`){if(e.partialMatches.length===0){let{matches:t,route:n}=Ft(s.activeRoutes);return{matches:t,loaderData:{},errors:{[n.id]:e.error}}}let t=Pt(e.partialMatches).route.id;return{matches:e.partialMatches,loaderData:{},errors:{[t]:e.error}}}if(e.matches)i=e.matches;else{let{error:e,notFoundMatches:t,route:r}=Ye(n.pathname);return{matches:t,loaderData:{},errors:{[r.id]:e}}}}let C=s.activeRoutes,{dsMatches:w,revalidatingFetchers:T}=$e(t,l,a,o,e.history,N,i,x,n,g?[]:r,g===!0,ae,oe,V,ue,R,C,u,e.patchRoutesOnNavigation!=null,s.branches,v,y);if(ce=++se,!e.dataStrategy&&!w.some(e=>e.shouldLoad)&&!w.some(e=>e.route.middleware&&e.route.middleware.length>0)&&T.length===0){let e=new Map(N.fetchers),t=Re(e);return _e(n,{matches:i,loaderData:{},errors:v&&Z(v[1])?{[v[0]]:v[1].error}:null,...Nt(v),...t?{fetchers:e}:{}},{flushSync:_}),{shortCircuited:!0}}if(S){let e={};if(!d){e.navigation=b;let t=we(v);t!==void 0&&(e.actionData=t)}T.length>0&&(e.fetchers=Te(T)),U(e,{flushSync:_})}T.forEach(e=>{Y(e.key),e.controller&&L.set(e.key,e.controller)});let E=()=>T.forEach(e=>Y(e.key));I&&I.signal.addEventListener(`abort`,E);let{loaderResults:D,fetcherResults:O}=await je(w,T,t,n,l);if(t.signal.aborted)return{shortCircuited:!0};I&&I.signal.removeEventListener(`abort`,E),T.forEach(e=>L.delete(e.key));let k=It(D);if(k)return await W(t,k.result,!0,{replace:h}),{shortCircuited:!0};if(k=It(O),k)return R.add(k.key),await W(t,k.result,!0,{replace:h}),{shortCircuited:!0};let A=new Map(N.fetchers),{loaderData:j,errors:M}=jt(N,i,D,v,T,O,A);g&&N.errors&&(M={...N.errors,...M});let P=Re(A),F=ze(ce,A),ee=P||F||T.length>0;return{matches:i,loaderData:j,errors:M,...ee?{workingFetchers:A}:{}}}function we(e){if(e&&!Z(e[1]))return{[e[0]]:e[1].data};if(N.actionData)return Object.keys(N.actionData).length===0?null:N.actionData}function Te(e){let t=new Map(N.fetchers);return e.forEach(e=>{let n=t.get(e.key),r=tn(void 0,n?n.data:void 0);t.set(e.key,r)}),t}async function Ee(t,n,r,i){Y(t);let a=(i&&i.flushSync)===!0,o=Ne(M),c=s.activeRoutes,l=Ze(N.location,N.matches,u,r,n,i?.relative),d=O(c,l,u,!1,s.branches),f=ot(d,c,l);if(f.active&&f.matches&&(d=f.matches),o&&o(Zt(e.history,l,d)),!d){q(t,n,X(404,{pathname:l}),{flushSync:a});return}let{path:p,submission:m,error:h}=Qe(!0,l,i);if(h){q(t,n,h,{flushSync:a});return}let g=e.getContext?await e.getContext():new v,_=(i&&i.preventScrollReset)===!0;if(m&&Q(m.formMethod)){await De(t,n,p,d,g,f.active,a,_,m,i&&i.defaultShouldRevalidate);return}ue.set(t,{routeId:n,path:p}),await Oe(t,n,p,d,g,f.active,a,_,m)}async function De(t,n,i,l,d,f,p,m,h,g){Me(),ue.delete(t),K(t,nn(h,N.fetchers.get(t)),{flushSync:p});let _=new AbortController,v=Dt(e.history,i,_.signal,h);if(f){let e=await st(l,new URL(v.url).pathname,v.signal,t);if(e.type===`aborted`)return;if(e.type===`error`){q(t,n,e.error,{flushSync:p});return}if(e.matches)l=e.matches;else{q(t,n,X(404,{pathname:i}),{flushSync:p});return}}let y=Xt(l,i);if(!y.route.action&&!y.route.lazy){q(t,n,X(405,{method:h.formMethod,pathname:i,routeId:n}),{flushSync:p});return}L.set(t,_);let b=se,x=vt(a,o,v,i,l,y,r,d),S=await G(v,i,x,d,t),C=S[y.route.id];if(!C){for(let e of x)if(S[e.route.id]){C=S[e.route.id];break}}if(v.signal.aborted){L.get(t)===_&&L.delete(t);return}if(V.has(t)){if(Ut(C)||Z(C)){K(t,rn(void 0));return}}else{if(Ut(C)){if(L.delete(t),ce>b){K(t,rn(void 0));return}return R.add(t),K(t,tn(h)),W(v,C,!1,{fetcherSubmission:h,preventScrollReset:m})}if(Z(C)){q(t,n,C.error);return}}let w=N.navigation.location||N.location,T=Dt(e.history,w,_.signal),E=s.activeRoutes,D=N.navigation.state===`idle`?N.matches:O(E,N.navigation.location,u,!1,s.branches);c(D,`Didn't find any matches after fetcher action`);let k=++se;le.set(t,k);let{dsMatches:A,revalidatingFetchers:j}=$e(T,d,a,o,e.history,N,D,h,w,r,!1,ae,oe,V,ue,R,E,u,e.patchRoutesOnNavigation!=null,s.branches,[y.route.id,C],g),M=tn(h,C.data),F=new Map(N.fetchers);F.set(t,M),j.filter(e=>e.key!==t).forEach(e=>{let t=e.key,n=F.get(t),r=tn(void 0,n?n.data:void 0);F.set(t,r),Y(t),e.controller&&L.set(t,e.controller)}),U({fetchers:F});let ee=()=>j.forEach(e=>Y(e.key));_.signal.addEventListener(`abort`,ee);let{loaderResults:te,fetcherResults:ne}=await je(A,j,T,w,d);if(_.signal.aborted)return;_.signal.removeEventListener(`abort`,ee),le.delete(t),L.delete(t),j.forEach(e=>L.delete(e.key));let re=N.fetchers.has(t),ie=e=>{if(!re)return e;let n=new Map(e.fetchers);return n.set(t,rn(C.data)),{...e,fetchers:n}},z=It(te);if(z)return N=ie(N),W(T,z.result,!1,{preventScrollReset:m});if(z=It(ne),z)return R.add(z.key),N=ie(N),W(T,z.result,!1,{preventScrollReset:m});let B=new Map(N.fetchers);re&&B.set(t,rn(C.data));let{loaderData:de,errors:H}=jt(N,D,te,void 0,j,ne,B);ze(k,B),N.navigation.state===`loading`&&k>ce?(c(P,`Expected pending action`),I&&I.abort(),_e(N.navigation.location,{matches:D,loaderData:de,errors:H,fetchers:B})):(U({errors:H,loaderData:Mt(N.loaderData,de,D,H),fetchers:B}),ae=!1)}async function Oe(t,n,i,s,c,l,u,d,f){let p=N.fetchers.get(t);K(t,tn(f,p?p.data:void 0),{flushSync:u});let m=new AbortController,h=Dt(e.history,i,m.signal);if(l){let e=await st(s,new URL(h.url).pathname,h.signal,t);if(e.type===`aborted`)return;if(e.type===`error`){q(t,n,e.error,{flushSync:u});return}if(e.matches)s=e.matches;else{q(t,n,X(404,{pathname:i}),{flushSync:u});return}}let g=Xt(s,i);L.set(t,m);let _=se,v=await G(h,i,vt(a,o,h,i,s,g,r,c),c,t),y=v[g.route.id];if(!y){for(let e of s)if(v[e.route.id]){y=v[e.route.id];break}}if(L.get(t)===m&&L.delete(t),!h.signal.aborted){if(V.has(t)){K(t,rn(void 0));return}if(Ut(y)){if(ce>_){K(t,rn(void 0));return}R.add(t),await W(h,y,!1,{preventScrollReset:d});return}if(Z(y)){q(t,n,y.error);return}K(t,rn(y.data))}}async function W(r,i,a,{submission:o,fetcherSubmission:s,preventScrollReset:l,replace:d}={}){a||(F?.resolve(),F=null),i.response.headers.has(`X-Remix-Revalidate`)&&(ae=!0);let p=i.response.headers.get(`Location`);c(p,`Expected a Location header on the redirect Response`),p=Et(p,new URL(r.url),u,e.history);let m=f(N.location,p,{_isRedirect:!0});if(n){let e=!1;if(i.response.headers.has(`X-Remix-Reload-Document`))e=!0;else if(de(p)){let n=g(t,p,!0);e=n.origin!==t.location.origin||z(n.pathname,u)==null}if(e){d?t.location.replace(p):t.location.assign(p);return}}I=null;let h=d===!0||i.response.headers.has(`X-Remix-Replace`)?`REPLACE`:`PUSH`,{formMethod:_,formAction:v,formEncType:y}=N.navigation;!o&&!s&&_&&v&&y&&(o=Qt(N.navigation));let b=o||s;He.has(i.response.status)&&b&&Q(b.formMethod)?await be(h,m,{submission:{...b,formAction:p},preventScrollReset:l||ee,enableViewTransition:a?te:void 0}):await be(h,m,{overrideNavigation:$t(m,[],h,o),fetcherSubmission:s,preventScrollReset:l||ee,enableViewTransition:a?te:void 0})}async function G(e,t,n,r,i){let a,o={};try{a=await yt(d,e,t,n,i,r,!1)}catch(e){return n.filter(e=>e.shouldLoad).forEach(t=>{o[t.route.id]={type:`error`,error:e}}),o}if(e.signal.aborted)return o;if(!Q(e.method))for(let e of n){if(a[e.route.id]?.type===`error`)break;!a.hasOwnProperty(e.route.id)&&!N.loaderData.hasOwnProperty(e.route.id)&&(!N.errors||!N.errors.hasOwnProperty(e.route.id))&&e.shouldCallHandler()&&(a[e.route.id]={type:`error`,result:Error(`No result returned from dataStrategy for route ${e.route.id}`)})}for(let[t,r]of Object.entries(a))if(Ht(r)){let i=r.result;o[t]={type:`redirect`,response:Ct(i,e,t,n,u)}}else o[t]=await St(r);return o}async function je(e,t,n,r,i){let a=G(n,r,e,i,null),o=Promise.all(t.map(async e=>{if(e.matches&&e.match&&e.request&&e.controller){let t=(await G(e.request,e.path,e.matches,i,e.key))[e.match.route.id];return{[e.key]:t}}return Promise.resolve({[e.key]:{type:`error`,error:X(404,{pathname:e.path})}})}));return{loaderResults:await a,fetcherResults:(await o).reduce((e,t)=>Object.assign(e,t),{})}}function Me(){ae=!0,ue.forEach((e,t)=>{L.has(t)&&oe.add(t),Y(t)})}function K(e,t,n={}){let r=new Map(N.fetchers);r.set(e,t),U({fetchers:r},{flushSync:(n&&n.flushSync)===!0})}function q(e,t,n,r={}){let i=Pt(N.matches,t),a=new Map(N.fetchers);Fe(a,e),U({errors:{[i.route.id]:n},fetchers:a},{flushSync:(r&&r.flushSync)===!0})}function J(e){return B.set(e,(B.get(e)||0)+1),V.has(e)&&V.delete(e),N.fetchers.get(e)||We}function Pe(e,t){Y(e,t?.reason),K(e,rn(null))}function Fe(e,t){let n=N.fetchers.get(t);L.has(t)&&!(n&&n.state===`loading`&&le.has(t))&&Y(t),ue.delete(t),le.delete(t),R.delete(t),V.delete(t),oe.delete(t),e.delete(t)}function Ie(e){let t=(B.get(e)||0)-1;t<=0?(B.delete(e),V.add(e)):B.set(e,t),U({fetchers:new Map(N.fetchers)})}function Y(e,t){let n=L.get(e);n&&(n.abort(t),L.delete(e))}function Le(e,t){for(let n of e){let e=t.get(n);c(e,`Expected fetcher: ${n}`);let r=rn(e.data);t.set(n,r)}}function Re(e){let t=[],n=!1;for(let r of R){let i=e.get(r);c(i,`Expected fetcher: ${r}`),i.state===`loading`&&(R.delete(r),t.push(r),n=!0)}return Le(t,e),n}function ze(e,t){let n=[];for(let[r,i]of le)if(i<e){let e=t.get(r);c(e,`Expected fetcher: ${r}`),e.state===`loading`&&(Y(r),le.delete(r),n.push(r))}return Le(n,t),n.length>0}function Be(e,t){let n=N.blockers.get(e)||Ge;return H.get(e)!==t&&H.set(e,t),n}function Ve(e){N.blockers.delete(e),H.delete(e)}function Ke(e,t){let n=N.blockers.get(e)||Ge;c(n.state===`unblocked`&&t.state===`blocked`||n.state===`blocked`&&t.state===`blocked`||n.state===`blocked`&&t.state===`proceeding`||n.state===`blocked`&&t.state===`unblocked`||n.state===`proceeding`&&t.state===`unblocked`,`Invalid blocker state transition: ${n.state} -> ${t.state}`);let r=new Map(N.blockers);r.set(e,t),U({blockers:r})}function qe({currentLocation:e,nextLocation:t,historyAction:n}){if(H.size===0)return;H.size>1&&l(!1,`A router only supports one blocker at a time`);let r=Array.from(H.entries()),[i,a]=r[r.length-1],o=N.blockers.get(i);if(!(o&&o.state===`proceeding`)&&a({currentLocation:e,nextLocation:t,historyAction:n}))return i}function Ye(e){let t=X(404,{pathname:e}),n=s.activeRoutes,{matches:r,route:i}=Ft(n);return{notFoundMatches:r,route:i,error:t}}function Xe(e,t,n){if(b=e,S=t,x=n||null,!C&&N.navigation===Ue){C=!0;let e=it(N.location,N.matches);e!=null&&U({restoreScrollPosition:e})}return()=>{b=null,S=null,x=null}}function nt(e,t){return x&&x(e,t.map(e=>k(e,N.loaderData)))||e.key}function rt(e,t){if(b&&S){let n=nt(e,t);b[n]=S()}}function it(e,t){if(b){let n=nt(e,t),r=b[n];if(typeof r==`number`)return r}return null}function ot(t,n,r){if(e.patchRoutesOnNavigation){let e=s.branches;if(!t)return{active:!0,matches:O(n,r,u,!0,e)||[]};if(Object.keys(t[0].params).length>0)return{active:!0,matches:O(n,r,u,!0,e)}}return{active:!1,matches:null}}async function st(t,n,r,i){if(!e.patchRoutesOnNavigation)return{type:`success`,matches:t};let c=t;for(;;){let t=o;try{await e.patchRoutesOnNavigation({signal:r,path:n,matches:c,fetcherKey:i,patch:(e,n)=>{r.aborted||at(e,n,s,t,a,!1)}})}catch(e){return{type:`error`,error:e,partialMatches:c}}if(r.aborted)return{type:`aborted`};let l=s.branches,d=O(s.activeRoutes,n,u,!1,l),f=null;if(d&&(Object.keys(d[0].params).length===0||(f=O(s.activeRoutes,n,u,!0,l),!(f&&c.length<f.length&&ct(c,f.slice(0,c.length))))))return{type:`success`,matches:d};if(f||=O(s.activeRoutes,n,u,!0,l),!f||ct(c,f))return{type:`success`,matches:null};c=f}}function ct(e,t){return e.length===t.length&&e.every((e,n)=>e.route.id===t[n].route.id)}function lt(e){o={},s.setHmrRoutes(T(e,a,void 0,o))}function ut(e,t,n=!1){at(e,t,s,o,a,n),s.hasHMRRoutes||U({})}return M={get basename(){return u},get future(){return p},get state(){return N},get routes(){return s.stableRoutes},get branches(){return s.branches},get manifest(){return o},get window(){return t},initialize:me,subscribe:ge,enableScrollRestoration:Xe,navigate:ve,fetch:Ee,revalidate:ye,createHref:t=>e.history.createHref(t),encodeLocation:t=>e.history.encodeLocation(t),getFetcher:J,resetFetcher:Pe,deleteFetcher:Ie,dispose:he,getBlocker:Be,deleteBlocker:Ve,patchRoutes:ut,_internalFetchControllers:L,_internalSetRoutes:lt,_internalSetStateDoNotUseOrYouWillBreakYourApp(e){U(e)}},e.instrumentations&&(M=Ae(M,e.instrumentations.map(e=>e.router).filter(Boolean))),M}function Xe(e){return e!=null&&(`formData`in e&&e.formData!=null||`body`in e&&e.body!==void 0)}function Ze(e,t,n,r,i,a){let o,s;if(i){o=[];for(let e of t)if(o.push(e),e.route.id===i){s=e;break}}else o=t,s=t[t.length-1];let c=he(r||`.`,me(o),z(e.pathname,n)||e.pathname,a===`path`);if(r??(c.search=e.search,c.hash=e.hash),(r==null||r===``||r===`.`)&&s){let e=Yt(c.search);if(s.route.index&&!e)c.search=c.search?c.search.replace(/^\?/,`?index&`):`?index`;else if(!s.route.index&&e){let e=new URLSearchParams(c.search),t=e.getAll(`index`);e.delete(`index`),t.filter(e=>e).forEach(t=>e.append(`index`,t));let n=e.toString();c.search=n?`?${n}`:``}}return n!==`/`&&(c.pathname=B({basename:n,pathname:c.pathname})),p(c)}function Qe(e,t,n){if(!n||!Xe(n))return{path:t};if(n.formMethod&&!Jt(n.formMethod))return{path:t,error:X(405,{method:n.formMethod})};let r=()=>({path:t,error:X(400,{type:`invalid-body`})}),i=(n.formMethod||`get`).toUpperCase(),a=Lt(t);if(n.body!==void 0){if(n.formEncType===`text/plain`){if(!Q(i))return r();let e=typeof n.body==`string`?n.body:n.body instanceof FormData||n.body instanceof URLSearchParams?Array.from(n.body.entries()).reduce((e,[t,n])=>`${e}${t}=${n}\n`,``):String(n.body);return{path:t,submission:{formMethod:i,formAction:a,formEncType:n.formEncType,formData:void 0,json:void 0,text:e}}}if(n.formEncType===`application/json`){if(!Q(i))return r();try{let e=typeof n.body==`string`?JSON.parse(n.body):n.body;return{path:t,submission:{formMethod:i,formAction:a,formEncType:n.formEncType,formData:void 0,json:e,text:void 0}}}catch{return r()}}}c(typeof FormData==`function`,`FormData is not available in this environment`);let o,s;if(n.formData)o=Ot(n.formData),s=n.formData;else if(n.body instanceof FormData)o=Ot(n.body),s=n.body;else if(n.body instanceof URLSearchParams)o=n.body,s=kt(o);else if(n.body==null)o=new URLSearchParams,s=new FormData;else try{o=new URLSearchParams(n.body),s=kt(o)}catch{return r()}let l={formMethod:i,formAction:a,formEncType:n&&n.formEncType||`application/x-www-form-urlencoded`,formData:s,json:void 0,text:void 0};if(Q(l.formMethod))return{path:t,submission:l};let u=m(t);return e&&u.search&&Yt(u.search)&&o.append(`index`,``),u.search=`?${o}`,{path:p(u),submission:l}}function $e(e,t,n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x){let S=b?Z(b[1])?b[1].error:b[1].data:void 0,C=i.createURL(a.location),w=i.createURL(c),T;if(u&&a.errors){let e=Object.keys(a.errors)[0];T=o.findIndex(t=>t.route.id===e)}else if(b&&Z(b[1])){let e=b[0];T=o.findIndex(t=>t.route.id===e)-1}let E=b?b[1].statusCode:void 0,D=E&&E>=400,k={currentUrl:C,currentParams:a.matches[0]?.params||{},nextUrl:w,nextParams:o[0].params,...s,actionResult:S,actionStatus:E},A=we(o),j=o.map((i,o)=>{let{route:s}=i,f=null;if(T!=null&&o>T)f=!1;else if(s.lazy)f=!0;else if(!et(s))f=!1;else if(u){let{shouldLoad:e}=tt(s,a.loaderData,a.errors);f=e}else nt(a.loaderData,a.matches[o],i)&&(f=!0);if(f!==null)return _t(n,r,e,c,A,i,l,t,f);let p=!1;typeof x==`boolean`?p=x:D?p=!1:d||C.pathname+C.search===w.pathname+w.search?p=!0:C.search===w.search?rt(a.matches[o],i)&&(p=!0):p=!0;let m={...k,defaultShouldRevalidate:p};return _t(n,r,e,c,A,i,l,t,it(i,m),m,x)}),M=[];return m.forEach((e,s)=>{if(u||!o.some(t=>t.route.id===e.routeId)||p.has(s))return;let c=a.fetchers.get(s),m=c&&c.state!==`idle`&&c.data===void 0,b=O(g,e.path,_??`/`,!1,y);if(!b){if(v&&m)return;M.push({key:s,routeId:e.routeId,path:e.path,matches:null,match:null,request:null,controller:null});return}if(h.has(s))return;let S=Xt(b,e.path),C=new AbortController,w=Dt(i,e.path,C.signal),T=null;if(f.has(s))f.delete(s),T=vt(n,r,w,e.path,b,S,l,t);else if(m)d&&(T=vt(n,r,w,e.path,b,S,l,t));else{let i;i=typeof x==`boolean`?x:!D&&d;let a={...k,defaultShouldRevalidate:i};it(S,a)&&(T=vt(n,r,w,e.path,b,S,l,t,a))}T&&M.push({key:s,routeId:e.routeId,path:e.path,matches:T,match:S,request:w,controller:C})}),{dsMatches:j,revalidatingFetchers:M}}function et(e){return e.loader!=null||e.middleware!=null&&e.middleware.length>0}function tt(e,t,n){if(e.lazy)return{shouldLoad:!0,renderFallback:!0};if(!et(e))return{shouldLoad:!1,renderFallback:!1};let r=t!=null&&e.id in t,i=n!=null&&n[e.id]!==void 0;if(!r&&i)return{shouldLoad:!1,renderFallback:!1};if(typeof e.loader==`function`&&e.loader.hydrate===!0)return{shouldLoad:!0,renderFallback:!r};let a=!r&&!i;return{shouldLoad:a,renderFallback:a}}function nt(e,t,n){let r=!t||n.route.id!==t.route.id,i=!e.hasOwnProperty(n.route.id);return r||i}function rt(e,t){let n=e.route.path;return e.pathname!==t.pathname||n!=null&&n.endsWith(`*`)&&e.params[`*`]!==t.params[`*`]}function it(e,t){if(e.route.shouldRevalidate){let n=e.route.shouldRevalidate(t);if(typeof n==`boolean`)return n}return t.defaultShouldRevalidate}function at(e,t,n,r,i,a){let o;if(e){let t=r[e];c(t,`No route found to patch children into: routeId = ${e}`),t.children||=[],o=t.children}else o=n.activeRoutes;let s=[],l=[];if(t.forEach(e=>{let t=o.find(t=>ot(e,t));t?l.push({existingRoute:t,newRoute:e}):s.push(e)}),s.length>0){let t=T(s,i,[e||`_`,`patch`,String(o?.length||`0`)],r);o.push(...t)}if(a&&l.length>0)for(let e=0;e<l.length;e++){let{existingRoute:t,newRoute:n}=l[e],r=t,[a]=T([n],i,[],{},!0);Object.assign(r,{element:a.element?a.element:r.element,errorElement:a.errorElement?a.errorElement:r.errorElement,hydrateFallbackElement:a.hydrateFallbackElement?a.hydrateFallbackElement:r.hydrateFallbackElement})}n.hasHMRRoutes||n.setRoutes([...n.activeRoutes])}function ot(e,t){return`id`in e&&`id`in t&&e.id===t.id?!0:e.index!==t.index||e.path!==t.path||e.caseSensitive!==t.caseSensitive?!1:(!e.children||e.children.length===0)&&(!t.children||t.children.length===0)?!0:e.children?.every((e,n)=>t.children?.some(t=>ot(e,t)))??!1}var st=new WeakMap,ct=({key:e,route:t,manifest:n,mapRouteProperties:r})=>{let i=n[t.id];if(c(i,`No route found in manifest`),!i.lazy||typeof i.lazy!=`object`)return;let a=i.lazy[e];if(!a)return;let o=st.get(i);o||(o={},st.set(i,o));let s=o[e];if(s)return s;let u=(async()=>{let t=b(e),n=i[e]!==void 0;if(t)l(!t,`Route property `+e+` is not a supported lazy route property. This property will be ignored.`),o[e]=Promise.resolve();else if(n)l(!1,`Route "${i.id}" has a static property "${e}" defined. The lazy property will be ignored.`);else{let t=await a();t!=null&&(Object.assign(i,{[e]:t}),Object.assign(i,r(i)))}typeof i.lazy==`object`&&(i.lazy[e]=void 0,Object.values(i.lazy).every(e=>e===void 0)&&(i.lazy=void 0))})();return o[e]=u,u},lt=new WeakMap;function ut(e,t,n,r,i){let a=n[e.id];if(c(a,`No route found in manifest`),!e.lazy)return{lazyRoutePromise:void 0,lazyHandlerPromise:void 0};if(typeof e.lazy==`function`){let t=lt.get(a);if(t)return{lazyRoutePromise:t,lazyHandlerPromise:t};let n=(async()=>{c(typeof e.lazy==`function`,`No lazy route function found`);let t=await e.lazy(),n={};for(let e in t){let r=t[e];if(r===void 0)continue;let i=S(e),o=a[e]!==void 0;i?l(!i,`Route property `+e+` is not a supported property to be returned from a lazy route function. This property will be ignored.`):o?l(!o,`Route "${a.id}" has a static property "${e}" defined but its lazy function is also returning a value for this property. The lazy route property "${e}" will be ignored.`):n[e]=r}Object.assign(a,n),Object.assign(a,{...r(a),lazy:void 0})})();return lt.set(a,n),n.catch(()=>{}),{lazyRoutePromise:n,lazyHandlerPromise:n}}let o=Object.keys(e.lazy),s=[],u;for(let a of o){if(i&&i.includes(a))continue;let o=ct({key:a,route:e,manifest:n,mapRouteProperties:r});o&&(s.push(o),a===t&&(u=o))}let d=s.length>0?Promise.all(s).then(()=>{}):void 0;return d?.catch(()=>{}),u?.catch(()=>{}),{lazyRoutePromise:d,lazyHandlerPromise:u}}async function dt(e){let t=e.matches.filter(e=>e.shouldLoad),n={};return(await Promise.all(t.map(e=>e.resolve()))).forEach((e,r)=>{n[t[r].route.id]=e}),n}async function ft(e){return e.matches.some(e=>e.route.middleware)?pt(e,()=>dt(e)):dt(e)}function pt(e,t){return mt(e,t,e=>{if(qt(e))throw e;return e},Bt,n);async function n(t,n,r){if(r)return Object.assign(r.value,{[n]:{type:`error`,result:t}});{let{matches:r}=e,i=Math.min(Math.max(r.findIndex(e=>e.route.id===n),0),Math.max(r.findIndex(e=>e.shouldCallHandler()),0)),a=r[i].route.id;for(let e of r.slice(0,i+1))try{await e._lazyPromises?.route}catch{a=e.route.id;break}return{[Pt(r,a).route.id]:{type:`error`,result:t}}}}}async function mt(e,t,n,r,i){let{matches:a,...o}=e;return await ht(o,a.flatMap(e=>e.route.middleware?e.route.middleware.map(t=>[e.route.id,t]):[]),t,n,r,i)}async function ht(e,t,n,r,i,a,o=0){let{request:s}=e;if(s.signal.aborted)throw s.signal.reason??Error(`Request aborted: ${s.method} ${s.url}`);let c=t[o];if(!c)return await n();let[l,u]=c,d,f=async()=>{if(d)throw Error("You may only call `next()` once per middleware");try{return d={value:await ht(e,t,n,r,i,a,o+1)},d.value}catch(e){return d={value:await a(e,l,d)},d.value}};try{let t=await u(e,f),n=t==null?void 0:r(t);return i(n)?n:d?n??d.value:(d={value:await f()},d.value)}catch(e){return await a(e,l,d)}}function gt(e,t,n,r,i){let a=ct({key:`middleware`,route:r.route,manifest:t,mapRouteProperties:e}),o=ut(r.route,Q(n.method)?`action`:`loader`,t,e,i);return{middleware:a,route:o.lazyRoutePromise,handler:o.lazyHandlerPromise}}function _t(e,t,n,r,i,a,o,s,c,l=null,u){let d=!1,f=gt(e,t,n,a,o);return{...a,_lazyPromises:f,shouldLoad:c,shouldRevalidateArgs:l,shouldCallHandler(e){return d=!0,l?typeof u==`boolean`?it(a,{...l,defaultShouldRevalidate:u}):typeof e==`boolean`?it(a,{...l,defaultShouldRevalidate:e}):it(a,l):c},resolve(e){let{lazy:t,loader:o,middleware:l}=a.route,u=d||c||e&&!Q(n.method)&&(t||o),p=l&&l.length>0&&!o&&!t;return u&&(Q(n.method)||!p)?bt({request:n,path:r,pattern:i,match:a,lazyHandlerPromise:f?.handler,lazyRoutePromise:f?.route,handlerOverride:e,scopedContext:s}):Promise.resolve({type:`data`,result:void 0})}}}function vt(e,t,n,r,i,a,o,s,c=null){return i.map(l=>l.route.id===a.route.id?_t(e,t,n,r,we(i),l,o,s,!0,c):{...l,shouldLoad:!1,shouldRevalidateArgs:c,shouldCallHandler:()=>!1,_lazyPromises:gt(e,t,n,l,o),resolve:()=>Promise.resolve({type:`data`,result:void 0})})}async function yt(e,t,n,r,i,a,o){r.some(e=>e._lazyPromises?.middleware)&&await Promise.all(r.map(e=>e._lazyPromises?.middleware));let s={request:t,url:Te(t,n),pattern:we(r),params:r[0].params,context:a,matches:r},c=o?()=>{throw Error("You cannot call `runClientMiddleware()` from a static handler `dataStrategy`. Middleware is run outside of `dataStrategy` during SSR in order to bubble up the Response. You can enable middleware via the `respond` API in `query`/`queryRoute`")}:e=>{let t=s;return pt(t,()=>e({...t,fetcherKey:i,runClientMiddleware:()=>{throw Error("Cannot call `runClientMiddleware()` from within an `runClientMiddleware` handler")}}))},l=await e({...s,fetcherKey:i,runClientMiddleware:c});try{await Promise.all(r.flatMap(e=>[e._lazyPromises?.handler,e._lazyPromises?.route]))}catch{}return l}async function bt({request:e,path:t,pattern:n,match:r,lazyHandlerPromise:i,lazyRoutePromise:a,handlerOverride:o,scopedContext:s}){let c,l,u=Q(e.method),d=u?`action`:`loader`,f=i=>{let a,c=new Promise((e,t)=>a=t);l=()=>a(),e.signal.addEventListener(`abort`,l);let u=a=>typeof i==`function`?i({request:e,url:Te(e,t),pattern:n,params:r.params,context:s},...a===void 0?[]:[a]):Promise.reject(Error(`You cannot call the handler for a route which defines a boolean "${d}" [routeId: ${r.route.id}]`)),f=(async()=>{try{return{type:`data`,result:await(o?o(e=>u(e)):u())}}catch(e){return{type:`error`,result:e}}})();return Promise.race([f,c])};try{let t=u?r.route.action:r.route.loader;if(i||a){if(t){let e,[n]=await Promise.all([f(t).catch(t=>{e=t}),i,a]);if(e!==void 0)throw e;c=n}else{await i;let t=u?r.route.action:r.route.loader;if(t)[c]=await Promise.all([f(t),a]);else if(d===`action`){let t=new URL(e.url),n=t.pathname+t.search;throw X(405,{method:e.method,pathname:n,routeId:r.route.id})}else return{type:`data`,result:void 0}}}else if(t)c=await f(t);else{let t=new URL(e.url);throw X(404,{pathname:t.pathname+t.search})}}catch(e){return{type:`error`,result:e}}finally{l&&e.signal.removeEventListener(`abort`,l)}return c}async function xt(e){let t=e.headers.get(`Content-Type`);return t&&/\bapplication\/json\b/.test(t)?e.body==null?null:e.json():e.text()}async function St(e){let{result:t,type:n}=e;if(Gt(t)){let e;try{e=await xt(t)}catch(e){return{type:`error`,error:e}}return n===`error`?{type:`error`,error:new Se(t.status,t.statusText,e),statusCode:t.status,headers:t.headers}:{type:`data`,data:e,statusCode:t.status,headers:t.headers}}return n===`error`?Wt(t)?t.data instanceof Error?{type:`error`,error:t.data,statusCode:t.init?.status,headers:t.init?.headers?new Headers(t.init.headers):void 0}:{type:`error`,error:zt(t),statusCode:Ce(t)?t.status:void 0,headers:t.init?.headers?new Headers(t.init.headers):void 0}:{type:`error`,error:t,statusCode:Ce(t)?t.status:void 0}:Wt(t)?{type:`data`,data:t.data,statusCode:t.init?.status,headers:t.init?.headers?new Headers(t.init.headers):void 0}:{type:`data`,data:t}}function Ct(e,t,n,r,i){let a=e.headers.get(`Location`);if(c(a,`Redirects returned/thrown from loaders/actions must have a Location header`),!de(a)){let o=r.slice(0,r.findIndex(e=>e.route.id===n)+1);a=Ze(new URL(t.url),o,i,a),e.headers.set(`Location`,a)}return e}var wt=[`about:`,`blob:`,`chrome:`,`chrome-untrusted:`,`content:`,`data:`,`devtools:`,`file:`,`filesystem:`,`javascript:`];function Tt(e){try{return wt.includes(new URL(e).protocol)}catch{return!1}}function Et(e,t,n,a){if(de(e)){let a=e,o=r.test(a)?new URL(i(a,t.protocol)):new URL(a);if(Tt(o.toString()))throw Error(`Invalid redirect location`);let s=z(o.pathname,n)!=null;if(o.origin===t.origin&&s)return ge(o.pathname)+o.search+o.hash}try{if(Tt(a.createURL(e).toString()))throw Error(`Invalid redirect location`)}catch{}return e}function Dt(e,t,n,r){let i=e.createURL(Lt(t)).toString(),a={signal:n};if(r&&Q(r.formMethod)){let{formMethod:e,formEncType:t}=r;a.method=e.toUpperCase(),t===`application/json`?(a.headers=new Headers({"Content-Type":t}),a.body=JSON.stringify(r.json)):a.body=t===`text/plain`?r.text:t===`application/x-www-form-urlencoded`&&r.formData?Ot(r.formData):r.formData}return new Request(i,a)}function Ot(e){let t=new URLSearchParams;for(let[n,r]of e.entries())t.append(n,typeof r==`string`?r:r.name);return t}function kt(e){let t=new FormData;for(let[n,r]of e.entries())t.append(n,r);return t}function At(e,t,n,r=!1,i=!1){let a={},o=null,s,l=!1,u={},d=n&&Z(n[1])?n[1].error:void 0;return e.forEach(n=>{if(!(n.route.id in t))return;let f=n.route.id,p=t[f];if(c(!Ut(p),`Cannot handle redirect results in processLoaderData`),Z(p)){let t=p.error;if(d!==void 0&&(t=d,d=void 0),o||={},i)o[f]=t;else{let n=Pt(e,f);o[n.route.id]??(o[n.route.id]=t)}r||(a[f]=qe),l||(l=!0,s=Ce(p.error)?p.error.status:500),p.headers&&(u[f]=p.headers)}else a[f]=p.data,p.statusCode&&p.statusCode!==200&&!l&&(s=p.statusCode),p.headers&&(u[f]=p.headers)}),d!==void 0&&n&&(o={[n[0]]:d},n[2]&&(a[n[2]]=void 0)),{loaderData:a,errors:o,statusCode:s||200,loaderHeaders:u}}function jt(e,t,n,r,i,a,o){let{loaderData:s,errors:l}=At(t,n,r);return i.filter(e=>!e.matches||e.matches.some(e=>e.shouldLoad)).forEach(t=>{let{key:n,match:r,controller:i}=t;if(i&&i.signal.aborted)return;let s=a[n];if(c(s,`Did not find corresponding fetcher result`),Z(s)){let t=Pt(e.matches,r?.route.id);l&&l[t.route.id]||(l={...l,[t.route.id]:s.error}),o.delete(n)}else if(Ut(s))c(!1,`Unhandled fetcher revalidation redirect`);else{let e=rn(s.data);o.set(n,e)}}),{loaderData:s,errors:l}}function Mt(e,t,n,r){let i=Object.entries(t).filter(([,e])=>e!==qe).reduce((e,[t,n])=>(e[t]=n,e),{});for(let a of n){let n=a.route.id;if(!t.hasOwnProperty(n)&&e.hasOwnProperty(n)&&a.route.loader&&(i[n]=e[n]),r&&r.hasOwnProperty(n))break}return i}function Nt(e){return e?Z(e[1])?{actionData:{}}:{actionData:{[e[0]]:e[1].data}}:{}}function Pt(e,t){return(t?e.slice(0,e.findIndex(e=>e.route.id===t)+1):[...e]).reverse().find(e=>e.route.ErrorBoundary!=null||e.route.errorElement!=null)||e[0]}function Ft(e){let t=e.length===1?e[0]:e.find(e=>e.index||!e.path||e.path===`/`)||{id:`__shim-error-route__`};return{matches:[{params:{},pathname:``,pathnameBase:``,route:t}],route:t}}function X(e,{pathname:t,routeId:n,method:r,type:i,message:a}={}){let o=`Unknown Server Error`,s=`Unknown @remix-run/router error`;return e===400?(o=`Bad Request`,r&&t&&n?s=`You made a ${r} request to "${t}" but did not provide a \`loader\` for route "${n}", so there is no way to handle the request.`:i===`invalid-body`&&(s=`Unable to encode submission body`)):e===403?(o=`Forbidden`,s=`Route "${n}" does not match URL "${t}"`):e===404?(o=`Not Found`,s=`No route matches URL "${t}"`):e===405&&(o=`Method Not Allowed`,r&&t&&n?s=`You made a ${r.toUpperCase()} request to "${t}" but did not provide an \`action\` for route "${n}", so there is no way to handle the request.`:r&&(s=`Invalid request method "${r.toUpperCase()}"`)),new Se(e||500,o,Error(s),!0)}function It(e){let t=Object.entries(e);for(let e=t.length-1;e>=0;e--){let[n,r]=t[e];if(Ut(r))return{key:n,result:r}}}function Lt(e){return p({...typeof e==`string`?m(e):e,hash:``})}function Rt(e,t){return e.pathname!==t.pathname||e.search!==t.search?!1:e.hash===``?t.hash!==``:e.hash===t.hash||t.hash!==``}function zt(e){return new Se(e.init?.status??500,e.init?.statusText??`Internal Server Error`,e.data)}function Bt(e){return typeof e==`object`&&!!e&&Object.entries(e).every(([e,t])=>typeof e==`string`&&Vt(t))}function Vt(e){return typeof e==`object`&&!!e&&`type`in e&&`result`in e&&(e.type===`data`||e.type===`error`)}function Ht(e){return Gt(e.result)&&Ve.has(e.result.status)}function Z(e){return e.type===`error`}function Ut(e){return(e&&e.type)===`redirect`}function Wt(e){return typeof e==`object`&&!!e&&`type`in e&&`data`in e&&`init`in e&&e.type===`DataWithResponseInit`}function Gt(e){return e!=null&&typeof e.status==`number`&&typeof e.statusText==`string`&&typeof e.headers==`object`&&e.body!==void 0}function Kt(e){return Ve.has(e)}function qt(e){return Gt(e)&&Kt(e.status)&&e.headers.has(`Location`)}function Jt(e){return Be.has(e.toUpperCase())}function Q(e){return Re.has(e.toUpperCase())}function Yt(e){return new URLSearchParams(e).getAll(`index`).some(e=>e===``)}function Xt(e,t){let n=typeof t==`string`?m(t).search:t.search;if(e[e.length-1].route.index&&Yt(n||``))return e[e.length-1];let r=pe(e);return r[r.length-1]}function Zt(e,t,n){return{url:Te(e.createURL(t),t),pattern:n?we(n):``,params:n?.[0]?.params?{...n[0].params}:{}}}function Qt(e){let{formMethod:t,formAction:n,formEncType:r,text:i,formData:a,json:o}=e;if(!(!t||!n||!r)){if(i!=null)return{formMethod:t,formAction:n,formEncType:r,formData:void 0,json:void 0,text:i};if(a!=null)return{formMethod:t,formAction:n,formEncType:r,formData:a,json:void 0,text:void 0};if(o!==void 0)return{formMethod:t,formAction:n,formEncType:r,formData:void 0,json:o,text:void 0}}}function $t(e,t,n,r){return r?{state:`loading`,location:e,matches:t,historyAction:n,formMethod:r.formMethod,formAction:r.formAction,formEncType:r.formEncType,formData:r.formData,json:r.json,text:r.text}:{state:`loading`,location:e,matches:t,historyAction:n,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0}}function en(e,t,n,r){return{state:`submitting`,location:e,matches:t,historyAction:n,formMethod:r.formMethod,formAction:r.formAction,formEncType:r.formEncType,formData:r.formData,json:r.json,text:r.text}}function tn(e,t){return e?{state:`loading`,formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text,data:t}:{state:`loading`,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:t}}function nn(e,t){return{state:`submitting`,formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text,data:t?t.data:void 0}}function rn(e){return{state:`idle`,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:e}}function an(e,t){try{let n=e.sessionStorage.getItem(Ke);if(n){let e=JSON.parse(n);for(let[n,r]of Object.entries(e||{}))r&&Array.isArray(r)&&t.set(n,new Set(r||[]))}}catch{}}function on(e,t){if(t.size>0){let n={};for(let[e,r]of t)n[e]=[...r];try{e.sessionStorage.setItem(Ke,JSON.stringify(n))}catch(e){l(!1,`Failed to save applied view transitions in sessionStorage (${e}).`)}}}function sn(){let e,t,n=new Promise((r,i)=>{e=async e=>{r(e);try{await n}catch{}},t=async e=>{i(e);try{await n}catch{}}});return{promise:n,resolve:e,reject:t}}var cn=_.createContext(null);cn.displayName=`DataRouter`;var ln=_.createContext(null);ln.displayName=`DataRouterState`;var un=_.createContext(!1);function dn(){return _.useContext(un)}var fn=_.createContext({isTransitioning:!1});fn.displayName=`ViewTransition`;var pn=_.createContext(new Map);pn.displayName=`Fetchers`;var mn=_.createContext(null);mn.displayName=`Await`;var hn=_.createContext(null);hn.displayName=`Navigation`;var gn=_.createContext(null);gn.displayName=`Location`;var $=_.createContext({outlet:null,matches:[],isDataRoute:!1});$.displayName=`Route`;var _n=_.createContext(null);_n.displayName=`RouteError`;var vn=`REACT_ROUTER_ERROR`,yn=`REDIRECT`,bn=`ROUTE_ERROR_RESPONSE`;function xn(e){if(e.startsWith(`${vn}:${yn}:{`))try{let t=JSON.parse(e.slice(28));if(typeof t==`object`&&t&&typeof t.status==`number`&&typeof t.statusText==`string`&&typeof t.location==`string`&&typeof t.reloadDocument==`boolean`&&typeof t.replace==`boolean`)return t}catch{}}function Sn(e){if(e.startsWith(`${vn}:${bn}:{`))try{let t=JSON.parse(e.slice(40));if(typeof t==`object`&&t&&typeof t.status==`number`&&typeof t.statusText==`string`)return new Se(t.status,t.statusText,t.data)}catch{}}function Cn(e,{relative:t}={}){c(wn(),`useHref() may be used only in the context of a <Router> component.`);let{basename:n,navigator:r}=_.useContext(hn),{hash:i,pathname:a,search:o}=Mn(e,{relative:t}),s=a;return n!==`/`&&(s=a===`/`?n:U([n,a])),r.createHref({pathname:s,search:o,hash:i})}function wn(){return _.useContext(gn)!=null}function Tn(){return c(wn(),`useLocation() may be used only in the context of a <Router> component.`),_.useContext(gn).location}var En=`You should call navigate() in a React.useEffect(), not when your component is first rendered.`;function Dn(){let{isDataRoute:e}=_.useContext($);return e?Xn():On()}function On(){c(wn(),`useNavigate() may be used only in the context of a <Router> component.`);let e=_.useContext(cn),{basename:t,navigator:n}=_.useContext(hn),{matches:r}=_.useContext($),{pathname:i}=Tn(),a=JSON.stringify(me(r)),o=_.useRef(!1);return _.useLayoutEffect(()=>{o.current=!0}),_.useCallback((r,s={})=>{if(l(o.current,En),!o.current)return;if(typeof r==`number`){n.go(r);return}let c=he(r,JSON.parse(a),i,s.relative===`path`);e==null&&t!==`/`&&(c.pathname=c.pathname===`/`?t:U([t,c.pathname])),(s.replace?n.replace:n.push)(c,s.state,s)},[t,n,a,i,e])}var kn=_.createContext(null);function An(e){let t=_.useContext($).outlet;return _.useMemo(()=>t&&_.createElement(kn.Provider,{value:e},t),[t,e])}function jn(){let{matches:e}=_.useContext($);return e[e.length-1]?.params??{}}function Mn(e,{relative:t}={}){let{matches:n}=_.useContext($),{pathname:r}=Tn(),i=JSON.stringify(me(n));return _.useMemo(()=>he(e,JSON.parse(i),r,t===`path`),[e,i,r,t])}function Nn(e,t,n){c(wn(),`useRoutes() may be used only in the context of a <Router> component.`);let{navigator:r}=_.useContext(hn),{matches:i}=_.useContext($),a=i[i.length-1],o=a?a.params:{};a&&a.pathname;let s=a?a.pathnameBase:`/`;a&&a.route;let l=Tn(),u;if(t){let e=typeof t==`string`?m(t):t;c(s===`/`||e.pathname?.startsWith(s),`When overriding the location using \`<Routes location>\` or \`useRoutes(routes, location)\`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "${s}" but pathname "${e.pathname}" was given in the \`location\` prop.`),u=e}else u=l;let d=u.pathname||`/`,f=d;if(s!==`/`){let e=s.replace(/^\//,``).split(`/`);f=`/`+d.replace(/^\//,``).split(`/`).slice(e.length).join(`/`)}let p=n&&n.state.matches.length?n.state.matches.map(e=>Object.assign(e,{route:n.manifest[e.route.id]||e.route})):D(e,{pathname:f}),h=Bn(p&&p.map(e=>Object.assign({},e,{params:Object.assign({},o,e.params),pathname:U([s,r.encodeLocation?r.encodeLocation(e.pathname.replace(/%/g,`%25`).replace(/\?/g,`%3F`).replace(/#/g,`%23`)).pathname:e.pathname]),pathnameBase:e.pathnameBase===`/`?s:U([s,r.encodeLocation?r.encodeLocation(e.pathnameBase.replace(/%/g,`%25`).replace(/\?/g,`%3F`).replace(/#/g,`%23`)).pathname:e.pathnameBase])})),i,n);return t&&h?_.createElement(gn.Provider,{value:{location:{pathname:`/`,search:``,hash:``,state:null,key:`default`,mask:void 0,...u},navigationType:`POP`}},h):h}function Pn(){let e=Yn(),t=Ce(e)?`${e.status} ${e.statusText}`:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null;return _.createElement(_.Fragment,null,_.createElement(`h2`,null,`Unexpected Application Error!`),_.createElement(`h3`,{style:{fontStyle:`italic`}},t),n?_.createElement(`pre`,{style:{padding:`0.5rem`,backgroundColor:`rgba(200,200,200, 0.5)`}},n):null,null)}var Fn=_.createElement(Pn,null),In=class extends _.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static contextType=un;static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||t.revalidation!==`idle`&&e.revalidation===`idle`?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error===void 0?t.error:e.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){this.props.onError?this.props.onError(e,t):console.error(`React Router caught the following error during render`,e)}render(){let e=this.state.error;if(this.context&&typeof e==`object`&&e&&`digest`in e&&typeof e.digest==`string`){let t=Sn(e.digest);t&&(e=t)}let t=e===void 0?this.props.children:_.createElement($.Provider,{value:this.props.routeContext},_.createElement(_n.Provider,{value:e,children:this.props.component}));return this.context?_.createElement(Rn,{error:e},t):t}},Ln=new WeakMap;function Rn({children:e,error:t}){let{basename:n}=_.useContext(hn);if(typeof t==`object`&&t&&`digest`in t&&typeof t.digest==`string`){let e=xn(t.digest);if(e){let r=Ln.get(t);if(r)throw r;let i=De(e.location,n),a=i.absoluteURL||i.to;if(Tt(a))throw Error(`Invalid redirect location`);if(Ee&&!Ln.get(t)){if(i.isExternal||e.reloadDocument)window.location.href=a;else{let n=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(i.to,{replace:e.replace}));throw Ln.set(t,n),n}}return _.createElement(`meta`,{httpEquiv:`refresh`,content:`0;url=${a}`})}}return e}function zn({routeContext:e,match:t,children:n}){let r=_.useContext(cn);return r&&r.static&&r.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=t.route.id),_.createElement($.Provider,{value:e},n)}function Bn(e,t=[],n){let r=n?.state;if(e==null){if(!r)return null;if(r.errors)e=r.matches;else if(t.length===0&&!r.initialized&&r.matches.length>0)e=r.matches;else return null}let i=e,a=r?.errors;if(a!=null){let e=i.findIndex(e=>e.route.id&&a?.[e.route.id]!==void 0);c(e>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(a).join(`,`)}`),i=i.slice(0,Math.min(i.length,e+1))}let o=!1,s=-1;if(n&&r){o=r.renderFallback;for(let e=0;e<i.length;e++){let t=i[e];if((t.route.HydrateFallback||t.route.hydrateFallbackElement)&&(s=e),t.route.id){let{loaderData:e,errors:a}=r,c=t.route.loader&&!e.hasOwnProperty(t.route.id)&&(!a||a[t.route.id]===void 0);if(t.route.lazy||c){n.isStatic&&(o=!0),i=s>=0?i.slice(0,s+1):[i[0]];break}}}}let l=n?.onError,u=r&&l?(e,t)=>{l(e,{location:r.location,params:r.matches?.[0]?.params??{},pattern:we(r.matches),errorInfo:t})}:void 0;return i.reduceRight((e,n,c)=>{let l,d=!1,f=null,p=null;r&&(l=a&&n.route.id?a[n.route.id]:void 0,f=n.route.errorElement||Fn,o&&(s<0&&c===0?(Qn(`route-fallback`,!1,"No `HydrateFallback` element provided to render during initial hydration"),d=!0,p=null):s===c&&(d=!0,p=n.route.hydrateFallbackElement||null)));let m=t.concat(i.slice(0,c+1)),h=()=>{let t;return t=l?f:d?p:n.route.Component?_.createElement(n.route.Component,null):n.route.element?n.route.element:e,_.createElement(zn,{match:n,routeContext:{outlet:e,matches:m,isDataRoute:r!=null},children:t})};return r&&(n.route.ErrorBoundary||n.route.errorElement||c===0)?_.createElement(In,{location:r.location,revalidation:r.revalidation,component:f,error:l,children:h(),routeContext:{outlet:null,matches:m,isDataRoute:!0},onError:u}):h()},null)}function Vn(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Hn(e){let t=_.useContext(cn);return c(t,Vn(e)),t}function Un(e){let t=_.useContext(ln);return c(t,Vn(e)),t}function Wn(e){let t=_.useContext($);return c(t,Vn(e)),t}function Gn(e){let t=Wn(e),n=t.matches[t.matches.length-1];return c(n.route.id,`${e} can only be used on routes that contain a unique "id"`),n.route.id}function Kn(){return Gn(`useRouteId`)}function qn(){let e=Un(`useNavigation`);return _.useMemo(()=>{let{matches:t,historyAction:n,...r}=e.navigation;return r},[e.navigation])}function Jn(){let{matches:e,loaderData:t}=Un(`useMatches`);return _.useMemo(()=>e.map(e=>k(e,t)),[e,t])}function Yn(){let e=_.useContext(_n),t=Un(`useRouteError`),n=Gn(`useRouteError`);return e===void 0?t.errors?.[n]:e}function Xn(){let{router:e}=Hn(`useNavigate`),t=Gn(`useNavigate`),n=_.useRef(!1);return _.useLayoutEffect(()=>{n.current=!0}),_.useCallback(async(r,i={})=>{l(n.current,En),n.current&&(typeof r==`number`?await e.navigate(r):await e.navigate(r,{fromRouteId:t,...i}))},[e,t])}var Zn={};function Qn(e,t,n){!t&&!Zn[e]&&(Zn[e]=!0,l(!1,n))}export{De as A,xe as C,U as D,we as E,c as F,m as I,l as L,z as M,s as N,ce as O,p as P,n as R,Se as S,me as T,hn as _,Dn as a,dn as b,jn as c,Nn as d,mn as f,gn as g,pn as h,Jn as i,he as j,D as k,Mn as l,ln as m,wn as n,qn as o,cn as p,Tn as r,An as s,Cn as t,Kn as u,$ as v,w,Ye as x,fn as y};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import"./chunk-FOHPRMQF-DHwB1DNv.js";import{w as e}from"./mermaid-parser.core-BUBZKecf.js";export{e as createInfoServices};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{n as e}from"./mermaid-parser.core-BUBZKecf.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{t as n}from"./src-CmaQbKwl.js";import{c as r}from"./chunk-DU6HZSFF-CLH64LYR.js";import{f as i}from"./mermaid.core-BmHyJa2W.js";var a={parse:t(async t=>{let r=await e(`info`,t);n.debug(r)},`parse`)},o={version:`11.17.2`},s={parser:a,db:{getVersion:t(()=>o.version,`getVersion`)},renderer:{draw:t((e,t,a)=>{n.debug(`rendering info diagram
|
|
2
|
-
`+e);let o=i(t);r(o,100,400,!0),o.append(`g`).append(`text`).attr(`x`,100).attr(`y`,40).attr(`class`,`version`).attr(`font-size`,32).style(`text-anchor`,`middle`).text(`v${a}`)},`draw`)}};export{s as diagram};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
function e(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e)}return this}export{e as t};
|
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
import{n as e}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import"./src-CmaQbKwl.js";import{H as t,K as n,U as r,a as i,c as a,s as o,v as s,w as c,x as l,y as u}from"./chunk-DU6HZSFF-CLH64LYR.js";import{p as d}from"./chunk-75Z2AOVW-CNnr4_ra.js";import{t as f}from"./rough.esm-Dy-Kn_BL.js";import{f as p}from"./mermaid.core-BmHyJa2W.js";var m=(function(){var t=e(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[1,4],r=[1,14],i=[1,12],a=[1,13],o=[6,7,8],s=[1,20],c=[1,18],l=[1,19],u=[6,7,11],d=[1,6,13,14],f=[1,23],p=[1,24],m=[1,6,7,11,13,14],h={trace:e(function(){},`trace`),yy:{},symbols_:{error:2,start:3,ishikawa:4,spaceLines:5,SPACELINE:6,NL:7,ISHIKAWA:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,TEXT:14,$accept:0,$end:1},terminals_:{2:`error`,6:`SPACELINE`,7:`NL`,8:`ISHIKAWA`,11:`EOF`,13:`SPACELIST`,14:`TEXT`},productions_:[0,[3,1],[3,2],[5,1],[5,2],[5,2],[4,2],[4,3],[10,1],[10,1],[10,1],[10,2],[10,2],[9,3],[9,2],[12,2],[12,1],[12,1],[12,1]],performAction:e(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 6:case 7:return r;case 15:r.addNode(a[s-1].length,a[s].trim());break;case 16:r.addNode(0,a[s].trim())}},`anonymous`),table:[{3:1,4:2,5:3,6:[1,5],8:n},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:n},{6:r,7:[1,10],9:9,12:11,13:i,14:a},t(o,[2,3]),{1:[2,2]},t(o,[2,4]),t(o,[2,5]),{1:[2,6],6:r,12:15,13:i,14:a},{6:r,9:16,12:11,13:i,14:a},{6:s,7:c,10:17,11:l},t(u,[2,18],{14:[1,21]}),t(u,[2,16]),t(u,[2,17]),{6:s,7:c,10:22,11:l},{1:[2,7],6:r,12:15,13:i,14:a},t(d,[2,14],{7:f,11:p}),t(m,[2,8]),t(m,[2,9]),t(m,[2,10]),t(u,[2,15]),t(d,[2,13],{7:f,11:p}),t(m,[2,11]),t(m,[2,12])],defaultActions:{2:[2,1],6:[2,2]},parseError:e(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:e(function(t){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(t,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}e(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}e(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`:
|
|
2
|
-
`+h.showPosition()+`
|
|
3
|
-
Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};h.lexer=(function(){return{EOF:1,parseError:e(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:e(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:e(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:e(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:e(function(){return this._more=!0,this},`more`),reject:e(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
4
|
-
`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:e(function(e){this.unput(this.match.slice(e))},`less`),pastInput:e(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:e(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:e(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+`
|
|
5
|
-
`+t+`^`},`showPosition`),test_match:e(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:e(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;a<i.length;a++)if(n=this._input.match(this.rules[i[a]]),n&&(!t||n[0].length>t[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text.
|
|
6
|
-
`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:e(function(){return this.next()||this.lex()},`lex`),begin:e(function(e){this.conditionStack.push(e)},`begin`),popState:e(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:e(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:e(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:e(function(e){this.begin(e)},`pushState`),stateStackSize:e(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:e(function(e,t,n,r){switch(n){case 0:return 6;case 1:return 8;case 2:return 8;case 3:return 6;case 4:return 7;case 5:return 13;case 6:return 14;case 7:return 11}},`anonymous`),rules:[/^(?:\s*%%.*)/i,/^(?:ishikawa-beta\b)/i,/^(?:ishikawa\b)/i,/^(?:[\s]+[\n])/i,/^(?:[\n]+)/i,/^(?:[\s]+)/i,/^(?:[^\n]+)/i,/^(?:$)/i],conditions:{INITIAL:{rules:[0,1,2,3,4,5,6,7],inclusive:!0}}}})();function g(){this.yy={}}return e(g,`Parser`),g.prototype=h,h.Parser=g,new g})();m.parser=m;var h=m,g=class{constructor(){this.stack=[],this.clear=this.clear.bind(this),this.addNode=this.addNode.bind(this),this.getRoot=this.getRoot.bind(this)}static{e(this,`IshikawaDB`)}clear(){this.root=void 0,this.stack=[],this.baseLevel=void 0,i()}getRoot(){return this.root}addNode(e,t){let r=o.sanitizeText(t,l());if(!this.root){this.root={text:r,children:[]},this.stack=[{level:0,node:this.root}],n(r);return}this.baseLevel??=e;let i=e-this.baseLevel+1;for(i<=0&&(i=1);this.stack.length>1&&this.stack[this.stack.length-1].level>=i;)this.stack.pop();let a=this.stack[this.stack.length-1].node,s={text:r,children:[]};a.children.push(s),this.stack.push({level:i,node:s})}getAccTitle(){return u()}setAccTitle(e){r(e)}getAccDescription(){return s()}setAccDescription(e){t(e)}getDiagramTitle(){return c()}setDiagramTitle(e){n(e)}},_=14,v=250,y=30,b=60,x=5,S=82*Math.PI/180,C=Math.cos(S),w=Math.sin(S),T=e((e,t,n)=>{let r=e.node().getBBox(),i=r.width+t*2,o=r.height+t*2;a(e,o,i,n),e.attr(`viewBox`,`${r.x-t} ${r.y-t} ${i} ${o}`)},`applyPaddedViewBox`),E=e((e,t,n,r)=>{let i=r.db.getRoot();if(!i)return;let a=l(),{look:o,handDrawnSeed:s,themeVariables:c}=a,u=d(a.fontSize)[0]??_,m=o===`handDrawn`,h=i.children??[],g=a.ishikawa?.diagramPadding??20,y=a.ishikawa?.useMaxWidth??!1,b=p(t),x=b.append(`g`).attr(`class`,`ishikawa`),S=m?f.svg(b.node()):void 0,C=S?{roughSvg:S,seed:s??0,lineColor:c?.lineColor??`#333`,fillColor:c?.mainBkg??`#fff`}:void 0,w=`ishikawa-arrow-${t}`;m||x.append(`defs`).append(`marker`).attr(`id`,w).attr(`viewBox`,`0 0 10 10`).attr(`refX`,0).attr(`refY`,5).attr(`markerWidth`,6).attr(`markerHeight`,6).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 10 0 L 0 5 L 10 10 Z`).attr(`class`,`ishikawa-arrow`);let E=0,k=v,A=m?void 0:L(x,E,k,E,k,`ishikawa-spine`);if(O(x,E,k,i.text,u,C),!h.length){m&&L(x,E,k,E,k,`ishikawa-spine`,C),T(b,g,y);return}E-=20;let j=h.filter((e,t)=>t%2==0),N=h.filter((e,t)=>t%2==1),P=D(j),F=D(N),I=P.total+F.total,R=v,z=v;if(I>0){let e=v*2,t=v*.3;R=Math.max(t,e*(P.total/I)),z=Math.max(t,e*(F.total/I))}let B=u*2;R=Math.max(R,P.max*B),z=Math.max(z,F.max*B),k=Math.max(R,v),A&&A.attr(`y1`,k).attr(`y2`,k),x.select(`.ishikawa-head-group`).attr(`transform`,`translate(0,${k})`);let V=Math.ceil(h.length/2);for(let e=0;e<V;e++){let t=x.append(`g`).attr(`class`,`ishikawa-pair`);for(let[n,r,i]of[[h[e*2],-1,R],[h[e*2+1],1,z]])n&&M(t,n,E,k,r,i,u,C);E=t.selectAll(`text`).nodes().reduce((e,t)=>Math.min(e,t.getBBox().x),1/0)}if(m)L(x,E,k,0,k,`ishikawa-spine`,C);else{A.attr(`x1`,E);let e=`url(#${w})`;x.selectAll(`line.ishikawa-branch, line.ishikawa-sub-branch`).attr(`marker-start`,e)}T(b,g,y)},`draw`),D=e(t=>{let n=e(e=>e.children.reduce((e,t)=>e+1+n(t),0),`countDescendants`);return t.reduce((e,t)=>{let r=n(t);return e.total+=r,e.max=Math.max(e.max,r),e},{total:0,max:0})},`sideStats`),O=e((e,t,n,r,i,a)=>{let o=Math.max(6,Math.floor(110/(i*.6))),s=e.append(`g`).attr(`class`,`ishikawa-head-group`).attr(`transform`,`translate(${t},${n})`),c=F(s,P(r,o),0,0,`ishikawa-head-label`,`start`,i),l=c.node().getBBox(),u=Math.max(60,l.width+6),d=Math.max(40,l.height*2+40),f=`M 0 ${-d/2} L 0 ${d/2} Q ${u*2.4} 0 0 ${-d/2} Z`;if(a){let e=a.roughSvg.path(f,{roughness:1.5,seed:a.seed,fill:a.fillColor,fillStyle:`hachure`,fillWeight:2.5,hachureGap:5,stroke:a.lineColor,strokeWidth:2});s.insert(()=>e,`:first-child`).attr(`class`,`ishikawa-head`)}else s.insert(`path`,`:first-child`).attr(`class`,`ishikawa-head`).attr(`d`,f);c.attr(`transform`,`translate(${(u-l.width)/2-l.x+3},${-l.y-l.height/2})`)},`drawHead`),k=e((t,n)=>{let r=[],i=[],a=e((e,t,o)=>{let s=n===-1?[...e].reverse():e;for(let e of s){let n=r.length,s=e.children??[];r.push({depth:o,text:P(e.text,15),parentIndex:t,childCount:s.length}),o%2==0?(i.push(n),s.length&&a(s,n,o+1)):(s.length&&a(s,n,o+1),i.push(n))}},`walk`);return a(t,-1,2),{entries:r,yOrder:i}},`flattenTree`),A=e((e,t,n,r,i,a,o)=>{let s=e.append(`g`).attr(`class`,`ishikawa-label-group`),c=F(s,t,n,r+11*i,`ishikawa-label cause`,`middle`,a).node().getBBox();if(o){let e=o.roughSvg.rectangle(c.x-20,c.y-2,c.width+40,c.height+4,{roughness:1.5,seed:o.seed,fill:o.fillColor,fillStyle:`hachure`,fillWeight:2.5,hachureGap:5,stroke:o.lineColor,strokeWidth:2});s.insert(()=>e,`:first-child`).attr(`class`,`ishikawa-label-box`)}else s.insert(`rect`,`:first-child`).attr(`class`,`ishikawa-label-box`).attr(`x`,c.x-20).attr(`y`,c.y-2).attr(`width`,c.width+40).attr(`height`,c.height+4)},`drawCauseLabel`),j=e((e,t,n,r,i,a)=>{let o=Math.sqrt(r*r+i*i);if(o===0)return;let s=r/o,c=i/o,l=-c*6,u=s*6,d=t,f=n,p=`M ${d} ${f} L ${d-s*6*2+l} ${f-c*6*2+u} L ${d-s*6*2-l} ${f-c*6*2-u} Z`,m=a.roughSvg.path(p,{roughness:1,seed:a.seed,fill:a.lineColor,fillStyle:`solid`,stroke:a.lineColor,strokeWidth:1});e.append(()=>m)},`drawArrowMarker`),M=e((e,t,n,r,i,a,o,s)=>{let c=t.children??[],l=a*(c.length?1:.2),u=-C*l,d=w*l*i,f=n+u,p=r+d;if(L(e,n,r,f,p,`ishikawa-branch`,s),s&&j(e,n,r,n-f,r-p,s),A(e,t.text,f,p,i,o,s),!c.length)return;let{entries:m,yOrder:h}=k(c,i),g=m.length,_=Array(g);for(let[e,t]of h.entries())_[t]=r+d*((e+1)/(g+1));let v=new Map;v.set(-1,{x0:n,y0:r,x1:f,y1:p,childCount:c.length,childrenDrawn:0});let S=-C,T=w*i,E=i<0?`ishikawa-label up`:`ishikawa-label down`;for(let[t,n]of m.entries()){let r=_[t],i=v.get(n.parentIndex),a=e.append(`g`).attr(`class`,`ishikawa-sub-group`),c=0,l=0,u=0;if(n.depth%2==0){let e=i.y1-i.y0;c=I(i.x0,i.x1,e?(r-i.y0)/e:.5),l=r,u=c-(n.childCount>0?b+n.childCount*x:y),L(a,c,r,u,r,`ishikawa-sub-branch`,s),s&&j(a,c,r,1,0,s),F(a,n.text,u,r,`ishikawa-label align`,`end`,o)}else{let e=i.childrenDrawn++;c=I(i.x0,i.x1,(i.childCount-e)/(i.childCount+1)),l=i.y0,u=c+S*((r-l)/T),L(a,c,l,u,r,`ishikawa-sub-branch`,s),s&&j(a,c,l,c-u,l-r,s),F(a,n.text,u,r,E,`end`,o)}n.childCount>0&&v.set(t,{x0:c,y0:l,x1:u,y1:r,childCount:n.childCount,childrenDrawn:0})}},`drawBranch`),N=e(e=>e.split(/<br\s*\/?>|\n/),`splitLines`),P=e((e,t)=>{if(e.length<=t)return e;let n=[];for(let r of e.split(/\s+/)){let e=n.length-1;e>=0&&n[e].length+1+r.length<=t?n[e]+=` `+r:n.push(r)}return n.join(`
|
|
7
|
-
`)},`wrapText`),F=e((e,t,n,r,i,a,o)=>{let s=N(t),c=o*1.05,l=e.append(`text`).attr(`class`,i).attr(`text-anchor`,a).attr(`x`,n).attr(`y`,r-(s.length-1)*c/2);for(let[e,t]of s.entries())l.append(`tspan`).attr(`x`,n).attr(`dy`,e===0?0:c).text(t);return l},`drawMultilineText`),I=e((e,t,n)=>e+(t-e)*n,`lerp`),L=e((e,t,n,r,i,a,o)=>{if(o){let s=o.roughSvg.line(t,n,r,i,{roughness:1.5,seed:o.seed,stroke:o.lineColor,strokeWidth:2});e.append(()=>s).attr(`class`,a);return}return e.append(`line`).attr(`class`,a).attr(`x1`,t).attr(`y1`,n).attr(`x2`,r).attr(`y2`,i)},`drawLine`),R={parser:h,get db(){return new g},renderer:{draw:E},styles:e(e=>`
|
|
8
|
-
.ishikawa .ishikawa-spine,
|
|
9
|
-
.ishikawa .ishikawa-branch,
|
|
10
|
-
.ishikawa .ishikawa-sub-branch {
|
|
11
|
-
stroke: ${e.lineColor};
|
|
12
|
-
stroke-width: 2;
|
|
13
|
-
fill: none;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.ishikawa .ishikawa-sub-branch {
|
|
17
|
-
stroke-width: 1;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
.ishikawa .ishikawa-arrow {
|
|
21
|
-
fill: ${e.lineColor};
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
.ishikawa .ishikawa-head {
|
|
25
|
-
fill: ${e.mainBkg};
|
|
26
|
-
stroke: ${e.lineColor};
|
|
27
|
-
stroke-width: 2;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
.ishikawa .ishikawa-label-box {
|
|
31
|
-
fill: ${e.mainBkg};
|
|
32
|
-
stroke: ${e.lineColor};
|
|
33
|
-
stroke-width: 2;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
.ishikawa text {
|
|
37
|
-
font-family: ${e.fontFamily};
|
|
38
|
-
font-size: ${e.fontSize};
|
|
39
|
-
fill: ${e.textColor};
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
.ishikawa .ishikawa-head-label {
|
|
43
|
-
font-weight: 600;
|
|
44
|
-
text-anchor: middle;
|
|
45
|
-
dominant-baseline: middle;
|
|
46
|
-
font-size: 14px;
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
.ishikawa .ishikawa-label {
|
|
50
|
-
text-anchor: end;
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
.ishikawa .ishikawa-label.cause {
|
|
54
|
-
text-anchor: middle;
|
|
55
|
-
dominant-baseline: middle;
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
.ishikawa .ishikawa-label.align {
|
|
59
|
-
text-anchor: end;
|
|
60
|
-
dominant-baseline: middle;
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
.ishikawa .ishikawa-label.up {
|
|
64
|
-
dominant-baseline: baseline;
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
.ishikawa .ishikawa-label.down {
|
|
68
|
-
dominant-baseline: hanging;
|
|
69
|
-
}
|
|
70
|
-
`,`getStyles`)};export{R as diagram};
|
|
@@ -1,139 +0,0 @@
|
|
|
1
|
-
import{w as e}from"./src-Dvwdl2PF.js";import{n as t}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import"./src-CmaQbKwl.js";import{H as n,K as r,U as i,a,c as o,v as s,w as c,x as l,y as u}from"./chunk-DU6HZSFF-CLH64LYR.js";import{t as d}from"./arc-C7rN-mtx.js";import{t as f}from"./chunk-5VM5RSS4-ZNzvKenW.js";import{a as p,n as m,o as h,s as g}from"./chunk-F27PBJKO-4Quz7TPv.js";var _=(function(){var e=t(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[6,8,10,11,12,14,16,17,18],r=[1,9],i=[1,10],a=[1,11],o=[1,12],s=[1,13],c=[1,14],l={trace:t(function(){},`trace`),yy:{},symbols_:{error:2,start:3,journey:4,document:5,EOF:6,line:7,SPACE:8,statement:9,NEWLINE:10,title:11,acc_title:12,acc_title_value:13,acc_descr:14,acc_descr_value:15,acc_descr_multiline_value:16,section:17,taskName:18,taskData:19,$accept:0,$end:1},terminals_:{2:`error`,4:`journey`,6:`EOF`,8:`SPACE`,10:`NEWLINE`,11:`title`,12:`acc_title`,13:`acc_title_value`,14:`acc_descr`,15:`acc_descr_value`,16:`acc_descr_multiline_value`,17:`section`,18:`taskName`,19:`taskData`},productions_:[0,[3,3],[5,0],[5,2],[7,2],[7,1],[7,1],[7,1],[9,1],[9,2],[9,2],[9,1],[9,1],[9,2]],performAction:t(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 1:return a[s-1];case 2:this.$=[];break;case 3:a[s-1].push(a[s]),this.$=a[s-1];break;case 4:case 5:this.$=a[s];break;case 6:case 7:this.$=[];break;case 8:r.setDiagramTitle(a[s].substr(6)),this.$=a[s].substr(6);break;case 9:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 10:case 11:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 12:r.addSection(a[s].substr(8)),this.$=a[s].substr(8);break;case 13:r.addTask(a[s-1],a[s]),this.$=`task`}},`anonymous`),table:[{3:1,4:[1,2]},{1:[3]},e(n,[2,2],{5:3}),{6:[1,4],7:5,8:[1,6],9:7,10:[1,8],11:r,12:i,14:a,16:o,17:s,18:c},e(n,[2,7],{1:[2,1]}),e(n,[2,3]),{9:15,11:r,12:i,14:a,16:o,17:s,18:c},e(n,[2,5]),e(n,[2,6]),e(n,[2,8]),{13:[1,16]},{15:[1,17]},e(n,[2,11]),e(n,[2,12]),{19:[1,18]},e(n,[2,4]),e(n,[2,9]),e(n,[2,10]),e(n,[2,13])],defaultActions:{},parseError:t(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:t(function(e){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;this.parseError=typeof g.yy.parseError==`function`?g.yy.parseError:Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}t(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}t(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`:
|
|
2
|
-
`+h.showPosition()+`
|
|
3
|
-
Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};l.lexer=(function(){return{EOF:1,parseError:t(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:t(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:t(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:t(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:t(function(){return this._more=!0,this},`more`),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
4
|
-
`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:t(function(e){this.unput(this.match.slice(e))},`less`),pastInput:t(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:t(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:t(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+`
|
|
5
|
-
`+t+`^`},`showPosition`),test_match:t(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:t(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;a<i.length;a++)if(n=this._input.match(this.rules[i[a]]),n&&(!t||n[0].length>t[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e!==!1&&e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text.
|
|
6
|
-
`+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:t(function(){return this.next()||this.lex()},`lex`),begin:t(function(e){this.conditionStack.push(e)},`begin`),popState:t(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:t(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:t(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:t(function(e){this.begin(e)},`pushState`),stateStackSize:t(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:t(function(e,t,n,r){switch(n){case 0:break;case 1:break;case 2:return 10;case 3:break;case 4:break;case 5:return 4;case 6:return 11;case 7:return this.begin(`acc_title`),12;case 8:return this.popState(),`acc_title_value`;case 9:return this.begin(`acc_descr`),14;case 10:return this.popState(),`acc_descr_value`;case 11:this.begin(`acc_descr_multiline`);break;case 12:this.popState();break;case 13:return`acc_descr_multiline_value`;case 14:return 17;case 15:return 18;case 16:return 19;case 17:return`:`;case 18:return 6;case 19:return`INVALID`}},`anonymous`),rules:[/^(?:%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:journey\b)/i,/^(?:title\s[^#\n;]+)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:section\s[^#:\n;]+)/i,/^(?:[^#:\n;]+)/i,/^(?::[^#\n;]+)/i,/^(?::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{acc_descr_multiline:{rules:[12,13],inclusive:!1},acc_descr:{rules:[10],inclusive:!1},acc_title:{rules:[8],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,9,11,14,15,16,17,18,19],inclusive:!0}}}})();function u(){this.yy={}}return t(u,`Parser`),u.prototype=l,l.Parser=u,new u})();_.parser=_;var v=_,y=``,b=[],x=[],S=[],C=t(function(){b.length=0,x.length=0,y=``,S.length=0,a()},`clear`),w=t(function(e){y=e,b.push(e)},`addSection`),T=t(function(){return b},`getSections`),E=t(function(){let e=A(),t=0;for(;!e&&t<100;)e=A(),t++;return x.push(...S),x},`getTasks`),D=t(function(){let e=[];return x.forEach(t=>{t.people&&e.push(...t.people)}),[...new Set(e)].sort()},`updateActors`),O=t(function(e,t){let n=t.substr(1).split(`:`),r=0,i=[];n.length===1?(r=Number(n[0]),i=[]):(r=Number(n[0]),i=n[1].split(`,`));let a=i.map(e=>e.trim()),o={section:y,type:y,people:a,task:e,score:r};S.push(o)},`addTask`),k=t(function(e){let t={section:y,type:y,description:e,task:e,classes:[]};x.push(t)},`addTaskOrg`),A=t(function(){let e=t(function(e){return S[e].processed},`compileTask`),n=!0;for(let[t,r]of S.entries())e(t),n&&=r.processed;return n},`compileTasks`),j={getConfig:t(()=>l().journey,`getConfig`),clear:C,setDiagramTitle:r,getDiagramTitle:c,setAccTitle:i,getAccTitle:u,setAccDescription:n,getAccDescription:s,addSection:w,getSections:T,getTasks:E,addTask:O,addTaskOrg:k,getActors:t(function(){return D()},`getActors`)},M=t(e=>`.label {
|
|
7
|
-
font-family: ${e.fontFamily};
|
|
8
|
-
color: ${e.textColor};
|
|
9
|
-
}
|
|
10
|
-
.mouth {
|
|
11
|
-
stroke: #666;
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
line {
|
|
15
|
-
stroke: ${e.textColor}
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
.legend {
|
|
19
|
-
fill: ${e.textColor};
|
|
20
|
-
font-family: ${e.fontFamily};
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
.label text {
|
|
24
|
-
fill: #333;
|
|
25
|
-
}
|
|
26
|
-
.label {
|
|
27
|
-
color: ${e.textColor}
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
.face {
|
|
31
|
-
${e.faceColor?`fill: ${e.faceColor}`:`fill: #FFF8DC`};
|
|
32
|
-
stroke: #999;
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
.node rect,
|
|
36
|
-
.node circle,
|
|
37
|
-
.node ellipse,
|
|
38
|
-
.node polygon,
|
|
39
|
-
.node path {
|
|
40
|
-
fill: ${e.mainBkg};
|
|
41
|
-
stroke: ${e.nodeBorder};
|
|
42
|
-
stroke-width: 1px;
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
.node .label {
|
|
46
|
-
text-align: center;
|
|
47
|
-
}
|
|
48
|
-
.node.clickable {
|
|
49
|
-
cursor: pointer;
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
.arrowheadPath {
|
|
53
|
-
fill: ${e.arrowheadColor};
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
.edgePaths .path {
|
|
57
|
-
stroke: ${e.lineColor};
|
|
58
|
-
stroke-width: 1.5px;
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
.flowchart-link {
|
|
62
|
-
stroke: ${e.lineColor};
|
|
63
|
-
fill: none;
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
.edgeLabel {
|
|
67
|
-
background-color: ${e.edgeLabelBackground};
|
|
68
|
-
rect {
|
|
69
|
-
opacity: 0.5;
|
|
70
|
-
}
|
|
71
|
-
text-align: center;
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
.cluster rect {
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
.cluster text {
|
|
78
|
-
fill: ${e.titleColor};
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
div.mermaidTooltip {
|
|
82
|
-
position: absolute;
|
|
83
|
-
text-align: center;
|
|
84
|
-
max-width: 200px;
|
|
85
|
-
padding: 2px;
|
|
86
|
-
font-family: ${e.fontFamily};
|
|
87
|
-
font-size: 12px;
|
|
88
|
-
background: ${e.tertiaryColor};
|
|
89
|
-
border: 1px solid ${e.border2};
|
|
90
|
-
border-radius: 2px;
|
|
91
|
-
pointer-events: none;
|
|
92
|
-
z-index: 100;
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
.task-type-0, .section-type-0 {
|
|
96
|
-
${e.fillType0?`fill: ${e.fillType0}`:``};
|
|
97
|
-
}
|
|
98
|
-
.task-type-1, .section-type-1 {
|
|
99
|
-
${e.fillType0?`fill: ${e.fillType1}`:``};
|
|
100
|
-
}
|
|
101
|
-
.task-type-2, .section-type-2 {
|
|
102
|
-
${e.fillType0?`fill: ${e.fillType2}`:``};
|
|
103
|
-
}
|
|
104
|
-
.task-type-3, .section-type-3 {
|
|
105
|
-
${e.fillType0?`fill: ${e.fillType3}`:``};
|
|
106
|
-
}
|
|
107
|
-
.task-type-4, .section-type-4 {
|
|
108
|
-
${e.fillType0?`fill: ${e.fillType4}`:``};
|
|
109
|
-
}
|
|
110
|
-
.task-type-5, .section-type-5 {
|
|
111
|
-
${e.fillType0?`fill: ${e.fillType5}`:``};
|
|
112
|
-
}
|
|
113
|
-
.task-type-6, .section-type-6 {
|
|
114
|
-
${e.fillType0?`fill: ${e.fillType6}`:``};
|
|
115
|
-
}
|
|
116
|
-
.task-type-7, .section-type-7 {
|
|
117
|
-
${e.fillType0?`fill: ${e.fillType7}`:``};
|
|
118
|
-
}
|
|
119
|
-
|
|
120
|
-
.actor-0 {
|
|
121
|
-
${e.actor0?`fill: ${e.actor0}`:``};
|
|
122
|
-
}
|
|
123
|
-
.actor-1 {
|
|
124
|
-
${e.actor1?`fill: ${e.actor1}`:``};
|
|
125
|
-
}
|
|
126
|
-
.actor-2 {
|
|
127
|
-
${e.actor2?`fill: ${e.actor2}`:``};
|
|
128
|
-
}
|
|
129
|
-
.actor-3 {
|
|
130
|
-
${e.actor3?`fill: ${e.actor3}`:``};
|
|
131
|
-
}
|
|
132
|
-
.actor-4 {
|
|
133
|
-
${e.actor4?`fill: ${e.actor4}`:``};
|
|
134
|
-
}
|
|
135
|
-
.actor-5 {
|
|
136
|
-
${e.actor5?`fill: ${e.actor5}`:``};
|
|
137
|
-
}
|
|
138
|
-
${f()}
|
|
139
|
-
`,`getStyles`),N=t(function(e,t){return p(e,t)},`drawRect`),P=t(function(e,n){let r=e.append(`circle`).attr(`cx`,n.cx).attr(`cy`,n.cy).attr(`class`,`face`).attr(`r`,15).attr(`stroke-width`,2).attr(`overflow`,`visible`),i=e.append(`g`);i.append(`circle`).attr(`cx`,n.cx-5).attr(`cy`,n.cy-5).attr(`r`,1.5).attr(`stroke-width`,2).attr(`fill`,`#666`).attr(`stroke`,`#666`),i.append(`circle`).attr(`cx`,n.cx+5).attr(`cy`,n.cy-5).attr(`r`,1.5).attr(`stroke-width`,2).attr(`fill`,`#666`).attr(`stroke`,`#666`);function a(e){let t=d().startAngle(Math.PI/2).endAngle(Math.PI/2*3).innerRadius(15/2).outerRadius(15/2.2);e.append(`path`).attr(`class`,`mouth`).attr(`d`,t).attr(`transform`,`translate(`+n.cx+`,`+(n.cy+2)+`)`)}t(a,`smile`);function o(e){let t=d().startAngle(3*Math.PI/2).endAngle(Math.PI/2*5).innerRadius(15/2).outerRadius(15/2.2);e.append(`path`).attr(`class`,`mouth`).attr(`d`,t).attr(`transform`,`translate(`+n.cx+`,`+(n.cy+7)+`)`)}t(o,`sad`);function s(e){e.append(`line`).attr(`class`,`mouth`).attr(`stroke`,2).attr(`x1`,n.cx-5).attr(`y1`,n.cy+7).attr(`x2`,n.cx+5).attr(`y2`,n.cy+7).attr(`class`,`mouth`).attr(`stroke-width`,`1px`).attr(`stroke`,`#666`)}return t(s,`ambivalent`),n.score>3?a(i):n.score<3?o(i):s(i),r},`drawFace`),F=t(function(e,t){let n=e.append(`circle`);return n.attr(`cx`,t.cx),n.attr(`cy`,t.cy),n.attr(`class`,`actor-`+t.pos),n.attr(`fill`,t.fill),n.attr(`stroke`,t.stroke),n.attr(`r`,t.r),n.class!==void 0&&n.attr(`class`,n.class),t.title!==void 0&&n.append(`title`).text(t.title),n},`drawCircle`),I=t(function(e,t){return h(e,t)},`drawText`),L=t(function(e,n){function r(e,t,n,r,i){return e+`,`+t+` `+(e+n)+`,`+t+` `+(e+n)+`,`+(t+r-i)+` `+(e+n-i*1.2)+`,`+(t+r)+` `+e+`,`+(t+r)}t(r,`genPoints`);let i=e.append(`polygon`);i.attr(`points`,r(n.x,n.y,50,20,7)),i.attr(`class`,`labelBox`),n.y+=n.labelMargin,n.x+=.5*n.labelMargin,I(e,n)},`drawLabel`),R=t(function(e,t,n){let r=e.append(`g`),i=g();i.x=t.x,i.y=t.y,i.fill=t.fill,i.width=n.width*t.taskCount+n.diagramMarginX*(t.taskCount-1),i.height=n.height,i.class=`journey-section section-type-`+t.num,i.rx=3,i.ry=3,N(r,i),H(n)(t.text,r,i.x,i.y,i.width,i.height,{class:`journey-section section-type-`+t.num},n,t.colour)},`drawSection`),z=-1,B=t(function(e,t,n,r){let i=t.x+n.width/2,a=e.append(`g`);z++,a.append(`line`).attr(`id`,r+`-task`+z).attr(`x1`,i).attr(`y1`,t.y).attr(`x2`,i).attr(`y2`,450).attr(`class`,`task-line`).attr(`stroke-width`,`1px`).attr(`stroke-dasharray`,`4 2`).attr(`stroke`,`#666`),P(a,{cx:i,cy:300+(5-t.score)*30,score:t.score});let o=g();o.x=t.x,o.y=t.y,o.fill=t.fill,o.width=n.width,o.height=n.height,o.class=`task task-type-`+t.num,o.rx=3,o.ry=3,N(a,o);let s=t.x+14;t.people.forEach(e=>{let n=t.actors[e].color,r={cx:s,cy:t.y,r:7,fill:n,stroke:`#000`,title:e,pos:t.actors[e].position};F(a,r),s+=10}),H(n)(t.task,a,o.x,o.y,o.width,o.height,{class:`task`},n,t.colour)},`drawTask`),V=t(function(e,t){m(e,t)},`drawBackgroundRect`),H=(function(){function e(e,t,n,r,a,o,s,c){i(t.append(`text`).attr(`x`,n+a/2).attr(`y`,r+o/2+5).style(`font-color`,c).style(`text-anchor`,`middle`).text(e),s)}t(e,`byText`);function n(e,t,n,r,a,o,s,c,l){let{taskFontSize:u,taskFontFamily:d}=c,f=e.split(/<br\s*\/?>/gi);for(let e=0;e<f.length;e++){let c=e*u-u*(f.length-1)/2,p=t.append(`text`).attr(`x`,n+a/2).attr(`y`,r).attr(`fill`,l).style(`text-anchor`,`middle`).style(`font-size`,u).style(`font-family`,d);p.append(`tspan`).attr(`x`,n+a/2).attr(`dy`,c).text(f[e]),p.attr(`y`,r+o/2).attr(`dominant-baseline`,`central`).attr(`alignment-baseline`,`central`),i(p,s)}}t(n,`byTspan`);function r(e,t,r,a,o,s,c,l){let u=t.append(`switch`),d=u.append(`foreignObject`).attr(`x`,r).attr(`y`,a).attr(`width`,o).attr(`height`,s).attr(`position`,`fixed`).append(`xhtml:div`).style(`display`,`table`).style(`height`,`100%`).style(`width`,`100%`);d.append(`div`).attr(`class`,`label`).style(`display`,`table-cell`).style(`text-align`,`center`).style(`vertical-align`,`middle`).text(e),n(e,u,r,a,o,s,c,l),i(d,c)}t(r,`byFo`);function i(e,t){for(let n in t)n in t&&e.attr(n,t[n])}return t(i,`_setTextAttrs`),function(t){return t.textPlacement===`fo`?r:t.textPlacement===`old`?e:n}})(),U={drawRect:N,drawCircle:F,drawSection:R,drawText:I,drawLabel:L,drawTask:B,drawBackgroundRect:V,initGraphics:t(function(e,t){z=-1,e.append(`defs`).append(`marker`).attr(`id`,t+`-arrowhead`).attr(`refX`,5).attr(`refY`,2).attr(`markerWidth`,6).attr(`markerHeight`,4).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 0,0 V 4 L6,2 Z`)},`initGraphics`)},W=t(function(e){Object.keys(e).forEach(function(t){J[t]=e[t]})},`setConf`),G={},K=0;function q(e){let t=l().journey,n=t.maxLabelWidth;K=0;let r=60;Object.keys(G).forEach(i=>{let a=G[i].color,o={cx:20,cy:r,r:7,fill:a,stroke:`#000`,pos:G[i].position};U.drawCircle(e,o);let s=e.append(`text`).attr(`visibility`,`hidden`).text(i),c=s.node().getBoundingClientRect().width;s.remove();let l=[];if(c<=n)l=[i];else{let t=i.split(` `),r=``;s=e.append(`text`).attr(`visibility`,`hidden`),t.forEach(e=>{let t=r?`${r} ${e}`:e;if(s.text(t),s.node().getBoundingClientRect().width>n){if(r&&l.push(r),r=e,s.text(e),s.node().getBoundingClientRect().width>n){let t=``;for(let r of e)t+=r,s.text(t+`-`),s.node().getBoundingClientRect().width>n&&(l.push(t.slice(0,-1)+`-`),t=r);r=t}}else r=t}),r&&l.push(r),s.remove()}l.forEach((n,i)=>{let a={x:40,y:r+7+i*20,fill:`#666`,text:n,textMargin:t.boxTextMargin??5},o=U.drawText(e,a).node().getBoundingClientRect().width;o>K&&o>t.leftMargin-o&&(K=o)}),r+=Math.max(20,l.length*20)})}t(q,`drawActorLegend`);var J=l().journey,Y=0,ee=t(function(t,n,r,i){let a=l(),s=a.journey.titleColor,c=a.journey.titleFontSize,u=a.journey.titleFontFamily,d=a.securityLevel,f;d===`sandbox`&&(f=e(`#i`+n));let p=e(d===`sandbox`?f.nodes()[0].contentDocument.body:`body`);X.init();let m=p.select(`#`+n);U.initGraphics(m,n);let h=i.db.getTasks(),g=i.db.getDiagramTitle(),_=i.db.getActors();for(let e in G)delete G[e];let v=0;_.forEach(e=>{G[e]={color:J.actorColours[v%J.actorColours.length],position:v},v++}),q(m),Y=J.leftMargin+K,X.insert(0,0,Y,Object.keys(G).length*50),te(m,h,0,n);let y=X.getBounds();g&&m.append(`text`).text(g).attr(`x`,Y).attr(`font-size`,c).attr(`font-weight`,`bold`).attr(`y`,25).attr(`fill`,s).attr(`font-family`,u);let b=y.stopy-y.starty+2*J.diagramMarginY,x=Y+y.stopx+2*J.diagramMarginX;o(m,b,x,J.useMaxWidth),m.append(`line`).attr(`x1`,Y).attr(`y1`,J.height*4).attr(`x2`,x-Y-4).attr(`y2`,J.height*4).attr(`stroke-width`,4).attr(`stroke`,`black`).attr(`marker-end`,`url(#`+n+`-arrowhead)`);let S=g?70:0;m.attr(`viewBox`,`${y.startx} -25 ${x} ${b+S}`),m.attr(`preserveAspectRatio`,`xMinYMin meet`),m.attr(`height`,b+S+25)},`draw`),X={data:{startx:void 0,stopx:void 0,starty:void 0,stopy:void 0},verticalPos:0,sequenceItems:[],init:t(function(){this.sequenceItems=[],this.data={startx:void 0,stopx:void 0,starty:void 0,stopy:void 0},this.verticalPos=0},`init`),updateVal:t(function(e,t,n,r){e[t]=e[t]===void 0?n:r(n,e[t])},`updateVal`),updateBounds:t(function(e,n,r,i){let a=l().journey,o=this,s=0;function c(c){return t(function(t){s++;let l=o.sequenceItems.length-s+1;o.updateVal(t,`starty`,n-l*a.boxMargin,Math.min),o.updateVal(t,`stopy`,i+l*a.boxMargin,Math.max),o.updateVal(X.data,`startx`,e-l*a.boxMargin,Math.min),o.updateVal(X.data,`stopx`,r+l*a.boxMargin,Math.max),c!==`activation`&&(o.updateVal(t,`startx`,e-l*a.boxMargin,Math.min),o.updateVal(t,`stopx`,r+l*a.boxMargin,Math.max),o.updateVal(X.data,`starty`,n-l*a.boxMargin,Math.min),o.updateVal(X.data,`stopy`,i+l*a.boxMargin,Math.max))},`updateItemBounds`)}t(c,`updateFn`),this.sequenceItems.forEach(c())},`updateBounds`),insert:t(function(e,t,n,r){let i=Math.min(e,n),a=Math.max(e,n),o=Math.min(t,r),s=Math.max(t,r);this.updateVal(X.data,`startx`,i,Math.min),this.updateVal(X.data,`starty`,o,Math.min),this.updateVal(X.data,`stopx`,a,Math.max),this.updateVal(X.data,`stopy`,s,Math.max),this.updateBounds(i,o,a,s)},`insert`),bumpVerticalPos:t(function(e){this.verticalPos+=e,this.data.stopy=this.verticalPos},`bumpVerticalPos`),getVerticalPos:t(function(){return this.verticalPos},`getVerticalPos`),getBounds:t(function(){return this.data},`getBounds`)},Z=J.sectionFills,Q=J.sectionColours,te=t(function(e,t,n,r){let i=l().journey,a=``,o=n+(i.height*2+i.diagramMarginY),s=0,c=`#CCC`,u=`black`,d=0;for(let[n,l]of t.entries()){if(a!==l.section){c=Z[s%Z.length],d=s%Z.length,u=Q[s%Q.length];let r=0,o=l.section;for(let e=n;e<t.length&&t[e].section==o;e++)r+=1;let f={x:n*i.taskMargin+n*i.width+Y,y:50,text:l.section,fill:c,num:d,colour:u,taskCount:r};U.drawSection(e,f,i),a=l.section,s++}let f=l.people.reduce((e,t)=>(G[t]&&(e[t]=G[t]),e),{});l.x=n*i.taskMargin+n*i.width+Y,l.y=o,l.width=i.diagramMarginX,l.height=i.diagramMarginY,l.colour=u,l.fill=c,l.num=d,l.actors=f,U.drawTask(e,l,i,r),X.insert(l.x,l.y,l.x+l.width+i.taskMargin,450)}},`drawTasks`),$={setConf:W,draw:ee},ne={parser:v,db:j,renderer:$,styles:M,init:t(e=>{$.setConf(e.journey),j.clear()},`init`)};export{ne as diagram};
|