import{s as w,t as A}from"./chunk-C6uGsfWa.js";import{Ao as jx,Br as T$,C as Au,Ca as dA,Fn as MV,Fo as kV,Gn as NV,Hi as Zt,Ja as g,Jn as Nhe,Jt as Hx,Ki as _5,Kr as Tu,Kt as Hw,L as Bx,Lr as Se$1,Ls as sAe,N as Bn,Nr as S$,Ns as rh,Or as Rhe,R as C$,Ra as f5,Rr as Si,S as Ahe,Sc as x$,So as jV,Ta as dBe,To as je,V as CI,Wi as _$,Ws as sn,X as D$,Xo as lx,Zi as aA,Zs as th,_s as ph,ai as Vj,br as Qc,cr as Owe,ei as V,eo as h5,et as DI,fi as Wg,gt as Ex,hi as Wx,hn as Kn,jt as Gj,k as Bb,lo as i3,mt as Em,n as $B,nn as J$,nr as O3,nt as DT,pn as Kc,pr as PV,s as $a,ss as o5,va as cf,wn as LV,xa as cr,ya as ci,yc as wp,za as fA}from"./chunk-b0nJCs5_.js";import{t as X1}from"./chunk-CDRFWLLW.js";import"./chunk-Bm4_iVi2.js";import"./chunk-C0C2vyNb.js";import{A as qn,C as fn,I as yn,O as ln,_ as Zn,o as Je,p as Vn,s as Jn,t as $n,u as Qn}from"./chunk-Cmet2Nw-.js";import"./chunk-CkJf4plT.js";import"./chunk-Dga4Oy_6.js";import{c as oi}from"./chunk-q-6uNE4L.js";import{t as S}from"./chunk-CKCWxqhm.js";import{O as sr}from"./chunk-DcB590Yc.js";import"./chunk-CnEH9ox82.js";import{n as ce}from"./chunk-DwtxXnIx2.js";import"./chunk-DsKBogZp.js";import"./chunk-DWd4safw.js";import{a as ne,r as Le}from"./chunk-BAE6eT2L.js";import{i as o}from"./chunk-BWPHh9Wj.js";import{t as g$1}from"./chunk-DJBlpGNa.js";import{d as Xe,h as Ze,i as Jo,o as Ke,p as Ye,t as $t$1,w as zt,x as qe}from"./chunk-B2OTUWHm2.js";import{t as k}from"./chunk-DGv871DT2.js";var It=A((lo,Et)=>{Et.exports=`<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-key-round-icon lucide-key-round">
  <path d="M2.586 17.414A2 2 0 0 0 2 18.828V21a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h1a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h.172a2 2 0 0 0 1.414-.586l.814-.814a6.5 6.5 0 1 0-4-4z" />
  <circle cx="16.5" cy="7.5" r=".5" fill="currentColor" />
</svg>
`});var At=A((_o,Pt)=>{Pt.exports=`<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-briefcase-business-icon lucide-briefcase-business">
  <path d="M12 12h.01" />
  <path d="M16 6V4a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v2" />
  <path d="M22 13a18.15 18.15 0 0 1-20 0" />
  <rect width="20" height="14" x="2" y="6" rx="2" />
</svg>
`});function $e(){return`no_welcome_modal`}var Ne=class l{hide=Ahe();static ɵfac=function(e){return new(e||l)};static ɵcmp=$a({type:l,selectors:[[`my-admin-config-wizard-documentation`]],outputs:{hide:`hide`},decls:55,vars:0,consts:()=>{let n;n="Felicitări";let e;e="Platforma ta a fost configurată!";let t;t=`Este timpul să adaugi informații despre platforma ta! ${`[�#12�|�#13�|�#14�|�#15�|�#16�]`}Configurarea unei descrieri${`[�/#12�|�/#13�|�/#14�|�/#15�|�/#16�]`}, specificarea ${`[�#12�|�#13�|�#14�|�#15�|�#16�]`}cine ești${`[�/#12�|�/#13�|�/#14�|�/#15�|�/#16�]`}, de ce ${`[�#12�|�#13�|�#14�|�#15�|�#16�]`}ai creat platforma ta${`[�/#12�|�/#13�|�/#14�|�/#15�|�/#16�]`} și ${`[�#12�|�#13�|�#14�|�#15�|�#16�]`}cât timp${`[�/#12�|�/#13�|�/#14�|�/#15�|�/#16�]`} intenționezi să o ${`[�#12�|�#13�|�#14�|�#15�|�#16�]`}menții${`[�/#12�|�/#13�|�/#14�|�/#15�|�/#16�]`} este foarte important pentru ca vizitatorii să înțeleagă ce tip de site web este. `,t=C$(t);let r;r="Link-uri utile";let s;s="Site-ul oficial PeerTube:";let p;p="Articol de blog, ajutor sau descoperă PeerTube";let I;I="Index public PeerTube:";let D;D="Adaugă platforma ta în indexul public oficial PeerTube";let x;x="Documentație";let k;k="Administrator:";let X;X="Gestionarea utilizatorilor, urmărirea altor platforme, gestionarea spam-erilor, configurarea stocării obiecte sau transcodare la distanță...";let A;A="Configurează-ți contul, gestionează liste de redare video, descoperă aplicații terțe...";let y;y="Interfață linie de comandă:";let we;we="Încărcați sau importați videoclipuri, analizați jurnalele, eliminați directoarele de stocare, resetați parola utilizatorului ...";let Le;Le="Închide";let We;return We="Completează informațiile platformei",[n,e,t,r,s,p,I,D,x,k,X,A,y,we,Le,We,[1,`root`],[1,`one-column`],[1,`mascot-container`],[`src`,`/client/assets/images/mascot/happy.svg`,`alt`,`mascot`,1,`mascot`],[1,`title`],[1,`sub-title`],[1,`mt-4`],[1,`text-content`],[`href`,`https://joinpeertube.org`,`target`,`_blank`,1,`link-primary`,`me-1`],[`href`,`https://instances.joinpeertube.org/instances`,`target`,`_blank`,1,`link-primary`,`me-1`],[`href`,`https://docs.joinpeertube.org/admin/following-instances`,`target`,`_blank`,1,`link-primary`,`me-1`],[`href`,`https://docs.joinpeertube.org/use/setup-account`,`target`,`_blank`,1,`link-primary`,`me-1`],[`href`,`https://docs.joinpeertube.org/maintain/tools`,`target`,`_blank`,1,`link-primary`,`me-1`],[1,`buttons`],[`theme`,`secondary`,3,`click`],[`theme`,`primary`,`ptRouterLink`,`/admin/settings/config`,3,`click`]]},template:function(e,t){e&1&&(wp(0,`div`,16)(1,`div`,17)(2,`div`,18),th(3,`img`,19),Bb(),wp(4,`h4`)(5,`div`,20),S$(6,0),Bb(),wp(7,`div`,21),S$(8,1),Bb()()(),wp(9,`div`,22)(10,`span`,23),Hx(11,2),th(12,`strong`)(13,`strong`)(14,`strong`)(15,`strong`)(16,`strong`),Bx(),Bb()(),wp(17,`div`,22)(18,`h5`),S$(19,3),Bb(),wp(20,`ul`,23)(21,`li`)(22,`a`,24),S$(23,4),Bb(),wp(24,`span`),S$(25,5),Bb()(),wp(26,`li`)(27,`a`,25),S$(28,6),Bb(),wp(29,`span`),S$(30,7),Bb()()()(),wp(31,`div`,22)(32,`h5`),S$(33,8),Bb(),wp(34,`ul`,23)(35,`li`)(36,`a`,26),S$(37,9),Bb(),wp(38,`span`),S$(39,10),Bb()(),wp(40,`li`)(41,`a`,27),J$(42,`User:`),Bb(),wp(43,`span`),S$(44,11),Bb()(),wp(45,`li`)(46,`a`,28),S$(47,12),Bb(),wp(48,`span`),S$(49,13),Bb()()()(),wp(50,`div`,29)(51,`my-button`,30),rh(`click`,function(){return t.hide.emit()}),S$(52,14),Bb(),wp(53,`my-button`,31),rh(`click`,function(){return t.hide.emit()}),S$(54,15),Bb()()())},dependencies:[ce],styles:[`.steps[_ngcontent-%COMP%]{color:var(--%NS%fg-200);font-size:14px;font-weight:700}.title[_ngcontent-%COMP%]{color:var(--%NS%fg-350);font-weight:700;font-size:calc(1.3625rem + 1.35vw)}@media(min-width:1200px){.title[_ngcontent-%COMP%]{font-size:2.375rem}}.sub-title[_ngcontent-%COMP%]{color:var(--%NS%fg-300);font-weight:400;font-size:1.25rem}h4[_ngcontent-%COMP%]{margin-bottom:0}.text-content[_ngcontent-%COMP%]{color:var(--%NS%fg-200)}.buttons[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;justify-content:center;margin-top:calc(1.375rem + 1.5vw)}@media(min-width:1200px){.buttons[_ngcontent-%COMP%]{margin-top:2.5rem}}.buttons[_ngcontent-%COMP%]{gap:calc(1.275rem + .3vw)}@media(min-width:1200px){.buttons[_ngcontent-%COMP%]{gap:1.5rem}}form[_ngcontent-%COMP%]{max-width:512px;width:100%}.two-columns[_ngcontent-%COMP%]{display:flex;gap:1rem}.two-columns.width-50[_ngcontent-%COMP%] > div[_ngcontent-%COMP%]{width:50%}.one-column[_ngcontent-%COMP%]{text-align:center}.one-column[_ngcontent-%COMP%]   .mascot-container[_ngcontent-%COMP%]{position:relative;height:110px;margin:0 auto}.one-column[_ngcontent-%COMP%]   .mascot-container[_ngcontent-%COMP%], .one-column[_ngcontent-%COMP%]   .mascot[_ngcontent-%COMP%]{width:170px}.one-column[_ngcontent-%COMP%]   .mascot[_ngcontent-%COMP%]{position:absolute;top:-100px;left:0;height:190px}h5[_ngcontent-%COMP%]{font-size:1rem;font-weight:700;color:var(--%NS%fg-300)}`],changeDetection:1})};var Nt=l=>({"input-error":l});function Tt(l,n){if(l&1&&(wp(0,`div`,22),J$(1),Bb()),l&2){let e=D$();$B(),aA(e.formErrors.platformName)}}function Dt(l,n){if(l&1&&(wp(0,`div`,22),J$(1),Bb()),l&2){let e=D$();$B(),aA(e.formErrors.shortDescription)}}function Ft(l,n){if(l&1){let e=jV();wp(0,`my-button`,34),rh(`click`,function(){CI(e);return DI(D$().back.emit())}),S$(1,10),Bb()}}var Ie=class l{server=g(Zt);formReactiveService=g(S);themeService=g(Wg);currentStep=ph.required({transform:i3});totalSteps=ph.required({transform:i3});showBack=ph.required({transform:Tu});back=Ahe();next=Ahe();hide=Ahe();form;formErrors={};validationMessages={};ngOnInit(){this.buildForm();let n=DT(this.server.getHTMLConfig().instance.avatars,128);n&&fetch(n.fileUrl).then(e=>e.blob()).then(e=>this.form.patchValue({avatar:e})).catch(()=>{V.error(`Could not fetch instance avatar`)})}get avatarFileConstraints(){return this.server.getHTMLConfig().avatar.file}buildForm(){let n={platformName:$t$1,shortDescription:zt,avatar:null,primaryColor:o},{form:e,formErrors:t,validationMessages:r}=this.formReactiveService.buildForm(n,this.getDefaultValues());this.form=e,this.formErrors=t,this.validationMessages=r}getDefaultValues(){let n=this.server.getHTMLConfig(),e=n.theme.customization.primaryColor,t=e?this.themeService.formatColorForForm(e):this.themeService.formatColorForForm(this.themeService.getCSSConfigValue(`primaryColor`));return{platformName:n.instance.name,shortDescription:n.instance.shortDescription,avatar:void 0,primaryColor:t}}static ɵfac=function(e){return new(e||l)};static ɵcmp=$a({type:l,selectors:[[`my-admin-config-wizard-edit-info`]],inputs:{currentStep:[1,`currentStep`],totalSteps:[1,`totalSteps`],showBack:[1,`showBack`]},outputs:{back:`back`,next:`next`,hide:`hide`},decls:39,vars:15,consts:()=>{let n;n=`PAS ${`�0�`}/${`�1�`}`;let e;e="Informații generale";let t;t="Poți edita aceste informații ulterior";let r;r="Numele platformei";let s;s="Descriere scurtă";let p;p="Pictograma platformei";let I;I="Folosită în diverse locuri precum site-ul web, aplicația mobilă și rețelele sociale";let D;D="Color primar";let x;x="Pasul următor";let k;k="Ignoră pentru moment";let X;return X="Înapoi",[n,e,t,r,s,p,I,D,x,k,X,[1,`root`],[1,`two-columns`],[`src`,`/client/assets/images/mascot/pointing.svg`,`alt`,`mascot`,1,`mascot`],[1,`steps`],[1,`header-steps`],[1,`title`],[1,`text-content`],[3,`formGroup`],[1,`form-group`],[`for`,`platformName`],[`type`,`text`,`id`,`platformName`,`formControlName`,`platformName`,1,`form-control`,3,`ngClass`],[`role`,`alert`,1,`form-error`],[`for`,`shortDescription`],[`id`,`shortDescription`,`formControlName`,`shortDescription`,1,`form-control`,`small`,3,`ngClass`],[`for`,`avatarfile`],[1,`form-group-description`],[`formControlName`,`avatar`,`inputName`,`avatar`,`displayDelete`,`true`,1,`avatar-preview`,3,`fileConstraints`],[`for`,`primaryColor`],[`inputId`,`primaryColor`,`formControlName`,`primaryColor`,3,`formError`],[1,`buttons`],[`icon`,`arrow-left`,`theme`,`secondary`],[`theme`,`primary`,3,`click`,`disabled`],[1,`button-as-link`,3,`click`],[`icon`,`arrow-left`,`theme`,`secondary`,3,`click`]]},template:function(e,t){e&1&&(wp(0,`div`,11)(1,`div`,12)(2,`div`),th(3,`img`,13),Bb(),wp(4,`div`)(5,`div`,14)(6,`div`,15),S$(7,0),Bb()(),wp(8,`h4`,16),S$(9,1),Bb(),wp(10,`div`,17),S$(11,2),Bb(),wp(12,`form`,18)(13,`div`,19)(14,`label`,20),S$(15,3),Bb(),th(16,`input`,21),Vj(),NV(17,Tt,2,1,`div`,22),Bb(),wp(18,`div`,19)(19,`label`,23),S$(20,4),Bb(),th(21,`textarea`,24),Vj(),NV(22,Dt,2,1,`div`,22),Bb(),wp(23,`div`,19)(24,`label`,25),S$(25,5),Bb(),wp(26,`div`,26),S$(27,6),Bb(),th(28,`my-image-input`,27),Vj(),Bb(),wp(29,`div`,19)(30,`label`,28),S$(31,7),Bb(),th(32,`my-peertube-color-picker`,29),Vj(),Bb(),wp(33,`div`,30),NV(34,Ft,2,0,`my-button`,31),wp(35,`my-button`,32),rh(`click`,function(){return t.next.emit(t.form.value)}),S$(36,8),Bb(),wp(37,`button`,33),rh(`click`,function(){return t.hide.emit()}),S$(38,9),Bb()()()()()()),e&2&&($B(7),jx(t.currentStep())(t.totalSteps()),T$(7),$B(5),Ex(`formGroup`,t.form),$B(4),Ex(`ngClass`,h5(11,Nt,t.formErrors.platformName)),Gj(),$B(),MV(t.formErrors.platformName?17:-1),$B(4),Ex(`ngClass`,h5(13,Nt,t.formErrors.shortDescription)),Gj(),$B(),MV(t.formErrors.shortDescription?22:-1),$B(6),Ex(`fileConstraints`,t.avatarFileConstraints),Gj(),$B(4),Ex(`formError`,t.formErrors.primaryColor),Gj(),$B(2),MV(t.showBack()?34:-1),$B(),Ex(`disabled`,!t.form.valid))},dependencies:[Au,O3,Jn,Zn,Je,qn,$n,Qn,Vn,yn,Ke,Le,ce,k],styles:[`form[_ngcontent-%COMP%]{margin-top:calc(1.325rem + .9vw)}@media(min-width:1200px){form[_ngcontent-%COMP%]{margin-top:2rem}}.mascot[_ngcontent-%COMP%]{margin-top:-90px;width:170px;height:190px}.avatar-preview[_ngcontent-%COMP%]{width:128px;height:128px}@media screen and (max-width:800px){.mascot[_ngcontent-%COMP%]{display:none}.two-columns[_ngcontent-%COMP%]{justify-content:center}}textarea[_ngcontent-%COMP%]{min-height:150px}`,`.steps[_ngcontent-%COMP%]{color:var(--%NS%fg-200);font-size:14px;font-weight:700}.title[_ngcontent-%COMP%]{color:var(--%NS%fg-350);font-weight:700;font-size:calc(1.3625rem + 1.35vw)}@media(min-width:1200px){.title[_ngcontent-%COMP%]{font-size:2.375rem}}.sub-title[_ngcontent-%COMP%]{color:var(--%NS%fg-300);font-weight:400;font-size:1.25rem}h4[_ngcontent-%COMP%]{margin-bottom:0}.text-content[_ngcontent-%COMP%]{color:var(--%NS%fg-200)}.buttons[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;justify-content:center;margin-top:calc(1.375rem + 1.5vw)}@media(min-width:1200px){.buttons[_ngcontent-%COMP%]{margin-top:2.5rem}}.buttons[_ngcontent-%COMP%]{gap:calc(1.275rem + .3vw)}@media(min-width:1200px){.buttons[_ngcontent-%COMP%]{gap:1.5rem}}form[_ngcontent-%COMP%]{max-width:512px;width:100%}.two-columns[_ngcontent-%COMP%]{display:flex;gap:1rem}.two-columns.width-50[_ngcontent-%COMP%] > div[_ngcontent-%COMP%]{width:50%}.one-column[_ngcontent-%COMP%]{text-align:center}.one-column[_ngcontent-%COMP%]   .mascot-container[_ngcontent-%COMP%]{position:relative;height:110px;margin:0 auto}.one-column[_ngcontent-%COMP%]   .mascot-container[_ngcontent-%COMP%], .one-column[_ngcontent-%COMP%]   .mascot[_ngcontent-%COMP%]{width:170px}.one-column[_ngcontent-%COMP%]   .mascot[_ngcontent-%COMP%]{position:absolute;top:-100px;left:0;height:190px}h5[_ngcontent-%COMP%]{font-size:1rem;font-weight:700;color:var(--%NS%fg-300)}`],changeDetection:1})};var Oe=class l{el=g(Bn);unsafeHTML=ph.required();ngOnInit(){let n=this.el.nativeElement;n.innerHTML=this.unsafeHTML(),n.ariaHidden=`true`}static ɵfac=function(e){return new(e||l)};static ɵcmp=$a({type:l,selectors:[[`my-custom-icon`]],inputs:{unsafeHTML:[1,`unsafeHTML`]},decls:0,vars:0,template:function(e,t){},styles:[`[_nghost-%COMP%]{display:inline-block;height:24px;width:24px}[_nghost-%COMP%]     svg{vertical-align:bottom;width:inherit;height:inherit}[_nghost-%COMP%]     .feather-flag{margin-left:-1px}`]})};var Se=class l{formReactiveService=g(S);usageType=Rhe.required();form;formErrors={};validationMessages={};registrationOptions=[{id:`open`,label:"Deschis",description:"Oricine se poate înregistra și folosi platforma"},{id:`approval`,label:"Necesită aprobare",description:"Oricine se poate înregistra, dar un moderator trebuie să aprobe contul înainte ca utilizatorul să poată folosi platforma"},{id:`closed`,label:"Închis",description:"Doar un administrator poate crea utilizatori pe platformă"}];importOptions=[{id:`enabled`,label:"Activat",description:`Your community can import videos from remote platforms (YouTube, Vimeo...) and automatically synchronize remote channels`},{id:`disabled`,label:"Dezactivat",description:"Comunitatea ta nu poate importa sau sincroniza conținut de pe platforme externe"}];liveOptions=[{id:`enabled`,label:"Da",description:"Comunitatea ta poate transmite live pe platformă (acest lucru necesită un efort suplimentar de moderare)"},{id:`disabled`,label:"Nu",description:"Comunității tale nu i se permite să ruleze transmisiuni live pe platformă"}];globalSearchOptions=[{id:`enabled`,label:"Activează căutarea globală",description:"Folosește https://sepiasearch.org ca motor de căutare implicit pentru a căuta conținut pe toate platformele PeerTube cunoscute"},{id:`disabled`,label:"Dezactivează căutarea globală",description:"Folosește motorul de căutare al platformei tale, care afișează doar conținut local"}];videoQuotaOptions=Jo();ngOnInit(){this.buildForm(),this.form.valueChanges.subscribe(n=>{this.usageType().patch(n)})}buildForm(){let{form:e,formErrors:t,validationMessages:r}=this.formReactiveService.buildForm({registration:null,remoteImport:null,videoQuota:null,live:null,globalSearch:null},this.usageType());this.form=e,this.formErrors=t,this.validationMessages=r}static ɵfac=function(e){return new(e||l)};static ɵcmp=$a({type:l,selectors:[[`my-community-based-config`]],inputs:{usageType:[1,`usageType`]},outputs:{usageType:`usageTypeChange`},decls:21,vars:6,consts:()=>{let n;n="Politică de înregistrare";let e;e="Cota de videoclipuri pentru utilizatorii noi";let t;t="Import și sincronizare videoclipuri";let r;r="Comunitatea mea poate transmite live";let s;return s="Căutare",[n,e,t,r,s,[3,`formGroup`],[1,`form-group`],[`for`,``],[`inputId`,`registration`,`formControlName`,`registration`,3,`items`],[`inputId`,`videoQuota`,`formControlName`,`videoQuota`,3,`items`],[`for`,`remoteImport`],[`inputId`,`remoteImport`,`formControlName`,`remoteImport`,3,`items`],[`inputId`,`live`,`formControlName`,`live`,3,`items`],[`inputId`,`globalSearch`,`formControlName`,`globalSearch`,3,`items`]]},template:function(e,t){e&1&&(wp(0,`form`,5)(1,`div`,6)(2,`label`,7),S$(3,0),Bb(),th(4,`my-select-options`,8),Vj(),Bb(),wp(5,`div`,6)(6,`label`,7),S$(7,1),Bb(),th(8,`my-select-options`,9),Vj(),Bb(),wp(9,`div`,6)(10,`label`,10),S$(11,2),Bb(),th(12,`my-select-options`,11),Vj(),Bb(),wp(13,`div`,6)(14,`label`,7),S$(15,3),Bb(),th(16,`my-select-options`,12),Vj(),Bb(),wp(17,`div`,6)(18,`label`,7),S$(19,4),Bb(),th(20,`my-select-options`,13),Vj(),Bb()()),e&2&&(Ex(`formGroup`,t.form),$B(4),Ex(`items`,t.registrationOptions),Gj(),$B(4),Ex(`items`,t.videoQuotaOptions),Gj(),$B(4),Ex(`items`,t.importOptions),Gj(),$B(4),Ex(`items`,t.liveOptions),Gj(),$B(4),Ex(`items`,t.globalSearchOptions),Gj())},dependencies:[Jn,Zn,qn,$n,Qn,Vn,yn,Ye,Le,oi],encapsulation:2,changeDetection:1})};var Te=class l{formReactiveService=g(S);usageType=Rhe.required();form;formErrors={};validationMessages={};p2pOptions=[{id:`enabled`,label:"Activat",description:"Activează implicit fluxul P2P pentru utilizatorii anonimi și cei noi"},{id:`disabled`,label:"Dezactivat",description:"Dezactivează fluxul P2P"}];transcriptionOptions=[{id:`enabled`,label:"Activat",description:"Activează transcrierea automată a videoclipurilor pentru a genera automat subtitrări"},{id:`disabled`,label:"Dezactivat",description:"Dezactivează transcrierea automată a videoclipurilor"}];keepOriginalVideoOptions=[{id:`enabled`,label:"Da",description:"Păstrează fișierul original al videoclipului pe server"},{id:`disabled`,label:"Nu",description:"Șterge fișierul original al videoclipului după procesare"}];authenticationOptions=[{id:`local`,label:"Dezactivat",description:"Platforma ta va gestiona înregistrarea și autentificarea utilizatorilor intern"},{id:`ldap`,label:"LDAP",description:"Utilizează LDAP pentru autentificarea utilizatorilor"},{id:`oidc`,label:"OIDC",description:"Utilizează OpenID Connect pentru autentificarea utilizatorilor"},{id:`saml`,label:"SAML",description:"Utilizează SAML 2.0 pentru autentificarea utilizatorilor"}];ngOnInit(){this.buildForm(),this.form.valueChanges.subscribe(n=>{this.usageType().patch(n)})}buildForm(){let{form:e,formErrors:t,validationMessages:r}=this.formReactiveService.buildForm({keepOriginalVideo:null,p2p:null,transcription:null,authType:null},this.usageType());this.form=e,this.formErrors=t,this.validationMessages=r}static ɵfac=function(e){return new(e||l)};static ɵcmp=$a({type:l,selectors:[[`my-institutional-config`]],inputs:{usageType:[1,`usageType`]},outputs:{usageType:`usageTypeChange`},decls:21,vars:5,consts:()=>{let n;n="Salvează o copie a videoclipului încărcat";let e;e="P2P";let t;t=`Ajută platforma ta să distribuie conținut video, dar ${`�#10�`}reduce confidențialitatea ${`�#11�`}${`�/#11�`}${`�/#10�`} utilizatorilor tăi `;let r;r="Transcrierea videoclipului";let s;return s="Autentificare la distanță",[n,e,t,r,s,[3,`formGroup`],[1,`form-group`],[`for`,`keepOriginalVideo`],[`inputId`,`keepOriginalVideo`,`formControlName`,`keepOriginalVideo`,3,`items`],[`for`,`p2p`],[1,`form-group-description`],[`href`,`https://docs.joinpeertube.org/admin/privacy-guide#player-p2p`,`target`,`_blank`],[`iconName`,`external-link`],[`inputId`,`p2p`,`formControlName`,`p2p`,3,`items`],[`for`,`transcription`],[`inputId`,`transcription`,`formControlName`,`transcription`,3,`items`],[`for`,`authType`],[`inputId`,`authType`,`formControlName`,`authType`,3,`items`]]},template:function(e,t){e&1&&(wp(0,`form`,5)(1,`div`,6)(2,`label`,7),S$(3,0),Bb(),th(4,`my-select-options`,8),Vj(),Bb(),wp(5,`div`,6)(6,`label`,9),S$(7,1),Bb(),wp(8,`div`,10),Hx(9,2),wp(10,`a`,11),th(11,`my-global-icon`,12),Bb(),Bx(),Bb(),th(12,`my-select-options`,13),Vj(),Bb(),wp(13,`div`,6)(14,`label`,14),S$(15,3),Bb(),th(16,`my-select-options`,15),Vj(),Bb(),wp(17,`div`,6)(18,`label`,16),S$(19,4),Bb(),th(20,`my-select-options`,17),Vj(),Bb()()),e&2&&(Ex(`formGroup`,t.form),$B(4),Ex(`items`,t.keepOriginalVideoOptions),Gj(),$B(8),Ex(`items`,t.p2pOptions),Gj(),$B(4),Ex(`items`,t.transcriptionOptions),Gj(),$B(4),Ex(`items`,t.authenticationOptions),Gj())},dependencies:[Jn,Zn,qn,$n,Qn,Vn,yn,Ye,Le,oi,X1],encapsulation:2,changeDetection:1})};var De=class l{formReactiveService=g(S);usageType=Rhe.required();form;formErrors={};validationMessages={};importOptions=[{id:`enabled`,label:"Activat",description:"Utilizatorii pot importa videoclipuri de pe platforme externe (YouTube, Vimeo...) și pot sincroniza automat canalele externe"},{id:`disabled`,label:"Dezactivat",description:"Dezactivează importul videoclipurilor și sincronizarea canalelor"}];liveOptions=[{id:`enabled`,label:"Da"},{id:`disabled`,label:"Nu"}];keepOriginalVideoOptions=[{id:`enabled`,label:"Da",description:"Păstrează fișierul original al videoclipului pe server"},{id:`disabled`,label:"Nu",description:"Șterge fișierul original al videoclipului după procesare"}];ngOnInit(){this.buildForm(),this.form.valueChanges.subscribe(n=>{this.usageType().patch(n)})}buildForm(){let{form:e,formErrors:t,validationMessages:r}=this.formReactiveService.buildForm({remoteImport:null,live:null,keepOriginalVideo:null},this.usageType());this.form=e,this.formErrors=t,this.validationMessages=r}static ɵfac=function(e){return new(e||l)};static ɵcmp=$a({type:l,selectors:[[`my-private-instance-config`]],inputs:{usageType:[1,`usageType`]},outputs:{usageType:`usageTypeChange`},decls:13,vars:4,consts:()=>{let n;n="Import și sincronizare videoclipuri";let e;e="Utilizatorii pot transmite fluxuri live";let t;return t="Salvează o copie a videoclipului încărcat",[n,e,t,[3,`formGroup`],[1,`form-group`],[`for`,`remoteImport`],[`inputId`,`remoteImport`,`formControlName`,`remoteImport`,3,`items`],[`for`,`live`],[`inputId`,`live`,`formControlName`,`live`,3,`items`],[`for`,`keepOriginalVideo`],[`inputId`,`keepOriginalVideo`,`formControlName`,`keepOriginalVideo`,3,`items`]]},template:function(e,t){e&1&&(wp(0,`form`,3)(1,`div`,4)(2,`label`,5),S$(3,0),Bb(),th(4,`my-select-options`,6),Vj(),Bb(),wp(5,`div`,4)(6,`label`,7),S$(7,1),Bb(),th(8,`my-select-options`,8),Vj(),Bb(),wp(9,`div`,4)(10,`label`,9),S$(11,2),Bb(),th(12,`my-select-options`,10),Vj(),Bb()()),e&2&&(Ex(`formGroup`,t.form),$B(4),Ex(`items`,t.importOptions),Gj(),$B(4),Ex(`items`,t.liveOptions),Gj(),$B(4),Ex(`items`,t.keepOriginalVideoOptions),Gj())},dependencies:[Jn,Zn,qn,$n,Qn,Vn,yn,Ye,Le,oi],encapsulation:2,changeDetection:1})};var ie=class l{registration;videoQuota;remoteImport;live;globalSearch;defaultPrivacy;defaultCommentPolicy;p2p;federation;keepOriginalVideo;allowReplaceFile;preferDisplayName;transcription;authType;unsafeExplanations=[];config={};plugins=[];constructor(n){for(let[e,t]of Object.entries(n))this[e]=t}static initForCommunity(){let n=new l({registration:`approval`,remoteImport:`disabled`,live:`enabled`,videoQuota:5368709120,globalSearch:`enabled`,defaultPrivacy:sn.PUBLIC,p2p:`enabled`,federation:`enabled`,keepOriginalVideo:`disabled`,allowReplaceFile:`disabled`,defaultCommentPolicy:void 0,authType:void 0,preferDisplayName:void 0,transcription:void 0});return n.compute(),n}static initForPrivateInstance(){let n=new l({registration:`closed`,remoteImport:`enabled`,live:`enabled`,videoQuota:-1,globalSearch:`disabled`,defaultPrivacy:sn.INTERNAL,p2p:`disabled`,federation:`disabled`,keepOriginalVideo:`enabled`,allowReplaceFile:`enabled`,preferDisplayName:`enabled`,defaultCommentPolicy:void 0,authType:void 0,transcription:void 0});return n.compute(),n}static initForInstitution(){let n=new l({registration:`closed`,remoteImport:`enabled`,live:`enabled`,videoQuota:-1,globalSearch:`disabled`,defaultPrivacy:sn.PUBLIC,p2p:`disabled`,keepOriginalVideo:`enabled`,allowReplaceFile:`enabled`,preferDisplayName:`enabled`,authType:`local`,transcription:`enabled`,defaultCommentPolicy:Em.REQUIRES_APPROVAL,federation:void 0});return n.compute(),n}compute(){this.unsafeExplanations=[],this.plugins=[],this.config={},this.computeRegistration(),this.computeDefaultVideoPrivacy(),this.computeVideoQuota(),this.computeKeepOriginalVideo(),this.computeReplaceVideoFile(),this.computeVideoImport(),this.computeStreamLives(),this.computeP2P(),this.computeGlobalSearch(),this.computeDefaultVideoCommentPolicy(),this.computeFederation(),this.computeMiniatureSettings(),this.computeTranscription(),this.computeAuth()}getUnsafeExplanations(){return[...this.unsafeExplanations]}getConfig(){return w({},this.config)}getPlugins(){return[...this.plugins]}patch(n){for(let[e,t]of Object.entries(n))this[e]=t;this.compute()}computeRegistration(){Owe(this.registration)&&(this.registration===`open`?(this.addExplanation("<strong>Allow</strong> any user <strong>to register</strong>"),this.addConfig({signup:{enabled:!0,requiresApproval:!1}})):this.registration===`approval`?(this.addExplanation("Allow users to <strong>apply for registration</strong> on your platform"),this.addConfig({signup:{enabled:!0,requiresApproval:!0}})):this.registration===`closed`&&(this.addExplanation("<strong>Disable</strong> user <strong>registration</strong>"),this.addConfig({signup:{enabled:!1}})),(this.registration===`approval`||this.registration===`open`)&&(this.addExplanation("Require <strong>moderator approval</strong> for videos published by your community"),this.addConfig({autoBlacklist:{videos:{ofUsers:{enabled:!0}}}})))}computeVideoQuota(){Owe(this.videoQuota)&&(this.addConfig({user:{videoQuota:this.videoQuota}}),this.videoQuota===0?this.addExplanation("<strong>Prevent</strong> new users <strong>from uploading videos</strong> (can be changed by moderators)"):this.videoQuota===-1?this.addExplanation("<strong>Not limit the amount of videos</strong> new users can upload"):this.addExplanation(`Set <strong>video quota to ${sAe(this.videoQuota,0)}</strong> for new users (can be changed by moderators)`))}computeVideoImport(){Owe(this.remoteImport)&&(this.addConfig({import:{videos:{http:{enabled:this.remoteImport===`enabled`}},videoChannelSynchronization:{enabled:this.remoteImport===`enabled`}}}),this.remoteImport===`enabled`?this.addExplanation("<strong>Permiteți utilizatorilor dvs. de pe</strong> <strong> să importe și să sincronizeze videoclipuri de pe</strong> de pe platforme externe (YouTube, Vimeo...)"):this.addExplanation("<strong>Împiedicați utilizatorii</strong> <strong> să importe videoclipuri</strong> de pe platforme externe"))}computeStreamLives(){Owe(this.live)&&(this.addConfig({live:{enabled:this.live===`enabled`}}),this.live===`enabled`?(this.plugins.push(`peertube-plugin-livechat`),this.addExplanation("<strong>Permiteți utilizatorilor de pe</strong> <strong> să creeze un flux live pe</strong> și să discute cu spectatorii lor folosind pluginul <strong>Livechat</strong>")):this.addExplanation("<strong>Împiedicați utilizatorii site-ului</strong> să difuzeze fluxuri live pe <strong></strong>"))}computeDefaultVideoPrivacy(){Owe(this.defaultPrivacy)&&(this.addConfig({defaults:{publish:{privacy:this.defaultPrivacy}}}),this.defaultPrivacy===sn.INTERNAL?this.addExplanation("Setați setarea implicită pentru confidențialitatea videoclipurilor din „ <strong>” (</strong> ) la „ <strong>” (Intern)</strong>"):this.defaultPrivacy===sn.PUBLIC&&this.addExplanation("Set the <strong>default video privacy</strong> to <strong>Public</strong>"))}computeDefaultVideoCommentPolicy(){Owe(this.defaultCommentPolicy)&&(this.addConfig({defaults:{publish:{commentsPolicy:this.defaultCommentPolicy}}}),this.addExplanation("<strong>Require approval</strong> by default of new video comment"))}computeP2P(){Owe(this.p2p)&&(this.addConfig({defaults:{p2p:{embed:{enabled:this.p2p===`enabled`},webapp:{enabled:this.p2p===`enabled`}}}}),this.p2p===`enabled`?this.addExplanation("<strong>Enable P2P streaming</strong> by default for anonymous and new users"):this.addExplanation("<strong>Disable P2P streaming</strong> by default for anonymous and new users"))}computeFederation(){Owe(this.federation)&&(this.addConfig({followers:{instance:{enabled:this.federation===`enabled`},channels:{enabled:this.federation===`enabled`}}}),this.federation===`enabled`?this.addExplanation("<strong>Allow</strong> external platforms/users to <strong>subscribe</strong> to your content"):this.addExplanation("<strong>Prevent</strong> external platforms/users to <strong>subscribe to your content</strong>"))}computeKeepOriginalVideo(){Owe(this.keepOriginalVideo)&&(this.addConfig({transcoding:{originalFile:{keep:this.keepOriginalVideo===`enabled`}}}),this.keepOriginalVideo===`enabled`&&this.addExplanation("<strong>Save a copy</strong> of the uploaded video file"))}computeReplaceVideoFile(){Owe(this.allowReplaceFile)&&(this.addConfig({videoFile:{update:{enabled:this.allowReplaceFile===`enabled`}}}),this.allowReplaceFile===`enabled`&&this.addExplanation("<strong>Allow</strong> your users <strong>to replace a video</strong> that has already been published"))}computeMiniatureSettings(){Owe(this.preferDisplayName)&&this.addConfig({client:{videos:{miniature:{preferAuthorDisplayName:this.preferDisplayName===`enabled`}}}})}computeGlobalSearch(){Owe(this.globalSearch)&&(this.addConfig({search:{searchIndex:{enabled:this.globalSearch===`enabled`,isDefaultSearch:this.globalSearch===`enabled`,url:`https://sepiasearch.org`}}}),this.globalSearch===`enabled`&&this.addExplanation("Set <a href=\"https://sepiasearch.org\" target=\"_blank\">SepiaSearch</a> as <strong>default search engine</strong>"))}computeTranscription(){Owe(this.transcription)&&(this.addConfig({videoTranscription:{enabled:this.transcription===`enabled`}}),this.transcription===`enabled`&&this.addExplanation("<strong>Enable automatic transcription</strong> of videos to create subtitles and improve accessibility"))}computeAuth(){if(!Owe(this.authType))return;let n=" The plugin <strong>must be configured</strong> after the pre-configuration wizard confirmation.";this.authType===`ldap`?(this.addExplanation("Install the <strong>LDAP</strong> authentication plugin."+n),this.plugins.push(`peertube-plugin-auth-ldap`)):this.authType===`saml`?(this.addExplanation("Install the <strong>SAML 2.0</strong> authentication plugin."+n),this.plugins.push(`peertube-plugin-auth-saml2`)):this.authType===`oidc`&&(this.addExplanation("Install the <strong>OpenID Connect</strong> authentication plugin."+n),this.plugins.push(`peertube-plugin-auth-openid-connect`))}addConfig(n){return this.config=dBe(this.config,n)}addExplanation(n){this.unsafeExplanations.push(n)}};var yt=l=>({"platform-type-selected":l});function ht(l,n){if(l&1&&th(0,`my-community-based-config`,35),l&2){let e=D$();Ex(`usageType`,e.usageType[e.platformType])}}function Rt(l,n){if(l&1&&th(0,`my-institutional-config`,35),l&2){let e=D$();Ex(`usageType`,e.usageType[e.platformType])}}function bt(l,n){if(l&1&&th(0,`my-private-instance-config`,35),l&2){let e=D$();Ex(`usageType`,e.usageType[e.platformType])}}var Fe=class l{currentStep=ph.required({transform:i3});totalSteps=ph.required({transform:i3});back=Ahe();next=Ahe();hide=Ahe();iconKey=It();iconInstitution=At();platformType;usageType={community:ie.initForCommunity(),institution:ie.initForInstitution(),private:ie.initForPrivateInstance()};static ɵfac=function(e){return new(e||l)};static ɵcmp=$a({type:l,selectors:[[`my-admin-config-wizard-form`]],inputs:{currentStep:[1,`currentStep`],totalSteps:[1,`totalSteps`]},outputs:{back:`back`,next:`next`,hide:`hide`},decls:58,vars:12,consts:()=>{let n;n=`PAS ${`�0�`}/${`�1�`}`;let e;e="Tip de utilizare";let t;t="Platforma mea este mai degrabă...";let r;r="Bazată pe comunitate";let s;s="Activează o comunitate să publice conținut și să interacționeze împreună.";let p;p="Instituțional";let I;I="Pentru a difuza videoclipuri. Recomandat pentru instituții publice, asociații și companii.";let D;D="Personal";let x;x="Doar anumite persoane pot accesa conținutul. Recomandat pentru familii și comunități închise.";let k;k="Înapoi";let X;X="Previzualizează configurația";let A;return A="Ignoră pentru moment",[n,e,t,r,s,p,I,D,x,k,X,A,[1,`root`],[1,`two-columns`,`mb-4`],[`src`,`/client/assets/images/mascot/default.svg`,`alt`,`mascot`,1,`mascot`],[1,`steps`],[1,`header-steps`],[1,`title`],[1,`text-content`],[1,`label`],[1,`two-columns`,`width-50`],[1,`platform-types`,3,`ngClass`],[1,`ul-unstyle`],[1,`platform-type`],[`type`,`radio`,`name`,`platformType`,`id`,`platformTypeCommunity`,`value`,`community`,3,`ngModelChange`,`ngModel`],[`for`,`platformTypeCommunity`],[`iconName`,`users`],[1,`type-label`],[1,`type-description`],[`type`,`radio`,`name`,`platformType`,`id`,`platformTypeInstitution`,`value`,`institution`,3,`ngModelChange`,`ngModel`],[`for`,`platformTypeInstitution`],[3,`unsafeHTML`],[`type`,`radio`,`name`,`platformType`,`id`,`platformTypePrivate`,`value`,`private`,3,`ngModelChange`,`ngModel`],[`for`,`platformTypePrivate`],[1,`platform-config`],[3,`usageType`],[1,`buttons`],[`icon`,`arrow-left`,`theme`,`secondary`,3,`click`],[`theme`,`primary`,3,`click`,`disabled`],[1,`button-as-link`,3,`click`]]},template:function(e,t){e&1&&(wp(0,`div`,12)(1,`div`,13)(2,`div`),th(3,`img`,14),Bb(),wp(4,`div`)(5,`div`,15)(6,`div`,16),S$(7,0),Bb()(),wp(8,`h4`,17),S$(9,1),Bb(),wp(10,`div`,18),J$(11,`You can also edit your platform configuration at a later time`),Bb()()(),wp(12,`div`,19),S$(13,2),Bb(),wp(14,`div`,20)(15,`div`,21)(16,`ul`,22)(17,`li`,23)(18,`input`,24),fA(`ngModelChange`,function(s){return o5(t.platformType,s)||(t.platformType=s),s}),Bb(),Vj(),wp(19,`label`,25)(20,`div`),th(21,`my-global-icon`,26),Bb(),wp(22,`div`)(23,`div`,27),S$(24,3),Bb(),wp(25,`div`,28),S$(26,4),Bb()()()(),wp(27,`li`,23)(28,`input`,29),fA(`ngModelChange`,function(s){return o5(t.platformType,s)||(t.platformType=s),s}),Bb(),Vj(),wp(29,`label`,30)(30,`div`),th(31,`my-custom-icon`,31),Bb(),wp(32,`div`)(33,`div`,27),S$(34,5),Bb(),wp(35,`div`,28),S$(36,6),Bb()()()(),wp(37,`li`,23)(38,`input`,32),fA(`ngModelChange`,function(s){return o5(t.platformType,s)||(t.platformType=s),s}),Bb(),Vj(),wp(39,`label`,33)(40,`div`),th(41,`my-custom-icon`,31),Bb(),wp(42,`div`)(43,`div`,27),S$(44,7),Bb(),wp(45,`div`,28),S$(46,8),Bb()()()()()(),wp(47,`div`,34),NV(48,ht,1,1,`my-community-based-config`,35)(49,Rt,1,1,`my-institutional-config`,35)(50,bt,1,1,`my-private-instance-config`,35),Bb()(),wp(51,`div`,36)(52,`my-button`,37),rh(`click`,function(){return t.back.emit()}),S$(53,9),Bb(),wp(54,`my-button`,38),rh(`click`,function(){return t.next.emit(t.usageType[t.platformType])}),S$(55,10),Bb(),wp(56,`button`,39),rh(`click`,function(){return t.hide.emit()}),S$(57,11),Bb()()()),e&2&&($B(7),jx(t.currentStep())(t.totalSteps()),T$(7),$B(8),Ex(`ngClass`,h5(10,yt,t.platformType)),$B(3),dA(`ngModel`,t.platformType),Gj(),$B(10),dA(`ngModel`,t.platformType),Gj(),$B(3),Ex(`unsafeHTML`,t.iconInstitution),$B(7),dA(`ngModel`,t.platformType),Gj(),$B(3),Ex(`unsafeHTML`,t.iconKey),$B(7),MV(t.platformType===`community`?48:t.platformType===`institution`?49:t.platformType===`private`?50:-1),$B(6),Ex(`disabled`,!t.platformType))},dependencies:[Au,O3,Jn,Je,fn,qn,ln,Qn,Ye,Le,ce,X1,Se,De,Te,Oe],styles:[`.mascot[_ngcontent-%COMP%]{margin-top:-90px;width:170px;height:190px}.two-columns.width-50[_ngcontent-%COMP%]{gap:0}.platform-types[_ngcontent-%COMP%]{display:flex}@media screen and (min-width:800px){.platform-types.platform-type-selected[_ngcontent-%COMP%] + div[_ngcontent-%COMP%]{border-inline-start:1px solid var(--%NS%bg-secondary-450)}.platform-types[_ngcontent-%COMP%] + div[_ngcontent-%COMP%]{padding-inline-start:calc(1.325rem + .9vw)}.platform-types[_ngcontent-%COMP%]{margin-inline-end:calc(1.325rem + .9vw)}}@media screen and (min-width:800px)and (min-width:1200px){.platform-types[_ngcontent-%COMP%] + div[_ngcontent-%COMP%]{padding-inline-start:2rem}}@media screen and (min-width:800px)and (min-width:1200px){.platform-types[_ngcontent-%COMP%]{margin-inline-end:2rem}}@media screen and (max-width:800px){.platform-types.platform-type-selected[_ngcontent-%COMP%] + div[_ngcontent-%COMP%]{border-block-start:1px solid var(--%NS%bg-secondary-450)}.platform-types[_ngcontent-%COMP%] + div[_ngcontent-%COMP%]{padding-top:calc(1.325rem + .9vw)}.platform-types[_ngcontent-%COMP%]{margin-bottom:calc(1.325rem + .9vw)}}@media screen and (max-width:800px)and (min-width:1200px){.platform-types[_ngcontent-%COMP%] + div[_ngcontent-%COMP%]{padding-top:2rem}}@media screen and (max-width:800px)and (min-width:1200px){.platform-types[_ngcontent-%COMP%]{margin-bottom:2rem}}.platform-types[_ngcontent-%COMP%]   ul[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.platform-type[_ngcontent-%COMP%]   label[_ngcontent-%COMP%]{cursor:pointer;display:flex;align-items:center;padding:1rem 1.5rem;gap:1rem;color:var(--%NS%fg-300);border-radius:8px;border:1px solid var(--%NS%bg-secondary-450);margin:0}.platform-type[_ngcontent-%COMP%]   label[_ngcontent-%COMP%]   my-global-icon[_ngcontent-%COMP%], .platform-type[_ngcontent-%COMP%]   label[_ngcontent-%COMP%]   my-custom-icon[_ngcontent-%COMP%]{color:var(--%NS%secondary-icon-color);display:inline-block;width:34px;height:34px;line-height:34px}.platform-type[_ngcontent-%COMP%]   label[_ngcontent-%COMP%]:hover{background-color:var(--%NS%bg-secondary-300)}.platform-type[_ngcontent-%COMP%]   input[type=radio][_ngcontent-%COMP%]{display:none}.type-label[_ngcontent-%COMP%]{color:var(--%NS%fg-400);font-weight:700;font-size:1rem}.type-description[_ngcontent-%COMP%]{font-size:14px;font-weight:400}input[type=radio][_ngcontent-%COMP%]:checked + label[_ngcontent-%COMP%]{border:2px solid var(--%NS%border-primary);margin:-1px;background-color:var(--%NS%bg)}input[type=radio][_ngcontent-%COMP%]:checked + label[_ngcontent-%COMP%]   my-global-icon[_ngcontent-%COMP%], input[type=radio][_ngcontent-%COMP%]:checked + label[_ngcontent-%COMP%]   my-custom-icon[_ngcontent-%COMP%]{color:var(--%NS%border-primary)}@media screen and (max-width:800px){.mascot[_ngcontent-%COMP%]{display:none}.two-columns[_ngcontent-%COMP%]{justify-content:center}.two-columns.width-50[_ngcontent-%COMP%]{flex-direction:column;align-items:center}.two-columns.width-50[_ngcontent-%COMP%] > div[_ngcontent-%COMP%]{width:100%!important}}`,`.steps[_ngcontent-%COMP%]{color:var(--%NS%fg-200);font-size:14px;font-weight:700}.title[_ngcontent-%COMP%]{color:var(--%NS%fg-350);font-weight:700;font-size:calc(1.3625rem + 1.35vw)}@media(min-width:1200px){.title[_ngcontent-%COMP%]{font-size:2.375rem}}.sub-title[_ngcontent-%COMP%]{color:var(--%NS%fg-300);font-weight:400;font-size:1.25rem}h4[_ngcontent-%COMP%]{margin-bottom:0}.text-content[_ngcontent-%COMP%]{color:var(--%NS%fg-200)}.buttons[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;justify-content:center;margin-top:calc(1.375rem + 1.5vw)}@media(min-width:1200px){.buttons[_ngcontent-%COMP%]{margin-top:2.5rem}}.buttons[_ngcontent-%COMP%]{gap:calc(1.275rem + .3vw)}@media(min-width:1200px){.buttons[_ngcontent-%COMP%]{gap:1.5rem}}form[_ngcontent-%COMP%]{max-width:512px;width:100%}.two-columns[_ngcontent-%COMP%]{display:flex;gap:1rem}.two-columns.width-50[_ngcontent-%COMP%] > div[_ngcontent-%COMP%]{width:50%}.one-column[_ngcontent-%COMP%]{text-align:center}.one-column[_ngcontent-%COMP%]   .mascot-container[_ngcontent-%COMP%]{position:relative;height:110px;margin:0 auto}.one-column[_ngcontent-%COMP%]   .mascot-container[_ngcontent-%COMP%], .one-column[_ngcontent-%COMP%]   .mascot[_ngcontent-%COMP%]{width:170px}.one-column[_ngcontent-%COMP%]   .mascot[_ngcontent-%COMP%]{position:absolute;top:-100px;left:0;height:190px}h5[_ngcontent-%COMP%]{font-size:1rem;font-weight:700;color:var(--%NS%fg-300)}`],changeDetection:1})};function vt(l,n){if(l&1&&th(0,`li`,14),l&2){let e=n.$implicit;Ex(`innerHTML`,e,Hw)}}var Ee=class l{adminConfig=g(qe);pluginAPI=g(Xe);notifier=g(Si);html=g(Kc);server=g(Zt);instanceLogo=g(Ze);currentStep=ph.required({transform:i3});totalSteps=ph.required({transform:i3});usageType=ph.required();instanceInfo=ph.required();dryRun=ph.required({transform:Tu});back=Ahe();next=Ahe();hide=Ahe();safeExplanations=[];plugins=[];config={};updating=!1;ngOnChanges(){this.usageType()&&(this.safeExplanations=this.usageType().getUnsafeExplanations().map(n=>this.html.toSimpleSafeHtml(n)),this.config=dBe({instance:{name:this.instanceInfo().platformName,shortDescription:this.instanceInfo().shortDescription},theme:{customization:{primaryColor:this.instanceInfo().primaryColor}}},this.usageType().getConfig()),this.plugins=this.usageType().getPlugins())}confirm(){if(this.dryRun())return this.next.emit();this.updating=!0,this.adminConfig.updateCustomConfig(this.config).pipe(je(()=>{let n=this.instanceInfo().avatar;return n?this.instanceLogo.updateAvatar(n):this.instanceLogo.deleteAvatar()}),je(()=>this.server.resetConfig()),je(()=>Se$1(this.plugins).pipe(cr(n=>this.pluginAPI.install(n)),cf()))).subscribe({next:()=>{this.updating=!1,this.next.emit()},error:n=>{this.notifier.handleError(n),this.updating=!1}})}static ɵfac=function(e){return new(e||l)};static ɵcmp=$a({type:l,selectors:[[`my-admin-config-wizard-preview`]],inputs:{currentStep:[1,`currentStep`],totalSteps:[1,`totalSteps`],usageType:[1,`usageType`],instanceInfo:[1,`instanceInfo`],dryRun:[1,`dryRun`]},outputs:{back:`back`,next:`next`,hide:`hide`},features:[f5([qe,Xe,Ze]),ci],decls:25,vars:4,consts:()=>{let n;n=`PAS ${`�0�`}/${`�1�`}`;let e;e="Previzualizare configurație";let t;t="Dacă confirmi, PeerTube va:";let r;r="Dacă dorești un control mai fin asupra setărilor, configurația platformei tale poate fi ușor modificată după finalizarea asistentului de pre-configurare!";let s;s="Înapoi";let p;p="Confirmă această configurație";let I;return I="Ignoră pentru moment",[n,e,t,r,s,p,I,[1,`root`],[1,`two-columns`],[`src`,`/client/assets/images/mascot/default.svg`,`alt`,`mascot`,1,`mascot`],[1,`steps`],[1,`header-steps`],[1,`title`],[1,`text-content`,`mt-3`],[3,`innerHTML`],[1,`buttons`],[`icon`,`arrow-left`,`theme`,`secondary`,3,`click`],[`theme`,`primary`,3,`click`,`disabled`,`loading`],[1,`button-as-link`,3,`click`]]},template:function(e,t){e&1&&(wp(0,`div`,7)(1,`div`,8)(2,`div`),th(3,`img`,9),Bb(),wp(4,`div`)(5,`div`,10)(6,`div`,11),S$(7,0),Bb()(),wp(8,`h4`,12),S$(9,1),Bb(),wp(10,`div`,13)(11,`p`),S$(12,2),Bb(),wp(13,`ul`),PV(14,vt,1,1,`li`,14,LV),Bb(),wp(16,`p`),S$(17,3),Bb()()()(),wp(18,`div`,15)(19,`my-button`,16),rh(`click`,function(){return t.back.emit()}),S$(20,4),Bb(),wp(21,`my-button`,17),rh(`click`,function(){return t.confirm()}),S$(22,5),Bb(),wp(23,`button`,18),rh(`click`,function(){return t.hide.emit()}),S$(24,6),Bb()()()),e&2&&($B(7),jx(t.currentStep())(t.totalSteps()),T$(7),$B(7),kV(t.safeExplanations),$B(7),Ex(`disabled`,t.updating)(`loading`,t.updating))},dependencies:[Jn,Qn,Ye,Le,ce],styles:[`.steps[_ngcontent-%COMP%]{color:var(--%NS%fg-200);font-size:14px;font-weight:700}.title[_ngcontent-%COMP%]{color:var(--%NS%fg-350);font-weight:700;font-size:calc(1.3625rem + 1.35vw)}@media(min-width:1200px){.title[_ngcontent-%COMP%]{font-size:2.375rem}}.sub-title[_ngcontent-%COMP%]{color:var(--%NS%fg-300);font-weight:400;font-size:1.25rem}h4[_ngcontent-%COMP%]{margin-bottom:0}.text-content[_ngcontent-%COMP%]{color:var(--%NS%fg-200)}.buttons[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;justify-content:center;margin-top:calc(1.375rem + 1.5vw)}@media(min-width:1200px){.buttons[_ngcontent-%COMP%]{margin-top:2.5rem}}.buttons[_ngcontent-%COMP%]{gap:calc(1.275rem + .3vw)}@media(min-width:1200px){.buttons[_ngcontent-%COMP%]{gap:1.5rem}}form[_ngcontent-%COMP%]{max-width:512px;width:100%}.two-columns[_ngcontent-%COMP%]{display:flex;gap:1rem}.two-columns.width-50[_ngcontent-%COMP%] > div[_ngcontent-%COMP%]{width:50%}.one-column[_ngcontent-%COMP%]{text-align:center}.one-column[_ngcontent-%COMP%]   .mascot-container[_ngcontent-%COMP%]{position:relative;height:110px;margin:0 auto}.one-column[_ngcontent-%COMP%]   .mascot-container[_ngcontent-%COMP%], .one-column[_ngcontent-%COMP%]   .mascot[_ngcontent-%COMP%]{width:170px}.one-column[_ngcontent-%COMP%]   .mascot[_ngcontent-%COMP%]{position:absolute;top:-100px;left:0;height:190px}h5[_ngcontent-%COMP%]{font-size:1rem;font-weight:700;color:var(--%NS%fg-300)}`],changeDetection:1})};var Pe=class l{back=Ahe();next=Ahe();hide=Ahe();static ɵfac=function(e){return new(e||l)};static ɵcmp=$a({type:l,selectors:[[`my-admin-config-wizard-welcome`]],outputs:{back:`back`,next:`next`,hide:`hide`},decls:18,vars:0,consts:()=>{let n;n="Bine ai venit la PeerTube";let e;e="stimate administrator!";let t;t=`Sepia, caracatița, are câteva întrebări pentru a te ajuta ${`�#10�`}să preconfigurezi rapid platforma ta${`�/#10�`}.`;let r;r="Hai să începem!";let s;s="Amintește-mi mai târziu";let p;return p="Nu afișa din nou",[n,e,t,r,s,p,[1,`root`,`one-column`],[1,`mascot-container`],[`src`,`/client/assets/images/mascot/happy.svg`,`alt`,`mascot`,1,`mascot`],[1,`title`],[1,`sub-title`],[1,`text-content`,`mt-3`],[1,`buttons`],[`theme`,`primary`,3,`click`],[`theme`,`secondary`,3,`click`],[1,`button-as-link`,3,`click`]]},template:function(e,t){e&1&&(wp(0,`div`,6)(1,`div`,7),th(2,`img`,8),Bb(),wp(3,`h4`)(4,`div`,9),S$(5,0),Bb(),wp(6,`div`,10),S$(7,1),Bb()(),wp(8,`div`,11),Hx(9,2),th(10,`strong`),Bx(),Bb(),wp(11,`div`,12)(12,`my-button`,13),rh(`click`,function(){return t.next.emit()}),S$(13,3),Bb(),wp(14,`my-button`,14),rh(`click`,function(){return t.hide.emit({doNotOpenAgain:!1})}),S$(15,4),Bb(),wp(16,`button`,15),rh(`click`,function(){return t.hide.emit({doNotOpenAgain:!0})}),S$(17,5),Bb()()())},dependencies:[Jn,Qn,Le,ce],styles:[`.steps[_ngcontent-%COMP%]{color:var(--%NS%fg-200);font-size:14px;font-weight:700}.title[_ngcontent-%COMP%]{color:var(--%NS%fg-350);font-weight:700;font-size:calc(1.3625rem + 1.35vw)}@media(min-width:1200px){.title[_ngcontent-%COMP%]{font-size:2.375rem}}.sub-title[_ngcontent-%COMP%]{color:var(--%NS%fg-300);font-weight:400;font-size:1.25rem}h4[_ngcontent-%COMP%]{margin-bottom:0}.text-content[_ngcontent-%COMP%]{color:var(--%NS%fg-200)}.buttons[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;justify-content:center;margin-top:calc(1.375rem + 1.5vw)}@media(min-width:1200px){.buttons[_ngcontent-%COMP%]{margin-top:2.5rem}}.buttons[_ngcontent-%COMP%]{gap:calc(1.275rem + .3vw)}@media(min-width:1200px){.buttons[_ngcontent-%COMP%]{gap:1.5rem}}form[_ngcontent-%COMP%]{max-width:512px;width:100%}.two-columns[_ngcontent-%COMP%]{display:flex;gap:1rem}.two-columns.width-50[_ngcontent-%COMP%] > div[_ngcontent-%COMP%]{width:50%}.one-column[_ngcontent-%COMP%]{text-align:center}.one-column[_ngcontent-%COMP%]   .mascot-container[_ngcontent-%COMP%]{position:relative;height:110px;margin:0 auto}.one-column[_ngcontent-%COMP%]   .mascot-container[_ngcontent-%COMP%], .one-column[_ngcontent-%COMP%]   .mascot[_ngcontent-%COMP%]{width:170px}.one-column[_ngcontent-%COMP%]   .mascot[_ngcontent-%COMP%]{position:absolute;top:-100px;left:0;height:190px}h5[_ngcontent-%COMP%]{font-size:1rem;font-weight:700;color:var(--%NS%fg-300)}`],changeDetection:1})};var Gt=[`modal`];var $t=[`stepper`];function wt(l,n){if(l&1){let e=jV();wp(0,`cdk-step`,3)(1,`my-admin-config-wizard-welcome`,11),rh(`back`,function(){CI(e),D$();return DI(x$(2).previous())})(`next`,function(){CI(e),D$();return DI(x$(2).next())})(`hide`,function(r){CI(e);return DI(D$(2).hide(r))}),Bb()()}}function Lt(l,n){if(l&1){let e=jV();wp(0,`cdk-step`,10)(1,`my-admin-config-wizard-documentation`,12),rh(`hide`,function(){CI(e);return DI(D$(2).hide({doNotOpenAgain:!0}))}),Bb()()}}function Wt(l,n){if(l&1){let e=jV();wp(0,`div`,2)(1,`my-common-stepper`,null,1),NV(3,wt,2,0,`cdk-step`,3),wp(4,`cdk-step`,4)(5,`my-admin-config-wizard-edit-info`,5),rh(`back`,function(){CI(e);return DI(x$(2).previous())})(`next`,function(r){CI(e);let s=x$(2),p=D$();return p.instanceInfo=r,DI(s.next())})(`hide`,function(){CI(e);return DI(D$().hide())}),Bb()(),wp(6,`cdk-step`,6)(7,`my-admin-config-wizard-form`,7),rh(`back`,function(){CI(e);return DI(x$(2).previous())})(`next`,function(r){CI(e);let s=x$(2),p=D$();return p.usageType=r,DI(s.next())})(`hide`,function(){CI(e);return DI(D$().hide())}),Bb()(),wp(8,`cdk-step`,8)(9,`my-admin-config-wizard-preview`,9),rh(`back`,function(){CI(e);return DI(x$(2).previous())})(`next`,function(){CI(e);let r=x$(2),s=D$();return DI(s.showWelcome?r.next():s.hide())})(`hide`,function(){CI(e);return DI(D$().hide())}),Bb()(),NV(10,Lt,2,0,`cdk-step`,10),Bb()()}if(l&2){let e=D$();$B(3),MV(e.showWelcome?3:-1),$B(2),Ex(`currentStep`,e.currentStep())(`showBack`,e.showWelcome),$B(2),Ex(`currentStep`,e.currentStep()),$B(2),Ex(`usageType`,e.usageType)(`instanceInfo`,e.instanceInfo)(`dryRun`,e.dryRun)(`currentStep`,e.currentStep()),$B(),MV(e.showWelcome?10:-1)}}var Ot=class l{modalService=g(sr);userService=g(Qc);notifier=g(Si);modal=Nhe(`modal`);stepper=Nhe(`stepper`);created=Ahe();usageType;instanceInfo;showWelcome;dryRun;modalRef;ngOnInit(){this.created.emit()}shouldAutoOpen(n){return this.modalService.hasOpenModals()?!1:this.getFragment()===`#admin-welcome-wizard`||this.getFragment()===`#admin-welcome-wizard-test`?!0:!(n.noWelcomeModal===!0||Kn.getItem($e())===`true`)}show({showWelcome:n}){this.showWelcome=n,this.dryRun=this.getFragment()===`#admin-welcome-wizard-test`,this.modalRef=this.modalService.open(this.modal(),{centered:!0,backdrop:`static`,keyboard:!1,size:`lg`})}currentStep(){if(!this.stepper())return 0;let n=this.stepper().selectedIndex;return this.showWelcome?n:n+1}totalSteps(){if(!this.stepper())return 0;let n=this.stepper().steps.length;return this.showWelcome?n-1:n}hide(n={}){let{doNotOpenAgain:e=!1}=n;e&&this.doNotOpenAgain(),this.modalRef.close()}doNotOpenAgain(){Kn.setItem($e(),`true`),this.userService.updateMyProfile({noWelcomeModal:!0}).subscribe({next:()=>V.info(`We will not open the welcome modal again.`),error:n=>this.notifier.handleError(n)})}getFragment(){return window.location.hash}static ɵfac=function(e){return new(e||l)};static ɵcmp=$a({type:l,selectors:[[`my-admin-config-wizard-modal`]],viewQuery:function(e,t){e&1&&Wx(t.modal,Gt,5)(t.stepper,$t,5),e&2&&_$(2)},outputs:{created:`created`},decls:2,vars:0,consts:()=>{let n;n="Introducere de bun venit";let e;e="Editează informațiile generale";let t;t="Tip de utilizare";let r;r="Previzualizare configurație";let s;return s="Documentație post-configurare",[[`modal`,``],[`stepper`,``],[1,`modal-body`],[`label`,n],[`label`,e],[`totalSteps`,`3`,3,`back`,`next`,`hide`,`currentStep`,`showBack`],[`label`,t],[`totalSteps`,`3`,3,`back`,`next`,`hide`,`currentStep`],[`label`,r],[`totalSteps`,`3`,3,`back`,`next`,`hide`,`usageType`,`instanceInfo`,`dryRun`,`currentStep`],[`label`,s],[3,`back`,`next`,`hide`],[3,`hide`]]},template:function(e,t){e&1&&lx(0,Wt,11,9,`ng-template`,null,0,_5)},dependencies:[Le,ne,g$1,Pe,Ie,Fe,Ee,Ne],styles:[`.modal-body[_ngcontent-%COMP%]{padding:2rem 3rem}`],changeDetection:1})};export{Ot as AdminConfigWizardModalComponent};
//# debugId=0bbfc3c7-87a2-5c04-88ef-5700b1f0cdb3
//# sourceMappingURL=chunk-DMnt2b4T.js.map