import { getPath } from "../../utils/path.ts"; import { formatBytes } from "../../../deps/std.ts"; import breadcrumb from "../breadcrumb.ts"; import type { CMSContent, Version } from "../../../types.ts"; interface Props { options: CMSContent; file: string; publicPath: string; type: string; size: number; collection: string; version?: Version; } export default function template( { options, type, file, collection, size, publicPath, version }: Props, ) { const { basePath } = options; const src = getPath(basePath, "uploads", collection, "raw", file); return ` ${ breadcrumb(options, version, [ collection, getPath(basePath, "uploads", collection), ], "File details") }

Details of

Public path:
${publicPath}
Type:
${type}
Size:
${formatBytes(size)}
Download file
`; }