@aws/mynah-ui 4.23.0 → 4.23.1

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.
@@ -11,6 +11,7 @@ export interface ChatItemButtonsWrapperProps {
11
11
  buttons: ChatItemButton[] | null;
12
12
  formItems?: ChatItemFormItemsWrapper | null;
13
13
  onActionClick?: (action: ChatItemButton, e?: Event) => void;
14
+ onAllButtonsDisabled?: () => void;
14
15
  }
15
16
  export declare class ChatItemButtonsWrapper {
16
17
  private readonly props;
@@ -15,9 +15,11 @@ export declare class ChatItemFormItemsWrapper {
15
15
  private readonly validationItems;
16
16
  private isValid;
17
17
  onValidationChange?: (isValid: boolean) => void;
18
+ onAllFormItemsDisabled?: () => void;
18
19
  render: ExtendedHTMLElement;
19
20
  constructor(props: ChatItemFormItemsWrapperProps);
20
21
  private readonly getValidationHandler;
22
+ private readonly handleTextualItemKeyPressEvent;
21
23
  private readonly isItemValid;
22
24
  isFormValid: () => boolean;
23
25
  disableAll: () => void;
@@ -12,6 +12,7 @@ export interface CustomFormWrapperProps {
12
12
  title?: string;
13
13
  description?: string;
14
14
  onFormAction?: (actionName: string, formData: Record<string, string>) => void;
15
+ onFormDisabled?: () => void;
15
16
  onCloseButtonClick?: (e: Event) => void;
16
17
  }
17
18
  export declare class CustomFormWrapper {
@@ -9,6 +9,7 @@ export interface TextAreaProps {
9
9
  classNames?: string[];
10
10
  attributes?: Record<string, string>;
11
11
  label?: HTMLElement | ExtendedHTMLElement | string;
12
+ autoFocus?: boolean;
12
13
  description?: ExtendedHTMLElement;
13
14
  mandatory?: boolean;
14
15
  fireModifierAndEnterKeyPress?: () => void;
@@ -19,6 +20,7 @@ export interface TextAreaProps {
19
20
  };
20
21
  value?: string;
21
22
  onChange?: (value: string) => void;
23
+ onKeyPress?: (event: KeyboardEvent) => void;
22
24
  testId?: string;
23
25
  }
24
26
  export declare abstract class TextAreaAbstract {
@@ -9,6 +9,7 @@ export interface TextInputProps {
9
9
  classNames?: string[];
10
10
  attributes?: Record<string, string>;
11
11
  label?: HTMLElement | ExtendedHTMLElement | string;
12
+ autoFocus?: boolean;
12
13
  description?: ExtendedHTMLElement;
13
14
  mandatory?: boolean;
14
15
  fireModifierAndEnterKeyPress?: () => void;
@@ -20,6 +21,7 @@ export interface TextInputProps {
20
21
  };
21
22
  value?: string;
22
23
  onChange?: (value: string) => void;
24
+ onKeyPress?: (event: KeyboardEvent) => void;
23
25
  testId?: string;
24
26
  }
25
27
  export declare abstract class TextInputAbstract {
package/dist/main.d.ts CHANGED
@@ -70,6 +70,7 @@ export interface MynahUIProps {
70
70
  onFormLinkClick?: (link: string, mouseEvent?: MouseEvent, eventId?: string) => void;
71
71
  onSendFeedback?: (tabId: string, feedbackPayload: FeedbackPayload, eventId?: string) => void;
72
72
  onFormModifierEnterPress?: (formData: Record<string, string>, tabId: string, eventId?: string) => void;
73
+ onFormTextualItemKeyPress?: (event: KeyboardEvent, formData: Record<string, string>, itemId: string, tabId: string, eventId?: string) => boolean;
73
74
  onCustomFormAction?: (tabId: string, action: {
74
75
  id: string;
75
76
  text?: string;