import{L as Lt$1,V as Vt,I as Ii,K as Ke,X as Xe,j as je,$ as $i,q as qi}from'./chunk-C3m-N9OS.js';import{T}from'./chunk-C0mtIoRH.js';import{m as me}from'./chunk-CwqbN2ap.js';import'./chunk-BtfjBYk-.js';import{A as Ae,i as ie$1}from'./chunk-Bac_zSGY.js';import{a}from'./chunk-CuI19v-E.js';import'./chunk-BZydbr1g.js';import{g,r as rr,P as Pc,a as rc,w as wpe,C as Cpe,B as Bn,j,b as Pa,_ as _0,D as D$,f as fx,c as DV,J as Jn,Q as Qn,H as it,s as sp,e as Pp,u as ub,y as yV,i as ix,h as sx,F as Fp,$ as $t$1,I as w,K as Pk,L as qp,O as J$,R as tl,S as qS,U as cl,V as w3,Z as Zn,Y as Je,q as qn,a0 as $n,a1 as Vn,a2 as yn,t as GH,m as _2,z as zB,v as ax,x as vV,a3 as B0,a4 as l$,W as WH,A as w2,a5 as fn,l as ln,T as Tr,a6 as KV,n as Mx,p as e$,N as Nx,a7 as gg,a8 as HUe,a9 as Oe,aa as ge,ab as Qn$1,ac as Vd,ad as ti,ae as R2,af as A2,ag as N2,ah as c$,ai as EV,k as k2,d as $I,aj as IV,G as GI,o as bV,ak as wx,al as H,am as Zt,an as Qh,ao as D,ap as R_e,aq as txe,ar as _pe,as as Yl,at as Mn,au as ow}from'./main-ajlqprgK.js';var Mt=H((Yn,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 ft=H((Bn,Ft)=>{Ft.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 Ee(){return"no_welcome_modal";}var dt=(()=>{class r{hide=Cpe();static ɵfac=function(o){return new(o||r)();};static ɵcmp=Pa({type:r,selectors:[["my-admin-config-wizard-documentation"]],outputs:{hide:"hide"},decls:55,vars:0,consts:()=>{let t;t="Grattis";let o;o="Din plattform \xE4r grundinst\xE4lld!";let e;e="Det \xE4r nu l\xE4ge att l\xE4gga till information om plattformen! "+"[\uFFFD#12\uFFFD|\uFFFD#13\uFFFD|\uFFFD#14\uFFFD|\uFFFD#15\uFFFD|\uFFFD#16\uFFFD]"+"Skapa en beskrivning"+"[\uFFFD/#12\uFFFD|\uFFFD/#13\uFFFD|\uFFFD/#14\uFFFD|\uFFFD/#15\uFFFD|\uFFFD/#16\uFFFD]"+", som anger "+"[\uFFFD#12\uFFFD|\uFFFD#13\uFFFD|\uFFFD#14\uFFFD|\uFFFD#15\uFFFD|\uFFFD#16\uFFFD]"+"vilka ni \xE4r"+"[\uFFFD/#12\uFFFD|\uFFFD/#13\uFFFD|\uFFFD/#14\uFFFD|\uFFFD/#15\uFFFD|\uFFFD/#16\uFFFD]"+", varf\xF6r "+"[\uFFFD#12\uFFFD|\uFFFD#13\uFFFD|\uFFFD#14\uFFFD|\uFFFD#15\uFFFD|\uFFFD#16\uFFFD]"+"ni skapade plattformen"+"[\uFFFD/#12\uFFFD|\uFFFD/#13\uFFFD|\uFFFD/#14\uFFFD|\uFFFD/#15\uFFFD|\uFFFD/#16\uFFFD]"+" och "+"[\uFFFD#12\uFFFD|\uFFFD#13\uFFFD|\uFFFD#14\uFFFD|\uFFFD#15\uFFFD|\uFFFD#16\uFFFD]"+"hur l\xE4nge"+"[\uFFFD/#12\uFFFD|\uFFFD/#13\uFFFD|\uFFFD/#14\uFFFD|\uFFFD/#15\uFFFD|\uFFFD/#16\uFFFD]"+" ni planerar att "+"[\uFFFD#12\uFFFD|\uFFFD#13\uFFFD|\uFFFD#14\uFFFD|\uFFFD#15\uFFFD|\uFFFD#16\uFFFD]"+"driva och underh\xE5lla den"+"[\uFFFD/#12\uFFFD|\uFFFD/#13\uFFFD|\uFFFD/#14\uFFFD|\uFFFD/#15\uFFFD|\uFFFD/#16\uFFFD]"+". Det \xE4r mycket viktigt f\xF6r bes\xF6kare att f\xF6rst\xE5 vilken typ av webbplats de \xE4r p\xE5. ",e=EV(e);let a;a="Anv\xE4ndbara l\xE4nkar";let d;d="Officiella PeerTube-sajten:";let p;p="Bloggpost, f\xE5 hj\xE4lp eller utforska och uppt\xE4cka PeerTube";let A;A="\xD6ppet PeerTube-register:";let E;E="L\xE4gg till din plattform till det \xF6ppna oficiella PeerTube-registret";let x;x="Dokumentation";let k;k="Administrat\xF6r:";let X;X="Hantera anv\xE4ndare, f\xF6lj andra plattform, hantera spammare, konfigurera objektlagring eller fj\xE4rromkodning ...";let O;O="Skapa ditt konto, hantera spellistor, uppt\xE4ck tredjepartsapplikationer \u2026";let R;R="Kommandoradsgr\xE4nssnitt:";let Fe;Fe="Ladda upp eller importera videor, s\xF6k i loggfiler, besk\xE4r lagringskataloger, \xE5terst\xE4ll anv\xE4ndares l\xF6senord \u2026";let Pe;Pe="St\xE4ng";let he;return he="Fyll i plattformsinformation",[t,o,e,a,d,p,A,E,x,k,X,O,R,Fe,Pe,he,[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(o,e){o&1&&(sp(0,"div",16)(1,"div",17)(2,"div",18),Pp(3,"img",19),ub(),sp(4,"h4")(5,"div",20),yV(6,0),ub(),sp(7,"div",21),yV(8,1),ub()()(),sp(9,"div",22)(10,"span",23),ix(11,2),Pp(12,"strong")(13,"strong")(14,"strong")(15,"strong")(16,"strong"),sx(),ub()(),sp(17,"div",22)(18,"h5"),yV(19,3),ub(),sp(20,"ul",23)(21,"li")(22,"a",24),yV(23,4),ub(),sp(24,"span"),yV(25,5),ub()(),sp(26,"li")(27,"a",25),yV(28,6),ub(),sp(29,"span"),yV(30,7),ub()()()(),sp(31,"div",22)(32,"h5"),yV(33,8),ub(),sp(34,"ul",23)(35,"li")(36,"a",26),yV(37,9),ub(),sp(38,"span"),yV(39,10),ub()(),sp(40,"li")(41,"a",27),KV(42,"User:"),ub(),sp(43,"span"),yV(44,11),ub()(),sp(45,"li")(46,"a",28),yV(47,12),ub(),sp(48,"span"),yV(49,13),ub()()()(),sp(50,"div",29)(51,"my-button",30),Fp("click",function(){return e.hide.emit();}),yV(52,14),ub(),sp(53,"my-button",31),Fp("click",function(){return e.hide.emit();}),yV(54,15),ub()()());},dependencies:[it],styles:[".steps[_ngcontent-%COMP%]{color:var(--fg-200);font-size:14px;font-weight:700}.title[_ngcontent-%COMP%]{color:var(--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(--fg-300);font-weight:400;font-size:1.25rem}h4[_ngcontent-%COMP%]{margin-bottom:0}.text-content[_ngcontent-%COMP%]{color:var(--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(--fg-300)}"],changeDetection:1});}return r;})();var mt=r=>({"input-error":r});function St(r,c){if(r&1&&(sp(0,"div",22),KV(1),ub()),r&2){let t=bV();zB(),wx(t.formErrors.platformName);}}function Tt(r,c){if(r&1&&(sp(0,"div",22),KV(1),ub()),r&2){let t=bV();zB(),wx(t.formErrors.shortDescription);}}function Dt(r,c){if(r&1){let t=k2();sp(0,"my-button",34),Fp("click",function(){$I(t);let e=bV();return GI(e.back.emit());}),yV(1,10),ub();}}var ct=(()=>{class r{server=g($t$1);formReactiveService=g(w);themeService=g(Pk);currentStep=qp.required({transform:J$});totalSteps=qp.required({transform:J$});showBack=qp.required({transform:tl});back=Cpe();next=Cpe();hide=Cpe();form;formErrors={};validationMessages={};ngOnInit(){this.buildForm();let t=qS(this.server.getHTMLConfig().instance.avatars,128);t&&fetch(t.fileUrl).then(o=>o.blob()).then(o=>this.form.patchValue({avatar:o})).catch(()=>{j.error("Could not fetch instance avatar");});}get avatarFileConstraints(){return this.server.getHTMLConfig().avatar.file;}buildForm(){let t={platformName:Vt,shortDescription:Lt$1,avatar:null,primaryColor:a},{form:o,formErrors:e,validationMessages:a$1}=this.formReactiveService.buildForm(t,this.getDefaultValues());this.form=o,this.formErrors=e,this.validationMessages=a$1;}getDefaultValues(){let t=this.server.getHTMLConfig(),o=t.theme.customization.primaryColor,e=o?this.themeService.formatColorForForm(o):this.themeService.formatColorForForm(this.themeService.getCSSConfigValue("primaryColor"));return{platformName:t.instance.name,shortDescription:t.instance.shortDescription,avatar:void 0,primaryColor:e};}static ɵfac=function(o){return new(o||r)();};static ɵcmp=Pa({type:r,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 t;t="STEG "+"\uFFFD0\uFFFD"+"/"+"\uFFFD1\uFFFD"+"";let o;o="Generell information";let e;e="Du kan redigera denna information senare";let a;a="Plattformsnamn";let d;d="Kort beskrivning";let p;p="Platformsikon";let A;A="Anv\xE4nds p\xE5 olika platser som p\xE5 webbplatsen, mobilapplikationen, och sociala medier";let E;E="Prim\xE4rf\xE4rg";let x;x="N\xE4sta steg";let k;k="Ignorera f\xF6r tillf\xE4llet";let X;return X="Tillbaka",[t,o,e,a,d,p,A,E,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(o,e){o&1&&(sp(0,"div",11)(1,"div",12)(2,"div"),Pp(3,"img",13),ub(),sp(4,"div")(5,"div",14)(6,"div",15),yV(7,0),ub()(),sp(8,"h4",16),yV(9,1),ub(),sp(10,"div",17),yV(11,2),ub(),sp(12,"form",18)(13,"div",19)(14,"label",20),yV(15,3),ub(),Pp(16,"input",21),GH(),_2(17,St,2,1,"div",22),ub(),sp(18,"div",19)(19,"label",23),yV(20,4),ub(),Pp(21,"textarea",24),GH(),_2(22,Tt,2,1,"div",22),ub(),sp(23,"div",19)(24,"label",25),yV(25,5),ub(),sp(26,"div",26),yV(27,6),ub(),Pp(28,"my-image-input",27),GH(),ub(),sp(29,"div",19)(30,"label",28),yV(31,7),ub(),Pp(32,"my-peertube-color-picker",29),GH(),ub(),sp(33,"div",30),_2(34,Dt,2,0,"my-button",31),sp(35,"my-button",32),Fp("click",function(){return e.next.emit(e.form.value);}),yV(36,8),ub(),sp(37,"button",33),Fp("click",function(){return e.hide.emit();}),yV(38,9),ub()()()()()()),o&2&&(zB(7),ax(e.currentStep())(e.totalSteps()),vV(7),zB(5),B0("formGroup",e.form),zB(4),B0("ngClass",l$(11,mt,e.formErrors.platformName)),WH(),zB(),w2(e.formErrors.platformName?17:-1),zB(4),B0("ngClass",l$(13,mt,e.formErrors.shortDescription)),WH(),zB(),w2(e.formErrors.shortDescription?22:-1),zB(6),B0("fileConstraints",e.avatarFileConstraints),WH(),zB(4),B0("formError",e.formErrors.primaryColor),WH(),zB(2),w2(e.showBack()?34:-1),zB(),B0("disabled",!e.form.valid));},dependencies:[cl,w3,Jn,Zn,Je,qn,$n,Qn,Vn,yn,Ii,Ae,it,me],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(--fg-200);font-size:14px;font-weight:700}.title[_ngcontent-%COMP%]{color:var(--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(--fg-300);font-weight:400;font-size:1.25rem}h4[_ngcontent-%COMP%]{margin-bottom:0}.text-content[_ngcontent-%COMP%]{color:var(--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(--fg-300)}"],changeDetection:1});}return r;})();var pt=(()=>{class r{el=g(Mn);unsafeHTML=qp.required();ngOnInit(){let t=this.el.nativeElement;t.innerHTML=this.unsafeHTML(),t.ariaHidden="true";}static ɵfac=function(o){return new(o||r)();};static ɵcmp=Pa({type:r,selectors:[["my-custom-icon"]],inputs:{unsafeHTML:[1,"unsafeHTML"]},decls:0,vars:0,template:function(o,e){},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}"]});}return r;})();var ut=(()=>{class r{formReactiveService=g(w);usageType=_pe.required();form;formErrors={};validationMessages={};registrationOptions=[{id:"open",label:"\xD6ppen",description:"Vem som helst kan registrera sig och anv\xE4nda plattformen"},{id:"approval",label:"Kr\xE4ver godk\xE4nnande",description:"Vem som helst kan registrera sig, men en moderator m\xE5ste godk\xE4nna kontot innan det kan anv\xE4ndas p\xE5 plattformen"},{id:"closed",label:"St\xE4ngd",description:"Endast en administrat\xF6r kan skapa anv\xE4ndare p\xE5 plattformen"}];importOptions=[{id:"enabled",label:"Aktiverad",description:"Your community can import videos from remote platforms (YouTube, Vimeo...) and automatically synchronize remote channels"},{id:"disabled",label:"Avaktiverad",description:"Din community kan inte importera eller synkronisera material fr\xE5n fj\xE4rrplattformar"}];liveOptions=[{id:"enabled",label:"Ja",description:"Din community kan g\xF6ra direkts\xE4ndningar p\xE5 plattformen (detta kr\xE4ver extra moderering)"},{id:"disabled",label:"Nej",description:"Din community f\xE5r inte g\xF6ra direkts\xE4ndningar p\xE5 plattformen"}];globalSearchOptions=[{id:"enabled",label:"Aktivera global s\xF6kning",description:"Anv\xE4nd https://sepiasearch.org som standards\xF6kmotor f\xF6r att s\xF6ka efter material p\xE5 alla k\xE4nda PeerTube-plattformar"},{id:"disabled",label:"Sl\xE5 av global s\xF6kning",description:"Anv\xE4nd din plattforms s\xF6kmotor som endast visar lokalt material"}];videoQuotaOptions=qi();ngOnInit(){this.buildForm(),this.form.valueChanges.subscribe(t=>{this.usageType().patch(t);});}buildForm(){let t={registration:null,remoteImport:null,videoQuota:null,live:null,globalSearch:null},{form:o,formErrors:e,validationMessages:a}=this.formReactiveService.buildForm(t,this.usageType());this.form=o,this.formErrors=e,this.validationMessages=a;}static ɵfac=function(o){return new(o||r)();};static ɵcmp=Pa({type:r,selectors:[["my-community-based-config"]],inputs:{usageType:[1,"usageType"]},outputs:{usageType:"usageTypeChange"},decls:21,vars:6,consts:()=>{let t;t="Registreringspolicy";let o;o="Videokvot f\xF6r nya anv\xE4ndare";let e;e="Videoimport och -synkronisering";let a;a="Min gemenskap kan str\xF6mma direkts\xE4ndningar";let d;return d="S\xF6k",[t,o,e,a,d,[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(o,e){o&1&&(sp(0,"form",5)(1,"div",6)(2,"label",7),yV(3,0),ub(),Pp(4,"my-select-options",8),GH(),ub(),sp(5,"div",6)(6,"label",7),yV(7,1),ub(),Pp(8,"my-select-options",9),GH(),ub(),sp(9,"div",6)(10,"label",10),yV(11,2),ub(),Pp(12,"my-select-options",11),GH(),ub(),sp(13,"div",6)(14,"label",7),yV(15,3),ub(),Pp(16,"my-select-options",12),GH(),ub(),sp(17,"div",6)(18,"label",7),yV(19,4),ub(),Pp(20,"my-select-options",13),GH(),ub()()),o&2&&(B0("formGroup",e.form),zB(4),B0("items",e.registrationOptions),WH(),zB(4),B0("items",e.videoQuotaOptions),WH(),zB(4),B0("items",e.importOptions),WH(),zB(4),B0("items",e.liveOptions),WH(),zB(4),B0("items",e.globalSearchOptions),WH());},dependencies:[Jn,Zn,qn,$n,Qn,Vn,yn,Ke,Ae,Yl],encapsulation:2,changeDetection:1});}return r;})();var gt=(()=>{class r{formReactiveService=g(w);usageType=_pe.required();form;formErrors={};validationMessages={};p2pOptions=[{id:"enabled",label:"Aktiverad",description:"Sl\xE5 p\xE5 P2P-direkts\xE4ndning som standard f\xF6r anonyma och nya anv\xE4ndare"},{id:"disabled",label:"Avaktiverad",description:"Sl\xE5 av P2P-direkts\xE4ndning"}];transcriptionOptions=[{id:"enabled",label:"Aktiverad",description:"Sl\xE5 p\xE5 automatisk transkription av videor f\xF6r att automatiskt generera undertexter"},{id:"disabled",label:"Avaktiverad",description:"Sl\xE5 av automatisk transkription av videor"}];keepOriginalVideoOptions=[{id:"enabled",label:"Ja",description:"Beh\xE5ll den ursprungliga videofilen p\xE5 servern"},{id:"disabled",label:"Nej",description:"Ta bort den ursprungliga videofilen efter bearbetning"}];authenticationOptions=[{id:"local",label:"Avaktiverad",description:"Din plattform hanterar anv\xE4ndarregistrering och inloggning internt"},{id:"ldap",label:"LDAP",description:"Anv\xE4nd LDAP f\xF6r anv\xE4ndarautentisering"},{id:"oidc",label:"OIDC",description:"Anv\xE4nd OpenID Connect f\xF6r anv\xE4ndarautentisering"},{id:"saml",label:"SAML",description:"Anv\xE4nd SAML 2.0 f\xF6r anv\xE4ndarautentisering"}];ngOnInit(){this.buildForm(),this.form.valueChanges.subscribe(t=>{this.usageType().patch(t);});}buildForm(){let t={keepOriginalVideo:null,p2p:null,transcription:null,authType:null},{form:o,formErrors:e,validationMessages:a}=this.formReactiveService.buildForm(t,this.usageType());this.form=o,this.formErrors=e,this.validationMessages=a;}static ɵfac=function(o){return new(o||r)();};static ɵcmp=Pa({type:r,selectors:[["my-institutional-config"]],inputs:{usageType:[1,"usageType"]},outputs:{usageType:"usageTypeChange"},decls:21,vars:5,consts:()=>{let t;t="Spara en kopia av den uppladdade videon";let o;o="P2P";let e;e="Hj\xE4lper din plattform att distribuera videoinneh\xE5ll, men "+"\uFFFD#10\uFFFD"+"minskar integriteten "+"\uFFFD#11\uFFFD"+""+"\uFFFD/#11\uFFFD"+""+"\uFFFD/#10\uFFFD"+" f\xF6r dina anv\xE4ndare ";let a;a="Videoomkodning";let d;return d="Fj\xE4rrautentisering",[t,o,e,a,d,[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(o,e){o&1&&(sp(0,"form",5)(1,"div",6)(2,"label",7),yV(3,0),ub(),Pp(4,"my-select-options",8),GH(),ub(),sp(5,"div",6)(6,"label",9),yV(7,1),ub(),sp(8,"div",10),ix(9,2),sp(10,"a",11),Pp(11,"my-global-icon",12),ub(),sx(),ub(),Pp(12,"my-select-options",13),GH(),ub(),sp(13,"div",6)(14,"label",14),yV(15,3),ub(),Pp(16,"my-select-options",15),GH(),ub(),sp(17,"div",6)(18,"label",16),yV(19,4),ub(),Pp(20,"my-select-options",17),GH(),ub()()),o&2&&(B0("formGroup",e.form),zB(4),B0("items",e.keepOriginalVideoOptions),WH(),zB(8),B0("items",e.p2pOptions),WH(),zB(4),B0("items",e.transcriptionOptions),WH(),zB(4),B0("items",e.authenticationOptions),WH());},dependencies:[Jn,Zn,qn,$n,Qn,Vn,yn,Ke,Ae,Yl,Tr],encapsulation:2,changeDetection:1});}return r;})();var Ct=(()=>{class r{formReactiveService=g(w);usageType=_pe.required();form;formErrors={};validationMessages={};importOptions=[{id:"enabled",label:"Aktiverad",description:"Anv\xE4ndare kan importera videor fr\xE5n fj\xE4rrplattformar (YouTube, Vimeo ...) och automatiskt synkronisera fj\xE4rrkanaler"},{id:"disabled",label:"Avaktiverad",description:"Sl\xE5 av videoimport och kanalsynkronisering"}];liveOptions=[{id:"enabled",label:"Ja"},{id:"disabled",label:"Nej"}];keepOriginalVideoOptions=[{id:"enabled",label:"Ja",description:"Beh\xE5ll den ursprungliga videofilen p\xE5 servern"},{id:"disabled",label:"Nej",description:"Ta bort den ursprungliga videofilen efter bearbetning"}];ngOnInit(){this.buildForm(),this.form.valueChanges.subscribe(t=>{this.usageType().patch(t);});}buildForm(){let t={remoteImport:null,live:null,keepOriginalVideo:null},{form:o,formErrors:e,validationMessages:a}=this.formReactiveService.buildForm(t,this.usageType());this.form=o,this.formErrors=e,this.validationMessages=a;}static ɵfac=function(o){return new(o||r)();};static ɵcmp=Pa({type:r,selectors:[["my-private-instance-config"]],inputs:{usageType:[1,"usageType"]},outputs:{usageType:"usageTypeChange"},decls:13,vars:4,consts:()=>{let t;t="Videoimport och -synkronisering";let o;o="Anv\xE4ndare kan str\xF6mma direkts\xE4ndningar";let e;return e="Spara en kopia av den uppladdade videon",[t,o,e,[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(o,e){o&1&&(sp(0,"form",3)(1,"div",4)(2,"label",5),yV(3,0),ub(),Pp(4,"my-select-options",6),GH(),ub(),sp(5,"div",4)(6,"label",7),yV(7,1),ub(),Pp(8,"my-select-options",8),GH(),ub(),sp(9,"div",4)(10,"label",9),yV(11,2),ub(),Pp(12,"my-select-options",10),GH(),ub()()),o&2&&(B0("formGroup",e.form),zB(4),B0("items",e.importOptions),WH(),zB(4),B0("items",e.liveOptions),WH(),zB(4),B0("items",e.keepOriginalVideoOptions),WH());},dependencies:[Jn,Zn,qn,$n,Qn,Vn,yn,Ke,Ae,Yl],encapsulation:2,changeDetection:1});}return r;})();var ie=class r{registration;videoQuota;remoteImport;live;globalSearch;defaultPrivacy;defaultCommentPolicy;p2p;federation;keepOriginalVideo;allowReplaceFile;preferDisplayName;transcription;authType;unsafeExplanations=[];config={};plugins=[];constructor(c){for(let[t,o]of Object.entries(c))this[t]=o;}static initForCommunity(){let c=new r({registration:"approval",remoteImport:"disabled",live:"enabled",videoQuota:5368709120,globalSearch:"enabled",defaultPrivacy:Zt.PUBLIC,p2p:"enabled",federation:"enabled",keepOriginalVideo:"disabled",allowReplaceFile:"disabled",defaultCommentPolicy:void 0,authType:void 0,preferDisplayName:void 0,transcription:void 0});return c.compute(),c;}static initForPrivateInstance(){let c=new r({registration:"closed",remoteImport:"enabled",live:"enabled",videoQuota:-1,globalSearch:"disabled",defaultPrivacy:Zt.INTERNAL,p2p:"disabled",federation:"disabled",keepOriginalVideo:"enabled",allowReplaceFile:"enabled",preferDisplayName:"enabled",defaultCommentPolicy:void 0,authType:void 0,transcription:void 0});return c.compute(),c;}static initForInstitution(){let c=new r({registration:"closed",remoteImport:"enabled",live:"enabled",videoQuota:-1,globalSearch:"disabled",defaultPrivacy:Zt.PUBLIC,p2p:"disabled",keepOriginalVideo:"enabled",allowReplaceFile:"enabled",preferDisplayName:"enabled",authType:"local",transcription:"enabled",defaultCommentPolicy:Qh.REQUIRES_APPROVAL,federation:void 0});return c.compute(),c;}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 D({},this.config);}getPlugins(){return[...this.plugins];}patch(c){for(let[t,o]of Object.entries(c))this[t]=o;this.compute();}computeRegistration(){R_e(this.registration)&&(this.registration==="open"?(this.addExplanation("<strong>Till\xE5t</strong> vem som helst <strong>att registrera sig</strong>"),this.addConfig({signup:{enabled:true,requiresApproval:false}})):this.registration==="approval"?(this.addExplanation("Till\xE5t anv\xE4ndare att <strong>ans\xF6ka om registrering</strong> p\xE5 plattformen"),this.addConfig({signup:{enabled:true,requiresApproval:true}})):this.registration==="closed"&&(this.addExplanation("<strong>Sl\xE5 av</strong> m\xF6jlighet f\xF6r anv\xE4ndare att <strong>registrera sig</strong>"),this.addConfig({signup:{enabled:false}})),(this.registration==="approval"||this.registration==="open")&&(this.addExplanation("Kr\xE4v <strong>moderators godk\xE4nnande</strong> f\xF6r videor publicerade av n\xE5gon i gemenskapen"),this.addConfig({autoBlacklist:{videos:{ofUsers:{enabled:true}}}})));}computeVideoQuota(){R_e(this.videoQuota)&&(this.addConfig({user:{videoQuota:this.videoQuota}}),this.videoQuota===0?this.addExplanation("<strong>F\xF6rhindra</strong> nya anv\xE4ndare <strong>fr\xE5n att ladda upp videor</strong> (kan \xE4ndras av moderatorerna)"):this.videoQuota===-1?this.addExplanation("<strong>Begr\xE4nsa inte antalet videor</strong> nya anv\xE4ndare kan ladda upp"):this.addExplanation("S\xE4tt <strong>video-utrymme till "+txe(this.videoQuota,0)+"</strong> f\xF6r nya anv\xE4ndare (kan \xE4ndras av moderatorerna)"));}computeVideoImport(){R_e(this.remoteImport)&&(this.addConfig({import:{videos:{http:{enabled:this.remoteImport==="enabled"}},videoChannelSynchronization:{enabled:this.remoteImport==="enabled"}}}),this.remoteImport==="enabled"?this.addExplanation("<strong>Till\xE5t</strong> anv\xE4ndare <strong>att importera och synkronisera</strong> videor fr\xE5n andra plattformar (YouTube, Vimeo ...)"):this.addExplanation("<strong>Till\xE5t inte</strong> anv\xE4ndare <strong>att importera videor</strong> fr\xE5n andra plattformar"));}computeStreamLives(){R_e(this.live)&&(this.addConfig({live:{enabled:this.live==="enabled"}}),this.live==="enabled"?(this.plugins.push("peertube-plugin-livechat"),this.addExplanation("<strong>Till\xE5t</strong> anv\xE4ndare <strong>att str\xF6mma direkts\xE4ndningar</strong> och att chatta med tittarna genom <strong>Livechat</strong>-till\xE4gget")):this.addExplanation("<strong>Till\xE5t inte</strong> anv\xE4ndarna att <strong>direkts\xE4nda</strong>"));}computeDefaultVideoPrivacy(){R_e(this.defaultPrivacy)&&(this.addConfig({defaults:{publish:{privacy:this.defaultPrivacy}}}),this.defaultPrivacy===Zt.INTERNAL?this.addExplanation("S\xE4tt <strong>video-synlighet</strong> till <strong>Intern</strong> som standard"):this.defaultPrivacy===Zt.PUBLIC&&this.addExplanation("S\xE4tt <strong>video-synlighet</strong> till <strong>\xD6ppet tillg\xE4nglig</strong> som standard"));}computeDefaultVideoCommentPolicy(){R_e(this.defaultCommentPolicy)&&(this.addConfig({defaults:{publish:{commentsPolicy:this.defaultCommentPolicy}}}),this.addExplanation("<strong>Kr\xE4v godk\xE4nnande</strong> f\xF6r nya kommentarer p\xE5 videor"));}computeP2P(){R_e(this.p2p)&&(this.addConfig({defaults:{p2p:{embed:{enabled:this.p2p==="enabled"},webapp:{enabled:this.p2p==="enabled"}}}}),this.p2p==="enabled"?this.addExplanation("<strong>Sl\xE5 p\xE5 P2P-str\xF6mning</strong> som standard f\xF6r anonyma och nya anv\xE4ndare"):this.addExplanation("<strong>Sl\xE5 av P2P-str\xF6mning</strong> som standard f\xF6r anonyma och nya anv\xE4ndare"));}computeFederation(){R_e(this.federation)&&(this.addConfig({followers:{instance:{enabled:this.federation==="enabled"},channels:{enabled:this.federation==="enabled"}}}),this.federation==="enabled"?this.addExplanation("<strong>Till\xE5t</strong> anv\xE4ndare p\xE5 externa plattformar att <strong>prenumerera</strong> p\xE5 inneh\xE5ll fr\xE5n den h\xE4r plattformen"):this.addExplanation("<strong>Till\xE5t inte</strong> anv\xE4ndare p\xE5 externa plattformar att <strong>prenumerera p\xE5 den h\xE4r plattformens inneh\xE5ll</strong>"));}computeKeepOriginalVideo(){R_e(this.keepOriginalVideo)&&(this.addConfig({transcoding:{originalFile:{keep:this.keepOriginalVideo==="enabled"}}}),this.keepOriginalVideo==="enabled"&&this.addExplanation("<strong>Spara en kopia</strong> av den uppladdade videofilen"));}computeReplaceVideoFile(){R_e(this.allowReplaceFile)&&(this.addConfig({videoFile:{update:{enabled:this.allowReplaceFile==="enabled"}}}),this.allowReplaceFile==="enabled"&&this.addExplanation("<strong>Till\xE5t</strong> dina anv\xE4ndare <strong>att ers\xE4tta en video</strong> som redan har publicerats"));}computeMiniatureSettings(){R_e(this.preferDisplayName)&&this.addConfig({client:{videos:{miniature:{preferAuthorDisplayName:this.preferDisplayName==="enabled"}}}});}computeGlobalSearch(){R_e(this.globalSearch)&&(this.addConfig({search:{searchIndex:{enabled:this.globalSearch==="enabled",isDefaultSearch:this.globalSearch==="enabled",url:"https://sepiasearch.org"}}}),this.globalSearch==="enabled"&&this.addExplanation("S\xE4tt <a href=\"https://sepiasearch.org\" target=\"_blank\">SepiaSearch</a> som <strong>standards\xF6kmotor</strong>"));}computeTranscription(){R_e(this.transcription)&&(this.addConfig({videoTranscription:{enabled:this.transcription==="enabled"}}),this.transcription==="enabled"&&this.addExplanation("<strong>Sl\xE5 p\xE5 automatisk transkribering</strong> av videor f\xF6r att skapa undertexter och \xF6ka tillg\xE4ngligheten"));}computeAuth(){if(!R_e(this.authType))return;let c="Till\xE4gget <strong>beh\xF6ver konfigureras</strong> efter att den h\xE4r grundl\xE4ggande konfigurationen av h\xE4lpredan \xE4r klar.";this.authType==="ldap"?(this.addExplanation("Installera till\xE4gget f\xF6r <strong>LDAP</strong> -autentisering."+c),this.plugins.push("peertube-plugin-auth-ldap")):this.authType==="saml"?(this.addExplanation("Installera till\xE4gget f\xF6r <strong>SAML 2.0</strong>-autentisering."+c),this.plugins.push("peertube-plugin-auth-saml2")):this.authType==="oidc"&&(this.addExplanation("Installera till\xE4gget f\xF6r <strong>OpenID Connect</strong>-autentisering."+c),this.plugins.push("peertube-plugin-auth-openid-connect"));}addConfig(c){return this.config=HUe(this.config,c);}addExplanation(c){this.unsafeExplanations.push(c);}};var Pt=r=>({"platform-type-selected":r});function ht(r,c){if(r&1&&Pp(0,"my-community-based-config",35),r&2){let t=bV();B0("usageType",t.usageType[t.platformType]);}}function Rt(r,c){if(r&1&&Pp(0,"my-institutional-config",35),r&2){let t=bV();B0("usageType",t.usageType[t.platformType]);}}function yt(r,c){if(r&1&&Pp(0,"my-private-instance-config",35),r&2){let t=bV();B0("usageType",t.usageType[t.platformType]);}}var It=(()=>{class r{currentStep=qp.required({transform:J$});totalSteps=qp.required({transform:J$});back=Cpe();next=Cpe();hide=Cpe();iconKey=Mt();iconInstitution=ft();platformType;usageType={community:ie.initForCommunity(),institution:ie.initForInstitution(),private:ie.initForPrivateInstance()};static ɵfac=function(o){return new(o||r)();};static ɵcmp=Pa({type:r,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 t;t="STEG "+"\uFFFD0\uFFFD"+"/"+"\uFFFD1\uFFFD"+"";let o;o="Anv\xE4ndningstyp";let e;e="Plattformen \xE4r mer som ...";let a;a="Gemenskaphetsbaserad";let d;d="M\xF6jligg\xF6r f\xF6r er gemenskap att publicera inneh\xE5ll och interagera med varandra.";let p;p="Institutionell";let A;A="F\xF6r att sprida och visa era videor. Rekommenderat f\xF6r offentlig verksamhet, f\xF6reningar och f\xF6retag.";let E;E="Privat";let x;x="Endast vissa personer har \xE5tkomst till inneh\xE5llet. Rekommenderat f\xF6r familjer och avgr\xE4nsade gemenskaper.";let k;k="Tillbaka";let X;X="Granska konfigurationen";let O;return O="Ignorera f\xF6r tillf\xE4llet",[t,o,e,a,d,p,A,E,x,k,X,O,[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(o,e){o&1&&(sp(0,"div",12)(1,"div",13)(2,"div"),Pp(3,"img",14),ub(),sp(4,"div")(5,"div",15)(6,"div",16),yV(7,0),ub()(),sp(8,"h4",17),yV(9,1),ub(),sp(10,"div",18),KV(11,"You can also edit your platform configuration at a later time"),ub()()(),sp(12,"div",19),yV(13,2),ub(),sp(14,"div",20)(15,"div",21)(16,"ul",22)(17,"li",23)(18,"input",24),Mx("ngModelChange",function(d){return e$(e.platformType,d)||(e.platformType=d),d;}),ub(),GH(),sp(19,"label",25)(20,"div"),Pp(21,"my-global-icon",26),ub(),sp(22,"div")(23,"div",27),yV(24,3),ub(),sp(25,"div",28),yV(26,4),ub()()()(),sp(27,"li",23)(28,"input",29),Mx("ngModelChange",function(d){return e$(e.platformType,d)||(e.platformType=d),d;}),ub(),GH(),sp(29,"label",30)(30,"div"),Pp(31,"my-custom-icon",31),ub(),sp(32,"div")(33,"div",27),yV(34,5),ub(),sp(35,"div",28),yV(36,6),ub()()()(),sp(37,"li",23)(38,"input",32),Mx("ngModelChange",function(d){return e$(e.platformType,d)||(e.platformType=d),d;}),ub(),GH(),sp(39,"label",33)(40,"div"),Pp(41,"my-custom-icon",31),ub(),sp(42,"div")(43,"div",27),yV(44,7),ub(),sp(45,"div",28),yV(46,8),ub()()()()()(),sp(47,"div",34),_2(48,ht,1,1,"my-community-based-config",35)(49,Rt,1,1,"my-institutional-config",35)(50,yt,1,1,"my-private-instance-config",35),ub()(),sp(51,"div",36)(52,"my-button",37),Fp("click",function(){return e.back.emit();}),yV(53,9),ub(),sp(54,"my-button",38),Fp("click",function(){return e.next.emit(e.usageType[e.platformType]);}),yV(55,10),ub(),sp(56,"button",39),Fp("click",function(){return e.hide.emit();}),yV(57,11),ub()()()),o&2&&(zB(7),ax(e.currentStep())(e.totalSteps()),vV(7),zB(8),B0("ngClass",l$(10,Pt,e.platformType)),zB(3),Nx("ngModel",e.platformType),WH(),zB(10),Nx("ngModel",e.platformType),WH(),zB(3),B0("unsafeHTML",e.iconInstitution),zB(7),Nx("ngModel",e.platformType),WH(),zB(3),B0("unsafeHTML",e.iconKey),zB(7),w2(e.platformType==="community"?48:e.platformType==="institution"?49:e.platformType==="private"?50:-1),zB(6),B0("disabled",!e.platformType));},dependencies:[cl,w3,Jn,Je,fn,qn,ln,Qn,Ke,Ae,it,Tr,ut,Ct,gt,pt],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(--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(--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(--fg-300);border-radius:8px;border:1px solid var(--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(--secondary-icon-color);display:inline-block;width:34px;height:34px;line-height:34px}.platform-type[_ngcontent-%COMP%]   label[_ngcontent-%COMP%]:hover{background-color:var(--bg-secondary-300)}.platform-type[_ngcontent-%COMP%]   input[type=radio][_ngcontent-%COMP%]{display:none}.type-label[_ngcontent-%COMP%]{color:var(--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(--border-primary);margin:-1px;background-color:var(--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(--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(--fg-200);font-size:14px;font-weight:700}.title[_ngcontent-%COMP%]{color:var(--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(--fg-300);font-weight:400;font-size:1.25rem}h4[_ngcontent-%COMP%]{margin-bottom:0}.text-content[_ngcontent-%COMP%]{color:var(--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(--fg-300)}"],changeDetection:1});}return r;})();function vt(r,c){if(r&1&&Pp(0,"li",14),r&2){let t=c.$implicit;B0("innerHTML",t,ow);}}var Nt=(()=>{class r{adminConfig=g(Xe);pluginAPI=g(je);notifier=g(rc);html=g(gg);server=g($t$1);instanceLogo=g($i);currentStep=qp.required({transform:J$});totalSteps=qp.required({transform:J$});usageType=qp.required();instanceInfo=qp.required();dryRun=qp.required({transform:tl});back=Cpe();next=Cpe();hide=Cpe();safeExplanations=[];plugins=[];config={};updating=false;ngOnChanges(){this.usageType()&&(this.safeExplanations=this.usageType().getUnsafeExplanations().map(t=>this.html.toSimpleSafeHtml(t)),this.config=HUe({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=true,this.adminConfig.updateCustomConfig(this.config).pipe(Oe(()=>{let t=this.instanceInfo().avatar;return t?this.instanceLogo.updateAvatar(t):this.instanceLogo.deleteAvatar();}),Oe(()=>this.server.resetConfig()),Oe(()=>ge(this.plugins).pipe(Qn$1(t=>this.pluginAPI.install(t)),Vd()))).subscribe({next:()=>{this.updating=false,this.next.emit();},error:t=>{this.notifier.handleError(t),this.updating=false;}});}static ɵfac=function(o){return new(o||r)();};static ɵcmp=Pa({type:r,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:[c$([Xe,je,$i]),ti],decls:25,vars:4,consts:()=>{let t;t="STEG "+"\uFFFD0\uFFFD"+"/"+"\uFFFD1\uFFFD"+"";let o;o="F\xF6rhandsgranskning av konfiguration";let e;e="Om du bekr\xE4ftar kommer PeerTube att:";let a;a="Om du vill ha fler inst\xE4llningsm\xF6jligheter kan du enkelt \xE4ndra plattformskonfigurationen efter att du avslutat f\xF6rkonfigurationshj\xE4lpredan!";let d;d="Tillbaka";let p;p="Bekr\xE4fta konfigurationen";let A;return A="Ignorera f\xF6r tillf\xE4llet",[t,o,e,a,d,p,A,[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(o,e){o&1&&(sp(0,"div",7)(1,"div",8)(2,"div"),Pp(3,"img",9),ub(),sp(4,"div")(5,"div",10)(6,"div",11),yV(7,0),ub()(),sp(8,"h4",12),yV(9,1),ub(),sp(10,"div",13)(11,"p"),yV(12,2),ub(),sp(13,"ul"),R2(14,vt,1,1,"li",14,A2),ub(),sp(16,"p"),yV(17,3),ub()()()(),sp(18,"div",15)(19,"my-button",16),Fp("click",function(){return e.back.emit();}),yV(20,4),ub(),sp(21,"my-button",17),Fp("click",function(){return e.confirm();}),yV(22,5),ub(),sp(23,"button",18),Fp("click",function(){return e.hide.emit();}),yV(24,6),ub()()()),o&2&&(zB(7),ax(e.currentStep())(e.totalSteps()),vV(7),zB(7),N2(e.safeExplanations),zB(7),B0("disabled",e.updating)("loading",e.updating));},dependencies:[Jn,Qn,Ke,Ae,it],styles:[".steps[_ngcontent-%COMP%]{color:var(--fg-200);font-size:14px;font-weight:700}.title[_ngcontent-%COMP%]{color:var(--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(--fg-300);font-weight:400;font-size:1.25rem}h4[_ngcontent-%COMP%]{margin-bottom:0}.text-content[_ngcontent-%COMP%]{color:var(--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(--fg-300)}"],changeDetection:1});}return r;})();var At=(()=>{class r{back=Cpe();next=Cpe();hide=Cpe();static ɵfac=function(o){return new(o||r)();};static ɵcmp=Pa({type:r,selectors:[["my-admin-config-wizard-welcome"]],outputs:{back:"back",next:"next",hide:"hide"},decls:18,vars:0,consts:()=>{let t;t="V\xE4lkommen till PeerTube";let o;o="f\xF6r administrat\xF6ren";let e;e="Sepia, bl\xE4ckfisken, har n\xE5gra fr\xE5gor f\xF6r att hj\xE4lpa till att "+"\uFFFD#10\uFFFD"+"snabbt f\xF6rkonfigurera plattformen"+"\uFFFD/#10\uFFFD"+".";let a;a="Nu k\xF6r vi!";let d;d="P\xE5minn mig senare";let p;return p="Visa inte igen",[t,o,e,a,d,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(o,e){o&1&&(sp(0,"div",6)(1,"div",7),Pp(2,"img",8),ub(),sp(3,"h4")(4,"div",9),yV(5,0),ub(),sp(6,"div",10),yV(7,1),ub()(),sp(8,"div",11),ix(9,2),Pp(10,"strong"),sx(),ub(),sp(11,"div",12)(12,"my-button",13),Fp("click",function(){return e.next.emit();}),yV(13,3),ub(),sp(14,"my-button",14),Fp("click",function(){return e.hide.emit({doNotOpenAgain:false});}),yV(15,4),ub(),sp(16,"button",15),Fp("click",function(){return e.hide.emit({doNotOpenAgain:true});}),yV(17,5),ub()()());},dependencies:[Jn,Qn,Ae,it],styles:[".steps[_ngcontent-%COMP%]{color:var(--fg-200);font-size:14px;font-weight:700}.title[_ngcontent-%COMP%]{color:var(--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(--fg-300);font-weight:400;font-size:1.25rem}h4[_ngcontent-%COMP%]{margin-bottom:0}.text-content[_ngcontent-%COMP%]{color:var(--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(--fg-300)}"],changeDetection:1});}return r;})();var bt=["modal"],Gt=["stepper"];function $t(r,c){if(r&1){let t=k2();sp(0,"cdk-step",3)(1,"my-admin-config-wizard-welcome",11),Fp("back",function(){$I(t),bV();let e=IV(2);return GI(e.previous());})("next",function(){$I(t),bV();let e=IV(2);return GI(e.next());})("hide",function(e){$I(t);let a=bV(2);return GI(a.hide(e));}),ub()();}}function Lt(r,c){if(r&1){let t=k2();sp(0,"cdk-step",10)(1,"my-admin-config-wizard-documentation",12),Fp("hide",function(){$I(t);let e=bV(2);return GI(e.hide({doNotOpenAgain:true}));}),ub()();}}function wt(r,c){if(r&1){let t=k2();sp(0,"div",2)(1,"my-common-stepper",null,1),_2(3,$t,2,0,"cdk-step",3),sp(4,"cdk-step",4)(5,"my-admin-config-wizard-edit-info",5),Fp("back",function(){$I(t);let e=IV(2);return GI(e.previous());})("next",function(e){$I(t);let a=IV(2),d=bV();return d.instanceInfo=e,GI(a.next());})("hide",function(){$I(t);let e=bV();return GI(e.hide());}),ub()(),sp(6,"cdk-step",6)(7,"my-admin-config-wizard-form",7),Fp("back",function(){$I(t);let e=IV(2);return GI(e.previous());})("next",function(e){$I(t);let a=IV(2),d=bV();return d.usageType=e,GI(a.next());})("hide",function(){$I(t);let e=bV();return GI(e.hide());}),ub()(),sp(8,"cdk-step",8)(9,"my-admin-config-wizard-preview",9),Fp("back",function(){$I(t);let e=IV(2);return GI(e.previous());})("next",function(){$I(t);let e=IV(2),a=bV();return GI(a.showWelcome?e.next():a.hide());})("hide",function(){$I(t);let e=bV();return GI(e.hide());}),ub()(),_2(10,Lt,2,0,"cdk-step",10),ub()();}if(r&2){let t=bV();zB(3),w2(t.showWelcome?3:-1),zB(2),B0("currentStep",t.currentStep())("showBack",t.showWelcome),zB(2),B0("currentStep",t.currentStep()),zB(2),B0("usageType",t.usageType)("instanceInfo",t.instanceInfo)("dryRun",t.dryRun)("currentStep",t.currentStep()),zB(),w2(t.showWelcome?10:-1);}}var Bo=(()=>{class r{modalService=g(rr);userService=g(Pc);notifier=g(rc);modal=wpe("modal");stepper=wpe("stepper");created=Cpe();usageType;instanceInfo;showWelcome;dryRun;modalRef;ngOnInit(){this.created.emit();}shouldAutoOpen(t){return this.modalService.hasOpenModals()?false:this.getFragment()==="#admin-welcome-wizard"||this.getFragment()==="#admin-welcome-wizard-test"?true:!(t.noWelcomeModal===true||Bn.getItem(Ee())==="true");}show({showWelcome:t}){this.showWelcome=t,this.dryRun=this.getFragment()==="#admin-welcome-wizard-test",this.modalRef=this.modalService.open(this.modal(),{centered:true,backdrop:"static",keyboard:false,size:"lg"});}currentStep(){if(!this.stepper())return 0;let t=this.stepper().selectedIndex;return this.showWelcome?t:t+1;}totalSteps(){if(!this.stepper())return 0;let t=this.stepper().steps.length;return this.showWelcome?t-1:t;}hide(t={}){let{doNotOpenAgain:o=false}=t;o&&this.doNotOpenAgain(),this.modalRef.close();}doNotOpenAgain(){Bn.setItem(Ee(),"true"),this.userService.updateMyProfile({noWelcomeModal:true}).subscribe({next:()=>j.info("We will not open the welcome modal again."),error:t=>this.notifier.handleError(t)});}getFragment(){return window.location.hash;}static ɵfac=function(o){return new(o||r)();};static ɵcmp=Pa({type:r,selectors:[["my-admin-config-wizard-modal"]],viewQuery:function(o,e){o&1&&fx(e.modal,bt,5)(e.stepper,Gt,5),o&2&&DV(2);},outputs:{created:"created"},decls:2,vars:0,consts:()=>{let t;t="V\xE4lkomstintroduktion";let o;o="Redigera generell information";let e;e="Anv\xE4ndningstyp";let a;a="F\xF6rhandsgranskning av konfiguration";let d;return d="Efterkonfigurationsdokumentation",[["modal",""],["stepper",""],[1,"modal-body"],["label",t],["label",o],["totalSteps","3",3,"back","next","hide","currentStep","showBack"],["label",e],["totalSteps","3",3,"back","next","hide","currentStep"],["label",a],["totalSteps","3",3,"back","next","hide","usageType","instanceInfo","dryRun","currentStep"],["label",d],[3,"back","next","hide"],[3,"hide"]];},template:function(o,e){o&1&&_0(0,wt,11,9,"ng-template",null,0,D$);},dependencies:[Ae,ie$1,T,At,ct,It,Nt,dt],styles:[".modal-body[_ngcontent-%COMP%]{padding:2rem 3rem}"],changeDetection:1});}return r;})();/**i18n:fad79908930cbb4c308e7550a5fe49bb3841dbb330066a6429aebaa006173605*/export{Bo as AdminConfigWizardModalComponent};//# sourceMappingURL=chunk-wNAbld7F.js.map