@livechat/design-system-react-components 2.20.0 → 2.22.0
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/Accordion/components/{AccordionAnimatedLabel.d.ts → AccordionAnimatedLabel/AccordionAnimatedLabel.d.ts} +1 -1
- package/dist/components/Accordion/components/AccordionAnimatedLabel/styles.d.ts +2 -0
- package/dist/components/Accordion/components/AccordionMultilineElement/styles.d.ts +2 -0
- package/dist/components/Accordion/components/index.d.ts +2 -0
- package/dist/components/Accordion/styles.d.ts +8 -0
- package/dist/components/ActionCard/types.d.ts +20 -2
- package/dist/components/AppFrame/components/SideNavigationGroup/constants.d.ts +1 -0
- package/dist/components/AppFrame/components/SideNavigationGroup/types.d.ts +46 -1
- package/dist/components/Picker/components/PickerTrigger.d.ts +1 -0
- package/dist/foundations/shadow-token.d.ts +1 -0
- package/dist/hooks/useAnimations.d.ts +1 -1
- package/dist/index.cjs +136 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.js +2573 -2440
- package/dist/style.css +1 -1
- package/package.json +5 -3
- /package/dist/components/Accordion/components/{AccordionMultilineElement.d.ts → AccordionMultilineElement/AccordionMultilineElement.d.ts} +0 -0
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export declare const baseStyles: (isPromo?: boolean) => string;
|
|
2
|
+
export declare const kind: (kind?: string) => string;
|
|
3
|
+
export declare const open: string;
|
|
4
|
+
export declare const label: (isPromo?: boolean) => string;
|
|
5
|
+
export declare const chevron: (isOpen?: boolean, isPromo?: boolean) => string;
|
|
6
|
+
export declare const content: string;
|
|
7
|
+
export declare const contentInner: (isOpen?: boolean, isPromo?: boolean) => string;
|
|
8
|
+
export declare const footer: (isPromo?: boolean) => string;
|
|
@@ -1,5 +1,23 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
export
|
|
2
|
+
export type ActionCardProps = ({
|
|
3
|
+
/**
|
|
4
|
+
* Specify if the card is in loading state
|
|
5
|
+
*/
|
|
6
|
+
isLoading: true;
|
|
7
|
+
/**
|
|
8
|
+
* Specify if the card is in animated loading state
|
|
9
|
+
*/
|
|
10
|
+
isLoadingAnimated?: boolean;
|
|
11
|
+
} | {
|
|
12
|
+
/**
|
|
13
|
+
* Specify if the card is in loading state
|
|
14
|
+
*/
|
|
15
|
+
isLoading?: false;
|
|
16
|
+
/**
|
|
17
|
+
* Loading animation is not available when not loading
|
|
18
|
+
*/
|
|
19
|
+
isLoadingAnimated?: never;
|
|
20
|
+
}) & {
|
|
3
21
|
/**
|
|
4
22
|
* The CSS class for main container
|
|
5
23
|
*/
|
|
@@ -20,4 +38,4 @@ export interface ActionCardProps {
|
|
|
20
38
|
* Optional handler called on card click
|
|
21
39
|
*/
|
|
22
40
|
onClick?: () => void;
|
|
23
|
-
}
|
|
41
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const SIDE_NAVIGATION_LINK_LABEL_TEST_ID = "side-navigation-link-label-test-id";
|
|
@@ -1,5 +1,9 @@
|
|
|
1
|
+
import { IUseAnimations } from '../../../../hooks/useAnimations';
|
|
1
2
|
import { ComponentCoreProps } from '../../../../utils/types';
|
|
2
3
|
import * as React from 'react';
|
|
4
|
+
interface IOnClickProps {
|
|
5
|
+
toggle: () => void;
|
|
6
|
+
}
|
|
3
7
|
export interface ISideNavigationGroupProps extends ComponentCoreProps {
|
|
4
8
|
/**
|
|
5
9
|
* It will display your side navigation elements
|
|
@@ -10,19 +14,60 @@ export interface ISideNavigationGroupProps extends ComponentCoreProps {
|
|
|
10
14
|
*/
|
|
11
15
|
label?: React.ReactNode | ((isOpen: boolean) => React.ReactNode);
|
|
12
16
|
/**
|
|
13
|
-
* The right node of the side navigation list
|
|
17
|
+
* The right node of the side navigation list
|
|
14
18
|
*/
|
|
15
19
|
rightNode?: React.ReactNode | ((isOpen: boolean) => React.ReactNode);
|
|
16
20
|
/**
|
|
17
21
|
* Specify whether the list should be collapsible
|
|
18
22
|
*/
|
|
19
23
|
isCollapsible?: boolean;
|
|
24
|
+
/**
|
|
25
|
+
* Specify whether the label is a link
|
|
26
|
+
*/
|
|
27
|
+
isLinkLabel?: boolean;
|
|
28
|
+
/**
|
|
29
|
+
* Specify whether the list label is active
|
|
30
|
+
*/
|
|
31
|
+
isActive?: boolean;
|
|
32
|
+
/**
|
|
33
|
+
* Specify whether the list is open
|
|
34
|
+
*/
|
|
35
|
+
isOpen?: IUseAnimations['isOpen'];
|
|
36
|
+
/**
|
|
37
|
+
* Specify whether the list is mounted
|
|
38
|
+
*/
|
|
39
|
+
isMounted?: IUseAnimations['isMounted'];
|
|
40
|
+
/**
|
|
41
|
+
* Set whether the list should be visible
|
|
42
|
+
*/
|
|
43
|
+
setShouldBeVisible?: IUseAnimations['setShouldBeVisible'];
|
|
44
|
+
/**
|
|
45
|
+
* The function to call on list label click
|
|
46
|
+
*/
|
|
47
|
+
onClick?: ({ toggle }: IOnClickProps) => void;
|
|
20
48
|
/**
|
|
21
49
|
* The function to call on item hover
|
|
22
50
|
*/
|
|
23
51
|
onItemHover?: () => void;
|
|
52
|
+
/**
|
|
53
|
+
* The ref of the list wrapper
|
|
54
|
+
*/
|
|
55
|
+
listWrapperRef?: React.RefObject<HTMLDivElement>;
|
|
24
56
|
/**
|
|
25
57
|
* Specify whether the list should be open on the first render
|
|
26
58
|
*/
|
|
27
59
|
shouldOpenOnInit?: boolean;
|
|
60
|
+
/**
|
|
61
|
+
* The CSS class name for the label
|
|
62
|
+
*/
|
|
63
|
+
labelClassName?: string;
|
|
64
|
+
/**
|
|
65
|
+
* The CSS class name for the label wrapper
|
|
66
|
+
*/
|
|
67
|
+
labelWrapperClassName?: string;
|
|
68
|
+
/**
|
|
69
|
+
* The CSS class name for the list wrapper
|
|
70
|
+
*/
|
|
71
|
+
listWrapperClassName?: string;
|
|
28
72
|
}
|
|
73
|
+
export {};
|
|
@@ -4,7 +4,7 @@ interface UseAnimationsProps {
|
|
|
4
4
|
elementRef: React.RefObject<HTMLDivElement>;
|
|
5
5
|
includeSleepWakeScenario?: boolean;
|
|
6
6
|
}
|
|
7
|
-
interface IUseAnimations {
|
|
7
|
+
export interface IUseAnimations {
|
|
8
8
|
isOpen: boolean;
|
|
9
9
|
isMounted: boolean;
|
|
10
10
|
setShouldBeVisible: React.Dispatch<React.SetStateAction<boolean>>;
|