1"use strict";(self.webpackChunkstartdeck_pwa=self.webpackChunkstartdeck_pwa||[]).push([[842],{6842:(Yt,y,m)=>{m.r(y),m.d(y,{TeamDocsModule:()=>Dt});var S=m(4543),_=m(6204),e=m(1699),d=m(1071),p=m(6575),o=m(8849);function M(i,s){1&i&&(e.ynx(0),e.TgZ(1,"button",31),e._uU(2," Subscribe "),e.qZA(),e.TgZ(3,"p",32),e._uU(4," This type of account (Gmail) may not create a Team Docs account as they do not support shared drives. These accounts may join a StartDeck Team, but Teams can only be created from Google Workspace Business Account "),e.qZA(),e.TgZ(5,"p",33),e._uU(6," For assistance, please email "),e.TgZ(7,"u"),e._uU(8,"[email protected]"),e.qZA()(),e.BQk())}function q(i,s){1&i&&(e.ynx(0),e.TgZ(1,"a",34),e._uU(2," Try now "),e.qZA(),e.BQk()),2&i&&(e.xp6(1),e.Q6J("routerLink","/subscription/team-docs"))}function J(i,s){if(1&i){const t=e.EpF();e.ynx(0),e.TgZ(1,"a",35),e.NdJ("click",function(){e.CHM(t);const a=e.oxw();return e.KtG(a.redirectToTeamDocs())}),e._uU(2," Try now "),e.qZA(),e.BQk()}}let N=(()=>{class i{constructor(t,n,a){this.apiService=t,this.helperService=n,this.authService=a,this.email=""}ngOnInit(){}subscribeEmailFormHandler(t){this.email=t.value.email,""!=this.email?/^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(this.email)?(this.apiService.post("subscribe-to-startdeck",{email:this.email}).subscribe(),this.email="",this.helperService.successMessage("Thank you for subscribing to StartDeck. We will notify you with new updates.")):this.helperService.errorMessage("Please provide the valid email address."):this.helperService.errorMessage("Please provide the email address")}redirectToTeamDocs(){this.authService.isLoggedIn||this.helperService.navigateToUrl("/login?action=team-docs")}back(){this.helperService.jumpToPreviousPage()}static#e=this.\u0275fac=function(n){return new(n||i)(e.Y36(d.sM),e.Y36(d.W_),e.Y36(d.e8))};static#t=this.\u0275cmp=e.Xpm({type:i,selectors:[["app-team-docs"]],decls:62,vars:4,consts:[[1,"bg-white"],[1,"md:container","mx-auto"],[1,"flex","sm:items-center","px-4","py-3"],[1,"pr-2"],["href","javascript:void(0);",1,"text-gray-300",3,"click"],[1,"fa","fa-angle-left","font-bold","text-3xl"],[1,"text-gray-300","font-medium","flex-1","text-center","text-sm","sm:text-base"],[1,"min-h-90-vh","lg:min-h-70-vh","xl:min-h-screen"],[1,"md:container","mx-auto","px-4","py-4"],[1,"w-full","md:w-10/12","xl:w-8/12","mx-auto","text-center","mt-4","mb-6","sm:mb-8"],[1,"text-gray-600","sm:leading-8","text-sm","sm:text-base"],[1,"grid","grid-cols-1","sm:grid-cols-2","lg:grid-cols-4","gap-6"],[1,"bg-white","shadow-card","px-3","py-4","text-center"],["src","assets/images/team-docs/team-templates.png","alt","Centralized, Branded and Complaint Team Templates",1,"inline-block","mb-4","w-32"],[1,"text-gray-300","text-sm","font-bold","mb-3"],[1,"text-center","text-xs","text-gray-600","mb-2"],[1,"text-center","text-xs","text-gray-600"],["src","assets/images/team-docs/file-management.png","alt","Streamlined Team Project and File Management",1,"inline-block","mb-4","w-32"],["src","assets/images/team-docs/team-sharing.png","alt","Simple, Secure Team Sharing",1,"inline-block","mb-4","w-32"],["src","assets/images/team-docs/member-roles.png","alt","Easily Manage Team Rosters and Member Roles",1,"inline-block","mb-4","w-32"],[1,"text-center","py-8"],[4,"ngIf"],[1,"flex","flex-wrap","sm:p-8",2,"background-image","url(assets/images/team-docs/subscribe-bg-primary.png)"],[1,"container","mx-auto","px-4","py-4","mb-20"],[1,"bg-white","shadow-card","p-8","text-center","w-full","lg:w-7/12","mx-auto"],["src","assets/images/team-docs/icon-envelope-open-primary.svg",1,"inline-block"],[1,"text-gray-300","text-2xl","leading-8","font-bold","mb-2","mt-4"],[1,"text-center","text-sm","text-gray-600","font-normal","mb-6"],["type","email","placeholder","Enter Your Email","name","email",1,"border-b","border-gray-900","text-sm","block","w-full","sm:w-8/12","mx-auto","py-3","h-12","mb-6","text-gray-300","focus:outline-none","focus:shadow-outline","focus:border-primary","placeholder-gray-light",3,"ngModel","ngModelChange"],[1,"bg-primary","px-6","py-2","text-white","text-sm","tracking-wider","font-medium","focus:outline-none","hover:shadow-btn","transition-all","duration-300"],["src","assets/images/icon-send.svg",1,"inline-block"],[1,"bg-gray-900","rounded","px-6","py-2","text-white","text-sm","tracking-wider","font-medium","focus:outline-none","hover:shadow-btn","transition-all","duration-300","mb-3","cursor-not-allowed"],[1,"text-center","text-xs","
1sm:text-sm","text-danger","font-normal","tracking-wide","mb-2"],[1,"text-center","text-xs","sm:text-sm","text-danger","font-normal","tracking-wide"],[1,"bg-success","rounded","px-6","py-2","text-white","text-sm","tracking-wider","font-medium","focus:outline-none","hover:shadow-btn","transition-all","duration-300","inline-block",3,"routerLink"],["href","javascript:void(0);",1,"bg-success","rounded","px-6","py-2","text-white","text-sm","tracking-wider","font-medium","focus:outline-none","hover:shadow-btn","transition-all","duration-300","inline-block",3,"click"]],template:function(n,a){1&n&&(e.TgZ(0,"div",0)(1,"div",1)(2,"div",2)(3,"div",3)(4,"a",4),e.NdJ("click",function(){return a.back()}),e._UZ(5,"i",5),e.qZA()(),e.TgZ(6,"div",6),e._uU(7," StartDeck Team Docs Edition "),e.qZA()()()(),e.TgZ(8,"div",7)(9,"div",8)(10,"div",9)(11,"p",10),e._uU(12,"Managing a team? Use our Team Docs edition to centralize your templates, projects and content for your entire team. Team-wide workflow transparency. Secure and scalable."),e.qZA()(),e.TgZ(13,"div",11)(14,"div",12),e._UZ(15,"img",13),e.TgZ(16,"h4",14),e._uU(17,"Centralized, Branded and Complaint Team Templates"),e.qZA(),e.TgZ(18,"p",15),e._uU(19,"End the confusion and use of outdated and non-compliant templates."),e.qZA(),e.TgZ(20,"p",16),e._uU(21,"StartDeck Team Docs organizes templates for all team members making sure your reports are on-brand and compliant."),e.qZA()(),e.TgZ(22,"div",12),e._UZ(23,"img",17),e.TgZ(24,"h4",14),e._uU(25,"Streamlined Team Project and File Management"),e.qZA(),e.TgZ(26,"p",15),e._uU(27,"Like Templates, Projects are centralized on StartDeck Team Docs."),e.qZA(),e.TgZ(28,"p",16),e._uU(29,"Team members can quickly find projects and files in a central location, tagged and indexed for fast search across all your devices. "),e.qZA()(),e.TgZ(30,"div",12),e._UZ(31,"img",18),e.TgZ(32,"h4",14),e._uU(33,"Simple, Secure Team Sharing"),e.qZA(),e.TgZ(34,"p",15),e._uU(35,"Team members easily collaborate and leverage team resources with StartDeck Team Docs."),e.qZA(),e.TgZ(36,"p",16),e._uU(37,"Shared team resources include templates, projects, content library and contacts."),e.qZA()(),e.TgZ(38,"div",12),e._UZ(39,"img",19),e.TgZ(40,"h4",14),e._uU(41,"Easily Manage Team Rosters and Member Roles"),e.qZA(),e.TgZ(42,"p",15),e._uU(43,"Add/remove Team members as needed easily. Onboard new users with just an email address - Team Docs takes care of the details."),e.qZA(),e.TgZ(44,"p",16),e._uU(45,"Roles for Manager, Content Manager and Contributor give members the right permissions for the role."),e.qZA()()(),e.TgZ(46,"div",20),e.YNc(47,M,9,0,"ng-container",21),e.YNc(48,q,3,1,"ng-container",21),e.YNc(49,J,3,0,"ng-container",21),e.qZA()(),e.TgZ(50,"div",22)(51,"div",23)(52,"div",24),e._UZ(53,"img",25),e.TgZ(54,"h2",26),e._uU(55,"Get Updates"),e.qZA(),e.TgZ(56,"p",27),e._uU(57,"We will not share your email address."),e.qZA(),e.TgZ(58,"input",28),e.NdJ("ngModelChange",function(c){return a.email=c}),e.qZA(),e.TgZ(59,"button",29),e._uU(60," Subscribe "),e._UZ(61,"img",30),e.qZA()()()()()),2&n&&(e.xp6(47),e.Q6J("ngIf",a.authService.user&&0==a.authService.user.can_create_team_drives),e.xp6(1),e.Q6J("ngIf",a.authService.user&&1==a.authService.user.can_create_team_drives),e.xp6(1),e.Q6J("ngIf",!a.authService.user),e.xp6(9),e.Q6J("ngModel",a.email))},dependencies:[p.O5,_.rH,o.Fj,o.JJ,o.On],encapsulation:2})}return i})();var b=m(3455);let L=(()=>{class i extends b.u{constructor(){super(),this.data={}}ngOnInit(){}setInputData(t){this.data=t}static#e=this.\u0275fac=function(n){return new(n||i)};static#t=this.\u0275cmp=e.Xpm({type:i,selectors:[["app-upgrade-team-docs-licenses"]],features:[e.qOj],decls:11,vars:1,consts:[[1,"modal","in","p-4"],[1,"modal-dialog","w-full","sm:w-8/12","md:w-6/12","animated-from-top","relative","rounded"],[1,"fa","fa-times","text-danger","text-sm","mt-1","leading-6","opacity-75","cursor-pointer","modalclose","absolute","right-0","mr-4",3,"click"],[1,"modal-body","p-4","border-b","border-gray-white"],[1,"text-xl","font-bold","text-center","mb-2"],[1,"text-center","text-sm","text-gray-600","font-normal","mt-4"],[1,"p-4","text-center"],["href","javascript:void(0);",1,"bg-primary","inline-block","px-4","py-2","text-white","rounded","text-sm","tracking-wide","font-medium","focus:outline-none","hover:shadow-btn","transition-all","duration-300",3,"routerLink","click"]],template:function(n,a){1&n&&(e.TgZ(0,"div",0)(1,"div",1)(2,"i",2),e.NdJ("click",function(){return a.close()}),e.qZA(),e.TgZ(3,"div",3)(4,"h4",4),e._uU(5,"Upgrade Team Doc Licenses"),e.qZA(),e.TgZ(6,"p",5),e._uU(7," You have assigned all your purchased licenses. Please upgrade your licenses. "),e.qZA()(),e.TgZ(8,"div",6)(9,"a",7),e.NdJ("click",function(){return a.close()}),e._uU(10," Upgrade Now "),e.qZA()()()()),2&n&&(e.xp6(9),e.Q6J("routerLink","/subscription/team-docs/upgrade"))},dependencies:[_.rH],encapsulation:2})}return i})();var g=m(2185);function Q(i,s){1&i&&(e.TgZ(0,"div",10),e._UZ(1,"i",11),e.qZA())}function D(i,s){if(1&i&&(e.TgZ(0,"span"),e._uU(1),e.qZA()),2&i){const t=e.oxw(2);e.xp6(1),e.AsE(" You have assigned ",t.data.licenses.length," out of your ",t.data.team_docs_members_count," licenses. ")}}function j(i,s){1&i&&e._uU(0," To add new members in roster, Please add more licenses. ")}const Z=function(){return{manage_licenses:"true"}};function Y(i,s){1&i&&(e.TgZ(0,"li",35)(1,"a",25),e._uU(2," Remove Licenses "),e.qZA()()),2&i&&(e.xp6(1),e.Q6J("routerLink","/subscription/team-docs/downgrade")("queryParams",e.DdM(2,Z)))}function E(i,s){1&i&&(e.TgZ(0,"span",44),e._uU(1," (Team Owner) "),e.qZA())}
1function O(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"div",45)(1,"a",46),e.NdJ("click",function(){e.CHM(t);const a=e.oxw().$implicit,r=e.oxw(2);return e.KtG(r.deleteLicense(a.uid))}),e._UZ(2,"img",47),e.qZA()()}}function F(i,s){if(1&i&&(e.TgZ(0,"li",36)(1,"div",37),e._UZ(2,"img",38),e.TgZ(3,"div",39)(4,"div",40),e._uU(5),e.YNc(6,E,2,0,"span",41),e.qZA(),e.TgZ(7,"small",42),e._uU(8),e.qZA()()(),e.YNc(9,O,3,0,"div",43),e.qZA()),2&i){const t=s.$implicit;e.xp6(2),e.Q6J("src",t.profile_image_url,e.LSH),e.xp6(3),e.hij(" "," "!=t.name?t.name:"--"," "),e.xp6(1),e.Q6J("ngIf",t.is_owner),e.xp6(2),e.Oqu(t.email),e.xp6(1),e.Q6J("ngIf",!t.is_owner)}}function B(i,s){if(1&i){const t=e.EpF();e.ynx(0),e.TgZ(1,"label",48),e._uU(2," Add New Team Member to Roster: "),e.qZA(),e.TgZ(3,"div",49)(4,"div",50)(5,"input",51),e.NdJ("ngModelChange",function(a){e.CHM(t);const r=e.oxw(2);return e.KtG(r.email=a)}),e.qZA(),e.TgZ(6,"button",52),e.NdJ("click",function(){e.CHM(t);const a=e.oxw(2);return e.KtG(a.addMember())}),e._uU(7," Add "),e.qZA()()(),e.TgZ(8,"div",53),e._UZ(9,"i",54),e._uU(10," Team members must have a private Gmail or Business Google Workspace account. NOTE: Adding a team member to the roster will not add the user to a team. To invite a team member to join a specific team, go to Active Teams. "),e.qZA(),e.BQk()}if(2&i){const t=e.oxw(2);e.xp6(5),e.Q6J("value",t.email)("ngModel",t.email)}}function H(i,s){if(1&i&&(e.TgZ(0,"div",12)(1,"div",13)(2,"div",14)(3,"div",15)(4,"div",16),e._UZ(5,"i",17),e.YNc(6,D,2,2,"span",18),e.YNc(7,j,1,0,"ng-template",null,19,e.W1O),e.qZA(),e.TgZ(9,"div",20)(10,"a",21),e._UZ(11,"img",22),e.qZA(),e.TgZ(12,"ul",23)(13,"li",24)(14,"a",25),e._uU(15," Add Licenses "),e.qZA()(),e.YNc(16,Y,3,3,"li",26),e.qZA()()(),e.TgZ(17,"div",27),e._uU(18,"Team Roster"),e.qZA(),e.TgZ(19,"div",28)(20,"ul",29),e.YNc(21,F,10,5,"li",30),e.qZA()(),e.YNc(22,B,11,2,"ng-container",31),e.qZA(),e.TgZ(23,"div",32)(24,"a",33),e._uU(25," Create New Team "),e.qZA(),e.TgZ(26,"a",34),e._uU(27," Go to Active Teams "),e.qZA()()()()),2&i){const t=e.MAs(8),n=e.oxw();e.xp6(6),e.Q6J("ngIf",n.data.team_docs_members_count>1)("ngIfElse",t),e.xp6(8),e.Q6J("routerLink","/subscription/team-docs/upgrade")("queryParams",e.DdM(9,Z)),e.xp6(2),e.Q6J("ngIf",n.data.team_docs_members_count>1&&n.data.licenses.length<n.data.team_docs_members_count),e.xp6(5),e.Q6J("ngForOf",n.data.licenses),e.xp6(1),e.Q6J("ngIf",n.data.team_docs_members_count>1&&n.data.licenses.length<n.data.team_docs_members_count),e.xp6(2),e.Q6J("routerLink","/team-docs/teams/create"),e.xp6(2),e.Q6J("routerLink","/team-docs/teams")}}let R=(()=>{class i{constructor(t,n){this.helperService=t,this.teamDocsService=n,this.data={},this.email=""}ngOnInit(){this.teamDocsService.observer().subscribe(t=>this.data=t),this.getLicenses()}getLicenses(){this.teamDocsService.licenses().subscribe(t=>{t.error?(this.helperService.errorMessage(t.message),this.helperService.navigateToUrl("projects")):(this.teamDocsService.updateObserver(t.data),this.helperService.bindJqueryDropdown())})}deleteLicense(t){confirm("Are you sure you want to delete this member? This will also delete this member from all the active teams. \n \n All data is retained on team drive.")&&(this.helperService.blockUI(),this.teamDocsService.deleteLicense(t).subscribe(n=>{n.error?(this.helperService.errorMessage(n.message),this.helperService.unBlockUI()):(this.teamDocsService.updateObserver(n.data),this.helperService.successMessage("Member Deleted."),this.helperService.unBlockUI())}))}validatate(){var t=!1,n="";return this.email?/^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(this.email)||(t=!0,n="Please enter a valid email address."):(t=!0,n="Please provide email address."),!t||(this.helperService.errorMessage(n),!1)}addMember(){if(this.validatate()){if(this.data.licenses.length>=this.data.team_docs_members_count)return void this.helperService.openModal(L,null);this.helperService.blockUI(),this.teamDocsService.addLicenseMember({email:this.email}).subscribe(t=>{t.error?this.helperService.errorMessage(t.message):(this.teamDocsService.updateObserver(t.data),this.email="",this.helperService.successMessage("Member Added.")),this.helperService.unBlockUI()})}}back(){this.helperService.jumpToPreviousPage()}static#e=this.\u0275fac=function(n){return new(n||i)(e.Y36(d.W_),e.Y36(g.e))};
1static#t=this.\u0275cmp=e.Xpm({type:i,selectors:[["app-licenses"]],decls:12,vars:2,consts:[[1,"bg-white"],[1,"container","mx-auto"],[1,"flex","sm:items-center","px-4","py-3"],[1,"pr-2"],["href","javascript:void(0);",1,"text-gray-300",3,"click"],[1,"fa","fa-angle-left","font-bold","text-3xl"],[1,"text-gray-300","font-medium","flex-1","text-center","text-sm","sm:text-base"],[1,"container","mx-auto","px-4","py-4","min-h-90-vh","lg:min-h-70-vh","xl:min-h-screen","mb-20"],["class","mt-20 p-25p text-center",4,"ngIf","ngIfElse"],["showLicenses",""],[1,"mt-20","p-25p","text-center"],["aria-hidden","true",1,"fa","fa-spinner","fa-2x","fa-spin","text-primary","font-size-50"],[1,"flex","flex-wrap"],[1,"w-full","md:w-10/12","mx-auto"],[1,"bg-white","shadow-card","p-3","sm:p-4","mb-4"],[1,"p-2","mb-3","text-primary","bg-primary","bg-opacity-10","border","border-primary","border-opacity-25","text-sm","rounded","flex","relative"],[1,"w-11/12","md:w-8/12"],[1,"fa","fa-exclamation-circle"],[4,"ngIf","ngIfElse"],["hasOnlyOneLicense",""],[1,"w-1/12","md:w-4/12","text-right"],["href","javascript:void(0);",1,"inline-block","md:hidden","dropdown-toggle-action"],["src","assets/images/icon-ellipsis-v.svg",1,"inline-block"],[1,"bg-white","md:bg-transparent","list-none","shadow-dropdown","md:shadow-none","text-sm","text-left","md:text-right","leading-6","text-gray-300","px-3","md:px-0","absolute","md:static","rounded","dropdown-menu","hidden","md:block","z-10","mt-2","md:mt-0","md:flex","md:flex-wrap","md:items-center","md:justify-end",2,"right","16px"],[1,"block","md:inline-block","py-2","md:py-0"],["href","javascript:void(0);",1,"md:text-primary","md:underline",3,"routerLink","queryParams"],["class","block md:inline-block py-2 md:py-0 border-t md:border-t-0 border-light md:border-l md:border-primary md:border-opacity-25 md:pl-4 md:ml-4",4,"ngIf"],[1,"mb-2","text-gray-300","text-sm","font-medium"],[1,"bg-smoke-white","bg-opacity-25","border","border-gray-light","border-opacity-25","rounded","px-3"],[1,"last-child-style-none"],["class","flex justify-between sm:items-center py-3 border-b border-light",4,"ngFor","ngForOf"],[4,"ngIf"],[1,"flex","w-full","gap-4","justify-center","text-center"],["href","javascript:void(0);",1,"bg-success","rounded","px-2","sm:px-6","py-2","w-6/12","sm:w-auto","inline-block","text-white","text-xs","sm:text-sm","tracking-wider","font-medium","focus:outline-none","hover:shadow-btn","transition-all","duration-300",3,"routerLink"],["href","javascript:void(0);",1,"bg-primary","rounded","px-2","sm:px-6","py-2","w-6/12","sm:w-auto","inline-block","text-white","text-xs","sm:text-sm","tracking-wider","font-medium","focus:outline-none","hover:shadow-btn","transition-all","duration-300",3,"routerLink"],[1,"block","md:inline-block","py-2","md:py-0","border-t","md:border-t-0","border-light","md:border-l","md:border-primary","md:border-opacity-25","md:pl-4","md:ml-4"],[1,"flex","justify-between","sm:items-center","py-3","border-b","border-light"],[1,"flex","items-start"],[1,"inline-block","w-7","h-7","rounded-full","mt-0.5",3,"src"],[1,"ml-2"],[1,"text-gray-300","text-sm","leading-4","sm:leading-5","flex","flex-wrap","gap-0.5","break-all"],["class","text-gray-900",4,"ngIf"],[1,"text-gray-900","leading-4","break-all"],["class","text-right w-6",4,"ngIf"],[1,"text-gray-900"],[1,"text-right","w-6"],["href","javascript:void(0);",3,"click"],["alt","Delete","src","assets/images/icon-delete-danger.svg",1,"inline-block","w-3"],[1,"block","text-gray-600","text-sm","font-medium","mb-2","mt-3"],[1,"w-full"],[1,"flex","items-center","border","border-primary","rounded"],["id","","type","text","placeholder","Please enter a Gmail or Google Workspace email address","required","true","autofocus","",1,"appearance-none","bg-transparent","border-none","w-full","text-gray-300","focus:outline-none","focus:shadow-outline","placeholder-gray-light","text-xs","sm:text-sm","p-2",3,"value","ngModel","ngModelChange"],["type","button",1,"bg-primary","px-4","sm:px-6","py-2","text-white","text-xs","tracking-wider","font-medium","focus:outline-none","hover:shadow-btn","transition-all","duration-300",3,"click"],[1,"p-2","mt-4","text-gray-600","bg-gray-600","bg-opacity-10","border","border-gray-600","border-opacity-25","font-normal","text-xs","rounded"],[1,"fa","fa-info-circle","text-sm"]],template:function(n,a){if(1&n&&(e.TgZ(0,"div",0)(1,"div",1)(2,"div",2)(3,"div",3)(4,"a",4),e.NdJ("click",function(){return a.back()}),e._UZ(5,"i",5),e.qZA()(),e.TgZ(6,"div",6),e._uU(7," Manage Team Roster "),e.qZA()()()(),e.TgZ(8,"div",7),e.YNc(9,Q,2,0,"div",8),e.YNc(10,H,28,10,"ng-template",null,9,e.W1O),e.qZA()),2&n){const r=e.MAs(11);e.xp6(9),e.Q6J("ngIf",!a.data.licenses)("ngIfElse",r)}},dependencies:[p.sg,p.O5,_.rH,o.Fj,o.JJ,o.Q7,o.On],encapsulation:2})}return i})(),k=(()=>{class i{transform(t,n){n=n.toLowerCase();const a=[];return 0===t.length||""===n?t:(t.forEach(function(r){r.name.toLowerCase().includes(n)&&a.push(r)}),a)}static#e=this.\u0275fac=function(n){return new(n||i)};static#t=this.\u0275pipe=e.Yjl({name:"teamFilter",type:i,pure:!1})}return i})();function G(i,s){1&i&&(e.TgZ(0,"div",11),e._UZ(1,"i",12),e.qZA())}function V(i,s){1&i&&(e.TgZ(0,"p",13),e._UZ(1,"i",14),e._uU(2," This Team Docs subscription has been canceled or expired. To continue using Team Docs, please "),e.TgZ(3,"a",15),e._uU(4,"subscribe"),e.qZA(),e._uU(5,". All Team files are retained on your shared Google Drive. "),e.qZA()),2&i&&(e.xp6(3),e.Q6J("routerLink","/subscription/team-docs"))}
1function P(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"div",20)(1,"input",21),e.NdJ("ngModelChange",function(a){e.CHM(t);const r=e.oxw(2);return e.KtG(r.searchTeam=a)}),e.qZA(),e.TgZ(2,"i",22),e.NdJ("click",function(){e.CHM(t);const a=e.oxw(2);return e.KtG(a.searchTeam="")}),e.qZA()()}if(2&i){const t=e.oxw(2);e.xp6(1),e.Q6J("ngModel",t.searchTeam)}}function K(i,s){if(1&i&&(e.ynx(0),e.TgZ(1,"a",23),e._UZ(2,"img",24),e.qZA(),e.TgZ(3,"ul",25)(4,"li",26)(5,"a",27),e._uU(6," Manage Team Roster "),e.qZA()(),e.TgZ(7,"li",26)(8,"a",28),e.ALo(9,"teamFilter"),e._uU(10," Create New Team "),e.qZA()(),e.TgZ(11,"li",26)(12,"a",29),e._uU(13," Inactive Teams "),e.qZA()()(),e.BQk()),2&i){const t=e.oxw(2);e.xp6(5),e.Q6J("routerLink","/team-docs/licenses"),e.xp6(3),e.Q6J("routerLink","/team-docs/teams/create")("ngClass",0===e.xi3(9,4,t.teams,t.searchTeam).length?"sm:bg-success sm:bg-opacity-100 sm:border-success sm:text-white":"sm:text-gray-600"),e.xp6(4),e.Q6J("routerLink","/team-docs/inactive-teams")}}function W(i,s){1&i&&(e.TgZ(0,"div",30)(1,"div",31),e._uU(2,"No active team found"),e.qZA(),e.TgZ(3,"p",32),e._uU(4," You can either "),e.TgZ(5,"span",33),e._uU(6,"create a new team"),e.qZA(),e.TgZ(7,"a",34),e._uU(8,"create a new team"),e.qZA(),e._uU(9," or reactivate "),e.TgZ(10,"span",33),e._uU(11,"inactive team"),e.qZA(),e.TgZ(12,"a",34),e._uU(13,"inactive team"),e.qZA(),e._uU(14," if any. "),e.qZA()()),2&i&&(e.xp6(7),e.Q6J("routerLink","/team-docs/teams/create"),e.xp6(5),e.Q6J("routerLink","/team-docs/inactive-teams"))}function $(i,s){if(1&i&&(e.TgZ(0,"a",45),e._UZ(1,"i",46),e.qZA()),2&i){const t=e.oxw().$implicit;e.Q6J("href","https://drive.google.com/drive/u/2/folders/"+t.google_drive_id,e.LSH)}}function z(i,s){1&i&&e._UZ(0,"img",50)}function X(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"a",51),e.NdJ("click",function(){e.CHM(t);const a=e.oxw(2).$implicit,r=e.oxw(3);return e.KtG(r.acceptInviation(a))}),e._uU(1," Accept "),e.qZA()}}function ee(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"a",52),e.NdJ("click",function(){e.CHM(t);const a=e.oxw(2).$implicit,r=e.oxw(3);return e.KtG(r.setActiveTeam(a))}),e._uU(1," Set as Active "),e.qZA()}}function te(i,s){if(1&i&&(e.TgZ(0,"div"),e.YNc(1,z,1,0,"img",47),e.YNc(2,X,2,0,"a",48),e.YNc(3,ee,2,0,"a",49),e.qZA()),2&i){const t=e.oxw().$implicit;e.xp6(1),e.Q6J("ngIf",t.is_default),e.xp6(1),e.Q6J("ngIf",t.has_pending_invitation),e.xp6(1),e.Q6J("ngIf",!t.has_pending_invitation&&!t.is_default)}}function ie(i,s){1&i&&(e.TgZ(0,"div",53),e._UZ(1,"i",14),e._uU(2," Subscription Expired "),e.qZA())}function ne(i,s){if(1&i&&(e.TgZ(0,"div",37)(1,"a",38),e._UZ(2,"img",39),e.qZA(),e.TgZ(3,"div",40)(4,"div",41)(5,"a",42),e._uU(6),e.qZA(),e.YNc(7,$,2,1,"a",43),e.qZA(),e.YNc(8,te,4,3,"div",10),e.YNc(9,ie,3,0,"div",44),e.qZA()()),2&i){const t=s.$implicit;e.xp6(1),e.Q6J("title",t.name)("routerLink","/team-docs/teams/"+t.uid),e.xp6(1),e.Q6J("src",t.profile_image,e.LSH),e.xp6(3),e.Q6J("title",t.name)("routerLink","/team-docs/teams/"+t.uid),e.xp6(1),e.hij(" ",t.name," "),e.xp6(1),e.Q6J("ngIf",t.has_subscription_expired),e.xp6(1),e.Q6J("ngIf",!t.has_subscription_expired),e.xp6(1),e.Q6J("ngIf",t.has_subscription_expired)}}function ae(i,s){if(1&i&&(e.TgZ(0,"div",35),e.YNc(1,ne,10,9,"div",36),e.ALo(2,"teamFilter"),e.qZA()),2&i){const t=e.oxw(2);e.xp6(1),e.Q6J("ngForOf",e.xi3(2,1,t.teams,t.searchTeam))}}function re(i,s){if(1&i&&(e.ynx(0),e.TgZ(1,"div",16),e.YNc(2,P,3,1,"div",17),e.YNc(3,K,14,7,"ng-container",10),e.qZA(),e.YNc(4,W,15,2,"div",18),e.ALo(5,"teamFilter"),e.YNc(6,ae,3,4,"div",19),e.BQk()),2&i){const t=e.oxw();e.xp6(2),e.Q6J("ngIf",!t.authService.user.hasAnyExpiredTeamDocsSubscription),e.xp6(1),e.Q6J("ngIf",t.authService.user.hasTeamDocsSubscription&&!t.authService.user.hasAnyExpiredTeamDocsSubscription),e.xp6(1),e.Q6J("ngIf",0===e.xi3(5,4,t.teams,t.searchTeam).length),e.xp6(2),e.Q6J("ngIf",t.teams.length>0)}}let se=(()=>{class i{constructor(t,n,a){this.teamDocsService=t,this.helperService=n,this.authService=a,this.searchTeam="",this.teams=null}ngOnInit(){this.getTeams()}ngAfterViewInit(){this.helperService.bindJqueryDropdown()}getTeams(){this.teamDocsService.getTeams().subscribe(t=>{t&&!t.error?this.teams=t:(this.helperService.errorMessage(t.message),this.helperService.navigateToUrl("/team-docs"))})}back(){this.helperService.jumpToPreviousPage()}setActiveTeam(t){confirm("This action will display '"+t.name+"' Templates, Projects, Contacts and Content Library entries in StartDeck. \n\n"+t.owner_name+" is the owner of "+t.name+"'s content. \n\nYou can switch back to personal Templates and Projects at any time.")&&this.teamDocsService.makeTeamDefault(t.uid).subscribe(a=>{a&&!a.error?this.helperService.navigateToUrl("/projects"):this.helperService.errorMessage(
1a.message)})}acceptInviation(t){this.helperService.blockUI(),this.teamDocsService.acceptTeamInvitation(t.uid).subscribe(n=>{n&&n.error?(this.helperService.errorMessage(n.message),this.helperService.unBlockUI()):(this.helperService.navigateToUrl("/team-docs/teams/"+t.uid),this.helperService.successMessage("Invitation Accepted."),this.helperService.unBlockUI())})}static#e=this.\u0275fac=function(n){return new(n||i)(e.Y36(g.e),e.Y36(d.W_),e.Y36(d.e8))};static#t=this.\u0275cmp=e.Xpm({type:i,selectors:[["app-teams"]],decls:12,vars:3,consts:[[1,"bg-white"],[1,"container","mx-auto"],[1,"flex","sm:items-center","px-4","py-3","relative"],[1,"pr-2"],["href","javascript:void(0);",1,"text-gray-300",3,"click"],[1,"fa","fa-angle-left","font-bold","text-3xl"],[1,"text-gray-300","font-medium","flex-1","text-center","text-sm","sm:text-base"],[1,"container","mx-auto","px-4","py-4","min-h-90-vh","lg:min-h-70-vh","xl:min-h-screen","mb-20"],["class","mt-20 p-25p text-center",4,"ngIf"],["class","text-sm text-danger rounded-md bg-red-100 px-3 py-2 mb-3",4,"ngIf"],[4,"ngIf"],[1,"mt-20","p-25p","text-center"],["aria-hidden","true",1,"fa","fa-spinner","fa-2x","fa-spin","text-primary","font-size-50"],[1,"text-sm","text-danger","rounded-md","bg-red-100","px-3","py-2","mb-3"],[1,"fa","fa-exclamation-triangle"],["href","javascript:void(0);",1,"underline","whitespace-nowrap","font-medium","hover:text-red-600",3,"routerLink"],[1,"flex","sm:block","items-center","mb-4","relative"],["class","relative flex-1 mr-2 sm:mr-0",4,"ngIf"],["class","md:w-8/12 mx-auto text-center pt-4 sm:pt-8",4,"ngIf"],["class","grid grid-cols-1 sm:grid-cols-2 md:grid-cols-3 xl:grid-cols-4 gap-4 sm:gap-5",4,"ngIf"],[1,"relative","flex-1","mr-2","sm:mr-0"],["placeholder","Search Teams",1,"border","border-gray-light","px-2","py-1","h-10","text-sm","leading-4","font-normal","text-gray-300","placeholder-gray-light","rounded","w-full","focus:outline-none","focus:border-primary",3,"ngModel","ngModelChange"],[1,"fa","fa-search","text-gray-light","text-sm","absolute","right-2","top-3",3,"click"],["href","javascript:void(0);",1,"inline-block","sm:hidden","dropdown-toggle-action","text-right"],["src","assets/images/icon-ellipsis-v.svg",1,"inline-block","w-8"],[1,"bg-white","min-w-36","sm:w-auto","sm:bg-transparent","list-none","shadow-dropdown","sm:shadow-none","text-xs","text-left","sm:text-right","leading-6","text-gray-300","px-3","sm:px-0","absolute","sm:static","rounded","dropdown-menu","hidden","z-10","sm:flex","sm:flex-wrap","sm:items-center","sm:gap-3","sm:justify-end","top-9","right-0","mt-2","sm:mt-3"],[1,"block","sm:inline-block"],["href","javascript:void(0);",1,"sm:bg-gray-white","sm:bg-opacity-50","sm:hover:bg-primary","sm:rounded","sm:px-3","py-1","block","sm:inline-block","sm:text-gray-600","sm:hover:text-white","border-b","sm:border","border-light","sm:border-gray-900","sm:hover:border-primary","text-xs","tracking-wider","focus:outline-none","sm:hover:shadow-btn","transition-all","duration-300",3,"routerLink"],["href","javascript:void(0);",1,"sm:bg-gray-white","sm:bg-opacity-50","sm:hover:bg-success","sm:rounded","sm:px-3","py-1","block","sm:inline-block","sm:hover:text-white","border-b","sm:border","border-light","sm:border-gray-900","sm:hover:border-success","text-xs","tracking-wider","focus:outline-none","sm:hover:shadow-btn","transition-all","duration-300",3,"routerLink","ngClass"],["href","javascript:void(0);",1,"sm:bg-gray-white","sm:bg-opacity-50","sm:hover:bg-warning","sm:rounded","sm:px-3","py-1","block","sm:inline-block","sm:text-gray-600","sm:hover:text-white","border-b","sm:border","border-light","sm:border-gray-900","sm:hover:border-warning","text-xs","tracking-wider","focus:outline-none","sm:hover:shadow-btn","transition-all","duration-300",3,"routerLink"],[1,"md:w-8/12","mx-auto","text-center","pt-4","sm:pt-8"],[1,"text-gray-900","mb-4"],[1,"mb-6","text-gray-600","font-normal","sm:font-medium","text-xs","sm:text-sm","leading-6"],[1,"hidden","sm:inline"],["href","javascript:void(0);",1,"text-primary","underline","inline","sm:hidden",3,"routerLink"],[1,"grid","grid-cols-1","sm:grid-cols-2","md:grid-cols-3","xl:grid-cols-4","gap-4","sm:gap-5"],["class","bg-white shadow-card rounded clearfix p-1.5 sm:p-0",4,"ngFor","ngForOf"],[1,"bg-white","shadow-card","rounded","clearfix","p-1.5","sm:p-0"],["href","javascript:void(0);",1,"inline-block","sm:block","float-left","sm:float-none","mr-1.5","sm:mr-0",3,"title","routerLink"],["alt","",1,"h-8","sm:h-24","md:h-36","object-cover","w-8","sm:w-full","rounded","sm:rounded-t","sm:rounded-b-none",3,"src"],[1,"flex","justify-between","p-0","sm:p-2","sm:w-full","mt-0.5","sm:mt-0"],[1,"truncate","pr-2"],["href","javascript:void(0);",1,"sm:font-medium","text-gray-300","text-sm","hover:text-primary","transition-all","duration-300",3,"title","routerLink"],["title","Open Team folder in Google Drive","class","text-primary text-sm ml-1","target","_blank",3,"href",4,"ngIf"],["class","text-danger text-xxs italic font-medium",4,"ngIf"],["title","Open Team folder in Google Drive","target","_blank",1,"text-primary","text-sm","ml-1",3,"href"],[1,"fa","fa-external-link"],["class","inline-block -mt-0.5","src","assets/images/icon-check-success.svg",4,"ngIf"],["title","Accept","class","bg-primary bg-opacity-10 text-primary hover:bg-primary focus:outline-none hover:shadow-btn inline-block px-1.5 sm:px-2.5 py-0.5 font-medium rounded text-gray-300 hover:text-white text-opacity-75 text-xs focus:outline-none hover:shadow-btn transition-all duration-300","href","javascript:void(0);",3,"click",4,"ngIf"],["class","bg-success bg-opacity-10 text-success hover:bg-success focus:outline-none hover:shadow-btn inline-block px-1.5 sm:px-2.5 py-0.5 font-medium rounded text-gray-300 hover:text-white text-opacity-75 text-xs focus:outline-none hover:shadow-btn transition-all duration-300","href","javascript:void(0);",3,"click",4,"ngIf"],["src","assets/images/icon-check-success.svg",1,"inline-block","-mt-0.5"],["title","Accept","href","javascript:void(0);",1,"bg-primary","bg-opacity-10","text-primary","hover:bg-primary","focus:outline-none","hover:shadow-btn","inline-block","px-1.5","sm:px-2.5","py-0.5","font-medium","rounded","text-gray-300","hover:text-white","text-opacity-75","text-xs","focus:outline-none","hover:shadow-btn","transition-all","duration-300",3,"click"],["href","javascript:void(0);",1,"bg-success","bg-opacity-10","text-success","hover:bg-success","focus:outline-none","hover:shadow-btn","inline-block","px-1.5","sm:px-2.5","py-0.5","font-medium","rounded","text-gray-300","hover:text-white","text-opacity-75","text-xs","focus:outline-none","hover:shadow-btn","transition-all","duration-300",3,"click"],[1,"text-danger","text-xxs","italic","font-medium"]],template:function(n,a){1&n&&(e.TgZ(0,"div",0)(1,"div",1)(2,"div",2)(3,"div",3)(4,"a",4),e.NdJ("click",function(){return a.back()}),e._UZ(5,"i",5),e.qZA()(),e.TgZ(6,"div",6),e._uU(7," Active Teams "),e.qZA()()()(),e.TgZ(8,"div",7),e.YNc(9,G,2,0,"div",8),e.YNc(10,V,6,1,"p",9),e.YNc(11,re,7,7,"ng-container",10),e.qZA()),2&n&&(e.xp6(9),e.Q6J("ngIf",!a.teams),e.xp6(1),e.Q6J("ngIf",a.authService.user.hasAnyExpiredTeamDocsSubscription),e.xp6(1),e.Q6J("ngIf",a.teams))},dependencies:[p.mk,p.sg,p.O5,_.rH,o.Fj,o.JJ,o.On,k],encapsulation:2})}return i})();function oe(i,s){1&i&&(e.TgZ(0,"div",10),e._UZ(1,"i",11),e.qZA())}function ce(i,s){1&i&&(e.TgZ(0,"a",20),e._UZ(1,"img",21),e.qZA())}
1function le(i,s){if(1&i&&(e.TgZ(0,"ul",22)(1,"li",23)(2,"a",24),e._uU(3," Manage Team Roster "),e.qZA()(),e.TgZ(4,"li",23)(5,"a",25),e.ALo(6,"teamFilter"),e._uU(7," Create New Team "),e.qZA()(),e.TgZ(8,"li",23)(9,"a",26),e._uU(10," Active Teams "),e.qZA()()()),2&i){const t=e.oxw(2);e.xp6(2),e.Q6J("routerLink","/team-docs/licenses"),e.xp6(3),e.Q6J("routerLink","/team-docs/teams/create")("ngClass",0===e.xi3(6,4,t.teams,t.searchTeam).length?"sm:bg-success sm:bg-opacity-100 sm:border-success sm:text-white":"sm:text-gray-600"),e.xp6(4),e.Q6J("routerLink","/team-docs/teams")}}function me(i,s){1&i&&(e.TgZ(0,"div",27)(1,"div",28),e._uU(2,"No inactive team found"),e.qZA()())}function de(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"div",40)(1,"a",41),e.NdJ("click",function(){e.CHM(t);const a=e.oxw().$implicit,r=e.oxw(3);return e.KtG(r.remove(a))}),e._uU(2," Remove Team "),e.qZA()()}}function pe(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"div",31)(1,"div",32),e._UZ(2,"img",33),e.qZA(),e.TgZ(3,"div",34)(4,"div",35)(5,"span",36),e._uU(6),e.qZA()(),e.YNc(7,de,3,0,"div",37),e.TgZ(8,"div",38)(9,"a",39),e.NdJ("click",function(){const r=e.CHM(t).$implicit,c=e.oxw(3);return e.KtG(c.activate(r))}),e._uU(10," Activate "),e.qZA()()()()}if(2&i){const t=s.$implicit,n=e.oxw(3);e.xp6(1),e.Q6J("title",t.name),e.xp6(1),e.Q6J("src",t.profile_image,e.LSH),e.xp6(3),e.Q6J("title",t.name),e.xp6(1),e.hij(" ",t.name," "),e.xp6(1),e.Q6J("ngIf",n.authService.user.email==t.owner_email)}}function _e(i,s){if(1&i&&(e.TgZ(0,"div",29),e.YNc(1,pe,11,5,"div",30),e.ALo(2,"teamFilter"),e.qZA()),2&i){const t=e.oxw(2);e.xp6(1),e.Q6J("ngForOf",e.xi3(2,1,t.teams,t.searchTeam))}}function ue(i,s){if(1&i){const t=e.EpF();e.ynx(0),e.TgZ(1,"div",12)(2,"div",13)(3,"input",14),e.NdJ("ngModelChange",function(a){e.CHM(t);const r=e.oxw();return e.KtG(r.searchTeam=a)}),e.qZA(),e.TgZ(4,"i",15),e.NdJ("click",function(){e.CHM(t);const a=e.oxw();return e.KtG(a.searchTeam="")}),e.qZA()(),e.YNc(5,ce,2,0,"a",16),e.YNc(6,le,11,7,"ul",17),e.qZA(),e.YNc(7,me,3,0,"div",18),e.ALo(8,"teamFilter"),e.YNc(9,_e,3,4,"div",19),e.BQk()}if(2&i){const t=e.oxw();e.xp6(3),e.Q6J("ngModel",t.searchTeam),e.xp6(2),e.Q6J("ngIf",1==t.authService.user.can_create_team_drives),e.xp6(1),e.Q6J("ngIf",1==t.authService.user.can_create_team_drives),e.xp6(1),e.Q6J("ngIf",0===e.xi3(8,5,t.teams,t.searchTeam).length),e.xp6(2),e.Q6J("ngIf",t.teams.length>0)}}let ge=(()=>{class i{constructor(t,n,a){this.teamDocsService=t,this.helperService=n,this.authService=a,this.searchTeam="",this.teams=null}ngAfterViewInit(){this.helperService.bindJqueryDropdown()}ngOnInit(){this.getDeactiveTeams()}getDeactiveTeams(){this.teamDocsService.getDeactiveTeams().subscribe(t=>{t&&!t.error?this.teams=t:(this.helperService.errorMessage(t.message),this.helperService.navigateToUrl("/team-docs/teams"))})}activate(t){this.helperService.blockUI(),this.teamDocsService.activateTeam(t.uid).subscribe(n=>{n&&!n.error?(this.helperService.navigateToUrl("/team-docs/teams"),this.helperService.successMessage("Team '"+t.name+"' activated. View team to set as default."),this.helperService.unBlockUI()):(this.helperService.errorMessage(n.message),this.helperService.unBlockUI())})}remove(t){1==confirm("Are you sure you want to remove this team?\n\nThis action removes the Team from StartDeck. All folders, templates, projects and content library entries are retained in the Team Owner's shared drive.")&&(this.helperService.blockUI(),this.teamDocsService.removeTeam(t.uid).subscribe(n=>{n&&!n.error?(this.helperService.navigateToUrl("/team-docs/teams"),this.helperService.successMessage("Team '"+t.name+"' removed sucessfully."),this.helperService.unBlockUI()):(this.helperService.errorMessage(n.message),this.helperService.unBlockUI())}))}back(){this.helperService.jumpToPreviousPage()}static#e=this.\u0275fac=function(n){return new(n||i)(e.Y36(g.e),e.Y36(d.W_),e.Y36(d.e8))};static#t=this.\u0275cmp=e.Xpm({type:i,selectors:[["app-inactive-teams"]],decls:11,vars:2,consts:[[1,"bg-white"],[1,"container","mx-auto"],[1,"flex","sm:items-center","px-4","py-3","relative"],[1,"pr-2"],["href","javascript:void(0);",1,"text-gray-300",3,"click"],[1,"fa","fa-angle-left","font-bold","text-3xl"],[1,"text-gray-300","font-medium","flex-1","text-center","text-sm","sm:text-base"],[1,"container","mx-auto","px-4","py-4","min-h-90-vh","lg:min-h-70-vh","xl:min-h-screen","mb-2
10"],["class","mt-20 p-25p text-center",4,"ngIf"],[4,"ngIf"],[1,"mt-20","p-25p","text-center"],["aria-hidden","true",1,"fa","fa-spinner","fa-2x","fa-spin","text-primary","font-size-50"],[1,"flex","sm:block","items-center","mb-4","relative"],[1,"relative","flex-1","mr-2","sm:mr-0"],["type","text","name","","id","","placeholder","Search Teams",1,"border","border-gray-light","px-2","py-1","h-10","text-sm","leading-4","font-normal","text-gray-300","placeholder-gray-light","rounded","w-full","focus:outline-none","focus:border-primary",3,"ngModel","ngModelChange"],[1,"fa","fa-search","text-gray-light","text-sm","absolute","right-2","top-3",3,"click"],["class","inline-block sm:hidden dropdown-toggle-action text-right","href","javascript:void(0);",4,"ngIf"],["class","bg-white min-w-36 sm:w-auto sm:bg-transparent list-none shadow-dropdown sm:shadow-none text-xs text-left sm:text-right leading-6 text-gray-300 px-3 sm:px-0 absolute sm:static rounded dropdown-menu hidden z-10 sm:flex sm:flex-wrap sm:items-center sm:gap-3 sm:justify-end top-9 right-0 mt-2 sm:mt-3",4,"ngIf"],["class","md:w-8/12 mx-auto text-center pt-4 sm:pt-8",4,"ngIf"],["class","grid grid-cols-1 sm:grid-cols-2 md:grid-cols-3 xl:grid-cols-4 gap-4 sm:gap-5",4,"ngIf"],["href","javascript:void(0);",1,"inline-block","sm:hidden","dropdown-toggle-action","text-right"],["src","assets/images/icon-ellipsis-v.svg",1,"inline-block","w-8"],[1,"bg-white","min-w-36","sm:w-auto","sm:bg-transparent","list-none","shadow-dropdown","sm:shadow-none","text-xs","text-left","sm:text-right","leading-6","text-gray-300","px-3","sm:px-0","absolute","sm:static","rounded","dropdown-menu","hidden","z-10","sm:flex","sm:flex-wrap","sm:items-center","sm:gap-3","sm:justify-end","top-9","right-0","mt-2","sm:mt-3"],[1,"block","sm:inline-block"],["href","javascript:void(0);",1,"sm:bg-gray-white","sm:bg-opacity-50","sm:hover:bg-primary","sm:rounded","sm:px-3","py-1","block","sm:inline-block","sm:text-gray-600","sm:hover:text-white","border-b","sm:border","border-light","sm:border-gray-900","sm:hover:border-primary","text-xs","tracking-wider","focus:outline-none","sm:hover:shadow-btn","transition-all","duration-300",3,"routerLink"],["href","javascript:void(0);",1,"sm:bg-gray-white","sm:bg-opacity-50","sm:hover:bg-success","sm:rounded","sm:px-3","py-1","block","sm:inline-block","sm:hover:text-white","border-b","sm:border","border-light","sm:border-gray-900","sm:hover:border-success","text-xs","tracking-wider","focus:outline-none","sm:hover:shadow-btn","transition-all","duration-300",3,"routerLink","ngClass"],["href","javascript:void(0);",1,"sm:bg-gray-white","sm:bg-opacity-50","sm:hover:bg-warning","sm:rounded","sm:px-3","py-1","block","sm:inline-block","sm:text-gray-600","sm:hover:text-white","border-b","sm:border","border-light","sm:border-gray-900","sm:hover:border-warning","text-xs","tracking-wider","focus:outline-none","sm:hover:shadow-btn","transition-all","duration-300",3,"routerLink"],[1,"md:w-8/12","mx-auto","text-center","pt-4","sm:pt-8"],[1,"text-gray-900","mb-4"],[1,"grid","grid-cols-1","sm:grid-cols-2","md:grid-cols-3","xl:grid-cols-4","gap-4","sm:gap-5"],["class","bg-white shadow-card rounded clearfix p-1.5 sm:p-0",4,"ngFor","ngForOf"],[1,"bg-white","shadow-card","rounded","clearfix","p-1.5","sm:p-0"],[1,"inline-block","sm:block","float-left","sm:float-none","mr-1.5","sm:mr-0",3,"title"],["alt","",1,"h-8","sm:h-24","md:h-36","object-cover","w-8","sm:w-full","rounded","sm:rounded-t","sm:rounded-b-none",3,"src"],[1,"flex","justify-between","p-0","sm:p-2","sm:w-full","mt-0.5","sm:mt-0"],[1,"flex-1","truncate","pr-2"],[1,"sm:font-medium","text-gray-300","text-sm",3,"title"],["class","mr-3",4,"ngIf"],[1,""],["href","javascript:void(0);",1,"bg-primary","bg-opacity-10","text-primary","hover:bg-primary","focus:outline-none","hover:shadow-btn","inline-block","px-1.5","sm:px-2.5","py-0.5","font-medium","rounded","text-gray-300","hover:text-white","text-opacity-75","text-xs","focus:outline-none","hover:shadow-btn","transition-all","duration-300",3,"click"],[1,"mr-3"],["href","javascript:void(0);",1,"bg-danger","bg-opacity-10","text-danger","hover:bg-danger","focus:outline-none","hover:shadow-btn","inline-block","px-1.5","sm:px-2.5","py-0.5","font-medium","rounded","hover:text-white","text-xs","focus:outline-none","hover:shadow-btn","transition-all","duration-300",3,"click"]],template:function(n,a){1&n&&(e.TgZ(0,"div",0)(1,"div",1)(2,"div",2)(3,"div",3)(4,"a",4),e.NdJ("click",function(){return a.back()}),e._UZ(5,"i",5),e.qZA()(),e.TgZ(6,"div",6),e._uU(7," Inactive Teams "),e.qZA()()()(),e.TgZ(8,"div",7),e.YNc(9,oe,2,0,"div",8),e.YNc(10,ue,10,8,"
1ng-container",9),e.qZA()),2&n&&(e.xp6(9),e.Q6J("ngIf",!a.teams),e.xp6(1),e.Q6J("ngIf",a.teams))},dependencies:[p.mk,p.sg,p.O5,_.rH,o.Fj,o.JJ,o.On,k],encapsulation:2})}return i})();var u=m(7178),h=m(4769);function he(i,s){if(1&i&&(e.TgZ(0,"option",8),e._uU(1),e.qZA()),2&i){const t=s.$implicit;e.Q6J("value",t.key),e.xp6(1),e.hij(" ",t.value," ")}}let A=(()=>{class i{constructor(t){this.data=t}ngOnInit(){}onChange(t){t&&(this.data.member={...this.data.member,role:t,role_name:(0,u.find)(this.data.roles,(n,a)=>a==t)})}update(){return this.data.member}close(){return null}static#e=this.\u0275fac=function(n){return new(n||i)(e.Y36(h.eJ))};static#t=this.\u0275cmp=e.Xpm({type:i,selectors:[["app-edit-member-role"]],decls:14,vars:7,consts:[["mat-dialog-title","",1,"text-base","leading-6","break-all"],[1,"w-full"],["matInput","",1,"appearance-none","relative","block","w-full","text-xs","rounded","px-3","h-10","bg-white","border","border-gray-light","focus:border-primary","focus:outline-none","select-aarow-change","text-gray-900",3,"ngModel","change"],["value",""],[3,"value",4,"ngFor","ngForOf"],["align","end"],[1,"px-3","py-1","font-medium","bg-warning","text-xs","text-white","rounded","my-3","mr-2","focus:outline-none","hover:shadow-btn","transition-all","duration-300",3,"mat-dialog-close"],[1,"px-3","py-1","font-medium","bg-primary","text-xs","text-white","rounded","my-3","focus:outline-none","hover:shadow-btn","transition-all","duration-300",3,"mat-dialog-close"],[3,"value"]],template:function(n,a){1&n&&(e.TgZ(0,"h3",0),e._uU(1),e.qZA(),e.TgZ(2,"mat-dialog-content")(3,"div",1)(4,"select",2),e.NdJ("change",function(c){return a.onChange(c.target.value)}),e.TgZ(5,"option",3),e._uU(6," Select Role "),e.qZA(),e.YNc(7,he,2,2,"option",4),e.ALo(8,"keyvalue"),e.qZA()()(),e.TgZ(9,"mat-dialog-actions",5)(10,"button",6),e._uU(11," Cancel "),e.qZA(),e.TgZ(12,"button",7),e._uU(13," Update "),e.qZA()()),2&n&&(e.xp6(1),e.hij(" ",a.data.member.email," "),e.xp6(3),e.Q6J("ngModel",a.data.member.role),e.xp6(3),e.Q6J("ngForOf",e.lcZ(8,5,a.data.roles)),e.xp6(3),e.Q6J("mat-dialog-close",a.close()),e.xp6(2),e.Q6J("mat-dialog-close",a.update()))},dependencies:[p.sg,o.YN,o.Kr,o.EJ,o.JJ,o.On,h.aO,h.YS,h.Rb,h.ev,p.Nd],encapsulation:2})}return i})();var fe=m(1670),xe=m(9740),v=m(8540),be=m(605);function ve(i,s){1&i&&(e.TgZ(0,"div",13),e._UZ(1,"i",14),e.qZA())}function Te(i,s){if(1&i&&(e.TgZ(0,"li",30)(1,"div",25),e._uU(2," Current number of licenses: "),e.qZA(),e.TgZ(3,"div",31)(4,"div",32),e._uU(5),e.qZA()()()),2&i){const t=e.oxw(2);e.xp6(5),e.hij(" ",t.subscription.members_count," ")}}function we(i,s){if(1&i&&(e.TgZ(0,"li",33)(1,"div",34),e._uU(2," Total amount: "),e.qZA(),e.TgZ(3,"div",31)(4,"div",32),e._uU(5),e.qZA()()()),2&i){const t=e.oxw(2);e.xp6(5),e.hij(" $",t.no_of_license*t.data.plan.price," ")}}function ye(i,s){if(1&i&&(e.TgZ(0,"div",35),e._uU(1),e.qZA()),2&i){const t=e.oxw(2);e.xp6(1),e.lnq(" You are adding ",t.no_of_license," new license(s) so your next billing amount for ",t.no_of_license+t.subscription.members_count," license(s) will be $",t.no_of_license*t.data.plan.price+t.totalAmount,". ")}}function Ze(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"div",15)(1,"div",16)(2,"div",17)(3,"span",18),e._uU(4),e.qZA(),e.TgZ(5,"span",19),e._uU(6,"\xa0/ License / Month"),e.qZA()()(),e.TgZ(7,"p",20),e._uU(8),e.qZA(),e.TgZ(9,"div",21)(10,"ul",22),e.YNc(11,Te,6,1,"li",23),e.TgZ(12,"li",24)(13,"div",25),e._uU(14," Add new licenses: "),e.qZA(),e.TgZ(15,"div",26)(16,"input",27),e.NdJ("ngModelChange",function(a){e.CHM(t);const r=e.oxw();return e.KtG(r.no_of_license=a)}),e.qZA()()(),e.YNc(17,we,6,1,"li",28),e.qZA()(),e.YNc(18,ye,2,3,"div",29),e.qZA()}if(2&i){const t=e.oxw();e.xp6(4),e.hij("$",t.data.plan.price,""),e.xp6(4),e.hij(" All of your ",t.ownerLicenses," license(s) have been assigned to team members. To add additional team members, please add additional license(s). "),e.xp6(3),e.Q6J("ngIf",t.subscription),e.xp6(5),e.Q6J("value",t.no_of_license)("ngModel",t.no_of_license)("min",t.requiredLicenses),e.xp6(1),e.Q6J("ngIf",t.data.plan&&t.subscription&&!t.subscription.subscription.on_trial),e.xp6(1),e.Q6J("ngIf",t.data.plan&&t.subscription&&!t.subscription.subscription.on_trial)}}
1function ke(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"a",39),e.NdJ("click",function(){e.CHM(t);const a=e.oxw(2);return e.KtG(a.apply())}),e._uU(1,"Cancel"),e.qZA()}}function Ae(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"a",39),e.NdJ("click",function(){e.CHM(t);const a=e.oxw(2);return e.KtG(a.apply())}),e._uU(1,"Cancel"),e.qZA()}}function Ce(i,s){1&i&&(e.TgZ(0,"button",40),e._uU(1,"Add Licenses Now"),e.qZA())}function Ue(i,s){if(1&i&&(e.TgZ(0,"button",40),e._uU(1),e.qZA()),2&i){const t=e.oxw(2);e.xp6(1),e.hij("Add Licenses Now ",t.no_of_license*t.data.plan.price-t.discount,"")}}function Ie(i,s){if(1&i&&(e.TgZ(0,"div",36),e.YNc(1,ke,2,0,"a",37),e.YNc(2,Ae,2,0,"a",37),e.YNc(3,Ce,2,0,"button",38),e.YNc(4,Ue,2,1,"button",38),e.qZA()),2&i){const t=e.oxw();e.xp6(1),e.Q6J("ngIf",t.goToManageLicensePage),e.xp6(1),e.Q6J("ngIf",!t.goToManageLicensePage),e.xp6(1),e.Q6J("ngIf",!t.discount),e.xp6(1),e.Q6J("ngIf",t.discount)}}let C=(()=>{class i extends b.u{constructor(t,n){super(),this._subscriptionService=t,this._helperService=n,this.data={},this.no_of_license=1,this.braintreeInstance=null,this.subscription=null,this.discount=0,this.couponName="",this.ownerLicenses=0,this.totalAmount=0,this.requiredLicenses=1}setInputData(t){this.data=t,this.ownerLicenses=t.licensesCount,this.requiredLicenses=t.requiredLicenses,this.no_of_license=t.requiredLicenses}ngOnInit(){this.getClientTokenAndPlan(),this._subscriptionService.get().subscribe(t=>{this.subscription=t.data,this.totalAmount=parseInt(this.subscription.subscription.next_bill_amount)}),this._helperService.unBlockUI()}getDiscountValue(t){this.discount=t.amount,this.couponName=t.name}getClientTokenAndPlan(){this._subscriptionService.getClientTokenAndSubscriptionPlan().subscribe(t=>{t&&!t.error?(this.data=t,this.initBrainTree(t.token)):(this._helperService.errorMessage(t.message),this._helperService.navigateToUrl("/team-docs"))})}initBrainTree(t){t&&xe.create({authorization:t,container:"#dropin-container",paypal:{flow:"vault"}},(n,a)=>{n?console.error(n):this.braintreeInstance=a})}getBraintreePaymentMethodToken(){var t={error:!1,payload_token:null},n=this;return new Promise((a,r)=>{n.braintreeInstance.requestPaymentMethod((c,l)=>{c?(t.error=!0,console.error(c)):t.payload_token=l.nonce,a(t)})})}submitHandler(t){var n=this;return(0,fe.Z)(function*(){var a=null;if(n.data.token){let r=yield n.getBraintreePaymentMethodToken();if(r.error)return n._helperService.errorMessage(r.error_message),!1;a=r.payload_token}n._helperService.blockUI(),n._subscriptionService.upgradeTeamDocs({token:a,trial_used:n.data.trial_used,no_of_license:t.value.no_of_license}).subscribe(r=>{r&&!r.error?(n._helperService.successMessage("New Licenses added."),n._helperService.unBlockUI(),n.close(!0)):(n._helperService.errorMessage(r.message),n._helperService.unBlockUI())})})()}subscriptionPriceAfterUpgrade(){return parseInt(this.subscription.subscription.next_bill_amount)+this.no_of_license*this.data.plan.price}upgradedLicensePrice_back(){let t=+this.data.members_count*+this.data.plan.price,n=t+this.no_of_license*this.data.plan.price,a=v(this.data.subscription.billing_period_start_date),r=v(this.data.subscription.billing_period_end_date),c=Math.abs(a.diff(r,"days"))+1;return((Math.abs(v().diff(r,"days"))+1)/c*(n-t)).toFixed(2)}apply(){this.close()}static#e=this.\u0275fac=function(n){return new(n||i)(e.Y36(be.F),e.Y36(d.W_))};static#t=this.\u0275cmp=e.Xpm({type:i,selectors:[["app-upgrade-licenses"]],features:[e.qOj],decls:15,vars:5,consts:[[1,"modal","in","p-4","overflow-auto"],[1,"modal-dialog","max-w-2xl"],[1,"modal-header","px-4","py-2","bg-primary","text-white","text-sm","leading-6","relative","flex","justify-between"],[1,"fa","fa-times","leading-6","opacity-50","cursor-pointer","modalclose",3,"click"],[1,"modal-body","p-4","pt-3"],["class","mt-20 p-25p text-center",4,"ngIf"],[1,"flex","flex-wrap",3,"ngClass"],[3,"ngSubmit"],["subscriptionForm","ngForm"],["class","mb-3",4,"ngIf"],[1,"mb-3",3,"ngClass"],["id","dropin-container"],["class","flex flex-wrap w-full justify-center text-center",4,"ngIf"],[1,"mt-20","p-25p","text-center"],["aria-hidden","true",1,"fa","fa-spinner","fa-spin","text-primary","font-size-50","fa-2x"],[1,"mb-3"],[1,"text-center","mb-3"],[1,"text-success","flex","items-center","justify-center","md:leading-8"],[1,"text-xl","md:text-2xl","font-extrabold"],[1,"md:text-lg","font-medium"],[1,"px-2","py-1","leading-5","mb-3","text-danger","bg-danger","bg-opacity-10","border","border-danger","border-opacity-25","text-xs","rounded"],[1,"p-3","border","border-dashed","border-gray-light","bg-smoke-white","bg-opacity-25","mt-3","rounded","relative"],[1,"text-sm","text-gray-300","font-normal","leading-5"],["class","flex flex-wrap items-center pb-3",4,"ngIf"],[1,"flex","flex-wrap","items-center","py-2","border-t","border-gray-light","border-opacity-50"],[1,"w-10/12","text-gray-600"],[1,"w-2/12","text-right"],["name","no_of_license","type","number","autofocus","",1,"border","rounded","border-opacity-50","border-primary","text-sm","w-full","sm:w-17","px-1","py-1","text-gray-300","focus:outline-none","focus:shadow-outline","focus:border-primary","placeholder-gray-light",3,"value","ngModel","min","ngModelChange"],["class","flex flex-wrap items-center pt-3 border-t border-gray-light border-opacity-50 text-gray-300 font-bold",4,"ngIf"],["class","bg-gray-light bg-opacity-10 text-gray-300 italic text-xs px-2 py-1 border-l-2 border-gray-900 mt-3",4,"ngIf"],[1,"flex","flex-wrap","items-center","pb-3"],[1,"w-2/12"],[1,"w-full","sm:w-17","sm:ml-auto"],[1,"flex","flex-wrap","items-center","pt-3","border-t","border-gray-light","border-opacity-50","text-gray-300","font-bold"],[1,"w-10/12"],[1,"bg-gray-light","bg-opacity-10","text-gray-300","italic","text-xs","px-2","py-1","border-l-2","border-gray-900","mt-3"],[1,"flex","flex-wrap","w-full","justify-center","text-center"],["href","javascript:void(0);","class","bg-warning rounded px-4 py-1.5 mx-2 inline-block text-white text-xs tracking-wider font-medium focus:outline-none hover:shadow-btn transition-all duration-300",3,"click",4,"ngIf"],["class","bg-success rounded px-4 py-1.5 mx-2 inline-block text-white text-xs tracking-wider font-medium focus:outline-none hover:shadow-btn transition-all duration-300",4,"ngIf"],["href","javascript:void(0);",1,"bg-warning","rounded","px-4","py-1.5","mx-2","inline-block","text-white","text-xs","tracking-wider","font-medium","focus:outline-none","hover:shadow-btn","transition-all","duration-300",3,"click"],[1,"bg-success","rounded","px-4","py-1.5","mx-2","inline-block","text-white","text-xs","tracking-wider","font-medium","focus:outline-none","hover:shadow-btn","transition-all","duration-300"]],template:function(n,a){if(1&n){const r=e.EpF();e.TgZ(0,"div",0)(1,"div",1)(2,"div",2)(3,"span"),e._uU(4," Upgrade licenses "),e.qZA(),e.TgZ(5,"i",3),e.NdJ("click",function(){return a.apply()}),e.qZA()(),e.TgZ(6,"div",4),e.YNc(7,ve,2,0,"div",5),e.TgZ(8,"div",6)(9,"form",7,8),e.NdJ("ngSubmit",function(){e.CHM(r);const l=e.MAs(10);return e.KtG(a.submitHandler(l))}),e.YNc(11,Ze,19,8,"div",9),e.TgZ(12,"div",10),e._UZ(13,"div",11),e.qZA(),e.YNc(14,Ie,5,4,"div",12),e.qZA()()()()()}2&n&&(e.xp6(7),e.Q6J("ngIf",!a.subscription||a.subscription&&!a.subscription.subscription.on_trial&&!a.braintreeInstance),e.xp6(1),e.Q6J("ngClass",a.subscription&&a.subscription.subscription.on_trial&&a.data&&a.data.plan||a.subscription&&!a.subscription.subscription.on_trial&&a.braintreeInstance?"visible":"invisible"),e.xp6(3),e.Q6J("ngIf",a.data&&a.data.plan),e.xp6(1),e.Q6J("ngClass",a.subscription&&!a.subscription.subscription.on_trial&&a.braintreeInstance?"visible":"invisible"),e.xp6(2),e.Q6J("ngIf",a.subscription&&a.subscription.subscription.on_trial&&a.data&&a.data.plan||a.subscription&&!a.subscription.subscription.on_trial&&a.braintreeInstance))},dependencies:[p.mk,p.O5,o._Y,o.Fj,o.wV,o.JJ,o.JL,o.qQ,o.On,o.F],encapsulation:2})}return i})();var U=m(638);function Se(i,s){1&i&&(e.TgZ(0,"div",10),e._UZ(1,"i",11),e.qZA())}function Me(i,s){1&i&&e._UZ(0,"img",55)}
1function qe(i,s){if(1&i&&e._UZ(0,"img",24),2&i){const t=e.oxw().$implicit;e.Q6J("src",t.profile_image_url,e.LSH)}}function Je(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"li",22)(1,"div",47),e.YNc(2,Me,1,0,"img",48),e.YNc(3,qe,1,1,"img",49),e.TgZ(4,"div",25)(5,"div",26),e._uU(6),e.TgZ(7,"span",27),e._uU(8),e.TgZ(9,"img",50),e.NdJ("click",function(){const r=e.CHM(t).$implicit,c=e.oxw(2);return e.KtG(c.editMember(r))}),e.qZA(),e._uU(10,") "),e.qZA()(),e.TgZ(11,"small",51),e._uU(12),e.qZA()()(),e.TgZ(13,"div",52)(14,"a",53),e.NdJ("click",function(){const r=e.CHM(t).$implicit,c=e.oxw(2);return e.KtG(c.deleteMember(r))}),e._UZ(15,"img",54),e.qZA()()()}if(2&i){const t=s.$implicit;e.xp6(2),e.Q6J("ngIf",!t.profile_image_url),e.xp6(1),e.Q6J("ngIf",t.profile_image_url),e.xp6(3),e.hij(" "," "==t.name?"--":t.name," "),e.xp6(2),e.hij(" (",t.role_name," "),e.xp6(4),e.hij(" ",t.email," ")}}function Ne(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"div",34)(1,"app-combo-box",56),e.NdJ("valueChange",function(a){e.CHM(t);const r=e.oxw(2);return e.KtG(r.data.selectedEmail=a)})("optionsChange",function(a){e.CHM(t);const r=e.oxw(2);return e.KtG(r.data.comboBoxInputData=a)}),e.qZA()()}if(2&i){const t=e.oxw(2);e.xp6(1),e.Q6J("DefaultText",t.comboPlaceHolder)("value",t.data.selectedEmail)("required",0)("options",t.data.comboBoxInputData)}}function Le(i,s){if(1&i&&(e.TgZ(0,"option",57),e._uU(1),e.qZA()),2&i){const t=s.$implicit;e.Q6J("value",t.key),e.xp6(1),e.hij(" ",t.value," ")}}function Qe(i,s){1&i&&(e.TgZ(0,"div",58),e._UZ(1,"i",59),e._uU(2," Inviting a team member will send an email request for them to join the team. NOTE: They are not an active member of the team until they accept the request. "),e.qZA())}function De(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"div",12)(1,"div",13)(2,"div",14)(3,"div",15)(4,"label",16),e._uU(5,"Team Name"),e.qZA(),e.TgZ(6,"a",17),e._uU(7," Manage Team Roster "),e.qZA()(),e.TgZ(8,"div",18)(9,"input",19),e.NdJ("ngModelChange",function(a){e.CHM(t);const r=e.oxw();return e.KtG(r.data.teamName=a)}),e.qZA()(),e.TgZ(10,"div",20)(11,"ul",21)(12,"li",22)(13,"div",23),e._UZ(14,"img",24),e.TgZ(15,"div",25)(16,"div",26),e._uU(17),e.TgZ(18,"span",27),e._uU(19," (Owner) "),e.qZA()(),e.TgZ(20,"small",28),e._uU(21),e.qZA()()()(),e.YNc(22,Je,16,5,"li",29),e.qZA()(),e.TgZ(23,"div",30)(24,"label",31),e._uU(25,"Invite Team Members"),e.qZA(),e.TgZ(26,"div",32),e.YNc(27,Ne,2,4,"div",33),e.TgZ(28,"div",34)(29,"select",35),e.NdJ("ngModelChange",function(a){e.CHM(t);const r=e.oxw();return e.KtG(r.data.selectedRole=a)}),e.TgZ(30,"option",36),e._uU(31,"Select Role"),e.qZA(),e.YNc(32,Le,2,2,"option",37),e.ALo(33,"keyvalue"),e.qZA()(),e.TgZ(34,"button",38),e.NdJ("click",function(){e.CHM(t);const a=e.oxw();return e.KtG(a.addMember())}),e._uU(35," Invite Member "),e.qZA()(),e.TgZ(36,"div",39)(37,"label",40),e._uU(38,"Role Permissions:"),e.qZA(),e.TgZ(39,"ul",41)(40,"li",42)(41,"span",43),e._uU(42,"Manager: "),e.qZA(),e._uU(43,"Add/remove members, add/edit/delete content"),e.qZA(),e.TgZ(44,"li",42)(45,"span",43),e._uU(46,"Content Manager: "),e.qZA(),e._uU(47,"Add/edit/delete content "),e.qZA(),e.TgZ(48,"li",42)(49,"span",43),e._uU(50,"Contributor: "),e.qZA(),e._uU(51,"Add/edit content"),e.qZA()()()()(),e.YNc(52,Qe,3,0,"div",44),e.TgZ(53,"div",45)(54,"button",46),e.NdJ("click",function(){e.CHM(t);const a=e.oxw();return e.KtG(a.submitHandler())}),e._uU(55," Create Team "),e.qZA()()()()}if(2&i){const t=e.oxw();e.xp6(6),e.Q6J("routerLink","/team-docs/licenses"),e.xp6(3),e.Q6J("value",t.data.teamName)("ngModel",t.data.teamName),e.xp6(5),e.Q6J("src",t.data.owner.profile_image_url,e.LSH),e.xp6(3),e.hij(" ",t.data.owner.name," "),e.xp6(4),e.Oqu(t.data.owner.email),e.xp6(1),e.Q6J("ngForOf",t.members),e.xp6(5),e.Q6J("ngIf",t.showCombo),e.xp6(2),e.Q6J("ngModel",t.data.selectedRole),e.xp6(3),e.Q6J("ngForOf",e.lcZ(33,11,t.roles)),e.xp6(20),e.Q6J("ngIf",t.data.licensesWithoutOwner&&t.data.licensesWithoutOwner.length>0)}}let je=(()=>{class i{constructor(t,n,a,r){this.teamDocsService=t,this.helperService=n,this.dialog=a,this.authService=r,this.data={},this.member_counter=0,this.members=[],this.roles=[],this.comboBoxInput=null,this.showCombo=!1,this.licenses=null,this.comboPlaceHolder="Please enter a Gmail or Google Worksp
1ace email address"}ngOnInit(){this.data={...this.data,teamName:"",selectedEmail:"",selectedRole:""},this.loadRoles(),this.loadLicenses()}loadRoles(){this.teamDocsService.loadRoles().subscribe(t=>this.roles=t)}loadLicenses(){this.teamDocsService.licenses().subscribe(t=>{let n=(0,u.find)(t.data.licenses,function(r){return r.is_owner}),a=(0,u.filter)(t.data.licenses,function(r){return!r.is_owner});this.licenses=a.map(function(r){return r.email}),this.comboBoxInput=JSON.stringify(a.map(function(r){return r.email})),this.data={...this.data,...t.data,owner:n,licensesWithoutOwner:a,comboBoxInputData:this.comboBoxInput},this.showCombo=!0})}addMember(){let t=this.data.selectedEmail,n=this.data.selectedRole;if(!t||!n)return void this.helperService.errorMessage("Please provide all fields.");if(!/^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(t))return void this.helperService.errorMessage("Please provide a valid email address.");if((0,u.find)(this.members,l=>l.email==t))return void this.helperService.errorMessage("You have already added this team member.");if(t==this.data.owner.email)return void this.helperService.errorMessage("You can't add owner email as team member. This email is already a part of the team.");let r=(0,u.find)(this.data.licenses,l=>l.email==t);this.members.push({index:this.member_counter++,name:r?r.name:"--",email:t,role_name:(0,u.find)(this.roles,(l,x)=>x==n),role:n,profile_image_url:r?r.profile_image_url:"assets/images/default-user-profile/gray.svg"});var c=[];c="object"==typeof this.comboBoxInput?this.comboBoxInput:JSON.parse(this.comboBoxInput),this.comboBoxInput=c.filter(function(l){return l!==t}),this.data={...this.data,selectedEmail:"",selectedRole:"",comboBoxInputData:this.comboBoxInput},this.showCombo=!1,this.helperService.delay(200).then(()=>{this.showCombo=!0})}editMember(t){this.dialog.open(A,{width:"500px",disableClose:!0,panelClass:"material-modal-panel",data:{member:t,roles:this.roles}}).afterClosed().subscribe(a=>{a&&this.members.splice(this.members.indexOf(t),1,a)})}deleteMember(t){this.member_counter--,this.members.splice(this.members.indexOf(t),1);var n=[];n="object"==typeof this.comboBoxInput?this.comboBoxInput:JSON.parse(this.comboBoxInput),-1!=this.licenses.indexOf(t.email)&&n.push(t.email),this.comboBoxInput=n,this.data={...this.data,selectedEmail:"",selectedRole:"",comboBoxInputData:this.comboBoxInput},this.showCombo=!1,this.helperService.delay(200).then(()=>{this.showCombo=!0})}back(){this.helperService.jumpToPreviousPage()}submitHandler(){this.helperService.blockUI(),this.teamDocsService.addLicenseMembers({members:this.members}).subscribe(n=>{0==n.error?this.createTeam():1==n.error&&n.type&&"ALL_LICENSES_USED"==n.type?this.openUpgradeLicenseModal(n):this.helperService.errorMessage(n.message),this.helperService.unBlockUI()})}createTeam(){this.helperService.blockUI(),this.teamDocsService.create({teamName:this.data.teamName,members:this.members}).subscribe(n=>{this.helperService.unBlockUI(),n&&1==n.error?(this.helperService.navigateToUrl(n.type&&"NO_TEAM_NAME"==n.type?"/team-docs/teams/create":n.type&&"NO_TEAM_DOC_SUBSCRIPTION"==n.type||n.type&&"NO_TEAM_DOC_LICENSE"==n.type?"/team-docs":"/team-docs/teams"),this.helperService.errorMessage(n.message)):(this.helperService.navigateToUrl("/team-docs/teams/"+n.team_uid),this.helperService.successMessage("Team created."))})}openUpgradeLicenseModal(t){this.helperService.openModal(C,{licensesCount:t.licensesCount,requiredLicenses:t.requiredLicenses}).output().subscribe(a=>{a&&this.submitHandler()})}setPlaceHolderText(){this.data={...this.data,selectedEmail:"Please enter a Gmail or Google Workspace email address",selectedRole:""}}clearPlaceHolderText(){this.data={...this.data,selectedEmail:"",selectedRole:""}}static#e=this.\u0275fac=function(n){return new(n||i)(e.Y36(g.e),e.Y36(d.W_),e.Y36(h.on),e.Y36(d.e8))};static#t=this.\u0275cmp=e.Xpm({type:i,selectors:[["app-create-team"]],decls:12,vars:2,consts:[[1,"bg-white"],[1,"container","mx-auto"],[1,"flex","sm:items-center","px-4","py-3"],[1,"pr-2"],["href","javascript:void(0);",1,"text-gray-300",3,"click"],[1,"fa","fa-angle-left","font-bold","text-3xl"],[1,"text-gray-300","font-medium","flex-1","text-center","text-sm","sm:text-base"],[1,"container","mx-auto","px-4","py-4","min-h-90-vh","lg:min-h-70-vh","xl:min-h-screen","mb-2
10"],["class","text-center",4,"ngIf","ngIfElse"],["hasLicenses",""],[1,"text-center"],["aria-hidden","true",1,"fa","fa-spinner","fa-2x","fa-spin","text-primary","font-size-50"],[1,"flex","flex-wrap"],[1,"w-full","md:w-10/12","mx-auto"],[1,"bg-white","shadow-card","p-3","sm:p-4","mb-4"],[1,"-mt-2","pb-1","clearfix"],[1,"text-gray-600","text-sm"],["href","javascript:void(0);",1,"text-xs","text-primary","underline","float-right",3,"routerLink"],[1,"pb-4"],["placeholder","Enter Team Name","autofocus","",1,"border","border-gray-light","px-2","py-1","h-10","text-sm","leading-4","font-normal","text-gray-300","placeholder-gray-light","rounded","w-full","focus:outline-none","focus:border-primary",3,"value","ngModel","ngModelChange"],[1,"bg-smoke-white","bg-opacity-75","border","border-gray-light","border-opacity-50","rounded","px-3"],[1,"last-child-style-none"],[1,"flex","flex-wrap","items-center","py-3","border-b","border-light"],[1,"w-full","flex","items-start"],[1,"inline-block","w-7","h-7","rounded-full","mt-0.5",3,"src"],[1,"ml-2"],[1,"text-gray-300","text-sm","leading-4","sm:leading-5","flex","flex-wrap"],[1,"text-gray-900","tracking-normal","ml-0.5"],[1,"font-normal","text-gray-900","leading-4","break-all"],["class","flex flex-wrap items-center py-3 border-b border-light",4,"ngFor","ngForOf"],[1,"border","border-dashed","border-gray-light","border-opacity-50","rounded","p-3","pt-1.5","mt-4"],[1,"block","text-gray-600","text-sm","mb-1"],[1,"flex","flex-wrap","gap-3","sm:gap-0"],["class","w-full sm:w-5/12 sm:pr-3",4,"ngIf"],[1,"w-full","sm:w-5/12","sm:pr-3"],[1,"appearance-none","relative","block","w-full","text-xs","rounded","px-2","py-1","h-9","bg-white","border","border-gray-light","focus:border-primary","focus:outline-none","select-aarow-change","text-gray-600",3,"ngModel","ngModelChange"],["value",""],[3,"value",4,"ngFor","ngForOf"],[1,"bg-transparent","sm:bg-primary","rounded","w-full","sm:w-2/12","text-right","sm:text-center","leading-4","inline-block","text-primary","sm:text-white","text-xs","focus:outline-none","sm:hover:shadow-btn","transition-all","duration-300","underline","sm:no-underline","p-1",3,"click"],[1,"px-2","sm:px-3","py-2","text-gray-600","bg-gray-light","bg-opacity-10","rounded","mt-3"],[1,"block","font-medium","text-sm","mb-0.5"],[1,"list-disc","text-xs","pl-4"],[1,""],[1,"text-gray-300"],["class","px-3 tracking-wide py-2 text-primary bg-primary bg-opacity-10 border border-primary border-opacity-25 text-xs rounded mt-4",4,"ngIf"],[1,"flex","flex-wrap","w-full","gap-4","justify-center","text-center","mt-4"],[1,"bg-success","rounded","px-6","py-2","inline-block","text-white","text-sm","tracking-wider","font-medium","focus:outline-none","hover:shadow-btn","transition-all","duration-300",3,"click"],[1,"w-11/12","flex","items-start"],["class","inline-block w-7 h-7 rounded-full mt-0.5","src","assets/images/default-user-profile/gray.svg",4,"ngIf"],["class","inline-block w-7 h-7 rounded-full mt-0.5",3,"src",4,"ngIf"],["src","assets/images/icon-pencil.svg",1,"inline-block","w-3","cursor-pointer",3,"click"],[1,"text-gray-900","leading-4"],[1,"w-1/12","text-right"],["href","javascript:void(0);",3,"click"],["alt","Delete","src","assets/images/icon-delete-danger.svg",1,"inline-block","w-3"],["src","assets/images/default-user-profile/gray.svg",1,"inline-block","w-7","h-7","rounded-full","mt-0.5"],[3,"DefaultText","value","required","options","valueChange","optionsChange"],[3,"value"],[1,"px-3","tracking-wide","py-2","text-primary","bg-primary","bg-opacity-10","border","border-primary","border-opacity-25","text-xs","rounded","mt-4"],[1,"fa","fa-info-circle","text-sm"]],template:function(n,a){if(1&n&&(e.TgZ(0,"div",0)(1,"div",1)(2,"div",2)(3,"div",3)(4,"a",4),e.NdJ("click",function(){return a.back()}),e._UZ(5,"i",5),e.qZA()(),e.TgZ(6,"div",6),e._uU(7," Create New Team "),e.qZA()()()(),e.TgZ(8,"div",7),e.YNc(9,Se,2,0,"div",8),e.YNc(10,De,56,13,"ng-template",null,9,e.W1O),e.qZA()),2&n){const r=e.MAs(11);e.xp6(9),e.Q6J("ngIf",!a.data.licenses)("ngIfElse",r)}},dependencies:[p.sg,p.O5,_.rH,o.YN,o.Kr,o.Fj,o.EJ,o.JJ,o.On,U.o,p.Nd],encapsulation:2})}return i})();var I=m(1861);let Ye=(()=>{class i extends b.u{constructor(t,n){super(),this._helper=t,this._teamDocs=n,this.data={},this.team=null}setInputData(t){this.data=t}ngOnInit(){this.team=this.data.team?this.data.team:null}submitHandler(t){this.close(),this._helper.blockUI("Updating ...."),this._teamDocs.renameTeam(this.team.uid,{team_name:t.value.team_name}).subscribe(n=>{n&&n.error?(this._helper.errorMessage(n.message),this._helper.unBlockUI()):(this._helper.successMessage("Team updated."),this._teamDocs.updateObserver(n.data),this._helper.unBlockUI())})}static#e=this.\u0275fac=function(n){return new(n||i)(e.Y36(I.W),e.Y36(g.e))};static#t=this.\u0275cmp=e.Xpm({type:i,selectors:[["app-rename-team"]],features:[e.qOj],decls:13,vars:2,consts:[[1,"modal","in","p-4"],[1,"modal-dialog","w-full","sm:w-6/12","md:w-4/12","animated-from-top"],[1,"modal-header","px-4","py-3","bg-primary","text-white","relative","flex","justify-between"],[1,"fa","fa-times","leading-6","opacity-50","cursor-pointer","modalclose",3,"click"],[1,"modal-body","p-4"],[3,"ngSubmit"],["renameTeamForm","ngForm"],["type","text","placeholder","Enter Team Name","name","team_name","required","true",1,"bg-white","border-b","border-gray-900","text-gray-300","focus:border-primary","w-full","text-gray-300","focus:outline-none","focus:shadow-none","placeholder-gray-light","text-sm","py-2","transition-all","duration-300",3,"value","ngModel"],[1,"text-right","pt-4"],["type","submit",1,"bg-success","px-4","py-2","text-white","rounded","text-sm","tracking-wide","font-medium","focus:outline-none","hover:shadow-btn","transition-all","duration-300"]],template:function(n,a){if(1&n){const r=e.EpF();e.TgZ(0,"div",0)(1,"div",1)(2,"div",2)(3,"span"),e._uU(4,"Rename Team"),e.qZA(),e.TgZ(5,"i",3),e.NdJ("click",function(){return a.close()}),e.qZA()(),e.TgZ(6,"div",4)(7,"form",5,6),e.NdJ("ngSubmit",function(){e.CHM(r);const l=e.MAs(8);return e.KtG(a.submitHandler(l))}
1),e._UZ(9,"input",7),e.TgZ(10,"div",8)(11,"button",9),e._uU(12," Update "),e.qZA()()()()()()}2&n&&(e.xp6(9),e.Q6J("value",a.team.name)("ngModel",a.team.name))},dependencies:[o._Y,o.Fj,o.JJ,o.JL,o.Q7,o.On,o.F],encapsulation:2})}return i})();function Ee(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"div",4)(1,"div",5)(2,"div",6)(3,"div",7)(4,"a",8),e.NdJ("click",function(){e.CHM(t);const a=e.oxw();return e.KtG(a.back())}),e._UZ(5,"i",9),e.qZA()(),e.TgZ(6,"div",10),e._uU(7),e.qZA()()()()}if(2&i){const t=e.oxw();e.xp6(7),e.hij(" ",t.data.team.name," ")}}function Oe(i,s){1&i&&(e.TgZ(0,"div",11),e._UZ(1,"i",12),e.qZA())}function Fe(i,s){1&i&&(e.TgZ(0,"div",43),e._UZ(1,"img",44),e.qZA())}function Be(i,s){1&i&&(e.TgZ(0,"div",47),e._UZ(1,"i",48),e._uU(2," Accepting this team invitation will grant you access to the team's Templates and Projects. NOTE: Your personal Google Drive documents are still private and are not shared. You can switch between teams and your personal documents at any time. "),e.qZA())}function He(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"li",54)(1,"a",56),e.NdJ("click",function(){e.CHM(t);const a=e.oxw(4);return e.KtG(a.setMyDrive())}
1),e._UZ(2,"img",57)(3,"img",58),e._uU(4," Active "),e.qZA()()}}function Re(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"li",54)(1,"a",59),e.NdJ("click",function(){e.CHM(t);const a=e.oxw(4);return e.KtG(a.setDefault())}),e._uU(2," Set as Active "),e.qZA()()}}function Ge(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"li",54)(1,"a",60),e.NdJ("click",function(){e.CHM(t);const a=e.oxw(4);return e.KtG(a.rename())}),e._uU(2," Rename Team "),e.qZA()()}}function Ve(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"li",54)(1,"a",61),e.NdJ("click",function(){e.CHM(t);const a=e.oxw(4);return e.KtG(a.deactivate())}),e._uU(2," Deactivate Team "),e.qZA()()}}function Pe(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"li",54)(1,"a",61),e.NdJ("click",function(){e.CHM(t);const a=e.oxw(4);return e.KtG(a.leave())}),e._uU(2," Leave Team "),e.qZA()()}}function Ke(i,s){1&i&&(e.TgZ(0,"li",54)(1,"a",55),e._uU(2," Manage Team Roster "),e.qZA()()),2&i&&(e.xp6(1),e.Q6J("routerLink","/team-docs/licenses"))}function We(i,s){if(1&i&&(e.TgZ(0,"div",49)(1,"a",50),e._uU(2," Actions "),e._UZ(3,"i",51),e.qZA(),e.TgZ(4,"ul",52),e.YNc(5,He,5,0,"li",53),e.YNc(6,Re,3,0,"li",53),e.YNc(7,Ge,3,0,"li",53),e.YNc(8,Ve,3,0,"li",53),e.YNc(9,Pe,3,0,"li",53),e.YNc(10,Ke,3,1,"li",53),e.TgZ(11,"li",54)(12,"a",55),e._uU(13," Activity "),e.qZA()()()()),2&i){const t=e.oxw(3);e.xp6(5),e.Q6J("ngIf",t.data.team.is_default),e.xp6(1),e.Q6J("ngIf",!t.data.team.is_default),e.xp6(1),e.Q6J("ngIf",t.data.team.permission.RENAME_TEAM),e.xp6(1),e.Q6J("ngIf",t.data.team.owner.id==t.authService.user.id),e.xp6(1),e.Q6J("ngIf",t.data.team.owner.id!=t.authService.user.id),e.xp6(1),e.Q6J("ngIf",t.data.team.owner.uid==t.authService.user.uid),e.xp6(2),e.Q6J("routerLink","/team-docs/teams/"+t.data.team.uid+"/activities")}}function $e(i,s){if(1&i&&(e.ynx(0),e.YNc(1,Be,3,0,"div",45),e.YNc(2,We,14,7,"div",46),e.BQk()),2&i){const t=e.oxw(2);e.xp6(1),e.Q6J("ngIf",t.data.team.has_pending_invitation),e.xp6(1),e.Q6J("ngIf",!t.data.team.has_pending_invitation)}}function ze(i,s){1&i&&(e.TgZ(0,"span"),e._uU(1," To continue using Team Docs, please "),e.TgZ(2,"a",65),e._uU(3,"subscribe"),e.qZA(),e._uU(4,". "),e.qZA()),2&i&&(e.xp6(2),e.Q6J("routerLink","/subscription/team-docs"))}function Xe(i,s){1&i&&e._uU(0,"All Team files are retained on the Team Owner's shared Google Drive.")}function et(i,s){if(1&i&&(e.TgZ(0,"p",62),e._UZ(1,"i",63),e._uU(2," This Team Docs subscription has been canceled or expired. "),e.YNc(3,ze,5,1,"span",20),e.YNc(4,Xe,1,0,"ng-template",null,64,e.W1O),e.qZA()),2&i){const t=e.MAs(5),n=e.oxw(2);e.xp6(3),e.Q6J("ngIf",n.isOwner())("ngIfElse",t)}}function tt(i,s){if(1&i&&(e.TgZ(0,"div",70),e._UZ(1,"img",71),e.TgZ(2,"div",72)(3,"div",73),e._uU(4),e.TgZ(5,"span",74),e._uU(6," (Owner) "),e.qZA()(),e.TgZ(7,"small",75),e._uU(8),e.qZA()()()),2&i){const t=e.oxw().$implicit;e.xp6(1),e.Q6J("src",t.profile_image_url,e.LSH),e.xp6(3),e.hij(" ",t.name," "),e.xp6(4),e.Oqu(t.email)}}function it(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"img",77),e.NdJ("click",function(){e.CHM(t);const a=e.oxw(2).$implicit,r=e.oxw(2);return e.KtG(r.editMember(a))}),e.qZA()}}function nt(i,s){if(1&i&&(e.TgZ(0,"div",70),e._UZ(1,"img",71),e.TgZ(2,"div",72)(3,"div",73),e._uU(4),e.TgZ(5,"span",74),e._uU(6),e.YNc(7,it,1,0,"img",76),e._uU(8,") "),e.qZA()(),e.TgZ(9,"small",75),e._uU(10),e.qZA()()()),2&i){const t=e.oxw().$implicit,n=e.oxw(2);e.xp6(1),e.Q6J("src",t.profile_image_url,e.LSH),e.xp6(3),e.hij(" "," "!=t.name?t.name:"--"," "),e.xp6(2),e.hij(" (",t.role,""),e.xp6(1),e.Q6J("ngIf",n.data.team.owner.id==t.id||!n.data.team.has_pending_invitation&&n.authService.user.id!=t.id&&n.data.team.permission&&n.data.team.permission.EDIT_TEAM_MEMBER&&!n.data.team.has_subscription_expired),e.xp6(3),e.Oqu(t.email)}}function at(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"div",78)(1,"a",79),e.NdJ("click",function(){e.CHM(t);const a=e.oxw().$implicit,r=e.oxw(2);return e.KtG(r.deleteTeamUser(a))}),e._UZ(2,"img",80),e.qZA()()}}function rt(i,s){if(1&i&&(e.TgZ(0,"li",66),e.YNc(1,tt,9,3,"div",67),e.YNc(2,nt,11,5,"ng-template",null,68,e.W1O),e.YNc(4,at,3,0,"div",69),e.qZA()),2&i){const t=s.$implicit,n=e.MAs(3),a=e.oxw(2);e.xp6(1),e.Q6J("ngIf",t.id==a.data.team.owner.id)("ngIfElse",n),e.xp6(3),e.Q6J("ngIf",a.authService.user.id!=t.id&&!a.data.team.has_pending_invitation&&t.id!=a.data.team.owner.id&&a.data.team.permission&&a.data.team.permission.EDIT_TEAM_MEMBER&&!a.data.team.has_subscription_expired)}}
1function st(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"div",78)(1,"a",79),e.NdJ("click",function(){e.CHM(t);const a=e.oxw().$implicit,r=e.oxw(3);return e.KtG(r.deleteTeamUser(a))}),e._UZ(2,"img",80),e.qZA()()}}function ot(i,s){if(1&i&&(e.TgZ(0,"li",66)(1,"div",70),e._UZ(2,"img",71),e.TgZ(3,"div",72)(4,"div",73),e._uU(5),e.qZA(),e.TgZ(6,"small",82),e._uU(7),e.qZA()()(),e.YNc(8,st,3,0,"div",69),e.qZA()),2&i){const t=s.$implicit,n=e.oxw(3);e.xp6(2),e.Q6J("src",t.profile_image_url,e.LSH),e.xp6(3),e.hij(" ",t.email," "),e.xp6(2),e.hij(" ",t.role," "),e.xp6(1),e.Q6J("ngIf",!n.data.team.has_pending_invitation&&n.data.team.permission&&n.data.team.permission.EDIT_TEAM_MEMBER&&!n.data.team.has_subscription_expired)}}function ct(i,s){if(1&i&&(e.ynx(0),e.TgZ(1,"div",81),e._uU(2," Pending Invitations "),e.qZA(),e.TgZ(3,"div",24)(4,"ul",25),e.YNc(5,ot,9,4,"li",26),e.qZA()(),e.BQk()),2&i){const t=e.oxw(2);e.xp6(5),e.Q6J("ngForOf",t.data.team.pendingUsers)}}function lt(i,s){if(1&i&&(e.TgZ(0,"option",92),e._uU(1),e.qZA()),2&i){const t=s.$implicit;e.Q6J("value",t.email),e.xp6(1),e.hij(" ",t.email," ")}}function mt(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"div",87)(1,"select",88),e.NdJ("ngModelChange",function(a){e.CHM(t);const r=e.oxw(4);return e.KtG(r.selectedMemberEmail=a)}),e.TgZ(2,"option",89),e._uU(3,"Select Licenses"),e.qZA(),e.YNc(4,lt,2,2,"option",90),e.qZA()()}if(2&i){const t=e.oxw(4);e.xp6(1),e.Q6J("ngModel",t.selectedMemberEmail),e.xp6(3),e.Q6J("ngForOf",t.data.team.unassignedLicenses)}}function dt(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"div",87)(1,"app-combo-box",93),e.NdJ("optionsChange",function(a){e.CHM(t);const r=e.oxw(4);return e.KtG(r.data.comboBoxInputData=a)})("change",function(a){e.CHM(t);const r=e.oxw(4);return e.KtG(r.handleComboxboxOutput(a,r.member))}),e.qZA()()}if(2&i){const t=e.oxw(4);e.xp6(1),e.Q6J("DefaultText",t.comboPlaceHolder)("required",0)("value","")("options",t.data.comboBoxInputData)}}function pt(i,s){if(1&i&&(e.TgZ(0,"option",92),e._uU(1),e.qZA()),2&i){const t=s.$implicit;e.Q6J("value",t.key),e.xp6(1),e.hij(" ",t.value," ")}}function _t(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"button",94),e.NdJ("click",function(){e.CHM(t);const a=e.oxw(4);return e.KtG(a.addMember("owner"))}),e._uU(1," Invite Member "),e.qZA()}}function ut(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"button",94),e.NdJ("click",function(){e.CHM(t);const a=e.oxw(4);return e.KtG(a.addMember("manager"))}),e._uU(1," Invite Member "),e.qZA()}}function gt(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"div")(1,"label",83),e._uU(2,"Invite Team Members"),e.qZA(),e.TgZ(3,"div",84)(4,"div",85),e.YNc(5,mt,5,2,"div",86),e.YNc(6,dt,2,4,"div",86),e.TgZ(7,"div",87)(8,"select",88),e.NdJ("ngModelChange",function(a){e.CHM(t);const r=e.oxw(3);return e.KtG(r.selectedMemberRole=a)}),e.TgZ(9,"option",89),e._uU(10,"Select Role"),e.qZA(),e.YNc(11,pt,2,2,"option",90),e.ALo(12,"keyvalue"),e.qZA()(),e.YNc(13,_t,2,0,"button",91),e.YNc(14,ut,2,0,"button",91),e.qZA()()()}if(2&i){const t=e.oxw(3);e.xp6(5),e.Q6J("ngIf",t.data.team.owner.uid!=t.user.uid),e.xp6(1),e.Q6J("ngIf",t.data.team.owner.uid==t.user.uid&&t.showCombo),e.xp6(2),e.Q6J("ngModel",t.selectedMemberRole),e.xp6(3),e.Q6J("ngForOf",e.lcZ(12,6,t.roles)),e.xp6(2),e.Q6J("ngIf",t.data.team&&t.data.team.owner.uid==t.user.uid),e.xp6(1),e.Q6J("ngIf",t.data.team&&t.data.team.owner.uid!=t.user.uid)}}function ht(i,s){if(1&i&&(e.ynx(0),e.YNc(1,gt,15,8,"div",27),e.BQk()),2&i){const t=e.oxw(2);e.xp6(1),e.Q6J("ngIf",!t.data.team.has_subscription_expired)}}function ft(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"div",95)(1,"button",96),e.NdJ("click",function(){e.CHM(t);const a=e.oxw(2);return e.KtG(a.acceptInvitation())}),e._uU(2," Accept Invitation "),e.qZA(),e.TgZ(3,"button",97),e.NdJ("click",function(){e.CHM(t);const a=e.oxw(2);return e.KtG(a.rejectInvitation())}),e._uU(4," Reject Invitation "),e.qZA()()}}function xt(i,s){if(1&i&&(e.TgZ(0,"div",38)(1,"dt",39),e._uU(2," Billing Period: "),e.qZA(),e.TgZ(3,"dd",40),e._uU(4),e.qZA()()),2&i){const t=e.oxw(2);e.xp6(4),e.AsE(" ",t.data.team.subscription.billing_period_start_date," - ",t.data.team.subscription.billing_period_end_date," ")}}function bt(i,s){1&i&&(e.TgZ(0,"span"),e._uU(1," Expired "),e.qZA())}function vt(i,s){1&i&&(e.TgZ(0,"span"),e._uU(1," Canceled "),e.qZA())}function Tt(i,s){1&i&&(e.TgZ(0,"span"),e._uU(1," On Trial "),e.qZA())}function wt(i,s){1&i&&(e.TgZ(0,"span"),e._uU(1," Active "),e.qZA())}
1function yt(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"button",100),e.NdJ("click",function(){e.CHM(t);const a=e.oxw(3);return e.KtG(a.submitHandler("owner"))}),e._uU(1,"Save "),e.qZA()}}function Zt(i,s){if(1&i){const t=e.EpF();e.TgZ(0,"button",100),e.NdJ("click",function(){e.CHM(t);const a=e.oxw(3);return e.KtG(a.submitHandler("manager"))}),e._uU(1,"Save "),e.qZA()}}function kt(i,s){if(1&i&&(e.TgZ(0,"div",98),e.YNc(1,yt,2,0,"button",99),e.YNc(2,Zt,2,0,"button",99),e.qZA()),2&i){const t=e.oxw(2);e.xp6(1),e.Q6J("ngIf",t.data.team&&t.data.team.owner.uid==t.user.uid),e.xp6(1),e.Q6J("ngIf",t.data.team&&t.data.team.owner.uid!=t.user.uid)}}function At(i,s){if(1&i&&(e.TgZ(0,"div",13)(1,"div",14)(2,"div",15)(3,"div",16),e._UZ(4,"img",17),e.YNc(5,Fe,2,0,"div",18),e.qZA(),e.TgZ(6,"div",19),e.YNc(7,$e,3,2,"ng-container",20),e.YNc(8,et,6,2,"ng-template",null,21,e.W1O),e.TgZ(10,"div",13)(11,"div",22)(12,"label",23),e._uU(13,"Team Members"),e.qZA(),e.TgZ(14,"div",24)(15,"ul",25),e.YNc(16,rt,5,3,"li",26),e.qZA()(),e.YNc(17,ct,6,1,"ng-container",27),e.YNc(18,ht,2,1,"ng-container",27),e.TgZ(19,"div",28)(20,"label",29),e._uU(21,"Role Permissions:"),e.qZA(),e.TgZ(22,"ul",30)(23,"li",31)(24,"span",32),e._uU(25,"Manager: "),e.qZA(),e._uU(26,"Add/remove members, add/edit/delete content"),e.qZA(),e.TgZ(27,"li",31)(28,"span",32),e._uU(29,"Content Manager: "),e.qZA(),e._uU(30,"Add/edit/delete content "),e.qZA(),e.TgZ(31,"li",31)(32,"span",32),e._uU(33,"Contributor: "),e.qZA(),e._uU(34,"Add/edit content "),e.qZA()()()(),e.TgZ(35,"div",33),e.YNc(36,ft,5,0,"div",34),e.ynx(37),e.TgZ(38,"label",35),e._UZ(39,"i",36),e._uU(40," Team Subscription"),e.qZA(),e.TgZ(41,"dl",37)(42,"div",38)(43,"dt",39),e._uU(44," Team Owner: "),e.qZA(),e.TgZ(45,"dd",40),e._uU(46),e.qZA()(),e.YNc(47,xt,5,2,"div",41),e.TgZ(48,"div",38)(49,"dt",39),e._uU(50," Subscription Status: "),e.qZA(),e.TgZ(51,"dd",40),e.YNc(52,bt,2,0,"span",27),e.YNc(53,vt,2,0,"span",27),e.YNc(54,Tt,2,0,"span",27),e.YNc(55,wt,2,0,"span",27),e.qZA()()(),e.BQk(),e.qZA()()()(),e.YNc(56,kt,3,2,"div",42),e.qZA()()),2&i){const t=e.MAs(9),n=e.oxw();e.xp6(4),e.Q6J("src",n.data.team.profile_image,e.LSH),e.xp6(1),e.Q6J("ngIf",n.data.team.is_default),e.xp6(2),e.Q6J("ngIf",!n.data.team.has_subscription_expired)("ngIfElse",t),e.xp6(9),e.Q6J("ngForOf",n.data.team.activeUsers),e.xp6(1),e.Q6J("ngIf",n.data.team.pendingUsers.length>0),e.xp6(1),e.Q6J("ngIf",!n.data.team.has_pending_invitation&&n.data.team.permission.ADD_TEAM_MEMBER&&n.data.team.unassignedLicenses&&n.data.team.unassignedLicenses.length>0||n.data.team&&n.data.team.owner.uid==n.user.uid),e.xp6(18),e.Q6J("ngIf",!n.data.team.has_subscription_expired&&n.data.team.has_pending_invitation),e.xp6(10),e.hij(" ",n.data.team.owner.name," "),e.xp6(1),e.Q6J("ngIf",!n.data.team.subscription.on_trial),e.xp6(5),e.Q6J("ngIf",n.data.team.subscription.is_expired),e.xp6(1),e.Q6J("ngIf",n.data.team.subscription.is_cancelled),e.xp6(1),e.Q6J("ngIf",n.data.team.subscription.on_trial),e.xp6(1),e.Q6J("ngIf",!n.data.team.subscription.on_trial&&!n.data.team.subscription.is_cancelled&&!n.data.team.subscription.is_expired),e.xp6(1),e.Q6J("ngIf",n.data.team&&!n.data.team.has_subscription_expired&&!n.data.team.has_pending_invitation&&n.data.team.permission.EDIT_TEAM_MEMBER)}}let Ct=(()=>{class i{constructor(t,n,a,r,c){this.teamDocsService=t,this.helperService=n,this.activeRoute=a,this.dialog=r,this.authService=c,this.data={},this.members=[],this.member_counter=0,this.roles=[],this.user=null,this.owner=null,this.comboPlaceHolder="Please enter a Gmail or Google Workspace email address",this.selectedMemberRole="",this.selectedMemberEmail="",this.showCombo=!1,this.comboBoxInputData="",this.response=null}ngOnInit(){this.subscription=this.teamDocsService.observer().subscribe(t=>this.handleObserverResponse(t)),this.findByUid(this.activeRoute.snapshot.params.uid),this.loadRoles(),this.user=this.authService.user}ngOnDestroy(){this.subscription.unsubscribe()}loadRoles(){this.teamDocsService.loadRoles().subscribe(t=>this.roles=t)}findByUid(t){this.teamDocsService.findTeamByUid(t).subscribe(n=>{n&&!n.error?(this.teamDocsService.updateObserver(n.data),this.helperService.bindJqueryDropdown()):(this.helperService.errorMessage(n.message),this.helperService.navigateToUrl("/team-docs"))})}addMember(t){if(!this.selectedMemberRole||!this.selectedMemberEmail)return void this.helperService.errorMessage("Please provide all fields.");if(!/^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(this.selectedMemberEmail))return void this.helperService.errorMessage("Please provide a valid email address.");
1if((0,u.find)(this.members,l=>l.email==this.selectedMemberEmail))return void this.helperService.errorMessage("You have already added this team member.");if(this.selectedMemberEmail==this.data.team.owner.email)return void this.helperService.errorMessage("You can't add owner email as team member. This email is already a part of the team.");let a=(0,u.find)(this.data.licenses,l=>l.email==this.selectedMemberEmail);this.members.push({index:this.member_counter++,name:a?a.name:"--",email:this.selectedMemberEmail,role_name:(0,u.find)(this.roles,(l,x)=>x==this.selectedMemberRole),role:this.selectedMemberRole,profile_image_url:a?a.profile_image_url:"assets/images/default-user-profile/gray.svg"});var r=[];r="object"==typeof this.comboBoxInputData?this.comboBoxInputData:JSON.parse(this.comboBoxInputData);var c=this;this.comboBoxInputData=r.filter(function(l){return l!==c.selectedMemberEmail}),this.data={...this.data,...this.response,comboBoxInputData:this.comboBoxInputData},this.showCombo=!1,this.helperService.delay(200).then(()=>{this.showCombo=!0}),this.selectedMemberRole="",this.selectedMemberEmail="",this.submitHandler(t)}deleteMember(t){this.member_counter--,this.members.splice(this.members.indexOf(t),1)}resetMembers(){this.member_counter=0,this.members=[]}deleteTeamUser(t){confirm("Are you sure you want to delete "+t.email+" from the team '"+this.data.team.name+"'? \n \n All files are retained on Google Drive.")&&(this.helperService.blockUI("Removing "+t.email),this.teamDocsService.deleteTeamMember(this.data.team.uid,t.team_license_id).subscribe(n=>{n&&n.error?(this.helperService.errorMessage(n.message),this.helperService.unBlockUI()):(this.teamDocsService.updateObserver(n.data),this.helperService.successMessage("Member deleted from team."),this.helperService.unBlockUI())}))}rename(){this.helperService.openModal(Ye,{team:this.data.team})}setDefault(){confirm("This action will display '"+this.data.team.name+"' Templates, Projects, Contacts and Content Library entries in StartDeck. \n\n"+this.data.team.owner.name+" is the owner of "+this.data.team.name+"'s content. \n\nYou can switch back to personal Templates and Projects at any time.")&&this.teamDocsService.makeTeamDefault(this.data.team.uid).subscribe(n=>{n&&!n.error?this.helperService.navigateToUrl("/projects"):this.helperService.errorMessage(n.message)})}setMyDrive(){confirm("This action will display Google Drive Templates, Projects, Contacts and Content Library entries in StartDeck.")&&this.teamDocsService.setMyDrive().subscribe(()=>window.location.reload())}deactivate(){confirm("Are you sure you want to deactivate team '"+this.data.team.name+"'?")&&(this.helperService.blockUI(),this.teamDocsService.deactivateTeam({team_uid:this.data.team.uid}).subscribe(t=>{t&&!t.error?(this.helperService.navigateToUrl("/team-docs/inactive-teams"),this.helperService.unBlockUI(),this.helperService.successMessage("Team - "+this.data.team.name+" has been deactivated.")):(this.helperService.unBlockUI(),this.helperService.errorMessage(t.message))}))}leave(){confirm("Are you sure you want to leave '"+this.data.team.name+"' team?")&&(this.helperService.blockUI(),this.teamDocsService.leaveTeam(this.data.team.uid).subscribe(t=>{t&&(this.helperService.unBlockUI(),this.helperService.navigateToUrl("/team-docs/teams"))}))}acceptInvitation(){this.helperService.blockUI(),this.teamDocsService.acceptTeamInvitation(this.data.team.uid).subscribe(t=>{t&&t.error?(this.helperService.errorMessage(t.message),this.helperService.unBlockUI()):(window.location.reload(),this.helperService.successMessage("Invitation Accepted."),this.helperService.unBlockUI())})}rejectInvitation(){confirm("Are you sure you want to reject the invitation?")&&(this.helperService.blockUI(),this.teamDocsService.rejectTeamInvitation(this.data.team.uid).subscribe(t=>{t&&t.error?(this.helperService.errorMessage(t.message),this.helperService.unBlockUI()):(this.helperService.navigateToUrl("/team-docs/teams"),this.helperService.successMessage("Invitation Rejected."),this.helperService.unBlockUI())}))}back(){this.helperService.jumpToPreviousPage()}editMember(t){this.dialog.open(A,{width:"500px",disableClose:!0,panelClass:"material-modal-panel",data:{roles:this.roles,member:{email:t.email,role:t.team_role_id}}}).afterClosed().subscribe(a=>{a&&a.role_name&&a.role&&a.email&&(a={...t,role:a.role_name,team_role_id:a.role,email:a.email},this.data.team.activeUsers.splice(this.data.team.activeUsers.indexOf(t),1,a))})}validateMembers(){if(0==this.members.length)return!0;for(let t of this.members)if(t.error=!1,!t.email&&!t.role)return!0}validateForm(){let t=!1,n="";if(0==this.members.length)return!0;for(let r of this.members){if(r.error=!1,!r.email&&!r.role)return!0;
1if(!r.email&&r.role||r.email&&!r.role){r.error=!0,t=!0,n="Please fill all required fields";break}if(!/^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(r.email)){n="Please provide a valid email address..",t=!0;break}let c=(0,u.filter)(this.members,["email",r.email]);if(c.length>1){(0,u.forEach)(c,jt=>jt.error=!0),t=!0,n="Members with same email address are not allowed.";break}let l=this.data.team.pendingUsers.concat(this.data.team.activeUsers);if((0,u.filter)(l,["email",r.email]).length>0){t=!0,n="Members with same email address are already present in team.";break}}return!t||(this.helperService.errorMessage(n),!1)}submitHandler(t){this.validateForm()&&(this.helperService.blockUI(),"owner"==t?this.validateMembers()?(this.updateTeam(),this.helperService.unBlockUI()):this.teamDocsService.addLicenseMembers({members:this.members}).subscribe(a=>{0==a.error?this.updateTeam():1==a.error&&a.type&&"ALL_LICENSES_USED"==a.type?this.openUpgradeLicenseModal(a):this.helperService.errorMessage(a.message),this.helperService.unBlockUI()}):(this.updateTeam(),this.helperService.unBlockUI()))}updateTeam(){let t={newUsers:this.members,users:this.data.team.activeUsers.concat(this.data.team.pendingUsers)};this.helperService.blockUI(),this.teamDocsService.updateTeam(this.data.team.uid,t).subscribe(n=>{n&&!n.error?(this.teamDocsService.updateObserver(n.data),this.resetMembers(),this.helperService.successMessage("Team updated."),this.helperService.unBlockUI()):(this.helperService.errorMessage(n.message),this.helperService.navigateToUrl("/team-docs/teams"),this.helperService.unBlockUI())})}openUpgradeLicenseModal(t){this.helperService.openModal(C,{licensesCount:t.licensesCount,requiredLicenses:t.requiredLicenses}).output().subscribe(a=>{a&&this.submitHandler("owner")})}handleObserverResponse(t){this.comboBoxInputData=JSON.stringify(t.team.unassignedLicenses.map(function(n){return n.email})),this.response=t,this.owner=t.team.owner,this.data={...this.data,...t,comboBoxInputData:this.comboBoxInputData},this.showCombo=!0}handleComboxboxOutput(t){this.selectedMemberEmail=t}isOwner(){return this.data.team.owner.id==this.authService.user.id}static#e=this.\u0275fac=function(n){return new(n||i)(e.Y36(g.e),e.Y36(d.W_),e.Y36(_.gz),e.Y36(h.on),e.Y36(d.e8))};static#t=this.\u0275cmp=e.Xpm({type:i,selectors:[["app-view-team"]],decls:5,vars:3,consts:[["class","bg-white",4,"ngIf"],[1,"md:container","mx-auto","px-4","py-4","min-h-90-vh","lg:min-h-70-vh","xl:min-h-screen","mb-20"],["class","mt-20 p-25p text-center",4,"ngIf","ngIfElse"],["showTeam",""],[1,"bg-white"],[1,"md:container","mx-auto"],[1,"flex","sm:items-center","px-4","py-3"],[1,"pr-2"],["href","javascript:void(0);",1,"text-gray-300",3,"click"],[1,"fa","fa-angle-left","font-bold","text-3xl"],[1,"text-gray-300","font-medium","flex-1","text-center","text-sm","sm:text-base"],[1,"mt-20","p-25p","text-center"],["aria-hidden","true",1,"fa","fa-spinner","fa-2x","fa-spin","text-primary"],[1,"flex","flex-wrap"],[1,"w-full","lg:w-10/12","mx-auto"],[1,"bg-white","shadow-card"],[1,"relative"],["alt","StartDeck Team",1,"h-20","md:h-24","lg:h-full","object-cover","w-full",3,"src"],["class","bg-white p-1 rounded-full inline-block absolute top-2 right-2",4,"ngIf"],[1,"p-3"],[4,"ngIf","ngIfElse"],["teamDocsSubscriptionExpired",""],[1,"w-full","md:w-9/12","lg:w-9/12","md:pr-3","order-last","md:order-none"],[1,"block","text-gray-600","text-sm","mb-1"],[1,"bg-smoke-white","bg-opacity-75","border","border-gray-light","border-opacity-50","rounded","px-3"],[1,"last-child-style-none"],["class","flex justify-between sm:items-center py-3 border-b border-gray-light border-opacity-25",4,"ngFor","ngForOf"],[4,"ngIf"],[1,"px-2","sm:px-3","py-2","text-gray-600","bg-gray-light","bg-opacity-10","mt-3","rounded"],[1,"block","font-medium","text-sm","mb-0.5"],[1,"list-disc","text-xs","pl-4"],[1,""],[1,"text-gray-300"],[1,"w-full","md:w-3/12","lg:w-3/12","bg-white","rounded","border","border-light","mb-3","md:mb-0"],["class","flex md:block justify-end p-3",4,"ngIf"],[1,"block","text-gray-600","bg-opacity-50","text-xs","font-medium","bg-light","px-3","py-1.5"],[1,"fa","fa-info-circle"],[1,"grid","grid-cols-1","sm:grid-cols-3","md:grid-cols-1","gap-3","rounded","px-3","py-2"],[1,"sm:col-span-1"],[1,"text-xs","text-gray-900"],[1,"text-xs","font-medium","text-gray-300"],["class","sm:col-span-1",4,"ngIf"],["class","flex flex-wrap w-full gap-4 mt-4 justify-center text-center",4,"ngIf"],[1,"bg-white","p-1","rounded-full","inline-block","absolute","top-2","right-2"],["src","assets/images/icon-check-success.svg"],["class","p-2 mb-3 text-gray-600 bg-gray-600 bg-opacity-10 border border-gray-600 border-opacity-25 font-normal text-xs rounded",4,"ngIf"],["class","flex w-full gap-3 justify-end sm:justify-start sm:text-center mb-3 relative",4,"ngIf"],[1,"p-2","mb-3","text-gray-600","bg-gray-600","bg-opacity-10","border","border-gray-600","border-opacity-25","font-normal","text-xs","rounded"],[1,"fa","fa-info-circle","text-sm"],[1,"flex","w-full","gap-3","justify-end","sm:justify-start","sm:text-center","mb-3","relative"],["href","javascript:void(0);",1,"text-xs","font-medium","bg-light","px-3","py-0.5","rounded","text-primary","inline-block","sm:hidden","dropdown-toggle-action"],[1,"fa","fa-angle-down","text-sm","font-bold","ml-1"],[1,"bg-white","min-w-36","sm:w-auto","sm:bg-transparent","list-none","shadow-dropdown","sm:shadow-none","text-xs","text-left","sm:text-right","leading-6","text-gray-300","px-3","sm:px-0","absolute","sm:static","rounded","dropdown-menu","hidden","z-10","mt-3","sm:mt-0","sm:flex","
1sm:flex-wrap","sm:items-center","sm:gap-2.5","md:gap-3","sm:justify-end","top-6"],["class","block sm:inline-block",4,"ngIf"],[1,"block","sm:inline-block"],["href","javascript:void(0);",1,"bg-white","sm:hover:bg-primary","sm:rounded","sm:px-2.5","md:px-3","py-1.5","sm:py-1","block","sm:inline-block","sm:text-gray-900","sm:hover:text-white","border-b","sm:border","border-light","sm:border-gray-900","sm:hover:border-primary","text-xs","tracking-wider","focus:outline-none","sm:hover:shadow-btn","transition-all","duration-300",3,"routerLink"],["href","javascript:void(0);",1,"bg-white","sm:bg-success","sm:rounded","sm:px-2.5","md:px-3","py-1.5","sm:py-1","block","sm:inline-block","sm:text-white","border-b","sm:border","border-light","sm:border-success","sm:hover:border-success","text-xs","tracking-wider","focus:outline-none","sm:hover:shadow-btn","transition-all","duration-300",3,"click"],["src","assets/images/icon-check-white.svg",1,"w-3.5","hidden","sm:inline-block","-mt-0.5"],["src","assets/images/icon-check-success.svg",1,"w-3.5","inline-block","sm:hidden","-mt-0.5"],["href","javascript:void(0);",1,"bg-white","sm:hover:bg-success","sm:rounded","sm:px-2.5","md:px-3","py-1.5","sm:py-1","block","sm:inline-block","sm:text-gray-900","sm:hover:text-white","border-b","sm:border","border-light","sm:border-gray-900","sm:hover:border-success","text-xs","tracking-wider","focus:outline-none","sm:hover:shadow-btn","transition-all","duration-300",3,"click"],["href","javascript:void(0);",1,"bg-white","sm:hover:bg-primary","sm:rounded","sm:px-2.5","md:px-3","py-1.5","sm:py-1","block","sm:inline-block","sm:text-gray-900","sm:hover:text-white","border-b","sm:border","border-light","sm:border-gray-900","sm:hover:border-primary","text-xs","tracking-wider","focus:outline-none","sm:hover:shadow-btn","transition-all","duration-300",3,"click"],["href","javascript:void(0);",1,"bg-white","sm:hover:bg-warning","sm:rounded","sm:px-2.5","md:px-3","py-1.5","sm:py-1","block","sm:inline-block","sm:text-gray-900","sm:hover:text-white","border-b","sm:border","border-light","sm:border-gray-900","sm:hover:border-warning","text-xs","tracking-wider","focus:outline-none","sm:hover:shadow-btn","transition-all","duration-300",3,"click"],[1,"text-xs","text-danger","rounded-md","bg-red-100","px-2.5","py-1.5","mb-3"],[1,"fa","fa-exclamation-triangle"],["notOwner",""],["href","javascript:void(0);",1,"underline","whitespace-nowrap","font-medium","hover:text-red-600",3,"routerLink"],[1,"flex","justify-between","sm:items-center","py-3","border-b","border-gray-light","border-opacity-25"],["class","flex items-start",4,"ngIf","ngIfElse"],["ActiveMember",""],["class","text-right w-6",4,"ngIf"],[1,"flex","items-start"],[1,"inline-block","w-7","h-7","rounded-full","mt-0.5",3,"src"],[1,"ml-2"],[1,"text-gray-300","text-sm","leading-4","sm:leading-5","flex","flex-wrap","gap-0.5","break-all"],[1,"text-gray-900"],[1,"text-gray-900","leading-4","break-all"],["class"," inline-block w-3 cursor-pointer","src","assets/images/icon-pencil.svg",3,"click",4,"ngIf"],["src","assets/images/icon-pencil.svg",1,"inline-block","w-3","cursor-pointer",3,"click"],[1,"text-right","w-6"],["href","javascript:void(0);",3,"click"],["alt","Delete","src","assets/images/icon-delete-danger.svg",1,"inline-block","w-3"],[1,"mb-1","text-warning","text-xs","font-medium","italic","mt-2"],[1,"text-gray-900","tracking-normal","leading-4"],[1,"block","text-gray-600","text-sm","mb-1","mt-2"],[1,"border","border-dashed","border-gray-light","border-opacity-50","rounded","p-3","mb-3","relative"],[1,"flex","flex-wrap","gap-3","sm:gap-0"],["class","w-full sm:w-5/12 sm:pr-3",4,"ngIf"],[1,"w-full","sm:w-5/12","sm:pr-3"],[1,"appearance-none","relative","block","w-full","text-xs","rounded","px-2","py-1","h-9","bg-white","border","border-gray-light","focus:border-primary","focus:outline-none","select-aarow-change","text-gray-600",3,"ngModel","ngModelChange"],["value",""],[3,"value",4,"ngFor","ngForOf"],["class","bg-transparent sm:bg-primary rounded w-full sm:w-2/12 text-right sm:text-center leading-4 inline-block text-primary sm:text-white text-xs focus:outline-none sm:hover:shadow-btn transition-all duration-300 underline sm:no-underline p-1",3,"click",4,"ngIf"],[3,"value"],[3,"DefaultText","required","value","o
1ptions","optionsChange","change"],[1,"bg-transparent","sm:bg-primary","rounded","w-full","sm:w-2/12","text-right","sm:text-center","leading-4","inline-block","text-primary","sm:text-white","text-xs","focus:outline-none","sm:hover:shadow-btn","transition-all","duration-300","underline","sm:no-underline","p-1",3,"click"],[1,"flex","md:block","justify-end","p-3"],[1,"bg-primary","rounded","px-2","py-1.5","w-full","inline-block","text-white","text-xs","tracking-wider","font-medium","focus:outline-none","hover:shadow-btn","transition-all","duration-300","mr-3","md:mr-0","md:mb-3",3,"click"],[1,"bg-danger","rounded","px-2","py-1.5","w-full","inline-block","text-white","text-xs","tracking-wider","font-medium","focus:outline-none","hover:shadow-btn","transition-all","duration-300",3,"click"],[1,"flex","flex-wrap","w-full","gap-4","mt-4","justify-center","text-center"],["class","bg-success rounded px-6 py-2 inline-block text-white text-sm tracking-wider font-medium focus:outline-none hover:shadow-btn transition-all duration-300",3,"click",4,"ngIf"],[1,"bg-success","rounded","px-6","py-2","inline-block","text-white","text-sm","tracking-wider","font-medium","focus:outline-none","hover:shadow-btn","transition-all","duration-300",3,"click"]],template:function(n,a){if(1&n&&(e.YNc(0,Ee,8,1,"div",0),e.TgZ(1,"div",1),e.YNc(2,Oe,2,0,"div",2),e.YNc(3,At,57,15,"ng-template",null,3,e.W1O),e.qZA()),2&n){const r=e.MAs(4);e.Q6J("ngIf",a.data.team),e.xp6(2),e.Q6J("ngIf",!a.data.team)("ngIfElse",r)}},dependencies:[p.sg,p.O5,_.rH,o.YN,o.Kr,o.EJ,o.JJ,o.On,U.o,p.Nd],encapsulation:2})}return i})();function Ut(i,s){1&i&&(e.TgZ(0,"div",10),e._UZ(1,"i",11),e.qZA())}function It(i,s){if(1&i&&e._UZ(0,"img",23),2&i){const t=e.oxw().$implicit;e.Q6J("src",t.user.profile_image_url,e.LSH)}}function St(i,s){1&i&&e._UZ(0,"img",24)}function Mt(i,s){if(1&i&&(e.TgZ(0,"li",15)(1,"div",16),e.YNc(2,It,1,1,"img",17),e.YNc(3,St,1,0,"img",18),e.TgZ(4,"div",19)(5,"h4",20),e._uU(6),e.qZA(),e.TgZ(7,"small",21),e._UZ(8,"i",22),e._uU(9),e.qZA()()()()),2&i){const t=s.$implicit;e.xp6(2),e.Q6J("ngIf",t.user.profile_image_url),e.xp6(1),e.Q6J("ngIf",!t.user.profile_image_url),e.xp6(3),e.hij(" ",t.description," "),e.xp6(3),e.hij(" ",t.updated_at," ")}}function qt(i,s){if(1&i&&(e.TgZ(0,"div",12)(1,"ul",13),e.YNc(2,Mt,10,4,"li",14),e.qZA()()),2&i){const t=e.oxw();e.xp6(2),e.Q6J("ngForOf",t.data.activities)}}let Jt=(()=>{class i{constructor(t,n,a){this.activateRoute=t,this.helperService=n,this.teamDocsService=a,this.data={},this.isLoading=!1,this.team_uid=""}ngOnInit(){this.team_uid=this.activateRoute.snapshot.params.uid,this.getActivities()}getActivities(){this.isLoading=!0,this.teamDocsService.teamActivities(this.team_uid).subscribe(n=>{this.data=n,this.isLoading=!1})}back(){this.helperService.jumpToPreviousPage()}static#e=this.\u0275fac=function(n){return new(n||i)(e.Y36(_.gz),e.Y36(d.W_),e.Y36(g.e))};static#t=this.\u0275cmp=e.Xpm({type:i,selectors:[["app-team-activity"]],decls:12,vars:4,consts:[[1,"bg-white"],[1,"container","mx-auto"],[1,"flex","sm:items-center","px-4","py-3"],[1,"pr-2"],["href","javascript:void(0);",1,"text-gray-300",3,"routerLink"],[1,"fa","fa-angle-left","font-bold","text-3xl"],[1,"text-gray-300","font-medium","flex-1","text-center","text-sm","sm:text-base"],[1,"container","mx-auto","px-4","py-4","min-h-90-vh","lg:min-h-70-vh","xl:min-h-screen","mb-20"],["class","mt-20 p-25p text-center",4,"ngIf","ngIfElse"],["showActivites",""],[1,"mt-20","p-25p","text-center"],["aria-hidden","true",1,"fa","fa-spinner","fa-2x","fa-spin","text-primary","font-size-50"],[1,"bg-white","shadow-card","px-4"],[1,"last-child-style-none"],["class","flex flex-wrap py-4 border-b border-light",4,"ngFor","ngForOf"],[1,"flex","flex-wrap","py-4","border-b","border-light"],[1,"w-full","flex","items-start"],["class","inline-block w-7 h-7 rounded-full mt-0.5",3,"src",4,"ngIf"],["class","inline-block w-7 h-7 rounded-full mt-0.5","src","assets/images/default-member-profile.png",4,"ngIf"],[1,"ml-2"],[1,"text-gray-300","text-sm","leading-5","md:leading-4"],[1,"font-normal","text-gray-900","leading-4"],[1,"fa","fa-clock-o"],[1,"inline-block","w-7","h-7","rounded-full","mt-0.5",3,"src"],["src","assets/images/default-member-profile.png",1,"inline-block","w-7","h-7","rounded-full","mt-0.5"]],template:function(n,a){if(1&n&&(e.TgZ(0,"div",0)(1,"div",1)(2,"div",2)(3,"div",3)(4,"a",4),e._UZ(5,"i",5),e.qZA()(),e.TgZ(6,"div",6),e._uU(7),e.qZA()()()(),e.TgZ(8,"div",7),e.YNc(9,Ut,2,0,"div",8),e.YNc(10,qt,3,1,"ng-template",null,9,e.W1O),e.qZA()),2&n){const r=e.MAs(11);e.xp6(4),e.Q6J("routerLink","/team-docs/teams/"+a.team_uid),e.xp6(3),e.hij(" ",a.data&&a.data.team_name?a.data.team_name+" Activity":"Activity"," "),e.xp6(2),e.Q6J("ngIf",a.data.activities&&0==a.data.activities.length)("ngIfElse",r)}},dependencies:[p.sg,p.O5,_.rH],encapsulation:2})}return i})();var f=m(8036),T=m(3499),Nt=m(304);let w=(()=>{class i{constructor(t,n){this.authService=t,this.helper=n}canActivate(t,n){return this.authService.authenticate(!0).then(a=>{if(!a)return!1;let r=this.authService.user||null;return!!(r&&r.hasTeamDocsSubscription||r&&!r.hasTeamDocsSubscription&&r.teams.length>0)||(this.helper.navigateToUrl("/team-docs"),!1)})}static#e=this.\u0275fac=function(n){return new(n||i)(e.LFG(Nt.e),e.LFG(I.W))};static#t=this.\u0275prov=e.Yz7({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})();const Lt=[{path:"",component:N,data:{title:"Team Docs | StartDeck",logo:d.W_.getLogo(1)}},{path:"licenses",component:R,canActivate:[f.a,T.a],data:{title:"Team Roster | Team Docs | StartDeck",logo:d.W_.getLogo(3)}},{path:"teams/create",component:je,canActivate:[f.a,T.a],data:{title:"Create Team | Team Docs | StartDeck",logo:d.W_.getLogo(3)}},{path:"teams",component:se,canActivate:[f.a,w],data:{title:"Teams | Team Docs | StartDeck",logo:d.W_.getLogo(3)}},{path:"inactive-teams",component:ge,canActivate:[f.a,T.a],data:{title:"Inactive Teams | Team Docs | StartDeck",logo:d.W_.getLogo(3)}},{path:"teams/:uid",component:Ct,canActivate:[f.a,w],data:{title:"Team | Team Docs | StartDeck",logo:d.W_.getLogo(3)}},{path:"teams/:uid/activities",component:Jt,canActivate:[f.a,w],data:{title:"Team Activities | Team Docs | StartDeck",logo:d.W_.getLogo(3)}}];let Qt=(()=>
1{class i{static#e=this.\u0275fac=function(n){return new(n||i)};static#t=this.\u0275mod=e.oAB({type:i});static#i=this.\u0275inj=e.cJS({imports:[_.Bz.forChild(Lt),_.Bz]})}return i})(),Dt=(()=>{class i{static#e=this.\u0275fac=function(n){return new(n||i)};static#t=this.\u0275mod=e.oAB({type:i});static#i=this.\u0275inj=e.cJS({imports:[S.I,Qt]})}return i})()}}]); 2//# sourceMappingURL=842.c1c443994c653d57.js.map
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.