@react-fabric/core 1.0.0-beta.55 → 1.0.0-beta.58

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 (93) hide show
  1. package/css/components/_card.css +8 -4
  2. package/css/components/_icon.css +3 -3
  3. package/css/components/_tabPanel.css +40 -0
  4. package/css/core/_aside.css +4 -6
  5. package/css/reset/_reset.css +14 -0
  6. package/dist/cjs/components/avatar/Avatar.js +9 -4
  7. package/dist/cjs/components/badge/Badge.js +2 -10
  8. package/dist/cjs/components/button/Button.js +7 -12
  9. package/dist/cjs/components/card/Card.js +18 -12
  10. package/dist/cjs/components/chip/Chip.js +9 -14
  11. package/dist/cjs/components/dropdown/Dropdown.js +1 -0
  12. package/dist/cjs/components/icon/Icon.js +37 -8
  13. package/dist/cjs/components/menu/MenuItem.js +5 -12
  14. package/dist/cjs/components/panel/Panel.js +4 -13
  15. package/dist/cjs/components/tabpanel/Tab.js +4 -13
  16. package/dist/cjs/components/tabpanel/TabPanel.js +2 -1
  17. package/dist/cjs/core/aside/Aside.js +2 -11
  18. package/dist/cjs/core/headfoot/HeadFoot.js +4 -2
  19. package/dist/cjs/core/page/Page.js +4 -13
  20. package/dist/cjs/index.js +1 -0
  21. package/dist/cjs/overlays/alert/Alert.js +3 -1
  22. package/dist/cjs/overlays/flyout/Flyout.js +6 -11
  23. package/dist/cjs/overlays/message/Message.js +2 -0
  24. package/dist/cjs/overlays/modal/Modal.js +6 -13
  25. package/dist/cjs/overlays/toast/Toast.js +3 -1
  26. package/dist/cjs/types/icons.js +2 -1
  27. package/dist/esm/components/avatar/Avatar.js +9 -4
  28. package/dist/esm/components/badge/Badge.js +3 -11
  29. package/dist/esm/components/button/Button.js +9 -14
  30. package/dist/esm/components/card/Card.js +18 -12
  31. package/dist/esm/components/chip/Chip.js +10 -15
  32. package/dist/esm/components/dropdown/Dropdown.js +1 -0
  33. package/dist/esm/components/icon/Icon.js +39 -11
  34. package/dist/esm/components/menu/MenuItem.js +6 -13
  35. package/dist/esm/components/panel/Panel.js +5 -14
  36. package/dist/esm/components/tabpanel/Tab.js +5 -14
  37. package/dist/esm/components/tabpanel/TabPanel.js +2 -1
  38. package/dist/esm/core/aside/Aside.js +3 -12
  39. package/dist/esm/core/headfoot/HeadFoot.js +4 -2
  40. package/dist/esm/core/page/Page.js +5 -14
  41. package/dist/esm/index.js +1 -1
  42. package/dist/esm/overlays/alert/Alert.js +3 -1
  43. package/dist/esm/overlays/flyout/Flyout.js +7 -12
  44. package/dist/esm/overlays/message/Message.js +2 -0
  45. package/dist/esm/overlays/modal/Modal.js +7 -14
  46. package/dist/esm/overlays/toast/Toast.js +3 -1
  47. package/dist/esm/types/icons.js +2 -1
  48. package/dist/types/components/avatar/Avatar.d.ts +5 -1
  49. package/dist/types/components/badge/Badge.d.ts +8 -3
  50. package/dist/types/components/button/Button.d.ts +12 -3
  51. package/dist/types/components/card/Card.d.ts +5 -3
  52. package/dist/types/components/chip/Chip.d.ts +12 -3
  53. package/dist/types/components/icon/Icon.d.ts +10 -4
  54. package/dist/types/components/index.d.ts +1 -1
  55. package/dist/types/components/menu/MenuItem.d.ts +1 -1
  56. package/dist/types/components/menu/types.d.ts +7 -2
  57. package/dist/types/components/panel/Panel.d.ts +8 -5
  58. package/dist/types/components/tabpanel/Tab.d.ts +8 -5
  59. package/dist/types/components/tabpanel/TabPanel.d.ts +5 -1
  60. package/dist/types/core/aside/Aside.d.ts +8 -5
  61. package/dist/types/core/page/Page.d.ts +8 -5
  62. package/dist/types/overlays/alert/Alert.d.ts +15 -3
  63. package/dist/types/overlays/flyout/Flyout.d.ts +9 -5
  64. package/dist/types/overlays/message/Message.d.ts +15 -3
  65. package/dist/types/overlays/modal/Modal.d.ts +6 -6
  66. package/dist/types/overlays/toast/Toast.d.ts +15 -3
  67. package/dist/types/types/icons.d.ts +2 -1
  68. package/dist/types/types/index.d.ts +0 -18
  69. package/package.json +14 -14
  70. package/src/components/avatar/Avatar.tsx +10 -2
  71. package/src/components/badge/Badge.tsx +7 -13
  72. package/src/components/button/Button.tsx +24 -19
  73. package/src/components/card/Card.tsx +29 -15
  74. package/src/components/chip/Chip.tsx +15 -13
  75. package/src/components/dropdown/Dropdown.tsx +1 -0
  76. package/src/components/icon/Icon.tsx +48 -7
  77. package/src/components/index.ts +1 -1
  78. package/src/components/menu/MenuItem.tsx +4 -9
  79. package/src/components/menu/types.ts +6 -6
  80. package/src/components/panel/Panel.tsx +7 -13
  81. package/src/components/tabpanel/Tab.tsx +8 -19
  82. package/src/components/tabpanel/TabPanel.tsx +6 -0
  83. package/src/core/aside/Aside.tsx +7 -13
  84. package/src/core/headfoot/HeadFoot.tsx +2 -2
  85. package/src/core/page/Page.tsx +8 -23
  86. package/src/overlays/alert/Alert.tsx +24 -5
  87. package/src/overlays/flyout/Flyout.tsx +11 -22
  88. package/src/overlays/message/Message.tsx +18 -3
  89. package/src/overlays/modal/Modal.tsx +8 -24
  90. package/src/overlays/toast/Toast.tsx +23 -4
  91. package/src/types/global.d.ts +8 -0
  92. package/src/types/icons.ts +3 -1
  93. package/src/types/index.ts +0 -19
@@ -40,6 +40,7 @@ var Toast = function Toast(_ref) {
40
40
  _ref$color = _ref.color,
41
41
  color = _ref$color === void 0 ? "primary" : _ref$color,
42
42
  icon = _ref.icon,
43
+ iconSrc = _ref.iconSrc,
43
44
  rtlFlip = _ref.rtlFlip,
44
45
  actions = _ref.actions,
45
46
  onClose = _ref.onClose,
@@ -52,6 +53,7 @@ var Toast = function Toast(_ref) {
52
53
  var iconType = useMemo(function () {
53
54
  if (icon) return /*#__PURE__*/jsx(Icon, {
54
55
  icon: icon,
56
+ iconSrc: iconSrc,
55
57
  size: "md",
56
58
  rtlFlip: rtlFlip,
57
59
  color: color + "-600"
@@ -78,7 +80,7 @@ var Toast = function Toast(_ref) {
78
80
  color: "".concat(color, "-600")
79
81
  });
80
82
  }
81
- }, [color, type, icon]);
83
+ }, [color, type, icon, iconSrc, rtlFlip]);
82
84
  var elRef = useRef(null);
83
85
  var handleClose = useCallback(function (ret) {
84
86
  elRef.current && (elRef.current.dataset.show = "false");
@@ -183,7 +183,7 @@ var CoreIcons;
183
183
  _CoreIcons.mediaAspect = "M19,12H17V15H14V17H19V12M7,9H10V7H5V12H7V9M21,3H3A2,2 0 0,0 1,5V19A2,2 0 0,0 3,21H21A2,2 0 0,0 23,19V5A2,2 0 0,0 21,3M21,19H3V5H21V19Z";
184
184
  _CoreIcons.mediaZoomer = "M15 0.004c-4.97 0-9 4.030-9 9 0 1.52 0.38 2.95 1.046 4.206l-6.258 6.256 0.005 0.005c-0.489 0.481-0.794 1.147-0.794 1.887 0 1.462 1.185 2.647 2.647 2.647 0.739 0 1.406-0.304 1.886-0.794l-0.002-0.001 6.256-6.255c1.257 0.668 2.689 1.050 4.213 1.050 4.97 0 9-4.030 9-9s-4.030-9-9-9zM3.596 22.273c-0.241 0.25-0.576 0.407-0.95 0.407-0.731 0-1.324-0.592-1.324-1.323 0-0.373 0.157-0.707 0.407-0.95l-0.007-0.006 6.050-6.050c0.529 0.713 1.159 1.343 1.87 1.874l-6.047 6.047zM15 16.505c-4.142 0-7.5-3.359-7.5-7.5s3.358-7.5 7.5-7.5c4.141 0 7.5 3.358 7.5 7.5s-3.359 7.5-7.5 7.5zM15 3.754c0.206 0 0.375 0.168 0.375 0.375s-0.169 0.375-0.375 0.375c-2.486 0-4.5 2.015-4.5 4.5 0 0.207-0.168 0.375-0.375 0.375s-0.375-0.168-0.375-0.375c0-2.9 2.35-5.25 5.25-5.25z";
185
185
  _CoreIcons.mediaOrient = "M7.34,6.41L0.86,12.9L7.35,19.38L13.84,12.9L7.34,6.41M3.69,12.9L7.35,9.24L11,12.9L7.34,16.56L3.69,12.9M19.36,6.64C17.61,4.88 15.3,4 13,4V0.76L8.76,5L13,9.24V6C14.79,6 16.58,6.68 17.95,8.05C20.68,10.78 20.68,15.22 17.95,17.95C16.58,19.32 14.79,20 13,20C12.03,20 11.06,19.79 10.16,19.39L8.67,20.88C10,21.62 11.5,22 13,22C15.3,22 17.61,21.12 19.36,19.36C22.88,15.85 22.88,10.15 19.36,6.64Z";
186
- _CoreIcons.mediaCrop = "M7,17V1H5V5H1V7H5V17A2,2 0 0,0 7,19H17V23H19V19H23V17M17,15H19V7C19,5.89 18.1,5 17,5H9V7H17V15Z";
186
+ _CoreIcons.mediaCrop = "M13,17H17V13H19V17H23V19H19V23H17V19H13V17M11,17V19H9V17H11M7,17V19H5V17H7M19,9V11H17V9H19M19,5V7H17V5H19M15,5V7H13V5H15M11,5V7H9V5H11M7,5V7H5V5H7M7,13V15H5V13H7M7,9V11H5V9H7Z";
187
187
  _CoreIcons.mediaImage = "M19,19H5V5H19M19,3H5A2,2 0 0,0 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V5A2,2 0 0,0 19,3M13.96,12.29L11.21,15.83L9.25,13.47L6.5,17H17.5L13.96,12.29Z";
188
188
  _CoreIcons.mediaVideo = "M15,8V16H5V8H15M16,6H4A1,1 0 0,0 3,7V17A1,1 0 0,0 4,18H16A1,1 0 0,0 17,17V13.5L21,17.5V6.5L17,10.5V7A1,1 0 0,0 16,6Z";
189
189
  _CoreIcons.mediaAudio = "M17.3,11C17.3,14 14.76,16.1 12,16.1C9.24,16.1 6.7,14 6.7,11H5C5,14.41 7.72,17.23 11,17.72V21H13V17.72C16.28,17.23 19,14.41 19,11M10.8,4.9C10.8,4.24 11.34,3.7 12,3.7C12.66,3.7 13.2,4.24 13.2,4.9L13.19,11.1C13.19,11.76 12.66,12.3 12,12.3C11.34,12.3 10.8,11.76 10.8,11.1M12,14A3,3 0 0,0 15,11V5A3,3 0 0,0 12,2A3,3 0 0,0 9,5V11A3,3 0 0,0 12,14Z";
@@ -205,6 +205,7 @@ var CoreIcons;
205
205
  _CoreIcons.mediaVolume3 = "M14,3.23V5.29C16.89,6.15 19,8.83 19,12C19,15.17 16.89,17.84 14,18.7V20.77C18,19.86 21,16.28 21,12C21,7.72 18,4.14 14,3.23M16.5,12C16.5,10.23 15.5,8.71 14,7.97V16C15.5,15.29 16.5,13.76 16.5,12M3,9V15H7L12,20V4L7,9H3Z";
206
206
  _CoreIcons.mediaComment = "M9,22A1,1 0 0,1 8,21V18H4A2,2 0 0,1 2,16V4C2,2.89 2.9,2 4,2H20A2,2 0 0,1 22,4V16A2,2 0 0,1 20,18H13.9L10.2,21.71C10,21.9 9.75,22 9.5,22V22H9M10,16V19.08L13.08,16H20V4H4V16H10M6,7H18V9H6V7M6,11H15V13H6V11Z";
207
207
  _CoreIcons.mediaCommentAdd = "M9,22A1,1 0 0,1 8,21V18H4A2,2 0 0,1 2,16V4C2,2.89 2.9,2 4,2H20A2,2 0 0,1 22,4V16A2,2 0 0,1 20,18H13.9L10.2,21.71C10,21.9 9.75,22 9.5,22V22H9M10,16V19.08L13.08,16H20V4H4V16H10M11,6H13V9H16V11H13V14H11V11H8V9H11V6Z";
208
+ _CoreIcons.mediaCapture = "M12,10L11.06,12.06L9,13L11.06,13.94L12,16L12.94,13.94L15,13L12.94,12.06L12,10M20,5H16.83L15,3H9L7.17,5H4A2,2 0 0,0 2,7V19A2,2 0 0,0 4,21H20A2,2 0 0,0 22,19V7A2,2 0 0,0 20,5M20,19H4V7H8.05L8.64,6.35L9.88,5H14.12L15.36,6.35L15.95,7H20V19M12,8A5,5 0 0,0 7,13A5,5 0 0,0 12,18A5,5 0 0,0 17,13A5,5 0 0,0 12,8M12,16A3,3 0 0,1 9,13A3,3 0 0,1 12,10A3,3 0 0,1 15,13A3,3 0 0,1 12,16Z";
208
209
  _CoreIcons.mediaLightness = "M12,18A6,6 0 0,1 6,12A6,6 0 0,1 12,6A6,6 0 0,1 18,12A6,6 0 0,1 12,18M20,15.31L23.31,12L20,8.69V4H15.31L12,0.69L8.69,4H4V8.69L0.69,12L4,15.31V20H8.69L12,23.31L15.31,20H20V15.31Z";
209
210
  _CoreIcons.mediaColor = "M19,11.5C19,11.5 17,13.67 17,15A2,2 0 0,0 19,17A2,2 0 0,0 21,15C21,13.67 19,11.5 19,11.5M5.21,10L10,5.21L14.79,10M16.56,8.94L7.62,0L6.21,1.41L8.59,3.79L3.44,8.94C2.85,9.5 2.85,10.47 3.44,11.06L8.94,16.56C9.23,16.85 9.62,17 10,17C10.38,17 10.77,16.85 11.06,16.56L16.56,11.06C17.15,10.47 17.15,9.5 16.56,8.94Z";
210
211
  _CoreIcons.mediaInvert = "M12,19.58V19.58C10.4,19.58 8.89,18.96 7.76,17.83C6.62,16.69 6,15.19 6,13.58C6,12 6.62,10.47 7.76,9.34L12,5.1M17.66,7.93L12,2.27V2.27L6.34,7.93C3.22,11.05 3.22,16.12 6.34,19.24C7.9,20.8 9.95,21.58 12,21.58C14.05,21.58 16.1,20.8 17.66,19.24C20.78,16.12 20.78,11.05 17.66,7.93Z";
@@ -36,6 +36,10 @@ export interface AvatarProps extends CssProp, AriaProps, TestProps, RefProp {
36
36
  * rounded icon
37
37
  */
38
38
  rounded?: boolean;
39
+ /**
40
+ * prevent click default, useful when component is within a `a` link
41
+ */
42
+ preventDefault?: boolean;
39
43
  /**
40
44
  * click handler
41
45
  */
@@ -69,4 +73,4 @@ export interface AvatarProps extends CssProp, AriaProps, TestProps, RefProp {
69
73
  * @see {@link https://adarshpastakia.github.io/react-fabric/?path=/story/core-components-avatar--docs} for more details.
70
74
  * @see {@link https://boringavatars.com/} for more information on Boring Avatars.
71
75
  */
72
- export declare const Avatar: ({ ref, name, avatar, fallbackIcon, bg, color, size, rounded, variant, className, viewBox, onClick, ...aria }: AvatarProps) => import("react/jsx-runtime").JSX.Element;
76
+ export declare const Avatar: ({ ref, name, avatar, fallbackIcon, bg, color, size, rounded, variant, className, viewBox, preventDefault, onClick, ...aria }: AvatarProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,5 +1,6 @@
1
- import { type BadgeType, type ChildProp, type CssProp, type IconProps, type RefProp } from "../../types";
2
- export interface BadgeProps extends CssProp, RefProp, IconProps, Partial<ChildProp> {
1
+ import { type BadgeType, type ChildProp, type CssProp, type RefProp } from "../../types";
2
+ import { IconProps } from "../icon/Icon";
3
+ export interface BadgeProps extends CssProp, RefProp, Partial<ChildProp> {
3
4
  /**
4
5
  * make wrapper a block element
5
6
  */
@@ -12,6 +13,10 @@ export interface BadgeProps extends CssProp, RefProp, IconProps, Partial<ChildPr
12
13
  * badge value
13
14
  */
14
15
  value?: number | string;
16
+ /**
17
+ * icon path or props
18
+ */
19
+ icon?: IconProps;
15
20
  /**
16
21
  * max value for number display
17
22
  */
@@ -51,4 +56,4 @@ export declare const getBadgeProps: (badge?: string | number | BadgeType) => Any
51
56
  *
52
57
  * @see {@link https://adarshpastakia.github.io/react-fabric/?path=/docs/core-components-badge--docs} for more details.
53
58
  */
54
- export declare const Badge: ({ ref, className, value, max, ping, block, inline, placement, children, forButton, icon, iconBg, iconColor, rtlFlip, ...rest }: BadgeProps) => import("react/jsx-runtime").JSX.Element;
59
+ export declare const Badge: ({ ref, className, value, max, ping, block, inline, placement, children, forButton, icon, ...rest }: BadgeProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,6 +1,7 @@
1
1
  import { type MouseEventHandler, type WheelEventHandler } from "react";
2
- import { type ColorState, type AriaProps, type BadgeType, type CallbackReturn, type CssProp, type IconProps, type PolymorphicProps, type RefProp, type SizeType, type TestProps } from "../../types";
3
- export interface BaseProps extends CssProp, AriaProps, IconProps, RefProp, TestProps {
2
+ import { type AriaProps, type BadgeType, type CallbackReturn, type ColorState, type CssProp, type PolymorphicProps, type RefProp, type SizeType, type TestProps } from "../../types";
3
+ import { IconProps } from "../icon/Icon";
4
+ export interface BaseProps extends CssProp, AriaProps, RefProp, TestProps {
4
5
  /**
5
6
  * primary icon alignment
6
7
  */
@@ -17,6 +18,10 @@ export interface BaseProps extends CssProp, AriaProps, IconProps, RefProp, TestP
17
18
  * button color
18
19
  */
19
20
  color?: ColorState;
21
+ /**
22
+ * icon path or props
23
+ */
24
+ icon?: IconProps;
20
25
  /**
21
26
  * button type
22
27
  */
@@ -74,6 +79,10 @@ export interface BaseProps extends CssProp, AriaProps, IconProps, RefProp, TestP
74
79
  * keyboard shortcut
75
80
  */
76
81
  hotKey?: string;
82
+ /**
83
+ * prevent click default, useful when button is within a `a` link
84
+ */
85
+ preventDefault?: boolean;
77
86
  stopPropagation?: boolean;
78
87
  onMouseOut?: MouseEventHandler;
79
88
  onMouseOver?: MouseEventHandler;
@@ -114,5 +123,5 @@ export type ButtonProps<Tag extends React.ElementType = "button"> = BaseProps &
114
123
  *
115
124
  * @see {@link https://adarshpastakia.github.io/react-fabric/?path=/docs/core-components-button--docs} for more details.
116
125
  */
117
- export declare const Button: <Tag extends React.ElementType = "button">({ as, ref, children, className, active, color, icon, iconBg, iconColor, iconAlign, altIcon, rtlFlip, rounded, size, disabled, loading, variant, badge, fullWidth, spinOnHover, onClick, actionMessage, stopPropagation, type, hotKey, showActionDone, showActionDoneEvent, tabIndex, "data-ref": dataRef, ...aria }: ButtonProps<Tag>) => import("react/jsx-runtime").JSX.Element;
126
+ export declare const Button: <Tag extends React.ElementType = "button">({ as, ref, children, className, active, color, icon, iconAlign, altIcon, rounded, size, disabled, loading, variant, badge, fullWidth, spinOnHover, onClick, actionMessage, preventDefault, stopPropagation, type, hotKey, showActionDone, showActionDoneEvent, tabIndex, "data-ref": dataRef, ...aria }: ButtonProps<Tag>) => import("react/jsx-runtime").JSX.Element;
118
127
  export {};
@@ -1,8 +1,8 @@
1
1
  import { type DragEvent, type MouseEventHandler } from "react";
2
2
  import { type ContentProps } from "../../core/content/Content";
3
3
  import { type HeadFootProps } from "../../core/headfoot/HeadFoot";
4
- import { type AriaProps, type ChildrenProp, type CssProp, type RefProp, type TestProps } from "../../types";
5
- export interface CardProps extends CssProp, AriaProps, TestProps, RefProp<HTMLDivElement>, ChildrenProp<React.ReactElement<HeadFootProps | ContentProps>> {
4
+ import { PolymorphicProps, type AriaProps, type ChildrenProp, type CssProp, type RefProp, type TestProps } from "../../types";
5
+ interface BaseProps extends CssProp, AriaProps, TestProps, RefProp<HTMLDivElement>, ChildrenProp<React.ReactElement<HeadFootProps | ContentProps>> {
6
6
  /**
7
7
  * apply flex fill styling
8
8
  */
@@ -40,6 +40,7 @@ export interface CardProps extends CssProp, AriaProps, TestProps, RefProp<HTMLDi
40
40
  */
41
41
  dragData?: KeyValue;
42
42
  }
43
+ export type CardProps<Tag extends React.ElementType = "div"> = BaseProps & PolymorphicProps<Tag>;
43
44
  /**
44
45
  * A component that displays a card with a header, body, and footer. It can be used to display content in a structured format.
45
46
  * It supports various features such as click handling, drag-and-drop functionality, and customizable styles.
@@ -74,4 +75,5 @@ export interface CardProps extends CssProp, AriaProps, TestProps, RefProp<HTMLDi
74
75
  *
75
76
  * @see {@link https://adarshpastakia.github.io/react-fabric/?path=/docs/core-components-card--docs} for more details.
76
77
  */
77
- export declare const Card: ({ children, className, bodyClassName, selected, selectedRibbon, onClick, onDragStart, flex, draggable, dragKey, dragData, ref, ...aria }: CardProps) => import("react/jsx-runtime").JSX.Element;
78
+ export declare const Card: <Tag extends React.ElementType = "div">({ children, className, bodyClassName, selected, selectedRibbon, onClick, onDragStart, flex, draggable, dragKey, dragData, ref, as, ...aria }: CardProps<Tag>) => import("react/jsx-runtime").JSX.Element;
79
+ export {};
@@ -1,6 +1,7 @@
1
1
  import { type ReactElement } from "react";
2
- import { type AriaProps, type ChildProp, type ColorType, type CssProp, type IconProps, type PaletteType, type PolymorphicProps, type RefProp, type SizeType, type TestProps } from "../../types";
3
- export interface ChipProps extends CssProp, AriaProps, IconProps, TestProps, ChildProp<string | ReactElement>, RefProp<HTMLDivElement> {
2
+ import { type AriaProps, type ChildProp, type ColorType, type CssProp, type PaletteType, type PolymorphicProps, type RefProp, type SizeType, type TestProps } from "../../types";
3
+ import { IconProps } from "../icon/Icon";
4
+ export interface ChipProps extends CssProp, AriaProps, TestProps, ChildProp<string | ReactElement>, RefProp<HTMLDivElement> {
4
5
  /**
5
6
  * chip size
6
7
  */
@@ -17,10 +18,18 @@ export interface ChipProps extends CssProp, AriaProps, IconProps, TestProps, Chi
17
18
  * full rounded edges
18
19
  */
19
20
  rounded?: boolean;
21
+ /**
22
+ * icon path or props
23
+ */
24
+ icon?: IconProps;
20
25
  /**
21
26
  * disabled state
22
27
  */
23
28
  disabled?: boolean;
29
+ /**
30
+ * prevent click default, useful when component is within a `a` link
31
+ */
32
+ preventDefault?: boolean;
24
33
  /**
25
34
  * prevent click propagation
26
35
  */
@@ -58,4 +67,4 @@ export interface ChipProps extends CssProp, AriaProps, IconProps, TestProps, Chi
58
67
  *
59
68
  * @see {@link https://adarshpastakia.github.io/react-fabric/?path=/docs/core-components-chip--docs} for more details.
60
69
  */
61
- export declare const Chip: <Tag extends React.ElementType = "div">({ ref, children, className, size, color, variant, icon, iconBg, iconColor, rtlFlip, disabled, onClick, onIconClick, onRemove, rounded, stopPropagation, as, ...aria }: ChipProps & PolymorphicProps<Tag>) => import("react/jsx-runtime").JSX.Element;
70
+ export declare const Chip: <Tag extends React.ElementType = "div">({ ref, children, className, size, color, variant, icon, disabled, onClick, onIconClick, onRemove, rounded, preventDefault, stopPropagation, as, ...aria }: ChipProps & PolymorphicProps<Tag>) => import("react/jsx-runtime").JSX.Element;
@@ -1,9 +1,13 @@
1
- import { type PaletteType, type AriaProps, type ColorType, type CssProp, type RefProp, type SizeType, type TestProps } from "../../types";
2
- export interface IconProps extends CssProp, AriaProps, RefProp, TestProps {
1
+ import { type AriaProps, type ColorType, type CssProp, type PaletteType, type RefProp, type SizeType, type TestProps } from "../../types";
2
+ export interface Props extends CssProp, AriaProps, RefProp, TestProps {
3
3
  /**
4
4
  * svg path / webfont className / 1-4 letter text
5
5
  */
6
- icon: string;
6
+ icon: string | JSX.Element;
7
+ /**
8
+ * icon image source URL, if failed to load then shows icon
9
+ */
10
+ iconSrc?: string;
7
11
  /**
8
12
  * background color (CSS color / tailwind color)
9
13
  */
@@ -38,6 +42,8 @@ export interface IconProps extends CssProp, AriaProps, RefProp, TestProps {
38
42
  */
39
43
  onClick?: React.MouseEventHandler;
40
44
  }
45
+ export type IconProps = string | Pick<Props, "icon" | "iconSrc" | "bg" | "color" | "size" | "rtlFlip" | "viewBox" | "rounded" | "animate">;
46
+ export declare const getIconProps: (props: IconProps) => Props;
41
47
  /**
42
48
  * A versatile icon component that supports SVG paths, webfont icons, and text icons.
43
49
  * It can be styled with background color, icon color, size, and animations.
@@ -67,4 +73,4 @@ export interface IconProps extends CssProp, AriaProps, RefProp, TestProps {
67
73
  *
68
74
  * @see {@link https://adarshpastakia.github.io/react-fabric/?path=/docs/core-components-icon--docs} for more details.
69
75
  */
70
- export declare const Icon: ({ ref, icon, bg, color, size, rtlFlip, animate, rounded, disabled, viewBox, className, onClick, ...rest }: IconProps) => import("react/jsx-runtime").JSX.Element;
76
+ export declare const Icon: ({ ref, icon, iconSrc, bg, color, size, rtlFlip, animate, rounded, disabled, viewBox, className, onClick, ...rest }: Props) => import("react/jsx-runtime").JSX.Element;
@@ -18,7 +18,7 @@ export { Divider } from "./divider/Divider";
18
18
  export { Dropdown, DropdownDismiss } from "./dropdown/Dropdown";
19
19
  export { DropdownTool } from "./dropdown/DropdownTool";
20
20
  export { EmptyContent } from "./empty/EmptyContent";
21
- export { Icon } from "./icon/Icon";
21
+ export { Icon, getIconProps } from "./icon/Icon";
22
22
  export { Image, Video } from "./media/Media";
23
23
  export { ContextMenu } from "./menu/ContextMenu";
24
24
  export { Menu } from "./menu/Menu";
@@ -21,4 +21,4 @@ import { type MenuItemProps } from "./types";
21
21
  *
22
22
  * @see {@link https://adarshpastakia.github.io/react-fabric/?path=/docs/core-components-menu--docs} for documentation.
23
23
  */
24
- export declare const MenuItem: <Tag extends React.ElementType = "button">({ as, label, color, className, icon, iconBg, iconColor, appendLabel, rtlFlip, altIcon, id, active, disabled, onClick, badge, hotKey, tabIndex, minimal, "data-open": childOpen, ref, ...aria }: MenuItemProps & PolymorphicProps<Tag>) => import("react/jsx-runtime").JSX.Element;
24
+ export declare const MenuItem: <Tag extends React.ElementType = "button">({ as, label, color, className, icon, appendLabel, altIcon, id, active, disabled, onClick, badge, hotKey, tabIndex, minimal, "data-open": childOpen, ref, ...aria }: MenuItemProps & PolymorphicProps<Tag>) => import("react/jsx-runtime").JSX.Element;
@@ -1,6 +1,7 @@
1
1
  import { type ElementType, type MouseEvent } from "react";
2
- import { type AriaProps, type BadgeType, type CallbackReturn, type ChildrenProp, type ColorState, type CssProp, type IconProps, type TestProps } from "../../types";
3
- export interface MenuItemProps extends CssProp, AriaProps, TestProps, IconProps {
2
+ import { type AriaProps, type BadgeType, type CallbackReturn, type ChildrenProp, type ColorState, type CssProp, type TestProps } from "../../types";
3
+ import { IconProps } from "../icon/Icon";
4
+ export interface MenuItemProps extends CssProp, AriaProps, TestProps {
4
5
  /**
5
6
  * menu id passed via menu.onClick
6
7
  */
@@ -17,6 +18,10 @@ export interface MenuItemProps extends CssProp, AriaProps, TestProps, IconProps
17
18
  * menu color
18
19
  */
19
20
  color?: ColorState;
21
+ /**
22
+ * icon path or props
23
+ */
24
+ icon?: IconProps;
20
25
  /**
21
26
  * item active
22
27
  */
@@ -1,7 +1,8 @@
1
1
  import { type ContentProps } from "../../core/content/Content";
2
2
  import { type HeadFootProps } from "../../core/headfoot/HeadFoot";
3
- import { type AriaProps, type ChildrenProp, type CollapseProps, type CssProp, type ExpandProps, type IconProps, type TestProps } from "../../types";
4
- export interface PanelProps extends CssProp, AriaProps, TestProps, IconProps, ExpandProps, CollapseProps, ChildrenProp<HeadFootProps | ContentProps> {
3
+ import { type AriaProps, type ChildrenProp, type CollapseProps, type CssProp, type ExpandProps, type TestProps } from "../../types";
4
+ import { IconProps } from "../icon/Icon";
5
+ export interface PanelProps extends CssProp, AriaProps, TestProps, ExpandProps, CollapseProps, ChildrenProp<HeadFootProps | ContentProps> {
5
6
  /**
6
7
  * panel id used by panel stack
7
8
  */
@@ -22,6 +23,10 @@ export interface PanelProps extends CssProp, AriaProps, TestProps, IconProps, Ex
22
23
  * title css classname(s)
23
24
  */
24
25
  titleClassName?: string;
26
+ /**
27
+ * icon path or props
28
+ */
29
+ icon?: IconProps;
25
30
  /**
26
31
  * loading state
27
32
  */
@@ -71,8 +76,6 @@ export interface PanelProps extends CssProp, AriaProps, TestProps, IconProps, Ex
71
76
  * <Panel
72
77
  * title="Panel Title"
73
78
  * icon={CoreIcons.info}
74
- * iconBg="bg-blue-500"
75
- * iconColor="text-white"
76
79
  * actions={<button>Action</button>}
77
80
  * expandable
78
81
  * collapsable
@@ -92,4 +95,4 @@ export interface PanelProps extends CssProp, AriaProps, TestProps, IconProps, Ex
92
95
  *
93
96
  * @see {@link https://adarshpastakia.github.io/react-fabric/?path=/docs/core-components-panel--docs} for more details.
94
97
  */
95
- export declare const Panel: ({ children, className, titleClassName, headerClassName, title, actions, icon, iconBg, iconColor, rtlFlip, panelId, height, width, minHeight, minWidth, maxHeight, maxWidth, loading, expandable, expanded: _expanded, onExpand, collapsable, collapsed: _collapsed, onCollapse, onClose, onBack, ...aria }: PanelProps) => import("react/jsx-runtime").JSX.Element;
98
+ export declare const Panel: ({ children, className, titleClassName, headerClassName, title, actions, icon, panelId, height, width, minHeight, minWidth, maxHeight, maxWidth, loading, expandable, expanded: _expanded, onExpand, collapsable, collapsed: _collapsed, onCollapse, onClose, onBack, ...aria }: PanelProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,6 +1,7 @@
1
1
  import { type ReactElement } from "react";
2
- import { type AriaProps, type BadgeType, type CallbackReturn, type ChildrenProp, type ColorState, type CssProp, type IconProps, type PolymorphicProps, type RefProp, type TestProps, type TooltipProp } from "../../types";
3
- export interface TabProps extends Partial<ChildrenProp>, CssProp, RefProp, AriaProps, TestProps, IconProps, TooltipProp {
2
+ import { type AriaProps, type BadgeType, type CallbackReturn, type ChildrenProp, type ColorState, type CssProp, type PolymorphicProps, type RefProp, type TestProps, type TooltipProp } from "../../types";
3
+ import { IconProps } from "../icon/Icon";
4
+ export interface TabProps extends Partial<ChildrenProp>, CssProp, RefProp, AriaProps, TestProps, TooltipProp {
4
5
  /**
5
6
  * tab id
6
7
  */
@@ -13,6 +14,10 @@ export interface TabProps extends Partial<ChildrenProp>, CssProp, RefProp, AriaP
13
14
  * tab color
14
15
  */
15
16
  color?: ColorState;
17
+ /**
18
+ * icon path or props
19
+ */
20
+ icon?: IconProps;
16
21
  /**
17
22
  * tab badge
18
23
  */
@@ -56,8 +61,6 @@ export interface TabProps extends Partial<ChildrenProp>, CssProp, RefProp, AriaP
56
61
  * id="tab1"
57
62
  * label="Tab 1"
58
63
  * icon="home"
59
- * iconBg="bg-blue-500"
60
- * iconColor="text-white"
61
64
  * badge="New"
62
65
  * onClick={(id) => console.log(`Tab clicked: ${id}`)}
63
66
  * onClose={() => console.log("Tab closed")}
@@ -73,4 +76,4 @@ export interface TabProps extends Partial<ChildrenProp>, CssProp, RefProp, AriaP
73
76
  *
74
77
  * @see {@link https://adarshpastakia.github.io/react-fabric/?path=/docs/core-components-tabpanel--docs} for more details.
75
78
  */
76
- export declare const Tab: <Tag extends React.ElementType = "button">({ ref, as, id, className, label, icon, iconBg, iconColor, rtlFlip, badge, disabled, onClose, active, onClick, tabFlex, color, actions, tooltip, activeClassName, ...aria }: TabProps & PolymorphicProps<Tag>) => import("react/jsx-runtime").JSX.Element;
79
+ export declare const Tab: <Tag extends React.ElementType = "button">({ ref, as, id, className, label, icon, badge, disabled, onClose, active, onClick, tabFlex, color, actions, tooltip, activeClassName, ...aria }: TabProps & PolymorphicProps<Tag>) => import("react/jsx-runtime").JSX.Element;
@@ -18,6 +18,10 @@ export interface TabPanelProps extends ChildrenProp<typeof Tab> {
18
18
  * tab button flex to fill tabs
19
19
  */
20
20
  tabFlex?: boolean;
21
+ /**
22
+ * rotate tab sideways for start/end orientation
23
+ */
24
+ tabRotate?: boolean;
21
25
  /**
22
26
  * tab button gap
23
27
  */
@@ -84,4 +88,4 @@ export interface TabPanelProps extends ChildrenProp<typeof Tab> {
84
88
  *
85
89
  * @see {@link https://adarshpastakia.github.io/react-fabric/?path=/docs/core-components-tabpanel--docs} for more details.
86
90
  */
87
- export declare const TabPanel: ({ children, headerClassName, orientation, activeTab, activeClassName, justify, variant, tabFlex, append, prepend, gap, onBeforeChange, onChange, }: TabPanelProps) => import("react/jsx-runtime").JSX.Element;
91
+ export declare const TabPanel: ({ children, headerClassName, orientation, activeTab, activeClassName, justify, variant, tabFlex, append, prepend, tabRotate, gap, onBeforeChange, onChange, }: TabPanelProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,6 +1,7 @@
1
1
  import { type ReactNode } from "react";
2
- import { type ChildrenProp, type CollapseProps, type CssProp, type Elements, type IconProps, type TestProps } from "../../types";
3
- export interface AsideProps extends IconProps, ChildrenProp, CollapseProps, CssProp, TestProps {
2
+ import { IconProps } from "../../components/icon/Icon";
3
+ import { type ChildrenProp, type CollapseProps, type CssProp, type Elements, type TestProps } from "../../types";
4
+ export interface AsideProps extends ChildrenProp, CollapseProps, CssProp, TestProps {
4
5
  /**
5
6
  * page title
6
7
  */
@@ -9,6 +10,10 @@ export interface AsideProps extends IconProps, ChildrenProp, CollapseProps, CssP
9
10
  * align inline-end
10
11
  */
11
12
  align?: "start" | "end";
13
+ /**
14
+ * icon path or props
15
+ */
16
+ icon?: IconProps;
12
17
  /**
13
18
  * header actions
14
19
  */
@@ -63,8 +68,6 @@ export interface AsideProps extends IconProps, ChildrenProp, CollapseProps, CssP
63
68
  * <Aside
64
69
  * title="Sidebar Title"
65
70
  * icon={CoreIcons.menu}
66
- * iconBg="bg-gray-200"
67
- * iconColor="text-gray-800"
68
71
  * rtlFlip={true}
69
72
  * className="custom-aside"
70
73
  * bodyClassName="custom-aside-body"
@@ -90,4 +93,4 @@ export interface AsideProps extends IconProps, ChildrenProp, CollapseProps, CssP
90
93
  *
91
94
  * @see {@link https://adarshpastakia.github.io/react-fabric/?path=/story/core-application--aside} for more details.
92
95
  */
93
- export declare const Aside: ({ children, title, icon, iconBg, iconColor, rtlFlip, className, bodyClassName, headerClassName, resizeable, flyout, onFlyout, collapsed, collapsable, onCollapse, actions, loading, align, width: wd, minWidth, maxWidth, "data-testid": testId, "data-test-value": testValue, }: AsideProps) => import("react/jsx-runtime").JSX.Element;
96
+ export declare const Aside: ({ children, title, icon, className, bodyClassName, headerClassName, resizeable, flyout, onFlyout, collapsed, collapsable, onCollapse, actions, loading, align, width: wd, minWidth, maxWidth, "data-testid": testId, "data-test-value": testValue, }: AsideProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,5 +1,6 @@
1
- import { type ChildrenProp, type IconProps, type RefProp, type TestProps } from "../../types";
2
- export interface PageProps extends IconProps, ChildrenProp, TestProps, RefProp<HTMLDivElement> {
1
+ import { IconProps } from "../../components/icon/Icon";
2
+ import { type ChildrenProp, type RefProp, type TestProps } from "../../types";
3
+ export interface PageProps extends ChildrenProp, TestProps, RefProp<HTMLDivElement> {
3
4
  /**
4
5
  * page title
5
6
  */
@@ -12,6 +13,10 @@ export interface PageProps extends IconProps, ChildrenProp, TestProps, RefProp<H
12
13
  * paper style drop shadow
13
14
  */
14
15
  paper?: boolean;
16
+ /**
17
+ * icon path or props
18
+ */
19
+ icon?: IconProps;
15
20
  /**
16
21
  * loading indicator
17
22
  */
@@ -31,8 +36,6 @@ export interface PageProps extends IconProps, ChildrenProp, TestProps, RefProp<H
31
36
  * <Page
32
37
  * title="My Page"
33
38
  * icon="home"
34
- * iconBg="bg-blue-500"
35
- * iconColor="text-white"
36
39
  * loading={false}
37
40
  * paper={true}
38
41
  * data-testid="my-page"
@@ -45,4 +48,4 @@ export interface PageProps extends IconProps, ChildrenProp, TestProps, RefProp<H
45
48
  *
46
49
  * @see {@link https://adarshpastakia.github.io/react-fabric/?path=/story/core-application--page} for more details.
47
50
  */
48
- export declare const Page: ({ ref, children, paper, title, titleClassName, icon, rtlFlip, iconBg, iconColor, loading, "data-testid": testId, "data-test-value": testValue, ...rest }: PageProps) => import("react/jsx-runtime").JSX.Element;
51
+ export declare const Page: ({ ref, children, paper, title, titleClassName, icon, loading, "data-testid": testId, "data-test-value": testValue, ...rest }: PageProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,9 +1,21 @@
1
- import { type ColorState, type Elements, type IconProps } from "../../types";
2
- export interface AlertProps extends Omit<IconProps, "iconBg" | "iconColor"> {
1
+ import { type ColorState, type Elements } from "../../types";
2
+ export interface AlertProps {
3
3
  /**
4
4
  * toast type
5
5
  */
6
6
  type?: "alert" | "confirm" | "prompt";
7
+ /**
8
+ * svg path / webfont className / 1-4 letter text
9
+ */
10
+ icon: string;
11
+ /**
12
+ * icon image source URL, if failed to load then shows icon
13
+ */
14
+ iconSrc?: string;
15
+ /**
16
+ * flip icon in rtl
17
+ */
18
+ rtlFlip?: boolean;
7
19
  /**
8
20
  * toast title
9
21
  */
@@ -37,4 +49,4 @@ export interface AlertProps extends Omit<IconProps, "iconBg" | "iconColor"> {
37
49
  */
38
50
  defaultValue?: string;
39
51
  }
40
- export declare const Alert: ({ title, message, color, icon, rtlFlip, actions, onClose, type, okLabel, cancelLabel, placeholder, defaultValue, }: AlertProps) => import("react/jsx-runtime").JSX.Element;
52
+ export declare const Alert: ({ title, message, color, icon, iconSrc, rtlFlip, actions, onClose, type, okLabel, cancelLabel, placeholder, defaultValue, }: AlertProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,7 +1,7 @@
1
- import { type ElementType } from "react";
2
- import { type AriaProps, type CallbackReturn, type ChildrenProp, type Elements, type IconProps, type TestProps } from "../../types";
3
- export interface FlyoutProps extends AriaProps, TestProps, Omit<IconProps, "icon">, ChildrenProp {
4
- icon?: string | ElementType<IconProps>;
1
+ import { IconProps } from "../../components/icon/Icon";
2
+ import { type AriaProps, type CallbackReturn, type ChildrenProp, type Elements, type TestProps } from "../../types";
3
+ export interface FlyoutProps extends AriaProps, TestProps, ChildrenProp {
4
+ icon?: IconProps;
5
5
  /**
6
6
  * flyout alignment
7
7
  */
@@ -38,6 +38,10 @@ export interface FlyoutProps extends AriaProps, TestProps, Omit<IconProps, "icon
38
38
  * minimum width
39
39
  */
40
40
  minWidth?: string | number;
41
+ /**
42
+ * portal root element
43
+ */
44
+ root?: HTMLElement;
41
45
  /**
42
46
  * hide backdrop mask
43
47
  */
@@ -55,4 +59,4 @@ export interface FlyoutProps extends AriaProps, TestProps, Omit<IconProps, "icon
55
59
  */
56
60
  onBeforeClose?: (...args: AnyObject) => CallbackReturn;
57
61
  }
58
- export declare const Flyout: ({ icon, iconBg, iconColor, iconClassName, rtlFlip, title, actions, closeOnClick, headerClassName, onClose, onBeforeClose, children, loading, size, width, minWidth, hideMask, align, ...aria }: FlyoutProps) => import("react/jsx-runtime").JSX.Element;
62
+ export declare const Flyout: ({ icon, iconClassName, title, actions, closeOnClick, headerClassName, onClose, onBeforeClose, children, loading, size, width, minWidth, root, hideMask, align, ...aria }: FlyoutProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,5 +1,17 @@
1
- import { type ColorState, type Elements, type IconProps } from "../../types";
2
- export interface MessageProps extends Omit<IconProps, "iconBg" | "iconColor"> {
1
+ import { type ColorState, type Elements } from "../../types";
2
+ export interface MessageProps {
3
+ /**
4
+ * svg path / webfont className / 1-4 letter text
5
+ */
6
+ icon: string;
7
+ /**
8
+ * icon image source URL, if failed to load then shows icon
9
+ */
10
+ iconSrc?: string;
11
+ /**
12
+ * flip icon in rtl
13
+ */
14
+ rtlFlip?: boolean;
3
15
  /**
4
16
  * message title
5
17
  */
@@ -17,4 +29,4 @@ export interface MessageProps extends Omit<IconProps, "iconBg" | "iconColor"> {
17
29
  */
18
30
  actions?: Elements<JSX.Element>;
19
31
  }
20
- export declare const Message: ({ title, message, color, icon, rtlFlip, actions, onClose, }: MessageProps) => import("react/jsx-runtime").JSX.Element;
32
+ export declare const Message: ({ title, message, color, icon, iconSrc, rtlFlip, actions, onClose, }: MessageProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,7 +1,7 @@
1
- import { type ElementType } from "react";
2
- import { type AriaProps, type CallbackReturn, type ChildrenProp, type Elements, type IconProps, type TestProps } from "../../types";
3
- export interface ModalProps extends AriaProps, TestProps, Omit<IconProps, "icon">, ChildrenProp {
4
- icon?: string | ElementType<IconProps>;
1
+ import { IconProps } from "../../components/icon/Icon";
2
+ import { type AriaProps, type CallbackReturn, type ChildrenProp, type Elements, type TestProps } from "../../types";
3
+ export interface ModalProps extends AriaProps, TestProps, ChildrenProp {
4
+ icon?: IconProps;
5
5
  /**
6
6
  * header className
7
7
  */
@@ -49,7 +49,7 @@ export interface ModalProps extends AriaProps, TestProps, Omit<IconProps, "icon"
49
49
  /**
50
50
  * hide mask background
51
51
  */
52
- noMask?: boolean;
52
+ hideMask?: boolean;
53
53
  /**
54
54
  * close handler
55
55
  */
@@ -59,4 +59,4 @@ export interface ModalProps extends AriaProps, TestProps, Omit<IconProps, "icon"
59
59
  */
60
60
  onBeforeClose?: (...args: AnyObject) => CallbackReturn;
61
61
  }
62
- export declare const Modal: ({ icon, iconBg, iconColor, iconClassName, rtlFlip, title, actions, headerClassName, onClose, onBeforeClose, children, loading, root, size, noMask, width, height, minHeight, minWidth, ...aria }: ModalProps) => import("react/jsx-runtime").JSX.Element;
62
+ export declare const Modal: ({ icon, iconClassName, title, actions, headerClassName, onClose, onBeforeClose, children, loading, root, size, hideMask, width, height, minHeight, minWidth, ...aria }: ModalProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,9 +1,21 @@
1
- import { type ColorState, type Elements, type IconProps } from "../../types";
2
- export interface ToastProps extends Omit<IconProps, "iconBg" | "iconColor"> {
1
+ import { type ColorState, type Elements } from "../../types";
2
+ export interface ToastProps {
3
3
  /**
4
4
  * toast type
5
5
  */
6
6
  type?: "alert" | "confirm";
7
+ /**
8
+ * svg path / webfont className / 1-4 letter text
9
+ */
10
+ icon: string;
11
+ /**
12
+ * icon image source URL, if failed to load then shows icon
13
+ */
14
+ iconSrc?: string;
15
+ /**
16
+ * flip icon in rtl
17
+ */
18
+ rtlFlip?: boolean;
7
19
  /**
8
20
  * toast title
9
21
  */
@@ -29,4 +41,4 @@ export interface ToastProps extends Omit<IconProps, "iconBg" | "iconColor"> {
29
41
  */
30
42
  cancelLabel?: string;
31
43
  }
32
- export declare const Toast: ({ title, message, color, icon, rtlFlip, actions, onClose, onCloseAll, type, okLabel, cancelLabel, }: ToastProps) => import("react/jsx-runtime").JSX.Element;
44
+ export declare const Toast: ({ title, message, color, icon, iconSrc, rtlFlip, actions, onClose, onCloseAll, type, okLabel, cancelLabel, }: ToastProps) => import("react/jsx-runtime").JSX.Element;
@@ -180,7 +180,7 @@ export declare namespace CoreIcons {
180
180
  const mediaAspect = "M19,12H17V15H14V17H19V12M7,9H10V7H5V12H7V9M21,3H3A2,2 0 0,0 1,5V19A2,2 0 0,0 3,21H21A2,2 0 0,0 23,19V5A2,2 0 0,0 21,3M21,19H3V5H21V19Z";
181
181
  const mediaZoomer = "M15 0.004c-4.97 0-9 4.030-9 9 0 1.52 0.38 2.95 1.046 4.206l-6.258 6.256 0.005 0.005c-0.489 0.481-0.794 1.147-0.794 1.887 0 1.462 1.185 2.647 2.647 2.647 0.739 0 1.406-0.304 1.886-0.794l-0.002-0.001 6.256-6.255c1.257 0.668 2.689 1.050 4.213 1.050 4.97 0 9-4.030 9-9s-4.030-9-9-9zM3.596 22.273c-0.241 0.25-0.576 0.407-0.95 0.407-0.731 0-1.324-0.592-1.324-1.323 0-0.373 0.157-0.707 0.407-0.95l-0.007-0.006 6.050-6.050c0.529 0.713 1.159 1.343 1.87 1.874l-6.047 6.047zM15 16.505c-4.142 0-7.5-3.359-7.5-7.5s3.358-7.5 7.5-7.5c4.141 0 7.5 3.358 7.5 7.5s-3.359 7.5-7.5 7.5zM15 3.754c0.206 0 0.375 0.168 0.375 0.375s-0.169 0.375-0.375 0.375c-2.486 0-4.5 2.015-4.5 4.5 0 0.207-0.168 0.375-0.375 0.375s-0.375-0.168-0.375-0.375c0-2.9 2.35-5.25 5.25-5.25z";
182
182
  const mediaOrient = "M7.34,6.41L0.86,12.9L7.35,19.38L13.84,12.9L7.34,6.41M3.69,12.9L7.35,9.24L11,12.9L7.34,16.56L3.69,12.9M19.36,6.64C17.61,4.88 15.3,4 13,4V0.76L8.76,5L13,9.24V6C14.79,6 16.58,6.68 17.95,8.05C20.68,10.78 20.68,15.22 17.95,17.95C16.58,19.32 14.79,20 13,20C12.03,20 11.06,19.79 10.16,19.39L8.67,20.88C10,21.62 11.5,22 13,22C15.3,22 17.61,21.12 19.36,19.36C22.88,15.85 22.88,10.15 19.36,6.64Z";
183
- const mediaCrop = "M7,17V1H5V5H1V7H5V17A2,2 0 0,0 7,19H17V23H19V19H23V17M17,15H19V7C19,5.89 18.1,5 17,5H9V7H17V15Z";
183
+ const mediaCrop = "M13,17H17V13H19V17H23V19H19V23H17V19H13V17M11,17V19H9V17H11M7,17V19H5V17H7M19,9V11H17V9H19M19,5V7H17V5H19M15,5V7H13V5H15M11,5V7H9V5H11M7,5V7H5V5H7M7,13V15H5V13H7M7,9V11H5V9H7Z";
184
184
  const mediaImage = "M19,19H5V5H19M19,3H5A2,2 0 0,0 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V5A2,2 0 0,0 19,3M13.96,12.29L11.21,15.83L9.25,13.47L6.5,17H17.5L13.96,12.29Z";
185
185
  const mediaVideo = "M15,8V16H5V8H15M16,6H4A1,1 0 0,0 3,7V17A1,1 0 0,0 4,18H16A1,1 0 0,0 17,17V13.5L21,17.5V6.5L17,10.5V7A1,1 0 0,0 16,6Z";
186
186
  const mediaAudio = "M17.3,11C17.3,14 14.76,16.1 12,16.1C9.24,16.1 6.7,14 6.7,11H5C5,14.41 7.72,17.23 11,17.72V21H13V17.72C16.28,17.23 19,14.41 19,11M10.8,4.9C10.8,4.24 11.34,3.7 12,3.7C12.66,3.7 13.2,4.24 13.2,4.9L13.19,11.1C13.19,11.76 12.66,12.3 12,12.3C11.34,12.3 10.8,11.76 10.8,11.1M12,14A3,3 0 0,0 15,11V5A3,3 0 0,0 12,2A3,3 0 0,0 9,5V11A3,3 0 0,0 12,14Z";
@@ -202,6 +202,7 @@ export declare namespace CoreIcons {
202
202
  const mediaVolume3 = "M14,3.23V5.29C16.89,6.15 19,8.83 19,12C19,15.17 16.89,17.84 14,18.7V20.77C18,19.86 21,16.28 21,12C21,7.72 18,4.14 14,3.23M16.5,12C16.5,10.23 15.5,8.71 14,7.97V16C15.5,15.29 16.5,13.76 16.5,12M3,9V15H7L12,20V4L7,9H3Z";
203
203
  const mediaComment = "M9,22A1,1 0 0,1 8,21V18H4A2,2 0 0,1 2,16V4C2,2.89 2.9,2 4,2H20A2,2 0 0,1 22,4V16A2,2 0 0,1 20,18H13.9L10.2,21.71C10,21.9 9.75,22 9.5,22V22H9M10,16V19.08L13.08,16H20V4H4V16H10M6,7H18V9H6V7M6,11H15V13H6V11Z";
204
204
  const mediaCommentAdd = "M9,22A1,1 0 0,1 8,21V18H4A2,2 0 0,1 2,16V4C2,2.89 2.9,2 4,2H20A2,2 0 0,1 22,4V16A2,2 0 0,1 20,18H13.9L10.2,21.71C10,21.9 9.75,22 9.5,22V22H9M10,16V19.08L13.08,16H20V4H4V16H10M11,6H13V9H16V11H13V14H11V11H8V9H11V6Z";
205
+ const mediaCapture = "M12,10L11.06,12.06L9,13L11.06,13.94L12,16L12.94,13.94L15,13L12.94,12.06L12,10M20,5H16.83L15,3H9L7.17,5H4A2,2 0 0,0 2,7V19A2,2 0 0,0 4,21H20A2,2 0 0,0 22,19V7A2,2 0 0,0 20,5M20,19H4V7H8.05L8.64,6.35L9.88,5H14.12L15.36,6.35L15.95,7H20V19M12,8A5,5 0 0,0 7,13A5,5 0 0,0 12,18A5,5 0 0,0 17,13A5,5 0 0,0 12,8M12,16A3,3 0 0,1 9,13A3,3 0 0,1 12,10A3,3 0 0,1 15,13A3,3 0 0,1 12,16Z";
205
206
  const mediaLightness = "M12,18A6,6 0 0,1 6,12A6,6 0 0,1 12,6A6,6 0 0,1 18,12A6,6 0 0,1 12,18M20,15.31L23.31,12L20,8.69V4H15.31L12,0.69L8.69,4H4V8.69L0.69,12L4,15.31V20H8.69L12,23.31L15.31,20H20V15.31Z";
206
207
  const mediaColor = "M19,11.5C19,11.5 17,13.67 17,15A2,2 0 0,0 19,17A2,2 0 0,0 21,15C21,13.67 19,11.5 19,11.5M5.21,10L10,5.21L14.79,10M16.56,8.94L7.62,0L6.21,1.41L8.59,3.79L3.44,8.94C2.85,9.5 2.85,10.47 3.44,11.06L8.94,16.56C9.23,16.85 9.62,17 10,17C10.38,17 10.77,16.85 11.06,16.56L16.56,11.06C17.15,10.47 17.15,9.5 16.56,8.94Z";
207
208
  const mediaInvert = "M12,19.58V19.58C10.4,19.58 8.89,18.96 7.76,17.83C6.62,16.69 6,15.19 6,13.58C6,12 6.62,10.47 7.76,9.34L12,5.1M17.66,7.93L12,2.27V2.27L6.34,7.93C3.22,11.05 3.22,16.12 6.34,19.24C7.9,20.8 9.95,21.58 12,21.58C14.05,21.58 16.1,20.8 17.66,19.24C20.78,16.12 20.78,11.05 17.66,7.93Z";
@@ -84,24 +84,6 @@ export type PolymorphicProps<AsTag extends ReactTag> = Omit<PropsOf<AsTag>, "chi
84
84
  */
85
85
  as?: AsTag;
86
86
  };
87
- export interface IconProps {
88
- /**
89
- * svg path / image url
90
- */
91
- icon?: string;
92
- /**
93
- * flip icon in rtl
94
- */
95
- rtlFlip?: boolean;
96
- /**
97
- * icon background color
98
- */
99
- iconBg?: ColorType | PaletteType | string;
100
- /**
101
- * icon color
102
- */
103
- iconColor?: ColorType | PaletteType | string;
104
- }
105
87
  export interface CollapseProps {
106
88
  /**
107
89
  * Allow collapsing