@epam/ai-dial-ui-kit 0.6.0-rc.0 → 0.6.0-rc.10
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/README.md +4 -3
- package/dist/dial-ui-kit.cjs.js +28 -28
- package/dist/dial-ui-kit.es.js +7528 -7462
- package/dist/src/components/AutocompleteInput/AutocompleteInput.d.ts +3 -4
- package/dist/src/components/Breadcrumb/Breadcrumb.d.ts +8 -8
- package/dist/src/components/Breadcrumb/BreadcrumbItem.d.ts +4 -5
- package/dist/src/components/Button/Button.d.ts +10 -1
- package/dist/src/components/ConfirmationPopup/ConfirmationPopup.d.ts +2 -2
- package/dist/src/components/ErrorText/ErrorText.d.ts +2 -2
- package/dist/src/components/FileManager/FileManager.d.ts +11 -3
- package/dist/src/components/FileManager/FileManagerContext.d.ts +5 -3
- package/dist/src/components/FileManager/components/ConflictResolutionPopup/ConflictResolutionPopup.d.ts +0 -2
- package/dist/src/components/FileManager/components/DestinationFolderPopup/DestinationFolderPopup.d.ts +5 -1
- package/dist/src/components/FileManager/components/FileManagerNavigationPanel/FileManagerNavigationPanel.d.ts +1 -1
- package/dist/src/components/FileManager/components/FileMetadataPopup/FileMetadataPopup.d.ts +1 -1
- package/dist/src/components/FileManager/hooks/use-current-path.d.ts +7 -4
- package/dist/src/components/FileManager/hooks/use-paths-selection.d.ts +13 -0
- package/dist/src/components/FormPopup/FormPopup.d.ts +2 -2
- package/dist/src/components/Grid/constants.d.ts +0 -3
- package/dist/src/components/LabelledText/LabelledText.d.ts +1 -1
- package/dist/src/components/Popup/Popup.d.ts +2 -2
- package/dist/src/components/RadioButton/RadioButton.d.ts +2 -2
- package/dist/src/components/RadioGroupPopupField/RadioGroupPopupField.d.ts +3 -3
- package/dist/src/components/Switch/Switch.d.ts +2 -2
- package/dist/src/models/breadcrumb.d.ts +1 -1
- package/dist/src/types/form-item.d.ts +1 -1
- package/package.json +1 -1
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import { FC } from 'react';
|
|
2
2
|
import { DialAutocompleteInputValueProps } from './AutocompleteInputValue';
|
|
3
3
|
export interface DialAutocompleteInputProps extends DialAutocompleteInputValueProps {
|
|
4
|
-
placeholder?: string;
|
|
5
|
-
updateSelected: (items: string[]) => void;
|
|
6
4
|
containerClassName?: string;
|
|
7
5
|
inputClassName?: string;
|
|
6
|
+
onChange: (items: string[]) => void;
|
|
8
7
|
}
|
|
9
8
|
/**
|
|
10
9
|
* A component that provides an interactive input field with autocomplete functionality. Users can
|
|
@@ -17,7 +16,7 @@ export interface DialAutocompleteInputProps extends DialAutocompleteInputValuePr
|
|
|
17
16
|
* <DialAutocompleteInput
|
|
18
17
|
* placeholder="Type to add items"
|
|
19
18
|
* selectedItems={['Item 1', 'Item 2']}
|
|
20
|
-
*
|
|
19
|
+
* onChange={(items) => console.log(items)}
|
|
21
20
|
* containerClassName="custom-container-class"
|
|
22
21
|
* inputClassName="custom-input-class"
|
|
23
22
|
* listClassName="custom-list-class"
|
|
@@ -27,7 +26,7 @@ export interface DialAutocompleteInputProps extends DialAutocompleteInputValuePr
|
|
|
27
26
|
*
|
|
28
27
|
* @param [placeholder] - The placeholder text displayed in the input field when no items are selected.
|
|
29
28
|
* @param [selectedItems=[]] - An array of strings representing the currently selected items.
|
|
30
|
-
* @param
|
|
29
|
+
* @param onChange - A callback function that updates the list of selected items. Called when items are added or removed.
|
|
31
30
|
* @param [listClassName] - Additional CSS classes applied to the `<ul>` element containing the list of selected items.
|
|
32
31
|
* @param [listElementClassName] - Additional CSS classes applied to each `<li>` element representing an individual selected item.
|
|
33
32
|
* @param [containerClassName] - Additional CSS classes applied to the container `<div>` element wrapping the input and list.
|
|
@@ -6,7 +6,7 @@ export interface DialBreadcrumbProps {
|
|
|
6
6
|
ariaLabel?: string;
|
|
7
7
|
className?: string;
|
|
8
8
|
children?: ReactNode;
|
|
9
|
-
|
|
9
|
+
labelClassName?: string;
|
|
10
10
|
}
|
|
11
11
|
/**
|
|
12
12
|
* Breadcrumb navigation component with horizontal scroll on overflow.
|
|
@@ -18,16 +18,16 @@ export interface DialBreadcrumbProps {
|
|
|
18
18
|
* ```tsx
|
|
19
19
|
* <DialBreadcrumb
|
|
20
20
|
* pathItems={[
|
|
21
|
-
* {
|
|
22
|
-
* {
|
|
23
|
-
* {
|
|
21
|
+
* { label: 'Home', href: '/' },
|
|
22
|
+
* { label: 'Section', href: '/section' },
|
|
23
|
+
* { label: 'Current Page' },
|
|
24
24
|
* ]}
|
|
25
25
|
* />
|
|
26
26
|
*
|
|
27
27
|
* <DialBreadcrumb>
|
|
28
|
-
* <DialBreadcrumbItem
|
|
29
|
-
* <DialBreadcrumbItem
|
|
30
|
-
* <DialBreadcrumbItem
|
|
28
|
+
* <DialBreadcrumbItem label="Home" href="/" />
|
|
29
|
+
* <DialBreadcrumbItem label="Section" href="/section" />
|
|
30
|
+
* <DialBreadcrumbItem label="Current Page" />
|
|
31
31
|
* </DialBreadcrumb>
|
|
32
32
|
* ```
|
|
33
33
|
*
|
|
@@ -36,6 +36,6 @@ export interface DialBreadcrumbProps {
|
|
|
36
36
|
* @param [ariaLabel] - Aria label for the `<nav>` element (default: "Breadcrumb").
|
|
37
37
|
* @param [className] - Additional CSS classes for the `<nav>` container.
|
|
38
38
|
* @param [children] - Alternatively, compose with `<DialBreadcrumbItem/>` as children.
|
|
39
|
-
* @param [
|
|
39
|
+
* @param [labelClassName] - Additional CSS classes applied to each item when using `pathItems` prop.
|
|
40
40
|
*/
|
|
41
41
|
export declare const DialBreadcrumb: FC<DialBreadcrumbProps>;
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
import { FC, MouseEventHandler, ReactNode } from 'react';
|
|
2
|
-
export interface DialBreadcrumbItemProps {
|
|
3
|
-
|
|
1
|
+
import { FC, HTMLAttributes, MouseEventHandler, ReactNode } from 'react';
|
|
2
|
+
export interface DialBreadcrumbItemProps extends Omit<HTMLAttributes<HTMLLIElement>, 'onClick'> {
|
|
3
|
+
label: ReactNode;
|
|
4
4
|
href?: string;
|
|
5
5
|
onClick?: MouseEventHandler<HTMLAnchorElement>;
|
|
6
6
|
disabled?: boolean;
|
|
7
7
|
iconBefore?: ReactNode;
|
|
8
|
-
|
|
9
|
-
titleClassName?: string;
|
|
8
|
+
labelClassName?: string;
|
|
10
9
|
isLast?: boolean;
|
|
11
10
|
separator?: ReactNode;
|
|
12
11
|
}
|
|
@@ -21,9 +21,18 @@ export interface DialButtonProps extends DetailedHTMLProps<ButtonHTMLAttributes<
|
|
|
21
21
|
* />
|
|
22
22
|
* ```
|
|
23
23
|
*
|
|
24
|
+
* @example
|
|
25
|
+
* ```tsx
|
|
26
|
+
* <DialButton
|
|
27
|
+
* label={<span>Custom <strong>Label</strong></span>}
|
|
28
|
+
* aria-label="Custom Label"
|
|
29
|
+
* onClick={handleClick}
|
|
30
|
+
* />
|
|
31
|
+
* ```
|
|
32
|
+
*
|
|
24
33
|
* inherits all properties from the `ButtonHTMLAttributes<HTMLButtonElement>`
|
|
25
34
|
*
|
|
26
|
-
* @param [label] - The
|
|
35
|
+
* @param [label] - The content of the button. Can be any React node.
|
|
27
36
|
* @param [variant=ButtonVariant.Primary] - Defines the visual style of the button
|
|
28
37
|
* @param [textClassName] - Additional CSS classes to apply specifically to the button text
|
|
29
38
|
* @param [iconAfter] - Icon or element to display after the button text
|
|
@@ -24,7 +24,7 @@ export interface DialConfirmationPopupProps extends DialPopupProps {
|
|
|
24
24
|
* ```tsx
|
|
25
25
|
* <ConfirmationModal
|
|
26
26
|
* open
|
|
27
|
-
*
|
|
27
|
+
* header="Delete item?"
|
|
28
28
|
* description="This action cannot be undone."
|
|
29
29
|
* confirmLabel="Delete"
|
|
30
30
|
* onClose={() => setOpen(false)}
|
|
@@ -32,7 +32,7 @@ export interface DialConfirmationPopupProps extends DialPopupProps {
|
|
|
32
32
|
* />
|
|
33
33
|
* ```
|
|
34
34
|
*
|
|
35
|
-
* @param
|
|
35
|
+
* @param header - Title content for the header
|
|
36
36
|
* @param [description] - Secondary text (ignored when `children` set)
|
|
37
37
|
* @param [descriptionClassName] - Custom CSS class for the description
|
|
38
38
|
* @param [open=false] - Controls visibility of the popup
|
|
@@ -16,7 +16,7 @@ import { ConflictResolutionPopupProps } from './components/ConflictResolutionPop
|
|
|
16
16
|
import { RenameValidationMessages } from './hooks/use-item-renaming';
|
|
17
17
|
type GridRow = FileManagerGridRow;
|
|
18
18
|
export type DialFileManagerConflictResolutionPopupOptions = Omit<ConflictResolutionPopupProps, 'open' | 'onClose' | 'onReplace' | 'onDuplicate' | 'conflictingFiles'>;
|
|
19
|
-
export type DialFileManagerDestinationFolderPopupOptions = Pick<DestinationFolderPopupProps, 'setDestinationFolderPath' | 'destinationFolderPath' | 'addFolderLabel' | 'copyLabel' | 'moveLabel' | 'hiddenFilesSwitcherLabel' | '
|
|
19
|
+
export type DialFileManagerDestinationFolderPopupOptions = Pick<DestinationFolderPopupProps, 'setDestinationFolderPath' | 'destinationFolderPath' | 'addFolderLabel' | 'copyLabel' | 'moveLabel' | 'hiddenFilesSwitcherLabel' | 'header' | 'onCreateFolder' | 'onCreateFolderValidate' | 'folderCreationValidationMessages' | 'disabledPathTooltip'> & {
|
|
20
20
|
getCopyHeader?: (itemsCount: number, itemName?: string) => string;
|
|
21
21
|
getMoveHeader?: (itemsCount: number, itemName?: string) => string;
|
|
22
22
|
};
|
|
@@ -24,7 +24,7 @@ export interface FileMetadataPopupOptions {
|
|
|
24
24
|
fileMetadata?: DialFile;
|
|
25
25
|
loading?: boolean;
|
|
26
26
|
clearMetadata?: () => void;
|
|
27
|
-
|
|
27
|
+
header?: ReactNode;
|
|
28
28
|
nameLabel?: string;
|
|
29
29
|
pathLabel?: string;
|
|
30
30
|
modifiedDateLabel?: string;
|
|
@@ -33,7 +33,7 @@ export interface FileMetadataPopupOptions {
|
|
|
33
33
|
}
|
|
34
34
|
export interface FileTreeOptions extends Omit<DialFoldersTreeProps, 'items' | 'selectedPath' | 'onItemClick'> {
|
|
35
35
|
width?: number;
|
|
36
|
-
|
|
36
|
+
header?: ReactNode;
|
|
37
37
|
containerClassName?: string;
|
|
38
38
|
additionalButtons?: ReactNode;
|
|
39
39
|
collapsed?: boolean;
|
|
@@ -98,12 +98,16 @@ export interface CreateFolderValidationMessages {
|
|
|
98
98
|
}
|
|
99
99
|
export interface DialFileManagerProps {
|
|
100
100
|
path?: string;
|
|
101
|
+
defaultPath?: string;
|
|
101
102
|
className?: string;
|
|
102
103
|
allowedFileTypes?: DialFileAcceptType[];
|
|
103
104
|
items?: DialFile[];
|
|
104
105
|
rootItem?: DialRootFolder;
|
|
105
106
|
filesLoading?: boolean;
|
|
106
107
|
sharedByMePaths?: Set<string>;
|
|
108
|
+
selectedPaths?: Set<string>;
|
|
109
|
+
defaultSelectedPaths?: Set<string>;
|
|
110
|
+
onSelectedPathsChange?: (paths: Set<string>) => void;
|
|
107
111
|
showHiddenFiles?: boolean;
|
|
108
112
|
onShowHiddenFilesChange?: (value: boolean) => void;
|
|
109
113
|
treeOptions?: FileTreeOptions;
|
|
@@ -186,10 +190,13 @@ export interface DialFileManagerProps {
|
|
|
186
190
|
* ```
|
|
187
191
|
*
|
|
188
192
|
* @param [path] - Absolute path of the current location (e.g. "/All files/Design/Icons")
|
|
193
|
+
* @param [defaultPath] - Initial path used in uncontrolled mode (applied only on first render)
|
|
189
194
|
* @param [className] - Additional classes for the root container
|
|
190
195
|
* @param [items] - Full hierarchical list of files and folders used by both tree and grid
|
|
191
196
|
* @param [rootItem] - Optional root folder item to represent the top-level container in the tree
|
|
192
197
|
* @param [filesLoading=false] - When true, shows skeleton loading state in the grid
|
|
198
|
+
* @param [selectedPaths] - Controlled set of selected item paths
|
|
199
|
+
* @param [defaultSelectedPaths] - Initial selected paths used in uncontrolled mode
|
|
193
200
|
*
|
|
194
201
|
* @param [treeOptions] - Options that configure the collapsible sidebar and folders tree
|
|
195
202
|
* @param [navigationPanelOptions] - Options for the breadcrumb and search panel (value/onSearchChange for controlled search)
|
|
@@ -201,6 +208,7 @@ export interface DialFileManagerProps {
|
|
|
201
208
|
* @param [compactViewWidthBreakpoint=DEFAULT_COMPACT_VIEW_WIDTH_BREAKPOINT] - Width (px) below which the component switches to compact view.
|
|
202
209
|
*
|
|
203
210
|
* @param [onPathChange] - Callback fired when user navigates via tree or breadcrumb
|
|
211
|
+
* @param [onSelectedPathsChange] - Callback fired when the selected paths change
|
|
204
212
|
* @param [onTableFileClick] - Callback fired when a file row is clicked in the grid
|
|
205
213
|
*
|
|
206
214
|
* @param [onCopyFiles] - Callback fired when files copy-paste
|
|
@@ -31,7 +31,9 @@ export interface FileManagerContextValue {
|
|
|
31
31
|
toolbarOptions?: ToolbarOptions;
|
|
32
32
|
bulkActionsToolbarOptions?: BulkActionsToolbarOptions;
|
|
33
33
|
deleteConfirmationOptions?: DeleteConfirmationOptions;
|
|
34
|
-
destinationFolderPopupOptions?: DialFileManagerDestinationFolderPopupOptions
|
|
34
|
+
destinationFolderPopupOptions?: DialFileManagerDestinationFolderPopupOptions & {
|
|
35
|
+
sourceFolder?: string;
|
|
36
|
+
};
|
|
35
37
|
conflictResolutionPopupOptions?: DialFileManagerConflictResolutionPopupOptions;
|
|
36
38
|
fileMetadataPopupOptions?: FileMetadataPopupOptions;
|
|
37
39
|
compactViewWidthBreakpoint?: number;
|
|
@@ -45,9 +47,9 @@ export interface FileManagerContextValue {
|
|
|
45
47
|
isTreeCollapsed: boolean;
|
|
46
48
|
toggleTreeCollapse: () => void;
|
|
47
49
|
setIsTreeCollapsed: (value: boolean) => void;
|
|
48
|
-
|
|
50
|
+
selectedPaths: Set<string>;
|
|
49
51
|
selectedFiles: Map<string, DialFile>;
|
|
50
|
-
|
|
52
|
+
setSelectedPaths: (paths: Set<string>) => void;
|
|
51
53
|
clearSelection: () => void;
|
|
52
54
|
currentFolder?: DialFile;
|
|
53
55
|
gridRows: FileManagerGridRow[];
|
|
@@ -12,7 +12,6 @@ export interface ConflictResolutionPopupProps {
|
|
|
12
12
|
onDuplicate: () => void;
|
|
13
13
|
onDecideForEach?: (decisions: FileConflictDecision[]) => void;
|
|
14
14
|
conflictingFiles: DialFile[];
|
|
15
|
-
title?: string;
|
|
16
15
|
singleFileTitle?: string;
|
|
17
16
|
multipleFilesTitle?: string;
|
|
18
17
|
message?: string;
|
|
@@ -78,7 +77,6 @@ export interface ConflictResolutionPopupProps {
|
|
|
78
77
|
* @param onDuplicate - Callback fired when Duplicate/Duplicate All is confirmed
|
|
79
78
|
* @param [onDecideForEach] - Callback fired when individual decisions are confirmed; receives array of decisions
|
|
80
79
|
* @param conflictingFiles - Array of files with name conflicts
|
|
81
|
-
* @param [title] - Custom title (overrides singleFileTitle and multipleFilesTitle)
|
|
82
80
|
* @param [singleFileTitle="Replace Or Duplicate Item"] - Title for single file conflicts
|
|
83
81
|
* @param [multipleFilesTitle="Replace Or Duplicate Items"] - Title for multiple file conflicts
|
|
84
82
|
* @param [message] - Custom message (overrides default conflict description)
|
|
@@ -11,7 +11,9 @@ export interface DestinationFolderPopupProps extends DialFileManagerProps {
|
|
|
11
11
|
addFolderLabel?: string;
|
|
12
12
|
hiddenFilesSwitcherLabel?: string;
|
|
13
13
|
mode?: 'copy' | 'move';
|
|
14
|
-
|
|
14
|
+
header?: ReactNode;
|
|
15
|
+
sourceFolder?: string;
|
|
16
|
+
disabledPathTooltip?: string;
|
|
15
17
|
}
|
|
16
18
|
/**
|
|
17
19
|
* DestinationFolderPopup
|
|
@@ -48,5 +50,7 @@ export interface DestinationFolderPopupProps extends DialFileManagerProps {
|
|
|
48
50
|
* @param rootItem - Root folder item
|
|
49
51
|
* @param path - Current path in the File Manager
|
|
50
52
|
* @param onPathChange - Callback fired when the path changes
|
|
53
|
+
* @param [sourceFolder] - The source folder path for move operations
|
|
54
|
+
* @param [disabledPathTooltip="Unavailable for the original path. Please select another folder"] - Tooltip text when destination is disabled
|
|
51
55
|
*/
|
|
52
56
|
export declare const DestinationFolderPopup: FC<DestinationFolderPopupProps>;
|
|
@@ -44,7 +44,7 @@ export interface DialFileManagerNavigationPanelProps extends Omit<DialBreadcrumb
|
|
|
44
44
|
* ```
|
|
45
45
|
*
|
|
46
46
|
* @param [ariaLabel="Breadcrumb"] - Aria label for the breadcrumb `<nav>`
|
|
47
|
-
* @param [
|
|
47
|
+
* @param [labelClassName] - Extra classes for breadcrumb titles
|
|
48
48
|
* @param [path] - A full path string that will be split into breadcrumb items
|
|
49
49
|
* @param [makeHref] - Factory to create hrefs for segments
|
|
50
50
|
* @param [onItemClick] - Callback fired when a breadcrumb item is clicked
|
|
@@ -1,10 +1,13 @@
|
|
|
1
1
|
export interface UseCurrentPathOptions {
|
|
2
2
|
path?: string;
|
|
3
|
+
defaultPath?: string;
|
|
3
4
|
onPathChange?: (nextPath?: string) => void;
|
|
4
5
|
onSelectionClear?: () => void;
|
|
5
6
|
}
|
|
6
|
-
|
|
7
|
-
currentPath
|
|
8
|
-
setCurrentPath:
|
|
7
|
+
interface UseCurrentPathResult {
|
|
8
|
+
currentPath?: string;
|
|
9
|
+
setCurrentPath: (nextPath?: string) => void;
|
|
9
10
|
handlePathChange: (nextPath?: string) => void;
|
|
10
|
-
}
|
|
11
|
+
}
|
|
12
|
+
export declare const useCurrentPath: ({ path, defaultPath, onPathChange, onSelectionClear, }: UseCurrentPathOptions) => UseCurrentPathResult;
|
|
13
|
+
export {};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
interface UsePathsSelectionParams {
|
|
2
|
+
selectedPaths?: Set<string>;
|
|
3
|
+
defaultSelectedPaths?: Set<string>;
|
|
4
|
+
onSelectedPathsChange?: (paths: Set<string>) => void;
|
|
5
|
+
}
|
|
6
|
+
interface UsePathsSelectionResult {
|
|
7
|
+
selectedPaths: Set<string>;
|
|
8
|
+
setSelectedPaths: (paths: Set<string>) => void;
|
|
9
|
+
clearSelection: () => void;
|
|
10
|
+
isControlled: boolean;
|
|
11
|
+
}
|
|
12
|
+
export declare function usePathsSelection({ selectedPaths, defaultSelectedPaths, onSelectedPathsChange, }: UsePathsSelectionParams): UsePathsSelectionResult;
|
|
13
|
+
export {};
|
|
@@ -20,13 +20,13 @@ export interface DialFormPopupProps extends DialPopupProps {
|
|
|
20
20
|
* ```tsx
|
|
21
21
|
* <DialFormPopup
|
|
22
22
|
* open
|
|
23
|
-
*
|
|
23
|
+
* header="Create Model"
|
|
24
24
|
* onClose={() => setOpen(false)}
|
|
25
25
|
* onSubmit={handleSubmit}
|
|
26
26
|
* />
|
|
27
27
|
* ```
|
|
28
28
|
*
|
|
29
|
-
* @param
|
|
29
|
+
* @param header - Title content for the header
|
|
30
30
|
* @param [open=false] - Controls visibility of the popup
|
|
31
31
|
* @param [submitLabel="Submit"] - Label for the primary action button
|
|
32
32
|
* @param [cancelLabel="Cancel"] - Label for the cancel button
|
|
@@ -18,7 +18,7 @@ export interface DialLabelledTextProps {
|
|
|
18
18
|
* />
|
|
19
19
|
* ```
|
|
20
20
|
*
|
|
21
|
-
* @param label - The main label text for the field
|
|
21
|
+
* @param [label] - The main label text for the field
|
|
22
22
|
* @param [text] - Optional tooltip and secondary text
|
|
23
23
|
* @param [tooltip] - Optional tooltip different from main text
|
|
24
24
|
* @param [children] - Custom content to render instead of the default text/tooltip
|
|
@@ -2,7 +2,7 @@ import { FC, MouseEvent, ReactNode } from 'react';
|
|
|
2
2
|
import { PopupSize } from '../../types/popup';
|
|
3
3
|
export interface DialPopupProps {
|
|
4
4
|
open?: boolean;
|
|
5
|
-
|
|
5
|
+
header?: ReactNode;
|
|
6
6
|
portalId?: string;
|
|
7
7
|
className?: string;
|
|
8
8
|
overlayClassName?: string;
|
|
@@ -40,7 +40,7 @@ export interface DialPopupProps {
|
|
|
40
40
|
* ```
|
|
41
41
|
*
|
|
42
42
|
* @param [open=false] - Controls visibility of the popup
|
|
43
|
-
* @param [
|
|
43
|
+
* @param [header] - Optional title rendered in the header
|
|
44
44
|
* @param [portalId] - Optional portal container id
|
|
45
45
|
* @param [className] - Additional CSS classes applied to the popup container
|
|
46
46
|
* @param [overlayClassName] - Additional CSS classes applied to the overlay
|
|
@@ -2,7 +2,7 @@ import { FC, ReactNode } from 'react';
|
|
|
2
2
|
export interface DialRadioButtonProps {
|
|
3
3
|
name: string;
|
|
4
4
|
value: string;
|
|
5
|
-
|
|
5
|
+
label?: ReactNode;
|
|
6
6
|
description?: ReactNode;
|
|
7
7
|
checked?: boolean;
|
|
8
8
|
inputId: string;
|
|
@@ -33,7 +33,7 @@ export interface DialRadioButtonProps {
|
|
|
33
33
|
*
|
|
34
34
|
* @param name - Radio group name
|
|
35
35
|
* @param value - Radio value emitted on change
|
|
36
|
-
* @param [
|
|
36
|
+
* @param [label] - Visible label text
|
|
37
37
|
* @param [description] - Supporting text shown when checked
|
|
38
38
|
* @param [checked=false] - Controlled checked state
|
|
39
39
|
* @param inputId - ID associated with the label
|
|
@@ -5,7 +5,7 @@ import { DialRadioGroupProps } from '../RadioGroup/RadioGroup';
|
|
|
5
5
|
import { DialPopupProps } from '../Popup/Popup';
|
|
6
6
|
export interface RadioGroupPopupFieldProps extends Pick<DialFieldLabelProps, 'fieldTitle' | 'htmlFor'>, Omit<DialInputPopupProps, 'onOpen' | 'children'>, Pick<DialRadioGroupProps, 'radioButtons'>, Pick<DialPopupProps, 'onClose' | 'portalId' | 'size'> {
|
|
7
7
|
customInputValue?: string;
|
|
8
|
-
|
|
8
|
+
header: string;
|
|
9
9
|
cancelButtonTitle?: string;
|
|
10
10
|
applyButtonTitle?: string;
|
|
11
11
|
isValid: boolean;
|
|
@@ -29,7 +29,7 @@ export interface RadioGroupPopupFieldProps extends Pick<DialFieldLabelProps, 'fi
|
|
|
29
29
|
* <DialRadioGroupPopupField
|
|
30
30
|
* fieldTitle="Status"
|
|
31
31
|
* htmlFor="status"
|
|
32
|
-
*
|
|
32
|
+
* header="Select status"
|
|
33
33
|
* emptyValueText="None"
|
|
34
34
|
* radioButtons={[
|
|
35
35
|
* { id: 'draft', name: 'Draft' },
|
|
@@ -55,7 +55,7 @@ export interface RadioGroupPopupFieldProps extends Pick<DialFieldLabelProps, 'fi
|
|
|
55
55
|
* @param [inputClassName] - Extra classes applied to the collapsed input container
|
|
56
56
|
* @param emptyValueText - Placeholder text when no value is selected
|
|
57
57
|
* @param [onClose] - Callback fired when the popup closes
|
|
58
|
-
* @param
|
|
58
|
+
* @param header - Title text shown in the popup header
|
|
59
59
|
* @param [portalId] - Target portal id for rendering the popup
|
|
60
60
|
* @param onApply - Callback fired when the Apply button is clicked
|
|
61
61
|
* @param [cancelButtonTitle="Cancel"] - Text for the Cancel button
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { FC, ReactNode } from 'react';
|
|
2
2
|
export interface DialSwitchProps {
|
|
3
|
-
|
|
3
|
+
label?: ReactNode;
|
|
4
4
|
switchId: string;
|
|
5
5
|
isOn?: boolean;
|
|
6
6
|
disabled?: boolean;
|
|
@@ -13,7 +13,7 @@ export interface DialSwitchProps {
|
|
|
13
13
|
* ```tsx
|
|
14
14
|
* <DialSwitch
|
|
15
15
|
* switchId="switch"
|
|
16
|
-
*
|
|
16
|
+
* label="Toggle"
|
|
17
17
|
* isOn={true}
|
|
18
18
|
* disabled={false}
|
|
19
19
|
* onChange={(value) => console.log(value)}
|
|
@@ -12,7 +12,7 @@ export declare enum FormItemOrientation {
|
|
|
12
12
|
/**
|
|
13
13
|
* Base properties for form item components providing layout, labeling, and validation display
|
|
14
14
|
*
|
|
15
|
-
* @param label - The label text or element to display for the form item
|
|
15
|
+
* @param [label] - The label text or element to display for the form item
|
|
16
16
|
* @param optional - Whether the field is optional (displays optional indicator)
|
|
17
17
|
* @param optionalText - Custom text to display for optional fields (default: "(Optional)")
|
|
18
18
|
* @param description - Description text to display below the label
|