@openparachute/app 0.22.15-rc.2 → 0.22.15-rc.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (59) hide show
  1. package/CHANGELOG.md +4 -0
  2. package/dist/.parachute/info +1 -1
  3. package/dist/assets/Account-D0h6O8Fw.js +1 -0
  4. package/dist/assets/{Activity-DM07RTaL.js → Activity-K74lz7be.js} +1 -1
  5. package/dist/assets/{AddVault-CCUUpUpS.js → AddVault-DRwBvbhl.js} +1 -1
  6. package/dist/assets/AddVaultChooser-BeAu_6Sf.js +1 -0
  7. package/dist/assets/AddVaultCreate-BCV0cbE-.js +1 -0
  8. package/dist/assets/Calendar-BdnpLRbx.js +1 -0
  9. package/dist/assets/CheckEmail-DDbWzG2r.js +1 -0
  10. package/dist/assets/ConnectAI-Dcn5RhIk.js +1 -0
  11. package/dist/assets/DayView-RBUIG0ht.js +1 -0
  12. package/dist/assets/Export-Bs1BQGwv.js +1 -0
  13. package/dist/assets/{Import-D038Sg4Z.js → Import-C1CAy6gk.js} +1 -1
  14. package/dist/assets/{NoteEditor-Cdr7U6a5.js → NoteEditor-BiF7u2II.js} +1 -1
  15. package/dist/assets/NoteNew-EDC5DN9z.js +8 -0
  16. package/dist/assets/{NoteRenderer-ChWpdbI7.js → NoteRenderer-CVHb_hev.js} +1 -1
  17. package/dist/assets/NoteView-3dqZLg5S.js +3 -0
  18. package/dist/assets/{OAuthCallback-CxZrvmxm.js → OAuthCallback-DZfGvDHw.js} +1 -1
  19. package/dist/assets/{PinArchiveButtons-DB8N7LBI.js → PinArchiveButtons-CFvL4XBO.js} +1 -1
  20. package/dist/assets/Settings-CN7EqJHc.js +1 -0
  21. package/dist/assets/{TagPage-BpiAw1a5.js → TagPage-B1FYKxLN.js} +1 -1
  22. package/dist/assets/{TagSchemaEditor-_n7m_7Xz.js → TagSchemaEditor-CMCwC2U0.js} +1 -1
  23. package/dist/assets/Tags-DcbmSGY5.js +1 -0
  24. package/dist/assets/{VaultGraph-BjX5cCDb.js → VaultGraph-3A0kx4wI.js} +3 -3
  25. package/dist/assets/Vaults-DM198kBa.js +1 -0
  26. package/dist/assets/{ViewNew-DkEvCm66.js → ViewNew-KOli1zPy.js} +1 -1
  27. package/dist/assets/ViewSurface-D0oPkxKC.js +1 -0
  28. package/dist/assets/Welcome-DhYNT96e.js +1 -0
  29. package/dist/assets/{WizardShell-DU1MCyj6.js → WizardShell-dR1ElLgB.js} +1 -1
  30. package/dist/assets/{attachment-upload-BPBeh3-z.js → attachment-upload-Dt0I8iWK.js} +1 -1
  31. package/dist/assets/{history-DdcRLE7l.js → history-CFoof_sA.js} +1 -1
  32. package/dist/assets/index-D-RN2HHm.css +1 -0
  33. package/dist/assets/index-GcTfNe1b.js +66 -0
  34. package/dist/assets/mcp-address-C02VbHLL.js +1 -0
  35. package/dist/assets/{provenance-CPDeMpx4.js → provenance-Hx5MxK3k.js} +1 -1
  36. package/dist/assets/{react-force-graph-2d-CHJEP3br.js → react-force-graph-2d-B2Gxxhfm.js} +1 -1
  37. package/dist/assets/{transcribe-default-DXKy7pnW.js → transcribe-default-DKody_lk.js} +1 -1
  38. package/dist/assets/{useAttachmentUploader-CW66AUeK.js → useAttachmentUploader-CwUuyNf7.js} +1 -1
  39. package/dist/index.html +2 -2
  40. package/dist/sw.js +1 -1
  41. package/meta.json +1 -1
  42. package/package.json +1 -1
  43. package/dist/assets/Account-Hp5OkH4s.js +0 -1
  44. package/dist/assets/AddVaultChooser-1EvPF7Ar.js +0 -1
  45. package/dist/assets/AddVaultCreate-BRI7isPc.js +0 -1
  46. package/dist/assets/Calendar-hX-e_t5t.js +0 -1
  47. package/dist/assets/CheckEmail-DsBGRDN5.js +0 -1
  48. package/dist/assets/ConnectAI-DSIclnVy.js +0 -1
  49. package/dist/assets/DayView-li8WEaCe.js +0 -1
  50. package/dist/assets/Export-CthQyoju.js +0 -1
  51. package/dist/assets/NoteNew-DA_3KP7v.js +0 -8
  52. package/dist/assets/NoteView-DOgD2Mi_.js +0 -3
  53. package/dist/assets/Settings-B9QD34GX.js +0 -1
  54. package/dist/assets/Tags-DpgXCyXu.js +0 -1
  55. package/dist/assets/Vaults-Col2somv.js +0 -1
  56. package/dist/assets/ViewSurface-CfwIfZk5.js +0 -1
  57. package/dist/assets/Welcome-Bhrr6Tp-.js +0 -1
  58. package/dist/assets/index-BBWRhmyM.css +0 -1
  59. package/dist/assets/index-oE_2AheL.js +0 -66
@@ -1,8 +0,0 @@
1
- import{av as Le,r as o,aw as Ue,ax as qe,ay as xe,a as Fe,b as Ve,ab as Oe,az as Be,aA as Ge,aB as He,aC as We,a6 as Ke,aa as Ye,aD as ze,am as Je,aE as Qe,C as Ze,ap as Xe,j as e,N as et,aF as tt,aG as be,V as st,aq as H,aH as nt,aI as at,aJ as rt,aK as ee,aL as ot,aM as it,aN as D,L as ct,as as lt,A as dt,aO as ut,au as mt}from"./index-oE_2AheL.js";import{v as pt,A as ft}from"./attachment-upload-BPBeh3-z.js";import{u as ht,C as gt,A as xt,a as bt}from"./useAttachmentUploader-CW66AUeK.js";import{b as vt,N as yt}from"./NoteRenderer-ChWpdbI7.js";import{l as ve,u as jt,a as kt,b as wt}from"./transcribe-default-DXKy7pnW.js";import{r as Rt}from"./editor-mode-D9fveTEx.js";import"./types-BaJkUfo6.js";const Nt=30*6e4,Tt=20*1024*1024,St=1e4;function Ct(t){const c=t.segmentMs??Nt,l=t.setTimer??((x,S)=>setTimeout(x,S)),b=t.clearTimer??(x=>clearTimeout(x)),k=t.makeRecorder??(x=>Le({...x,releaseStreamOnStop:!1})),g=[];let n=null,d=null,f="idle",u=0,h=0,y=!1;const m=()=>{for(const x of t.stream.getTracks())x.stop()},r=()=>{d!==null&&(b(d),d=null)},p=()=>{d=l(()=>{d=null,R()},c)},i=()=>{h+=1;const x=h;n=k({stream:t.stream,mimeType:t.mimeType,releaseStreamOnStop:!1,now:t.now,MediaRecorderCtor:t.MediaRecorderCtor,dataIntervalMs:St,onData:S=>{x===h&&S>=Tt&&R()}}),n.start(),u+=1,p()},R=()=>{var x;f!=="recording"||!n||y||(y=!0,r(),g.push(n.stop()),i(),(x=t.onRoll)==null||x.call(t,u),y=!1)};return{get state(){return f},get activePart(){return u},start(){if(f!=="idle")throw new Error(`Cannot start from ${f}`);f="recording",i()},async stop(){if(f!=="recording"||!n)throw new Error(`Cannot stop from ${f}`);f="stopped",r(),g.push(n.stop()),n=null;const x=await Promise.all(g);return m(),x},cancel(){r(),n&&n.cancel(),n=null,f="stopped",m()}}}function At(){const[t,c]=o.useState({kind:"idle"}),[l,b]=o.useState(0),[k,g]=o.useState(0),n=o.useRef(null),d=o.useRef(null);o.useEffect(()=>{if(t.kind!=="recording")return;const m=setInterval(()=>b(Date.now()-t.startedAt),250);return()=>clearInterval(m)},[t]),o.useEffect(()=>()=>{d.current&&URL.revokeObjectURL(d.current),n.current&&n.current.state==="recording"&&n.current.cancel()},[]);const f=o.useCallback(async()=>{if(!(t.kind==="recording"||t.kind==="requesting")){c({kind:"requesting"});try{const m=Ue();if(!m){c({kind:"denied",message:"This browser can't record audio in a format we can save."});return}const r=await qe(),p=Ct({stream:r,mimeType:m,onRoll:i=>g(i)});n.current=p,p.start(),b(0),g(p.activePart),c({kind:"recording",startedAt:Date.now()})}catch(m){const r=m,p=r.kind==="permission-denied"?"Microphone access was denied. Update your browser's site settings to record.":r.kind==="no-device"?"No microphone was found on this device.":r instanceof Error?r.message:"Microphone is not available in this browser.";c({kind:"denied",message:p})}}},[t]),u=o.useCallback(async()=>{var r;const m=n.current;if(!(!m||t.kind!=="recording"))try{const p=await m.stop();n.current=null,g(0);const i=((r=p[0])==null?void 0:r.mimeType)??"",R=p.reduce((W,F)=>W+F.durationMs,0),x=p[0],S=x?URL.createObjectURL(new Blob([x.data],{type:x.mimeType})):"";d.current&&URL.revokeObjectURL(d.current),d.current=S||null,c({kind:"have-audio",segments:p,mimeType:i,url:S,durationMs:R})}catch(p){console.warn(p instanceof Error?`Recording failed: ${p.message}`:"Recording failed."),g(0),c({kind:"idle"})}},[t]),h=o.useCallback(()=>{d.current&&(URL.revokeObjectURL(d.current),d.current=null),c({kind:"idle"}),b(0),g(0)},[]),y=o.useCallback(()=>{h()},[h]);return{phase:t,elapsedMs:l,parts:k,startRecording:f,stopRecording:u,discardAudio:h,reset:y}}function Et(t){const{segments:c,mimeType:l,recordedAt:b,willTranscribe:k}=t,g=c.length>1,n=t.typedText.trim(),d=c.map((y,m)=>({filename:g?xe(l,b,m+1):xe(l,b),transcribe:k,...k&&g?{segment_index:m}:{}})),f=k?g?c.map((y,m)=>`_Transcript pending (part ${m+1})._`).join(`
2
-
3
- `):"_Transcript pending._":"",u=d.map(y=>`![[${y.filename}]]`).join(`
4
-
5
- `),h=[];return n&&h.push(n),f&&h.push(f),h.push(u),{body:`${h.join(`
6
-
7
- `)}
8
- `,segments:d}}const ye={content:"",path:"",tags:[]};function Vt(){const t=Fe(s=>s.getActiveVault()),c=Ve(),l=Oe(s=>s.push),b=Be(),k=Ge(),g=He(),{db:n,blobStore:d,engine:f}=We(),{roles:u}=Ke((t==null?void 0:t.id)??null),h=Ye(),y=o.useRef(ze()),m=o.useRef(Rt()).current,r=o.useRef((t==null?void 0:t.id)??null).current,p=o.useRef(null),[i,R]=o.useState(()=>{if(r){const s=Je(r,D);if(s)return p.current=s.savedAt,s.body}return{...ye,path:y.current}}),[x,S]=o.useState(()=>p.current),[W,F]=o.useState(""),[se,A]=o.useState(null),[V,ke]=o.useState([]),[we,ne]=o.useState(!1),K=o.useRef(null),ae=o.useRef(null),v=At(),M=Qe(),T=M.capability,Re=v.phase.kind==="requesting"||v.phase.kind==="recording"||v.phase.kind==="have-audio",Ne=(T==null?void 0:T.enabled)===!1&&!Re,Y=typeof(T==null?void 0:T.minutes_remaining)=="number"?T.minutes_remaining:void 0,z=Y!==void 0&&Y<=0,[J,re]=o.useState(()=>r?ve(r):!0),Te=(T==null?void 0:T.enabled)!==!1,oe=o.useRef(v.phase.kind);o.useEffect(()=>{const s=oe.current,a=v.phase.kind;oe.current=a,a==="idle"&&s!=="idle"&&r&&re(ve(r))},[v.phase.kind,r]);const[Se]=Ze(),ie=Se.has("voice"),ce=o.useRef(!1);o.useEffect(()=>{var s;!ie||ce.current||M.settled&&((s=M.capability)==null?void 0:s.enabled)!==!1&&(ce.current=!0,v.startRecording())},[ie,M.settled,M.capability,v.startRecording]);const E=ht({noteId:null,onInsert:s=>{K.current?K.current.insertAtCursor(s):R(a=>({...a,content:`${a.content}${s}`}))},onStaged:s=>ke(a=>[...a,s]),onError:s=>l(s,"error")}),_=o.useRef(p.current!==null),O=o.useRef(null);o.useEffect(()=>{_.current||(R(s=>{const a=O.current?s.tags.filter(I=>I!==O.current):s.tags,j=a.includes(u.captureText)?a:[...a,u.captureText];return j===s.tags?s:{...s,tags:j}}),O.current=u.captureText)},[u.captureText]);const le=!_.current&&(i.tags.length===0||i.tags.length===1&&i.tags[0]===u.captureText),Ce=i.content.trim().length>0||!le||i.path.trim().length>0&&i.path!==y.current;if(Xe(r,D,i,Ce),!t)return e.jsx(et,{to:"/",replace:!0});const $=v.phase.kind==="have-audio",Q=i.content.trim().length>0,B=i.content.length>0||i.path!==y.current||!le||$,L=i.path.trim().length>0&&(Q||$),P=b.isPending||we,de=o.useCallback(()=>{if(!L||P)return;const s=tt({content:i.content,path:i.path,tags:i.tags});h&&be(t.id,h),A(null),b.mutate(s,{onSuccess:async a=>{for(const j of V)try{await k.mutateAsync({noteId:a.id,path:j.path,mimeType:j.mimeType})}catch(I){const Z=I instanceof Error?I.message:"Link failed";l(`Failed to attach ${j.filename}: ${Z}`,"error")}r&&H(r,D),l(`Created ${a.path??a.id}`,"success"),c(`/n/${encodeURIComponent(a.id)}`,{replace:!0})},onError:a=>{a instanceof st?A("Session expired. Reconnect to save."):A(a instanceof Error?`${a.message} — if the path is taken, try a different one.`:"Create failed")}})},[t,r,h,i,L,k,b,c,P,l,V]),ue=o.useCallback(async()=>{if(!L||P||v.phase.kind!=="have-audio")return;if(!n||!d){l("Sync queue not ready — try again in a moment.","error");return}A(null);const s=v.phase,a=s.segments,j=s.mimeType,I=i.path.trim(),Z=i.tags,De=nt(i.content),fe=Array.from(new Set([u.captureVoice,...Z,...De].filter(w=>w.length>0)));Q&&fe.push(u.captureText);const he=Array.from(new Set(fe)),Me=new Date,U=at(),_e=!z&&J,X=Et({segments:a,mimeType:j,typedText:i.content,recordedAt:Me,willTranscribe:_e});for(let w=0;w<a.length;w++){const C=pt(new File([a[w].data],X.segments[w].filename,{type:j}));if(C){l(C,"error"),A(C);return}}ne(!0),h&&be(t.id,h);const ge={content:X.body,path:I,metadata:{source:"voice"},...he.length?{tags:he}:{}};try{const w=X.segments.map((N,q)=>({segment:N,data:a[q].data,blobId:rt()})),C=[];try{for(const N of w)await d.put(N.blobId,N.data,j,t.id),C.push(N.blobId)}catch(N){throw(await Promise.allSettled(C.map(G=>d.delete(G)))).forEach((G,$e)=>{G.status==="rejected"&&console.warn(`Could not roll back staged voice blob ${C[$e]}; it may need cleanup.`,G.reason)}),N}await ee(n,{kind:"create-note",localId:U,payload:ge},{vaultId:t.id});for(const{segment:N,blobId:q}of w)await ee(n,{kind:"upload-attachment",blobId:q,filename:N.filename,mimeType:j},{vaultId:t.id}),await ee(n,{kind:"link-attachment",noteId:U,pathRef:ot(q),mimeType:j,transcribe:N.transcribe,...N.segment_index!==void 0?{segment_index:N.segment_index}:{}},{vaultId:t.id});f==null||f.runOnce(),g.setQueryData(["note",t.id,U],it(ge,U)),r&&H(r,D),l("Captured — syncing audio.","success"),v.discardAudio(),c(`/n/${encodeURIComponent(U)}`,{replace:!0})}catch(w){l(w instanceof Error?`Capture failed: ${w.message}`:"Capture failed.","error"),A(w instanceof Error?w.message:"Capture failed")}finally{ne(!1)}},[t,r,d,h,n,i,f,Q,L,c,z,P,l,g,u.captureText,u.captureVoice,J,v]),me=o.useCallback(()=>{$?ue():de()},[$,de,ue]),pe=o.useCallback(()=>{B&&!confirm("Discard this draft?")||(r&&H(r,D),v.discardAudio(),c("/"))},[r,B,c,v]),Ae=o.useCallback(()=>{r&&H(r,D),_.current=!1,O.current=u.captureText,R({...ye,path:y.current,tags:[u.captureText]}),v.discardAudio(),S(null)},[r,v,u.captureText]);o.useEffect(()=>{if(!B)return;const s=a=>{a.preventDefault(),a.returnValue=""};return window.addEventListener("beforeunload",s),()=>window.removeEventListener("beforeunload",s)},[B]);const Ee=s=>{const a=mt(s);!a||i.tags.includes(a)||(_.current=!0,R(j=>({...j,tags:[...j.tags,a]})),F(""))},Pe=s=>{_.current=!0,R(a=>({...a,tags:a.tags.filter(j=>j!==s)}))},Ie=vt({id:"__new__",createdAt:new Date().toISOString()});return e.jsxs("div",{className:"page",children:[e.jsx("nav",{className:"mb-6 text-sm text-fg-dim",children:e.jsx(ct,{to:"/notes",className:"hover:text-accent",children:"← All notes"})}),e.jsxs("article",{children:[e.jsxs("header",{className:"composer mb-6 p-5 md:p-6",children:[e.jsxs("div",{className:"flex flex-wrap items-center justify-between gap-3",children:[e.jsx("span",{className:"eyebrow",children:"New note"}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("button",{type:"button",onClick:pe,className:"btn btn-secondary btn-touch",children:"Cancel"}),e.jsx("button",{type:"button",onClick:me,disabled:!L||P,className:"btn btn-primary btn-touch",title:"Create (⌘S)",children:P?"Creating…":"Create"})]})]}),e.jsx("input",{type:"text",value:i.path,onChange:s=>R(a=>({...a,path:s.target.value})),className:i.path===y.current?"mt-4 w-full border-0 bg-transparent font-sans text-sm text-fg-dim outline-none placeholder:text-fg-dim":"mt-4 w-full border-0 bg-transparent font-serif text-2xl text-fg outline-none placeholder:text-fg-dim md:text-3xl","aria-label":"Note path",placeholder:"Name your note — or just start writing"}),e.jsx("div",{className:"mt-4",children:e.jsx(lt,{tags:i.tags,input:W,onInputChange:F,onAdd:Ee,onRemove:Pe})})]}),x?e.jsxs("div",{role:"status","data-testid":"draft-restored",className:"mb-4 flex flex-wrap items-center justify-between gap-2 rounded-xl border border-accent/30 bg-accent/5 px-3 py-2 text-sm",children:[e.jsxs("span",{className:"text-fg-muted",children:["Unsaved draft restored from ",dt(x),"."]}),e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx("button",{type:"button",onClick:Ae,className:"text-fg-dim hover:text-danger",children:"Discard draft"}),e.jsx("button",{type:"button",onClick:()=>S(null),"aria-label":"Dismiss draft-restored notice",className:"text-fg-dim hover:text-accent",children:"✕"})]})]}):null,se?e.jsx("div",{role:"alert",className:"mb-4 rounded-xl border border-danger-border bg-danger-soft p-3 text-sm text-danger",children:se}):null,Ne?e.jsx(ut,{capability:T}):e.jsxs(e.Fragment,{children:[e.jsx(Dt,{voice:v,minutesRemaining:Y,outOfMinutes:z,transcribe:J,onTranscribeChange:re,showTranscribeToggle:Te}),e.jsx(Pt,{vaultId:t.id,captureEngaged:$})]}),e.jsxs("div",{className:`grid min-h-[60dvh] gap-4 ${m?"":"lg:grid-cols-2"}`,children:[e.jsx(ft,{onDropFiles:E.start,className:"card min-h-0 h-[60dvh] min-w-0",hint:"Images, audio, webm video",children:e.jsx(gt,{ref:K,value:i.content,onChange:s=>R(a=>({...a,content:s})),onSave:me,onCancel:pe,placeholder:"Start writing…",onPasteFile:s=>(E.start(s),!0),onRequestAttachment:()=>{var s;return(s=ae.current)==null?void 0:s.open()},livePreview:m})}),m?null:e.jsx("div",{className:"card min-w-0 overflow-auto p-4 lg:h-[60dvh] lg:min-h-0",children:i.content.trim()?e.jsx(yt,{note:{path:i.path,content:i.content},resolve:Ie}):e.jsx("p",{className:"text-sm text-fg-dim",children:"Preview appears here as you type."})})]}),e.jsxs("section",{className:"mt-6 border-t border-border pt-4",children:[e.jsxs("div",{className:"mb-3 flex items-center justify-between",children:[e.jsx("h2",{className:"font-serif text-xl",children:"Attachments"}),e.jsx(xt,{ref:ae,onPickFiles:E.start})]}),e.jsxs("p",{className:"mb-3 text-xs text-fg-dim",children:["Drop or paste files into the editor. Attachments link to the note when you save. Max 100 MB each. Images, audio, webm video."," ",e.jsx("a",{href:"https://github.com/ParachuteComputer/parachute-vault/issues/127",target:"_blank",rel:"noreferrer",className:"text-accent hover:underline",children:"PDF + mp4 coming"}),"."]}),e.jsx(bt,{uploads:E.uploads,onCancel:E.cancel,onDismiss:E.dismiss}),V.length>0?e.jsx("ul",{className:"mt-3 space-y-1 text-sm",children:V.map(s=>e.jsxs("li",{className:"flex items-center justify-between gap-2 rounded-lg border border-border bg-card/50 px-3 py-1.5 font-mono text-xs text-fg-muted",children:[e.jsx("span",{className:"truncate",children:s.filename}),e.jsx("span",{className:"shrink-0 text-fg-dim",children:"staged"})]},s.path))}):null]})]})]})}function Pt({vaultId:t,captureEngaged:c}){const l=jt(),b=kt(),{made:k,markMade:g}=wt(t),[n,d]=o.useState(null);if(!(c&&!k&&l.supported&&l.value==="keep"))return null;const u=h=>{d(null),b.mutate(h,{onSuccess:()=>g(),onError:()=>d("Couldn't save that choice — this recording is kept (the vault default). We'll ask again next time; you can also set it in Settings.")})};return e.jsxs("div",{"data-testid":"retention-choice",className:"mb-4 flex flex-col gap-2 rounded-xl border border-border bg-card/60 p-3",children:[e.jsx("p",{className:"text-xs text-fg-muted",children:"First voice note here — should this vault keep your audio files after transcribing?"}),e.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[e.jsx("button",{type:"button",onClick:()=>u("keep"),disabled:b.isPending,className:"btn btn-secondary btn-touch",children:"Keep my recordings"}),e.jsx("button",{type:"button",onClick:()=>u("until_transcribed"),disabled:b.isPending,className:"btn btn-secondary btn-touch",children:"Just keep the words"}),e.jsx("span",{className:"text-xs text-fg-dim",children:"(audio deleted after transcribing)"})]}),e.jsx("p",{className:"text-xs text-fg-dim",children:"Either way your capture saves now. Change this anytime in Settings."}),n?e.jsx("p",{className:"text-xs text-danger","data-testid":"retention-choice-error",children:n}):null]})}const It=30;function je({checked:t,disabled:c,onChange:l}){return e.jsxs("div",{className:"flex basis-full items-center gap-3",children:[e.jsx("span",{className:"text-xs text-fg-dim",children:"Transcribe this recording"}),e.jsx("button",{type:"button",role:"switch","aria-checked":t,"aria-label":"Transcribe this recording","data-testid":"transcribe-toggle",disabled:c,onClick:()=>l(!t),className:`relative h-7 w-12 shrink-0 rounded-full transition-colors disabled:opacity-40 ${t?"bg-accent":"bg-border"}`,children:e.jsx("span",{className:`absolute top-0.5 left-0 h-6 w-6 rounded-full bg-card shadow-sm transition-transform ${t?"translate-x-5":"translate-x-0.5"}`})})]})}function Dt({voice:t,minutesRemaining:c,outOfMinutes:l,transcribe:b,onTranscribeChange:k,showTranscribeToggle:g}){const{phase:n,elapsedMs:d,parts:f,startRecording:u,stopRecording:h,discardAudio:y}=t,m=n.kind==="recording",r=n.kind==="requesting",p=!l&&b,i=typeof c=="number"&&c<=It;return n.kind==="have-audio"?e.jsxs("div",{className:"mb-4 flex flex-col gap-2 rounded-xl border border-accent/30 bg-accent/5 p-3",children:[e.jsxs("div",{className:"flex items-center justify-between gap-3",children:[e.jsxs("span",{className:"text-sm text-fg-muted",children:["🎙 Recorded ",te(n.durationMs),n.segments.length>1?` · ${n.segments.length} parts`:""]}),e.jsx("button",{type:"button",onClick:y,className:"text-xs text-fg-dim hover:text-danger",children:"Discard"})]}),e.jsx("audio",{controls:!0,src:n.url,className:"w-full",children:e.jsx("track",{kind:"captions"})}),g?e.jsx(je,{checked:p,disabled:l,onChange:k}):null,e.jsx("p",{className:"text-xs text-fg-dim",children:l?"Saved as audio-only — you're out of transcription minutes this month.":p?"Transcript will be appended once your vault processes it. Save to commit.":"Saved as audio-only — transcription is off for this recording."})]}):e.jsxs("div",{className:"mb-4 flex flex-wrap items-center justify-between gap-3 rounded-xl border border-border bg-card/60 p-3",children:[e.jsx("div",{className:"text-xs text-fg-dim",children:m?f>1?`Recording — tap Stop to finish. (part ${f})`:"Recording — tap Stop to finish.":r?"Requesting microphone…":l?"You're out of transcription minutes this month — this saves as audio-only.":p?"Add a voice memo to this note. Audio gets transcribed and appended.":"Add a voice memo to this note. Saved as audio-only — transcription is off for this recording."}),m?e.jsxs("button",{type:"button",onClick:()=>void h(),"aria-label":`Recording — ${te(d)} — stop`,"aria-pressed":"true",className:"flex min-h-11 items-center gap-2 rounded-full border border-danger-border bg-danger-soft px-4 py-2 text-sm font-medium text-danger",children:[e.jsx("span",{"aria-hidden":"true",className:"animate-pulse",children:"🎙"}),e.jsxs("span",{children:["Stop ",te(d)]})]}):e.jsxs("button",{type:"button",onClick:()=>void u(),"aria-label":"Record voice memo",disabled:r,className:"flex min-h-11 items-center gap-2 rounded-full border border-accent/30 bg-accent/10 px-4 py-2 text-sm font-medium text-accent hover:bg-accent/15 disabled:opacity-40",children:[e.jsx("span",{"aria-hidden":"true",children:"🎙"}),e.jsx("span",{children:r?"Requesting…":"Record"})]}),g?e.jsx(je,{checked:p,disabled:l,onChange:k}):null,i&&!l?e.jsxs("p",{className:"basis-full text-xs text-fg-dim","data-testid":"voice-minutes-left",children:["About ",Math.round(c)," min of transcription left this month."]}):null,n.kind==="denied"?e.jsx("p",{className:"basis-full rounded-xl border border-danger-border bg-danger-soft px-3 py-2 text-xs text-danger",children:n.message}):null]})}function te(t){const c=Math.floor(t/1e3),l=Math.floor(c/60),b=c%60;return`${String(l).padStart(2,"0")}:${String(b).padStart(2,"0")}`}export{Vt as NoteNew};
@@ -1,3 +0,0 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/react-force-graph-2d-CHJEP3br.js","assets/index-oE_2AheL.js","assets/index-BBWRhmyM.css"])))=>i.map(i=>d[i]);
2
- import{aa as k,a as w,aB as M,r as d,aS as D,j as t,ak as $,aT as V,L as g,aU as O,aV as _,aW as z,aX as H,aY as G,aj as W,aZ as K,a_ as q,N as Q,a$ as X,a5 as Y,y as b,a6 as Z,b0 as J,aC as ee,al as P,b1 as te,b2 as se,b3 as ne,b4 as ae,ar as re,b5 as ie,E as oe,z as le,b6 as C,A,a2 as ce,b7 as de,V as ue,ac as me,b8 as he,b9 as xe}from"./index-oE_2AheL.js";import{P as fe,D as pe}from"./PinArchiveButtons-DB8N7LBI.js";import{b as ge,N as be}from"./NoteRenderer-ChWpdbI7.js";function je(e,s){const n=k(),a=w(u=>u.activeVaultId),i=M(),[l,r]=d.useState(!1),o=s&&!Ne(s)?s.path:void 0;return d.useEffect(()=>{if(r(!1),!n||!a||!e||!o)return;let u=!0;const m=()=>{u&&i.invalidateQueries({queryKey:["note",a,e]})},c=ve(n,o,{onUpsert:m,onRemove:m,onStatus:x=>{u&&r(x==="open")}});return()=>{u=!1,r(!1),c()}},[n,a,e,o,i]),{isLive:l}}function Ne(e){return D(e.id)}function ve(e,s,n){return e.subscribe({path:s},{onSnapshot:()=>{},onUpsert:()=>n.onUpsert(),onRemove:()=>n.onRemove(),onStatus:n.onStatus})}const ye=1,we=3,ke=1;function Ce(e,s){const n=new Map,a=new Map;for(const l of s.values())for(const r of l.links??[]){if(r.sourceId===r.targetId||!s.has(r.sourceId)||!s.has(r.targetId))continue;const o=`${r.sourceId}|${r.targetId}|${r.relationship}`;n.has(o)||(n.set(o,{source:r.sourceId,target:r.targetId,relationship:r.relationship}),a.set(r.sourceId,(a.get(r.sourceId)??0)+1),a.set(r.targetId,(a.get(r.targetId)??0)+1))}return{nodes:[...s.values()].map(l=>{var r;return{id:l.id,path:l.path,tags:l.tags,summary:typeof((r=l.metadata)==null?void 0:r.summary)=="string"?l.metadata.summary:void 0,isAnchor:l.id===e,linkCount:a.get(l.id)??0}}),edges:[...n.values()]}}async function Ie(e,s,n,a){const i=new Map;i.set(e.id,e);let l=[e];for(let r=1;r<=s;r++){const o=new Set;for(const c of l)for(const x of c.links??[]){const f=x.sourceId===c.id?x.targetId:x.sourceId;f!==c.id&&(i.has(f)||o.add(f))}if(o.size===0)break;const u=await Promise.all([...o].map(c=>n(c).catch(()=>null)));if(a!=null&&a.cancelled)return i;const m=[];for(const c of u)c&&!i.has(c.id)&&(i.set(c.id,c),m.push(c));l=m}return i}function Ee(e,s,n){const[a,i]=d.useState(null),[l,r]=d.useState(!1);return d.useEffect(()=>{if(!e||!s){i(null),r(!1);return}const o={cancelled:!1};return r(!0),Ie(s,n,u=>e.getNote(u,{includeLinks:!0}),o).then(u=>{o.cancelled||(i(Ce(s.id,u)),r(!1))}).catch(()=>{o.cancelled||r(!1)}),()=>{o.cancelled=!0}},[e,s,n]),{data:a,isLoading:l}}const Se=d.lazy(()=>_(()=>import("./react-force-graph-2d-CHJEP3br.js"),__vite__mapDeps([0,1,2])));function Re({anchor:e}){const[s,n]=d.useState(!0),[a,i]=d.useState(ke),l=k(),{data:r,isLoading:o}=Ee(l,s?e:void 0,a);return t.jsxs("section",{className:"mt-10 border-t border-border pt-6",children:[t.jsxs("header",{className:"mb-4 flex flex-wrap items-center justify-between gap-3",children:[t.jsxs("div",{className:"flex items-center gap-3",children:[t.jsxs("button",{type:"button",onClick:()=>n(u=>!u),"aria-expanded":s,className:"font-serif text-xl text-fg hover:text-accent",children:[s?"▾":"▸"," Neighborhood"]}),s&&r?t.jsxs("span",{className:"text-xs text-fg-dim",children:[r.nodes.length," ",r.nodes.length===1?"note":"notes"]}):null]}),s?t.jsx(Te,{depth:a,onChange:i}):null]}),s?t.jsx(Le,{data:r,isLoading:o}):null]})}function Te({depth:e,onChange:s}){const n=[];for(let a=ye;a<=we;a++)n.push(a);return t.jsxs("fieldset",{className:"flex items-center gap-1 text-xs text-fg-dim",children:[t.jsx("legend",{className:"mr-1 inline-block",children:"Hops"}),n.map(a=>t.jsx("button",{type:"button","aria-pressed":a===e,onClick:()=>s(a),className:a===e?"rounded border border-accent bg-accent/10 px-2 py-0.5 text-accent":"rounded border border-border bg-card px-2 py-0.5 hover:text-accent",children:a},a))]})}function Le({data:e,isLoading:s}){const[n,a]=d.useState(null),i=d.useRef(null);if(d.useEffect(()=>{n&&e&&!e.nodes.some(m=>m.id===n)&&a(null)},[e,n]),!e&&s)return t.jsx(B,{});if(!e)return null;if(e.nodes.length<=1)return t.jsx("div",{className:"rounded-md border border-border bg-card p-6 text-center text-sm text-fg-dim",children:"This note has no neighbors yet."});const l=e.nodes.filter(m=>!m.isAnchor),r=n?e.nodes.find(m=>m.id===n)??null:null,o=m=>{i.current=document.activeElement??null,a(m)},u=m=>{var c,x;a(null),m!=null&&m.restoreFocus&&((x=(c=i.current)==null?void 0:c.focus)==null||x.call(c))};return t.jsxs(t.Fragment,{children:[t.jsx(Be,{data:e,onSelect:o}),r?t.jsx(Ae,{node:r,onClose:u},r.id):null,t.jsx(Pe,{neighbors:l,selectedId:n,onSelect:o})]})}function Pe({neighbors:e,selectedId:s,onSelect:n}){return e.length===0?null:t.jsxs("div",{className:"mt-4",children:[t.jsx("h3",{className:"eyebrow mb-2",children:"Neighbors"}),t.jsx("ul",{className:"flex flex-wrap gap-2",children:e.map(a=>{const i=O(a.path??a.id);return t.jsx("li",{children:t.jsx("button",{type:"button",onClick:()=>n(a.id),"aria-haspopup":"dialog","aria-pressed":s===a.id,"aria-label":`Preview ${i}`,className:`btn btn-sm btn-touch max-w-full ${s===a.id?"btn-primary":"btn-secondary"}`,children:t.jsx("span",{className:"truncate",children:i})})},a.id)})})]})}function Ae({node:e,onClose:s}){var r;const n=$(e.id),a=d.useRef(null);d.useEffect(()=>{var o;(o=a.current)==null||o.focus()},[]);const i=V({id:e.id,path:e.path,content:(r=n.data)==null?void 0:r.content}),l=$e(n.data);return t.jsxs("div",{role:"dialog",ref:a,"aria-label":"Note preview",tabIndex:-1,"data-testid":"neighbor-preview",onKeyDown:o=>{o.key==="Escape"&&s({restoreFocus:!0})},onBlur:o=>{o.currentTarget.contains(o.relatedTarget)||s()},className:"focus-ring card mt-3 p-4",children:[t.jsxs("div",{className:"flex items-start justify-between gap-3",children:[t.jsx("h3",{className:"min-w-0 truncate font-serif text-lg text-fg",children:i}),t.jsx("button",{type:"button",onClick:()=>s({restoreFocus:!0}),"aria-label":"Close preview",className:"shrink-0 text-fg-dim hover:text-accent",children:"✕"})]}),e.tags&&e.tags.length>0?t.jsx("div",{className:"mt-1.5 flex flex-wrap gap-1.5",children:e.tags.map(o=>t.jsxs("span",{className:"chip chip-tag max-w-full break-all",children:["#",o]},o))}):null,t.jsx(Fe,{isPaused:n.fetchStatus==="paused",isPending:n.isPending,isError:n.isError,snippet:l}),t.jsx("div",{className:"mt-3",children:t.jsx(g,{to:`/n/${encodeURIComponent(e.id)}`,className:"btn btn-primary btn-touch",children:"Open note"})})]})}function Fe({isPaused:e,isPending:s,isError:n,snippet:a}){return e&&s?t.jsx("p",{className:"mt-2 text-sm text-fg-dim",children:"Preview unavailable offline."}):s?t.jsx("p",{className:"mt-2 text-sm text-fg-dim",children:"Loading preview…"}):n?t.jsx("p",{className:"mt-2 text-sm text-fg-dim",children:"Couldn't load preview."}):a?t.jsx("p",{className:"mt-2 text-sm text-fg-muted",children:a}):t.jsx("p",{className:"mt-2 text-sm text-fg-dim",children:"No preview text."})}function $e(e){if(!e)return null;const s=(e.preview??z(e.content??"")).trim();return s?s.length>200?`${s.slice(0,200).trimEnd()}…`:s:null}function B(){return t.jsx("div",{"aria-busy":"true",className:"h-[24rem] w-full animate-pulse rounded-md border border-border bg-card"})}function Be({data:e,onSelect:s}){const n=d.useRef(null),[a,i]=d.useState({w:600,h:384});d.useEffect(()=>{const r=n.current;if(!r)return;const o=()=>{const m=r.getBoundingClientRect();i({w:Math.max(320,Math.floor(m.width)),h:384})};o();const u=new ResizeObserver(o);return u.observe(r),()=>u.disconnect()},[]);const l=d.useMemo(()=>({nodes:e.nodes.map(r=>({...r})),links:e.edges.map(r=>({source:r.source,target:r.target,rel:r.relationship}))}),[e]);return t.jsx("div",{ref:n,"data-testid":"neighborhood-graph-canvas",className:"overflow-hidden rounded-md border border-border bg-card",children:t.jsx(d.Suspense,{fallback:t.jsx(B,{}),children:t.jsx(Se,{graphData:l,width:a.w,height:a.h,nodeLabel:r=>Ue(r),nodeVal:r=>{const o=r;return o.isAnchor?8:3+Math.min(o.linkCount,8)},nodeColor:r=>r.isAnchor?"#c9b170":"#8a9a7a",linkColor:()=>"rgba(160, 160, 160, 0.4)",linkDirectionalArrowLength:3,linkDirectionalArrowRelPos:1,cooldownTicks:80,onNodeClick:r=>{s(r.id)}})})})}function Ue(e){const s=[e.path??e.id];return e.tags&&e.tags.length>0&&s.push(`tags: ${e.tags.join(", ")}`),e.summary&&s.push(e.summary),s.join(`
3
- `)}function Me({content:e,attachments:s,onRetry:n,retrying:a=!1}){const i={content:e,attachments:s},l=H(i);if(l==="pending"){const r=G(i);return t.jsxs("output",{"aria-live":"polite",className:"mb-4 inline-flex items-center gap-2 rounded-md border border-sky-500/30 bg-sky-500/5 px-3 py-1.5 text-xs text-sky-300",children:[t.jsx("span",{"aria-hidden":!0,className:"inline-block h-2 w-2 animate-pulse rounded-full bg-sky-400"}),"Transcribing…",r?t.jsxs("span",{className:"text-sky-300/80",children:["part ",Math.min(r.done+1,r.total)," of ",r.total]}):null]})}return l==="failed"?t.jsxs("output",{className:"mb-4 inline-flex flex-wrap items-center gap-2 rounded-md border border-amber-500/30 bg-amber-500/5 px-3 py-1.5 text-xs text-amber-200",children:[t.jsx("span",{children:"Transcription unavailable — open the audio below and add a note by hand."}),n?t.jsx("button",{type:"button",onClick:n,disabled:a,className:"rounded border border-amber-500/40 px-2 py-0.5 font-medium text-amber-100 hover:bg-amber-500/15 disabled:opacity-50",children:a?"Retrying…":"Retry"}):null]}):l==="voice-limit"?t.jsx("output",{className:"mb-4 inline-flex items-center gap-2 rounded-md border border-border bg-bg/40 px-3 py-1.5 text-xs text-fg-muted",children:"Monthly voice limit reached — transcription resumes next month. The audio is saved below."}):null}function rt(){const{id:e}=W(),s=w(i=>i.getActiveVault()),n=K(),a=$(e);return je(e,a.data),d.useEffect(()=>{s&&e&&q(s.id,e)},[s,e]),s?t.jsxs("div",{className:"page",children:[t.jsx("nav",{className:"mb-6 text-sm text-fg-dim",children:t.jsx(g,{to:"/notes",className:"focus-ring hover:text-accent",children:"← All notes"})}),a.isPending?t.jsx(Xe,{}):a.data?t.jsxs(t.Fragment,{children:[a.isError?t.jsx(Y,{}):null,t.jsx(De,{note:a.data,cacheId:e})]}):a.isError?t.jsx(tt,{error:a.error,retry:()=>a.refetch()}):t.jsx(et,{id:e??""})]}):t.jsx(Q,{to:X("/",`${n.pathname}${n.search}`),replace:!0})}function De({note:e,cacheId:s}){var T,L;const n=w(h=>h.getActiveVault()),{roles:a}=Z((n==null?void 0:n.id)??null),i=J(),{mirror:l}=ee(),r=l.state==="offline",o=e.contentEvicted===!0,u=d.useMemo(()=>ge(e),[e]),m=P(h=>h.on),c=P(h=>h.setOn);d.useEffect(()=>{if(!m)return;const h=y=>{y.key==="Escape"&&c(!1)};return window.addEventListener("keydown",h),()=>window.removeEventListener("keydown",h)},[m,c]);const x=e.path??e.id,f=te(e.content),p=f!==null&&!se(f,e)?f:null,j=p!==null?{kind:"title",text:p}:e.path?ne(e.path):{kind:"title",text:e.id},I=d.useMemo(()=>p!==null?{...e,content:ae(e.content??"")}:e,[e,p]),E=typeof((T=e.metadata)==null?void 0:T.summary)=="string"?e.metadata.summary:null,S=d.useMemo(()=>(e.links??[]).filter(h=>h.targetId===e.id&&h.sourceId!==e.id&&h.sourceNote),[e]),R=d.useMemo(()=>{const h=new Set,y=[];for(const N of e.links??[])N.sourceId!==e.id||N.targetId===e.id||N.targetNote&&(h.has(N.targetId)||(h.add(N.targetId),y.push(N)));return y},[e]);return t.jsxs("article",{className:"grid gap-10 lg:grid-cols-[minmax(0,1fr)_18rem]",children:[t.jsxs("div",{className:"min-w-0",children:[t.jsxs("header",{className:"mb-8 border-b border-border pb-5",children:[t.jsx("h1",{className:j.kind==="timestamp"?"page-title title-timestamp":"page-title",children:j.text}),r?t.jsx(Ze,{}):null,e.tags&&e.tags.length>0?t.jsx(ze,{tags:e.tags}):null,E?t.jsx("p",{className:"mt-3 text-fg-muted",children:E}):null,t.jsxs("div",{className:"mt-4 flex flex-wrap items-center gap-2",children:[t.jsx(g,{to:`/n/${encodeURIComponent(e.id)}/edit`,className:"btn btn-secondary btn-touch",children:"Edit"}),t.jsx(fe,{note:e,keyboard:!0}),t.jsx(pe,{note:e}),t.jsxs("button",{type:"button",onClick:()=>c(!0),className:"btn btn-ghost btn-touch",title:"Focus (⌘.)",children:[t.jsx(re,{width:16,height:16}),"Focus"]}),ie(e,a.view)?t.jsx(g,{to:`/views/${encodeURIComponent(e.id)}`,className:"btn btn-secondary btn-touch",children:"Open as view"}):null]}),t.jsx(Ge,{value:x,isPath:!!e.path})]}),t.jsx(Me,{content:e.content??"",attachments:e.attachments,onRetry:()=>i.mutate({cacheId:s??e.id,serverId:e.id}),retrying:i.isPending}),o?t.jsx(Je,{preview:e.preview}):(L=I.content)!=null&&L.trim()?t.jsx(be,{note:I,resolve:u}):p===null?t.jsx(Ye,{noteId:e.id}):null,e.attachments&&e.attachments.length>0?t.jsxs("section",{className:"mt-10 border-t border-border pt-6",children:[t.jsx("h2",{className:"mb-3 font-serif text-xl",children:"Attachments"}),t.jsx("div",{className:"space-y-6",children:e.attachments.map(h=>t.jsx(We,{attachment:h},h.id))})]}):null,t.jsx(Re,{anchor:e})]}),t.jsxs("aside",{className:"space-y-6 text-sm lg:sticky lg:top-24 lg:self-start",children:[t.jsx(Ve,{note:e}),R.length>0?t.jsx(F,{title:"Outbound",links:R,peer:"target"}):null,S.length>0?t.jsx(F,{title:"Inbound",links:S,peer:"source"}):null]})]})}function Ve({note:e}){const s=e.createdAt,n=e.updatedAt,a=Object.entries(e.metadata??{}).filter(([i])=>i!=="summary");return t.jsxs("section",{className:"card shadow-soft p-4",children:[t.jsx("h2",{className:"eyebrow mb-2",children:"Metadata"}),t.jsxs("dl",{className:"space-y-1.5 text-sm",children:[e.path?t.jsx(v,{label:"Title",value:t.jsx("span",{className:"font-mono text-xs break-all",children:e.path})}):null,t.jsx(v,{label:"ID",value:t.jsx("span",{className:"font-mono text-xs break-all",children:e.id})}),t.jsx(v,{label:"Created",value:t.jsx("time",{title:s,children:A(s)})}),n?t.jsx(v,{label:"Updated",value:t.jsx("time",{title:n,children:A(n)})}):null,e.path?t.jsx(v,{label:"Path",value:t.jsx(ce,{value:e.path,label:"note path",className:"mt-1"})}):null,a.map(([i,l])=>t.jsx(v,{label:i,value:t.jsx("span",{className:"break-all text-fg-muted",children:String(l)})},i))]}),t.jsx(Oe,{noteId:e.id}),e.path?t.jsx(_e,{path:e.path}):null,t.jsx(de,{note:e,variant:"detail",className:"mt-3"})]})}function Oe({noteId:e}){const s=w(l=>l.getActiveVault()),{copied:n,copy:a}=C(),i=s?he(s):"";return i?t.jsx("button",{type:"button",onClick:()=>a(xe(i,e)),className:"btn btn-secondary btn-touch mt-3 w-full","aria-label":"Copy a shareable link to this note",children:n?"Copied ✓":"Copy link"}):null}function _e({path:e}){const{copied:s,copy:n}=C();return t.jsx("button",{type:"button",onClick:()=>n(e),className:"btn btn-secondary btn-touch mt-3 w-full","aria-label":"Copy reference to this note",children:s?"Copied ✓":"Copy reference"})}function v({label:e,value:s}){return t.jsxs("div",{className:"flex flex-col gap-0.5",children:[t.jsx("dt",{className:"eyebrow",children:e}),t.jsx("dd",{children:s})]})}function ze({tags:e}){return t.jsx("div",{className:"mt-2 flex flex-wrap gap-1","aria-label":"Tags",children:e.map(s=>t.jsxs(g,{to:`/tags/${encodeURIComponent(s)}`,className:"chip chip-tag focus-ring max-w-full break-all",children:["#",s]},s))})}function He(e){return t.jsxs("svg",{width:12,height:12,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:1.75,strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...e,children:[t.jsx("rect",{x:"9",y:"9",width:"11",height:"11",rx:"2"}),t.jsx("path",{d:"M5 15H4.5A1.5 1.5 0 0 1 3 13.5v-9A1.5 1.5 0 0 1 4.5 3h9A1.5 1.5 0 0 1 15 4.5V5"})]})}function Ge({value:e,isPath:s}){const{copied:n,copy:a}=C();return t.jsxs("button",{type:"button",onClick:()=>a(e),"aria-label":s?"Copy path":"Copy note id",className:"focus-ring group mt-4 flex max-w-full items-center gap-1.5 rounded text-fg-dim transition-colors hover:text-fg-muted",children:[t.jsx(He,{className:"shrink-0 opacity-70 transition-opacity group-hover:opacity-100"}),t.jsx("span",{className:"min-w-0 truncate font-mono text-xs",children:e}),n?t.jsx("span",{className:"shrink-0 text-xs text-fg-muted",children:"Copied"}):null]})}function F({title:e,links:s,peer:n}){return t.jsxs("section",{className:"card shadow-soft p-4",children:[t.jsxs("h2",{className:"eyebrow mb-2 tabular-nums",children:[e," (",s.length,")"]}),t.jsx("ul",{className:"space-y-1.5",children:s.map(a=>{var o;const i=n==="source"?a.sourceNote:a.targetNote;if(!i)return null;const l=i.path??i.id,r=typeof((o=i.metadata)==null?void 0:o.summary)=="string"?i.metadata.summary:null;return t.jsx("li",{children:t.jsxs(g,{to:`/n/${encodeURIComponent(i.id)}`,className:"block rounded px-1 py-0.5 hover:bg-bg/50",children:[t.jsx("div",{className:"truncate font-mono text-xs text-fg-muted hover:text-accent",children:l}),r?t.jsx("div",{className:"mt-0.5 line-clamp-2 text-xs text-fg-dim",children:r}):null]})},`${a.sourceId}->${a.targetId}:${a.relationship}`)})})]})}function We({attachment:e}){const s=e.filename;if(!s||!e.url)return t.jsx("figure",{className:"card shadow-soft p-3",children:t.jsx(U,{})});const n=(e.mimeType??"").toLowerCase();return t.jsxs("figure",{className:"card shadow-soft p-3",children:[t.jsxs("figcaption",{className:"mb-2 flex items-baseline justify-between gap-3",children:[t.jsx("span",{className:"truncate font-mono text-xs text-fg-muted",children:s}),typeof e.size=="number"?t.jsx("span",{className:"shrink-0 text-xs text-fg-dim",children:Qe(e.size)}):null]}),t.jsx(Ke,{attachment:e,mime:n,filename:s})]})}function U(){return t.jsxs("div",{className:"flex items-center gap-2 text-sm text-fg-dim","aria-busy":"true",children:[t.jsx(b,{className:"h-4 w-32"}),t.jsx("span",{children:"Processing…"})]})}function Ke({attachment:e,mime:s,filename:n}){const a=k(),[i,l]=d.useState(null),[r,o]=d.useState(null),u=qe(s,n),m=u!=="other",c=e.url;if(d.useEffect(()=>{if(!m||!c||!a)return;let f=!1,p=null;return o(null),a.fetchAttachmentBlob(c).then(j=>{f||(p=URL.createObjectURL(j),l(p))}).catch(j=>{f||o(j instanceof Error?j.message:"Failed to load attachment")}),()=>{f=!0,p&&URL.revokeObjectURL(p)}},[m,c,a]),!c)return t.jsx(U,{});if(r)return t.jsx("p",{className:"text-sm text-danger",children:r});if(m&&!i)return t.jsx(b,{className:"h-32 w-full"});const x=i??c;return u==="image"?t.jsx("img",{src:x,alt:n,className:"max-h-[32rem] rounded"}):u==="audio"?t.jsx("audio",{controls:!0,src:x,className:"w-full"}):u==="video"?t.jsx("video",{controls:!0,src:x,className:"w-full rounded"}):u==="pdf"?t.jsxs(t.Fragment,{children:[t.jsx("iframe",{src:x,title:n,className:"h-[40rem] w-full rounded border border-border"}),t.jsxs("a",{href:x,download:n,className:"mt-2 inline-block text-sm text-accent hover:underline",children:["Download ",n]})]}):t.jsxs("a",{href:x,download:n,className:"text-sm text-accent hover:underline",children:["Download ",n]})}function qe(e,s){if(e.startsWith("image/"))return"image";if(e.startsWith("audio/"))return"audio";if(e.startsWith("video/"))return"video";if(e==="application/pdf")return"pdf";const n=s.toLowerCase().split(".").pop()??"";return["png","jpg","jpeg","gif","webp","svg"].includes(n)?"image":["mp3","wav","ogg","m4a","flac"].includes(n)?"audio":["mp4","webm","mov"].includes(n)?"video":n==="pdf"?"pdf":"other"}function Qe(e){return e<1024?`${e} B`:e<1024*1024?`${(e/1024).toFixed(1)} KB`:e<1024*1024*1024?`${(e/(1024*1024)).toFixed(1)} MB`:`${(e/(1024*1024*1024)).toFixed(2)} GB`}function Xe(){return t.jsxs("div",{className:"grid gap-10 lg:grid-cols-[minmax(0,1fr)_18rem]","aria-busy":"true",children:[t.jsxs("div",{className:"min-w-0 space-y-3",children:[t.jsx(b,{className:"h-3 w-32"}),t.jsx(b,{className:"h-8 w-2/3"}),t.jsx(b,{className:"h-4 w-full"}),t.jsx("div",{className:"mt-6 space-y-2",children:[0,1,2,3,4,5].map(e=>t.jsx(b,{className:"h-3",width:`${70+e*13%25}%`},e))})]}),t.jsxs("div",{className:"space-y-4",children:[t.jsx(b,{className:"h-32"}),t.jsx(b,{className:"h-24"})]})]})}function Ye({noteId:e}){return t.jsxs("p",{className:"my-8 font-serif text-lg italic text-fg-muted",children:["Nothing here yet."," ",t.jsx(g,{to:`/n/${encodeURIComponent(e)}/edit`,className:"not-italic text-accent hover:underline",children:"Start writing →"})]})}function Ze(){return t.jsx("p",{className:"mt-2",children:t.jsx("span",{className:"chip bg-bg-soft text-fg-muted",title:"Served from your offline copy",children:"Saved copy"})})}function Je({preview:e}){return t.jsxs("div",{className:"my-8",children:[e?t.jsx("p",{className:"mb-4 text-fg-muted",children:e}):null,t.jsx("p",{className:"font-serif text-lg italic text-fg-muted",children:"Connect to load this note."})]})}function et({id:e}){return t.jsx(le,{title:t.jsx("span",{className:"font-serif text-xl text-fg",children:"Note not found"}),description:t.jsxs(t.Fragment,{children:["No note with id ",t.jsx("span",{className:"font-mono",children:e})," in this vault."]}),action:t.jsx(g,{to:"/notes",className:"text-sm text-accent hover:underline",children:"Back to all notes"})})}function tt({error:e,retry:s}){const n=e instanceof ue,a=e instanceof me,i=n?"Session expired":a?"Note not found":"Could not load note",l=n?e.message:a?"Couldn't find this note. It may have been deleted, or the link may be wrong.":"Something went wrong loading this note. You can try again, or head back to your notes.";return t.jsx(oe,{title:i,message:t.jsxs(t.Fragment,{children:[l,n?null:t.jsxs("details",{className:"mt-3",children:[t.jsx("summary",{className:"cursor-pointer text-xs text-fg-dim hover:text-fg-muted",children:"Technical detail"}),t.jsx("p",{className:"mt-1 whitespace-pre-wrap break-words font-mono text-xs text-fg-dim",children:e.message})]})]}),retry:n?void 0:s,action:n?t.jsx(g,{to:"/add",className:"btn btn-primary",children:"Reconnect vault"}):t.jsx(g,{to:"/notes",className:"btn btn-secondary btn-touch",children:"Back to notes"})})}export{rt as NoteView};
@@ -1 +0,0 @@
1
- import{a as T,j as e,N as C,L as j,bh as k,ab as y,r as d,bi as E,bj as A,bk as O,bl as R,bm as L,a6 as M,bn as P,bo as N,bp as g,aC as $,bq as _,br as I,A as D,bs as V,b as z,u as B,g as F,bt as G,bu as H,h as U,i as Y,bv as K}from"./index-oE_2AheL.js";import{u as q,a as Q,b as W,c as X}from"./transcribe-default-DXKy7pnW.js";import{r as Z,w as J}from"./editor-mode-D9fveTEx.js";import"./types-BaJkUfo6.js";function pe(){const t=T(a=>a.getActiveVault());return t?e.jsxs("div",{className:"page-prose",children:[e.jsxs("header",{className:"mb-10",children:[e.jsx("nav",{className:"mb-4 text-sm text-fg-dim",children:e.jsx(j,{to:"/",className:"focus-ring hover:text-accent",children:"← Home"})}),e.jsx("p",{className:"eyebrow mb-1",children:t.name}),e.jsx("h1",{className:"page-title",children:"Settings"}),e.jsx("p",{className:"mt-2 text-fg-muted",children:"Everything about this vault, in one calm place."})]}),e.jsxs("div",{className:"space-y-8",children:[e.jsx(ee,{}),e.jsx(se,{}),e.jsx(ne,{vaultId:t.id}),e.jsx(ie,{}),e.jsx(re,{}),e.jsx(de,{vaultId:t.id}),e.jsx(ue,{vaultId:t.id}),e.jsx(le,{vaultId:t.id}),e.jsx(oe,{})]})]}):e.jsx(C,{to:"/",replace:!0})}function ee(){return e.jsxs("section",{"aria-label":"Manage",children:[e.jsx("h2",{className:"eyebrow mb-3",children:"Manage"}),e.jsxs("div",{className:"card divide-y divide-border rounded-xl shadow-soft",children:[e.jsx(b,{to:"/account",title:"Account",description:"Your plan, billing, hosted vaults, and sign-in — managed in the app."}),e.jsx(te,{}),e.jsx(b,{to:"/connect",title:"Connections",description:"Connect Claude, ChatGPT, or any MCP client to this vault."}),e.jsx(b,{to:"/vaults",title:"Vaults",description:"Add a vault, switch between them, or export."})]})]})}function te(){const t=z(),a=B(r=>r.identityEpoch),[n,s]=d.useState(null),[i,u]=d.useState(!1);if(d.useEffect(()=>{let r=!0;return F().then(o=>{r&&s(o.signed_in?{identity:o.email??o.username??null,csrf:o.csrf}:null)}).catch(()=>{r&&s(null)}),()=>{r=!1}},[a]),!n)return null;const{identity:c,csrf:h}=n;async function x(){u(!0);try{await U(h)}finally{Y(),t("/",{replace:!0})}}return e.jsxs("div",{className:"flex items-center justify-between gap-4 px-5 py-4",children:[e.jsxs("span",{className:"min-w-0",children:[e.jsxs("span",{className:"block font-medium text-fg",children:["Signed in",c?` as ${c}`:""]}),e.jsx("span",{className:"mt-0.5 block text-sm text-fg-muted",children:"Signing out ends your account session on this device. Vaults already connected here stay until you remove them."})]}),e.jsx("button",{type:"button",onClick:x,disabled:i,className:"btn btn-secondary btn-touch shrink-0",children:i?"Signing out…":"Sign out"})]})}function b({to:t,href:a,title:n,description:s}){const i=e.jsxs(e.Fragment,{children:[e.jsxs("span",{className:"min-w-0",children:[e.jsx("span",{className:"block font-medium text-fg",children:n}),e.jsx("span",{className:"mt-0.5 block text-sm text-fg-muted",children:s})]}),e.jsx("span",{"aria-hidden":"true",className:"shrink-0 text-fg-dim",children:a?"↗":"→"})]}),u="focus-ring flex items-center justify-between gap-4 px-5 py-4 transition-colors hover:bg-bg-soft first:rounded-t-xl last:rounded-b-xl";return a?e.jsx("a",{href:a,className:u,children:i}):e.jsx(j,{to:t??"/",className:u,children:i})}function se(){return e.jsxs("section",{className:"card space-y-3 rounded-xl p-6 shadow-soft",children:[e.jsxs("div",{children:[e.jsx("h2",{className:"font-serif text-xl text-fg",children:"Import notes"}),e.jsx("p",{className:"mt-1 text-sm text-fg-muted",children:"Bring in an Obsidian vault zip or a folder of markdown files. Parsed in your browser; previewed before any note lands in the vault."})]}),e.jsx(j,{to:"/import",className:"btn btn-primary btn-touch",children:"Open importer"})]})}const ae=[{value:"keep",title:"Keep",help:"Recordings are stored with your notes; included wherever attachments are included."},{value:"until_transcribed",title:"Delete after transcribing",help:"Your words stay; the audio file is removed once the transcript lands."},{value:"never",title:"Never store",help:"Audio is removed even if transcription fails — the transcript is your only copy; failed transcriptions lose the audio."}];function ne({vaultId:t}){const a=k(),n=q(),s=Q(),{markMade:i}=W(t),{transcribeDefault:u,setTranscribeDefault:c}=X(t),h=y(r=>r.push);if((a==null?void 0:a.enabled)===!1)return null;const x=r=>{r===n.value||s.isPending||s.mutate(r,{onSuccess:()=>{i(),h("Voice recording setting saved.","success")},onError:o=>{h(o instanceof Error&&o.message?`Couldn't save: ${o.message}`:"Couldn't save the voice recording setting.","error")}})};return e.jsxs("section",{className:"card space-y-6 rounded-xl p-6 shadow-soft",children:[e.jsxs("div",{children:[e.jsx("h2",{className:"font-serif text-xl text-fg",children:"Voice"}),e.jsx("p",{className:"mt-1 text-sm text-fg-muted",children:"How voice capture behaves in this vault."})]}),e.jsxs("div",{className:"flex items-start justify-between gap-4",children:[e.jsxs("div",{children:[e.jsx("h3",{className:"font-medium text-fg",children:"Transcribe recordings by default"}),e.jsx("p",{className:"mt-1 text-sm text-fg-muted",children:"New voice notes start with transcription on — your words are added to the note. Turn it off for a single recording right where you capture. Applies on this device."})]}),e.jsx("button",{type:"button",role:"switch","aria-checked":u,"aria-label":"Transcribe recordings by default","data-testid":"transcribe-default-toggle",onClick:()=>c(!u),className:`relative h-7 w-12 shrink-0 rounded-full transition-colors ${u?"bg-accent":"bg-border"}`,children:e.jsx("span",{className:`absolute top-0.5 left-0 h-6 w-6 rounded-full bg-card shadow-sm transition-transform ${u?"translate-x-5":"translate-x-0.5"}`})})]}),e.jsxs("div",{className:"space-y-4 border-t border-border pt-6",children:[e.jsxs("div",{children:[e.jsx("h3",{className:"font-medium text-fg",children:"Keep recordings"}),e.jsx("p",{className:"mt-1 text-sm text-fg-muted",children:"What happens to the audio file after a voice note is transcribed. Applies to this vault, from every device connected to it."})]}),n.isLoading?e.jsx("p",{className:"text-sm text-fg-dim",children:"Loading…"}):n.isError?e.jsx("p",{className:"text-sm text-fg-dim","data-testid":"retention-load-error",children:"Couldn't load this setting — check the vault connection."}):e.jsxs(e.Fragment,{children:[e.jsxs("fieldset",{className:"space-y-2",disabled:!n.supported||s.isPending,children:[e.jsx("legend",{className:"sr-only",children:"Voice recording retention"}),ae.map(r=>{const o=n.value===r.value;return e.jsxs("label",{className:`flex items-start gap-3 rounded-xl border p-3 transition-colors ${o?"border-accent bg-accent/5":"border-border hover:border-accent/40"}`,children:[e.jsx("input",{type:"radio",name:"audio-retention",value:r.value,checked:o,onChange:()=>x(r.value),className:"mt-1 accent-accent"}),e.jsxs("span",{children:[e.jsx("span",{className:"block font-medium text-fg",children:r.title}),e.jsx("span",{className:"mt-0.5 block text-sm text-fg-muted",children:r.help})]})]},r.value)})]}),n.supported?null:e.jsx("p",{className:"text-xs text-fg-dim","data-testid":"retention-unsupported",children:"This vault doesn't support changing this yet — recordings are kept. Update the vault to choose."})]})]})]})}function ie(){const[t,a]=d.useState(()=>Z()),n=s=>{a(s),J(s)};return e.jsx("section",{className:"card space-y-4 rounded-xl p-6 shadow-soft",children:e.jsxs("div",{className:"flex items-start justify-between gap-4",children:[e.jsxs("div",{children:[e.jsx("h2",{className:"font-serif text-xl text-fg",children:"Live preview"}),e.jsx("p",{className:"mt-1 text-sm text-fg-muted",children:"Formats your writing as you type — Markdown stays underneath. Turn off for the raw editor with a side-by-side preview."})]}),e.jsx("button",{type:"button",role:"switch","aria-checked":t,"aria-label":"Live preview",onClick:()=>n(!t),className:`relative h-7 w-12 shrink-0 rounded-full transition-colors ${t?"bg-accent":"bg-border"}`,children:e.jsx("span",{className:`absolute top-0.5 left-0 h-6 w-6 rounded-full bg-card shadow-sm transition-transform ${t?"translate-x-5":"translate-x-0.5"}`})})]})})}function re(){const[t,a]=d.useState(()=>E()),n=s=>{a(s),G(s),H(s)};return e.jsxs("section",{className:"card space-y-4 rounded-xl p-6 shadow-soft",children:[e.jsxs("div",{children:[e.jsx("h2",{className:"font-serif text-xl text-fg",children:"Text size"}),e.jsx("p",{className:"mt-1 text-sm text-fg-muted",children:"Affects the editor and rendered notes on this device. Your markdown isn't changed."})]}),e.jsxs("fieldset",{className:"space-y-2",children:[e.jsx("legend",{className:"sr-only",children:"View text size"}),A.map(s=>{const i=t===s;return e.jsxs("label",{className:`flex items-center gap-3 rounded-xl border p-3 transition-colors ${i?"border-accent bg-accent/5":"border-border hover:border-accent/40"}`,children:[e.jsx("input",{type:"radio",name:"text-size",value:s,checked:i,onChange:()=>n(s),className:"accent-accent"}),e.jsx("span",{className:"font-medium text-fg",children:O(s)})]},s)})]})]})}function le({vaultId:t}){const{db:a,mirror:n}=$(),s=y(m=>m.push),[i,u]=d.useState(null),[c,h]=d.useState(null),x=d.useCallback(async()=>{if(!a)return;const[m,l]=await Promise.all([_(a,t),I(a,t)]);u({bytes:m,count:l})},[a,t]);if(d.useEffect(()=>{x()},[x]),!n.enabled)return null;const r=async()=>{if(!c){h("sync");try{await n.syncNow(),await x(),s("Synced offline copy.","success")}catch{s("Couldn't sync the offline copy right now.","error")}finally{h(null)}}},o=async()=>{if(!c&&confirm("Clear this vault's offline copy from this device? Un-synced changes are kept.")){h("clear");try{await n.clearOffline(),await x(),s("Offline copy cleared.","success")}catch{s("Couldn't clear the offline copy.","error")}finally{h(null)}}};return e.jsxs("section",{className:"card space-y-5 rounded-xl p-6 shadow-soft","aria-label":"Offline",children:[e.jsxs("div",{children:[e.jsx("h2",{className:"font-serif text-xl text-fg",children:"Offline"}),e.jsx("p",{className:"mt-1 text-sm text-fg-muted",children:"A copy of this vault is kept on this device so your notes open without a connection."})]}),e.jsxs("dl",{className:"space-y-2 text-sm",children:[e.jsxs("div",{className:"flex items-baseline justify-between gap-4",children:[e.jsx("dt",{className:"text-fg-muted",children:"Status"}),e.jsx("dd",{className:"text-fg",children:ce(n.state)})]}),e.jsxs("div",{className:"flex items-baseline justify-between gap-4",children:[e.jsx("dt",{className:"text-fg-muted",children:"Last synced"}),e.jsx("dd",{className:"text-fg-muted",children:n.lastSyncedAt?D(new Date(n.lastSyncedAt).toISOString()):"never"})]}),e.jsxs("div",{className:"flex items-baseline justify-between gap-4",children:[e.jsx("dt",{className:"text-fg-muted",children:"Saved on this device"}),e.jsx("dd",{className:"text-fg-muted tabular-nums","data-testid":"offline-usage",children:i?`${i.count} note${i.count===1?"":"s"} · ${w(i.bytes)} of ${w(K)}`:"—"})]})]}),e.jsxs("div",{className:"flex flex-wrap items-center gap-3 pt-1",children:[e.jsx("button",{type:"button",onClick:r,disabled:c!==null,className:"btn btn-secondary btn-touch",children:c==="sync"?"Syncing…":"Sync now"}),e.jsx("button",{type:"button",onClick:o,disabled:c!==null,className:"text-sm text-danger hover:underline disabled:opacity-60",children:c==="clear"?"Clearing…":"Clear offline copy"})]})]})}function ce(t){switch(t){case"hydrating":return"Saving your vault…";case"offline":return"Offline — showing your saved vault";case"error":return"Sync error";default:return"Saved for offline"}}function w(t){return t<1024*1024?`${(t/1024).toFixed(0)} KB`:t<1024*1024*1024?`${(t/(1024*1024)).toFixed(1)} MB`:`${(t/(1024*1024*1024)).toFixed(2)} GB`}function oe(){const[t,a]=d.useState(!1);return d.useEffect(()=>{a(V())},[]),t?e.jsx("section",{className:"card rounded-xl p-6 text-sm shadow-soft",children:e.jsxs("p",{className:"text-fg-muted",children:[e.jsx("span",{className:"mr-2 inline-block rounded-full bg-positive-soft px-2 py-0.5 text-xs font-medium text-positive",children:"Installed"}),"Parachute is running as an installed app on this device."]})}):null}const S={auto:{title:"Auto",help:"Show the tree only when the vault has enough folders to make it worth the space."},always:{title:"Always",help:"Always show the tree, even on a tag-flat vault."},never:{title:"Never",help:"Hide the tree. The path-prefix text input still works."}};function de({vaultId:t}){const{mode:a,setMode:n}=R(t);return e.jsxs("section",{className:"card space-y-4 rounded-xl p-6 shadow-soft",children:[e.jsxs("div",{children:[e.jsx("h2",{className:"font-serif text-xl text-fg",children:"Folder tree (Notes sidebar)"}),e.jsx("p",{className:"mt-1 text-sm text-fg-muted",children:"Controls the collapsible folder tree on the notes list page. Auto-detect renders the tree when the vault has at least five top-level folders or twenty notes in folders."})]}),e.jsxs("fieldset",{className:"space-y-2",children:[e.jsx("legend",{className:"sr-only",children:"Path tree visibility"}),L.map(s=>{const i=a===s;return e.jsxs("label",{className:`flex items-start gap-3 rounded-xl border p-3 transition-colors ${i?"border-accent bg-accent/5":"border-border hover:border-accent/40"}`,children:[e.jsx("input",{type:"radio",name:"path-tree-mode",value:s,checked:i,onChange:()=>n(s),className:"mt-1 accent-accent"}),e.jsxs("span",{children:[e.jsx("span",{className:"block font-medium text-fg",children:S[s].title}),e.jsx("span",{className:"mt-0.5 block text-sm text-fg-muted",children:S[s].help})]})]},s)})]})]})}const v={pinned:{title:"Pinned",help:"Tag for notes you want at the top of views."},archived:{title:"Archived",help:"Tag for notes you've moved out of the way."},captureVoice:{title:"Voice capture",help:"Default tag for new voice memos."},captureText:{title:"Text capture",help:"Default tag for quick typed notes."},view:{title:"Saved view",help:"Tag that view notes carry. Used to list them in the Views band."}};function ue({vaultId:t}){const{roles:a,setRoles:n}=M(t),s=P(),i=y(l=>l.push),u=d.useId(),[c,h]=d.useState(a);d.useEffect(()=>h(a),[a]);const x=d.useMemo(()=>{const l=(s.data??[]).map(f=>f.name);return[...new Set(l)].sort((f,p)=>f.localeCompare(p))},[s.data]),r=N.some(l=>c[l].trim()!==a[l]),o=()=>{n(c),i("Tag roles saved.","success")},m=()=>{n(null),h(g),i("Tag roles reset to defaults.","success")};return e.jsxs("section",{className:"card space-y-5 rounded-xl p-6 shadow-soft",children:[e.jsxs("div",{children:[e.jsx("h2",{className:"font-serif text-xl text-fg",children:"Tag roles"}),e.jsx("p",{className:"mt-1 text-sm text-fg-muted",children:"Point each role at whatever tag your vault already uses. Changes apply to future notes only — existing notes keep their current tags."})]}),e.jsx("datalist",{id:u,children:x.map(l=>e.jsx("option",{value:l},l))}),e.jsx("div",{className:"space-y-4",children:N.map(l=>e.jsxs("label",{className:"block text-sm",children:[e.jsxs("span",{className:"mb-1.5 flex items-baseline justify-between gap-2",children:[e.jsx("span",{className:"font-medium text-fg",children:v[l].title}),e.jsxs("span",{className:"text-xs text-fg-dim",children:["default: #",g[l]]})]}),e.jsx("input",{type:"text",value:c[l],onChange:f=>h(p=>({...p,[l]:f.target.value})),list:u,placeholder:g[l],"aria-label":`${v[l].title} tag role`,spellCheck:!1,autoCapitalize:"none",autoCorrect:"off",className:"input input-on-bg"}),e.jsx("span",{className:"mt-1.5 block text-xs text-fg-dim",children:v[l].help})]},l))}),e.jsxs("div",{className:"flex flex-wrap items-center gap-4 pt-1",children:[e.jsx("button",{type:"button",onClick:o,disabled:!r,className:"btn btn-primary btn-lg",children:"Save"}),e.jsx("button",{type:"button",onClick:m,className:"btn btn-ghost",children:"Reset to defaults"})]})]})}export{pe as Settings};
@@ -1 +0,0 @@
1
- import{ab as z,r,ae as F,V as R,j as e,a as D,by as I,aC as V,bz as B,bA as K,bB as U,N as W,y as Z,E as _,L as A,z as P}from"./index-oE_2AheL.js";import{T as q}from"./TagSchemaEditor-_n7m_7Xz.js";const O=t=>Object.values(t).reduce((n,g)=>n+g,0);function L({mode:t,sources:n,tagOptions:g,onClose:i,onRun:y,onRunMerge:l,pending:o,offline:c}){const m=z(a=>a.push),d=r.useId(),[p,h]=r.useState(t==="rename"?n[0]??"":""),[f,u]=r.useState(null),[x,v]=r.useState(null),[w,S]=r.useState(!1),b=r.useRef(null);r.useEffect(()=>{var a,s;(a=b.current)==null||a.focus(),(s=b.current)==null||s.select()},[]),r.useEffect(()=>{const a=s=>{s.key==="Escape"&&i()};return window.addEventListener("keydown",a),()=>window.removeEventListener("keydown",a)},[i]);const j=p.trim().replace(/^#/,""),N=!o&&!c&&!w&&j.length>0&&!(t==="rename"&&j===n[0]),T=r.useCallback(async()=>{if(N){u(null),v(null);try{const a=await y(j);if("renamed"in a)m(`Renamed on ${a.renamed} note${a.renamed===1?"":"s"}.`,"success");else{const s=O(a.merged);m(`Merged into #${a.target} on ${s} note${s===1?"":"s"}.`,"success")}i()}catch(a){if(a instanceof F&&t==="rename"&&l){v(a.target);return}a instanceof R?u("Session expired. Reconnect to retry."):u(a instanceof Error?a.message:"Operation failed.")}}},[N,j,t,i,y,l,m]),E=r.useCallback(async()=>{if(!(!x||!l)){u(null),S(!0);try{const a=await l(x),s=O(a.merged);m(`Merged into #${a.target} on ${s} note${s===1?"":"s"}.`,"success"),i()}catch(a){a instanceof R?u("Session expired. Reconnect to retry."):u(a instanceof Error?a.message:"Merge failed."),S(!1)}}},[x,i,l,m]),k=t==="rename"?"Rename tag":`Merge ${n.length} tags`;return e.jsx("dialog",{open:!0,"aria-labelledby":"tag-op-title",className:"fixed inset-0 z-40 m-0 flex h-full max-h-full w-full max-w-full items-center justify-center bg-black/60 p-4",onMouseDown:a=>{a.target===a.currentTarget&&i()},children:e.jsxs("div",{className:"w-full max-w-md rounded-2xl border border-border bg-card p-6 shadow-lift",children:[e.jsx("h2",{id:"tag-op-title",className:"mb-2 font-serif text-xl text-fg",children:k}),e.jsxs("p",{className:"mb-3 text-sm text-fg-muted",children:[t==="rename"?e.jsxs(e.Fragment,{children:["Rename ",e.jsx(C,{children:n[0]})," on every note that carries it. Notes that already have the new tag will end up with one copy."]}):e.jsxs(e.Fragment,{children:["Combine"," ",n.map((a,s)=>e.jsxs("span",{children:[e.jsx(C,{children:a}),s<n.length-1?", ":""]},a))," ","into one tag. The originals are removed."]})," ","Changes apply atomically on the vault."]}),e.jsxs("label",{className:"mb-3 block text-sm",children:[e.jsx("span",{className:"mb-1 block text-fg-muted",children:t==="rename"?"New tag name":"Target tag"}),e.jsx("input",{ref:b,type:"text",value:p,onChange:a=>{h(a.target.value),x&&v(null)},onKeyDown:a=>{a.key==="Enter"&&N&&T()},list:d,"aria-label":t==="rename"?"New tag name":"Merge target tag",spellCheck:!1,autoCapitalize:"none",autoCorrect:"off",className:"w-full rounded-lg border border-border bg-bg/40 px-2.5 py-1.5 font-mono text-sm text-fg focus:border-accent focus:outline-none",autoComplete:"off"}),e.jsx("datalist",{id:d,children:g.map(a=>e.jsx("option",{value:a},a))})]}),c?e.jsx("p",{className:"mb-3 text-sm text-amber-300",children:"Offline — tag operations need a live vault connection."}):null,x?e.jsxs("div",{role:"alert",className:"mb-3 rounded-md border border-amber-500/40 bg-amber-500/5 p-3 text-sm",children:[e.jsxs("p",{className:"mb-2 text-amber-300",children:["A tag named ",e.jsx(C,{children:x})," already exists."]}),e.jsxs("p",{className:"mb-3 text-fg-muted",children:["Merge ",e.jsx(C,{children:n[0]})," into ",e.jsx(C,{children:x})," instead? Notes that carry both end up with one copy."]}),e.jsx("button",{type:"button",onClick:()=>void E(),disabled:w,className:"rounded-lg bg-accent px-3 py-1.5 text-xs font-medium text-(--color-on-accent) hover:bg-accent-hover disabled:opacity-40",children:w?"Merging…":`Merge into #${x}`})]}):null,f?e.jsx("p",{role:"alert",className:"mb-3 text-sm text-red-400",children:f}):null,e.jsxs("div",{className:"flex justify-end gap-2",children:[e.jsx("button",{type:"button",onClick:i,className:"min-h-11 rounded-lg border border-border bg-card px-3 py-1.5 text-sm text-fg-muted hover:text-fg",children:"Cancel"}),e.jsx("button",{type:"button",onClick:()=>void T(),disabled:!N,className:"min-h-11 rounded-lg bg-accent px-4 py-1.5 text-sm font-medium text-(--color-on-accent) hover:bg-accent-hover disabled:opacity-40",children:o?t==="rename"?"Renaming…":"Merging…":t==="rename"?"Rename":"Merge"})]})]})})}function C({children:t}){return e.jsxs("span",{className:"rounded bg-bg/60 px-1 py-0.5 font-mono text-xs text-fg",children:["#",t]})}function te(){const t=D(s=>s.getActiveVault()),n=I(),{isOnline:g}=V(),{isPinned:i,togglePin:y}=B((t==null?void 0:t.id)??null),[l,o]=r.useState(""),[c,m]=r.useState("count"),[d,p]=r.useState(new Set),[h,f]=r.useState(null),[u,x]=r.useState(!1),[v,w]=r.useState(null),S=K(),b=U(),j=r.useMemo(()=>H(n.data??[],l,c),[n.data,l,c]),N=r.useMemo(()=>(n.data??[]).map(s=>s.name),[n.data]),T=s=>{p(M=>{const $=new Set(M);return $.has(s)?$.delete(s):$.add(s),$})},E=()=>p(new Set);if(!t)return e.jsx(W,{to:"/",replace:!0});const k=d.size,a=!g;return e.jsxs("div",{className:"page",children:[e.jsxs("header",{className:"mb-5 flex flex-wrap items-baseline justify-between gap-x-4 gap-y-3 md:mb-6",children:[e.jsxs("div",{children:[e.jsx("p",{className:"eyebrow",children:t.name}),e.jsx("h1",{className:"page-title",children:"Tags"})]}),e.jsxs("button",{type:"button",onClick:()=>m(s=>s==="count"?"alpha":"count"),className:"focus-ring text-sm text-fg-muted hover:text-accent","aria-label":"Toggle tag sort",children:["Sort: ",c==="count"?"most used":"A–Z"]})]}),e.jsx("input",{type:"search",placeholder:"Filter tags…",value:l,onChange:s=>o(s.target.value),"aria-label":"Filter tags",className:"input mb-6"}),k>0?e.jsxs("div",{className:"mb-6 flex flex-wrap items-center gap-3 rounded-xl border border-accent/30 bg-accent/5 px-4 py-3 text-sm","aria-label":"Tag selection actions",children:[e.jsxs("span",{className:"text-fg-muted",children:[k," selected: ",Array.from(d).join(", ")]}),e.jsx("button",{type:"button",onClick:()=>x(!0),disabled:k<2||a,className:"btn btn-primary btn-sm",children:"Merge into…"}),e.jsx("button",{type:"button",onClick:E,className:"btn btn-ghost btn-sm",children:"Clear"})]}):null,n.isPending?e.jsx(J,{}):n.isError?e.jsx(Q,{error:n.error}):j.length===0?e.jsx(X,{filtering:l.trim().length>0,hasAny:(n.data??[]).length>0}):e.jsx("ul",{className:"card shadow-soft divide-y divide-border rounded-xl","aria-label":"Tag list",children:j.map(s=>e.jsx(G,{tag:s,selected:d.has(s.name),onToggle:()=>T(s.name),onRename:()=>f(s.name),onEditSchema:()=>w(s.name),pinned:i(s.name),onTogglePin:()=>y(s.name),offline:a},s.name))}),n.data&&n.data.length>0?e.jsxs("p",{className:"mt-6 text-xs tabular-nums text-fg-dim",children:[j.length," / ",n.data.length," tag",n.data.length===1?"":"s"]}):null,h!==null?e.jsx(L,{mode:"rename",sources:[h],tagOptions:N,onClose:()=>f(null),pending:S.isPending||b.isPending,offline:a,onRun:s=>S.mutateAsync({oldName:h,newName:s}),onRunMerge:s=>b.mutateAsync({sources:[h],target:s})}):null,u?e.jsx(L,{mode:"merge",sources:Array.from(d),tagOptions:N,onClose:()=>x(!1),pending:b.isPending,offline:a,onRun:async s=>{const M=await b.mutateAsync({sources:Array.from(d),target:s});return E(),M}}):null,v!==null?e.jsx(q,{tagName:v,onClose:()=>w(null)}):null]})}function G({tag:t,selected:n,onToggle:g,onRename:i,onEditSchema:y,pinned:l,onTogglePin:o,offline:c}){const m=t.fields?Object.keys(t.fields):[],d=t.parent_names??[],p=!!t.description||m.length>0||d.length>0;return e.jsxs("li",{className:"px-4 py-3 text-sm transition-colors hover:bg-bg-soft",children:[e.jsxs("div",{className:"flex flex-wrap items-center gap-3",children:[e.jsx("input",{type:"checkbox",checked:n,onChange:g,"aria-label":`Select tag ${t.name}`,className:"accent-accent"}),e.jsxs(A,{to:`/tags/${encodeURIComponent(t.name)}`,className:"chip chip-tag focus-ring shrink-0 max-w-full break-all",children:[e.jsxs("span",{className:"font-mono",children:["#",t.name]}),e.jsx("span",{className:"tabular-nums opacity-70",children:t.count??0})]}),e.jsxs("div",{className:"-my-3 ml-auto flex shrink-0 items-center gap-4",children:[e.jsx("button",{type:"button",onClick:o,className:l?"focus-ring flex min-h-11 items-center text-xs font-medium text-accent hover:text-accent-hover":"focus-ring flex min-h-11 items-center text-xs text-fg-muted hover:text-accent","aria-label":l?`Unpin tag ${t.name}`:`Pin tag ${t.name}`,"aria-pressed":l,title:l?"Pinned to home strip — click to unpin":"Pin to home strip",children:l?"★ Pinned":"☆ Pin"}),e.jsx("button",{type:"button",onClick:y,disabled:c,className:"focus-ring flex min-h-11 items-center text-xs text-fg-muted hover:text-accent disabled:opacity-40","aria-label":`Edit schema for tag ${t.name}`,children:p?"Schema":"+ Schema"}),e.jsx("button",{type:"button",onClick:i,disabled:c,className:"focus-ring flex min-h-11 items-center text-xs text-fg-muted hover:text-accent disabled:opacity-40","aria-label":`Rename tag ${t.name}`,children:"Rename"})]})]}),p?e.jsxs("dl",{className:"ml-8 mt-2 flex flex-wrap items-baseline gap-x-3 gap-y-1 text-xs text-fg-dim","aria-label":`Schema for ${t.name}`,children:[t.description?e.jsxs("div",{className:"flex w-full items-baseline gap-1.5",children:[e.jsx("dt",{className:"sr-only",children:"Description"}),e.jsx("dd",{className:"italic",children:t.description})]}):null,m.length>0?e.jsxs("div",{className:"flex items-baseline gap-1.5",children:[e.jsx("dt",{className:"uppercase tracking-wider",children:"Fields"}),e.jsx("dd",{className:"font-mono text-fg-muted",children:m.map(h=>{var f,u;return`${h}: ${((u=(f=t.fields)==null?void 0:f[h])==null?void 0:u.type)??"?"}`}).join(", ")})]}):null,d.length>0?e.jsxs("div",{className:"flex items-baseline gap-1.5",children:[e.jsx("dt",{className:"uppercase tracking-wider",children:"Parents"}),e.jsx("dd",{className:"font-mono text-fg-muted",children:d.join(", ")})]}):null]}):null]})}function H(t,n,g){const i=n.trim().toLowerCase(),l=[...i?t.filter(o=>o.name.toLowerCase().includes(i)):t];return g==="alpha"?l.sort((o,c)=>o.name.localeCompare(c.name)):l.sort((o,c)=>(c.count??0)-(o.count??0)||o.name.localeCompare(c.name)),l}function J(){return e.jsx("div",{className:"space-y-2","aria-busy":"true",children:[0,1,2,3,4].map(t=>e.jsx(Z,{className:"h-12 rounded-xl"},t))})}function Q({error:t}){const n=t instanceof R;return e.jsx(_,{title:n?"Session expired":"Could not load tags",message:t.message,action:n?e.jsx(A,{to:"/add",className:"btn btn-primary",children:"Reconnect vault"}):void 0})}function X({filtering:t,hasAny:n}){return t&&n?e.jsx(P,{title:"No tags match your filter."}):e.jsx(P,{title:"No tags in this vault yet.",action:e.jsx(A,{to:"/new",className:"btn btn-primary",children:"Create a note"})})}export{te as Tags};
@@ -1 +0,0 @@
1
- import{F as h,a,j as e,L as n,bK as u,b8 as x}from"./index-oE_2AheL.js";import{v as p}from"./provenance-CPDeMpx4.js";import{a as v}from"./types-BaJkUfo6.js";function N(){const i=h(),o=a(s=>s.vaults),d=a(s=>s.activeVaultId),m=a(s=>s.removeVault),c=Object.values(o).sort((s,t)=>s.name.localeCompare(t.name));return e.jsxs("div",{className:"page-prose",children:[e.jsxs("header",{className:"mb-8 flex flex-wrap items-center justify-between gap-4",children:[e.jsxs("div",{children:[e.jsx("h1",{className:"page-title",children:"Vaults"}),e.jsx("p",{className:"mt-2 text-fg-muted",children:"Every vault you've connected, in one place."})]}),e.jsx(n,{to:"/add-vault",className:"btn btn-primary btn-touch",children:"Add vault"})]}),c.length===0?e.jsxs("div",{className:"card rounded-xl p-8 text-center shadow-soft",children:[e.jsx("p",{className:"mb-1 font-serif text-lg text-fg",children:"No vaults connected yet."}),e.jsx("p",{className:"mb-5 text-sm text-fg-muted",children:"Open one you already have, create a new one, or connect a self-hosted vault."}),e.jsx(n,{to:"/add-vault",className:"btn btn-primary btn-touch",children:"Add vault"})]}):e.jsx("ul",{className:"space-y-3",children:c.map(s=>{const t=s.id===d,l=v(s.url),r=p(s);return e.jsxs("li",{className:"card rounded-xl p-5 shadow-soft",children:[e.jsxs("div",{className:"flex items-center justify-between gap-4",children:[e.jsxs("div",{className:"min-w-0",children:[e.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[e.jsx("span",{className:"font-serif text-lg text-fg",children:s.name}),t?e.jsx("span",{className:"chip chip-tag-active",children:"active"}):null,e.jsxs("span",{className:"chip",children:[r.kind==="cloud"?"☁":"⌂"," ",r.label]}),l?e.jsx("span",{className:"chip border-warning/40 bg-warning-soft text-warning",children:"needs reconnect"}):null]}),e.jsx("p",{className:"mt-1 truncate note-id",children:s.url})]}),e.jsxs("div",{className:"flex shrink-0 items-center gap-4 text-sm",children:[t?null:e.jsx("button",{type:"button",onClick:()=>i(`${u()}/v/${encodeURIComponent(x(s))}`),className:"focus-ring text-fg-muted hover:text-accent",children:"Make active"}),e.jsx("button",{type:"button",onClick:()=>{confirm(`Remove ${s.name} from this device? Your notes stay in the vault — only this device's stored access is removed. You can add it again anytime.`)&&m(s.id)},className:"focus-ring text-danger hover:text-danger-hover",children:"Remove from this device"})]})]}),l?e.jsxs("p",{className:"mt-3 rounded-xl border border-warning/30 bg-warning-soft px-3 py-2 text-xs text-warning",children:["Vault now serves under ",e.jsx("code",{className:"font-mono",children:"/vault/<name>/"}),". This stored URL is from the older scheme and won't reach the new endpoints. Remove this entry and"," ",e.jsx(n,{to:"/add",className:"underline",children:"add it again"})," ","— discovery will pick the right URL automatically."]}):null]},s.id)})})]})}export{N as Vaults};
@@ -1 +0,0 @@
1
- import{j as n,bS as lt,r as y,bT as O,bU as $,L as I,b7 as ot,A as ct,aB as dt,ao as se,ab as ae,v as F,bD as q,bV as _e,bW as Le,bX as ut,bY as Be,Z as mt,z as V,a1 as xt,$ as Ne,a4 as ee,bZ as Fe,b_ as pt,b$ as ht,c0 as ft,c1 as bt,c2 as gt,c3 as Ve,a as Re,a6 as yt,C as jt,c4 as vt,c5 as Nt,c6 as we,c7 as wt,b as kt,bR as R,c8 as te,aj as Ct,c9 as St,N as $t,E as Oe,ca as Tt,cb as Ie,cc as Et,cd as Q,y as C,ce as Dt,cf as Pt,cg as Mt,az as At,ch as _t,ci as Lt,a8 as ke,a9 as Ce,cj as Bt}from"./index-oE_2AheL.js";import{T as Ft}from"./TagSchemaEditor-_n7m_7Xz.js";const Vt="—",qe=/^https?:\/\//i;function ze(e){return typeof e=="string"&&qe.test(e)}const Se=24;function Rt(e){try{const t=new URL(e);let s=`${t.pathname}${t.search}${t.hash}`;return s==="/"&&(s=""),s.length>Se&&(s=`${s.slice(0,Se-1)}…`),{host:t.host,rest:s}}catch{return{host:e.replace(qe,""),rest:""}}}function Ot({value:e,schema:t}){if(e==null||e==="")return Vt;if(typeof e=="boolean")return e?n.jsx("span",{className:"text-grass",children:"✓"}):n.jsx("span",{className:"text-fg-dim",children:"✕"});if((t==null?void 0:t.type)==="date"&&typeof e=="string")return lt(e);if(ze(e)){const{host:s,rest:a}=Rt(e);return n.jsxs("span",{className:"min-w-0 truncate text-accent underline underline-offset-2",title:e,children:[s,a?n.jsx("span",{className:"opacity-70",children:a}):null]})}return typeof e=="number"?n.jsx("span",{className:"tabular-nums",children:String(e)}):String(e)}function z(e,t){if(t&&t.length>0||e!=null&&e.enum&&e.enum.length>0)return"enum";switch(e==null?void 0:e.type){case"date":return"date";case"boolean":return"boolean";case"number":return"number";default:return"string"}}const It="focus-ring inline-flex max-w-[9rem] items-center rounded px-1 py-0.5 text-[0.6875rem] hover:text-accent disabled:opacity-50";function qt(e){if(typeof e!="string")return"";const t=e.match(/^\d{4}-\d{2}-\d{2}/);return t?t[0]:""}function re({field:e,schema:t,value:s,onCommit:a,disabled:r=!1,options:i,includeClear:l=!1,trigger:o}){const u=z(t,i),[c,m]=y.useState(!1),p=s==null||s==="",d=(o==null?void 0:o.label)??n.jsx(Ot,{value:s,schema:t}),h=(o==null?void 0:o.ariaLabel)??`Edit ${e}`,j=(o==null?void 0:o.className)??`${It} ${p&&!(o!=null&&o.label)?"text-fg-dim":"text-fg"}`;if(u==="boolean"){const v=(o==null?void 0:o.ariaLabel)??`Edit ${e} (${s===!0?"checked":"unchecked"})`;return n.jsx("button",{type:"button",disabled:r,"aria-label":v,onClick:()=>a(s!==!0),className:j,children:d})}const g=u==="enum"?i??((t==null?void 0:t.enum)??[]).map(v=>({value:v,label:v})):[],f=l&&!p,b=v=>{m(!1),a(v)};return n.jsxs("div",{className:"relative",children:[n.jsx("button",{type:"button",disabled:r,"aria-haspopup":u==="enum"?"menu":"dialog","aria-expanded":c,"aria-label":h,title:o!=null&&o.label?void 0:`Edit ${e}`,onClick:()=>m(v=>!v),className:j,children:d}),c?n.jsxs(n.Fragment,{children:[n.jsx("button",{type:"button","aria-hidden":"true",tabIndex:-1,className:"fixed inset-0 z-10 cursor-default",onClick:()=>m(!1)}),u==="enum"?n.jsxs("div",{role:"menu","aria-label":h,className:"card absolute right-0 z-20 mt-1 flex min-w-[10rem] flex-col gap-0.5 p-1 shadow-lg",children:[g.map(v=>n.jsxs("button",{type:"button",role:"menuitem",onClick:()=>b(v.value),className:`focus-ring flex items-center gap-1.5 rounded px-2 py-1.5 text-left text-sm hover:bg-bg-soft ${v.muted?"text-fg-dim":"text-fg"}`,children:[v.value===null||v.value===void 0||v.value===""?null:n.jsx("span",{"aria-hidden":"true",className:`tint-dot tint-${O(String(v.value))}`}),v.label]},v.value===null?"__clear__":String(v.value))),f?n.jsx("button",{type:"button",role:"menuitem",onClick:()=>b(null),className:"focus-ring rounded px-2 py-1.5 text-left text-sm text-fg-dim hover:bg-bg-soft",children:"Clear"}):null]}):n.jsx(zt,{kind:u,value:s,ariaLabel:h,onCommit:b,onCancel:()=>m(!1)})]}):null]})}function zt({kind:e,value:t,ariaLabel:s,onCommit:a,onCancel:r}){const i=e==="date"?qt(t):t==null?"":String(t),[l,o]=y.useState(i),u=()=>{const c=l.trim();if(c==="")return a(null);if(e==="number"){const m=Number(c);return Number.isFinite(m)?a(m):r()}a(c)};return n.jsxs("div",{role:"dialog","aria-label":s,className:"card absolute right-0 z-20 mt-1 flex min-w-[10rem] items-center gap-1 p-1 shadow-lg",children:[n.jsx("input",{autoFocus:!0,type:e==="date"?"date":e==="number"?"number":"text",value:l,"aria-label":s,onChange:c=>o(c.target.value),onKeyDown:c=>{c.key==="Enter"?(c.preventDefault(),u()):c.key==="Escape"&&(c.preventDefault(),r())},className:"w-full rounded border border-border bg-bg/40 px-1.5 py-1 text-xs text-fg focus:border-accent focus:outline-none"}),n.jsx("button",{type:"button",onClick:u,"aria-label":"Save",className:"focus-ring rounded px-1.5 py-1 text-xs text-accent hover:bg-bg-soft",children:"✓"}),ze(t)?n.jsx("a",{href:t,target:"_blank",rel:"noopener noreferrer","aria-label":"Open link",title:"Open link",className:"focus-ring rounded px-1.5 py-1 text-xs text-accent hover:bg-bg-soft",children:"↗"}):null]})}function Gt(e){for(const t of e.attachments??[]){const s=typeof t.url=="string"?t.url:null;if(typeof t.mimeType=="string"&&t.mimeType.startsWith("image/")&&s&&/^https?:\/\//i.test(s))return s}return null}function G({note:e,pinnedTag:t,archivedTag:s,variant:a="compact",overlay:r,footer:i,drag:l}){const o=$(e),u=e.updatedAt??e.createdAt,c=(e.tags??[]).includes(t),m=(e.tags??[]).includes(s),p=a==="gallery"?Gt(e):null,[d,h]=y.useState(!1),j=p&&!d,g=(l==null?void 0:l.canDrag)??!1,f=n.jsxs(I,{to:`/n/${encodeURIComponent(e.id)}`,draggable:g?!1:void 0,"data-note-id":e.id,className:`focus-ring card group flex flex-col overflow-hidden rounded-xl shadow-sm transition hover:border-accent hover:shadow-md ${m?"opacity-60 italic":""}`,children:[a==="gallery"?n.jsx("div",{className:"aspect-[3/2] w-full overflow-hidden bg-bg-soft",children:j?n.jsx("img",{src:p,alt:"",loading:"lazy",onError:()=>h(!0),className:"h-full w-full object-cover"}):n.jsx("div",{"aria-hidden":"true",className:"flex h-full w-full items-end p-3 text-fg-dim",children:n.jsx("span",{className:"line-clamp-3 text-sm text-fg-muted",children:e.preview??""})})}):null,n.jsxs("div",{className:"flex flex-1 flex-col gap-1 p-3",children:[n.jsxs("div",{className:"flex items-baseline justify-between gap-2",children:[n.jsxs("span",{className:"flex min-w-0 items-baseline gap-1.5",children:[c?n.jsx("span",{className:"shrink-0 text-accent","aria-label":"pinned",title:"pinned",children:"★"}):null,n.jsx("span",{className:o.kind==="timestamp"?"min-w-0 truncate text-sm title-timestamp":"min-w-0 truncate text-sm font-medium text-fg",children:o.text})]}),n.jsx(ot,{note:e})]}),e.preview&&!(a==="gallery"&&!j)?n.jsx("p",{className:"line-clamp-2 text-xs text-fg-muted",children:e.preview}):null,n.jsx("span",{className:"mt-auto pt-1 text-[0.6875rem] tabular-nums text-fg-dim",children:ct(u)})]})]});return!r&&!i&&!g?f:n.jsxs("div",{className:g?"relative flex flex-col cursor-grab":"relative flex flex-col",...(l==null?void 0:l.sourceProps)??{},children:[f,r?n.jsx("div",{className:"absolute right-2 top-2",children:r}):null,i?n.jsx("div",{className:"mt-1",children:i}):null]})}function Ut(e,t,s){const a={...e.metadata??{}};return s===null?delete a[t]:a[t]=s,{...e,metadata:a}}function Yt(e,t,s,a){return e&&e.map(r=>r.id===t?Ut(r,s,a):r)}function Wt(e,t){const s=dt(),a=se(e);return{move:y.useCallback(async(i,l,o)=>{const u=s.getQueryData(t);s.setQueryData(t,c=>Yt(c,e,i,l));try{const c=await a.mutateAsync({metadata:{[i]:l},...o?{if_updated_at:o}:{force:!0}}),m=c==null?void 0:c.updatedAt;m&&s.setQueryData(t,p=>p==null?void 0:p.map(d=>d.id===e?{...d,updatedAt:m}:d))}catch(c){throw s.setQueryData(t,u),c}},[s,t,e,a]),isPending:a.isPending}}const Ht=1800,J="field-write-flash",Qt=700;function Jt(e){return e===null?null:typeof e=="boolean"?e?"Yes":"No":String(e)}function Xt(e){if(typeof document>"u")return;const t=typeof CSS<"u"&&typeof CSS.escape=="function"?CSS.escape(e):e.replace(/["\\]/g,"\\$&");for(const s of document.querySelectorAll(`[data-note-id="${t}"]`))s.classList.remove(J),s.offsetWidth,s.classList.add(J),window.setTimeout(()=>s.classList.remove(J),Qt)}function U(e,t){const s=ae(c=>c.push),{move:a,isPending:r}=Wt(e.id,t),i=e.id,l=e.updatedAt,o=$(e).text;return{write:y.useCallback(async(c,m,p)=>{try{await a(c,m,l)}catch(h){const j=(p==null?void 0:p.errorPrefix)??`Couldn't update ${c} on "${o}"`;s(`${j}: ${h instanceof Error?h.message:"unknown error"}`,"error");return}const d=(p==null?void 0:p.valueLabel)??Jt(m);s(d===null?`✓ ${c} cleared`:`✓ ${c} → ${d}`,"success",{durationMs:Ht}),Xt(i)},[a,l,o,i,s]),isPending:r}}function Ge(e){if(e==null)return null;const t=typeof e;return t==="string"||t==="number"||t==="boolean"?e:null}function P({note:e,fields:t,viewResultsKey:s,omit:a}){const{write:r,isPending:i}=U(e,s),l=a&&a.length>0?t.filter(o=>!a.includes(o.name)):t;return l.length===0?null:n.jsx("div",{className:"flex flex-wrap items-center gap-1.5 px-3 pb-2.5 pt-0.5",children:l.map(o=>{var m;const u=Ge((m=e.metadata)==null?void 0:m[o.name]),c=z(o.schema)==="enum"&&u!==null&&u!==""?O(String(u)):null;return n.jsxs("span",{className:`inline-flex items-center gap-1 rounded-full border py-0.5 pl-2 pr-1 text-[0.6875rem] leading-none ${c?`chip-tinted tint-${c}`:"border-border bg-bg-soft/60"}`,children:[c?n.jsx("span",{"aria-hidden":"true",className:"tint-dot"}):null,n.jsx("span",{className:"text-fg-dim",children:o.name}),n.jsx(re,{field:o.name,schema:o.schema,value:u,disabled:i,includeClear:!0,onCommit:p=>void r(o.name,p)})]},o.name)})})}function Zt(e,t){var a;const s=(a=e.metadata)==null?void 0:a[t];if(s==null)return null;if(typeof s=="string"){const r=s.trim();return r===""?null:r}return typeof s=="number"||typeof s=="boolean"?String(s):null}const Kt={status:["active","incubating","dormant","paused","archived","done","shipped","dropped"],priority:["high","medium","low"]};function en(e,t){var a;const s=(a=t==null?void 0:t[e])==null?void 0:a.enum;return s&&s.length>0?s:Kt[e]??[]}function tn(e,t,s=[]){var m;const a=new Map,r=new Map,i=[];for(const p of e){const d=Zt(p,t);if(d===null){i.push(p);continue}const h=a.get(d);h?h.push(p):(a.set(d,[p]),r.set(d,(m=p.metadata)==null?void 0:m[t]))}const l=s.filter(p=>a.has(p)),o=new Set(l),u=[...a.keys()].filter(p=>!o.has(p)).sort((p,d)=>p.localeCompare(d)),c=[...l,...u].map(p=>({key:p,label:p,notes:a.get(p)??[],uncategorized:!1,value:r.get(p)}));return i.length>0&&c.push({key:"",label:`No ${t}`,notes:i,uncategorized:!0,value:null}),c}function nn(e){if(typeof e!="string")return null;const t=e.trim();if(!t)return null;const s=t.match(/^(\d{4})-(\d{2})-(\d{2})/);if(s){const r=new Date(Number(s[1]),Number(s[2])-1,Number(s[3]));return Number.isNaN(r.getTime())?null:r}const a=new Date(t);return Number.isNaN(a.getTime())?null:a}function sn(e,t){var i;const s=new Map,a=[],r=new Map;for(const l of e){const o=nn((i=l.metadata)==null?void 0:i[t]);if(!o){a.push(l);continue}r.set(l.id,o);const u=F(o),c=s.get(u);c?c.push(l):s.set(u,[l])}return{byDay:s,undated:a,dates:r}}function an(e){const t=new Map,s=[],a=new Map;for(const r of e){const i=r.createdAt?new Date(r.createdAt):null;if(!i||Number.isNaN(i.getTime())){s.push(r);continue}a.set(r.id,i);const l=F(i),o=t.get(l);o?o.push(r):t.set(l,[r])}return{byDay:t,undated:s,dates:a}}function $e(e,t=new Date){let s=null;for(const r of e)(!s||r.getTime()>s.getTime())&&(s=r);const a=s??t;return{year:a.getFullYear(),month:a.getMonth()+1}}function rn({notes:e,laneBy:t,subjectTag:s,roles:a,viewResultsKey:r,fields:i=[]}){const l=q(s??null),o=y.useMemo(()=>{var g,f,b,v;const c=tn(e,t,en(t,(g=l.data)==null?void 0:g.fields)),m=((v=(b=(f=l.data)==null?void 0:f.fields)==null?void 0:b[t])==null?void 0:v.enum)??[];if(m.length===0)return c;const p=new Map(c.filter(x=>!x.uncategorized).map(x=>[x.key,x])),d=m.map(x=>p.get(x)??{key:x,label:x,notes:[],uncategorized:!1,value:x}),h=new Set(m),j=c.filter(x=>x.uncategorized||!h.has(x.key));return[...d,...j]},[e,t,l.data]),u=_e();return n.jsx("div",{className:"overflow-x-auto pb-2",children:n.jsx("div",{className:"flex items-start gap-4",children:o.map(c=>n.jsx(ln,{lane:c,dropRegistry:u,children:c.notes.map(m=>n.jsx(cn,{note:m,laneBy:t,lanes:o,currentLane:c,roles:a,viewResultsKey:r,fields:i,dropRegistry:u},m.id))},c.uncategorized?"__uncategorized__":c.key))})})}function ln({lane:e,dropRegistry:t,children:s}){const a=y.useCallback(l=>t.dispatch(l,e),[t,e]),{isOver:r,targetProps:i}=Le(a);return n.jsxs("section",{"aria-label":e.label,className:`flex w-72 shrink-0 flex-col gap-2 rounded-2xl border border-border-light bg-bg-soft p-2 ${r?"outline-2 outline-offset-2 outline-accent/50":""}`,...i,children:[n.jsxs("header",{className:"flex items-baseline justify-between gap-2 px-1.5 pt-1",children:[n.jsxs("span",{className:"flex min-w-0 items-center gap-1.5",children:[e.uncategorized?null:n.jsx("span",{"aria-hidden":"true",className:`tint-dot tint-${O(e.key)}`}),n.jsx("span",{className:`min-w-0 truncate text-sm font-semibold ${e.uncategorized?"text-fg-dim":"text-fg"}`,children:e.label})]}),n.jsx("span",{className:"shrink-0 rounded-full bg-bg px-2 text-xs tabular-nums text-fg-dim",children:e.notes.length})]}),n.jsx("div",{className:"flex flex-col gap-2",children:e.notes.length===0?n.jsx("p",{className:"py-4 text-center text-xs italic text-fg-dim",children:ut()?"Drop here":"No notes"}):s})]})}function Te(e,t){return e.uncategorized||t.uncategorized?e.uncategorized&&t.uncategorized:e.key===t.key}const on="focus-ring rounded-full border border-border bg-bg-soft/90 px-2 py-0.5 text-[0.6875rem] font-medium text-fg-dim backdrop-blur transition-colors hover:text-accent disabled:opacity-50";function cn({note:e,laneBy:t,lanes:s,currentLane:a,roles:r,viewResultsKey:i,fields:l,dropRegistry:o}){const{write:u,isPending:c}=U(e,i),m=y.useMemo(()=>s.filter(f=>!Te(f,a)),[s,a]),p=y.useMemo(()=>m.map(f=>({value:f.value,label:f.label,muted:f.uncategorized})),[m]),d=y.useCallback(async(f,b)=>{await u(t,f,{valueLabel:b,errorPrefix:`Couldn't move "${$(e).text}"`})},[u,t,e]),h=async f=>{const b=p.find(v=>v.value===f);await d(f,b==null?void 0:b.label)},j=Be(e.id),g=y.useCallback(f=>{c||Te(f,a)||d(f.value,f.label)},[c,a,d]);return y.useEffect(()=>o.register(e.id,g),[o,e.id,g]),n.jsx(G,{note:e,pinnedTag:r.pinned,archivedTag:r.archived,drag:j,overlay:m.length>0?n.jsx(re,{field:t,value:a.value,options:p,disabled:c,onCommit:f=>void h(f),trigger:{label:"Move",ariaLabel:`Move to another ${t}`,className:on}}):null,footer:l.length>0?n.jsx(P,{note:e,fields:l,viewResultsKey:i,omit:m.length>0?[t]:void 0}):null})}const dn=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],X=2;function un({notes:e,dateField:t,roles:s,viewResultsKey:a,fields:r=[]}){const i=y.useMemo(()=>t===null?an(e):sn(e,t),[e,t]),[l,o]=y.useState(()=>$e(i.dates.values())),[u,c]=y.useState(null),m=y.useMemo(()=>mt(l.year,l.month),[l]),p=F(),d=_e();if(i.byDay.size===0)return n.jsxs("div",{className:"space-y-4",children:[n.jsx(V,{title:"Nothing on the calendar yet",description:t===null?void 0:`Give a note a ${t} date below and it lands on the grid.`}),t===null?null:n.jsx(Ee,{notes:i.undated,dateField:t,roles:s,viewResultsKey:a,fields:r})]});const h=g=>{c(null),o(g)},j=u?i.byDay.get(u)??[]:[];return n.jsxs("div",{className:"space-y-3",children:[n.jsxs("header",{className:"flex flex-wrap items-baseline justify-between gap-3",children:[n.jsx("h2",{className:"font-serif text-2xl tracking-tight text-fg",children:xt(l.year,l.month)}),n.jsxs("div",{className:"flex items-center gap-2 text-sm",children:[n.jsx("button",{type:"button",onClick:()=>h(Ne(l.year,l.month,-1)),className:"chip","aria-label":"Previous month",children:"← Prev"}),n.jsx("button",{type:"button",onClick:()=>h($e(i.dates.values())),className:"chip",children:"Latest"}),n.jsx("button",{type:"button",onClick:()=>h(Ne(l.year,l.month,1)),className:"chip","aria-label":"Next month",children:"Next →"})]})]}),n.jsxs("div",{className:"overflow-hidden rounded-md border border-border bg-card",children:[n.jsx("div",{className:"grid grid-cols-7 border-b border-border bg-bg-soft text-2xs uppercase tracking-wider text-fg-dim",children:dn.map(g=>n.jsx("div",{className:"px-2 py-2 text-center",children:g},g))}),n.jsx("div",{className:"grid grid-cols-7",children:m.map(g=>{const f=F(g),b=g.getMonth()+1===l.month,v=i.byDay.get(f)??[],x=f===p,w=f===u;return n.jsx(mn,{dayKey:f,dayNumber:g.getDate(),inMonth:b,isToday:x,isSelected:w,notes:v,onSelect:()=>c(f),dateField:t,viewResultsKey:a,dropRegistry:d},f)})})]}),u&&j.length>0?n.jsxs("section",{"aria-label":`Notes on ${ee(u)}`,className:"space-y-2",children:[n.jsxs("div",{className:"flex items-baseline justify-between gap-2",children:[n.jsx("p",{className:"eyebrow",children:ee(u)}),n.jsx("button",{type:"button",onClick:()=>c(null),className:"text-xs text-fg-dim hover:text-accent focus-ring rounded",children:"Clear"})]}),n.jsx("div",{className:"grid grid-cols-[repeat(auto-fill,minmax(min(100%,16rem),1fr))] gap-2",children:j.map(g=>n.jsx(G,{note:g,pinnedTag:s.pinned,archivedTag:s.archived,footer:r.length>0?n.jsx(P,{note:g,fields:r,viewResultsKey:a}):null},g.id))})]}):null,t===null?n.jsx("p",{className:"text-xs text-fg-dim",children:"Showing by created date — set a date field to schedule."}):n.jsx(Ee,{notes:i.undated,dateField:t,roles:s,viewResultsKey:a,fields:r})]})}function mn({dayKey:e,dayNumber:t,inMonth:s,isToday:a,isSelected:r,notes:i,onSelect:l,dateField:o,viewResultsKey:u,dropRegistry:c}){const m=i.length>0,p=o!==null,d=y.useCallback(x=>c.dispatch(x,e),[c,e]),{isOver:h,targetProps:j}=Le(d),g=p&&s?j:{},f=n.jsx("span",{className:`mb-1 inline-flex h-6 w-6 items-center justify-center rounded-full font-serif tabular-nums ${a?"bg-accent text-(--color-on-accent)":"text-fg"}`,children:t}),b=n.jsxs("span",{className:"flex flex-col gap-0.5",children:[i.slice(0,X).map(x=>o===null?n.jsx(xn,{note:x},x.id):n.jsx(pn,{note:x,dayKey:e,dateField:o,viewResultsKey:u,dropRegistry:c},x.id)),i.length>X?n.jsxs("span",{className:"text-[10px] text-fg-dim",children:["+",i.length-X," more"]}):null]}),v=`flex min-h-24 flex-col border-b border-r border-border p-1.5 text-left text-xs ${s?"":"opacity-40"} ${r?"bg-accent/5":""} ${p&&s&&h?"bg-accent/5 outline-2 -outline-offset-2 outline-accent/60":""}`;return m?n.jsxs("button",{type:"button",onClick:l,"aria-label":`${ee(e)} — ${i.length} notes`,className:`${v} hover:bg-bg/60 focus:bg-bg/60 focus:outline-none`,"data-day":e,...g,children:[f,b]}):n.jsxs("div",{className:v,"data-day":e,...g,children:[f,n.jsx("span",{className:"sr-only",children:"no notes"})]})}const ne="truncate rounded-md border border-border bg-card px-1.5 py-0.5 text-[10px] leading-tight text-fg shadow-sm";function xn({note:e}){return n.jsx("span",{"data-note-id":e.id,className:ne,children:$(e).text})}function pn({note:e,dayKey:t,dateField:s,viewResultsKey:a,dropRegistry:r}){const{write:i,isPending:l}=U(e,a),o=Be(e.id),u=y.useCallback(c=>{l||c===t||i(s,c,{errorPrefix:`Couldn't move "${$(e).text}"`})},[l,t,s,i,e]);return y.useEffect(()=>r.register(e.id,u),[r,e.id,u]),n.jsx("span",{"data-note-id":e.id,className:o.canDrag?`${ne} cursor-grab`:ne,...o.sourceProps,children:$(e).text})}function Ee({notes:e,dateField:t,roles:s,viewResultsKey:a,fields:r}){if(e.length===0)return null;const i=r.find(o=>o.name===t)??{name:t,schema:{type:"date"}},l=/date/i.test(t)?t:`${t} date`;return n.jsxs("section",{"aria-label":`Not on the calendar — no ${l}`,className:"space-y-2",children:[n.jsx("p",{className:"eyebrow",children:"Not on the calendar yet"}),n.jsxs("p",{className:"text-xs text-fg-dim",children:[e.length," ",e.length===1?"note has":"notes have"," no ",l," — set one to place ",e.length===1?"it":"them","."]}),n.jsx("div",{className:"grid grid-cols-[repeat(auto-fill,minmax(min(100%,16rem),1fr))] gap-2",children:e.map(o=>n.jsx(G,{note:o,pinnedTag:s.pinned,archivedTag:s.archived,footer:n.jsx(P,{note:o,fields:[i],viewResultsKey:a})},o.id))})]})}const hn="border-[color-mix(in_srgb,var(--color-accent)_40%,var(--color-border))]";function Ue({label:e,value:t,icon:s,ariaLabel:a,haspopup:r="menu",open:i,dirty:l=!1,onClick:o}){return n.jsxs("button",{type:"button","aria-haspopup":r,"aria-expanded":i,"aria-label":a,onClick:o,className:`focus-ring inline-flex min-h-8 items-center gap-1.5 rounded-full border bg-card px-3 py-1 transition-colors duration-(--dur-quick) ease-out hover:border-accent/50 ${l?hn:"border-border"}`,children:[s?n.jsx("span",{"aria-hidden":"true",className:"flex-none text-fg-muted",children:s}):null,e?n.jsx("span",{className:"text-2xs uppercase tracking-[0.08em] text-fg-dim",children:e}):null,n.jsx("span",{className:"text-xs font-medium text-fg",children:t}),n.jsx("span",{"aria-hidden":"true",className:"text-2xs text-fg-dim",children:"▾"})]})}function ie({label:e,value:t,icon:s,ariaLabel:a,menuLabel:r,options:i,sections:l,current:o,onSelect:u,note:c,actions:m,busy:p=!1,dirty:d=!1}){const[h,j]=y.useState(!1);y.useEffect(()=>{if(!h)return;const x=w=>{w.key==="Escape"&&j(!1)};return document.addEventListener("keydown",x),()=>document.removeEventListener("keydown",x)},[h]);const g=x=>{j(!1),u(x)},f=x=>{j(!1),x.onSelect()},b=x=>{const w=x.value===o;return n.jsxs("button",{type:"button",role:"menuitemradio","aria-checked":w,onClick:()=>g(x.value),className:`focus-ring flex w-full items-center gap-2 rounded-lg px-2 py-1.5 text-left text-sm hover:bg-bg-soft ${w?"text-fg":"text-fg-muted"}`,children:[x.glyph?n.jsx("span",{"aria-hidden":"true",className:"flex-none",children:x.glyph}):null,n.jsxs("span",{className:"flex min-w-0 flex-1 items-center gap-2",children:[n.jsx("span",{className:x.hint?"shrink-0":"min-w-0 shrink truncate",children:x.label??x.value}),x.hint?n.jsx("span",{"aria-hidden":"true",className:"min-w-0 shrink truncate text-2xs text-fg-dim",children:x.hint}):null]}),w?n.jsx("span",{"aria-hidden":"true",className:"text-accent",children:"✓"}):null]},x.value)},v=l?l.reduce((x,w)=>x+w.options.length,0):(i==null?void 0:i.length)??0;return n.jsxs("div",{className:"relative",children:[n.jsx(Ue,{label:e,value:t,icon:s,ariaLabel:a,open:h,dirty:d,onClick:()=>j(x=>!x)}),h?n.jsxs(n.Fragment,{children:[n.jsx("button",{type:"button","aria-hidden":"true",tabIndex:-1,onClick:()=>j(!1),className:"enter-fade fixed inset-0 z-30 cursor-default bg-black/40 sm:bg-transparent"}),n.jsxs("div",{role:"menu","aria-label":r,className:"card enter-rise fixed inset-x-0 bottom-0 z-40 max-h-[70dvh] overflow-y-auto rounded-b-none p-1.5 pb-[calc(0.375rem+env(safe-area-inset-bottom))] shadow-lift sm:absolute sm:top-full sm:right-auto sm:bottom-auto sm:mt-1 sm:max-h-80 sm:w-56 sm:rounded-b-[var(--radius-2xl)] sm:pb-1.5",children:[n.jsx("p",{"aria-hidden":"true",className:"eyebrow px-2 pt-1.5 pb-1",children:r}),l?l.map((x,w)=>n.jsxs("div",{className:w>0?"mt-1 border-t border-border-light pt-1":void 0,children:[x.heading?n.jsx("p",{"aria-hidden":"true",className:"px-2 pt-1 pb-0.5 text-2xs uppercase tracking-[0.08em] text-fg-dim",children:x.heading}):null,x.options.map(b)]},x.heading??w)):i==null?void 0:i.map(b),c?n.jsx("p",{className:"px-2 pt-1.5 pb-1 text-xs text-fg-dim",children:c}):null,m&&m.length>0?n.jsx("div",{className:v>0?"mt-1 border-t border-border-light pt-1":void 0,children:m.map(x=>n.jsxs("button",{type:"button",role:"menuitem",disabled:p,onClick:()=>f(x),className:"focus-ring flex w-full items-center gap-2 rounded-lg px-2 py-1.5 text-left text-sm text-fg-muted hover:bg-bg-soft disabled:opacity-50",children:[x.glyph?n.jsx("span",{"aria-hidden":"true",className:"flex-none",children:x.glyph}):null,n.jsxs("span",{className:"min-w-0 flex-1",children:[n.jsx("span",{className:"block truncate text-fg",children:x.label}),x.hint?n.jsx("span",{className:"block truncate text-2xs text-fg-dim",children:x.hint}):null]})]},x.key))}):null]})]}):null]})}function De(e){switch(z(e)){case"enum":case"boolean":return"●";case"date":return"📅";case"number":return"#";default:return"Aa"}}function fn({fields:e,schemaFields:t,onChange:s,dirty:a=!1}){const[r,i]=y.useState(!1);y.useEffect(()=>{if(!r)return;const d=h=>{h.key==="Escape"&&i(!1)};return document.addEventListener("keydown",d),()=>document.removeEventListener("keydown",d)},[r]);const l=e.map(d=>d.name),o=Object.keys(t).filter(d=>!l.includes(d));if(l.length===0&&o.length===0)return null;const u=l.length===1,c=d=>{u||s(l.filter(h=>h!==d))},m=d=>s([...l,d]),p=(d,h)=>{const j=[...l],[g]=j.splice(d,1);j.splice(d+h,0,g),s(j)};return n.jsxs("div",{className:"relative",children:[n.jsx(Ue,{label:"Fields",value:String(l.length),haspopup:"dialog",open:r,dirty:a,onClick:()=>i(d=>!d)}),r?n.jsxs(n.Fragment,{children:[n.jsx("button",{type:"button","aria-hidden":"true",tabIndex:-1,onClick:()=>i(!1),className:"enter-fade fixed inset-0 z-30 cursor-default bg-black/40 sm:bg-transparent"}),n.jsxs("div",{role:"dialog","aria-label":"Fields",className:"card enter-rise fixed inset-x-0 bottom-0 z-40 max-h-[70dvh] overflow-y-auto rounded-b-none p-1.5 pb-[calc(0.375rem+env(safe-area-inset-bottom))] shadow-lift sm:absolute sm:top-full sm:right-auto sm:bottom-auto sm:mt-1 sm:max-h-80 sm:w-60 sm:rounded-b-[var(--radius-2xl)] sm:pb-1.5",children:[n.jsx("p",{className:"eyebrow px-2 pt-1.5 pb-1",children:"Fields"}),n.jsxs("ul",{className:"flex flex-col gap-0.5",children:[e.map((d,h)=>n.jsxs("li",{className:"flex items-center gap-1 rounded-lg px-2 py-1 hover:bg-bg-soft",children:[n.jsxs("label",{className:"flex min-w-0 flex-1 cursor-pointer items-center gap-2 text-sm text-fg",children:[n.jsx("input",{type:"checkbox",checked:!0,disabled:u,onChange:()=>c(d.name)}),n.jsx("span",{"aria-hidden":"true",className:"w-4 flex-none text-center text-2xs text-fg-dim",children:De(d.schema)}),n.jsx("span",{className:"truncate",children:d.name})]}),n.jsx("button",{type:"button","aria-label":`Move ${d.name} up`,disabled:h===0,onClick:()=>p(h,-1),className:"focus-ring rounded px-1.5 py-0.5 text-sm text-fg-muted hover:bg-bg-soft hover:text-fg disabled:opacity-30",children:"↑"}),n.jsx("button",{type:"button","aria-label":`Move ${d.name} down`,disabled:h===l.length-1,onClick:()=>p(h,1),className:"focus-ring rounded px-1.5 py-0.5 text-sm text-fg-muted hover:bg-bg-soft hover:text-fg disabled:opacity-30",children:"↓"})]},d.name)),o.map(d=>n.jsx("li",{className:"flex items-center gap-1 rounded-lg px-2 py-1 hover:bg-bg-soft",children:n.jsxs("label",{className:"flex min-w-0 flex-1 cursor-pointer items-center gap-2 text-sm text-fg-muted",children:[n.jsx("input",{type:"checkbox",checked:!1,onChange:()=>m(d)}),n.jsx("span",{"aria-hidden":"true",className:"w-4 flex-none text-center text-2xs text-fg-dim",children:De(t[d])}),n.jsx("span",{className:"truncate",children:d})]})},d))]}),u?n.jsx("p",{className:"px-2 pt-1.5 pb-1 text-xs text-fg-dim",children:"Views show at least one field."}):null]})]}):null]})}function bn({notes:e,roles:t,viewResultsKey:s,fields:a=[]}){return n.jsx("div",{"aria-label":"Gallery",className:"grid grid-cols-[repeat(auto-fill,minmax(min(100%,13rem),1fr))] gap-4",children:e.map(r=>n.jsx(G,{note:r,variant:"gallery",pinnedTag:t.pinned,archivedTag:t.archived,footer:a.length>0?n.jsx(P,{note:r,fields:a,viewResultsKey:s}):null},r.id))})}const Z={list:"List",board:"Board",calendar:"Calendar",gallery:"Gallery",table:"Table"};function Pe({kind:e}){switch(e){case"board":return n.jsx(gt,{width:14,height:14});case"calendar":return n.jsx(bt,{width:14,height:14});case"gallery":return n.jsx(ft,{width:14,height:14});case"table":return n.jsx(ht,{width:14,height:14});default:return n.jsx(pt,{width:14,height:14})}}function gn({kind:e,onSwitch:t,dirty:s=!1}){return n.jsx(ie,{ariaLabel:`Lens: ${Z[e]}`,menuLabel:"Lens",icon:n.jsx(Pe,{kind:e}),value:Z[e],options:Fe.map(a=>({value:a,label:Z[a],glyph:n.jsx(Pe,{kind:a})})),current:e,onSelect:t,dirty:s})}function yn(e,t,s){const a=e.filter(s).map(r=>r.name);return t&&!a.includes(t)&&a.unshift(t),a}const jn="This view isn't scoped to one tag, so there's no schema to add a field to — add a single tag to the query, or open a tag's view.";function Ye(e,t,s){return[{key:"__add_field__",label:e,hint:t,onSelect:s}]}const Me="Date fields plot on the Calendar lens (By date) — not offered here.";function K(e,t){return{value:e,hint:t,glyph:n.jsx("span",{className:`tint-dot tint-${O(e)}`})}}function vn(e){const t=[],s=[],a=[];for(const r of e){const i=z(r.schema);i==="date"?a.push(r):i==="enum"?t.push(r):s.push(r)}return{valueBearing:t,other:s,dateFields:a}}function Nn(e){return(e.enum??[]).join(" · ")}function wn(e,t,s,a,r){if(e)return t>0?Me:void 0;if(!s)return jn;if(r)return`#${s} has no fields yet — add one to give this board its columns:`;if(!a)return Me}function kn({value:e,fields:t,onChange:s,dirty:a=!1,createTag:r=null,schemaReady:i=!0,onAddField:l}){const{valueBearing:o,other:u,dateFields:c}=vn(t),m=new Set([...o,...u].map(f=>f.name)),p=e!==void 0&&!m.has(e)?e:void 0,d=[];p!==void 0&&d.push({options:[K(p)]}),o.length>0&&d.push({heading:"Fields with values",options:o.map(f=>K(f.name,Nn(f.schema)))}),u.length>0&&d.push({heading:"Other fields · one column per value",options:u.map(f=>K(f.name))});const h=d.length>0,j=t.length===0,g=j&&!!r&&i&&!!l;return n.jsx(ie,{label:"Group by",menuLabel:"Group by",value:e??"—",sections:d,current:e,onSelect:s,note:wn(h,c.length,r,j,g),actions:g?Ye("Add a field to group by…","You name it; give it values to get columns.",l):void 0,dirty:a})}function Cn({value:e,fields:t,onChange:s,dirty:a=!1,createTag:r=null,schemaReady:i=!0,onAddField:l}){const o=yn(t,e,c=>c.schema.type==="date"),u=o.length===0&&!!r&&i&&!!l;return n.jsx(ie,{label:"By date",menuLabel:"By date",value:e??"created",options:o.map(c=>({value:c})),current:e,onSelect:s,note:o.length===0&&u?`Showing by created date. #${r} has no date field — add one to plot and drag by it:`:e===void 0?"Showing by created date":void 0,actions:u?Ye("Add a date field…","You name it; it holds a date on each note.",l):void 0,dirty:a})}function Sn({notes:e,roles:t,viewResultsKey:s,fields:a=[]}){return n.jsx("div",{className:"overflow-hidden rounded-xl border border-border bg-card shadow-sm",children:n.jsx("div",{className:"overflow-x-auto",children:n.jsxs("table",{className:"w-full min-w-[36rem] border-collapse text-sm",children:[n.jsx("thead",{children:n.jsxs("tr",{className:"border-b border-border text-left",children:[n.jsx("th",{scope:"col",className:"sticky left-0 z-[1] bg-bg-soft px-3 py-2 text-2xs font-semibold uppercase tracking-[0.08em] text-fg-dim",children:"Note"}),a.map(r=>n.jsx("th",{scope:"col",className:`whitespace-nowrap bg-bg-soft px-3 py-2 text-2xs font-semibold uppercase tracking-[0.08em] text-fg-dim ${r.schema.type==="number"?"text-right":""}`,children:r.name},r.name))]})}),n.jsx("tbody",{children:e.map(r=>n.jsx($n,{note:r,fields:a,roles:t,viewResultsKey:s},r.id))})]})})})}function $n({note:e,fields:t,roles:s,viewResultsKey:a}){const{write:r,isPending:i}=U(e,a),l=$(e),o=(e.tags??[]).includes(s.pinned),u=(e.tags??[]).includes(s.archived);return n.jsxs("tr",{"data-note-id":e.id,className:`group border-b border-border-light last:border-b-0 hover:bg-bg-soft/60 ${u?"opacity-60 italic":""}`,children:[n.jsx("th",{scope:"row",className:"group-hover:after:opacity-100 sticky left-0 z-[1] bg-card px-3 py-1.5 text-left font-normal after:pointer-events-none after:absolute after:inset-0 after:-z-10 after:bg-bg-soft/60 after:opacity-0",children:n.jsxs(I,{to:`/n/${encodeURIComponent(e.id)}`,className:"focus-ring inline-flex max-w-[16rem] items-baseline gap-1.5 hover:text-accent",children:[o?n.jsx("span",{className:"shrink-0 text-accent","aria-label":"pinned",title:"pinned",children:"★"}):null,n.jsx("span",{className:l.kind==="timestamp"?"min-w-0 truncate title-timestamp":"min-w-0 truncate font-medium text-fg",children:l.text})]})}),t.map(c=>{var m;return n.jsx("td",{className:`px-3 py-1 align-middle ${c.schema.type==="number"?"text-right":""}`,children:n.jsx(re,{field:c.name,schema:c.schema,value:Ge((m=e.metadata)==null?void 0:m[c.name]),disabled:i,includeClear:!0,onCommit:p=>void r(c.name,p)})},c.name)})]})}function We(e){return e.kind!==void 0||e.groupBy!==void 0||e.dateField!==void 0||e.fields!==void 0}function Tn(e){const t=new URLSearchParams;return e.kind&&t.set("kind",e.kind),e.groupBy&&t.set("group",e.groupBy),e.dateField&&t.set("date",e.dateField),e.fields&&e.fields.length>0&&t.set("fields",e.fields.join(",")),t}function En(e){const t={},s=e.get("kind");s&&Fe.includes(s)&&(t.kind=s);const a=e.get("group");a&&(t.groupBy=a);const r=e.get("date");r&&(t.dateField=r);const i=e.get("fields");if(i){const l=i.split(",").map(o=>o.trim()).filter(Boolean);l.length>0&&(t.fields=l)}return t}function le(e,t){return We(t)?{...e,kind:t.kind??e.kind,groupBy:t.groupBy??e.groupBy,dateField:t.dateField??e.dateField,fields:t.fields??e.fields}:e}function Dn(e,t){return e===void 0||t===void 0?e===t:e.length===t.length&&e.every((s,a)=>s===t[a])}function Ae(e,t){const s={};return t.kind!==void 0&&t.kind!==e.kind&&(s.kind=t.kind),t.groupBy!==void 0&&t.groupBy!==e.groupBy&&(s.groupBy=t.groupBy),t.dateField!==void 0&&t.dateField!==e.dateField&&(s.dateField=t.dateField),t.fields!==void 0&&!Dn(t.fields,e.fields)&&(s.fields=t.fields),s}function Pn(e){var t;return(t=e.find(s=>{var a;return(((a=s.schema.enum)==null?void 0:a.length)??0)>0}))==null?void 0:t.name}function Mn(e){var t;return(t=e.find(s=>s.schema.type==="date"))==null?void 0:t.name}function An(e,t,s,a){const r={...t,kind:s};if(s==="board"){if(!(t.groupBy??e.groupBy)){const i=Pn(a);i&&(r.groupBy=i)}}else e.groupBy===void 0&&(r.groupBy=void 0);if(s==="calendar"){if(!(t.dateField??e.dateField)){const i=Mn(a);i&&(r.dateField=i)}}else e.dateField===void 0&&(r.dateField=void 0);return r}function _n(e,t,s){const r={kind:le(e,t).kind};return s!==null&&(r.query=JSON.stringify(s)),t.groupBy!==void 0&&(r.group_by=t.groupBy),t.dateField!==void 0&&(r.date_field=t.dateField),t.fields!==void 0&&(r.fields=JSON.stringify(t.fields)),r}function Ln(e,t){const s={kind:e.kind};return t!==null&&(s.query=JSON.stringify(t)),e.groupBy!==void 0&&(s.group_by=e.groupBy),e.dateField!==void 0&&(s.date_field=e.dateField),e.fields!==void 0&&(s.fields=JSON.stringify(e.fields)),s}const Bn={type:"string"};function M(e){const t=Ve(e);return t.length===1?t[0]:null}function Fn(e,t){return e.fields&&e.fields.length>0?e.fields.map(a=>({name:a,schema:(t==null?void 0:t[a])??Bn})):M(e.query)&&t?Object.entries(t).map(([a,r])=>({name:a,schema:r})):[]}function Vn(e){const t=e?M(e.query):null,s=q(t);return y.useMemo(()=>e?Fn(e,He(s.data)):[],[e,s.data])}function He(e){return(e==null?void 0:e.fields)??null}function Rn(e){const t=e?M(e.query):null,s=q(t);return y.useMemo(()=>He(s.data)??{},[s.data])}function On(e){const t=e?M(e.query):null,s=q(t);return t?s.isSuccess:!0}function In(e,t,s=[]){if(s.includes(t))return{pinned:[],rest:e};const a=[],r=[];for(const i of e)(i.tags??[]).includes(t)?a.push(i):r.push(i);return{pinned:a,rest:r}}function Qe(){return n.jsx("nav",{className:"mb-6 text-sm text-fg-dim",children:n.jsx(I,{to:"/notes",className:"focus-ring hover:text-accent",children:"← All notes"})})}function ls(){const{id:e}=Ct(),t=Re(a=>a.getActiveVault()),s=St(e);return t?s.data?n.jsx(zn,{note:s.data}):n.jsxs("div",{className:"page",children:[n.jsx(Qe,{}),s.isPending?n.jsx(qn,{}):s.isError?n.jsx(Oe,{title:"Couldn't load this view",message:s.error instanceof Error?s.error.message:void 0,retry:()=>s.refetch()}):n.jsx(V,{title:"View not found",description:"It may have been deleted or moved."})]}):n.jsx($t,{to:"/",replace:!0})}function qn(){return n.jsxs("div",{className:"space-y-4","aria-busy":"true",children:[n.jsx(C,{height:32,width:"40%"}),n.jsx(C,{height:20,width:"60%"}),n.jsxs("div",{className:"space-y-2 pt-4",children:[n.jsx(C,{height:56}),n.jsx(C,{height:56}),n.jsx(C,{height:56})]})]})}function zn({note:e}){const t=y.useMemo(()=>te(e),[e]);return n.jsx(Gn,{def:t,backingNote:e,nav:n.jsx(Qe,{})})}function Gn({def:e,backingNote:t,pageSize:s,total:a,nav:r}){var ye;const i=Re(N=>N.getActiveVault()),{roles:l}=yt((i==null?void 0:i.id)??null),o=typeof s=="number"&&s>0,[u,c]=y.useState(0),[m,p]=jt(),d=y.useMemo(()=>vt(m),[m]),h=y.useMemo(()=>Ae(e,En(m)),[e,m]),j=(N,k)=>{const T=Tn(N);for(const[L,B]of Lt(k))T.append(L,B);p(T,{replace:!0})},g=N=>j(h,N),f=N=>{j(Ae(e,N),d)},b=y.useMemo(()=>le(e,h),[e,h]),v=y.useMemo(()=>JSON.stringify({q:b.query,r:d}),[b.query,d]);y.useEffect(()=>{c(0)},[v]);const x=y.useMemo(()=>!o||!b.query?b:{...b,query:{...b.query,offset:u,limit:s+1}},[o,b,u,s]),w=Nt(x,d,{live:!o}),S=y.useMemo(()=>o&&w.data?w.data.slice(0,s):w.data,[o,w.data,s]),oe=(S==null?void 0:S.length)??0,ce=o?(((ye=w.data)==null?void 0:ye.length)??0)>s:!1,Je=we(d),Xe=o&&!ce?u+oe:void 0,Ze=Je?void 0:a,E=Vn(b),Ke=Rn(b),de=[...b.problems,...w.problems],ue=y.useMemo(()=>S?In(S,l.pinned,Ve(b.query)):{pinned:[],rest:[]},[S,l.pinned,b.query]),et=t!==null,me=(We(h)||we(d))&&et,[tt,xe]=y.useState(!1),[pe,Y]=y.useState(!1),A=wt(l.view,pe),he=se(t==null?void 0:t.id),nt=kt(),fe=ae(N=>N.push),st=y.useMemo(()=>(A.data??[]).filter(N=>N.id!==(t==null?void 0:t.id)).flatMap(N=>{const k=R(te(N).title);return N.path&&N.path!==k?[N.path,k]:[k]}),[t==null?void 0:t.id,A.data]),at=async N=>{if(t)try{const k=await he.mutateAsync({path:R(N),...t.updatedAt?{if_updated_at:t.updatedAt}:{force:!0}});fe(`Renamed view to "${te(k).title}".`,"success"),Y(!1),k.id!==t.id&&nt(`/views/${encodeURIComponent(k.id)}`,{replace:!0})}catch(k){fe(`Could not rename view: ${k.message}`,"error")}},be=()=>p(new URLSearchParams,{replace:!0}),_=y.useMemo(()=>M(b.query),[b.query]),ge=On(b),[W,H]=y.useState(null),rt=N=>{var B,je;const k=W;if(!k)return;const T=Object.entries(N),L=k==="date"?(B=T.find(([,D])=>D.type==="date"))==null?void 0:B[0]:(je=T.find(([,D])=>{var ve;return(((ve=D.enum)==null?void 0:ve.length)??0)>0})??T.find(([,D])=>D.type!=="date"))==null?void 0:je[0];L&&f({...h,[k==="group"?"groupBy":"dateField"]:L})},it=b.kind==="board"||b.kind==="table";return n.jsxs("div",{className:it?"page page-wide":"page",children:[r,n.jsxs("article",{className:me?"pb-20":void 0,children:[n.jsx(Yn,{def:b,backingNote:t,count:Ze,onRename:t?()=>Y(!0):void 0}),n.jsxs("div",{className:"mb-1 flex flex-wrap items-center gap-x-2 gap-y-2 py-1",children:[n.jsx(gn,{kind:b.kind,onSwitch:N=>f(An(e,h,N,E)),dirty:e.kind!==b.kind}),b.kind==="board"?n.jsx(kn,{value:b.groupBy,fields:E,onChange:N=>f({...h,groupBy:N}),dirty:e.groupBy!==b.groupBy,createTag:_,schemaReady:ge,onAddField:()=>H("group")}):null,b.kind==="calendar"?n.jsx(Cn,{value:b.dateField,fields:E,onChange:N=>f({...h,dateField:N}),dirty:e.dateField!==b.dateField,createTag:_,schemaReady:ge,onAddField:()=>H("date")}):null,n.jsx(fn,{fields:E,schemaFields:Ke,onChange:N=>f({...h,fields:N}),dirty:e.fields!==b.fields})]}),n.jsx(Xn,{def:e,refinements:d,onChange:g}),de.length>0?n.jsx(Hn,{problems:de}):null,n.jsx("div",{className:"mt-6",children:n.jsx(Qn,{def:b,data:S,isPending:w.isPending,isError:w.isError,error:w.error,retry:w.refetch,viewResultsKey:w.queryKey,fields:E,pinned:ue.pinned,rest:ue.rest,roles:l})}),o?n.jsx(Wn,{offset:u,shown:oe,total:Xe,hasPrev:u>0,hasNext:ce,onPrev:()=>c(N=>Math.max(0,N-s)),onNext:()=>c(N=>N+s)}):null,me?n.jsx(Un,{onSave:()=>xe(!0),onRevert:be}):null,tt&&t?n.jsx(ss,{note:t,def:e,draft:h,refinements:d,roles:l,onClose:()=>xe(!1),onSaved:be}):null,pe&&t?n.jsx(ns,{currentName:e.title,currentPath:t.path,existingPaths:st,isChecking:A.isPending,checkFailed:A.isError,isRenaming:he.isPending,onCancel:()=>Y(!1),onRename:at}):null,W&&_?n.jsx(Ft,{tagName:_,intent:W,onSaved:rt,onClose:()=>H(null)}):null]})]})}function Un({onSave:e,onRevert:t}){const s=Dt(a=>a.setShown);return y.useEffect(()=>(s(!0),()=>s(!1)),[s]),n.jsx("div",{"aria-label":"View modified",className:"glass-panel fixed inset-x-0 bottom-[calc(3.5rem+env(safe-area-inset-bottom))] z-20 border-t border-border md:bottom-0 md:pb-[env(safe-area-inset-bottom)]",children:n.jsxs("div",{className:"mx-auto flex w-full max-w-(--w-page) items-center justify-between gap-3 px-5 py-2.5 md:px-10",children:[n.jsxs("div",{className:"flex min-w-0 items-center gap-2.5",children:[n.jsx("span",{"aria-hidden":"true",className:"view-modified-pulse h-2 w-2 shrink-0 rounded-full bg-accent"}),n.jsxs("p",{className:"min-w-0 text-sm text-fg-muted",children:[n.jsx("span",{className:"font-medium text-fg",children:"View modified"})," — you're exploring. Save to keep this layout."]})]}),n.jsxs("div",{className:"flex items-center gap-2",children:[n.jsx("button",{type:"button",onClick:t,className:"btn btn-secondary btn-touch",children:"Revert"}),n.jsx("button",{type:"button",onClick:e,className:"btn btn-primary btn-touch",children:"Save"})]})]})})}function Yn({def:e,backingNote:t,count:s,onRename:a}){return n.jsxs("header",{className:"mb-4 flex flex-wrap items-center justify-between gap-3 border-b border-border pb-5",children:[n.jsxs("div",{className:"flex min-w-0 items-center gap-2.5",children:[n.jsx(Tt,{kind:e.kind,hueTag:Ie(e.query)}),n.jsxs("div",{className:"min-w-0",children:[n.jsx("h1",{className:"page-title truncate",children:e.title}),typeof s=="number"?n.jsx("p",{className:"text-sm text-fg-dim",children:s===1?"1 note":`${s.toLocaleString()} notes`}):null]})]}),t?n.jsxs("div",{className:"flex items-center gap-2",children:[n.jsx("button",{type:"button",onClick:a,className:"btn btn-secondary btn-touch",children:"Rename"}),n.jsx(I,{to:`/n/${encodeURIComponent(t.id)}/edit`,className:"btn btn-secondary btn-touch",children:"Edit view note"})]}):null]})}function Wn({offset:e,shown:t,total:s,hasPrev:a,hasNext:r,onPrev:i,onNext:l}){const o=t>0?e+1:0,u=e+t;return!a&&!r?null:n.jsxs("div",{className:"mt-6 flex items-center justify-between text-fg-dim text-sm",children:[n.jsx("span",{children:t>0?typeof s=="number"?`Showing ${o}–${u} of ${s.toLocaleString()}`:`Showing ${o}–${u}`:""}),n.jsxs("div",{className:"flex gap-2",children:[n.jsx("button",{type:"button",disabled:!a,onClick:i,className:"btn btn-secondary btn-touch",children:"Previous"}),n.jsx("button",{type:"button",disabled:!r,onClick:l,className:"btn btn-secondary btn-touch",children:"Next"})]})]})}function Hn({problems:e}){return n.jsx("output",{"aria-live":"polite",className:"mt-4 block rounded-lg border border-(--color-warning) bg-(--color-warning-soft) p-3 text-sm text-fg",children:n.jsx("ul",{className:"list-disc space-y-1 pl-5",children:e.map((t,s)=>n.jsx("li",{children:t.message},`${t.code}-${s}`))})})}function Qn({def:e,data:t,isPending:s,isError:a,error:r,retry:i,viewResultsKey:l,fields:o,pinned:u,rest:c,roles:m}){if(e.query===null)return n.jsx(V,{title:"Nothing is being shown",description:"Fix the view's query to see results."});if(s)return n.jsxs("div",{className:"space-y-2","aria-busy":"true",children:[n.jsx(C,{height:56}),n.jsx(C,{height:56}),n.jsx(C,{height:56})]});if(a)return n.jsx(Oe,{title:"Couldn't run this view",message:r instanceof Error?r.message:void 0,retry:i});if(!t||u.length===0&&c.length===0)return n.jsx(V,{title:"No notes match this view yet."});const p=[...u,...c];switch(e.kind){case"board":if(e.groupBy)return n.jsx(rn,{notes:p,laneBy:e.groupBy,subjectTag:Ie(e.query),roles:m,viewResultsKey:l,fields:o});break;case"gallery":return n.jsx(bn,{notes:p,roles:m,viewResultsKey:l,fields:o});case"table":return n.jsx(Sn,{notes:p,roles:m,viewResultsKey:l,fields:o});case"calendar":return n.jsx(un,{notes:p,dateField:e.dateField||null,roles:m,viewResultsKey:l,fields:o})}return n.jsx(Jn,{pinned:u,rest:c,roles:m,viewResultsKey:l,fields:o})}function Jn({pinned:e,rest:t,roles:s,viewResultsKey:a,fields:r}){const i=l=>r.length>0?n.jsx(P,{note:l,fields:r,viewResultsKey:a}):null;return n.jsxs("div",{className:"space-y-6",children:[e.length>0?n.jsxs("section",{"aria-label":"Pinned",children:[n.jsx("p",{className:"eyebrow mb-2",children:"Pinned"}),n.jsx(ke,{"aria-label":"Pinned notes",children:e.map(l=>n.jsx(Ce,{note:l,pinnedTag:s.pinned,archivedTag:s.archived,footer:i(l)},l.id))})]}):null,t.length>0?n.jsx("section",{"aria-label":"Results",children:n.jsx(ke,{"aria-label":"View results",children:t.map(l=>n.jsx(Ce,{note:l,pinnedTag:s.pinned,archivedTag:s.archived,footer:i(l)},l.id))})}):null]})}function Xn({def:e,refinements:t,onChange:s}){const a=y.useMemo(()=>Et(e.query),[e.query]),r=i=>{const l=t.removeExcludes.includes(i);s({...t,removeExcludes:l?t.removeExcludes.filter(o=>o!==i):[...t.removeExcludes,i]})};return n.jsxs("div",{className:"flex flex-wrap items-center gap-2 py-2",children:[a.map(i=>n.jsx(Zn,{chip:i,toggled:i.kind==="exclude"&&!!i.value&&t.removeExcludes.includes(i.value),onToggle:i.kind==="exclude"&&i.value?()=>r(i.value):void 0},`${i.kind}-${i.value??i.label}`)),t.addTags.map(i=>n.jsx(Q,{label:`+#${i}`,onRemove:()=>s({...t,addTags:t.addTags.filter(l=>l!==i)})},`add-${i}`)),t.search?n.jsx(Q,{label:`"${t.search}"`,onRemove:()=>s({...t,search:void 0})}):null,t.sort?n.jsx(Q,{label:`sorted by ${t.sort==="desc"?"newest":"oldest"}`,onRemove:()=>s({...t,sort:void 0})}):null,n.jsx(Kn,{onAdd:i=>s({...t,addTags:[...t.addTags,i]})}),n.jsx(es,{value:t.search??"",onChange:i=>s({...t,search:i||void 0})}),n.jsx(ts,{value:t.sort,onChange:i=>s({...t,sort:i})})]})}function Zn({chip:e,toggled:t,onToggle:s}){return s?n.jsx("button",{type:"button",onClick:s,"aria-pressed":!t,title:t?"Excluded again — tap to peek":"Tap to peek at these too",className:`chip ${t?"opacity-50 line-through":""}`,children:e.label}):n.jsx("span",{className:"chip",children:e.label})}function Kn({onAdd:e}){const[t,s]=y.useState(""),a=()=>{const r=t.trim().replace(/^#/,"");r&&(e(r),s(""))};return n.jsx("input",{type:"text",value:t,onChange:r=>s(r.target.value),onKeyDown:r=>{r.key==="Enter"&&(r.preventDefault(),a())},placeholder:"+ tag","aria-label":"Add a tag filter",className:"w-24 rounded-full border border-border bg-bg/40 px-2.5 py-1 text-xs text-fg focus:border-accent focus:outline-none"})}function es({value:e,onChange:t}){return n.jsx("input",{type:"search",value:e,onChange:s=>t(s.target.value),placeholder:"Search…","aria-label":"Search within this view",className:"w-32 rounded-full border border-border bg-bg/40 px-2.5 py-1 text-xs text-fg focus:border-accent focus:outline-none"})}function ts({value:e,onChange:t}){return n.jsx("button",{type:"button",onClick:()=>t(e==="desc"?"asc":e==="asc"?void 0:"desc"),className:"chip","aria-label":"Cycle sort order",children:e==="desc"?"Newest first":e==="asc"?"Oldest first":"Sort"})}function ns({currentName:e,currentPath:t,existingPaths:s,isChecking:a,checkFailed:r,isRenaming:i,onCancel:l,onRename:o}){const[u,c]=y.useState(e),m=u.trim(),d=R(m)===t,h=_t(m,s,t),j=m.length>0&&!d&&!h&&!a&&!r&&!i;return n.jsx("div",{className:"dialog-overlay",role:"dialog","aria-modal":"true","aria-labelledby":"rename-view-title",onMouseDown:g=>{g.target===g.currentTarget&&!i&&l()},children:n.jsxs("div",{className:"dialog-panel max-w-(--w-narrow)",children:[n.jsx("h2",{id:"rename-view-title",className:"mb-3 font-serif text-xl text-fg",children:"Rename view"}),n.jsxs("label",{className:"block text-sm",children:[n.jsx("span",{className:"mb-1 block text-fg-muted",children:"Name"}),n.jsx("input",{type:"text",value:u,autoFocus:!0,onChange:g=>c(g.target.value),onKeyDown:g=>{g.key==="Enter"&&j&&o(m),g.key==="Escape"&&!i&&l()},"aria-label":"View name",className:"input input-on-bg"})]}),a?n.jsx("p",{className:"mt-2 text-xs text-fg-dim",children:"Checking existing views…"}):null,r?n.jsx("p",{className:"mt-2 text-xs text-danger",children:"Existing view names couldn't be checked. Close this dialog and try again."}):h?n.jsx("p",{className:"mt-2 text-xs text-danger",children:"A view with that name already exists."}):null,n.jsxs("div",{className:"mt-4 flex justify-end gap-2",children:[n.jsx("button",{type:"button",onClick:l,disabled:i,className:"btn btn-secondary btn-touch",children:"Cancel"}),n.jsx("button",{type:"button",onClick:()=>j&&void o(m),disabled:!j,className:"btn btn-primary btn-touch",children:i?"Renaming…":"Rename"})]})]})})}function ss({note:e,def:t,draft:s,refinements:a,roles:r,onClose:i,onSaved:l}){const o=ae(x=>x.push),u=Pt(),c=Mt(e,u),[m,p]=y.useState(c),[d,h]=y.useState(`${t.title} (copy)`),[j,g]=y.useState(!1),f=se(e.id),b=At(),v=async()=>{g(!0);try{const x=Bt(t.query,a);m==="update"?(await f.mutateAsync({metadata:_n(t,s,x),...e.updatedAt?{if_updated_at:e.updatedAt}:{force:!0}}),o(`Updated "${t.title}".`,"success")):(await b.mutateAsync({content:"",path:R(d),tags:[r.view],metadata:Ln(le(t,s),x)}),o(`Saved "${d}".`,"success")),l(),i()}catch(x){o(`Could not save: ${x.message}`,"error")}finally{g(!1)}};return n.jsx("div",{className:"dialog-overlay",role:"dialog","aria-labelledby":"save-view-title",onMouseDown:x=>{x.target===x.currentTarget&&i()},children:n.jsxs("div",{className:"dialog-panel max-w-md",children:[n.jsx("h2",{id:"save-view-title",className:"mb-3 font-serif text-xl text-fg",children:"Save this view"}),n.jsxs("div",{className:"mb-4 space-y-2",children:[n.jsxs("label",{className:"flex items-center gap-2 text-sm",children:[n.jsx("input",{type:"radio",name:"save-mode",checked:m==="update",onChange:()=>p("update")}),"Update this view"]}),n.jsxs("label",{className:"flex items-center gap-2 text-sm",children:[n.jsx("input",{type:"radio",name:"save-mode",checked:m==="fork",onChange:()=>p("fork")}),"Save as new view"]})]}),m==="fork"?n.jsxs("label",{className:"mb-4 block text-sm",children:[n.jsx("span",{className:"mb-1 block text-fg-muted",children:"Name"}),n.jsx("input",{type:"text",value:d,onChange:x=>h(x.target.value),className:"w-full rounded-lg border border-border bg-bg/40 px-2.5 py-1.5 text-sm text-fg focus:border-accent focus:outline-none"})]}):null,n.jsxs("div",{className:"flex justify-end gap-2",children:[n.jsx("button",{type:"button",onClick:i,className:"btn btn-secondary btn-touch",children:"Cancel"}),n.jsx("button",{type:"button",onClick:()=>void v(),disabled:j||m==="fork"&&!d.trim(),className:"btn btn-primary btn-touch",children:j?"Saving…":"Save"})]})]})})}export{Gn as ViewCanvas,ls as ViewSurface};
@@ -1 +0,0 @@
1
- import{b as w,C as N,r as i,g as y,l as v,bL as S,o as j,k,j as e,N as b,R as h,L as C}from"./index-oE_2AheL.js";import{W as p}from"./WizardShell-DU1MCyj6.js";import{f as z}from"./provenance-CPDeMpx4.js";import"./history-DdcRLE7l.js";function A(){const r=w(),[a]=N(),[t,n]=i.useState({kind:"checking"}),[l,f]=i.useState(0),d=i.useRef(null),m=i.useRef(null),x=a.get("new")==="1";if(i.useEffect(()=>{if(x)return;const s=`${l}|${a.toString()}`;if(d.current===s)return;d.current=s,n(c=>c.kind==="checking"?c:{kind:"checking"});const o=a.get("pick")==="1";(async()=>{let c;try{c=await y()}catch{n({kind:"redirect"});return}if(!c.signed_in){n({kind:"redirect"});return}try{const{vaults:u}=await v();if(o&&u.length>0){n({kind:"picker",email:c.email,vaults:u});return}const g=S(u);g.kind==="first-vault"?n({kind:"first-vault"}):g.kind==="welcome-back"?n({kind:"welcome-back",email:c.email,vault:g.vault}):n({kind:"picker",email:c.email,vaults:g.vaults})}catch(u){n({kind:"net-error",message:u instanceof Error?u.message:"Unknown error"})}})()},[l,a,x]),i.useEffect(()=>{if(t.kind!=="welcome-back"||t.error||m.current===t.vault.name)return;m.current=t.vault.name;const s=t.vault.name;(async()=>{try{await j(s),k(s),r("/",{replace:!0})}catch(o){m.current=null,n(c=>c.kind==="welcome-back"&&c.vault.name===s?{...c,error:o instanceof Error?o.message:"Couldn't open your vault."}:c)}})()},[t,r]),x)return e.jsx(b,{to:"/add-vault/create",replace:!0});switch(t.kind){case"checking":return e.jsx(E,{});case"redirect":return e.jsx(b,{to:a.get("link")==="expired"?"/?link=expired":"/",replace:!0});case"first-vault":return e.jsx(b,{to:"/add-vault/create?first=1",replace:!0});case"net-error":return e.jsx(O,{message:t.message,onRetry:()=>{n({kind:"checking"}),f(s=>s+1)}});case"welcome-back":return e.jsx(R,{email:t.email,vaultName:t.vault.name,error:t.error,onRetry:()=>n(s=>s.kind==="welcome-back"?{...s,error:void 0}:s)});case"picker":return e.jsx(W,{email:t.email,vaults:t.vaults,onOpenVault:async s=>{await j(s.name),k(s.name),r("/")},onCreateNew:()=>{r("/add-vault/create")}});default:return null}}function E(){return e.jsxs(p,{escape:{kind:"none"},children:[e.jsx(h,{size:72,className:"mx-auto mb-4 animate-pulse"}),e.jsx("p",{className:"eyebrow mb-3",children:"One moment"}),e.jsxs("h1",{className:"hero-title mb-2",style:{fontSize:"clamp(1.8rem, 4vw, 2.3rem)"},children:["Signing you ",e.jsx("span",{className:"accent-word",children:"in…"})]}),e.jsx("output",{"aria-live":"polite",className:"font-round text-sm text-fg-muted",children:"Checking your vaults…"})]})}function O({message:r,onRetry:a}){return e.jsxs(p,{escape:{kind:"back",to:"/"},children:[e.jsx(h,{size:56,className:"mx-auto mb-6"}),e.jsx("p",{className:"eyebrow mb-3",children:"Almost there"}),e.jsxs("h1",{className:"hero-title mb-4",style:{fontSize:"clamp(1.8rem, 4vw, 2.2rem)"},children:["You're signed in — we just couldn't fetch your ",e.jsx("span",{className:"accent-word",children:"vaults."})]}),e.jsx("p",{className:"mx-auto mb-6 max-w-sm text-fg-muted",children:r}),e.jsx("button",{type:"button",onClick:a,className:"btn btn-primary btn-lg justify-center rounded-full px-6 shadow-soft",children:"Try again"})]})}function R({email:r,vaultName:a,error:t,onRetry:n}){return t?e.jsxs(p,{escape:{kind:"back",to:"/"},children:[e.jsx(h,{size:60,className:"mx-auto mb-6"}),e.jsx("p",{className:"eyebrow mb-3",children:"One moment"}),e.jsxs("h1",{className:"hero-title mb-4",style:{fontSize:"clamp(1.6rem, 3.5vw, 2.1rem)"},children:["Couldn't open ",e.jsxs("span",{className:"accent-word",children:[a,"."]})]}),e.jsx("p",{className:"mx-auto mb-6 max-w-sm text-fg-muted",children:t}),e.jsx("button",{type:"button",onClick:n,className:"btn btn-primary btn-lg justify-center rounded-full px-6 shadow-soft",children:"Try again"})]}):e.jsxs(p,{escape:{kind:"none"},children:[e.jsx(h,{size:76,className:"mx-auto mb-4 animate-pulse"}),e.jsx("p",{className:"eyebrow mb-3",children:"Welcome back"}),e.jsxs("h1",{className:"hero-title mb-3",style:{fontSize:"clamp(1.8rem, 4vw, 2.1rem)"},children:["Opening ",e.jsxs("span",{className:"accent-word",children:[a,"…"]})]}),e.jsxs("output",{"aria-live":"polite",className:"mx-auto max-w-sm text-fg-muted",children:["Signed in as ",r??"you"," — opening ",a,"…"]})]})}function V({vault:r,busy:a,onOpen:t}){const n=z(r.usage),l=r.url?r.url.replace(/^https?:\/\//,""):"";return e.jsxs("li",{className:"card flex items-center gap-4 rounded-2xl p-4 shadow-soft",children:[e.jsx("span",{"aria-hidden":"true",className:"grid h-9 w-9 shrink-0 place-items-center rounded-lg bg-grass-soft text-base",children:"🌱"}),e.jsxs("div",{className:"min-w-0 flex-1 text-left",children:[e.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[e.jsx("span",{className:"font-serif text-lg text-fg",children:r.name}),e.jsx("span",{className:"chip",children:"☁ Cloud"})]}),l?e.jsx("p",{className:"mt-0.5 truncate note-id",children:l}):null,n?e.jsx("p",{className:"mt-0.5 font-round text-xs text-fg-muted",children:n}):null]}),e.jsx("button",{type:"button",onClick:t,disabled:a,className:"btn btn-primary btn-touch shrink-0 rounded-full",children:a?"Opening…":"Open →"})]})}function W({email:r,vaults:a,onOpenVault:t,onCreateNew:n}){const[l,f]=i.useState(null),[d,m]=i.useState(null);async function x(s){if(!l){f(s.name),m(null);try{await t(s)}catch(o){f(null),m(o instanceof Error?o.message:"Couldn't open that vault.")}}}return e.jsxs(p,{wide:!0,escape:{kind:"back",to:"/"},children:[e.jsx(h,{size:56,className:"mx-auto mb-6"}),e.jsx("p",{className:"eyebrow mb-3",children:"Which vault"}),e.jsxs("h1",{className:"hero-title mb-3",style:{fontSize:"clamp(1.8rem, 4vw, 2.4rem)"},children:["Which vault ",e.jsx("span",{className:"accent-word",children:"today?"})]}),e.jsxs("p",{className:"mx-auto mb-8 max-w-sm text-fg-muted",children:["Signed in as ",r??"you"," · ",a.length," vault",a.length===1?"":"s"," on Cloud"]}),e.jsx("ul",{className:"mx-auto flex max-w-md flex-col gap-3",children:a.map(s=>e.jsx(V,{vault:s,busy:l===s.name,onOpen:()=>x(s)},s.name))}),d?e.jsx("p",{className:"mx-auto mt-6 max-w-sm rounded-lg border border-danger-border bg-danger-soft px-3 py-2 text-sm text-danger",children:d}):null,e.jsxs("p",{className:"mt-8 font-round text-sm text-fg-muted",children:[e.jsx("button",{type:"button",onClick:n,className:"font-semibold text-accent hover:underline",children:"+ Create a new vault"})," ","·"," ",e.jsx(C,{to:"/add",className:"font-semibold hover:underline",style:{color:"var(--color-sky)"},children:"Connect a self-hosted vault"})]})]})}export{A as Welcome};
@@ -1 +0,0 @@
1
- /*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-space-y-reverse:0;--tw-divide-y-reverse:0;--tw-border-style:solid;--tw-leading:initial;--tw-font-weight:initial;--tw-tracking:initial;--tw-ordinal:initial;--tw-slashed-zero:initial;--tw-numeric-figure:initial;--tw-numeric-spacing:initial;--tw-numeric-fraction:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-outline-style:solid;--tw-blur:initial;--tw-brightness:initial;--tw-contrast:initial;--tw-grayscale:initial;--tw-hue-rotate:initial;--tw-invert:initial;--tw-opacity:initial;--tw-saturate:initial;--tw-sepia:initial;--tw-drop-shadow:initial;--tw-drop-shadow-color:initial;--tw-drop-shadow-alpha:100%;--tw-drop-shadow-size:initial;--tw-backdrop-blur:initial;--tw-backdrop-brightness:initial;--tw-backdrop-contrast:initial;--tw-backdrop-grayscale:initial;--tw-backdrop-hue-rotate:initial;--tw-backdrop-invert:initial;--tw-backdrop-opacity:initial;--tw-backdrop-saturate:initial;--tw-backdrop-sepia:initial;--tw-duration:initial;--tw-ease:initial;--tw-scale-x:1;--tw-scale-y:1;--tw-scale-z:1;--tw-content:""}}}@font-face{font-family:Fraunces Variable;font-style:normal;font-display:swap;font-weight:100 900;src:url(/assets/fraunces-vietnamese-opsz-normal-Czevyj-6.woff2)format("woff2-variations");unicode-range:U+102-103,U+110-111,U+128-129,U+168-169,U+1A0-1A1,U+1AF-1B0,U+300-301,U+303-304,U+308-309,U+323,U+329,U+1EA0-1EF9,U+20AB}@font-face{font-family:Fraunces Variable;font-style:normal;font-display:swap;font-weight:100 900;src:url(/assets/fraunces-latin-ext-opsz-normal-CJcjJNj7.woff2)format("woff2-variations");unicode-range:U+100-2BA,U+2BD-2C5,U+2C7-2CC,U+2CE-2D7,U+2DD-2FF,U+304,U+308,U+329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Fraunces Variable;font-style:normal;font-display:swap;font-weight:100 900;src:url(/assets/fraunces-latin-opsz-normal-DihXLNYH.woff2)format("woff2-variations");unicode-range:U+??,U+131,U+152-153,U+2BB-2BC,U+2C6,U+2DA,U+2DC,U+304,U+308,U+329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}@font-face{font-family:Fraunces Variable;font-style:italic;font-display:swap;font-weight:100 900;src:url(/assets/fraunces-vietnamese-opsz-italic-DxWqP7Ku.woff2)format("woff2-variations");unicode-range:U+102-103,U+110-111,U+128-129,U+168-169,U+1A0-1A1,U+1AF-1B0,U+300-301,U+303-304,U+308-309,U+323,U+329,U+1EA0-1EF9,U+20AB}@font-face{font-family:Fraunces Variable;font-style:italic;font-display:swap;font-weight:100 900;src:url(/assets/fraunces-latin-ext-opsz-italic-CGbN9UgK.woff2)format("woff2-variations");unicode-range:U+100-2BA,U+2BD-2C5,U+2C7-2CC,U+2CE-2D7,U+2DD-2FF,U+304,U+308,U+329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Fraunces Variable;font-style:italic;font-display:swap;font-weight:100 900;src:url(/assets/fraunces-latin-opsz-italic-lSdLDfvT.woff2)format("woff2-variations");unicode-range:U+??,U+131,U+152-153,U+2BB-2BC,U+2C6,U+2DA,U+2DC,U+304,U+308,U+329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}@font-face{font-family:Figtree Variable;font-style:normal;font-display:swap;font-weight:300 900;src:url(/assets/figtree-latin-ext-wght-normal-DCwSJGxG.woff2)format("woff2-variations");unicode-range:U+100-2BA,U+2BD-2C5,U+2C7-2CC,U+2CE-2D7,U+2DD-2FF,U+304,U+308,U+329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Figtree Variable;font-style:normal;font-display:swap;font-weight:300 900;src:url(/assets/figtree-latin-wght-normal-D_ZTVpCC.woff2)format("woff2-variations");unicode-range:U+??,U+131,U+152-153,U+2BB-2BC,U+2C6,U+2DA,U+2DC,U+304,U+308,U+329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}@layer theme{:root,:host{--font-sans:"Figtree Variable", -apple-system, system-ui, "Segoe UI", Roboto, sans-serif;--font-serif:"Fraunces Variable", ui-serif, "New York", "Iowan Old Style", Georgia, serif;--font-mono:ui-monospace, "SF Mono", "JetBrains Mono", Menlo, Monaco, "Cascadia Code", monospace;--color-red-50:oklch(97.1% .013 17.38);--color-red-100:oklch(93.6% .032 17.717);--color-red-200:oklch(88.5% .062 18.334);--color-red-300:oklch(80.8% .114 19.571);--color-red-400:oklch(70.4% .191 22.216);--color-red-500:oklch(63.7% .237 25.331);--color-amber-100:oklch(96.2% .059 95.617);--color-amber-200:oklch(92.4% .12 95.746);--color-amber-300:oklch(87.9% .169 91.605);--color-amber-400:oklch(82.8% .189 84.429);--color-amber-500:oklch(76.9% .188 70.08);--color-sky-300:oklch(82.8% .111 230.318);--color-sky-400:oklch(74.6% .16 232.661);--color-sky-500:oklch(68.5% .169 237.323);--color-black:#000;--spacing:.25rem;--container-xs:20rem;--container-sm:24rem;--container-md:28rem;--container-xl:36rem;--container-2xl:42rem;--container-3xl:48rem;--container-4xl:56rem;--container-5xl:64rem;--container-6xl:72rem;--text-xs:.75rem;--text-xs--line-height:calc(1 / .75);--text-sm:.875rem;--text-sm--line-height:calc(1.25 / .875);--text-base:1rem;--text-base--line-height: 1.5 ;--text-lg:1.125rem;--text-lg--line-height:calc(1.75 / 1.125);--text-xl:1.375rem;--text-xl--line-height:calc(1.75 / 1.25);--text-2xl:1.625rem;--text-2xl--line-height:calc(2 / 1.5);--text-3xl:1.9375rem;--text-3xl--line-height: 1.2 ;--font-weight-normal:400;--font-weight-medium:500;--font-weight-semibold:600;--font-weight-bold:700;--tracking-tight:-.025em;--tracking-normal:0em;--tracking-wider:.05em;--leading-tight:1.25;--leading-snug:1.375;--leading-relaxed:1.625;--radius-xs:3px;--radius-sm:4px;--radius-md:6px;--radius-lg:12px;--radius-xl:16px;--radius-2xl:24px;--shadow-sm:0 1px 2px #24422e0f;--ease-out:cubic-bezier(.25, 1, .5, 1);--animate-pulse:pulse 2s cubic-bezier(.4, 0, .6, 1) infinite;--blur-md:12px;--default-transition-duration:.15s;--default-transition-timing-function:cubic-bezier(.4, 0, .2, 1);--default-font-family:var(--font-sans);--default-mono-font-family:var(--font-mono);--font-round:var(--font-sans);--color-bg:#fafaf6;--color-bg-soft:#f7f5ec;--color-fg:#233c2a;--color-fg-muted:#5b6f5e;--color-fg-dim:#8a968b;--color-accent:#bf4a2a;--color-accent-hover:#a63f23;--color-accent-light:#e05d3c;--color-sky:#5b8fa8;--color-grass:#3f8a58;--color-grass-soft:#e1f0e4;--color-grass-ink:#245c39;--color-sun:#f4c020;--color-sun-soft:#fdf1c9;--color-sun-ink:#6b5200;--color-sage:#527e5d;--color-clay:#a8653f;--color-ochre:#a67c1e;--color-plum:#7d5490;--color-border:#d6e2d6;--color-border-light:#e4ece4;--color-card:#fefefa;--color-on-accent:#fff;--color-danger:#c0492f;--color-danger-hover:#a23b25;--color-danger-soft:#c0492f1a}@supports (color:color-mix(in lab,red,red)){:root,:host{--color-danger-soft:color-mix(in srgb, var(--color-danger) 10%, transparent)}}:root,:host{--color-danger-border:#c0492f4d}@supports (color:color-mix(in lab,red,red)){:root,:host{--color-danger-border:color-mix(in srgb, var(--color-danger) 30%, transparent)}}:root,:host{--color-warning:#b45309;--color-warning-soft:#b453091f}@supports (color:color-mix(in lab,red,red)){:root,:host{--color-warning-soft:color-mix(in srgb, var(--color-warning) 12%, transparent)}}:root,:host{--color-positive:var(--color-accent);--color-positive-soft:#bf4a2a1f}@supports (color:color-mix(in lab,red,red)){:root,:host{--color-positive-soft:color-mix(in srgb, var(--color-accent) 12%, transparent)}}:root,:host{--color-coral-soft:#fbe4d9;--color-coral-ink:#8f3417;--text-2xs:.6875rem;--lh-live:1.7;--lh-prose-tight:1.5;--radius-full:9999px;--shadow-soft:0 12px 40px -18px oklch(40% .05 152/.22);--shadow-lift:0 24px 60px -30px oklch(40% .05 152/.28);--dur-quick:.12s;--dur-move:.2s;--dur-enter:.28s;--ease-spring:cubic-bezier(.34, 1.56, .64, 1);--canvas-wash:#3f8a5812}@supports (color:color-mix(in lab,red,red)){:root,:host{--canvas-wash:color-mix(in srgb, var(--color-grass) 7%, transparent)}}:root,:host{--canvas-wash-accent:#bf4a2a0d}@supports (color:color-mix(in lab,red,red)){:root,:host{--canvas-wash-accent:color-mix(in srgb, var(--color-accent) 5%, transparent)}}:root,:host{--w-prose:42rem;--w-page:72rem;--w-narrow:32rem;--w-surface:52rem;--w-board:96rem;--font-size-prose:18px;--font-size-editor:15px}}@layer base{*,:after,:before,::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;-moz-tab-size:4;tab-size:4;line-height:1.5;font-family:var(--default-font-family,-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", "Noto Sans", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji");font-feature-settings:var(--default-font-feature-settings,normal);font-variation-settings:var(--default-font-variation-settings,normal);-webkit-tap-highlight-color:transparent}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:var(--default-mono-font-family,ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace);font-feature-settings:var(--default-mono-font-feature-settings,normal);font-variation-settings:var(--default-mono-font-variation-settings,normal);font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring:where(:not(iframe)){outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab,red,red)){::placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block:0}::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-day-field{padding-block:0}::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){-webkit-appearance:button;-moz-appearance:button;appearance:button}::file-selector-button{-webkit-appearance:button;-moz-appearance:button;appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}}@layer components{.focus-ring{outline:none}.focus-ring:focus-visible{outline-offset:2px;box-shadow:0 0 0 2px var(--color-bg),0 0 0 4px #bf4a2ab3;outline:2px solid #0000}@supports (color:color-mix(in lab,red,red)){.focus-ring:focus-visible{box-shadow:0 0 0 2px var(--color-bg),0 0 0 4px color-mix(in srgb,var(--color-accent) 70%,transparent)}}.focus-ring:focus-visible{border-radius:var(--radius-sm)}.btn{border-radius:var(--radius-full);min-height:2.25rem;font-family:var(--font-round);font-size:var(--text-sm);white-space:nowrap;cursor:pointer;transition:background-color var(--dur-quick) var(--ease-out),border-color var(--dur-quick) var(--ease-out),color var(--dur-quick) var(--ease-out),box-shadow var(--dur-quick) var(--ease-out),transform var(--dur-move) var(--ease-spring);justify-content:center;align-items:center;gap:.5rem;padding:.375rem 1rem;font-weight:500;line-height:1.2;display:inline-flex}.btn:disabled,.btn[aria-disabled=true]{opacity:.45;cursor:not-allowed}.btn:focus-visible{outline-offset:2px;box-shadow:0 0 0 2px var(--color-bg),0 0 0 4px #bf4a2ab3;outline:2px solid #0000}@supports (color:color-mix(in lab,red,red)){.btn:focus-visible{box-shadow:0 0 0 2px var(--color-bg),0 0 0 4px color-mix(in srgb,var(--color-accent) 70%,transparent)}}.btn-primary{background-color:var(--color-accent);color:var(--color-on-accent)}.btn-primary:not(:disabled):hover{background-color:var(--color-accent-hover)}@media(prefers-reduced-motion:no-preference){.btn-primary:not(:disabled):hover{transform:scale(1.02)}}.btn-secondary{background-color:var(--color-card);color:var(--color-fg-muted);border:1px solid var(--color-border)}.btn-secondary:not(:disabled):hover{color:var(--color-accent);border-color:var(--color-accent)}.btn-ghost{color:var(--color-fg-muted);background-color:#0000;min-height:0;padding:.25rem .5rem}.btn-ghost:not(:disabled):hover{color:var(--color-accent)}.btn-danger{background-color:var(--color-danger-soft);color:var(--color-danger);border:1px solid var(--color-danger-border)}.btn-danger:not(:disabled):hover{background-color:#c0492f2e}@supports (color:color-mix(in lab,red,red)){.btn-danger:not(:disabled):hover{background-color:color-mix(in srgb,var(--color-danger) 18%,transparent)}}.btn-danger:not(:disabled):hover{border-color:var(--color-danger)}.btn-accent-soft{background-color:#bf4a2a1a}@supports (color:color-mix(in lab,red,red)){.btn-accent-soft{background-color:color-mix(in srgb,var(--color-accent) 10%,transparent)}}.btn-accent-soft{color:var(--color-accent);border:1px solid #bf4a2a99}@supports (color:color-mix(in lab,red,red)){.btn-accent-soft{border:1px solid color-mix(in srgb,var(--color-accent) 60%,transparent)}}.btn-accent-soft:not(:disabled):hover{background-color:#bf4a2a33}@supports (color:color-mix(in lab,red,red)){.btn-accent-soft:not(:disabled):hover{background-color:color-mix(in srgb,var(--color-accent) 20%,transparent)}}.btn-danger-solid{background-color:var(--color-danger);color:var(--color-on-accent)}.btn-danger-solid:not(:disabled):hover{background-color:var(--color-danger-hover)}.btn-sm{min-height:0;font-size:var(--text-xs);padding:.25rem .75rem}.btn-lg{min-height:2.75rem;font-size:var(--text-base);padding:.5rem 1rem}.btn-touch{min-height:2.75rem}.input,.textarea,.select{background-color:var(--color-card);width:100%;color:var(--color-fg);border:1px solid var(--color-border);border-radius:var(--radius-full);font-size:var(--text-sm);transition:border-color var(--dur-quick) var(--ease-out),box-shadow var(--dur-quick) var(--ease-out);padding:.5rem 1rem;line-height:1.5}.textarea{resize:vertical;border-radius:var(--radius-xl);padding:.5rem .75rem}.input::placeholder,.textarea::placeholder{color:var(--color-fg-dim)}.input:focus-visible,.textarea:focus-visible,.select:focus-visible{border-color:var(--color-accent);outline:none;box-shadow:0 0 0 3px #bf4a2a38}@supports (color:color-mix(in lab,red,red)){.input:focus-visible,.textarea:focus-visible,.select:focus-visible{box-shadow:0 0 0 3px color-mix(in srgb,var(--color-accent) 22%,transparent)}}.input:disabled,.textarea:disabled,.select:disabled{opacity:.5;cursor:not-allowed}.input-on-bg{background-color:var(--color-bg)}.card{background-color:var(--color-card);border:1px solid var(--color-border);border-radius:var(--radius-2xl)}.glass-panel{background-color:#f7f5ecd1}@supports (color:color-mix(in lab,red,red)){.glass-panel{background-color:color-mix(in srgb,var(--color-bg-soft) 82%,transparent)}}.glass-panel{-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px)}.cm-format-toolbar-docked{padding:.375rem .5rem;padding-bottom:calc(.375rem + env(safe-area-inset-bottom));border-top:1px solid var(--color-border);box-shadow:var(--shadow-lift);animation:enter-rise var(--dur-enter) var(--ease-out) both;justify-content:center;align-items:center;gap:.25rem;display:flex}.chip{border-radius:var(--radius-full);font-size:var(--text-xs);border:1px solid var(--color-border);background-color:var(--color-bg-soft);color:var(--color-fg-muted);align-items:center;gap:.25rem;padding:.125rem .625rem;line-height:1.4;display:inline-flex}.chip-tag{border-color:#bf4a2a4d}@supports (color:color-mix(in lab,red,red)){.chip-tag{border-color:color-mix(in srgb,var(--color-accent) 30%,transparent)}}.chip-tag{background-color:#bf4a2a1a}@supports (color:color-mix(in lab,red,red)){.chip-tag{background-color:color-mix(in srgb,var(--color-accent) 10%,transparent)}}.chip-tag{color:var(--color-accent)}.chip-tag:hover{border-color:var(--color-accent);background-color:#bf4a2a33}@supports (color:color-mix(in lab,red,red)){.chip-tag:hover{background-color:color-mix(in srgb,var(--color-accent) 20%,transparent)}}.chip-tag-active{border-color:var(--color-accent);background-color:var(--color-accent);color:var(--color-on-accent)}.chip-featured{border-color:#8f341740}@supports (color:color-mix(in lab,red,red)){.chip-featured{border-color:color-mix(in srgb,var(--color-coral-ink) 25%,transparent)}}.chip-featured{background-color:var(--color-coral-soft);color:var(--color-coral-ink)}.dialog-overlay{z-index:40;animation:enter-fade var(--dur-quick) var(--ease-out) both;background-color:#0009;justify-content:center;align-items:center;padding:1rem;display:flex;position:fixed;top:0;right:0;bottom:0;left:0}.dialog-panel{background-color:var(--color-card);border:1px solid var(--color-border);border-radius:var(--radius-2xl);width:100%;box-shadow:var(--shadow-lift);animation:enter-rise var(--dur-enter) var(--ease-out) both;padding:1.25rem}.app-canvas{background-color:var(--color-bg);background-image:radial-gradient(1100px 520px at 50% -6%,var(--canvas-wash),transparent 70%),radial-gradient(900px 480px at 4% 104%,var(--canvas-wash-accent),transparent 70%);background-repeat:no-repeat}.page-title{font-family:var(--font-serif);font-size:clamp(var(--text-2xl),calc(var(--text-xl) + 1.2vw),2.25rem);letter-spacing:-.01em;color:var(--color-fg);text-wrap:balance;line-height:1.12}.title-timestamp{font-family:var(--font-sans);color:var(--color-fg-dim);font-variant-numeric:tabular-nums;font-weight:400}.eyebrow{font-family:var(--font-round);font-size:var(--text-xs);text-transform:uppercase;letter-spacing:.08em;color:var(--color-sage)}.eyebrow-accent{color:var(--color-accent)}.note-id{font-family:var(--font-mono);font-size:var(--text-xs);color:var(--color-fg-dim);word-break:break-all}.page{max-width:var(--w-page);margin-inline:auto;padding-block:1.5rem;padding-inline:1.25rem}@media(min-width:768px){.page{padding-block:2.75rem;padding-inline:2.5rem}}.page.page-wide{max-width:var(--w-board)}.page-surface{max-width:var(--w-surface);margin-inline:auto;padding-block:1.5rem;padding-inline:1.25rem}@media(min-width:768px){.page-surface{padding-block:2.75rem;padding-inline:2rem}}.page-prose{max-width:var(--w-prose);margin-inline:auto;padding-block:2rem;padding-inline:1.25rem}@media(min-width:768px){.page-prose{padding-block:3.25rem;padding-inline:2rem}}.skeleton{background-color:#d6e2d68c}@supports (color:color-mix(in lab,red,red)){.skeleton{background-color:color-mix(in srgb,var(--color-border) 55%,transparent)}}.skeleton{border-radius:var(--radius-sm);animation:1.6s cubic-bezier(.4,0,.6,1) infinite pulse}.composer{border:1.5px solid var(--color-border);background-color:var(--color-card);box-shadow:var(--shadow-soft);transition:border-color var(--dur-quick) var(--ease-out),box-shadow var(--dur-quick) var(--ease-out);border-radius:20px}.composer-focus,.composer:hover,.composer:focus-within{border-color:var(--color-accent-light);box-shadow:0 0 0 4px var(--color-coral-soft)}.nudge-sun{border-radius:var(--radius-xl);border:1px solid #e4d384;align-items:center;gap:.75rem;display:flex}@supports (color:color-mix(in lab,red,red)){.nudge-sun{border:1px solid color-mix(in srgb,var(--color-sun) 45%,var(--color-border))}}.nudge-sun{background-color:var(--color-sun-soft);color:var(--color-sun-ink);font-family:var(--font-round);padding:.75rem 1rem;font-weight:600}.note-row{border-radius:var(--radius-xl);transition:background-color var(--dur-quick) var(--ease-out),border-color var(--dur-quick) var(--ease-out),transform var(--dur-move) var(--ease-out),box-shadow var(--dur-move) var(--ease-out);border:1px solid #0000;gap:.75rem;padding:.75rem;display:flex}.note-row:hover{background-color:var(--color-card);border-color:var(--color-border-light)}@media(hover:hover)and (prefers-reduced-motion:no-preference){.note-row:hover{box-shadow:var(--shadow-sm);transform:translateY(-1px)}}.note-row:active{background-color:var(--color-grass-soft);border-color:#0000}.note-dot{border-radius:var(--radius-full);background-color:var(--color-grass);flex:none;width:.5rem;height:.5rem;margin-top:.45rem}.hue-dot{border-radius:var(--radius-full);flex:none;width:.5rem;height:.5rem}.hue-dot-sage{background-color:var(--color-sage)}.hue-dot-sky{background-color:var(--color-sky)}.hue-dot-sun{background-color:var(--color-sun)}.hue-dot-coral{background-color:var(--color-coral-ink)}.hue-dot-grass{background-color:var(--color-grass)}.hue-dot-clay{background-color:var(--color-clay)}.hue-dot-ochre{background-color:var(--color-ochre)}.hue-dot-plum{background-color:var(--color-plum)}.chip-tinted{background:var(--sc)}@supports (color:color-mix(in lab,red,red)){.chip-tinted{background:color-mix(in srgb,var(--sc) 10%,var(--color-card))}}.chip-tinted{border-color:var(--sc)}@supports (color:color-mix(in lab,red,red)){.chip-tinted{border-color:color-mix(in srgb,var(--sc) 30%,var(--color-border))}}.tint-dot{border-radius:var(--radius-full);background:var(--sc);flex:none;width:.4375rem;height:.4375rem}.tint-sage{--sc:var(--color-sage)}.tint-sky{--sc:var(--color-sky)}.tint-sun{--sc:var(--color-sun)}.tint-coral{--sc:var(--color-coral-ink)}.tint-grass{--sc:var(--color-grass)}.tint-clay{--sc:var(--color-clay)}.tint-ochre{--sc:var(--color-ochre)}.tint-plum{--sc:var(--color-plum)}.tint-danger{--sc:var(--color-danger)}.tile{border-radius:var(--radius-xl);border:1.5px solid var(--color-border);background-color:var(--color-card);box-shadow:var(--shadow-soft);transition:border-color var(--dur-quick) var(--ease-out),box-shadow var(--dur-quick) var(--ease-out),transform var(--dur-quick) var(--ease-out)}.tile:hover{border-color:#bf4a2a8c}@supports (color:color-mix(in lab,red,red)){.tile:hover{border-color:color-mix(in srgb,var(--color-accent) 55%,transparent)}}.tile:hover{box-shadow:var(--shadow-lift)}.hero-title{font-family:var(--font-serif);letter-spacing:-.02em;color:var(--color-fg);text-wrap:balance;font-size:clamp(2.4rem,5vw,3.6rem);font-weight:600;line-height:1.05}.accent-word{color:var(--color-accent-light);font-style:italic}@keyframes drop-in{0%{opacity:0;transform:translateY(-42px)rotate(-7deg)}60%{opacity:1;transform:translateY(6px)rotate(2deg)}to{opacity:1;transform:translateY(0)rotate(-2deg)}}.drop-in{animation:1.2s cubic-bezier(.3,.7,.4,1) both drop-in}@keyframes fade-up{0%{opacity:0;transform:translateY(8px)}to{opacity:1;transform:translateY(0)}}.fade-up{animation:fade-up var(--dur-enter) ease both}@keyframes enter-rise{0%{opacity:0;transform:translateY(10px)}to{opacity:1;transform:translateY(0)}}.enter-rise{animation:enter-rise var(--dur-enter) var(--ease-out) both}@keyframes enter-fade{0%{opacity:0}to{opacity:1}}.enter-fade{animation:enter-fade var(--dur-quick) var(--ease-out) both}.qs-scrim-fade{animation:enter-fade .18s var(--ease-out) both}@keyframes field-write-flash{0%,to{outline-color:#0000}20%{outline-color:color-mix(in srgb,var(--color-accent) 75%,transparent)}}.field-write-flash{outline-offset:2px;animation:field-write-flash .6s var(--ease-out);outline:2px solid #0000}@keyframes view-modified-pulse{0%,to{opacity:1;transform:scale(1)}50%{opacity:.4;transform:scale(.75)}}.view-modified-pulse{animation:2s ease-in-out infinite view-modified-pulse}@media(prefers-reduced-motion:reduce){:root{--dur-move:0s;--dur-enter:0s}.drop-in,.fade-up,.enter-rise,.enter-fade,.qs-scrim-fade,.field-write-flash,.view-modified-pulse,.dialog-overlay,.dialog-panel,.cm-format-toolbar-docked{animation:none}}}@layer utilities{.pointer-events-auto{pointer-events:auto}.pointer-events-none{pointer-events:none}.collapse{visibility:collapse}.invisible{visibility:hidden}.visible{visibility:visible}.sr-only{clip-path:inset(50%);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.absolute{position:absolute}.fixed{position:fixed}.relative{position:relative}.static{position:static}.sticky{position:sticky}.inset-0{top:0;right:0;bottom:0;left:0}.inset-x-0{inset-inline:0}.top-0{top:0}.top-0\.5{top:calc(var(--spacing) * .5)}.top-2{top:calc(var(--spacing) * 2)}.top-4{top:calc(var(--spacing) * 4)}.top-6{top:calc(var(--spacing) * 6)}.-right-0\.5{right:calc(var(--spacing) * -.5)}.right-0{right:0}.right-2{right:calc(var(--spacing) * 2)}.right-3{right:calc(var(--spacing) * 3)}.right-4{right:calc(var(--spacing) * 4)}.right-5{right:calc(var(--spacing) * 5)}.right-6{right:calc(var(--spacing) * 6)}.-bottom-0\.5{bottom:calc(var(--spacing) * -.5)}.bottom-0{bottom:0}.bottom-3{bottom:calc(var(--spacing) * 3)}.bottom-6{bottom:calc(var(--spacing) * 6)}.bottom-20{bottom:calc(var(--spacing) * 20)}.bottom-\[calc\(3\.5rem\+env\(safe-area-inset-bottom\)\)\]{bottom:calc(3.5rem + env(safe-area-inset-bottom))}.bottom-full{bottom:100%}.left-0{left:0}.left-1\/2{left:50%}.left-4{left:calc(var(--spacing) * 4)}.-z-10{z-index:-10}.z-10{z-index:10}.z-20{z-index:20}.z-30{z-index:30}.z-40{z-index:40}.z-50{z-index:50}.z-\[1\]{z-index:1}.row-1{grid-row:1}.container{width:100%}@media(min-width:40rem){.container{max-width:40rem}}@media(min-width:48rem){.container{max-width:48rem}}@media(min-width:64rem){.container{max-width:64rem}}@media(min-width:80rem){.container{max-width:80rem}}@media(min-width:96rem){.container{max-width:96rem}}.m-0{margin:0}.m-auto{margin:auto}.-mx-2{margin-inline:calc(var(--spacing) * -2)}.-mx-5{margin-inline:calc(var(--spacing) * -5)}.mx-1{margin-inline:var(--spacing)}.mx-1\.5{margin-inline:calc(var(--spacing) * 1.5)}.mx-2{margin-inline:calc(var(--spacing) * 2)}.mx-auto{margin-inline:auto}.-my-3{margin-block:calc(var(--spacing) * -3)}.my-8{margin-block:calc(var(--spacing) * 8)}.-mt-4{margin-top:calc(var(--spacing) * -4)}.mt-0\.5{margin-top:calc(var(--spacing) * .5)}.mt-1{margin-top:var(--spacing)}.mt-1\.5{margin-top:calc(var(--spacing) * 1.5)}.mt-2{margin-top:calc(var(--spacing) * 2)}.mt-3{margin-top:calc(var(--spacing) * 3)}.mt-4{margin-top:calc(var(--spacing) * 4)}.mt-5{margin-top:calc(var(--spacing) * 5)}.mt-6{margin-top:calc(var(--spacing) * 6)}.mt-8{margin-top:calc(var(--spacing) * 8)}.mt-10{margin-top:calc(var(--spacing) * 10)}.mt-auto{margin-top:auto}.mr-1{margin-right:var(--spacing)}.mr-2{margin-right:calc(var(--spacing) * 2)}.mb-1{margin-bottom:var(--spacing)}.mb-1\.5{margin-bottom:calc(var(--spacing) * 1.5)}.mb-2{margin-bottom:calc(var(--spacing) * 2)}.mb-3{margin-bottom:calc(var(--spacing) * 3)}.mb-4{margin-bottom:calc(var(--spacing) * 4)}.mb-5{margin-bottom:calc(var(--spacing) * 5)}.mb-6{margin-bottom:calc(var(--spacing) * 6)}.mb-8{margin-bottom:calc(var(--spacing) * 8)}.mb-10{margin-bottom:calc(var(--spacing) * 10)}.ml-0\.5{margin-left:calc(var(--spacing) * .5)}.ml-1{margin-left:var(--spacing)}.ml-2{margin-left:calc(var(--spacing) * 2)}.ml-4{margin-left:calc(var(--spacing) * 4)}.ml-8{margin-left:calc(var(--spacing) * 8)}.ml-auto{margin-left:auto}.line-clamp-2{-webkit-line-clamp:2;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.line-clamp-3{-webkit-line-clamp:3;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.block{display:block}.contents{display:contents}.flex{display:flex}.grid{display:grid}.hidden{display:none}.inline{display:inline}.inline-block{display:inline-block}.inline-flex{display:inline-flex}.table{display:table}.aspect-\[3\/2\]{aspect-ratio:3/2}.h-1{height:var(--spacing)}.h-1\.5{height:calc(var(--spacing) * 1.5)}.h-2{height:calc(var(--spacing) * 2)}.h-3{height:calc(var(--spacing) * 3)}.h-4{height:calc(var(--spacing) * 4)}.h-5{height:calc(var(--spacing) * 5)}.h-6{height:calc(var(--spacing) * 6)}.h-7{height:calc(var(--spacing) * 7)}.h-8{height:calc(var(--spacing) * 8)}.h-9{height:calc(var(--spacing) * 9)}.h-10{height:calc(var(--spacing) * 10)}.h-11{height:calc(var(--spacing) * 11)}.h-12{height:calc(var(--spacing) * 12)}.h-14{height:calc(var(--spacing) * 14)}.h-16{height:calc(var(--spacing) * 16)}.h-24{height:calc(var(--spacing) * 24)}.h-32{height:calc(var(--spacing) * 32)}.h-\[3\.25rem\]{height:3.25rem}.h-\[24rem\]{height:24rem}.h-\[40rem\]{height:40rem}.h-\[60dvh\]{height:60dvh}.h-\[85dvh\]{height:85dvh}.h-\[calc\(100dvh-5rem\)\]{height:calc(100dvh - 5rem)}.h-\[…dvh\]{height:…dvh}.h-dvh{height:100dvh}.h-full{height:100%}.h-px{height:1px}.max-h-48{max-height:calc(var(--spacing) * 48)}.max-h-\[32rem\]{max-height:32rem}.max-h-\[45vh\]{max-height:45vh}.max-h-\[60vh\]{max-height:60vh}.max-h-\[70dvh\]{max-height:70dvh}.max-h-\[85dvh\]{max-height:85dvh}.max-h-full{max-height:100%}.max-h-none{max-height:none}.min-h-0{min-height:0}.min-h-6{min-height:calc(var(--spacing) * 6)}.min-h-8{min-height:calc(var(--spacing) * 8)}.min-h-11{min-height:calc(var(--spacing) * 11)}.min-h-20{min-height:calc(var(--spacing) * 20)}.min-h-24{min-height:calc(var(--spacing) * 24)}.min-h-\[40vh\]{min-height:40vh}.min-h-\[50dvh\]{min-height:50dvh}.min-h-\[60dvh\]{min-height:60dvh}.min-h-\[85dvh\]{min-height:85dvh}.min-h-\[calc\(100dvh-4rem\)\]{min-height:calc(100dvh - 4rem)}.min-h-dvh{min-height:100dvh}.w-1{width:var(--spacing)}.w-1\.5{width:calc(var(--spacing) * 1.5)}.w-1\/3{width:33.3333%}.w-2{width:calc(var(--spacing) * 2)}.w-2\/3{width:66.6667%}.w-2\/5{width:40%}.w-3\/5{width:60%}.w-4{width:calc(var(--spacing) * 4)}.w-4\/5{width:80%}.w-5{width:calc(var(--spacing) * 5)}.w-6{width:calc(var(--spacing) * 6)}.w-7{width:calc(var(--spacing) * 7)}.w-8{width:calc(var(--spacing) * 8)}.w-9{width:calc(var(--spacing) * 9)}.w-10{width:calc(var(--spacing) * 10)}.w-11{width:calc(var(--spacing) * 11)}.w-12{width:calc(var(--spacing) * 12)}.w-14{width:calc(var(--spacing) * 14)}.w-16{width:calc(var(--spacing) * 16)}.w-24{width:calc(var(--spacing) * 24)}.w-32{width:calc(var(--spacing) * 32)}.w-40{width:calc(var(--spacing) * 40)}.w-44{width:calc(var(--spacing) * 44)}.w-60{width:calc(var(--spacing) * 60)}.w-72{width:calc(var(--spacing) * 72)}.w-80{width:calc(var(--spacing) * 80)}.w-\[3\.25rem\]{width:3.25rem}.w-full{width:100%}.w-px{width:1px}.w-screen{width:100vw}.max-w-\(--w-narrow\){max-width:var(--w-narrow)}.max-w-\(--w-page\){max-width:var(--w-page)}.max-w-2xl{max-width:var(--container-2xl)}.max-w-3xl{max-width:var(--container-3xl)}.max-w-4xl{max-width:var(--container-4xl)}.max-w-5xl{max-width:var(--container-5xl)}.max-w-6xl{max-width:var(--container-6xl)}.max-w-\[9rem\]{max-width:9rem}.max-w-\[12rem\]{max-width:12rem}.max-w-\[16rem\]{max-width:16rem}.max-w-full{max-width:100%}.max-w-md{max-width:var(--container-md)}.max-w-none{max-width:none}.max-w-prose{max-width:65ch}.max-w-sm{max-width:var(--container-sm)}.max-w-xl{max-width:var(--container-xl)}.max-w-xs{max-width:var(--container-xs)}.min-w-0{min-width:0}.min-w-11{min-width:calc(var(--spacing) * 11)}.min-w-24{min-width:calc(var(--spacing) * 24)}.min-w-48{min-width:calc(var(--spacing) * 48)}.min-w-\[10rem\]{min-width:10rem}.min-w-\[36rem\]{min-width:36rem}.flex-1{flex:1}.flex-none{flex:none}.flex-shrink,.shrink{flex-shrink:1}.shrink-0{flex-shrink:0}.flex-grow,.grow{flex-grow:1}.basis-full{flex-basis:100%}.border-collapse{border-collapse:collapse}.-translate-x-1\/2{--tw-translate-x: -50% ;translate:var(--tw-translate-x) var(--tw-translate-y)}.translate-x-0\.5{--tw-translate-x:calc(var(--spacing) * .5);translate:var(--tw-translate-x) var(--tw-translate-y)}.translate-x-5{--tw-translate-x:calc(var(--spacing) * 5);translate:var(--tw-translate-x) var(--tw-translate-y)}.rotate-45{rotate:45deg}.rotate-180{rotate:180deg}.transform{transform:var(--tw-rotate-x,) var(--tw-rotate-y,) var(--tw-rotate-z,) var(--tw-skew-x,) var(--tw-skew-y,)}.animate-pulse{animation:var(--animate-pulse)}.cursor-default{cursor:default}.cursor-grab{cursor:grab}.cursor-pointer{cursor:pointer}.touch-none{touch-action:none}.resize{resize:both}.resize-none{resize:none}.list-decimal{list-style-type:decimal}.list-disc{list-style-type:disc}.list-none{list-style-type:none}.grid-cols-7{grid-template-columns:repeat(7,minmax(0,1fr))}.grid-cols-\[repeat\(auto-fill\,minmax\(min\(100\%\,13rem\)\,1fr\)\)\]{grid-template-columns:repeat(auto-fill,minmax(min(100%,13rem),1fr))}.grid-cols-\[repeat\(auto-fill\,minmax\(min\(100\%\,16rem\)\,1fr\)\)\]{grid-template-columns:repeat(auto-fill,minmax(min(100%,16rem),1fr))}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.place-items-center{place-items:center}.items-baseline{align-items:baseline}.items-center{align-items:center}.items-end{align-items:flex-end}.items-start{align-items:flex-start}.items-stretch{align-items:stretch}.justify-around{justify-content:space-around}.justify-between{justify-content:space-between}.justify-center{justify-content:center}.justify-end{justify-content:flex-end}.gap-0\.5{gap:calc(var(--spacing) * .5)}.gap-1{gap:var(--spacing)}.gap-1\.5{gap:calc(var(--spacing) * 1.5)}.gap-2{gap:calc(var(--spacing) * 2)}.gap-2\.5{gap:calc(var(--spacing) * 2.5)}.gap-3{gap:calc(var(--spacing) * 3)}.gap-4{gap:calc(var(--spacing) * 4)}.gap-10{gap:calc(var(--spacing) * 10)}:where(.space-y-0\.5>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * .5) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * .5) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-1>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(var(--spacing) * var(--tw-space-y-reverse));margin-block-end:calc(var(--spacing) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-1\.5>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 1.5) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 1.5) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-2>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 2) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 2) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-2\.5>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 2.5) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 2.5) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-3>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 3) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 3) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-4>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 4) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 4) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-5>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 5) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 5) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-6>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 6) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 6) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-8>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 8) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 8) * calc(1 - var(--tw-space-y-reverse)))}.gap-x-2{column-gap:calc(var(--spacing) * 2)}.gap-x-3{column-gap:calc(var(--spacing) * 3)}.gap-x-4{column-gap:calc(var(--spacing) * 4)}.gap-y-1{row-gap:var(--spacing)}.gap-y-2{row-gap:calc(var(--spacing) * 2)}.gap-y-3{row-gap:calc(var(--spacing) * 3)}:where(.divide-y>:not(:last-child)){--tw-divide-y-reverse:0;border-bottom-style:var(--tw-border-style);border-top-style:var(--tw-border-style);border-top-width:calc(1px * var(--tw-divide-y-reverse));border-bottom-width:calc(1px * calc(1 - var(--tw-divide-y-reverse)))}:where(.divide-border>:not(:last-child)){border-color:var(--color-border)}:where(.divide-border-light>:not(:last-child)){border-color:var(--color-border-light)}.self-center{align-self:center}.self-start{align-self:flex-start}.truncate{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-x-auto{overflow-x:auto}.overflow-x-hidden{overflow-x:hidden}.overflow-y-auto{overflow-y:auto}.rounded{border-radius:.25rem}.rounded-2xl{border-radius:var(--radius-2xl)}.rounded-full{border-radius:var(--radius-full)}.rounded-lg{border-radius:var(--radius-lg)}.rounded-md{border-radius:var(--radius-md)}.rounded-sm{border-radius:var(--radius-sm)}.rounded-xl{border-radius:var(--radius-xl)}.rounded-t-\[var\(--radius-2xl\)\]{border-top-left-radius:var(--radius-2xl);border-top-right-radius:var(--radius-2xl)}.rounded-b-none{border-bottom-right-radius:0;border-bottom-left-radius:0}.border{border-style:var(--tw-border-style);border-width:1px}.border-0{border-style:var(--tw-border-style);border-width:0}.border-2{border-style:var(--tw-border-style);border-width:2px}.border-t{border-top-style:var(--tw-border-style);border-top-width:1px}.border-r{border-right-style:var(--tw-border-style);border-right-width:1px}.border-b{border-bottom-style:var(--tw-border-style);border-bottom-width:1px}.border-b-2{border-bottom-style:var(--tw-border-style);border-bottom-width:2px}.border-l{border-left-style:var(--tw-border-style);border-left-width:1px}.border-dashed{--tw-border-style:dashed;border-style:dashed}.border-\(--color-danger-border\){border-color:var(--color-danger-border)}.border-\(--color-warning\){border-color:var(--color-warning)}.border-\[color-mix\(in_srgb\,var\(--color-accent\)_40\%\,var\(--color-border\)\)\]{border-color:#cda591}@supports (color:color-mix(in lab,red,red)){.border-\[color-mix\(in_srgb\,var\(--color-accent\)_40\%\,var\(--color-border\)\)\]{border-color:color-mix(in srgb,var(--color-accent) 40%,var(--color-border))}}.border-accent{border-color:var(--color-accent)}.border-accent\/30{border-color:#bf4a2a4d}@supports (color:color-mix(in lab,red,red)){.border-accent\/30{border-color:color-mix(in oklab,var(--color-accent) 30%,transparent)}}.border-accent\/40{border-color:#bf4a2a66}@supports (color:color-mix(in lab,red,red)){.border-accent\/40{border-color:color-mix(in oklab,var(--color-accent) 40%,transparent)}}.border-accent\/60{border-color:#bf4a2a99}@supports (color:color-mix(in lab,red,red)){.border-accent\/60{border-color:color-mix(in oklab,var(--color-accent) 60%,transparent)}}.border-amber-400\/40{border-color:#fcbb0066}@supports (color:color-mix(in lab,red,red)){.border-amber-400\/40{border-color:color-mix(in oklab,var(--color-amber-400) 40%,transparent)}}.border-amber-500\/30{border-color:#f99c004d}@supports (color:color-mix(in lab,red,red)){.border-amber-500\/30{border-color:color-mix(in oklab,var(--color-amber-500) 30%,transparent)}}.border-amber-500\/40{border-color:#f99c0066}@supports (color:color-mix(in lab,red,red)){.border-amber-500\/40{border-color:color-mix(in oklab,var(--color-amber-500) 40%,transparent)}}.border-border{border-color:var(--color-border)}.border-border-light{border-color:var(--color-border-light)}.border-danger-border{border-color:var(--color-danger-border)}.border-grass{border-color:var(--color-grass)}.border-grass\/40{border-color:#3f8a5866}@supports (color:color-mix(in lab,red,red)){.border-grass\/40{border-color:color-mix(in oklab,var(--color-grass) 40%,transparent)}}.border-red-500\/30{border-color:#fb2c364d}@supports (color:color-mix(in lab,red,red)){.border-red-500\/30{border-color:color-mix(in oklab,var(--color-red-500) 30%,transparent)}}.border-red-500\/40{border-color:#fb2c3666}@supports (color:color-mix(in lab,red,red)){.border-red-500\/40{border-color:color-mix(in oklab,var(--color-red-500) 40%,transparent)}}.border-sky-500\/30{border-color:#00a5ef4d}@supports (color:color-mix(in lab,red,red)){.border-sky-500\/30{border-color:color-mix(in oklab,var(--color-sky-500) 30%,transparent)}}.border-sun{border-color:var(--color-sun)}.border-transparent{border-color:#0000}.border-warning{border-color:var(--color-warning)}.border-warning\/30{border-color:#b453094d}@supports (color:color-mix(in lab,red,red)){.border-warning\/30{border-color:color-mix(in oklab,var(--color-warning) 30%,transparent)}}.border-warning\/40{border-color:#b4530966}@supports (color:color-mix(in lab,red,red)){.border-warning\/40{border-color:color-mix(in oklab,var(--color-warning) 40%,transparent)}}.bg-\(--color-danger-soft\){background-color:var(--color-danger-soft)}.bg-\(--color-warning-soft\){background-color:var(--color-warning-soft)}.bg-\[color-mix\(in_srgb\,var\(--color-fg\)_32\%\,transparent\)\]{background-color:#233c2a52}@supports (color:color-mix(in lab,red,red)){.bg-\[color-mix\(in_srgb\,var\(--color-fg\)_32\%\,transparent\)\]{background-color:color-mix(in srgb,var(--color-fg) 32%,transparent)}}.bg-accent{background-color:var(--color-accent)}.bg-accent\/5{background-color:#bf4a2a0d}@supports (color:color-mix(in lab,red,red)){.bg-accent\/5{background-color:color-mix(in oklab,var(--color-accent) 5%,transparent)}}.bg-accent\/10{background-color:#bf4a2a1a}@supports (color:color-mix(in lab,red,red)){.bg-accent\/10{background-color:color-mix(in oklab,var(--color-accent) 10%,transparent)}}.bg-accent\/15{background-color:#bf4a2a26}@supports (color:color-mix(in lab,red,red)){.bg-accent\/15{background-color:color-mix(in oklab,var(--color-accent) 15%,transparent)}}.bg-accent\/20{background-color:#bf4a2a33}@supports (color:color-mix(in lab,red,red)){.bg-accent\/20{background-color:color-mix(in oklab,var(--color-accent) 20%,transparent)}}.bg-amber-400{background-color:var(--color-amber-400)}.bg-amber-400\/10{background-color:#fcbb001a}@supports (color:color-mix(in lab,red,red)){.bg-amber-400\/10{background-color:color-mix(in oklab,var(--color-amber-400) 10%,transparent)}}.bg-amber-500\/5{background-color:#f99c000d}@supports (color:color-mix(in lab,red,red)){.bg-amber-500\/5{background-color:color-mix(in oklab,var(--color-amber-500) 5%,transparent)}}.bg-amber-500\/10{background-color:#f99c001a}@supports (color:color-mix(in lab,red,red)){.bg-amber-500\/10{background-color:color-mix(in oklab,var(--color-amber-500) 10%,transparent)}}.bg-bg{background-color:var(--color-bg)}.bg-bg-soft{background-color:var(--color-bg-soft)}.bg-bg-soft\/60{background-color:#f7f5ec99}@supports (color:color-mix(in lab,red,red)){.bg-bg-soft\/60{background-color:color-mix(in oklab,var(--color-bg-soft) 60%,transparent)}}.bg-bg-soft\/90{background-color:#f7f5ece6}@supports (color:color-mix(in lab,red,red)){.bg-bg-soft\/90{background-color:color-mix(in oklab,var(--color-bg-soft) 90%,transparent)}}.bg-bg\/40{background-color:#fafaf666}@supports (color:color-mix(in lab,red,red)){.bg-bg\/40{background-color:color-mix(in oklab,var(--color-bg) 40%,transparent)}}.bg-bg\/60{background-color:#fafaf699}@supports (color:color-mix(in lab,red,red)){.bg-bg\/60{background-color:color-mix(in oklab,var(--color-bg) 60%,transparent)}}.bg-bg\/80{background-color:#fafaf6cc}@supports (color:color-mix(in lab,red,red)){.bg-bg\/80{background-color:color-mix(in oklab,var(--color-bg) 80%,transparent)}}.bg-bg\/90{background-color:#fafaf6e6}@supports (color:color-mix(in lab,red,red)){.bg-bg\/90{background-color:color-mix(in oklab,var(--color-bg) 90%,transparent)}}.bg-bg\/95{background-color:#fafaf6f2}@supports (color:color-mix(in lab,red,red)){.bg-bg\/95{background-color:color-mix(in oklab,var(--color-bg) 95%,transparent)}}.bg-black\/40{background-color:#0006}@supports (color:color-mix(in lab,red,red)){.bg-black\/40{background-color:color-mix(in oklab,var(--color-black) 40%,transparent)}}.bg-black\/60{background-color:#0009}@supports (color:color-mix(in lab,red,red)){.bg-black\/60{background-color:color-mix(in oklab,var(--color-black) 60%,transparent)}}.bg-border{background-color:var(--color-border)}.bg-border-light{background-color:var(--color-border-light)}.bg-border\/40{background-color:#d6e2d666}@supports (color:color-mix(in lab,red,red)){.bg-border\/40{background-color:color-mix(in oklab,var(--color-border) 40%,transparent)}}.bg-card{background-color:var(--color-card)}.bg-card\/30{background-color:#fefefa4d}@supports (color:color-mix(in lab,red,red)){.bg-card\/30{background-color:color-mix(in oklab,var(--color-card) 30%,transparent)}}.bg-card\/40{background-color:#fefefa66}@supports (color:color-mix(in lab,red,red)){.bg-card\/40{background-color:color-mix(in oklab,var(--color-card) 40%,transparent)}}.bg-card\/50{background-color:#fefefa80}@supports (color:color-mix(in lab,red,red)){.bg-card\/50{background-color:color-mix(in oklab,var(--color-card) 50%,transparent)}}.bg-card\/60{background-color:#fefefa99}@supports (color:color-mix(in lab,red,red)){.bg-card\/60{background-color:color-mix(in oklab,var(--color-card) 60%,transparent)}}.bg-card\/90{background-color:#fefefae6}@supports (color:color-mix(in lab,red,red)){.bg-card\/90{background-color:color-mix(in oklab,var(--color-card) 90%,transparent)}}.bg-coral-soft{background-color:var(--color-coral-soft)}.bg-danger-soft{background-color:var(--color-danger-soft)}.bg-fg{background-color:var(--color-fg)}.bg-grass-soft{background-color:var(--color-grass-soft)}.bg-positive-soft{background-color:var(--color-positive-soft)}.bg-red-500\/5{background-color:#fb2c360d}@supports (color:color-mix(in lab,red,red)){.bg-red-500\/5{background-color:color-mix(in oklab,var(--color-red-500) 5%,transparent)}}.bg-red-500\/10{background-color:#fb2c361a}@supports (color:color-mix(in lab,red,red)){.bg-red-500\/10{background-color:color-mix(in oklab,var(--color-red-500) 10%,transparent)}}.bg-red-500\/20{background-color:#fb2c3633}@supports (color:color-mix(in lab,red,red)){.bg-red-500\/20{background-color:color-mix(in oklab,var(--color-red-500) 20%,transparent)}}.bg-red-500\/30{background-color:#fb2c364d}@supports (color:color-mix(in lab,red,red)){.bg-red-500\/30{background-color:color-mix(in oklab,var(--color-red-500) 30%,transparent)}}.bg-sage{background-color:var(--color-sage)}.bg-sky-400{background-color:var(--color-sky-400)}.bg-sky-500\/5{background-color:#00a5ef0d}@supports (color:color-mix(in lab,red,red)){.bg-sky-500\/5{background-color:color-mix(in oklab,var(--color-sky-500) 5%,transparent)}}.bg-sun-soft{background-color:var(--color-sun-soft)}.bg-transparent{background-color:#0000}.bg-warning-soft{background-color:var(--color-warning-soft)}.object-cover{object-fit:cover}.p-0{padding:0}.p-0\.5{padding:calc(var(--spacing) * .5)}.p-1{padding:var(--spacing)}.p-1\.5{padding:calc(var(--spacing) * 1.5)}.p-2{padding:calc(var(--spacing) * 2)}.p-3{padding:calc(var(--spacing) * 3)}.p-4{padding:calc(var(--spacing) * 4)}.p-5{padding:calc(var(--spacing) * 5)}.p-6{padding:calc(var(--spacing) * 6)}.p-8{padding:calc(var(--spacing) * 8)}.p-10{padding:calc(var(--spacing) * 10)}.px-0{padding-inline:0}.px-1{padding-inline:var(--spacing)}.px-1\.5{padding-inline:calc(var(--spacing) * 1.5)}.px-2{padding-inline:calc(var(--spacing) * 2)}.px-2\.5{padding-inline:calc(var(--spacing) * 2.5)}.px-3{padding-inline:calc(var(--spacing) * 3)}.px-3\.5{padding-inline:calc(var(--spacing) * 3.5)}.px-4{padding-inline:calc(var(--spacing) * 4)}.px-5{padding-inline:calc(var(--spacing) * 5)}.px-6{padding-inline:calc(var(--spacing) * 6)}.py-0\.5{padding-block:calc(var(--spacing) * .5)}.py-1{padding-block:var(--spacing)}.py-1\.5{padding-block:calc(var(--spacing) * 1.5)}.py-2{padding-block:calc(var(--spacing) * 2)}.py-2\.5{padding-block:calc(var(--spacing) * 2.5)}.py-3{padding-block:calc(var(--spacing) * 3)}.py-4{padding-block:calc(var(--spacing) * 4)}.py-6{padding-block:calc(var(--spacing) * 6)}.py-10{padding-block:calc(var(--spacing) * 10)}.pt-0\.5{padding-top:calc(var(--spacing) * .5)}.pt-1{padding-top:var(--spacing)}.pt-1\.5{padding-top:calc(var(--spacing) * 1.5)}.pt-2{padding-top:calc(var(--spacing) * 2)}.pt-2\.5{padding-top:calc(var(--spacing) * 2.5)}.pt-3{padding-top:calc(var(--spacing) * 3)}.pt-4{padding-top:calc(var(--spacing) * 4)}.pt-6{padding-top:calc(var(--spacing) * 6)}.pt-\[max\(0\.75rem\,env\(safe-area-inset-top\)\)\]{padding-top:max(.75rem,env(safe-area-inset-top))}.pr-1{padding-right:var(--spacing)}.pb-0\.5{padding-bottom:calc(var(--spacing) * .5)}.pb-1{padding-bottom:var(--spacing)}.pb-1\.5{padding-bottom:calc(var(--spacing) * 1.5)}.pb-2{padding-bottom:calc(var(--spacing) * 2)}.pb-2\.5{padding-bottom:calc(var(--spacing) * 2.5)}.pb-3{padding-bottom:calc(var(--spacing) * 3)}.pb-5{padding-bottom:calc(var(--spacing) * 5)}.pb-16{padding-bottom:calc(var(--spacing) * 16)}.pb-20{padding-bottom:calc(var(--spacing) * 20)}.pb-\[calc\(0\.75rem\+env\(safe-area-inset-bottom\)\)\]{padding-bottom:calc(.75rem + env(safe-area-inset-bottom))}.pb-\[calc\(0\.375rem\+env\(safe-area-inset-bottom\)\)\]{padding-bottom:calc(.375rem + env(safe-area-inset-bottom))}.pb-\[calc\(1rem\+env\(safe-area-inset-bottom\)\)\]{padding-bottom:calc(1rem + env(safe-area-inset-bottom))}.pl-1{padding-left:var(--spacing)}.pl-2{padding-left:calc(var(--spacing) * 2)}.pl-4{padding-left:calc(var(--spacing) * 4)}.pl-5{padding-left:calc(var(--spacing) * 5)}.pl-11{padding-left:calc(var(--spacing) * 11)}.text-center{text-align:center}.text-left{text-align:left}.text-right{text-align:right}.align-middle{vertical-align:middle}.font-mono{font-family:var(--font-mono)}.font-round{font-family:var(--font-round)}.font-sans{font-family:var(--font-sans)}.font-serif{font-family:var(--font-serif)}.text-2xl{font-size:var(--text-2xl);line-height:var(--tw-leading,var(--text-2xl--line-height))}.text-3xl{font-size:var(--text-3xl);line-height:var(--tw-leading,var(--text-3xl--line-height))}.text-base{font-size:var(--text-base);line-height:var(--tw-leading,var(--text-base--line-height))}.text-lg{font-size:var(--text-lg);line-height:var(--tw-leading,var(--text-lg--line-height))}.text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.text-xl{font-size:var(--text-xl);line-height:var(--tw-leading,var(--text-xl--line-height))}.text-xs{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}.text-2xs{font-size:var(--text-2xs)}.text-\[0\.6875rem\]{font-size:.6875rem}.text-\[10px\]{font-size:10px}.leading-none{--tw-leading:1;line-height:1}.leading-relaxed{--tw-leading:var(--leading-relaxed);line-height:var(--leading-relaxed)}.leading-snug{--tw-leading:var(--leading-snug);line-height:var(--leading-snug)}.leading-tight{--tw-leading:var(--leading-tight);line-height:var(--leading-tight)}.font-bold{--tw-font-weight:var(--font-weight-bold);font-weight:var(--font-weight-bold)}.font-medium{--tw-font-weight:var(--font-weight-medium);font-weight:var(--font-weight-medium)}.font-normal{--tw-font-weight:var(--font-weight-normal);font-weight:var(--font-weight-normal)}.font-semibold{--tw-font-weight:var(--font-weight-semibold);font-weight:var(--font-weight-semibold)}.tracking-\[0\.4em\]{--tw-tracking:.4em;letter-spacing:.4em}.tracking-\[0\.08em\]{--tw-tracking:.08em;letter-spacing:.08em}.tracking-normal{--tw-tracking:var(--tracking-normal);letter-spacing:var(--tracking-normal)}.tracking-tight{--tw-tracking:var(--tracking-tight);letter-spacing:var(--tracking-tight)}.tracking-wider{--tw-tracking:var(--tracking-wider);letter-spacing:var(--tracking-wider)}.break-words{overflow-wrap:break-word}.break-all{word-break:break-all}.whitespace-nowrap{white-space:nowrap}.whitespace-pre-wrap{white-space:pre-wrap}.text-\(--color-danger\){color:var(--color-danger)}.text-\(--color-on-accent\){color:var(--color-on-accent)}.text-accent{color:var(--color-accent)}.text-amber-100{color:var(--color-amber-100)}.text-amber-100\/70{color:#fef3c6b3}@supports (color:color-mix(in lab,red,red)){.text-amber-100\/70{color:color-mix(in oklab,var(--color-amber-100) 70%,transparent)}}.text-amber-100\/90{color:#fef3c6e6}@supports (color:color-mix(in lab,red,red)){.text-amber-100\/90{color:color-mix(in oklab,var(--color-amber-100) 90%,transparent)}}.text-amber-200{color:var(--color-amber-200)}.text-amber-300{color:var(--color-amber-300)}.text-amber-500{color:var(--color-amber-500)}.text-bg{color:var(--color-bg)}.text-coral-ink{color:var(--color-coral-ink)}.text-danger{color:var(--color-danger)}.text-fg{color:var(--color-fg)}.text-fg-dim{color:var(--color-fg-dim)}.text-fg-muted{color:var(--color-fg-muted)}.text-grass{color:var(--color-grass)}.text-grass-ink{color:var(--color-grass-ink)}.text-on-accent{color:var(--color-on-accent)}.text-positive{color:var(--color-positive)}.text-red-50{color:var(--color-red-50)}.text-red-100{color:var(--color-red-100)}.text-red-200{color:var(--color-red-200)}.text-red-200\/80{color:#ffcacacc}@supports (color:color-mix(in lab,red,red)){.text-red-200\/80{color:color-mix(in oklab,var(--color-red-200) 80%,transparent)}}.text-red-300{color:var(--color-red-300)}.text-red-400{color:var(--color-red-400)}.text-sky-300{color:var(--color-sky-300)}.text-sky-300\/80{color:#77d4ffcc}@supports (color:color-mix(in lab,red,red)){.text-sky-300\/80{color:color-mix(in oklab,var(--color-sky-300) 80%,transparent)}}.text-sun-ink{color:var(--color-sun-ink)}.text-sun-ink\/70{color:#6b5200b3}@supports (color:color-mix(in lab,red,red)){.text-sun-ink\/70{color:color-mix(in oklab,var(--color-sun-ink) 70%,transparent)}}.text-warning{color:var(--color-warning)}.capitalize{text-transform:capitalize}.lowercase{text-transform:lowercase}.normal-case{text-transform:none}.uppercase{text-transform:uppercase}.italic{font-style:italic}.not-italic{font-style:normal}.tabular-nums{--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal,) var(--tw-slashed-zero,) var(--tw-numeric-figure,) var(--tw-numeric-spacing,) var(--tw-numeric-fraction,)}.line-through{text-decoration-line:line-through}.underline{text-decoration-line:underline}.decoration-dashed{text-decoration-style:dashed}.underline-offset-2{text-underline-offset:2px}.underline-offset-4{text-underline-offset:4px}.accent-accent{accent-color:var(--color-accent)}.opacity-40{opacity:.4}.opacity-50{opacity:.5}.opacity-60{opacity:.6}.opacity-70{opacity:.7}.opacity-80{opacity:.8}.shadow{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a), 0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-lg{--tw-shadow:0 8px 24px var(--tw-shadow-color,#24422e1f), 0 2px 6px var(--tw-shadow-color,#24422e0f);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-lift{--tw-shadow:0 24px 60px -30px var(--tw-shadow-color,oklch(40% .05 152/.28));box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-md{--tw-shadow:0 2px 8px var(--tw-shadow-color,#24422e14), 0 1px 2px var(--tw-shadow-color,#24422e0d);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-sm{--tw-shadow:0 1px 2px var(--tw-shadow-color,#24422e0f);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-soft{--tw-shadow:0 12px 40px -18px var(--tw-shadow-color,oklch(40% .05 152/.22));box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.ring-2{--tw-ring-shadow:var(--tw-ring-inset,) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.ring-\(--color-card\){--tw-ring-color:var(--color-card)}.outline{outline-style:var(--tw-outline-style);outline-width:1px}.outline-2{outline-style:var(--tw-outline-style);outline-width:2px}.-outline-offset-2{outline-offset:-2px}.outline-offset-2{outline-offset:2px}.outline-accent{outline-color:var(--color-accent)}.outline-accent\/50{outline-color:#bf4a2a80}@supports (color:color-mix(in lab,red,red)){.outline-accent\/50{outline-color:color-mix(in oklab,var(--color-accent) 50%,transparent)}}.outline-accent\/60{outline-color:#bf4a2a99}@supports (color:color-mix(in lab,red,red)){.outline-accent\/60{outline-color:color-mix(in oklab,var(--color-accent) 60%,transparent)}}.blur{--tw-blur:blur(8px);filter:var(--tw-blur,) var(--tw-brightness,) var(--tw-contrast,) var(--tw-grayscale,) var(--tw-hue-rotate,) var(--tw-invert,) var(--tw-saturate,) var(--tw-sepia,) var(--tw-drop-shadow,)}.filter{filter:var(--tw-blur,) var(--tw-brightness,) var(--tw-contrast,) var(--tw-grayscale,) var(--tw-hue-rotate,) var(--tw-invert,) var(--tw-saturate,) var(--tw-sepia,) var(--tw-drop-shadow,)}.backdrop-blur{--tw-backdrop-blur:blur(8px);-webkit-backdrop-filter:var(--tw-backdrop-blur,) var(--tw-backdrop-brightness,) var(--tw-backdrop-contrast,) var(--tw-backdrop-grayscale,) var(--tw-backdrop-hue-rotate,) var(--tw-backdrop-invert,) var(--tw-backdrop-opacity,) var(--tw-backdrop-saturate,) var(--tw-backdrop-sepia,);backdrop-filter:var(--tw-backdrop-blur,) var(--tw-backdrop-brightness,) var(--tw-backdrop-contrast,) var(--tw-backdrop-grayscale,) var(--tw-backdrop-hue-rotate,) var(--tw-backdrop-invert,) var(--tw-backdrop-opacity,) var(--tw-backdrop-saturate,) var(--tw-backdrop-sepia,)}.backdrop-blur-\[3px\]{--tw-backdrop-blur:blur(3px);-webkit-backdrop-filter:var(--tw-backdrop-blur,) var(--tw-backdrop-brightness,) var(--tw-backdrop-contrast,) var(--tw-backdrop-grayscale,) var(--tw-backdrop-hue-rotate,) var(--tw-backdrop-invert,) var(--tw-backdrop-opacity,) var(--tw-backdrop-saturate,) var(--tw-backdrop-sepia,);backdrop-filter:var(--tw-backdrop-blur,) var(--tw-backdrop-brightness,) var(--tw-backdrop-contrast,) var(--tw-backdrop-grayscale,) var(--tw-backdrop-hue-rotate,) var(--tw-backdrop-invert,) var(--tw-backdrop-opacity,) var(--tw-backdrop-saturate,) var(--tw-backdrop-sepia,)}.backdrop-blur-md{--tw-backdrop-blur:blur(var(--blur-md));-webkit-backdrop-filter:var(--tw-backdrop-blur,) var(--tw-backdrop-brightness,) var(--tw-backdrop-contrast,) var(--tw-backdrop-grayscale,) var(--tw-backdrop-hue-rotate,) var(--tw-backdrop-invert,) var(--tw-backdrop-opacity,) var(--tw-backdrop-saturate,) var(--tw-backdrop-sepia,);backdrop-filter:var(--tw-backdrop-blur,) var(--tw-backdrop-brightness,) var(--tw-backdrop-contrast,) var(--tw-backdrop-grayscale,) var(--tw-backdrop-hue-rotate,) var(--tw-backdrop-invert,) var(--tw-backdrop-opacity,) var(--tw-backdrop-saturate,) var(--tw-backdrop-sepia,)}.backdrop-filter{-webkit-backdrop-filter:var(--tw-backdrop-blur,) var(--tw-backdrop-brightness,) var(--tw-backdrop-contrast,) var(--tw-backdrop-grayscale,) var(--tw-backdrop-hue-rotate,) var(--tw-backdrop-invert,) var(--tw-backdrop-opacity,) var(--tw-backdrop-saturate,) var(--tw-backdrop-sepia,);backdrop-filter:var(--tw-backdrop-blur,) var(--tw-backdrop-brightness,) var(--tw-backdrop-contrast,) var(--tw-backdrop-grayscale,) var(--tw-backdrop-hue-rotate,) var(--tw-backdrop-invert,) var(--tw-backdrop-opacity,) var(--tw-backdrop-saturate,) var(--tw-backdrop-sepia,)}.transition{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter,display,content-visibility,overlay,pointer-events;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-\[width\]{transition-property:width;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-all{transition-property:all;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-opacity{transition-property:opacity;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-shadow{transition-property:box-shadow;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-transform{transition-property:transform,translate,scale,rotate;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.duration-\(--dur-move\){--tw-duration:var(--dur-move);transition-duration:var(--dur-move)}.duration-\(--dur-quick\){--tw-duration:var(--dur-quick);transition-duration:var(--dur-quick)}.ease-out{--tw-ease:var(--ease-out);transition-timing-function:var(--ease-out)}.outline-none{--tw-outline-style:none;outline-style:none}.select-none{-webkit-user-select:none;user-select:none}.\[transition\:min-height_var\(--dur-move\)_ease\]{transition:min-height var(--dur-move) ease}.group-open\:rotate-90:is(:where(.group):is([open],:popover-open,:open) *){rotate:90deg}@media(hover:hover){.group-hover\:scale-105:is(:where(.group):hover *){--tw-scale-x:105%;--tw-scale-y:105%;--tw-scale-z:105%;scale:var(--tw-scale-x) var(--tw-scale-y)}.group-hover\:border-accent\/50:is(:where(.group):hover *){border-color:#bf4a2a80}@supports (color:color-mix(in lab,red,red)){.group-hover\:border-accent\/50:is(:where(.group):hover *){border-color:color-mix(in oklab,var(--color-accent) 50%,transparent)}}.group-hover\:opacity-100:is(:where(.group):hover *){opacity:1}}.placeholder\:text-fg-dim::placeholder{color:var(--color-fg-dim)}.after\:pointer-events-none:after{content:var(--tw-content);pointer-events:none}.after\:absolute:after{content:var(--tw-content);position:absolute}.after\:inset-0:after{content:var(--tw-content);top:0;right:0;bottom:0;left:0}.after\:-z-10:after{content:var(--tw-content);z-index:-10}.after\:bg-bg-soft\/60:after{content:var(--tw-content);background-color:#f7f5ec99}@supports (color:color-mix(in lab,red,red)){.after\:bg-bg-soft\/60:after{background-color:color-mix(in oklab,var(--color-bg-soft) 60%,transparent)}}.after\:opacity-0:after{content:var(--tw-content);opacity:0}@media(hover:hover){.group-hover\:after\:opacity-100:is(:where(.group):hover *):after{content:var(--tw-content);opacity:1}}.first\:rounded-t-xl:first-child{border-top-left-radius:var(--radius-xl);border-top-right-radius:var(--radius-xl)}.last\:rounded-b-xl:last-child{border-bottom-right-radius:var(--radius-xl);border-bottom-left-radius:var(--radius-xl)}.last\:border-b-0:last-child{border-bottom-style:var(--tw-border-style);border-bottom-width:0}.focus-within\:shadow-lift:focus-within{--tw-shadow:0 24px 60px -30px var(--tw-shadow-color,oklch(40% .05 152/.28));box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}@media(hover:hover){.hover\:scale-105:hover{--tw-scale-x:105%;--tw-scale-y:105%;--tw-scale-z:105%;scale:var(--tw-scale-x) var(--tw-scale-y)}.hover\:border-accent:hover{border-color:var(--color-accent)}.hover\:border-accent\/40:hover{border-color:#bf4a2a66}@supports (color:color-mix(in lab,red,red)){.hover\:border-accent\/40:hover{border-color:color-mix(in oklab,var(--color-accent) 40%,transparent)}}.hover\:border-accent\/50:hover{border-color:#bf4a2a80}@supports (color:color-mix(in lab,red,red)){.hover\:border-accent\/50:hover{border-color:color-mix(in oklab,var(--color-accent) 50%,transparent)}}.hover\:border-red-500\/40:hover{border-color:#fb2c3666}@supports (color:color-mix(in lab,red,red)){.hover\:border-red-500\/40:hover{border-color:color-mix(in oklab,var(--color-red-500) 40%,transparent)}}.hover\:bg-accent-hover:hover{background-color:var(--color-accent-hover)}.hover\:bg-accent\/10:hover{background-color:#bf4a2a1a}@supports (color:color-mix(in lab,red,red)){.hover\:bg-accent\/10:hover{background-color:color-mix(in oklab,var(--color-accent) 10%,transparent)}}.hover\:bg-accent\/15:hover{background-color:#bf4a2a26}@supports (color:color-mix(in lab,red,red)){.hover\:bg-accent\/15:hover{background-color:color-mix(in oklab,var(--color-accent) 15%,transparent)}}.hover\:bg-accent\/20:hover{background-color:#bf4a2a33}@supports (color:color-mix(in lab,red,red)){.hover\:bg-accent\/20:hover{background-color:color-mix(in oklab,var(--color-accent) 20%,transparent)}}.hover\:bg-amber-500\/15:hover{background-color:#f99c0026}@supports (color:color-mix(in lab,red,red)){.hover\:bg-amber-500\/15:hover{background-color:color-mix(in oklab,var(--color-amber-500) 15%,transparent)}}.hover\:bg-amber-500\/20:hover{background-color:#f99c0033}@supports (color:color-mix(in lab,red,red)){.hover\:bg-amber-500\/20:hover{background-color:color-mix(in oklab,var(--color-amber-500) 20%,transparent)}}.hover\:bg-bg:hover{background-color:var(--color-bg)}.hover\:bg-bg-soft:hover{background-color:var(--color-bg-soft)}.hover\:bg-bg-soft\/60:hover{background-color:#f7f5ec99}@supports (color:color-mix(in lab,red,red)){.hover\:bg-bg-soft\/60:hover{background-color:color-mix(in oklab,var(--color-bg-soft) 60%,transparent)}}.hover\:bg-bg\/50:hover{background-color:#fafaf680}@supports (color:color-mix(in lab,red,red)){.hover\:bg-bg\/50:hover{background-color:color-mix(in oklab,var(--color-bg) 50%,transparent)}}.hover\:bg-bg\/60:hover{background-color:#fafaf699}@supports (color:color-mix(in lab,red,red)){.hover\:bg-bg\/60:hover{background-color:color-mix(in oklab,var(--color-bg) 60%,transparent)}}.hover\:bg-red-500\/10:hover{background-color:#fb2c361a}@supports (color:color-mix(in lab,red,red)){.hover\:bg-red-500\/10:hover{background-color:color-mix(in oklab,var(--color-red-500) 10%,transparent)}}.hover\:bg-red-500\/40:hover{background-color:#fb2c3666}@supports (color:color-mix(in lab,red,red)){.hover\:bg-red-500\/40:hover{background-color:color-mix(in oklab,var(--color-red-500) 40%,transparent)}}.hover\:bg-red-500\/50:hover{background-color:#fb2c3680}@supports (color:color-mix(in lab,red,red)){.hover\:bg-red-500\/50:hover{background-color:color-mix(in oklab,var(--color-red-500) 50%,transparent)}}.hover\:text-accent:hover{color:var(--color-accent)}.hover\:text-accent-hover:hover{color:var(--color-accent-hover)}.hover\:text-danger:hover{color:var(--color-danger)}.hover\:text-danger-hover:hover{color:var(--color-danger-hover)}.hover\:text-fg:hover{color:var(--color-fg)}.hover\:text-fg-muted:hover{color:var(--color-fg-muted)}.hover\:text-red-100:hover{color:var(--color-red-100)}.hover\:text-red-400:hover{color:var(--color-red-400)}.hover\:text-sun-ink:hover{color:var(--color-sun-ink)}.hover\:underline:hover{text-decoration-line:underline}.hover\:shadow-md:hover{--tw-shadow:0 2px 8px var(--tw-shadow-color,#24422e14), 0 1px 2px var(--tw-shadow-color,#24422e0d);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}}.focus\:border-accent:focus{border-color:var(--color-accent)}.focus\:border-accent-light:focus{border-color:var(--color-accent-light)}.focus\:border-border:focus{border-color:var(--color-border)}.focus\:border-red-400:focus{border-color:var(--color-red-400)}.focus\:bg-bg\/60:focus{background-color:#fafaf699}@supports (color:color-mix(in lab,red,red)){.focus\:bg-bg\/60:focus{background-color:color-mix(in oklab,var(--color-bg) 60%,transparent)}}.focus\:text-fg:focus{color:var(--color-fg)}.focus\:outline-none:focus{--tw-outline-style:none;outline-style:none}.focus-visible\:outline-2:focus-visible{outline-style:var(--tw-outline-style);outline-width:2px}.focus-visible\:outline-accent:focus-visible{outline-color:var(--color-accent)}.disabled\:cursor-not-allowed:disabled{cursor:not-allowed}.disabled\:opacity-30:disabled{opacity:.3}.disabled\:opacity-40:disabled{opacity:.4}.disabled\:opacity-50:disabled{opacity:.5}.disabled\:opacity-60:disabled{opacity:.6}@media(prefers-reduced-motion:reduce){@media(hover:hover){.motion-reduce\:group-hover\:scale-100:is(:where(.group):hover *),.motion-reduce\:hover\:scale-100:hover{--tw-scale-x:100%;--tw-scale-y:100%;--tw-scale-z:100%;scale:var(--tw-scale-x) var(--tw-scale-y)}}}@media not all and (min-width:820px){.max-\[820px\]\:flex{display:flex}}@media(min-width:900px){.min-\[900px\]\:flex{display:flex}.min-\[900px\]\:hidden{display:none}}@media(min-width:40rem){.sm\:absolute{position:absolute}.sm\:top-full{top:100%}.sm\:right-0{right:0}.sm\:right-auto{right:auto}.sm\:bottom-auto{bottom:auto}.sm\:left-auto{left:auto}.sm\:mt-1{margin-top:var(--spacing)}.sm\:flex{display:flex}.sm\:inline{display:inline}.sm\:max-h-80{max-height:calc(var(--spacing) * 80)}.sm\:max-h-\[30rem\]{max-height:30rem}.sm\:w-56{width:calc(var(--spacing) * 56)}.sm\:w-60{width:calc(var(--spacing) * 60)}.sm\:w-\[26rem\]{width:26rem}.sm\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.sm\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.sm\:rounded-b-\[var\(--radius-2xl\)\]{border-bottom-right-radius:var(--radius-2xl);border-bottom-left-radius:var(--radius-2xl)}.sm\:bg-transparent{background-color:#0000}.sm\:px-10{padding-inline:calc(var(--spacing) * 10)}.sm\:pb-1\.5{padding-bottom:calc(var(--spacing) * 1.5)}.sm\:pb-4{padding-bottom:calc(var(--spacing) * 4)}}@media(min-width:48rem){.md\:sticky{position:sticky}.md\:top-6{top:calc(var(--spacing) * 6)}.md\:right-6{right:calc(var(--spacing) * 6)}.md\:bottom-0{bottom:0}.md\:bottom-6{bottom:calc(var(--spacing) * 6)}.md\:-mx-8{margin-inline:calc(var(--spacing) * -8)}.md\:mb-6{margin-bottom:calc(var(--spacing) * 6)}.md\:block{display:block}.md\:flex{display:flex}.md\:hidden{display:none}.md\:min-h-0{min-height:0}.md\:flex-row{flex-direction:row}.md\:items-center{align-items:center}.md\:justify-between{justify-content:space-between}.md\:self-auto{align-self:auto}.md\:self-start{align-self:flex-start}.md\:p-6{padding:calc(var(--spacing) * 6)}.md\:p-8{padding:calc(var(--spacing) * 8)}.md\:px-6{padding-inline:calc(var(--spacing) * 6)}.md\:px-8{padding-inline:calc(var(--spacing) * 8)}.md\:px-10{padding-inline:calc(var(--spacing) * 10)}.md\:py-10{padding-block:calc(var(--spacing) * 10)}.md\:pb-0{padding-bottom:0}.md\:pb-\[env\(safe-area-inset-bottom\)\]{padding-bottom:env(safe-area-inset-bottom)}.md\:text-3xl{font-size:var(--text-3xl);line-height:var(--tw-leading,var(--text-3xl--line-height))}}@media(min-width:64rem){.lg\:sticky{position:sticky}.lg\:top-24{top:calc(var(--spacing) * 24)}.lg\:mx-auto{margin-inline:auto}.lg\:mb-3{margin-bottom:calc(var(--spacing) * 3)}.lg\:block{display:block}.lg\:flex{display:flex}.lg\:hidden{display:none}.lg\:h-\[60dvh\]{height:60dvh}.lg\:h-auto{height:auto}.lg\:max-h-\[50vh\]{max-height:50vh}.lg\:max-h-\[55vh\]{max-height:55vh}.lg\:min-h-0{min-height:0}.lg\:w-full{width:100%}.lg\:max-w-xl{max-width:var(--container-xl)}.lg\:flex-none{flex:none}.lg\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.lg\:grid-cols-\[minmax\(0\,1fr\)_18rem\]{grid-template-columns:minmax(0,1fr) 18rem}.lg\:flex-col-reverse{flex-direction:column-reverse}.lg\:self-end{align-self:flex-end}.lg\:self-start{align-self:flex-start}.lg\:rounded-\[var\(--radius-2xl\)\]{border-radius:var(--radius-2xl)}.lg\:border{border-style:var(--tw-border-style);border-width:1px}.lg\:border-border{border-color:var(--color-border)}.lg\:bg-transparent{background-color:#0000}.lg\:p-0{padding:0}.lg\:px-5{padding-inline:calc(var(--spacing) * 5)}.lg\:px-6{padding-inline:calc(var(--spacing) * 6)}.lg\:py-3{padding-block:calc(var(--spacing) * 3)}.lg\:pb-8{padding-bottom:calc(var(--spacing) * 8)}.lg\:shadow-lift{--tw-shadow:0 24px 60px -30px var(--tw-shadow-color,oklch(40% .05 152/.28));box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.lg\:backdrop-blur-none{--tw-backdrop-blur: ;-webkit-backdrop-filter:var(--tw-backdrop-blur,) var(--tw-backdrop-brightness,) var(--tw-backdrop-contrast,) var(--tw-backdrop-grayscale,) var(--tw-backdrop-hue-rotate,) var(--tw-backdrop-invert,) var(--tw-backdrop-opacity,) var(--tw-backdrop-saturate,) var(--tw-backdrop-sepia,);backdrop-filter:var(--tw-backdrop-blur,) var(--tw-backdrop-brightness,) var(--tw-backdrop-contrast,) var(--tw-backdrop-grayscale,) var(--tw-backdrop-hue-rotate,) var(--tw-backdrop-invert,) var(--tw-backdrop-opacity,) var(--tw-backdrop-saturate,) var(--tw-backdrop-sepia,)}}}pre code.hljs{padding:1em;display:block;overflow-x:auto}code.hljs{padding:3px 5px}.hljs{color:#24292e;background:#fff}.hljs-doctag,.hljs-keyword,.hljs-meta .hljs-keyword,.hljs-template-tag,.hljs-template-variable,.hljs-type,.hljs-variable.language_{color:#d73a49}.hljs-title,.hljs-title.class_,.hljs-title.class_.inherited__,.hljs-title.function_{color:#6f42c1}.hljs-attr,.hljs-attribute,.hljs-literal,.hljs-meta,.hljs-number,.hljs-operator,.hljs-variable,.hljs-selector-attr,.hljs-selector-class,.hljs-selector-id{color:#005cc5}.hljs-regexp,.hljs-string,.hljs-meta .hljs-string{color:#032f62}.hljs-built_in,.hljs-symbol{color:#e36209}.hljs-comment,.hljs-code,.hljs-formula{color:#6a737d}.hljs-name,.hljs-quote,.hljs-selector-tag,.hljs-selector-pseudo{color:#22863a}.hljs-subst{color:#24292e}.hljs-section{color:#005cc5;font-weight:700}.hljs-bullet{color:#735c0f}.hljs-emphasis{color:#24292e;font-style:italic}.hljs-strong{color:#24292e;font-weight:700}.hljs-addition{color:#22863a;background-color:#f0fff4}.hljs-deletion{color:#b31d28;background-color:#ffeef0}:root[data-text-size=larger]{--font-size-prose:22px;--font-size-editor:18px;font-size:18px}:root[data-text-size=largest]{--font-size-prose:26px;--font-size-editor:22px;font-size:22px}:root{--_d-bg:#161d18;--_d-bg-soft:#1c241d;--_d-fg:#e7ece5;--_d-fg-muted:#a7b3a7;--_d-fg-dim:#71806f;--_d-accent:#ec7a5c;--_d-accent-hover:#f08d70;--_d-accent-light:#c95f40;--_d-sky:#7fb3cc;--_d-grass:#6fbf8a;--_d-grass-strong:#4f9d6b;--_d-grass-soft:#1e3527;--_d-grass-ink:#9fd9b3;--_d-sun:#f4c020;--_d-sun-soft:#38300f;--_d-sun-ink:#f0d68a;--_d-sage:#8fb096;--_d-clay:#c98f6c;--_d-ochre:#d9a53d;--_d-plum:#b48fc4;--_d-shadow-ink:#000}@supports (color:color-mix(in lab,red,red)){:root{--_d-shadow-ink:color-mix(in srgb, #000 90%, var(--_d-accent) 10%)}}:root{--_d-shadow-soft:0 10px 30px var(--_d-shadow-ink)}@supports (color:color-mix(in lab,red,red)){:root{--_d-shadow-soft:0 10px 30px color-mix(in srgb, var(--_d-shadow-ink) 42%, transparent)}}:root{--_d-shadow-lift:0 18px 44px var(--_d-shadow-ink)}@supports (color:color-mix(in lab,red,red)){:root{--_d-shadow-lift:0 18px 44px color-mix(in srgb, var(--_d-shadow-ink) 52%, transparent)}}:root{--_d-border:#303b31;--_d-border-light:#283229;--_d-card:#1e271f;--_d-card-hover:#252f26;--_d-canvas-wash:var(--_d-grass)}@supports (color:color-mix(in lab,red,red)){:root{--_d-canvas-wash:color-mix(in srgb, var(--_d-grass) 5%, transparent)}}:root{--_d-canvas-wash-accent:var(--_d-accent)}@supports (color:color-mix(in lab,red,red)){:root{--_d-canvas-wash-accent:color-mix(in srgb, var(--_d-accent) 4%, transparent)}}:root{--_d-on-accent:#2a1710;--_d-coral-soft:#3a221b;--_d-coral-ink:#f2ac92;--_d-danger:#e8836b;--_d-danger-hover:#ef9982;--_d-warning:#fcd34d;--_d-shadow-sm:0 1px 2px var(--_d-shadow-ink)}@supports (color:color-mix(in lab,red,red)){:root{--_d-shadow-sm:0 1px 2px color-mix(in srgb, var(--_d-shadow-ink) 30%, transparent)}}:root{--_d-shadow-md:0 2px 8px var(--_d-shadow-ink), 0 1px 2px var(--_d-shadow-ink)}@supports (color:color-mix(in lab,red,red)){:root{--_d-shadow-md:0 2px 8px color-mix(in srgb, var(--_d-shadow-ink) 40%, transparent), 0 1px 2px color-mix(in srgb, var(--_d-shadow-ink) 25%, transparent)}}:root{--_d-shadow-lg:0 8px 24px var(--_d-shadow-ink), 0 2px 6px var(--_d-shadow-ink)}@supports (color:color-mix(in lab,red,red)){:root{--_d-shadow-lg:0 8px 24px color-mix(in srgb, var(--_d-shadow-ink) 50%, transparent), 0 2px 6px color-mix(in srgb, var(--_d-shadow-ink) 30%, transparent)}}@media(prefers-color-scheme:dark){:root:not([data-theme=light]){--color-bg:var(--_d-bg);--color-bg-soft:var(--_d-bg-soft);--color-fg:var(--_d-fg);--color-fg-muted:var(--_d-fg-muted);--color-fg-dim:var(--_d-fg-dim);--color-accent:var(--_d-accent);--color-accent-hover:var(--_d-accent-hover);--color-accent-light:var(--_d-accent-light);--color-sky:var(--_d-sky);--color-grass:var(--_d-grass);--color-grass-strong:var(--_d-grass-strong);--color-grass-soft:var(--_d-grass-soft);--color-grass-ink:var(--_d-grass-ink);--color-sun:var(--_d-sun);--color-sun-soft:var(--_d-sun-soft);--color-sun-ink:var(--_d-sun-ink);--color-sage:var(--_d-sage);--color-clay:var(--_d-clay);--color-ochre:var(--_d-ochre);--color-plum:var(--_d-plum);--color-border:var(--_d-border);--color-border-light:var(--_d-border-light);--color-card:var(--_d-card);--color-card-hover:var(--_d-card-hover);--color-on-accent:var(--_d-on-accent);--color-coral-soft:var(--_d-coral-soft);--color-coral-ink:var(--_d-coral-ink);--color-danger:var(--_d-danger);--color-danger-hover:var(--_d-danger-hover);--color-warning:var(--_d-warning);--shadow-sm:var(--_d-shadow-sm);--shadow-md:var(--_d-shadow-md);--shadow-lg:var(--_d-shadow-lg);--shadow-soft:var(--_d-shadow-soft);--shadow-lift:var(--_d-shadow-lift);--canvas-wash:var(--_d-canvas-wash);--canvas-wash-accent:var(--_d-canvas-wash-accent)}}:root[data-theme=dark]{--color-bg:var(--_d-bg);--color-bg-soft:var(--_d-bg-soft);--color-fg:var(--_d-fg);--color-fg-muted:var(--_d-fg-muted);--color-fg-dim:var(--_d-fg-dim);--color-accent:var(--_d-accent);--color-accent-hover:var(--_d-accent-hover);--color-accent-light:var(--_d-accent-light);--color-sky:var(--_d-sky);--color-grass:var(--_d-grass);--color-grass-strong:var(--_d-grass-strong);--color-grass-soft:var(--_d-grass-soft);--color-grass-ink:var(--_d-grass-ink);--color-sun:var(--_d-sun);--color-sun-soft:var(--_d-sun-soft);--color-sun-ink:var(--_d-sun-ink);--color-sage:var(--_d-sage);--color-clay:var(--_d-clay);--color-ochre:var(--_d-ochre);--color-plum:var(--_d-plum);--color-border:var(--_d-border);--color-border-light:var(--_d-border-light);--color-card:var(--_d-card);--color-card-hover:var(--_d-card-hover);--color-on-accent:var(--_d-on-accent);--color-coral-soft:var(--_d-coral-soft);--color-coral-ink:var(--_d-coral-ink);--color-danger:var(--_d-danger);--color-danger-hover:var(--_d-danger-hover);--color-warning:var(--_d-warning);--shadow-sm:var(--_d-shadow-sm);--shadow-md:var(--_d-shadow-md);--shadow-lg:var(--_d-shadow-lg);--shadow-soft:var(--_d-shadow-soft);--shadow-lift:var(--_d-shadow-lift);--canvas-wash:var(--_d-canvas-wash);--canvas-wash-accent:var(--_d-canvas-wash-accent)}html,body{font-family:var(--font-sans);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;line-height:1.65}::selection{background-color:#bf4a2a3d}@supports (color:color-mix(in lab,red,red)){::selection{background-color:color-mix(in srgb,var(--color-accent) 24%,transparent)}}body{padding-left:env(safe-area-inset-left);padding-right:env(safe-area-inset-right);padding-bottom:env(safe-area-inset-bottom)}.prose-note{color:var(--color-fg);font-size:var(--font-size-prose);max-width:var(--w-prose);line-height:1.78}.prose-note h1,.prose-note h2,.prose-note h3,.prose-note h4{font-family:var(--font-serif);color:var(--color-fg);letter-spacing:-.015em;margin-top:1.75em;margin-bottom:.5em;line-height:1.25}.prose-note h1{font-size:var(--text-3xl)}.prose-note h2{font-size:var(--text-2xl)}.prose-note h3{font-size:var(--text-xl)}.prose-note h4{font-size:var(--text-lg)}.prose-note p{text-wrap:pretty;margin:.75em 0}.prose-note p:has(br){line-height:var(--lh-prose-tight)}.external-link:after{content:"↗" / "";vertical-align:text-top;white-space:nowrap;margin-left:.15em;font-size:.75em;display:inline-block}.prose-note ul,.prose-note ol{margin:.75em 0;padding-left:1.5rem}.prose-note ul{list-style:outside}.prose-note ol{list-style:decimal}.prose-note li,.prose-note li>p{margin:.25em 0}.prose-note blockquote{border-left:3px solid var(--color-border);color:var(--color-fg-muted);margin:1em 0;padding-left:1rem;font-style:italic}.prose-note code{font-family:var(--font-mono);background:var(--color-bg-soft);border-radius:var(--radius-xs);padding:.1em .35em;font-size:.875em}.prose-note pre{background:var(--color-bg-soft);border:1px solid var(--color-border);border-radius:var(--radius-md);margin:1em 0;padding:.9rem 1rem;font-size:.875em;line-height:1.5;overflow-x:auto}.prose-note pre code{font-size:inherit;background:0 0;border-radius:0;padding:0}.prose-note table{border-collapse:collapse;width:max-content;max-width:100%;margin:1em 0;font-size:.9em;display:block;overflow-x:auto}.prose-note th,.prose-note td{border:1px solid var(--color-border);text-align:left;padding:.5rem .75rem}.prose-note th{background:var(--color-bg-soft);font-weight:500}.prose-note hr{border:0;border-top:1px solid var(--color-border);margin:1.5em 0}.prose-note img{border-radius:var(--radius-md);max-width:100%;height:auto}.prose-note input[type=checkbox]{margin-right:.4em}.prose-note li.task-list-item{list-style:none}.csv-scroll{overflow-x:auto}.csv-warning{border:1px solid var(--color-warning);background:var(--color-warning-soft);border-radius:var(--radius-sm);font-size:var(--text-sm);color:var(--color-warning);margin-bottom:.5rem;padding:.5rem .75rem}.vault-media-error{font-size:var(--text-xs);color:var(--color-danger)}.vault-media-loading{border-radius:var(--radius-md);background:#d6e2d666;width:10rem;height:6rem;display:inline-block}@supports (color:color-mix(in lab,red,red)){.vault-media-loading{background:color-mix(in srgb,var(--color-border) 40%,transparent)}}.vault-media-loading{animation:2s cubic-bezier(.4,0,.6,1) infinite pulse}@keyframes pulse{50%{opacity:.5}}@media(prefers-reduced-motion:reduce){.vault-media-loading,.skeleton{animation:none}}@media(prefers-color-scheme:dark){:root:not([data-theme=light]) .prose-note code,:root:not([data-theme=light]) .prose-note pre{background:var(--color-bg-soft);border-color:var(--color-border)}:root:not([data-theme=light]) .prose-note .hljs{color:var(--color-fg);background:var(--color-bg-soft)!important}}:root[data-theme=dark] .prose-note code,:root[data-theme=dark] .prose-note pre{background:var(--color-bg-soft);border-color:var(--color-border)}:root[data-theme=dark] .prose-note .hljs{color:var(--color-fg);background:var(--color-bg-soft)!important}@property --tw-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-z{syntax:"*";inherits:false;initial-value:0}@property --tw-rotate-x{syntax:"*";inherits:false}@property --tw-rotate-y{syntax:"*";inherits:false}@property --tw-rotate-z{syntax:"*";inherits:false}@property --tw-skew-x{syntax:"*";inherits:false}@property --tw-skew-y{syntax:"*";inherits:false}@property --tw-space-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-divide-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-tracking{syntax:"*";inherits:false}@property --tw-ordinal{syntax:"*";inherits:false}@property --tw-slashed-zero{syntax:"*";inherits:false}@property --tw-numeric-figure{syntax:"*";inherits:false}@property --tw-numeric-spacing{syntax:"*";inherits:false}@property --tw-numeric-fraction{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-outline-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-blur{syntax:"*";inherits:false}@property --tw-brightness{syntax:"*";inherits:false}@property --tw-contrast{syntax:"*";inherits:false}@property --tw-grayscale{syntax:"*";inherits:false}@property --tw-hue-rotate{syntax:"*";inherits:false}@property --tw-invert{syntax:"*";inherits:false}@property --tw-opacity{syntax:"*";inherits:false}@property --tw-saturate{syntax:"*";inherits:false}@property --tw-sepia{syntax:"*";inherits:false}@property --tw-drop-shadow{syntax:"*";inherits:false}@property --tw-drop-shadow-color{syntax:"*";inherits:false}@property --tw-drop-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-drop-shadow-size{syntax:"*";inherits:false}@property --tw-backdrop-blur{syntax:"*";inherits:false}@property --tw-backdrop-brightness{syntax:"*";inherits:false}@property --tw-backdrop-contrast{syntax:"*";inherits:false}@property --tw-backdrop-grayscale{syntax:"*";inherits:false}@property --tw-backdrop-hue-rotate{syntax:"*";inherits:false}@property --tw-backdrop-invert{syntax:"*";inherits:false}@property --tw-backdrop-opacity{syntax:"*";inherits:false}@property --tw-backdrop-saturate{syntax:"*";inherits:false}@property --tw-backdrop-sepia{syntax:"*";inherits:false}@property --tw-duration{syntax:"*";inherits:false}@property --tw-ease{syntax:"*";inherits:false}@property --tw-scale-x{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-y{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-z{syntax:"*";inherits:false;initial-value:1}@property --tw-content{syntax:"*";inherits:false;initial-value:""}