UNPKG

@wordpress/components

Version:
28 lines 1.01 kB
/// <reference types="react" /> import type { CustomGradientPickerProps } from './types'; /** * CustomGradientPicker is a React component that renders a UI for specifying * linear or radial gradients. Radial gradients are displayed in the picker as * a slice of the gradient from the center to the outside. * * ```jsx * import { CustomGradientPicker } from '@wordpress/components'; * import { useState } from '@wordpress/element'; * * const MyCustomGradientPicker = () => { * const [ gradient, setGradient ] = useState(); * * return ( * <CustomGradientPicker * value={ gradient } * onChange={ setGradient } * /> * ); * }; * ``` */ export declare function CustomGradientPicker({ /** Start opting into the new margin-free styles that will become the default in a future version. */ __nextHasNoMargin, value, onChange, __experimentalIsRenderedInSidebar, }: CustomGradientPickerProps): JSX.Element; export default CustomGradientPicker; //# sourceMappingURL=index.d.ts.map