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

Slider refactor #20657

Merged
merged 67 commits into from
Jan 5, 2022
Merged
Show file tree
Hide file tree
Changes from 44 commits
Commits
Show all changes
67 commits
Select commit Hold shift + click to select a range
30659ae
init refactor of slider
micahgodbolt Nov 9, 2021
8ad4cfd
start bringing marks back in
micahgodbolt Nov 12, 2021
e2ae6cd
stories for slider
micahgodbolt Nov 18, 2021
0c9ad2a
story cleanup
micahgodbolt Nov 18, 2021
50c6f84
cleanup
micahgodbolt Nov 18, 2021
40d8a97
update spec
micahgodbolt Nov 18, 2021
6dc8efc
Change files
micahgodbolt Nov 18, 2021
d312352
update api
micahgodbolt Nov 18, 2021
d4236a7
Apply suggestions from code review
micahgodbolt Nov 19, 2021
07e60a1
move stateful styles into css variables
micahgodbolt Nov 19, 2021
5171836
merge conflicts
micahgodbolt Nov 29, 2021
47e7079
add slider to react-components main export
micahgodbolt Nov 29, 2021
ae6f7ed
cleanup and add ticks
micahgodbolt Nov 30, 2021
ab2b781
change var name
micahgodbolt Nov 30, 2021
663fe05
cleanup snaps
micahgodbolt Nov 30, 2021
66281f2
remove ranged fixture
micahgodbolt Nov 30, 2021
50509a4
Merge branch 'master' into slider-refactor
micahgodbolt Dec 1, 2021
964b130
fix package version
micahgodbolt Dec 1, 2021
4d65009
fix prettier
micahgodbolt Dec 1, 2021
5f2b8de
add primary slot
micahgodbolt Dec 2, 2021
b93be27
api update
micahgodbolt Dec 2, 2021
ab02143
react components api
micahgodbolt Dec 2, 2021
cb4bbd4
Merge branch 'master' into slider-refactor
micahgodbolt Dec 3, 2021
48ab826
revert react components to remove slider
micahgodbolt Dec 7, 2021
37ba000
merge conflicts
micahgodbolt Dec 7, 2021
e4c542b
merge conflicts
micahgodbolt Dec 7, 2021
334e632
update api md
micahgodbolt Dec 7, 2021
efec9c4
Delete @fluentui-react-components-2b36a74e-2147-4df0-a4f2-ab6c12c5603…
micahgodbolt Dec 7, 2021
b2a4ced
cleanup testing
micahgodbolt Dec 7, 2021
461fb9e
Merge branch 'slider-refactor' of https://github.com/micahgodbolt/flu…
micahgodbolt Dec 7, 2021
ac453d3
slider types
micahgodbolt Dec 7, 2021
30ce476
simplify onChange prop
micahgodbolt Dec 8, 2021
2d620ec
update api
micahgodbolt Dec 8, 2021
49003d2
move back to onChange with data
micahgodbolt Dec 8, 2021
1c9db3c
remove unused stuff
micahgodbolt Dec 8, 2021
f2a5f74
Update packages/react-slider/src/components/Slider/Slider.types.ts
micahgodbolt Dec 10, 2021
1295f39
Update packages/react-slider/src/components/Slider/Slider.types.ts
micahgodbolt Dec 10, 2021
9c4b7d6
refactor css variables
micahgodbolt Dec 10, 2021
a20674a
Merge branch 'slider-refactor' of https://github.com/micahgodbolt/flu…
micahgodbolt Dec 10, 2021
e74747e
api update fix build
micahgodbolt Dec 10, 2021
eb37683
fix RTL issues
micahgodbolt Dec 10, 2021
91989cc
remove utils, cleanup tests, update ids
micahgodbolt Dec 13, 2021
40e3e85
remove unnecessary code
micahgodbolt Dec 13, 2021
bcdc3b8
new snaps
micahgodbolt Dec 13, 2021
8c30db3
Merge branch 'master' into slider-refactor
micahgodbolt Dec 14, 2021
95a2ef7
fixed thumb alignment, moved input to bottom of DOM stack
micahgodbolt Dec 14, 2021
f9ab541
Update packages/react-slider/src/components/Slider/Slider.test.tsx
micahgodbolt Dec 14, 2021
dbd71a4
Update packages/react-slider/src/components/Slider/Slider.types.ts
micahgodbolt Dec 14, 2021
8bc8246
updated stories with descriptions, fixed stateful bug
micahgodbolt Dec 14, 2021
6143326
updated tests
micahgodbolt Dec 14, 2021
b4cab2c
Merge branch 'slider-refactor' of https://github.com/micahgodbolt/flu…
micahgodbolt Dec 14, 2021
ea4a6c9
fixed pretty
micahgodbolt Dec 14, 2021
f504078
Merge branch 'master' into slider-refactor
micahgodbolt Dec 14, 2021
7de4704
api
micahgodbolt Dec 15, 2021
060dbb5
Merge branch 'master' into slider-refactor
micahgodbolt Dec 16, 2021
22d35ae
remove old snaps
micahgodbolt Dec 16, 2021
dfc2d9e
snaps
micahgodbolt Dec 16, 2021
9ba550a
update snaps
micahgodbolt Dec 16, 2021
6134a50
Merge branch 'master' into slider-refactor
micahgodbolt Dec 21, 2021
96895c5
test clean up
micahgodbolt Dec 21, 2021
3ee76d2
remove unused methods
micahgodbolt Dec 21, 2021
9a9b6cd
Merge branch 'master' into slider-refactor
micahgodbolt Jan 3, 2022
45c399a
change private to true
micahgodbolt Jan 3, 2022
67ddf8e
add outline for HC
micahgodbolt Jan 4, 2022
56292cf
Merge branch 'master' into slider-refactor
micahgodbolt Jan 4, 2022
4be0680
cleanup linting
micahgodbolt Jan 4, 2022
7c824ac
snaps
micahgodbolt Jan 4, 2022
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
185 changes: 0 additions & 185 deletions apps/vr-tests/src/stories/RangedSliderConverged.stories.tsx

This file was deleted.

190 changes: 1 addition & 189 deletions apps/vr-tests/src/stories/SliderConverged.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,6 @@ import Screener, { Steps } from 'screener-storybook/src/screener';
import { storiesOf } from '@storybook/react';
import { Slider } from '@fluentui/react-slider';

const LabelComponent = () => <div style={{ width: '30px', height: '30px', background: 'green' }} />;

const MarkComponent = () => (
<div
style={{
width: '10px',
height: '10px',
background: 'red',
}}
/>
);

storiesOf('Slider Converged', module)
.addDecorator(story => (
<Screener
Expand Down Expand Up @@ -56,180 +44,4 @@ storiesOf('Slider Converged', module)
.addStory('Origin (max)', () => <Slider className="test-class" max={10} origin={10} />)
.addStory('Origin Vertical (max)', () => (
<Slider className="test-class" min={10} vertical origin={10} />
))
.addStory('Marks', () => <Slider className="test-class" max={10} defaultValue={3} marks />, {
includeRtl: true,
includeHighContrast: true,
includeDarkMode: true,
})
.addStory(
'Marks Vertical',
() => <Slider className="test-class" vertical max={10} defaultValue={3} marks />,
{
includeRtl: true,
},
)
.addStory(
'Marks Custom Value',
() => <Slider className="test-class" max={10} defaultValue={3} marks={[0, 1, 5, 8, 10]} />,
{
includeRtl: true,
},
)
.addStory(
'Marks Custom Value Vertical',
() => (
<Slider className="test-class" vertical max={10} defaultValue={3} marks={[0, 1, 5, 8, 10]} />
),
{
includeRtl: true,
},
)
.addStory(
'Marks Label Value',
() => (
<Slider
className="test-class"
max={10}
defaultValue={3}
marks={[
0,
{ value: 1, label: 'hello world' },
{ value: 2, label: 'hello' },
8,
{ value: 10, label: '10' },
]}
/>
),
{
includeRtl: true,
},
)
.addStory(
'Marks Label Vertical',
() => (
<Slider
className="test-class"
vertical
max={10}
defaultValue={3}
marks={[
0,
{ value: 1, label: 'hello world' },
{ value: 2, label: 'hello' },
8,
{ value: 10, label: '10' },
]}
/>
),
{
includeRtl: true,
},
)
.addStory('Marks Label Disabled', () => (
<Slider
className="test-class"
disabled
max={10}
defaultValue={7}
marks={[
0,
{ value: 1, label: 'hello world' },
{ value: 2, label: 'hello' },
8,
{ value: 10, label: '10' },
]}
/>
))
.addStory(
'Marks Custom Label Value',
() => (
<Slider
className="test-class"
max={10}
defaultValue={6}
marks={[
1,
{
value: 3,
label: <LabelComponent />,
},
{ value: 4, label: 'world' },
8,
]}
/>
),
{
includeRtl: true,
},
)
.addStory(
'Marks Custom Label Vertical',
() => (
<Slider
className="test-class"
vertical
max={10}
defaultValue={6}
marks={[
1,
{
value: 3,
label: <LabelComponent />,
},
{ value: 4, label: 'world' },
8,
]}
/>
),
{
includeRtl: true,
},
)
.addStory(
'Custom Marks',
() => (
<Slider
className="test-class"
max={10}
defaultValue={6}
marks={[
1,
{
value: 3,
label: <LabelComponent />,
mark: <MarkComponent />,
},
{ value: 4, label: 'world' },
8,
]}
/>
),
{
includeRtl: true,
},
)
.addStory(
'Custom Marks Vertical',
() => (
<Slider
className="test-class"
vertical
max={10}
defaultValue={6}
marks={[
1,
{
value: 3,
label: <LabelComponent />,
mark: <MarkComponent />,
},
{ value: 4, label: 'world' },
8,
]}
/>
),
{
includeRtl: true,
},
);
));
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"type": "prerelease",
"comment": "Refactor slider component: removed marks support, RangedSlider is removed",
"packageName": "@fluentui/react-slider",
"email": "[email protected]",
"dependentChangeType": "patch"
}
Loading