@livechat/design-system-react-components 1.30.0 → 1.31.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/AppFrame/stories-helpers.d.ts +0 -2
- package/dist/components/DetailsCard/DetailsCard.d.ts +1 -1
- package/dist/components/Modal/index.d.ts +1 -0
- package/dist/components/OnboardingChecklist/OnboardingChecklist.d.ts +3 -0
- package/dist/components/OnboardingChecklist/components/CheckListItem.d.ts +3 -0
- package/dist/components/OnboardingChecklist/components/index.d.ts +1 -0
- package/dist/components/OnboardingChecklist/index.d.ts +2 -0
- package/dist/components/OnboardingChecklist/types.d.ts +93 -0
- package/dist/components/Picker/hooks/useFloatingPicker.d.ts +2 -1
- package/dist/foundations/design-token.d.ts +2 -0
- package/dist/index.cjs.js +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.es.js +2823 -2539
- package/dist/style.css +1 -1
- package/package.json +3 -3
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
interface ExampleAppContentProps {
|
|
3
3
|
showToggle: boolean;
|
|
4
|
-
topBarVisible: boolean;
|
|
5
|
-
handleTopBarButtonClick: () => void;
|
|
6
4
|
}
|
|
7
5
|
export declare const ExampleAppContent: React.FC<ExampleAppContentProps>;
|
|
8
6
|
export declare const ExampleTopBar: React.FC;
|
|
@@ -35,6 +35,6 @@ export interface IDetailsCardProps {
|
|
|
35
35
|
/**
|
|
36
36
|
* Callback function called when the card label is clicked
|
|
37
37
|
*/
|
|
38
|
-
onClick?: () => void;
|
|
38
|
+
onClick?: (e: React.MouseEvent<HTMLButtonElement | HTMLAnchorElement | HTMLDivElement>) => void;
|
|
39
39
|
}
|
|
40
40
|
export declare const DetailsCard: React.FC<IDetailsCardProps>;
|
|
@@ -3,6 +3,7 @@ export { ModalBase } from './components/ModalBase';
|
|
|
3
3
|
export { ModalCloseButton } from './components/ModalCloseButton';
|
|
4
4
|
export { ModalPortal } from './components/ModalPortal';
|
|
5
5
|
export { ModalHeader } from './components/ModalHeader';
|
|
6
|
+
export { ActionModalContent } from './components/ActionModalContent';
|
|
6
7
|
export type { ModalProps } from './Modal';
|
|
7
8
|
export type { ModalBaseProps } from './components/ModalBase';
|
|
8
9
|
export type { ModalCloseButtonProps } from './components/ModalCloseButton';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { CheckListItem } from './CheckListItem';
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
export interface IChecklistItemProps {
|
|
3
|
+
/**
|
|
4
|
+
* Define the unique id of the item
|
|
5
|
+
*/
|
|
6
|
+
id: string;
|
|
7
|
+
/**
|
|
8
|
+
* Set the title of the item
|
|
9
|
+
*/
|
|
10
|
+
title: string;
|
|
11
|
+
/**
|
|
12
|
+
* Set the description of the item
|
|
13
|
+
*/
|
|
14
|
+
description: string;
|
|
15
|
+
/**
|
|
16
|
+
* The element to display when the item is active
|
|
17
|
+
*/
|
|
18
|
+
cta: React.ReactElement;
|
|
19
|
+
/**
|
|
20
|
+
* The element to display in the right column when the item is active
|
|
21
|
+
*/
|
|
22
|
+
placeholder: React.ReactElement;
|
|
23
|
+
}
|
|
24
|
+
export interface ICheckListItem extends Omit<IChecklistItemProps, 'placeholder'> {
|
|
25
|
+
isActive: boolean;
|
|
26
|
+
isChecked: boolean;
|
|
27
|
+
isLastElement: boolean;
|
|
28
|
+
onClick: (id: string) => void;
|
|
29
|
+
}
|
|
30
|
+
export type ICompletionMessageDataProps = {
|
|
31
|
+
/**
|
|
32
|
+
* Set the title of the complete state
|
|
33
|
+
*/
|
|
34
|
+
title: string;
|
|
35
|
+
/**
|
|
36
|
+
* Set the greeting text of the complete state
|
|
37
|
+
*/
|
|
38
|
+
greetingText?: string;
|
|
39
|
+
/**
|
|
40
|
+
* The element to display when the checklist is completed before the animation starts
|
|
41
|
+
*/
|
|
42
|
+
placeholder?: React.ReactElement;
|
|
43
|
+
/**
|
|
44
|
+
* Define the delay betweend displaying complete placeholder and the animation starts
|
|
45
|
+
*/
|
|
46
|
+
delay?: number;
|
|
47
|
+
/**
|
|
48
|
+
* Define the custom heigh of content visible after checklist complete
|
|
49
|
+
*/
|
|
50
|
+
height?: number;
|
|
51
|
+
};
|
|
52
|
+
export interface IOnboardingChecklistProps {
|
|
53
|
+
/**
|
|
54
|
+
* The CSS class for the component
|
|
55
|
+
*/
|
|
56
|
+
className?: string;
|
|
57
|
+
/**
|
|
58
|
+
* Set the title of the checklist
|
|
59
|
+
*/
|
|
60
|
+
title: string;
|
|
61
|
+
/**
|
|
62
|
+
* Set the greeting text of the checklist
|
|
63
|
+
*/
|
|
64
|
+
greetingText?: string;
|
|
65
|
+
/**
|
|
66
|
+
* The list of items to display
|
|
67
|
+
*/
|
|
68
|
+
items: IChecklistItemProps[];
|
|
69
|
+
/**
|
|
70
|
+
* Set to define the active item
|
|
71
|
+
*/
|
|
72
|
+
activeItemId: string;
|
|
73
|
+
/**
|
|
74
|
+
* Set to defined the complete items
|
|
75
|
+
*/
|
|
76
|
+
completedItemsIds: string[];
|
|
77
|
+
/**
|
|
78
|
+
* Callback function when list element is clicked
|
|
79
|
+
*/
|
|
80
|
+
onActiveChange: (id: string) => void;
|
|
81
|
+
/**
|
|
82
|
+
* The CSS class for the right column
|
|
83
|
+
*/
|
|
84
|
+
placeholderClassName?: string;
|
|
85
|
+
/**
|
|
86
|
+
* Set to define the checklist is completed
|
|
87
|
+
*/
|
|
88
|
+
isCompleted?: boolean;
|
|
89
|
+
/**
|
|
90
|
+
* Complete element which will be displayed when `isCompleted` is true
|
|
91
|
+
*/
|
|
92
|
+
completionMessageData: ICompletionMessageDataProps;
|
|
93
|
+
}
|
|
@@ -13,6 +13,7 @@ interface UseFloatingPickerProps {
|
|
|
13
13
|
maxListHeight: number;
|
|
14
14
|
isOpen?: boolean;
|
|
15
15
|
onVisibilityChange?: (open: boolean, event?: Event | undefined) => void;
|
|
16
|
+
searchPhrase?: string;
|
|
16
17
|
}
|
|
17
18
|
interface IUseFloatingPicker {
|
|
18
19
|
getReferenceProps: (userProps?: React.HTMLProps<HTMLElement> | undefined) => Record<string, unknown>;
|
|
@@ -31,5 +32,5 @@ interface IUseFloatingPicker {
|
|
|
31
32
|
pointer: boolean;
|
|
32
33
|
setPointer: (pointer: boolean) => void;
|
|
33
34
|
}
|
|
34
|
-
export declare const useFloatingPicker: ({ disabled, items, placement, minListHeight, maxListHeight, floatingStrategy, useDismissHookProps, useClickHookProps, isOpen, onVisibilityChange, }: UseFloatingPickerProps) => IUseFloatingPicker;
|
|
35
|
+
export declare const useFloatingPicker: ({ disabled, items, placement, minListHeight, maxListHeight, floatingStrategy, useDismissHookProps, useClickHookProps, isOpen, onVisibilityChange, searchPhrase, }: UseFloatingPickerProps) => IUseFloatingPicker;
|
|
35
36
|
export {};
|
|
@@ -365,5 +365,7 @@ export declare const DesignToken: {
|
|
|
365
365
|
OnePopoverBorderActive: string;
|
|
366
366
|
OneTooltipBackground: string;
|
|
367
367
|
ContentBasicAutofill: string;
|
|
368
|
+
SurfaceCheckListItemOpenBackground: string;
|
|
369
|
+
SurfaceCheckListBackground: string;
|
|
368
370
|
};
|
|
369
371
|
export type DesignTokenKey = keyof typeof DesignToken;
|