@digital-ai/dot-components 4.14.0 → 4.15.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@digital-ai/dot-components",
3
- "version": "4.14.0",
3
+ "version": "4.15.0",
4
4
  "private": false,
5
5
  "license": "SEE LICENSE IN <LICENSE.md>",
6
6
  "contributors": [
@@ -1,4 +1,4 @@
1
- import { MouseEvent, KeyboardEvent } from 'react';
1
+ import { MouseEvent, KeyboardEvent, ReactNode } from 'react';
2
2
  import { CommonProps } from './CommonProps';
3
3
  import { TooltipPlacement } from './tooltip';
4
4
  export type ButtonType = 'destructive' | 'primary' | 'outlined' | 'text';
@@ -6,6 +6,8 @@ export type ButtonSize = 'small' | 'medium' | 'large';
6
6
  export interface BaseButtonProps extends CommonProps {
7
7
  /** If true, the button will be focused **/
8
8
  autoFocus?: boolean;
9
+ /** If true, makes a tooltip not interactive, so it will close when the user hovers over the tooltip before the leaveDelay is expired. */
10
+ disableInteractive?: boolean;
9
11
  /** If true, the ripple effect will be disabled. */
10
12
  disableRipple?: boolean;
11
13
  /** If true, the button will be disabled. */
@@ -20,8 +22,8 @@ export interface BaseButtonProps extends CommonProps {
20
22
  size?: ButtonSize;
21
23
  /** Tab order for the button. */
22
24
  tabIndex?: number;
23
- /** Help text to be displayed on hover */
24
- tooltip?: string;
25
+ /** Help component to be displayed on hover */
26
+ tooltip?: ReactNode | string | number;
25
27
  /** If set, determines the placement of the tooltip */
26
28
  tooltipPlacement?: TooltipPlacement;
27
29
  /** The type of button */
@@ -1,8 +1,8 @@
1
1
  import { ReactNode, MouseEvent } from 'react';
2
2
  import { CommonProps } from '../CommonProps';
3
- import { IconButtonProps } from '../button/IconButton';
3
+ import { IconButtonProps } from '../button';
4
4
  import { ListItemProps } from '../list';
5
- import { BadgeVariant } from '../badge/Badge';
5
+ import { BadgeVariant } from '../badge';
6
6
  export interface AppToolbarIconButtons extends IconButtonProps {
7
7
  /** custom color code for the badge */
8
8
  badgeColor?: string;
@@ -11,6 +11,8 @@ export interface AvatarProps extends CommonProps {
11
11
  color?: AvatarColor;
12
12
  /** Used for the root node; button is used when onClick is passed. */
13
13
  component?: string;
14
+ /** If true, makes a tooltip not interactive, so it will close when the user hovers over the tooltip before the leaveDelay is expired. */
15
+ disableInteractive?: boolean;
14
16
  /** The ID of the icon to display on the avatar */
15
17
  iconId?: string;
16
18
  /** Source for the image used for the avatar */
@@ -34,4 +36,4 @@ export interface AvatarProps extends CommonProps {
34
36
  /** The shape of the avatar */
35
37
  variant?: AvatarVariant;
36
38
  }
37
- export declare const DotAvatar: ({ alt, ariaLabel, ariaRole, className, component, color, "data-testid": dataTestId, iconId, imageSrc, onClick, number, size, tabIndex, text, type, tooltip, variant, style, }: AvatarProps) => import("react/jsx-runtime").JSX.Element;
39
+ export declare const DotAvatar: ({ alt, ariaLabel, ariaRole, className, component, disableInteractive, color, "data-testid": dataTestId, iconId, imageSrc, onClick, number, size, tabIndex, text, type, tooltip, variant, style, }: AvatarProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,4 +1,4 @@
1
- import { CommonIconButtonProps } from '../button/IconButton';
1
+ import { CommonIconButtonProps } from './IconButton';
2
2
  export interface CopyButtonProps extends CommonIconButtonProps {
3
3
  /** Tooltip shown briefly after the value has been copied. */
4
4
  copiedTooltip?: string;
@@ -11,4 +11,4 @@ export interface CopyButtonProps extends CommonIconButtonProps {
11
11
  /** The content which will be copied to the clipboard */
12
12
  value: string;
13
13
  }
14
- export declare const DotCopyButton: ({ ariaLabel, ariaRole, className, color, copiedTooltip, copyTooltip, "data-pendoid": dataPendoId, "data-testid": dataTestId, disabled, disableRipple, iconId, iconSize, onClick, shape, showCopiedIcon, size, tooltip, value, }: CopyButtonProps) => import("react/jsx-runtime").JSX.Element;
14
+ export declare const DotCopyButton: ({ ariaLabel, ariaRole, className, color, copiedTooltip, copyTooltip, "data-pendoid": dataPendoId, "data-testid": dataTestId, disableInteractive, disabled, disableRipple, iconId, iconSize, onClick, shape, showCopiedIcon, size, tooltip, value, }: CopyButtonProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,4 +1,4 @@
1
- import { MouseEvent } from 'react';
1
+ import { MouseEvent, ReactNode } from 'react';
2
2
  import { CommonProps } from '../CommonProps';
3
3
  import { IconFontSize } from '../icon/Icon';
4
4
  import { TooltipPlacement } from '../tooltip';
@@ -8,6 +8,8 @@ export type IconButtonShape = 'circle' | 'square';
8
8
  export interface CommonIconButtonProps extends CommonProps {
9
9
  /** 'default', 'inherit', 'primary', 'secondary' */
10
10
  color?: IconButtonColor;
11
+ /** If true, makes a tooltip not interactive, so it will close when the user hovers over the tooltip before the leaveDelay is expired. */
12
+ disableInteractive?: boolean;
11
13
  /** If true, the ripple effect is disabled. */
12
14
  disableRipple?: boolean;
13
15
  /** If true, the button will be disabled. */
@@ -20,8 +22,8 @@ export interface CommonIconButtonProps extends CommonProps {
20
22
  shape?: IconButtonShape;
21
23
  /** Determines the size of the button and padding around the icon */
22
24
  size?: IconButtonSize;
23
- /** Help text to be displayed on icon hover */
24
- tooltip?: string;
25
+ /** Help component to be displayed on icon hover */
26
+ tooltip?: ReactNode | string | number;
25
27
  /** If set, determines the placement of the tooltip */
26
28
  tooltipPlacement?: TooltipPlacement;
27
29
  }
@@ -29,4 +31,4 @@ export interface IconButtonProps extends CommonIconButtonProps {
29
31
  /** The icon to display on the button */
30
32
  iconId: string;
31
33
  }
32
- export declare const DotIconButton: ({ ariaLabel, ariaRole, className, color, "data-pendoid": dataPendoId, "data-testid": dataTestId, disableRipple, disabled, iconId, iconSize, onClick, shape, size, tooltip, tooltipPlacement, }: IconButtonProps) => import("react/jsx-runtime").JSX.Element;
34
+ export declare const DotIconButton: ({ ariaLabel, ariaRole, className, color, "data-pendoid": dataPendoId, "data-testid": dataTestId, disableInteractive, disableRipple, disabled, iconId, iconSize, onClick, shape, size, tooltip, tooltipPlacement, }: IconButtonProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,3 +1,4 @@
1
+ import { ReactNode } from 'react';
1
2
  import { CommonProps } from '../../CommonProps';
2
3
  export type ButtonToggleSingleValue = string | number | boolean;
3
4
  export type ButtonToggleSize = 'small' | 'medium' | 'large';
@@ -6,9 +7,10 @@ export type ButtonToggleValue = ButtonToggleSingleValue | Array<ButtonToggleSing
6
7
  export interface ButtonToggleOption extends CommonProps {
7
8
  ariaLabel: string;
8
9
  badgeContent?: number;
10
+ disableInteractive?: boolean;
9
11
  disabled?: boolean;
10
12
  iconId?: string;
11
13
  text?: string;
12
- tooltip?: string;
14
+ tooltip?: ReactNode | string | number;
13
15
  value: ButtonToggleValue;
14
16
  }
@@ -1,6 +1,8 @@
1
1
  import { CommonProps } from '../CommonProps';
2
2
  export type IconFontSize = 'small' | 'medium';
3
3
  export interface IconProps extends CommonProps {
4
+ /** If true, makes a tooltip not interactive, so it will close when the user hovers over the tooltip before the leaveDelay is expired. */
5
+ disableInteractive?: boolean;
4
6
  /** Determines the size of the icon and spacing around it */
5
7
  fontSize?: IconFontSize;
6
8
  /** The ID of the icon to display on the button */
@@ -8,4 +10,4 @@ export interface IconProps extends CommonProps {
8
10
  /** Tooltip text displayed on hover */
9
11
  tooltip?: string;
10
12
  }
11
- export declare const DotIcon: ({ ariaLabel, ariaRole, className, "data-testid": dataTestId, fontSize, iconId, tooltip, }: IconProps) => import("react/jsx-runtime").JSX.Element;
13
+ export declare const DotIcon: ({ ariaLabel, ariaRole, className, "data-testid": dataTestId, disableInteractive, fontSize, iconId, tooltip, }: IconProps) => import("react/jsx-runtime").JSX.Element;
@@ -5,4 +5,4 @@ export interface ProgressButtonProps extends ButtonProps {
5
5
  /** Is spinner displayed */
6
6
  isLoading?: boolean;
7
7
  }
8
- export declare const DotProgressButton: ({ ariaLabel, children, className, "data-pendoid": dataPendoId, "data-testid": dataTestId, disabled, disableRipple, fullWidth, isLoading, isSubmit, onClick, size, startIcon, tooltip, type, }: ProgressButtonProps) => import("react/jsx-runtime").JSX.Element;
8
+ export declare const DotProgressButton: ({ ariaLabel, children, className, "data-pendoid": dataPendoId, "data-testid": dataTestId, disabled, disableInteractive, disableRipple, fullWidth, isLoading, isSubmit, onClick, size, startIcon, tooltip, type, }: ProgressButtonProps) => import("react/jsx-runtime").JSX.Element;
@@ -12,4 +12,4 @@ export interface SplitButtonProps extends BaseButtonProps {
12
12
  /**The options within the button dropdown */
13
13
  options: Array<MenuItemProps>;
14
14
  }
15
- export declare const DotSplitButton: ({ autoFocus, ariaLabel, className, "data-pendoid": dataPendoId, "data-testid": dataTestId, defaultMainOptionKey, disabled, disablePortal, disableRipple, fullWidth, isSubmit, onOptionClick, options, size, tooltip, tooltipPlacement, type, }: SplitButtonProps) => import("react/jsx-runtime").JSX.Element;
15
+ export declare const DotSplitButton: ({ autoFocus, ariaLabel, className, "data-pendoid": dataPendoId, "data-testid": dataTestId, defaultMainOptionKey, disabled, disableInteractive, disablePortal, disableRipple, fullWidth, isSubmit, onOptionClick, options, size, tooltip, tooltipPlacement, type, }: SplitButtonProps) => import("react/jsx-runtime").JSX.Element;