@phake/lanework 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/dist-local/client/assets/app-BLu5Ut7v.css +2 -0
- package/dist-local/client/assets/{board._owner._repo-hvj6B94q.js → board._owner._repo-BahBdjhM.js} +6 -5
- package/dist-local/client/assets/{dist-DZ2bn-Z6.js → dist-C8XwKPa6.js} +1 -1
- package/dist-local/client/assets/{gemini-2_FJD5P-.js → gemini-FrNNf4gc.js} +1 -1
- package/dist-local/client/assets/{guide-BXJBZbQA.js → guide-BcU07F30.js} +3 -3
- package/dist-local/client/assets/{index-TbIMjf2L.js → index-BBeG6qcu.js} +2 -2
- package/dist-local/client/assets/{review-status-RAnd_eAC.js → review-status-DNKYsJwj.js} +1 -1
- package/dist-local/client/assets/{routes-DhFdKFMi.js → routes-0vSeDi9u.js} +1 -1
- package/dist-local/server/assets/{_tanstack-start-manifest_v-CNDxZb5c.js → _tanstack-start-manifest_v-B0OMELmw.js} +13 -13
- package/dist-local/server/assets/{board._owner._repo-WPs_mhzX.js → board._owner._repo-Bpsm6LuL.js} +1 -1
- package/dist-local/server/assets/{board._owner._repo-BgLMPzjG.js → board._owner._repo-DkTATrxq.js} +73 -23
- package/dist-local/server/assets/{router-CaG3M3Zu.js → router-DU-_0lCL.js} +2 -2
- package/dist-local/server/server.js +2 -2
- package/package.json +1 -1
- package/dist-local/client/assets/app-DMYVKfjU.css +0 -2
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/dist-
|
|
2
|
-
import{a as e}from"./chunk-Cyuzqnbw.js";import{G as t,l as n,t as r}from"./link-CUk1Z0N6.js";import{g as i,n as a,t as o,v as s}from"./review-status-
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/dist-C8XwKPa6.js","assets/chunk-Cyuzqnbw.js","assets/index-BBeG6qcu.js","assets/link-CUk1Z0N6.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{a as e}from"./chunk-Cyuzqnbw.js";import{G as t,l as n,t as r}from"./link-CUk1Z0N6.js";import{g as i,n as a,t as o,v as s}from"./review-status-DNKYsJwj.js";import{a as c,d as l,f as u,i as d,p as f,u as p}from"./index-BBeG6qcu.js";import{S as m,_ as h,a as g,b as _,h as v,i as y,l as b,m as x,n as S,o as C,r as w,s as T,t as E,x as D,y as O}from"./gemini-FrNNf4gc.js";import{t as k}from"./reviews-core-BKrjFeCa.js";var A=[[`path`,{d:`M9 15C9 12.1716 9 10.7574 9.87868 9.87868C10.7574 9 12.1716 9 15 9L16 9C18.8284 9 20.2426 9 21.1213 9.87868C22 10.7574 22 12.1716 22 15V16C22 18.8284 22 20.2426 21.1213 21.1213C20.2426 22 18.8284 22 16 22H15C12.1716 22 10.7574 22 9.87868 21.1213C9 20.2426 9 18.8284 9 16L9 15Z`,stroke:`currentColor`,strokeLinecap:`round`,strokeLinejoin:`round`,strokeWidth:`1.5`,key:`0`}],[`path`,{d:`M16.9999 9C16.9975 6.04291 16.9528 4.51121 16.092 3.46243C15.9258 3.25989 15.7401 3.07418 15.5376 2.90796C14.4312 2 12.7875 2 9.5 2C6.21252 2 4.56878 2 3.46243 2.90796C3.25989 3.07417 3.07418 3.25989 2.90796 3.46243C2 4.56878 2 6.21252 2 9.5C2 12.7875 2 14.4312 2.90796 15.5376C3.07417 15.7401 3.25989 15.9258 3.46243 16.092C4.51121 16.9528 6.04291 16.9975 9 16.9999`,stroke:`currentColor`,strokeLinecap:`round`,strokeLinejoin:`round`,strokeWidth:`1.5`,key:`1`}]],j=[[`path`,{d:`M4 7C4.58984 7.60684 6.15973 10 7 10C7.84027 10 9.41016 7.60684 10 7M7 9L7 2`,stroke:`currentColor`,strokeLinecap:`round`,strokeLinejoin:`round`,strokeWidth:`1.5`,key:`0`}],[`path`,{d:`M4 13L4 14.5442C4 17.7892 4 19.4117 4.88607 20.5107C5.06508 20.7327 5.26731 20.9349 5.48933 21.1139C6.58831 22 8.21082 22 11.4558 22C12.1614 22 12.5141 22 12.8372 21.886C12.9044 21.8623 12.9702 21.835 13.0345 21.8043C13.3436 21.6564 13.593 21.407 14.0919 20.9081L18.8284 16.1716C19.4065 15.5935 19.6955 15.3045 19.8478 14.9369C20 14.5694 20 14.1606 20 13.3431V10C20 6.22876 20 4.34315 18.8284 3.17157C17.6569 2 15.7712 2 12 2M13 21.5V21C13 18.1716 13 16.7574 13.8787 15.8787C14.7574 15 16.1716 15 19 15H19.5`,stroke:`currentColor`,strokeLinecap:`round`,strokeLinejoin:`round`,strokeWidth:`1.5`,key:`1`}]],M=e(t()),N=`# Instructions for AI agents
|
|
3
3
|
|
|
4
4
|
These guidelines define how AI agents (Claude Code, Codex, Cursor, …) should work
|
|
5
5
|
on this repository. Follow them for code-related tasks while respecting the user's
|
|
@@ -112,4 +112,4 @@ item you disagree with, add a \`> ...\` note. I implement only after every box i
|
|
|
112
112
|
| File | Change |
|
|
113
113
|
| --- | --- |
|
|
114
114
|
| \`src/...\` | … |
|
|
115
|
-
`,F=n();function I(){let{user:e}=d.useLoaderData();return e?(0,F.jsxs)(a,{user:e,children:[(0,F.jsx)(L,{}),(0,F.jsx)(`div`,{className:`min-h-0 flex-1 overflow-y-auto`,children:(0,F.jsx)(R,{})})]}):(0,F.jsxs)(`div`,{className:`min-h-screen overflow-y-auto`,children:[(0,F.jsx)(v,{actions:(0,F.jsx)(x,{size:`sm`,children:`Continue with GitHub`})}),(0,F.jsx)(`div`,{className:`pt-16`,children:(0,F.jsx)(R,{})})]})}function L(){return(0,F.jsxs)(`div`,{className:`px-6 pt-5 pb-4`,children:[(0,F.jsxs)(r,{to:`/`,className:`mb-3 inline-flex items-center gap-1.5 rounded-lg border px-3 py-1.5 text-sm font-medium text-muted-foreground transition-colors hover:bg-muted hover:text-foreground`,children:[(0,F.jsx)(s,{icon:m,className:`size-4`}),`Back to board`]}),(0,F.jsx)(`div`,{className:`text-sm text-muted-foreground`,children:`Documentation`}),(0,F.jsx)(`h1`,{className:`mt-1 font-heading text-2xl font-semibold tracking-tight`,children:`How to use`})]})}function R(){return(0,F.jsxs)(`div`,{className:`mx-auto w-full max-w-3xl animate-in space-y-10 px-6 py-8 fade-in duration-500 motion-reduce:animate-none`,children:[(0,F.jsxs)(`section`,{className:`space-y-3`,children:[(0,F.jsx)(`h2`,{className:`font-heading text-xl font-semibold`,children:`Turn agent reviews into a board`}),(0,F.jsxs)(`p`,{className:`text-sm leading-relaxed text-muted-foreground`,children:[`This app visualizes the`,` `,(0,F.jsx)(`code`,{className:`rounded bg-muted px-1.5 py-0.5 text-xs`,children:`.agents/reviews`}),` folder of a GitHub repo. Your coding agent — Claude Code, Codex, Cursor, … — writes a review checklist per piece of work; the board groups them into columns and reads their metadata. Set it up once by adding an instructions file to your repo.`]})]}),(0,F.jsxs)(`section`,{className:`space-y-3`,children:[(0,F.jsx)(z,{icon:O,children:`How files map to the board`}),(0,F.jsx)(T,{children:(0,F.jsxs)(b,{className:`space-y-4 pt-6 text-sm`,children:[(0,F.jsx)(`p`,{className:`font-mono text-xs text-muted-foreground`,children:`.agents/reviews/`}),(0,F.jsx)(`div`,{className:`flex flex-col gap-2`,children:k.map(e=>{let t=o[e];return(0,F.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,F.jsxs)(`code`,{className:`w-28 font-mono text-xs text-foreground`,children:[e,`/`]}),(0,F.jsx)(s,{icon:D,className:`size-4 text-muted-foreground`}),(0,F.jsxs)(`span`,{className:`inline-flex items-center gap-1.5 rounded-full bg-muted px-2.5 py-1 text-xs font-medium`,children:[(0,F.jsx)(s,{icon:t.icon,className:f(`size-3.5`,t.color)}),t.label]})]},e)})}),(0,F.jsxs)(`p`,{className:`text-muted-foreground`,children:[`Each card reads its `,(0,F.jsx)(`strong`,{children:`column`}),` from the folder, and`,` `,(0,F.jsx)(`strong`,{children:`date · priority · assignees · tags · progress`}),` from the file's YAML frontmatter plus its `,(0,F.jsx)(`code`,{className:`rounded bg-muted px-1 py-0.5 text-xs`,children:`- [ ]`}),` `,`/ `,(0,F.jsx)(`code`,{className:`rounded bg-muted px-1 py-0.5 text-xs`,children:`- [x]`}),` checkboxes.`]})]})})]}),(0,F.jsxs)(`section`,{className:`space-y-4`,children:[(0,F.jsx)(z,{icon:h,children:`Set it up`}),(0,F.jsxs)(B,{n:1,title:`Add an instructions file to your repo`,children:[(0,F.jsxs)(`p`,{className:`text-sm text-muted-foreground`,children:[(0,F.jsx)(`code`,{className:`rounded bg-muted px-1.5 py-0.5 text-xs`,children:`AGENTS.md`}),` is the cross-tool standard. Drop it at your repo root — most agents pick it up automatically.`]}),(0,F.jsxs)(`div`,{className:`mt-4 grid gap-3 sm:grid-cols-2`,children:[(0,F.jsx)(V,{index:0,icon:(0,F.jsx)(C,{className:`size-5`}),tool:`Claude Code`,file:`CLAUDE.md or AGENTS.md`}),(0,F.jsx)(V,{index:1,icon:(0,F.jsx)(H,{Light:g,Dark:y}),tool:`OpenAI Codex`,file:`AGENTS.md`}),(0,F.jsx)(V,{index:2,icon:(0,F.jsx)(H,{Light:w,Dark:S}),tool:`Cursor`,file:`AGENTS.md / .cursor/rules`}),(0,F.jsx)(V,{index:3,icon:(0,F.jsx)(E,{className:`size-5`}),tool:`Gemini CLI & others`,file:`AGENTS.md / GEMINI.md`})]})]}),(0,F.jsxs)(B,{n:2,title:`Paste this standardized template`,children:[(0,F.jsx)(`p`,{className:`mb-3 text-sm text-muted-foreground`,children:`Project-agnostic. Add your own Domain Rules & Gotchas below the marked line, and swap in your own tag vocabulary.`}),(0,F.jsx)(U,{code:N,filename:`AGENTS.md`,icon:(0,F.jsx)(C,{className:`size-5`})})]}),(0,F.jsx)(B,{n:3,title:`Let the agent write a review`,children:(0,F.jsxs)(`p`,{className:`text-sm text-muted-foreground`,children:[`Ask your agent to plan a behavior-changing task. Following the rules above, it writes a checklist to`,` `,(0,F.jsx)(`code`,{className:`rounded bg-muted px-1.5 py-0.5 text-xs`,children:`.agents/reviews/todo/YYYY-MM-DD-<slug>.md`}),`. You approve by flipping every `,(0,F.jsx)(`code`,{className:`rounded bg-muted px-1 py-0.5 text-xs`,children:`- [ ]`}),` `,`to `,(0,F.jsx)(`code`,{className:`rounded bg-muted px-1 py-0.5 text-xs`,children:`- [x]`}),`; it then moves the file to `,(0,F.jsx)(`code`,{className:`rounded bg-muted px-1 py-0.5 text-xs`,children:`processing/`}),(0,F.jsx)(s,{icon:D,className:`mx-1 inline size-3.5 align-[-0.2em]`}),(0,F.jsx)(`code`,{className:`rounded bg-muted px-1 py-0.5 text-xs`,children:`done/`}),`.`]})}),(0,F.jsx)(B,{n:4,title:`Open the repo here`,children:(0,F.jsxs)(`p`,{className:`text-sm text-muted-foreground`,children:[`Use the repo switcher (top-left) or the`,` `,(0,F.jsx)(r,{to:`/`,className:`underline underline-offset-2 hover:text-foreground`,children:`projects page`}),` `,`to open the board. Cards appear as the agent creates and moves review files.`]})})]}),(0,F.jsxs)(`section`,{className:`space-y-3`,children:[(0,F.jsx)(z,{icon:_,children:`Example review file`}),(0,F.jsx)(U,{code:P,filename:`2026-06-21-rate-limiting.md`})]})]})}function z({icon:e,children:t}){return(0,F.jsxs)(`h2`,{className:`flex items-center gap-2 font-heading text-lg font-semibold`,children:[(0,F.jsx)(s,{icon:e,className:`size-5 text-primary`}),t]})}function B({n:e,title:t,children:n}){return(0,F.jsxs)(`div`,{className:`flex gap-3`,children:[(0,F.jsx)(`span`,{className:`mt-0.5 grid size-6 shrink-0 place-items-center rounded-full bg-primary text-xs font-semibold text-primary-foreground`,children:e}),(0,F.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,F.jsx)(`h3`,{className:`font-medium`,children:t}),(0,F.jsx)(`div`,{className:`mt-1`,children:n})]})]})}function V({icon:e,tool:t,file:n,index:r=0}){return(0,F.jsxs)(T,{size:`sm`,style:{animationDelay:`${r*60}ms`},className:`group relative animate-in gap-0 overflow-hidden p-4 fade-in slide-in-from-bottom-2 fill-mode-both duration-500 ease-out transition-[box-shadow,transform,--tw-ring-color] hover:-translate-y-0.5 hover:shadow-md hover:ring-foreground/20 motion-reduce:animate-none`,children:[(0,F.jsx)(`div`,{className:`pointer-events-none absolute -right-8 -top-8 size-20 rounded-full bg-primary/10 opacity-0 blur-2xl transition-opacity duration-300 group-hover:opacity-100`}),(0,F.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,F.jsx)(`span`,{className:`grid size-10 shrink-0 place-items-center rounded-xl bg-gradient-to-b from-background to-muted ring-1 ring-foreground/10 transition-transform duration-200 group-hover:scale-105`,children:e}),(0,F.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,F.jsx)(`div`,{className:`truncate text-sm font-medium`,children:t}),(0,F.jsxs)(`div`,{className:`mt-1 inline-flex max-w-full items-center gap-1.5 rounded-md bg-muted px-1.5 py-0.5 font-mono text-[11px] text-muted-foreground`,children:[(0,F.jsx)(s,{icon:_,className:`size-3 shrink-0`}),(0,F.jsx)(`span`,{className:`truncate`,children:n})]})]})]})]})}function H({Light:e,Dark:t}){return(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)(e,{className:`size-5 dark:hidden`}),(0,F.jsx)(t,{className:`hidden size-5 dark:block`})]})}function U({code:e,filename:t,lang:n=`markdown`,icon:r}){let[a,o]=(0,M.useState)(!1),[s,l]=(0,M.useState)(null);(0,M.useEffect)(()=>{let t=!0;return c(async()=>{let{codeToHtml:e}=await import(`./dist-
|
|
115
|
+
`,F=n();function I(){let{user:e}=d.useLoaderData();return e?(0,F.jsxs)(a,{user:e,children:[(0,F.jsx)(L,{}),(0,F.jsx)(`div`,{className:`min-h-0 flex-1 overflow-y-auto`,children:(0,F.jsx)(R,{})})]}):(0,F.jsxs)(`div`,{className:`min-h-screen overflow-y-auto`,children:[(0,F.jsx)(v,{actions:(0,F.jsx)(x,{size:`sm`,children:`Continue with GitHub`})}),(0,F.jsx)(`div`,{className:`pt-16`,children:(0,F.jsx)(R,{})})]})}function L(){return(0,F.jsxs)(`div`,{className:`px-6 pt-5 pb-4`,children:[(0,F.jsxs)(r,{to:`/`,className:`mb-3 inline-flex items-center gap-1.5 rounded-lg border px-3 py-1.5 text-sm font-medium text-muted-foreground transition-colors hover:bg-muted hover:text-foreground`,children:[(0,F.jsx)(s,{icon:m,className:`size-4`}),`Back to board`]}),(0,F.jsx)(`div`,{className:`text-sm text-muted-foreground`,children:`Documentation`}),(0,F.jsx)(`h1`,{className:`mt-1 font-heading text-2xl font-semibold tracking-tight`,children:`How to use`})]})}function R(){return(0,F.jsxs)(`div`,{className:`mx-auto w-full max-w-3xl animate-in space-y-10 px-6 py-8 fade-in duration-500 motion-reduce:animate-none`,children:[(0,F.jsxs)(`section`,{className:`space-y-3`,children:[(0,F.jsx)(`h2`,{className:`font-heading text-xl font-semibold`,children:`Turn agent reviews into a board`}),(0,F.jsxs)(`p`,{className:`text-sm leading-relaxed text-muted-foreground`,children:[`This app visualizes the`,` `,(0,F.jsx)(`code`,{className:`rounded bg-muted px-1.5 py-0.5 text-xs`,children:`.agents/reviews`}),` folder of a GitHub repo. Your coding agent — Claude Code, Codex, Cursor, … — writes a review checklist per piece of work; the board groups them into columns and reads their metadata. Set it up once by adding an instructions file to your repo.`]})]}),(0,F.jsxs)(`section`,{className:`space-y-3`,children:[(0,F.jsx)(z,{icon:O,children:`How files map to the board`}),(0,F.jsx)(T,{children:(0,F.jsxs)(b,{className:`space-y-4 pt-6 text-sm`,children:[(0,F.jsx)(`p`,{className:`font-mono text-xs text-muted-foreground`,children:`.agents/reviews/`}),(0,F.jsx)(`div`,{className:`flex flex-col gap-2`,children:k.map(e=>{let t=o[e];return(0,F.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,F.jsxs)(`code`,{className:`w-28 font-mono text-xs text-foreground`,children:[e,`/`]}),(0,F.jsx)(s,{icon:D,className:`size-4 text-muted-foreground`}),(0,F.jsxs)(`span`,{className:`inline-flex items-center gap-1.5 rounded-full bg-muted px-2.5 py-1 text-xs font-medium`,children:[(0,F.jsx)(s,{icon:t.icon,className:f(`size-3.5`,t.color)}),t.label]})]},e)})}),(0,F.jsxs)(`p`,{className:`text-muted-foreground`,children:[`Each card reads its `,(0,F.jsx)(`strong`,{children:`column`}),` from the folder, and`,` `,(0,F.jsx)(`strong`,{children:`date · priority · assignees · tags · progress`}),` from the file's YAML frontmatter plus its `,(0,F.jsx)(`code`,{className:`rounded bg-muted px-1 py-0.5 text-xs`,children:`- [ ]`}),` `,`/ `,(0,F.jsx)(`code`,{className:`rounded bg-muted px-1 py-0.5 text-xs`,children:`- [x]`}),` checkboxes.`]})]})})]}),(0,F.jsxs)(`section`,{className:`space-y-4`,children:[(0,F.jsx)(z,{icon:h,children:`Set it up`}),(0,F.jsxs)(B,{n:1,title:`Add an instructions file to your repo`,children:[(0,F.jsxs)(`p`,{className:`text-sm text-muted-foreground`,children:[(0,F.jsx)(`code`,{className:`rounded bg-muted px-1.5 py-0.5 text-xs`,children:`AGENTS.md`}),` is the cross-tool standard. Drop it at your repo root — most agents pick it up automatically.`]}),(0,F.jsxs)(`div`,{className:`mt-4 grid gap-3 sm:grid-cols-2`,children:[(0,F.jsx)(V,{index:0,icon:(0,F.jsx)(C,{className:`size-5`}),tool:`Claude Code`,file:`CLAUDE.md or AGENTS.md`}),(0,F.jsx)(V,{index:1,icon:(0,F.jsx)(H,{Light:g,Dark:y}),tool:`OpenAI Codex`,file:`AGENTS.md`}),(0,F.jsx)(V,{index:2,icon:(0,F.jsx)(H,{Light:w,Dark:S}),tool:`Cursor`,file:`AGENTS.md / .cursor/rules`}),(0,F.jsx)(V,{index:3,icon:(0,F.jsx)(E,{className:`size-5`}),tool:`Gemini CLI & others`,file:`AGENTS.md / GEMINI.md`})]})]}),(0,F.jsxs)(B,{n:2,title:`Paste this standardized template`,children:[(0,F.jsx)(`p`,{className:`mb-3 text-sm text-muted-foreground`,children:`Project-agnostic. Add your own Domain Rules & Gotchas below the marked line, and swap in your own tag vocabulary.`}),(0,F.jsx)(U,{code:N,filename:`AGENTS.md`,icon:(0,F.jsx)(C,{className:`size-5`})})]}),(0,F.jsx)(B,{n:3,title:`Let the agent write a review`,children:(0,F.jsxs)(`p`,{className:`text-sm text-muted-foreground`,children:[`Ask your agent to plan a behavior-changing task. Following the rules above, it writes a checklist to`,` `,(0,F.jsx)(`code`,{className:`rounded bg-muted px-1.5 py-0.5 text-xs`,children:`.agents/reviews/todo/YYYY-MM-DD-<slug>.md`}),`. You approve by flipping every `,(0,F.jsx)(`code`,{className:`rounded bg-muted px-1 py-0.5 text-xs`,children:`- [ ]`}),` `,`to `,(0,F.jsx)(`code`,{className:`rounded bg-muted px-1 py-0.5 text-xs`,children:`- [x]`}),`; it then moves the file to `,(0,F.jsx)(`code`,{className:`rounded bg-muted px-1 py-0.5 text-xs`,children:`processing/`}),(0,F.jsx)(s,{icon:D,className:`mx-1 inline size-3.5 align-[-0.2em]`}),(0,F.jsx)(`code`,{className:`rounded bg-muted px-1 py-0.5 text-xs`,children:`done/`}),`.`]})}),(0,F.jsx)(B,{n:4,title:`Open the repo here`,children:(0,F.jsxs)(`p`,{className:`text-sm text-muted-foreground`,children:[`Use the repo switcher (top-left) or the`,` `,(0,F.jsx)(r,{to:`/`,className:`underline underline-offset-2 hover:text-foreground`,children:`projects page`}),` `,`to open the board. Cards appear as the agent creates and moves review files.`]})})]}),(0,F.jsxs)(`section`,{className:`space-y-3`,children:[(0,F.jsx)(z,{icon:_,children:`Example review file`}),(0,F.jsx)(U,{code:P,filename:`2026-06-21-rate-limiting.md`})]})]})}function z({icon:e,children:t}){return(0,F.jsxs)(`h2`,{className:`flex items-center gap-2 font-heading text-lg font-semibold`,children:[(0,F.jsx)(s,{icon:e,className:`size-5 text-primary`}),t]})}function B({n:e,title:t,children:n}){return(0,F.jsxs)(`div`,{className:`flex gap-3`,children:[(0,F.jsx)(`span`,{className:`mt-0.5 grid size-6 shrink-0 place-items-center rounded-full bg-primary text-xs font-semibold text-primary-foreground`,children:e}),(0,F.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,F.jsx)(`h3`,{className:`font-medium`,children:t}),(0,F.jsx)(`div`,{className:`mt-1`,children:n})]})]})}function V({icon:e,tool:t,file:n,index:r=0}){return(0,F.jsxs)(T,{size:`sm`,style:{animationDelay:`${r*60}ms`},className:`group relative animate-in gap-0 overflow-hidden p-4 fade-in slide-in-from-bottom-2 fill-mode-both duration-500 ease-out transition-[box-shadow,transform,--tw-ring-color] hover:-translate-y-0.5 hover:shadow-md hover:ring-foreground/20 motion-reduce:animate-none`,children:[(0,F.jsx)(`div`,{className:`pointer-events-none absolute -right-8 -top-8 size-20 rounded-full bg-primary/10 opacity-0 blur-2xl transition-opacity duration-300 group-hover:opacity-100`}),(0,F.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,F.jsx)(`span`,{className:`grid size-10 shrink-0 place-items-center rounded-xl bg-gradient-to-b from-background to-muted ring-1 ring-foreground/10 transition-transform duration-200 group-hover:scale-105`,children:e}),(0,F.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,F.jsx)(`div`,{className:`truncate text-sm font-medium`,children:t}),(0,F.jsxs)(`div`,{className:`mt-1 inline-flex max-w-full items-center gap-1.5 rounded-md bg-muted px-1.5 py-0.5 font-mono text-[11px] text-muted-foreground`,children:[(0,F.jsx)(s,{icon:_,className:`size-3 shrink-0`}),(0,F.jsx)(`span`,{className:`truncate`,children:n})]})]})]})]})}function H({Light:e,Dark:t}){return(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)(e,{className:`size-5 dark:hidden`}),(0,F.jsx)(t,{className:`hidden size-5 dark:block`})]})}function U({code:e,filename:t,lang:n=`markdown`,icon:r}){let[a,o]=(0,M.useState)(!1),[s,l]=(0,M.useState)(null);(0,M.useEffect)(()=>{let t=!0;return c(async()=>{let{codeToHtml:e}=await import(`./dist-C8XwKPa6.js`).then(e=>e.t);return{codeToHtml:e}},__vite__mapDeps([0,1,2,3])).then(({codeToHtml:t})=>t(e,{lang:n,themes:{light:`github-light`,dark:`github-dark`}})).then(e=>t&&l(e)).catch(()=>t&&l(null)),()=>{t=!1}},[e,n]);let u=t.split(`.`).pop()?.toUpperCase()??`TXT`;function d(){navigator.clipboard.writeText(e).then(()=>{o(!0),setTimeout(()=>o(!1),1500)})}function f(){let n=URL.createObjectURL(new Blob([e],{type:`text/plain;charset=utf-8`})),r=document.createElement(`a`);r.href=n,r.download=t,r.click(),URL.revokeObjectURL(n)}return(0,F.jsxs)(`div`,{className:`overflow-hidden rounded-xl border bg-card`,children:[(0,F.jsxs)(`div`,{className:`flex items-center justify-between gap-2 border-b bg-muted/40 px-3 py-2`,children:[(0,F.jsxs)(`div`,{className:`flex min-w-0 items-center gap-2`,children:[r?(0,F.jsx)(`span`,{className:`grid size-5 shrink-0 place-items-center`,children:r}):(0,F.jsx)(`span`,{className:`grid size-5 shrink-0 place-items-center rounded bg-foreground/85 font-mono text-[9px] font-bold text-background`,children:u}),(0,F.jsx)(`span`,{className:`truncate font-mono text-xs text-muted-foreground`,children:t})]}),(0,F.jsxs)(`div`,{className:`flex items-center gap-0.5`,children:[(0,F.jsx)(W,{onClick:f,icon:j,label:`Download`}),(0,F.jsx)(W,{onClick:d,icon:a?i:A,label:a?`Copied`:`Copy`})]})]}),(0,F.jsx)(`div`,{className:`shiki-block max-h-[460px] overflow-auto`,children:s?(0,F.jsx)(`div`,{dangerouslySetInnerHTML:{__html:s}}):(0,F.jsx)(`pre`,{className:`m-0 p-4 font-mono text-xs leading-relaxed text-foreground`,children:e})})]})}function W({onClick:e,icon:t,label:n}){return(0,F.jsxs)(p,{children:[(0,F.jsx)(u,{render:(0,F.jsx)(`button`,{type:`button`,onClick:e,"aria-label":n,className:`grid size-7 place-items-center rounded-md text-muted-foreground transition-colors hover:bg-foreground/10 hover:text-foreground`,children:(0,F.jsx)(s,{icon:t,className:`size-4`})})}),(0,F.jsx)(l,{children:n})]})}export{I as component};
|