mdifit 0.1.1 → 0.1.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.
Files changed (92) hide show
  1. package/CHANGELOG.md +14 -0
  2. package/README.md +5 -4
  3. package/dist/client/assets/{abnfDiagram-YUKMZFIV-BZo2faX7.js → abnfDiagram-YUKMZFIV-DjDjNYh9.js} +1 -1
  4. package/dist/client/assets/{arc-CbUErDpN.js → arc-BB1sr77E.js} +1 -1
  5. package/dist/client/assets/{architecture-WOLXFQ4H-BVSJViF-.js → architecture-WOLXFQ4H-BGRdSn0x.js} +1 -1
  6. package/dist/client/assets/{architectureDiagram-47P4ROYG-BPx-GkYK.js → architectureDiagram-47P4ROYG-Bhw4J3xQ.js} +1 -1
  7. package/dist/client/assets/{blockDiagram-E7TT5TSB-CSwuSJCT.js → blockDiagram-E7TT5TSB-BzkPvJiQ.js} +1 -1
  8. package/dist/client/assets/{c4Diagram-CRA5TL53-CK_OWGYX.js → c4Diagram-CRA5TL53-CvwsFRzm.js} +1 -1
  9. package/dist/client/assets/channel-C4SLDU7t.js +1 -0
  10. package/dist/client/assets/{chunk-2BW5OAIV-MCOb6mxM.js → chunk-2BW5OAIV-D5Qj8Q2W.js} +1 -1
  11. package/dist/client/assets/{chunk-3YJQHVM4-Xz1DUt9r.js → chunk-3YJQHVM4-l9nWADIg.js} +1 -1
  12. package/dist/client/assets/{chunk-4EA7E6EY-Bj0Yui92.js → chunk-4EA7E6EY-C0v9hWIC.js} +1 -1
  13. package/dist/client/assets/{chunk-7TKQ45FW-BDWm-ILS.js → chunk-7TKQ45FW-BzW_BF1f.js} +1 -1
  14. package/dist/client/assets/{chunk-AW2ZBBNX-CqHCy96c.js → chunk-AW2ZBBNX-BOwITOZY.js} +1 -1
  15. package/dist/client/assets/{chunk-DBDB3WZW-B6Ha2UK4.js → chunk-DBDB3WZW-mqha7s7f.js} +1 -1
  16. package/dist/client/assets/{chunk-E2ZNV5FY-D1BIxPMx.js → chunk-E2ZNV5FY-CBOkwewU.js} +1 -1
  17. package/dist/client/assets/{chunk-EU5HNXII-C-AygpcN.js → chunk-EU5HNXII-BDrmiuen.js} +1 -1
  18. package/dist/client/assets/{chunk-FVRAUYC3-DzHSGBRS.js → chunk-FVRAUYC3-DgwsnPZT.js} +1 -1
  19. package/dist/client/assets/{chunk-HJ2JQQFS-ie5keT3-.js → chunk-HJ2JQQFS-DD88ca1g.js} +1 -1
  20. package/dist/client/assets/{chunk-HTAEGDNF-BlGvPtac.js → chunk-HTAEGDNF-BziTvRNf.js} +1 -1
  21. package/dist/client/assets/{chunk-KQW6MTUR-DJ-exuGd.js → chunk-KQW6MTUR-Bjo0oFUM.js} +1 -1
  22. package/dist/client/assets/{chunk-NTY3LDVX-DC4zuhvF.js → chunk-NTY3LDVX-DscqVJZQ.js} +1 -1
  23. package/dist/client/assets/{chunk-VPRB5NB3-ZzCBRMxY.js → chunk-VPRB5NB3-BwgJCQTz.js} +1 -1
  24. package/dist/client/assets/{chunk-XC4XBNZT-CF_ExUnR.js → chunk-XC4XBNZT-C-hUCVsJ.js} +1 -1
  25. package/dist/client/assets/{chunk-XXDRQBXY-HcWWupEv.js → chunk-XXDRQBXY-BRE0Bj42.js} +1 -1
  26. package/dist/client/assets/{classDiagram-v2-K4WV4PDN-DnJv6yBN.js → classDiagram-v2-K4WV4PDN-BqVWnS3E.js} +1 -1
  27. package/dist/client/assets/{cose-bilkent-JH36ORCC-o1PgxDw-.js → cose-bilkent-JH36ORCC-CowNKODI.js} +1 -1
  28. package/dist/client/assets/{cynefin-EF2NZ3EQ-DbKgEyex.js → cynefin-EF2NZ3EQ-D0IVI6wI.js} +1 -1
  29. package/dist/client/assets/{cynefinDiagram-3GCD6N5R-E-dQwibH.js → cynefinDiagram-3GCD6N5R-CBYiq6Vy.js} +1 -1
  30. package/dist/client/assets/{dagre-W4DXFKR2-Ap0ceLBZ.js → dagre-W4DXFKR2-zfCe2e_H.js} +1 -1
  31. package/dist/client/assets/{diagram-2UJZ2QOL-DX0wm8yh.js → diagram-2UJZ2QOL-CjRV5n1F.js} +1 -1
  32. package/dist/client/assets/{diagram-OVF4WLC6-0cczPc2_.js → diagram-OVF4WLC6-2vu1ftyi.js} +1 -1
  33. package/dist/client/assets/{diagram-PFPMY2P6-Cpy5DgfO.js → diagram-PFPMY2P6-Dk5kOCD2.js} +1 -1
  34. package/dist/client/assets/{diagram-UMYRVEAY-C5yo0bqh.js → diagram-UMYRVEAY-DH20bKG4.js} +1 -1
  35. package/dist/client/assets/{diagram-YEKJPTXX-D3KnlmKv.js → diagram-YEKJPTXX-S8TAKovw.js} +1 -1
  36. package/dist/client/assets/{diagram-ZIFT7M5P-DPlI4ecN.js → diagram-ZIFT7M5P-CTBO8iCO.js} +1 -1
  37. package/dist/client/assets/{dist-CXpE70MZ.js → dist-C_tiWm-_.js} +1 -1
  38. package/dist/client/assets/{ebnfDiagram-VR2GEFS7-Dr-ifRlW.js → ebnfDiagram-VR2GEFS7-YPuSnC9a.js} +1 -1
  39. package/dist/client/assets/{elk-IJKZMXRS-DjZ0uo78.js → elk-IJKZMXRS-DFMRb8PY.js} +1 -1
  40. package/dist/client/assets/{erDiagram-O2IAPWRE-D3AbDLxv.js → erDiagram-O2IAPWRE-DEWGjJIC.js} +1 -1
  41. package/dist/client/assets/{eventmodeling-K75KTNOO-DUq1BcFp.js → eventmodeling-K75KTNOO-CsoKP7Kk.js} +1 -1
  42. package/dist/client/assets/flowDiagram-OXPTDLAJ-B0TO2txc.js +1 -0
  43. package/dist/client/assets/{ganttDiagram-R7TSEDQI-CpFnm4MR.js → ganttDiagram-R7TSEDQI-DjI0wOt_.js} +1 -1
  44. package/dist/client/assets/{gitGraph-VSP46ZUC-BVX8vTtR.js → gitGraph-VSP46ZUC-DYV_SxZX.js} +1 -1
  45. package/dist/client/assets/{gitGraphDiagram-XJZIOB7I-CPQk5VE5.js → gitGraphDiagram-XJZIOB7I-BExZk6Ip.js} +1 -1
  46. package/dist/client/assets/{index-C_Aj3ei6.css → index-B1sc_VJP.css} +1 -1
  47. package/dist/client/assets/{index-ER_woxi_.js → index-CFauUEo5.js} +8 -8
  48. package/dist/client/assets/{info-OHQRW6UA-CiACZ4dZ.js → info-OHQRW6UA-_PGgqHBK.js} +1 -1
  49. package/dist/client/assets/{infoDiagram-5W2HQ5XZ-CeYol-zS.js → infoDiagram-5W2HQ5XZ-Ct7Xkmxv.js} +1 -1
  50. package/dist/client/assets/{ishikawaDiagram-K3B6WC7H-fZGAv7aC.js → ishikawaDiagram-K3B6WC7H-6fFHBhEJ.js} +1 -1
  51. package/dist/client/assets/{journeyDiagram-COXZFDF6-hYD4-Nzu.js → journeyDiagram-COXZFDF6-9yLET_N7.js} +1 -1
  52. package/dist/client/assets/{kanban-definition-P3RFRI5V-CsPnTF1p.js → kanban-definition-P3RFRI5V-C_Wk-kP3.js} +1 -1
  53. package/dist/client/assets/{line-BNTKL8TA.js → line-CiquwXl-.js} +1 -1
  54. package/dist/client/assets/{linear-Cce8bX2R.js → linear-j4E2p09E.js} +1 -1
  55. package/dist/client/assets/{mermaid-parser.core-Dm9zbKNC.js → mermaid-parser.core-DnyWp22g.js} +3 -3
  56. package/dist/client/assets/{mermaid.core-BlTF5SGB.js → mermaid.core-CC7Mjmim.js} +4 -4
  57. package/dist/client/assets/{mindmap-definition-LZFPQGKD-DPDZDyrF.js → mindmap-definition-LZFPQGKD-Bjyclie9.js} +1 -1
  58. package/dist/client/assets/{packet-JDAUHWVQ-Cw7drr4R.js → packet-JDAUHWVQ-BO2oRn9k.js} +1 -1
  59. package/dist/client/assets/{pegDiagram-BGZESJAR-B_-egrxY.js → pegDiagram-BGZESJAR-fpy0BoA6.js} +1 -1
  60. package/dist/client/assets/{pie-XZMESJXO-CnISYYP8.js → pie-XZMESJXO-tQ1Bhk1D.js} +1 -1
  61. package/dist/client/assets/{pieDiagram-CAPJLFHJ-B3V9syR-.js → pieDiagram-CAPJLFHJ-DDYrtVO5.js} +1 -1
  62. package/dist/client/assets/{quadrantDiagram-GDMTTRAM-Cyd2Tmto.js → quadrantDiagram-GDMTTRAM-Bm38tNvj.js} +1 -1
  63. package/dist/client/assets/{radar-ABXABTNO-B_y2nD2r.js → radar-ABXABTNO-XYcf5ZFe.js} +1 -1
  64. package/dist/client/assets/{railroad-I3PHUGI6-Ce0KRsHH.js → railroad-I3PHUGI6-yABHrrSp.js} +1 -1
  65. package/dist/client/assets/{railroad-abnf-LNEFI6M7-B8j69Jgn.js → railroad-abnf-LNEFI6M7-C6nv1MeD.js} +1 -1
  66. package/dist/client/assets/{railroad-ebnf-DWYD2UWJ-BlQVZVUm.js → railroad-ebnf-DWYD2UWJ-B-jcbRR7.js} +1 -1
  67. package/dist/client/assets/{railroad-peg-JR7BVNR7-D2rqEEbb.js → railroad-peg-JR7BVNR7-Fy-FXnU-.js} +1 -1
  68. package/dist/client/assets/{railroadDiagram-SM67HX2B-i4CS0l36.js → railroadDiagram-SM67HX2B-C-wzOdeh.js} +1 -1
  69. package/dist/client/assets/{requirementDiagram-X7JNWC4A-BqT0bKku.js → requirementDiagram-X7JNWC4A-C2vuBz71.js} +1 -1
  70. package/dist/client/assets/{sankeyDiagram-UM26HJRW-CkDhYMye.js → sankeyDiagram-UM26HJRW-VeIvIweU.js} +1 -1
  71. package/dist/client/assets/{sequenceDiagram-ZO4K6R2Y-b7MivyiD.js → sequenceDiagram-ZO4K6R2Y-DDQjlIqd.js} +1 -1
  72. package/dist/client/assets/{src-C4U1ove4.js → src-C6KzIDbE.js} +1 -1
  73. package/dist/client/assets/{stateDiagram-v2-TBUQTH76-CwrO6djX.js → stateDiagram-v2-TBUQTH76-DQD4024w.js} +1 -1
  74. package/dist/client/assets/{swimlanes-N4OXWK64-yg75UB9r.js → swimlanes-N4OXWK64-JOj2yGO9.js} +1 -1
  75. package/dist/client/assets/swimlanesDiagram-K3J5GTZL-CM5Cd15s.js +8 -0
  76. package/dist/client/assets/{timeline-definition-YOQAKGHF-fwRPIAK4.js → timeline-definition-YOQAKGHF-CC_dv_Yy.js} +1 -1
  77. package/dist/client/assets/{treeView-D4JQ5SDB-BnLg_7c8.js → treeView-D4JQ5SDB-dm-xyZ9g.js} +1 -1
  78. package/dist/client/assets/{treemap-SAJKECNS-BYOiaxt8.js → treemap-SAJKECNS-CEdGc5dx.js} +1 -1
  79. package/dist/client/assets/{usecaseDiagram-VIAY4XPW-CcVmBMgy.js → usecaseDiagram-VIAY4XPW-Drcb7b3J.js} +1 -1
  80. package/dist/client/assets/{vennDiagram-BLWOH2XV-CYEpNiOb.js → vennDiagram-BLWOH2XV-Du__TT5s.js} +1 -1
  81. package/dist/client/assets/{wardley-7MLQ67FV-Cuuf5uPH.js → wardley-7MLQ67FV-DturZ0EB.js} +1 -1
  82. package/dist/client/assets/{wardleyDiagram-YMQ3BMBF-BoKIF4tr.js → wardleyDiagram-YMQ3BMBF-BVXX8ZUH.js} +1 -1
  83. package/dist/client/assets/{xychartDiagram-TAQBALBS-B51VR_20.js → xychartDiagram-TAQBALBS-CyXltbG2.js} +1 -1
  84. package/dist/client/index.html +2 -2
  85. package/dist/node/cli/args.js +10 -6
  86. package/dist/node/cli/index.js +65 -27
  87. package/dist/node/cli/instance.rules.js +22 -2
  88. package/dist/node/cli/ports.js +50 -0
  89. package/package.json +1 -1
  90. package/dist/client/assets/channel-DFaMRHZc.js +0 -1
  91. package/dist/client/assets/flowDiagram-OXPTDLAJ-BbHJTVjI.js +0 -1
  92. package/dist/client/assets/swimlanesDiagram-K3J5GTZL-BcIfokoM.js +0 -8
@@ -1,4 +1,4 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/mermaid.core-BlTF5SGB.js","assets/chunk-Y2CYZVJY-DsF7k-Jl.js","assets/src-C4U1ove4.js","assets/chunk-VPRB5NB3-ZzCBRMxY.js","assets/chunk-3YJQHVM4-Xz1DUt9r.js","assets/dist-CXpE70MZ.js","assets/chunk-HJ2JQQFS-ie5keT3-.js","assets/chunk-E2ZNV5FY-D1BIxPMx.js","assets/chunk-DUW6YSOI-Dgx8z5s3.js","assets/chunk-4EA7E6EY-Bj0Yui92.js","assets/chunk-XC4XBNZT-CF_ExUnR.js","assets/chunk-J5ZVWO5B-oDCd-gWO.js","assets/rough.esm-Dy-Kn_BL.js","assets/chunk-DBDB3WZW-B6Ha2UK4.js","assets/chunk-2BW5OAIV-MCOb6mxM.js","assets/line-BNTKL8TA.js","assets/path-fybaL0A-.js","assets/array-BifhSqXX.js","assets/chunk-NTY3LDVX-DC4zuhvF.js"])))=>i.map(i=>d[i]);
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/mermaid.core-CC7Mjmim.js","assets/chunk-Y2CYZVJY-DsF7k-Jl.js","assets/src-C6KzIDbE.js","assets/chunk-VPRB5NB3-BwgJCQTz.js","assets/chunk-3YJQHVM4-l9nWADIg.js","assets/dist-C_tiWm-_.js","assets/chunk-HJ2JQQFS-DD88ca1g.js","assets/chunk-E2ZNV5FY-CBOkwewU.js","assets/chunk-DUW6YSOI-Dgx8z5s3.js","assets/chunk-4EA7E6EY-C0v9hWIC.js","assets/chunk-XC4XBNZT-C-hUCVsJ.js","assets/chunk-J5ZVWO5B-oDCd-gWO.js","assets/rough.esm-Dy-Kn_BL.js","assets/chunk-DBDB3WZW-mqha7s7f.js","assets/chunk-2BW5OAIV-D5Qj8Q2W.js","assets/line-CiquwXl-.js","assets/path-fybaL0A-.js","assets/array-BifhSqXX.js","assets/chunk-NTY3LDVX-DscqVJZQ.js"])))=>i.map(i=>d[i]);
2
2
  var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(e,t)=>()=>(t||(e((t={exports:{}}).exports,t,t.exports),e=null),t.exports),s=(e,n)=>{let r={};for(var i in e)t(r,i,{get:e[i],enumerable:!0});return n||t(r,Symbol.toStringTag,{value:`Module`}),r},c=(e,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(var c=r(i),l=0,u=c.length,d;l<u;l++)d=c[l],!a.call(e,d)&&d!==o&&t(e,d,{get:(e=>i[e]).bind(null,d),enumerable:!(s=n(i,d))||s.enumerable});return e},l=(n,r,o)=>(o=n==null?{}:e(i(n)),c(r||!n||!n.__esModule||!a.call(n,`default`)?t(o,`default`,{value:n,enumerable:!0}):o,n)),u=(e=>typeof require<`u`?require:typeof Proxy<`u`?new Proxy(e,{get:(e,t)=>(typeof require<`u`?require:e)[t]}):e)(function(e){if(typeof require<`u`)return require.apply(this,arguments);throw Error('Calling `require` for "'+e+"\" in an environment that doesn't expose the `require` function. See https://rolldown.rs/in-depth/bundling-cjs#require-external-modules for more details.")});(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),t.credentials=e.crossOrigin===`use-credentials`?`include`:e.crossOrigin===`anonymous`?`omit`:`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();function d(e){let t=Object.create(null);for(let n of e.split(`,`))t[n]=1;return e=>e in t}var f={},p=[],m=()=>{},h=()=>!1,g=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),_=e=>e.startsWith(`onUpdate:`),v=Object.assign,y=(e,t)=>{let n=e.indexOf(t);n>-1&&e.splice(n,1)},b=Object.prototype.hasOwnProperty,x=(e,t)=>b.call(e,t),S=Array.isArray,C=e=>A(e)===`[object Map]`,w=e=>A(e)===`[object Set]`,ee=e=>A(e)===`[object Date]`,T=e=>typeof e==`function`,E=e=>typeof e==`string`,D=e=>typeof e==`symbol`,O=e=>typeof e==`object`&&!!e,k=e=>(O(e)||T(e))&&T(e.then)&&T(e.catch),te=Object.prototype.toString,A=e=>te.call(e),ne=e=>A(e).slice(8,-1),j=e=>A(e)===`[object Object]`,M=e=>E(e)&&e!==`NaN`&&e[0]!==`-`&&``+parseInt(e,10)===e,N=d(`,key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted`),re=e=>{let t=Object.create(null);return(n=>t[n]||(t[n]=e(n)))},ie=/-\w/g,P=re(e=>e.replace(ie,e=>e.slice(1).toUpperCase())),ae=/\B([A-Z])/g,oe=re(e=>e.replace(ae,`-$1`).toLowerCase()),F=re(e=>e.charAt(0).toUpperCase()+e.slice(1)),se=re(e=>e?`on${F(e)}`:``),ce=(e,t)=>!Object.is(e,t),le=(e,...t)=>{for(let n=0;n<e.length;n++)e[n](...t)},ue=(e,t,n,r=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:r,value:n})},de=e=>{let t=parseFloat(e);return isNaN(t)?e:t},fe,pe=()=>fe||=typeof globalThis<`u`?globalThis:typeof self<`u`?self:typeof window<`u`?window:typeof global<`u`?global:{};function me(e){if(S(e)){let t={};for(let n=0;n<e.length;n++){let r=e[n],i=E(r)?ve(r):me(r);if(i)for(let e in i)t[e]=i[e]}return t}if(E(e)||O(e))return e}var he=/;(?![^(]*\))/g,ge=/:([^]+)/,_e=/"(?:[^"\\]|\\[^])*"|'(?:[^'\\]|\\[^])*'|\\[^]|\/\*[^]*?\*\//g;function ve(e){let t={};return e.replace(_e,e=>e.startsWith(`/*`)?``:e).split(he).forEach(e=>{if(e){let n=e.split(ge);n.length>1&&(t[n[0].trim()]=n[1].trim())}}),t}function ye(e){let t=``;if(E(e))t=e;else if(S(e))for(let n=0;n<e.length;n++){let r=ye(e[n]);r&&(t+=r+` `)}else if(O(e))for(let n in e)e[n]&&(t+=n+` `);return t.trim()}var be=d(`itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,playsinline,readonly`);function xe(e){return!!e||e===``}function Se(e,t,n){if(e.length!==t.length)return!1;let r=!0;for(let i=0;r&&i<e.length;i++)r=Ee(e[i],t[i],n);return r}function Ce(e,t,n){if(e.size!==t.size)return!1;let r=Array.from(t),i=new Uint8Array(r.length);for(let t of e){let e=-1;for(let a=0;a<r.length;a++)if(!i[a]&&Ee(t,r[a],n)){e=a;break}if(e<0)return!1;i[e]=1}return!0}function we(e,t,n){let r=C(e),i=C(t);if(r||i||(r=w(e),i=w(t),r||i))return r&&i?Ce(e,t,n):!1;if(Object.keys(e).length!==Object.keys(t).length)return!1;for(let r in e){let i=e.hasOwnProperty(r),a=t.hasOwnProperty(r);if(i&&!a||!i&&a||!Ee(e[r],t[r],n))return!1}return String(e)===String(t)}function Te(e,t,n,r){n||=[new Map,new Map];let[i,a]=n;if(i.has(e)||a.has(t))return i.get(e)===t&&a.get(t)===e;i.set(e,t),a.set(t,e);let o=r(e,t,n);return i.delete(e),a.delete(t),o}function Ee(e,t,n){if(e===t)return!0;let r=ee(e),i=ee(t);return r||i?r&&i?e.getTime()===t.getTime():!1:(r=D(e),i=D(t),r||i?e===t:(r=S(e),i=S(t),r||i?r&&i?Te(e,t,n,Se):!1:(r=O(e),i=O(t),r||i?!r||!i?!1:Te(e,t,n,we):String(e)===String(t))))}function De(e,t){return e.findIndex(e=>Ee(e,t))}var Oe=e=>!!(e&&e.__v_isRef===!0),I=e=>E(e)?e:e==null?``:S(e)||O(e)&&(e.toString===te||!T(e.toString))?Oe(e)?I(e.value):JSON.stringify(e,ke,2):String(e),ke=(e,t)=>Oe(t)?ke(e,t.value):C(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((e,[t,n],r)=>(e[Ae(t,r)+` =>`]=n,e),{})}:w(t)?{[`Set(${t.size})`]:[...t.values()].map(e=>Ae(e))}:D(t)?Ae(t):O(t)&&!S(t)&&!j(t)?String(t):t,Ae=(e,t=``)=>D(e)?`Symbol(${e.description??t})`:e,je,Me=class{constructor(e=!1){this.detached=e,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this._warnOnRun=!0,this.__v_skip=!0,!e&&je&&(je.active?(this.parent=je,this.index=(je.scopes||(je.scopes=[])).push(this)-1):(this._active=!1,this._warnOnRun=!1))}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let e,t;if(this.scopes){let n=this.scopes.slice();for(e=0,t=n.length;e<t;e++)n[e].pause()}for(e=0,t=this.effects.length;e<t;e++)this.effects[e].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let e,t;if(this.scopes){let n=this.scopes.slice();for(e=0,t=n.length;e<t;e++)n[e].resume()}let n=this.effects.slice();for(e=0,t=n.length;e<t;e++)n[e].resume()}}run(e){if(this._active){let t=je;try{return je=this,e()}finally{je=t}}}on(){++this._on===1&&(this.prevScope=je,je=this)}off(){if(this._on>0&&--this._on===0){if(je===this)je=this.prevScope;else{let e=je;for(;e;){if(e.prevScope===this){e.prevScope=this.prevScope;break}e=e.prevScope}}this.prevScope=void 0}}stop(e){if(this._active){this._active=!1;let t,n;for(t=0,n=this.effects.length;t<n;t++)this.effects[t].stop();for(this.effects.length=0,t=0,n=this.cleanups.length;t<n;t++)this.cleanups[t]();if(this.cleanups.length=0,this.scopes){let e=this.scopes.slice();for(t=0,n=e.length;t<n;t++)e[t].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!e){let e=this.parent.scopes.pop();e&&e!==this&&(this.parent.scopes[this.index]=e,e.index=this.index)}this.parent=void 0}}};function Ne(){return je}var L,Pe=new WeakSet,Fe=class{constructor(e){this.fn=e,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,je&&(je.active?je.effects.push(this):this.flags&=-2)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,Pe.has(this)&&(Pe.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||ze(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,Qe(this),He(this);let e=L,t=Je;L=this,Je=!0;try{return this.fn()}finally{Ue(this),L=e,Je=t,this.flags&=-3}}stop(){if(this.flags&1){for(let e=this.deps;e;e=e.nextDep)Ke(e);this.deps=this.depsTail=void 0,Qe(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?Pe.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){We(this)&&this.run()}get dirty(){return We(this)}},Ie=0,Le,Re;function ze(e,t=!1){e.flags|=8,t?(e.next=Re,Re=e):(e.next=Le,Le=e)}function Be(){Ie++}function Ve(){if(--Ie>0)return;if(Re){let e=Re;for(Re=void 0;e;){let t=e.next;e.next=void 0,e.flags&=-9,e=t}}let e;for(;Le;){let t=Le;for(Le=void 0;t;){let n=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(t){e||=t}t=n}}if(e)throw e}function He(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function Ue(e){let t,n=e.depsTail,r=n;for(;r;){let e=r.prevDep;r.version===-1?(r===n&&(n=e),Ke(r),qe(r)):t=r,r.dep.activeLink=r.prevActiveLink,r.prevActiveLink=void 0,r=e}e.deps=t,e.depsTail=n}function We(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(Ge(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function Ge(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===$e)||(e.globalVersion=$e,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!We(e))))return;e.flags|=2;let t=e.dep,n=L,r=Je;L=e,Je=!0;try{He(e);let n=e.fn(e._value);(t.version===0||ce(n,e._value))&&(e.flags|=128,e._value=n,t.version++)}catch(e){throw t.version++,e}finally{L=n,Je=r,Ue(e),e.flags&=-3}}function Ke(e,t=!1){let{dep:n,prevSub:r,nextSub:i}=e;if(r&&(r.nextSub=i,e.prevSub=void 0),i&&(i.prevSub=r,e.nextSub=void 0),n.subs===e&&(n.subs=r,!r&&n.computed)){n.computed.flags&=-5;for(let e=n.computed.deps;e;e=e.nextDep)Ke(e,!0)}!t&&!--n.sc&&n.map&&n.map.delete(n.key)}function qe(e){let{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}var Je=!0,Ye=[];function Xe(){Ye.push(Je),Je=!1}function Ze(){let e=Ye.pop();Je=e===void 0||e}function Qe(e){let{cleanup:t}=e;if(e.cleanup=void 0,t){let e=L;L=void 0;try{t()}finally{L=e}}}var $e=0,et=class{constructor(e,t){this.sub=e,this.dep=t,this.version=t.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}},tt=class{constructor(e){this.computed=e,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0,this.__v_skip=!0}track(e){if(!L||!Je||L===this.computed)return;let t=this.activeLink;if(t===void 0||t.sub!==L)t=this.activeLink=new et(L,this),L.deps?(t.prevDep=L.depsTail,L.depsTail.nextDep=t,L.depsTail=t):L.deps=L.depsTail=t,nt(t);else if(t.version===-1&&(t.version=this.version,t.nextDep)){let e=t.nextDep;e.prevDep=t.prevDep,t.prevDep&&(t.prevDep.nextDep=e),t.prevDep=L.depsTail,t.nextDep=void 0,L.depsTail.nextDep=t,L.depsTail=t,L.deps===t&&(L.deps=e)}return t}trigger(e){this.version++,$e++,this.notify(e)}notify(e){Be();try{for(let e=this.subs;e;e=e.prevSub)e.sub.notify()&&e.sub.dep.notify()}finally{Ve()}}};function nt(e){if(e.dep.sc++,e.sub.flags&4){let t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let e=t.deps;e;e=e.nextDep)nt(e)}let n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}}var rt=new WeakMap,it=Symbol(``),at=Symbol(``),ot=Symbol(``);function st(e,t,n){if(Je&&L){let t=rt.get(e);t||rt.set(e,t=new Map);let r=t.get(n);r||(t.set(n,r=new tt),r.map=t,r.key=n),r.track()}}function ct(e,t,n,r,i,a){let o=rt.get(e);if(!o){$e++;return}let s=e=>{e&&e.trigger()};if(Be(),t===`clear`)o.forEach(s);else{let i=S(e),a=i&&M(n);if(i&&n===`length`){let e=Number(r);o.forEach((t,n)=>{(n===`length`||n===ot||!D(n)&&n>=e)&&s(t)})}else switch((n!==void 0||o.has(void 0))&&s(o.get(n)),a&&s(o.get(ot)),t){case`add`:i?a&&s(o.get(`length`)):(s(o.get(it)),C(e)&&s(o.get(at)));break;case`delete`:i||(s(o.get(it)),C(e)&&s(o.get(at)));break;case`set`:C(e)&&s(o.get(it))}}Ve()}function lt(e){let t=R(e);return t===e||(st(t,`iterate`,ot),Yt(e))?t:Jt(e)?qt(e)?t.map(e=>$t(Qt(e))):t.map($t):t.map(Qt)}function ut(e){return st(e=R(e),`iterate`,ot),e}function dt(e,t){return Jt(e)?$t(qt(e)?Qt(t):t):Qt(t)}var ft={__proto__:null,[Symbol.iterator](){return pt(this,Symbol.iterator,e=>dt(this,e))},concat(...e){return lt(this).concat(...e.map(e=>S(e)?lt(e):e))},entries(){return pt(this,`entries`,e=>(e[1]=dt(this,e[1]),e))},every(e,t){return gt(this,`every`,e,t,void 0,arguments)},filter(e,t){return gt(this,`filter`,e,t,e=>e.map(e=>dt(this,e)),arguments)},find(e,t){return gt(this,`find`,e,t,e=>dt(this,e),arguments)},findIndex(e,t){return gt(this,`findIndex`,e,t,void 0,arguments)},findLast(e,t){return gt(this,`findLast`,e,t,e=>dt(this,e),arguments)},findLastIndex(e,t){return gt(this,`findLastIndex`,e,t,void 0,arguments)},forEach(e,t){return gt(this,`forEach`,e,t,void 0,arguments)},includes(...e){return vt(this,`includes`,e)},indexOf(...e){return vt(this,`indexOf`,e)},join(e){return lt(this).join(e)},lastIndexOf(...e){return vt(this,`lastIndexOf`,e)},map(e,t){return gt(this,`map`,e,t,void 0,arguments)},pop(){return yt(this,`pop`)},push(...e){return yt(this,`push`,e)},reduce(e,...t){return _t(this,`reduce`,e,t)},reduceRight(e,...t){return _t(this,`reduceRight`,e,t)},shift(){return yt(this,`shift`)},some(e,t){return gt(this,`some`,e,t,void 0,arguments)},splice(...e){return yt(this,`splice`,e)},toReversed(){return lt(this).toReversed()},toSorted(e){return lt(this).toSorted(e)},toSpliced(...e){return lt(this).toSpliced(...e)},unshift(...e){return yt(this,`unshift`,e)},values(){return pt(this,`values`,e=>dt(this,e))}};function pt(e,t,n){let r=ut(e),i=r[t],a=i.call(r);if(r!==e&&!Yt(e)){if(a[Symbol.toStringTag]===`Array Iterator`){let e=Object.create(Object.getPrototypeOf(a));return e.next=()=>mt(a.next(),n),i!==ht[t]&&Object.defineProperties(e,{return:{get(){let e=a.return;return typeof e==`function`?e.bind(a):e}},throw:{get(){let e=a.throw;return typeof e==`function`?e.bind(a):e}}}),e}a._next=a.next,a.next=()=>mt(a._next(),n)}return a}function mt(e,t){return e.done||(e.value=t(e.value)),e}var ht=Array.prototype;function gt(e,t,n,r,i,a){let o=ut(e),s=o!==e&&!Yt(e),c=o[t];if(c!==ht[t]){let t=c.apply(e,a);return s?Qt(t):t}let l=n;o!==e&&(s?l=function(t,r){return n.call(this,dt(e,t),r,e)}:n.length>2&&(l=function(t,r){return n.call(this,t,r,e)}));let u=c.call(o,l,r);return s&&i?i(u):u}function _t(e,t,n,r){let i=ut(e),a=i!==e&&!Yt(e),o=n,s=!1;i!==e&&(a?(s=r.length===0,o=function(t,r,i){return s&&(s=!1,t=dt(e,t)),n.call(this,t,dt(e,r),i,e)}):n.length>3&&(o=function(t,r,i){return n.call(this,t,r,i,e)}));let c=i[t](o,...r);return s?dt(e,c):c}function vt(e,t,n){let r=R(e);st(r,`iterate`,ot);let i=r[t](...n);return(i===-1||i===!1)&&Xt(n[0])?(n[0]=R(n[0]),r[t](...n)):i}function yt(e,t,n=[]){Xe(),Be();let r=R(e)[t].apply(e,n);return Ve(),Ze(),r}var bt=d(`__proto__,__v_isRef,__isVue`),xt=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!==`arguments`&&e!==`caller`).map(e=>Symbol[e]).filter(D));function St(e){D(e)||(e=String(e));let t=R(this);return st(t,`has`,e),t.hasOwnProperty(e)}var Ct=class{constructor(e=!1,t=!1){this._isReadonly=e,this._isShallow=t}get(e,t,n){if(t===`__v_skip`)return e.__v_skip;let r=this._isReadonly,i=this._isShallow;if(t===`__v_isReactive`)return!r;if(t===`__v_isReadonly`)return r;if(t===`__v_isShallow`)return i;if(t===`__v_raw`)return n===(r?i?Vt:Bt:i?zt:Rt).get(e)||Object.getPrototypeOf(e)===Object.getPrototypeOf(n)?e:void 0;let a=S(e);if(!r){let e;if(a&&(e=ft[t]))return e;if(t===`hasOwnProperty`)return St}let o=Reflect.get(e,t,en(e)?e:n);if((D(t)?xt.has(t):bt(t))||(r||st(e,`get`,t),i))return o;if(en(o)){let e=a&&M(t)?o:o.value;return r&&O(e)?Gt(e):e}return O(o)?r?Gt(o):Ut(o):o}},wt=class extends Ct{constructor(e=!1){super(!1,e)}set(e,t,n,r){let i=e[t],a=S(e)&&M(t);if(!this._isShallow){let e=Jt(i);if(!Yt(n)&&!Jt(n)&&(i=R(i),n=R(n)),!a&&en(i)&&!en(n))return e||(i.value=n),!0}let o=a?Number(t)<e.length:x(e,t),s=Reflect.set(e,t,n,en(e)?e:r);return e===R(r)&&s&&(o?ce(n,i)&&ct(e,`set`,t,n,i):ct(e,`add`,t,n)),s}deleteProperty(e,t){let n=x(e,t),r=e[t],i=Reflect.deleteProperty(e,t);return i&&n&&ct(e,`delete`,t,void 0,r),i}has(e,t){let n=Reflect.has(e,t);return(!D(t)||!xt.has(t))&&st(e,`has`,t),n}ownKeys(e){return st(e,`iterate`,S(e)?`length`:it),Reflect.ownKeys(e)}},Tt=class extends Ct{constructor(e=!1){super(!0,e)}set(e,t){return!0}deleteProperty(e,t){return!0}},Et=new wt,Dt=new Tt,Ot=new wt(!0),kt=e=>e,At=e=>Reflect.getPrototypeOf(e);function jt(e,t,n){return function(...r){let i=this.__v_raw,a=R(i),o=C(a),s=e===`entries`||e===Symbol.iterator&&o,c=e===`keys`&&o,l=i[e](...r),u=n?kt:t?$t:Qt;return!t&&st(a,`iterate`,c?at:it),v(Object.create(l),{next(){let{value:e,done:t}=l.next();return t?{value:e,done:t}:{value:s?[u(e[0]),u(e[1])]:u(e),done:t}}})}}function Mt(e){return function(...t){return e===`delete`?!1:e===`clear`?void 0:this}}function Nt(e,t){let n={get(n){let r=this.__v_raw,i=R(r),a=R(n);e||(ce(n,a)&&st(i,`get`,n),st(i,`get`,a));let{has:o}=At(i),s=t?kt:e?$t:Qt;if(o.call(i,n))return s(r.get(n));if(o.call(i,a))return s(r.get(a));r!==i&&r.get(n)},get size(){let t=this.__v_raw;return!e&&st(R(t),`iterate`,it),t.size},has(t){let n=this.__v_raw,r=R(n),i=R(t);return e||(ce(t,i)&&st(r,`has`,t),st(r,`has`,i)),t===i?n.has(t):n.has(t)||n.has(i)},forEach(n,r){let i=this,a=i.__v_raw,o=R(a),s=t?kt:e?$t:Qt;return!e&&st(o,`iterate`,it),a.forEach((e,t)=>n.call(r,s(e),s(t),i))}};return v(n,e?{add:Mt(`add`),set:Mt(`set`),delete:Mt(`delete`),clear:Mt(`clear`)}:{add(e){let n=R(this),r=At(n),i=R(e),a=!t&&!Yt(e)&&!Jt(e)?i:e;return r.has.call(n,a)||ce(e,a)&&r.has.call(n,e)||ce(i,a)&&r.has.call(n,i)||(n.add(a),ct(n,`add`,a,a)),this},set(e,n){!t&&!Yt(n)&&!Jt(n)&&(n=R(n));let r=R(this),{has:i,get:a}=At(r),o=i.call(r,e);o||=(e=R(e),i.call(r,e));let s=a.call(r,e);return r.set(e,n),o?ce(n,s)&&ct(r,`set`,e,n,s):ct(r,`add`,e,n),this},delete(e){let t=R(this),{has:n,get:r}=At(t),i=n.call(t,e);i||=(e=R(e),n.call(t,e));let a=r?r.call(t,e):void 0,o=t.delete(e);return i&&ct(t,`delete`,e,void 0,a),o},clear(){let e=R(this),t=e.size!==0,n=e.clear();return t&&ct(e,`clear`,void 0,void 0,void 0),n}}),[`keys`,`values`,`entries`,Symbol.iterator].forEach(r=>{n[r]=jt(r,e,t)}),n}function Pt(e,t){let n=Nt(e,t);return(r,i,a)=>i===`__v_isReactive`?!e:i===`__v_isReadonly`?e:i===`__v_isShallow`?t:i===`__v_raw`?r:Reflect.get(x(n,i)&&i in r?n:r,i,a)}var Ft={get:Pt(!1,!1)},It={get:Pt(!1,!0)},Lt={get:Pt(!0,!1)},Rt=new WeakMap,zt=new WeakMap,Bt=new WeakMap,Vt=new WeakMap;function Ht(e){switch(e){case`Object`:case`Array`:return 1;case`Map`:case`Set`:case`WeakMap`:case`WeakSet`:return 2;default:return 0}}function Ut(e){return Jt(e)?e:Kt(e,!1,Et,Ft,Rt)}function Wt(e){return Kt(e,!1,Ot,It,zt)}function Gt(e){return Kt(e,!0,Dt,Lt,Bt)}function Kt(e,t,n,r,i){if(!O(e)||e.__v_raw&&!(t&&e.__v_isReactive)||e.__v_skip||!Object.isExtensible(e))return e;let a=i.get(e);if(a)return a;let o=Ht(ne(e));if(o===0)return e;let s=new Proxy(e,o===2?r:n);return i.set(e,s),s}function qt(e){return Jt(e)?qt(e.__v_raw):!!(e&&e.__v_isReactive)}function Jt(e){return!!(e&&e.__v_isReadonly)}function Yt(e){return!!(e&&e.__v_isShallow)}function Xt(e){return e?!!e.__v_raw:!1}function R(e){let t=e&&e.__v_raw;return t?R(t):e}function Zt(e){return!x(e,`__v_skip`)&&Object.isExtensible(e)&&ue(e,`__v_skip`,!0),e}var Qt=e=>O(e)?Ut(e):e,$t=e=>O(e)?Gt(e):e;function en(e){return e?e.__v_isRef===!0:!1}function z(e){return nn(e,!1)}function tn(e){return nn(e,!0)}function nn(e,t){return en(e)?e:new rn(e,t)}var rn=class{constructor(e,t){this.dep=new tt,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=t?e:R(e),this._value=t?e:Qt(e),this.__v_isShallow=t}get value(){return this.dep.track(),this._value}set value(e){let t=this._rawValue,n=this.__v_isShallow||Yt(e)||Jt(e);e=n?e:R(e),ce(e,t)&&(this._rawValue=e,this._value=n?e:Qt(e),this.dep.trigger())}};function B(e){return en(e)?e.value:e}var an={get:(e,t,n)=>t===`__v_raw`?e:B(Reflect.get(e,t,n)),set:(e,t,n,r)=>{let i=e[t];return en(i)&&!en(n)?(i.value=n,!0):Reflect.set(e,t,n,r)}};function on(e){return qt(e)?e:new Proxy(e,an)}var sn=class{constructor(e,t,n){this.fn=e,this.setter=t,this._value=void 0,this.dep=new tt(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=$e-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!t,this.isSSR=n}notify(){if(this.flags|=16,!(this.flags&8)&&L!==this)return ze(this,!0),!0}get value(){let e=this.dep.track();return Ge(this),e&&(e.version=this.dep.version),this._value}set value(e){this.setter&&this.setter(e)}};function cn(e,t,n=!1){let r,i;return T(e)?r=e:(r=e.get,i=e.set),new sn(r,i,n)}var ln={},un=new WeakMap,dn=void 0;function fn(e,t=!1,n=dn){if(n){let t=un.get(n);t||un.set(n,t=[]),t.push(e)}}function pn(e,t,n=f){let{immediate:r,deep:i,once:a,scheduler:o,augmentJob:s,call:c}=n,l=e=>i?e:Yt(e)||i===!1||i===0?mn(e,1):mn(e),u,d,p,h,g=!1,_=!1;if(en(e)?(d=()=>e.value,g=Yt(e)):qt(e)?(d=()=>l(e),g=!0):S(e)?(_=!0,g=e.some(e=>qt(e)||Yt(e)),d=()=>e.map(e=>{if(en(e))return e.value;if(qt(e))return l(e);if(T(e))return c?c(e,2):e()})):d=T(e)?t?c?()=>c(e,2):e:()=>{if(p){Xe();try{p()}finally{Ze()}}let t=dn;dn=u;try{return c?c(e,3,[h]):e(h)}finally{dn=t}}:m,t&&i){let e=d,t=i===!0?1/0:i;d=()=>mn(e(),t)}let v=Ne(),b=()=>{u.stop(),v&&v.active&&y(v.effects,u)};if(a&&t){let e=t;t=(...t)=>{try{return e(...t)}finally{b()}}}let x=_?Array(e.length).fill(ln):ln,C=e=>{if(u.flags&1&&(u.dirty||e)){if(t){let n=u.run();if(e||i||g||(_?n.some((e,t)=>ce(e,x[t])):ce(n,x))){let e=dn;Xe();try{p&&p(),dn=u;let e=[n,x===ln?void 0:_&&x[0]===ln?[]:x,h];x=n,c?c(t,3,e):t(...e)}finally{dn=e,Ze()}}}else u.run()}};return s&&s(C),u=new Fe(d),u.scheduler=o?()=>o(C,!1):C,h=e=>fn(e,!1,u),p=u.onStop=()=>{let e=un.get(u);if(e){if(c)c(e,4);else for(let t of e)t();un.delete(u)}},t?r?C(!0):x=u.run():o?o(C.bind(null,!0),!0):u.run(),b.pause=u.pause.bind(u),b.resume=u.resume.bind(u),b.stop=b,b}function mn(e,t=1/0,n){if(t<=0||!O(e)||e.__v_skip||(n||=new Map,(n.get(e)||0)>=t))return e;if(n.set(e,t),t--,en(e))mn(e.value,t,n);else if(S(e))for(let r=0;r<e.length;r++)mn(e[r],t,n);else if(w(e)||C(e))e.forEach(e=>{mn(e,t,n)});else if(j(e)){for(let r in e)mn(e[r],t,n);for(let r of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,r)&&mn(e[r],t,n)}return e}function hn(e,t,n,r){try{return r?e(...r):e()}catch(e){_n(e,t,n)}}function gn(e,t,n,r){if(T(e)){let i=hn(e,t,n,r);return i&&k(i)&&i.catch(e=>{_n(e,t,n)}),i}if(S(e)){let i=[];for(let a=0;a<e.length;a++)i.push(gn(e[a],t,n,r));return i}}function _n(e,t,n,r=!0){let i=t?t.vnode:null,{errorHandler:a,throwUnhandledErrorInProduction:o}=t&&t.appContext.config||f;if(t){let r=t.parent,i=t.proxy,o=`https://vuejs.org/error-reference/#runtime-${n}`;for(;r;){let t=r.ec;if(t){for(let n=0;n<t.length;n++)if(t[n](e,i,o)===!1)return}r=r.parent}if(a){Xe(),hn(a,null,10,[e,i,o]),Ze();return}}vn(e,n,i,r,o)}function vn(e,t,n,r=!0,i=!1){if(i)throw e;console.error(e)}var yn=[],bn=-1,xn=[],Sn=null,Cn=0,wn=Promise.resolve(),Tn=null;function En(e){let t=Tn||wn;return e?t.then(this?e.bind(this):e):t}function Dn(e){let t=bn+1,n=yn.length;for(;t<n;){let r=t+n>>>1,i=yn[r],a=Fn(i);a<e||a===e&&i.flags&2?t=r+1:n=r}return t}function On(e){if(!(e.flags&1)){let t=Fn(e),n=yn[yn.length-1];!n||!(e.flags&2)&&t>=Fn(n)?yn.push(e):yn.splice(Dn(t),0,e),e.flags|=1,kn()}}function kn(){Tn||=wn.then(In)}function An(e){if(!S(e))Sn&&e.id===-1?Sn.splice(Cn+1,0,e):e.flags&1||(xn.push(e),e.flags|=1);else for(let t=0;t<e.length;t++)xn.push(e[t]);kn()}function jn(e,t,n,r=bn+1){for(;r<yn.length;r++){let n=yn[r];if(n&&n.flags&2){if(e&&n.id!==e.uid||t!==void 0&&!(n.id>=t))continue;yn.splice(r,1),r=e?r-1:bn,n.flags&4&&(n.flags&=-2),n(),n.flags&4||(n.flags&=-2)}}}function Mn(e,t,n=0){if(xn.length){let e=xn,r=0;if(t){e=[];for(let i=0;i<xn.length;i++){let a=xn[i];(a.i===void 0?t.has(a):!a.i||a.i.uid<n)?xn[r++]=a:e.push(a)}}let i=[...new Set(e)].sort((e,t)=>Fn(e)-Fn(t));if(xn.length=r,Sn){for(let e=0;e<i.length;e++)Sn.push(i[e]);return}for(Sn=i,Cn=0;Cn<Sn.length;Cn++){let e=Sn[Cn];e.flags&4&&(e.flags&=-2),e.flags&8||e(),e.flags&=-2}Sn=null,Cn=0}}var Nn=!1;function Pn(e,t){if(Nn){e();return}let n=t===void 0?void 0:new Set(xn);e(),Nn=!0;try{jn(void 0,t),Mn(void 0,n,t)}finally{Nn=!1}}var Fn=e=>e.id==null?e.flags&2?-1:1/0:e.id;function In(e){try{for(bn=0;bn<yn.length;bn++){let e=yn[bn];e&&!(e.flags&8)&&(e.flags&4&&(e.flags&=-2),hn(e,e.i,e.i?15:14),e.flags&4||(e.flags&=-2))}}finally{for(;bn<yn.length;bn++){let e=yn[bn];e&&(e.flags&=-2)}bn=-1,yn.length=0,Mn(e),Tn=null,(yn.length||xn.length)&&In(e)}}var Ln=null,Rn=null;function zn(e){let t=Ln;return Ln=e,Rn=e&&e.type.__scopeId||null,t}function Bn(e,t=Ln,n){if(!t||e._n)return e;let r=(...n)=>{r._d&&ra(-1);let i=zn(t),a=$i.length,o;try{o=e(...n)}finally{for(let e=$i.length;e>a;e--)ta();zn(i),r._d&&ra(1)}return o};return r._n=!0,r._c=!0,r._d=!0,r}function Vn(e,t){if(Ln===null)return e;let n=Ia(Ln),r=e.dirs||=[];for(let e=0;e<t.length;e++){let[i,a,o,s=f]=t[e];i&&(T(i)&&(i={mounted:i,updated:i}),i.deep&&mn(a),r.push({dir:i,instance:n,value:a,oldValue:void 0,arg:o,modifiers:s}))}return e}function Hn(e,t,n,r){let i=e.dirs,a=t&&t.dirs;for(let o=0;o<i.length;o++){let s=i[o];a&&(s.oldValue=a[o].value);let c=s.dir[r];c&&(Xe(),gn(c,n,8,[e.el,s,e,t]),Ze())}}function Un(e,t){if(Sa){let n=Sa.provides,r=Sa.parent&&Sa.parent.provides;r===n&&(n=Sa.provides=Object.create(r)),n[e]=t}}function Wn(e,t,n=!1){let r=Ca();if(r||ai){let i=ai?ai._context.provides:r?r.parent==null||r.ce?r.vnode.appContext&&r.vnode.appContext.provides:r.parent.provides:void 0;if(i&&e in i)return i[e];if(arguments.length>1)return n&&T(t)?t.call(r&&r.proxy):t}}var Gn=Symbol.for(`v-scx`),Kn=()=>Wn(Gn);function qn(e,t,n){return Jn(e,t,n)}function Jn(e,t,n=f){let{immediate:r,deep:i,flush:a,once:o}=n,s=v({},n),c=t&&r||!t&&a!==`post`,l;if(ka){if(a===`sync`){let e=Kn();l=e.__watcherHandles||=[]}else if(!c){let e=()=>{};return e.stop=m,e.resume=m,e.pause=m,e}}let u=Sa;s.call=(e,t,n)=>gn(e,u,t,n);let d=!1;a===`post`?s.scheduler=e=>{e.i=u,Li(e,u&&u.suspense)}:a!==`sync`&&(d=!0,s.scheduler=(e,t)=>{t?e():On(e)}),s.augmentJob=e=>{t&&(e.flags|=4),d&&(e.flags|=2,u&&(e.id=u.uid,e.i=u))};let p=pn(e,t,s);return ka&&(l?l.push(p):c&&p()),p}function Yn(e,t,n){let r=this.proxy,i=E(e)?e.includes(`.`)?Xn(r,e):()=>r[e]:e.bind(r,r),a;T(t)?a=t:(a=t.handler,n=t);let o=Ea(this),s=Jn(i,a.bind(r),n);return o(),s}function Xn(e,t){let n=t.split(`.`);return()=>{let t=e;for(let e=0;e<n.length&&t;e++)t=t[n[e]];return t}}var Zn=Symbol(`_vte`),Qn=e=>e.__isTeleport,$n=Symbol(`_leaveCb`);function er(e){let t=e[0];if(e.length>1){for(let n of e)if(n.type!==Zi){t=n;break}}return t}function tr(e){if(!ur(e))return Qn(e.type)&&e.children?er(e.children):e;if(e.component)return e.component.subTree;let{shapeFlag:t,children:n}=e;if(n){if(t&16)return n[0];if(t&32&&T(n.default))return n.default()}}function nr(e,t){if(e.shapeFlag&6&&e.component){e.transition=t;let n=e.component.subTree;nr(Qn(n.type)&&tr(n)||n,t)}else if(e.shapeFlag&128)e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback);else if(e.transition=t,e.type===H&&S(e.children)){let n=fi(e.children,!1);n&&nr(n,t)}}function rr(e){if(e.component)return rr(e.component.subTree);if(e.type===H){let t=S(e.children)&&fi(e.children,!1);return t?rr(t):void 0}if(e.type!==Zi)return e}function V(e,t){return T(e)?v({name:e.name},t,{setup:e}):e}function ir(e){e.ids=[e.ids[0]+e.ids[2]+++`-`,0,0]}function ar(e,t){let n;return!!((n=Object.getOwnPropertyDescriptor(e,t))&&!n.configurable)}var or=new WeakMap;function sr(e,t,n,r,i=!1){if(S(e)){e.forEach((e,a)=>sr(e,t&&(S(t)?t[a]:t),n,r,i));return}if(lr(r)&&!i){r.shapeFlag&512&&r.type.__asyncResolved&&r.component.subTree.component&&sr(e,t,n,r.component.subTree);return}let a=r.shapeFlag&4?Ia(r.component):r.el,o=i?null:a,{i:s,r:c}=e,l=t&&t.r,u=s.refs===f?s.refs={}:s.refs,d=s.setupState,p=R(d),m=d===f?h:e=>!ar(u,e)&&x(p,e),g=(e,t)=>!(t&&ar(u,t));if(l!=null&&l!==c){if(cr(t),E(l))u[l]=null,m(l)&&(d[l]=null);else if(en(l)){let e=t;g(l,e.k)&&(l.value=null),e.k&&(u[e.k]=null)}}if(T(c))hn(c,s,12,[o,u]);else{let t=E(c),r=en(c);if(t||r){let s=()=>{if(e.f){let n=t?m(c)?d[c]:u[c]:g(c)||!e.k?c.value:u[e.k];if(i)S(n)&&y(n,a);else if(S(n))n.includes(a)||n.push(a);else if(t)u[c]=[a],m(c)&&(d[c]=u[c]);else{let t=[a];g(c,e.k)&&(c.value=t),e.k&&(u[e.k]=t)}}else t?(u[c]=o,m(c)&&(d[c]=o)):r&&(g(c,e.k)&&(c.value=o),e.k&&(u[e.k]=o))};if(o){let t=()=>{s(),or.delete(e)};t.id=-1,or.set(e,t),Li(t,n)}else cr(e),s()}}}function cr(e){let t=or.get(e);t&&(t.flags|=8,or.delete(e))}pe().requestIdleCallback,pe().cancelIdleCallback;var lr=e=>!!e.type.__asyncLoader,ur=e=>e.type.__isKeepAlive;function dr(e,t){pr(e,`a`,t)}function fr(e,t){pr(e,`da`,t)}function pr(e,t,n=Sa){let r=e.__wdc||=()=>{let t=n;for(;t;){if(t.isDeactivated)return;t=t.parent}return e()};if(hr(t,r,n),n){let e=n.parent;for(;e&&e.parent;)ur(e.parent.vnode)&&mr(r,t,n,e),e=e.parent}}function mr(e,t,n,r){let i=hr(t,e,r,!0);Sr(()=>{y(r[t],i)},n)}function hr(e,t,n=Sa,r=!1){if(n){let i=n[e]||(n[e]=[]),a=t.__weh||=(...r)=>{Xe();let i=Ea(n),a=gn(t,n,e,r);return i(),Ze(),a};return r?i.unshift(a):i.push(a),a}}var gr=e=>(t,n=Sa)=>{(!ka||e===`sp`)&&hr(e,(...e)=>t(...e),n)},_r=gr(`bm`),vr=gr(`m`),yr=gr(`bu`),br=gr(`u`),xr=gr(`bum`),Sr=gr(`um`),Cr=gr(`sp`),wr=gr(`rtg`),Tr=gr(`rtc`);function Er(e,t=Sa){hr(`ec`,e,t)}var Dr=`components`;function Or(e,t){return Ar(Dr,e,!0,t)||e}var kr=Symbol.for(`v-ndc`);function Ar(e,t,n=!0,r=!1){let i=Ln||Sa;if(i){let n=i.type;if(e===Dr){let e=La(n,!1);if(e&&(e===t||e===P(t)||e===F(P(t))))return n}let a=jr(i[e]||n[e],t)||jr(i.appContext[e],t);return!a&&r?n:a}}function jr(e,t){return e&&(e[t]||e[P(t)]||e[F(P(t))])}function Mr(e,t,n,r){let i,a=n&&n[r],o=S(e);if(o||E(e)){let n=o&&qt(e),r=!1,s=!1;n&&(r=!Yt(e),s=Jt(e),e=ut(e)),i=Array(e.length);for(let n=0,o=e.length;n<o;n++)i[n]=t(r?s?$t(Qt(e[n])):Qt(e[n]):e[n],n,void 0,a&&a[n])}else if(typeof e==`number`){if(!Number.isInteger(e)||e<0)i=[];else{i=Array(e);for(let n=0;n<e;n++)i[n]=t(n+1,n,void 0,a&&a[n])}}else if(O(e)){if(e[Symbol.iterator])i=Array.from(e,(e,n)=>t(e,n,void 0,a&&a[n]));else{let n=Object.keys(e);i=Array(n.length);for(let r=0,o=n.length;r<o;r++){let o=n[r];i[r]=t(e[o],o,r,a&&a[r])}}}else i=[];return n&&(n[r]=i),i}function Nr(e,t){for(let n=0;n<t.length;n++){let r=t[n];if(S(r))for(let t=0;t<r.length;t++)e[r[t].name]=r[t].fn;else r&&(e[r.name]=r.key?(...e)=>{let t=r.fn(...e);return t&&(t.key=r.key),t}:r.fn)}return e}function Pr(e,t,n,r,i,a){if(n??={},Ln.ce||Ln.parent&&lr(Ln.parent)&&Ln.parent.ce){let e=a!=null&&n.key==null?v({},n,{key:a}):n,i=Object.keys(e).length>0;return t!=="default"&&(e.name=t),U(),G(H,null,[q(`slot`,e,r&&r())],i?-2:64)}let o=e[t];o&&o._c&&(o._d=!1);let s=$i.length;U();let c;try{let i=o&&Fr(o(n)),s=n.key||a||i&&i.key;c=G(H,{key:(s&&!D(s)?s:`_${t}`)+(!i&&r?`_fb`:``)},i||(r?r():[]),i&&e._===1?64:-2)}catch(e){for(let e=$i.length;e>s;e--)ta();throw e}finally{o&&o._c&&(o._d=!0)}return!i&&c.scopeId&&(c.slotScopeIds=[c.scopeId+`-s`]),c}function Fr(e){return e.some(e=>!aa(e)||!(e.type===Zi||e.type===H&&!Fr(e.children)))?e:null}var Ir=e=>e?Oa(e)?Ia(e):Ir(e.parent):null,Lr=v(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>Ir(e.parent),$root:e=>Ir(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>Kr(e),$forceUpdate:e=>e.f||=()=>{On(e.update)},$nextTick:e=>e.n||=En.bind(e.proxy),$watch:e=>Yn.bind(e)}),Rr=(e,t)=>e!==f&&!e.__isScriptSetup&&x(e,t),zr={get({_:e},t){if(t===`__v_skip`)return!0;let{ctx:n,setupState:r,data:i,props:a,accessCache:o,type:s,appContext:c}=e;if(t[0]!==`$`){let e=o[t];if(e!==void 0)switch(e){case 1:return r[t];case 2:return i[t];case 4:return n[t];case 3:return a[t]}else if(Rr(r,t))return o[t]=1,r[t];else if(i!==f&&x(i,t))return o[t]=2,i[t];else if(x(a,t))return o[t]=3,a[t];else if(n!==f&&x(n,t))return o[t]=4,n[t];else Vr&&(o[t]=0)}let l=Lr[t],u,d;if(l)return t===`$attrs`&&st(e.attrs,`get`,``),l(e);if((u=s.__cssModules)&&(u=u[t]))return u;if(n!==f&&x(n,t))return o[t]=4,n[t];if(d=c.config.globalProperties,x(d,t))return d[t]},set({_:e},t,n){let{data:r,setupState:i,ctx:a}=e;return Rr(i,t)?(i[t]=n,!0):r!==f&&x(r,t)?(r[t]=n,!0):x(e.props,t)||t[0]===`$`&&t.slice(1)in e?!1:(a[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:r,appContext:i,props:a,type:o}},s){let c;return!!(n[s]||e!==f&&s[0]!==`$`&&x(e,s)||Rr(t,s)||x(a,s)||x(r,s)||x(Lr,s)||x(i.config.globalProperties,s)||(c=o.__cssModules)&&c[s])},defineProperty(e,t,n){return n.get==null?x(n,`value`)&&this.set(e,t,n.value,null):e._.accessCache[t]=0,Reflect.defineProperty(e,t,n)}};function Br(e){return S(e)?e.reduce((e,t)=>(e[t]=null,e),{}):e}var Vr=!0;function Hr(e){let t=Kr(e),n=e.proxy,r=e.ctx;Vr=!1,t.beforeCreate&&Wr(t.beforeCreate,e,`bc`);let{data:i,computed:a,methods:o,watch:s,provide:c,inject:l,created:u,beforeMount:d,mounted:f,beforeUpdate:p,updated:h,activated:g,deactivated:_,beforeDestroy:v,beforeUnmount:y,destroyed:b,unmounted:x,render:C,renderTracked:w,renderTriggered:ee,errorCaptured:E,serverPrefetch:D,expose:k,inheritAttrs:te,components:A,directives:ne,filters:j}=t;if(l&&Ur(l,r,null),o)for(let e in o){let t=o[e];T(t)&&(r[e]=t.bind(n))}if(i){let t=i.call(n,n);O(t)&&(e.data=Ut(t))}if(Vr=!0,a)for(let e in a){let t=a[e],i=X({get:T(t)?t.bind(n,n):T(t.get)?t.get.bind(n,n):m,set:!T(t)&&T(t.set)?t.set.bind(n):m});Object.defineProperty(r,e,{enumerable:!0,configurable:!0,get:()=>i.value,set:e=>i.value=e})}if(s)for(let e in s)Gr(s[e],r,n,e);if(c){let e=T(c)?c.call(n):c;Reflect.ownKeys(e).forEach(t=>{Un(t,e[t])})}u&&Wr(u,e,`c`);function M(e,t){S(t)?t.forEach(t=>e(t.bind(n))):t&&e(t.bind(n))}if(M(_r,d),M(vr,f),M(yr,p),M(br,h),M(dr,g),M(fr,_),M(Er,E),M(Tr,w),M(wr,ee),M(xr,y),M(Sr,x),M(Cr,D),S(k)){if(k.length){let t=e.exposed||={};k.forEach(e=>{Object.defineProperty(t,e,{get:()=>n[e],set:t=>n[e]=t,enumerable:!0})})}else e.exposed||={}}C&&e.render===m&&(e.render=C),te!=null&&(e.inheritAttrs=te),A&&(e.components=A),ne&&(e.directives=ne),D&&ir(e)}function Ur(e,t,n=m){S(e)&&(e=Zr(e));for(let n in e){let r=e[n],i;i=O(r)?`default`in r?Wn(r.from||n,r.default,!0):Wn(r.from||n):Wn(r),en(i)?Object.defineProperty(t,n,{enumerable:!0,configurable:!0,get:()=>i.value,set:e=>i.value=e}):t[n]=i}}function Wr(e,t,n){gn(S(e)?e.map(e=>e.bind(t.proxy)):e.bind(t.proxy),t,n)}function Gr(e,t,n,r){let i=r.includes(`.`)?Xn(n,r):()=>n[r];if(E(e)){let n=t[e];T(n)&&qn(i,n)}else if(T(e))qn(i,e.bind(n));else if(O(e)){if(S(e))e.forEach(e=>Gr(e,t,n,r));else{let r=T(e.handler)?e.handler.bind(n):t[e.handler];T(r)&&qn(i,r,e)}}}function Kr(e){let t=e.type,{mixins:n,extends:r}=t,{mixins:i,optionsCache:a,config:{optionMergeStrategies:o}}=e.appContext,s=a.get(t),c;return s?c=s:!i.length&&!n&&!r?c=t:(c={},i.length&&i.forEach(e=>qr(c,e,o,!0)),qr(c,t,o)),O(t)&&a.set(t,c),c}function qr(e,t,n,r=!1){let{mixins:i,extends:a}=t;a&&qr(e,a,n,!0),i&&i.forEach(t=>qr(e,t,n,!0));for(let i in t)if(!(r&&i===`expose`)){let r=Jr[i]||n&&n[i];e[i]=r?r(e[i],t[i]):t[i]}return e}var Jr={data:Yr,props:ei,emits:ei,methods:$r,computed:$r,beforeCreate:Qr,created:Qr,beforeMount:Qr,mounted:Qr,beforeUpdate:Qr,updated:Qr,beforeDestroy:Qr,beforeUnmount:Qr,destroyed:Qr,unmounted:Qr,activated:Qr,deactivated:Qr,errorCaptured:Qr,serverPrefetch:Qr,components:$r,directives:$r,watch:ti,provide:Yr,inject:Xr};function Yr(e,t){return t?e?function(){return v(T(e)?e.call(this,this):e,T(t)?t.call(this,this):t)}:t:e}function Xr(e,t){return $r(Zr(e),Zr(t))}function Zr(e){if(S(e)){let t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function Qr(e,t){return e?[...new Set([].concat(e,t))]:t}function $r(e,t){return e?v(Object.create(null),e,t):t}function ei(e,t){return e?S(e)&&S(t)?[...new Set([...e,...t])]:v(Object.create(null),Br(e),Br(t??{})):t}function ti(e,t){if(!e)return t;if(!t)return e;let n=v(Object.create(null),e);for(let r in t)n[r]=Qr(e[r],t[r]);return n}function ni(){return{app:null,config:{isNativeTag:h,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}var ri=0;function ii(e,t){return function(n,r=null){T(n)||(n=v({},n)),r!=null&&!O(r)&&(r=null);let i=ni(),a=new WeakSet,o=[],s=!1,c=i.app={_uid:ri++,_component:n,_props:r,_container:null,_context:i,_instance:null,version:za,get config(){return i.config},set config(e){},use(e,...t){return a.has(e)||(e&&T(e.install)?(a.add(e),e.install(c,...t)):T(e)&&(a.add(e),e(c,...t))),c},mixin(e){return i.mixins.includes(e)||i.mixins.push(e),c},component(e,t){return t?(i.components[e]=t,c):i.components[e]},directive(e,t){return t?(i.directives[e]=t,c):i.directives[e]},mount(a,o,l){if(!s){let u=c._ceVNode||q(n,r);return u.appContext=i,l===!0?l=`svg`:l===!1&&(l=void 0),o&&t?t(u,a):e(u,a,l),s=!0,c._container=a,a.__vue_app__=c,Ia(u.component)}},onUnmount(e){o.push(e)},unmount(){s&&(gn(o,c._instance,16),e(null,c._container),delete c._container.__vue_app__)},provide(e,t){return i.provides[e]=t,c},runWithContext(e){let t=ai;ai=c;try{return e()}finally{ai=t}}};return c}}var ai=null,oi=(e,t)=>t===`modelValue`||t===`model-value`?e.modelModifiers:e[`${t}Modifiers`]||e[`${P(t)}Modifiers`]||e[`${oe(t)}Modifiers`];function si(e,t,...n){if(e.isUnmounted)return;let r=e.vnode.props||f,i=n,a=t.startsWith(`update:`),o=a&&oi(r,t.slice(7));o&&(o.trim&&(i=n.map(e=>E(e)?e.trim():e)),o.number&&(i=i.map(de)));let s,c=r[s=se(t)]||r[s=se(P(t))];!c&&a&&(c=r[s=se(oe(t))]),c&&gn(c,e,6,i);let l=r[s+`Once`];if(l){if(!e.emitted)e.emitted={};else if(e.emitted[s])return;e.emitted[s]=!0,gn(l,e,6,i)}}var ci=new WeakMap;function li(e,t,n=!1){let r=n?ci:t.emitsCache,i=r.get(e);if(i!==void 0)return i;let a=e.emits,o={},s=!1;if(!T(e)){let r=e=>{let n=li(e,t,!0);n&&(s=!0,v(o,n))};!n&&t.mixins.length&&t.mixins.forEach(r),e.extends&&r(e.extends),e.mixins&&e.mixins.forEach(r)}return!a&&!s?(O(e)&&r.set(e,null),null):(S(a)?a.forEach(e=>o[e]=null):v(o,a),O(e)&&r.set(e,o),o)}function ui(e,t){return!e||!g(t)?!1:(t=t.slice(2),t=t===`Once`?t:t.replace(/Once$/,``),x(e,t[0].toLowerCase()+t.slice(1))||x(e,oe(t))||x(e,t))}function di(e){let{type:t,vnode:n,proxy:r,withProxy:i,propsOptions:[a],slots:o,attrs:s,emit:c,render:l,renderCache:u,props:d,data:f,setupState:p,ctx:m,inheritAttrs:h}=e,g=zn(e),v,y;try{if(n.shapeFlag&4){let e=i||r,t=e;v=pa(l.call(t,e,u,d,p,f,m)),y=s}else{let e=t;v=pa(e.length>1?e(d,{attrs:s,slots:o,emit:c}):e(d,null)),y=t.props?s:pi(s)}}catch(t){$i.length=0,_n(t,e,1),v=q(Zi)}let b=v;if(y&&h!==!1){let e=Object.keys(y),{shapeFlag:t}=b;e.length&&t&7&&(a&&e.some(_)&&(y=mi(y,a)),b=da(b,y,!1,!0))}return n.dirs&&(b=da(b,null,!1,!0),b.dirs=b.dirs?b.dirs.concat(n.dirs):n.dirs),n.transition&&nr(Qn(b.type)&&tr(b)||b,n.transition),v=b,zn(g),v}function fi(e,t=!0){let n;for(let t=0;t<e.length;t++){let r=e[t];if(aa(r)){if(r.type!==Zi||r.children===`v-if`){if(n)return;n=r}}else return}return n}var pi=e=>{let t;for(let n in e)(n===`class`||n===`style`||g(n))&&((t||={})[n]=e[n]);return t},mi=(e,t)=>{let n={};for(let r in e)(!_(r)||!(r.slice(9)in t))&&(n[r]=e[r]);return n};function hi(e,t,n){let{props:r,children:i,component:a}=e,{props:o,children:s,patchFlag:c}=t,l=a.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&c>=0){if(c&1024)return!0;if(c&16)return r?gi(r,o,l):!!o;if(c&8){let e=t.dynamicProps;for(let t=0;t<e.length;t++){let n=e[t];if(_i(o,r,n)&&!ui(l,n))return!0}}}else return(i||s)&&(!s||!s.$stable)?!0:r===o?!1:r?!o||gi(r,o,l):!!o;return!1}function gi(e,t,n){let r=Object.keys(t);if(r.length!==Object.keys(e).length)return!0;for(let i=0;i<r.length;i++){let a=r[i];if(!x(e,a)||_i(t,e,a)&&!ui(n,a))return!0}return!1}function _i(e,t,n){let r=e[n],i=t[n];return n===`style`&&O(r)&&O(i)?!Ee(r,i):r!==i}function vi({vnode:e,parent:t,suspense:n},r){for(;t;){let n=t.subTree;if(n.suspense&&n.suspense.activeBranch===e&&(n.suspense.vnode.el=n.el=r,e=n),n===e)(e=t.vnode).el=r,t=t.parent;else break}n&&n.activeBranch===e&&(n.vnode.el=r)}var yi={},bi=()=>Object.create(yi),xi=e=>Object.getPrototypeOf(e)===yi;function Si(e,t,n,r=!1){let i={},a=bi();e.propsDefaults=Object.create(null),wi(e,t,i,a);for(let t in e.propsOptions[0])t in i||(i[t]=void 0);e.props=n?r?i:Wt(i):e.type.props?i:a,e.attrs=a}function Ci(e,t,n,r){let{props:i,attrs:a,vnode:{patchFlag:o}}=e,s=R(i),[c]=e.propsOptions,l=!1;if((r||o>0)&&!(o&16)){if(o&8){let n=e.vnode.dynamicProps;for(let r=0;r<n.length;r++){let o=n[r];if(ui(e.emitsOptions,o))continue;let u=t[o];if(c){if(x(a,o))u!==a[o]&&(a[o]=u,l=!0);else{let t=P(o);i[t]=Ti(c,s,t,u,e,!1)}}else u!==a[o]&&(a[o]=u,l=!0)}}}else{wi(e,t,i,a)&&(l=!0);let r;for(let a in s)(!t||!x(t,a)&&((r=oe(a))===a||!x(t,r)))&&(c?n&&(n[a]!==void 0||n[r]!==void 0)&&(i[a]=Ti(c,s,a,void 0,e,!0)):delete i[a]);if(a!==s)for(let e in a)(!t||!x(t,e))&&(delete a[e],l=!0)}l&&ct(e.attrs,`set`,``)}function wi(e,t,n,r){let[i,a]=e.propsOptions,o=!1,s;if(t)for(let c in t){if(N(c))continue;let l=t[c],u;i&&x(i,u=P(c))?!a||!a.includes(u)?n[u]=l:(s||={})[u]=l:ui(e.emitsOptions,c)||(!(c in r)||l!==r[c])&&(r[c]=l,o=!0)}if(a){let t=R(n),r=s||f;for(let o=0;o<a.length;o++){let s=a[o];n[s]=Ti(i,t,s,r[s],e,!x(r,s))}}return o}function Ti(e,t,n,r,i,a){let o=e[n];if(o!=null){let e=x(o,`default`);if(e&&r===void 0){let e=o.default;if(o.type!==Function&&!o.skipFactory&&T(e)){let{propsDefaults:a}=i;if(n in a)r=a[n];else{let o=Ea(i);r=a[n]=e.call(null,t),o()}}else r=e;i.ce&&i.ce._setProp(n,r)}o[0]&&(a&&!e?r=!1:o[1]&&(r===``||r===oe(n))&&(r=!0))}return r}var Ei=new WeakMap;function Di(e,t,n=!1){let r=n?Ei:t.propsCache,i=r.get(e);if(i)return i;let a=e.props,o={},s=[],c=!1;if(!T(e)){let r=e=>{c=!0;let[n,r]=Di(e,t,!0);v(o,n),r&&s.push(...r)};!n&&t.mixins.length&&t.mixins.forEach(r),e.extends&&r(e.extends),e.mixins&&e.mixins.forEach(r)}if(!a&&!c)return O(e)&&r.set(e,p),p;if(S(a))for(let e=0;e<a.length;e++){let t=P(a[e]);Oi(t)&&(o[t]=f)}else if(a)for(let e in a){let t=P(e);if(Oi(t)){let n=a[e],r=o[t]=S(n)||T(n)?{type:n}:v({},n),i=r.type,c=!1,l=!0;if(S(i))for(let e=0;e<i.length;++e){let t=i[e],n=T(t)&&t.name;if(n===`Boolean`){c=!0;break}n===`String`&&(l=!1)}else c=T(i)&&i.name===`Boolean`;r[0]=c,r[1]=l,(c||x(r,`default`))&&s.push(t)}}let l=[o,s];return O(e)&&r.set(e,l),l}function Oi(e){return e[0]!==`$`&&!N(e)}var ki=e=>e===`_`||e===`_ctx`||e===`$stable`,Ai=e=>S(e)?e.map(pa):[pa(e)],ji=(e,t,n)=>{if(t._n)return t;let r=Bn((...e)=>Ai(t(...e)),n);return r._c=!1,r},Mi=(e,t,n)=>{let r=e._ctx;for(let n in e){if(ki(n))continue;let i=e[n];if(T(i))t[n]=ji(n,i,r);else if(i!=null){let e=Ai(i);t[n]=()=>e}}},Ni=(e,t)=>{let n=Ai(t);e.slots.default=()=>n},Pi=(e,t,n)=>{for(let r in t)(n||!ki(r))&&(e[r]=t[r])},Fi=(e,t,n)=>{let r=e.slots=bi();if(e.vnode.shapeFlag&32){let e=t._;e?(Pi(r,t,n),n&&ue(r,`_`,e,!0)):Mi(t,r)}else t&&Ni(e,t)},Ii=(e,t,n)=>{let{vnode:r,slots:i}=e,a=!0,o=f;if(r.shapeFlag&32){let e=t._;e?n&&e===1?a=!1:Pi(i,t,n):(a=!t.$stable,Mi(t,i)),o=t}else t&&(Ni(e,t),o={default:1});if(a)for(let e in i)!ki(e)&&o[e]==null&&delete i[e]},Li=Yi;function Ri(e){return zi(e)}function zi(e,t){let n=pe();n.__VUE__=!0;let{insert:r,remove:i,patchProp:a,createElement:o,createText:s,createComment:c,setText:l,setElementText:u,parentNode:d,nextSibling:h,setScopeId:g=m,insertStaticContent:_}=e,v=(e,t,n,r=null,i=null,a=null,o=void 0,s=null,c=!!t.dynamicChildren)=>{if(e===t)return;e&&!oa(e,t)&&(r=fe(e),F(e,i,a,!0),e=null),t.patchFlag===-2&&(c=!1,t.dynamicChildren=null),t.dynamicChildren&&e&&e.dynamicChildren&&e.dynamicChildren.hasOnce&&(t.dynamicChildren===p&&(t.dynamicChildren=[]),t.dynamicChildren.hasOnce=!0);let{type:l,ref:u,shapeFlag:d}=t;switch(l){case Xi:y(e,t,n,r);break;case Zi:b(e,t,n,r);break;case Qi:e??x(t,n,r,o);break;case H:te(e,t,n,r,i,a,o,s,c);break;default:d&1?w(e,t,n,r,i,a,o,s,c):d&6?A(e,t,n,r,i,a,o,s,c):(d&64||d&128)&&l.process(e,t,n,r,i,a,o,s,c,he)}u!=null&&i?sr(u,e&&e.ref,a,t||e,!t):u==null&&e&&e.ref!=null&&sr(e.ref,null,a,e,!0)},y=(e,t,n,i)=>{if(e==null)r(t.el=s(t.children),n,i);else{let n=t.el=e.el;t.children!==e.children&&l(n,t.children)}},b=(e,t,n,i)=>{e==null?r(t.el=c(t.children||``),n,i):t.el=e.el},x=(e,t,n,r)=>{[e.el,e.anchor]=_(e.children,t,n,r,e.el,e.anchor)},S=({el:e,anchor:t},n,i)=>{let a;for(;e&&e!==t;)a=h(e),r(e,n,i),e=a;r(t,n,i)},C=({el:e,anchor:t})=>{let n;for(;e&&e!==t;)n=h(e),i(e),e=n;i(t)},w=(e,t,n,r,i,a,o,s,c)=>{if(t.type===`svg`?o=`svg`:t.type===`math`&&(o=`mathml`),e==null)ee(t,n,r,i,a,o,s,c);else{let n=e.el&&e.el._isVueCE?e.el:null;try{n&&n._beginPatch(),D(e,t,i,a,o,s,c)}finally{n&&n._endPatch()}}},ee=(e,t,n,i,s,c,l,d)=>{let f,p,{props:m,shapeFlag:h,transition:g,dirs:_}=e;if(f=e.el=o(e.type,c,m&&m.is,m),h&8?u(f,e.children):h&16&&E(e.children,f,null,i,s,Bi(e,c),l,d),_&&Hn(e,null,i,`created`),T(f,e,e.scopeId,l,i),m){for(let e in m)e!==`value`&&!N(e)&&a(f,e,null,m[e],c,i);`value`in m&&a(f,`value`,null,m.value,c),(p=m.onVnodeBeforeMount)&&_a(p,i,e)}_&&Hn(e,null,i,`beforeMount`);let v=Hi(s,g);v&&g.beforeEnter(f),r(f,t,n),((p=m&&m.onVnodeMounted)||v||_)&&Li(()=>{try{p&&_a(p,i,e),v&&g.enter(f),_&&Hn(e,null,i,`mounted`)}finally{}},s)},T=(e,t,n,r,i)=>{if(n&&g(e,n),r)for(let t=0;t<r.length;t++)g(e,r[t]);if(i){let n=i.subTree;if(t===n||Ji(n.type)&&(n.ssContent===t||n.ssFallback===t)){let t=i.vnode;T(e,t,t.scopeId,t.slotScopeIds,i.parent)}}},E=(e,t,n,r,i,a,o,s,c=0)=>{for(let l=c;l<e.length;l++){let c=e[l]=s?ma(e[l]):pa(e[l]);v(null,c,t,n,r,i,a,o,s)}},D=(e,t,n,r,i,o,s)=>{let c=t.el=e.el,{patchFlag:l,dynamicChildren:d,dirs:p}=t;l|=e.patchFlag&16;let m=e.props||f,h=t.props||f,g;if(n&&Vi(n,!1),(g=h.onVnodeBeforeUpdate)&&_a(g,n,t,e),p&&Hn(t,e,n,`beforeUpdate`),n&&Vi(n,!0),d&&(!e.dynamicChildren||e.dynamicChildren.length!==d.length)&&(l=0,s=!1,d=null),(m.innerHTML&&h.innerHTML==null||m.textContent&&h.textContent==null)&&u(c,``),d?O(e.dynamicChildren,d,c,n,r,Bi(t,i),o):s||ie(e,t,c,null,n,r,Bi(t,i),o,!1),l>0){if(l&16)k(c,m,h,n,i);else if(l&2&&m.class!==h.class&&a(c,`class`,null,h.class,i),l&4&&a(c,`style`,m.style,h.style,i),l&8){let e=t.dynamicProps;for(let t=0;t<e.length;t++){let r=e[t],o=m[r],s=h[r];(s!==o||r===`value`)&&a(c,r,o,s,i,n)}}l&1&&e.children!==t.children&&u(c,t.children)}else!s&&d==null&&k(c,m,h,n,i);((g=h.onVnodeUpdated)||p)&&Li(()=>{g&&_a(g,n,t,e),p&&Hn(t,e,n,`updated`)},r)},O=(e,t,n,r,i,a,o)=>{for(let s=0;s<t.length;s++){let c=e[s],l=t[s],u=c.el||qi(c),f=u&&(c.type===H||!oa(c,l)||c.shapeFlag&198)?d(u):n;v(c,l,f,null,r,i,a,o,!0)}},k=(e,t,n,r,i)=>{if(t!==n){if(t!==f)for(let o in t)!N(o)&&!(o in n)&&a(e,o,t[o],null,i,r);for(let o in n){if(N(o))continue;let s=n[o],c=t[o];s!==c&&o!==`value`&&a(e,o,c,s,i,r)}`value`in n&&a(e,`value`,t.value,n.value,i)}},te=(e,t,n,i,a,o,c,l,u)=>{let d=t.el=e?e.el:s(``),f=t.anchor=e?e.anchor:s(``),{patchFlag:p,dynamicChildren:m,slotScopeIds:h}=t;h&&(l=l?l.concat(h):h),e==null?(r(d,n,i),r(f,n,i),E(t.children||[],n,f,a,o,c,l,u)):p>0&&p&64&&m&&e.dynamicChildren&&e.dynamicChildren.length===m.length?(O(e.dynamicChildren,m,n,a,o,c,l),(t.key!=null||a&&t===a.subTree)&&Ui(e,t,!0)):ie(e,t,n,f,a,o,c,l,u)},A=(e,t,n,r,i,a,o,s,c)=>{t.slotScopeIds=s,e==null?t.shapeFlag&512?i.ctx.activate(t,n,r,o,c):ne(t,n,r,i,a,o,c):j(e,t,c)},ne=(e,t,n,r,i,a,o)=>{let s=e.component=xa(e,r,i);if(ur(e)&&(s.ctx.renderer=he),Aa(s,!1,o),s.asyncDep){if(i&&i.registerDep(s,M,o,a),!e.el){let r=s.subTree=q(Zi);b(null,r,t,n),e.placeholder=r.el}}else M(s,e,t,n,i,a,o)},j=(e,t,n)=>{let r=t.component=e.component;if(hi(e,t,n)){if(r.asyncDep&&!r.asyncResolved){t.el=e.el,t.placeholder=e.placeholder,re(r,t,n);return}r.next=t,r.update()}else t.el=e.el,t.placeholder=e.placeholder,r.vnode=t},M=(e,t,n,r,i,a,o)=>{let s=()=>{if(e.isMounted){let{next:t,bu:n,u:r,parent:s,vnode:c}=e;{let n=Gi(e);if(n){t&&(t.el=c.el,re(e,t,o)),n.asyncDep.then(()=>{Li(()=>{e.isUnmounted||l()},i)});return}}let u=t,f;Vi(e,!1),t?(t.el=c.el,re(e,t,o)):t=c,n&&le(n),(f=t.props&&t.props.onVnodeBeforeUpdate)&&_a(f,s,t,c),Vi(e,!0);let p=di(e),m=e.subTree;e.subTree=p,v(m,p,d(m.el),fe(m),e,i,a),t.el=p.el,u===null&&vi(e,p.el),r&&Li(r,i),(f=t.props&&t.props.onVnodeUpdated)&&Li(()=>_a(f,s,t,c),i)}else{let o,{el:s,props:c}=t,{bm:l,m:u,parent:d,root:f,type:p}=e,m=lr(t);if(Vi(e,!1),l&&le(l),!m&&(o=c&&c.onVnodeBeforeMount)&&_a(o,d,t),Vi(e,!0),s&&_e){let t=()=>{e.subTree=di(e),_e(s,e.subTree,e,i,null)};m&&p.__asyncHydrate?p.__asyncHydrate(s,e,t):t()}else{f.ce&&f.ce._hasShadowRoot()&&f.ce._injectChildStyle(p,e.parent?e.parent.type:void 0);let o=e.subTree=di(e);v(null,o,n,r,e,i,a),t.el=o.el}if(u&&Li(u,i),!m&&(o=c&&c.onVnodeMounted)){let e=t;Li(()=>_a(o,d,e),i)}(t.shapeFlag&256||d&&lr(d.vnode)&&d.vnode.shapeFlag&256)&&e.a&&Li(e.a,i),e.isMounted=!0,t=n=r=null}};e.scope.on();let c=e.effect=new Fe(s);e.scope.off();let l=e.update=c.run.bind(c),u=e.job=c.runIfDirty.bind(c);u.i=e,u.id=e.uid,c.scheduler=()=>On(u),Vi(e,!0),l()},re=(e,t,n)=>{t.component=e;let r=e.vnode.props;e.vnode=t,e.next=null,Ci(e,t.props,r,n),Ii(e,t.children,n),Xe(),jn(e),Ze()},ie=(e,t,n,r,i,a,o,s,c=!1)=>{let l=e&&e.children,d=e?e.shapeFlag:0,f=t.children,{patchFlag:p,shapeFlag:m}=t;if(p>0){if(p&128){ae(l,f,n,r,i,a,o,s,c);return}if(p&256){P(l,f,n,r,i,a,o,s,c);return}}m&8?(d&16&&de(l,i,a),f!==l&&u(n,f)):d&16?m&16?ae(l,f,n,r,i,a,o,s,c):de(l,i,a,!0):(d&8&&u(n,``),m&16&&E(f,n,r,i,a,o,s,c))},P=(e,t,n,r,i,a,o,s,c)=>{e||=p,t||=p;let l=e.length,u=t.length,d=Math.min(l,u),f=0;for(;f<d;f++){let r=t[f]=c?ma(t[f]):pa(t[f]);v(e[f],r,n,null,i,a,o,s,c)}l>u?de(e,i,a,!0,!1,d):E(t,n,r,i,a,o,s,c,d)},ae=(e,t,n,r,i,a,o,s,c)=>{let l=0,u=t.length,d=e.length-1,f=u-1;for(;l<=d&&l<=f;){let r=e[l],u=t[l]=c?ma(t[l]):pa(t[l]);if(oa(r,u))v(r,u,n,null,i,a,o,s,c);else break;l++}for(;l<=d&&l<=f;){let r=e[d],l=t[f]=c?ma(t[f]):pa(t[f]);if(oa(r,l))v(r,l,n,null,i,a,o,s,c);else break;d--,f--}if(l>d){if(l<=f){let e=f+1,d=e<u?t[e].el:r;for(;l<=f;)v(null,t[l]=c?ma(t[l]):pa(t[l]),n,d,i,a,o,s,c),l++}}else if(l>f)for(;l<=d;)F(e[l],i,a,!0),l++;else{let m=l,h=l,g=new Map;for(l=h;l<=f;l++){let e=t[l]=c?ma(t[l]):pa(t[l]);e.key!=null&&g.set(e.key,l)}let _,y=0,b=f-h+1,x=!1,S=0,C=Array(b);for(l=0;l<b;l++)C[l]=0;for(l=m;l<=d;l++){let r=e[l];if(y>=b){F(r,i,a,!0);continue}let u;if(r.key!=null)u=g.get(r.key);else for(_=h;_<=f;_++)if(C[_-h]===0&&oa(r,t[_])){u=_;break}u===void 0?F(r,i,a,!0):(C[u-h]=l+1,u>=S?S=u:x=!0,v(r,t[u],n,null,i,a,o,s,c),y++)}let w=x?Wi(C):p;for(_=w.length-1,l=b-1;l>=0;l--){let e=h+l,d=t[e],f=t[e+1],p=e+1<u?f.el||qi(f):r;C[l]===0?v(null,d,n,p,i,a,o,s,c):x&&(_<0||l!==w[_]?oe(d,n,p,2):_--)}}},oe=(e,t,n,a,o=null)=>{let{el:s,type:c,transition:l,children:u,shapeFlag:d}=e;if(d&6)oe(e.component.subTree,t,n,a);else if(d&128)e.suspense.move(t,n,a);else if(d&64)c.move(e,t,n,he);else if(c===H){r(s,t,n);for(let e=0;e<u.length;e++)oe(u[e],t,n,a);r(e.anchor,t,n)}else if(c===Qi)S(e,t,n);else if(a!==2&&d&1&&l){if(a===0)l.persisted&&!s[$n]?r(s,t,n):(l.beforeEnter(s),r(s,t,n),Li(()=>l.enter(s),o));else{let{leave:a,delayLeave:o,afterLeave:c}=l,u=()=>{e.ctx.isUnmounted?i(s):r(s,t,n)},d=()=>{let e=s._isLeaving||!!s[$n];s._isLeaving&&s[$n](!0),l.persisted&&!e?u():a(s,()=>{u(),c&&c()})};o?o(s,u,d):d()}}else r(s,t,n)},F=(e,t,n,r=!1,i=!1)=>{let{type:a,props:o,ref:s,children:c,dynamicChildren:l,shapeFlag:u,patchFlag:d,dirs:f,cacheIndex:p,memo:m}=e;if((d===-2||l&&l.hasOnce)&&(i=!1),s!=null&&(Xe(),sr(s,null,n,e,!0),Ze()),p!=null&&(!e.ctx||e.ctx===t)&&(t.renderCache[p]=void 0),u&256){t.ctx.deactivate(e);return}let h=u&1&&f,g=!lr(e),_;if(g&&(_=o&&o.onVnodeBeforeUnmount)&&_a(_,t,e),u&6)ue(e.component,n,r);else{if(u&128){e.suspense.unmount(n,r);return}h&&Hn(e,null,t,`beforeUnmount`),u&64?e.type.remove(e,t,n,he,r):l&&!l.hasOnce&&(a!==H||d>0&&d&64)?de(l,t,n,!1,!0):(a===H&&d&384||!i&&u&16)&&de(c,t,n),r&&se(e)}let v=m!=null&&p==null;(g&&(_=o&&o.onVnodeUnmounted)||h||v)&&Li(()=>{_&&_a(_,t,e),h&&Hn(e,null,t,`unmounted`),v&&(e.el=null)},n)},se=e=>{let{type:t,el:n,anchor:r,transition:a}=e,o=t===H;if(o&&!a){ce(n,r);return}if(t===Qi){C(e),a&&!a.persisted&&a.afterLeave&&a.afterLeave();return}let s=o?rr(e):e,c=()=>{o?d(n)&&ce(n,r):i(n),a&&!a.persisted&&a.afterLeave&&a.afterLeave()};if(s&&s.shapeFlag&1&&a&&!a.persisted){let{leave:e,delayLeave:t}=a,n=s.el,r=()=>e(n,c);t?t(n,c,r):r()}else c()},ce=(e,t)=>{let n;for(;e!==t;)n=h(e),i(e),e=n;i(t)},ue=(e,t,n)=>{let{bum:r,scope:i,job:a,subTree:o,um:s,m:c,a:l}=e;Ki(c),Ki(l),r&&le(r),i.stop(),a?(a.flags|=8,F(o,e,t,n)):e.vnode.el&&o&&(o.transition=e.vnode.transition,F(o,e,t,n)),s&&Li(s,t),Li(()=>{e.isUnmounted=!0},t)},de=(e,t,n,r=!1,i=!1,a=0)=>{for(let o=a;o<e.length;o++)F(e[o],t,n,r,i)},fe=e=>{if(e.shapeFlag&6)return fe(e.component.subTree);if(e.shapeFlag&128)return e.suspense.next();let t=h(e.anchor||e.el),n=t&&t[Zn];return n?h(n):t},me=(e,t,n)=>{Pn(()=>{e==null?t._vnode&&F(t._vnode,null,null,!0):v(t._vnode||null,e,t,null,null,null,n),t._vnode=e},e&&t._vnode?void 0:e&&e.component?e.component.uid:ba())},he={p:v,um:F,m:oe,r:se,mt:ne,mc:E,pc:ie,pbc:O,n:fe,o:e},ge,_e;return t&&([ge,_e]=t(he)),{render:me,hydrate:ge,createApp:ii(me,ge)}}function Bi({type:e,props:t},n){return n===`svg`&&e===`foreignObject`||n===`mathml`&&e===`annotation-xml`&&t&&t.encoding&&t.encoding.includes(`html`)?void 0:n}function Vi({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function Hi(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function Ui(e,t,n=!1){let r=e.children,i=t.children;if(S(r)&&S(i))for(let e=0;e<r.length;e++){let t=r[e],a=i[e];a.shapeFlag&1&&!a.dynamicChildren&&((a.patchFlag<=0||a.patchFlag===32)&&(a=i[e]=ma(i[e]),a.el=t.el),!n&&a.patchFlag!==-2&&Ui(t,a)),a.type===Xi&&(a.patchFlag===-1&&(a=i[e]=ma(a)),a.el=t.el),a.type===Zi&&!a.el&&(a.el=t.el)}}function Wi(e){let t=e.slice(),n=[0],r,i,a,o,s,c=e.length;for(r=0;r<c;r++){let c=e[r];if(c!==0){if(i=n[n.length-1],e[i]<c){t[r]=i,n.push(r);continue}for(a=0,o=n.length-1;a<o;)s=a+o>>1,e[n[s]]<c?a=s+1:o=s;c<e[n[a]]&&(a>0&&(t[r]=n[a-1]),n[a]=r)}}for(a=n.length,o=n[a-1];a-->0;)n[a]=o,o=t[o];return n}function Gi(e){let t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:Gi(t)}function Ki(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}function qi(e){if(e.placeholder)return e.placeholder;let t=e.component;return t?qi(t.subTree):null}var Ji=e=>e.__isSuspense;function Yi(e,t){t&&t.pendingBranch?S(e)?t.effects.push(...e):t.effects.push(e):An(e)}var H=Symbol.for(`v-fgt`),Xi=Symbol.for(`v-txt`),Zi=Symbol.for(`v-cmt`),Qi=Symbol.for(`v-stc`),$i=[],ea=null;function U(e=!1){$i.push(ea=e?null:[])}function ta(){$i.pop(),ea=$i[$i.length-1]||null}var na=1;function ra(e,t=!1){na+=e,e<0&&ea&&t&&(ea.hasOnce=!0)}function ia(e){return e.dynamicChildren=na>0?ea||p:null,ta(),na>0&&ea&&ea.push(e),e}function W(e,t,n,r,i,a){return ia(K(e,t,n,r,i,a,!0))}function G(e,t,n,r,i){return ia(q(e,t,n,r,i,!0))}function aa(e){return e?e.__v_isVNode===!0:!1}function oa(e,t){return e.type===t.type&&e.key===t.key}var sa=({key:e})=>e??null,ca=({ref:e,ref_key:t,ref_for:n})=>(typeof e==`number`&&(e=``+e),e==null?null:E(e)||en(e)||T(e)?{i:Ln,r:e,k:t,f:!!n}:e);function K(e,t=null,n=null,r=0,i=null,a=e===H?0:1,o=!1,s=!1){let c={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&sa(t),ref:t&&ca(t),scopeId:Rn,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:a,patchFlag:r,dynamicProps:i,dynamicChildren:null,appContext:null,ctx:Ln};return s?(ha(c,n),a&128&&e.normalize(c)):n&&(c.shapeFlag|=E(n)?8:16),na>0&&!o&&ea&&(c.patchFlag>0||a&6)&&c.patchFlag!==32&&ea.push(c),c}var q=la;function la(e,t=null,n=null,r=0,i=null,a=!1){if((!e||e===kr)&&(e=Zi),aa(e)){let r=da(e,t,!0);return n&&ha(r,n),na>0&&!a&&ea&&(r.shapeFlag&6?ea[ea.indexOf(e)]=r:ea.push(r)),r.patchFlag=-2,r}if(Ra(e)&&(e=e.__vccOpts),t){t=ua(t);let{class:e,style:n}=t;e&&!E(e)&&(t.class=ye(e)),O(n)&&(Xt(n)&&!S(n)&&(n=v({},n)),t.style=me(n))}let o=E(e)?1:Ji(e)?128:Qn(e)?64:O(e)?4:T(e)?2:0;return K(e,t,n,r,i,o,a,!0)}function ua(e){return e?Xt(e)||xi(e)?v({},e):e:null}function da(e,t,n=!1,r=!1){let{props:i,ref:a,patchFlag:o,children:s,transition:c}=e,l=t?ga(i||{},t):i,u={__v_isVNode:!0,__v_skip:!0,type:e.type,props:l,key:l&&sa(l),ref:t&&t.ref?n&&a?S(a)?a.concat(ca(t)):[a,ca(t)]:ca(t):a,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:s,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==H?o===-1?16:o|16:o,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:c,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&da(e.ssContent),ssFallback:e.ssFallback&&da(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce,cacheIndex:e.cacheIndex};return c&&r&&nr(u,c.clone(u)),u}function J(e=` `,t=0){return q(Xi,null,e,t)}function fa(e,t){let n=q(Qi,null,e);return n.staticCount=t,n}function Y(e=``,t=!1){return t?(U(),G(Zi,null,e)):q(Zi,null,e)}function pa(e){return e==null||typeof e==`boolean`?q(Zi):S(e)?q(H,null,e.slice()):aa(e)?ma(e):q(Xi,null,String(e))}function ma(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:da(e)}function ha(e,t){let n=0,{shapeFlag:r}=e;if(t==null)t=null;else if(S(t))n=16;else if(typeof t==`object`){if(r&65){let n=t.default;n&&(n._c&&(n._d=!1),ha(e,n()),n._c&&(n._d=!0));return}{n=32;let r=t._;!r&&!xi(t)?t._ctx=Ln:r===3&&Ln&&(Ln.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}}else if(T(t)){if(r&65){ha(e,{default:t});return}t={default:t,_ctx:Ln},n=32}else t=String(t),r&64?(n=16,t=[J(t)]):n=8;e.children=t,e.shapeFlag|=n}function ga(...e){let t={};for(let n=0;n<e.length;n++){let r=e[n];for(let e in r)if(e===`class`)t.class!==r.class&&(t.class=ye([t.class,r.class]));else if(e===`style`)t.style=me([t.style,r.style]);else if(g(e)){let n=t[e],i=r[e];i&&n!==i&&!(S(n)&&n.includes(i))?t[e]=n?[].concat(n,i):i:i==null&&n==null&&!_(e)&&(t[e]=i)}else e!==``&&(t[e]=r[e])}return t}function _a(e,t,n,r=null){gn(e,t,7,[n,r])}var va=ni(),ya=0;function ba(){return ya}function xa(e,t,n){let r=e.type,i=(t?t.appContext:e.appContext)||va,a={uid:ya++,vnode:e,type:r,parent:t,appContext:i,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new Me(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(i.provides),ids:t?t.ids:[``,0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:Di(r,i),emitsOptions:li(r,i),emit:null,emitted:null,propsDefaults:f,inheritAttrs:r.inheritAttrs,ctx:f,data:f,props:f,attrs:f,slots:f,refs:f,setupState:f,setupContext:null,suspense:n,suspenseId:n?n.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return a.ctx={_:a},a.root=t?t.root:a,a.emit=si.bind(null,a),e.ce&&e.ce(a),a}var Sa=null,Ca=()=>Sa||Ln,wa,Ta;{let e=pe(),t=(t,n)=>{let r;return(r=e[t])||(r=e[t]=[]),r.push(n),e=>{r.length>1?r.forEach(t=>t(e)):r[0](e)}};wa=t(`__VUE_INSTANCE_SETTERS__`,e=>Sa=e),Ta=t(`__VUE_SSR_SETTERS__`,e=>ka=e)}var Ea=e=>{let t=Sa;return wa(e),e.scope.on(),()=>{e.scope.off(),wa(t)}},Da=()=>{Sa&&Sa.scope.off(),wa(null)};function Oa(e){return e.vnode.shapeFlag&4}var ka=!1;function Aa(e,t=!1,n=!1){t&&Ta(t);let{props:r,children:i}=e.vnode,a=Oa(e);Si(e,r,a,t),Fi(e,i,n||t);let o=a?ja(e,t):void 0;return t&&Ta(!1),o}function ja(e,t){let n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,zr);let{setup:r}=n;if(r){Xe();let n=e.setupContext=r.length>1?Fa(e):null,i=Ea(e),a=hn(r,e,0,[e.props,n]),o=k(a);if(Ze(),i(),(o||e.sp)&&!lr(e)&&ir(e),o){if(a.then(Da,Da),t)return a.then(n=>{Ta(!0);try{Ma(e,n,t)}finally{Ta(!1)}}).catch(t=>{_n(t,e,0)});e.asyncDep=a}else Ma(e,a,t)}else Na(e,t)}function Ma(e,t,n){T(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:O(t)&&(e.setupState=on(t)),Na(e,n)}function Na(e,t,n){let r=e.type;e.render||=r.render||m;{let t=Ea(e);Xe();try{Hr(e)}finally{Ze(),t()}}}var Pa={get(e,t){return st(e,`get`,``),e[t]}};function Fa(e){return{attrs:new Proxy(e.attrs,Pa),slots:e.slots,emit:e.emit,expose:t=>{e.exposed=t||{}}}}function Ia(e){return e.exposed?e.exposeProxy||=new Proxy(on(Zt(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in Lr)return Lr[n](e)},has(e,t){return t in e||t in Lr}}):e.proxy}function La(e,t=!0){return T(e)?e.displayName||e.name:e.name||t&&e.__name}function Ra(e){return T(e)&&`__vccOpts`in e}var X=(e,t)=>cn(e,t,ka),za=`3.5.44`,Ba=void 0,Va=typeof window<`u`&&window.trustedTypes;if(Va)try{Ba=Va.createPolicy(`vue`,{createHTML:e=>e})}catch{}var Ha=Ba?e=>Ba.createHTML(e):e=>e,Ua=`http://www.w3.org/2000/svg`,Wa=`http://www.w3.org/1998/Math/MathML`,Ga=typeof document<`u`?document:null,Ka=Ga&&Ga.createElement(`template`),qa={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{let t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,r)=>{let i=t===`svg`?Ga.createElementNS(Ua,e):t===`mathml`?Ga.createElementNS(Wa,e):n?Ga.createElement(e,{is:n}):Ga.createElement(e);return e===`select`&&r&&r.multiple!=null&&i.setAttribute(`multiple`,r.multiple),i},createText:e=>Ga.createTextNode(e),createComment:e=>Ga.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Ga.querySelector(e),setScopeId(e,t){e.setAttribute(t,``)},insertStaticContent(e,t,n,r,i,a){let o=n?n.previousSibling:t.lastChild;if(i&&(i===a||i.nextSibling))for(;t.insertBefore(i.cloneNode(!0),n),i!==a&&(i=i.nextSibling););else{Ka.innerHTML=Ha(r===`svg`?`<svg>${e}</svg>`:r===`mathml`?`<math>${e}</math>`:e);let i=Ka.content;if(r===`svg`||r===`mathml`){let e=i.firstChild;for(;e.firstChild;)i.appendChild(e.firstChild);i.removeChild(e)}t.insertBefore(i,n)}return[o?o.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},Ja=Symbol(`_vtc`);function Ya(e,t,n){let r=e[Ja];r&&(t=(t?[t,...r]:[...r]).join(` `)),t==null?e.removeAttribute(`class`):n?e.setAttribute(`class`,t):e.className=t}var Xa=Symbol(`_vod`),Za=Symbol(`_vsh`),Qa=Symbol(``),$a=/(?:^|;)\s*display\s*:/;function eo(e,t,n){let r=e.style,i=E(n),a=!1;if(n&&!i){if(t){if(E(t))for(let e of t.split(`;`)){let t=e.slice(0,e.indexOf(`:`)).trim();n[t]??no(r,t,``)}else for(let e in t)n[e]??no(r,e,``)}for(let i in n){i===`display`&&(a=!0);let o=n[i];o==null?no(r,i,``):oo(e,i,!E(t)&&t?t[i]:void 0,o)||no(r,i,o)}}else if(i){if(t!==n){let e=r[Qa];e&&(n+=`;`+e),r.cssText=n,a=$a.test(n)}}else t&&e.removeAttribute(`style`);Xa in e&&((!i||t!==n)&&(e[Xa]=a?r.display:``),e[Za]&&(r.display=`none`))}var to=/\s*!important$/;function no(e,t,n){if(S(n))n.forEach(n=>no(e,t,n));else if(n??=``,t.startsWith(`--`))to.test(n)?e.setProperty(t,n.replace(to,``),`important`):e.setProperty(t,n);else{let r=ao(e,t);to.test(n)?e.setProperty(oe(r),n.replace(to,``),`important`):e[r]=n}}var ro=[`Webkit`,`Moz`,`ms`],io={};function ao(e,t){let n=io[t];if(n)return n;let r=P(t);if(r!==`filter`&&r in e)return io[t]=r;r=F(r);for(let n=0;n<ro.length;n++){let i=ro[n]+r;if(i in e)return io[t]=i}return t}function oo(e,t,n,r){return e.tagName===`TEXTAREA`&&(t===`width`||t===`height`)&&E(r)&&n===r}var so=`http://www.w3.org/1999/xlink`;function co(e,t,n,r,i,a=be(t)){r&&t.startsWith(`xlink:`)?n==null?e.removeAttributeNS(so,t.slice(6,t.length)):e.setAttributeNS(so,t,n):n==null||a&&!xe(n)?e.removeAttribute(t):e.setAttribute(t,a?``:D(n)?String(n):n)}function lo(e,t,n,r,i){if(t===`innerHTML`||t===`textContent`){n!=null&&(e[t]=t===`innerHTML`?Ha(n):n);return}let a=e.tagName;if(t===`value`&&a!==`PROGRESS`&&!a.includes(`-`)){let r=a===`OPTION`?e.getAttribute(`value`)||``:e.value,i=n==null?e.type===`checkbox`?`on`:``:String(n);(r!==i||!(`_value`in e))&&(e.value=i),n??e.removeAttribute(t),e._value=n;return}let o=!1;if(n===``||n==null){let r=typeof e[t];r===`boolean`?n=xe(n):n==null&&r===`string`?(n=``,o=!0):r===`number`&&(n=0,o=!0)}try{e[t]=n}catch{}o&&e.removeAttribute(i||t)}function uo(e,t,n,r){e.addEventListener(t,n,r)}function fo(e,t,n,r){e.removeEventListener(t,n,r)}var po=Symbol(`_vei`);function mo(e,t,n,r,i=null){let a=e[po]||(e[po]={}),o=a[t];if(r&&o)o.value=r;else{let[n,s]=_o(t);r?uo(e,n,a[t]=xo(r,i),s):o&&(fo(e,n,o,s),a[t]=void 0)}}var ho=/(Once|Passive|Capture)$/,go=/^on:?(?:Once|Passive|Capture)$/;function _o(e){let t,n;for(;(n=e.match(ho))&&!go.test(e);)t||={},e=e.slice(0,e.length-n[1].length),t[n[1].toLowerCase()]=!0;return[e[2]===`:`?e.slice(3):oe(e.slice(2)),t]}var vo=0,yo=Promise.resolve(),bo=()=>vo||=(yo.then(()=>vo=0),Date.now());function xo(e,t){let n=e=>{if(!e._vts)e._vts=Date.now();else if(e._vts<=n.attached)return;let r=n.value;if(S(r)){let n=e.stopImmediatePropagation;e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0};let i=r.slice(),a=[e];for(let n=0;n<i.length&&!e._stopped;n++){let e=i[n];e&&gn(e,t,5,a)}}else gn(r,t,5,[e])};return n.value=e,n.attached=bo(),n}var So=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,Co=(e,t,n,r,i,a)=>{let o=i===`svg`;t===`class`?Ya(e,r,o):t===`style`?eo(e,n,r):g(t)?_(t)||mo(e,t,n,r,a):(t[0]===`.`?(t=t.slice(1),1):t[0]===`^`?(t=t.slice(1),0):wo(e,t,r,o))?(lo(e,t,r),!e.tagName.includes(`-`)&&(t===`value`||t===`checked`||t===`selected`)&&co(e,t,r,o,a,t!==`value`)):e._isVueCE&&(To(e,t)||e._def.__asyncLoader&&(/[A-Z]/.test(t)||!E(r)))?lo(e,P(t),r,a,t):(t===`true-value`?e._trueValue=r:t===`false-value`&&(e._falseValue=r),co(e,t,r,o))};function wo(e,t,n,r){if(r)return!!(t===`innerHTML`||t===`textContent`||t in e&&So(t)&&T(n));if(t===`spellcheck`||t===`draggable`||t===`translate`||t===`autocorrect`||t===`sandbox`&&e.tagName===`IFRAME`||t===`form`||t===`list`&&e.tagName===`INPUT`||t===`type`&&e.tagName===`TEXTAREA`)return!1;if(t===`width`||t===`height`){let t=e.tagName;if(t===`IMG`||t===`VIDEO`||t===`CANVAS`||t===`SOURCE`)return!1}return So(t)&&E(n)?!1:t in e}function To(e,t){let n=e._def.props;if(!n)return!1;let r=P(t);return Array.isArray(n)?n.some(e=>P(e)===r):Object.keys(n).some(e=>P(e)===r)}var Eo=e=>{let t=e.props[`onUpdate:modelValue`]||!1;return S(t)?e=>le(t,e):t};function Do(e){e.target.composing=!0}function Oo(e){let t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event(`input`)))}var ko=Symbol(`_assign`),Ao=Symbol(`_initialValue`);function jo(e,t,n){return t&&(e=e.trim()),n&&(e=de(e)),e}var Mo={created(e,{modifiers:{lazy:t,trim:n,number:r}},i){e.parentNode&&(e.type===`text`?e[Ao]=e.defaultValue.replace(/[\r\n]/g,``):e.type===`textarea`&&(e[Ao]=e.defaultValue.replace(/\r\n?/g,`
3
3
  `))),e[ko]=Eo(i);let a=r||i.props&&i.props.type===`number`;uo(e,t?`change`:`input`,t=>{t.target.composing||e[ko](jo(e.value,n,a))}),(n||a)&&uo(e,`change`,()=>{e.value=jo(e.value,n,a)}),t||(uo(e,`compositionstart`,Do),uo(e,`compositionend`,Oo),uo(e,`change`,Oo))},mounted(e,{value:t,modifiers:{trim:n,number:r}}){let i=t??``,a=e[Ao];delete e[Ao],a!==void 0&&(e.type===`text`||e.type===`textarea`)&&e.value!==a?e[ko](jo(e.value,n,r)):e.value=i},beforeUpdate(e,{value:t,oldValue:n,modifiers:{lazy:r,trim:i,number:a}},o){if(e[ko]=Eo(o),e.composing)return;let s=(a||e.type===`number`)&&!/^0\d/.test(e.value)?de(e.value):e.value,c=t??``;if(s===c)return;let l=e.getRootNode();(l instanceof Document||l instanceof ShadowRoot)&&l.activeElement===e&&e.type!==`range`&&(r&&t===n||i&&e.value.trim()===c)||(e.value=c)}},No={deep:!0,created(e,t,n){e[ko]=Eo(n),uo(e,`change`,()=>{let t=e._modelValue,n=Fo(e),r=e.checked,i=e[ko];if(S(t)){let e=De(t,n),a=e!==-1;if(r&&!a)i(t.concat(n));else if(!r&&a){let n=[...t];n.splice(e,1),i(n)}}else if(w(t)){let e=new Set(t);r?e.add(n):e.delete(n),i(e)}else i(Io(e,r))})},mounted:Po,beforeUpdate(e,t,n){e[ko]=Eo(n),Po(e,t,n)}};function Po(e,{value:t,oldValue:n},r){e._modelValue=t;let i;if(S(t))i=De(t,r.props.value)>-1;else if(w(t))i=t.has(r.props.value);else{if(t===n)return;i=Ee(t,Io(e,!0))}e.checked!==i&&(e.checked=i)}function Fo(e){return`_value`in e?e._value:e.value}function Io(e,t){let n=t?`_trueValue`:`_falseValue`;return n in e?e[n]:t}var Lo=[`ctrl`,`shift`,`alt`,`meta`],Ro={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>`button`in e&&e.button!==0,middle:e=>`button`in e&&e.button!==1,right:e=>`button`in e&&e.button!==2,exact:(e,t)=>Lo.some(n=>e[`${n}Key`]&&!t.includes(n))},zo=(e,t)=>{if(!e)return e;let n=e._withMods||={},r=t.join(`.`);return n[r]||(n[r]=((n,...r)=>{for(let e=0;e<t.length;e++){let r=Ro[t[e]];if(r&&r(n,t))return}return e(n,...r)}))},Bo=v({patchProp:Co},qa),Vo;function Ho(){return Vo||=Ri(Bo)}var Uo=((...e)=>{let t=Ho().createApp(...e),{mount:n}=t;return t.mount=e=>{let r=Go(e);if(!r)return;let i=t._component;!T(i)&&!i.render&&!i.template&&(i.template=r.innerHTML),r.nodeType===1&&(r.textContent=``);let a=n(r,!1,Wo(r));return r instanceof Element&&(r.removeAttribute(`v-cloak`),r.setAttribute(`data-v-app`,``)),a},t});function Wo(e){if(e instanceof SVGElement)return`svg`;if(typeof MathMLElement==`function`&&e instanceof MathMLElement)return`mathml`}function Go(e){return E(e)?document.querySelector(e):e}var Ko={mode:`read`,includeQuotes:!0,showFiles:!0,showComments:!0,boca:!1};function qo(e){let t={};try{t=JSON.parse(e??`{}`)??{}}catch{}let n=e=>typeof t[e]==`boolean`?t[e]:Ko[e];return{mode:t.mode===`source`?`source`:`read`,includeQuotes:n(`includeQuotes`),showFiles:n(`showFiles`),showComments:n(`showComments`),boca:n(`boca`)}}function Jo(e){return`mdifit:v1:${e}`}function Yo(){return{comments:[],read:{}}}function Xo(e){if(!e)return Yo();try{let t=JSON.parse(e),n=Array.isArray(t.comments)?t.comments.filter(ns):[],r={};if(t.read&&typeof t.read==`object`)for(let[e,n]of Object.entries(t.read))typeof n==`number`&&(r[e]=n);return{comments:n,read:r}}catch{return Yo()}}function Zo(e){return JSON.stringify({comments:e.comments,read:e.read})}function Qo(e){return e.toSorted((e,t)=>e.path.localeCompare(t.path,`en`,{numeric:!0})||e.startLine-t.startLine||e.createdAt-t.createdAt)}function $o(e){let t=new Map;for(let n of e)t.set(n.path,(t.get(n.path)??0)+1);return t}function es(e,t){let n=t[e.path];return n===void 0?`unread`:e.mtimeMs>n?`edited`:`read`}function ts(e,t){return`${e.toString(36)}-${Math.floor(t*1e9).toString(36)}`}function ns(e){let t=e;return typeof t==`object`&&!!t&&typeof t.id==`string`&&typeof t.path==`string`&&Number.isInteger(t.startLine)&&Number.isInteger(t.endLine)&&typeof t.body==`string`&&(t.quote===null||typeof t.quote==`string`)&&(t.suggestion===null||typeof t.suggestion==`string`)&&typeof t.createdAt==`number`}function rs(e,t,n){if(!t)return e[0]??null;let r=e.indexOf(t);return r<0?e[0]??null:e[r+n]??null}function is(e,t,n,r){let i=new Map(t.map(e=>[e.path,e])),a=r?e.indexOf(r):-1;for(let t=1;t<=e.length;t++){let o=e[(a+t)%e.length],s=o?i.get(o):void 0;if(s&&o!==r&&es(s,n)!==`read`)return o??null}return null}function as(e,t){return e.filter(e=>es(e,t)===`read`).length}var os=class extends Error{code;status;constructor(e,t,n){super(n),this.name=`ApiError`,this.status=e,this.code=t}};async function ss(e,t){let n;try{n=await fetch(e,{signal:t})}catch(e){throw e.name===`AbortError`?e:new os(0,`offline`,`mdifit is not running. Start it again from the terminal.`)}if(!n.ok){let e=await n.json().catch(()=>null);throw new os(n.status,e?.error.code??`error`,e?.error.message??n.statusText)}return await n.json()}function cs(){return ss(`/api/workspace`)}function ls(e){return ss(`/api/file?path=${encodeURIComponent(e)}`)}function us(e,t){return ss(`/api/search?q=${encodeURIComponent(e)}`,t)}function ds(e){let t=new EventSource(`/api/events`);return t.addEventListener(`change`,t=>{e(JSON.parse(t.data).path)}),()=>t.close()}function fs(e){let t=Jo(e),n=Ut(Xo(ps(t)));return qn(n,()=>ms(t,Zo(n)),{deep:!0}),window.addEventListener(`storage`,e=>{if(e.key!==t)return;let r=Xo(e.newValue);n.comments=r.comments,n.read=r.read}),{state:n,addComment(e){let t={...e,id:ts(Date.now(),Math.random()),createdAt:Date.now()};return n.comments.push(t),t},updateComment(e,t){let r=n.comments.findIndex(t=>t.id===e),i=n.comments[r];i&&(n.comments[r]={...i,...t})},removeComment(e){n.comments=n.comments.filter(t=>t.id!==e)},clearComments(e){let t=e?new Set(e):null;n.comments=t?n.comments.filter(e=>!t.has(e.id)):[]},markRead(e){n.read[e.path]=e.mtimeMs},markUnread(e){delete n.read[e]}}}function ps(e){try{return localStorage.getItem(e)}catch{return null}}function ms(e,t){try{localStorage.setItem(e,t)}catch{}}var hs=`mdifit:prefs`;function gs(){return qo(ps(hs))}function _s(e){ms(hs,JSON.stringify(e))}var vs=/[\p{L}\p{N}_]/u;function ys(e){return e!==void 0&&vs.test(e)}function bs(e,t){let n=t;for(;n>0&&ys(e[n-1])&&ys(e[n]);)n--;for(;n<e.length&&/\s/.test(e[n]??``);)n++;return n}function xs(e,t){let n=t;for(;n<e.length&&ys(e[n-1])&&ys(e[n]);)n++;for(;n>0&&/\s/.test(e[n-1]??``);)n--;return n}function Ss(e,t){let n=t.replace(/\s+/g,` `).trim();if(!n)return null;let r=``,i=[];e.forEach((e,t)=>{for(let n=0;n<e.length;n++){let a=e[n]??``;if(/\s/.test(a)){if(r.endsWith(` `)||r===``)continue;r+=` `}else r+=a;i.push({segment:t,offset:n})}});let a=r.indexOf(n);if(a<0&&(a=r.toLowerCase().indexOf(n.toLowerCase())),a<0)return null;let o=i[a],s=i[a+n.length-1];return!o||!s?null:{start:o,end:{segment:s.segment,offset:s.offset+1}}}function Cs(e){let t=window.getSelection();if(!t||t.isCollapsed||t.rangeCount===0)return null;let n=t.getRangeAt(0).cloneRange();if(!e.contains(n.commonAncestorContainer)||(ws(n),n.collapsed))return null;t.removeAllRanges(),t.addRange(n);let r=n.toString().trim(),i=Ts(n.startContainer,e),a=Ts(n.endContainer,e);if(!r||!i||!a)return null;let o=[i,a].flatMap(e=>[Number(e.dataset.lineStart),Number(e.dataset.lineEnd??e.dataset.lineStart)]);return{startLine:Math.min(...o),endLine:Math.max(...o),quote:r,rect:n.getBoundingClientRect(),range:n.cloneRange()}}function ws(e){let{startContainer:t,endContainer:n}=e;if(t instanceof Text&&e.setStart(t,bs(t.data,e.startOffset)),n instanceof Text){let t=xs(n.data,e.endOffset);(n!==e.startContainer||t>=e.startOffset)&&e.setEnd(n,t)}}function Ts(e,t){let n=e instanceof HTMLElement?e:e.parentElement;if(!n?.closest(`[data-doc]`))return null;let r=n.closest(`[data-line-start]`);return r&&t.contains(r)?r:null}function Es(){window.getSelection()?.removeAllRanges()}async function Ds(e){try{return await navigator.clipboard.writeText(e),!0}catch{let t=document.createElement(`textarea`);t.value=e,t.style.position=`fixed`,t.style.opacity=`0`,document.body.append(t),t.select();let n=document.execCommand(`copy`);return t.remove(),n}}function Os(e){let t=e;return t?t.isContentEditable||[`INPUT`,`TEXTAREA`,`SELECT`].includes(t.tagName):!1}function ks(e,t=`center`){e&&(e.scrollIntoView({block:t,behavior:`smooth`}),e.classList.remove(`flash`),e.offsetWidth,e.classList.add(`flash`))}var As={};function js(e){let t=As[e];if(t)return t;t=As[e]=[];for(let e=0;e<128;e++){let n=String.fromCharCode(e);t.push(n)}for(let n=0;n<e.length;n++){let r=e.charCodeAt(n);t[r]=`%`+(`0`+r.toString(16).toUpperCase()).slice(-2)}return t}function Ms(e,t){typeof t!=`string`&&(t=Ms.defaultChars);let n=js(t);return e.replace(/(%[a-f0-9]{2})+/gi,function(e){let t=``;for(let r=0,i=e.length;r<i;r+=3){let a=parseInt(e.slice(r+1,r+3),16);if(a<128)t+=n[a];else{if((a&224)==192&&r+3<i){let n=parseInt(e.slice(r+4,r+6),16);if((n&192)==128){let e=a<<6&1984|n&63;t+=e<128?`��`:String.fromCharCode(e),r+=3;continue}}if((a&240)==224&&r+6<i){let n=parseInt(e.slice(r+4,r+6),16),i=parseInt(e.slice(r+7,r+9),16);if((n&192)==128&&(i&192)==128){let e=a<<12&61440|n<<6&4032|i&63;t+=e<2048||e>=55296&&e<=57343?`���`:String.fromCharCode(e),r+=6;continue}}if((a&248)==240&&r+9<i){let n=parseInt(e.slice(r+4,r+6),16),i=parseInt(e.slice(r+7,r+9),16),o=parseInt(e.slice(r+10,r+12),16);if((n&192)==128&&(i&192)==128&&(o&192)==128){let e=a<<18&1835008|n<<12&258048|i<<6&4032|o&63;e<65536||e>1114111?t+=`����`:(e-=65536,t+=String.fromCharCode(55296+(e>>10),56320+(e&1023))),r+=9;continue}}t+=`�`}}return t})}Ms.defaultChars=`;/?:@&=+$,#`,Ms.componentChars=``;var Ns={};function Ps(e){let t=Ns[e];if(t)return t;t=Ns[e]=[];for(let e=0;e<128;e++){let n=String.fromCharCode(e);/^[0-9a-z]$/i.test(n)?t.push(n):t.push(`%`+(`0`+e.toString(16).toUpperCase()).slice(-2))}for(let n=0;n<e.length;n++)t[e.charCodeAt(n)]=e[n];return t}function Fs(e,t,n){typeof t!=`string`&&(n=t,t=Fs.defaultChars),n===void 0&&(n=!0);let r=Ps(t),i=``;for(let t=0,a=e.length;t<a;t++){let o=e.charCodeAt(t);if(n&&o===37&&t+2<a&&/^[0-9a-f]{2}$/i.test(e.slice(t+1,t+3)))i+=e.slice(t,t+3),t+=2;else if(o<128)i+=r[o];else if(o>=55296&&o<=57343){if(o>=55296&&o<=56319&&t+1<a){let n=e.charCodeAt(t+1);if(n>=56320&&n<=57343){i+=encodeURIComponent(e[t]+e[t+1]),t++;continue}}i+=`%EF%BF%BD`}else i+=encodeURIComponent(e[t])}return i}Fs.defaultChars=`;/?:@&=+$,-_.!~*'()#`,Fs.componentChars=`-_.!~*'()`;function Is(e){let t=``;return t+=e.protocol||``,t+=e.slashes?`//`:``,t+=e.auth?e.auth+`@`:``,e.hostname&&e.hostname.indexOf(`:`)!==-1?t+=`[`+e.hostname+`]`:t+=e.hostname||``,t+=e.port?`:`+e.port:``,t+=e.pathname||``,t+=e.search||``,t+=e.hash||``,t}function Ls(){this.protocol=null,this.slashes=null,this.auth=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.pathname=null}var Rs=/^([a-z0-9.+-]+:)/i,zs=/:[0-9]*$/,Bs=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,Vs=[`%`,`/`,`?`,`;`,`#`,`'`,`{`,`}`,`|`,`\\`,`^`,"`",`<`,`>`,`"`,"`",` `,`\r`,`
4
4
  `,` `],Hs=[`/`,`?`,`#`],Us=255,Ws=/^[+a-z0-9A-Z_-]{0,63}$/,Gs=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,Ks={javascript:!0,"javascript:":!0},qs={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0};function Js(e,t){if(e&&e instanceof Ls)return e;let n=new Ls;return n.parse(e,t),n}Ls.prototype.parse=function(e,t){let n,r,i,a=e;if(a=a.trim(),!t&&e.split(`#`).length===1){let e=Bs.exec(a);if(e)return this.pathname=e[1],e[2]&&(this.search=e[2]),this}let o=Rs.exec(a);if(o&&(o=o[0],n=o.toLowerCase(),this.protocol=o,a=a.substr(o.length)),(t||o||a.match(/^\/\/[^@\/]+@[^@\/]+/))&&(i=a.substr(0,2)===`//`,i&&!(o&&Ks[o])&&(a=a.substr(2),this.slashes=!0)),!Ks[o]&&(i||o&&!qs[o])){let e=-1;for(let t=0;t<Hs.length;t++)r=a.indexOf(Hs[t]),r!==-1&&(e===-1||r<e)&&(e=r);let t,n;n=e===-1?a.lastIndexOf(`@`):a.lastIndexOf(`@`,e),n!==-1&&(t=a.slice(0,n),a=a.slice(n+1),this.auth=t),e=-1;for(let t=0;t<Vs.length;t++)r=a.indexOf(Vs[t]),r!==-1&&(e===-1||r<e)&&(e=r);e===-1&&(e=a.length),a[e-1]===`:`&&e--;let i=a.slice(0,e);a=a.slice(e),this.parseHost(i),this.hostname=this.hostname||``;let o=this.hostname[0]===`[`&&this.hostname[this.hostname.length-1]===`]`;if(!o){let e=this.hostname.split(/\./);for(let t=0,n=e.length;t<n;t++){let n=e[t];if(n&&!n.match(Ws)){let r=``;for(let e=0,t=n.length;e<t;e++)n.charCodeAt(e)>127?r+=`x`:r+=n[e];if(!r.match(Ws)){let r=e.slice(0,t),i=e.slice(t+1),o=n.match(Gs);o&&(r.push(o[1]),i.unshift(o[2])),i.length&&(a=i.join(`.`)+a),this.hostname=r.join(`.`);break}}}}this.hostname.length>Us&&(this.hostname=``),o&&(this.hostname=this.hostname.substr(1,this.hostname.length-2))}let s=a.indexOf(`#`);s!==-1&&(this.hash=a.substr(s),a=a.slice(0,s));let c=a.indexOf(`?`);return c!==-1&&(this.search=a.substr(c),a=a.slice(0,c)),a&&(this.pathname=a),qs[n]&&this.hostname&&!this.pathname&&(this.pathname=``),this},Ls.prototype.parseHost=function(e){let t=zs.exec(e);t&&(t=t[0],t!==`:`&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)};var Ys=s({decode:()=>Ms,encode:()=>Fs,format:()=>Is,parse:()=>Js}),Xs=s({Any:()=>Zs,Cc:()=>Qs,Cf:()=>$s,P:()=>ec,S:()=>tc,Z:()=>nc}),Zs=/[\0-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,Qs=/[\0-\x1F\x7F-\x9F]/,$s=/[\xAD\u0600-\u0605\u061C\u06DD\u070F\u0890\u0891\u08E2\u180E\u200B-\u200F\u202A-\u202E\u2060-\u2064\u2066-\u206F\uFEFF\uFFF9-\uFFFB]|\uD804[\uDCBD\uDCCD]|\uD80D[\uDC30-\uDC3F]|\uD82F[\uDCA0-\uDCA3]|\uD834[\uDD73-\uDD7A]|\uDB40[\uDC01\uDC20-\uDC7F]/,ec=/[!-#%-\*,-\/:;\?@\[-\]_\{\}\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061D-\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C77\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B4E\u1B4F\u1B5A-\u1B60\u1B7D-\u1B7F\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4F\u2E52-\u2E5D\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD803[\uDD6E\uDEAD\uDED0\uDF55-\uDF59\uDF86-\uDF89]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC8\uDDCD\uDDDB\uDDDD-\uDDDF\uDE38-\uDE3D\uDEA9\uDFD4\uDFD5\uDFD7\uDFD8]|\uD805[\uDC4B-\uDC4F\uDC5A\uDC5B\uDC5D\uDCC6\uDDC1-\uDDD7\uDE41-\uDE43\uDE60-\uDE6C\uDEB9\uDF3C-\uDF3E]|\uD806[\uDC3B\uDD44-\uDD46\uDDE2\uDE3F-\uDE46\uDE9A-\uDE9C\uDE9E-\uDEA2\uDF00-\uDF09\uDFE1]|\uD807[\uDC41-\uDC45\uDC70\uDC71\uDEF7\uDEF8\uDF43-\uDF4F\uDFFF]|\uD809[\uDC70-\uDC74]|\uD80B[\uDFF1\uDFF2]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD81B[\uDD6D-\uDD6F\uDE97-\uDE9A\uDFE2]|\uD82F\uDC9F|\uD836[\uDE87-\uDE8B]|\uD839\uDDFF|\uD83A[\uDD5E\uDD5F]/,tc=/[\$\+<->\^`\|~\xA2-\xA6\xA8\xA9\xAC\xAE-\xB1\xB4\xB8\xD7\xF7\u02C2-\u02C5\u02D2-\u02DF\u02E5-\u02EB\u02ED\u02EF-\u02FF\u0375\u0384\u0385\u03F6\u0482\u058D-\u058F\u0606-\u0608\u060B\u060E\u060F\u06DE\u06E9\u06FD\u06FE\u07F6\u07FE\u07FF\u0888\u09F2\u09F3\u09FA\u09FB\u0AF1\u0B70\u0BF3-\u0BFA\u0C7F\u0D4F\u0D79\u0E3F\u0F01-\u0F03\u0F13\u0F15-\u0F17\u0F1A-\u0F1F\u0F34\u0F36\u0F38\u0FBE-\u0FC5\u0FC7-\u0FCC\u0FCE\u0FCF\u0FD5-\u0FD8\u109E\u109F\u1390-\u1399\u166D\u17DB\u1940\u19DE-\u19FF\u1B61-\u1B6A\u1B74-\u1B7C\u1FBD\u1FBF-\u1FC1\u1FCD-\u1FCF\u1FDD-\u1FDF\u1FED-\u1FEF\u1FFD\u1FFE\u2044\u2052\u207A-\u207C\u208A-\u208C\u20A0-\u20C1\u2100\u2101\u2103-\u2106\u2108\u2109\u2114\u2116-\u2118\u211E-\u2123\u2125\u2127\u2129\u212E\u213A\u213B\u2140-\u2144\u214A-\u214D\u214F\u218A\u218B\u2190-\u2307\u230C-\u2328\u232B-\u2429\u2440-\u244A\u249C-\u24E9\u2500-\u2767\u2794-\u27C4\u27C7-\u27E5\u27F0-\u2982\u2999-\u29D7\u29DC-\u29FB\u29FE-\u2B73\u2B76-\u2BFF\u2CE5-\u2CEA\u2E50\u2E51\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFF\u3004\u3012\u3013\u3020\u3036\u3037\u303E\u303F\u309B\u309C\u3190\u3191\u3196-\u319F\u31C0-\u31E5\u31EF\u3200-\u321E\u322A-\u3247\u3250\u3260-\u327F\u328A-\u32B0\u32C0-\u33FF\u4DC0-\u4DFF\uA490-\uA4C6\uA700-\uA716\uA720\uA721\uA789\uA78A\uA828-\uA82B\uA836-\uA839\uAA77-\uAA79\uAB5B\uAB6A\uAB6B\uFB29\uFBB2-\uFBD2\uFD40-\uFD4F\uFD90\uFD91\uFDC8-\uFDCF\uFDFC-\uFDFF\uFE62\uFE64-\uFE66\uFE69\uFF04\uFF0B\uFF1C-\uFF1E\uFF3E\uFF40\uFF5C\uFF5E\uFFE0-\uFFE6\uFFE8-\uFFEE\uFFFC\uFFFD]|\uD800[\uDD37-\uDD3F\uDD79-\uDD89\uDD8C-\uDD8E\uDD90-\uDD9C\uDDA0\uDDD0-\uDDFC]|\uD802[\uDC77\uDC78\uDEC8]|\uD803[\uDD8E\uDD8F\uDED1-\uDED8]|\uD805\uDF3F|\uD807[\uDFD5-\uDFF1]|\uD81A[\uDF3C-\uDF3F\uDF45]|\uD82F\uDC9C|\uD833[\uDC00-\uDCEF\uDCFA-\uDCFC\uDD00-\uDEB3\uDEBA-\uDED0\uDEE0-\uDEF0\uDF50-\uDFC3]|\uD834[\uDC00-\uDCF5\uDD00-\uDD26\uDD29-\uDD64\uDD6A-\uDD6C\uDD83\uDD84\uDD8C-\uDDA9\uDDAE-\uDDEA\uDE00-\uDE41\uDE45\uDF00-\uDF56]|\uD835[\uDEC1\uDEDB\uDEFB\uDF15\uDF35\uDF4F\uDF6F\uDF89\uDFA9\uDFC3]|\uD836[\uDC00-\uDDFF\uDE37-\uDE3A\uDE6D-\uDE74\uDE76-\uDE83\uDE85\uDE86]|\uD838[\uDD4F\uDEFF]|\uD83B[\uDCAC\uDCB0\uDD2E\uDEF0\uDEF1]|\uD83C[\uDC00-\uDC2B\uDC30-\uDC93\uDCA0-\uDCAE\uDCB1-\uDCBF\uDCC1-\uDCCF\uDCD1-\uDCF5\uDD0D-\uDDAD\uDDE6-\uDE02\uDE10-\uDE3B\uDE40-\uDE48\uDE50\uDE51\uDE60-\uDE65\uDF00-\uDFFF]|\uD83D[\uDC00-\uDED8\uDEDC-\uDEEC\uDEF0-\uDEFC\uDF00-\uDFD9\uDFE0-\uDFEB\uDFF0]|\uD83E[\uDC00-\uDC0B\uDC10-\uDC47\uDC50-\uDC59\uDC60-\uDC87\uDC90-\uDCAD\uDCB0-\uDCBB\uDCC0\uDCC1\uDCD0-\uDCD8\uDD00-\uDE57\uDE60-\uDE6D\uDE70-\uDE7C\uDE80-\uDE8A\uDE8E-\uDEC6\uDEC8\uDECD-\uDEDC\uDEDF-\uDEEA\uDEEF-\uDEF8\uDF00-\uDF92\uDF94-\uDFEF\uDFFA]/,nc=/[ \xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/,rc=[8364,0,8218,402,8222,8230,8224,8225,710,8240,352,8249,338,0,381,0,0,8216,8217,8220,8221,8226,8211,8212,732,8482,353,8250,339,0,382,376];function ic(e){return e===0||e>=55296&&e<=57343||e>1114111}function ac(e){return ic(e)?65533:e>=128&&e<=159&&rc[e-128]||e}function oc(e){return e-1>>>0<127||e-160>>>0<55136?String.fromCharCode(e):String.fromCodePoint(ac(e))}var sc=(()=>{let e=new Uint8Array(127),t=0;for(let n=33;n<=126;n++)n!==34&&n!==36&&n!==92&&(e[n]=t++);return e})();function cc(e,t,n,r,i,a){let o=e.length,s=a*90,c=0,l=()=>{let t=sc[e.charCodeAt(c++)];return t<a?t:t*91-s+sc[e.charCodeAt(c++)]},u=n-r,d=n+i,f=new Int32Array(d);f.fill(-1,r,a),f.fill(-1,a+u,d);let p=new Int32Array(d),m=new Int32Array(d);function h(t,n){let r=0,i=n,a=n+t;for(;i<a;){let t=sc[e.charCodeAt(c++)];if(t<89)r+=t,f[i++]=r;else if(t===89){let t=sc[e.charCodeAt(c++)]+2;for(;t--;)f[i++]=++r}else{let t=sc[e.charCodeAt(c++)];r+=89+(t<90?t*91+sc[e.charCodeAt(c++)]:sc[e.charCodeAt(c++)]*8281+sc[e.charCodeAt(c++)]*91+sc[e.charCodeAt(c++)]),f[i++]=r}}}h(r,0),h(u,a);let g=new Int32Array(i*2),_=0,v=0;function y(e,t){for(let n=0;n<e;n++){let e=t+n,r=l(),i=l();g[v*2]=r,g[v*2+1]=i,v+=1,p[e]=_;let a=(f[r]<0?m[r]:1)+(f[i]<0?m[i]:1);m[e]=a,_+=a}}y(i-a+r,a+u),y(a-r,r);let b=new Uint16Array(_),x=0;for(let e=0;e<v;e++)for(let t=0;t<2;t++){let n=g[e*2+t],r=f[n];if(r<0){let e=p[n],t=e+m[n];for(;e<t;)b[x++]=b[e++]}else b[x++]=r}let S=new Uint16Array(t),C=0;for(;c<o;){let t=sc[e.charCodeAt(c++)];t>=a&&(t=t*91-s+sc[e.charCodeAt(c++)]);let n=f[t];if(n<0){let e=p[t],n=e+m[t];for(;e<n;)S[C++]=b[e++]}else S[C++]=n}return S}var lc=cc("!}.&u%}'&}*'~!6*)%&,~!J~!J~%L~y<~!R,~~%Lu~~#GD~~#|)1#%}^%}2%+#.##%##%}&%##%'#%##&%#%#'%#&#%#&#'#%%#&#%##%#)%''%&%#%#'%#%%#%%}%%%#%#&(23#%%#&-%0%('1#(##%#'##+%'*.:1}#%#6-+(%'%%#%%%}#L'2351&('%}&/N'(0(/*-%(%%}#'+&T%7.2}#&%&#%#36/5##%&%%#&#%%#))2%%##%&&'0~!#*+&'%1~!%).'3q?&%'1~!.##%6(~!+%%%(Gw'rT~!E#<nA%#jZ~!H%(~!42##~!*31&~!G%U~#)5~#`3~!J~!Z~%]~%Y~%C~!q~!u~#kz~%#~!6'~!D~!U~!?~#T~!c%~!G#'~%7|~!G~!J~!G&~#pb~(Df}#%}*&}#%##%##%##&#-}&'#'&%#.++}%mI,#,@&(}*%}*'%&##&#%##%}&0}#.},U},%}+%}&%}#%##&}B%(}(%}+%)})%##%#&}&%##%&}<%}>%#%&}*%}(%}9%}/%})%}*%}*%}?&}&%}3%}&*#%})%#%#)}#&#-#+*%E%%'%'#%}#*V##&##I}#&&##%&%#&&Qf%%))w/0+&%#(#.%-''''++++7}>%4'',##1,#%#&%##&#'##&#*#9)%&%}#*}%,#+P(%A&%#'&##wSD',9E00#y#@}(+}&%&>~!#~!X}#*}(&&}(&}(,%}%&#+&}#&}I%#%}%)#(},'%#*}4%%#%}(''}#/##(##),%-##%%)#&}(.}&%#&}%%}*&#%},&&}&%}#%*'#%})%}D&}&%}-&}6&#&}-,%}#%})-(~+`~,=?~I9'9%~!,#%})%})%}@%}?%}(~!?~#<~#pP~#BG~#=1#%K+~#?#~%;)~#A~#mF1~#A'~'X%'~#lR~#N~'N~#r~#m#-~#i'?%#'%~#B%##%,%#~#_%#0%~#]732~,w~2+#:&#%&'0%&>%}#>##F+)#%&&#(+_}4&}-%}(&}@&}O7Fdf0@+/v4}&WU##&/0#&'('B#%}.%}'+#%}#%%&#&%#%##+#&#)#6#'#.},%}c%},%#%##%&#&%#&~#>'*-.%##%##%}#%%}%'~#)D1}#%*&~#_%%'(~#S2%'.}#~#=##*'*-%}&'%'##&&~'E%.#&~#M4}%%##&'%#~#O1##%&#'+~#<B%##%%'%+~#;#@%}#&%#&&%#(~#H1}'%'##&&~#?A}&'~#D#%32}'&&&&~#[}'(#%}'~#;C})&}%%#%~#=&%,3}%'(#%%~#^'#&&)#%'~#Y%-~#d-%'~#^%%&#&&&}#~#b~2t*&'~&(~&@~0%~e~3}%*''0})&}+~!9##-}#%-hD*)1fC#%/&/fB#40~!+#)*4~!+~!K'&:~!/*7~!.#~!H~!L':~%x&~!H#~!*~%1~!I#~!+A~#p'~!F~~#-#~,,(~.Z~!V~%;'B'mq-W~!N~%I%#&&#&}#%},%%}'%}+X#%}#&}(%}'%}<%}#%}%%'}'%}:~![)9@~%>~#UA%-%##&~!C%~!-.9:~!1~!-^2/:a~!y,D*J#-5)/4~%23,~#G~!L1~!0X3`~!2+~!!0-~&E~!W~!o,>Y&]~%cZx_&~#O*9#A#'#+I'%#)~!0B*-5A+-((F&*M#)(-7-5+'-3a5Vi~!Y~!?+[)%3),ERHm~!+:D,VG.+)?fB%%*(%)'(#&80%1'8`K8?`+'Z#&O&'H5#*9)A%%5&3))0%39+.*7#()&&*=4@**L)<'_&*+..;(#*+)./&0#3)%')-8(4ixD(&.}%,('aI:,)%,k2231T)I'#/-W7,/'Q#.'Y24+h')37</31&83##&0#),H(?'&?/1##%#&&#%''-%&&&#(&''&#.-'%#%%(,')*'&#&#'##%(%(#%('#&##%%%%('%#%#%%#%#&%##h>w+v<ayvyvcg.uuhKr}g/v|g>u9i[~>g5uI~=RvdwEg;v/g;uk!!TTSx]@RT!U!#!@VBRUU!'UTe-d0c`e&gSdicedFcrdTaqb.kYcAohdYd@a3e+d}dMdtd.aJ#bqcK`dle/e.e'dwdPdodddjbEb}ogd^ofdpduc6j?l%d{drdqc)d7bacOdQ%T#Y)X.sR[yH>6Vyv3[xwLu>vo'!*.[yBacahoj>6Rew3[xqdZa#!a&#^(X-[yG>6Vyu3[xvg3sEr|g.u/Ri9db0T#^(Xa)!-[y;>6Vylg4wKs{JwNZt3@3r=c4Z([xlg;wKt!cpq's@v7A'*a(a+!-a#[y<3Dt?3Dt'>6Vym3[xmg9rxsNJwLZt4~?r?db1T#`-!(Xa,!0[yS>6Vz%NuQs.g4wKtnJwNZtS@3r>c4Z([y%g;wKtrdga8!a(!#&T*Y-Xa#!a0<or[yc3Dtq>6Vz43[y3JwNZtf@3s!Ju}!%Dti:pm3c_%X#tjB5pkd6q!r]u?voC'*-a.a2!0a&a+[yI3DtI3Ds~3DtH>6Vyw3[xx;:s#~<5pKJwNZtE@3r~d`a)!a2T#a.(!+U.X1[yT3Dt`3Dtv>6Vz&3[y&g9rxwzcxstPu.<rAJwLZtT~?r@dZa%!a.&^*Za(/Reu[ya>6Vz23[y1g3sEr}wkg{NuQRg{ci(U#5@b`~,cg#U(2WnH5wugcRh7dX#T(Y,a'Ta!!a,[yZ<]mj>6Vz,3[y+Pv#5ReZKu+=,%!H}7ABwkaS?Rh:BcW(X#<]mrj:ubv/ARekdg%!(!a.*Ta(Y.X1!#sP>Rl*Dt6[y>>6Vyo3Wf*jOvuumvuRgRJuq*!:9<B@bX~3jVv&v@s@5Re[d/rQt{uAvo&a&a*)a2!,0Wf!3Dt0=Bs'>6Re}3[xy~<5s%JwJZt1~Gs)c;&!#2sJkNuXvzq7rxu,Re8dka4!a8(aEZ+a@Y.X1Xa)[yd=Bs(3DtP>6Vz53[y4cX#X&Re:avRe9~<5s&JwJZtQ~Gs*i^rzvdRg+Jv{%!2sbB@bX}kdga,!Za?&^*T1/!a'Dt+[y6>6Vyf3Wf%g/u;s4hGu6?Rh-JvZ,!c%#&RoX54Rivj7uyvf8RgTKvZB%*!2sGh<vu5Rgq<=C::9bb~#dZ#T&Ta6Y.X*Dt>[y93Wf)coZ(T,6VyifluvRgC@95@B@bX~/hFu34cC#T,k/unq8w8Q5RkUklwQuzunq8w8Q5Rk8d/rJu?v8w9)-&!a0a;a&aIWejg3sEr/h1s<DtDJvyZqY5aws3Jvy!&Wei~Hr1:au5@Bag>23E~5c:Z&bX};kKv?w&unuVu5Rjc;>bs)#~@:Rh.=ay<a]C;b`}Vd6s/t{uAvoaxa()!a,a7%-a#a2Dt,[yF2Wo[>6Vyt3[xuNuPRi&NuPwpi#RoWh?vf8Ri%Jv]!%Ri:KvxD!.'2WeAjZu`q9rxu,Re7woeAg-unLq(qA_/*2Wg_g3u5q^9:4E}/jTrxrzv=Wkkd~0UX#^^Xa-a1a5T&a=U1a'*aEa]!a*aPaA-adok[y54Rn>;:p3~Dp5g9rpsFNvZqjg3uJp4~<5p0Pw;5qlJwNZt*@3p1Pw:5p/Ou!5p2JvG'!6Vye=<qnJvh_[xhg3v,Rh3kOwOw-sDuev/Re^dha[a%!%!a+#Ta7)-5TaCaO!aka!a)sf[yb2>Rl!9ARiq5E}Qg=ucRkBE|oJrJ_@Wk~@Wk{JrJ_@Wk|@WkyJrJ_@Wk}@WkzJvO_[y2g-vMRmiKuYC!)&>Ri;>Ri<@3RkNc](X#@9Rk=g5vuRmhKvDB!+'=]meg3u4Rmgd)#Y'Vz3CARmfd`a+!%T'!+#Ta1Ta6TaM-sTDt9[yA9sYd'%Y#s[[xpj:ueunaXRgEjRq,v-vuqdd2'`#6Rev<32@5>:2<E}5xIo9a*X#Y(;5RePJvD_g>vyRgNj8w)v8<wggs:RgXiZt|vjx,hSq3ah!-(~@:Ro/Ou!5RhWj^v(pyw8unRhUdx-UY#^Ua.a3a70!)%UX1TaDa)'omRiRRhE[y:3Dsz=Br,>6Vyj3[xkg6ruwjcqsrPw;5r*Ku]D'Zt-@3r(~?r.i[vwv]dU1a--U#`a4(g/vsRhPOu!5RhLj:rmu9Wo!~@:wdh@g/vsRiTjXuvvNr}:RhBj^v(pyw8unRn]dz1UYa'a+^Y(!aETZalaRY.Ta?a4[yDJw1!#qLsW>6Vyrfzq-pLflpwRe|Js>%!Dt@3Dt&Jvy_[xs~HrnjMuwpsw'RecKu+D#'!t<~Grl~?rjg5u-x,gwp{ah!-(~@:Rg~Ou!5Rh'jXuvvNr}:Rh#cW#X/c;&!#2sLi[v7u7RgpJv)(!iLrxu,Re6j7v@s@5Se[e7d`aW!Za(a`T.a#!a3!&aDa-!9)Dt_=6s+3[x~~DR|h~DS6avhGun5RkZj3w)v-]mkKunB!&*]kb97R|i<ARk<c:Z(6Vy}Juh'!wziMRoS:F|vkLuauJv5vtvQRh1d='T+Y#VyO~DR|jcF#T'7R|g97R|kJv3'!ay<Rj,Jvh&!:ReXcsa6*a+#a#_aIRf9aLRf?c,Z&Rf5Rf7c.Z&Rf;Rf>cQ#%T'p-Rf8Rf=ct#%'(*!,p,Rf4p+Rf6Rf:Rf<d~'Ua%U*^UYa(!a,-!#a4YaTalaEX0a8a<Weo3Dt/3Dsx=Br93Wen~Dr;~<5p<JwNZt2@3p=Pw:5p;Ou!5r3c7&!#:p>3Ds}KvGB)_6Vyk2sM=<r7x'eovA(!hFu1ARf}cV#X&@r5j6rvwQa^Rf3c=Za'wkghJv__g;unRggA53B9=b^}%j6uduo5Jq;!(hIv%2Re`Ou4ARe_e%a#^^^Xa&!a*a2!&a6YaP!*ad!#a:aE/5Rn?[y@>6Vyp;:pE~DrY~<5pBJwNZt8@3pCh=rt3rWPw:5pAJup_[xoNuPpF9c!#'45pD5ARn)d8#X'X*3@rU72s]h>v<<sSjJpqvewOJq/(!hNw'5ReBk0s2u3w/w'5ReE5@Jq.!a+JQ!&WeU23d(#Y&RjG5]jBk!u7w&u0udARjEe#+^^^Ub#!a2/a`Z(agT1!a-a;|@TaG!aS[yV=Re~fow'RguNuPRe?bz#'>RoUWeL>:Cbb|?JwPZtVg6ruRmzJvD'!6Vz(g/vmRh~Jvy_[y(g9voRgyx*cy(#2>Ri2B9b]~9kIw9u7rluJu3Rg]dI#a%UY'@=p%CAx.gQZ&RhwwygtRm{x5g_Z'+ABqR9Woa=Bp&dV#^*Xa'!&@o{g4v]Rk;Jv{!%Rk[wkkiA5RkiwwfUB=x,fUuqC&*!>RfTg8v0RfV~ARfSd;rJsAuAv9wR'ae+/aO!a@aza/a#[yQ@Wg!2Wemg3sEr0JvB_g>uvReWg2v+Re=KupB_+[y!2AbY~-~Hr2AJwD!(h<~El>h<~El?Kun@+_:9b`}Kg-v/Ri3g;vtwyk_9]k_d=&T#*U.6qh@Ab`|K9:H|CJv[!&3Dtex'fDwC%!Rf[9WlMd[(^X,!a%Z06Vz!@WgBg=v~Rgvg,QRe@awd,#Y+jTv|Q~EfWj]uNr|~FRfXdy#Y&^Ua%!aO.!(a)Ua;=!a@aKap!a-,a!Ta]a[rSa]p?[y82sK=Bq~;:p:~<5p8Pw:5p7d'#Y'Wf(;RnRi[u4w&RgJJvG'!6Vyh=<r#ijuuv/sIKuYD'ZtG@3p9~Gr&d2#`(g<vtRgFj`u5w&rqpxRf2CJuY!+:wfnTOu!5Rg}jNs1ucv&RfwJvA!&3@q|BDcC#T,k/unq8w8Q5RkTklwQuzunq8w8Q5Rk9dga#!a'!a=#a0!:+Tb*b@aO.a4!aba8aFJv^}?!VyR~Dr<g;u%Rn.~<5p[x'e`wNZtR@3p]Pw:5pZhNvjBp.woe_g5u-r4JwF!%DtO3:ooc7&!#:p^3DtpLuGw(!+%)Dtk6Vz#2sd=<r8d'#Y([y#<x3gJt`w@!)%}MRiowzikRij=]ilxAf3,U(#B2Rf#g0v-Rm[ck{`U#]giKv3>)!&6Ri154s,KuGB_%@r68r:dJ|t`#X(9<E|u2@H|rx3gJu?w'!+'1Nu7Reg4=H~+9<wxgY95Rm]xLggZ-`(X}U2:Ri4h<uOawRmsJv__5@bb{jbV~3dka#a'a]!,#a+U=a>b6a3b%!/aKa/)!arwve^VyJ;:pR~DpTg3uJpS~<5pOPw;5qmPw:5pNOu!5pQJvG'!6Vyx=<qoJvA!{~Jup!%@qk7Rn/KvyD!}''[xz;>wkh'?Rh,x8gyt`w5D!&),(SgyccRgztJ@3pPB5p#d'(Y#<]mmifubw&RgoJvE&!82s^JvF&!8Rf,ADb]~;x=h'rNu]vK!,%'*0RnORh)4Rh*AqQg-vaRnNg;wHwkh'ba~4cE#Ta*x3gctyw@'!+%RnFRnD<4Rn@hFvK5RnCxWg[#`&a0Ua()`1Rm75Rg[c]%X#qi8Rg^NvdRj>BwzgZauwji7Rm6A4wgg]d1#&(*,.0a#Rm;Rm<Rm=Rm>Rm?Rm@RmARmBe%#^^^Xaea?aC/b+(,!a+a#!a/!>a&Ta<aKbD!2wphBRnk[yPw}hE|.=Br-3Dtm>6Vy~g6urRf.x,hPrNav!%'RnqRo%Ro#Nu;q[Pw;5r+JwNZtM@3r)d'#Y'Weh;xChL#`&RnmRnoKu}>%(!Rne~Bs-;2wjcussJv+'!aYSO}6@B<5?ba~8LrNvj!.%*ROwungw~ng~:9;Ri^>wtnig;wHRnixDh@|(UZ.x1h@|)!#:2<H|*xHn]#-UX'3Ro)z=iT}6ARns=Bwsn_wpnaRncw]aR(#UXa&Ua*a/=]iPd'#Y&Ro'WnXf{QRm2hNvj]nZd`'T~&1`{|`#9b]{}c:'!#Wl{>@=be}]?cl{{U#:5Abb}Jds#^YaF!a*b4a#a3aPa>&Tb!bH!*a_!Eau?/a&RjY<]gj>6Vz*;:pe~DrZg,QRj1JwNZtX@wihspcJvZ&!VyX9WmOJu|!|N2WmHJvh&!]ht~Bpbcn&T(!#RmQ<s7Nu;padH#X'`+WmJ@>RmKCARhnKup=!)&Wf+:RhqNuPpf9c!#'45pd5AwghpARn(Ls@w!%,)!RmP@Wfe<E|IJva!&WmNg8vsRmLd`*.`#Y'Xa!axRn*]hrA8Rhug5s@rXg8u!RmMd8#X'X*3@rV72smdI*#UY&RmICARho~GsgxVgd)Ta'U-Y&Xa!T#RnEWnA@Wffg1uDRi0hFvK5RnBxGnG&#`%owp)@wsf+bX}Ze-*1!a*^^^Ua|!#a.aq&Ya2!a>.a6!a:aO`aJDtL[y`@Wg#>6Vz12@wzoYRoZNuPRi!NuPRhzg=ucRi,@=b`{Yg=ucRi-ACJvB!&Sh[ebSh]ebi`wUuFRm4Jw2_[y0JvB!.<Ju(!&SoG}6Shd}6<Ju(!&SoH}6She}6Kur@._g5vHRieJvx!{L2G{Kx6gd'T#?Rh82Wi5cZ#X(g1w)Rm5dW-Y(Ta#!a)!#aYa=wnfE=su2>>bU{0j9udv:<svj8uQv-7RgHdE%#^'sq9sp=>Bb_{TJv`!&g/r|snj6v(us5d,#Y(56H}[978H}]Jw5!&g1rushJvB!+j;v{u5?zDhd}6}bj;v{u5?zDhe}6}ce*#`(^^^a[aea!=!a6a*aoXb1a.!aAbL!b>,b'aL!aV@Wf|2Wlg3[y/JwNZt^@3piPw:5pgJunZou3@rsJva&!Vy_g<v~Rm#JvG'!6Vz0=<r{Ju{%!:pj@WfsiXuJu3Rm:JvZ&!WfA~Bph@c4Z&Dtwax5rubx(#:awRk1@d,#Y&RfjRfid1#,Y(@Wfp2Wlrg5s@ryKu[@!,'=]ig9wlk?Rk>g5u-rqJvy'!@9RkQcH(T#=>Ri~@<wkj(Wj(KuZB*!&<7rw@9RkRcH(T#=>Ri}@<wkj)Wj)dg(Ta2Xa9X#`-!a*CARhg@@=I}d9x;c~#X%so=<sj>2@@=aybb}XjWv0Q~EfEj3vLv;<d,#Y(56H}`978H}_dgaPaFa'a/!#a3Y0a_a;a|!1(a7-[yE3[xt;:pJNvZrrg3uJrvJwNZt=@3pIh=rt3rxPw:5pGOu!5rpJvG'!6Vys=<rz@c4Z&Dt(ax5rtJvZ!&~BpH@wsfNg-vaRlNci*U#=<wei<F}a5@Jq.!a*JQ!%@qZ23d(#Y&RjH5]jCk!u7w&u0udARjFd/prq=tyvpaEa(a:.!a1aZ(@@=I}:9wpd%=<sX55w_h}@@=I{t=ay<aU@@=I}T=ay<2@@=I})?C9:9au@9Cb]}DP~=x-fAZ(2Wl1=ay<aU@@=I}>5@d##Y+jTv|vV~EfFj]uNpn~FRfGdgaK!Z2&!a8a-Tb({E!acTbM*!a(DtY[yYd'%Y#sl[y*hHvh>Re5x2c{Z}.j4uCvcawRiMd+#X+_x&d!},<5RkX;2Hzw@x,gavfB-!{CcF&T#Roe;RodwWbBg5urRgaKvHC*_6Vz+<4opieuew&Rmq@d]&Y)X,T#X0Rh}<BqP=4qS9:ReMg/ujReNJw0!/<Jui%!bd{kawwnemRelAxUa?a3#*.&UX(Ya+a/RhvRnQ<o}9Wmtd-#Y&RgSRmw9;Rmxay=Rmyg-vaRmuxEhSrNu,v-voC!%(aR.a(a7+1Ro1>Ro5CE{A9b]{@;5x#eO{:g;urRi+KrNA!%(Ro3>Ro79;Ri_Ku@>{;&!x%gX|{KunA_+g5QRj/g3u5Rj#g>uERj%wio/xRhS&!,!#^1U}wba{8>>@=be}qC@:D5ba{7Ku+A&!}x?ba}t>>@=be}se(aA^^^Uat!b0#{pa+awUazbGa#aLb9bgaWac'a5TbS=Br!d1#`%scp_Jvl!#rT>Re0JvX&!VyN=H{Fcm#U&:pY=ReaJv2&!]h0=]nUJvG'!6Vy|=<r%JrM_=]h2@Wlud'#)U'Wf'b]{i=]h/Jvh!&~BpWg=v]RnMx+ny#'Nu;pVwjnu=]nwxJnx,T#`&Reqwjnt=]nvieu9vrRjLLuYwP(#+!th@wih5pX~Gr'g5v/Rh4KunA'!-CARnP@wwiN:Rm_9x'cvw>!|l=<saKvAA!0&3@q}>w^e1bp#&Re2Re3BDx7gH#T|f5H|eKuZ>!%(:qNAH{]Jv6!+3B2B9=b^{X<5<B92:E{ZLvhwA(a;a%!igQuyRmad+#Y}m@3Rh5d8#X'X*:AqUAHzmaxwbh<aXRnVcF}RT#Nw&cj#U(BWnug/vsRntdka)(a3+.Zb7aYYan1!bVa@Xa}[y^@b[{G=H{+hFu73Rj&Pv#5ReQcK%T#sig1v{Rj'Ku+D#'!t]~Grm~?rkKuMB!01d5#`'Vy.ta3Dtu~Hroc8#'{^45s85AwZbP&!#Rn!wghxWn#KvEA!)&2RlA2RlBx:h|#(T,=]j09Wobz>x]z/@awRoTd+#Y(az]hFhCrm4d,#Y+jTv|Q~EfMj]uNr|~FRfOdCa!Xa9_X#@<plJvf!%b`{(9;Rgwc;.!#2x7cw#T|UDb]|T5Ju={(!=@E{&Jv)&!Ab`{'awJvf!~*>>@=be{#KuY>!+&4Ezyi[ugv&RjIdea+T)#UXa&T-T&a!Rh9auRmW=]kLg5vuRn+g3u4Rn-Ow6ARn,hHus5xNk?#UX(U~)/g8v0RkD~AwkkF?Ri.OuNBwkkA?Ri/d|a2`a*^UYa.!aBTZaTa'Xa;!(!2!-a#b2[yC>6Vyq3[xr2Wi?g1rusVh%s?DtF~<5rbJs;%!DtBfswKtCj[uvuSsEu3RgVx3o:u+wN'*Zt;@3rd~Grh~?rfg8w)Lq)qE&-a%!>bI|`jWv0vV~EfCjTv|vV~Ef@j]uNpn~FRfBcK#T']gWNu7x,k7q4ai(0!hHv8<RhmkMu9vrsBuev/RhlCJvB!,g<v{wchh~@:Rhji[vrv{wchi~@:RhkdS&a5UY#Ta!RgPwwiI5BwciI~@:Rh`x'iJvj'!5]iJPu8Bwch]~@:Rhach)U#h3rp]gLh@t|Ax,hTq3ah!-(~@:Ro0Ou!5RhXj^v(pyw8unRhVd|)`,^UYas!a?/a2Z'a^Ta{Tb7Ta(a#!a,Wf&9sZ3DtAadamov=Bqt3[xig8vsRm~>waiL2b`{QJv*_Ouv2qgj<v]v2BqfdR'X*X#Y-@3qr~Gqv~?p6hHv-]glPup5Lq+q?_%*b_{qF{n9b^{rOu4ARhpKvCD!+&~Bqp:5Dbb}nwoiKl&unuTuBv]v+ueunaXRf0=Jvh!0nKufu8v1w&w7q%w&uHrz:Rgnj5w,uxDJq/(!hNw'5ReCk0s2u3w/w'5ReFd>Za&!*UaA=<wkgsRnSJv^!%Refifw3vyRgOKu_B'!,<]gkiiu:w&Rh<=C@a^<B57@2F{[<B5@aW:=3away9A5aW=<B=C@a^<B57@2F{Ie-#`(^^^bCara.b8aza6!/bZ,!adTbnTbOb+aFaS!aAT9@Wf~2Wli3Dtl2@d,#Y&RfnRfmJwJZtN~GqyJva&!VyMg<v~Rm%iXuJu3Rm9Jv[_=]ih9wlkDRkCd1#`(@Wg>2Wls3cH#T(@<Rj*=>Ri|b~'#23s9h<~El.d'#Y&Dtxi^rzvdRl#d*#U%(o|B2s`hJwSaxRmDKv4B&!1:Rmdd5#`'Vx}to~Hq{x'f1v3(!BA5ba|bJv_&!Wfug1v]ReIdO+U/Y#&G}-8wze=Rh{g1v]ReHg/uQRf/by#)ibQwERl/cH#T(@<Rj+=>Ri{cNu+vlax-!(#a0qa9<Rii2;;bU{H;x<i=&X#Rk`<4wwi=C9H~8xAI(Y#<azRi@45wXI<B9;5bb~7dL(X#Xa(+!aL6Vy{g5QqOau:5au2@ay547EzbxOcU(UX-T#Ta#:Cbb|A?wjh/b_|SOw6ARgtihr}u7Rhy<d1#T)X1@@=I|~=ay<2@@=aybb}Sj3vLv;<d,#Y(56H}A978H}@dGpvs@uAu`vcw9*!aFa+ai%(b!aXa8.a?a[ozWey=sU2@G}Nch&U#Rf_WexKu+D#'!t:~Gr`~?r^j]uNr|~FRg*j^psurwJt|RmcKv)@&!)7Rkv~Br[@wxfO:Rl3co#U'6Rezj_q#vIuavjRltwzeyh@vr5JqD0!>aY?C9:9au@9Cb]}9cl#U*5;5<H||jbuus1ucv&Rfvg1v~d/pppzqFr^a--a~!aMat1(hFv;Wiz@@=Izoj5uuv-7Rix~Cw`fk2WlVcZ#X,k)u3vWs@u2]ktg;wEx'fBq(_2Wg/jTv|vV~EfoJv]!15x'hzqG!(P~EfU~CRl_j6v(us5x4i-#T(2WmZ?C2F|d>Kq<aj1!*jTqIsBv=Wl`~Cw`fi2WlWj`v0u*~>RlR=c>Z,k#u3vWs@u2]kr<c1Z+jTqIsBv=Wla~Cw`fm2WlXdmb3!a{(arZa`bkTa%TbQTa-a9+c'!aM!/[yL=Bqug.w'RifhFvyDRj.g>vgwyk^9]k^Jv3_@WfbAARkhJw2_[x|JvB_wkoIRoKwkoJRoLd'(Y#<]gm=<9<H|yd'%_X#skDtb3awwqkgNulRkgdB#^',9:p'hJwSaxRmEBwVb8@4=H|qLu+w50&!)@3qs~?pU>Awwn;;Rn=c:Z'ARn<=<qwKvC@!/&~BqqJv6!&]eVb^z^xRge'/a%+^`#Sge}6<4Rn3=]n0Pw2>Rn8Jw0!&>Rn:>Rn6cY#a7+!a&=<wkaNw~h3z_c5Z{=wjh#=]nLKv^D!&)Vyz=bW|swYb<WetcG#T(2wxa@qVx@gD#Y&b^|V5JwG&!5bb|pg/w&RgD@x=kHs=uAvn!a%%/'+RmSRh694Ro`g-vaRmRhHv-]mlxCcS#`&ba~.5cD#Ta)P~=d,#Y(56H{>978H{Dd_#{2^Y%_+qbbb{6g3sERhsbU{?dfa.,`a(Xa<!aiX#(55RiG54RiHcI#T'WiU3RiVNvdwtfcRlKNvdd,#Y&RlHRlExQgf.1*^T'X#Sgf}6Wn4=]hfPrk>Rn7Jw0!&>Rn5>Rn9Lunw?&a2!,5<oq@@wqfdRlJj5Q~=d,#Y(~ARfcOuN]fdDKw;ay(}i!547E}j?cI#T(@5bV}iCbV}hdv(^^Tb?a40,b##Tbo!a*bR!a<b|a/!aKai!aU[yK=]o^g:v>ReGJwPZtK<7Rh+h<~El,Pv#5ReR@awwxjCg,ulRjDJv6&!]j!z?aQeeg>w=Sh<eeJw;!&axEzOg,Qosc!#*:wkeJ]eJ>x'h-u(!%Ro.w~h.zPdNZ(X,Ya![x{;9ReY;wkgxRiF:x?ap#Y&RmUg<s2Rkod]+UY0TZ'!a&A9sw<=bczLNvuw{gqzNhJwSaxRmCKuLay!#&s_Rf-55b^{uJvZa!!c%#(55Ri654wmiu5RiuawLu,vp!+}^%b_}Y9;wkgxba}o>A9:=b^}zKuh=a''!3awRk3c*'!#aHRk6c+Z&Rk5Rk4Jv)&!awRjSawd9*`#0?C2@EzMj8u<uJ5RmbjQrquJu3x,k>uq@_+=ayb^|W~ARkEOuN]k@7dhzV^X/X&a-#zRzSb`zXcJzTT#2WkVKvDBzW!%FzY9;5bbzWjQrquJu3Jw3%!b`zU=ayb^zQd:#X(T-a!6Vyywxh}=b]{Jg=u1RiAdGp~qHtzv!w(wA+a+a;<!aJaYai'anasb(=azRmV:Cbb{MLq2vb!%')RjuRjrRjtRjqx3jnqCw3!%')Rk(Rk+Rk&Rk)Lq2vb!%')Rj{RjxRjzRjwLq2vb!%')RjsRjpRjfRjex3jcqCw3!%')Rk'Rk*RjkRjl9<CbbzfOu4ARhxLq2vb!%')RjyRjvRjhRjgx=joq*uKvb!%')+-Rk.Rk%Rj~Rk-Rk#Rj}x=jdq*uKvb!%')+-Rk,Rk!Rj|RjmRjjRjidAq&qKs@uAv8Aa.'*-a@a&0!aM@a5[y73Dsy3Ds|3Dt):wxgI2sHJwJZt.~Gqxwsf0ikrzt}Rl0Jvy_[xj~HqzKv_A|D!&WfP8axRoVcf,U#k(v]v+ueunaXRf1Ju}'!g8u#Ri=jQw!sCunLprq>!,')~<5qeGzq9F{W=c##%s5au:5aU3CBE|;d4#X(D!a&6Vygx(b;#(=]ed?C2F{N<capoq2r[a&!aPa9,'Pw;5s:@@=I|,55w_h|@@=IzcP~=x'fCqB_2Wl2>aU@@=I|1OuNBc1Z+jTqIsBv=Wlc~Cw`fl2WlZ~AcTa%!Z+jTqIsBv=Wlb~Cw`fh2WlYk+uNqJsBv=WlSg,u3dca3#UXaMYa)TaB-=cM|7T#<bI}l5@B932:aV2G{BOuNBJq:|M!5Ezt=<B=C@a^<B57@2F{v>cB{/T#=ay<bI{3Jv6!a.6BKq0ah&+!5E}HP~Ef{978BaU@@=Iza<7d#.Y#978BaU@@=IzH~AJq0!(@@=IzG978BaU@@=IzFe,aU*Y&^^^bvJb,b:bFad!a,c2Ta>aL.bo6!a#CbTa'T#Re{2Wlh2@G{yg6t~Ro_NvdRfticuRQRllJv3&!x&c|zs@Jw3!%RflwpfkRlpKuL;%(!Re<@G|C2GzdhIvuBwgjAg-u0RjAKQB%!(GzZ@G|5NuuRl7d='T+Y#Vy[g<v~Rm!==G|>JvA!)@wma=]m1ifuaw&RmnLs@vT'!|/+[y,g:v>ReTJw1!#qX=x!eC{bLu+wT&)ZtZauq_~Graci&U#F|89:r_Lupvq!.)&2RlG8RfaC=x!eF{_h?rpWlmd&'!#X|&]k::xJey#`'T|+<E|&2@H|%dE#(^,g;u.RiEg6vjRiC9xCkA{O|zY#g=ucRmXKs0@!&*@G|m@awRknJuh!,3d(}gY}eJvj!%Rm):Jw3!%Rm+Rm-Ls0w(&!a(a#@b[|6cZ#X'7RkxWgAOu4ARn'dH'U#Y*Vz-Wm'CARm}d]*#a%^a*T'aK!a<9bV{PC=p*Jw4!&SgxcbB5r]idw(wBRmF7xFkt#&`(Rm/Rm8E|!JuY_9:Rl5=wrgr2:bbxd@xXfB(a*#T+!.X0X1Ta/a'T&RlDRfL>RlyARl9b[z[>RfZ:RlL:RfRwlg/ARl;9;RlxKv,A/!%7s69<74=BA5ba{-8Bde#`a<XaKYa1,a'P~=wxfB2bZ}}?C972@@=I}r8@55B9;5bb}G978B2@@=aybb}3j3vLv;<Jw3&!>Rfk=ayb^}4~Ad1#`*@@=aybb{w2@>==<bbz]dx+UY#^UaF!a9!bB'Ya1.!ajXa#%olRhD[y=3Dt#Ov5BrHKuMB%!(Rf^Wep~HrJwkiQjKr|~FRg)Ku+D#'!t5~GrF~?rDdV)UY,Z/_7RkuG{<~BrBg,rlsO:235B@bX}|d?a1!#`(6Vyn5@d##Y+jTv|vV~EfIj]uNpn~FRfH7Lq2vb1!a9-978BaU@@=Iz9978BbU}#~AJq0!(@@=Iz8978BaU@@=Iz7~AJQ|}!978BbU}!JvkaK!AdUa21-U#`a+(g/vsRn~Ou!5RPj:rmu9WhOjXuvvNr}:RhAj^v(pyw8unRn[kPr}p|u7vwv]RiSBd;pppzq@qHQa?(b.!a.a`@.|xa(hFv;Wiyj5uuv-7Riw~Cw`fg2WlU978BbU|wOuNBJqG!(P~EfD~CRlQcZ#X,k)u3vWs@u2]ksg;wEx'f@q1_2Wg.j]uNpn~FRfqJv]!15x'h{qG!(@@=IzK~CRl^j6v(us5x4i,#T(2WmY?C2F{1>Kq<aj1!*jTqIsBv=Wld~Cw`fj2Wl[j`v0u*~>RlT=c>Z,k#u3vWs@u2]kq<c1Z+jTqIsBv=Wle~Cw`fn2Wl]dn1#c(a(b^a2!b/bAT(bj!aDa7bu,a_a{c0!2T0g:v>ReD2@G{42@G{5~DpM~<5rc=Bx6i>{RT#RnI@zCx]y]z:2Jv[!zr5Awyk]9]k]dD(Y+X#6Vz.g=wKtgwhaCwgmTWj2Lu,w%_+/[y-B;b^xeg3u3Rj-2@bX{*KrJ<!+'@Wg(g?QRlC@Jv`!%b[zIwsfII}8JQ_@w|kW|=Jv(%!AqcOuNBJvEzh!bYzjLs@wP#(0!oy@>RkdJwMZtc3Dtd@BcG#T'9bWxg2@2Fznd*#Y+;2x'c}w<zizixNgwa#Z'U+!/!a'!a+w~g~z6wcn{Rn}wcnzRn|5Rh%=]nJg5vuRmvNvdRlvcprJu}w*az*a#!%.a.'Bot9qT]kj@Wg'ay2Gzv@Jv`!%b[zEwsfHI}1;ck#Ux`<Cbbx_Lu+w!a&0*!wko*wwo,So,}6Juqxf!E}PigQuyRm`d3(`#8>Rn%:A5B;bZ~%KvhCa!a2!x>k7#Uxb@b{#xaRk7Jw0!)>wwhlShl}6>wwhmShm}6CJvB!.x'hhvj{!!5Bwkhhbaz}x'hivjz~!5Bwkhibaz|xEhTrNu,v-vpD!a%&/)a3a.,%Ro2t[CE{)@3re9b]{%wjo09:rgc:Z&Ro6=<riifuaw&RmoKrNA!%(Ro4>Ro89;Ri`dSaL'UYzxZb)7Rka3xRhT&!,!#^1U}vbaz{>>@=be}yC@:D5bazzKu+A&!}{?ba}y>>@=be}wxBh[t`u~vJvr!%a!a()a,a0a4RoC=]o;Ju(!%RoGRhdwjh`=]oAg>w#Ro?g5vuRo=NvdRl|Ku]C.!&;RoEJvB!%RoORoMBx'h[v+_?w~h`}~5?w~hd~!xKh]oiptu-utv.vp!#%&a30a@a'a+(a/aOp(o~p!RoDJu(!%RoHRhewjha=]oBNvdRl}g>w#Ro@g5vuRo>c[#X']o<CauRoRAd-#Y':RkpauRoQKu]C.!&;RoFJvB!%RoNRoPBx'h]v+_?w~ha}t5?w~he}ue!/UbhYacXaW^Tc&a;b:a-c/#b&aja1(!cL+!bKbt!bmcRc9aIc?8[yW3Dtt94Rg`Jv}!&SiRMzBhEebShEMNuPRe>x7gL#TzuwjirRipc<Z&>on;>z=h-MSh.Mwqczx'a7vj&!>Re4@=ResJt__NuPRi*NuPRi)j]uNr|~FRfzKrJ>_+@Wfy@Wf]2WocKrJ<!+'@Wg%g/QRl@@Jv`!&awRl<wsfFIzgLu(w*!.*&ShBMwvhIRhI9;RhNx1hK'!#Sn]Mx1hK~0!#:2<H~7cNu+w7D*'1ZtW>Rn1~?rOc:Z&Rn2=<rQ<7wjh&=BSnLMc]#X(6Vz)w[b=a!U#9wzgMc3#&(RgMRitRis<x,gKt`ax!&+SioM=BSilMc3#&(RgKRinRimKurB,!&SiQMzBhDebShDM6BJQ!(P~Efx978B2@@=I}WLrJw!!,a*&@G}O@9wkibRid@@x'fKwC!&SlDMSfLMjUv~Q~EfKKv3@a+!(hFv-]mpx/hYZ(C5RiWz<o/MwkhY?So/M@x,gbvfB*&!SgEM:SoeeehFu3:Rgbda(,^TZa)X/7Sg[eb:2RgI~BrMC@wgkc:wwkcRerx3h(uUvK!&*,SnOM4Sh*MArRg;wHRh(x=h;rJvPwI!a4',a'0@Wg&=BSh/Mg>w=Rh=g3w*wwgGRgGcW(X#;Sg}M2Gzk@Jv`!&awRl=wsfGIz`dKZ*T'Y-:RhR7RhQg5u-p`j6v(us5d,#Y+~Awkia?RicOuNBwkibba}Ld6p~tyu_vbAa'a+!a/'a3aEa8a!>Sh,ebJv{!&Sh@ebSaReb9;SgwebNuPRi(NvdRl)NuPRi'hHu^<Rm^Jvv_@Wl(g;u1Si/ebKu'B&!*Sh?eb@Wl'z@aPeb95Si.ebcpputyvjB)!,&a+0a%ShAMWeK@G}C@WfJ9;RhMwvhH9w{ia}ix,hJvRA1(!zAn[MRhHx1hJ~*!#hFv(BSn[MBJQ!(@@=I~'978B2@@=I}2db.Ua<'X}+T#a0XaG2G}E;wkg|wuh!Rh!x,hZu,@)!&So0MVy)C5RiXACJvB!&5RiY5RiZg8w)cG}*T#2@bU}=KsA>(!a.3wkhZba~(x,h^u(A!&(SoCMRhb5Bz=h[eb?w~hb~6x,h_u(A!&(SoDMRhc5Bz=h]eb?w~hc~6e)aA1T#T,^^^c-bMb&blcPaP(a/!0!bA=b5c@a(!bfbrc#2afwmhARnjwchORnp2Wlf3DtsNvdRl-2@wpa<]m0bx(#:awRk2@Jw3!%RfhwpfgRlnKQB%!(G{V@G|'NuuRl6d='T+Y#VyUg<v~Rl~==G|<Jv+'!aYShC}6@B<5?ba~8@Jw3'!g2QRljhLrpWlOd+#Y'g.w'rIg>w*wgj@g-u0Rj@Lu+wT&)ZtUauq]~GrGci&U#F|39:rELrNvj!.%*RhCwunfw~nf~:9;Ri]>wtnhg;wHRnhx3hDs@v~!/+'@Wfr@9RkSNu&Rlo=@<5GzoKs0@_+@Wl+@awRkmJuh!-3d(}pY#qWJvj!%Rm(:Jw3!%Rm,Rm*de&!1U-U#`)Re;@G|.@9Ri82@wjfvRlq=@<5GzpLvOvr!).&2RlF8Rf`C=x!eE{.Jw3_g2QRlkhLrpWlPde(!#U{s,UXa*Ta'[y'g:v>ReS;x0PZ&RnlRnn~HrKJw1}f!=x!eB|2w]aP(#Xa&a*Ta.Ua2a7=]iOd'#Y&Ro&WnWg;u.RiDg6vjRiBNvdRlzhNvj]nYJuW_2Wm3x)kFze{9d])!a.!,Y01!#&aC!a3RndC=ox~BrC@2b^{pg,rlse7x'ksuq!%Rm.E{xidw(wBRmGx9o+)X#wwo-So-}69:Rl4@xSf@a#XZ'X)X,Ta(/ARl8b[xc>RfY:RlI:RfQwlg.ARl:9;Rlwdn'#^XafaQa1X1TaHTa)@b[{zcZ#X'7RkwWg@Ou4ARn&x)kG#{,g7u/RkGdH'U#Y*Vz'Wm&CARm|bx#(A]gUbUzJj9Q~=d,#Y(56H}l978H{U7d,0#U*2>ABb_xZ978BbU{e~AJQ{g!978BbU{hxMh?ad{oUYZ.x1h?{l!#:2<H{mx3n[t{vl!,&a%3Ro(z=iS}6ARnr=Bwsn^wvn`Rnbd`*T}B0!#^X'BG{c9b]{a>>@=be}F?JvS!&BG{d7BG}(Bde#`a1X,Ya@!a'P~=wxf@2bZ}I56B2@@=aybb}08@55B9;5bb}<j3vLv;<Jw3&!>Rfg=ayb^}&OuNBKuLA!)a!P~=x#fD{f2@>==<bbzl?C972@@=Ix^d6rSu,v7w*C(0a)a6#B+a%!sQ[y?3Dt%3[xn~<5rLOu!5p@Ku+D#'!t7~GrP~?rNKvlaya7'!h+v-5qMg=t|cd,U#5AAaa5Abb{S@52B5@a[@52B5Gx[iXueu;d<#`a(!/549C;ag>23ExY5@Dah89b^~689Jv)!~2b[~1Lv'w(%*!a#bX|aPrmawRe]keu7uhv-q6rxu,q`xTo]/a5aU!bNaDXbi!b-!ao!b<bwA!#5@B932:aV2G|:d-)Y#hJrL>RhG<7@C5<H|_=Cau:5aj5@B932:bJ|ng>vIbs)#?C2F|9jPv0w.vISh-MKvUaz(.!9ABbb|[5;5<H|Eg>unwfh;9:4E|YjQsBt|vjx'hYq3!(?C2F|J:2<BaY?C2F|GOu!5x,g|p{ah!-(?C2F|c9:4E|OjXuvvNr}:Rh&i[w*t|cd+U#jJvsu)vsSn~Mkfrmu9p}u7vwv]So!McW#Xa!ax5@A5aY:5;5<H|>kJv~vYrquJu3x4ib#T)2@SmZM?C2F|Bj:rmu9@xPhI(a*a#U#`a3-5Abb|L~@:RhK9:4E|0@52B5G|#C::aY?C2F|-:2<BaY?C2F|.5Jvk!a)javYrquJu3x4ia#T)2@SmYM?C2F|HAxPhH(!a#U#`a*-5Abb|4~@:RhJ9:4E|R@52B5G|F:2<BaY?C2F|Sc^#Xa2j=Qq5CJvB!-g<v{z;hhM?C2F|Zi[vrv{z;hiM?C2F|XKsA>!a)-g<v{z;h[eb?C2F|]i[vrv{z;h]eb?C2F|^iZu.vix,hZq3ah!.(?C2F|QOu!5ShXM:2<BaY?C2F|P",13494,2713,49,25,61),uc;(function(e){e[e.VALUE_LENGTH=49152]=`VALUE_LENGTH`,e[e.FLAG13=8192]=`FLAG13`,e[e.BRANCH_LENGTH=8064]=`BRANCH_LENGTH`,e[e.JUMP_TABLE=127]=`JUMP_TABLE`,e[e.VALUE_MASK=8191]=`VALUE_MASK`})(uc||={});var dc;(function(e){e[e.AMP=38]=`AMP`,e[e.NUM=35]=`NUM`,e[e.SEMI=59]=`SEMI`,e[e.EQUALS=61]=`EQUALS`,e[e.ZERO=48]=`ZERO`,e[e.NINE=57]=`NINE`,e[e.LOWER_A=97]=`LOWER_A`,e[e.LOWER_X=120]=`LOWER_X`})(dc||={});var fc=32,pc=21,mc=2097151,hc=2047,gc=0;function _c(e){let t=e>>>pc;return t===hc?gc:t}function vc(e){return e-dc.ZERO>>>0<=9}function yc(e){return(e|fc)-dc.LOWER_A>>>0<=5}function bc(e){return(e|fc)-dc.LOWER_A>>>0<=25}function xc(e){return e===dc.EQUALS||bc(e)||vc(e)}var Sc;(function(e){e[e.EntityStart=0]=`EntityStart`,e[e.NumericStart=1]=`NumericStart`,e[e.NumericDecimal=2]=`NumericDecimal`,e[e.NumericHex=3]=`NumericHex`,e[e.NamedEntity=4]=`NamedEntity`})(Sc||={});var Cc;(function(e){e[e.Legacy=0]=`Legacy`,e[e.Strict=1]=`Strict`,e[e.Attribute=2]=`Attribute`})(Cc||={});function wc(e,t,n,r){let i=(t&uc.BRANCH_LENGTH)>>7,a=t&uc.JUMP_TABLE;if(a){if(i===0)return r===a?n:-1;let t=r-a;if(t>>>0>=i)return-1;let o=e[n+t];return o===0?-1:n+i+o-1&65535}if(i===0)return-1;let o=i+1>>1,s=n+o+i;for(let t=0;t<i;t++){let i=e[n+(t>>1)]>>((t&1)<<3)&255;if(i===r)return s+e[n+o+t]&65535;if(i>r)return-1}return-1}function Tc(e,t,n){return n===1?String.fromCharCode(e[t]&uc.VALUE_MASK):n===2?String.fromCharCode(e[t+1]):String.fromCharCode(e[t+1],e[t+2])}function Ec(e,t,n){let r=t+1,i=0,a=r;if(r<n&&(e.charCodeAt(r)|fc)===dc.LOWER_X)for(r+=1,a=r;r<n;){let t=e.charCodeAt(r);if(vc(t))i=i*16+(t-dc.ZERO);else if(yc(t))i=i*16+((t|fc)-dc.LOWER_A+10);else break;r+=1}else for(;r<n;){let t=e.charCodeAt(r)-dc.ZERO;if(t>>>0>9)break;i=i*10+t,r+=1}if(r===a)return 0;r<n&&e.charCodeAt(r)===dc.SEMI&&(r+=1),i>1114111&&(i=1114112);let o=r-t;return o>=hc&&(gc=o,o=hc),o<<pc|i}function Dc(e,t,n){let r=lc,i=e.indexOf(`&`);if(i<0)return e;let a=e.length,o=0,s=``,c=r[0],l=c&uc.JUMP_TABLE,u=(c&uc.BRANCH_LENGTH)>>7;do{let c=i+1,d=e.charCodeAt(c),f,p;if(d===dc.NUM){let n=Ec(e,c,a);f=_c(n),t&&f>0&&e.charCodeAt(c+f-1)!==dc.SEMI&&(f=0),p=f===0?``:oc(n&mc)}else if(bc(d)){f=0,p=``;let n=d-l,i;if(n>>>0<u){let e=r[1+n];i=e===0?-1:u+e&65535}else i=-1;let o=0,s=0,m=i<0?0:r[i],h=c+1;trie:for(;h<a;){for(;(m&(uc.VALUE_LENGTH|uc.FLAG13))===0&&(m&uc.JUMP_TABLE)!==0;){let t=m&uc.JUMP_TABLE,n=(m&uc.BRANCH_LENGTH)>>7;if(n===0){if(e.charCodeAt(h)!==t)break trie;i+=1}else{let a=e.charCodeAt(h)-t;if(a>>>0>=n)break trie;let o=r[i+1+a];if(o===0)break trie;i=i+n+o&65535}if(m=r[i],h+=1,h>=a)break trie}if((m&(uc.VALUE_LENGTH|uc.FLAG13))===uc.FLAG13){let t=(m&uc.BRANCH_LENGTH)>>7;if(e.charCodeAt(h)!==(m&uc.JUMP_TABLE))break;h+=1;let n=t-1,a=i+1,o=0;for(;o+1<n;o+=2){let t=r[a];if(e.charCodeAt(h)!==(t&255)||(h+=1,e.charCodeAt(h)!==(t>>8&255)))break trie;h+=1,a+=1}if(o<n){if(e.charCodeAt(h)!==(r[a]&255))break;h+=1}i+=1+(t>>1),m=r[i];continue}let n=m>>>14,l=e.charCodeAt(h);if(n!==0){if(l===dc.SEMI){f=h-c+1,p=n===1?String.fromCharCode(m&uc.VALUE_MASK):Tc(r,i,n);break}if(!t&&(m&uc.FLAG13)===0&&(f=h-c,o=i,s=n),n===1)break}let u=wc(r,m,i+(n||1),l);if(u<0)break;i=u,m=r[i],h+=1}if(p===``){let e=m>>>14;e!==0&&!t&&(m&uc.FLAG13)===0&&(f=h-c,o=i,s=e),f>0&&(p=Tc(r,o,s))}}else f=0,p=``;f===0||n&&d!==dc.NUM&&e.charCodeAt(c+f-1)!==dc.SEMI&&c+f<a&&xc(e.charCodeAt(c+f))?i=c:(o<i&&(s+=e.slice(o,i)),s+=p,i=o=c+f),e.charCodeAt(i)!==dc.AMP&&(i=e.indexOf(`&`,i))}while(i>=0);return s+e.slice(o)}function Oc(e){return Dc(e,!0,!1)}var kc=class{src_Any=Zs.source;src_Cc=Qs.source;src_Z=nc.source;src_P=ec.source;src_ZPCc=[this.src_Z,this.src_P,this.src_Cc].join(`|`);src_ZCc=[this.src_Z,this.src_Cc].join(`|`);cache={};opts={maxLength:1e4,urlAuth:!1,schema_names:[]};constructor(e={}){this.opts={...this.opts,...e}}set(e={}){return this.opts={...this.opts,...e},this.cache={},this}escapeRE(e){return e.replace(/[.?*+^$[\]\\(){}|-]/g,`\\$&`)}nestedPairRE(e,t,n=4){let r=this.escapeRE(e),i=this.escapeRE(t),a=`(?:(?!${this.src_ZCc}|${r}|${i}).)`,o=`${r}${a}{0,1000}${i}`;for(let e=2;e<=n;e++)o=`${r}(?:${a}|${o}){0,1000}${i}`;return o}get_text_separators(){return this.cache.text_separators??=/[><\uff5c]/}get_pseudo_letter(){return this.cache.src_pseudo_letter??=RegExp(`(?:(?!${this.get_text_separators().source}|${this.src_ZPCc})${this.src_Any})`)}get_ipv4_addr(){return this.cache.src_ip4??=RegExp(`(?:(?:25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9][0-9]|[0-9])[.]){3}(?:25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9][0-9]|[0-9])`)}get_ipv6_addr(){let e=`[0-9A-Fa-f]{1,4}`,t=`(?:(?:${e}:${e})|${this.get_ipv4_addr().source})`;return this.cache.src_ip6_addr??=RegExp(`(?:(?:${e}:){6}${t}|::(?:${e}:){5}${t}|(?:${e})?::(?:${e}:){4}${t}|(?:(?:${e}:){0,1}${e})?::(?:${e}:){3}${t}|(?:(?:${e}:){0,2}${e})?::(?:${e}:){2}${t}|(?:(?:${e}:){0,3}${e})?::${e}:${t}|(?:(?:${e}:){0,4}${e})?::${t}|(?:(?:${e}:){0,5}${e})?::${e}|(?:(?:${e}:){0,6}${e})?::)`)}get_ipv6_url_host(){return this.cache.src_ip6_host??=RegExp(`\\[${this.get_ipv6_addr().source}\\]`)}get_ipv6_mail_host(){return this.cache.src_ipv6_mail_host??=RegExp(`\\[IPv6:${this.get_ipv6_addr().source}\\]`)}get_auth(){return this.cache.src_auth??=RegExp(`(?:(?:(?!${this.src_ZCc}|[@/\\[\\]()]).){1,50}@)?`)}get_port(){return this.cache.src_port??=RegExp(`(?::(?:6(?:[0-4]\\d{3}|5(?:[0-4]\\d{2}|5(?:[0-2]\\d|3[0-5])))|[1-5]?\\d{1,4}))?`)}get_host_terminator(){return this.cache.src_host_terminator??=RegExp(`(?=$|${this.get_text_separators().source}|${this.src_ZPCc})(?!${this.opts[`---`]?`-(?!--)|`:`-|`}_|:\\d|\\.-|\\.(?!$|${this.src_ZPCc}))`)}get_path_terminator(){return this.cache.src_path_terminator??=RegExp(`${this.src_ZPCc}|${this.get_text_separators().source}`)}get_path(){return this.cache.src_path??=RegExp(`(?:[/?#](?:${this.nestedPairRE(`[`,`]`)}|${this.nestedPairRE(`(`,`)`)}|${this.nestedPairRE(`{`,`}`)}|\\"(?:(?!${this.src_ZCc}|["]).){1,100}\\"|\\'(?:(?!${this.src_ZCc}|[']).){1,100}\\'|\\'(?=${this.get_pseudo_letter().source}|[-])|\\.{2,20}[:]?[a-zA-Z0-9%/&]|\\.(?!${this.src_ZCc}|[.]|$)|`+(this.opts[`---`]?`\\-(?!--(?:[^-]|$))(?:-{0,19})|`:`\\-{1,20}|`)+`,(?!${this.src_ZCc}|$)|;(?!${this.src_ZCc}|$)|\\!{1,20}(?!${this.src_ZCc}|[!]|$)|\\?(?!${this.src_ZCc}|[?]|$)|`+this.get_path_extra().source+`[\\\\/:%@#&=_~*]|(?!${this.get_path_terminator().source}).){1,${this.opts.maxLength}}|\\/)?`)}get_mail_name(){return this.cache.src_mail_name??=RegExp("[-!#$%&'*+/=?^_`{|}~a-zA-Z0-9](?:[-!#$%&'*+/=?^_`{|}~a-zA-Z0-9]|[.](?=[-!#$%&'*+/=?^_`{|}~a-zA-Z0-9])){0,63}")}get_xn(){return this.cache.src_xn??=RegExp(`xn--[a-z0-9\\-]{1,59}`)}get_tld(){if(this.cache.tld)return this.cache.tld;let e=[...new Set(this.opts.tlds||[])].sort().reverse().join(`|`);return this.cache.tld=RegExp(`${e||`$#none#$`}|${this.get_xn().source}`),this.cache.tld}get_domain_root(){return this.cache.src_domain_root??=RegExp(`(?:`+this.get_xn().source+`|${this.get_pseudo_letter().source}{1,63})`)}get_domain(){return this.cache.src_domain??=RegExp(`(?:`+this.get_xn().source+`|(?:${this.get_pseudo_letter().source})|(?:${this.get_pseudo_letter().source}(?:-|${this.get_pseudo_letter().source}){0,61}${this.get_pseudo_letter().source}))`)}get_url_host_port(){return this.cache.url_host_port??=RegExp(`(?:`+this.get_ipv6_url_host().source+`|(?:(?:(?:${this.get_domain().source})\\.){0,10}${this.get_domain().source}))`+this.get_port().source+this.get_host_terminator().source)}get_fuzzy_url_host_port(){return this.cache.fuzzy_url_host_port??=RegExp(`(?:`+(this.opts.fuzzyIP?this.get_ipv4_addr().source+`|`:``)+`(?:(?:(?:${this.get_domain().source})\\.){1,10}(?:${this.get_tld().source})))`+this.get_host_terminator().source)}get_mail_host(){return this.cache.src_mail_host??=RegExp(`(?:`+this.get_ipv6_mail_host().source+`|(?:(?:(?:${this.get_domain().source})\\.){0,4}${this.get_domain().source}))`+this.get_host_terminator().source)}get_fuzzy_mail_host(){return this.cache.src_fuzzy_mail_host??=RegExp(`(?:`+this.get_ipv6_mail_host().source+`|(?:(?:(?:${this.get_domain().source})[.]){1,4}${this.get_domain_root().source}))`+this.get_host_terminator().source)}get_path_extra(){return this.cache.src_path_extra??=RegExp(``)}get_fuzzy_mail_host_search(){return this.cache.mail_fuzzy_host_search??=RegExp(`@${this.get_fuzzy_mail_host().source}`,`ig`)}get_fuzzy_link_search(){return this.cache.link_fuzzy_search??=RegExp(`(^|(?![.:/\\-_@])(?:[$+<=>^\`|\uff5c]|${this.src_ZPCc}))(?:(?![$+<=>^\`|\uff5c])${this.get_fuzzy_url_host_port().source}${this.get_path().source})`,`ig`)}get_http_validator(){return this.cache.http_validator??=RegExp(`\\/\\/`+(this.opts.urlAuth?this.get_auth().source:``)+this.get_url_host_port().source+this.get_path().source,`iy`)}get_relative_proto_validator(){return this.cache.relative_proto_validator??=RegExp((this.opts.urlAuth?this.get_auth().source:``)+`(?:localhost|${this.get_ipv6_url_host().source}|(?:(?:${this.get_domain().source})[.]){1,10}${this.get_domain_root().source})`+this.get_port().source+this.get_host_terminator().source+this.get_path().source,`iy`)}get_mail_name_validator(){return this.cache.mail_name_validator??=RegExp(`(?:^|${this.get_text_separators().source}|"|\\(|${this.src_ZCc})(${this.get_mail_name().source})$`)}get_mailto_validator(){return this.cache.mailto_validator??=RegExp(`${this.get_mail_name().source}@${this.get_mail_host().source}`,`iy`)}get_schema_names(){return this.cache.schema_names??=new RegExp((this.opts.schema_names||[]).map(e=>this.escapeRE(e)).join(`|`))}get_schema_search(){return this.cache.schema_search??=RegExp(`(^|(?!_)(?:[><\uff5c]|${this.src_ZPCc}))(${this.get_schema_names().source})`,`ig`)}get_schema_at_start(){return this.cache.schema_at_start??=RegExp(`^${this.get_schema_search().source}`,`i`)}},Ac={validate:(e,t,n)=>{let r=n.re.get_http_validator();r.lastIndex=t;let i=r.exec(e);return i?i[0].length:0},normalize:(e,t)=>t.normalize(e)},jc={"http:":Ac,"https:":Ac,"ftp:":Ac,"//":{validate:function(e,t,n){let r=n.re.get_relative_proto_validator();r.lastIndex=t;let i=r.exec(e);return i?t>=3&&e[t-3]===`:`||t>=3&&e[t-3]===`/`?0:i[0].length:0},normalize:(e,t)=>t.normalize(e)},"mailto:":{validate:function(e,t,n){let r=n.re.get_mailto_validator();r.lastIndex=t;let i=r.exec(e);return i?i[0].length:0},normalize:(e,t)=>t.normalize(e)}},Mc=`a:cdefgilmnoqrstuwxz|b:abdefghijmnorstvwyz|c:acdfghiklmnoruvwxyz|d:ejkmoz|e:cegrstu|f:ijkmor|g:abdefghilmnpqrstuwy|h:kmnrtu|i:delmnoqrst|j:emop|k:eghimnprwyz|l:abcikrstuvy|m:acdeghklmnopqrstuvwxyz|n:acefgilopruz|o:m|p:aefghklmnrstwy|q:a|r:eosuw|s:abcdeghijklmnortuvxyz|t:cdfghjklmnortvwz|u:agksyz|v:aceginu|w:fs|y:et|z:amw`,Nc=`biz|com|edu|gov|net|org|pro|web|xxx|aero|asia|coop|info|museum|name|shop|рф`;function Pc(){let e=Nc.split(`|`);return Mc.split(`|`).forEach(t=>{let n=t.indexOf(`:`),r=t.slice(0,n);for(let i of t.slice(n+1))e.push(r+i)}),e}var Fc={fuzzyLink:!1,fuzzyEmail:!0,fuzzyIP:!1,"---":!1,tlds:Pc(),urlAuth:!1,maxLength:1e4},Ic=class{schema;index;lastIndex;raw;text;url;constructor(e,t,n,r){let i=e.slice(n,r);this.schema=t.toLowerCase(),this.index=n,this.lastIndex=r,this.raw=i,this.text=i,this.url=i}},Lc=class{__opts__;__schemas__;re;constructor(e={}){let{rebuilder:t,...n}=e;this.__opts__={...Fc,...n},this.__schemas__={...jc},this.re=t||new kc,this.re.set({...this.__opts__,schema_names:Object.keys(this.__schemas__)})}add(e,t=null){if(!t)delete this.__schemas__[e];else{let n={normalize:(e,t)=>t.normalize(e),...t};this.__schemas__[e]=n}return this.re.set({...this.__opts__,schema_names:Object.keys(this.__schemas__)}),this}set(e={}){return this.__opts__={...this.__opts__,...e},this.re.set({...this.__opts__,schema_names:Object.keys(this.__schemas__)}),this}test(e){if(!e.length)return!1;let t,n;for(n=this.re.get_schema_search(),n.lastIndex=0;(t=n.exec(e))!==null;)if(this.testSchemaAt(e,t[2],n.lastIndex))return!0;if(this.__opts__.fuzzyLink&&this.__schemas__[`http:`]&&(n=this.re.get_fuzzy_link_search(),n.lastIndex=0,n.exec(e)!==null))return!0;if(this.__opts__.fuzzyEmail&&this.__schemas__[`mailto:`]&&e.indexOf(`@`)>=0){let n=this.re.get_fuzzy_mail_host_search(),r=this.re.get_mail_name_validator();for(n.lastIndex=0;(t=n.exec(e))!==null;){let n=e.slice(Math.max(0,t.index-65),t.index);if(r.test(n))return!0}}return!1}testSchemaAt(e,t,n){return this.__schemas__[t.toLowerCase()]?this.__schemas__[t.toLowerCase()].validate(e.slice(0,n+this.__opts__.maxLength),n,this):0}match(e){let t=[],n=this.re.get_schema_search(),r,i,a,o,s,c,l=!1,u=!1,d=!1,f=0;if(!e.length)return null;for(n.lastIndex=0,this.__opts__.fuzzyLink&&this.__schemas__[`http:`]&&(r=this.re.get_fuzzy_link_search(),r.lastIndex=0),this.__opts__.fuzzyEmail&&this.__schemas__[`mailto:`]&&(i=this.re.get_fuzzy_mail_host_search(),i.lastIndex=0,a=this.re.get_mail_name_validator());;){let p=Math.max(f-1,0);if(i&&a&&!d&&(!s||s.index<f))for(i.lastIndex<p&&(i.lastIndex=p);;){let t=i.exec(e);if(!t){d=!0,s=void 0;break}let n=a.exec(e.slice(Math.max(0,t.index-65),t.index));if(n){if(s={schema:`mailto:`,index:t.index-n[1].length,lastIndex:t.index+t[0].length},s.index>=f)break;i.lastIndex<p&&(i.lastIndex=p)}}if(r&&!u&&(!o||o.index<f))for(r.lastIndex<p&&(r.lastIndex=p);;){let t=r.exec(e);if(!t){u=!0,o=void 0;break}if(o={schema:``,index:t.index+t[1].length,lastIndex:t.index+t[0].length},o.index>=f)break;r.lastIndex<p&&(r.lastIndex=p)}let m=s;(!m||o&&(o.index<m.index||o.index===m.index&&o.lastIndex>m.lastIndex))&&(m=o);let h;if(!l)for(;;){if(!c){n.lastIndex<p&&(n.lastIndex=p);let t=n.exec(e);if(!t){l=!0;break}c={schema:t[2],index:t.index+t[1].length,lastIndex:t.index+t[0].length}}if(c.index<f){c=void 0;continue}if(m&&c.index>m.index)break;let t=c;c=void 0;let r=this.testSchemaAt(e,t.schema,t.lastIndex);if(r){h={schema:t.schema,index:t.index,lastIndex:t.lastIndex+r};break}}let g=h;if((!g||s&&(s.index<g.index||s.index===g.index&&s.lastIndex>g.lastIndex))&&(g=s),(!g||o&&(o.index<g.index||o.index===g.index&&o.lastIndex>g.lastIndex))&&(g=o),!g)break;g===s?s=void 0:g===o&&(o=void 0);let _=new Ic(e,g.schema,g.index,g.lastIndex);_.schema?this.__schemas__[_.schema].normalize(_,this):this.normalize(_),t.push(_),f=g.lastIndex}return t.length?t:null}matchAtStart(e){if(!e.length)return null;let t=this.re.get_schema_at_start().exec(e);if(!t)return null;let n=this.testSchemaAt(e,t[2],t[0].length);if(!n)return null;let r=new Ic(e,t[2],t.index+t[1].length,t.index+t[0].length+n);return this.__schemas__[r.schema].normalize(r,this),r}tlds(e,t=!1){return e=Array.isArray(e)?e:[e],t?this.__opts__.tlds=this.__opts__.tlds.concat(e):this.__opts__.tlds=e,this.re.set({...this.__opts__,schema_names:Object.keys(this.__schemas__)}),this}normalize(e){e.schema||(e.url=`http://${e.url}`),e.schema===`mailto:`&&!/^mailto:/i.test(e.url)&&(e.url=`mailto:${e.url}`)}},Rc=2147483647,zc=36,Bc=1,Vc=26,Hc=38,Uc=700,Wc=72,Gc=128,Kc=`-`,qc=/^xn--/,Jc=/[^\0-\x7F]/,Yc=/[\x2E\u3002\uFF0E\uFF61]/g,Xc={overflow:`Overflow: input needs wider integers to process`,"not-basic":`Illegal input >= 0x80 (not a basic code point)`,"invalid-input":`Invalid input`},Zc=35,Qc=Math.floor,$c=String.fromCharCode;function el(e){throw RangeError(Xc[e])}function tl(e,t){let n=[],r=e.length;for(;r--;)n[r]=t(e[r]);return n}function nl(e,t){let n=e.split(`@`),r=``;n.length>1&&(r=n[0]+`@`,e=n[1]),e=e.replace(Yc,`.`);let i=tl(e.split(`.`),t).join(`.`);return r+i}function rl(e){let t=[],n=0,r=e.length;for(;n<r;){let i=e.charCodeAt(n++);if(i>=55296&&i<=56319&&n<r){let r=e.charCodeAt(n++);(r&64512)==56320?t.push(((i&1023)<<10)+(r&1023)+65536):(t.push(i),n--)}else t.push(i)}return t}var il=e=>String.fromCodePoint(...e),al=function(e){return e>=48&&e<58?26+(e-48):e>=65&&e<91?e-65:e>=97&&e<123?e-97:zc},ol=function(e,t){return e+22+75*(e<26)-((t!=0)<<5)},sl=function(e,t,n){let r=0;for(e=n?Qc(e/Uc):e>>1,e+=Qc(e/t);e>455;r+=zc)e=Qc(e/Zc);return Qc(r+36*e/(e+Hc))},cl=function(e){let t=[],n=e.length,r=0,i=Gc,a=Wc,o=e.lastIndexOf(Kc);o<0&&(o=0);for(let n=0;n<o;++n)e.charCodeAt(n)>=128&&el(`not-basic`),t.push(e.charCodeAt(n));for(let s=o>0?o+1:0;s<n;){let o=r;for(let t=1,i=zc;;i+=zc){s>=n&&el(`invalid-input`);let o=al(e.charCodeAt(s++));o>=zc&&el(`invalid-input`),o>Qc((Rc-r)/t)&&el(`overflow`),r+=o*t;let c=i<=a?Bc:i>=a+Vc?Vc:i-a;if(o<c)break;let l=zc-c;t>Qc(Rc/l)&&el(`overflow`),t*=l}let c=t.length+1;a=sl(r-o,c,o==0),Qc(r/c)>Rc-i&&el(`overflow`),i+=Qc(r/c),r%=c,t.splice(r++,0,i)}return String.fromCodePoint(...t)},ll=function(e){let t=[];e=rl(e);let n=e.length,r=Gc,i=0,a=Wc;for(let n of e)n<128&&t.push($c(n));let o=t.length,s=o;for(o&&t.push(Kc);s<n;){let n=Rc;for(let t of e)t>=r&&t<n&&(n=t);let c=s+1;n-r>Qc((Rc-i)/c)&&el(`overflow`),i+=(n-r)*c,r=n;for(let n of e)if(n<r&&++i>Rc&&el(`overflow`),n===r){let e=i;for(let n=zc;;n+=zc){let r=n<=a?Bc:n>=a+Vc?Vc:n-a;if(e<r)break;let i=e-r,o=zc-r;t.push($c(ol(r+i%o,0))),e=Qc(i/o)}t.push($c(ol(e,0))),a=sl(i,c,s===o),i=0,++s}++i,++r}return t.join(``)},ul={version:`2.3.1`,ucs2:{decode:rl,encode:il},decode:cl,encode:ll,toASCII:function(e){return nl(e,function(e){return Jc.test(e)?`xn--`+ll(e):e})},toUnicode:function(e){return nl(e,function(e){return qc.test(e)?cl(e.slice(4).toLowerCase()):e})}},dl=Object.defineProperty,fl=(e,t)=>{let n={};for(var r in e)dl(n,r,{get:e[r],enumerable:!0});return t||dl(n,Symbol.toStringTag,{value:`Module`}),n},pl=fl({arrayReplaceAt:()=>hl,asciiTrim:()=>Ll,callable:()=>ml,escapeHtml:()=>Ol,escapeRE:()=>Al,fromCodePoint:()=>_l,isMdAsciiPunct:()=>Pl,isPunctChar:()=>Ml,isPunctCharCode:()=>Nl,isSpace:()=>Z,isValidEntityCode:()=>gl,isWhiteSpace:()=>jl,lib:()=>Rl,normalizeReference:()=>Fl,unescapeAll:()=>Cl,unescapeMd:()=>Sl});function ml(e){let t=function(...n){return Reflect.construct(e,n,new.target&&new.target!==t?new.target:e)};return Object.defineProperty(t,"name",{value:e.name}),Object.setPrototypeOf(t,e),t.prototype=e.prototype,t}function hl(e,t,n){return[].concat(e.slice(0,t),n,e.slice(t+1))}function gl(e){return!(e>=55296&&e<=57343||e>=64976&&e<=65007||(e&65535)==65535||(e&65535)==65534||e>=0&&e<=8||e===11||e>=14&&e<=31||e>=127&&e<=159||e>1114111)}function _l(e){if(e>65535){e-=65536;let t=55296+(e>>10),n=56320+(e&1023);return String.fromCharCode(t,n)}return String.fromCharCode(e)}var vl=/\\([!"#$%&'()*+,\-./:;<=>?@[\\\]^_`{|}~])/g,yl=RegExp(`${vl.source}|&([a-z#][a-z0-9]{1,31});`,`gi`),bl=/^#((?:x[a-f0-9]{1,8}|[0-9]{1,8}))$/i;function xl(e,t){if(t.charCodeAt(0)===35&&bl.test(t)){let n=t[1].toLowerCase()===`x`?parseInt(t.slice(2),16):parseInt(t.slice(1),10);return gl(n)?_l(n):e}let n=Oc(e);return n===e?e:n}function Sl(e){return e.indexOf(`\\`)<0?e:e.replace(vl,`$1`)}function Cl(e){return e.indexOf(`\\`)<0&&e.indexOf(`&`)<0?e:e.replace(yl,function(e,t,n){return t||xl(e,n)})}var wl=/[&<>"]/,Tl=/[&<>"]/g,El={"&":`&amp;`,"<":`&lt;`,">":`&gt;`,'"':`&quot;`};function Dl(e){return El[e]}function Ol(e){return wl.test(e)?e.replace(Tl,Dl):e}var kl=/[.?*+^$[\]\\(){}|-]/g;function Al(e){return e.replace(kl,`\\$&`)}function Z(e){switch(e){case 9:case 32:return!0}return!1}function jl(e){if(e>=8192&&e<=8202)return!0;switch(e){case 9:case 10:case 11:case 12:case 13:case 32:case 160:case 5760:case 8239:case 8287:case 12288:return!0}return!1}function Ml(e){return ec.test(e)||tc.test(e)}function Nl(e){return Ml(_l(e))}function Pl(e){switch(e){case 33:case 34:case 35:case 36:case 37:case 38:case 39:case 40:case 41:case 42:case 43:case 44:case 45:case 46:case 47:case 58:case 59:case 60:case 61:case 62:case 63:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 124:case 125:case 126:return!0;default:return!1}}function Fl(e){return e=e.trim().replace(/\s+/g,` `),e.toLowerCase().toUpperCase()}function Il(e){return e===32||e===9||e===10||e===13}function Ll(e){let t=0;for(;t<e.length&&Il(e.charCodeAt(t));t++);let n=e.length-1;for(;n>=t&&Il(e.charCodeAt(n));n--);return e.slice(t,n+1)}var Rl={mdurl:Ys,ucmicro:Xs};function zl(e,t,n){let r,i,a,o,s=e.posMax,c=e.pos;for(e.pos=t+1,r=1;e.pos<s;){if(a=e.src.charCodeAt(e.pos),a===93&&(r--,r===0)){i=!0;break}if(o=e.pos,e.md.inline.skipToken(e),a===91){if(o===e.pos-1)r++;else if(n)return e.pos=c,-1}}let l=-1;return i&&(l=e.pos),e.pos=c,l}function Bl(e,t,n){let r,i=t,a={ok:!1,pos:0,str:``};if(e.charCodeAt(i)===60){for(i++;i<n;){if(r=e.charCodeAt(i),r===10||r===60)return a;if(r===62)return a.pos=i+1,a.str=Cl(e.slice(t+1,i)),a.ok=!0,a;r===92&&i+1<n?i+=2:i++}return a}let o=0;for(;i<n&&(r=e.charCodeAt(i),!(r===32||r<32||r===127));)if(r===92&&i+1<n){if(e.charCodeAt(i+1)===32){i++;continue}i+=2}else{if(r===40&&(o++,o>32))return a;if(r===41){if(o===0)break;o--}i++}return t===i||o!==0||(a.str=Cl(e.slice(t,i)),a.pos=i,a.ok=!0),a}function Vl(e,t,n,r){let i,a=t,o={ok:!1,can_continue:!1,pos:0,str:``,marker:0};if(r)o.str=r.str,o.marker=r.marker;else{if(a>=n)return o;let r=e.charCodeAt(a);if(r!==34&&r!==39&&r!==40)return o;t++,a++,r===40&&(r=41),o.marker=r}for(;a<n;){if(i=e.charCodeAt(a),i===o.marker)return o.pos=a+1,o.str+=Cl(e.slice(t,a)),o.ok=!0,o;if(i===40&&o.marker===41)return o;i===92&&a+1<n&&a++,a++}return o.can_continue=!0,o.str+=Cl(e.slice(t,a)),o}var Hl=fl({parseLinkDestination:()=>Bl,parseLinkLabel:()=>zl,parseLinkTitle:()=>Vl});function Ul(e){"@babel/helpers - typeof";return Ul=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},Ul(e)}function Wl(e,t){if(Ul(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(Ul(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function Gl(e){var t=Wl(e,`string`);return Ul(t)==`symbol`?t:t+``}function Q(e,t,n){return(t=Gl(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Kl=class{constructor(e,t,n){Q(this,`map`,null),Q(this,`level`,0),Q(this,`children`,null),Q(this,`content`,``),Q(this,`markup`,``),Q(this,`info`,``),Q(this,`block`,!1),Q(this,`hidden`,!1),this.type=e,this.tag=t,this.attrs=null,this.nesting=n,this.meta=null}attrIndex(e){if(!this.attrs)return-1;let t=this.attrs;for(let n=0,r=t.length;n<r;n++)if(t[n][0]===e)return n;return-1}attrPush(e){this.attrs?this.attrs.push(e):this.attrs=[e]}attrSet(e,t){let n=this.attrIndex(e),r=[e,t];n<0?this.attrPush(r):this.attrs[n]=r}attrGet(e){let t=this.attrIndex(e),n=null;return t>=0&&(n=this.attrs[t][1]),n}attrJoin(e,t){let n=this.attrIndex(e);n<0?this.attrPush([e,t]):this.attrs[n][1]=`${this.attrs[n][1]} ${t}`}},ql=class{constructor(){Q(this,`__rules__`,[]),Q(this,`__cache__`,null)}__find__(e){for(let t=0;t<this.__rules__.length;t++)if(this.__rules__[t].name===e)return t;return-1}__compile__(){let e=new Set;this.__rules__.forEach(t=>{t.enabled&&t.alt.forEach(t=>{t&&e.add(t)})}),this.__cache__=Object.create(null),this.__cache__[``]=[],this.__rules__.forEach(e=>{e.enabled&&this.__cache__[``].push(e.fn)}),e.forEach(e=>{this.__cache__[e]=[],this.__rules__.forEach(t=>{t.enabled&&t.alt.indexOf(e)>=0&&this.__cache__[e].push(t.fn)})})}at(e,t,n={}){let r=this.__find__(e);if(r===-1)throw Error(`Parser rule not found: ${e}`);this.__rules__[r].fn=t,this.__rules__[r].alt=n.alt||[],this.__cache__=null}before(e,t,n,r={}){let i=this.__find__(e);if(i===-1)throw Error(`Parser rule not found: ${e}`);this.__rules__.splice(i,0,{name:t,enabled:!0,fn:n,alt:r.alt||[]}),this.__cache__=null}after(e,t,n,r={}){let i=this.__find__(e);if(i===-1)throw Error(`Parser rule not found: ${e}`);this.__rules__.splice(i+1,0,{name:t,enabled:!0,fn:n,alt:r.alt||[]}),this.__cache__=null}push(e,t,n={}){this.__rules__.push({name:e,enabled:!0,fn:t,alt:n.alt||[]}),this.__cache__=null}enable(e,t=!1){Array.isArray(e)||(e=[e]);let n=[];return e.forEach(e=>{let r=this.__find__(e);if(r<0){if(t)return;throw Error(`Rules manager: invalid rule name ${e}`)}this.__rules__[r].enabled=!0,n.push(e)}),this.__cache__=null,n}enableOnly(e,t=!1){Array.isArray(e)||(e=[e]),this.__rules__.forEach(e=>{e.enabled=!1}),this.enable(e,t)}disable(e,t=!1){Array.isArray(e)||(e=[e]);let n=[];return e.forEach(e=>{let r=this.__find__(e);if(r<0){if(t)return;throw Error(`Rules manager: invalid rule name ${e}`)}this.__rules__[r].enabled=!1,n.push(e)}),this.__cache__=null,n}getRules(e){return this.__cache__||this.__compile__(),this.__cache__[e]||[]}},Jl={};Jl.code_inline=function(e,t,n,r,i){let a=e[t];return`<code${i.renderAttrs(a)}>${Ol(a.content)}</code>`},Jl.code_block=function(e,t,n,r,i){let a=e[t];return`<pre${i.renderAttrs(a)}><code>${Ol(e[t].content)}</code></pre>\n`},Jl.fence=function(e,t,n,r,i){let a=e[t],o=a.info?Cl(a.info).trim():``,s=``,c=``;if(o){let e=o.split(/(\s+)/g);s=e[0],c=e.slice(2).join(``)}let l;if(l=n.highlight&&n.highlight(a.content,s,c)||Ol(a.content),l.indexOf(`<pre`)===0)return l+`
@@ -17,11 +17,11 @@ https://github.com/highlightjs/highlight.js/issues/2277`),i=e,r=t),n===void 0&&(
17
17
  `),1;if(re>1e5&&re>r.index*3)throw Error(`potential infinite loop, way more iterations than matches`);return j+=a,a.length}let E=ne(e);if(!E)throw ve(s.replace(`{}`,e)),Error(`Unknown language: "`+e+`"`);let D=De(E),O=``,k=a||D,te={},A=new l.__emitter(l);w();let j=``,M=0,N=0,re=0,ie=!1;try{if(E.__emitTokens)E.__emitTokens(n,A);else{for(k.matcher.considerAll();;){re++,ie?ie=!1:k.matcher.considerAll(),k.matcher.lastIndex=N;let e=k.matcher.exec(n);if(!e)break;let t=T(n.substring(N,e.index),e);N=e.index+t}T(n.substring(N))}return A.finalize(),O=A.toHTML(),{language:e,value:O,relevance:M,illegal:!1,_emitter:A,_top:k}}catch(t){if(t.message&&t.message.includes(`Illegal`))return{language:e,value:je(n),illegal:!0,relevance:0,_illegalBy:{message:t.message,index:N,context:n.slice(N-100,N+100),mode:t.mode,resultSoFar:O},_emitter:A};if(o)return{language:e,value:je(n),illegal:!1,relevance:0,errorRaised:t,_emitter:A,_top:k};throw t}}function b(e){let t={value:je(e),illegal:!1,relevance:0,_top:c,_emitter:new l.__emitter(l)};return t._emitter.addText(e),t}function S(e,n){n=n||l.languages||Object.keys(t);let r=b(e),i=n.filter(ne).filter(M).map(t=>v(t,e,!1));i.unshift(r);let[a,o]=i.sort((e,t)=>{if(e.relevance!==t.relevance)return t.relevance-e.relevance;if(e.language&&t.language){if(ne(e.language).supersetOf===t.language)return 1;if(ne(t.language).supersetOf===e.language)return-1}return 0}),s=a;return s.secondBest=o,s}function C(e,t,n){let r=t&&i[t]||n;e.classList.add(`hljs`),e.classList.add(`language-${r}`)}function w(e){let t=null,n=d(e);if(u(n))return;if(P(`before:highlightElement`,{el:e,language:n}),e.dataset.highlighted){console.log("Element previously highlighted. To highlight again, first unset `dataset.highlighted`.",e);return}if(e.children.length>0&&(l.ignoreUnescapedHTML||(console.warn(`One of your code blocks includes unescaped HTML. This is a potentially serious security risk.`),console.warn(`https://github.com/highlightjs/highlight.js/wiki/security`),console.warn(`The element with unescaped HTML:`),console.warn(e)),l.throwUnescapedHTML))throw new Ae(`One of your code blocks includes unescaped HTML.`,e.innerHTML);t=e;let r=t.textContent,i=n?p(r,{language:n,ignoreIllegals:!0}):S(r);e.innerHTML=i.value,e.dataset.highlighted=`yes`,C(e,n,i.language),e.result={language:i.language,re:i.relevance,relevance:i.relevance},i.secondBest&&(e.secondBest={language:i.secondBest.language,relevance:i.secondBest.relevance}),P(`after:highlightElement`,{el:e,result:i,text:r})}function ee(e){l=Me(l,e)}let T=()=>{O(),be(`10.6.0`,`initHighlighting() deprecated. Use highlightAll() now.`)};function E(){O(),be(`10.6.0`,`initHighlightingOnLoad() deprecated. Use highlightAll() now.`)}let D=!1;function O(){function e(){O()}document.readyState===`loading`?(D||window.addEventListener(`DOMContentLoaded`,e,!1),D=!0):document.querySelectorAll(l.cssSelector).forEach(w)}function k(n,r){let i=null;try{i=r(e)}catch(e){if(ve(`Language definition for '{}' could not be registered.`.replace(`{}`,n)),o)ve(e);else throw e;i=c}i.name||(i.name=n),t[n]=i,i.rawDefinition=r.bind(null,e),i.aliases&&j(i.aliases,{languageName:n})}function te(e){delete t[e];for(let t of Object.keys(i))i[t]===e&&delete i[t]}function A(){return Object.keys(t)}function ne(e){return e=(e||``).toLowerCase(),t[e]||t[i[e]]}function j(e,{languageName:t}){typeof e==`string`&&(e=[e]),e.forEach(e=>{i[e.toLowerCase()]=t})}function M(e){let t=ne(e);return t&&!t.disableAutodetect}function N(e){e[`before:highlightBlock`]&&!e[`before:highlightElement`]&&(e[`before:highlightElement`]=t=>{e[`before:highlightBlock`](Object.assign({block:t.el},t))}),e[`after:highlightBlock`]&&!e[`after:highlightElement`]&&(e[`after:highlightElement`]=t=>{e[`after:highlightBlock`](Object.assign({block:t.el},t))})}function re(e){N(e),a.push(e)}function ie(e){let t=a.indexOf(e);t!==-1&&a.splice(t,1)}function P(e,t){let n=e;a.forEach(function(e){e[n]&&e[n](t)})}function oe(e){return be(`10.7.0`,`highlightBlock will be removed entirely in v12.0`),be(`10.7.0`,`Please use highlightElement now.`),w(e)}Object.assign(e,{highlight:p,highlightAuto:S,highlightAll:O,highlightElement:w,highlightBlock:oe,configure:ee,initHighlighting:T,initHighlightingOnLoad:E,registerLanguage:k,unregisterLanguage:te,listLanguages:A,getLanguage:ne,registerAliases:j,autoDetection:M,inherit:Me,addPlugin:re,removePlugin:ie}),e.debugMode=function(){o=!1},e.safeMode=function(){o=!0},e.versionString=ke,e.regex={concat:_,lookahead:m,either:y,optional:g,anyNumberOfTimes:h};for(let e in ae)typeof ae[e]==`object`&&n(ae[e]);return Object.assign(e,ae),e},Fe=Pe({});Fe.newInstance=()=>Pe({}),t.exports=Fe,Fe.HighlightJS=Fe,Fe.default=Fe}))()).default;function Ud(e){let t=e.regex,n={},r={begin:/\$\{/,end:/\}/,contains:[`self`,{begin:/:-/,contains:[n]}]};Object.assign(n,{className:`variable`,variants:[{begin:t.concat(/\$[\w\d#@][\w\d_]*/,`(?![\\w\\d])(?![$])`)},r]});let i={className:`subst`,begin:/\$\(/,end:/\)/,contains:[e.BACKSLASH_ESCAPE]},a=e.inherit(e.COMMENT(),{match:[/(^|\s)/,/#.*$/],scope:{2:`comment`}}),o={begin:/<<-?\s*(?=\w+)/,starts:{contains:[e.END_SAME_AS_BEGIN({begin:/(\w+)/,end:/(\w+)/,className:`string`})]}},s={className:`string`,begin:/"/,end:/"/,contains:[e.BACKSLASH_ESCAPE,n,i]};i.contains.push(s);let c={match:/\\"/},l={className:`string`,begin:/'/,end:/'/},u={match:/\\'/},d={begin:/\$?\(\(/,end:/\)\)/,contains:[{begin:/\d+#[0-9a-f]+/,className:`number`},e.NUMBER_MODE,n]},f=e.SHEBANG({binary:`(${[`fish`,`bash`,`zsh`,`sh`,`csh`,`ksh`,`tcsh`,`dash`,`scsh`].join(`|`)})`,relevance:10}),p={className:`function`,begin:/\w[\w\d_]*\s*\(\s*\)\s*\{/,returnBegin:!0,contains:[e.inherit(e.TITLE_MODE,{begin:/\w[\w\d_]*/})],relevance:0},m=[`if`,`then`,`else`,`elif`,`fi`,`time`,`for`,`while`,`until`,`in`,`do`,`done`,`case`,`esac`,`coproc`,`function`,`select`],h=[`true`,`false`],g={match:/(\/[a-z._-]+)+/},_=[`break`,`cd`,`continue`,`eval`,`exec`,`exit`,`export`,`getopts`,`hash`,`pwd`,`readonly`,`return`,`shift`,`test`,`times`,`trap`,`umask`,`unset`],v=[`alias`,`bind`,`builtin`,`caller`,`command`,`declare`,`echo`,`enable`,`help`,`let`,`local`,`logout`,`mapfile`,`printf`,`read`,`readarray`,`source`,`sudo`,`type`,`typeset`,`ulimit`,`unalias`],y=`autoload.bg.bindkey.bye.cap.chdir.clone.comparguments.compcall.compctl.compdescribe.compfiles.compgroups.compquote.comptags.comptry.compvalues.dirs.disable.disown.echotc.echoti.emulate.fc.fg.float.functions.getcap.getln.history.integer.jobs.kill.limit.log.noglob.popd.print.pushd.pushln.rehash.sched.setcap.setopt.stat.suspend.ttyctl.unfunction.unhash.unlimit.unsetopt.vared.wait.whence.where.which.zcompile.zformat.zftp.zle.zmodload.zparseopts.zprof.zpty.zregexparse.zsocket.zstyle.ztcp`.split(`.`),b=`chcon.chgrp.chown.chmod.cp.dd.df.dir.dircolors.ln.ls.mkdir.mkfifo.mknod.mktemp.mv.realpath.rm.rmdir.shred.sync.touch.truncate.vdir.b2sum.base32.base64.cat.cksum.comm.csplit.cut.expand.fmt.fold.head.join.md5sum.nl.numfmt.od.paste.ptx.pr.sha1sum.sha224sum.sha256sum.sha384sum.sha512sum.shuf.sort.split.sum.tac.tail.tr.tsort.unexpand.uniq.wc.arch.basename.chroot.date.dirname.du.echo.env.expr.factor.groups.hostid.id.link.logname.nice.nohup.nproc.pathchk.pinky.printenv.printf.pwd.readlink.runcon.seq.sleep.stat.stdbuf.stty.tee.test.timeout.tty.uname.unlink.uptime.users.who.whoami.yes`.split(`.`);return{name:`Bash`,aliases:[`sh`,`zsh`],keywords:{$pattern:/\b[a-z][a-z0-9._-]+\b/,keyword:m,literal:h,built_in:[..._,...v,`set`,`shopt`,...y,...b]},contains:[f,e.SHEBANG(),p,d,a,o,g,s,c,l,u,n]}}var Wd=e=>({IMPORTANT:{scope:`meta`,begin:`!important`},BLOCK_COMMENT:e.C_BLOCK_COMMENT_MODE,HEXCOLOR:{scope:`number`,begin:/#(([0-9a-fA-F]{3,4})|(([0-9a-fA-F]{2}){3,4}))\b/},UNICODE_RANGE:{scope:`number`,begin:/\b[Uu]\+[0-9A-Fa-f][0-9A-Fa-f?]{0,5}(-[0-9A-Fa-f][0-9A-Fa-f]{0,5})?/},FUNCTION_DISPATCH:{className:`built_in`,begin:/[\w-]+(?=\()/},ATTRIBUTE_SELECTOR_MODE:{scope:`selector-attr`,begin:/\[/,end:/\]/,illegal:`$`,contains:[e.APOS_STRING_MODE,e.QUOTE_STRING_MODE]},CSS_NUMBER_MODE:{scope:`number`,begin:e.NUMBER_RE+`(%|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc|px|deg|grad|rad|turn|s|ms|Hz|kHz|dpi|dpcm|dppx)?`,relevance:0},CSS_VARIABLE:{className:`attr`,begin:/--[A-Za-z_][A-Za-z0-9_-]*/}}),Gd=`a.abbr.address.article.aside.audio.b.blockquote.body.button.canvas.caption.cite.code.dd.del.details.dfn.div.dl.dt.em.fieldset.figcaption.figure.footer.form.h1.h2.h3.h4.h5.h6.header.hgroup.html.i.iframe.img.input.ins.kbd.label.legend.li.main.mark.menu.nav.object.ol.optgroup.option.p.picture.q.quote.samp.section.select.source.span.strong.summary.sup.table.tbody.td.textarea.tfoot.th.thead.time.tr.ul.var.video`.split(`.`),Kd=`defs.g.marker.mask.pattern.svg.switch.symbol.feBlend.feColorMatrix.feComponentTransfer.feComposite.feConvolveMatrix.feDiffuseLighting.feDisplacementMap.feFlood.feGaussianBlur.feImage.feMerge.feMorphology.feOffset.feSpecularLighting.feTile.feTurbulence.linearGradient.radialGradient.stop.circle.ellipse.image.line.path.polygon.polyline.rect.text.use.textPath.tspan.foreignObject.clipPath`.split(`.`),qd=[...Gd,...Kd],Jd=`any-hover.any-pointer.aspect-ratio.color.color-gamut.color-index.device-aspect-ratio.device-height.device-width.display-mode.forced-colors.grid.height.hover.inverted-colors.monochrome.orientation.overflow-block.overflow-inline.pointer.prefers-color-scheme.prefers-contrast.prefers-reduced-motion.prefers-reduced-transparency.resolution.scan.scripting.update.width.min-width.max-width.min-height.max-height`.split(`.`).sort().reverse(),Yd=`active.any-link.blank.checked.current.default.defined.dir.disabled.drop.empty.enabled.first.first-child.first-of-type.fullscreen.future.focus.focus-visible.focus-within.has.host.host-context.hover.indeterminate.in-range.invalid.is.lang.last-child.last-of-type.left.link.local-link.not.nth-child.nth-col.nth-last-child.nth-last-col.nth-last-of-type.nth-of-type.only-child.only-of-type.optional.out-of-range.past.placeholder-shown.read-only.read-write.required.right.root.scope.target.target-within.user-invalid.valid.visited.where`.split(`.`).sort().reverse(),Xd=[`after`,`backdrop`,`before`,`cue`,`cue-region`,`first-letter`,`first-line`,`grammar-error`,`marker`,`part`,`placeholder`,`selection`,`slotted`,`spelling-error`].sort().reverse(),Zd=`accent-color.align-content.align-items.align-self.alignment-baseline.all.anchor-name.animation.animation-composition.animation-delay.animation-direction.animation-duration.animation-fill-mode.animation-iteration-count.animation-name.animation-play-state.animation-range.animation-range-end.animation-range-start.animation-timeline.animation-timing-function.appearance.aspect-ratio.backdrop-filter.backface-visibility.background.background-attachment.background-blend-mode.background-clip.background-color.background-image.background-origin.background-position.background-position-x.background-position-y.background-repeat.background-size.baseline-shift.block-size.border.border-block.border-block-color.border-block-end.border-block-end-color.border-block-end-style.border-block-end-width.border-block-start.border-block-start-color.border-block-start-style.border-block-start-width.border-block-style.border-block-width.border-bottom.border-bottom-color.border-bottom-left-radius.border-bottom-right-radius.border-bottom-style.border-bottom-width.border-collapse.border-color.border-end-end-radius.border-end-start-radius.border-image.border-image-outset.border-image-repeat.border-image-slice.border-image-source.border-image-width.border-inline.border-inline-color.border-inline-end.border-inline-end-color.border-inline-end-style.border-inline-end-width.border-inline-start.border-inline-start-color.border-inline-start-style.border-inline-start-width.border-inline-style.border-inline-width.border-left.border-left-color.border-left-style.border-left-width.border-radius.border-right.border-right-color.border-right-style.border-right-width.border-spacing.border-start-end-radius.border-start-start-radius.border-style.border-top.border-top-color.border-top-left-radius.border-top-right-radius.border-top-style.border-top-width.border-width.bottom.box-align.box-decoration-break.box-direction.box-flex.box-flex-group.box-lines.box-ordinal-group.box-orient.box-pack.box-shadow.box-sizing.break-after.break-before.break-inside.caption-side.caret-color.clear.clip.clip-path.clip-rule.color.color-interpolation.color-interpolation-filters.color-profile.color-rendering.color-scheme.column-count.column-fill.column-gap.column-rule.column-rule-color.column-rule-style.column-rule-width.column-span.column-width.columns.contain.contain-intrinsic-block-size.contain-intrinsic-height.contain-intrinsic-inline-size.contain-intrinsic-size.contain-intrinsic-width.container.container-name.container-type.content.content-visibility.corner-bottom-left-shape.corner-bottom-right-shape.corner-shape.corner-top-left-shape.corner-top-right-shape.counter-increment.counter-reset.counter-set.cue.cue-after.cue-before.cursor.cx.cy.direction.display.dominant-baseline.empty-cells.enable-background.field-sizing.fill.fill-opacity.fill-rule.filter.flex.flex-basis.flex-direction.flex-flow.flex-grow.flex-shrink.flex-wrap.float.flood-color.flood-opacity.flow.font.font-display.font-family.font-feature-settings.font-kerning.font-language-override.font-optical-sizing.font-palette.font-size.font-size-adjust.font-smooth.font-smoothing.font-stretch.font-style.font-synthesis.font-synthesis-position.font-synthesis-small-caps.font-synthesis-style.font-synthesis-weight.font-variant.font-variant-alternates.font-variant-caps.font-variant-east-asian.font-variant-emoji.font-variant-ligatures.font-variant-numeric.font-variant-position.font-variation-settings.font-weight.forced-color-adjust.gap.glyph-orientation-horizontal.glyph-orientation-vertical.grid.grid-area.grid-auto-columns.grid-auto-flow.grid-auto-rows.grid-column.grid-column-end.grid-column-start.grid-gap.grid-row.grid-row-end.grid-row-start.grid-template.grid-template-areas.grid-template-columns.grid-template-rows.hanging-punctuation.height.hyphenate-character.hyphenate-limit-chars.hyphens.icon.image-orientation.image-rendering.image-resolution.ime-mode.initial-letter.initial-letter-align.inline-size.inset.inset-area.inset-block.inset-block-end.inset-block-start.inset-inline.inset-inline-end.inset-inline-start.isolation.justify-content.justify-items.justify-self.kerning.left.letter-spacing.lighting-color.line-break.line-height.line-height-step.list-style.list-style-image.list-style-position.list-style-type.margin.margin-block.margin-block-end.margin-block-start.margin-bottom.margin-inline.margin-inline-end.margin-inline-start.margin-left.margin-right.margin-top.margin-trim.marker.marker-end.marker-mid.marker-start.marks.mask.mask-border.mask-border-mode.mask-border-outset.mask-border-repeat.mask-border-slice.mask-border-source.mask-border-width.mask-clip.mask-composite.mask-image.mask-mode.mask-origin.mask-position.mask-repeat.mask-size.mask-type.masonry-auto-flow.math-depth.math-shift.math-style.max-block-size.max-height.max-inline-size.max-width.min-block-size.min-height.min-inline-size.min-width.mix-blend-mode.nav-down.nav-index.nav-left.nav-right.nav-up.none.normal.object-fit.object-position.offset.offset-anchor.offset-distance.offset-path.offset-position.offset-rotate.opacity.order.orphans.outline.outline-color.outline-offset.outline-style.outline-width.overflow.overflow-anchor.overflow-block.overflow-clip-margin.overflow-inline.overflow-wrap.overflow-x.overflow-y.overlay.overscroll-behavior.overscroll-behavior-block.overscroll-behavior-inline.overscroll-behavior-x.overscroll-behavior-y.padding.padding-block.padding-block-end.padding-block-start.padding-bottom.padding-inline.padding-inline-end.padding-inline-start.padding-left.padding-right.padding-top.page.page-break-after.page-break-before.page-break-inside.paint-order.pause.pause-after.pause-before.perspective.perspective-origin.place-content.place-items.place-self.pointer-events.position.position-anchor.position-visibility.print-color-adjust.quotes.r.resize.rest.rest-after.rest-before.right.rotate.row-gap.ruby-align.ruby-position.scale.scroll-behavior.scroll-margin.scroll-margin-block.scroll-margin-block-end.scroll-margin-block-start.scroll-margin-bottom.scroll-margin-inline.scroll-margin-inline-end.scroll-margin-inline-start.scroll-margin-left.scroll-margin-right.scroll-margin-top.scroll-padding.scroll-padding-block.scroll-padding-block-end.scroll-padding-block-start.scroll-padding-bottom.scroll-padding-inline.scroll-padding-inline-end.scroll-padding-inline-start.scroll-padding-left.scroll-padding-right.scroll-padding-top.scroll-snap-align.scroll-snap-stop.scroll-snap-type.scroll-timeline.scroll-timeline-axis.scroll-timeline-name.scrollbar-color.scrollbar-gutter.scrollbar-width.shape-image-threshold.shape-margin.shape-outside.shape-rendering.speak.speak-as.src.stop-color.stop-opacity.stroke.stroke-dasharray.stroke-dashoffset.stroke-linecap.stroke-linejoin.stroke-miterlimit.stroke-opacity.stroke-width.tab-size.table-layout.text-align.text-align-all.text-align-last.text-anchor.text-combine-upright.text-decoration.text-decoration-color.text-decoration-line.text-decoration-skip.text-decoration-skip-ink.text-decoration-style.text-decoration-thickness.text-emphasis.text-emphasis-color.text-emphasis-position.text-emphasis-style.text-indent.text-justify.text-orientation.text-overflow.text-rendering.text-shadow.text-size-adjust.text-transform.text-underline-offset.text-underline-position.text-wrap.text-wrap-mode.text-wrap-style.timeline-scope.top.touch-action.transform.transform-box.transform-origin.transform-style.transition.transition-behavior.transition-delay.transition-duration.transition-property.transition-timing-function.translate.unicode-bidi.unicode-range.user-modify.user-select.vector-effect.vertical-align.view-timeline.view-timeline-axis.view-timeline-inset.view-timeline-name.view-transition-name.visibility.voice-balance.voice-duration.voice-family.voice-pitch.voice-range.voice-rate.voice-stress.voice-volume.white-space.white-space-collapse.widows.width.will-change.word-break.word-spacing.word-wrap.writing-mode.x.y.z-index.zoom`.split(`.`).sort().reverse();function Qd(e){let t=e.regex,n=Wd(e),r={begin:/-(webkit|moz|ms|o)-(?=[a-z])/},i=/@-?\w[\w]*(-\w+)*/,a=[e.APOS_STRING_MODE,e.QUOTE_STRING_MODE];return{name:`CSS`,case_insensitive:!0,illegal:/[=|'\$]/,keywords:{keyframePosition:`from to`},classNameAliases:{keyframePosition:`selector-tag`},contains:[n.BLOCK_COMMENT,r,n.CSS_NUMBER_MODE,{className:`selector-id`,begin:/#[A-Za-z0-9_-]+/,relevance:0},{className:`selector-class`,begin:`\\.[a-zA-Z-][a-zA-Z0-9_-]*`,relevance:0},n.ATTRIBUTE_SELECTOR_MODE,{className:`selector-pseudo`,variants:[{begin:`:(`+Yd.join(`|`)+`)`},{begin:`:(:)?(`+Xd.join(`|`)+`)`}]},n.CSS_VARIABLE,{className:`attribute`,begin:`\\b(`+Zd.join(`|`)+`)\\b`},{begin:/:/,end:/[;}{]/,contains:[n.BLOCK_COMMENT,n.HEXCOLOR,n.IMPORTANT,n.CSS_NUMBER_MODE,n.UNICODE_RANGE,...a,{begin:/(url|data-uri)\(/,end:/\)/,relevance:0,keywords:{built_in:`url data-uri`},contains:[...a,{className:`string`,begin:/[^)]/,endsWithParent:!0,excludeEnd:!0}]},n.FUNCTION_DISPATCH]},{begin:t.lookahead(/@/),end:`[{;]`,relevance:0,illegal:/:/,contains:[{className:`keyword`,begin:i},{begin:/\s/,endsWithParent:!0,excludeEnd:!0,relevance:0,keywords:{$pattern:/[a-z-]+/,keyword:`and or not only`,attribute:Jd.join(` `)},contains:[{begin:/[a-z-]+(?=:)/,className:`attribute`},...a,n.CSS_NUMBER_MODE]}]},{className:`selector-tag`,begin:`\\b(`+qd.join(`|`)+`)\\b`}]}}function $d(e){let t=e.regex;return{name:`Diff`,aliases:[`patch`],contains:[{className:`meta`,relevance:10,match:t.either(/^@@ +-\d+,\d+ +\+\d+,\d+ +@@/,/^@@ +-\d+ +\+\d+,\d+ +@@/,/^@@ +-\d+,\d+ +\+\d+ +@@/,/^@@ +-\d+ +\+\d+ +@@/,/^\*\*\* +\d+,\d+ +\*\*\*\*$/,/^--- +\d+,\d+ +----$/)},{className:`comment`,variants:[{begin:t.either(/Index: /,/^index/,/={3,}/,/^-{3}/,/^\*{3} /,/^\+{3}/,/^diff --git/),end:/$/},{match:/^\*{15}$/}]},{className:`addition`,begin:/^\+/,end:/$/},{className:`deletion`,begin:/^-/,end:/$/},{className:`addition`,begin:/^!/,end:/$/}]}}function ef(e){let t={keyword:[`break`,`case`,`chan`,`const`,`continue`,`default`,`defer`,`else`,`fallthrough`,`for`,`func`,`go`,`goto`,`if`,`import`,`interface`,`map`,`package`,`range`,`return`,`select`,`struct`,`switch`,`type`,`var`],type:[`bool`,`byte`,`complex64`,`complex128`,`error`,`float32`,`float64`,`int8`,`int16`,`int32`,`int64`,`string`,`uint8`,`uint16`,`uint32`,`uint64`,`int`,`uint`,`uintptr`,`rune`],literal:[`true`,`false`,`iota`,`nil`],built_in:[`append`,`cap`,`close`,`complex`,`copy`,`imag`,`len`,`make`,`new`,`panic`,`print`,`println`,`real`,`recover`,`delete`]};return{name:`Go`,aliases:[`golang`],keywords:t,illegal:`</`,contains:[e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,{className:`string`,variants:[e.QUOTE_STRING_MODE,e.APOS_STRING_MODE,{begin:"`",end:"`"}]},{className:`number`,variants:[{match:/-?\b0[xX]\.[a-fA-F0-9](_?[a-fA-F0-9])*[pP][+-]?\d(_?\d)*i?/,relevance:0},{match:/-?\b0[xX](_?[a-fA-F0-9])+((\.([a-fA-F0-9](_?[a-fA-F0-9])*)?)?[pP][+-]?\d(_?\d)*)?i?/,relevance:0},{match:/-?\b0[oO](_?[0-7])*i?/,relevance:0},{match:/-?\b0[bB](_?[01])*i?/,relevance:0},{match:/-?\.\d(_?\d)*([eE][+-]?\d(_?\d)*)?i?/,relevance:0},{match:/-?\b\d(_?\d)*(\.(\d(_?\d)*)?)?([eE][+-]?\d(_?\d)*)?i?/,relevance:0}]},{begin:/:=/},{className:`function`,beginKeywords:`func`,end:`\\s*(\\{|$)`,excludeEnd:!0,contains:[e.TITLE_MODE,{className:`params`,begin:/\(/,end:/\)/,endsParent:!0,keywords:t,illegal:/["']/}]}]}}var tf=`[A-Za-z$_][0-9A-Za-z$_]*`,nf=`as.in.of.if.for.while.finally.var.new.function.do.return.void.else.break.catch.instanceof.with.throw.case.default.try.switch.continue.typeof.delete.let.yield.const.class.debugger.async.await.static.import.from.export.extends.using`.split(`.`),rf=[`true`,`false`,`null`,`undefined`,`NaN`,`Infinity`],af=`Object.Function.Boolean.Symbol.Math.Date.Number.BigInt.String.RegExp.Array.Float32Array.Float64Array.Int8Array.Uint8Array.Uint8ClampedArray.Int16Array.Int32Array.Uint16Array.Uint32Array.BigInt64Array.BigUint64Array.Set.Map.WeakSet.WeakMap.ArrayBuffer.SharedArrayBuffer.Atomics.DataView.JSON.Promise.Generator.GeneratorFunction.AsyncFunction.Reflect.Proxy.Intl.WebAssembly`.split(`.`),of=[`Error`,`EvalError`,`InternalError`,`RangeError`,`ReferenceError`,`SyntaxError`,`TypeError`,`URIError`],sf=[`setInterval`,`setTimeout`,`clearInterval`,`clearTimeout`,`require`,`exports`,`eval`,`isFinite`,`isNaN`,`parseFloat`,`parseInt`,`decodeURI`,`decodeURIComponent`,`encodeURI`,`encodeURIComponent`,`escape`,`unescape`],cf=[`arguments`,`this`,`super`,`console`,`window`,`document`,`localStorage`,`sessionStorage`,`module`,`self`,`global`],lf=[].concat(sf,af,of);function uf(e){let t=e.regex,n=(e,{after:t})=>{let n=`</`+e[0].slice(1);return e.input.indexOf(n,t)!==-1},r=tf,i={begin:`<>`,end:`</>`},a=/<[A-Za-z0-9\\._:-]+\s*\/>/,o={begin:/<[A-Za-z0-9\\._:-]+/,end:/\/[A-Za-z0-9\\._:-]+>|\/>/,isTrulyOpeningTag:(e,t)=>{let r=e[0].length+e.index,i=e.input[r];if(i===`<`||i===`,`){t.ignoreMatch();return}i===`>`&&(n(e,{after:r})||t.ignoreMatch());let a,o=e.input.substring(r);((a=o.match(/^\s*=/))||(a=o.match(/^\s+extends\s+/))&&a.index===0)&&t.ignoreMatch()}},s={$pattern:tf,keyword:nf,literal:rf,built_in:lf,"variable.language":cf},c=`[0-9](_?[0-9])*`,l=`\\.(${c})`,u=`0|[1-9](_?[0-9])*|0[0-7]*[89][0-9]*`,d={className:`number`,variants:[{begin:`(\\b(${u})((${l})|\\.)?|(${l}))[eE][+-]?(${c})\\b`},{begin:`\\b(${u})\\b((${l})\\b|\\.)?|(${l})\\b`},{begin:`\\b(0|[1-9](_?[0-9])*)n\\b`},{begin:`\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*n?\\b`},{begin:`\\b0[bB][0-1](_?[0-1])*n?\\b`},{begin:`\\b0[oO][0-7](_?[0-7])*n?\\b`},{begin:`\\b0[0-7]+n?\\b`}],relevance:0},f={className:`subst`,begin:`\\$\\{`,end:`\\}`,keywords:s,contains:[]},p={begin:".?html`",end:``,starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,f],subLanguage:`xml`}},m={begin:".?css`",end:``,starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,f],subLanguage:`css`}},h={begin:".?gql`",end:``,starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,f],subLanguage:`graphql`}},g={className:`string`,begin:"`",end:"`",contains:[e.BACKSLASH_ESCAPE,f]},_={className:`comment`,variants:[e.COMMENT(/\/\*\*(?!\/)/,`\\*/`,{relevance:0,contains:[{begin:`(?=@[A-Za-z]+)`,relevance:0,contains:[{className:`doctag`,begin:`@[A-Za-z]+`},{className:`type`,begin:`\\{`,end:`\\}`,excludeEnd:!0,excludeBegin:!0,relevance:0},{className:`variable`,begin:r+`(?=\\s*(-)|$)`,endsParent:!0,relevance:0},{begin:/(?=[^\n])\s/,relevance:0}]}]}),e.C_BLOCK_COMMENT_MODE,e.C_LINE_COMMENT_MODE]},v=[e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,p,m,h,g,{match:/\$\d+/},d];f.contains=v.concat({begin:/\{/,end:/\}/,keywords:s,contains:[`self`].concat(v)});let y=[].concat(_,f.contains),b=y.concat([{begin:/(\s*)\(/,end:/\)/,keywords:s,contains:[`self`].concat(y)}]),x={className:`params`,begin:/(\s*)\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:s,contains:b},S={variants:[{match:[/class/,/\s+/,r,/\s+/,/extends/,/\s+/,t.concat(r,`(`,t.concat(/\./,r),`)*`)],scope:{1:`keyword`,3:`title.class`,5:`keyword`,7:`title.class.inherited`}},{match:[/class/,/\s+/,r],scope:{1:`keyword`,3:`title.class`}}]},C={relevance:0,match:t.either(/\bJSON/,/\b[A-Z][a-z]+([A-Z][a-z]*|\d)*/,/\b[A-Z]{2,}([A-Z][a-z]+|\d)+([A-Z][a-z]*)*/,/\b[A-Z]{2,}[a-z]+([A-Z][a-z]+|\d)*([A-Z][a-z]*)*/),className:`title.class`,keywords:{_:[...af,...of]}},w={label:`use_strict`,className:`meta`,relevance:10,begin:/^\s*['"]use (strict|asm)['"]/},ee={variants:[{match:[/function/,/\s+/,r,/(?=\s*\()/]},{match:[/function/,/\s*(?=\()/]}],className:{1:`keyword`,3:`title.function`},label:`func.def`,contains:[x],illegal:/%/},T={relevance:0,match:/\b[A-Z][A-Z_0-9]+\b/,className:`variable.constant`};function E(e){return t.concat(`(?!`,e.join(`|`),`)`)}let D={match:t.concat(/\b/,E([...sf,`super`,`import`,`await`].map(e=>`${e}\\s*\\(`)),r,t.lookahead(/\s*\(/)),className:`title.function`,relevance:0},O={begin:t.concat(/\./,t.lookahead(t.concat(r,/(?![0-9A-Za-z$_(])/))),end:r,excludeBegin:!0,keywords:`prototype`,className:`property`,relevance:0},k={match:[/get|set/,/\s+/,r,/(?=\()/],className:{1:`keyword`,3:`title.function`},contains:[{begin:/\(\)/},x]},te=`(\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)|`+e.UNDERSCORE_IDENT_RE+`)\\s*=>`,A={match:[/const|var|let/,/\s+/,r,/\s*/,/=\s*/,/(async\s*)?/,t.lookahead(te)],keywords:`async`,className:{1:`keyword`,3:`title.function`},contains:[x]};return{name:`JavaScript`,aliases:[`js`,`jsx`,`mjs`,`cjs`],keywords:s,exports:{PARAMS_CONTAINS:b,CLASS_REFERENCE:C},illegal:/#(?![$_A-Za-z])/,contains:[e.SHEBANG({label:`shebang`,binary:`node`,relevance:5}),w,e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,p,m,h,g,_,{match:/\$\d+/},d,C,{scope:`attr`,match:r+t.lookahead(`:`),relevance:0},A,{begin:`(`+e.RE_STARTERS_RE+`|\\b(case|return|throw)\\b)\\s*`,keywords:`return throw case`,relevance:0,contains:[_,e.REGEXP_MODE,{className:`function`,begin:te,returnBegin:!0,end:`\\s*=>`,contains:[{className:`params`,variants:[{begin:e.UNDERSCORE_IDENT_RE,relevance:0},{className:null,begin:/\(\s*\)/,skip:!0},{begin:/(\s*)\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:s,contains:b}]}]},{begin:/,/,relevance:0},{match:/\s+/,relevance:0},{variants:[{begin:i.begin,end:i.end},{match:a},{begin:o.begin,"on:begin":o.isTrulyOpeningTag,end:o.end}],subLanguage:`xml`,contains:[{begin:o.begin,end:o.end,skip:!0,contains:[`self`]}]}]},ee,{beginKeywords:`while if switch catch for`},{begin:`\\b(?!function)`+e.UNDERSCORE_IDENT_RE+`\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)\\s*\\{`,returnBegin:!0,label:`func.def`,contains:[x,e.inherit(e.TITLE_MODE,{begin:r,className:`title.function`})]},{match:/\.\.\./,relevance:0},O,{match:`\\$`+r,relevance:0},{match:[/\bconstructor(?=\s*\()/],className:{1:`title.function`},contains:[x]},D,T,S,k,{match:/\$[(.]/}]}}var df={scope:`number`,match:`([-+]?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)|NaN|[-+]?Infinity`,relevance:0};function ff(e){let t={className:`attr`,begin:/(("(\\.|[^\\"\r\n])*")|('(\\.|[^\\'\r\n])*'))(?=\s*:)/,relevance:1.01},n={match:/[{}[\],:]/,className:`punctuation`,relevance:0},r=[`true`,`false`,`null`],i={scope:`literal`,beginKeywords:r.join(` `)};return{name:`JSON`,aliases:[`jsonc`,`json5`],keywords:{literal:r},contains:[t,n,e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,i,df,e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE],illegal:`\\S`}}function pf(e){let t=e.regex,n={begin:/<\/?[A-Za-z_]/,end:`>`,subLanguage:`xml`,relevance:0},r={match:/^ {0,3}([-*_])[ \t]*(?:\1[ \t]*){2,}$/},i={className:`code`,variants:[{begin:"(`{3,})[^`](.|\\n)*?\\1`*[ ]*"},{begin:`(~{3,})[^~](.|\\n)*?\\1~*[ ]*`},{begin:"```",end:"```+[ ]*$"},{begin:`~~~`,end:`~~~+[ ]*$`},{begin:"`.+?`"},{begin:`(?=^( {4}|\\t))`,contains:[{begin:`^( {4}|\\t)`,end:`(\\n)$`}],relevance:0}]},a={className:`bullet`,begin:`^[ ]*([*+-]|(\\d+\\.))(?=\\s+)`,end:`\\s+`,excludeEnd:!0},o={begin:/^\[[^\n]+\]:/,returnBegin:!0,contains:[{className:`symbol`,begin:/\[/,end:/\]/,excludeBegin:!0,excludeEnd:!0},{className:`link`,begin:/:\s*/,end:/$/,excludeBegin:!0}]},s={variants:[{begin:/\[.+?\]\[.*?\]/,relevance:0},{begin:/\[.+?\]\(((data|javascript|mailto):|(?:http|ftp)s?:\/\/).*?\)/,relevance:2},{begin:t.concat(/\[.+?\]\(/,/[A-Za-z][A-Za-z0-9+.-]*/,/:\/\/.*?\)/),relevance:2},{begin:/\[.+?\]\([./?&#].*?\)/,relevance:1},{begin:/\[.*?\]\(.*?\)/,relevance:0}],returnBegin:!0,contains:[{match:/\[(?=\])/},{className:`string`,relevance:0,begin:`\\[`,end:`\\]`,excludeBegin:!0,returnEnd:!0},{className:`link`,relevance:0,begin:`\\]\\(`,end:`\\)`,excludeBegin:!0,excludeEnd:!0},{className:`symbol`,relevance:0,begin:`\\]\\[`,end:`\\]`,excludeBegin:!0,excludeEnd:!0}]},c={className:`strong`,contains:[],variants:[{begin:/_{2}(?!\s)/,end:/_{2}/},{begin:/\*{2}(?!\s)/,end:/\*{2}/}]},l={className:`emphasis`,contains:[],variants:[{begin:/\*(?![*\s])/,end:/\*/},{begin:/_(?![_\s])/,end:/_/,relevance:0}]},u=e.inherit(c,{contains:[]}),d=e.inherit(l,{contains:[]});c.contains.push(d),l.contains.push(u);let f=[n,s];return[c,l,u,d].forEach(e=>{e.contains=e.contains.concat(f)}),f=f.concat(c,l),{name:`Markdown`,aliases:[`md`,`mkdown`,`mkd`],contains:[{className:`section`,variants:[{begin:`^#{1,6}`,end:`$`,contains:f},{begin:`(?=^.+?\\n[=-]{2,}$)`,contains:[{begin:`^[=-]*$`},{begin:`^`,end:`\\n`,contains:f}]}]},n,a,r,c,l,{className:`quote`,begin:`^>\\s+`,contains:f,end:`$`},i,s,o,{scope:`literal`,match:/&([a-zA-Z0-9]+|#[0-9]{1,7}|#[Xx][0-9a-fA-F]{1,6});/}]}}function mf(e){let t=e.regex,n=/[\p{XID_Start}_]\p{XID_Continue}*/u,r=`and.as.assert.async.await.break.case.class.continue.def.del.elif.else.except.finally.for.from.global.if.import.in.is.lambda.lazy.match.nonlocal|10.not.or.pass.raise.return.try.while.with.yield`.split(`.`),i={$pattern:/[A-Za-z]\w+|__\w+__/,keyword:r,built_in:`__import__.abs.aiter.all.anext.any.ascii.bin.bool.breakpoint.bytearray.bytes.callable.chr.classmethod.compile.complex.delattr.dict.dir.divmod.enumerate.eval.exec.filter.float.format.frozendict.frozenset.getattr.globals.hasattr.hash.help.hex.id.input.int.isinstance.issubclass.iter.len.list.locals.map.max.memoryview.min.next.object.oct.open.ord.pow.print.property.range.repr.reversed.round.sentinel.set.setattr.slice.sorted.staticmethod.str.sum.super.tuple.type.vars.zip`.split(`.`),literal:[`__debug__`,`Ellipsis`,`False`,`None`,`NotImplemented`,`True`],type:[`Any`,`Callable`,`Coroutine`,`Dict`,`List`,`Literal`,`Generic`,`Optional`,`Sequence`,`Set`,`Tuple`,`Type`,`Union`]},a={className:`meta`,begin:/^(>>>|\.\.\.) /},o={className:`subst`,begin:/\{/,end:/\}/,keywords:i,illegal:/#/},s={begin:/\{\{/,relevance:0},c={className:`string`,contains:[e.BACKSLASH_ESCAPE],variants:[{begin:/([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?'''/,end:/'''/,contains:[e.BACKSLASH_ESCAPE,a],relevance:10},{begin:/([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?"""/,end:/"""/,contains:[e.BACKSLASH_ESCAPE,a],relevance:10},{begin:/([fFtT][rR]|[rR][fFtT]|[fFtT])'''/,end:/'''/,contains:[e.BACKSLASH_ESCAPE,a,s,o]},{begin:/([fFtT][rR]|[rR][fFtT]|[fFtT])"""/,end:/"""/,contains:[e.BACKSLASH_ESCAPE,a,s,o]},{begin:/([uU]|[rR])'/,end:/'/,relevance:10},{begin:/([uU]|[rR])"/,end:/"/,relevance:10},{begin:/([bB]|[bB][rR]|[rR][bB])'/,end:/'/},{begin:/([bB]|[bB][rR]|[rR][bB])"/,end:/"/},{begin:/([fFtT][rR]|[rR][fFtT]|[fFtT])'/,end:/'/,contains:[e.BACKSLASH_ESCAPE,s,o]},{begin:/([fFtT][rR]|[rR][fFtT]|[fFtT])"/,end:/"/,contains:[e.BACKSLASH_ESCAPE,s,o]},e.APOS_STRING_MODE,e.QUOTE_STRING_MODE]},l=`[0-9](_?[0-9])*`,u=`(\\b(${l}))?\\.(${l})|\\b(${l})\\.`,d=`\\b|${r.join(`|`)}`,f={className:`number`,relevance:0,variants:[{begin:`(\\b(${l})|(${u}))[eE][+-]?(${l})[jJ]?(?=${d})`},{begin:`(${u})[jJ]?`},{begin:`\\b([1-9](_?[0-9])*|0+(_?0)*)[lLjJ]?(?=${d})`},{begin:`\\b0[bB](_?[01])+[lL]?(?=${d})`},{begin:`\\b0[oO](_?[0-7])+[lL]?(?=${d})`},{begin:`\\b0[xX](_?[0-9a-fA-F])+[lL]?(?=${d})`},{begin:`\\b(${l})[jJ](?=${d})`}]},p={className:`comment`,begin:t.lookahead(/# type:/),end:/$/,keywords:i,contains:[{begin:/# type:/},{begin:/#/,end:/\b\B/,endsWithParent:!0}]},m={className:`params`,variants:[{className:``,begin:/\(\s*\)/,skip:!0},{begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:i,contains:[`self`,a,f,c,e.HASH_COMMENT_MODE]}]};return o.contains=[c,f,a],{name:`Python`,aliases:[`py`,`gyp`,`ipython`],unicodeRegex:!0,keywords:i,illegal:/(<\/|\?)|=>/,contains:[a,f,{scope:`variable.language`,match:/\bself\b/},{beginKeywords:`if`,relevance:0},{match:/\bor\b/,scope:`keyword`},c,p,e.HASH_COMMENT_MODE,{match:[/\bdef/,/\s+/,n],scope:{1:`keyword`,3:`title.function`},contains:[m]},{variants:[{match:[/\bclass/,/\s+/,n,/\s*/,/\(\s*/,n,/\s*\)/]},{match:[/\bclass/,/\s+/,n]}],scope:{1:`keyword`,3:`title.class`,6:`title.class.inherited`}},{className:`meta`,begin:/^[\t ]*@/,end:/(?=#)|$/,contains:[f,m,c]}]}}function hf(e){let t=e.regex,n=/(r#)?/,r=t.concat(n,e.UNDERSCORE_IDENT_RE),i=t.concat(n,e.IDENT_RE),a={scope:`title.function.invoke`,relevance:0,begin:t.concat(/\b/,/(?!(?:let|for|while|if|else|match)\b)/,i,t.lookahead(/\s*\(/))},o=`([ui](8|16|32|64|128|size)|f(16|32|64|128))?`,s=`abstract.as.async.await.become.box.break.const.continue.crate.do.dyn.else.enum.extern.false.final.fn.for.if.impl.in.let.loop.macro.match.mod.move.mut.override.priv.pub.raw.ref.return.self.Self.static.struct.super.trait.true.try.type.typeof.union.unsafe.unsized.use.virtual.where.while.yield`.split(`.`),c=[`true`,`false`,`Some`,`None`,`Ok`,`Err`],l=`drop .Copy.Send.Sized.Sync.Drop.Fn.FnMut.FnOnce.ToOwned.Clone.Debug.PartialEq.PartialOrd.Eq.Ord.AsRef.AsMut.Into.From.Default.Iterator.Extend.IntoIterator.DoubleEndedIterator.ExactSizeIterator.SliceConcatExt.ToString.assert!.assert_eq!.bitflags!.bytes!.cfg!.col!.concat!.concat_idents!.debug_assert!.debug_assert_eq!.env!.eprintln!.panic!.file!.format!.format_args!.include_bytes!.include_str!.line!.local_data_key!.module_path!.option_env!.print!.println!.select!.stringify!.try!.unimplemented!.unreachable!.vec!.write!.writeln!.macro_rules!.assert_ne!.debug_assert_ne!`.split(`.`),u=[`i8`,`i16`,`i32`,`i64`,`i128`,`isize`,`u8`,`u16`,`u32`,`u64`,`u128`,`usize`,`f16`,`f32`,`f64`,`f128`,`str`,`char`,`bool`,`Box`,`Option`,`Result`,`String`,`Vec`];return{name:`Rust`,aliases:[`rs`],keywords:{$pattern:e.IDENT_RE+`!?`,type:u,keyword:s,literal:c,built_in:l},illegal:`</`,contains:[e.C_LINE_COMMENT_MODE,e.COMMENT(`/\\*`,`\\*/`,{contains:[`self`]}),e.inherit(e.QUOTE_STRING_MODE,{begin:/b?"/,illegal:null}),{scope:`symbol`,begin:/'[a-zA-Z_][a-zA-Z0-9_]*(?!')/},{scope:`string`,variants:[{begin:/b?r(#*)"(.|\n)*?"\1(?!#)/},{begin:/b?'/,end:/'/,contains:[{scope:`char.escape`,match:/\\('|"|\\|\w|x\w{2}|u\w{4}|U\w{8})/}]}]},{scope:`number`,variants:[{begin:`\\b0b([01_]+)`+o},{begin:`\\b0o([0-7_]+)`+o},{begin:`\\b0x([A-Fa-f0-9_]+)`+o},{begin:`\\b(\\d[\\d_]*(\\.[0-9_]+)?([eE][+-]?[0-9_]+)?)`+o}],relevance:0},{begin:[/\bsafe/,/\s+/,/extern/],scope:{1:`keyword`,3:`keyword`}},{begin:[/fn/,/\s+/,r],scope:{1:`keyword`,3:`title.function`}},{scope:`meta`,begin:`#!?\\[`,end:`\\]`,contains:[{scope:`string`,begin:/"/,end:/"/,contains:[e.BACKSLASH_ESCAPE]}]},{begin:[/let/,/\s+/,/(?:mut\s+)?/,r],scope:{1:`keyword`,3:`keyword`,4:`variable`}},{begin:[/for/,/\s+/,r,/\s+/,/in/],scope:{1:`keyword`,3:`variable`,5:`keyword`}},{begin:[/type/,/\s+/,r],scope:{1:`keyword`,3:`title.class`}},{begin:[/(?:trait|enum|struct|union|impl|for)/,/\s+/,r],scope:{1:`keyword`,3:`title.class`}},{begin:e.IDENT_RE+`::`,keywords:{keyword:`Self`,built_in:l,type:u}},{scope:`punctuation`,begin:`->`},a]}}function gf(e){return{name:`Shell Session`,aliases:[`console`,`shellsession`],contains:[{className:`meta.prompt`,begin:/^\s{0,3}[./~\w\d[\]()@-]*[>%$#][ ]?/,starts:{end:/[^\\](?=\s*$)/,subLanguage:`bash`}}]}}function _f(e){let t=e.regex,n=e.COMMENT(`--`,`$`),r={scope:`string`,variants:[{begin:/'/,end:/'/,contains:[{match:/''/}]}]},i={begin:/"/,end:/"/,contains:[{match:/""/}]},a=[`true`,`false`,`unknown`],o=[`double precision`,`large object`,`with timezone`,`without timezone`],s=`bigint.binary.blob.boolean.char.character.clob.date.dec.decfloat.decimal.float.int.integer.interval.nchar.nclob.national.numeric.real.row.smallint.time.timestamp.varchar.varying.varbinary`.split(`.`),c=[`add`,`asc`,`collation`,`desc`,`final`,`first`,`last`,`view`],l=`abs.acos.all.allocate.alter.and.any.are.array.array_agg.array_max_cardinality.as.asensitive.asin.asymmetric.at.atan.atomic.authorization.avg.begin.begin_frame.begin_partition.between.bigint.binary.blob.boolean.both.by.call.called.cardinality.cascaded.case.cast.ceil.ceiling.char.char_length.character.character_length.check.classifier.clob.close.coalesce.collate.collect.column.commit.condition.connect.constraint.contains.convert.copy.corr.corresponding.cos.cosh.count.covar_pop.covar_samp.create.cross.cube.cume_dist.current.current_catalog.current_date.current_default_transform_group.current_path.current_role.current_row.current_schema.current_time.current_timestamp.current_path.current_role.current_transform_group_for_type.current_user.cursor.cycle.date.day.deallocate.dec.decimal.decfloat.declare.default.define.delete.dense_rank.deref.describe.deterministic.disconnect.distinct.double.drop.dynamic.each.element.else.empty.end.end_frame.end_partition.end-exec.equals.escape.every.except.exec.execute.exists.exp.external.extract.false.fetch.filter.first_value.float.floor.for.foreign.frame_row.free.from.full.function.fusion.get.global.grant.group.grouping.groups.having.hold.hour.identity.in.indicator.initial.inner.inout.insensitive.insert.int.integer.intersect.intersection.interval.into.is.join.json_array.json_arrayagg.json_exists.json_object.json_objectagg.json_query.json_table.json_table_primitive.json_value.lag.language.large.last_value.lateral.lead.leading.left.like.like_regex.listagg.ln.local.localtime.localtimestamp.log.log10.lower.match.match_number.match_recognize.matches.max.member.merge.method.min.minute.mod.modifies.module.month.multiset.national.natural.nchar.nclob.new.no.none.normalize.not.nth_value.ntile.null.nullif.numeric.octet_length.occurrences_regex.of.offset.old.omit.on.one.only.open.or.order.out.outer.over.overlaps.overlay.parameter.partition.pattern.per.percent.percent_rank.percentile_cont.percentile_disc.period.portion.position.position_regex.power.precedes.precision.prepare.primary.procedure.ptf.range.rank.reads.real.recursive.ref.references.referencing.regr_avgx.regr_avgy.regr_count.regr_intercept.regr_r2.regr_slope.regr_sxx.regr_sxy.regr_syy.release.result.return.returns.revoke.right.rollback.rollup.row.row_number.rows.running.savepoint.scope.scroll.search.second.seek.select.sensitive.session_user.set.show.similar.sin.sinh.skip.smallint.some.specific.specifictype.sql.sqlexception.sqlstate.sqlwarning.sqrt.start.static.stddev_pop.stddev_samp.submultiset.subset.substring.substring_regex.succeeds.sum.symmetric.system.system_time.system_user.table.tablesample.tan.tanh.then.time.timestamp.timezone_hour.timezone_minute.to.trailing.translate.translate_regex.translation.treat.trigger.trim.trim_array.true.truncate.uescape.union.unique.unknown.unnest.update.upper.user.using.value.values.value_of.var_pop.var_samp.varbinary.varchar.varying.versioning.when.whenever.where.width_bucket.window.with.within.without.year`.split(`.`),u=`abs.acos.array_agg.asin.atan.avg.cast.ceil.ceiling.coalesce.corr.cos.cosh.count.covar_pop.covar_samp.cume_dist.dense_rank.deref.element.exp.extract.first_value.floor.json_array.json_arrayagg.json_exists.json_object.json_objectagg.json_query.json_table.json_table_primitive.json_value.lag.last_value.lead.listagg.ln.log.log10.lower.max.min.mod.nth_value.ntile.nullif.percent_rank.percentile_cont.percentile_disc.position.position_regex.power.rank.regr_avgx.regr_avgy.regr_count.regr_intercept.regr_r2.regr_slope.regr_sxx.regr_sxy.regr_syy.row_number.sin.sinh.sqrt.stddev_pop.stddev_samp.substring.substring_regex.sum.tan.tanh.translate.translate_regex.treat.trim.trim_array.unnest.upper.value_of.var_pop.var_samp.width_bucket`.split(`.`),d=[`current_catalog`,`current_date`,`current_default_transform_group`,`current_path`,`current_role`,`current_schema`,`current_transform_group_for_type`,`current_user`,`session_user`,`system_time`,`system_user`,`current_time`,`localtime`,`current_timestamp`,`localtimestamp`],f=[`create table`,`insert into`,`primary key`,`foreign key`,`not null`,`alter table`,`add constraint`,`grouping sets`,`on overflow`,`character set`,`respect nulls`,`ignore nulls`,`nulls first`,`nulls last`,`depth first`,`breadth first`],p=u,m=[...l,...c].filter(e=>!u.includes(e)),h={scope:`variable`,match:/@[a-z0-9][a-z0-9_]*/},g={scope:`operator`,match:/[-+*/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?/,relevance:0},_={match:t.concat(/\b/,t.either(...p),/\s*\(/),relevance:0,keywords:{built_in:p}};function v(e){return t.concat(/\b/,t.either(...e.map(e=>e.replace(/\s+/,`\\s+`))),/\b/)}let y={scope:`keyword`,match:v(f),relevance:0};function b(e,{exceptions:t,when:n}={}){let r=n;return t||=[],e.map(e=>e.match(/\|\d+$/)||t.includes(e)?e:r(e)?`${e}|0`:e)}return{name:`SQL`,case_insensitive:!0,illegal:/[{}]|<\//,keywords:{$pattern:/\b[\w\.]+/,keyword:b(m,{when:e=>e.length<3}),literal:a,type:s,built_in:d},contains:[{scope:`type`,match:v(o)},y,_,h,r,i,e.C_NUMBER_MODE,e.C_BLOCK_COMMENT_MODE,n,g]}}var vf=`[A-Za-z$_][0-9A-Za-z$_]*`,yf=`as.in.of.if.for.while.finally.var.new.function.do.return.void.else.break.catch.instanceof.with.throw.case.default.try.switch.continue.typeof.delete.let.yield.const.class.debugger.async.await.static.import.from.export.extends.using`.split(`.`),bf=[`true`,`false`,`null`,`undefined`,`NaN`,`Infinity`],xf=`Object.Function.Boolean.Symbol.Math.Date.Number.BigInt.String.RegExp.Array.Float32Array.Float64Array.Int8Array.Uint8Array.Uint8ClampedArray.Int16Array.Int32Array.Uint16Array.Uint32Array.BigInt64Array.BigUint64Array.Set.Map.WeakSet.WeakMap.ArrayBuffer.SharedArrayBuffer.Atomics.DataView.JSON.Promise.Generator.GeneratorFunction.AsyncFunction.Reflect.Proxy.Intl.WebAssembly`.split(`.`),Sf=[`Error`,`EvalError`,`InternalError`,`RangeError`,`ReferenceError`,`SyntaxError`,`TypeError`,`URIError`],Cf=[`setInterval`,`setTimeout`,`clearInterval`,`clearTimeout`,`require`,`exports`,`eval`,`isFinite`,`isNaN`,`parseFloat`,`parseInt`,`decodeURI`,`decodeURIComponent`,`encodeURI`,`encodeURIComponent`,`escape`,`unescape`],wf=[`arguments`,`this`,`super`,`console`,`window`,`document`,`localStorage`,`sessionStorage`,`module`,`self`,`global`],Tf=[].concat(Cf,xf,Sf);function Ef(e){let t=e.regex,n=(e,{after:t})=>{let n=`</`+e[0].slice(1);return e.input.indexOf(n,t)!==-1},r=vf,i={begin:`<>`,end:`</>`},a=/<[A-Za-z0-9\\._:-]+\s*\/>/,o={begin:/<[A-Za-z0-9\\._:-]+/,end:/\/[A-Za-z0-9\\._:-]+>|\/>/,isTrulyOpeningTag:(e,t)=>{let r=e[0].length+e.index,i=e.input[r];if(i===`<`||i===`,`){t.ignoreMatch();return}i===`>`&&(n(e,{after:r})||t.ignoreMatch());let a,o=e.input.substring(r);((a=o.match(/^\s*=/))||(a=o.match(/^\s+extends\s+/))&&a.index===0)&&t.ignoreMatch()}},s={$pattern:vf,keyword:yf,literal:bf,built_in:Tf,"variable.language":wf},c=`[0-9](_?[0-9])*`,l=`\\.(${c})`,u=`0|[1-9](_?[0-9])*|0[0-7]*[89][0-9]*`,d={className:`number`,variants:[{begin:`(\\b(${u})((${l})|\\.)?|(${l}))[eE][+-]?(${c})\\b`},{begin:`\\b(${u})\\b((${l})\\b|\\.)?|(${l})\\b`},{begin:`\\b(0|[1-9](_?[0-9])*)n\\b`},{begin:`\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*n?\\b`},{begin:`\\b0[bB][0-1](_?[0-1])*n?\\b`},{begin:`\\b0[oO][0-7](_?[0-7])*n?\\b`},{begin:`\\b0[0-7]+n?\\b`}],relevance:0},f={className:`subst`,begin:`\\$\\{`,end:`\\}`,keywords:s,contains:[]},p={begin:".?html`",end:``,starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,f],subLanguage:`xml`}},m={begin:".?css`",end:``,starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,f],subLanguage:`css`}},h={begin:".?gql`",end:``,starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,f],subLanguage:`graphql`}},g={className:`string`,begin:"`",end:"`",contains:[e.BACKSLASH_ESCAPE,f]},_={className:`comment`,variants:[e.COMMENT(/\/\*\*(?!\/)/,`\\*/`,{relevance:0,contains:[{begin:`(?=@[A-Za-z]+)`,relevance:0,contains:[{className:`doctag`,begin:`@[A-Za-z]+`},{className:`type`,begin:`\\{`,end:`\\}`,excludeEnd:!0,excludeBegin:!0,relevance:0},{className:`variable`,begin:r+`(?=\\s*(-)|$)`,endsParent:!0,relevance:0},{begin:/(?=[^\n])\s/,relevance:0}]}]}),e.C_BLOCK_COMMENT_MODE,e.C_LINE_COMMENT_MODE]},v=[e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,p,m,h,g,{match:/\$\d+/},d];f.contains=v.concat({begin:/\{/,end:/\}/,keywords:s,contains:[`self`].concat(v)});let y=[].concat(_,f.contains),b=y.concat([{begin:/(\s*)\(/,end:/\)/,keywords:s,contains:[`self`].concat(y)}]),x={className:`params`,begin:/(\s*)\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:s,contains:b},S={variants:[{match:[/class/,/\s+/,r,/\s+/,/extends/,/\s+/,t.concat(r,`(`,t.concat(/\./,r),`)*`)],scope:{1:`keyword`,3:`title.class`,5:`keyword`,7:`title.class.inherited`}},{match:[/class/,/\s+/,r],scope:{1:`keyword`,3:`title.class`}}]},C={relevance:0,match:t.either(/\bJSON/,/\b[A-Z][a-z]+([A-Z][a-z]*|\d)*/,/\b[A-Z]{2,}([A-Z][a-z]+|\d)+([A-Z][a-z]*)*/,/\b[A-Z]{2,}[a-z]+([A-Z][a-z]+|\d)*([A-Z][a-z]*)*/),className:`title.class`,keywords:{_:[...xf,...Sf]}},w={label:`use_strict`,className:`meta`,relevance:10,begin:/^\s*['"]use (strict|asm)['"]/},ee={variants:[{match:[/function/,/\s+/,r,/(?=\s*\()/]},{match:[/function/,/\s*(?=\()/]}],className:{1:`keyword`,3:`title.function`},label:`func.def`,contains:[x],illegal:/%/},T={relevance:0,match:/\b[A-Z][A-Z_0-9]+\b/,className:`variable.constant`};function E(e){return t.concat(`(?!`,e.join(`|`),`)`)}let D={match:t.concat(/\b/,E([...Cf,`super`,`import`,`await`].map(e=>`${e}\\s*\\(`)),r,t.lookahead(/\s*\(/)),className:`title.function`,relevance:0},O={begin:t.concat(/\./,t.lookahead(t.concat(r,/(?![0-9A-Za-z$_(])/))),end:r,excludeBegin:!0,keywords:`prototype`,className:`property`,relevance:0},k={match:[/get|set/,/\s+/,r,/(?=\()/],className:{1:`keyword`,3:`title.function`},contains:[{begin:/\(\)/},x]},te=`(\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)|`+e.UNDERSCORE_IDENT_RE+`)\\s*=>`,A={match:[/const|var|let/,/\s+/,r,/\s*/,/=\s*/,/(async\s*)?/,t.lookahead(te)],keywords:`async`,className:{1:`keyword`,3:`title.function`},contains:[x]};return{name:`JavaScript`,aliases:[`js`,`jsx`,`mjs`,`cjs`],keywords:s,exports:{PARAMS_CONTAINS:b,CLASS_REFERENCE:C},illegal:/#(?![$_A-Za-z])/,contains:[e.SHEBANG({label:`shebang`,binary:`node`,relevance:5}),w,e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,p,m,h,g,_,{match:/\$\d+/},d,C,{scope:`attr`,match:r+t.lookahead(`:`),relevance:0},A,{begin:`(`+e.RE_STARTERS_RE+`|\\b(case|return|throw)\\b)\\s*`,keywords:`return throw case`,relevance:0,contains:[_,e.REGEXP_MODE,{className:`function`,begin:te,returnBegin:!0,end:`\\s*=>`,contains:[{className:`params`,variants:[{begin:e.UNDERSCORE_IDENT_RE,relevance:0},{className:null,begin:/\(\s*\)/,skip:!0},{begin:/(\s*)\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:s,contains:b}]}]},{begin:/,/,relevance:0},{match:/\s+/,relevance:0},{variants:[{begin:i.begin,end:i.end},{match:a},{begin:o.begin,"on:begin":o.isTrulyOpeningTag,end:o.end}],subLanguage:`xml`,contains:[{begin:o.begin,end:o.end,skip:!0,contains:[`self`]}]}]},ee,{beginKeywords:`while if switch catch for`},{begin:`\\b(?!function)`+e.UNDERSCORE_IDENT_RE+`\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)\\s*\\{`,returnBegin:!0,label:`func.def`,contains:[x,e.inherit(e.TITLE_MODE,{begin:r,className:`title.function`})]},{match:/\.\.\./,relevance:0},O,{match:`\\$`+r,relevance:0},{match:[/\bconstructor(?=\s*\()/],className:{1:`title.function`},contains:[x]},D,T,S,k,{match:/\$[(.]/}]}}function Df(e){let t=e.regex,n=Ef(e),r=vf,i=[`any`,`void`,`number`,`boolean`,`string`,`object`,`never`,`symbol`,`bigint`,`unknown`],a={begin:[/namespace/,/\s+/,e.IDENT_RE],beginScope:{1:`keyword`,3:`title.class`}},o={beginKeywords:`interface`,end:/\{/,excludeEnd:!0,keywords:{keyword:`interface extends`,built_in:i},contains:[n.exports.CLASS_REFERENCE]},s={className:`meta`,relevance:10,begin:/^\s*['"]use strict['"]/},c={$pattern:vf,keyword:yf.concat([`type`,`interface`,`public`,`private`,`protected`,`implements`,`declare`,`abstract`,`readonly`,`enum`,`override`,`satisfies`]),literal:bf,built_in:Tf.concat(i),"variable.language":wf},l={className:`meta`,begin:`@`+r},u=(e,t,n)=>{let r=e.contains.findIndex(e=>e.label===t);if(r===-1)throw Error(`can not find mode to replace`);e.contains.splice(r,1,n)};Object.assign(n.keywords,c),n.exports.PARAMS_CONTAINS.push(l);let d=n.contains.find(e=>e.scope===`attr`),f=Object.assign({},d,{match:t.concat(r,t.lookahead(/\s*\?:/))});n.exports.PARAMS_CONTAINS.push([n.exports.CLASS_REFERENCE,d,f]),n.contains=n.contains.concat([l,a,o,f]),u(n,`shebang`,e.SHEBANG()),u(n,`use_strict`,s);let p=n.contains.find(e=>e.label===`func.def`);return p.relevance=0,Object.assign(n,{name:`TypeScript`,aliases:[`ts`,`tsx`,`mts`,`cts`]}),n}function Of(e){let t=e.regex,n=t.concat(/[\p{L}_]/u,t.optional(/[\p{L}0-9_.-]*:/u),/[\p{L}0-9_.-]*/u),r=/[\p{L}0-9._:-]+/u,i={className:`symbol`,begin:/&[a-z]+;|&#[0-9]+;|&#x[a-f0-9]+;/},a={begin:/\s/,contains:[{className:`keyword`,begin:/#?[a-z_][a-z1-9_-]+/,illegal:/\n/}]},o=e.inherit(a,{begin:/\(/,end:/\)/}),s=e.inherit(e.APOS_STRING_MODE,{className:`string`}),c=e.inherit(e.QUOTE_STRING_MODE,{className:`string`}),l={endsWithParent:!0,illegal:/</,relevance:0,contains:[{className:`attr`,begin:r,relevance:0},{begin:/=\s*/,relevance:0,contains:[{className:`string`,endsParent:!0,variants:[{begin:/"/,end:/"/,contains:[i]},{begin:/'/,end:/'/,contains:[i]},{begin:/[^\s"'=<>`]+/}]}]}]};return{name:`HTML, XML`,aliases:[`html`,`xhtml`,`rss`,`atom`,`xjb`,`xsd`,`xsl`,`plist`,`wsf`,`svg`],case_insensitive:!0,unicodeRegex:!0,contains:[{className:`meta`,begin:/<![a-z]/,end:/>/,relevance:10,contains:[a,c,s,o,{begin:/\[/,end:/\]/,contains:[{className:`meta`,begin:/<![a-z]/,end:/>/,contains:[a,o,c,s]}]}]},e.COMMENT(/<!--/,/-->/,{relevance:10}),{begin:/<!\[CDATA\[/,end:/\]\]>/,relevance:10},i,{className:`meta`,end:/\?>/,variants:[{begin:/<\?xml/,relevance:10,contains:[c]},{begin:/<\?[a-z][a-z0-9]+/}]},{className:`tag`,begin:/<style(?=\s|>)/,end:/>/,keywords:{name:`style`},contains:[l],starts:{end:/<\/style>/,returnEnd:!0,subLanguage:`css`}},{className:`tag`,begin:/<script(?=\s|>)/,end:/>/,keywords:{name:`script`},contains:[l],starts:{end:/<\/script>/,returnEnd:!0,subLanguage:`javascript`}},{className:`tag`,begin:/<>|<\/>/},{className:`tag`,begin:t.concat(/</,t.lookahead(t.concat(n,t.either(/\/>/,/>/,/\s/)))),end:/\/?>/,contains:[{className:`name`,begin:n,relevance:0,starts:l}]},{className:`tag`,begin:t.concat(/<\//,t.lookahead(t.concat(n,/>/))),contains:[{className:`name`,begin:n,relevance:0},{begin:/>/,relevance:0,endsParent:!0}]}]}}function kf(e){let t=`true false yes no null`,n=`[\\w#;/?:@&=+$,.~*'()[\\]]+`,r={className:`attr`,variants:[{begin:/[\w*@][\w*@ :()\./-]*:(?=[ \t]|$)/},{begin:/"[\w*@][\w*@ :()\./-]*":(?=[ \t]|$)/},{begin:/'[\w*@][\w*@ :()\./-]*':(?=[ \t]|$)/}]},i={className:`template-variable`,variants:[{begin:/\{\{/,end:/\}\}/},{begin:/%\{/,end:/\}/}]},a={className:`string`,relevance:0,begin:/'/,end:/'/,contains:[{match:/''/,scope:`char.escape`,relevance:0}]},o={className:`string`,relevance:0,variants:[{begin:/"/,end:/"/},{begin:/\S+/}],contains:[e.BACKSLASH_ESCAPE,i]},s=e.inherit(o,{variants:[{begin:/'/,end:/'/,contains:[{begin:/''/,relevance:0}]},{begin:/"/,end:/"/},{begin:/[^\s,{}[\]]+/}]}),c={className:`number`,begin:`\\b[0-9]{4}(-[0-9][0-9]){0,2}([Tt \\t][0-9][0-9]?(:[0-9][0-9]){2})?(\\.[0-9]*)?([ \\t])*(Z|[-+][0-9][0-9]?(:[0-9][0-9])?)?\\b`},l={end:`,`,endsWithParent:!0,excludeEnd:!0,keywords:t,relevance:0},u={begin:/\{/,end:/\}/,contains:[l],illegal:`\\n`,relevance:0},d={begin:`\\[`,end:`\\]`,contains:[l],illegal:`\\n`,relevance:0},f=[r,{className:`meta`,begin:`^---\\s*$`,relevance:10},{className:`string`,begin:`[\\|>]([1-9]?[+-])?[ ]*\\n( +)[^ ][^\\n]*\\n(\\2[^\\n]+\\n?)*`},{begin:`<%[%=-]?`,end:`[%-]?%>`,subLanguage:`ruby`,excludeBegin:!0,excludeEnd:!0,relevance:0},{className:`type`,begin:`!\\w+!`+n},{className:`type`,begin:`!<`+n+`>`},{className:`type`,begin:`!`+n},{className:`type`,begin:`!!`+n},{className:`meta`,begin:`&`+e.UNDERSCORE_IDENT_RE+`$`},{className:`meta`,begin:`\\*`+e.UNDERSCORE_IDENT_RE+`$`},{className:`bullet`,begin:`-(?=[ ]|$)`,relevance:0},e.HASH_COMMENT_MODE,{beginKeywords:t,keywords:{literal:t}},c,{className:`number`,begin:e.C_NUMBER_RE+`\\b`,relevance:0},u,d,a,o],p=[...f];return p.pop(),p.push(s),l.contains=p,{name:`YAML`,case_insensitive:!0,aliases:[`yml`],contains:f}}function Af(e,t){let n=e.split(`/`).slice(0,-1);for(let e of Pf(t).split(`/`))if(e!==``&&e!==`.`){if(e===`..`){if(n.length===0)return null;n.pop()}else n.push(e)}return n.length>0?n.join(`/`):null}function jf(e){return/^[a-z][a-z0-9+.-]*:/i.test(e)||e.startsWith(`//`)||e.startsWith(`/`)}function Mf(e){return/\.(md|markdown)$/i.test(e)}function Nf(e){return e.split(`/`).map(encodeURIComponent).join(`/`)}function Pf(e){try{return decodeURI(e)}catch{return e}}function Ff(e){if(!e.startsWith(`#/`))return{path:null,anchor:null};let t=e.slice(2),n=t.indexOf(`#`),r=n<0?t:t.slice(0,n),i=n<0?``:t.slice(n+1);return{path:Bf(r),anchor:Bf(i)||null}}function If(e){return e.path===null?``:`#/${e.path.split(`/`).map(encodeURIComponent).join(`/`)}${e.anchor?`#${encodeURIComponent(e.anchor)}`:``}`}function Lf(e){return e!==null&&(e===``||e.endsWith(`/`))}function Rf(e){return e.slice(0,e.lastIndexOf(`/`)+1)}function zf(e){let t=e?/^L(\d+)$/.exec(e):null;return t?.[1]?Number(t[1]):null}function Bf(e){try{return decodeURIComponent(e)}catch{return e}}var Vf={bash:Ud,css:Qd,diff:$d,go:ef,javascript:uf,json:ff,markdown:pf,python:mf,rust:hf,shell:gf,sql:_f,typescript:Df,xml:Of,yaml:kf};for(let[e,t]of Object.entries(Vf))Hd.registerLanguage(e,t);var Hf={note:`Note`,tip:`Tip`,important:`Important`,warning:`Warning`,caution:`Caution`},Uf=new Vd({html:!1,linkify:!0,highlight(e,t){let n=t.trim().toLowerCase();return n&&Hd.getLanguage(n)?Hd.highlight(e,{language:n,ignoreIllegals:!0}).value:``}});Uf.core.ruler.push(`mdifit`,e=>{let t=e.env,n=e.tokens,r=e.src.split(`
18
18
  `);n.forEach((i,a)=>{i.map&&i.block&&i.nesting!==-1&&(i.attrSet(`data-line-start`,String(i.map[0]+1)),i.attrSet(`data-line-end`,String(Jf(r,i.map[0],i.map[1])))),i.type===`heading_open`&&Xf(i,n[a+1],t),i.type===`blockquote_open`&&Zf(i,n,a),i.type===`list_item_open`&&Qf(e,i,a),i.type===`inline`&&$f(i.children??[],t.filePath)})});var Wf=Uf.renderer.rules.link_open??((e,t,n,r,i)=>i.renderToken(e,t,n));Uf.renderer.rules.link_open=(e,t,n,r,i)=>{let a=e[t],o=String(a?.attrGet(`href`)??``);return a&&jf(o)&&!o.startsWith(`/`)&&(a.attrSet(`target`,`_blank`),a.attrSet(`rel`,`noopener noreferrer`)),Wf(e,t,n,r,i)};function Gf(e,t){let n={filePath:t,headings:[],slugs:new Map},r=Uf.parse(qf(e),n),i=[],a=0,o=0;return r.forEach((e,t)=>{if(o+=e.nesting,o!==0)return;let s=r.slice(a,t+1),c=s[0]?.map;c&&i.push({key:`${c[0]}-${c[1]}-${i.length}`,html:Uf.renderer.render(s,Uf.options,n),startLine:c[0]+1,endLine:Number(s[0]?.attrGet(`data-line-end`)??c[0]+1),diagram:Kf(s[0])}),a=t+1}),{blocks:i,headings:n.headings}}function Kf(e){return e?.type===`fence`&&e.info.trim().split(/\s+/)[0]?.toLowerCase()===`mermaid`?e.content:null}function qf(e){let t=e.split(`
19
19
  `);if(t[0]?.trim()!==`---`)return e;let n=t.findIndex((e,t)=>t>0&&e.trim()===`---`);return n<0?e:t.map((e,t)=>t<=n?``:e).join(`
20
- `)}function Jf(e,t,n){let r=n-1;for(;r>t&&(e[r]??``).trim()===``;)r--;return r+1}function Yf(e){return e.trim().toLowerCase().replace(/[^\p{L}\p{N}\s_-]/gu,``).replace(/\s/g,`-`)}function Xf(e,t,n){let r=(t?.children??[]).filter(e=>e.type===`text`||e.type===`code_inline`).map(e=>e.content).join(``),i=Yf(r)||`section`,a=n.slugs.get(i)??0;n.slugs.set(i,a+1);let o=a===0?i:`${i}-${a}`;e.attrSet(`id`,o),n.headings.push({level:Number(e.tag.slice(1)),text:r,slug:o,line:(e.map?.[0]??0)+1})}function Zf(e,t,n){let r=t[n+2];if(t[n+1]?.type!==`paragraph_open`||r?.type!==`inline`)return;let i=/^\[!(\w+)\]\s*/.exec(r.content),a=i?.[1]?.toLowerCase(),o=a?Hf[a]:void 0;if(!i||!a||!o)return;e.attrJoin(`class`,`alert alert-${a}`),e.attrSet(`data-alert`,o),r.content=r.content.slice(i[0].length);let s=r.children??[],c=s[0];c?.type===`text`&&(c.content=c.content.replace(/^\[!\w+\]\s*/,``),c.content===``&&s[1]?.type===`softbreak`?s.splice(0,2):c.content===``&&s.splice(0,1))}function Qf(e,t,n){let r=e.tokens,i=r[n+2];if(r[n+1]?.type!==`paragraph_open`||i?.type!==`inline`)return;let a=i.children?.[0],o=a?.type===`text`?/^\[([ xX])\]\s+/.exec(a.content):null;if(!a||!o)return;a.content=a.content.slice(o[0].length);let s=new e.Token(`html_inline`,``,0);s.content=`<input type="checkbox" disabled${o[1]===` `?``:` checked`}> `,i.children?.unshift(s),t.attrJoin(`class`,`task-item`)}function $f(e,t){for(let n of e){if(n.type===`link_open`){let e=String(n.attrGet(`href`)??``);if(!e||jf(e))continue;if(e.startsWith(`#`)){n.attrSet(`href`,If({path:t,anchor:e.slice(1)}));continue}let[r=``,i=``]=e.split(`#`),a=Af(t,r);if(!a)continue;n.attrSet(`href`,Mf(a)?If({path:a,anchor:i||null}):`/raw/${Nf(a)}`)}if(n.type===`image`){let e=String(n.attrGet(`src`)??``),r=e&&!jf(e)?Af(t,e):null;r&&n.attrSet(`src`,`/raw/${Nf(r)}`),n.attrSet(`loading`,`lazy`)}}}var ep=`boca`,tp={typed:``,at:0};function np(e,t,n){let r=n-e.at<=1500?e.typed:``;if(t===`boca`[r.length]){let e=r+t,i=e===ep;return{state:{typed:i?``:e,at:n},consumed:e.length>=2,undoFirst:e.length===2,matched:i}}return{state:{typed:t===`b`?t:``,at:n},consumed:!1,undoFirst:!1,matched:!1}}var rp=[{action:`palette`,keys:`⌘K`,label:`Search files, headings and text`},{action:`comment`,keys:`C`,label:`Comment on the selection`},{action:`suggest`,keys:`S`,label:`Suggest an edit to the selection`},{action:`prompt`,keys:`P`,label:`Review and copy the prompt`},{action:`toggleRead`,keys:`R`,label:`Mark the file read / unread`},{action:`toggleMode`,keys:`V`,label:`Switch Read / Source view`},{action:`nextFile`,keys:`]`,label:`Next file`},{action:`previousFile`,keys:`[`,label:`Previous file`},{action:`toggleFiles`,keys:`B`,label:`Show / hide the files panel`},{action:`toggleComments`,keys:`N`,label:`Show / hide the comments panel`},{action:`help`,keys:`?`,label:`Show shortcuts`}];function ip(e){let t=e.key.toLowerCase();if((e.metaKey||e.ctrlKey)&&!e.altKey&&t===`k`)return`palette`;if(e.editing||e.metaKey||e.ctrlKey||e.altKey)return null;switch(e.key){case`c`:return`comment`;case`s`:return`suggest`;case`p`:return`prompt`;case`r`:return`toggleRead`;case`v`:return`toggleMode`;case`]`:return`nextFile`;case`[`:return`previousFile`;case`b`:return`toggleFiles`;case`n`:return`toggleComments`;case`?`:return`help`;default:return null}}function ap(e){return e.normalize(`NFD`).replace(/\p{Diacritic}/gu,``).toLowerCase()}function op(e,t,n=`${t}s`){return`${e} ${e===1?t:n}`}function sp(e,t){let n=Math.floor((t-e)/6e4);if(n<1)return`just now`;if(n<60)return`${n} min ago`;let r=Math.floor(n/60);if(r<24)return`${r} h ago`;let i=Math.floor(r/24);return i<14?`${i} d ago`:new Date(e).toISOString().slice(0,10)}var cp=[`width`,`height`,`stroke-width`],lp=[`d`],$=V({__name:`Icon`,props:{name:{},size:{default:16},strokeWidth:{default:2}},setup(e){let t={search:[`M11 18a7 7 0 1 0 0-14 7 7 0 0 0 0 14z`,`M20 20l-3.5-3.5`],file:[`M14 3H6a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V9z`,`M14 3v6h6`],folder:[`M3 7a2 2 0 0 1 2-2h4l2 2h8a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z`],"chevron-right":[`M9 6l6 6-6 6`],"chevron-left":[`M15 6l-6 6 6 6`],"chevron-down":[`M6 9l6 6 6-6`],check:[`M5 12l5 5 9-10`],copy:[`M9 9h10a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2H11a2 2 0 0 1-2-2z`,`M5 15V5a2 2 0 0 1 2-2h10`],comment:[`M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z`],edit:[`M12 20h9`,`M16.5 3.5a2.1 2.1 0 0 1 3 3L7 19l-4 1 1-4z`],trash:[`M4 7h16`,`M10 11v6M14 11v6`,`M6 7l1 13h10l1-13`,`M9 7V4h6v3`],close:[`M6 6l12 12M18 6L6 18`],plus:[`M12 5v14M5 12h14`],link:[`M10 13a5 5 0 0 0 7.5.5l3-3a5 5 0 0 0-7-7l-1.7 1.7`,`M14 11a5 5 0 0 0-7.5-.5l-3 3a5 5 0 0 0 7 7l1.7-1.7`],"arrow-right":[`M5 12h14M13 6l6 6-6 6`],"panel-left":[`M3 5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z`,`M9 3v18`],"panel-right":[`M3 5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z`,`M15 3v18`],expand:[`M15 3h6v6`,`M9 21H3v-6`,`M21 3l-7 7`,`M3 21l7-7`],keyboard:[`M3 7a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2v10a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z`,`M7 10h.01M11 10h.01M15 10h.01M8 14h8`]};return(n,r)=>(U(),W(`svg`,{width:e.size,height:e.size,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,"stroke-width":e.strokeWidth,"stroke-linecap":`round`,"stroke-linejoin":`round`,"aria-hidden":`true`},[(U(!0),W(H,null,Mr(t[e.name],e=>(U(),W(`path`,{key:e,d:e},null,8,lp))),128))],8,cp))}});function up(e,t){let n=ap(e.replace(/\s+/g,``)),r=ap(t);if(!n)return 0;let i=r.lastIndexOf(`/`)+1,a=0,o=-2,s=0;for(let e of n){let t=r.indexOf(e,s);if(t<0)return null;a+=1,t===o+1&&(a+=3),t>=i&&(a+=2),(t===i||r[t-1]===`-`||r[t-1]===`_`)&&(a+=2),o=t,s=t+1}return a-r.length/100}function dp(e,t){return e.map(e=>({file:e,score:up(t,`${e.path}`)})).filter(e=>e.score!==null).toSorted((e,t)=>t.score-e.score).slice(0,8).map(({file:e})=>({key:`file:${e.path}`,kind:`file`,path:e.path,line:null,label:e.path,detail:e.title??``}))}function fp(e){return e.map(e=>({key:`${e.kind}:${e.path}:${e.line}`,kind:e.kind,path:e.path,line:e.line,label:e.kind===`heading`?`${`#`.repeat(e.level??1)} ${e.text}`:e.text,detail:`${e.path}:L${e.line}`}))}function pp(e,t){let n=ap(t.trim()),r=n?ap(e).indexOf(n):-1;return r<0?[{text:e,match:!1}]:[{text:e.slice(0,r),match:!1},{text:e.slice(r,r+n.length),match:!0},{text:e.slice(r+n.length),match:!1}].filter(e=>e.text)}var mp={class:`field`},hp=[`aria-activedescendant`],gp={id:`palette-results`,class:`results`,role:`listbox`},_p={class:`group`,role:`presentation`},vp=[`id`,`data-index`,`aria-selected`,`onMousemove`,`onClick`],yp={class:`label`},bp={key:0},xp={class:`detail`},Sp={key:0,class:`empty`},Cp=V({__name:`CommandPalette`,props:{open:{type:Boolean},files:{}},emits:[`close`,`go`],setup(e,{emit:t}){let n=e,r=t,i=z(null),a=z(null),o=z(``),s=z([]),c=z(0),l=z(!1),u=X(()=>[...dp(n.files,o.value),...s.value]),d=[{kind:`file`,label:`Files`},{kind:`heading`,label:`Headings`},{kind:`text`,label:`Text`}],f=null,p;qn(o,e=>{c.value=0,clearTimeout(p),f?.abort(),e.trim().length<2?(s.value=[],l.value=!1):(l.value=!0,p=setTimeout(async()=>{let t=new AbortController;f=t;try{s.value=fp((await us(e,t.signal)).hits)}catch{}finally{f===t&&!t.signal.aborted&&(l.value=!1)}},120))}),qn(()=>n.open,e=>{e?(o.value=``,s.value=[],i.value?.showModal(),a.value?.focus()):i.value?.close()},{flush:`post`});function m(e){return u.value.indexOf(e)}function h(e){e&&r(`go`,e)}function g(e){let t=u.value.length;e.key===`ArrowDown`?(e.preventDefault(),c.value=t?(c.value+1)%t:0):e.key===`ArrowUp`?(e.preventDefault(),c.value=t?(c.value-1+t)%t:0):e.key===`Enter`&&(e.preventDefault(),h(u.value[c.value]))}return qn(c,e=>{i.value?.querySelector(`[data-index="${e}"]`)?.scrollIntoView({block:`nearest`})}),(e,t)=>(U(),W(`dialog`,{ref_key:`dialog`,ref:i,class:`palette`,"aria-label":`Go to`,onClose:t[1]||=e=>r(`close`),onKeydown:g},[K(`label`,mp,[q($,{name:`search`,size:18}),t[2]||=K(`span`,{class:`visually-hidden`},`Search files, headings and text`,-1),Vn(K(`input`,{ref_key:`input`,ref:a,"onUpdate:modelValue":t[0]||=e=>o.value=e,type:`text`,placeholder:`Search files, headings and text…`,role:`combobox`,"aria-controls":`palette-results`,"aria-activedescendant":u.value.length?`palette-${c.value}`:void 0,"aria-expanded":`true`,autocomplete:`off`,spellcheck:`false`},null,8,hp),[[Mo,o.value]]),t[3]||=K(`kbd`,null,`Esc`,-1)]),K(`div`,gp,[(U(),W(H,null,Mr(d,e=>(U(),W(H,{key:e.kind},[u.value.some(t=>t.kind===e.kind)?(U(),W(H,{key:0},[K(`div`,_p,I(e.label),1),(U(!0),W(H,null,Mr(u.value.filter(t=>t.kind===e.kind),e=>(U(),W(`button`,{id:`palette-${m(e)}`,key:e.key,type:`button`,role:`option`,class:`item`,"data-index":m(e),"aria-selected":m(e)===c.value,onMousemove:t=>c.value=m(e),onClick:t=>h(e)},[e.kind===`file`?(U(),G($,{key:0,name:`file`,size:15})):Y(``,!0),K(`span`,yp,[(U(!0),W(H,null,Mr(B(pp)(e.label,o.value),(e,t)=>(U(),W(H,{key:t},[e.match?(U(),W(`strong`,bp,I(e.text),1)):(U(),W(H,{key:1},[J(I(e.text),1)],64))],64))),128))]),K(`span`,xp,I(e.detail),1)],40,vp))),128))],64)):Y(``,!0)],64))),64)),u.value.length===0?(U(),W(`p`,Sp,I(o.value.trim().length<2?`Type to search every file.`:l.value?`Searching…`:`Nothing found.`),1)):Y(``,!0)]),t[4]||=K(`footer`,null,[K(`span`,null,[K(`kbd`,null,`↑`),K(`kbd`,null,`↓`),J(` move`)]),K(`span`,null,[K(`kbd`,null,`↵`),J(` open`)])],-1)],544))}}),wp=(e,t)=>{let n=e.__vccOpts||e;for(let[e,r]of t)n[e]=r;return n},Tp=wp(Cp,[[`__scopeId`,`data-v-dfcef181`]]),Ep={class:`rail`,"aria-label":`Comments`},Dp={class:`tabs`,role:`tablist`},Op=[`aria-selected`],kp=[`aria-selected`],Ap={key:0,class:`list`},jp=[`href`],Mp={class:`meta`},Np={key:0,class:`kind`},Pp={key:0,class:`quote`},Fp={key:1,class:`suggestion`},Ip={key:2,class:`body`},Lp={key:1,class:`empty`},Rp={key:0},zp={key:1},Bp=[`disabled`],Vp=[`disabled`],Hp=wp(V({__name:`CommentsRail`,props:{comments:{},currentPath:{}},emits:[`openPrompt`,`clear`],setup(e,{emit:t}){let n=e,r=t,i=z(`file`),a=X(()=>n.comments.filter(e=>e.path===n.currentPath)),o=X(()=>Qo(i.value===`file`?a.value:n.comments));function s(e){return e.startLine===e.endLine?`L${e.startLine}`:`L${e.startLine}-L${e.endLine}`}function c(){let e=o.value.map(e=>e.id),t=i.value===`file`?`in this file`:`in every file`;e.length&&window.confirm(`Delete ${e.length} comments ${t}?`)&&r(`clear`,e)}return(t,n)=>(U(),W(`aside`,Ep,[K(`div`,Dp,[K(`button`,{type:`button`,role:`tab`,"aria-selected":i.value===`file`,onClick:n[0]||=e=>i.value=`file`},[n[3]||=J(` This file `,-1),K(`span`,null,I(a.value.length),1)],8,Op),K(`button`,{type:`button`,role:`tab`,"aria-selected":i.value===`all`,onClick:n[1]||=e=>i.value=`all`},[n[4]||=J(` All files `,-1),K(`span`,null,I(e.comments.length),1)],8,kp)]),o.value.length?(U(),W(`ol`,Ap,[(U(!0),W(H,null,Mr(o.value,e=>(U(),W(`li`,{key:e.id},[K(`a`,{href:B(If)({path:e.path,anchor:`comment-${e.id}`}),class:`item`},[K(`span`,Mp,[e.suggestion===null?Y(``,!0):(U(),W(`span`,Np,`Suggested edit`)),K(`code`,null,I(i.value===`all`?`${e.path}:`:``)+I(s(e)),1)]),e.quote?(U(),W(`span`,Pp,`“`+I(e.quote)+`”`,1)):Y(``,!0),e.suggestion===null?Y(``,!0):(U(),W(`span`,Fp,`→ `+I(e.suggestion),1)),e.body?(U(),W(`span`,Ip,I(e.body),1)):Y(``,!0)],8,jp)]))),128))])):(U(),W(`div`,Lp,[q($,{name:`comment`,size:20}),i.value===`file`?(U(),W(`p`,Rp,` Select text to comment on it, or click a line number. Your comments stay in this browser. `)):(U(),W(`p`,zp,`No comments yet.`))])),K(`footer`,null,[K(`button`,{type:`button`,class:`btn btn-comment`,disabled:e.comments.length===0,onClick:n[2]||=e=>r(`openPrompt`)},[q($,{name:`copy`}),n[5]||=J(` Copy all prompt `,-1)],8,Bp),K(`button`,{type:`button`,class:`btn`,disabled:o.value.length===0,onClick:c},`Clear`,8,Vp)])]))}}),[[`__scopeId`,`data-v-c8817f32`]]),Up=[`readme.md`,`agents.md`,`index.md`,`readme.markdown`];function Wp(e,t){return e.filter(e=>Yp(e.path,t)!==null).map(e=>({path:e.path,rank:Up.indexOf(Xp(e.path).toLowerCase())})).filter(e=>e.rank>=0).toSorted((e,t)=>e.rank-t.rank).map(e=>e.path)}function Gp(e,t){return t===``||e.some(e=>e.path.startsWith(t))}function Kp(e,t,n,r){let i=new Map,a=[];for(let o of e){if(!o.path.startsWith(t))continue;let e=o.path.slice(t.length),s=e.indexOf(`/`),c=es(o,n),l=r.get(o.path)??0;if(s<0){a.push({name:e,path:o.path,title:o.title,status:c,comments:l,mtimeMs:o.mtimeMs});continue}let u=e.slice(0,s),d=i.get(u)??{name:u,path:`${t}${u}/`,files:0,unread:0,comments:0};d.files+=1,d.unread+=c===`read`?0:1,d.comments+=l,i.set(u,d)}return{folders:[...i.values()].toSorted(Jp),files:a.toSorted(Jp)}}function qp(e,t){return e===``?t:e.slice(0,-1).split(`/`).at(-1)??t}function Jp(e,t){return e.name.localeCompare(t.name,`en`,{sensitivity:`base`,numeric:!0})}function Yp(e,t){if(!e.startsWith(t))return null;let n=e.slice(t.length);return n.includes(`/`)?null:n}function Xp(e){return e.slice(e.lastIndexOf(`/`)+1)}var Zp={class:`list`},Qp=[`href`],$p={class:`name`},em={class:`meta`},tm=[`aria-label`],nm=[`href`],rm={class:`name`},im={key:0,class:`title`},am={key:0,class:`badge`},om={class:`meta`},sm=[`aria-label`],cm=wp(V({__name:`FolderList`,props:{listing:{},now:{}},setup(e){return(t,n)=>(U(),W(`ul`,Zp,[(U(!0),W(H,null,Mr(e.listing.folders,e=>(U(),W(`li`,{key:e.path},[K(`a`,{class:`row`,href:B(If)({path:e.path,anchor:null})},[q($,{name:`folder`,class:`icon`}),K(`span`,$p,I(e.name),1),K(`span`,em,[J(I(B(op)(e.files,`file`))+` `,1),e.unread?(U(),W(H,{key:0},[J(` · `+I(e.unread)+` unread`,1)],64)):Y(``,!0)]),e.comments?(U(),W(`span`,{key:0,class:`count`,"aria-label":`${e.comments} comments`},[q($,{name:`comment`,size:13}),J(I(e.comments),1)],8,tm)):Y(``,!0)],8,Qp)]))),128)),(U(!0),W(H,null,Mr(e.listing.files,t=>(U(),W(`li`,{key:t.path},[K(`a`,{class:ye([`row`,t.status]),href:B(If)({path:t.path,anchor:null})},[q($,{name:t.status===`read`?`check`:`file`,class:`icon status`},null,8,[`name`]),K(`span`,rm,[J(I(t.name)+` `,1),t.title?(U(),W(`span`,im,I(t.title),1)):Y(``,!0)]),t.status===`edited`?(U(),W(`span`,am,`edited`)):Y(``,!0),K(`span`,om,I(B(sp)(t.mtimeMs,e.now)),1),t.comments?(U(),W(`span`,{key:1,class:`count`,"aria-label":`${t.comments} comments`},[q($,{name:`comment`,size:13}),J(I(t.comments),1)],8,sm)):Y(``,!0)],10,nm)]))),128))]))}}),[[`__scopeId`,`data-v-58e7e372`]]),lm={class:`strip`,"aria-label":`Folder`},um=[`aria-expanded`],dm={key:0,class:`segmented`,role:`radiogroup`,"aria-label":`Open with`},fm=[`aria-checked`,`onClick`],pm=wp(V({__name:`FolderStrip`,props:{folder:{},rootName:{},listing:{},entries:{},entry:{}},emits:[`chooseEntry`],setup(e,{emit:t}){let n=e,r=t,i=z(!1),a=z(Date.now()),o=X(()=>{let e=[op(n.listing.files.length,`file`)];return n.listing.folders.length&&e.push(op(n.listing.folders.length,`folder`)),`${e.join(` · `)} in ${qp(n.folder,n.rootName)}`});function s(){i.value=!i.value,a.value=Date.now()}function c(e){return e.slice(e.lastIndexOf(`/`)+1)}return(t,n)=>(U(),W(`section`,lm,[K(`header`,null,[K(`button`,{type:`button`,class:`toggle`,"aria-expanded":i.value,onClick:s},[q($,{name:i.value?`chevron-down`:`chevron-right`,size:14,"stroke-width":2.4},null,8,[`name`]),q($,{name:`folder`,size:15}),J(` `+I(o.value),1)],8,um),e.entries.length>1?(U(),W(`div`,dm,[(U(!0),W(H,null,Mr(e.entries,t=>(U(),W(`button`,{key:t,type:`button`,role:`radio`,"aria-checked":t===e.entry,onClick:e=>r(`chooseEntry`,t)},I(c(t)),9,fm))),128))])):Y(``,!0)]),i.value?(U(),G(cm,{key:0,listing:e.listing,now:a.value,class:`list`},null,8,[`listing`,`now`])):Y(``,!0)]))}}),[[`__scopeId`,`data-v-f69c9da8`]]),mm={class:`folder`},hm={class:`page`},gm={class:`summary`},_m=wp(V({__name:`FolderView`,props:{folder:{},rootName:{},listing:{}},setup(e){let t=Date.now();return(n,r)=>(U(),W(`main`,mm,[K(`div`,hm,[K(`header`,null,[q($,{name:`folder`,size:22}),K(`h1`,null,I(B(qp)(e.folder,e.rootName)),1),K(`span`,gm,[J(I(B(op)(e.listing.files.length,`file`))+` `,1),e.listing.folders.length?(U(),W(H,{key:0},[J(` · `+I(B(op)(e.listing.folders.length,`folder`)),1)],64)):Y(``,!0)])]),e.listing.files.length||e.listing.folders.length?(U(),G(cm,{key:0,listing:e.listing,now:B(t),class:`list`},null,8,[`listing`,`now`])):Y(``,!0),r[0]||=K(`p`,{class:`hint`},[J(` No `),K(`code`,null,`README.md`),J(` or `),K(`code`,null,`AGENTS.md`),J(` here. Add one and this folder opens with it. `)],-1)])]))}}),[[`__scopeId`,`data-v-fb616f2e`]]),vm=`
20
+ `)}function Jf(e,t,n){let r=n-1;for(;r>t&&(e[r]??``).trim()===``;)r--;return r+1}function Yf(e){return e.trim().toLowerCase().replace(/[^\p{L}\p{N}\s_-]/gu,``).replace(/\s/g,`-`)}function Xf(e,t,n){let r=(t?.children??[]).filter(e=>e.type===`text`||e.type===`code_inline`).map(e=>e.content).join(``),i=Yf(r)||`section`,a=n.slugs.get(i)??0;n.slugs.set(i,a+1);let o=a===0?i:`${i}-${a}`;e.attrSet(`id`,o),n.headings.push({level:Number(e.tag.slice(1)),text:r,slug:o,line:(e.map?.[0]??0)+1})}function Zf(e,t,n){let r=t[n+2];if(t[n+1]?.type!==`paragraph_open`||r?.type!==`inline`)return;let i=/^\[!(\w+)\]\s*/.exec(r.content),a=i?.[1]?.toLowerCase(),o=a?Hf[a]:void 0;if(!i||!a||!o)return;e.attrJoin(`class`,`alert alert-${a}`),e.attrSet(`data-alert`,o),r.content=r.content.slice(i[0].length);let s=r.children??[],c=s[0];c?.type===`text`&&(c.content=c.content.replace(/^\[!\w+\]\s*/,``),c.content===``&&s[1]?.type===`softbreak`?s.splice(0,2):c.content===``&&s.splice(0,1))}function Qf(e,t,n){let r=e.tokens,i=r[n+2];if(r[n+1]?.type!==`paragraph_open`||i?.type!==`inline`)return;let a=i.children?.[0],o=a?.type===`text`?/^\[([ xX])\]\s+/.exec(a.content):null;if(!a||!o)return;a.content=a.content.slice(o[0].length);let s=new e.Token(`html_inline`,``,0);s.content=`<input type="checkbox" disabled${o[1]===` `?``:` checked`}> `,i.children?.unshift(s),t.attrJoin(`class`,`task-item`)}function $f(e,t){for(let n of e){if(n.type===`link_open`){let e=String(n.attrGet(`href`)??``);if(!e||jf(e))continue;if(e.startsWith(`#`)){n.attrSet(`href`,If({path:t,anchor:e.slice(1)}));continue}let[r=``,i=``]=e.split(`#`),a=Af(t,r);if(!a)continue;n.attrSet(`href`,Mf(a)?If({path:a,anchor:i||null}):`/raw/${Nf(a)}`)}if(n.type===`image`){let e=String(n.attrGet(`src`)??``),r=e&&!jf(e)?Af(t,e):null;r&&n.attrSet(`src`,`/raw/${Nf(r)}`),n.attrSet(`loading`,`lazy`)}}}var ep=`boca`,tp={typed:``,at:0};function np(e,t,n){let r=n-e.at<=1500?e.typed:``;if(t===`boca`[r.length]){let e=r+t,i=e===ep;return{state:{typed:i?``:e,at:n},consumed:e.length>=2,undoFirst:e.length===2,matched:i}}return{state:{typed:t===`b`?t:``,at:n},consumed:!1,undoFirst:!1,matched:!1}}var rp=[{action:`palette`,keys:`⌘K`,label:`Search files, headings and text`},{action:`comment`,keys:`C`,label:`Comment on the selection`},{action:`suggest`,keys:`S`,label:`Suggest an edit to the selection`},{action:`prompt`,keys:`P`,label:`Review and copy the prompt`},{action:`toggleRead`,keys:`R`,label:`Mark the file read / unread`},{action:`toggleMode`,keys:`V`,label:`Switch Read / Source view`},{action:`nextFile`,keys:`]`,label:`Next file`},{action:`previousFile`,keys:`[`,label:`Previous file`},{action:`toggleFiles`,keys:`B`,label:`Show / hide the files panel`},{action:`toggleComments`,keys:`N`,label:`Show / hide the comments panel`},{action:`help`,keys:`?`,label:`Show shortcuts`}];function ip(e){let t=e.key.toLowerCase();if((e.metaKey||e.ctrlKey)&&!e.altKey&&t===`k`)return`palette`;if(e.editing||e.metaKey||e.ctrlKey||e.altKey)return null;switch(e.key){case`c`:return`comment`;case`s`:return`suggest`;case`p`:return`prompt`;case`r`:return`toggleRead`;case`v`:return`toggleMode`;case`]`:return`nextFile`;case`[`:return`previousFile`;case`b`:return`toggleFiles`;case`n`:return`toggleComments`;case`?`:return`help`;default:return null}}function ap(e){return e.normalize(`NFD`).replace(/\p{Diacritic}/gu,``).toLowerCase()}function op(e,t,n=`${t}s`){return`${e} ${e===1?t:n}`}function sp(e,t){let n=Math.floor((t-e)/6e4);if(n<1)return`just now`;if(n<60)return`${n} min ago`;let r=Math.floor(n/60);if(r<24)return`${r} h ago`;let i=Math.floor(r/24);return i<14?`${i} d ago`:new Date(e).toISOString().slice(0,10)}var cp=[`width`,`height`,`stroke-width`],lp=[`d`],$=V({__name:`Icon`,props:{name:{},size:{default:16},strokeWidth:{default:2}},setup(e){let t={search:[`M11 18a7 7 0 1 0 0-14 7 7 0 0 0 0 14z`,`M20 20l-3.5-3.5`],file:[`M14 3H6a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V9z`,`M14 3v6h6`],folder:[`M3 7a2 2 0 0 1 2-2h4l2 2h8a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z`],"chevron-right":[`M9 6l6 6-6 6`],"chevron-left":[`M15 6l-6 6 6 6`],"chevron-down":[`M6 9l6 6 6-6`],check:[`M5 12l5 5 9-10`],copy:[`M9 9h10a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2H11a2 2 0 0 1-2-2z`,`M5 15V5a2 2 0 0 1 2-2h10`],comment:[`M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z`],edit:[`M12 20h9`,`M16.5 3.5a2.1 2.1 0 0 1 3 3L7 19l-4 1 1-4z`],trash:[`M4 7h16`,`M10 11v6M14 11v6`,`M6 7l1 13h10l1-13`,`M9 7V4h6v3`],close:[`M6 6l12 12M18 6L6 18`],plus:[`M12 5v14M5 12h14`],link:[`M10 13a5 5 0 0 0 7.5.5l3-3a5 5 0 0 0-7-7l-1.7 1.7`,`M14 11a5 5 0 0 0-7.5-.5l-3 3a5 5 0 0 0 7 7l1.7-1.7`],"arrow-right":[`M5 12h14M13 6l6 6-6 6`],"panel-left":[`M3 5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z`,`M9 3v18`],"panel-right":[`M3 5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z`,`M15 3v18`],expand:[`M15 3h6v6`,`M9 21H3v-6`,`M21 3l-7 7`,`M3 21l7-7`],keyboard:[`M3 7a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2v10a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z`,`M7 10h.01M11 10h.01M15 10h.01M8 14h8`]};return(n,r)=>(U(),W(`svg`,{width:e.size,height:e.size,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,"stroke-width":e.strokeWidth,"stroke-linecap":`round`,"stroke-linejoin":`round`,"aria-hidden":`true`},[(U(!0),W(H,null,Mr(t[e.name],e=>(U(),W(`path`,{key:e,d:e},null,8,lp))),128))],8,cp))}}),up=.7;function dp(e,t){let n=ap(e.replace(/\s+/g,``)),r=ap(t);if(!n)return 0;let i=r.lastIndexOf(`/`)+1,a=0,o=-2,s=0;for(let e of n){let t=r.indexOf(e,s);if(t<0)return null;a+=1,t===o+1&&(a+=3),t>=i&&(a+=2),(t===i||r[t-1]===`-`||r[t-1]===`_`)&&(a+=2),o=t,s=t+1}return a-r.length/100}function fp(e,t){let n=e.map(e=>({file:e,score:dp(t,e.path)})).filter(e=>e.score!==null),r=Math.max(0,...n.map(e=>e.score));return n.filter(e=>e.score>=r*up).toSorted((e,t)=>t.file.mtimeMs-e.file.mtimeMs||t.score-e.score).slice(0,8).map(({file:e})=>({key:`file:${e.path}`,kind:`file`,path:e.path,line:null,label:e.path,detail:e.title??``,mtimeMs:e.mtimeMs}))}function pp(e){return e.map(e=>({key:`${e.kind}:${e.path}:${e.line}`,kind:e.kind,path:e.path,line:e.line,label:e.kind===`heading`?`${`#`.repeat(e.level??1)} ${e.text}`:e.text,detail:`${e.path}:L${e.line}`,mtimeMs:null}))}function mp(e,t){let n=ap(t.trim()),r=n?ap(e).indexOf(n):-1;return r<0?[{text:e,match:!1}]:[{text:e.slice(0,r),match:!1},{text:e.slice(r,r+n.length),match:!0},{text:e.slice(r+n.length),match:!1}].filter(e=>e.text)}var hp={class:`field`},gp=[`aria-activedescendant`],_p={id:`palette-results`,class:`results`,role:`listbox`},vp={class:`group`,role:`presentation`},yp=[`id`,`data-index`,`aria-selected`,`onMousemove`,`onClick`],bp={class:`label`},xp={key:0},Sp={class:`detail`},Cp=[`datetime`,`title`],wp={key:0,class:`empty`},Tp=V({__name:`CommandPalette`,props:{open:{type:Boolean},files:{}},emits:[`close`,`go`],setup(e,{emit:t}){let n=e,r=t,i=z(null),a=z(null),o=z(``),s=z([]),c=z(0),l=z(!1),u=z(Date.now()),d=X(()=>[...fp(n.files,o.value),...s.value]),f=X(()=>[{kind:`file`,label:o.value.trim()?`Files`:`Recent files`},{kind:`heading`,label:`Headings`},{kind:`text`,label:`Text`}]),p=null,m;qn(o,e=>{c.value=0,clearTimeout(m),p?.abort(),e.trim().length<2?(s.value=[],l.value=!1):(l.value=!0,m=setTimeout(async()=>{let t=new AbortController;p=t;try{s.value=pp((await us(e,t.signal)).hits)}catch{}finally{p===t&&!t.signal.aborted&&(l.value=!1)}},120))}),qn(()=>n.open,e=>{e?(o.value=``,s.value=[],u.value=Date.now(),i.value?.showModal(),a.value?.focus()):i.value?.close()},{flush:`post`});function h(e){return d.value.indexOf(e)}function g(e){e&&r(`go`,e)}function _(e){let t=d.value.length;e.key===`ArrowDown`?(e.preventDefault(),c.value=t?(c.value+1)%t:0):e.key===`ArrowUp`?(e.preventDefault(),c.value=t?(c.value-1+t)%t:0):e.key===`Enter`&&(e.preventDefault(),g(d.value[c.value]))}return qn(c,e=>{i.value?.querySelector(`[data-index="${e}"]`)?.scrollIntoView({block:`nearest`})}),(e,t)=>(U(),W(`dialog`,{ref_key:`dialog`,ref:i,class:`palette`,"aria-label":`Go to`,onClose:t[1]||=e=>r(`close`),onKeydown:_},[K(`label`,hp,[q($,{name:`search`,size:18}),t[2]||=K(`span`,{class:`visually-hidden`},`Search files, headings and text`,-1),Vn(K(`input`,{ref_key:`input`,ref:a,"onUpdate:modelValue":t[0]||=e=>o.value=e,type:`text`,placeholder:`Search files, headings and text…`,role:`combobox`,"aria-controls":`palette-results`,"aria-activedescendant":d.value.length?`palette-${c.value}`:void 0,"aria-expanded":`true`,autocomplete:`off`,spellcheck:`false`},null,8,gp),[[Mo,o.value]]),t[3]||=K(`kbd`,null,`Esc`,-1)]),K(`div`,_p,[(U(!0),W(H,null,Mr(f.value,e=>(U(),W(H,{key:e.kind},[d.value.some(t=>t.kind===e.kind)?(U(),W(H,{key:0},[K(`div`,vp,I(e.label),1),(U(!0),W(H,null,Mr(d.value.filter(t=>t.kind===e.kind),e=>(U(),W(`button`,{id:`palette-${h(e)}`,key:e.key,type:`button`,role:`option`,class:`item`,"data-index":h(e),"aria-selected":h(e)===c.value,onMousemove:t=>c.value=h(e),onClick:t=>g(e)},[e.kind===`file`?(U(),G($,{key:0,name:`file`,size:15})):Y(``,!0),K(`span`,bp,[(U(!0),W(H,null,Mr(B(mp)(e.label,o.value),(e,t)=>(U(),W(H,{key:t},[e.match?(U(),W(`strong`,xp,I(e.text),1)):(U(),W(H,{key:1},[J(I(e.text),1)],64))],64))),128))]),K(`span`,Sp,I(e.detail),1),e.mtimeMs===null?Y(``,!0):(U(),W(`time`,{key:1,class:`age`,datetime:new Date(e.mtimeMs).toISOString(),title:new Date(e.mtimeMs).toLocaleString()},I(B(sp)(e.mtimeMs,u.value)),9,Cp))],40,yp))),128))],64)):Y(``,!0)],64))),128)),d.value.length===0?(U(),W(`p`,wp,I(o.value.trim().length<2?`No Markdown files here.`:l.value?`Searching…`:`Nothing found.`),1)):Y(``,!0)]),t[4]||=K(`footer`,null,[K(`span`,null,[K(`kbd`,null,`↑`),K(`kbd`,null,`↓`),J(` move`)]),K(`span`,null,[K(`kbd`,null,`↵`),J(` open`)])],-1)],544))}}),Ep=(e,t)=>{let n=e.__vccOpts||e;for(let[e,r]of t)n[e]=r;return n},Dp=Ep(Tp,[[`__scopeId`,`data-v-82807646`]]),Op={class:`rail`,"aria-label":`Comments`},kp={class:`tabs`,role:`tablist`},Ap=[`aria-selected`],jp=[`aria-selected`],Mp={key:0,class:`list`},Np=[`href`],Pp={class:`meta`},Fp={key:0,class:`kind`},Ip={key:0,class:`quote`},Lp={key:1,class:`suggestion`},Rp={key:2,class:`body`},zp={key:1,class:`empty`},Bp={key:0},Vp={key:1},Hp=[`disabled`],Up=[`disabled`],Wp=Ep(V({__name:`CommentsRail`,props:{comments:{},currentPath:{}},emits:[`openPrompt`,`clear`],setup(e,{emit:t}){let n=e,r=t,i=z(`file`),a=X(()=>n.comments.filter(e=>e.path===n.currentPath)),o=X(()=>Qo(i.value===`file`?a.value:n.comments));function s(e){return e.startLine===e.endLine?`L${e.startLine}`:`L${e.startLine}-L${e.endLine}`}function c(){let e=o.value.map(e=>e.id),t=i.value===`file`?`in this file`:`in every file`;e.length&&window.confirm(`Delete ${e.length} comments ${t}?`)&&r(`clear`,e)}return(t,n)=>(U(),W(`aside`,Op,[K(`div`,kp,[K(`button`,{type:`button`,role:`tab`,"aria-selected":i.value===`file`,onClick:n[0]||=e=>i.value=`file`},[n[3]||=J(` This file `,-1),K(`span`,null,I(a.value.length),1)],8,Ap),K(`button`,{type:`button`,role:`tab`,"aria-selected":i.value===`all`,onClick:n[1]||=e=>i.value=`all`},[n[4]||=J(` All files `,-1),K(`span`,null,I(e.comments.length),1)],8,jp)]),o.value.length?(U(),W(`ol`,Mp,[(U(!0),W(H,null,Mr(o.value,e=>(U(),W(`li`,{key:e.id},[K(`a`,{href:B(If)({path:e.path,anchor:`comment-${e.id}`}),class:`item`},[K(`span`,Pp,[e.suggestion===null?Y(``,!0):(U(),W(`span`,Fp,`Suggested edit`)),K(`code`,null,I(i.value===`all`?`${e.path}:`:``)+I(s(e)),1)]),e.quote?(U(),W(`span`,Ip,`“`+I(e.quote)+`”`,1)):Y(``,!0),e.suggestion===null?Y(``,!0):(U(),W(`span`,Lp,`→ `+I(e.suggestion),1)),e.body?(U(),W(`span`,Rp,I(e.body),1)):Y(``,!0)],8,Np)]))),128))])):(U(),W(`div`,zp,[q($,{name:`comment`,size:20}),i.value===`file`?(U(),W(`p`,Bp,` Select text to comment on it, or click a line number. Your comments stay in this browser. `)):(U(),W(`p`,Vp,`No comments yet.`))])),K(`footer`,null,[K(`button`,{type:`button`,class:`btn btn-comment`,disabled:e.comments.length===0,onClick:n[2]||=e=>r(`openPrompt`)},[q($,{name:`copy`}),n[5]||=J(` Copy all prompt `,-1)],8,Hp),K(`button`,{type:`button`,class:`btn`,disabled:o.value.length===0,onClick:c},`Clear`,8,Up)])]))}}),[[`__scopeId`,`data-v-c8817f32`]]),Gp=[`readme.md`,`agents.md`,`index.md`,`readme.markdown`];function Kp(e,t){return e.filter(e=>Zp(e.path,t)!==null).map(e=>({path:e.path,rank:Gp.indexOf(Qp(e.path).toLowerCase())})).filter(e=>e.rank>=0).toSorted((e,t)=>e.rank-t.rank).map(e=>e.path)}function qp(e,t){return t===``||e.some(e=>e.path.startsWith(t))}function Jp(e,t,n,r){let i=new Map,a=[];for(let o of e){if(!o.path.startsWith(t))continue;let e=o.path.slice(t.length),s=e.indexOf(`/`),c=es(o,n),l=r.get(o.path)??0;if(s<0){a.push({name:e,path:o.path,title:o.title,status:c,comments:l,mtimeMs:o.mtimeMs});continue}let u=e.slice(0,s),d=i.get(u)??{name:u,path:`${t}${u}/`,files:0,unread:0,comments:0};d.files+=1,d.unread+=c===`read`?0:1,d.comments+=l,i.set(u,d)}return{folders:[...i.values()].toSorted(Xp),files:a.toSorted(Xp)}}function Yp(e,t){return e===``?t:e.slice(0,-1).split(`/`).at(-1)??t}function Xp(e,t){return e.name.localeCompare(t.name,`en`,{sensitivity:`base`,numeric:!0})}function Zp(e,t){if(!e.startsWith(t))return null;let n=e.slice(t.length);return n.includes(`/`)?null:n}function Qp(e){return e.slice(e.lastIndexOf(`/`)+1)}var $p={class:`list`},em=[`href`],tm={class:`name`},nm={class:`meta`},rm=[`aria-label`],im=[`href`],am={class:`name`},om={key:0,class:`title`},sm={key:0,class:`badge`},cm={class:`meta`},lm=[`aria-label`],um=Ep(V({__name:`FolderList`,props:{listing:{},now:{}},setup(e){return(t,n)=>(U(),W(`ul`,$p,[(U(!0),W(H,null,Mr(e.listing.folders,e=>(U(),W(`li`,{key:e.path},[K(`a`,{class:`row`,href:B(If)({path:e.path,anchor:null})},[q($,{name:`folder`,class:`icon`}),K(`span`,tm,I(e.name),1),K(`span`,nm,[J(I(B(op)(e.files,`file`))+` `,1),e.unread?(U(),W(H,{key:0},[J(` · `+I(e.unread)+` unread`,1)],64)):Y(``,!0)]),e.comments?(U(),W(`span`,{key:0,class:`count`,"aria-label":`${e.comments} comments`},[q($,{name:`comment`,size:13}),J(I(e.comments),1)],8,rm)):Y(``,!0)],8,em)]))),128)),(U(!0),W(H,null,Mr(e.listing.files,t=>(U(),W(`li`,{key:t.path},[K(`a`,{class:ye([`row`,t.status]),href:B(If)({path:t.path,anchor:null})},[q($,{name:t.status===`read`?`check`:`file`,class:`icon status`},null,8,[`name`]),K(`span`,am,[J(I(t.name)+` `,1),t.title?(U(),W(`span`,om,I(t.title),1)):Y(``,!0)]),t.status===`edited`?(U(),W(`span`,sm,`edited`)):Y(``,!0),K(`span`,cm,I(B(sp)(t.mtimeMs,e.now)),1),t.comments?(U(),W(`span`,{key:1,class:`count`,"aria-label":`${t.comments} comments`},[q($,{name:`comment`,size:13}),J(I(t.comments),1)],8,lm)):Y(``,!0)],10,im)]))),128))]))}}),[[`__scopeId`,`data-v-58e7e372`]]),dm={class:`strip`,"aria-label":`Folder`},fm=[`aria-expanded`],pm={key:0,class:`segmented`,role:`radiogroup`,"aria-label":`Open with`},mm=[`aria-checked`,`onClick`],hm=Ep(V({__name:`FolderStrip`,props:{folder:{},rootName:{},listing:{},entries:{},entry:{}},emits:[`chooseEntry`],setup(e,{emit:t}){let n=e,r=t,i=z(!1),a=z(Date.now()),o=X(()=>{let e=[op(n.listing.files.length,`file`)];return n.listing.folders.length&&e.push(op(n.listing.folders.length,`folder`)),`${e.join(` · `)} in ${Yp(n.folder,n.rootName)}`});function s(){i.value=!i.value,a.value=Date.now()}function c(e){return e.slice(e.lastIndexOf(`/`)+1)}return(t,n)=>(U(),W(`section`,dm,[K(`header`,null,[K(`button`,{type:`button`,class:`toggle`,"aria-expanded":i.value,onClick:s},[q($,{name:i.value?`chevron-down`:`chevron-right`,size:14,"stroke-width":2.4},null,8,[`name`]),q($,{name:`folder`,size:15}),J(` `+I(o.value),1)],8,fm),e.entries.length>1?(U(),W(`div`,pm,[(U(!0),W(H,null,Mr(e.entries,t=>(U(),W(`button`,{key:t,type:`button`,role:`radio`,"aria-checked":t===e.entry,onClick:e=>r(`chooseEntry`,t)},I(c(t)),9,mm))),128))])):Y(``,!0)]),i.value?(U(),G(um,{key:0,listing:e.listing,now:a.value,class:`list`},null,8,[`listing`,`now`])):Y(``,!0)]))}}),[[`__scopeId`,`data-v-f69c9da8`]]),gm={class:`folder`},_m={class:`page`},vm={class:`summary`},ym=Ep(V({__name:`FolderView`,props:{folder:{},rootName:{},listing:{}},setup(e){let t=Date.now();return(n,r)=>(U(),W(`main`,gm,[K(`div`,_m,[K(`header`,null,[q($,{name:`folder`,size:22}),K(`h1`,null,I(B(Yp)(e.folder,e.rootName)),1),K(`span`,vm,[J(I(B(op)(e.listing.files.length,`file`))+` `,1),e.listing.folders.length?(U(),W(H,{key:0},[J(` · `+I(B(op)(e.listing.folders.length,`folder`)),1)],64)):Y(``,!0)])]),e.listing.files.length||e.listing.folders.length?(U(),G(um,{key:0,listing:e.listing,now:B(t),class:`list`},null,8,[`listing`,`now`])):Y(``,!0),r[0]||=K(`p`,{class:`hint`},[J(` No `),K(`code`,null,`README.md`),J(` or `),K(`code`,null,`AGENTS.md`),J(` here. Add one and this folder opens with it. `)],-1)])]))}}),[[`__scopeId`,`data-v-fb616f2e`]]),bm=`
21
21
  =====
22
- `;function ym(e,t){let n=e.startLine===e.endLine?`L${e.startLine}`:`L${e.startLine}-L${e.endLine}`;return`${t}${e.path}:${n}`}function bm(e,t){let n=[ym(e,t.promptBase)];e.suggestion===null?t.includeQuotes&&e.quote&&n.push(Sm(e.quote)):n.push(Cm(`ORIGINAL`,e.quote??``),Cm(`SUGGESTED`,e.suggestion));let r=e.body.trim();return r&&n.push(r),n.join(`
23
- `)}function xm(e,t){return Qo(e).map(e=>bm(e,t)).join(vm)}function Sm(e){return e.trim().split(/\r?\n/).map(e=>`> ${e.trim()}`.trimEnd()).join(`
24
- `)}function Cm(e,t){let n=Math.max(2,...[...t.matchAll(/`+/g)].map(e=>e[0].length)),r="`".repeat(n+1);return`${e}:\n${r}\n${t}\n${r}`}var wm={class:`summary`},Tm={class:`options`},Em={class:`segmented`,role:`radiogroup`,"aria-label":`Comments to include`},Dm=[`aria-checked`,`disabled`],Om=[`aria-checked`],km=[`checked`],Am={class:`preview`},jm=[`disabled`],Mm=wp(V({__name:`PromptDialog`,props:{open:{type:Boolean},comments:{},currentPath:{},promptBase:{},includeQuotes:{type:Boolean}},emits:[`close`,`update:includeQuotes`,`copied`],setup(e,{emit:t}){let n=e,r=t,i=z(null),a=z(`all`),o=z(!1),s=z(``),c=X(()=>n.comments.filter(e=>e.path===n.currentPath)),l=X(()=>a.value===`file`?c.value:n.comments),u=X(()=>xm(l.value,{promptBase:n.promptBase,includeQuotes:n.includeQuotes}));qn(u,e=>s.value=e,{immediate:!0}),qn(()=>n.open,e=>{e?(a.value=`all`,s.value=u.value,i.value?.showModal()):i.value?.close()},{flush:`post`});async function d(){s.value.trim()&&await Ds(s.value)&&r(`copied`,l.value.length,l.value.map(e=>e.id),o.value)}function f(e){e.key===`Enter`&&(e.metaKey||e.ctrlKey)&&(e.preventDefault(),d())}return(t,n)=>(U(),W(`dialog`,{ref_key:`dialog`,ref:i,class:`prompt`,"aria-labelledby":`prompt-title`,onClose:n[7]||=e=>r(`close`),onKeydown:f},[K(`header`,null,[n[8]||=K(`h2`,{id:`prompt-title`},`Review prompt`,-1),K(`span`,wm,I(B(op)(l.value.length,`comment`)),1),K(`button`,{type:`button`,class:`btn-icon`,"aria-label":`Close`,onClick:n[0]||=e=>r(`close`)},[q($,{name:`close`,size:18})])]),K(`div`,Tm,[K(`div`,Em,[K(`button`,{type:`button`,role:`radio`,"aria-checked":a.value===`file`,disabled:!e.currentPath,onClick:n[1]||=e=>a.value=`file`},` This file (`+I(c.value.length)+`) `,9,Dm),K(`button`,{type:`button`,role:`radio`,"aria-checked":a.value===`all`,onClick:n[2]||=e=>a.value=`all`},` All files (`+I(e.comments.length)+`) `,9,Om)]),K(`label`,null,[K(`input`,{type:`checkbox`,checked:e.includeQuotes,onChange:n[3]||=e=>r(`update:includeQuotes`,e.target.checked)},null,40,km),n[9]||=J(` Quote the selected text `,-1)])]),K(`label`,Am,[n[10]||=K(`span`,{class:`visually-hidden`},`Prompt`,-1),Vn(K(`textarea`,{"onUpdate:modelValue":n[4]||=e=>s.value=e,spellcheck:`false`},null,512),[[Mo,s.value]])]),K(`footer`,null,[K(`label`,null,[Vn(K(`input`,{"onUpdate:modelValue":n[5]||=e=>o.value=e,type:`checkbox`},null,512),[[No,o.value]]),n[11]||=J(` Delete these comments after copying `,-1)]),K(`button`,{type:`button`,class:`btn`,onClick:n[6]||=e=>s.value=u.value},`Reset`),K(`button`,{type:`button`,class:`btn btn-comment`,disabled:!s.value.trim(),onClick:d},[q($,{name:`copy`}),n[12]||=J(` Copy prompt `,-1),n[13]||=K(`kbd`,null,`⌘↵`,-1)],8,jm)])],544))}}),[[`__scopeId`,`data-v-c5a0d837`]]),Nm=4;function Pm(e,t,n){let r=Im(n);if(!r)return t;let i=[],a=``;for(let n=t.startLine;n<=t.endLine;n++){let t=Im(e[n-1]??``);t&&(a&&(a+=` `),i.push({line:n,start:a.length}),a+=t)}let o=a.indexOf(r),s=o+r.length;if(o<0){let e=r.split(` `);o=a.indexOf(e.slice(0,Nm).join(` `));let n=e.slice(-4).join(` `),i=o<0?-1:a.indexOf(n,o);if(o<0)return t;s=i<0?o+1:i+n.length}return{startLine:Fm(i,o),endLine:Fm(i,s-1)}}function Fm(e,t){let n=e[0]?.line??1;for(let r of e){if(r.start>t)break;n=r.line}return n}function Im(e){return e.replace(/!?\[([^\]]*)\]\([^)]*\)/g,`$1`).replace(/^\s{0,3}(#{1,6}\s+|>\s?|[-*+]\s+(\[[ xX]\]\s+)?|\d+[.)]\s+)/gm,``).replace(/[*_`~|]/g,``).replace(/\s+/g,` `).trim().toLowerCase()}function Lm(e,t){let n=null;for(let r of e)if(r.startLine<=t)n=r;else break;return n??e[0]??null}function Rm(e,t){return e.quote??t.slice(e.startLine-1,e.endLine).join(`
25
- `)}function zm(e,t,n){let r={mode:e,...t,body:``,suggestion:``,editingId:null};return e===`suggest`&&(r.suggestion=Rm(r,n)),r}function Bm(e){return{mode:e.suggestion===null?`comment`:`suggest`,startLine:e.startLine,endLine:e.endLine,quote:e.quote,body:e.body,suggestion:e.suggestion??``,editingId:e.id}}function Vm(e,t,n){if(e.mode===t)return e;let r=t===`suggest`&&!e.suggestion?Rm(e,n):e.suggestion;return{...e,mode:t,suggestion:r}}function Hm(e,t,n){let r=e.body.trim();if(e.mode===`suggest`){let i=Rm(e,n);return e.suggestion===i&&!r?null:{path:t,startLine:e.startLine,endLine:e.endLine,quote:i,body:r,suggestion:e.suggestion}}return r?{path:t,startLine:e.startLine,endLine:e.endLine,quote:e.quote,body:r,suggestion:null}:null}function Um(e){let t=[],n=null,r=e[0]?.trim()===`---`;return e.forEach((e,i)=>{if(r){t.push(`meta`),i>0&&e.trim()===`---`&&(r=!1);return}let a=/^\s{0,3}(`{3,}|~{3,})/.exec(e);if(a?.[1]){let e=a[1].charAt(0);n===null?n=e:n===e&&(n=null),t.push(`fence`)}else n===null?/^\s{0,3}#{1,6}\s/.test(e)?t.push(`heading`):/^\s{0,3}>/.test(e)?t.push(`quote`):/^\s*([-*+]|\d+[.)])\s/.test(e)?t.push(`list`):t.push(`text`):t.push(`code`)}),t}function Wm(e,t,n=4){let r=[];for(let i of e.toSorted((e,t)=>e.top-t.top)){let e=r.at(-1),a=e?Math.max(i.top,e.top+t+n):i.top;r.push({id:i.id,top:a})}return r}function Gm(e){return e.marginSpace>=e.width?{side:`margin`,top:Math.max(0,e.anchor.top-10),left:e.pageWidth-14}:{side:`below`,top:e.anchor.bottom+10,left:Math.max(0,e.pageWidth-e.gutter-e.width)}}function Km(e){return e.toSorted((e,t)=>e.startLine-t.startLine||e.createdAt-t.createdAt)}function qm(e){return e.startLine===e.endLine?`Line ${e.startLine}`:`Lines ${e.startLine}–${e.endLine}`}var Jm=[`id`],Ym={key:0,class:`kind`},Xm={class:`ref`},Zm={class:`actions`},Qm={key:0,class:`diff`},$m={class:`del`},eh={class:`add`},th={key:1},nh={key:2},rh=wp(V({__name:`CommentCard`,props:{comment:{},promptBase:{}},emits:[`edit`,`remove`,`copy`],setup(e,{emit:t}){let n=t;return(t,r)=>(U(),W(`article`,{id:`comment-${e.comment.id}`,class:ye([`card`,{suggestion:e.comment.suggestion!==null}])},[K(`header`,null,[e.comment.suggestion===null?Y(``,!0):(U(),W(`span`,Ym,`Suggested edit`)),K(`code`,Xm,I(B(ym)(e.comment,e.promptBase)),1),K(`span`,Zm,[K(`button`,{type:`button`,class:`btn btn-small`,onClick:r[0]||=e=>n(`copy`)},`Copy prompt`),K(`button`,{type:`button`,class:`btn-icon`,"aria-label":`Edit comment`,title:`Edit`,onClick:r[1]||=e=>n(`edit`)},[q($,{name:`edit`,size:15})]),K(`button`,{type:`button`,class:`btn-icon`,"aria-label":`Delete comment`,title:`Delete`,onClick:r[2]||=e=>n(`remove`)},[q($,{name:`trash`,size:15})])])]),e.comment.suggestion===null?e.comment.quote?(U(),W(`blockquote`,th,I(e.comment.quote),1)):Y(``,!0):(U(),W(`div`,Qm,[K(`pre`,$m,I(e.comment.quote),1),K(`pre`,eh,I(e.comment.suggestion),1)])),e.comment.body?(U(),W(`p`,nh,I(e.comment.body),1)):Y(``,!0)],10,Jm))}}),[[`__scopeId`,`data-v-1b983aee`]]),ih={class:`ref`},ah={class:`segmented`,role:`radiogroup`,"aria-label":`Kind`},oh=[`aria-checked`],sh=[`aria-checked`],ch={key:0},lh={class:`original`},uh={class:`replacement`},dh=wp(V({__name:`CommentComposer`,props:{draft:{},location:{},lines:{}},emits:[`switchMode`,`save`,`cancel`],setup(e,{emit:t}){let n=t,r=z(null);vr(async()=>{await En(),r.value?.focus(),r.value?.scrollIntoView({block:`nearest`,behavior:`smooth`})});function i(e){e.key===`Enter`&&(e.metaKey||e.ctrlKey)?(e.preventDefault(),n(`save`)):e.key===`Escape`&&(e.preventDefault(),n(`cancel`))}async function a(e){n(`switchMode`,e),await En(),r.value?.focus()}return(t,o)=>(U(),W(`form`,{class:ye([`composer`,e.draft.mode]),onSubmit:o[6]||=zo(e=>n(`save`),[`prevent`]),onKeydown:i},[K(`header`,null,[K(`code`,ih,I(e.location),1),K(`div`,ah,[K(`button`,{type:`button`,role:`radio`,"aria-checked":e.draft.mode===`comment`,onClick:o[0]||=e=>a(`comment`)},` Comment `,8,oh),K(`button`,{type:`button`,role:`radio`,"aria-checked":e.draft.mode===`suggest`,onClick:o[1]||=e=>a(`suggest`)},` Suggest edit `,8,sh)])]),e.draft.mode===`comment`?(U(),W(H,{key:0},[e.draft.quote?(U(),W(`blockquote`,ch,I(e.draft.quote),1)):Y(``,!0),K(`label`,null,[o[7]||=K(`span`,{class:`visually-hidden`},`Comment`,-1),Vn(K(`textarea`,{ref_key:`field`,ref:r,"onUpdate:modelValue":o[2]||=t=>e.draft.body=t,rows:`3`,placeholder:`What should change?`},null,512),[[Mo,e.draft.body]])])],64)):(U(),W(H,{key:1},[K(`div`,lh,[o[8]||=K(`span`,{class:`label`},`Replace`,-1),K(`pre`,null,I(B(Rm)(e.draft,e.lines)),1)]),K(`label`,uh,[o[9]||=K(`span`,{class:`label`},`With`,-1),Vn(K(`textarea`,{ref_key:`field`,ref:r,"onUpdate:modelValue":o[3]||=t=>e.draft.suggestion=t,rows:`3`},null,512),[[Mo,e.draft.suggestion]])]),K(`label`,null,[o[10]||=K(`span`,{class:`label`},`Why (optional)`,-1),Vn(K(`input`,{"onUpdate:modelValue":o[4]||=t=>e.draft.body=t,type:`text`},null,512),[[Mo,e.draft.body]])])],64)),K(`footer`,null,[o[11]||=K(`span`,{class:`hint`},[K(`kbd`,null,`⌘↵`),J(` save · `),K(`kbd`,null,`Esc`),J(` cancel`)],-1),K(`button`,{type:`button`,class:`btn`,onClick:o[5]||=e=>n(`cancel`)},`Cancel`),K(`button`,{type:`submit`,class:ye([`btn`,e.draft.mode===`suggest`?`btn-suggest`:`btn-primary`])},I(e.draft.editingId?`Save`:e.draft.mode===`suggest`?`Add suggestion`:`Add comment`),3)])],34))}}),[[`__scopeId`,`data-v-28379e78`]]),fh=[`id`,`aria-label`],ph={class:`top`},mh={key:0,class:`nav`},hh={key:0,class:`diff`},gh={key:1,class:`body`},_h={class:`actions`},vh=wp(V({__name:`MarginComment`,props:{comment:{},placement:{},index:{},total:{}},emits:[`previous`,`next`,`copy`,`edit`,`remove`],setup(e,{emit:t}){let n=e,r=t,i=z(null);return qn(()=>n.placement,()=>i.value?.scrollIntoView({block:`nearest`,behavior:`smooth`}),{flush:`post`,immediate:!0}),(t,n)=>(U(),W(`section`,{id:`comment-${e.comment.id}`,ref_key:`root`,ref:i,class:ye([`margin-pop`,e.placement.side]),style:me({top:`${e.placement.top}px`,left:`${e.placement.left}px`}),"aria-label":`Comment on ${B(qm)(e.comment).toLowerCase()}`},[K(`div`,ph,[K(`span`,null,I(B(qm)(e.comment))+` · `+I(B(sp)(e.comment.createdAt,Date.now())),1),e.total>1?(U(),W(`div`,mh,[K(`button`,{type:`button`,class:`mini`,"aria-label":`Previous comment`,onClick:n[0]||=e=>r(`previous`)},[q($,{name:`chevron-left`,size:15,"stroke-width":2.2})]),K(`span`,null,I(e.index+1)+` / `+I(e.total),1),K(`button`,{type:`button`,class:`mini`,"aria-label":`Next comment`,onClick:n[1]||=e=>r(`next`)},[q($,{name:`chevron-right`,size:15,"stroke-width":2.2})])])):Y(``,!0)]),e.comment.suggestion===null?Y(``,!0):(U(),W(`div`,hh,[K(`del`,null,I(e.comment.quote),1),K(`ins`,null,I(e.comment.suggestion),1)])),e.comment.body?(U(),W(`p`,gh,I(e.comment.body),1)):Y(``,!0),K(`div`,_h,[K(`button`,{type:`button`,class:`text-btn`,onClick:n[2]||=e=>r(`copy`)},[q($,{name:`copy`,size:15}),n[5]||=J(` Copy prompt `,-1)]),n[6]||=K(`span`,{class:`spacer`},null,-1),K(`button`,{type:`button`,class:`mini`,"aria-label":`Edit comment`,title:`Edit`,onClick:n[3]||=e=>r(`edit`)},[q($,{name:`edit`,size:15})]),K(`button`,{type:`button`,class:`mini`,"aria-label":`Delete comment`,title:`Delete`,onClick:n[4]||=e=>r(`remove`)},[q($,{name:`trash`,size:15})])])],14,fh))}}),[[`__scopeId`,`data-v-3cb588af`]]),yh=[`aria-label`],bh={class:`top`},xh={class:`kind`,role:`radiogroup`,"aria-label":`Kind`},Sh=[`aria-checked`],Ch=[`aria-checked`],wh={key:0,class:`plain`},Th={class:`field`},Eh={class:`field`},Dh={class:`foot`},Oh={class:`hint`},kh={type:`submit`,class:`primary`},Ah=wp(V({__name:`MarginComposer`,props:{draft:{},placement:{}},emits:[`switchMode`,`save`,`cancel`],setup(e,{emit:t}){let n=e,r=t,i=z(null),a=z(null);vr(async()=>{await En(),a.value?.focus({preventScroll:!0})}),qn(()=>n.placement,()=>i.value?.scrollIntoView({block:`nearest`,behavior:`smooth`}),{flush:`post`,immediate:!0});function o(e){e.key===`Enter`&&(e.metaKey||e.ctrlKey)?(e.preventDefault(),r(`save`)):e.key===`Escape`&&(e.preventDefault(),r(`cancel`))}async function s(e){r(`switchMode`,e),await En(),a.value?.focus({preventScroll:!0})}return(t,n)=>(U(),W(`form`,{ref_key:`root`,ref:i,class:ye([`margin-pop`,e.placement.side]),style:me({top:`${e.placement.top}px`,left:`${e.placement.left}px`}),"aria-label":e.draft.mode===`suggest`?`Suggest an edit`:`New comment`,onSubmit:n[6]||=zo(e=>r(`save`),[`prevent`]),onKeydown:o},[K(`div`,bh,[K(`span`,null,I(B(qm)(e.draft)),1),K(`div`,xh,[K(`button`,{type:`button`,role:`radio`,"aria-checked":e.draft.mode===`comment`,onClick:n[0]||=e=>s(`comment`)},` Comment `,8,Sh),K(`button`,{type:`button`,role:`radio`,"aria-checked":e.draft.mode===`suggest`,onClick:n[1]||=e=>s(`suggest`)},` Suggest edit `,8,Ch)])]),e.draft.mode===`comment`?(U(),W(`label`,wh,[n[7]||=K(`span`,{class:`visually-hidden`},`Comment`,-1),Vn(K(`textarea`,{ref_key:`field`,ref:a,"onUpdate:modelValue":n[2]||=t=>e.draft.body=t,rows:`3`,placeholder:`Add a comment…`},null,512),[[Mo,e.draft.body]])])):(U(),W(H,{key:1},[K(`label`,Th,[n[8]||=J(` Replace with `,-1),Vn(K(`textarea`,{ref_key:`field`,ref:a,"onUpdate:modelValue":n[3]||=t=>e.draft.suggestion=t,rows:`3`},null,512),[[Mo,e.draft.suggestion]])]),K(`label`,Eh,[n[9]||=K(`span`,null,[J(`Why `),K(`span`,{class:`optional`},`(optional)`)],-1),Vn(K(`input`,{"onUpdate:modelValue":n[4]||=t=>e.draft.body=t,type:`text`},null,512),[[Mo,e.draft.body]])])],64)),K(`div`,Dh,[K(`span`,Oh,I(e.draft.mode===`suggest`?`Preview in the text`:`⌘↵ to save`),1),K(`button`,{type:`button`,class:`ghost`,onClick:n[5]||=e=>r(`cancel`)},`Cancel`),K(`button`,kh,I(e.draft.editingId?`Save`:e.draft.mode===`suggest`?`Suggest`:`Comment`),1)])],46,yh))}}),[[`__scopeId`,`data-v-b21eecf1`]]),jh=`modulepreload`,Mh=function(e){return`/`+e},Nh={},Ph=function(e){return e.pathname.endsWith(`.css`)},Fh=function(e,t,n){if(t in e)return e[t];let r=n();if(!r){e[t]=void 0;return}let i=r.then(()=>{e[t]=void 0},n=>{throw e[t]=void 0,n});return e[t]=i,i},Ih=function(e,t,n){let r=Promise.resolve();if(t&&t.length>0){let e,i=document.querySelector(`meta[property=csp-nonce]`),a=i?.nonce||i?.getAttribute(`nonce`);function o(e){return Promise.all(e.map(e=>Promise.resolve(e).then(e=>({status:`fulfilled`,value:e}),e=>({status:`rejected`,reason:e}))))}function s(e){return import.meta.resolve?new URL(import.meta.resolve(e)):new URL(e,import.meta.url)}r=o(t.map(t=>{t=Mh(t,n);let r=s(t),i=Ph(r);return Fh(Nh,r.href,()=>{if(e===void 0){e={all:new Set,styles:new Set};let t=document.getElementsByTagName(`link`);for(let n=t.length-1;n>=0;n--){let r=t[n];e.all.add(r.href),r.rel===`stylesheet`&&e.styles.add(r.href)}}if((i?e.styles:e.all).has(r.href))return;let t=document.createElement(`link`);if(t.rel=i?`stylesheet`:jh,i||(t.as=`script`),t.crossOrigin=``,t.href=r.href,a&&t.setAttribute(`nonce`,a),document.head.appendChild(t),i)return new Promise((e,n)=>{t.addEventListener(`load`,e),t.addEventListener(`error`,()=>n(Error(`Unable to preload CSS for ${r}`)))})})}).filter(e=>e!==void 0))}function i(e){let t=new Event(`vite:preloadError`,{cancelable:!0});if(t.payload=e,window.dispatchEvent(t),!t.defaultPrevented)throw e}return r.then(t=>{for(let e of t||[])e.status===`rejected`&&i(e.reason);return e().catch(i)})},Lh=new Map,Rh=null,zh=null,Bh=0,Vh=Promise.resolve();function Hh(e,t){return`${e}\n${t}`}function Uh(e){return((e instanceof Error?e.message:String(e)).split(`
26
- `).find(e=>e.trim())??`Invalid diagram`).trim().replace(/:$/,``)}function Wh(e,t){let n=Hh(t,e),r=Lh.get(n);if(r)return r;let i=Gh(()=>Kh(e,t));return Lh.set(n,i),i}function Gh(e){let t=Vh.then(e,e);return Vh=t.catch(()=>void 0),t}async function Kh(e,t){let n=await qh();zh!==t&&(n.initialize({startOnLoad:!1,securityLevel:`strict`,theme:t===`dark`?`dark`:`default`,fontFamily:`IBM Plex Sans, system-ui, sans-serif`}),zh=t);let r=`mdifit-diagram-${++Bh}`;try{await n.parse(e);let{svg:t}=await n.render(r,e);return{svg:t,error:null}}catch(e){return{svg:null,error:Uh(e)}}finally{document.getElementById(`d${r}`)?.remove(),document.getElementById(r)?.remove()}}function qh(){return Rh??=Ih(()=>import(`./mermaid.core-BlTF5SGB.js`).then(e=>e.default),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18])),Rh}function Jh(){let e=window.matchMedia(`(prefers-color-scheme: dark)`),t=z(e.matches?`dark`:`light`),n=e=>t.value=e.matches?`dark`:`light`;return e.addEventListener(`change`,n),xr(()=>e.removeEventListener(`change`,n)),t}var Yh={class:`diagram`},Xh={class:`tools`},Zh={class:`segmented`,role:`radiogroup`,"aria-label":`Show`},Qh=[`aria-checked`],$h=[`aria-checked`],eg={key:0,class:`error`,role:`status`},tg=[`innerHTML`],ng=[`innerHTML`],rg={key:2,class:`loading`},ig=[`innerHTML`],ag=wp(V({__name:`DiagramBlock`,props:{source:{},codeHtml:{}},setup(e){let t=e,n=Jh(),r=z(null),i=z(`diagram`),a=z(null);return qn(()=>[t.source,n.value],async([e,i])=>{let a=await Wh(e,i);e===t.source&&i===n.value&&(r.value=a)},{immediate:!0}),(t,n)=>(U(),W(`figure`,Yh,[K(`div`,Xh,[K(`div`,Zh,[K(`button`,{type:`button`,role:`radio`,"aria-checked":i.value===`diagram`,onClick:n[0]||=e=>i.value=`diagram`},` Diagram `,8,Qh),K(`button`,{type:`button`,role:`radio`,"aria-checked":i.value===`code`,onClick:n[1]||=e=>i.value=`code`},` Code `,8,$h)]),r.value?.svg&&i.value===`diagram`?(U(),W(`button`,{key:0,type:`button`,class:`btn-icon`,"aria-label":`Open the diagram full size`,title:`Full size`,onClick:n[2]||=e=>a.value?.showModal()},[q($,{name:`expand`})])):Y(``,!0)]),i.value===`code`||r.value?.error?(U(),W(H,{key:0},[r.value?.error&&i.value===`diagram`?(U(),W(`p`,eg,` Mermaid: `+I(r.value.error),1)):Y(``,!0),K(`div`,{class:`markdown`,"data-doc":``,innerHTML:e.codeHtml},null,8,tg)],64)):r.value?.svg?(U(),W(`div`,{key:1,class:`svg`,"data-doc":``,innerHTML:r.value.svg},null,8,ng)):(U(),W(`p`,rg,`Drawing diagram…`)),K(`dialog`,{ref_key:`dialog`,ref:a,class:`full`,"aria-label":`Diagram`,onClick:n[4]||=zo(e=>a.value?.close(),[`self`])},[K(`header`,null,[n[5]||=K(`span`,null,`Diagram`,-1),K(`button`,{type:`button`,class:`btn-icon`,"aria-label":`Close`,onClick:n[3]||=e=>a.value?.close()},[q($,{name:`close`,size:18})])]),r.value?.svg?(U(),W(`div`,{key:0,class:`svg-full`,innerHTML:r.value.svg},null,8,ig)):Y(``,!0)],512)]))}}),[[`__scopeId`,`data-v-df7e320a`]]),og={class:`read`},sg=[`data-line-start`,`data-line-end`],cg=[`aria-label`,`onClick`],lg=[`innerHTML`],ug=wp(V({__name:`ReadView`,props:{blocks:{}},emits:[`addAt`],setup(e,{emit:t}){let n=t;return(t,r)=>(U(),W(`div`,og,[(U(!0),W(H,null,Mr(e.blocks,e=>(U(),W(`section`,{key:e.key,class:`block`,"data-line-start":e.startLine,"data-line-end":e.endLine},[K(`button`,{type:`button`,class:`add`,"aria-label":`Comment on line ${e.startLine}`,title:`Comment on this block`,onClick:t=>n(`addAt`,e)},[q($,{name:`plus`,size:14,"stroke-width":2.2})],8,cg),e.diagram===null?(U(),W(`div`,{key:1,class:`markdown`,"data-doc":``,innerHTML:e.html},null,8,lg)):(U(),G(ag,{key:0,source:e.diagram,"code-html":e.html},null,8,[`source`,`code-html`]))],8,sg))),128))]))}}),[[`__scopeId`,`data-v-3ac10086`]]),dg=44,fg=wp(V({__name:`SelectionToolbar`,props:{rect:{}},emits:[`comment`,`suggest`,`copyRef`],setup(e,{emit:t}){let n=e,r=t,i=X(()=>{let e=n.rect.top-dg-8,t=e>8?e:n.rect.bottom+8,r=Math.min(Math.max(n.rect.left+n.rect.width/2,130),window.innerWidth-130);return{top:`${t}px`,left:`${r}px`}});return(e,t)=>(U(),W(`div`,{class:`toolbar`,role:`toolbar`,"aria-label":`Selection`,style:me(i.value),onMousedown:t[3]||=zo(()=>{},[`prevent`])},[K(`button`,{type:`button`,title:`Comment (C)`,onClick:t[0]||=e=>r(`comment`)},[q($,{name:`comment`,size:16}),t[4]||=J(`Comment `,-1)]),K(`button`,{type:`button`,title:`Suggest an edit (S)`,onClick:t[1]||=e=>r(`suggest`)},[q($,{name:`edit`,size:16}),t[5]||=J(`Suggest `,-1)]),K(`button`,{type:`button`,"aria-label":`Copy reference`,title:`Copy reference`,onClick:t[2]||=e=>r(`copyRef`)},[q($,{name:`link`,size:16})])],36))}}),[[`__scopeId`,`data-v-6153ab2c`]]),pg={class:`source`},mg=[`data-line-start`,`data-line-end`],hg=[`aria-label`,`onClick`],gg={class:`text`,"data-doc":``},_g={class:`after`},vg=wp(V({__name:`SourceView`,props:{lines:{}},emits:[`addAt`],setup(e,{emit:t}){let n=e,r=t,i=X(()=>Um(n.lines)),a=z(null);function o(e,t){t.shiftKey&&a.value!==null?r(`addAt`,{startLine:Math.min(a.value,e),endLine:Math.max(a.value,e)}):r(`addAt`,{startLine:e,endLine:e}),a.value=e}return(t,n)=>(U(),W(`div`,pg,[(U(!0),W(H,null,Mr(e.lines,(e,n)=>(U(),W(H,{key:n},[K(`div`,{class:ye([`src-line`,i.value[n]]),"data-line-start":n+1,"data-line-end":n+1},[K(`button`,{type:`button`,class:`number`,"aria-label":`Comment on line ${n+1}`,title:`Comment on this line (shift-click for a range)`,onClick:e=>o(n+1,e)},I(n+1),9,hg),K(`span`,gg,I(e||` `),1)],10,mg),K(`div`,_g,[Pr(t.$slots,`after`,{line:n+1},void 0,!0)])],64))),128))]))}}),[[`__scopeId`,`data-v-0c60cb9e`]]),yg=[`mdifit-comment`,`mdifit-suggest`,`mdifit-active`,`mdifit-pending`,`mdifit-del`];function bg(e,t){typeof CSS<`u`&&`highlights`in CSS&&(t.length===0?CSS.highlights.delete(e):CSS.highlights.set(e,new Highlight(...t)))}function xg(){for(let e of yg)bg(e,[])}function Sg(e,t){let n=null;for(let r of e.querySelectorAll(`.block`))if(Number(r.dataset.lineStart)<=t)n=r;else break;return n??e.querySelector(`.block`)}function Cg(e,t){if(!t.quote)return null;let n=Og(e,t.startLine,t.endLine),r=Ss(n.map(e=>e.data),t.quote),i=r?n[r.start.segment]:void 0,a=r?n[r.end.segment]:void 0;if(!r||!i||!a)return null;let o=document.createRange();return o.setStart(i,r.start.offset),o.setEnd(a,r.end.offset),o}function wg(e,t){let n=e.getBoundingClientRect(),r=t instanceof Range?t.getClientRects():[t.getBoundingClientRect()],i=r[0]??t.getBoundingClientRect(),a=r[r.length-1]??i;return{top:i.top-n.top,bottom:a.bottom-n.top}}function Tg(e){return e!==null&&e.startContainer.isConnected&&!e.collapsed}function Eg(e,t){let n=document.createElement(`ins`);n.className=`mdifit-preview`,n.textContent=` ${t}`;let r=e.cloneRange();return r.collapse(!1),r.insertNode(n),n}function Dg(e){if(!e)return;let t=e.parentNode;e.remove(),t?.normalize()}function Og(e,t,n){let r=[];for(let i of e.querySelectorAll(`.block`)){let e=Number(i.dataset.lineStart);if(!(Number(i.dataset.lineEnd)<t||e>n))for(let e of i.querySelectorAll(`[data-doc]`)){let t=document.createTreeWalker(e,NodeFilter.SHOW_TEXT);for(let e=t.nextNode();e;e=t.nextNode())e.parentElement?.closest(`.mdifit-preview`)||r.push(e)}}return r}var kg={key:0,class:`before`},Ag=[`aria-label`,`aria-expanded`,`onClick`],jg={key:3,class:`empty`},Mg={class:`end`},Ng=[`href`],Pg=28,Fg=72,Ig=296,Lg=wp(V({__name:`Reader`,props:{file:{},rendered:{},comments:{},promptBase:{},mode:{},anchor:{},status:{},nextPath:{}},emits:[`add`,`update`,`remove`,`toggleRead`,`toast`],setup(e,{expose:t,emit:n}){let r=e,i=n,a=z(null),o=z(null),s=z(null),c=z(null),l=z(null),u=z([]),d=z(null),f=null,p=null,m=new Map,h=X(()=>r.file.source.split(`
27
- `)),g=X(()=>Km(r.comments)),_=X(()=>r.comments.find(e=>e.id===l.value)??null),v=X(()=>g.value.findIndex(e=>e.id===l.value));function y(e){let t=h.value.length;return r.comments.filter(n=>Math.min(n.endLine,t)===e)}function b(e){return e.filter(e=>e.id!==s.value?.editingId)}function x(e){return ym({...e,path:r.file.path},r.promptBase)}function S(e){if(s.value)return f??Sg(e,s.value.startLine);let t=_.value;return t?m.get(t.id)??Sg(e,t.startLine):null}function C(){let e=o.value;if(!e||r.mode!==`read`){xg(),u.value=[],d.value=null;return}let t=s.value;t?.quote&&!Tg(f)&&(f=Cg(e,t)),w(),m.clear();let n=[],i=[],c=[];for(let a of r.comments){if(a.id===t?.editingId)continue;let r=Cg(e,a);m.set(a.id,r),r&&(a.suggestion===null?n:i).push(r);let o=r??Sg(e,a.startLine);o&&c.push({id:a.id,top:wg(e,o).top})}bg(`mdifit-comment`,n),bg(`mdifit-suggest`,i);let p=l.value?m.get(l.value):null;bg(`mdifit-active`,p?[p]:[]);let h=t&&f?[f]:[];bg(`mdifit-pending`,t?.mode===`comment`?h:[]),bg(`mdifit-del`,t?.mode===`suggest`?h:[]);let g=new Set(r.comments.filter(e=>e.suggestion!==null).map(e=>e.id));u.value=Wm(c,Pg).map(e=>({...e,suggestion:g.has(e.id)}));let _=S(e),v=a.value?.getBoundingClientRect();d.value=_&&v?Gm({anchor:wg(e,_),pageWidth:e.offsetWidth,marginSpace:v.right-e.getBoundingClientRect().right,gutter:Fg,width:Ig}):null}function w(){Dg(p),p=null;let e=s.value;e?.mode===`suggest`&&Tg(f)&&e.suggestion!==Rm(e,h.value)&&(p=Eg(f,e.suggestion))}let ee=0;function T(){cancelAnimationFrame(ee),ee=requestAnimationFrame(C)}function E(){requestAnimationFrame(()=>{let e=o.value?Cs(o.value):null;if(!e){c.value=null;return}let t=r.mode===`read`?Pm(h.value,e,e.quote):e;c.value={...e,startLine:t.startLine,endLine:t.endLine}})}function D(){c.value&&window.getSelection()?.isCollapsed&&(c.value=null)}function O(e){let t=c.value;return t?(l.value=null,f=r.mode===`read`?t.range:null,s.value=zm(e,{startLine:t.startLine,endLine:t.endLine,quote:t.quote},h.value),c.value=null,Es(),!0):!1}async function k(){let e=c.value;e&&(await Ds(bm({id:``,path:r.file.path,startLine:e.startLine,endLine:e.endLine,quote:e.quote,body:``,suggestion:null,createdAt:0},{promptBase:r.promptBase,includeQuotes:!0}))&&i(`toast`,`Reference copied`),c.value=null,Es())}function te(e){l.value=null,f=null,s.value=zm(`comment`,{startLine:e.startLine,endLine:e.endLine,quote:null},h.value)}function A(e){f=null,s.value=zm(`comment`,{...e,quote:null},h.value)}function ne(e){s.value&&=Vm(s.value,e,h.value)}function j(){Dg(p),p=null,f=null,s.value=null}function M(e){return!e.body.trim()&&(e.mode===`comment`||e.suggestion===Rm(e,h.value))}function N(){let e=s.value;if(!e)return;let t=Hm(e,r.file.path,h.value);t?(e.editingId?i(`update`,e.editingId,t):i(`add`,t),j()):i(`toast`,e.mode===`suggest`?`Change the text to suggest an edit`:`Write a comment first`)}function re(e){f=m.get(e.id)?.cloneRange()??null,l.value=null,s.value=Bm(e)}function ie(e){l.value=null,i(`remove`,e.id)}async function P(e){await Ds(bm(e,{promptBase:r.promptBase,includeQuotes:!0}))&&i(`toast`,`Prompt copied`)}function ae(e){(!s.value||M(s.value))&&(j(),l.value=l.value===e?null:e)}async function oe(e){let t=g.value;if(t.length===0)return;let n=t[(v.value+e+t.length)%t.length];if(!n)return;l.value=n.id,await En();let r=o.value;(m.get(n.id)?.startContainer.parentElement??(r?Sg(r,n.startLine):null))?.scrollIntoView({block:`center`,behavior:`smooth`})}function F(e){e.target?.closest(`.margin-pop, .bubble, .toolbar`)||(l.value=null,s.value&&r.mode===`read`&&M(s.value)&&j())}function se(e){e.key===`Escape`&&l.value&&(l.value=null)}let ce=null;async function le(){await En();let e=o.value;if(!e)return;let t=ce!==r.file.path;if(ce=r.file.path,r.mode===`read`&&r.anchor?.startsWith(`comment-`)){let t=r.anchor.slice(8);if(r.comments.some(e=>e.id===t)){l.value=t,C();let n=m.get(t)?.startContainer.parentElement;ks(n??Sg(e,r.comments.find(e=>e.id===t)?.startLine??1));return}}let n=r.mode===`source`?r.rendered.headings.find(e=>e.slug===r.anchor)?.line:void 0,i=zf(r.anchor)??n??null;if(i!==null){let t=r.mode===`read`?`.block[data-line-start="${Lm(r.rendered.blocks,i)?.startLine}"]`:`.src-line[data-line-start="${i}"]`;ks(e.querySelector(t))}else if(r.anchor){let t=document.getElementById(r.anchor);t&&e.contains(t)&&ks(t,r.anchor.startsWith(`comment-`)?`center`:`start`)}else t&&a.value?.scrollTo({top:0})}qn(()=>r.file.path,()=>{j(),l.value=null}),qn(()=>[r.file.path,r.anchor,r.mode],le,{immediate:!0}),qn(()=>[r.rendered,r.comments,r.mode,l.value,s.value,s.value?.mode,s.value?.suggestion],()=>void En(T),{immediate:!0});let ue=null;return vr(()=>{document.addEventListener(`selectionchange`,D),document.addEventListener(`pointerdown`,F),window.addEventListener(`keydown`,se),window.addEventListener(`resize`,T),ue=new ResizeObserver(T),o.value&&ue.observe(o.value)}),xr(()=>{document.removeEventListener(`selectionchange`,D),document.removeEventListener(`pointerdown`,F),window.removeEventListener(`keydown`,se),window.removeEventListener(`resize`,T),ue?.disconnect(),cancelAnimationFrame(ee),Dg(p),xg()}),t({startFromSelection:O}),(t,n)=>(U(),W(`main`,{ref_key:`scroller`,ref:a,class:`reader`,onScrollPassive:n[8]||=e=>c.value=null},[K(`article`,{ref_key:`content`,ref:o,class:ye([`page`,e.mode]),onMouseup:E,onKeyup:zo(E,[`shift`])},[t.$slots.before?(U(),W(`div`,kg,[Pr(t.$slots,`before`,{},void 0,!0)])):Y(``,!0),e.mode===`read`?(U(),W(H,{key:1},[q(ug,{blocks:e.rendered.blocks,onAddAt:te},null,8,[`blocks`]),(U(!0),W(H,null,Mr(u.value,e=>(U(),W(`button`,{key:e.id,type:`button`,class:ye([`bubble`,{active:e.id===l.value}]),style:me({top:`${e.top}px`}),"aria-label":e.suggestion?`Open suggested edit`:`Open comment`,"aria-expanded":e.id===l.value,onClick:t=>ae(e.id)},[q($,{name:e.suggestion?`edit`:`comment`,size:14},null,8,[`name`])],14,Ag))),128)),s.value&&d.value?(U(),G(Ah,{key:`${s.value.startLine}-${s.value.endLine}-${s.value.editingId}`,draft:s.value,placement:d.value,onSwitchMode:ne,onSave:N,onCancel:j},null,8,[`draft`,`placement`])):_.value&&d.value?(U(),G(vh,{key:1,comment:_.value,placement:d.value,index:v.value,total:g.value.length,onPrevious:n[0]||=e=>oe(-1),onNext:n[1]||=e=>oe(1),onCopy:n[2]||=e=>P(_.value),onEdit:n[3]||=e=>re(_.value),onRemove:n[4]||=e=>ie(_.value)},null,8,[`comment`,`placement`,`index`,`total`])):Y(``,!0)],64)):(U(),G(vg,{key:2,lines:h.value,onAddAt:A},{after:Bn(({line:t})=>[(U(!0),W(H,null,Mr(b(y(t)),t=>(U(),G(rh,{key:t.id,comment:t,"prompt-base":e.promptBase,onEdit:e=>re(t),onRemove:e=>i(`remove`,t.id),onCopy:e=>P(t)},null,8,[`comment`,`prompt-base`,`onEdit`,`onRemove`,`onCopy`]))),128)),s.value&&Math.min(s.value.endLine,h.value.length)===t?(U(),G(dh,{key:`${s.value.startLine}-${s.value.endLine}-${s.value.editingId}`,draft:s.value,lines:h.value,location:x(s.value),onSwitchMode:ne,onSave:N,onCancel:j},null,8,[`draft`,`lines`,`location`])):Y(``,!0)]),_:1},8,[`lines`])),e.file.source.trim()===``?(U(),W(`p`,jg,`This file is empty.`)):Y(``,!0),K(`footer`,Mg,[K(`button`,{type:`button`,class:ye([`btn`,e.status===`read`?``:`btn-primary`]),title:`R`,onClick:n[5]||=e=>i(`toggleRead`)},[q($,{name:`check`}),J(` `+I(e.status===`read`?`Read · mark unread`:e.status===`edited`?`Changed since you read it · mark read`:`Mark as read`),1)],2),e.nextPath?(U(),W(`a`,{key:0,class:`next`,href:B(If)({path:e.nextPath,anchor:null})},[J(` Next: `+I(e.nextPath)+` `,1),q($,{name:`arrow-right`})],8,Ng)):Y(``,!0)])],34),c.value?(U(),G(fg,{key:0,rect:c.value.rect,onComment:n[6]||=e=>O(`comment`),onSuggest:n[7]||=e=>O(`suggest`),onCopyRef:k},null,8,[`rect`])):Y(``,!0)],544))}}),[[`__scopeId`,`data-v-aa7fa4d6`]]),Rg=wp(V({__name:`ShortcutsDialog`,props:{open:{type:Boolean}},emits:[`close`],setup(e,{emit:t}){let n=e,r=t,i=z(null);return qn(()=>n.open,e=>e?i.value?.showModal():i.value?.close(),{flush:`post`}),(e,t)=>(U(),W(`dialog`,{ref_key:`dialog`,ref:i,class:`shortcuts`,"aria-labelledby":`shortcuts-title`,onClose:t[1]||=e=>r(`close`)},[K(`header`,null,[t[2]||=K(`h2`,{id:`shortcuts-title`},`Keyboard shortcuts`,-1),K(`button`,{type:`button`,class:`btn-icon`,"aria-label":`Close`,onClick:t[0]||=e=>r(`close`)},[q($,{name:`close`,size:18})])]),K(`dl`,null,[(U(!0),W(H,null,Mr(B(rp),e=>(U(),W(H,{key:e.action},[K(`dt`,null,[K(`kbd`,null,I(e.keys),1)]),K(`dd`,null,I(e.label),1)],64))),128)),t[3]||=K(`dt`,null,[K(`kbd`,null,`⌘↵`)],-1),t[4]||=K(`dd`,null,`Save a comment / copy the prompt`,-1),t[5]||=K(`dt`,null,[K(`kbd`,null,`Shift`),J(` + click`)],-1),t[6]||=K(`dd`,null,`Comment on a range of source lines`,-1)])],544))}}),[[`__scopeId`,`data-v-6c3846be`]]);function zg(e){let t={kind:`folder`,name:``,path:``,children:[]};for(let n of Bg(e)){let r=n.path.split(`/`),i=t;for(let e of r.slice(0,-1)){let t=i.path?`${i.path}/${e}`:e,n=i.children.find(t=>t.kind===`folder`&&t.name===e);n||(n={kind:`folder`,name:e,path:t,children:[]},i.children.push(n)),i=n}i.children.push({kind:`file`,name:r.at(-1)??n.path,path:n.path,title:n.title,status:es(n,e.read),comments:e.commentCounts.get(n.path)??0})}return Wg(t.children.map(Ug))}function Bg(e){let t=ap(e.query.trim());return e.files.filter(n=>e.filter===`unread`&&es(n,e.read)===`read`||e.filter===`commented`&&!e.commentCounts.get(n.path)?!1:!t||ap(`${n.path} ${n.title??``}`).includes(t))}function Vg(e,t,n){return{all:e.length,unread:e.filter(e=>es(e,t)!==`read`).length,commented:e.filter(e=>n.get(e.path)).length}}function Hg(e){return e.flatMap(e=>e.kind===`file`?[e]:Hg(e.children))}function Ug(e){if(e.kind===`file`)return e;let t=e;for(;t.children.length===1&&t.children[0]?.kind===`folder`;){let e=t.children[0];t={...e,name:`${t.name}/${e.name}`}}return{...t,children:t.children.map(Ug)}}function Wg(e){return e.map(e=>e.kind===`folder`?{...e,children:Wg(e.children)}:e).toSorted((e,t)=>e.kind===t.kind?e.name.localeCompare(t.name,`en`,{sensitivity:`base`,numeric:!0}):e.kind===`folder`?-1:1)}var Gg={class:`node`},Kg=[`aria-expanded`,`aria-label`],qg=[`href`,`aria-current`],Jg={key:0,class:`children`},Yg=[`href`,`aria-current`,`title`],Xg=[`title`],Zg={class:`name`},Qg={key:0,class:`badge`},$g=[`aria-label`],e_={key:0,class:`outline`,"aria-label":`Outline`},t_=[`href`],n_=wp(V({__name:`TreeNodeRow`,props:{node:{},depth:{},currentPath:{},currentFolder:{},collapsed:{},headings:{}},emits:[`toggle`],setup(e,{emit:t}){let n=t;return(t,r)=>{let i=Or(`TreeNodeRow`,!0);return U(),W(`li`,Gg,[e.node.kind===`folder`?(U(),W(H,{key:0},[K(`div`,{class:ye([`row folder`,{active:`${e.node.path}/`===e.currentFolder}]),style:me({paddingLeft:`${4+e.depth*14}px`})},[K(`button`,{type:`button`,class:`chevron`,"aria-expanded":!e.collapsed.has(e.node.path),"aria-label":`${e.collapsed.has(e.node.path)?`Expand`:`Collapse`} ${e.node.name}`,onClick:r[0]||=t=>n(`toggle`,e.node.path)},[q($,{name:e.collapsed.has(e.node.path)?`chevron-right`:`chevron-down`,size:14,"stroke-width":2.4},null,8,[`name`])],8,Kg),K(`a`,{class:`name`,href:B(If)({path:`${e.node.path}/`,anchor:null}),"aria-current":`${e.node.path}/`===e.currentFolder?`page`:void 0},I(e.node.name),9,qg)],6),e.collapsed.has(e.node.path)?Y(``,!0):(U(),W(`ul`,Jg,[(U(!0),W(H,null,Mr(e.node.children,t=>(U(),G(i,{key:t.path,node:t,depth:e.depth+1,"current-path":e.currentPath,"current-folder":e.currentFolder,collapsed:e.collapsed,headings:e.headings,onToggle:r[1]||=e=>n(`toggle`,e)},null,8,[`node`,`depth`,`current-path`,`current-folder`,`collapsed`,`headings`]))),128))]))],64)):(U(),W(H,{key:1},[K(`a`,{class:ye([`row file`,{active:e.node.path===e.currentPath,read:e.node.status===`read`}]),href:B(If)({path:e.node.path,anchor:null}),style:me({paddingLeft:`${8+e.depth*14}px`}),"aria-current":e.node.path===e.currentPath?`page`:void 0,title:e.node.title??e.node.path},[K(`span`,{class:ye([`status`,e.node.status]),title:e.node.status===`edited`?`Changed since you read it`:void 0},[e.node.status===`read`?(U(),G($,{key:0,name:`check`,size:14,"stroke-width":2.6})):(U(),G($,{key:1,name:`file`,size:15}))],10,Xg),K(`span`,Zg,I(e.node.name),1),e.node.status===`edited`?(U(),W(`span`,Qg,`edited`)):Y(``,!0),e.node.comments?(U(),W(`span`,{key:1,class:`count`,"aria-label":`${e.node.comments} comments`},[q($,{name:`comment`,size:13}),J(I(e.node.comments),1)],8,$g)):Y(``,!0)],14,Yg),e.node.path===e.currentPath&&e.headings.length?(U(),W(`ul`,e_,[(U(!0),W(H,null,Mr(e.headings,t=>(U(),W(`li`,{key:t.slug},[K(`a`,{href:B(If)({path:e.node.path,anchor:t.slug}),style:me({paddingLeft:`${30+e.depth*14+(t.level-1)*12}px`})},I(t.text),13,t_)]))),128))])):Y(``,!0)],64))])}}}),[[`__scopeId`,`data-v-23877561`]]),r_={class:`sidebar`,"aria-label":`Files`},i_={class:`search`},a_={class:`field`},o_={class:`filters`,role:`radiogroup`,"aria-label":`Show`},s_=[`aria-checked`,`onClick`],c_={key:0,class:`tree`},l_={key:1,class:`empty`},u_=wp(V({__name:`Sidebar`,props:{files:{},read:{},commentCounts:{},currentPath:{},currentFolder:{},headings:{}},setup(e){let t=e,n=z(`all`),r=z(``),i=Ut(new Set),a=X(()=>zg({files:t.files,read:t.read,commentCounts:t.commentCounts,filter:n.value,query:r.value})),o=X(()=>Vg(t.files,t.read,t.commentCounts)),s=[{value:`all`,label:`All`},{value:`unread`,label:`Unread`},{value:`commented`,label:`Commented`}];function c(e){i.has(e)?i.delete(e):i.add(e)}return(t,l)=>(U(),W(`aside`,r_,[K(`div`,i_,[K(`label`,a_,[q($,{name:`search`}),l[1]||=K(`span`,{class:`visually-hidden`},`Filter files`,-1),Vn(K(`input`,{"onUpdate:modelValue":l[0]||=e=>r.value=e,type:`search`,placeholder:`Filter files…`},null,512),[[Mo,r.value]])])]),K(`div`,o_,[(U(),W(H,null,Mr(s,e=>K(`button`,{key:e.value,type:`button`,role:`radio`,"aria-checked":n.value===e.value,onClick:t=>n.value=e.value},[J(I(e.label)+` `,1),K(`span`,null,I(o.value[e.value]),1)],8,s_)),64))]),a.value.length?(U(),W(`ul`,c_,[(U(!0),W(H,null,Mr(a.value,t=>(U(),G(n_,{key:t.path,node:t,depth:0,"current-path":e.currentPath,"current-folder":e.currentFolder,collapsed:i,headings:e.headings,onToggle:c},null,8,[`node`,`current-path`,`current-folder`,`collapsed`,`headings`]))),128))])):(U(),W(`p`,l_,I(e.files.length===0?`No Markdown files here.`:`No files match.`),1))]))}}),[[`__scopeId`,`data-v-18a9062d`]]);function d_(e,t,n){let r=(n??t??``).split(`/`).filter(Boolean),i=[{label:e,path:``,current:!1}],a=``;r.forEach((e,t)=>{a=t===r.length-1&&n!==null?`${a}${e}`:`${a}${e}/`,i.push({label:e,path:a,current:!1})});let o=i.at(-1);return o&&(o.current=!0),i}var f_={class:`topbar`},p_=[`aria-pressed`,`aria-label`,`title`],m_={class:`path`,"aria-label":`Breadcrumb`},h_=[`title`],g_=[`href`,`title`],__=[`aria-label`,`title`],v_={class:`segmented`,role:`group`,"aria-label":`View`},y_=[`aria-pressed`],b_=[`aria-pressed`],x_={class:`progress`},S_={class:`bar`,"aria-hidden":`true`},C_=[`disabled`],w_=[`aria-pressed`,`aria-label`,`title`],T_=wp(V({__name:`TopBar`,props:{crumbs:{},copyablePath:{},mode:{},showFiles:{type:Boolean},showComments:{type:Boolean},hasFiles:{type:Boolean},readCount:{},fileCount:{},commentCount:{}},emits:[`update:mode`,`openPrompt`,`openPalette`,`copyPath`,`toggleFiles`,`toggleComments`],setup(e,{emit:t}){let n=t;return(t,r)=>(U(),W(`header`,f_,[e.hasFiles?(U(),W(`button`,{key:0,type:`button`,class:`btn-icon panel-toggle`,"aria-pressed":e.showFiles,"aria-label":e.showFiles?`Hide files panel`:`Show files panel`,title:`${e.showFiles?`Hide`:`Show`} files (B)`,onClick:r[0]||=e=>n(`toggleFiles`)},[q($,{name:`panel-left`,size:18})],8,p_)):Y(``,!0),r[9]||=fa(`<div class="brand" data-v-a62fdb6b><svg width="24" height="24" viewBox="0 0 64 64" aria-hidden="true" data-v-a62fdb6b><rect width="64" height="64" rx="15" fill="currentColor" data-v-a62fdb6b></rect><rect x="13" y="16" width="28" height="4.5" rx="2.25" fill="var(--surface)" data-v-a62fdb6b></rect><rect x="13" y="27.5" width="22" height="4.5" rx="2.25" fill="var(--surface)" data-v-a62fdb6b></rect><rect x="13" y="34.5" width="22" height="2.5" rx="1.25" fill="var(--brand-accent)" data-v-a62fdb6b></rect><rect x="13" y="43.5" width="25" height="4.5" rx="2.25" fill="var(--surface)" opacity="0.5" data-v-a62fdb6b></rect><path d="M43 24.5h9a3 3 0 0 1 3 3v6.5a3 3 0 0 1-3 3h-4.5l-3.5 3.25V37h-1a3 3 0 0 1-3-3v-6.5a3 3 0 0 1 3-3z" fill="var(--brand-accent)" data-v-a62fdb6b></path></svg> mdifit </div>`,1),K(`nav`,m_,[K(`ol`,null,[(U(!0),W(H,null,Mr(e.crumbs,e=>(U(),W(`li`,{key:e.path},[e.current?(U(),W(`span`,{key:0,class:`crumb current`,"aria-current":`page`,title:e.label},I(e.label),9,h_)):(U(),W(H,{key:1},[K(`a`,{class:`crumb`,href:B(If)({path:e.path,anchor:null}),title:e.label},I(e.label),9,g_),q($,{name:`chevron-right`,size:14,class:`sep`})],64))]))),128))]),e.copyablePath?(U(),W(`button`,{key:0,type:`button`,class:`btn-icon`,"aria-label":`Copy path ${e.copyablePath}`,title:`Copy ${e.copyablePath}`,onClick:r[1]||=e=>n(`copyPath`)},[q($,{name:`copy`})],8,__)):Y(``,!0)]),K(`div`,v_,[K(`button`,{type:`button`,"aria-pressed":e.mode===`read`,onClick:r[2]||=e=>n(`update:mode`,`read`)},` Read `,8,y_),K(`button`,{type:`button`,"aria-pressed":e.mode===`source`,onClick:r[3]||=e=>n(`update:mode`,`source`)},` Source `,8,b_)]),K(`div`,x_,[K(`span`,null,I(e.readCount)+` / `+I(e.fileCount)+` read`,1),K(`span`,S_,[K(`span`,{style:me({width:`${e.fileCount?e.readCount/e.fileCount*100:0}%`})},null,4)])]),K(`button`,{type:`button`,class:`btn`,title:`Search files, headings and text`,onClick:r[4]||=e=>n(`openPalette`)},[q($,{name:`search`}),r[7]||=J(` Search `,-1),r[8]||=K(`kbd`,null,`⌘K`,-1)]),K(`button`,{type:`button`,class:`btn btn-comment`,disabled:e.commentCount===0,title:`Review and copy the prompt (P)`,onClick:r[5]||=e=>n(`openPrompt`)},[q($,{name:`copy`}),J(` Copy prompt · `+I(e.commentCount),1)],8,C_),K(`button`,{type:`button`,class:`btn-icon panel-toggle`,"aria-pressed":e.showComments,"aria-label":e.showComments?`Hide comments panel`:`Show comments panel`,title:`${e.showComments?`Hide`:`Show`} comments (N)`,onClick:r[6]||=e=>n(`toggleComments`)},[q($,{name:`panel-right`,size:18})],8,w_)]))}}),[[`__scopeId`,`data-v-a62fdb6b`]]),E_={key:0,class:`fatal`,role:`alert`},D_={key:1,class:`shell`},O_={key:3,class:`placeholder`},k_={key:0,role:`alert`},A_={key:1},j_={key:2},M_={class:`toast`,role:`status`,"aria-live":`polite`},N_={key:0};Uo(wp(V({__name:`App`,setup(e){let t=tn(null),n=tn(null),r=tn(null),i=z(Ff(location.hash)),a=z(gs()),o=z(null),s=z(null),c=z(null),l=z(null),u=z(null),d=z({}),f=X(()=>t.value?.files??[]),p=X(()=>t.value?.promptBase??``),m=X(()=>a.value.showFiles&&!t.value?.single),h=X(()=>n.value?.state.comments??[]),g=X(()=>n.value?.state.read??{}),_=X(()=>$o(h.value)),v=X(()=>Hg(zg({files:f.value,read:{},commentCounts:new Map,filter:`all`,query:``})).map(e=>e.path)),y=X(()=>Lf(i.value.path)?i.value.path:null),b=X(()=>y.value===null?[]:Wp(f.value,y.value)),x=X(()=>{if(y.value===null)return i.value.path;let e=d.value[y.value];return e&&b.value.includes(e)?e:b.value[0]??null}),S=X(()=>y.value===null?null:Kp(f.value,y.value,g.value,_.value)),C=X(()=>{let e=t.value?.name??``;return t.value?.single?[{label:e,path:x.value??``,current:!0}]:d_(e,y.value,x.value)}),w=X(()=>{let e=x.value??y.value;return e===null?null:`${p.value}${e}`||`./`}),ee=X(()=>f.value.find(e=>e.path===x.value)??null),T=X(()=>r.value?Gf(r.value.source,r.value.path):null),E=X(()=>h.value.filter(e=>e.path===r.value?.path)),D=X(()=>ee.value?es(ee.value,g.value):`unread`),O=X(()=>is(v.value,f.value,g.value,x.value));qn(a,_s,{deep:!0}),qn(()=>a.value.boca,e=>document.documentElement.toggleAttribute(`data-boca`,e),{immediate:!0});async function k(){try{let e=await cs();(!n.value||t.value?.rootPath!==e.rootPath)&&(n.value=fs(e.rootPath)),t.value=e,o.value=null,te(e)}catch(e){o.value=e instanceof os?e.message:String(e)}}function te(e){let t=i.value.path;if(e.single){let n=e.files[0]?.path;n&&t!==n&&j({path:n,anchor:null},!0);return}if(t===null){j({path:``,anchor:null},!0);return}if(Lf(t)?Gp(e.files,t):e.files.some(e=>e.path===t))return;let n=Lf(t)?``:Rf(t);j({path:Gp(e.files,n)?n:``,anchor:null},!0)}let A=0;async function ne(e){let t=++A;try{let n=await ls(e);if(t!==A)return;r.value=n,s.value=null,document.title=`${e} · mdifit`}catch(e){if(t!==A)return;s.value=e instanceof os?e.message:String(e)}}qn(x,e=>{e?ne(e):(r.value=null,s.value=null,document.title=`${y.value||t.value?.name||``} · mdifit`)},{immediate:!0});function j(e,t=!1){let n=If(e);t?history.replaceState(null,``,n):location.hash!==n&&(location.hash=n),i.value=e}function M(){i.value=Ff(location.hash),t.value&&te(t.value)}function N(){let e=ee.value;e&&n.value&&(D.value===`read`?n.value.markUnread(e.path):n.value.markRead(e))}function re(e,t,r){r&&n.value?.clearComments(t),l.value=null,F(`Copied ${op(e,`comment`)}${r?` and deleted them`:``}`)}async function ie(){w.value&&await Ds(w.value)&&F(`Path copied`)}function P(e){y.value!==null&&(d.value={...d.value,[y.value]:e})}function ae(e){l.value=null,j({path:e.path,anchor:e.line?`L${e.line}`:null})}let oe;function F(e){c.value=e,clearTimeout(oe),oe=setTimeout(()=>c.value=null,2200)}let se=tp;function ce(e,n){if(n||l.value||e.metaKey||e.ctrlKey||e.altKey)return!1;let r=np(se,e.key,Date.now());return se=r.state,r.undoFirst&&!t.value?.single&&(a.value.showFiles=!a.value.showFiles),r.matched&&(a.value.boca=!a.value.boca,F(a.value.boca?`Azul y oro. Dale Boca.`:`Azul y oro, en pausa.`)),r.consumed&&e.preventDefault(),r.consumed}function le(e){let n=Os(e.target);if(ce(e,n))return;let r=ip({key:e.key,metaKey:e.metaKey,ctrlKey:e.ctrlKey,altKey:e.altKey,editing:n});if(r&&!(l.value&&r!==`palette`))switch(e.preventDefault(),r){case`palette`:l.value=l.value===`palette`?null:`palette`;break;case`comment`:case`suggest`:u.value?.startFromSelection(r)||F(`Select some text first`);break;case`prompt`:h.value.length?l.value=`prompt`:F(`No comments yet`);break;case`toggleRead`:N();break;case`toggleMode`:a.value.mode=a.value.mode===`read`?`source`:`read`;break;case`nextFile`:case`previousFile`:{let e=rs(v.value,x.value,r===`nextFile`?1:-1);e&&j({path:e,anchor:null});break}case`toggleFiles`:t.value?.single||(a.value.showFiles=!a.value.showFiles);break;case`toggleComments`:a.value.showComments=!a.value.showComments;break;case`help`:l.value=`help`}}let ue=null;return vr(()=>{window.addEventListener(`hashchange`,M),window.addEventListener(`keydown`,le),k(),ue=ds(e=>{k(),e===x.value&&ne(e)})}),xr(()=>{window.removeEventListener(`hashchange`,M),window.removeEventListener(`keydown`,le),ue?.()}),(e,d)=>o.value?(U(),W(`div`,E_,[d[14]||=K(`h1`,null,`mdifit`,-1),K(`p`,null,I(o.value),1),K(`button`,{type:`button`,class:`btn btn-primary`,onClick:k},`Try again`)])):t.value&&n.value?(U(),W(`div`,D_,[q(T_,{mode:a.value.mode,"onUpdate:mode":d[0]||=e=>a.value.mode=e,"show-files":a.value.showFiles,"show-comments":a.value.showComments,"has-files":!t.value.single,crumbs:C.value,"copyable-path":w.value,"read-count":B(as)(f.value,g.value),"file-count":f.value.length,"comment-count":h.value.length,onOpenPrompt:d[1]||=e=>l.value=`prompt`,onOpenPalette:d[2]||=e=>l.value=`palette`,onCopyPath:ie,onToggleFiles:d[3]||=e=>a.value.showFiles=!a.value.showFiles,onToggleComments:d[4]||=e=>a.value.showComments=!a.value.showComments},null,8,[`mode`,`show-files`,`show-comments`,`has-files`,`crumbs`,`copyable-path`,`read-count`,`file-count`,`comment-count`]),K(`div`,{class:ye([`body`,{"no-files":!m.value,"no-comments":!a.value.showComments}])},[m.value?(U(),G(u_,{key:0,files:f.value,read:g.value,"comment-counts":_.value,"current-path":x.value,"current-folder":y.value,headings:T.value?.headings??[]},null,8,[`files`,`read`,`comment-counts`,`current-path`,`current-folder`,`headings`])):Y(``,!0),r.value&&T.value&&r.value.path===x.value?(U(),G(Lg,{key:1,ref_key:`reader`,ref:u,file:r.value,rendered:T.value,comments:E.value,"prompt-base":p.value,mode:a.value.mode,anchor:i.value.anchor,status:D.value,"next-path":O.value,onAdd:d[5]||=e=>n.value.addComment(e),onUpdate:d[6]||=(e,t)=>n.value?.updateComment(e,t),onRemove:d[7]||=e=>n.value.removeComment(e),onToggleRead:N,onToast:F},Nr({_:2},[y.value!==null&&S.value?{name:`before`,fn:Bn(()=>[q(pm,{folder:y.value,"root-name":t.value.name,listing:S.value,entries:b.value,entry:r.value.path,onChooseEntry:P},null,8,[`folder`,`root-name`,`listing`,`entries`,`entry`])]),key:`0`}:void 0]),1032,[`file`,`rendered`,`comments`,`prompt-base`,`mode`,`anchor`,`status`,`next-path`])):y.value!==null&&x.value===null&&S.value?(U(),G(_m,{key:2,folder:y.value,"root-name":t.value.name,listing:S.value},null,8,[`folder`,`root-name`,`listing`])):(U(),W(`main`,O_,[s.value?(U(),W(`p`,k_,I(s.value),1)):f.value.length===0?(U(),W(`p`,A_,`No Markdown files in `+I(t.value.name)+`.`,1)):(U(),W(`p`,j_,`Loading…`))])),a.value.showComments?(U(),G(Hp,{key:4,comments:h.value,"current-path":x.value,onOpenPrompt:d[8]||=e=>l.value=`prompt`,onClear:d[9]||=e=>n.value.clearComments(e)},null,8,[`comments`,`current-path`])):Y(``,!0)],2),q(Mm,{"include-quotes":a.value.includeQuotes,"onUpdate:includeQuotes":d[10]||=e=>a.value.includeQuotes=e,open:l.value===`prompt`,comments:h.value,"current-path":x.value,"prompt-base":p.value,onClose:d[11]||=e=>l.value=null,onCopied:re},null,8,[`include-quotes`,`open`,`comments`,`current-path`,`prompt-base`]),q(Tp,{open:l.value===`palette`,files:f.value,onClose:d[12]||=e=>l.value=null,onGo:ae},null,8,[`open`,`files`]),q(Rg,{open:l.value===`help`,onClose:d[13]||=e=>l.value=null},null,8,[`open`]),K(`div`,M_,[c.value?(U(),W(`span`,N_,I(c.value),1)):Y(``,!0)])])):Y(``,!0)}}),[[`__scopeId`,`data-v-7e92f30f`]])).mount(`#app`);export{l as i,o as n,u as r,Ih as t};
22
+ `;function xm(e,t){let n=e.startLine===e.endLine?`L${e.startLine}`:`L${e.startLine}-L${e.endLine}`;return`${t}${e.path}:${n}`}function Sm(e,t){let n=[xm(e,t.promptBase)];e.suggestion===null?t.includeQuotes&&e.quote&&n.push(wm(e.quote)):n.push(Tm(`ORIGINAL`,e.quote??``),Tm(`SUGGESTED`,e.suggestion));let r=e.body.trim();return r&&n.push(r),n.join(`
23
+ `)}function Cm(e,t){return Qo(e).map(e=>Sm(e,t)).join(bm)}function wm(e){return e.trim().split(/\r?\n/).map(e=>`> ${e.trim()}`.trimEnd()).join(`
24
+ `)}function Tm(e,t){let n=Math.max(2,...[...t.matchAll(/`+/g)].map(e=>e[0].length)),r="`".repeat(n+1);return`${e}:\n${r}\n${t}\n${r}`}var Em={class:`summary`},Dm={class:`options`},Om={class:`segmented`,role:`radiogroup`,"aria-label":`Comments to include`},km=[`aria-checked`,`disabled`],Am=[`aria-checked`],jm=[`checked`],Mm={class:`preview`},Nm=[`disabled`],Pm=Ep(V({__name:`PromptDialog`,props:{open:{type:Boolean},comments:{},currentPath:{},promptBase:{},includeQuotes:{type:Boolean}},emits:[`close`,`update:includeQuotes`,`copied`],setup(e,{emit:t}){let n=e,r=t,i=z(null),a=z(`all`),o=z(!1),s=z(``),c=X(()=>n.comments.filter(e=>e.path===n.currentPath)),l=X(()=>a.value===`file`?c.value:n.comments),u=X(()=>Cm(l.value,{promptBase:n.promptBase,includeQuotes:n.includeQuotes}));qn(u,e=>s.value=e,{immediate:!0}),qn(()=>n.open,e=>{e?(a.value=`all`,s.value=u.value,i.value?.showModal()):i.value?.close()},{flush:`post`});async function d(){s.value.trim()&&await Ds(s.value)&&r(`copied`,l.value.length,l.value.map(e=>e.id),o.value)}function f(e){e.key===`Enter`&&(e.metaKey||e.ctrlKey)&&(e.preventDefault(),d())}return(t,n)=>(U(),W(`dialog`,{ref_key:`dialog`,ref:i,class:`prompt`,"aria-labelledby":`prompt-title`,onClose:n[7]||=e=>r(`close`),onKeydown:f},[K(`header`,null,[n[8]||=K(`h2`,{id:`prompt-title`},`Review prompt`,-1),K(`span`,Em,I(B(op)(l.value.length,`comment`)),1),K(`button`,{type:`button`,class:`btn-icon`,"aria-label":`Close`,onClick:n[0]||=e=>r(`close`)},[q($,{name:`close`,size:18})])]),K(`div`,Dm,[K(`div`,Om,[K(`button`,{type:`button`,role:`radio`,"aria-checked":a.value===`file`,disabled:!e.currentPath,onClick:n[1]||=e=>a.value=`file`},` This file (`+I(c.value.length)+`) `,9,km),K(`button`,{type:`button`,role:`radio`,"aria-checked":a.value===`all`,onClick:n[2]||=e=>a.value=`all`},` All files (`+I(e.comments.length)+`) `,9,Am)]),K(`label`,null,[K(`input`,{type:`checkbox`,checked:e.includeQuotes,onChange:n[3]||=e=>r(`update:includeQuotes`,e.target.checked)},null,40,jm),n[9]||=J(` Quote the selected text `,-1)])]),K(`label`,Mm,[n[10]||=K(`span`,{class:`visually-hidden`},`Prompt`,-1),Vn(K(`textarea`,{"onUpdate:modelValue":n[4]||=e=>s.value=e,spellcheck:`false`},null,512),[[Mo,s.value]])]),K(`footer`,null,[K(`label`,null,[Vn(K(`input`,{"onUpdate:modelValue":n[5]||=e=>o.value=e,type:`checkbox`},null,512),[[No,o.value]]),n[11]||=J(` Delete these comments after copying `,-1)]),K(`button`,{type:`button`,class:`btn`,onClick:n[6]||=e=>s.value=u.value},`Reset`),K(`button`,{type:`button`,class:`btn btn-comment`,disabled:!s.value.trim(),onClick:d},[q($,{name:`copy`}),n[12]||=J(` Copy prompt `,-1),n[13]||=K(`kbd`,null,`⌘↵`,-1)],8,Nm)])],544))}}),[[`__scopeId`,`data-v-c5a0d837`]]),Fm=4;function Im(e,t,n){let r=Rm(n);if(!r)return t;let i=[],a=``;for(let n=t.startLine;n<=t.endLine;n++){let t=Rm(e[n-1]??``);t&&(a&&(a+=` `),i.push({line:n,start:a.length}),a+=t)}let o=a.indexOf(r),s=o+r.length;if(o<0){let e=r.split(` `);o=a.indexOf(e.slice(0,Fm).join(` `));let n=e.slice(-4).join(` `),i=o<0?-1:a.indexOf(n,o);if(o<0)return t;s=i<0?o+1:i+n.length}return{startLine:Lm(i,o),endLine:Lm(i,s-1)}}function Lm(e,t){let n=e[0]?.line??1;for(let r of e){if(r.start>t)break;n=r.line}return n}function Rm(e){return e.replace(/!?\[([^\]]*)\]\([^)]*\)/g,`$1`).replace(/^\s{0,3}(#{1,6}\s+|>\s?|[-*+]\s+(\[[ xX]\]\s+)?|\d+[.)]\s+)/gm,``).replace(/[*_`~|]/g,``).replace(/\s+/g,` `).trim().toLowerCase()}function zm(e,t){let n=null;for(let r of e)if(r.startLine<=t)n=r;else break;return n??e[0]??null}function Bm(e,t){return e.quote??t.slice(e.startLine-1,e.endLine).join(`
25
+ `)}function Vm(e,t,n){let r={mode:e,...t,body:``,suggestion:``,editingId:null};return e===`suggest`&&(r.suggestion=Bm(r,n)),r}function Hm(e){return{mode:e.suggestion===null?`comment`:`suggest`,startLine:e.startLine,endLine:e.endLine,quote:e.quote,body:e.body,suggestion:e.suggestion??``,editingId:e.id}}function Um(e,t,n){if(e.mode===t)return e;let r=t===`suggest`&&!e.suggestion?Bm(e,n):e.suggestion;return{...e,mode:t,suggestion:r}}function Wm(e,t,n){let r=e.body.trim();if(e.mode===`suggest`){let i=Bm(e,n);return e.suggestion===i&&!r?null:{path:t,startLine:e.startLine,endLine:e.endLine,quote:i,body:r,suggestion:e.suggestion}}return r?{path:t,startLine:e.startLine,endLine:e.endLine,quote:e.quote,body:r,suggestion:null}:null}function Gm(e){let t=[],n=null,r=e[0]?.trim()===`---`;return e.forEach((e,i)=>{if(r){t.push(`meta`),i>0&&e.trim()===`---`&&(r=!1);return}let a=/^\s{0,3}(`{3,}|~{3,})/.exec(e);if(a?.[1]){let e=a[1].charAt(0);n===null?n=e:n===e&&(n=null),t.push(`fence`)}else n===null?/^\s{0,3}#{1,6}\s/.test(e)?t.push(`heading`):/^\s{0,3}>/.test(e)?t.push(`quote`):/^\s*([-*+]|\d+[.)])\s/.test(e)?t.push(`list`):t.push(`text`):t.push(`code`)}),t}function Km(e,t,n=4){let r=[];for(let i of e.toSorted((e,t)=>e.top-t.top)){let e=r.at(-1),a=e?Math.max(i.top,e.top+t+n):i.top;r.push({id:i.id,top:a})}return r}function qm(e){return e.marginSpace>=e.width?{side:`margin`,top:Math.max(0,e.anchor.top-10),left:e.pageWidth-14}:{side:`below`,top:e.anchor.bottom+10,left:Math.max(0,e.pageWidth-e.gutter-e.width)}}function Jm(e){return e.toSorted((e,t)=>e.startLine-t.startLine||e.createdAt-t.createdAt)}function Ym(e){return e.startLine===e.endLine?`Line ${e.startLine}`:`Lines ${e.startLine}–${e.endLine}`}var Xm=[`id`],Zm={key:0,class:`kind`},Qm={class:`ref`},$m={class:`actions`},eh={key:0,class:`diff`},th={class:`del`},nh={class:`add`},rh={key:1},ih={key:2},ah=Ep(V({__name:`CommentCard`,props:{comment:{},promptBase:{}},emits:[`edit`,`remove`,`copy`],setup(e,{emit:t}){let n=t;return(t,r)=>(U(),W(`article`,{id:`comment-${e.comment.id}`,class:ye([`card`,{suggestion:e.comment.suggestion!==null}])},[K(`header`,null,[e.comment.suggestion===null?Y(``,!0):(U(),W(`span`,Zm,`Suggested edit`)),K(`code`,Qm,I(B(xm)(e.comment,e.promptBase)),1),K(`span`,$m,[K(`button`,{type:`button`,class:`btn btn-small`,onClick:r[0]||=e=>n(`copy`)},`Copy prompt`),K(`button`,{type:`button`,class:`btn-icon`,"aria-label":`Edit comment`,title:`Edit`,onClick:r[1]||=e=>n(`edit`)},[q($,{name:`edit`,size:15})]),K(`button`,{type:`button`,class:`btn-icon`,"aria-label":`Delete comment`,title:`Delete`,onClick:r[2]||=e=>n(`remove`)},[q($,{name:`trash`,size:15})])])]),e.comment.suggestion===null?e.comment.quote?(U(),W(`blockquote`,rh,I(e.comment.quote),1)):Y(``,!0):(U(),W(`div`,eh,[K(`pre`,th,I(e.comment.quote),1),K(`pre`,nh,I(e.comment.suggestion),1)])),e.comment.body?(U(),W(`p`,ih,I(e.comment.body),1)):Y(``,!0)],10,Xm))}}),[[`__scopeId`,`data-v-1b983aee`]]),oh={class:`ref`},sh={class:`segmented`,role:`radiogroup`,"aria-label":`Kind`},ch=[`aria-checked`],lh=[`aria-checked`],uh={key:0},dh={class:`original`},fh={class:`replacement`},ph=Ep(V({__name:`CommentComposer`,props:{draft:{},location:{},lines:{}},emits:[`switchMode`,`save`,`cancel`],setup(e,{emit:t}){let n=t,r=z(null);vr(async()=>{await En(),r.value?.focus(),r.value?.scrollIntoView({block:`nearest`,behavior:`smooth`})});function i(e){e.key===`Enter`&&(e.metaKey||e.ctrlKey)?(e.preventDefault(),n(`save`)):e.key===`Escape`&&(e.preventDefault(),n(`cancel`))}async function a(e){n(`switchMode`,e),await En(),r.value?.focus()}return(t,o)=>(U(),W(`form`,{class:ye([`composer`,e.draft.mode]),onSubmit:o[6]||=zo(e=>n(`save`),[`prevent`]),onKeydown:i},[K(`header`,null,[K(`code`,oh,I(e.location),1),K(`div`,sh,[K(`button`,{type:`button`,role:`radio`,"aria-checked":e.draft.mode===`comment`,onClick:o[0]||=e=>a(`comment`)},` Comment `,8,ch),K(`button`,{type:`button`,role:`radio`,"aria-checked":e.draft.mode===`suggest`,onClick:o[1]||=e=>a(`suggest`)},` Suggest edit `,8,lh)])]),e.draft.mode===`comment`?(U(),W(H,{key:0},[e.draft.quote?(U(),W(`blockquote`,uh,I(e.draft.quote),1)):Y(``,!0),K(`label`,null,[o[7]||=K(`span`,{class:`visually-hidden`},`Comment`,-1),Vn(K(`textarea`,{ref_key:`field`,ref:r,"onUpdate:modelValue":o[2]||=t=>e.draft.body=t,rows:`3`,placeholder:`What should change?`},null,512),[[Mo,e.draft.body]])])],64)):(U(),W(H,{key:1},[K(`div`,dh,[o[8]||=K(`span`,{class:`label`},`Replace`,-1),K(`pre`,null,I(B(Bm)(e.draft,e.lines)),1)]),K(`label`,fh,[o[9]||=K(`span`,{class:`label`},`With`,-1),Vn(K(`textarea`,{ref_key:`field`,ref:r,"onUpdate:modelValue":o[3]||=t=>e.draft.suggestion=t,rows:`3`},null,512),[[Mo,e.draft.suggestion]])]),K(`label`,null,[o[10]||=K(`span`,{class:`label`},`Why (optional)`,-1),Vn(K(`input`,{"onUpdate:modelValue":o[4]||=t=>e.draft.body=t,type:`text`},null,512),[[Mo,e.draft.body]])])],64)),K(`footer`,null,[o[11]||=K(`span`,{class:`hint`},[K(`kbd`,null,`⌘↵`),J(` save · `),K(`kbd`,null,`Esc`),J(` cancel`)],-1),K(`button`,{type:`button`,class:`btn`,onClick:o[5]||=e=>n(`cancel`)},`Cancel`),K(`button`,{type:`submit`,class:ye([`btn`,e.draft.mode===`suggest`?`btn-suggest`:`btn-primary`])},I(e.draft.editingId?`Save`:e.draft.mode===`suggest`?`Add suggestion`:`Add comment`),3)])],34))}}),[[`__scopeId`,`data-v-28379e78`]]),mh=[`id`,`aria-label`],hh={class:`top`},gh={key:0,class:`nav`},_h={key:0,class:`diff`},vh={key:1,class:`body`},yh={class:`actions`},bh=Ep(V({__name:`MarginComment`,props:{comment:{},placement:{},index:{},total:{}},emits:[`previous`,`next`,`copy`,`edit`,`remove`],setup(e,{emit:t}){let n=e,r=t,i=z(null);return qn(()=>n.placement,()=>i.value?.scrollIntoView({block:`nearest`,behavior:`smooth`}),{flush:`post`,immediate:!0}),(t,n)=>(U(),W(`section`,{id:`comment-${e.comment.id}`,ref_key:`root`,ref:i,class:ye([`margin-pop`,e.placement.side]),style:me({top:`${e.placement.top}px`,left:`${e.placement.left}px`}),"aria-label":`Comment on ${B(Ym)(e.comment).toLowerCase()}`},[K(`div`,hh,[K(`span`,null,I(B(Ym)(e.comment))+` · `+I(B(sp)(e.comment.createdAt,Date.now())),1),e.total>1?(U(),W(`div`,gh,[K(`button`,{type:`button`,class:`mini`,"aria-label":`Previous comment`,onClick:n[0]||=e=>r(`previous`)},[q($,{name:`chevron-left`,size:15,"stroke-width":2.2})]),K(`span`,null,I(e.index+1)+` / `+I(e.total),1),K(`button`,{type:`button`,class:`mini`,"aria-label":`Next comment`,onClick:n[1]||=e=>r(`next`)},[q($,{name:`chevron-right`,size:15,"stroke-width":2.2})])])):Y(``,!0)]),e.comment.suggestion===null?Y(``,!0):(U(),W(`div`,_h,[K(`del`,null,I(e.comment.quote),1),K(`ins`,null,I(e.comment.suggestion),1)])),e.comment.body?(U(),W(`p`,vh,I(e.comment.body),1)):Y(``,!0),K(`div`,yh,[K(`button`,{type:`button`,class:`text-btn`,onClick:n[2]||=e=>r(`copy`)},[q($,{name:`copy`,size:15}),n[5]||=J(` Copy prompt `,-1)]),n[6]||=K(`span`,{class:`spacer`},null,-1),K(`button`,{type:`button`,class:`mini`,"aria-label":`Edit comment`,title:`Edit`,onClick:n[3]||=e=>r(`edit`)},[q($,{name:`edit`,size:15})]),K(`button`,{type:`button`,class:`mini`,"aria-label":`Delete comment`,title:`Delete`,onClick:n[4]||=e=>r(`remove`)},[q($,{name:`trash`,size:15})])])],14,mh))}}),[[`__scopeId`,`data-v-3cb588af`]]),xh=[`aria-label`],Sh={class:`top`},Ch={class:`kind`,role:`radiogroup`,"aria-label":`Kind`},wh=[`aria-checked`],Th=[`aria-checked`],Eh={key:0,class:`plain`},Dh={class:`field`},Oh={class:`field`},kh={class:`foot`},Ah={class:`hint`},jh={type:`submit`,class:`primary`},Mh=Ep(V({__name:`MarginComposer`,props:{draft:{},placement:{}},emits:[`switchMode`,`save`,`cancel`],setup(e,{emit:t}){let n=e,r=t,i=z(null),a=z(null);vr(async()=>{await En(),a.value?.focus({preventScroll:!0})}),qn(()=>n.placement,()=>i.value?.scrollIntoView({block:`nearest`,behavior:`smooth`}),{flush:`post`,immediate:!0});function o(e){e.key===`Enter`&&(e.metaKey||e.ctrlKey)?(e.preventDefault(),r(`save`)):e.key===`Escape`&&(e.preventDefault(),r(`cancel`))}async function s(e){r(`switchMode`,e),await En(),a.value?.focus({preventScroll:!0})}return(t,n)=>(U(),W(`form`,{ref_key:`root`,ref:i,class:ye([`margin-pop`,e.placement.side]),style:me({top:`${e.placement.top}px`,left:`${e.placement.left}px`}),"aria-label":e.draft.mode===`suggest`?`Suggest an edit`:`New comment`,onSubmit:n[6]||=zo(e=>r(`save`),[`prevent`]),onKeydown:o},[K(`div`,Sh,[K(`span`,null,I(B(Ym)(e.draft)),1),K(`div`,Ch,[K(`button`,{type:`button`,role:`radio`,"aria-checked":e.draft.mode===`comment`,onClick:n[0]||=e=>s(`comment`)},` Comment `,8,wh),K(`button`,{type:`button`,role:`radio`,"aria-checked":e.draft.mode===`suggest`,onClick:n[1]||=e=>s(`suggest`)},` Suggest edit `,8,Th)])]),e.draft.mode===`comment`?(U(),W(`label`,Eh,[n[7]||=K(`span`,{class:`visually-hidden`},`Comment`,-1),Vn(K(`textarea`,{ref_key:`field`,ref:a,"onUpdate:modelValue":n[2]||=t=>e.draft.body=t,rows:`3`,placeholder:`Add a comment…`},null,512),[[Mo,e.draft.body]])])):(U(),W(H,{key:1},[K(`label`,Dh,[n[8]||=J(` Replace with `,-1),Vn(K(`textarea`,{ref_key:`field`,ref:a,"onUpdate:modelValue":n[3]||=t=>e.draft.suggestion=t,rows:`3`},null,512),[[Mo,e.draft.suggestion]])]),K(`label`,Oh,[n[9]||=K(`span`,null,[J(`Why `),K(`span`,{class:`optional`},`(optional)`)],-1),Vn(K(`input`,{"onUpdate:modelValue":n[4]||=t=>e.draft.body=t,type:`text`},null,512),[[Mo,e.draft.body]])])],64)),K(`div`,kh,[K(`span`,Ah,I(e.draft.mode===`suggest`?`Preview in the text`:`⌘↵ to save`),1),K(`button`,{type:`button`,class:`ghost`,onClick:n[5]||=e=>r(`cancel`)},`Cancel`),K(`button`,jh,I(e.draft.editingId?`Save`:e.draft.mode===`suggest`?`Suggest`:`Comment`),1)])],46,xh))}}),[[`__scopeId`,`data-v-b21eecf1`]]),Nh=`modulepreload`,Ph=function(e){return`/`+e},Fh={},Ih=function(e){return e.pathname.endsWith(`.css`)},Lh=function(e,t,n){if(t in e)return e[t];let r=n();if(!r){e[t]=void 0;return}let i=r.then(()=>{e[t]=void 0},n=>{throw e[t]=void 0,n});return e[t]=i,i},Rh=function(e,t,n){let r=Promise.resolve();if(t&&t.length>0){let e,i=document.querySelector(`meta[property=csp-nonce]`),a=i?.nonce||i?.getAttribute(`nonce`);function o(e){return Promise.all(e.map(e=>Promise.resolve(e).then(e=>({status:`fulfilled`,value:e}),e=>({status:`rejected`,reason:e}))))}function s(e){return import.meta.resolve?new URL(import.meta.resolve(e)):new URL(e,import.meta.url)}r=o(t.map(t=>{t=Ph(t,n);let r=s(t),i=Ih(r);return Lh(Fh,r.href,()=>{if(e===void 0){e={all:new Set,styles:new Set};let t=document.getElementsByTagName(`link`);for(let n=t.length-1;n>=0;n--){let r=t[n];e.all.add(r.href),r.rel===`stylesheet`&&e.styles.add(r.href)}}if((i?e.styles:e.all).has(r.href))return;let t=document.createElement(`link`);if(t.rel=i?`stylesheet`:Nh,i||(t.as=`script`),t.crossOrigin=``,t.href=r.href,a&&t.setAttribute(`nonce`,a),document.head.appendChild(t),i)return new Promise((e,n)=>{t.addEventListener(`load`,e),t.addEventListener(`error`,()=>n(Error(`Unable to preload CSS for ${r}`)))})})}).filter(e=>e!==void 0))}function i(e){let t=new Event(`vite:preloadError`,{cancelable:!0});if(t.payload=e,window.dispatchEvent(t),!t.defaultPrevented)throw e}return r.then(t=>{for(let e of t||[])e.status===`rejected`&&i(e.reason);return e().catch(i)})},zh=new Map,Bh=null,Vh=null,Hh=0,Uh=Promise.resolve();function Wh(e,t){return`${e}\n${t}`}function Gh(e){return((e instanceof Error?e.message:String(e)).split(`
26
+ `).find(e=>e.trim())??`Invalid diagram`).trim().replace(/:$/,``)}function Kh(e,t){let n=Wh(t,e),r=zh.get(n);if(r)return r;let i=qh(()=>Jh(e,t));return zh.set(n,i),i}function qh(e){let t=Uh.then(e,e);return Uh=t.catch(()=>void 0),t}async function Jh(e,t){let n=await Yh();Vh!==t&&(n.initialize({startOnLoad:!1,securityLevel:`strict`,theme:t===`dark`?`dark`:`default`,fontFamily:`IBM Plex Sans, system-ui, sans-serif`}),Vh=t);let r=`mdifit-diagram-${++Hh}`;try{await n.parse(e);let{svg:t}=await n.render(r,e);return{svg:t,error:null}}catch(e){return{svg:null,error:Gh(e)}}finally{document.getElementById(`d${r}`)?.remove(),document.getElementById(r)?.remove()}}function Yh(){return Bh??=Rh(()=>import(`./mermaid.core-CC7Mjmim.js`).then(e=>e.default),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18])),Bh}function Xh(){let e=window.matchMedia(`(prefers-color-scheme: dark)`),t=z(e.matches?`dark`:`light`),n=e=>t.value=e.matches?`dark`:`light`;return e.addEventListener(`change`,n),xr(()=>e.removeEventListener(`change`,n)),t}var Zh={class:`diagram`},Qh={class:`tools`},$h={class:`segmented`,role:`radiogroup`,"aria-label":`Show`},eg=[`aria-checked`],tg=[`aria-checked`],ng={key:0,class:`error`,role:`status`},rg=[`innerHTML`],ig=[`innerHTML`],ag={key:2,class:`loading`},og=[`innerHTML`],sg=Ep(V({__name:`DiagramBlock`,props:{source:{},codeHtml:{}},setup(e){let t=e,n=Xh(),r=z(null),i=z(`diagram`),a=z(null);return qn(()=>[t.source,n.value],async([e,i])=>{let a=await Kh(e,i);e===t.source&&i===n.value&&(r.value=a)},{immediate:!0}),(t,n)=>(U(),W(`figure`,Zh,[K(`div`,Qh,[K(`div`,$h,[K(`button`,{type:`button`,role:`radio`,"aria-checked":i.value===`diagram`,onClick:n[0]||=e=>i.value=`diagram`},` Diagram `,8,eg),K(`button`,{type:`button`,role:`radio`,"aria-checked":i.value===`code`,onClick:n[1]||=e=>i.value=`code`},` Code `,8,tg)]),r.value?.svg&&i.value===`diagram`?(U(),W(`button`,{key:0,type:`button`,class:`btn-icon`,"aria-label":`Open the diagram full size`,title:`Full size`,onClick:n[2]||=e=>a.value?.showModal()},[q($,{name:`expand`})])):Y(``,!0)]),i.value===`code`||r.value?.error?(U(),W(H,{key:0},[r.value?.error&&i.value===`diagram`?(U(),W(`p`,ng,` Mermaid: `+I(r.value.error),1)):Y(``,!0),K(`div`,{class:`markdown`,"data-doc":``,innerHTML:e.codeHtml},null,8,rg)],64)):r.value?.svg?(U(),W(`div`,{key:1,class:`svg`,"data-doc":``,innerHTML:r.value.svg},null,8,ig)):(U(),W(`p`,ag,`Drawing diagram…`)),K(`dialog`,{ref_key:`dialog`,ref:a,class:`full`,"aria-label":`Diagram`,onClick:n[4]||=zo(e=>a.value?.close(),[`self`])},[K(`header`,null,[n[5]||=K(`span`,null,`Diagram`,-1),K(`button`,{type:`button`,class:`btn-icon`,"aria-label":`Close`,onClick:n[3]||=e=>a.value?.close()},[q($,{name:`close`,size:18})])]),r.value?.svg?(U(),W(`div`,{key:0,class:`svg-full`,innerHTML:r.value.svg},null,8,og)):Y(``,!0)],512)]))}}),[[`__scopeId`,`data-v-df7e320a`]]),cg={class:`read`},lg=[`data-line-start`,`data-line-end`],ug=[`aria-label`,`onClick`],dg=[`innerHTML`],fg=Ep(V({__name:`ReadView`,props:{blocks:{}},emits:[`addAt`],setup(e,{emit:t}){let n=t;return(t,r)=>(U(),W(`div`,cg,[(U(!0),W(H,null,Mr(e.blocks,e=>(U(),W(`section`,{key:e.key,class:`block`,"data-line-start":e.startLine,"data-line-end":e.endLine},[K(`button`,{type:`button`,class:`add`,"aria-label":`Comment on line ${e.startLine}`,title:`Comment on this block`,onClick:t=>n(`addAt`,e)},[q($,{name:`plus`,size:14,"stroke-width":2.2})],8,ug),e.diagram===null?(U(),W(`div`,{key:1,class:`markdown`,"data-doc":``,innerHTML:e.html},null,8,dg)):(U(),G(sg,{key:0,source:e.diagram,"code-html":e.html},null,8,[`source`,`code-html`]))],8,lg))),128))]))}}),[[`__scopeId`,`data-v-3ac10086`]]),pg=44,mg=Ep(V({__name:`SelectionToolbar`,props:{rect:{}},emits:[`comment`,`suggest`,`copyRef`],setup(e,{emit:t}){let n=e,r=t,i=X(()=>{let e=n.rect.top-pg-8,t=e>8?e:n.rect.bottom+8,r=Math.min(Math.max(n.rect.left+n.rect.width/2,130),window.innerWidth-130);return{top:`${t}px`,left:`${r}px`}});return(e,t)=>(U(),W(`div`,{class:`toolbar`,role:`toolbar`,"aria-label":`Selection`,style:me(i.value),onMousedown:t[3]||=zo(()=>{},[`prevent`])},[K(`button`,{type:`button`,title:`Comment (C)`,onClick:t[0]||=e=>r(`comment`)},[q($,{name:`comment`,size:16}),t[4]||=J(`Comment `,-1)]),K(`button`,{type:`button`,title:`Suggest an edit (S)`,onClick:t[1]||=e=>r(`suggest`)},[q($,{name:`edit`,size:16}),t[5]||=J(`Suggest `,-1)]),K(`button`,{type:`button`,"aria-label":`Copy reference`,title:`Copy reference`,onClick:t[2]||=e=>r(`copyRef`)},[q($,{name:`link`,size:16})])],36))}}),[[`__scopeId`,`data-v-6153ab2c`]]),hg={class:`source`},gg=[`data-line-start`,`data-line-end`],_g=[`aria-label`,`onClick`],vg={class:`text`,"data-doc":``},yg={class:`after`},bg=Ep(V({__name:`SourceView`,props:{lines:{}},emits:[`addAt`],setup(e,{emit:t}){let n=e,r=t,i=X(()=>Gm(n.lines)),a=z(null);function o(e,t){t.shiftKey&&a.value!==null?r(`addAt`,{startLine:Math.min(a.value,e),endLine:Math.max(a.value,e)}):r(`addAt`,{startLine:e,endLine:e}),a.value=e}return(t,n)=>(U(),W(`div`,hg,[(U(!0),W(H,null,Mr(e.lines,(e,n)=>(U(),W(H,{key:n},[K(`div`,{class:ye([`src-line`,i.value[n]]),"data-line-start":n+1,"data-line-end":n+1},[K(`button`,{type:`button`,class:`number`,"aria-label":`Comment on line ${n+1}`,title:`Comment on this line (shift-click for a range)`,onClick:e=>o(n+1,e)},I(n+1),9,_g),K(`span`,vg,I(e||` `),1)],10,gg),K(`div`,yg,[Pr(t.$slots,`after`,{line:n+1},void 0,!0)])],64))),128))]))}}),[[`__scopeId`,`data-v-0c60cb9e`]]),xg=[`mdifit-comment`,`mdifit-suggest`,`mdifit-active`,`mdifit-pending`,`mdifit-del`];function Sg(e,t){typeof CSS<`u`&&`highlights`in CSS&&(t.length===0?CSS.highlights.delete(e):CSS.highlights.set(e,new Highlight(...t)))}function Cg(){for(let e of xg)Sg(e,[])}function wg(e,t){let n=null;for(let r of e.querySelectorAll(`.block`))if(Number(r.dataset.lineStart)<=t)n=r;else break;return n??e.querySelector(`.block`)}function Tg(e,t){if(!t.quote)return null;let n=Ag(e,t.startLine,t.endLine),r=Ss(n.map(e=>e.data),t.quote),i=r?n[r.start.segment]:void 0,a=r?n[r.end.segment]:void 0;if(!r||!i||!a)return null;let o=document.createRange();return o.setStart(i,r.start.offset),o.setEnd(a,r.end.offset),o}function Eg(e,t){let n=e.getBoundingClientRect(),r=t instanceof Range?t.getClientRects():[t.getBoundingClientRect()],i=r[0]??t.getBoundingClientRect(),a=r[r.length-1]??i;return{top:i.top-n.top,bottom:a.bottom-n.top}}function Dg(e){return e!==null&&e.startContainer.isConnected&&!e.collapsed}function Og(e,t){let n=document.createElement(`ins`);n.className=`mdifit-preview`,n.textContent=` ${t}`;let r=e.cloneRange();return r.collapse(!1),r.insertNode(n),n}function kg(e){if(!e)return;let t=e.parentNode;e.remove(),t?.normalize()}function Ag(e,t,n){let r=[];for(let i of e.querySelectorAll(`.block`)){let e=Number(i.dataset.lineStart);if(!(Number(i.dataset.lineEnd)<t||e>n))for(let e of i.querySelectorAll(`[data-doc]`)){let t=document.createTreeWalker(e,NodeFilter.SHOW_TEXT);for(let e=t.nextNode();e;e=t.nextNode())e.parentElement?.closest(`.mdifit-preview`)||r.push(e)}}return r}var jg={key:0,class:`before`},Mg=[`aria-label`,`aria-expanded`,`onClick`],Ng={key:3,class:`empty`},Pg={class:`end`},Fg=[`href`],Ig=28,Lg=72,Rg=296,zg=Ep(V({__name:`Reader`,props:{file:{},rendered:{},comments:{},promptBase:{},mode:{},anchor:{},status:{},nextPath:{}},emits:[`add`,`update`,`remove`,`toggleRead`,`toast`],setup(e,{expose:t,emit:n}){let r=e,i=n,a=z(null),o=z(null),s=z(null),c=z(null),l=z(null),u=z([]),d=z(null),f=null,p=null,m=new Map,h=X(()=>r.file.source.split(`
27
+ `)),g=X(()=>Jm(r.comments)),_=X(()=>r.comments.find(e=>e.id===l.value)??null),v=X(()=>g.value.findIndex(e=>e.id===l.value));function y(e){let t=h.value.length;return r.comments.filter(n=>Math.min(n.endLine,t)===e)}function b(e){return e.filter(e=>e.id!==s.value?.editingId)}function x(e){return xm({...e,path:r.file.path},r.promptBase)}function S(e){if(s.value)return f??wg(e,s.value.startLine);let t=_.value;return t?m.get(t.id)??wg(e,t.startLine):null}function C(){let e=o.value;if(!e||r.mode!==`read`){Cg(),u.value=[],d.value=null;return}let t=s.value;t?.quote&&!Dg(f)&&(f=Tg(e,t)),w(),m.clear();let n=[],i=[],c=[];for(let a of r.comments){if(a.id===t?.editingId)continue;let r=Tg(e,a);m.set(a.id,r),r&&(a.suggestion===null?n:i).push(r);let o=r??wg(e,a.startLine);o&&c.push({id:a.id,top:Eg(e,o).top})}Sg(`mdifit-comment`,n),Sg(`mdifit-suggest`,i);let p=l.value?m.get(l.value):null;Sg(`mdifit-active`,p?[p]:[]);let h=t&&f?[f]:[];Sg(`mdifit-pending`,t?.mode===`comment`?h:[]),Sg(`mdifit-del`,t?.mode===`suggest`?h:[]);let g=new Set(r.comments.filter(e=>e.suggestion!==null).map(e=>e.id));u.value=Km(c,Ig).map(e=>({...e,suggestion:g.has(e.id)}));let _=S(e),v=a.value?.getBoundingClientRect();d.value=_&&v?qm({anchor:Eg(e,_),pageWidth:e.offsetWidth,marginSpace:v.right-e.getBoundingClientRect().right,gutter:Lg,width:Rg}):null}function w(){kg(p),p=null;let e=s.value;e?.mode===`suggest`&&Dg(f)&&e.suggestion!==Bm(e,h.value)&&(p=Og(f,e.suggestion))}let ee=0;function T(){cancelAnimationFrame(ee),ee=requestAnimationFrame(C)}function E(){requestAnimationFrame(()=>{let e=o.value?Cs(o.value):null;if(!e){c.value=null;return}let t=r.mode===`read`?Im(h.value,e,e.quote):e;c.value={...e,startLine:t.startLine,endLine:t.endLine}})}function D(){c.value&&window.getSelection()?.isCollapsed&&(c.value=null)}function O(e){let t=c.value;return t?(l.value=null,f=r.mode===`read`?t.range:null,s.value=Vm(e,{startLine:t.startLine,endLine:t.endLine,quote:t.quote},h.value),c.value=null,Es(),!0):!1}async function k(){let e=c.value;e&&(await Ds(Sm({id:``,path:r.file.path,startLine:e.startLine,endLine:e.endLine,quote:e.quote,body:``,suggestion:null,createdAt:0},{promptBase:r.promptBase,includeQuotes:!0}))&&i(`toast`,`Reference copied`),c.value=null,Es())}function te(e){l.value=null,f=null,s.value=Vm(`comment`,{startLine:e.startLine,endLine:e.endLine,quote:null},h.value)}function A(e){f=null,s.value=Vm(`comment`,{...e,quote:null},h.value)}function ne(e){s.value&&=Um(s.value,e,h.value)}function j(){kg(p),p=null,f=null,s.value=null}function M(e){return!e.body.trim()&&(e.mode===`comment`||e.suggestion===Bm(e,h.value))}function N(){let e=s.value;if(!e)return;let t=Wm(e,r.file.path,h.value);t?(e.editingId?i(`update`,e.editingId,t):i(`add`,t),j()):i(`toast`,e.mode===`suggest`?`Change the text to suggest an edit`:`Write a comment first`)}function re(e){f=m.get(e.id)?.cloneRange()??null,l.value=null,s.value=Hm(e)}function ie(e){l.value=null,i(`remove`,e.id)}async function P(e){await Ds(Sm(e,{promptBase:r.promptBase,includeQuotes:!0}))&&i(`toast`,`Prompt copied`)}function ae(e){(!s.value||M(s.value))&&(j(),l.value=l.value===e?null:e)}async function oe(e){let t=g.value;if(t.length===0)return;let n=t[(v.value+e+t.length)%t.length];if(!n)return;l.value=n.id,await En();let r=o.value;(m.get(n.id)?.startContainer.parentElement??(r?wg(r,n.startLine):null))?.scrollIntoView({block:`center`,behavior:`smooth`})}function F(e){e.target?.closest(`.margin-pop, .bubble, .toolbar`)||(l.value=null,s.value&&r.mode===`read`&&M(s.value)&&j())}function se(e){e.key===`Escape`&&l.value&&(l.value=null)}let ce=null;async function le(){await En();let e=o.value;if(!e)return;let t=ce!==r.file.path;if(ce=r.file.path,r.mode===`read`&&r.anchor?.startsWith(`comment-`)){let t=r.anchor.slice(8);if(r.comments.some(e=>e.id===t)){l.value=t,C();let n=m.get(t)?.startContainer.parentElement;ks(n??wg(e,r.comments.find(e=>e.id===t)?.startLine??1));return}}let n=r.mode===`source`?r.rendered.headings.find(e=>e.slug===r.anchor)?.line:void 0,i=zf(r.anchor)??n??null;if(i!==null){let t=r.mode===`read`?`.block[data-line-start="${zm(r.rendered.blocks,i)?.startLine}"]`:`.src-line[data-line-start="${i}"]`;ks(e.querySelector(t))}else if(r.anchor){let t=document.getElementById(r.anchor);t&&e.contains(t)&&ks(t,r.anchor.startsWith(`comment-`)?`center`:`start`)}else t&&a.value?.scrollTo({top:0})}qn(()=>r.file.path,()=>{j(),l.value=null}),qn(()=>[r.file.path,r.anchor,r.mode],le,{immediate:!0}),qn(()=>[r.rendered,r.comments,r.mode,l.value,s.value,s.value?.mode,s.value?.suggestion],()=>void En(T),{immediate:!0});let ue=null;return vr(()=>{document.addEventListener(`selectionchange`,D),document.addEventListener(`pointerdown`,F),window.addEventListener(`keydown`,se),window.addEventListener(`resize`,T),ue=new ResizeObserver(T),o.value&&ue.observe(o.value)}),xr(()=>{document.removeEventListener(`selectionchange`,D),document.removeEventListener(`pointerdown`,F),window.removeEventListener(`keydown`,se),window.removeEventListener(`resize`,T),ue?.disconnect(),cancelAnimationFrame(ee),kg(p),Cg()}),t({startFromSelection:O}),(t,n)=>(U(),W(`main`,{ref_key:`scroller`,ref:a,class:`reader`,onScrollPassive:n[8]||=e=>c.value=null},[K(`article`,{ref_key:`content`,ref:o,class:ye([`page`,e.mode]),onMouseup:E,onKeyup:zo(E,[`shift`])},[t.$slots.before?(U(),W(`div`,jg,[Pr(t.$slots,`before`,{},void 0,!0)])):Y(``,!0),e.mode===`read`?(U(),W(H,{key:1},[q(fg,{blocks:e.rendered.blocks,onAddAt:te},null,8,[`blocks`]),(U(!0),W(H,null,Mr(u.value,e=>(U(),W(`button`,{key:e.id,type:`button`,class:ye([`bubble`,{active:e.id===l.value}]),style:me({top:`${e.top}px`}),"aria-label":e.suggestion?`Open suggested edit`:`Open comment`,"aria-expanded":e.id===l.value,onClick:t=>ae(e.id)},[q($,{name:e.suggestion?`edit`:`comment`,size:14},null,8,[`name`])],14,Mg))),128)),s.value&&d.value?(U(),G(Mh,{key:`${s.value.startLine}-${s.value.endLine}-${s.value.editingId}`,draft:s.value,placement:d.value,onSwitchMode:ne,onSave:N,onCancel:j},null,8,[`draft`,`placement`])):_.value&&d.value?(U(),G(bh,{key:1,comment:_.value,placement:d.value,index:v.value,total:g.value.length,onPrevious:n[0]||=e=>oe(-1),onNext:n[1]||=e=>oe(1),onCopy:n[2]||=e=>P(_.value),onEdit:n[3]||=e=>re(_.value),onRemove:n[4]||=e=>ie(_.value)},null,8,[`comment`,`placement`,`index`,`total`])):Y(``,!0)],64)):(U(),G(bg,{key:2,lines:h.value,onAddAt:A},{after:Bn(({line:t})=>[(U(!0),W(H,null,Mr(b(y(t)),t=>(U(),G(ah,{key:t.id,comment:t,"prompt-base":e.promptBase,onEdit:e=>re(t),onRemove:e=>i(`remove`,t.id),onCopy:e=>P(t)},null,8,[`comment`,`prompt-base`,`onEdit`,`onRemove`,`onCopy`]))),128)),s.value&&Math.min(s.value.endLine,h.value.length)===t?(U(),G(ph,{key:`${s.value.startLine}-${s.value.endLine}-${s.value.editingId}`,draft:s.value,lines:h.value,location:x(s.value),onSwitchMode:ne,onSave:N,onCancel:j},null,8,[`draft`,`lines`,`location`])):Y(``,!0)]),_:1},8,[`lines`])),e.file.source.trim()===``?(U(),W(`p`,Ng,`This file is empty.`)):Y(``,!0),K(`footer`,Pg,[K(`button`,{type:`button`,class:ye([`btn`,e.status===`read`?``:`btn-primary`]),title:`R`,onClick:n[5]||=e=>i(`toggleRead`)},[q($,{name:`check`}),J(` `+I(e.status===`read`?`Read · mark unread`:e.status===`edited`?`Changed since you read it · mark read`:`Mark as read`),1)],2),e.nextPath?(U(),W(`a`,{key:0,class:`next`,href:B(If)({path:e.nextPath,anchor:null})},[J(` Next: `+I(e.nextPath)+` `,1),q($,{name:`arrow-right`})],8,Fg)):Y(``,!0)])],34),c.value?(U(),G(mg,{key:0,rect:c.value.rect,onComment:n[6]||=e=>O(`comment`),onSuggest:n[7]||=e=>O(`suggest`),onCopyRef:k},null,8,[`rect`])):Y(``,!0)],544))}}),[[`__scopeId`,`data-v-aa7fa4d6`]]),Bg=Ep(V({__name:`ShortcutsDialog`,props:{open:{type:Boolean}},emits:[`close`],setup(e,{emit:t}){let n=e,r=t,i=z(null);return qn(()=>n.open,e=>e?i.value?.showModal():i.value?.close(),{flush:`post`}),(e,t)=>(U(),W(`dialog`,{ref_key:`dialog`,ref:i,class:`shortcuts`,"aria-labelledby":`shortcuts-title`,onClose:t[1]||=e=>r(`close`)},[K(`header`,null,[t[2]||=K(`h2`,{id:`shortcuts-title`},`Keyboard shortcuts`,-1),K(`button`,{type:`button`,class:`btn-icon`,"aria-label":`Close`,onClick:t[0]||=e=>r(`close`)},[q($,{name:`close`,size:18})])]),K(`dl`,null,[(U(!0),W(H,null,Mr(B(rp),e=>(U(),W(H,{key:e.action},[K(`dt`,null,[K(`kbd`,null,I(e.keys),1)]),K(`dd`,null,I(e.label),1)],64))),128)),t[3]||=K(`dt`,null,[K(`kbd`,null,`⌘↵`)],-1),t[4]||=K(`dd`,null,`Save a comment / copy the prompt`,-1),t[5]||=K(`dt`,null,[K(`kbd`,null,`Shift`),J(` + click`)],-1),t[6]||=K(`dd`,null,`Comment on a range of source lines`,-1)])],544))}}),[[`__scopeId`,`data-v-6c3846be`]]);function Vg(e){let t={kind:`folder`,name:``,path:``,children:[]};for(let n of Hg(e)){let r=n.path.split(`/`),i=t;for(let e of r.slice(0,-1)){let t=i.path?`${i.path}/${e}`:e,n=i.children.find(t=>t.kind===`folder`&&t.name===e);n||(n={kind:`folder`,name:e,path:t,children:[]},i.children.push(n)),i=n}i.children.push({kind:`file`,name:r.at(-1)??n.path,path:n.path,title:n.title,status:es(n,e.read),comments:e.commentCounts.get(n.path)??0})}return Kg(t.children.map(Gg))}function Hg(e){let t=ap(e.query.trim());return e.files.filter(n=>e.filter===`unread`&&es(n,e.read)===`read`||e.filter===`commented`&&!e.commentCounts.get(n.path)?!1:!t||ap(`${n.path} ${n.title??``}`).includes(t))}function Ug(e,t,n){return{all:e.length,unread:e.filter(e=>es(e,t)!==`read`).length,commented:e.filter(e=>n.get(e.path)).length}}function Wg(e){return e.flatMap(e=>e.kind===`file`?[e]:Wg(e.children))}function Gg(e){if(e.kind===`file`)return e;let t=e;for(;t.children.length===1&&t.children[0]?.kind===`folder`;){let e=t.children[0];t={...e,name:`${t.name}/${e.name}`}}return{...t,children:t.children.map(Gg)}}function Kg(e){return e.map(e=>e.kind===`folder`?{...e,children:Kg(e.children)}:e).toSorted((e,t)=>e.kind===t.kind?e.name.localeCompare(t.name,`en`,{sensitivity:`base`,numeric:!0}):e.kind===`folder`?-1:1)}var qg={class:`node`},Jg=[`aria-expanded`,`aria-label`],Yg=[`href`,`aria-current`],Xg={key:0,class:`children`},Zg=[`href`,`aria-current`,`title`],Qg=[`title`],$g={class:`name`},e_={key:0,class:`badge`},t_=[`aria-label`],n_={key:0,class:`outline`,"aria-label":`Outline`},r_=[`href`],i_=Ep(V({__name:`TreeNodeRow`,props:{node:{},depth:{},currentPath:{},currentFolder:{},collapsed:{},headings:{}},emits:[`toggle`],setup(e,{emit:t}){let n=t;return(t,r)=>{let i=Or(`TreeNodeRow`,!0);return U(),W(`li`,qg,[e.node.kind===`folder`?(U(),W(H,{key:0},[K(`div`,{class:ye([`row folder`,{active:`${e.node.path}/`===e.currentFolder}]),style:me({paddingLeft:`${4+e.depth*14}px`})},[K(`button`,{type:`button`,class:`chevron`,"aria-expanded":!e.collapsed.has(e.node.path),"aria-label":`${e.collapsed.has(e.node.path)?`Expand`:`Collapse`} ${e.node.name}`,onClick:r[0]||=t=>n(`toggle`,e.node.path)},[q($,{name:e.collapsed.has(e.node.path)?`chevron-right`:`chevron-down`,size:14,"stroke-width":2.4},null,8,[`name`])],8,Jg),K(`a`,{class:`name`,href:B(If)({path:`${e.node.path}/`,anchor:null}),"aria-current":`${e.node.path}/`===e.currentFolder?`page`:void 0},I(e.node.name),9,Yg)],6),e.collapsed.has(e.node.path)?Y(``,!0):(U(),W(`ul`,Xg,[(U(!0),W(H,null,Mr(e.node.children,t=>(U(),G(i,{key:t.path,node:t,depth:e.depth+1,"current-path":e.currentPath,"current-folder":e.currentFolder,collapsed:e.collapsed,headings:e.headings,onToggle:r[1]||=e=>n(`toggle`,e)},null,8,[`node`,`depth`,`current-path`,`current-folder`,`collapsed`,`headings`]))),128))]))],64)):(U(),W(H,{key:1},[K(`a`,{class:ye([`row file`,{active:e.node.path===e.currentPath,read:e.node.status===`read`}]),href:B(If)({path:e.node.path,anchor:null}),style:me({paddingLeft:`${8+e.depth*14}px`}),"aria-current":e.node.path===e.currentPath?`page`:void 0,title:e.node.title??e.node.path},[K(`span`,{class:ye([`status`,e.node.status]),title:e.node.status===`edited`?`Changed since you read it`:void 0},[e.node.status===`read`?(U(),G($,{key:0,name:`check`,size:14,"stroke-width":2.6})):(U(),G($,{key:1,name:`file`,size:15}))],10,Qg),K(`span`,$g,I(e.node.name),1),e.node.status===`edited`?(U(),W(`span`,e_,`edited`)):Y(``,!0),e.node.comments?(U(),W(`span`,{key:1,class:`count`,"aria-label":`${e.node.comments} comments`},[q($,{name:`comment`,size:13}),J(I(e.node.comments),1)],8,t_)):Y(``,!0)],14,Zg),e.node.path===e.currentPath&&e.headings.length?(U(),W(`ul`,n_,[(U(!0),W(H,null,Mr(e.headings,t=>(U(),W(`li`,{key:t.slug},[K(`a`,{href:B(If)({path:e.node.path,anchor:t.slug}),style:me({paddingLeft:`${30+e.depth*14+(t.level-1)*12}px`})},I(t.text),13,r_)]))),128))])):Y(``,!0)],64))])}}}),[[`__scopeId`,`data-v-23877561`]]),a_={class:`sidebar`,"aria-label":`Files`},o_={class:`search`},s_={class:`field`},c_={class:`filters`,role:`radiogroup`,"aria-label":`Show`},l_=[`aria-checked`,`onClick`],u_={key:0,class:`tree`},d_={key:1,class:`empty`},f_=Ep(V({__name:`Sidebar`,props:{files:{},read:{},commentCounts:{},currentPath:{},currentFolder:{},headings:{}},setup(e){let t=e,n=z(`all`),r=z(``),i=Ut(new Set),a=X(()=>Vg({files:t.files,read:t.read,commentCounts:t.commentCounts,filter:n.value,query:r.value})),o=X(()=>Ug(t.files,t.read,t.commentCounts)),s=[{value:`all`,label:`All`},{value:`unread`,label:`Unread`},{value:`commented`,label:`Commented`}];function c(e){i.has(e)?i.delete(e):i.add(e)}return(t,l)=>(U(),W(`aside`,a_,[K(`div`,o_,[K(`label`,s_,[q($,{name:`search`}),l[1]||=K(`span`,{class:`visually-hidden`},`Filter files`,-1),Vn(K(`input`,{"onUpdate:modelValue":l[0]||=e=>r.value=e,type:`search`,placeholder:`Filter files…`},null,512),[[Mo,r.value]])])]),K(`div`,c_,[(U(),W(H,null,Mr(s,e=>K(`button`,{key:e.value,type:`button`,role:`radio`,"aria-checked":n.value===e.value,onClick:t=>n.value=e.value},[J(I(e.label)+` `,1),K(`span`,null,I(o.value[e.value]),1)],8,l_)),64))]),a.value.length?(U(),W(`ul`,u_,[(U(!0),W(H,null,Mr(a.value,t=>(U(),G(i_,{key:t.path,node:t,depth:0,"current-path":e.currentPath,"current-folder":e.currentFolder,collapsed:i,headings:e.headings,onToggle:c},null,8,[`node`,`current-path`,`current-folder`,`collapsed`,`headings`]))),128))])):(U(),W(`p`,d_,I(e.files.length===0?`No Markdown files here.`:`No files match.`),1))]))}}),[[`__scopeId`,`data-v-18a9062d`]]);function p_(e,t,n){let r=(n??t??``).split(`/`).filter(Boolean),i=[{label:e,path:``,current:!1}],a=``;r.forEach((e,t)=>{a=t===r.length-1&&n!==null?`${a}${e}`:`${a}${e}/`,i.push({label:e,path:a,current:!1})});let o=i.at(-1);return o&&(o.current=!0),i}var m_={class:`topbar`},h_=[`aria-pressed`,`aria-label`,`title`],g_={class:`path`,"aria-label":`Breadcrumb`},__=[`title`],v_=[`href`,`title`],y_=[`aria-label`,`title`],b_={class:`segmented`,role:`group`,"aria-label":`View`},x_=[`aria-pressed`],S_=[`aria-pressed`],C_={class:`progress`},w_={class:`bar`,"aria-hidden":`true`},T_=[`disabled`],E_=[`aria-pressed`,`aria-label`,`title`],D_=Ep(V({__name:`TopBar`,props:{crumbs:{},copyablePath:{},mode:{},showFiles:{type:Boolean},showComments:{type:Boolean},hasFiles:{type:Boolean},readCount:{},fileCount:{},commentCount:{}},emits:[`update:mode`,`openPrompt`,`openPalette`,`copyPath`,`toggleFiles`,`toggleComments`],setup(e,{emit:t}){let n=t;return(t,r)=>(U(),W(`header`,m_,[e.hasFiles?(U(),W(`button`,{key:0,type:`button`,class:`btn-icon panel-toggle`,"aria-pressed":e.showFiles,"aria-label":e.showFiles?`Hide files panel`:`Show files panel`,title:`${e.showFiles?`Hide`:`Show`} files (B)`,onClick:r[0]||=e=>n(`toggleFiles`)},[q($,{name:`panel-left`,size:18})],8,h_)):Y(``,!0),r[9]||=fa(`<div class="brand" data-v-a62fdb6b><svg width="24" height="24" viewBox="0 0 64 64" aria-hidden="true" data-v-a62fdb6b><rect width="64" height="64" rx="15" fill="currentColor" data-v-a62fdb6b></rect><rect x="13" y="16" width="28" height="4.5" rx="2.25" fill="var(--surface)" data-v-a62fdb6b></rect><rect x="13" y="27.5" width="22" height="4.5" rx="2.25" fill="var(--surface)" data-v-a62fdb6b></rect><rect x="13" y="34.5" width="22" height="2.5" rx="1.25" fill="var(--brand-accent)" data-v-a62fdb6b></rect><rect x="13" y="43.5" width="25" height="4.5" rx="2.25" fill="var(--surface)" opacity="0.5" data-v-a62fdb6b></rect><path d="M43 24.5h9a3 3 0 0 1 3 3v6.5a3 3 0 0 1-3 3h-4.5l-3.5 3.25V37h-1a3 3 0 0 1-3-3v-6.5a3 3 0 0 1 3-3z" fill="var(--brand-accent)" data-v-a62fdb6b></path></svg> mdifit </div>`,1),K(`nav`,g_,[K(`ol`,null,[(U(!0),W(H,null,Mr(e.crumbs,e=>(U(),W(`li`,{key:e.path},[e.current?(U(),W(`span`,{key:0,class:`crumb current`,"aria-current":`page`,title:e.label},I(e.label),9,__)):(U(),W(H,{key:1},[K(`a`,{class:`crumb`,href:B(If)({path:e.path,anchor:null}),title:e.label},I(e.label),9,v_),q($,{name:`chevron-right`,size:14,class:`sep`})],64))]))),128))]),e.copyablePath?(U(),W(`button`,{key:0,type:`button`,class:`btn-icon`,"aria-label":`Copy path ${e.copyablePath}`,title:`Copy ${e.copyablePath}`,onClick:r[1]||=e=>n(`copyPath`)},[q($,{name:`copy`})],8,y_)):Y(``,!0)]),K(`div`,b_,[K(`button`,{type:`button`,"aria-pressed":e.mode===`read`,onClick:r[2]||=e=>n(`update:mode`,`read`)},` Read `,8,x_),K(`button`,{type:`button`,"aria-pressed":e.mode===`source`,onClick:r[3]||=e=>n(`update:mode`,`source`)},` Source `,8,S_)]),K(`div`,C_,[K(`span`,null,I(e.readCount)+` / `+I(e.fileCount)+` read`,1),K(`span`,w_,[K(`span`,{style:me({width:`${e.fileCount?e.readCount/e.fileCount*100:0}%`})},null,4)])]),K(`button`,{type:`button`,class:`btn`,title:`Search files, headings and text`,onClick:r[4]||=e=>n(`openPalette`)},[q($,{name:`search`}),r[7]||=J(` Search `,-1),r[8]||=K(`kbd`,null,`⌘K`,-1)]),K(`button`,{type:`button`,class:`btn btn-comment`,disabled:e.commentCount===0,title:`Review and copy the prompt (P)`,onClick:r[5]||=e=>n(`openPrompt`)},[q($,{name:`copy`}),J(` Copy prompt · `+I(e.commentCount),1)],8,T_),K(`button`,{type:`button`,class:`btn-icon panel-toggle`,"aria-pressed":e.showComments,"aria-label":e.showComments?`Hide comments panel`:`Show comments panel`,title:`${e.showComments?`Hide`:`Show`} comments (N)`,onClick:r[6]||=e=>n(`toggleComments`)},[q($,{name:`panel-right`,size:18})],8,E_)]))}}),[[`__scopeId`,`data-v-a62fdb6b`]]),O_={key:0,class:`fatal`,role:`alert`},k_={key:1,class:`shell`},A_={key:3,class:`placeholder`},j_={key:0,role:`alert`},M_={key:1},N_={key:2},P_={class:`toast`,role:`status`,"aria-live":`polite`},F_={key:0};Uo(Ep(V({__name:`App`,setup(e){let t=tn(null),n=tn(null),r=tn(null),i=z(Ff(location.hash)),a=z(gs()),o=z(null),s=z(null),c=z(null),l=z(null),u=z(null),d=z({}),f=X(()=>t.value?.files??[]),p=X(()=>t.value?.promptBase??``),m=X(()=>a.value.showFiles&&!t.value?.single),h=X(()=>n.value?.state.comments??[]),g=X(()=>n.value?.state.read??{}),_=X(()=>$o(h.value)),v=X(()=>Wg(Vg({files:f.value,read:{},commentCounts:new Map,filter:`all`,query:``})).map(e=>e.path)),y=X(()=>Lf(i.value.path)?i.value.path:null),b=X(()=>y.value===null?[]:Kp(f.value,y.value)),x=X(()=>{if(y.value===null)return i.value.path;let e=d.value[y.value];return e&&b.value.includes(e)?e:b.value[0]??null}),S=X(()=>y.value===null?null:Jp(f.value,y.value,g.value,_.value)),C=X(()=>{let e=t.value?.name??``;return t.value?.single?[{label:e,path:x.value??``,current:!0}]:p_(e,y.value,x.value)}),w=X(()=>{let e=x.value??y.value;return e===null?null:`${p.value}${e}`||`./`}),ee=X(()=>f.value.find(e=>e.path===x.value)??null),T=X(()=>r.value?Gf(r.value.source,r.value.path):null),E=X(()=>h.value.filter(e=>e.path===r.value?.path)),D=X(()=>ee.value?es(ee.value,g.value):`unread`),O=X(()=>is(v.value,f.value,g.value,x.value));qn(a,_s,{deep:!0}),qn(()=>a.value.boca,e=>document.documentElement.toggleAttribute(`data-boca`,e),{immediate:!0});async function k(){try{let e=await cs();(!n.value||t.value?.rootPath!==e.rootPath)&&(n.value=fs(e.rootPath)),t.value=e,o.value=null,te(e)}catch(e){o.value=e instanceof os?e.message:String(e)}}function te(e){let t=i.value.path;if(e.single){let n=e.files[0]?.path;n&&t!==n&&j({path:n,anchor:null},!0);return}if(t===null){j({path:``,anchor:null},!0);return}if(Lf(t)?qp(e.files,t):e.files.some(e=>e.path===t))return;let n=Lf(t)?``:Rf(t);j({path:qp(e.files,n)?n:``,anchor:null},!0)}let A=0;async function ne(e){let t=++A;try{let n=await ls(e);if(t!==A)return;r.value=n,s.value=null,document.title=`${e} · mdifit`}catch(e){if(t!==A)return;s.value=e instanceof os?e.message:String(e)}}qn(x,e=>{e?ne(e):(r.value=null,s.value=null,document.title=`${y.value||t.value?.name||``} · mdifit`)},{immediate:!0});function j(e,t=!1){let n=If(e);t?history.replaceState(null,``,n):location.hash!==n&&(location.hash=n),i.value=e}function M(){i.value=Ff(location.hash),t.value&&te(t.value)}function N(){let e=ee.value;e&&n.value&&(D.value===`read`?n.value.markUnread(e.path):n.value.markRead(e))}function re(e,t,r){r&&n.value?.clearComments(t),l.value=null,F(`Copied ${op(e,`comment`)}${r?` and deleted them`:``}`)}async function ie(){w.value&&await Ds(w.value)&&F(`Path copied`)}function P(e){y.value!==null&&(d.value={...d.value,[y.value]:e})}function ae(e){l.value=null,j({path:e.path,anchor:e.line?`L${e.line}`:null})}let oe;function F(e){c.value=e,clearTimeout(oe),oe=setTimeout(()=>c.value=null,2200)}let se=tp;function ce(e,n){if(n||l.value||e.metaKey||e.ctrlKey||e.altKey)return!1;let r=np(se,e.key,Date.now());return se=r.state,r.undoFirst&&!t.value?.single&&(a.value.showFiles=!a.value.showFiles),r.matched&&(a.value.boca=!a.value.boca,F(a.value.boca?`Azul y oro. Dale Boca.`:`Azul y oro, en pausa.`)),r.consumed&&e.preventDefault(),r.consumed}function le(e){let n=Os(e.target);if(ce(e,n))return;let r=ip({key:e.key,metaKey:e.metaKey,ctrlKey:e.ctrlKey,altKey:e.altKey,editing:n});if(r&&!(l.value&&r!==`palette`))switch(e.preventDefault(),r){case`palette`:l.value=l.value===`palette`?null:`palette`;break;case`comment`:case`suggest`:u.value?.startFromSelection(r)||F(`Select some text first`);break;case`prompt`:h.value.length?l.value=`prompt`:F(`No comments yet`);break;case`toggleRead`:N();break;case`toggleMode`:a.value.mode=a.value.mode===`read`?`source`:`read`;break;case`nextFile`:case`previousFile`:{let e=rs(v.value,x.value,r===`nextFile`?1:-1);e&&j({path:e,anchor:null});break}case`toggleFiles`:t.value?.single||(a.value.showFiles=!a.value.showFiles);break;case`toggleComments`:a.value.showComments=!a.value.showComments;break;case`help`:l.value=`help`}}let ue=null;return vr(()=>{window.addEventListener(`hashchange`,M),window.addEventListener(`keydown`,le),k(),ue=ds(e=>{k(),e===x.value&&ne(e)})}),xr(()=>{window.removeEventListener(`hashchange`,M),window.removeEventListener(`keydown`,le),ue?.()}),(e,d)=>o.value?(U(),W(`div`,O_,[d[14]||=K(`h1`,null,`mdifit`,-1),K(`p`,null,I(o.value),1),K(`button`,{type:`button`,class:`btn btn-primary`,onClick:k},`Try again`)])):t.value&&n.value?(U(),W(`div`,k_,[q(D_,{mode:a.value.mode,"onUpdate:mode":d[0]||=e=>a.value.mode=e,"show-files":a.value.showFiles,"show-comments":a.value.showComments,"has-files":!t.value.single,crumbs:C.value,"copyable-path":w.value,"read-count":B(as)(f.value,g.value),"file-count":f.value.length,"comment-count":h.value.length,onOpenPrompt:d[1]||=e=>l.value=`prompt`,onOpenPalette:d[2]||=e=>l.value=`palette`,onCopyPath:ie,onToggleFiles:d[3]||=e=>a.value.showFiles=!a.value.showFiles,onToggleComments:d[4]||=e=>a.value.showComments=!a.value.showComments},null,8,[`mode`,`show-files`,`show-comments`,`has-files`,`crumbs`,`copyable-path`,`read-count`,`file-count`,`comment-count`]),K(`div`,{class:ye([`body`,{"no-files":!m.value,"no-comments":!a.value.showComments}])},[m.value?(U(),G(f_,{key:0,files:f.value,read:g.value,"comment-counts":_.value,"current-path":x.value,"current-folder":y.value,headings:T.value?.headings??[]},null,8,[`files`,`read`,`comment-counts`,`current-path`,`current-folder`,`headings`])):Y(``,!0),r.value&&T.value&&r.value.path===x.value?(U(),G(zg,{key:1,ref_key:`reader`,ref:u,file:r.value,rendered:T.value,comments:E.value,"prompt-base":p.value,mode:a.value.mode,anchor:i.value.anchor,status:D.value,"next-path":O.value,onAdd:d[5]||=e=>n.value.addComment(e),onUpdate:d[6]||=(e,t)=>n.value?.updateComment(e,t),onRemove:d[7]||=e=>n.value.removeComment(e),onToggleRead:N,onToast:F},Nr({_:2},[y.value!==null&&S.value?{name:`before`,fn:Bn(()=>[q(hm,{folder:y.value,"root-name":t.value.name,listing:S.value,entries:b.value,entry:r.value.path,onChooseEntry:P},null,8,[`folder`,`root-name`,`listing`,`entries`,`entry`])]),key:`0`}:void 0]),1032,[`file`,`rendered`,`comments`,`prompt-base`,`mode`,`anchor`,`status`,`next-path`])):y.value!==null&&x.value===null&&S.value?(U(),G(ym,{key:2,folder:y.value,"root-name":t.value.name,listing:S.value},null,8,[`folder`,`root-name`,`listing`])):(U(),W(`main`,A_,[s.value?(U(),W(`p`,j_,I(s.value),1)):f.value.length===0?(U(),W(`p`,M_,`No Markdown files in `+I(t.value.name)+`.`,1)):(U(),W(`p`,N_,`Loading…`))])),a.value.showComments?(U(),G(Wp,{key:4,comments:h.value,"current-path":x.value,onOpenPrompt:d[8]||=e=>l.value=`prompt`,onClear:d[9]||=e=>n.value.clearComments(e)},null,8,[`comments`,`current-path`])):Y(``,!0)],2),q(Pm,{"include-quotes":a.value.includeQuotes,"onUpdate:includeQuotes":d[10]||=e=>a.value.includeQuotes=e,open:l.value===`prompt`,comments:h.value,"current-path":x.value,"prompt-base":p.value,onClose:d[11]||=e=>l.value=null,onCopied:re},null,8,[`include-quotes`,`open`,`comments`,`current-path`,`prompt-base`]),q(Dp,{open:l.value===`palette`,files:f.value,onClose:d[12]||=e=>l.value=null,onGo:ae},null,8,[`open`,`files`]),q(Bg,{open:l.value===`help`,onClose:d[13]||=e=>l.value=null},null,8,[`open`]),K(`div`,P_,[c.value?(U(),W(`span`,F_,I(c.value),1)):Y(``,!0)])])):Y(``,!0)}}),[[`__scopeId`,`data-v-7e92f30f`]])).mount(`#app`);export{l as i,o as n,u as r,Rh as t};