n8n-editor-ui
Version:
Workflow Editor UI for n8n
2 lines • 5.33 kB
JavaScript
!function(){try{("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{}).SENTRY_RELEASE={id:"n8n@2.13.4"}}catch(e){}}(),System.register(["./vue.runtime.esm-bundler-legacy-IafOlCW8.js","./_MapCache-legacy-DwgdC8YO.js","./src-legacy-Dwzr7bD0.js","./_plugin-vue_export-helper-legacy-DEZAmQqp.js","./sanitize-html-legacy-ChR3ikxn.js","./users.store-legacy-OKuN0qAC.js","./constants-legacy-DNCca_FT.js","./merge-legacy-uu1aGqHK.js","./_baseOrderBy-legacy-PsQY_Pvh.js","./dateformat-legacy-BxdD_OP7.js","./useDebounce-legacy-CT3oYGrC.js","./assistant.store-legacy-kpq6KUPM.js"],(function(e,t){var a,n,s,i,l,o,c,r,d,u,g,b,p,_,f,x,y,v,h,m,T,w,k,S,j,D,E;return{setters:[function(e){a=e.$,n=e.A,s=e.C,i=e.E,l=e.Ft,o=e.N,c=e.S,r=e.Sn,d=e.Wt,u=e.X,g=e._n,b=e.bt,p=e.j,_=e.ot,f=e.yt},function(e){x=e.bt},function(e){y=e.Yi,v=e.Zi,h=e.yt},function(e){m=e.t},function(e){},function(e){T=e.As,w=e.Tr,k=e.en,S=e.jr,j=e.vn},function(e){e.Ps},function(e){},function(e){},function(e){},function(e){},function(e){D=e.t}],execute:function(){(E=document.createElement("style")).textContent="._container_5309p_125{gap:var(--spacing--xl);flex-direction:column;display:flex}._header_5309p_131,._content_5309p_137{gap:var(--spacing--2xs);flex-direction:column;display:flex}._checkboxContainer_5309p_143{border:var(--border-width)var(--border-style)var(--color--info--tint-1);border-radius:var(--radius);padding:var(--spacing--md)var(--spacing--md)var(--spacing--xs);flex-direction:column;display:flex}._checkboxContainer_5309p_143 label{font-weight:var(--font-weight--bold);padding-bottom:var(--spacing--5xs)}._checkboxContainer_5309p_143 ._checkboxDescription_5309p_154{padding:var(--spacing--2xs)var(--spacing--xl)}._checkboxContainer_5309p_143 ._notice_5309p_157{margin-left:var(--spacing--xl);margin-top:var(--spacing--2xs)}._privacyNote_5309p_162 span+span{margin-left:var(--spacing--4xs)}\n/*$vite$:1*/",document.head.appendChild(E);try{t="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},(A=(new t.Error).stack)&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[A]="44ca6a26-b1d8-40b0-9e70-10d9fcced509",t._sentryDebugIdIdentifier="sentry-dbid-44ca6a26-b1d8-40b0-9e70-10d9fcced509")}catch(t){}var t,A;e("default",m(o({__name:"SettingsAIView",setup(e){const t=x(),o=w(),m=j(),E=S(),A=k(),C=D(),$=T(),N=l(!0),V=c((()=>C.isAssistantEnabled)),I=c((()=>$.isAiBuilderEnabled)),B=c((()=>$.isAskAiEnabled)),P=c((()=>$.isAiDataSharingEnabled)),U=c((()=>V.value&&B.value?t.baseText("settings.ai.description.both"):V.value?t.baseText("settings.ai.description.assistantOnly"):B.value?t.baseText("settings.ai.description.askAiOnly"):t.baseText("settings.ai.description.both"))),z=c((()=>I.value?t.baseText("settings.ai.confirm.message.builderEnabled"):t.baseText("settings.ai.confirm.message.builderDisabled"))),M=async e=>{if("boolean"==typeof e&&(e||"confirm"===await E.confirm(z.value,{title:t.baseText("settings.ai.confirm.title"),confirmButtonText:t.baseText("settings.ai.confirm.confirmButtonText"),cancelButtonText:t.baseText("generic.cancel")})))try{await $.updateAiDataSharingSettings(e),o.showMessage({title:t.baseText("settings.ai.updated.success"),type:"success"}),A.track("User changed AI Usage settings",{allow_sending_parameter_values:e})}catch(a){o.showError(a,t.baseText("settings.ai.updated.error"))}};return u((async()=>{m.set(t.baseText("settings.ai"))})),(e,l)=>{const o=_("n8n-html");return a(),i("div",{class:g(e.$style.container),"data-test-id":"ai"},[s("div",{class:g(e.$style.header)},[p(d(y),{size:"2xlarge"},{default:f((()=>[n(r(d(t).baseText("settings.ai")),1)])),_:1}),b(p(d(v),{size:"small",color:"text-light"},null,512),[[o,U.value]])],2),s("div",{class:g(e.$style.content)},[s("div",{class:g(e.$style.checkboxContainer)},[p(d(h),{modelValue:N.value,"onUpdate:modelValue":l[0]||(l[0]=e=>N.value=e),disabled:!0,label:d(t).baseText("settings.ai.allowSendingSchema.label")},null,8,["modelValue","label"]),p(d(v),{class:g(e.$style.checkboxDescription),color:"text-base"},{default:f((()=>[n(r(d(t).baseText("settings.ai.allowSendingSchema.description")),1)])),_:1},8,["class"])],2),s("div",{class:g(e.$style.checkboxContainer)},[p(d(h),{"model-value":P.value,label:d(t).baseText("settings.ai.allowSendingParameterValues.label"),"onUpdate:modelValue":M},null,8,["model-value","label"]),p(d(v),{class:g(e.$style.checkboxDescription),color:"text-base"},{default:f((()=>[n(r(d(t).baseText("settings.ai.allowSendingParameterValues.description")),1)])),_:1},8,["class"])],2)],2),s("div",{class:g(e.$style.privacyNote)},[p(d(v),{bold:!0},{default:f((()=>[n(r(d(t).baseText("settings.ai.privacyNote.heading")),1)])),_:1}),b(p(d(v),{color:"text-base"},null,512),[[o,d(t).baseText("settings.ai.privacyNote.content",{interpolate:{docsLink:"https://docs.n8n.io/manage-cloud/ai-assistant"}})]])],2)],2)}}}),[["__cssModules",{$style:{container:"_container_5309p_125",header:"_header_5309p_131",content:"_content_5309p_137",checkboxContainer:"_checkboxContainer_5309p_143",checkboxDescription:"_checkboxDescription_5309p_154",notice:"_notice_5309p_157",privacyNote:"_privacyNote_5309p_162"}}]]))}}}));
//# sourceMappingURL=SettingsAIView-legacy-BrAXG_4A.js.map