1import{d as Oe,e as Ze}from"./chunk-4LWRTZ4J.js";import{B as Pe,D as ae,Eb as xe,Ja as V,Kb as Te,Lb as Re,Ob as Ne,Pb as Fe,Xa as I,Xb as Me,db as A,ea as T,fb as R,qb as De,sb as Ee}from"./chunk-FE3MHUBC.js";import{Cc as ke,E as M,Eb as K,Fb as ve,Ja as de,M as ce,Ma as ge,Ob as we,Qb as Z,Sb as W,Ub as q,Vb as X,Wb as J,Xb as ee,Yb as g,Z as me,Zb as C,_ as O,_b as _,cc as H,ec as ye,f as F,fb as fe,ga as he,ha as pe,ic as k,jc as Ce,kb as z,kc as v,l as E,la as s,lc as _e,m as u,mc as Se,oc as te,pc as ie,qc as ne,qd as oe,sa as P,ta as D,ud as Ie,vc as L,wa as U,wb as Y,wc as x,xa as B,xb as ue,ya as Q,yb as ze,z as G,zc as be}from"./chunk-OQ4XWHPB.js";import{a as b,f as j}from"./chunk-JNGVGNCT.js";var Ge=["*"],Ue=["imgRef"],Be=["imagePreviewWrapper"];function Qe(t,r){if(t&1){let e=H();g(0,"div",13),k("click",function(i){P(e);let o=v();return D(o.onSwitchLeft(i))}),_(1,"nz-icon",14),C(),g(2,"div",15),k("click",function(i){P(e);let o=v();return D(o.onSwitchRight(i))}),_(3,"nz-icon",16),C()}if(t&2){let e=v();x("ant-image-preview-switch-left-disabled",e.index<=0),z(2),x("ant-image-preview-switch-right-disabled",e.index>=e.images.length-1)}}function Ye(t,r){if(t&1&&(g(0,"li",5),be(1),C()),t&2){let e=v();z(),ke("",e.index+1," / ",e.images.length)}}function Ke(t,r){if(t&1){let e=H();g(0,"li",17),k("click",function(){let i=P(e).$implicit;return D(i.onClick())}),_(1,"nz-icon",18),C()}if(t&2){let e=r.$implicit,n=v();x("ant-image-preview-operations-operation-disabled",n.zoomOutDisabled&&e.type==="zoomOut"),z(),ee("nzType",e.icon)("nzRotate",e.rotate??0)}}function qe(t,r){if(t&1&&_(0,"img",20,1),t&2){let e=v().$implicit,n=v();L("width",e.width)("height",e.height)("transform",n.previewImageTransform),we("src",n.sanitizerResourceUrl(e.src),fe)("srcset",e.srcset)("alt",e.alt)}}function Xe(t,r){if(t&1&&Z(0,qe,2,9,"img",19),t&2){let e=r.$index,n=v();W(e===n.index?0:-1)}}var Je=(()=>{class t{nzScaleStep=null;images=[];addImage(e){this.images.push(e)}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=Y({type:t,selectors:[["nz-image-group"]],inputs:{nzScaleStep:"nzScaleStep"},exportAs:["nzImageGroup"],ngContentSelectors:Ge,decls:1,vars:0,template:function(n,i){n&1&&(_e(),Se(0))},encapsulation:2,changeDetection:0})}return t})(),Ae="image",N=class{nzKeyboard=!0;nzNoAnimation=!1;nzMaskClosable=!0;nzCloseOnNavigation=!0;nzZIndex;nzZoom;nzRotate;nzFlipHorizontally;nzFlipVertically;nzScaleStep;nzDirection};function et(t){let r={};return t.width<=t.clientWidth&&t.height<=t.clientHeight&&(r={x:0,y:0}),(t.width>t.clientWidth||t.height>t.clientHeight)&&(r={x:Le(t.left,t.width,t.clientWidth),y:Le(t.top,t.height,t.clientHeight)}),r}function tt(t){let r=t.getBoundingClientRect(),e=document.documentElement;return{left:r.left+(window.pageXOffset||e.scrollLeft)-(e.clientLeft||document.body.clientLeft||0),top:r.top+(window.pageYOffset||e.scrollTop)-(e.clientTop||document.body.clientTop||0)}}function it(){let t=document.documentElement.clientWidth,r=window.innerHeight||document.documentElement.clientHeight;return{width:t,height:r}}function Le(t,r,e){let n=t+r,i=(r-e)/2,o=null;return r>e?(t>0&&(o=i),t<0&&n<e&&(o=-i)):(t<0||n>e)&&(o=t<0?i:-i),o}var Ve={x:0,y:0},se=.5,nt=1,ot=0,$e=(()=>{class t{document=s(B);ngZone=s(ve);cdr=s(oe);nzConfigService=s(A);config=s(N);sanitizer=s(Pe);destroyRef=s(Q);_defaultNzZoom=nt;_defaultNzScaleStep=se;_defaultNzRotate=ot;images=[];index=0;isDragging=!1;visible=!0;animationStateChanged=new K;scaleStepMap=new Map;previewImageTransform="";previewImageWrapperTransform="";operations=[{icon:"close",onClick:()=>{this.onClose()},type:"close"},{icon:"zoom-in",onClick:()=>{this.onZoomIn()},type:"zoomIn"},{icon:"zoom-out",onClick:()=>{this.onZoomOut()},type:"zoomOut"},{icon:"rotate-right",onClick:()=>{this.onRotateRight()},type:"rotateRight"},{icon:"rotate-left",onClick:()=>{this.onRotateLeft()},type:"rotateLeft"},{icon:"swap",onClick:()=>{this.onHorizontalFlip()},type:"flipHorizontally"},{icon:"swap",onClick:()=>{this.onVerticalFlip()},type:"flipVertically",rotate:90}];zoomOutDisabled=!1;position=b({},Ve);previewRef;closeClick=new K;imageRef;imagePreviewWrapper;zoom=this.config.nzZoom??this._defaultNzZoom;rotate=this.config.nzRotate??this._defaultNzRotate;scaleStep=this.config.nzScaleStep??this._defaultNzScaleStep;flipHorizontally=this.config.nzFlipHorizontally??!1;flipVertically=this.config.nzFlipVertically??!1;get animationDisabled(){return this.config.nzNoAnimation??!1}get maskClosable(){let e=this.nzConfigService.getConfigForComponent(Ae)||{};return this.config.nzMaskClosable??e.nzMaskClosable??!0}constructor(){this.updateZoomOutDisabled(),this.updatePreviewImageTransform(),this.updatePreviewImageWrapperTransform()}ngOnInit(){V(this.imagePreviewWrapper.nativeElement,"mousedown").pipe(I(this.destroyRef)).subscribe(()=>{this.isDragging=!0}),V(this.imagePreviewWrapper.nativeElement,"wheel").pipe(I(this.destroyRef)).subscribe(e=>{this.ngZone.run(()=>this.wheelZoomEventHandler(e))}),V(this.document,"keydown").pipe(M(e=>e.keyCode===27),I(this.destroyRef)).subscribe(()=>{this.ngZone.run(()=>{this.onClose(),this.markForCheck()})})}setImages(e,n){n&&(this.scaleStepMap=n),this.images=e,this.markForCheck()}switchTo(e){this.index=e,this.markForCheck()}next(){this.index<this.images.length-1&&(this.reset(),this.index++,this.updatePreviewImageTransform(),this.updatePreviewImageWrapperTransform(),this.updateZoomOutDisabled(),this.markForCheck())}prev(){this.index>0&&(this.reset(),this.index--,this.updatePreviewImageTransform(),this.updatePreviewImageWrapperTransform(),this.updateZoomOutDisabled(),this.markForCheck())}markForCheck(){this.cdr.markForCheck()}onClose(){this.visible=!1,this.closeClick.emit()}onZoomIn(){let e=this.scaleStepMap.get(this.images[this.index].src??this.images[this.index].srcset)??this.scaleStep;this.zoom+=e,this.updatePreviewImageTransform(),this.updateZoomOutDisabled()}
1onZoomOut(){if(this.zoom>1){let e=this.scaleStepMap.get(this.images[this.index].src??this.images[this.index].srcset)??this.scaleStep;this.zoom-=e,this.updatePreviewImageTransform(),this.updateZoomOutDisabled(),this.zoom<=1&&this.reCenterImage()}}onRotateRight(){this.rotate+=90,this.updatePreviewImageTransform()}onRotateLeft(){this.rotate-=90,this.updatePreviewImageTransform()}onSwitchLeft(e){e.preventDefault(),e.stopPropagation(),this.prev()}onSwitchRight(e){e.preventDefault(),e.stopPropagation(),this.next()}onHorizontalFlip(){this.flipHorizontally=!this.flipHorizontally,this.updatePreviewImageTransform()}onVerticalFlip(){this.flipVertically=!this.flipVertically,this.updatePreviewImageTransform()}wheelZoomEventHandler(e){e.preventDefault(),e.stopPropagation(),this.handlerImageTransformationWhileZoomingWithMouse(e,e.deltaY),this.handleImageScaleWhileZoomingWithMouse(e.deltaY),this.updatePreviewImageWrapperTransform(),this.updatePreviewImageTransform(),this.markForCheck()}onAnimationStart(e){this.animationStateChanged.emit(e)}onAnimationDone(e){this.animationStateChanged.emit(e)}onDragEnd(e){this.isDragging=!1;let n=this.imageRef.nativeElement.offsetWidth*this.zoom,i=this.imageRef.nativeElement.offsetHeight*this.zoom,{left
1:o,top:m}=tt(this.imageRef.nativeElement),{width:c,height:f}=it(),S=this.rotate%180!==0,y=et({width:S?i:n,height:S?n:i,left:o,top:m,clientWidth:c,clientHeight:f});T(y.x)||T(y.y)?this.position=b(b({},this.position),y):!T(y.x)&&!T(y.y)&&(this.position={x:e.source.getFreeDragPosition().x,y:e.source.getFreeDragPosition().y})}sanitizerResourceUrl(e){return this.sanitizer.bypassSecurityTrustResourceUrl(e)}updatePreviewImageTransform(){this.previewImageTransform=`scale3d(${this.zoom*(this.flipHorizontally?-1:1)}, ${this.zoom*(this.flipVertically?-1:1)}, 1) rotate(${this.rotate}deg)`}updatePreviewImageWrapperTransform(){this.previewImageWrapperTransform=`translate3d(${this.position.x}px, ${this.position.y}px, 0)`}updateZoomOutDisabled(){this.zoomOutDisabled=this.zoom<=1}handlerImageTransformationWhileZoomingWithMouse(e,n){let i,o=this.imageRef.nativeElement,c=getComputedStyle(o).transform.match(/matrix.*\((.+)\)/);c?i=+c[1].split(", ")[0]:i=this.zoom;let f=(e.clientX-o.getBoundingClientRect().x)/i,S=(e.clientY-o.getBoundingClientRect().y)/i,w=n<0?this.scaleStep/2:-this.scaleStep/2;this.position.x+=-f*w*2+o.offsetWidth*w,this.position.y+=-S*w*2+o.offsetHeight*w}handleImageScaleWhileZoomingWithMouse(e){this.isZoomedInWithMouseWheel(e)?this.onZoomIn():this.onZoomOut(),this.zoom<=1&&this.reCenterImage()}isZoomedInWithMouseWheel(e){return e<0}reset(){this.zoom=this.config.nzZoom??this._defaultNzZoom,this.scaleStep=this.config.nzScaleStep??this._defaultNzScaleStep,this.rotate=this.config.nzRotate??this._defaultNzRotate,this.flipHorizontally=!1,this.flipVertically=!1,this.reCenterImage()}reCenterImage(){this.position=b({},Ve)}static \u0275fac=function(n){return new(n||t)};static \u0275cmp=Y({type:t,selectors:[["nz-image-preview"]],viewQuery:function(n,i){if(n&1&&(te(Ue,5),te(Be,7)),n&2){let o;ie(o=ne())&&(i.imageRef=o.first),ie(o=ne())&&(i.imagePreviewWrapper=o.first)}},hostAttrs:[1,"ant-image-preview-root"],hostVars:6,hostBindings:function(n,i){n&1&&Ce("@fadeMotion.start",function(m){return i.onAnimationStart(m)})("@fadeMotion.done",function(m){return i.onAnimationDone(m)}),n&2&&(ye("@.disabled",i.config.nzNoAnimation)("@fadeMotion",i.visible?"enter":"leave"),L("z-index",i.config.nzZIndex),x("ant-image-preview-moving",i.isDragging))},exportAs:["nzImagePreview"],decls:17,vars:5,consts:[["imagePreviewWrapper",""],["imgRef",""],[1,"ant-image-preview-mask"],[1,"ant-image-preview-operations-wrapper"],[1,"ant-image-preview-operations"],[1,"ant-image-preview-operations-progress"],[1,"ant-image-preview-operations-operation",3,"ant-image-preview-operations-operation-disabled"],["tabindex","-1",1,"ant-image-preview-wrap",3,"click"],["role","dialog","aria-modal","true",1,"ant-image-preview"],["tabindex","0","aria-hidden","true",1,"ant-image-preview-focus-trap"],[1,"ant-image-preview-content"],[1,"ant-image-preview-body"],["cdkDrag","",1,"ant-image-preview-img-wrapper",3,"cdkDragEnded","cdkDragFreeDragPosition"],[1,"ant-image-preview-switch-left",3,"click"],["nzType","left","nzTheme","outline"],[1,"ant-image-preview-switch-right",3,"click"],["nzType","right","nzTheme","outline"],[1,"ant-image-preview-operations-operation",3,"click"],["nzTheme","outline",1,"ant-image-preview-operations-icon",3,"nzType","nzRotate"],["cdkDragHandle","",1,"ant-image-preview-img",3,"width","height","transform"],["cdkDragHandle","",1,"ant-image-preview-img"]],template:function(n,i){if(n&1){let o=H();_(0,"div",2),g(1,"div",3),Z(2,Qe,4,4),g(3,"ul",4),Z(4,Ye,2,2,"li",5),X(5,Ke,2,4,"li",6,q),C()(),g(7,"div",7),k("click",function(c){return P(o),D(i.maskClosable&&c.target===c.currentTarget&&i.onClose())}),g(8,"div",8),_(9,"div",9),g(10,"div",10)(11,"div",11)(12,"div",12,0),k("cdkDragEnded",function(c){return P(o),D(i.onDragEnd(c))}),X(14,Xe,1,1,null,null,q),C()()(),_(16,"div",9),C()()}n&2&&(z(2),W(i.images.length>1?2:-1),z(2),W(i.images.length>1?4:-1),z(),J(i.operations),z(7),L("transform",i.previewImageWrapperTransform),ee("cdkDragFreeDragPosition",i.position),z(2),J(i.images))},dependencies:[Ee,De,Oe,Ze],encapsulation:2,data:{animation:[Me]},changeDetection:0})}return t})(),le=class{previewInstance;config;overlayRef;destroy$=new F;constructor(r,e,n){this.previewInstance=r,this.config=e,this.overlayRef=n,n.keydownEvents().pipe(M(i=>this.config.nzKeyboard&&(i.keyCode===27||i.keyCode===37||i.keyCode===39)&&!Te(i))).subscribe(i=>{i.preventDefault(),i.keyCode===27&&r.onClose(),i.keyCode===37&&this.prev(),i.keyCode===39&&this.next()}),n.detachments().subscribe(()=>{this.overlayRef.dispose()}),r.closeClick.pipe(ce(1),me(()=>r.animationStateChanged),M(i=>i.phaseName==="done"),O(this.destroy$)).subscribe(()=>{this.close()})}switchTo(r){this.previewInstance.switchTo(r)}
1next(){this.previewInstance.next()}prev(){this.previewInstance.prev()}close(){this.destroy$.next(),this.overlayRef.dispose()}},je=(()=>{class t{overlay=s(Fe);injector=s(U);nzConfigService=s(A);directionality=s(ae);preview(e,n,i){return this.display(e,n,i)}display(e,n,i){let o=b(b({},new N),n??{}),m=this.createOverlay(o),c=this.attachPreviewComponent(m,o);c.setImages(e,i);let f=new le(c,o,m);return c.previewRef=f,f}attachPreviewComponent(e,n){let i=U.create({parent:this.injector,providers:[{provide:Ne,useValue:e},{provide:N,useValue:n}]}),o=new xe($e,null,i);return e.attach(o).instance}createOverlay(e){let n=this.nzConfigService.getConfigForComponent(Ae)||{},i=new Re({scrollStrategy:this.overlay.scrollStrategies.block(),positionStrategy:this.overlay.position().global(),disposeOnNavigation:e.nzCloseOnNavigation??n.nzCloseOnNavigation??!0,direction:e.nzDirection||n.nzDirection||this.directionality.value});return this.overlay.create(i)}static \u0275fac=function(n){return new(n||t)};static \u0275prov=he({token:t,factory:t.\u0275fac})}return t})(),at="image",Rt=(()=>{var p;let t,r=[],e=[],n,i=[],o=[],m,c=[],f=[],S,w=[],y=[];return p=class{document=s(B);nzConfigService=s(A);elementRef=s(ge);nzImageService=s(je);cdr=s(oe);directionality=s(ae);destroyRef=s(Q);_nzModuleName=at;nzSrc="";nzSrcset="";nzDisablePreview=u(this,r,!1);nzFallback=(u(this,e),u(this,i,null));nzPlaceholder=(u(this,o),u(this,c,null));nzScaleStep=(u(this,f),u(this,w,null));dir=u(this,y);backLoadImage;status="normal";backLoadDestroy$=new F;parentGroup=s(Je,{optional:!0});get previewable(){return!this.nzDisablePreview&&this.status!=="error"}ngOnInit(){this.backLoad(),this.parentGroup&&this.parentGroup.addImage(this),this.directionality&&(this.directionality.change?.pipe(I(this.destroyRef)).subscribe(l=>{this.dir=l,this.cdr.detectChanges()}),this.dir=this.directionality.value)}onPreview(){if(this.previewable)if(this.parentGroup){let l=this.parentGroup.images.filter(d=>d.previewable),a=l.map(d=>({src:d.nzSrc,srcset:d.nzSrcset})),h=l.findIndex(d=>this===d),$=new Map;l.forEach(d=>{$.set(d.nzSrc??d.nzSrcset,d.nzScaleStep??this.parentGroup.nzScaleStep??this.nzScaleStep??se)}),this.nzImageService.preview(a,{nzDirection:this.dir},$).switchTo(h)}else{let l=[{src:this.nzSrc,srcset:this.nzSrcset}];this.nzImageService.preview(l,{nzDirection:this.dir,nzScaleStep:this.nzScaleStep??se})}}getElement(){return this.elementRef}ngOnChanges(l){let{nzSrc:a}=l;a&&(this.getElement().nativeElement.src=a.currentValue,this.backLoad())}backLoad(){this.backLoadImage=this.document.createElement("img"),this.backLoadImage.src=this.nzSrc,this.backLoadImage.srcset=this.nzSrcset,this.status="loading",this.backLoadDestroy$.next(),this.backLoadDestroy$.complete(),this.backLoadDestroy$=new F,this.backLoadImage.complete?(this.status="normal",this.getElement().nativeElement.src=this.nzSrc,this.getElement().nativeElement.srcset=this.nzSrcset):(this.nzPlaceholder?(this.getElement().nativeElement.src=this.nzPlaceholder,this.getElement().nativeElement.srcset=""):(this.getElement().nativeElement.src=this.nzSrc,this.getElement().nativeElement.srcset=this.nzSrcset),G(this.backLoadImage,"load").pipe(O(this.backLoadDestroy$),I(this.destroyRef)).subscribe(()=>{this.status="normal",this.getElement().nativeElement.src=this.nzSrc,this.getElement().nativeElement.srcset=this.nzSrcset}),G(this.backLoadImage,"error").pipe(O(this.backLoadDestroy$),I(this.destroyRef)).subscribe(()=>{this.status="error",this.nzFallback&&(this.getElement().nativeElement.src=this.nzFallback,this.getElement().nativeElement.srcset="")}))}},(()=>{let l=typeof Symbol=="function"&&Symbol.metadata?Object.create(null):void 0;t=[R()],n=[R()],m=[R()],S=[R()],E(null,null,t,{kind:"field",name:"nzDisablePreview",static:!1,private:!1,access:{has:a=>"nzDisablePreview"in a,get:a=>a.nzDisablePreview,set:(a,h)=>{a.nzDisablePreview=h}},metadata:l},r,e),E(null,null,n,{kind:"field",name:"nzFallback",static:!1,private:!1,access:{has:a=>"nzFallback"in a,get:a=>a.nzFallback,set:(a,h)=>{a.nzFallback=h}},metadata:l},i,o),E(null,null,m,{kind:"field",name:"nzPlaceholder",static:!1,private:!1,access:{has:a=>"nzPlaceholder"in a,get:a=>a.nzPlaceholder,set:(a,h)=>{a.nzPlaceholder=h}},metadata:l},c,f),E(null,null,S,{kind:"field",name:"nzScaleStep",static:!1,private:!1,access:{has:a=>"nzScaleStep"in a,get:a=>a.nzScaleStep,set:(a,h)=>{a.nzScaleStep=h}},metadata:l},w,y),l&&Object.defineProperty(p,Symbol.metadata,{enumerable:!0,configurable:!0,writable:!0,value:l})})(),j(p,"\u0275fac",function(a){return new(a||p)}),j(p,"\u0275dir",ze({type:p,selectors:[["img","nz-image",""]],hostBindings:function(a,h){a&1&&k("click",function(){return h.onPreview()})},inputs:{nzSrc:"nzSrc",nzSrcset:"nzSrcset",nzDisablePreview:[2,"nzDisablePreview","nzDisablePreview",Ie],nzFallback:"nzFallback",nzPlaceholder:"nzPlaceholder",nzScaleStep:"nzScaleStep"},exportAs:["nzImage"],features:[de]})),p})(),Nt=(()=>{class t{static \u0275fac=function(n){return new(n||t)};static \u0275mod=ue({type:t});static \u0275inj=pe({providers:[je],imports:[$e]})}return t})();export{Je as a,je as b,Rt as c,Nt as d};
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.