@muraldevkit/ui-toolkit 4.52.1 → 4.52.3

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.
@@ -3,6 +3,7 @@ import { MrlButtonProps } from '../MrlButton';
3
3
  import { DSIconType } from '../../svg';
4
4
  import { DataQa } from '../../../utils/dataQa';
5
5
  export declare const DEFAULT_RESET_TIME = 4000;
6
+ export declare const DEFAULT_FEEDBACK_TIME = 500;
6
7
  export type PossibleState = 'normal' | 'processing' | 'success' | 'error';
7
8
  export type MrlProcessingButtonConfig = {
8
9
  normal: {
@@ -11,7 +12,12 @@ export type MrlProcessingButtonConfig = {
11
12
  };
12
13
  processing: {
13
14
  action: () => Promise<void>;
14
- text: string;
15
+ /**
16
+ * The minimum time to show the processing state before executing the action.
17
+ * This provides visual feedback to users that their action was registered.
18
+ */
19
+ feedbackTime?: number;
20
+ text?: string;
15
21
  };
16
22
  success?: {
17
23
  text: string;
@@ -22,7 +28,7 @@ export type MrlProcessingButtonConfig = {
22
28
  icon?: DSIconType;
23
29
  };
24
30
  };
25
- export interface MrlProcessingButtonProps extends Omit<MrlButtonProps, 'ref'>, DataQa {
31
+ export interface MrlProcessingButtonProps extends Omit<MrlButtonProps, 'ref' | 'text'>, DataQa {
26
32
  /**
27
33
  * The configuration for the processing button.
28
34
  */
@@ -1,3 +1,4 @@
1
1
  export * from './MrlAnimatedIconButton';
2
2
  export * from './MrlButton';
3
3
  export * from './MrlIconButton';
4
+ export * from './MrlProcessingButton';
@@ -23,7 +23,16 @@ export interface MrlMenuItemProps {
23
23
  onMouseOut?: (e?: React.MouseEvent) => void;
24
24
  /** Data-qa attribute for the menu item */
25
25
  dataQa?: string;
26
- /** Role for the menu item */
26
+ /**
27
+ * Role for the menu item
28
+ *
29
+ * When using `menuitemcheckbox` or `menuitemradio`, the menu item will be treated as a selectable item,
30
+ * aria-checked will be set to 'true' or 'false' based on the selected state.
31
+ *
32
+ * @default 'menuitem' - for regular menu items
33
+ * @example 'menuitemcheckbox' - for checkbox menu items
34
+ * @example 'menuitemradio' - for radio menu items
35
+ */
27
36
  role?: 'menuitem' | 'menuitemcheckbox' | 'menuitemradio';
28
37
  /** If the menu item is selected */
29
38
  selected?: boolean;
@@ -80,7 +80,7 @@ export declare const colorPictoStoryData: {
80
80
  export declare const animateStoryData: {
81
81
  args: {
82
82
  delay: number;
83
- state: "stop" | "play";
83
+ state: "play" | "stop";
84
84
  };
85
85
  argTypes: {
86
86
  delay: {