@nocobase/portal-template-default 1.0.15 → 1.0.16
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/assets/{LineDraw-iG-ADes-.js → LineDraw-vPRTWiQ5.js} +1 -1
- package/dist/assets/{SymbolDraw-DXoSw1tM.js → SymbolDraw-DOl_Tss3.js} +1 -1
- package/dist/assets/{VisualMapping-C_ee4Eht.js → VisualMapping-j08W3KBm.js} +1 -1
- package/dist/assets/{auth-method-demo-DaOCuvsq.js → auth-method-demo-B2qcpY8z.js} +1 -1
- package/dist/assets/auto-login-provider-BMtzvdxG.js +1 -0
- package/dist/assets/{auto-login-provider-5Uxza9Ms.js → auto-login-provider-Bukw7zEe.js} +2 -2
- package/dist/assets/auto-redirect-provider-C6GNPg5r.js +1 -0
- package/dist/assets/auto-redirect-provider-D5c6kN2R.js +1 -0
- package/dist/assets/{auto-redirect-provider-CfwRvYOI.js → auto-redirect-provider-iTzGEDpU.js} +1 -1
- package/dist/assets/{calendar-DjDRfD5t.js → calendar-Dv2RNnsr.js} +1 -1
- package/dist/assets/{card-DuQBOS6A.js → card-C9Hpeq1c.js} +1 -1
- package/dist/assets/{cas-sign-in-button-CyqG1QME.js → cas-sign-in-button-BQn3Mttx.js} +1 -1
- package/dist/assets/{components-D-ptYjX_.js → components-BT5mL9gW.js} +1 -1
- package/dist/assets/{configuration-gate-C08mkkiX.js → configuration-gate-BJoadoA6.js} +1 -1
- package/dist/assets/{createClipPathFromCoordSys-wj34-b1B.js → createClipPathFromCoordSys-m8IbnJ1z.js} +1 -1
- package/dist/assets/createSeriesDataSimply-DKUV5b5e.js +1 -0
- package/dist/assets/{customGraphicKeyframeAnimation-DWrhrHL_.js → customGraphicKeyframeAnimation-CYLPurwK.js} +1 -1
- package/dist/assets/{demo-DkIhyiRK.js → demo-BWGOwqtJ.js} +1 -1
- package/dist/assets/{demo-D4OiKplc.js → demo-BWbcvkya.js} +1 -1
- package/dist/assets/{demo-BYWHeKUe.js → demo-DIASSPgn.js} +1 -1
- package/dist/assets/{demo-DBueJg0m.js → demo-DuZ6asUU.js} +1 -1
- package/dist/assets/{demo-CPWoNtx8.js → demo-Dxcy4bDE.js} +1 -1
- package/dist/assets/{demo-CyvJk5zV.js → demo-YpEC76uw.js} +1 -1
- package/dist/assets/{demo-tpTjO0sC.js → demo-wzkoR8T2.js} +1 -1
- package/dist/assets/{dingtalk-sign-in-button-DSWsSruv.js → dingtalk-sign-in-button-DSluFaP9.js} +1 -1
- package/dist/assets/{echarts-preview-DxHNfq1C.js → echarts-preview-mRXoEciY.js} +1 -1
- package/dist/assets/{echarts-runtime-D8kXn6ME.js → echarts-runtime-CvLr4Slh.js} +3 -3
- package/dist/assets/{echarts-runtime-advanced-QY8v95qK.js → echarts-runtime-advanced-BC1tvfQ0.js} +1 -1
- package/dist/assets/{echarts-runtime-common-D-yqAK-r.js → echarts-runtime-common-DhNaV5B8.js} +1 -1
- package/dist/assets/{echarts-runtime-components-P4-i8jPU.js → echarts-runtime-components-BiioS8t1.js} +1 -1
- package/dist/assets/{echarts-runtime-hierarchy-ByQZ-DbP.js → echarts-runtime-hierarchy-CAWqYvFh.js} +1 -1
- package/dist/assets/{floating-BFVEyPEp.js → floating-RVbHvIiD.js} +1 -1
- package/dist/assets/{index-um5hdKdZ.js → index-BysibBZu.js} +1 -1
- package/dist/assets/{index-CwNxd66J.js → index-C-tdHirk.js} +1 -1
- package/dist/assets/{index-gFtCXH3o.js → index-CBZbj45X.js} +1 -1
- package/dist/assets/index-CgkdZ6Oc.js +686 -0
- package/dist/assets/{index-Btk35Nx-.js → index-Dw20Lzpp.js} +3 -3
- package/dist/assets/{index-BgCbGDMc.js → index-hSBzW-VA.js} +1 -1
- package/dist/assets/{labelHelper-DQqRy3a_.js → labelHelper-DbITmOUW.js} +1 -1
- package/dist/assets/{ldap-sign-in-form--6Gt3yGq.js → ldap-sign-in-form-BOMNDTkK.js} +1 -1
- package/dist/assets/{oidc-sign-in-button-CQdRcR_p.js → oidc-sign-in-button-Cgpa8Qzj.js} +1 -1
- package/dist/assets/{page-context-CnQ4GYM7.js → page-context-AU6RU0Qi.js} +4 -4
- package/dist/assets/prompt-card-FWugRgi-.js +1 -0
- package/dist/assets/{prompt-output-DZHRM2ft.js → prompt-output-DMTuTNab.js} +1 -1
- package/dist/assets/{saml-sign-in-button-BHL5a0JV.js → saml-sign-in-button-qt8bMeoQ.js} +1 -1
- package/dist/assets/{sectorHelper-DN_Vv6OL.js → sectorHelper-C6L782Ue.js} +1 -1
- package/dist/assets/shortcut-Bu7jT_-w.js +47 -0
- package/dist/assets/{sms-sign-in-form-DTX9GV2I.js → sms-sign-in-form-Bo2WLZuP.js} +1 -1
- package/dist/assets/{static.browser-jI1psK0d.js → static.browser-CoPxsICt.js} +8 -8
- package/dist/assets/switch-DQkkIE7G.js +1 -0
- package/dist/assets/{tool-cards-DFttLAfo.js → tool-cards-ipgJ_3Ec.js} +1 -1
- package/dist/assets/{use-authenticator-sign-in-CRGjzXju.js → use-authenticator-sign-in-BzFeh7qe.js} +1 -1
- package/dist/assets/{use-dingtalk-sign-in-8WYzJ2jf.js → use-dingtalk-sign-in-mrq6K5Yx.js} +1 -1
- package/dist/assets/{use-wecom-sign-in-C9j8wfCD.js → use-wecom-sign-in-PPIMLvGa.js} +1 -1
- package/dist/assets/wecom-sign-in-button-rUq9RW8R.js +1 -0
- package/dist/index.html +1 -1
- package/dist/index.raw.html +1 -1
- package/package.json +1 -1
- package/src/components/auth/sign-up-form.tsx +287 -59
- package/src/components/auth/types.ts +23 -1
- package/dist/assets/auto-login-provider-DyaPGK2D.js +0 -1
- package/dist/assets/auto-redirect-provider-Cr3jmYts.js +0 -1
- package/dist/assets/auto-redirect-provider-QkJQRBbG.js +0 -1
- package/dist/assets/createSeriesDataSimply-D0A6SAVQ.js +0 -1
- package/dist/assets/index-MB-jfQld.js +0 -686
- package/dist/assets/prompt-card-B2RS4nt2.js +0 -1
- package/dist/assets/shortcut-C5x5LQWU.js +0 -47
- package/dist/assets/switch-CRL8PmRI.js +0 -1
- package/dist/assets/wecom-sign-in-button-mIS1zGSU.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{_ as R,bF as k,W as N,a4 as G,bG as H,bH as fe,be as he,bI as me,bq as pe,f as C,k as ce,aL as ve,bJ as W,bK as F,bL as re,bM as de,D as ye,bx as ge,aS as _e,bk as oe,P as be,j as Te,y as Y,x as Se,u as ae,z as K,r as Le,ap as Me,H as Pe,t as we,ac as Ce,ad as Ae,bn as Ie,G as ie,ae as ne,af as se,a as Oe,I as Re}from"./echarts-runtime-D8kXn6ME.js";var j=H,Be=(function(a){R(r,a);function r(e){var t=a.call(this)||this;return t.type="view",t.dimensions=["x","y"],t._roamTransformable=new k,t._rawTransformable=new k,t.name=e,t}return r.prototype.setBoundingRect=function(e,t,o,i){return this._rect=new N(e,t,o,i),this._rect},r.prototype.getBoundingRect=function(){return this._rect},r.prototype.setViewRect=function(e,t,o,i){this._transformTo(e,t,o,i),this._viewRect=new N(e,t,o,i)},r.prototype._transformTo=function(e,t,o,i){var n=this.getBoundingRect(),s=this._rawTransformable;s.transform=n.calculateTransform(new N(e,t,o,i));var l=s.parent;s.parent=null,s.decomposeTransform(),s.parent=l,this._updateTransform()},r.prototype.setCenter=function(e,t){e&&(this._center=[G(e[0],t.getWidth()),G(e[1],t.getHeight())],this._updateCenterAndZoom())},r.prototype.setZoom=function(e){e=e||1;var t=this.zoomLimit;t&&(t.max!=null&&(e=Math.min(t.max,e)),t.min!=null&&(e=Math.max(t.min,e))),this._zoom=e,this._updateCenterAndZoom()},r.prototype.getDefaultCenter=function(){var e=this.getBoundingRect(),t=e.x+e.width/2,o=e.y+e.height/2;return[t,o]},r.prototype.getCenter=function(){return this._center||this.getDefaultCenter()},r.prototype.getZoom=function(){return this._zoom||1},r.prototype.getRoamTransform=function(){return this._roamTransformable.getLocalTransform()},r.prototype._updateCenterAndZoom=function(){var e=this._rawTransformable.getLocalTransform(),t=this._roamTransformable,o=this.getDefaultCenter(),i=this.getCenter(),n=this.getZoom();i=H([],i,e),o=H([],o,e),t.originX=i[0],t.originY=i[1],t.x=o[0]-i[0],t.y=o[1]-i[1],t.scaleX=t.scaleY=n,this._updateTransform()},r.prototype._updateTransform=function(){var e=this._roamTransformable,t=this._rawTransformable;t.parent=e,e.updateTransform(),t.updateTransform(),fe(this.transform||(this.transform=[]),t.transform||he()),this._rawTransform=t.getLocalTransform(),this.invTransform=this.invTransform||[],me(this.invTransform,this.transform),this.decomposeTransform()},r.prototype.getTransformInfo=function(){var e=this._rawTransformable,t=this._roamTransformable,o=new k;return o.transform=t.transform,o.decomposeTransform(),{roam:{x:o.x,y:o.y,scaleX:o.scaleX,scaleY:o.scaleY},raw:{x:e.x,y:e.y,scaleX:e.scaleX,scaleY:e.scaleY}}},r.prototype.getViewRect=function(){return this._viewRect},r.prototype.getViewRectAfterRoam=function(){var e=this.getBoundingRect().clone();return e.applyTransform(this.transform),e},r.prototype.dataToPoint=function(e,t,o){var i=t?this._rawTransform:this.transform;return o=o||[],i?j(o,e,i):pe(o,e)},r.prototype.pointToData=function(e){var t=this.invTransform;return t?j([],e,t):[e[0],e[1]]},r.prototype.convertToPixel=function(e,t,o){var i=U(t);return i===this?i.dataToPoint(o):null},r.prototype.convertFromPixel=function(e,t,o){var i=U(t);return i===this?i.pointToData(o):null},r.prototype.containPoint=function(e){return this.getViewRectAfterRoam().contain(e[0],e[1])},r.dimensions=["x","y"],r})(k);function U(a){var r=a.seriesModel;return r?r.coordinateSystem:null}function D(a,r){return a.pointToProjected?a.pointToProjected(r):a.pointToData(r)}function ze(a,r,e,t){var o=a.getZoom(),i=a.getCenter(),n=r.zoom,s=a.projectedToPoint?a.projectedToPoint(i):a.dataToPoint(i);if(r.dx!=null&&r.dy!=null&&(s[0]-=r.dx,s[1]-=r.dy,a.setCenter(D(a,s),t)),n!=null){if(e){var l=e.min||0,u=e.max||1/0;n=Math.max(Math.min(o*n,u),l)/o}a.scaleX*=n,a.scaleY*=n;var f=(r.originX-a.x)*(n-1),m=(r.originY-a.y)*(n-1);a.x-=f,a.y-=m,a.updateTransform(),a.setCenter(D(a,s),t),a.setZoom(n*o)}return{center:a.getCenter(),zoom:a.getZoom()}}var xe=(function(a){R(r,a);function r(e){var t=a.call(this)||this;t._zr=e;var o=C(t._mousedownHandler,t),i=C(t._mousemoveHandler,t),n=C(t._mouseupHandler,t),s=C(t._mousewheelHandler,t),l=C(t._pinchHandler,t);return t.enable=function(u,f){this.disable(),this._opt=ce(ve(f)||{},{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),u==null&&(u=!0),(u===!0||u==="move"||u==="pan")&&(e.on("mousedown",o),e.on("mousemove",i),e.on("mouseup",n)),(u===!0||u==="scale"||u==="zoom")&&(e.on("mousewheel",s),e.on("pinch",l))},t.disable=function(){e.off("mousedown",o),e.off("mousemove",i),e.off("mouseup",n),e.off("mousewheel",s),e.off("pinch",l)},t}return r.prototype.isDragging=function(){return this._dragging},r.prototype.isPinching=function(){return this._pinching},r.prototype.setPointerChecker=function(e){this.pointerChecker=e},r.prototype.dispose=function(){this.disable()},r.prototype._mousedownHandler=function(e){if(!W(e)){for(var t=e.target;t;){if(t.draggable)return;t=t.__hostTarget||t.parent}var o=e.offsetX,i=e.offsetY;this.pointerChecker&&this.pointerChecker(e,o,i)&&(this._x=o,this._y=i,this._dragging=!0)}},r.prototype._mousemoveHandler=function(e){if(!(!this._dragging||!E("moveOnMouseMove",e,this._opt)||e.gestureEvent==="pinch"||F(this._zr,"globalPan"))){var t=e.offsetX,o=e.offsetY,i=this._x,n=this._y,s=t-i,l=o-n;this._x=t,this._y=o,this._opt.preventDefaultMouseMove&&re(e.event),le(this,"pan","moveOnMouseMove",e,{dx:s,dy:l,oldX:i,oldY:n,newX:t,newY:o,isAvailableBehavior:null})}},r.prototype._mouseupHandler=function(e){W(e)||(this._dragging=!1)},r.prototype._mousewheelHandler=function(e){var t=E("zoomOnMouseWheel",e,this._opt),o=E("moveOnMouseWheel",e,this._opt),i=e.wheelDelta,n=Math.abs(i),s=e.offsetX,l=e.offsetY;if(!(i===0||!t&&!o)){if(t){var u=n>3?1.4:n>1?1.2:1.1,f=i>0?u:1/u;X(this,"zoom","zoomOnMouseWheel",e,{scale:f,originX:s,originY:l,isAvailableBehavior:null})}if(o){var m=Math.abs(i),h=(i>0?1:-1)*(m>3?.4:m>1?.15:.05);X(this,"scrollMove","moveOnMouseWheel",e,{scrollDelta:h,originX:s,originY:l,isAvailableBehavior:null})}}},r.prototype._pinchHandler=function(e){if(!F(this._zr,"globalPan")){var t=e.pinchScale>1?1.1:1/1.1;X(this,"zoom",null,e,{scale:t,originX:e.pinchX,originY:e.pinchY,isAvailableBehavior:null})}},r})(de);function X(a,r,e,t,o){a.pointerChecker&&a.pointerChecker(t,o.originX,o.originY)&&(re(t.event),le(a,r,e,t,o))}function le(a,r,e,t,o){o.isAvailableBehavior=C(E,null,e,t),a.trigger(r,o)}function E(a,r,e){var t=e[a];return!a||t&&(!ye(t)||r.event[t+"Key"])}function Ve(a,r,e){var t=a.target;t.x+=r,t.y+=e,t.dirty()}function He(a,r,e,t){var o=a.target,i=a.zoomLimit,n=a.zoom=a.zoom||1;if(n*=r,i){var s=i.min||0,l=i.max||1/0;n=Math.max(Math.min(l,n),s)}var u=n/a.zoom;a.zoom=n,o.x-=(e-o.x)*(u-1),o.y-=(t-o.y)*(u-1),o.scaleX*=u,o.scaleY*=u,o.dirty()}var $=ge.prototype,B=_e.prototype,ue=(function(){function a(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1}return a})();(function(a){R(r,a);function r(){return a!==null&&a.apply(this,arguments)||this}return r})(ue);function z(a){return isNaN(+a.cpx1)||isNaN(+a.cpy1)}var ke=(function(a){R(r,a);function r(e){var t=a.call(this,e)||this;return t.type="ec-line",t}return r.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},r.prototype.getDefaultShape=function(){return new ue},r.prototype.buildPath=function(e,t){z(t)?$.buildPath.call(this,e,t):B.buildPath.call(this,e,t)},r.prototype.pointAt=function(e){return z(this.shape)?$.pointAt.call(this,e):B.pointAt.call(this,e)},r.prototype.tangentAt=function(e){var t=this.shape,o=z(t)?[t.x2-t.x1,t.y2-t.y1]:B.tangentAt.call(this,e);return oe(o,o)},r})(be),x=["fromSymbol","toSymbol"];function q(a){return"_"+a+"Type"}function J(a,r,e){var t=r.getItemVisual(e,a);if(!t||t==="none")return t;var o=r.getItemVisual(e,a+"Size"),i=r.getItemVisual(e,a+"Rotate"),n=r.getItemVisual(e,a+"Offset"),s=r.getItemVisual(e,a+"KeepAspect"),l=ne(o),u=se(n||0,l);return t+l+u+(i||"")+(s||"")}function Q(a,r,e){var t=r.getItemVisual(e,a);if(!(!t||t==="none")){var o=r.getItemVisual(e,a+"Size"),i=r.getItemVisual(e,a+"Rotate"),n=r.getItemVisual(e,a+"Offset"),s=r.getItemVisual(e,a+"KeepAspect"),l=ne(o),u=se(n||0,l),f=Oe(t,-l[0]/2+u[0],-l[1]/2+u[1],l[0],l[1],null,s);return f.__specifiedRotation=i==null||isNaN(i)?void 0:+i*Math.PI/180||0,f.name=a,f}}function Ee(a){var r=new ke({name:"line",subPixelOptimize:!0});return Z(r.shape,a),r}function Z(a,r){a.x1=r[0][0],a.y1=r[0][1],a.x2=r[1][0],a.y2=r[1][1],a.percent=1;var e=r[2];e?(a.cpx1=e[0],a.cpy1=e[1]):(a.cpx1=NaN,a.cpy1=NaN)}var Ne=(function(a){R(r,a);function r(e,t,o){var i=a.call(this)||this;return i._createLine(e,t,o),i}return r.prototype._createLine=function(e,t,o){var i=e.hostModel,n=e.getItemLayout(t),s=Ee(n);s.shape.percent=0,Te(s,{shape:{percent:1}},i,t),this.add(s),Y(x,function(l){var u=Q(l,e,t);this.add(u),this[q(l)]=J(l,e,t)},this),this._updateCommonStl(e,t,o)},r.prototype.updateData=function(e,t,o){var i=e.hostModel,n=this.childOfName("line"),s=e.getItemLayout(t),l={shape:{}};Z(l.shape,s),Se(n,l,i,t),Y(x,function(u){var f=J(u,e,t),m=q(u);if(this[m]!==f){this.remove(this.childOfName(u));var h=Q(u,e,t);this.add(h)}this[m]=f},this),this._updateCommonStl(e,t,o)},r.prototype.getLinePath=function(){return this.childAt(0)},r.prototype._updateCommonStl=function(e,t,o){var i=e.hostModel,n=this.childOfName("line"),s=o&&o.emphasisLineStyle,l=o&&o.blurLineStyle,u=o&&o.selectLineStyle,f=o&&o.labelStatesModels,m=o&&o.emphasisDisabled,h=o&&o.focus,A=o&&o.blurScope;if(!o||e.hasItemOption){var v=e.getItemModel(t),d=v.getModel("emphasis");s=d.getModel("lineStyle").getLineStyle(),l=v.getModel(["blur","lineStyle"]).getLineStyle(),u=v.getModel(["select","lineStyle"]).getLineStyle(),m=d.get("disabled"),h=d.get("focus"),A=d.get("blurScope"),f=ae(v)}var S=e.getItemVisual(t,"style"),b=S.stroke;n.useStyle(S),n.style.fill=null,n.style.strokeNoScale=!0,n.ensureState("emphasis").style=s,n.ensureState("blur").style=l,n.ensureState("select").style=u,Y(x,function(P){var p=this.childOfName(P);if(p){p.setColor(b),p.style.opacity=S.opacity;for(var L=0;L<K.length;L++){var c=K[L],w=n.getState(c);if(w){var M=w.style||{},I=p.ensureState(c),O=I.style||(I.style={});M.stroke!=null&&(O[p.__isEmptyBrush?"stroke":"fill"]=M.stroke),M.opacity!=null&&(O.opacity=M.opacity)}}p.markRedraw()}},this);var T=i.getRawValue(t);Le(this,f,{labelDataIndex:t,labelFetcher:{getFormattedLabel:function(P,p){return i.getFormattedLabel(P,p,e.dataType)}},inheritColor:b||"#000",defaultOpacity:S.opacity,defaultText:(T==null?e.getName(t):isFinite(T)?Me(T):T)+""});var g=this.getTextContent();if(g){var _=f.normal;g.__align=g.style.align,g.__verticalAlign=g.style.verticalAlign,g.__position=_.get("position")||"middle";var y=_.get("distance");Pe(y)||(y=[y,y]),g.__labelDistance=y}this.setTextConfig({position:null,local:!0,inside:!1}),we(this,h,A,m)},r.prototype.highlight=function(){Ce(this)},r.prototype.downplay=function(){Ae(this)},r.prototype.updateLayout=function(e,t){this.setLinePoints(e.getItemLayout(t))},r.prototype.setLinePoints=function(e){var t=this.childOfName("line");Z(t.shape,e),t.dirty()},r.prototype.beforeUpdate=function(){var e=this,t=e.childOfName("fromSymbol"),o=e.childOfName("toSymbol"),i=e.getTextContent();if(!t&&!o&&(!i||i.ignore))return;for(var n=1,s=this.parent;s;)s.scaleX&&(n/=s.scaleX),s=s.parent;var l=e.childOfName("line");if(!this.__dirty&&!l.__dirty)return;var u=l.shape.percent,f=l.pointAt(0),m=l.pointAt(u),h=Ie([],m,f);oe(h,h);function A(w,M){var I=w.__specifiedRotation;if(I==null){var O=l.tangentAt(M);w.attr("rotation",(M===1?-1:1)*Math.PI/2-Math.atan2(O[1],O[0]))}else w.attr("rotation",I)}if(t&&(t.setPosition(f),A(t,0),t.scaleX=t.scaleY=n*u,t.markRedraw()),o&&(o.setPosition(m),A(o,1),o.scaleX=o.scaleY=n*u,o.markRedraw()),i&&!i.ignore){i.x=i.y=0,i.originX=i.originY=0;var v=void 0,d=void 0,S=i.__labelDistance,b=S[0]*n,T=S[1]*n,g=u/2,_=l.tangentAt(g),y=[_[1],-_[0]],P=l.pointAt(g);y[1]>0&&(y[0]=-y[0],y[1]=-y[1]);var p=_[0]<0?-1:1;if(i.__position!=="start"&&i.__position!=="end"){var L=-Math.atan2(_[1],_[0]);m[0]<f[0]&&(L=Math.PI+L),i.rotation=L}var c=void 0;switch(i.__position){case"insideStartTop":case"insideMiddleTop":case"insideEndTop":case"middle":c=-T,d="bottom";break;case"insideStartBottom":case"insideMiddleBottom":case"insideEndBottom":c=T,d="top";break;default:c=0,d="middle"}switch(i.__position){case"end":i.x=h[0]*b+m[0],i.y=h[1]*T+m[1],v=h[0]>.8?"left":h[0]<-.8?"right":"center",d=h[1]>.8?"top":h[1]<-.8?"bottom":"middle";break;case"start":i.x=-h[0]*b+f[0],i.y=-h[1]*T+f[1],v=h[0]>.8?"right":h[0]<-.8?"left":"center",d=h[1]>.8?"bottom":h[1]<-.8?"top":"middle";break;case"insideStartTop":case"insideStart":case"insideStartBottom":i.x=b*p+f[0],i.y=f[1]+c,v=_[0]<0?"right":"left",i.originX=-b*p,i.originY=-c;break;case"insideMiddleTop":case"insideMiddle":case"insideMiddleBottom":case"middle":i.x=P[0],i.y=P[1]+c,v="center",i.originY=-c;break;case"insideEndTop":case"insideEnd":case"insideEndBottom":i.x=-b*p+m[0],i.y=m[1]+c,v=_[0]>=0?"right":"left",i.originX=b*p,i.originY=-c;break}i.scaleX=i.scaleY=n,i.setStyle({verticalAlign:i.__verticalAlign||d,align:i.__align||v})}},r})(ie),Ze=(function(){function a(r){this.group=new ie,this._LineCtor=r||Ne}return a.prototype.updateData=function(r){var e=this;this._progressiveEls=null;var t=this,o=t.group,i=t._lineData;t._lineData=r,i||o.removeAll();var n=ee(r);r.diff(i).add(function(s){e._doAdd(r,s,n)}).update(function(s,l){e._doUpdate(i,r,l,s,n)}).remove(function(s){o.remove(i.getItemGraphicEl(s))}).execute()},a.prototype.updateLayout=function(){var r=this._lineData;r&&r.eachItemGraphicEl(function(e,t){e.updateLayout(r,t)},this)},a.prototype.incrementalPrepareUpdate=function(r){this._seriesScope=ee(r),this._lineData=null,this.group.removeAll()},a.prototype.incrementalUpdate=function(r,e){this._progressiveEls=[];function t(s){!s.isGroup&&!Ye(s)&&(s.incremental=!0,s.ensureState("emphasis").hoverLayer=!0)}for(var o=r.start;o<r.end;o++){var i=e.getItemLayout(o);if(V(i)){var n=new this._LineCtor(e,o,this._seriesScope);n.traverse(t),this.group.add(n),e.setItemGraphicEl(o,n),this._progressiveEls.push(n)}}},a.prototype.remove=function(){this.group.removeAll()},a.prototype.eachRendered=function(r){Re(this._progressiveEls||this.group,r)},a.prototype._doAdd=function(r,e,t){var o=r.getItemLayout(e);if(V(o)){var i=new this._LineCtor(r,e,t);r.setItemGraphicEl(e,i),this.group.add(i)}},a.prototype._doUpdate=function(r,e,t,o,i){var n=r.getItemGraphicEl(t);if(!V(e.getItemLayout(o))){this.group.remove(n);return}n?n.updateData(e,o,i):n=new this._LineCtor(e,o,i),e.setItemGraphicEl(o,n),this.group.add(n)},a})();function Ye(a){return a.animators&&a.animators.length>0}function ee(a){var r=a.hostModel,e=r.getModel("emphasis");return{lineStyle:r.getModel("lineStyle").getLineStyle(),emphasisLineStyle:e.getModel(["lineStyle"]).getLineStyle(),blurLineStyle:r.getModel(["blur","lineStyle"]).getLineStyle(),selectLineStyle:r.getModel(["select","lineStyle"]).getLineStyle(),emphasisDisabled:e.get("disabled"),blurScope:e.get("blurScope"),focus:e.get("focus"),labelStatesModels:ae(r)}}function te(a){return isNaN(a[0])||isNaN(a[1])}function V(a){return a&&!te(a[0])&&!te(a[1])}export{Ze as L,xe as R,Be as V,He as a,ze as b,Ne as c,Ve as u};
|
|
1
|
+
import{_ as R,bF as k,W as N,a4 as G,bG as H,bH as fe,be as he,bI as me,bq as pe,f as C,k as ce,aL as ve,bJ as W,bK as F,bL as re,bM as de,D as ye,bx as ge,aS as _e,bk as oe,P as be,j as Te,y as Y,x as Se,u as ae,z as K,r as Le,ap as Me,H as Pe,t as we,ac as Ce,ad as Ae,bn as Ie,G as ie,ae as ne,af as se,a as Oe,I as Re}from"./echarts-runtime-CvLr4Slh.js";var j=H,Be=(function(a){R(r,a);function r(e){var t=a.call(this)||this;return t.type="view",t.dimensions=["x","y"],t._roamTransformable=new k,t._rawTransformable=new k,t.name=e,t}return r.prototype.setBoundingRect=function(e,t,o,i){return this._rect=new N(e,t,o,i),this._rect},r.prototype.getBoundingRect=function(){return this._rect},r.prototype.setViewRect=function(e,t,o,i){this._transformTo(e,t,o,i),this._viewRect=new N(e,t,o,i)},r.prototype._transformTo=function(e,t,o,i){var n=this.getBoundingRect(),s=this._rawTransformable;s.transform=n.calculateTransform(new N(e,t,o,i));var l=s.parent;s.parent=null,s.decomposeTransform(),s.parent=l,this._updateTransform()},r.prototype.setCenter=function(e,t){e&&(this._center=[G(e[0],t.getWidth()),G(e[1],t.getHeight())],this._updateCenterAndZoom())},r.prototype.setZoom=function(e){e=e||1;var t=this.zoomLimit;t&&(t.max!=null&&(e=Math.min(t.max,e)),t.min!=null&&(e=Math.max(t.min,e))),this._zoom=e,this._updateCenterAndZoom()},r.prototype.getDefaultCenter=function(){var e=this.getBoundingRect(),t=e.x+e.width/2,o=e.y+e.height/2;return[t,o]},r.prototype.getCenter=function(){return this._center||this.getDefaultCenter()},r.prototype.getZoom=function(){return this._zoom||1},r.prototype.getRoamTransform=function(){return this._roamTransformable.getLocalTransform()},r.prototype._updateCenterAndZoom=function(){var e=this._rawTransformable.getLocalTransform(),t=this._roamTransformable,o=this.getDefaultCenter(),i=this.getCenter(),n=this.getZoom();i=H([],i,e),o=H([],o,e),t.originX=i[0],t.originY=i[1],t.x=o[0]-i[0],t.y=o[1]-i[1],t.scaleX=t.scaleY=n,this._updateTransform()},r.prototype._updateTransform=function(){var e=this._roamTransformable,t=this._rawTransformable;t.parent=e,e.updateTransform(),t.updateTransform(),fe(this.transform||(this.transform=[]),t.transform||he()),this._rawTransform=t.getLocalTransform(),this.invTransform=this.invTransform||[],me(this.invTransform,this.transform),this.decomposeTransform()},r.prototype.getTransformInfo=function(){var e=this._rawTransformable,t=this._roamTransformable,o=new k;return o.transform=t.transform,o.decomposeTransform(),{roam:{x:o.x,y:o.y,scaleX:o.scaleX,scaleY:o.scaleY},raw:{x:e.x,y:e.y,scaleX:e.scaleX,scaleY:e.scaleY}}},r.prototype.getViewRect=function(){return this._viewRect},r.prototype.getViewRectAfterRoam=function(){var e=this.getBoundingRect().clone();return e.applyTransform(this.transform),e},r.prototype.dataToPoint=function(e,t,o){var i=t?this._rawTransform:this.transform;return o=o||[],i?j(o,e,i):pe(o,e)},r.prototype.pointToData=function(e){var t=this.invTransform;return t?j([],e,t):[e[0],e[1]]},r.prototype.convertToPixel=function(e,t,o){var i=U(t);return i===this?i.dataToPoint(o):null},r.prototype.convertFromPixel=function(e,t,o){var i=U(t);return i===this?i.pointToData(o):null},r.prototype.containPoint=function(e){return this.getViewRectAfterRoam().contain(e[0],e[1])},r.dimensions=["x","y"],r})(k);function U(a){var r=a.seriesModel;return r?r.coordinateSystem:null}function D(a,r){return a.pointToProjected?a.pointToProjected(r):a.pointToData(r)}function ze(a,r,e,t){var o=a.getZoom(),i=a.getCenter(),n=r.zoom,s=a.projectedToPoint?a.projectedToPoint(i):a.dataToPoint(i);if(r.dx!=null&&r.dy!=null&&(s[0]-=r.dx,s[1]-=r.dy,a.setCenter(D(a,s),t)),n!=null){if(e){var l=e.min||0,u=e.max||1/0;n=Math.max(Math.min(o*n,u),l)/o}a.scaleX*=n,a.scaleY*=n;var f=(r.originX-a.x)*(n-1),m=(r.originY-a.y)*(n-1);a.x-=f,a.y-=m,a.updateTransform(),a.setCenter(D(a,s),t),a.setZoom(n*o)}return{center:a.getCenter(),zoom:a.getZoom()}}var xe=(function(a){R(r,a);function r(e){var t=a.call(this)||this;t._zr=e;var o=C(t._mousedownHandler,t),i=C(t._mousemoveHandler,t),n=C(t._mouseupHandler,t),s=C(t._mousewheelHandler,t),l=C(t._pinchHandler,t);return t.enable=function(u,f){this.disable(),this._opt=ce(ve(f)||{},{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),u==null&&(u=!0),(u===!0||u==="move"||u==="pan")&&(e.on("mousedown",o),e.on("mousemove",i),e.on("mouseup",n)),(u===!0||u==="scale"||u==="zoom")&&(e.on("mousewheel",s),e.on("pinch",l))},t.disable=function(){e.off("mousedown",o),e.off("mousemove",i),e.off("mouseup",n),e.off("mousewheel",s),e.off("pinch",l)},t}return r.prototype.isDragging=function(){return this._dragging},r.prototype.isPinching=function(){return this._pinching},r.prototype.setPointerChecker=function(e){this.pointerChecker=e},r.prototype.dispose=function(){this.disable()},r.prototype._mousedownHandler=function(e){if(!W(e)){for(var t=e.target;t;){if(t.draggable)return;t=t.__hostTarget||t.parent}var o=e.offsetX,i=e.offsetY;this.pointerChecker&&this.pointerChecker(e,o,i)&&(this._x=o,this._y=i,this._dragging=!0)}},r.prototype._mousemoveHandler=function(e){if(!(!this._dragging||!E("moveOnMouseMove",e,this._opt)||e.gestureEvent==="pinch"||F(this._zr,"globalPan"))){var t=e.offsetX,o=e.offsetY,i=this._x,n=this._y,s=t-i,l=o-n;this._x=t,this._y=o,this._opt.preventDefaultMouseMove&&re(e.event),le(this,"pan","moveOnMouseMove",e,{dx:s,dy:l,oldX:i,oldY:n,newX:t,newY:o,isAvailableBehavior:null})}},r.prototype._mouseupHandler=function(e){W(e)||(this._dragging=!1)},r.prototype._mousewheelHandler=function(e){var t=E("zoomOnMouseWheel",e,this._opt),o=E("moveOnMouseWheel",e,this._opt),i=e.wheelDelta,n=Math.abs(i),s=e.offsetX,l=e.offsetY;if(!(i===0||!t&&!o)){if(t){var u=n>3?1.4:n>1?1.2:1.1,f=i>0?u:1/u;X(this,"zoom","zoomOnMouseWheel",e,{scale:f,originX:s,originY:l,isAvailableBehavior:null})}if(o){var m=Math.abs(i),h=(i>0?1:-1)*(m>3?.4:m>1?.15:.05);X(this,"scrollMove","moveOnMouseWheel",e,{scrollDelta:h,originX:s,originY:l,isAvailableBehavior:null})}}},r.prototype._pinchHandler=function(e){if(!F(this._zr,"globalPan")){var t=e.pinchScale>1?1.1:1/1.1;X(this,"zoom",null,e,{scale:t,originX:e.pinchX,originY:e.pinchY,isAvailableBehavior:null})}},r})(de);function X(a,r,e,t,o){a.pointerChecker&&a.pointerChecker(t,o.originX,o.originY)&&(re(t.event),le(a,r,e,t,o))}function le(a,r,e,t,o){o.isAvailableBehavior=C(E,null,e,t),a.trigger(r,o)}function E(a,r,e){var t=e[a];return!a||t&&(!ye(t)||r.event[t+"Key"])}function Ve(a,r,e){var t=a.target;t.x+=r,t.y+=e,t.dirty()}function He(a,r,e,t){var o=a.target,i=a.zoomLimit,n=a.zoom=a.zoom||1;if(n*=r,i){var s=i.min||0,l=i.max||1/0;n=Math.max(Math.min(l,n),s)}var u=n/a.zoom;a.zoom=n,o.x-=(e-o.x)*(u-1),o.y-=(t-o.y)*(u-1),o.scaleX*=u,o.scaleY*=u,o.dirty()}var $=ge.prototype,B=_e.prototype,ue=(function(){function a(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1}return a})();(function(a){R(r,a);function r(){return a!==null&&a.apply(this,arguments)||this}return r})(ue);function z(a){return isNaN(+a.cpx1)||isNaN(+a.cpy1)}var ke=(function(a){R(r,a);function r(e){var t=a.call(this,e)||this;return t.type="ec-line",t}return r.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},r.prototype.getDefaultShape=function(){return new ue},r.prototype.buildPath=function(e,t){z(t)?$.buildPath.call(this,e,t):B.buildPath.call(this,e,t)},r.prototype.pointAt=function(e){return z(this.shape)?$.pointAt.call(this,e):B.pointAt.call(this,e)},r.prototype.tangentAt=function(e){var t=this.shape,o=z(t)?[t.x2-t.x1,t.y2-t.y1]:B.tangentAt.call(this,e);return oe(o,o)},r})(be),x=["fromSymbol","toSymbol"];function q(a){return"_"+a+"Type"}function J(a,r,e){var t=r.getItemVisual(e,a);if(!t||t==="none")return t;var o=r.getItemVisual(e,a+"Size"),i=r.getItemVisual(e,a+"Rotate"),n=r.getItemVisual(e,a+"Offset"),s=r.getItemVisual(e,a+"KeepAspect"),l=ne(o),u=se(n||0,l);return t+l+u+(i||"")+(s||"")}function Q(a,r,e){var t=r.getItemVisual(e,a);if(!(!t||t==="none")){var o=r.getItemVisual(e,a+"Size"),i=r.getItemVisual(e,a+"Rotate"),n=r.getItemVisual(e,a+"Offset"),s=r.getItemVisual(e,a+"KeepAspect"),l=ne(o),u=se(n||0,l),f=Oe(t,-l[0]/2+u[0],-l[1]/2+u[1],l[0],l[1],null,s);return f.__specifiedRotation=i==null||isNaN(i)?void 0:+i*Math.PI/180||0,f.name=a,f}}function Ee(a){var r=new ke({name:"line",subPixelOptimize:!0});return Z(r.shape,a),r}function Z(a,r){a.x1=r[0][0],a.y1=r[0][1],a.x2=r[1][0],a.y2=r[1][1],a.percent=1;var e=r[2];e?(a.cpx1=e[0],a.cpy1=e[1]):(a.cpx1=NaN,a.cpy1=NaN)}var Ne=(function(a){R(r,a);function r(e,t,o){var i=a.call(this)||this;return i._createLine(e,t,o),i}return r.prototype._createLine=function(e,t,o){var i=e.hostModel,n=e.getItemLayout(t),s=Ee(n);s.shape.percent=0,Te(s,{shape:{percent:1}},i,t),this.add(s),Y(x,function(l){var u=Q(l,e,t);this.add(u),this[q(l)]=J(l,e,t)},this),this._updateCommonStl(e,t,o)},r.prototype.updateData=function(e,t,o){var i=e.hostModel,n=this.childOfName("line"),s=e.getItemLayout(t),l={shape:{}};Z(l.shape,s),Se(n,l,i,t),Y(x,function(u){var f=J(u,e,t),m=q(u);if(this[m]!==f){this.remove(this.childOfName(u));var h=Q(u,e,t);this.add(h)}this[m]=f},this),this._updateCommonStl(e,t,o)},r.prototype.getLinePath=function(){return this.childAt(0)},r.prototype._updateCommonStl=function(e,t,o){var i=e.hostModel,n=this.childOfName("line"),s=o&&o.emphasisLineStyle,l=o&&o.blurLineStyle,u=o&&o.selectLineStyle,f=o&&o.labelStatesModels,m=o&&o.emphasisDisabled,h=o&&o.focus,A=o&&o.blurScope;if(!o||e.hasItemOption){var v=e.getItemModel(t),d=v.getModel("emphasis");s=d.getModel("lineStyle").getLineStyle(),l=v.getModel(["blur","lineStyle"]).getLineStyle(),u=v.getModel(["select","lineStyle"]).getLineStyle(),m=d.get("disabled"),h=d.get("focus"),A=d.get("blurScope"),f=ae(v)}var S=e.getItemVisual(t,"style"),b=S.stroke;n.useStyle(S),n.style.fill=null,n.style.strokeNoScale=!0,n.ensureState("emphasis").style=s,n.ensureState("blur").style=l,n.ensureState("select").style=u,Y(x,function(P){var p=this.childOfName(P);if(p){p.setColor(b),p.style.opacity=S.opacity;for(var L=0;L<K.length;L++){var c=K[L],w=n.getState(c);if(w){var M=w.style||{},I=p.ensureState(c),O=I.style||(I.style={});M.stroke!=null&&(O[p.__isEmptyBrush?"stroke":"fill"]=M.stroke),M.opacity!=null&&(O.opacity=M.opacity)}}p.markRedraw()}},this);var T=i.getRawValue(t);Le(this,f,{labelDataIndex:t,labelFetcher:{getFormattedLabel:function(P,p){return i.getFormattedLabel(P,p,e.dataType)}},inheritColor:b||"#000",defaultOpacity:S.opacity,defaultText:(T==null?e.getName(t):isFinite(T)?Me(T):T)+""});var g=this.getTextContent();if(g){var _=f.normal;g.__align=g.style.align,g.__verticalAlign=g.style.verticalAlign,g.__position=_.get("position")||"middle";var y=_.get("distance");Pe(y)||(y=[y,y]),g.__labelDistance=y}this.setTextConfig({position:null,local:!0,inside:!1}),we(this,h,A,m)},r.prototype.highlight=function(){Ce(this)},r.prototype.downplay=function(){Ae(this)},r.prototype.updateLayout=function(e,t){this.setLinePoints(e.getItemLayout(t))},r.prototype.setLinePoints=function(e){var t=this.childOfName("line");Z(t.shape,e),t.dirty()},r.prototype.beforeUpdate=function(){var e=this,t=e.childOfName("fromSymbol"),o=e.childOfName("toSymbol"),i=e.getTextContent();if(!t&&!o&&(!i||i.ignore))return;for(var n=1,s=this.parent;s;)s.scaleX&&(n/=s.scaleX),s=s.parent;var l=e.childOfName("line");if(!this.__dirty&&!l.__dirty)return;var u=l.shape.percent,f=l.pointAt(0),m=l.pointAt(u),h=Ie([],m,f);oe(h,h);function A(w,M){var I=w.__specifiedRotation;if(I==null){var O=l.tangentAt(M);w.attr("rotation",(M===1?-1:1)*Math.PI/2-Math.atan2(O[1],O[0]))}else w.attr("rotation",I)}if(t&&(t.setPosition(f),A(t,0),t.scaleX=t.scaleY=n*u,t.markRedraw()),o&&(o.setPosition(m),A(o,1),o.scaleX=o.scaleY=n*u,o.markRedraw()),i&&!i.ignore){i.x=i.y=0,i.originX=i.originY=0;var v=void 0,d=void 0,S=i.__labelDistance,b=S[0]*n,T=S[1]*n,g=u/2,_=l.tangentAt(g),y=[_[1],-_[0]],P=l.pointAt(g);y[1]>0&&(y[0]=-y[0],y[1]=-y[1]);var p=_[0]<0?-1:1;if(i.__position!=="start"&&i.__position!=="end"){var L=-Math.atan2(_[1],_[0]);m[0]<f[0]&&(L=Math.PI+L),i.rotation=L}var c=void 0;switch(i.__position){case"insideStartTop":case"insideMiddleTop":case"insideEndTop":case"middle":c=-T,d="bottom";break;case"insideStartBottom":case"insideMiddleBottom":case"insideEndBottom":c=T,d="top";break;default:c=0,d="middle"}switch(i.__position){case"end":i.x=h[0]*b+m[0],i.y=h[1]*T+m[1],v=h[0]>.8?"left":h[0]<-.8?"right":"center",d=h[1]>.8?"top":h[1]<-.8?"bottom":"middle";break;case"start":i.x=-h[0]*b+f[0],i.y=-h[1]*T+f[1],v=h[0]>.8?"right":h[0]<-.8?"left":"center",d=h[1]>.8?"bottom":h[1]<-.8?"top":"middle";break;case"insideStartTop":case"insideStart":case"insideStartBottom":i.x=b*p+f[0],i.y=f[1]+c,v=_[0]<0?"right":"left",i.originX=-b*p,i.originY=-c;break;case"insideMiddleTop":case"insideMiddle":case"insideMiddleBottom":case"middle":i.x=P[0],i.y=P[1]+c,v="center",i.originY=-c;break;case"insideEndTop":case"insideEnd":case"insideEndBottom":i.x=-b*p+m[0],i.y=m[1]+c,v=_[0]>=0?"right":"left",i.originX=b*p,i.originY=-c;break}i.scaleX=i.scaleY=n,i.setStyle({verticalAlign:i.__verticalAlign||d,align:i.__align||v})}},r})(ie),Ze=(function(){function a(r){this.group=new ie,this._LineCtor=r||Ne}return a.prototype.updateData=function(r){var e=this;this._progressiveEls=null;var t=this,o=t.group,i=t._lineData;t._lineData=r,i||o.removeAll();var n=ee(r);r.diff(i).add(function(s){e._doAdd(r,s,n)}).update(function(s,l){e._doUpdate(i,r,l,s,n)}).remove(function(s){o.remove(i.getItemGraphicEl(s))}).execute()},a.prototype.updateLayout=function(){var r=this._lineData;r&&r.eachItemGraphicEl(function(e,t){e.updateLayout(r,t)},this)},a.prototype.incrementalPrepareUpdate=function(r){this._seriesScope=ee(r),this._lineData=null,this.group.removeAll()},a.prototype.incrementalUpdate=function(r,e){this._progressiveEls=[];function t(s){!s.isGroup&&!Ye(s)&&(s.incremental=!0,s.ensureState("emphasis").hoverLayer=!0)}for(var o=r.start;o<r.end;o++){var i=e.getItemLayout(o);if(V(i)){var n=new this._LineCtor(e,o,this._seriesScope);n.traverse(t),this.group.add(n),e.setItemGraphicEl(o,n),this._progressiveEls.push(n)}}},a.prototype.remove=function(){this.group.removeAll()},a.prototype.eachRendered=function(r){Re(this._progressiveEls||this.group,r)},a.prototype._doAdd=function(r,e,t){var o=r.getItemLayout(e);if(V(o)){var i=new this._LineCtor(r,e,t);r.setItemGraphicEl(e,i),this.group.add(i)}},a.prototype._doUpdate=function(r,e,t,o,i){var n=r.getItemGraphicEl(t);if(!V(e.getItemLayout(o))){this.group.remove(n);return}n?n.updateData(e,o,i):n=new this._LineCtor(e,o,i),e.setItemGraphicEl(o,n),this.group.add(n)},a})();function Ye(a){return a.animators&&a.animators.length>0}function ee(a){var r=a.hostModel,e=r.getModel("emphasis");return{lineStyle:r.getModel("lineStyle").getLineStyle(),emphasisLineStyle:e.getModel(["lineStyle"]).getLineStyle(),blurLineStyle:r.getModel(["blur","lineStyle"]).getLineStyle(),selectLineStyle:r.getModel(["select","lineStyle"]).getLineStyle(),emphasisDisabled:e.get("disabled"),blurScope:e.get("blurScope"),focus:e.get("focus"),labelStatesModels:ae(r)}}function te(a){return isNaN(a[0])||isNaN(a[1])}function V(a){return a&&!te(a[0])&&!te(a[1])}export{Ze as L,xe as R,Be as V,He as a,ze as b,Ne as c,Ve as u};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{_ as U,a as Z,ac as j,ad as k,x as G,J as F,j as H,u as N,af as B,al as J,N as C,r as K,t as $,l as q,ah as T,ae as Q,G as X,I as W,a9 as x}from"./echarts-runtime-
|
|
1
|
+
import{_ as U,a as Z,ac as j,ad as k,x as G,J as F,j as H,u as N,af as B,al as J,N as C,r as K,t as $,l as q,ah as T,ae as Q,G as X,I as W,a9 as x}from"./echarts-runtime-CvLr4Slh.js";import{a as ee}from"./labelHelper-DbITmOUW.js";var te=(function(n){U(t,n);function t(e,l,i,a){var m=n.call(this)||this;return m.updateData(e,l,i,a),m}return t.prototype._createSymbol=function(e,l,i,a,m){this.removeAll();var s=Z(e,-1,-1,2,2,null,m);s.attr({z2:100,culling:!0,scaleX:a[0]/2,scaleY:a[1]/2}),s.drift=le,this._symbolType=e,this.add(s)},t.prototype.stopSymbolAnimation=function(e){this.childAt(0).stopAnimation(null,e)},t.prototype.getSymbolType=function(){return this._symbolType},t.prototype.getSymbolPath=function(){return this.childAt(0)},t.prototype.highlight=function(){j(this.childAt(0))},t.prototype.downplay=function(){k(this.childAt(0))},t.prototype.setZ=function(e,l){var i=this.childAt(0);i.zlevel=e,i.z=l},t.prototype.setDraggable=function(e,l){var i=this.childAt(0);i.draggable=e,i.cursor=!l&&e?"move":i.cursor},t.prototype.updateData=function(e,l,i,a){this.silent=!1;var m=e.getItemVisual(l,"symbol")||"circle",s=e.hostModel,c=t.getSymbolSize(e,l),h=m!==this._symbolType,y=a&&a.disableAnimation;if(h){var u=e.getItemVisual(l,"symbolKeepAspect");this._createSymbol(m,e,l,c,u)}else{var o=this.childAt(0);o.silent=!1;var r={scaleX:c[0]/2,scaleY:c[1]/2};y?o.attr(r):G(o,r,s,l),F(o)}if(this._updateCommon(e,l,c,i,a),h){var o=this.childAt(0);if(!y){var r={scaleX:this._sizeX,scaleY:this._sizeY,style:{opacity:o.style.opacity}};o.scaleX=o.scaleY=0,o.style.opacity=0,H(o,r,s,l)}}y&&this.childAt(0).stopAnimation("leave")},t.prototype._updateCommon=function(e,l,i,a,m){var s=this.childAt(0),c=e.hostModel,h,y,u,o,r,f,b,v,p;if(a&&(h=a.emphasisItemStyle,y=a.blurItemStyle,u=a.selectItemStyle,o=a.focus,r=a.blurScope,b=a.labelStatesModels,v=a.hoverScale,p=a.cursorStyle,f=a.emphasisDisabled),!a||e.hasItemOption){var g=a&&a.itemModel?a.itemModel:e.getItemModel(l),S=g.getModel("emphasis");h=S.getModel("itemStyle").getItemStyle(),u=g.getModel(["select","itemStyle"]).getItemStyle(),y=g.getModel(["blur","itemStyle"]).getItemStyle(),o=S.get("focus"),r=S.get("blurScope"),f=S.get("disabled"),b=N(g),v=S.getShallow("scale"),p=g.getShallow("cursor")}var V=e.getItemVisual(l,"symbolRotate");s.attr("rotation",(V||0)*Math.PI/180||0);var _=B(e.getItemVisual(l,"symbolOffset"),i);_&&(s.x=_[0],s.y=_[1]),p&&s.attr("cursor",p);var d=e.getItemVisual(l,"style"),E=d.fill;if(s instanceof J){var I=s.style;s.useStyle(C({image:I.image,x:I.x,y:I.y,width:I.width,height:I.height},d))}else s.__isEmptyBrush?s.useStyle(C({},d)):s.useStyle(d),s.style.decal=null,s.setColor(E,m&&m.symbolInnerColor),s.style.strokeNoScale=!0;var D=e.getItemVisual(l,"liftZ"),A=this._z2;D!=null?A==null&&(this._z2=s.z2,s.z2+=D):A!=null&&(s.z2=A,this._z2=null);var w=m&&m.useNameLabel;K(s,b,{labelFetcher:c,labelDataIndex:l,defaultText:R,inheritColor:E,defaultOpacity:d.opacity});function R(P){return w?e.getName(P):ee(e,P)}this._sizeX=i[0]/2,this._sizeY=i[1]/2;var z=s.ensureState("emphasis");z.style=h,s.ensureState("select").style=u,s.ensureState("blur").style=y;var O=v==null||v===!0?Math.max(1.1,3/this._sizeY):isFinite(v)&&v>0?+v:1;z.scaleX=this._sizeX*O,z.scaleY=this._sizeY*O,this.setSymbolScale(1),$(this,o,r,f)},t.prototype.setSymbolScale=function(e){this.scaleX=this.scaleY=e},t.prototype.fadeOut=function(e,l,i){var a=this.childAt(0),m=q(this).dataIndex,s=i&&i.animation;if(this.silent=a.silent=!0,i&&i.fadeLabel){var c=a.getTextContent();c&&T(c,{style:{opacity:0}},l,{dataIndex:m,removeOpt:s,cb:function(){a.removeTextContent()}})}else a.removeTextContent();T(a,{style:{opacity:0},scaleX:0,scaleY:0},l,{dataIndex:m,cb:e,removeOpt:s})},t.getSymbolSize=function(e,l){return Q(e.getItemVisual(l,"symbolSize"))},t})(X);function le(n,t){this.parent.drift(n,t)}function M(n,t,e,l){return t&&!isNaN(t[0])&&!isNaN(t[1])&&!(l.isIgnore&&l.isIgnore(e))&&!(l.clipShape&&!l.clipShape.contain(t[0],t[1]))&&n.getItemVisual(e,"symbol")!=="none"}function L(n){return n!=null&&!x(n)&&(n={isIgnore:n}),n||{}}function Y(n){var t=n.hostModel,e=t.getModel("emphasis");return{emphasisItemStyle:e.getModel("itemStyle").getItemStyle(),blurItemStyle:t.getModel(["blur","itemStyle"]).getItemStyle(),selectItemStyle:t.getModel(["select","itemStyle"]).getItemStyle(),focus:e.get("focus"),blurScope:e.get("blurScope"),emphasisDisabled:e.get("disabled"),hoverScale:e.get("scale"),labelStatesModels:N(t),cursorStyle:t.get("cursor")}}var ie=(function(){function n(t){this.group=new X,this._SymbolCtor=t||te}return n.prototype.updateData=function(t,e){this._progressiveEls=null,e=L(e);var l=this.group,i=t.hostModel,a=this._data,m=this._SymbolCtor,s=e.disableAnimation,c=Y(t),h={disableAnimation:s},y=e.getSymbolPoint||function(u){return t.getItemLayout(u)};a||l.removeAll(),t.diff(a).add(function(u){var o=y(u);if(M(t,o,u,e)){var r=new m(t,u,c,h);r.setPosition(o),t.setItemGraphicEl(u,r),l.add(r)}}).update(function(u,o){var r=a.getItemGraphicEl(o),f=y(u);if(!M(t,f,u,e)){l.remove(r);return}var b=t.getItemVisual(u,"symbol")||"circle",v=r&&r.getSymbolType&&r.getSymbolType();if(!r||v&&v!==b)l.remove(r),r=new m(t,u,c,h),r.setPosition(f);else{r.updateData(t,u,c,h);var p={x:f[0],y:f[1]};s?r.attr(p):G(r,p,i)}l.add(r),t.setItemGraphicEl(u,r)}).remove(function(u){var o=a.getItemGraphicEl(u);o&&o.fadeOut(function(){l.remove(o)},i)}).execute(),this._getSymbolPoint=y,this._data=t},n.prototype.updateLayout=function(){var t=this,e=this._data;e&&e.eachItemGraphicEl(function(l,i){var a=t._getSymbolPoint(i);l.setPosition(a),l.markRedraw()})},n.prototype.incrementalPrepareUpdate=function(t){this._seriesScope=Y(t),this._data=null,this.group.removeAll()},n.prototype.incrementalUpdate=function(t,e,l){this._progressiveEls=[],l=L(l);function i(c){c.isGroup||(c.incremental=!0,c.ensureState("emphasis").hoverLayer=!0)}for(var a=t.start;a<t.end;a++){var m=e.getItemLayout(a);if(M(e,m,a,l)){var s=new this._SymbolCtor(e,a,this._seriesScope);s.traverse(i),s.setPosition(m),this.group.add(s),e.setItemGraphicEl(a,s),this._progressiveEls.push(s)}}},n.prototype.eachRendered=function(t){W(this._progressiveEls||this.group,t)},n.prototype.remove=function(t){var e=this.group,l=this._data;l&&t?l.eachItemGraphicEl(function(i){i.fadeOut(function(){e.remove(i)},l.hostModel)}):e.removeAll()},n})();export{ie as S,te as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{_ as j,m as T,k as U,bN as ae,aL as se,D as O,o as he,aX as de,a1 as ve,bO as ge,bP as me,bQ as ye,bR as xe,y as v,H as P,ai as Ve,bS as be,aw as Ae,aK as we,bT as re,bU as Me,bV as Ie,a4 as G,bW as ie,bX as Te,b as Se,aY as Le,aU as _e,aA as D,a9 as H,bY as Ne,f as ne,aV as ze,bZ as $,b_ as q,bg as Ce,bf as K}from"./echarts-runtime-D8kXn6ME.js";var N=me.value;function R(r,e){return U({show:e},r)}var Pe=(function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(){var t=this.get("boundaryGap"),a=this.get("splitNumber"),i=this.get("scale"),n=this.get("axisLine"),o=this.get("axisTick"),s=this.get("axisLabel"),u=this.get("axisName"),f=this.get(["axisName","show"]),l=this.get(["axisName","formatter"]),h=this.get("axisNameGap"),m=this.get("triggerEvent"),b=T(this.get("indicator")||[],function(c){c.max!=null&&c.max>0&&!c.min?c.min=0:c.min!=null&&c.min<0&&!c.max&&(c.max=0);var g=u;c.color!=null&&(g=U({color:c.color},u));var d=ae(se(c),{boundaryGap:t,splitNumber:a,scale:i,axisLine:n,axisTick:o,axisLabel:s,name:c.text,showName:f,nameLocation:"end",nameGap:h,nameTextStyle:g,triggerEvent:m},!1);if(O(l)){var x=d.name;d.name=l.replace("{value}",x??"")}else he(l)&&(d.name=l(d.name,d));var y=new de(d,null,this.ecModel);return ve(y,ge.prototype),y.mainType="radar",y.componentIndex=this.componentIndex,y},this);this._indicatorModels=b},e.prototype.getIndicatorModels=function(){return this._indicatorModels},e.type="radar",e.defaultOption={z:0,center:["50%","50%"],radius:"75%",startAngle:90,axisName:{show:!0},boundaryGap:[0,0],splitNumber:5,axisNameGap:15,scale:!1,shape:"polygon",axisLine:ae({lineStyle:{color:"#bbb"}},N.axisLine),axisLabel:R(N.axisLabel,!1),axisTick:R(N.axisTick,!1),splitLine:R(N.splitLine,!0),splitArea:R(N.splitArea,!0),indicator:[]},e})(ye),De=["axisLine","axisTickLabel","axisName"],He=(function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,i){var n=this.group;n.removeAll(),this._buildAxes(t),this._buildSplitLineAndArea(t)},e.prototype._buildAxes=function(t){var a=t.coordinateSystem,i=a.getIndicatorAxes(),n=T(i,function(o){var s=o.model.get("showName")?o.name:"",u=new xe(o.model,{axisName:s,position:[a.cx,a.cy],rotation:o.angle,labelDirection:-1,tickDirection:-1,nameDirection:1});return u});v(n,function(o){v(De,o.add,o),this.group.add(o.getGroup())},this)},e.prototype._buildSplitLineAndArea=function(t){var a=t.coordinateSystem,i=a.getIndicatorAxes();if(!i.length)return;var n=t.get("shape"),o=t.getModel("splitLine"),s=t.getModel("splitArea"),u=o.getModel("lineStyle"),f=s.getModel("areaStyle"),l=o.get("show"),h=s.get("show"),m=u.get("color"),b=f.get("color"),c=P(m)?m:[m],g=P(b)?b:[b],d=[],x=[];function y(V,M,L){var _=L%M.length;return V[_]=V[_]||[],_}if(n==="circle")for(var S=i[0].getTicksCoords(),ee=a.cx,te=a.cy,p=0;p<S.length;p++){if(l){var A=y(d,c,p);d[A].push(new Ve({shape:{cx:ee,cy:te,r:S[p].coord}}))}if(h&&p<S.length-1){var A=y(x,g,p);x[A].push(new be({shape:{cx:ee,cy:te,r0:S[p].coord,r:S[p+1].coord}}))}}else for(var E,ce=T(i,function(V,M){var L=V.getTicksCoords();return E=E==null?L.length-1:Math.min(L.length-1,E),T(L,function(_){return a.coordToPoint(_.coord,M)})}),Y=[],p=0;p<=E;p++){for(var w=[],Z=0;Z<i.length;Z++)w.push(ce[Z][p]);if(w[0]&&w.push(w[0].slice()),l){var A=y(d,c,p);d[A].push(new Ae({shape:{points:w}}))}if(h&&Y){var A=y(x,g,p-1);x[A].push(new we({shape:{points:w.concat(Y)}}))}Y=w.slice().reverse()}var fe=u.getLineStyle(),pe=f.getAreaStyle();v(x,function(V,M){this.group.add(re(V,{style:U({stroke:"none",fill:g[M%g.length]},pe),silent:!0}))},this),v(d,function(V,M){this.group.add(re(V,{style:U({fill:"none",stroke:c[M%c.length]},fe),silent:!0}))},this)},e.type="radar",e})(Me),ke=(function(r){j(e,r);function e(t,a,i){var n=r.call(this,t,a,i)||this;return n.type="value",n.angle=0,n.name="",n}return e})(Ie),Ee=(function(){function r(e,t,a){this.dimensions=[],this._model=e,this._indicatorAxes=T(e.getIndicatorModels(),function(i,n){var o="indicator_"+n,s=new ke(o,new ie);return s.name=i.get("name"),s.model=i,i.axis=s,this.dimensions.push(o),s},this),this.resize(e,a)}return r.prototype.getIndicatorAxes=function(){return this._indicatorAxes},r.prototype.dataToPoint=function(e,t){var a=this._indicatorAxes[t];return this.coordToPoint(a.dataToCoord(e),t)},r.prototype.coordToPoint=function(e,t){var a=this._indicatorAxes[t],i=a.angle,n=this.cx+e*Math.cos(i),o=this.cy-e*Math.sin(i);return[n,o]},r.prototype.pointToData=function(e){var t=e[0]-this.cx,a=e[1]-this.cy,i=Math.sqrt(t*t+a*a);t/=i,a/=i;for(var n=Math.atan2(-a,t),o=1/0,s,u=-1,f=0;f<this._indicatorAxes.length;f++){var l=this._indicatorAxes[f],h=Math.abs(n-l.angle);h<o&&(s=l,u=f,o=h)}return[u,+(s&&s.coordToData(i))]},r.prototype.resize=function(e,t){var a=e.get("center"),i=t.getWidth(),n=t.getHeight(),o=Math.min(i,n)/2;this.cx=G(a[0],i),this.cy=G(a[1],n),this.startAngle=e.get("startAngle")*Math.PI/180;var s=e.get("radius");(O(s)||Se(s))&&(s=[0,s]),this.r0=G(s[0],o),this.r=G(s[1],o),v(this._indicatorAxes,function(u,f){u.setExtent(this.r0,this.r);var l=this.startAngle+f*Math.PI*2/this._indicatorAxes.length;l=Math.atan2(Math.sin(l),Math.cos(l)),u.angle=l},this)},r.prototype.update=function(e,t){var a=this._indicatorAxes,i=this._model;v(a,function(s){s.scale.setExtent(1/0,-1/0)}),e.eachSeriesByType("radar",function(s,u){if(!(s.get("coordinateSystem")!=="radar"||e.getComponent("radar",s.get("radarIndex"))!==i)){var f=s.getData();v(a,function(l){l.scale.unionExtentFromData(f,f.mapDimension(l.dim))})}},this);var n=i.get("splitNumber"),o=new ie;o.setExtent(0,n),o.setInterval(1),v(a,function(s,u){Te(s.scale,s.model,o)})},r.prototype.convertToPixel=function(e,t,a){return console.warn("Not implemented."),null},r.prototype.convertFromPixel=function(e,t,a){return console.warn("Not implemented."),null},r.prototype.containPoint=function(e){return console.warn("Not implemented."),!1},r.create=function(e,t){var a=[];return e.eachComponent("radar",function(i){var n=new r(i,e,t);a.push(n),i.coordinateSystem=n}),e.eachSeriesByType("radar",function(i){i.get("coordinateSystem")==="radar"&&(i.coordinateSystem=a[i.get("radarIndex")||0])}),a},r.dimensions=[],r})();function Xe(r){r.registerCoordinateSystem("radar",Ee),r.registerComponentModel(Pe),r.registerComponentView(He),r.registerVisual({seriesType:"radar",reset:function(e){var t=e.getData();t.each(function(a){t.setItemVisual(a,"legendIcon","roundRect")}),t.setVisual("legendIcon","roundRect")}})}var k=v,Ge=H,X=-1,le=(function(){function r(e){var t=e.mappingMethod,a=e.type,i=this.option=se(e);this.type=a,this.mappingMethod=t,this._normalizeData=Be[t];var n=r.visualHandlers[a];this.applyVisual=n.applyVisual,this.getColorMapper=n.getColorMapper,this._normalizedToVisual=n._normalizedToVisual[t],t==="piecewise"?(Q(i),Re(i)):t==="category"?i.categories?Fe(i):Q(i,!0):(_e(t!=="linear"||i.dataExtent),Q(i))}return r.prototype.mapValueToVisual=function(e){var t=this._normalizeData(e);return this._normalizedToVisual(t,e)},r.prototype.getNormalizer=function(){return ne(this._normalizeData,this)},r.listVisualTypes=function(){return ze(r.visualHandlers)},r.isValidType=function(e){return r.visualHandlers.hasOwnProperty(e)},r.eachVisual=function(e,t,a){H(e)?v(e,t,a):t.call(a,e)},r.mapVisual=function(e,t,a){var i,n=P(e)?[]:H(e)?{}:(i=!0,null);return r.eachVisual(e,function(o,s){var u=t.call(a,o,s);i?n=u:n[s]=u}),n},r.retrieveVisuals=function(e){var t={},a;return e&&k(r.visualHandlers,function(i,n){e.hasOwnProperty(n)&&(t[n]=e[n],a=!0)}),a?t:null},r.prepareVisualTypes=function(e){if(P(e))e=e.slice();else if(Ge(e)){var t=[];k(e,function(a,i){t.push(i)}),e=t}else return[];return e.sort(function(a,i){return i==="color"&&a!=="color"&&a.indexOf("color")===0?1:-1}),e},r.dependsOn=function(e,t){return t==="color"?!!(e&&e.indexOf(t)===0):e===t},r.findPieceIndex=function(e,t,a){for(var i,n=1/0,o=0,s=t.length;o<s;o++){var u=t[o].value;if(u!=null){if(u===e||O(u)&&u===e+"")return o;a&&m(u,o)}}for(var o=0,s=t.length;o<s;o++){var f=t[o],l=f.interval,h=f.close;if(l){if(l[0]===-1/0){if(B(h[1],e,l[1]))return o}else if(l[1]===1/0){if(B(h[0],l[0],e))return o}else if(B(h[0],l[0],e)&&B(h[1],e,l[1]))return o;a&&m(l[0],o),a&&m(l[1],o)}}if(a)return e===1/0?t.length-1:e===-1/0?0:i;function m(b,c){var g=Math.abs(b-e);g<n&&(n=g,i=c)}},r.visualHandlers={color:{applyVisual:z("color"),getColorMapper:function(){var e=this.option;return ne(e.mappingMethod==="category"?function(t,a){return!a&&(t=this._normalizeData(t)),C.call(this,t)}:function(t,a,i){var n=!!i;return!a&&(t=this._normalizeData(t)),i=q(t,e.parsedVisual,i),n?i:$(i,"rgba")},this)},_normalizedToVisual:{linear:function(e){return $(q(e,this.option.parsedVisual),"rgba")},category:C,piecewise:function(e,t){var a=W.call(this,t);return a==null&&(a=$(q(e,this.option.parsedVisual),"rgba")),a},fixed:I}},colorHue:F(function(e,t){return K(e,t)}),colorSaturation:F(function(e,t){return K(e,null,t)}),colorLightness:F(function(e,t){return K(e,null,null,t)}),colorAlpha:F(function(e,t){return Ce(e,t)}),decal:{applyVisual:z("decal"),_normalizedToVisual:{linear:null,category:C,piecewise:null,fixed:null}},opacity:{applyVisual:z("opacity"),_normalizedToVisual:J([0,1])},liftZ:{applyVisual:z("liftZ"),_normalizedToVisual:{linear:I,category:I,piecewise:I,fixed:I}},symbol:{applyVisual:function(e,t,a){var i=this.mapValueToVisual(e);a("symbol",i)},_normalizedToVisual:{linear:oe,category:C,piecewise:function(e,t){var a=W.call(this,t);return a==null&&(a=oe.call(this,e)),a},fixed:I}},symbolSize:{applyVisual:z("symbolSize"),_normalizedToVisual:J([0,1])}},r})();function Re(r){var e=r.pieceList;r.hasSpecialVisual=!1,v(e,function(t,a){t.originIndex=a,t.visual!=null&&(r.hasSpecialVisual=!0)})}function Fe(r){var e=r.categories,t=r.categoryMap={},a=r.visual;if(k(e,function(o,s){t[o]=s}),!P(a)){var i=[];H(a)?k(a,function(o,s){var u=t[s];i[u??X]=o}):i[X]=a,a=ue(r,i)}for(var n=e.length-1;n>=0;n--)a[n]==null&&(delete t[e[n]],e.pop())}function Q(r,e){var t=r.visual,a=[];H(t)?k(t,function(n){a.push(n)}):t!=null&&a.push(t);var i={color:1,symbol:1};!e&&a.length===1&&!i.hasOwnProperty(r.type)&&(a[1]=a[0]),ue(r,a)}function F(r){return{applyVisual:function(e,t,a){var i=this.mapValueToVisual(e);a("color",r(t("color"),i))},_normalizedToVisual:J([0,1])}}function oe(r){var e=this.option.visual;return e[Math.round(D(r,[0,1],[0,e.length-1],!0))]||{}}function z(r){return function(e,t,a){a(r,this.mapValueToVisual(e))}}function C(r){var e=this.option.visual;return e[this.option.loop&&r!==X?r%e.length:r]}function I(){return this.option.visual[0]}function J(r){return{linear:function(e){return D(e,r,this.option.visual,!0)},category:C,piecewise:function(e,t){var a=W.call(this,t);return a==null&&(a=D(e,r,this.option.visual,!0)),a},fixed:I}}function W(r){var e=this.option,t=e.pieceList;if(e.hasSpecialVisual){var a=le.findPieceIndex(r,t),i=t[a];if(i&&i.visual)return i.visual[this.type]}}function ue(r,e){return r.visual=e,r.type==="color"&&(r.parsedVisual=T(e,function(t){var a=Ne(t);return a||[0,0,0,1]})),e}var Be={linear:function(r){return D(r,this.option.dataExtent,[0,1],!0)},piecewise:function(r){var e=this.option.pieceList,t=le.findPieceIndex(r,e,!0);if(t!=null)return D(t,[0,e.length-1],[0,1],!0)},category:function(r){var e=this.option.categories?this.option.categoryMap[r]:r;return e??X},fixed:Le};function B(r,e,t){return r?e<=t:e<t}export{le as V,Xe as i};
|
|
1
|
+
import{_ as j,m as T,k as U,bN as ae,aL as se,D as O,o as he,aX as de,a1 as ve,bO as ge,bP as me,bQ as ye,bR as xe,y as v,H as P,ai as Ve,bS as be,aw as Ae,aK as we,bT as re,bU as Me,bV as Ie,a4 as G,bW as ie,bX as Te,b as Se,aY as Le,aU as _e,aA as D,a9 as H,bY as Ne,f as ne,aV as ze,bZ as $,b_ as q,bg as Ce,bf as K}from"./echarts-runtime-CvLr4Slh.js";var N=me.value;function R(r,e){return U({show:e},r)}var Pe=(function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(){var t=this.get("boundaryGap"),a=this.get("splitNumber"),i=this.get("scale"),n=this.get("axisLine"),o=this.get("axisTick"),s=this.get("axisLabel"),u=this.get("axisName"),f=this.get(["axisName","show"]),l=this.get(["axisName","formatter"]),h=this.get("axisNameGap"),m=this.get("triggerEvent"),b=T(this.get("indicator")||[],function(c){c.max!=null&&c.max>0&&!c.min?c.min=0:c.min!=null&&c.min<0&&!c.max&&(c.max=0);var g=u;c.color!=null&&(g=U({color:c.color},u));var d=ae(se(c),{boundaryGap:t,splitNumber:a,scale:i,axisLine:n,axisTick:o,axisLabel:s,name:c.text,showName:f,nameLocation:"end",nameGap:h,nameTextStyle:g,triggerEvent:m},!1);if(O(l)){var x=d.name;d.name=l.replace("{value}",x??"")}else he(l)&&(d.name=l(d.name,d));var y=new de(d,null,this.ecModel);return ve(y,ge.prototype),y.mainType="radar",y.componentIndex=this.componentIndex,y},this);this._indicatorModels=b},e.prototype.getIndicatorModels=function(){return this._indicatorModels},e.type="radar",e.defaultOption={z:0,center:["50%","50%"],radius:"75%",startAngle:90,axisName:{show:!0},boundaryGap:[0,0],splitNumber:5,axisNameGap:15,scale:!1,shape:"polygon",axisLine:ae({lineStyle:{color:"#bbb"}},N.axisLine),axisLabel:R(N.axisLabel,!1),axisTick:R(N.axisTick,!1),splitLine:R(N.splitLine,!0),splitArea:R(N.splitArea,!0),indicator:[]},e})(ye),De=["axisLine","axisTickLabel","axisName"],He=(function(r){j(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,i){var n=this.group;n.removeAll(),this._buildAxes(t),this._buildSplitLineAndArea(t)},e.prototype._buildAxes=function(t){var a=t.coordinateSystem,i=a.getIndicatorAxes(),n=T(i,function(o){var s=o.model.get("showName")?o.name:"",u=new xe(o.model,{axisName:s,position:[a.cx,a.cy],rotation:o.angle,labelDirection:-1,tickDirection:-1,nameDirection:1});return u});v(n,function(o){v(De,o.add,o),this.group.add(o.getGroup())},this)},e.prototype._buildSplitLineAndArea=function(t){var a=t.coordinateSystem,i=a.getIndicatorAxes();if(!i.length)return;var n=t.get("shape"),o=t.getModel("splitLine"),s=t.getModel("splitArea"),u=o.getModel("lineStyle"),f=s.getModel("areaStyle"),l=o.get("show"),h=s.get("show"),m=u.get("color"),b=f.get("color"),c=P(m)?m:[m],g=P(b)?b:[b],d=[],x=[];function y(V,M,L){var _=L%M.length;return V[_]=V[_]||[],_}if(n==="circle")for(var S=i[0].getTicksCoords(),ee=a.cx,te=a.cy,p=0;p<S.length;p++){if(l){var A=y(d,c,p);d[A].push(new Ve({shape:{cx:ee,cy:te,r:S[p].coord}}))}if(h&&p<S.length-1){var A=y(x,g,p);x[A].push(new be({shape:{cx:ee,cy:te,r0:S[p].coord,r:S[p+1].coord}}))}}else for(var E,ce=T(i,function(V,M){var L=V.getTicksCoords();return E=E==null?L.length-1:Math.min(L.length-1,E),T(L,function(_){return a.coordToPoint(_.coord,M)})}),Y=[],p=0;p<=E;p++){for(var w=[],Z=0;Z<i.length;Z++)w.push(ce[Z][p]);if(w[0]&&w.push(w[0].slice()),l){var A=y(d,c,p);d[A].push(new Ae({shape:{points:w}}))}if(h&&Y){var A=y(x,g,p-1);x[A].push(new we({shape:{points:w.concat(Y)}}))}Y=w.slice().reverse()}var fe=u.getLineStyle(),pe=f.getAreaStyle();v(x,function(V,M){this.group.add(re(V,{style:U({stroke:"none",fill:g[M%g.length]},pe),silent:!0}))},this),v(d,function(V,M){this.group.add(re(V,{style:U({fill:"none",stroke:c[M%c.length]},fe),silent:!0}))},this)},e.type="radar",e})(Me),ke=(function(r){j(e,r);function e(t,a,i){var n=r.call(this,t,a,i)||this;return n.type="value",n.angle=0,n.name="",n}return e})(Ie),Ee=(function(){function r(e,t,a){this.dimensions=[],this._model=e,this._indicatorAxes=T(e.getIndicatorModels(),function(i,n){var o="indicator_"+n,s=new ke(o,new ie);return s.name=i.get("name"),s.model=i,i.axis=s,this.dimensions.push(o),s},this),this.resize(e,a)}return r.prototype.getIndicatorAxes=function(){return this._indicatorAxes},r.prototype.dataToPoint=function(e,t){var a=this._indicatorAxes[t];return this.coordToPoint(a.dataToCoord(e),t)},r.prototype.coordToPoint=function(e,t){var a=this._indicatorAxes[t],i=a.angle,n=this.cx+e*Math.cos(i),o=this.cy-e*Math.sin(i);return[n,o]},r.prototype.pointToData=function(e){var t=e[0]-this.cx,a=e[1]-this.cy,i=Math.sqrt(t*t+a*a);t/=i,a/=i;for(var n=Math.atan2(-a,t),o=1/0,s,u=-1,f=0;f<this._indicatorAxes.length;f++){var l=this._indicatorAxes[f],h=Math.abs(n-l.angle);h<o&&(s=l,u=f,o=h)}return[u,+(s&&s.coordToData(i))]},r.prototype.resize=function(e,t){var a=e.get("center"),i=t.getWidth(),n=t.getHeight(),o=Math.min(i,n)/2;this.cx=G(a[0],i),this.cy=G(a[1],n),this.startAngle=e.get("startAngle")*Math.PI/180;var s=e.get("radius");(O(s)||Se(s))&&(s=[0,s]),this.r0=G(s[0],o),this.r=G(s[1],o),v(this._indicatorAxes,function(u,f){u.setExtent(this.r0,this.r);var l=this.startAngle+f*Math.PI*2/this._indicatorAxes.length;l=Math.atan2(Math.sin(l),Math.cos(l)),u.angle=l},this)},r.prototype.update=function(e,t){var a=this._indicatorAxes,i=this._model;v(a,function(s){s.scale.setExtent(1/0,-1/0)}),e.eachSeriesByType("radar",function(s,u){if(!(s.get("coordinateSystem")!=="radar"||e.getComponent("radar",s.get("radarIndex"))!==i)){var f=s.getData();v(a,function(l){l.scale.unionExtentFromData(f,f.mapDimension(l.dim))})}},this);var n=i.get("splitNumber"),o=new ie;o.setExtent(0,n),o.setInterval(1),v(a,function(s,u){Te(s.scale,s.model,o)})},r.prototype.convertToPixel=function(e,t,a){return console.warn("Not implemented."),null},r.prototype.convertFromPixel=function(e,t,a){return console.warn("Not implemented."),null},r.prototype.containPoint=function(e){return console.warn("Not implemented."),!1},r.create=function(e,t){var a=[];return e.eachComponent("radar",function(i){var n=new r(i,e,t);a.push(n),i.coordinateSystem=n}),e.eachSeriesByType("radar",function(i){i.get("coordinateSystem")==="radar"&&(i.coordinateSystem=a[i.get("radarIndex")||0])}),a},r.dimensions=[],r})();function Xe(r){r.registerCoordinateSystem("radar",Ee),r.registerComponentModel(Pe),r.registerComponentView(He),r.registerVisual({seriesType:"radar",reset:function(e){var t=e.getData();t.each(function(a){t.setItemVisual(a,"legendIcon","roundRect")}),t.setVisual("legendIcon","roundRect")}})}var k=v,Ge=H,X=-1,le=(function(){function r(e){var t=e.mappingMethod,a=e.type,i=this.option=se(e);this.type=a,this.mappingMethod=t,this._normalizeData=Be[t];var n=r.visualHandlers[a];this.applyVisual=n.applyVisual,this.getColorMapper=n.getColorMapper,this._normalizedToVisual=n._normalizedToVisual[t],t==="piecewise"?(Q(i),Re(i)):t==="category"?i.categories?Fe(i):Q(i,!0):(_e(t!=="linear"||i.dataExtent),Q(i))}return r.prototype.mapValueToVisual=function(e){var t=this._normalizeData(e);return this._normalizedToVisual(t,e)},r.prototype.getNormalizer=function(){return ne(this._normalizeData,this)},r.listVisualTypes=function(){return ze(r.visualHandlers)},r.isValidType=function(e){return r.visualHandlers.hasOwnProperty(e)},r.eachVisual=function(e,t,a){H(e)?v(e,t,a):t.call(a,e)},r.mapVisual=function(e,t,a){var i,n=P(e)?[]:H(e)?{}:(i=!0,null);return r.eachVisual(e,function(o,s){var u=t.call(a,o,s);i?n=u:n[s]=u}),n},r.retrieveVisuals=function(e){var t={},a;return e&&k(r.visualHandlers,function(i,n){e.hasOwnProperty(n)&&(t[n]=e[n],a=!0)}),a?t:null},r.prepareVisualTypes=function(e){if(P(e))e=e.slice();else if(Ge(e)){var t=[];k(e,function(a,i){t.push(i)}),e=t}else return[];return e.sort(function(a,i){return i==="color"&&a!=="color"&&a.indexOf("color")===0?1:-1}),e},r.dependsOn=function(e,t){return t==="color"?!!(e&&e.indexOf(t)===0):e===t},r.findPieceIndex=function(e,t,a){for(var i,n=1/0,o=0,s=t.length;o<s;o++){var u=t[o].value;if(u!=null){if(u===e||O(u)&&u===e+"")return o;a&&m(u,o)}}for(var o=0,s=t.length;o<s;o++){var f=t[o],l=f.interval,h=f.close;if(l){if(l[0]===-1/0){if(B(h[1],e,l[1]))return o}else if(l[1]===1/0){if(B(h[0],l[0],e))return o}else if(B(h[0],l[0],e)&&B(h[1],e,l[1]))return o;a&&m(l[0],o),a&&m(l[1],o)}}if(a)return e===1/0?t.length-1:e===-1/0?0:i;function m(b,c){var g=Math.abs(b-e);g<n&&(n=g,i=c)}},r.visualHandlers={color:{applyVisual:z("color"),getColorMapper:function(){var e=this.option;return ne(e.mappingMethod==="category"?function(t,a){return!a&&(t=this._normalizeData(t)),C.call(this,t)}:function(t,a,i){var n=!!i;return!a&&(t=this._normalizeData(t)),i=q(t,e.parsedVisual,i),n?i:$(i,"rgba")},this)},_normalizedToVisual:{linear:function(e){return $(q(e,this.option.parsedVisual),"rgba")},category:C,piecewise:function(e,t){var a=W.call(this,t);return a==null&&(a=$(q(e,this.option.parsedVisual),"rgba")),a},fixed:I}},colorHue:F(function(e,t){return K(e,t)}),colorSaturation:F(function(e,t){return K(e,null,t)}),colorLightness:F(function(e,t){return K(e,null,null,t)}),colorAlpha:F(function(e,t){return Ce(e,t)}),decal:{applyVisual:z("decal"),_normalizedToVisual:{linear:null,category:C,piecewise:null,fixed:null}},opacity:{applyVisual:z("opacity"),_normalizedToVisual:J([0,1])},liftZ:{applyVisual:z("liftZ"),_normalizedToVisual:{linear:I,category:I,piecewise:I,fixed:I}},symbol:{applyVisual:function(e,t,a){var i=this.mapValueToVisual(e);a("symbol",i)},_normalizedToVisual:{linear:oe,category:C,piecewise:function(e,t){var a=W.call(this,t);return a==null&&(a=oe.call(this,e)),a},fixed:I}},symbolSize:{applyVisual:z("symbolSize"),_normalizedToVisual:J([0,1])}},r})();function Re(r){var e=r.pieceList;r.hasSpecialVisual=!1,v(e,function(t,a){t.originIndex=a,t.visual!=null&&(r.hasSpecialVisual=!0)})}function Fe(r){var e=r.categories,t=r.categoryMap={},a=r.visual;if(k(e,function(o,s){t[o]=s}),!P(a)){var i=[];H(a)?k(a,function(o,s){var u=t[s];i[u??X]=o}):i[X]=a,a=ue(r,i)}for(var n=e.length-1;n>=0;n--)a[n]==null&&(delete t[e[n]],e.pop())}function Q(r,e){var t=r.visual,a=[];H(t)?k(t,function(n){a.push(n)}):t!=null&&a.push(t);var i={color:1,symbol:1};!e&&a.length===1&&!i.hasOwnProperty(r.type)&&(a[1]=a[0]),ue(r,a)}function F(r){return{applyVisual:function(e,t,a){var i=this.mapValueToVisual(e);a("color",r(t("color"),i))},_normalizedToVisual:J([0,1])}}function oe(r){var e=this.option.visual;return e[Math.round(D(r,[0,1],[0,e.length-1],!0))]||{}}function z(r){return function(e,t,a){a(r,this.mapValueToVisual(e))}}function C(r){var e=this.option.visual;return e[this.option.loop&&r!==X?r%e.length:r]}function I(){return this.option.visual[0]}function J(r){return{linear:function(e){return D(e,r,this.option.visual,!0)},category:C,piecewise:function(e,t){var a=W.call(this,t);return a==null&&(a=D(e,r,this.option.visual,!0)),a},fixed:I}}function W(r){var e=this.option,t=e.pieceList;if(e.hasSpecialVisual){var a=le.findPieceIndex(r,t),i=t[a];if(i&&i.visual)return i.visual[this.type]}}function ue(r,e){return r.visual=e,r.type==="color"&&(r.parsedVisual=T(e,function(t){var a=Ne(t);return a||[0,0,0,1]})),e}var Be={linear:function(r){return D(r,this.option.dataExtent,[0,1],!0)},piecewise:function(r){var e=this.option.pieceList,t=le.findPieceIndex(r,e,!0);if(t!=null)return D(t,[0,e.length-1],[0,1],!0)},category:function(r){var e=this.option.categories?this.option.categoryMap[r]:r;return e??X},fixed:Le};function B(r,e,t){return r?e<=t:e<t}export{le as V,Xe as i};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as e,B as a}from"./index-
|
|
1
|
+
import{j as e,B as a}from"./index-CgkdZ6Oc.js";import{C as r,a as d,b as l,c,d as x}from"./card-C9Hpeq1c.js";function h({authType:s,children:t,description:i,methodName:n}){return e.jsxs("div",{className:"space-y-8 pb-12",children:[e.jsxs("header",{className:"space-y-2",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(a,{variant:"secondary",children:"Authentication"}),e.jsx(a,{variant:"outline",children:s})]}),e.jsx("h1",{className:"font-heading text-3xl font-semibold tracking-tight",children:n}),e.jsx("p",{className:"max-w-3xl text-muted-foreground",children:i})]}),e.jsxs(r,{className:"max-w-2xl",children:[e.jsxs(d,{children:[e.jsx(l,{children:"Default component"}),e.jsx(c,{children:"Installed Registries add this UI to the dynamic login page automatically."})]}),e.jsx(x,{children:e.jsx("div",{className:"max-w-sm",children:t})})]})]})}export{h as A};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{j as r}from"./index-CgkdZ6Oc.js";import{A as i}from"./auto-redirect-provider-iTzGEDpU.js";import{i as t}from"./use-wecom-sign-in-PPIMLvGa.js";function n({children:e}){const o=t();return r.jsx(i,{resource:"wecom",action:"checkLogin",enabled:o,query:{isWeComBrowser:o},children:e})}export{n as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index-
|
|
2
|
-
import{
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index-C-tdHirk.js","assets/index-CgkdZ6Oc.js","assets/index-NH3aqqQz.css"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{a$ as p,b as d,aY as m,aZ as s,b0 as w,j as k,b1 as y,b2 as A}from"./index-CgkdZ6Oc.js";import{i as b}from"./use-dingtalk-sign-in-mrq6K5Yx.js";const T=new Set(["/login","/signin","/register","/forgot-password"]);async function C(l){const u=await A(()=>import("./index-C-tdHirk.js").then(c=>c.i),__vite__mapDeps([0,1,2])),n=u.default??u;return new Promise((c,h)=>{const i=t=>{const a=(t==null?void 0:t.code)??(t==null?void 0:t.authCode);a?c(String(a)):h(new Error("DingTalk did not return an authorization code."))},o=t=>h(new Error((t==null?void 0:t.errorMessage)||(t==null?void 0:t.message)||"Unable to request a DingTalk authorization code.")),f=()=>{var a,e;const t=(e=(a=n==null?void 0:n.runtime)==null?void 0:a.permission)==null?void 0:e.requestAuthCode;if(typeof t=="function"){const r=t({corpId:l,success:i,fail:o});r!=null&&r.then&&r.then(i).catch(o);return}if(typeof(n==null?void 0:n.getAuthCode)=="function"){n.getAuthCode({corpId:l,success:i,fail:o});return}o({message:"DingTalk auth-code API is unavailable."})};try{typeof n.ready=="function"?n.ready(f):f()}catch(t){o(t)}})}function v({children:l}){const{pathname:u,search:n}=p(),c=d.useRef(!1),h=b(),i=m(`${u}${n}`),o=h&&!s.getToken()&&!T.has(u),[f,t]=d.useState(o);return d.useEffect(()=>{if(!o||c.current){t(!1);return}c.current=!0,t(!0);const a=new AbortController;return(async()=>{try{const e=await s.action("dingtalk","checkLogin",{method:"GET",query:{isDingTalkBrowser:!0,redirect:i},signal:a.signal,authenticator:null,includeRole:!1,withAclMeta:!1});if((e==null?void 0:e.success)!==!1)return;if(e.autoLoginType==="oauth"&&e.authUrl){window.location.replace(s.resolveUrl(e.authUrl));return}if(e.autoLoginType!=="internal"||!e.authenticator||!e.corpId)return;const r=await C(e.corpId),g=await s.action("auth","signIn",{method:"POST",authenticator:e.authenticator,body:{authCode:r,loginType:"internal"}});if(!g.token)throw new Error("NocoBase did not return an access token.");s.setAuthenticator(e.authenticator),s.setToken(g.token),s.setRole(null),w(),window.location.replace(i)}catch(e){e instanceof DOMException&&e.name==="AbortError"||console.warn("Unable to complete DingTalk automatic login",e)}finally{t(!1)}})(),()=>a.abort()},[i,o]),f?k.jsx(y,{className:"min-h-svh"}):l}export{v as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{j as e}from"./index-CgkdZ6Oc.js";import{A as t}from"./auto-redirect-provider-iTzGEDpU.js";function c({children:r}){return e.jsx(t,{resource:"saml",action:"checkRedirect",children:r})}export{c as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{j as e}from"./index-CgkdZ6Oc.js";import{A as t}from"./auto-redirect-provider-iTzGEDpU.js";function c({children:r}){return e.jsx(t,{resource:"oidc",action:"checkRedirect",children:r})}export{c as default};
|
package/dist/assets/{auto-redirect-provider-CfwRvYOI.js → auto-redirect-provider-iTzGEDpU.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{a$ as b,b as s,aY as A,aZ as a,j as w,b1 as x}from"./index-CgkdZ6Oc.js";const E=new Set(["/login","/signin","/register","/forgot-password"]);function C({resource:o,action:r,enabled:d=!0,query:c,children:g}){const{pathname:i,search:m}=b(),l=s.useRef(!1),u=A(`${i}${m}`),n=d&&!a.getToken()&&!E.has(i),[p,t]=s.useState(n),f=s.useMemo(()=>c,[JSON.stringify(c)]);return s.useEffect(()=>{if(!n||l.current){t(!1);return}l.current=!0,t(!0);const h=new AbortController;return a.action(o,r,{method:"GET",query:{redirect:u,...f},signal:h.signal,authenticator:null,includeRole:!1,withAclMeta:!1}).then(e=>{if((e==null?void 0:e.success)===!1&&e.authUrl){window.location.replace(a.resolveUrl(e.authUrl));return}t(!1)}).catch(e=>{e instanceof DOMException&&e.name==="AbortError"||t(!1)}),()=>h.abort()},[r,u,o,n,f]),p?w.jsx(x,{className:"min-h-svh"}):g}export{C as A};
|