Skip to content
Snippets Groups Projects
Commit 354f4379 authored by OZGCloud's avatar OZGCloud
Browse files

OZG-4527 Use CSS dark mode detection

parent f6e9ce87
No related branches found
No related tags found
No related merge requests found
...@@ -25,6 +25,7 @@ ...@@ -25,6 +25,7 @@
$grey: #777; $grey: #777;
$greyLight: rgba(0, 0, 0, 0.08); $greyLight: rgba(0, 0, 0, 0.08);
$darkModeGreyLight: rgba(255, 255, 255, 0.6);
$background: #fafafa; $background: #fafafa;
$dark-background: #303030; $dark-background: #303030;
......
...@@ -21,15 +21,11 @@ ...@@ -21,15 +21,11 @@
.az_icon { .az_icon {
grid-area: az_icon; grid-area: az_icon;
color: #c2c2c2; color: $darkModeGreyLight;
margin-top: 12px; margin-top: 12px;
&--active { &--active {
color: black; color: black;
&--dark-mode {
color: #c2c2c2;
}
} }
} }
...@@ -61,3 +57,9 @@ mat-icon { ...@@ -61,3 +57,9 @@ mat-icon {
mat-dialog-content { mat-dialog-content {
padding-top: 0.5rem !important; padding-top: 0.5rem !important;
} }
:host-context(.dark) {
.az_icon {
color: $darkModeGreyLight;
}
}
\ No newline at end of file
import { AppService } from '@alfa-client/app-shared';
import { COMMAND_ERROR_MESSAGES, CommandResource, hasError, isSuccessfulDone } from '@alfa-client/command-shared'; import { COMMAND_ERROR_MESSAGES, CommandResource, hasError, isSuccessfulDone } from '@alfa-client/command-shared';
import { StateResource, createEmptyStateResource, hasContent, isClipboardReadSupported } from '@alfa-client/tech-shared'; import { StateResource, createEmptyStateResource, hasContent, isClipboardReadSupported } from '@alfa-client/tech-shared';
import { SnackBarService } from '@alfa-client/ui'; import { SnackBarService } from '@alfa-client/ui';
...@@ -21,7 +20,6 @@ export class AktenzeichenEditDialogComponent implements OnInit { ...@@ -21,7 +20,6 @@ export class AktenzeichenEditDialogComponent implements OnInit {
vorgang: VorgangWithEingangResource; vorgang: VorgangWithEingangResource;
setAktenzeichenPending$: Observable<StateResource<CommandResource>> = of(createEmptyStateResource<CommandResource>()); setAktenzeichenPending$: Observable<StateResource<CommandResource>> = of(createEmptyStateResource<CommandResource>());
darkMode$: Observable<boolean>;
hasAktenzeichen$: Observable<boolean>; hasAktenzeichen$: Observable<boolean>;
isPasteSupported = false; isPasteSupported = false;
...@@ -31,7 +29,6 @@ export class AktenzeichenEditDialogComponent implements OnInit { ...@@ -31,7 +29,6 @@ export class AktenzeichenEditDialogComponent implements OnInit {
public formService: AktenzeichenEditDialogFormservice, public formService: AktenzeichenEditDialogFormservice,
private readonly snackbarService: SnackBarService, private readonly snackbarService: SnackBarService,
private readonly vorgangService: VorgangService, private readonly vorgangService: VorgangService,
private appService: AppService,
public dialogRef: MatDialogRef<AktenzeichenEditDialogComponent>, public dialogRef: MatDialogRef<AktenzeichenEditDialogComponent>,
@Inject(MAT_DIALOG_DATA) public data: AktenzeichenEditDialogData, @Inject(MAT_DIALOG_DATA) public data: AktenzeichenEditDialogData,
) { ) {
...@@ -44,7 +41,6 @@ export class AktenzeichenEditDialogComponent implements OnInit { ...@@ -44,7 +41,6 @@ export class AktenzeichenEditDialogComponent implements OnInit {
this.hasAktenzeichen$ = this.formService.valueChanges() this.hasAktenzeichen$ = this.formService.valueChanges()
.pipe(startWith(this.vorgang.aktenzeichen)) .pipe(startWith(this.vorgang.aktenzeichen))
.pipe(map(hasContent)); .pipe(map(hasContent));
this.darkMode$ = this.appService.getDarkMode();
} }
public onCancel(): void { public onCancel(): void {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment