import type { Meta } from "@storybook/react"; import { Upload } from "../src/components/Upload/Upload"; import { fn } from "@storybook/test"; import "./Upload.stories.css"; import { CodexDataSdk, CodexDataSlowSdk, CodexDataErrorSdk } from "./sdk"; const meta = { title: "Advanced/Upload", component: Upload, parameters: { layout: "centered", }, tags: ["autodocs"], argTypes: {}, args: { onMouseEnter: fn(), onMouseLeave: fn(), onClick: fn(), onSuccess: fn(), onDeleteItem: fn(), onFileChange: fn(), }, } satisfies Meta; export default meta; type Props = { onClick?: () => void; onMouseEnter?: () => void; onMouseLeave?: () => void; onSuccess?: () => void; onDeletedItem?: () => void; }; const Template = (p: Props) => { return ; }; export const Multiple = Template.bind({}); const SlowTemplate = (p: Props) => { return (
); }; export const Slow = SlowTemplate.bind({}); const SingleTemplate = (p: Props) => { return (
{ }
); }; export const Single = SingleTemplate.bind({}); const ErrorTemplate = (p: Props) => { return (
{ }
); }; export const Error = ErrorTemplate.bind({});