@appbuckets/react-ui
Version:
Just Another React UI Framework
18 lines (17 loc) • 548 B
TypeScript
import * as React from 'react';
import type { ColorPickerChangeHandler } from '../ColorPicker';
export declare type UseColorPickerValueReturn = [
string,
ColorPickerChangeHandler,
React.Dispatch<React.SetStateAction<string>>
];
/**
* Use this hook to get automatically the color picker value
* and the handler function to attach to color picker.
* Additionally function to force change will be returned
*
* @param initialValue
*/
export declare function useColorPickerValue(
initialValue?: string | null
): UseColorPickerValueReturn;