"use client" import type { CertificateDto } from "@mmapp/contracts/certificates" import { cn } from "@/lib/utils" function daysLeftBar(days: number, total = 365): number { if (days <= 0) return 0 return Math.min(100, Math.round((days / total) * 100)) } function CertificateExpandedDetail({ cert }: { cert: CertificateDto }) { const pct = daysLeftBar(cert.daysLeft) return (
Key size
{cert.keySize} bit
Действителен с
{cert.validFrom}
SAN / Alt Names
Trusted
{cert.trusted ? "Да (доверенный)" : "Нет (не доверенный)"}