The VS Code of video editing, built for agents.
TypeScript
Enhance attachment tile styling and improve composer layout
konstantin-paulusba792a329543
diff --git a/apps/web/src/agent-chat/attachments.tsx b/apps/web/src/agent-chat/attachments.tsxindex 8af0c7bf..3bcc225b 100644--- a/apps/web/src/agent-chat/attachments.tsx+++ b/apps/web/src/agent-chat/attachments.tsx@@ -11,6 +11,7 @@ import { Show, createSignal } from "solid-js";import { Icon } from "@/components/ui/icon";import { RemoveButton } from "@/components/ui/remove-button";+import { cx } from "@/lib/cva";/*** A file or folder dropped onto a composer. Only what the tile and the@@ -142,6 +143,7 @@ export function DropOverlay(props: { radius?: string }) {type AttachmentTileProps = {attachment: Attachment;+ class?: string;onRemove(): void;};@@ -153,7 +155,10 @@ type AttachmentTileProps = {*/export function AttachmentTile(props: AttachmentTileProps) {return (- <div class="group relative size-10 shrink-0" title={props.attachment.name}>+ <div+ class={cx("group relative size-10 shrink-0", props.class)}+ title={props.attachment.name}+ ><div class="grid size-full place-items-center overflow-hidden rounded-lg bg-input text-muted-foreground"><Showwhen={props.attachment.kind === "folder"}diff --git a/apps/web/src/agent-chat/composer.tsx b/apps/web/src/agent-chat/composer.tsxindex dc524198..8058e54d 100644--- a/apps/web/src/agent-chat/composer.tsx+++ b/apps/web/src/agent-chat/composer.tsx@@ -76,11 +76,12 @@ export function Composer(props: ComposerProps) {{/* The remove buttons overhang the tiles' corners, and a scrollingrow clips at its edge — so the row pads for them and pulls itselfback up by the same amount. */}- <div class="-mt-2.5 flex w-full items-start gap-2 overflow-x-auto pt-2.5 pr-2.5">+ <div class="-mt-2.5 flex w-full items-start gap-1.5 overflow-x-auto pt-2.5 pr-2.5"><For each={props.attachments}>{(entry) => (<AttachmentTileattachment={entry}+ class="size-9 [&>div]:rounded-md"onRemove={() => props.onAttachments(props.attachments.filter((item) => item.key !== entry.key))}/>)}