@cloudscape-design/chat-components 1.0.19 → 1.0.21

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.
@@ -1,4 +1,4 @@
1
1
  export var PACKAGE_SOURCE = "chat-components";
2
- export var PACKAGE_VERSION = "1.0.0 (aefa6dab)";
2
+ export var PACKAGE_VERSION = "1.0.0 (62fec21f)";
3
3
  export var THEME = "open-source-visual-refresh";
4
4
  export var ALWAYS_VISUAL_REFRESH = true;
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "PACKAGE_SOURCE": "chat-components",
3
- "PACKAGE_VERSION": "1.0.0 (aefa6dab)",
3
+ "PACKAGE_VERSION": "1.0.0 (62fec21f)",
4
4
  "THEME": "open-source-visual-refresh",
5
5
  "ALWAYS_VISUAL_REFRESH": true
6
6
  }
@@ -1,3 +1,3 @@
1
1
  {
2
- "commit": "aefa6dabdee7d032b73fc0b0b7fe455184b98ca4"
2
+ "commit": "62fec21fadc0b3a2fc355d95b7e2d4a968dce706"
3
3
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cloudscape-design/chat-components",
3
- "version": "1.0.19",
3
+ "version": "1.0.21",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/cloudscape-design/chat-components.git"
@@ -1,11 +1,10 @@
1
1
  import { ElementWrapper } from '@cloudscape-design/test-utils-core/dom';
2
- import '@cloudscape-design/components/test-utils/dom';
3
2
  export { ElementWrapper };
4
3
  import AvatarWrapper from './avatar';
5
- export { AvatarWrapper };
6
4
  import ChatBubbleWrapper from './chat-bubble';
7
- export { ChatBubbleWrapper };
8
5
  import LoadingBarWrapper from './loading-bar';
6
+ export { AvatarWrapper };
7
+ export { ChatBubbleWrapper };
9
8
  export { LoadingBarWrapper };
10
9
  declare module '@cloudscape-design/test-utils-core/dist/dom' {
11
10
  interface ElementWrapper {
@@ -1,9 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.LoadingBarWrapper = exports.ChatBubbleWrapper = exports.AvatarWrapper = exports.ElementWrapper = void 0;
4
+ // Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
5
+ // SPDX-License-Identifier: Apache-2.0
4
6
  const dom_1 = require("@cloudscape-design/test-utils-core/dom");
5
7
  Object.defineProperty(exports, "ElementWrapper", { enumerable: true, get: function () { return dom_1.ElementWrapper; } });
6
- require("@cloudscape-design/components/test-utils/dom");
7
8
  const utils_1 = require("@cloudscape-design/test-utils-core/utils");
8
9
  const avatar_1 = require("./avatar");
9
10
  exports.AvatarWrapper = avatar_1.default;
@@ -38,8 +39,12 @@ dom_1.ElementWrapper.prototype.findLoadingBar = function (selector) {
38
39
  dom_1.ElementWrapper.prototype.findAllLoadingBars = function (selector) {
39
40
  return this.findAllComponents(loading_bar_1.default, selector);
40
41
  };
41
- function wrapper(root = document.body) { if (document && document.body && !document.body.contains(root)) {
42
- console.warn('[AwsUi] [test-utils] provided element is not part of the document body, interactions may work incorrectly');
43
- } ; return new dom_1.ElementWrapper(root); }
42
+ function wrapper(root = document.body) {
43
+ if (document && document.body && !document.body.contains(root)) {
44
+ console.warn('[AwsUi] [test-utils] provided element is not part of the document body, interactions may work incorrectly');
45
+ }
46
+ ;
47
+ return new dom_1.ElementWrapper(root);
48
+ }
44
49
  exports.default = wrapper;
45
50
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/test-utils/dom/index.ts"],"names":[],"mappings":";;;AAAA,gEAAwE;AAG/D,+FAHA,oBAAc,OAGA;AAFvB,wDAAsD;AACtD,oEAA0E;AAGlE,qCAAqC;AAC5B,wBADF,gBAAa,CACE;AAGtB,+CAA8C;AACrC,4BADF,qBAAiB,CACE;AAG1B,+CAA8C;AACrC,4BADF,qBAAiB,CACE;AAmE5B,oBAAc,CAAC,SAAS,CAAC,UAAU,GAAG,UAAS,QAAQ;IACr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,SAAS,CAAC,kBAAkB,GAAG,UAAS,QAAQ;IAC7D,OAAO,IAAI,CAAC,iBAAiB,CAAC,qBAAiB,EAAE,QAAQ,CAAC,CAAC;AAC7D,CAAC,CAAC;AACR,SAAwB,OAAO,CAAC,OAAgB,QAAQ,CAAC,IAAI,IAAI,IAAI,QAAQ,IAAI,QAAQ,CAAC,IAAI,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,EAAE;IAAE,OAAO,CAAC,IAAI,CAAC,2GAA2G,CAAC,CAAA;CAAC,CAAA,CAAC,CAAC,OAAO,IAAI,oBAAc,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAAjS,0BAAiS","sourcesContent":["import { ElementWrapper } from '@cloudscape-design/test-utils-core/dom';\nimport '@cloudscape-design/components/test-utils/dom';\nimport { appendSelector } from '@cloudscape-design/test-utils-core/utils';\nexport { ElementWrapper };\n\n import AvatarWrapper from './avatar';\n export { AvatarWrapper };\n \n\n import ChatBubbleWrapper from './chat-bubble';\n export { ChatBubbleWrapper };\n \n\n import LoadingBarWrapper from './loading-bar';\n export { LoadingBarWrapper };\n \ndeclare module '@cloudscape-design/test-utils-core/dist/dom' {\n interface ElementWrapper {\n \n /**\n * Returns the wrapper of the first Avatar that matches the specified CSS selector.\n * If no CSS selector is specified, returns the wrapper of the first Avatar.\n * If no matching Avatar is found, returns `null`.\n *\n * @param {string} [selector] CSS Selector\n * @returns {AvatarWrapper | null}\n */\n findAvatar(selector?: string): AvatarWrapper | null;\n\n /**\n * Returns an array of Avatar wrapper that matches the specified CSS selector.\n * If no CSS selector is specified, returns all of the Avatars inside the current wrapper.\n * If no matching Avatar is found, returns an empty array.\n *\n * @param {string} [selector] CSS Selector\n * @returns {Array<AvatarWrapper>}\n */\n findAllAvatars(selector?: string): Array<AvatarWrapper>;\n\n /**\n * Returns the wrapper of the first ChatBubble that matches the specified CSS selector.\n * If no CSS selector is specified, returns the wrapper of the first ChatBubble.\n * If no matching ChatBubble is found, returns `null`.\n *\n * @param {string} [selector] CSS Selector\n * @returns {ChatBubbleWrapper | null}\n */\n findChatBubble(selector?: string): ChatBubbleWrapper | null;\n\n /**\n * Returns an array of ChatBubble wrapper that matches the specified CSS selector.\n * If no CSS selector is specified, returns all of the ChatBubbles inside the current wrapper.\n * If no matching ChatBubble is found, returns an empty array.\n *\n * @param {string} [selector] CSS Selector\n * @returns {Array<ChatBubbleWrapper>}\n */\n findAllChatBubbles(selector?: string): Array<ChatBubbleWrapper>;\n\n /**\n * Returns the wrapper of the first LoadingBar that matches the specified CSS selector.\n * If no CSS selector is specified, returns the wrapper of the first LoadingBar.\n * If no matching LoadingBar is found, returns `null`.\n *\n * @param {string} [selector] CSS Selector\n * @returns {LoadingBarWrapper | null}\n */\n findLoadingBar(selector?: string): LoadingBarWrapper | null;\n\n /**\n * Returns an array of LoadingBar wrapper that matches the specified CSS selector.\n * If no CSS selector is specified, returns all of the LoadingBars inside the current wrapper.\n * If no matching LoadingBar is found, returns an empty array.\n *\n * @param {string} [selector] CSS Selector\n * @returns {Array<LoadingBarWrapper>}\n */\n findAllLoadingBars(selector?: string): Array<LoadingBarWrapper>;\n }\n }\n\n ElementWrapper.prototype.findAvatar = function(selector) {\n const rootSelector = `.${AvatarWrapper.rootSelector}`;\n // casting to 'any' is needed to avoid this issue with generics\n // https://github.com/microsoft/TypeScript/issues/29132\n return (this as any).findComponent(selector ? appendSelector(selector, rootSelector) : rootSelector, AvatarWrapper);\n };\n\n ElementWrapper.prototype.findAllAvatars = function(selector) {\n return this.findAllComponents(AvatarWrapper, selector);\n };\n\n ElementWrapper.prototype.findChatBubble = function(selector) {\n const rootSelector = `.${ChatBubbleWrapper.rootSelector}`;\n // casting to 'any' is needed to avoid this issue with generics\n // https://github.com/microsoft/TypeScript/issues/29132\n return (this as any).findComponent(selector ? appendSelector(selector, rootSelector) : rootSelector, ChatBubbleWrapper);\n };\n\n ElementWrapper.prototype.findAllChatBubbles = function(selector) {\n return this.findAllComponents(ChatBubbleWrapper, selector);\n };\n\n ElementWrapper.prototype.findLoadingBar = function(selector) {\n const rootSelector = `.${LoadingBarWrapper.rootSelector}`;\n // casting to 'any' is needed to avoid this issue with generics\n // https://github.com/microsoft/TypeScript/issues/29132\n return (this as any).findComponent(selector ? appendSelector(selector, rootSelector) : rootSelector, LoadingBarWrapper);\n };\n\n ElementWrapper.prototype.findAllLoadingBars = function(selector) {\n return this.findAllComponents(LoadingBarWrapper, selector);\n };\nexport default function wrapper(root: Element = document.body) { if (document && document.body && !document.body.contains(root)) { console.warn('[AwsUi] [test-utils] provided element is not part of the document body, interactions may work incorrectly')}; return new ElementWrapper(root); }"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/test-utils/dom/index.ts"],"names":[],"mappings":";;;AACA,qEAAqE;AACrE,sCAAsC;AACtC,gEAAwE;AAG/D,+FAHA,oBAAc,OAGA;AAFvB,oEAA0E;AAI1E,qCAAqC;AAK5B,wBALF,gBAAa,CAKE;AAJtB,+CAA8C;AAKrC,4BALF,qBAAiB,CAKE;AAJ1B,+CAA8C;AAKrC,4BALF,qBAAiB,CAKE;AAkE1B,oBAAc,CAAC,SAAS,CAAC,UAAU,GAAG,UAAS,QAAQ;IACrD,MAAM,YAAY,GAAG,IAAI,gBAAa,CAAC,YAAY,EAAE,CAAC;IACtD,+DAA+D;IAC/D,uDAAuD;IACvD,OAAQ,IAAY,CAAC,aAAa,CAAC,QAAQ,CAAC,CAAC,CAAC,IAAA,sBAAc,EAAC,QAAQ,EAAE,YAAY,CAAC,CAAC,CAAC,CAAC,YAAY,EAAE,gBAAa,CAAC,CAAC;AACtH,CAAC,CAAC;AAEF,oBAAc,CAAC,SAAS,CAAC,cAAc,GAAG,UAAS,QAAQ;IACzD,OAAO,IAAI,CAAC,iBAAiB,CAAC,gBAAa,EAAE,QAAQ,CAAC,CAAC;AACzD,CAAC,CAAC;AACF,oBAAc,CAAC,SAAS,CAAC,cAAc,GAAG,UAAS,QAAQ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azon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport { ElementWrapper } from '@cloudscape-design/test-utils-core/dom';\nimport { appendSelector } from '@cloudscape-design/test-utils-core/utils';\n\nexport { ElementWrapper };\n\nimport AvatarWrapper from './avatar';\nimport ChatBubbleWrapper from './chat-bubble';\nimport LoadingBarWrapper from './loading-bar';\n\n\nexport { AvatarWrapper };\nexport { ChatBubbleWrapper };\nexport { LoadingBarWrapper };\n\ndeclare module '@cloudscape-design/test-utils-core/dist/dom' {\n interface ElementWrapper {\n \n/**\n * Returns the wrapper of the first Avatar that matches the specified CSS selector.\n * If no CSS selector is specified, returns the wrapper of the first Avatar.\n * If no matching Avatar is found, returns `null`.\n *\n * @param {string} [selector] CSS Selector\n * @returns {AvatarWrapper | null}\n */\nfindAvatar(selector?: string): AvatarWrapper | null;\n\n/**\n * Returns an array of Avatar wrapper that matches the specified CSS selector.\n * If no CSS selector is specified, returns all of the Avatars inside the current wrapper.\n * If no matching Avatar is found, returns an empty array.\n *\n * @param {string} [selector] CSS Selector\n * @returns {Array<AvatarWrapper>}\n */\nfindAllAvatars(selector?: string): Array<AvatarWrapper>;\n/**\n * Returns the wrapper of the first ChatBubble that matches the specified CSS selector.\n * If no CSS selector is specified, returns the wrapper of the first ChatBubble.\n * If no matching ChatBubble is found, returns `null`.\n *\n * @param {string} [selector] CSS Selector\n * @returns {ChatBubbleWrapper | null}\n */\nfindChatBubble(selector?: string): ChatBubbleWrapper | null;\n\n/**\n * Returns an array of ChatBubble wrapper that matches the specified CSS selector.\n * If no CSS selector is specified, returns all of the ChatBubbles inside the current wrapper.\n * If no matching ChatBubble is found, returns an empty array.\n *\n * @param {string} [selector] CSS Selector\n * @returns {Array<ChatBubbleWrapper>}\n */\nfindAllChatBubbles(selector?: string): Array<ChatBubbleWrapper>;\n/**\n * Returns the wrapper of the first LoadingBar that matches the specified CSS selector.\n * If no CSS selector is specified, returns the wrapper of the first LoadingBar.\n * If no matching LoadingBar is found, returns `null`.\n *\n * @param {string} [selector] CSS Selector\n * @returns {LoadingBarWrapper | null}\n */\nfindLoadingBar(selector?: string): LoadingBarWrapper | null;\n\n/**\n * Returns an array of LoadingBar wrapper that matches the specified CSS selector.\n * If no CSS selector is specified, returns all of the LoadingBars inside the current wrapper.\n * If no matching LoadingBar is found, returns an empty array.\n *\n * @param {string} [selector] CSS Selector\n * @returns {Array<LoadingBarWrapper>}\n */\nfindAllLoadingBars(selector?: string): Array<LoadingBarWrapper>;\n }\n}\n\n\nElementWrapper.prototype.findAvatar = function(selector) {\n const rootSelector = `.${AvatarWrapper.rootSelector}`;\n // casting to 'any' is needed to avoid this issue with generics\n // https://github.com/microsoft/TypeScript/issues/29132\n return (this as any).findComponent(selector ? appendSelector(selector, rootSelector) : rootSelector, AvatarWrapper);\n};\n\nElementWrapper.prototype.findAllAvatars = function(selector) {\n return this.findAllComponents(AvatarWrapper, selector);\n};\nElementWrapper.prototype.findChatBubble = function(selector) {\n const rootSelector = `.${ChatBubbleWrapper.rootSelector}`;\n // casting to 'any' is needed to avoid this issue with generics\n // https://github.com/microsoft/TypeScript/issues/29132\n return (this as any).findComponent(selector ? appendSelector(selector, rootSelector) : rootSelector, ChatBubbleWrapper);\n};\n\nElementWrapper.prototype.findAllChatBubbles = function(selector) {\n return this.findAllComponents(ChatBubbleWrapper, selector);\n};\nElementWrapper.prototype.findLoadingBar = function(selector) {\n const rootSelector = `.${LoadingBarWrapper.rootSelector}`;\n // casting to 'any' is needed to avoid this issue with generics\n // https://github.com/microsoft/TypeScript/issues/29132\n return (this as any).findComponent(selector ? appendSelector(selector, rootSelector) : rootSelector, LoadingBarWrapper);\n};\n\nElementWrapper.prototype.findAllLoadingBars = function(selector) {\n return this.findAllComponents(LoadingBarWrapper, selector);\n};\n\n\nexport default function wrapper(root: Element = document.body) {\n if (document && document.body && !document.body.contains(root)) {\n console.warn('[AwsUi] [test-utils] provided element is not part of the document body, interactions may work incorrectly')\n };\n return new ElementWrapper(root);\n}\n"]}
@@ -1,11 +1,10 @@
1
1
  import { ElementWrapper } from '@cloudscape-design/test-utils-core/selectors';
2
- import '@cloudscape-design/components/test-utils/selectors';
3
2
  export { ElementWrapper };
4
3
  import AvatarWrapper from './avatar';
5
- export { AvatarWrapper };
6
4
  import ChatBubbleWrapper from './chat-bubble';
7
- export { ChatBubbleWrapper };
8
5
  import LoadingBarWrapper from './loading-bar';
6
+ export { AvatarWrapper };
7
+ export { ChatBubbleWrapper };
9
8
  export { LoadingBarWrapper };
10
9
  declare module '@cloudscape-design/test-utils-core/dist/selectors' {
11
10
  interface ElementWrapper {
@@ -1,9 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.LoadingBarWrapper = exports.ChatBubbleWrapper = exports.AvatarWrapper = exports.ElementWrapper = void 0;
4
+ // Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
5
+ // SPDX-License-Identifier: Apache-2.0
4
6
  const selectors_1 = require("@cloudscape-design/test-utils-core/selectors");
5
7
  Object.defineProperty(exports, "ElementWrapper", { enumerable: true, get: function () { return selectors_1.ElementWrapper; } });
6
- require("@cloudscape-design/components/test-utils/selectors");
7
8
  const utils_1 = require("@cloudscape-design/test-utils-core/utils");
8
9
  const avatar_1 = require("./avatar");
9
10
  exports.AvatarWrapper = avatar_1.default;
@@ -38,6 +39,8 @@ selectors_1.ElementWrapper.prototype.findLoadingBar = function (selector) {
38
39
  selectors_1.ElementWrapper.prototype.findAllLoadingBars = function (selector) {
39
40
  return this.findAllComponents(loading_bar_1.default, selector);
40
41
  };
41
- function wrapper(root = 'body') { return new selectors_1.ElementWrapper(root); }
42
+ function wrapper(root = 'body') {
43
+ return new selectors_1.ElementWrapper(root);
44
+ }
42
45
  exports.default = wrapper;
43
46
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/test-utils/selectors/index.ts"],"names":[],"mappings":";;;AAAA,4E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CAAC,YAAY,EAAE,CAAC;IAC1D,+DAA+D;IAC/D,uDAAuD;IACvD,OAAQ,IAAY,CAAC,aAAa,CAAC,QAAQ,CAAC,CAAC,CAAC,IAAA,sBAAc,EAAC,QAAQ,EAAE,YAAY,CAAC,CAAC,CAAC,CAAC,YAAY,EAAE,qBAAiB,CAAC,CAAC;AAC1H,CAAC,CAAC;AAEF,0BAAc,CAAC,SAAS,CAAC,kBAAkB,GAAG,UAAS,QAAQ;IAC7D,OAAO,IAAI,CAAC,iBAAiB,CAAC,qBAAiB,EAAE,QAAQ,CAAC,CAAC;AAC7D,CAAC,CAAC;AACR,SAAwB,OAAO,CAAC,OAAe,MAAM,IAAI,OAAO,IAAI,0BAAc,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAA3F,0BAA2F","sourcesContent":["import { ElementWrapper } from '@cloudscape-design/test-utils-core/selectors';\nimport '@cloudscape-design/components/test-utils/selectors';\nimport { appendSelector } from '@cloudscape-design/test-utils-core/utils';\nexport { ElementWrapper };\n\n import AvatarWrapper from './avatar';\n export { AvatarWrapper };\n \n\n import ChatBubbleWrapper from './chat-bubble';\n export { ChatBubbleWrapper };\n \n\n import LoadingBarWrapper from './loading-bar';\n export { LoadingBarWrapper };\n \ndeclare module '@cloudscape-design/test-utils-core/dist/selectors' {\n interface ElementWrapper {\n \n /**\n * Returns a wrapper that matches the Avatars with the specified CSS selector.\n * If no CSS selector is specified, returns a wrapper that matches Avatars.\n *\n * @param {string} [selector] CSS Selector\n * @returns {AvatarWrapper}\n */\n findAvatar(selector?: string): AvatarWrapper;\n\n /**\n * Returns a multi-element wrapper that matches Avatars with the specified CSS selector.\n * If no CSS selector is specified, returns a multi-element wrapper that matches Avatars.\n *\n * @param {string} [selector] CSS Selector\n * @returns {MultiElementWrapper<AvatarWrapper>}\n */\n findAllAvatars(selector?: string): MultiElementWrapper<AvatarWrapper>;\n\n /**\n * Returns a wrapper that matches the ChatBubbles with the specified CSS selector.\n * If no CSS selector is specified, returns a wrapper that matches ChatBubbles.\n *\n * @param {string} [selector] CSS Selector\n * @returns {ChatBubbleWrapper}\n */\n findChatBubble(selector?: string): ChatBubbleWrapper;\n\n /**\n * Returns a multi-element wrapper that matches ChatBubbles with the specified CSS selector.\n * If no CSS selector is specified, returns a multi-element wrapper that matches ChatBubbles.\n *\n * @param {string} [selector] CSS Selector\n * @returns {MultiElementWrapper<ChatBubbleWrapper>}\n */\n findAllChatBubbles(selector?: string): MultiElementWrapper<ChatBubbleWrapper>;\n\n /**\n * Returns a wrapper that matches the LoadingBars with the specified CSS selector.\n * If no CSS selector is specified, returns a wrapper that matches LoadingBars.\n *\n * @param {string} [selector] CSS Selector\n * @returns {LoadingBarWrapper}\n */\n findLoadingBar(selector?: string): LoadingBarWrapper;\n\n /**\n * Returns a multi-element wrapper that matches LoadingBars with the specified CSS selector.\n * If no CSS selector is specified, returns a multi-element wrapper that matches LoadingBars.\n *\n * @param {string} [selector] CSS Selector\n * @returns {MultiElementWrapper<LoadingBarWrapper>}\n */\n findAllLoadingBars(selector?: string): MultiElementWrapper<LoadingBarWrapper>;\n }\n }\n\n ElementWrapper.prototype.findAvatar = function(selector) {\n const rootSelector = `.${AvatarWrapper.rootSelector}`;\n // casting to 'any' is needed to avoid this issue with generics\n // https://github.com/microsoft/TypeScript/issues/29132\n return (this as any).findComponent(selector ? appendSelector(selector, rootSelector) : rootSelector, AvatarWrapper);\n };\n\n ElementWrapper.prototype.findAllAvatars = function(selector) {\n return this.findAllComponents(AvatarWrapper, selector);\n };\n\n ElementWrapper.prototype.findChatBubble = function(selector) {\n const rootSelector = `.${ChatBubbleWrapper.rootSelector}`;\n // casting to 'any' is needed to avoid this issue with generics\n // https://github.com/microsoft/TypeScript/issues/29132\n return (this as any).findComponent(selector ? appendSelector(selector, rootSelector) : rootSelector, ChatBubbleWrapper);\n };\n\n ElementWrapper.prototype.findAllChatBubbles = function(selector) {\n return this.findAllComponents(ChatBubbleWrapper, selector);\n };\n\n ElementWrapper.prototype.findLoadingBar = function(selector) {\n const rootSelector = `.${LoadingBarWrapper.rootSelector}`;\n // casting to 'any' is needed to avoid this issue with generics\n // https://github.com/microsoft/TypeScript/issues/29132\n return (this as any).findComponent(selector ? appendSelector(selector, rootSelector) : rootSelector, LoadingBarWrapper);\n };\n\n ElementWrapper.prototype.findAllLoadingBars = function(selector) {\n return this.findAllComponents(LoadingBarWrapper, selector);\n };\nexport default function wrapper(root: string = 'body') { return new ElementWrapper(root); }"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/test-utils/selectors/index.ts"],"names":[],"mappings":";;;AACA,qEAAqE;AACrE,sCAAsC;AACtC,4EAA8E;AAGrE,+FAHA,0BAAc,OAGA;AAFvB,oEAA0E;AAI1E,qCAAqC;AAK5B,wBALF,gBAAa,CAKE;AAJtB,+CAA8C;AAKrC,4BALF,qBAAiB,CAKE;AAJ1B,+CAA8C;AAKrC,4BALF,qBAAiB,CAKE;AA4D1B,0BAAc,CAAC,SAAS,CAAC,UAAU,GAAG,UAAS,QAAQ;IACrD,MAAM,YAAY,GAAG,IAAI,gBAAa,CAAC,YAAY,EAAE,CAAC;IACtD,+DAA+D;IAC/D,uDAAuD;IACvD,OAAQ,IAAY,CAAC,aAAa,CAAC,QAAQ,CAAC,CAAC,CAAC,IAAA,sBAAc,EAAC,QAAQ,EAAE,YAAY,CAAC,CAAC,CAAC,CAAC,YAAY,EAAE,gBAAa,CAAC,CAAC;AACtH,CAAC,CAAC;AAEF,0BAAc,CAAC,SAAS,CAAC,cAAc,GAAG,UAAS,QAAQ;IACzD,OAAO,IAAI,CAAC,iBAAiB,CAAC,gBAAa,EAAE,QAAQ,CAAC,CAAC;AACzD,CAAC,CAAC;AACF,0BAAc,CAAC,SAAS,CAAC,cAAc,GAAG,UAAS,QAAQ;IACzD,MAAM,YAAY,GAAG,IAAI,qBAAiB,CAAC,YAAY,EAAE,CAAC;IAC1D,+DAA+D;IAC/D,uDAAuD;IACvD,OAAQ,IAAY,CAAC,aAAa,CAAC,QAAQ,CAAC,CAAC,CAAC,IAAA,sBAAc,EAAC,QAAQ,EAAE,YAAY,CAAC,CAAC,CAAC,CAAC,YAAY,EAAE,qBAAiB,CAAC,CAAC;AAC1H,CAAC,CAAC;AAEF,0BAAc,CAAC,SAAS,CAAC,kBAAkB,GAAG,UAAS,QAAQ;IAC7D,OAAO,IAAI,CAAC,iBAAiB,CAAC,qBAAiB,EAAE,QAAQ,CAAC,CAAC;AAC7D,CAAC,CAAC;AACF,0BAAc,CAAC,SAAS,CAAC,cAAc,GAAG,UAAS,QAAQ;IACzD,MAAM,YAAY,GAAG,IAAI,qBAAiB,CAAC,YAAY,EAAE,CAAC;IAC1D,+DAA+D;IAC/D,uDAAuD;IACvD,OAAQ,IAAY,CAAC,aAAa,CAAC,QAAQ,CAAC,CAAC,CAAC,IAAA,sBAAc,EAAC,QAAQ,EAAE,YAAY,CAAC,CAAC,CAAC,CAAC,YAAY,EAAE,qBAAiB,CAAC,CAAC;AAC1H,CAAC,CAAC;AAEF,0BAAc,CAAC,SAAS,CAAC,kBAAkB,GAAG,UAAS,QAAQ;IAC7D,OAAO,IAAI,CAAC,iBAAiB,CAAC,qBAAiB,EAAE,QAAQ,CAAC,CAAC;AAC7D,CAAC,CAAC;AAGF,SAAwB,OAAO,CAAC,OAAe,MAAM;IACnD,OAAO,IAAI,0BAAc,CAAC,IAAI,CAAC,CAAC;AAClC,CAAC;AAFD,0BAEC","sourcesContent":["\n// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport { ElementWrapper } from '@cloudscape-design/test-utils-core/selectors';\nimport { appendSelector } from '@cloudscape-design/test-utils-core/utils';\n\nexport { ElementWrapper };\n\nimport AvatarWrapper from './avatar';\nimport ChatBubbleWrapper from './chat-bubble';\nimport LoadingBarWrapper from './loading-bar';\n\n\nexport { AvatarWrapper };\nexport { ChatBubbleWrapper };\nexport { LoadingBarWrapper };\n\ndeclare module '@cloudscape-design/test-utils-core/dist/selectors' {\n interface ElementWrapper {\n \n/**\n * Returns a wrapper that matches the Avatars with the specified CSS selector.\n * If no CSS selector is specified, returns a wrapper that matches Avatars.\n *\n * @param {string} [selector] CSS Selector\n * @returns {AvatarWrapper}\n */\nfindAvatar(selector?: string): AvatarWrapper;\n\n/**\n * Returns a multi-element wrapper that matches Avatars with the specified CSS selector.\n * If no CSS selector is specified, returns a multi-element wrapper that matches Avatars.\n *\n * @param {string} [selector] CSS Selector\n * @returns {MultiElementWrapper<AvatarWrapper>}\n */\nfindAllAvatars(selector?: string): MultiElementWrapper<AvatarWrapper>;\n/**\n * Returns a wrapper that matches the ChatBubbles with the specified CSS selector.\n * If no CSS selector is specified, returns a wrapper that matches ChatBubbles.\n *\n * @param {string} [selector] CSS Selector\n * @returns {ChatBubbleWrapper}\n */\nfindChatBubble(selector?: string): ChatBubbleWrapper;\n\n/**\n * Returns a multi-element wrapper that matches ChatBubbles with the specified CSS selector.\n * If no CSS selector is specified, returns a multi-element wrapper that matches ChatBubbles.\n *\n * @param {string} [selector] CSS Selector\n * @returns {MultiElementWrapper<ChatBubbleWrapper>}\n */\nfindAllChatBubbles(selector?: string): MultiElementWrapper<ChatBubbleWrapper>;\n/**\n * Returns a wrapper that matches the LoadingBars with the specified CSS selector.\n * If no CSS selector is specified, returns a wrapper that matches LoadingBars.\n *\n * @param {string} [selector] CSS Selector\n * @returns {LoadingBarWrapper}\n */\nfindLoadingBar(selector?: string): LoadingBarWrapper;\n\n/**\n * Returns a multi-element wrapper that matches LoadingBars with the specified CSS selector.\n * If no CSS selector is specified, returns a multi-element wrapper that matches LoadingBars.\n *\n * @param {string} [selector] CSS Selector\n * @returns {MultiElementWrapper<LoadingBarWrapper>}\n */\nfindAllLoadingBars(selector?: string): MultiElementWrapper<LoadingBarWrapper>;\n }\n}\n\n\nElementWrapper.prototype.findAvatar = function(selector) {\n const rootSelector = `.${AvatarWrapper.rootSelector}`;\n // casting to 'any' is needed to avoid this issue with generics\n // https://github.com/microsoft/TypeScript/issues/29132\n return (this as any).findComponent(selector ? appendSelector(selector, rootSelector) : rootSelector, AvatarWrapper);\n};\n\nElementWrapper.prototype.findAllAvatars = function(selector) {\n return this.findAllComponents(AvatarWrapper, selector);\n};\nElementWrapper.prototype.findChatBubble = function(selector) {\n const rootSelector = `.${ChatBubbleWrapper.rootSelector}`;\n // casting to 'any' is needed to avoid this issue with generics\n // https://github.com/microsoft/TypeScript/issues/29132\n return (this as any).findComponent(selector ? appendSelector(selector, rootSelector) : rootSelector, ChatBubbleWrapper);\n};\n\nElementWrapper.prototype.findAllChatBubbles = function(selector) {\n return this.findAllComponents(ChatBubbleWrapper, selector);\n};\nElementWrapper.prototype.findLoadingBar = function(selector) {\n const rootSelector = `.${LoadingBarWrapper.rootSelector}`;\n // casting to 'any' is needed to avoid this issue with generics\n // https://github.com/microsoft/TypeScript/issues/29132\n return (this as any).findComponent(selector ? appendSelector(selector, rootSelector) : rootSelector, LoadingBarWrapper);\n};\n\nElementWrapper.prototype.findAllLoadingBars = function(selector) {\n return this.findAllComponents(LoadingBarWrapper, selector);\n};\n\n\nexport default function wrapper(root: string = 'body') {\n return new ElementWrapper(root);\n}\n"]}