1"use strict";(self.webpackChunkapp=self.webpackChunkapp||[]).push([[1011],{41011:(st,f,c)=>{c.r(f),c.d(f,{CalendarEventWidgetModule:()=>ct});var s=c(32881),l=c(35933),u=c(56959),x=c(27471),v=c(89908),y=c(89897),g=c(53750),C=c(59640),T=c(36933);const E=n=>{const a=n.container?.bl_cms_activity_category_hdr,e=a.guid?.toString(),o=a.name?.toString();return{guid:e,name:o,events:[]}};var D=c(9661);const I=(0,C.Mz)(T.u.KR,D.K8.selectWidgetByName("calendar-event-widget"),(n,a)=>{let o=Object.entries(n).map(([,r])=>r).map(r=>r.bl_cms_activity_category_hdr.guid?.toString()).map(r=>n[r]).filter(r=>!(0,g.kZ)(r)).map(r=>({container:r})).map(E),i=[];return a?.widgetPlaceHolderConfig?.param?.categoriesSortList?.forEach(r=>{o.every(d=>d.name!==r.name||(i.push(d),o=o.filter(p=>p.guid!==d.guid),!1))}),o?.length>0&&(i=[...i,...o]),i});var M=c(53993),F=c(96354),t=c(41360),m=function(n){return n.ALL_DAY="All Day",n.TODAY="Today",n}(m||{});const h=n=>({color:n});function w(n,a){if(1&n&&(t.qex(0),t.j41(1,"h3",5),t.EFF(2),t.nI1(3,"date"),t.k0s(),t.bVm()),2&n){const e=t.XpG(2);t.R7$(),t.Y8G("ngStyle",t.eq3(6,h,e.color)),t.R7$(),t.Lme(" ",e.today,", ",t.i5U(3,3,e.dateIndex," d MMMM")," ")}}function P(n,a){if(1&n&&(t.j41(0,"h3",5),t.EFF(1),t.nI1(2,"date"),t.k0s()),2&n){const e=t.XpG(2);t.Y8G("ngStyle",t.eq3(5,h,e.color)),t.R7$(),t.SpI(" ",t.i5U(2,2,e.dateIndex,"EEEE, d MMMM")," ")}}function G(n,a){if(1&n&&(t.qex(0),t.j41(1,"ion-text"),t.DNE(2,w,4,8,"ng-container",4),t.nI1(3,"date"),t.nI1(4,"date"),t.DNE(5,P,3,7,"ng-template",null,0,t.C5r),t.k0s(),t.bVm()),2&n){const e=t.sdS(6),o=t.XpG();t.R7$(2),t.Y8G("ngIf",t.i5U(3,2,o.currentDate,"d/M/yy")===t.i5U(4,5,o.dateIndex,"d/M/yy"))("ngIfElse",e)}}let b=(()=>{class n{constructor(){this.today=m.TODAY,this.currentDate=new Date}static{this.\u0275fac=function(o){return new(o||n)}}static{this.\u0275cmp=t.VBU({type:n,selectors:[["app-calendar-title-ui"]],inputs:{dateIndex:"dateIndex",color:"color"},standalone:!1,decls:3,vars:1,consts:[["notCurrentDate",""],[1,"pt-3","pl-3","pr-3","pb-1"],[1,"bot-border"],[4,"ngIf"],[4,"ngIf","ngIfElse"],[2,"margin-bottom","5px",3,"ngStyle"]],template:function(o,i){1&o&&(t.j41(0,"ion-row",1)(1,"ion-col",2),t.DNE(2,G,7,8,"ng-container",3),t.k0s()()),2&o&&(t.R
17$(2),t.Y8G("ngIf",i.dateIndex))},dependencies:[s.bT,s.B3,l.hU,l.ln,l.IO,s.vh],styles:[".bot-border[_ngcontent-%COMP%]{border-bottom:1px solid lightgray}"]})}}return n})();var $=c(96508),_=c.n($);let j=(()=>{class n{constructor(){}transform(e){if(e>0){const o=new Date;return o.setDate(o.getDate()+e),o}return new Date}static{this.\u0275fac=function(o){return new(o||n)}}static{this.\u0275pipe=t.EJ8({name:"getDateByIndex",type:n,pure:!0,standalone:!1})}}return n})(),O=(()=>{class n{constructor(){}transform(e,o){return e.filter(i=>i.totalDays>0).filter(i=>o>=i.startIndex&&o<i.totalDays+i.startIndex)}static{this.\u0275fac=function(o){return new(o||n)}}static{this.\u0275pipe=t.EJ8({name:"filterEventsByIndex",type:n,pure:!0,standalone:!1})}}return n})(),Y=(()=>{class n{constructor(){}transform(e,o){const i=_()().startOf("day").add(o,"days"),r=_()(e.endDate).startOf("day");return!_()(i).isSame(r,"day")}static{this.\u0275fac=function(o){return new(o||n)}}static{this.\u0275pipe=t.EJ8({name:"checkFullDay",type:n,pure:!0,standalone:!1})}}return n})(),R=(()=>{class n{transform(e,o){return e?o?_().utc(e).tz("Asia/Kuala_Lumpur").format("YYYY-MM-DD HH:mm:ss"):_().utc(e).format("YYYY-MM-DD HH:mm:ss"):""}static{this.\u0275fac=function(o){return new(o||n)}}static{this.\u0275pipe=t.EJ8({name:"convertToMlTimeZone",type:n,pure:!0,standalone:!1})}}return n})();const N=n=>({"background-color":n});function S(n,a){if(1&n&&(t.qex(0),t.j41(1,"h4",7),t.EFF(2),t.k0s(),t.bVm()),2&n){const e=t.XpG();t.R7$(2),t.SpI(" ",e.allDay," ")}}function W(n,a){if(1&n&&(t.j41(0,"h4",7),t.EFF(1),t.nI1(2,"convertToMlTimeZone"),t.nI1(3,"date"),t.nI1(4,"convertToMlTimeZone"),t.nI1(5,"date"),t.k0s()),2&n){const e=t.XpG();t.R7$(),t.Lme(" ",t.i5U(3,5,t.i5U(2,2,e.event.startDate,e.isConvertToMlTimeZone),"HH:mm")," - ",t.i5U(5,11,t.i5U(4,8,e.event.endDate,e.isConvertToMlTimeZone),"HH:mm")," ")}}let X=(()=>{class n{constructor(){this.isConvertToMlTimeZone=!1,this.onNavigate=new t.bkB,this.allDay=m.ALL_DAY}static{this.\u0275fac=function(o){return new(o||n)}}static{this.\u0275cmp=t.VBU({type:n,selectors:[["app-calendar-event-ui"]],inputs:{event:"event",index:"index",isConvertToMlTimeZone:"isConvertToMlTimeZone"},outputs:{onNavigate:"onNavigate"},standalone:!1,decls:11,vars:9,consts:[["notFullDay",""],[1,"box",3,"ngStyle"],[1,"box-1"],[1,"box-2"],[4,"ngIf","ngIfElse"],[3,"click"],[1,"event-name"],[2,"margin-bottom","0"]],template:function(o,i){if(1&o){const r=t.RV6();t.j41(0,"div",1)(1,"div",2)(2,"div",3)(3,"ion-text"),t.DNE(4,S,3,1,"ng-container",4),t.nI1(5,"checkFullDay"),t.DNE(6,W,6,14,"ng-template",null,0,t.C5r),t.k0s(),t.j41(8,"ion-text",5),t.bIt("click",function(){return t.eBV(r),t.Njj(i.onNavigate.emit(i.event))}),t.j41(9,"h3",6),t.EFF(10),t.k0s()()()()()}if(2&o){const r=t.sdS(7);t.Y8G("ngStyle",t.eq3(7,N,i.event.color)),t.R7$(4),t.Y8G("ngIf",t.i5U(5,4,i.event,i.index))("ngIfElse",r),t.R7$(6),t.SpI(" ",i.event.eventName," ")}},dependencies:[s.bT,s.B3,l.IO,s.vh,Y,R],styles:[".box[_ngcontent-%COMP%]{margin:10px;border-radius:5px}.box-1[_ngcontent-%COMP%]{background-color:#fff;position:relative;left:20px;width:calc(100% - 20px)}.box-2[_ngcontent-%COMP%]{padding:10px;border:2px solid lightgray;border-left:none}.event-name[_ngcontent-%COMP%]{margin-bottom:1px;color:#000;font-weight:700}.box[_ngcontent-%COMP%]:hover{opacity:.6}"]})}}return n})(),k=(()=>{class n{transform(e,o){return!(e.length>0&&e.some(r=>r?.trim()?.toLowerCase()===o?.trim()?.toLowerCase()))}static{this.\u0275fac=function(o){return new(o||n)}}static{this.\u0275pipe=t.EJ8({name:"filterCategory",type:n,pure:!0,standalone:!1})}}return n})();const V=n=>({height:n}),Z=()=>[];function B(n,a){if(1&n){const e=t.RV6();t.j41(0,"ion-col",16)(1,"app-calendar-event-ui",17),t.bIt("onNavigate",function(i){t.eBV(e);const r=t.XpG(6);return t.Njj(r.navigate(i))}),t.k0s()()}if(2&n){const e=a.$implicit,o=t.XpG(6);t.R7$(),t.Y8G("index",0)("isConvertToMlTimeZone",o.isConvertToMlTimeZone)("event",e)}}function H(n,a){if(1&n&&(t.j41(0,"ion-accordion",9)(1,"ion-row",10)(2,"ion-col")(3,"h2",11),t.EFF(4),t.k0s()(),t.j41(5,"div",12),t.nrm(6,"ion-icon",13),t.k0s()(),t.j41(7,"ion-row",14),t.DNE(8,B,2,3,"ion-col",15),t.k0s()()),2&n){const e=t.XpG().ngIf,o=t.XpG(2).$implicit;t.R7$(4),t.SpI(" ",o.name," "),t.R7$(4),t.Y8G("ngForOf",e)}}function U(n,a){if(1&n&&(t.qex(0),t.DNE(1,H,9,2,"ion-accordion",8),t.bVm()),2&n){const e=a.ngIf;t.R7$(),t.Y8G("ngIf",e.length>0)}}function A(n,a){if(1&n&&(t.qex(0),t.DNE(1,U,2,1,"ng-container",0),t.nI1(2,"filterEventsByIndex"),t.bVm()),2&n){const e=t.XpG().$implicit;t.R7$(),t.Y8G("ngIf",t.i5U(2,1,e.events,0))}}function L(n,a){if(1&n&&(t.qex(0),t.DNE(1,A,3,4,"ng-container",0),t.nI1(2,"filterCategory"),t.bVm()),2&n){const e=a.$implicit,o=t.XpG(2);t.R7$(),t.Y8G("ngIf",t.i5U(2,1,o.activityCategories,null==e?null:e.name))}}function z(n,a){if(1&n){const e=t.RV6();t.j41(0,"ion-col",16)(1,"app-calendar-event-ui",18),t.bIt("onNavigate",function(i){t.eBV(e);const r=t.XpG(7);return t.Njj(r.navigate(i))}),t.k0s()()}if(2&n){const e=a.$implicit,o=t.XpG(5).index,i=t.XpG(2);t.R7$(),t.Y8G("index",o+1)("event",e)("isConvertToMlTimeZone",i.isConvertToMlTimeZone)}}function J(n,a){if(1&n&&(t.j41(0,"ion-accordion",9)(1,"ion-row",10)(2,"ion-col")(3,"h2",11),t.EFF(4),t.k0s()(),t.j41(5,"div",12),t.nrm(6,"ion-icon",13),t.k0s()(),t.j41(7,"ion-row",14),t.DNE(8,z,2,3,"ion-col",15),t.k0s()()),2&n){const e=t.XpG().ngIf,o=t.XpG(2).$implicit;t.R7$(4),t.SpI(" ",o.name," "),t.R7$(4),t.Y8G("ngForOf",e)}}function K(n,a){if(1&n&&(t.qex(0),t.DNE(1,J,9,2,"ion-accordion",8),t.bVm()),2&n){const e=a.ngIf;t.R7$(),t.Y8G("ngIf",e.length>0)}}function Q(n,a){if(1&n&&(t.qex(0),t.DNE(1,K,2,1,"ng-container",0),t.nI1(2,"filterEventsByIndex"),t.bVm()),2&n){const e=t.XpG().$implicit,o=t.XpG().index;t.R7$(),t.Y8G("ngIf",t.i5U(2,1,e.events,o+1))}}function q(n,a){if(1&n&&(t.qex(0),t.DNE(1,Q,3,4,"ng-container",0),t.nI1(2,"filterCategory"),t.bVm()),2&n){const e=a.$implicit,o=t.XpG(3);t.R7$(),t.Y8G("ngIf",t.i5U(2,1,o.activityCategories,null==e?null:e.name))}}function tt(n,a){if(1&n&&(t.j41(0,"ion-row")(1,"ion-col"),t.nrm(2,"app-calendar-title-ui",1),t.nI1(3,"getDateByIndex"),t.j41(4,"ion-row",2)(5,"ion-col")(6,"ion-accordion-group"),t.DNE(7,q,3,4,"ng-container",3),t.k0s()()()()()),2&n){const e=a.index,o=t.XpG().ngIf,i=t.XpG();t.R7$(2),t.Y8G("dateIndex",t.bMT(3,3,e+1))("color",i.textColor),t.R7$(5),t.Y8G("ngForOf",o)}}function nt(n,a){if(1&n){const e=t.RV6();t.j41(0,"ion-card")(1,"ion-row")(2,"ion-col"),t.nrm(3,"app-calendar-title-ui",1),t.nI1(4,"getDateByIndex"),t.j41(5,"ion-row",2)(6,"ion-col")(7,"ion-accordion-group"),t.DNE(8,L,3,4,"ng-container",3),t.k0s()()(),t.j41(9,"ion-row",4)(10,"ion-col")(11,"div",5)(12,"span",6),t.bIt("click",function(){t.eBV(e);const i=t.XpG();
1return t.Njj(i.onToggle())}),t.EFF(13),t.k0s()()()()()(),t.j41(14,"ion-row")(15,"ion-col",7),t.DNE(16,tt,8,5,"ion-row",3),t.k0s()()()}if(2&n){const e=a.ngIf,o=t.XpG();t.R7$(3),t.Y8G("dateIndex",t.bMT(4,6,0))("color",o.textColor),t.R7$(5),t.Y8G("ngForOf",e),t.R7$(5),t.SpI(" ",o.viewMore," "),t.R7$(2),t.Y8G("ngStyle",t.eq3(8,V,o.collapse?"auto":0)),t.R7$(),t.Y8G("ngForOf",t.lJ4(10,Z).constructor(6))}}let et=(()=>{class n{constructor(e){this.store=e,this.dateColor="#000",this.textColor="#000",this.collapse=!1,this.viewMore="View More",this.activityCategories=[],this.isConvertToMlTimeZone=!0,this.events$=this.store.select(v.e.getWeeklyEvents),this.activityCategory$=this.store.select(I).pipe((0,M.E)(this.store.select(v.e.getWeeklyEvents)),(0,F.T)(([o,i])=>[...o.map(d=>({...d,events:i.filter(p=>p.activityCategory==d.guid)}))]))}ngOnInit(){this.widgetPlaceHolderConfigParams=this.widgetPlaceHolderConfig.param,this.dateColor=this.widgetPlaceHolderConfigParams?.dateColor??this.dateColor,this.textColor=this.widgetPlaceHolderConfigParams?.textColor??this.textColor,this.isConvertToMlTimeZone=(0,g.uJ)(this.widgetPlaceHolderConfigParams?.isConvertToMlTimeZone)?this.isConvertToMlTimeZone:this.widgetPlaceHolderConfigParams?.isConvertToMlTimeZone,this.store.dispatch(x.n.loadWeeklyEventOnDateInit({date:new Date})),this.widgetPlaceHolderConfigParams?.hiddenActivityCategories?.length>0&&(this.activityCategories=this.widgetPlaceHolderConfigParams?.hiddenActivityCategories)}navigate(e){return(0,g.uJ)(e?.layoutInstance?.url)?(0,g.uJ)(e?.url)||this.store.dispatch(y.Y3.navigateForward({url:e.url})):this.store.dispatch(y.Y3.navigateForward({url:e.layoutInstance.url,queryParams:{...e.layoutInstance.queryParams}})),!1}onToggle(){this.collapse=!this.collapse,this.viewMore=this.collapse?"View Less":"View More"}static{this.\u0275fac=function(o){return new(o||n)(t.rXU(C.il))}}static{this.\u0275cmp=t.VBU({type:n,selectors:[["calendar-event-widget"]],inputs:{widgetPlaceHolderConfig:"widgetPlaceHolderConfig"},standalone:!1,decls:5,vars:3,consts:[[4,"ngIf"],[3,"dateIndex","color"],[1,"pb-3","pl-3","pr-3"],[4,"ngFor","ngForOf"],[1,"ml-3","mr-3","mb-3"],[1,"align-end"],[1,"view-more",3,"click"],[3,"ngStyle"],["class","bot-border",4,"ngIf"],[1,"bot-border"],["slot","header"],[1,"category-name"],[1,"header-icon","center"],["name","chevron-down",1,"ion-accordion-toggle-icon"],["slot","content"],["size","12",4,"ngFor","ngForOf"],["size","12"],[3,"onNavigate","index","isConvertToMlTimeZone","event"],[3,"onNavigate","index","event","isConvertToMlTimeZone"]],template:function(o,i){1&o&&(t.j41(0,"ion-grid")(1,"ion-row")(2,"ion-col"),t.DNE(3,nt,17,11,"ion-card",0),t.nI1(4,"async"),t.k0s()()()),2&o&&(t.R
17$(3),t.Y8G("ngIf",t.bMT(4,1,i.activityCategory$)))},dependencies:[l.xk,l.YH,l.b_,l.hU,l.lO,l.iq,l.ln,b,X,s.Sq,s.bT,s.B3,j,O,s.Jj,k],styles:["ion-card[_ngcontent-%COMP%]{max-width:400px;border-radius:15px;margin:auto}ion-icon[_ngcontent-%COMP%]{cursor:pointer}.bot-border[_ngcontent-%COMP%]{border-bottom:1px solid lightgray} .mat-typography h1{font-family:Arnhem,Times,serif;font-size:24px} .mat-typography h3{font-family:Arnhem,Times,serif;font-size:18px} .mat-typography h4{font-family:Arnhem,Times,serif;font-size:17px}.category-name[_ngcontent-%COMP%]{font-family:Arnhem,Times,serif;margin:4px 0 4px 2px}.center[_ngcontent-%COMP%]{display:flex;justify-content:center;align-items:center}.header-icon[_ngcontent-%COMP%]{width:40px;display:flex;justify-content:flex-end;align-items:center}.view-more[_ngcontent-%COMP%]{font-family:Arnhem,Times,serif;font-size:14px;cursor:pointer;color:#1d311d}.align-end[_ngcontent-%COMP%]{text-align:end}.event-name[_ngcontent-%COMP%]{margin-bottom:1px;color:#000;font-weight:700}"]})}}return n})();var ot=c(79350),it=c(62525),at=c(7456);let rt=(()=>{class n{static{this.\u0275fac=function(o){return new(o||n)}}static{this.\u0275mod=t.$C({type:n})}static{this.\u0275inj=t.G2t({imports:[s.MD,l.bv,at.vj,ot.d,it.s,u.L]})}}return n})(),ct=(()=>{class n{static{this.rootComponent=et}static{this.\u0275fac=function(o){return new(o||n)}}static{this.\u0275mod=t.$C({type:n})}static{this.\u0275inj=t.G2t({providers:[s.vh],imports:[l.bv,u.L,rt,s.MD]})}}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.