From d5faa5bdcff02d95e923f7067571489df7bfe483 Mon Sep 17 00:00:00 2001 From: Gaz Jones Date: Mon, 9 Oct 2023 20:37:36 +0100 Subject: [PATCH 1/2] fix(button): disabled state on monochrome variant --- .changeset/healthy-cameras-fry.md | 5 +++++ polaris-react/src/components/Button/Button.scss | 3 +-- polaris-react/src/components/Button/Button.stories.tsx | 5 +++++ 3 files changed, 11 insertions(+), 2 deletions(-) create mode 100644 .changeset/healthy-cameras-fry.md diff --git a/.changeset/healthy-cameras-fry.md b/.changeset/healthy-cameras-fry.md new file mode 100644 index 00000000000..8b7d06f514a --- /dev/null +++ b/.changeset/healthy-cameras-fry.md @@ -0,0 +1,5 @@ +--- +'@shopify/polaris': patch +--- + +Fixes disabled state for `monochromePlain` variant in `Button` diff --git a/polaris-react/src/components/Button/Button.scss b/polaris-react/src/components/Button/Button.scss index 825d8ab4061..b26d0e2aed8 100644 --- a/polaris-react/src/components/Button/Button.scss +++ b/polaris-react/src/components/Button/Button.scss @@ -956,8 +956,7 @@ } &.disabled { - color: currentColor; - opacity: 0.4; + color: var(--p-color-text-disabled); svg { fill: currentColor; diff --git a/polaris-react/src/components/Button/Button.stories.tsx b/polaris-react/src/components/Button/Button.stories.tsx index 058bba96798..230f6c5f021 100644 --- a/polaris-react/src/components/Button/Button.stories.tsx +++ b/polaris-react/src/components/Button/Button.stories.tsx @@ -706,6 +706,11 @@ export function DisabledState() { + + + ); } From 566026a61b9aa835e0df1add17249a8aa527ea7c Mon Sep 17 00:00:00 2001 From: Gaz Jones Date: Fri, 13 Oct 2023 15:42:36 +0100 Subject: [PATCH 2/2] chore: implement feedback --- .changeset/healthy-cameras-fry.md | 2 +- polaris-react/src/components/Button/Button.stories.tsx | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.changeset/healthy-cameras-fry.md b/.changeset/healthy-cameras-fry.md index 8b7d06f514a..77866663d14 100644 --- a/.changeset/healthy-cameras-fry.md +++ b/.changeset/healthy-cameras-fry.md @@ -2,4 +2,4 @@ '@shopify/polaris': patch --- -Fixes disabled state for `monochromePlain` variant in `Button` +Fixed disabled state for `monochromePlain` variant in `Button` diff --git a/polaris-react/src/components/Button/Button.stories.tsx b/polaris-react/src/components/Button/Button.stories.tsx index 230f6c5f021..4c9c27d07c1 100644 --- a/polaris-react/src/components/Button/Button.stories.tsx +++ b/polaris-react/src/components/Button/Button.stories.tsx @@ -706,11 +706,12 @@ export function DisabledState() { - + {/* Visual check to ensure the button color is not inherited from the parent */} + - + ); }