gantri-components 1.119.1 → 1.119.2
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/components/color-picker/__tests__/color-picker.test.d.ts +1 -0
- package/dist/components/color-picker/color-picker.presets.d.ts +2 -2
- package/dist/components/color-picker/color-picker.types.d.ts +7 -8
- package/dist/components/color-picker/components/color-picker-item/__tests__/color-picker-item.test.d.ts +1 -0
- package/dist/components/color-picker/components/color-picker-item/color-picker-item.presets.d.ts +2 -0
- package/dist/components/color-picker/components/color-picker-item/color-picker-item.types.d.ts +7 -4
- package/dist/components/color-picker/components/color-picker-item/color-picker.styles.d.ts +3 -3
- package/dist/components/overlay/__tests__/overlay.test.d.ts +1 -0
- package/dist/components/overlay/overlay.types.d.ts +12 -1
- package/dist/index.cjs.js +1 -1
- package/dist/index.esm.js +1 -1
- package/dist/index.umd.js +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare const ColorPickerPresets:
|
|
1
|
+
import { ColorPickerDefaultProps } from './color-picker.types';
|
|
2
|
+
export declare const ColorPickerPresets: ColorPickerDefaultProps;
|
|
@@ -1,12 +1,6 @@
|
|
|
1
1
|
import { ChangeEvent } from 'react';
|
|
2
2
|
export declare type ColorPickerVariant = 'large' | 'small';
|
|
3
|
-
export interface ColorPickerProps {
|
|
4
|
-
allowMultipleSelection?: boolean;
|
|
5
|
-
/**
|
|
6
|
-
* List of colors to render,
|
|
7
|
-
* defaults to gantri's product colors list
|
|
8
|
-
* */
|
|
9
|
-
colors?: PickerColor[];
|
|
3
|
+
export interface ColorPickerProps extends Partial<ColorPickerDefaultProps> {
|
|
10
4
|
labelText?: string;
|
|
11
5
|
labelTx?: string;
|
|
12
6
|
labelTxValues?: Record<string, unknown>;
|
|
@@ -15,7 +9,12 @@ export interface ColorPickerProps {
|
|
|
15
9
|
onValueChange?: (selected: PickerColor | PickerColor[] | null) => void;
|
|
16
10
|
readOnly?: boolean;
|
|
17
11
|
value?: string | string[];
|
|
18
|
-
|
|
12
|
+
}
|
|
13
|
+
export interface ColorPickerDefaultProps {
|
|
14
|
+
allowMultipleSelection: boolean;
|
|
15
|
+
/** List of colors to render. Defaults to Gantri's product colors list. */
|
|
16
|
+
colors: PickerColor[];
|
|
17
|
+
variant: ColorPickerVariant;
|
|
19
18
|
}
|
|
20
19
|
export interface PickerColor {
|
|
21
20
|
code: string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/dist/components/color-picker/components/color-picker-item/color-picker-item.types.d.ts
CHANGED
|
@@ -1,9 +1,12 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { CSSProperties } from 'styled-components';
|
|
2
2
|
import { ColorPickerVariant, PickerColor } from '../../color-picker.types';
|
|
3
|
-
export interface ColorPickerItemProps {
|
|
3
|
+
export interface ColorPickerItemProps extends Partial<ColorPickerItemDefaultProps> {
|
|
4
4
|
active?: boolean;
|
|
5
5
|
color: PickerColor;
|
|
6
6
|
onColorClick: (color: PickerColor) => void;
|
|
7
|
-
|
|
8
|
-
|
|
7
|
+
/** Overrides `variant`. */
|
|
8
|
+
size?: CSSProperties['width'];
|
|
9
|
+
}
|
|
10
|
+
export interface ColorPickerItemDefaultProps {
|
|
11
|
+
variant: ColorPickerVariant;
|
|
9
12
|
}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { CSSProperties } from 'styled-components';
|
|
2
2
|
import { ColorPickerVariant } from '../../color-picker.types';
|
|
3
3
|
export declare const StyledColorOutline: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {
|
|
4
4
|
$selected?: boolean | undefined;
|
|
5
|
-
$size?:
|
|
5
|
+
$size?: CSSProperties['width'];
|
|
6
6
|
$variant?: ColorPickerVariant | undefined;
|
|
7
7
|
}, never>;
|
|
8
8
|
export declare const StyledColor: import("styled-components").StyledComponent<import("react-spring").AnimatedComponent<"span">, import("styled-components").DefaultTheme, {
|
|
9
|
-
$size?:
|
|
9
|
+
$size?: CSSProperties['width'];
|
|
10
10
|
$variant?: ColorPickerVariant | undefined;
|
|
11
11
|
color: string;
|
|
12
12
|
}, never>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,19 +1,30 @@
|
|
|
1
1
|
import { CSSProperties, ReactNode } from 'react';
|
|
2
2
|
export interface OverlayProps {
|
|
3
|
+
/** Trigger event interactions with this component causes `content` to render, as appropriate. */
|
|
4
|
+
children?: ReactNode;
|
|
5
|
+
/** Applied as inline styles to the `children` wrapper. */
|
|
3
6
|
containerStyles?: CSSProperties;
|
|
7
|
+
/** The component to show/hide. */
|
|
4
8
|
content: ReactNode;
|
|
5
9
|
disabled?: boolean;
|
|
6
10
|
offsetBottom?: string;
|
|
7
11
|
offsetLeft?: string;
|
|
8
12
|
offsetRight?: string;
|
|
9
13
|
offsetTop?: string;
|
|
14
|
+
/**
|
|
15
|
+
* Not called if `triggerEvent` is `'manual'`.
|
|
16
|
+
*
|
|
17
|
+
* If `triggerEvent` is `'hover'`, this can be called twice. Once for unhovering the child, and once for unhovering the content.
|
|
18
|
+
* */
|
|
10
19
|
onClose?: (opened: false) => void;
|
|
20
|
+
/** Not called if `triggerEvent` is `'manual'` */
|
|
11
21
|
onOpen?: (opened: true) => void;
|
|
22
|
+
/** Should be used when `triggerEvent` is `'manual'`. */
|
|
12
23
|
open?: boolean;
|
|
13
24
|
parentContainer?: HTMLElement;
|
|
14
25
|
position?: OverlayPosition;
|
|
15
26
|
prerenderContent?: boolean;
|
|
16
|
-
triggerEvent?: 'click' | 'hover' | '
|
|
27
|
+
triggerEvent?: 'click' | 'hover' | 'manual';
|
|
17
28
|
}
|
|
18
29
|
export interface UseOverlayParams {
|
|
19
30
|
content: ReactNode;
|