moreShopAdmin/dist/admin/assets/canvg.90844e8b.js

4 lines
120 KiB
JavaScript
Raw Normal View History

2024-11-08 17:23:40 +08:00
import{r as Ia,a as Da,b as za,c as Fa,d as La,e as qa,f as Xa,g as Ga,h as Ya,i as ja,j as Ua,k as Ha,l as Wa,m as Qa,n as Za,o as Ja,p as Ka,q as ei,s as ti,t as ri,u as ni,v as ai,w as ii,x as ui,y as si,z as li,A as oi,B as fi,C as ci,D as hi,E as vi,F as gi,G as di,H as pi}from"./core-js.02a9a8e7.js";import{r as yi,b as mi,c as Si,d as bi,e as _i,f as ki,h as Pi,i as Ri,j as Ci,k as wi,l as xi,m as Ei}from"./@babel.80d29b7b.js";import{r as Ai}from"./raf.4a8e4708.js";import{r as Ti}from"./rgbcolor.20c71161.js";import{r as Mi}from"./svg-pathdata.200d31ca.js";import{r as Bi}from"./stackblur-canvas.7cb77c32.js";function Ni(y,pe){for(var oe=0;oe<pe.length;oe++){const K=pe[oe];if(typeof K!="string"&&!Array.isArray(K)){for(const ee in K)if(ee!=="default"&&!(ee in y)){const fe=Object.getOwnPropertyDescriptor(K,ee);fe&&Object.defineProperty(y,ee,fe.get?fe:{enumerable:!0,get:()=>K[ee]})}}}return Object.freeze(Object.defineProperty(y,Symbol.toStringTag,{value:"Module"}))}var Ze={},ar;function Oi(){return ar||(ar=1,function(y){Object.defineProperty(y,"__esModule",{value:!0}),Ia(),Da(),za();var pe=yi(),oe=mi();Fa(),La(),qa(),Xa(),Ga(),Ya(),ja();var K=Si(),ee=bi(),fe=_i(),ur=ki();Ua(),Ha(),Wa(),Qa(),Za();var sr=Ai();Ja(),Ka();var lr=Ti();ei(),ti();var or=Pi(),fr=Ri(),cr=Ci();ri(),ni(),ai(),ii(),ui(),si();var hr=wi();li(),oi();var vr=xi();fi();var ce=Mi();ci();var gr=Ei();hi(),vi(),gi(),di(),pi();var dr=Bi;function L(u){return u&&typeof u=="object"&&"default"in u?u:{default:u}}var $=L(pe),W=L(oe),M=L(K),we=L(ee),b=L(fe),P=L(ur),xe=L(sr),Ee=L(lr),x=L(or),C=L(fr),d=L(cr),pr=L(hr),te=L(vr),he=L(gr);function yr(){var u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},l=u.DOMParser,t={window:null,ignoreAnimation:!0,ignoreMouse:!0,DOMParser:l,createCanvas:function(e,a){return new OffscreenCanvas(e,a)},createImage:function(e){return W.default($.default.mark(function a(){var n,i,s;return $.default.wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return f.next=2,fetch(e);case 2:return n=f.sent,f.next=5,n.blob();case 5:return i=f.sent,f.next=8,createImageBitmap(i);case 8:return s=f.sent,f.abrupt("return",s);case 10:case"end":return f.stop()}},a)}))()}};return(typeof DOMParser<"u"||typeof l>"u")&&Reflect.deleteProperty(t,"DOMParser"),t}function mr(u){var l=u.DOMParser,t=u.canvas,r=u.fetch;return{window:null,ignoreAnimation:!0,ignoreMouse:!0,DOMParser:l,fetch:r,createCanvas:t.createCanvas,createImage:t.loadImage}}var Sr=Object.freeze({__proto__:null,offscreen:yr,node:mr});function re(u){return u.replace(/(?!\u3000)\s+/gm," ")}function Je(u){return u.replace(/^[\n \t]+/,"")}function Ke(u){return u.replace(/[\n \t]+$/,"")}function q(u){var l=(u||"").match(/-?(\d+(?:\.\d*(?:[eE][+-]?\d+)?)?|\.\d+)(?=\D|$)/gm)||[];return l.map(parseFloat)}var br=/^[A-Z-]+$/;function et(u){return br.test(u)?u.toLowerCase():u}function Ae(u){var l=/url\(('([^']+)'|"([^"]+)"|([^'")]+))\)/.exec(u)||[];return l[2]||l[3]||l[4]}function tt(u){if(!u.startsWith("rgb"))return u;var l=3,t=u.replace(/\d+(\.\d+)?/g,function(r,e){return l--&&e?String(Math.round(parseFloat(r))):r});return t}var _r=/(\[[^\]]+\])/g,kr=/(#[^\s+>~.[:]+)/g,Pr=/(\.[^\s+>~.[:]+)/g,Rr=/(::[^\s+>~.[:]+|:first-line|:first-letter|:before|:after)/gi,Cr=/(:[\w-]+\([^)]*\))/gi,wr=/(:[^\s+>~.[:]+)/g,xr=/([^\s+>~.[:]+)/g;function ne(u,l){var t=l.exec(u);return t?[u.replace(l," "),t.length]:[u,0]}function rt(u){var l=[0,0,0],t=u.replace(/:not\(([^)]*)\)/g," $1 ").replace(/{[\s\S]*/gm," "),r=0,e=ne(t,_r),a=M.default(e,2);t=a[0],r=a[1],l[1]+=r;var n=ne(t,kr),i=M.default(n,2);t=i[0],r=i[1],l[0]+=r;var s=ne(t,Pr),o=M.default(s,2);t=o[0],r=o[1],l[1]+=r;var f=ne(t,Rr),c=M.default(f,2);t=c[0],r=c[1],l[2]+=r;var h=ne(t,Cr),v=M.default(h,2);t=v[0],r=v[1],l[1]+=r;var g=ne(t,wr),p=M.default(g,2);t=p[0],r=p[1],l[1]+=r,t=t.replace(/[*\s+>~]/g," ").replace(/[#.]/g," ");var S=ne(t,xr),m=M.default(S,2);return t=m[0],r=m[1],l[2]+=r,l.join("")}var ae=1e-8;function Te(u){return Math.sqrt(Math.pow(u[0],2)+Math.pow(u[1],2))}function ye(u,l){return(u[0]*l[0]+u[1]*l[1])/(Te(u)*Te(l))}function Me(u,l){return(u[0]*l[1]
2024-11-08 12:27:11 +08:00
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,n=!1,i;return{s:function(){t=t.call(u)},n:function(){var o=t.next();return a=o.done,o},e:function(o){n=!0,i=o},f:function(){try{!a&&t.return!=null&&t.return()}finally{if(n)throw i}}}}function Xn(u,l){if(!!u){if(typeof u=="string")return Ct(u,l);var t=Object.prototype.toString.call(u).slice(8,-1);if(t==="Object"&&u.constructor&&(t=u.constructor.name),t==="Map"||t==="Set")return Array.from(u);if(t==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return Ct(u,l)}}function Ct(u,l){(l==null||l>u.length)&&(l=u.length);for(var t=0,r=new Array(l);t<l;t++)r[t]=u[t];return r}function Gn(u){var l=Yn();return function(){var r=d.default(u),e;if(l){var a=d.default(this).constructor;e=Reflect.construct(r,arguments,a)}else e=r.apply(this,arguments);return C.default(this,e)}}function Yn(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}var wt=function(u){x.default(t,u);var l=Gn(t);function t(r,e,a){var n;b.default(this,t),n=l.call(this,r,e,a),n.type="font",n.glyphs={},n.horizAdvX=n.getAttribute("horiz-adv-x").getNumber();var i=r.definitions,s=he.default(n),o=s.children,f=qn(o),c;try{for(f.s();!(c=f.n()).done;){var h=c.value;switch(h.type){case"font-face":{n.fontFace=h;var v=h.getStyle("font-family");v.hasValue()&&(i[v.getString()]=he.default(n));break}case"missing-glyph":n.missingGlyph=h;break;case"glyph":{var g=h;g.arabicForm?(n.isRTL=!0,n.isArabic=!0,typeof n.glyphs[g.unicode]>"u"&&(n.glyphs[g.unicode]={}),n.glyphs[g.unicode][g.arabicForm]=g):n.glyphs[g.unicode]=g;break}default:}}}catch(p){f.e(p)}finally{f.f()}return n}return P.default(t,[{key:"render",value:function(){}}]),t}(N);function jn(u){var l=Un();return function(){var r=d.default(u),e;if(l){var a=d.default(this).constructor;e=Reflect.construct(r,arguments,a)}else e=r.apply(this,arguments);return C.default(this,e)}}function Un(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}var xt=function(u){x.default(t,u);var l=jn(t);function t(r,e,a){var n;return b.default(this,t),n=l.call(this,r,e,a),n.type="font-face",n.ascent=n.getAttribute("ascent").getNumber(),n.descent=n.getAttribute("descent").getNumber(),n.unitsPerEm=n.getAttribute("units-per-em").getNumber(),n}return t}(N);function Hn(u){var l=Wn();return function(){var r=d.default(u),e;if(l){var a=d.default(this).constructor;e=Reflect.construct(r,arguments,a)}else e=r.apply(this,arguments);return C.default(this,e)}}function Wn(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}var Et=function(u){x.default(t,u);var l=Hn(t);function t(){var r;return b.default(this,t),r=l.apply(this,arguments),r.type="missing-glyph",r.horizAdvX=0,r}return t}(V);function Qn(u){var l=Zn();return function(){var r=d.default(u),e;if(l){var a=d.default(this).constructor;e=Reflect.construct(r,arguments,a)}else e=r.apply(this,arguments);return C.default(this,e)}}function Zn(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}var At=function(u){x.default(t,u);var l=Qn(t);function t(){var r;return b.default(this,t),r=l.apply(this,arguments),r.type="tref",r}return P.default(t,[{key:"getText",value:function(){var e=this.getHrefAttribute().getDefinition();if(e){var a=e.children[0];if(a)return a.getText()}return""}}]),t}(ue);function Jn(u){var l=Kn();return function(){var r=d.default(u),e;if(l){var a=d.default(this).constructor;e=Reflect.construct(r,arguments,a)}else e=r.apply(this,arguments);r
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,n=!1,i;return{s:function(){t=t.call(u)},n:function(){var o=t.next();return a=o.done,o},e:function(o){n=!0,i=o},f:function(){try{!a&&t.return!=null&&t.return()}finally{if(n)throw i}}}}function ta(u,l){if(!!u){if(typeof u=="string")return Mt(u,l);var t=Object.prototype.toString.call(u).slice(8,-1);if(t==="Object"&&u.constructor&&(t=u.constructor.name),t==="Map"||t==="Set")return Array.from(u);if(t==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return Mt(u,l)}}function Mt(u,l){(l==null||l>u.length)&&(l=u.length);for(var t=0,r=new Array(l);t<l;t++)r[t]=u[t];return r}function Bt(u,l){var t=Object.keys(u);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(u);l&&(r=r.filter(function(e){return Object.getOwnPropertyDescriptor(u,e).enumerable})),t.push.apply(t,r)}return t}function _e(u){for(var l=1;l<arguments.length;l++){var t=arguments[l]!=null?arguments[l]:{};l%2?Bt(Object(t),!0).forEach(function(r){we.default(u,r,t[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(u,Object.getOwnPropertyDescriptors(t)):Bt(Object(t)).forEach(function(r){Object.defineProperty(u,r,Object.getOwnPropertyDescriptor(t,r))})}return u}function ra(u){var l=na();return function(){var r=d.default(u),e;if(l){var a=d.default(this).constructor;e=Reflect.construct(r,arguments,a)}else e=r.apply(this,arguments);return C.default(this,e)}}function na(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}var Nt=function(u){x.default(t,u);var l=ra(t);function t(r,e,a){var n;b.default(this,t),n=l.call(this,r,e,a),n.type="textPath",n.textWidth=0,n.textHeight=0,n.pathLength=-1,n.glyphInfo=null,n.letterSpacingCache=[],n.measuresCache=new Map([["",0]]);var i=n.getHrefAttribute().getDefinition();return n.text=n.getTextFromNode(),n.dataArray=n.parsePathData(i),n}return P.default(t,[{key:"getText",value:function(){return this.text}},{key:"path",value:function(e){var a=this.dataArray;e&&e.beginPath(),a.forEach(function(n){var i=n.type,s=n.points;switch(i){case A.LINE_TO:e&&e.lineTo(s[0],s[1]);break;case A.MOVE_TO:e&&e.moveTo(s[0],s[1]);break;case A.CURVE_TO:e&&e.bezierCurveTo(s[0],s[1],s[2],s[3],s[4],s[5]);break;case A.QUAD_TO:e&&e.quadraticCurveTo(s[0],s[1],s[2],s[3]);break;case A.ARC:{var o=M.default(s,8),f=o[0],c=o[1],h=o[2],v=o[3],g=o[4],p=o[5],S=o[6],m=o[7],E=h>v?h:v,k=h>v?1:h/v,_=h>v?v/h:1;e&&(e.translate(f,c),e.rotate(S),e.scale(k,_),e.arc(0,0,E,g,g+p,Boolean(1-m)),e.scale(1/k,1/_),e.rotate(-S),e.translate(-f,-c));break}case A.CLOSE_PATH:e&&e.closePath();break}})}},{key:"renderChildren",value:function(e){this.setTextData(e),e.save();var a=this.parent.getStyle("text-decoration").getString(),n=this.getFontSize(),i=this.glyphInfo,s=e.fillStyle;a==="underline"&&e.beginPath(),i.forEach(function(o,f){var c=o.p0,h=o.p1,v=o.rotation,g=o.text;e.save(),e.translate(c.x,c.y),e.rotate(v),e.fillStyle&&e.fillText(g,0,0),e.strokeStyle&&e.strokeText(g,0,0),e.restore(),a==="underline"&&(f===0&&e.moveTo(c.x,c.y+n/8),e.lineTo(h.x,h.y+n/5))}),a==="underline"&&(e.lineWidth=n/20,e.strokeStyle=s,e.stroke(),e.closePath()),e.restore()}},{key:"getLetterSpacingAt",value:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0;return this.letterSpacingCache[e]||0}},{key:"findSegmentToFitChar",value:function(e,a,n,i,s,o,f,c,h){var v=o,g=this.measureText(e,c);c===" "&&a==="justify"&&n<i&&(g+=(i-n)/s),h>-1&&(v+=this.getLetterSpacingAt(h));var p=this.textHeight/20,S=this.getEquidistantPointOnPath(v,p,0),m=this.getEquidistantPointOnPath(v+g,p,0),E={p0:S,p1:m},k=S&&m?Math.atan2(m.y-S.y,m.x-S.x):0;if(f){var _=Math.cos(Math.PI/2+k)*f,w=Math.cos(-k)*f;E.p0=_e(_e({},S),{},{x:S.x+_,y:S.y+w}),E.p1=_e(_e({},m),{},{x:m.x+_,y:m.y+w})}return v+=g,{offset:v,segment:E,rotation:k}}},{key:"measureText",value:function(e,a){var n=this.measuresCache,i=a||this.getText();if(n.has(i))return n.get(i);v