Skip to content

Commit

Permalink
fixup! Make stylelint happy
Browse files Browse the repository at this point in the history
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
  • Loading branch information
susnux committed Aug 18, 2023
1 parent d05b825 commit 277dc6f
Showing 1 changed file with 18 additions and 22 deletions.
40 changes: 18 additions & 22 deletions src/components/NcInputField/NcInputField.vue
Expand Up @@ -394,13 +394,25 @@ export default {
&:focus-visible {
box-shadow: rgb(248, 250, 252) 0px 0px 0px 2px, var(--color-primary-element) 0px 0px 0px 4px, rgba(0, 0, 0, 0.05) 0px 1px 2px 0px
}
// Align label text color with border color (on hover / focus)
&:focus + .input-field__label,
&:hover:not(:placeholder-shown) + .input-field__label {
color: var(--color-success-text);
}
}
&--error {
border-color: var(--color-error) !important; //Override hover border color
&:focus-visible {
box-shadow: rgb(248, 250, 252) 0px 0px 0px 2px, var(--color-primary-element) 0px 0px 0px 4px, rgba(0, 0, 0, 0.05) 0px 1px 2px 0px
}
// Align label text color with border color (on hover / focus)
&:focus + .input-field__label,
&:hover:not(:placeholder-shown) + .input-field__label {
color: var(--color-error-text);
}
}
&--leading-icon {
Expand All @@ -410,6 +422,12 @@ export default {
&--trailing-icon {
padding-inline-end: 32px;
}
// Align label text color with border color (on hover / focus)
&:focus + .input-field__label,
&:hover:not(&--success, &--error):not(:placeholder-shown) + .input-field__label {
color: var(--color-primary-element);
}
}
&__label {
Expand Down Expand Up @@ -457,28 +475,6 @@ export default {
}
}
// Align label text color with border color (on hover / focus)
&__input {
&:focus + .input-field__label,
&:hover:not(&--success, &--error):not(:placeholder-shown) + .input-field__label {
color: var(--color-primary-element);
}
&--success {
&:focus + .input-field__label,
&:hover:not(:placeholder-shown) + .input-field__label {
color: var(--color-success-text);
}
}
&--error {
&:focus + .input-field__label,
&:hover:not(:placeholder-shown) + .input-field__label {
color: var(--color-error-text);
}
}
}
&__icon {
position: absolute;
height: 32px;
Expand Down

0 comments on commit 277dc6f

Please sign in to comment.