mirror of
https://github.com/penpot/penpot.git
synced 2026-05-28 11:23:42 +00:00
🐛 Fix empty values should not have dimmed text (#7015)
This commit is contained in:
parent
4d688b1d55
commit
3b04cd37ff
@ -49,7 +49,7 @@
|
|||||||
|
|
||||||
(mf/defc option*
|
(mf/defc option*
|
||||||
{::mf/private true}
|
{::mf/private true}
|
||||||
[{:keys [id ref label icon aria-label on-click selected focused dimmed] :rest props}]
|
[{:keys [id ref label icon aria-label on-click selected focused] :rest props}]
|
||||||
(let [class (stl/css-case :option true
|
(let [class (stl/css-case :option true
|
||||||
:option-with-icon (some? icon)
|
:option-with-icon (some? icon)
|
||||||
:option-selected selected
|
:option-selected selected
|
||||||
@ -72,9 +72,7 @@
|
|||||||
:aria-hidden (when label true)
|
:aria-hidden (when label true)
|
||||||
:aria-label (when (not label) aria-label)}])
|
:aria-label (when (not label) aria-label)}])
|
||||||
|
|
||||||
[:span {:class (stl/css-case :option-text true
|
[:span {:class (stl/css :option-text)} label]
|
||||||
:option-text-dimmed dimmed)}
|
|
||||||
label]
|
|
||||||
|
|
||||||
(when selected
|
(when selected
|
||||||
[:> i/icon*
|
[:> i/icon*
|
||||||
@ -117,7 +115,6 @@
|
|||||||
:aria-label aria-label
|
:aria-label aria-label
|
||||||
:ref ref
|
:ref ref
|
||||||
:focused (= id focused)
|
:focused (= id focused)
|
||||||
:dimmed false
|
|
||||||
:on-click on-click}]))
|
:on-click on-click}]))
|
||||||
|
|
||||||
(when (seq options-blank)
|
(when (seq options-blank)
|
||||||
@ -138,5 +135,4 @@
|
|||||||
:aria-label aria-label
|
:aria-label aria-label
|
||||||
:ref ref
|
:ref ref
|
||||||
:focused (= id focused)
|
:focused (= id focused)
|
||||||
:dimmed true
|
|
||||||
:on-click on-click}]))])]))
|
:on-click on-click}]))])]))
|
||||||
|
|||||||
@ -67,10 +67,6 @@
|
|||||||
padding-inline-start: var(--sp-xxs);
|
padding-inline-start: var(--sp-xxs);
|
||||||
}
|
}
|
||||||
|
|
||||||
.option-text-dimmed {
|
|
||||||
color: var(--options-dropdown-empty);
|
|
||||||
}
|
|
||||||
|
|
||||||
.option-icon {
|
.option-icon {
|
||||||
color: var(--options-dropdown-icon-fg-color);
|
color: var(--options-dropdown-icon-fg-color);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user