MCPcopy Create free account
hub / github.com/adobe/react-spectrum / onChange

Function onChange

packages/react-stately/src/color/useColorSliderState.ts:95–97  ·  view source on GitHub ↗
(v)

Source from the content-addressed store, hash-verified

93 value: color.getChannelValue(channel),
94 defaultValue: defaultColor.getChannelValue(channel),
95 onChange(v) {
96 setColor(color.withChannelValue(channel, v));
97 },
98 onChangeEnd(v) {
99 // onChange will have already been called with the right value, this is just to trigger onChangeEnd
100 if (props.onChangeEnd) {

Callers 2

useControlledStateFunction · 0.50
createOnChangeFunction · 0.50

Calls 2

withChannelValueMethod · 0.80
setColorFunction · 0.70

Tested by

no test coverage detected