From 67e8e859e816c64f57f834dad72ed3b9d38b4444 Mon Sep 17 00:00:00 2001 From: pine3ree Date: Tue, 12 Sep 2023 16:15:29 +0200 Subject: [PATCH] Add $form-floating-label-color var (defaults to $input-placeholder-color) to allow extra customization Signed-off-by: pine3ree --- scss/_variables.scss | 1 + scss/forms/_floating-labels.scss | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/scss/_variables.scss b/scss/_variables.scss index 7706c0f6a5e0..ba10e593bbe6 100644 --- a/scss/_variables.scss +++ b/scss/_variables.scss @@ -1075,6 +1075,7 @@ $form-floating-input-padding-b: .625rem !default; $form-floating-label-height: 1.5em !default; $form-floating-label-opacity: .65 !default; $form-floating-label-transform: scale(.85) translateY(-.5rem) translateX(.15rem) !default; +$form-floating-label-color: $input-placeholder-color !default; // When the label is acting as a placeholder $form-floating-label-disabled-color: $gray-600 !default; $form-floating-transition: opacity .1s ease-in-out, transform .1s ease-in-out !default; // scss-docs-end form-floating-variables diff --git a/scss/forms/_floating-labels.scss b/scss/forms/_floating-labels.scss index 17d8e5cc5016..295013659fec 100644 --- a/scss/forms/_floating-labels.scss +++ b/scss/forms/_floating-labels.scss @@ -17,7 +17,7 @@ height: 100%; // allow textareas padding: $form-floating-padding-y $form-floating-padding-x; overflow: hidden; - color: $input-placeholder-color; + color: $form-floating-label-color; text-align: start; text-overflow: ellipsis; white-space: nowrap;