@aws/mynah-ui 2.0.0-beta.1 → 2.0.0-beta.11.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.
Files changed (56) hide show
  1. package/DEVELOPMENT.md +24 -0
  2. package/README.md +1 -1
  3. package/dist/components/chat-item/chat-item-card.d.ts +3 -10
  4. package/dist/components/chat-item/chat-item-followup.d.ts +2 -1
  5. package/dist/components/chat-item/chat-item-related-content.d.ts +25 -0
  6. package/dist/components/chat-item/chat-item-relevance-vote.d.ts +17 -0
  7. package/dist/components/{suggestion-card/suggestion-card-context-wrapper.d.ts → chat-item/chat-item-tree-view-wrapper.d.ts} +6 -4
  8. package/dist/components/chat-item/chat-item-tree-view.d.ts +22 -0
  9. package/dist/components/chat-item/chat-prompt-input.d.ts +13 -10
  10. package/dist/components/chat-item/chat-wrapper.d.ts +10 -9
  11. package/dist/components/feedback-form/feedback-form-comment.d.ts +2 -2
  12. package/dist/components/feedback-form/feedback-form.d.ts +5 -2
  13. package/dist/components/icon/icon-importer.d.ts +9 -0
  14. package/dist/components/icon.d.ts +6 -3
  15. package/dist/components/navigation-tabs.d.ts +7 -6
  16. package/dist/components/notification/notification.d.ts +0 -4
  17. package/dist/components/overlay/overlay.d.ts +4 -37
  18. package/dist/components/suggestion-card/suggestion-card-body.d.ts +2 -1
  19. package/dist/components/suggestion-card/suggestion-card-header.d.ts +2 -2
  20. package/dist/components/suggestion-card/suggestion-card.d.ts +1 -1
  21. package/dist/components/syntax-highlighter.d.ts +21 -3
  22. package/dist/components/toggle.d.ts +7 -5
  23. package/dist/helper/config.d.ts +6 -5
  24. package/dist/helper/date-time.d.ts +2 -2
  25. package/dist/helper/dom.d.ts +2 -0
  26. package/dist/helper/events.d.ts +0 -15
  27. package/dist/helper/file-tree.d.ts +16 -0
  28. package/dist/helper/store.d.ts +3 -39
  29. package/dist/helper/tabs-store.d.ts +40 -0
  30. package/dist/main.d.ts +32 -70
  31. package/dist/main.js +1 -1
  32. package/dist/main.js.LICENSE.txt +5 -0
  33. package/dist/main.js.map +1 -1
  34. package/dist/static.d.ts +81 -238
  35. package/package.json +12 -8
  36. package/dist/components/context-item.d.ts +0 -16
  37. package/dist/components/feedback-form/feedback-form-stars.d.ts +0 -15
  38. package/dist/components/main-container.d.ts +0 -20
  39. package/dist/components/navigation-tabs-vertical.d.ts +0 -13
  40. package/dist/components/prioritization-menu.d.ts +0 -18
  41. package/dist/components/query-text-short-view.d.ts +0 -10
  42. package/dist/components/search-block/autocomplete-card.d.ts +0 -20
  43. package/dist/components/search-block/autocomplete-content.d.ts +0 -32
  44. package/dist/components/search-block/search-api-help.d.ts +0 -14
  45. package/dist/components/search-block/search-card-header.d.ts +0 -11
  46. package/dist/components/search-block/search-card.d.ts +0 -19
  47. package/dist/components/search-block/search-context.d.ts +0 -30
  48. package/dist/components/search-block/search-history-card.d.ts +0 -16
  49. package/dist/components/search-block/search-history-content.d.ts +0 -19
  50. package/dist/components/search-block/search-input.d.ts +0 -22
  51. package/dist/components/search-block/search-live-toggle.d.ts +0 -15
  52. package/dist/components/suggestion-card/suggestion-card-relevance-vote.d.ts +0 -14
  53. package/dist/helper/find-language.d.ts +0 -17
  54. package/dist/helper/payload-transformer.d.ts +0 -13
  55. package/dist/translations/en.d.ts +0 -13
  56. package/dist/translations/i18n.d.ts +0 -17
package/dist/static.d.ts CHANGED
@@ -2,102 +2,52 @@
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 { ToggleOption } from './components/toggle';
5
+ import { MynahIcons } from './components/icon';
6
+ export interface QuickActionCommandGroup {
7
+ groupName?: string;
8
+ commands: Array<{
9
+ command: string;
10
+ description?: string;
11
+ promptText?: string;
12
+ }>;
13
+ }
6
14
  export interface MynahUIDataModel {
7
- loading?: boolean;
15
+ tabTitle?: string;
8
16
  loadingChat?: boolean;
9
17
  showChatAvatars?: boolean;
10
- liveSearchState?: LiveSearchState;
11
- liveSearchAnimation?: boolean;
12
- query?: string;
13
- chatMessageOnTopOfSearchResults?: string;
14
- code?: string;
15
- codeSelection?: SearchPayloadCodeSelection;
16
- codeQuery?: SearchPayloadCodeQuery;
17
- matchPolicy?: SearchPayloadMatchPolicy;
18
- invisibleContextItems?: string[];
19
- navigationTabs?: ToggleOption[];
20
- sideNavigationTabs?: ToggleOption[];
21
- userAddedContext?: string[];
22
- mode?: MynahMode;
23
- suggestions?: Suggestion[];
18
+ quickActionCommands?: QuickActionCommandGroup[];
19
+ promptInputPlaceholder?: string;
20
+ promptInputDisabledState?: boolean;
24
21
  chatItems?: ChatItem[];
25
- autoCompleteSuggestions?: AutocompleteItem[];
26
- searchHistory?: SearchHistoryItem[];
27
- showingHistoricalSearch?: boolean;
28
- headerInfo?: {
29
- content: string;
30
- type?: NotificationType;
31
- };
22
+ }
23
+ export interface MynahUITabStoreTab {
24
+ isSelected?: boolean;
25
+ store?: MynahUIDataModel;
26
+ }
27
+ export interface MynahUITabStoreModel {
28
+ [tabId: string]: MynahUITabStoreTab;
32
29
  }
33
30
  export declare enum MynahEventNames {
34
31
  RESET_STORE = "resetStore",
35
- CONTEXT_VISIBILITY_CHANGE = "contextVisibilityChange",
36
- AUTOCOMPLETE_SUGGESTION_CLICK = "autoCompleteSuggestionClick",
37
- SEARCH = "search",
38
- INPUT_QUERY_CHANGE = "inputQueryChange",
39
- REQUEST_SEARCH_HISTORY = "requestSearchHistory",
40
- SEARCH_HISTORY_ITEM_CLICK = "searchHistoryItemClick",
41
- LIVE_SEARCH_STATE_CHANGED = "liveSearchStateChanged",
42
32
  FEEDBACK_SET = "feedbackSet",
43
- CODE_DETAILS_CLICK = "codeDetailsClick",
44
- SUGGESTION_VOTE = "suggestionVote",
33
+ CARD_VOTE = "cardVote",
45
34
  SUGGESTION_OPEN = "suggestionOpen",
46
35
  SUGGESTION_LINK_COPY = "suggestionLinkCopy",
47
36
  SUGGESTION_ENGAGEMENT = "suggestionEngagement",
48
- SUGGESTION_COPY_TO_CLIPBOARD = "suggestionCopyToClipboard",
37
+ COPY_CODE_TO_CLIPBOARD = "copyCodeToClipboard",
38
+ INSERT_CODE_TO_CURSOR_POSITION = "insertCodeToCursorPosition",
49
39
  CHAT_PROMPT = "chatPrompt",
50
40
  FOLLOW_UP_CLICKED = "followUpClicked",
51
- SUGGESTION_ATTACHED_TO_CHAT = "suggestionAttachedToChat",
52
41
  UPDATE_LAST_CHAT_ANSWER_STREAM = "updateLastChatAnswerStream",
53
- CLEAR_CHAT = "clearChat",
54
42
  SHOW_MORE_WEB_RESULTS_CLICK = "showMoreWebResultsClick",
55
- SHOW_FEEDBACK_FORM_CLICK = "showFeedbackFormClick"
43
+ SHOW_FEEDBACK_FORM = "showFeedbackForm",
44
+ OPEN_DIFF = "openDiff"
56
45
  }
57
- export declare const MynahPortalNames: {
58
- WRAPPER: string;
59
- SIDE_NAV: string;
60
- OVERLAY: string;
61
- FEEDBACK_FORM: string;
62
- };
63
- export interface SearchPayloadMatchPolicy {
64
- must: string[];
65
- should: string[];
66
- mustNot: string[];
67
- }
68
- export interface SearchPayloadCodeSelection {
69
- selectedCode: string;
70
- file?: {
71
- range: {
72
- start: {
73
- row: string;
74
- column: string;
75
- };
76
- end: {
77
- row: string;
78
- column: string;
79
- };
80
- };
81
- name: string;
82
- };
83
- }
84
- export interface FullyQualifiedName {
85
- source: string[];
86
- symbol: string[];
87
- }
88
- export interface SearchPayloadCodeQuery {
89
- simpleNames: string[];
90
- fullyQualifiedNames: {
91
- used: FullyQualifiedName[];
92
- };
93
- }
94
- export interface SearchPayload {
95
- query: string;
96
- matchPolicy: SearchPayloadMatchPolicy;
97
- codeSelection: SearchPayloadCodeSelection;
98
- codeQuery?: SearchPayloadCodeQuery;
99
- code?: string;
100
- selectedTab?: string;
46
+ export declare enum MynahPortalNames {
47
+ WRAPPER = "wrapper",
48
+ SIDE_NAV = "sideNav",
49
+ OVERLAY = "overlay",
50
+ FEEDBACK_FORM = "feedbackForm"
101
51
  }
102
52
  export interface SuggestionMetaData {
103
53
  stars?: number;
@@ -108,21 +58,13 @@ export interface SuggestionMetaData {
108
58
  score?: number;
109
59
  lastActivityDate?: number;
110
60
  }
111
- export declare type SuggestionMetaDataUnion = Record<string, SuggestionMetaData>;
112
- export interface CanonicalExample {
113
- canonicalExample: {
114
- body: string;
115
- url: string;
116
- };
117
- }
118
61
  export interface Suggestion {
119
- id: string;
120
62
  title: string;
121
- url: string;
122
- body: string;
123
- context: string[];
63
+ id?: string;
64
+ url?: string;
65
+ body?: string;
124
66
  type?: string;
125
- metadata?: SuggestionMetaDataUnion | CanonicalExample;
67
+ metadata?: Record<string, SuggestionMetaData>;
126
68
  }
127
69
  export declare enum ChatItemType {
128
70
  PROMPT = "prompt",
@@ -130,35 +72,32 @@ export declare enum ChatItemType {
130
72
  AI_PROMPT = "ai-prompt",
131
73
  ANSWER = "answer",
132
74
  ANSWER_STREAM = "answer-stream",
133
- ANSWER_PART = "answer-part"
75
+ ANSWER_PART = "answer-part",
76
+ CODE_RESULT = "code-result"
134
77
  }
135
78
  export interface ChatItem {
136
- body?: string;
79
+ body?: string | string[];
137
80
  type: ChatItemType;
81
+ messageId?: string;
82
+ canBeVoted?: boolean;
138
83
  followUp?: {
139
84
  text?: string;
140
85
  options?: ChatItemFollowUp[];
141
86
  };
142
87
  relatedContent?: {
143
- title: string | boolean;
88
+ title?: string;
144
89
  content: Suggestion[];
145
90
  };
146
- suggestions?: {
147
- title: string | boolean;
148
- suggestions: Suggestion[];
149
- };
150
91
  }
151
92
  export interface ChatPrompt {
152
- prompt: string;
93
+ prompt?: string;
153
94
  attachment?: Suggestion;
154
95
  }
155
96
  export interface ChatItemFollowUp extends ChatPrompt {
156
- type: string;
97
+ type?: string;
157
98
  pillText: string;
158
- }
159
- export declare enum MynahMode {
160
- CHAT = "chat",
161
- SEARCH = "search"
99
+ status?: 'info' | 'success' | 'warning' | 'error';
100
+ icon?: MynahIcons;
162
101
  }
163
102
  export declare enum KeyMap {
164
103
  ESCAPE = "Escape",
@@ -178,73 +117,18 @@ export declare enum KeyMap {
178
117
  TAB = "Tab",
179
118
  SHIFT = "Shift",
180
119
  CONTROL = "Control",
181
- ALT = "Alt"
182
- }
183
- export declare enum LiveSearchState {
184
- PAUSE = "pauseLiveSearch",
185
- RESUME = "resumeLiveSearch",
186
- STOP = "stopLiveSearch"
187
- }
188
- export declare const SupportedCodingLanguages: string[];
189
- declare type ElementType<T extends readonly unknown[]> = T extends ReadonlyArray<infer ElementType> ? ElementType : never;
190
- export declare type SupportedCodingLanguagesType = ElementType<typeof SupportedCodingLanguages>;
191
- export declare const SupportedCodingLanguagesExtensionToTypeMap: {
192
- ts: string;
193
- js: string;
194
- py: string;
195
- java: string;
196
- json: string;
197
- };
198
- export declare type OnCopiedToClipboardFunction = (type?: 'selection' | 'block', text?: string) => void;
199
- export interface SearchHistoryFilters {
200
- /**
201
- * Flag to define are we looking in global search-history or only in worplace
202
- *
203
- * @default - Search will be performed on workplace store
204
- */
205
- isGlobal: boolean;
206
- /**
207
- * Flag to define are we looking only for queries which were manually typed by the user,
208
- * or only for quries whic were generated by plugin itself, or it's not important
209
- *
210
- * @default - We won't filter records bases on type of input
211
- */
212
- isManualSearch?: boolean;
213
- /**
214
- * Array of language filters. If user chose some, the results would be filtered
215
- *
216
- * @default - We won't filter records bases on languages
217
- */
218
- languages: string[];
219
- /**
220
- * User text from search bar in search-history part of UI
221
- *
222
- * @default - We won't filter records bases on user input in search-history search bar
223
- */
224
- text?: string;
225
- /**
226
- * Allow us to skip n-first results
227
- *
228
- * @default - The starting offset will be 0
229
- */
230
- resultOffset: number;
231
- /**
232
- * Limit of how many results we want to get from store
233
- *
234
- * @default - The records count won't be limited
235
- */
236
- resultLimit?: number;
120
+ ALT = "Alt",
121
+ SLASH = "/"
237
122
  }
238
- export interface CodeQuery {
239
- simpleNames: string[];
240
- fullyQualifiedNames: {
241
- used: FullyQualifiedName[];
123
+ export interface ReferenceTrackerInformation {
124
+ range: {
125
+ start: number;
126
+ end: number;
242
127
  };
128
+ tooltipMarkdown: string;
243
129
  }
244
- export declare enum ContextChangeType {
245
- 'ADD' = "add",
246
- 'REMOVE' = "remove"
247
- }
130
+ export declare type OnCopiedToClipboardFunction = (type?: 'selection' | 'block', text?: string, referenceTrackerInformation?: ReferenceTrackerInformation[]) => void;
131
+ export declare type OnInsertToCursorPositionFunction = (type?: 'selection' | 'block', text?: string, referenceTrackerInformation?: ReferenceTrackerInformation[]) => void;
248
132
  export declare enum SuggestionEventName {
249
133
  OPEN = "openSuggestion",
250
134
  COPY = "copy"
@@ -253,100 +137,59 @@ export declare enum RelevancyVoteType {
253
137
  UP = "upvote",
254
138
  DOWN = "downvote"
255
139
  }
256
- /**
257
- * 'interaction' will be set if there was a potential text selection or a click input was triggered by the user.
258
- * If this is a selection selectionDistanceTraveled object will also be filled
259
- * 'timespend' will be set basically if there is no interaction except mouse movements in a time spent longer than the ENGAGEMENT_DURATION_LIMIT
260
- * Don't forget that in 'timespend' case, user should leave the suggestion card at some point to count it as an interaction.
261
- * (They need to go back to the code or move to another card instead)
262
- */
263
140
  export declare enum EngagementType {
264
141
  INTERACTION = "interaction",
265
142
  TIME = "timespend"
266
143
  }
267
144
  export interface SuggestionEngagement {
268
- /**
269
- * Suggestion information
270
- */
271
145
  suggestion: Suggestion;
272
- /**
273
- * Engagement type
274
- */
275
146
  engagementType: EngagementType;
276
- /**
277
- * Total duration in ms till the engagement triggered.
278
- */
279
147
  engagementDurationTillTrigger: number;
280
- /**
281
- * This is a little bit more than what you might expect on a normal scroll position of the suggestion card.
282
- * This attribute gives the value for how much the users traveled their mouses and additionally how much they scrolled to focus on that suggestion
283
- */
284
148
  scrollDistanceToEngage: number;
285
- /**
286
- * Total mouse movement in x and y directions till the engagament triggered.
287
- * To avoid confusion: this is not the distance between start and end points, this is the total traveled distance.
288
- */
289
149
  totalMouseDistanceTraveled: {
290
150
  x: number;
291
151
  y: number;
292
152
  };
293
- /**
294
- * If the engagementType is "interaction" and this object has a value, you can assume it as a text selection.
295
- * If the engagementType is "interaction" but this object is not defined, you can assume it as a click
296
- */
297
153
  selectionDistanceTraveled?: {
298
154
  x: number;
299
155
  y: number;
300
156
  selectedText?: string;
301
157
  };
302
158
  }
303
- export interface SearchHistoryItem {
304
- query: {
305
- input: string;
306
- queryContext: SearchPayloadMatchPolicy;
307
- queryId?: string;
308
- trigger: string;
309
- codeQuery: CodeQuery;
310
- codeSelection: SearchPayloadCodeSelection;
311
- code?: string;
312
- selectedTab?: string;
313
- };
314
- recordDate?: number;
315
- suggestions: Suggestion[];
316
- }
317
- export declare enum ContextTypes {
318
- MUST = "must",
319
- SHOULD = "should",
320
- MUST_NOT = "mustNot"
321
- }
322
- export declare enum ContextSource {
323
- AUTO = "auto",
324
- USER = "user",
325
- SUGGESTION = "suggestion"
326
- }
327
- export declare enum ContextTypeClassNames {
328
- should = "mynah-should-contain",
329
- must = "mynah-must-contain",
330
- mustNot = "mynah-must-not-contain"
331
- }
332
- export interface ContextType {
333
- context: string;
334
- type?: ContextTypes;
335
- source: ContextSource;
336
- }
337
- export declare type FeedbackStars = 1 | 2 | 3 | 4 | 5;
338
159
  export interface FeedbackPayload {
339
- stars?: FeedbackStars;
160
+ messageId: string;
161
+ tabId: string;
162
+ selectedOption: string;
340
163
  comment?: string;
341
164
  }
342
- export interface AutocompleteItem {
343
- suggestion: string;
344
- highlight: string;
345
- }
346
165
  export declare enum NotificationType {
347
166
  INFO = "info",
348
167
  SUCCESS = "ok-circled",
349
168
  WARNING = "warning",
350
169
  ERROR = "error"
351
170
  }
352
- export {};
171
+ export interface ConfigModel {
172
+ texts: {
173
+ awsqTitle: string;
174
+ feedbackFormTitle: string;
175
+ feedbackFormOptionsLabel: string;
176
+ feedbackFormCommentLabel: string;
177
+ feedbackThanks: string;
178
+ feedbackReportButtonLabel: string;
179
+ codeSuggestions: string;
180
+ clickFileToViewDiff: string;
181
+ files: string;
182
+ insertAtCursorLabel: string;
183
+ copy: string;
184
+ showMore: string;
185
+ save: string;
186
+ cancel: string;
187
+ submit: string;
188
+ stopGenerating: string;
189
+ copyToClipboard: string;
190
+ };
191
+ feedbackOptions: Array<{
192
+ label: string;
193
+ value: string;
194
+ }>;
195
+ }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@aws/mynah-ui",
3
3
  "displayName": "AWS Mynah UI",
4
- "version": "2.0.0-beta.1",
4
+ "version": "2.0.0-beta.11.0",
5
5
  "description": "AWS Tookit VSCode and Intellij IDE Extension Mynah UI",
6
6
  "publisher": "Amazon Web Services",
7
7
  "license": "Apache License 2.0",
@@ -25,26 +25,30 @@
25
25
  "prismjs": "1.29.0"
26
26
  },
27
27
  "devDependencies": {
28
- "@typescript-eslint/eslint-plugin": "5.34.0",
29
- "@types/eslint": "7.2.13",
28
+ "@types/eslint": "^8.44.3",
30
29
  "@types/eslint-scope": "3.7.0",
31
30
  "@types/estree": "0.0.49",
32
31
  "@types/glob": "7.1.3",
33
32
  "@types/json-schema": "7.0.7",
34
33
  "@types/node": "17.0.29",
35
34
  "@types/prismjs": "1.26.0",
35
+ "@typescript-eslint/eslint-plugin": "^5.34.0",
36
+ "@typescript-eslint/parser": "^5.62.0",
36
37
  "css-loader": "6.6.0",
37
- "eslint": "8.22.0",
38
- "eslint-config-prettier": "^8.5.0",
38
+ "eslint": "^8.22.0",
39
+ "eslint-config-prettier": "^8.10.0",
39
40
  "eslint-config-standard-with-typescript": "22.0.0",
40
41
  "eslint-plugin-header": "^3.1.1",
41
42
  "eslint-plugin-import": "2.26.0",
42
43
  "eslint-plugin-n": "15.2.5",
43
44
  "eslint-plugin-no-null": "^1.0.2",
45
+ "eslint-plugin-prettier": "^5.0.0",
44
46
  "eslint-plugin-promise": "6.0.0",
47
+ "prettier": "^3.0.3",
45
48
  "sass": "1.49.8",
46
49
  "sass-loader": "12.6.0",
47
50
  "style-loader": "3.3.1",
51
+ "svg-url-loader": "^8.0.0",
48
52
  "ts-loader": "9.2.6",
49
53
  "ts-node": "10.4.0",
50
54
  "typescript": "4.5.2",
@@ -52,11 +56,11 @@
52
56
  "webpack-cli": "4.7.2"
53
57
  },
54
58
  "prettier": {
55
- "printWidth": 120,
59
+ "printWidth": 160,
56
60
  "trailingComma": "es5",
57
- "tabWidth": 4,
61
+ "tabWidth": 2,
58
62
  "singleQuote": true,
59
- "semi": false,
63
+ "semi": true,
60
64
  "bracketSpacing": true,
61
65
  "arrowParens": "avoid",
62
66
  "endOfLine": "lf"
@@ -1,16 +0,0 @@
1
- /*!
2
- * Copyright 2022 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3
- * SPDX-License-Identifier: Apache-2.0
4
- */
5
- import { ContextType } from '../static';
6
- import { ExtendedHTMLElement } from '../helper/dom';
7
- export interface ContextPillProps {
8
- context: ContextType;
9
- showRemoveButton?: boolean;
10
- }
11
- export declare class ContextPill {
12
- private readonly props;
13
- render: ExtendedHTMLElement;
14
- constructor(props: ContextPillProps);
15
- private readonly handleMenuOpen;
16
- }
@@ -1,15 +0,0 @@
1
- /*!
2
- * Copyright 2022 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3
- * SPDX-License-Identifier: Apache-2.0
4
- */
5
- import { ExtendedHTMLElement } from '../../helper/dom';
6
- import { FeedbackStars } from '../../static';
7
- export interface FeedbackFormStarsProps {
8
- onChange?: (star: FeedbackStars) => void;
9
- initStar?: FeedbackStars;
10
- }
11
- export declare class FeedbackFormStars {
12
- render: ExtendedHTMLElement;
13
- constructor(props: FeedbackFormStarsProps);
14
- setStar: (star: FeedbackStars) => void;
15
- }
@@ -1,20 +0,0 @@
1
- /*!
2
- * Copyright 2022 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3
- * SPDX-License-Identifier: Apache-2.0
4
- */
5
- import { ExtendedHTMLElement } from '../helper/dom';
6
- import { Suggestion } from '../static';
7
- export interface MainContainerProps {
8
- onNavigationTabChange?: (selectedTab: string) => void;
9
- onCloseButtonClick?: () => void;
10
- }
11
- export declare class MainContainer {
12
- private readonly navTabs;
13
- private readonly cardsWrapper;
14
- private readonly skeletonWrapper;
15
- private readonly mainContainer;
16
- render: ExtendedHTMLElement;
17
- constructor(props: MainContainerProps);
18
- clearCards: () => void;
19
- updateCards: (suggestions: Suggestion[]) => void;
20
- }
@@ -1,13 +0,0 @@
1
- /*!
2
- * Copyright 2022 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3
- * SPDX-License-Identifier: Apache-2.0
4
- */
5
- import { ExtendedHTMLElement } from '../helper/dom';
6
- import { NavivationTabsProps } from './navigation-tabs';
7
- export declare class NavivationTabsVertical {
8
- render: ExtendedHTMLElement;
9
- private readonly props;
10
- constructor(props: NavivationTabsProps);
11
- private readonly setLoading;
12
- private readonly getTabsRender;
13
- }
@@ -1,18 +0,0 @@
1
- /*!
2
- * Copyright 2022 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3
- * SPDX-License-Identifier: Apache-2.0
4
- */
5
- import { ContextType } from '../static';
6
- import { ExtendedHTMLElement } from '../helper/dom';
7
- export interface PrioritizationMenuButtonsProps {
8
- context: ContextType;
9
- referenceElement: Element | ExtendedHTMLElement;
10
- onMenuClose: () => void;
11
- }
12
- export declare class PrioritizationMenuButtons {
13
- private menuOverlay;
14
- private readonly props;
15
- constructor(props: PrioritizationMenuButtonsProps);
16
- createOverlay(): void;
17
- private readonly handlePrioritizationButtonClick;
18
- }
@@ -1,10 +0,0 @@
1
- /*!
2
- * Copyright 2022 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3
- * SPDX-License-Identifier: Apache-2.0
4
- */
5
- import { ExtendedHTMLElement } from '../helper/dom';
6
- export declare class QueryTextShortView {
7
- render: ExtendedHTMLElement;
8
- private readonly textBlock;
9
- constructor();
10
- }
@@ -1,20 +0,0 @@
1
- /*!
2
- * Copyright 2022 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3
- * SPDX-License-Identifier: Apache-2.0
4
- */
5
- import { AutocompleteItem } from '../../static';
6
- import { ExtendedHTMLElement } from '../../helper/dom';
7
- export interface AutocompleteCardContentProps {
8
- searchQuery: string;
9
- content: AutocompleteItem;
10
- onAutocompleteClick: (autocompleteQuery: AutocompleteItem, index: number) => void;
11
- index: number;
12
- isHovered: boolean | false;
13
- }
14
- export declare class AutocompleteCardContent {
15
- render: ExtendedHTMLElement;
16
- openSearch: any;
17
- searchQuery: string;
18
- constructor(props: AutocompleteCardContentProps);
19
- private formatSuggestion;
20
- }
@@ -1,32 +0,0 @@
1
- /*!
2
- * Copyright 2022 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3
- * SPDX-License-Identifier: Apache-2.0
4
- */
5
- import { AutocompleteItem } from '../../static';
6
- import { ExtendedHTMLElement } from '../../helper/dom';
7
- export interface AutocompleteContentProps {
8
- searchQuery: string;
9
- referenceElement: Element | ExtendedHTMLElement;
10
- autocompleteSuggestions: AutocompleteItem[];
11
- onClose?: () => void;
12
- }
13
- export declare class AutocompleteContent {
14
- private readonly autocompleteItemsOverlay;
15
- suggestions: AutocompleteItem[];
16
- private searchQuery;
17
- private currHover;
18
- private readonly props;
19
- private isUsed;
20
- render: ExtendedHTMLElement;
21
- constructor(props: AutocompleteContentProps);
22
- autocompleteCards: (autocompleteSuggestions: AutocompleteItem[], hovered: number) => ExtendedHTMLElement[];
23
- private readonly handleAutocompleteClick;
24
- updateSuggestions: (autocompleteSuggestions: AutocompleteItem[], hoverQuery: number) => void;
25
- updateQuery: (searchQuery: string) => void;
26
- hover: (isUp: boolean) => string;
27
- setIsUsed: (val: boolean) => void;
28
- getIsUsed: () => boolean;
29
- getCurrentSelected: () => number;
30
- getSuggestionsCount: () => number;
31
- close: () => void;
32
- }
@@ -1,14 +0,0 @@
1
- /*!
2
- * Copyright 2022 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3
- * SPDX-License-Identifier: Apache-2.0
4
- */
5
- import { ExtendedHTMLElement } from '../../helper/dom';
6
- export declare class SearchApiHelp {
7
- render: ExtendedHTMLElement;
8
- private isCollapsed;
9
- constructor();
10
- private readonly hide;
11
- private readonly show;
12
- private readonly updateContent;
13
- private readonly onCodeDetailsClicked;
14
- }
@@ -1,11 +0,0 @@
1
- /*!
2
- * Copyright 2022 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3
- * SPDX-License-Identifier: Apache-2.0
4
- */
5
- import { ExtendedHTMLElement } from '../../helper/dom';
6
- export declare class SearchCardHeader {
7
- private readonly infoBar;
8
- render: ExtendedHTMLElement;
9
- constructor();
10
- private readonly getHeaderInfoContent;
11
- }
@@ -1,19 +0,0 @@
1
- /*!
2
- * Copyright 2022 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3
- * SPDX-License-Identifier: Apache-2.0
4
- */
5
- import { ExtendedHTMLElement } from '../../helper/dom';
6
- export declare class SearchCard {
7
- private unfoldedByContextInsertion;
8
- private unfoldedByButton;
9
- private readonly searchInput;
10
- private readonly searchAPIHelp;
11
- private readonly liveSearchToggle;
12
- private readonly foldUnfoldButton;
13
- private readonly contextManagement;
14
- private readonly searchCardHeader;
15
- render: ExtendedHTMLElement;
16
- constructor();
17
- addFocusOnInput: () => void;
18
- setFolded: (folded: boolean) => void;
19
- }