Skip to content

Commit bda0296

Browse files
committed
feat(progress-bar): use ionColor
1 parent 85829fe commit bda0296

2 files changed

Lines changed: 9 additions & 23 deletions

File tree

core/src/themes/ionic/default.tokens.ts

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { currentColor, mix, dynamicFont } from '../../utils/theme';
1+
import { currentColor, ionColor, mix, dynamicFont } from '../../utils/theme';
22
import { defaultTheme as baseDefaultTheme } from '../base/default.tokens';
33
import { colors as baseColors } from '../base/shared.tokens';
44
import type { DefaultTheme } from '../themes.interfaces';
@@ -473,9 +473,7 @@ export const defaultTheme: DefaultTheme = {
473473
indeterminate: {
474474
progress: {
475475
default: {
476-
// TODO: Replace with ionColor() once that utility is merged
477-
// ion-color(primary, base) -> ionColor('primary', 'base')
478-
background: 'var(--ion-color-primary-bold)',
476+
background: ionColor('primary', 'base'),
479477
},
480478

481479
semantic: {
@@ -497,9 +495,7 @@ export const defaultTheme: DefaultTheme = {
497495
determinate: {
498496
progress: {
499497
default: {
500-
// TODO: Replace with ionColor() once that utility is merged
501-
// ion-color(primary, base) -> ionColor('primary', 'base')
502-
background: 'var(--ion-color-primary-bold)',
498+
background: ionColor('primary', 'base'),
503499
},
504500

505501
semantic: {

core/src/themes/ios/default.tokens.ts

Lines changed: 6 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { rgba, currentColor, clamp, mix, dynamicFont } from '../../utils/theme';
1+
import { rgba, currentColor, ionColor, clamp, mix, dynamicFont } from '../../utils/theme';
22
import { defaultTheme as baseDefaultTheme } from '../base/default.tokens';
33
import { colors as baseColors } from '../base/shared.tokens';
44
import type { DefaultTheme } from '../themes.interfaces';
@@ -485,9 +485,7 @@ export const defaultTheme: DefaultTheme = {
485485
indeterminate: {
486486
progress: {
487487
default: {
488-
// TODO: Replace with ionColor() once that utility is merged
489-
// ion-color(primary, base) -> ionColor('primary', 'base')
490-
background: 'var(--ion-color-primary-bold)',
488+
background: ionColor('primary', 'base'),
491489
},
492490

493491
semantic: {
@@ -500,9 +498,7 @@ export const defaultTheme: DefaultTheme = {
500498
buffer: {
501499
bar: {
502500
default: {
503-
// TODO: Replace rgba() with ionColor() once that utility is merged
504-
// ion-color(primary, base, 0.3) -> ionColor('primary', 'base', { alpha: 0.3 }),
505-
background: rgba('var(--ion-color-primary-bold-rgb)', 0.3),
501+
background: ionColor('primary', 'base', { alpha: 0.3 }),
506502
},
507503

508504
solid: {
@@ -517,9 +513,7 @@ export const defaultTheme: DefaultTheme = {
517513
determinate: {
518514
progress: {
519515
default: {
520-
// TODO: Replace with ionColor() once that utility is merged
521-
// ion-color(primary, base) -> ionColor('primary', 'base')
522-
background: 'var(--ion-color-primary-bold)',
516+
background: ionColor('primary', 'base'),
523517
},
524518

525519
semantic: {
@@ -532,9 +526,7 @@ export const defaultTheme: DefaultTheme = {
532526
buffer: {
533527
bar: {
534528
default: {
535-
// TODO: Replace rgba() with ionColor() once that utility is merged
536-
// ion-color(primary, base, 0.3) -> ionColor('primary', 'base', { alpha: 0.3 }),
537-
background: rgba('var(--ion-color-primary-bold-rgb)', 0.3),
529+
background: ionColor('primary', 'base', { alpha: 0.3 }),
538530
},
539531

540532
solid: {
@@ -546,9 +538,7 @@ export const defaultTheme: DefaultTheme = {
546538

547539
circles: {
548540
default: {
549-
// TODO: Replace rgba() with ionColor() once that utility is merged
550-
// ion-color(primary, base, 0.3) -> ionColor('primary', 'base', { alpha: 0.3 })
551-
background: rgba('var(--ion-color-primary-bold-rgb)', 0.3),
541+
background: ionColor('primary', 'base', { alpha: 0.3 }),
552542
},
553543

554544
semantic: {

0 commit comments

Comments
 (0)