1"use strict";(self.webpackChunkinitiative_as_a_service=self.webpackChunkinitiative_as_a_service||[]).push([["src_app_features_history_history_module_ts"],{7458(V,P,i){i.d(P,{HistoryModule:()=>_e});var m=i(72200),r=i(89417),I=i(99213),g=i(59115),y=i(9183),h=i(90882),c=i(78884),M=i(38132),v=i(10467),S=i(11514),e=i(73664),d=i(84412),$=i(21413),O=i(33726),E=i(983),_=i(5964),R=i(56977),a=i(96697),f=i(99437),p=i(65245),T=i(30786),L=i(84100),G=i(86906),F=i(12257),k=i(57805),x=i(54079),W=i(97005),H=i(91708),w=i(1835);const D=[{key:"All",value:x.f.ALL},{key:"Published",value:x.f.PUBLISHED},{key:"Unpublished",value:x.f.UNPUBLISHED}];var X=i(8101),u=i(2615),z=i(17705),N=i(91029),Y=i(80029),K=i(61945),Q=i(80633),Z=i(82049),J=i(32591),q=i(95416),ee=i(345),te=i(49030),ie=i(86820);const re=["iframe"];function ne(o,C){if(1&o&&(e.j41(0,"span"),e.EFF(1),e.k0s()),2&o){const t=e.XpG().$implicit;e.R7$(),e.SpI("By ",null==t.account?null:t.account.name)}}function se(o,C){if(1&o&&(e.j41(0,"span"),e.EFF(1,"\xa0\u2022\xa0"),e.k0s(),e.j41(2,"lib-status",32),e.EFF(3,"Published"),e.k0s()),2&o){const t=e.XpG(6);e.R7$(2),e.Y8G("size",t.statusSize.Small)("type",t.statusType.Positive)}}function oe(o,C){if(1&o){const t=e.RV6();e.j41(0,"div",28),e.nI1(1,"async"),e.bIt("click",function(){const s=u.eBV(t).$implicit,l=e.XpG(5);return u.Njj(l.selectVersion(s))}),e.j41(2,"div")(3,"div",29)(4,"span"),e.EFF(5),e.nI1(6,"date"),e.k0s()(),e.j41(7,"p",30),e.EFF(8),e.k0s(),e.j41(9,"div",31),e.DNE(10,ne,2,1,"span",16),e.nVh(11,se,4,2),e.k0s()()()}if(2&o){const t=C.$implicit,n=e.XpG(5);e.AVh("versions-item--selected",t.id===e.bMT(1,6,n.selectedVersionId$)),e.R7$(5),e.JRh(e.i5U(6,8,t.createdAt,n.DatePipeFormat.MMM_D_Y_H_MM_A)),e.R7$(3),e.SpI(" ",t.title," "),e.R7$(2),e.Y8G("ngIf",null==t?null:t.account),e.R7$(),e.vxM(t.backupOnPublish?11:-1)}}function ae(o,C){if(1&o&&(e.j41(0,"div",26),e.DNE(1,oe,12,11,"div",27),e.k0s()),2&o){const t=e.XpG().ngIf;e.R7$(),e.Y8G("ngForOf",t)}}function ce(o,C){if(1&o&&(e.qex(0),e.DNE(1,ae,2,1,"div",25),e.bVm()),2&o){const t=C.ngIf;e.XpG(3);const n=e.sdS(36);e.R7$(),e.Y8G("ngIf",t.length)("ngIfElse",n)}}function le(o,C){if(1&o&&(e.qex(0),e.DNE(1,ce,2,2,"ng-container",16),e.nI1(2,"async"),e.bVm()),2&o){const t=e.XpG(2);e.R7$(),e.Y8G("ngIf",e.bMT(2,1,t.versions$))}}function de(o,C){if(1&o){const t=e.RV6();e.qex(0),e.j41(1,"form",21),e.bIt("click",function(s){return u.eBV(t),e.sdS(3).toggleMenu(),u.Njj(s.stopPropagation())}),e.j41(2,"lib-input",22,3),e.bIt("click",function(s){return u.eBV(t),u.Njj(s.stopPropagation())}),e.k0s()(),e.j41(4,"lib-menu",23,4),e.bIt("selected",function(s){u.eBV(t);const l=e.XpG();return u.Njj(l.onVersionChange(s))}),e.k0s(),e.DNE(6,le,3,3,"ng-container",24),e.nI1(7,"async"),e.nI1(8,"async"),e.bVm()}if(2&o){const t=e.sdS(3),n=e.sdS(5),s=e.XpG(),l=e.sdS(34);e.R7$(),e.Y8G("formGroup",s.versionsForm),e.R7$(),e.AVh("active",t.menuOpen),e.Y8G("iconRight",t.menuOpen?"chevron-up":"chevron-down")("isIconRightSVG",!0)("matMenuTriggerFor",n.menu),e.R7$(2),e.HbH("form-field-lib-menu "+s.forumTheme),e.Y8G("menuItemsConfig",s.versionsMenuConfig),e.R7$(2),e.Y8G("ngIf",e.bMT(7,11,s.isVersionsLoaded$)&&e.bMT(8,13,s.isSiteSnapshotLoaded$))("ngIfElse",l)}}function pe(o,C){1&o&&e.eu8(0)}function me(o,C){1&o&&(e.qex(0),e.j41(1,"div",33)(2,"p",34),e.EFF(3,"This version is unavailable."),e.k0s()(),e.bVm())}function he(o,C){1&o&&(e.j41(0,"div",35),e.nrm(1,"mat-spinner",36),e.k0s())}function ge(o,C){1&o&&(e.j41(0,"p",37),e.EFF(1,"No available versions"),e.k0s())}let A=(()=>{class o{onMessage(t){if(t.data?.path){let n;n=t.data?.subpageId&&t.data?.objectType?{path:t.data.path,subpageId:t.data?.subpageId,objectType:t.data?.objectType}:t.data?.subpageId?{path:t.data.path,subpageId:t.data?.subpageId}:{path:t.data.path},this.navigateToPage(t.data?.openLinkInNewTab,n,t.data?.fragment)}(t.data?.goBack||t.data?.goBackNavigator)&&(this.route.snapshot.queryParams.openInNewTab?window.close():(this.url$.next(this.previousUrl$.value),this.previousUrl$.next(""))),t.data?.loaded&&this.isLoading$.next(!1)}constructor(t,n,s,l,b,U,j,fe,ye,Se,be,Ie){this.router=t,this.route=n,this.cdr=s,this.versionsService=l,this.sitesSnapshotsService=b,this.designSettingsService=U,this.pagesSnapshotsService=j,this.date=fe,this.dialog=ye,this.snackBar=Se,this.sanitizer=be,this.mixpanelService=Ie,this.isSavingInProgress=!1,this.isNewVersionSelected=!1,this.currentSite$=this.sitesSnapshotsService.currentSite$,this.selectedVersion$=new d.t(null),this.selectedVersionId$=new d.t(0),this.isLoading$=new d.t(!1),this.isNoPages$=new d.t(!1),this.isHistoryOpened$=this.versionsService.isHistoryOpened$,this.isVersionsLoaded$=this.versionsService.isVersionsLoaded$,this.isSiteSnapshotLoaded$=this.sitesSnapshotsService.isSiteSnapshotLoaded$,this.selectedFilterVersion=D[0],this.versionFilters=D,this.versions$=this.versionsService.histories$,this.historyUrl="",this.url$=new d.t(""),this.previousUrl$=new d.t(""),this.versionsScrolled$=new d.t(!1),this.buttonStyle=c.inm,this.buttonType=c.VQ,this.buttonState=c.UwB,this.iconButtonType=c.ZUJ,this.buttonIconPosition=c.fEU,this.statusSize=c.Iqg,this.statusType=c.XUj,this.forumTheme=G.C,this.DatePipeFormat=L.u,this.versionsForm=new r.gE({menuInput:new r.MJ(this.selectedFilterVersion.key)}),this.versionsMenuConfig={items:this.versionFilters.map(B=>({id:B.value,label:B.key,checked:B.value===this.selectedFilterVersion.value}))}
1,this.siteId=this.route.snapshot.params.siteId,this.destroy$=new $.B}ngOnInit(){this.url$.next(this.sanitizer.bypassSecurityTrustResourceUrl("")),this.loadVersions(),this.isVersionsLoaded$.pipe((0,_.p)(Boolean),(0,R.Q)(this.destroy$)).subscribe(()=>{this.selectedVersionId$.next(this.versions$.getValue().find(n=>n.active)?.id||0)});const t=this.route.snapshot.queryParams.versionId;t?(this.isNewVersionSelected=!0,this.isSiteSnapshotLoaded$.next(!0),this.selectedVersionId$.next(Number(t)),this.openNewVersion(t)):this.openCurrentVersion(),this.handleVersionsScrolled()}ngOnDestroy(){this.destroy$.next(),this.destroy$.complete(),this.versionsService.resetHistories()}ngAfterViewInit(){(0,O.R)(this.iframe?.nativeElement,"load").pipe((0,R.Q)(this.destroy$)).subscribe(()=>{this.isLoading$.next(!0),this.updateIframeDesignSettings()})}onExit(){var t=this;return(0,v.A)(function*(){yield t.router.navigate([F.n.BUILDER,t.siteId])})()}onVersionChange(t){this.selectedFilterVersion=D.find(n=>n.value===t.id),this.versionsForm.controls.menuInput.setValue(this.selectedFilterVersion.key),this.versionsMenuConfig.items=this.versionsMenuConfig.items.map(n=>({...n,checked:n.id===t.id})),this.changeVersion()}onRestore(){const t=this.selectedVersion$.value,n=this.date.transform(t.createdAt,"MMM d, y, h:mm a");this.dialog.open(W.P,(0,X.cd)(n)).afterClosed().pipe((0,a.s)(1),(0,_.p)(Boolean)).subscribe(()=>{this.isSavingInProgress=!0,this.cdr.detectChanges(),this.versionsService.applyVersion(this.siteId,t.id).pipe((0,a.s)(1),(0,f.W)(()=>(this.isSavingInProgress=!1,this.cdr.detectChanges(),this.snackBar.openFromComponent(H.Y,w.hi),E.w))).subscribe(()=>{this.isSavingInProgress=!1,this.isNewVersionSelected=!1,this.changeVersion(),this.openCurrentVersion(),this.snackBar.openFromComponent(H.Y,(0,w.M1)(t.title)),this.cdr.detectChanges(),this.mixpanelService.pageTrack(this.mixpanelService.ACTIONS.SUBMIT,{type:this.mixpanelService.SUBMIT_TYPE.RESTORE})})})}toggleHistory(){this.versionsService.isHistoryOpened$.next(!this.versionsService.isHistoryOpened$.value)}changeVersion(){this.versionsService.nextPage="",this.loadVersions()}selectVersion(t){t.id!==this.selectedVersionId$.value&&(this.isNewVersionSelected=!t.active,this.selectedVersionId$.next(t.id),this.selectedVersion$.next(t),this.isLoading$.next(!0),this.isNewVersionSelected?this.openNewVersion(t.id):this.openCurrentVersion())}onHistoryScroll(){this.versionsScrolled$.next(!0)}navigateToPage(t,n,s=""){if(t){const l={queryParams:n};l.queryParams.openInNewTab=!0,l.queryParams.versionId=this.isNewVersionSelected?this.selectedVersionId$.value:null,l.queryParams.snapshotId=this.currentSite$.value?.snapshot;const b=this.router.serializeUrl(this.router.createUrlTree([F.n.HISTORY,this.siteId],l));window.open(b,"_blank")}else{const l=n.subpageId?`&subpageId=${n.subpageId}`:"",b=n.objectType?`&objectType=${n.objectType}`:"",U=s?`#${s}`:"",j=`${this.getFrameUrl(n.path)}${l}${b}${U}`;this.previousUrl$.next(this.url$.value),this.nextUrlSanitized(j)}}nextUrlSanitized(t){const n=this.sanitizer.sanitize(e.WPN.URL,t)??"";this.url$.next(this.sanitizer.bypassSecurityTrustResourceUrl(n))}updateIframeDesignSettings(){this.designSettingsService.changeDesignTheme(this.iframe?.nativeElement.contentDocument)}loadCurrentSite(){this.sitesSnapshotsService.getSiteSnapshot(this.siteId).pipe((0,a.s)(1)).subscribe(t=>{this.updateDesignSettings(t.configuration.theme)})}loadPagesSnapshots(){this.pagesSnapshotsService.getPagesSnapshot(this.siteId).pipe((0,a.s)(1)).subscribe(t=>{this.isNoPages$.next(!1);const s=this.route.snapshot.queryParams.path||t.find(b=>b.isHome)?.path||t[0].path;this.nextUrlSanitized(`${this.historyUrl}&path=${s}`)})}loadVersions(){this.versionsService.loadVersions(this.siteId,this.getVersionListFilter()).pipe((0,a.s)(1)).subscribe()}getVersionListFilter(){return this.selectedFilterVersion.value===x.f.ALL?null:this.selectedFilterVersion.value}handleVersionsScrolled(){this.versionsScrolled$.pipe((0,p.i)(1),(0,T.p)(()=>this.versionsService.loadVersions(this.siteId,this.getVersionListFilter()).pipe((0,a.s)(1))),(0,R.Q)(this.destroy$)).subscribe()}updateDesignSettings(t){const n=Object.values(k.P).includes(t)?t:k.P.FORUM_LIGHT;this.designSettingsService.selectedTheme$.next(n),this.updateIframeDesignSettings()}openCurrentVersion(){this.loadCurrentSite(),this.loadPagesSnapshots(),this.historyUrl=`/page-preview?origin=preview&isHistory=true&siteId=${this.siteId}`}openNewVersion(t){this.versionsService.loadVersion(this.siteId,t).pipe((0,a.s)(1)).subscribe(n=>{if(n.pages.length){this.isNoPages$.next(!1),this.updateDesignSettings(n?.theme);
1const s=this.route.snapshot.queryParams.path;this.historyUrl=`public-site?origin=preview&isHistory=true&siteId=${this.siteId}&versionId=${t}`;const l=s?`${this.getFrameUrl(s)}`:this.historyUrl;this.nextUrlSanitized(l)}else this.isNoPages$.next(!0),this.url$.next(this.sanitizer.bypassSecurityTrustResourceUrl(""))})}getFrameUrl(t){if(this.historyUrl.includes("public-site")){const n=this.historyUrl.split("?");return n[0]+=`/${t}`,n.join("?")}return`${this.historyUrl}&path=${t}`}static{this.\u0275fac=function(n){return new(n||o)(e.rXU(N.Ix),e.rXU(N.nX),e.rXU(z.gRc),e.rXU(Y.L),e.rXU(K.X),e.rXU(Q.D),e.rXU(Z.h),e.rXU(m.vh),e.rXU(J.bZ),e.rXU(q.UG),e.rXU(ee.up),e.rXU(te.aO))}}static{this.\u0275cmp=e.VBU({type:o,selectors:[["app-history"]],viewQuery:function(n,s){if(1&n&&e.GBs(re,5),2&n){let l;e.mGM(l=e.lsd())&&(s.iframe=l.first)}},hostBindings:function(n,s){1&n&&e.bIt("message",function(b){return s.onMessage(b)},e.tSv)},standalone:!1,decls:37,vars:51,consts:[["iframe",""],["loadingSpinner",""],["noVersions",""],["menuTrigger","matMenuTrigger"],["menuInstance","libMenu"],[1,"admin-panel-header"],[1,"admin-panel-header__container"],[1,"admin-panel-header__section"],[3,"buttonClick","type","state","iconPosition"],["libIconContent","","svgIcon","exit-chat-line"],[1,"action-items"],[3,"buttonClick","type","state"],["disableClose","true","opened","true","mode","side","infiniteScroll","",1,"page-sidenav",3,"scrolled","infiniteScrollDistance","infiniteScrollThrottle","infiniteScrollContainer","alwaysCallback"],[1,"d-flex","page-sidenav-title","heading-medium"],[3,"click","type"],["libIconContent",""],[4,"ngIf"],[1,"side-nav-content"],[1,"iframe-container"],[4,"ngIf","ngIfThen"],["frameborder","0",1,"preview-iframe",2,"width","100%",3,"src"],[1,"menu-input-form","version-menu",3,"click","formGroup"],["formControlName","menuInput",1,"community-panel",3,"click","iconRight","isIconRightSVG","matMenuTriggerFor"],["yPosition","below",3,"selected","menuItemsConfig"],[4,"ngIf","ngIfElse"],["class","versions-wrapper",4,"ngIf","ngIfElse"],[1,"versions-wrapper"],["class","versions-item",3,"versions-item--selected","click",4,"ngFor","ngForOf"],[1,"versions-item",3,"click"],[1,"versions-item-subtitle","body-xs-regular"],[1,"versions-item-title","body-medium"],[1,"versions-item-subtitle"],[3,"size","type"],[1,"error-message"],[1,"heading-medium"],[1,"d-flex","spinner"],["diameter","35"],[1,"text-center"]],template:function(n,s){if(1&n){const l=e.RV6();e.j41(0,"header",5)(1,"div",6)(2,"div",7)(3,"lib-button",8),e.bIt("buttonClick",function(){return u.eBV(l),u.Njj(s.onExit())}),e.nrm(4,"mat-icon",9),e.EFF(5," Exit history "),e.k0s()(),e.j41(6,"div",7)(7,"div",10)(8,"lib-button",11),e.nI1(9,"async"),e.bIt("buttonClick",function(){return u.eBV(l),u.Njj(s.onRestore())}),e.EFF(10," Restore "),e.k0s()()()()(),e.j41(11,"mat-drawer-container")(12,"mat-drawer",12),e.nI1(13,"async"),e.bIt("scrolled",function(){return u.eBV(l),u.Njj(s.onHistoryScroll())}),e.j41(14,"h4",13)(15,"lib-icon-button",14),e.bIt("click",function(){return u.eBV(l),u.Njj(s.toggleHistory())}),e.j41(16,"mat-icon",15),e.EFF(17),e.nI1(18,"async"),e.k0s()()(),e.DNE(19,de,9,15,"ng-container",16),e.nI1(20,"async"),e.k0s(),e.j41(21,"mat-drawer-content",17),e.nI1(22,"async"),e.j41(23,"div",18),e.DNE(24,pe,1,0,"ng-container",19),e.nI1(25,"async"),e.nI1(26,"async"),e.DNE(27,me,4,0,"ng-container",16),e.nI1(28,"async"),e.nrm(29,"iframe",20,0),e.nI1(31,"async"),e.nI1(32,"async"),e.k0s()()(),e.DNE(33,he,2,0,"ng-template",null,1,e.C5r)(35,ge,2,0,"ng-template",null,2,e.C5r)}if(2&n){const l=e.sdS(34);e.HbH(s.forumTheme),e.R7$(3),e.Aen(s.buttonStyle.Ghost),e.Y8G("type",s.buttonType.Secondary)("state",s.isSavingInProgress?s.buttonState.Disabled:s.buttonState.Default)("iconPosition",s.buttonIconPosition.Left),e.R7$(5),e.Aen(s.buttonStyle.Solid),e.Y8G("type",s.buttonType.Primary)("state",!s.isNewVersionSelected||s.isSavingInProgress||e.bMT(9,31,s.isNoPages$)?s.buttonState.Disabled:s.buttonState.Default),e.R7$(3),e.HbH("mat-drawer-transition "+s.forumTheme),e.R7$(),e.Y8G("@openClose",!!e.bMT(13,33,s.isHistoryOpened$))("infiniteScrollDistance",1)("infiniteScrollThrottle",300)("infiniteScrollContainer",".mat-drawer-inner-container")("alwaysCallback",!0),e.R7$(3),e.Aen(s.buttonStyle.Ghost),e.Y8G("type",s.iconButtonType.Secondary),e.R7$(2),e.SpI(" ",e.bMT(18,35,s.isHistoryOpened$)?"keyboard_arrow_left":"keyboard_arrow_right"," "),e.R7$(2),e.Y8G("ngIf",e.bMT(20,37,s.isHistoryOpened$)),e.R7$(2),e.xc7("margin-left",e.bMT(22,39,s.isHistoryOpened$)?"396px":"60px"),e.R7$(3),e.Y8G("ngIf",e.bMT(25,41,s.isLoading$)&&!e.bMT(26,43,s.isNoPages$))("ngIfThen",l),e.R7$(3),e.Y8G("ngIf",e.bMT(28,45,s.isNoPages$)),e.R7$(2),e.xc7("height",e.bMT(31,47,s.isLoading$)?"0px":"100%"),e.Y8G("src",e.bMT(32,49,s.url$),e.f$h)}},dependencies:[m.Sq,m.bT,ie.D,c.Qpp,c.CR$,c.q9O,c.xBz,r.qT,r.BC,r.cb,r.j4,r.JD,
1c.Sjx,c.ZuA,y.LG,g.Cp,h.qe,h.$C,h.$l,I.An,m.Jj,m.vh],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;height:100%}[_nghost-%COMP%] mat-drawer-container[_ngcontent-%COMP%]{flex-grow:1}[_nghost-%COMP%] .page-sidenav[_ngcontent-%COMP%]{width:396px;max-width:396px;padding:0!important;box-shadow:var(--elevation-level-2);border-right:none}[_nghost-%COMP%] .page-sidenav[_ngcontent-%COMP%] .mat-drawer-inner-container{padding:var(--space-300)}[_nghost-%COMP%] .page-sidenav[_ngcontent-%COMP%] .page-sidenav-title[_ngcontent-%COMP%]{align-items:center;justify-content:flex-end;margin-bottom:var(--space-300)}[_nghost-%COMP%] .page-sidenav[_ngcontent-%COMP%] .version-menu[_ngcontent-%COMP%]{margin-bottom:var(--space-300)}.versions-item[_ngcontent-%COMP%]{padding:var(--space-200);border-bottom:var(--border-width-hairline) solid var(--colour-border-tertiary);display:flex;justify-content:space-between;align-items:center}.versions-item[_ngcontent-%COMP%]:last-child{border-bottom:none}.versions-item--selected[_ngcontent-%COMP%], .versions-item[_ngcontent-%COMP%]:hover{border-color:var(--colour-border-on-accent);border-radius:var(--border-radius-100);background:var(--colour-surface-neutral-subtle-default)}.versions-item[_ngcontent-%COMP%]:hover{cursor:pointer}.versions-item-title[_ngcontent-%COMP%]{color:var(--colour-text-primary);margin-bottom:var(--space-050)}.versions-item-subtitle[_ngcontent-%COMP%]{font-family:var(--typography-body-small-font-family);font-weight:var(--typography-body-small-font-weight);line-height:var(--typography-body-small-line-height);font-size:var(--typography-body-small-font-size);letter-spacing:var(--typography-body-regular-letter-spacing);text-transform:var(--typography-body-regular-text-case);color:var(--colour-text-secondary)}.spinner[_ngcontent-%COMP%]{justify-content:center}.side-nav-content[_ngcontent-%COMP%] .spinner[_ngcontent-%COMP%]{height:100%;align-items:center}.button-exit[_ngcontent-%COMP%]{padding:var(--space-150) var(--space-300)}.iframe-container[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:center;width:100%;height:100%}.error-message[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;height:100%;color:var(--colour-text-primary)}"],data:{animation:[(0,S.hZ)("openClose",[(0,S.wk)("true",(0,S.iF)({})),(0,S.wk)("false",(0,S.iF)({padding:"24px 18px",width:"auto"})),(0,S.kY)("false <=> true",[(0,S.i0)("0.4s cubic-bezier(0.25, 0.8, 0.25, 1)")])])]},changeDetection:0})}}return o})();const ue=[{path:"",component:A,children:[{path:"",component:A,pathMatch:"full"}]}];let ve=(()=>{class o{static{this.\u0275fac=function(n){return new(n||o)}}static{this.\u0275mod=e.$C({type:o})}static{this.\u0275inj=u.G2t({imports:[M.iI.forChild(ue),M.iI]})}}return o})(),_e=(()=>{class o{static{this.\u0275fac=function(n){return new(n||o)}}static{this.\u0275mod=e.$C({type:o})}static{this.\u0275inj=u.G2t({providers:[m.vh],imports:[m.MD,ve,c.Qpp,c.q9O,c.xBz,r.X1,c.Sjx,c.ZuA,y.D6,g.Cn,h.vg,I.m_]})}}return o})()},82049(V,P,i){i.d(P,{h:()=>M});var m=i(29330),r=i(84412),I=i(96354),g=i(88141),y=i(56710),h=i(2615),c=i(73878);let M=(()=>{class v{constructor(e,d){this.httpClient=e,this.apiEndpointService=d,this.pagesSnapshots$=new r.t([])}getPageRedirectUrl(e,d){return`${this.apiEndpointService.getFWSEndpoint()}/communities/v1/public/initiatives/site/page-redirect?initiative_id=${e}&page_id=${d}`}getPagesLookup(e){const d=`${this.apiEndpointService.getFWSEndpoint()}/communities/v1/sites/${e}/pages/lookup`;return this.httpClient.get(d)}getPagesSnapshot(e,d){const $=`${this.apiEndpointService.getFWSEndpoint()}/communities/v1/sites/${e}/pages`;let O=new m.Lr;return d&&(O=O.append("X-Preview-Tier",d)),this.httpClient.get($,{headers:O}).pipe((0,I.T)(E=>E.sort((_,R)=>(_.order||0)-(R.order||0))),(0,g.M)(E=>{this.pagesSnapshots$.next((0,y.eZ)(E))}))}changeSnapshotsOrder(e,d){const $=`${this.apiEndpointService.getFWSEndpoint()}/communities/v1/sites/${e}/pages/orders`;return this.httpClient.put($,{pages_ids:d})}addSnapshotPages(e,d){const $=`${this.apiEndpointService.getFWSEndpoint()}/communities/v1/sites/${e}/pages`;return this.httpClient.post($,d)}static{this.\u0275fac=function(d){return new(d||v)(h.KVO(m.Qq),h.KVO(c.J))}}static{this.\u0275prov=h.jDH({token:v,factory:v.\u0275fac,providedIn:"root"})}}return v})()},56710(V,P,i){i.d(P,{dL:()=>m,eZ:()=>I,et:()=>r});const m=g=>!g||!g.length||g.every(y=>null===y||""===y),r=g=>g.map(y=>Object.values(y?.errors)).flat(2).join("\n"),I=g=>[...Array.isArray(g)?g:[]].sort((h,c)=>h?.visible===c?.visible?0:h?.visible?-1:1).sort((h,c)=>h?.visible||c?.visible?0:h.name.localeCompare(c.name))},30786(V,P,i){i.d(P,{p:()=>y});var m=i(96354),r=i(58750),I=i(39974),g=i(54360);function y(h,c){return c?M=>M.pipe(y((v,S)=>(0,r.Tg)(h(v,S)).pipe((0,m.T)((e,d)=>c(v,e,S,d))))):(0,I.N)((M,v)=>{let S=0,e=null,d=!1;M.subscribe((0,g._)(v,$=>{e||(e=(0,g._)(v,void 0,()=>{e=null,d&&v.complete()}),(0,r.Tg)(h($,S++)).subscribe(e))},()=>{d=!0,!e&&v.complete()}
1))})}},9183(V,P,i){i.d(P,{D6:()=>E,LG:()=>$});var m=i(2615),r=i(73664),I=i(17705),g=i(72200),y=i(31804),h=i(22466);const c=["determinateSpinner"];function M(_,R){if(1&_&&(m.qSk(),r.j41(0,"svg",11),r.nrm(1,"circle",12),r.k0s()),2&_){const a=r.XpG();r.BMQ("viewBox",a._viewBox()),r.R7$(),r.xc7("stroke-dasharray",a._strokeCircumference(),"px")("stroke-dashoffset",a._strokeCircumference()/2,"px")("stroke-width",a._circleStrokeWidth(),"%"),r.BMQ("r",a._circleRadius())}}const v=new m.nKC("mat-progress-spinner-default-options",{providedIn:"root",factory:function S(){return{diameter:e}}}),e=100;let $=(()=>{class _{_elementRef=(0,m.WQX)(r.aKT);_noopAnimations;get color(){return this._color||this._defaultColor}set color(a){this._color=a}_color;_defaultColor="primary";_determinateCircle;constructor(){const a=(0,m.WQX)(v),f=(0,y._J)(),p=this._elementRef.nativeElement;this._noopAnimations="di-disabled"===f&&!!a&&!a._forceAnimations,this.mode="mat-spinner"===p.nodeName.toLowerCase()?"indeterminate":"determinate",!this._noopAnimations&&"reduced-motion"===f&&p.classList.add("mat-progress-spinner-reduced-motion"),a&&(a.color&&(this.color=this._defaultColor=a.color),a.diameter&&(this.diameter=a.diameter),a.strokeWidth&&(this.strokeWidth=a.strokeWidth))}mode;get value(){return"determinate"===this.mode?this._value:0}set value(a){this._value=Math.max(0,Math.min(100,a||0))}_value=0;get diameter(){return this._diameter}set diameter(a){this._diameter=a||0}_diameter=e;get strokeWidth(){return this._strokeWidth??this.diameter/10}set strokeWidth(a){this._strokeWidth=a||0}_strokeWidth;_circleRadius(){return(this.diameter-10)/2}_viewBox(){const a=2*this._circleRadius()+this.strokeWidth;return`0 0 ${a} ${a}`}_strokeCircumference(){return 2*Math.PI*this._circleRadius()}_strokeDashOffset(){return"determinate"===this.mode?this._strokeCircumference()*(100-this._value)/100:null}_circleStrokeWidth(){return this.strokeWidth/this.diameter*100}static \u0275fac=function(f){return new(f||_)};static \u0275cmp=r.VBU({type:_,selectors:[["mat-progress-spinner"],["mat-spinner"]],viewQuery:function(f,p){if(1&f&&r.GBs(c,5),2&f){let T;r.mGM(T=r.lsd())&&(p._determinateCircle=T.first)}},hostAttrs:["role","progressbar","tabindex","-1",1,"mat-mdc-progress-spinner","mdc-circular-progress"],hostVars:18,hostBindings:function(f,p){2&f&&(r.BMQ("aria-valuemin",0)("aria-valuemax",100)("aria-valuenow","determinate"===p.mode?p.value:null)("mode",p.mode),r.HbH("mat-"+p.color),r.xc7("width",p.diameter,"px")("height",p.diameter,"px")("--mat-progress-spinner-size",p.diameter+"px")("--mat-progress-spinner-active-indicator-width",p.diameter+"px"),r.AVh("_mat-animation-noopable",p._noopAnimations)("mdc-circular-progress--indeterminate","indeterminate"===p.mode))},inputs:{color:"color",mode:"mode",value:[2,"value","value",I.Udg],diameter:[2,"diameter","diameter",I.Udg],strokeWidth:[2,"strokeWidth","strokeWidth",I.Udg]},exportAs:["matProgressSpinner"],decls:14,vars:11,consts:[["circle",""],["determinateSpinner",""],["aria-hidden","true",1,"mdc-circular-progress__determinate-container"],["xmlns","http://www.w3.org/2000/svg","focusable","false",1,"mdc-circular-progress__determinate-circle-graphic"],["cx","50%","cy","50%",1,"mdc-circular-progress__determinate-circle"],["aria-hidden","true",1,"mdc-circular-progress__indeterminate-container"],[1,"mdc-circular-progress__spinner-layer"],[1,"mdc-circular-progress__circle-clipper","mdc-circular-progress__circle-left"],[3,"ngTemplateOutlet"],[1,"mdc-circular-progress__gap-patch"],[1,"mdc-circular-progress__circle-clipper","mdc-circular-progress__circle-right"],["xmlns","http://www.w3.org/2000/svg","focusable","false",1,"mdc-circular-progress__indeterminate-circle-graphic"],["cx","50%","cy","50%"]],template:function(f,p){if(1&f&&(r.DNE(0,M,2,8,"ng-template",null,0,r.C5r),r.j41(2,"div",2,1),m.qSk(),r.j41(4,"svg",3),r.nrm(5,"circle",4),r.k0s()(),m.joV(),r.j41(6,"div",5)(7,"div",6)(8,"div",7),r.eu8(9,8),r.k0s(),r.j41(10,"div",9),r.eu8(11,8),r.k0s(),r.j41(12,"div",10),r.eu8(13,8),r.k0s()()()),2&f){const T=r.sdS(1);r.R7$(4),r.BMQ("viewBox",p._viewBox()),r.R7$(),r.xc7("stroke-dasharray",p._strokeCircumference(),"px")("stroke-dashoffset",p._strokeDashOffset(),"px")("stroke-width",p._circleStrokeWidth(),"%"),r.BMQ("r",p._circleRadius()),r.R7$(4),r.Y8G("ngTemplateOutlet",T),r.R7$(2),r.Y8G("ngTemplateOutlet",T),r.R7$(2),r.Y8G("ngTemplateOutlet",T)}},dependencies:[g.T3],styles:[".mat-mdc-progress-spinner{--mat-progress-spinner-animation-multiplier: 1;display:block;overflow:hidden;line-height:0;position:relative;direction:ltr;transition:opacity 250ms cubic-bezier(0.4, 0, 0.6, 1)}.mat-mdc-progress-spinner circle{stroke-width:var(--mat-progress-spinner-active-indicator-width, 4px)}.mat-mdc-progress-spinner._mat-animation-noopable,.mat-mdc-progress-spinner._mat-animation-noopable .mdc-circular-progress__determinate-circle{transition:none !important}.mat-mdc-progress-spinner._mat-animation-noopable .mdc-circular-progress__indeterminate-circle-graphic,.mat-mdc-progress-spinner._mat-animation-noopable .mdc-circular-progress__spinner-layer,.mat-mdc-progress-spinner._mat-animation-noopable .mdc-circular-progress__indeterminate-container{animation:none !important}.mat-mdc-progress-spinner._mat-animation-noopable .mdc-circular-progress__indeterminate-container circle{stroke-dasharray:0 !important}@media(forced-colors: active){.mat-mdc-progress-spinner .mdc-circular-progress__indeterminate-circle-graphic,.mat-mdc-progress-spinner .mdc-circular-progress__determinate-circle{stroke:currentColor;stroke:CanvasText}}.mat-progress-spinner-reduced-motion{--mat-progress-spinner-animation-multiplier: 1.25}.mdc-circular-progress__determinate-container,.mdc-circular-progress__indeterminate-circle-graphic,.mdc-circular-progress__indeterminate-container,.mdc-circular-progress__spinner-layer{position:absolute;width:100%;height:100%}.mdc-circular-progress__determinate-container{transform:rotate(-90deg)}.mdc-circular-progress--indeterminate .mdc-circular-progress__determinate-container{opacity:0}
1.mdc-circular-progress__indeterminate-container{font-size:0;letter-spacing:0;white-space:nowrap;opacity:0}.mdc-circular-progress--indeterminate .mdc-circular-progress__indeterminate-container{opacity:1;animation:mdc-circular-progress-container-rotate calc(1568.2352941176ms*var(--mat-progress-spinner-animation-multiplier)) linear infinite}.mdc-circular-progress__determinate-circle-graphic,.mdc-circular-progress__indeterminate-circle-graphic{fill:rgba(0,0,0,0)}.mat-mdc-progress-spinner .mdc-circular-progress__determinate-circle,.mat-mdc-progress-spinner .mdc-circular-progress__indeterminate-circle-graphic{stroke:var(--mat-progress-spinner-active-indicator-color, var(--mat-sys-primary))}@media(forced-colors: active){.mat-mdc-progress-spinner .mdc-circular-progress__determinate-circle,.mat-mdc-progress-spinner .mdc-circular-progress__indeterminate-circle-graphic{stroke:CanvasText}}.mdc-circular-progress__determinate-circle{transition:stroke-dashoffset 500ms cubic-bezier(0, 0, 0.2, 1)}.mdc-circular-progress__gap-patch{position:absolute;top:0;left:47.5%;box-sizing:border-box;width:5%;height:100%;overflow:hidden}.mdc-circular-progress__gap-patch .mdc-circular-progress__indeterminate-circle-graphic{left:-900%;width:2000%;transform:rotate(180deg)}.mdc-circular-progress__circle-clipper .mdc-circular-progress__indeterminate-circle-graphic{width:200%}.mdc-circular-progress__circle-right .mdc-circular-progress__indeterminate-circle-graphic{left:-100%}.mdc-circular-progress--indeterminate .mdc-circular-progress__circle-left .mdc-circular-progress__indeterminate-circle-graphic{animation:mdc-circular-progress-left-spin calc(1333ms*var(--mat-progress-spinner-animation-multiplier)) cubic-bezier(0.4, 0, 0.2, 1) infinite both}.mdc-circular-progress--indeterminate .mdc-circular-progress__circle-right .mdc-circular-progress__indeterminate-circle-graphic{animation:mdc-circular-progress-right-spin calc(1333ms*var(--mat-progress-spinner-animation-multiplier)) cubic-bezier(0.4, 0, 0.2, 1) infinite both}.mdc-circular-progress__circle-clipper{display:inline-flex;position:relative;width:50%;height:100%;overflow:hidden}.mdc-circular-progress--indeterminate .mdc-circular-progress__spinner-layer{animation:mdc-circular-progress-spinner-layer-rotate calc(5332ms*var(--mat-progress-spinner-animation-multiplier)) cubic-bezier(0.4, 0, 0.2, 1) infinite both}@keyframes mdc-circular-progress-container-rotate{to{transform:rotate(360deg)}}@keyframes mdc-circular-progress-spinner-layer-rotate{12.5%{transform:rotate(135deg)}25%{transform:rotate(270deg)}37.5%{transform:rotate(405deg)}50%{transform:rotate(540deg)}62.5%{transform:rotate(675deg)}75%{transform:rotate(810deg)}87.5%{transform:rotate(945deg)}100%{transform:rotate(1080deg)}}@keyframes mdc-circular-progress-left-spin{from{transform:rotate(265deg)}50%{transform:rotate(130deg)}to{transform:rotate(265deg)}}@keyframes mdc-circular-progress-right-spin{from{transform:rotate(-265deg)}50%{transform:rotate(-130deg)}to{transform:rotate(-265deg)}}\n"],encapsulation:2,changeDetection:0})}return _})(),E=(()=>{class _{static \u0275fac=function(f){return new(f||_)};static \u0275mod=r.$C({type:_});static \u0275inj=m.G2t({imports:[h.y]})}return _})()}}]);
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.