@epam/ai-dial-ui-kit 0.4.0-rc.5 → 0.4.0-rc.51

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.
Files changed (68) hide show
  1. package/dist/dial-ui-kit.cjs.js +28 -28
  2. package/dist/dial-ui-kit.es.js +8941 -7854
  3. package/dist/index.css +2 -2
  4. package/dist/src/components/AutocompleteInput/AutocompleteInputValue.d.ts +2 -0
  5. package/dist/src/components/Breadcrumb/BreadcrumbItem.d.ts +2 -2
  6. package/dist/src/components/Breadcrumb/constants.d.ts +4 -1
  7. package/dist/src/components/Checkbox/Checkbox.d.ts +2 -2
  8. package/dist/src/components/CollapsibleSidebar/CollapsibleSidebar.d.ts +7 -3
  9. package/dist/src/components/FileManager/FileManager.d.ts +47 -14
  10. package/dist/src/components/FileManager/FileManagerContext.d.ts +56 -0
  11. package/dist/src/components/FileManager/FileManagerProvider.d.ts +17 -0
  12. package/dist/src/components/FileManager/components/FileManagerBulkActionsToolbar/FileManagerBulkActionsToolbar.d.ts +53 -0
  13. package/dist/src/components/FileManager/components/FileManagerBulkActionsToolbar/constants.d.ts +3 -0
  14. package/dist/src/components/FileManager/components/FileManagerItemIcon/FileManagerItemIcon.d.ts +46 -0
  15. package/dist/src/components/FileManager/components/FileManagerItemName/FileManagerItemName.d.ts +48 -0
  16. package/dist/src/components/FileManager/components/FileManagerItemNameInput/FileManagerItemNameInput.d.ts +65 -0
  17. package/dist/src/components/FileManager/components/FileManagerToolbar/DialFileManagerToolbar.d.ts +27 -24
  18. package/dist/src/components/FileManager/components/FoldersTree/FoldersTree.d.ts +23 -3
  19. package/dist/src/components/FileManager/constants.d.ts +1 -1
  20. package/dist/src/components/FileManager/hooks/__tests__/use-current-path.spec.d.ts +1 -0
  21. package/dist/src/components/FileManager/hooks/__tests__/use-file-clipboard.spec.d.ts +1 -0
  22. package/dist/src/components/FileManager/hooks/__tests__/use-show-hidden-files.spec.d.ts +1 -0
  23. package/dist/src/components/FileManager/hooks/use-collapse-tree.d.ts +9 -0
  24. package/dist/src/components/FileManager/hooks/use-current-path.d.ts +10 -0
  25. package/dist/src/components/FileManager/hooks/use-file-clipboard.d.ts +20 -0
  26. package/dist/src/components/FileManager/hooks/use-file-manager-context.d.ts +5 -0
  27. package/dist/src/components/FileManager/hooks/use-item-renaming.d.ts +13 -0
  28. package/dist/src/components/FileManager/hooks/use-show-hidden-files.d.ts +5 -0
  29. package/dist/src/components/FileManager/utils.d.ts +1 -0
  30. package/dist/src/components/Grid/Grid.d.ts +9 -1
  31. package/dist/src/components/Grid/comparators/base-column-comparator.spec.d.ts +1 -0
  32. package/dist/src/components/Grid/constants.d.ts +0 -1
  33. package/dist/src/components/Grid/renderers/DateCellRenderer.d.ts +32 -0
  34. package/dist/src/components/Grid/renderers/constants.d.ts +3 -0
  35. package/dist/src/components/Grid/renderers/utils.d.ts +2 -0
  36. package/dist/src/components/Grid/renderers/utils.spec.d.ts +1 -0
  37. package/dist/src/components/Input/Input.d.ts +4 -1
  38. package/dist/src/components/InputPopup/InputPopup.d.ts +6 -2
  39. package/dist/src/components/NoDataContent/NoDataContent.d.ts +3 -0
  40. package/dist/src/components/Search/Search.d.ts +2 -0
  41. package/dist/src/components/Select/MultiSelectTags.d.ts +2 -2
  42. package/dist/src/components/Select/Select.d.ts +7 -0
  43. package/dist/src/components/Select/constants.d.ts +1 -1
  44. package/dist/src/components/SelectField/SelectField.d.ts +5 -0
  45. package/dist/src/components/Steps/tests/utils.spec.d.ts +1 -0
  46. package/dist/src/components/Tab/Tab.d.ts +1 -4
  47. package/dist/src/components/Tabs/Tabs.d.ts +27 -14
  48. package/dist/src/components/Tag/Tag.d.ts +2 -2
  49. package/dist/src/components/Tooltip/Tooltip.d.ts +2 -2
  50. package/dist/src/components/Tooltip/TooltipContent.d.ts +5 -2
  51. package/dist/src/components/Tooltip/TooltipTrigger.d.ts +6 -4
  52. package/dist/src/hooks/use-editable-item.d.ts +64 -0
  53. package/dist/src/hooks/use-flexible-actions.d.ts +86 -0
  54. package/dist/src/hooks/use-is-mobile-screen.d.ts +15 -0
  55. package/dist/src/hooks/use-screen-type.d.ts +19 -0
  56. package/dist/src/index.d.ts +10 -4
  57. package/dist/src/models/dropdown.d.ts +2 -2
  58. package/dist/src/models/select.d.ts +1 -0
  59. package/dist/src/models/tab.d.ts +1 -0
  60. package/dist/src/types/file-manager.d.ts +13 -0
  61. package/dist/src/types/flexible-actions.d.ts +4 -0
  62. package/dist/src/types/item.d.ts +4 -0
  63. package/dist/src/types/screen.d.ts +6 -0
  64. package/dist/src/types/select.d.ts +8 -0
  65. package/dist/src/types/tab.d.ts +4 -0
  66. package/dist/src/utils/merge-classes.spec.d.ts +1 -0
  67. package/dist/src/utils/mobile.d.ts +35 -0
  68. package/package.json +8 -8
@@ -8,6 +8,8 @@ export interface DialFileManagerToolbarProps {
8
8
  activeTab?: string;
9
9
  areHiddenFilesVisible: boolean;
10
10
  hiddenFilesSwitcherLabel?: string;
11
+ showHiddenFilesLabel?: string;
12
+ hideHiddenFilesLabel?: string;
11
13
  isCreateButtonVisible?: boolean;
12
14
  createButtonVariant?: ButtonVariant;
13
15
  createButtonDropdownItems?: DropdownItem[];
@@ -18,18 +20,16 @@ export interface DialFileManagerToolbarProps {
18
20
  onRefresh?: () => void;
19
21
  }
20
22
  /**
21
- * DialFileManagerToolbar — A configurable toolbar component for file manager views.
23
+ * DialFileManagerToolbar — A configurable, responsive toolbar component for file management views.
22
24
  *
23
- * Provides a clean and functional toolbar for file management pages with:
24
- * - Tab navigation for switching between different sections or views
25
- * - Hidden files toggle via `DialSwitch`
26
- * - Refresh button with icon
27
- * - Optional "Create" button or dropdown for file/folder creation
28
- * - Fully responsive horizontal layout
25
+ * Provides a flexible toolbar interface for file managers or similar UIs, supporting:
26
+ * - Tab navigation for switching between file sections or views
27
+ * - A toggle for showing or hiding hidden files
28
+ * - A refresh button for reloading content
29
+ * - An optional "Create" button or dropdown for creating new files or folders
29
30
  *
30
31
  * @example
31
32
  * ```tsx
32
- * // Basic usage
33
33
  * const tabs: TabModel[] = [
34
34
  * { id: 'all', name: 'All Files' },
35
35
  * { id: 'favorites', name: 'Favorites' },
@@ -40,8 +40,8 @@ export interface DialFileManagerToolbarProps {
40
40
  * activeTab="all"
41
41
  * areHiddenFilesVisible={false}
42
42
  * onTabChange={(id) => console.log('Switched to tab:', id)}
43
- * onToggleHiddenFiles={(visible) => console.log('Hidden files:', visible)}
44
- * onRefresh={() => console.log('Refreshing...')}
43
+ * onToggleHiddenFiles={(visible) => console.log('Hidden files visible:', visible)}
44
+ * onRefresh={() => console.log('Refreshed')}
45
45
  * isCreateButtonVisible
46
46
  * createButtonDropdownItems={[
47
47
  * { key: 'folder', label: 'New Folder' },
@@ -50,23 +50,26 @@ export interface DialFileManagerToolbarProps {
50
50
  * />
51
51
  * ```
52
52
  *
53
- * @param [tabs] - Array of tabs to display, each defined by a `TabModel` (id and label).
54
- * @param [activeTab] - ID of the currently active tab.
55
- * @param [onTabChange] - Callback fired when the user selects a different tab.
56
- * @param [areHiddenFilesVisible] - Indicates whether hidden files are currently visible.
57
- * @param [onToggleHiddenFiles] - Callback fired when the hidden files toggle is switched.
58
- * @param [hiddenFilesSwitcherLabel='Hidden files'] - Label text for the hidden files toggle switch.
53
+ * @param [tabs] - List of tab definitions to display, each represented by a `TabModel` containing `id` and `name`.
54
+ * @param [activeTab] - The ID of the currently active tab.
55
+ * @param areHiddenFilesVisible - Whether hidden files are currently visible.
56
+ * @param [hiddenFilesSwitcherLabel='Hidden files'] - Label for the hidden files toggle control.
57
+ * @param [showHiddenFilesLabel='Show hidden'] - Label shown when hidden files are not visible.
58
+ * @param [hideHiddenFilesLabel='Hide hidden'] - Label shown when hidden files are visible.
59
+ * @param [onTabChange] - Callback fired when the user switches between tabs. Receives the selected tab ID.
60
+ * @param [onToggleHiddenFiles] - Callback fired when the hidden files visibility is toggled. Receives the new visibility state.
59
61
  * @param [onRefresh] - Callback fired when the refresh button is clicked.
60
- * @param [refreshButtonLabel='Refresh'] - Label for the refresh button.
61
- * @param [isCreateButtonVisible] - Whether the create button or dropdown should be visible.
62
+ * @param [refreshButtonLabel='Refresh'] - Text label for the refresh button.
63
+ * @param [isCreateButtonVisible] - Whether the "Create" button or dropdown should be displayed.
62
64
  * @param [createButtonVariant=ButtonVariant.Secondary] - Visual style variant for the create button.
63
- * @param [createButtonDropdownItems=[]] - Dropdown menu items for the create button (used when multiple creation options are available).
64
- * @param [createButtonLabel='Create'] - Label for the create button.
65
+ * @param [createButtonDropdownItems=[]] - Dropdown items available under the create button. If empty, a single create button is shown instead.
66
+ * @param [createButtonLabel='Create'] - Label text for the create button.
65
67
  *
66
68
  * @remarks
67
- * - The component is layout-flexible and designed for use inside file or asset management toolbars.
68
- * - Tabs are rendered using `DialTabs`, and actions use `DialButton`, `DialSwitch`, and `DialButtonDropdown`.
69
- * - The refresh and create actions are aligned on the right for intuitive placement.
70
- * - When `createButtonDropdownItems` is empty, the create button behaves as a single-action button.
69
+ * - Tabs are rendered via `DialTabs`.
70
+ * - The hidden files toggle uses `DialSwitch`.
71
+ * - The refresh and create actions use `DialButton` or dropdown variants for consistency.
72
+ * - The toolbar automatically adapts its layout for different screen sizes.
73
+ * - When `createButtonDropdownItems` is provided, the create button becomes a dropdown menu.
71
74
  */
72
75
  export declare const DialFileManagerToolbar: FC<DialFileManagerToolbarProps>;
@@ -6,12 +6,17 @@ export interface DialFoldersTreeProps {
6
6
  expandedPaths?: Set<string>;
7
7
  loadingPaths?: Set<string>;
8
8
  selectedPath?: string;
9
+ renamedPath?: string;
9
10
  showFiles?: boolean;
10
11
  emptyStateTitle?: string;
11
12
  emptyStateDescription?: string;
12
13
  emptyStateIcon?: ReactNode;
13
14
  onItemClick?: (item: DialFile) => void;
15
+ onRenameSave?: (value: string) => void;
16
+ onRenameCancel?: () => void;
17
+ onRenameValidate?: (value: string, item: DialFile) => string | null;
14
18
  getContextMenuItems?: (item: DialFile) => DropdownItem[];
19
+ areHiddenFilesVisible?: boolean;
15
20
  }
16
21
  /**
17
22
  * DialFoldersTree — A hierarchical folder tree component with nested expand/collapse support, selection highlighting,
@@ -21,6 +26,7 @@ export interface DialFoldersTreeProps {
21
26
  * - Expandable and collapsible items
22
27
  * - Optional file visibility
23
28
  * - Loading state indicators for specific paths
29
+ * - Inline renaming support for folders or files
24
30
  * - Multi-item selection highlighting
25
31
  * - Context menu integration via `DialDropdown`
26
32
  * - Recursive rendering with indentation and icons
@@ -48,15 +54,23 @@ export interface DialFoldersTreeProps {
48
54
  *
49
55
  * // With expanded and selected items
50
56
  * const expandedPaths = new Set(['/documents']);
51
- * const selectedPaths = new Set(['/documents/file.txt']);
52
57
  *
53
58
  * <DialFoldersTree
54
59
  * items={items}
55
60
  * expandedPaths={expandedPaths}
56
- * selectedPaths={selectedPaths}
61
+ * selectedPath="/documents/file.txt"
57
62
  * onItemClick={(item) => console.log('Clicked:', item.path)}
58
63
  * />
59
64
  *
65
+ * // With inline renaming and validation
66
+ * <DialFoldersTree
67
+ * items={items}
68
+ * renamedPath="/documents"
69
+ * onRenameValidate={(value) => (value.trim() ? null : 'Name cannot be empty')}
70
+ * onRenameSave={(newValue) => console.log('Saved new name:', newValue)}
71
+ * onRenameCancel={() => console.log('Edit cancelled')}
72
+ * />
73
+ *
60
74
  * // With custom empty state and context menu
61
75
  * const getContextMenuItems = (item: DialFile): DropdownItem[] => [
62
76
  * { key: 'rename', label: 'Rename' },
@@ -76,16 +90,22 @@ export interface DialFoldersTreeProps {
76
90
  * @param [expandedPaths] - Set of folder paths that should be expanded.
77
91
  * @param [loadingPaths] - Set of folder paths currently loading (shows spinner or placeholder).
78
92
  * @param [selectedPath] - Path representing the currently selected folder or file.
93
+ * @param [renamedPath] - Path of the folder or file currently being edited.
79
94
  * @param [showFiles=false] - Whether to show files in addition to folders.
80
95
  * @param [emptyStateTitle='No Folders'] - Title text displayed when there are no items.
81
96
  * @param [emptyStateDescription] - Optional description text for the empty state.
82
97
  * @param [emptyStateIcon] - Optional icon to display in the empty state.
83
98
  * @param [onItemClick] - Callback fired when a folder or file is clicked (receives the corresponding `DialFile` node).
99
+ * @param [onRenameSave] - Callback fired when editing is confirmed with a valid name (receives the new name).
100
+ * @param [onRenameCancel] - Callback fired when editing is cancelled.
101
+ * @param [onRenameValidate] - Function to validate the new name during editing. Should return an error string or `null` if valid.
84
102
  * @param [getContextMenuItems] - Function returning context menu items for a given node.
103
+ * @param [areHiddenFilesVisible=false] - Whether hidden files (dotfiles) should be visible in the tree.
85
104
  *
86
105
  * @remarks
87
106
  * - Folder and file data must follow the `DialFile` model.
88
- * - The `expandedPaths`, `loadingPaths`, and `selectedPaths` props are externally controlled; the component itself does not manage them internally.
107
+ * - The `expandedPaths`, `loadingPaths`, `selectedPath`, and `renamedPath` props are externally controlled.
108
+ * - Inline renaming is fully customizable using `onRenameSave`, `onRenameCancel`, and `onRenameValidate`.
89
109
  * - Context menus can be attached to both folders and files using `getContextMenuItems`.
90
110
  * - Use `showFiles={false}` to render only folders for a simplified tree.
91
111
  */
@@ -5,5 +5,5 @@ export declare const contentGridClasses = "flex flex-col flex-1 min-h-0 min-w-0
5
5
  export declare const contentHeaderClasses = "items-center";
6
6
  export declare const treeBaseClasses = "w-full h-full rounded bg-layer-3 text-secondary overflow-auto min-w-0";
7
7
  export declare const gridBaseClasses = "flex-1 w-full rounded text-secondary overflow-auto min-h-0 min-w-0";
8
- export declare const sidebarWidth = 360;
8
+ export declare const sidebarWidth = 280;
9
9
  export declare const sidebarTitleDefault = "Files";
@@ -0,0 +1,9 @@
1
+ export interface UseCollapseTreeOptions {
2
+ collapsed?: boolean;
3
+ onCollapseChange?: (collapsed: boolean) => void;
4
+ }
5
+ export declare const useCollapseTree: (options?: UseCollapseTreeOptions) => {
6
+ isTreeCollapsed: boolean;
7
+ toggleTreeCollapse: () => void;
8
+ setIsTreeCollapsed: (value: boolean) => void;
9
+ };
@@ -0,0 +1,10 @@
1
+ export interface UseCurrentPathOptions {
2
+ path?: string;
3
+ onPathChange?: (nextPath?: string) => void;
4
+ onSelectionClear?: () => void;
5
+ }
6
+ export declare const useCurrentPath: ({ path, onPathChange, onSelectionClear, }: UseCurrentPathOptions) => {
7
+ currentPath: string | undefined;
8
+ setCurrentPath: import('react').Dispatch<import('react').SetStateAction<string | undefined>>;
9
+ handlePathChange: (nextPath?: string) => void;
10
+ };
@@ -0,0 +1,20 @@
1
+ import { DialFile } from '../../../models/file';
2
+ import { DialCopiedItem } from '../../../types/file-manager';
3
+ export interface UseFileClipboardOptions {
4
+ getDestination: () => string;
5
+ getDestinationFiles: () => DialFile[];
6
+ getSourceFiles: () => DialFile[];
7
+ onCopyFiles?: (items: DialCopiedItem[]) => void;
8
+ onMoveToFiles?: (items: DialCopiedItem[]) => void;
9
+ }
10
+ export declare const useFileClipboard: ({ getDestination, getDestinationFiles, getSourceFiles, onCopyFiles, onMoveToFiles, }: UseFileClipboardOptions) => {
11
+ state: {
12
+ copied: Set<string>;
13
+ cut: Set<string>;
14
+ hasItems: boolean;
15
+ };
16
+ copy: (files: string[]) => void;
17
+ cut: (files: string[]) => void;
18
+ paste: (overwrite?: boolean) => void;
19
+ clear: () => void;
20
+ };
@@ -0,0 +1,5 @@
1
+ /**
2
+ * Hook to read the File Manager context.
3
+ * Throws if used outside of the provider.
4
+ */
5
+ export declare const useFileManagerContext: () => import('../FileManagerContext').FileManagerContextValue;
@@ -0,0 +1,13 @@
1
+ import { DialFile } from '../../../models/file';
2
+ export declare const useItemRenaming: ({ onRename, onRenameSave, onRenameCancel, onRenameValidate, }: {
3
+ onRename?: (path: string) => void;
4
+ onRenameSave?: (value: string) => void;
5
+ onRenameCancel?: () => void;
6
+ onRenameValidate?: (value: string, item: DialFile) => string | null;
7
+ }) => {
8
+ renamedPath: string | undefined;
9
+ renameHandler: (path: string) => void;
10
+ renameSaveHandler: (value: string) => void;
11
+ renameCancelHandler: () => void;
12
+ renameValidateHandler: (value: string, item: DialFile) => string | null;
13
+ };
@@ -0,0 +1,5 @@
1
+ export declare const useShowHiddenFiles: (initialState?: boolean) => {
2
+ areHiddenFilesVisible: boolean;
3
+ toggleHiddenFilesVisibility: () => void;
4
+ setAreHiddenFilesVisible: import('react').Dispatch<import('react').SetStateAction<boolean>>;
5
+ };
@@ -3,3 +3,4 @@ export declare const findFolderForPath: (root: DialFile[] | undefined, path?: st
3
3
  export declare const normalizeToLowerCase: (input?: string) => string;
4
4
  export declare const normalizeExtensionWithoutDot: (input?: string) => string;
5
5
  export declare const collectAllDescendants: (folder?: DialFile) => DialFile[];
6
+ export declare const isHiddenDotFile: (node: DialFile) => boolean;
@@ -1,4 +1,5 @@
1
1
  import { ColDef, GridOptions } from 'ag-grid-community';
2
+ import { ReactNode } from 'react';
2
3
  import { DropdownItem } from '../../models/dropdown';
3
4
  export interface DialGridProps<T extends object = Record<string, unknown>> {
4
5
  columnDefs?: ColDef<T>[];
@@ -14,6 +15,9 @@ export interface DialGridProps<T extends object = Record<string, unknown>> {
14
15
  getRowId?: (row: T) => string;
15
16
  alternateOddRowColors?: boolean;
16
17
  filterPlaceholder?: string;
18
+ emptyStateIcon?: ReactNode;
19
+ emptyStateTitle?: string;
20
+ emptyStateDescription?: string;
17
21
  }
18
22
  /**
19
23
  * DialGrid — A feature-rich data grid wrapper built on ag-Grid with dark theme support.
@@ -86,5 +90,9 @@ export interface DialGridProps<T extends object = Record<string, unknown>> {
86
90
  * @param [getRowId] - Function to extract unique ID from a row object (defaults to 'id' field)
87
91
  * @param [alternateOddRowColors=false] - Whether to alternate background colors for odd/even rows
88
92
  * @param [filterPlaceholder='Enter value'] - Placeholder text for column filter inputs
93
+ * @param [emptyStateIcon] - Optional icon for empty state
94
+ * @param [emptyStateTitle] - Optional title text displayed when the grid has no rows to show.
95
+ * @param [emptyStateDescription] - Optional description text displayed below the empty state title,
96
+ * providing additional context or instructions (e.g., “No data found” or “Try adjusting your filters”).
89
97
  */
90
- export declare const DialGrid: <T extends object>({ columnDefs, rowData, additionalGridOptions, getContextMenuItems, cssClass, ariaLabel, withSelectionColumn, wrapCustomCellRenderers, selectedRowIds, onSelectionChange, getRowId, alternateOddRowColors, filterPlaceholder, }: DialGridProps<T>) => import("react/jsx-runtime").JSX.Element;
98
+ export declare const DialGrid: <T extends object>({ columnDefs, rowData, additionalGridOptions, getContextMenuItems, cssClass, ariaLabel, withSelectionColumn, wrapCustomCellRenderers, selectedRowIds, onSelectionChange, getRowId, alternateOddRowColors, filterPlaceholder, emptyStateIcon, emptyStateTitle, emptyStateDescription, }: DialGridProps<T>) => import("react/jsx-runtime").JSX.Element;
@@ -18,7 +18,6 @@ export declare const GRID_THEME_COLORS: {
18
18
  fontFamily: {
19
19
  googleFont: string;
20
20
  };
21
- headerColumnBorderHeight: string;
22
21
  cellStyle: {
23
22
  textAlign: string;
24
23
  };
@@ -0,0 +1,32 @@
1
+ import { FC } from 'react';
2
+ import { ICellRendererParams } from 'ag-grid-community';
3
+ export type DateValue = string | number | Date;
4
+ export interface DialDateCellRendererProps extends Partial<ICellRendererParams<Record<string, unknown>, DateValue>> {
5
+ value?: DateValue | null;
6
+ locale?: string;
7
+ options?: Intl.DateTimeFormatOptions;
8
+ emptyPlaceholder?: string;
9
+ cssClass?: string;
10
+ }
11
+ /**
12
+ * Minimal date cell renderer (ag-Grid compatible).
13
+ *
14
+ * Renders the value in the **"MMM dd, yyyy"** format (e.g., "Jul 20, 2025"),
15
+ * wrapped in `DialEllipsisTooltip` (tooltip only appears if truncated).
16
+ *
17
+ * @example
18
+ * ```tsx
19
+ * // ag-Grid colDef
20
+ * { field: 'createdAt', cellRenderer: DateCellRenderer, cellRendererParams: { options: { timeZone: 'UTC' } } }
21
+ *
22
+ * // Direct usage
23
+ * <DateCellRenderer value="2025-07-20T00:00:00Z" options={{ timeZone: 'UTC' }} />
24
+ * <DateCellRenderer value={1752969600000} options={{ timeZone: 'UTC' }} /> // milliseconds
25
+ * ```
26
+ *
27
+ * @param [locale='en-US'] - Locale fixed to U.S. English by default to enforce "Jul 20, 2025".
28
+ * @param [options={ year: 'numeric', month: 'numeric', day: '2-digit', hour: '2-digit', minute: '2-digit', second: '2-digit', timeZone: 'UTC' }] - Options for date formatting (e.g., timeZone).
29
+ * @param [emptyPlaceholder='—'] - Placeholder when value is empty/invalid.
30
+ * @param [cssClass] - Additional classes merged into the wrapper.
31
+ */
32
+ export declare const DialDateCellRenderer: FC<DialDateCellRendererProps>;
@@ -0,0 +1,3 @@
1
+ export declare const DEFAULT_LOCALE = "en-US";
2
+ export declare const DEFAULT_DATE_FORMAT_OPTIONS: Intl.DateTimeFormatOptions;
3
+ export declare const dateCellBaseClasses = "text-primary";
@@ -0,0 +1,2 @@
1
+ import { DateValue } from './DateCellRenderer';
2
+ export declare function convertToDate(input?: DateValue | null): Date | null;
@@ -0,0 +1 @@
1
+ export {};
@@ -1,4 +1,4 @@
1
- import { FC, FocusEvent } from 'react';
1
+ import { FC, FocusEvent, Ref } from 'react';
2
2
  import { InputBaseProps, NumberInputBaseProps } from '../../models/field-control-props';
3
3
  export interface DialInputProps extends InputBaseProps, Partial<NumberInputBaseProps> {
4
4
  type?: string;
@@ -7,6 +7,8 @@ export interface DialInputProps extends InputBaseProps, Partial<NumberInputBaseP
7
7
  hideBorder?: boolean;
8
8
  tooltipText?: string;
9
9
  tooltipTriggerClassName?: string;
10
+ hideTooltip?: boolean;
11
+ inputRef?: Ref<HTMLInputElement>;
10
12
  onChange?: (value?: string) => void;
11
13
  onBlur?: (event: FocusEvent<HTMLInputElement, Element>) => void;
12
14
  }
@@ -34,6 +36,7 @@ export interface DialInputProps extends InputBaseProps, Partial<NumberInputBaseP
34
36
  * @param hideBorder - Whether to hide the input border styling
35
37
  * @param tooltipText - The text to display inside the tooltip. If empty, the tooltip will display the value prop.
36
38
  * @param tooltipTriggerClassName - Additional CSS classes to apply to the tooltip
39
+ * @param hideTooltip - Whether to hide the tooltip
37
40
  * @param onChange - Callback function called when the input value changes
38
41
  * @param onBlur - Callback function called when the input blurs
39
42
  */
@@ -7,9 +7,11 @@ export interface DialInputPopupProps {
7
7
  disabled?: boolean;
8
8
  valueCssClasses?: string;
9
9
  inputCssClasses?: string;
10
+ placeholder?: string;
10
11
  elementId?: string;
11
12
  errorText?: string;
12
- emptyValueText: string;
13
+ invalid?: boolean;
14
+ emptyValueText?: string;
13
15
  }
14
16
  /**
15
17
  * An input field that opens a popup when clicked, displaying a selected value or a list of values.
@@ -35,6 +37,7 @@ export interface DialInputPopupProps {
35
37
  *
36
38
  * @param [open] - The current state of the modal, indicating whether it is opened or closed.
37
39
  * @param [selectedValue] - The currently selected value(s). Can be a string for a single value or an array of strings for multiple values.
40
+ * @param [placeholder] - Placeholder text displayed when no value is selected.
38
41
  * @param children - The content to render inside the modal when it is opened.
39
42
  * @param onOpen - A callback function triggered when the modal open button is clicked.
40
43
  * @param [disabled=false] - Whether the input is disabled, preventing user interaction.
@@ -42,6 +45,7 @@ export interface DialInputPopupProps {
42
45
  * @param [inputCssClasses] - Additional CSS classes applied to the input container.
43
46
  * @param [elementId] - A unique identifier for the input element, useful for accessibility and testing.
44
47
  * @param [errorText] - An optional error message displayed below the input when an error state is present.
45
- * @param emptyValueText - The text displayed when no value is selected.
48
+ * @param [invalid] - Whether the input is in an invalid state, affecting styling. Applyed automatically if errorText is provided.
49
+ * @param [emptyValueText] - The text displayed when no value is selected and placeholder is not provided.
46
50
  */
47
51
  export declare const DialInputPopup: FC<DialInputPopupProps>;
@@ -3,6 +3,9 @@ export interface DialNoDataContentProps {
3
3
  icon?: ReactNode;
4
4
  title: string;
5
5
  description?: string;
6
+ containerCssClass?: string;
7
+ titleCssClass?: string;
8
+ descriptionCssClass?: string;
6
9
  }
7
10
  /**
8
11
  * A component for displaying a message and icon when there is no data to show.
@@ -11,6 +11,7 @@ export interface DialSearchProps {
11
11
  containerCssClass?: string;
12
12
  onChange?: (value: string) => void;
13
13
  size?: SearchSize;
14
+ allowClear?: boolean;
14
15
  }
15
16
  /**
16
17
  * A search input component with a customizable placeholder, icons, flexible props, and the ability
@@ -38,5 +39,6 @@ export interface DialSearchProps {
38
39
  * @param [containerCssClass] - Additional CSS classes applied to the container
39
40
  * @param [onChange] - Callback fired when the input value changes
40
41
  * @param [size=SearchSize.Base] - The size of the search input. Uses the {@link SearchSize} enum.
42
+ * @param [allowClear=true] - Whether to show a clear button when there is a value
41
43
  */
42
44
  export declare const DialSearch: FC<DialSearchProps>;
@@ -1,8 +1,8 @@
1
1
  import { SelectOption } from '../../models/select';
2
- import { MouseEvent } from 'react';
2
+ import { FC, MouseEvent } from 'react';
3
3
  export interface DialMultiSelectTagsProps {
4
4
  options: SelectOption[];
5
5
  selectedValues: string[];
6
6
  handleRemoveTag?: (event: MouseEvent<HTMLButtonElement, globalThis.MouseEvent>, val: string) => void;
7
7
  }
8
- export declare const DialMultiSelectTags: React.FC<DialMultiSelectTagsProps>;
8
+ export declare const DialMultiSelectTags: FC<DialMultiSelectTagsProps>;
@@ -1,9 +1,13 @@
1
1
  import { FC, ReactNode, MouseEvent } from 'react';
2
2
  import { SelectOption } from '../../models/select';
3
+ import { SelectSize, SelectVariant } from '../../types/select';
3
4
  export interface DialSelectProps {
4
5
  options: SelectOption[];
5
6
  multiple?: boolean;
7
+ size?: SelectSize;
8
+ variant?: SelectVariant;
6
9
  value?: string | string[];
10
+ prefix?: string;
7
11
  defaultValue?: string | string[];
8
12
  placeholder?: string;
9
13
  searchable?: boolean;
@@ -16,6 +20,8 @@ export interface DialSelectProps {
16
20
  disabled?: boolean;
17
21
  cssClass?: string;
18
22
  closable?: boolean;
23
+ header?: ReactNode | (() => ReactNode);
24
+ footer?: ReactNode | (() => ReactNode);
19
25
  onClose?: (e: MouseEvent<HTMLButtonElement>) => void;
20
26
  onChange?: (next: string | string[]) => void;
21
27
  }
@@ -43,6 +49,7 @@ export interface DialSelectProps {
43
49
  * @param options - Array of options to select from.
44
50
  * @param [multiple] - Whether multiple selections are allowed.
45
51
  * @param [value] - Controlled selected value(s).
52
+ * @param [prefix] - Prefix for selected value(s).
46
53
  * @param [defaultValue] - Uncontrolled initial selected value(s).
47
54
  * @param [placeholder] - Placeholder text when no selection is made.
48
55
  * @param [searchable] - Whether to show a search input to filter options.
@@ -1,4 +1,4 @@
1
- export declare const selectTriggerBaseClasses = "dial-input flex px-3 py-2 w-full items-center justify-between gap-2 dial-small min-h-[38px]";
1
+ export declare const selectTriggerBaseClasses = "dial-input flex w-full items-center justify-between gap-2 dial-small";
2
2
  export declare const selectOverlayBaseClasses = "w-full rounded";
3
3
  export declare const selectOptionBaseClasses = "flex w-full items-center justify-between gap-2 px-3 h-[34px] dial-small text-primary truncate hover:bg-accent-primary-alpha focus:bg-accent-primary-alpha focus:outline-none";
4
4
  export declare const selectOptionSelectedClasses = "bg-accent-primary-alpha";
@@ -25,6 +25,11 @@ export interface DialSelectFieldProps extends Omit<DialSelectProps, 'cssClass'>,
25
25
  * onChange={(v) => setTransport(v as string)}
26
26
  * />
27
27
  *
28
+ * @params - Component properties extending:
29
+ * - {@link DialSelectProps} for select options and props, except for cssClass
30
+ * - {@link DialFormItemProps} for form item props, except for htmlFor
31
+ * - {@link DialFieldLabelProps} for label props, except for label, children, value
32
+ *
28
33
  * @param selectCssClass CSS class for the select element
29
34
  * @param containerCssClass CSS class for the form item container
30
35
  * @param emptyStateTitle Title to show when there are no options
@@ -0,0 +1 @@
1
+ export {};
@@ -3,7 +3,6 @@ import { FC } from 'react';
3
3
  export interface DialTabProps {
4
4
  tab: TabModel;
5
5
  active: boolean;
6
- disabled?: boolean;
7
6
  invalid?: boolean;
8
7
  horizontal?: boolean;
9
8
  cssClass?: string;
@@ -24,10 +23,8 @@ export interface DialTabProps {
24
23
  * />
25
24
  * ```
26
25
  *
27
- * @param tab - The tab model containing its `id` and `name`.
26
+ * @param tab - The tab model containing its `id`, `name`, [`disabled`], [`invalid`].
28
27
  * @param active - Whether the tab is currently active.
29
- * @param [disabled=false] - Whether the tab is disabled and non-interactive.
30
- * @param [invalid=false] - Whether the tab is marked as invalid, displaying an error icon.
31
28
  * @param [horizontal=false] - Whether the tab is displayed in horizontal orientation.
32
29
  * @param [cssClass] - Additional CSS classes applied to the tab element.
33
30
  * @param onClick - Callback fired when the tab is clicked. Receives the tab’s `id`.
@@ -1,22 +1,29 @@
1
1
  import { FC } from 'react';
2
2
  import { TabModel } from '../../models/tab';
3
- import { TabOrientation } from '../../types/tab';
3
+ import { SmallScreenThreshold, TabOrientation } from '../../types/tab';
4
4
  export interface DialTabsProps {
5
5
  tabs: TabModel[];
6
6
  activeTab: string;
7
7
  onClick: (id: string) => void;
8
8
  orientation?: TabOrientation;
9
+ smallScreenThreshold?: SmallScreenThreshold;
10
+ smallScreenContainerCssClass?: string;
11
+ smallScreenDropdownItemCssClass?: string;
9
12
  }
10
13
  /**
11
- * A responsive and overflow-aware tabs component that adapts between horizontal and dropdown (mobile) layouts
12
- * based on screen size and available space. When there are too many tabs to fit in one line,
13
- * the component automatically adds a dropdown button for accessing hidden tabs and enables smooth horizontal scrolling.
14
+ * A responsive and overflow-aware tabs component that automatically adapts its layout
15
+ * between a scrollable tab bar and a dropdown menu on smaller screens.
14
16
  *
15
- * Supports both horizontal and vertical orientations and can integrate with JSON editor states to toggle
16
- * visibility when needed. Automatically keeps the active tab in view when navigating through scrollable tabs.
17
+ * When there are too many tabs to fit in a single line, it introduces a dropdown button
18
+ * for accessing hidden tabs and ensures smooth horizontal scrolling. The component also
19
+ * automatically keeps the active tab in view.
17
20
  *
18
- * On larger screens, tabs are displayed horizontally or vertically according to the {@link TabOrientation} prop.
19
- * On smaller screens, tabs collapse into a dropdown menu for better usability.
21
+ * Supports both horizontal and vertical orientations and dynamically adjusts layout
22
+ * based on screen size and available space.
23
+ *
24
+ * On larger screens, tabs are displayed according to the `orientation` prop
25
+ * (horizontal or vertical). On smaller screens (mobile or tablet), the tabs collapse
26
+ * into a dropdown menu for better usability.
20
27
  *
21
28
  * @example
22
29
  * ```tsx
@@ -32,15 +39,21 @@ export interface DialTabsProps {
32
39
  * />
33
40
  * ```
34
41
  *
35
- * @param tabs - Array of tab models to render. Each tab should include an `id` and `label`.
42
+ * @param tabs - Array of tab models to render. Each tab must include an `id` and a display `name`.
36
43
  * @param activeTab - The identifier of the currently active tab.
37
44
  * @param onClick - Callback fired when a tab is selected. Receives the tab's `id` as an argument.
38
- * @param [orientation=TabOrientation.Horizontal] - The layout direction of the tabs. Uses the {@link TabOrientation} enum.
45
+ * @param [orientation=TabOrientation.Horizontal] - Layout direction of the tabs. Uses the {@link TabOrientation} enum.
46
+ * @param [smallScreenThreshold=SmallScreenThreshold.Tablet] - Defines the screen size threshold
47
+ * below which tabs collapse into a dropdown. Uses the {@link SmallScreenThreshold} enum.
48
+ * When set to `Tablet`, both mobile and tablet screens will trigger dropdown mode.
49
+ * @param [smallScreenContainerCssClass] - Optional CSS class applied to the dropdown container
50
+ * in small-screen (collapsed) mode.
51
+ * @param [smallScreenDropdownItemCssClass] - Optional CSS class applied to individual dropdown
52
+ * items in small-screen mode.
39
53
  *
40
54
  * @remarks
41
- * - Automatically detects overflow using a `ResizeObserver` and toggles a dropdown button when tabs exceed
42
- * available width.
43
- * - Smoothly scrolls the tab row to keep the active tab visible.
44
- * - Switches to a dedicated dropdown interface on mobile and tablet screens via the `useIsTabletScreen` hook.
55
+ * - Automatically detects horizontal overflow via `ResizeObserver` and shows a dropdown when needed.
56
+ * - Smoothly scrolls to keep the active tab visible when navigating.
57
+ * - Switches layout responsively based on `smallScreenThreshold`.
45
58
  */
46
59
  export declare const DialTabs: FC<DialTabsProps>;
@@ -1,9 +1,9 @@
1
1
  import { TagVariant } from '../../types/tag';
2
- import { FC, ReactNode } from 'react';
2
+ import { FC, MouseEvent, ReactNode } from 'react';
3
3
  export interface DialTagProps {
4
4
  tag: string;
5
5
  cssClass?: string;
6
- remove?: (event: React.MouseEvent<HTMLButtonElement>) => void;
6
+ remove?: (event: MouseEvent<HTMLButtonElement>) => void;
7
7
  variant?: TagVariant;
8
8
  iconBefore?: ReactNode;
9
9
  bordered?: boolean;
@@ -1,6 +1,6 @@
1
1
  import { FC, ReactNode } from 'react';
2
2
  import { DialTooltipContainerOptions } from './TooltipContext';
3
- export interface Props extends DialTooltipContainerOptions {
3
+ export interface DialTooltipProps extends DialTooltipContainerOptions {
4
4
  hideTooltip?: boolean;
5
5
  tooltip: ReactNode;
6
6
  children: ReactNode;
@@ -28,4 +28,4 @@ export interface Props extends DialTooltipContainerOptions {
28
28
  * @param [open] - Controlled open state for the tooltip
29
29
  * @param [onOpenChange] - Callback fired when the tooltip open state changes
30
30
  */
31
- export declare const DialTooltip: FC<Props>;
31
+ export declare const DialTooltip: FC<DialTooltipProps>;
@@ -1,8 +1,11 @@
1
- import { HTMLProps } from 'react';
1
+ import { CSSProperties, FC, HTMLProps } from 'react';
2
+ export interface Props extends HTMLProps<HTMLDivElement> {
3
+ style?: CSSProperties;
4
+ }
2
5
  /**
3
6
  * The content area of a tooltip that displays the tooltip information
4
7
  *
5
8
  * @param children - The content to display inside the tooltip
6
9
  * @param [style] - Additional inline styles for the tooltip content
7
10
  */
8
- export declare const DialTooltipContent: import('react').ForwardRefExoticComponent<Omit<HTMLProps<HTMLDivElement>, "ref"> & import('react').RefAttributes<HTMLDivElement>>;
11
+ export declare const DialTooltipContent: FC<Props>;