gardenjs 1.6.4 → 1.6.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -12,38 +12,17 @@ permissions:
12
12
  contents: read
13
13
 
14
14
  jobs:
15
- build:
15
+ build-publish:
16
16
  runs-on: ubuntu-latest
17
17
  steps:
18
18
  - uses: actions/checkout@v4
19
- - uses: actions/setup-node@v4
20
19
  with:
21
- node-version: 22
22
- - run: npm ci
23
- - run: npm run build
24
-
25
- # Artefakt hochladen, damit publish-job darauf zugreifen kann
26
- - uses: actions/upload-artifact@v4
27
- with:
28
- name: dist
29
- path: dist
30
-
31
- publish-npm:
32
- needs: build
33
- runs-on: ubuntu-latest
34
- steps:
35
- - uses: actions/checkout@v4
20
+ ref: ${{ github.event.release.tag_name }}
36
21
  - uses: actions/setup-node@v4
37
22
  with:
38
- node-version: 22
23
+ node-version: 24
39
24
  registry-url: https://registry.npmjs.org/
40
25
  - run: npm install -g npm@latest
41
26
  - run: npm ci
42
-
43
- # Artefakt wieder herunterladen
44
- - uses: actions/download-artifact@v4
45
- with:
46
- name: dist
47
- path: dist
48
-
49
- - run: npm publish
27
+ - run: npm run build
28
+ - run: npm publish --access public
@@ -0,0 +1,46 @@
1
+ import{b as Rn,E as In,a as Ln,n as Fe,d as Hn,c as ge,p as ne,e as U,u as le,g as p,s as oe,f as te,o as sn,h as rn,i as E,j as w,k as f,l as et,t as Z,m as Nt,q as re,r as W,v as m,w as se,x as Ie,y as he,z as Nn,A as Bn,B as ln,C as P,D as tt,F as ae,G as an,H as An,I as Bt,J as ee,K as yt,L as be,M as nt,N as jn,O as G,P as y,Q as qn,R as A,S as Wn}from"./props-DKVIKFn7.js";import{routes as Pn,navTree as On}from"../base.js";import{dasMap as Dn}from"../das_import_map.js";import Un from"../../garden.config.js";function Ge(i,e,...t){var n=i,s=Fe,r;Rn(()=>{s!==(s=e())&&(r&&(Hn(r),r=null),r=Ln(()=>s(n,...t)))},In)}function Zn(i,e,t,n){document.addEventListener("mousemove",e),document.addEventListener("mouseup",t),te(n,!0)}var Fn=E('<div class="container svelte-1pql0kc"><div class="top svelte-1pql0kc"><!></div> <div></div> <!></div>');function Gn(i,e){ne(e,!0);let t=U(e,"topHeight",15),n=oe(void 0),s=oe(!1),r=oe(!1);le(()=>{if(p(n)&&!p(r)){if(te(r,!0),t()&&e.maxHeight)return;const T=p(n).offsetHeight;e.onSetMaxHeight(T),e.onSetTopHeight(Math.round(T*.7))}});const l=re(()=>{if(Number.isInteger(t())&&Number.isInteger(e.maxHeight))return e.maxHeight<t()?e.maxHeight+"px":t()+"px"}),a=new ResizeObserver(T=>{T.forEach(()=>{e.onSetMaxHeight(p(n).offsetHeight),e.onSetMaxWidth(p(n).offsetWidth)})});sn(()=>{a.observe(p(n))}),rn(()=>{a.disconnect()});const o=T=>{window.getSelection().removeAllRanges();const C=Math.min(e.maxHeight,T.pageY-p(n).offsetTop-7);t(C),e.onSetTopHeight(t())};function c(){document.removeEventListener("mousemove",o),document.removeEventListener("mouseup",c),e.onSetTopHeight(t()),te(s,!1)}var h=Fn(),g=f(h),d=f(g);Ge(d,()=>e.top??Fe);var u=w(g,2);let x;u.__mousedown=[Zn,o,c,s];var z=w(u,2);Ge(z,()=>e.bottom??Fe),et(h,T=>te(n,T),()=>p(n)),Z(T=>{Nt(g,`height: ${p(l)??""};`),x=W(u,1,"dragbar svelte-1pql0kc",null,x,T)},[()=>({dragging:p(s)})]),m(i,h),se()}ge(["mousedown"]);var Vn=E('<div><div><!></div> <div><div class="dragbar-icon svelte-mmou7f"></div></div> <div><div class="dragbar-icon svelte-mmou7f"></div></div> <div><div class="dragbar-icon svelte-mmou7f"></div></div></div>');function Qn(i,e){ne(e,!0);let t=U(e,"disabled",3,!1),n=oe(void 0),s="";const r=re(()=>Number.isInteger(Number(e.paneHeight))&&!t()?Math.min(Number(e.paneHeight),Number(e.maxHeight))+"px":e.maxHeight+"px"),l=re(()=>Number.isInteger(Number(e.paneWidth))?Math.min(Number(e.paneWidth),Number(e.maxWidth))+"px":e.maxWidth+"px"),a=B=>()=>{s=B,document.addEventListener("mousemove",o),document.addEventListener("mouseup",c)},o=B=>{if(window.getSelection().removeAllRanges(),s.includes("horizontal")){let q=B.pageY-p(n).offsetTop-11;q>e.maxHeight?q="full":(q=Math.min(e.maxHeight,q),q=Math.max(50,q)),e.onSetStageHeight(q)}if(s.includes("vertical")){let q=B.pageX-p(n).offsetLeft-10;q>e.maxWidth?q="full":(q=Math.min(e.maxWidth,q),q=Math.max(50,q)),e.onSetStageWidth(q)}};function c(){document.removeEventListener("mousemove",o),document.removeEventListener("mouseup",c)}var h=Vn();let g;var d=f(h);let u,x;var z=f(d);Ge(z,()=>e.children??Fe),et(d,B=>te(n,B),()=>p(n));var T=w(d,2);let C;var R=re(()=>a("vertical"));T.__mousedown=function(...B){p(R)?.apply(this,B)};var M=w(T,2);let N;var I=re(()=>a("horizontal"));M.__mousedown=function(...B){p(I)?.apply(this,B)};var L=w(M,2);let O;var F=re(()=>a("verticalhorizontal"));L.__mousedown=function(...B){p(F)?.apply(this,B)},Z((B,q,Ne,we,xe,pe)=>{g=W(h,1,"resizepane-container svelte-mmou7f",null,g,B),u=W(d,1,"resizepane",null,u,q),x=Nt(d,"",x,Ne),C=W(T,1,"dragbar vertical svelte-mmou7f",null,C,we),N=W(M,1,"dragbar horizontal svelte-mmou7f",null,N,xe),O=W(L,1,"dragbar corner svelte-mmou7f",null,O,pe)},[()=>({disabled:t()}),()=>({disabled:t()}),()=>({width:t()?void 0:p(l),height:t()?void 0:p(r)}),()=>({disabled:t()}),()=>({disabled:t()}),()=>({disabled:t()})]),m(i,h),se()}ge(["mousedown"]);function Xn(i,e){ne(e,!0);let t=U(e,"item",19,()=>({}));var n=Ie(),s=he(n);Nn(s,()=>t().page,(r,l)=>{l(r,Bn(()=>t().props))}),m(i,n),se()}var Kn=(i,e,t)=>e(p(t)),Yn=E('<li class="svelte-1opzoal"><button> <span class="dot svelte-1opzoal"></span></button></li>'),Jn=E('<div class="panel_nav svelte-1opzoal"><nav class="svelte-1opzoal"><ul class="svelte-1opzoal"></ul></nav> <button class="panel_toggle svelte-1opzoal" title="Collapse panel"><span class="is-hidden svelte-1opzoal">Collapse panel</span> <svg class="controls_btn-icon svelte-1opzoal" xmlns="http://www.w3.org/2000/svg" width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><rect width="18" height="18" x="3" y="3" rx="2" ry="2"></rect><line x1="3" x2="21" y1="15" y2="15"></line><path d="m15 8-3 3-3-3"></path></svg></button></div> <div class="panel_pane svelte-1opzoal"><!></div>',1),$n=E('<div class="panel_container svelte-1opzoal"><!></div>');function es(i,e){ne(e,!0);let t=U(e,"tabs",19,()=>[]),n=oe(ln({}));const s=re(()=>t()?t().find(c=>c.name===p(n))||t()[0]:{}),r=c=>{te(n,c.name,!0)};var l=$n(),a=f(l);{var o=c=>{var h=Jn(),g=he(h),d=f(g),u=f(d);tt(u,21,t,M=>M.name,(M,N)=>{var I=Yn(),L=f(I);L.__click=[Kn,r,N];let O;var F=f(L);Z(B=>{O=W(L,1,"svelte-1opzoal",null,O,B),ae(F,p(N).name)},[()=>({active:p(N).name===p(s).name})]),m(M,I)});var x=w(d,2);x.__click=function(...M){e.onToggleExpandPanel?.apply(this,M)};var z=w(g,2),T=f(z);{var C=M=>{Xn(M,{get item(){return p(s)}})},R=M=>{var N=Ie(),I=he(N);{var L=F=>{var B=Ie(),q=he(B);Ge(q,()=>e.children),m(F,B)},O=F=>{var B=an("No tab content provided");m(F,B)};P(I,F=>{e.children?F(L):F(O,!1)},!0)}m(M,N)};P(T,M=>{p(s)&&p(s).page?M(C):M(R,!1)})}m(c,h)};P(a,c=>{t().length&&c(o)})}m(i,l),se()}ge(["click"]);var ts=(i,e,t)=>e.onSelectExample(p(t)),ns=E('<li><button class="svelte-uqxlqe"><span class="dot svelte-uqxlqe"></span> </button></li>'),ss=E('<ul class="examples svelte-uqxlqe"></ul>');function is(i,e){ne(e,!0);let t=U(e,"examples",19,()=>[]);var n=ss();tt(n,21,t,An,(s,r)=>{var l=ns();let a;var o=f(l);o.__click=[ts,e,r];var c=w(f(o));Z(h=>{a=W(l,1,"svelte-uqxlqe",null,a,h),ae(c,` ${p(r)??""}`)},[()=>({active:e.selected==p(r)})]),m(s,l)}),m(i,n),se()}ge(["click"]);function on(){return{async:!1,baseUrl:null,breaks:!1,extensions:null,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,hooks:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1}}let We=on();function rs(i){We=i}const cn=/[&<>"']/,ls=new RegExp(cn.source,"g"),un=/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,as=new RegExp(un.source,"g"),os={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},Zt=i=>os[i];function J(i,e){if(e){if(cn.test(i))return i.replace(ls,Zt)}else if(un.test(i))return i.replace(as,Zt);return i}const cs=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig;function hn(i){return i.replace(cs,(e,t)=>(t=t.toLowerCase(),t==="colon"?":":t.charAt(0)==="#"?t.charAt(1)==="x"?String.fromCharCode(parseInt(t.substring(2),16)):String.fromCharCode(+t.substring(1)):""))}const us=/(^|[^\[])\^/g;function j(i,e){i=typeof i=="string"?i:i.source,e=e||"";const t={replace:(n,s)=>(s=s.source||s,s=s.replace(us,"$1"),i=i.replace(n,s),t),getRegex:()=>new RegExp(i,e)};return t}const hs=/[^\w:]/g,ds=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;function Ft(i,e,t){if(i){let n;try{n=decodeURIComponent(hn(t)).replace(hs,"").toLowerCase()}catch{return null}if(n.indexOf("javascript:")===0||n.indexOf("vbscript:")===0||n.indexOf("data:")===0)return null}e&&!ds.test(t)&&(t=vs(e,t));try{t=encodeURI(t).replace(/%25/g,"%")}catch{return null}return t}const ut={},gs=/^[^:]+:\/*[^/]*$/,ps=/^([^:]+:)[\s\S]*$/,fs=/^([^:]+:\/*[^/]*)[\s\S]*$/;function vs(i,e){ut[" "+i]||(gs.test(i)?ut[" "+i]=i+"/":ut[" "+i]=dt(i,"/",!0)),i=ut[" "+i];const t=i.indexOf(":")===-1;return e.substring(0,2)==="//"?t?e:i.replace(ps,"$1")+e:e.charAt(0)==="/"?t?e:i.replace(fs,"$1")+e:i+e}const gt={exec:function(){}};function Gt(i,e){const t=i.replace(/\|/g,(r,l,a)=>{let o=!1,c=l;for(;--c>=0&&a[c]==="\\";)o=!o;return o?"|":" |"}),n=t.split(/ \|/);let s=0;if(n[0].trim()||n.shift(),n.length>0&&!n[n.length-1].trim()&&n.pop(),n.length>e)n.splice(e);else for(;n.length<e;)n.push("");for(;s<n.length;s++)n[s]=n[s].trim().replace(/\\\|/g,"|");return n}function dt(i,e,t){const n=i.length;if(n===0)return"";let s=0;for(;s<n;){const r=i.charAt(n-s-1);if(r===e&&!t)s++;else if(r!==e&&t)s++;else break}return i.slice(0,n-s)}function ms(i,e){if(i.indexOf(e[1])===-1)return-1;const t=i.length;let n=0,s=0;for(;s<t;s++)if(i[s]==="\\")s++;else if(i[s]===e[0])n++;else if(i[s]===e[1]&&(n--,n<0))return s;return-1}function ks(i){i&&i.sanitize&&!i.silent&&console.warn("marked(): sanitize and sanitizer parameters are deprecated since version 0.7.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/#/USING_ADVANCED.md#options")}function Vt(i,e){if(e<1)return"";let t="";for(;e>1;)e&1&&(t+=i),e>>=1,i+=i;return t+i}function Qt(i,e,t,n){const s=e.href,r=e.title?J(e.title):null,l=i[1].replace(/\\([\[\]])/g,"$1");if(i[0].charAt(0)!=="!"){n.state.inLink=!0;const a={type:"link",raw:t,href:s,title:r,text:l,tokens:n.inlineTokens(l)};return n.state.inLink=!1,a}return{type:"image",raw:t,href:s,title:r,text:J(l)}}function bs(i,e){const t=i.match(/^(\s+)(?:```)/);if(t===null)return e;const n=t[1];return e.split(`
2
+ `).map(s=>{const r=s.match(/^\s+/);if(r===null)return s;const[l]=r;return l.length>=n.length?s.slice(n.length):s}).join(`
3
+ `)}class At{constructor(e){this.options=e||We}space(e){const t=this.rules.block.newline.exec(e);if(t&&t[0].length>0)return{type:"space",raw:t[0]}}code(e){const t=this.rules.block.code.exec(e);if(t){const n=t[0].replace(/^ {1,4}/gm,"");return{type:"code",raw:t[0],codeBlockStyle:"indented",text:this.options.pedantic?n:dt(n,`
4
+ `)}}}fences(e){const t=this.rules.block.fences.exec(e);if(t){const n=t[0],s=bs(n,t[3]||"");return{type:"code",raw:n,lang:t[2]?t[2].trim().replace(this.rules.inline._escapes,"$1"):t[2],text:s}}}heading(e){const t=this.rules.block.heading.exec(e);if(t){let n=t[2].trim();if(/#$/.test(n)){const s=dt(n,"#");(this.options.pedantic||!s||/ $/.test(s))&&(n=s.trim())}return{type:"heading",raw:t[0],depth:t[1].length,text:n,tokens:this.lexer.inline(n)}}}hr(e){const t=this.rules.block.hr.exec(e);if(t)return{type:"hr",raw:t[0]}}blockquote(e){const t=this.rules.block.blockquote.exec(e);if(t){const n=t[0].replace(/^ *>[ \t]?/gm,""),s=this.lexer.state.top;this.lexer.state.top=!0;const r=this.lexer.blockTokens(n);return this.lexer.state.top=s,{type:"blockquote",raw:t[0],tokens:r,text:n}}}list(e){let t=this.rules.block.list.exec(e);if(t){let n,s,r,l,a,o,c,h,g,d,u,x,z=t[1].trim();const T=z.length>1,C={type:"list",raw:"",ordered:T,start:T?+z.slice(0,-1):"",loose:!1,items:[]};z=T?`\\d{1,9}\\${z.slice(-1)}`:`\\${z}`,this.options.pedantic&&(z=T?z:"[*+-]");const R=new RegExp(`^( {0,3}${z})((?:[ ][^\\n]*)?(?:\\n|$))`);for(;e&&(x=!1,!(!(t=R.exec(e))||this.rules.block.hr.test(e)));){if(n=t[0],e=e.substring(n.length),h=t[2].split(`
5
+ `,1)[0].replace(/^\t+/,N=>" ".repeat(3*N.length)),g=e.split(`
6
+ `,1)[0],this.options.pedantic?(l=2,u=h.trimLeft()):(l=t[2].search(/[^ ]/),l=l>4?1:l,u=h.slice(l),l+=t[1].length),o=!1,!h&&/^ *$/.test(g)&&(n+=g+`
7
+ `,e=e.substring(g.length+1),x=!0),!x){const N=new RegExp(`^ {0,${Math.min(3,l-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),I=new RegExp(`^ {0,${Math.min(3,l-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),L=new RegExp(`^ {0,${Math.min(3,l-1)}}(?:\`\`\`|~~~)`),O=new RegExp(`^ {0,${Math.min(3,l-1)}}#`);for(;e&&(d=e.split(`
8
+ `,1)[0],g=d,this.options.pedantic&&(g=g.replace(/^ {1,4}(?=( {4})*[^ ])/g," ")),!(L.test(g)||O.test(g)||N.test(g)||I.test(e)));){if(g.search(/[^ ]/)>=l||!g.trim())u+=`
9
+ `+g.slice(l);else{if(o||h.search(/[^ ]/)>=4||L.test(h)||O.test(h)||I.test(h))break;u+=`
10
+ `+g}!o&&!g.trim()&&(o=!0),n+=d+`
11
+ `,e=e.substring(d.length+1),h=g.slice(l)}}C.loose||(c?C.loose=!0:/\n *\n *$/.test(n)&&(c=!0)),this.options.gfm&&(s=/^\[[ xX]\] /.exec(u),s&&(r=s[0]!=="[ ] ",u=u.replace(/^\[[ xX]\] +/,""))),C.items.push({type:"list_item",raw:n,task:!!s,checked:r,loose:!1,text:u}),C.raw+=n}C.items[C.items.length-1].raw=n.trimRight(),C.items[C.items.length-1].text=u.trimRight(),C.raw=C.raw.trimRight();const M=C.items.length;for(a=0;a<M;a++)if(this.lexer.state.top=!1,C.items[a].tokens=this.lexer.blockTokens(C.items[a].text,[]),!C.loose){const N=C.items[a].tokens.filter(L=>L.type==="space"),I=N.length>0&&N.some(L=>/\n.*\n/.test(L.raw));C.loose=I}if(C.loose)for(a=0;a<M;a++)C.items[a].loose=!0;return C}}html(e){const t=this.rules.block.html.exec(e);if(t){const n={type:"html",raw:t[0],pre:!this.options.sanitizer&&(t[1]==="pre"||t[1]==="script"||t[1]==="style"),text:t[0]};if(this.options.sanitize){const s=this.options.sanitizer?this.options.sanitizer(t[0]):J(t[0]);n.type="paragraph",n.text=s,n.tokens=this.lexer.inline(s)}return n}}def(e){const t=this.rules.block.def.exec(e);if(t){const n=t[1].toLowerCase().replace(/\s+/g," "),s=t[2]?t[2].replace(/^<(.*)>$/,"$1").replace(this.rules.inline._escapes,"$1"):"",r=t[3]?t[3].substring(1,t[3].length-1).replace(this.rules.inline._escapes,"$1"):t[3];return{type:"def",tag:n,raw:t[0],href:s,title:r}}}table(e){const t=this.rules.block.table.exec(e);if(t){const n={type:"table",header:Gt(t[1]).map(s=>({text:s})),align:t[2].replace(/^ *|\| *$/g,"").split(/ *\| */),rows:t[3]&&t[3].trim()?t[3].replace(/\n[ \t]*$/,"").split(`
12
+ `):[]};if(n.header.length===n.align.length){n.raw=t[0];let s=n.align.length,r,l,a,o;for(r=0;r<s;r++)/^ *-+: *$/.test(n.align[r])?n.align[r]="right":/^ *:-+: *$/.test(n.align[r])?n.align[r]="center":/^ *:-+ *$/.test(n.align[r])?n.align[r]="left":n.align[r]=null;for(s=n.rows.length,r=0;r<s;r++)n.rows[r]=Gt(n.rows[r],n.header.length).map(c=>({text:c}));for(s=n.header.length,l=0;l<s;l++)n.header[l].tokens=this.lexer.inline(n.header[l].text);for(s=n.rows.length,l=0;l<s;l++)for(o=n.rows[l],a=0;a<o.length;a++)o[a].tokens=this.lexer.inline(o[a].text);return n}}}lheading(e){const t=this.rules.block.lheading.exec(e);if(t)return{type:"heading",raw:t[0],depth:t[2].charAt(0)==="="?1:2,text:t[1],tokens:this.lexer.inline(t[1])}}paragraph(e){const t=this.rules.block.paragraph.exec(e);if(t){const n=t[1].charAt(t[1].length-1)===`
13
+ `?t[1].slice(0,-1):t[1];return{type:"paragraph",raw:t[0],text:n,tokens:this.lexer.inline(n)}}}text(e){const t=this.rules.block.text.exec(e);if(t)return{type:"text",raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(e){const t=this.rules.inline.escape.exec(e);if(t)return{type:"escape",raw:t[0],text:J(t[1])}}tag(e){const t=this.rules.inline.tag.exec(e);if(t)return!this.lexer.state.inLink&&/^<a /i.test(t[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&/^<\/a>/i.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&/^<(pre|code|kbd|script)(\s|>)/i.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:this.options.sanitize?"text":"html",raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(t[0]):J(t[0]):t[0]}}link(e){const t=this.rules.inline.link.exec(e);if(t){const n=t[2].trim();if(!this.options.pedantic&&/^</.test(n)){if(!/>$/.test(n))return;const l=dt(n.slice(0,-1),"\\");if((n.length-l.length)%2===0)return}else{const l=ms(t[2],"()");if(l>-1){const o=(t[0].indexOf("!")===0?5:4)+t[1].length+l;t[2]=t[2].substring(0,l),t[0]=t[0].substring(0,o).trim(),t[3]=""}}let s=t[2],r="";if(this.options.pedantic){const l=/^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(s);l&&(s=l[1],r=l[3])}else r=t[3]?t[3].slice(1,-1):"";return s=s.trim(),/^</.test(s)&&(this.options.pedantic&&!/>$/.test(n)?s=s.slice(1):s=s.slice(1,-1)),Qt(t,{href:s&&s.replace(this.rules.inline._escapes,"$1"),title:r&&r.replace(this.rules.inline._escapes,"$1")},t[0],this.lexer)}}reflink(e,t){let n;if((n=this.rules.inline.reflink.exec(e))||(n=this.rules.inline.nolink.exec(e))){let s=(n[2]||n[1]).replace(/\s+/g," ");if(s=t[s.toLowerCase()],!s){const r=n[0].charAt(0);return{type:"text",raw:r,text:r}}return Qt(n,s,n[0],this.lexer)}}emStrong(e,t,n=""){let s=this.rules.inline.emStrong.lDelim.exec(e);if(!s||s[3]&&n.match(/[\p{L}\p{N}]/u))return;const r=s[1]||s[2]||"";if(!r||r&&(n===""||this.rules.inline.punctuation.exec(n))){const l=s[0].length-1;let a,o,c=l,h=0;const g=s[0][0]==="*"?this.rules.inline.emStrong.rDelimAst:this.rules.inline.emStrong.rDelimUnd;for(g.lastIndex=0,t=t.slice(-1*e.length+l);(s=g.exec(t))!=null;){if(a=s[1]||s[2]||s[3]||s[4]||s[5]||s[6],!a)continue;if(o=a.length,s[3]||s[4]){c+=o;continue}else if((s[5]||s[6])&&l%3&&!((l+o)%3)){h+=o;continue}if(c-=o,c>0)continue;o=Math.min(o,o+c+h);const d=e.slice(0,l+s.index+(s[0].length-a.length)+o);if(Math.min(l,o)%2){const x=d.slice(1,-1);return{type:"em",raw:d,text:x,tokens:this.lexer.inlineTokens(x)}}const u=d.slice(2,-2);return{type:"strong",raw:d,text:u,tokens:this.lexer.inlineTokens(u)}}}}codespan(e){const t=this.rules.inline.code.exec(e);if(t){let n=t[2].replace(/\n/g," ");const s=/[^ ]/.test(n),r=/^ /.test(n)&&/ $/.test(n);return s&&r&&(n=n.substring(1,n.length-1)),n=J(n,!0),{type:"codespan",raw:t[0],text:n}}}br(e){const t=this.rules.inline.br.exec(e);if(t)return{type:"br",raw:t[0]}}del(e){const t=this.rules.inline.del.exec(e);if(t)return{type:"del",raw:t[0],text:t[2],tokens:this.lexer.inlineTokens(t[2])}}autolink(e,t){const n=this.rules.inline.autolink.exec(e);if(n){let s,r;return n[2]==="@"?(s=J(this.options.mangle?t(n[1]):n[1]),r="mailto:"+s):(s=J(n[1]),r=s),{type:"link",raw:n[0],text:s,href:r,tokens:[{type:"text",raw:s,text:s}]}}}url(e,t){let n;if(n=this.rules.inline.url.exec(e)){let s,r;if(n[2]==="@")s=J(this.options.mangle?t(n[0]):n[0]),r="mailto:"+s;else{let l;do l=n[0],n[0]=this.rules.inline._backpedal.exec(n[0])[0];while(l!==n[0]);s=J(n[0]),n[1]==="www."?r="http://"+n[0]:r=n[0]}return{type:"link",raw:n[0],text:s,href:r,tokens:[{type:"text",raw:s,text:s}]}}}inlineText(e,t){const n=this.rules.inline.text.exec(e);if(n){let s;return this.lexer.state.inRawBlock?s=this.options.sanitize?this.options.sanitizer?this.options.sanitizer(n[0]):J(n[0]):n[0]:s=J(this.options.smartypants?t(n[0]):n[0]),{type:"text",raw:n[0],text:s}}}}const k={newline:/^(?: *(?:\n|$))+/,code:/^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/,fences:/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,hr:/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,heading:/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/,html:"^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))",def:/^ {0,3}\[(label)\]: *(?:\n *)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/,table:gt,lheading:/^((?:.|\n(?!\n))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,_paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,text:/^[^\n]+/};k._label=/(?!\s*\])(?:\\.|[^\[\]\\])+/;k._title=/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/;k.def=j(k.def).replace("label",k._label).replace("title",k._title).getRegex();k.bullet=/(?:[*+-]|\d{1,9}[.)])/;k.listItemStart=j(/^( *)(bull) */).replace("bull",k.bullet).getRegex();k.list=j(k.list).replace(/bull/g,k.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+k.def.source+")").getRegex();k._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul";k._comment=/<!--(?!-?>)[\s\S]*?(?:-->|$)/;k.html=j(k.html,"i").replace("comment",k._comment).replace("tag",k._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex();k.paragraph=j(k._paragraph).replace("hr",k.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",k._tag).getRegex();k.blockquote=j(k.blockquote).replace("paragraph",k.paragraph).getRegex();k.normal={...k};k.gfm={...k.normal,table:"^ *([^\\n ].*\\|.*)\\n {0,3}(?:\\| *)?(:?-+:? *(?:\\| *:?-+:? *)*)(?:\\| *)?(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)"};k.gfm.table=j(k.gfm.table).replace("hr",k.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",k._tag).getRegex();k.gfm.paragraph=j(k._paragraph).replace("hr",k.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("table",k.gfm.table).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",k._tag).getRegex();k.pedantic={...k.normal,html:j(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",k._comment).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:gt,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:j(k.normal._paragraph).replace("hr",k.hr).replace("heading",` *#{1,6} *[^
14
+ ]`).replace("lheading",k.lheading).replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").getRegex()};const v={escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,autolink:/^<(scheme:[^\s\x00-\x1f<>]*|email)>/,url:gt,tag:"^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>",link:/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/,reflink:/^!?\[(label)\]\[(ref)\]/,nolink:/^!?\[(ref)\](?:\[\])?/,reflinkSearch:"reflink|nolink(?!\\()",emStrong:{lDelim:/^(?:\*+(?:([punct_])|[^\s*]))|^_+(?:([punct*])|([^\s_]))/,rDelimAst:/^(?:[^_*\\]|\\.)*?\_\_(?:[^_*\\]|\\.)*?\*(?:[^_*\\]|\\.)*?(?=\_\_)|(?:[^*\\]|\\.)+(?=[^*])|[punct_](\*+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\*+)(?=[punct_\s]|$)|[punct_\s](\*+)(?=[^punct*_\s])|[\s](\*+)(?=[punct_])|[punct_](\*+)(?=[punct_])|(?:[^punct*_\s\\]|\\.)(\*+)(?=[^punct*_\s])/,rDelimUnd:/^(?:[^_*\\]|\\.)*?\*\*(?:[^_*\\]|\\.)*?\_(?:[^_*\\]|\\.)*?(?=\*\*)|(?:[^_\\]|\\.)+(?=[^_])|[punct*](\_+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\_+)(?=[punct*\s]|$)|[punct*\s](\_+)(?=[^punct*_\s])|[\s](\_+)(?=[punct*])|[punct*](\_+)(?=[punct*])/},code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,br:/^( {2,}|\\)\n(?!\s*$)/,del:gt,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,punctuation:/^([\spunctuation])/};v._punctuation="!\"#$%&'()+\\-.,/:;<=>?@\\[\\]`^{|}~";v.punctuation=j(v.punctuation).replace(/punctuation/g,v._punctuation).getRegex();v.blockSkip=/\[[^\]]*?\]\([^\)]*?\)|`[^`]*?`|<[^>]*?>/g;v.escapedEmSt=/(?:^|[^\\])(?:\\\\)*\\[*_]/g;v._comment=j(k._comment).replace("(?:-->|$)","-->").getRegex();v.emStrong.lDelim=j(v.emStrong.lDelim).replace(/punct/g,v._punctuation).getRegex();v.emStrong.rDelimAst=j(v.emStrong.rDelimAst,"g").replace(/punct/g,v._punctuation).getRegex();v.emStrong.rDelimUnd=j(v.emStrong.rDelimUnd,"g").replace(/punct/g,v._punctuation).getRegex();v._escapes=/\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/g;v._scheme=/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/;v._email=/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/;v.autolink=j(v.autolink).replace("scheme",v._scheme).replace("email",v._email).getRegex();v._attribute=/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/;v.tag=j(v.tag).replace("comment",v._comment).replace("attribute",v._attribute).getRegex();v._label=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/;v._href=/<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/;v._title=/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/;v.link=j(v.link).replace("label",v._label).replace("href",v._href).replace("title",v._title).getRegex();v.reflink=j(v.reflink).replace("label",v._label).replace("ref",k._label).getRegex();v.nolink=j(v.nolink).replace("ref",k._label).getRegex();v.reflinkSearch=j(v.reflinkSearch,"g").replace("reflink",v.reflink).replace("nolink",v.nolink).getRegex();v.normal={...v};v.pedantic={...v.normal,strong:{start:/^__|\*\*/,middle:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,endAst:/\*\*(?!\*)/g,endUnd:/__(?!_)/g},em:{start:/^_|\*/,middle:/^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/,endAst:/\*(?!\*)/g,endUnd:/_(?!_)/g},link:j(/^!?\[(label)\]\((.*?)\)/).replace("label",v._label).getRegex(),reflink:j(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",v._label).getRegex()};v.gfm={...v.normal,escape:j(v.escape).replace("])","~|])").getRegex(),_extended_email:/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,url:/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/};v.gfm.url=j(v.gfm.url,"i").replace("email",v.gfm._extended_email).getRegex();v.breaks={...v.gfm,br:j(v.br).replace("{2,}","*").getRegex(),text:j(v.gfm.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()};function ws(i){return i.replace(/---/g,"—").replace(/--/g,"–").replace(/(^|[-\u2014/(\[{"\s])'/g,"$1‘").replace(/'/g,"’").replace(/(^|[-\u2014/(\[{\u2018\s])"/g,"$1“").replace(/"/g,"”").replace(/\.{3}/g,"…")}function Xt(i){let e="",t,n;const s=i.length;for(t=0;t<s;t++)n=i.charCodeAt(t),Math.random()>.5&&(n="x"+n.toString(16)),e+="&#"+n+";";return e}class Le{constructor(e){this.tokens=[],this.tokens.links=Object.create(null),this.options=e||We,this.options.tokenizer=this.options.tokenizer||new At,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};const t={block:k.normal,inline:v.normal};this.options.pedantic?(t.block=k.pedantic,t.inline=v.pedantic):this.options.gfm&&(t.block=k.gfm,this.options.breaks?t.inline=v.breaks:t.inline=v.gfm),this.tokenizer.rules=t}static get rules(){return{block:k,inline:v}}static lex(e,t){return new Le(t).lex(e)}static lexInline(e,t){return new Le(t).inlineTokens(e)}lex(e){e=e.replace(/\r\n|\r/g,`
15
+ `),this.blockTokens(e,this.tokens);let t;for(;t=this.inlineQueue.shift();)this.inlineTokens(t.src,t.tokens);return this.tokens}blockTokens(e,t=[]){this.options.pedantic?e=e.replace(/\t/g," ").replace(/^ +$/gm,""):e=e.replace(/^( *)(\t+)/gm,(a,o,c)=>o+" ".repeat(c.length));let n,s,r,l;for(;e;)if(!(this.options.extensions&&this.options.extensions.block&&this.options.extensions.block.some(a=>(n=a.call({lexer:this},e,t))?(e=e.substring(n.raw.length),t.push(n),!0):!1))){if(n=this.tokenizer.space(e)){e=e.substring(n.raw.length),n.raw.length===1&&t.length>0?t[t.length-1].raw+=`
16
+ `:t.push(n);continue}if(n=this.tokenizer.code(e)){e=e.substring(n.raw.length),s=t[t.length-1],s&&(s.type==="paragraph"||s.type==="text")?(s.raw+=`
17
+ `+n.raw,s.text+=`
18
+ `+n.text,this.inlineQueue[this.inlineQueue.length-1].src=s.text):t.push(n);continue}if(n=this.tokenizer.fences(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.heading(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.hr(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.blockquote(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.list(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.html(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.def(e)){e=e.substring(n.raw.length),s=t[t.length-1],s&&(s.type==="paragraph"||s.type==="text")?(s.raw+=`
19
+ `+n.raw,s.text+=`
20
+ `+n.raw,this.inlineQueue[this.inlineQueue.length-1].src=s.text):this.tokens.links[n.tag]||(this.tokens.links[n.tag]={href:n.href,title:n.title});continue}if(n=this.tokenizer.table(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.lheading(e)){e=e.substring(n.raw.length),t.push(n);continue}if(r=e,this.options.extensions&&this.options.extensions.startBlock){let a=1/0;const o=e.slice(1);let c;this.options.extensions.startBlock.forEach(function(h){c=h.call({lexer:this},o),typeof c=="number"&&c>=0&&(a=Math.min(a,c))}),a<1/0&&a>=0&&(r=e.substring(0,a+1))}if(this.state.top&&(n=this.tokenizer.paragraph(r))){s=t[t.length-1],l&&s.type==="paragraph"?(s.raw+=`
21
+ `+n.raw,s.text+=`
22
+ `+n.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=s.text):t.push(n),l=r.length!==e.length,e=e.substring(n.raw.length);continue}if(n=this.tokenizer.text(e)){e=e.substring(n.raw.length),s=t[t.length-1],s&&s.type==="text"?(s.raw+=`
23
+ `+n.raw,s.text+=`
24
+ `+n.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=s.text):t.push(n);continue}if(e){const a="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(a);break}else throw new Error(a)}}return this.state.top=!0,t}inline(e,t=[]){return this.inlineQueue.push({src:e,tokens:t}),t}inlineTokens(e,t=[]){let n,s,r,l=e,a,o,c;if(this.tokens.links){const h=Object.keys(this.tokens.links);if(h.length>0)for(;(a=this.tokenizer.rules.inline.reflinkSearch.exec(l))!=null;)h.includes(a[0].slice(a[0].lastIndexOf("[")+1,-1))&&(l=l.slice(0,a.index)+"["+Vt("a",a[0].length-2)+"]"+l.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(a=this.tokenizer.rules.inline.blockSkip.exec(l))!=null;)l=l.slice(0,a.index)+"["+Vt("a",a[0].length-2)+"]"+l.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;(a=this.tokenizer.rules.inline.escapedEmSt.exec(l))!=null;)l=l.slice(0,a.index+a[0].length-2)+"++"+l.slice(this.tokenizer.rules.inline.escapedEmSt.lastIndex),this.tokenizer.rules.inline.escapedEmSt.lastIndex--;for(;e;)if(o||(c=""),o=!1,!(this.options.extensions&&this.options.extensions.inline&&this.options.extensions.inline.some(h=>(n=h.call({lexer:this},e,t))?(e=e.substring(n.raw.length),t.push(n),!0):!1))){if(n=this.tokenizer.escape(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.tag(e)){e=e.substring(n.raw.length),s=t[t.length-1],s&&n.type==="text"&&s.type==="text"?(s.raw+=n.raw,s.text+=n.text):t.push(n);continue}if(n=this.tokenizer.link(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(n.raw.length),s=t[t.length-1],s&&n.type==="text"&&s.type==="text"?(s.raw+=n.raw,s.text+=n.text):t.push(n);continue}if(n=this.tokenizer.emStrong(e,l,c)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.codespan(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.br(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.del(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.autolink(e,Xt)){e=e.substring(n.raw.length),t.push(n);continue}if(!this.state.inLink&&(n=this.tokenizer.url(e,Xt))){e=e.substring(n.raw.length),t.push(n);continue}if(r=e,this.options.extensions&&this.options.extensions.startInline){let h=1/0;const g=e.slice(1);let d;this.options.extensions.startInline.forEach(function(u){d=u.call({lexer:this},g),typeof d=="number"&&d>=0&&(h=Math.min(h,d))}),h<1/0&&h>=0&&(r=e.substring(0,h+1))}if(n=this.tokenizer.inlineText(r,ws)){e=e.substring(n.raw.length),n.raw.slice(-1)!=="_"&&(c=n.raw.slice(-1)),o=!0,s=t[t.length-1],s&&s.type==="text"?(s.raw+=n.raw,s.text+=n.text):t.push(n);continue}if(e){const h="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(h);break}else throw new Error(h)}}return t}}class jt{constructor(e){this.options=e||We}code(e,t,n){const s=(t||"").match(/\S*/)[0];if(this.options.highlight){const r=this.options.highlight(e,s);r!=null&&r!==e&&(n=!0,e=r)}return e=e.replace(/\n$/,"")+`
25
+ `,s?'<pre><code class="'+this.options.langPrefix+J(s)+'">'+(n?e:J(e,!0))+`</code></pre>
26
+ `:"<pre><code>"+(n?e:J(e,!0))+`</code></pre>
27
+ `}blockquote(e){return`<blockquote>
28
+ ${e}</blockquote>
29
+ `}html(e){return e}heading(e,t,n,s){if(this.options.headerIds){const r=this.options.headerPrefix+s.slug(n);return`<h${t} id="${r}">${e}</h${t}>
30
+ `}return`<h${t}>${e}</h${t}>
31
+ `}hr(){return this.options.xhtml?`<hr/>
32
+ `:`<hr>
33
+ `}list(e,t,n){const s=t?"ol":"ul",r=t&&n!==1?' start="'+n+'"':"";return"<"+s+r+`>
34
+ `+e+"</"+s+`>
35
+ `}listitem(e){return`<li>${e}</li>
36
+ `}checkbox(e){return"<input "+(e?'checked="" ':"")+'disabled="" type="checkbox"'+(this.options.xhtml?" /":"")+"> "}paragraph(e){return`<p>${e}</p>
37
+ `}table(e,t){return t&&(t=`<tbody>${t}</tbody>`),`<table>
38
+ <thead>
39
+ `+e+`</thead>
40
+ `+t+`</table>
41
+ `}tablerow(e){return`<tr>
42
+ ${e}</tr>
43
+ `}tablecell(e,t){const n=t.header?"th":"td";return(t.align?`<${n} align="${t.align}">`:`<${n}>`)+e+`</${n}>
44
+ `}strong(e){return`<strong>${e}</strong>`}em(e){return`<em>${e}</em>`}codespan(e){return`<code>${e}</code>`}br(){return this.options.xhtml?"<br/>":"<br>"}del(e){return`<del>${e}</del>`}link(e,t,n){if(e=Ft(this.options.sanitize,this.options.baseUrl,e),e===null)return n;let s='<a href="'+e+'"';return t&&(s+=' title="'+t+'"'),s+=">"+n+"</a>",s}image(e,t,n){if(e=Ft(this.options.sanitize,this.options.baseUrl,e),e===null)return n;let s=`<img src="${e}" alt="${n}"`;return t&&(s+=` title="${t}"`),s+=this.options.xhtml?"/>":">",s}text(e){return e}}class dn{strong(e){return e}em(e){return e}codespan(e){return e}del(e){return e}html(e){return e}text(e){return e}link(e,t,n){return""+n}image(e,t,n){return""+n}br(){return""}}class gn{constructor(){this.seen={}}serialize(e){return e.toLowerCase().trim().replace(/<[!\/a-z].*?>/ig,"").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g,"").replace(/\s/g,"-")}getNextSafeSlug(e,t){let n=e,s=0;if(this.seen.hasOwnProperty(n)){s=this.seen[e];do s++,n=e+"-"+s;while(this.seen.hasOwnProperty(n))}return t||(this.seen[e]=s,this.seen[n]=0),n}slug(e,t={}){const n=this.serialize(e);return this.getNextSafeSlug(n,t.dryrun)}}class He{constructor(e){this.options=e||We,this.options.renderer=this.options.renderer||new jt,this.renderer=this.options.renderer,this.renderer.options=this.options,this.textRenderer=new dn,this.slugger=new gn}static parse(e,t){return new He(t).parse(e)}static parseInline(e,t){return new He(t).parseInline(e)}parse(e,t=!0){let n="",s,r,l,a,o,c,h,g,d,u,x,z,T,C,R,M,N,I,L;const O=e.length;for(s=0;s<O;s++){if(u=e[s],this.options.extensions&&this.options.extensions.renderers&&this.options.extensions.renderers[u.type]&&(L=this.options.extensions.renderers[u.type].call({parser:this},u),L!==!1||!["space","hr","heading","code","table","blockquote","list","html","paragraph","text"].includes(u.type))){n+=L||"";continue}switch(u.type){case"space":continue;case"hr":{n+=this.renderer.hr();continue}case"heading":{n+=this.renderer.heading(this.parseInline(u.tokens),u.depth,hn(this.parseInline(u.tokens,this.textRenderer)),this.slugger);continue}case"code":{n+=this.renderer.code(u.text,u.lang,u.escaped);continue}case"table":{for(g="",h="",a=u.header.length,r=0;r<a;r++)h+=this.renderer.tablecell(this.parseInline(u.header[r].tokens),{header:!0,align:u.align[r]});for(g+=this.renderer.tablerow(h),d="",a=u.rows.length,r=0;r<a;r++){for(c=u.rows[r],h="",o=c.length,l=0;l<o;l++)h+=this.renderer.tablecell(this.parseInline(c[l].tokens),{header:!1,align:u.align[l]});d+=this.renderer.tablerow(h)}n+=this.renderer.table(g,d);continue}case"blockquote":{d=this.parse(u.tokens),n+=this.renderer.blockquote(d);continue}case"list":{for(x=u.ordered,z=u.start,T=u.loose,a=u.items.length,d="",r=0;r<a;r++)R=u.items[r],M=R.checked,N=R.task,C="",R.task&&(I=this.renderer.checkbox(M),T?R.tokens.length>0&&R.tokens[0].type==="paragraph"?(R.tokens[0].text=I+" "+R.tokens[0].text,R.tokens[0].tokens&&R.tokens[0].tokens.length>0&&R.tokens[0].tokens[0].type==="text"&&(R.tokens[0].tokens[0].text=I+" "+R.tokens[0].tokens[0].text)):R.tokens.unshift({type:"text",text:I}):C+=I),C+=this.parse(R.tokens,T),d+=this.renderer.listitem(C,N,M);n+=this.renderer.list(d,x,z);continue}case"html":{n+=this.renderer.html(u.text);continue}case"paragraph":{n+=this.renderer.paragraph(this.parseInline(u.tokens));continue}case"text":{for(d=u.tokens?this.parseInline(u.tokens):u.text;s+1<O&&e[s+1].type==="text";)u=e[++s],d+=`
45
+ `+(u.tokens?this.parseInline(u.tokens):u.text);n+=t?this.renderer.paragraph(d):d;continue}default:{const F='Token with "'+u.type+'" type was not found.';if(this.options.silent){console.error(F);return}else throw new Error(F)}}}return n}parseInline(e,t){t=t||this.renderer;let n="",s,r,l;const a=e.length;for(s=0;s<a;s++){if(r=e[s],this.options.extensions&&this.options.extensions.renderers&&this.options.extensions.renderers[r.type]&&(l=this.options.extensions.renderers[r.type].call({parser:this},r),l!==!1||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(r.type))){n+=l||"";continue}switch(r.type){case"escape":{n+=t.text(r.text);break}case"html":{n+=t.html(r.text);break}case"link":{n+=t.link(r.href,r.title,this.parseInline(r.tokens,t));break}case"image":{n+=t.image(r.href,r.title,r.text);break}case"strong":{n+=t.strong(this.parseInline(r.tokens,t));break}case"em":{n+=t.em(this.parseInline(r.tokens,t));break}case"codespan":{n+=t.codespan(r.text);break}case"br":{n+=t.br();break}case"del":{n+=t.del(this.parseInline(r.tokens,t));break}case"text":{n+=t.text(r.text);break}default:{const o='Token with "'+r.type+'" type was not found.';if(this.options.silent){console.error(o);return}else throw new Error(o)}}}return n}}class St{constructor(e){this.options=e||We}static passThroughHooks=new Set(["preprocess","postprocess"]);preprocess(e){return e}postprocess(e){return e}}function xs(i,e,t){return n=>{if(n.message+=`
46
+ Please report this to https://github.com/markedjs/marked.`,i){const s="<p>An error occurred:</p><pre>"+J(n.message+"",!0)+"</pre>";if(e)return Promise.resolve(s);if(t){t(null,s);return}return s}if(e)return Promise.reject(n);if(t){t(n);return}throw n}}function pn(i,e){return(t,n,s)=>{typeof n=="function"&&(s=n,n=null);const r={...n};n={...b.defaults,...r};const l=xs(n.silent,n.async,s);if(typeof t>"u"||t===null)return l(new Error("marked(): input parameter is undefined or null"));if(typeof t!="string")return l(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(t)+", string expected"));if(ks(n),n.hooks&&(n.hooks.options=n),s){const a=n.highlight;let o;try{n.hooks&&(t=n.hooks.preprocess(t)),o=i(t,n)}catch(g){return l(g)}const c=function(g){let d;if(!g)try{n.walkTokens&&b.walkTokens(o,n.walkTokens),d=e(o,n),n.hooks&&(d=n.hooks.postprocess(d))}catch(u){g=u}return n.highlight=a,g?l(g):s(null,d)};if(!a||a.length<3||(delete n.highlight,!o.length))return c();let h=0;b.walkTokens(o,function(g){g.type==="code"&&(h++,setTimeout(()=>{a(g.text,g.lang,function(d,u){if(d)return c(d);u!=null&&u!==g.text&&(g.text=u,g.escaped=!0),h--,h===0&&c()})},0))}),h===0&&c();return}if(n.async)return Promise.resolve(n.hooks?n.hooks.preprocess(t):t).then(a=>i(a,n)).then(a=>n.walkTokens?Promise.all(b.walkTokens(a,n.walkTokens)).then(()=>a):a).then(a=>e(a,n)).then(a=>n.hooks?n.hooks.postprocess(a):a).catch(l);try{n.hooks&&(t=n.hooks.preprocess(t));const a=i(t,n);n.walkTokens&&b.walkTokens(a,n.walkTokens);let o=e(a,n);return n.hooks&&(o=n.hooks.postprocess(o)),o}catch(a){return l(a)}}}function b(i,e,t){return pn(Le.lex,He.parse)(i,e,t)}b.options=b.setOptions=function(i){return b.defaults={...b.defaults,...i},rs(b.defaults),b};b.getDefaults=on;b.defaults=We;b.use=function(...i){const e=b.defaults.extensions||{renderers:{},childTokens:{}};i.forEach(t=>{const n={...t};if(n.async=b.defaults.async||n.async||!1,t.extensions&&(t.extensions.forEach(s=>{if(!s.name)throw new Error("extension name required");if(s.renderer){const r=e.renderers[s.name];r?e.renderers[s.name]=function(...l){let a=s.renderer.apply(this,l);return a===!1&&(a=r.apply(this,l)),a}:e.renderers[s.name]=s.renderer}if(s.tokenizer){if(!s.level||s.level!=="block"&&s.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");e[s.level]?e[s.level].unshift(s.tokenizer):e[s.level]=[s.tokenizer],s.start&&(s.level==="block"?e.startBlock?e.startBlock.push(s.start):e.startBlock=[s.start]:s.level==="inline"&&(e.startInline?e.startInline.push(s.start):e.startInline=[s.start]))}s.childTokens&&(e.childTokens[s.name]=s.childTokens)}),n.extensions=e),t.renderer){const s=b.defaults.renderer||new jt;for(const r in t.renderer){const l=s[r];s[r]=(...a)=>{let o=t.renderer[r].apply(s,a);return o===!1&&(o=l.apply(s,a)),o}}n.renderer=s}if(t.tokenizer){const s=b.defaults.tokenizer||new At;for(const r in t.tokenizer){const l=s[r];s[r]=(...a)=>{let o=t.tokenizer[r].apply(s,a);return o===!1&&(o=l.apply(s,a)),o}}n.tokenizer=s}if(t.hooks){const s=b.defaults.hooks||new St;for(const r in t.hooks){const l=s[r];St.passThroughHooks.has(r)?s[r]=a=>{if(b.defaults.async)return Promise.resolve(t.hooks[r].call(s,a)).then(c=>l.call(s,c));const o=t.hooks[r].call(s,a);return l.call(s,o)}:s[r]=(...a)=>{let o=t.hooks[r].apply(s,a);return o===!1&&(o=l.apply(s,a)),o}}n.hooks=s}if(t.walkTokens){const s=b.defaults.walkTokens;n.walkTokens=function(r){let l=[];return l.push(t.walkTokens.call(this,r)),s&&(l=l.concat(s.call(this,r))),l}}b.setOptions(n)})};b.walkTokens=function(i,e){let t=[];for(const n of i)switch(t=t.concat(e.call(b,n)),n.type){case"table":{for(const s of n.header)t=t.concat(b.walkTokens(s.tokens,e));for(const s of n.rows)for(const r of s)t=t.concat(b.walkTokens(r.tokens,e));break}case"list":{t=t.concat(b.walkTokens(n.items,e));break}default:b.defaults.extensions&&b.defaults.extensions.childTokens&&b.defaults.extensions.childTokens[n.type]?b.defaults.extensions.childTokens[n.type].forEach(function(s){t=t.concat(b.walkTokens(n[s],e))}):n.tokens&&(t=t.concat(b.walkTokens(n.tokens,e)))}return t};b.parseInline=pn(Le.lexInline,He.parseInline);b.Parser=He;b.parser=He.parse;b.Renderer=jt;b.TextRenderer=dn;b.Lexer=Le;b.lexer=Le.lex;b.Tokenizer=At;b.Slugger=gn;b.Hooks=St;b.parse=b;b.options;b.setOptions;b.use;b.walkTokens;b.parseInline;He.parse;Le.lex;const _s="modulepreload",ys=function(i){return"/"+i},Kt={},fn=function(e,t,n){let s=Promise.resolve();if(t&&t.length>0){let o=function(c){return Promise.all(c.map(h=>Promise.resolve(h).then(g=>({status:"fulfilled",value:g}),g=>({status:"rejected",reason:g}))))};document.getElementsByTagName("link");const l=document.querySelector("meta[property=csp-nonce]"),a=l?.nonce||l?.getAttribute("nonce");s=o(t.map(c=>{if(c=ys(c),c in Kt)return;Kt[c]=!0;const h=c.endsWith(".css"),g=h?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${c}"]${g}`))return;const d=document.createElement("link");if(d.rel=h?"stylesheet":_s,h||(d.as="script"),d.crossOrigin="",d.href=c,a&&d.setAttribute("nonce",a),document.head.appendChild(d),h)return new Promise((u,x)=>{d.addEventListener("load",u),d.addEventListener("error",()=>x(new Error(`Unable to preload CSS for ${c}`)))})}))}function r(l){const a=new Event("vite:preloadError",{cancelable:!0});if(a.payload=l,window.dispatchEvent(a),!a.defaultPrevented)throw l}return s.then(l=>{for(const a of l||[])a.status==="rejected"&&r(a.reason);return e().catch(r)})},vn=async i=>{try{(await fn(async()=>{const{default:t}=await import("./index-eUfJTxoU.js");return{default:t}},[])).default.highlightElement(i)}catch(e){console.error("Could not load highlight.js",e)}};var Ss=E('<div class="markdown-body"><!></div>');function zs(i,e){ne(e,!0);let t=oe(void 0);le(()=>{e.das&&p(t)&&setTimeout(()=>{p(t)&&Array.from(p(t).querySelectorAll("pre code")).forEach(r=>{vn(r)})},200)});var n=Ss(),s=f(n);Bt(s,()=>b(e.das.descriptionfile||e.das.description)),et(n,r=>te(t,r),()=>p(t)),m(i,n),se()}var Ts=E('<pre><code class="language-xml"> </code></pre>'),Cs=E("<div><!> <!></div>");function Es(i,e){ne(e,!0);let t=oe(void 0),n=oe(void 0),s=oe(ln([]));e.devmodus||r();async function r(){const d=await fn(()=>import("../raw_component_import_map.js"),[]);te(s,d.rawComponentMap,!0)}function l(d,u){te(t,null),setTimeout(()=>{te(t,u[d],!0)})}le(()=>{l(e.componentName,p(s))}),le(()=>{p(t)&&p(n)&&vn(p(n))});var a=Cs(),o=f(a);{var c=d=>{var u=an("Running Gardenjs in devmodus. No Code view supported.");m(d,u)};P(o,d=>{e.devmodus&&d(c)})}var h=w(o,2);{var g=d=>{var u=Ts(),x=f(u),z=f(x);et(x,T=>te(n,T),()=>p(n)),Z(()=>ae(z,p(t))),m(d,u)};P(h,d=>{p(t)&&d(g)})}m(i,a),se()}var Ms=E('<iframe class="stage_iframe svelte-17n05ij" title="preview" src="/frame.html"></iframe>'),Rs=E('<div class="panel svelte-17n05ij"><!></div>');function Is(i,e){ne(e,!0);let t=U(e,"das",19,()=>({})),n=oe(void 0),s=oe(void 0);const r=new ResizeObserver(c=>{c.forEach(h=>{e.onUpdateStageRect(h.contentRect)})});sn(()=>{p(s)&&(r.observe(p(s)),p(s).contentWindow.onload=()=>{te(n,!0)},p(s).contentWindow.addEventListener("mousemove",function(c){var h=p(s).getBoundingClientRect(),g=new CustomEvent("mousemove",{bubbles:!0,cancelable:!1});g.pageX=c.clientX+h.left,g.pageY=c.clientY+h.top,p(s).dispatchEvent(g)}),p(s).contentWindow.addEventListener("mouseup",function(){var c=new CustomEvent("mouseup",{bubbles:!0,cancelable:!1});p(s).dispatchEvent(c)}))}),rn(()=>{r.disconnect()});function l(c){const h=[];return c.description&&h.push({name:"Notes",props:{das:c},page:zs}),c.examples?.length&&h.push({name:"Examples",props:{selected:e.selectedExample,examples:c.examples.map(g=>g.title),onSelectExample:a},page:is}),!e.devmodus&&c.componentfile&&h.push({name:"Code",props:{componentName:e.componentName,devmodus:e.devmodus},page:Es}),h}function a(c){globalThis.history.pushState({selectedExample:c},"",window.location.pathname.substring(7))}le(()=>{p(n)&&(!p(s).contentDocument||/frame.html$/.test(p(s).contentWindow.location),p(s).contentWindow.postMessage({selectedExample:e.selectedExample,componentName:e.componentName,stageSize:e.stageSize,theme:e.theme,appTheme:e.appTheme,showInspector:e.showInspector,showGrid:e.showGrid,gridSettings:e.gridSettings},window.location))});const o=re(()=>l(t()));Gn(i,{get topHeight(){return e.stageContainerHeight},get maxHeight(){return e.stageContainerMaxHeight},get onSetTopHeight(){return e.onSetStageContainerHeight},get onSetMaxHeight(){return e.onSetStageContainerMaxHeight},get onSetMaxWidth(){return e.onSetStageContainerWidth},top:g=>{{let d=re(()=>e.stageSize!=="full");Qn(g,{get disabled(){return p(d)},get maxHeight(){return e.stageMaxHeight},get maxWidth(){return e.stageMaxWidth},get paneHeight(){return e.stageHeight},get paneWidth(){return e.stageWidth},get onSetStageHeight(){return e.onSetStageHeight},get onSetStageWidth(){return e.onSetStageWidth},children:(u,x)=>{var z=Ms();et(z,T=>te(s,T),()=>p(s)),Z(()=>Nt(z,e.stageStyle)),m(u,z)},$$slots:{default:!0}})}},bottom:g=>{var d=Rs(),u=f(d);{var x=z=>{es(z,{get tabs(){return p(o)},get onToggleExpandPanel(){return e.onToggleExpandPanel}})};P(u,z=>{e.panelExpanded&&z(x)})}m(g,d)},$$slots:{top:!0,bottom:!0}}),se()}function Ls(i,e){i.button!==0||i.metaKey||i.ctrlKey||i.shiftKey||i.altKey||(i.preventDefault(),globalThis.history.pushState({},"",e.href))}var Hs=E('<a><div class="component_link-container svelte-1cnyrt6"><div class="component_dot svelte-1cnyrt6"></div> <div class="component_icon svelte-1cnyrt6"><svg xmlns="http://www.w3.org/2000/svg" width="15" viewBox="0 0 24 24" height="15" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><path d="M21 8a2 2 0 00-1-1.73l-7-4a2 2 0 00-2 0l-7 4A2 2 0 003 8v8a2 2 0 001 1.73l7 4a2 2 0 002 0l7-4A2 2 0 0021 16z"></path><path d="M3.3 7l8.7 5 8.7-5M12 22V12"></path></svg></div> <div class="component_label svelte-1cnyrt6"><!></div></div></a>');function mn(i,e){var t=Hs();let n;t.__click=[Ls,e];var s=f(t),r=w(f(s),4),l=f(r);Bt(l,()=>e.text),Z(a=>{ee(t,"href",e.href),n=W(t,1,"component_link svelte-1cnyrt6",null,n,a)},[()=>({selected:e.selected})]),m(i,t)}ge(["click"]);var Ns=(i,e,t)=>e.onToggleBookmark(p(t)),Bs=E('<li class="component svelte-qxg2ml"><!> <button class="close svelte-qxg2ml"><svg xmlns="http://www.w3.org/2000/svg" class="close-icon svelte-qxg2ml" height="12" viewBox="0 0 24 24" width="12" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M18 6L6 18M6 6l12 12"></path></svg></button></li>'),As=E('<div class="bookmarks svelte-qxg2ml"><div class="bookmarks_title svelte-qxg2ml"><span class="bookmarks_title-icon svelte-qxg2ml"><svg xmlns="http://www.w3.org/2000/svg" class="bookmark_icon" height="15" viewBox="0 0 24 24" width="15" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M12 2l3.09 6.26L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l6.91-1.01L12 2z"></path></svg></span> <span class="bookmarks_title-label svelte-qxg2ml">Bookmarks</span></div> <nav class="bookmarks_nav"><ul class="components svelte-qxg2ml"></ul></nav> <div class="border-btm svelte-qxg2ml"></div></div>');function js(i,e){ne(e,!0);let t=U(e,"bookmarks",19,()=>[]);var n=As(),s=w(f(n),2),r=f(s);tt(r,21,t,l=>l.key,(l,a)=>{var o=Bs(),c=f(o);mn(c,{get href(){return p(a).href},get selected(){return p(a).selected},get text(){return p(a).name}});var h=w(c,2);h.__click=[Ns,e,a],m(l,o)}),m(i,n),se()}ge(["click"]);var qs=E('<li class="component svelte-1nn9bvq"><!></li>'),Ws=(i,e,t)=>e.onToggleFoldStatusOfNode({...p(t)}),Ps=E('<li><button><span><svg xmlns="http://www.w3.org/2000/svg" width="12" viewBox="0 0 24 24" height="12" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M18 15l-6-6-6 6"></path></svg></span> <span class="folder_icon svelte-1nn9bvq"><svg xmlns="http://www.w3.org/2000/svg" width="15" viewBox="0 0 24 24" height="15" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><path d="M4 20h16a2 2 0 002-2V8a2 2 0 00-2-2h-7.93a2 2 0 01-1.66-.9l-.82-1.2A2 2 0 007.93 3H4a2 2 0 00-2 2v13c0 1.1.9 2 2 2z"></path></svg></span> <span class="folder_label svelte-1nn9bvq"><!></span></button> <!></li>'),Os=E("<ul></ul>");function kn(i,e){ne(e,!0);let t=U(e,"nodes",19,()=>[]),n=U(e,"level",3,1);var s=Os();tt(s,21,t,r=>r.key,(r,l)=>{var a=Ie(),o=he(a);{var c=g=>{var d=qs(),u=f(d);mn(u,{get href(){return p(l).href},get selected(){return p(l).selected},get text(){return p(l).name}}),m(g,d)},h=g=>{var d=Ps();let u;var x=f(d);x.__click=[Ws,e,l];var z=f(x);let T;var C=w(z,4),R=f(C);Bt(R,()=>p(l).name);var M=w(x,2);{var N=I=>{{let L=re(()=>n()+1);kn(I,{get nodes(){return p(l).children},get level(){return p(L)},get onToggleFoldStatusOfNode(){return e.onToggleFoldStatusOfNode}})}};P(M,I=>{p(l).unfolded&&I(N)})}Z((I,L)=>{u=W(d,1,"folder svelte-1nn9bvq",null,u,I),W(x,1,`folder_btn btn_level-${n()??""}`,"svelte-1nn9bvq"),ee(x,"title",p(l).unfolded?"fold":"unfold"),T=W(z,1,"folder_arrow svelte-1nn9bvq",null,T,L)},[()=>({unfolded:p(l).unfolded}),()=>({unfolded_icon:p(l).unfolded})]),m(g,d)};P(o,g=>{p(l).isLeaf?g(c):g(h,!1)})}m(r,a)}),Z(()=>W(s,1,`filter_list components level-${n()??""}`,"svelte-1nn9bvq")),m(i,s),se()}ge(["click"]);var Ds=E('<img title="start"/>'),Us=E('<img title="start"/>'),Zs=E('<span class="svelte-1oee4bz"> </span>'),Fs=(i,e)=>e.onUpdateFilter(i.target.value),Gs=E('<div><div class="filter_zero-results svelte-1oee4bz"> </div></div>'),Vs=E('<!> <nav class="components-nav svelte-1oee4bz"><!></nav>',1),Qs=(i,e,t)=>e()?t.onExpandTree():t.onCollapseTree(),Xs=be('<svg class="controls_btn-icon svelte-1oee4bz" xmlns="http://www.w3.org/2000/svg" height="20" viewBox="0 0 24 24" width="20" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><path d="M7 15l5 5 5-5M7 9l5-5 5 5"></path></svg>'),Ks=be('<svg class="controls_btn-icon svelte-1oee4bz" xmlns="http://www.w3.org/2000/svg" height="20" viewBox="0 0 24 24" width="20" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><path d="M7 20l5-5 5 5M7 4l5 5 5-5"></path></svg>'),Ys=be('<svg class="controls_btn-icon svelte-1oee4bz" xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><rect width="18" height="18" x="3" y="3" rx="2" ry="2"></rect><line x1="3" x2="21" y1="15" y2="15"></line><path d="m15 8-3 3-3-3"></path></svg>'),Js=be('<svg class="controls_btn-icon svelte-1oee4bz" xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><rect width="18" height="18" x="3" y="3" rx="2" ry="2"></rect><line x1="3" x2="21" y1="15" y2="15"></line><path d="m9 10 3-3 3 3"></path></svg>'),$s=E('<li><a class="controls_btn svelte-1oee4bz" href="https://gardenjs.org/docs" target="_blank" rel="noreferrer"><svg class="controls_btn-icon svelte-1oee4bz" xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="10"></circle><path d="M9.09 9a3 3 0 015.83 1c0 2-3 3-3 3m.08 4h.01"></path></svg> <span class="controls_btn-label svelte-1oee4bz">Gardenjs Docs</span></a></li>'),ei=E('<header><a href="/"><!></a> <div class="filter svelte-1oee4bz"><input aria-autocomplete="list" id="filter" class="filter_input svelte-1oee4bz" autocomplete="off" type="search" placeholder="Filter..."/></div> <!> <nav class="controls svelte-1oee4bz"><ul><li><button class="controls_btn svelte-1oee4bz"><!> <span class="controls_btn-label svelte-1oee4bz"> </span></button></li> <li><button class="controls_btn svelte-1oee4bz"><!> <span class="controls_btn-label svelte-1oee4bz"> </span></button></li> <!></ul></nav></header>');function ti(i,e){ne(e,!0);let t=U(e,"bookmarks",19,()=>[]),n=U(e,"nodes",19,()=>[]),s=U(e,"panelExpanded",3,!0),r=U(e,"sidebarExpanded",3,!0),l=U(e,"treeCollapsed",3,!1);var a=ei();let o;var c=f(a);let h;c.__click=function(...S){e.onLogoClicked?.apply(this,S)};var g=f(c);{var d=S=>{var H=Ds();Z(()=>{ee(H,"src",`/assets/${e.projectLogoDarkmode??""}`),ee(H,"alt",`${e.projectTitle??""} logo`)}),m(S,H)},u=S=>{var H=Ie(),ce=he(H);{var ue=D=>{var V=Us();Z(()=>{ee(V,"src",`/assets/${e.projectLogo??""}`),ee(V,"alt",`${e.projectTitle??""} logo`)}),m(D,V)},Ce=D=>{var V=Zs(),Ee=f(V);Z(()=>ae(Ee,e.projectTitle)),m(D,V)};P(ce,D=>{e.projectLogo?D(ue):D(Ce,!1)},!0)}m(S,H)};P(g,S=>{e.projectLogoDarkmode&&e.appTheme==="dark"?S(d):S(u,!1)})}var x=w(c,2),z=f(x);z.__input=[Fs,e];var T=w(x,2);{var C=S=>{var H=Gs(),ce=f(H),ue=f(ce);Z(()=>ae(ue,`No results for '${e.filter??""}'`)),m(S,H)},R=S=>{var H=Vs(),ce=he(H);{var ue=V=>{js(V,{get bookmarks(){return t()},get onToggleBookmark(){return e.onToggleBookmark}})};P(ce,V=>{t().length>0&&V(ue)})}var Ce=w(ce,2),D=f(Ce);kn(D,{get nodes(){return n()},get onToggleFoldStatusOfNode(){return e.onToggleFoldStatusOfNode}}),m(S,H)};P(T,S=>{n().length==0&&e.filter?S(C):S(R,!1)})}var M=w(T,2),N=f(M),I=f(N),L=f(I);L.__click=[Qs,l,e];var O=f(L);{var F=S=>{var H=Xs();m(S,H)},B=S=>{var H=Ks();m(S,H)};P(O,S=>{l()?S(F):S(B,!1)})}var q=w(O,2),Ne=f(q),we=w(I,2),xe=f(we);xe.__click=function(...S){e.onToggleExpandPanel?.apply(this,S)};var pe=f(xe);{var Pe=S=>{var H=Ys();m(S,H)},Be=S=>{var H=Js();m(S,H)};P(pe,S=>{s()?S(Pe):S(Be,!1)})}var Qe=w(pe,2),Xe=f(Qe),Oe=w(we,2);{var _e=S=>{var H=$s();m(S,H)};P(Oe,S=>{e.docsLink===1&&S(_e)})}Z((S,H)=>{o=W(a,1,"sidebar_container svelte-1oee4bz",null,o,S),h=W(c,1,"project-identifier svelte-1oee4bz",null,h,H),yt(z,e.filter||""),ee(L,"title",l()?"Expand":"Collapse"),ae(Ne,`${l()?"Expand":"Collapse"} Explorer`),ee(xe,"title",s()?"Collapse":"Expand"),ae(Xe,`${s()?"Collapse":"Expand"} Panel`)},[()=>({"show-sidebar":r()}),()=>({"has-logo":e.projectLogo})]),m(i,a),se()}ge(["click","input"]);var ni=(i,e,t)=>e.handleButtonClick(p(t).name),si=E('<li class="svelte-4algbe"><button><span class="dropdown_item-dot svelte-4algbe"></span> </button></li>'),ii=E('<div class="dropdown svelte-4algbe"><!> <div><ul class="svelte-4algbe"></ul></div></div>');function ht(i,e){ne(e,!0);let t=U(e,"options",19,()=>[]),n=U(e,"dropright",3,!1);var s=Ie(),r=he(s);{var l=o=>{var c=ii(),h=f(c);Ge(h,()=>e.buttonSnippet??Fe);var g=w(h,2);let d;var u=f(g);tt(u,21,t,x=>x.name,(x,z)=>{var T=si(),C=f(T);C.__click=[ni,e,z];let R;var M=w(f(C));Z(N=>{R=W(C,1,"svelte-4algbe",null,R,N),ae(M,` ${p(z).name??""}`)},[()=>({active:p(z).active})]),m(x,T)}),Z(x=>d=W(g,1,"dropdown_items svelte-4algbe",null,d,x),[()=>({"dropdown_items-right":n()})]),m(o,c)},a=o=>{var c=Ie(),h=he(c);Ge(h,()=>e.buttonSnippet??Fe,()=>({onClick:()=>{e.handleButtonClick(t()[0].name)}})),m(o,c)};P(r,o=>{t().length>1?o(l):o(a,!1)})}m(i,s),se()}ge(["click"]);var ri=be('<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" class="svelte-y9l547"><rect x="3" y="3" width="18" height="18" rx="2" ry="2"></rect><path d="M9 3v18m7-6l-3-3 3-3"></path></svg>'),li=be('<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" class="svelte-y9l547"><rect x="3" y="3" width="18" height="18" rx="2" ry="2"></rect><path d="M9 3v18m5-12l3 3-3 3"></path></svg>'),ai=(i,e)=>e.onToggleBookmark(e.node),oi=be('<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" fill="currentColor" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" class="svelte-y9l547"><path d="M12 2l3.09 6.26L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l6.91-1.01L12 2z"></path></svg>'),ci=be('<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" class="svelte-y9l547"><path d="M12 2l3.09 6.26L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l6.91-1.01L12 2z"></path></svg>'),ui=E('<button class="topbar_btn reveal_btn svelte-y9l547" title="Reveal in explorer"><span class="is-hidden svelte-y9l547">Reveal in explorer</span> <svg xmlns="http://www.w3.org/2000/svg" width="24" viewBox="0 0 24 24" height="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" class="svelte-y9l547"><path d="M8 5h13m-8 7h8m-8 7h8M3 10a2 2 0 002 2h3"></path><path d="M3 5v12a2 2 0 002 2h3"></path></svg></button>'),hi=E('<button class="topbar_btn bookmark_btn svelte-y9l547"><span class="is-hidden svelte-y9l547"> </span> <!></button> <!>',1),di=E('<button title="Small"><span class="is-hidden svelte-y9l547">Resize viewport to small</span> <svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><rect x="5" y="2" width="14" height="20" rx="2" ry="2"></rect><path d="M12 18h.01"></path></svg> <span class="dot svelte-y9l547"></span></button>'),gi=E('<button title="Medium"><span class="is-hidden svelte-y9l547">Resize viewport to medium</span> <svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><rect x="4" y="2" width="16" height="20" rx="2" ry="2"></rect><path d="M12 18h.01"></path></svg> <span class="dot svelte-y9l547"></span></button>'),pi=E('<button title="Large"><span class="is-hidden svelte-y9l547">Resize viewport to large</span> <svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><rect x="3" y="4" width="18" height="12" rx="2" ry="2"></rect><path d="M2 20h20"></path></svg> <span class="dot svelte-y9l547"></span></button>'),fi=(i,e)=>e.onSetStageSize("full"),vi=(i,e)=>{e.onSetStageWidth(Number.parseInt(i.target.value))},mi=(i,e)=>{e.onSetStageHeight(Number.parseInt(i.target.value))},ki=E('<button class="dropdown_btn topbar_btn svelte-y9l547" title="Switch component theme"><span class="is-hidden svelte-y9l547">Open menu for selecting themes</span> <svg xmlns="http://www.w3.org/2000/svg" width="24" viewBox="0 0 24 24" height="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" class="svelte-y9l547"><circle cx="13.5" cy="6.5" r=".5"></circle><circle cx="17.5" cy="10.5" r=".5"></circle><circle cx="8.5" cy="7.5" r=".5"></circle><circle cx="6.5" cy="12.5" r=".5"></circle><path d="M12 2C6.5 2 2 6.5 2 12s4.5 10 10 10c.926 0 1.648-.746 1.648-1.688 0-.437-.18-.835-.437-1.125-.29-.289-.438-.652-.438-1.125a1.64 1.64 0 011.668-1.668h1.996c3.051 0 5.555-2.503 5.555-5.554C21.965 6.012 17.461 2 12 2z"></path></svg></button>'),bi=be('<svg xmlns="http://www.w3.org/2000/svg" class="mode-icon svelte-y9l547" width="24" viewBox="0 0 24 24" height="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="4"></circle><path d="M12 2v2m0 16v2M4.93 4.93l1.41 1.41m11.32 11.32l1.41 1.41M2 12h2m16 0h2M6.34 17.66l-1.41 1.41M19.07 4.93l-1.41 1.41"></path></svg>'),wi=be('<svg xmlns="http://www.w3.org/2000/svg" class="mode-icon svelte-y9l547" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><path d="M12 3a6.364 6.364 0 009 9 9 9 0 11-9-9z"></path></svg>'),xi=E('<div class="topbar svelte-y9l547"><div class="topbar_container svelte-y9l547"><div class="topbar_nav svelte-y9l547"><button class="topbar_btn is-first-btn svelte-y9l547"><span class="is-hidden svelte-y9l547"> </span> <!></button> <!></div> <div class="topbar_nav svelte-y9l547"><div class="stagesize-nav svelte-y9l547"><!> <!> <!> <button title="Full"><span class="is-hidden svelte-y9l547">Resize viewport to full</span> <svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" class="svelte-y9l547"><rect x="2" y="3" width="20" height="14" rx="2" ry="2"></rect><path d="M8 21h8m-4-4v4"></path></svg> <span class="dot svelte-y9l547"></span></button> <button class="svelte-y9l547"><span class="is-hidden svelte-y9l547"> </span> <svg xmlns="http://www.w3.org/2000/svg" width="24" viewBox="0 0 24 24" height="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" class="svelte-y9l547"><rect width="12" height="20" x="6" y="2" rx="2"></rect><rect width="20" height="12" x="2" y="6" rx="2"></rect></svg></button></div> <div class="stagesize-value svelte-y9l547"><input class="stagesize-input svelte-y9l547" type="number" min="50"/> <div class="stagesize-value-multi_sign svelte-y9l547">&#47;</div> <input class="stagesize-input svelte-y9l547" type="number" min="50"/></div> <button title="Show background grid"><span class="is-hidden svelte-y9l547">Show background grid</span> <svg xmlns="http://www.w3.org/2000/svg" width="24" viewBox="0 0 24 24" height="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" class="svelte-y9l547"><rect width="18" height="18" x="3" y="3" rx="2"></rect><path d="M3 9h18M3 15h18M9 3v18m6-18v18"></path></svg> <span class="dot svelte-y9l547"></span></button> <button title="Visualise margins and paddings"><span class="is-hidden svelte-y9l547">Visualise margins and paddings</span> <svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" class="svelte-y9l547"><path d="M12 15v-3.014M16 15v-3.014M20 6H4m16 2V4M4 8V4m4 11v-3.014"></path><rect x="3" y="12" width="18" height="7" rx="1"></rect></svg> <span class="dot svelte-y9l547"></span></button> <button class="topbar_btn openexternal_btn svelte-y9l547" title="Open component in new tab"><span class="is-hidden svelte-y9l547">Open component in new tab</span> <svg xmlns="http://www.w3.org/2000/svg" class="open-new-tab-icon svelte-y9l547" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><path d="M18 13v6a2 2 0 01-2 2H5a2 2 0 01-2-2V8a2 2 0 012-2h6m4-3h6v6m-11 5L21 3"></path></svg></button> <!> <button class="topbar_btn is-last-btn svelte-y9l547"><span class="is-hidden svelte-y9l547"> </span> <!></button></div></div></div>');function _i(i,e){ne(e,!0);let t=U(e,"appTheme",3,"default"),n=U(e,"landscape",3,!1),s=U(e,"sidebarExpanded",3,!0),r=U(e,"stageSize",3,"full"),l=U(e,"stageSizes",19,()=>({})),a=U(e,"themes",19,()=>[]),o=oe(!1);const c=re(()=>Math.round(e.stageRect.width)),h=re(()=>Math.round(e.stageRect.height));le(()=>{te(o,t()==="dark"),t()==="dark"?document.documentElement.setAttribute("data-theme","dark"):document.documentElement.setAttribute("data-theme","light")});var g=xi(),d=f(g),u=f(d),x=f(u);x.__click=function(..._){e.onToggleExpandSidebar?.apply(this,_)};var z=f(x),T=f(z),C=w(z,2);{var R=_=>{var X=ri();m(_,X)},M=_=>{var X=li();m(_,X)};P(C,_=>{s()?_(R):_(M,!1)})}var N=w(x,2);{var I=_=>{var X=hi(),$=he(X);$.__click=[ai,e];var fe=f($),je=f(fe),K=w(fe,2);{var ve=Y=>{var De=oi();m(Y,De)},qe=Y=>{var De=ci();m(Y,De)};P(K,Y=>{e.node.bookmark?Y(ve):Y(qe,!1)})}var me=w($,2);{var Q=Y=>{var De=ui();De.__click=function(...Mn){e.onRevealInExplorer?.apply(this,Mn)},m(Y,De)};P(me,Y=>{e.nodeVisibleInExplorer||Y(Q)})}Z(()=>{ee($,"title",e.node.bookmark?"Remove from bookmarks":"Add to bookmarks"),ae(je,e.node.bookmark?"Remove from bookmarks":"Add to bookmarks")}),m(_,X)};P(N,_=>{e.node&&_(I)})}var L=w(u,2),O=f(L),F=f(O);{var B=_=>{ht(_,{get options(){return l().small},get handleButtonClick(){return e.onSetStageSize},buttonSnippet:($,fe)=>{let je=()=>fe?.().onClick;var K=di();let ve;K.__click=function(...Q){je()?.apply(this,Q)};var qe=w(f(K),2);let me;Z((Q,Y)=>{ve=W(K,1,"dropdown_btn topbar_btn svelte-y9l547",null,ve,Q),me=W(qe,0,"svelte-y9l547",null,me,Y)},[()=>({active:l().small.some(Q=>Q.active)}),()=>({landscape:n()})]),m($,K)},$$slots:{buttonSnippet:!0}})};P(F,_=>{l().small?.length>0&&_(B)})}var q=w(F,2);{var Ne=_=>{ht(_,{get options(){return l().medium},get handleButtonClick(){return e.onSetStageSize},buttonSnippet:($,fe)=>{let je=()=>fe?.().onClick;var K=gi();let ve;K.__click=function(...Q){je()?.apply(this,Q)};var qe=w(f(K),2);let me;Z((Q,Y)=>{ve=W(K,1,"dropdown_btn topbar_btn svelte-y9l547",null,ve,Q),me=W(qe,0,"svelte-y9l547",null,me,Y)},[()=>({active:l().medium.some(Q=>Q.active)}),()=>({landscape:n()})]),m($,K)},$$slots:{buttonSnippet:!0}})};P(q,_=>{l().medium?.length>0&&_(Ne)})}var we=w(q,2);{var xe=_=>{ht(_,{get options(){return l().large},get handleButtonClick(){return e.onSetStageSize},buttonSnippet:($,fe)=>{let je=()=>fe?.().onClick;var K=pi();let ve;K.__click=function(...Q){je()?.apply(this,Q)};var qe=w(f(K),2);let me;Z((Q,Y)=>{ve=W(K,1,"dropdown_btn topbar_btn svelte-y9l547",null,ve,Q),me=W(qe,0,"svelte-y9l547",null,me,Y)},[()=>({active:l().large.some(Q=>Q.active)}),()=>({landscape:n()})]),m($,K)},$$slots:{buttonSnippet:!0}})};P(we,_=>{l().large?.length>0&&_(xe)})}var pe=w(we,2);pe.__click=[fi,e];let Pe;var Be=w(pe,2);Be.__click=function(..._){e.onToggleOrientation?.apply(this,_)};var Qe=f(Be),Xe=f(Qe),Oe=w(O,2),_e=f(Oe);_e.__change=[vi,e];var S=w(_e,4);S.__change=[mi,e];var H=w(Oe,2);let ce;H.__click=function(..._){e.onToggleShowGrid?.apply(this,_)};var ue=w(H,2);let Ce;ue.__click=function(..._){e.onToggleShowInspector?.apply(this,_)};var D=w(ue,2);D.__click=function(..._){e.onOpenInTab?.apply(this,_)};var V=w(D,2);{var Ee=_=>{ht(_,{get options(){return a()},dropright:!0,get handleButtonClick(){return e.onSetTheme},buttonSnippet:$=>{var fe=ki();m($,fe)},$$slots:{buttonSnippet:!0}})};P(V,_=>{a().length>1&&_(Ee)})}var Ae=w(V,2);Ae.__click=function(..._){e.onToggleAppTheme?.apply(this,_)};var ot=f(Ae),ct=f(ot),xt=w(ot,2);{var Cn=_=>{var X=bi();m(_,X)},En=_=>{var X=wi();m(_,X)};P(xt,_=>{p(o)?_(Cn):_(En,!1)})}Z((_,X,$)=>{ee(x,"title",s()?"Collapse sidebar":"Expand sidebar"),ae(T,s()?"Collapse sidebar":"Expand sidebar"),Pe=W(pe,1,"svelte-y9l547",null,Pe,_),ee(Be,"title",n()?"Portrait mode":"Landscape mode"),ae(Xe,`Reverse the aspect ratio to ${n()?"portrait mode":"landscape mode"}`),_e.disabled=r()!=="full",yt(_e,p(c)),ee(_e,"max",e.stageMaxWidth),S.disabled=r()!=="full",yt(S,p(h)),ee(S,"max",e.stageMaxHeight),ce=W(H,1,"topbar_btn show-grid svelte-y9l547",null,ce,X),Ce=W(ue,1,"topbar_btn show-m-p_btn svelte-y9l547",null,Ce,$),ee(Ae,"title",p(o)?"Light mode":"Dark mode"),ae(ct,p(o)?"Light mode":"Dark mode")},[()=>({active:r()==="full"}),()=>({active:e.showGrid===!0}),()=>({active:e.showInspector===!0})]),m(i,g),se()}ge(["click","change"]);function ze(i,e,t=s=>s,n=s=>s){const s=G(t(localStorage.getItem(i))??e);return s.subscribe(r=>{localStorage.setItem(i,n(r))}),s}const st=i=>Number.isNaN(Number(i))?i:Number(i),Me=G([]),Ye=G({small:[{name:"small",h:1170,w:550}],medium:[{name:"medium",h:1080,w:810}],large:[{name:"large",h:960,w:1536}]}),Yt={name:"full",h:"100%",w:"100%"},bn=G(""),it=ze("stageSize","full"),Je=ze("landscape",!1,i=>i==="true"),ye=ze("stageContainerHeight","",st),qt=ze("stageContainerWidth","",st),Se=ze("stageContainerMaxHeight","",st),pt=ze("stageHeight","full",st),ft=ze("stageWidth","full",st),yi=nt([ye,Se],([i,e])=>Math.min(i,e)-20),Si=nt(qt,i=>i-20),wn=G({}),Ke=G(!0),zt=ze("appTheme","default"),Ze=ze("frameTheme"),Tt=G(!0),$e=G(!1),Ct=G(!1),Et=G(!1),xn=G({size:16,style:"lined",color:"#ddd"}),zi=()=>{it.set("full"),Je.set(!1),ye.set(""),qt.set(""),Se.set(""),pt.set("full"),ft.set("full")};function Ti({size:i,style:e,color:t}){xn.set({size:i??50,style:e??"lined",color:t??"grey"})}let Ue="";function Ci(i){Ye.set(i),yn(y(it))}function Ei(i){y(Ze)||Ze.set(i?.find(e=>e.active)?.name??i[0].name),Me.set(i?.map(e=>({...e,active:e.name===y(Ze)}))),rt()}function Mi(i){Me.set(y(Me).map(e=>({...e,active:e.name===i}))),Ze.set(i),rt()}function Ri(){zt.set(y(zt)==="dark"?"default":"dark")}function Ii(){return y(Me)&&y(Me).length>0?y(Me).find(i=>i.name===y(Ze))??y(Me)[0]:{stageBg:"white"}}function Li(i){if(i==="full")return Yt;const e=y(Ye),t=[...e.small??[],...e.medium??[],...e.large??[]].find(n=>n.name===i);return t?{...t,h:`${t.h}px`,w:`${t.w}px`}:Yt}function rt(){const i=Ii().stageBg,{h:e,w:t}=Li(y(it)),n=y(Je)?`width: ${e}; height: ${t}`:`width: ${t}; height: ${e}`,s=`background-color: ${i}`;bn.set(`${n}; ${s}; transition: 0s;`)}function Hi(i){ye.set(i),_n()}function Ni(i){wn.set(i)}function Bi(i){const e=i-9;Se.set(e),_n()}function Ai(i){qt.set(i)}function Jt(i){Number.isInteger(i)?pt.set(Math.max(50,i)):pt.set(i)}function $t(i){Number.isInteger(i)?ft.set(Math.max(50,i)):ft.set(i)}function _n(){Number.isInteger(y(ye))&&Number.isInteger(y(Se))&&Ke.set(y(ye)<y(Se))}function en(){y(Ke)?(Ue=y(ye),ye.set(y(Se))):((!Number.isInteger(Ue)||Number.isInteger(Ue)&&y(Se)-Ue<50)&&(Ue=Math.round(y(Se)*.7)),ye.set(Ue)),Ke.set(!y(Ke))}function ji(){y(Wt)?$e.set(!y($e)):Tt.set(!y(Tt))}function qi(){Ct.set(!y(Ct))}function Wi(){Et.set(!y(Et))}const Wt=jn(window.innerWidth<840,i=>{const e=()=>{i(window.innerWidth<840),$e.set(!1)};return window.addEventListener("resize",e),()=>{window.removeEventListener("resize",e)}}),Pi=nt([Tt,$e,Wt],([i,e,t])=>t?e:i);function Oi(){y(Wt)&&$e.set(!1)}function yn(i){it.set(i);const e=y(Ye),t=Object.keys(e).reduce((n,s)=>(n[s]=e[s].map(r=>({...r,active:r.name===i})),n),{});Ye.set(t),rt()}function Di(){Je.set(!y(Je)),rt()}rt();function Ui(i,e,t=s=>s,n=s=>s){const s=G(t(localStorage.getItem(i))??e);return s.subscribe(r=>{localStorage.setItem(i,n(r))}),s}const Pt=G([]),wt=G(),Ot=G(),ke=Ui("bookmarks",[],JSON.parse,JSON.stringify);let tn=!1,de=G([]),Ve=[],lt;const Zi=nt(de,i=>!i.some(e=>Ut(e))),Fi=nt(Ot,i=>{const e=[];let t=i;for(;t.parent;)e.push(t.parent),t=t.parent;return e.every(n=>Ut(n))});function at(i){return[i,...Gi(i)]}function Gi(i){return i.children?i.children.flatMap(at):[]}function Vi(i){lt=i,Te(),nr()}function Qi(i){wt.set(i),Te()}function Xi(i){de.set(i),tn||(Sn(),sr(),tn=!0),Pt.set(Dt(y(de))),de.set(i)}function Te(){Pt.set(Dt(y(de))),de.set(y(de))}function Dt(i,e){const t=y(wt)?.toLowerCase();return i.map(n=>{const s=t?n.name?.toLowerCase().includes(t):!0,r=t&&s?Ki(n.name):n.name;if(n.isLeaf){const a=e?.visible||s?{...n,parent:e,name:r,selected:lt===n.key,isLeaf:!0,bookmark:y(ke).find(o=>o.key===n.key)!==void 0}:void 0;return a?.selected&&Ot.set(a),a}else{n.parent=e;const l=Dt(n.children,n).filter(o=>o),a=s||l.length>0;return a?{...n,parent:e,name:r,children:l,unfolded:Ut(n,t,a),filterMatches:s}:void 0}}).filter(n=>n)}function Ki(i){const e=y(wt).toLowerCase(),t=i.toLowerCase().indexOf(e),n=t+e.length,s=i.substring(0,t),r=i.substring(t,n),l=i.substring(n);return`${s}<span class="highlight">${r}</span>${l}`}function Ut(i,e,t){return e&&t||Ve[i.key]}function _t(i){return i.split("#")[0].split("?")[0].replace(/\/+$/,"")}function Yi(i){const e=_t(i),n=y(de).flatMap(at).find(l=>l.isLeaf&&_t(l.href)===e),r=(_t(n?.href)||e).split("/").filter(l=>l.length>0);if(r.length<2)return n;for(let l=0;l<r.length-1;l++){const a="/"+r.slice(0,l+1).join("/")+"/";Ve[a]=!0}Te()}function Ji(i){Ve[i.key]=!Ve[i.key],Te()}function $i(){Ve=y(de).flatMap(at).reduce((e,t)=>(e[t.key]=!1,e),{}),Te()}function Sn(){Ve=y(de).flatMap(at).reduce((e,t)=>(e[t.key]=!0,e),{}),Te()}function nn(i){i.bookmark?er({...i}):tr({...i,bookmark:!0}),Te()}function er(i){ke.set(y(ke).filter(e=>i.key!==e.key).map(e=>({...e,selected:e.key===lt}))),Te()}function tr(i){ke.set([...y(ke),i].map(e=>({...e,selected:e.key===lt})).sort((e,t)=>e.name.localeCompare(t.name))),Te()}function nr(){ke.set([...y(ke)].map(i=>({...i,selected:i.key===lt})).sort((i,e)=>i.name.localeCompare(e.name)))}function sr(){const i=y(de).flatMap(at),e=y(ke).filter(t=>i.some(n=>n.key===t.key));ke.set(e)}const zn=[],ir=globalThis.location?globalThis.location.pathname+globalThis.location.search:"";let ie=ir,Re="",Mt,Rt={url:ie};(function(){globalThis.history&&(globalThis.history.state&&globalThis.history.state.url==ie&&(Rt=globalThis.history.state),globalThis.history.replaceState(Rt,null,ie))})();function rr(i,e,t){Mt=i,Re=e,t&&lr(t),vt(Rt,ie)}function lr(i){zn.push(i)}function vt(i,e){zn.forEach(t=>{t(ar(e),i)})}function ar(i){const e=i.substring(Re.length),t=Object.keys(Mt).find(n=>e.match(new RegExp("^"+n+"$","i")));return t?Mt[t]:null}(function(i){if(i){var e=i.pushState,t=i.replaceState;i.pushState=function(n,s,r){let a=typeof r=="string"?r:"";Re.length>0&&a.startsWith(Re)&&(a=a.substring(Re.length)||"/"),a.length===0&&(a="/"),a[0]!=="/"&&(a="/"+a),ie=Re+a;const o=n&&typeof n=="object"?n:{};return o.url=ie,o.url!==i.state?.url||o.selectedExample!==i.state?.selectedExample?(vt(o,ie),e.apply(i,[o,"",ie])):(vt(o,ie),t.apply(i,[o,"",ie]))}}})(globalThis.history);globalThis.onpopstate=function(i){i.state?ie=i.state.url:ie=Re.length>0?Re:"/",vt(i.state,ie)};const It=G(""),mt=G(),kt=G({}),or=G("");let bt,Lt,Ht;function cr(i){bt=i,Ht&&Tn()}function ur(i,e,t){bt=i,Ht||(Ht=!0,rr(e,t,hr))}function hr(i,e){if(mt.set({}),It.set(""),kt.set({}),i&&bt){It.set(i.fullname),or.set(i.route);const t=bt[i.fullname];t.componentfile=i.file,mt.set(t),Lt=e,Tn()}}function Tn(){const i=y(mt).examples||[];Lt?.selectedExample?kt.set(i.find(e=>e.title==Lt.selectedExample)?.title):kt.set(i[0]?.title)}var dr=()=>{window.top.location.reload()},gr=E('<div class="message svelte-yh1ir7"><div class="click-completed svelte-yh1ir7">Relative link was clicked!</div> <div class="instruction svelte-yh1ir7">Click the button to return: <button class="svelte-yh1ir7">back</button></div></div>'),pr=E('<div class="garden svelte-yh1ir7"><div class="sidebar svelte-yh1ir7"><!></div> <div class="main svelte-yh1ir7"><!> <!></div></div>');function fr(i,e){ne(e,!0);const[t,n]=qn(),s=()=>A(It,"$componentName",t),r=()=>A(kt,"$selectedExample",t),l=()=>A(Ze,"$activeTheme",t),a=()=>A(zt,"$appTheme",t),o=()=>A(ke,"$bookmarks",t),c=()=>A(wt,"$filterNavTree",t),h=()=>A(Pt,"$nodes",t),g=()=>A(Ke,"$panelExpanded",t),d=()=>A(Zi,"$treeCollapsed",t),u=()=>A(Pi,"$sidebarExpanded",t),x=()=>A(Je,"$landscape",t),z=()=>A(Ot,"$selectedNode",t),T=()=>A(Et,"$showGrid",t),C=()=>A(Fi,"$selectedNodeVisibleInTree",t),R=()=>A(Ct,"$showInspector",t),M=()=>A(pt,"$stageHeight",t),N=()=>A(yi,"$stageMaxHeight",t),I=()=>A(Si,"$stageMaxWidth",t),L=()=>A(wn,"$stageRect",t),O=()=>A(it,"$stageSize",t),F=()=>A(Ye,"$stageSizes",t),B=()=>A(ft,"$stageWidth",t),q=()=>A(Me,"$themes",t),Ne=()=>A(mt,"$das",t),we=()=>A(xn,"$gridSettings",t),xe=()=>A(ye,"$stageContainerHeight",t),pe=()=>A(Se,"$stageContainerMaxHeight",t),Pe=()=>A(bn,"$stageStyle",t);let Be="/garden";le(()=>{Xi(e.navTree)}),le(()=>{e.routes&&e.dasMap&&ur(e.dasMap,e.routes,Be)}),le(()=>{cr(e.dasMap)}),le(()=>{Ei(e.config.themes)}),le(()=>{e.config.devices&&Ci(e.config.devices),e.config.grid&&Ti(e.config.grid)}),le(()=>{Vi(s()),Oi()});let Qe=e.config.project_title||"",Xe=e.config.project_logo?.split("/").pop()||null,Oe=e.config.project_logo_darkmode?.split("/").pop()||null,_e=re(()=>e.config.docs_link?1:0);function S(){const D=window.open("/frame.html","_blank");D&&(D.onload=()=>{D.postMessage({selectedExample:r(),componentName:s(),theme:l()},window.location.origin)})}var H=Ie(),ce=he(H);{var ue=D=>{var V=gr(),Ee=w(f(V),2),Ae=w(f(Ee));Ae.__click=[dr],m(D,V)},Ce=D=>{var V=pr(),Ee=f(V),Ae=f(Ee);ti(Ae,{get docsLink(){return p(_e)},get projectLogoDarkmode(){return Oe},get projectLogo(){return Xe},get projectTitle(){return Qe},get appTheme(){return a()},get bookmarks(){return o()},get filter(){return c()},get nodes(){return h()},get panelExpanded(){return g()},get treeCollapsed(){return d()},get sidebarExpanded(){return u()},get onLogoClicked(){return zi},get onToggleBookmark(){return nn},get onToggleExpandPanel(){return en},get onToggleFoldStatusOfNode(){return Ji},get onUpdateFilter(){return Qi},get onCollapseTree(){return $i},get onExpandTree(){return Sn}});var ot=w(Ee,2),ct=f(ot);_i(ct,{get appTheme(){return a()},get landscape(){return x()},get node(){return z()},get showGrid(){return T()},get nodeVisibleInExplorer(){return C()},get showInspector(){return R()},get sidebarExpanded(){return u()},get stageHeight(){return M()},get stageMaxHeight(){return N()},get stageMaxWidth(){return I()},get stageRect(){return L()},get stageSize(){return O()},get stageSizes(){return F()},get stageWidth(){return B()},get themes(){return q()},onOpenInTab:S,get onSetStageHeight(){return Jt},get onSetStageWidth(){return $t},get onSetStageSize(){return yn},get onSetTheme(){return Mi},get onToggleAppTheme(){return Ri},get onToggleBookmark(){return nn},get onToggleExpandSidebar(){return ji},get onToggleOrientation(){return Di},get onToggleShowGrid(){return Wi},get onToggleShowInspector(){return qi},onRevealInExplorer:()=>Yi(z()?.href)});var xt=w(ct,2);Is(xt,{get appTheme(){return a()},get componentName(){return s()},get das(){return Ne()},get devmodus(){return e.config.devmodus},get gridSettings(){return we()},get panelExpanded(){return g()},get selectedExample(){return r()},get showGrid(){return T()},get showInspector(){return R()},get stageContainerHeight(){return xe()},get stageContainerMaxHeight(){return pe()},get stageHeight(){return M()},get stageMaxHeight(){return N()},get stageMaxWidth(){return I()},get stageSize(){return O()},get stageStyle(){return Pe()},get stageWidth(){return B()},get theme(){return l()},get onSetStageContainerHeight(){return Hi},get onSetStageContainerMaxHeight(){return Bi},get onSetStageContainerWidth(){return Ai},get onSetStageHeight(){return Jt},get onSetStageWidth(){return $t},get onToggleExpandPanel(){return en},get onUpdateStageRect(){return Ni}}),m(D,V)};P(ce,D=>{window.top!==window.self?D(ue):D(Ce,!1)})}m(i,H),se(),n()}ge(["click"]);Wn(fr,{target:document.getElementById("app"),props:{navTree:On,routes:Pn,dasMap:Dn,config:Un}});
@@ -16,4 +16,4 @@
16
16
 
17
17
  Outdated base version: https://github.com/primer/github-syntax-dark
18
18
  Current colors taken from GitHub's CSS
19
- */[data-theme=dark] .hljs{color:#c9d1d9}[data-theme=dark] .hljs-doctag,[data-theme=dark] .hljs-keyword,[data-theme=dark] .hljs-meta .hljs-keyword,[data-theme=dark] .hljs-template-tag,[data-theme=dark] .hljs-template-variable,[data-theme=dark] .hljs-type,[data-theme=dark] .hljs-variable.language_{color:#ff7b72}[data-theme=dark] .hljs-title,[data-theme=dark] .hljs-title.class_,[data-theme=dark] .hljs-title.class_.inherited__,[data-theme=dark] .hljs-title.function_{color:#d2a8ff}[data-theme=dark] .hljs-attr,[data-theme=dark] .hljs-attribute,[data-theme=dark] .hljs-literal,[data-theme=dark] .hljs-meta,[data-theme=dark] .hljs-number,[data-theme=dark] .hljs-operator,[data-theme=dark] .hljs-variable,[data-theme=dark] .hljs-selector-attr,[data-theme=dark] .hljs-selector-class,[data-theme=dark] .hljs-selector-id{color:#79c0ff}[data-theme=dark] .hljs-regexp,[data-theme=dark] .hljs-string,[data-theme=dark] .hljs-meta .hljs-string{color:#a5d6ff}[data-theme=dark] .hljs-built_in,[data-theme=dark] .hljs-symbol{color:#ffa657}[data-theme=dark] .hljs-comment,[data-theme=dark] .hljs-code,[data-theme=dark] .hljs-formula{color:#8b949e}[data-theme=dark] .hljs-name,[data-theme=dark] .hljs-quote,[data-theme=dark] .hljs-selector-tag,[data-theme=dark] .hljs-selector-pseudo{color:#7ee787}[data-theme=dark] .hljs-subst{color:#c9d1d9}[data-theme=dark] .hljs-section{color:#1f6feb;font-weight:700}[data-theme=dark] .hljs-bullet{color:#f2cc60}[data-theme=dark] .hljs-emphasis{color:#c9d1d9;font-style:italic}[data-theme=dark] .hljs-strong{color:#c9d1d9;font-weight:700}[data-theme=dark] .hljs-addition{color:#aff5b4;background-color:#033a16}[data-theme=dark] .hljs-deletion{color:#ffdcd7;background-color:#67060c}.stage_iframe.svelte-17n05ij{display:block;align-self:center;margin:auto;height:100%;width:100%;background-color:var(--c-basic-0)}.panel.svelte-17n05ij{display:flex;flex-direction:column;flex-wrap:nowrap;position:relative;margin-bottom:.375rem;height:100%;width:100%;background-color:var(--c-basic-0);border-top:0;border-radius:0 0 .625rem .625rem;overflow-y:auto}.component_link.svelte-1cnyrt6{display:flex;margin:0;padding:.188rem 0;width:100%;height:1.375rem;text-transform:initial;font-size:.813rem;color:var(--c-basic-600);line-height:1.2;font-weight:400}.component_link.svelte-1cnyrt6:hover,.component_link.svelte-1cnyrt6:focus-visible{color:var(--c-primary);font-weight:500;background-color:var(--c-basic-100)}.component_link-container.svelte-1cnyrt6{display:flex;align-items:center}.component_link.svelte-1cnyrt6 .component_dot:where(.svelte-1cnyrt6){margin:0 .5rem 0 -.219rem;height:.375rem;width:.375rem!important;background-color:transparent;border-radius:50%}.component_link.selected.svelte-1cnyrt6 .component_dot:where(.svelte-1cnyrt6){background-color:var(--c-primary)}.component_link.selected.svelte-1cnyrt6{margin-left:-1px;color:var(--c-primary);font-weight:600;background-color:var(--c-primary-bg);border-left:1px solid var(--c-primary)}.component_icon.svelte-1cnyrt6{display:flex;align-items:center;margin:0 .5rem 0 0;color:var(--c-basic-400)}.component_label.svelte-1cnyrt6{margin-right:.5rem;overflow:hidden;white-space:nowrap}.bookmarks.svelte-qxg2ml{display:none}@media (min-height: 500px) and (min-width: 500px){.bookmarks.svelte-qxg2ml{display:block}}.bookmarks_title.svelte-qxg2ml{display:flex;justify-content:flex-start;align-items:center;width:100%;margin:0;padding:.5rem .688rem .375rem}.bookmarks_title-icon.svelte-qxg2ml{display:flex;align-items:center;margin-right:.375rem;color:var(--c-primary)}.bookmarks_title-label.svelte-qxg2ml{display:flex;width:100%;font-size:.813rem;color:var(--c-basic-900);font-weight:600;text-transform:uppercase;overflow:hidden;white-space:nowrap}.border-btm.svelte-qxg2ml{margin:1rem 0 .5rem;height:1px;border-bottom:1px solid var(--c-bg-body)}.components.svelte-qxg2ml{margin-left:1.063rem;width:100%;border-left:1px solid var(--c-basic-250)}.component.svelte-qxg2ml{display:flex;height:1.375rem;width:100%;z-index:1}.close.svelte-qxg2ml{position:absolute;display:flex;justify-content:flex-end;align-items:center;right:0;width:1.75rem;height:1.375rem;z-index:9;background-color:var(--c-sidebar-bg)}.component:has(.component_link:hover) .close,.component:has(.component_link:focus-visible) .close{background-color:var(--c-basic-100)}.component:has(.close:hover) .component_link.selected,.component:has(.component_link.selected) .close{background-color:var(--c-primary-bg)!important}.component:has(.close:hover) .component_link,.close.svelte-qxg2ml:hover{background-color:var(--c-basic-100)}.close-icon.svelte-qxg2ml{display:block;color:var(--c-basic-600)}.close.svelte-qxg2ml:hover .close-icon:where(.svelte-qxg2ml),.close.svelte-qxg2ml:focus-visible .close-icon:where(.svelte-qxg2ml){color:var(--c-primary);stroke-width:4}.components.svelte-1nn9bvq{margin-left:1.063rem;border-left:1px solid var(--c-basic-250)}.component.svelte-1nn9bvq{height:1.375rem}.level-1.svelte-1nn9bvq{width:100%;margin:0;padding:0;border:none}.folder.svelte-1nn9bvq{display:block;margin:0}.folder_btn.svelte-1nn9bvq{display:flex;justify-content:flex-start;align-items:center;width:100%;margin:0;padding:.5rem .688rem .375rem}.folder_label.svelte-1nn9bvq{display:flex;width:100%;font-size:.813rem;color:var(--c-basic-900);font-weight:600;text-transform:uppercase;overflow:hidden;white-space:nowrap}.folder_btn.svelte-1nn9bvq:hover{background-color:var(--c-basic-100)}.folder_btn.svelte-1nn9bvq:hover .folder_label:where(.svelte-1nn9bvq){color:var(--c-primary)}.folder_btn.svelte-1nn9bvq:focus-visible{color:var(--c-primary);outline:none;background-color:var(--c-basic-100)}.folder_arrow.svelte-1nn9bvq{display:flex;align-items:center;width:.938rem;height:1.25rem;transition:.2s;margin-right:.375rem;color:var(--c-basic-900)}.folder_arrow.unfolded_icon.svelte-1nn9bvq{transform:rotate(180deg);transition:.2s}.folder_icon.svelte-1nn9bvq{display:flex;align-items:center;margin-right:.375rem;color:var(--c-primary)}.btn_level-3.svelte-1nn9bvq .folder_label:where(.svelte-1nn9bvq){font-size:.813rem}.filter_list.svelte-1nn9bvq .highlight{padding:0 .125rem;color:var(--c-primary);font-weight:700}.sidebar_container.svelte-1oee4bz{--w-sidebar: 260px;display:flex;flex-direction:column;position:relative;margin:.375rem 0;width:0;max-width:var(--w-sidebar);height:calc(100vh - .75rem);background-color:var(--c-sidebar-bg);border-radius:.625rem;transition:width .1s;overflow:hidden}.show-sidebar.svelte-1oee4bz{margin:.375rem .375rem .375rem 0;width:var(--w-sidebar);box-sizing:border-box}.project-identifier.svelte-1oee4bz{position:relative;display:flex;flex-shrink:0;flex-direction:row;justify-content:center;align-items:center;padding:.25rem .688rem;margin:0 0 .125rem;width:var(--w-sidebar);height:2.25rem;background-color:var(--c-sidebar);inline-size:var(--w-sidebar);overflow:hidden;white-space:nowrap;font-size:1.25rem;color:var(--c-primary);text-decoration:none;font-weight:900;line-height:1}.project-identifier.has-logo.svelte-1oee4bz{height:auto}.project-identifier.svelte-1oee4bz:focus-visible{color:var(--c-basic-500)}.project-identifier.svelte-1oee4bz span:where(.svelte-1oee4bz){overflow:hidden}.filter.svelte-1oee4bz{display:flex;flex-shrink:0;margin:0 0 .25rem;padding:.25rem .688rem;height:2.25rem}.filter_input.svelte-1oee4bz{padding:.125rem .125rem .125rem .688rem;width:100%;height:100%;color:var(--c-basic-900);background-color:var(--c-basic-0);border:1px solid var(--c-primary);border-radius:1.75rem}input.filter_input[type=search].svelte-1oee4bz{font-size:.813rem}input[type=search].svelte-1oee4bz::-webkit-search-cancel-button{-webkit-appearance:none}.filter_input.svelte-1oee4bz::placeholder{font-size:.813rem;color:var(--c-basic-500)}.filter_input.svelte-1oee4bz:focus-visible{background-color:var(--c-primary-bg)}.filter_zero-results.svelte-1oee4bz{width:var(--w-sidebar);padding:.5rem .688rem .375rem;text-transform:initial;font-size:.813rem;color:var(--c-basic-600);font-weight:400;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.components-nav.svelte-1oee4bz{display:flex;flex-shrink:1;overflow:hidden;visibility:visible;width:var(--w-sidebar);overflow-y:auto;margin:0 0 1rem}.controls.svelte-1oee4bz{display:none}@media (min-height: 35rem){.controls.svelte-1oee4bz{display:block;flex-shrink:0;width:var(--w-sidebar);height:103px;bottom:.375rem;padding:0;background-color:var(--c-sidebar);border-top:1px solid var(--c-bg-body);border-bottom-right-radius:.5rem;border-bottom-left-radius:.5rem;overflow:hidden}}.controls_btn.svelte-1oee4bz{display:flex;justify-content:flex-start;align-items:center;width:100%;height:2.125rem;margin:0;padding:0 .688rem;text-align:left}.controls_btn.svelte-1oee4bz:hover,.controls_btn.svelte-1oee4bz:focus-visible{background-color:var(--c-basic-100)}.controls_btn-icon.svelte-1oee4bz{margin:0;color:var(--c-basic-700)}.controls_btn-label.svelte-1oee4bz{position:relative;align-self:center;margin-left:.75rem;width:100%;color:var(--c-basic-900);font-size:.875rem;font-weight:400}.controls_btn.svelte-1oee4bz:hover .controls_btn-label:where(.svelte-1oee4bz),.controls_btn.svelte-1oee4bz:focus-visible .controls_btn-label:where(.svelte-1oee4bz),.controls_btn.svelte-1oee4bz:hover .controls_btn-icon:where(.svelte-1oee4bz),.controls_btn.svelte-1oee4bz:focus-visible .controls_btn-icon:where(.svelte-1oee4bz){color:var(--c-primary)}.dropdown.svelte-4algbe{position:relative;display:inline-block;z-index:99}.dropdown_items.svelte-4algbe{visibility:hidden;position:absolute;left:0;padding:.375rem 0 0;z-index:9}.dropdown_items-right.svelte-4algbe{left:unset;right:0}.dropdown_items.svelte-4algbe ul:where(.svelte-4algbe){margin:0;padding:0;background-color:var(--c-basic-50);filter:drop-shadow(0px 5px 5px rgba(0,0,0,.05)) drop-shadow(0 1px 3px rgba(0,0,0,.1));border-radius:.5rem;overflow:hidden}.dropdown_items.svelte-4algbe ul:where(.svelte-4algbe) li:where(.svelte-4algbe){display:block;list-style:none;margin:0;padding:0}.dropdown_items.svelte-4algbe ul:where(.svelte-4algbe) li:where(.svelte-4algbe) button:where(.svelte-4algbe){display:flex;align-items:center;justify-items:flex-start;width:100%;min-width:5rem;padding:.5rem;font-size:.75rem;color:var(--c-basic-900);font-weight:500;text-transform:capitalize;white-space:nowrap}.dropdown_items.svelte-4algbe ul:where(.svelte-4algbe) li:where(.svelte-4algbe) button:where(.svelte-4algbe) .dropdown_item-dot:where(.svelte-4algbe){display:block;margin:0 .5rem 0 0;height:.313rem;width:.313rem;background-color:transparent;border-radius:50%}.dropdown_items.svelte-4algbe ul:where(.svelte-4algbe) li:where(.svelte-4algbe) button.active:where(.svelte-4algbe) .dropdown_item-dot:where(.svelte-4algbe),.dropdown_items.svelte-4algbe ul:where(.svelte-4algbe) li:where(.svelte-4algbe) button.active:where(.svelte-4algbe):hover .dropdown_item-dot:where(.svelte-4algbe){background-color:var(--c-primary)}.dropdown_items.svelte-4algbe ul:where(.svelte-4algbe) li:where(.svelte-4algbe) button:where(.svelte-4algbe):hover,.dropdown_items.svelte-4algbe ul:where(.svelte-4algbe) li:where(.svelte-4algbe) button:where(.svelte-4algbe):focus-visible{color:var(--c-primary);background-color:var(--c-basic-100)}.dropdown_items.svelte-4algbe ul:where(.svelte-4algbe) li:where(.svelte-4algbe) button.active:where(.svelte-4algbe){color:var(--c-primary);font-weight:500;background-color:var(--c-primary-bg);border-color:var(--c-primary)}.dropdown.svelte-4algbe:hover>.dropdown_items:where(.svelte-4algbe),.dropdown.svelte-4algbe:focus-visible>.dropdown_items:where(.svelte-4algbe){display:block;visibility:visible}.topbar.svelte-12qmtz{--h-topbar: 2.25rem;margin:.375rem 0;width:100%;height:var(--h-topbar);background-color:var(--c-topbar-bg);border-radius:.625rem}.topbar_container.svelte-12qmtz{display:flex;justify-content:space-between;width:100%;height:100%;padding:0;z-index:999999}.topbar_nav.svelte-12qmtz{display:flex;align-items:center}.topbar_btn.svelte-12qmtz{display:flex;align-items:center;padding:0 .375rem;height:var(--h-topbar);background:none}.topbar_btn.svelte-12qmtz:hover,.topbar_btn.svelte-12qmtz:focus-visible{background-color:var(--c-basic-100)}.is-hidden.svelte-12qmtz{position:absolute!important;overflow:hidden;width:1px;height:1px;padding:0;border:0;clip:rect(1px,1px,1px,1px)}.topbar_btn.svelte-12qmtz svg:where(.svelte-12qmtz){height:1.125rem;color:var(--c-basic-700)}.topbar_btn.svelte-12qmtz:hover svg:where(.svelte-12qmtz),.topbar_btn.svelte-12qmtz:focus-visible svg:where(.svelte-12qmtz){color:var(--c-primary)}.is-first-btn.svelte-12qmtz{border-radius:.5rem 0 0 .5rem}.is-last-btn.svelte-12qmtz{border-radius:0 .5rem .5rem 0}@media (max-height: 499px){.bookmark_btn.svelte-12qmtz{display:none}}@media (max-width: 499px){.bookmark_btn.svelte-12qmtz,.openexternal_btn.svelte-12qmtz{display:none}}.stagesize-value.svelte-12qmtz{display:none}@media (min-width: 640px){.stagesize-value.svelte-12qmtz{display:inline-flex;align-items:center;padding:0 1rem;font-size:.75rem}.stagesize-input.svelte-12qmtz{padding:.25rem .375rem;width:42px;font-size:.75rem;font-family:ui-monospace,Menlo,Monaco,Cascadia Mono,Segoe UI Mono,Roboto Mono,Oxygen Mono,"Ubuntu Monospace",Source Code Pro,Fira Mono,Droid Sans Mono,Courier New,"monospace";color:var(--c-basic-600);text-align:right;background-color:transparent;border:1px solid var(--c-primary);border-radius:.125rem}.stagesize-input.svelte-12qmtz:focus-visible{background-color:var(--c-primary-bg)}.stagesize-input.svelte-12qmtz:disabled{border-color:transparent}.stagesize-value-multi_sign.svelte-12qmtz{margin:0 .25rem;color:var(--c-basic-700)}}.stagesize-nav.svelte-12qmtz{display:none}@media (min-width: 1280px){.stagesize-nav.svelte-12qmtz{position:relative;display:inline-flex;background-color:var(--c-basic-100)}.stagesize-nav.svelte-12qmtz button:where(.svelte-12qmtz){position:relative;display:flex;justify-content:center;flex-direction:column;align-self:center;height:var(--h-topbar);margin:0;padding:0 .25rem;background:none;overflow:hidden}.stagesize-nav.svelte-12qmtz button:where(.svelte-12qmtz):hover,.stagesize-nav.svelte-12qmtz button:where(.svelte-12qmtz):focus-visible{background-color:var(--c-basic-150)}.stagesize-nav.svelte-12qmtz svg:where(.svelte-12qmtz){height:1.125rem;color:var(--c-basic-700);transition:.2s}.stagesize-nav.svelte-12qmtz button:where(.svelte-12qmtz):hover svg:where(.svelte-12qmtz),.stagesize-nav.svelte-12qmtz button:where(.svelte-12qmtz):focus-visible svg:where(.svelte-12qmtz),.stagesize-nav.svelte-12qmtz button.active:where(.svelte-12qmtz) svg:where(.svelte-12qmtz){color:var(--c-primary)}.stagesize-nav.svelte-12qmtz svg.landscape:where(.svelte-12qmtz){transform:rotate(90deg);transition:.2s}.stagesize-nav.svelte-12qmtz .dot:where(.svelte-12qmtz){display:block;position:absolute;left:50%;bottom:.125rem;transform:translate(-50%);height:.313rem;width:.313rem;background-color:transparent;border-radius:50%}.stagesize-nav.svelte-12qmtz button.active:where(.svelte-12qmtz){background-color:var(--c-primary-bg)}.stagesize-nav.svelte-12qmtz button.active:where(.svelte-12qmtz) .dot:where(.svelte-12qmtz){background-color:var(--c-primary)}}button.topbar_btn.active.svelte-12qmtz{background-color:var(--c-primary-bg)}button.topbar_btn.active.svelte-12qmtz .dot:where(.svelte-12qmtz){background-color:var(--c-primary)}.sidebar.svelte-yh1ir7{flex-grow:0;flex-shrink:0}.garden.svelte-yh1ir7{display:flex;flex-direction:row;flex-wrap:nowrap;flex-grow:1;margin:0;padding:0 .375rem;width:100vw;height:100vh;overflow:hidden;background-color:var(--c-bg-body)}.main.svelte-yh1ir7{display:flex;flex-direction:column;width:100%;height:100vh;overflow-y:auto}.message.svelte-yh1ir7{display:inline-block;margin:1rem;padding:1rem;background-color:#fff;border-radius:.625rem}.click-completed.svelte-yh1ir7{margin:0 0 .75rem;font-size:120%;font-weight:500}.instruction.svelte-yh1ir7 button:where(.svelte-yh1ir7){padding:.125rem .75rem;background:var(--c-basic-150);border-radius:.375rem;font-size:90%;color:var(--c-basic-900);font-weight:600;text-transform:uppercase}*,:before,:after{box-sizing:border-box;border:0 solid #fff}*:focus,*:focus:not(:focus-visible){outline:none}html{-webkit-text-size-adjust:100%;scroll-behavior:smooth;background-color:var(--c-bg-body)}body{margin:0;min-height:100vh;text-rendering:optimizeSpeed;line-height:1}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}a{text-decoration-skip-ink:auto}img,picture,embed,object,video{max-width:100%;width:auto;height:auto}img,video,canvas,audio,iframe,embed,object{display:block;border:none}input,button,textarea,select{font:inherit}@media (prefers-reduced-motion: reduce){*,*:before,*:after{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important;scroll-behavior:auto!important}}:root{--c-primary: hsl(185, 80%, 40%);--c-primary-bg: hsl(185, 100%, 95%);--c-basic-0: hsl(216, 20%, 100%);--c-basic-50: hsl(216, 20%, 98%);--c-basic-75: hsl(216, 20%, 96%);--c-basic-100: hsl(216, 20%, 94%);--c-basic-150: hsl(216, 20%, 90%);--c-basic-200: hsl(216, 20%, 87%);--c-basic-250: hsl(216, 20%, 84%);--c-basic-300: hsl(216, 20%, 81%);--c-basic-400: hsl(216, 20%, 64%);--c-basic-500: hsl(216, 20%, 46%);--c-basic-600: hsl(216, 20%, 32%);--c-basic-700: hsl(216, 20%, 25%);--c-basic-800: hsl(216, 20%, 15%);--c-basic-900: hsl(216, 20%, 10%);--c-bg-body: var(--c-basic-200);--c-topbar-bg: var(--c-basic-0);--c-sidebar-bg: var(--c-basic-0);--c-dragbar-bg: var(--c-basic-100);--c-dragbar-bg-hover: var(--c-basic-200);--c-dragbar-icon: var(--c-basic-400)}[data-theme=dark]{--c-primary: hsl(185, 80%, 70%);--c-primary-bg: hsl(185, 80%, 17%);--c-basic-0: hsl(216, 30%, 5%);--c-basic-50: hsl(216, 30%, 10%);--c-basic-75: hsl(216, 30%, 14%);--c-basic-100: hsl(216, 30%, 18%);--c-basic-150: hsl(216, 30%, 22%);--c-basic-200: hsl(216, 30%, 25%);--c-basic-250: hsl(216, 30%, 30%);--c-basic-300: hsl(216, 30%, 33%);--c-basic-400: hsl(216, 30%, 46%);--c-basic-500: hsl(216, 30%, 64%);--c-basic-600: hsl(216, 30%, 83%);--c-basic-700: hsl(216, 30%, 90%);--c-basic-800: hsl(216, 30%, 96%);--c-basic-900: hsl(216, 30%, 98%);--c-bg-body: var(--c-basic-150);--c-topbar-bg: var(--c-basic-0);--c-sidebar-bg: var(--c-basic-0);--c-dragbar-bg: var(--c-basic-250);--c-dragbar-bg-hover: var(--c-basic-150);--c-dragbar-icon: var(--c-basic-500)}body{font-family:system-ui,-apple-system,Segoe UI,Roboto,Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji";text-shadow:1px 1px 1px rgba(0,0,0,.004);-webkit-font-smoothing:antialiased;-moz-font-smoothing:antialiased}h1,h2,h3,h4,h5,h6{margin:0;color:var(--c-basic-600);line-height:1.2}p{margin:.5rem 0;font-size:.875rem;color:var(--c-basic-600);line-height:1.5}li{font-size:.875rem;color:var(--c-basic-600);line-height:1.5}a,a:visited{font-size:.875rem;color:var(--c-primary);line-height:1.5;text-decoration:underline;text-decoration-skip-ink:auto}nav ol,nav ul{margin:0;padding:0;list-style:none}nav li{display:block;margin:0;padding:0}nav a{display:block;margin:0;padding:0;text-decoration:none}button{cursor:pointer;background-color:transparent;border:none}input[type=number]::-webkit-inner-spin-button,input[type=number]::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}input[type=number]{-moz-appearance:textfield;appearance:textfield;margin:0}
19
+ */[data-theme=dark] .hljs{color:#c9d1d9}[data-theme=dark] .hljs-doctag,[data-theme=dark] .hljs-keyword,[data-theme=dark] .hljs-meta .hljs-keyword,[data-theme=dark] .hljs-template-tag,[data-theme=dark] .hljs-template-variable,[data-theme=dark] .hljs-type,[data-theme=dark] .hljs-variable.language_{color:#ff7b72}[data-theme=dark] .hljs-title,[data-theme=dark] .hljs-title.class_,[data-theme=dark] .hljs-title.class_.inherited__,[data-theme=dark] .hljs-title.function_{color:#d2a8ff}[data-theme=dark] .hljs-attr,[data-theme=dark] .hljs-attribute,[data-theme=dark] .hljs-literal,[data-theme=dark] .hljs-meta,[data-theme=dark] .hljs-number,[data-theme=dark] .hljs-operator,[data-theme=dark] .hljs-variable,[data-theme=dark] .hljs-selector-attr,[data-theme=dark] .hljs-selector-class,[data-theme=dark] .hljs-selector-id{color:#79c0ff}[data-theme=dark] .hljs-regexp,[data-theme=dark] .hljs-string,[data-theme=dark] .hljs-meta .hljs-string{color:#a5d6ff}[data-theme=dark] .hljs-built_in,[data-theme=dark] .hljs-symbol{color:#ffa657}[data-theme=dark] .hljs-comment,[data-theme=dark] .hljs-code,[data-theme=dark] .hljs-formula{color:#8b949e}[data-theme=dark] .hljs-name,[data-theme=dark] .hljs-quote,[data-theme=dark] .hljs-selector-tag,[data-theme=dark] .hljs-selector-pseudo{color:#7ee787}[data-theme=dark] .hljs-subst{color:#c9d1d9}[data-theme=dark] .hljs-section{color:#1f6feb;font-weight:700}[data-theme=dark] .hljs-bullet{color:#f2cc60}[data-theme=dark] .hljs-emphasis{color:#c9d1d9;font-style:italic}[data-theme=dark] .hljs-strong{color:#c9d1d9;font-weight:700}[data-theme=dark] .hljs-addition{color:#aff5b4;background-color:#033a16}[data-theme=dark] .hljs-deletion{color:#ffdcd7;background-color:#67060c}.stage_iframe.svelte-17n05ij{display:block;align-self:center;margin:auto;height:100%;width:100%;background-color:var(--c-basic-0)}.panel.svelte-17n05ij{display:flex;flex-direction:column;flex-wrap:nowrap;position:relative;margin-bottom:.375rem;height:100%;width:100%;background-color:var(--c-basic-0);border-top:0;border-radius:0 0 .625rem .625rem;overflow-y:auto}.component_link.svelte-1cnyrt6{display:flex;margin:0;padding:.188rem 0;width:100%;height:1.375rem;text-transform:initial;font-size:.813rem;color:var(--c-basic-600);line-height:1.2;font-weight:400}.component_link.svelte-1cnyrt6:hover,.component_link.svelte-1cnyrt6:focus-visible{color:var(--c-primary);font-weight:500;background-color:var(--c-basic-100)}.component_link-container.svelte-1cnyrt6{display:flex;align-items:center}.component_link.svelte-1cnyrt6 .component_dot:where(.svelte-1cnyrt6){margin:0 .5rem 0 -.219rem;height:.375rem;width:.375rem!important;background-color:transparent;border-radius:50%}.component_link.selected.svelte-1cnyrt6 .component_dot:where(.svelte-1cnyrt6){background-color:var(--c-primary)}.component_link.selected.svelte-1cnyrt6{margin-left:-1px;color:var(--c-primary);font-weight:600;background-color:var(--c-primary-bg);border-left:1px solid var(--c-primary)}.component_icon.svelte-1cnyrt6{display:flex;align-items:center;margin:0 .5rem 0 0;color:var(--c-basic-400)}.component_label.svelte-1cnyrt6{margin-right:.5rem;overflow:hidden;white-space:nowrap}.bookmarks.svelte-qxg2ml{display:none}@media (min-height: 500px) and (min-width: 500px){.bookmarks.svelte-qxg2ml{display:block}}.bookmarks_title.svelte-qxg2ml{display:flex;justify-content:flex-start;align-items:center;width:100%;margin:0;padding:.5rem .688rem .375rem}.bookmarks_title-icon.svelte-qxg2ml{display:flex;align-items:center;margin-right:.375rem;color:var(--c-primary)}.bookmarks_title-label.svelte-qxg2ml{display:flex;width:100%;font-size:.813rem;color:var(--c-basic-900);font-weight:600;text-transform:uppercase;overflow:hidden;white-space:nowrap}.border-btm.svelte-qxg2ml{margin:1rem 0 .5rem;height:1px;border-bottom:1px solid var(--c-bg-body)}.components.svelte-qxg2ml{margin-left:1.063rem;width:100%;border-left:1px solid var(--c-basic-250)}.component.svelte-qxg2ml{display:flex;height:1.375rem;width:100%;z-index:1}.close.svelte-qxg2ml{position:absolute;display:flex;justify-content:flex-end;align-items:center;right:0;width:1.75rem;height:1.375rem;z-index:9;background-color:var(--c-sidebar-bg)}.component:has(.component_link:hover) .close,.component:has(.component_link:focus-visible) .close{background-color:var(--c-basic-100)}.component:has(.close:hover) .component_link.selected,.component:has(.component_link.selected) .close{background-color:var(--c-primary-bg)!important}.component:has(.close:hover) .component_link,.close.svelte-qxg2ml:hover{background-color:var(--c-basic-100)}.close-icon.svelte-qxg2ml{display:block;color:var(--c-basic-600)}.close.svelte-qxg2ml:hover .close-icon:where(.svelte-qxg2ml),.close.svelte-qxg2ml:focus-visible .close-icon:where(.svelte-qxg2ml){color:var(--c-primary);stroke-width:4}.components.svelte-1nn9bvq{margin-left:1.063rem;border-left:1px solid var(--c-basic-250)}.component.svelte-1nn9bvq{height:1.375rem}.level-1.svelte-1nn9bvq{width:100%;margin:0;padding:0;border:none}.folder.svelte-1nn9bvq{display:block;margin:0}.folder_btn.svelte-1nn9bvq{display:flex;justify-content:flex-start;align-items:center;width:100%;margin:0;padding:.5rem .688rem .375rem}.folder_label.svelte-1nn9bvq{display:flex;width:100%;font-size:.813rem;color:var(--c-basic-900);font-weight:600;text-transform:uppercase;overflow:hidden;white-space:nowrap}.folder_btn.svelte-1nn9bvq:hover{background-color:var(--c-basic-100)}.folder_btn.svelte-1nn9bvq:hover .folder_label:where(.svelte-1nn9bvq){color:var(--c-primary)}.folder_btn.svelte-1nn9bvq:focus-visible{color:var(--c-primary);outline:none;background-color:var(--c-basic-100)}.folder_arrow.svelte-1nn9bvq{display:flex;align-items:center;width:.938rem;height:1.25rem;transition:.2s;margin-right:.375rem;color:var(--c-basic-900)}.folder_arrow.unfolded_icon.svelte-1nn9bvq{transform:rotate(180deg);transition:.2s}.folder_icon.svelte-1nn9bvq{display:flex;align-items:center;margin-right:.375rem;color:var(--c-primary)}.btn_level-3.svelte-1nn9bvq .folder_label:where(.svelte-1nn9bvq){font-size:.813rem}.filter_list.svelte-1nn9bvq .highlight{padding:0 .125rem;color:var(--c-primary);font-weight:700}.sidebar_container.svelte-1oee4bz{--w-sidebar: 260px;display:flex;flex-direction:column;position:relative;margin:.375rem 0;width:0;max-width:var(--w-sidebar);height:calc(100vh - .75rem);background-color:var(--c-sidebar-bg);border-radius:.625rem;transition:width .1s;overflow:hidden}.show-sidebar.svelte-1oee4bz{margin:.375rem .375rem .375rem 0;width:var(--w-sidebar);box-sizing:border-box}.project-identifier.svelte-1oee4bz{position:relative;display:flex;flex-shrink:0;flex-direction:row;justify-content:center;align-items:center;padding:.25rem .688rem;margin:0 0 .125rem;width:var(--w-sidebar);height:2.25rem;background-color:var(--c-sidebar);inline-size:var(--w-sidebar);overflow:hidden;white-space:nowrap;font-size:1.25rem;color:var(--c-primary);text-decoration:none;font-weight:900;line-height:1}.project-identifier.has-logo.svelte-1oee4bz{height:auto}.project-identifier.svelte-1oee4bz:focus-visible{color:var(--c-basic-500)}.project-identifier.svelte-1oee4bz span:where(.svelte-1oee4bz){overflow:hidden}.filter.svelte-1oee4bz{display:flex;flex-shrink:0;margin:0 0 .25rem;padding:.25rem .688rem;height:2.25rem}.filter_input.svelte-1oee4bz{padding:.125rem .125rem .125rem .688rem;width:100%;height:100%;color:var(--c-basic-900);background-color:var(--c-basic-0);border:1px solid var(--c-primary);border-radius:1.75rem}input.filter_input[type=search].svelte-1oee4bz{font-size:.813rem}input[type=search].svelte-1oee4bz::-webkit-search-cancel-button{-webkit-appearance:none}.filter_input.svelte-1oee4bz::placeholder{font-size:.813rem;color:var(--c-basic-500)}.filter_input.svelte-1oee4bz:focus-visible{background-color:var(--c-primary-bg)}.filter_zero-results.svelte-1oee4bz{width:var(--w-sidebar);padding:.5rem .688rem .375rem;text-transform:initial;font-size:.813rem;color:var(--c-basic-600);font-weight:400;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.components-nav.svelte-1oee4bz{display:flex;flex-shrink:1;overflow:hidden;visibility:visible;width:var(--w-sidebar);overflow-y:auto;margin:0 0 1rem}.controls.svelte-1oee4bz{display:none}@media (min-height: 35rem){.controls.svelte-1oee4bz{display:block;flex-shrink:0;width:var(--w-sidebar);height:103px;bottom:.375rem;padding:0;background-color:var(--c-sidebar);border-top:1px solid var(--c-bg-body);border-bottom-right-radius:.5rem;border-bottom-left-radius:.5rem;overflow:hidden}}.controls_btn.svelte-1oee4bz{display:flex;justify-content:flex-start;align-items:center;width:100%;height:2.125rem;margin:0;padding:0 .688rem;text-align:left}.controls_btn.svelte-1oee4bz:hover,.controls_btn.svelte-1oee4bz:focus-visible{background-color:var(--c-basic-100)}.controls_btn-icon.svelte-1oee4bz{margin:0;color:var(--c-basic-700)}.controls_btn-label.svelte-1oee4bz{position:relative;align-self:center;margin-left:.75rem;width:100%;color:var(--c-basic-900);font-size:.875rem;font-weight:400}.controls_btn.svelte-1oee4bz:hover .controls_btn-label:where(.svelte-1oee4bz),.controls_btn.svelte-1oee4bz:focus-visible .controls_btn-label:where(.svelte-1oee4bz),.controls_btn.svelte-1oee4bz:hover .controls_btn-icon:where(.svelte-1oee4bz),.controls_btn.svelte-1oee4bz:focus-visible .controls_btn-icon:where(.svelte-1oee4bz){color:var(--c-primary)}.dropdown.svelte-4algbe{position:relative;display:inline-block;z-index:99}.dropdown_items.svelte-4algbe{visibility:hidden;position:absolute;left:0;padding:.375rem 0 0;z-index:9}.dropdown_items-right.svelte-4algbe{left:unset;right:0}.dropdown_items.svelte-4algbe ul:where(.svelte-4algbe){margin:0;padding:0;background-color:var(--c-basic-50);filter:drop-shadow(0px 5px 5px rgba(0,0,0,.05)) drop-shadow(0 1px 3px rgba(0,0,0,.1));border-radius:.5rem;overflow:hidden}.dropdown_items.svelte-4algbe ul:where(.svelte-4algbe) li:where(.svelte-4algbe){display:block;list-style:none;margin:0;padding:0}.dropdown_items.svelte-4algbe ul:where(.svelte-4algbe) li:where(.svelte-4algbe) button:where(.svelte-4algbe){display:flex;align-items:center;justify-items:flex-start;width:100%;min-width:5rem;padding:.5rem;font-size:.75rem;color:var(--c-basic-900);font-weight:500;text-transform:capitalize;white-space:nowrap}.dropdown_items.svelte-4algbe ul:where(.svelte-4algbe) li:where(.svelte-4algbe) button:where(.svelte-4algbe) .dropdown_item-dot:where(.svelte-4algbe){display:block;margin:0 .5rem 0 0;height:.313rem;width:.313rem;background-color:transparent;border-radius:50%}.dropdown_items.svelte-4algbe ul:where(.svelte-4algbe) li:where(.svelte-4algbe) button.active:where(.svelte-4algbe) .dropdown_item-dot:where(.svelte-4algbe),.dropdown_items.svelte-4algbe ul:where(.svelte-4algbe) li:where(.svelte-4algbe) button.active:where(.svelte-4algbe):hover .dropdown_item-dot:where(.svelte-4algbe){background-color:var(--c-primary)}.dropdown_items.svelte-4algbe ul:where(.svelte-4algbe) li:where(.svelte-4algbe) button:where(.svelte-4algbe):hover,.dropdown_items.svelte-4algbe ul:where(.svelte-4algbe) li:where(.svelte-4algbe) button:where(.svelte-4algbe):focus-visible{color:var(--c-primary);background-color:var(--c-basic-100)}.dropdown_items.svelte-4algbe ul:where(.svelte-4algbe) li:where(.svelte-4algbe) button.active:where(.svelte-4algbe){color:var(--c-primary);font-weight:500;background-color:var(--c-primary-bg);border-color:var(--c-primary)}.dropdown.svelte-4algbe:hover>.dropdown_items:where(.svelte-4algbe),.dropdown.svelte-4algbe:focus-visible>.dropdown_items:where(.svelte-4algbe){display:block;visibility:visible}.topbar.svelte-y9l547{--h-topbar: 2.25rem;margin:.375rem 0;width:100%;height:var(--h-topbar);background-color:var(--c-topbar-bg);border-radius:.625rem}.topbar_container.svelte-y9l547{display:flex;justify-content:space-between;width:100%;height:100%;padding:0;z-index:999999}.topbar_nav.svelte-y9l547{display:flex;align-items:center}.topbar_btn.svelte-y9l547{display:flex;align-items:center;padding:0 .375rem;height:var(--h-topbar);background:none}.topbar_btn.svelte-y9l547:hover,.topbar_btn.svelte-y9l547:focus-visible{background-color:var(--c-basic-100)}.is-hidden.svelte-y9l547{position:absolute!important;overflow:hidden;width:1px;height:1px;padding:0;border:0;clip:rect(1px,1px,1px,1px)}.topbar_btn.svelte-y9l547 svg:where(.svelte-y9l547){height:1.125rem;color:var(--c-basic-700)}.topbar_btn.svelte-y9l547:hover svg:where(.svelte-y9l547),.topbar_btn.svelte-y9l547:focus-visible svg:where(.svelte-y9l547){color:var(--c-primary)}.is-first-btn.svelte-y9l547{border-radius:.5rem 0 0 .5rem}.is-last-btn.svelte-y9l547{border-radius:0 .5rem .5rem 0}@media (max-height: 499px){.bookmark_btn.svelte-y9l547,.reveal_btn.svelte-y9l547{display:none}}@media (max-width: 499px){.bookmark_btn.svelte-y9l547,.reveal_btn.svelte-y9l547,.openexternal_btn.svelte-y9l547{display:none}}.stagesize-value.svelte-y9l547{display:none}@media (min-width: 640px){.stagesize-value.svelte-y9l547{display:inline-flex;align-items:center;padding:0 1rem;font-size:.75rem}.stagesize-input.svelte-y9l547{padding:.25rem .375rem;width:42px;font-size:.75rem;font-family:ui-monospace,Menlo,Monaco,Cascadia Mono,Segoe UI Mono,Roboto Mono,Oxygen Mono,"Ubuntu Monospace",Source Code Pro,Fira Mono,Droid Sans Mono,Courier New,"monospace";color:var(--c-basic-600);text-align:right;background-color:transparent;border:1px solid var(--c-primary);border-radius:.125rem}.stagesize-input.svelte-y9l547:focus-visible{background-color:var(--c-primary-bg)}.stagesize-input.svelte-y9l547:disabled{border-color:transparent}.stagesize-value-multi_sign.svelte-y9l547{margin:0 .25rem;color:var(--c-basic-700)}}.stagesize-nav.svelte-y9l547{display:none}@media (min-width: 1280px){.stagesize-nav.svelte-y9l547{position:relative;display:inline-flex;background-color:var(--c-basic-100)}.stagesize-nav.svelte-y9l547 button:where(.svelte-y9l547){position:relative;display:flex;justify-content:center;flex-direction:column;align-self:center;height:var(--h-topbar);margin:0;padding:0 .25rem;background:none;overflow:hidden}.stagesize-nav.svelte-y9l547 button:where(.svelte-y9l547):hover,.stagesize-nav.svelte-y9l547 button:where(.svelte-y9l547):focus-visible{background-color:var(--c-basic-150)}.stagesize-nav.svelte-y9l547 svg:where(.svelte-y9l547){height:1.125rem;color:var(--c-basic-700);transition:.2s}.stagesize-nav.svelte-y9l547 button:where(.svelte-y9l547):hover svg:where(.svelte-y9l547),.stagesize-nav.svelte-y9l547 button:where(.svelte-y9l547):focus-visible svg:where(.svelte-y9l547),.stagesize-nav.svelte-y9l547 button.active:where(.svelte-y9l547) svg:where(.svelte-y9l547){color:var(--c-primary)}.stagesize-nav.svelte-y9l547 svg.landscape:where(.svelte-y9l547){transform:rotate(90deg);transition:.2s}.stagesize-nav.svelte-y9l547 .dot:where(.svelte-y9l547){display:block;position:absolute;left:50%;bottom:.125rem;transform:translate(-50%);height:.313rem;width:.313rem;background-color:transparent;border-radius:50%}.stagesize-nav.svelte-y9l547 button.active:where(.svelte-y9l547){background-color:var(--c-primary-bg)}.stagesize-nav.svelte-y9l547 button.active:where(.svelte-y9l547) .dot:where(.svelte-y9l547){background-color:var(--c-primary)}}button.topbar_btn.active.svelte-y9l547{background-color:var(--c-primary-bg)}button.topbar_btn.active.svelte-y9l547 .dot:where(.svelte-y9l547){background-color:var(--c-primary)}.sidebar.svelte-yh1ir7{flex-grow:0;flex-shrink:0}.garden.svelte-yh1ir7{display:flex;flex-direction:row;flex-wrap:nowrap;flex-grow:1;margin:0;padding:0 .375rem;width:100vw;height:100vh;overflow:hidden;background-color:var(--c-bg-body)}.main.svelte-yh1ir7{display:flex;flex-direction:column;width:100%;height:100vh;overflow-y:auto}.message.svelte-yh1ir7{display:inline-block;margin:1rem;padding:1rem;background-color:#fff;border-radius:.625rem}.click-completed.svelte-yh1ir7{margin:0 0 .75rem;font-size:120%;font-weight:500}.instruction.svelte-yh1ir7 button:where(.svelte-yh1ir7){padding:.125rem .75rem;background:var(--c-basic-150);border-radius:.375rem;font-size:90%;color:var(--c-basic-900);font-weight:600;text-transform:uppercase}*,:before,:after{box-sizing:border-box;border:0 solid #fff}*:focus,*:focus:not(:focus-visible){outline:none}html{-webkit-text-size-adjust:100%;scroll-behavior:smooth;background-color:var(--c-bg-body)}body{margin:0;min-height:100vh;text-rendering:optimizeSpeed;line-height:1}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}a{text-decoration-skip-ink:auto}img,picture,embed,object,video{max-width:100%;width:auto;height:auto}img,video,canvas,audio,iframe,embed,object{display:block;border:none}input,button,textarea,select{font:inherit}@media (prefers-reduced-motion: reduce){*,*:before,*:after{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important;scroll-behavior:auto!important}}:root{--c-primary: hsl(185, 80%, 40%);--c-primary-bg: hsl(185, 100%, 95%);--c-basic-0: hsl(216, 20%, 100%);--c-basic-50: hsl(216, 20%, 98%);--c-basic-75: hsl(216, 20%, 96%);--c-basic-100: hsl(216, 20%, 94%);--c-basic-150: hsl(216, 20%, 90%);--c-basic-200: hsl(216, 20%, 87%);--c-basic-250: hsl(216, 20%, 84%);--c-basic-300: hsl(216, 20%, 81%);--c-basic-400: hsl(216, 20%, 64%);--c-basic-500: hsl(216, 20%, 46%);--c-basic-600: hsl(216, 20%, 32%);--c-basic-700: hsl(216, 20%, 25%);--c-basic-800: hsl(216, 20%, 15%);--c-basic-900: hsl(216, 20%, 10%);--c-bg-body: var(--c-basic-200);--c-topbar-bg: var(--c-basic-0);--c-sidebar-bg: var(--c-basic-0);--c-dragbar-bg: var(--c-basic-100);--c-dragbar-bg-hover: var(--c-basic-200);--c-dragbar-icon: var(--c-basic-400)}[data-theme=dark]{--c-primary: hsl(185, 80%, 70%);--c-primary-bg: hsl(185, 80%, 17%);--c-basic-0: hsl(216, 30%, 5%);--c-basic-50: hsl(216, 30%, 10%);--c-basic-75: hsl(216, 30%, 14%);--c-basic-100: hsl(216, 30%, 18%);--c-basic-150: hsl(216, 30%, 22%);--c-basic-200: hsl(216, 30%, 25%);--c-basic-250: hsl(216, 30%, 30%);--c-basic-300: hsl(216, 30%, 33%);--c-basic-400: hsl(216, 30%, 46%);--c-basic-500: hsl(216, 30%, 64%);--c-basic-600: hsl(216, 30%, 83%);--c-basic-700: hsl(216, 30%, 90%);--c-basic-800: hsl(216, 30%, 96%);--c-basic-900: hsl(216, 30%, 98%);--c-bg-body: var(--c-basic-150);--c-topbar-bg: var(--c-basic-0);--c-sidebar-bg: var(--c-basic-0);--c-dragbar-bg: var(--c-basic-250);--c-dragbar-bg-hover: var(--c-basic-150);--c-dragbar-icon: var(--c-basic-500)}body{font-family:system-ui,-apple-system,Segoe UI,Roboto,Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji";text-shadow:1px 1px 1px rgba(0,0,0,.004);-webkit-font-smoothing:antialiased;-moz-font-smoothing:antialiased}h1,h2,h3,h4,h5,h6{margin:0;color:var(--c-basic-600);line-height:1.2}p{margin:.5rem 0;font-size:.875rem;color:var(--c-basic-600);line-height:1.5}li{font-size:.875rem;color:var(--c-basic-600);line-height:1.5}a,a:visited{font-size:.875rem;color:var(--c-primary);line-height:1.5;text-decoration:underline;text-decoration-skip-ink:auto}nav ol,nav ul{margin:0;padding:0;list-style:none}nav li{display:block;margin:0;padding:0}nav a{display:block;margin:0;padding:0;text-decoration:none}button{cursor:pointer;background-color:transparent;border:none}input[type=number]::-webkit-inner-spin-button,input[type=number]::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}input[type=number]{-moz-appearance:textfield;appearance:textfield;margin:0}
package/dist/index.html CHANGED
@@ -5,9 +5,9 @@
5
5
  <link rel="icon" href="/assets/favicon.svg" />
6
6
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
7
7
  <title>Gardenjs UI Component Explorer</title>
8
- <script type="module" crossorigin src="/assets/index-CRU5e1Zv.js"></script>
8
+ <script type="module" crossorigin src="/assets/index-Cxvk1O88.js"></script>
9
9
  <link rel="modulepreload" crossorigin href="/assets/props-DKVIKFn7.js">
10
- <link rel="stylesheet" crossorigin href="/assets/index-CT3BsFit.css">
10
+ <link rel="stylesheet" crossorigin href="/assets/index-DfGHKcnI.css">
11
11
  </head>
12
12
 
13
13
  <body>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gardenjs",
3
- "version": "1.6.4",
3
+ "version": "1.6.6",
4
4
  "description": "A component library explorer for UI development, testing and documentation.",
5
5
  "repository": {
6
6
  "type": "git",
@@ -47,7 +47,7 @@
47
47
  "./main.scss": "./src/client/assets/scss/main.scss"
48
48
  },
49
49
  "scripts": {
50
- "prepare": "husky",
50
+ "prepare": "test -d .git && husky install || true",
51
51
  "build": "vite build",
52
52
  "dev": "vite",
53
53
  "preview": "vite preview",
@@ -30,6 +30,7 @@
30
30
  updateStageHeight,
31
31
  updateStageWidth,
32
32
  updateStageRect,
33
+ resetStage,
33
34
  sidebarExpanded,
34
35
  toggleExpandSidebar,
35
36
  toggleShowInspector,
@@ -43,15 +44,18 @@
43
44
  } from './logic/stage.js'
44
45
  import {
45
46
  nodes,
46
- rootNodesExpanded,
47
+ treeCollapsed,
47
48
  toggleFolder,
48
- toggleRootFolders,
49
+ collapseTree,
50
+ expandTree,
51
+ navigateToLeafNode,
49
52
  filterNavTree,
50
53
  updateFilter,
51
54
  updateNavTree,
52
55
  updateSelectedComponent,
53
56
  toggleBookmark,
54
57
  selectedNode,
58
+ selectedNodeVisibleInTree,
55
59
  bookmarks,
56
60
  } from './logic/navTree.js'
57
61
  import {
@@ -60,7 +64,6 @@
60
64
  componentName,
61
65
  selectedExample,
62
66
  updateDasMap,
63
- currentRoute,
64
67
  } from './logic/routing.js'
65
68
 
66
69
  let baseurl = '/garden'
@@ -88,7 +91,7 @@
88
91
  }
89
92
  })
90
93
  $effect(() => {
91
- updateSelectedComponent($currentRoute, $componentName)
94
+ updateSelectedComponent($componentName)
92
95
  handleSelectionChanged()
93
96
  })
94
97
 
@@ -101,6 +104,7 @@
101
104
 
102
105
  function openInTab() {
103
106
  const targetWindow = window.open('/frame.html', '_blank')
107
+ if (!targetWindow) return
104
108
  targetWindow.onload = () => {
105
109
  targetWindow.postMessage(
106
110
  {
@@ -139,13 +143,15 @@
139
143
  filter={$filterNavTree}
140
144
  nodes={$nodes}
141
145
  panelExpanded={$panelExpanded}
142
- rootNodesExpanded={$rootNodesExpanded}
146
+ treeCollapsed={$treeCollapsed}
143
147
  sidebarExpanded={$sidebarExpanded}
148
+ onLogoClicked={resetStage}
144
149
  onToggleBookmark={toggleBookmark}
145
150
  onToggleExpandPanel={toggleExpandPanel}
146
151
  onToggleFoldStatusOfNode={toggleFolder}
147
- onToggleRootFolders={toggleRootFolders}
148
152
  onUpdateFilter={updateFilter}
153
+ onCollapseTree={collapseTree}
154
+ onExpandTree={expandTree}
149
155
  />
150
156
  </div>
151
157
  <div class="main">
@@ -154,6 +160,7 @@
154
160
  landscape={$landscape}
155
161
  node={$selectedNode}
156
162
  showGrid={$showGrid}
163
+ nodeVisibleInExplorer={$selectedNodeVisibleInTree}
157
164
  showInspector={$showInspector}
158
165
  sidebarExpanded={$sidebarExpanded}
159
166
  stageHeight={$stageHeight}
@@ -175,6 +182,7 @@
175
182
  onToggleOrientation={toggleOrientation}
176
183
  onToggleShowGrid={toggleShowGrid}
177
184
  onToggleShowInspector={toggleShowInspector}
185
+ onRevealInExplorer={() => navigateToLeafNode($selectedNode?.href)}
178
186
  />
179
187
  <Stage
180
188
  appTheme={$appTheme}
@@ -17,6 +17,9 @@
17
17
  $effect(() => {
18
18
  if (element && !init) {
19
19
  init = true
20
+ if (topHeight && maxHeight) {
21
+ return
22
+ }
20
23
  const elementHeight = element.offsetHeight
21
24
  onSetMaxHeight(elementHeight)
22
25
  onSetTopHeight(Math.round(elementHeight * 0.7))
@@ -14,15 +14,15 @@
14
14
  let dragType = ''
15
15
 
16
16
  const paneHeightWithUnit = $derived.by(() => {
17
- if (Number.isInteger(paneHeight) && !disabled) {
18
- return Math.min(paneHeight, maxHeight) + 'px'
17
+ if (Number.isInteger(Number(paneHeight)) && !disabled) {
18
+ return Math.min(Number(paneHeight), Number(maxHeight)) + 'px'
19
19
  }
20
20
  return maxHeight + 'px'
21
21
  })
22
22
 
23
23
  const paneWidthWithUnit = $derived.by(() => {
24
- if (Number.isInteger(paneWidth)) {
25
- return Math.min(paneWidth, maxWidth) + 'px'
24
+ if (Number.isInteger(Number(paneWidth))) {
25
+ return Math.min(Number(paneWidth), Number(maxWidth)) + 'px'
26
26
  }
27
27
  return maxWidth + 'px'
28
28
  })
@@ -12,18 +12,25 @@
12
12
  projectLogo,
13
13
  projectLogoDarkmode,
14
14
  projectTitle,
15
- rootNodesExpanded = true,
16
15
  sidebarExpanded = true,
16
+ treeCollapsed = false,
17
17
  onToggleBookmark,
18
18
  onToggleExpandPanel,
19
19
  onToggleFoldStatusOfNode,
20
- onToggleRootFolders,
20
+ onCollapseTree,
21
+ onExpandTree,
21
22
  onUpdateFilter,
23
+ onLogoClicked,
22
24
  } = $props()
23
25
  </script>
24
26
 
25
27
  <header class="sidebar_container" class:show-sidebar={sidebarExpanded}>
26
- <a class="project-identifier" class:has-logo={projectLogo} href="/">
28
+ <a
29
+ class="project-identifier"
30
+ class:has-logo={projectLogo}
31
+ href="/"
32
+ onclick={onLogoClicked}
33
+ >
27
34
  {#if projectLogoDarkmode && appTheme === 'dark'}
28
35
  <img
29
36
  src="/assets/{projectLogoDarkmode}"
@@ -68,17 +75,17 @@
68
75
  <!-- prettier-ignore -->
69
76
  <ul>
70
77
  <li>
71
- <button class="controls_btn" title={rootNodesExpanded ? 'Collapse' : 'Restore'} onclick={onToggleRootFolders}>
72
- {#if rootNodesExpanded}
73
- <svg class="controls_btn-icon" xmlns="http://www.w3.org/2000/svg" height="20" viewBox="0 0 24 24" width="20" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><path d="M7 20l5-5 5 5M7 4l5 5 5-5" /></svg>
74
- {:else}
78
+ <button class="controls_btn" title={treeCollapsed ? 'Expand' : 'Collapse'} onclick={() => treeCollapsed ? onExpandTree() : onCollapseTree()}>
79
+ {#if treeCollapsed}
75
80
  <svg class="controls_btn-icon" xmlns="http://www.w3.org/2000/svg" height="20" viewBox="0 0 24 24" width="20" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><path d="M7 15l5 5 5-5M7 9l5-5 5 5" /></svg>
81
+ {:else}
82
+ <svg class="controls_btn-icon" xmlns="http://www.w3.org/2000/svg" height="20" viewBox="0 0 24 24" width="20" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><path d="M7 20l5-5 5 5M7 4l5 5 5-5" /></svg>
76
83
  {/if}
77
- <span class="controls_btn-label">{rootNodesExpanded ? 'Collapse' : 'Expand'} Navigation</span>
84
+ <span class="controls_btn-label">{treeCollapsed ? 'Expand' : 'Collapse'} Explorer</span>
78
85
  </button>
79
86
  </li>
80
87
  <li>
81
- <button class="controls_btn" title={panelExpanded ? 'Collapse' : 'Restore'} onclick={onToggleExpandPanel}>
88
+ <button class="controls_btn" title={panelExpanded ? 'Collapse' : 'Expand'} onclick={onToggleExpandPanel}>
82
89
  {#if panelExpanded}
83
90
  <svg class="controls_btn-icon" xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><rect width="18" height="18" x="3" y="3" rx="2" ry="2" /><line x1="3" x2="21" y1="15" y2="15" /><path d="m15 8-3 3-3-3" /></svg>
84
91
  {:else}
@@ -5,6 +5,7 @@
5
5
  appTheme = 'default',
6
6
  landscape = false,
7
7
  node,
8
+ nodeVisibleInExplorer,
8
9
  showGrid,
9
10
  showInspector,
10
11
  sidebarExpanded = true,
@@ -25,6 +26,7 @@
25
26
  onToggleOrientation,
26
27
  onToggleShowGrid,
27
28
  onToggleShowInspector,
29
+ onRevealInExplorer,
28
30
  } = $props()
29
31
 
30
32
  let dark = $state(false)
@@ -53,7 +55,7 @@
53
55
  {/if}
54
56
  </button>
55
57
  {#if node}
56
- <button class="topbar_btn bookmark_btn" onclick={() => onToggleBookmark(node)}>
58
+ <button class="topbar_btn bookmark_btn" onclick={() => onToggleBookmark(node)} title={node.bookmark ? 'Remove from bookmarks' : 'Add to bookmarks'}>
57
59
  <span class="is-hidden">{node.bookmark ? 'Remove from bookmarks' : 'Add to bookmarks'}</span>
58
60
  {#if node.bookmark}
59
61
  <svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" fill="currentColor" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><path d="M12 2l3.09 6.26L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l6.91-1.01L12 2z"/></svg>
@@ -61,6 +63,12 @@
61
63
  <svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><path d="M12 2l3.09 6.26L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l6.91-1.01L12 2z"/></svg>
62
64
  {/if}
63
65
  </button>
66
+ {#if !nodeVisibleInExplorer}
67
+ <button class="topbar_btn reveal_btn" onclick={onRevealInExplorer} title="Reveal in explorer">
68
+ <span class="is-hidden">Reveal in explorer</span>
69
+ <svg xmlns="http://www.w3.org/2000/svg" width="24" viewBox="0 0 24 24" height="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><path d="M8 5h13m-8 7h8m-8 7h8M3 10a2 2 0 002 2h3"/><path d="M3 5v12a2 2 0 002 2h3"/></svg>
70
+ </button>
71
+ {/if}
64
72
  {/if}
65
73
  </div>
66
74
  <div class="topbar_nav">
@@ -211,12 +219,14 @@
211
219
 
212
220
  /* remove btns on small screens */
213
221
  @media (max-height: 499px) {
214
- .bookmark_btn {
222
+ .bookmark_btn,
223
+ .reveal_btn {
215
224
  display: none;
216
225
  }
217
226
  }
218
227
  @media (max-width: 499px) {
219
228
  .bookmark_btn,
229
+ .reveal_btn,
220
230
  .openexternal_btn {
221
231
  display: none;
222
232
  }
@@ -1,4 +1,4 @@
1
- import { writable, get } from 'svelte/store'
1
+ import { writable, get, derived } from 'svelte/store'
2
2
 
3
3
  function localStore(
4
4
  name,
@@ -16,24 +16,31 @@ function localStore(
16
16
  }
17
17
 
18
18
  export const nodes = writable([])
19
- export const rootNodesExpanded = writable(true)
20
19
  export const filterNavTree = writable()
21
20
  export const selectedNode = writable()
22
21
  export const bookmarks = localStore('bookmarks', [], JSON.parse, JSON.stringify)
23
22
 
24
23
  let initialized = false
25
- let currentRoute = ''
26
- let navtree = []
24
+ let navtree = writable([])
27
25
  let unfoldedNodes = []
28
26
  let selectedComponent
29
27
 
30
- function initializeTree(navtree) {
31
- const all = navtree.flatMap(getAllNodes)
32
- unfoldedNodes = all.reduce((acc, cur) => {
33
- acc[cur.key] = true
34
- return acc
35
- }, {})
36
- }
28
+ export const treeCollapsed = derived(navtree, ($navtree) => {
29
+ return !$navtree.some((node) => isUnfolded(node))
30
+ })
31
+
32
+ export const selectedNodeVisibleInTree = derived(
33
+ selectedNode,
34
+ ($selectedNode) => {
35
+ const parentNodes = []
36
+ let node = $selectedNode
37
+ while (node.parent) {
38
+ parentNodes.push(node.parent)
39
+ node = node.parent
40
+ }
41
+ return parentNodes.every((node) => isUnfolded(node))
42
+ }
43
+ )
37
44
 
38
45
  function getAllNodes(node) {
39
46
  return [node, ...getAllChildNodes(node)]
@@ -43,8 +50,7 @@ function getAllChildNodes(node) {
43
50
  return node.children ? node.children.flatMap(getAllNodes) : []
44
51
  }
45
52
 
46
- export function updateSelectedComponent(route, componentName) {
47
- currentRoute = route
53
+ export function updateSelectedComponent(componentName) {
48
54
  selectedComponent = componentName
49
55
  updateTree()
50
56
  updateBookmarks()
@@ -56,20 +62,22 @@ export function updateFilter(newFilter) {
56
62
  }
57
63
 
58
64
  export function updateNavTree(newNavTree) {
59
- navtree = newNavTree
65
+ navtree.set(newNavTree)
60
66
  if (!initialized) {
61
- initializeTree(navtree)
67
+ expandTree()
62
68
  cleanupBookmarks()
63
69
  initialized = true
64
70
  }
65
- nodes.set(transformNavTree(navtree))
71
+ nodes.set(transformNavTree(get(navtree)))
72
+ navtree.set(newNavTree)
66
73
  }
67
74
 
68
75
  function updateTree() {
69
- nodes.set(transformNavTree(navtree))
76
+ nodes.set(transformNavTree(get(navtree)))
77
+ navtree.set(get(navtree))
70
78
  }
71
79
 
72
- function transformNavTree(nodes, parentVisible) {
80
+ function transformNavTree(nodes, parent) {
73
81
  const filter = get(filterNavTree)?.toLowerCase()
74
82
  return nodes
75
83
  .map((child) => {
@@ -79,10 +87,11 @@ function transformNavTree(nodes, parentVisible) {
79
87
  const name =
80
88
  filter && filterMatches ? highlightFilterMatch(child.name) : child.name
81
89
  if (child.isLeaf) {
82
- const visible = parentVisible || filterMatches
90
+ const visible = parent?.visible || filterMatches
83
91
  const node = visible
84
92
  ? {
85
93
  ...child,
94
+ parent,
86
95
  name,
87
96
  selected: selectedComponent === child.key,
88
97
  isLeaf: true,
@@ -95,17 +104,19 @@ function transformNavTree(nodes, parentVisible) {
95
104
  }
96
105
  return node
97
106
  } else {
98
- const children = transformNavTree(
99
- child.children,
100
- parentVisible || filterMatches
101
- ).filter((n) => n)
107
+ child.parent = parent
108
+ const children = transformNavTree(child.children, child).filter(
109
+ (n) => n
110
+ )
102
111
  const visible = filterMatches || children.length > 0
112
+
103
113
  return visible
104
114
  ? {
105
115
  ...child,
116
+ parent,
106
117
  name,
107
118
  children,
108
- unfolded: isUnfolded(child, currentRoute, filter, visible),
119
+ unfolded: isUnfolded(child, filter, visible),
109
120
  filterMatches,
110
121
  }
111
122
  : undefined
@@ -124,49 +135,52 @@ function highlightFilterMatch(text) {
124
135
  return `${start}<span class="highlight">${middle}</span>${end}`
125
136
  }
126
137
 
127
- function isUnfolded(node, route, filter, visible) {
128
- return (
129
- (filter && visible) ||
130
- unfoldedNodes[node.key] ||
131
- route?.indexOf(node.key) === 0
132
- )
138
+ function isUnfolded(node, filter, visible) {
139
+ return (filter && visible) || unfoldedNodes[node.key]
133
140
  }
134
141
 
135
- export function toggleRootFolders() {
136
- rootNodesExpanded.set(!get(rootNodesExpanded))
137
- const newNodes = get(nodes).map((n) => ({
138
- ...n,
139
- unfolded: get(rootNodesExpanded) && unfoldedNodes[n.key],
140
- }))
141
- nodes.set(newNodes)
142
+ function normalizeHref(href) {
143
+ return href.split('#')[0].split('?')[0].replace(/\/+$/, '')
142
144
  }
143
145
 
144
- export function toggleFolder(node) {
145
- if (!get(rootNodesExpanded)) {
146
- expandRootNode(node)
147
- return
148
- }
149
- if (unfoldedNodes[node.key] && !(currentRoute.indexOf(node.key) === 0)) {
150
- unfoldedNodes[node.key] = false
151
- } else {
152
- unfoldedNodes[node.key] = true
146
+ export function navigateToLeafNode(href) {
147
+ const targetHref = normalizeHref(href)
148
+
149
+ const all = get(navtree).flatMap(getAllNodes)
150
+ const leaf = all.find((n) => n.isLeaf && normalizeHref(n.href) === targetHref)
151
+
152
+ const hrefToUse = normalizeHref(leaf?.href) || targetHref
153
+ const parts = hrefToUse.split('/').filter((p) => p.length > 0)
154
+ if (parts.length < 2) return leaf
155
+
156
+ for (let i = 0; i < parts.length - 1; i++) {
157
+ const key = '/' + parts.slice(0, i + 1).join('/') + '/'
158
+ unfoldedNodes[key] = true
153
159
  }
160
+
154
161
  updateTree()
155
162
  }
156
163
 
157
- function expandRootNode(node) {
158
- rootNodesExpanded.set(true)
159
- Object.keys(unfoldedNodes).forEach((key) => (unfoldedNodes[key] = false))
160
- const newNodes = get(nodes).map((n) => {
161
- if (n.key === node.key || currentRoute.indexOf(n.key) === 0) {
162
- unfoldedNodes[n.key] = true
163
- return { ...n, unfolded: true }
164
- } else {
165
- unfoldedNodes[n.key] = false
166
- return { ...n, unfolded: false }
167
- }
168
- })
169
- nodes.set(newNodes)
164
+ export function toggleFolder(node) {
165
+ unfoldedNodes[node.key] = !unfoldedNodes[node.key]
166
+ updateTree()
167
+ }
168
+
169
+ export function collapseTree() {
170
+ const all = get(navtree).flatMap(getAllNodes)
171
+ unfoldedNodes = all.reduce((acc, cur) => {
172
+ acc[cur.key] = false
173
+ return acc
174
+ }, {})
175
+ updateTree()
176
+ }
177
+
178
+ export function expandTree() {
179
+ const all = get(navtree).flatMap(getAllNodes)
180
+ unfoldedNodes = all.reduce((acc, cur) => {
181
+ acc[cur.key] = true
182
+ return acc
183
+ }, {})
170
184
  updateTree()
171
185
  }
172
186
 
@@ -212,7 +226,7 @@ function updateBookmarks() {
212
226
  }
213
227
 
214
228
  function cleanupBookmarks() {
215
- const allNodes = navtree.flatMap(getAllNodes)
229
+ const allNodes = get(navtree).flatMap(getAllNodes)
216
230
  const validBookmarks = get(bookmarks).filter((bookmark) => {
217
231
  return allNodes.some((node) => node.key === bookmark.key)
218
232
  })
@@ -15,6 +15,13 @@ function localStore(
15
15
  return store
16
16
  }
17
17
 
18
+ const textOrNumberParser = (value) => {
19
+ if (Number.isNaN(Number(value))) {
20
+ return value
21
+ }
22
+ return Number(value)
23
+ }
24
+
18
25
  export const themes = writable([])
19
26
  export const stageSizes = writable({
20
27
  small: [{ name: 'small', h: 1170, w: 550 }],
@@ -35,11 +42,24 @@ export const landscape = localStore(
35
42
  false,
36
43
  (value) => value === 'true'
37
44
  )
38
- export const stageContainerHeight = writable('')
39
- export const stageContainerWidth = writable('')
40
- export const stageContainerMaxHeight = writable('')
41
- export const stageHeight = writable('full')
42
- export const stageWidth = writable('full')
45
+ export const stageContainerHeight = localStore(
46
+ 'stageContainerHeight',
47
+ '',
48
+ textOrNumberParser
49
+ )
50
+ export const stageContainerWidth = localStore(
51
+ 'stageContainerWidth',
52
+ '',
53
+ textOrNumberParser
54
+ )
55
+ export const stageContainerMaxHeight = localStore(
56
+ 'stageContainerMaxHeight',
57
+ '',
58
+ textOrNumberParser
59
+ )
60
+ export const stageHeight = localStore('stageHeight', 'full', textOrNumberParser)
61
+ export const stageWidth = localStore('stageWidth', 'full', textOrNumberParser)
62
+
43
63
  export const stageMaxHeight = derived(
44
64
  [stageContainerHeight, stageContainerMaxHeight],
45
65
  ([$stageContainerHeight, $stageContainerMaxHeight]) =>
@@ -69,6 +89,16 @@ export const gridSettings = writable({
69
89
  color: '#ddd',
70
90
  })
71
91
 
92
+ export const resetStage = () => {
93
+ stageSize.set('full')
94
+ landscape.set(false)
95
+ stageContainerHeight.set('')
96
+ stageContainerWidth.set('')
97
+ stageContainerMaxHeight.set('')
98
+ stageHeight.set('full')
99
+ stageWidth.set('full')
100
+ }
101
+
72
102
  export function setGridSettings({ size, style, color }) {
73
103
  gridSettings.set({
74
104
  size: size ?? 50,
@@ -81,6 +111,7 @@ let previousPanelHeight = ''
81
111
 
82
112
  export function setStageSizes(newStageSizes) {
83
113
  stageSizes.set(newStageSizes)
114
+ setStagesize(get(stageSize))
84
115
  }
85
116
 
86
117
  export function setThemes(newThemes) {
@@ -213,8 +244,6 @@ export function toggleExpandPanel() {
213
244
  panelExpanded.set(!get(panelExpanded))
214
245
  }
215
246
 
216
- computeStageStyle()
217
-
218
247
  export function toggleExpandSidebar() {
219
248
  if (get(mobileNav)) {
220
249
  mobileSidebarExpanded.set(!get(mobileSidebarExpanded))
@@ -278,3 +307,5 @@ export function toggleOrientation() {
278
307
  landscape.set(!get(landscape))
279
308
  computeStageStyle()
280
309
  }
310
+
311
+ computeStageStyle()
@@ -1,46 +0,0 @@
1
- import{b as Tn,E as En,a as Cn,n as Ze,d as Rn,c as de,p as $,e as U,u as ae,g as p,s as ce,f as J,o as $t,h as en,i as C,j as _,k as f,l as $e,t as F,m as qt,q as se,r as W,v,w as ee,x as Re,y as me,z as Mn,A as qn,B as tn,C as O,D as et,F as oe,G as nn,H as In,I as It,J as te,K as kt,L as ke,M as Lt,N as Ln,O as P,P as z,Q as Hn,R as N,S as Bn}from"./props-DKVIKFn7.js";import{routes as Nn,navTree as An}from"../base.js";import{dasMap as jn}from"../das_import_map.js";import Wn from"../../garden.config.js";function Fe(i,e,...t){var n=i,s=Ze,r;Tn(()=>{s!==(s=e())&&(r&&(Rn(r),r=null),r=Cn(()=>s(n,...t)))},En)}function On(i,e,t,n){document.addEventListener("mousemove",e),document.addEventListener("mouseup",t),J(n,!0)}var Pn=C('<div class="container svelte-1pql0kc"><div class="top svelte-1pql0kc"><!></div> <div></div> <!></div>');function Dn(i,e){$(e,!0);let t=U(e,"topHeight",15),n=ce(void 0),s=ce(!1),r=ce(!1);ae(()=>{if(p(n)&&!p(r)){J(r,!0);const E=p(n).offsetHeight;e.onSetMaxHeight(E),e.onSetTopHeight(Math.round(E*.7))}});const l=se(()=>{if(Number.isInteger(t())&&Number.isInteger(e.maxHeight))return e.maxHeight<t()?e.maxHeight+"px":t()+"px"}),a=new ResizeObserver(E=>{E.forEach(()=>{e.onSetMaxHeight(p(n).offsetHeight),e.onSetMaxWidth(p(n).offsetWidth)})});$t(()=>{a.observe(p(n))}),en(()=>{a.disconnect()});const o=E=>{window.getSelection().removeAllRanges();const S=Math.min(e.maxHeight,E.pageY-p(n).offsetTop-7);t(S),e.onSetTopHeight(t())};function c(){document.removeEventListener("mousemove",o),document.removeEventListener("mouseup",c),e.onSetTopHeight(t()),J(s,!1)}var h=Pn(),g=f(h),d=f(g);Fe(d,()=>e.top??Ze);var u=_(g,2);let w;u.__mousedown=[On,o,c,s];var T=_(u,2);Fe(T,()=>e.bottom??Ze),$e(h,E=>J(n,E),()=>p(n)),F(E=>{qt(g,`height: ${p(l)??""};`),w=W(u,1,"dragbar svelte-1pql0kc",null,w,E)},[()=>({dragging:p(s)})]),v(i,h),ee()}de(["mousedown"]);var Un=C('<div><div><!></div> <div><div class="dragbar-icon svelte-mmou7f"></div></div> <div><div class="dragbar-icon svelte-mmou7f"></div></div> <div><div class="dragbar-icon svelte-mmou7f"></div></div></div>');function Zn(i,e){$(e,!0);let t=U(e,"disabled",3,!1),n=ce(void 0),s="";const r=se(()=>Number.isInteger(e.paneHeight)&&!t()?Math.min(e.paneHeight,e.maxHeight)+"px":e.maxHeight+"px"),l=se(()=>Number.isInteger(e.paneWidth)?Math.min(e.paneWidth,e.maxWidth)+"px":e.maxWidth+"px"),a=B=>()=>{s=B,document.addEventListener("mousemove",o),document.addEventListener("mouseup",c)},o=B=>{if(window.getSelection().removeAllRanges(),s.includes("horizontal")){let j=B.pageY-p(n).offsetTop-11;j>e.maxHeight?j="full":(j=Math.min(e.maxHeight,j),j=Math.max(50,j)),e.onSetStageHeight(j)}if(s.includes("vertical")){let j=B.pageX-p(n).offsetLeft-10;j>e.maxWidth?j="full":(j=Math.min(e.maxWidth,j),j=Math.max(50,j)),e.onSetStageWidth(j)}};function c(){document.removeEventListener("mousemove",o),document.removeEventListener("mouseup",c)}var h=Un();let g;var d=f(h);let u,w;var T=f(d);Fe(T,()=>e.children??Ze),$e(d,B=>J(n,B),()=>p(n));var E=_(d,2);let S;var M=se(()=>a("vertical"));E.__mousedown=function(...B){p(M)?.apply(this,B)};var R=_(E,2);let H;var q=se(()=>a("horizontal"));R.__mousedown=function(...B){p(q)?.apply(this,B)};var I=_(R,2);let D;var G=se(()=>a("verticalhorizontal"));I.__mousedown=function(...B){p(G)?.apply(this,B)},F((B,j,Ie,be,we,ge)=>{g=W(h,1,"resizepane-container svelte-mmou7f",null,g,B),u=W(d,1,"resizepane",null,u,j),w=qt(d,"",w,Ie),S=W(E,1,"dragbar vertical svelte-mmou7f",null,S,be),H=W(R,1,"dragbar horizontal svelte-mmou7f",null,H,we),D=W(I,1,"dragbar corner svelte-mmou7f",null,D,ge)},[()=>({disabled:t()}),()=>({disabled:t()}),()=>({width:t()?void 0:p(l),height:t()?void 0:p(r)}),()=>({disabled:t()}),()=>({disabled:t()}),()=>({disabled:t()})]),v(i,h),ee()}de(["mousedown"]);function Fn(i,e){$(e,!0);let t=U(e,"item",19,()=>({}));var n=Re(),s=me(n);Mn(s,()=>t().page,(r,l)=>{l(r,qn(()=>t().props))}),v(i,n),ee()}var Gn=(i,e,t)=>e(p(t)),Qn=C('<li class="svelte-1opzoal"><button> <span class="dot svelte-1opzoal"></span></button></li>'),Vn=C('<div class="panel_nav svelte-1opzoal"><nav class="svelte-1opzoal"><ul class="svelte-1opzoal"></ul></nav> <button class="panel_toggle svelte-1opzoal" title="Collapse panel"><span class="is-hidden svelte-1opzoal">Collapse panel</span> <svg class="controls_btn-icon svelte-1opzoal" xmlns="http://www.w3.org/2000/svg" width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><rect width="18" height="18" x="3" y="3" rx="2" ry="2"></rect><line x1="3" x2="21" y1="15" y2="15"></line><path d="m15 8-3 3-3-3"></path></svg></button></div> <div class="panel_pane svelte-1opzoal"><!></div>',1),Xn=C('<div class="panel_container svelte-1opzoal"><!></div>');function Kn(i,e){$(e,!0);let t=U(e,"tabs",19,()=>[]),n=ce(tn({}));const s=se(()=>t()?t().find(c=>c.name===p(n))||t()[0]:{}),r=c=>{J(n,c.name,!0)};var l=Xn(),a=f(l);{var o=c=>{var h=Vn(),g=me(h),d=f(g),u=f(d);et(u,21,t,R=>R.name,(R,H)=>{var q=Qn(),I=f(q);I.__click=[Gn,r,H];let D;var G=f(I);F(B=>{D=W(I,1,"svelte-1opzoal",null,D,B),oe(G,p(H).name)},[()=>({active:p(H).name===p(s).name})]),v(R,q)});var w=_(d,2);w.__click=function(...R){e.onToggleExpandPanel?.apply(this,R)};var T=_(g,2),E=f(T);{var S=R=>{Fn(R,{get item(){return p(s)}})},M=R=>{var H=Re(),q=me(H);{var I=G=>{var B=Re(),j=me(B);Fe(j,()=>e.children),v(G,B)},D=G=>{var B=nn("No tab content provided");v(G,B)};O(q,G=>{e.children?G(I):G(D,!1)},!0)}v(R,H)};O(E,R=>{p(s)&&p(s).page?R(S):R(M,!1)})}v(c,h)};O(a,c=>{t().length&&c(o)})}v(i,l),ee()}de(["click"]);var Yn=(i,e,t)=>e.onSelectExample(p(t)),Jn=C('<li><button class="svelte-uqxlqe"><span class="dot svelte-uqxlqe"></span> </button></li>'),$n=C('<ul class="examples svelte-uqxlqe"></ul>');function es(i,e){$(e,!0);let t=U(e,"examples",19,()=>[]);var n=$n();et(n,21,t,In,(s,r)=>{var l=Jn();let a;var o=f(l);o.__click=[Yn,e,r];var c=_(f(o));F(h=>{a=W(l,1,"svelte-uqxlqe",null,a,h),oe(c,` ${p(r)??""}`)},[()=>({active:e.selected==p(r)})]),v(s,l)}),v(i,n),ee()}de(["click"]);function sn(){return{async:!1,baseUrl:null,breaks:!1,extensions:null,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,hooks:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1}}let Ae=sn();function ts(i){Ae=i}const rn=/[&<>"']/,ns=new RegExp(rn.source,"g"),ln=/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,ss=new RegExp(ln.source,"g"),is={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},Ot=i=>is[i];function Y(i,e){if(e){if(rn.test(i))return i.replace(ns,Ot)}else if(ln.test(i))return i.replace(ss,Ot);return i}const rs=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig;function an(i){return i.replace(rs,(e,t)=>(t=t.toLowerCase(),t==="colon"?":":t.charAt(0)==="#"?t.charAt(1)==="x"?String.fromCharCode(parseInt(t.substring(2),16)):String.fromCharCode(+t.substring(1)):""))}const ls=/(^|[^\[])\^/g;function A(i,e){i=typeof i=="string"?i:i.source,e=e||"";const t={replace:(n,s)=>(s=s.source||s,s=s.replace(ls,"$1"),i=i.replace(n,s),t),getRegex:()=>new RegExp(i,e)};return t}const as=/[^\w:]/g,os=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;function Pt(i,e,t){if(i){let n;try{n=decodeURIComponent(an(t)).replace(as,"").toLowerCase()}catch{return null}if(n.indexOf("javascript:")===0||n.indexOf("vbscript:")===0||n.indexOf("data:")===0)return null}e&&!os.test(t)&&(t=ds(e,t));try{t=encodeURI(t).replace(/%25/g,"%")}catch{return null}return t}const rt={},cs=/^[^:]+:\/*[^/]*$/,us=/^([^:]+:)[\s\S]*$/,hs=/^([^:]+:\/*[^/]*)[\s\S]*$/;function ds(i,e){rt[" "+i]||(cs.test(i)?rt[" "+i]=i+"/":rt[" "+i]=at(i,"/",!0)),i=rt[" "+i];const t=i.indexOf(":")===-1;return e.substring(0,2)==="//"?t?e:i.replace(us,"$1")+e:e.charAt(0)==="/"?t?e:i.replace(hs,"$1")+e:i+e}const ot={exec:function(){}};function Dt(i,e){const t=i.replace(/\|/g,(r,l,a)=>{let o=!1,c=l;for(;--c>=0&&a[c]==="\\";)o=!o;return o?"|":" |"}),n=t.split(/ \|/);let s=0;if(n[0].trim()||n.shift(),n.length>0&&!n[n.length-1].trim()&&n.pop(),n.length>e)n.splice(e);else for(;n.length<e;)n.push("");for(;s<n.length;s++)n[s]=n[s].trim().replace(/\\\|/g,"|");return n}function at(i,e,t){const n=i.length;if(n===0)return"";let s=0;for(;s<n;){const r=i.charAt(n-s-1);if(r===e&&!t)s++;else if(r!==e&&t)s++;else break}return i.slice(0,n-s)}function gs(i,e){if(i.indexOf(e[1])===-1)return-1;const t=i.length;let n=0,s=0;for(;s<t;s++)if(i[s]==="\\")s++;else if(i[s]===e[0])n++;else if(i[s]===e[1]&&(n--,n<0))return s;return-1}function ps(i){i&&i.sanitize&&!i.silent&&console.warn("marked(): sanitize and sanitizer parameters are deprecated since version 0.7.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/#/USING_ADVANCED.md#options")}function Ut(i,e){if(e<1)return"";let t="";for(;e>1;)e&1&&(t+=i),e>>=1,i+=i;return t+i}function Zt(i,e,t,n){const s=e.href,r=e.title?Y(e.title):null,l=i[1].replace(/\\([\[\]])/g,"$1");if(i[0].charAt(0)!=="!"){n.state.inLink=!0;const a={type:"link",raw:t,href:s,title:r,text:l,tokens:n.inlineTokens(l)};return n.state.inLink=!1,a}return{type:"image",raw:t,href:s,title:r,text:Y(l)}}function fs(i,e){const t=i.match(/^(\s+)(?:```)/);if(t===null)return e;const n=t[1];return e.split(`
2
- `).map(s=>{const r=s.match(/^\s+/);if(r===null)return s;const[l]=r;return l.length>=n.length?s.slice(n.length):s}).join(`
3
- `)}class Ht{constructor(e){this.options=e||Ae}space(e){const t=this.rules.block.newline.exec(e);if(t&&t[0].length>0)return{type:"space",raw:t[0]}}code(e){const t=this.rules.block.code.exec(e);if(t){const n=t[0].replace(/^ {1,4}/gm,"");return{type:"code",raw:t[0],codeBlockStyle:"indented",text:this.options.pedantic?n:at(n,`
4
- `)}}}fences(e){const t=this.rules.block.fences.exec(e);if(t){const n=t[0],s=fs(n,t[3]||"");return{type:"code",raw:n,lang:t[2]?t[2].trim().replace(this.rules.inline._escapes,"$1"):t[2],text:s}}}heading(e){const t=this.rules.block.heading.exec(e);if(t){let n=t[2].trim();if(/#$/.test(n)){const s=at(n,"#");(this.options.pedantic||!s||/ $/.test(s))&&(n=s.trim())}return{type:"heading",raw:t[0],depth:t[1].length,text:n,tokens:this.lexer.inline(n)}}}hr(e){const t=this.rules.block.hr.exec(e);if(t)return{type:"hr",raw:t[0]}}blockquote(e){const t=this.rules.block.blockquote.exec(e);if(t){const n=t[0].replace(/^ *>[ \t]?/gm,""),s=this.lexer.state.top;this.lexer.state.top=!0;const r=this.lexer.blockTokens(n);return this.lexer.state.top=s,{type:"blockquote",raw:t[0],tokens:r,text:n}}}list(e){let t=this.rules.block.list.exec(e);if(t){let n,s,r,l,a,o,c,h,g,d,u,w,T=t[1].trim();const E=T.length>1,S={type:"list",raw:"",ordered:E,start:E?+T.slice(0,-1):"",loose:!1,items:[]};T=E?`\\d{1,9}\\${T.slice(-1)}`:`\\${T}`,this.options.pedantic&&(T=E?T:"[*+-]");const M=new RegExp(`^( {0,3}${T})((?:[ ][^\\n]*)?(?:\\n|$))`);for(;e&&(w=!1,!(!(t=M.exec(e))||this.rules.block.hr.test(e)));){if(n=t[0],e=e.substring(n.length),h=t[2].split(`
5
- `,1)[0].replace(/^\t+/,H=>" ".repeat(3*H.length)),g=e.split(`
6
- `,1)[0],this.options.pedantic?(l=2,u=h.trimLeft()):(l=t[2].search(/[^ ]/),l=l>4?1:l,u=h.slice(l),l+=t[1].length),o=!1,!h&&/^ *$/.test(g)&&(n+=g+`
7
- `,e=e.substring(g.length+1),w=!0),!w){const H=new RegExp(`^ {0,${Math.min(3,l-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),q=new RegExp(`^ {0,${Math.min(3,l-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),I=new RegExp(`^ {0,${Math.min(3,l-1)}}(?:\`\`\`|~~~)`),D=new RegExp(`^ {0,${Math.min(3,l-1)}}#`);for(;e&&(d=e.split(`
8
- `,1)[0],g=d,this.options.pedantic&&(g=g.replace(/^ {1,4}(?=( {4})*[^ ])/g," ")),!(I.test(g)||D.test(g)||H.test(g)||q.test(e)));){if(g.search(/[^ ]/)>=l||!g.trim())u+=`
9
- `+g.slice(l);else{if(o||h.search(/[^ ]/)>=4||I.test(h)||D.test(h)||q.test(h))break;u+=`
10
- `+g}!o&&!g.trim()&&(o=!0),n+=d+`
11
- `,e=e.substring(d.length+1),h=g.slice(l)}}S.loose||(c?S.loose=!0:/\n *\n *$/.test(n)&&(c=!0)),this.options.gfm&&(s=/^\[[ xX]\] /.exec(u),s&&(r=s[0]!=="[ ] ",u=u.replace(/^\[[ xX]\] +/,""))),S.items.push({type:"list_item",raw:n,task:!!s,checked:r,loose:!1,text:u}),S.raw+=n}S.items[S.items.length-1].raw=n.trimRight(),S.items[S.items.length-1].text=u.trimRight(),S.raw=S.raw.trimRight();const R=S.items.length;for(a=0;a<R;a++)if(this.lexer.state.top=!1,S.items[a].tokens=this.lexer.blockTokens(S.items[a].text,[]),!S.loose){const H=S.items[a].tokens.filter(I=>I.type==="space"),q=H.length>0&&H.some(I=>/\n.*\n/.test(I.raw));S.loose=q}if(S.loose)for(a=0;a<R;a++)S.items[a].loose=!0;return S}}html(e){const t=this.rules.block.html.exec(e);if(t){const n={type:"html",raw:t[0],pre:!this.options.sanitizer&&(t[1]==="pre"||t[1]==="script"||t[1]==="style"),text:t[0]};if(this.options.sanitize){const s=this.options.sanitizer?this.options.sanitizer(t[0]):Y(t[0]);n.type="paragraph",n.text=s,n.tokens=this.lexer.inline(s)}return n}}def(e){const t=this.rules.block.def.exec(e);if(t){const n=t[1].toLowerCase().replace(/\s+/g," "),s=t[2]?t[2].replace(/^<(.*)>$/,"$1").replace(this.rules.inline._escapes,"$1"):"",r=t[3]?t[3].substring(1,t[3].length-1).replace(this.rules.inline._escapes,"$1"):t[3];return{type:"def",tag:n,raw:t[0],href:s,title:r}}}table(e){const t=this.rules.block.table.exec(e);if(t){const n={type:"table",header:Dt(t[1]).map(s=>({text:s})),align:t[2].replace(/^ *|\| *$/g,"").split(/ *\| */),rows:t[3]&&t[3].trim()?t[3].replace(/\n[ \t]*$/,"").split(`
12
- `):[]};if(n.header.length===n.align.length){n.raw=t[0];let s=n.align.length,r,l,a,o;for(r=0;r<s;r++)/^ *-+: *$/.test(n.align[r])?n.align[r]="right":/^ *:-+: *$/.test(n.align[r])?n.align[r]="center":/^ *:-+ *$/.test(n.align[r])?n.align[r]="left":n.align[r]=null;for(s=n.rows.length,r=0;r<s;r++)n.rows[r]=Dt(n.rows[r],n.header.length).map(c=>({text:c}));for(s=n.header.length,l=0;l<s;l++)n.header[l].tokens=this.lexer.inline(n.header[l].text);for(s=n.rows.length,l=0;l<s;l++)for(o=n.rows[l],a=0;a<o.length;a++)o[a].tokens=this.lexer.inline(o[a].text);return n}}}lheading(e){const t=this.rules.block.lheading.exec(e);if(t)return{type:"heading",raw:t[0],depth:t[2].charAt(0)==="="?1:2,text:t[1],tokens:this.lexer.inline(t[1])}}paragraph(e){const t=this.rules.block.paragraph.exec(e);if(t){const n=t[1].charAt(t[1].length-1)===`
13
- `?t[1].slice(0,-1):t[1];return{type:"paragraph",raw:t[0],text:n,tokens:this.lexer.inline(n)}}}text(e){const t=this.rules.block.text.exec(e);if(t)return{type:"text",raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(e){const t=this.rules.inline.escape.exec(e);if(t)return{type:"escape",raw:t[0],text:Y(t[1])}}tag(e){const t=this.rules.inline.tag.exec(e);if(t)return!this.lexer.state.inLink&&/^<a /i.test(t[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&/^<\/a>/i.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&/^<(pre|code|kbd|script)(\s|>)/i.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:this.options.sanitize?"text":"html",raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(t[0]):Y(t[0]):t[0]}}link(e){const t=this.rules.inline.link.exec(e);if(t){const n=t[2].trim();if(!this.options.pedantic&&/^</.test(n)){if(!/>$/.test(n))return;const l=at(n.slice(0,-1),"\\");if((n.length-l.length)%2===0)return}else{const l=gs(t[2],"()");if(l>-1){const o=(t[0].indexOf("!")===0?5:4)+t[1].length+l;t[2]=t[2].substring(0,l),t[0]=t[0].substring(0,o).trim(),t[3]=""}}let s=t[2],r="";if(this.options.pedantic){const l=/^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(s);l&&(s=l[1],r=l[3])}else r=t[3]?t[3].slice(1,-1):"";return s=s.trim(),/^</.test(s)&&(this.options.pedantic&&!/>$/.test(n)?s=s.slice(1):s=s.slice(1,-1)),Zt(t,{href:s&&s.replace(this.rules.inline._escapes,"$1"),title:r&&r.replace(this.rules.inline._escapes,"$1")},t[0],this.lexer)}}reflink(e,t){let n;if((n=this.rules.inline.reflink.exec(e))||(n=this.rules.inline.nolink.exec(e))){let s=(n[2]||n[1]).replace(/\s+/g," ");if(s=t[s.toLowerCase()],!s){const r=n[0].charAt(0);return{type:"text",raw:r,text:r}}return Zt(n,s,n[0],this.lexer)}}emStrong(e,t,n=""){let s=this.rules.inline.emStrong.lDelim.exec(e);if(!s||s[3]&&n.match(/[\p{L}\p{N}]/u))return;const r=s[1]||s[2]||"";if(!r||r&&(n===""||this.rules.inline.punctuation.exec(n))){const l=s[0].length-1;let a,o,c=l,h=0;const g=s[0][0]==="*"?this.rules.inline.emStrong.rDelimAst:this.rules.inline.emStrong.rDelimUnd;for(g.lastIndex=0,t=t.slice(-1*e.length+l);(s=g.exec(t))!=null;){if(a=s[1]||s[2]||s[3]||s[4]||s[5]||s[6],!a)continue;if(o=a.length,s[3]||s[4]){c+=o;continue}else if((s[5]||s[6])&&l%3&&!((l+o)%3)){h+=o;continue}if(c-=o,c>0)continue;o=Math.min(o,o+c+h);const d=e.slice(0,l+s.index+(s[0].length-a.length)+o);if(Math.min(l,o)%2){const w=d.slice(1,-1);return{type:"em",raw:d,text:w,tokens:this.lexer.inlineTokens(w)}}const u=d.slice(2,-2);return{type:"strong",raw:d,text:u,tokens:this.lexer.inlineTokens(u)}}}}codespan(e){const t=this.rules.inline.code.exec(e);if(t){let n=t[2].replace(/\n/g," ");const s=/[^ ]/.test(n),r=/^ /.test(n)&&/ $/.test(n);return s&&r&&(n=n.substring(1,n.length-1)),n=Y(n,!0),{type:"codespan",raw:t[0],text:n}}}br(e){const t=this.rules.inline.br.exec(e);if(t)return{type:"br",raw:t[0]}}del(e){const t=this.rules.inline.del.exec(e);if(t)return{type:"del",raw:t[0],text:t[2],tokens:this.lexer.inlineTokens(t[2])}}autolink(e,t){const n=this.rules.inline.autolink.exec(e);if(n){let s,r;return n[2]==="@"?(s=Y(this.options.mangle?t(n[1]):n[1]),r="mailto:"+s):(s=Y(n[1]),r=s),{type:"link",raw:n[0],text:s,href:r,tokens:[{type:"text",raw:s,text:s}]}}}url(e,t){let n;if(n=this.rules.inline.url.exec(e)){let s,r;if(n[2]==="@")s=Y(this.options.mangle?t(n[0]):n[0]),r="mailto:"+s;else{let l;do l=n[0],n[0]=this.rules.inline._backpedal.exec(n[0])[0];while(l!==n[0]);s=Y(n[0]),n[1]==="www."?r="http://"+n[0]:r=n[0]}return{type:"link",raw:n[0],text:s,href:r,tokens:[{type:"text",raw:s,text:s}]}}}inlineText(e,t){const n=this.rules.inline.text.exec(e);if(n){let s;return this.lexer.state.inRawBlock?s=this.options.sanitize?this.options.sanitizer?this.options.sanitizer(n[0]):Y(n[0]):n[0]:s=Y(this.options.smartypants?t(n[0]):n[0]),{type:"text",raw:n[0],text:s}}}}const k={newline:/^(?: *(?:\n|$))+/,code:/^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/,fences:/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,hr:/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,heading:/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/,html:"^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))",def:/^ {0,3}\[(label)\]: *(?:\n *)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/,table:ot,lheading:/^((?:.|\n(?!\n))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,_paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,text:/^[^\n]+/};k._label=/(?!\s*\])(?:\\.|[^\[\]\\])+/;k._title=/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/;k.def=A(k.def).replace("label",k._label).replace("title",k._title).getRegex();k.bullet=/(?:[*+-]|\d{1,9}[.)])/;k.listItemStart=A(/^( *)(bull) */).replace("bull",k.bullet).getRegex();k.list=A(k.list).replace(/bull/g,k.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+k.def.source+")").getRegex();k._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul";k._comment=/<!--(?!-?>)[\s\S]*?(?:-->|$)/;k.html=A(k.html,"i").replace("comment",k._comment).replace("tag",k._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex();k.paragraph=A(k._paragraph).replace("hr",k.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",k._tag).getRegex();k.blockquote=A(k.blockquote).replace("paragraph",k.paragraph).getRegex();k.normal={...k};k.gfm={...k.normal,table:"^ *([^\\n ].*\\|.*)\\n {0,3}(?:\\| *)?(:?-+:? *(?:\\| *:?-+:? *)*)(?:\\| *)?(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)"};k.gfm.table=A(k.gfm.table).replace("hr",k.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",k._tag).getRegex();k.gfm.paragraph=A(k._paragraph).replace("hr",k.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("table",k.gfm.table).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",k._tag).getRegex();k.pedantic={...k.normal,html:A(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",k._comment).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:ot,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:A(k.normal._paragraph).replace("hr",k.hr).replace("heading",` *#{1,6} *[^
14
- ]`).replace("lheading",k.lheading).replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").getRegex()};const m={escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,autolink:/^<(scheme:[^\s\x00-\x1f<>]*|email)>/,url:ot,tag:"^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>",link:/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/,reflink:/^!?\[(label)\]\[(ref)\]/,nolink:/^!?\[(ref)\](?:\[\])?/,reflinkSearch:"reflink|nolink(?!\\()",emStrong:{lDelim:/^(?:\*+(?:([punct_])|[^\s*]))|^_+(?:([punct*])|([^\s_]))/,rDelimAst:/^(?:[^_*\\]|\\.)*?\_\_(?:[^_*\\]|\\.)*?\*(?:[^_*\\]|\\.)*?(?=\_\_)|(?:[^*\\]|\\.)+(?=[^*])|[punct_](\*+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\*+)(?=[punct_\s]|$)|[punct_\s](\*+)(?=[^punct*_\s])|[\s](\*+)(?=[punct_])|[punct_](\*+)(?=[punct_])|(?:[^punct*_\s\\]|\\.)(\*+)(?=[^punct*_\s])/,rDelimUnd:/^(?:[^_*\\]|\\.)*?\*\*(?:[^_*\\]|\\.)*?\_(?:[^_*\\]|\\.)*?(?=\*\*)|(?:[^_\\]|\\.)+(?=[^_])|[punct*](\_+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\_+)(?=[punct*\s]|$)|[punct*\s](\_+)(?=[^punct*_\s])|[\s](\_+)(?=[punct*])|[punct*](\_+)(?=[punct*])/},code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,br:/^( {2,}|\\)\n(?!\s*$)/,del:ot,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,punctuation:/^([\spunctuation])/};m._punctuation="!\"#$%&'()+\\-.,/:;<=>?@\\[\\]`^{|}~";m.punctuation=A(m.punctuation).replace(/punctuation/g,m._punctuation).getRegex();m.blockSkip=/\[[^\]]*?\]\([^\)]*?\)|`[^`]*?`|<[^>]*?>/g;m.escapedEmSt=/(?:^|[^\\])(?:\\\\)*\\[*_]/g;m._comment=A(k._comment).replace("(?:-->|$)","-->").getRegex();m.emStrong.lDelim=A(m.emStrong.lDelim).replace(/punct/g,m._punctuation).getRegex();m.emStrong.rDelimAst=A(m.emStrong.rDelimAst,"g").replace(/punct/g,m._punctuation).getRegex();m.emStrong.rDelimUnd=A(m.emStrong.rDelimUnd,"g").replace(/punct/g,m._punctuation).getRegex();m._escapes=/\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/g;m._scheme=/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/;m._email=/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/;m.autolink=A(m.autolink).replace("scheme",m._scheme).replace("email",m._email).getRegex();m._attribute=/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/;m.tag=A(m.tag).replace("comment",m._comment).replace("attribute",m._attribute).getRegex();m._label=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/;m._href=/<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/;m._title=/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/;m.link=A(m.link).replace("label",m._label).replace("href",m._href).replace("title",m._title).getRegex();m.reflink=A(m.reflink).replace("label",m._label).replace("ref",k._label).getRegex();m.nolink=A(m.nolink).replace("ref",k._label).getRegex();m.reflinkSearch=A(m.reflinkSearch,"g").replace("reflink",m.reflink).replace("nolink",m.nolink).getRegex();m.normal={...m};m.pedantic={...m.normal,strong:{start:/^__|\*\*/,middle:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,endAst:/\*\*(?!\*)/g,endUnd:/__(?!_)/g},em:{start:/^_|\*/,middle:/^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/,endAst:/\*(?!\*)/g,endUnd:/_(?!_)/g},link:A(/^!?\[(label)\]\((.*?)\)/).replace("label",m._label).getRegex(),reflink:A(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",m._label).getRegex()};m.gfm={...m.normal,escape:A(m.escape).replace("])","~|])").getRegex(),_extended_email:/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,url:/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/};m.gfm.url=A(m.gfm.url,"i").replace("email",m.gfm._extended_email).getRegex();m.breaks={...m.gfm,br:A(m.br).replace("{2,}","*").getRegex(),text:A(m.gfm.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()};function ms(i){return i.replace(/---/g,"—").replace(/--/g,"–").replace(/(^|[-\u2014/(\[{"\s])'/g,"$1‘").replace(/'/g,"’").replace(/(^|[-\u2014/(\[{\u2018\s])"/g,"$1“").replace(/"/g,"”").replace(/\.{3}/g,"…")}function Ft(i){let e="",t,n;const s=i.length;for(t=0;t<s;t++)n=i.charCodeAt(t),Math.random()>.5&&(n="x"+n.toString(16)),e+="&#"+n+";";return e}class Me{constructor(e){this.tokens=[],this.tokens.links=Object.create(null),this.options=e||Ae,this.options.tokenizer=this.options.tokenizer||new Ht,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};const t={block:k.normal,inline:m.normal};this.options.pedantic?(t.block=k.pedantic,t.inline=m.pedantic):this.options.gfm&&(t.block=k.gfm,this.options.breaks?t.inline=m.breaks:t.inline=m.gfm),this.tokenizer.rules=t}static get rules(){return{block:k,inline:m}}static lex(e,t){return new Me(t).lex(e)}static lexInline(e,t){return new Me(t).inlineTokens(e)}lex(e){e=e.replace(/\r\n|\r/g,`
15
- `),this.blockTokens(e,this.tokens);let t;for(;t=this.inlineQueue.shift();)this.inlineTokens(t.src,t.tokens);return this.tokens}blockTokens(e,t=[]){this.options.pedantic?e=e.replace(/\t/g," ").replace(/^ +$/gm,""):e=e.replace(/^( *)(\t+)/gm,(a,o,c)=>o+" ".repeat(c.length));let n,s,r,l;for(;e;)if(!(this.options.extensions&&this.options.extensions.block&&this.options.extensions.block.some(a=>(n=a.call({lexer:this},e,t))?(e=e.substring(n.raw.length),t.push(n),!0):!1))){if(n=this.tokenizer.space(e)){e=e.substring(n.raw.length),n.raw.length===1&&t.length>0?t[t.length-1].raw+=`
16
- `:t.push(n);continue}if(n=this.tokenizer.code(e)){e=e.substring(n.raw.length),s=t[t.length-1],s&&(s.type==="paragraph"||s.type==="text")?(s.raw+=`
17
- `+n.raw,s.text+=`
18
- `+n.text,this.inlineQueue[this.inlineQueue.length-1].src=s.text):t.push(n);continue}if(n=this.tokenizer.fences(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.heading(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.hr(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.blockquote(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.list(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.html(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.def(e)){e=e.substring(n.raw.length),s=t[t.length-1],s&&(s.type==="paragraph"||s.type==="text")?(s.raw+=`
19
- `+n.raw,s.text+=`
20
- `+n.raw,this.inlineQueue[this.inlineQueue.length-1].src=s.text):this.tokens.links[n.tag]||(this.tokens.links[n.tag]={href:n.href,title:n.title});continue}if(n=this.tokenizer.table(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.lheading(e)){e=e.substring(n.raw.length),t.push(n);continue}if(r=e,this.options.extensions&&this.options.extensions.startBlock){let a=1/0;const o=e.slice(1);let c;this.options.extensions.startBlock.forEach(function(h){c=h.call({lexer:this},o),typeof c=="number"&&c>=0&&(a=Math.min(a,c))}),a<1/0&&a>=0&&(r=e.substring(0,a+1))}if(this.state.top&&(n=this.tokenizer.paragraph(r))){s=t[t.length-1],l&&s.type==="paragraph"?(s.raw+=`
21
- `+n.raw,s.text+=`
22
- `+n.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=s.text):t.push(n),l=r.length!==e.length,e=e.substring(n.raw.length);continue}if(n=this.tokenizer.text(e)){e=e.substring(n.raw.length),s=t[t.length-1],s&&s.type==="text"?(s.raw+=`
23
- `+n.raw,s.text+=`
24
- `+n.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=s.text):t.push(n);continue}if(e){const a="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(a);break}else throw new Error(a)}}return this.state.top=!0,t}inline(e,t=[]){return this.inlineQueue.push({src:e,tokens:t}),t}inlineTokens(e,t=[]){let n,s,r,l=e,a,o,c;if(this.tokens.links){const h=Object.keys(this.tokens.links);if(h.length>0)for(;(a=this.tokenizer.rules.inline.reflinkSearch.exec(l))!=null;)h.includes(a[0].slice(a[0].lastIndexOf("[")+1,-1))&&(l=l.slice(0,a.index)+"["+Ut("a",a[0].length-2)+"]"+l.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(a=this.tokenizer.rules.inline.blockSkip.exec(l))!=null;)l=l.slice(0,a.index)+"["+Ut("a",a[0].length-2)+"]"+l.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;(a=this.tokenizer.rules.inline.escapedEmSt.exec(l))!=null;)l=l.slice(0,a.index+a[0].length-2)+"++"+l.slice(this.tokenizer.rules.inline.escapedEmSt.lastIndex),this.tokenizer.rules.inline.escapedEmSt.lastIndex--;for(;e;)if(o||(c=""),o=!1,!(this.options.extensions&&this.options.extensions.inline&&this.options.extensions.inline.some(h=>(n=h.call({lexer:this},e,t))?(e=e.substring(n.raw.length),t.push(n),!0):!1))){if(n=this.tokenizer.escape(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.tag(e)){e=e.substring(n.raw.length),s=t[t.length-1],s&&n.type==="text"&&s.type==="text"?(s.raw+=n.raw,s.text+=n.text):t.push(n);continue}if(n=this.tokenizer.link(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(n.raw.length),s=t[t.length-1],s&&n.type==="text"&&s.type==="text"?(s.raw+=n.raw,s.text+=n.text):t.push(n);continue}if(n=this.tokenizer.emStrong(e,l,c)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.codespan(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.br(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.del(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.autolink(e,Ft)){e=e.substring(n.raw.length),t.push(n);continue}if(!this.state.inLink&&(n=this.tokenizer.url(e,Ft))){e=e.substring(n.raw.length),t.push(n);continue}if(r=e,this.options.extensions&&this.options.extensions.startInline){let h=1/0;const g=e.slice(1);let d;this.options.extensions.startInline.forEach(function(u){d=u.call({lexer:this},g),typeof d=="number"&&d>=0&&(h=Math.min(h,d))}),h<1/0&&h>=0&&(r=e.substring(0,h+1))}if(n=this.tokenizer.inlineText(r,ms)){e=e.substring(n.raw.length),n.raw.slice(-1)!=="_"&&(c=n.raw.slice(-1)),o=!0,s=t[t.length-1],s&&s.type==="text"?(s.raw+=n.raw,s.text+=n.text):t.push(n);continue}if(e){const h="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(h);break}else throw new Error(h)}}return t}}class Bt{constructor(e){this.options=e||Ae}code(e,t,n){const s=(t||"").match(/\S*/)[0];if(this.options.highlight){const r=this.options.highlight(e,s);r!=null&&r!==e&&(n=!0,e=r)}return e=e.replace(/\n$/,"")+`
25
- `,s?'<pre><code class="'+this.options.langPrefix+Y(s)+'">'+(n?e:Y(e,!0))+`</code></pre>
26
- `:"<pre><code>"+(n?e:Y(e,!0))+`</code></pre>
27
- `}blockquote(e){return`<blockquote>
28
- ${e}</blockquote>
29
- `}html(e){return e}heading(e,t,n,s){if(this.options.headerIds){const r=this.options.headerPrefix+s.slug(n);return`<h${t} id="${r}">${e}</h${t}>
30
- `}return`<h${t}>${e}</h${t}>
31
- `}hr(){return this.options.xhtml?`<hr/>
32
- `:`<hr>
33
- `}list(e,t,n){const s=t?"ol":"ul",r=t&&n!==1?' start="'+n+'"':"";return"<"+s+r+`>
34
- `+e+"</"+s+`>
35
- `}listitem(e){return`<li>${e}</li>
36
- `}checkbox(e){return"<input "+(e?'checked="" ':"")+'disabled="" type="checkbox"'+(this.options.xhtml?" /":"")+"> "}paragraph(e){return`<p>${e}</p>
37
- `}table(e,t){return t&&(t=`<tbody>${t}</tbody>`),`<table>
38
- <thead>
39
- `+e+`</thead>
40
- `+t+`</table>
41
- `}tablerow(e){return`<tr>
42
- ${e}</tr>
43
- `}tablecell(e,t){const n=t.header?"th":"td";return(t.align?`<${n} align="${t.align}">`:`<${n}>`)+e+`</${n}>
44
- `}strong(e){return`<strong>${e}</strong>`}em(e){return`<em>${e}</em>`}codespan(e){return`<code>${e}</code>`}br(){return this.options.xhtml?"<br/>":"<br>"}del(e){return`<del>${e}</del>`}link(e,t,n){if(e=Pt(this.options.sanitize,this.options.baseUrl,e),e===null)return n;let s='<a href="'+e+'"';return t&&(s+=' title="'+t+'"'),s+=">"+n+"</a>",s}image(e,t,n){if(e=Pt(this.options.sanitize,this.options.baseUrl,e),e===null)return n;let s=`<img src="${e}" alt="${n}"`;return t&&(s+=` title="${t}"`),s+=this.options.xhtml?"/>":">",s}text(e){return e}}class on{strong(e){return e}em(e){return e}codespan(e){return e}del(e){return e}html(e){return e}text(e){return e}link(e,t,n){return""+n}image(e,t,n){return""+n}br(){return""}}class cn{constructor(){this.seen={}}serialize(e){return e.toLowerCase().trim().replace(/<[!\/a-z].*?>/ig,"").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g,"").replace(/\s/g,"-")}getNextSafeSlug(e,t){let n=e,s=0;if(this.seen.hasOwnProperty(n)){s=this.seen[e];do s++,n=e+"-"+s;while(this.seen.hasOwnProperty(n))}return t||(this.seen[e]=s,this.seen[n]=0),n}slug(e,t={}){const n=this.serialize(e);return this.getNextSafeSlug(n,t.dryrun)}}class qe{constructor(e){this.options=e||Ae,this.options.renderer=this.options.renderer||new Bt,this.renderer=this.options.renderer,this.renderer.options=this.options,this.textRenderer=new on,this.slugger=new cn}static parse(e,t){return new qe(t).parse(e)}static parseInline(e,t){return new qe(t).parseInline(e)}parse(e,t=!0){let n="",s,r,l,a,o,c,h,g,d,u,w,T,E,S,M,R,H,q,I;const D=e.length;for(s=0;s<D;s++){if(u=e[s],this.options.extensions&&this.options.extensions.renderers&&this.options.extensions.renderers[u.type]&&(I=this.options.extensions.renderers[u.type].call({parser:this},u),I!==!1||!["space","hr","heading","code","table","blockquote","list","html","paragraph","text"].includes(u.type))){n+=I||"";continue}switch(u.type){case"space":continue;case"hr":{n+=this.renderer.hr();continue}case"heading":{n+=this.renderer.heading(this.parseInline(u.tokens),u.depth,an(this.parseInline(u.tokens,this.textRenderer)),this.slugger);continue}case"code":{n+=this.renderer.code(u.text,u.lang,u.escaped);continue}case"table":{for(g="",h="",a=u.header.length,r=0;r<a;r++)h+=this.renderer.tablecell(this.parseInline(u.header[r].tokens),{header:!0,align:u.align[r]});for(g+=this.renderer.tablerow(h),d="",a=u.rows.length,r=0;r<a;r++){for(c=u.rows[r],h="",o=c.length,l=0;l<o;l++)h+=this.renderer.tablecell(this.parseInline(c[l].tokens),{header:!1,align:u.align[l]});d+=this.renderer.tablerow(h)}n+=this.renderer.table(g,d);continue}case"blockquote":{d=this.parse(u.tokens),n+=this.renderer.blockquote(d);continue}case"list":{for(w=u.ordered,T=u.start,E=u.loose,a=u.items.length,d="",r=0;r<a;r++)M=u.items[r],R=M.checked,H=M.task,S="",M.task&&(q=this.renderer.checkbox(R),E?M.tokens.length>0&&M.tokens[0].type==="paragraph"?(M.tokens[0].text=q+" "+M.tokens[0].text,M.tokens[0].tokens&&M.tokens[0].tokens.length>0&&M.tokens[0].tokens[0].type==="text"&&(M.tokens[0].tokens[0].text=q+" "+M.tokens[0].tokens[0].text)):M.tokens.unshift({type:"text",text:q}):S+=q),S+=this.parse(M.tokens,E),d+=this.renderer.listitem(S,H,R);n+=this.renderer.list(d,w,T);continue}case"html":{n+=this.renderer.html(u.text);continue}case"paragraph":{n+=this.renderer.paragraph(this.parseInline(u.tokens));continue}case"text":{for(d=u.tokens?this.parseInline(u.tokens):u.text;s+1<D&&e[s+1].type==="text";)u=e[++s],d+=`
45
- `+(u.tokens?this.parseInline(u.tokens):u.text);n+=t?this.renderer.paragraph(d):d;continue}default:{const G='Token with "'+u.type+'" type was not found.';if(this.options.silent){console.error(G);return}else throw new Error(G)}}}return n}parseInline(e,t){t=t||this.renderer;let n="",s,r,l;const a=e.length;for(s=0;s<a;s++){if(r=e[s],this.options.extensions&&this.options.extensions.renderers&&this.options.extensions.renderers[r.type]&&(l=this.options.extensions.renderers[r.type].call({parser:this},r),l!==!1||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(r.type))){n+=l||"";continue}switch(r.type){case"escape":{n+=t.text(r.text);break}case"html":{n+=t.html(r.text);break}case"link":{n+=t.link(r.href,r.title,this.parseInline(r.tokens,t));break}case"image":{n+=t.image(r.href,r.title,r.text);break}case"strong":{n+=t.strong(this.parseInline(r.tokens,t));break}case"em":{n+=t.em(this.parseInline(r.tokens,t));break}case"codespan":{n+=t.codespan(r.text);break}case"br":{n+=t.br();break}case"del":{n+=t.del(this.parseInline(r.tokens,t));break}case"text":{n+=t.text(r.text);break}default:{const o='Token with "'+r.type+'" type was not found.';if(this.options.silent){console.error(o);return}else throw new Error(o)}}}return n}}class bt{constructor(e){this.options=e||Ae}static passThroughHooks=new Set(["preprocess","postprocess"]);preprocess(e){return e}postprocess(e){return e}}function vs(i,e,t){return n=>{if(n.message+=`
46
- Please report this to https://github.com/markedjs/marked.`,i){const s="<p>An error occurred:</p><pre>"+Y(n.message+"",!0)+"</pre>";if(e)return Promise.resolve(s);if(t){t(null,s);return}return s}if(e)return Promise.reject(n);if(t){t(n);return}throw n}}function un(i,e){return(t,n,s)=>{typeof n=="function"&&(s=n,n=null);const r={...n};n={...b.defaults,...r};const l=vs(n.silent,n.async,s);if(typeof t>"u"||t===null)return l(new Error("marked(): input parameter is undefined or null"));if(typeof t!="string")return l(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(t)+", string expected"));if(ps(n),n.hooks&&(n.hooks.options=n),s){const a=n.highlight;let o;try{n.hooks&&(t=n.hooks.preprocess(t)),o=i(t,n)}catch(g){return l(g)}const c=function(g){let d;if(!g)try{n.walkTokens&&b.walkTokens(o,n.walkTokens),d=e(o,n),n.hooks&&(d=n.hooks.postprocess(d))}catch(u){g=u}return n.highlight=a,g?l(g):s(null,d)};if(!a||a.length<3||(delete n.highlight,!o.length))return c();let h=0;b.walkTokens(o,function(g){g.type==="code"&&(h++,setTimeout(()=>{a(g.text,g.lang,function(d,u){if(d)return c(d);u!=null&&u!==g.text&&(g.text=u,g.escaped=!0),h--,h===0&&c()})},0))}),h===0&&c();return}if(n.async)return Promise.resolve(n.hooks?n.hooks.preprocess(t):t).then(a=>i(a,n)).then(a=>n.walkTokens?Promise.all(b.walkTokens(a,n.walkTokens)).then(()=>a):a).then(a=>e(a,n)).then(a=>n.hooks?n.hooks.postprocess(a):a).catch(l);try{n.hooks&&(t=n.hooks.preprocess(t));const a=i(t,n);n.walkTokens&&b.walkTokens(a,n.walkTokens);let o=e(a,n);return n.hooks&&(o=n.hooks.postprocess(o)),o}catch(a){return l(a)}}}function b(i,e,t){return un(Me.lex,qe.parse)(i,e,t)}b.options=b.setOptions=function(i){return b.defaults={...b.defaults,...i},ts(b.defaults),b};b.getDefaults=sn;b.defaults=Ae;b.use=function(...i){const e=b.defaults.extensions||{renderers:{},childTokens:{}};i.forEach(t=>{const n={...t};if(n.async=b.defaults.async||n.async||!1,t.extensions&&(t.extensions.forEach(s=>{if(!s.name)throw new Error("extension name required");if(s.renderer){const r=e.renderers[s.name];r?e.renderers[s.name]=function(...l){let a=s.renderer.apply(this,l);return a===!1&&(a=r.apply(this,l)),a}:e.renderers[s.name]=s.renderer}if(s.tokenizer){if(!s.level||s.level!=="block"&&s.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");e[s.level]?e[s.level].unshift(s.tokenizer):e[s.level]=[s.tokenizer],s.start&&(s.level==="block"?e.startBlock?e.startBlock.push(s.start):e.startBlock=[s.start]:s.level==="inline"&&(e.startInline?e.startInline.push(s.start):e.startInline=[s.start]))}s.childTokens&&(e.childTokens[s.name]=s.childTokens)}),n.extensions=e),t.renderer){const s=b.defaults.renderer||new Bt;for(const r in t.renderer){const l=s[r];s[r]=(...a)=>{let o=t.renderer[r].apply(s,a);return o===!1&&(o=l.apply(s,a)),o}}n.renderer=s}if(t.tokenizer){const s=b.defaults.tokenizer||new Ht;for(const r in t.tokenizer){const l=s[r];s[r]=(...a)=>{let o=t.tokenizer[r].apply(s,a);return o===!1&&(o=l.apply(s,a)),o}}n.tokenizer=s}if(t.hooks){const s=b.defaults.hooks||new bt;for(const r in t.hooks){const l=s[r];bt.passThroughHooks.has(r)?s[r]=a=>{if(b.defaults.async)return Promise.resolve(t.hooks[r].call(s,a)).then(c=>l.call(s,c));const o=t.hooks[r].call(s,a);return l.call(s,o)}:s[r]=(...a)=>{let o=t.hooks[r].apply(s,a);return o===!1&&(o=l.apply(s,a)),o}}n.hooks=s}if(t.walkTokens){const s=b.defaults.walkTokens;n.walkTokens=function(r){let l=[];return l.push(t.walkTokens.call(this,r)),s&&(l=l.concat(s.call(this,r))),l}}b.setOptions(n)})};b.walkTokens=function(i,e){let t=[];for(const n of i)switch(t=t.concat(e.call(b,n)),n.type){case"table":{for(const s of n.header)t=t.concat(b.walkTokens(s.tokens,e));for(const s of n.rows)for(const r of s)t=t.concat(b.walkTokens(r.tokens,e));break}case"list":{t=t.concat(b.walkTokens(n.items,e));break}default:b.defaults.extensions&&b.defaults.extensions.childTokens&&b.defaults.extensions.childTokens[n.type]?b.defaults.extensions.childTokens[n.type].forEach(function(s){t=t.concat(b.walkTokens(n[s],e))}):n.tokens&&(t=t.concat(b.walkTokens(n.tokens,e)))}return t};b.parseInline=un(Me.lexInline,qe.parseInline);b.Parser=qe;b.parser=qe.parse;b.Renderer=Bt;b.TextRenderer=on;b.Lexer=Me;b.lexer=Me.lex;b.Tokenizer=Ht;b.Slugger=cn;b.Hooks=bt;b.parse=b;b.options;b.setOptions;b.use;b.walkTokens;b.parseInline;qe.parse;Me.lex;const ks="modulepreload",bs=function(i){return"/"+i},Gt={},hn=function(e,t,n){let s=Promise.resolve();if(t&&t.length>0){let o=function(c){return Promise.all(c.map(h=>Promise.resolve(h).then(g=>({status:"fulfilled",value:g}),g=>({status:"rejected",reason:g}))))};document.getElementsByTagName("link");const l=document.querySelector("meta[property=csp-nonce]"),a=l?.nonce||l?.getAttribute("nonce");s=o(t.map(c=>{if(c=bs(c),c in Gt)return;Gt[c]=!0;const h=c.endsWith(".css"),g=h?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${c}"]${g}`))return;const d=document.createElement("link");if(d.rel=h?"stylesheet":ks,h||(d.as="script"),d.crossOrigin="",d.href=c,a&&d.setAttribute("nonce",a),document.head.appendChild(d),h)return new Promise((u,w)=>{d.addEventListener("load",u),d.addEventListener("error",()=>w(new Error(`Unable to preload CSS for ${c}`)))})}))}function r(l){const a=new Event("vite:preloadError",{cancelable:!0});if(a.payload=l,window.dispatchEvent(a),!a.defaultPrevented)throw l}return s.then(l=>{for(const a of l||[])a.status==="rejected"&&r(a.reason);return e().catch(r)})},dn=async i=>{try{(await hn(async()=>{const{default:t}=await import("./index-eUfJTxoU.js");return{default:t}},[])).default.highlightElement(i)}catch(e){console.error("Could not load highlight.js",e)}};var ws=C('<div class="markdown-body"><!></div>');function xs(i,e){$(e,!0);let t=ce(void 0);ae(()=>{e.das&&p(t)&&setTimeout(()=>{p(t)&&Array.from(p(t).querySelectorAll("pre code")).forEach(r=>{dn(r)})},200)});var n=ws(),s=f(n);It(s,()=>b(e.das.descriptionfile||e.das.description)),$e(n,r=>J(t,r),()=>p(t)),v(i,n),ee()}var _s=C('<pre><code class="language-xml"> </code></pre>'),Ss=C("<div><!> <!></div>");function ys(i,e){$(e,!0);let t=ce(void 0),n=ce(void 0),s=ce(tn([]));e.devmodus||r();async function r(){const d=await hn(()=>import("../raw_component_import_map.js"),[]);J(s,d.rawComponentMap,!0)}function l(d,u){J(t,null),setTimeout(()=>{J(t,u[d],!0)})}ae(()=>{l(e.componentName,p(s))}),ae(()=>{p(t)&&p(n)&&dn(p(n))});var a=Ss(),o=f(a);{var c=d=>{var u=nn("Running Gardenjs in devmodus. No Code view supported.");v(d,u)};O(o,d=>{e.devmodus&&d(c)})}var h=_(o,2);{var g=d=>{var u=_s(),w=f(u),T=f(w);$e(w,E=>J(n,E),()=>p(n)),F(()=>oe(T,p(t))),v(d,u)};O(h,d=>{p(t)&&d(g)})}v(i,a),ee()}var zs=C('<iframe class="stage_iframe svelte-17n05ij" title="preview" src="/frame.html"></iframe>'),Ts=C('<div class="panel svelte-17n05ij"><!></div>');function Es(i,e){$(e,!0);let t=U(e,"das",19,()=>({})),n=ce(void 0),s=ce(void 0);const r=new ResizeObserver(c=>{c.forEach(h=>{e.onUpdateStageRect(h.contentRect)})});$t(()=>{p(s)&&(r.observe(p(s)),p(s).contentWindow.onload=()=>{J(n,!0)},p(s).contentWindow.addEventListener("mousemove",function(c){var h=p(s).getBoundingClientRect(),g=new CustomEvent("mousemove",{bubbles:!0,cancelable:!1});g.pageX=c.clientX+h.left,g.pageY=c.clientY+h.top,p(s).dispatchEvent(g)}),p(s).contentWindow.addEventListener("mouseup",function(){var c=new CustomEvent("mouseup",{bubbles:!0,cancelable:!1});p(s).dispatchEvent(c)}))}),en(()=>{r.disconnect()});function l(c){const h=[];return c.description&&h.push({name:"Notes",props:{das:c},page:xs}),c.examples?.length&&h.push({name:"Examples",props:{selected:e.selectedExample,examples:c.examples.map(g=>g.title),onSelectExample:a},page:es}),!e.devmodus&&c.componentfile&&h.push({name:"Code",props:{componentName:e.componentName,devmodus:e.devmodus},page:ys}),h}function a(c){globalThis.history.pushState({selectedExample:c},"",window.location.pathname.substring(7))}ae(()=>{p(n)&&(!p(s).contentDocument||/frame.html$/.test(p(s).contentWindow.location),p(s).contentWindow.postMessage({selectedExample:e.selectedExample,componentName:e.componentName,stageSize:e.stageSize,theme:e.theme,appTheme:e.appTheme,showInspector:e.showInspector,showGrid:e.showGrid,gridSettings:e.gridSettings},window.location))});const o=se(()=>l(t()));Dn(i,{get topHeight(){return e.stageContainerHeight},get maxHeight(){return e.stageContainerMaxHeight},get onSetTopHeight(){return e.onSetStageContainerHeight},get onSetMaxHeight(){return e.onSetStageContainerMaxHeight},get onSetMaxWidth(){return e.onSetStageContainerWidth},top:g=>{{let d=se(()=>e.stageSize!=="full");Zn(g,{get disabled(){return p(d)},get maxHeight(){return e.stageMaxHeight},get maxWidth(){return e.stageMaxWidth},get paneHeight(){return e.stageHeight},get paneWidth(){return e.stageWidth},get onSetStageHeight(){return e.onSetStageHeight},get onSetStageWidth(){return e.onSetStageWidth},children:(u,w)=>{var T=zs();$e(T,E=>J(s,E),()=>p(s)),F(()=>qt(T,e.stageStyle)),v(u,T)},$$slots:{default:!0}})}},bottom:g=>{var d=Ts(),u=f(d);{var w=T=>{Kn(T,{get tabs(){return p(o)},get onToggleExpandPanel(){return e.onToggleExpandPanel}})};O(u,T=>{e.panelExpanded&&T(w)})}v(g,d)},$$slots:{top:!0,bottom:!0}}),ee()}function Cs(i,e){i.button!==0||i.metaKey||i.ctrlKey||i.shiftKey||i.altKey||(i.preventDefault(),globalThis.history.pushState({},"",e.href))}var Rs=C('<a><div class="component_link-container svelte-1cnyrt6"><div class="component_dot svelte-1cnyrt6"></div> <div class="component_icon svelte-1cnyrt6"><svg xmlns="http://www.w3.org/2000/svg" width="15" viewBox="0 0 24 24" height="15" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><path d="M21 8a2 2 0 00-1-1.73l-7-4a2 2 0 00-2 0l-7 4A2 2 0 003 8v8a2 2 0 001 1.73l7 4a2 2 0 002 0l7-4A2 2 0 0021 16z"></path><path d="M3.3 7l8.7 5 8.7-5M12 22V12"></path></svg></div> <div class="component_label svelte-1cnyrt6"><!></div></div></a>');function gn(i,e){var t=Rs();let n;t.__click=[Cs,e];var s=f(t),r=_(f(s),4),l=f(r);It(l,()=>e.text),F(a=>{te(t,"href",e.href),n=W(t,1,"component_link svelte-1cnyrt6",null,n,a)},[()=>({selected:e.selected})]),v(i,t)}de(["click"]);var Ms=(i,e,t)=>e.onToggleBookmark(p(t)),qs=C('<li class="component svelte-qxg2ml"><!> <button class="close svelte-qxg2ml"><svg xmlns="http://www.w3.org/2000/svg" class="close-icon svelte-qxg2ml" height="12" viewBox="0 0 24 24" width="12" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M18 6L6 18M6 6l12 12"></path></svg></button></li>'),Is=C('<div class="bookmarks svelte-qxg2ml"><div class="bookmarks_title svelte-qxg2ml"><span class="bookmarks_title-icon svelte-qxg2ml"><svg xmlns="http://www.w3.org/2000/svg" class="bookmark_icon" height="15" viewBox="0 0 24 24" width="15" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M12 2l3.09 6.26L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l6.91-1.01L12 2z"></path></svg></span> <span class="bookmarks_title-label svelte-qxg2ml">Bookmarks</span></div> <nav class="bookmarks_nav"><ul class="components svelte-qxg2ml"></ul></nav> <div class="border-btm svelte-qxg2ml"></div></div>');function Ls(i,e){$(e,!0);let t=U(e,"bookmarks",19,()=>[]);var n=Is(),s=_(f(n),2),r=f(s);et(r,21,t,l=>l.key,(l,a)=>{var o=qs(),c=f(o);gn(c,{get href(){return p(a).href},get selected(){return p(a).selected},get text(){return p(a).name}});var h=_(c,2);h.__click=[Ms,e,a],v(l,o)}),v(i,n),ee()}de(["click"]);var Hs=C('<li class="component svelte-1nn9bvq"><!></li>'),Bs=(i,e,t)=>e.onToggleFoldStatusOfNode({...p(t)}),Ns=C('<li><button><span><svg xmlns="http://www.w3.org/2000/svg" width="12" viewBox="0 0 24 24" height="12" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M18 15l-6-6-6 6"></path></svg></span> <span class="folder_icon svelte-1nn9bvq"><svg xmlns="http://www.w3.org/2000/svg" width="15" viewBox="0 0 24 24" height="15" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><path d="M4 20h16a2 2 0 002-2V8a2 2 0 00-2-2h-7.93a2 2 0 01-1.66-.9l-.82-1.2A2 2 0 007.93 3H4a2 2 0 00-2 2v13c0 1.1.9 2 2 2z"></path></svg></span> <span class="folder_label svelte-1nn9bvq"><!></span></button> <!></li>'),As=C("<ul></ul>");function pn(i,e){$(e,!0);let t=U(e,"nodes",19,()=>[]),n=U(e,"level",3,1);var s=As();et(s,21,t,r=>r.key,(r,l)=>{var a=Re(),o=me(a);{var c=g=>{var d=Hs(),u=f(d);gn(u,{get href(){return p(l).href},get selected(){return p(l).selected},get text(){return p(l).name}}),v(g,d)},h=g=>{var d=Ns();let u;var w=f(d);w.__click=[Bs,e,l];var T=f(w);let E;var S=_(T,4),M=f(S);It(M,()=>p(l).name);var R=_(w,2);{var H=q=>{{let I=se(()=>n()+1);pn(q,{get nodes(){return p(l).children},get level(){return p(I)},get onToggleFoldStatusOfNode(){return e.onToggleFoldStatusOfNode}})}};O(R,q=>{p(l).unfolded&&q(H)})}F((q,I)=>{u=W(d,1,"folder svelte-1nn9bvq",null,u,q),W(w,1,`folder_btn btn_level-${n()??""}`,"svelte-1nn9bvq"),te(w,"title",p(l).unfolded?"fold":"unfold"),E=W(T,1,"folder_arrow svelte-1nn9bvq",null,E,I)},[()=>({unfolded:p(l).unfolded}),()=>({unfolded_icon:p(l).unfolded})]),v(g,d)};O(o,g=>{p(l).isLeaf?g(c):g(h,!1)})}v(r,a)}),F(()=>W(s,1,`filter_list components level-${n()??""}`,"svelte-1nn9bvq")),v(i,s),ee()}de(["click"]);var js=C('<img title="start"/>'),Ws=C('<img title="start"/>'),Os=C('<span class="svelte-1oee4bz"> </span>'),Ps=(i,e)=>e.onUpdateFilter(i.target.value),Ds=C('<div><div class="filter_zero-results svelte-1oee4bz"> </div></div>'),Us=C('<!> <nav class="components-nav svelte-1oee4bz"><!></nav>',1),Zs=ke('<svg class="controls_btn-icon svelte-1oee4bz" xmlns="http://www.w3.org/2000/svg" height="20" viewBox="0 0 24 24" width="20" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><path d="M7 20l5-5 5 5M7 4l5 5 5-5"></path></svg>'),Fs=ke('<svg class="controls_btn-icon svelte-1oee4bz" xmlns="http://www.w3.org/2000/svg" height="20" viewBox="0 0 24 24" width="20" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><path d="M7 15l5 5 5-5M7 9l5-5 5 5"></path></svg>'),Gs=ke('<svg class="controls_btn-icon svelte-1oee4bz" xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><rect width="18" height="18" x="3" y="3" rx="2" ry="2"></rect><line x1="3" x2="21" y1="15" y2="15"></line><path d="m15 8-3 3-3-3"></path></svg>'),Qs=ke('<svg class="controls_btn-icon svelte-1oee4bz" xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><rect width="18" height="18" x="3" y="3" rx="2" ry="2"></rect><line x1="3" x2="21" y1="15" y2="15"></line><path d="m9 10 3-3 3 3"></path></svg>'),Vs=C('<li><a class="controls_btn svelte-1oee4bz" href="https://gardenjs.org/docs" target="_blank" rel="noreferrer"><svg class="controls_btn-icon svelte-1oee4bz" xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="10"></circle><path d="M9.09 9a3 3 0 015.83 1c0 2-3 3-3 3m.08 4h.01"></path></svg> <span class="controls_btn-label svelte-1oee4bz">Gardenjs Docs</span></a></li>'),Xs=C('<header><a href="/"><!></a> <div class="filter svelte-1oee4bz"><input aria-autocomplete="list" id="filter" class="filter_input svelte-1oee4bz" autocomplete="off" type="search" placeholder="Filter..."/></div> <!> <nav class="controls svelte-1oee4bz"><ul><li><button class="controls_btn svelte-1oee4bz"><!> <span class="controls_btn-label svelte-1oee4bz"> </span></button></li> <li><button class="controls_btn svelte-1oee4bz"><!> <span class="controls_btn-label svelte-1oee4bz"> </span></button></li> <!></ul></nav></header>');function Ks(i,e){$(e,!0);let t=U(e,"bookmarks",19,()=>[]),n=U(e,"nodes",19,()=>[]),s=U(e,"panelExpanded",3,!0),r=U(e,"rootNodesExpanded",3,!0),l=U(e,"sidebarExpanded",3,!0);var a=Xs();let o;var c=f(a);let h;var g=f(c);{var d=y=>{var L=js();F(()=>{te(L,"src",`/assets/${e.projectLogoDarkmode??""}`),te(L,"alt",`${e.projectTitle??""} logo`)}),v(y,L)},u=y=>{var L=Re(),ue=me(L);{var he=Z=>{var Q=Ws();F(()=>{te(Q,"src",`/assets/${e.projectLogo??""}`),te(Q,"alt",`${e.projectTitle??""} logo`)}),v(Z,Q)},Se=Z=>{var Q=Os(),ye=f(Q);F(()=>oe(ye,e.projectTitle)),v(Z,Q)};O(ue,Z=>{e.projectLogo?Z(he):Z(Se,!1)},!0)}v(y,L)};O(g,y=>{e.projectLogoDarkmode&&e.appTheme==="dark"?y(d):y(u,!1)})}var w=_(c,2),T=f(w);T.__input=[Ps,e];var E=_(w,2);{var S=y=>{var L=Ds(),ue=f(L),he=f(ue);F(()=>oe(he,`No results for '${e.filter??""}'`)),v(y,L)},M=y=>{var L=Us(),ue=me(L);{var he=Q=>{Ls(Q,{get bookmarks(){return t()},get onToggleBookmark(){return e.onToggleBookmark}})};O(ue,Q=>{t().length>0&&Q(he)})}var Se=_(ue,2),Z=f(Se);pn(Z,{get nodes(){return n()},get onToggleFoldStatusOfNode(){return e.onToggleFoldStatusOfNode}}),v(y,L)};O(E,y=>{n().length==0&&e.filter?y(S):y(M,!1)})}var R=_(E,2),H=f(R),q=f(H),I=f(q);I.__click=function(...y){e.onToggleRootFolders?.apply(this,y)};var D=f(I);{var G=y=>{var L=Zs();v(y,L)},B=y=>{var L=Fs();v(y,L)};O(D,y=>{r()?y(G):y(B,!1)})}var j=_(D,2),Ie=f(j),be=_(q,2),we=f(be);we.__click=function(...y){e.onToggleExpandPanel?.apply(this,y)};var ge=f(we);{var We=y=>{var L=Gs();v(y,L)},Le=y=>{var L=Qs();v(y,L)};O(ge,y=>{s()?y(We):y(Le,!1)})}var Ge=_(ge,2),Qe=f(Ge),Oe=_(be,2);{var xe=y=>{var L=Vs();v(y,L)};O(Oe,y=>{e.docsLink===1&&y(xe)})}F((y,L)=>{o=W(a,1,"sidebar_container svelte-1oee4bz",null,o,y),h=W(c,1,"project-identifier svelte-1oee4bz",null,h,L),kt(T,e.filter||""),te(I,"title",r()?"Collapse":"Restore"),oe(Ie,`${r()?"Collapse":"Expand"} Navigation`),te(we,"title",s()?"Collapse":"Restore"),oe(Qe,`${s()?"Collapse":"Expand"} Panel`)},[()=>({"show-sidebar":l()}),()=>({"has-logo":e.projectLogo})]),v(i,a),ee()}de(["input","click"]);var Ys=(i,e,t)=>e.handleButtonClick(p(t).name),Js=C('<li class="svelte-4algbe"><button><span class="dropdown_item-dot svelte-4algbe"></span> </button></li>'),$s=C('<div class="dropdown svelte-4algbe"><!> <div><ul class="svelte-4algbe"></ul></div></div>');function lt(i,e){$(e,!0);let t=U(e,"options",19,()=>[]),n=U(e,"dropright",3,!1);var s=Re(),r=me(s);{var l=o=>{var c=$s(),h=f(c);Fe(h,()=>e.buttonSnippet??Ze);var g=_(h,2);let d;var u=f(g);et(u,21,t,w=>w.name,(w,T)=>{var E=Js(),S=f(E);S.__click=[Ys,e,T];let M;var R=_(f(S));F(H=>{M=W(S,1,"svelte-4algbe",null,M,H),oe(R,` ${p(T).name??""}`)},[()=>({active:p(T).active})]),v(w,E)}),F(w=>d=W(g,1,"dropdown_items svelte-4algbe",null,d,w),[()=>({"dropdown_items-right":n()})]),v(o,c)},a=o=>{var c=Re(),h=me(c);Fe(h,()=>e.buttonSnippet??Ze,()=>({onClick:()=>{e.handleButtonClick(t()[0].name)}})),v(o,c)};O(r,o=>{t().length>1?o(l):o(a,!1)})}v(i,s),ee()}de(["click"]);var ei=ke('<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" class="svelte-12qmtz"><rect x="3" y="3" width="18" height="18" rx="2" ry="2"></rect><path d="M9 3v18m7-6l-3-3 3-3"></path></svg>'),ti=ke('<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" class="svelte-12qmtz"><rect x="3" y="3" width="18" height="18" rx="2" ry="2"></rect><path d="M9 3v18m5-12l3 3-3 3"></path></svg>'),ni=(i,e)=>e.onToggleBookmark(e.node),si=ke('<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" fill="currentColor" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" class="svelte-12qmtz"><path d="M12 2l3.09 6.26L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l6.91-1.01L12 2z"></path></svg>'),ii=ke('<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" class="svelte-12qmtz"><path d="M12 2l3.09 6.26L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l6.91-1.01L12 2z"></path></svg>'),ri=C('<button class="topbar_btn bookmark_btn svelte-12qmtz"><span class="is-hidden svelte-12qmtz"> </span> <!></button>'),li=C('<button title="Small"><span class="is-hidden svelte-12qmtz">Resize viewport to small</span> <svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><rect x="5" y="2" width="14" height="20" rx="2" ry="2"></rect><path d="M12 18h.01"></path></svg> <span class="dot svelte-12qmtz"></span></button>'),ai=C('<button title="Medium"><span class="is-hidden svelte-12qmtz">Resize viewport to medium</span> <svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><rect x="4" y="2" width="16" height="20" rx="2" ry="2"></rect><path d="M12 18h.01"></path></svg> <span class="dot svelte-12qmtz"></span></button>'),oi=C('<button title="Large"><span class="is-hidden svelte-12qmtz">Resize viewport to large</span> <svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><rect x="3" y="4" width="18" height="12" rx="2" ry="2"></rect><path d="M2 20h20"></path></svg> <span class="dot svelte-12qmtz"></span></button>'),ci=(i,e)=>e.onSetStageSize("full"),ui=(i,e)=>{e.onSetStageWidth(Number.parseInt(i.target.value))},hi=(i,e)=>{e.onSetStageHeight(Number.parseInt(i.target.value))},di=C('<button class="dropdown_btn topbar_btn svelte-12qmtz" title="Switch component theme"><span class="is-hidden svelte-12qmtz">Open menu for selecting themes</span> <svg xmlns="http://www.w3.org/2000/svg" width="24" viewBox="0 0 24 24" height="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" class="svelte-12qmtz"><circle cx="13.5" cy="6.5" r=".5"></circle><circle cx="17.5" cy="10.5" r=".5"></circle><circle cx="8.5" cy="7.5" r=".5"></circle><circle cx="6.5" cy="12.5" r=".5"></circle><path d="M12 2C6.5 2 2 6.5 2 12s4.5 10 10 10c.926 0 1.648-.746 1.648-1.688 0-.437-.18-.835-.437-1.125-.29-.289-.438-.652-.438-1.125a1.64 1.64 0 011.668-1.668h1.996c3.051 0 5.555-2.503 5.555-5.554C21.965 6.012 17.461 2 12 2z"></path></svg></button>'),gi=ke('<svg xmlns="http://www.w3.org/2000/svg" class="mode-icon svelte-12qmtz" width="24" viewBox="0 0 24 24" height="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="4"></circle><path d="M12 2v2m0 16v2M4.93 4.93l1.41 1.41m11.32 11.32l1.41 1.41M2 12h2m16 0h2M6.34 17.66l-1.41 1.41M19.07 4.93l-1.41 1.41"></path></svg>'),pi=ke('<svg xmlns="http://www.w3.org/2000/svg" class="mode-icon svelte-12qmtz" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><path d="M12 3a6.364 6.364 0 009 9 9 9 0 11-9-9z"></path></svg>'),fi=C('<div class="topbar svelte-12qmtz"><div class="topbar_container svelte-12qmtz"><div class="topbar_nav svelte-12qmtz"><button class="topbar_btn is-first-btn svelte-12qmtz"><span class="is-hidden svelte-12qmtz"> </span> <!></button> <!></div> <div class="topbar_nav svelte-12qmtz"><div class="stagesize-nav svelte-12qmtz"><!> <!> <!> <button title="Full"><span class="is-hidden svelte-12qmtz">Resize viewport to full</span> <svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" class="svelte-12qmtz"><rect x="2" y="3" width="20" height="14" rx="2" ry="2"></rect><path d="M8 21h8m-4-4v4"></path></svg> <span class="dot svelte-12qmtz"></span></button> <button class="svelte-12qmtz"><span class="is-hidden svelte-12qmtz"> </span> <svg xmlns="http://www.w3.org/2000/svg" width="24" viewBox="0 0 24 24" height="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" class="svelte-12qmtz"><rect width="12" height="20" x="6" y="2" rx="2"></rect><rect width="20" height="12" x="2" y="6" rx="2"></rect></svg></button></div> <div class="stagesize-value svelte-12qmtz"><input class="stagesize-input svelte-12qmtz" type="number" min="50"/> <div class="stagesize-value-multi_sign svelte-12qmtz">&#47;</div> <input class="stagesize-input svelte-12qmtz" type="number" min="50"/></div> <button title="Show background grid"><span class="is-hidden svelte-12qmtz">Show background grid</span> <svg xmlns="http://www.w3.org/2000/svg" width="24" viewBox="0 0 24 24" height="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" class="svelte-12qmtz"><rect width="18" height="18" x="3" y="3" rx="2"></rect><path d="M3 9h18M3 15h18M9 3v18m6-18v18"></path></svg> <span class="dot svelte-12qmtz"></span></button> <button title="Visualise margins and paddings"><span class="is-hidden svelte-12qmtz">Visualise margins and paddings</span> <svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" class="svelte-12qmtz"><path d="M12 15v-3.014M16 15v-3.014M20 6H4m16 2V4M4 8V4m4 11v-3.014"></path><rect x="3" y="12" width="18" height="7" rx="1"></rect></svg> <span class="dot svelte-12qmtz"></span></button> <button class="topbar_btn openexternal_btn svelte-12qmtz" title="Open component in new tab"><span class="is-hidden svelte-12qmtz">Open component in new tab</span> <svg xmlns="http://www.w3.org/2000/svg" class="open-new-tab-icon svelte-12qmtz" height="24" viewBox="0 0 24 24" width="24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><path d="M18 13v6a2 2 0 01-2 2H5a2 2 0 01-2-2V8a2 2 0 012-2h6m4-3h6v6m-11 5L21 3"></path></svg></button> <!> <button class="topbar_btn is-last-btn svelte-12qmtz"><span class="is-hidden svelte-12qmtz"> </span> <!></button></div></div></div>');function mi(i,e){$(e,!0);let t=U(e,"appTheme",3,"default"),n=U(e,"landscape",3,!1),s=U(e,"sidebarExpanded",3,!0),r=U(e,"stageSize",3,"full"),l=U(e,"stageSizes",19,()=>({})),a=U(e,"themes",19,()=>[]),o=ce(!1);const c=se(()=>Math.round(e.stageRect.width)),h=se(()=>Math.round(e.stageRect.height));ae(()=>{J(o,t()==="dark"),t()==="dark"?document.documentElement.setAttribute("data-theme","dark"):document.documentElement.setAttribute("data-theme","light")});var g=fi(),d=f(g),u=f(d),w=f(u);w.__click=function(...x){e.onToggleExpandSidebar?.apply(this,x)};var T=f(w),E=f(T),S=_(T,2);{var M=x=>{var V=ei();v(x,V)},R=x=>{var V=ti();v(x,V)};O(S,x=>{s()?x(M):x(R,!1)})}var H=_(w,2);{var q=x=>{var V=ri();V.__click=[ni,e];var ie=f(V),_e=f(ie),Be=_(ie,2);{var K=re=>{var le=si();v(re,le)},pe=re=>{var le=ii();v(re,le)};O(Be,re=>{e.node.bookmark?re(K):re(pe,!1)})}F(()=>oe(_e,e.node.bookmark?"Remove from bookmarks":"Add to bookmarks")),v(x,V)};O(H,x=>{e.node&&x(q)})}var I=_(u,2),D=f(I),G=f(D);{var B=x=>{lt(x,{get options(){return l().small},get handleButtonClick(){return e.onSetStageSize},buttonSnippet:(ie,_e)=>{let Be=()=>_e?.().onClick;var K=li();let pe;K.__click=function(...X){Be()?.apply(this,X)};var re=_(f(K),2);let le;F((X,Ve)=>{pe=W(K,1,"dropdown_btn topbar_btn svelte-12qmtz",null,pe,X),le=W(re,0,"svelte-12qmtz",null,le,Ve)},[()=>({active:l().small.some(X=>X.active)}),()=>({landscape:n()})]),v(ie,K)},$$slots:{buttonSnippet:!0}})};O(G,x=>{l().small?.length>0&&x(B)})}var j=_(G,2);{var Ie=x=>{lt(x,{get options(){return l().medium},get handleButtonClick(){return e.onSetStageSize},buttonSnippet:(ie,_e)=>{let Be=()=>_e?.().onClick;var K=ai();let pe;K.__click=function(...X){Be()?.apply(this,X)};var re=_(f(K),2);let le;F((X,Ve)=>{pe=W(K,1,"dropdown_btn topbar_btn svelte-12qmtz",null,pe,X),le=W(re,0,"svelte-12qmtz",null,le,Ve)},[()=>({active:l().medium.some(X=>X.active)}),()=>({landscape:n()})]),v(ie,K)},$$slots:{buttonSnippet:!0}})};O(j,x=>{l().medium?.length>0&&x(Ie)})}var be=_(j,2);{var we=x=>{lt(x,{get options(){return l().large},get handleButtonClick(){return e.onSetStageSize},buttonSnippet:(ie,_e)=>{let Be=()=>_e?.().onClick;var K=oi();let pe;K.__click=function(...X){Be()?.apply(this,X)};var re=_(f(K),2);let le;F((X,Ve)=>{pe=W(K,1,"dropdown_btn topbar_btn svelte-12qmtz",null,pe,X),le=W(re,0,"svelte-12qmtz",null,le,Ve)},[()=>({active:l().large.some(X=>X.active)}),()=>({landscape:n()})]),v(ie,K)},$$slots:{buttonSnippet:!0}})};O(be,x=>{l().large?.length>0&&x(we)})}var ge=_(be,2);ge.__click=[ci,e];let We;var Le=_(ge,2);Le.__click=function(...x){e.onToggleOrientation?.apply(this,x)};var Ge=f(Le),Qe=f(Ge),Oe=_(D,2),xe=f(Oe);xe.__change=[ui,e];var y=_(xe,4);y.__change=[hi,e];var L=_(Oe,2);let ue;L.__click=function(...x){e.onToggleShowGrid?.apply(this,x)};var he=_(L,2);let Se;he.__click=function(...x){e.onToggleShowInspector?.apply(this,x)};var Z=_(he,2);Z.__click=function(...x){e.onOpenInTab?.apply(this,x)};var Q=_(Z,2);{var ye=x=>{lt(x,{get options(){return a()},dropright:!0,get handleButtonClick(){return e.onSetTheme},buttonSnippet:ie=>{var _e=di();v(ie,_e)},$$slots:{buttonSnippet:!0}})};O(Q,x=>{a().length>1&&x(ye)})}var He=_(Q,2);He.__click=function(...x){e.onToggleAppTheme?.apply(this,x)};var st=f(He),it=f(st),vt=_(st,2);{var yn=x=>{var V=gi();v(x,V)},zn=x=>{var V=pi();v(x,V)};O(vt,x=>{p(o)?x(yn):x(zn,!1)})}F((x,V,ie)=>{te(w,"title",s()?"Collapse sidebar":"Expand sidebar"),oe(E,s()?"Collapse sidebar":"Expand sidebar"),We=W(ge,1,"svelte-12qmtz",null,We,x),te(Le,"title",n()?"Portrait mode":"Landscape mode"),oe(Qe,`Reverse the aspect ratio to ${n()?"portrait mode":"landscape mode"}`),xe.disabled=r()!=="full",kt(xe,p(c)),te(xe,"max",e.stageMaxWidth),y.disabled=r()!=="full",kt(y,p(h)),te(y,"max",e.stageMaxHeight),ue=W(L,1,"topbar_btn show-grid svelte-12qmtz",null,ue,V),Se=W(he,1,"topbar_btn show-m-p_btn svelte-12qmtz",null,Se,ie),te(He,"title",p(o)?"Light mode":"Dark mode"),oe(it,p(o)?"Light mode":"Dark mode")},[()=>({active:r()==="full"}),()=>({active:e.showGrid===!0}),()=>({active:e.showInspector===!0})]),v(i,g),ee()}de(["click","change"]);function pt(i,e,t=s=>s,n=s=>s){const s=P(t(localStorage.getItem(i))??e);return s.subscribe(r=>{localStorage.setItem(i,n(r))}),s}const ze=P([]),Ye=P({small:[{name:"small",h:1170,w:550}],medium:[{name:"medium",h:1080,w:810}],large:[{name:"large",h:960,w:1536}]}),Qt={name:"full",h:"100%",w:"100%"},fn=P(""),Nt=pt("stageSize","full"),ct=pt("landscape",!1,i=>i==="true"),Ee=P(""),mn=P(""),Ce=P(""),wt=P("full"),xt=P("full"),vi=Lt([Ee,Ce],([i,e])=>Math.min(i,e)-20),ki=Lt(mn,i=>i-20),vn=P({}),Xe=P(!0),_t=pt("appTheme","default"),De=pt("frameTheme"),St=P(!0),Je=P(!1),yt=P(!1),zt=P(!1),kn=P({size:16,style:"lined",color:"#ddd"});function bi({size:i,style:e,color:t}){kn.set({size:i??50,style:e??"lined",color:t??"grey"})}let Pe="";function wi(i){Ye.set(i)}function xi(i){z(De)||De.set(i?.find(e=>e.active)?.name??i[0].name),ze.set(i?.map(e=>({...e,active:e.name===z(De)}))),tt()}function _i(i){ze.set(z(ze).map(e=>({...e,active:e.name===i}))),De.set(i),tt()}function Si(){_t.set(z(_t)==="dark"?"default":"dark")}function yi(){return z(ze)&&z(ze).length>0?z(ze).find(i=>i.name===z(De))??z(ze)[0]:{stageBg:"white"}}function zi(i){if(i==="full")return Qt;const e=z(Ye),t=[...e.small??[],...e.medium??[],...e.large??[]].find(n=>n.name===i);return t?{...t,h:`${t.h}px`,w:`${t.w}px`}:Qt}function tt(){const i=yi().stageBg,{h:e,w:t}=zi(z(Nt)),n=z(ct)?`width: ${e}; height: ${t}`:`width: ${t}; height: ${e}`,s=`background-color: ${i}`;fn.set(`${n}; ${s}; transition: 0s;`)}function Ti(i){Ee.set(i),bn()}function Ei(i){vn.set(i)}function Ci(i){const e=i-9;Ce.set(e),bn()}function Ri(i){mn.set(i)}function Vt(i){Number.isInteger(i)?wt.set(Math.max(50,i)):wt.set(i)}function Xt(i){Number.isInteger(i)?xt.set(Math.max(50,i)):xt.set(i)}function bn(){Number.isInteger(z(Ee))&&Number.isInteger(z(Ce))&&Xe.set(z(Ee)<z(Ce))}function Kt(){z(Xe)?(Pe=z(Ee),Ee.set(z(Ce))):((!Number.isInteger(Pe)||Number.isInteger(Pe)&&z(Ce)-Pe<50)&&(Pe=Math.round(z(Ce)*.7)),Ee.set(Pe)),Xe.set(!z(Xe))}tt();function Mi(){z(At)?Je.set(!z(Je)):St.set(!z(St))}function qi(){yt.set(!z(yt))}function Ii(){zt.set(!z(zt))}const At=Ln(window.innerWidth<840,i=>{const e=()=>{i(window.innerWidth<840),Je.set(!1)};return window.addEventListener("resize",e),()=>{window.removeEventListener("resize",e)}}),Li=Lt([St,Je,At],([i,e,t])=>t?e:i);function Hi(){z(At)&&Je.set(!1)}function Bi(i){Nt.set(i);const e=z(Ye),t=Object.keys(e).reduce((n,s)=>(n[s]=e[s].map(r=>({...r,active:r.name===i})),n),{});Ye.set(t),tt()}function Ni(){ct.set(!z(ct)),tt()}function Ai(i,e,t=s=>s,n=s=>s){const s=P(t(localStorage.getItem(i))??e);return s.subscribe(r=>{localStorage.setItem(i,n(r))}),s}const Ne=P([]),Ue=P(!0),ft=P(),wn=P(),ve=Ai("bookmarks",[],JSON.parse,JSON.stringify);let Yt=!1,mt="",Ke=[],fe=[],nt;function ji(i){fe=i.flatMap(jt).reduce((t,n)=>(t[n.key]=!0,t),{})}function jt(i){return[i,...Wi(i)]}function Wi(i){return i.children?i.children.flatMap(jt):[]}function Oi(i,e){mt=i,nt=e,je(),Ki()}function Pi(i){ft.set(i),je()}function Di(i){Ke=i,Yt||(ji(Ke),Yi(),Yt=!0),Ne.set(Wt(Ke))}function je(){Ne.set(Wt(Ke))}function Wt(i,e){const t=z(ft)?.toLowerCase();return i.map(n=>{const s=t?n.name?.toLowerCase().includes(t):!0,r=t&&s?Ui(n.name):n.name;if(n.isLeaf){const a=e||s?{...n,name:r,selected:nt===n.key,isLeaf:!0,bookmark:z(ve).find(o=>o.key===n.key)!==void 0}:void 0;return a?.selected&&wn.set(a),a}else{const l=Wt(n.children,e||s).filter(o=>o),a=s||l.length>0;return a?{...n,name:r,children:l,unfolded:Zi(n,mt,t,a),filterMatches:s}:void 0}}).filter(n=>n)}function Ui(i){const e=z(ft).toLowerCase(),t=i.toLowerCase().indexOf(e),n=t+e.length,s=i.substring(0,t),r=i.substring(t,n),l=i.substring(n);return`${s}<span class="highlight">${r}</span>${l}`}function Zi(i,e,t,n){return t&&n||fe[i.key]||e?.indexOf(i.key)===0}function Fi(){Ue.set(!z(Ue));const i=z(Ne).map(e=>({...e,unfolded:z(Ue)&&fe[e.key]}));Ne.set(i)}function Gi(i){if(!z(Ue)){Qi(i);return}fe[i.key]&&mt.indexOf(i.key)!==0?fe[i.key]=!1:fe[i.key]=!0,je()}function Qi(i){Ue.set(!0),Object.keys(fe).forEach(t=>fe[t]=!1);const e=z(Ne).map(t=>t.key===i.key||mt.indexOf(t.key)===0?(fe[t.key]=!0,{...t,unfolded:!0}):(fe[t.key]=!1,{...t,unfolded:!1}));Ne.set(e),je()}function Jt(i){i.bookmark?Vi({...i}):Xi({...i,bookmark:!0}),je()}function Vi(i){ve.set(z(ve).filter(e=>i.key!==e.key).map(e=>({...e,selected:e.key===nt}))),je()}function Xi(i){ve.set([...z(ve),i].map(e=>({...e,selected:e.key===nt})).sort((e,t)=>e.name.localeCompare(t.name))),je()}function Ki(){ve.set([...z(ve)].map(i=>({...i,selected:i.key===nt})).sort((i,e)=>i.name.localeCompare(e.name)))}function Yi(){const i=Ke.flatMap(jt),e=z(ve).filter(t=>i.some(n=>n.key===t.key));ve.set(e)}const xn=[],Ji=globalThis.location?globalThis.location.pathname+globalThis.location.search:"";let ne=Ji,Te="",Tt,Et={url:ne};(function(){globalThis.history&&(globalThis.history.state&&globalThis.history.state.url==ne&&(Et=globalThis.history.state),globalThis.history.replaceState(Et,null,ne))})();function $i(i,e,t){Tt=i,Te=e,t&&er(t),ut(Et,ne)}function er(i){xn.push(i)}function ut(i,e){xn.forEach(t=>{t(tr(e),i)})}function tr(i){const e=i.substring(Te.length),t=Object.keys(Tt).find(n=>e.match(new RegExp("^"+n+"$","i")));return t?Tt[t]:null}(function(i){if(i){var e=i.pushState,t=i.replaceState;i.pushState=function(n,s,r){let a=typeof r=="string"?r:"";Te.length>0&&a.startsWith(Te)&&(a=a.substring(Te.length)||"/"),a.length===0&&(a="/"),a[0]!=="/"&&(a="/"+a),ne=Te+a;const o=n&&typeof n=="object"?n:{};return o.url=ne,o.url!==i.state?.url||o.selectedExample!==i.state?.selectedExample?(ut(o,ne),e.apply(i,[o,"",ne])):(ut(o,ne),t.apply(i,[o,"",ne]))}}})(globalThis.history);globalThis.onpopstate=function(i){i.state?ne=i.state.url:ne=Te.length>0?Te:"/",ut(i.state,ne)};const Ct=P(""),ht=P(),dt=P({}),_n=P("");let gt,Rt,Mt;function nr(i){gt=i,Mt&&Sn()}function sr(i,e,t){gt=i,Mt||(Mt=!0,$i(e,t,ir))}function ir(i,e){if(ht.set({}),Ct.set(""),dt.set({}),i&&gt){Ct.set(i.fullname),_n.set(i.route);const t=gt[i.fullname];t.componentfile=i.file,ht.set(t),Rt=e,Sn()}}function Sn(){const i=z(ht).examples||[];Rt?.selectedExample?dt.set(i.find(e=>e.title==Rt.selectedExample)?.title):dt.set(i[0]?.title)}var rr=()=>{window.top.location.reload()},lr=C('<div class="message svelte-yh1ir7"><div class="click-completed svelte-yh1ir7">Relative link was clicked!</div> <div class="instruction svelte-yh1ir7">Click the button to return: <button class="svelte-yh1ir7">back</button></div></div>'),ar=C('<div class="garden svelte-yh1ir7"><div class="sidebar svelte-yh1ir7"><!></div> <div class="main svelte-yh1ir7"><!> <!></div></div>');function or(i,e){$(e,!0);const[t,n]=Hn(),s=()=>N(_n,"$currentRoute",t),r=()=>N(Ct,"$componentName",t),l=()=>N(dt,"$selectedExample",t),a=()=>N(De,"$activeTheme",t),o=()=>N(_t,"$appTheme",t),c=()=>N(ve,"$bookmarks",t),h=()=>N(ft,"$filterNavTree",t),g=()=>N(Ne,"$nodes",t),d=()=>N(Xe,"$panelExpanded",t),u=()=>N(Ue,"$rootNodesExpanded",t),w=()=>N(Li,"$sidebarExpanded",t),T=()=>N(ct,"$landscape",t),E=()=>N(wn,"$selectedNode",t),S=()=>N(zt,"$showGrid",t),M=()=>N(yt,"$showInspector",t),R=()=>N(wt,"$stageHeight",t),H=()=>N(vi,"$stageMaxHeight",t),q=()=>N(ki,"$stageMaxWidth",t),I=()=>N(vn,"$stageRect",t),D=()=>N(Nt,"$stageSize",t),G=()=>N(Ye,"$stageSizes",t),B=()=>N(xt,"$stageWidth",t),j=()=>N(ze,"$themes",t),Ie=()=>N(ht,"$das",t),be=()=>N(kn,"$gridSettings",t),we=()=>N(Ee,"$stageContainerHeight",t),ge=()=>N(Ce,"$stageContainerMaxHeight",t),We=()=>N(fn,"$stageStyle",t);let Le="/garden";ae(()=>{Di(e.navTree)}),ae(()=>{e.routes&&e.dasMap&&sr(e.dasMap,e.routes,Le)}),ae(()=>{nr(e.dasMap)}),ae(()=>{xi(e.config.themes)}),ae(()=>{e.config.devices&&wi(e.config.devices),e.config.grid&&bi(e.config.grid)}),ae(()=>{Oi(s(),r()),Hi()});let Ge=e.config.project_title||"",Qe=e.config.project_logo?.split("/").pop()||null,Oe=e.config.project_logo_darkmode?.split("/").pop()||null,xe=se(()=>e.config.docs_link?1:0);function y(){const Z=window.open("/frame.html","_blank");Z.onload=()=>{Z.postMessage({selectedExample:l(),componentName:r(),theme:a()},window.location.origin)}}var L=Re(),ue=me(L);{var he=Z=>{var Q=lr(),ye=_(f(Q),2),He=_(f(ye));He.__click=[rr],v(Z,Q)},Se=Z=>{var Q=ar(),ye=f(Q),He=f(ye);Ks(He,{get docsLink(){return p(xe)},get projectLogoDarkmode(){return Oe},get projectLogo(){return Qe},get projectTitle(){return Ge},get appTheme(){return o()},get bookmarks(){return c()},get filter(){return h()},get nodes(){return g()},get panelExpanded(){return d()},get rootNodesExpanded(){return u()},get sidebarExpanded(){return w()},get onToggleBookmark(){return Jt},get onToggleExpandPanel(){return Kt},get onToggleFoldStatusOfNode(){return Gi},get onToggleRootFolders(){return Fi},get onUpdateFilter(){return Pi}});var st=_(ye,2),it=f(st);mi(it,{get appTheme(){return o()},get landscape(){return T()},get node(){return E()},get showGrid(){return S()},get showInspector(){return M()},get sidebarExpanded(){return w()},get stageHeight(){return R()},get stageMaxHeight(){return H()},get stageMaxWidth(){return q()},get stageRect(){return I()},get stageSize(){return D()},get stageSizes(){return G()},get stageWidth(){return B()},get themes(){return j()},onOpenInTab:y,get onSetStageHeight(){return Vt},get onSetStageWidth(){return Xt},get onSetStageSize(){return Bi},get onSetTheme(){return _i},get onToggleAppTheme(){return Si},get onToggleBookmark(){return Jt},get onToggleExpandSidebar(){return Mi},get onToggleOrientation(){return Ni},get onToggleShowGrid(){return Ii},get onToggleShowInspector(){return qi}});var vt=_(it,2);Es(vt,{get appTheme(){return o()},get componentName(){return r()},get das(){return Ie()},get devmodus(){return e.config.devmodus},get gridSettings(){return be()},get panelExpanded(){return d()},get selectedExample(){return l()},get showGrid(){return S()},get showInspector(){return M()},get stageContainerHeight(){return we()},get stageContainerMaxHeight(){return ge()},get stageHeight(){return R()},get stageMaxHeight(){return H()},get stageMaxWidth(){return q()},get stageSize(){return D()},get stageStyle(){return We()},get stageWidth(){return B()},get theme(){return a()},get onSetStageContainerHeight(){return Ti},get onSetStageContainerMaxHeight(){return Ci},get onSetStageContainerWidth(){return Ri},get onSetStageHeight(){return Vt},get onSetStageWidth(){return Xt},get onToggleExpandPanel(){return Kt},get onUpdateStageRect(){return Ei}}),v(Z,Q)};O(ue,Z=>{window.top!==window.self?Z(he):Z(Se,!1)})}v(i,L),ee(),n()}de(["click"]);Bn(or,{target:document.getElementById("app"),props:{navTree:An,routes:Nn,dasMap:jn,config:Wn}});