From 593a2b24c198e00eb90b2231f98e97da58d56742 Mon Sep 17 00:00:00 2001 From: Diogo Bastos <50139916+DiogoABastos@users.noreply.github.com> Date: Fri, 24 May 2024 11:14:33 +0100 Subject: [PATCH] AAE-22783 Fix form elements label style (#9725) --- .../form/components/form-renderer.component.scss | 13 ++++++------- lib/core/src/lib/styles/_mat-selectors.scss | 1 + 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/lib/core/src/lib/form/components/form-renderer.component.scss b/lib/core/src/lib/form/components/form-renderer.component.scss index f91248a4402..c39b3c5ccf6 100644 --- a/lib/core/src/lib/form/components/form-renderer.component.scss +++ b/lib/core/src/lib/form/components/form-renderer.component.scss @@ -17,12 +17,6 @@ } } -.adf-container-widget__header-text, -.adf-label { - font-family: var(--theme-font-family); - color: var(--theme-primary-color); -} - .adf-field-list { padding: 0; list-style-type: none; @@ -97,11 +91,16 @@ #{$mat-form-field} { width: 100%; + #{$mat-text-field-focused} { + label { + color: var(--theme-primary-color); + } + } + label { transform: scaleX(1); transition: transform 150ms linear; background-color: 300ms cubic-bezier(0.55, 0, 0.55, 0.2); - color: var(--theme-primary-color); } #{$mat-form-field-prefix} { diff --git a/lib/core/src/lib/styles/_mat-selectors.scss b/lib/core/src/lib/styles/_mat-selectors.scss index 357da5d6302..20d6a2f7aba 100644 --- a/lib/core/src/lib/styles/_mat-selectors.scss +++ b/lib/core/src/lib/styles/_mat-selectors.scss @@ -53,6 +53,7 @@ $mat-form-field-invalid: '.mat-form-field-invalid'; $mat-form-field-appearance-outline: '.mat-form-field-appearance-outline'; $mat-text-field-outlined: '.mdc-text-field--outlined'; $mat-text-field-outlined-thick: '.mdc-text-field--outlined-thick'; +$mat-text-field-focused: '.mdc-text-field--focused'; $mat-dialog-actions: '.mat-mdc-dialog-actions'; $mat-dialog-container: '.mdc-dialog__container'; $mat-dialog-content: '.mat-mdc-dialog-content';