First
[anni] / static / frontends / pleroma-fe / dev1 / static / js / 9801.d57b3706e7d0e36264a2.js
1 "use strict";(self.webpackChunkpleroma_fe=self.webpackChunkpleroma_fe||[]).push([[9801],{9541:(t,e,n)=>{n.r(e),n.d(e,{default:()=>te});var a=n(66252),i=n(3577),r=["label"],l=["label"],s={class:"setting-item"},o={href:"https://docs-develop.pleroma.social/backend/configuration/howto_database_config/",target:"_blank"},d=(0,a._)("code",null,"config :pleroma, configurable_from_database",-1),c=(0,a._)("code",null,"true",-1),u=["label"],p=["label"],m=["label"],f=n(79354),h=["label"],_={class:"setting-item"},b={class:"setting-list"},g={class:"setting-item"},w={class:"setting-list"},y={class:"setting-list suboptions"},v={class:"setting-list suboptions"},k={class:"setting-list"},O={class:"setting-list suboptions"},D={key:0},S={class:"setting-list"},j={class:"setting-item"},P={class:"setting-list"},$={key:0},W={class:"setting-list"},z={class:"setting-list"},Z={class:"setting-list"},C={class:"setting-list"},L=n(4942),I=n(59236),q=n(77218),M=n(87449),E={key:0,class:"StringSetting"},U=["for"],x=["id","disabled","value"],B=n(7761);function A(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,a)}return n}const F=function(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?A(Object(n),!0).forEach((function(e){(0,L.Z)(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):A(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}({},B.Z);var T=n(83744);const Y=(0,T.Z)(F,[["render",function(t,e,n,r,l,s){var o=(0,a.up)("ModifiedIndicator"),d=(0,a.up)("ProfileSettingIndicator"),c=(0,a.up)("DraftButtons");return t.matchesExpertLevel?((0,a.wg)(),(0,a.iD)("label",E,[(0,a._)("label",{for:t.path,class:(0,i.C_)({faint:t.shouldBeDisabled})},[t.backendDescriptionLabel?((0,a.wg)(),(0,a.iD)(a.HY,{key:0},[(0,a.Uk)((0,i.zw)(t.backendDescriptionLabel+" "),1)],64)):"admin"===t.source?((0,a.wg)(),(0,a.iD)(a.HY,{key:1},[(0,a.Uk)(" MISSING LABEL FOR "+(0,i.zw)(t.path),1)],64)):(0,a.WI)(t.$slots,"default",{key:2})],10,U),(0,a._)("input",{id:t.path,class:"string-input",disabled:t.shouldBeDisabled,value:t.realDraftMode?t.draft:t.state,onChange:e[0]||(e[0]=function(){return t.update&&t.update.apply(t,arguments)})},null,40,x),(0,a.Uk)(" "+(0,i.zw)(" ")+" "),(0,a.Wm)(o,{changed:t.isChanged,onclick:t.reset},null,8,["changed","onclick"]),(0,a.Wm)(d,{"is-profile":t.isProfileSetting},null,8,["is-profile"]),(0,a.Wm)(c),t.backendDescriptionDescription?((0,a.wg)(),(0,a.iD)("p",{key:0,class:(0,i.C_)(["setting-description",{faint:t.shouldBeDisabled}])},(0,i.zw)(t.backendDescriptionDescription+" "),3)):(0,a.kq)("",!0)])):(0,a.kq)("",!0)}]]);var H={key:0,class:"GroupSetting"},G=n(18446),K=n.n(G);function N(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,a)}return n}function R(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?N(Object(n),!0).forEach((function(e){(0,L.Z)(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):N(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}const V=R(R({},B.Z),{},{computed:R(R({},B.Z.computed),{},{isDirty:function(){return!K()(this.state,this.draft)}})}),X=(0,T.Z)(V,[["render",function(t,e,n,i,r,l){var s=(0,a.up)("ModifiedIndicator"),o=(0,a.up)("ProfileSettingIndicator"),d=(0,a.up)("DraftButtons");return t.matchesExpertLevel?((0,a.wg)(),(0,a.iD)("span",H,[(0,a.Wm)(s,{changed:t.isChanged,onclick:t.reset},null,8,["changed","onclick"]),(0,a.Wm)(o,{"is-profile":t.isProfileSetting},null,8,["is-profile"]),(0,a.Wm)(d)])):(0,a.kq)("",!0)}]]);var J={key:0,class:"AttachmentSetting"},Q=["for"],tt={class:"attachment-input"},et={class:"controls"},nt=["id","disabled","value"],at={class:"controls"},it=n(58394),rt=n(37804),lt=n(66596);function st(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,a)}return n}function ot(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?st(Object(n),!0).forEach((function(e){(0,L.Z)(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):st(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}const dt=ot(ot({},B.Z),{},{props:ot(ot({},B.Z.props),{},{acceptTypes:{type:String,required:!1,default:"image/*"}}),components:ot(ot({},B.Z.components),{},{MediaUpload:rt.Z,Attachment:lt.Z}),computed:ot(ot({},B.Z.computed),{},{attachment:function(){var t=this.realDraftMode?this.draft:this.state,e=t.includes("://")?t:this.$store.state.instance.server+t;return{mimetype:(0,it.iL)(e),url:e}}}),methods:ot(ot({},B.Z.methods),{},{setMediaFile:function(t){this.realDraftMode?this.draft=t.url:this.configSink(this.path,t.url)}})}),ct=(0,T.Z)(dt,[["render",function(t,e,n,r,l,s){var o=(0,a.up)("ModifiedIndicator"),d=(0,a.up)("ProfileSettingIndicator"),c=(0,a.up)("Attachment"),u=(0,a.up)("MediaUpload"),p=(0,a.up)("DraftButtons");return t.matchesExpertLevel?((0,a.wg)(),(0,a.iD)("span",J,[(0,a._)("label",{for:t.path,class:(0,i.C_)({faint:t.shouldBeDisabled})},[t.backendDescriptionLabel?((0,a.wg)(),(0,a.iD)(a.HY,{key:0},[(0,a.Uk)((0,i.zw)(t.backendDescriptionLabel+" "),1)],64)):"admin"===t.source?((0,a.wg)(),(0,a.iD)(a.HY,{key:1},[(0,a.Uk)(" MISSING LABEL FOR "+(0,i.zw)(t.path),1)],64)):(0,a.WI)(t.$slots,"default",{key:2})],10,Q),t.backendDescriptionDescription?((0,a.wg)(),(0,a.iD)("p",{key:0,class:(0,i.C_)(["setting-description",{faint:t.shouldBeDisabled}])},(0,i.zw)(t.backendDescriptionDescription+" "),3)):(0,a.kq)("",!0),(0,a._)("div",tt,[(0,a._)("div",null,(0,i.zw)(t.$t("settings.url")),1),(0,a._)("div",et,[(0,a._)("input",{id:t.path,class:"string-input",disabled:t.shouldBeDisabled,value:t.realDraftMode?t.draft:t.state,onChange:e[0]||(e[0]=function(){return t.update&&t.update.apply(t,arguments)})},null,40,nt),(0,a.Uk)(" "+(0,i.zw)(" ")+" "),(0,a.Wm)(o,{changed:t.isChanged,onclick:t.reset},null,8,["changed","onclick"]),(0,a.Wm)(d,{"is-profile":t.isProfileSetting},null,8,["is-profile"])]),(0,a._)("div",null,(0,i.zw)(t.$t("settings.preview")),1),(0,a.Wm)(c,{class:"attachment",compact:t.compact,attachment:t.attachment,size:"small","hide-description":"",onSetMedia:t.onMedia,onNaturalSizeLoad:t.onNaturalSizeLoad},null,8,["compact","attachment","onSetMedia","onNaturalSizeLoad"]),(0,a._)("div",at,[(0,a.Wm)(u,{ref:"mediaUpload",class:"media-upload-icon","drop-files":t.dropFiles,"normal-button":"","accept-types":t.acceptTypes,onUploaded:t.setMediaFile,onUploadFailed:t.uploadFailed},null,8,["drop-files","accept-types","onUploaded","onUploadFailed"])])]),(0,a.Wm)(p)])):(0,a.kq)("",!0)}]]);var ut=n(76875),pt=n(9382),mt=n(84131);function ft(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,a)}return n}pt.vI.add(mt.g4A);const ht={provide:function(){return{defaultDraftMode:!0,defaultSource:"admin"}},components:{BooleanSetting:I.Z,ChoiceSetting:q.Z,IntegerSetting:M.Z,StringSetting:Y,AttachmentSetting:ct,GroupSetting:X},computed:function(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?ft(Object(n),!0).forEach((function(e){(0,L.Z)(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):ft(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}({},(0,ut.Z)())},_t=(0,T.Z)(ht,[["render",function(t,e,n,r,l,s){var o=(0,a.up)("StringSetting"),d=(0,a.up)("AttachmentSetting"),c=(0,a.up)("BooleanSetting"),u=(0,a.up)("IntegerSetting"),p=(0,a.up)("ChoiceSetting"),m=(0,a.up)("GroupSetting");return(0,a.wg)(),(0,a.iD)("div",{label:t.$t("admin_dash.tabs.instance")},[(0,a._)("div",_,[(0,a._)("h2",null,(0,i.zw)(t.$t("admin_dash.instance.instance")),1),(0,a._)("ul",b,[(0,a._)("li",null,[(0,a.Wm)(o,{path:":pleroma.:instance.:name"})]),(0,a._)("li",null,[(0,a.Wm)(o,{path:":pleroma.:instance.:email"})]),(0,a._)("li",null,[(0,a.Wm)(o,{path:":pleroma.:instance.:description"})]),(0,a._)("li",null,[(0,a.Wm)(o,{path:":pleroma.:instance.:short_description"})]),(0,a._)("li",null,[(0,a.Wm)(d,{path:":pleroma.:instance.:instance_thumbnail"})]),(0,a._)("li",null,[(0,a.Wm)(d,{path:":pleroma.:instance.:background_image"})])])]),(0,a._)("div",g,[(0,a._)("h2",null,(0,i.zw)(t.$t("admin_dash.instance.registrations")),1),(0,a._)("ul",w,[(0,a._)("li",null,[(0,a.Wm)(c,{path:":pleroma.:instance.:registrations_open"}),(0,a._)("ul",y,[(0,a._)("li",null,[(0,a.Wm)(c,{path:":pleroma.:instance.:invites_enabled","parent-path":":pleroma.:instance.:registrations_open","parent-invert":""})])])]),(0,a._)("li",null,[(0,a.Wm)(c,{path:":pleroma.:instance.:birthday_required"}),(0,a._)("ul",v,[(0,a._)("li",null,[(0,a.Wm)(u,{path:":pleroma.:instance.:birthday_min_age","parent-path":":pleroma.:instance.:birthday_required"})])])]),(0,a._)("li",null,[(0,a.Wm)(c,{path:":pleroma.:instance.:account_activation_required"})]),(0,a._)("li",null,[(0,a.Wm)(c,{path:":pleroma.:instance.:account_approval_required"})]),(0,a._)("li",null,[(0,a._)("h3",null,(0,i.zw)(t.$t("admin_dash.instance.captcha_header")),1),(0,a._)("ul",k,[(0,a._)("li",null,[(0,a.Wm)(c,{path:[":pleroma","Pleroma.Captcha",":enabled"]},null,8,["path"]),(0,a._)("ul",O,[(0,a._)("li",null,[(0,a.Wm)(p,{path:[":pleroma","Pleroma.Captcha",":method"],"parent-path":[":pleroma","Pleroma.Captcha",":enabled"],"option-label-map":{"Pleroma.Captcha.Native":t.$t("admin_dash.captcha.native"),"Pleroma.Captcha.Kocaptcha":t.$t("admin_dash.captcha.kocaptcha")}},null,8,["path","parent-path","option-label-map"]),(0,a.Wm)(u,{path:[":pleroma","Pleroma.Captcha",":seconds_valid"],"parent-path":[":pleroma","Pleroma.Captcha",":enabled"]},null,8,["path","parent-path"])]),t.adminDraft[":pleroma"]["Pleroma.Captcha"][":enabled"]&&"Pleroma.Captcha.Kocaptcha"===t.adminDraft[":pleroma"]["Pleroma.Captcha"][":method"]?((0,a.wg)(),(0,a.iD)("li",D,[(0,a._)("h4",null,(0,i.zw)(t.$t("admin_dash.instance.kocaptcha")),1),(0,a._)("ul",S,[(0,a._)("li",null,[(0,a.Wm)(o,{path:[":pleroma","Pleroma.Captcha.Kocaptcha",":endpoint"]},null,8,["path"])])])])):(0,a.kq)("",!0)])])])])])]),(0,a._)("div",j,[(0,a._)("h2",null,(0,i.zw)(t.$t("admin_dash.instance.access")),1),(0,a._)("ul",P,[(0,a._)("li",null,[(0,a.Wm)(c,{"override-backend-description":"","override-backend-description-label":"",path:":pleroma.:instance.:public"})]),(0,a._)("li",null,[(0,a.Wm)(p,{"override-backend-description":"","override-backend-description-label":"",path:":pleroma.:instance.:limit_to_local_content"})]),t.expertLevel?((0,a.wg)(),(0,a.iD)("li",$,[(0,a._)("h3",null,(0,i.zw)(t.$t("admin_dash.instance.restrict.header")),1),(0,a._)("p",null,(0,i.zw)(t.$t("admin_dash.instance.restrict.description")),1),(0,a._)("ul",W,[(0,a._)("li",null,[(0,a._)("h4",null,(0,i.zw)(t.$t("admin_dash.instance.restrict.timelines")),1),(0,a._)("ul",z,[(0,a._)("li",null,[(0,a.Wm)(c,{path:":pleroma.:restrict_unauthenticated.:timelines.:local","indeterminate-state":":if_instance_is_private","swap-description-and-label":"","hide-description":""})]),(0,a._)("li",null,[(0,a.Wm)(c,{path:":pleroma.:restrict_unauthenticated.:timelines.:federated","indeterminate-state":":if_instance_is_private","swap-description-and-label":"","hide-description":""})]),(0,a._)("li",null,[(0,a.Wm)(m,{path:":pleroma.:restrict_unauthenticated.:timelines"})])])]),(0,a._)("li",null,[(0,a._)("h4",null,(0,i.zw)(t.$t("admin_dash.instance.restrict.profiles")),1),(0,a._)("ul",Z,[(0,a._)("li",null,[(0,a.Wm)(c,{path:":pleroma.:restrict_unauthenticated.:profiles.:local","indeterminate-state":":if_instance_is_private","swap-description-and-label":"","hide-description":""})]),(0,a._)("li",null,[(0,a.Wm)(c,{path:":pleroma.:restrict_unauthenticated.:profiles.:remote","indeterminate-state":":if_instance_is_private","swap-description-and-label":"","hide-description":""})]),(0,a._)("li",null,[(0,a.Wm)(m,{path:":pleroma.:restrict_unauthenticated.:profiles"})])])]),(0,a._)("li",null,[(0,a._)("h4",null,(0,i.zw)(t.$t("admin_dash.instance.restrict.activities")),1),(0,a._)("ul",C,[(0,a._)("li",null,[(0,a.Wm)(c,{path:":pleroma.:restrict_unauthenticated.:activities.:local","indeterminate-state":":if_instance_is_private","swap-description-and-label":"","hide-description":""})]),(0,a._)("li",null,[(0,a.Wm)(c,{path:":pleroma.:restrict_unauthenticated.:activities.:remote","indeterminate-state":":if_instance_is_private","swap-description-and-label":"","hide-description":""})]),(0,a._)("li",null,[(0,a.Wm)(m,{path:":pleroma.:restrict_unauthenticated.:activities"})])])])])])):(0,a.kq)("",!0)])])],8,h)}]]);var bt=["label"],gt={class:"setting-item"},wt={class:"setting-list"},yt={class:"setting-list"},vt={class:"setting-list"},kt={class:"setting-list"},Ot={class:"setting-list"},Dt={class:"setting-list"};function St(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,a)}return n}pt.vI.add(mt.g4A);const jt={data:function(){},components:{BooleanSetting:I.Z,ChoiceSetting:q.Z,IntegerSetting:M.Z,StringSetting:Y},computed:function(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?St(Object(n),!0).forEach((function(e){(0,L.Z)(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):St(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}({},(0,ut.Z)())},Pt=(0,T.Z)(jt,[["render",function(t,e,n,r,l,s){var o=(0,a.up)("IntegerSetting");return(0,a.wg)(),(0,a.iD)("div",{label:t.$t("admin_dash.tabs.limits")},[(0,a._)("div",gt,[(0,a._)("h2",null,(0,i.zw)(t.$t("admin_dash.limits.arbitrary_limits")),1),(0,a._)("ul",wt,[(0,a._)("li",null,[(0,a._)("h3",null,(0,i.zw)(t.$t("admin_dash.limits.posts")),1),(0,a._)("ul",yt,[(0,a._)("li",null,[(0,a.Wm)(o,{source:"admin",path:":pleroma.:instance.:limit","draft-mode":""})]),(0,a._)("li",null,[(0,a.Wm)(o,{source:"admin",path:":pleroma.:instance.:remote_limit",expert:"1","draft-mode":""})])])]),(0,a._)("li",null,[(0,a._)("h3",null,(0,i.zw)(t.$t("admin_dash.limits.uploads")),1),(0,a._)("ul",vt,[(0,a._)("li",null,[(0,a.Wm)(o,{source:"admin",path:":pleroma.:instance.:description_limit","draft-mode":""})]),(0,a._)("li",null,[(0,a.Wm)(o,{source:"admin",path:":pleroma.:instance.:upload_limit","draft-mode":""})]),(0,a._)("li",null,[(0,a.Wm)(o,{source:"admin",path:":pleroma.:instance.:max_media_attachments","draft-mode":""})])])]),(0,a._)("li",null,[(0,a._)("h3",null,(0,i.zw)(t.$t("admin_dash.limits.users")),1),(0,a._)("ul",kt,[(0,a._)("li",null,[(0,a.Wm)(o,{source:"admin",path:":pleroma.:instance.:max_pinned_statuses","draft-mode":""})]),(0,a._)("li",null,[(0,a.Wm)(o,{source:"admin",path:":pleroma.:instance.:user_bio_length","draft-mode":""})]),(0,a._)("li",null,[(0,a.Wm)(o,{source:"admin",path:":pleroma.:instance.:user_name_length","draft-mode":""})]),(0,a._)("li",null,[(0,a._)("h4",null,(0,i.zw)(t.$t("admin_dash.limits.profile_fields")),1),(0,a._)("ul",Ot,[(0,a._)("li",null,[(0,a.Wm)(o,{source:"admin",path:":pleroma.:instance.:max_account_fields","draft-mode":""})]),(0,a._)("li",null,[(0,a.Wm)(o,{source:"admin",path:":pleroma.:instance.:max_remote_account_fields","draft-mode":"",expert:"1"})]),(0,a._)("li",null,[(0,a.Wm)(o,{source:"admin",path:":pleroma.:instance.:account_field_name_length","draft-mode":""})]),(0,a._)("li",null,[(0,a.Wm)(o,{source:"admin",path:":pleroma.:instance.:account_field_value_length","draft-mode":""})])])]),(0,a._)("li",null,[(0,a._)("h4",null,(0,i.zw)(t.$t("admin_dash.limits.user_uploads")),1),(0,a._)("ul",Dt,[(0,a._)("li",null,[(0,a.Wm)(o,{source:"admin",path:":pleroma.:instance.:avatar_upload_limit","draft-mode":""})]),(0,a._)("li",null,[(0,a.Wm)(o,{source:"admin",path:":pleroma.:instance.:banner_upload_limit","draft-mode":""})])])])])])])])],8,bt)}]]);var $t=["label"],Wt={class:"setting-item"},zt={class:"setting-list"},Zt={class:"setting-list"},Ct={class:"setting-list"},Lt={class:"cards-list"},It={key:0},qt=["href"],Mt={key:1},Et={key:2},Ut=["href"],xt={class:"btn-group"},Bt=["onClick"],At={class:"dropdown-menu"},Ft=["onClick"],Tt=["title"],Yt={key:0,class:"btn-group"},Ht=["disabled","onClick"],Gt={class:"dropdown-menu"},Kt=["onClick"],Nt=["title"],Rt=n(84535);function Vt(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,a)}return n}pt.vI.add(mt.g4A);const Xt={provide:function(){return{defaultDraftMode:!0,defaultSource:"admin"}},components:{BooleanSetting:I.Z,ChoiceSetting:q.Z,IntegerSetting:M.Z,StringSetting:Y,GroupSetting:X,Popover:Rt.default},created:function(){this.user.rights.admin&&this.$store.dispatch("loadFrontendsStuff")},computed:function(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?Vt(Object(n),!0).forEach((function(e){(0,L.Z)(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Vt(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}({frontends:function(){return this.$store.state.adminSettings.frontends}},(0,ut.Z)()),methods:{update:function(t,e){var n=this,a=e||t.refs[0],i={name:t.name,ref:a};this.$store.state.api.backendInteractor.installFrontend({payload:i}).then((function(t){n.$store.dispatch("loadFrontendsStuff")}))},setDefault:function(t,e){var n=e||t.refs[0],a=t.name;this.$store.commit("updateAdminDraft",{path:[":pleroma",":frontends",":primary"],value:{name:a,ref:n}})}}},Jt=(0,T.Z)(Xt,[["render",function(t,e,n,r,l,s){var o=(0,a.up)("StringSetting"),d=(0,a.up)("GroupSetting"),c=(0,a.up)("i18n-t"),u=(0,a.up)("FAIcon"),p=(0,a.up)("Popover");return(0,a.wg)(),(0,a.iD)("div",{class:"frontends-tab",label:t.$t("admin_dash.tabs.frontends")},[(0,a._)("div",Wt,[(0,a._)("h2",null,(0,i.zw)(t.$t("admin_dash.tabs.frontends")),1),(0,a._)("p",null,(0,i.zw)(t.$t("admin_dash.frontend.wip_notice")),1),(0,a._)("ul",zt,[(0,a._)("li",null,[(0,a._)("h3",null,(0,i.zw)(t.$t("admin_dash.frontend.default_frontend")),1),(0,a._)("p",null,(0,i.zw)(t.$t("admin_dash.frontend.default_frontend_tip")),1),(0,a._)("p",null,(0,i.zw)(t.$t("admin_dash.frontend.default_frontend_tip2")),1),(0,a._)("ul",Zt,[(0,a._)("li",null,[(0,a.Wm)(o,{path:":pleroma.:frontends.:primary.name"})]),(0,a._)("li",null,[(0,a.Wm)(o,{path:":pleroma.:frontends.:primary.ref"})]),(0,a._)("li",null,[(0,a.Wm)(d,{path:":pleroma.:frontends.:primary"})])])])]),(0,a._)("div",Ct,[(0,a._)("h3",null,(0,i.zw)(t.$t("admin_dash.frontend.available_frontends")),1),(0,a._)("ul",Lt,[((0,a.wg)(!0),(0,a.iD)(a.HY,null,(0,a.Ko)(t.frontends,(function(e){return(0,a.wg)(),(0,a.iD)("li",{key:e.name},[(0,a._)("strong",null,(0,i.zw)(e.name),1),(0,a.Uk)(" "+(0,i.zw)(" ")+" "),t.adminDraft[":pleroma"][":frontends"][":primary"].name===e.name?((0,a.wg)(),(0,a.iD)("span",It,[t.adminDraft[":pleroma"][":frontends"][":primary"].ref===e.refs[0]?((0,a.wg)(),(0,a.j4)(c,{key:0,keypath:"admin_dash.frontend.is_default"})):((0,a.wg)(),(0,a.j4)(c,{key:1,keypath:"admin_dash.frontend.is_default_custom"},{version:(0,a.w5)((function(){return[(0,a._)("code",null,(0,i.zw)(t.adminDraft[":pleroma"][":frontends"][":primary"].ref),1)]})),_:1}))])):(0,a.kq)("",!0),(0,a._)("dl",null,[(0,a._)("dt",null,(0,i.zw)(t.$t("admin_dash.frontend.repository")),1),(0,a._)("dd",null,[(0,a._)("a",{href:e.git,target:"_blank"},(0,i.zw)(e.git),9,qt)]),t.expertLevel?((0,a.wg)(),(0,a.iD)(a.HY,{key:0},[(0,a._)("dt",null,(0,i.zw)(t.$t("admin_dash.frontend.versions")),1),((0,a.wg)(!0),(0,a.iD)(a.HY,null,(0,a.Ko)(e.refs,(function(t){return(0,a.wg)(),(0,a.iD)("dd",{key:t},[(0,a._)("code",null,(0,i.zw)(t),1)])})),128))],64)):(0,a.kq)("",!0),t.expertLevel?((0,a.wg)(),(0,a.iD)("dt",Mt,(0,i.zw)(t.$t("admin_dash.frontend.build_url")),1)):(0,a.kq)("",!0),t.expertLevel?((0,a.wg)(),(0,a.iD)("dd",Et,[(0,a._)("a",{href:e.build_url,target:"_blank"},(0,i.zw)(e.build_url),9,Ut)])):(0,a.kq)("",!0)]),(0,a._)("div",null,[(0,a._)("span",xt,[(0,a._)("button",{class:"button button-default btn",type:"button",onClick:function(n){return t.update(e)}},(0,i.zw)(e.installed?t.$t("admin_dash.frontend.reinstall"):t.$t("admin_dash.frontend.install")),9,Bt),e.refs.length>1?((0,a.wg)(),(0,a.j4)(p,{key:0,trigger:"click",class:"button-dropdown",placement:"bottom"},{content:(0,a.w5)((function(){return[(0,a._)("div",At,[((0,a.wg)(!0),(0,a.iD)(a.HY,null,(0,a.Ko)(e.refs,(function(n){return(0,a.wg)(),(0,a.iD)("button",{key:n,class:"button-default dropdown-item",onClick:function(a){return t.update(e,n)}},[(0,a.Wm)(c,{keypath:"admin_dash.frontend.install_version"},{version:(0,a.w5)((function(){return[(0,a._)("code",null,(0,i.zw)(n),1)]})),_:2},1024)],8,Ft)})),128))])]})),trigger:(0,a.w5)((function(){return[(0,a._)("button",{class:"button button-default btn dropdown-button",type:"button",title:t.$t("admin_dash.frontend.more_install_options")},[(0,a.Wm)(u,{icon:"chevron-down"})],8,Tt)]})),_:2},1024)):(0,a.kq)("",!0)]),e.installed&&"admin-fe"!==e.name?((0,a.wg)(),(0,a.iD)("span",Yt,[(0,a._)("button",{class:"button button-default btn",type:"button",disabled:t.adminDraft[":pleroma"][":frontends"][":primary"].name===e.name&&t.adminDraft[":pleroma"][":frontends"][":primary"].ref===e.refs[0],onClick:function(n){return t.setDefault(e)}},(0,i.zw)(t.$t("admin_dash.frontend.set_default")),9,Ht),(0,a.Uk)(" "+(0,i.zw)(" ")+" "),e.refs.length>1?((0,a.wg)(),(0,a.j4)(p,{key:0,trigger:"click",class:"button-dropdown",placement:"bottom"},{content:(0,a.w5)((function(){return[(0,a._)("div",Gt,[((0,a.wg)(!0),(0,a.iD)(a.HY,null,(0,a.Ko)(e.refs.slice(1),(function(n){return(0,a.wg)(),(0,a.iD)("button",{key:n,class:"button-default dropdown-item",onClick:function(a){return t.setDefault(e,n)}},[(0,a.Wm)(c,{keypath:"admin_dash.frontend.set_default_version"},{version:(0,a.w5)((function(){return[(0,a._)("code",null,(0,i.zw)(n),1)]})),_:2},1024)],8,Kt)})),128))])]})),trigger:(0,a.w5)((function(){return[(0,a._)("button",{class:"button button-default btn dropdown-button",type:"button",title:t.$t("admin_dash.frontend.more_default_options")},[(0,a.Wm)(u,{icon:"chevron-down"})],8,Nt)]})),_:2},1024)):(0,a.kq)("",!0)])):(0,a.kq)("",!0)])])})),128))])])])],8,$t)}]]);pt.vI.add(mt.klh,mt.ioV,mt.py1,mt.XsY,mt.qmU,mt.q7m,mt.Aq,mt.YHc);const Qt={components:{TabSwitcher:f.Z,InstanceTab:_t,LimitsTab:Pt,FrontendsTab:Jt},computed:{user:function(){return this.$store.state.users.currentUser},isLoggedIn:function(){return!!this.$store.state.users.currentUser},open:function(){return"hidden"!==this.$store.state.interface.settingsModalState},bodyLock:function(){return"visible"===this.$store.state.interface.settingsModalState},adminDbLoaded:function(){return this.$store.state.adminSettings.loaded},adminDescriptionsLoaded:function(){return null!==this.$store.state.adminSettings.descriptions},noDb:function(){return!1===this.$store.state.adminSettings.dbConfigEnabled}},created:function(){this.user.rights.admin&&this.$store.dispatch("loadAdminStuff")},methods:{onOpen:function(){var t=this.$store.state.interface.settingsModalTargetTab;if(t){var e=this.$refs.tabSwitcher.$slots.default().findIndex((function(e){return e.props&&e.props["data-tab-name"]===t}));e>=0&&this.$refs.tabSwitcher.setTab(e)}this.$store.dispatch("clearSettingsModalTargetTab")}},mounted:function(){this.onOpen()},watch:{open:function(t){t&&this.onOpen()}}},te=(0,T.Z)(Qt,[["render",function(t,e,n,f,h,_){var b=(0,a.up)("i18n-t"),g=(0,a.up)("InstanceTab"),w=(0,a.up)("LimitsTab"),y=(0,a.up)("FrontendsTab"),v=(0,a.up)("tab-switcher");return t.adminDescriptionsLoaded&&(t.noDb||t.adminDbLoaded)?((0,a.wg)(),(0,a.j4)(v,{key:0,ref:"tabSwitcher",class:"settings_tab-switcher","side-tab-bar":!0,"scrollable-tabs":!0,"render-only-focused":!0,"body-scroll-lock":t.bodyLock},{default:(0,a.w5)((function(){return[t.noDb?((0,a.wg)(),(0,a.iD)("div",{key:0,label:t.$t("admin_dash.tabs.nodb"),icon:"exclamation-triangle","data-tab-name":"nodb-notice"},[(0,a._)("div",{label:t.$t("admin_dash.tabs.nodb")},[(0,a._)("div",s,[(0,a._)("h2",null,(0,i.zw)(t.$t("admin_dash.nodb.heading")),1),(0,a.Wm)(b,{keypath:"admin_dash.nodb.text"},{documentation:(0,a.w5)((function(){return[(0,a._)("a",o,(0,i.zw)(t.$t("admin_dash.nodb.documentation")),1)]})),property:(0,a.w5)((function(){return[d]})),value:(0,a.w5)((function(){return[c]})),_:1}),(0,a._)("p",null,(0,i.zw)(t.$t("admin_dash.nodb.text2")),1)])],8,l)],8,r)):(0,a.kq)("",!0),t.adminDbLoaded?((0,a.wg)(),(0,a.iD)("div",{key:1,label:t.$t("admin_dash.tabs.instance"),icon:"wrench","data-tab-name":"general"},[(0,a.Wm)(g)],8,u)):(0,a.kq)("",!0),t.adminDbLoaded?((0,a.wg)(),(0,a.iD)("div",{key:2,label:t.$t("admin_dash.tabs.limits"),icon:"hand","data-tab-name":"limits"},[(0,a.Wm)(w)],8,p)):(0,a.kq)("",!0),(0,a._)("div",{label:t.$t("admin_dash.tabs.frontends"),icon:"laptop-code","data-tab-name":"frontends"},[(0,a.Wm)(y)],8,m)]})),_:1},8,["body-scroll-lock"])):(0,a.kq)("",!0)}]])}}]);
2 //# sourceMappingURL=9801.d57b3706e7d0e36264a2.js.map