phirepass-widgets 0.0.56 → 0.0.57

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.
@@ -1 +0,0 @@
1
- class n{__destroy_into_raw(){const n=this.__wbg_ptr;return this.__wbg_ptr=0,_.unregister(this),n}free(){const n=this.__destroy_into_raw();P.__wbg_channel_free(n,0)}authenticate(n,t,e){const r=R(n,P.__wbindgen_export,P.__wbindgen_export2),o=N,c=R(t,P.__wbindgen_export,P.__wbindgen_export2);P.channel_authenticate(this.__wbg_ptr,r,o,c,N,S(e)?Number.MAX_SAFE_INTEGER:e>>>0)}connect(){P.channel_connect(this.__wbg_ptr)}disconnect(){P.channel_disconnect(this.__wbg_ptr)}is_connected(){return 0!==P.channel_is_connected(this.__wbg_ptr)}is_disconnected(){return 0!==P.channel_is_disconnected(this.__wbg_ptr)}constructor(n,t,e){const r=R(n,P.__wbindgen_export,P.__wbindgen_export2),o=N,c=R(t,P.__wbindgen_export,P.__wbindgen_export2),i=N;var s=S(e)?0:R(e,P.__wbindgen_export,P.__wbindgen_export2);const u=P.channel_new(r,o,c,i,s,N);return this.__wbg_ptr=u,_.register(this,this.__wbg_ptr,this),this}on_connection_close(n){P.channel_on_connection_close(this.__wbg_ptr,S(n)?0:u(n))}on_connection_error(n){P.channel_on_connection_error(this.__wbg_ptr,S(n)?0:u(n))}on_connection_message(n){P.channel_on_connection_message(this.__wbg_ptr,S(n)?0:u(n))}on_connection_open(n){P.channel_on_connection_open(this.__wbg_ptr,S(n)?0:u(n))}on_protocol_message(n){P.channel_on_protocol_message(this.__wbg_ptr,S(n)?0:u(n))}open_sftp_tunnel(n,t,e,r){const o=R(n,P.__wbindgen_export,P.__wbindgen_export2),c=N;var i=S(t)?0:R(t,P.__wbindgen_export,P.__wbindgen_export2),s=N,_=S(e)?0:R(e,P.__wbindgen_export,P.__wbindgen_export2);P.channel_open_sftp_tunnel(this.__wbg_ptr,o,c,i,s,_,N,S(r)?Number.MAX_SAFE_INTEGER:r>>>0)}open_ssh_tunnel(n,t,e,r){const o=R(n,P.__wbindgen_export,P.__wbindgen_export2),c=N;var i=S(t)?0:R(t,P.__wbindgen_export,P.__wbindgen_export2),s=N,_=S(e)?0:R(e,P.__wbindgen_export,P.__wbindgen_export2);P.channel_open_ssh_tunnel(this.__wbg_ptr,o,c,i,s,_,N,S(r)?Number.MAX_SAFE_INTEGER:r>>>0)}send_sftp_delete(n,t,e,r,o){const c=R(n,P.__wbindgen_export,P.__wbindgen_export2),i=N,s=R(e,P.__wbindgen_export,P.__wbindgen_export2),_=N,u=R(r,P.__wbindgen_export,P.__wbindgen_export2);P.channel_send_sftp_delete(this.__wbg_ptr,c,i,t,s,_,u,N,S(o)?Number.MAX_SAFE_INTEGER:o>>>0)}send_sftp_download_chunk(n,t,e,r,o){const c=R(n,P.__wbindgen_export,P.__wbindgen_export2);P.channel_send_sftp_download_chunk(this.__wbg_ptr,c,N,t,e,r,S(o)?Number.MAX_SAFE_INTEGER:o>>>0)}send_sftp_download_start(n,t,e,r,o){const c=R(n,P.__wbindgen_export,P.__wbindgen_export2),i=N,s=R(e,P.__wbindgen_export,P.__wbindgen_export2),_=N,u=R(r,P.__wbindgen_export,P.__wbindgen_export2);P.channel_send_sftp_download_start(this.__wbg_ptr,c,i,t,s,_,u,N,S(o)?Number.MAX_SAFE_INTEGER:o>>>0)}send_sftp_list_data(n,t,e,r){const o=R(n,P.__wbindgen_export,P.__wbindgen_export2),c=N,i=R(e,P.__wbindgen_export,P.__wbindgen_export2);P.channel_send_sftp_list_data(this.__wbg_ptr,o,c,t,i,N,S(r)?Number.MAX_SAFE_INTEGER:r>>>0)}send_sftp_upload_chunk(n,t,e,r,o,c,i){const s=R(n,P.__wbindgen_export,P.__wbindgen_export2),_=N,u=function(n){const t=(0,P.__wbindgen_export)(1*n.length,1)>>>0;return h().set(n,t/1),N=n.length,t}(c);P.channel_send_sftp_upload_chunk(this.__wbg_ptr,s,_,t,e,r,o,u,N,S(i)?Number.MAX_SAFE_INTEGER:i>>>0)}send_sftp_upload_start(n,t,e,r,o,c,i){const s=R(n,P.__wbindgen_export,P.__wbindgen_export2),_=N,u=R(e,P.__wbindgen_export,P.__wbindgen_export2),a=N,f=R(r,P.__wbindgen_export,P.__wbindgen_export2);P.channel_send_sftp_upload_start(this.__wbg_ptr,s,_,t,u,a,f,N,o,c,S(i)?Number.MAX_SAFE_INTEGER:i>>>0)}send_ssh_terminal_resize(n,t,e,r,o,c){const i=R(n,P.__wbindgen_export,P.__wbindgen_export2);P.channel_send_ssh_terminal_resize(this.__wbg_ptr,i,N,t,e,r,o,c)}send_ssh_tunnel_data(n,t,e){const r=R(n,P.__wbindgen_export,P.__wbindgen_export2),o=N,c=R(e,P.__wbindgen_export,P.__wbindgen_export2);P.channel_send_ssh_tunnel_data(this.__wbg_ptr,r,o,t,c,N)}start_heartbeat(n){P.channel_start_heartbeat(this.__wbg_ptr,n)}stop_heartbeat(){P.channel_stop_heartbeat(this.__wbg_ptr)}}Symbol.dispose&&(n.prototype[Symbol.dispose]=n.prototype.free);const t=Object.freeze({Generic:0,0:"Generic",Authentication:10,10:"Authentication",RequiresUsername:100,100:"RequiresUsername",RequiresPassword:110,110:"RequiresPassword",RequiresUsernamePassword:120,120:"RequiresUsernamePassword"});function e(){const n={__proto__:null,__wbg_Error_3639a60ed15f87e7:function(n,t){return u(Error(w(n,t)))},__wbg_String_8564e559799eccda:function(n,t){const e=R(String(p(t)),P.__wbindgen_export,P.__wbindgen_export2),r=N;d().setInt32(n+4,r,!0),d().setInt32(n+0,e,!0)},__wbg___wbindgen_debug_string_07cb72cfcc952e2b:function(n,t){const e=R(f(p(t)),P.__wbindgen_export,P.__wbindgen_export2),r=N;d().setInt32(n+4,r,!0),d().setInt32(n+0,e,!0)},__wbg___wbindgen_string_get_965592073e5d848c:function(n,t){const e=p(t),r="string"==typeof e?e:void 0;var o=S(r)?0:R(r,P.__wbindgen_export,P.__wbindgen_export2),c=N;d().setInt32(n+4,c,!0),d().setInt32(n+0,o,!0)},__wbg___wbindgen_throw_9c75d47bf9e7731e:function(n,t){throw new Error(w(n,t))},__wbg__wbg_cb_unref_158e43e869788cdc:function(n){p(n)._wbg_cb_unref()},__wbg_call_a41d6421b30a32c5:function(){return y((function(n,t,e){return u(p(n).call(p(t),p(e)))}),arguments)},__wbg_call_add9e5a76382e668:function(){return y((function(n,t){return u(p(n).call(p(t)))}),arguments)},__wbg_clearInterval_26ba580547547579:function(n){return u(clearInterval(T(n)))},__wbg_close_931d0c62e2aab92c:function(){return y((function(n){p(n).close()}),arguments)},__wbg_data_4a14fad4c5f216c4:function(n){return u(p(n).data)},__wbg_from_ff141b1e4c69b979:function(n){return u(Array.from(p(n)))},__wbg_info_b32d86aa057de44b:function(n,t){console.info(w(n,t))},__wbg_instanceof_ArrayBuffer_eab9f28fbec23477:function(n){let t;try{t=p(n)instanceof ArrayBuffer}catch(n){t=!1}return t},__wbg_length_ba3c032602efe310:function(n){return p(n).length},__wbg_new_2fad8ca02fd00684:function(){return u(new Object)},__wbg_new_3baa8d9866155c79:function(){return u(new Array)},__wbg_new_8454eee672b2ba6e:function(n){return u(new Uint8Array(p(n)))},__wbg_new_with_str_sequence_d90cb07368a00c61:function(){return y((function(n,t,e){return u(new WebSocket(w(n,t),p(e)))}),arguments)},__wbg_prototypesetcall_fd4050e806e1d519:function(n,t,e){Uint8Array.prototype.set.call(b(n,t),p(e))},__wbg_push_60a5366c0bb22a7d:function(n,t){return p(n).push(p(t))},__wbg_readyState_be3cc9403da6c6ae:function(n){return p(n).readyState},__wbg_send_c422d0aa0cb71d09:function(){return y((function(n,t,e){p(n).send(b(t,e))}),arguments)},__wbg_setInterval_cbf1c35c6a692d37:function(){return y((function(n,t){return u(setInterval(p(n),t))}),arguments)},__wbg_set_6be42768c690e380:function(n,t,e){p(n)[T(t)]=T(e)},__wbg_set_binaryType_8564bdba0fbec720:function(n,t){p(n).binaryType=s[t]},__wbg_set_f614f6a0608d1d1d:function(n,t,e){p(n)[t>>>0]=T(e)},__wbg_set_onclose_f756840519cd20b5:function(n,t){p(n).onclose=p(t)},__wbg_set_onerror_02f33de339f1fa31:function(n,t){p(n).onerror=p(t)},__wbg_set_onmessage_d2ff0c1d20584625:function(n,t){p(n).onmessage=p(t)},__wbg_set_onopen_1da8a4f65e6180d2:function(n,t){p(n).onopen=p(t)},__wbg_warn_a5241bed60363932:function(n,t){console.warn(w(n,t))},__wbindgen_cast_0000000000000001:function(n,t){return u(v(n,t,o))},__wbindgen_cast_0000000000000002:function(n,t){return u(v(n,t,c))},__wbindgen_cast_0000000000000003:function(n,t){return u(v(n,t,i))},__wbindgen_cast_0000000000000004:function(n,t){return u(v(n,t,r))},__wbindgen_cast_0000000000000005:function(n){return u(n)},__wbindgen_cast_0000000000000006:function(n,t){return u(b(n,t))},__wbindgen_cast_0000000000000007:function(n,t){return u(w(n,t))},__wbindgen_cast_0000000000000008:function(n){return u(BigInt.asUintN(64,n))},__wbindgen_object_clone_ref:function(n){return u(p(n))},__wbindgen_object_drop_ref:function(n){T(n)}};return{__proto__:null,"./phirepass-channel_bg.js":n}}function r(n,t){P.__wasm_bindgen_func_elem_40(n,t)}function o(n,t,e){P.__wasm_bindgen_func_elem_42(n,t,u(e))}function c(n,t,e){P.__wasm_bindgen_func_elem_42_1(n,t,u(e))}function i(n,t,e){P.__wasm_bindgen_func_elem_42_2(n,t,u(e))}const s=["blob","arraybuffer"],_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((n=>P.__wbg_channel_free(n,1)));function u(n){A===m.length&&m.push(m.length+1);const t=A;return A=m[t],m[t]=n,t}const a="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((n=>P.__wbindgen_export4(n.a,n.b)));function f(n){const t=typeof n;if("number"==t||"boolean"==t||null==n)return`${n}`;if("string"==t)return`"${n}"`;if("symbol"==t){const t=n.description;return null==t?"Symbol":`Symbol(${t})`}if("function"==t){const t=n.name;return"string"==typeof t&&t.length>0?`Function(${t})`:"Function"}if(Array.isArray(n)){const t=n.length;let e="[";t>0&&(e+=f(n[0]));for(let r=1;r<t;r++)e+=", "+f(n[r]);return e+="]",e}const e=/\[object ([^\]]+)\]/.exec(toString.call(n));let r;if(!(e&&e.length>1))return toString.call(n);if(r=e[1],"Object"==r)try{return"Object("+JSON.stringify(n)+")"}catch(n){return"Object"}return n instanceof Error?`${n.name}: ${n.message}\n${n.stack}`:r}function b(n,t){return n>>>=0,h().subarray(n/1,n/1+t)}let l=null;function d(){return(null===l||!0===l.buffer.detached||void 0===l.buffer.detached&&l.buffer!==P.memory.buffer)&&(l=new DataView(P.memory.buffer)),l}function w(n,t){return function(n,t){return F+=t,F>=j&&(U=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}),U.decode(),F=t),U.decode(h().subarray(n,n+t))}(n>>>0,t)}let g=null;function h(){return null!==g&&0!==g.byteLength||(g=new Uint8Array(P.memory.buffer)),g}function p(n){return m[n]}function y(n,t){try{return n.apply(this,t)}catch(n){P.__wbindgen_export3(u(n))}}let m=new Array(1024).fill(void 0);m.push(void 0,null,!0,!1);let A=m.length;function S(n){return null==n}function v(n,t,e){const r={a:n,b:t,cnt:1},o=(...n)=>{r.cnt++;const t=r.a;r.a=0;try{return e(t,r.b,...n)}finally{r.a=t,o._wbg_cb_unref()}};return o._wbg_cb_unref=()=>{0==--r.cnt&&(P.__wbindgen_export4(r.a,r.b),r.a=0,a.unregister(r))},a.register(o,r,r),o}function R(n,t,e){if(void 0===e){const e=O.encode(n),r=t(e.length,1)>>>0;return h().subarray(r,r+e.length).set(e),N=e.length,r}let r=n.length,o=t(r,1)>>>0;const c=h();let i=0;for(;i<r;i++){const t=n.charCodeAt(i);if(t>127)break;c[o+i]=t}if(i!==r){0!==i&&(n=n.slice(i)),o=e(o,r,r=i+3*n.length,1)>>>0;const t=h().subarray(o+i,o+r);i+=O.encodeInto(n,t).written,o=e(o,r,i,1)>>>0}return N=i,o}function T(n){const t=p(n);return function(n){n<1028||(m[n]=A,A=n)}(n),t}let U=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0});U.decode();const j=2146435072;let F=0;const O=new TextEncoder;"encodeInto"in O||(O.encodeInto=function(n,t){const e=O.encode(n);return t.set(e),{read:n.length,written:e.length}});let P,N=0;async function q(n){if(void 0!==P)return P;void 0!==n&&(Object.getPrototypeOf(n)===Object.prototype?({module_or_path:n}=n):console.warn("using deprecated parameters for the initialization function; pass a single object instead")),void 0===n&&(n=new URL("phirepass-channel_bg.wasm",import.meta.url));const t=e();("string"==typeof n||"function"==typeof Request&&n instanceof Request||"function"==typeof URL&&n instanceof URL)&&(n=fetch(n));const{instance:r}=await async function(n,t){if("function"==typeof Response&&n instanceof Response){if("function"==typeof WebAssembly.instantiateStreaming)try{return await WebAssembly.instantiateStreaming(n,t)}catch(t){if(!n.ok||!function(n){switch(n){case"basic":case"cors":case"default":return!0}return!1}(n.type)||"application/wasm"===n.headers.get("Content-Type"))throw t;console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve Wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",t)}const e=await n.arrayBuffer();return await WebAssembly.instantiate(e,t)}{const e=await WebAssembly.instantiate(n,t);return e instanceof WebAssembly.Instance?{instance:e,module:n}:e}}(await n,t);return function(n){return P=n.exports,l=null,g=null,P}(r)}var I,W,k;!function(n){n.Error="Error",n.AuthSuccess="AuthSuccess",n.TunnelOpened="TunnelOpened",n.TunnelClosed="TunnelClosed",n.TunnelData="TunnelData",n.SFTPListItems="SFTPListItems",n.SFTPDownloadStartResponse="SFTPDownloadStartResponse",n.SFTPDownloadChunk="SFTPDownloadChunk",n.SFTPUploadStartResponse="SFTPUploadStartResponse",n.SFTPUploadChunkAck="SFTPUploadChunkAck"}(I||(I={})),function(n){n[n.Username=0]="Username",n[n.Password=1]="Password",n[n.Default=2]="Default"}(W||(W={})),function(n){n.Disconnected="disconnected",n.Connected="connected",n.Error="error"}(k||(k={}));export{n as C,t as E,W as I,I as P,q as _,k as a}
@@ -1 +0,0 @@
1
- class n{__destroy_into_raw(){const n=this.__wbg_ptr;return this.__wbg_ptr=0,_.unregister(this),n}free(){const n=this.__destroy_into_raw();P.__wbg_channel_free(n,0)}authenticate(n,t,e){const r=R(n,P.__wbindgen_export,P.__wbindgen_export2),o=N,c=R(t,P.__wbindgen_export,P.__wbindgen_export2);P.channel_authenticate(this.__wbg_ptr,r,o,c,N,S(e)?Number.MAX_SAFE_INTEGER:e>>>0)}connect(){P.channel_connect(this.__wbg_ptr)}disconnect(){P.channel_disconnect(this.__wbg_ptr)}is_connected(){return 0!==P.channel_is_connected(this.__wbg_ptr)}is_disconnected(){return 0!==P.channel_is_disconnected(this.__wbg_ptr)}constructor(n,t,e){const r=R(n,P.__wbindgen_export,P.__wbindgen_export2),o=N,c=R(t,P.__wbindgen_export,P.__wbindgen_export2),i=N;var s=S(e)?0:R(e,P.__wbindgen_export,P.__wbindgen_export2);const u=P.channel_new(r,o,c,i,s,N);return this.__wbg_ptr=u,_.register(this,this.__wbg_ptr,this),this}on_connection_close(n){P.channel_on_connection_close(this.__wbg_ptr,S(n)?0:u(n))}on_connection_error(n){P.channel_on_connection_error(this.__wbg_ptr,S(n)?0:u(n))}on_connection_message(n){P.channel_on_connection_message(this.__wbg_ptr,S(n)?0:u(n))}on_connection_open(n){P.channel_on_connection_open(this.__wbg_ptr,S(n)?0:u(n))}on_protocol_message(n){P.channel_on_protocol_message(this.__wbg_ptr,S(n)?0:u(n))}open_sftp_tunnel(n,t,e,r){const o=R(n,P.__wbindgen_export,P.__wbindgen_export2),c=N;var i=S(t)?0:R(t,P.__wbindgen_export,P.__wbindgen_export2),s=N,_=S(e)?0:R(e,P.__wbindgen_export,P.__wbindgen_export2);P.channel_open_sftp_tunnel(this.__wbg_ptr,o,c,i,s,_,N,S(r)?Number.MAX_SAFE_INTEGER:r>>>0)}open_ssh_tunnel(n,t,e,r){const o=R(n,P.__wbindgen_export,P.__wbindgen_export2),c=N;var i=S(t)?0:R(t,P.__wbindgen_export,P.__wbindgen_export2),s=N,_=S(e)?0:R(e,P.__wbindgen_export,P.__wbindgen_export2);P.channel_open_ssh_tunnel(this.__wbg_ptr,o,c,i,s,_,N,S(r)?Number.MAX_SAFE_INTEGER:r>>>0)}send_sftp_delete(n,t,e,r,o){const c=R(n,P.__wbindgen_export,P.__wbindgen_export2),i=N,s=R(e,P.__wbindgen_export,P.__wbindgen_export2),_=N,u=R(r,P.__wbindgen_export,P.__wbindgen_export2);P.channel_send_sftp_delete(this.__wbg_ptr,c,i,t,s,_,u,N,S(o)?Number.MAX_SAFE_INTEGER:o>>>0)}send_sftp_download_chunk(n,t,e,r,o){const c=R(n,P.__wbindgen_export,P.__wbindgen_export2);P.channel_send_sftp_download_chunk(this.__wbg_ptr,c,N,t,e,r,S(o)?Number.MAX_SAFE_INTEGER:o>>>0)}send_sftp_download_start(n,t,e,r,o){const c=R(n,P.__wbindgen_export,P.__wbindgen_export2),i=N,s=R(e,P.__wbindgen_export,P.__wbindgen_export2),_=N,u=R(r,P.__wbindgen_export,P.__wbindgen_export2);P.channel_send_sftp_download_start(this.__wbg_ptr,c,i,t,s,_,u,N,S(o)?Number.MAX_SAFE_INTEGER:o>>>0)}send_sftp_list_data(n,t,e,r){const o=R(n,P.__wbindgen_export,P.__wbindgen_export2),c=N,i=R(e,P.__wbindgen_export,P.__wbindgen_export2);P.channel_send_sftp_list_data(this.__wbg_ptr,o,c,t,i,N,S(r)?Number.MAX_SAFE_INTEGER:r>>>0)}send_sftp_upload_chunk(n,t,e,r,o,c,i){const s=R(n,P.__wbindgen_export,P.__wbindgen_export2),_=N,u=function(n){const t=(0,P.__wbindgen_export)(1*n.length,1)>>>0;return h().set(n,t/1),N=n.length,t}(c);P.channel_send_sftp_upload_chunk(this.__wbg_ptr,s,_,t,e,r,o,u,N,S(i)?Number.MAX_SAFE_INTEGER:i>>>0)}send_sftp_upload_start(n,t,e,r,o,c,i){const s=R(n,P.__wbindgen_export,P.__wbindgen_export2),_=N,u=R(e,P.__wbindgen_export,P.__wbindgen_export2),a=N,f=R(r,P.__wbindgen_export,P.__wbindgen_export2);P.channel_send_sftp_upload_start(this.__wbg_ptr,s,_,t,u,a,f,N,o,c,S(i)?Number.MAX_SAFE_INTEGER:i>>>0)}send_ssh_terminal_resize(n,t,e,r,o,c){const i=R(n,P.__wbindgen_export,P.__wbindgen_export2);P.channel_send_ssh_terminal_resize(this.__wbg_ptr,i,N,t,e,r,o,c)}send_ssh_tunnel_data(n,t,e){const r=R(n,P.__wbindgen_export,P.__wbindgen_export2),o=N,c=R(e,P.__wbindgen_export,P.__wbindgen_export2);P.channel_send_ssh_tunnel_data(this.__wbg_ptr,r,o,t,c,N)}start_heartbeat(n){P.channel_start_heartbeat(this.__wbg_ptr,n)}stop_heartbeat(){P.channel_stop_heartbeat(this.__wbg_ptr)}}Symbol.dispose&&(n.prototype[Symbol.dispose]=n.prototype.free);const t=Object.freeze({Generic:0,0:"Generic",Authentication:10,10:"Authentication",RequiresUsername:100,100:"RequiresUsername",RequiresPassword:110,110:"RequiresPassword",RequiresUsernamePassword:120,120:"RequiresUsernamePassword"});function e(){const n={__proto__:null,__wbg_Error_3639a60ed15f87e7:function(n,t){return u(Error(w(n,t)))},__wbg_String_8564e559799eccda:function(n,t){const e=R(String(p(t)),P.__wbindgen_export,P.__wbindgen_export2),r=N;d().setInt32(n+4,r,!0),d().setInt32(n+0,e,!0)},__wbg___wbindgen_debug_string_07cb72cfcc952e2b:function(n,t){const e=R(f(p(t)),P.__wbindgen_export,P.__wbindgen_export2),r=N;d().setInt32(n+4,r,!0),d().setInt32(n+0,e,!0)},__wbg___wbindgen_string_get_965592073e5d848c:function(n,t){const e=p(t),r="string"==typeof e?e:void 0;var o=S(r)?0:R(r,P.__wbindgen_export,P.__wbindgen_export2),c=N;d().setInt32(n+4,c,!0),d().setInt32(n+0,o,!0)},__wbg___wbindgen_throw_9c75d47bf9e7731e:function(n,t){throw new Error(w(n,t))},__wbg__wbg_cb_unref_158e43e869788cdc:function(n){p(n)._wbg_cb_unref()},__wbg_call_a41d6421b30a32c5:function(){return y((function(n,t,e){return u(p(n).call(p(t),p(e)))}),arguments)},__wbg_call_add9e5a76382e668:function(){return y((function(n,t){return u(p(n).call(p(t)))}),arguments)},__wbg_clearInterval_26ba580547547579:function(n){return u(clearInterval(T(n)))},__wbg_close_931d0c62e2aab92c:function(){return y((function(n){p(n).close()}),arguments)},__wbg_data_4a14fad4c5f216c4:function(n){return u(p(n).data)},__wbg_from_ff141b1e4c69b979:function(n){return u(Array.from(p(n)))},__wbg_info_b32d86aa057de44b:function(n,t){console.info(w(n,t))},__wbg_instanceof_ArrayBuffer_eab9f28fbec23477:function(n){let t;try{t=p(n)instanceof ArrayBuffer}catch(n){t=!1}return t},__wbg_length_ba3c032602efe310:function(n){return p(n).length},__wbg_new_2fad8ca02fd00684:function(){return u(new Object)},__wbg_new_3baa8d9866155c79:function(){return u(new Array)},__wbg_new_8454eee672b2ba6e:function(n){return u(new Uint8Array(p(n)))},__wbg_new_with_str_sequence_d90cb07368a00c61:function(){return y((function(n,t,e){return u(new WebSocket(w(n,t),p(e)))}),arguments)},__wbg_prototypesetcall_fd4050e806e1d519:function(n,t,e){Uint8Array.prototype.set.call(b(n,t),p(e))},__wbg_push_60a5366c0bb22a7d:function(n,t){return p(n).push(p(t))},__wbg_readyState_be3cc9403da6c6ae:function(n){return p(n).readyState},__wbg_send_c422d0aa0cb71d09:function(){return y((function(n,t,e){p(n).send(b(t,e))}),arguments)},__wbg_setInterval_cbf1c35c6a692d37:function(){return y((function(n,t){return u(setInterval(p(n),t))}),arguments)},__wbg_set_6be42768c690e380:function(n,t,e){p(n)[T(t)]=T(e)},__wbg_set_binaryType_8564bdba0fbec720:function(n,t){p(n).binaryType=s[t]},__wbg_set_f614f6a0608d1d1d:function(n,t,e){p(n)[t>>>0]=T(e)},__wbg_set_onclose_f756840519cd20b5:function(n,t){p(n).onclose=p(t)},__wbg_set_onerror_02f33de339f1fa31:function(n,t){p(n).onerror=p(t)},__wbg_set_onmessage_d2ff0c1d20584625:function(n,t){p(n).onmessage=p(t)},__wbg_set_onopen_1da8a4f65e6180d2:function(n,t){p(n).onopen=p(t)},__wbg_warn_a5241bed60363932:function(n,t){console.warn(w(n,t))},__wbindgen_cast_0000000000000001:function(n,t){return u(v(n,t,o))},__wbindgen_cast_0000000000000002:function(n,t){return u(v(n,t,c))},__wbindgen_cast_0000000000000003:function(n,t){return u(v(n,t,i))},__wbindgen_cast_0000000000000004:function(n,t){return u(v(n,t,r))},__wbindgen_cast_0000000000000005:function(n){return u(n)},__wbindgen_cast_0000000000000006:function(n,t){return u(b(n,t))},__wbindgen_cast_0000000000000007:function(n,t){return u(w(n,t))},__wbindgen_cast_0000000000000008:function(n){return u(BigInt.asUintN(64,n))},__wbindgen_object_clone_ref:function(n){return u(p(n))},__wbindgen_object_drop_ref:function(n){T(n)}};return{__proto__:null,"./phirepass-channel_bg.js":n}}function r(n,t){P.__wasm_bindgen_func_elem_40(n,t)}function o(n,t,e){P.__wasm_bindgen_func_elem_42(n,t,u(e))}function c(n,t,e){P.__wasm_bindgen_func_elem_42_1(n,t,u(e))}function i(n,t,e){P.__wasm_bindgen_func_elem_42_2(n,t,u(e))}const s=["blob","arraybuffer"],_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((n=>P.__wbg_channel_free(n,1)));function u(n){A===m.length&&m.push(m.length+1);const t=A;return A=m[t],m[t]=n,t}const a="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((n=>P.__wbindgen_export4(n.a,n.b)));function f(n){const t=typeof n;if("number"==t||"boolean"==t||null==n)return`${n}`;if("string"==t)return`"${n}"`;if("symbol"==t){const t=n.description;return null==t?"Symbol":`Symbol(${t})`}if("function"==t){const t=n.name;return"string"==typeof t&&t.length>0?`Function(${t})`:"Function"}if(Array.isArray(n)){const t=n.length;let e="[";t>0&&(e+=f(n[0]));for(let r=1;r<t;r++)e+=", "+f(n[r]);return e+="]",e}const e=/\[object ([^\]]+)\]/.exec(toString.call(n));let r;if(!(e&&e.length>1))return toString.call(n);if(r=e[1],"Object"==r)try{return"Object("+JSON.stringify(n)+")"}catch(n){return"Object"}return n instanceof Error?`${n.name}: ${n.message}\n${n.stack}`:r}function b(n,t){return n>>>=0,h().subarray(n/1,n/1+t)}let l=null;function d(){return(null===l||!0===l.buffer.detached||void 0===l.buffer.detached&&l.buffer!==P.memory.buffer)&&(l=new DataView(P.memory.buffer)),l}function w(n,t){return function(n,t){return F+=t,F>=j&&(U=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}),U.decode(),F=t),U.decode(h().subarray(n,n+t))}(n>>>0,t)}let g=null;function h(){return null!==g&&0!==g.byteLength||(g=new Uint8Array(P.memory.buffer)),g}function p(n){return m[n]}function y(n,t){try{return n.apply(this,t)}catch(n){P.__wbindgen_export3(u(n))}}let m=new Array(1024).fill(void 0);m.push(void 0,null,!0,!1);let A=m.length;function S(n){return null==n}function v(n,t,e){const r={a:n,b:t,cnt:1},o=(...n)=>{r.cnt++;const t=r.a;r.a=0;try{return e(t,r.b,...n)}finally{r.a=t,o._wbg_cb_unref()}};return o._wbg_cb_unref=()=>{0==--r.cnt&&(P.__wbindgen_export4(r.a,r.b),r.a=0,a.unregister(r))},a.register(o,r,r),o}function R(n,t,e){if(void 0===e){const e=O.encode(n),r=t(e.length,1)>>>0;return h().subarray(r,r+e.length).set(e),N=e.length,r}let r=n.length,o=t(r,1)>>>0;const c=h();let i=0;for(;i<r;i++){const t=n.charCodeAt(i);if(t>127)break;c[o+i]=t}if(i!==r){0!==i&&(n=n.slice(i)),o=e(o,r,r=i+3*n.length,1)>>>0;const t=h().subarray(o+i,o+r);i+=O.encodeInto(n,t).written,o=e(o,r,i,1)>>>0}return N=i,o}function T(n){const t=p(n);return function(n){n<1028||(m[n]=A,A=n)}(n),t}let U=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0});U.decode();const j=2146435072;let F=0;const O=new TextEncoder;"encodeInto"in O||(O.encodeInto=function(n,t){const e=O.encode(n);return t.set(e),{read:n.length,written:e.length}});let P,N=0;async function q(n){if(void 0!==P)return P;void 0!==n&&(Object.getPrototypeOf(n)===Object.prototype?({module_or_path:n}=n):console.warn("using deprecated parameters for the initialization function; pass a single object instead")),void 0===n&&(n=new URL("phirepass-channel_bg.wasm",import.meta.url));const t=e();("string"==typeof n||"function"==typeof Request&&n instanceof Request||"function"==typeof URL&&n instanceof URL)&&(n=fetch(n));const{instance:r}=await async function(n,t){if("function"==typeof Response&&n instanceof Response){if("function"==typeof WebAssembly.instantiateStreaming)try{return await WebAssembly.instantiateStreaming(n,t)}catch(t){if(!n.ok||!function(n){switch(n){case"basic":case"cors":case"default":return!0}return!1}(n.type)||"application/wasm"===n.headers.get("Content-Type"))throw t;console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve Wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",t)}const e=await n.arrayBuffer();return await WebAssembly.instantiate(e,t)}{const e=await WebAssembly.instantiate(n,t);return e instanceof WebAssembly.Instance?{instance:e,module:n}:e}}(await n,t);return function(n){return P=n.exports,l=null,g=null,P}(r)}var I,W,k;!function(n){n.Error="Error",n.AuthSuccess="AuthSuccess",n.TunnelOpened="TunnelOpened",n.TunnelClosed="TunnelClosed",n.TunnelData="TunnelData",n.SFTPListItems="SFTPListItems",n.SFTPDownloadStartResponse="SFTPDownloadStartResponse",n.SFTPDownloadChunk="SFTPDownloadChunk",n.SFTPUploadStartResponse="SFTPUploadStartResponse",n.SFTPUploadChunkAck="SFTPUploadChunkAck"}(I||(I={})),function(n){n[n.Username=0]="Username",n[n.Password=1]="Password",n[n.Default=2]="Default"}(W||(W={})),function(n){n.Disconnected="disconnected",n.Connected="connected",n.Error="error"}(k||(k={}));export{n as C,t as E,W as I,I as P,q as _,k as a}