feat(tests): update data classification UI to org's 4-tier scheme

This commit is contained in:
kitos
2026-07-07 11:16:45 +02:00
parent a66fefa30b
commit 1519ccc95c
3 changed files with 5 additions and 5 deletions
@@ -5,9 +5,9 @@ import type { DataClassification } from "../../types/models";
// ── Options ────────────────────────────────────────────────────────
const CLASSIFICATION_OPTIONS: { value: DataClassification; label: string; color: string }[] = [
{ value: "public", label: "Public", color: "border-gray-500/30 bg-gray-800/50 text-gray-400" },
{ value: "internal", label: "Internal", color: "border-blue-500/30 bg-blue-900/30 text-blue-400" },
{ value: "sensitive", label: "Sensitive", color: "border-amber-500/30 bg-amber-900/30 text-amber-400" },
{ value: "public_release", label: "Public Release", color: "border-gray-500/30 bg-gray-800/50 text-gray-400" },
{ value: "general_use", label: "General Use", color: "border-blue-500/30 bg-blue-900/30 text-blue-400" },
{ value: "confidential", label: "Confidential", color: "border-amber-500/30 bg-amber-900/30 text-amber-400" },
{ value: "restricted", label: "Restricted", color: "border-red-500/30 bg-red-900/30 text-red-400" },
];
@@ -531,7 +531,7 @@ export default function TestDetailHeader({
</span>
<DataClassificationBadge
value={test.data_classification}
canEdit={role === "admin"}
canEdit={["admin", "manager", "red_tech", "red_lead", "blue_tech", "blue_lead"].includes(role)}
isSaving={isUpdatingClassification}
onChange={onUpdateClassification}
/>
+1 -1
View File
@@ -62,7 +62,7 @@ export type ContainmentResult = "contained" | "partially_contained" | "not_conta
export type AttackSuccessResult = "successful" | "not_successful" | "partially_successful";
export type DataClassification = "public" | "internal" | "sensitive" | "restricted";
export type DataClassification = "public_release" | "general_use" | "confidential" | "restricted";
export type ValidationStatus = "pending" | "approved" | "rejected";