Skip to content

Commit

Permalink
EPMRPP-87463 || Adjust styles for fields dark theme (#3676)
Browse files Browse the repository at this point in the history
* EPMRPP-87463 || Adjust styles for fields dark theme

* EPMRPP-87463 || Code review fixes - 1
  • Loading branch information
AmsterGet authored Nov 28, 2023
1 parent 88b30a4 commit fa6f149
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,10 @@
&.active {
color: $COLOR--darkmode-topaz-text;
}

&:hover {
color: $COLOR--bg-000;
}
}

&.divider {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -131,11 +131,17 @@

.dark {
&.autocomplete {
@include hover-state($COLOR--darkmode-gray-150);
@include focus-state($COLOR--darkmode-topaz-focused);
background-color: $COLOR--darkmode-bg-solid-98;
border-color: $COLOR--darkmode-gray-200;
}

.input {
color: $COLOR--bg-000;
}

&.error.touched {
@include error-state($COLOR--darkmode-error-default);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -26,21 +26,25 @@
cursor: pointer;
}

@mixin hover-state($backgroundColor, $color) {
@mixin hover-state($backgroundColor, $borderColor, $color: $COLOR--almost-black) {
&:hover:not(:active) {
background: $backgroundColor;
}

&.hover:not(.disabled) {
padding: 8px 11px 6px;
background-color: $backgroundColor;
border: 1px solid $color;
border: 1px solid $borderColor;
}

&.hover:not(.disabled):hover {
border: none;
padding: 9px 12px 7px;
}

&:hover:not(.selected) {
color: $color;
}
}

@mixin active-state($color) {
Expand Down Expand Up @@ -72,8 +76,8 @@

.dark {
&.dropdown-option {
@include dropdown-option($COLOR--bg-000);
@include hover-state($COLOR--darkmode-bg-solid-98, $COLOR--darkmode-topaz-focused);
@include dropdown-option($COLOR--darkmode-gray-100);
@include hover-state($COLOR--darkmode-bg-solid-98, $COLOR--darkmode-topaz-focused, $COLOR--bg-000);
@include active-state($COLOR--darkmode-topaz-pressed);

&.selected {
Expand Down
7 changes: 3 additions & 4 deletions app/src/componentLibrary/fieldText/fieldText.scss
Original file line number Diff line number Diff line change
Expand Up @@ -250,11 +250,11 @@

&.input-container {
@include input-container($COLOR--darkmode-gray-200, $COLOR--darkmode-bg-solid-98);
@include hover-state($COLOR--darkmode-gray-100);
@include focus-state($COLOR--topaz-focused);
@include hover-state($COLOR--darkmode-gray-150);
@include focus-state($COLOR--darkmode-topaz-focused);

&.error.touched {
@include error-state($COLOR--red-failed-2);
@include error-state($COLOR--darkmode-error-default);
}

&.disabled {
Expand Down Expand Up @@ -284,7 +284,6 @@
&.input {
@include input-base;
@include input-text($COLOR--bg-000);
font-family: $FONT-REGULAR;
}

&.placeholder {
Expand Down

0 comments on commit fa6f149

Please sign in to comment.