@epam/ai-dial-ui-kit 0.5.0-rc.16 → 0.5.0-rc.18

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.
@@ -1,6 +1,7 @@
1
1
  import { FC, MouseEvent, ReactNode, Ref } from 'react';
2
2
  import { ButtonVariant } from '../../types/button';
3
3
  export interface DialButtonProps {
4
+ type?: 'button' | 'submit';
4
5
  variant?: ButtonVariant;
5
6
  cssClass?: string;
6
7
  textCssClass?: string;
@@ -27,6 +28,7 @@ export interface DialButtonProps {
27
28
  * ```
28
29
  *
29
30
  * @param [title] - The text content of the button
31
+ * @param [type='button'] - The HTML button type attribute
30
32
  * @param [variant=ButtonVariant.Primary] - Defines the visual style of the button
31
33
  * @param [cssClass] - Additional CSS classes to apply to the button
32
34
  * @param [textCssClass] - Additional CSS classes to apply specifically to the button text
@@ -20,6 +20,8 @@ export interface FileTreeOptions extends Omit<DialFoldersTreeProps, 'items' | 's
20
20
  additionalButtons?: ReactNode;
21
21
  collapsed?: boolean;
22
22
  onCollapseChange?: (collapsed: boolean) => void;
23
+ expandedPaths?: Set<string>;
24
+ onExpandedPathsChange?: (expandedPaths: Set<string>) => void;
23
25
  actionLabels?: {
24
26
  [DialFileManagerActions.Duplicate]?: string;
25
27
  [DialFileManagerActions.Copy]?: string;
@@ -17,6 +17,7 @@ export interface DialFoldersTreeProps {
17
17
  onRenameValidate?: (value: string, item: DialFile) => string | null;
18
18
  getContextMenuItems?: (item: DialFile) => DropdownItem[];
19
19
  areHiddenFilesVisible?: boolean;
20
+ onExpandedPathsChange?: (expandedPaths: Set<string>) => void;
20
21
  }
21
22
  /**
22
23
  * DialFoldersTree — A hierarchical folder tree component with nested expand/collapse support, selection highlighting,
@@ -0,0 +1,13 @@
1
+ export interface UseExpandedPathsOptions {
2
+ expandedPaths?: Set<string>;
3
+ onExpandedPathsChange?: (expandedPaths: Set<string>) => void;
4
+ }
5
+ export declare const useExpandedPaths: (options?: UseExpandedPathsOptions) => {
6
+ expandedPaths: Set<string>;
7
+ setExpandedPaths: (newSet: Set<string>) => void;
8
+ togglePath: (path: string) => void;
9
+ collapseAll: () => void;
10
+ expandPath: (path: string) => void;
11
+ collapsePath: (path: string) => void;
12
+ isControlled: boolean;
13
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@epam/ai-dial-ui-kit",
3
- "version": "0.5.0-rc.16",
3
+ "version": "0.5.0-rc.18",
4
4
  "type": "module",
5
5
  "license": "Apache-2.0",
6
6
  "description": "A modern UI kit for building AI DIAL interfaces with React",