new HuePicker(options)
Parameters:| Name | Type | Description |
|---|
options | object | Properties| Name | Type | Description |
|---|
onSelect | function | called with hex color on each hue change | onCancel | function | called when picker is dismissed without selection |
|
Classes
- HuePicker
Methods
open(anchorEl, initialHue)
Renders and positions the picker popover anchored below `anchorEl`.
Parameters:| Name | Type | Default | Description |
|---|
anchorEl | HTMLElement | | element to anchor below (e.g. a color swatch) |
initialHue | number | 0 | hue (0–360) to pre-position the cursor at |
remove()
Removes the picker from the DOM and cleans up all listeners.