Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(input/combo/select): styling issues #1038

Merged
merged 7 commits into from
Feb 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 22 additions & 4 deletions src/components/combo/themes/dark/_themes.scss
Original file line number Diff line number Diff line change
@@ -1,7 +1,25 @@
@use 'sass:map';
@use 'styles/utilities' as *;
@use 'igniteui-theming/sass/themes/schemas/components/dark/combo' as *;
@use 'components/input/themes/dark/themes' as input-theme;

$material: digest-schema($dark-combo);
$bootstrap: digest-schema($dark-bootstrap-combo);
$fluent: digest-schema($dark-fluent-combo);
$indigo: digest-schema($dark-indigo-combo);
$material: map.merge(digest-schema($dark-combo), (
helper-text-color: map.get(input-theme.$material, 'helper-text-color'),
disabled-text-color: map.get(input-theme.$material, 'disabled-text-color'),
error-secondary-color: map.get(input-theme.$material, 'helper-text-color')
));
$bootstrap: map.merge(digest-schema($dark-bootstrap-combo), (
helper-text-color: map.get(input-theme.$bootstrap, 'helper-text-color'),
disabled-text-color: map.get(input-theme.$bootstrap, 'disabled-text-color'),
error-secondary-color: map.get(input-theme.$bootstrap, 'error-secondary-color')
));
$fluent: map.merge(digest-schema($dark-fluent-combo), (
helper-text-color: map.get(input-theme.$fluent, 'helper-text-color'),
disabled-text-color: map.get(input-theme.$fluent, 'disabled-text-color'),
error-secondary-color: map.get(input-theme.$fluent, 'error-secondary-color')
));
$indigo: map.merge(digest-schema($dark-indigo-combo), (
helper-text-color: map.get(input-theme.$indigo, 'helper-text-color'),
disabled-text-color: map.get(input-theme.$indigo, 'disabled-text-color'),
error-secondary-color: map.get(input-theme.$indigo, 'error-secondary-color')
));
26 changes: 22 additions & 4 deletions src/components/combo/themes/light/_themes.scss
Original file line number Diff line number Diff line change
@@ -1,7 +1,25 @@
@use 'sass:map';
@use 'styles/utilities' as *;
@use 'igniteui-theming/sass/themes/schemas/components/light/combo' as *;
@use 'components/input/themes/light/themes' as input-theme;

$material: digest-schema($light-combo);
$bootstrap: digest-schema($bootstrap-combo);
$fluent: digest-schema($fluent-combo);
$indigo: digest-schema($indigo-combo);
$material: map.merge(digest-schema($light-combo), (
helper-text-color: map.get(input-theme.$material, 'helper-text-color'),
disabled-text-color: map.get(input-theme.$material, 'disabled-text-color'),
error-secondary-color: map.get(input-theme.$material, 'helper-text-color')
));
$bootstrap: map.merge(digest-schema($bootstrap-combo), (
helper-text-color: map.get(input-theme.$bootstrap, 'helper-text-color'),
disabled-text-color: map.get(input-theme.$bootstrap, 'disabled-text-color'),
error-secondary-color: map.get(input-theme.$bootstrap, 'error-secondary-color')
));
$fluent: map.merge(digest-schema($fluent-combo), (
helper-text-color: map.get(input-theme.$fluent, 'helper-text-color'),
disabled-text-color: map.get(input-theme.$fluent, 'disabled-text-color'),
error-secondary-color: map.get(input-theme.$fluent, 'error-secondary-color')
));
$indigo: map.merge(digest-schema($indigo-combo), (
helper-text-color: map.get(input-theme.$indigo, 'helper-text-color'),
disabled-text-color: map.get(input-theme.$indigo, 'disabled-text-color'),
error-secondary-color: map.get(input-theme.$indigo, 'error-secondary-color')
));
11 changes: 6 additions & 5 deletions src/components/combo/themes/shared/combo.bootstrap.scss
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
@use 'styles/utilities' as *;
@use '../light/themes' as *;
@use '../../../input/themes/light/themes' as input-theme;
@use '../../../dropdown/themes/light/themes' as dropdown-theme;
@use 'components/input/themes/light/themes' as input-theme;
@use 'components/dropdown/themes/light/themes' as dropdown-theme;

$theme: $bootstrap;
$input-theme: input-theme.$bootstrap;
Expand All @@ -14,6 +14,7 @@ $dropdown-theme: dropdown-theme.$bootstrap;

[part='helper-text'] {
margin-top: rem(4px);
color: var-get($theme, 'helper-text-color');
}

[part='list-wrapper'] {
Expand Down Expand Up @@ -93,7 +94,7 @@ $dropdown-theme: dropdown-theme.$bootstrap;

:host([invalid]) {
::slotted([slot='helper-text']) {
color: var-get($input-theme, 'error-secondary-color');
color: var-get($theme, 'error-secondary-color');
}
}

Expand All @@ -104,13 +105,13 @@ $dropdown-theme: dropdown-theme.$bootstrap;
igc-input::part(label),
igc-input::part(input)::placeholder,
::slotted([slot='helper-text']) {
color: var-get($input-theme, 'disabled-text-color');
color: var-get($theme, 'disabled-text-color');
}

[part~='clear-icon'] {
border-inline-end: rem(1px) solid var-get($input-theme, 'disabled-border-color');
background: inherit;
color: var-get($input-theme, 'disabled-text-color');
color: var-get($theme, 'disabled-text-color');

igc-icon {
color: inherit;
Expand Down
12 changes: 5 additions & 7 deletions src/components/combo/themes/shared/combo.fluent.scss
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
@use 'styles/utilities' as *;
@use '../light/themes' as *;
@use '../../../input/themes/light/themes' as input-theme;
@use '../../../dropdown/themes/light/themes' as dropdown-theme;
@use 'components/dropdown/themes/light/themes' as dropdown-theme;

$theme: $fluent;
$input-theme: input-theme.$fluent;
$dropdown-theme: dropdown-theme.$fluent;

:host {
Expand All @@ -17,7 +15,7 @@ $dropdown-theme: dropdown-theme.$fluent;
display: block;
padding: 0;
margin-top: rem(5px);
color: color(gray, 700);
color: var-get($theme, 'helper-text-color');
}
}

Expand Down Expand Up @@ -81,7 +79,7 @@ $dropdown-theme: dropdown-theme.$fluent;

:host([invalid]) {
::slotted([slot='helper-text']) {
color: var-get($input-theme, 'error-secondary-color');
color: var-get($theme, 'error-secondary-color');
}
}

Expand Down Expand Up @@ -109,12 +107,12 @@ $dropdown-theme: dropdown-theme.$fluent;
igc-input::part(label),
igc-input::part(input)::placeholder,
::slotted([slot='helper-text']) {
color: color(gray, 500);
color: var-get($theme, 'disabled-text-color');
}

[part~='clear-icon'] {
background: inherit;
color: var-get($input-theme, 'disabled-text-color');
color: var-get($theme, 'disabled-text-color');

igc-icon {
color: inherit;
Expand Down
12 changes: 6 additions & 6 deletions src/components/combo/themes/shared/combo.indigo.scss
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
@use 'styles/utilities' as *;
@use '../light/themes' as *;
@use '../../../input/themes/light/themes' as input-theme;
@use '../../../dropdown/themes/light/themes' as dropdown-theme;
@use 'components/input/themes/light/themes' as input-theme;
@use 'components/dropdown/themes/light/themes' as dropdown-theme;

$theme: $indigo;
$input-theme: input-theme.$indigo;
Expand All @@ -21,7 +21,7 @@ $dropdown-theme: dropdown-theme.$indigo;
}

::slotted([slot='helper-text']) {
color: var-get($input-theme, 'helper-text-color');
color: var-get($theme, 'helper-text-color');
}
}

Expand Down Expand Up @@ -101,7 +101,7 @@ $dropdown-theme: dropdown-theme.$indigo;

:host([invalid]) {
::slotted([slot='helper-text']) {
color: var-get($input-theme, 'error-secondary-color');
color: var-get($theme, 'error-secondary-color');
}
}

Expand All @@ -110,7 +110,7 @@ $dropdown-theme: dropdown-theme.$indigo;
::slotted([slot='prefix']),
::slotted([slot='suffix']),
::slotted([slot='helper-text']) {
color: var-get($input-theme, 'disabled-text-color');
color: var-get($theme, 'disabled-text-color');
}

igc-input::part(input)::selection {
Expand All @@ -119,7 +119,7 @@ $dropdown-theme: dropdown-theme.$indigo;

[part~='clear-icon'] {
background: inherit;
color: var-get($input-theme, 'disabled-text-color');
color: var-get($theme, 'disabled-text-color');

igc-icon {
color: inherit;
Expand Down
12 changes: 6 additions & 6 deletions src/components/combo/themes/shared/combo.material.scss
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
@use 'styles/utilities' as *;
@use '../light/themes' as *;
@use '../../../input/themes/light/themes' as input-theme;
@use '../../../dropdown/themes/light/themes' as dropdown-theme;
@use 'components/input/themes/light/themes' as input-theme;
@use 'components/dropdown/themes/light/themes' as dropdown-theme;

$theme: $material;
$input-theme: input-theme.$material;
Expand All @@ -19,7 +19,7 @@ $dropdown-theme: dropdown-theme.$material;
::slotted([slot='helper-text']) {
@include type-style('caption');

color: var-get($input-theme, 'helper-text-color');
color: var-get($theme, 'helper-text-color');
line-height: 1;
}

Expand Down Expand Up @@ -122,7 +122,7 @@ $dropdown-theme: dropdown-theme.$material;

:host([invalid]) {
::slotted([slot='helper-text']) {
color: var-get($input-theme, 'error-secondary-color');
color: var-get($theme, 'error-secondary-color');
}
}

Expand All @@ -133,12 +133,12 @@ $dropdown-theme: dropdown-theme.$material;
igc-input::part(label),
igc-input::part(input)::placeholder,
::slotted([slot='helper-text']) {
color: var-get($input-theme, 'disabled-text-color');
color: var-get($theme, 'disabled-text-color');
}

[part~='clear-icon'] {
background: inherit;
color: var-get($input-theme, 'disabled-text-color');
color: var-get($theme, 'disabled-text-color');

igc-icon {
color: inherit;
Expand Down
7 changes: 4 additions & 3 deletions src/components/input/themes/shared/input.material.scss
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
@use 'styles/utilities' as *;
@use '../light/themes' as *;
@use 'igniteui-theming/sass/animations/easings' as *;

$theme: $material;
$idle-border-width: rem(1px) !default;
Expand Down Expand Up @@ -74,7 +75,7 @@ input:placeholder-shown + [part='notch'] [part='label'],
transform 150ms cubic-bezier(.4, 0, .2, 1),
color 150ms cubic-bezier(.4, 0, .2, 1),
font-size 150ms cubic-bezier(.4, 0, .2, 1);
line-height: 1;
line-height: normal;
text-overflow: ellipsis;
overflow: hidden;
will-change: font-size, color, transform;
Expand Down Expand Up @@ -231,7 +232,7 @@ input:placeholder-shown + [part='notch'] [part='label'],

input:placeholder-shown + [part='notch'] [part='label'],
[part~='filled'] + [part='notch'] [part='label'] {
transform: translateY(-106%);
transform: translateY(-73%);
}
}

Expand Down Expand Up @@ -259,7 +260,7 @@ input:placeholder-shown + [part='notch'] [part='label'],
}

[part='notch'] [part='label'] {
transform: translateY(-106%);
transform: translateY(-73%);
}
}

Expand Down
25 changes: 21 additions & 4 deletions src/components/select/themes/dark/_themes.scss
Original file line number Diff line number Diff line change
@@ -1,8 +1,25 @@
@use 'sass:map';
@use 'styles/utilities' as *;
@use 'igniteui-theming/sass/themes/schemas/components/dark/select' as *;
@use 'components/input/themes/dark/themes' as input-theme;

$material: digest-schema($dark-select);
$indigo: digest-schema($dark-indigo-select);
$fluent: digest-schema($dark-fluent-select);
$bootstrap: digest-schema($dark-bootstrap-select);
$material: map.merge(digest-schema($dark-select), (
helper-text-color: map.get(input-theme.$material, 'helper-text-color'),
disabled-text-color: map.get(input-theme.$material, 'disabled-text-color'),
error-secondary-color: map.get(input-theme.$material, 'helper-text-color')
));
$bootstrap: map.merge(digest-schema($dark-bootstrap-select), (
helper-text-color: map.get(input-theme.$bootstrap, 'helper-text-color'),
disabled-text-color: map.get(input-theme.$bootstrap, 'disabled-text-color'),
error-secondary-color: map.get(input-theme.$bootstrap, 'error-secondary-color')
));
$fluent: map.merge(digest-schema($dark-fluent-select), (
helper-text-color: map.get(input-theme.$fluent, 'helper-text-color'),
disabled-text-color: map.get(input-theme.$fluent, 'disabled-text-color'),
error-secondary-color: map.get(input-theme.$fluent, 'error-secondary-color')
));
$indigo: map.merge(digest-schema($dark-indigo-select), (
helper-text-color: map.get(input-theme.$indigo, 'helper-text-color'),
disabled-text-color: map.get(input-theme.$indigo, 'disabled-text-color'),
error-secondary-color: map.get(input-theme.$indigo, 'error-secondary-color')
));
2 changes: 1 addition & 1 deletion src/components/select/themes/dark/select.bootstrap.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
@use 'styles/utilities' as *;
@use 'themes' as *;
@use '../../../dropdown/themes/dark/themes' as dropdown-theme;
@use 'components/dropdown/themes/dark/themes' as dropdown-theme;

$dropdown-theme: dropdown-theme.$bootstrap;
$theme: $bootstrap;
Expand Down
2 changes: 1 addition & 1 deletion src/components/select/themes/dark/select.fluent.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
@use 'styles/utilities' as *;
@use 'themes' as *;
@use '../../../dropdown/themes/dark/themes' as dropdown-theme;
@use 'components/dropdown/themes/dark/themes' as dropdown-theme;

$dropdown-theme: dropdown-theme.$fluent;
$theme: $fluent;
Expand Down
2 changes: 1 addition & 1 deletion src/components/select/themes/dark/select.indigo.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
@use 'styles/utilities' as *;
@use 'themes' as *;
@use '../../../dropdown/themes/dark/themes' as dropdown-theme;
@use 'components/dropdown/themes/dark/themes' as dropdown-theme;

$dropdown-theme: dropdown-theme.$indigo;
$theme: $indigo;
Expand Down
2 changes: 1 addition & 1 deletion src/components/select/themes/dark/select.material.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
@use 'styles/utilities' as *;
@use 'themes' as *;
@use '../../../dropdown/themes/dark/themes' as dropdown-theme;
@use 'components/dropdown/themes/dark/themes' as dropdown-theme;

$dropdown-theme: dropdown-theme.$material;
$theme: $material;
Expand Down
25 changes: 21 additions & 4 deletions src/components/select/themes/light/_themes.scss
Original file line number Diff line number Diff line change
@@ -1,8 +1,25 @@
@use 'sass:map';
@use 'styles/utilities' as *;
@use 'igniteui-theming/sass/themes/schemas/components/light/select' as *;
@use 'components/input/themes/light/themes' as input-theme;

$material: digest-schema($light-select);
$bootstrap: digest-schema($bootstrap-select);
$fluent: digest-schema($fluent-select);
$indigo: digest-schema($indigo-select);
$material: map.merge(digest-schema($light-select), (
helper-text-color: map.get(input-theme.$material, 'helper-text-color'),
disabled-text-color: map.get(input-theme.$material, 'disabled-text-color'),
error-secondary-color: map.get(input-theme.$material, 'helper-text-color')
));
$bootstrap: map.merge(digest-schema($bootstrap-select), (
helper-text-color: map.get(input-theme.$bootstrap, 'helper-text-color'),
disabled-text-color: map.get(input-theme.$bootstrap, 'disabled-text-color'),
error-secondary-color: map.get(input-theme.$bootstrap, 'error-secondary-color')
));
$fluent: map.merge(digest-schema($fluent-select), (
helper-text-color: map.get(input-theme.$fluent, 'helper-text-color'),
disabled-text-color: map.get(input-theme.$fluent, 'disabled-text-color'),
error-secondary-color: map.get(input-theme.$fluent, 'error-secondary-color')
));
$indigo: map.merge(digest-schema($indigo-select), (
helper-text-color: map.get(input-theme.$indigo, 'helper-text-color'),
disabled-text-color: map.get(input-theme.$indigo, 'disabled-text-color'),
error-secondary-color: map.get(input-theme.$indigo, 'error-secondary-color')
));
5 changes: 1 addition & 4 deletions src/components/select/themes/light/select.bootstrap.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
@use 'styles/utilities' as *;
@use 'themes' as *;
@use '../../../dropdown/themes/light/themes' as dropdown-theme;
@use 'components/dropdown/themes/light/themes' as dropdown-theme;

$dropdown-theme: dropdown-theme.$bootstrap;
$theme: $bootstrap;
Expand All @@ -13,6 +13,3 @@ $theme: $bootstrap;
--dd-border-radius: #{var-get($dropdown-theme, 'border-radius')};
--dd-border-color: #{var-get($dropdown-theme, 'border-color')};
}



2 changes: 1 addition & 1 deletion src/components/select/themes/light/select.fluent.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
@use 'styles/utilities' as *;
@use 'themes' as *;
@use '../../../dropdown/themes/light/themes' as dropdown-theme;
@use 'components/dropdown/themes/light/themes' as dropdown-theme;

$dropdown-theme: dropdown-theme.$fluent;
$theme: $fluent;
Expand Down
2 changes: 1 addition & 1 deletion src/components/select/themes/light/select.indigo.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
@use 'styles/utilities' as *;
@use 'themes' as *;
@use '../../../dropdown/themes/light/themes' as dropdown-theme;
@use 'components/dropdown/themes/light/themes' as dropdown-theme;

$dropdown-theme: dropdown-theme.$indigo;
$theme: $indigo;
Expand Down
Loading
Loading