"use strict";(self.webpackChunkdotcms_ui=self.webpackChunkdotcms_ui||[]).push([[2514],{22514:(Z,u,r)=>{r.r(u),r.d(u,{DotPortletDetailModule:()=>A});var a=r(36895),t=r(86353),d=r(87904),m=r(47619),w=r(38131),f=r(42816),h=r(21339),k=r(8817),p=r(14804);let v=(()=>{class o{constructor(e){this.dotWorkflowTaskDetailService=e,this.shutdown=new t.vpe,this.custom=new t.vpe}ngOnInit(){this.url$=this.dotWorkflowTaskDetailService.viewUrl$,this.header$=this.dotWorkflowTaskDetailService.header$}onClose(){this.dotWorkflowTaskDetailService.clear(),this.shutdown.emit()}}return o.\u0275fac=function(e){return new(e||o)(t.Y36(m.l))},o.\u0275cmp=t.Xpm({type:o,selectors:[["dot-workflow-task-detail"]],outputs:{shutdown:"shutdown",custom:"custom"},decls:3,vars:6,consts:[[3,"url","header","shutdown","custom"]],template:function(e,s){1&e&&(t.TgZ(0,"dot-iframe-dialog",0),t.NdJ("shutdown",function(){return s.onClose()})("custom",function(i){return s.custom.emit(i)}),t.ALo(1,"async"),t.ALo(2,"async"),t.qZA()),2&e&&t.Q6J("url",t.lcZ(1,2,s.url$))("header",t.lcZ(2,4,s.header$))},dependencies:[p.P,a.Ov],encapsulation:2}),o})(),D=(()=>{class o{constructor(e,s,l,i,c,I){this.dotWorkflowTaskDetailService=e,this.dotMessageService=s,this.dotRouterService=l,this.route=i,this.dotIframeService=c,this.dotCustomEventHandlerService=I}ngOnInit(){this.dotWorkflowTaskDetailService.view({header:this.dotMessageService.get("workflow.task.dialog.header"),id:this.route.snapshot.params.asset})}onCloseWorkflowTaskEditor(){this.dotRouterService.gotoPortlet("/c/workflow"),this.dotIframeService.reloadData("workflow")}onCustomEvent(e){["edit-task-executed-workflow","close"].includes(e.detail.name)?this.onCloseWorkflowTaskEditor():(e.detail.data.callback="fileActionCallbackFromAngular",this.dotCustomEventHandlerService.handle(e))}}return o.\u0275fac=function(e){return new(e||o)(t.Y36(m.l),t.Y36(w.l),t.Y36(f.W),t.Y36(d.gz),t.Y36(h.h),t.Y36(k.K))},o.\u0275cmp=t.Xpm({type:o,selectors:[["dot-workflow-task"]],features:[t._Bn([])],decls:1,vars:0,consts:[[3,"shutdown","custom"]],template:function(e,s){1&e&&(t.TgZ(0,"dot-workflow-task-detail",0),t.NdJ("shutdown",function(){return s.onCloseWorkflowTaskEditor()})("custom",function(i){return s.onCustomEvent(i)}),t.qZA())},dependencies:[v],encapsulation:2}),o})();var C=r(17118),T=r(97972);let W=(()=>{class o{constructor(e,s,l,i,c){this.dotContentletEditorService=e,this.dotRouterService=s,this.dotIframeService=l,this.route=i,this.dotCustomEventHandlerService=c}ngAfterViewInit(){setTimeout(()=>{this.dotContentletEditorService.edit({data:{inode:this.route.snapshot.params.asset}})},0)}onCloseEditor(){this.dotRouterService.gotoPortlet(`/c/${this.dotRouterService.currentPortlet.id}`),this.dotIframeService.reloadData(this.dotRouterService.currentPortlet.id)}onCustomEvent(e){this.dotCustomEventHandlerService.handle(e)}}return o.\u0275fac=function(e){return new(e||o)(t.Y36(C.G),t.Y36(f.W),t.Y36(h.h),t.Y36(d.gz),t.Y36(k.K))},o.\u0275cmp=t.Xpm({type:o,selectors:[["dot-contentlets"]],features:[t._Bn([])],decls:1,vars:0,consts:[[3,"shutdown","custom"]],template:function(e,s){1&e&&(t.TgZ(0,"dot-edit-contentlet",0),t.NdJ("shutdown",function(){return s.onCloseEditor()})("custom",function(i){return s.onCustomEvent(i)}),t.qZA())},dependencies:[T.Q],encapsulation:2}),o})();function _(o,n){1&o&&t._UZ(0,"dot-workflow-task")}function S(o,n){1&o&&t._UZ(0,"dot-contentlets")}let g=(()=>{class o{constructor(e){this.route=e,this.isWorkflow=!1,this.isContent=!1}ngOnInit(){this.isWorkflow="workflow"===this.route.parent.parent.snapshot.params.id,this.isContent=!this.isWorkflow}}return o.\u0275fac=function(e){return new(e||o)(t.Y36(d.gz))},o.\u0275cmp=t.Xpm({type:o,selectors:[["dot-portlet-detail"]],decls:2,vars:2,consts:[[4,"ngIf"]],template:function(e,s){1&e&&(t.YNc(0,_,1,0,"dot-workflow-task",0),t.YNc(1,S,1,0,"dot-contentlets",0)),2&e&&(t.Q6J("ngIf",s.isWorkflow),t.xp6(1),t.Q6J("ngIf",s.isContent))},dependencies:[a.O5,D,W]}),o})();var y=r(6619);let P=(()=>{class o{}return o.\u0275fac=function(e){return new(e||o)},o.\u0275mod=t.oAB({type:o}),o.\u0275inj=t.cJS({imports:[a.ez,y.r]}),o})();var E=r(67807);let Y=(()=>{class o{}return o.\u0275fac=function(e){return new(e||o)},o.\u0275mod=t.oAB({type:o}),o.\u0275inj=t.cJS({imports:[E.U]}),o})();const M=[{component:g,path:""}];let A=(()=>{class o{}return o.\u0275fac=function(e){return new(e||o)},o.\u0275mod=t.oAB({type:o}),o.\u0275inj=t.cJS({imports:[a.ez,P,Y,d.Bz.forChild(M)]}),o})()}}]);