gp-designer 1.0.39 → 1.0.41
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.
- package/dist/gp-designer.es.js +8 -8
- package/dist/gp-designer.umd.js +1 -1
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/gp-designer.es.js
CHANGED
@@ -17231,10 +17231,10 @@ var dU = function(A, e) {
|
|
17231
17231
|
var r = e.ownerDocument, n = r.documentElement ? Qr(A, getComputedStyle(r.documentElement).backgroundColor) : He.TRANSPARENT, s = r.body ? Qr(A, getComputedStyle(r.body).backgroundColor) : He.TRANSPARENT, a = typeof t == "string" ? Qr(A, t) : t === null ? He.TRANSPARENT : 4294967295;
|
17232
17232
|
return e === r.documentElement ? ze(n) ? ze(s) ? a : s : n : a;
|
17233
17233
|
};
|
17234
|
-
const gU = { class: "flex gp-dsigner" }, EU = {
|
17234
|
+
const gU = { class: "flex gp-dsigner" }, EU = {
|
17235
17235
|
key: 0,
|
17236
|
-
class: "
|
17237
|
-
}, pU = { class: "text-sm font-thin text-gray-500" }, mU = ["innerHTML"], wU = ["innerHTML"], TU = { class: "flex-1" }, bU = {
|
17236
|
+
class: "flex items-center justify-between border-b"
|
17237
|
+
}, CU = { class: "text-lg font-bold p-2" }, pU = { class: "text-sm font-thin text-gray-500" }, mU = ["innerHTML"], wU = ["innerHTML"], TU = { class: "flex-1" }, bU = {
|
17238
17238
|
key: 0,
|
17239
17239
|
class: "text-lg font-bold border-b p-2"
|
17240
17240
|
}, UU = { class: "p-2" }, QU = { class: "sticky top-0" }, FU = {
|
@@ -17576,16 +17576,16 @@ const gU = { class: "flex gp-dsigner" }, EU = { class: "flex items-center justif
|
|
17576
17576
|
class: "border-l overflow-auto resize-area",
|
17577
17577
|
style: Li({ width: IA.value + "px" })
|
17578
17578
|
}, [
|
17579
|
-
|
17580
|
-
|
17579
|
+
S.showTitle ? (G(), V("div", EU, [
|
17580
|
+
b("h2", CU, [
|
17581
17581
|
L[3] || (L[3] = Aa(" 实时预览 ")),
|
17582
17582
|
b("span", pU, WA(IA.value) + "px", 1)
|
17583
|
-
])
|
17583
|
+
]),
|
17584
17584
|
b("div", {
|
17585
17585
|
onClick: L[0] || (L[0] = () => I()),
|
17586
17586
|
class: "p-2 cursor-pointer text-blue-500"
|
17587
17587
|
}, " 生成封面 ")
|
17588
|
-
]),
|
17588
|
+
])) : q("", !0),
|
17589
17589
|
b("div", {
|
17590
17590
|
ref_key: "previewRef",
|
17591
17591
|
ref: C
|
@@ -17678,7 +17678,7 @@ const gU = { class: "flex gp-dsigner" }, EU = { class: "flex items-center justif
|
|
17678
17678
|
}, 512)
|
17679
17679
|
]));
|
17680
17680
|
}
|
17681
|
-
}), yU = /* @__PURE__ */ wt(_U, [["__scopeId", "data-v-
|
17681
|
+
}), yU = /* @__PURE__ */ wt(_U, [["__scopeId", "data-v-3248e027"]]), RU = {
|
17682
17682
|
install(A) {
|
17683
17683
|
A.component("Designer", yU);
|
17684
17684
|
}
|
package/dist/gp-designer.umd.js
CHANGED
@@ -35,4 +35,4 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
35
35
|
content: "" !important;
|
36
36
|
display: none !important;
|
37
37
|
}`,zT=function(A){Ab(A,"."+ai+$T+Sl+`
|
38
|
-
.`+si+jT+Sl)},Ab=function(A,e){var t=A.ownerDocument;if(t){var r=t.createElement("style");r.textContent=e,A.appendChild(r)}},vl=function(){function A(){}return A.getOrigin=function(e){var t=A._link;return t?(t.href=e,t.href=t.href,t.protocol+t.hostname+t.port):"about:blank"},A.isSameOrigin=function(e){return A.getOrigin(e)===A._origin},A.setContext=function(e){A._link=e.document.createElement("a"),A._origin=A.getOrigin(e.location.href)},A._origin="about:blank",A}(),eb=function(){function A(e,t){this.context=e,this._options=t,this._cache={}}return A.prototype.addImage=function(e){var t=Promise.resolve();return this.has(e)||(ui(e)||ab(e))&&(this._cache[e]=this.loadImage(e)).catch(function(){}),t},A.prototype.match=function(e){return this._cache[e]},A.prototype.loadImage=function(e){return kA(this,void 0,void 0,function(){var t,r,n,a,s=this;return DA(this,function(u){switch(u.label){case 0:return t=vl.isSameOrigin(e),r=!ii(e)&&this._options.useCORS===!0&&LA.SUPPORT_CORS_IMAGES&&!t,n=!ii(e)&&!t&&!ui(e)&&typeof this._options.proxy=="string"&&LA.SUPPORT_CORS_XHR&&!r,!t&&this._options.allowTaint===!1&&!ii(e)&&!ui(e)&&!n&&!r?[2]:(a=e,n?[4,this.proxy(a)]:[3,2]);case 1:a=u.sent(),u.label=2;case 2:return this.context.logger.debug("Added image "+e.substring(0,256)),[4,new Promise(function(o,c){var f=new Image;f.onload=function(){return o(f)},f.onerror=c,(sb(a)||r)&&(f.crossOrigin="anonymous"),f.src=a,f.complete===!0&&setTimeout(function(){return o(f)},500),s._options.imageTimeout>0&&setTimeout(function(){return c("Timed out ("+s._options.imageTimeout+"ms) loading image")},s._options.imageTimeout)})];case 3:return[2,u.sent()]}})})},A.prototype.has=function(e){return typeof this._cache[e]<"u"},A.prototype.keys=function(){return Promise.resolve(Object.keys(this._cache))},A.prototype.proxy=function(e){var t=this,r=this._options.proxy;if(!r)throw new Error("No proxy defined");var n=e.substring(0,256);return new Promise(function(a,s){var u=LA.SUPPORT_RESPONSE_TYPE?"blob":"text",o=new XMLHttpRequest;o.onload=function(){if(o.status===200)if(u==="text")a(o.response);else{var h=new FileReader;h.addEventListener("load",function(){return a(h.result)},!1),h.addEventListener("error",function(d){return s(d)},!1),h.readAsDataURL(o.response)}else s("Failed to proxy resource "+n+" with status code "+o.status)},o.onerror=s;var c=r.indexOf("?")>-1?"&":"?";if(o.open("GET",""+r+c+"url="+encodeURIComponent(e)+"&responseType="+u),u!=="text"&&o instanceof XMLHttpRequest&&(o.responseType=u),t._options.imageTimeout){var f=t._options.imageTimeout;o.timeout=f,o.ontimeout=function(){return s("Timed out ("+f+"ms) proxying "+n)}}o.send()})},A}(),tb=/^data:image\/svg\+xml/i,rb=/^data:image\/.*;base64,/i,nb=/^data:image\/.*/i,ab=function(A){return LA.SUPPORT_SVG_DRAWING||!ib(A)},ii=function(A){return nb.test(A)},sb=function(A){return rb.test(A)},ui=function(A){return A.substr(0,4)==="blob"},ib=function(A){return A.substr(-3).toLowerCase()==="svg"||tb.test(A)},x=function(){function A(e,t){this.type=0,this.x=e,this.y=t}return A.prototype.add=function(e,t){return new A(this.x+e,this.y+t)},A}(),Lt=function(A,e,t){return new x(A.x+(e.x-A.x)*t,A.y+(e.y-A.y)*t)},$n=function(){function A(e,t,r,n){this.type=1,this.start=e,this.startControl=t,this.endControl=r,this.end=n}return A.prototype.subdivide=function(e,t){var r=Lt(this.start,this.startControl,e),n=Lt(this.startControl,this.endControl,e),a=Lt(this.endControl,this.end,e),s=Lt(r,n,e),u=Lt(n,a,e),o=Lt(s,u,e);return t?new A(this.start,r,s,o):new A(o,u,a,this.end)},A.prototype.add=function(e,t){return new A(this.start.add(e,t),this.startControl.add(e,t),this.endControl.add(e,t),this.end.add(e,t))},A.prototype.reverse=function(){return new A(this.end,this.endControl,this.startControl,this.start)},A}(),re=function(A){return A.type===1},ub=function(){function A(e){var t=e.styles,r=e.bounds,n=br(t.borderTopLeftRadius,r.width,r.height),a=n[0],s=n[1],u=br(t.borderTopRightRadius,r.width,r.height),o=u[0],c=u[1],f=br(t.borderBottomRightRadius,r.width,r.height),h=f[0],d=f[1],m=br(t.borderBottomLeftRadius,r.width,r.height),C=m[0],T=m[1],F=[];F.push((a+o)/r.width),F.push((C+h)/r.width),F.push((s+T)/r.height),F.push((c+d)/r.height);var Q=Math.max.apply(Math,F);Q>1&&(a/=Q,s/=Q,o/=Q,c/=Q,h/=Q,d/=Q,C/=Q,T/=Q);var I=r.width-o,H=r.height-d,M=r.width-h,y=r.height-T,p=t.borderTopWidth,L=t.borderRightWidth,k=t.borderBottomWidth,O=t.borderLeftWidth,AA=uA(t.paddingTop,e.bounds.width),oA=uA(t.paddingRight,e.bounds.width),cA=uA(t.paddingBottom,e.bounds.width),W=uA(t.paddingLeft,e.bounds.width);this.topLeftBorderDoubleOuterBox=a>0||s>0?BA(r.left+O/3,r.top+p/3,a-O/3,s-p/3,aA.TOP_LEFT):new x(r.left+O/3,r.top+p/3),this.topRightBorderDoubleOuterBox=a>0||s>0?BA(r.left+I,r.top+p/3,o-L/3,c-p/3,aA.TOP_RIGHT):new x(r.left+r.width-L/3,r.top+p/3),this.bottomRightBorderDoubleOuterBox=h>0||d>0?BA(r.left+M,r.top+H,h-L/3,d-k/3,aA.BOTTOM_RIGHT):new x(r.left+r.width-L/3,r.top+r.height-k/3),this.bottomLeftBorderDoubleOuterBox=C>0||T>0?BA(r.left+O/3,r.top+y,C-O/3,T-k/3,aA.BOTTOM_LEFT):new x(r.left+O/3,r.top+r.height-k/3),this.topLeftBorderDoubleInnerBox=a>0||s>0?BA(r.left+O*2/3,r.top+p*2/3,a-O*2/3,s-p*2/3,aA.TOP_LEFT):new x(r.left+O*2/3,r.top+p*2/3),this.topRightBorderDoubleInnerBox=a>0||s>0?BA(r.left+I,r.top+p*2/3,o-L*2/3,c-p*2/3,aA.TOP_RIGHT):new x(r.left+r.width-L*2/3,r.top+p*2/3),this.bottomRightBorderDoubleInnerBox=h>0||d>0?BA(r.left+M,r.top+H,h-L*2/3,d-k*2/3,aA.BOTTOM_RIGHT):new x(r.left+r.width-L*2/3,r.top+r.height-k*2/3),this.bottomLeftBorderDoubleInnerBox=C>0||T>0?BA(r.left+O*2/3,r.top+y,C-O*2/3,T-k*2/3,aA.BOTTOM_LEFT):new x(r.left+O*2/3,r.top+r.height-k*2/3),this.topLeftBorderStroke=a>0||s>0?BA(r.left+O/2,r.top+p/2,a-O/2,s-p/2,aA.TOP_LEFT):new x(r.left+O/2,r.top+p/2),this.topRightBorderStroke=a>0||s>0?BA(r.left+I,r.top+p/2,o-L/2,c-p/2,aA.TOP_RIGHT):new x(r.left+r.width-L/2,r.top+p/2),this.bottomRightBorderStroke=h>0||d>0?BA(r.left+M,r.top+H,h-L/2,d-k/2,aA.BOTTOM_RIGHT):new x(r.left+r.width-L/2,r.top+r.height-k/2),this.bottomLeftBorderStroke=C>0||T>0?BA(r.left+O/2,r.top+y,C-O/2,T-k/2,aA.BOTTOM_LEFT):new x(r.left+O/2,r.top+r.height-k/2),this.topLeftBorderBox=a>0||s>0?BA(r.left,r.top,a,s,aA.TOP_LEFT):new x(r.left,r.top),this.topRightBorderBox=o>0||c>0?BA(r.left+I,r.top,o,c,aA.TOP_RIGHT):new x(r.left+r.width,r.top),this.bottomRightBorderBox=h>0||d>0?BA(r.left+M,r.top+H,h,d,aA.BOTTOM_RIGHT):new x(r.left+r.width,r.top+r.height),this.bottomLeftBorderBox=C>0||T>0?BA(r.left,r.top+y,C,T,aA.BOTTOM_LEFT):new x(r.left,r.top+r.height),this.topLeftPaddingBox=a>0||s>0?BA(r.left+O,r.top+p,Math.max(0,a-O),Math.max(0,s-p),aA.TOP_LEFT):new x(r.left+O,r.top+p),this.topRightPaddingBox=o>0||c>0?BA(r.left+Math.min(I,r.width-L),r.top+p,I>r.width+L?0:Math.max(0,o-L),Math.max(0,c-p),aA.TOP_RIGHT):new x(r.left+r.width-L,r.top+p),this.bottomRightPaddingBox=h>0||d>0?BA(r.left+Math.min(M,r.width-O),r.top+Math.min(H,r.height-k),Math.max(0,h-L),Math.max(0,d-k),aA.BOTTOM_RIGHT):new x(r.left+r.width-L,r.top+r.height-k),this.bottomLeftPaddingBox=C>0||T>0?BA(r.left+O,r.top+Math.min(y,r.height-k),Math.max(0,C-O),Math.max(0,T-k),aA.BOTTOM_LEFT):new x(r.left+O,r.top+r.height-k),this.topLeftContentBox=a>0||s>0?BA(r.left+O+W,r.top+p+AA,Math.max(0,a-(O+W)),Math.max(0,s-(p+AA)),aA.TOP_LEFT):new x(r.left+O+W,r.top+p+AA),this.topRightContentBox=o>0||c>0?BA(r.left+Math.min(I,r.width+O+W),r.top+p+AA,I>r.width+O+W?0:o-O+W,c-(p+AA),aA.TOP_RIGHT):new x(r.left+r.width-(L+oA),r.top+p+AA),this.bottomRightContentBox=h>0||d>0?BA(r.left+Math.min(M,r.width-(O+W)),r.top+Math.min(H,r.height+p+AA),Math.max(0,h-(L+oA)),d-(k+cA),aA.BOTTOM_RIGHT):new x(r.left+r.width-(L+oA),r.top+r.height-(k+cA)),this.bottomLeftContentBox=C>0||T>0?BA(r.left+O+W,r.top+y,Math.max(0,C-(O+W)),T-(k+cA),aA.BOTTOM_LEFT):new x(r.left+O+W,r.top+r.height-(k+cA))}return A}(),aA;(function(A){A[A.TOP_LEFT=0]="TOP_LEFT",A[A.TOP_RIGHT=1]="TOP_RIGHT",A[A.BOTTOM_RIGHT=2]="BOTTOM_RIGHT",A[A.BOTTOM_LEFT=3]="BOTTOM_LEFT"})(aA||(aA={}));var BA=function(A,e,t,r,n){var a=4*((Math.sqrt(2)-1)/3),s=t*a,u=r*a,o=A+t,c=e+r;switch(n){case aA.TOP_LEFT:return new $n(new x(A,c),new x(A,c-u),new x(o-s,e),new x(o,e));case aA.TOP_RIGHT:return new $n(new x(A,e),new x(A+s,e),new x(o,c-u),new x(o,c));case aA.BOTTOM_RIGHT:return new $n(new x(o,e),new x(o,e+u),new x(A+s,c),new x(A,c));case aA.BOTTOM_LEFT:default:return new $n(new x(o,c),new x(o-s,c),new x(A,e+u),new x(A,e))}},jn=function(A){return[A.topLeftBorderBox,A.topRightBorderBox,A.bottomRightBorderBox,A.bottomLeftBorderBox]},ob=function(A){return[A.topLeftContentBox,A.topRightContentBox,A.bottomRightContentBox,A.bottomLeftContentBox]},zn=function(A){return[A.topLeftPaddingBox,A.topRightPaddingBox,A.bottomRightPaddingBox,A.bottomLeftPaddingBox]},cb=function(){function A(e,t,r){this.offsetX=e,this.offsetY=t,this.matrix=r,this.type=0,this.target=6}return A}(),Aa=function(){function A(e,t){this.path=e,this.target=t,this.type=1}return A}(),lb=function(){function A(e){this.opacity=e,this.type=2,this.target=6}return A}(),fb=function(A){return A.type===0},Ll=function(A){return A.type===1},hb=function(A){return A.type===2},Hl=function(A,e){return A.length===e.length?A.some(function(t,r){return t===e[r]}):!1},db=function(A,e,t,r,n){return A.map(function(a,s){switch(s){case 0:return a.add(e,t);case 1:return a.add(e+r,t);case 2:return a.add(e+r,t+n);case 3:return a.add(e,t+n)}return a})},xl=function(){function A(e){this.element=e,this.inlineLevel=[],this.nonInlineLevel=[],this.negativeZIndex=[],this.zeroOrAutoZIndexOrTransformedOrOpacity=[],this.positiveZIndex=[],this.nonPositionedFloats=[],this.nonPositionedInlineLevel=[]}return A}(),Dl=function(){function A(e,t){if(this.container=e,this.parent=t,this.effects=[],this.curves=new ub(this.container),this.container.styles.opacity<1&&this.effects.push(new lb(this.container.styles.opacity)),this.container.styles.transform!==null){var r=this.container.bounds.left+this.container.styles.transformOrigin[0].number,n=this.container.bounds.top+this.container.styles.transformOrigin[1].number,a=this.container.styles.transform;this.effects.push(new cb(r,n,a))}if(this.container.styles.overflowX!==0){var s=jn(this.curves),u=zn(this.curves);Hl(s,u)?this.effects.push(new Aa(s,6)):(this.effects.push(new Aa(s,2)),this.effects.push(new Aa(u,4)))}}return A.prototype.getEffects=function(e){for(var t=[2,3].indexOf(this.container.styles.position)===-1,r=this.parent,n=this.effects.slice(0);r;){var a=r.effects.filter(function(o){return!Ll(o)});if(t||r.container.styles.position!==0||!r.parent){if(n.unshift.apply(n,a),t=[2,3].indexOf(r.container.styles.position)===-1,r.container.styles.overflowX!==0){var s=jn(r.curves),u=zn(r.curves);Hl(s,u)||n.unshift(new Aa(u,6))}}else n.unshift.apply(n,a);r=r.parent}return n.filter(function(o){return bA(o.target,e)})},A}(),oi=function(A,e,t,r){A.container.elements.forEach(function(n){var a=bA(n.flags,4),s=bA(n.flags,2),u=new Dl(n,A);bA(n.styles.display,2048)&&r.push(u);var o=bA(n.flags,8)?[]:r;if(a||s){var c=a||n.styles.isPositioned()?t:e,f=new xl(u);if(n.styles.isPositioned()||n.styles.opacity<1||n.styles.isTransformed()){var h=n.styles.zIndex.order;if(h<0){var d=0;c.negativeZIndex.some(function(C,T){return h>C.element.container.styles.zIndex.order?(d=T,!1):d>0}),c.negativeZIndex.splice(d,0,f)}else if(h>0){var m=0;c.positiveZIndex.some(function(C,T){return h>=C.element.container.styles.zIndex.order?(m=T+1,!1):m>0}),c.positiveZIndex.splice(m,0,f)}else c.zeroOrAutoZIndexOrTransformedOrOpacity.push(f)}else n.styles.isFloating()?c.nonPositionedFloats.push(f):c.nonPositionedInlineLevel.push(f);oi(u,f,a?f:t,o)}else n.styles.isInlineLevel()?e.inlineLevel.push(u):e.nonInlineLevel.push(u),oi(u,e,t,o);bA(n.flags,8)&&Ol(n,o)})},Ol=function(A,e){for(var t=A instanceof js?A.start:1,r=A instanceof js?A.reversed:!1,n=0;n<e.length;n++){var a=e[n];a.container instanceof ul&&typeof a.container.value=="number"&&a.container.value!==0&&(t=a.container.value),a.listValue=yr(t,a.container.styles.listStyleType,!0),t+=r?-1:1}},Bb=function(A){var e=new Dl(A,null),t=new xl(e),r=[];return oi(e,t,t,r),Ol(e.container,r),t},Rl=function(A,e){switch(e){case 0:return ne(A.topLeftBorderBox,A.topLeftPaddingBox,A.topRightBorderBox,A.topRightPaddingBox);case 1:return ne(A.topRightBorderBox,A.topRightPaddingBox,A.bottomRightBorderBox,A.bottomRightPaddingBox);case 2:return ne(A.bottomRightBorderBox,A.bottomRightPaddingBox,A.bottomLeftBorderBox,A.bottomLeftPaddingBox);case 3:default:return ne(A.bottomLeftBorderBox,A.bottomLeftPaddingBox,A.topLeftBorderBox,A.topLeftPaddingBox)}},gb=function(A,e){switch(e){case 0:return ne(A.topLeftBorderBox,A.topLeftBorderDoubleOuterBox,A.topRightBorderBox,A.topRightBorderDoubleOuterBox);case 1:return ne(A.topRightBorderBox,A.topRightBorderDoubleOuterBox,A.bottomRightBorderBox,A.bottomRightBorderDoubleOuterBox);case 2:return ne(A.bottomRightBorderBox,A.bottomRightBorderDoubleOuterBox,A.bottomLeftBorderBox,A.bottomLeftBorderDoubleOuterBox);case 3:default:return ne(A.bottomLeftBorderBox,A.bottomLeftBorderDoubleOuterBox,A.topLeftBorderBox,A.topLeftBorderDoubleOuterBox)}},Eb=function(A,e){switch(e){case 0:return ne(A.topLeftBorderDoubleInnerBox,A.topLeftPaddingBox,A.topRightBorderDoubleInnerBox,A.topRightPaddingBox);case 1:return ne(A.topRightBorderDoubleInnerBox,A.topRightPaddingBox,A.bottomRightBorderDoubleInnerBox,A.bottomRightPaddingBox);case 2:return ne(A.bottomRightBorderDoubleInnerBox,A.bottomRightPaddingBox,A.bottomLeftBorderDoubleInnerBox,A.bottomLeftPaddingBox);case 3:default:return ne(A.bottomLeftBorderDoubleInnerBox,A.bottomLeftPaddingBox,A.topLeftBorderDoubleInnerBox,A.topLeftPaddingBox)}},pb=function(A,e){switch(e){case 0:return ea(A.topLeftBorderStroke,A.topRightBorderStroke);case 1:return ea(A.topRightBorderStroke,A.bottomRightBorderStroke);case 2:return ea(A.bottomRightBorderStroke,A.bottomLeftBorderStroke);case 3:default:return ea(A.bottomLeftBorderStroke,A.topLeftBorderStroke)}},ea=function(A,e){var t=[];return re(A)?t.push(A.subdivide(.5,!1)):t.push(A),re(e)?t.push(e.subdivide(.5,!0)):t.push(e),t},ne=function(A,e,t,r){var n=[];return re(A)?n.push(A.subdivide(.5,!1)):n.push(A),re(t)?n.push(t.subdivide(.5,!0)):n.push(t),re(r)?n.push(r.subdivide(.5,!0).reverse()):n.push(r),re(e)?n.push(e.subdivide(.5,!1).reverse()):n.push(e),n},Ml=function(A){var e=A.bounds,t=A.styles;return e.add(t.borderLeftWidth,t.borderTopWidth,-(t.borderRightWidth+t.borderLeftWidth),-(t.borderTopWidth+t.borderBottomWidth))},ta=function(A){var e=A.styles,t=A.bounds,r=uA(e.paddingLeft,t.width),n=uA(e.paddingRight,t.width),a=uA(e.paddingTop,t.width),s=uA(e.paddingBottom,t.width);return t.add(r+e.borderLeftWidth,a+e.borderTopWidth,-(e.borderRightWidth+e.borderLeftWidth+r+n),-(e.borderTopWidth+e.borderBottomWidth+a+s))},Cb=function(A,e){return A===0?e.bounds:A===2?ta(e):Ml(e)},mb=function(A,e){return A===0?e.bounds:A===2?ta(e):Ml(e)},ci=function(A,e,t){var r=Cb(xt(A.styles.backgroundOrigin,e),A),n=mb(xt(A.styles.backgroundClip,e),A),a=wb(xt(A.styles.backgroundSize,e),t,r),s=a[0],u=a[1],o=br(xt(A.styles.backgroundPosition,e),r.width-s,r.height-u),c=Tb(xt(A.styles.backgroundRepeat,e),o,a,r,n),f=Math.round(r.left+o[0]),h=Math.round(r.top+o[1]);return[c,f,h,s,u]},Ht=function(A){return iA(A)&&A.value===yt.AUTO},ra=function(A){return typeof A=="number"},wb=function(A,e,t){var r=e[0],n=e[1],a=e[2],s=A[0],u=A[1];if(!s)return[0,0];if(mA(s)&&u&&mA(u))return[uA(s,t.width),uA(u,t.height)];var o=ra(a);if(iA(s)&&(s.value===yt.CONTAIN||s.value===yt.COVER)){if(ra(a)){var c=t.width/t.height;return c<a!=(s.value===yt.COVER)?[t.width,t.width/a]:[t.height*a,t.height]}return[t.width,t.height]}var f=ra(r),h=ra(n),d=f||h;if(Ht(s)&&(!u||Ht(u))){if(f&&h)return[r,n];if(!o&&!d)return[t.width,t.height];if(d&&o){var m=f?r:n*a,C=h?n:r/a;return[m,C]}var T=f?r:t.width,F=h?n:t.height;return[T,F]}if(o){var Q=0,I=0;return mA(s)?Q=uA(s,t.width):mA(u)&&(I=uA(u,t.height)),Ht(s)?Q=I*a:(!u||Ht(u))&&(I=Q/a),[Q,I]}var H=null,M=null;if(mA(s)?H=uA(s,t.width):u&&mA(u)&&(M=uA(u,t.height)),H!==null&&(!u||Ht(u))&&(M=f&&h?H/r*n:t.height),M!==null&&Ht(s)&&(H=f&&h?M/n*r:t.width),H!==null&&M!==null)return[H,M];throw new Error("Unable to calculate background-size for element")},xt=function(A,e){var t=A[e];return typeof t>"u"?A[0]:t},Tb=function(A,e,t,r,n){var a=e[0],s=e[1],u=t[0],o=t[1];switch(A){case 2:return[new x(Math.round(r.left),Math.round(r.top+s)),new x(Math.round(r.left+r.width),Math.round(r.top+s)),new x(Math.round(r.left+r.width),Math.round(o+r.top+s)),new x(Math.round(r.left),Math.round(o+r.top+s))];case 3:return[new x(Math.round(r.left+a),Math.round(r.top)),new x(Math.round(r.left+a+u),Math.round(r.top)),new x(Math.round(r.left+a+u),Math.round(r.height+r.top)),new x(Math.round(r.left+a),Math.round(r.height+r.top))];case 1:return[new x(Math.round(r.left+a),Math.round(r.top+s)),new x(Math.round(r.left+a+u),Math.round(r.top+s)),new x(Math.round(r.left+a+u),Math.round(r.top+s+o)),new x(Math.round(r.left+a),Math.round(r.top+s+o))];default:return[new x(Math.round(n.left),Math.round(n.top)),new x(Math.round(n.left+n.width),Math.round(n.top)),new x(Math.round(n.left+n.width),Math.round(n.height+n.top)),new x(Math.round(n.left),Math.round(n.height+n.top))]}},bb="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7",kl="Hidden Text",Ub=function(){function A(e){this._data={},this._document=e}return A.prototype.parseMetrics=function(e,t){var r=this._document.createElement("div"),n=this._document.createElement("img"),a=this._document.createElement("span"),s=this._document.body;r.style.visibility="hidden",r.style.fontFamily=e,r.style.fontSize=t,r.style.margin="0",r.style.padding="0",r.style.whiteSpace="nowrap",s.appendChild(r),n.src=bb,n.width=1,n.height=1,n.style.margin="0",n.style.padding="0",n.style.verticalAlign="baseline",a.style.fontFamily=e,a.style.fontSize=t,a.style.margin="0",a.style.padding="0",a.appendChild(this._document.createTextNode(kl)),r.appendChild(a),r.appendChild(n);var u=n.offsetTop-a.offsetTop+2;r.removeChild(a),r.appendChild(this._document.createTextNode(kl)),r.style.lineHeight="normal",n.style.verticalAlign="super";var o=n.offsetTop-r.offsetTop+2;return s.removeChild(r),{baseline:u,middle:o}},A.prototype.getMetrics=function(e,t){var r=e+" "+t;return typeof this._data[r]>"u"&&(this._data[r]=this.parseMetrics(e,t)),this._data[r]},A}(),Pl=function(){function A(e,t){this.context=e,this.options=t}return A}(),Qb=1e4,Fb=function(A){ue(e,A);function e(t,r){var n=A.call(this,t,r)||this;return n._activeEffects=[],n.canvas=r.canvas?r.canvas:document.createElement("canvas"),n.ctx=n.canvas.getContext("2d"),r.canvas||(n.canvas.width=Math.floor(r.width*r.scale),n.canvas.height=Math.floor(r.height*r.scale),n.canvas.style.width=r.width+"px",n.canvas.style.height=r.height+"px"),n.fontMetrics=new Ub(document),n.ctx.scale(n.options.scale,n.options.scale),n.ctx.translate(-r.x,-r.y),n.ctx.textBaseline="bottom",n._activeEffects=[],n.context.logger.debug("Canvas renderer initialized ("+r.width+"x"+r.height+") with scale "+r.scale),n}return e.prototype.applyEffects=function(t){for(var r=this;this._activeEffects.length;)this.popEffect();t.forEach(function(n){return r.applyEffect(n)})},e.prototype.applyEffect=function(t){this.ctx.save(),hb(t)&&(this.ctx.globalAlpha=t.opacity),fb(t)&&(this.ctx.translate(t.offsetX,t.offsetY),this.ctx.transform(t.matrix[0],t.matrix[1],t.matrix[2],t.matrix[3],t.matrix[4],t.matrix[5]),this.ctx.translate(-t.offsetX,-t.offsetY)),Ll(t)&&(this.path(t.path),this.ctx.clip()),this._activeEffects.push(t)},e.prototype.popEffect=function(){this._activeEffects.pop(),this.ctx.restore()},e.prototype.renderStack=function(t){return kA(this,void 0,void 0,function(){var r;return DA(this,function(n){switch(n.label){case 0:return r=t.element.container.styles,r.isVisible()?[4,this.renderStackContent(t)]:[3,2];case 1:n.sent(),n.label=2;case 2:return[2]}})})},e.prototype.renderNode=function(t){return kA(this,void 0,void 0,function(){return DA(this,function(r){switch(r.label){case 0:if(bA(t.container.flags,16))debugger;return t.container.styles.isVisible()?[4,this.renderNodeBackgroundAndBorders(t)]:[3,3];case 1:return r.sent(),[4,this.renderNodeContent(t)];case 2:r.sent(),r.label=3;case 3:return[2]}})})},e.prototype.renderTextWithLetterSpacing=function(t,r,n){var a=this;if(r===0)this.ctx.fillText(t.text,t.bounds.left,t.bounds.top+n);else{var s=$s(t.text);s.reduce(function(u,o){return a.ctx.fillText(o,u,t.bounds.top+n),u+a.ctx.measureText(o).width},t.bounds.left)}},e.prototype.createFontStyle=function(t){var r=t.fontVariant.filter(function(s){return s==="normal"||s==="small-caps"}).join(""),n=Sb(t.fontFamily).join(", "),a=Tr(t.fontSize)?""+t.fontSize.number+t.fontSize.unit:t.fontSize.number+"px";return[[t.fontStyle,r,t.fontWeight,a,n].join(" "),n,a]},e.prototype.renderTextNode=function(t,r){return kA(this,void 0,void 0,function(){var n,a,s,u,o,c,f,h,d=this;return DA(this,function(m){return n=this.createFontStyle(r),a=n[0],s=n[1],u=n[2],this.ctx.font=a,this.ctx.direction=r.direction===1?"rtl":"ltr",this.ctx.textAlign="left",this.ctx.textBaseline="alphabetic",o=this.fontMetrics.getMetrics(s,u),c=o.baseline,f=o.middle,h=r.paintOrder,t.textBounds.forEach(function(C){h.forEach(function(T){switch(T){case 0:d.ctx.fillStyle=NA(r.color),d.renderTextWithLetterSpacing(C,r.letterSpacing,c);var F=r.textShadow;F.length&&C.text.trim().length&&(F.slice(0).reverse().forEach(function(Q){d.ctx.shadowColor=NA(Q.color),d.ctx.shadowOffsetX=Q.offsetX.number*d.options.scale,d.ctx.shadowOffsetY=Q.offsetY.number*d.options.scale,d.ctx.shadowBlur=Q.blur.number,d.renderTextWithLetterSpacing(C,r.letterSpacing,c)}),d.ctx.shadowColor="",d.ctx.shadowOffsetX=0,d.ctx.shadowOffsetY=0,d.ctx.shadowBlur=0),r.textDecorationLine.length&&(d.ctx.fillStyle=NA(r.textDecorationColor||r.color),r.textDecorationLine.forEach(function(Q){switch(Q){case 1:d.ctx.fillRect(C.bounds.left,Math.round(C.bounds.top+c),C.bounds.width,1);break;case 2:d.ctx.fillRect(C.bounds.left,Math.round(C.bounds.top),C.bounds.width,1);break;case 3:d.ctx.fillRect(C.bounds.left,Math.ceil(C.bounds.top+f),C.bounds.width,1);break}}));break;case 1:r.webkitTextStrokeWidth&&C.text.trim().length&&(d.ctx.strokeStyle=NA(r.webkitTextStrokeColor),d.ctx.lineWidth=r.webkitTextStrokeWidth,d.ctx.lineJoin=window.chrome?"miter":"round",d.ctx.strokeText(C.text,C.bounds.left,C.bounds.top+c)),d.ctx.strokeStyle="",d.ctx.lineWidth=0,d.ctx.lineJoin="miter";break}})}),[2]})})},e.prototype.renderReplacedElement=function(t,r,n){if(n&&t.intrinsicWidth>0&&t.intrinsicHeight>0){var a=ta(t),s=zn(r);this.path(s),this.ctx.save(),this.ctx.clip(),this.ctx.drawImage(n,0,0,t.intrinsicWidth,t.intrinsicHeight,a.left,a.top,a.width,a.height),this.ctx.restore()}},e.prototype.renderNodeContent=function(t){return kA(this,void 0,void 0,function(){var r,n,a,s,u,o,I,I,c,f,h,d,M,m,C,y,T,F,Q,I,H,M,y;return DA(this,function(p){switch(p.label){case 0:this.applyEffects(t.getEffects(4)),r=t.container,n=t.curves,a=r.styles,s=0,u=r.textNodes,p.label=1;case 1:return s<u.length?(o=u[s],[4,this.renderTextNode(o,a)]):[3,4];case 2:p.sent(),p.label=3;case 3:return s++,[3,1];case 4:if(!(r instanceof al))return[3,8];p.label=5;case 5:return p.trys.push([5,7,,8]),[4,this.context.cache.match(r.src)];case 6:return I=p.sent(),this.renderReplacedElement(r,n,I),[3,8];case 7:return p.sent(),this.context.logger.error("Error loading image "+r.src),[3,8];case 8:if(r instanceof sl&&this.renderReplacedElement(r,n,r.canvas),!(r instanceof il))return[3,12];p.label=9;case 9:return p.trys.push([9,11,,12]),[4,this.context.cache.match(r.svg)];case 10:return I=p.sent(),this.renderReplacedElement(r,n,I),[3,12];case 11:return p.sent(),this.context.logger.error("Error loading svg "+r.svg.substring(0,255)),[3,12];case 12:return r instanceof fl&&r.tree?(c=new e(this.context,{scale:this.options.scale,backgroundColor:r.backgroundColor,x:0,y:0,width:r.width,height:r.height}),[4,c.render(r.tree)]):[3,14];case 13:f=p.sent(),r.width&&r.height&&this.ctx.drawImage(f,0,0,r.width,r.height,r.bounds.left,r.bounds.top,r.bounds.width,r.bounds.height),p.label=14;case 14:if(r instanceof zs&&(h=Math.min(r.bounds.width,r.bounds.height),r.type===Yn?r.checked&&(this.ctx.save(),this.path([new x(r.bounds.left+h*.39363,r.bounds.top+h*.79),new x(r.bounds.left+h*.16,r.bounds.top+h*.5549),new x(r.bounds.left+h*.27347,r.bounds.top+h*.44071),new x(r.bounds.left+h*.39694,r.bounds.top+h*.5649),new x(r.bounds.left+h*.72983,r.bounds.top+h*.23),new x(r.bounds.left+h*.84,r.bounds.top+h*.34085),new x(r.bounds.left+h*.39363,r.bounds.top+h*.79)]),this.ctx.fillStyle=NA(ol),this.ctx.fill(),this.ctx.restore()):r.type===Xn&&r.checked&&(this.ctx.save(),this.ctx.beginPath(),this.ctx.arc(r.bounds.left+h/2,r.bounds.top+h/2,h/4,0,Math.PI*2,!0),this.ctx.fillStyle=NA(ol),this.ctx.fill(),this.ctx.restore())),Ib(r)&&r.value.length){switch(d=this.createFontStyle(a),M=d[0],m=d[1],C=this.fontMetrics.getMetrics(M,m).baseline,this.ctx.font=M,this.ctx.fillStyle=NA(a.color),this.ctx.textBaseline="alphabetic",this.ctx.textAlign=yb(r.styles.textAlign),y=ta(r),T=0,r.styles.textAlign){case 1:T+=y.width/2;break;case 2:T+=y.width;break}F=y.add(T,0,0,-y.height/2+1),this.ctx.save(),this.path([new x(y.left,y.top),new x(y.left+y.width,y.top),new x(y.left+y.width,y.top+y.height),new x(y.left,y.top+y.height)]),this.ctx.clip(),this.renderTextWithLetterSpacing(new Ir(r.value,F),a.letterSpacing,C),this.ctx.restore(),this.ctx.textBaseline="alphabetic",this.ctx.textAlign="left"}if(!bA(r.styles.display,2048))return[3,20];if(r.styles.listStyleImage===null)return[3,19];if(Q=r.styles.listStyleImage,Q.type!==0)return[3,18];I=void 0,H=Q.url,p.label=15;case 15:return p.trys.push([15,17,,18]),[4,this.context.cache.match(H)];case 16:return I=p.sent(),this.ctx.drawImage(I,r.bounds.left-(I.width+10),r.bounds.top),[3,18];case 17:return p.sent(),this.context.logger.error("Error loading list-style-image "+H),[3,18];case 18:return[3,20];case 19:t.listValue&&r.styles.listStyleType!==-1&&(M=this.createFontStyle(a)[0],this.ctx.font=M,this.ctx.fillStyle=NA(a.color),this.ctx.textBaseline="middle",this.ctx.textAlign="right",y=new be(r.bounds.left,r.bounds.top+uA(r.styles.paddingTop,r.bounds.width),r.bounds.width,kc(a.lineHeight,a.fontSize.number)/2+1),this.renderTextWithLetterSpacing(new Ir(t.listValue,y),a.letterSpacing,kc(a.lineHeight,a.fontSize.number)/2+2),this.ctx.textBaseline="bottom",this.ctx.textAlign="left"),p.label=20;case 20:return[2]}})})},e.prototype.renderStackContent=function(t){return kA(this,void 0,void 0,function(){var r,n,Q,a,s,Q,u,o,Q,c,f,Q,h,d,Q,m,C,Q,T,F,Q;return DA(this,function(I){switch(I.label){case 0:if(bA(t.element.container.flags,16))debugger;return[4,this.renderNodeBackgroundAndBorders(t.element)];case 1:I.sent(),r=0,n=t.negativeZIndex,I.label=2;case 2:return r<n.length?(Q=n[r],[4,this.renderStack(Q)]):[3,5];case 3:I.sent(),I.label=4;case 4:return r++,[3,2];case 5:return[4,this.renderNodeContent(t.element)];case 6:I.sent(),a=0,s=t.nonInlineLevel,I.label=7;case 7:return a<s.length?(Q=s[a],[4,this.renderNode(Q)]):[3,10];case 8:I.sent(),I.label=9;case 9:return a++,[3,7];case 10:u=0,o=t.nonPositionedFloats,I.label=11;case 11:return u<o.length?(Q=o[u],[4,this.renderStack(Q)]):[3,14];case 12:I.sent(),I.label=13;case 13:return u++,[3,11];case 14:c=0,f=t.nonPositionedInlineLevel,I.label=15;case 15:return c<f.length?(Q=f[c],[4,this.renderStack(Q)]):[3,18];case 16:I.sent(),I.label=17;case 17:return c++,[3,15];case 18:h=0,d=t.inlineLevel,I.label=19;case 19:return h<d.length?(Q=d[h],[4,this.renderNode(Q)]):[3,22];case 20:I.sent(),I.label=21;case 21:return h++,[3,19];case 22:m=0,C=t.zeroOrAutoZIndexOrTransformedOrOpacity,I.label=23;case 23:return m<C.length?(Q=C[m],[4,this.renderStack(Q)]):[3,26];case 24:I.sent(),I.label=25;case 25:return m++,[3,23];case 26:T=0,F=t.positiveZIndex,I.label=27;case 27:return T<F.length?(Q=F[T],[4,this.renderStack(Q)]):[3,30];case 28:I.sent(),I.label=29;case 29:return T++,[3,27];case 30:return[2]}})})},e.prototype.mask=function(t){this.ctx.beginPath(),this.ctx.moveTo(0,0),this.ctx.lineTo(this.canvas.width,0),this.ctx.lineTo(this.canvas.width,this.canvas.height),this.ctx.lineTo(0,this.canvas.height),this.ctx.lineTo(0,0),this.formatPath(t.slice(0).reverse()),this.ctx.closePath()},e.prototype.path=function(t){this.ctx.beginPath(),this.formatPath(t),this.ctx.closePath()},e.prototype.formatPath=function(t){var r=this;t.forEach(function(n,a){var s=re(n)?n.start:n;a===0?r.ctx.moveTo(s.x,s.y):r.ctx.lineTo(s.x,s.y),re(n)&&r.ctx.bezierCurveTo(n.startControl.x,n.startControl.y,n.endControl.x,n.endControl.y,n.end.x,n.end.y)})},e.prototype.renderRepeat=function(t,r,n,a){this.path(t),this.ctx.fillStyle=r,this.ctx.translate(n,a),this.ctx.fill(),this.ctx.translate(-n,-a)},e.prototype.resizeImage=function(t,r,n){var a;if(t.width===r&&t.height===n)return t;var s=(a=this.canvas.ownerDocument)!==null&&a!==void 0?a:document,u=s.createElement("canvas");u.width=Math.max(1,r),u.height=Math.max(1,n);var o=u.getContext("2d");return o.drawImage(t,0,0,t.width,t.height,0,0,r,n),u},e.prototype.renderBackgroundImage=function(t){return kA(this,void 0,void 0,function(){var r,n,a,s,u,o;return DA(this,function(c){switch(c.label){case 0:r=t.styles.backgroundImage.length-1,n=function(f){var h,d,m,AA,P,z,W,tA,k,C,AA,P,z,W,tA,T,F,Q,I,H,M,y,p,L,k,O,AA,oA,cA,W,tA,R,P,z,rA,lA,UA,HA,RA,QA,PA,wA;return DA(this,function(ce){switch(ce.label){case 0:if(f.type!==0)return[3,5];h=void 0,d=f.url,ce.label=1;case 1:return ce.trys.push([1,3,,4]),[4,a.context.cache.match(d)];case 2:return h=ce.sent(),[3,4];case 3:return ce.sent(),a.context.logger.error("Error loading background-image "+d),[3,4];case 4:return h&&(m=ci(t,r,[h.width,h.height,h.width/h.height]),AA=m[0],P=m[1],z=m[2],W=m[3],tA=m[4],k=a.ctx.createPattern(a.resizeImage(h,W,tA),"repeat"),a.renderRepeat(AA,k,P,z)),[3,6];case 5:f1(f)?(C=ci(t,r,[null,null,null]),AA=C[0],P=C[1],z=C[2],W=C[3],tA=C[4],T=i1(f.angle,W,tA),F=T[0],Q=T[1],I=T[2],H=T[3],M=T[4],y=document.createElement("canvas"),y.width=W,y.height=tA,p=y.getContext("2d"),L=p.createLinearGradient(Q,H,I,M),yc(f.stops,F).forEach(function(Xe){return L.addColorStop(Xe.stop,NA(Xe.color))}),p.fillStyle=L,p.fillRect(0,0,W,tA),W>0&&tA>0&&(k=a.ctx.createPattern(y,"repeat"),a.renderRepeat(AA,k,P,z))):h1(f)&&(O=ci(t,r,[null,null,null]),AA=O[0],oA=O[1],cA=O[2],W=O[3],tA=O[4],R=f.position.length===0?[Ds]:f.position,P=uA(R[0],W),z=uA(R[R.length-1],tA),rA=u1(f,P,z,W,tA),lA=rA[0],UA=rA[1],lA>0&&UA>0&&(HA=a.ctx.createRadialGradient(oA+P,cA+z,0,oA+P,cA+z,lA),yc(f.stops,lA*2).forEach(function(Xe){return HA.addColorStop(Xe.stop,NA(Xe.color))}),a.path(AA),a.ctx.fillStyle=HA,lA!==UA?(RA=t.bounds.left+.5*t.bounds.width,QA=t.bounds.top+.5*t.bounds.height,PA=UA/lA,wA=1/PA,a.ctx.save(),a.ctx.translate(RA,QA),a.ctx.transform(1,0,0,PA,0,0),a.ctx.translate(-RA,-QA),a.ctx.fillRect(oA,wA*(cA-QA)+QA,W,tA*wA),a.ctx.restore()):a.ctx.fill())),ce.label=6;case 6:return r--,[2]}})},a=this,s=0,u=t.styles.backgroundImage.slice(0).reverse(),c.label=1;case 1:return s<u.length?(o=u[s],[5,n(o)]):[3,4];case 2:c.sent(),c.label=3;case 3:return s++,[3,1];case 4:return[2]}})})},e.prototype.renderSolidBorder=function(t,r,n){return kA(this,void 0,void 0,function(){return DA(this,function(a){return this.path(Rl(n,r)),this.ctx.fillStyle=NA(t),this.ctx.fill(),[2]})})},e.prototype.renderDoubleBorder=function(t,r,n,a){return kA(this,void 0,void 0,function(){var s,u;return DA(this,function(o){switch(o.label){case 0:return r<3?[4,this.renderSolidBorder(t,n,a)]:[3,2];case 1:return o.sent(),[2];case 2:return s=gb(a,n),this.path(s),this.ctx.fillStyle=NA(t),this.ctx.fill(),u=Eb(a,n),this.path(u),this.ctx.fill(),[2]}})})},e.prototype.renderNodeBackgroundAndBorders=function(t){return kA(this,void 0,void 0,function(){var r,n,a,s,u,o,c,f,h=this;return DA(this,function(d){switch(d.label){case 0:return this.applyEffects(t.getEffects(2)),r=t.container.styles,n=!Ke(r.backgroundColor)||r.backgroundImage.length,a=[{style:r.borderTopStyle,color:r.borderTopColor,width:r.borderTopWidth},{style:r.borderRightStyle,color:r.borderRightColor,width:r.borderRightWidth},{style:r.borderBottomStyle,color:r.borderBottomColor,width:r.borderBottomWidth},{style:r.borderLeftStyle,color:r.borderLeftColor,width:r.borderLeftWidth}],s=_b(xt(r.backgroundClip,0),t.curves),n||r.boxShadow.length?(this.ctx.save(),this.path(s),this.ctx.clip(),Ke(r.backgroundColor)||(this.ctx.fillStyle=NA(r.backgroundColor),this.ctx.fill()),[4,this.renderBackgroundImage(t.container)]):[3,2];case 1:d.sent(),this.ctx.restore(),r.boxShadow.slice(0).reverse().forEach(function(m){h.ctx.save();var C=jn(t.curves),T=m.inset?0:Qb,F=db(C,-T+(m.inset?1:-1)*m.spread.number,(m.inset?1:-1)*m.spread.number,m.spread.number*(m.inset?-2:2),m.spread.number*(m.inset?-2:2));m.inset?(h.path(C),h.ctx.clip(),h.mask(F)):(h.mask(C),h.ctx.clip(),h.path(F)),h.ctx.shadowOffsetX=m.offsetX.number+T,h.ctx.shadowOffsetY=m.offsetY.number,h.ctx.shadowColor=NA(m.color),h.ctx.shadowBlur=m.blur.number,h.ctx.fillStyle=m.inset?NA(m.color):"rgba(0,0,0,1)",h.ctx.fill(),h.ctx.restore()}),d.label=2;case 2:u=0,o=0,c=a,d.label=3;case 3:return o<c.length?(f=c[o],f.style!==0&&!Ke(f.color)&&f.width>0?f.style!==2?[3,5]:[4,this.renderDashedDottedBorder(f.color,f.width,u,t.curves,2)]:[3,11]):[3,13];case 4:return d.sent(),[3,11];case 5:return f.style!==3?[3,7]:[4,this.renderDashedDottedBorder(f.color,f.width,u,t.curves,3)];case 6:return d.sent(),[3,11];case 7:return f.style!==4?[3,9]:[4,this.renderDoubleBorder(f.color,f.width,u,t.curves)];case 8:return d.sent(),[3,11];case 9:return[4,this.renderSolidBorder(f.color,u,t.curves)];case 10:d.sent(),d.label=11;case 11:u++,d.label=12;case 12:return o++,[3,3];case 13:return[2]}})})},e.prototype.renderDashedDottedBorder=function(t,r,n,a,s){return kA(this,void 0,void 0,function(){var u,o,c,f,h,d,m,C,T,F,Q,I,H,M,y,p,y,p;return DA(this,function(L){return this.ctx.save(),u=pb(a,n),o=Rl(a,n),s===2&&(this.path(o),this.ctx.clip()),re(o[0])?(c=o[0].start.x,f=o[0].start.y):(c=o[0].x,f=o[0].y),re(o[1])?(h=o[1].end.x,d=o[1].end.y):(h=o[1].x,d=o[1].y),n===0||n===2?m=Math.abs(c-h):m=Math.abs(f-d),this.ctx.beginPath(),s===3?this.formatPath(u):this.formatPath(o.slice(0,2)),C=r<3?r*3:r*2,T=r<3?r*2:r,s===3&&(C=r,T=r),F=!0,m<=C*2?F=!1:m<=C*2+T?(Q=m/(2*C+T),C*=Q,T*=Q):(I=Math.floor((m+T)/(C+T)),H=(m-I*C)/(I-1),M=(m-(I+1)*C)/I,T=M<=0||Math.abs(T-H)<Math.abs(T-M)?H:M),F&&(s===3?this.ctx.setLineDash([0,C+T]):this.ctx.setLineDash([C,T])),s===3?(this.ctx.lineCap="round",this.ctx.lineWidth=r):this.ctx.lineWidth=r*2+1.1,this.ctx.strokeStyle=NA(t),this.ctx.stroke(),this.ctx.setLineDash([]),s===2&&(re(o[0])&&(y=o[3],p=o[0],this.ctx.beginPath(),this.formatPath([new x(y.end.x,y.end.y),new x(p.start.x,p.start.y)]),this.ctx.stroke()),re(o[1])&&(y=o[1],p=o[2],this.ctx.beginPath(),this.formatPath([new x(y.end.x,y.end.y),new x(p.start.x,p.start.y)]),this.ctx.stroke())),this.ctx.restore(),[2]})})},e.prototype.render=function(t){return kA(this,void 0,void 0,function(){var r;return DA(this,function(n){switch(n.label){case 0:return this.options.backgroundColor&&(this.ctx.fillStyle=NA(this.options.backgroundColor),this.ctx.fillRect(this.options.x,this.options.y,this.options.width,this.options.height)),r=Bb(t),[4,this.renderStack(r)];case 1:return n.sent(),this.applyEffects([]),[2,this.canvas]}})})},e}(Pl),Ib=function(A){return A instanceof ll||A instanceof cl?!0:A instanceof zs&&A.type!==Xn&&A.type!==Yn},_b=function(A,e){switch(A){case 0:return jn(e);case 2:return ob(e);case 1:default:return zn(e)}},yb=function(A){switch(A){case 1:return"center";case 2:return"right";case 0:default:return"left"}},Nb=["-apple-system","system-ui"],Sb=function(A){return/iPhone OS 15_(0|1)/.test(window.navigator.userAgent)?A.filter(function(e){return Nb.indexOf(e)===-1}):A},vb=function(A){ue(e,A);function e(t,r){var n=A.call(this,t,r)||this;return n.canvas=r.canvas?r.canvas:document.createElement("canvas"),n.ctx=n.canvas.getContext("2d"),n.options=r,n.canvas.width=Math.floor(r.width*r.scale),n.canvas.height=Math.floor(r.height*r.scale),n.canvas.style.width=r.width+"px",n.canvas.style.height=r.height+"px",n.ctx.scale(n.options.scale,n.options.scale),n.ctx.translate(-r.x,-r.y),n.context.logger.debug("EXPERIMENTAL ForeignObject renderer initialized ("+r.width+"x"+r.height+" at "+r.x+","+r.y+") with scale "+r.scale),n}return e.prototype.render=function(t){return kA(this,void 0,void 0,function(){var r,n;return DA(this,function(a){switch(a.label){case 0:return r=Zs(this.options.width*this.options.scale,this.options.height*this.options.scale,this.options.scale,this.options.scale,t),[4,Lb(r)];case 1:return n=a.sent(),this.options.backgroundColor&&(this.ctx.fillStyle=NA(this.options.backgroundColor),this.ctx.fillRect(0,0,this.options.width*this.options.scale,this.options.height*this.options.scale)),this.ctx.drawImage(n,-this.options.x*this.options.scale,-this.options.y*this.options.scale),[2,this.canvas]}})})},e}(Pl),Lb=function(A){return new Promise(function(e,t){var r=new Image;r.onload=function(){e(r)},r.onerror=t,r.src="data:image/svg+xml;charset=utf-8,"+encodeURIComponent(new XMLSerializer().serializeToString(A))})},Hb=function(){function A(e){var t=e.id,r=e.enabled;this.id=t,this.enabled=r,this.start=Date.now()}return A.prototype.debug=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.enabled&&(typeof window<"u"&&window.console&&typeof console.debug=="function"?console.debug.apply(console,ln([this.id,this.getTime()+"ms"],e)):this.info.apply(this,e))},A.prototype.getTime=function(){return Date.now()-this.start},A.prototype.info=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.enabled&&typeof window<"u"&&window.console&&typeof console.info=="function"&&console.info.apply(console,ln([this.id,this.getTime()+"ms"],e))},A.prototype.warn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.enabled&&(typeof window<"u"&&window.console&&typeof console.warn=="function"?console.warn.apply(console,ln([this.id,this.getTime()+"ms"],e)):this.info.apply(this,e))},A.prototype.error=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.enabled&&(typeof window<"u"&&window.console&&typeof console.error=="function"?console.error.apply(console,ln([this.id,this.getTime()+"ms"],e)):this.info.apply(this,e))},A.instances={},A}(),xb=function(){function A(e,t){var r;this.windowBounds=t,this.instanceName="#"+A.instanceCount++,this.logger=new Hb({id:this.instanceName,enabled:e.logging}),this.cache=(r=e.cache)!==null&&r!==void 0?r:new eb(this,e)}return A.instanceCount=1,A}(),Db=function(A,e){return e===void 0&&(e={}),Ob(A,e)};typeof window<"u"&&vl.setContext(window);var Ob=function(A,e){return kA(void 0,void 0,void 0,function(){var t,r,n,a,s,u,o,c,f,h,d,m,C,T,F,Q,I,H,M,y,L,p,L,k,O,AA,oA,cA,W,tA,R,P,z,rA,lA,UA,HA,RA,QA,PA;return DA(this,function(wA){switch(wA.label){case 0:if(!A||typeof A!="object")return[2,Promise.reject("Invalid element provided as first argument")];if(t=A.ownerDocument,!t)throw new Error("Element is not attached to a Document");if(r=t.defaultView,!r)throw new Error("Document is not attached to a Window");return n={allowTaint:(k=e.allowTaint)!==null&&k!==void 0?k:!1,imageTimeout:(O=e.imageTimeout)!==null&&O!==void 0?O:15e3,proxy:e.proxy,useCORS:(AA=e.useCORS)!==null&&AA!==void 0?AA:!1},a=Bs({logging:(oA=e.logging)!==null&&oA!==void 0?oA:!0,cache:e.cache},n),s={windowWidth:(cA=e.windowWidth)!==null&&cA!==void 0?cA:r.innerWidth,windowHeight:(W=e.windowHeight)!==null&&W!==void 0?W:r.innerHeight,scrollX:(tA=e.scrollX)!==null&&tA!==void 0?tA:r.pageXOffset,scrollY:(R=e.scrollY)!==null&&R!==void 0?R:r.pageYOffset},u=new be(s.scrollX,s.scrollY,s.windowWidth,s.windowHeight),o=new xb(a,u),c=(P=e.foreignObjectRendering)!==null&&P!==void 0?P:!1,f={allowTaint:(z=e.allowTaint)!==null&&z!==void 0?z:!1,onclone:e.onclone,ignoreElements:e.ignoreElements,inlineImages:c,copyStyles:c},o.logger.debug("Starting document clone with size "+u.width+"x"+u.height+" scrolled to "+-u.left+","+-u.top),h=new Nl(o,A,f),d=h.clonedReferenceElement,d?[4,h.toIFrame(t,u)]:[2,Promise.reject("Unable to find element in cloned iframe")];case 1:return m=wA.sent(),C=ei(d)||RT(d)?dC(d.ownerDocument):fn(o,d),T=C.width,F=C.height,Q=C.left,I=C.top,H=Rb(o,d,e.backgroundColor),M={canvas:e.canvas,backgroundColor:H,scale:(lA=(rA=e.scale)!==null&&rA!==void 0?rA:r.devicePixelRatio)!==null&&lA!==void 0?lA:1,x:((UA=e.x)!==null&&UA!==void 0?UA:0)+Q,y:((HA=e.y)!==null&&HA!==void 0?HA:0)+I,width:(RA=e.width)!==null&&RA!==void 0?RA:Math.ceil(T),height:(QA=e.height)!==null&&QA!==void 0?QA:Math.ceil(F)},c?(o.logger.debug("Document cloned, using foreign object rendering"),L=new vb(o,M),[4,L.render(d)]):[3,3];case 2:return y=wA.sent(),[3,5];case 3:return o.logger.debug("Document cloned, element located at "+Q+","+I+" with size "+T+"x"+F+" using computed rendering"),o.logger.debug("Starting DOM parsing"),p=dl(o,d),H===p.styles.backgroundColor&&(p.styles.backgroundColor=Qe.TRANSPARENT),o.logger.debug("Starting renderer for element at "+M.x+","+M.y+" with size "+M.width+"x"+M.height),L=new Fb(o,M),[4,L.render(p)];case 4:y=wA.sent(),wA.label=5;case 5:return(!((PA=e.removeContainer)!==null&&PA!==void 0)||PA)&&(Nl.destroy(m)||o.logger.error("Cannot detach cloned iframe as it is not in the DOM anymore")),o.logger.debug("Finished rendering"),[2,y]}})})},Rb=function(A,e,t){var r=e.ownerDocument,n=r.documentElement?Ur(A,getComputedStyle(r.documentElement).backgroundColor):Qe.TRANSPARENT,a=r.body?Ur(A,getComputedStyle(r.body).backgroundColor):Qe.TRANSPARENT,s=typeof t=="string"?Ur(A,t):t===null?Qe.TRANSPARENT:4294967295;return e===r.documentElement?Ke(n)?Ke(a)?s:a:n:s};const Mb={class:"flex gp-dsigner"},kb={class:"flex items-center justify-between border-b"},Pb={key:0,class:"text-lg font-bold p-2"},Kb={class:"text-sm font-thin text-gray-500"},Vb=["innerHTML"],Gb=["innerHTML"],Yb={class:"flex-1"},Xb={key:0,class:"text-lg font-bold border-b p-2"},Wb={class:"p-2"},Jb={class:"sticky top-0"},qb={key:0,class:"text-lg font-bold border-b p-2"},Zb={class:"text-sm font-thin text-gray-500"},$b={class:"p-2"},Kl=At(l.defineComponent({__name:"Designer",props:{mode:{default:"design"},template:{},css:{},js:{},previewWidth:{default:375},uploadByFile:{},icons:{},rules:{},preview:{type:Boolean,default:!0},showTitle:{type:Boolean,default:!0}},emits:["update:modelValue","update:element"],setup(A,{expose:e,emit:t}){const r=A,n=t,a=l.ref(r.template),s=l.ref();let u=ao("",{},!1);const o=l.ref("");l.watch(()=>r.template,S=>{a.value=S},{immediate:!0}),l.watch(()=>a.value,S=>{S&&(s.value=O(S))},{immediate:!0}),l.watch(()=>r.css,S=>{S.forEach(v=>{if(document.querySelector(`link[href="${v}"]`))return;const K=document.createElement("link");K.rel="stylesheet",K.href=v,document.head.appendChild(K)})},{immediate:!0}),l.watch(()=>r.js,S=>{!S||S.length===0||S.forEach(v=>{if(document.querySelector(`script[src="${v}"]`))return;const K=document.createElement("script");K.src=v,document.body.appendChild(K)})},{immediate:!0});const c=l.ref(r.mode);l.watch(()=>s.value,S=>{S&&n("update:element",S)},{immediate:!0});const f=l.ref("");l.watch(()=>o.value,S=>{n("update:modelValue",S)},{immediate:!0});const h=l.ref(),d=l.ref(),m=l.ref(),C=l.ref(),T=l.ref(),F=l.ref(),Q=l.ref("");function I(S=void 0){C.value&&Db(C.value,{x:0,y:0,scrollX:window.scrollX,scrollY:window.scrollY,useCORS:!0,allowTaint:!0}).then(v=>{S&&typeof S=="function"?S(v):v.toBlob(K=>{const Y=URL.createObjectURL(K);window.open(Y,"_blank")}),q.success("生成封面成功")})}function H(S){T.value=S}function M(S,v=""){if(v){const K=y(s.value,v);K?F.value=K:F.value=S}else F.value=S}function y(S,v){if(S.xpath===v)return S;if(S.children&&S.children.length)for(const K of S.children){const Y=y(K,v);if(Y)return Y}}function p(S,v){var K,Y;return S.tag===v.tag&&((K=S.children)==null?void 0:K.length)===((Y=v.children)==null?void 0:Y.length)}function L(S){if(T.value.xpath==S.xpath){if(T.value){if(S.type===Z.Block){var v=!0;const K=y(s.value,T.value.parentxpath||"");if(K&&K.children&&K.children.forEach(Y=>{if(Y.tag!=T.value.tag||!p(Y,T.value)){v=!1;return}}),!v){q.error("同级结构不一致,错误配置!");return}}if(T.value.rule=S.rule,T.value.type=S.type,T.value.type===Z.Block){const K=y(s.value,T.value.parentxpath||"");K&&K.children&&(K.children.forEach(Y=>{if(Y.tag!=T.value.tag||!p(Y,T.value)){q.error("同级结构不一致,无法配置为块类型");return}}),K.children.forEach(Y=>{Y.tag===T.value.tag&&(Y.rule=S.rule,Y.type=S.type)}))}}f.value=new Date().getTime().toString(),q.success("保存成功")}}function k(S){o.value=S}function O(S){u=ao(S);const v=u("body").children().toArray().map(K=>AA(u(K)));return o.value=u("body").html()||"",v[0]}function AA(S,v=""){var ot;function K($A){if(!$A||!$A[0])return"";const JA=[];let ct=$A;for(;ct.length&&ct[0].tagName!=="html";){const Gl=ct[0].tagName,zb=ct.parent().children(Gl).index(ct)+1;JA.unshift(`${Gl}[${zb}]`),ct=ct.parent()}return"/html/"+JA.join("/")}const Y=K(S).replace("/html/body[1]",""),MA=S.children().toArray().map($A=>AA(u($A),Y)),Ce=(ot=r.rules)==null?void 0:ot.find($A=>$A.xpath===Y);return{tag:S[0].tagName,text:S.contents().not(S.children()).text().trim(),attrs:S[0].attribs,children:MA,xpath:Y,parentxpath:v,type:(Ce==null?void 0:Ce.type)||Z.None,rule:(Ce==null?void 0:Ce.rule)||{}}}function oA(S){console.log("更新子节点的文本",S);const v=y(s.value,S.element.xpath);if(v){const K=l.toRaw(v);K.editText=S.newText}}function cA(S,v=""){function K(Y,MA){var $A;const ot=(MA?(($A=y(s.value,MA))==null?void 0:$A.children)||[]:[s.value]).filter(JA=>JA.tag===Y.tag).indexOf(Y)+1;return`${MA}/${Y.tag}[${ot}]`}S.xpath=K(S,v),S.parentxpath=v,(S.children||[]).forEach(Y=>cA(Y,S.xpath))}function W({action:S,element:v,newBlock:K}){const Y=y(s.value,v.parentxpath||"");if(!Y||!Y.children)return;const MA=Y.children.findIndex(JA=>JA===v);if(MA===-1){q.error("未找到元素");return}const Ce=Y.children.length,{minBlock:ot,maxBlock:$A}=v.rule;if((S==="add"||S==="copy")&&Ce>=($A||1/0)){Q.value=`无法添加更多块。最大块数量为 ${$A}`,q.error(Q.value);return}switch(S){case"add":if(K){const JA={...K,xpath:"",children:JSON.parse(JSON.stringify(K.children))};Y.children.splice(MA+1,0,JA),q.success("添加成功")}break;case"copy":if(K){const JA={...K,xpath:"",children:JSON.parse(JSON.stringify(K.children))};Y.children.splice(MA+1,0,JA),q.success("复制成功")}break;case"moveUp":if(MA>0){const[JA]=Y.children.splice(MA,1);Y.children.splice(MA-1,0,JA),q.success("前移成功")}else q.error("已经是第一个块,无法前移");break;case"moveDown":if(MA<Y.children.length-1){const[JA]=Y.children.splice(MA,1);Y.children.splice(MA+1,0,JA),q.success("后移成功")}else q.error("已经是最后一个块,无法后移");break;case"delete":if(Ce<=(ot||0)){Q.value=`无法删除更多块。最小块数量为 ${ot}`,q.error(Q.value);return}Y.children.splice(MA,1),q.success("删除成功");break}Q.value="",cA(s.value)}function tA(S,v){let K=v.attrs.class.replace(/icon-\S+/g,`icon-${S}`);v.attrs.class=K}function R(S){const v=S.file,K=y(s.value,S.element.xpath);if(r.uploadByFile)r.uploadByFile(v).then(Y=>{Y.success&&(K.attrs.src=Y.file.url,f.value=new Date().getTime().toString())});else{K.attrs.alt=v.name;const Y=URL.createObjectURL(v);K.attrs.src=Y,f.value=new Date().getTime().toString()}}function P(S){const{icon:v}=S,K=y(s.value,S.element.xpath);let Y=K.attrs.class.replace(/icon-\S+/g,`icon-${v}`);K.attrs.class=Y,f.value=new Date().getTime().toString()}const z=S=>S.type.startsWith("image/")?!0:(q.error("只能上传图片文件"),!1),rA=l.ref({});function lA(S,v){if(!S||S.length===0)return;const K=S[0];if(v.rule&&(v.rule.minImageWidth||v.rule.maxImageHeight)){if(v.rule.minImageWidth&&K.width<v.rule.minImageWidth){q.error(`图片宽度不能小于 ${v.rule.minImageWidth}px`);return}if(v.rule.maxImageHeight&&K.height<v.rule.maxImageHeight){q.error(`图片高度不能小于 ${v.rule.maxImageHeight}px`);return}}v.rule.minImageWidth&&v.rule.maxImageHeight?(rA.value.width=v.rule.minImageWidth,rA.value.height=v.rule.maxImageHeight,rA.value.aspectRatio=v.rule.minImageWidth/v.rule.maxImageHeight):rA.value={},K&&(v.rule.crop?(K.thumbUrl,h.value.handleOpenCropper(rA.value,K.file,K.name,v)):r.uploadByFile?r.uploadByFile(K.file).then(Y=>{Y.success&&(v.attrs.src=Y.file.url,f.value=new Date().getTime().toString())}):(v.attrs.src=K.thumbUrl,f.value=new Date().getTime().toString()))}const UA=l.ref(r.previewWidth),HA=l.ref(375);let RA=l.ref(!1),QA=l.ref(""),PA=0,wA=0;function ce(S){QA.value=S,RA.value=!0,PA=event.clientX,S==="preview"?wA=UA.value:S==="structure"&&(wA=HA.value),window.addEventListener("mousemove",Xe),window.addEventListener("mouseup",Vl)}function Xe(S){if(!RA.value)return;const v=S.clientX-PA;QA.value==="preview"?UA.value=Math.max(200,wA+v):QA.value==="structure"&&(HA.value=Math.max(200,wA-v))}function Vl(){RA.value=!1,QA.value="",window.removeEventListener("mousemove",Xe),window.removeEventListener("mouseup",Vl)}return e({generateCover:I}),(S,v)=>(l.openBlock(),l.createElementBlock("div",Mb,[S.preview?(l.openBlock(),l.createElementBlock("div",{key:0,class:"border-l overflow-auto resize-area",style:l.normalizeStyle({width:UA.value+"px"})},[l.createElementVNode("div",kb,[S.showTitle?(l.openBlock(),l.createElementBlock("h2",Pb,[v[3]||(v[3]=l.createTextVNode(" 实时预览 ")),l.createElementVNode("span",Kb,l.toDisplayString(UA.value)+"px",1)])):l.createCommentVNode("",!0),l.createElementVNode("div",{onClick:v[0]||(v[0]=()=>I()),class:"p-2 cursor-pointer text-blue-500"}," 生成封面 ")]),l.createElementVNode("div",{ref_key:"previewRef",ref:C},[o.value?(l.openBlock(),l.createElementBlock("div",{key:0,innerHTML:o.value},null,8,Vb)):(l.openBlock(),l.createElementBlock("div",{key:1,innerHTML:l.unref(u)("body").html()},null,8,Gb))],512)],4)):l.createCommentVNode("",!0),S.preview?(l.openBlock(),l.createElementBlock("div",{key:1,class:"resizer",onMousedown:v[1]||(v[1]=K=>ce("preview"))},null,32)):l.createCommentVNode("",!0),l.createElementVNode("div",Yb,[S.showTitle?(l.openBlock(),l.createElementBlock("h2",Xb,"结构渲染")):l.createCommentVNode("",!0),l.createElementVNode("div",Wb,[s.value?(l.openBlock(),l.createBlock(nE,{key:0,"upload-by-file":S.uploadByFile,cropper:h.value,icon:d.value,upload:m.value,mode:S.mode,icons:S.icons,r:f.value,element:s.value,selectedElement:T.value,hoveredElement:F.value,onSelectElement:H,onHoverElement:M,onContentUpdated:k,onUpdateText:oA,onBlockAction:W,onAddIcon:tA},null,8,["upload-by-file","cropper","icon","upload","mode","icons","r","element","selectedElement","hoveredElement"])):l.createCommentVNode("",!0)])]),c.value=="design"?(l.openBlock(),l.createElementBlock("div",{key:2,class:"resizer",onMousedown:v[2]||(v[2]=K=>ce("structure"))},null,32)):l.createCommentVNode("",!0),c.value=="design"?(l.openBlock(),l.createElementBlock("div",{key:3,class:"resize-area",style:l.normalizeStyle({width:HA.value+"px"})},[l.createElementVNode("div",Jb,[S.showTitle?(l.openBlock(),l.createElementBlock("h2",qb,[v[4]||(v[4]=l.createTextVNode(" 节点属性 ")),l.createElementVNode("span",Zb,l.toDisplayString(HA.value)+"px",1)])):l.createCommentVNode("",!0),l.createElementVNode("div",$b,[T.value?(l.openBlock(),l.createBlock(OE,{key:0,element:T.value,onUpdateElement:L},null,8,["element"])):l.createCommentVNode("",!0)])])],4)):l.createCommentVNode("",!0),l.createVNode(Wp,{ref_key:"cropperRef",ref:h,onOk:R},null,512),l.createVNode(nC,{icons:S.icons,ref_key:"iconRef",ref:d,onOk:P},null,8,["icons"]),l.createVNode(hC,{ref_key:"uploadRef",ref:m,multiple:!1,show:!1,beforeUpload:z,onChange:lA},{"upload-icon":l.withCtx(()=>v[5]||(v[5]=[l.createElementVNode("div",{class:"p-2"},"上传",-1)])),_:1},512)]))}}),[["__scopeId","data-v-481f6863"]]),jb={install(A){A.component("Designer",Kl)}};Ie.Designer=Kl,Ie.default=jb,Object.defineProperties(Ie,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|
38
|
+
.`+si+jT+Sl)},Ab=function(A,e){var t=A.ownerDocument;if(t){var r=t.createElement("style");r.textContent=e,A.appendChild(r)}},vl=function(){function A(){}return A.getOrigin=function(e){var t=A._link;return t?(t.href=e,t.href=t.href,t.protocol+t.hostname+t.port):"about:blank"},A.isSameOrigin=function(e){return A.getOrigin(e)===A._origin},A.setContext=function(e){A._link=e.document.createElement("a"),A._origin=A.getOrigin(e.location.href)},A._origin="about:blank",A}(),eb=function(){function A(e,t){this.context=e,this._options=t,this._cache={}}return A.prototype.addImage=function(e){var t=Promise.resolve();return this.has(e)||(ui(e)||ab(e))&&(this._cache[e]=this.loadImage(e)).catch(function(){}),t},A.prototype.match=function(e){return this._cache[e]},A.prototype.loadImage=function(e){return kA(this,void 0,void 0,function(){var t,r,n,a,s=this;return DA(this,function(u){switch(u.label){case 0:return t=vl.isSameOrigin(e),r=!ii(e)&&this._options.useCORS===!0&&LA.SUPPORT_CORS_IMAGES&&!t,n=!ii(e)&&!t&&!ui(e)&&typeof this._options.proxy=="string"&&LA.SUPPORT_CORS_XHR&&!r,!t&&this._options.allowTaint===!1&&!ii(e)&&!ui(e)&&!n&&!r?[2]:(a=e,n?[4,this.proxy(a)]:[3,2]);case 1:a=u.sent(),u.label=2;case 2:return this.context.logger.debug("Added image "+e.substring(0,256)),[4,new Promise(function(o,c){var f=new Image;f.onload=function(){return o(f)},f.onerror=c,(sb(a)||r)&&(f.crossOrigin="anonymous"),f.src=a,f.complete===!0&&setTimeout(function(){return o(f)},500),s._options.imageTimeout>0&&setTimeout(function(){return c("Timed out ("+s._options.imageTimeout+"ms) loading image")},s._options.imageTimeout)})];case 3:return[2,u.sent()]}})})},A.prototype.has=function(e){return typeof this._cache[e]<"u"},A.prototype.keys=function(){return Promise.resolve(Object.keys(this._cache))},A.prototype.proxy=function(e){var t=this,r=this._options.proxy;if(!r)throw new Error("No proxy defined");var n=e.substring(0,256);return new Promise(function(a,s){var u=LA.SUPPORT_RESPONSE_TYPE?"blob":"text",o=new XMLHttpRequest;o.onload=function(){if(o.status===200)if(u==="text")a(o.response);else{var h=new FileReader;h.addEventListener("load",function(){return a(h.result)},!1),h.addEventListener("error",function(d){return s(d)},!1),h.readAsDataURL(o.response)}else s("Failed to proxy resource "+n+" with status code "+o.status)},o.onerror=s;var c=r.indexOf("?")>-1?"&":"?";if(o.open("GET",""+r+c+"url="+encodeURIComponent(e)+"&responseType="+u),u!=="text"&&o instanceof XMLHttpRequest&&(o.responseType=u),t._options.imageTimeout){var f=t._options.imageTimeout;o.timeout=f,o.ontimeout=function(){return s("Timed out ("+f+"ms) proxying "+n)}}o.send()})},A}(),tb=/^data:image\/svg\+xml/i,rb=/^data:image\/.*;base64,/i,nb=/^data:image\/.*/i,ab=function(A){return LA.SUPPORT_SVG_DRAWING||!ib(A)},ii=function(A){return nb.test(A)},sb=function(A){return rb.test(A)},ui=function(A){return A.substr(0,4)==="blob"},ib=function(A){return A.substr(-3).toLowerCase()==="svg"||tb.test(A)},x=function(){function A(e,t){this.type=0,this.x=e,this.y=t}return A.prototype.add=function(e,t){return new A(this.x+e,this.y+t)},A}(),Lt=function(A,e,t){return new x(A.x+(e.x-A.x)*t,A.y+(e.y-A.y)*t)},$n=function(){function A(e,t,r,n){this.type=1,this.start=e,this.startControl=t,this.endControl=r,this.end=n}return A.prototype.subdivide=function(e,t){var r=Lt(this.start,this.startControl,e),n=Lt(this.startControl,this.endControl,e),a=Lt(this.endControl,this.end,e),s=Lt(r,n,e),u=Lt(n,a,e),o=Lt(s,u,e);return t?new A(this.start,r,s,o):new A(o,u,a,this.end)},A.prototype.add=function(e,t){return new A(this.start.add(e,t),this.startControl.add(e,t),this.endControl.add(e,t),this.end.add(e,t))},A.prototype.reverse=function(){return new A(this.end,this.endControl,this.startControl,this.start)},A}(),re=function(A){return A.type===1},ub=function(){function A(e){var t=e.styles,r=e.bounds,n=br(t.borderTopLeftRadius,r.width,r.height),a=n[0],s=n[1],u=br(t.borderTopRightRadius,r.width,r.height),o=u[0],c=u[1],f=br(t.borderBottomRightRadius,r.width,r.height),h=f[0],d=f[1],m=br(t.borderBottomLeftRadius,r.width,r.height),C=m[0],T=m[1],F=[];F.push((a+o)/r.width),F.push((C+h)/r.width),F.push((s+T)/r.height),F.push((c+d)/r.height);var Q=Math.max.apply(Math,F);Q>1&&(a/=Q,s/=Q,o/=Q,c/=Q,h/=Q,d/=Q,C/=Q,T/=Q);var I=r.width-o,H=r.height-d,M=r.width-h,y=r.height-T,p=t.borderTopWidth,L=t.borderRightWidth,k=t.borderBottomWidth,O=t.borderLeftWidth,AA=uA(t.paddingTop,e.bounds.width),oA=uA(t.paddingRight,e.bounds.width),cA=uA(t.paddingBottom,e.bounds.width),W=uA(t.paddingLeft,e.bounds.width);this.topLeftBorderDoubleOuterBox=a>0||s>0?BA(r.left+O/3,r.top+p/3,a-O/3,s-p/3,aA.TOP_LEFT):new x(r.left+O/3,r.top+p/3),this.topRightBorderDoubleOuterBox=a>0||s>0?BA(r.left+I,r.top+p/3,o-L/3,c-p/3,aA.TOP_RIGHT):new x(r.left+r.width-L/3,r.top+p/3),this.bottomRightBorderDoubleOuterBox=h>0||d>0?BA(r.left+M,r.top+H,h-L/3,d-k/3,aA.BOTTOM_RIGHT):new x(r.left+r.width-L/3,r.top+r.height-k/3),this.bottomLeftBorderDoubleOuterBox=C>0||T>0?BA(r.left+O/3,r.top+y,C-O/3,T-k/3,aA.BOTTOM_LEFT):new x(r.left+O/3,r.top+r.height-k/3),this.topLeftBorderDoubleInnerBox=a>0||s>0?BA(r.left+O*2/3,r.top+p*2/3,a-O*2/3,s-p*2/3,aA.TOP_LEFT):new x(r.left+O*2/3,r.top+p*2/3),this.topRightBorderDoubleInnerBox=a>0||s>0?BA(r.left+I,r.top+p*2/3,o-L*2/3,c-p*2/3,aA.TOP_RIGHT):new x(r.left+r.width-L*2/3,r.top+p*2/3),this.bottomRightBorderDoubleInnerBox=h>0||d>0?BA(r.left+M,r.top+H,h-L*2/3,d-k*2/3,aA.BOTTOM_RIGHT):new x(r.left+r.width-L*2/3,r.top+r.height-k*2/3),this.bottomLeftBorderDoubleInnerBox=C>0||T>0?BA(r.left+O*2/3,r.top+y,C-O*2/3,T-k*2/3,aA.BOTTOM_LEFT):new x(r.left+O*2/3,r.top+r.height-k*2/3),this.topLeftBorderStroke=a>0||s>0?BA(r.left+O/2,r.top+p/2,a-O/2,s-p/2,aA.TOP_LEFT):new x(r.left+O/2,r.top+p/2),this.topRightBorderStroke=a>0||s>0?BA(r.left+I,r.top+p/2,o-L/2,c-p/2,aA.TOP_RIGHT):new x(r.left+r.width-L/2,r.top+p/2),this.bottomRightBorderStroke=h>0||d>0?BA(r.left+M,r.top+H,h-L/2,d-k/2,aA.BOTTOM_RIGHT):new x(r.left+r.width-L/2,r.top+r.height-k/2),this.bottomLeftBorderStroke=C>0||T>0?BA(r.left+O/2,r.top+y,C-O/2,T-k/2,aA.BOTTOM_LEFT):new x(r.left+O/2,r.top+r.height-k/2),this.topLeftBorderBox=a>0||s>0?BA(r.left,r.top,a,s,aA.TOP_LEFT):new x(r.left,r.top),this.topRightBorderBox=o>0||c>0?BA(r.left+I,r.top,o,c,aA.TOP_RIGHT):new x(r.left+r.width,r.top),this.bottomRightBorderBox=h>0||d>0?BA(r.left+M,r.top+H,h,d,aA.BOTTOM_RIGHT):new x(r.left+r.width,r.top+r.height),this.bottomLeftBorderBox=C>0||T>0?BA(r.left,r.top+y,C,T,aA.BOTTOM_LEFT):new x(r.left,r.top+r.height),this.topLeftPaddingBox=a>0||s>0?BA(r.left+O,r.top+p,Math.max(0,a-O),Math.max(0,s-p),aA.TOP_LEFT):new x(r.left+O,r.top+p),this.topRightPaddingBox=o>0||c>0?BA(r.left+Math.min(I,r.width-L),r.top+p,I>r.width+L?0:Math.max(0,o-L),Math.max(0,c-p),aA.TOP_RIGHT):new x(r.left+r.width-L,r.top+p),this.bottomRightPaddingBox=h>0||d>0?BA(r.left+Math.min(M,r.width-O),r.top+Math.min(H,r.height-k),Math.max(0,h-L),Math.max(0,d-k),aA.BOTTOM_RIGHT):new x(r.left+r.width-L,r.top+r.height-k),this.bottomLeftPaddingBox=C>0||T>0?BA(r.left+O,r.top+Math.min(y,r.height-k),Math.max(0,C-O),Math.max(0,T-k),aA.BOTTOM_LEFT):new x(r.left+O,r.top+r.height-k),this.topLeftContentBox=a>0||s>0?BA(r.left+O+W,r.top+p+AA,Math.max(0,a-(O+W)),Math.max(0,s-(p+AA)),aA.TOP_LEFT):new x(r.left+O+W,r.top+p+AA),this.topRightContentBox=o>0||c>0?BA(r.left+Math.min(I,r.width+O+W),r.top+p+AA,I>r.width+O+W?0:o-O+W,c-(p+AA),aA.TOP_RIGHT):new x(r.left+r.width-(L+oA),r.top+p+AA),this.bottomRightContentBox=h>0||d>0?BA(r.left+Math.min(M,r.width-(O+W)),r.top+Math.min(H,r.height+p+AA),Math.max(0,h-(L+oA)),d-(k+cA),aA.BOTTOM_RIGHT):new x(r.left+r.width-(L+oA),r.top+r.height-(k+cA)),this.bottomLeftContentBox=C>0||T>0?BA(r.left+O+W,r.top+y,Math.max(0,C-(O+W)),T-(k+cA),aA.BOTTOM_LEFT):new x(r.left+O+W,r.top+r.height-(k+cA))}return A}(),aA;(function(A){A[A.TOP_LEFT=0]="TOP_LEFT",A[A.TOP_RIGHT=1]="TOP_RIGHT",A[A.BOTTOM_RIGHT=2]="BOTTOM_RIGHT",A[A.BOTTOM_LEFT=3]="BOTTOM_LEFT"})(aA||(aA={}));var BA=function(A,e,t,r,n){var a=4*((Math.sqrt(2)-1)/3),s=t*a,u=r*a,o=A+t,c=e+r;switch(n){case aA.TOP_LEFT:return new $n(new x(A,c),new x(A,c-u),new x(o-s,e),new x(o,e));case aA.TOP_RIGHT:return new $n(new x(A,e),new x(A+s,e),new x(o,c-u),new x(o,c));case aA.BOTTOM_RIGHT:return new $n(new x(o,e),new x(o,e+u),new x(A+s,c),new x(A,c));case aA.BOTTOM_LEFT:default:return new $n(new x(o,c),new x(o-s,c),new x(A,e+u),new x(A,e))}},jn=function(A){return[A.topLeftBorderBox,A.topRightBorderBox,A.bottomRightBorderBox,A.bottomLeftBorderBox]},ob=function(A){return[A.topLeftContentBox,A.topRightContentBox,A.bottomRightContentBox,A.bottomLeftContentBox]},zn=function(A){return[A.topLeftPaddingBox,A.topRightPaddingBox,A.bottomRightPaddingBox,A.bottomLeftPaddingBox]},cb=function(){function A(e,t,r){this.offsetX=e,this.offsetY=t,this.matrix=r,this.type=0,this.target=6}return A}(),Aa=function(){function A(e,t){this.path=e,this.target=t,this.type=1}return A}(),lb=function(){function A(e){this.opacity=e,this.type=2,this.target=6}return A}(),fb=function(A){return A.type===0},Ll=function(A){return A.type===1},hb=function(A){return A.type===2},Hl=function(A,e){return A.length===e.length?A.some(function(t,r){return t===e[r]}):!1},db=function(A,e,t,r,n){return A.map(function(a,s){switch(s){case 0:return a.add(e,t);case 1:return a.add(e+r,t);case 2:return a.add(e+r,t+n);case 3:return a.add(e,t+n)}return a})},xl=function(){function A(e){this.element=e,this.inlineLevel=[],this.nonInlineLevel=[],this.negativeZIndex=[],this.zeroOrAutoZIndexOrTransformedOrOpacity=[],this.positiveZIndex=[],this.nonPositionedFloats=[],this.nonPositionedInlineLevel=[]}return A}(),Dl=function(){function A(e,t){if(this.container=e,this.parent=t,this.effects=[],this.curves=new ub(this.container),this.container.styles.opacity<1&&this.effects.push(new lb(this.container.styles.opacity)),this.container.styles.transform!==null){var r=this.container.bounds.left+this.container.styles.transformOrigin[0].number,n=this.container.bounds.top+this.container.styles.transformOrigin[1].number,a=this.container.styles.transform;this.effects.push(new cb(r,n,a))}if(this.container.styles.overflowX!==0){var s=jn(this.curves),u=zn(this.curves);Hl(s,u)?this.effects.push(new Aa(s,6)):(this.effects.push(new Aa(s,2)),this.effects.push(new Aa(u,4)))}}return A.prototype.getEffects=function(e){for(var t=[2,3].indexOf(this.container.styles.position)===-1,r=this.parent,n=this.effects.slice(0);r;){var a=r.effects.filter(function(o){return!Ll(o)});if(t||r.container.styles.position!==0||!r.parent){if(n.unshift.apply(n,a),t=[2,3].indexOf(r.container.styles.position)===-1,r.container.styles.overflowX!==0){var s=jn(r.curves),u=zn(r.curves);Hl(s,u)||n.unshift(new Aa(u,6))}}else n.unshift.apply(n,a);r=r.parent}return n.filter(function(o){return bA(o.target,e)})},A}(),oi=function(A,e,t,r){A.container.elements.forEach(function(n){var a=bA(n.flags,4),s=bA(n.flags,2),u=new Dl(n,A);bA(n.styles.display,2048)&&r.push(u);var o=bA(n.flags,8)?[]:r;if(a||s){var c=a||n.styles.isPositioned()?t:e,f=new xl(u);if(n.styles.isPositioned()||n.styles.opacity<1||n.styles.isTransformed()){var h=n.styles.zIndex.order;if(h<0){var d=0;c.negativeZIndex.some(function(C,T){return h>C.element.container.styles.zIndex.order?(d=T,!1):d>0}),c.negativeZIndex.splice(d,0,f)}else if(h>0){var m=0;c.positiveZIndex.some(function(C,T){return h>=C.element.container.styles.zIndex.order?(m=T+1,!1):m>0}),c.positiveZIndex.splice(m,0,f)}else c.zeroOrAutoZIndexOrTransformedOrOpacity.push(f)}else n.styles.isFloating()?c.nonPositionedFloats.push(f):c.nonPositionedInlineLevel.push(f);oi(u,f,a?f:t,o)}else n.styles.isInlineLevel()?e.inlineLevel.push(u):e.nonInlineLevel.push(u),oi(u,e,t,o);bA(n.flags,8)&&Ol(n,o)})},Ol=function(A,e){for(var t=A instanceof js?A.start:1,r=A instanceof js?A.reversed:!1,n=0;n<e.length;n++){var a=e[n];a.container instanceof ul&&typeof a.container.value=="number"&&a.container.value!==0&&(t=a.container.value),a.listValue=yr(t,a.container.styles.listStyleType,!0),t+=r?-1:1}},Bb=function(A){var e=new Dl(A,null),t=new xl(e),r=[];return oi(e,t,t,r),Ol(e.container,r),t},Rl=function(A,e){switch(e){case 0:return ne(A.topLeftBorderBox,A.topLeftPaddingBox,A.topRightBorderBox,A.topRightPaddingBox);case 1:return ne(A.topRightBorderBox,A.topRightPaddingBox,A.bottomRightBorderBox,A.bottomRightPaddingBox);case 2:return ne(A.bottomRightBorderBox,A.bottomRightPaddingBox,A.bottomLeftBorderBox,A.bottomLeftPaddingBox);case 3:default:return ne(A.bottomLeftBorderBox,A.bottomLeftPaddingBox,A.topLeftBorderBox,A.topLeftPaddingBox)}},gb=function(A,e){switch(e){case 0:return ne(A.topLeftBorderBox,A.topLeftBorderDoubleOuterBox,A.topRightBorderBox,A.topRightBorderDoubleOuterBox);case 1:return ne(A.topRightBorderBox,A.topRightBorderDoubleOuterBox,A.bottomRightBorderBox,A.bottomRightBorderDoubleOuterBox);case 2:return ne(A.bottomRightBorderBox,A.bottomRightBorderDoubleOuterBox,A.bottomLeftBorderBox,A.bottomLeftBorderDoubleOuterBox);case 3:default:return ne(A.bottomLeftBorderBox,A.bottomLeftBorderDoubleOuterBox,A.topLeftBorderBox,A.topLeftBorderDoubleOuterBox)}},Eb=function(A,e){switch(e){case 0:return ne(A.topLeftBorderDoubleInnerBox,A.topLeftPaddingBox,A.topRightBorderDoubleInnerBox,A.topRightPaddingBox);case 1:return ne(A.topRightBorderDoubleInnerBox,A.topRightPaddingBox,A.bottomRightBorderDoubleInnerBox,A.bottomRightPaddingBox);case 2:return ne(A.bottomRightBorderDoubleInnerBox,A.bottomRightPaddingBox,A.bottomLeftBorderDoubleInnerBox,A.bottomLeftPaddingBox);case 3:default:return ne(A.bottomLeftBorderDoubleInnerBox,A.bottomLeftPaddingBox,A.topLeftBorderDoubleInnerBox,A.topLeftPaddingBox)}},pb=function(A,e){switch(e){case 0:return ea(A.topLeftBorderStroke,A.topRightBorderStroke);case 1:return ea(A.topRightBorderStroke,A.bottomRightBorderStroke);case 2:return ea(A.bottomRightBorderStroke,A.bottomLeftBorderStroke);case 3:default:return ea(A.bottomLeftBorderStroke,A.topLeftBorderStroke)}},ea=function(A,e){var t=[];return re(A)?t.push(A.subdivide(.5,!1)):t.push(A),re(e)?t.push(e.subdivide(.5,!0)):t.push(e),t},ne=function(A,e,t,r){var n=[];return re(A)?n.push(A.subdivide(.5,!1)):n.push(A),re(t)?n.push(t.subdivide(.5,!0)):n.push(t),re(r)?n.push(r.subdivide(.5,!0).reverse()):n.push(r),re(e)?n.push(e.subdivide(.5,!1).reverse()):n.push(e),n},Ml=function(A){var e=A.bounds,t=A.styles;return e.add(t.borderLeftWidth,t.borderTopWidth,-(t.borderRightWidth+t.borderLeftWidth),-(t.borderTopWidth+t.borderBottomWidth))},ta=function(A){var e=A.styles,t=A.bounds,r=uA(e.paddingLeft,t.width),n=uA(e.paddingRight,t.width),a=uA(e.paddingTop,t.width),s=uA(e.paddingBottom,t.width);return t.add(r+e.borderLeftWidth,a+e.borderTopWidth,-(e.borderRightWidth+e.borderLeftWidth+r+n),-(e.borderTopWidth+e.borderBottomWidth+a+s))},Cb=function(A,e){return A===0?e.bounds:A===2?ta(e):Ml(e)},mb=function(A,e){return A===0?e.bounds:A===2?ta(e):Ml(e)},ci=function(A,e,t){var r=Cb(xt(A.styles.backgroundOrigin,e),A),n=mb(xt(A.styles.backgroundClip,e),A),a=wb(xt(A.styles.backgroundSize,e),t,r),s=a[0],u=a[1],o=br(xt(A.styles.backgroundPosition,e),r.width-s,r.height-u),c=Tb(xt(A.styles.backgroundRepeat,e),o,a,r,n),f=Math.round(r.left+o[0]),h=Math.round(r.top+o[1]);return[c,f,h,s,u]},Ht=function(A){return iA(A)&&A.value===yt.AUTO},ra=function(A){return typeof A=="number"},wb=function(A,e,t){var r=e[0],n=e[1],a=e[2],s=A[0],u=A[1];if(!s)return[0,0];if(mA(s)&&u&&mA(u))return[uA(s,t.width),uA(u,t.height)];var o=ra(a);if(iA(s)&&(s.value===yt.CONTAIN||s.value===yt.COVER)){if(ra(a)){var c=t.width/t.height;return c<a!=(s.value===yt.COVER)?[t.width,t.width/a]:[t.height*a,t.height]}return[t.width,t.height]}var f=ra(r),h=ra(n),d=f||h;if(Ht(s)&&(!u||Ht(u))){if(f&&h)return[r,n];if(!o&&!d)return[t.width,t.height];if(d&&o){var m=f?r:n*a,C=h?n:r/a;return[m,C]}var T=f?r:t.width,F=h?n:t.height;return[T,F]}if(o){var Q=0,I=0;return mA(s)?Q=uA(s,t.width):mA(u)&&(I=uA(u,t.height)),Ht(s)?Q=I*a:(!u||Ht(u))&&(I=Q/a),[Q,I]}var H=null,M=null;if(mA(s)?H=uA(s,t.width):u&&mA(u)&&(M=uA(u,t.height)),H!==null&&(!u||Ht(u))&&(M=f&&h?H/r*n:t.height),M!==null&&Ht(s)&&(H=f&&h?M/n*r:t.width),H!==null&&M!==null)return[H,M];throw new Error("Unable to calculate background-size for element")},xt=function(A,e){var t=A[e];return typeof t>"u"?A[0]:t},Tb=function(A,e,t,r,n){var a=e[0],s=e[1],u=t[0],o=t[1];switch(A){case 2:return[new x(Math.round(r.left),Math.round(r.top+s)),new x(Math.round(r.left+r.width),Math.round(r.top+s)),new x(Math.round(r.left+r.width),Math.round(o+r.top+s)),new x(Math.round(r.left),Math.round(o+r.top+s))];case 3:return[new x(Math.round(r.left+a),Math.round(r.top)),new x(Math.round(r.left+a+u),Math.round(r.top)),new x(Math.round(r.left+a+u),Math.round(r.height+r.top)),new x(Math.round(r.left+a),Math.round(r.height+r.top))];case 1:return[new x(Math.round(r.left+a),Math.round(r.top+s)),new x(Math.round(r.left+a+u),Math.round(r.top+s)),new x(Math.round(r.left+a+u),Math.round(r.top+s+o)),new x(Math.round(r.left+a),Math.round(r.top+s+o))];default:return[new x(Math.round(n.left),Math.round(n.top)),new x(Math.round(n.left+n.width),Math.round(n.top)),new x(Math.round(n.left+n.width),Math.round(n.height+n.top)),new x(Math.round(n.left),Math.round(n.height+n.top))]}},bb="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7",kl="Hidden Text",Ub=function(){function A(e){this._data={},this._document=e}return A.prototype.parseMetrics=function(e,t){var r=this._document.createElement("div"),n=this._document.createElement("img"),a=this._document.createElement("span"),s=this._document.body;r.style.visibility="hidden",r.style.fontFamily=e,r.style.fontSize=t,r.style.margin="0",r.style.padding="0",r.style.whiteSpace="nowrap",s.appendChild(r),n.src=bb,n.width=1,n.height=1,n.style.margin="0",n.style.padding="0",n.style.verticalAlign="baseline",a.style.fontFamily=e,a.style.fontSize=t,a.style.margin="0",a.style.padding="0",a.appendChild(this._document.createTextNode(kl)),r.appendChild(a),r.appendChild(n);var u=n.offsetTop-a.offsetTop+2;r.removeChild(a),r.appendChild(this._document.createTextNode(kl)),r.style.lineHeight="normal",n.style.verticalAlign="super";var o=n.offsetTop-r.offsetTop+2;return s.removeChild(r),{baseline:u,middle:o}},A.prototype.getMetrics=function(e,t){var r=e+" "+t;return typeof this._data[r]>"u"&&(this._data[r]=this.parseMetrics(e,t)),this._data[r]},A}(),Pl=function(){function A(e,t){this.context=e,this.options=t}return A}(),Qb=1e4,Fb=function(A){ue(e,A);function e(t,r){var n=A.call(this,t,r)||this;return n._activeEffects=[],n.canvas=r.canvas?r.canvas:document.createElement("canvas"),n.ctx=n.canvas.getContext("2d"),r.canvas||(n.canvas.width=Math.floor(r.width*r.scale),n.canvas.height=Math.floor(r.height*r.scale),n.canvas.style.width=r.width+"px",n.canvas.style.height=r.height+"px"),n.fontMetrics=new Ub(document),n.ctx.scale(n.options.scale,n.options.scale),n.ctx.translate(-r.x,-r.y),n.ctx.textBaseline="bottom",n._activeEffects=[],n.context.logger.debug("Canvas renderer initialized ("+r.width+"x"+r.height+") with scale "+r.scale),n}return e.prototype.applyEffects=function(t){for(var r=this;this._activeEffects.length;)this.popEffect();t.forEach(function(n){return r.applyEffect(n)})},e.prototype.applyEffect=function(t){this.ctx.save(),hb(t)&&(this.ctx.globalAlpha=t.opacity),fb(t)&&(this.ctx.translate(t.offsetX,t.offsetY),this.ctx.transform(t.matrix[0],t.matrix[1],t.matrix[2],t.matrix[3],t.matrix[4],t.matrix[5]),this.ctx.translate(-t.offsetX,-t.offsetY)),Ll(t)&&(this.path(t.path),this.ctx.clip()),this._activeEffects.push(t)},e.prototype.popEffect=function(){this._activeEffects.pop(),this.ctx.restore()},e.prototype.renderStack=function(t){return kA(this,void 0,void 0,function(){var r;return DA(this,function(n){switch(n.label){case 0:return r=t.element.container.styles,r.isVisible()?[4,this.renderStackContent(t)]:[3,2];case 1:n.sent(),n.label=2;case 2:return[2]}})})},e.prototype.renderNode=function(t){return kA(this,void 0,void 0,function(){return DA(this,function(r){switch(r.label){case 0:if(bA(t.container.flags,16))debugger;return t.container.styles.isVisible()?[4,this.renderNodeBackgroundAndBorders(t)]:[3,3];case 1:return r.sent(),[4,this.renderNodeContent(t)];case 2:r.sent(),r.label=3;case 3:return[2]}})})},e.prototype.renderTextWithLetterSpacing=function(t,r,n){var a=this;if(r===0)this.ctx.fillText(t.text,t.bounds.left,t.bounds.top+n);else{var s=$s(t.text);s.reduce(function(u,o){return a.ctx.fillText(o,u,t.bounds.top+n),u+a.ctx.measureText(o).width},t.bounds.left)}},e.prototype.createFontStyle=function(t){var r=t.fontVariant.filter(function(s){return s==="normal"||s==="small-caps"}).join(""),n=Sb(t.fontFamily).join(", "),a=Tr(t.fontSize)?""+t.fontSize.number+t.fontSize.unit:t.fontSize.number+"px";return[[t.fontStyle,r,t.fontWeight,a,n].join(" "),n,a]},e.prototype.renderTextNode=function(t,r){return kA(this,void 0,void 0,function(){var n,a,s,u,o,c,f,h,d=this;return DA(this,function(m){return n=this.createFontStyle(r),a=n[0],s=n[1],u=n[2],this.ctx.font=a,this.ctx.direction=r.direction===1?"rtl":"ltr",this.ctx.textAlign="left",this.ctx.textBaseline="alphabetic",o=this.fontMetrics.getMetrics(s,u),c=o.baseline,f=o.middle,h=r.paintOrder,t.textBounds.forEach(function(C){h.forEach(function(T){switch(T){case 0:d.ctx.fillStyle=NA(r.color),d.renderTextWithLetterSpacing(C,r.letterSpacing,c);var F=r.textShadow;F.length&&C.text.trim().length&&(F.slice(0).reverse().forEach(function(Q){d.ctx.shadowColor=NA(Q.color),d.ctx.shadowOffsetX=Q.offsetX.number*d.options.scale,d.ctx.shadowOffsetY=Q.offsetY.number*d.options.scale,d.ctx.shadowBlur=Q.blur.number,d.renderTextWithLetterSpacing(C,r.letterSpacing,c)}),d.ctx.shadowColor="",d.ctx.shadowOffsetX=0,d.ctx.shadowOffsetY=0,d.ctx.shadowBlur=0),r.textDecorationLine.length&&(d.ctx.fillStyle=NA(r.textDecorationColor||r.color),r.textDecorationLine.forEach(function(Q){switch(Q){case 1:d.ctx.fillRect(C.bounds.left,Math.round(C.bounds.top+c),C.bounds.width,1);break;case 2:d.ctx.fillRect(C.bounds.left,Math.round(C.bounds.top),C.bounds.width,1);break;case 3:d.ctx.fillRect(C.bounds.left,Math.ceil(C.bounds.top+f),C.bounds.width,1);break}}));break;case 1:r.webkitTextStrokeWidth&&C.text.trim().length&&(d.ctx.strokeStyle=NA(r.webkitTextStrokeColor),d.ctx.lineWidth=r.webkitTextStrokeWidth,d.ctx.lineJoin=window.chrome?"miter":"round",d.ctx.strokeText(C.text,C.bounds.left,C.bounds.top+c)),d.ctx.strokeStyle="",d.ctx.lineWidth=0,d.ctx.lineJoin="miter";break}})}),[2]})})},e.prototype.renderReplacedElement=function(t,r,n){if(n&&t.intrinsicWidth>0&&t.intrinsicHeight>0){var a=ta(t),s=zn(r);this.path(s),this.ctx.save(),this.ctx.clip(),this.ctx.drawImage(n,0,0,t.intrinsicWidth,t.intrinsicHeight,a.left,a.top,a.width,a.height),this.ctx.restore()}},e.prototype.renderNodeContent=function(t){return kA(this,void 0,void 0,function(){var r,n,a,s,u,o,I,I,c,f,h,d,M,m,C,y,T,F,Q,I,H,M,y;return DA(this,function(p){switch(p.label){case 0:this.applyEffects(t.getEffects(4)),r=t.container,n=t.curves,a=r.styles,s=0,u=r.textNodes,p.label=1;case 1:return s<u.length?(o=u[s],[4,this.renderTextNode(o,a)]):[3,4];case 2:p.sent(),p.label=3;case 3:return s++,[3,1];case 4:if(!(r instanceof al))return[3,8];p.label=5;case 5:return p.trys.push([5,7,,8]),[4,this.context.cache.match(r.src)];case 6:return I=p.sent(),this.renderReplacedElement(r,n,I),[3,8];case 7:return p.sent(),this.context.logger.error("Error loading image "+r.src),[3,8];case 8:if(r instanceof sl&&this.renderReplacedElement(r,n,r.canvas),!(r instanceof il))return[3,12];p.label=9;case 9:return p.trys.push([9,11,,12]),[4,this.context.cache.match(r.svg)];case 10:return I=p.sent(),this.renderReplacedElement(r,n,I),[3,12];case 11:return p.sent(),this.context.logger.error("Error loading svg "+r.svg.substring(0,255)),[3,12];case 12:return r instanceof fl&&r.tree?(c=new e(this.context,{scale:this.options.scale,backgroundColor:r.backgroundColor,x:0,y:0,width:r.width,height:r.height}),[4,c.render(r.tree)]):[3,14];case 13:f=p.sent(),r.width&&r.height&&this.ctx.drawImage(f,0,0,r.width,r.height,r.bounds.left,r.bounds.top,r.bounds.width,r.bounds.height),p.label=14;case 14:if(r instanceof zs&&(h=Math.min(r.bounds.width,r.bounds.height),r.type===Yn?r.checked&&(this.ctx.save(),this.path([new x(r.bounds.left+h*.39363,r.bounds.top+h*.79),new x(r.bounds.left+h*.16,r.bounds.top+h*.5549),new x(r.bounds.left+h*.27347,r.bounds.top+h*.44071),new x(r.bounds.left+h*.39694,r.bounds.top+h*.5649),new x(r.bounds.left+h*.72983,r.bounds.top+h*.23),new x(r.bounds.left+h*.84,r.bounds.top+h*.34085),new x(r.bounds.left+h*.39363,r.bounds.top+h*.79)]),this.ctx.fillStyle=NA(ol),this.ctx.fill(),this.ctx.restore()):r.type===Xn&&r.checked&&(this.ctx.save(),this.ctx.beginPath(),this.ctx.arc(r.bounds.left+h/2,r.bounds.top+h/2,h/4,0,Math.PI*2,!0),this.ctx.fillStyle=NA(ol),this.ctx.fill(),this.ctx.restore())),Ib(r)&&r.value.length){switch(d=this.createFontStyle(a),M=d[0],m=d[1],C=this.fontMetrics.getMetrics(M,m).baseline,this.ctx.font=M,this.ctx.fillStyle=NA(a.color),this.ctx.textBaseline="alphabetic",this.ctx.textAlign=yb(r.styles.textAlign),y=ta(r),T=0,r.styles.textAlign){case 1:T+=y.width/2;break;case 2:T+=y.width;break}F=y.add(T,0,0,-y.height/2+1),this.ctx.save(),this.path([new x(y.left,y.top),new x(y.left+y.width,y.top),new x(y.left+y.width,y.top+y.height),new x(y.left,y.top+y.height)]),this.ctx.clip(),this.renderTextWithLetterSpacing(new Ir(r.value,F),a.letterSpacing,C),this.ctx.restore(),this.ctx.textBaseline="alphabetic",this.ctx.textAlign="left"}if(!bA(r.styles.display,2048))return[3,20];if(r.styles.listStyleImage===null)return[3,19];if(Q=r.styles.listStyleImage,Q.type!==0)return[3,18];I=void 0,H=Q.url,p.label=15;case 15:return p.trys.push([15,17,,18]),[4,this.context.cache.match(H)];case 16:return I=p.sent(),this.ctx.drawImage(I,r.bounds.left-(I.width+10),r.bounds.top),[3,18];case 17:return p.sent(),this.context.logger.error("Error loading list-style-image "+H),[3,18];case 18:return[3,20];case 19:t.listValue&&r.styles.listStyleType!==-1&&(M=this.createFontStyle(a)[0],this.ctx.font=M,this.ctx.fillStyle=NA(a.color),this.ctx.textBaseline="middle",this.ctx.textAlign="right",y=new be(r.bounds.left,r.bounds.top+uA(r.styles.paddingTop,r.bounds.width),r.bounds.width,kc(a.lineHeight,a.fontSize.number)/2+1),this.renderTextWithLetterSpacing(new Ir(t.listValue,y),a.letterSpacing,kc(a.lineHeight,a.fontSize.number)/2+2),this.ctx.textBaseline="bottom",this.ctx.textAlign="left"),p.label=20;case 20:return[2]}})})},e.prototype.renderStackContent=function(t){return kA(this,void 0,void 0,function(){var r,n,Q,a,s,Q,u,o,Q,c,f,Q,h,d,Q,m,C,Q,T,F,Q;return DA(this,function(I){switch(I.label){case 0:if(bA(t.element.container.flags,16))debugger;return[4,this.renderNodeBackgroundAndBorders(t.element)];case 1:I.sent(),r=0,n=t.negativeZIndex,I.label=2;case 2:return r<n.length?(Q=n[r],[4,this.renderStack(Q)]):[3,5];case 3:I.sent(),I.label=4;case 4:return r++,[3,2];case 5:return[4,this.renderNodeContent(t.element)];case 6:I.sent(),a=0,s=t.nonInlineLevel,I.label=7;case 7:return a<s.length?(Q=s[a],[4,this.renderNode(Q)]):[3,10];case 8:I.sent(),I.label=9;case 9:return a++,[3,7];case 10:u=0,o=t.nonPositionedFloats,I.label=11;case 11:return u<o.length?(Q=o[u],[4,this.renderStack(Q)]):[3,14];case 12:I.sent(),I.label=13;case 13:return u++,[3,11];case 14:c=0,f=t.nonPositionedInlineLevel,I.label=15;case 15:return c<f.length?(Q=f[c],[4,this.renderStack(Q)]):[3,18];case 16:I.sent(),I.label=17;case 17:return c++,[3,15];case 18:h=0,d=t.inlineLevel,I.label=19;case 19:return h<d.length?(Q=d[h],[4,this.renderNode(Q)]):[3,22];case 20:I.sent(),I.label=21;case 21:return h++,[3,19];case 22:m=0,C=t.zeroOrAutoZIndexOrTransformedOrOpacity,I.label=23;case 23:return m<C.length?(Q=C[m],[4,this.renderStack(Q)]):[3,26];case 24:I.sent(),I.label=25;case 25:return m++,[3,23];case 26:T=0,F=t.positiveZIndex,I.label=27;case 27:return T<F.length?(Q=F[T],[4,this.renderStack(Q)]):[3,30];case 28:I.sent(),I.label=29;case 29:return T++,[3,27];case 30:return[2]}})})},e.prototype.mask=function(t){this.ctx.beginPath(),this.ctx.moveTo(0,0),this.ctx.lineTo(this.canvas.width,0),this.ctx.lineTo(this.canvas.width,this.canvas.height),this.ctx.lineTo(0,this.canvas.height),this.ctx.lineTo(0,0),this.formatPath(t.slice(0).reverse()),this.ctx.closePath()},e.prototype.path=function(t){this.ctx.beginPath(),this.formatPath(t),this.ctx.closePath()},e.prototype.formatPath=function(t){var r=this;t.forEach(function(n,a){var s=re(n)?n.start:n;a===0?r.ctx.moveTo(s.x,s.y):r.ctx.lineTo(s.x,s.y),re(n)&&r.ctx.bezierCurveTo(n.startControl.x,n.startControl.y,n.endControl.x,n.endControl.y,n.end.x,n.end.y)})},e.prototype.renderRepeat=function(t,r,n,a){this.path(t),this.ctx.fillStyle=r,this.ctx.translate(n,a),this.ctx.fill(),this.ctx.translate(-n,-a)},e.prototype.resizeImage=function(t,r,n){var a;if(t.width===r&&t.height===n)return t;var s=(a=this.canvas.ownerDocument)!==null&&a!==void 0?a:document,u=s.createElement("canvas");u.width=Math.max(1,r),u.height=Math.max(1,n);var o=u.getContext("2d");return o.drawImage(t,0,0,t.width,t.height,0,0,r,n),u},e.prototype.renderBackgroundImage=function(t){return kA(this,void 0,void 0,function(){var r,n,a,s,u,o;return DA(this,function(c){switch(c.label){case 0:r=t.styles.backgroundImage.length-1,n=function(f){var h,d,m,AA,P,z,W,tA,k,C,AA,P,z,W,tA,T,F,Q,I,H,M,y,p,L,k,O,AA,oA,cA,W,tA,R,P,z,rA,lA,UA,HA,RA,QA,PA,wA;return DA(this,function(ce){switch(ce.label){case 0:if(f.type!==0)return[3,5];h=void 0,d=f.url,ce.label=1;case 1:return ce.trys.push([1,3,,4]),[4,a.context.cache.match(d)];case 2:return h=ce.sent(),[3,4];case 3:return ce.sent(),a.context.logger.error("Error loading background-image "+d),[3,4];case 4:return h&&(m=ci(t,r,[h.width,h.height,h.width/h.height]),AA=m[0],P=m[1],z=m[2],W=m[3],tA=m[4],k=a.ctx.createPattern(a.resizeImage(h,W,tA),"repeat"),a.renderRepeat(AA,k,P,z)),[3,6];case 5:f1(f)?(C=ci(t,r,[null,null,null]),AA=C[0],P=C[1],z=C[2],W=C[3],tA=C[4],T=i1(f.angle,W,tA),F=T[0],Q=T[1],I=T[2],H=T[3],M=T[4],y=document.createElement("canvas"),y.width=W,y.height=tA,p=y.getContext("2d"),L=p.createLinearGradient(Q,H,I,M),yc(f.stops,F).forEach(function(Xe){return L.addColorStop(Xe.stop,NA(Xe.color))}),p.fillStyle=L,p.fillRect(0,0,W,tA),W>0&&tA>0&&(k=a.ctx.createPattern(y,"repeat"),a.renderRepeat(AA,k,P,z))):h1(f)&&(O=ci(t,r,[null,null,null]),AA=O[0],oA=O[1],cA=O[2],W=O[3],tA=O[4],R=f.position.length===0?[Ds]:f.position,P=uA(R[0],W),z=uA(R[R.length-1],tA),rA=u1(f,P,z,W,tA),lA=rA[0],UA=rA[1],lA>0&&UA>0&&(HA=a.ctx.createRadialGradient(oA+P,cA+z,0,oA+P,cA+z,lA),yc(f.stops,lA*2).forEach(function(Xe){return HA.addColorStop(Xe.stop,NA(Xe.color))}),a.path(AA),a.ctx.fillStyle=HA,lA!==UA?(RA=t.bounds.left+.5*t.bounds.width,QA=t.bounds.top+.5*t.bounds.height,PA=UA/lA,wA=1/PA,a.ctx.save(),a.ctx.translate(RA,QA),a.ctx.transform(1,0,0,PA,0,0),a.ctx.translate(-RA,-QA),a.ctx.fillRect(oA,wA*(cA-QA)+QA,W,tA*wA),a.ctx.restore()):a.ctx.fill())),ce.label=6;case 6:return r--,[2]}})},a=this,s=0,u=t.styles.backgroundImage.slice(0).reverse(),c.label=1;case 1:return s<u.length?(o=u[s],[5,n(o)]):[3,4];case 2:c.sent(),c.label=3;case 3:return s++,[3,1];case 4:return[2]}})})},e.prototype.renderSolidBorder=function(t,r,n){return kA(this,void 0,void 0,function(){return DA(this,function(a){return this.path(Rl(n,r)),this.ctx.fillStyle=NA(t),this.ctx.fill(),[2]})})},e.prototype.renderDoubleBorder=function(t,r,n,a){return kA(this,void 0,void 0,function(){var s,u;return DA(this,function(o){switch(o.label){case 0:return r<3?[4,this.renderSolidBorder(t,n,a)]:[3,2];case 1:return o.sent(),[2];case 2:return s=gb(a,n),this.path(s),this.ctx.fillStyle=NA(t),this.ctx.fill(),u=Eb(a,n),this.path(u),this.ctx.fill(),[2]}})})},e.prototype.renderNodeBackgroundAndBorders=function(t){return kA(this,void 0,void 0,function(){var r,n,a,s,u,o,c,f,h=this;return DA(this,function(d){switch(d.label){case 0:return this.applyEffects(t.getEffects(2)),r=t.container.styles,n=!Ke(r.backgroundColor)||r.backgroundImage.length,a=[{style:r.borderTopStyle,color:r.borderTopColor,width:r.borderTopWidth},{style:r.borderRightStyle,color:r.borderRightColor,width:r.borderRightWidth},{style:r.borderBottomStyle,color:r.borderBottomColor,width:r.borderBottomWidth},{style:r.borderLeftStyle,color:r.borderLeftColor,width:r.borderLeftWidth}],s=_b(xt(r.backgroundClip,0),t.curves),n||r.boxShadow.length?(this.ctx.save(),this.path(s),this.ctx.clip(),Ke(r.backgroundColor)||(this.ctx.fillStyle=NA(r.backgroundColor),this.ctx.fill()),[4,this.renderBackgroundImage(t.container)]):[3,2];case 1:d.sent(),this.ctx.restore(),r.boxShadow.slice(0).reverse().forEach(function(m){h.ctx.save();var C=jn(t.curves),T=m.inset?0:Qb,F=db(C,-T+(m.inset?1:-1)*m.spread.number,(m.inset?1:-1)*m.spread.number,m.spread.number*(m.inset?-2:2),m.spread.number*(m.inset?-2:2));m.inset?(h.path(C),h.ctx.clip(),h.mask(F)):(h.mask(C),h.ctx.clip(),h.path(F)),h.ctx.shadowOffsetX=m.offsetX.number+T,h.ctx.shadowOffsetY=m.offsetY.number,h.ctx.shadowColor=NA(m.color),h.ctx.shadowBlur=m.blur.number,h.ctx.fillStyle=m.inset?NA(m.color):"rgba(0,0,0,1)",h.ctx.fill(),h.ctx.restore()}),d.label=2;case 2:u=0,o=0,c=a,d.label=3;case 3:return o<c.length?(f=c[o],f.style!==0&&!Ke(f.color)&&f.width>0?f.style!==2?[3,5]:[4,this.renderDashedDottedBorder(f.color,f.width,u,t.curves,2)]:[3,11]):[3,13];case 4:return d.sent(),[3,11];case 5:return f.style!==3?[3,7]:[4,this.renderDashedDottedBorder(f.color,f.width,u,t.curves,3)];case 6:return d.sent(),[3,11];case 7:return f.style!==4?[3,9]:[4,this.renderDoubleBorder(f.color,f.width,u,t.curves)];case 8:return d.sent(),[3,11];case 9:return[4,this.renderSolidBorder(f.color,u,t.curves)];case 10:d.sent(),d.label=11;case 11:u++,d.label=12;case 12:return o++,[3,3];case 13:return[2]}})})},e.prototype.renderDashedDottedBorder=function(t,r,n,a,s){return kA(this,void 0,void 0,function(){var u,o,c,f,h,d,m,C,T,F,Q,I,H,M,y,p,y,p;return DA(this,function(L){return this.ctx.save(),u=pb(a,n),o=Rl(a,n),s===2&&(this.path(o),this.ctx.clip()),re(o[0])?(c=o[0].start.x,f=o[0].start.y):(c=o[0].x,f=o[0].y),re(o[1])?(h=o[1].end.x,d=o[1].end.y):(h=o[1].x,d=o[1].y),n===0||n===2?m=Math.abs(c-h):m=Math.abs(f-d),this.ctx.beginPath(),s===3?this.formatPath(u):this.formatPath(o.slice(0,2)),C=r<3?r*3:r*2,T=r<3?r*2:r,s===3&&(C=r,T=r),F=!0,m<=C*2?F=!1:m<=C*2+T?(Q=m/(2*C+T),C*=Q,T*=Q):(I=Math.floor((m+T)/(C+T)),H=(m-I*C)/(I-1),M=(m-(I+1)*C)/I,T=M<=0||Math.abs(T-H)<Math.abs(T-M)?H:M),F&&(s===3?this.ctx.setLineDash([0,C+T]):this.ctx.setLineDash([C,T])),s===3?(this.ctx.lineCap="round",this.ctx.lineWidth=r):this.ctx.lineWidth=r*2+1.1,this.ctx.strokeStyle=NA(t),this.ctx.stroke(),this.ctx.setLineDash([]),s===2&&(re(o[0])&&(y=o[3],p=o[0],this.ctx.beginPath(),this.formatPath([new x(y.end.x,y.end.y),new x(p.start.x,p.start.y)]),this.ctx.stroke()),re(o[1])&&(y=o[1],p=o[2],this.ctx.beginPath(),this.formatPath([new x(y.end.x,y.end.y),new x(p.start.x,p.start.y)]),this.ctx.stroke())),this.ctx.restore(),[2]})})},e.prototype.render=function(t){return kA(this,void 0,void 0,function(){var r;return DA(this,function(n){switch(n.label){case 0:return this.options.backgroundColor&&(this.ctx.fillStyle=NA(this.options.backgroundColor),this.ctx.fillRect(this.options.x,this.options.y,this.options.width,this.options.height)),r=Bb(t),[4,this.renderStack(r)];case 1:return n.sent(),this.applyEffects([]),[2,this.canvas]}})})},e}(Pl),Ib=function(A){return A instanceof ll||A instanceof cl?!0:A instanceof zs&&A.type!==Xn&&A.type!==Yn},_b=function(A,e){switch(A){case 0:return jn(e);case 2:return ob(e);case 1:default:return zn(e)}},yb=function(A){switch(A){case 1:return"center";case 2:return"right";case 0:default:return"left"}},Nb=["-apple-system","system-ui"],Sb=function(A){return/iPhone OS 15_(0|1)/.test(window.navigator.userAgent)?A.filter(function(e){return Nb.indexOf(e)===-1}):A},vb=function(A){ue(e,A);function e(t,r){var n=A.call(this,t,r)||this;return n.canvas=r.canvas?r.canvas:document.createElement("canvas"),n.ctx=n.canvas.getContext("2d"),n.options=r,n.canvas.width=Math.floor(r.width*r.scale),n.canvas.height=Math.floor(r.height*r.scale),n.canvas.style.width=r.width+"px",n.canvas.style.height=r.height+"px",n.ctx.scale(n.options.scale,n.options.scale),n.ctx.translate(-r.x,-r.y),n.context.logger.debug("EXPERIMENTAL ForeignObject renderer initialized ("+r.width+"x"+r.height+" at "+r.x+","+r.y+") with scale "+r.scale),n}return e.prototype.render=function(t){return kA(this,void 0,void 0,function(){var r,n;return DA(this,function(a){switch(a.label){case 0:return r=Zs(this.options.width*this.options.scale,this.options.height*this.options.scale,this.options.scale,this.options.scale,t),[4,Lb(r)];case 1:return n=a.sent(),this.options.backgroundColor&&(this.ctx.fillStyle=NA(this.options.backgroundColor),this.ctx.fillRect(0,0,this.options.width*this.options.scale,this.options.height*this.options.scale)),this.ctx.drawImage(n,-this.options.x*this.options.scale,-this.options.y*this.options.scale),[2,this.canvas]}})})},e}(Pl),Lb=function(A){return new Promise(function(e,t){var r=new Image;r.onload=function(){e(r)},r.onerror=t,r.src="data:image/svg+xml;charset=utf-8,"+encodeURIComponent(new XMLSerializer().serializeToString(A))})},Hb=function(){function A(e){var t=e.id,r=e.enabled;this.id=t,this.enabled=r,this.start=Date.now()}return A.prototype.debug=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.enabled&&(typeof window<"u"&&window.console&&typeof console.debug=="function"?console.debug.apply(console,ln([this.id,this.getTime()+"ms"],e)):this.info.apply(this,e))},A.prototype.getTime=function(){return Date.now()-this.start},A.prototype.info=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.enabled&&typeof window<"u"&&window.console&&typeof console.info=="function"&&console.info.apply(console,ln([this.id,this.getTime()+"ms"],e))},A.prototype.warn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.enabled&&(typeof window<"u"&&window.console&&typeof console.warn=="function"?console.warn.apply(console,ln([this.id,this.getTime()+"ms"],e)):this.info.apply(this,e))},A.prototype.error=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.enabled&&(typeof window<"u"&&window.console&&typeof console.error=="function"?console.error.apply(console,ln([this.id,this.getTime()+"ms"],e)):this.info.apply(this,e))},A.instances={},A}(),xb=function(){function A(e,t){var r;this.windowBounds=t,this.instanceName="#"+A.instanceCount++,this.logger=new Hb({id:this.instanceName,enabled:e.logging}),this.cache=(r=e.cache)!==null&&r!==void 0?r:new eb(this,e)}return A.instanceCount=1,A}(),Db=function(A,e){return e===void 0&&(e={}),Ob(A,e)};typeof window<"u"&&vl.setContext(window);var Ob=function(A,e){return kA(void 0,void 0,void 0,function(){var t,r,n,a,s,u,o,c,f,h,d,m,C,T,F,Q,I,H,M,y,L,p,L,k,O,AA,oA,cA,W,tA,R,P,z,rA,lA,UA,HA,RA,QA,PA;return DA(this,function(wA){switch(wA.label){case 0:if(!A||typeof A!="object")return[2,Promise.reject("Invalid element provided as first argument")];if(t=A.ownerDocument,!t)throw new Error("Element is not attached to a Document");if(r=t.defaultView,!r)throw new Error("Document is not attached to a Window");return n={allowTaint:(k=e.allowTaint)!==null&&k!==void 0?k:!1,imageTimeout:(O=e.imageTimeout)!==null&&O!==void 0?O:15e3,proxy:e.proxy,useCORS:(AA=e.useCORS)!==null&&AA!==void 0?AA:!1},a=Bs({logging:(oA=e.logging)!==null&&oA!==void 0?oA:!0,cache:e.cache},n),s={windowWidth:(cA=e.windowWidth)!==null&&cA!==void 0?cA:r.innerWidth,windowHeight:(W=e.windowHeight)!==null&&W!==void 0?W:r.innerHeight,scrollX:(tA=e.scrollX)!==null&&tA!==void 0?tA:r.pageXOffset,scrollY:(R=e.scrollY)!==null&&R!==void 0?R:r.pageYOffset},u=new be(s.scrollX,s.scrollY,s.windowWidth,s.windowHeight),o=new xb(a,u),c=(P=e.foreignObjectRendering)!==null&&P!==void 0?P:!1,f={allowTaint:(z=e.allowTaint)!==null&&z!==void 0?z:!1,onclone:e.onclone,ignoreElements:e.ignoreElements,inlineImages:c,copyStyles:c},o.logger.debug("Starting document clone with size "+u.width+"x"+u.height+" scrolled to "+-u.left+","+-u.top),h=new Nl(o,A,f),d=h.clonedReferenceElement,d?[4,h.toIFrame(t,u)]:[2,Promise.reject("Unable to find element in cloned iframe")];case 1:return m=wA.sent(),C=ei(d)||RT(d)?dC(d.ownerDocument):fn(o,d),T=C.width,F=C.height,Q=C.left,I=C.top,H=Rb(o,d,e.backgroundColor),M={canvas:e.canvas,backgroundColor:H,scale:(lA=(rA=e.scale)!==null&&rA!==void 0?rA:r.devicePixelRatio)!==null&&lA!==void 0?lA:1,x:((UA=e.x)!==null&&UA!==void 0?UA:0)+Q,y:((HA=e.y)!==null&&HA!==void 0?HA:0)+I,width:(RA=e.width)!==null&&RA!==void 0?RA:Math.ceil(T),height:(QA=e.height)!==null&&QA!==void 0?QA:Math.ceil(F)},c?(o.logger.debug("Document cloned, using foreign object rendering"),L=new vb(o,M),[4,L.render(d)]):[3,3];case 2:return y=wA.sent(),[3,5];case 3:return o.logger.debug("Document cloned, element located at "+Q+","+I+" with size "+T+"x"+F+" using computed rendering"),o.logger.debug("Starting DOM parsing"),p=dl(o,d),H===p.styles.backgroundColor&&(p.styles.backgroundColor=Qe.TRANSPARENT),o.logger.debug("Starting renderer for element at "+M.x+","+M.y+" with size "+M.width+"x"+M.height),L=new Fb(o,M),[4,L.render(p)];case 4:y=wA.sent(),wA.label=5;case 5:return(!((PA=e.removeContainer)!==null&&PA!==void 0)||PA)&&(Nl.destroy(m)||o.logger.error("Cannot detach cloned iframe as it is not in the DOM anymore")),o.logger.debug("Finished rendering"),[2,y]}})})},Rb=function(A,e,t){var r=e.ownerDocument,n=r.documentElement?Ur(A,getComputedStyle(r.documentElement).backgroundColor):Qe.TRANSPARENT,a=r.body?Ur(A,getComputedStyle(r.body).backgroundColor):Qe.TRANSPARENT,s=typeof t=="string"?Ur(A,t):t===null?Qe.TRANSPARENT:4294967295;return e===r.documentElement?Ke(n)?Ke(a)?s:a:n:s};const Mb={class:"flex gp-dsigner"},kb={key:0,class:"flex items-center justify-between border-b"},Pb={class:"text-lg font-bold p-2"},Kb={class:"text-sm font-thin text-gray-500"},Vb=["innerHTML"],Gb=["innerHTML"],Yb={class:"flex-1"},Xb={key:0,class:"text-lg font-bold border-b p-2"},Wb={class:"p-2"},Jb={class:"sticky top-0"},qb={key:0,class:"text-lg font-bold border-b p-2"},Zb={class:"text-sm font-thin text-gray-500"},$b={class:"p-2"},Kl=At(l.defineComponent({__name:"Designer",props:{mode:{default:"design"},template:{},css:{},js:{},previewWidth:{default:375},uploadByFile:{},icons:{},rules:{},preview:{type:Boolean,default:!0},showTitle:{type:Boolean,default:!0}},emits:["update:modelValue","update:element"],setup(A,{expose:e,emit:t}){const r=A,n=t,a=l.ref(r.template),s=l.ref();let u=ao("",{},!1);const o=l.ref("");l.watch(()=>r.template,S=>{a.value=S},{immediate:!0}),l.watch(()=>a.value,S=>{S&&(s.value=O(S))},{immediate:!0}),l.watch(()=>r.css,S=>{S.forEach(v=>{if(document.querySelector(`link[href="${v}"]`))return;const K=document.createElement("link");K.rel="stylesheet",K.href=v,document.head.appendChild(K)})},{immediate:!0}),l.watch(()=>r.js,S=>{!S||S.length===0||S.forEach(v=>{if(document.querySelector(`script[src="${v}"]`))return;const K=document.createElement("script");K.src=v,document.body.appendChild(K)})},{immediate:!0});const c=l.ref(r.mode);l.watch(()=>s.value,S=>{S&&n("update:element",S)},{immediate:!0});const f=l.ref("");l.watch(()=>o.value,S=>{n("update:modelValue",S)},{immediate:!0});const h=l.ref(),d=l.ref(),m=l.ref(),C=l.ref(),T=l.ref(),F=l.ref(),Q=l.ref("");function I(S=void 0){C.value&&Db(C.value,{x:0,y:0,scrollX:window.scrollX,scrollY:window.scrollY,useCORS:!0,allowTaint:!0}).then(v=>{S&&typeof S=="function"?S(v):v.toBlob(K=>{const Y=URL.createObjectURL(K);window.open(Y,"_blank")}),q.success("生成封面成功")})}function H(S){T.value=S}function M(S,v=""){if(v){const K=y(s.value,v);K?F.value=K:F.value=S}else F.value=S}function y(S,v){if(S.xpath===v)return S;if(S.children&&S.children.length)for(const K of S.children){const Y=y(K,v);if(Y)return Y}}function p(S,v){var K,Y;return S.tag===v.tag&&((K=S.children)==null?void 0:K.length)===((Y=v.children)==null?void 0:Y.length)}function L(S){if(T.value.xpath==S.xpath){if(T.value){if(S.type===Z.Block){var v=!0;const K=y(s.value,T.value.parentxpath||"");if(K&&K.children&&K.children.forEach(Y=>{if(Y.tag!=T.value.tag||!p(Y,T.value)){v=!1;return}}),!v){q.error("同级结构不一致,错误配置!");return}}if(T.value.rule=S.rule,T.value.type=S.type,T.value.type===Z.Block){const K=y(s.value,T.value.parentxpath||"");K&&K.children&&(K.children.forEach(Y=>{if(Y.tag!=T.value.tag||!p(Y,T.value)){q.error("同级结构不一致,无法配置为块类型");return}}),K.children.forEach(Y=>{Y.tag===T.value.tag&&(Y.rule=S.rule,Y.type=S.type)}))}}f.value=new Date().getTime().toString(),q.success("保存成功")}}function k(S){o.value=S}function O(S){u=ao(S);const v=u("body").children().toArray().map(K=>AA(u(K)));return o.value=u("body").html()||"",v[0]}function AA(S,v=""){var ot;function K($A){if(!$A||!$A[0])return"";const JA=[];let ct=$A;for(;ct.length&&ct[0].tagName!=="html";){const Gl=ct[0].tagName,zb=ct.parent().children(Gl).index(ct)+1;JA.unshift(`${Gl}[${zb}]`),ct=ct.parent()}return"/html/"+JA.join("/")}const Y=K(S).replace("/html/body[1]",""),MA=S.children().toArray().map($A=>AA(u($A),Y)),Ce=(ot=r.rules)==null?void 0:ot.find($A=>$A.xpath===Y);return{tag:S[0].tagName,text:S.contents().not(S.children()).text().trim(),attrs:S[0].attribs,children:MA,xpath:Y,parentxpath:v,type:(Ce==null?void 0:Ce.type)||Z.None,rule:(Ce==null?void 0:Ce.rule)||{}}}function oA(S){console.log("更新子节点的文本",S);const v=y(s.value,S.element.xpath);if(v){const K=l.toRaw(v);K.editText=S.newText}}function cA(S,v=""){function K(Y,MA){var $A;const ot=(MA?(($A=y(s.value,MA))==null?void 0:$A.children)||[]:[s.value]).filter(JA=>JA.tag===Y.tag).indexOf(Y)+1;return`${MA}/${Y.tag}[${ot}]`}S.xpath=K(S,v),S.parentxpath=v,(S.children||[]).forEach(Y=>cA(Y,S.xpath))}function W({action:S,element:v,newBlock:K}){const Y=y(s.value,v.parentxpath||"");if(!Y||!Y.children)return;const MA=Y.children.findIndex(JA=>JA===v);if(MA===-1){q.error("未找到元素");return}const Ce=Y.children.length,{minBlock:ot,maxBlock:$A}=v.rule;if((S==="add"||S==="copy")&&Ce>=($A||1/0)){Q.value=`无法添加更多块。最大块数量为 ${$A}`,q.error(Q.value);return}switch(S){case"add":if(K){const JA={...K,xpath:"",children:JSON.parse(JSON.stringify(K.children))};Y.children.splice(MA+1,0,JA),q.success("添加成功")}break;case"copy":if(K){const JA={...K,xpath:"",children:JSON.parse(JSON.stringify(K.children))};Y.children.splice(MA+1,0,JA),q.success("复制成功")}break;case"moveUp":if(MA>0){const[JA]=Y.children.splice(MA,1);Y.children.splice(MA-1,0,JA),q.success("前移成功")}else q.error("已经是第一个块,无法前移");break;case"moveDown":if(MA<Y.children.length-1){const[JA]=Y.children.splice(MA,1);Y.children.splice(MA+1,0,JA),q.success("后移成功")}else q.error("已经是最后一个块,无法后移");break;case"delete":if(Ce<=(ot||0)){Q.value=`无法删除更多块。最小块数量为 ${ot}`,q.error(Q.value);return}Y.children.splice(MA,1),q.success("删除成功");break}Q.value="",cA(s.value)}function tA(S,v){let K=v.attrs.class.replace(/icon-\S+/g,`icon-${S}`);v.attrs.class=K}function R(S){const v=S.file,K=y(s.value,S.element.xpath);if(r.uploadByFile)r.uploadByFile(v).then(Y=>{Y.success&&(K.attrs.src=Y.file.url,f.value=new Date().getTime().toString())});else{K.attrs.alt=v.name;const Y=URL.createObjectURL(v);K.attrs.src=Y,f.value=new Date().getTime().toString()}}function P(S){const{icon:v}=S,K=y(s.value,S.element.xpath);let Y=K.attrs.class.replace(/icon-\S+/g,`icon-${v}`);K.attrs.class=Y,f.value=new Date().getTime().toString()}const z=S=>S.type.startsWith("image/")?!0:(q.error("只能上传图片文件"),!1),rA=l.ref({});function lA(S,v){if(!S||S.length===0)return;const K=S[0];if(v.rule&&(v.rule.minImageWidth||v.rule.maxImageHeight)){if(v.rule.minImageWidth&&K.width<v.rule.minImageWidth){q.error(`图片宽度不能小于 ${v.rule.minImageWidth}px`);return}if(v.rule.maxImageHeight&&K.height<v.rule.maxImageHeight){q.error(`图片高度不能小于 ${v.rule.maxImageHeight}px`);return}}v.rule.minImageWidth&&v.rule.maxImageHeight?(rA.value.width=v.rule.minImageWidth,rA.value.height=v.rule.maxImageHeight,rA.value.aspectRatio=v.rule.minImageWidth/v.rule.maxImageHeight):rA.value={},K&&(v.rule.crop?(K.thumbUrl,h.value.handleOpenCropper(rA.value,K.file,K.name,v)):r.uploadByFile?r.uploadByFile(K.file).then(Y=>{Y.success&&(v.attrs.src=Y.file.url,f.value=new Date().getTime().toString())}):(v.attrs.src=K.thumbUrl,f.value=new Date().getTime().toString()))}const UA=l.ref(r.previewWidth),HA=l.ref(375);let RA=l.ref(!1),QA=l.ref(""),PA=0,wA=0;function ce(S){QA.value=S,RA.value=!0,PA=event.clientX,S==="preview"?wA=UA.value:S==="structure"&&(wA=HA.value),window.addEventListener("mousemove",Xe),window.addEventListener("mouseup",Vl)}function Xe(S){if(!RA.value)return;const v=S.clientX-PA;QA.value==="preview"?UA.value=Math.max(200,wA+v):QA.value==="structure"&&(HA.value=Math.max(200,wA-v))}function Vl(){RA.value=!1,QA.value="",window.removeEventListener("mousemove",Xe),window.removeEventListener("mouseup",Vl)}return e({generateCover:I}),(S,v)=>(l.openBlock(),l.createElementBlock("div",Mb,[S.preview?(l.openBlock(),l.createElementBlock("div",{key:0,class:"border-l overflow-auto resize-area",style:l.normalizeStyle({width:UA.value+"px"})},[S.showTitle?(l.openBlock(),l.createElementBlock("div",kb,[l.createElementVNode("h2",Pb,[v[3]||(v[3]=l.createTextVNode(" 实时预览 ")),l.createElementVNode("span",Kb,l.toDisplayString(UA.value)+"px",1)]),l.createElementVNode("div",{onClick:v[0]||(v[0]=()=>I()),class:"p-2 cursor-pointer text-blue-500"}," 生成封面 ")])):l.createCommentVNode("",!0),l.createElementVNode("div",{ref_key:"previewRef",ref:C},[o.value?(l.openBlock(),l.createElementBlock("div",{key:0,innerHTML:o.value},null,8,Vb)):(l.openBlock(),l.createElementBlock("div",{key:1,innerHTML:l.unref(u)("body").html()},null,8,Gb))],512)],4)):l.createCommentVNode("",!0),S.preview?(l.openBlock(),l.createElementBlock("div",{key:1,class:"resizer",onMousedown:v[1]||(v[1]=K=>ce("preview"))},null,32)):l.createCommentVNode("",!0),l.createElementVNode("div",Yb,[S.showTitle?(l.openBlock(),l.createElementBlock("h2",Xb,"结构渲染")):l.createCommentVNode("",!0),l.createElementVNode("div",Wb,[s.value?(l.openBlock(),l.createBlock(nE,{key:0,"upload-by-file":S.uploadByFile,cropper:h.value,icon:d.value,upload:m.value,mode:S.mode,icons:S.icons,r:f.value,element:s.value,selectedElement:T.value,hoveredElement:F.value,onSelectElement:H,onHoverElement:M,onContentUpdated:k,onUpdateText:oA,onBlockAction:W,onAddIcon:tA},null,8,["upload-by-file","cropper","icon","upload","mode","icons","r","element","selectedElement","hoveredElement"])):l.createCommentVNode("",!0)])]),c.value=="design"?(l.openBlock(),l.createElementBlock("div",{key:2,class:"resizer",onMousedown:v[2]||(v[2]=K=>ce("structure"))},null,32)):l.createCommentVNode("",!0),c.value=="design"?(l.openBlock(),l.createElementBlock("div",{key:3,class:"resize-area",style:l.normalizeStyle({width:HA.value+"px"})},[l.createElementVNode("div",Jb,[S.showTitle?(l.openBlock(),l.createElementBlock("h2",qb,[v[4]||(v[4]=l.createTextVNode(" 节点属性 ")),l.createElementVNode("span",Zb,l.toDisplayString(HA.value)+"px",1)])):l.createCommentVNode("",!0),l.createElementVNode("div",$b,[T.value?(l.openBlock(),l.createBlock(OE,{key:0,element:T.value,onUpdateElement:L},null,8,["element"])):l.createCommentVNode("",!0)])])],4)):l.createCommentVNode("",!0),l.createVNode(Wp,{ref_key:"cropperRef",ref:h,onOk:R},null,512),l.createVNode(nC,{icons:S.icons,ref_key:"iconRef",ref:d,onOk:P},null,8,["icons"]),l.createVNode(hC,{ref_key:"uploadRef",ref:m,multiple:!1,show:!1,beforeUpload:z,onChange:lA},{"upload-icon":l.withCtx(()=>v[5]||(v[5]=[l.createElementVNode("div",{class:"p-2"},"上传",-1)])),_:1},512)]))}}),[["__scopeId","data-v-3248e027"]]),jb={install(A){A.component("Designer",Kl)}};Ie.Designer=Kl,Ie.default=jb,Object.defineProperties(Ie,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|
package/dist/style.css
CHANGED
@@ -6,4 +6,4 @@
|
|
6
6
|
* Released under the MIT license
|
7
7
|
*
|
8
8
|
* Date: 2024-04-21T07:43:02.731Z
|
9
|
-
*/.cropper-container{direction:ltr;font-size:0;line-height:0;position:relative;touch-action:none;-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;user-select:none}.cropper-container img{backface-visibility:hidden;display:block;height:100%;image-orientation:0deg;max-height:none!important;max-width:none!important;min-height:0!important;min-width:0!important;width:100%}.cropper-wrap-box,.cropper-canvas,.cropper-drag-box,.cropper-crop-box,.cropper-modal{bottom:0;left:0;position:absolute;right:0;top:0}.cropper-wrap-box,.cropper-canvas{overflow:hidden}.cropper-drag-box{background-color:#fff;opacity:0}.cropper-modal{background-color:#000;opacity:.5}.cropper-view-box{display:block;height:100%;outline:1px solid #39f;outline-color:#3399ffbf;overflow:hidden;width:100%}.cropper-dashed{border:0 dashed #eee;display:block;opacity:.5;position:absolute}.cropper-dashed.dashed-h{border-bottom-width:1px;border-top-width:1px;height:calc(100% / 3);left:0;top:calc(100% / 3);width:100%}.cropper-dashed.dashed-v{border-left-width:1px;border-right-width:1px;height:100%;left:calc(100% / 3);top:0;width:calc(100% / 3)}.cropper-center{display:block;height:0;left:50%;opacity:.75;position:absolute;top:50%;width:0}.cropper-center:before,.cropper-center:after{background-color:#eee;content:" ";display:block;position:absolute}.cropper-center:before{height:1px;left:-3px;top:0;width:7px}.cropper-center:after{height:7px;left:0;top:-3px;width:1px}.cropper-face,.cropper-line,.cropper-point{display:block;height:100%;opacity:.1;position:absolute;width:100%}.cropper-face{background-color:#fff;left:0;top:0}.cropper-line{background-color:#39f}.cropper-line.line-e{cursor:ew-resize;right:-3px;top:0;width:5px}.cropper-line.line-n{cursor:ns-resize;height:5px;left:0;top:-3px}.cropper-line.line-w{cursor:ew-resize;left:-3px;top:0;width:5px}.cropper-line.line-s{bottom:-3px;cursor:ns-resize;height:5px;left:0}.cropper-point{background-color:#39f;height:5px;opacity:.75;width:5px}.cropper-point.point-e{cursor:ew-resize;margin-top:-3px;right:-3px;top:50%}.cropper-point.point-n{cursor:ns-resize;left:50%;margin-left:-3px;top:-3px}.cropper-point.point-w{cursor:ew-resize;left:-3px;margin-top:-3px;top:50%}.cropper-point.point-s{bottom:-3px;cursor:s-resize;left:50%;margin-left:-3px}.cropper-point.point-ne{cursor:nesw-resize;right:-3px;top:-3px}.cropper-point.point-nw{cursor:nwse-resize;left:-3px;top:-3px}.cropper-point.point-sw{bottom:-3px;cursor:nesw-resize;left:-3px}.cropper-point.point-se{bottom:-3px;cursor:nwse-resize;height:20px;opacity:1;right:-3px;width:20px}@media (min-width: 768px){.cropper-point.point-se{height:15px;width:15px}}@media (min-width: 992px){.cropper-point.point-se{height:10px;width:10px}}@media (min-width: 1200px){.cropper-point.point-se{height:5px;opacity:.75;width:5px}}.cropper-point.point-se:before{background-color:#39f;bottom:-50%;content:" ";display:block;height:200%;opacity:0;position:absolute;right:-50%;width:200%}.cropper-invisible{opacity:0}.cropper-bg{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAAA3NCSVQICAjb4U/gAAAABlBMVEXMzMz////TjRV2AAAACXBIWXMAAArrAAAK6wGCiw1aAAAAHHRFWHRTb2Z0d2FyZQBBZG9iZSBGaXJld29ya3MgQ1M26LyyjAAAABFJREFUCJlj+M/AgBVhF/0PAH6/D/HkDxOGAAAAAElFTkSuQmCC)}.cropper-hide{display:block;height:0;position:absolute;width:0}.cropper-hidden{display:none!important}.cropper-move{cursor:move}.cropper-crop{cursor:crosshair}.cropper-disabled .cropper-drag-box,.cropper-disabled .cropper-face,.cropper-disabled .cropper-line,.cropper-disabled .cropper-point{cursor:not-allowed}.before{position:relative;overflow:hidden}.before img{position:absolute}.upload-wrapper[data-v-08babff9]{max-width:500px}.file-list[data-v-08babff9]{max-height:300px;overflow-y:auto}.gp-dsigner[data-v-481f6863]{font-family:微软雅黑}.resize-area[data-v-481f6863]{transition:width .1s ease}.resizer[data-v-481f6863]{width:6px;background:#f0f0f0;cursor:col-resize;display:flex;justify-content:center;align-items:center;position:relative;z-index:1;-webkit-user-select:none;-moz-user-select:none;user-select:none}:root{--gp-designer-theme-color: #3574e6}.gp-designer-theme-text,.gp-designer-theme-icon{color:var(--gp-designer-theme-color)}.gp-designer-theme-button{background-color:var(--gp-designer-theme-color)}*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html,:host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]{display:none}.container{width:100%}@media (min-width: 640px){.container{max-width:640px}}@media (min-width: 768px){.container{max-width:768px}}@media (min-width: 1024px){.container{max-width:1024px}}@media (min-width: 1280px){.container{max-width:1280px}}@media (min-width: 1536px){.container{max-width:1536px}}.visible{visibility:visible}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.sticky{position:sticky}.inset-0{top:0;right:0;bottom:0;left:0}.bottom-4{bottom:1rem}.left-0{left:0}.left-1\/2{left:50%}.left-2{left:.5rem}.left-4{left:1rem}.right-4{right:1rem}.top-0{top:0}.top-1\/2{top:50%}.top-2{top:.5rem}.top-4{top:1rem}.z-10{z-index:10}.z-\[99999\]{z-index:99999}.m-2{margin:.5rem}.mx-1{margin-left:.25rem;margin-right:.25rem}.my-2{margin-top:.5rem;margin-bottom:.5rem}.mb-2{margin-bottom:.5rem}.ml-2{margin-left:.5rem}.ml-3{margin-left:.75rem}.ml-4{margin-left:1rem}.mr-2{margin-right:.5rem}.mt-1{margin-top:.25rem}.mt-2{margin-top:.5rem}.mt-3{margin-top:.75rem}.mt-4{margin-top:1rem}.mt-5{margin-top:1.25rem}.block{display:block}.flex{display:flex}.contents{display:contents}.hidden{display:none}.h-12{height:3rem}.h-20{height:5rem}.h-5{height:1.25rem}.h-\[100vh\]{height:100vh}.h-\[200px\]{height:200px}.h-\[300px\]{height:300px}.h-\[40px\]{height:40px}.h-full{height:100%}.max-h-\[500px\]{max-height:500px}.w-12{width:3rem}.w-5{width:1.25rem}.w-\[100vw\]{width:100vw}.w-\[110px\]{width:110px}.w-\[270px\]{width:270px}.w-\[300px\]{width:300px}.w-\[640px\]{width:640px}.w-\[700px\]{width:700px}.w-auto{width:auto}.w-full{width:100%}.flex-1{flex:1 1 0%}.flex-none{flex:none}.-translate-x-1\/2{--tw-translate-x: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-translate-y-1\/2{--tw-translate-y: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.cursor-auto{cursor:auto}.cursor-not-allowed{cursor:not-allowed}.cursor-pointer{cursor:pointer}.flex-row{flex-direction:row}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.flex-nowrap{flex-wrap:nowrap}.content-center{align-content:center}.items-start{align-items:flex-start}.items-center{align-items:center}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-2{gap:.5rem}.space-x-1>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(.25rem * var(--tw-space-x-reverse));margin-left:calc(.25rem * calc(1 - var(--tw-space-x-reverse)))}.space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(.5rem * var(--tw-space-x-reverse));margin-left:calc(.5rem * calc(1 - var(--tw-space-x-reverse)))}.space-x-4>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(1rem * var(--tw-space-x-reverse));margin-left:calc(1rem * calc(1 - var(--tw-space-x-reverse)))}.space-x-5>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(1.25rem * var(--tw-space-x-reverse));margin-left:calc(1.25rem * calc(1 - var(--tw-space-x-reverse)))}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-visible{overflow:visible}.overflow-y-auto{overflow-y:auto}.rounded{border-radius:.25rem}.rounded-lg{border-radius:.5rem}.rounded-sm{border-radius:.125rem}.border{border-width:1px}.border-2{border-width:2px}.border-b{border-bottom-width:1px}.border-l{border-left-width:1px}.border-t{border-top-width:1px}.border-dashed{border-style:dashed}.border-\[\#DEDEDE\]{--tw-border-opacity: 1;border-color:rgb(222 222 222 / var(--tw-border-opacity))}.border-blue-500{--tw-border-opacity: 1;border-color:rgb(59 130 246 / var(--tw-border-opacity))}.border-gray-200{--tw-border-opacity: 1;border-color:rgb(229 231 235 / var(--tw-border-opacity))}.border-green-500{--tw-border-opacity: 1;border-color:rgb(34 197 94 / var(--tw-border-opacity))}.border-red-500{--tw-border-opacity: 1;border-color:rgb(239 68 68 / var(--tw-border-opacity))}.bg-\[\#474AFF\]{--tw-bg-opacity: 1;background-color:rgb(71 74 255 / var(--tw-bg-opacity))}.bg-\[\#f4f8ff\]{--tw-bg-opacity: 1;background-color:rgb(244 248 255 / var(--tw-bg-opacity))}.bg-\[rgba\(0\,0\,0\,0\.7\)\]{background-color:#000000b3}.bg-black\/80{background-color:#000c}.bg-blue-100{--tw-bg-opacity: 1;background-color:rgb(219 234 254 / var(--tw-bg-opacity))}.bg-blue-500\/80{background-color:#3b82f6cc}.bg-blue-600{--tw-bg-opacity: 1;background-color:rgb(37 99 235 / var(--tw-bg-opacity))}.bg-gray-100{--tw-bg-opacity: 1;background-color:rgb(243 244 246 / var(--tw-bg-opacity))}.bg-gray-200{--tw-bg-opacity: 1;background-color:rgb(229 231 235 / var(--tw-bg-opacity))}.bg-gray-900{--tw-bg-opacity: 1;background-color:rgb(17 24 39 / var(--tw-bg-opacity))}.bg-green-100{--tw-bg-opacity: 1;background-color:rgb(220 252 231 / var(--tw-bg-opacity))}.bg-green-500{--tw-bg-opacity: 1;background-color:rgb(34 197 94 / var(--tw-bg-opacity))}.bg-green-500\/80{background-color:#22c55ecc}.bg-red-100{--tw-bg-opacity: 1;background-color:rgb(254 226 226 / var(--tw-bg-opacity))}.bg-red-50{--tw-bg-opacity: 1;background-color:rgb(254 242 242 / var(--tw-bg-opacity))}.bg-red-500\/80{background-color:#ef4444cc}.bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity))}.bg-yellow-100{--tw-bg-opacity: 1;background-color:rgb(254 249 195 / var(--tw-bg-opacity))}.bg-yellow-50{--tw-bg-opacity: 1;background-color:rgb(254 252 232 / var(--tw-bg-opacity))}.bg-opacity-50{--tw-bg-opacity: .5}.object-cover{-o-object-fit:cover;object-fit:cover}.p-1{padding:.25rem}.p-2{padding:.5rem}.p-3{padding:.75rem}.p-4{padding:1rem}.p-6{padding:1.5rem}.px-4{padding-left:1rem;padding-right:1rem}.px-6{padding-left:1.5rem;padding-right:1.5rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-4{padding-top:1rem;padding-bottom:1rem}.pb-8{padding-bottom:2rem}.pr-\[70px\]{padding-right:70px}.text-center{text-align:center}.text-4xl{font-size:2.25rem;line-height:2.5rem}.text-base{font-size:1rem;line-height:1.5rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xs{font-size:.75rem;line-height:1rem}.font-bold{font-weight:700}.font-medium{font-weight:500}.font-semibold{font-weight:600}.font-thin{font-weight:100}.text-\[\#333\]{--tw-text-opacity: 1;color:rgb(51 51 51 / var(--tw-text-opacity))}.text-\[\#666\]{--tw-text-opacity: 1;color:rgb(102 102 102 / var(--tw-text-opacity))}.text-\[\#999\]{--tw-text-opacity: 1;color:rgb(153 153 153 / var(--tw-text-opacity))}.text-blue-500{--tw-text-opacity: 1;color:rgb(59 130 246 / var(--tw-text-opacity))}.text-blue-800{--tw-text-opacity: 1;color:rgb(30 64 175 / var(--tw-text-opacity))}.text-gray-400{--tw-text-opacity: 1;color:rgb(156 163 175 / var(--tw-text-opacity))}.text-gray-50{--tw-text-opacity: 1;color:rgb(249 250 251 / var(--tw-text-opacity))}.text-gray-500{--tw-text-opacity: 1;color:rgb(107 114 128 / var(--tw-text-opacity))}.text-gray-700{--tw-text-opacity: 1;color:rgb(55 65 81 / var(--tw-text-opacity))}.text-green-500{--tw-text-opacity: 1;color:rgb(34 197 94 / var(--tw-text-opacity))}.text-green-800{--tw-text-opacity: 1;color:rgb(22 101 52 / var(--tw-text-opacity))}.text-red-500{--tw-text-opacity: 1;color:rgb(239 68 68 / var(--tw-text-opacity))}.text-red-800{--tw-text-opacity: 1;color:rgb(153 27 27 / var(--tw-text-opacity))}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity))}.text-yellow-500{--tw-text-opacity: 1;color:rgb(234 179 8 / var(--tw-text-opacity))}.text-yellow-800{--tw-text-opacity: 1;color:rgb(133 77 14 / var(--tw-text-opacity))}.opacity-0{opacity:0}.shadow-xl{--tw-shadow: 0 20px 25px -5px rgb(0 0 0 / .1), 0 8px 10px -6px rgb(0 0 0 / .1);--tw-shadow-colored: 0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.outline{outline-style:solid}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.hover\:border-blue-500:hover{--tw-border-opacity: 1;border-color:rgb(59 130 246 / var(--tw-border-opacity))}.hover\:border-gray-400:hover{--tw-border-opacity: 1;border-color:rgb(156 163 175 / var(--tw-border-opacity))}.hover\:bg-blue-700:hover{--tw-bg-opacity: 1;background-color:rgb(29 78 216 / var(--tw-bg-opacity))}.hover\:bg-gray-200:hover{--tw-bg-opacity: 1;background-color:rgb(229 231 235 / var(--tw-bg-opacity))}.hover\:text-gray-600:hover{--tw-text-opacity: 1;color:rgb(75 85 99 / var(--tw-text-opacity))}.hover\:text-gray-800:hover{--tw-text-opacity: 1;color:rgb(31 41 55 / var(--tw-text-opacity))}.hover\:underline:hover{text-decoration-line:underline}
|
9
|
+
*/.cropper-container{direction:ltr;font-size:0;line-height:0;position:relative;touch-action:none;-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;user-select:none}.cropper-container img{backface-visibility:hidden;display:block;height:100%;image-orientation:0deg;max-height:none!important;max-width:none!important;min-height:0!important;min-width:0!important;width:100%}.cropper-wrap-box,.cropper-canvas,.cropper-drag-box,.cropper-crop-box,.cropper-modal{bottom:0;left:0;position:absolute;right:0;top:0}.cropper-wrap-box,.cropper-canvas{overflow:hidden}.cropper-drag-box{background-color:#fff;opacity:0}.cropper-modal{background-color:#000;opacity:.5}.cropper-view-box{display:block;height:100%;outline:1px solid #39f;outline-color:#3399ffbf;overflow:hidden;width:100%}.cropper-dashed{border:0 dashed #eee;display:block;opacity:.5;position:absolute}.cropper-dashed.dashed-h{border-bottom-width:1px;border-top-width:1px;height:calc(100% / 3);left:0;top:calc(100% / 3);width:100%}.cropper-dashed.dashed-v{border-left-width:1px;border-right-width:1px;height:100%;left:calc(100% / 3);top:0;width:calc(100% / 3)}.cropper-center{display:block;height:0;left:50%;opacity:.75;position:absolute;top:50%;width:0}.cropper-center:before,.cropper-center:after{background-color:#eee;content:" ";display:block;position:absolute}.cropper-center:before{height:1px;left:-3px;top:0;width:7px}.cropper-center:after{height:7px;left:0;top:-3px;width:1px}.cropper-face,.cropper-line,.cropper-point{display:block;height:100%;opacity:.1;position:absolute;width:100%}.cropper-face{background-color:#fff;left:0;top:0}.cropper-line{background-color:#39f}.cropper-line.line-e{cursor:ew-resize;right:-3px;top:0;width:5px}.cropper-line.line-n{cursor:ns-resize;height:5px;left:0;top:-3px}.cropper-line.line-w{cursor:ew-resize;left:-3px;top:0;width:5px}.cropper-line.line-s{bottom:-3px;cursor:ns-resize;height:5px;left:0}.cropper-point{background-color:#39f;height:5px;opacity:.75;width:5px}.cropper-point.point-e{cursor:ew-resize;margin-top:-3px;right:-3px;top:50%}.cropper-point.point-n{cursor:ns-resize;left:50%;margin-left:-3px;top:-3px}.cropper-point.point-w{cursor:ew-resize;left:-3px;margin-top:-3px;top:50%}.cropper-point.point-s{bottom:-3px;cursor:s-resize;left:50%;margin-left:-3px}.cropper-point.point-ne{cursor:nesw-resize;right:-3px;top:-3px}.cropper-point.point-nw{cursor:nwse-resize;left:-3px;top:-3px}.cropper-point.point-sw{bottom:-3px;cursor:nesw-resize;left:-3px}.cropper-point.point-se{bottom:-3px;cursor:nwse-resize;height:20px;opacity:1;right:-3px;width:20px}@media (min-width: 768px){.cropper-point.point-se{height:15px;width:15px}}@media (min-width: 992px){.cropper-point.point-se{height:10px;width:10px}}@media (min-width: 1200px){.cropper-point.point-se{height:5px;opacity:.75;width:5px}}.cropper-point.point-se:before{background-color:#39f;bottom:-50%;content:" ";display:block;height:200%;opacity:0;position:absolute;right:-50%;width:200%}.cropper-invisible{opacity:0}.cropper-bg{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAAA3NCSVQICAjb4U/gAAAABlBMVEXMzMz////TjRV2AAAACXBIWXMAAArrAAAK6wGCiw1aAAAAHHRFWHRTb2Z0d2FyZQBBZG9iZSBGaXJld29ya3MgQ1M26LyyjAAAABFJREFUCJlj+M/AgBVhF/0PAH6/D/HkDxOGAAAAAElFTkSuQmCC)}.cropper-hide{display:block;height:0;position:absolute;width:0}.cropper-hidden{display:none!important}.cropper-move{cursor:move}.cropper-crop{cursor:crosshair}.cropper-disabled .cropper-drag-box,.cropper-disabled .cropper-face,.cropper-disabled .cropper-line,.cropper-disabled .cropper-point{cursor:not-allowed}.before{position:relative;overflow:hidden}.before img{position:absolute}.upload-wrapper[data-v-08babff9]{max-width:500px}.file-list[data-v-08babff9]{max-height:300px;overflow-y:auto}.gp-dsigner[data-v-3248e027]{font-family:微软雅黑}.resize-area[data-v-3248e027]{transition:width .1s ease}.resizer[data-v-3248e027]{width:6px;background:#f0f0f0;cursor:col-resize;display:flex;justify-content:center;align-items:center;position:relative;z-index:1;-webkit-user-select:none;-moz-user-select:none;user-select:none}:root{--gp-designer-theme-color: #3574e6}.gp-designer-theme-text,.gp-designer-theme-icon{color:var(--gp-designer-theme-color)}.gp-designer-theme-button{background-color:var(--gp-designer-theme-color)}*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html,:host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]{display:none}.container{width:100%}@media (min-width: 640px){.container{max-width:640px}}@media (min-width: 768px){.container{max-width:768px}}@media (min-width: 1024px){.container{max-width:1024px}}@media (min-width: 1280px){.container{max-width:1280px}}@media (min-width: 1536px){.container{max-width:1536px}}.visible{visibility:visible}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.sticky{position:sticky}.inset-0{top:0;right:0;bottom:0;left:0}.bottom-4{bottom:1rem}.left-0{left:0}.left-1\/2{left:50%}.left-2{left:.5rem}.left-4{left:1rem}.right-4{right:1rem}.top-0{top:0}.top-1\/2{top:50%}.top-2{top:.5rem}.top-4{top:1rem}.z-10{z-index:10}.z-\[99999\]{z-index:99999}.m-2{margin:.5rem}.mx-1{margin-left:.25rem;margin-right:.25rem}.my-2{margin-top:.5rem;margin-bottom:.5rem}.mb-2{margin-bottom:.5rem}.ml-2{margin-left:.5rem}.ml-3{margin-left:.75rem}.ml-4{margin-left:1rem}.mr-2{margin-right:.5rem}.mt-1{margin-top:.25rem}.mt-2{margin-top:.5rem}.mt-3{margin-top:.75rem}.mt-4{margin-top:1rem}.mt-5{margin-top:1.25rem}.block{display:block}.flex{display:flex}.contents{display:contents}.hidden{display:none}.h-12{height:3rem}.h-20{height:5rem}.h-5{height:1.25rem}.h-\[100vh\]{height:100vh}.h-\[200px\]{height:200px}.h-\[300px\]{height:300px}.h-\[40px\]{height:40px}.h-full{height:100%}.max-h-\[500px\]{max-height:500px}.w-12{width:3rem}.w-5{width:1.25rem}.w-\[100vw\]{width:100vw}.w-\[110px\]{width:110px}.w-\[270px\]{width:270px}.w-\[300px\]{width:300px}.w-\[640px\]{width:640px}.w-\[700px\]{width:700px}.w-auto{width:auto}.w-full{width:100%}.flex-1{flex:1 1 0%}.flex-none{flex:none}.-translate-x-1\/2{--tw-translate-x: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-translate-y-1\/2{--tw-translate-y: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.cursor-auto{cursor:auto}.cursor-not-allowed{cursor:not-allowed}.cursor-pointer{cursor:pointer}.flex-row{flex-direction:row}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.flex-nowrap{flex-wrap:nowrap}.content-center{align-content:center}.items-start{align-items:flex-start}.items-center{align-items:center}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-2{gap:.5rem}.space-x-1>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(.25rem * var(--tw-space-x-reverse));margin-left:calc(.25rem * calc(1 - var(--tw-space-x-reverse)))}.space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(.5rem * var(--tw-space-x-reverse));margin-left:calc(.5rem * calc(1 - var(--tw-space-x-reverse)))}.space-x-4>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(1rem * var(--tw-space-x-reverse));margin-left:calc(1rem * calc(1 - var(--tw-space-x-reverse)))}.space-x-5>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(1.25rem * var(--tw-space-x-reverse));margin-left:calc(1.25rem * calc(1 - var(--tw-space-x-reverse)))}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-visible{overflow:visible}.overflow-y-auto{overflow-y:auto}.rounded{border-radius:.25rem}.rounded-lg{border-radius:.5rem}.rounded-sm{border-radius:.125rem}.border{border-width:1px}.border-2{border-width:2px}.border-b{border-bottom-width:1px}.border-l{border-left-width:1px}.border-t{border-top-width:1px}.border-dashed{border-style:dashed}.border-\[\#DEDEDE\]{--tw-border-opacity: 1;border-color:rgb(222 222 222 / var(--tw-border-opacity))}.border-blue-500{--tw-border-opacity: 1;border-color:rgb(59 130 246 / var(--tw-border-opacity))}.border-gray-200{--tw-border-opacity: 1;border-color:rgb(229 231 235 / var(--tw-border-opacity))}.border-green-500{--tw-border-opacity: 1;border-color:rgb(34 197 94 / var(--tw-border-opacity))}.border-red-500{--tw-border-opacity: 1;border-color:rgb(239 68 68 / var(--tw-border-opacity))}.bg-\[\#474AFF\]{--tw-bg-opacity: 1;background-color:rgb(71 74 255 / var(--tw-bg-opacity))}.bg-\[\#f4f8ff\]{--tw-bg-opacity: 1;background-color:rgb(244 248 255 / var(--tw-bg-opacity))}.bg-\[rgba\(0\,0\,0\,0\.7\)\]{background-color:#000000b3}.bg-black\/80{background-color:#000c}.bg-blue-100{--tw-bg-opacity: 1;background-color:rgb(219 234 254 / var(--tw-bg-opacity))}.bg-blue-500\/80{background-color:#3b82f6cc}.bg-blue-600{--tw-bg-opacity: 1;background-color:rgb(37 99 235 / var(--tw-bg-opacity))}.bg-gray-100{--tw-bg-opacity: 1;background-color:rgb(243 244 246 / var(--tw-bg-opacity))}.bg-gray-200{--tw-bg-opacity: 1;background-color:rgb(229 231 235 / var(--tw-bg-opacity))}.bg-gray-900{--tw-bg-opacity: 1;background-color:rgb(17 24 39 / var(--tw-bg-opacity))}.bg-green-100{--tw-bg-opacity: 1;background-color:rgb(220 252 231 / var(--tw-bg-opacity))}.bg-green-500{--tw-bg-opacity: 1;background-color:rgb(34 197 94 / var(--tw-bg-opacity))}.bg-green-500\/80{background-color:#22c55ecc}.bg-red-100{--tw-bg-opacity: 1;background-color:rgb(254 226 226 / var(--tw-bg-opacity))}.bg-red-50{--tw-bg-opacity: 1;background-color:rgb(254 242 242 / var(--tw-bg-opacity))}.bg-red-500\/80{background-color:#ef4444cc}.bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity))}.bg-yellow-100{--tw-bg-opacity: 1;background-color:rgb(254 249 195 / var(--tw-bg-opacity))}.bg-yellow-50{--tw-bg-opacity: 1;background-color:rgb(254 252 232 / var(--tw-bg-opacity))}.bg-opacity-50{--tw-bg-opacity: .5}.object-cover{-o-object-fit:cover;object-fit:cover}.p-1{padding:.25rem}.p-2{padding:.5rem}.p-3{padding:.75rem}.p-4{padding:1rem}.p-6{padding:1.5rem}.px-4{padding-left:1rem;padding-right:1rem}.px-6{padding-left:1.5rem;padding-right:1.5rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-4{padding-top:1rem;padding-bottom:1rem}.pb-8{padding-bottom:2rem}.pr-\[70px\]{padding-right:70px}.text-center{text-align:center}.text-4xl{font-size:2.25rem;line-height:2.5rem}.text-base{font-size:1rem;line-height:1.5rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xs{font-size:.75rem;line-height:1rem}.font-bold{font-weight:700}.font-medium{font-weight:500}.font-semibold{font-weight:600}.font-thin{font-weight:100}.text-\[\#333\]{--tw-text-opacity: 1;color:rgb(51 51 51 / var(--tw-text-opacity))}.text-\[\#666\]{--tw-text-opacity: 1;color:rgb(102 102 102 / var(--tw-text-opacity))}.text-\[\#999\]{--tw-text-opacity: 1;color:rgb(153 153 153 / var(--tw-text-opacity))}.text-blue-500{--tw-text-opacity: 1;color:rgb(59 130 246 / var(--tw-text-opacity))}.text-blue-800{--tw-text-opacity: 1;color:rgb(30 64 175 / var(--tw-text-opacity))}.text-gray-400{--tw-text-opacity: 1;color:rgb(156 163 175 / var(--tw-text-opacity))}.text-gray-50{--tw-text-opacity: 1;color:rgb(249 250 251 / var(--tw-text-opacity))}.text-gray-500{--tw-text-opacity: 1;color:rgb(107 114 128 / var(--tw-text-opacity))}.text-gray-700{--tw-text-opacity: 1;color:rgb(55 65 81 / var(--tw-text-opacity))}.text-green-500{--tw-text-opacity: 1;color:rgb(34 197 94 / var(--tw-text-opacity))}.text-green-800{--tw-text-opacity: 1;color:rgb(22 101 52 / var(--tw-text-opacity))}.text-red-500{--tw-text-opacity: 1;color:rgb(239 68 68 / var(--tw-text-opacity))}.text-red-800{--tw-text-opacity: 1;color:rgb(153 27 27 / var(--tw-text-opacity))}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity))}.text-yellow-500{--tw-text-opacity: 1;color:rgb(234 179 8 / var(--tw-text-opacity))}.text-yellow-800{--tw-text-opacity: 1;color:rgb(133 77 14 / var(--tw-text-opacity))}.opacity-0{opacity:0}.shadow-xl{--tw-shadow: 0 20px 25px -5px rgb(0 0 0 / .1), 0 8px 10px -6px rgb(0 0 0 / .1);--tw-shadow-colored: 0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.outline{outline-style:solid}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.hover\:border-blue-500:hover{--tw-border-opacity: 1;border-color:rgb(59 130 246 / var(--tw-border-opacity))}.hover\:border-gray-400:hover{--tw-border-opacity: 1;border-color:rgb(156 163 175 / var(--tw-border-opacity))}.hover\:bg-blue-700:hover{--tw-bg-opacity: 1;background-color:rgb(29 78 216 / var(--tw-bg-opacity))}.hover\:bg-gray-200:hover{--tw-bg-opacity: 1;background-color:rgb(229 231 235 / var(--tw-bg-opacity))}.hover\:text-gray-600:hover{--tw-text-opacity: 1;color:rgb(75 85 99 / var(--tw-text-opacity))}.hover\:text-gray-800:hover{--tw-text-opacity: 1;color:rgb(31 41 55 / var(--tw-text-opacity))}.hover\:underline:hover{text-decoration-line:underline}
|