From 2c443a5bc32422b50d9367b65962348e870448ac Mon Sep 17 00:00:00 2001 From: eugene-sinitsyn Date: Tue, 10 Mar 2020 17:48:17 +0300 Subject: [PATCH] Fix actions color --- .../styles/material/_angular-material.scss | 15 +++++++++++ .../styles/material/_material-dark.scss | 2 -- .../styles/material/_material-light.scss | 2 -- ...material.scss => _material-overrides.scss} | 25 +++++-------------- src/app/@theme/styles/styles.scss | 7 +++++- 5 files changed, 27 insertions(+), 24 deletions(-) create mode 100644 src/app/@theme/styles/material/_angular-material.scss rename src/app/@theme/styles/material/{_material.scss => _material-overrides.scss} (56%) diff --git a/src/app/@theme/styles/material/_angular-material.scss b/src/app/@theme/styles/material/_angular-material.scss new file mode 100644 index 00000000..b0e53a15 --- /dev/null +++ b/src/app/@theme/styles/material/_angular-material.scss @@ -0,0 +1,15 @@ +@import '~@angular/material/theming'; + +@mixin angular-material() { + @include mat-core(); + + @include nb-for-theme(material-dark) { + $custom-dark-theme: mat-dark-theme(mat-palette($mat-pink), mat-palette($mat-blue-grey)); + @include angular-material-theme($custom-dark-theme); + } + + @include nb-for-theme(material-light) { + $custom-light-theme: mat-light-theme(mat-palette($mat-indigo), mat-palette($mat-pink)); + @include angular-material-theme($custom-light-theme); + } +} \ No newline at end of file diff --git a/src/app/@theme/styles/material/_material-dark.scss b/src/app/@theme/styles/material/_material-dark.scss index 6f7bead5..045fbbc4 100644 --- a/src/app/@theme/styles/material/_material-dark.scss +++ b/src/app/@theme/styles/material/_material-dark.scss @@ -375,8 +375,6 @@ $theme: ( footer-text-color: text-basic-color, footer-text-highlight-color: footer-text-color, sidebar-background-color: background-basic-color-2, - actions-icon-color: text-basic-color, - actions-text-color: text-basic-color, material-regular-font-weight: 400, menu-text-font-weight: material-regular-font-weight, diff --git a/src/app/@theme/styles/material/_material-light.scss b/src/app/@theme/styles/material/_material-light.scss index 169fdb19..f7e84821 100644 --- a/src/app/@theme/styles/material/_material-light.scss +++ b/src/app/@theme/styles/material/_material-light.scss @@ -375,8 +375,6 @@ $theme: ( footer-text-color: text-alternate-color, footer-text-highlight-color: footer-text-color, sidebar-background-color: background-basic-color-2, - actions-icon-color: text-alternate-color, - actions-text-color: text-alternate-color, menu-text-font-weight: 400, menu-text-color: rgba(0, 0, 0, 0.87), diff --git a/src/app/@theme/styles/material/_material.scss b/src/app/@theme/styles/material/_material-overrides.scss similarity index 56% rename from src/app/@theme/styles/material/_material.scss rename to src/app/@theme/styles/material/_material-overrides.scss index 4d228533..ebb4c246 100644 --- a/src/app/@theme/styles/material/_material.scss +++ b/src/app/@theme/styles/material/_material-overrides.scss @@ -1,29 +1,16 @@ -@import '~@angular/material/theming'; - -@include nb-install() { - @include nb-for-theme(material-dark) { - $custom-dark-theme: mat-dark-theme(mat-palette($mat-pink), mat-palette($mat-blue-grey)); - @include angular-material-theme($custom-dark-theme); - } - - @include nb-for-theme(material-light) { - $custom-light-theme: mat-light-theme(mat-palette($mat-indigo), mat-palette($mat-pink)); - @include angular-material-theme($custom-light-theme); - } - +@mixin material-overrides() { @include nb-for-themes(material-dark, material-light) { - @include mat-core(); - nb-layout-header { - .logo-container nb-icon { - color: nb-theme(text-control-color); + nb-actions, .logo-container { + nb-icon, .user-name { + color: nb-theme(color-basic-100) !important; + } } - + .select-button { background-color: nb-theme(background-basic-color-3) !important; } } - nb-sidebar { transition: width 0.3s; diff --git a/src/app/@theme/styles/styles.scss b/src/app/@theme/styles/styles.scss index 42369947..4c7001bb 100644 --- a/src/app/@theme/styles/styles.scss +++ b/src/app/@theme/styles/styles.scss @@ -13,12 +13,14 @@ @import '~bootstrap/scss/mixins'; @import '~bootstrap/scss/grid'; +@import './material/angular-material'; + // loading progress bar theme @import './pace.theme'; @import './layout'; @import './overrides'; -@import './material/material'; +@import './material/material-overrides'; // install the framework and custom global styles @include nb-install() { @@ -31,5 +33,8 @@ // loading progress bar @include ngx-pace-theme(); + @include angular-material(); + @include nb-overrides(); + @include material-overrides(); };