Skip to content

Commit 8d2d269

Browse files
fix(colorloupe): adds correct disabled styles (#3453)
- correctly adds styles for disabled color loupes - rebuilds metadata.json - create changeset
1 parent 33a896e commit 8d2d269

File tree

3 files changed

+10
-0
lines changed

3 files changed

+10
-0
lines changed

.changeset/slow-dogs-yawn.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@spectrum-css/colorloupe": minor
3+
---
4+
5+
Color loupes should not be displayed when their color handle is disabled, so this work adds the `.is-disabled` selector to color loupe's CSS, with `opacity: 0`.

components/colorloupe/index.css

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,10 @@
6060
transform: translate(0, 0);
6161
opacity: 1;
6262
}
63+
64+
&.is-disabled {
65+
opacity: 0;
66+
}
6367
}
6468

6569
.spectrum-ColorLoupe-inner-border {

components/colorloupe/metadata/metadata.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
".spectrum-ColorLoupe-checkerboard-pattern",
88
".spectrum-ColorLoupe-inner-border",
99
".spectrum-ColorLoupe-outer-border",
10+
".spectrum-ColorLoupe.is-disabled",
1011
".spectrum-ColorLoupe.is-open",
1112
".spectrum-ColorLoupe:dir(rtl)",
1213
"[dir=\"rtl\"] .spectrum-ColorLoupe"

0 commit comments

Comments
 (0)