nextcloud/dist/sharebymail-admin-settings.mjs
Ferdinand Thiessen a623bffb00
chore: compile assets
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2026-01-14 10:27:02 +01:00

2 lines
2.5 KiB
JavaScript

import{f as l,c as u,o as f,w as i,e as p,g as m,t as d,h as b}from"./runtime-dom.esm-bundler-BrYCUcZF.chunk.mjs";import{c as w}from"./index-BfylblLb.chunk.mjs";import{a as g}from"./index-JpgrUA2Z-BFiKKJ1W.chunk.mjs";import{a as S,l as c}from"./index-xFugdZPW.chunk.mjs";import{t as h}from"./translation-DoG5ZELJ-gw0g4US-.chunk.mjs";import{c as I}from"./index-cDQt1Drw.chunk.mjs";import{a as M}from"./createElementId-DhjFt1I9--Zqj3wLs.chunk.mjs";import{N as k}from"./NcCheckboxRadioSwitch-BCSKF7Tk-yPckcGKs.chunk.mjs";import{N}from"./ContentCopy-DVkZwwZt.chunk.mjs";import{g as R}from"./index-6_gsQFyp.chunk.mjs";import"./string_decoder-BO00msnV.chunk.mjs";import"./NcNoteCard-CVhtNL04-hwuc093N.chunk.mjs";import"./mdi-D55n0uzy.chunk.mjs";import"./NcPasswordField-djttkA5Q-2g87vOpY.chunk.mjs";import"./NcInputField-Bwsh2aHY-CHbAfY0u.chunk.mjs";const T=R().detectLogLevel().setApp("sharebymail").build(),V={name:"AdminSettings",components:{NcCheckboxRadioSwitch:k,NcSettingsSection:N},setup(){return{t:h}},data(){return{sendPasswordMail:c("sharebymail","sendPasswordMail"),replyToInitiator:c("sharebymail","replyToInitiator")}},watch:{sendPasswordMail(e){this.update("sendpasswordmail",e)},replyToInitiator(e){this.update("replyToInitiator",e)}},methods:{async update(e,a){await I();const o=M("/apps/provisioning_api/api/v1/config/apps/{appId}/{key}",{appId:"sharebymail",key:e}),s=a?"yes":"no";try{const{data:t}=await w.post(o,{value:s});this.handleResponse({status:t.ocs?.meta?.status})}catch(t){this.handleResponse({errorMessage:h("sharebymail","Unable to update share by mail config"),error:t})}},async handleResponse({status:e,errorMessage:a,error:o}){e!=="ok"&&(g(a),T.error(a,{error:o}))}}};function v(e,a,o,s,t,x){const n=l("NcCheckboxRadioSwitch"),y=l("NcSettingsSection");return f(),u(y,{name:s.t("sharebymail","Share by mail"),description:s.t("sharebymail","Allows people to share a personalized link to a file or folder by putting in an email address.")},{default:i(()=>[p(n,{modelValue:t.sendPasswordMail,"onUpdate:modelValue":a[0]||(a[0]=r=>t.sendPasswordMail=r),type:"switch"},{default:i(()=>[m(d(s.t("sharebymail","Send password by mail")),1)]),_:1},8,["modelValue"]),p(n,{modelValue:t.replyToInitiator,"onUpdate:modelValue":a[1]||(a[1]=r=>t.replyToInitiator=r),type:"switch"},{default:i(()=>[m(d(s.t("sharebymail","Reply to initiator")),1)]),_:1},8,["modelValue"])]),_:1},8,["name","description"])}const P=S(V,[["render",v]]),_=b(P);_.mount("#vue-admin-sharebymail");
//# sourceMappingURL=sharebymail-admin-settings.mjs.map