Skip to content

Commit

Permalink
💄 - style: alter color of input controls based on placeholder state
Browse files Browse the repository at this point in the history
  • Loading branch information
svenvandescheur committed Jul 25, 2024
1 parent d850ad6 commit 617008a
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/components/form/input/input.scss
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@
width: min(320px, 100%);
max-width: 100%;

&::placeholder {
color: var(--typography-color-muted);
}

&[size] {
width: auto;
}
Expand Down
5 changes: 5 additions & 0 deletions src/components/form/select/select.scss
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,11 @@
width: fit-content;
}

// Empty state
&:has(option[selected][value=""]) {
color: var(--typography-color-muted);
}

&--text-size-xs {
--mykn-select-padding-xs: calc(var(--spacing-h) / 2);
--select-font-size: var(--typography-font-size-body-xs);
Expand Down

0 comments on commit 617008a

Please sign in to comment.