mirror of
https://github.com/zoriya/v10.git
synced 2026-08-16 02:45:09 +00:00
refactor(core): replace document listeners with pointer capture in slider (#762)
This commit is contained in:
@@ -50,6 +50,7 @@ export const SliderRoot = forwardRef(function SliderRoot(
|
||||
rootRef,
|
||||
thumbRef: sliderThumbRef,
|
||||
rootProps,
|
||||
rootStyle,
|
||||
thumbProps,
|
||||
} = useSlider({
|
||||
computeState: (input) => {
|
||||
@@ -89,7 +90,7 @@ export const SliderRoot = forwardRef(function SliderRoot(
|
||||
state,
|
||||
stateAttrMap: SliderDataAttrs,
|
||||
ref: [forwardedRef, rootRef],
|
||||
props: [{ style: cssVars }, rootProps, elementProps],
|
||||
props: [{ style: { ...cssVars, ...rootStyle } }, rootProps, elementProps],
|
||||
}
|
||||
)}
|
||||
</SliderProvider>
|
||||
|
||||
Reference in New Issue
Block a user