tauri/examples/api/dist/assets/index.js

30 lines
40 KiB
JavaScript
Raw Normal View History

var zi=Object.defineProperty,Ci=Object.defineProperties;var Mi=Object.getOwnPropertyDescriptors;var Yl=Object.getOwnPropertySymbols;var Ti=Object.prototype.hasOwnProperty,Si=Object.prototype.propertyIsEnumerable;var Jl=(n,t,l)=>t in n?zi(n,t,{enumerable:!0,configurable:!0,writable:!0,value:l}):n[t]=l,Kl=(n,t)=>{for(var l in t||(t={}))Ti.call(t,l)&&Jl(n,l,t[l]);if(Yl)for(var l of Yl(t))Si.call(t,l)&&Jl(n,l,t[l]);return n},Ql=(n,t)=>Ci(n,Mi(t));import{S as X,i as Y,s as J,e as o,a as h,t as C,b as u,c as S,d as e,l as y,f as G,n as W,g as R,r as x,h as Ri,j as Li,o as Ei,k as Hi,m as Zl,p as Oi,q as en,u as $l,v as Wn,w as Un,x as Pi,y as E,z as xl,A as ei,B as Ai,C as tn,D as $e,E as ti,F as Ii,G as Wi,H as Ui,I as qi,J as qn,K as xe,L as ni,M as Nn,N as Dn,O as B,P as jn,Q as nn,R as Gn,T as li,U as ii,V as Ni,W as Di,X as si,Y as oi,Z as ji,_ as Gi,$ as Bi,a0 as Fi,a1 as Vi,a2 as Xi,a3 as Yi,a4 as Ji,a5 as Ki,a6 as Bn,a7 as Fn,a8 as Vn,a9 as Xn,aa as Yn,ab as Qi,ac as ai,ad as Zi,ae as $i,af as xi,ag as es}from"./vendor.js";const ts=function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))i(s);new MutationObserver(s=>{for(const a of s)if(a.type==="childList")for(const r of a.addedNodes)r.tagName==="LINK"&&r.rel==="modulepreload"&&i(r)}).observe(document,{childList:!0,subtree:!0});function l(s){const a={};return s.integrity&&(a.integrity=s.integrity),s.referrerpolicy&&(a.referrerPolicy=s.referrerpolicy),s.crossorigin==="use-credentials"?a.credentials="include":s.crossorigin==="anonymous"?a.credentials="omit":a.credentials="same-origin",a}function i(s){if(s.ep)return;s.ep=!0;const a=l(s);fetch(s.href,a)}};ts();function ns(n){let t,l,i,s,a,r,c,m,v,k,g,p,_,w,b,d,z,M,q,A,P;return{c(){t=o("h1"),t.textContent="Welcome",l=h(),i=o("p"),i.textContent="Tauri's API capabilities using the ` @tauri-apps/api ` package. It's used as\n the main validation app, serving as the testbed of our development process. In\n the future, this app will be used on Tauri's integration tests.",s=h(),a=o("p"),r=C("Current App version: "),c=C(n[0]),m=h(),v=o("p"),k=C("Current Tauri version: "),g=C(n[1]),p=h(),_=o("p"),w=C("Current App name: "),b=C(n[2]),d=h(),z=o("button"),z.textContent="Close application",M=h(),q=o("button"),q.textContent="Relaunch application",u(z,"class","button"),u(q,"class","button")},m(L,I){S(L,t,I),S(L,l,I),S(L,i,I),S(L,s,I),S(L,a,I),e(a,r),e(a,c),S(L,m,I),S(L,v,I),e(v,k),e(v,g),S(L,p,I),S(L,_,I),e(_,w),e(_,b),S(L,d,I),S(L,z,I),S(L,M,I),S(L,q,I),A||(P=[y(z,"click",n[3]),y(q,"click",n[4])],A=!0)},p(L,[I]){I&1&&G(c,L[0]),I&2&&G(g,L[1]),I&4&&G(b,L[2])},i:W,o:W,d(L){L&&R(t),L&&R(l),L&&R(i),L&&R(s),L&&R(a),L&&R(m),L&&R(v),L&&R(p),L&&R(_),L&&R(d),L&&R(z),L&&R(M),L&&R(q),A=!1,x(P)}}}function ls(n,t,l){let i=0,s=0,a="Unknown";Ri().then(m=>{l(2,a=m)}),Li().then(m=>{l(0,i=m)}),Ei().then(m=>{l(1,s=m)});async function r(){await Hi()}async function c(){await Zl()}return[i,s,a,r,c]}class is extends X{constructor(t){super();Y(this,t,ls,ns,J,{})}}function ss(n){let t,l,i,s,a,r,c,m,v,k,g;return{c(){t=o("div"),l=C(`This binary can be run on the terminal and takes the following arguments:
`),i=o("ul"),i.innerHTML=`<li>--config PATH</li>
<li>--theme light|dark|system</li>
<li>--verbose</li>`,s=C(`
Additionally, it has a `),a=o("i"),a.textContent="update --background",r=C(` subcommand.
Note that the arguments are only parsed, not implemented.
`),c=o("br"),m=h(),v=o("button"),v.textContent="Get matches",u(v,"class","button"),u(v,"id","cli-matches")},m(p,_){S(p,t,_),e(t,l),e(t,i),e(t,s),e(t,a),e(t,r),e(t,c),e(t,m),e(t,v),k||(g=y(v,"click",n[0]),k=!0)},p:W,i:W,o:W,d(p){p&&R(t),k=!1,g()}}}function os(n,t,l){let{onMessage:i}=t;function s(){Oi().then(i).catch(i)}return n.$$set=a=>{"onMessage"in a&&l(1,i=a.onMessage)},[s,i]}class as extends X{constructor(t){super();Y(this,t,os,ss,J,{onMessage:1})}}function us(n){let t,l,i,s,a,r,c,m;return{c(){t=o("div"),l=o("button"),l.textContent="Call Log API",i=h(),s=o("button"),s.textContent="Call Request (async) API",a=h(),r=o("button"),r.textContent="Send event to Rust",u(l,"class","button"),u(l,"id","log"),u(s,"class","button"),u(s,"id","request"),u(r,"class","button"),u(r,"id","event")},m(v,k){S(v,t,k),e(t,l),e(t,i),e(t,s),e(t,a),e(t,r),c||(m=[y(l,"click",n[0]),y(s,"click",n[1]),y(r,"click",n[2])],c=!0)},p:W,i:W,o:W,d(v){v&&R(t),c=!1,x(m)}}}function rs(n,t,l){let{onMessage:i}=t,s;en(async()=>{s=await $l("rust-event",i)}),Wn(()=>{s&&s()});function a(){Un("log_operation",{event:"tauri-click",payload:"this payload is optional because we used Option in Rust"})}function r(){Un("perform_request",{endpoint:"dummy endpoint arg",body:{id:5,name:"test"}}).then(i).catch(i)}function c(){Pi("js-event","this is the payload string")}return n.$$set=m=>{"onMessage"in m&&l(3,i=m.onMessage)},[a,r,c,i]}class cs extends X{constructor(t){super();Y(this,t,rs,us,J,{onMessage:3})}}function ps(n){let t,l,i,s,a,r,c,m,v,k,g,p,_,w,b,d,z,M,q,A;return{c(){t=o("div"),l=o("input"),i=h(),s=o("input"),a=h(),r=o("div"),c=o("input"),m=h(),v=o("label"),v.textContent="Multiple",k=h(),g=o("div"),p=o("input"),_=h(),w=o("label"),w.textContent="Directory",b=h(),d=o("button"),d.textContent="Open dialog",z=h(),M=o("button"),M.textContent="Open save dialog",u(l,"id","dialog-default-path"),u(l,"placeholder","Default path"),u(s,"id","dialog-filter"),u(s,"placeholder","Extensions filter, comma-separated"),u(s,"class","svelte-1eg58yg"),u(c,"type","checkbox"),u(c,"id","dialog-multiple"),u(v,"for","dialog-multiple"),u(p,"type","checkbox"),u(p,"id","dialog-directory"),u(w,"for","dialog-directory"),u(d,"class","button"),u(d,"id","open-dialog"),u(M,"class","button"),u(M,"id","save-dialog")},m(P,L){S(P,t,L),e(t,l),E(l,n[0]),e(t,i),e(t,s),E(s,n[1]),e(t,a),e(t,r),e(r,c),c.checked=n[2],e(r,m),e(r,v),e(t,k),e(t,g),e(g,p),p.checked=n[3],e(g,_),e(g,w),e(t,b),e(t,d),e(t,z),e(t,M),q||(A=[y(l,"input",n[8]),y(s,"input",n[9]),y(c,"change",n[10]),y(p,"change",n[11]),y(d,"click",n[4]),y(M,"click",n[5])],q=!0)},p(P,[L]){L&1&&l.value!==P[0]&&E(l,P[0]),L&2&&s.value!==P[1]&&E(s,P[1]),L&4&&(c.checked=P[2]),L&8&&(p.checked=P[3])},i:W,o:W,d(P){P&&R(t),q=!1,x(A)}}}function fs(n,t){var l=new Blob([n],{type:"application/octet-binary"}),i=new FileReader;i.onload=function(s){var a=s.target.result;t(a.substr(a.indexOf(",")+1))},i.readAsDataURL(l)}function ds(n,t,l){let{onMessage:i}=t,{insecureRenderHtml:s}=t,a=null,r=null,c=!1,m=!1;function v(){xl({title:"My wonderful open dialog",defaultPath:a,filters:r?[{name:"Tauri Example",extensions:r.split(",").map(b=>b.trim())}]:[],multiple:c,directory:m}).then(function(b){if(Array.isArray(b))i(b);else{var d=b,z=d.match(/\S+\.\S+$/g);ei(d).then(function(M){z&&(d.includes(".png")||d.includes(".jpg"))?fs(new Uint8Array(M),function(q){var A="data:image/png;base64,"+q;s('<img src="'+A+'"></img>')}):i(b)}).catch(i(b))}}).catch(i)}function k(){Ai({title:"My wonderful save dialog",defaultPath:a,filters:r?[{name:"Tauri Example",extensions:r.split(",").map(b=>b.trim())}]:[]}).then(i).catch(i)}function g(){a=this.value,l(0,a)}function p(){r=this.value,l(1,r)}function _(){c=this.checked,l(2,c)}function w(){m=this.checked,l(3,m)}return n.$$set=b=>{"onMessage"in b&&l(6,i=b.onMessage),"insecureRenderHtml"in b&&l(7,s=b.insecureRenderHtml)},[a,r,c,m,v,k,i,s,g,p,_,w]}class hs extends X{constructor(t){super();Y(this,t,ds,ps,J,{onMessage:6,insecureRenderHtml:7})}}function ui(n,t,l){const i=n.slice();return i[9]=t[l],i}function ri(n){let t,l=n[9][0]+"",i,s;return{c(){t=o("option"),
Resizable`),m=h(),v=o("label"),k=o("input"),g=C(`
Maximize`),p=h(),_=o("button"),_.textContent="Center",w=h(),b=o("button"),b.textContent="Minimize",d=h(),z=o("button"),z.textContent="Hide",M=h(),q=o("label"),A=o("input"),P=C(`
Transparent`),L=h(),I=o("label"),N=o("input"),K=C(`
Has decorations`),fe=h(),V=o("label"),j=o("input"),O=C(`
Always on top`),Q=h(),H=o("label"),F=o("input"),Se=C(`
Fullscreen`),Re=h(),Ae=o("button"),Ae.textContent="Change icon",wt=h(),et=o("div"),ee=o("div"),de=o("div"),Ie=o("div"),kt=C(`X
`),le=o("input"),yt=h(),We=o("div"),zt=C(`Y
`),ie=o("input"),Ct=h(),he=o("div"),Ue=o("div"),Mt=C(`Width
`),se=o("input"),Tt=h(),qe=o("div"),St=C(`Height
`),oe=o("input"),Rt=h(),me=o("div"),Ne=o("div"),Lt=C(`Min width
`),ae=o("input"),Et=h(),De=o("div"),Ht=C(`Min height
`),ue=o("input"),Ot=h(),ve=o("div"),je=o("div"),D=C(`Max width
`),te=o("input"),Jn=h(),Pt=o("div"),Kn=C(`Max height
`),ce=o("input"),ln=h(),re=o("div"),Ge=o("div"),_e=o("div"),sn=o("div"),sn.textContent="Inner Size",Qn=h(),tt=o("span"),Zn=C("Width: "),on=C(At),$n=h(),nt=o("span"),xn=C("Height: "),an=C(It),el=h(),ge=o("div"),un=o("div"),un.textContent="Outer Size",tl=h(),lt=o("span"),nl=C("Width: "),rn=C(Wt),ll=h(),it=o("span"),il=C("Height: "),cn=C(Ut),sl=h(),Be=o("div"),be=o("div"),pn=o("div"),pn.textContent="Inner Logical Size",ol=h(),st=o("span"),al=C("Width: "),fn=C(qt),ul=h(),ot=o("span"),rl=C("Height: "),dn=C(Nt),cl=h(),we=o("div"),hn=o("div"),hn.textContent="Outer Logical Size",pl=h(),at=o("span"),fl=C("Width: "),mn=C(Dt),dl=h(),ut=o("span"),hl=C("Height: "),vn=C(jt),ml=h(),Fe=o("div"),ke=o("div"),_n=o("div"),_n.textContent="Inner Position",vl=h(),rt=o("span"),_l=C("x: "),gn=C(Gt),gl=h(),ct=o("span"),bl=C("y: "),bn=C(Bt),wl=h(),ye=o("div"),wn=o("div"),wn.textContent="Outer Position",kl=h(),pt=o("span"),yl=C("x: "),kn=C(Ft),zl=h(),ft=o("span"),Cl=C("y: "),yn=C(Vt),Ml=h(),Ve=o("div"),ze=o("div"),zn=o("div"),zn.textContent="Inner Logical Position",Tl=h(),dt=o("span"),Sl=C("x: "),Cn=C(Xt),Rl=h(),ht=o("span"),Ll=C("y: "),Mn=C(Yt),El=h(),Ce=o("div"),Tn=o("div"),Tn.textContent="Outer Logical Position",Hl=h(),mt=o("span"),Ol=C("x: "),Sn=C(Jt),Pl=h(),vt=o("span"),Al=C("y: "),Rn=C(Kt),Ln=h(),ne=o("div"),En=o("h4"),En.textContent="Cursor",Il=h(),Qt=o("label"),Xe=o("input"),Wl=C(`
Grab`),Ul=h(),Zt=o("label"),Ye=o("input"),ql=C(`
Visible`),Nl=h(),pe=o("select");for(let f=0;f<$.length;f+=1)$[f].c();Dl=h(),Je=o("div"),$t=o("div"),jl=C(`X position
`),Le=o("input"),Gl=h(),xt=o("div"),Bl=C(`Y position
`),Ee=o("input"),Hn=h(),Me=o("form"),He=o("input"),Fl=h(),_t=o("button"),_t.textContent="Set title",On=h(),Te=o("form"),Oe=o("input"),Vl=h(),gt=o("button"),gt.textContent="Open URL",Pn=h(),Pe=o("button"),Pe.textContent="Request attention",An=h(),Ke=o("button"),Ke.textContent="New window",u(l,"class","button"),n[0]===void 0&&qn(()=>n[37].call(l)),u(r,"type","checkbox"),u(k,"type","checkbox"),u(_,"title","Unminimizes after 2 seconds"),u(b,"title","Unminimizes after 2 seconds"),u(z,"title","Visible again after 2 seconds"),u(A,"type","checkbox"),u(N,"type","checkbox"),u(j,"type","checkbox"),u(F,"type","checkbox"),u(le,"type","number"),u(le,"min","0"),u(le,"class","svelte-1tppwwz"),u(ie,"type","number"),u(ie,"min","0"),u(ie,"class","svelte-1tppwwz"),u(de,"class","flex col grow svelte-1tppwwz"),u(se,"type","number"),u(se,"min","400"),u(se,"class","svelte-1tppwwz"),u(oe,"type","number"),u(oe,"min","400"),u(oe,"class","svelte-1tppwwz"),u(he,"class","flex col grow svelte-1tppwwz"),u(ae,"type","number"),u(ae,"class","svelte-1tppwwz"),u(ue,"type","number"),u(ue,"class","svelte-1tppwwz"),u(me,"class","flex col grow svelte-1tppwwz"),u(te,"type","number"),u(te,"min","400"),u(te,"class","svelte-1tppwwz"),u(ce,"type","number"),u(ce,"min","400"),u(ce,"class","svelte-1tppwwz"),u(ve,"class","flex col grow svelte-1tppwwz"),u(ee,"class","window-controls flex flex-row svelte-1tppwwz"),u(t,"class","flex col"),u(tt,"class","svelte-1tppwwz"),u(nt,"class","svelte-1tppwwz"),u(_e,"class","grow window-property svelte-1tppwwz"),u(lt,"class","svelte-1tppwwz"),u(it,"class","svelte-1tppwwz"),u(ge,"class","grow window-property svelte-1tppwwz"),u(Ge,"class","flex"),u(st,"class","svelte-1tppwwz"),u(ot,"class","svelte-1tppwwz"),u(be,"class","grow window-property svelte-1tppwwz"),u(at,"class","svelte-1tppwwz"),u(ut,"class","svelte-1tppwwz"),u(we,"class","grow window-property svelte-1tppwwz"),u(Be,"class","flex"),u(rt,"class","svelte-1tppwwz"),u(ct,"class","svelte-1tppwwz"),u(ke,"class","grow window-property svelte-1tppwwz"),u(pt,"class","svelte-1tppwwz"),u(ft,"class","svelte-1tppwwz"),u(ye,"class","grow window-property svelte-1tppwwz"),u(Fe,"class","flex"),u(dt,"class","svelte-1tppwwz"),u(ht,"class","svelte-1tppwwz"),u(ze,"class","grow window-property svelte-1tppwwz"),u(mt,"class","svelte-1tppwwz"),u(vt,"class","svelte-1tppwwz"),u(Ce,"class","grow window-property svelte-1tppwwz"),u(Ve,"class","flex"),u(Xe,"type","checkbox"),u(Ye,"type","checkbox"),u(pe,"class","button"),n[19]===void 0&&qn(()=>n[55].call(pe)),u(Le,"type","number"),u(Ee,"type","number"),u(Je,"class","flex col grow svelte-1tppwwz"),u(He,"id","title"),u(_t,"class","button"),u(_t,"type","submit"),u(Me,"class","svelte-1tppwwz"),u(Oe,"id","url"),u(gt,"class","button"),u(gt,"id","open-url"),u(Te,"class","svelte-1tppwwz"),u(Pe,"class","button"),u(Pe,"title","Minimizes the window, requests attention for 3s and then resets it"),u(Ke,"class","button")},m(f,T){S(f,t,T),e(t,l);for(let U=0;U<Z.length;U+=1)Z[U].m(l,null);xe(l,n[0]),e(t,i),e(t,s),e(s,a),e(a,r),r.checked=n[2],e(a,c),e(s,m),e(s,v),e(v,k),k.checked=n[3],e(v,g),e(s,p),e(s,_),e(s,w),e(s,b),e(s,d),e(s,z),e(s,M),e(s,q),e(q,A),A.checked=n[21],e(q,P),e(s,L),e(s,I),e(I,N),N.checked=n[4],e(I,K),e(s,fe),e(s,V),e(V,j),j.checked=n[5],e(V,O),e(s,Q),e(s,H),e(H,F),F.checked=n[6],e(H,Se),e(s,Re),e(s,Ae),e(t,wt),e(t,et),e(et,ee),e(ee,de),e(de,Ie),e(Ie,kt),e(Ie,le),E(le,n[13]),e(de,yt),e(de,We),e(We,zt),e(We,ie),E(ie,n[14]),e(ee,Ct),e(ee,he),e(he,Ue),e(Ue,Mt),e(Ue,se),E(se,n[7]),e(he,Tt),e(he,qe),e(qe,St),e(qe,oe),E(oe,n[8]),e(ee,Rt),e(ee,me),e(me,Ne),e(Ne,Lt),e(Ne,ae),E(ae,n[9]),e(me,Et),e(me,De),e(De,Ht),e(De,ue),E(ue,n[10]),e(ee,Ot),e(ee,ve),e(ve,je),e(je,D),e(je,te),E(te,n[11]),e(ve,Jn),e(ve,Pt),e(Pt,Kn),e(Pt,ce),E(ce,n[12]),S(f,ln,T),S(f,re,T),e(re,Ge),e(Ge,_e),e(_e,sn),e(_e,Qn),e(_e,tt),e(tt,Zn),e(tt,on),e(_e,$n),e(_e,nt),e(nt,xn),e(nt,an),e(Ge,el),e(Ge,ge),e(ge,un),e(ge,tl),e(ge,lt),e(lt,nl),e(lt,rn),e(ge,ll),e(ge,it),e(it,il),e(it,cn),e(re,sl),e(re,Be),e(Be,be),e(be,pn),e(be,ol),e(be,st),e(st,al),e(st,fn),e(be,ul),e(be,ot),e(ot,rl),e(ot,dn),e(Be,
<video id="localVideo" autoplay="" playsinline=""><track kind="captions"/></video>`},m(l,i){S(l,t,i)},p:W,i:W,o:W,d(l){l&&R(t)}}}function Gs(n,t,l){let{onMessage:i}=t;const s=window.constraints={audio:!0,video:!0};function a(c){const m=document.querySelector("video"),v=c.getVideoTracks();i("Got stream with constraints:",s),i(`Using video device: ${v[0].label}`),window.stream=c,m.srcObject=c}function r(c){if(c.name==="ConstraintNotSatisfiedError"){const m=s.video;i(`The resolution ${m.width.exact}x${m.height.exact} px is not supported by your device.`)}else c.name==="PermissionDeniedError"&&i("Permissions have not been granted to use your camera and microphone, you need to allow the page access to your devices in order for the demo to work.");i(`getUserMedia error: ${c.name}`,c)}return en(async()=>{try{const c=await navigator.mediaDevices.getUserMedia(s);a(c)}catch(c){r(c)}}),Wn(()=>{window.stream.getTracks().forEach(function(c){c.stop()})}),n.$$set=c=>{"onMessage"in c&&l(0,i=c.onMessage)},[i]}class Bs extends X{constructor(t){super();Y(this,t,Gs,js,J,{onMessage:0})}}function Fs(n){let t,l,i,s,a,r,c,m,v,k,g,p,_,w,b;return p=new Ki({props:{json:n[2]}}),{c(){t=o("div"),l=o("input"),i=h(),s=o("input"),a=h(),r=o("label"),c=o("input"),m=C(`
Multipart`),v=h(),k=o("button"),k.textContent="Post it.",g=h(),Bn(p.$$.fragment),u(c,"type","checkbox"),u(k,"type","button")},m(d,z){S(d,t,z),e(t,l),E(l,n[0]),e(t,i),e(t,s),E(s,n[1]),e(t,a),e(t,r),e(r,c),c.checked=n[3],e(r,m),e(t,v),e(t,k),e(t,g),Fn(p,t,null),_=!0,w||(b=[y(l,"input",n[5]),y(s,"input",n[6]),y(c,"change",n[7]),y(k,"click",n[4])],w=!0)},p(d,[z]){z&1&&l.value!==d[0]&&E(l,d[0]),z&2&&s.value!==d[1]&&E(s,d[1]),z&8&&(c.checked=d[3]);const M={};z&4&&(M.json=d[2]),p.$set(M)},i(d){_||(Vn(p.$$.fragment,d),_=!0)},o(d){Xn(p.$$.fragment,d),_=!1},d(d){d&&R(t),Yn(p),w=!1,x(b)}}}function Vs(n,t,l){let i="baz",s="qux",a=null,r=!0;async function c(){const g=await ni().catch(p=>{throw onMessage(p),p});l(2,a=await g.request({url:"http://localhost:3003",method:"POST",body:Nn.form({foo:i,bar:s}),headers:r?{"Content-Type":"multipart/form-data"}:void 0,responseType:Qi.Text}))}function m(){i=this.value,l(0,i)}function v(){s=this.value,l(1,s)}function k(){r=this.checked,l(3,r)}return[i,s,a,r,c,m,v,k]}class Xs extends X{constructor(t){super();Y(this,t,Vs,Fs,J,{})}}function bi(n,t,l){const i=n.slice();return i[10]=t[l],i}function wi(n,t,l){const i=n.slice();return i[13]=t[l],i}function ki(n){let t,l=n[13].label+"",i,s,a,r,c;function m(){return n[9](n[13])}return{c(){t=o("p"),i=C(l),s=h(),u(t,"class",a="nv noselect "+(n[0]===n[13]?"nv_selected":""))},m(v,k){S(v,t,k),e(t,i),e(t,s),r||(c=y(t,"click",m),r=!0)},p(v,k){n=v,k&1&&a!==(a="nv noselect "+(n[0]===n[13]?"nv_selected":""))&&u(t,"class",a)},d(v){v&&R(t),r=!1,c()}}}function Ys(n){let t,l=n[10].html+"",i;return{c(){i=ai(),t=new es(i)},m(s,a){t.m(l,s,a),S(s,i,a)},p(s,a){a&2&&l!==(l=s[10].html+"")&&t.p(l)},d(s){s&&R(i),s&&t.d()}}}function Js(n){let t,l=n[10].text+"",i;return{c(){t=o("p"),i=C(l)},m(s,a){S(s,t,a),e(t,i)},p(s,a){a&2&&l!==(l=s[10].text+"")&&G(i,l)},d(s){s&&R(t)}}}function yi(n){let t;function l(a,r){return a[10].text?Js:Ys}let i=l(n),s=i(n);return{c(){s.c(),t=ai()},m(a,r){s.m(a,r),S(a,t,r)},p(a,r){i===(i=l(a))&&s?s.p(a,r):(s.d(1),s=i(a),s&&(s.c(),s.m(t.parentNode,t)))},d(a){s.d(a),a&&R(t)}}}function Ks(n){let t,l,i,s,a,r,c,m,v,k,g,p,_,w,b,d,z,M,q,A,P,L,I=n[2],N=[];for(let O=0;O<I.length;O+=1)N[O]=ki(wi(n,I,O));var K=n[0].component;function fe(O){return{props:{onMessage:O[5],insecureRenderHtml:O[6]}}}K&&(p=new K(fe(n)));let V=n[1],j=[];for(let O=0;O<V.length;O+=1)j[O]=yi(bi(n,V,O));return{c(){t=o("main"),l=o("div"),i=o("img"),a=h(),r=o("div"),r.innerHTML=`<a class="dark-link" target="_blank" href="https://tauri.studio/en/docs/get-started/intro">Documentation</a>
<a class="dark-link" target="_blank" href="https://github.com/tauri-apps/tauri">Github</a>
<a class="dark-link" target="_blank" href="https://github.com/tauri-apps/tauri/tree/dev/tauri/examples/api">Source</a>`,c=h(),m=o("div"),v=o("div");for(let O=0;O<N.length;O+=1)N[O].c();k=h(),g=o("div"),p&&Bn(p.$$.fragment),_=h(),w=o("div"),b=o("p"),d=o("strong"),d.textContent="Tauri Console",z=h(),M=o("span"),M.textContent="clear",q=h();for(let O=0;O<j.length;O+=1)j[O].c();u(i,"class","logo"),i.src!==(s="tauri logo.png")&&u(i,"src",s),u(i,"height","60"),u(i,"alt","logo"),u(l,"class","flex row noselect just-around container svelte-1fam3xt"),u(l,"data-tauri-drag-region",""),u(v,"class","view-container svelte-1fam3xt"),u(g,"class","content"),u(m,"class","flex row"),u(M,"class","nv"),u(b,"class","flex row just-around"),u(w,"id","response"),u(w,"class","svelte-1fam3xt")},m(O,Q){S(O,t,Q),e(t,l),e(l,i),e(l,a),e(l,r),e(t,c),e(t,m),e(m,v);for(let H=0;H<N.length;H+=1)N[H].m(v,null);e(m,k),e(m,g),p&&Fn(p,g,null),e(t,_),e(t,w),e(w,b),e(b,d),e(b,z),e(b,M),e(w,q);for(let H=0;H<j.length;H+=1)j[H].m(w,null);A=!0,P||(L=[y(i,"click",n[8]),y(M,"click",n[7])],P=!0)},p(O,[Q]){if(Q&21){I=O[2];let H;for(H=0;H<I.length;H+=1){const F=wi(O,I,H);N[H]?N[H].p(F,Q):(N[H]=ki(F),N[H].c(),N[H].m(v,null))}for(;H<N.length;H+=1)N[H].d(1);N.length=I.length}if(K!==(K=O[0].component)){if(p){$i();const H=p;Xn(H.$$.fragment,1,0,()=>{Yn(H,1)}),Zi()}K?(p=new K(fe(O)),Bn(p.$$.fragment),Vn(p.$$.fragment,1),Fn(p,g,null)):p=null}if(Q&2){V=O[1];let H;for(H=0;H<V.length;H+=1){const F=bi(O,V,H);j[H]?j[H].p(F,Q):(j[H]=yi(F),j[H].c(),j[H].m(w,null))}for(;H<j.length;H+=1)j[H].d(1);j.length=V.length}},i(O){A||(p&&Vn(p.$$.fragment,O),A=!0)},o(O){p&&Xn(p.$$.fragment,O),A=!1},d(O){O&&R(t),$e(N,O),p&&Yn(p),$e(j,O),P=!1,x(L)}}}const Qs="ctrl+b";function Zs(n,t,l){let i;en(()=>{xi(Qs,()=>{Un("menu_toggle")})}),jn.listen("tauri://file-drop",function(_){m(`File drop: ${_.payload}`)});const s=[{label:"Welcome",component:is},{label:"Messages",component:cs},{label:"CLI",component:as},{label:"Dialog",component:hs},{label:"File system",component:gs},{label:"HTTP",component:ks},{label:"HTTP Form",component:Xs},{label:"Notifications",component:Ms},{label:"Window",component:Rs},{label:"Shortcuts",component:Hs},{label:"Shell",component:As},{label:"Updater",component:Us},{label:"Clipboard",component:Ds},{label:"WebRTC",component:Bs}];let a=s[0],r=oi([]);si(n,r,_=>l(1,i=_));function c(_){l(0,a=_)}function m(_){r.update(w=>[{text:`[${new Date().toLocaleTimeString()}]: `+(typeof _=="string"?_:JSON.stringify(_))},...w])}function v(_){r.update(w=>[{html:_},...w])}function k(){r.update(()=>[])}function g(){ii("https://tauri.studio/")}return[a,i,s,r,c,m,v,k,g,_=>c(_)]}class $s extends X{constructor(t){super();Y(this,t,Zs,Ks,J,{})}}new $s({target:document.body});