@assistant-ui/elements-modal-sizeloading the log…
NO RECENT BUILD
Pipeline
  1. Docsusage, props, keywords
  2. Demosrc/demo.tsx
  3. Buildshadcn add → vite
  4. Capturelight, dark, motion
  5. IndexBM25 + vectors

Public log. Prompts, raw model errors and costs stay on the admin side.

Log
Demo source
src/demo.tsx · from an earlier run
import { useRef } from "react"import { ArrowUpIcon } from "lucide-react"import { useModalSize } from "@/components/assistant-ui/utils/modal-size"import { Avatar, AvatarFallback, AvatarImage } from "@/components/ui/avatar"import { Button } from "@/components/ui/button"import { Input } from "@/components/ui/input"import { avatarImage } from "@/preview/images"export default function ModalSizeDemo() {  const contentRef = useRef<HTMLDivElement>(null)  const { size, reset, handleProps } = useModalSize(contentRef)  return (    <div className="flex w-full max-w-md justify-center">      <div        ref={contentRef}        style={size ? { width: size.width, height: size.height } : undefined}        className="relative flex h-[360px] w-[360px] flex-col gap-3 overflow-hidden rounded-xl border bg-background p-4 shadow-sm"      >        <div className="flex items-center gap-3 border-b pb-3">          <Avatar>            <AvatarImage src={avatarImage("Olivia Martin")} alt="Olivia Martin" />            <AvatarFallback>OM</AvatarFallback>          </Avatar>          <div className="text-sm">            <p className="font-medium">Olivia Martin</p>            <p className="text-xs text-muted-foreground">Online</p>          </div>        </div>        <div className="flex flex-1 flex-col gap-2 text-sm">          <p className="max-w-[80%] rounded-lg bg-muted px-3 py-2">Hi! Can you help me with my order?</p>          <p className="ml-auto max-w-[80%] rounded-lg bg-primary px-3 py-2 text-primary-foreground">Of course, what do you need?</p>        </div>        <div className="flex gap-2">          <Input placeholder="Type a message..." />          <Button size="icon" aria-label="Send">            <ArrowUpIcon />          </Button>        </div>        <div          role="separator"          aria-label="Resize modal"          tabIndex={0}          onDoubleClick={reset}          {...handleProps}          className="absolute bottom-0 right-0 z-10 size-4 cursor-se-resize"        />      </div>    </div>  )}