@connectif/ui-components 2.3.0 → 2.3.2

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.
@@ -120,7 +120,7 @@ export type ButtonProps = Pick<MuiButtonProps, 'id' | 'disabled' | 'onClick' | '
120
120
  * Button can be primary, secondary, outlined or text, and it can have an icon at the start or at the end.
121
121
  * It can be disabled.
122
122
  */
123
- declare const Button: React.ForwardRefExoticComponent<Pick<MuiButtonProps, "sx" | "onClick" | "className" | "id" | "aria-controls" | "aria-expanded" | "aria-haspopup" | "onMouseEnter" | "onMouseLeave" | "disabled" | "type"> & {
123
+ declare const Button: React.ForwardRefExoticComponent<Pick<MuiButtonProps, "id" | "className" | "aria-controls" | "aria-expanded" | "aria-haspopup" | "sx" | "disabled" | "type" | "onClick" | "onMouseEnter" | "onMouseLeave"> & {
124
124
  /**
125
125
  * The variant of the button.
126
126
  */
@@ -29,7 +29,7 @@ export type ButtonWithActionsProps = ButtonProps & Pick<PopoverProps, 'anchorHor
29
29
  * A component that groups multiple buttons.
30
30
  * All supported children types of this component are: Button, IconButton, MenuButton or MenuIconButton.
31
31
  */
32
- declare const ButtonWithActions: React.ForwardRefExoticComponent<Pick<MuiButtonProps, "sx" | "onClick" | "className" | "id" | "aria-controls" | "aria-expanded" | "aria-haspopup" | "onMouseEnter" | "onMouseLeave" | "disabled" | "type"> & {
32
+ declare const ButtonWithActions: React.ForwardRefExoticComponent<Pick<MuiButtonProps, "id" | "className" | "aria-controls" | "aria-expanded" | "aria-haspopup" | "sx" | "disabled" | "type" | "onClick" | "onMouseEnter" | "onMouseLeave"> & {
33
33
  variant?: "contained" | "outlined" | "text";
34
34
  color?: "primary" | "inherit" | "white" | "warning";
35
35
  size?: "M" | "L" | "XL";
@@ -43,7 +43,7 @@ declare const ButtonWithActions: React.ForwardRefExoticComponent<Pick<MuiButtonP
43
43
  badgeLeft?: boolean;
44
44
  children?: React.ReactElement<"input">;
45
45
  link?: React.ElementType;
46
- } & Pick<PopoverProps, "anchorHorizontalOrigin" | "horizontalAlign"> & {
46
+ } & Pick<PopoverProps, "horizontalAlign" | "anchorHorizontalOrigin"> & {
47
47
  /**
48
48
  * The options to show in button submenu
49
49
  */
@@ -53,7 +53,7 @@ export type IconButtonProps = Pick<MuiIconButtonProps, 'disabled' | 'onClick' |
53
53
  */
54
54
  shape?: 'default' | 'square';
55
55
  };
56
- declare const IconButton: React.ForwardRefExoticComponent<Pick<MuiIconButtonProps, "sx" | "onClick" | "className" | "id" | "onMouseDown" | "disabled"> & {
56
+ declare const IconButton: React.ForwardRefExoticComponent<Pick<MuiIconButtonProps, "id" | "className" | "sx" | "disabled" | "onClick" | "onMouseDown"> & {
57
57
  /**
58
58
  * The identifier of the icon to display.
59
59
  */
@@ -17,7 +17,7 @@ export type IconToggleButtonProps = Pick<MuiToggleButtonProps, 'disabled' | 'onC
17
17
  */
18
18
  value?: string;
19
19
  };
20
- declare const _default: React.ForwardRefExoticComponent<Pick<MuiToggleButtonProps, "sx" | "onClick" | "disabled" | "selected"> & {
20
+ declare const _default: React.ForwardRefExoticComponent<Pick<MuiToggleButtonProps, "sx" | "disabled" | "onClick" | "selected"> & {
21
21
  variant?: IconToggleButtonVariant;
22
22
  /**
23
23
  * The identifier of the icon to display at the start of the button.
@@ -29,7 +29,7 @@ export type MenuButtonProps = Omit<ButtonProps, 'children' | 'component'> & Pick
29
29
  * A component that displays a Button with a menu.
30
30
  * An invisible overlay is displayed on top of the page to close menu if clicked outside.
31
31
  */
32
- declare const MenuButton: React.ForwardRefExoticComponent<Omit<ButtonProps, "children" | "component"> & Pick<PopoverProps, "anchorHorizontalOrigin" | "horizontalAlign"> & {
32
+ declare const MenuButton: React.ForwardRefExoticComponent<Omit<ButtonProps, "children" | "component"> & Pick<PopoverProps, "horizontalAlign" | "anchorHorizontalOrigin"> & {
33
33
  /**
34
34
  * The list of menu items to display.
35
35
  */
@@ -37,13 +37,13 @@ export type MenuIconButtonProps = IconButtonProps & Pick<PopoverProps, 'anchorHo
37
37
  * A component that displays an IconButton with a menu.
38
38
  * An invisible overlay is displayed on top of the page to close menu if clicked outside.
39
39
  */
40
- declare const MenuIconButton: React.ForwardRefExoticComponent<Pick<import("@mui/material").IconButtonProps, "sx" | "onClick" | "className" | "id" | "onMouseDown" | "disabled"> & {
40
+ declare const MenuIconButton: React.ForwardRefExoticComponent<Pick<import("@mui/material").IconButtonProps, "id" | "className" | "sx" | "disabled" | "onClick" | "onMouseDown"> & {
41
41
  iconId: import("..").IconId;
42
- size?: "M" | "L" | "S" | "XL" | "XXS" | "XS" | "ML";
42
+ size?: "XXS" | "XS" | "S" | "M" | "L" | "XL" | "ML";
43
43
  'data-test'?: string;
44
44
  variant?: "contained" | "default" | "primary" | "outlined";
45
45
  shape?: "default" | "square";
46
- } & Pick<PopoverProps, "anchorHorizontalOrigin" | "horizontalAlign"> & {
46
+ } & Pick<PopoverProps, "horizontalAlign" | "anchorHorizontalOrigin"> & {
47
47
  /**
48
48
  * The list of menu items to display.
49
49
  */
@@ -25,6 +25,10 @@ export interface EnhancedCardTitleProps {
25
25
  * Size of the title. By default the size is determined according to parent EnhancedCard size.
26
26
  */
27
27
  size?: 'S' | 'M';
28
+ /**
29
+ * Padding around the title. Default is 'none'.
30
+ */
31
+ padding?: string;
28
32
  /**
29
33
  * Data test id. By default the dataTest of parent EnhancedCard is used to compose a dataTest string.
30
34
  */
@@ -2,6 +2,7 @@ import * as React from 'react';
2
2
  import './EchartsConfig';
3
3
  import { ChartTooltipEntryFormatter } from '../../utils/ChartUtils';
4
4
  import { IncrementLabelType } from '../../propTypes/IncrementLabel';
5
+ import { CallbackDataParams } from 'echarts/types/dist/shared';
5
6
  export type DonutChartProps = {
6
7
  /**
7
8
  * The css style to apply to the chart container.
@@ -69,11 +70,27 @@ export type DonutChartProps = {
69
70
  * The color for this data item.
70
71
  */
71
72
  color: string;
73
+ /**
74
+ * The opacity to apply in color. Value between 0 and 1.
75
+ */
76
+ opacity?: number;
72
77
  }[];
73
78
  }[];
79
+ /**
80
+ * To modify start angle
81
+ */
82
+ startAngle?: number;
83
+ /**
84
+ * Inner circle width. Values between 0 to 100.
85
+ */
86
+ innerWidth?: number;
87
+ /**
88
+ * Function used to set specified tooltip.
89
+ */
90
+ getTooltip?: (param: CallbackDataParams) => React.ReactNode;
74
91
  };
75
92
  /**
76
93
  * A donut chart component to display numeric data grouped by categories and series.
77
94
  */
78
- declare const DonutChart: ({ style, isLoading, series, tooltipEntryFormatter, onClick }: DonutChartProps) => import("react/jsx-runtime").JSX.Element;
95
+ declare const DonutChart: ({ style, isLoading, series, startAngle, innerWidth, tooltipEntryFormatter, getTooltip, onClick }: DonutChartProps) => import("react/jsx-runtime").JSX.Element;
79
96
  export default DonutChart;
@@ -911,7 +911,7 @@ export type ChipProps = Pick<MuiChipProps, 'id' | 'label' | 'sx' | 'onClick' | '
911
911
  * A component that displays a chip containing simple text.
912
912
  * If chips doesn't fit in the available space, they will be truncated with ellipsis.
913
913
  */
914
- declare const Chip: React.ForwardRefExoticComponent<Pick<MuiChipProps, "sx" | "onClick" | "id" | "onMouseEnter" | "onMouseLeave" | "label" | "onDelete"> & {
914
+ declare const Chip: React.ForwardRefExoticComponent<Pick<MuiChipProps, "label" | "id" | "sx" | "onClick" | "onMouseEnter" | "onMouseLeave" | "onDelete"> & {
915
915
  /**
916
916
  * The icon to display
917
917
  */
@@ -29,7 +29,7 @@ export type MenuChipProps = Omit<ChipProps, 'children' | 'component'> & Pick<Pop
29
29
  * A component that displays a Chip with a menu.
30
30
  * An invisible overlay is displayed on top of the page to close menu if clicked outside.
31
31
  */
32
- declare const MenuChip: React.ForwardRefExoticComponent<Omit<ChipProps, "children" | "component"> & Pick<PopoverProps, "anchorHorizontalOrigin" | "horizontalAlign"> & {
32
+ declare const MenuChip: React.ForwardRefExoticComponent<Omit<ChipProps, "children" | "component"> & Pick<PopoverProps, "horizontalAlign" | "anchorHorizontalOrigin"> & {
33
33
  /**
34
34
  * The list of menu items to display.
35
35
  */
@@ -1,6 +1,7 @@
1
1
  import * as React from 'react';
2
2
  import { SvgIconProps } from '@mui/material';
3
- import { icons } from './icons';
3
+ import { IconId } from './icons';
4
+ export { IconId } from './icons';
4
5
  export declare const iconSizes: {
5
6
  readonly XXS: 12;
6
7
  readonly XS: 16;
@@ -10,9 +11,6 @@ export declare const iconSizes: {
10
11
  readonly XL: 48;
11
12
  readonly XXL: 72;
12
13
  };
13
- export interface IconRegistry {
14
- }
15
- export type IconId = keyof typeof icons | keyof IconRegistry;
16
14
  export type IconProps = Pick<SvgIconProps, 'sx'> & {
17
15
  /**
18
16
  * The ID of the icon to display.
@@ -1958,3 +1958,7 @@ export declare const iconIds: string[];
1958
1958
  declare let customIcons: Record<string, string>;
1959
1959
  export declare function registerCustomIcons(newIcons: Record<string, string>): void;
1960
1960
  export { customIcons };
1961
+ export interface IconRegistry {
1962
+ }
1963
+ export type IconId = keyof typeof icons | keyof IconRegistry;
1964
+ export declare function getIconPath(icon: IconId): string;
@@ -1,4 +1,4 @@
1
1
  export { default as Icon, iconSizes } from './Icon';
2
- export type { IconProps, IconId, IconRegistry } from './Icon';
3
- export { iconIds, registerCustomIcons } from './icons';
2
+ export type { IconProps } from './Icon';
3
+ export { iconIds, registerCustomIcons, IconRegistry, getIconPath, IconId } from './icons';
4
4
  export { default as StackedIcons, StackedIconsProps } from './StackedIcons';
@@ -5,7 +5,7 @@ export type InfoBoxProps = {
5
5
  children: React.ReactNode;
6
6
  variant?: InfoBoxVariant;
7
7
  collapsedHeight?: number;
8
- sx?: SxProps;
8
+ sx?: Omit<SxProps, 'position'>;
9
9
  };
10
10
  declare const InfoBox: React.FC<InfoBoxProps>;
11
11
  export default InfoBox;
@@ -30,7 +30,7 @@ export type DatePickerProps = Omit<TextFieldProps, 'value' | 'onChange' | 'type'
30
30
  * An input component which uses a vitamined TextField with a popover to allow user
31
31
  * to pick a Date (without time component)
32
32
  */
33
- declare const DatePicker: React.ForwardRefExoticComponent<Omit<TextFieldProps, "onBlur" | "onChange" | "onKeyDown" | "onScroll" | "value" | "maxLength" | "type"> & {
33
+ declare const DatePicker: React.ForwardRefExoticComponent<Omit<TextFieldProps, "type" | "onBlur" | "onChange" | "onKeyDown" | "onScroll" | "value" | "maxLength"> & {
34
34
  /**
35
35
  * The value handled by this DatePicker
36
36
  */
@@ -56,7 +56,7 @@ export type NumberFieldProps = Omit<TextFieldProps, 'value' | 'onChange' | 'mult
56
56
  * The exposed `ref` property is the refference to the native &lt;input&gt; element,
57
57
  * typed as React.Ref&lt;HTMLInputElement&gt;
58
58
  */
59
- declare const NumberField: React.ForwardRefExoticComponent<Omit<TextFieldProps, "defaultValue" | "onChange" | "onScroll" | "value" | "multiline" | "type"> & {
59
+ declare const NumberField: React.ForwardRefExoticComponent<Omit<TextFieldProps, "type" | "onChange" | "onScroll" | "value" | "defaultValue" | "multiline"> & {
60
60
  /**
61
61
  * The numeric value of this input.
62
62
  */
@@ -25,7 +25,7 @@ export type PhoneFieldProps = Omit<TextFieldProps, 'multiline' | 'onChange' | 'r
25
25
  * The exposed `ref` property is the refference to the native &lt;input&gt; element,
26
26
  * typed as React.Ref&lt;HTMLInputElement&gt;
27
27
  */
28
- declare const PhoneField: React.ForwardRefExoticComponent<Omit<TextFieldProps, "defaultValue" | "onChange" | "onScroll" | "multiline" | "rows" | "type"> & {
28
+ declare const PhoneField: React.ForwardRefExoticComponent<Omit<TextFieldProps, "type" | "onChange" | "onScroll" | "defaultValue" | "rows" | "multiline"> & {
29
29
  /**
30
30
  * Called when the value changes
31
31
  */
@@ -20,7 +20,7 @@ export type ListItemButtonProps = Pick<MuiListItemButtonProps, 'onClick' | 'tabI
20
20
  'data-test'?: string;
21
21
  buttonDataTest?: string;
22
22
  } & BaseListItemProps;
23
- declare const ListItemButton: React.ForwardRefExoticComponent<Pick<MuiListItemButtonProps, "onClick" | "className" | "tabIndex" | "role" | "onMouseDown" | "onMouseEnter" | "onMouseLeave" | "onMouseUp"> & {
23
+ declare const ListItemButton: React.ForwardRefExoticComponent<Pick<MuiListItemButtonProps, "className" | "role" | "tabIndex" | "onClick" | "onMouseDown" | "onMouseEnter" | "onMouseLeave" | "onMouseUp"> & {
24
24
  /**
25
25
  * If `true`, the onClick callback will also be triggered on aux click. Default is `false`.
26
26
  */