feat(tests): update data classification UI to org's 4-tier scheme
This commit is contained in:
@@ -5,9 +5,9 @@ import type { DataClassification } from "../../types/models";
|
|||||||
// ── Options ────────────────────────────────────────────────────────
|
// ── Options ────────────────────────────────────────────────────────
|
||||||
|
|
||||||
const CLASSIFICATION_OPTIONS: { value: DataClassification; label: string; color: string }[] = [
|
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: "public_release", label: "Public Release", 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: "general_use", label: "General Use", 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: "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" },
|
{ 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>
|
</span>
|
||||||
<DataClassificationBadge
|
<DataClassificationBadge
|
||||||
value={test.data_classification}
|
value={test.data_classification}
|
||||||
canEdit={role === "admin"}
|
canEdit={["admin", "manager", "red_tech", "red_lead", "blue_tech", "blue_lead"].includes(role)}
|
||||||
isSaving={isUpdatingClassification}
|
isSaving={isUpdatingClassification}
|
||||||
onChange={onUpdateClassification}
|
onChange={onUpdateClassification}
|
||||||
/>
|
/>
|
||||||
|
|||||||
@@ -62,7 +62,7 @@ export type ContainmentResult = "contained" | "partially_contained" | "not_conta
|
|||||||
|
|
||||||
export type AttackSuccessResult = "successful" | "not_successful" | "partially_successful";
|
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";
|
export type ValidationStatus = "pending" | "approved" | "rejected";
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user