import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
import { Icon } from "@powerhousedao/design-system";
function getDocumentIcon(documentType) {
    switch (documentType) {
        case "analytics-processor":
            return "AnalyticsProcessorModule";
        case "relational-processor":
            return "RelationalProcessorModule";
        case "codegen-processor":
            return "CodegenProcessorModule";
        case "app":
            return "AppModule";
        case "document-model":
            return "DocumentModelModule";
        case "editor":
            return "EditorModule";
        case "package":
            return "PackageModule";
        case "subgraph":
            return "SubgraphModule";
        default:
            return "PowerhouseDocumentModule";
    }
}
export function UploadFileItemHeader(props) {
    const { fileName, fileSize, documentType, onClose, ...delegatedProps } = props;
    return (_jsxs("div", { className: "flex items-center gap-2", ...delegatedProps, children: [_jsx("div", { className: "flex h-9 w-7 flex-shrink-0 items-center justify-center", children: _jsx(Icon, { name: getDocumentIcon(documentType), size: 48, className: "text-gray-600" }) }), _jsxs("div", { className: "flex flex-1 flex-col gap-0.5", children: [_jsx("div", { className: "text-xs font-medium leading-[18px] text-gray-900", children: fileName }), _jsx("div", { className: "text-xs font-medium leading-[18px] text-gray-500", children: fileSize })] }), onClose && (_jsx("div", { className: "flex h-9 w-[18px] flex-shrink-0 items-start justify-center", children: _jsx("button", { type: "button", onClick: onClose, className: "flex h-[18px] w-[18px] items-center justify-center text-gray-600 hover:text-gray-800", "aria-label": "Close", children: _jsx(Icon, { name: "XmarkLight", size: 18 }) }) }))] }));
}
//# sourceMappingURL=header.js.map