chore: scan attributes are always available in compliance-scan-info component

This commit is contained in:
Pablo Lara
2025-06-04 11:26:41 +02:00
parent e9a22c1513
commit 8a8586f298
2 changed files with 10 additions and 16 deletions
@@ -9,10 +9,10 @@ interface ComplianceScanInfoProps {
providerInfo: {
provider: ProviderType;
alias?: string;
uid?: string;
uid: string;
};
attributes?: {
name?: string;
attributes: {
name: string;
completed_at: string;
};
};
@@ -29,17 +29,13 @@ export const ComplianceScanInfo: React.FC<ComplianceScanInfoProps> = ({
entityId={scan.providerInfo.uid}
hideCopyButton
/>
{scan.attributes && (
<>
<Divider orientation="vertical" className="mx-2 h-6" />
<div className="flex flex-col items-start">
<p className="text-xs text-default-500">
{scan.attributes.name || "- -"}
</p>
<DateWithTime inline dateTime={scan.attributes.completed_at} />
</div>
</>
)}
<Divider orientation="vertical" className="mx-2 h-6" />
<div className="flex flex-col items-start">
<p className="text-xs text-default-500">
{scan.attributes.name || "- -"}
</p>
<DateWithTime inline dateTime={scan.attributes.completed_at} />
</div>
</div>
);
};
-2
View File
@@ -1,8 +1,6 @@
import { LucideIcon } from "lucide-react";
import { SVGProps } from "react";
import { ProviderAccountProps } from "./providers";
export type IconSvgProps = SVGProps<SVGSVGElement> & {
size?: number;
};