@zag-js/color-picker 1.18.3 → 1.18.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +36 -36
- package/dist/index.d.ts +36 -36
- package/package.json +9 -9
package/dist/index.d.mts
CHANGED
|
@@ -49,9 +49,9 @@ type ElementIds = Partial<{
|
|
|
49
49
|
positioner: string;
|
|
50
50
|
formatSelect: string;
|
|
51
51
|
areaThumb: string;
|
|
52
|
-
channelInput(id: string)
|
|
53
|
-
channelSliderTrack(id: ColorChannel)
|
|
54
|
-
channelSliderThumb(id: ColorChannel)
|
|
52
|
+
channelInput: (id: string) => string;
|
|
53
|
+
channelSliderTrack: (id: ColorChannel) => string;
|
|
54
|
+
channelSliderThumb: (id: ColorChannel) => string;
|
|
55
55
|
}>;
|
|
56
56
|
interface ColorPickerProps extends CommonProperties, DirectionProperty, InteractOutsideHandlers {
|
|
57
57
|
/**
|
|
@@ -243,19 +243,19 @@ interface ColorPickerApi<T extends PropTypes = PropTypes> {
|
|
|
243
243
|
/**
|
|
244
244
|
* Function to set the color value
|
|
245
245
|
*/
|
|
246
|
-
setValue(value: string | Color)
|
|
246
|
+
setValue: (value: string | Color) => void;
|
|
247
247
|
/**
|
|
248
248
|
* Function to set the color value
|
|
249
249
|
*/
|
|
250
|
-
getChannelValue(channel: ColorChannel)
|
|
250
|
+
getChannelValue: (channel: ColorChannel) => string;
|
|
251
251
|
/**
|
|
252
252
|
* Function to get the formatted and localized value of a specific channel
|
|
253
253
|
*/
|
|
254
|
-
getChannelValueText(channel: ColorChannel, locale: string)
|
|
254
|
+
getChannelValueText: (channel: ColorChannel, locale: string) => string;
|
|
255
255
|
/**
|
|
256
256
|
* Function to set the color value of a specific channel
|
|
257
257
|
*/
|
|
258
|
-
setChannelValue(channel: ColorChannel, value: number)
|
|
258
|
+
setChannelValue: (channel: ColorChannel, value: number) => void;
|
|
259
259
|
/**
|
|
260
260
|
* The current color format
|
|
261
261
|
*/
|
|
@@ -263,7 +263,7 @@ interface ColorPickerApi<T extends PropTypes = PropTypes> {
|
|
|
263
263
|
/**
|
|
264
264
|
* Function to set the color format
|
|
265
265
|
*/
|
|
266
|
-
setFormat(format: ColorFormat)
|
|
266
|
+
setFormat: (format: ColorFormat) => void;
|
|
267
267
|
/**
|
|
268
268
|
* The alpha value of the color
|
|
269
269
|
*/
|
|
@@ -271,37 +271,37 @@ interface ColorPickerApi<T extends PropTypes = PropTypes> {
|
|
|
271
271
|
/**
|
|
272
272
|
* Function to set the color alpha
|
|
273
273
|
*/
|
|
274
|
-
setAlpha(value: number)
|
|
274
|
+
setAlpha: (value: number) => void;
|
|
275
275
|
/**
|
|
276
276
|
* Function to open or close the color picker
|
|
277
277
|
*/
|
|
278
|
-
setOpen(open: boolean)
|
|
279
|
-
getRootProps()
|
|
280
|
-
getLabelProps()
|
|
281
|
-
getControlProps()
|
|
282
|
-
getTriggerProps()
|
|
283
|
-
getPositionerProps()
|
|
284
|
-
getContentProps()
|
|
285
|
-
getHiddenInputProps()
|
|
286
|
-
getValueTextProps()
|
|
287
|
-
getAreaProps(props?: AreaProps)
|
|
288
|
-
getAreaBackgroundProps(props?: AreaProps)
|
|
289
|
-
getAreaThumbProps(props?: AreaProps)
|
|
290
|
-
getChannelInputProps(props: ChannelInputProps)
|
|
291
|
-
getChannelSliderProps(props: ChannelSliderProps)
|
|
292
|
-
getChannelSliderTrackProps(props: ChannelSliderProps)
|
|
293
|
-
getChannelSliderThumbProps(props: ChannelSliderProps)
|
|
294
|
-
getChannelSliderLabelProps(props: ChannelProps)
|
|
295
|
-
getChannelSliderValueTextProps(props: ChannelProps)
|
|
296
|
-
getTransparencyGridProps(props?: TransparencyGridProps)
|
|
297
|
-
getEyeDropperTriggerProps()
|
|
298
|
-
getSwatchGroupProps()
|
|
299
|
-
getSwatchTriggerProps(props: SwatchTriggerProps)
|
|
300
|
-
getSwatchTriggerState(props: SwatchTriggerProps)
|
|
301
|
-
getSwatchProps(props: SwatchProps)
|
|
302
|
-
getSwatchIndicatorProps(props: SwatchProps)
|
|
303
|
-
getFormatSelectProps()
|
|
304
|
-
getFormatTriggerProps()
|
|
278
|
+
setOpen: (open: boolean) => void;
|
|
279
|
+
getRootProps: () => T["element"];
|
|
280
|
+
getLabelProps: () => T["element"];
|
|
281
|
+
getControlProps: () => T["element"];
|
|
282
|
+
getTriggerProps: () => T["button"];
|
|
283
|
+
getPositionerProps: () => T["element"];
|
|
284
|
+
getContentProps: () => T["element"];
|
|
285
|
+
getHiddenInputProps: () => T["input"];
|
|
286
|
+
getValueTextProps: () => T["element"];
|
|
287
|
+
getAreaProps: (props?: AreaProps) => T["element"];
|
|
288
|
+
getAreaBackgroundProps: (props?: AreaProps) => T["element"];
|
|
289
|
+
getAreaThumbProps: (props?: AreaProps) => T["element"];
|
|
290
|
+
getChannelInputProps: (props: ChannelInputProps) => T["input"];
|
|
291
|
+
getChannelSliderProps: (props: ChannelSliderProps) => T["element"];
|
|
292
|
+
getChannelSliderTrackProps: (props: ChannelSliderProps) => T["element"];
|
|
293
|
+
getChannelSliderThumbProps: (props: ChannelSliderProps) => T["element"];
|
|
294
|
+
getChannelSliderLabelProps: (props: ChannelProps) => T["element"];
|
|
295
|
+
getChannelSliderValueTextProps: (props: ChannelProps) => T["element"];
|
|
296
|
+
getTransparencyGridProps: (props?: TransparencyGridProps) => T["element"];
|
|
297
|
+
getEyeDropperTriggerProps: () => T["button"];
|
|
298
|
+
getSwatchGroupProps: () => T["element"];
|
|
299
|
+
getSwatchTriggerProps: (props: SwatchTriggerProps) => T["button"];
|
|
300
|
+
getSwatchTriggerState: (props: SwatchTriggerProps) => SwatchTriggerState;
|
|
301
|
+
getSwatchProps: (props: SwatchProps) => T["element"];
|
|
302
|
+
getSwatchIndicatorProps: (props: SwatchProps) => T["element"];
|
|
303
|
+
getFormatSelectProps: () => T["select"];
|
|
304
|
+
getFormatTriggerProps: () => T["button"];
|
|
305
305
|
}
|
|
306
306
|
|
|
307
307
|
declare function connect<T extends PropTypes>(service: ColorPickerService, normalize: NormalizeProps<T>): ColorPickerApi<T>;
|
package/dist/index.d.ts
CHANGED
|
@@ -49,9 +49,9 @@ type ElementIds = Partial<{
|
|
|
49
49
|
positioner: string;
|
|
50
50
|
formatSelect: string;
|
|
51
51
|
areaThumb: string;
|
|
52
|
-
channelInput(id: string)
|
|
53
|
-
channelSliderTrack(id: ColorChannel)
|
|
54
|
-
channelSliderThumb(id: ColorChannel)
|
|
52
|
+
channelInput: (id: string) => string;
|
|
53
|
+
channelSliderTrack: (id: ColorChannel) => string;
|
|
54
|
+
channelSliderThumb: (id: ColorChannel) => string;
|
|
55
55
|
}>;
|
|
56
56
|
interface ColorPickerProps extends CommonProperties, DirectionProperty, InteractOutsideHandlers {
|
|
57
57
|
/**
|
|
@@ -243,19 +243,19 @@ interface ColorPickerApi<T extends PropTypes = PropTypes> {
|
|
|
243
243
|
/**
|
|
244
244
|
* Function to set the color value
|
|
245
245
|
*/
|
|
246
|
-
setValue(value: string | Color)
|
|
246
|
+
setValue: (value: string | Color) => void;
|
|
247
247
|
/**
|
|
248
248
|
* Function to set the color value
|
|
249
249
|
*/
|
|
250
|
-
getChannelValue(channel: ColorChannel)
|
|
250
|
+
getChannelValue: (channel: ColorChannel) => string;
|
|
251
251
|
/**
|
|
252
252
|
* Function to get the formatted and localized value of a specific channel
|
|
253
253
|
*/
|
|
254
|
-
getChannelValueText(channel: ColorChannel, locale: string)
|
|
254
|
+
getChannelValueText: (channel: ColorChannel, locale: string) => string;
|
|
255
255
|
/**
|
|
256
256
|
* Function to set the color value of a specific channel
|
|
257
257
|
*/
|
|
258
|
-
setChannelValue(channel: ColorChannel, value: number)
|
|
258
|
+
setChannelValue: (channel: ColorChannel, value: number) => void;
|
|
259
259
|
/**
|
|
260
260
|
* The current color format
|
|
261
261
|
*/
|
|
@@ -263,7 +263,7 @@ interface ColorPickerApi<T extends PropTypes = PropTypes> {
|
|
|
263
263
|
/**
|
|
264
264
|
* Function to set the color format
|
|
265
265
|
*/
|
|
266
|
-
setFormat(format: ColorFormat)
|
|
266
|
+
setFormat: (format: ColorFormat) => void;
|
|
267
267
|
/**
|
|
268
268
|
* The alpha value of the color
|
|
269
269
|
*/
|
|
@@ -271,37 +271,37 @@ interface ColorPickerApi<T extends PropTypes = PropTypes> {
|
|
|
271
271
|
/**
|
|
272
272
|
* Function to set the color alpha
|
|
273
273
|
*/
|
|
274
|
-
setAlpha(value: number)
|
|
274
|
+
setAlpha: (value: number) => void;
|
|
275
275
|
/**
|
|
276
276
|
* Function to open or close the color picker
|
|
277
277
|
*/
|
|
278
|
-
setOpen(open: boolean)
|
|
279
|
-
getRootProps()
|
|
280
|
-
getLabelProps()
|
|
281
|
-
getControlProps()
|
|
282
|
-
getTriggerProps()
|
|
283
|
-
getPositionerProps()
|
|
284
|
-
getContentProps()
|
|
285
|
-
getHiddenInputProps()
|
|
286
|
-
getValueTextProps()
|
|
287
|
-
getAreaProps(props?: AreaProps)
|
|
288
|
-
getAreaBackgroundProps(props?: AreaProps)
|
|
289
|
-
getAreaThumbProps(props?: AreaProps)
|
|
290
|
-
getChannelInputProps(props: ChannelInputProps)
|
|
291
|
-
getChannelSliderProps(props: ChannelSliderProps)
|
|
292
|
-
getChannelSliderTrackProps(props: ChannelSliderProps)
|
|
293
|
-
getChannelSliderThumbProps(props: ChannelSliderProps)
|
|
294
|
-
getChannelSliderLabelProps(props: ChannelProps)
|
|
295
|
-
getChannelSliderValueTextProps(props: ChannelProps)
|
|
296
|
-
getTransparencyGridProps(props?: TransparencyGridProps)
|
|
297
|
-
getEyeDropperTriggerProps()
|
|
298
|
-
getSwatchGroupProps()
|
|
299
|
-
getSwatchTriggerProps(props: SwatchTriggerProps)
|
|
300
|
-
getSwatchTriggerState(props: SwatchTriggerProps)
|
|
301
|
-
getSwatchProps(props: SwatchProps)
|
|
302
|
-
getSwatchIndicatorProps(props: SwatchProps)
|
|
303
|
-
getFormatSelectProps()
|
|
304
|
-
getFormatTriggerProps()
|
|
278
|
+
setOpen: (open: boolean) => void;
|
|
279
|
+
getRootProps: () => T["element"];
|
|
280
|
+
getLabelProps: () => T["element"];
|
|
281
|
+
getControlProps: () => T["element"];
|
|
282
|
+
getTriggerProps: () => T["button"];
|
|
283
|
+
getPositionerProps: () => T["element"];
|
|
284
|
+
getContentProps: () => T["element"];
|
|
285
|
+
getHiddenInputProps: () => T["input"];
|
|
286
|
+
getValueTextProps: () => T["element"];
|
|
287
|
+
getAreaProps: (props?: AreaProps) => T["element"];
|
|
288
|
+
getAreaBackgroundProps: (props?: AreaProps) => T["element"];
|
|
289
|
+
getAreaThumbProps: (props?: AreaProps) => T["element"];
|
|
290
|
+
getChannelInputProps: (props: ChannelInputProps) => T["input"];
|
|
291
|
+
getChannelSliderProps: (props: ChannelSliderProps) => T["element"];
|
|
292
|
+
getChannelSliderTrackProps: (props: ChannelSliderProps) => T["element"];
|
|
293
|
+
getChannelSliderThumbProps: (props: ChannelSliderProps) => T["element"];
|
|
294
|
+
getChannelSliderLabelProps: (props: ChannelProps) => T["element"];
|
|
295
|
+
getChannelSliderValueTextProps: (props: ChannelProps) => T["element"];
|
|
296
|
+
getTransparencyGridProps: (props?: TransparencyGridProps) => T["element"];
|
|
297
|
+
getEyeDropperTriggerProps: () => T["button"];
|
|
298
|
+
getSwatchGroupProps: () => T["element"];
|
|
299
|
+
getSwatchTriggerProps: (props: SwatchTriggerProps) => T["button"];
|
|
300
|
+
getSwatchTriggerState: (props: SwatchTriggerProps) => SwatchTriggerState;
|
|
301
|
+
getSwatchProps: (props: SwatchProps) => T["element"];
|
|
302
|
+
getSwatchIndicatorProps: (props: SwatchProps) => T["element"];
|
|
303
|
+
getFormatSelectProps: () => T["select"];
|
|
304
|
+
getFormatTriggerProps: () => T["button"];
|
|
305
305
|
}
|
|
306
306
|
|
|
307
307
|
declare function connect<T extends PropTypes>(service: ColorPickerService, normalize: NormalizeProps<T>): ColorPickerApi<T>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zag-js/color-picker",
|
|
3
|
-
"version": "1.18.
|
|
3
|
+
"version": "1.18.5",
|
|
4
4
|
"description": "Core logic for the color-picker widget implemented as a state machine",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"js",
|
|
@@ -27,14 +27,14 @@
|
|
|
27
27
|
"url": "https://github.com/chakra-ui/zag/issues"
|
|
28
28
|
},
|
|
29
29
|
"dependencies": {
|
|
30
|
-
"@zag-js/core": "1.18.
|
|
31
|
-
"@zag-js/anatomy": "1.18.
|
|
32
|
-
"@zag-js/dom-query": "1.18.
|
|
33
|
-
"@zag-js/dismissable": "1.18.
|
|
34
|
-
"@zag-js/utils": "1.18.
|
|
35
|
-
"@zag-js/color-utils": "1.18.
|
|
36
|
-
"@zag-js/popper": "1.18.
|
|
37
|
-
"@zag-js/types": "1.18.
|
|
30
|
+
"@zag-js/core": "1.18.5",
|
|
31
|
+
"@zag-js/anatomy": "1.18.5",
|
|
32
|
+
"@zag-js/dom-query": "1.18.5",
|
|
33
|
+
"@zag-js/dismissable": "1.18.5",
|
|
34
|
+
"@zag-js/utils": "1.18.5",
|
|
35
|
+
"@zag-js/color-utils": "1.18.5",
|
|
36
|
+
"@zag-js/popper": "1.18.5",
|
|
37
|
+
"@zag-js/types": "1.18.5"
|
|
38
38
|
},
|
|
39
39
|
"devDependencies": {
|
|
40
40
|
"clean-package": "2.2.0"
|