File tree Expand file tree Collapse file tree 2 files changed +7
-8
lines changed
Expand file tree Collapse file tree 2 files changed +7
-8
lines changed Original file line number Diff line number Diff line change 1- import * as React from "react" ;
2- import { VisuallyHidden } from "ariakit" ;
3- import { useForkRef , useWrapElement } from "ariakit-utils" ;
1+ import { useForkRef } from "ariakit-utils" ;
42import {
53 createComponent ,
64 createElement ,
@@ -16,10 +14,6 @@ export const useSliderInput = createHook<SliderInputOptions>(
1614 props = { ...props , ref : useForkRef ( state . inputRef , props . ref ) } ;
1715 props = mergeProps ( state . inputProps , props ) ;
1816
19- props = useWrapElement ( props , element => (
20- < VisuallyHidden > { element } </ VisuallyHidden >
21- ) ) ;
22-
2317 return props ;
2418 } ,
2519) ;
Original file line number Diff line number Diff line change 11import * as React from "react" ;
2+ import { VisuallyHidden } from "ariakit" ;
23import {
34 createComponent ,
45 createElement ,
@@ -12,7 +13,11 @@ import { SliderThumbState } from "./slider-thumb-state";
1213
1314export const useSliderThumb = createHook < SliderThumbOptions > (
1415 ( { state, ...props } ) => {
15- const children = < SliderInput state = { state } /> ;
16+ const children = (
17+ < VisuallyHidden >
18+ < SliderInput state = { state } />
19+ </ VisuallyHidden >
20+ ) ;
1621
1722 props = { children, ...props } ;
1823 props = mergeProps ( state . thumbProps , props ) ;
You can’t perform that action at this time.
0 commit comments