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] Remove unnecessary data-focusvisible attribute #36091

Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ const Thumb = React.forwardRef(function Thumb(
props: SliderUnstyledThumbSlotProps,
ref: React.ForwardedRef<HTMLDivElement>,
) {
const { 'data-index': index, 'data-focusvisible': focusVisible, ownerState, ...other } = props;
const { 'data-index': index, ownerState, ...other } = props;
return <div data-track={ownerState.track} {...other} ref={ref} />;
});

Expand Down
1 change: 0 additions & 1 deletion packages/mui-base/src/SliderUnstyled/SliderUnstyled.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -273,7 +273,6 @@ const SliderUnstyled = React.forwardRef(function SliderUnstyled<
<Thumb
key={index}
data-index={index}
data-focusvisible={focusedThumbIndex === index}
{...thumbProps}
className={clsx(classes.thumb, thumbProps.className, {
[classes.active]: active === index,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -278,7 +278,6 @@ export type SliderUnstyledRailSlotProps = {

export type SliderUnstyledThumbSlotProps = UseSliderThumbSlotProps & {
'data-index': number;
'data-focusvisible': boolean;
children: React.ReactNode;
className?: string;
ownerState: SliderUnstyledOwnerState;
Expand Down
1 change: 0 additions & 1 deletion packages/mui-material/src/Slider/Slider.js
Original file line number Diff line number Diff line change
Expand Up @@ -757,7 +757,6 @@ const Slider = React.forwardRef(function Slider(inputProps, ref) {
>
<ThumbSlot
data-index={index}
data-focusvisible={focusedThumbIndex === index}
{...thumbProps}
className={clsx(classes.thumb, thumbProps.className, {
[classes.active]: active === index,
Expand Down