PageSourceSearch

https://exode.me/client/en-US/chunk-2IN5DTZX.js

js exode.me collected 2026-10-04 16:17:16 UTC 51,286 bytes, 11 lines download raw bytes

1import{a as Ft,b as Ue,e as T}from"./chunk-UIL7TNUD.js";import"./chunk-ONJDYF7W.js";import{a as Pt,b as yt,r as v,s as ht,t as bt,v as Ve,w as Be,x as Ye}from"./chunk-THAUX7GZ.js";import{c as Et}from"./chunk-KHC4A3RT.js";import{a as Rt}from"./chunk-BH6MQPW4.js";import"./chunk-U7E76NBH.js";import"./chunk-MBPSVMMT.js";import"./chunk-L435IOLB.js";import"./chunk-R6AMCAHD.js";import"./chunk-EFBJB4GU.js";import"./chunk-MTPQLCOP.js";import{h as ie}from"./chunk-VDA4PBJF.js";import"./chunk-YLZ34D6D.js";import"./chunk-QXVUYXIG.js";import{b as Y}from"./chunk-OR7MKCZD.js";import{c as b}from"./chunk-PG4F5PSG.js";import"./chunk-CIVVPYF3.js";import{E as y,F as h,c as Se,g as R,h as X,o as Ct,p as U,r as Mt,w as V,x as B}from"./chunk-EBOVR5NW.js";import{u as At}from"./chunk-UME7L37K.js";import{a as ye}from"./chunk-R76LZEZS.js";import{Ab as H,Bb as K,C as tt,Ca as l,Cb as a,Cc as M,D as nt,Db as J,Dc as F,Eb as ee,Ec as ke,Fb as pt,Gb as u,Ib as C,Ic as te,If as Fe,Jh as Tt,Lc as Oe,Ma as f,Mc as z,Oh as St,Pe as Nt,Ph as Dt,Q as Ce,Qb as ct,Rb as ut,Rg as Ee,Sa as lt,Sb as W,Sg as Ot,Ta as _t,Ue as E,Vc as Te,Xb as q,Yb as xe,Zc as ft,aa as g,bc as Me,cc as Ie,dc as Ne,ed as ne,fa as A,fb as w,ga as O,gb as L,i as et,ib as st,jb as mt,jc as Ae,kb as dt,lb as s,lc as fe,le as It,mb as i,nb as o,ob as m,qa as ot,ra as it,ta as rt,th as Pe,wc as gt,xe as oe,xf as Xe,ya as at,yb as Q,zf as De}from"./chunk-HVCWS4IF.js";import{a as Ke,e as Je,j as c}from"./chunk-KJ7W2O2B.js";var $t=Je((Po,xt)=>{xt.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">
2  <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" />
3  <circle cx="16.5" cy="7.5" r=".5" fill="currentColor" />
4</svg>
5`;});var wt=Je((yo,kt)=>{kt.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">
6  <path d="M12 12h.01" />
7  <path d="M16 6V4a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v2" />
8  <path d="M22 13a18.15 18.15 0 0 1-20 0" />
9  <rect width="20" height="14" x="2" y="6" rx="2" />
10</svg>
11`;});var j=class j extends Ue{};c(j,"\u0275fac",(()=>{let n;return function(t){return(n||(n=it(j)))(t||j);};})()),c(j,"\u0275cmp",f({type:j,selectors:[["my-admin-config-wizard-stepper"]],features:[Ae([{provide:Ue,useExisting:j}]),lt],decls:2,vars:1,consts:[[3,"ngTemplateOutlet"]],template:function(e,t){e&1&&(i(0,"div"),m(1,"div",0),o()),e&2&&(l(),s("ngTemplateOutlet",t.selected?t.selected.content:null));},dependencies:[ne,ft],encapsulation:2}));var he=j;function je(){return"no_welcome_modal";}var re=class re{hide=M();};c(re,"\u0275fac",function(e){return new(e||re)();}),c(re,"\u0275cmp",f({type:re,selectors:[["my-admin-config-wizard-documentation"]],outputs:{hide:"hide"},decls:55,vars:0,consts:()=>{let n;n="Congratulations";let e;e="Your platform has been configured!";let t;t=" It's time to add information about your platform! "+"[\uFFFD#12\uFFFD|\uFFFD#13\uFFFD|\uFFFD#14\uFFFD|\uFFFD#15\uFFFD|\uFFFD#16\uFFFD]"+"Setting up a description"+"[\uFFFD/#12\uFFFD|\uFFFD/#13\uFFFD|\uFFFD/#14\uFFFD|\uFFFD/#15\uFFFD|\uFFFD/#16\uFFFD]"+", specifying "+"[\uFFFD#12\uFFFD|\uFFFD#13\uFFFD|\uFFFD#14\uFFFD|\uFFFD#15\uFFFD|\uFFFD#16\uFFFD]"+"who you are"+"[\uFFFD/#12\uFFFD|\uFFFD/#13\uFFFD|\uFFFD/#14\uFFFD|\uFFFD/#15\uFFFD|\uFFFD/#16\uFFFD]"+", why "+"[\uFFFD#12\uFFFD|\uFFFD#13\uFFFD|\uFFFD#14\uFFFD|\uFFFD#15\uFFFD|\uFFFD#16\uFFFD]"+"you created your platform"+"[\uFFFD/#12\uFFFD|\uFFFD/#13\uFFFD|\uFFFD/#14\uFFFD|\uFFFD/#15\uFFFD|\uFFFD/#16\uFFFD]"+" and "+"[\uFFFD#12\uFFFD|\uFFFD#13\uFFFD|\uFFFD#14\uFFFD|\uFFFD#15\uFFFD|\uFFFD#16\uFFFD]"+"how long"+"[\uFFFD/#12\uFFFD|\uFFFD/#13\uFFFD|\uFFFD/#14\uFFFD|\uFFFD/#15\uFFFD|\uFFFD/#16\uFFFD]"+" you plan to "+"[\uFFFD#12\uFFFD|\uFFFD#13\uFFFD|\uFFFD#14\uFFFD|\uFFFD#15\uFFFD|\uFFFD#16\uFFFD]"+"maintain it"+"[\uFFFD/#12\uFFFD|\uFFFD/#13\uFFFD|\uFFFD/#14\uFFFD|\uFFFD/#15\uFFFD|\uFFFD/#16\uFFFD]"+" is very important for visitors to understand on what type of website they are. ",t=pt(t);let r;r="Useful links";let _;_="Official PeerTube website:";let p;p="Blog post, get help or discover PeerTube";let I;I="Public PeerTube index:";let S;S="Put your platform on the official PeerTube public index";let Z;Z="Documentation";let x;x="Admin:";let k;k="Managing users, following other platforms, dealing with spammers, configure object storage or remote transcoding...";let N;N="Setup your account, managing video playlists, discover third-party applications...";let P;P="CLI:";let qe;qe="Upload or import videos, parse logs, prune storage directories, reset user password...";let Qe;Qe="Close";let He;return He="Fill platform information",[n,e,t,r,_,p,I,S,Z,x,k,N,P,qe,Qe,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(e,t){e&1&&(i(0,"div",16)(1,"div",17)(2,"div",18),m(3,"img",19),o(),i(4,"h4")(5,"div",20),a(6,0),o(),i(7,"div",21),a(8,1),o()()(),i(9,"div",22)(10,"span",23),H(11,2),m(12,"strong")(13,"strong")(14,"strong")(15,"strong")(16,"strong"),K(),o()(),i(17,"div",22)(18,"h5"),a(19,3),o(),i(20,"ul",23)(21,"li")(22,"a",24),a(23,4),o(),i(24,"span"),a(25,5),o()(),i(26,"li")(27,"a",25),a(28,6),o(),i(29,"span"),a(30,7),o()()()(),i(31,"div",22)(32,"h5"),a(33,8),o(),i(34,"ul",23)(35,"li")(36,"a",26),a(37,9),o(),i(38,"span"),a(39,10),o()(),i(40,"li")(41,"a",27),q(42,"User:"),o(),i(43,"span"),a(44,11),o()(),i(45,"li")(46,"a",28),a(47,12),o(),i(48,"span"),a(49,13),o()()()(),i(50,"div",29)(51,"my-button",30),u("click",function(){return t.hide.emit();}),a(52,14),o(),i(53,"my-button",31),u("click",function(){return t.hide.emit();}),a(54,15),o()()());},dependencies:[b],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)}"]}));var Re=re;var Gt=d=>({"input-error":d});function Wt(d,n){if(d&1&&(i(0,"div",22),q(1),o()),d&2){let e=C();l(),xe(e.formErrors.platformName);}}function zt(d,n){if(d&1&&(i(0,"div",22),q(1),o()),d&2){let e=C();l(),xe(e.formErrors.shortDescription);}}function Zt(d,n){if(d&1){let e=Q();i(0,"my-button",34),u("click",function(){A(e);let r=C();return O(r.back.emit());}),a(1,10),o();}}
11var ae=class ae{server=g(Pe);formReactiveService=g(Y);themeService=g(Dt);currentStep=F.required({transform:z});totalSteps=F.required({transform:z});showBack=F.required({transform:Oe});back=M();next=M();hide=M();form;formErrors={};validationMessages={};ngOnInit(){this.buildForm();let n=Nt(this.server.getHTMLConfig().instance.avatars,128);n&&fetch(n.fileUrl).then(e=>e.blob()).then(e=>this.form.patchValue({avatar:e})).catch(()=>{De.error("Could not fetch instance avatar");});}get avatarFileConstraints(){return this.server.getHTMLConfig().avatar.file;}buildForm(){let n={platformName:Pt,shortDescription:yt,avatar:null,primaryColor:Et},{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};}};c(ae,"\u0275fac",function(e){return new(e||ae)();}),c(ae,"\u0275cmp",f({type:ae,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="STEP "+"\uFFFD0\uFFFD"+"/"+"\uFFFD1\uFFFD"+"";let e;e="General information";let t;t="You can edit this information later";let r;r="Platform name";let _;_="Short description";let p;p="Platform icon";let I;I="Used in various places such as on the website, mobile application and social media";let S;S="Primary color";let Z;Z="Next step";let x;x="Ignore for now";let k;return k="Back",[n,e,t,r,_,p,I,S,Z,x,k,[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&&(i(0,"div",11)(1,"div",12)(2,"div"),m(3,"img",13),o(),i(4,"div")(5,"div",14)(6,"div",15),a(7,0),o()(),i(8,"h4",16),a(9,1),o(),i(10,"div",17),a(11,2),o(),i(12,"form",18)(13,"div",19)(14,"label",20),a(15,3),o(),m(16,"input",21),w(17,Wt,2,1,"div",22),o(),i(18,"div",19)(19,"label",23),a(20,4),o(),m(21,"textarea",24),w(22,zt,2,1,"div",22),o(),i(23,"div",19)(24,"label",25),a(25,5),o(),i(26,"div",26),a(27,6),o(),m(28,"my-image-input",27),o(),i(29,"div",19)(30,"label",28),a(31,7),o(),m(32,"my-peertube-color-picker",29),o(),i(33,"div",30),w(34,Zt,2,0,"my-button",31),i(35,"my-button",32),u("click",function(){return t.next.emit(t.form.value);}),a(36,8),o(),i(37,"button",33),u("click",function(){return t.hide.emit();}),a(38,9),o()()()()()()),e&2&&(l(7),J(t.currentStep())(t.totalSteps()),ee(7),l(5),s("formGroup",t.form),l(4),s("ngClass",fe(11,Gt,t.formErrors.platformName)),l(),L(t.formErrors.platformName?17:-1),l(4),s("ngClass",fe(13,Gt,t.formErrors.shortDescription)),l(),L(t.formErrors.shortDescription?22:-1),l(6),s("fileConstraints",t.avatarFileConstraints),l(4),s("formError",t.formErrors.primaryColor),l(2),L(t.showBack()?34:-1),l(),s("disabled",!t.form.valid));},dependencies:[ne,Te,y,U,Se,R,X,h,B,V,ht,T,b,Rt],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)}"]}));var be=ae;var le=class le{el=g(rt);unsafeHTML=F.required();ngOnInit(){let n=this.el.nativeElement;n.innerHTML=this.unsafeHTML(),n.ariaHidden="true";}};c(le,"\u0275fac",function(e){return new(e||le)();}),c(le,"\u0275cmp",f({type:le,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}"],changeDetection:0}));var Ge=le;var _e=class _e{formReactiveService=g(Y);usageType=te.required();form;formErrors={};validationMessages={};registrationOptions=[{id:"open",label:"Open",description:"Anyone can register and use the platform"},{id:"approval",label:"Requires approval",description:"Anyone can register, but a moderator must approve their account before they can use the platform"},{id:"closed",label:"Closed",description:"Only an administrator can create users on the platform"}];importOptions=[{id:"enabled",label:"Enabled",description:"Your community can import videos from remote platforms (YouTube, Vimeo...) and automatically synchronize remote channels"},{id:"disabled",label:"Disabled",description:"Your community cannot import or synchronize content from remote platforms"}];liveOptions=[{id:"enabled",label:"Yes",description:"Your community can live stream on the platform (this requires extra moderation work)"},{id:"disabled",label:"No",description:"Your community is not permitted to run live streams on the platform"}];globalSearchOptions=[{id:"enabled",label:"Enable global search",description:"Use https://sepiasearch.org as default search engine to search for content across all known PeerTube platforms"},{id:"disabled",label:"Disable global search",description:"Use your platform search engine which only displays local content"}];videoQuotaOptions=bt();ngOnInit(){this.buildForm(),this.form.valueChanges.subscribe(n=>{this.usageType().patch(n);});}buildForm(){let n={registration:null,remoteImport:null,videoQuota:null,live:null,globalSearch:null},{form:e,formErrors:t,validationMessages:r}=this.formReactiveService.buildForm(n,this.usageType());this.form=e,this.formErrors=t,this.validationMessages=r;}};c(_e,"\u0275fac",function(e){return new(e||_e)();}),c(_e,"\u0275cmp",f({type:_e,selectors:[["my-community-based-config"]],inputs:{usageType:[1,"usageType"]},outputs:{usageType:"usageTypeChange"},decls:21,vars:6,consts:()=>{let n;n="Registration policy";let e;e="Video quota for new users";let t;t="Video import and synchronization";let r;r="My community can stream lives";let _;return _="Search",[n,e,t,r,_,[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&&(i(0,"form",5)(1,"div",6)(2,"label",7),a(3,0),o(),m(4,"my-select-options",8),o(),i(5,"div",6)(6,"label",7),a(7,1),o(),m(8,"my-select-options",9),o(),i(9,"div",6)(10,"label",10),a(11,2),o(),m(12,"my-select-options",11),o(),i(13,"div",6)(14,"label",7),a(15,3),o(),m(16,"my-select-options",12),o(),i(17,"div",6)(18,"label",7),a(19,4),o(),m(20,"my-select-options",13),o()()),e&2&&(s("formGroup",t.form),l(4),s("items",t.registrationOptions),l(4),s("items",t.videoQuotaOptions),l(4),s("items",t.importOptions),l(4),s("items",t.liveOptions),l(4),s("items",t.globalSearchOptions));},dependencies:[y,U,R,X,h,B,V,v,T,ie],encapsulation:2}));var $e=_e;var se=class se{formReactiveService=g(Y);usageType=te.required();form;formErrors={};validationMessages={};p2pOptions=[{id:"enabled",label:"Enabled",description:"Enable P2P streaming by default for anonymous and new users"},{id:"disabled",label:"Disabled",description:"Disable P2P streaming"}];transcriptionOptions=[{id:"enabled",label:"Enabled",description:"Enable automatic transcription of videos to automatically generate subtitles"},{id:"disabled",label:"Disabled",description:"Disable automatic transcription of videos"}];keepOriginalVideoOptions=[{id:"enabled",label:"Yes",description:"Keep the original video file on the server"},{id:"disabled",label:"No",description:"Delete the original video file after processing"}];authenticationOptions=[{id:"local",label:"Disabled",description:"Your platform will manage user registration and login internally"},{id:"ldap",label:"LDAP",description:"Use LDAP for user authentication"},{id:"oidc",label:"OIDC",description:"Use OpenID Connect for user authentication"},{id:"saml",label:"SAML",description:"Use SAML 2.0 for user authentication"}];ngOnInit(){this.buildForm(),this.form.valueChanges.subscribe(n=>{this.usageType().patch(n);});}buildForm(){let n={keepOriginalVideo:null,p2p:null,transcription:null,authType:null},{form:e,formErrors:t,validationMessages:r}=this.formReactiveService.buildForm(n,this.usageType());this.form=e,this.formErrors=t,this.validationMessages=r;}};c(se,"\u0275fac",function(e){return new(e||se)();}),c(se,"\u0275cmp",f({type:se,selectors:[["my-institutional-config"]],inputs:{usageType:[1,"usageType"]},outputs:{usageType:"usageTypeChange"},decls:21,vars:5,consts:()=>{let n;n="Save a copy of the uploaded video";let e;e="P2P";let t;t=" Helps your platform to distribute video content, but "+"\uFFFD#10\uFFFD"+"decreases privacy "+"\uFFFD#11\uFFFD"+""+"\uFFFD/#11\uFFFD"+""+"\uFFFD/#10\uFFFD"+" of your users ";let r;r="Video transcription";let _;return _="Remote authentication",[n,e,t,r,_,[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&&(i(0,"form",5)(1,"div",6)(2,"label",7),a(3,0),o(),m(4,"my-select-options",8),o(),i(5,"div",6)(6,"label",9),a(7,1),o(),i(8,"div",10),H(9,2),i(10,"a",11),m(11,"my-global-icon",12),o(),K(),o(),m(12,"my-select-options",13),o(),i(13,"div",6)(14,"label",14),a(15,3),o(),m(16,"my-select-options",15),o(),i(17,"div",6)(18,"label",16),a(19,4),o(),m(20,"my-select-options",17),o()()),e&2&&(s("formGroup",t.form),l(4),s("items",t.keepOriginalVideoOptions),l(8),s("items",t.p2pOptions),l(4),s("items",t.transcriptionOptions),l(4),s("items",t.authenticationOptions));},dependencies:[y,U,R,X,h,B,V,v,T,ie,ye],encapsulation:2}));var we=se;var me=class me{formReactiveService=g(Y);usageType=te.required();form;formErrors={};validationMessages={};importOptions=[{id:"enabled",label:"Enabled",description:"Users can import videos from remote platforms (YouTube, Vimeo...) and automatically synchronize remote channels"},{id:"disabled",label:"Disabled",description:"Disable video import and channel synchronization"}];liveOptions=[{id:"enabled",label:"Yes"},{id:"disabled",label:"No"}];keepOriginalVideoOptions=[{id:"enabled",label:"Yes",description:"Keep the original video file on the server"},{id:"disabled",label:"No",description:"Delete the original video file after processing"}];ngOnInit(){this.buildForm(),this.form.valueChanges.subscribe(n=>{this.usageType().patch(n);});}buildForm(){let n={remoteImport:null,live:null,keepOriginalVideo:null},{form:e,formErrors:t,validationMessages:r}=this.formReactiveService.buildForm(n,this.usageType());this.form=e,this.formErrors=t,this.validationMessages=r;}};c(me,"\u0275fac",function(e){return new(e||me)();}),c(me,"\u0275cmp",f({type:me,selectors:[["my-private-instance-config"]],inputs:{usageType:[1,"usageType"]},outputs:{usageType:"usageTypeChange"},decls:13,vars:4,consts:()=>{let n;n="Video import and synchronization";let e;e="Users can stream lives";let t;return t="Save a copy of the uploaded video",[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&&(i(0,"form",3)(1,"div",4)(2,"label",5),a(3,0),o(),m(4,"my-select-options",6),o(),i(5,"div",4)(6,"label",7),a(7,1),o(),m(8,"my-select-options",8),o(),i(9,"div",4)(10,"label",9),a(11,2),o(),m(12,"my-select-options",10),o()()),e&2&&(s("formGroup",t.form),l(4),s("items",t.importOptions),l(4),s("items",t.liveOptions),l(4),s("items",t.keepOriginalVideoOptions));},dependencies:[y,U,R,X,h,B,V,v,T,ie],encapsulation:2}));var Le=me;var de=class d{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 d({registration:"approval",remoteImport:"disabled",live:"enabled",videoQuota:5368709120,globalSearch:"enabled",defaultPrivacy:oe.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 d({registration:"closed",remoteImport:"enabled",live:"enabled",videoQuota:-1,globalSearch:"disabled",defaultPrivacy:oe.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 d({registration:"closed",remoteImport:"enabled",live:"enabled",videoQuota:-1,globalSearch:"disabled",defaultPrivacy:oe.PUBLIC,p2p:"disabled",keepOriginalVideo:"enabled",allowReplaceFile:"enabled",preferDisplayName:"enabled",authType:"local",transcription:"enabled",defaultCommentPolicy:It.REQUIRES_APPROVAL,federation:void 0});return n.compute(),n;}compute(){this.unsafeExplanations=[],this.plugins=[],this.config={},this.computeRegistration
11(),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 Ke({},this.config);}getPlugins(){return[...this.plugins];}patch(n){for(let[e,t]of Object.entries(n))this[e]=t;this.compute();}computeRegistration(){E(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(){E(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 "+Ot(this.videoQuota,0)+"</strong> for new users (can be changed by moderators)"));}computeVideoImport(){E(this.remoteImport)&&(this.addConfig({import:{videos:{http:{enabled:this.remoteImport==="enabled"}},videoChannelSynchronization:{enabled:this.remoteImport==="enabled"}}}),this.remoteImport==="enabled"?this.addExplanation("<strong>Allow</strong> your users <strong>to import and synchronize</strong> videos from remote platforms (YouTube, Vimeo...)"):this.addExplanation("<strong>Prevent</strong> your users <strong>from importing videos</strong> from remote platforms"));}computeStreamLives(){E(this.live)&&(this.addConfig({live:{enabled:this.live==="enabled"}}),this.live==="enabled"?(this.plugins.push("peertube-plugin-livechat"),this.addExplanation("<strong>Allow</strong> your users <strong>to stream lives</strong> and chat with their viewers using the <strong>Livechat</strong> plugin")):this.addExplanation("<strong>Prevent</strong> your users from running <strong>live streams</strong>"));}computeDefaultVideoPrivacy(){E(this.defaultPrivacy)&&(this.addConfig({defaults:{publish:{privacy:this.defaultPrivacy}}}),this.defaultPrivacy===oe.INTERNAL?this.addExplanation("Set the <strong>default video privacy</strong> to <strong>Internal</strong>"):this.defaultPrivacy===oe.PUBLIC&&this.addExplanation("Set the <strong>default video privacy</strong> to <strong>Public</strong>"));}computeDefaultVideoCommentPolicy(){E(this.defaultCommentPolicy)&&(this.addConfig({defaults:{publish:{commentsPolicy:this.defaultCommentPolicy}}}),this.addExplanation("<strong>Require approval</strong> by default of new video comment"));}computeP2P(){E(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(){E(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(){E(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(){E(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(){E(this.preferDisplayName)&&this.addConfig({client:{videos:{miniature:{preferAuthorDisplayName:this.preferDisplayName==="enabled"}}}});}computeGlobalSearch(){E(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(){E(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(!E(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=Fe(this.config,n);}addExplanation(n){this.unsafeExplanations.push(n);}};var Xt=d=>({"platform-type-selected":d});function Ut(d,n){if(d&1&&m(0,"my-community-based-config",35),d&2){let e=C();s("usageType",e.usageType[e.platformType]);}}function Vt(d,n){if(d&1&&m(0,"my-institutional-config",35),d&2){let e=C();s("usageType",e.usageType[e.platformType]);}}function Bt(d,n){if(d&1&&m(0,"my-private-instance-config",35),d&2){let e=C();s("usageType",e.usageType[e.platformType]);}}var pe=class pe{currentStep=F.required({transform:z});totalSteps=F.required({transform:z});back=M();next=M();hide=M();iconKey=$t();iconInstitution=wt();platformType;usageType={community:de.initForCommunity(),institution:de.initForInstitution(),private:de.initForPrivateInstance()};};c(pe,"\u0275fac",function(e){return new(e||pe)();}),c(pe,"\u0275cmp",f({type:pe,selectors:[["my-admin-config-wizard-form"]],inputs:{currentStep:[1,"currentStep"],totalSteps:[1,"totalSteps"]}
11,outputs:{back:"back",next:"next",hide:"hide"},decls:58,vars:12,consts:()=>{let n;n="STEP "+"\uFFFD0\uFFFD"+"/"+"\uFFFD1\uFFFD"+"";let e;e="Usage type";let t;t="My platform is more like...";let r;r="Community-based";let _;_="Enable a community to publish content and interact together.";let p;p="Institutional";let I;I="To broadcast your videos. Recommended for public institutions, association and companies.";let S;S="Private";let Z;Z="Only certain people can access content. Recommended for families and closed communities.";let x;x="Back";let k;k="Preview configuration";let N;return N="Ignore for now",[n,e,t,r,_,p,I,S,Z,x,k,N,[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&&(i(0,"div",12)(1,"div",13)(2,"div"),m(3,"img",14),o(),i(4,"div")(5,"div",15)(6,"div",16),a(7,0),o()(),i(8,"h4",17),a(9,1),o(),i(10,"div",18),q(11,"You can also edit your platform configuration at a later time"),o()()(),i(12,"div",19),a(13,2),o(),i(14,"div",20)(15,"div",21)(16,"ul",22)(17,"li",23)(18,"input",24),Ne("ngModelChange",function(_){return Ie(t.platformType,_)||(t.platformType=_),_;}),o(),i(19,"label",25)(20,"div"),m(21,"my-global-icon",26),o(),i(22,"div")(23,"div",27),a(24,3),o(),i(25,"div",28),a(26,4),o()()()(),i(27,"li",23)(28,"input",29),Ne("ngModelChange",function(_){return Ie(t.platformType,_)||(t.platformType=_),_;}),o(),i(29,"label",30)(30,"div"),m(31,"my-custom-icon",31),o(),i(32,"div")(33,"div",27),a(34,5),o(),i(35,"div",28),a(36,6),o()()()(),i(37,"li",23)(38,"input",32),Ne("ngModelChange",function(_){return Ie(t.platformType,_)||(t.platformType=_),_;}),o(),i(39,"label",33)(40,"div"),m(41,"my-custom-icon",31),o(),i(42,"div")(43,"div",27),a(44,7),o(),i(45,"div",28),a(46,8),o()()()()()(),i(47,"div",34),w(48,Ut,1,1,"my-community-based-config",35)(49,Vt,1,1,"my-institutional-config",35)(50,Bt,1,1,"my-private-instance-config",35),o()(),i(51,"div",36)(52,"my-button",37),u("click",function(){return t.back.emit();}),a(53,9),o(),i(54,"my-button",38),u("click",function(){return t.next.emit(t.usageType[t.platformType]);}),a(55,10),o(),i(56,"button",39),u("click",function(){return t.hide.emit();}),a(57,11),o()()()),e&2&&(l(7),J(t.currentStep())(t.totalSteps()),ee(7),l(8),s("ngClass",fe(10,Xt,t.platformType)),l(3),Me("ngModel",t.platformType),l(10),Me("ngModel",t.platformType),l(3),s("unsafeHTML",t.iconInstitution),l(7),Me("ngModel",t.platformType),l(3),s("unsafeHTML",t.iconKey),l(7),L(t.platformType==="community"?48:t.platformType==="institution"?49:t.platformType==="private"?50:-1),l(6),s("disabled",!t.platformType));},dependencies:[ne,Te,y,Se,Mt,R,Ct,h,v,T,b,ye,$e,Le,we,Ge],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)}"]}));var We=pe;function Yt(d,n){if(d&1&&m(0,"li",14),d&2){let e=n.$implicit;s("innerHTML",e,at);}}var ce=class ce{adminConfig=g(Ve);pluginAPI=g(Be);notifier=g(Ee);html=g(Tt);
11server=g(Pe);instanceLogo=g(Ye);currentStep=F.required({transform:z});totalSteps=F.required({transform:z});usageType=F.required();instanceInfo=F.required();dryRun=F.required({transform:Oe});back=M();next=M();hide=M();safeExplanations=[];plugins=[];config={};updating=!1;ngOnChanges(){this.usageType()&&(this.safeExplanations=this.usageType().getUnsafeExplanations().map(n=>this.html.toSimpleSafeHtml(n)),this.config=Fe({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(Ce(()=>{let n=this.instanceInfo().avatar;return n?this.instanceLogo.updateAvatar(n):this.instanceLogo.deleteAvatar();}),Ce(()=>this.server.resetConfig()),Ce(()=>et(this.plugins).pipe(nt(n=>this.pluginAPI.install(n)),tt()))).subscribe({next:()=>{this.updating=!1,this.next.emit();},error:n=>{this.notifier.handleError(n),this.updating=!1;}});}};c(ce,"\u0275fac",function(e){return new(e||ce)();}),c(ce,"\u0275cmp",f({type:ce,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:[Ae([Ve,Be,Ye]),ot],decls:25,vars:4,consts:()=>{let n;n="STEP "+"\uFFFD0\uFFFD"+"/"+"\uFFFD1\uFFFD"+"";let e;e="Configuration preview";let t;t="If you confirm, PeerTube will:";let r;r=" If you want finer settings control, your platform configuration can be easily changed after the pre-configuration wizard! ";let _;_="Back";let p;p="Confirm this configuration";let I;return I="Ignore for now",[n,e,t,r,_,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&&(i(0,"div",7)(1,"div",8)(2,"div"),m(3,"img",9),o(),i(4,"div")(5,"div",10)(6,"div",11),a(7,0),o()(),i(8,"h4",12),a(9,1),o(),i(10,"div",13)(11,"p"),a(12,2),o(),i(13,"ul"),mt(14,Yt,1,1,"li",14,st),o(),i(16,"p"),a(17,3),o()()()(),i(18,"div",15)(19,"my-button",16),u("click",function(){return t.back.emit();}),a(20,4),o(),i(21,"my-button",17),u("click",function(){return t.confirm();}),a(22,5),o(),i(23,"button",18),u("click",function(){return t.hide.emit();}),a(24,6),o()()()),e&2&&(l(7),J(t.currentStep())(t.totalSteps()),ee(7),l(7),dt(t.safeExplanations),l(7),s("disabled",t.updating)("loading",t.updating));},dependencies:[y,h,v,T,b],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)}"]}));var ze=ce;var ue=class ue{back=M();next=M();hide=M();};c(ue,"\u0275fac",function(e){return new(e||ue)();}),c(ue,"\u0275cmp",f({type:ue,selectors:[["my-admin-config-wizard-welcome"]],outputs:{back:"back",
11next:"next",hide:"hide"},decls:18,vars:0,consts:()=>{let n;n="Welcome to PeerTube";let e;e="dear administrator!";let t;t="Sepia, the cuttlefish, has a few questions to help you "+"\uFFFD#10\uFFFD"+"quickly pre-configure your platform"+"\uFFFD/#10\uFFFD"+".";let r;r="Let's go!";let _;_="Remind me later";let p;return p="Do not display again",[n,e,t,r,_,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&&(i(0,"div",6)(1,"div",7),m(2,"img",8),o(),i(3,"h4")(4,"div",9),a(5,0),o(),i(6,"div",10),a(7,1),o()(),i(8,"div",11),H(9,2),m(10,"strong"),K(),o(),i(11,"div",12)(12,"my-button",13),u("click",function(){return t.next.emit();}),a(13,3),o(),i(14,"my-button",14),u("click",function(){return t.hide.emit({doNotOpenAgain:!1});}),a(15,4),o(),i(16,"button",15),u("click",function(){return t.hide.emit({doNotOpenAgain:!0});}),a(17,5),o()()());},dependencies:[y,h,T,b],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)}"]}));var Ze=ue;var jt=["modal"],qt=["stepper"];function Qt(d,n){if(d&1){let e=Q();i(0,"cdk-step",3)(1,"my-admin-config-wizard-welcome",11),u("back",function(){A(e),C();let r=W(2);return O(r.previous());})("next",function(){A(e),C();let r=W(2);return O(r.next());})("hide",function(r){A(e);let _=C(2);return O(_.hide(r));}),o()();}}function Ht(d,n){if(d&1){let e=Q();i(0,"cdk-step",10)(1,"my-admin-config-wizard-documentation",12),u("hide",function(){A(e);let r=C(2);return O(r.hide({doNotOpenAgain:!0}));}),o()();}}function Kt(d,n){if(d&1){let e=Q();i(0,"div",2)(1,"my-admin-config-wizard-stepper",null,1),w(3,Qt,2,0,"cdk-step",3),i(4,"cdk-step",4)(5,"my-admin-config-wizard-edit-info",5),u("back",function(){A(e);let r=W(2);return O(r.previous());})("next",function(r){A(e);let _=W(2),p=C();return p.instanceInfo=r,O(_.next());})("hide",function(){A(e);let r=C();return O(r.hide());}),o()(),i(6,"cdk-step",6)(7,"my-admin-config-wizard-form",7),u("back",function(){A(e);let r=W(2);return O(r.previous());})("next",function(r){A(e);let _=W(2),p=C();return p.usageType=r,O(_.next());})("hide",function(){A(e);let r=C();return O(r.hide());}),o()(),i(8,"cdk-step",8)(9,"my-admin-config-wizard-preview",9),u("back",function(){A(e);let r=W(2);return O(r.previous());})("next",function(){A(e);let r=W(2),_=C();return O(_.showWelcome?r.next():_.hide());})("hide",function(){A(e);let r=C();return O(r.hide());}),o()(),w(10,Ht,2,0,"cdk-step",10),o()();}if(d&2){let e=C();l(3),L(e.showWelcome?3:-1),l(2),s("currentStep",e.currentStep())("showBack",e.showWelcome),l(2),s("currentStep",e.currentStep()),l(2),s("usageType",e.usageType)("instanceInfo",e.instanceInfo)("dryRun",e.dryRun)("currentStep",e.currentStep()),l(),L(e.showWelcome?10:-1);}}var ge=class ge{modalService=g(At);userService=g(St);notifier=g(Ee);modal=ke("modal");stepper=ke("stepper");created=M();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||Xe.getItem(je())==="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(){Xe.setItem(je(),"true"),this.userService.updateMyProfile({noWelcomeModal:!0}).subscribe({next:()=>De.info("We will not open the welcome modal again."),error:n=>this.notifier.handleError(n)});}getFragment(){return window.location.hash;}};c(ge,"\u0275fac",function(e){return new(e||ge)();}),c(ge,"\u0275cmp",f({type:ge,selectors:[["my-admin-config-wizard-modal"]],viewQuery:function(e,t){e&1&&ct(t.modal,jt,5)(t.stepper,qt,5),e&2&&ut(2);},outputs:{created:"created"},decls:2,vars:0,consts:()=>{let n;n="Welcome introduction";let e;e="Edit general information";let t;t="Usage type";let r;r="Configuration preview";let _;return _="Post configuration documentation",[["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",_],[3,"back","next","hide"],[3,"hide"]];},template:function(e,t){e&1&&_t(0,Kt,11,9,"ng-template",null,0,gt);},dependencies:[T,Ft,he,Ze,be,We,ze,Re],styles:[".modal-body[_ngcontent-%COMP%]{padding:2rem 3rem}"]}));var Lt=ge;export{Lt as AdminConfigWizardModalComponent};/**i18n:347eeb695970c32bc275618edc2e751c67145d9fc3012e70543c114a99b9e016*/

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.