You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
2 lines
38 KiB
2 lines
38 KiB
2 months ago
|
/*! wmf.js (C) 2020-present SheetJS LLC -- https://sheetjs.com */
|
||
|
var WMF=function(e){var n={};function i(t){if(n[t])return n[t].exports;var r=n[t]={i:t,l:!1,exports:{}};return e[t].call(r.exports,r,r.exports,i),r.l=!0,r.exports}return i.m=e,i.c=n,i.d=function(t,r,e){i.o(t,r)||Object.defineProperty(t,r,{enumerable:!0,get:e})},i.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},i.t=function(r,t){if(1&t&&(r=i(r)),8&t)return r;if(4&t&&"object"==typeof r&&r&&r.__esModule)return r;var e=Object.create(null);if(i.r(e),Object.defineProperty(e,"default",{enumerable:!0,value:r}),2&t&&"string"!=typeof r)for(var n in r)i.d(e,n,function(t){return r[t]}.bind(null,n));return e},i.n=function(t){var r=t&&t.__esModule?function(){return t.default}:function(){return t};return i.d(r,"a",r),r},i.o=function(t,r){return Object.prototype.hasOwnProperty.call(t,r)},i.p="",i(i.s=2)}([function(t,U,r){"use strict";(function(u){Object.defineProperty(U,"__esModule",{value:!0});var t,c=!(void 0===u||"undefined"==typeof process||void 0===process.versions||!process.versions.node);if(U.has_buf=c,U.Buffer_from=t,void 0!==u){var r=!u.from;if(!r)try{u.from("foo","utf8")}catch(t){r=!0}U.Buffer_from=t=r?function(t,r){return r?new u(t,r):new u(t)}:u.from.bind(u),u.alloc||(u.alloc=function(t){return new u(t)}),u.allocUnsafe||(u.allocUnsafe=function(t){return new u(t)})}U.new_raw_buf=function(t){return c?u.alloc(t):new Array(t)},U.new_unsafe_buf=function(t){return c?u.allocUnsafe(t):new Array(t)},U._chr=function(t){return String.fromCharCode(t)},U.chr0=/\u0000/g,U.chr1=/[\u0001-\u0006]/g;var l,n,p=function(t,r){return t[r]},d=function(t,r){return 256*t[r+1]+t[r]},g=function(t,r){var e=256*t[r+1]+t[r];return e<32768?e:-1*(65535-e+1)},_=function(t,r){return t[r+3]*(1<<24)+(t[r+2]<<16)+(t[r+1]<<8)+t[r]},y=function(t,r){return t[r+3]<<24|t[r+2]<<16|t[r+1]<<8|t[r]},E=function(t,r){return t[r]<<24|t[r+1]<<16|t[r+2]<<8|t[r+3]},v=function(t,r,e){for(var n=[],i=r;i<e;i+=2)n.push(String.fromCharCode(d(t,i)));return n.join("").replace(U.chr0,"")},i=U.__utf16le=v,w=function(t,r,e){for(var n=[],i=r;i<r+e;++i)n.push(("0"+t[i].toString(16)).slice(-2));return n.join("")},o=w,b=function(t,r,e){for(var n=[],i=r;i<e;i++)n.push(String.fromCharCode(p(t,i)));return n.join("")},s=b,A=function(t,r){var e=_(t,r);return 0<e?b(t,r+4,r+4+e-1):""},a=A,T=function(t,r){var e=_(t,r);return 0<e?b(t,r+4,r+4+e-1):""},f=T,m=function(t,r){var e=2*_(t,r);return 0<e?b(t,r+4,r+4+e-1):""},h=m;l=n=function(t,r){var e=_(t,r);return 0<e?v(t,r+4,r+4+e):""};function S(t,r){var e=_(t,r);return 0<e?b(t,r+4,r+4+e):""}function e(t,r){return function(t,r){for(var e=1-2*(t[r+7]>>>7),n=((127&t[r+7])<<4)+(t[r+6]>>>4&15),i=15&t[r+6],o=5;0<=o;--o)i=256*i+t[r+o];return 2047==n?0==i?1/0*e:NaN:(0==n?n=-1022:(n-=1023,i+=Math.pow(2,52)),e*Math.pow(2,n-52)*i)}(t,r)}var R=S,P=e;function C(t,r){var e,n,i,o,s,a="",f=0,h=[];switch(r){case"dbcs":if(s=this.l,c&&u.isBuffer(this))a=this.slice(this.l,this.l+2*t).toString("utf16le");else for(o=0;o<t;++o)a+=String.fromCharCode(d(this,s)),s+=2;t*=2;break;case"utf8":a=b(this,this.l,this.l+t);break;case"utf16le":t*=2,a=v(this,this.l,this.l+t);break;case"wstr":return C.call(this,t,"dbcs");case"lpstr-ansi":a=A(this,this.l),t=4+_(this,this.l);break;case"lpstr-cp":a=T(this,this.l),t=4+_(this,this.l);break;case"lpwstr":a=m(this,this.l),t=4+2*_(this,this.l);break;case"lpp4":t=4+_(this,this.l),a=l(this,this.l),2&t&&(t+=2);break;case"8lpp4":t=4+_(this,this.l),a=R(this,this.l),3&t&&(t+=4-(3&t));break;case"cstr":for(t=0,a="";0!==(n=p(this,this.l+t++));)h.push(String.fromCharCode(n));a=h.join("");break;case"_wstr":for(t=0,a="";0!==(n=d(this,this.l+t));)h.push(String.fromCharCode(n)),t+=2;t+=2,a=h.join("");break;case"dbcs-cont":for(a="",s=this.l,o=0;o<t;++o){if(this.lens&&-1!==this.lens.indexOf(s))return n=p(this,s),this.l=s+1,i=C.call(this,t-o,n?"dbcs-cont":"sbcs-cont"),h.join("")+i;h.push(String.fromCharCode(d(this,s))),s+=2}a=h.join(""),t*=2;break;case"cpstr":case"sbcs-cont":for(a="",s=this.l,o=0;o!=t;++o){if(this.lens&&-1!==this.lens.index
|