2022-09-15 17:28:52 +03:00
|
|
|
const $l=function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))i(o);new MutationObserver(o=>{for(const l of o)if(l.type==="childList")for(const u of l.addedNodes)u.tagName==="LINK"&&u.rel==="modulepreload"&&i(u)}).observe(document,{childList:!0,subtree:!0});function n(o){const l={};return o.integrity&&(l.integrity=o.integrity),o.referrerpolicy&&(l.referrerPolicy=o.referrerpolicy),o.crossorigin==="use-credentials"?l.credentials="include":o.crossorigin==="anonymous"?l.credentials="omit":l.credentials="same-origin",l}function i(o){if(o.ep)return;o.ep=!0;const l=n(o);fetch(o.href,l)}};$l();function J(){}function _l(t){return t()}function Uo(){return Object.create(null)}function pe(t){t.forEach(_l)}function er(t){return typeof t=="function"}function Me(t,e){return t!=t?e==e:t!==e||t&&typeof t=="object"||typeof t=="function"}let Fn;function tr(t,e){return Fn||(Fn=document.createElement("a")),Fn.href=e,t===Fn.href}function nr(t){return Object.keys(t).length===0}function ir(t,...e){if(t==null)return J;const n=t.subscribe(...e);return n.unsubscribe?()=>n.unsubscribe():n}function bl(t,e,n){t.$$.on_destroy.push(ir(e,n))}function r(t,e){t.appendChild(e)}function m(t,e,n){t.insertBefore(e,n||null)}function h(t){t.parentNode.removeChild(t)}function pt(t,e){for(let n=0;n<t.length;n+=1)t[n]&&t[n].d(e)}function s(t){return document.createElement(t)}function or(t){return document.createElementNS("http://www.w3.org/2000/svg",t)}function z(t){return document.createTextNode(t)}function v(){return z(" ")}function ei(){return z("")}function D(t,e,n,i){return t.addEventListener(e,n,i),()=>t.removeEventListener(e,n,i)}function Yn(t){return function(e){return e.preventDefault(),t.call(this,e)}}function a(t,e,n){n==null?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n)}function se(t){return t===""?null:+t}function lr(t){return Array.from(t.childNodes)}function Z(t,e){e=""+e,t.wholeText!==e&&(t.data=e)}function G(t,e){t.value=e==null?"":e}function Ot(t,e){for(let n=0;n<t.options.length;n+=1){const i=t.options[n];if(i.__value===e){i.selected=!0;return}}t.selectedIndex=-1}function Di(t){const e=t.querySelector(":checked")||t.options[0];return e&&e.__value}function qn(t,e,n){t.classList[n?"add":"remove"](e)}class rr{constructor(e=!1){this.is_svg=!1,this.is_svg=e,this.e=this.n=null}c(e){this.h(e)}m(e,n,i=null){this.e||(this.is_svg?this.e=or(n.nodeName):this.e=s(n.nodeName),this.t=n,this.c(e)),this.i(i)}h(e){this.e.innerHTML=e,this.n=Array.from(this.e.childNodes)}i(e){for(let n=0;n<this.n.length;n+=1)m(this.t,this.n[n],e)}p(e){this.d(),this.h(e),this.i(this.a)}d(){this.n.forEach(h)}}let Vt;function Bt(t){Vt=t}function gl(){if(!Vt)throw new Error("Function called outside component initialization");return Vt}function ct(t){gl().$$.on_mount.push(t)}function Ri(t){gl().$$.on_destroy.push(t)}const Ft=[],Kn=[],Vn=[],Fo=[],sr=Promise.resolve();let zi=!1;function ur(){zi||(zi=!0,sr.then(yl))}function At(t){Vn.push(t)}const Ai=new Set;let Bn=0;function yl(){const t=Vt;do{for(;Bn<Ft.length;){const e=Ft[Bn];Bn++,Bt(e),ar(e.$$)}for(Bt(null),Ft.length=0,Bn=0;Kn.length;)Kn.pop()();for(let e=0;e<Vn.length;e+=1){const n=Vn[e];Ai.has(n)||(Ai.add(n),n())}Vn.length=0}while(Ft.length);for(;Fo.length;)Fo.pop()();zi=!1,Ai.clear(),Bt(t)}function ar(t){if(t.fragment!==null){t.update(),pe(t.before_update);const e=t.dirty;t.dirty=[-1],t.fragment&&t.fragment.p(t.ctx,e),t.after_update.forEach(At)}}const Gn=new Set;let ft;function ti(){ft={r:0,c:[],p:ft}}function ni(){ft.r||pe(ft.c),ft=ft.p}function We(t,e){t&&t.i&&(Gn.delete(t),t.i(e))}function He(t,e,n,i){if(t&&t.o){if(Gn.has(t))return;Gn.add(t),ft.c.push(()=>{Gn.delete(t),i&&(n&&t.d(1),i())}),t.o(e)}else i&&i()}function xn(t){t&&t.c()}function Gt(t,e,n,i){const{fragment:o,on_mount:l,on_destroy:u,after_update:f}=t.$$;o&&o.m(e,n),i||At(()=>{const c=l.map(_l).filter(er);u?u.push(...c):pe(c),t.$$.on_mount=[]}),f.forEach(At)}function Jt(t,e){const n=t.$$;n.fragment!==null&&(pe(n.on_destroy),n.f
|
2022-07-04 04:15:23 +03:00
|
|
|
`),stderr:f.join(`
|
2022-09-15 17:28:52 +03:00
|
|
|
`)})}),n.spawn().catch(l)})]})})},e}(Jn);function Ni(t,e){return M(this,void 0,void 0,function(){return T(this,function(n){return[2,A({__tauriModule:"Shell",message:{cmd:"open",path:t,with:e}})]})})}Object.freeze({__proto__:null,Command:Tl,Child:Ml,EventEmitter:Jn,open:Ni});function Cl(t,e){return M(this,void 0,void 0,function(){return T(this,function(n){return[2,A({__tauriModule:"Event",message:{cmd:"unlisten",event:t,eventId:e}})]})})}function Ll(t,e,n){return M(this,void 0,void 0,function(){return T(this,function(i){switch(i.label){case 0:return[4,A({__tauriModule:"Event",message:{cmd:"emit",event:t,windowLabel:e,payload:typeof n=="string"?n:JSON.stringify(n)}})];case 1:return i.sent(),[2]}})})}function ji(t,e,n){return M(this,void 0,void 0,function(){var i=this;return T(this,function(o){return[2,A({__tauriModule:"Event",message:{cmd:"listen",event:t,windowLabel:e,handler:ht(n)}}).then(function(l){return function(){return M(i,void 0,void 0,function(){return T(this,function(u){return[2,Cl(t,l)]})})}})]})})}function Sl(t,e,n){return M(this,void 0,void 0,function(){return T(this,function(i){return[2,ji(t,e,function(o){n(o),Cl(t,o.id).catch(function(){})})]})})}var ve;function Yt(t,e){return M(this,void 0,void 0,function(){return T(this,function(n){return[2,ji(t,null,e)]})})}function Ol(t,e){return M(this,void 0,void 0,function(){return T(this,function(n){return[2,Sl(t,null,e)]})})}function ii(t,e){return M(this,void 0,void 0,function(){return T(this,function(n){return[2,Ll(t,void 0,e)]})})}(function(t){t.WINDOW_RESIZED="tauri://resize",t.WINDOW_MOVED="tauri://move",t.WINDOW_CLOSE_REQUESTED="tauri://close-requested",t.WINDOW_CREATED="tauri://window-created",t.WINDOW_DESTROYED="tauri://destroyed",t.WINDOW_FOCUS="tauri://focus",t.WINDOW_BLUR="tauri://blur",t.WINDOW_SCALE_FACTOR_CHANGED="tauri://scale-change",t.WINDOW_THEME_CHANGED="tauri://theme-changed",t.WINDOW_FILE_DROP="tauri://file-drop",t.WINDOW_FILE_DROP_HOVER="tauri://file-drop-hover",t.WINDOW_FILE_DROP_CANCELLED="tauri://file-drop-cancelled",t.MENU="tauri://menu",t.CHECK_UPDATE="tauri://update",t.UPDATE_AVAILABLE="tauri://update-available",t.INSTALL_UPDATE="tauri://update-install",t.STATUS_UPDATE="tauri://update-status",t.DOWNLOAD_PROGRESS="tauri://update-download-progress"})(ve||(ve={}));Object.freeze({__proto__:null,get TauriEvent(){return ve},listen:Yt,once:Ol,emit:ii});var Xt,Zn=function(t,e){this.type="Logical",this.width=t,this.height=e},St=function(){function t(e,n){this.type="Physical",this.width=e,this.height=n}return t.prototype.toLogical=function(e){return new Zn(this.width/e,this.height/e)},t}(),Al=function(t,e){this.type="Logical",this.x=t,this.y=e},dt=function(){function t(e,n){this.type="Physical",this.x=e,this.y=n}return t.prototype.toLogical=function(e){return new Al(this.x/e,this.y/e)},t}();function qt(){return new Et(window.__TAURI_METADATA__.__currentWindow.label,{skip:!0})}function El(){return window.__TAURI_METADATA__.__windows.map(function(t){return new Et(t.label,{skip:!0})})}(function(t){t[t.Critical=1]="Critical",t[t.Informational=2]="Informational"})(Xt||(Xt={}));var Be,qo=["tauri://created","tauri://error"],Dl=function(){function t(e){this.label=e,this.listeners=Object.create(null)}return t.prototype.listen=function(e,n){return M(this,void 0,void 0,function(){var i=this;return T(this,function(o){return this._handleTauriEvent(e,n)?[2,Promise.resolve(function(){var l=i.listeners[e];l.splice(l.indexOf(n),1)})]:[2,ji(e,this.label,n)]})})},t.prototype.once=function(e,n){return M(this,void 0,void 0,function(){var i=this;return T(this,function(o){return this._handleTauriEvent(e,n)?[2,Promise.resolve(function(){var l=i.listeners[e];l.splice(l.indexOf(n),1)})]:[2,Sl(e,this.label,n)]})})},t.prototype.emit=function(e,n){return M(this,void 0,void 0,function(){var i,o;return T(this,function(l){if(qo.includes(e)){for(i=0,o=this.listeners[e]||[];i<o.length;i++)(0,o[i])({event:e,id:-1,windowLabel:this.label,payload:n});return[2,Promise.resolve()]}return[2,Ll(e,this.label,n)]})})},t.prototype._handleTauriEvent=function(e,n){return!!qo.includes(e)&&(e in
|
|
|
|
Note that this is not an issue if running this frontend on a browser instead of a Tauri window.`),Be=new Et("main",{skip:!0}));Object.freeze({__proto__:null,WebviewWindow:Et,WebviewWindowHandle:Dl,WindowManager:zl,CloseRequestedEvent:Wl,getCurrent:qt,getAll:El,get appWindow(){return Be},LogicalSize:Zn,PhysicalSize:St,LogicalPosition:Al,PhysicalPosition:dt,get UserAttentionType(){return Xt},currentMonitor:dr,primaryMonitor:pr,availableMonitors:hr});function mr(){return navigator.appVersion.includes("Win")}var vr=mr()?`\r
|
2022-07-04 04:15:23 +03:00
|
|
|
`:`
|
2022-09-15 17:28:52 +03:00
|
|
|
`;function Pl(){return M(this,void 0,void 0,function(){return T(this,function(t){return[2,A({__tauriModule:"Os",message:{cmd:"platform"}})]})})}function _r(){return M(this,void 0,void 0,function(){return T(this,function(t){return[2,A({__tauriModule:"Os",message:{cmd:"version"}})]})})}function br(){return M(this,void 0,void 0,function(){return T(this,function(t){return[2,A({__tauriModule:"Os",message:{cmd:"osType"}})]})})}function gr(){return M(this,void 0,void 0,function(){return T(this,function(t){return[2,A({__tauriModule:"Os",message:{cmd:"arch"}})]})})}function yr(){return M(this,void 0,void 0,function(){return T(this,function(t){return[2,A({__tauriModule:"Os",message:{cmd:"tempdir"}})]})})}Object.freeze({__proto__:null,EOL:vr,platform:Pl,version:_r,type:br,arch:gr,tempdir:yr});function Rl(){return M(this,void 0,void 0,function(){return T(this,function(t){return[2,A({__tauriModule:"App",message:{cmd:"getAppVersion"}})]})})}function Il(){return M(this,void 0,void 0,function(){return T(this,function(t){return[2,A({__tauriModule:"App",message:{cmd:"getAppName"}})]})})}function Nl(){return M(this,void 0,void 0,function(){return T(this,function(t){return[2,A({__tauriModule:"App",message:{cmd:"getTauriVersion"}})]})})}Object.freeze({__proto__:null,getName:Il,getVersion:Rl,getTauriVersion:Nl});function jl(t){return t===void 0&&(t=0),M(this,void 0,void 0,function(){return T(this,function(e){return[2,A({__tauriModule:"Process",message:{cmd:"exit",exitCode:t}})]})})}function Hi(){return M(this,void 0,void 0,function(){return T(this,function(t){return[2,A({__tauriModule:"Process",message:{cmd:"relaunch"}})]})})}Object.freeze({__proto__:null,exit:jl,relaunch:Hi});function wr(t){let e,n,i,o,l,u,f,c,p,d,k,_,y,g,b,O,W,U,R,q,E,L,S,P,C,F;return{c(){e=s("p"),e.innerHTML=`This is a demo of Tauri's API capabilities using the <code>@tauri-apps/api</code> package. It's used as the main validation app, serving as the test bed of our
|
2022-07-04 04:15:23 +03:00
|
|
|
development process. In the future, this app will be used on Tauri's integration
|
2022-09-15 17:28:52 +03:00
|
|
|
tests.`,n=v(),i=s("br"),o=v(),l=s("br"),u=v(),f=s("pre"),c=z("App name: "),p=s("code"),d=z(t[2]),k=z(`
|
|
|
|
App version: `),_=s("code"),y=z(t[0]),g=z(`
|
|
|
|
Tauri version: `),b=s("code"),O=z(t[1]),W=z(`
|
|
|
|
`),U=v(),R=s("br"),q=v(),E=s("div"),L=s("button"),L.textContent="Close application",S=v(),P=s("button"),P.textContent="Relaunch application",a(L,"class","btn"),a(P,"class","btn"),a(E,"class","flex flex-wrap gap-1 shadow-")},m(B,Y){m(B,e,Y),m(B,n,Y),m(B,i,Y),m(B,o,Y),m(B,l,Y),m(B,u,Y),m(B,f,Y),r(f,c),r(f,p),r(p,d),r(f,k),r(f,_),r(_,y),r(f,g),r(f,b),r(b,O),r(f,W),m(B,U,Y),m(B,R,Y),m(B,q,Y),m(B,E,Y),r(E,L),r(E,S),r(E,P),C||(F=[D(L,"click",t[3]),D(P,"click",t[4])],C=!0)},p(B,[Y]){Y&4&&Z(d,B[2]),Y&1&&Z(y,B[0]),Y&2&&Z(O,B[1])},i:J,o:J,d(B){B&&h(e),B&&h(n),B&&h(i),B&&h(o),B&&h(l),B&&h(u),B&&h(f),B&&h(U),B&&h(R),B&&h(q),B&&h(E),C=!1,pe(F)}}}function kr(t,e,n){let i="0.0.0",o="0.0.0",l="Unknown";Il().then(c=>{n(2,l=c)}),Rl().then(c=>{n(0,i=c)}),Nl().then(c=>{n(1,o=c)});async function u(){await jl()}async function f(){await Hi()}return[i,o,l,u,f]}class Mr extends Se{constructor(e){super(),Le(this,e,kr,wr,Me,{})}}function Hl(){return M(this,void 0,void 0,function(){return T(this,function(t){return[2,A({__tauriModule:"Cli",message:{cmd:"cliMatches"}})]})})}Object.freeze({__proto__:null,getMatches:Hl});function Tr(t){let e,n,i,o,l,u,f,c,p,d,k,_,y;return{c(){e=s("p"),e.innerHTML=`This binary can be run from the terminal and takes the following arguments:
|
2022-07-04 04:15:23 +03:00
|
|
|
<code class="code-block flex flex-wrap my-2"><pre> --config <PATH>
|
|
|
|
--theme <light|dark|system>
|
|
|
|
--verbose</pre></code>
|
2022-09-15 17:28:52 +03:00
|
|
|
Additionally, it has a <code>update --background</code> subcommand.`,n=v(),i=s("br"),o=v(),l=s("div"),l.textContent="Note that the arguments are only parsed, not implemented.",u=v(),f=s("br"),c=v(),p=s("br"),d=v(),k=s("button"),k.textContent="Get matches",a(l,"class","note"),a(k,"class","btn"),a(k,"id","cli-matches")},m(g,b){m(g,e,b),m(g,n,b),m(g,i,b),m(g,o,b),m(g,l,b),m(g,u,b),m(g,f,b),m(g,c,b),m(g,p,b),m(g,d,b),m(g,k,b),_||(y=D(k,"click",t[0]),_=!0)},p:J,i:J,o:J,d(g){g&&h(e),g&&h(n),g&&h(i),g&&h(o),g&&h(l),g&&h(u),g&&h(f),g&&h(c),g&&h(p),g&&h(d),g&&h(k),_=!1,y()}}}function Cr(t,e,n){let{onMessage:i}=e;function o(){Hl().then(i).catch(i)}return t.$$set=l=>{"onMessage"in l&&n(1,i=l.onMessage)},[o,i]}class Lr extends Se{constructor(e){super(),Le(this,e,Cr,Tr,Me,{onMessage:1})}}function Sr(t){let e,n,i,o,l,u,f,c;return{c(){e=s("div"),n=s("button"),n.textContent="Call Log API",i=v(),o=s("button"),o.textContent="Call Request (async) API",l=v(),u=s("button"),u.textContent="Send event to Rust",a(n,"class","btn"),a(n,"id","log"),a(o,"class","btn"),a(o,"id","request"),a(u,"class","btn"),a(u,"id","event")},m(p,d){m(p,e,d),r(e,n),r(e,i),r(e,o),r(e,l),r(e,u),f||(c=[D(n,"click",t[0]),D(o,"click",t[1]),D(u,"click",t[2])],f=!0)},p:J,i:J,o:J,d(p){p&&h(e),f=!1,pe(c)}}}function Or(t,e,n){let{onMessage:i}=e,o;ct(async()=>{o=await Yt("rust-event",i)}),Ri(()=>{o&&o()});function l(){Qn("log_operation",{event:"tauri-click",payload:"this payload is optional because we used Option in Rust"})}function u(){Qn("perform_request",{endpoint:"dummy endpoint arg",body:{id:5,name:"test"}}).then(i).catch(i)}function f(){ii("js-event","this is the payload string")}return t.$$set=c=>{"onMessage"in c&&n(3,i=c.onMessage)},[l,u,f,i]}class Ar extends Se{constructor(e){super(),Le(this,e,Or,Sr,Me,{onMessage:3})}}function Ui(t){return t===void 0&&(t={}),M(this,void 0,void 0,function(){return T(this,function(e){return typeof t=="object"&&Object.freeze(t),[2,A({__tauriModule:"Dialog",message:{cmd:"openDialog",options:t}})]})})}function Ul(t){return t===void 0&&(t={}),M(this,void 0,void 0,function(){return T(this,function(e){return typeof t=="object"&&Object.freeze(t),[2,A({__tauriModule:"Dialog",message:{cmd:"saveDialog",options:t}})]})})}function Er(t,e){var n;return M(this,void 0,void 0,function(){var i;return T(this,function(o){return i=typeof e=="string"?{title:e}:e,[2,A({__tauriModule:"Dialog",message:{cmd:"messageDialog",message:t.toString(),title:(n=i==null?void 0:i.title)===null||n===void 0?void 0:n.toString(),type:i==null?void 0:i.type}})]})})}function Fl(t,e){var n;return M(this,void 0,void 0,function(){var i;return T(this,function(o){return i=typeof e=="string"?{title:e}:e,[2,A({__tauriModule:"Dialog",message:{cmd:"askDialog",message:t.toString(),title:(n=i==null?void 0:i.title)===null||n===void 0?void 0:n.toString(),type:i==null?void 0:i.type}})]})})}function Dr(t,e){var n;return M(this,void 0,void 0,function(){var i;return T(this,function(o){return i=typeof e=="string"?{title:e}:e,[2,A({__tauriModule:"Dialog",message:{cmd:"confirmDialog",message:t.toString(),title:(n=i==null?void 0:i.title)===null||n===void 0?void 0:n.toString(),type:i==null?void 0:i.type}})]})})}Object.freeze({__proto__:null,open:Ui,save:Ul,message:Er,ask:Fl,confirm:Dr});var Dt;function zr(t,e){return e===void 0&&(e={}),M(this,void 0,void 0,function(){return T(this,function(n){return[2,A({__tauriModule:"Fs",message:{cmd:"readTextFile",path:t,options:e}})]})})}function Fi(t,e){return e===void 0&&(e={}),M(this,void 0,void 0,function(){var n;return T(this,function(i){switch(i.label){case 0:return[4,A({__tauriModule:"Fs",message:{cmd:"readFile",path:t,options:e}})];case 1:return n=i.sent(),[2,Uint8Array.from(n)]}})})}function Pi(t,e,n){return M(this,void 0,void 0,function(){var i,o;return T(this,function(l){return typeof n=="object"&&Object.freeze(n),typeof t=="object"&&Object.freeze(t),i={path:"",contents:""},o=n,typeof t=="string"?i.path=t:(i.path=t.path,i.contents=t.contents),typeof e=="string"?i.contents=e!=null?e:"":o=e,[2,A({__tauriModule:"Fs",message:{cmd:"writeFile",path:i.path,
|
|
|
|
Multipart`),te=v(),oe=s("br"),K=v(),ge=s("br"),N=v(),x=s("button"),x.textContent="Post it",le=v(),ae=s("br"),ee=v(),_e=s("br"),re=v(),xn(ye.$$.fragment),i.__value="GET",i.value=i.__value,o.__value="POST",o.value=o.__value,l.__value="PUT",l.value=l.__value,u.__value="PATCH",u.value=u.__value,f.__value="DELETE",f.value=f.__value,a(n,"class","input"),a(n,"id","request-method"),t[0]===void 0&&At(()=>t[9].call(n)),a(k,"class","input h-auto w-100%"),a(k,"id","request-body"),a(k,"placeholder","Request body"),a(k,"rows","5"),a(b,"class","btn"),a(b,"id","make-request"),a(L,"class","input"),a(P,"class","input"),a(E,"class","flex gap-2 children:grow"),a($,"type","checkbox"),a(x,"class","btn"),a(x,"type","button")},m(I,V){m(I,e,V),r(e,n),r(n,i),r(n,o),r(n,l),r(n,u),r(n,f),Ot(n,t[0]),r(e,c),r(e,p),r(e,d),r(e,k),G(k,t[1]),r(e,_),r(e,y),r(e,g),r(e,b),m(I,O,V),m(I,W,V),m(I,U,V),m(I,R,V),m(I,q,V),m(I,E,V),r(E,L),G(L,t[2]),r(E,S),r(E,P),G(P,t[3]),m(I,C,V),m(I,F,V),m(I,B,V),m(I,Y,V),r(Y,$),$.checked=t[5],r(Y,be),m(I,te,V),m(I,oe,V),m(I,K,V),m(I,ge,V),m(I,N,V),m(I,x,V),m(I,le,V),m(I,ae,V),m(I,ee,V),m(I,_e,V),m(I,re,V),Gt(ye,I,V),ne=!0,Te||(Ae=[D(n,"change",t[9]),D(k,"input",t[10]),D(e,"submit",Yn(t[6])),D(L,"input",t[11]),D(P,"input",t[12]),D($,"change",t[13]),D(x,"click",t[7])],Te=!0)},p(I,[V]){V&1&&Ot(n,I[0]),V&2&&G(k,I[1]),V&4&&L.value!==I[2]&&G(L,I[2]),V&8&&P.value!==I[3]&&G(P,I[3]),V&32&&($.checked=I[5]);const Ne={};V&16&&(Ne.json=I[4]),ye.$set(Ne)},i(I){ne||(We(ye.$$.fragment,I),ne=!0)},o(I){He(ye.$$.fragment,I),ne=!1},d(I){I&&h(e),I&&h(O),I&&h(W),I&&h(U),I&&h(R),I&&h(q),I&&h(E),I&&h(C),I&&h(F),I&&h(B),I&&h(Y),I&&h(te),I&&h(oe),I&&h(K),I&&h(ge),I&&h(N),I&&h(x),I&&h(le),I&&h(ae),I&&h(ee),I&&h(_e),I&&h(re),Jt(ye,I),Te=!1,pe(Ae)}}}function ts(t,e,n){let i="GET",o="",{onMessage:l}=e;async function u(){const W=await $n().catch(q=>{throw l(q),q}),R={url:"http://localhost:3003",method:i||"GET"||"GET"};o.startsWith("{")&&o.endsWith("}")||o.startsWith("[")&&o.endsWith("]")?R.body=Xn.json(JSON.parse(o)):o!==""&&(R.body=Xn.text(o)),W.request(R).then(l).catch(l)}let f="baz",c="qux",p=null,d=!0;async function k(){const W=await $n().catch(U=>{throw l(U),U});n(4,p=await W.request({url:"http://localhost:3003",method:"POST",body:Xn.form({foo:f,bar:c}),headers:d?{"Content-Type":"multipart/form-data"}:void 0,responseType:zt.Text}))}function _(){i=Di(this),n(0,i)}function y(){o=this.value,n(1,o)}function g(){f=this.value,n(2,f)}function b(){c=this.value,n(3,c)}function O(){d=this.checked,n(5,d)}return t.$$set=W=>{"onMessage"in W&&n(8,l=W.onMessage)},[i,o,f,c,p,d,u,k,l,_,y,g,b,O]}class ns extends Se{constructor(e){super(),Le(this,e,ts,es,Me,{onMessage:8})}}function is(t){let e,n,i;return{c(){e=s("button"),e.textContent="Send test notification",a(e,"class","btn"),a(e,"id","notification")},m(o,l){m(o,e,l),n||(i=D(e,"click",os),n=!0)},p:J,i:J,o:J,d(o){o&&h(e),n=!1,i()}}}function os(){new Notification("Notification title",{body:"This is the notification body"})}function ls(t,e,n){let{onMessage:i}=e;return t.$$set=o=>{"onMessage"in o&&n(0,i=o.onMessage)},[i]}class rs extends Se{constructor(e){super(),Le(this,e,ls,is,Me,{onMessage:0})}}function $o(t,e,n){const i=t.slice();return i[65]=e[n],i}function el(t,e,n){const i=t.slice();return i[68]=e[n],i}function tl(t){let e,n,i,o,l,u,f=Object.keys(t[1]),c=[];for(let p=0;p<f.length;p+=1)c[p]=nl(el(t,f,p));return{c(){e=s("span"),e.textContent="Selected window:",n=v(),i=s("select"),o=s("option"),o.textContent="Choose a window...";for(let p=0;p<c.length;p+=1)c[p].c();a(e,"class","font-700 text-sm"),o.__value="",o.value=o.__value,o.disabled=!0,o.selected=!0,a(i,"class","input"),t[0]===void 0&&At(()=>t[38].call(i))},m(p,d){m(p,e,d),m(p,n,d),m(p,i,d),r(i,o);for(let k=0;k<c.length;k+=1)c[k].m(i,null);Ot(i,t[0]),l||(u=D(i,"change",t[38]),l=!0)},p(p,d){if(d[0]&2){f=Object.keys(p[1]);let k;for(k=0;k<f.length;k+=1){const _=el(p,f,k);c[k]?c[k].p(_,d):(c[k]=nl(_),c[k].c(),c[k].m(i,null))}for(;k<c.length;k+=1)c[k].d(1);c.length=f.length}d[0]&3&&Ot(i,p[0])},d(p){p&&h(e),p&&h(n),p&&h(i),pt(c,p),l=!1,u()}}}function nl(t){let e,n=t[
|
|
|
|
`),R=s("input"),q=v(),E=s("label"),L=z(`Resizable
|
|
|
|
`),S=s("input"),P=v(),C=s("label"),F=z(`Has decorations
|
|
|
|
`),B=s("input"),Y=v(),$=s("label"),be=z(`Always on top
|
|
|
|
`),te=s("input"),oe=v(),K=s("label"),ge=z(`Fullscreen
|
|
|
|
`),N=s("input"),x=v(),le=s("br"),ae=v(),ee=s("div"),_e=s("div"),re=s("div"),ye=z(`X
|
|
|
|
`),ne=s("input"),Te=v(),Ae=s("div"),I=z(`Y
|
|
|
|
`),V=s("input"),Ne=v(),Ee=s("div"),Ce=s("div"),ce=z(`Width
|
|
|
|
`),he=s("input"),fe=v(),De=s("div"),nt=z(`Height
|
|
|
|
`),me=s("input"),de=v(),j=s("div"),ie=s("div"),X=z(`Min width
|
|
|
|
`),we=s("input"),Kt=v(),mt=s("div"),xt=z(`Min height
|
|
|
|
`),je=s("input"),Qt=v(),Ve=s("div"),Q=s("div"),Wt=z(`Max width
|
|
|
|
`),Pe=s("input"),Pt=v(),it=s("div"),Rt=z(`Max height
|
|
|
|
`),Re=s("input"),vt=v(),_t=s("br"),bt=v(),ze=s("div"),Ue=s("div"),Ie=s("div"),ot=s("div"),ot.textContent="Inner Size",It=v(),lt=s("span"),Nt=z("Width: "),oi=z(gt),Bi=v(),Zt=s("span"),Vi=z("Height: "),li=z($t),Gi=v(),Ge=s("div"),en=s("div"),en.textContent="Outer Size",Ji=v(),tn=s("span"),Xi=z("Width: "),ri=z(nn),Yi=v(),on=s("span"),Ki=z("Height: "),si=z(ln),xi=v(),yt=s("div"),Je=s("div"),rn=s("div"),rn.textContent="Inner Logical Size",Qi=v(),sn=s("span"),Zi=z("Width: "),ui=z(un),$i=v(),an=s("span"),eo=z("Height: "),ai=z(cn),to=v(),Xe=s("div"),fn=s("div"),fn.textContent="Outer Logical Size",no=v(),dn=s("span"),io=z("Width: "),ci=z(pn),oo=v(),hn=s("span"),lo=z("Height: "),fi=z(mn),ro=v(),wt=s("div"),Ye=s("div"),vn=s("div"),vn.textContent="Inner Position",so=v(),_n=s("span"),uo=z("x: "),di=z(bn),ao=v(),gn=s("span"),co=z("y: "),pi=z(yn),fo=v(),Ke=s("div"),wn=s("div"),wn.textContent="Outer Position",po=v(),kn=s("span"),ho=z("x: "),hi=z(Mn),mo=v(),Tn=s("span"),vo=z("y: "),mi=z(Cn),_o=v(),kt=s("div"),xe=s("div"),Ln=s("div"),Ln.textContent="Inner Logical Position",bo=v(),Sn=s("span"),go=z("x: "),vi=z(On),yo=v(),An=s("span"),wo=z("y: "),_i=z(En),ko=v(),Qe=s("div"),Dn=s("div"),Dn.textContent="Outer Logical Position",Mo=v(),zn=s("span"),To=z("x: "),bi=z(Wn),Co=v(),Pn=s("span"),Lo=z("y: "),gi=z(Rn),yi=v(),wi=s("br"),ki=v(),jt=s("h4"),jt.textContent="Cursor",Mi=v(),rt=s("div"),In=s("label"),Mt=s("input"),So=z(`
|
|
|
|
Grab`),Oo=v(),Nn=s("label"),Tt=s("input"),Ao=z(`
|
|
|
|
Visible`),Ti=v(),Fe=s("div"),jn=s("label"),Eo=z(`Icon
|
|
|
|
`),qe=s("select");for(let w=0;w<Oe.length;w+=1)Oe[w].c();Do=v(),Hn=s("label"),zo=z(`X position
|
|
|
|
`),Ze=s("input"),Wo=v(),Un=s("label"),Po=z(`Y position
|
|
|
|
`),$e=s("input"),Ci=v(),Li=s("br"),Si=v(),st=s("div"),ut=s("form"),et=s("input"),Ro=v(),Ht=s("button"),Ht.textContent="Set title",Io=v(),at=s("form"),tt=s("input"),No=v(),Ut=s("button"),Ut.textContent="Open URL",a(o,"class","btn"),a(o,"title","Unminimizes after 2 seconds"),a(u,"class","btn"),a(u,"title","Unminimizes after 2 seconds"),a(c,"class","btn"),a(c,"title","Visible again after 2 seconds"),a(d,"class","btn"),a(_,"class","btn"),a(_,"title","Minimizes the window, requests attention for 3s and then resets it"),a(i,"class","flex flex-wrap gap-2"),a(R,"type","checkbox"),a(S,"type","checkbox"),a(B,"type","checkbox"),a(te,"type","checkbox"),a(N,"type","checkbox"),a(O,"class","flex flex-wrap gap-2"),a(ne,"class","input"),a(ne,"type","number"),a(ne,"min","0"),a(V,"class","input"),a(V,"type","number"),a(V,"min","0"),a(_e,"class","flex children:grow flex-col"),a(he,"class","input"),a(he,"type","number"),a(he,"min","400"),a(me,"class","input"),a(me,"type","number"),a(me,"min","400"),a(Ee,"class","flex children:grow flex-col"),a(we,"class","input"),a(we,"type","number"),a(je,"class","input"),a(je,"type","number"),a(j,"class","flex children:grow flex-col"),a(Pe,"class","input"),a(Pe,"type","number"),a(Pe,"min","800"),a(Re,"class","input"),a(Re,"type","number"),a(Re,"min","400"),a(Ve,"class","flex children:grow flex-col"),a(ee,"class","flex flex-row gap-2 flex-wrap"),a(ot,"class","text-accent dark:text-darkAccent font-700"),a(Ie,"class","grow"),a(en,"class","text-accent dark:text-darkAccent font-700"),a(Ge,"class","grow"),a(Ue,"class","flex"),a(rn,"class","text-accent dark:text-darkAccent font-700"),a(Je,"class","grow"),a(fn,"class","text-accent dark:text-darkAccent font-700"),a(Xe,"class","grow"),a(yt,"class","flex"),a(vn,"class","text-accent dark:text-darkAccent font-700"),a(Ye,"class","grow"),a(wn,"class","text-accent dark:text-darkAccent font-700"),a(Ke,"class","grow"),a(wt,"class","flex"),a(Ln,"class","text-accent dark:text-darkAccent font-700"),a(xe,"class","grow"),a(Dn,"class","text-accent dark:text-darkAccent font-700"),a(Qe,"class","grow"),a(kt,"class","flex"),a(jt,"class","mb-2"),a(Mt,"type","checkbox"),a(Tt,"type","checkbox"),a(rt,"class","flex gap-2"),a(qe,"class","input"),t[19]===void 0&&At(()=>t[55].call(qe)),a(Ze,"class","input"),a(Ze,"type","number"),a($e,"class","input"),a($e,"type","number"),a(Fe,"class","flex gap-2"),a(et,"class","input grow"),a(et,"id","title"),a(Ht,"class","btn"),a(Ht,"type","submit"),a(ut,"class","flex gap-1"),a(tt,"class","input grow"),a(tt,"id","url"),a(Ut,"class","btn"),a(Ut,"id","open-url"),a(at,"class","flex gap-1"),a(st,"class","flex flex-col gap-1")},m(w,H){m(w,e,H),m(w,n,H),m(w,i,H),r(i,o),r(i,l),r(i,u),r(i,f),r(i,c),r(i,p),r(i,d),r(i,k),r(i,_),m(w,y,H),m(w,g,H),m(w,b,H),m(w,O,H),r(O,W),r(W,U),r(W,R),R.checked=t[3],r(O,q),r(O,E),r(E,L),r(E,S),S.checked=t[2],r(O,P),r(O,C),r(C,F),r(C,B),B.checked=t[4],r(O,Y),r(O,$),r($,be),r($,te),te.checked=t[5],r(O,oe),r(O,K),r(K,ge),r(K,N),N.checked=t[6],m(w,x,H),m(w,le,H),m(w,ae,H),m(w,ee,H),r(ee,_e),r(_e,re),r(re,ye),r(re,ne),G(ne,t[13]),r(_e,Te),r(_e,Ae),r(Ae,I),r(Ae,V),G(V,t[14]),r(ee,Ne),r(ee,Ee),r(Ee,Ce),r(Ce,ce),r(Ce,he),G(he,t[7]),r(Ee,fe),r(Ee,De),r(De,nt),r(De,me),G(me,t[8]),r(ee,de),r(ee,j),r(j,ie),r(ie,X),r(ie,we),G(we,t[9]),r(j,Kt),r(j,mt),r(mt,xt),r(mt,je),G(je,t[10]),r(ee,Qt),r(ee,Ve),r(Ve,Q),r(Q,Wt),r(Q,Pe),G(Pe,t[11]),r(Ve,Pt),r(Ve,it),r(it,Rt),r(it,Re),G(Re,t[12]),m(w,vt,H),m(w,_t,H),m(w,bt,H),m(w,ze,H),r(ze,Ue),r(Ue,Ie),r(Ie,ot),r(Ie,It),r(Ie,lt),r(lt,Nt),r(lt,oi),r(Ie,Bi),r(Ie,Zt),r(Zt,Vi),r(Zt,li),r(Ue,Gi),r(Ue,Ge),r(Ge,en),r(Ge,Ji),r(Ge,tn),r(tn,Xi),r(tn,ri),r(Ge,Yi),r(Ge,on),r(on,Ki),r(on,si),r(ze,xi),r(ze,yt),r(yt,Je),r(Je,rn),r(Je,Qi),r(Je,sn),r(sn,Zi),r(sn,ui),r(Je,$i),r(Je,an),r(an,eo),r(an,ai),r(yt,to),r(yt,Xe),r(Xe,fn),r(Xe,no),r(Xe,dn),r(dn,io),r(dn,ci),r(Xe,oo),r(Xe,hn),r(hn,lo),r(hn,fi),r(ze,ro),r(ze,wt),r(wt,Ye),r(Ye,vn),r(Ye,so),r(Ye,_n),r(_n,uo),r(_n,di),r(Ye,ao),r(Ye,gn),r(gn,co),r(gn,pi),r(wt,fo),r(wt,Ke),r(Ke,wn),r(Ke,po),r(Ke,kn),r(kn,ho),r(kn,hi),r(Ke,mo),r(Ke,Tn),r(Tn,vo),r(Tn,mi),r(ze,_o),r(ze,kt),
|
|
|
|
`),o=s("input"),l=v(),u=s("div"),f=z(`Encoding:
|
|
|
|
`),c=s("input"),p=v(),d=s("div"),k=z(`Working directory:
|
|
|
|
`),_=s("input"),y=v(),g=s("div"),b=z(`Arguments:
|
|
|
|
`),O=s("input"),W=v(),U=s("div"),R=s("button"),R.textContent="Run",q=v(),E=s("button"),E.textContent="Kill",L=v(),C&&C.c(),a(o,"class","grow input"),a(n,"class","flex items-center gap-1"),a(c,"class","grow input"),a(u,"class","flex items-center gap-1"),a(_,"class","grow input"),a(_,"placeholder","Working directory"),a(d,"class","flex items-center gap-1"),a(O,"class","grow input"),a(O,"placeholder","Environment variables"),a(g,"class","flex items-center gap-1"),a(R,"class","btn"),a(E,"class","btn"),a(U,"class","flex children:grow gap-1"),a(e,"class","flex flex-col childre:grow gap-1")},m(F,B){m(F,e,B),r(e,n),r(n,i),r(n,o),G(o,t[0]),r(e,l),r(e,u),r(u,f),r(u,c),G(c,t[3]),r(e,p),r(e,d),r(d,k),r(d,_),G(_,t[1]),r(e,y),r(e,g),r(g,b),r(g,O),G(O,t[2]),r(e,W),r(e,U),r(U,R),r(U,q),r(U,E),r(e,L),C&&C.m(e,null),S||(P=[D(o,"input",t[10]),D(c,"input",t[11]),D(_,"input",t[12]),D(O,"input",t[13]),D(R,"click",t[6]),D(E,"click",t[7])],S=!0)},p(F,[B]){B&1&&o.value!==F[0]&&G(o,F[0]),B&8&&c.value!==F[3]&&G(c,F[3]),B&2&&_.value!==F[1]&&G(_,F[1]),B&4&&O.value!==F[2]&&G(O,F[2]),F[5]?C?C.p(F,B):(C=ul(F),C.c(),C.m(e,null)):C&&(C.d(1),C=null)},i:J,o:J,d(F){F&&h(e),C&&C.d(),S=!1,pe(P)}}}function vs(t,e,n){const i=navigator.userAgent.includes("Windows");let o=i?"cmd":"sh",l=i?["/C"]:["-c"],{onMessage:u}=e,f='echo "hello world"',c=null,p="SOMETHING=value ANOTHER=2",d="",k="",_;function y(){return p.split(" ").reduce((L,S)=>{let[P,C]=S.split("=");return{...L,[P]:C}},{})}function g(){n(5,_=null);const L=new Tl(o,[...l,f],{cwd:c||null,env:y(),encoding:d});L.on("close",S=>{u(`command finished with code ${S.code} and signal ${S.signal}`),n(5,_=null)}),L.on("error",S=>u(`command error: "${S}"`)),L.stdout.on("data",S=>u(`command stdout: "${S}"`)),L.stderr.on("data",S=>u(`command stderr: "${S}"`)),L.spawn().then(S=>{n(5,_=S)}).catch(u)}function b(){_.kill().then(()=>u("killed child process")).catch(u)}function O(){_.write(k).catch(u)}function W(){f=this.value,n(0,f)}function U(){d=this.value,n(3,d)}function R(){c=this.value,n(1,c)}function q(){p=this.value,n(2,p)}function E(){k=this.value,n(4,k)}return t.$$set=L=>{"onMessage"in L&&n(9,u=L.onMessage)},[f,c,p,d,k,_,g,b,O,u,W,U,R,q,E]}class _s extends Se{constructor(e){super(),Le(this,e,vs,ms,Me,{onMessage:9})}}function qi(t){return M(this,void 0,void 0,function(){return T(this,function(e){return[2,Yt(ve.STATUS_UPDATE,function(n){t(n==null?void 0:n.payload)})]})})}function Kl(){return M(this,void 0,void 0,function(){function t(){e&&e(),e=void 0}var e;return T(this,function(n){return[2,new Promise(function(i,o){qi(function(l){return l.error?(t(),o(l.error)):l.status==="DONE"?(t(),i()):void 0}).then(function(l){e=l}).catch(function(l){throw t(),l}),ii(ve.INSTALL_UPDATE).catch(function(l){throw t(),l})})]})})}function xl(){return M(this,void 0,void 0,function(){function t(){e&&e(),e=void 0}var e;return T(this,function(n){return[2,new Promise(function(i,o){Ol(ve.UPDATE_AVAILABLE,function(l){var u;u=l==null?void 0:l.payload,t(),i({manifest:u,shouldUpdate:!0})}).catch(function(l){throw t(),l}),qi(function(l){return l.error?(t(),o(l.error)):l.status==="UPTODATE"?(t(),i({shouldUpdate:!1})):void 0}).then(function(l){e=l}).catch(function(l){throw t(),l}),ii(ve.CHECK_UPDATE).catch(function(l){throw t(),l})})]})})}Object.freeze({__proto__:null,onUpdaterEvent:qi,installUpdate:Kl,checkUpdate:xl});function bs(t){let e;return{c(){e=s("button"),e.innerHTML='<div class="spinner animate-spin svelte-4xesec"></div>',a(e,"class","btn text-accentText dark:text-darkAccentText flex items-center justify-center")},m(n,i){m(n,e,i)},p:J,d(n){n&&h(e)}}}function gs(t){let e,n,i;return{c(){e=s("button"),e.textContent="Install update",a(e,"class","btn")},m(o,l){m(o,e,l),n||(i=D(e,"click",t[4]),n=!0)},p:J,d(o){o&&h(e),n=!1,i()}}}function ys(t){let e,n,i;return{c(){e=s("button"),e.textContent="Check update",a(e,"class","btn")},m(o,l){m(o,e,l),n||(i=D(e,"click",t[3]),n=!0)},p:J,d(o){o&&h(e),n=!1,i()}}}function ws(t){let e;function n(l,u){return!l[0]&&!l[2]?ys:!l[1]&&l[2]?gs:bs}let i=n(t),o=i(t);return{c(){e=s("div"),o.c(),a(e,"class","flex ch
|
|
|
|
<video id="localVideo" autoplay="" playsinline=""><track kind="captions"/></video>`,a(e,"class","flex flex-col gap-2")},m(n,i){m(n,e,i)},p:J,i:J,o:J,d(n){n&&h(e)}}}function Os(t,e,n){let{onMessage:i}=e;const o=window.constraints={audio:!0,video:!0};function l(f){const c=document.querySelector("video"),p=f.getVideoTracks();i("Got stream with constraints:",o),i(`Using video device: ${p[0].label}`),window.stream=f,c.srcObject=f}function u(f){if(f.name==="ConstraintNotSatisfiedError"){const c=o.video;i(`The resolution ${c.width.exact}x${c.height.exact} px is not supported by your device.`)}else f.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: ${f.name}`,f)}return ct(async()=>{try{const f=await navigator.mediaDevices.getUserMedia(o);l(f)}catch(f){u(f)}}),Ri(()=>{window.stream.getTracks().forEach(function(f){f.stop()})}),t.$$set=f=>{"onMessage"in f&&n(0,i=f.onMessage)},[i]}class As extends Se{constructor(e){super(),Le(this,e,Os,Ss,Me,{onMessage:0})}}function al(t,e,n){const i=t.slice();return i[32]=e[n],i}function cl(t,e,n){const i=t.slice();return i[35]=e[n],i}function fl(t){let e,n,i,o,l,u,f,c,p,d,k,_,y,g,b;function O(L,S){return L[3]?Ds:Es}let W=O(t),U=W(t);function R(L,S){return L[2]?Ws:zs}let q=R(t),E=q(t);return{c(){e=s("div"),n=s("span"),n.textContent="Tauri API Validation",i=v(),o=s("span"),l=s("span"),U.c(),f=v(),c=s("span"),c.innerHTML='<div class="i-codicon-chrome-minimize"></div>',p=v(),d=s("span"),E.c(),_=v(),y=s("span"),y.innerHTML='<div class="i-codicon-chrome-close"></div>',a(n,"class","lt-sm:pl-10 text-darkPrimaryText"),a(l,"title",u=t[3]?"Switch to Light mode":"Switch to Dark mode"),a(l,"class","hover:bg-hoverOverlay active:bg-hoverOverlayDarker dark:hover:bg-darkHoverOverlay dark:active:bg-darkHoverOverlayDarker"),a(c,"title","Minimize"),a(c,"class","hover:bg-hoverOverlay active:bg-hoverOverlayDarker dark:hover:bg-darkHoverOverlay dark:active:bg-darkHoverOverlayDarker"),a(d,"title",k=t[2]?"Restore":"Maximize"),a(d,"class","hover:bg-hoverOverlay active:bg-hoverOverlayDarker dark:hover:bg-darkHoverOverlay dark:active:bg-darkHoverOverlayDarker"),a(y,"title","Close"),a(y,"class","hover:bg-red-700 dark:hover:bg-red-700 hover:text-darkPrimaryText active:bg-red-700/90 dark:active:bg-red-700/90 active:text-darkPrimaryText "),a(o,"class","h-100% children:h-100% children:w-12 children:inline-flex children:items-center children:justify-center"),a(e,"class","w-screen select-none h-8 pl-2 flex justify-between items-center absolute text-primaryText dark:text-darkPrimaryText"),a(e,"data-tauri-drag-region","")},m(L,S){m(L,e,S),r(e,n),r(e,i),r(e,o),r(o,l),U.m(l,null),r(o,f),r(o,c),r(o,p),r(o,d),E.m(d,null),r(o,_),r(o,y),g||(b=[D(l,"click",t[12]),D(c,"click",t[9]),D(d,"click",t[10]),D(y,"click",t[11])],g=!0)},p(L,S){W!==(W=O(L))&&(U.d(1),U=W(L),U&&(U.c(),U.m(l,null))),S[0]&8&&u!==(u=L[3]?"Switch to Light mode":"Switch to Dark mode")&&a(l,"title",u),q!==(q=R(L))&&(E.d(1),E=q(L),E&&(E.c(),E.m(d,null))),S[0]&4&&k!==(k=L[2]?"Restore":"Maximize")&&a(d,"title",k)},d(L){L&&h(e),U.d(),E.d(),g=!1,pe(b)}}}function Es(t){let e;return{c(){e=s("div"),a(e,"class","i-ph-moon")},m(n,i){m(n,e,i)},d(n){n&&h(e)}}}function Ds(t){let e;return{c(){e=s("div"),a(e,"class","i-ph-sun")},m(n,i){m(n,e,i)},d(n){n&&h(e)}}}function zs(t){let e;return{c(){e=s("div"),a(e,"class","i-codicon-chrome-maximize")},m(n,i){m(n,e,i)},d(n){n&&h(e)}}}function Ws(t){let e;return{c(){e=s("div"),a(e,"class","i-codicon-chrome-restore")},m(n,i){m(n,e,i)},d(n){n&&h(e)}}}function Ps(t){let e;return{c(){e=s("span"),a(e,"class","i-codicon-menu animate-duration-300ms animate-fade-in")},m(n,i){m(n,e,i)},d(n){n&&h(e)}}}function Rs(t){let e;return{c(){e=s("span"),a(e,"class","i-codicon-close animate-duration-300ms animate-fade-in")},m(n,i){m(n,e,i)},d(n){n&&h(e)}}}function dl(t){let e,n,i,o,l,u,f,c,p;function d(y,g){return y[3]?Ns:Is}let k=d(t),_=k(t);return{c(){e=s("a"),_.c(),n=v(),i=s("br"),o=v(),l=s("div"),u=v(),f=s
|
|
|
|
`),n=s("div"),a(n,"class","i-ph-moon")},m(i,o){m(i,e,o),m(i,n,o)},d(i){i&&h(e),i&&h(n)}}}function Ns(t){let e,n;return{c(){e=z(`Switch to Light mode
|
|
|
|
`),n=s("div"),a(n,"class","i-ph-sun")},m(i,o){m(i,e,o),m(i,n,o)},d(i){i&&h(e),i&&h(n)}}}function js(t){let e,n,i,o,l,u=t[35].label+"",f,c,p,d;function k(){return t[20](t[35])}return{c(){e=s("a"),n=s("div"),o=v(),l=s("p"),f=z(u),a(n,"class",i=t[35].icon+" mr-2"),a(e,"href","##"),a(e,"class",c="nv "+(t[1]===t[35]?"nv_selected":""))},m(_,y){m(_,e,y),r(e,n),r(e,o),r(e,l),r(l,f),p||(d=D(e,"click",k),p=!0)},p(_,y){t=_,y[0]&2&&c!==(c="nv "+(t[1]===t[35]?"nv_selected":""))&&a(e,"class",c)},d(_){_&&h(e),p=!1,d()}}}function pl(t){let e,n=t[35]&&js(t);return{c(){n&&n.c(),e=ei()},m(i,o){n&&n.m(i,o),m(i,e,o)},p(i,o){i[35]&&n.p(i,o)},d(i){n&&n.d(i),i&&h(e)}}}function hl(t){let e,n=t[32].html+"",i;return{c(){e=new rr(!1),i=ei(),e.a=i},m(o,l){e.m(n,o,l),m(o,i,l)},p(o,l){l[0]&64&&n!==(n=o[32].html+"")&&e.p(n)},d(o){o&&h(i),o&&e.d()}}}function Hs(t){let e,n,i,o,l,u,f,c,p,d,k,_,y,g,b,O,W,U,R,q,E,L,S,P,C,F,B,Y=t[1].label+"",$,be,te,oe,K,ge,N,x,le,ae,ee,_e,re,ye,ne,Te,Ae,I,V=t[5]&&fl(t);function Ne(j,ie){return j[0]?Rs:Ps}let Ee=Ne(t),Ce=Ee(t),ce=!t[5]&&dl(t),he=t[7],fe=[];for(let j=0;j<he.length;j+=1)fe[j]=pl(cl(t,he,j));var De=t[1].component;function nt(j){return{props:{onMessage:j[14],insecureRenderHtml:j[15]}}}De&&(K=new De(nt(t)));let me=t[6],de=[];for(let j=0;j<me.length;j+=1)de[j]=hl(al(t,me,j));return{c(){V&&V.c(),e=v(),n=s("div"),Ce.c(),i=v(),o=s("div"),l=s("aside"),u=s("img"),c=v(),ce&&ce.c(),p=v(),d=s("a"),d.innerHTML=`Documentation
|
|
|
|
<span class="i-codicon-link-external"></span>`,k=v(),_=s("a"),_.innerHTML=`GitHub
|
2022-08-15 00:39:35 +03:00
|
|
|
<span class="i-codicon-link-external"></span>`,y=v(),g=s("a"),g.innerHTML=`Source
|
2022-09-15 17:28:52 +03:00
|
|
|
<span class="i-codicon-link-external"></span>`,b=v(),O=s("br"),W=v(),U=s("div"),R=v(),q=s("br"),E=v(),L=s("div");for(let j=0;j<fe.length;j+=1)fe[j].c();P=v(),C=s("main"),F=s("div"),B=s("h1"),$=z(Y),be=v(),te=s("div"),oe=s("div"),K&&xn(K.$$.fragment),ge=v(),N=s("div"),x=s("div"),le=v(),ae=s("div"),ee=s("p"),ee.textContent="Console",_e=v(),re=s("div"),re.innerHTML='<div class="i-codicon-clear-all"></div>',ye=v(),ne=s("div");for(let j=0;j<de.length;j+=1)de[j].c();a(n,"id","sidebarToggle"),a(n,"class","z-2000 display-none lt-sm:flex justify-center items-center absolute top-2 left-2 w-8 h-8 rd-8 bg-accent dark:bg-darkAccent active:bg-accentDark dark:active:bg-darkAccentDark"),a(u,"class","self-center p-7 cursor-pointer"),tr(u.src,f="tauri_logo.png")||a(u,"src",f),a(u,"alt","Tauri logo"),a(d,"class","nv justify-between h-8"),a(d,"target","_blank"),a(d,"href","https://tauri.app/v1/guides/"),a(_,"class","nv justify-between h-8"),a(_,"target","_blank"),a(_,"href","https://github.com/tauri-apps/tauri"),a(g,"class","nv justify-between h-8"),a(g,"target","_blank"),a(g,"href","https://github.com/tauri-apps/tauri/tree/dev/examples/api"),a(U,"class","bg-white/5 h-2px"),a(L,"class","flex flex-col overflow-y-auto children-h-10 children-flex-none gap-1"),a(l,"id","sidebar"),a(l,"class",S="lt-sm:h-screen lt-sm:shadow-lg lt-sm:shadow lt-sm:transition-transform lt-sm:absolute lt-sm:z-1999 "+(t[5]?"bg-darkPrimaryLighter/60 lt-sm:bg-darkPrimaryLighter":"bg-darkPrimaryLighter")+" transition-colors-250 overflow-hidden grid select-none px-2"),a(oe,"class","mr-2"),a(te,"class","overflow-y-auto"),a(F,"class","px-5 overflow-hidden grid grid-rows-[auto_1fr]"),a(x,"class","bg-black/20 h-2px cursor-ns-resize"),a(ee,"class","font-semibold"),a(re,"class","cursor-pointer h-85% rd-1 p-1 flex justify-center items-center hover:bg-hoverOverlay dark:hover:bg-darkHoverOverlay active:bg-hoverOverlay/25 dark:active:bg-darkHoverOverlay/25 "),a(ae,"class","flex justify-between items-center px-2"),a(ne,"class","px-2 overflow-y-auto all:font-mono code-block all:text-xs"),a(N,"id","console"),a(N,"class","select-none h-15rem grid grid-rows-[2px_2rem_1fr] gap-1 overflow-hidden"),a(C,"class","flex-1 bg-primary dark:bg-darkPrimary transition-transform transition-colors-250 grid grid-rows-[2fr_auto]"),a(o,"class","flex h-screen w-screen overflow-hidden children-pt8 children-pb-2 text-primaryText dark:text-darkPrimaryText")},m(j,ie){V&&V.m(j,ie),m(j,e,ie),m(j,n,ie),Ce.m(n,null),m(j,i,ie),m(j,o,ie),r(o,l),r(l,u),r(l,c),ce&&ce.m(l,null),r(l,p),r(l,d),r(l,k),r(l,_),r(l,y),r(l,g),r(l,b),r(l,O),r(l,W),r(l,U),r(l,R),r(l,q),r(l,E),r(l,L);for(let X=0;X<fe.length;X+=1)fe[X].m(L,null);r(o,P),r(o,C),r(C,F),r(F,B),r(B,$),r(F,be),r(F,te),r(te,oe),K&&Gt(K,oe,null),r(C,ge),r(C,N),r(N,x),r(N,le),r(N,ae),r(ae,ee),r(ae,_e),r(ae,re),r(N,ye),r(N,ne);for(let X=0;X<de.length;X+=1)de[X].m(ne,null);t[21](N),Te=!0,Ae||(I=[D(u,"click",t[19]),D(x,"mousedown",t[17]),D(re,"click",t[16])],Ae=!0)},p(j,ie){if(j[5]?V?V.p(j,ie):(V=fl(j),V.c(),V.m(e.parentNode,e)):V&&(V.d(1),V=null),Ee!==(Ee=Ne(j))&&(Ce.d(1),Ce=Ee(j),Ce&&(Ce.c(),Ce.m(n,null))),j[5]?ce&&(ce.d(1),ce=null):ce?ce.p(j,ie):(ce=dl(j),ce.c(),ce.m(l,p)),ie[0]&387){he=j[7];let X;for(X=0;X<he.length;X+=1){const we=cl(j,he,X);fe[X]?fe[X].p(we,ie):(fe[X]=pl(we),fe[X].c(),fe[X].m(L,null))}for(;X<fe.length;X+=1)fe[X].d(1);fe.length=he.length}if((!Te||ie[0]&32&&S!==(S="lt-sm:h-screen lt-sm:shadow-lg lt-sm:shadow lt-sm:transition-transform lt-sm:absolute lt-sm:z-1999 "+(j[5]?"bg-darkPrimaryLighter/60 lt-sm:bg-darkPrimaryLighter":"bg-darkPrimaryLighter")+" transition-colors-250 overflow-hidden grid select-none px-2"))&&a(l,"class",S),(!Te||ie[0]&2)&&Y!==(Y=j[1].label+"")&&Z($,Y),De!==(De=j[1].component)){if(K){ti();const X=K;He(X.$$.fragment,1,0,()=>{Jt(X,1)}),ni()}De?(K=new De(nt(j)),xn(K.$$.fragment),We(K.$$.fragment,1),Gt(K,oe,null)):K=null}if(ie[0]&64){me=j[6];let X;for(X=0;X<me.length;X+=1){const we=al(j,me,X);de[X]?de[X].p(we,ie):(de[X]=hl(we),de[X].c(),de[X].m(ne,null))}for(;X<de.length;X+=1)de[X].d(1);de.length=me.length}},i(j){Te||(K&&We(K.$$.
|