PageSourceSearch

https://preview-8271-ng-zorro-antd.surge.sh/9793.74f7ccf64528329a.js

js preview-8271-ng-zorro-antd.surge.sh collected 2026-10-03 14:58:58 UTC 11,011 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunkng_zorro_antd_doc=self.webpackChunkng_zorro_antd_doc||[]).push([[9793],{9793:(nt,T,c)=>{c.d(T,{M:()=>C,W:()=>et});var t=c(9212),p=c(7582),z=c(6814),I=c(8645),P=c(9773),_=c(2196),x=c(2755),d=c(6700),y=c(227),O=c(9388);function $(n,i){if(1&n&&(t.ynx(0),t._UZ(1,"span",8),t.BQk()),2&n){const e=t.oxw(3);t.xp6(1),t.Q6J("nzType",e.icon)}}function D(n,i){if(1&n&&(t.ynx(0),t._uU(1),t.BQk()),2&n){const e=i.$implicit,s=t.oxw(4);t.xp6(1),t.hij(" ",e(s.nzPercent)," ")}}const N=n=>({$implicit:n});function M(n,i){if(1&n&&t.YNc(0,D,2,1,"ng-container",9),2&n){const e=t.oxw(3);t.Q6J("nzStringTemplateOutlet",e.formatter)("nzStringTemplateOutletContext",t.VKq(2,N,e.nzPercent))}}function E(n,i){if(1&n&&(t.TgZ(0,"span",5),t.YNc(1,$,2,1,"ng-container",6)(2,M,1,4,"ng-template",null,7,t.W1O),t.qZA()),2&n){const e=t.MAs(3),s=t.oxw(2);t.xp6(1),t.Q6J("ngIf",("exception"===s.status||"success"===s.status)&&!s.nzFormat)("ngIfElse",e)}}function G(n,i){if(1&n&&t.YNc(0,E,4,2,"span",4),2&n){const e=t.oxw();t.Q6J("ngIf",e.nzShowInfo)}}function W(n,i){if(1&n&&t._UZ(0,"div",17),2&n){const e=t.oxw(4);t.Udp("width",e.nzSuccessPercent,"%")("border-radius","round"===e.nzStrokeLinecap?"100px":"0")("height",e.strokeWidth,"px")}}function w(n,i){if(1&n&&(t.TgZ(0,"div",13)(1,"div",14),t._UZ(2,"div",15),t.YNc(3,W,1,6,"div",16),t.qZA()()),2&n){const e=t.oxw(3);t.xp6(2),t.Udp("width",e.nzPercent,"%")("border-radius","round"===e.nzStrokeLinecap?"100px":"0")("background",e.isGradient?null:e.nzStrokeColor)("background-image",e.isGradient?e.lineGradient:null)("height",e.strokeWidth,"px"),t.xp6(1),t.Q6J("ngIf",e.nzSuccessPercent||0===e.nzSuccessPercent)}}function A(n,i){}function Q(n,i){if(1&n&&(t.ynx(0),t.YNc(1,w,4,11,"div",11)(2,A,0,0,"ng-template",12),t.BQk()),2&n){const e=t.oxw(2),s=t.MAs(1);t.xp6(1),t.Q6J("ngIf",!e.isSteps),t.xp6(1),t.Q6J("ngTemplateOutlet",s)}}function Z(n,i){1&n&&t._UZ(0,"div",20),2&n&&t.Q6J("ngStyle",i.$implicit)}function J(n,i){}function F(n,i){if(1&n&&(t.TgZ(0,"div",18),t.YNc(1,Z,1,1,"div",19)(2,J,0,0,"ng-template",12),t.qZA()),2&n){const e=t.oxw(2),s=t.MAs(1);t.xp6(1),t.Q6J("ngForOf",e.steps),t.xp6(1),t.Q6J("ngTemplateOutlet",s)}}
1function U(n,i){if(1&n&&(t.TgZ(0,"div"),t.YNc(1,Q,3,2,"ng-container",2)(2,F,3,2,"div",10),t.qZA()),2&n){const e=t.oxw();t.xp6(1),t.Q6J("ngIf",!e.isSteps),t.xp6(1),t.Q6J("ngIf",e.isSteps)}}function L(n,i){if(1&n&&(t.O4$(),t._UZ(0,"stop")),2&n){const e=i.$implicit;t.uIk("offset",e.offset)("stop-color",e.color)}}function b(n,i){if(1&n&&(t.O4$(),t.TgZ(0,"defs")(1,"linearGradient",24),t.YNc(2,L,1,2,"stop",25),t.qZA()()),2&n){const e=t.oxw(2);t.xp6(1),t.Q6J("id","gradient-"+e.gradientId),t.xp6(1),t.Q6J("ngForOf",e.circleGradient)}}function B(n,i){if(1&n&&(t.O4$(),t._UZ(0,"path",26)),2&n){const e=i.$implicit,s=t.oxw(2);t.Q6J("ngStyle",e.strokePathStyle),t.uIk("d",s.pathString)("stroke-linecap",s.nzStrokeLinecap)("stroke",e.stroke)("stroke-width",s.nzPercent?s.strokeWidth:0)}}function Y(n,i){1&n&&t.O4$()}function R(n,i){if(1&n&&(t.TgZ(0,"div",14),t.O4$(),t.TgZ(1,"svg",21),t.YNc(2,b,3,2,"defs",2),t._UZ(3,"path",22),t.YNc(4,B,1,5,"path",23),t.qZA(),t.YNc(5,Y,0,0,"ng-template",12),t.qZA()),2&n){const e=t.oxw(),s=t.MAs(1);t.Udp("width",e.nzWidth,"px")("height",e.nzWidth,"px")("font-size",.15*e.nzWidth+6,"px"),t.ekj("ant-progress-circle-gradient",e.isGradient),t.xp6(2),t.Q6J("ngIf",e.isGradient),t.xp6(1),t.Q6J("ngStyle",e.trailPathStyle),t.uIk("stroke-width",e.strokeWidth)("d",e.pathString),t.xp6(1),t.Q6J("ngForOf",e.progressCirclePath)("ngForTrackBy",e.trackByFn),t.xp6(1),t.Q6J("ngTemplateOutlet",s)}}const k=n=>{let i=[];return Object.keys(n).forEach(e=>{const s=n[e],o=function K(n){return+n.replace("%","")}(e);isNaN(o)||i.push({key:o,value:s})}),i=i.sort((e,s)=>e.key-s.key),i};let V=0;const v="progress",H=new Map([["success","check"],["exception","close"]]),q=new Map([["normal","#108ee9"],["exception","#ff5500"],["success","#87d068"]]),tt=n=>`${n}%`;let C=(()=>{class n{get formatter(){return this.nzFormat||tt}get status(){return this.nzStatus||this.inferredStatus}get strokeWidth(){return this.nzStrokeWidth||("line"===this.nzType&&"small"!==this.nzSize?8:6)}get isCircleStyle(){return"circle"===this.nzType||"dashboard"===this.nzType}constructor(e,s,o){this.cdr=e,this.nzConfigService=s,this.directionality=o,this._nzModuleName=v,this.nzShowInfo=!0,this.nzWidth=132,this.nzStrokeColor=void 0,this.nzSize="default",this.nzPercent=0,this.nzStrokeWidth=void 0,this.nzGapDegree=void 0,this.nzType="line",this.nzGapPosition="top",this.nzStrokeLinecap="round",this.nzSteps=0,this.steps=[],this.lineGradient=null,this.isGradient=!1,this.isSteps=!1,this.gradientId=V++,this.progressCirclePath=[],this.trailPathStyle=null,this.dir="ltr",this.trackByFn=r=>`${r}`,this.cachedStatus="normal",this.inferredStatus="normal",this.destroy$=new I.x}ngOnChanges(e){const{nzSteps:s,nzGapPosition:o,nzStrokeLinecap:r,nzStrokeColor:a,nzGapDegree:g,nzType:f,nzStatus:h,nzPercent:l,nzSuccessPercent:u,nzStrokeWidth:S}=e;h&&(this.cachedStatus=this.nzStatus||this.cachedStatus),(l||u)&&(parseInt(this.nzPercent.toString(),10)>=100?((0,d.DX)(this.nzSuccessPercent)&&this.nzSuccessPercent>=100||void 0===this.nzSuccessPercent)&&(this.inferredStatus="success"):this.inferredStatus=this.cachedStatus),(h||l||u||a)&&this.updateIcon(),a&&this.setStrokeColor(),(o||r||g||f||l||a||a)&&this.getCirclePaths(),(l||s||S)&&(this.isSteps=this.nzSteps>0,this.isSteps&&this.getSteps())}ngOnInit(){this.nzConfigService.getConfigChangeEventForComponent(v).pipe((0,P.R)(this.destroy$)).subscribe(()=>{this.updateIcon(),this.setStrokeColor(),this.getCirclePaths()}),this.directionality.change?.pipe((0,P.R)(this.destroy$)).subscribe(e=>{this.dir=e,this.cdr.detectChanges()}),this.dir=this.directionality.value}ngOnDestroy(){this.destroy$.next(),this.destroy$.complete()}updateIcon(){const e=H.get(this.status);this.icon=e?e+(this.isCircleStyle?"-o":"-circle-fill"):""}getSteps(){const e=Math.floor(this.nzSteps*(this.nzPercent/100)),s="small"===this.nzSize?2:14,o=[];for(let r=0;r<this.nzSteps;r++){let a;r<=e-1&&(a=this.nzStrokeColor),o.push({backgroundColor:`${a}`,width:`${s}px`,height:`${this.strokeWidth}px`})}this.steps=o}getCirclePaths(){if(!this.isCircleStyle)return;const e=(0,d.DX)(this.nzSuccessPercent)?[this.nzSuccessPercent,this.nzPercent]:[this.nzPercent],s=50-this.strokeWidth/2,r=2*Math.PI*s,a=this.nzGapDegree||("circle"===this.nzType?0:75);let g=0,f=-s,h=0,l=-2*s;switch(this.nzGapPosition||("circle"===this.nzType?"top":"bottom")){case"left":g=-s,f=0,h=2*s,l=0;break;case"right":g=s,f=0,h=-2*s,l=0;break;case"bottom":f=s,l=2*s}this.pathString=`M 50,50 m ${g},${f}\n       a ${s},${s} 0 1 1 ${h},${-l}\n       a ${s},${s} 0 1 1 ${-h},${l}`,this.trailPathStyle={strokeDasharray:`${r-a}
1px ${r}px`,strokeDashoffset:`-${a/2}px`,transition:"stroke-dashoffset .3s ease 0s, stroke-dasharray .3s ease 0s, stroke .3s"},this.progressCirclePath=e.map((u,S)=>{const m=2===e.length&&0===S;return{stroke:this.isGradient&&!m?`url(#gradient-${this.gradientId})`:null,strokePathStyle:{stroke:this.isGradient?null:m?q.get("success"):this.nzStrokeColor,transition:"stroke-dashoffset .3s ease 0s, stroke-dasharray .3s ease 0s, stroke .3s, stroke-width .06s ease .3s",strokeDasharray:`${(u||0)/100*(r-a)}px ${r}px`,strokeDashoffset:`-${a/2}px`}}}).reverse()}setStrokeColor(){const e=this.nzStrokeColor,s=this.isGradient=!!e&&"string"!=typeof e;s&&!this.isCircleStyle?this.lineGradient=(n=>{const{from:i="#1890ff",to:e="#1890ff",direction:s="to right",...o}=n;return 0!==Object.keys(o).length?`linear-gradient(${s}, ${k(o).map(({key:a,value:g})=>`${g} ${a}%`).join(", ")})`:`linear-gradient(${s}, ${i}, ${e})`})(e):s&&this.isCircleStyle?this.circleGradient=(n=>k(this.nzStrokeColor).map(({key:i,value:e})=>({offset:`${i}%`,color:e})))():(this.lineGradient=null,this.circleGradient=[])}static#t=this.\u0275fac=function(s){return new(s||n)(t.Y36(t.sBO),t.Y36(_.jY),t.Y36(O.Is,8))};static#e=this.\u0275cmp=t.Xpm({type:n,selectors:[["nz-progress"]],inputs:{nzShowInfo:"nzShowInfo",nzWidth:"nzWidth",nzStrokeColor:"nzStrokeColor",nzSize:"nzSize",nzFormat:"nzFormat",nzSuccessPercent:"nzSuccessPercent",nzPercent:"nzPercent",nzStrokeWidth:"nzStrokeWidth",nzGapDegree:"nzGapDegree",nzStatus:"nzStatus",nzType:"nzType",nzGapPosition:"nzGapPosition",nzStrokeLinecap:"nzStrokeLinecap",nzSteps:"nzSteps"},exportAs:["nzProgress"],standalone:!0,features:[t.TTD,t.jDz],decls:5,vars:17,consts:[["progressInfoTemplate",""],[3,"ngClass"],[4,"ngIf"],["class","ant-progress-inner",3,"width","height","fontSize","ant-progress-circle-gradient",4,"ngIf"],["class","ant-progress-text",4,"ngIf"],[1,"ant-progress-text"],[4,"ngIf","ngIfElse"],["formatTemplate",""],["nz-icon","",3,"nzType"],[4,"nzStringTemplateOutlet","nzStringTemplateOutletContext"],["class","ant-progress-steps-outer",4,"ngIf"],["class","ant-progress-outer",4,"ngIf"],[3,"ngTemplateOutlet"],[1,"ant-progress-outer"],[1,"ant-progress-inner"],[1,"ant-progress-bg"],["class","ant-progress-success-bg",3,"width","border-radius","height",4,"ngIf"],[1,"ant-progress-success-bg"],[1,"ant-progress-steps-outer"],["class","ant-progress-steps-item",3,"ngStyle",4,"ngFor","ngForOf"],[1,"ant-progress-steps-item",3,"ngStyle"],["viewBox","0 0 100 100",1,"ant-progress-circle"],["stroke","#f3f3f3","fill-opacity","0",1,"ant-progress-circle-trail",3,"ngStyle"],["class","ant-progress-circle-path","fill-opacity","0",3,"ngStyle",4,"ngFor","ngForOf","ngForTrackBy"],["x1","100%","y1","0%","x2","0%","y2","0%",3,"id"],[4,"ngFor","ngForOf"],["fill-opacity","0",1,"ant-progress-circle-path",3,"ngStyle"]],template:function(s,o){1&s&&(t.YNc(0,G,1,1,"ng-template",null,0,t.W1O),t.TgZ(2,"div",1),t.YNc(3,U,3,2,"div",2)(4,R,6,15,"div",3),t.qZA()),2&s&&(t.xp6(2),t.ekj("ant-progress-line","line"===o.nzType)("ant-progress-small","small"===o.nzSize)("ant-progress-default","default"===o.nzSize)("ant-progress-show-info",o.nzShowInfo)("ant-progress-circle",o.isCircleStyle)("ant-progress-steps",o.isSteps)("ant-progress-rtl","rtl"===o.dir),t.Q6J("ngClass","ant-progress ant-progress-status-"+o.status),t.xp6(1),t.Q6J("ngIf","line"===o.nzType),t.xp6(1),t.Q6J("ngIf",o.isCircleStyle))},dependencies:[z.O5,y.PV,y.Ls,x.T,x.f,z.mk,z.tP,z.sg,z.PC],encapsulation:2,changeDetection:0})}return(0,p.gn)([(0,_.oS)()],n.prototype,"nzShowInfo",void 0),(0,p.gn)([(0,_.oS)()],n.prototype,"nzStrokeColor",void 0),(0,p.gn)([(0,_.oS)()],n.prototype,"nzSize",void 0),(0,p.gn)([(0,d.Rn)()],n.prototype,"nzSuccessPercent",void 0),(0,p.gn)([(0,d.Rn)()],n.prototype,"nzPercent",void 0),(0,p.gn)([(0,_.oS)(),(0,d.Rn)()],n.prototype,"nzStrokeWidth",void 0),(0,p.gn)([(0,_.oS)(),(0,d.Rn)()],n.prototype,"nzGapDegree",void 0),(0,p.gn)([(0,_.oS)()],n.prototype,"nzGapPosition",void 0),(0,p.gn)([(0,_.oS)()],n.prototype,"nzStrokeLinecap",void 0),(0,p.gn)([(0,d.Rn)()],n.prototype,"nzSteps",void 0),n})(),et=(()=>{class n{static#t=this.\u0275fac=function(s){return new(s||n)};static#e=this.\u0275mod=t.oAB({type:n});static#n=this.\u0275inj=t.cJS({imports:[C]})}return n})()}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.