@spencerboucher/switchyard 0.22.0 → 0.24.0
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.
- package/README.md +17 -7
- package/dist/bridge/switchyard-terminal.js +2 -0
- package/dist/policies/worker.js +199 -73
- package/dist/switchyard.mjs +17974 -14444
- package/package.json +1 -1
- package/web-dist/assets/AutomationView-BiSxKpgA.js +2 -0
- package/web-dist/assets/AutomationView-BiSxKpgA.js.map +1 -0
- package/web-dist/assets/Checkbox-CneW7ZHn.js +2 -0
- package/web-dist/assets/{Checkbox-DR78wXsg.js.map → Checkbox-CneW7ZHn.js.map} +1 -1
- package/web-dist/assets/DangerZone-tpxj5S8V.js +2 -0
- package/web-dist/assets/{DangerZone-CBnW9h0p.js.map → DangerZone-tpxj5S8V.js.map} +1 -1
- package/web-dist/assets/Field-0rAadZ7B.js +2 -0
- package/web-dist/assets/Field-0rAadZ7B.js.map +1 -0
- package/web-dist/assets/NavigationEditor-DE3vVnHw.js +2 -0
- package/web-dist/assets/{NavigationEditor-C0J7vDXL.js.map → NavigationEditor-DE3vVnHw.js.map} +1 -1
- package/web-dist/assets/Overlay-kkZVSidv.js +2 -0
- package/web-dist/assets/{Overlay-DPZqU_vB.js.map → Overlay-kkZVSidv.js.map} +1 -1
- package/web-dist/assets/{Priority-0hv1Vpg7.js → Priority-VTOBYjs9.js} +2 -2
- package/web-dist/assets/{Priority-0hv1Vpg7.js.map → Priority-VTOBYjs9.js.map} +1 -1
- package/web-dist/assets/RadioCards-Oy23yrpF.js +2 -0
- package/web-dist/assets/{RadioCards-CN5xELnc.js.map → RadioCards-Oy23yrpF.js.map} +1 -1
- package/web-dist/assets/ScopeRepository-BU9I7Gs_.js +6 -0
- package/web-dist/assets/ScopeRepository-BU9I7Gs_.js.map +1 -0
- package/web-dist/assets/ScopeSelect-7ZYRzci5.js +2 -0
- package/web-dist/assets/ScopeSelect-7ZYRzci5.js.map +1 -0
- package/web-dist/assets/SegmentedControl-CCObjCnv.js +2 -0
- package/web-dist/assets/SegmentedControl-CCObjCnv.js.map +1 -0
- package/web-dist/assets/Select-CRC4mF4U.js +2 -0
- package/web-dist/assets/{Select-CN7M29ap.js.map → Select-CRC4mF4U.js.map} +1 -1
- package/web-dist/assets/StructuredValue-DdwqFsZd.js +5 -0
- package/web-dist/assets/StructuredValue-DdwqFsZd.js.map +1 -0
- package/web-dist/assets/Switch-llihKH_2.js +2 -0
- package/web-dist/assets/{Switch-CZMY83Fw.js.map → Switch-llihKH_2.js.map} +1 -1
- package/web-dist/assets/Tabs-CIolUgNo.js +184 -0
- package/web-dist/assets/Tabs-CIolUgNo.js.map +1 -0
- package/web-dist/assets/{TextLink-BpF2vLiL.js → TextLink-BJlPjvKn.js} +2 -2
- package/web-dist/assets/{TextLink-BpF2vLiL.js.map → TextLink-BJlPjvKn.js.map} +1 -1
- package/web-dist/assets/{UINodeRenderer-DqIkLhF8.js → UINodeRenderer-DwZNt-8y.js} +3 -3
- package/web-dist/assets/{UINodeRenderer-DqIkLhF8.js.map → UINodeRenderer-DwZNt-8y.js.map} +1 -1
- package/web-dist/assets/UnfilteredNote-B77oGOcW.js +2 -0
- package/web-dist/assets/{UnfilteredNote-22-Qjb-f.js.map → UnfilteredNote-B77oGOcW.js.map} +1 -1
- package/web-dist/assets/api-C7CMr6g-.js +2 -0
- package/web-dist/assets/api-C7CMr6g-.js.map +1 -0
- package/web-dist/assets/{arrow-down-CzjHSpfM.js → arrow-down-Bqx9CSB1.js} +2 -2
- package/web-dist/assets/{arrow-down-CzjHSpfM.js.map → arrow-down-Bqx9CSB1.js.map} +1 -1
- package/web-dist/assets/{arrow-up-B4YU8Bg0.js → arrow-up-D0b2fv0Q.js} +2 -2
- package/web-dist/assets/{arrow-up-B4YU8Bg0.js.map → arrow-up-D0b2fv0Q.js.map} +1 -1
- package/web-dist/assets/attention-DMhF0I-p.js +2 -0
- package/web-dist/assets/attention-DMhF0I-p.js.map +1 -0
- package/web-dist/assets/auth-vd8OFoQx.js +2 -0
- package/web-dist/assets/auth-vd8OFoQx.js.map +1 -0
- package/web-dist/assets/automations-Dz_JHvUj.js +2 -0
- package/web-dist/assets/{automations-DnydDML9.js.map → automations-Dz_JHvUj.js.map} +1 -1
- package/web-dist/assets/board-CMfIsKrb.js +6 -0
- package/web-dist/assets/board-CMfIsKrb.js.map +1 -0
- package/web-dist/assets/{calendar-clock-B3bQkNKq.js → calendar-clock-C5cMYlld.js} +2 -2
- package/web-dist/assets/{calendar-clock-B3bQkNKq.js.map → calendar-clock-C5cMYlld.js.map} +1 -1
- package/web-dist/assets/chevron-right-5ip-ZfOW.js +2 -0
- package/web-dist/assets/{chevron-right-DuAbbYQ-.js.map → chevron-right-5ip-ZfOW.js.map} +1 -1
- package/web-dist/assets/code-BpPDYwth.js +24 -0
- package/web-dist/assets/code-BpPDYwth.js.map +1 -0
- package/web-dist/assets/{core.esm-BbOnWvFK.js → core.esm-C_QgTrGe.js} +2 -2
- package/web-dist/assets/{core.esm-BbOnWvFK.js.map → core.esm-C_QgTrGe.js.map} +1 -1
- package/web-dist/assets/{describe-DWsoiUix.js → describe-Bd1JbydU.js} +3 -3
- package/web-dist/assets/describe-Bd1JbydU.js.map +1 -0
- package/web-dist/assets/enroll-B_ZjVnEj.js +2 -0
- package/web-dist/assets/{enroll-CV77Sk6h.js.map → enroll-B_ZjVnEj.js.map} +1 -1
- package/web-dist/assets/external-link-DeLk0jmb.js +2 -0
- package/web-dist/assets/external-link-DeLk0jmb.js.map +1 -0
- package/web-dist/assets/{git-branch-Dr8PvfHN.js → git-branch-DuApoZes.js} +2 -2
- package/web-dist/assets/{git-branch-Dr8PvfHN.js.map → git-branch-DuApoZes.js.map} +1 -1
- package/web-dist/assets/{grip-vertical-Bc5pJHHF.js → grip-vertical-DfKSP8jp.js} +2 -2
- package/web-dist/assets/{grip-vertical-Bc5pJHHF.js.map → grip-vertical-DfKSP8jp.js.map} +1 -1
- package/web-dist/assets/{hand-B2TrADIv.js → hand-ryhCgGbh.js} +2 -2
- package/web-dist/assets/{hand-B2TrADIv.js.map → hand-ryhCgGbh.js.map} +1 -1
- package/web-dist/assets/index-BXoBPAUR.js +17 -0
- package/web-dist/assets/index-BXoBPAUR.js.map +1 -0
- package/web-dist/assets/index-Bm6tklht.css +2 -0
- package/web-dist/assets/{link-2-M5ENDPWT.js → link-2-pHvZvxCs.js} +2 -2
- package/web-dist/assets/{link-2-M5ENDPWT.js.map → link-2-pHvZvxCs.js.map} +1 -1
- package/web-dist/assets/logic-3so3T0af.js +4 -0
- package/web-dist/assets/logic-3so3T0af.js.map +1 -0
- package/web-dist/assets/logic-uhnfzaYJ.js +2 -0
- package/web-dist/assets/{logic-CG2E-voG.js.map → logic-uhnfzaYJ.js.map} +1 -1
- package/web-dist/assets/more-C41VHBVG.js +2 -0
- package/web-dist/assets/{more-CVjg2O5h.js.map → more-C41VHBVG.js.map} +1 -1
- package/web-dist/assets/{pencil-y_4AgVa2.js → pencil-BoQa6LEV.js} +2 -2
- package/web-dist/assets/{pencil-y_4AgVa2.js.map → pencil-BoQa6LEV.js.map} +1 -1
- package/web-dist/assets/{play-CYKX2aVL.js → play-DjTVY8Ej.js} +2 -2
- package/web-dist/assets/{play-CYKX2aVL.js.map → play-DjTVY8Ej.js.map} +1 -1
- package/web-dist/assets/{plus-B6uH1yKa.js → plus-BQPgQYui.js} +2 -2
- package/web-dist/assets/{plus-B6uH1yKa.js.map → plus-BQPgQYui.js.map} +1 -1
- package/web-dist/assets/{policyLogic-CioD2rMm.js → policyLogic-cyMrhCM6.js} +2 -2
- package/web-dist/assets/{policyLogic-CioD2rMm.js.map → policyLogic-cyMrhCM6.js.map} +1 -1
- package/web-dist/assets/{prefs-V29Ms2ZL.js → prefs-CkiUftvR.js} +2 -2
- package/web-dist/assets/{prefs-V29Ms2ZL.js.map → prefs-CkiUftvR.js.map} +1 -1
- package/web-dist/assets/preload-helper-B_HW6k8N.js +9 -0
- package/web-dist/assets/preload-helper-B_HW6k8N.js.map +1 -0
- package/web-dist/assets/queue-CSCmR2Xf.js +2 -0
- package/web-dist/assets/{queue-BGK9c062.js.map → queue-CSCmR2Xf.js.map} +1 -1
- package/web-dist/assets/rolldown-runtime-XKyaHtl9.js +1 -0
- package/web-dist/assets/{rotate-ccw-DvfmNYNE.js → rotate-ccw-C07CP9JG.js} +2 -2
- package/web-dist/assets/{rotate-ccw-DvfmNYNE.js.map → rotate-ccw-C07CP9JG.js.map} +1 -1
- package/web-dist/assets/{search-GTFKEqAS.js → search-bqDM8qB0.js} +2 -2
- package/web-dist/assets/{search-GTFKEqAS.js.map → search-bqDM8qB0.js.map} +1 -1
- package/web-dist/assets/settings-iTwK6CzQ.js +6 -0
- package/web-dist/assets/settings-iTwK6CzQ.js.map +1 -0
- package/web-dist/assets/states-goHGz_CJ.js +60 -0
- package/web-dist/assets/{states-BUWwUyu-.js.map → states-goHGz_CJ.js.map} +1 -1
- package/web-dist/assets/{terminal-DGVFZER3.js → terminal-BFJK8pLS.js} +2 -2
- package/web-dist/assets/{terminal-DGVFZER3.js.map → terminal-BFJK8pLS.js.map} +1 -1
- package/web-dist/assets/terminal-login-DwI8gUw-.js +2 -0
- package/web-dist/assets/{terminal-login-Gy6aLzgC.js.map → terminal-login-DwI8gUw-.js.map} +1 -1
- package/web-dist/assets/useBreakpoint-C7ONetzK.js +2 -0
- package/web-dist/assets/{useBreakpoint-DoLUoCMf.js.map → useBreakpoint-C7ONetzK.js.map} +1 -1
- package/web-dist/assets/useNow-BFhACgmu.js +2 -0
- package/web-dist/assets/{useNow-BS_9T7IY.js.map → useNow-BFhACgmu.js.map} +1 -1
- package/web-dist/assets/useResource-Br3v4Sui.js +2 -0
- package/web-dist/assets/useResource-Br3v4Sui.js.map +1 -0
- package/web-dist/assets/useSwipeTabs-_JvGirwa.js +2 -0
- package/web-dist/assets/useSwipeTabs-_JvGirwa.js.map +1 -0
- package/web-dist/assets/workboard-IozvaLbf.js +3 -0
- package/web-dist/assets/workboard-IozvaLbf.js.map +1 -0
- package/web-dist/index.html +9 -7
- package/web-dist/sw.js +1 -1
- package/web-dist/sw.js.map +1 -1
- package/web-dist/assets/AutomationView-DwZ_2m9J.js +0 -2
- package/web-dist/assets/AutomationView-DwZ_2m9J.js.map +0 -1
- package/web-dist/assets/Checkbox-DR78wXsg.js +0 -2
- package/web-dist/assets/DangerZone-CBnW9h0p.js +0 -2
- package/web-dist/assets/Field-DS2BMoqA.js +0 -2
- package/web-dist/assets/Field-DS2BMoqA.js.map +0 -1
- package/web-dist/assets/Markdown-BIO6MBTM.js +0 -184
- package/web-dist/assets/Markdown-BIO6MBTM.js.map +0 -1
- package/web-dist/assets/NavigationEditor-C0J7vDXL.js +0 -2
- package/web-dist/assets/Overlay-DPZqU_vB.js +0 -2
- package/web-dist/assets/RadioCards-CN5xELnc.js +0 -2
- package/web-dist/assets/ScopeSelect-BaJjip1Y.js +0 -2
- package/web-dist/assets/ScopeSelect-BaJjip1Y.js.map +0 -1
- package/web-dist/assets/SegmentedControl-CRmhE-Kn.js +0 -2
- package/web-dist/assets/SegmentedControl-CRmhE-Kn.js.map +0 -1
- package/web-dist/assets/Select-CN7M29ap.js +0 -2
- package/web-dist/assets/Switch-CZMY83Fw.js +0 -2
- package/web-dist/assets/Tabs-_1w3hoAR.js +0 -2
- package/web-dist/assets/Tabs-_1w3hoAR.js.map +0 -1
- package/web-dist/assets/UnfilteredNote-22-Qjb-f.js +0 -2
- package/web-dist/assets/api-RftVSu44.js +0 -2
- package/web-dist/assets/api-RftVSu44.js.map +0 -1
- package/web-dist/assets/attention-CEgIsUuq.js +0 -2
- package/web-dist/assets/attention-CEgIsUuq.js.map +0 -1
- package/web-dist/assets/automations-DnydDML9.js +0 -2
- package/web-dist/assets/board-BPxxc8G4.js +0 -6
- package/web-dist/assets/board-BPxxc8G4.js.map +0 -1
- package/web-dist/assets/chevron-right-DuAbbYQ-.js +0 -2
- package/web-dist/assets/code-D5IB7jTT.js +0 -28
- package/web-dist/assets/code-D5IB7jTT.js.map +0 -1
- package/web-dist/assets/describe-DWsoiUix.js.map +0 -1
- package/web-dist/assets/enroll-CV77Sk6h.js +0 -2
- package/web-dist/assets/index-BXQwol8u.css +0 -2
- package/web-dist/assets/index-cmIcNnnF.js +0 -17
- package/web-dist/assets/index-cmIcNnnF.js.map +0 -1
- package/web-dist/assets/logic-CG2E-voG.js +0 -2
- package/web-dist/assets/logic-D_vBBkcD.js +0 -4
- package/web-dist/assets/logic-D_vBBkcD.js.map +0 -1
- package/web-dist/assets/more-CVjg2O5h.js +0 -2
- package/web-dist/assets/queue-BGK9c062.js +0 -2
- package/web-dist/assets/repo-CuL_qbqU.js +0 -5
- package/web-dist/assets/repo-CuL_qbqU.js.map +0 -1
- package/web-dist/assets/selection-CAMJBh5A.js +0 -9
- package/web-dist/assets/selection-CAMJBh5A.js.map +0 -1
- package/web-dist/assets/settings-o7k_MPK7.js +0 -9
- package/web-dist/assets/settings-o7k_MPK7.js.map +0 -1
- package/web-dist/assets/states-BUWwUyu-.js +0 -60
- package/web-dist/assets/terminal-login-Gy6aLzgC.js +0 -2
- package/web-dist/assets/useBreakpoint-DoLUoCMf.js +0 -2
- package/web-dist/assets/useIndicator-BKqIsw2Q.js +0 -2
- package/web-dist/assets/useIndicator-BKqIsw2Q.js.map +0 -1
- package/web-dist/assets/useNow-BS_9T7IY.js +0 -2
- package/web-dist/assets/useResource-CPN6cDQ5.js +0 -2
- package/web-dist/assets/useResource-CPN6cDQ5.js.map +0 -1
- package/web-dist/assets/useSwipeTabs-XRK0_O6T.js +0 -2
- package/web-dist/assets/useSwipeTabs-XRK0_O6T.js.map +0 -1
- package/web-dist/assets/workboard-FE6bAMnW.js +0 -3
- package/web-dist/assets/workboard-FE6bAMnW.js.map +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"describe-DWsoiUix.js","names":["useMemo","useState","useCallback","apiPatch","useSyncStore","apiPost","errorMessage","create","require_react","__toESM","require_jsx_runtime","AutomationInput","TriangleAlert","toast","CircleCheck","import_react","import_jsx_runtime","FailureCount","count","automationPath","id","suffix","useLocalAutomations","set","s","a","byId","list","newer","b","useMergedAutomations","store","local","deleted","out","useMergedAutomation","fromStore","fromLocal","useToggleEnabled","busy","setBusy","res","enabled","useRunNow","state","onDone","TRIGGER_KIND_LABELS","MODE_OPTIONS","OVERLAP_OPTIONS","MISSED_OPTIONS","modeLabel","m","mode","TEMPLATE_VARIABLES","listText","items","pad","n","ordinal","mod100","capitalize","lines","text","l","DAY_NAMES","MONTH_NAMES","CRON_FIELDS","d","parseValue","lower","token","def","idx","parseCronField","src","parts","values","step","part","base","stepStr","extra","every","start","end","av","bv","v","i","sorted","full","parseCron","trimmed","expr","fields","parsed","validateCron","validateTimezone","tz","isContiguous","describeTime","h","at","times","hv","mv","first","last","mm","mondayFirst","describeDays","dom","dow","months","mon","inMonths","days","key","names","ords","of","describeCron","f","time","timezone","describeCronOrRaw","formatAbsolute","iso","describeTrigger","fmt","ctx","trigger","title","triggerClause","t","input","filters","summarizeAutomation","project","host","profile","action","c","checks","localTimezone","emptyDraft","opts","isoToLocalInput","localInputToIso","value","draftFromAutomation","toNumber","toOptionalNumber","draftTrigger","draftToInput","PATH_TO_FIELD","fieldForPath","path","intError","min","max","label","validateDraft","errors","msg","raw","issue","occurrenceTime","o","mergeOccurrences","lists","normalizeHistory","r","curlExample","url"],"sources":["../../src/features/automations/controls.tsx","../../src/features/automations/describe.ts"],"sourcesContent":["import type { Automation } from \"@switchyard/protocol\";\nimport { CircleCheck, TriangleAlert } from \"lucide-react\";\nimport { useCallback, useMemo, useState } from \"react\";\nimport { create } from \"zustand\";\nimport { toast } from \"../../components/ui/Toast\";\nimport { apiPatch, apiPost, errorMessage } from \"../../sync/api\";\nimport { useSyncStore } from \"../../sync/store\";\n\n/* Small building blocks shared by the Automations list and editor. */\n\n/** Failure count as icon + text; warning tone when > 0. */\nexport function FailureCount({ count }: { count: number }) {\n if (count > 0) {\n return (\n <span className=\"inline-flex items-center gap-1 text-sm text-warning\">\n <TriangleAlert aria-hidden className=\"size-4 shrink-0\" />\n {count === 1 ? \"1 failure\" : `${count} failures`}\n </span>\n );\n }\n return (\n <span className=\"inline-flex items-center gap-1 text-sm text-muted\">\n <CircleCheck aria-hidden className=\"size-4 shrink-0\" />\n No failures\n </span>\n );\n}\n\nexport const automationPath = (id: string, suffix = \"\") =>\n `/api/automations/${encodeURIComponent(id)}${suffix}`;\n\n/* ------------------------------------------------------------------ */\n/* Automations acknowledged over REST (create/patch responses, list */\n/* fallback) so views do not wait for the automation.updated event. */\n/* ------------------------------------------------------------------ */\n\ninterface LocalAutomations {\n byId: Record<string, Automation>;\n deleted: Record<string, true>;\n put(a: Automation): void;\n putMany(list: Automation[]): void;\n remove(id: string): void;\n}\n\nexport const useLocalAutomations = create<LocalAutomations>()((set) => ({\n byId: {},\n deleted: {},\n put: (a) => set((s) => ({ byId: { ...s.byId, [a.id]: a } })),\n putMany: (list) =>\n set((s) => {\n const byId = { ...s.byId };\n for (const a of list) byId[a.id] = a;\n return { byId };\n }),\n remove: (id) =>\n set((s) => {\n const byId = { ...s.byId };\n delete byId[id];\n return { byId, deleted: { ...s.deleted, [id]: true } };\n }),\n}));\n\nfunction newer(a: Automation | undefined, b: Automation | undefined): Automation | undefined {\n if (!a) return b;\n if (!b) return a;\n return b.updatedAt > a.updatedAt ? b : a;\n}\n\n/** Store automations merged with REST acknowledgements (newest updatedAt wins). */\nexport function useMergedAutomations(): Record<string, Automation> {\n const store = useSyncStore((s) => s.automations);\n const local = useLocalAutomations((s) => s.byId);\n const deleted = useLocalAutomations((s) => s.deleted);\n return useMemo(() => {\n const out: Record<string, Automation> = {};\n for (const id of new Set([...Object.keys(store), ...Object.keys(local)])) {\n if (deleted[id]) continue;\n const a = newer(store[id], local[id]);\n if (a) out[id] = a;\n }\n return out;\n }, [store, local, deleted]);\n}\n\nexport function useMergedAutomation(id: string | undefined): Automation | undefined {\n const fromStore = useSyncStore((s) => (id ? s.automations[id] : undefined));\n const fromLocal = useLocalAutomations((s) => (id ? s.byId[id] : undefined));\n const deleted = useLocalAutomations((s) => (id ? s.deleted[id] : undefined));\n return deleted ? undefined : newer(fromStore, fromLocal);\n}\n\n/** Enable/disable with no optimistic success: busy until the coordinator acknowledges. */\nexport function useToggleEnabled() {\n const [busy, setBusy] = useState<Record<string, boolean>>({});\n const toggle = useCallback(async (a: Pick<Automation, \"id\" | \"name\">, enabled: boolean) => {\n setBusy((b) => ({ ...b, [a.id]: true }));\n try {\n const res = await apiPatch<Automation | undefined>(automationPath(a.id), { enabled });\n if (res && typeof res === \"object\" && \"id\" in res) useLocalAutomations.getState().put(res);\n toast.success(`${a.name} ${enabled ? \"enabled\" : \"disabled\"}`);\n } catch (e) {\n toast.error(`Could not ${enabled ? \"enable\" : \"disable\"} ${a.name}: ${errorMessage(e)}`);\n } finally {\n setBusy((b) => ({ ...b, [a.id]: false }));\n }\n }, []);\n return { busy, toggle };\n}\n\n/** Manual \"Run now\": busy until acknowledged; never reports success early. */\nexport function useRunNow(onDone?: () => void) {\n const [busy, setBusy] = useState<Record<string, boolean>>({});\n const run = useCallback(\n async (a: Pick<Automation, \"id\" | \"name\">) => {\n setBusy((b) => ({ ...b, [a.id]: true }));\n try {\n const res = await apiPost<{ state?: string } | undefined>(automationPath(a.id, \"/run\"));\n const state = res && typeof res === \"object\" ? res.state : undefined;\n toast.success(\n state && state !== \"fired\"\n ? `${a.name}: occurrence recorded (${state.replace(/_/g, \" \")})`\n : `${a.name} started`,\n );\n onDone?.();\n } catch (e) {\n toast.error(`Could not run ${a.name}: ${errorMessage(e)}`);\n } finally {\n setBusy((b) => ({ ...b, [a.id]: false }));\n }\n },\n [onDone],\n );\n return { busy, run };\n}\n","import {\n type Automation,\n AutomationInput,\n type Occurrence,\n PRIORITY_LABELS,\n type Priority,\n type Trigger,\n} from \"@switchyard/protocol\";\n\n/*\n * Pure helpers for the Automations feature: a small cron describer, trigger\n * and whole-automation summaries, the editor draft <-> AutomationInput\n * conversion with field-level validation, and history merging.\n */\n\n/* ------------------------------------------------------------------ */\n/* Labels and explanations */\n/* ------------------------------------------------------------------ */\n\nexport type AutomationMode = AutomationInput[\"mode\"];\nexport type OverlapPolicy = AutomationInput[\"overlap\"];\nexport type MissedPolicy = AutomationInput[\"missed\"];\nexport type TriggerKind = Trigger[\"kind\"];\n\nexport const TRIGGER_KIND_LABELS: Record<TriggerKind, string> = {\n manual: \"Manual\",\n once: \"Once\",\n cron: \"Schedule\",\n webhook: \"Webhook\",\n dependency: \"Dependency\",\n};\n\nexport const MODE_OPTIONS: { value: AutomationMode; label: string; explanation: string }[] = [\n { value: \"fresh\", label: \"Fresh\", explanation: \"Fresh: a new task per occurrence\" },\n {\n value: \"continue\",\n label: \"Continue\",\n explanation: \"Continue: reuse the task with the same grouping key\",\n },\n {\n value: \"watch\",\n label: \"Watch\",\n explanation: \"Watch: only raises attention when something relevant changed\",\n },\n];\n\nexport const OVERLAP_OPTIONS: { value: OverlapPolicy; label: string; explanation: string }[] = [\n {\n value: \"skip\",\n label: \"Skip\",\n explanation: \"Skip: drop the occurrence while earlier work is still open\",\n },\n {\n value: \"queue_one\",\n label: \"Queue one\",\n explanation: \"Queue one: keep a single pending occurrence and fire it when the open work ends\",\n },\n {\n value: \"append\",\n label: \"Append\",\n explanation: \"Append: add the new objective to the open task (as a follow-up if it is running)\",\n },\n];\n\nexport const MISSED_OPTIONS: { value: MissedPolicy; label: string; explanation: string }[] = [\n {\n value: \"skip\",\n label: \"Skip\",\n explanation: \"Skip: occurrences missed while the coordinator was down are recorded and skipped\",\n },\n {\n value: \"run_once\",\n label: \"Run once\",\n explanation: \"Run once: on return, fire the newest missed occurrence once\",\n },\n];\n\nexport function modeLabel(mode: AutomationMode): string {\n return MODE_OPTIONS.find((m) => m.value === mode)?.label ?? mode;\n}\n\nexport function priorityLabel(p: Priority): string {\n return PRIORITY_LABELS[p] ?? String(p);\n}\n\nexport const TEMPLATE_VARIABLES = [\"{{date}}\", \"{{time}}\", \"{{occurrence}}\", \"{{payload.<path>}}\"];\n\n/* ------------------------------------------------------------------ */\n/* Text utilities */\n/* ------------------------------------------------------------------ */\n\n/** \"a\", \"a and b\", \"a, b and c\". */\nexport function listText(items: string[]): string {\n if (items.length <= 1) return items[0] ?? \"\";\n return `${items.slice(0, -1).join(\", \")} and ${items[items.length - 1]}`;\n}\n\nfunction pad(n: number): string {\n return String(n).padStart(2, \"0\");\n}\n\nexport function ordinal(n: number): string {\n const mod100 = n % 100;\n if (mod100 >= 11 && mod100 <= 13) return `${n}th`;\n switch (n % 10) {\n case 1:\n return `${n}st`;\n case 2:\n return `${n}nd`;\n case 3:\n return `${n}rd`;\n default:\n return `${n}th`;\n }\n}\n\nfunction capitalize(s: string): string {\n return s ? s[0]!.toUpperCase() + s.slice(1) : s;\n}\n\n/** Non-empty trimmed lines. */\nexport function lines(text: string): string[] {\n return text\n .split(\"\\n\")\n .map((l) => l.trim())\n .filter((l) => l.length > 0);\n}\n\n/* ------------------------------------------------------------------ */\n/* Cron */\n/* ------------------------------------------------------------------ */\n\nconst DAY_NAMES = [\"Sunday\", \"Monday\", \"Tuesday\", \"Wednesday\", \"Thursday\", \"Friday\", \"Saturday\"];\nconst MONTH_NAMES = [\n \"January\",\n \"February\",\n \"March\",\n \"April\",\n \"May\",\n \"June\",\n \"July\",\n \"August\",\n \"September\",\n \"October\",\n \"November\",\n \"December\",\n];\n\ninterface FieldDef {\n name: string;\n min: number;\n max: number;\n /** Three-letter aliases mapped to `min + index`. */\n names?: string[];\n}\n\nconst CRON_FIELDS: FieldDef[] = [\n { name: \"Minute\", min: 0, max: 59 },\n { name: \"Hour\", min: 0, max: 23 },\n { name: \"Day of month\", min: 1, max: 31 },\n {\n name: \"Month\",\n min: 1,\n max: 12,\n names: MONTH_NAMES.map((m) => m.slice(0, 3).toLowerCase()),\n },\n {\n name: \"Day of week\",\n min: 0,\n max: 7,\n names: DAY_NAMES.map((d) => d.slice(0, 3).toLowerCase()),\n },\n];\n\nexport interface CronField {\n /** `*` (or `?`): every value. */\n any: boolean;\n /** Expanded, sorted, unique values (empty when `any`). */\n values: number[];\n /** Set when the field is a single `*\\/n` or `a/n` step. */\n step: { every: number; start: number } | null;\n /** Uses croner extensions (L, W, #) the describer does not explain. */\n extended: boolean;\n}\n\nfunction parseValue(token: string, def: FieldDef): number | string {\n const lower = token.toLowerCase();\n if (def.names) {\n const idx = def.names.indexOf(lower);\n if (idx >= 0) return def.min + idx;\n }\n if (!/^\\d+$/.test(token)) return `\"${token}\" is not a number`;\n const n = Number(token);\n if (n < def.min || n > def.max) return `${n} is out of range ${def.min}–${def.max}`;\n return n;\n}\n\n/** Parse one cron field; returns an error message for invalid input. */\nexport function parseCronField(src: string, def: FieldDef): CronField | string {\n if (src === \"*\" || src === \"?\") return { any: true, values: [], step: null, extended: false };\n if (/[LW#]/i.test(src) && !def.names?.some((n) => src.toLowerCase().includes(n))) {\n if (!/^[0-9A-Za-z*?,\\-/#]+$/.test(src)) return `\"${src}\" is not valid`;\n return { any: false, values: [], step: null, extended: true };\n }\n const parts = src.split(\",\");\n const values = new Set<number>();\n let step: CronField[\"step\"] = null;\n for (const part of parts) {\n if (!part) return \"empty list item\";\n const [base, stepStr, extra] = part.split(\"/\");\n if (extra !== undefined) return `\"${part}\" has more than one step`;\n let every = 1;\n if (stepStr !== undefined) {\n if (!/^\\d+$/.test(stepStr) || Number(stepStr) < 1) return `\"${stepStr}\" is not a valid step`;\n every = Number(stepStr);\n }\n let start: number;\n let end: number;\n if (base === \"*\" || base === \"?\") {\n start = def.min;\n end = def.max;\n } else if (base?.includes(\"-\")) {\n const [a, b] = base.split(\"-\");\n const av = parseValue(a ?? \"\", def);\n const bv = parseValue(b ?? \"\", def);\n if (typeof av === \"string\") return av;\n if (typeof bv === \"string\") return bv;\n if (av > bv) return `range ${base} runs backwards`;\n start = av;\n end = bv;\n } else {\n const v = parseValue(base ?? \"\", def);\n if (typeof v === \"string\") return v;\n start = v;\n end = stepStr !== undefined ? def.max : v;\n }\n for (let i = start; i <= end; i += every) values.add(i);\n if (parts.length === 1 && stepStr !== undefined && !base?.includes(\"-\")) {\n step = { every, start };\n }\n }\n let sorted = [...values].sort((a, b) => a - b);\n // Day of week: 7 is Sunday.\n if (def.max === 7) sorted = [...new Set(sorted.map((v) => v % 7))].sort((a, b) => a - b);\n const full = def.max === 7 ? 7 : def.max - def.min + 1;\n if (sorted.length === full && !step)\n return { any: true, values: [], step: null, extended: false };\n return { any: false, values: sorted, step, extended: false };\n}\n\nexport function parseCron(expr: string): CronField[] | string {\n const trimmed = expr.trim();\n if (!trimmed) return \"Enter a cron expression\";\n const fields = trimmed.split(/\\s+/);\n if (fields.length !== 5) {\n return `Expected 5 fields (minute hour day-of-month month day-of-week), got ${fields.length}`;\n }\n const out: CronField[] = [];\n for (let i = 0; i < 5; i++) {\n const def = CRON_FIELDS[i]!;\n const parsed = parseCronField(fields[i]!, def);\n if (typeof parsed === \"string\") return `${def.name}: ${parsed}`;\n out.push(parsed);\n }\n return out;\n}\n\n/** Null when valid, otherwise a message. */\nexport function validateCron(expr: string): string | null {\n const parsed = parseCron(expr);\n return typeof parsed === \"string\" ? parsed : null;\n}\n\n/** Null when the IANA timezone is known to this browser. */\nexport function validateTimezone(tz: string): string | null {\n if (!tz.trim()) return \"Enter a timezone\";\n try {\n new Intl.DateTimeFormat(undefined, { timeZone: tz.trim() });\n return null;\n } catch {\n return `Unknown timezone \"${tz}\"`;\n }\n}\n\nfunction isContiguous(values: number[]): boolean {\n for (let i = 1; i < values.length; i++) if (values[i] !== values[i - 1]! + 1) return false;\n return values.length > 0;\n}\n\ntype TimePhrase = { kind: \"at\"; text: string } | { kind: \"freq\"; text: string };\n\nfunction describeTime(m: CronField, h: CronField): TimePhrase | null {\n if (m.any && h.any) return { kind: \"freq\", text: \"Every minute\" };\n if (m.step && m.step.start === 0 && h.any) {\n return {\n kind: \"freq\",\n text: m.step.every === 1 ? \"Every minute\" : `Every ${m.step.every} minutes`,\n };\n }\n if (m.any) {\n if (h.step || h.values.length === 0) return null;\n if (isContiguous(h.values)) {\n return {\n kind: \"freq\",\n text: `Every minute from ${pad(h.values[0]!)}:00 to ${pad(h.values[h.values.length - 1]!)}:59`,\n };\n }\n return null;\n }\n if (h.any) {\n if (m.step) return null;\n if (m.values.length === 1 && m.values[0] === 0) return { kind: \"freq\", text: \"Every hour\" };\n return {\n kind: \"freq\",\n text: `Every hour at ${listText(m.values.map((v) => `:${pad(v)}`))}`,\n };\n }\n if (h.step && h.step.start === 0 && m.values.length === 1 && !m.step) {\n const at = m.values[0] === 0 ? \"\" : ` at :${pad(m.values[0]!)}`;\n return {\n kind: \"freq\",\n text: h.step.every === 1 ? `Every hour${at}` : `Every ${h.step.every} hours${at}`,\n };\n }\n if (m.values.length * h.values.length <= 6) {\n const times: string[] = [];\n for (const hv of h.values) for (const mv of m.values) times.push(`${pad(hv)}:${pad(mv)}`);\n return { kind: \"at\", text: listText(times) };\n }\n if (!isContiguous(h.values)) return null;\n const first = h.values[0]!;\n const last = h.values[h.values.length - 1]!;\n if (m.step && m.step.start === 0) {\n return {\n kind: \"freq\",\n text: `Every ${m.step.every} minutes from ${pad(first)}:00 to ${pad(last)}:59`,\n };\n }\n if (m.values.length === 1) {\n const mm = pad(m.values[0]!);\n return { kind: \"freq\", text: `Every hour from ${pad(first)}:${mm} to ${pad(last)}:${mm}` };\n }\n return null;\n}\n\n/** Monday-first ordering for day-of-week lists. */\nfunction mondayFirst(a: number, b: number): number {\n return ((a + 6) % 7) - ((b + 6) % 7);\n}\n\nfunction describeDays(\n dom: CronField,\n mon: CronField,\n dow: CronField,\n): { lead: string; qual: string } | null {\n if (!dom.any && !dow.any) return null;\n const months = mon.any ? null : listText(mon.values.map((v) => MONTH_NAMES[v - 1]!));\n const inMonths = months ? ` in ${months}` : \"\";\n if (!dow.any) {\n const days = [...dow.values].sort(mondayFirst);\n const key = days.join(\",\");\n if (key === \"1,2,3,4,5\") {\n return { lead: `Every weekday${inMonths}`, qual: ` on weekdays${inMonths}` };\n }\n if (key === \"6,0\") {\n return { lead: `Every Saturday and Sunday${inMonths}`, qual: ` on weekends${inMonths}` };\n }\n const names = days.map((d) => DAY_NAMES[d]!);\n return {\n lead: `Every ${listText(names)}${inMonths}`,\n qual: ` on ${listText(names.map((n) => `${n}s`))}${inMonths}`,\n };\n }\n if (!dom.any) {\n if (dom.values.length > 5) return null;\n const ords = listText(dom.values.map(ordinal));\n const of = months ? months : \"every month\";\n return { lead: `On the ${ords} of ${of}`, qual: ` on the ${ords} of ${of}` };\n }\n return { lead: `Every day${inMonths}`, qual: inMonths };\n}\n\n/**\n * Human description of a 5-field cron expression (\"Every weekday at 09:00\n * (America/Denver)\"), or null when the expression is outside what this small\n * describer covers.\n */\nexport function describeCron(expr: string, timezone?: string): string | null {\n const parsed = parseCron(expr);\n if (typeof parsed === \"string\") return null;\n if (parsed.some((f) => f.extended)) return null;\n const [m, h, dom, mon, dow] = parsed as [CronField, CronField, CronField, CronField, CronField];\n const time = describeTime(m, h);\n const days = describeDays(dom, mon, dow);\n if (!time || !days) return null;\n const text = time.kind === \"at\" ? `${days.lead} at ${time.text}` : `${time.text}${days.qual}`;\n return timezone ? `${text} (${timezone})` : text;\n}\n\n/** describeCron with the raw-expression fallback. */\nexport function describeCronOrRaw(expr: string, timezone: string): string {\n return describeCron(expr, timezone) ?? `Cron ${expr.trim()} (${timezone})`;\n}\n\n/* ------------------------------------------------------------------ */\n/* Summaries */\n/* ------------------------------------------------------------------ */\n\nexport function formatAbsolute(iso: string): string {\n const d = new Date(iso);\n if (Number.isNaN(d.getTime())) return iso;\n return d.toLocaleString(undefined, { dateStyle: \"medium\", timeStyle: \"short\" });\n}\n\nexport interface SummaryContext {\n projectName?: string | null;\n /** Name of the explicitly selected host; null/undefined means the project default. */\n hostName?: string | null;\n profileName?: string | null;\n taskTitle?: (taskId: string) => string | undefined;\n formatDate?: (iso: string) => string;\n}\n\n/** Short trigger summary for list rows. */\nexport function describeTrigger(trigger: Trigger, ctx: SummaryContext = {}): string {\n const fmt = ctx.formatDate ?? formatAbsolute;\n switch (trigger.kind) {\n case \"manual\":\n return \"Manual\";\n case \"once\":\n return trigger.at && !Number.isNaN(Date.parse(trigger.at))\n ? `Once at ${fmt(trigger.at)}`\n : \"Once (no time chosen)\";\n case \"cron\":\n return describeCronOrRaw(trigger.expr, trigger.timezone);\n case \"webhook\":\n return \"Webhook\";\n case \"dependency\": {\n const title = trigger.taskId ? ctx.taskTitle?.(trigger.taskId) : undefined;\n if (title) return `When \"${title}\" is done`;\n return trigger.taskId ? \"When a deleted task is done\" : \"When a task is done\";\n }\n }\n}\n\ntype SummaryInput = Pick<\n AutomationInput,\n | \"trigger\"\n | \"filters\"\n | \"template\"\n | \"mode\"\n | \"groupingKey\"\n | \"overlap\"\n | \"missed\"\n | \"continuation\"\n | \"completion\"\n>;\n\nfunction triggerClause(input: SummaryInput, ctx: SummaryContext): string {\n const t = input.trigger;\n switch (t.kind) {\n case \"manual\":\n return \"When run manually\";\n case \"webhook\": {\n const filters = input.filters.filter((f) => f.path.trim());\n if (filters.length === 0) return \"When a webhook is received\";\n return `When a webhook is received where ${listText(\n filters.map((f) => `${f.path.trim()} = \"${f.equals}\"`),\n )}`;\n }\n default:\n return describeTrigger(t, ctx);\n }\n}\n\n/**\n * One-paragraph description of what the automation does, e.g. 'Every weekday\n * at 09:00 (America/Denver), create a fresh task \"Triage\" in Web on my-server; skip\n * if previous work is still open; skip missed runs; requires human review'.\n */\nexport function summarizeAutomation(input: SummaryInput, ctx: SummaryContext = {}): string {\n const title = input.template.title.trim() || \"Untitled task\";\n const project = ctx.projectName ? ` in ${ctx.projectName}` : \"\";\n const host = ctx.hostName ? ` on ${ctx.hostName}` : \" on the project's default host\";\n const profile = ctx.profileName ? ` with profile ${ctx.profileName}` : \"\";\n let action: string;\n switch (input.mode) {\n case \"continue\": {\n const key = input.groupingKey?.trim();\n action = key\n ? `continue the task grouped by \"${key}\" (or create \"${title}\")`\n : `continue the matching task (or create \"${title}\")`;\n break;\n }\n case \"watch\":\n action = `create a watch task \"${title}\" that only raises attention when something relevant changed`;\n break;\n default:\n action = `create a fresh task \"${title}\"`;\n }\n const parts = [`${triggerClause(input, ctx)}, ${action}${project}${host}${profile}`];\n parts.push(\n input.overlap === \"skip\"\n ? \"skip if previous work is still open\"\n : input.overlap === \"queue_one\"\n ? \"queue one occurrence if previous work is still open\"\n : \"append to the open task if previous work is still open\",\n );\n if (input.trigger.kind === \"cron\" || input.trigger.kind === \"once\") {\n parts.push(input.missed === \"skip\" ? \"skip missed runs\" : \"run missed runs once on return\");\n }\n if (input.continuation.enabled) {\n const c = input.continuation;\n parts.push(\n `continue automatically up to ${c.maxContinuations} times within ${c.maxElapsedMinutes} minutes`,\n );\n }\n const checks = input.completion.checks;\n if (checks && checks.length > 0) {\n parts.push(`run ${checks.length === 1 ? \"1 check\" : `${checks.length} checks`}`);\n }\n parts.push(\n input.completion.requireHumanReview ? \"requires human review\" : \"no human review required\",\n );\n return capitalize(parts.join(\"; \"));\n}\n\n/* ------------------------------------------------------------------ */\n/* Editor draft */\n/* ------------------------------------------------------------------ */\n\n/** Form state: strings for inputs so partial edits survive validation. */\nexport interface AutomationDraft {\n name: string;\n enabled: boolean;\n projectId: string;\n triggerKind: TriggerKind;\n /** datetime-local value (local time, no zone). */\n onceAt: string;\n cronExpr: string;\n cronTimezone: string;\n dependencyTaskId: string;\n filters: { path: string; equals: string }[];\n title: string;\n objective: string;\n /** One criterion per line. */\n criteria: string;\n priority: Priority;\n /** \"\" = project default. */\n hostId: string;\n /** \"\" = project default. */\n profileId: string;\n mode: AutomationMode;\n groupingKey: string;\n overlap: OverlapPolicy;\n missed: MissedPolicy;\n continuationEnabled: boolean;\n continuationObjective: string;\n maxContinuations: string;\n maxElapsedMinutes: string;\n maxTokens: string;\n maxCostUsd: string;\n /** One check per line; empty = project default (null). */\n checks: string;\n requireHumanReview: boolean;\n}\n\nexport function localTimezone(): string {\n try {\n return Intl.DateTimeFormat().resolvedOptions().timeZone || \"UTC\";\n } catch {\n return \"UTC\";\n }\n}\n\nexport function emptyDraft(opts: { projectId?: string; timezone?: string } = {}): AutomationDraft {\n return {\n name: \"\",\n enabled: true,\n projectId: opts.projectId ?? \"\",\n triggerKind: \"manual\",\n onceAt: \"\",\n cronExpr: \"0 9 * * 1-5\",\n cronTimezone: opts.timezone ?? localTimezone(),\n dependencyTaskId: \"\",\n filters: [],\n title: \"\",\n objective: \"\",\n criteria: \"\",\n priority: 2,\n hostId: \"\",\n profileId: \"\",\n mode: \"fresh\",\n groupingKey: \"\",\n overlap: \"skip\",\n missed: \"skip\",\n continuationEnabled: false,\n continuationObjective: \"\",\n maxContinuations: \"5\",\n maxElapsedMinutes: \"60\",\n maxTokens: \"\",\n maxCostUsd: \"\",\n checks: \"\",\n requireHumanReview: true,\n };\n}\n\n/** ISO -> datetime-local value in this browser's timezone. */\nexport function isoToLocalInput(iso: string | null | undefined): string {\n if (!iso) return \"\";\n const d = new Date(iso);\n if (Number.isNaN(d.getTime())) return \"\";\n return `${d.getFullYear()}-${pad(d.getMonth() + 1)}-${pad(d.getDate())}T${pad(d.getHours())}:${pad(d.getMinutes())}`;\n}\n\n/** datetime-local value -> ISO (interpreted as local time), or \"\" when empty/invalid. */\nexport function localInputToIso(value: string): string {\n if (!value) return \"\";\n const d = new Date(value);\n return Number.isNaN(d.getTime()) ? \"\" : d.toISOString();\n}\n\nexport function draftFromAutomation(\n a: Automation | AutomationInput,\n opts: { timezone?: string } = {},\n): AutomationDraft {\n const base = emptyDraft({ projectId: a.projectId, timezone: opts.timezone });\n const t = a.trigger;\n const c = a.continuation;\n return {\n ...base,\n name: a.name,\n enabled: a.enabled,\n triggerKind: t.kind,\n onceAt: t.kind === \"once\" ? isoToLocalInput(t.at) : \"\",\n cronExpr: t.kind === \"cron\" ? t.expr : base.cronExpr,\n cronTimezone: t.kind === \"cron\" ? t.timezone : base.cronTimezone,\n dependencyTaskId: t.kind === \"dependency\" ? t.taskId : \"\",\n filters: a.filters.map((f) => ({ ...f })),\n title: a.template.title,\n objective: a.template.objective,\n criteria: a.template.acceptanceCriteria.join(\"\\n\"),\n priority: a.template.priority,\n hostId: a.hostId ?? \"\",\n profileId: a.profileId ?? \"\",\n mode: a.mode,\n groupingKey: a.groupingKey ?? \"\",\n overlap: a.overlap,\n missed: a.missed,\n continuationEnabled: c.enabled,\n continuationObjective: c.enabled ? c.objective : \"\",\n maxContinuations: c.enabled ? String(c.maxContinuations) : base.maxContinuations,\n maxElapsedMinutes: c.enabled ? String(c.maxElapsedMinutes) : base.maxElapsedMinutes,\n maxTokens: c.enabled && c.maxTokens !== null ? String(c.maxTokens) : \"\",\n maxCostUsd: c.enabled && c.maxCostUsd !== null ? String(c.maxCostUsd) : \"\",\n checks: a.completion.checks ? a.completion.checks.join(\"\\n\") : \"\",\n requireHumanReview: a.completion.requireHumanReview,\n };\n}\n\nfunction toNumber(s: string): number {\n return s.trim() === \"\" ? Number.NaN : Number(s.trim());\n}\n\nfunction toOptionalNumber(s: string): number | null {\n return s.trim() === \"\" ? null : Number(s.trim());\n}\n\nfunction draftTrigger(d: AutomationDraft): Trigger {\n switch (d.triggerKind) {\n case \"manual\":\n return { kind: \"manual\" };\n case \"once\":\n return { kind: \"once\", at: localInputToIso(d.onceAt) };\n case \"cron\":\n return { kind: \"cron\", expr: d.cronExpr.trim(), timezone: d.cronTimezone.trim() };\n case \"webhook\":\n return { kind: \"webhook\" };\n case \"dependency\":\n return { kind: \"dependency\", taskId: d.dependencyTaskId };\n }\n}\n\n/**\n * Build the request body from a draft. The result is shaped like an\n * AutomationInput but is not validated (numbers may be NaN, strings empty);\n * run validateDraft before sending it.\n */\nexport function draftToInput(d: AutomationDraft): AutomationInput {\n const checks = lines(d.checks);\n return {\n name: d.name.trim(),\n enabled: d.enabled,\n projectId: d.projectId,\n trigger: draftTrigger(d),\n filters: d.filters\n .filter((f) => f.path.trim() || f.equals.trim())\n .map((f) => ({ path: f.path.trim(), equals: f.equals })),\n template: {\n title: d.title.trim(),\n objective: d.objective,\n acceptanceCriteria: lines(d.criteria),\n priority: d.priority,\n },\n hostId: d.hostId || null,\n profileId: d.profileId || null,\n mode: d.mode,\n groupingKey: d.groupingKey.trim() || null,\n overlap: d.overlap,\n missed: d.missed,\n continuation: d.continuationEnabled\n ? {\n enabled: true,\n objective: d.continuationObjective.trim(),\n maxContinuations: toNumber(d.maxContinuations),\n maxElapsedMinutes: toNumber(d.maxElapsedMinutes),\n maxTokens: toOptionalNumber(d.maxTokens),\n maxCostUsd: toOptionalNumber(d.maxCostUsd),\n }\n : { enabled: false },\n completion: {\n checks: checks.length > 0 ? checks : null,\n requireHumanReview: d.requireHumanReview,\n },\n };\n}\n\n/** Draft field keys that can carry an inline error. */\nexport type DraftField =\n | keyof AutomationDraft\n | `filters.${number}.path`\n | `filters.${number}.equals`\n | \"form\";\n\nexport type DraftErrors = Partial<Record<DraftField, string>>;\n\nconst PATH_TO_FIELD: Record<string, DraftField> = {\n name: \"name\",\n enabled: \"enabled\",\n projectId: \"projectId\",\n trigger: \"triggerKind\",\n \"trigger.kind\": \"triggerKind\",\n \"trigger.at\": \"onceAt\",\n \"trigger.expr\": \"cronExpr\",\n \"trigger.timezone\": \"cronTimezone\",\n \"trigger.taskId\": \"dependencyTaskId\",\n \"template.title\": \"title\",\n \"template.objective\": \"objective\",\n \"template.acceptanceCriteria\": \"criteria\",\n \"template.priority\": \"priority\",\n hostId: \"hostId\",\n profileId: \"profileId\",\n mode: \"mode\",\n groupingKey: \"groupingKey\",\n overlap: \"overlap\",\n missed: \"missed\",\n \"continuation.objective\": \"continuationObjective\",\n \"continuation.maxContinuations\": \"maxContinuations\",\n \"continuation.maxElapsedMinutes\": \"maxElapsedMinutes\",\n \"continuation.maxTokens\": \"maxTokens\",\n \"continuation.maxCostUsd\": \"maxCostUsd\",\n \"completion.checks\": \"checks\",\n \"completion.requireHumanReview\": \"requireHumanReview\",\n};\n\n/** Map a zod issue path to a draft field. */\nexport function fieldForPath(path: readonly PropertyKey[]): DraftField {\n const parts = path.map(String);\n if (parts[0] === \"filters\" && parts.length >= 3) {\n return `filters.${Number(parts[1])}.${parts[2] === \"equals\" ? \"equals\" : \"path\"}`;\n }\n if (parts[0] === \"template\" && parts[1] === \"acceptanceCriteria\") return \"criteria\";\n if (parts[0] === \"completion\" && parts[1] === \"checks\") return \"checks\";\n for (let n = parts.length; n > 0; n--) {\n const f = PATH_TO_FIELD[parts.slice(0, n).join(\".\")];\n if (f) return f;\n }\n return \"form\";\n}\n\nfunction intError(s: string, min: number, max: number, label: string): string | null {\n const n = toNumber(s);\n if (!Number.isInteger(n) || n < min || n > max) {\n return `${label} must be a whole number from ${min} to ${max}`;\n }\n return null;\n}\n\n/**\n * Validate a draft: friendly checks first (required fields, cron, timezone,\n * number ranges), then AutomationInput.safeParse for anything else.\n */\nexport function validateDraft(d: AutomationDraft): {\n input: AutomationInput | null;\n errors: DraftErrors;\n} {\n const errors: DraftErrors = {};\n const set = (f: DraftField, msg: string | null) => {\n if (msg && !errors[f]) errors[f] = msg;\n };\n if (!d.name.trim()) set(\"name\", \"Name is required\");\n if (!d.projectId) set(\"projectId\", \"Choose a project\");\n if (!d.title.trim()) set(\"title\", \"Task title is required\");\n switch (d.triggerKind) {\n case \"once\":\n if (!localInputToIso(d.onceAt)) set(\"onceAt\", \"Choose a date and time\");\n break;\n case \"cron\":\n set(\"cronExpr\", validateCron(d.cronExpr));\n set(\"cronTimezone\", validateTimezone(d.cronTimezone));\n break;\n case \"dependency\":\n if (!d.dependencyTaskId) set(\"dependencyTaskId\", \"Choose the task to wait for\");\n break;\n }\n d.filters.forEach((f, i) => {\n if (!f.path.trim() && f.equals.trim()) set(`filters.${i}.path`, \"Enter a payload path\");\n });\n if (d.mode === \"continue\" && !d.groupingKey.trim()) {\n set(\"groupingKey\", \"A grouping key is required to continue an existing task\");\n }\n if (d.continuationEnabled) {\n if (!d.continuationObjective.trim()) {\n set(\"continuationObjective\", \"An objective is required when continuation is on\");\n }\n set(\"maxContinuations\", intError(d.maxContinuations, 1, 50, \"Max continuations\"));\n set(\"maxElapsedMinutes\", intError(d.maxElapsedMinutes, 1, 1440, \"Max elapsed minutes\"));\n if (d.maxTokens.trim()) {\n const n = toNumber(d.maxTokens);\n if (!Number.isInteger(n) || n <= 0)\n set(\"maxTokens\", \"Max tokens must be a positive whole number\");\n }\n if (d.maxCostUsd.trim()) {\n const n = toNumber(d.maxCostUsd);\n if (!Number.isFinite(n) || n <= 0) set(\"maxCostUsd\", \"Max cost must be a positive amount\");\n }\n }\n const raw = draftToInput(d);\n const parsed = AutomationInput.safeParse(raw);\n if (!parsed.success) {\n for (const issue of parsed.error.issues) set(fieldForPath(issue.path), issue.message);\n }\n const ok = parsed.success && Object.keys(errors).length === 0;\n return { input: ok ? parsed.data : null, errors };\n}\n\n/* ------------------------------------------------------------------ */\n/* History */\n/* ------------------------------------------------------------------ */\n\nexport function occurrenceTime(o: Occurrence): string {\n return o.scheduledFor ?? o.createdAt;\n}\n\n/** Union by id (later lists win), newest first. */\nexport function mergeOccurrences(...lists: (Occurrence[] | undefined | null)[]): Occurrence[] {\n const byId = new Map<string, Occurrence>();\n for (const list of lists) for (const o of list ?? []) byId.set(o.id, o);\n return [...byId.values()].sort(\n (a, b) =>\n b.createdAt.localeCompare(a.createdAt) || occurrenceTime(b).localeCompare(occurrenceTime(a)),\n );\n}\n\n/** Accept `Occurrence[]` or `{items|occurrences: Occurrence[]}`. */\nexport function normalizeHistory(res: unknown): Occurrence[] {\n if (Array.isArray(res)) return res as Occurrence[];\n if (res && typeof res === \"object\") {\n const r = res as { items?: unknown; occurrences?: unknown };\n if (Array.isArray(r.items)) return r.items as Occurrence[];\n if (Array.isArray(r.occurrences)) return r.occurrences as Occurrence[];\n }\n return [];\n}\n\nexport function curlExample(token: string, url: string): string {\n return `curl -X POST -H 'Authorization: Bearer ${token}' -H 'Content-Type: application/json' -d '{}' ${url}`;\n}\n"],"mappings":"A,qLAWA,SAAgBiB,EAAa,CAAE,SAA4B,CASzD,OARIC,EAAQ,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states-BUWwUyu-.js";import{Ct as m,Dt as h,Et as g,_,ct as v}from"./index-cmIcNnnF.js";import{t as y}from"./TextLink-BpF2vLiL.js";import{a as b,c as x,i as S,l as C,n as w,o as T,r as E,s as D,t as O,u as k}from"./logic-CG2E-voG.js";var A={name:`log-in`,size:24,node:[[`path`,{d:`m10 17 5-5-5-5`,key:`1bsop3`}],[`path`,{d:`M15 12H3`,key:`6jk70r`}],[`path`,{d:`M15 3h4a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2h-4`,key:`u53s6r`}]]};A.node;var j=e(A),M=o(a(),1),N=s();function P(){let e=new URLSearchParams(location.hash.replace(/^#/,``)),t=new URLSearchParams(location.search);return e.get(`token`)??t.get(`token`)}function F(){let e=f(),[a]=d(),o=a.get(`next`),s=(0,M.useMemo)(P,[]),c=h(e=>e.status),l=h(e=>e.signedOutReason),u=(0,M.useMemo)(()=>E(),[]),[p,y]=(0,M.useState)(!1),[x,S]=(0,M.useState)(null);return(0,M.useEffect)(()=>{s&&history.replaceState(history.state,``,location.pathname+location.search)},[s]),(0,M.useEffect)(()=>{!s&&c===`authenticated`&&e(g(o),{replace:!0})},[s,c,o,e]),!s&&c===`checking`?(0,N.jsx)(r,{label:`Checking this device…`}):(0,N.jsx)(`div`,{className:`flex min-h-dvh items-start justify-center px-4 safe-pt-10 safe-pb-10 sm:items-center`,children:(0,N.jsxs)(`div`,{className:`w-full max-w-sm rounded-xl border border-border bg-surface p-5 shadow-sm`,children:[(0,N.jsxs)(`div`,{className:`mb-4 flex items-center gap-3`,children:[(0,N.jsx)(`img`,{src:`/icon.svg`,alt:``,className:`size-10 rounded-lg`}),(0,N.jsxs)(`div`,{children:[(0,N.jsx)(`h1`,{className:`text-lg font-semibold`,children:`Switchyard`}),(0,N.jsx)(`p`,{className:`text-sm text-muted`,children:s?`Sign in this browser`:`Sign in`})]})]}),l&&(0,N.jsx)(`p`,{role:`status`,className:`mb-3 rounded-md bg-warning-soft px-3 py-2 text-sm`,children:l}),s?(0,N.jsxs)(`form`,{onSubmit:async r=>{if(r.preventDefault(),s){y(!0),S(null);try{await n(`/api/enroll`,{token:s,name:u.slice(0,80),kind:_()?`pwa`:`browser`}),await m()===`authenticated`?e(g(o),{replace:!0}):S({code:`internal`,message:`Signed in, but the coordinator did not accept the new credential. Try again.`})}catch(e){let n=t(e)?e.code:`internal`;S({code:n,message:O[n]??(e instanceof Error?e.message:String(e))})}finally{y(!1)}}},className:`flex flex-col gap-3`,noValidate:!0,children:[(0,N.jsxs)(`p`,{className:`text-sm`,children:[`This single-use link signs in this browser as “`,u,`”. You can rename it in Settings › Clients.`]}),x&&(0,N.jsxs)(`div`,{role:`alert`,className:`rounded-md border border-border bg-danger-soft px-3 py-2 text-sm`,children:[(0,N.jsx)(`div`,{className:`font-medium`,children:b(x.code)}),(0,N.jsx)(`div`,{className:`text-muted`,children:x.message})]}),(0,N.jsx)(i,{type:`submit`,variant:`primary`,"data-testid":`signin-link`,busy:p,disabled:x?.code===`enrollment_expired`||x?.code===`enrollment_used`,icon:(0,N.jsx)(v,{className:`size-4`}),children:`Sign in`})]}):(0,N.jsx)(R,{next:o})]})})}var I=()=>_()?`pwa`:`browser`;function L({title:e,children:t}){return(0,N.jsxs)(`div`,{role:`alert`,className:`rounded-md border border-border bg-danger-soft px-3 py-2 text-sm`,children:[(0,N.jsxs)(`div`,{className:`flex items-center gap-1.5 font-medium`,children:[(0,N.jsx)(p,{"aria-hidden":!0,className:`size-4 shrink-0`}),e]}),(0,N.jsx)(`div`,{className:`break-words text-muted`,children:t})]})}function R({next:e}){let a=f(),o=(0,M.useMemo)(()=>E().slice(0,80),[]),[s,p]=d(),[h,y]=(0,M.useState)(null),[b,x]=(0,M.useState)(null),[w,T]=(0,M.useState)(0),[D,O]=(0,M.useState)(null),[A,P]=(0,M.useState)(()=>{let e=s.get(`error`);return e?{code:e,message:S(e,s.get(`detail`))}:null}),[F,R]=(0,M.useState)(null),B=(0,M.useRef)(null),V=C();(0,M.useEffect)(()=>{if(!s.has(`error`)&&!s.has(`detail`))return;let e=new URLSearchParams(s);e.delete(`error`),e.delete(`detail`),p(e,{replace:!0})},[]),(0,M.useEffect)(()=>{let e=new AbortController;return x(null),u(`/api/setup`,void 0,e.signal).then(t=>!e.signal.aborted&&y(t)).catch(t=>!e.signal.aborted&&x(t)),()=>e.abort()},[w]);let H=e=>{let n=t(e)?e.code:`internal`;e instanceof Error&&e.name===`NotAllowedError`?P({code:n,message:`Passkey sign-in was canceled or timed out.`}):P({code:n,message:t(e)?S(n,e.message):e instanceof Error?e.message:String(e)})},U=(0,M.useCallback)(async()=>{await m()===`authenticated`?a(g(e),{replace:!0}):P({code:`internal`,message:`Signed in, but the coordinator did not accept the new credential. Try again.`})},[a,e]),W=async()=>{O(`passkey`),P(null);try{let{challengeId:e,options:t}=await n(`/api/auth/passkey/options`),r=await V.run(()=>k({optionsJSON:t}));if(!r.ok){P({code:`canceled`,message:`Passkey sign-in was canceled.`});return}let i=r.value;await n(`/api/auth/passkey/verify`,{challengeId:e,response:i,deviceName:o,kind:I()}),await U()}catch(e){H(e)}finally{O(null)}},G=async()=>{O(`oidc`),P(null);let t=_();try{let r=await n(`/api/auth/oidc/begin`,{deviceName:o,kind:I(),next:g(e),handoff:t});if(t&&r.flowId&&r.pollToken)B.current=r.authorizeUrl,R({flowId:r.flowId,pollToken:r.pollToken}),window.open(r.authorizeUrl,`_blank`);else{location.assign(r.authorizeUrl);return}}catch(e){H(e)}O(null)};if(b)return(0,N.jsx)(c,{title:`Cannot reach Switchyard`,error:b,onRetry:()=>T(e=>e+1)});if(!h)return(0,N.jsx)(r,{label:`Checking this server…`});if(F)return(0,N.jsx)(z,{flowId:F.flowId,pollToken:F.pollToken,authorizeUrl:B.current,onDone:U,onExit:()=>R(null)});let K=h.passkey.registered&&h.passkey.available;return(0,N.jsxs)(`div`,{className:`flex flex-col gap-4 text-sm`,children:[(0,N.jsx)(`p`,{className:`text-base font-medium`,children:`Sign in to Switchyard`}),A&&(0,N.jsx)(L,{title:`Sign-in failed`,children:A.message}),(0,N.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[h.oidc&&(0,N.jsx)(i,{"data-testid":`signin-oidc`,variant:`primary`,busy:D===`oidc`,disabled:D!==null,icon:(0,N.jsx)(j,{className:`size-4`}),onClick:G,children:h.oidc.label}),K&&(0,N.jsx)(i,{"data-testid":`signin-passkey`,variant:h.oidc?`secondary`:`primary`,busy:D===`passkey`,disabled:D!==null,icon:(0,N.jsx)(v,{className:`size-4`}),onClick:W,children:`Sign in with a passkey`}),V.waiting&&(0,N.jsxs)(`div`,{role:`status`,className:`flex items-center gap-2 text-sm text-muted`,children:[(0,N.jsx)(l,{}),(0,N.jsx)(`span`,{className:`flex-1`,children:`Waiting for your passkey…`}),(0,N.jsx)(i,{size:`sm`,variant:`ghost`,onClick:V.cancel,children:`Cancel`})]}),h.passkey.registered&&!h.passkey.available&&h.passkey.reason&&(0,N.jsxs)(`p`,{className:`text-xs text-muted`,children:[`Passkeys are unavailable: `,h.passkey.reason,`.`]})]}),!h.oidc&&!K?(0,N.jsxs)(`p`,{"data-testid":`signin-pair-hint`,className:`text-muted`,children:[`No sign-in method is set up. On the machine running Switchyard, run`,` `,(0,N.jsx)(`code`,{children:`switchyard pair`}),` for a single-use sign-in link.`]}):(0,N.jsxs)(`p`,{className:`text-xs text-muted`,children:[`Locked out? Run `,(0,N.jsx)(`code`,{children:`switchyard pair`}),` on the server for a single-use sign-in link.`]})]})}function z({flowId:e,pollToken:r,authorizeUrl:a,onDone:o,onExit:s}){let[c,l]=(0,M.useState)(()=>x(Date.now())),u=(0,M.useRef)(c);u.current=c;let d=(0,M.useRef)(!1),f=(0,M.useRef)(o);f.current=o;let p=(0,M.useCallback)(e=>{let t=T(u.current,e);return u.current=t,l(t),t},[]),m=(0,M.useCallback)(async()=>{if(!(d.current||u.current.phase!==`waiting`)){d.current=!0;try{let t=await n(`/api/auth/oidc/claim`,{flowId:e,pollToken:r});p({type:`claim`,result:t,now:Date.now()}).phase===`done`&&await f.current()}catch(e){p({type:`claim_error`,code:t(e)?e.code:`network`,message:`This sign-in expired or was already used. Start again.`,now:Date.now()})}finally{d.current=!1}}},[e,r,p]);return(0,M.useEffect)(()=>{let e=()=>document.visibilityState===`visible`,t=setInterval(()=>{p({type:`tick`,now:Date.now()}),D(u.current,e())&&m()},w),n=()=>{D(u.current,e())&&m()};return document.addEventListener(`visibilitychange`,n),()=>{clearInterval(t),document.removeEventListener(`visibilitychange`,n)}},[m,p]),c.phase===`timeout`||c.phase===`failed`||c.phase===`canceled`?(0,N.jsxs)(`div`,{"data-testid":`signin-handoff`,className:`flex flex-col gap-3 text-sm`,children:[(0,N.jsx)(L,{title:c.phase===`timeout`?`Sign-in timed out`:`Sign-in stopped`,children:c.phase===`timeout`?`The sign-in was not finished in time. Start again.`:c.message??`Start again.`}),(0,N.jsx)(i,{onClick:s,children:`Back to sign-in`})]}):(0,N.jsxs)(`div`,{"data-testid":`signin-handoff`,role:`status`,className:`flex flex-col gap-3 text-sm`,children:[(0,N.jsx)(`p`,{className:`font-medium`,children:`Finish signing in, then come back here`}),(0,N.jsx)(`p`,{className:`text-muted`,children:`Complete single sign-on in the page that opened, then return to this app. This screen continues on its own.`}),a&&(0,N.jsx)(y,{href:a,external:!0,children:`Open the sign-in page again`}),(0,N.jsx)(i,{onClick:()=>{p({type:`cancel`}),s()},children:`Cancel`})]})}export{F as default,E as defaultDeviceName};
|
|
2
|
-
//# sourceMappingURL=enroll-CV77Sk6h.js.map
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */
|
|
2
|
-
@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{--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-pan-x:initial;--tw-pan-y:initial;--tw-pinch-zoom: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-duration:initial;--tw-ease:initial;--tw-content:""}::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-pan-x:initial;--tw-pan-y:initial;--tw-pinch-zoom: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-duration:initial;--tw-ease:initial;--tw-content:""}}}@layer theme{:root,:host{--font-sans:system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;--font-mono:ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;--color-black:#000;--color-white:#fff;--spacing:.25rem;--container-sm:24rem;--container-md:28rem;--container-lg:32rem;--container-xl:36rem;--container-2xl:42rem;--container-3xl:48rem;--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:calc(1.5 / 1);--text-lg:1.125rem;--text-lg--line-height:calc(1.75 / 1.125);--font-weight-normal:400;--font-weight-medium:500;--font-weight-semibold:600;--tracking-wide:.025em;--tracking-widest:.1em;--leading-tight:1.25;--leading-snug:1.375;--radius-sm:.25rem;--radius-md:.375rem;--radius-lg:.5rem;--radius-xl:.75rem;--radius-2xl:1rem;--ease-out:cubic-bezier(0, 0, .2, 1);--animate-spin:spin 1.4s linear infinite;--animate-pulse:pulse 2s cubic-bezier(.4, 0, .6, 1) infinite;--default-transition-duration:.15s;--default-transition-timing-function:cubic-bezier(.4, 0, .2, 1);--default-font-family:system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;--default-mono-font-family:ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;--color-accent:var(--sy-accent)}}@layer base{*,:after,:before{box-sizing:border-box;border:0 solid;margin:0;padding:0}::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%;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;-webkit-text-decoration:inherit;-webkit-text-decoration: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]){appearance:button}::file-selector-button{appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}html{-webkit-tap-highlight-color:transparent;-webkit-text-size-adjust:100%;-moz-text-size-adjust:100%;text-size-adjust:100%}html,body{background:var(--sy-bg);color:var(--sy-text);font-family:var(--font-sans);overscroll-behavior:none;overflow-x:clip}body{-webkit-font-smoothing:antialiased;min-height:100dvh;margin:0;line-height:1.5}#root{min-width:0;min-height:100dvh}:focus-visible{outline:2px solid var(--sy-focus);outline-offset:2px}code,pre,kbd,samp{font-family:var(--font-mono)}button,[role=button]{cursor:pointer}button:disabled,[aria-disabled=true]{cursor:not-allowed}}@layer components{@media (pointer:coarse){.tap{min-width:44px;min-height:44px}}.sy-prose{overflow-wrap:anywhere;min-width:0}.sy-prose>*+*{margin-top:.6em}.sy-prose h1,.sy-prose h2,.sy-prose h3,.sy-prose h4{margin-top:1em;font-weight:600;line-height:1.3}.sy-prose h1{font-size:1.25rem}.sy-prose h2{font-size:1.125rem}.sy-prose h3,.sy-prose h4{font-size:1rem}.sy-prose ul{padding-left:1.4em;list-style:outside}.sy-prose ol{padding-left:1.4em;list-style:decimal}.sy-prose a{color:var(--sy-accent);text-underline-offset:2px;text-decoration:underline}.sy-prose blockquote{border-left:3px solid var(--sy-border-strong);color:var(--sy-muted);padding-left:.75em}.sy-prose :not(pre)>code{background:var(--sy-surface-2);border:1px solid var(--sy-border);border-radius:4px;padding:0 .3em;font-size:.875em}.sy-prose hr{border-color:var(--sy-border)}.sy-prose input[type=checkbox]{margin-right:.4em}.sy-pressable{transition:transform .22s cubic-bezier(.2,.8,.2,1)}.sy-pressable[data-pressing]{transition-duration:.32s;transform:scale(.97)}.sy-pressable.sy-press-row[data-pressing]{background-color:var(--sy-surface-2);transform:none}.sy-sheet-in{animation:.26s cubic-bezier(.32,.72,0,1) sy-sheet-in}.sy-drawer-in{animation:.24s cubic-bezier(.32,.72,0,1) sy-drawer-in}.sy-pop-in{animation:.16s ease-out sy-pop-in}.sy-fade-in{animation:.2s ease-out sy-fade-in}.sy-slide-from-right{animation:.18s ease-out sy-slide-from-right}.sy-slide-from-left{animation:.18s ease-out sy-slide-from-left}.sy-prose-compact{font-size:.875rem;line-height:1.5rem}@media (min-width:768px){.sy-prose-compact{font-size:15px}}.sy-prose-compact>*+*{margin-top:.5em}.sy-prose-compact h1{font-size:1.0625rem}.sy-prose-compact h2{font-size:1rem}.sy-prose-compact h2[data-active=true]{background:var(--sy-accent-soft);box-shadow:inset 3px 0 0 var(--sy-accent);border-radius:.375rem;margin-left:-.5rem;padding:.15em .5rem}.sy-prose-compact h3,.sy-prose-compact h4{font-size:.9375rem}.sy-prose-compact h1,.sy-prose-compact h2,.sy-prose-compact h3,.sy-prose-compact h4{margin-top:1.1em;font-weight:600}.sy-prose-compact ul,.sy-prose-compact ol{padding-left:1.2em}.sy-code span[style]{color:var(--shiki-light)}@media (prefers-color-scheme:dark){.sy-code span[style]{color:var(--shiki-dark)}}}@layer utilities{.\@container{container-type:inline-size}.pointer-events-auto{pointer-events:auto}.pointer-events-none{pointer-events:none}.collapse{visibility:collapse}.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}.\!fixed{position:fixed!important}.absolute{position:absolute}.fixed{position:fixed}.relative{position:relative}.static{position:static}.sticky{position:sticky}.inset-0{inset:0}.inset-x-0{inset-inline:0}.inset-x-2{inset-inline:calc(var(--spacing) * 2)}.inset-y-0{inset-block:0}.inset-y-0\.5{inset-block:calc(var(--spacing) * .5)}.-top-0\.5{top:calc(var(--spacing) * -.5)}.-top-1\.5{top:calc(var(--spacing) * -1.5)}.top-0{top:0}.top-0\.5{top:calc(var(--spacing) * .5)}.top-1{top:var(--spacing)}.top-1\/2{top:50%}.top-2{top:calc(var(--spacing) * 2)}.top-16{top:calc(var(--spacing) * 16)}.top-\[calc\(var\(--safe-top\)\+0\.5rem\)\]{top:calc(var(--safe-top) + .5rem)}.top-full{top:100%}.right-0{right:0}.right-1{right:var(--spacing)}.right-2{right:calc(var(--spacing) * 2)}.-bottom-3{bottom:calc(var(--spacing) * -3)}.-bottom-px{bottom:-1px}.bottom-0{bottom:0}.bottom-3{bottom:calc(var(--spacing) * 3)}.bottom-full{bottom:100%}.left-0{left:0}.left-1\/2{left:50%}.left-2{left:calc(var(--spacing) * 2)}.left-2\.5{left:calc(var(--spacing) * 2.5)}.left-3{left:calc(var(--spacing) * 3)}.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}.z-\[60\]{z-index:60}.z-\[70\]{z-index:70}.col-start-1{grid-column-start:1}.row-start-2{grid-row-start:2}.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}.-mx-4{margin-inline:calc(var(--spacing) * -4)}.mx-4{margin-inline:calc(var(--spacing) * 4)}.mx-auto{margin-inline:auto}.-my-2\.5{margin-block:calc(var(--spacing) * -2.5)}.my-1{margin-block:var(--spacing)}.-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-6{margin-top:calc(var(--spacing) * 6)}.mt-px{margin-top:1px}.-mr-1{margin-right:calc(var(--spacing) * -1)}.-mr-1\.5{margin-right:calc(var(--spacing) * -1.5)}.mr-2{margin-right:calc(var(--spacing) * 2)}.mr-4{margin-right:calc(var(--spacing) * 4)}.mr-auto{margin-right:auto}.-mb-px{margin-bottom:-1px}.mb-1{margin-bottom:var(--spacing)}.mb-2{margin-bottom:calc(var(--spacing) * 2)}.mb-3{margin-bottom:calc(var(--spacing) * 3)}.mb-4{margin-bottom:calc(var(--spacing) * 4)}.-ml-1\.5{margin-left:calc(var(--spacing) * -1.5)}.-ml-2{margin-left:calc(var(--spacing) * -2)}.-ml-px{margin-left:-1px}.ml-1{margin-left:var(--spacing)}.ml-1\.5{margin-left:calc(var(--spacing) * 1.5)}.ml-2{margin-left:calc(var(--spacing) * 2)}.ml-2\.5{margin-left:calc(var(--spacing) * 2.5)}.ml-auto{margin-left:auto}.line-clamp-2{-webkit-line-clamp:2;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.line-clamp-6{-webkit-line-clamp:6;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.line-clamp-8{-webkit-line-clamp:8;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.\!block{display:block!important}.block{display:block}.contents{display:contents}.flex{display:flex}.grid{display:grid}.hidden{display:none}.inline{display:inline}.inline-flex{display:inline-flex}.table{display:table}.size-1\.5{width:calc(var(--spacing) * 1.5);height:calc(var(--spacing) * 1.5)}.size-2{width:calc(var(--spacing) * 2);height:calc(var(--spacing) * 2)}.size-2\.5{width:calc(var(--spacing) * 2.5);height:calc(var(--spacing) * 2.5)}.size-3{width:calc(var(--spacing) * 3);height:calc(var(--spacing) * 3)}.size-3\.5{width:calc(var(--spacing) * 3.5);height:calc(var(--spacing) * 3.5)}.size-4{width:calc(var(--spacing) * 4);height:calc(var(--spacing) * 4)}.size-5{width:calc(var(--spacing) * 5);height:calc(var(--spacing) * 5)}.size-6{width:calc(var(--spacing) * 6);height:calc(var(--spacing) * 6)}.size-7{width:calc(var(--spacing) * 7);height:calc(var(--spacing) * 7)}.size-8{width:calc(var(--spacing) * 8);height:calc(var(--spacing) * 8)}.size-9{width:calc(var(--spacing) * 9);height:calc(var(--spacing) * 9)}.size-10{width:calc(var(--spacing) * 10);height:calc(var(--spacing) * 10)}.size-11{width:calc(var(--spacing) * 11);height:calc(var(--spacing) * 11)}.h-0\.5{height:calc(var(--spacing) * .5)}.h-1{height:var(--spacing)}.h-1\.5{height:calc(var(--spacing) * 1.5)}.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-13{height:calc(var(--spacing) * 13)}.h-14{height:calc(var(--spacing) * 14)}.h-auto{height:auto}.h-auto\!{height:auto!important}.h-dvh{height:100dvh}.h-full{height:100%}.h-px{height:1px}.max-h-48{max-height:calc(var(--spacing) * 48)}.max-h-52{max-height:calc(var(--spacing) * 52)}.max-h-56{max-height:calc(var(--spacing) * 56)}.max-h-64{max-height:calc(var(--spacing) * 64)}.max-h-72{max-height:calc(var(--spacing) * 72)}.max-h-80{max-height:calc(var(--spacing) * 80)}.max-h-\[45dvh\]{max-height:45dvh}.max-h-\[60vh\]{max-height:60vh}.max-h-\[85dvh\]{max-height:85dvh}.max-h-\[90dvh\]{max-height:90dvh}.max-h-\[calc\(100dvh-2rem\)\]{max-height:calc(100dvh - 2rem)}.max-h-\[min\(28rem\,calc\(100dvh-8rem\)\)\]{max-height:min(28rem,100dvh - 8rem)}.max-h-\[min\(90dvh\,720px\)\]{max-height:min(90dvh,720px)}.max-h-dvh{max-height:100dvh}.min-h-0{min-height:0}.min-h-4{min-height:calc(var(--spacing) * 4)}.min-h-8{min-height:calc(var(--spacing) * 8)}.min-h-9{min-height:calc(var(--spacing) * 9)}.min-h-11{min-height:calc(var(--spacing) * 11)}.min-h-12{min-height:calc(var(--spacing) * 12)}.min-h-14{min-height:calc(var(--spacing) * 14)}.min-h-40{min-height:calc(var(--spacing) * 40)}.min-h-dvh{min-height:100dvh}.min-h-full{min-height:100%}.w-1\.5{width:calc(var(--spacing) * 1.5)}.w-5{width:calc(var(--spacing) * 5)}.w-8{width:calc(var(--spacing) * 8)}.w-9{width:calc(var(--spacing) * 9)}.w-10{width:calc(var(--spacing) * 10)}.w-52{width:calc(var(--spacing) * 52)}.w-56{width:calc(var(--spacing) * 56)}.w-60{width:calc(var(--spacing) * 60)}.w-72{width:calc(var(--spacing) * 72)}.w-96{width:calc(var(--spacing) * 96)}.w-\[6\.25rem\]{width:6.25rem}.w-auto{width:auto}.w-fit{width:-moz-fit-content;width:fit-content}.w-full{width:100%}.w-max{width:max-content}.w-px{width:1px}.max-w-2xl{max-width:var(--container-2xl)}.max-w-3xl{max-width:var(--container-3xl)}.max-w-24{max-width:calc(var(--spacing) * 24)}.max-w-32{max-width:calc(var(--spacing) * 32)}.max-w-44{max-width:calc(var(--spacing) * 44)}.max-w-56{max-width:calc(var(--spacing) * 56)}.max-w-64{max-width:calc(var(--spacing) * 64)}.max-w-\[16rem\]{max-width:16rem}.max-w-\[45\%\]{max-width:45%}.max-w-\[60vw\]{max-width:60vw}.max-w-\[80ch\]{max-width:80ch}.max-w-\[85\%\]{max-width:85%}.max-w-\[calc\(100\%-8px\)\]{max-width:calc(100% - 8px)}.max-w-\[calc\(100vw-1rem\)\]{max-width:calc(100vw - 1rem)}.max-w-\[min\(20rem\,calc\(100vw-1rem\)\)\]{max-width:min(20rem,100vw - 1rem)}.max-w-full{max-width:100%}.max-w-lg{max-width:var(--container-lg)}.max-w-md{max-width:var(--container-md)}.max-w-sm{max-width:var(--container-sm)}.max-w-xl{max-width:var(--container-xl)}.min-w-0{min-width:0}.min-w-5{min-width:calc(var(--spacing) * 5)}.min-w-6{min-width:calc(var(--spacing) * 6)}.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-\[6\.25rem\]{min-width:6.25rem}.min-w-full{min-width:100%}.flex-1{flex:1}.flex-\[1_1_10rem\]{flex:10rem}.flex-\[1_1_12rem\]{flex:12rem}.flex-\[1_1_14rem\]{flex:14rem}.flex-\[1_1_15rem\]{flex:15rem}.flex-\[1_1_16rem\]{flex:16rem}.shrink{flex-shrink:1}.shrink-0{flex-shrink:0}.grow{flex-grow:1}.basis-0{flex-basis:0}.basis-48{flex-basis:calc(var(--spacing) * 48)}.basis-full{flex-basis:100%}.border-collapse{border-collapse:collapse}.-translate-x-1\/2{--tw-translate-x:calc(calc(1 / 2 * 100%) * -1);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-1{--tw-translate-x:var(--spacing);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)}.translate-x-\[18px\]{--tw-translate-x:18px;translate:var(--tw-translate-x) var(--tw-translate-y)}.-translate-y-1\/2{--tw-translate-y:calc(calc(1 / 2 * 100%) * -1);translate:var(--tw-translate-x) var(--tw-translate-y)}.-rotate-90{rotate:-90deg}.rotate-1{rotate:1deg}.rotate-90{rotate:90deg}.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)}.animate-spin{animation:var(--animate-spin)}.cursor-col-resize{cursor:col-resize}.cursor-grab{cursor:grab}.cursor-not-allowed{cursor:not-allowed}.cursor-pointer{cursor:pointer}.cursor-row-resize{cursor:row-resize}.touch-pan-y{--tw-pan-y:pan-y;touch-action:var(--tw-pan-x,) var(--tw-pan-y,) var(--tw-pinch-zoom,)}.touch-none{touch-action:none}.resize{resize:both}.resize-none{resize:none}.scroll-mt-14{scroll-margin-top:calc(var(--spacing) * 14)}.scroll-mt-16{scroll-margin-top:calc(var(--spacing) * 16)}.scroll-ml-\[6\.25rem\]{scroll-margin-left:6.25rem}.\[scrollbar-width\:none\]{scrollbar-width:none}.list-decimal{list-style-type:decimal}.list-disc{list-style-type:disc}.list-none{list-style-type:none}.appearance-none{appearance:none}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.grid-cols-\[auto_1fr\]{grid-template-columns:auto 1fr}.grid-cols-\[auto_minmax\(0\,1fr\)\]{grid-template-columns:auto minmax(0,1fr)}.grid-cols-\[minmax\(0\,1fr\)_auto\]{grid-template-columns:minmax(0,1fr) auto}.grid-cols-\[minmax\(0\,1fr\)_minmax\(320px\,400px\)\]{grid-template-columns:minmax(0,1fr) minmax(320px,400px)}.grid-cols-\[minmax\(0\,2\.4fr\)_minmax\(0\,1fr\)_5\.5rem_minmax\(0\,1\.2fr\)_minmax\(0\,1\.4fr\)_7\.5rem_7rem_auto\]{grid-template-columns:minmax(0,2.4fr) minmax(0,1fr) 5.5rem minmax(0,1.2fr) minmax(0,1.4fr) 7.5rem 7rem auto}.grid-cols-\[minmax\(7rem\,auto\)_1fr\]{grid-template-columns:minmax(7rem,auto) 1fr}.grid-cols-\[repeat\(auto-fit\,minmax\(11rem\,1fr\)\)\]{grid-template-columns:repeat(auto-fit,minmax(11rem,1fr))}.flex-col{flex-direction:column}.flex-row{flex-direction:row}.flex-wrap{flex-wrap:wrap}.items-baseline{align-items:baseline}.items-center{align-items:center}.items-end{align-items:flex-end}.items-start{align-items:flex-start}.justify-between{justify-content:space-between}.justify-center{justify-content:center}.justify-end{justify-content:flex-end}.justify-start{justify-content:flex-start}.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-3{gap:calc(var(--spacing) * 3)}.gap-4{gap:calc(var(--spacing) * 4)}.gap-5{gap:calc(var(--spacing) * 5)}: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-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)))}.gap-x-1\.5{column-gap:calc(var(--spacing) * 1.5)}.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-x-5{column-gap:calc(var(--spacing) * 5)}.gap-y-0\.5{row-gap:calc(var(--spacing) * .5)}.gap-y-1{row-gap:var(--spacing)}.gap-y-2{row-gap:calc(var(--spacing) * 2)}: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(--sy-border)}.self-center{align-self:center}.self-start{align-self:flex-start}.self-stretch{align-self:stretch}.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-clip{overflow-x:clip}.overflow-x-hidden{overflow-x:hidden}.overflow-y-auto{overflow-y:auto}.overflow-y-hidden{overflow-y:hidden}.overscroll-contain{overscroll-behavior:contain}.overscroll-x-contain{overscroll-behavior-x:contain}.overscroll-y-contain{overscroll-behavior-y:contain}.rounded{border-radius:.25rem}.rounded-2xl{border-radius:var(--radius-2xl)}.rounded-full{border-radius:2147483647px}.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-lg{border-top-left-radius:var(--radius-lg);border-top-right-radius:var(--radius-lg)}.rounded-t-xl{border-top-left-radius:var(--radius-xl);border-top-right-radius:var(--radius-xl)}.border{border-style:var(--tw-border-style);border-width:1px}.border-y{border-block-style:var(--tw-border-style);border-block-width:1px}.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-0{border-bottom-style:var(--tw-border-style);border-bottom-width:0}.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-l-2{border-left-style:var(--tw-border-style);border-left-width:2px}.border-dashed{--tw-border-style:dashed;border-style:dashed}.border-accent{border-color:var(--sy-accent)}.border-border{border-color:var(--sy-border)}.border-border-strong{border-color:var(--sy-border-strong)}.border-danger,.border-danger\/50{border-color:var(--sy-danger)}@supports (color:color-mix(in lab, red, red)){.border-danger\/50{border-color:color-mix(in oklab, var(--sy-danger) 50%, transparent)}}.border-info{border-color:var(--sy-info)}.border-success{border-color:var(--sy-success)}.border-transparent{border-color:#0000}.border-warning{border-color:var(--sy-warning)}.bg-\[\#6e7681\]{background-color:#6e7681}.bg-\[\#30a46c\]{background-color:#30a46c}.bg-\[\#0090ff\]{background-color:#0090ff}.bg-\[\#e5484d\]{background-color:#e5484d}.bg-\[\#f76b15\]{background-color:#f76b15}.bg-accent{background-color:var(--sy-accent)}.bg-accent-fg{background-color:var(--sy-accent-fg)}.bg-accent-soft{background-color:var(--sy-accent-soft)}.bg-bg{background-color:var(--sy-bg)}.bg-black{background-color:var(--color-black)}.bg-border{background-color:var(--sy-border)}.bg-border-strong{background-color:var(--sy-border-strong)}.bg-danger{background-color:var(--sy-danger)}.bg-danger-soft{background-color:var(--sy-danger-soft)}.bg-diff-add{background-color:var(--sy-diff-add)}.bg-diff-del{background-color:var(--sy-diff-del)}.bg-diff-hunk{background-color:var(--sy-diff-hunk)}.bg-info-soft{background-color:var(--sy-info-soft)}.bg-muted{background-color:var(--sy-muted)}.bg-overlay{background-color:var(--sy-overlay)}.bg-subtle{background-color:var(--sy-subtle)}.bg-success{background-color:var(--sy-success)}.bg-success-soft{background-color:var(--sy-success-soft)}.bg-surface{background-color:var(--sy-surface)}.bg-surface-2{background-color:var(--sy-surface-2)}.bg-surface-3{background-color:var(--sy-surface-3)}.bg-transparent{background-color:#0000}.bg-warning{background-color:var(--sy-warning)}.bg-warning-soft{background-color:var(--sy-warning-soft)}.bg-white{background-color:var(--color-white)}.bg-\[conic-gradient\(var\(--sy-surface-2\)_25\%\,var\(--sy-surface\)_0_50\%\,var\(--sy-surface-2\)_0_75\%\,var\(--sy-surface\)_0\)\]{background-image:conic-gradient(var(--sy-surface-2) 25%,var(--sy-surface) 0 50%,var(--sy-surface-2) 0 75%,var(--sy-surface) 0)}.bg-\[length\:16px_16px\]{background-size:16px 16px}.fill-current{fill:currentColor}.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-2\.5{padding:calc(var(--spacing) * 2.5)}.p-3{padding:calc(var(--spacing) * 3)}.p-4{padding:calc(var(--spacing) * 4)}.p-5{padding:calc(var(--spacing) * 5)}.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-6{padding-inline:calc(var(--spacing) * 6)}.px-7{padding-inline:calc(var(--spacing) * 7)}.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-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-16{padding-top:calc(var(--spacing) * 16)}.safe-pt{padding-top:var(--safe-top)}.safe-pt-1{padding-top:calc(var(--spacing) * 1 + var(--safe-top))}.safe-pt-1\.5{padding-top:calc(var(--spacing) * 1.5 + var(--safe-top))}.safe-pt-4{padding-top:calc(var(--spacing) * 4 + var(--safe-top))}.safe-pt-10{padding-top:calc(var(--spacing) * 10 + var(--safe-top))}.safe-px{padding-left:var(--safe-left);padding-right:var(--safe-right)}.pr-1{padding-right:var(--spacing)}.pr-1\.5{padding-right:calc(var(--spacing) * 1.5)}.pr-2{padding-right:calc(var(--spacing) * 2)}.pr-3{padding-right:calc(var(--spacing) * 3)}.pr-4{padding-right:calc(var(--spacing) * 4)}.pr-5{padding-right:calc(var(--spacing) * 5)}.pr-6{padding-right:calc(var(--spacing) * 6)}.pr-7{padding-right:calc(var(--spacing) * 7)}.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-3{padding-bottom:calc(var(--spacing) * 3)}.pb-4{padding-bottom:calc(var(--spacing) * 4)}.pb-8{padding-bottom:calc(var(--spacing) * 8)}.pb-\[calc\(var\(--safe-bottom\)\+0\.5rem\)\]{padding-bottom:calc(var(--safe-bottom) + .5rem)}.safe-pb{padding-bottom:var(--safe-bottom)}.safe-pb-2{padding-bottom:calc(var(--spacing) * 2 + var(--safe-bottom))}.safe-pb-10{padding-bottom:calc(var(--spacing) * 10 + var(--safe-bottom))}.pl-1{padding-left:var(--spacing)}.pl-2{padding-left:calc(var(--spacing) * 2)}.pl-3{padding-left:calc(var(--spacing) * 3)}.pl-4{padding-left:calc(var(--spacing) * 4)}.pl-5{padding-left:calc(var(--spacing) * 5)}.pl-6{padding-left:calc(var(--spacing) * 6)}.pl-7{padding-left:calc(var(--spacing) * 7)}.pl-8{padding-left:calc(var(--spacing) * 8)}.pl-9{padding-left:calc(var(--spacing) * 9)}.pl-11{padding-left:calc(var(--spacing) * 11)}.text-center{text-align:center}.text-left{text-align:left}.text-right{text-align:right}.align-top{vertical-align:top}.font-mono{font-family:ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace}.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-xs{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}.text-\[11px\]{font-size:11px}.text-\[13px\]{font-size:13px}.text-\[15px\]{font-size:15px}.leading-4{--tw-leading:calc(var(--spacing) * 4);line-height:calc(var(--spacing) * 4)}.leading-5{--tw-leading:calc(var(--spacing) * 5);line-height:calc(var(--spacing) * 5)}.leading-6{--tw-leading:calc(var(--spacing) * 6);line-height:calc(var(--spacing) * 6)}.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-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-wide{--tw-tracking:var(--tracking-wide);letter-spacing:var(--tracking-wide)}.tracking-widest{--tw-tracking:var(--tracking-widest);letter-spacing:var(--tracking-widest)}.break-words{overflow-wrap:break-word}.break-all{word-break:break-all}.whitespace-normal{white-space:normal}.whitespace-normal\!{white-space:normal!important}.whitespace-nowrap{white-space:nowrap}.whitespace-pre{white-space:pre}.whitespace-pre-line{white-space:pre-line}.whitespace-pre-wrap{white-space:pre-wrap}.text-accent{color:var(--sy-accent)}.text-accent-fg{color:var(--sy-accent-fg)}.text-danger{color:var(--sy-danger)}.text-danger-fg{color:var(--sy-danger-fg)}.text-info{color:var(--sy-info)}.text-inherit{color:inherit}.text-muted{color:var(--sy-muted)}.text-subtle{color:var(--sy-subtle)}.text-success{color:var(--sy-success)}.text-text{color:var(--sy-text)}.text-warning{color:var(--sy-warning)}.text-white{color:var(--color-white)}.capitalize{text-transform:capitalize}.uppercase{text-transform:uppercase}.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}.underline-offset-2{text-underline-offset:2px}.accent-\[var\(--color-accent\)\]{accent-color:var(--color-accent)}.accent-\[var\(--sy-accent\)\]{accent-color:var(--sy-accent)}.opacity-0{opacity:0}.opacity-40{opacity:.4}.opacity-50{opacity:.5}.opacity-60{opacity:.6}.opacity-70{opacity:.7}.opacity-100{opacity:1}.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-pop{--tw-shadow:var(--sy-shadow);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 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)}.ring{--tw-ring-shadow:var(--tw-ring-inset,) 0 0 0 calc(1px + 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-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-4{--tw-ring-shadow:var(--tw-ring-inset,) 0 0 0 calc(4px + 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-accent{--tw-ring-color:var(--sy-accent)}.ring-accent-soft{--tw-ring-color:var(--sy-accent-soft)}.ring-offset-2{--tw-ring-offset-width:2px;--tw-ring-offset-shadow:var(--tw-ring-inset,) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)}.ring-offset-bg{--tw-ring-offset-color:var(--sy-bg)}.outline,.outline-1{outline-style:var(--tw-outline-style);outline-width:1px}.-outline-offset-1{outline-offset:calc(1px * -1)}.outline-warning{outline-color:var(--sy-warning)}.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,)}.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-\[flex-grow\]{transition-property:flex-grow;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-200{--tw-duration:.2s;transition-duration:.2s}.ease-out{--tw-ease:var(--ease-out);transition-timing-function:var(--ease-out)}.outline-none{--tw-outline-style:none;outline-style:none}.select-all{-webkit-user-select:all;user-select:all}.select-none{-webkit-user-select:none;user-select:none}.\[-webkit-touch-callout\:none\]{-webkit-touch-callout:none}.\[overflow-anchor\:none\]{overflow-anchor:none}.group-open\:rotate-90:is(:where(.group):is([open],:popover-open,:open) *){rotate:90deg}.group-focus-within\/msg\:opacity-100:is(:where(.group\/msg):focus-within *){opacity:1}@media (hover:hover){.group-hover\:h-0\.5:is(:where(.group):hover *){height:calc(var(--spacing) * .5)}.group-hover\:w-0\.5:is(:where(.group):hover *){width:calc(var(--spacing) * .5)}.group-hover\:bg-accent:is(:where(.group):hover *){background-color:var(--sy-accent)}.group-hover\:opacity-100:is(:where(.group):hover *),.group-hover\/msg\:opacity-100:is(:where(.group\/msg):hover *),.group-hover\/row\:opacity-100:is(:where(.group\/row):hover *){opacity:1}}.group-focus-visible\:h-0\.5:is(:where(.group):focus-visible *){height:calc(var(--spacing) * .5)}.group-focus-visible\:w-0\.5:is(:where(.group):focus-visible *){width:calc(var(--spacing) * .5)}.group-focus-visible\:bg-accent:is(:where(.group):focus-visible *){background-color:var(--sy-accent)}.group-has-\[input\:focus-visible\]\:outline-2:is(:where(.group):has(:is(input:focus-visible)) *){outline-style:var(--tw-outline-style);outline-width:2px}.group-has-\[input\:focus-visible\]\:outline-offset-2:is(:where(.group):has(:is(input:focus-visible)) *){outline-offset:2px}.group-has-\[input\:focus-visible\]\:outline-accent:is(:where(.group):has(:is(input:focus-visible)) *){outline-color:var(--sy-accent)}.placeholder\:text-subtle::placeholder{color:var(--sy-subtle)}.before\:absolute:before{content:var(--tw-content);position:absolute}.before\:inset-x-0:before{content:var(--tw-content);inset-inline:0}.before\:-inset-y-2\.5:before{content:var(--tw-content);inset-block:calc(var(--spacing) * -2.5)}.before\:content-\[\'\'\]:before{--tw-content:"";content:var(--tw-content)}.first\:pt-0:first-child{padding-top:0}.last\:border-b-0:last-child{border-bottom-style:var(--tw-border-style);border-bottom-width:0}.last\:pb-0:last-child{padding-bottom:0}.focus-within\:opacity-100:focus-within{opacity:1}@media (hover:hover){.hover\:border-accent-hover:hover{border-color:var(--sy-accent-hover)}.hover\:border-danger-hover:hover{border-color:var(--sy-danger-hover)}.hover\:bg-accent-hover:hover{background-color:var(--sy-accent-hover)}.hover\:bg-accent-soft:hover{background-color:var(--sy-accent-soft)}.hover\:bg-border:hover{background-color:var(--sy-border)}.hover\:bg-danger-hover:hover{background-color:var(--sy-danger-hover)}.hover\:bg-danger-soft:hover{background-color:var(--sy-danger-soft)}.hover\:bg-surface-2:hover{background-color:var(--sy-surface-2)}.hover\:text-text:hover{color:var(--sy-text)}.hover\:underline:hover{text-decoration-line:underline}}.focus\:not-sr-only:focus{clip-path:none;white-space:normal;width:auto;height:auto;margin:0;padding:0;position:static;overflow:visible}.focus\:fixed:focus{position:fixed}.focus\:top-2:focus{top:calc(var(--spacing) * 2)}.focus\:left-2:focus{left:calc(var(--spacing) * 2)}.focus\:border-accent:focus{border-color:var(--sy-accent)}.focus\:bg-surface-2:focus{background-color:var(--sy-surface-2)}.focus\:outline-none:focus{--tw-outline-style:none;outline-style:none}.focus-visible\:bg-surface-3:focus-visible{background-color:var(--sy-surface-3)}.focus-visible\:underline:focus-visible{text-decoration-line:underline}.focus-visible\:opacity-100:focus-visible{opacity:1}.focus-visible\:ring-2:focus-visible{--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)}.focus-visible\:ring-accent:focus-visible{--tw-ring-color:var(--sy-accent)}.focus-visible\:outline:focus-visible{outline-style:var(--tw-outline-style);outline-width:1px}.focus-visible\:outline-2:focus-visible{outline-style:var(--tw-outline-style);outline-width:2px}.focus-visible\:outline-offset-0:focus-visible{outline-offset:0px}.focus-visible\:outline-offset-\[-2px\]:focus-visible{outline-offset:-2px}.focus-visible\:outline-\[var\(--sy-focus\)\]:focus-visible{outline-color:var(--sy-focus)}.focus-visible\:outline-accent:focus-visible{outline-color:var(--sy-accent)}.focus-visible\:outline-none:focus-visible{--tw-outline-style:none;outline-style:none}.focus-visible\:outline-solid:focus-visible{--tw-outline-style:solid;outline-style:solid}.active\:cursor-grabbing:active{cursor:grabbing}.active\:bg-surface-2:active{background-color:var(--sy-surface-2)}.active\:bg-surface-3:active{background-color:var(--sy-surface-3)}.disabled\:pointer-events-none:disabled{pointer-events:none}.disabled\:cursor-not-allowed:disabled{cursor:not-allowed}.disabled\:opacity-45:disabled{opacity:.45}.disabled\:opacity-55:disabled{opacity:.55}.disabled\:opacity-60:disabled{opacity:.6}.has-\[\:focus-visible\]\:outline-2:has(:focus-visible){outline-style:var(--tw-outline-style);outline-width:2px}.has-\[\:focus-visible\]\:outline-offset-1:has(:focus-visible){outline-offset:1px}.has-\[\:focus-visible\]\:outline-offset-2:has(:focus-visible){outline-offset:2px}.has-\[\:focus-visible\]\:outline-accent:has(:focus-visible){outline-color:var(--sy-accent)}.has-\[\[data-testid\=document-interaction\]\]\:max-w-none:has([data-testid=document-interaction]){max-width:none}.aria-\[current\=true\]\:border-accent[aria-current=true]{border-color:var(--sy-accent)}.has-\[textarea\:focus\]\:border-accent:has(:is(textarea:focus)){border-color:var(--sy-accent)}.aria-\[current\=true\]\:text-text[aria-current=true]{color:var(--sy-text)}.aria-\[invalid\=true\]\:border-danger[aria-invalid=true],.aria-\[invalid\=true\]\:focus\:border-danger[aria-invalid=true]:focus{border-color:var(--sy-danger)}@media not all and (min-width:48rem){.max-md\:static{position:static}.max-md\:hidden{display:none}.max-md\:touch-pan-y{--tw-pan-y:pan-y;touch-action:var(--tw-pan-x,) var(--tw-pan-y,) var(--tw-pinch-zoom,)}.max-md\:overflow-hidden{overflow:hidden}.max-md\:opacity-100{opacity:1}}@media not all and (min-width:40rem){.max-sm\:w-full{width:100%}.max-sm\:basis-full{flex-basis:100%}}@media (min-width:1800px){.min-\[1800px\]\:text-base{font-size:var(--text-base);line-height:var(--tw-leading,var(--text-base--line-height))}}@media (min-width:40rem){.sm\:col-span-2{grid-column:span 2/span 2}.sm\:col-start-auto{grid-column-start:auto}.sm\:row-start-auto{grid-row-start:auto}.sm\:mb-0{margin-bottom:0}.sm\:ml-auto{margin-left:auto}.sm\:hidden{display:none}.sm\:inline{display:inline}.sm\:max-w-48{max-width:calc(var(--spacing) * 48)}.sm\:flex-1{flex:1}.sm\:basis-auto{flex-basis:auto}.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\:grid-cols-\[minmax\(0\,1fr\)_minmax\(0\,1fr\)_auto\]{grid-template-columns:minmax(0,1fr) minmax(0,1fr) auto}.sm\:grid-cols-\[minmax\(8rem\,12rem\)_minmax\(0\,1fr\)\]{grid-template-columns:minmax(8rem,12rem) minmax(0,1fr)}.sm\:flex-row{flex-direction:row}.sm\:flex-wrap{flex-wrap:wrap}.sm\:items-center{align-items:center}.sm\:items-start{align-items:flex-start}.sm\:justify-center{justify-content:center}.sm\:text-center{text-align:center}}@media (min-width:48rem){.md\:sticky{position:sticky}.md\:-top-3{top:calc(var(--spacing) * -3)}.md\:top-0{top:0}.md\:top-auto{top:auto}.md\:bottom-\[calc\(var\(--safe-bottom\)\+1rem\)\]{bottom:calc(var(--safe-bottom) + 1rem)}.md\:-mx-6{margin-inline:calc(var(--spacing) * -6)}.md\:mx-6{margin-inline:calc(var(--spacing) * 6)}.md\:block{display:block}.md\:grid{display:grid}.md\:h-8{height:calc(var(--spacing) * 8)}.md\:grid-cols-\[13rem_minmax\(0\,1fr\)\]{grid-template-columns:13rem minmax(0,1fr)}.md\:flex-row{flex-direction:row}.md\:flex-wrap{flex-wrap:wrap}.md\:items-end{align-items:flex-end}.md\:gap-3{gap:calc(var(--spacing) * 3)}.md\:gap-8{gap:calc(var(--spacing) * 8)}.md\:px-4{padding-inline:calc(var(--spacing) * 4)}.md\:px-6{padding-inline:calc(var(--spacing) * 6)}.md\:text-center{text-align:center}.md\:text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}}@media (min-width:80rem){.xl\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.xl\:items-start{align-items:flex-start}}@media (min-width:96rem){.\32 xl\:max-w-\[100ch\]{max-width:100ch}.\32 xl\:grid-cols-\[15rem_minmax\(0\,1fr\)\]{grid-template-columns:15rem minmax(0,1fr)}.\32 xl\:grid-cols-\[minmax\(0\,1fr\)_390px\]{grid-template-columns:minmax(0,1fr) 390px}}@container (width>=14rem){.\@min-\[14rem\]\:inline-flex{display:inline-flex}}@media (pointer:coarse){.pointer-coarse\:opacity-100{opacity:1}}@media (pointer:fine){.pointer-fine\:inline-flex{display:inline-flex}}.\[\&_h2\]\:scroll-mt-14 h2{scroll-margin-top:calc(var(--spacing) * 14)}.\[\&_td\]\:min-w-28 td{min-width:calc(var(--spacing) * 28)}.\[\&_td\]\:border td{border-style:var(--tw-border-style);border-width:1px}.\[\&_td\]\:border-border td{border-color:var(--sy-border)}.\[\&_td\]\:px-2 td{padding-inline:calc(var(--spacing) * 2)}.\[\&_td\]\:py-1 td{padding-block:var(--spacing)}.\[\&_td\]\:align-top td{vertical-align:top}.\[\&_th\]\:min-w-28 th{min-width:calc(var(--spacing) * 28)}.\[\&_th\]\:border th{border-style:var(--tw-border-style);border-width:1px}.\[\&_th\]\:border-border th{border-color:var(--sy-border)}.\[\&_th\]\:bg-surface-2 th{background-color:var(--sy-surface-2)}.\[\&_th\]\:px-2 th{padding-inline:calc(var(--spacing) * 2)}.\[\&_th\]\:py-1 th{padding-block:var(--spacing)}.\[\&_th\]\:text-left th{text-align:left}.\[\&\:\:-moz-range-thumb\]\:size-4::-moz-range-thumb{width:calc(var(--spacing) * 4);height:calc(var(--spacing) * 4)}.\[\&\:\:-webkit-details-marker\]\:hidden::-webkit-details-marker{display:none}.\[\&\:\:-webkit-slider-thumb\]\:size-4::-webkit-slider-thumb{width:calc(var(--spacing) * 4);height:calc(var(--spacing) * 4)}.\[\&\:\:-webkit-slider-thumb\]\:appearance-none::-webkit-slider-thumb{appearance:none}.\[data-keyboard-composer\]\:visible:is(data-keyboard-composer),.\[data-keyboard-default\]\:visible:is(data-keyboard-default),.\[data-keyboard-search\]\:visible:is(data-keyboard-search){visibility:visible}.\[\&\>span\]\:sr-only>span{clip-path:inset(50%);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.\[\&\>svg\]\:size-\[18px\]>svg{width:18px;height:18px}@media (pointer:coarse){.\[\@media\(pointer\:coarse\)\]\:opacity-100{opacity:1}}}:root{--lightningcss-light:initial;--lightningcss-dark: ;color-scheme:light dark;--sy-bg:#f8fafc;--sy-surface:#fff;--sy-surface-2:#f1f5f9;--sy-surface-3:#e2e8f0;--sy-border:#d5dce5;--sy-border-strong:#94a3b8;--sy-text:#0f172a;--sy-muted:#475569;--sy-subtle:#64748b;--sy-accent:#2563eb;--sy-accent-hover:#1d4ed8;--sy-accent-fg:#fff;--sy-accent-soft:#dbeafe;--sy-success:#15803d;--sy-success-soft:#dcfce7;--sy-warning:#b45309;--sy-warning-soft:#fef3c7;--sy-danger:#b91c1c;--sy-danger-hover:#991b1b;--sy-danger-fg:#fff;--sy-danger-soft:#fee2e2;--sy-info:#0369a1;--sy-info-soft:#e0f2fe;--sy-diff-add:#e6f6ea;--sy-diff-del:#fbe9e9;--sy-diff-hunk:#eef2f7;--sy-focus:#2563eb;--sy-overlay:#0f172a66;--sy-shadow:0 10px 30px #0f172a1f, 0 2px 6px #0f172a14;--rail-width:64px;--rail-expanded-width:200px;--bottom-nav-height:56px;--safe-top:env(safe-area-inset-top,0px);--safe-right:env(safe-area-inset-right,0px);--safe-bottom:env(safe-area-inset-bottom,0px);--safe-left:env(safe-area-inset-left,0px)}@media (prefers-color-scheme:dark){:root{--lightningcss-light: ;--lightningcss-dark:initial;--sy-bg:#0f1115;--sy-surface:#161a20;--sy-surface-2:#1d222a;--sy-surface-3:#262c36;--sy-border:#2e3541;--sy-border-strong:#4b5565;--sy-text:#e6e9ee;--sy-muted:#a3acb9;--sy-subtle:#8892a0;--sy-accent:#60a5fa;--sy-accent-hover:#93c5fd;--sy-accent-fg:#0b1220;--sy-accent-soft:#1e3a5f;--sy-success:#4ade80;--sy-success-soft:#14321f;--sy-warning:#fbbf24;--sy-warning-soft:#3a2c0c;--sy-danger:#f87171;--sy-danger-hover:#fca5a5;--sy-danger-fg:#1f0a0a;--sy-danger-soft:#3b1515;--sy-info:#38bdf8;--sy-info-soft:#0c2a3a;--sy-diff-add:#12291b;--sy-diff-del:#2f1517;--sy-diff-hunk:#1b2330;--sy-focus:#93c5fd;--sy-overlay:#0000008c;--sy-shadow:0 10px 30px #00000080, 0 2px 6px #0006}}@keyframes sy-sheet-in{0%{transform:translateY(100%)}}@keyframes sy-drawer-in{0%{transform:translate(100%)}}@keyframes sy-pop-in{0%{opacity:0;transform:scale(.97)}}@keyframes sy-fade-in{0%{opacity:0}}@keyframes sy-slide-from-right{0%{opacity:.4;transform:translate(24px)}}@keyframes sy-slide-from-left{0%{opacity:.4;transform:translate(-24px)}}@media (prefers-reduced-motion:reduce){*,:before,:after{transition-duration:.01ms!important;animation-duration:.01ms!important;animation-iteration-count:1!important}.animate-spin{animation:2.4s linear infinite spin!important}.sy-motion{transition-duration:.2s!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-pan-x{syntax:"*";inherits:false}@property --tw-pan-y{syntax:"*";inherits:false}@property --tw-pinch-zoom{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-duration{syntax:"*";inherits:false}@property --tw-ease{syntax:"*";inherits:false}@property --tw-content{syntax:"*";inherits:false;initial-value:""}@keyframes spin{to{transform:rotate(360deg)}}@keyframes pulse{50%{opacity:.5}}
|