thursday-agent 0.1.0 → 0.1.1
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/.next/BUILD_ID +1 -1
- package/.next/build-manifest.json +3 -3
- package/.next/prerender-manifest.json +3 -3
- package/.next/server/app/_global-error.html +1 -1
- package/.next/server/app/_global-error.rsc +1 -1
- package/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
- package/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/.next/server/app/_not-found.html +1 -1
- package/.next/server/app/_not-found.rsc +1 -1
- package/.next/server/app/_not-found.segments/_full.segment.rsc +1 -1
- package/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
- package/.next/server/app/_not-found.segments/_tree.segment.rsc +1 -1
- package/.next/server/app/artifact/[...path]/page/server-reference-manifest.json +1 -1
- package/.next/server/app/artifact/[...path]/page.js.nft.json +1 -1
- package/.next/server/app/artifact/[...path]/page_client-reference-manifest.js +1 -1
- package/.next/server/app/page/server-reference-manifest.json +41 -41
- package/.next/server/app/page.js.nft.json +1 -1
- package/.next/server/app/page_client-reference-manifest.js +1 -1
- package/.next/server/chunks/ssr/[root-of-the-server]__0dfwvr4._.js +1 -1
- package/.next/server/chunks/ssr/[root-of-the-server]__1-mnhyd._.js +1 -1
- package/.next/server/chunks/ssr/[root-of-the-server]__1e-f3gy._.js +3 -0
- package/.next/server/chunks/ssr/{[root-of-the-server]__0ng1y5l._.js → [root-of-the-server]__1ncajna._.js} +2 -2
- package/.next/server/chunks/ssr/_077-g6s._.js +1 -1
- package/.next/server/chunks/ssr/_0ay6b01._.js +1 -1
- package/.next/server/chunks/ssr/_0sf1isi._.js +1 -1
- package/.next/server/chunks/ssr/{_0c2y8ks._.js → _124q1la._.js} +2 -2
- package/.next/server/chunks/ssr/_19eoufz._.js +3 -0
- package/.next/server/chunks/ssr/{_1lz4t71._.js → _1aca4j8._.js} +2 -2
- package/.next/server/chunks/ssr/{_06l25rd._.js → _1b3yex3._.js} +2 -2
- package/.next/server/chunks/ssr/{_0n0wwfo._.js → _1cb_5sv._.js} +2 -2
- package/.next/server/chunks/ssr/{_0vbcev4._.js → _1dnxp2k._.js} +2 -2
- package/.next/server/chunks/ssr/_1e-dgz0._.js +1 -1
- package/.next/server/chunks/ssr/{_1wlc_pv._.js → _1hkvsg0._.js} +2 -2
- package/.next/server/chunks/ssr/{_061oc5l._.js → _1m5popy._.js} +2 -2
- package/.next/server/chunks/ssr/{_0-pwe74._.js → _1r2_qk-._.js} +2 -2
- package/.next/server/chunks/ssr/features_bot_components_bot-setting_tsx_01ajft6._.js +1 -1
- package/.next/server/chunks/ssr/features_config_components_14jqgy4._.js +1 -1
- package/.next/server/chunks/ssr/features_config_components_config-setting_tsx_0xfwqdg._.js +1 -1
- package/.next/server/chunks/ssr/features_connectors_components_mcp-setting_tsx_0jmbgvp._.js +1 -1
- package/.next/server/chunks/ssr/features_memory_components_memory-setting_tsx_0oa43sw._.js +1 -1
- package/.next/server/chunks/ssr/{node_modules_1i1aztk._.js → node_modules_00riwzq._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_13r64hh._.js → node_modules_012m-mo._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_01-lnjv._.js → node_modules_01jj5oy._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_0cagd-a._.js → node_modules_03f-6up._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_0o9cu2m._.js → node_modules_07_oxjr._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_06gkc-1._.js → node_modules_0egn4iq._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_0510bcb._.js → node_modules_0eqdzva._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_12ilj3x._.js → node_modules_0ewynyi._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_18h15oi._.js → node_modules_0i37h34._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_14qjnj6._.js → node_modules_0nh2m35._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_04m323e._.js → node_modules_0nq_p-o._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_1hfkkak._.js → node_modules_0sbobpz._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_20oe6vi._.js → node_modules_0xe_k12._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_1ekezwy._.js → node_modules_14uxpfb._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_1ci9xpq._.js → node_modules_17c71fz._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_1czzodm._.js → node_modules_17ls31t._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_0n9m8ww._.js → node_modules_1854ebs._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_0okab9u._.js → node_modules_1_w_b81._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_0eq4z64._.js → node_modules_1bjm3ch._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_1bog3e3._.js → node_modules_1euv75v._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_0a7_hec._.js → node_modules_1fsvm8f._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_0egyezs._.js → node_modules_1kj6swe._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_0kc8lu9._.js → node_modules_1mnmhse._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_1wya71n._.js → node_modules_1wsx1pg._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_0snv8wz._.js → node_modules_1y1m-q4._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_126jgz-._.js → node_modules_1yxkq1s._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_@mermaid-js_parser_dist_chunks_mermaid-parser_core_0babb8b._.js → node_modules_@mermaid-js_parser_dist_chunks_mermaid-parser_core_1f5re6n._.js} +1 -1
- package/.next/server/chunks/ssr/{node_modules_@mermaid-js_parser_dist_chunks_mermaid-parser_core_0jiglry._.js → node_modules_@mermaid-js_parser_dist_chunks_mermaid-parser_core_216aa7f._.js} +1 -1
- package/.next/server/middleware-build-manifest.js +3 -3
- package/.next/server/pages/404.html +1 -1
- package/.next/server/pages/500.html +1 -1
- package/.next/server/server-reference-manifest.js +1 -1
- package/.next/server/server-reference-manifest.json +42 -42
- package/.next/static/chunks/{1n0rxcrn8v33a.js → 0_6qjj4f3t3j-.js} +1 -1
- package/.next/static/chunks/{16jdhpex5davi.js → 0g2n0xskvyk04.js} +1 -1
- package/.next/static/chunks/{2tab0u1fay-lo.js → 0h7pjyewk7ky-.js} +1 -1
- package/.next/static/chunks/{1ti6qqe8rxjc9.js → 0yn2yol46cj77.js} +1 -1
- package/.next/static/chunks/{3ktulatcmvs36.js → 14s7e14xltx47.js} +1 -1
- package/.next/static/chunks/{1n1_b0m4z2r2l.js → 1lpdcqos7mkek.js} +1 -1
- package/.next/static/chunks/{225bcu0dkzwh9.js → 1rja48de93vvx.js} +1 -1
- package/.next/static/chunks/{3v_k5wbdx5z1e.js → 1u5d-pvhwir9g.js} +1 -1
- package/.next/static/chunks/{3imn63hmy-dvm.js → 261871a8ot1pi.js} +1 -1
- package/.next/static/chunks/{2bd12_uvbr996.js → 2cgzsjzheo2m2.js} +1 -1
- package/.next/static/chunks/{26jl58p1cmfyz.js → 2ka9uwo_evj7a.js} +1 -1
- package/.next/static/chunks/{3a8ieqoovwtgg.js → 2kl3n2d-4-7i5.js} +1 -1
- package/.next/static/chunks/{17yxvpmlyxotg.js → 2qci2z603es_m.js} +1 -1
- package/.next/static/chunks/{07hfxlyqq92v-.js → 2v_vqhmdl8de_.js} +1 -1
- package/.next/static/chunks/{0m28u02ktcwrt.js → 34eu8t79ko6lm.js} +1 -1
- package/.next/static/chunks/{0qwvymwynno3x.js → 35uo6rtl_otbd.js} +1 -1
- package/.next/static/chunks/{0t7ve-t64i24a.js → 3w7-y53xzl2ir.js} +1 -1
- package/.next/static/chunks/{1ma7gsnw16oor.js → 3yan6-5cvpk2o.js} +1 -1
- package/package.json +3 -17
- package/.next/server/chunks/ssr/[root-of-the-server]__1d9rffu._.js +0 -3
- package/.next/server/chunks/ssr/_0g7xsms._.js +0 -3
- package/node_modules/@img/sharp-libvips-linux-x64/README.md +0 -46
- package/node_modules/@img/sharp-libvips-linux-x64/lib/glib-2.0/include/glibconfig.h +0 -219
- package/node_modules/@img/sharp-libvips-linux-x64/lib/index.js +0 -1
- package/node_modules/@img/sharp-libvips-linux-x64/lib/libvips-cpp.so.8.18.6 +0 -0
- package/node_modules/@img/sharp-libvips-linux-x64/package.json +0 -43
- package/node_modules/@img/sharp-libvips-linux-x64/versions.json +0 -30
- package/node_modules/@img/sharp-libvips-linuxmusl-x64/README.md +0 -46
- package/node_modules/@img/sharp-libvips-linuxmusl-x64/lib/glib-2.0/include/glibconfig.h +0 -219
- package/node_modules/@img/sharp-libvips-linuxmusl-x64/lib/index.js +0 -1
- package/node_modules/@img/sharp-libvips-linuxmusl-x64/lib/libvips-cpp.so.8.18.6 +0 -0
- package/node_modules/@img/sharp-libvips-linuxmusl-x64/package.json +0 -43
- package/node_modules/@img/sharp-libvips-linuxmusl-x64/versions.json +0 -30
- package/node_modules/@img/sharp-linux-x64/index.cjs +0 -2
- package/node_modules/@img/sharp-linux-x64/lib/sharp-linux-x64-0.35.4.node +0 -0
- package/node_modules/@img/sharp-linux-x64/package.json +0 -47
- package/node_modules/@img/sharp-linuxmusl-x64/index.cjs +0 -2
- package/node_modules/@img/sharp-linuxmusl-x64/lib/sharp-linuxmusl-x64-0.35.4.node +0 -0
- package/node_modules/@img/sharp-linuxmusl-x64/package.json +0 -47
- package/node_modules/@libsql/linux-x64-gnu/index.node +0 -0
- package/node_modules/@libsql/linux-x64-gnu/package.json +0 -36
- package/node_modules/@libsql/linux-x64-musl/index.node +0 -0
- package/node_modules/@libsql/linux-x64-musl/package.json +0 -36
- package/node_modules/libsql/auth.js +0 -22
- package/node_modules/libsql/index.js +0 -441
- package/node_modules/libsql/node_modules/detect-libc/lib/detect-libc.js +0 -279
- package/node_modules/libsql/node_modules/detect-libc/lib/filesystem.js +0 -41
- package/node_modules/libsql/node_modules/detect-libc/lib/process.js +0 -19
- package/node_modules/libsql/node_modules/detect-libc/package.json +0 -40
- package/node_modules/libsql/package.json +0 -90
- package/node_modules/libsql/sqlite-error.js +0 -21
- package/node_modules/sharp/dist/channel.cjs +0 -177
- package/node_modules/sharp/dist/channel.mjs +0 -177
- package/node_modules/sharp/dist/colour.cjs +0 -199
- package/node_modules/sharp/dist/colour.mjs +0 -199
- package/node_modules/sharp/dist/composite.cjs +0 -213
- package/node_modules/sharp/dist/composite.mjs +0 -213
- package/node_modules/sharp/dist/constructor.cjs +0 -511
- package/node_modules/sharp/dist/constructor.mjs +0 -511
- package/node_modules/sharp/dist/index.cjs +0 -25
- package/node_modules/sharp/dist/index.d.cts +0 -1999
- package/node_modules/sharp/dist/index.d.mts +0 -2046
- package/node_modules/sharp/dist/index.mjs +0 -25
- package/node_modules/sharp/dist/input.cjs +0 -819
- package/node_modules/sharp/dist/input.mjs +0 -819
- package/node_modules/sharp/dist/is.cjs +0 -143
- package/node_modules/sharp/dist/is.mjs +0 -143
- package/node_modules/sharp/dist/libvips.cjs +0 -212
- package/node_modules/sharp/dist/libvips.mjs +0 -212
- package/node_modules/sharp/dist/operation.cjs +0 -1002
- package/node_modules/sharp/dist/operation.mjs +0 -1002
- package/node_modules/sharp/dist/output.cjs +0 -1785
- package/node_modules/sharp/dist/output.mjs +0 -1785
- package/node_modules/sharp/dist/resize.cjs +0 -617
- package/node_modules/sharp/dist/resize.mjs +0 -617
- package/node_modules/sharp/dist/sharp.cjs +0 -174
- package/node_modules/sharp/dist/sharp.mjs +0 -174
- package/node_modules/sharp/dist/utility.cjs +0 -301
- package/node_modules/sharp/dist/utility.mjs +0 -301
- package/node_modules/sharp/node_modules/semver/classes/comparator.js +0 -143
- package/node_modules/sharp/node_modules/semver/classes/range.js +0 -577
- package/node_modules/sharp/node_modules/semver/classes/semver.js +0 -350
- package/node_modules/sharp/node_modules/semver/functions/clean.js +0 -8
- package/node_modules/sharp/node_modules/semver/functions/cmp.js +0 -54
- package/node_modules/sharp/node_modules/semver/functions/coerce.js +0 -62
- package/node_modules/sharp/node_modules/semver/functions/compare-build.js +0 -9
- package/node_modules/sharp/node_modules/semver/functions/compare-loose.js +0 -5
- package/node_modules/sharp/node_modules/semver/functions/compare.js +0 -7
- package/node_modules/sharp/node_modules/semver/functions/diff.js +0 -60
- package/node_modules/sharp/node_modules/semver/functions/eq.js +0 -5
- package/node_modules/sharp/node_modules/semver/functions/gt.js +0 -5
- package/node_modules/sharp/node_modules/semver/functions/gte.js +0 -5
- package/node_modules/sharp/node_modules/semver/functions/inc.js +0 -21
- package/node_modules/sharp/node_modules/semver/functions/lt.js +0 -5
- package/node_modules/sharp/node_modules/semver/functions/lte.js +0 -5
- package/node_modules/sharp/node_modules/semver/functions/major.js +0 -5
- package/node_modules/sharp/node_modules/semver/functions/minor.js +0 -5
- package/node_modules/sharp/node_modules/semver/functions/neq.js +0 -5
- package/node_modules/sharp/node_modules/semver/functions/parse.js +0 -18
- package/node_modules/sharp/node_modules/semver/functions/patch.js +0 -5
- package/node_modules/sharp/node_modules/semver/functions/prerelease.js +0 -8
- package/node_modules/sharp/node_modules/semver/functions/rcompare.js +0 -5
- package/node_modules/sharp/node_modules/semver/functions/rsort.js +0 -5
- package/node_modules/sharp/node_modules/semver/functions/satisfies.js +0 -12
- package/node_modules/sharp/node_modules/semver/functions/sort.js +0 -5
- package/node_modules/sharp/node_modules/semver/functions/truncate.js +0 -48
- package/node_modules/sharp/node_modules/semver/functions/valid.js +0 -8
- package/node_modules/sharp/node_modules/semver/index.js +0 -93
- package/node_modules/sharp/node_modules/semver/internal/constants.js +0 -37
- package/node_modules/sharp/node_modules/semver/internal/debug.js +0 -11
- package/node_modules/sharp/node_modules/semver/internal/identifiers.js +0 -29
- package/node_modules/sharp/node_modules/semver/internal/lrucache.js +0 -42
- package/node_modules/sharp/node_modules/semver/internal/parse-options.js +0 -17
- package/node_modules/sharp/node_modules/semver/internal/re.js +0 -223
- package/node_modules/sharp/node_modules/semver/package.json +0 -78
- package/node_modules/sharp/node_modules/semver/ranges/gtr.js +0 -6
- package/node_modules/sharp/node_modules/semver/ranges/intersects.js +0 -9
- package/node_modules/sharp/node_modules/semver/ranges/ltr.js +0 -6
- package/node_modules/sharp/node_modules/semver/ranges/max-satisfying.js +0 -27
- package/node_modules/sharp/node_modules/semver/ranges/min-satisfying.js +0 -26
- package/node_modules/sharp/node_modules/semver/ranges/min-version.js +0 -63
- package/node_modules/sharp/node_modules/semver/ranges/outside.js +0 -82
- package/node_modules/sharp/node_modules/semver/ranges/simplify.js +0 -49
- package/node_modules/sharp/node_modules/semver/ranges/subset.js +0 -249
- package/node_modules/sharp/node_modules/semver/ranges/to-comparators.js +0 -10
- package/node_modules/sharp/node_modules/semver/ranges/valid.js +0 -13
- package/node_modules/sharp/package.json +0 -227
- /package/.next/static/{M8Zkbqz2M4SLzLsE8DC6V → G-9_HnysmzY_Bx9GpDYAO}/_buildManifest.js +0 -0
- /package/.next/static/{M8Zkbqz2M4SLzLsE8DC6V → G-9_HnysmzY_Bx9GpDYAO}/_clientMiddlewareManifest.js +0 -0
- /package/.next/static/{M8Zkbqz2M4SLzLsE8DC6V → G-9_HnysmzY_Bx9GpDYAO}/_ssgManifest.js +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,805995,e=>{"use strict";var t=e.i(843476),n=e.i(456420);let i={name:"audio-lines",size:24,node:[["path",{d:"M2 10v3",key:"1fnikh"}],["path",{d:"M6 6v11",key:"11sgs0"}],["path",{d:"M10 3v18",key:"yhl04a"}],["path",{d:"M14 8v7",key:"3a1oy3"}],["path",{d:"M18 5v13",key:"123xd1"}],["path",{d:"M22 10v3",key:"154ddg"}]]};i.node;let s=(0,n.default)(i),o={name:"captions",size:24,node:[["rect",{width:"18",height:"14",x:"3",y:"5",rx:"2",ry:"2",key:"12ruh7"}],["path",{d:"M7 15h4M15 15h2M7 11h2M13 11h4",key:"1ueiar"}]],aliases:["subtitles"]};o.node;let r=(0,n.default)(o);var
|
|
1
|
+
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,805995,e=>{"use strict";var t=e.i(843476),n=e.i(456420);let i={name:"audio-lines",size:24,node:[["path",{d:"M2 10v3",key:"1fnikh"}],["path",{d:"M6 6v11",key:"11sgs0"}],["path",{d:"M10 3v18",key:"yhl04a"}],["path",{d:"M14 8v7",key:"3a1oy3"}],["path",{d:"M18 5v13",key:"123xd1"}],["path",{d:"M22 10v3",key:"154ddg"}]]};i.node;let s=(0,n.default)(i),o={name:"captions",size:24,node:[["rect",{width:"18",height:"14",x:"3",y:"5",rx:"2",ry:"2",key:"12ruh7"}],["path",{d:"M7 15h4M15 15h2M7 11h2M13 11h4",key:"1ueiar"}]],aliases:["subtitles"]};o.node;let r=(0,n.default)(o);var l=e.i(689664),a=e.i(867927);let d={name:"clapperboard",size:24,node:[["path",{d:"m12.296 3.464 3.02 3.956",key:"qash78"}],["path",{d:"M20.2 6 3 11l-.9-2.4c-.3-1.1.3-2.2 1.3-2.5l13.5-4c1.1-.3 2.2.3 2.5 1.3z",key:"1h7j8b"}],["path",{d:"M3 11h18v8a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z",key:"4lm6w1"}],["path",{d:"m6.18 5.276 3.1 3.899",key:"zjj9t3"}]]};d.node;let c=(0,n.default)(d);var u=e.i(815170),g=e.i(466787),m=e.i(271645),h=e.i(798120),f=e.i(167881),x=e.i(23750),k=e.i(917162),p=e.i(146538),y=e.i(968978),v=e.i(265402),j=e.i(635963),b=e.i(95187);let N=(0,b.createServerReference)("7f9b3cf79921363eeeed943885510514b1f0b05850",b.callServer,void 0,b.findSourceMapURL,"removeConfigAction");var S=e.i(692422),C=e.i(992112),M=e.i(895836),A=e.i(609856),w=e.i(283653),z=e.i(647163);let R={image:u.Image,video:c,speech:s,transcription:r};function I({section:e}){let{data:n,isLoading:i,error:s}=(0,w.useServerRoute)(h.queryKey.config);if(i)return(0,t.jsx)(M.SettingSkeleton,{rows:4});if(s)return(0,t.jsx)(M.SettingError,{message:s.message});let o=e=>(0,C.isConfigSet)(n,e),r=e=>n?.find(t=>t.key===e)?.value,l=C.CONFIG_GROUPS.filter(t=>t.section===e),a=l.flatMap(e=>e.entries);return(0,t.jsx)(M.SettingScreen,{footer:(0,t.jsx)(M.SettingRailNote,{children:"keys"===e?(0,t.jsxs)(t.Fragment,{children:[a.filter(e=>o(e.key)).length," of"," ",a.length," set",l.some(e=>!(0,C.groupSatisfied)(e,o))?" · a call needs one voice key":" · your keys stay on this machine"]}):(0,t.jsxs)(t.Fragment,{children:[a.length," of ",a.length," resolved ·"," ",a.filter(e=>r(e.key)).length," pinned"]})}),children:l.map(e=>(0,t.jsx)(M.SettingGroup,{label:e.title,hint:e.hint,right:(0,t.jsx)(K,{group:e,isSet:o}),children:(0,t.jsx)(M.SettingItems,{children:e.entries.map(n=>n.choices?(0,t.jsx)($,{entry:n,choices:n.choices,value:r(n.key),isSet:o},n.key):(0,t.jsx)(T,{entry:n,set:o(n.key),needed:!(0,C.groupSatisfied)(e,o)},n.key))})},e.id))})}function K({group:e,isSet:n}){return"none"===e.require?null:(0,C.groupSatisfied)(e,n)?(0,t.jsxs)("span",{className:"flex items-center gap-1 font-mono text-[11px] text-muted-foreground",children:[(0,t.jsx)(l.Check,{className:"size-3"}),"ready"]}):(0,t.jsxs)("span",{className:(0,z.cn)("flex items-center gap-1 font-mono text-[11px]",z.WAITING_INK),children:[(0,t.jsx)(g.TriangleAlert,{className:"size-3"}),e.note??"Required"]})}function T({entry:e,set:n,needed:i}){return(0,t.jsxs)("button",{type:"button",onClick:()=>{var i,s;return i=e,s=n,k.notify.component({className:"sm:max-w-md",renderer:({close:e})=>(0,t.jsx)(O,{entry:i,set:s,onDone:e})})},className:"group flex w-full items-center gap-3 p-4 text-left outline-none transition-colors hover:bg-muted/50 focus-visible:ring-3 focus-visible:ring-ring/50 focus-visible:ring-inset",children:[e.provider&&(0,t.jsx)("span",{className:"grid size-8 shrink-0 place-items-center rounded-lg bg-muted/60",children:(0,t.jsx)(y.ProviderIcon,{provider:e.provider,className:"size-4"})}),(0,t.jsxs)("span",{className:"min-w-0 flex-1 space-y-0.5",children:[(0,t.jsx)("span",{className:"block truncate text-sm font-medium",children:e.label}),(0,t.jsx)("span",{className:"block truncate font-mono text-xs text-muted-foreground",children:e.key})]}),(0,t.jsxs)("span",{className:(0,z.cn)("flex shrink-0 items-center gap-1.5 font-mono text-xs",n?"text-muted-foreground":i?z.WAITING_INK:"text-muted-foreground/60"),children:[n&&(0,t.jsx)(l.Check,{className:"size-3"}),!n&&i&&(0,t.jsx)(g.TriangleAlert,{className:"size-3"}),n?"Set":i?"Needed":"Not set"]}),(0,t.jsx)(a.ChevronRight,{className:"size-4 shrink-0 text-muted-foreground/60 transition-colors group-hover:text-foreground"})]})}function $({entry:e,choices:n,value:i,isSet:s}){let o=n.find(e=>e.value===i),r=n.filter(e=>s(e.needs)),l=i&&!o?i:null,d=e.kind?R[e.kind]:j.BotsMark;return(0,t.jsxs)("button",{type:"button",onClick:()=>{var i,s,o;return e.kind||e.text?(i=e,k.notify.component({className:"sm:max-w-lg",renderer:({close:e})=>(0,t.jsx)(q,{entry:i,onDone:e})})):(s=e,o=n,k.notify.component({className:"sm:max-w-md",renderer:({close:e})=>(0,t.jsx)(B,{entry:s,choices:o,onDone:e})}))},className:"group flex w-full items-center gap-3 p-4 text-left outline-none transition-colors hover:bg-muted/50 focus-visible:ring-3 focus-visible:ring-ring/50 focus-visible:ring-inset",children:[(0,t.jsx)("span",{className:"grid size-8 shrink-0 place-items-center rounded-lg bg-muted/60",children:(0,t.jsx)(d,{className:"size-4 text-muted-foreground"})}),(0,t.jsxs)("span",{className:"min-w-0 flex-1 space-y-1",children:[(0,t.jsx)("span",{className:"block truncate text-sm font-medium",children:e.label}),(0,t.jsxs)("span",{className:"flex min-w-0 items-center gap-1.5",children:[!o&&!l&&(0,t.jsx)("span",{className:(0,z.cn)("shrink-0 rounded-[5px] border border-border/60 px-1 font-mono text-[10px]",e.kind?z.WAITING_INK:"text-muted-foreground"),children:e.kind?"off":"auto"}),(0,t.jsx)("span",{className:"truncate font-mono text-xs text-muted-foreground",children:o?.label??l??(e.kind?"Not offered to bots until you pick one":r[0]?.label??"No key for any of these yet")})]})]}),(0,t.jsx)(a.ChevronRight,{className:"size-4 shrink-0 text-muted-foreground/60 transition-colors group-hover:text-foreground"})]})}function q({entry:e,onDone:n}){let{data:i}=(0,w.useServerRoute)(h.queryKey.config),s=i?.find(t=>t.key===e.key)?.value,[o,r]=(0,m.useState)(()=>{let t=e.text?(0,v.parseTextModel)(s):(0,v.parseMediaModel)(s);return{provider:t?.provider??null,model:t?.model??""}}),l=()=>{(0,w.revalidate)(h.queryKey.config),n()},[a]=(0,A.useServerAction)(S.setConfigAction,{okMessage:`${e.label} saved`,onOk:l}),[d,c]=(0,A.useServerAction)(N,{okMessage:e.kind?`${e.label} switched off`:`${e.label} back to automatic`,onOk:l});return(0,t.jsx)(M.SettingDialogContent,{title:e.label,description:e.hint,footer:(0,t.jsxs)(t.Fragment,{children:[s&&(0,t.jsx)(f.Button,{variant:"ghost",loading:c,onClick:()=>d(e.key),children:e.kind?"Turn off":"Automatic"}),(0,t.jsx)(f.Button,{variant:"ghost",onClick:n,children:"Close"})]}),children:(0,t.jsx)(p.ModelPicker,{kind:e.kind,provider:o.provider,model:o.model,onChange:t=>{r(t),t.model.trim()&&a(e.key,`${t.provider}/${t.model.trim()}`)}})})}function B({entry:e,choices:n,onDone:i}){let{data:s}=(0,w.useServerRoute)(h.queryKey.config),o=s?.find(t=>t.key===e.key)?.value,r=()=>{(0,w.revalidate)(h.queryKey.config),i()},[l,a]=(0,A.useServerAction)(S.setConfigAction,{okMessage:`${e.label} saved`,onOk:r}),[d,c]=(0,A.useServerAction)(N,{okMessage:e.kind?`${e.label} switched off`:`${e.label} back to automatic`,onOk:r});return(0,t.jsx)(M.SettingDialogContent,{title:e.label,description:e.hint,footer:(0,t.jsxs)(t.Fragment,{children:[o&&(0,t.jsx)(f.Button,{variant:"ghost",loading:c,onClick:()=>d(e.key),children:e.kind?"Turn off":"Automatic"}),(0,t.jsx)(f.Button,{variant:"ghost",onClick:i,children:"Close"})]}),children:(0,t.jsx)(M.SettingChoiceRows,{options:n.map(e=>({value:e.value,label:e.label,disabled:!(0,C.isConfigSet)(s,e.needs)&&`needs ${e.needs}`})),value:o,onChange:t=>l(e.key,t),disabled:a})})}function O({entry:e,set:n,onDone:i}){let[s,o]=(0,m.useState)(""),r=()=>{(0,w.revalidate)(h.queryKey.config),(0,w.revalidate)(h.queryKey.llmModel)},[l,a]=(0,A.useServerAction)(S.setConfigAction,{okMessage:`${e.label} key saved`,onOk:()=>{r(),i()}}),[d,c]=(0,A.useServerAction)(N,{okMessage:`${e.label} key removed`,onOk:()=>{r(),i()}});return(0,t.jsx)(M.SettingDialogContent,{title:e.label,description:(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("span",{className:"font-mono",children:e.key}),e.hint&&(0,t.jsxs)(t.Fragment,{children:[" · ",e.hint]})]}),footer:(0,t.jsxs)(t.Fragment,{children:[n&&(0,t.jsx)(f.Button,{variant:"ghost",loading:c,onClick:()=>d(e.key),children:"Remove"}),(0,t.jsx)(f.Button,{variant:"ghost",onClick:i,children:"Cancel"}),(0,t.jsx)(f.Button,{loading:a,disabled:s.trim().length<8,onClick:()=>l(e.key,s),children:n?"Replace":"Save"})]}),children:(0,t.jsx)(x.Input,{value:s,onChange:e=>o(e.target.value),onKeyDown:t=>{"Enter"===t.key&&s.trim().length>=8&&l(e.key,s)},placeholder:n?"New value — replaces the current key":e.key,spellCheck:!1,type:"password",autoFocus:!0})})}e.s(["ConfigGroups",0,I,"ConfigSetting",0,function(){return(0,t.jsx)(I,{section:"keys"})}],805995)},855783,e=>{"use strict";var t=e.i(843476),n=e.i(805995);e.s(["ModelsSetting",0,function(){return(0,t.jsx)(n.ConfigGroups,{section:"models"})}])}]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,41533,t=>{"use strict";var e=t.i(247167);e.default.env.THURSDAY_APP_DIR?.trim()||e.default.cwd(),e.default.env.THURSDAY_HOME?.trim()||e.default.cwd(),e.default.env.THURSDAY_URL?.trim()||e.default.env.PORT?.trim();let a=".ai-workspace",r={workspace:a,artifacts:"artifacts",projects:"projects",scratch:"scratch",output:".output",skills:{default:"skills",custom:`${a}/.agents/skills`}};t.s(["APP_NAME",0,"Thursday","ARTIFACT_VIEW",0,{rows:200,setFiles:120},"BOT_RUN",0,{steps:25,compactAt:12e4,summaryWords:{min:600,max:3e3,perTokens:200},resumeMessages:20},"BROWSER_SKILL",0,"browser","PAGE_SIZE",0,50,"PATHS",0,r,"WORKSPACE_VIEW",0,{rows:200,textMax:524288,elementMax:0x3200000}])},621285,616172,492615,t=>{"use strict";var e=t.i(843476),a=t.i(271645),r=t.i(798120),n=t.i(167881),i=t.i(630374),o=t.i(683408),s=t.i(671428),l=t.i(647163);function d({className:t,...a}){return(0,e.jsx)("div",{"data-slot":"table-container",className:"relative w-full overflow-x-auto",children:(0,e.jsx)("table",{"data-slot":"table",className:(0,l.cn)("w-full caption-bottom text-sm",t),...a})})}function u({className:t,...a}){return(0,e.jsx)("thead",{"data-slot":"table-header",className:(0,l.cn)("[&_tr]:border-b",t),...a})}function c({className:t,...a}){return(0,e.jsx)("tbody",{"data-slot":"table-body",className:(0,l.cn)("[&_tr:last-child]:border-0",t),...a})}function h({className:t,...a}){return(0,e.jsx)("tr",{"data-slot":"table-row",className:(0,l.cn)("border-b border-border/60 transition-colors data-[state=selected]:bg-muted hover:bg-muted/40",t),...a})}function f({className:t,...a}){return(0,e.jsx)("th",{"data-slot":"table-head",className:(0,l.cn)("h-9 px-2 text-left align-middle font-mono text-[11px] font-normal tracking-[0.1em] whitespace-nowrap text-muted-foreground uppercase [&:has([role=checkbox])]:pr-0",t),...a})}function m({className:t,...a}){return(0,e.jsx)("td",{"data-slot":"table-cell",className:(0,l.cn)("p-2 align-middle [&:has([role=checkbox])]:pr-0",t),...a})}var g=t.i(41533);let w=t=>`text/${t}; charset=utf-8`,p={md:{kind:"markdown",mime:w("markdown")},markdown:{kind:"markdown",mime:w("markdown")},csv:{kind:"csv",mime:w("csv")},json:{kind:"json",mime:"application/json; charset=utf-8"},txt:{kind:"text",mime:w("plain")},log:{kind:"text",mime:w("plain")},html:{kind:"frame",mime:w("html")},htm:{kind:"frame",mime:w("html")},pdf:{kind:"frame",mime:"application/pdf"},png:{kind:"image",mime:"image/png"},jpg:{kind:"image",mime:"image/jpeg"},jpeg:{kind:"image",mime:"image/jpeg"},gif:{kind:"image",mime:"image/gif"},webp:{kind:"image",mime:"image/webp"},svg:{kind:"image",mime:"image/svg+xml"},mp3:{kind:"audio",mime:"audio/mpeg"},wav:{kind:"audio",mime:"audio/wav"},mp4:{kind:"video",mime:"video/mp4"},webm:{kind:"video",mime:"video/webm"},css:{kind:"none",mime:w("css")},js:{kind:"none",mime:w("javascript")},woff2:{kind:"none",mime:"font/woff2"}},y=t=>p[t.split(".").pop()?.toLowerCase()??""]?.kind??"none",b=Object.entries(p).filter(([,t])=>"none"!==t.kind).map(([t])=>t),x=RegExp(String.raw`(?<![\p{L}\p{N}_/:@%-])(?:[\p{L}\p{N}_.@%-]+/)*[\p{L}\p{N}_@%-]+(?:\.[\p{L}\p{N}_-]+)*\.(?:${b.join("|")})\b`,"giu"),k=`${g.PATHS.workspace}/`;function v(t){let e=t.trim(),a=e.indexOf(k);return a>=0?e.slice(a+k.length)||null:e.startsWith("/")||/^[A-Za-z]:/.test(e)||e.split("/").includes("..")?null:e||null}t.s(["pathsIn",0,function(t){let e=t.replace(/\b[a-z][\w+.-]*:\/\/\S+/gi," "),a=new Set;for(let t of e.match(x)??[]){let e=function(t){let e=v(t);if(!e)return null;let[a,...r]=e.split("/");return r.length&&a.includes(".")?null:e}(t);e&&a.add(e)}return[...a].slice(0,6)},"viewKindOf",0,y,"workspaceRelative",0,v],616172);var M=t.i(95187);let S=(0,M.createServerReference)("7f9ce9f25ec95af4b838fe978d9278a4e54676e14f",M.callServer,void 0,M.findSourceMapURL,"openFileAction");t.s(["openFileAction",0,S],492615);var N=t.i(609856);let j=new Set(["frame","image","audio","video"]);function D(t){let e=v(t);if(!e)return{how:"os"};let a=y(e);return j.has(a)?{how:"tab",path:e,href:r.queryKey.fileView(e)}:"none"===a?{how:"os"}:{how:"dialog",path:e}}let C=(0,a.createContext)(null),_={dialog:{prose:"px-5 py-4",block:"px-4 py-3"},page:{prose:"px-5 py-6 sm:px-8",block:"px-5 py-5"}};function T({kind:t,content:a,truncated:r,where:n="dialog"}){return(0,e.jsxs)(e.Fragment,{children:[null!=r&&(0,e.jsx)(P,{of:r}),(0,e.jsx)(O,{kind:t,content:a,where:n})]})}function P({of:t}){return(0,e.jsxs)("p",{className:"border-b border-border/60 px-5 py-2.5 font-mono text-[11px] text-muted-foreground",children:[`Showing the first ${(0,l.formatBytes)(g.WORKSPACE_VIEW.textMax)} of ${(0,l.formatBytes)(t)}. `,"Open the file itself for the rest."]})}function O({kind:t,content:a,where:r}){let n=_[r];switch(t){case"markdown":return(0,e.jsx)("div",{className:(0,l.cn)("min-w-0 text-sm leading-relaxed",n.prose),children:(0,e.jsx)(o.Markdown,{children:a})});case"csv":return(0,e.jsx)(L,{content:a,className:n.block});case"json":return(0,e.jsx)(E,{text:function(t){try{return JSON.stringify(JSON.parse(t),null,2)}catch{return t}}(a),className:n.block});default:return(0,e.jsx)(E,{text:a,className:n.block})}}function W(t){let[e,n]=(0,a.useState)(null),[i,o]=(0,a.useState)(null),[s,d]=(0,a.useState)(null);return(0,a.useEffect)(()=>{if(!t)return;n(null),o(null),d(null);let e=!1;return fetch(r.queryKey.file(t),{headers:{range:`bytes=0-${g.WORKSPACE_VIEW.textMax-1}`}}).then(async t=>{if(!t.ok)throw Error(await t.text());return{text:await t.text(),of:function(t){let e=t.headers.get("content-range")?.match(/^bytes \d+-(\d+)\/(\d+)$/);if(!e)return null;let[,a,r]=e.map(Number);return a+1<r?r:null}(t)}}).then(({text:t,of:a})=>{e||(n(null===a?t:t.slice(0,t.lastIndexOf("\n")+1||void 0)),d(a))}).catch(t=>!e&&o((0,l.errorToString)(t))),()=>{e=!0}},[t]),{content:e,failure:i,truncated:s}}function F({path:t,bytes:a}){let[r,i]=(0,N.useServerAction)(S);return(0,e.jsxs)("div",{className:"space-y-4 p-8",children:[(0,e.jsxs)("p",{className:"max-w-lg text-sm leading-relaxed text-muted-foreground",children:[`This file is ${(0,l.formatBytes)(a)} — too big to draw here without `,"taking the window with it. Open it where it is instead."]}),(0,e.jsx)(n.Button,{variant:"outline",loading:i,onClick:()=>r(t),children:"Reveal in the file manager"})]})}function B({path:t,kind:a,onClose:r}){let{content:n,failure:o,truncated:l}=W(t),d=t?.split("/").pop()??"";return(0,e.jsx)(i.Dialog,{open:null!==t,onOpenChange:t=>!t&&r(),children:(0,e.jsxs)(i.DialogContent,{className:"flex max-h-[calc(100vh-3rem)] flex-col gap-0 overflow-hidden p-0 sm:max-w-4xl",children:[(0,e.jsx)(i.DialogTitle,{className:"sr-only",children:d}),(0,e.jsx)("div",{className:"flex shrink-0 items-center gap-2 border-b border-border/60 px-4 py-2.5 pr-12",children:(0,e.jsx)("span",{className:"min-w-0 flex-1 truncate font-mono text-[12px]",children:t})}),(0,e.jsx)("div",{className:"min-h-0 flex-1 overflow-auto",children:o?(0,e.jsx)("p",{className:"p-5 font-mono text-xs text-destructive",children:o}):null===n?(0,e.jsxs)("div",{className:"space-y-3 p-5",children:[(0,e.jsx)(s.Skeleton,{className:"h-5 w-2/3"}),(0,e.jsx)(s.Skeleton,{className:"h-4 w-full"}),(0,e.jsx)(s.Skeleton,{className:"h-4 w-5/6"})]}):(0,e.jsx)(T,{kind:a,content:n,truncated:l})})]})})}function E({text:t,className:a}){return(0,e.jsx)("pre",{className:(0,l.cn)("overflow-x-auto font-mono text-[12px] leading-relaxed whitespace-pre-wrap text-foreground/90",a),children:t})}function L({content:t,className:r}){let[n,...i]=(0,a.useMemo)(()=>(function(t){let e=[],a=[],r="",n=!1;for(let i=0;i<t.length;i++){let o=t[i];n?'"'===o&&'"'===t[i+1]?(r+='"',i++):'"'===o?n=!1:r+=o:'"'===o?n=!0:","===o?(a.push(r),r=""):"\n"===o||"\r"===o?("\r"===o&&"\n"===t[i+1]&&i++,a.push(r),e.push(a),a=[],r=""):r+=o}return(r.length||a.length)&&(a.push(r),e.push(a)),e.filter(t=>t.some(t=>t.trim()))})(t),[t]);return n?(0,e.jsx)("div",{className:(0,l.cn)("overflow-x-auto",r),children:(0,e.jsxs)(d,{children:[(0,e.jsx)(u,{children:(0,e.jsx)(h,{children:n.map((t,a)=>(0,e.jsx)(f,{className:"whitespace-nowrap",children:t},`${a}-${t}`))})}),(0,e.jsx)(c,{children:i.map((t,a)=>(0,e.jsx)(h,{children:n.map((r,n)=>(0,e.jsx)(m,{className:"whitespace-nowrap",children:t[n]??""},`${a}-${n}`))},`${a}-${t[0]??""}`))})]})}):(0,e.jsx)(E,{text:t,className:r})}t.s(["FileBody",0,T,"FileDialog",0,B,"FileLink",0,function({path:t,className:n,title:i,label:o,children:s}){let l=D(t),d=(0,a.useContext)(C),[u,c]=(0,N.useServerAction)(S);return"tab"===l.how?(0,e.jsx)("a",{href:l.href,target:"_blank",rel:"noreferrer",title:i??t,"aria-label":o,className:n,children:s}):(0,e.jsx)("button",{type:"button",disabled:c,title:i??t,"aria-label":o,className:n,onClick:()=>{"dialog"===l.how?d?d(l.path):window.open(r.queryKey.fileView(l.path),"_blank"):u(t)},children:s})},"FilePreview",0,function({path:t,bytes:a}){let n=y(t),{content:i,failure:o,truncated:l}=W(j.has(n)?null:t);return("frame"===n||"image"===n)&&a>g.WORKSPACE_VIEW.elementMax?(0,e.jsx)(F,{path:t,bytes:a}):"frame"===n?(0,e.jsx)("iframe",{title:t,src:r.queryKey.file(t),allow:"clipboard-read; clipboard-write; fullscreen; autoplay",className:"h-full w-full bg-white"}):"image"===n?(0,e.jsx)("img",{src:r.queryKey.file(t),alt:t,className:"mx-auto max-w-full p-6"}):"audio"===n||"video"===n?"audio"===n?(0,e.jsx)("audio",{controls:!0,src:r.queryKey.file(t),className:"w-full p-6",children:(0,e.jsx)("track",{kind:"captions"})}):(0,e.jsx)("video",{controls:!0,src:r.queryKey.file(t),className:"max-w-full p-6",children:(0,e.jsx)("track",{kind:"captions"})}):o?(0,e.jsx)("p",{className:"p-5 font-mono text-xs text-destructive",children:o}):null===i?(0,e.jsxs)("div",{className:"space-y-3 p-5",children:[(0,e.jsx)(s.Skeleton,{className:"h-5 w-2/3"}),(0,e.jsx)(s.Skeleton,{className:"h-4 w-full"}),(0,e.jsx)(s.Skeleton,{className:"h-4 w-5/6"})]}):(0,e.jsx)(T,{kind:n,content:i,truncated:l})},"FileViewer",0,function({children:t}){let[r,n]=(0,a.useState)(null);return(0,e.jsxs)(C,{value:n,children:[t,(0,e.jsx)(B,{path:r,kind:r?y(r):"text",onClose:()=>n(null)})]})},"fileTarget",0,D,"useFileText",0,W,"useOpenFile",0,function(){let t=(0,a.useContext)(C);return(0,a.useCallback)(e=>{let a=D(e);if("os"===a.how)return!1;if("dialog"===a.how&&t)return t(a.path),!0;let n="tab"===a.how?a.href:r.queryKey.fileView(a.path);return null!==window.open(n,"_blank")},[t])}],621285)},245629,t=>{"use strict";var e=t.i(401851),a=t.i(677241),r=t.i(24708),n=t.i(845110),i=t.i(585890);function o(t,e,a){let[r,o]=(0,n.normalizeDates)(a?.in,t,e);return+(0,i.startOfDay)(r)==+(0,i.startOfDay)(o)}var s=t.i(281092),l=t.i(681307);let d=l.z.union([l.z.date(),l.z.iso.datetime()]),u=t=>new Date(t);t.s(["DateLikeSchema",0,d,"shortAgo",0,function(t,e=Date.now()){let a=Math.max(0,Math.round((e-u(t).getTime())/1e3));if(a<60)return"now";let r=Math.round(a/60);if(r<60)return`${r}m`;let n=Math.round(r/60);return n<24?`${n}h`:`${Math.round(n/24)}d`},"toDate",0,u,"whenOf",0,function(t){let n=u(t),i=(0,e.format)(n,"HH:mm");return o((0,a.constructFrom)(n,n),(0,r.constructNow)(n))?i:!function(t){var e,n;let i;return o((0,a.constructFrom)(t,t),(e=(0,r.constructNow)(t),n=void 0,i=(0,s.toDate)(e,n?.in),isNaN(-1)?(0,a.constructFrom)(n?.in||e,NaN):(i.setDate(i.getDate()+-1),i)))}(n)?`${(0,e.format)(n,"MMM d")} \xb7 ${i}`:`Yesterday ${i}`}],245629)},677241,234662,t=>{"use strict";let e=Symbol.for("constructDateFrom");t.s(["constructFromSymbol",0,e,"millisecondsInDay",0,864e5,"millisecondsInMinute",0,6e4,"millisecondsInWeek",0,6048e5,"minutesInDay",0,1440,"minutesInMonth",0,43200,"minutesInYear",0,525600],234662),t.s(["constructFrom",0,function(t,a){return"function"==typeof t?t(a):t&&"object"==typeof t&&e in t?t[e](a):t instanceof Date?new t.constructor(a):new Date(a)}],677241)},24708,t=>{"use strict";var e=t.i(677241);t.s(["constructNow",0,function(t){return(0,e.constructFrom)(t,Date.now())}])},401851,281092,99151,845110,585890,t=>{"use strict";var e=t.i(55545),a=t.i(455024),r=t.i(677241);function n(t,e){return(0,r.constructFrom)(e||t,t)}function i(t){let e=n(t),a=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));return a.setUTCFullYear(e.getFullYear()),t-a}function o(t,...e){let a=r.constructFrom.bind(null,t||e.find(t=>"object"==typeof t));return e.map(a)}t.s(["toDate",0,n],281092),t.s(["getTimezoneOffsetInMilliseconds",0,i],99151),t.s(["normalizeDates",0,o],845110);var s=t.i(234662);function l(t,e){let a=n(t,e?.in);return a.setHours(0,0,0,0),a}function d(t,e){let r=(0,a.getDefaultOptions)(),i=e?.weekStartsOn??e?.locale?.options?.weekStartsOn??r.weekStartsOn??r.locale?.options?.weekStartsOn??0,o=n(t,e?.in),s=o.getDay();return o.setDate(o.getDate()-(7*(s<i)+s-i)),o.setHours(0,0,0,0),o}function u(t,e){return d(t,{...e,weekStartsOn:1})}function c(t,e){let a=n(t,e?.in),i=a.getFullYear(),o=(0,r.constructFrom)(a,0);o.setFullYear(i+1,0,4),o.setHours(0,0,0,0);let s=u(o),l=(0,r.constructFrom)(a,0);l.setFullYear(i,0,4),l.setHours(0,0,0,0);let d=u(l);return a.getTime()>=s.getTime()?i+1:a.getTime()>=d.getTime()?i:i-1}function h(t,e){let i=n(t,e?.in),o=i.getFullYear(),s=(0,a.getDefaultOptions)(),l=e?.firstWeekContainsDate??e?.locale?.options?.firstWeekContainsDate??s.firstWeekContainsDate??s.locale?.options?.firstWeekContainsDate??1,u=(0,r.constructFrom)(e?.in||t,0);u.setFullYear(o+1,0,l),u.setHours(0,0,0,0);let c=d(u,e),h=(0,r.constructFrom)(e?.in||t,0);h.setFullYear(o,0,l),h.setHours(0,0,0,0);let f=d(h,e);return+i>=+c?o+1:+i>=+f?o:o-1}function f(t,e){let a=Math.abs(t).toString().padStart(e,"0");return(t<0?"-":"")+a}t.s(["startOfDay",0,l],585890);let m={y(t,e){let a=t.getFullYear(),r=a>0?a:1-a;return f("yy"===e?r%100:r,e.length)},M(t,e){let a=t.getMonth();return"M"===e?String(a+1):f(a+1,2)},d:(t,e)=>f(t.getDate(),e.length),a(t,e){let a=t.getHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return a.toUpperCase();case"aaa":return a;case"aaaaa":return a[0];default:return"am"===a?"a.m.":"p.m."}},h:(t,e)=>f(t.getHours()%12||12,e.length),H:(t,e)=>f(t.getHours(),e.length),m:(t,e)=>f(t.getMinutes(),e.length),s:(t,e)=>f(t.getSeconds(),e.length),S(t,e){let a=e.length;return f(Math.trunc(t.getMilliseconds()*Math.pow(10,a-3)),e.length)}},g={G:function(t,e,a){let r=+(t.getFullYear()>0);switch(e){case"G":case"GG":case"GGG":return a.era(r,{width:"abbreviated"});case"GGGGG":return a.era(r,{width:"narrow"});default:return a.era(r,{width:"wide"})}},y:function(t,e,a){if("yo"===e){let e=t.getFullYear();return a.ordinalNumber(e>0?e:1-e,{unit:"year"})}return m.y(t,e)},Y:function(t,e,a,r){let n=h(t,r),i=n>0?n:1-n;return"YY"===e?f(i%100,2):"Yo"===e?a.ordinalNumber(i,{unit:"year"}):f(i,e.length)},R:function(t,e){return f(c(t),e.length)},u:function(t,e){return f(t.getFullYear(),e.length)},Q:function(t,e,a){let r=Math.ceil((t.getMonth()+1)/3);switch(e){case"Q":return String(r);case"QQ":return f(r,2);case"Qo":return a.ordinalNumber(r,{unit:"quarter"});case"QQQ":return a.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return a.quarter(r,{width:"narrow",context:"formatting"});default:return a.quarter(r,{width:"wide",context:"formatting"})}},q:function(t,e,a){let r=Math.ceil((t.getMonth()+1)/3);switch(e){case"q":return String(r);case"qq":return f(r,2);case"qo":return a.ordinalNumber(r,{unit:"quarter"});case"qqq":return a.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return a.quarter(r,{width:"narrow",context:"standalone"});default:return a.quarter(r,{width:"wide",context:"standalone"})}},M:function(t,e,a){let r=t.getMonth();switch(e){case"M":case"MM":return m.M(t,e);case"Mo":return a.ordinalNumber(r+1,{unit:"month"});case"MMM":return a.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return a.month(r,{width:"narrow",context:"formatting"});default:return a.month(r,{width:"wide",context:"formatting"})}},L:function(t,e,a){let r=t.getMonth();switch(e){case"L":return String(r+1);case"LL":return f(r+1,2);case"Lo":return a.ordinalNumber(r+1,{unit:"month"});case"LLL":return a.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return a.month(r,{width:"narrow",context:"standalone"});default:return a.month(r,{width:"wide",context:"standalone"})}},w:function(t,e,i,o){let l,u,c,m,g,w=Math.round((d(l=n(t,o?.in),o)-(u=(0,a.getDefaultOptions)(),c=o?.firstWeekContainsDate??o?.locale?.options?.firstWeekContainsDate??u.firstWeekContainsDate??u.locale?.options?.firstWeekContainsDate??1,m=h(l,o),(g=(0,r.constructFrom)(o?.in||l,0)).setFullYear(m,0,c),g.setHours(0,0,0,0),d(g,o)))/s.millisecondsInWeek)+1;return"wo"===e?i.ordinalNumber(w,{unit:"week"}):f(w,e.length)},I:function(t,e,a){let i,o,l,d=Math.round((u(i=n(t,void 0))-(o=c(i,void 0),(l=(0,r.constructFrom)(i,0)).setFullYear(o,0,4),l.setHours(0,0,0,0),u(l)))/s.millisecondsInWeek)+1;return"Io"===e?a.ordinalNumber(d,{unit:"week"}):f(d,e.length)},d:function(t,e,a){return"do"===e?a.ordinalNumber(t.getDate(),{unit:"date"}):m.d(t,e)},D:function(t,e,a){let r,d,u=function(t,e){let[a,r]=o(void 0,t,e),n=l(a),d=l(r);return Math.round((n-i(n)-(d-i(d)))/s.millisecondsInDay)}(d=n(t,void 0),((r=n(d,void 0)).setFullYear(r.getFullYear(),0,1),r.setHours(0,0,0,0),r))+1;return"Do"===e?a.ordinalNumber(u,{unit:"dayOfYear"}):f(u,e.length)},E:function(t,e,a){let r=t.getDay();switch(e){case"E":case"EE":case"EEE":return a.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return a.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return a.day(r,{width:"short",context:"formatting"});default:return a.day(r,{width:"wide",context:"formatting"})}},e:function(t,e,a,r){let n=t.getDay(),i=(n-r.weekStartsOn+8)%7||7;switch(e){case"e":return String(i);case"ee":return f(i,2);case"eo":return a.ordinalNumber(i,{unit:"day"});case"eee":return a.day(n,{width:"abbreviated",context:"formatting"});case"eeeee":return a.day(n,{width:"narrow",context:"formatting"});case"eeeeee":return a.day(n,{width:"short",context:"formatting"});default:return a.day(n,{width:"wide",context:"formatting"})}},c:function(t,e,a,r){let n=t.getDay(),i=(n-r.weekStartsOn+8)%7||7;switch(e){case"c":return String(i);case"cc":return f(i,e.length);case"co":return a.ordinalNumber(i,{unit:"day"});case"ccc":return a.day(n,{width:"abbreviated",context:"standalone"});case"ccccc":return a.day(n,{width:"narrow",context:"standalone"});case"cccccc":return a.day(n,{width:"short",context:"standalone"});default:return a.day(n,{width:"wide",context:"standalone"})}},i:function(t,e,a){let r=t.getDay(),n=0===r?7:r;switch(e){case"i":return String(n);case"ii":return f(n,e.length);case"io":return a.ordinalNumber(n,{unit:"day"});case"iii":return a.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return a.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return a.day(r,{width:"short",context:"formatting"});default:return a.day(r,{width:"wide",context:"formatting"})}},a:function(t,e,a){let r=t.getHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return a.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"aaa":return a.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return a.dayPeriod(r,{width:"narrow",context:"formatting"});default:return a.dayPeriod(r,{width:"wide",context:"formatting"})}},b:function(t,e,a){let r,n=t.getHours();switch(r=12===n?"noon":0===n?"midnight":n/12>=1?"pm":"am",e){case"b":case"bb":return a.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"bbb":return a.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return a.dayPeriod(r,{width:"narrow",context:"formatting"});default:return a.dayPeriod(r,{width:"wide",context:"formatting"})}},B:function(t,e,a){let r,n=t.getHours();switch(r=n>=17?"evening":n>=12?"afternoon":n>=4?"morning":"night",e){case"B":case"BB":case"BBB":return a.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"BBBBB":return a.dayPeriod(r,{width:"narrow",context:"formatting"});default:return a.dayPeriod(r,{width:"wide",context:"formatting"})}},h:function(t,e,a){if("ho"===e){let e=t.getHours()%12;return 0===e&&(e=12),a.ordinalNumber(e,{unit:"hour"})}return m.h(t,e)},H:function(t,e,a){return"Ho"===e?a.ordinalNumber(t.getHours(),{unit:"hour"}):m.H(t,e)},K:function(t,e,a){let r=t.getHours()%12;return"Ko"===e?a.ordinalNumber(r,{unit:"hour"}):f(r,e.length)},k:function(t,e,a){let r=t.getHours();return(0===r&&(r=24),"ko"===e)?a.ordinalNumber(r,{unit:"hour"}):f(r,e.length)},m:function(t,e,a){return"mo"===e?a.ordinalNumber(t.getMinutes(),{unit:"minute"}):m.m(t,e)},s:function(t,e,a){return"so"===e?a.ordinalNumber(t.getSeconds(),{unit:"second"}):m.s(t,e)},S:function(t,e){return m.S(t,e)},X:function(t,e,a){let r=t.getTimezoneOffset();if(0===r)return"Z";switch(e){case"X":return p(r);case"XXXX":case"XX":return y(r);default:return y(r,":")}},x:function(t,e,a){let r=t.getTimezoneOffset();switch(e){case"x":return p(r);case"xxxx":case"xx":return y(r);default:return y(r,":")}},O:function(t,e,a){let r=t.getTimezoneOffset();switch(e){case"O":case"OO":case"OOO":return"GMT"+w(r,":");default:return"GMT"+y(r,":")}},z:function(t,e,a){let r=t.getTimezoneOffset();switch(e){case"z":case"zz":case"zzz":return"GMT"+w(r,":");default:return"GMT"+y(r,":")}},t:function(t,e,a){return f(Math.trunc(t/1e3),e.length)},T:function(t,e,a){return f(+t,e.length)}};function w(t,e=""){let a=t>0?"-":"+",r=Math.abs(t),n=Math.trunc(r/60),i=r%60;return 0===i?a+String(n):a+String(n)+e+f(i,2)}function p(t,e){return t%60==0?(t>0?"-":"+")+f(Math.abs(t)/60,2):y(t,e)}function y(t,e=""){let a=Math.abs(t);return(t>0?"-":"+")+f(Math.trunc(a/60),2)+e+f(a%60,2)}let b=(t,e)=>{switch(t){case"P":return e.date({width:"short"});case"PP":return e.date({width:"medium"});case"PPP":return e.date({width:"long"});default:return e.date({width:"full"})}},x=(t,e)=>{switch(t){case"p":return e.time({width:"short"});case"pp":return e.time({width:"medium"});case"ppp":return e.time({width:"long"});default:return e.time({width:"full"})}},k={p:x,P:(t,e)=>{let a,r=t.match(/(P+)(p+)?/)||[],n=r[1],i=r[2];if(!i)return b(t,e);switch(n){case"P":a=e.dateTime({width:"short"});break;case"PP":a=e.dateTime({width:"medium"});break;case"PPP":a=e.dateTime({width:"long"});break;default:a=e.dateTime({width:"full"})}return a.replace("{{date}}",b(n,e)).replace("{{time}}",x(i,e))}},v=/^D+$/,M=/^Y+$/,S=["D","DD","YY","YYYY"],N=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,j=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,D=/^'([^]*?)'?$/,C=/''/g,_=/[a-zA-Z]/;t.s(["format",0,function(t,r,i){let o=(0,a.getDefaultOptions)(),s=i?.locale??o.locale??e.defaultLocale,l=i?.firstWeekContainsDate??i?.locale?.options?.firstWeekContainsDate??o.firstWeekContainsDate??o.locale?.options?.firstWeekContainsDate??1,d=i?.weekStartsOn??i?.locale?.options?.weekStartsOn??o.weekStartsOn??o.locale?.options?.weekStartsOn??0,u=n(t,i?.in);if(!(u instanceof Date||"object"==typeof u&&"[object Date]"===Object.prototype.toString.call(u))&&"number"!=typeof u||isNaN(+n(u)))throw RangeError("Invalid time value");let c=r.match(j).map(t=>{let e=t[0];return"p"===e||"P"===e?(0,k[e])(t,s.formatLong):t}).join("").match(N).map(t=>{if("''"===t)return{isToken:!1,value:"'"};let e=t[0];if("'"===e){var a;let e;return{isToken:!1,value:(e=(a=t).match(D))?e[1].replace(C,"'"):a}}if(g[e])return{isToken:!0,value:t};if(e.match(_))throw RangeError("Format string contains an unescaped latin alphabet character `"+e+"`");return{isToken:!1,value:t}});s.localize.preprocessor&&(c=s.localize.preprocessor(u,c));let h={firstWeekContainsDate:l,weekStartsOn:d,locale:s};return c.map(e=>{if(!e.isToken)return e.value;let a=e.value;return(!i?.useAdditionalWeekYearTokens&&M.test(a)||!i?.useAdditionalDayOfYearTokens&&v.test(a))&&function(t,e,a){var r,n,i;let o,s=(r=t,n=e,i=a,o="Y"===r[0]?"years":"days of the month",`Use \`${r.toLowerCase()}\` instead of \`${r}\` (in \`${n}\`) for formatting ${o} to the input \`${i}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`);if(console.warn(s),S.includes(t))throw RangeError(s)}(a,r,String(t)),(0,g[a[0]])(u,a,s.localize,h)}).join("")}],401851)},55545,455024,t=>{"use strict";var e;let a={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}};function r(t){return (e={})=>{let a=e.width?String(e.width):t.defaultWidth;return t.formats[a]||t.formats[t.defaultWidth]}}let n={date:r({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:r({formats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},defaultWidth:"full"}),dateTime:r({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},i={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function o(t){return(e,a)=>{let r;if("formatting"===(a?.context?String(a.context):"standalone")&&t.formattingValues){let e=t.defaultFormattingWidth||t.defaultWidth,n=a?.width?String(a.width):e;r=t.formattingValues[n]||t.formattingValues[e]}else{let e=t.defaultWidth,n=a?.width?String(a.width):t.defaultWidth;r=t.values[n]||t.values[e]}return r[t.argumentCallback?t.argumentCallback(e):e]}}let s={ordinalNumber:(t,e)=>{let a=Number(t),r=a%100;if(r>20||r<10)switch(r%10){case 1:return a+"st";case 2:return a+"nd";case 3:return a+"rd"}return a+"th"},era:o({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:o({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},defaultWidth:"wide",argumentCallback:t=>t-1}),month:o({values:{narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},defaultWidth:"wide"}),day:o({values:{narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},defaultWidth:"wide"}),dayPeriod:o({values:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},defaultWidth:"wide",formattingValues:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},defaultFormattingWidth:"wide"})};function l(t){return(e,a={})=>{let r,n=a.width,i=n&&t.matchPatterns[n]||t.matchPatterns[t.defaultMatchWidth],o=e.match(i);if(!o)return null;let s=o[0],l=n&&t.parsePatterns[n]||t.parsePatterns[t.defaultParseWidth],d=Array.isArray(l)?function(t,e){for(let a=0;a<t.length;a++)if(e(t[a]))return a}(l,t=>t.test(s)):function(t,e){for(let a in t)if(Object.prototype.hasOwnProperty.call(t,a)&&e(t[a]))return a}(l,t=>t.test(s));return r=t.valueCallback?t.valueCallback(d):d,{value:r=a.valueCallback?a.valueCallback(r):r,rest:e.slice(s.length)}}}let d={ordinalNumber:(e={matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:t=>parseInt(t,10)},(t,a={})=>{let r=t.match(e.matchPattern);if(!r)return null;let n=r[0],i=t.match(e.parsePattern);if(!i)return null;let o=e.valueCallback?e.valueCallback(i[0]):i[0];return{value:o=a.valueCallback?a.valueCallback(o):o,rest:t.slice(n.length)}}),era:l({matchPatterns:{narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:"any"}),quarter:l({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:t=>t+1}),month:l({matchPatterns:{narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:"any"}),day:l({matchPatterns:{narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},defaultParseWidth:"any"}),dayPeriod:l({matchPatterns:{narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},defaultParseWidth:"any"})};t.s(["defaultLocale",0,{code:"en-US",formatDistance:(t,e,r)=>{let n,i=a[t];if(n="string"==typeof i?i:1===e?i.one:i.other.replace("{{count}}",e.toString()),r?.addSuffix)if(r.comparison&&r.comparison>0)return"in "+n;else return n+" ago";return n},formatLong:n,formatRelative:(t,e,a,r)=>i[t],localize:s,match:d,options:{weekStartsOn:0,firstWeekContainsDate:1}}],55545);let u={};t.s(["getDefaultOptions",0,function(){return u}],455024)},482022,t=>{"use strict";var e=t.i(456420);let a={name:"external-link",size:24,node:[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]]};a.node;let r=(0,e.default)(a);t.s(["ExternalLink",0,r],482022)},696017,t=>{"use strict";var e=t.i(60231),a=t.i(419524);t.i(947716);var r=t.i(723685),n=(0,a.__name)(t=>{let{securityLevel:a}=(0,e.getConfig2)(),n=(0,r.select)("body");if("sandbox"===a){let e=(0,r.select)(`#i${t}`),a=e.node()?.contentDocument??document;n=(0,r.select)(a.body)}return n.select(`#${t}`)},"selectSvgElement");t.s(["selectSvgElement",0,n])},502056,t=>{"use strict";var e=t.i(217248),a=t.i(447804),r=t.i(508324),n=t.i(419524),i=(0,n.__name)(({flowchart:t})=>{let e=t?.subGraphTitleMargin?.top??0,a=t?.subGraphTitleMargin?.bottom??0;return{subGraphTitleTopMargin:e,subGraphTitleBottomMargin:a,subGraphTitleTotalMargin:e+a}},"getSubGraphTitleMargins"),o=new Map;async function s(t,r,n){let i,s;"rect"===r.shape&&(r.rx&&r.ry?r.shape="roundedRect":r.shape="squareRect");let l=r.shape?e.shapes[r.shape]:void 0;if(!l)throw Error(`No such shape: ${r.shape}. Please check your syntax.`);if(r.link){let e;"sandbox"===n.config.securityLevel?e="_top":r.linkTarget&&(e=r.linkTarget||"_blank"),i=t.insert("svg:a").attr("xlink:href",r.link).attr("target",e??null),s=await l(i,r,n)}else i=s=await l(t,r,n);return i.attr("data-look",(0,a.handleUndefinedAttr)(r.look)),r.tooltip&&s.attr("title",r.tooltip),o.set(r.id,i),r.haveCallback&&i.attr("class",i.attr("class")+" clickable"),i}(0,n.__name)(s,"insertNode");var l=(0,n.__name)((t,e)=>{o.set(e.id,t)},"setNodeElem"),d=(0,n.__name)(()=>{o.clear()},"clear"),u=(0,n.__name)(t=>{let e=o.get(t.id);r.log.trace("Transforming node",t.diff,t,"translate("+(t.x-t.width/2-5)+", "+t.width/2+")");let a=t.diff||0;return t.clusterNode?e.attr("transform","translate("+(t.x+a-t.width/2)+", "+(t.y-t.height/2-8)+")"):e.attr("transform","translate("+t.x+", "+t.y+")"),a},"positionNode");t.s(["clear",0,d,"getSubGraphTitleMargins",0,i,"insertNode",0,s,"positionNode",0,u,"setNodeElem",0,l])},369110,t=>{"use strict";var e=t.i(502056),a=t.i(217248),r=t.i(224797),n=t.i(836333),i=t.i(60231),o=t.i(508324),s=t.i(419524);t.i(947716);var l=t.i(723685),d=t.i(883272),u=(0,s.__name)(async(t,e)=>{let s,u,c=(0,i.getConfig2)(),{themeVariables:h,handDrawnSeed:f}=c,{clusterBkg:m,clusterBorder:g}=h,{labelStyles:w,nodeStyles:p,borderStyles:y,backgroundStyles:b}=(0,r.styles2String)(e),x=t.insert("g").attr("class","cluster swimlane "+(e.cssClasses||"")).attr("id",e.id).attr("data-id",e.id).attr("data-et","cluster").attr("data-look",e.look),k=(0,i.evaluate)(c.flowchart.htmlLabels),v="LR"===e.direction,M=x.insert("g").attr("class","cluster-label swimlane-label"),S=await (0,n.createText)(M,e.label,{style:e.labelStyle,useHtmlLabels:k,isNode:!0,width:e.width}),N=S.getBBox();if(k){let t=S.children[0],e=(0,l.select)(S);N=t.getBoundingClientRect(),e.attr("width",N.width),e.attr("height",N.height)}let j=e.padding??0,D=e.width<=N.width+j?N.width+j:e.width;e.width<=N.width+j?e.diff=(D-e.width)/2-j:e.diff=-j;let C=e.height,_=e.y-C/2,T=e.y+C/2,P=e.x-D/2,O=void 0!==e.swimlaneContentTop?e.swimlaneContentTop:_+C/3,W=4*!!v,F=N.height+2*W;if(v){let t=Math.max(F,N.height+2*W),a=P+t,n=Math.max(0,D-t);if("handDrawn"===e.look){let i=d.default.svg(x),o=(0,r.userNodeOverrides)(e,{roughness:.7,fill:m,stroke:g,fillWeight:3,seed:f}),l=(0,r.userNodeOverrides)(e,{roughness:.7,fill:"none",stroke:g,seed:f}),c=i.rectangle(P,_,t,C,o);s=x.insert(()=>c,":first-child");let h=i.rectangle(a,_,n,C,l);u=x.insert(()=>h,":first-child"),s.select("path:nth-child(2)").attr("style",y.join(";")),s.select("path").attr("style",b.join(";").replace("fill","stroke"))}else s=x.insert("rect",":first-child"),u=x.insert("rect",":first-child"),s.attr("class","swimlane-title").attr("style",p).attr("x",P).attr("y",_).attr("width",t).attr("height",C).attr("fill",m).attr("stroke",g),u.attr("class","swimlane-body").attr("style",p).attr("x",a).attr("y",_).attr("width",n).attr("height",C).attr("fill","none").attr("stroke",g);let i=P+t/2,o=e.y;M.attr("transform",`translate(${i}, ${o}) rotate(-90) translate(${-N.width/2}, ${-N.height/2})`)}else{let t=Math.min(F,Math.max(0,O-_)),a=_+t,n=Math.max(0,T-a),i=e.x-D/2;if("handDrawn"===e.look){let o=d.default.svg(x),l=(0,r.userNodeOverrides)(e,{roughness:.7,fill:m,stroke:g,fillWeight:3,seed:f}),c=(0,r.userNodeOverrides)(e,{roughness:.7,fill:"none",stroke:g,seed:f}),h=o.rectangle(i,_,D,t,l);s=x.insert(()=>h,":first-child");let w=o.rectangle(i,a,D,n,c);u=x.insert(()=>w,":first-child"),s.select("path:nth-child(2)").attr("style",y.join(";")),s.select("path").attr("style",b.join(";").replace("fill","stroke"))}else s=x.insert("rect",":first-child"),u=x.insert("rect",":first-child"),s.attr("class","swimlane-title").attr("style",p).attr("x",i).attr("y",_).attr("width",D).attr("height",t).attr("fill",m).attr("stroke",g),u.attr("class","swimlane-body").attr("style",p).attr("x",i).attr("y",a).attr("width",D).attr("height",n).attr("fill","none").attr("stroke",g);let o=e.x-N.width/2,l=_+(t-N.height)/2;M.attr("transform",`translate(${o}, ${l})`)}if(o.log.trace("Swimlane data ",e,JSON.stringify(e)),w){let t=M.select("span");t&&t.attr("style",w)}return e.offsetX=0,e.width=D,e.height=C,e.offsetY=N.height-j/2,e.intersect=function(t){return(0,a.intersect_rect_default)(e,t)},{cluster:x,labelBBox:N}},"swimlane"),c=(0,s.__name)(async(t,s)=>{let u,c;o.log.info("Creating subgraph rect for ",s.id,s);let h=(0,i.getConfig2)(),{themeVariables:f,handDrawnSeed:m}=h,{clusterBkg:g,clusterBorder:w}=f,{labelStyles:p,nodeStyles:y,borderStyles:b,backgroundStyles:x}=(0,r.styles2String)(s),k=t.insert("g").attr("class","cluster "+s.cssClasses).attr("id",s.domId).attr("data-look",s.look),v=(0,i.getEffectiveHtmlLabels)(h),M=k.insert("g").attr("class","cluster-label "),S=(u="markdown"===s.labelType?await (0,n.createText)(M,s.label,{style:s.labelStyle,useHtmlLabels:v,isNode:!0,width:s.width}):await (0,a.createLabel_default)(M,s.label,s.labelStyle||"",!1,!0)).getBBox();if((0,i.getEffectiveHtmlLabels)(h)){let t=u.children[0],e=(0,l.select)(u);S=t.getBoundingClientRect(),e.attr("width",S.width),e.attr("height",S.height)}let N=s.width<=S.width+s.padding?S.width+s.padding:s.width;s.width<=S.width+s.padding?s.diff=(N-s.width)/2-s.padding:s.diff=-s.padding;let j=s.height,D=s.x-N/2,C=s.y-j/2;if(o.log.trace("Data ",s,JSON.stringify(s)),"handDrawn"===s.look){let t=d.default.svg(k),e=(0,r.userNodeOverrides)(s,{roughness:.7,fill:g,stroke:w,fillWeight:3,seed:m}),n=t.path((0,a.createRoundedRectPathD)(D,C,N,j,0),e);(c=k.insert(()=>(o.log.debug("Rough node insert CXC",n),n),":first-child")).select("path:nth-child(2)").attr("style",b.join(";")),c.select("path").attr("style",x.join(";").replace("fill","stroke"))}else(c=k.insert("rect",":first-child")).attr("style",y).attr("rx",s.rx).attr("ry",s.ry).attr("x",D).attr("y",C).attr("width",N).attr("height",j);let{subGraphTitleTopMargin:_}=(0,e.getSubGraphTitleMargins)(h);if(M.attr("transform",`translate(${s.x-S.width/2}, ${s.y-s.height/2+_})`),p){let t=M.select("span");t&&t.attr("style",p)}let T=c.node().getBBox();return s.offsetX=0,s.width=T.width,s.height=T.height,s.offsetY=S.height-s.padding/2,s.intersect=function(t){return(0,a.intersect_rect_default)(s,t)},{cluster:k,labelBBox:S}},"rect"),h=(0,s.__name)((t,e)=>{let r=t.insert("g").attr("class","note-cluster").attr("id",e.domId),n=r.insert("rect",":first-child"),i=0*e.padding,o=i/2;n.attr("rx",e.rx).attr("ry",e.ry).attr("x",e.x-e.width/2-o).attr("y",e.y-e.height/2-o).attr("width",e.width+i).attr("height",e.height+i).attr("fill","none");let s=n.node().getBBox();return e.width=s.width,e.height=s.height,e.intersect=function(t){return(0,a.intersect_rect_default)(e,t)},{cluster:r,labelBBox:{width:0,height:0}}},"noteGroup"),f=(0,s.__name)(async(t,e)=>{let r,n=(0,i.getConfig2)(),{themeVariables:o,handDrawnSeed:s}=n,{altBackground:u,compositeBackground:c,compositeTitleBackground:h,nodeBorder:f}=o,m=t.insert("g").attr("class",e.cssClasses).attr("id",e.domId).attr("data-id",e.id).attr("data-look",e.look),g=m.insert("g",":first-child"),w=m.insert("g").attr("class","cluster-label"),p=m.append("rect"),y=await (0,a.createLabel_default)(w,e.label,e.labelStyle,void 0,!0),b=y.getBBox();if((0,i.getEffectiveHtmlLabels)(n)){let t=y.children[0],e=(0,l.select)(y);b=t.getBoundingClientRect(),e.attr("width",b.width),e.attr("height",b.height)}let x=0*e.padding,k=(e.width<=b.width+e.padding?b.width+e.padding:e.width)+x;e.width<=b.width+e.padding?e.diff=(k-e.width)/2-e.padding:e.diff=-e.padding;let v=e.height+x,M=e.height+x-b.height-6,S=e.x-k/2,N=e.y-v/2;e.width=k;let j=e.y-e.height/2-x/2+b.height+2;if("handDrawn"===e.look){let t=e.cssClasses.includes("statediagram-cluster-alt"),n=d.default.svg(m),i=e.rx||e.ry?n.path((0,a.createRoundedRectPathD)(S,N,k,v,10),{roughness:.7,fill:h,fillStyle:"solid",stroke:f,seed:s}):n.rectangle(S,N,k,v,{seed:s});r=m.insert(()=>i,":first-child");let o=n.rectangle(S,j,k,M,{fill:t?u:c,fillStyle:t?"hachure":"solid",stroke:f,seed:s});r=m.insert(()=>i,":first-child"),p=m.insert(()=>o)}else(r=g.insert("rect",":first-child")).attr("class","outer").attr("x",S).attr("y",N).attr("width",k).attr("height",v).attr("data-look",e.look),p.attr("class","inner").attr("x",S).attr("y",j).attr("width",k).attr("height",M);return w.attr("transform",`translate(${e.x-b.width/2}, ${N+1-3*!(0,i.getEffectiveHtmlLabels)(n)})`),e.height=r.node().getBBox().height,e.offsetX=0,e.offsetY=b.height-e.padding/2,e.labelBBox=b,e.intersect=function(t){return(0,a.intersect_rect_default)(e,t)},{cluster:m,labelBBox:b}},"roundedWithTitle"),m=(0,s.__name)(async(t,s)=>{let u;o.log.info("Creating subgraph rect for ",s.id,s);let c=(0,i.getConfig2)(),{themeVariables:h,handDrawnSeed:f}=c,{clusterBkg:m,clusterBorder:g}=h,{labelStyles:w,nodeStyles:p,borderStyles:y,backgroundStyles:b}=(0,r.styles2String)(s),x=t.insert("g").attr("class","cluster "+s.cssClasses).attr("id",s.domId).attr("data-look",s.look),k=(0,i.getEffectiveHtmlLabels)(c),v=x.insert("g").attr("class","cluster-label "),M=await (0,n.createText)(v,s.label,{style:s.labelStyle,useHtmlLabels:k,isNode:!0,width:s.width}),S=M.getBBox();if((0,i.getEffectiveHtmlLabels)(c)){let t=M.children[0],e=(0,l.select)(M);S=t.getBoundingClientRect(),e.attr("width",S.width),e.attr("height",S.height)}let N=s.width<=S.width+s.padding?S.width+s.padding:s.width;s.width<=S.width+s.padding?s.diff=(N-s.width)/2-s.padding:s.diff=-s.padding;let j=s.height,D=s.x-N/2,C=s.y-j/2;if(o.log.trace("Data ",s,JSON.stringify(s)),"handDrawn"===s.look){let t=d.default.svg(x),e=(0,r.userNodeOverrides)(s,{roughness:.7,fill:m,stroke:g,fillWeight:4,seed:f}),n=t.path((0,a.createRoundedRectPathD)(D,C,N,j,s.rx),e);(u=x.insert(()=>(o.log.debug("Rough node insert CXC",n),n),":first-child")).select("path:nth-child(2)").attr("style",y.join(";")),u.select("path").attr("style",b.join(";").replace("fill","stroke"))}else(u=x.insert("rect",":first-child")).attr("style",p).attr("rx",s.rx).attr("ry",s.ry).attr("x",D).attr("y",C).attr("width",N).attr("height",j);let{subGraphTitleTopMargin:_}=(0,e.getSubGraphTitleMargins)(c);if(v.attr("transform",`translate(${s.x-S.width/2}, ${s.y-s.height/2+_})`),w){let t=v.select("span");t&&t.attr("style",w)}let T=u.node().getBBox();return s.offsetX=0,s.width=T.width,s.height=T.height,s.offsetY=S.height-s.padding/2,s.intersect=function(t){return(0,a.intersect_rect_default)(s,t)},{cluster:x,labelBBox:S}},"kanbanSection"),g={rect:c,squareRect:c,roundedWithTitle:f,noteGroup:h,divider:(0,s.__name)((t,e)=>{let r,{themeVariables:n,handDrawnSeed:o}=(0,i.getConfig2)(),{nodeBorder:s}=n,l=t.insert("g").attr("class",e.cssClasses).attr("id",e.domId).attr("data-look",e.look),u=l.insert("g",":first-child"),c=0*e.padding,h=e.width+c;e.diff=-e.padding;let f=e.height+c,m=e.x-h/2,g=e.y-f/2;if(e.width=h,"handDrawn"===e.look){let t=d.default.svg(l).rectangle(m,g,h,f,{fill:"lightgrey",roughness:.5,strokeLineDash:[5],stroke:s,seed:o});r=l.insert(()=>t,":first-child")}else{r=u.insert("rect",":first-child");let t="outer";e.look,t="divider",r.attr("class",t).attr("x",m).attr("y",g).attr("width",h).attr("height",f).attr("data-look",e.look)}return e.height=r.node().getBBox().height,e.offsetX=0,e.offsetY=0,e.intersect=function(t){return(0,a.intersect_rect_default)(e,t)},{cluster:l,labelBBox:{}}},"divider"),kanbanSection:m,swimlane:u},w=new Map,p=(0,s.__name)(async(t,e)=>{let a=e.shape||"rect",r=await g[a](t,e);return w.set(e.id,r),r},"insertCluster"),y=(0,s.__name)(()=>{w=new Map},"clear");t.s(["clear",0,y,"insertCluster",0,p])},121292,t=>{"use strict";var e=t.i(369110),a=t.i(382793),r=t.i(502056),n=t.i(217248),i=t.i(447804),o=t.i(60231),s=t.i(508324),l=t.i(419524),d={common:o.common_default,getConfig:o.getConfig,insertCluster:e.insertCluster,insertEdge:a.insertEdge,insertEdgeLabel:a.insertEdgeLabel,insertMarkers:a.markers_default,insertNode:r.insertNode,interpolateToCurve:i.interpolateToCurve,labelHelper:n.labelHelper,log:s.log,positionEdgeLabel:a.positionEdgeLabel},u={},c=(0,l.__name)(t=>{for(let e of t)u[e.name]=e},"registerLayoutLoaders");(0,l.__name)(()=>{c([{name:"dagre",loader:(0,l.__name)(async()=>await t.A(555153),"loader")},{name:"swimlane",loader:(0,l.__name)(async()=>await t.A(12782),"loader")},{name:"cose-bilkent",loader:(0,l.__name)(async()=>await t.A(208503),"loader")}])},"registerDefaultLayoutLoaders")();var h=(0,l.__name)(async(t,e)=>{if(!(t.layoutAlgorithm in u))throw Error(`Unknown layout algorithm: ${t.layoutAlgorithm}`);if(t.diagramId)for(let e of t.nodes){let a=e.domId||e.id;e.domId=`${t.diagramId}-${a}`}let a=u[t.layoutAlgorithm],r=await a.loader(),{theme:n,themeVariables:i}=t.config,{useGradient:o,gradientStart:s,gradientStop:l}=i,c=e.attr("id");if(e.append("defs").append("filter").attr("id",`${c}-drop-shadow`).attr("height","130%").attr("width","130%").append("feDropShadow").attr("dx","4").attr("dy","4").attr("stdDeviation",0).attr("flood-opacity","0.06").attr("flood-color",`${n?.includes("dark")?"#FFFFFF":"#000000"}`),e.append("defs").append("filter").attr("id",`${c}-drop-shadow-small`).attr("height","150%").attr("width","150%").append("feDropShadow").attr("dx","2").attr("dy","2").attr("stdDeviation",0).attr("flood-opacity","0.06").attr("flood-color",`${n?.includes("dark")?"#FFFFFF":"#000000"}`),o){let t=e.append("linearGradient").attr("id",e.attr("id")+"-gradient").attr("gradientUnits","objectBoundingBox").attr("x1","0%").attr("y1","0%").attr("x2","100%").attr("y2","0%");t.append("svg:stop").attr("offset","0%").attr("stop-color",s).attr("stop-opacity",1),t.append("svg:stop").attr("offset","100%").attr("stop-color",l).attr("stop-opacity",1)}return r.render(t,e,d,{algorithm:a.algorithm})},"render"),f=(0,l.__name)((t="",{fallback:e="dagre"}={})=>{if(t in u)return t;if(e in u)return s.log.warn(`Layout algorithm ${t} is not registered. Using ${e} as fallback.`),e;throw Error(`Both layout algorithms ${t} and ${e} are not registered.`)},"getRegisteredLayoutAlgorithm");t.s(["getRegisteredLayoutAlgorithm",0,f,"registerLayoutLoaders",0,c,"render",0,h])}]);
|
|
1
|
+
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,41533,t=>{"use strict";var e=t.i(247167);e.default.env.THURSDAY_APP_DIR?.trim()||e.default.cwd(),e.default.env.THURSDAY_HOME?.trim()||e.default.cwd(),e.default.env.THURSDAY_URL?.trim()||e.default.env.PORT?.trim();let a=".ai-workspace",r={workspace:a,artifacts:"artifacts",projects:"projects",scratch:"scratch",output:".output",skills:{default:"skills",custom:`${a}/.agents/skills`}};t.s(["APP_NAME",0,"Thursday","ARTIFACT_VIEW",0,{rows:200,setFiles:120},"BOT_RUN",0,{steps:25,compactAt:12e4,summaryWords:{min:600,max:3e3,perTokens:200},resumeMessages:20},"BROWSER_SKILL",0,"browser","PAGE_SIZE",0,50,"PATHS",0,r,"WORKSPACE_VIEW",0,{rows:200,textMax:524288,elementMax:0x3200000}])},621285,616172,808317,t=>{"use strict";var e=t.i(843476),a=t.i(271645),r=t.i(798120),n=t.i(167881),i=t.i(630374),o=t.i(683408),s=t.i(671428),l=t.i(647163);function d({className:t,...a}){return(0,e.jsx)("div",{"data-slot":"table-container",className:"relative w-full overflow-x-auto",children:(0,e.jsx)("table",{"data-slot":"table",className:(0,l.cn)("w-full caption-bottom text-sm",t),...a})})}function u({className:t,...a}){return(0,e.jsx)("thead",{"data-slot":"table-header",className:(0,l.cn)("[&_tr]:border-b",t),...a})}function c({className:t,...a}){return(0,e.jsx)("tbody",{"data-slot":"table-body",className:(0,l.cn)("[&_tr:last-child]:border-0",t),...a})}function h({className:t,...a}){return(0,e.jsx)("tr",{"data-slot":"table-row",className:(0,l.cn)("border-b border-border/60 transition-colors data-[state=selected]:bg-muted hover:bg-muted/40",t),...a})}function f({className:t,...a}){return(0,e.jsx)("th",{"data-slot":"table-head",className:(0,l.cn)("h-9 px-2 text-left align-middle font-mono text-[11px] font-normal tracking-[0.1em] whitespace-nowrap text-muted-foreground uppercase [&:has([role=checkbox])]:pr-0",t),...a})}function m({className:t,...a}){return(0,e.jsx)("td",{"data-slot":"table-cell",className:(0,l.cn)("p-2 align-middle [&:has([role=checkbox])]:pr-0",t),...a})}var g=t.i(41533);let w=t=>`text/${t}; charset=utf-8`,p={md:{kind:"markdown",mime:w("markdown")},markdown:{kind:"markdown",mime:w("markdown")},csv:{kind:"csv",mime:w("csv")},json:{kind:"json",mime:"application/json; charset=utf-8"},txt:{kind:"text",mime:w("plain")},log:{kind:"text",mime:w("plain")},html:{kind:"frame",mime:w("html")},htm:{kind:"frame",mime:w("html")},pdf:{kind:"frame",mime:"application/pdf"},png:{kind:"image",mime:"image/png"},jpg:{kind:"image",mime:"image/jpeg"},jpeg:{kind:"image",mime:"image/jpeg"},gif:{kind:"image",mime:"image/gif"},webp:{kind:"image",mime:"image/webp"},svg:{kind:"image",mime:"image/svg+xml"},mp3:{kind:"audio",mime:"audio/mpeg"},wav:{kind:"audio",mime:"audio/wav"},mp4:{kind:"video",mime:"video/mp4"},webm:{kind:"video",mime:"video/webm"},css:{kind:"none",mime:w("css")},js:{kind:"none",mime:w("javascript")},woff2:{kind:"none",mime:"font/woff2"}},y=t=>p[t.split(".").pop()?.toLowerCase()??""]?.kind??"none",b=Object.entries(p).filter(([,t])=>"none"!==t.kind).map(([t])=>t),x=RegExp(String.raw`(?<![\p{L}\p{N}_/:@%-])(?:[\p{L}\p{N}_.@%-]+/)*[\p{L}\p{N}_@%-]+(?:\.[\p{L}\p{N}_-]+)*\.(?:${b.join("|")})\b`,"giu"),k=`${g.PATHS.workspace}/`;function v(t){let e=t.trim(),a=e.indexOf(k);return a>=0?e.slice(a+k.length)||null:e.startsWith("/")||/^[A-Za-z]:/.test(e)||e.split("/").includes("..")?null:e||null}t.s(["pathsIn",0,function(t){let e=t.replace(/\b[a-z][\w+.-]*:\/\/\S+/gi," "),a=new Set;for(let t of e.match(x)??[]){let e=function(t){let e=v(t);if(!e)return null;let[a,...r]=e.split("/");return r.length&&a.includes(".")?null:e}(t);e&&a.add(e)}return[...a].slice(0,6)},"viewKindOf",0,y,"workspaceRelative",0,v],616172);var M=t.i(95187);let S=(0,M.createServerReference)("7f052a4d5cdc5c2b47d926a441b59fa063ccc51432",M.callServer,void 0,M.findSourceMapURL,"openFileAction");t.s(["openFileAction",0,S],808317);var N=t.i(609856);let j=new Set(["frame","image","audio","video"]);function D(t){let e=v(t);if(!e)return{how:"os"};let a=y(e);return j.has(a)?{how:"tab",path:e,href:r.queryKey.fileView(e)}:"none"===a?{how:"os"}:{how:"dialog",path:e}}let C=(0,a.createContext)(null),_={dialog:{prose:"px-5 py-4",block:"px-4 py-3"},page:{prose:"px-5 py-6 sm:px-8",block:"px-5 py-5"}};function T({kind:t,content:a,truncated:r,where:n="dialog"}){return(0,e.jsxs)(e.Fragment,{children:[null!=r&&(0,e.jsx)(P,{of:r}),(0,e.jsx)(O,{kind:t,content:a,where:n})]})}function P({of:t}){return(0,e.jsxs)("p",{className:"border-b border-border/60 px-5 py-2.5 font-mono text-[11px] text-muted-foreground",children:[`Showing the first ${(0,l.formatBytes)(g.WORKSPACE_VIEW.textMax)} of ${(0,l.formatBytes)(t)}. `,"Open the file itself for the rest."]})}function O({kind:t,content:a,where:r}){let n=_[r];switch(t){case"markdown":return(0,e.jsx)("div",{className:(0,l.cn)("min-w-0 text-sm leading-relaxed",n.prose),children:(0,e.jsx)(o.Markdown,{children:a})});case"csv":return(0,e.jsx)(L,{content:a,className:n.block});case"json":return(0,e.jsx)(E,{text:function(t){try{return JSON.stringify(JSON.parse(t),null,2)}catch{return t}}(a),className:n.block});default:return(0,e.jsx)(E,{text:a,className:n.block})}}function W(t){let[e,n]=(0,a.useState)(null),[i,o]=(0,a.useState)(null),[s,d]=(0,a.useState)(null);return(0,a.useEffect)(()=>{if(!t)return;n(null),o(null),d(null);let e=!1;return fetch(r.queryKey.file(t),{headers:{range:`bytes=0-${g.WORKSPACE_VIEW.textMax-1}`}}).then(async t=>{if(!t.ok)throw Error(await t.text());return{text:await t.text(),of:function(t){let e=t.headers.get("content-range")?.match(/^bytes \d+-(\d+)\/(\d+)$/);if(!e)return null;let[,a,r]=e.map(Number);return a+1<r?r:null}(t)}}).then(({text:t,of:a})=>{e||(n(null===a?t:t.slice(0,t.lastIndexOf("\n")+1||void 0)),d(a))}).catch(t=>!e&&o((0,l.errorToString)(t))),()=>{e=!0}},[t]),{content:e,failure:i,truncated:s}}function F({path:t,bytes:a}){let[r,i]=(0,N.useServerAction)(S);return(0,e.jsxs)("div",{className:"space-y-4 p-8",children:[(0,e.jsxs)("p",{className:"max-w-lg text-sm leading-relaxed text-muted-foreground",children:[`This file is ${(0,l.formatBytes)(a)} — too big to draw here without `,"taking the window with it. Open it where it is instead."]}),(0,e.jsx)(n.Button,{variant:"outline",loading:i,onClick:()=>r(t),children:"Reveal in the file manager"})]})}function B({path:t,kind:a,onClose:r}){let{content:n,failure:o,truncated:l}=W(t),d=t?.split("/").pop()??"";return(0,e.jsx)(i.Dialog,{open:null!==t,onOpenChange:t=>!t&&r(),children:(0,e.jsxs)(i.DialogContent,{className:"flex max-h-[calc(100vh-3rem)] flex-col gap-0 overflow-hidden p-0 sm:max-w-4xl",children:[(0,e.jsx)(i.DialogTitle,{className:"sr-only",children:d}),(0,e.jsx)("div",{className:"flex shrink-0 items-center gap-2 border-b border-border/60 px-4 py-2.5 pr-12",children:(0,e.jsx)("span",{className:"min-w-0 flex-1 truncate font-mono text-[12px]",children:t})}),(0,e.jsx)("div",{className:"min-h-0 flex-1 overflow-auto",children:o?(0,e.jsx)("p",{className:"p-5 font-mono text-xs text-destructive",children:o}):null===n?(0,e.jsxs)("div",{className:"space-y-3 p-5",children:[(0,e.jsx)(s.Skeleton,{className:"h-5 w-2/3"}),(0,e.jsx)(s.Skeleton,{className:"h-4 w-full"}),(0,e.jsx)(s.Skeleton,{className:"h-4 w-5/6"})]}):(0,e.jsx)(T,{kind:a,content:n,truncated:l})})]})})}function E({text:t,className:a}){return(0,e.jsx)("pre",{className:(0,l.cn)("overflow-x-auto font-mono text-[12px] leading-relaxed whitespace-pre-wrap text-foreground/90",a),children:t})}function L({content:t,className:r}){let[n,...i]=(0,a.useMemo)(()=>(function(t){let e=[],a=[],r="",n=!1;for(let i=0;i<t.length;i++){let o=t[i];n?'"'===o&&'"'===t[i+1]?(r+='"',i++):'"'===o?n=!1:r+=o:'"'===o?n=!0:","===o?(a.push(r),r=""):"\n"===o||"\r"===o?("\r"===o&&"\n"===t[i+1]&&i++,a.push(r),e.push(a),a=[],r=""):r+=o}return(r.length||a.length)&&(a.push(r),e.push(a)),e.filter(t=>t.some(t=>t.trim()))})(t),[t]);return n?(0,e.jsx)("div",{className:(0,l.cn)("overflow-x-auto",r),children:(0,e.jsxs)(d,{children:[(0,e.jsx)(u,{children:(0,e.jsx)(h,{children:n.map((t,a)=>(0,e.jsx)(f,{className:"whitespace-nowrap",children:t},`${a}-${t}`))})}),(0,e.jsx)(c,{children:i.map((t,a)=>(0,e.jsx)(h,{children:n.map((r,n)=>(0,e.jsx)(m,{className:"whitespace-nowrap",children:t[n]??""},`${a}-${n}`))},`${a}-${t[0]??""}`))})]})}):(0,e.jsx)(E,{text:t,className:r})}t.s(["FileBody",0,T,"FileDialog",0,B,"FileLink",0,function({path:t,className:n,title:i,label:o,children:s}){let l=D(t),d=(0,a.useContext)(C),[u,c]=(0,N.useServerAction)(S);return"tab"===l.how?(0,e.jsx)("a",{href:l.href,target:"_blank",rel:"noreferrer",title:i??t,"aria-label":o,className:n,children:s}):(0,e.jsx)("button",{type:"button",disabled:c,title:i??t,"aria-label":o,className:n,onClick:()=>{"dialog"===l.how?d?d(l.path):window.open(r.queryKey.fileView(l.path),"_blank"):u(t)},children:s})},"FilePreview",0,function({path:t,bytes:a}){let n=y(t),{content:i,failure:o,truncated:l}=W(j.has(n)?null:t);return("frame"===n||"image"===n)&&a>g.WORKSPACE_VIEW.elementMax?(0,e.jsx)(F,{path:t,bytes:a}):"frame"===n?(0,e.jsx)("iframe",{title:t,src:r.queryKey.file(t),allow:"clipboard-read; clipboard-write; fullscreen; autoplay",className:"h-full w-full bg-white"}):"image"===n?(0,e.jsx)("img",{src:r.queryKey.file(t),alt:t,className:"mx-auto max-w-full p-6"}):"audio"===n||"video"===n?"audio"===n?(0,e.jsx)("audio",{controls:!0,src:r.queryKey.file(t),className:"w-full p-6",children:(0,e.jsx)("track",{kind:"captions"})}):(0,e.jsx)("video",{controls:!0,src:r.queryKey.file(t),className:"max-w-full p-6",children:(0,e.jsx)("track",{kind:"captions"})}):o?(0,e.jsx)("p",{className:"p-5 font-mono text-xs text-destructive",children:o}):null===i?(0,e.jsxs)("div",{className:"space-y-3 p-5",children:[(0,e.jsx)(s.Skeleton,{className:"h-5 w-2/3"}),(0,e.jsx)(s.Skeleton,{className:"h-4 w-full"}),(0,e.jsx)(s.Skeleton,{className:"h-4 w-5/6"})]}):(0,e.jsx)(T,{kind:n,content:i,truncated:l})},"FileViewer",0,function({children:t}){let[r,n]=(0,a.useState)(null);return(0,e.jsxs)(C,{value:n,children:[t,(0,e.jsx)(B,{path:r,kind:r?y(r):"text",onClose:()=>n(null)})]})},"fileTarget",0,D,"useFileText",0,W,"useOpenFile",0,function(){let t=(0,a.useContext)(C);return(0,a.useCallback)(e=>{let a=D(e);if("os"===a.how)return!1;if("dialog"===a.how&&t)return t(a.path),!0;let n="tab"===a.how?a.href:r.queryKey.fileView(a.path);return null!==window.open(n,"_blank")},[t])}],621285)},245629,t=>{"use strict";var e=t.i(401851),a=t.i(677241),r=t.i(24708),n=t.i(845110),i=t.i(585890);function o(t,e,a){let[r,o]=(0,n.normalizeDates)(a?.in,t,e);return+(0,i.startOfDay)(r)==+(0,i.startOfDay)(o)}var s=t.i(281092),l=t.i(681307);let d=l.z.union([l.z.date(),l.z.iso.datetime()]),u=t=>new Date(t);t.s(["DateLikeSchema",0,d,"shortAgo",0,function(t,e=Date.now()){let a=Math.max(0,Math.round((e-u(t).getTime())/1e3));if(a<60)return"now";let r=Math.round(a/60);if(r<60)return`${r}m`;let n=Math.round(r/60);return n<24?`${n}h`:`${Math.round(n/24)}d`},"toDate",0,u,"whenOf",0,function(t){let n=u(t),i=(0,e.format)(n,"HH:mm");return o((0,a.constructFrom)(n,n),(0,r.constructNow)(n))?i:!function(t){var e,n;let i;return o((0,a.constructFrom)(t,t),(e=(0,r.constructNow)(t),n=void 0,i=(0,s.toDate)(e,n?.in),isNaN(-1)?(0,a.constructFrom)(n?.in||e,NaN):(i.setDate(i.getDate()+-1),i)))}(n)?`${(0,e.format)(n,"MMM d")} \xb7 ${i}`:`Yesterday ${i}`}],245629)},677241,234662,t=>{"use strict";let e=Symbol.for("constructDateFrom");t.s(["constructFromSymbol",0,e,"millisecondsInDay",0,864e5,"millisecondsInMinute",0,6e4,"millisecondsInWeek",0,6048e5,"minutesInDay",0,1440,"minutesInMonth",0,43200,"minutesInYear",0,525600],234662),t.s(["constructFrom",0,function(t,a){return"function"==typeof t?t(a):t&&"object"==typeof t&&e in t?t[e](a):t instanceof Date?new t.constructor(a):new Date(a)}],677241)},24708,t=>{"use strict";var e=t.i(677241);t.s(["constructNow",0,function(t){return(0,e.constructFrom)(t,Date.now())}])},401851,281092,99151,845110,585890,t=>{"use strict";var e=t.i(55545),a=t.i(455024),r=t.i(677241);function n(t,e){return(0,r.constructFrom)(e||t,t)}function i(t){let e=n(t),a=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));return a.setUTCFullYear(e.getFullYear()),t-a}function o(t,...e){let a=r.constructFrom.bind(null,t||e.find(t=>"object"==typeof t));return e.map(a)}t.s(["toDate",0,n],281092),t.s(["getTimezoneOffsetInMilliseconds",0,i],99151),t.s(["normalizeDates",0,o],845110);var s=t.i(234662);function l(t,e){let a=n(t,e?.in);return a.setHours(0,0,0,0),a}function d(t,e){let r=(0,a.getDefaultOptions)(),i=e?.weekStartsOn??e?.locale?.options?.weekStartsOn??r.weekStartsOn??r.locale?.options?.weekStartsOn??0,o=n(t,e?.in),s=o.getDay();return o.setDate(o.getDate()-(7*(s<i)+s-i)),o.setHours(0,0,0,0),o}function u(t,e){return d(t,{...e,weekStartsOn:1})}function c(t,e){let a=n(t,e?.in),i=a.getFullYear(),o=(0,r.constructFrom)(a,0);o.setFullYear(i+1,0,4),o.setHours(0,0,0,0);let s=u(o),l=(0,r.constructFrom)(a,0);l.setFullYear(i,0,4),l.setHours(0,0,0,0);let d=u(l);return a.getTime()>=s.getTime()?i+1:a.getTime()>=d.getTime()?i:i-1}function h(t,e){let i=n(t,e?.in),o=i.getFullYear(),s=(0,a.getDefaultOptions)(),l=e?.firstWeekContainsDate??e?.locale?.options?.firstWeekContainsDate??s.firstWeekContainsDate??s.locale?.options?.firstWeekContainsDate??1,u=(0,r.constructFrom)(e?.in||t,0);u.setFullYear(o+1,0,l),u.setHours(0,0,0,0);let c=d(u,e),h=(0,r.constructFrom)(e?.in||t,0);h.setFullYear(o,0,l),h.setHours(0,0,0,0);let f=d(h,e);return+i>=+c?o+1:+i>=+f?o:o-1}function f(t,e){let a=Math.abs(t).toString().padStart(e,"0");return(t<0?"-":"")+a}t.s(["startOfDay",0,l],585890);let m={y(t,e){let a=t.getFullYear(),r=a>0?a:1-a;return f("yy"===e?r%100:r,e.length)},M(t,e){let a=t.getMonth();return"M"===e?String(a+1):f(a+1,2)},d:(t,e)=>f(t.getDate(),e.length),a(t,e){let a=t.getHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return a.toUpperCase();case"aaa":return a;case"aaaaa":return a[0];default:return"am"===a?"a.m.":"p.m."}},h:(t,e)=>f(t.getHours()%12||12,e.length),H:(t,e)=>f(t.getHours(),e.length),m:(t,e)=>f(t.getMinutes(),e.length),s:(t,e)=>f(t.getSeconds(),e.length),S(t,e){let a=e.length;return f(Math.trunc(t.getMilliseconds()*Math.pow(10,a-3)),e.length)}},g={G:function(t,e,a){let r=+(t.getFullYear()>0);switch(e){case"G":case"GG":case"GGG":return a.era(r,{width:"abbreviated"});case"GGGGG":return a.era(r,{width:"narrow"});default:return a.era(r,{width:"wide"})}},y:function(t,e,a){if("yo"===e){let e=t.getFullYear();return a.ordinalNumber(e>0?e:1-e,{unit:"year"})}return m.y(t,e)},Y:function(t,e,a,r){let n=h(t,r),i=n>0?n:1-n;return"YY"===e?f(i%100,2):"Yo"===e?a.ordinalNumber(i,{unit:"year"}):f(i,e.length)},R:function(t,e){return f(c(t),e.length)},u:function(t,e){return f(t.getFullYear(),e.length)},Q:function(t,e,a){let r=Math.ceil((t.getMonth()+1)/3);switch(e){case"Q":return String(r);case"QQ":return f(r,2);case"Qo":return a.ordinalNumber(r,{unit:"quarter"});case"QQQ":return a.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return a.quarter(r,{width:"narrow",context:"formatting"});default:return a.quarter(r,{width:"wide",context:"formatting"})}},q:function(t,e,a){let r=Math.ceil((t.getMonth()+1)/3);switch(e){case"q":return String(r);case"qq":return f(r,2);case"qo":return a.ordinalNumber(r,{unit:"quarter"});case"qqq":return a.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return a.quarter(r,{width:"narrow",context:"standalone"});default:return a.quarter(r,{width:"wide",context:"standalone"})}},M:function(t,e,a){let r=t.getMonth();switch(e){case"M":case"MM":return m.M(t,e);case"Mo":return a.ordinalNumber(r+1,{unit:"month"});case"MMM":return a.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return a.month(r,{width:"narrow",context:"formatting"});default:return a.month(r,{width:"wide",context:"formatting"})}},L:function(t,e,a){let r=t.getMonth();switch(e){case"L":return String(r+1);case"LL":return f(r+1,2);case"Lo":return a.ordinalNumber(r+1,{unit:"month"});case"LLL":return a.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return a.month(r,{width:"narrow",context:"standalone"});default:return a.month(r,{width:"wide",context:"standalone"})}},w:function(t,e,i,o){let l,u,c,m,g,w=Math.round((d(l=n(t,o?.in),o)-(u=(0,a.getDefaultOptions)(),c=o?.firstWeekContainsDate??o?.locale?.options?.firstWeekContainsDate??u.firstWeekContainsDate??u.locale?.options?.firstWeekContainsDate??1,m=h(l,o),(g=(0,r.constructFrom)(o?.in||l,0)).setFullYear(m,0,c),g.setHours(0,0,0,0),d(g,o)))/s.millisecondsInWeek)+1;return"wo"===e?i.ordinalNumber(w,{unit:"week"}):f(w,e.length)},I:function(t,e,a){let i,o,l,d=Math.round((u(i=n(t,void 0))-(o=c(i,void 0),(l=(0,r.constructFrom)(i,0)).setFullYear(o,0,4),l.setHours(0,0,0,0),u(l)))/s.millisecondsInWeek)+1;return"Io"===e?a.ordinalNumber(d,{unit:"week"}):f(d,e.length)},d:function(t,e,a){return"do"===e?a.ordinalNumber(t.getDate(),{unit:"date"}):m.d(t,e)},D:function(t,e,a){let r,d,u=function(t,e){let[a,r]=o(void 0,t,e),n=l(a),d=l(r);return Math.round((n-i(n)-(d-i(d)))/s.millisecondsInDay)}(d=n(t,void 0),((r=n(d,void 0)).setFullYear(r.getFullYear(),0,1),r.setHours(0,0,0,0),r))+1;return"Do"===e?a.ordinalNumber(u,{unit:"dayOfYear"}):f(u,e.length)},E:function(t,e,a){let r=t.getDay();switch(e){case"E":case"EE":case"EEE":return a.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return a.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return a.day(r,{width:"short",context:"formatting"});default:return a.day(r,{width:"wide",context:"formatting"})}},e:function(t,e,a,r){let n=t.getDay(),i=(n-r.weekStartsOn+8)%7||7;switch(e){case"e":return String(i);case"ee":return f(i,2);case"eo":return a.ordinalNumber(i,{unit:"day"});case"eee":return a.day(n,{width:"abbreviated",context:"formatting"});case"eeeee":return a.day(n,{width:"narrow",context:"formatting"});case"eeeeee":return a.day(n,{width:"short",context:"formatting"});default:return a.day(n,{width:"wide",context:"formatting"})}},c:function(t,e,a,r){let n=t.getDay(),i=(n-r.weekStartsOn+8)%7||7;switch(e){case"c":return String(i);case"cc":return f(i,e.length);case"co":return a.ordinalNumber(i,{unit:"day"});case"ccc":return a.day(n,{width:"abbreviated",context:"standalone"});case"ccccc":return a.day(n,{width:"narrow",context:"standalone"});case"cccccc":return a.day(n,{width:"short",context:"standalone"});default:return a.day(n,{width:"wide",context:"standalone"})}},i:function(t,e,a){let r=t.getDay(),n=0===r?7:r;switch(e){case"i":return String(n);case"ii":return f(n,e.length);case"io":return a.ordinalNumber(n,{unit:"day"});case"iii":return a.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return a.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return a.day(r,{width:"short",context:"formatting"});default:return a.day(r,{width:"wide",context:"formatting"})}},a:function(t,e,a){let r=t.getHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return a.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"aaa":return a.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return a.dayPeriod(r,{width:"narrow",context:"formatting"});default:return a.dayPeriod(r,{width:"wide",context:"formatting"})}},b:function(t,e,a){let r,n=t.getHours();switch(r=12===n?"noon":0===n?"midnight":n/12>=1?"pm":"am",e){case"b":case"bb":return a.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"bbb":return a.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return a.dayPeriod(r,{width:"narrow",context:"formatting"});default:return a.dayPeriod(r,{width:"wide",context:"formatting"})}},B:function(t,e,a){let r,n=t.getHours();switch(r=n>=17?"evening":n>=12?"afternoon":n>=4?"morning":"night",e){case"B":case"BB":case"BBB":return a.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"BBBBB":return a.dayPeriod(r,{width:"narrow",context:"formatting"});default:return a.dayPeriod(r,{width:"wide",context:"formatting"})}},h:function(t,e,a){if("ho"===e){let e=t.getHours()%12;return 0===e&&(e=12),a.ordinalNumber(e,{unit:"hour"})}return m.h(t,e)},H:function(t,e,a){return"Ho"===e?a.ordinalNumber(t.getHours(),{unit:"hour"}):m.H(t,e)},K:function(t,e,a){let r=t.getHours()%12;return"Ko"===e?a.ordinalNumber(r,{unit:"hour"}):f(r,e.length)},k:function(t,e,a){let r=t.getHours();return(0===r&&(r=24),"ko"===e)?a.ordinalNumber(r,{unit:"hour"}):f(r,e.length)},m:function(t,e,a){return"mo"===e?a.ordinalNumber(t.getMinutes(),{unit:"minute"}):m.m(t,e)},s:function(t,e,a){return"so"===e?a.ordinalNumber(t.getSeconds(),{unit:"second"}):m.s(t,e)},S:function(t,e){return m.S(t,e)},X:function(t,e,a){let r=t.getTimezoneOffset();if(0===r)return"Z";switch(e){case"X":return p(r);case"XXXX":case"XX":return y(r);default:return y(r,":")}},x:function(t,e,a){let r=t.getTimezoneOffset();switch(e){case"x":return p(r);case"xxxx":case"xx":return y(r);default:return y(r,":")}},O:function(t,e,a){let r=t.getTimezoneOffset();switch(e){case"O":case"OO":case"OOO":return"GMT"+w(r,":");default:return"GMT"+y(r,":")}},z:function(t,e,a){let r=t.getTimezoneOffset();switch(e){case"z":case"zz":case"zzz":return"GMT"+w(r,":");default:return"GMT"+y(r,":")}},t:function(t,e,a){return f(Math.trunc(t/1e3),e.length)},T:function(t,e,a){return f(+t,e.length)}};function w(t,e=""){let a=t>0?"-":"+",r=Math.abs(t),n=Math.trunc(r/60),i=r%60;return 0===i?a+String(n):a+String(n)+e+f(i,2)}function p(t,e){return t%60==0?(t>0?"-":"+")+f(Math.abs(t)/60,2):y(t,e)}function y(t,e=""){let a=Math.abs(t);return(t>0?"-":"+")+f(Math.trunc(a/60),2)+e+f(a%60,2)}let b=(t,e)=>{switch(t){case"P":return e.date({width:"short"});case"PP":return e.date({width:"medium"});case"PPP":return e.date({width:"long"});default:return e.date({width:"full"})}},x=(t,e)=>{switch(t){case"p":return e.time({width:"short"});case"pp":return e.time({width:"medium"});case"ppp":return e.time({width:"long"});default:return e.time({width:"full"})}},k={p:x,P:(t,e)=>{let a,r=t.match(/(P+)(p+)?/)||[],n=r[1],i=r[2];if(!i)return b(t,e);switch(n){case"P":a=e.dateTime({width:"short"});break;case"PP":a=e.dateTime({width:"medium"});break;case"PPP":a=e.dateTime({width:"long"});break;default:a=e.dateTime({width:"full"})}return a.replace("{{date}}",b(n,e)).replace("{{time}}",x(i,e))}},v=/^D+$/,M=/^Y+$/,S=["D","DD","YY","YYYY"],N=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,j=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,D=/^'([^]*?)'?$/,C=/''/g,_=/[a-zA-Z]/;t.s(["format",0,function(t,r,i){let o=(0,a.getDefaultOptions)(),s=i?.locale??o.locale??e.defaultLocale,l=i?.firstWeekContainsDate??i?.locale?.options?.firstWeekContainsDate??o.firstWeekContainsDate??o.locale?.options?.firstWeekContainsDate??1,d=i?.weekStartsOn??i?.locale?.options?.weekStartsOn??o.weekStartsOn??o.locale?.options?.weekStartsOn??0,u=n(t,i?.in);if(!(u instanceof Date||"object"==typeof u&&"[object Date]"===Object.prototype.toString.call(u))&&"number"!=typeof u||isNaN(+n(u)))throw RangeError("Invalid time value");let c=r.match(j).map(t=>{let e=t[0];return"p"===e||"P"===e?(0,k[e])(t,s.formatLong):t}).join("").match(N).map(t=>{if("''"===t)return{isToken:!1,value:"'"};let e=t[0];if("'"===e){var a;let e;return{isToken:!1,value:(e=(a=t).match(D))?e[1].replace(C,"'"):a}}if(g[e])return{isToken:!0,value:t};if(e.match(_))throw RangeError("Format string contains an unescaped latin alphabet character `"+e+"`");return{isToken:!1,value:t}});s.localize.preprocessor&&(c=s.localize.preprocessor(u,c));let h={firstWeekContainsDate:l,weekStartsOn:d,locale:s};return c.map(e=>{if(!e.isToken)return e.value;let a=e.value;return(!i?.useAdditionalWeekYearTokens&&M.test(a)||!i?.useAdditionalDayOfYearTokens&&v.test(a))&&function(t,e,a){var r,n,i;let o,s=(r=t,n=e,i=a,o="Y"===r[0]?"years":"days of the month",`Use \`${r.toLowerCase()}\` instead of \`${r}\` (in \`${n}\`) for formatting ${o} to the input \`${i}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`);if(console.warn(s),S.includes(t))throw RangeError(s)}(a,r,String(t)),(0,g[a[0]])(u,a,s.localize,h)}).join("")}],401851)},55545,455024,t=>{"use strict";var e;let a={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}};function r(t){return (e={})=>{let a=e.width?String(e.width):t.defaultWidth;return t.formats[a]||t.formats[t.defaultWidth]}}let n={date:r({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:r({formats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},defaultWidth:"full"}),dateTime:r({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},i={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function o(t){return(e,a)=>{let r;if("formatting"===(a?.context?String(a.context):"standalone")&&t.formattingValues){let e=t.defaultFormattingWidth||t.defaultWidth,n=a?.width?String(a.width):e;r=t.formattingValues[n]||t.formattingValues[e]}else{let e=t.defaultWidth,n=a?.width?String(a.width):t.defaultWidth;r=t.values[n]||t.values[e]}return r[t.argumentCallback?t.argumentCallback(e):e]}}let s={ordinalNumber:(t,e)=>{let a=Number(t),r=a%100;if(r>20||r<10)switch(r%10){case 1:return a+"st";case 2:return a+"nd";case 3:return a+"rd"}return a+"th"},era:o({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:o({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},defaultWidth:"wide",argumentCallback:t=>t-1}),month:o({values:{narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},defaultWidth:"wide"}),day:o({values:{narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},defaultWidth:"wide"}),dayPeriod:o({values:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},defaultWidth:"wide",formattingValues:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},defaultFormattingWidth:"wide"})};function l(t){return(e,a={})=>{let r,n=a.width,i=n&&t.matchPatterns[n]||t.matchPatterns[t.defaultMatchWidth],o=e.match(i);if(!o)return null;let s=o[0],l=n&&t.parsePatterns[n]||t.parsePatterns[t.defaultParseWidth],d=Array.isArray(l)?function(t,e){for(let a=0;a<t.length;a++)if(e(t[a]))return a}(l,t=>t.test(s)):function(t,e){for(let a in t)if(Object.prototype.hasOwnProperty.call(t,a)&&e(t[a]))return a}(l,t=>t.test(s));return r=t.valueCallback?t.valueCallback(d):d,{value:r=a.valueCallback?a.valueCallback(r):r,rest:e.slice(s.length)}}}let d={ordinalNumber:(e={matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:t=>parseInt(t,10)},(t,a={})=>{let r=t.match(e.matchPattern);if(!r)return null;let n=r[0],i=t.match(e.parsePattern);if(!i)return null;let o=e.valueCallback?e.valueCallback(i[0]):i[0];return{value:o=a.valueCallback?a.valueCallback(o):o,rest:t.slice(n.length)}}),era:l({matchPatterns:{narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:"any"}),quarter:l({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:t=>t+1}),month:l({matchPatterns:{narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:"any"}),day:l({matchPatterns:{narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},defaultParseWidth:"any"}),dayPeriod:l({matchPatterns:{narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},defaultParseWidth:"any"})};t.s(["defaultLocale",0,{code:"en-US",formatDistance:(t,e,r)=>{let n,i=a[t];if(n="string"==typeof i?i:1===e?i.one:i.other.replace("{{count}}",e.toString()),r?.addSuffix)if(r.comparison&&r.comparison>0)return"in "+n;else return n+" ago";return n},formatLong:n,formatRelative:(t,e,a,r)=>i[t],localize:s,match:d,options:{weekStartsOn:0,firstWeekContainsDate:1}}],55545);let u={};t.s(["getDefaultOptions",0,function(){return u}],455024)},482022,t=>{"use strict";var e=t.i(456420);let a={name:"external-link",size:24,node:[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]]};a.node;let r=(0,e.default)(a);t.s(["ExternalLink",0,r],482022)},696017,t=>{"use strict";var e=t.i(60231),a=t.i(419524);t.i(947716);var r=t.i(723685),n=(0,a.__name)(t=>{let{securityLevel:a}=(0,e.getConfig2)(),n=(0,r.select)("body");if("sandbox"===a){let e=(0,r.select)(`#i${t}`),a=e.node()?.contentDocument??document;n=(0,r.select)(a.body)}return n.select(`#${t}`)},"selectSvgElement");t.s(["selectSvgElement",0,n])},502056,t=>{"use strict";var e=t.i(217248),a=t.i(447804),r=t.i(508324),n=t.i(419524),i=(0,n.__name)(({flowchart:t})=>{let e=t?.subGraphTitleMargin?.top??0,a=t?.subGraphTitleMargin?.bottom??0;return{subGraphTitleTopMargin:e,subGraphTitleBottomMargin:a,subGraphTitleTotalMargin:e+a}},"getSubGraphTitleMargins"),o=new Map;async function s(t,r,n){let i,s;"rect"===r.shape&&(r.rx&&r.ry?r.shape="roundedRect":r.shape="squareRect");let l=r.shape?e.shapes[r.shape]:void 0;if(!l)throw Error(`No such shape: ${r.shape}. Please check your syntax.`);if(r.link){let e;"sandbox"===n.config.securityLevel?e="_top":r.linkTarget&&(e=r.linkTarget||"_blank"),i=t.insert("svg:a").attr("xlink:href",r.link).attr("target",e??null),s=await l(i,r,n)}else i=s=await l(t,r,n);return i.attr("data-look",(0,a.handleUndefinedAttr)(r.look)),r.tooltip&&s.attr("title",r.tooltip),o.set(r.id,i),r.haveCallback&&i.attr("class",i.attr("class")+" clickable"),i}(0,n.__name)(s,"insertNode");var l=(0,n.__name)((t,e)=>{o.set(e.id,t)},"setNodeElem"),d=(0,n.__name)(()=>{o.clear()},"clear"),u=(0,n.__name)(t=>{let e=o.get(t.id);r.log.trace("Transforming node",t.diff,t,"translate("+(t.x-t.width/2-5)+", "+t.width/2+")");let a=t.diff||0;return t.clusterNode?e.attr("transform","translate("+(t.x+a-t.width/2)+", "+(t.y-t.height/2-8)+")"):e.attr("transform","translate("+t.x+", "+t.y+")"),a},"positionNode");t.s(["clear",0,d,"getSubGraphTitleMargins",0,i,"insertNode",0,s,"positionNode",0,u,"setNodeElem",0,l])},369110,t=>{"use strict";var e=t.i(502056),a=t.i(217248),r=t.i(224797),n=t.i(836333),i=t.i(60231),o=t.i(508324),s=t.i(419524);t.i(947716);var l=t.i(723685),d=t.i(883272),u=(0,s.__name)(async(t,e)=>{let s,u,c=(0,i.getConfig2)(),{themeVariables:h,handDrawnSeed:f}=c,{clusterBkg:m,clusterBorder:g}=h,{labelStyles:w,nodeStyles:p,borderStyles:y,backgroundStyles:b}=(0,r.styles2String)(e),x=t.insert("g").attr("class","cluster swimlane "+(e.cssClasses||"")).attr("id",e.id).attr("data-id",e.id).attr("data-et","cluster").attr("data-look",e.look),k=(0,i.evaluate)(c.flowchart.htmlLabels),v="LR"===e.direction,M=x.insert("g").attr("class","cluster-label swimlane-label"),S=await (0,n.createText)(M,e.label,{style:e.labelStyle,useHtmlLabels:k,isNode:!0,width:e.width}),N=S.getBBox();if(k){let t=S.children[0],e=(0,l.select)(S);N=t.getBoundingClientRect(),e.attr("width",N.width),e.attr("height",N.height)}let j=e.padding??0,D=e.width<=N.width+j?N.width+j:e.width;e.width<=N.width+j?e.diff=(D-e.width)/2-j:e.diff=-j;let C=e.height,_=e.y-C/2,T=e.y+C/2,P=e.x-D/2,O=void 0!==e.swimlaneContentTop?e.swimlaneContentTop:_+C/3,W=4*!!v,F=N.height+2*W;if(v){let t=Math.max(F,N.height+2*W),a=P+t,n=Math.max(0,D-t);if("handDrawn"===e.look){let i=d.default.svg(x),o=(0,r.userNodeOverrides)(e,{roughness:.7,fill:m,stroke:g,fillWeight:3,seed:f}),l=(0,r.userNodeOverrides)(e,{roughness:.7,fill:"none",stroke:g,seed:f}),c=i.rectangle(P,_,t,C,o);s=x.insert(()=>c,":first-child");let h=i.rectangle(a,_,n,C,l);u=x.insert(()=>h,":first-child"),s.select("path:nth-child(2)").attr("style",y.join(";")),s.select("path").attr("style",b.join(";").replace("fill","stroke"))}else s=x.insert("rect",":first-child"),u=x.insert("rect",":first-child"),s.attr("class","swimlane-title").attr("style",p).attr("x",P).attr("y",_).attr("width",t).attr("height",C).attr("fill",m).attr("stroke",g),u.attr("class","swimlane-body").attr("style",p).attr("x",a).attr("y",_).attr("width",n).attr("height",C).attr("fill","none").attr("stroke",g);let i=P+t/2,o=e.y;M.attr("transform",`translate(${i}, ${o}) rotate(-90) translate(${-N.width/2}, ${-N.height/2})`)}else{let t=Math.min(F,Math.max(0,O-_)),a=_+t,n=Math.max(0,T-a),i=e.x-D/2;if("handDrawn"===e.look){let o=d.default.svg(x),l=(0,r.userNodeOverrides)(e,{roughness:.7,fill:m,stroke:g,fillWeight:3,seed:f}),c=(0,r.userNodeOverrides)(e,{roughness:.7,fill:"none",stroke:g,seed:f}),h=o.rectangle(i,_,D,t,l);s=x.insert(()=>h,":first-child");let w=o.rectangle(i,a,D,n,c);u=x.insert(()=>w,":first-child"),s.select("path:nth-child(2)").attr("style",y.join(";")),s.select("path").attr("style",b.join(";").replace("fill","stroke"))}else s=x.insert("rect",":first-child"),u=x.insert("rect",":first-child"),s.attr("class","swimlane-title").attr("style",p).attr("x",i).attr("y",_).attr("width",D).attr("height",t).attr("fill",m).attr("stroke",g),u.attr("class","swimlane-body").attr("style",p).attr("x",i).attr("y",a).attr("width",D).attr("height",n).attr("fill","none").attr("stroke",g);let o=e.x-N.width/2,l=_+(t-N.height)/2;M.attr("transform",`translate(${o}, ${l})`)}if(o.log.trace("Swimlane data ",e,JSON.stringify(e)),w){let t=M.select("span");t&&t.attr("style",w)}return e.offsetX=0,e.width=D,e.height=C,e.offsetY=N.height-j/2,e.intersect=function(t){return(0,a.intersect_rect_default)(e,t)},{cluster:x,labelBBox:N}},"swimlane"),c=(0,s.__name)(async(t,s)=>{let u,c;o.log.info("Creating subgraph rect for ",s.id,s);let h=(0,i.getConfig2)(),{themeVariables:f,handDrawnSeed:m}=h,{clusterBkg:g,clusterBorder:w}=f,{labelStyles:p,nodeStyles:y,borderStyles:b,backgroundStyles:x}=(0,r.styles2String)(s),k=t.insert("g").attr("class","cluster "+s.cssClasses).attr("id",s.domId).attr("data-look",s.look),v=(0,i.getEffectiveHtmlLabels)(h),M=k.insert("g").attr("class","cluster-label "),S=(u="markdown"===s.labelType?await (0,n.createText)(M,s.label,{style:s.labelStyle,useHtmlLabels:v,isNode:!0,width:s.width}):await (0,a.createLabel_default)(M,s.label,s.labelStyle||"",!1,!0)).getBBox();if((0,i.getEffectiveHtmlLabels)(h)){let t=u.children[0],e=(0,l.select)(u);S=t.getBoundingClientRect(),e.attr("width",S.width),e.attr("height",S.height)}let N=s.width<=S.width+s.padding?S.width+s.padding:s.width;s.width<=S.width+s.padding?s.diff=(N-s.width)/2-s.padding:s.diff=-s.padding;let j=s.height,D=s.x-N/2,C=s.y-j/2;if(o.log.trace("Data ",s,JSON.stringify(s)),"handDrawn"===s.look){let t=d.default.svg(k),e=(0,r.userNodeOverrides)(s,{roughness:.7,fill:g,stroke:w,fillWeight:3,seed:m}),n=t.path((0,a.createRoundedRectPathD)(D,C,N,j,0),e);(c=k.insert(()=>(o.log.debug("Rough node insert CXC",n),n),":first-child")).select("path:nth-child(2)").attr("style",b.join(";")),c.select("path").attr("style",x.join(";").replace("fill","stroke"))}else(c=k.insert("rect",":first-child")).attr("style",y).attr("rx",s.rx).attr("ry",s.ry).attr("x",D).attr("y",C).attr("width",N).attr("height",j);let{subGraphTitleTopMargin:_}=(0,e.getSubGraphTitleMargins)(h);if(M.attr("transform",`translate(${s.x-S.width/2}, ${s.y-s.height/2+_})`),p){let t=M.select("span");t&&t.attr("style",p)}let T=c.node().getBBox();return s.offsetX=0,s.width=T.width,s.height=T.height,s.offsetY=S.height-s.padding/2,s.intersect=function(t){return(0,a.intersect_rect_default)(s,t)},{cluster:k,labelBBox:S}},"rect"),h=(0,s.__name)((t,e)=>{let r=t.insert("g").attr("class","note-cluster").attr("id",e.domId),n=r.insert("rect",":first-child"),i=0*e.padding,o=i/2;n.attr("rx",e.rx).attr("ry",e.ry).attr("x",e.x-e.width/2-o).attr("y",e.y-e.height/2-o).attr("width",e.width+i).attr("height",e.height+i).attr("fill","none");let s=n.node().getBBox();return e.width=s.width,e.height=s.height,e.intersect=function(t){return(0,a.intersect_rect_default)(e,t)},{cluster:r,labelBBox:{width:0,height:0}}},"noteGroup"),f=(0,s.__name)(async(t,e)=>{let r,n=(0,i.getConfig2)(),{themeVariables:o,handDrawnSeed:s}=n,{altBackground:u,compositeBackground:c,compositeTitleBackground:h,nodeBorder:f}=o,m=t.insert("g").attr("class",e.cssClasses).attr("id",e.domId).attr("data-id",e.id).attr("data-look",e.look),g=m.insert("g",":first-child"),w=m.insert("g").attr("class","cluster-label"),p=m.append("rect"),y=await (0,a.createLabel_default)(w,e.label,e.labelStyle,void 0,!0),b=y.getBBox();if((0,i.getEffectiveHtmlLabels)(n)){let t=y.children[0],e=(0,l.select)(y);b=t.getBoundingClientRect(),e.attr("width",b.width),e.attr("height",b.height)}let x=0*e.padding,k=(e.width<=b.width+e.padding?b.width+e.padding:e.width)+x;e.width<=b.width+e.padding?e.diff=(k-e.width)/2-e.padding:e.diff=-e.padding;let v=e.height+x,M=e.height+x-b.height-6,S=e.x-k/2,N=e.y-v/2;e.width=k;let j=e.y-e.height/2-x/2+b.height+2;if("handDrawn"===e.look){let t=e.cssClasses.includes("statediagram-cluster-alt"),n=d.default.svg(m),i=e.rx||e.ry?n.path((0,a.createRoundedRectPathD)(S,N,k,v,10),{roughness:.7,fill:h,fillStyle:"solid",stroke:f,seed:s}):n.rectangle(S,N,k,v,{seed:s});r=m.insert(()=>i,":first-child");let o=n.rectangle(S,j,k,M,{fill:t?u:c,fillStyle:t?"hachure":"solid",stroke:f,seed:s});r=m.insert(()=>i,":first-child"),p=m.insert(()=>o)}else(r=g.insert("rect",":first-child")).attr("class","outer").attr("x",S).attr("y",N).attr("width",k).attr("height",v).attr("data-look",e.look),p.attr("class","inner").attr("x",S).attr("y",j).attr("width",k).attr("height",M);return w.attr("transform",`translate(${e.x-b.width/2}, ${N+1-3*!(0,i.getEffectiveHtmlLabels)(n)})`),e.height=r.node().getBBox().height,e.offsetX=0,e.offsetY=b.height-e.padding/2,e.labelBBox=b,e.intersect=function(t){return(0,a.intersect_rect_default)(e,t)},{cluster:m,labelBBox:b}},"roundedWithTitle"),m=(0,s.__name)(async(t,s)=>{let u;o.log.info("Creating subgraph rect for ",s.id,s);let c=(0,i.getConfig2)(),{themeVariables:h,handDrawnSeed:f}=c,{clusterBkg:m,clusterBorder:g}=h,{labelStyles:w,nodeStyles:p,borderStyles:y,backgroundStyles:b}=(0,r.styles2String)(s),x=t.insert("g").attr("class","cluster "+s.cssClasses).attr("id",s.domId).attr("data-look",s.look),k=(0,i.getEffectiveHtmlLabels)(c),v=x.insert("g").attr("class","cluster-label "),M=await (0,n.createText)(v,s.label,{style:s.labelStyle,useHtmlLabels:k,isNode:!0,width:s.width}),S=M.getBBox();if((0,i.getEffectiveHtmlLabels)(c)){let t=M.children[0],e=(0,l.select)(M);S=t.getBoundingClientRect(),e.attr("width",S.width),e.attr("height",S.height)}let N=s.width<=S.width+s.padding?S.width+s.padding:s.width;s.width<=S.width+s.padding?s.diff=(N-s.width)/2-s.padding:s.diff=-s.padding;let j=s.height,D=s.x-N/2,C=s.y-j/2;if(o.log.trace("Data ",s,JSON.stringify(s)),"handDrawn"===s.look){let t=d.default.svg(x),e=(0,r.userNodeOverrides)(s,{roughness:.7,fill:m,stroke:g,fillWeight:4,seed:f}),n=t.path((0,a.createRoundedRectPathD)(D,C,N,j,s.rx),e);(u=x.insert(()=>(o.log.debug("Rough node insert CXC",n),n),":first-child")).select("path:nth-child(2)").attr("style",y.join(";")),u.select("path").attr("style",b.join(";").replace("fill","stroke"))}else(u=x.insert("rect",":first-child")).attr("style",p).attr("rx",s.rx).attr("ry",s.ry).attr("x",D).attr("y",C).attr("width",N).attr("height",j);let{subGraphTitleTopMargin:_}=(0,e.getSubGraphTitleMargins)(c);if(v.attr("transform",`translate(${s.x-S.width/2}, ${s.y-s.height/2+_})`),w){let t=v.select("span");t&&t.attr("style",w)}let T=u.node().getBBox();return s.offsetX=0,s.width=T.width,s.height=T.height,s.offsetY=S.height-s.padding/2,s.intersect=function(t){return(0,a.intersect_rect_default)(s,t)},{cluster:x,labelBBox:S}},"kanbanSection"),g={rect:c,squareRect:c,roundedWithTitle:f,noteGroup:h,divider:(0,s.__name)((t,e)=>{let r,{themeVariables:n,handDrawnSeed:o}=(0,i.getConfig2)(),{nodeBorder:s}=n,l=t.insert("g").attr("class",e.cssClasses).attr("id",e.domId).attr("data-look",e.look),u=l.insert("g",":first-child"),c=0*e.padding,h=e.width+c;e.diff=-e.padding;let f=e.height+c,m=e.x-h/2,g=e.y-f/2;if(e.width=h,"handDrawn"===e.look){let t=d.default.svg(l).rectangle(m,g,h,f,{fill:"lightgrey",roughness:.5,strokeLineDash:[5],stroke:s,seed:o});r=l.insert(()=>t,":first-child")}else{r=u.insert("rect",":first-child");let t="outer";e.look,t="divider",r.attr("class",t).attr("x",m).attr("y",g).attr("width",h).attr("height",f).attr("data-look",e.look)}return e.height=r.node().getBBox().height,e.offsetX=0,e.offsetY=0,e.intersect=function(t){return(0,a.intersect_rect_default)(e,t)},{cluster:l,labelBBox:{}}},"divider"),kanbanSection:m,swimlane:u},w=new Map,p=(0,s.__name)(async(t,e)=>{let a=e.shape||"rect",r=await g[a](t,e);return w.set(e.id,r),r},"insertCluster"),y=(0,s.__name)(()=>{w=new Map},"clear");t.s(["clear",0,y,"insertCluster",0,p])},121292,t=>{"use strict";var e=t.i(369110),a=t.i(382793),r=t.i(502056),n=t.i(217248),i=t.i(447804),o=t.i(60231),s=t.i(508324),l=t.i(419524),d={common:o.common_default,getConfig:o.getConfig,insertCluster:e.insertCluster,insertEdge:a.insertEdge,insertEdgeLabel:a.insertEdgeLabel,insertMarkers:a.markers_default,insertNode:r.insertNode,interpolateToCurve:i.interpolateToCurve,labelHelper:n.labelHelper,log:s.log,positionEdgeLabel:a.positionEdgeLabel},u={},c=(0,l.__name)(t=>{for(let e of t)u[e.name]=e},"registerLayoutLoaders");(0,l.__name)(()=>{c([{name:"dagre",loader:(0,l.__name)(async()=>await t.A(555153),"loader")},{name:"swimlane",loader:(0,l.__name)(async()=>await t.A(12782),"loader")},{name:"cose-bilkent",loader:(0,l.__name)(async()=>await t.A(208503),"loader")}])},"registerDefaultLayoutLoaders")();var h=(0,l.__name)(async(t,e)=>{if(!(t.layoutAlgorithm in u))throw Error(`Unknown layout algorithm: ${t.layoutAlgorithm}`);if(t.diagramId)for(let e of t.nodes){let a=e.domId||e.id;e.domId=`${t.diagramId}-${a}`}let a=u[t.layoutAlgorithm],r=await a.loader(),{theme:n,themeVariables:i}=t.config,{useGradient:o,gradientStart:s,gradientStop:l}=i,c=e.attr("id");if(e.append("defs").append("filter").attr("id",`${c}-drop-shadow`).attr("height","130%").attr("width","130%").append("feDropShadow").attr("dx","4").attr("dy","4").attr("stdDeviation",0).attr("flood-opacity","0.06").attr("flood-color",`${n?.includes("dark")?"#FFFFFF":"#000000"}`),e.append("defs").append("filter").attr("id",`${c}-drop-shadow-small`).attr("height","150%").attr("width","150%").append("feDropShadow").attr("dx","2").attr("dy","2").attr("stdDeviation",0).attr("flood-opacity","0.06").attr("flood-color",`${n?.includes("dark")?"#FFFFFF":"#000000"}`),o){let t=e.append("linearGradient").attr("id",e.attr("id")+"-gradient").attr("gradientUnits","objectBoundingBox").attr("x1","0%").attr("y1","0%").attr("x2","100%").attr("y2","0%");t.append("svg:stop").attr("offset","0%").attr("stop-color",s).attr("stop-opacity",1),t.append("svg:stop").attr("offset","100%").attr("stop-color",l).attr("stop-opacity",1)}return r.render(t,e,d,{algorithm:a.algorithm})},"render"),f=(0,l.__name)((t="",{fallback:e="dagre"}={})=>{if(t in u)return t;if(e in u)return s.log.warn(`Layout algorithm ${t} is not registered. Using ${e} as fallback.`),e;throw Error(`Both layout algorithms ${t} and ${e} are not registered.`)},"getRegisteredLayoutAlgorithm");t.s(["getRegisteredLayoutAlgorithm",0,f,"registerLayoutLoaders",0,c,"render",0,h])}]);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,787800,e=>{"use strict";var t=e.i(843476),n=e.i(689664),s=e.i(716327),r=e.i(867927),o=e.i(456420);let a={name:"play",size:24,node:[["path",{d:"M5 5a2 2 0 0 1 3.008-1.728l11.997 6.998a2 2 0 0 1 .003 3.458l-12 7A2 2 0 0 1 5 19z",key:"10ikf1"}]]};a.node;let i=(0,o.default)(a);var c=e.i(77071);let l={name:"refresh-cw",size:24,node:[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]};l.node;let d=(0,o.default)(l),m={name:"server",size:24,node:[["rect",{width:"20",height:"8",x:"2",y:"2",rx:"2",ry:"2",key:"ngkwjq"}],["rect",{width:"20",height:"8",x:"2",y:"14",rx:"2",ry:"2",key:"iecqi9"}],["line",{x1:"6",x2:"6.01",y1:"6",y2:"6",key:"16zg32"}],["line",{x1:"6",x2:"6.01",y1:"18",y2:"18",key:"nzw8ys"}]]};m.node;let p=(0,o.default)(m);var u=e.i(759659),h=e.i(263676),g=e.i(271645),f=e.i(798120),x=e.i(167881),v=e.i(986530),j=e.i(23750),y=e.i(647163);let b=(0,g.memo)(({data:e,name:n,initialExpandDepth:s=2})=>{let r=(0,g.useMemo)(()=>"string"==typeof e?function(e){let t=e.trim();if(!(t.startsWith("{")&&t.endsWith("}"))&&!(t.startsWith("[")&&t.endsWith("]")))return{success:!1,data:e};try{return{success:!0,data:JSON.parse(e)}}catch{return{success:!1,data:e}}}(e).data:e,[e]);return(0,t.jsx)("div",{className:" text-sm transition-all duration-300",children:(0,t.jsx)(N,{data:r,name:n,depth:0,initialExpandDepth:s})})});b.displayName="JsonView";let N=(0,g.memo)(({data:e,name:n,depth:s=0,initialExpandDepth:r})=>{var o;let a=void 0===e?"undefined":Array.isArray(e)?"array":null===e?"null":typeof e,[i,c]=(0,g.useState)("string"!==a&&s<r),l={number:"text-blue-500",boolean:"text-amber-500",null:"text-purple-500",undefined:"text-gray-500",string:"text-foreground break-all whitespace-pre-wrap",default:"text-muted-foreground"};switch(a){case"object":case"array":let d,m,p;return m=(d=(o="array"===a)?e:Object.entries(e)).length,p={open:o?"[":"{",close:o?"]":"}",collapsed:o?"[ ... ]":"{ ... }",empty:o?"[]":"{}"},0===m?(0,t.jsxs)("div",{className:"flex items-center",children:[n&&(0,t.jsxs)("span",{className:"mr-1 text-muted-foreground",children:[n,":"]}),(0,t.jsx)("span",{className:"text-muted-foreground",children:p.empty})]}):(0,t.jsxs)("div",{className:"flex flex-col",children:[(0,t.jsxs)("div",{className:"flex items-center mr-1 rounded cursor-pointer group hover:bg-input/30",onClick:()=>c(!i),children:[n&&(0,t.jsxs)("span",{className:"mr-1 text-muted-foreground hover:text-foreground",children:[n,":"]}),i?(0,t.jsx)("span",{className:"text-muted-foreground group-hover:text-foreground",children:p.open}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("span",{className:"text-muted-foreground group-hover:text-foreground",children:p.collapsed}),(0,t.jsxs)("span",{className:"ml-1 text-muted-foreground group-hover:text-foreground",children:[m," ",1===m?"item":"items"]})]})]}),i&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("div",{className:"pl-2 ml-4 border-l border-border",children:o?d.map((e,n)=>(0,t.jsx)("div",{className:"my-1",children:(0,t.jsx)(N,{data:e,name:`${n}`,depth:s+1,initialExpandDepth:r})},n)):d.map(([e,n])=>(0,t.jsx)("div",{className:"my-1",children:(0,t.jsx)(N,{data:n,name:e,depth:s+1,initialExpandDepth:r})},e))}),(0,t.jsx)("div",{className:"text-muted-foreground",children:p.close})]})]});case"string":return e.length>100?(0,t.jsxs)("div",{className:"flex mr-1 rounded group hover:bg-input/30",children:[n&&(0,t.jsxs)("span",{className:"mr-1 text-muted-foreground hover:text-foreground",children:[n,":"]}),(0,t.jsx)("pre",{className:(0,y.cn)(l.string,"cursor-pointer group-hover:text-foreground"),onClick:()=>c(!i),title:i?"Click to collapse":"Click to expand",children:i?`"${e}"`:`"${e.slice(0,100)}..."`})]}):(0,t.jsxs)("div",{className:"flex mr-1 rounded hover:bg-input/30",children:[n&&(0,t.jsxs)("span",{className:"mr-1 text-muted-foreground",children:[n,":"]}),(0,t.jsxs)("pre",{className:l.string,children:['"',e,'"']})]});case"undefined":return(0,t.jsxs)("div",{className:"flex items-center mr-1 rounded hover:bg-input/30",children:[n&&(0,t.jsxs)("span",{className:"mr-1 text-muted-foreground",children:[n,":"]}),(0,t.jsx)("span",{className:l.undefined,children:"undefined"})]});default:return(0,t.jsxs)("div",{className:"flex items-center mr-1 rounded hover:bg-input/30",children:[n&&(0,t.jsxs)("span",{className:"mr-1 text-muted-foreground",children:[n,":"]}),(0,t.jsx)("span",{className:l[a]||l.default,children:null===e?"null":String(e)})]})}});N.displayName="JsonNode";var k=e.i(917162),S=e.i(319036),C=e.i(127341),w=e.i(184762),z=e.i(6799),O=e.i(95187);let T=(0,O.createServerReference)("7f5a192ef8096b2b075df879d5ab6cbfd5be7f912c",O.callServer,void 0,O.findSourceMapURL,"callToolAction"),A=(0,O.createServerReference)("7fceb171d46c81de338e79d8c2d4aae8463fc77546",O.callServer,void 0,O.findSourceMapURL,"deleteServerAction"),I=(0,O.createServerReference)("7f3fc1217df939064475e09d962acf376dc47d28f7",O.callServer,void 0,O.findSourceMapURL,"refreshServerAction"),P=(0,O.createServerReference)("7f95e939ee78e6c29abae2f989202989a3645c590d",O.callServer,void 0,O.findSourceMapURL,"registerServerAction");var F=e.i(681307),$=e.i(245629);let M=F.z.object({url:F.z.url(),headers:F.z.record(F.z.string(),F.z.string()).optional(),oauthClient:F.z.object({clientId:F.z.string().min(1),clientSecret:F.z.string().optional()}).optional()}),R=F.z.object({command:F.z.string().min(1),args:F.z.array(F.z.string()).optional(),env:F.z.record(F.z.string(),F.z.string()).optional()}),D=F.z.union([M,R]),E=F.z.object({name:F.z.string(),description:F.z.string().optional(),inputSchema:F.z.looseObject({}).optional(),outputSchema:F.z.looseObject({}).optional()});function L(e){return"url"in e}F.z.object({clientInformation:F.z.looseObject({}).optional(),tokens:F.z.looseObject({}).optional(),authorizationServer:F.z.looseObject({}).optional(),codeVerifier:F.z.string().optional(),state:F.z.string().optional()});let q=F.z.object({name:F.z.string().min(1).max(40),config:D,toolCount:F.z.number().int(),lastError:F.z.string().nullish()}),B=E.extend({id:F.z.number().int(),description:F.z.string().nullish()});q.omit({toolCount:!0}).extend({tools:B.array().default([]),toolsSyncedAt:$.DateLikeSchema});let J=F.z.object({name:F.z.string().min(1,"Name is required").max(40).regex(/^[a-zA-Z0-9_-]+$/,"Only letters, numbers, - and _ are allowed"),config:D}),U=F.z.union([F.z.object({mcpServers:F.z.record(F.z.string(),D)}),F.z.record(F.z.string(),D)]),K=[{name:"notion",icon:"notion.so",description:"Pages, databases, and search",config:{url:"https://mcp.notion.com/mcp"}},{name:"github",icon:"github.com",description:"Repos, issues, PRs — paste a personal access token",config:{url:"https://api.githubcopilot.com/mcp/",headers:{Authorization:"Bearer <your-github-pat>"}}},{name:"linear",icon:"linear.app",description:"Issues, projects, and cycles",config:{url:"https://mcp.linear.app/mcp"}},{name:"slack",icon:"slack.com",description:"Channels, messages, and search",config:{url:"https://mcp.slack.com/mcp"}},{name:"atlassian",icon:"atlassian.com",description:"Jira and Confluence",config:{url:"https://mcp.atlassian.com/v1/mcp"}},{name:"asana",icon:"asana.com",description:"Tasks, projects, and portfolios",config:{url:"https://mcp.asana.com/mcp"}},{name:"monday",icon:"monday.com",description:"Boards, items, and updates",config:{url:"https://mcp.monday.com/mcp"}},{name:"clickup",icon:"clickup.com",description:"Tasks, docs, and spaces",config:{url:"https://mcp.clickup.com/mcp"}},{name:"airtable",icon:"airtable.com",description:"Bases, tables, and records",config:{url:"https://mcp.airtable.com/mcp"}},{name:"box",icon:"box.com",description:"Files, folders, and content search",config:{url:"https://mcp.box.com/mcp"}},{name:"figma",icon:"figma.com",description:"Design files and components",config:{url:"https://mcp.figma.com/mcp"}},{name:"canva",icon:"canva.com",description:"Create and manage designs",config:{url:"https://mcp.canva.com/mcp"}},{name:"sanity",icon:"sanity.io",description:"Structured content and datasets",config:{url:"https://mcp.sanity.io/mcp"}},{name:"webflow",icon:"webflow.com",description:"Sites, pages, and CMS collections",config:{url:"https://mcp.webflow.com/mcp"}},{name:"wix",icon:"wix.com",description:"Sites, stores, and bookings",config:{url:"https://mcp.wix.com/mcp"}},{name:"hubspot",icon:"hubspot.com",description:"Contacts, deals, and companies",config:{url:"https://app.hubspot.com/mcp/v1/http"}},{name:"attio",icon:"attio.com",description:"CRM records and lists",config:{url:"https://mcp.attio.com/mcp"}},{name:"intercom",icon:"intercom.com",description:"Conversations and support tickets",config:{url:"https://mcp.intercom.com/mcp"}},{name:"fireflies",icon:"fireflies.ai",description:"Meeting transcripts and summaries",config:{url:"https://mcp.fireflies.ai/mcp"}},{name:"stripe",icon:"stripe.com",description:"Payments, invoices, and customers",config:{url:"https://mcp.stripe.com"}},{name:"paypal",icon:"paypal.com",description:"Payments and orders",config:{url:"https://mcp.paypal.com/mcp"}},{name:"square",icon:"squareup.com",description:"Payments, catalog, and orders",config:{url:"https://mcp.squareup.com/mcp"}},{name:"ramp",icon:"ramp.com",description:"Spend, cards, and transactions",config:{url:"https://mcp.ramp.com/mcp"}},{name:"vercel",icon:"vercel.com",description:"Deployments and projects",config:{url:"https://mcp.vercel.com"}},{name:"netlify",icon:"netlify.com",description:"Sites, builds, and deploys",config:{url:"https://mcp.netlify.com/mcp"}},{name:"cloudflare",icon:"cloudflare.com",description:"Workers bindings — D1, R2, KV",config:{url:"https://bindings.mcp.cloudflare.com/mcp"}},{name:"supabase",icon:"supabase.com",description:"Projects, tables, and SQL",config:{url:"https://mcp.supabase.com/mcp"}},{name:"neon",icon:"neon.tech",description:"Postgres branches and queries",config:{url:"https://mcp.neon.tech/mcp"}},{name:"prisma",icon:"prisma.io",description:"Postgres databases and schema",config:{url:"https://mcp.prisma.io/mcp"}},{name:"sentry",icon:"sentry.io",description:"Errors and performance issues",config:{url:"https://mcp.sentry.dev/mcp"}},{name:"grafana",icon:"grafana.com",description:"Dashboards, metrics, and alerts",config:{url:"https://mcp.grafana.com/mcp"}},{name:"semgrep",icon:"semgrep.dev",description:"Scan code for security findings",config:{url:"https://mcp.semgrep.ai/mcp"}},{name:"postman",icon:"postman.com",description:"Collections, environments, and requests",config:{url:"https://mcp.postman.com/mcp"}},{name:"resend",icon:"resend.com",description:"Send email and manage audiences",config:{url:"https://mcp.resend.com/mcp"}},{name:"hugging-face",icon:"huggingface.co",description:"Models, datasets, and Spaces",config:{url:"https://huggingface.co/mcp"}},{name:"apify",icon:"apify.com",description:"Run scrapers and automation actors",config:{url:"https://mcp.apify.com"}},{name:"exa",icon:"exa.ai",description:"Web search for agents",config:{url:"https://mcp.exa.ai/mcp"}},{name:"kagi",icon:"kagi.com",description:"Search, summarize, and answer",config:{url:"https://mcp.kagi.com/mcp"}},{name:"context7",icon:"context7.com",description:"Up-to-date library docs",config:{url:"https://mcp.context7.com/mcp"}},{name:"deepwiki",icon:"deepwiki.com",description:"Ask questions about any GitHub repo",config:{url:"https://mcp.deepwiki.com/mcp"}},{name:"microsoft-learn",icon:"learn.microsoft.com",description:"Microsoft and Azure docs — no account",config:{url:"https://learn.microsoft.com/api/mcp"}},{name:"aws-knowledge",icon:"aws.amazon.com",description:"AWS docs and API references — no account",config:{url:"https://knowledge-mcp.global.api.aws"}},{name:"cloudflare-docs",icon:"developers.cloudflare.com",description:"Cloudflare docs — no account",config:{url:"https://docs.mcp.cloudflare.com/mcp"}},{name:"stack-overflow",icon:"stackoverflow.com",description:"Questions, answers, and teams",config:{url:"https://mcp.stackoverflow.com"}},{name:"playwright",icon:"playwright.dev",description:"Drive a real browser",config:{command:"npx",args:["@playwright/mcp@latest"]}},{name:"chrome-devtools",icon:"developer.chrome.com",description:"Inspect and debug Chrome",config:{command:"npx",args:["chrome-devtools-mcp@latest"]}}];var _=e.i(895836),H=e.i(333999),W=e.i(609856),V=e.i(283653);function G({name:e,onDone:n}){let{data:s,isLoading:r}=(0,V.useServerRoute)(f.queryKey.mcpServer(e)),[o,a]=(0,W.useServerAction)(I,{...ec,onOk:t=>{ec.onOk(t),(0,V.revalidate)(f.queryKey.mcpServer(e))}}),[i,c]=(0,W.useServerAction)(A,{okMessage:"Server deleted",onOk:()=>{n(),(0,V.revalidate)(f.queryKey.mcp)}}),l=async()=>{await k.notify.confirm({title:`Delete ${e}?`,description:"Its connection and saved authorization go with it.",okText:"Delete",destructive:!0})&&i(e)};if(r)return(0,t.jsx)(_.SettingSkeleton,{rows:4});if(!s)return null;let m=s.tools.length,p=L(s.config)?"HTTP":"STDIO";return(0,t.jsxs)(_.SettingDialogContent,{title:s.name,description:(0,t.jsxs)("span",{className:"flex min-w-0 items-center gap-1.5",children:[(0,t.jsx)("span",{className:"shrink-0 rounded-sm bg-muted px-1.5 py-0.5 font-mono text-[10px]",children:p}),(0,t.jsx)("span",{className:"truncate font-mono",children:ed(s.config)})]}),footer:(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(x.Button,{variant:"ghost",loading:c,onClick:l,children:[(0,t.jsx)(u.Trash2,{}),"Delete"]}),(0,t.jsxs)(x.Button,{variant:"outline",loading:a,onClick:()=>o(s.name),children:[(0,t.jsx)(d,{}),"Reconnect"]})]}),children:[s.lastError&&(0,t.jsx)("p",{className:"rounded-lg bg-destructive/10 px-3 py-2 font-mono text-xs text-destructive",children:s.lastError}),(0,t.jsxs)("p",{className:"text-right font-mono text-xs text-muted-foreground",children:[m," ",1===m?"tool":"tools"]}),s.tools.map(e=>(0,t.jsx)(Y,{tool:e,serverName:s.name},e.name))]})}function Q({server:e}){let s=e.toolCount,o=e.lastError?"error":s>0?"connected":"idle";return(0,t.jsxs)("button",{type:"button",onClick:()=>{k.notify.component({className:"sm:max-w-3xl",renderer:({close:n})=>(0,t.jsx)(G,{name:e.name,onDone:n})})},className:"group flex w-full items-center gap-3 p-4 text-left outline-none transition-colors hover:bg-muted/50 focus-visible:ring-3 focus-visible:ring-ring/50 focus-visible:ring-inset",children:[(0,t.jsx)("span",{className:"grid size-10 shrink-0 place-items-center rounded-lg bg-muted text-muted-foreground",children:(0,t.jsx)(X,{server:e})}),(0,t.jsxs)("span",{className:"min-w-0 flex-1 space-y-0.5",children:[(0,t.jsxs)("span",{className:"flex min-w-0 items-center gap-1.5",children:[(0,t.jsx)("span",{className:"truncate text-sm font-medium",children:e.name}),"connected"===o&&(0,t.jsx)(n.Check,{className:"size-3 shrink-0 text-muted-foreground"})]}),(0,t.jsx)("span",{className:"block truncate text-xs text-muted-foreground",children:"error"===o?(0,t.jsx)("span",{className:"text-destructive",children:e.lastError}):(0,t.jsxs)(t.Fragment,{children:[s>0?`${s} ${1===s?"tool":"tools"}`:"No tools yet",(0,t.jsxs)("span",{className:"font-mono text-[11px] text-muted-foreground/70",children:[" · ",ed(e.config)]})]})})]}),(0,t.jsx)(r.ChevronRight,{className:"size-4 shrink-0 text-muted-foreground/60 transition-colors group-hover:text-foreground"})]})}function X({server:e}){let n,s=(n=K.find(t=>L(t.config)?L(e.config)&&t.config.url.replace(/\/+$/,"")===e.config.url.replace(/\/+$/,""):!L(e.config)&&t.config.command===e.config.command&&(t.config.args??[]).join(" ")===(e.config.args??[]).join(" "))??K.find(t=>t.name===e.name),n?.icon);return s?(0,t.jsx)("img",{src:(0,y.faviconUrl)(s),alt:"",className:"size-5"}):(0,t.jsx)(p,{className:"size-4"})}function Y({tool:e,serverName:n}){let[o,a]=(0,g.useState)(!1),[i,c]=(0,g.useState)(!1),[l,d]=(0,g.useState)(!1),m=[["inputSchema",e.inputSchema],["outputSchema",e.outputSchema]].filter(([,e])=>e);return(0,t.jsxs)("div",{className:"rounded-xl border border-border/60 bg-background p-4",children:[(0,t.jsxs)("div",{className:"min-w-0 space-y-1",children:[(0,t.jsx)("span",{className:"block truncate font-mono text-sm",children:e.name}),e.description?(0,t.jsx)("p",{className:(0,y.cn)("text-xs text-muted-foreground",!l&&"line-clamp-2",e.description.length>140&&"cursor-pointer"),onClick:()=>d(!l),children:e.description}):null]}),(0,t.jsxs)("div",{className:"mt-2 flex justify-end gap-1",children:[m.length>0&&(0,t.jsxs)(x.Button,{size:"xs",variant:"ghost",className:"font-mono",onClick:()=>a(!o),children:[o?(0,t.jsx)(s.ChevronDown,{}):(0,t.jsx)(r.ChevronRight,{}),"Schema"]}),(0,t.jsxs)(x.Button,{size:"xs",variant:"ghost",className:"font-mono",onClick:()=>c(!i),children:[i?(0,t.jsx)(s.ChevronDown,{}):(0,t.jsx)(r.ChevronRight,{}),"Test"]})]}),o?(0,t.jsx)("div",{className:"mt-2 space-y-3 overflow-x-auto rounded-lg border border-input p-3",children:m.map(([e,n])=>(0,t.jsxs)("div",{className:"space-y-1",children:[(0,t.jsx)("span",{className:"block font-mono text-xs text-muted-foreground",children:"inputSchema"===e?"in":"out"}),(0,t.jsx)("pre",{className:"font-mono text-xs leading-relaxed whitespace-pre",children:function e(t,n=0){if(!t||"object"!=typeof t)return"unknown";let s=" ".repeat(n+1),r=" ".repeat(n);if(Array.isArray(t.enum))return t.enum.map(e=>JSON.stringify(e)).join(" | ");let o=t.anyOf??t.oneOf;if(Array.isArray(o))return o.map(t=>e(t,n)).join(" | ");if("array"===t.type){let s=e(t.items,n);return/[|{]/.test(s)?`(${s})[]`:`${s}[]`}if("object"===t.type||t.properties){let o=t.properties;if(!o||0===Object.keys(o).length)return"{}";let a=t.required??[],i=Object.entries(o).map(([t,r])=>{let o=a.includes(t)?"":"?",i=r?.description,c="string"==typeof i&&i.length<=60?` // ${i}`:"";return`${s}${t}${o}: ${e(r,n+1)}${c}`});return`{
|
|
1
|
+
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,787800,e=>{"use strict";var t=e.i(843476),n=e.i(689664),s=e.i(716327),r=e.i(867927),o=e.i(456420);let a={name:"play",size:24,node:[["path",{d:"M5 5a2 2 0 0 1 3.008-1.728l11.997 6.998a2 2 0 0 1 .003 3.458l-12 7A2 2 0 0 1 5 19z",key:"10ikf1"}]]};a.node;let i=(0,o.default)(a);var c=e.i(77071);let l={name:"refresh-cw",size:24,node:[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]};l.node;let d=(0,o.default)(l),m={name:"server",size:24,node:[["rect",{width:"20",height:"8",x:"2",y:"2",rx:"2",ry:"2",key:"ngkwjq"}],["rect",{width:"20",height:"8",x:"2",y:"14",rx:"2",ry:"2",key:"iecqi9"}],["line",{x1:"6",x2:"6.01",y1:"6",y2:"6",key:"16zg32"}],["line",{x1:"6",x2:"6.01",y1:"18",y2:"18",key:"nzw8ys"}]]};m.node;let p=(0,o.default)(m);var u=e.i(759659),h=e.i(263676),g=e.i(271645),f=e.i(798120),x=e.i(167881),v=e.i(986530),j=e.i(23750),y=e.i(647163);let b=(0,g.memo)(({data:e,name:n,initialExpandDepth:s=2})=>{let r=(0,g.useMemo)(()=>"string"==typeof e?function(e){let t=e.trim();if(!(t.startsWith("{")&&t.endsWith("}"))&&!(t.startsWith("[")&&t.endsWith("]")))return{success:!1,data:e};try{return{success:!0,data:JSON.parse(e)}}catch{return{success:!1,data:e}}}(e).data:e,[e]);return(0,t.jsx)("div",{className:" text-sm transition-all duration-300",children:(0,t.jsx)(N,{data:r,name:n,depth:0,initialExpandDepth:s})})});b.displayName="JsonView";let N=(0,g.memo)(({data:e,name:n,depth:s=0,initialExpandDepth:r})=>{var o;let a=void 0===e?"undefined":Array.isArray(e)?"array":null===e?"null":typeof e,[i,c]=(0,g.useState)("string"!==a&&s<r),l={number:"text-blue-500",boolean:"text-amber-500",null:"text-purple-500",undefined:"text-gray-500",string:"text-foreground break-all whitespace-pre-wrap",default:"text-muted-foreground"};switch(a){case"object":case"array":let d,m,p;return m=(d=(o="array"===a)?e:Object.entries(e)).length,p={open:o?"[":"{",close:o?"]":"}",collapsed:o?"[ ... ]":"{ ... }",empty:o?"[]":"{}"},0===m?(0,t.jsxs)("div",{className:"flex items-center",children:[n&&(0,t.jsxs)("span",{className:"mr-1 text-muted-foreground",children:[n,":"]}),(0,t.jsx)("span",{className:"text-muted-foreground",children:p.empty})]}):(0,t.jsxs)("div",{className:"flex flex-col",children:[(0,t.jsxs)("div",{className:"flex items-center mr-1 rounded cursor-pointer group hover:bg-input/30",onClick:()=>c(!i),children:[n&&(0,t.jsxs)("span",{className:"mr-1 text-muted-foreground hover:text-foreground",children:[n,":"]}),i?(0,t.jsx)("span",{className:"text-muted-foreground group-hover:text-foreground",children:p.open}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("span",{className:"text-muted-foreground group-hover:text-foreground",children:p.collapsed}),(0,t.jsxs)("span",{className:"ml-1 text-muted-foreground group-hover:text-foreground",children:[m," ",1===m?"item":"items"]})]})]}),i&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("div",{className:"pl-2 ml-4 border-l border-border",children:o?d.map((e,n)=>(0,t.jsx)("div",{className:"my-1",children:(0,t.jsx)(N,{data:e,name:`${n}`,depth:s+1,initialExpandDepth:r})},n)):d.map(([e,n])=>(0,t.jsx)("div",{className:"my-1",children:(0,t.jsx)(N,{data:n,name:e,depth:s+1,initialExpandDepth:r})},e))}),(0,t.jsx)("div",{className:"text-muted-foreground",children:p.close})]})]});case"string":return e.length>100?(0,t.jsxs)("div",{className:"flex mr-1 rounded group hover:bg-input/30",children:[n&&(0,t.jsxs)("span",{className:"mr-1 text-muted-foreground hover:text-foreground",children:[n,":"]}),(0,t.jsx)("pre",{className:(0,y.cn)(l.string,"cursor-pointer group-hover:text-foreground"),onClick:()=>c(!i),title:i?"Click to collapse":"Click to expand",children:i?`"${e}"`:`"${e.slice(0,100)}..."`})]}):(0,t.jsxs)("div",{className:"flex mr-1 rounded hover:bg-input/30",children:[n&&(0,t.jsxs)("span",{className:"mr-1 text-muted-foreground",children:[n,":"]}),(0,t.jsxs)("pre",{className:l.string,children:['"',e,'"']})]});case"undefined":return(0,t.jsxs)("div",{className:"flex items-center mr-1 rounded hover:bg-input/30",children:[n&&(0,t.jsxs)("span",{className:"mr-1 text-muted-foreground",children:[n,":"]}),(0,t.jsx)("span",{className:l.undefined,children:"undefined"})]});default:return(0,t.jsxs)("div",{className:"flex items-center mr-1 rounded hover:bg-input/30",children:[n&&(0,t.jsxs)("span",{className:"mr-1 text-muted-foreground",children:[n,":"]}),(0,t.jsx)("span",{className:l[a]||l.default,children:null===e?"null":String(e)})]})}});N.displayName="JsonNode";var k=e.i(917162),S=e.i(319036),C=e.i(127341),w=e.i(184762),z=e.i(6799),O=e.i(95187);let T=(0,O.createServerReference)("7f2e7f8f690055834405764f5ccc558b982feef623",O.callServer,void 0,O.findSourceMapURL,"callToolAction"),A=(0,O.createServerReference)("7f11c12690584a91e6473cd4ffa96ed746042a0dd0",O.callServer,void 0,O.findSourceMapURL,"deleteServerAction"),I=(0,O.createServerReference)("7f3027608f18c137a6f72b126943313b516c66155a",O.callServer,void 0,O.findSourceMapURL,"refreshServerAction"),P=(0,O.createServerReference)("7f2b77401f0cf3983b907d95b86ef3a82798cbac88",O.callServer,void 0,O.findSourceMapURL,"registerServerAction");var F=e.i(681307),$=e.i(245629);let M=F.z.object({url:F.z.url(),headers:F.z.record(F.z.string(),F.z.string()).optional(),oauthClient:F.z.object({clientId:F.z.string().min(1),clientSecret:F.z.string().optional()}).optional()}),R=F.z.object({command:F.z.string().min(1),args:F.z.array(F.z.string()).optional(),env:F.z.record(F.z.string(),F.z.string()).optional()}),D=F.z.union([M,R]),E=F.z.object({name:F.z.string(),description:F.z.string().optional(),inputSchema:F.z.looseObject({}).optional(),outputSchema:F.z.looseObject({}).optional()});function L(e){return"url"in e}F.z.object({clientInformation:F.z.looseObject({}).optional(),tokens:F.z.looseObject({}).optional(),authorizationServer:F.z.looseObject({}).optional(),codeVerifier:F.z.string().optional(),state:F.z.string().optional()});let q=F.z.object({name:F.z.string().min(1).max(40),config:D,toolCount:F.z.number().int(),lastError:F.z.string().nullish()}),B=E.extend({id:F.z.number().int(),description:F.z.string().nullish()});q.omit({toolCount:!0}).extend({tools:B.array().default([]),toolsSyncedAt:$.DateLikeSchema});let J=F.z.object({name:F.z.string().min(1,"Name is required").max(40).regex(/^[a-zA-Z0-9_-]+$/,"Only letters, numbers, - and _ are allowed"),config:D}),U=F.z.union([F.z.object({mcpServers:F.z.record(F.z.string(),D)}),F.z.record(F.z.string(),D)]),K=[{name:"notion",icon:"notion.so",description:"Pages, databases, and search",config:{url:"https://mcp.notion.com/mcp"}},{name:"github",icon:"github.com",description:"Repos, issues, PRs — paste a personal access token",config:{url:"https://api.githubcopilot.com/mcp/",headers:{Authorization:"Bearer <your-github-pat>"}}},{name:"linear",icon:"linear.app",description:"Issues, projects, and cycles",config:{url:"https://mcp.linear.app/mcp"}},{name:"slack",icon:"slack.com",description:"Channels, messages, and search",config:{url:"https://mcp.slack.com/mcp"}},{name:"atlassian",icon:"atlassian.com",description:"Jira and Confluence",config:{url:"https://mcp.atlassian.com/v1/mcp"}},{name:"asana",icon:"asana.com",description:"Tasks, projects, and portfolios",config:{url:"https://mcp.asana.com/mcp"}},{name:"monday",icon:"monday.com",description:"Boards, items, and updates",config:{url:"https://mcp.monday.com/mcp"}},{name:"clickup",icon:"clickup.com",description:"Tasks, docs, and spaces",config:{url:"https://mcp.clickup.com/mcp"}},{name:"airtable",icon:"airtable.com",description:"Bases, tables, and records",config:{url:"https://mcp.airtable.com/mcp"}},{name:"box",icon:"box.com",description:"Files, folders, and content search",config:{url:"https://mcp.box.com/mcp"}},{name:"figma",icon:"figma.com",description:"Design files and components",config:{url:"https://mcp.figma.com/mcp"}},{name:"canva",icon:"canva.com",description:"Create and manage designs",config:{url:"https://mcp.canva.com/mcp"}},{name:"sanity",icon:"sanity.io",description:"Structured content and datasets",config:{url:"https://mcp.sanity.io/mcp"}},{name:"webflow",icon:"webflow.com",description:"Sites, pages, and CMS collections",config:{url:"https://mcp.webflow.com/mcp"}},{name:"wix",icon:"wix.com",description:"Sites, stores, and bookings",config:{url:"https://mcp.wix.com/mcp"}},{name:"hubspot",icon:"hubspot.com",description:"Contacts, deals, and companies",config:{url:"https://app.hubspot.com/mcp/v1/http"}},{name:"attio",icon:"attio.com",description:"CRM records and lists",config:{url:"https://mcp.attio.com/mcp"}},{name:"intercom",icon:"intercom.com",description:"Conversations and support tickets",config:{url:"https://mcp.intercom.com/mcp"}},{name:"fireflies",icon:"fireflies.ai",description:"Meeting transcripts and summaries",config:{url:"https://mcp.fireflies.ai/mcp"}},{name:"stripe",icon:"stripe.com",description:"Payments, invoices, and customers",config:{url:"https://mcp.stripe.com"}},{name:"paypal",icon:"paypal.com",description:"Payments and orders",config:{url:"https://mcp.paypal.com/mcp"}},{name:"square",icon:"squareup.com",description:"Payments, catalog, and orders",config:{url:"https://mcp.squareup.com/mcp"}},{name:"ramp",icon:"ramp.com",description:"Spend, cards, and transactions",config:{url:"https://mcp.ramp.com/mcp"}},{name:"vercel",icon:"vercel.com",description:"Deployments and projects",config:{url:"https://mcp.vercel.com"}},{name:"netlify",icon:"netlify.com",description:"Sites, builds, and deploys",config:{url:"https://mcp.netlify.com/mcp"}},{name:"cloudflare",icon:"cloudflare.com",description:"Workers bindings — D1, R2, KV",config:{url:"https://bindings.mcp.cloudflare.com/mcp"}},{name:"supabase",icon:"supabase.com",description:"Projects, tables, and SQL",config:{url:"https://mcp.supabase.com/mcp"}},{name:"neon",icon:"neon.tech",description:"Postgres branches and queries",config:{url:"https://mcp.neon.tech/mcp"}},{name:"prisma",icon:"prisma.io",description:"Postgres databases and schema",config:{url:"https://mcp.prisma.io/mcp"}},{name:"sentry",icon:"sentry.io",description:"Errors and performance issues",config:{url:"https://mcp.sentry.dev/mcp"}},{name:"grafana",icon:"grafana.com",description:"Dashboards, metrics, and alerts",config:{url:"https://mcp.grafana.com/mcp"}},{name:"semgrep",icon:"semgrep.dev",description:"Scan code for security findings",config:{url:"https://mcp.semgrep.ai/mcp"}},{name:"postman",icon:"postman.com",description:"Collections, environments, and requests",config:{url:"https://mcp.postman.com/mcp"}},{name:"resend",icon:"resend.com",description:"Send email and manage audiences",config:{url:"https://mcp.resend.com/mcp"}},{name:"hugging-face",icon:"huggingface.co",description:"Models, datasets, and Spaces",config:{url:"https://huggingface.co/mcp"}},{name:"apify",icon:"apify.com",description:"Run scrapers and automation actors",config:{url:"https://mcp.apify.com"}},{name:"exa",icon:"exa.ai",description:"Web search for agents",config:{url:"https://mcp.exa.ai/mcp"}},{name:"kagi",icon:"kagi.com",description:"Search, summarize, and answer",config:{url:"https://mcp.kagi.com/mcp"}},{name:"context7",icon:"context7.com",description:"Up-to-date library docs",config:{url:"https://mcp.context7.com/mcp"}},{name:"deepwiki",icon:"deepwiki.com",description:"Ask questions about any GitHub repo",config:{url:"https://mcp.deepwiki.com/mcp"}},{name:"microsoft-learn",icon:"learn.microsoft.com",description:"Microsoft and Azure docs — no account",config:{url:"https://learn.microsoft.com/api/mcp"}},{name:"aws-knowledge",icon:"aws.amazon.com",description:"AWS docs and API references — no account",config:{url:"https://knowledge-mcp.global.api.aws"}},{name:"cloudflare-docs",icon:"developers.cloudflare.com",description:"Cloudflare docs — no account",config:{url:"https://docs.mcp.cloudflare.com/mcp"}},{name:"stack-overflow",icon:"stackoverflow.com",description:"Questions, answers, and teams",config:{url:"https://mcp.stackoverflow.com"}},{name:"playwright",icon:"playwright.dev",description:"Drive a real browser",config:{command:"npx",args:["@playwright/mcp@latest"]}},{name:"chrome-devtools",icon:"developer.chrome.com",description:"Inspect and debug Chrome",config:{command:"npx",args:["chrome-devtools-mcp@latest"]}}];var _=e.i(895836),H=e.i(333999),W=e.i(609856),V=e.i(283653);function G({name:e,onDone:n}){let{data:s,isLoading:r}=(0,V.useServerRoute)(f.queryKey.mcpServer(e)),[o,a]=(0,W.useServerAction)(I,{...ec,onOk:t=>{ec.onOk(t),(0,V.revalidate)(f.queryKey.mcpServer(e))}}),[i,c]=(0,W.useServerAction)(A,{okMessage:"Server deleted",onOk:()=>{n(),(0,V.revalidate)(f.queryKey.mcp)}}),l=async()=>{await k.notify.confirm({title:`Delete ${e}?`,description:"Its connection and saved authorization go with it.",okText:"Delete",destructive:!0})&&i(e)};if(r)return(0,t.jsx)(_.SettingSkeleton,{rows:4});if(!s)return null;let m=s.tools.length,p=L(s.config)?"HTTP":"STDIO";return(0,t.jsxs)(_.SettingDialogContent,{title:s.name,description:(0,t.jsxs)("span",{className:"flex min-w-0 items-center gap-1.5",children:[(0,t.jsx)("span",{className:"shrink-0 rounded-sm bg-muted px-1.5 py-0.5 font-mono text-[10px]",children:p}),(0,t.jsx)("span",{className:"truncate font-mono",children:ed(s.config)})]}),footer:(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(x.Button,{variant:"ghost",loading:c,onClick:l,children:[(0,t.jsx)(u.Trash2,{}),"Delete"]}),(0,t.jsxs)(x.Button,{variant:"outline",loading:a,onClick:()=>o(s.name),children:[(0,t.jsx)(d,{}),"Reconnect"]})]}),children:[s.lastError&&(0,t.jsx)("p",{className:"rounded-lg bg-destructive/10 px-3 py-2 font-mono text-xs text-destructive",children:s.lastError}),(0,t.jsxs)("p",{className:"text-right font-mono text-xs text-muted-foreground",children:[m," ",1===m?"tool":"tools"]}),s.tools.map(e=>(0,t.jsx)(Y,{tool:e,serverName:s.name},e.name))]})}function Q({server:e}){let s=e.toolCount,o=e.lastError?"error":s>0?"connected":"idle";return(0,t.jsxs)("button",{type:"button",onClick:()=>{k.notify.component({className:"sm:max-w-3xl",renderer:({close:n})=>(0,t.jsx)(G,{name:e.name,onDone:n})})},className:"group flex w-full items-center gap-3 p-4 text-left outline-none transition-colors hover:bg-muted/50 focus-visible:ring-3 focus-visible:ring-ring/50 focus-visible:ring-inset",children:[(0,t.jsx)("span",{className:"grid size-10 shrink-0 place-items-center rounded-lg bg-muted text-muted-foreground",children:(0,t.jsx)(X,{server:e})}),(0,t.jsxs)("span",{className:"min-w-0 flex-1 space-y-0.5",children:[(0,t.jsxs)("span",{className:"flex min-w-0 items-center gap-1.5",children:[(0,t.jsx)("span",{className:"truncate text-sm font-medium",children:e.name}),"connected"===o&&(0,t.jsx)(n.Check,{className:"size-3 shrink-0 text-muted-foreground"})]}),(0,t.jsx)("span",{className:"block truncate text-xs text-muted-foreground",children:"error"===o?(0,t.jsx)("span",{className:"text-destructive",children:e.lastError}):(0,t.jsxs)(t.Fragment,{children:[s>0?`${s} ${1===s?"tool":"tools"}`:"No tools yet",(0,t.jsxs)("span",{className:"font-mono text-[11px] text-muted-foreground/70",children:[" · ",ed(e.config)]})]})})]}),(0,t.jsx)(r.ChevronRight,{className:"size-4 shrink-0 text-muted-foreground/60 transition-colors group-hover:text-foreground"})]})}function X({server:e}){let n,s=(n=K.find(t=>L(t.config)?L(e.config)&&t.config.url.replace(/\/+$/,"")===e.config.url.replace(/\/+$/,""):!L(e.config)&&t.config.command===e.config.command&&(t.config.args??[]).join(" ")===(e.config.args??[]).join(" "))??K.find(t=>t.name===e.name),n?.icon);return s?(0,t.jsx)("img",{src:(0,y.faviconUrl)(s),alt:"",className:"size-5"}):(0,t.jsx)(p,{className:"size-4"})}function Y({tool:e,serverName:n}){let[o,a]=(0,g.useState)(!1),[i,c]=(0,g.useState)(!1),[l,d]=(0,g.useState)(!1),m=[["inputSchema",e.inputSchema],["outputSchema",e.outputSchema]].filter(([,e])=>e);return(0,t.jsxs)("div",{className:"rounded-xl border border-border/60 bg-background p-4",children:[(0,t.jsxs)("div",{className:"min-w-0 space-y-1",children:[(0,t.jsx)("span",{className:"block truncate font-mono text-sm",children:e.name}),e.description?(0,t.jsx)("p",{className:(0,y.cn)("text-xs text-muted-foreground",!l&&"line-clamp-2",e.description.length>140&&"cursor-pointer"),onClick:()=>d(!l),children:e.description}):null]}),(0,t.jsxs)("div",{className:"mt-2 flex justify-end gap-1",children:[m.length>0&&(0,t.jsxs)(x.Button,{size:"xs",variant:"ghost",className:"font-mono",onClick:()=>a(!o),children:[o?(0,t.jsx)(s.ChevronDown,{}):(0,t.jsx)(r.ChevronRight,{}),"Schema"]}),(0,t.jsxs)(x.Button,{size:"xs",variant:"ghost",className:"font-mono",onClick:()=>c(!i),children:[i?(0,t.jsx)(s.ChevronDown,{}):(0,t.jsx)(r.ChevronRight,{}),"Test"]})]}),o?(0,t.jsx)("div",{className:"mt-2 space-y-3 overflow-x-auto rounded-lg border border-input p-3",children:m.map(([e,n])=>(0,t.jsxs)("div",{className:"space-y-1",children:[(0,t.jsx)("span",{className:"block font-mono text-xs text-muted-foreground",children:"inputSchema"===e?"in":"out"}),(0,t.jsx)("pre",{className:"font-mono text-xs leading-relaxed whitespace-pre",children:function e(t,n=0){if(!t||"object"!=typeof t)return"unknown";let s=" ".repeat(n+1),r=" ".repeat(n);if(Array.isArray(t.enum))return t.enum.map(e=>JSON.stringify(e)).join(" | ");let o=t.anyOf??t.oneOf;if(Array.isArray(o))return o.map(t=>e(t,n)).join(" | ");if("array"===t.type){let s=e(t.items,n);return/[|{]/.test(s)?`(${s})[]`:`${s}[]`}if("object"===t.type||t.properties){let o=t.properties;if(!o||0===Object.keys(o).length)return"{}";let a=t.required??[],i=Object.entries(o).map(([t,r])=>{let o=a.includes(t)?"":"?",i=r?.description,c="string"==typeof i&&i.length<=60?` // ${i}`:"";return`${s}${t}${o}: ${e(r,n+1)}${c}`});return`{
|
|
2
2
|
${i.join("\n")}
|
|
3
3
|
${r}}`}return Array.isArray(t.type)?t.type.join(" | "):"string"==typeof t.type?t.type:"unknown"}(n)})]},e))}):null,i?(0,t.jsx)(Z,{tool:e,serverName:n}):null]})}function Z({tool:e,serverName:n}){let[s,r]=(0,g.useState)(()=>(function(e){let t=e.inputSchema?.properties;if(!t||"object"!=typeof t)return"{}";let n={};for(let[e,s]of Object.entries(t))n[e]=s?.type==="number"||s?.type==="integer"?0:s?.type!=="boolean"&&(s?.type==="array"?[]:s?.type==="object"?{}:"");return JSON.stringify(n,null,2)})(e)),[o,a]=(0,g.useState)(""),[c,l,d,m,p]=(0,W.useServerAction)(T,{errorMessage:!1});return(0,t.jsxs)("div",{className:"mt-2 space-y-2 rounded-lg border border-input p-3",children:[(0,t.jsx)(w.Textarea,{value:s,onChange:e=>r(e.target.value),spellCheck:!1,className:"min-h-24 resize-none font-mono text-xs"}),(0,t.jsxs)("div",{className:"flex items-center justify-between gap-2",children:[(0,t.jsx)("span",{className:"font-mono text-xs text-destructive",children:o||m}),(0,t.jsxs)(x.Button,{size:"sm",loading:l,onClick:()=>{let t;try{t=s.trim()?JSON.parse(s):void 0}catch{a("Not valid JSON");return}a(""),p(),c(n,e.name,t)},children:[!l&&(0,t.jsx)(i,{}),"Run"]})]}),void 0!==d&&(0,t.jsx)("div",{className:"overflow-x-auto rounded-lg bg-muted/40 p-3",children:(0,t.jsx)(b,{data:d,initialExpandDepth:3})})]})}function ee(e){return k.notify.component({className:"sm:max-w-lg",renderer:({close:n})=>(0,t.jsx)(et,{initial:e,onDone:n})})}function et({initial:e,onDone:n}){let s=e&&L(e.config)?e.config:void 0,r=e&&!L(e.config)?e.config:void 0,[o,a]=(0,H.useObjectState)({mode:r?"stdio":"http",name:e?.name??"",url:s?.url??"",headers:er(s?.headers),clientId:s?.oauthClient?.clientId??"",clientSecret:s?.oauthClient?.clientSecret??"",command:r?.command??"",args:(r?.args??[]).join(" "),env:er(r?.env),raw:""}),{mode:i,name:c,url:l,headers:d,clientId:m,clientSecret:p,command:u,args:h,env:f,raw:y}=o,[b,N]=(0,W.useServerAction)(P,{...ec,onOk:e=>{ec.onOk(e),"error"!==e.status&&n()}}),k=(0,g.useMemo)(()=>{var e,t,n,s,r,o,a;let c,g;return"json"===i?function(e){let t,n=e.trim();if(!n)return{value:null,error:""};try{t=JSON.parse(n)}catch{return{value:null,error:"Not valid JSON"}}let s=D.safeParse(t);if(s.success)return{value:{name:null,config:s.data},error:""};let r=U.safeParse(t);if(!r.success)return{value:null,error:"Needs a url or a command"};let o=Object.entries("mcpServers"in r.data?r.data.mcpServers:r.data)[0];return o?{value:{name:o[0],config:o[1]},error:""}:{value:null,error:"No server in there"}}(y):"http"===i?(e=l,t=d,n=m,s=p,(c=M.safeParse({url:e.trim(),headers:eo(t),oauthClient:n.trim()?{clientId:n.trim(),clientSecret:s.trim()}:void 0})).success?{value:{name:null,config:c.data},error:""}:{value:null,error:e.trim()?"Needs a valid url":""}):(r=u,o=h,a=f,(g=R.safeParse({command:r.trim(),args:o.split(/\s+/).filter(Boolean),env:eo(a)})).success?{value:{name:null,config:g.data},error:""}:{value:null,error:r.trim()?"Needs a command":""})},[i,y,l,d,m,p,u,h,f]),z="json"===i?y:JSON.stringify([i,l,d,m,p,u,h,f]),[O,T]=(0,g.useState)(z);(0,g.useEffect)(()=>{let e=setTimeout(()=>T(z),700);return()=>clearTimeout(e)},[z]);let A=O===z?k.error:"",I=c||k.value?.name||"",F=J.safeParse({name:I,config:k.value?.config});function $(e){let t=k.value?.config;return t?"json"===e?a({mode:e,raw:JSON.stringify(t,null,2)}):"http"===e&&L(t)?a({mode:e,url:t.url,headers:er(t.headers),clientId:t.oauthClient?.clientId??"",clientSecret:t.oauthClient?.clientSecret??""}):"stdio"!==e||L(t)?void a({mode:e}):a({mode:e,command:t.command,args:(t.args??[]).join(" "),env:er(t.env)}):a({mode:e})}let E=(0,t.jsxs)("span",{className:"flex items-center gap-2 font-mono text-xs text-muted-foreground",children:["JSON",(0,t.jsx)(S.Switch,{size:"sm",checked:"json"===i,onCheckedChange:e=>{let t;return e?$("json"):void $((t=k.value?.config)&&!L(t)?"stdio":"http")}})]});return(0,t.jsx)(_.SettingDialogContent,{title:"Add MCP server",description:"Its tools become available to Thursday and every sub-agent.",footer:(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(x.Button,{variant:"ghost",onClick:n,children:"Cancel"}),(0,t.jsx)(x.Button,{disabled:!F.success,loading:N,onClick:()=>{F.success&&!N&&b(F.data)},children:"Connect"})]}),children:(0,t.jsxs)("div",{className:"space-y-6",children:[(0,t.jsxs)(v.Field,{children:[(0,t.jsx)(v.FieldLabel,{children:"Name"}),(0,t.jsx)(j.Input,{value:I,onChange:e=>a({name:e.target.value}),placeholder:"notion",spellCheck:!1})]}),"json"===i?(0,t.jsxs)(v.Field,{children:[(0,t.jsxs)("div",{className:"flex min-h-6 items-center justify-between gap-2",children:[(0,t.jsx)(v.FieldLabel,{children:"JSON"}),E]}),(0,t.jsx)(w.Textarea,{value:y,onChange:e=>a({raw:e.target.value}),spellCheck:!1,placeholder:ea,className:"min-h-64 resize-none font-mono text-xs"})]}):(0,t.jsxs)(C.Tabs,{value:i,onValueChange:e=>$(e),className:"gap-6",children:[(0,t.jsxs)(v.Field,{children:[(0,t.jsxs)("div",{className:"flex min-h-6 items-center justify-between gap-2",children:[(0,t.jsx)(v.FieldLabel,{children:"Transport"}),E]}),(0,t.jsxs)(C.TabsList,{className:"w-full",children:[(0,t.jsx)(C.TabsTrigger,{value:"http",children:"HTTP"}),(0,t.jsx)(C.TabsTrigger,{value:"stdio",children:"STDIO"})]})]}),(0,t.jsxs)(C.TabsContent,{value:"http",className:"space-y-6",children:[(0,t.jsxs)(v.Field,{children:[(0,t.jsx)(v.FieldLabel,{children:"URL"}),(0,t.jsx)(j.Input,{value:l,onChange:e=>a({url:e.target.value}),placeholder:"https://mcp.notion.com/mcp",spellCheck:!1,className:"font-mono text-xs"})]}),(0,t.jsx)(en,{label:"Headers",pairs:d,onChange:e=>a({headers:e}),keyPlaceholder:"Authorization",valuePlaceholder:"Bearer sk-..."}),(0,t.jsxs)(v.Field,{children:[(0,t.jsx)(v.FieldLabel,{children:"OAuth client"}),(0,t.jsxs)("div",{className:"flex gap-2",children:[(0,t.jsx)(j.Input,{value:m,onChange:e=>a({clientId:e.target.value}),placeholder:"Client ID",spellCheck:!1,className:"font-mono text-xs"}),(0,t.jsx)(j.Input,{value:p,onChange:e=>a({clientSecret:e.target.value}),placeholder:"Client secret",spellCheck:!1,type:"password",className:"font-mono text-xs"})]}),(0,t.jsx)("p",{className:"text-xs text-muted-foreground",children:"Only for servers that refuse to register clients on their own, like Figma. Leave empty and one is created during sign-in."})]})]}),(0,t.jsxs)(C.TabsContent,{value:"stdio",className:"space-y-6",children:[(0,t.jsxs)(v.Field,{children:[(0,t.jsx)(v.FieldLabel,{children:"Command"}),(0,t.jsx)(j.Input,{value:u,onChange:e=>a({command:e.target.value}),placeholder:"npx",spellCheck:!1,className:"font-mono text-xs"})]}),(0,t.jsxs)(v.Field,{children:[(0,t.jsx)(v.FieldLabel,{children:"Args"}),(0,t.jsx)(j.Input,{value:h,onChange:e=>a({args:e.target.value}),placeholder:"-y @notionhq/notion-mcp-server",spellCheck:!1,className:"font-mono text-xs"})]}),(0,t.jsx)(en,{label:"Env",pairs:f,onChange:e=>a({env:e}),keyPlaceholder:"NOTION_TOKEN",valuePlaceholder:"ntn_..."})]})]}),A&&(0,t.jsx)("p",{className:"font-mono text-xs text-destructive",children:A})]})})}function en({label:e,pairs:n,onChange:s,keyPlaceholder:r,valuePlaceholder:o}){let a=(e,t)=>s(n.map(n=>n.id===e?{...n,...t}:n));return(0,t.jsxs)(v.Field,{children:[(0,t.jsx)(v.FieldLabel,{children:e}),(0,t.jsxs)("div",{className:"space-y-2",children:[n.map(e=>(0,t.jsxs)("div",{className:"flex gap-2",children:[(0,t.jsx)(j.Input,{value:e.key,onChange:t=>a(e.id,{key:t.target.value}),placeholder:r,spellCheck:!1,className:"font-mono text-xs"}),(0,t.jsx)(j.Input,{value:e.value,onChange:t=>a(e.id,{value:t.target.value}),placeholder:o,spellCheck:!1,className:"font-mono text-xs"}),(0,t.jsx)(x.Button,{variant:"ghost",size:"icon",onClick:()=>s(n.filter(t=>t.id!==e.id)),children:(0,t.jsx)(h.X,{})})]},e.id)),(0,t.jsxs)(x.Button,{variant:"outline",size:"sm",onClick:()=>s([...n,es()]),children:[(0,t.jsx)(c.Plus,{}),"Add"]})]})]})}let es=(e="",t="")=>({id:crypto.randomUUID(),key:e,value:t}),er=e=>Object.entries(e??{}).map(([e,t])=>es(e,t)),eo=e=>{let t=e.filter(e=>e.key.trim());if(t.length)return Object.fromEntries(t.map(e=>[e.key.trim(),e.value]))},ea=`/** STDIO Example */
|
|
4
4
|
{
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "thursday-agent",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.1",
|
|
4
4
|
"description": "A voice agent that runs on your own machine — talk to her, she hands the slow work to bots with a shell, a browser and skills.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"keywords": [
|
|
@@ -31,17 +31,11 @@
|
|
|
31
31
|
},
|
|
32
32
|
"dependencies": {
|
|
33
33
|
"@img/colour": "1.1.0",
|
|
34
|
-
"@img/sharp-libvips-linux-x64": "1.3.3",
|
|
35
|
-
"@img/sharp-libvips-linuxmusl-x64": "1.3.3",
|
|
36
|
-
"@img/sharp-linux-x64": "0.35.4",
|
|
37
|
-
"@img/sharp-linuxmusl-x64": "0.35.4",
|
|
38
34
|
"@libsql/client": "0.18.0",
|
|
39
35
|
"@libsql/client-6da938047d5fc1cd": "0.18.0",
|
|
40
36
|
"@libsql/core": "0.18.0",
|
|
41
37
|
"@libsql/hrana-client": "0.10.0",
|
|
42
38
|
"@libsql/isomorphic-ws": "0.1.5",
|
|
43
|
-
"@libsql/linux-x64-gnu": "0.5.29",
|
|
44
|
-
"@libsql/linux-x64-musl": "0.5.29",
|
|
45
39
|
"@neon-rs/load": "0.0.4",
|
|
46
40
|
"@next/env": "16.3.4",
|
|
47
41
|
"@shikijs/core": "3.23.0",
|
|
@@ -70,7 +64,6 @@
|
|
|
70
64
|
"hast-util-whitespace": "3.0.0",
|
|
71
65
|
"html-void-elements": "3.0.0",
|
|
72
66
|
"js-base64": "3.9.3",
|
|
73
|
-
"libsql": "0.5.29",
|
|
74
67
|
"mdast-util-to-hast": "13.2.1",
|
|
75
68
|
"micromark-util-character": "2.1.1",
|
|
76
69
|
"micromark-util-encode": "2.0.1",
|
|
@@ -87,7 +80,6 @@
|
|
|
87
80
|
"regex": "6.1.0",
|
|
88
81
|
"regex-recursion": "6.0.2",
|
|
89
82
|
"regex-utilities": "2.3.0",
|
|
90
|
-
"sharp": "0.35.4",
|
|
91
83
|
"shiki": "3.23.0",
|
|
92
84
|
"shiki-43d062b67f27bbdc": "3.23.0",
|
|
93
85
|
"space-separated-tokens": "2.0.2",
|
|
@@ -104,21 +96,17 @@
|
|
|
104
96
|
"vfile-message": "4.0.3",
|
|
105
97
|
"ws": "8.21.3",
|
|
106
98
|
"zwitch": "2.0.4",
|
|
99
|
+
"libsql": "0.5.29",
|
|
100
|
+
"sharp": "0.35.4",
|
|
107
101
|
"@playwright/cli": "^0.1.19"
|
|
108
102
|
},
|
|
109
103
|
"bundleDependencies": [
|
|
110
104
|
"@img/colour",
|
|
111
|
-
"@img/sharp-libvips-linux-x64",
|
|
112
|
-
"@img/sharp-libvips-linuxmusl-x64",
|
|
113
|
-
"@img/sharp-linux-x64",
|
|
114
|
-
"@img/sharp-linuxmusl-x64",
|
|
115
105
|
"@libsql/client",
|
|
116
106
|
"@libsql/client-6da938047d5fc1cd",
|
|
117
107
|
"@libsql/core",
|
|
118
108
|
"@libsql/hrana-client",
|
|
119
109
|
"@libsql/isomorphic-ws",
|
|
120
|
-
"@libsql/linux-x64-gnu",
|
|
121
|
-
"@libsql/linux-x64-musl",
|
|
122
110
|
"@neon-rs/load",
|
|
123
111
|
"@next/env",
|
|
124
112
|
"@shikijs/core",
|
|
@@ -147,7 +135,6 @@
|
|
|
147
135
|
"hast-util-whitespace",
|
|
148
136
|
"html-void-elements",
|
|
149
137
|
"js-base64",
|
|
150
|
-
"libsql",
|
|
151
138
|
"mdast-util-to-hast",
|
|
152
139
|
"micromark-util-character",
|
|
153
140
|
"micromark-util-encode",
|
|
@@ -164,7 +151,6 @@
|
|
|
164
151
|
"regex",
|
|
165
152
|
"regex-recursion",
|
|
166
153
|
"regex-utilities",
|
|
167
|
-
"sharp",
|
|
168
154
|
"shiki",
|
|
169
155
|
"shiki-43d062b67f27bbdc",
|
|
170
156
|
"space-separated-tokens",
|