File size: 380 Bytes
4655dd2 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 | import { clsx, type ClassValue } from "clsx"
import { twMerge } from "tailwind-merge"
export function cn(...inputs: ClassValue[]) {
return twMerge(clsx(inputs))
}
export const API_BASE = process.env.NEXT_PUBLIC_API_URL || "http://localhost:8000"
export function formatBytes(mb: number) {
if (mb >= 1024) return `${(mb/1024).toFixed(2)} GB`
return `${mb.toFixed(1)} MB`
}
|