@muraldevkit/ui-toolkit 2.23.1 → 2.25.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.
@@ -5,5 +5,5 @@ import './MrlAnimatedIconButton.scss';
5
5
  interface MrlAnimatedIconButtonProps extends Omit<MrlIconButtonProps, 'icon'> {
6
6
  icon: MrlSvgAnimateProps;
7
7
  }
8
- export declare const MrlAnimatedIconButton: React.ForwardRefExoticComponent<Pick<MrlAnimatedIconButtonProps, "form" | "slot" | "style" | "title" | "text" | "dir" | "name" | "disabled" | "id" | "defaultValue" | "state" | "children" | "kind" | "size" | "attrs" | "defaultChecked" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "draggable" | "hidden" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "inputMode" | "is" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "type" | "key" | "value" | "client" | "icon" | "badge" | "disableEvents" | "loading" | "loadingText" | "position" | "tipAnchor" | "toggleAria" | "toggleStyle" | "wrapperClassName" | "autoFocus" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget"> & React.RefAttributes<HTMLButtonElement>>;
8
+ export declare const MrlAnimatedIconButton: React.ForwardRefExoticComponent<Pick<MrlAnimatedIconButtonProps, "form" | "slot" | "style" | "title" | "text" | "dir" | "name" | "children" | "disabled" | "id" | "defaultValue" | "state" | "kind" | "size" | "attrs" | "defaultChecked" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "draggable" | "hidden" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "inputMode" | "is" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "type" | "key" | "value" | "client" | "icon" | "badge" | "disableEvents" | "loading" | "loadingText" | "position" | "tipAnchor" | "toggleAria" | "toggleStyle" | "wrapperClassName" | "autoFocus" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget"> & React.RefAttributes<HTMLButtonElement>>;
9
9
  export {};
@@ -75,4 +75,4 @@ export interface MrlButtonProps extends Omit<MrlComponentProps, 'style'>, React.
75
75
  */
76
76
  toggleStyle?: ToggleStyle;
77
77
  }
78
- export declare const MrlButton: React.ForwardRefExoticComponent<Pick<MrlButtonProps, "form" | "slot" | "style" | "title" | "text" | "dir" | "name" | "disabled" | "id" | "defaultValue" | "state" | "children" | "kind" | "size" | "attrs" | "defaultChecked" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "draggable" | "hidden" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "inputMode" | "is" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "type" | "key" | "value" | "icon" | "badge" | "disableEvents" | "loading" | "loadingText" | "toggleAria" | "toggleStyle" | "autoFocus" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "iconPos"> & React.RefAttributes<HTMLButtonElement>>;
78
+ export declare const MrlButton: React.ForwardRefExoticComponent<Pick<MrlButtonProps, "form" | "slot" | "style" | "title" | "text" | "dir" | "name" | "children" | "disabled" | "id" | "defaultValue" | "state" | "kind" | "size" | "attrs" | "defaultChecked" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "draggable" | "hidden" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "inputMode" | "is" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "type" | "key" | "value" | "icon" | "badge" | "disableEvents" | "loading" | "loadingText" | "toggleAria" | "toggleStyle" | "autoFocus" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "iconPos"> & React.RefAttributes<HTMLButtonElement>>;
@@ -91,4 +91,4 @@ export interface MrlIconButtonProps extends Omit<MrlComponentProps, 'style'>, Re
91
91
  */
92
92
  wrapperClassName?: string;
93
93
  }
94
- export declare const MrlIconButton: React.ForwardRefExoticComponent<Pick<MrlIconButtonProps, "form" | "slot" | "style" | "title" | "text" | "dir" | "name" | "disabled" | "id" | "defaultValue" | "state" | "children" | "kind" | "size" | "attrs" | "defaultChecked" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "draggable" | "hidden" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "inputMode" | "is" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "type" | "key" | "value" | "client" | "icon" | "badge" | "disableEvents" | "loading" | "loadingText" | "position" | "tipAnchor" | "toggleAria" | "toggleStyle" | "wrapperClassName" | "autoFocus" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget"> & React.RefAttributes<HTMLButtonElement>>;
94
+ export declare const MrlIconButton: React.ForwardRefExoticComponent<Pick<MrlIconButtonProps, "form" | "slot" | "style" | "title" | "text" | "dir" | "name" | "children" | "disabled" | "id" | "defaultValue" | "state" | "kind" | "size" | "attrs" | "defaultChecked" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "draggable" | "hidden" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "inputMode" | "is" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "type" | "key" | "value" | "client" | "icon" | "badge" | "disableEvents" | "loading" | "loadingText" | "position" | "tipAnchor" | "toggleAria" | "toggleStyle" | "wrapperClassName" | "autoFocus" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget"> & React.RefAttributes<HTMLButtonElement>>;
@@ -0,0 +1,62 @@
1
+ import React from 'react';
2
+ interface ErrorProps {
3
+ children?: React.ReactNode;
4
+ /**
5
+ * Required to log the error to observability.
6
+ *
7
+ * @param error
8
+ * @param errorInfo
9
+ * @returns void
10
+ */
11
+ logError: (error: Error, errorInfo: React.ErrorInfo) => void;
12
+ /**
13
+ * Fallback component to render when there is an error.
14
+ */
15
+ fallback: React.ReactNode;
16
+ }
17
+ interface State {
18
+ hasError: boolean;
19
+ }
20
+ /**
21
+ * When an error occurs during rendering, this component catches the error.
22
+ * Renders a fallback component for a user friendly msg and calls the log error callback.
23
+ *
24
+ * Error boundaries DO NOT catch errors for:
25
+ * Event handlers
26
+ * Asynchronous code (e.g. setTimeout or requestAnimationFrame callbacks)
27
+ * Server side rendering
28
+ * Errors thrown in the error boundary itself (rather than its children)
29
+ *
30
+ * @param ErrorProps
31
+ * @returns ErrorBoundary component
32
+ */
33
+ declare class ErrorBoundary extends React.Component<ErrorProps, State> {
34
+ /**
35
+ * Error boundry
36
+ *
37
+ * @param props fallback and logError
38
+ */
39
+ constructor(props: ErrorProps);
40
+ /**
41
+ * Update state so the next render will show the fallback UI.
42
+ *
43
+ * @param _error Error
44
+ * @returns State
45
+ */
46
+ static getDerivedStateFromError: (_error: Error) => State;
47
+ /**
48
+ * componentDidCatch react lifecycle method
49
+ *
50
+ * @param error error object
51
+ * @param errorInfo react.error info
52
+ */
53
+ componentDidCatch(error: Error, errorInfo: React.ErrorInfo): void;
54
+ /**
55
+ * Renders react node wrapped in error handler.
56
+ *
57
+ * @returns React.ReactNode
58
+ */
59
+ render(): React.ReactNode;
60
+ }
61
+ export declare const MrlErrorBoundary: typeof ErrorBoundary;
62
+ export {};
@@ -0,0 +1 @@
1
+ export * from './MrlErrorBoundary';
@@ -1,6 +1,7 @@
1
1
  export * from './button';
2
2
  export * from './container';
3
3
  export * from './divider';
4
+ export * from './error-boundary';
4
5
  export * from './focus-trap';
5
6
  export * from './form';
6
7
  export * from './grid';
@@ -1,16 +1,22 @@
1
1
  import React, { RefObject } from 'react';
2
2
  import { MenuPosition, VerticalAlign, HorizontalAlign } from '../constants';
3
- export type ActionType = 'ArrowUp' | 'ArrowDown' | 'Enter' | 'Escape' | ' ' | 'click' | null;
3
+ export type ActionType = 'ArrowUp' | 'ArrowDown' | 'ArrowRight' | 'Enter' | 'Escape' | ' ' | 'click' | null;
4
4
  export interface MrlMenuState {
5
5
  actionType: ActionType;
6
6
  isOpen: boolean;
7
7
  }
8
- interface MrlMenuProps {
8
+ export interface MrlMenuProps {
9
9
  /** Children to be rendered within the menu component*/
10
10
  children: React.ReactNode;
11
11
  /** Unique identifier for the menu */
12
12
  id?: string;
13
- /** If the menu is a submenu */
13
+ /**
14
+ * Private isSubMenu prop for use with MrlMenuItem
15
+ *
16
+ * !!! Please do not use this prop directly, it is only used internally by MrlMenuItem !!!
17
+ *
18
+ * @private
19
+ */
14
20
  isSubMenu?: boolean;
15
21
  /**
16
22
  * Kind of menu
@@ -19,6 +25,12 @@ interface MrlMenuProps {
19
25
  * @default 'default'
20
26
  */
21
27
  kind?: 'default' | 'compact';
28
+ /**
29
+ * Offset of the menu from the trigger element in pixels
30
+ *
31
+ * @default 10px
32
+ */
33
+ menuOffset?: number;
22
34
  /**
23
35
  * Horizontal and vertical alignment of the menu relative to the trigger element
24
36
  *
@@ -53,12 +65,6 @@ interface MrlMenuProps {
53
65
  * @param type - type of close event
54
66
  */
55
67
  onClose?: (type?: string) => void;
56
- /**
57
- * Callback to be called when the menu is opened
58
- *
59
- * @param type - type of close event
60
- */
61
- onOpen?: (type?: string) => void;
62
68
  }
63
69
  /**
64
70
  * MrlMenu component
@@ -68,5 +74,4 @@ interface MrlMenuProps {
68
74
  * @param {MrlMenuProps} props - The props for the MrlMenu component
69
75
  * @returns {Element} - rendered MrlMenu component
70
76
  */
71
- export declare function MrlMenu({ children, id, isSubMenu, kind, menuPosition, menuState, verticalAlign, horizontalAlign, onClose, onOpen, triggerRef }: MrlMenuProps): JSX.Element;
72
- export {};
77
+ export declare function MrlMenu({ children, id, isSubMenu, kind, menuOffset, menuPosition, menuState, verticalAlign, horizontalAlign, onClose, triggerRef }: MrlMenuProps): JSX.Element;
@@ -0,0 +1,37 @@
1
+ /**
2
+ * Find the closest menu parent of an element
3
+ *
4
+ * @param el - The element to start searching from
5
+ * @returns The closest menu parent or null if none is found
6
+ */
7
+ export declare const findClosestMenuParent: (el: HTMLElement | null) => HTMLElement | null | undefined;
8
+ /**
9
+ * Find the interactive element immediately before or after a reference element
10
+ *
11
+ * @param ref - The reference element
12
+ * @param direction - The direction to search in
13
+ * @returns The interactive element or null if none is found
14
+ */
15
+ export declare const findInteractiveElement: (ref: React.RefObject<HTMLElement> | undefined, direction?: 'next' | 'previous') => HTMLElement | null;
16
+ /**
17
+ * Calculate the horizontal positioning of the submenu
18
+ *
19
+ * @param overlapsRight - Whether the menu overlaps the right side of the screen
20
+ * @param overlapsLeft - Whether the menu overlaps the left side of the screen
21
+ * @param menuRect - The bounding rectangle of the menu
22
+ * @param triggerRef - The ref of the trigger element
23
+ * @returns The left position of the menu
24
+ */
25
+ export declare const calculateLeftPosition: (overlapsRight: boolean, overlapsLeft: boolean, menuRect: DOMRect, triggerRef: React.RefObject<HTMLElement>) => string;
26
+ /**
27
+ * Calculate vertical positioning of the submenu
28
+ *
29
+ * @param overlapsRight - Whether the menu overlaps the right side of the screen
30
+ * @param overlapsLeft - Whether the menu overlaps the left side of the screen
31
+ * @param triggerRef - The ref of the trigger element
32
+ * @param menuRect - The bounding rectangle of the menu
33
+ * @param parentMenu - The parent menu element
34
+ * @param triggerRect - The bounding rectangle of the trigger element
35
+ * @returns The top position of the menu
36
+ */
37
+ export declare const calculateTopPosition: (overlapsRight: boolean, overlapsLeft: boolean, triggerRef: React.RefObject<HTMLElement>, menuRect: DOMRect, parentMenu: HTMLElement, triggerRect: DOMRect) => string;
@@ -11,7 +11,7 @@ interface MrlMenuItemProps {
11
11
  /** Unique ID for the menu item */
12
12
  id?: string;
13
13
  /** Callback to be called when the menu item is clicked */
14
- onClick?: (e: React.MouseEvent<HTMLElement>) => void;
14
+ onClick: (e: React.MouseEvent<HTMLElement>) => void;
15
15
  /** Data-qa attribute for the menu item */
16
16
  dataQa?: string;
17
17
  /** If the menu item is selected */
@@ -0,0 +1,33 @@
1
+ import React from 'react';
2
+ interface MrlMenuItemLinkProps {
3
+ /** ID for associated description */
4
+ ariaDescribedBy?: string;
5
+ /**
6
+ Children to be rendered within the menu component
7
+ */
8
+ children: React.ReactNode | string;
9
+ /** If the menu item is disabled */
10
+ disabled?: boolean;
11
+ /** Href for the menu item */
12
+ href: string;
13
+ /** Target for links */
14
+ target?: string;
15
+ /** Unique ID for the menu item */
16
+ id?: string;
17
+ /** Callback to be called when the menu item is clicked */
18
+ onClick?: (e: React.MouseEvent<HTMLElement>) => void;
19
+ /** Data-qa attribute for the menu item */
20
+ dataQa?: string;
21
+ /** If the menu item is selected */
22
+ selected?: boolean;
23
+ }
24
+ /**
25
+ * MrlMenuItem component
26
+ *
27
+ * Renders a menu item to be used within the MrlMenu component
28
+ *
29
+ * @param {MrlMenuItemLinkProps} props - The props for the MrlMenuItem component
30
+ * @returns {Element} - rendered MrlMenuItem component
31
+ */
32
+ export declare function MrlMenuItemLink({ ariaDescribedBy, children, dataQa, disabled, href, id, onClick, selected, target }: MrlMenuItemLinkProps): JSX.Element;
33
+ export {};
@@ -0,0 +1 @@
1
+ export * from './MrlMenuItemLink';
@@ -1,4 +1,4 @@
1
- export type MenuPosition = 'bottom' | 'left' | 'right' | 'top';
1
+ export type MenuPosition = 'bottom' | 'left' | 'right' | 'top' | 'below';
2
2
  export type HorizontalAlign = 'left' | 'right' | 'center';
3
3
  export type VerticalAlign = 'top' | 'bottom' | 'center';
4
4
  export type MenuIgnore = 'ignore';
@@ -0,0 +1,20 @@
1
+ /// <reference types="react" />
2
+ import { MrlMenuState } from '..';
3
+ import { MenuPosition, VerticalAlign, HorizontalAlign } from '../constants';
4
+ interface MenuWithLinkProps {
5
+ menuAlign?: MenuPosition;
6
+ kind?: 'default' | 'compact';
7
+ verticalAlign?: VerticalAlign;
8
+ horizontalAlign?: HorizontalAlign;
9
+ menuState?: MrlMenuState;
10
+ onClose?: () => void;
11
+ triggerAlignment?: 'left' | 'right' | 'center';
12
+ }
13
+ /**
14
+ * Demo of a menu with a trigger for stories and testing
15
+ *
16
+ * @param {MenuWithLinkProps} props - The props for the menu with trigger
17
+ * @returns {Element} The menu with trigger demo
18
+ */
19
+ export declare const MenuWithLink: ({ menuAlign, verticalAlign, horizontalAlign, kind, menuState, onClose, triggerAlignment }: MenuWithLinkProps) => JSX.Element;
20
+ export {};
@@ -0,0 +1,20 @@
1
+ /// <reference types="react" />
2
+ import { MrlMenuState } from '../';
3
+ import { MenuPosition, VerticalAlign, HorizontalAlign } from '../constants';
4
+ interface MenuWithSubmenuProps {
5
+ menuAlign?: MenuPosition;
6
+ kind?: 'default' | 'compact';
7
+ verticalAlign?: VerticalAlign;
8
+ horizontalAlign?: HorizontalAlign;
9
+ menuState?: MrlMenuState;
10
+ onClose?: () => void;
11
+ triggerAlignment?: 'left' | 'right' | 'center';
12
+ }
13
+ /**
14
+ * Demo of a menu with a trigger for stories and testing
15
+ *
16
+ * @param {MenuWithSubmenuProps} props - The props for the menu with trigger
17
+ * @returns {Element} The menu with trigger demo
18
+ */
19
+ export declare const MenuWithSubmenu: ({ menuAlign, verticalAlign, horizontalAlign, kind, menuState, onClose, triggerAlignment }: MenuWithSubmenuProps) => JSX.Element;
20
+ export {};
@@ -2,12 +2,13 @@
2
2
  import { MrlMenuState } from '../';
3
3
  import { MenuPosition, VerticalAlign, HorizontalAlign } from '../constants';
4
4
  interface MenuWithTriggerProps {
5
- menuAlign?: MenuPosition | undefined;
6
- kind?: 'default' | 'compact' | undefined;
7
- verticalAlign: VerticalAlign | undefined;
8
- horizontalAlign: HorizontalAlign | undefined;
9
- menuState?: MrlMenuState | undefined;
10
- onClose?: () => void | undefined;
5
+ menuAlign?: MenuPosition;
6
+ kind?: 'default' | 'compact';
7
+ verticalAlign?: VerticalAlign;
8
+ horizontalAlign?: HorizontalAlign;
9
+ menuState?: MrlMenuState;
10
+ onClose?: () => void;
11
+ triggerAlignment?: 'left' | 'right' | 'center';
11
12
  }
12
13
  /**
13
14
  * Demo of a menu with a trigger for stories and testing
@@ -15,5 +16,5 @@ interface MenuWithTriggerProps {
15
16
  * @param {MenuWithTriggerProps} props - The props for the menu with trigger
16
17
  * @returns {Element} The menu with trigger demo
17
18
  */
18
- export declare const MenuWithTrigger: ({ menuAlign, verticalAlign, horizontalAlign, kind, menuState, onClose }: MenuWithTriggerProps) => JSX.Element;
19
+ export declare const MenuWithTrigger: ({ menuAlign, verticalAlign, horizontalAlign, kind, menuState, onClose, triggerAlignment }: MenuWithTriggerProps) => JSX.Element;
19
20
  export {};
@@ -0,0 +1,17 @@
1
+ import { RefObject } from 'react';
2
+ interface SubMenuPosition {
3
+ left: string;
4
+ top: string;
5
+ }
6
+ /**
7
+ * Calculates the position of the sub menu element
8
+ *
9
+ * @param triggerRef - The trigger element ref
10
+ * @param menuRef - The menu element ref
11
+ * @param isSubMenu - Is the menu a sub menu
12
+ * @param isOpen - Is the element visible
13
+ * @param originalMenuRect - The menu element rect
14
+ * @returns The sub menu position
15
+ */
16
+ export declare const useSubMenuElementPosition: (triggerRef: RefObject<HTMLElement> | undefined, menuRef: RefObject<HTMLDivElement>, isSubMenu: boolean, isOpen: boolean, originalMenuRect: DOMRect | null) => SubMenuPosition;
17
+ export {};
@@ -1,3 +1,4 @@
1
1
  export * from './MrlMenu';
2
2
  export * from './MrlMenuItem';
3
+ export * from './MrlMenuItemLink';
3
4
  export * from './MrlMenuGroup';
@@ -1,6 +1,7 @@
1
1
  import React from 'react';
2
2
  export interface PortalProps {
3
3
  children: React.ReactNode;
4
+ id?: string;
4
5
  }
5
6
  export declare const MRL_PORTAL_ID = "mrl-root-portal";
6
7
  /**
@@ -10,4 +11,4 @@ export declare const MRL_PORTAL_ID = "mrl-root-portal";
10
11
  * @param PortalProps Portal only takes children. Contact the platform team if you need to extend this.
11
12
  * @returns MrlPortal component
12
13
  */
13
- export declare const MrlPortal: ({ children }: PortalProps) => React.ReactElement | null;
14
+ export declare const MrlPortal: ({ children, id }: PortalProps) => React.ReactElement | null;
@@ -2,7 +2,7 @@ import { RefObject } from 'react';
2
2
  /**
3
3
  * Hook to detect clicks outside of a given DOM element.
4
4
  *
5
- * @param elementRef - Reference to the DOM element that caused this menu to be shown.
6
- * @param onOutsideClick - Function to call when a click is detected outside the elementRef element
5
+ * @param menuRef - Reference to the DOM element that caused this menu to be shown.
6
+ * @param onOutsideClick - Function to call when a click is detected outside the menuRef element
7
7
  */
8
- export declare const useClickOutside: (elementRef: RefObject<HTMLElement>, onOutsideClick: () => void) => void;
8
+ export declare const useClickOutside: (menuRef: RefObject<HTMLElement>, onOutsideClick: () => void) => void;
@@ -7,8 +7,10 @@ import { Alignment, Position } from './constants';
7
7
  *
8
8
  * @param {RefObject<HTMLElement>} triggerRef - Reference to the DOM element that triggers the menu.
9
9
  * @param {RefObject<HTMLElement>} elementRef - Reference to the DOM element that is the menu.
10
- * @param {boolean} isElementVisible - Whether the trigger element is visible.
11
10
  * @param {Alignment} menuAlign - The alignment configuration of the menu.
11
+ * @param {boolean} isElementVisible - Tells the hook if the element is visible. If false, the hook will not calculate the position.
12
+ * @param {number} menuOffset - The offset of the menu from the trigger element.
13
+ * @param disable - Whether to disable the hook.
12
14
  * @returns {Position} The calculated position of the menu element.
13
15
  */
14
- export declare const useTriggerPosition: (triggerRef: RefObject<HTMLElement> | undefined, elementRef: RefObject<HTMLElement>, isElementVisible: boolean, menuAlign: Alignment) => Position;
16
+ export declare const useTriggerPosition: (triggerRef: RefObject<HTMLElement> | undefined, elementRef: RefObject<HTMLElement>, menuAlign: Alignment, isElementVisible?: boolean, menuOffset?: number, disable?: boolean) => Position;