import{E as e,O as t,Y as n,c as r,d as i,dt as a,g as o,i as s,lt as c,s as l,t as u,u as d,ut as f}from"./_plugin-vue_export-helper-CnSQ-FNj.js";import{n as p,r as m,t as h}from"./index-KHHWwfaX.js";var g={class:`settings`},_={class:`settings__section`},v={class:`theme-grid`,role:`radiogroup`,"aria-label":`Choose theme`},y=[`aria-checked`,`aria-label`,`onClick`],b={class:`theme-swatch__label`},x={key:0,class:`theme-swatch__check`,"aria-hidden":`true`},S={class:`settings__section`},C={class:`settings__row`},w={class:`settings__row-value`},T=u(o({__name:`SettingsView`,setup(o){let u=m(),{saveTheme:T}=p(),E=l(()=>u.user?.theme??`warm-craft`);function D(e){T(e)}return(o,l)=>(e(),i(`main`,g,[l[5]||=r(`h1`,{class:`settings__title`},`Settings`,-1),r(`section`,_,[l[1]||=r(`h2`,{class:`settings__section-title`},`Theme`,-1),r(`div`,v,[(e(!0),i(s,null,t(n(h),t=>(e(),i(`button`,{key:t.id,type:`button`,role:`radio`,"aria-checked":E.value===t.id,"aria-label":t.label,class:c([`theme-swatch`,{"theme-swatch--active":E.value===t.id}]),style:f({"--swatch-bg":t.bg,"--swatch-primary":t.primary,"--swatch-text":t.text}),onClick:e=>D(t.id)},[l[0]||=r(`span`,{class:`theme-swatch__preview`,"aria-hidden":`true`},[r(`span`,{class:`theme-swatch__bar`}),r(`span`,{class:`theme-swatch__dot`})],-1),r(`span`,b,a(t.label),1),E.value===t.id?(e(),i(`span`,x,`✓`)):d(``,!0)],14,y))),128))])]),r(`section`,S,[l[3]||=r(`h2`,{class:`settings__section-title`},`Account`,-1),r(`div`,C,[l[2]||=r(`span`,{class:`settings__row-label`},`Signed in as`,-1),r(`span`,w,a(n(u).user?.email),1)]),l[4]||=r(`a`,{href:`/logout`,class:`settings__logout`},`Sign out`,-1)])]))}}),[[`__scopeId`,`data-v-1446e085`]]);export{T as default};