From a68dc30b715d062044c3991aedbb71a01e852c61 Mon Sep 17 00:00:00 2001 From: Julius Osokinas <20243687+josokinas@users.noreply.github.com> Date: Wed, 17 Feb 2021 16:59:38 +0000 Subject: [PATCH] fix(core): correct "disabled" styling for checkbox and radio (#328) --- packages/core/src/components/checkbox/checkbox.scss | 10 ++++++++-- packages/core/src/components/radio/radio.scss | 10 ++++++++-- .../indicator-container/indicator-container.scss | 1 - 3 files changed, 16 insertions(+), 5 deletions(-) diff --git a/packages/core/src/components/checkbox/checkbox.scss b/packages/core/src/components/checkbox/checkbox.scss index 80d5ba52d..7e9290a4d 100644 --- a/packages/core/src/components/checkbox/checkbox.scss +++ b/packages/core/src/components/checkbox/checkbox.scss @@ -74,7 +74,13 @@ } // indicating [disabled] input - .ods-checkbox:disabled + .ods-input-indicator::after { - border-color: helpers.color('content-disabled'); + .ods-checkbox:disabled + .ods-input-indicator { + &::after { + border-color: helpers.color('content-disabled'); + } + + &::before { + background-color: helpers.color('background-disabled'); + } } } diff --git a/packages/core/src/components/radio/radio.scss b/packages/core/src/components/radio/radio.scss index 333aea106..94ea48d7a 100644 --- a/packages/core/src/components/radio/radio.scss +++ b/packages/core/src/components/radio/radio.scss @@ -35,7 +35,13 @@ } // indicating [disabled] input - .ods-radio:disabled + .ods-input-indicator::after { - background-color: helpers.color('content-disabled'); + .ods-radio:disabled + .ods-input-indicator { + &::after { + background-color: helpers.color('content-disabled'); + } + + &::before { + background-color: helpers.color('background-disabled'); + } } } diff --git a/packages/core/src/internal/indicator-container/indicator-container.scss b/packages/core/src/internal/indicator-container/indicator-container.scss index 898f6852a..1d42b5e0a 100644 --- a/packages/core/src/internal/indicator-container/indicator-container.scss +++ b/packages/core/src/internal/indicator-container/indicator-container.scss @@ -126,7 +126,6 @@ .ods-checkbox:disabled, .ods-radio:disabled { + .ods-input-indicator::before { - background-color: helpers.color('background-disabled'); border-color: helpers.color('border-disabled'); }