@aws/mynah-ui 4.26.0 → 4.27.0-beta.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.
@@ -4,19 +4,19 @@
4
4
  */
5
5
  import { FeedbackPayload } from '../../static';
6
6
  import { ExtendedHTMLElement } from '../../helper/dom';
7
- import '../../styles/components/_feedback-form.scss';
8
7
  export interface FeedbackFormProps {
9
8
  initPayload?: FeedbackPayload;
10
9
  }
11
10
  export declare class FeedbackForm {
12
- private feedbackFormWrapper;
13
11
  private readonly feedbackOptionsWrapper;
14
12
  private readonly feedbackComment;
15
13
  private readonly feedbackSubmitButton;
14
+ readonly defaultFeedbackFormItems: ExtendedHTMLElement[];
16
15
  private feedbackPayload;
17
- readonly feedbackFormContainer: ExtendedHTMLElement;
16
+ private chatFormItems;
17
+ private chatButtons;
18
18
  constructor(props?: FeedbackFormProps);
19
19
  private readonly onFeedbackSet;
20
20
  close: () => void;
21
- show: () => void;
21
+ private readonly getFormItems;
22
22
  }
@@ -0,0 +1,20 @@
1
+ /*!
2
+ * Copyright 2025 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3
+ * SPDX-License-Identifier: Apache-2.0
4
+ */
5
+ import { DomBuilderObject, ExtendedHTMLElement } from '../main';
6
+ import '../styles/components/_sheet.scss';
7
+ export interface SheetProps {
8
+ tabId: string;
9
+ title?: string;
10
+ children?: Array<ExtendedHTMLElement | HTMLElement | string | DomBuilderObject>;
11
+ fullScreen?: boolean;
12
+ description?: string;
13
+ }
14
+ export declare class Sheet {
15
+ sheetContainer: ExtendedHTMLElement;
16
+ sheetWrapper: ExtendedHTMLElement;
17
+ constructor();
18
+ close: () => void;
19
+ show: () => void;
20
+ }
@@ -105,18 +105,15 @@ declare const _default: {
105
105
  };
106
106
  };
107
107
  feedbackForm: {
108
- wrapper: string;
109
- title: string;
110
- description: string;
111
108
  optionsSelectWrapper: string;
112
109
  optionsSelect: string;
113
110
  comment: string;
114
- closeButton: string;
115
111
  cancelButton: string;
116
112
  submitButton: string;
117
113
  };
118
- customFeedbackForm: {
114
+ sheet: {
119
115
  wrapper: string;
116
+ header: string;
120
117
  title: string;
121
118
  description: string;
122
119
  closeButton: string;
package/dist/main.d.ts CHANGED
@@ -2,7 +2,7 @@
2
2
  * Copyright 2022 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3
3
  * SPDX-License-Identifier: Apache-2.0
4
4
  */
5
- import { RelevancyVoteType, FeedbackPayload, MynahUIDataModel, NotificationType, ChatItem, ChatItemAction, ChatPrompt, MynahUITabStoreModel, MynahUITabStoreTab, ConfigModel, ReferenceTrackerInformation, CodeSelectionType, Engagement, ChatItemFormItem, ChatItemButton, CardRenderDetails, PromptAttachmentType, QuickActionCommand } from './static';
5
+ import { RelevancyVoteType, FeedbackPayload, MynahUIDataModel, NotificationType, ChatItem, ChatItemAction, ChatPrompt, MynahUITabStoreModel, MynahUITabStoreTab, ConfigModel, ReferenceTrackerInformation, CodeSelectionType, Engagement, ChatItemFormItem, ChatItemButton, CardRenderDetails, PromptAttachmentType, QuickActionCommand, DetailedList } from './static';
6
6
  import './styles/styles.scss';
7
7
  export { generateUID } from './helper/guid';
8
8
  export { ChatItemBodyRenderer, } from './helper/dom';
@@ -87,6 +87,9 @@ export interface MynahUIProps {
87
87
  onQuickCommandGroupActionClick?: (tabId: string, action: {
88
88
  id: string;
89
89
  }, eventId?: string) => void;
90
+ onDetailActionClick?: () => void;
91
+ onDetailItemClick?: () => void;
92
+ onDetailFilterChange?: () => void;
90
93
  }
91
94
  export declare class MynahUI {
92
95
  private readonly render;
@@ -97,6 +100,7 @@ export declare class MynahUI {
97
100
  private readonly tabsWrapper;
98
101
  private readonly tabContentsWrapper;
99
102
  private readonly feedbackForm?;
103
+ private readonly sheet?;
100
104
  private readonly chatWrappers;
101
105
  constructor(props: MynahUIProps);
102
106
  private readonly getUserEventId;
@@ -193,9 +197,15 @@ export declare class MynahUI {
193
197
  onNotificationHide?: ((eventId: string) => void) | undefined;
194
198
  }) => void;
195
199
  /**
196
- * Simply creates and shows a notification
197
- * @param props NotificationProps
200
+ * Simply creates and shows a custom form
198
201
  */
199
202
  showCustomForm: (tabId: string, formItems?: ChatItemFormItem[], buttons?: ChatItemButton[], title?: string, description?: string) => void;
203
+ openSheet: (data: {
204
+ tabId: string;
205
+ title?: string;
206
+ children?: Array<ChatItem | DetailedList>;
207
+ fullScreen?: boolean;
208
+ description?: string;
209
+ }) => void;
200
210
  destroy: () => void;
201
211
  }