Skip to content

Commit f5f7667

Browse files
- improve tokens usage;
1 parent 9547a9e commit f5f7667

File tree

3 files changed

+31
-7
lines changed

3 files changed

+31
-7
lines changed

core/src/components/range/range.common.scss

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -112,8 +112,6 @@
112112
width: 100%;
113113
height: var(--bar-height);
114114

115-
background: var(--bar-background);
116-
117115
pointer-events: none;
118116
}
119117

core/src/components/range/range.ionic.scss

Lines changed: 26 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,15 @@
66

77
:host {
88
--knob-border-radius: #{globals.$ion-border-radius-full};
9-
--knob-background: #{globals.$ion-primitives-base-white};
9+
--knob-background: #{globals.$ion-bg-input-default};
1010
--knob-box-shadow: none;
1111
--knob-size: #{globals.$ion-scale-600};
12-
--knob-handle-size: #{globals.$ion-scale-1000};
12+
--knob-handle-size: #{globals.$ion-scale-1100};
1313
--bar-height: #{globals.$ion-scale-200};
1414
--bar-background: #{globals.$ion-primitives-neutral-100};
1515
--bar-background-active: #{globals.ion-color(primary, base)};
1616
--bar-border-radius: #{globals.$ion-border-radius-400};
17-
--height: #{globals.$ion-scale-1000};
17+
--height: #{globals.$ion-scale-1100};
1818

1919
@include globals.typography(globals.$ion-body-md-regular);
2020

@@ -118,12 +118,14 @@
118118
font-size: globals.$ion-font-size-300;
119119

120120
text-align: center;
121+
122+
color: globals.$ion-text-default;
121123
}
122124

123125
.range-knob {
124126
border-width: globals.$ion-border-size-025;
125127
border-style: globals.$ion-border-style-solid;
126-
border-color: globals.ion-color(primary, base);
128+
border-color: globals.$ion-border-primary;
127129
box-sizing: border-box;
128130
}
129131

@@ -134,7 +136,14 @@
134136
// icons need to receive the same opacity.
135137

136138
:host(.range-disabled) {
137-
opacity: 0.3;
139+
.range-bar {
140+
background: globals.$ion-bg-neutral-subtle-default;
141+
}
142+
143+
.range-knob {
144+
background: globals.$ion-bg-input-disabled;
145+
border-color: globals.$ion-border-input-default;
146+
}
138147
}
139148

140149
// Range Label Placement - Start
@@ -207,3 +216,15 @@
207216
.range-knob-handle.ion-focused .range-knob {
208217
@include globals.focused-state();
209218
}
219+
220+
.range-bar {
221+
background: globals.$ion-bg-neutral-subtle-default;
222+
}
223+
224+
225+
// Range Pressed
226+
// ----------------------------------------------------------------
227+
.range-knob-handle.ion-activated .range-knob,
228+
.range-knob-handle.range-knob-pressed .range-knob{
229+
background: globals.$ion-bg-input-press;
230+
}

core/src/components/range/range.native.scss

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,3 +81,8 @@
8181
:host(.in-item.range-label-placement-stacked) .native-wrapper {
8282
@include margin(null, null, $range-item-label-margin-bottom, null);
8383
}
84+
85+
86+
.range-bar {
87+
background: var(--bar-background);
88+
}

0 commit comments

Comments
 (0)