import { jsx as _jsx } from "react/jsx-runtime";
import { documentTypes } from "../../constants/documents.js";
import { FileItem } from "./file-item.js";
const meta = {
    title: "Connect/Components/FileItem",
    component: FileItem,
    decorators: [
        (Story) => (_jsx("div", { className: "w-[500px] bg-white p-10", children: _jsx(Story, {}) })),
    ],
};
export default meta;
export const Default = {
    args: {
        isAllowedToCreateDocuments: true,
    },
    render: function Wrapper(args) {
        const node = {
            name: "Mock file",
            id: "1",
            kind: "file",
            documentType: "mock",
            parentFolder: "1",
        };
        const fileNodes = [...documentTypes, "SOME RANDOM DOCUMENT TYPE"].map((documentType, index) => ({
            ...node,
            documentType,
            id: `file-${index}`,
            name: `${documentType} document`,
        }));
        return (_jsx("div", { className: "flex flex-wrap gap-2", children: fileNodes.map((node) => (_jsx(FileItem, { fileNode: node, ...args }, node.id))) }));
    },
};
export const NotAllowedToCreateDocuments = {
    ...Default,
    args: {
        ...Default.args,
        isAllowedToCreateDocuments: false,
    },
};
//# sourceMappingURL=file-item.stories.js.map