All files / app/codeCharta/ui/filePanel/filePanelDeltaSelector/incompatibleMapsDialog incompatibleMapsDialog.component.ts

100% Statements 11/11
100% Branches 0/0
100% Functions 2/2
100% Lines 10/10

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 316x 6x 6x 6x 6x 6x   6x                 6x     3x               3x      
import { Component, Inject } from "@angular/core"
import { MAT_DIALOG_DATA, MatDialogContent, MatDialogActions, MatDialogClose } from "@angular/material/dialog"
import { MatCheckboxChange, MatCheckbox } from "@angular/material/checkbox"
import { MatToolbar } from "@angular/material/toolbar"
import { CdkScrollable } from "@angular/cdk/scrolling"
import { MatButton } from "@angular/material/button"
 
export const ALERT_ON_INCOMPATIBLE_MAPS = "alertOnIncompatibleMaps"
 
@Component({
    selector: "cc-incompatible-maps-dialog",
    templateUrl: "./incompatibleMapsDialog.component.html",
    styleUrls: ["./incompatibleMapsDialog.component.scss"],
    standalone: true,
    imports: [MatToolbar, CdkScrollable, MatDialogContent, MatCheckbox, MatDialogActions, MatButton, MatDialogClose]
})
export class IncompatibleMapsDialogComponent {
    constructor(
        @Inject(MAT_DIALOG_DATA)
        public data: {
            referenceFileName: string
            comparisonFileName: string
            fileWithMccMetric: string
        }
    ) {}
 
    setDoNotAlertOnIncompatibleMaps($event: MatCheckboxChange) {
        localStorage.setItem(ALERT_ON_INCOMPATIBLE_MAPS, JSON.stringify(!$event.checked))
    }
}