diff --git a/CSETWebNg/src/app/assessment/results/cpg/cpg-practice-table/cpg-practice-table.component.html b/CSETWebNg/src/app/assessment/results/cpg/cpg-practice-table/cpg-practice-table.component.html index 5483e52dbb..9c885309d6 100644 --- a/CSETWebNg/src/app/assessment/results/cpg/cpg-practice-table/cpg-practice-table.component.html +++ b/CSETWebNg/src/app/assessment/results/cpg/cpg-practice-table/cpg-practice-table.component.html @@ -23,13 +23,13 @@
+ [style.background-color]="backgroundColor(d.groupingId)" [style.borderColor]="backgroundColor(d.groupingId)"> {{d.title}}
- - diff --git a/CSETWebNg/src/app/assessment/results/cpg/cpg-practice-table/cpg-practice-table.component.scss b/CSETWebNg/src/app/assessment/results/cpg/cpg-practice-table/cpg-practice-table.component.scss index 8bef05a4c2..4f4d346886 100644 --- a/CSETWebNg/src/app/assessment/results/cpg/cpg-practice-table/cpg-practice-table.component.scss +++ b/CSETWebNg/src/app/assessment/results/cpg/cpg-practice-table/cpg-practice-table.component.scss @@ -30,7 +30,7 @@ SOFTWARE. text-transform: uppercase; margin-bottom: 2rem; padding: 1rem; - border-top: 1px solid #ccc !important; + border-top: none !important; } .cpg-table { diff --git a/CSETWebNg/src/app/assessment/results/cpg/cpg-practice-table/cpg-practice-table.component.ts b/CSETWebNg/src/app/assessment/results/cpg/cpg-practice-table/cpg-practice-table.component.ts index 978b55ece9..5c941f6e05 100644 --- a/CSETWebNg/src/app/assessment/results/cpg/cpg-practice-table/cpg-practice-table.component.ts +++ b/CSETWebNg/src/app/assessment/results/cpg/cpg-practice-table/cpg-practice-table.component.ts @@ -69,11 +69,35 @@ export class CpgPracticeTableComponent implements OnInit { * Returns the color for the CSF function of the group. * This is specific to CPG grouping IDs. * + * The colors were slightly modified in CSF 2.0. + * * As SSG models are added to CSET the new grouping codes will be * added to this logic. */ backgroundColor(groupId: number): string { + + // CPG 2.0 switch (groupId) { + case 567: + // govern + return this.colorSvc.nistCsfFuncColor('GV-2'); + case 568: + // identify + return this.colorSvc.nistCsfFuncColor('ID-2'); + case 569: + // protect + return this.colorSvc.nistCsfFuncColor('PR-2'); + case 570: + return this.colorSvc.nistCsfFuncColor('DE-2'); + case 571: + // respond + return this.colorSvc.nistCsfFuncColor('RS-2'); + case 572: + // recover + return this.colorSvc.nistCsfFuncColor('RC-2'); + + + // CPG 1.0 case 200: case 560: // identify @@ -94,12 +118,17 @@ export class CpgPracticeTableComponent implements OnInit { case 564: // recover return this.colorSvc.nistCsfFuncColor('RC'); + + + // SSG - IT case 565: // SSG - IT Software Development return '#305496'; - case 566: + case 566: // SSG - IT Product Design return '#548235'; + + default: return '#6BA443'; } diff --git a/CSETWebNg/src/app/assessment/results/reports/reports.component.ts b/CSETWebNg/src/app/assessment/results/reports/reports.component.ts index 695ee8624c..d907d3ae0d 100644 --- a/CSETWebNg/src/app/assessment/results/reports/reports.component.ts +++ b/CSETWebNg/src/app/assessment/results/reports/reports.component.ts @@ -372,6 +372,8 @@ export class ReportsComponent implements OnInit, AfterViewInit { this.currentSectionId = 'MVRA'; } else if (this.assessSvc.usesMaturityModel('CPG') && !this.isMobile) { this.currentSectionId = 'CPG'; + } else if (this.assessSvc.usesMaturityModel('CPG2') && !this.isMobile) { + this.currentSectionId = 'CPG'; } else if (this.assessSvc.usesMaturityModel('VADR') && !this.isMobile) { this.currentSectionId = 'VADR'; } else if (this.assessSvc.usesMaturityModel('C2M2') && !this.isMobile) { diff --git a/CSETWebNg/src/app/services/color.service.ts b/CSETWebNg/src/app/services/color.service.ts index 6de5dd5b41..d83c37b112 100644 --- a/CSETWebNg/src/app/services/color.service.ts +++ b/CSETWebNg/src/app/services/color.service.ts @@ -95,6 +95,28 @@ export class ColorService { * anywhere CSF colors are displayed in CSET. */ nistCsfFuncColor(func: string) { + + // CSF 2.0 colors + if (func.endsWith('-2')) { + switch (func) { + case 'GV-2': + return '#f9f39b'; + case 'ID-2': + return '#4cb3e0'; + case 'PR-2': + return '#918cea'; + case 'DE-2': + return '#fab647'; + case 'RS-2': + return '#e47677'; + case 'RC-2': + return '#7ef49e'; + default: + return '#FFFFFF'; + } + } + + // CSF 1.0 colors switch (func) { case 'ID': return '#355C9B'; diff --git a/CSETWebNg/src/assets/navigation/workflow-omni.xml b/CSETWebNg/src/assets/navigation/workflow-omni.xml index 6d20b63829..6f0dd2f03e 100644 --- a/CSETWebNg/src/assets/navigation/workflow-omni.xml +++ b/CSETWebNg/src/assets/navigation/workflow-omni.xml @@ -157,7 +157,7 @@ - + @@ -405,8 +405,8 @@ - - + +
@@ -53,7 +53,7 @@ [style.background-color]="backgroundColor(d.groupingId)"> {{t('reports.core.cpg.report.current assessment') | uppercase}}
{{t('reports.core.cpg.report.notes') | uppercase}}