xrfragment/dist/matrix-crdt.js

2 lines
8.9 MiB
JavaScript
Raw Normal View History

2023-12-27 18:26:21 +01:00
/*! For license information please see matrix-crdt.js.LICENSE.txt */
!function(A,g){"object"==typeof exports&&"object"==typeof module?module.exports=g():"function"==typeof define&&define.amd?define([],g):"object"==typeof exports?exports.matrix=g():A.matrix=g()}(self,(()=>(()=>{var A={7746:(A,g,I)=>{A=I.nmd(A);let Q,B={};B.__wbindgen_placeholder__=A.exports;let C=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0});C.decode();let E=null;function o(){return null!==E&&0!==E.byteLength||(E=new Uint8Array(Q.memory.buffer)),E}function n(A,g){return A>>>=0,C.decode(o().subarray(A,A+g))}const i=new Array(128).fill(void 0);i.push(void 0,null,!0,!1);let D=i.length;function a(A){D===i.length&&i.push(i.length+1);const g=D;return D=i[g],i[g]=A,g}function G(A){return i[A]}function c(A){const g=G(A);return function(A){A<132||(i[A]=D,D=A)}(A),g}function t(A){return null==A}let e=null;function s(){return null!==e&&0!==e.byteLength||(e=new Float64Array(Q.memory.buffer)),e}let N=null;function h(){return null!==N&&0!==N.byteLength||(N=new Int32Array(Q.memory.buffer)),N}let w=0,Y=new TextEncoder("utf-8");const y="function"==typeof Y.encodeInto?function(A,g){return Y.encodeInto(A,g)}:function(A,g){const I=Y.encode(A);return g.set(I),{read:A.length,written:I.length}};function M(A,g,I){if(void 0===I){const I=Y.encode(A),Q=g(I.length,1)>>>0;return o().subarray(Q,Q+I.length).set(I),w=I.length,Q}let Q=A.length,B=g(Q,1)>>>0;const C=o();let E=0;for(;E<Q;E++){const g=A.charCodeAt(E);if(g>127)break;C[B+E]=g}if(E!==Q){0!==E&&(A=A.slice(E)),B=I(B,Q,Q=E+3*A.length,1)>>>0;const g=o().subarray(B+E,B+Q);E+=y(A,g).written}return w=E,B}let k=null;function l(A){const g=typeof A;if("number"==g||"boolean"==g||null==A)return`${A}`;if("string"==g)return`"${A}"`;if("symbol"==g){const g=A.description;return null==g?"Symbol":`Symbol(${g})`}if("function"==g){const g=A.name;return"string"==typeof g&&g.length>0?`Function(${g})`:"Function"}if(Array.isArray(A)){const g=A.length;let I="[";g>0&&(I+=l(A[0]));for(let Q=1;Q<g;Q++)I+=", "+l(A[Q]);return I+="]",I}const I=/\[object ([^\]]+)\]/.exec(toString.call(A));let Q;if(!(I.length>1))return toString.call(A);if(Q=I[1],"Object"==Q)try{return"Object("+JSON.stringify(A)+")"}catch(A){return"Object"}return A instanceof Error?`${A.name}: ${A.message}\n${A.stack}`:Q}const R=new FinalizationRegistry((A=>{Q.__wbindgen_export_2.get(A.dtor)(A.a,A.b)}));function J(A,g,I,B){const C={a:A,b:g,cnt:1,dtor:I},E=(...A)=>{C.cnt++;const g=C.a;C.a=0;try{return B(g,C.b,...A)}finally{0==--C.cnt?(Q.__wbindgen_export_2.get(C.dtor)(g,C.b),R.unregister(C)):C.a=g}};return E.original=C,R.register(E,C,C),E}function F(A,g,I){try{const C=Q.__wbindgen_add_to_stack_pointer(-16);Q.wasm_bindgen__convert__closures__invoke1_mut__hbc098da5d2b7498e(C,A,g,a(I));var B=h()[C/4+0];if(h()[C/4+1])throw c(B)}finally{Q.__wbindgen_add_to_stack_pointer(16)}}function O(A,g,I,B){const C={a:A,b:g,cnt:1,dtor:I},E=(...A)=>{C.cnt++;try{return B(C.a,C.b,...A)}finally{0==--C.cnt&&(Q.__wbindgen_export_2.get(C.dtor)(C.a,C.b),C.a=0,R.unregister(C))}};return E.original=C,R.register(E,C,C),E}function Z(A,g){Q._dyn_core__ops__function__Fn_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hbff97dce5937efeb(A,g)}function m(A,g,I){Q._dyn_core__ops__function__Fn__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h6d3bd38ffc42664a(A,g,a(I))}function d(A,g,I){Q._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h8cef6383e8d1f614(A,g,a(I))}function U(A,g){Q._dyn_core__ops__function__FnMut_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hd4892df90e815ea9(A,g)}function j(A,g){if(!(A instanceof g))throw new Error(`expected instance of ${g.name}`);return A.ptr}let p=128;function r(A){if(1==p)throw new Error("out of js stack");return i[--p]=A,p}function b(A,g){const I=g(1*A.length,1)>>>0;return o().set(A,I/1),w=A.length,I}function L(A,g){return A>>>=0,o().subarray(A/1,A/1+g)}function S(A,g){try{return A.apply(this,g)}catch(A){Q.__wbindgen_exn_store(a(A))}}A.exports.getVersions=function(){const A=Q.getVersions();return Kg.__wrap(A)},A.exports.star