Skip to content

Commit

Permalink
fix(themes): igx-icon gets overridden multiple themes (#15220)
Browse files Browse the repository at this point in the history
  • Loading branch information
simeonoff authored Jan 10, 2025
1 parent 70f3831 commit 06959f3
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 25 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -384,7 +384,7 @@
}

@if $variant == 'indigo' {
%igx-icon-display {
igx-icon {
--size: #{sizable(rem(14px), rem(14px), rem(16px))}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -174,14 +174,14 @@
// The wrapping element here is needed
// in order to override the !important rule of .igx-icon--inactive.
%igx-combo__case-icon {
.igx-icon {
igx-icon {
// Important is needed since the .igx-icon--inactive has !important
color: color($color: 'gray', $variant: 600) !important;
}
}

%igx-combo__case-icon--active {
.igx-icon {
igx-icon {
color: color($color: 'primary')
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -99,13 +99,9 @@
}
}

igx-icon {
@if $variant == 'indigo' {
--component-size: 2;
} @else {
width: var(--igx-icon-size, #{rem(15px)});
height: var(--igx-icon-size, #{rem(15px)});
font-size: var(--igx-icon-size, #{rem(15px)});
@if $variant != 'indigo' {
igx-icon {
--size: var(--igx-icon-size, #{rem(15px)});
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1204,7 +1204,7 @@
} @else {
padding-inline: pad-inline(rem(8px), rem(12px), rem(16px));

%igx-icon-display {
igx-icon {
opacity: if($theme-variant == 'light', .75, .85);

&:hover {
Expand Down Expand Up @@ -1458,12 +1458,12 @@
} @else {
padding-inline: pad-inline(rem(8px), rem(12px), rem(16px));

%igx-icon-display {
igx-icon {
opacity: if($theme-variant == 'light', .75, .85);
}

&:hover {
%igx-icon-display {
igx-icon {
opacity: 1;
}
}
Expand Down Expand Up @@ -2035,13 +2035,10 @@
position: relative;
display: flex;

igx-icon {
@if $variant == 'indigo' {
--component-size: 2;
} @else {
width: var(--igx-icon-size, #{rem(15px)});
height: var(--igx-icon-size, #{rem(15px)});
font-size: var(--igx-icon-size, #{rem(15px)});

@if $variant != 'indigo' {
igx-icon {
--size: var(--igx-icon-size, #{rem(15px)});
}
}

Expand Down Expand Up @@ -2147,15 +2144,15 @@
%grid-excel-icon {
color: var-get($theme, 'header-selected-text-color');

%igx-icon-display {
igx-icon {
color: var-get($theme, 'header-selected-text-color');
}

&:focus,
&:hover {
color: var-get($theme, 'header-selected-text-color');

%igx-icon-display {
igx-icon {
color: var-get($theme, 'header-selected-text-color');
}
}
Expand Down Expand Up @@ -2499,7 +2496,7 @@
}

%igx-group-label__icon {
&.igx-icon {
@at-root igx-icon#{&} {
--component-size: #{if($variant == 'indigo', 2, 1)};

color: var-get($theme, 'group-label-icon');
Expand Down Expand Up @@ -3447,10 +3444,9 @@
}

@if $variant == 'indigo' {
%igx-icon-display {
igx-icon {
opacity: if($theme-variant == 'light', .75, .85);


&:hover {
opacity: 1;
cursor: pointer;
Expand Down

0 comments on commit 06959f3

Please sign in to comment.