1import{b as B}from"./chunk-FZFWY5Y6.js";import"./chunk-EGEBNI4V.js";import{E as z,g as X,o as V}from"./chunk-EBOVR5NW.js";import{u as K}from"./chunk-UME7L37K.js";import{a as q}from"./chunk-R76LZEZS.js";import{Ab as p,Bb as S,Ca as m,Cb as A,Cc as w,Db as h,Eb as $,Ec as k,Gb as T,Ib as O,Kd as x,Ma as R,Oh as j,Qb as G,Rb as I,Rg as Q,Ta as L,aa as d,bc as U,cc as b,dc as v,fa as a,fb as M,ga as l,gb as C,mb as o,nb as r,ob as c,th as Y,wc as W,xf as f,yb as y,zf as H}from"./chunk-HVCWS4IF.js";import{j as N}from"./chunk-KJ7W2O2B.js";var Z=["modal"];function ee(s,t){s&1&&(o(0,"li"),p(1,5),c(2,"strong"),S(),r());}function te(s,t){s&1&&(o(0,"li"),p(1,6),c(2,"strong"),S(),r());}function ne(s,t){if(s&1){let e=y();o(0,"div",7)(1,"h4",8),A(2,1),r(),o(3,"button",9),T("click",function(){let n=a(e).close;return l(n());}),c(4,"my-global-icon",10),r()(),o(5,"div",11),c(6,"img",12),o(7,"div",13),A(8,2),r(),o(9,"p"),p(10,3),c(11,"strong"),S(),r(),o(12,"ul"),M(13,ee,3,0,"li"),M(14,te,3,0,"li"),r()(),o(15,"div",14)(16,"my-peertube-checkbox",15),v("ngModelChange",function(n){a(e);let g=O();return b(g.stopDisplayModal,n)||(g.stopDisplayModal=n),l(n);}),r(),o(17,"input",16),T("click",function(){let n=a(e).close;return l(n());})("key.enter",function(){let n=a(e).close;return l(n());}),r(),o(18,"a",17),T("click",function(){let n=a(e).close;return l(n());})("key.enter",function(){let n=a(e).close;return l(n());}),A(19,4),r()();}if(s&2){let e=O();m(2),h(e.instanceName),$(2),m(11),C(e.hasAccountAvatar(e.user)?-1:13),m(),C(e.hasAccountDescription(e.user)?-1:14),m(2),U("ngModel",e.stopDisplayModal);}}var u=class u{userService=d(j);modalService=d(K);notifier=d(Q);serverService=d(Y);modal=k("modal");created=w();stopDisplayModal=!1;ref;user;LS_KEYS={NO_ACCOUNT_SETUP_WARNING_MODAL:"no_account_setup_warning_modal"};ngOnInit(){this.created.emit();}get instanceName(){return this.serverService.getHTMLConfig().instance.name;}hasAccountAvatar(t){return t.account.avatars.length!==0;}hasAccountDescription(t){return!!t.account.description;}shouldAutoOpen(t){return!(this.modalService.hasOpenModals()||t.noAccountSetupWarningModal===!0||f.getItem(this.LS_KEYS.NO_ACCOUNT_SETUP_WARNING_MODAL)==="true"||this.hasAccountAvatar(t)&&this.hasAccountDescription(t)||this.userService.hasSignupInThisSession());}show(t){this.user=t,!this.ref&&(this.ref=this.modalService.open(this.modal(),{centered:!0,backdrop:"static",keyboard:!1,size:"md"}),this.ref.result.finally(()=>{this.stopDisplayModal===!0&&this.doNotOpenAgain();}));}doNotOpenAgain(){f.setItem(this.LS_KEYS.NO_ACCOUNT_SETUP_WARNING_MODAL,"true"),this.userService.updateMyProfile({noAccountSetupWarningModal:!0}).subscribe({next:()=>H.info("We will not open the account setup modal again."),error:t=>this.notifier.handleError(t)});}};N(u,"\u0275fac",function(e){return new(e||u)();}),N(u,"\u0275cmp",R({type:u,selectors:[["my-account-setup-warning-modal"]],viewQuery:function(e,i){e&1&&G(i.modal,Z,5),e&2&&I();},outputs:{created:"created"},decls:2,vars:0,consts:()=>{let t;t="Close this modal";let e;e="Don't show me this anymore";let i;i="Close";let n;n="Welcome to "+"\uFFFD0\uFFFD"+", dear user!";let g;g="It's time to set up your account profile!";let E;E="Help moderators and other users to know "+"\uFFFD#11\uFFFD"+"who you are"+"\uFFFD/#11\uFFFD"+" by:";let F;F="Set up";let P;P="Uploading an "+"\uFFFD#2\uFFFD"+"avatar"+"\uFFFD/#2\uFFFD"+"";let D;return D="Writing a "+"\uFFFD#2\uFFFD"+"description"+"\uFFFD/#2\uFFFD"+"",[["modal",""],n,g,E,F,P,D,[1,"modal-header"],[1,"modal-title"],["title",t,1,"border-0","p-0",3,"click"],["iconName","cross"],[1,"modal-body"],["src","/client/assets/images/mascot/happy.svg","alt","",1,"mascot"],[1,"subtitle"],[1,"modal-footer","inputs"],["inputName","stopDisplayModal","labelText",e,3,"ngModelChange","ngModel"],["type","button","role","button","value",i,1,"peertube-button","secondary-button",3,"click","key.enter"],["routerLink","/my-account","rel","noopener noreferrer","ngbAutofocus","",1,"peertube-button-link","primary-button",3,"click","key.enter"]];},template:function(e,i){e&1&&L(0,ne,20,4,"ng-template",null,0,W);},dependencies:[q,B,z,X,V,x],styles:[".modal-body[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:center;justify-content:center}.mascot-fw[_ngcontent-%COMP%]{width:170px}.mascot[_ngcontent-%COMP%]{display:block;width:170px;height:220px;margin-inline-end:calc(1.325rem + .9vw)}@media(min-width:1200px){.mascot[_ngcontent-%COMP%]{margin-inline-end:2rem}}.subtitle[_ngcontent-%COMP%]{font-weight:600;margin-bottom:10px}li[_ngcontent-%COMP%]{margin-bottom:10px}"]}));var J=u;export{J as AccountSetupWarningModalComponent};/**i18n:347eeb695970c32bc275618edc2e751c67145d9fc3012e70543c114a99b9e016*/
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.