// Adapted from agentui (https://github.com/ashish200729/agentui), components/agents/agent-disclosure.tsx // Copyright (c) 2026 Saurabh Chauhan. MIT License, see ./LICENSE-agentui.md // 改造:motion 的 clipPath/height 动画换成 CSS grid-rows 0fr→1fr 过渡(duration-layout / ease-standard), // reduced motion 下不做过渡;收起时 inert + aria-hidden,键盘与读屏都跳过。 import type { ComponentPropsWithRef } from "react"; import { cn } from "~/lib/utils.ts"; export interface DisclosureProps extends ComponentPropsWithRef<"div"> { open: boolean; innerClassName?: string; } /** 折叠区:展开/收起只动高度与透明度 */ export function Disclosure({ open, className, innerClassName, children, ...props }: DisclosureProps) { return (