@elliemae/ds-chat 2.0.1 → 2.1.0-rc.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.
@@ -28,9 +28,9 @@ var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
28
28
 
29
29
  var _PaperAirplane, _Grid;
30
30
 
31
- function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
31
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
32
32
 
33
- function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty__default["default"](target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
33
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty__default["default"](target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
34
34
 
35
35
  const ChatComposer = props => {
36
36
  var _input$current;
@@ -146,7 +146,7 @@ const ChatComposer = props => {
146
146
  }, void 0, inputMaxLength && hasError ? /*#__PURE__*/jsxRuntime.jsxs(jsxRuntime.Fragment, {
147
147
  children: [/*#__PURE__*/_jsx__default["default"](styled.StyledCounterErrorA11y, {
148
148
  role: "alert"
149
- }, void 0, maxLengthMessage || "You have exceeded the character limit by ".concat(inputLength - inputMaxLength)), maxLengthMessage || "Please limit to less than ".concat(inputMaxLength, " characters. ")]
149
+ }, void 0, maxLengthMessage || "You have entered ".concat(inputLength, " characters and have exceeded the limit by ").concat(inputLength - inputMaxLength, ". Please limit to less than ").concat(inputMaxLength, " characters. ")), maxLengthMessage || "Please limit to less than ".concat(inputMaxLength, " characters. ")]
150
150
  }) : '', inputMaxLength ? " ".concat(inputLength, " / ").concat(inputMaxLength) : ''), _Grid || (_Grid = /*#__PURE__*/_jsx__default["default"](dsGrid.Grid, {}))));
151
151
  };
152
152
 
@@ -29,11 +29,11 @@ var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
29
29
  var DSIndeterminateProgressIndicator__default = /*#__PURE__*/_interopDefaultLegacy(DSIndeterminateProgressIndicator);
30
30
  var DSBanner__default = /*#__PURE__*/_interopDefaultLegacy(DSBanner);
31
31
 
32
- var _DSIndeterminateProgr, _StyledIndicatorConta;
32
+ var _DSIndeterminateProgr;
33
33
 
34
- function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
34
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
35
35
 
36
- function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty__default["default"](target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
36
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty__default["default"](target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
37
37
 
38
38
  const ChatContainer = props$1 => {
39
39
  var _containerRef$current;
@@ -86,17 +86,21 @@ const ChatContainer = props$1 => {
86
86
  const ref = actionRef || listRef;
87
87
 
88
88
  if (e.shiftKey && e.key === 'Tab') {
89
- e.preventDefault();
89
+ if (messagesListProps.messages.length > 0) {
90
+ e.preventDefault();
90
91
 
91
- if (['top', 'bottom'].includes(bannerPosition)) {
92
- bannerRef.current.focusOnWrapper();
93
- } else {
94
- const last = ref.current.getMessagesInView().pop();
95
- ref.current.focusToIndexWithoutScroll(last);
92
+ if (['top', 'bottom'].includes(bannerPosition)) {
93
+ bannerRef.current.focusOnWrapper();
94
+ } else {
95
+ var _ref$current;
96
+
97
+ const last = ref.current.getMessagesInView().pop();
98
+ (_ref$current = ref.current) === null || _ref$current === void 0 ? void 0 : _ref$current.focusToIndexWithoutScroll(last);
99
+ }
96
100
  }
97
101
  }
98
102
  }
99
- }, [actionRef, onComposerKeyDown, bannerPosition]); // Map actions
103
+ }, [actionRef, onComposerKeyDown, bannerPosition, messagesListProps.messages.length]); // Map actions
100
104
 
101
105
  React__default["default"].useEffect(() => {
102
106
  if (actionRef && actionRef.current) {
@@ -146,15 +150,15 @@ const ChatContainer = props$1 => {
146
150
  isOpen: true,
147
151
  type: bannerProps.type || DSBanner.BANNER_TYPES.INFO,
148
152
  actionRef: bannerRef
149
- })), sendingMessages && sendingMessages.length > 0 ? _StyledIndicatorConta || (_StyledIndicatorConta = /*#__PURE__*/_jsx__default["default"](styled.StyledIndicatorContainer, {
153
+ })), sendingMessages && sendingMessages.length > 0 ? /*#__PURE__*/_jsx__default["default"](styled.StyledIndicatorContainer, {
150
154
  isLoading: "bottom",
151
155
  linear: true,
152
156
  "data-testid": "ds-chat-loading-indicator"
153
157
  }, void 0, /*#__PURE__*/_jsx__default["default"](DSIndeterminateProgressIndicator__default["default"], {
154
158
  processing: true,
155
- title: "Loading",
159
+ title: sendingText,
156
160
  lineOnly: true
157
- }))) : null), /*#__PURE__*/jsxRuntime.jsx(ChatContainerComposer.ChatComposer, _objectSpread(_objectSpread({}, composerProps), {}, {
161
+ })) : null), /*#__PURE__*/jsxRuntime.jsx(ChatContainerComposer.ChatComposer, _objectSpread(_objectSpread({}, composerProps), {}, {
158
162
  onKeyDown: handleTabs,
159
163
  onResize: onResize,
160
164
  maxHeight: (((_containerRef$current = containerRef.current) === null || _containerRef$current === void 0 ? void 0 : _containerRef$current.clientHeight) || 0) / 2,
@@ -35,9 +35,9 @@ var _defineProperty__default = /*#__PURE__*/_interopDefaultLegacy(_definePropert
35
35
  var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
36
36
  var DSButton__default = /*#__PURE__*/_interopDefaultLegacy(DSButton);
37
37
 
38
- function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
38
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
39
39
 
40
- function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty__default["default"](target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
40
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty__default["default"](target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
41
41
 
42
42
  const getPadding = _ref => {
43
43
  let {
@@ -155,7 +155,17 @@ const ChatContainerMessagesList = props$2 => {
155
155
  switch (key) {
156
156
  case 'ArrowUp':
157
157
  e.preventDefault();
158
- if (index > 0) virtualListRef.current.querySelector("[data-index=\"".concat(index - 1, "\"]")).focus();
158
+
159
+ if (index > 0) {
160
+ var _virtualListRef$curre3;
161
+
162
+ ((_virtualListRef$curre3 = virtualListRef.current) === null || _virtualListRef$curre3 === void 0 ? void 0 : _virtualListRef$curre3.querySelector("[data-index=\"".concat(index - 1, "\"]"))).focus();
163
+ } else if (hasMoreItems === 'top') {
164
+ var _loadMoreRef$current;
165
+
166
+ (_loadMoreRef$current = loadMoreRef.current) === null || _loadMoreRef$current === void 0 ? void 0 : _loadMoreRef$current.focus();
167
+ }
168
+
159
169
  break;
160
170
 
161
171
  case 'ArrowDown':
@@ -178,31 +188,31 @@ const ChatContainerMessagesList = props$2 => {
178
188
  break;
179
189
 
180
190
  case 'Tab':
181
- e.preventDefault();
182
-
183
191
  if (hasMoreItems === 'bottom' && !e.shiftKey) {
184
- var _loadMoreRef$current;
185
-
186
- (_loadMoreRef$current = loadMoreRef.current) === null || _loadMoreRef$current === void 0 ? void 0 : _loadMoreRef$current.focus();
187
- } else if (hasMoreItems === 'top' && e.shiftKey) {
188
192
  var _loadMoreRef$current2;
189
193
 
194
+ e.preventDefault();
190
195
  (_loadMoreRef$current2 = loadMoreRef.current) === null || _loadMoreRef$current2 === void 0 ? void 0 : _loadMoreRef$current2.focus();
196
+ } else if (hasMoreItems === 'top' && e.shiftKey) {
197
+ var _loadMoreRef$current3;
198
+
199
+ e.preventDefault();
200
+ (_loadMoreRef$current3 = loadMoreRef.current) === null || _loadMoreRef$current3 === void 0 ? void 0 : _loadMoreRef$current3.focus();
191
201
  } else if (!e.shiftKey) {
192
202
  if (bannerPosition) {
203
+ e.preventDefault();
193
204
  bannerRef.current.focusOnWrapper();
194
- } else {
195
- actionRef.current.focusToComposer();
196
205
  }
197
206
  } else {
198
- var _virtualListRef$curre3;
207
+ var _virtualListRef$curre4;
199
208
 
200
- (_virtualListRef$curre3 = virtualListRef.current) === null || _virtualListRef$curre3 === void 0 ? void 0 : _virtualListRef$curre3.focus();
209
+ e.preventDefault();
210
+ (_virtualListRef$curre4 = virtualListRef.current) === null || _virtualListRef$curre4 === void 0 ? void 0 : _virtualListRef$curre4.focus();
201
211
  }
202
212
 
203
213
  break;
204
214
  }
205
- }, [actionRef, hasMoreItems, messages.length, bannerPosition, scrollAndFocus]);
215
+ }, [actionRef, bannerRef, hasMoreItems, messages.length, bannerPosition, scrollAndFocus]);
206
216
  const handleListKey = React__default["default"].useCallback(e => {
207
217
  const {
208
218
  key
@@ -211,7 +221,13 @@ const ChatContainerMessagesList = props$2 => {
211
221
  switch (key) {
212
222
  case 'ArrowUp':
213
223
  e.preventDefault();
214
- onlyFocus(onScrollStop().shift());
224
+
225
+ if (document.activeElement === loadMoreRef.current) {
226
+ scrollAndFocus(messages.length - 1);
227
+ } else {
228
+ onlyFocus(onScrollStop().shift());
229
+ }
230
+
215
231
  break;
216
232
 
217
233
  case 'ArrowDown':
@@ -232,15 +248,15 @@ const ChatContainerMessagesList = props$2 => {
232
248
  case 'Tab':
233
249
  if (document.activeElement !== loadMoreRef.current) {
234
250
  if (hasMoreItems === 'bottom' && !e.shiftKey) {
235
- var _loadMoreRef$current3;
251
+ var _loadMoreRef$current4;
236
252
 
237
253
  e.preventDefault();
238
- (_loadMoreRef$current3 = loadMoreRef.current) === null || _loadMoreRef$current3 === void 0 ? void 0 : _loadMoreRef$current3.focus();
254
+ (_loadMoreRef$current4 = loadMoreRef.current) === null || _loadMoreRef$current4 === void 0 ? void 0 : _loadMoreRef$current4.focus();
239
255
  } else if (hasMoreItems === 'top' && e.shiftKey) {
240
- var _loadMoreRef$current4;
256
+ var _loadMoreRef$current5;
241
257
 
242
258
  e.preventDefault();
243
- (_loadMoreRef$current4 = loadMoreRef.current) === null || _loadMoreRef$current4 === void 0 ? void 0 : _loadMoreRef$current4.focus();
259
+ (_loadMoreRef$current5 = loadMoreRef.current) === null || _loadMoreRef$current5 === void 0 ? void 0 : _loadMoreRef$current5.focus();
244
260
  } else if (!e.shiftKey) {
245
261
  e.preventDefault();
246
262
  actionRef.current.focusToComposer();
@@ -249,10 +265,10 @@ const ChatContainerMessagesList = props$2 => {
249
265
  e.preventDefault();
250
266
  actionRef.current.focusToComposer();
251
267
  } else {
252
- var _virtualListRef$curre4;
268
+ var _virtualListRef$curre5;
253
269
 
254
270
  e.preventDefault();
255
- (_virtualListRef$curre4 = virtualListRef.current) === null || _virtualListRef$curre4 === void 0 ? void 0 : _virtualListRef$curre4.focus();
271
+ (_virtualListRef$curre5 = virtualListRef.current) === null || _virtualListRef$curre5 === void 0 ? void 0 : _virtualListRef$curre5.focus();
256
272
  }
257
273
 
258
274
  break;
@@ -296,14 +312,14 @@ const ChatContainerMessagesList = props$2 => {
296
312
  "data-index": index,
297
313
  style: style,
298
314
  ref: measureRef,
299
- tabIndex: 0,
315
+ tabIndex: -1,
300
316
  onKeyDown: handleKey,
301
317
  role: "listitem",
302
318
  children: /*#__PURE__*/_jsx__default["default"](styled.StyledWrapperListItem, {
303
319
  type: row.type
304
320
  }, void 0, row.type === props$1.BUBBLE_TYPES.SENDER || row.type === props$1.BUBBLE_TYPES.RECIPIENT ?
305
321
  /*#__PURE__*/
306
- // eslint-disable-next-line
322
+ // eslint-disable-next-line eslint-comments/no-unlimited-disable
307
323
  jsxRuntime.jsx(ChatBubble.ChatBubble, _objectSpread(_objectSpread({}, row), {}, {
308
324
  helpMessage: isSending ? sendingText : row.helpMessage
309
325
  })) : null, row.type === props$1.BUBBLE_TYPES.DELIMITER ? /*#__PURE__*/jsxRuntime.jsx(MessageDelimiter.MessageDelimiter, _objectSpread({}, row)) : null, row.type === props$1.BUBBLE_TYPES.SYSTEM ? /*#__PURE__*/jsxRuntime.jsx(SystemMessage.SystemMessage, _objectSpread({}, row)) : null)
@@ -319,7 +335,7 @@ const ChatContainerMessagesList = props$2 => {
319
335
  onKeyDown: handleListKey,
320
336
  children: /*#__PURE__*/_jsx__default["default"](styled.StyledChatContainerContentListScroll, {
321
337
  height: "".concat(totalSize, "px")
322
- }, void 0, render, !isLoading && hasMoreItems ? /*#__PURE__*/_jsx__default["default"](styled.StyledLoadMoreContainer, {
338
+ }, void 0, !isLoading && hasMoreItems ? /*#__PURE__*/_jsx__default["default"](styled.StyledLoadMoreContainer, {
323
339
  hasMoreItems: hasMoreItems
324
340
  }, void 0, /*#__PURE__*/_jsx__default["default"](DSButton__default["default"], {
325
341
  labelText: "Load More",
@@ -327,7 +343,7 @@ const ChatContainerMessagesList = props$2 => {
327
343
  onClick: getMoreMessages,
328
344
  "data-testid": "ds-chat-load-more-btn",
329
345
  innerRef: loadMoreRef
330
- })) : null)
346
+ })) : null, render)
331
347
  }));
332
348
  };
333
349
 
@@ -28,9 +28,9 @@ var _defineProperty__default = /*#__PURE__*/_interopDefaultLegacy(_definePropert
28
28
  var _jsx__default = /*#__PURE__*/_interopDefaultLegacy(_jsx);
29
29
  var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
30
30
 
31
- function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
31
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
32
32
 
33
- function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty__default["default"](target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
33
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty__default["default"](target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
34
34
 
35
35
  const FooterChat = _ref => {
36
36
  let {
@@ -24,9 +24,9 @@ var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
24
24
 
25
25
  const _excluded = ["label", "dsId", "onClick", "Icon"];
26
26
 
27
- function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
27
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
28
28
 
29
- function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty__default["default"](target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
29
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty__default["default"](target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
30
30
  const SidebarButton = _ref => {
31
31
  let {
32
32
  label,
@@ -18,9 +18,9 @@ import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
18
18
 
19
19
  var _PaperAirplane, _Grid;
20
20
 
21
- function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
21
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
22
22
 
23
- function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
23
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
24
24
 
25
25
  const ChatComposer = props => {
26
26
  var _input$current;
@@ -136,7 +136,7 @@ const ChatComposer = props => {
136
136
  }, void 0, inputMaxLength && hasError ? /*#__PURE__*/jsxs(Fragment, {
137
137
  children: [/*#__PURE__*/_jsx(StyledCounterErrorA11y, {
138
138
  role: "alert"
139
- }, void 0, maxLengthMessage || "You have exceeded the character limit by ".concat(inputLength - inputMaxLength)), maxLengthMessage || "Please limit to less than ".concat(inputMaxLength, " characters. ")]
139
+ }, void 0, maxLengthMessage || "You have entered ".concat(inputLength, " characters and have exceeded the limit by ").concat(inputLength - inputMaxLength, ". Please limit to less than ").concat(inputMaxLength, " characters. ")), maxLengthMessage || "Please limit to less than ".concat(inputMaxLength, " characters. ")]
140
140
  }) : '', inputMaxLength ? " ".concat(inputLength, " / ").concat(inputMaxLength) : ''), _Grid || (_Grid = /*#__PURE__*/_jsx(Grid, {}))));
141
141
  };
142
142
 
@@ -17,11 +17,11 @@ import { StyledIndicatorContainer, StyledChatContainerContent, MobileStyledChatC
17
17
  import { useValidateProps } from './config/useValidateProps.js';
18
18
  import { jsxs, jsx } from 'react/jsx-runtime';
19
19
 
20
- var _DSIndeterminateProgr, _StyledIndicatorConta;
20
+ var _DSIndeterminateProgr;
21
21
 
22
- function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
22
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
23
23
 
24
- function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
24
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
25
25
 
26
26
  const ChatContainer = props => {
27
27
  var _containerRef$current;
@@ -74,17 +74,21 @@ const ChatContainer = props => {
74
74
  const ref = actionRef || listRef;
75
75
 
76
76
  if (e.shiftKey && e.key === 'Tab') {
77
- e.preventDefault();
77
+ if (messagesListProps.messages.length > 0) {
78
+ e.preventDefault();
78
79
 
79
- if (['top', 'bottom'].includes(bannerPosition)) {
80
- bannerRef.current.focusOnWrapper();
81
- } else {
82
- const last = ref.current.getMessagesInView().pop();
83
- ref.current.focusToIndexWithoutScroll(last);
80
+ if (['top', 'bottom'].includes(bannerPosition)) {
81
+ bannerRef.current.focusOnWrapper();
82
+ } else {
83
+ var _ref$current;
84
+
85
+ const last = ref.current.getMessagesInView().pop();
86
+ (_ref$current = ref.current) === null || _ref$current === void 0 ? void 0 : _ref$current.focusToIndexWithoutScroll(last);
87
+ }
84
88
  }
85
89
  }
86
90
  }
87
- }, [actionRef, onComposerKeyDown, bannerPosition]); // Map actions
91
+ }, [actionRef, onComposerKeyDown, bannerPosition, messagesListProps.messages.length]); // Map actions
88
92
 
89
93
  React.useEffect(() => {
90
94
  if (actionRef && actionRef.current) {
@@ -134,15 +138,15 @@ const ChatContainer = props => {
134
138
  isOpen: true,
135
139
  type: bannerProps.type || BANNER_TYPES.INFO,
136
140
  actionRef: bannerRef
137
- })), sendingMessages && sendingMessages.length > 0 ? _StyledIndicatorConta || (_StyledIndicatorConta = /*#__PURE__*/_jsx(StyledIndicatorContainer, {
141
+ })), sendingMessages && sendingMessages.length > 0 ? /*#__PURE__*/_jsx(StyledIndicatorContainer, {
138
142
  isLoading: "bottom",
139
143
  linear: true,
140
144
  "data-testid": "ds-chat-loading-indicator"
141
145
  }, void 0, /*#__PURE__*/_jsx(DSIndeterminateProgressIndicator, {
142
146
  processing: true,
143
- title: "Loading",
147
+ title: sendingText,
144
148
  lineOnly: true
145
- }))) : null), /*#__PURE__*/jsx(ChatComposer, _objectSpread(_objectSpread({}, composerProps), {}, {
149
+ })) : null), /*#__PURE__*/jsx(ChatComposer, _objectSpread(_objectSpread({}, composerProps), {}, {
146
150
  onKeyDown: handleTabs,
147
151
  onResize: onResize,
148
152
  maxHeight: (((_containerRef$current = containerRef.current) === null || _containerRef$current === void 0 ? void 0 : _containerRef$current.clientHeight) || 0) / 2,
@@ -24,9 +24,9 @@ import { listProps, defaultProps } from './props.js';
24
24
  import { useValidateProps } from './config/useValidateProps.js';
25
25
  import { jsx } from 'react/jsx-runtime';
26
26
 
27
- function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
27
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
28
28
 
29
- function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
29
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
30
30
 
31
31
  const getPadding = _ref => {
32
32
  let {
@@ -144,7 +144,17 @@ const ChatContainerMessagesList = props => {
144
144
  switch (key) {
145
145
  case 'ArrowUp':
146
146
  e.preventDefault();
147
- if (index > 0) virtualListRef.current.querySelector("[data-index=\"".concat(index - 1, "\"]")).focus();
147
+
148
+ if (index > 0) {
149
+ var _virtualListRef$curre3;
150
+
151
+ ((_virtualListRef$curre3 = virtualListRef.current) === null || _virtualListRef$curre3 === void 0 ? void 0 : _virtualListRef$curre3.querySelector("[data-index=\"".concat(index - 1, "\"]"))).focus();
152
+ } else if (hasMoreItems === 'top') {
153
+ var _loadMoreRef$current;
154
+
155
+ (_loadMoreRef$current = loadMoreRef.current) === null || _loadMoreRef$current === void 0 ? void 0 : _loadMoreRef$current.focus();
156
+ }
157
+
148
158
  break;
149
159
 
150
160
  case 'ArrowDown':
@@ -167,31 +177,31 @@ const ChatContainerMessagesList = props => {
167
177
  break;
168
178
 
169
179
  case 'Tab':
170
- e.preventDefault();
171
-
172
180
  if (hasMoreItems === 'bottom' && !e.shiftKey) {
173
- var _loadMoreRef$current;
174
-
175
- (_loadMoreRef$current = loadMoreRef.current) === null || _loadMoreRef$current === void 0 ? void 0 : _loadMoreRef$current.focus();
176
- } else if (hasMoreItems === 'top' && e.shiftKey) {
177
181
  var _loadMoreRef$current2;
178
182
 
183
+ e.preventDefault();
179
184
  (_loadMoreRef$current2 = loadMoreRef.current) === null || _loadMoreRef$current2 === void 0 ? void 0 : _loadMoreRef$current2.focus();
185
+ } else if (hasMoreItems === 'top' && e.shiftKey) {
186
+ var _loadMoreRef$current3;
187
+
188
+ e.preventDefault();
189
+ (_loadMoreRef$current3 = loadMoreRef.current) === null || _loadMoreRef$current3 === void 0 ? void 0 : _loadMoreRef$current3.focus();
180
190
  } else if (!e.shiftKey) {
181
191
  if (bannerPosition) {
192
+ e.preventDefault();
182
193
  bannerRef.current.focusOnWrapper();
183
- } else {
184
- actionRef.current.focusToComposer();
185
194
  }
186
195
  } else {
187
- var _virtualListRef$curre3;
196
+ var _virtualListRef$curre4;
188
197
 
189
- (_virtualListRef$curre3 = virtualListRef.current) === null || _virtualListRef$curre3 === void 0 ? void 0 : _virtualListRef$curre3.focus();
198
+ e.preventDefault();
199
+ (_virtualListRef$curre4 = virtualListRef.current) === null || _virtualListRef$curre4 === void 0 ? void 0 : _virtualListRef$curre4.focus();
190
200
  }
191
201
 
192
202
  break;
193
203
  }
194
- }, [actionRef, hasMoreItems, messages.length, bannerPosition, scrollAndFocus]);
204
+ }, [actionRef, bannerRef, hasMoreItems, messages.length, bannerPosition, scrollAndFocus]);
195
205
  const handleListKey = React.useCallback(e => {
196
206
  const {
197
207
  key
@@ -200,7 +210,13 @@ const ChatContainerMessagesList = props => {
200
210
  switch (key) {
201
211
  case 'ArrowUp':
202
212
  e.preventDefault();
203
- onlyFocus(onScrollStop().shift());
213
+
214
+ if (document.activeElement === loadMoreRef.current) {
215
+ scrollAndFocus(messages.length - 1);
216
+ } else {
217
+ onlyFocus(onScrollStop().shift());
218
+ }
219
+
204
220
  break;
205
221
 
206
222
  case 'ArrowDown':
@@ -221,15 +237,15 @@ const ChatContainerMessagesList = props => {
221
237
  case 'Tab':
222
238
  if (document.activeElement !== loadMoreRef.current) {
223
239
  if (hasMoreItems === 'bottom' && !e.shiftKey) {
224
- var _loadMoreRef$current3;
240
+ var _loadMoreRef$current4;
225
241
 
226
242
  e.preventDefault();
227
- (_loadMoreRef$current3 = loadMoreRef.current) === null || _loadMoreRef$current3 === void 0 ? void 0 : _loadMoreRef$current3.focus();
243
+ (_loadMoreRef$current4 = loadMoreRef.current) === null || _loadMoreRef$current4 === void 0 ? void 0 : _loadMoreRef$current4.focus();
228
244
  } else if (hasMoreItems === 'top' && e.shiftKey) {
229
- var _loadMoreRef$current4;
245
+ var _loadMoreRef$current5;
230
246
 
231
247
  e.preventDefault();
232
- (_loadMoreRef$current4 = loadMoreRef.current) === null || _loadMoreRef$current4 === void 0 ? void 0 : _loadMoreRef$current4.focus();
248
+ (_loadMoreRef$current5 = loadMoreRef.current) === null || _loadMoreRef$current5 === void 0 ? void 0 : _loadMoreRef$current5.focus();
233
249
  } else if (!e.shiftKey) {
234
250
  e.preventDefault();
235
251
  actionRef.current.focusToComposer();
@@ -238,10 +254,10 @@ const ChatContainerMessagesList = props => {
238
254
  e.preventDefault();
239
255
  actionRef.current.focusToComposer();
240
256
  } else {
241
- var _virtualListRef$curre4;
257
+ var _virtualListRef$curre5;
242
258
 
243
259
  e.preventDefault();
244
- (_virtualListRef$curre4 = virtualListRef.current) === null || _virtualListRef$curre4 === void 0 ? void 0 : _virtualListRef$curre4.focus();
260
+ (_virtualListRef$curre5 = virtualListRef.current) === null || _virtualListRef$curre5 === void 0 ? void 0 : _virtualListRef$curre5.focus();
245
261
  }
246
262
 
247
263
  break;
@@ -285,14 +301,14 @@ const ChatContainerMessagesList = props => {
285
301
  "data-index": index,
286
302
  style: style,
287
303
  ref: measureRef,
288
- tabIndex: 0,
304
+ tabIndex: -1,
289
305
  onKeyDown: handleKey,
290
306
  role: "listitem",
291
307
  children: /*#__PURE__*/_jsx(StyledWrapperListItem, {
292
308
  type: row.type
293
309
  }, void 0, row.type === BUBBLE_TYPES.SENDER || row.type === BUBBLE_TYPES.RECIPIENT ?
294
310
  /*#__PURE__*/
295
- // eslint-disable-next-line
311
+ // eslint-disable-next-line eslint-comments/no-unlimited-disable
296
312
  jsx(ChatBubble, _objectSpread(_objectSpread({}, row), {}, {
297
313
  helpMessage: isSending ? sendingText : row.helpMessage
298
314
  })) : null, row.type === BUBBLE_TYPES.DELIMITER ? /*#__PURE__*/jsx(MessageDelimiter, _objectSpread({}, row)) : null, row.type === BUBBLE_TYPES.SYSTEM ? /*#__PURE__*/jsx(SystemMessage, _objectSpread({}, row)) : null)
@@ -308,7 +324,7 @@ const ChatContainerMessagesList = props => {
308
324
  onKeyDown: handleListKey,
309
325
  children: /*#__PURE__*/_jsx(StyledChatContainerContentListScroll, {
310
326
  height: "".concat(totalSize, "px")
311
- }, void 0, render, !isLoading && hasMoreItems ? /*#__PURE__*/_jsx(StyledLoadMoreContainer, {
327
+ }, void 0, !isLoading && hasMoreItems ? /*#__PURE__*/_jsx(StyledLoadMoreContainer, {
312
328
  hasMoreItems: hasMoreItems
313
329
  }, void 0, /*#__PURE__*/_jsx(DSButton, {
314
330
  labelText: "Load More",
@@ -316,7 +332,7 @@ const ChatContainerMessagesList = props => {
316
332
  onClick: getMoreMessages,
317
333
  "data-testid": "ds-chat-load-more-btn",
318
334
  innerRef: loadMoreRef
319
- })) : null)
335
+ })) : null, render)
320
336
  }));
321
337
  };
322
338
 
@@ -18,9 +18,9 @@ import { chatSidebarProps, defaultProps } from './props.js';
18
18
  import { useValidateProps } from './config/useValidateProps.js';
19
19
  import { jsxs, jsx } from 'react/jsx-runtime';
20
20
 
21
- function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
21
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
22
22
 
23
- function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
23
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
24
24
 
25
25
  const FooterChat = _ref => {
26
26
  let {
@@ -13,9 +13,9 @@ import { jsxs } from 'react/jsx-runtime';
13
13
 
14
14
  const _excluded = ["label", "dsId", "onClick", "Icon"];
15
15
 
16
- function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
16
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
17
17
 
18
- function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
18
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
19
19
  const SidebarButton = _ref => {
20
20
  let {
21
21
  label,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@elliemae/ds-chat",
3
- "version": "2.0.1",
3
+ "version": "2.1.0-rc.0",
4
4
  "license": "MIT",
5
5
  "description": "ICE MT - Dimsum - Chat",
6
6
  "module": "./esm/index.js",
@@ -305,22 +305,22 @@
305
305
  "generateSubmodules": true
306
306
  },
307
307
  "dependencies": {
308
- "@elliemae/ds-banner": "2.0.1",
309
- "@elliemae/ds-button": "2.0.1",
310
- "@elliemae/ds-grid": "2.0.1",
311
- "@elliemae/ds-icons": "2.0.1",
312
- "@elliemae/ds-indeterminate-progress-indicator": "2.0.1",
313
- "@elliemae/ds-props-helpers": "2.0.1",
314
- "@elliemae/ds-system": "2.0.1",
315
- "@elliemae/ds-tooltip": "2.0.1",
316
- "@elliemae/ds-truncated-tooltip-text": "2.0.1",
308
+ "@elliemae/ds-banner": "2.1.0-rc.0",
309
+ "@elliemae/ds-button": "2.1.0-rc.0",
310
+ "@elliemae/ds-grid": "2.1.0-rc.0",
311
+ "@elliemae/ds-icons": "2.1.0-rc.0",
312
+ "@elliemae/ds-indeterminate-progress-indicator": "2.1.0-rc.0",
313
+ "@elliemae/ds-props-helpers": "2.1.0-rc.0",
314
+ "@elliemae/ds-system": "2.1.0-rc.0",
315
+ "@elliemae/ds-tooltip": "2.1.0-rc.0",
316
+ "@elliemae/ds-truncated-tooltip-text": "2.1.0-rc.0",
317
317
  "prop-types": "~15.7.2",
318
318
  "react-desc": "~4.1.2",
319
319
  "react-virtual": "~2.3.2"
320
320
  },
321
321
  "devDependencies": {
322
322
  "@testing-library/dom": "~8.11.1",
323
- "@testing-library/jest-dom": "~5.15.1",
323
+ "@testing-library/jest-dom": "~5.15.0",
324
324
  "@testing-library/react": "~12.1.2",
325
325
  "@testing-library/user-event": "~13.5.0",
326
326
  "styled-components": "~5.3.3"
@@ -6,22 +6,22 @@ declare const ChatCard: {
6
6
  propTypes: {
7
7
  title: any;
8
8
  content: {
9
- defaultValue<T = unknown>(arg: T): {
9
+ defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
10
10
  deprecated: import("react-desc").PropTypesDescValidator;
11
11
  };
12
- isRequired: import("react-desc").PropTypesDescValidator;
12
+ isRequired: import("react-desc").PropTypesDescValue;
13
13
  };
14
14
  time: {
15
- defaultValue<T = unknown>(arg: T): {
15
+ defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
16
16
  deprecated: import("react-desc").PropTypesDescValidator;
17
17
  };
18
- isRequired: import("react-desc").PropTypesDescValidator;
18
+ isRequired: import("react-desc").PropTypesDescValue;
19
19
  };
20
20
  rightAddon: {
21
- defaultValue<T = unknown>(arg: T): {
21
+ defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
22
22
  deprecated: import("react-desc").PropTypesDescValidator;
23
23
  };
24
- isRequired: import("react-desc").PropTypesDescValidator;
24
+ isRequired: import("react-desc").PropTypesDescValue;
25
25
  };
26
26
  };
27
27
  };
@@ -3,22 +3,22 @@
3
3
  export declare const propTypes: {
4
4
  title: any;
5
5
  content: {
6
- defaultValue<T = unknown>(arg: T): {
6
+ defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
7
7
  deprecated: import("react-desc").PropTypesDescValidator;
8
8
  };
9
- isRequired: import("react-desc").PropTypesDescValidator;
9
+ isRequired: import("react-desc").PropTypesDescValue;
10
10
  };
11
11
  time: {
12
- defaultValue<T = unknown>(arg: T): {
12
+ defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
13
13
  deprecated: import("react-desc").PropTypesDescValidator;
14
14
  };
15
- isRequired: import("react-desc").PropTypesDescValidator;
15
+ isRequired: import("react-desc").PropTypesDescValue;
16
16
  };
17
17
  rightAddon: {
18
- defaultValue<T = unknown>(arg: T): {
18
+ defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
19
19
  deprecated: import("react-desc").PropTypesDescValidator;
20
20
  };
21
- isRequired: import("react-desc").PropTypesDescValidator;
21
+ isRequired: import("react-desc").PropTypesDescValue;
22
22
  };
23
23
  };
24
24
  export interface CardPropTypes {
@@ -1,157 +1,5 @@
1
- /// <reference path="../../../../../../shared/typings/react-desc.d.ts" />
2
- /// <reference types="react" />
3
- export declare const StyledChatContainerContentComposer: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<import("@elliemae/ds-grid/types/types").GridPropsT & import("react").RefAttributes<HTMLDivElement>>, import("styled-components").DefaultTheme, {}, never>;
1
+ export declare const StyledChatContainerContentComposer: import("styled-components").StyledComponent<any, import("styled-components").DefaultTheme, object, string | number | symbol>;
4
2
  export declare const StyledComposerInput: import("styled-components").StyledComponent<"textarea", import("styled-components").DefaultTheme, any, never>;
5
- export declare const StyledComposerButton: import("styled-components").StyledComponent<{
6
- ({ innerRef, disabled, buttonType, fluidWidth, size, labelText, icon, onBlur, onClick, onKeyPress, leftIcon, tabIndex, variant, intent, containerProps, className, as: Component, type, ...rest }: {
7
- [x: string]: any;
8
- innerRef: any;
9
- disabled: any;
10
- buttonType: any;
11
- fluidWidth: any;
12
- size: any;
13
- labelText: any;
14
- icon: any;
15
- onBlur: any;
16
- onClick: any;
17
- onKeyPress: any;
18
- leftIcon: any;
19
- tabIndex: any;
20
- variant: any;
21
- intent: any;
22
- containerProps: any;
23
- className: any;
24
- as: any;
25
- type: any;
26
- }): JSX.Element;
27
- defaultProps: {
28
- disabled: boolean;
29
- fluidWidth: boolean;
30
- labelText: string;
31
- icon: null;
32
- onBlur: () => null;
33
- onClick: () => null;
34
- onKeyPress: () => null;
35
- leftIcon: null;
36
- tabIndex: number;
37
- variant: string;
38
- containerProps: {};
39
- as: string;
40
- type: string;
41
- };
42
- propTypes: {
43
- tabIndex: {
44
- defaultValue<T = unknown>(arg: T): {
45
- deprecated: import("react-desc").PropTypesDescValidator;
46
- };
47
- isRequired: import("react-desc").PropTypesDescValidator;
48
- };
49
- className: {
50
- defaultValue<T_1 = unknown>(arg: T_1): {
51
- deprecated: import("react-desc").PropTypesDescValidator;
52
- };
53
- isRequired: import("react-desc").PropTypesDescValidator;
54
- };
55
- 'aria-disabled': {
56
- defaultValue<T_2 = unknown>(arg: T_2): {
57
- deprecated: import("react-desc").PropTypesDescValidator;
58
- };
59
- isRequired: import("react-desc").PropTypesDescValidator;
60
- };
61
- as: {
62
- deprecated: import("react-desc").PropTypesDescValidator;
63
- };
64
- disabled: {
65
- defaultValue<T_3 = unknown>(arg: T_3): {
66
- deprecated: import("react-desc").PropTypesDescValidator;
67
- };
68
- isRequired: import("react-desc").PropTypesDescValidator;
69
- };
70
- fluidWidth: {
71
- defaultValue<T_4 = unknown>(arg: T_4): {
72
- deprecated: import("react-desc").PropTypesDescValidator;
73
- };
74
- isRequired: import("react-desc").PropTypesDescValidator;
75
- };
76
- labelText: {
77
- defaultValue<T_5 = unknown>(arg: T_5): {
78
- deprecated: import("react-desc").PropTypesDescValidator;
79
- };
80
- isRequired: import("react-desc").PropTypesDescValidator;
81
- };
82
- icon: {
83
- defaultValue<T_6 = unknown>(arg: T_6): {
84
- deprecated: import("react-desc").PropTypesDescValidator;
85
- };
86
- isRequired: import("react-desc").PropTypesDescValidator;
87
- };
88
- leftIcon: {
89
- defaultValue<T_7 = unknown>(arg: T_7): {
90
- deprecated: import("react-desc").PropTypesDescValidator;
91
- };
92
- isRequired: import("react-desc").PropTypesDescValidator;
93
- };
94
- buttonType: {
95
- defaultValue<T_8 = unknown>(arg: T_8): {
96
- deprecated: import("react-desc").PropTypesDescValidator;
97
- };
98
- isRequired: import("react-desc").PropTypesDescValidator;
99
- };
100
- size: {
101
- defaultValue<T_9 = unknown>(arg: T_9): {
102
- deprecated: import("react-desc").PropTypesDescValidator;
103
- };
104
- isRequired: import("react-desc").PropTypesDescValidator;
105
- };
106
- type: {
107
- defaultValue<T_10 = unknown>(arg: T_10): {
108
- deprecated: import("react-desc").PropTypesDescValidator;
109
- };
110
- isRequired: import("react-desc").PropTypesDescValidator;
111
- };
112
- variant: {
113
- defaultValue<T_11 = unknown>(arg: T_11): {
114
- deprecated: import("react-desc").PropTypesDescValidator;
115
- };
116
- isRequired: import("react-desc").PropTypesDescValidator;
117
- };
118
- innerRef: {
119
- defaultValue<T_12 = unknown>(arg: T_12): {
120
- deprecated: import("react-desc").PropTypesDescValidator;
121
- };
122
- isRequired: import("react-desc").PropTypesDescValidator;
123
- };
124
- onBlur: {
125
- defaultValue<T_13 = unknown>(arg: T_13): {
126
- deprecated: import("react-desc").PropTypesDescValidator;
127
- };
128
- isRequired: import("react-desc").PropTypesDescValidator;
129
- };
130
- intent: {
131
- defaultValue<T_14 = unknown>(arg: T_14): {
132
- deprecated: import("react-desc").PropTypesDescValidator;
133
- };
134
- isRequired: import("react-desc").PropTypesDescValidator;
135
- };
136
- containerProps: {
137
- defaultValue<T_15 = unknown>(arg: T_15): {
138
- deprecated: import("react-desc").PropTypesDescValidator;
139
- };
140
- isRequired: import("react-desc").PropTypesDescValidator;
141
- };
142
- onClick: {
143
- defaultValue<T_16 = unknown>(arg: T_16): {
144
- deprecated: import("react-desc").PropTypesDescValidator;
145
- };
146
- isRequired: import("react-desc").PropTypesDescValidator;
147
- };
148
- onKeyPress: {
149
- defaultValue<T_17 = unknown>(arg: T_17): {
150
- deprecated: import("react-desc").PropTypesDescValidator;
151
- };
152
- isRequired: import("react-desc").PropTypesDescValidator;
153
- };
154
- };
155
- }, import("styled-components").DefaultTheme, {}, never>;
156
- export declare const StyledCounterArea: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<import("@elliemae/ds-grid/types/types").GridPropsT & import("react").RefAttributes<HTMLDivElement>>, import("styled-components").DefaultTheme, {}, never>;
3
+ export declare const StyledComposerButton: import("styled-components").StyledComponent<any, import("styled-components").DefaultTheme, object, string | number | symbol>;
4
+ export declare const StyledCounterArea: import("styled-components").StyledComponent<any, import("styled-components").DefaultTheme, object, string | number | symbol>;
157
5
  export declare const StyledCounterErrorA11y: import("styled-components").StyledComponent<"span", import("styled-components").DefaultTheme, {}, never>;
@@ -17,25 +17,25 @@ declare const ChatContainer: {
17
17
  deprecated: import("react-desc").PropTypesDescValidator;
18
18
  };
19
19
  isLoading: {
20
- defaultValue<T = unknown>(arg: T): {
20
+ defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
21
21
  deprecated: import("react-desc").PropTypesDescValidator;
22
22
  };
23
- isRequired: import("react-desc").PropTypesDescValidator;
23
+ isRequired: import("react-desc").PropTypesDescValue;
24
24
  };
25
25
  hasMoreItems: {
26
- defaultValue<T = unknown>(arg: T): {
26
+ defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
27
27
  deprecated: import("react-desc").PropTypesDescValidator;
28
28
  };
29
- isRequired: import("react-desc").PropTypesDescValidator;
29
+ isRequired: import("react-desc").PropTypesDescValue;
30
30
  };
31
31
  getMoreMessages: {
32
32
  deprecated: import("react-desc").PropTypesDescValidator;
33
33
  };
34
34
  bannerPosition: {
35
- defaultValue<T = unknown>(arg: T): {
35
+ defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
36
36
  deprecated: import("react-desc").PropTypesDescValidator;
37
37
  };
38
- isRequired: import("react-desc").PropTypesDescValidator;
38
+ isRequired: import("react-desc").PropTypesDescValue;
39
39
  };
40
40
  bannerProps: {
41
41
  deprecated: import("react-desc").PropTypesDescValidator;
@@ -11,22 +11,22 @@ declare const ChatContainerMessagesList: {
11
11
  deprecated: import("react-desc").PropTypesDescValidator;
12
12
  };
13
13
  onScrollEnds: {
14
- defaultValue<T = unknown>(arg: T): {
14
+ defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
15
15
  deprecated: import("react-desc").PropTypesDescValidator;
16
16
  };
17
- isRequired: import("react-desc").PropTypesDescValidator;
17
+ isRequired: import("react-desc").PropTypesDescValue;
18
18
  };
19
19
  isLoading: {
20
- defaultValue<T = unknown>(arg: T): {
20
+ defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
21
21
  deprecated: import("react-desc").PropTypesDescValidator;
22
22
  };
23
- isRequired: import("react-desc").PropTypesDescValidator;
23
+ isRequired: import("react-desc").PropTypesDescValue;
24
24
  };
25
25
  hasMoreItems: {
26
- defaultValue<T = unknown>(arg: T): {
26
+ defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
27
27
  deprecated: import("react-desc").PropTypesDescValidator;
28
28
  };
29
- isRequired: import("react-desc").PropTypesDescValidator;
29
+ isRequired: import("react-desc").PropTypesDescValue;
30
30
  };
31
31
  getMoreMessages: {
32
32
  deprecated: import("react-desc").PropTypesDescValidator;
@@ -10,16 +10,16 @@ declare const MessageDelimiter: {
10
10
  deprecated: import("react-desc").PropTypesDescValidator;
11
11
  };
12
12
  extraProps: {
13
- defaultValue<T = unknown>(arg: T): {
13
+ defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
14
14
  deprecated: import("react-desc").PropTypesDescValidator;
15
15
  };
16
- isRequired: import("react-desc").PropTypesDescValidator;
16
+ isRequired: import("react-desc").PropTypesDescValue;
17
17
  };
18
18
  verticalMargin: {
19
- defaultValue<T = unknown>(arg: T): {
19
+ defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
20
20
  deprecated: import("react-desc").PropTypesDescValidator;
21
21
  };
22
- isRequired: import("react-desc").PropTypesDescValidator;
22
+ isRequired: import("react-desc").PropTypesDescValue;
23
23
  };
24
24
  };
25
25
  };
@@ -12,15 +12,15 @@ export declare const messageDelimiterProps: {
12
12
  deprecated: import("react-desc").PropTypesDescValidator;
13
13
  };
14
14
  extraProps: {
15
- defaultValue<T = unknown>(arg: T): {
15
+ defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
16
16
  deprecated: import("react-desc").PropTypesDescValidator;
17
17
  };
18
- isRequired: import("react-desc").PropTypesDescValidator;
18
+ isRequired: import("react-desc").PropTypesDescValue;
19
19
  };
20
20
  verticalMargin: {
21
- defaultValue<T = unknown>(arg: T): {
21
+ defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
22
22
  deprecated: import("react-desc").PropTypesDescValidator;
23
23
  };
24
- isRequired: import("react-desc").PropTypesDescValidator;
24
+ isRequired: import("react-desc").PropTypesDescValue;
25
25
  };
26
26
  };
@@ -7,10 +7,10 @@ declare const SystemMessage: {
7
7
  propTypes: {
8
8
  title: any;
9
9
  time: {
10
- defaultValue<T = unknown>(arg: T): {
10
+ defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
11
11
  deprecated: import("react-desc").PropTypesDescValidator;
12
12
  };
13
- isRequired: import("react-desc").PropTypesDescValidator;
13
+ isRequired: import("react-desc").PropTypesDescValue;
14
14
  };
15
15
  body: any;
16
16
  };
@@ -8,10 +8,10 @@ export declare const defaultProps: SystemMessageProps;
8
8
  export declare const systemMessageProps: {
9
9
  title: any;
10
10
  time: {
11
- defaultValue<T = unknown>(arg: T): {
11
+ defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
12
12
  deprecated: import("react-desc").PropTypesDescValidator;
13
13
  };
14
- isRequired: import("react-desc").PropTypesDescValidator;
14
+ isRequired: import("react-desc").PropTypesDescValue;
15
15
  };
16
16
  body: any;
17
17
  };
@@ -59,10 +59,10 @@ declare const TileButton: {
59
59
  deprecated: import("react-desc").PropTypesDescValidator;
60
60
  };
61
61
  innerRef: {
62
- defaultValue<T = unknown>(arg: T): {
62
+ defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
63
63
  deprecated: import("react-desc").PropTypesDescValidator;
64
64
  };
65
- isRequired: import("react-desc").PropTypesDescValidator;
65
+ isRequired: import("react-desc").PropTypesDescValue;
66
66
  };
67
67
  };
68
68
  defaultProps: TileButtonProps;
@@ -80,9 +80,9 @@ export declare const propsTileButton: {
80
80
  deprecated: import("react-desc").PropTypesDescValidator;
81
81
  };
82
82
  innerRef: {
83
- defaultValue<T = unknown>(arg: T): {
83
+ defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
84
84
  deprecated: import("react-desc").PropTypesDescValidator;
85
85
  };
86
- isRequired: import("react-desc").PropTypesDescValidator;
86
+ isRequired: import("react-desc").PropTypesDescValue;
87
87
  };
88
88
  };