Skip to content

Commit 8abdff8

Browse files
committed
fix(slider): fix tick values alignment
fix #180
1 parent a9fa6e9 commit 8abdff8

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

src/Slider/Slider.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ const Mark = styled.div`
221221
position: absolute;
222222
bottom: 0;
223223
left: 0;
224-
224+
line-height: 1;
225225
font-size: 0.875rem;
226226
227227
${({ vertical }) =>

src/Slider/Slider.stories.js

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -90,9 +90,14 @@ export const Default = () => (
9090
size='300px'
9191
min={0}
9292
max={6}
93-
step={1.5}
93+
step={1}
9494
defaultValue={0}
95-
marks
95+
marks={[
96+
{ value: 0, label: '0°C' },
97+
{ value: 2, label: '2°C' },
98+
{ value: 4, label: '4°C' },
99+
{ value: 6, label: '6°C' }
100+
]}
96101
orientation='vertical'
97102
/>
98103
</div>

0 commit comments

Comments
 (0)