From 756d72b6bdcb4393eb9955196b61b09ad5151be8 Mon Sep 17 00:00:00 2001 From: Paul Gschwendtner Date: Sat, 27 May 2017 19:28:13 +0200 Subject: [PATCH] fix(dialog): invalid text color in dark themes In dark themes the dialog container will have a dark background and the text should therefore have a light text color. Currently the text color is still dark on a dark background which causes the dialog to look bad in dark themes. --- src/lib/dialog/_dialog-theme.scss | 2 ++ tools/gulp/packaging/build-tasks-gulp.ts | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/lib/dialog/_dialog-theme.scss b/src/lib/dialog/_dialog-theme.scss index 5c058ad6ca19..a5f5301ca171 100644 --- a/src/lib/dialog/_dialog-theme.scss +++ b/src/lib/dialog/_dialog-theme.scss @@ -4,8 +4,10 @@ @mixin mat-dialog-theme($theme) { $background: map-get($theme, background); + $foreground: map-get($theme, foreground); .mat-dialog-container { background: mat-color($background, dialog); + color: mat-color($foreground, text); } } diff --git a/tools/gulp/packaging/build-tasks-gulp.ts b/tools/gulp/packaging/build-tasks-gulp.ts index 49ee73be3746..a29a81e42a88 100644 --- a/tools/gulp/packaging/build-tasks-gulp.ts +++ b/tools/gulp/packaging/build-tasks-gulp.ts @@ -14,7 +14,7 @@ const inlineResources = require('../../../scripts/release/inline-resources'); * @param packageName Name of the package. Needs to be similar to the directory name in `src/`. * @param requiredPackages Required packages that will be built before building the current package. */ -export function createPackageBuildTasks(packageName: string, requiredPackages: string[] = [], ) { +export function createPackageBuildTasks(packageName: string, requiredPackages: string[] = []) { // To avoid refactoring of the project the package material will map to the source path `lib/`. const packageRoot = join(SOURCE_ROOT, packageName === 'material' ? 'lib' : packageName); const packageOut = join(DIST_ROOT, 'packages', packageName);