Carregando…
Carregando…
Carregando…Attached file/image card with upload states, actions and horizontal-scroll group.
$ npx kikitocn add attachment@/lib/utils@/components/ui/cn/spinner@radix-ui/react-slot| Prop | Tipo | Padrão | Descrição |
|---|---|---|---|
state | 'idle' | 'uploading' | 'processing' | 'error' | 'done' | 'done' | Estado do upload — 'uploading'/'processing' aplicam shimmer no título |
size | 'default' | 'sm' | 'xs' | 'default' | Densidade do card |
orientation | 'horizontal' | 'vertical' | 'horizontal' | Direção do layout interno |
children* | React.ReactNode | — | AttachmentMedia + AttachmentContent + AttachmentActions |
className | string | — | Classes CSS extras |
style | React.CSSProperties | — | Estilos inline extras |
done · uploading (shimmer) · error
AttachmentGroup
import { Attachment } from "@/components/ui/cn/attachment/Attachment";
export function AttachmentExample() {
return (
<Attachment state="idle" size="default">
Attachment
</Attachment>
);
}