@sap_oss/wdio-qmate-service 2.9.8 → 2.10.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.
- package/CONTRIBUTING.md +34 -0
- package/docs/doc.md +417 -1
- package/lib/index.js +5 -2
- package/lib/index.js.map +1 -1
- package/lib/reuse/helper/elementResolving.js +1 -2
- package/lib/reuse/helper/elementResolving.js.map +1 -1
- package/lib/reuse/helper/inputValidation.js +1 -2
- package/lib/reuse/helper/inputValidation.js.map +1 -1
- package/lib/reuse/index.js +17 -0
- package/lib/reuse/index.js.map +1 -1
- package/lib/reuse/modules/mobile/Mobile.d.ts +16 -0
- package/lib/reuse/modules/mobile/Mobile.js +25 -0
- package/lib/reuse/modules/mobile/Mobile.js.map +1 -0
- package/lib/reuse/modules/mobile/android.d.ts +29 -0
- package/lib/reuse/modules/mobile/android.js +84 -0
- package/lib/reuse/modules/mobile/android.js.map +1 -0
- package/lib/reuse/modules/mobile/device.d.ts +29 -0
- package/lib/reuse/modules/mobile/device.js +63 -0
- package/lib/reuse/modules/mobile/device.js.map +1 -0
- package/lib/reuse/modules/mobile/element.d.ts +76 -0
- package/lib/reuse/modules/mobile/element.js +132 -0
- package/lib/reuse/modules/mobile/element.js.map +1 -0
- package/lib/reuse/modules/mobile/gestures.d.ts +22 -0
- package/lib/reuse/modules/mobile/gestures.js +46 -0
- package/lib/reuse/modules/mobile/gestures.js.map +1 -0
- package/lib/reuse/modules/mobile/ios.d.ts +10 -0
- package/lib/reuse/modules/mobile/ios.js +21 -0
- package/lib/reuse/modules/mobile/ios.js.map +1 -0
- package/lib/reuse/modules/mobile/userInteraction.d.ts +28 -0
- package/lib/reuse/modules/mobile/userInteraction.js +75 -0
- package/lib/reuse/modules/mobile/userInteraction.js.map +1 -0
- package/lib/reuse/modules/util/Util.d.ts +1 -1
- package/lib/reuse/modules/util/browser.d.ts +24 -0
- package/lib/reuse/modules/util/browser.js +36 -0
- package/lib/reuse/modules/util/browser.js.map +1 -1
- package/lib/reuse/modules/util/data.d.ts +2 -2
- package/lib/reuse/modules/util/data.js +1 -1
- package/lib/reuse/modules/util/data.js.map +1 -1
- package/lib/reuse/modules/util/file.d.ts +0 -1
- package/lib/reuse/runner/runner.js +1 -2
- package/lib/reuse/runner/runner.js.map +1 -1
- package/lib/scripts/dataExchange/dataExchange.js +48 -31
- package/lib/scripts/dataExchange/dataExchange.js.map +1 -1
- package/lib/scripts/dataExchange/dataExchangeUtil.d.ts +3 -3
- package/lib/scripts/dataExchange/dataExchangeUtil.js +10 -10
- package/lib/scripts/dataExchange/dataExchangeUtil.js.map +1 -1
- package/lib/scripts/hooks/after.js +1 -1
- package/lib/scripts/hooks/after.js.map +1 -1
- package/lib/scripts/hooks/before.js +1 -1
- package/lib/scripts/hooks/before.js.map +1 -1
- package/lib/scripts/hooks/beforeSession.js +2 -2
- package/lib/scripts/hooks/beforeSession.js.map +1 -1
- package/lib/scripts/hooks/onComplete.js +1 -1
- package/lib/scripts/hooks/onComplete.js.map +1 -1
- package/lib/scripts/hooks/onPrepare.js +1 -1
- package/lib/scripts/hooks/onPrepare.js.map +1 -1
- package/lib/scripts/hooks/utils/isBrowserDefined.d.ts +1 -0
- package/lib/scripts/hooks/utils/isBrowserDefined.js +7 -0
- package/lib/scripts/hooks/utils/isBrowserDefined.js.map +1 -0
- package/package.json +11 -4
- package/test/helper/configurations/mobile.conf.js +16 -0
- package/test/watchMode/config.js +18 -0
- package/test/watchMode/navigateToUrlAndClick.spec.js +16 -0
package/CONTRIBUTING.md
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
# Contributing to an SAP Open Source Project
|
|
2
|
+
|
|
3
|
+
## General Remarks
|
|
4
|
+
|
|
5
|
+
You are welcome to contribute content (code, documentation etc.) to this open source project.
|
|
6
|
+
|
|
7
|
+
There are some important things to know:
|
|
8
|
+
|
|
9
|
+
1. You must **comply to the license of this project**, **accept the Developer Certificate of Origin** (see below) before being able to contribute. The acknowledgement to the DCO will usually be requested from you as part of your first pull request to this project.
|
|
10
|
+
2. Please **adhere to our [Code of Conduct](CODE_OF_CONDUCT.md)**.
|
|
11
|
+
3. If you plan to use **generative AI for your contribution**, please see our guideline below.
|
|
12
|
+
4. **Not all proposed contributions can be accepted**. Some features may fit another project better or doesn't fit the general direction of this project. Of course, this doesn't apply to most bug fixes, but a major feature implementation for instance needs to be discussed with one of the maintainers first. Possibly, one who touched the related code or module recently. The more effort you invest, the better you should clarify in advance whether the contribution will match the project's direction. The best way would be to just open an issue to discuss the feature you plan to implement (make it clear that you intend to contribute). We will then forward the proposal to the respective code owner. This avoids disappointment.
|
|
13
|
+
|
|
14
|
+
## Developer Certificate of Origin (DCO)
|
|
15
|
+
|
|
16
|
+
Contributors will be asked to accept a DCO before they submit the first pull request to this projects, this happens in an automated fashion during the submission process. SAP uses [the standard DCO text of the Linux Foundation](https://developercertificate.org/).
|
|
17
|
+
|
|
18
|
+
## Contributing with AI-generated code
|
|
19
|
+
|
|
20
|
+
As artificial intelligence evolves, AI-generated code is becoming valuable for many software projects, including open-source initiatives. While we recognize the potential benefits of incorporating AI-generated content into our open-source projects there a certain requirements that need to be reflected and adhered to when making contributions.
|
|
21
|
+
|
|
22
|
+
Please see our [guideline for AI-generated code contributions to SAP Open Source Software Projects](CONTRIBUTING_USING_GENAI.md) for these requirements.
|
|
23
|
+
|
|
24
|
+
## How to Contribute
|
|
25
|
+
|
|
26
|
+
1. Make sure the change is welcome (see [General Remarks](#general-remarks)).
|
|
27
|
+
2. Create a branch by forking the repository and apply your change.
|
|
28
|
+
3. Commit and push your change on that branch.
|
|
29
|
+
4. Create a pull request in the repository using this branch.
|
|
30
|
+
5. Follow the link posted by the CLA assistant to your pull request and accept it, as described above.
|
|
31
|
+
6. Wait for our code review and approval, possibly enhancing your change on request.
|
|
32
|
+
- Note that the maintainers have many duties. So, depending on the required effort for reviewing, testing, and clarification, this may take a while.
|
|
33
|
+
7. Once the change has been approved and merged, we will inform you in a comment.
|
|
34
|
+
8. Celebrate!
|
package/docs/doc.md
CHANGED
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
<dt><a href="#service">service</a></dt>
|
|
17
17
|
<dd><p>Global namespace for service modules.</p>
|
|
18
18
|
</dd>
|
|
19
|
+
<dt><a href="#mobile">mobile</a></dt>
|
|
20
|
+
<dd><p>Global namespace for mobile modules.</p>
|
|
21
|
+
</dd>
|
|
19
22
|
</dl>
|
|
20
23
|
|
|
21
24
|
<a name="common"></a>
|
|
@@ -571,6 +574,9 @@ Global namespace for util modules.
|
|
|
571
574
|
* [.log(message)](#util.browser.log)
|
|
572
575
|
* [.warn(message)](#util.browser.warn)
|
|
573
576
|
* [.error(message)](#util.browser.error)
|
|
577
|
+
* [.isMobile()](#util.browser.isMobile) ⇒ <code>boolean</code>
|
|
578
|
+
* [.isAndroid()](#util.browser.isAndroid) ⇒ <code>boolean</code>
|
|
579
|
+
* [.isIos()](#util.browser.isIos) ⇒ <code>boolean</code>
|
|
574
580
|
* [.component](#util.component)
|
|
575
581
|
* [new component()](#new_util.component_new)
|
|
576
582
|
* [.loadEntryPoint([folderPath])](#util.component.loadEntryPoint) ⇒ <code>Object</code>
|
|
@@ -644,6 +650,9 @@ Global namespace for util modules.
|
|
|
644
650
|
* [.log(message)](#util.browser.log)
|
|
645
651
|
* [.warn(message)](#util.browser.warn)
|
|
646
652
|
* [.error(message)](#util.browser.error)
|
|
653
|
+
* [.isMobile()](#util.browser.isMobile) ⇒ <code>boolean</code>
|
|
654
|
+
* [.isAndroid()](#util.browser.isAndroid) ⇒ <code>boolean</code>
|
|
655
|
+
* [.isIos()](#util.browser.isIos) ⇒ <code>boolean</code>
|
|
647
656
|
|
|
648
657
|
<a name="util.browser.getBaseUrl"></a>
|
|
649
658
|
|
|
@@ -960,6 +969,39 @@ add error message to browser logs, can be viewed in the html report
|
|
|
960
969
|
```js
|
|
961
970
|
await util.browser.error("This is an error message");
|
|
962
971
|
```
|
|
972
|
+
<a name="util.browser.isMobile"></a>
|
|
973
|
+
|
|
974
|
+
#### browser.isMobile() ⇒ <code>boolean</code>
|
|
975
|
+
Indicates a mobile session
|
|
976
|
+
|
|
977
|
+
**Kind**: static method of [<code>browser</code>](#util.browser)
|
|
978
|
+
**Returns**: <code>boolean</code> - Return true if its a mobile session driver.
|
|
979
|
+
**Example**
|
|
980
|
+
```js
|
|
981
|
+
await util.browser.isMobile();
|
|
982
|
+
```
|
|
983
|
+
<a name="util.browser.isAndroid"></a>
|
|
984
|
+
|
|
985
|
+
#### browser.isAndroid() ⇒ <code>boolean</code>
|
|
986
|
+
Indicates a mobile session
|
|
987
|
+
|
|
988
|
+
**Kind**: static method of [<code>browser</code>](#util.browser)
|
|
989
|
+
**Returns**: <code>boolean</code> - Return true if its a Android session driver.
|
|
990
|
+
**Example**
|
|
991
|
+
```js
|
|
992
|
+
await util.browser.isAndroid();
|
|
993
|
+
```
|
|
994
|
+
<a name="util.browser.isIos"></a>
|
|
995
|
+
|
|
996
|
+
#### browser.isIos() ⇒ <code>boolean</code>
|
|
997
|
+
Indicates an iOS session
|
|
998
|
+
|
|
999
|
+
**Kind**: static method of [<code>browser</code>](#util.browser)
|
|
1000
|
+
**Returns**: <code>boolean</code> - Return true if its a iOS session driver.
|
|
1001
|
+
**Example**
|
|
1002
|
+
```js
|
|
1003
|
+
await util.browser.isIos();
|
|
1004
|
+
```
|
|
963
1005
|
<a name="util.component"></a>
|
|
964
1006
|
|
|
965
1007
|
### util.component
|
|
@@ -1185,7 +1227,7 @@ Decrypts the passed input data.
|
|
|
1185
1227
|
|
|
1186
1228
|
| Param | Type | Description |
|
|
1187
1229
|
| --- | --- | --- |
|
|
1188
|
-
| data | <code>String</code> | The encrypted data to decrypt. |
|
|
1230
|
+
| data | <code>String</code> \| <code>Array.<String></code> | The encrypted data to decrypt. Single value or array of values for different keys. |
|
|
1189
1231
|
|
|
1190
1232
|
**Example**
|
|
1191
1233
|
```js
|
|
@@ -5722,3 +5764,377 @@ const config = {
|
|
|
5722
5764
|
},
|
|
5723
5765
|
let res = await service.rest.put(`${browser.config.baseUrl}/posts/99`, payload, config);
|
|
5724
5766
|
```
|
|
5767
|
+
<a name="mobile"></a>
|
|
5768
|
+
|
|
5769
|
+
## mobile
|
|
5770
|
+
Global namespace for mobile modules.
|
|
5771
|
+
|
|
5772
|
+
**Kind**: global constant
|
|
5773
|
+
|
|
5774
|
+
* [mobile](#mobile)
|
|
5775
|
+
* [.android](#mobile.android)
|
|
5776
|
+
* [.pressKeyByName(keyName)](#mobile.android.pressKeyByName)
|
|
5777
|
+
* [.pressKeyByCode(keyCode)](#mobile.android.pressKeyByCode)
|
|
5778
|
+
* [.device](#mobile.device)
|
|
5779
|
+
* [.isAppInstalled(packageIdorBundleId)](#mobile.device.isAppInstalled) ⇒ <code>boolean</code>
|
|
5780
|
+
* [.installApp(appPath)](#mobile.device.installApp)
|
|
5781
|
+
* [.element](#mobile.element)
|
|
5782
|
+
* [.isVisible(element, [strict])](#mobile.element.isVisible) ⇒ <code>Boolean</code>
|
|
5783
|
+
* [.isPresent(elem)](#mobile.element.isPresent) ⇒ <code>Boolean</code>
|
|
5784
|
+
* [.waitToBePresent(selector, [timeout])](#mobile.element.waitToBePresent)
|
|
5785
|
+
* [.waitToBeVisible(selector, [timeout])](#mobile.element.waitToBeVisible)
|
|
5786
|
+
* [.waitToBeClickable(selector, [timeout])](#mobile.element.waitToBeClickable)
|
|
5787
|
+
* [.isSelected(elem)](#mobile.element.isSelected) ⇒ <code>boolean</code>
|
|
5788
|
+
* [.gestures](#mobile.gestures)
|
|
5789
|
+
* [.waitToBeClickable(startX, startY, endX, endY, duration)](#mobile.gestures.waitToBeClickable) ⇒ <code>Promise.<void></code>
|
|
5790
|
+
* [.ios](#mobile.ios)
|
|
5791
|
+
* [.userInteraction](#mobile.userInteraction)
|
|
5792
|
+
* [.tap(element, [timeout])](#mobile.userInteraction.tap)
|
|
5793
|
+
* [.check(element)](#mobile.userInteraction.check)
|
|
5794
|
+
|
|
5795
|
+
<a name="mobile.android"></a>
|
|
5796
|
+
|
|
5797
|
+
### mobile.android
|
|
5798
|
+
**Kind**: static class of [<code>mobile</code>](#mobile)
|
|
5799
|
+
|
|
5800
|
+
* [.android](#mobile.android)
|
|
5801
|
+
* [.pressKeyByName(keyName)](#mobile.android.pressKeyByName)
|
|
5802
|
+
* [.pressKeyByCode(keyCode)](#mobile.android.pressKeyByCode)
|
|
5803
|
+
|
|
5804
|
+
<a name="mobile.android.pressKeyByName"></a>
|
|
5805
|
+
|
|
5806
|
+
#### android.pressKeyByName(keyName)
|
|
5807
|
+
Simulate pressing a hardware key on the android device (e.g., back button, home button, etc.),
|
|
5808
|
+
|
|
5809
|
+
**Kind**: static method of [<code>android</code>](#mobile.android)
|
|
5810
|
+
|
|
5811
|
+
| Param | Type | Description |
|
|
5812
|
+
| --- | --- | --- |
|
|
5813
|
+
| keyName | <code>string</code> | The name of the key (e.g., "back", "home", "volumeUp", etc.) |
|
|
5814
|
+
|
|
5815
|
+
**Example**
|
|
5816
|
+
```js
|
|
5817
|
+
await mobile.device.pressKeyByName("back");
|
|
5818
|
+
```
|
|
5819
|
+
**Example**
|
|
5820
|
+
```js
|
|
5821
|
+
await mobile.device.pressKeyByName("home");
|
|
5822
|
+
```
|
|
5823
|
+
**Example**
|
|
5824
|
+
```js
|
|
5825
|
+
await mobile.device.pressKeyByName("volumeUp");
|
|
5826
|
+
```
|
|
5827
|
+
**Example**
|
|
5828
|
+
```js
|
|
5829
|
+
await mobile.device.pressKeyByName("volumeDown");
|
|
5830
|
+
```
|
|
5831
|
+
**Example**
|
|
5832
|
+
```js
|
|
5833
|
+
await mobile.device.pressKeyByName("volumeMute");
|
|
5834
|
+
```
|
|
5835
|
+
**Example**
|
|
5836
|
+
```js
|
|
5837
|
+
await mobile.device.pressKeyByName("power");
|
|
5838
|
+
```
|
|
5839
|
+
**Example**
|
|
5840
|
+
```js
|
|
5841
|
+
await mobile.device.pressKeyByName("enter");
|
|
5842
|
+
```
|
|
5843
|
+
**Example**
|
|
5844
|
+
```js
|
|
5845
|
+
await mobile.device.pressKeyByName("space");
|
|
5846
|
+
```
|
|
5847
|
+
**Example**
|
|
5848
|
+
```js
|
|
5849
|
+
await mobile.device.pressKeyByName("delete");
|
|
5850
|
+
```
|
|
5851
|
+
**Example**
|
|
5852
|
+
```js
|
|
5853
|
+
await mobile.device.pressKeyByName("menu");
|
|
5854
|
+
```
|
|
5855
|
+
**Example**
|
|
5856
|
+
```js
|
|
5857
|
+
await mobile.device.pressKeyByName("search");
|
|
5858
|
+
```
|
|
5859
|
+
**Example**
|
|
5860
|
+
```js
|
|
5861
|
+
await mobile.device.pressKeyByName("camera");
|
|
5862
|
+
```
|
|
5863
|
+
**Example**
|
|
5864
|
+
```js
|
|
5865
|
+
await mobile.device.pressKeyByName("focus");
|
|
5866
|
+
```
|
|
5867
|
+
**Example**
|
|
5868
|
+
```js
|
|
5869
|
+
await mobile.device.pressKeyByName("notification");
|
|
5870
|
+
```
|
|
5871
|
+
**Example**
|
|
5872
|
+
```js
|
|
5873
|
+
await mobile.device.pressKeyByName("call");
|
|
5874
|
+
```
|
|
5875
|
+
**Example**
|
|
5876
|
+
```js
|
|
5877
|
+
await mobile.device.pressKeyByName("calendar");
|
|
5878
|
+
```
|
|
5879
|
+
**Example**
|
|
5880
|
+
```js
|
|
5881
|
+
await mobile.device.pressKeyByName("recent");
|
|
5882
|
+
```
|
|
5883
|
+
**Example**
|
|
5884
|
+
```js
|
|
5885
|
+
await mobile.device.pressKeyByName("settings");
|
|
5886
|
+
```
|
|
5887
|
+
<a name="mobile.android.pressKeyByCode"></a>
|
|
5888
|
+
|
|
5889
|
+
#### android.pressKeyByCode(keyCode)
|
|
5890
|
+
Simulate pressing a hardware key on the android device (e.g., back button, home button, etc.),
|
|
5891
|
+
|
|
5892
|
+
**Kind**: static method of [<code>android</code>](#mobile.android)
|
|
5893
|
+
|
|
5894
|
+
| Param | Type | Description |
|
|
5895
|
+
| --- | --- | --- |
|
|
5896
|
+
| keyCode | <code>string</code> | The code of the key (e.g., 4 (back), 3 (home) , etc.) |
|
|
5897
|
+
|
|
5898
|
+
**Example**
|
|
5899
|
+
```js
|
|
5900
|
+
await mobile.android.pressKeyByCode(4);
|
|
5901
|
+
```
|
|
5902
|
+
<a name="mobile.device"></a>
|
|
5903
|
+
|
|
5904
|
+
### mobile.device
|
|
5905
|
+
**Kind**: static class of [<code>mobile</code>](#mobile)
|
|
5906
|
+
|
|
5907
|
+
* [.device](#mobile.device)
|
|
5908
|
+
* [.isAppInstalled(packageIdorBundleId)](#mobile.device.isAppInstalled) ⇒ <code>boolean</code>
|
|
5909
|
+
* [.installApp(appPath)](#mobile.device.installApp)
|
|
5910
|
+
|
|
5911
|
+
<a name="mobile.device.isAppInstalled"></a>
|
|
5912
|
+
|
|
5913
|
+
#### device.isAppInstalled(packageIdorBundleId) ⇒ <code>boolean</code>
|
|
5914
|
+
Check wether given package/bundle app is installed or not in the device.
|
|
5915
|
+
|
|
5916
|
+
**Kind**: static method of [<code>device</code>](#mobile.device)
|
|
5917
|
+
**Returns**: <code>boolean</code> - Returns true if specified app package/bundled installed in the device, or false.
|
|
5918
|
+
|
|
5919
|
+
| Param | Type | Description |
|
|
5920
|
+
| --- | --- | --- |
|
|
5921
|
+
| packageIdorBundleId | <code>string</code> | Android package Id, or iOS bundle Id. |
|
|
5922
|
+
|
|
5923
|
+
**Example**
|
|
5924
|
+
```js
|
|
5925
|
+
await mobile.device.isAppInstalled("com.google.android.apps.maps");
|
|
5926
|
+
```
|
|
5927
|
+
<a name="mobile.device.installApp"></a>
|
|
5928
|
+
|
|
5929
|
+
#### device.installApp(appPath)
|
|
5930
|
+
Install the appropriate app based on the platform the test is being executed on.
|
|
5931
|
+
|
|
5932
|
+
**Kind**: static method of [<code>device</code>](#mobile.device)
|
|
5933
|
+
|
|
5934
|
+
| Param | Type | Description |
|
|
5935
|
+
| --- | --- | --- |
|
|
5936
|
+
| appPath | <code>string</code> | Path of the app(.apk, .ipa) |
|
|
5937
|
+
|
|
5938
|
+
**Example**
|
|
5939
|
+
```js
|
|
5940
|
+
await mobile.device.installApp("/path/to/your/app.apk");
|
|
5941
|
+
await mobile.device.installApp("/path/to/your/app.ipa");
|
|
5942
|
+
```
|
|
5943
|
+
<a name="mobile.element"></a>
|
|
5944
|
+
|
|
5945
|
+
### mobile.element
|
|
5946
|
+
**Kind**: static class of [<code>mobile</code>](#mobile)
|
|
5947
|
+
|
|
5948
|
+
* [.element](#mobile.element)
|
|
5949
|
+
* [.isVisible(element, [strict])](#mobile.element.isVisible) ⇒ <code>Boolean</code>
|
|
5950
|
+
* [.isPresent(elem)](#mobile.element.isPresent) ⇒ <code>Boolean</code>
|
|
5951
|
+
* [.waitToBePresent(selector, [timeout])](#mobile.element.waitToBePresent)
|
|
5952
|
+
* [.waitToBeVisible(selector, [timeout])](#mobile.element.waitToBeVisible)
|
|
5953
|
+
* [.waitToBeClickable(selector, [timeout])](#mobile.element.waitToBeClickable)
|
|
5954
|
+
* [.isSelected(elem)](#mobile.element.isSelected) ⇒ <code>boolean</code>
|
|
5955
|
+
|
|
5956
|
+
<a name="mobile.element.isVisible"></a>
|
|
5957
|
+
|
|
5958
|
+
#### element.isVisible(element, [strict]) ⇒ <code>Boolean</code>
|
|
5959
|
+
Returns a boolean if the mobile element is visible to the user.
|
|
5960
|
+
|
|
5961
|
+
**Kind**: static method of [<code>element</code>](#mobile.element)
|
|
5962
|
+
**Returns**: <code>Boolean</code> - Returns true or false.
|
|
5963
|
+
|
|
5964
|
+
| Param | Type | Default | Description |
|
|
5965
|
+
| --- | --- | --- | --- |
|
|
5966
|
+
| element | <code>Object</code> | | The Mobile Ui element. |
|
|
5967
|
+
| [strict] | <code>Boolean</code> | <code>true</code> | If strict mode is enabled it will only return "true" if the element is visible on the mobile view and within the viewport. If "false", it will be sufficient if the element is visible on the view but not inside the current viewport. |
|
|
5968
|
+
|
|
5969
|
+
**Example**
|
|
5970
|
+
```js
|
|
5971
|
+
const elem = await mobile.element.isVisible("button01");
|
|
5972
|
+
await mobile.element.isVisible(elem);
|
|
5973
|
+
```
|
|
5974
|
+
<a name="mobile.element.isPresent"></a>
|
|
5975
|
+
|
|
5976
|
+
#### element.isPresent(elem) ⇒ <code>Boolean</code>
|
|
5977
|
+
Returns a boolean if the element is present at the DOM or not. It might be hidden.
|
|
5978
|
+
|
|
5979
|
+
**Kind**: static method of [<code>element</code>](#mobile.element)
|
|
5980
|
+
**Returns**: <code>Boolean</code> - Returns true or false.
|
|
5981
|
+
|
|
5982
|
+
| Param | Type | Description |
|
|
5983
|
+
| --- | --- | --- |
|
|
5984
|
+
| elem | <code>Object</code> | The element. |
|
|
5985
|
+
|
|
5986
|
+
**Example**
|
|
5987
|
+
```js
|
|
5988
|
+
await mobile.element.isPresent(elem);
|
|
5989
|
+
```
|
|
5990
|
+
<a name="mobile.element.waitToBePresent"></a>
|
|
5991
|
+
|
|
5992
|
+
#### element.waitToBePresent(selector, [timeout])
|
|
5993
|
+
Waits until the element with the given selector is present.
|
|
5994
|
+
|
|
5995
|
+
**Kind**: static method of [<code>element</code>](#mobile.element)
|
|
5996
|
+
|
|
5997
|
+
| Param | Type | Default | Description |
|
|
5998
|
+
| --- | --- | --- | --- |
|
|
5999
|
+
| selector | <code>Object</code> | | The CSS selector describing the element. |
|
|
6000
|
+
| [timeout] | <code>Number</code> | <code>30000</code> | The timeout to wait (ms). |
|
|
6001
|
+
|
|
6002
|
+
**Example**
|
|
6003
|
+
```js
|
|
6004
|
+
await mobile.element.waitToBePresent(".input01");
|
|
6005
|
+
```
|
|
6006
|
+
**Example**
|
|
6007
|
+
```js
|
|
6008
|
+
await mobile.element.waitToBePresent("#button12");
|
|
6009
|
+
```
|
|
6010
|
+
**Example**
|
|
6011
|
+
```js
|
|
6012
|
+
await mobile.element.waitToBePresent("p:first-child");
|
|
6013
|
+
```
|
|
6014
|
+
<a name="mobile.element.waitToBeVisible"></a>
|
|
6015
|
+
|
|
6016
|
+
#### element.waitToBeVisible(selector, [timeout])
|
|
6017
|
+
Waits until the element with the given selector is visible.
|
|
6018
|
+
|
|
6019
|
+
**Kind**: static method of [<code>element</code>](#mobile.element)
|
|
6020
|
+
|
|
6021
|
+
| Param | Type | Default | Description |
|
|
6022
|
+
| --- | --- | --- | --- |
|
|
6023
|
+
| selector | <code>Object</code> | | The CSS selector describing the element. |
|
|
6024
|
+
| [timeout] | <code>Number</code> | <code>30000</code> | The timeout to wait (ms). |
|
|
6025
|
+
|
|
6026
|
+
**Example**
|
|
6027
|
+
```js
|
|
6028
|
+
await mobile.element.waitToBeVisible(".input01");
|
|
6029
|
+
```
|
|
6030
|
+
**Example**
|
|
6031
|
+
```js
|
|
6032
|
+
await mobile.element.waitToBeVisible("#button12");
|
|
6033
|
+
```
|
|
6034
|
+
**Example**
|
|
6035
|
+
```js
|
|
6036
|
+
await mobile.element.waitToBeVisible("p:first-child");
|
|
6037
|
+
```
|
|
6038
|
+
<a name="mobile.element.waitToBeClickable"></a>
|
|
6039
|
+
|
|
6040
|
+
#### element.waitToBeClickable(selector, [timeout])
|
|
6041
|
+
Waits until the element with the given selector is clickable.
|
|
6042
|
+
|
|
6043
|
+
**Kind**: static method of [<code>element</code>](#mobile.element)
|
|
6044
|
+
|
|
6045
|
+
| Param | Type | Default | Description |
|
|
6046
|
+
| --- | --- | --- | --- |
|
|
6047
|
+
| selector | <code>Object</code> | | The CSS selector describing the element. |
|
|
6048
|
+
| [timeout] | <code>Number</code> | <code>30000</code> | The timeout to wait (ms). |
|
|
6049
|
+
|
|
6050
|
+
**Example**
|
|
6051
|
+
```js
|
|
6052
|
+
await mobile.element.waitToBeClickable(".input01");
|
|
6053
|
+
```
|
|
6054
|
+
**Example**
|
|
6055
|
+
```js
|
|
6056
|
+
await mobile.element.waitToBeClickable("#button12");
|
|
6057
|
+
```
|
|
6058
|
+
**Example**
|
|
6059
|
+
```js
|
|
6060
|
+
await mobile.element.waitToBeClickable("p:first-child");
|
|
6061
|
+
```
|
|
6062
|
+
<a name="mobile.element.isSelected"></a>
|
|
6063
|
+
|
|
6064
|
+
#### element.isSelected(elem) ⇒ <code>boolean</code>
|
|
6065
|
+
Returns a boolean if the element (e.g. checkbox) is selected.
|
|
6066
|
+
|
|
6067
|
+
**Kind**: static method of [<code>element</code>](#mobile.element)
|
|
6068
|
+
|
|
6069
|
+
| Param | Type | Description |
|
|
6070
|
+
| --- | --- | --- |
|
|
6071
|
+
| elem | <code>Object</code> | The element. |
|
|
6072
|
+
|
|
6073
|
+
**Example**
|
|
6074
|
+
```js
|
|
6075
|
+
const elem = await mobile.element.getById("elem01");
|
|
6076
|
+
const isSelected = await mobile.element.isSelected(elem);
|
|
6077
|
+
```
|
|
6078
|
+
<a name="mobile.gestures"></a>
|
|
6079
|
+
|
|
6080
|
+
### mobile.gestures
|
|
6081
|
+
**Kind**: static class of [<code>mobile</code>](#mobile)
|
|
6082
|
+
<a name="mobile.gestures.waitToBeClickable"></a>
|
|
6083
|
+
|
|
6084
|
+
#### gestures.waitToBeClickable(startX, startY, endX, endY, duration) ⇒ <code>Promise.<void></code>
|
|
6085
|
+
Swipe from one point to another on the screen.
|
|
6086
|
+
|
|
6087
|
+
**Kind**: static method of [<code>gestures</code>](#mobile.gestures)
|
|
6088
|
+
|
|
6089
|
+
| Param | Type | Description |
|
|
6090
|
+
| --- | --- | --- |
|
|
6091
|
+
| startX | <code>number</code> | The starting X coordinate of the swipe |
|
|
6092
|
+
| startY | <code>number</code> | The starting Y coordinate of the swipe |
|
|
6093
|
+
| endX | <code>number</code> | The ending X coordinate of the swipe |
|
|
6094
|
+
| endY | <code>number</code> | The ending Y coordinate of the swipe |
|
|
6095
|
+
| duration | <code>number</code> | The duration of the swipe in milliseconds (optional, default is 1000ms) |
|
|
6096
|
+
|
|
6097
|
+
<a name="mobile.ios"></a>
|
|
6098
|
+
|
|
6099
|
+
### mobile.ios
|
|
6100
|
+
**Kind**: static class of [<code>mobile</code>](#mobile)
|
|
6101
|
+
<a name="mobile.userInteraction"></a>
|
|
6102
|
+
|
|
6103
|
+
### mobile.userInteraction
|
|
6104
|
+
**Kind**: static class of [<code>mobile</code>](#mobile)
|
|
6105
|
+
|
|
6106
|
+
* [.userInteraction](#mobile.userInteraction)
|
|
6107
|
+
* [.tap(element, [timeout])](#mobile.userInteraction.tap)
|
|
6108
|
+
* [.check(element)](#mobile.userInteraction.check)
|
|
6109
|
+
|
|
6110
|
+
<a name="mobile.userInteraction.tap"></a>
|
|
6111
|
+
|
|
6112
|
+
#### userInteraction.tap(element, [timeout])
|
|
6113
|
+
Tap's on the mobile element.
|
|
6114
|
+
|
|
6115
|
+
**Kind**: static method of [<code>userInteraction</code>](#mobile.userInteraction)
|
|
6116
|
+
|
|
6117
|
+
| Param | Type | Default | Description |
|
|
6118
|
+
| --- | --- | --- | --- |
|
|
6119
|
+
| element | <code>Element</code> \| <code>string</code> | | The element or CSS selector describing the element. |
|
|
6120
|
+
| [timeout] | <code>Number</code> | <code>30000</code> | The timeout to wait (ms). |
|
|
6121
|
+
|
|
6122
|
+
**Example**
|
|
6123
|
+
```js
|
|
6124
|
+
const elem = await mobile.userInteraction.tap(elem);
|
|
6125
|
+
```
|
|
6126
|
+
<a name="mobile.userInteraction.check"></a>
|
|
6127
|
+
|
|
6128
|
+
#### userInteraction.check(element)
|
|
6129
|
+
Checks the given checkbox.
|
|
6130
|
+
|
|
6131
|
+
**Kind**: static method of [<code>userInteraction</code>](#mobile.userInteraction)
|
|
6132
|
+
|
|
6133
|
+
| Param | Type | Description |
|
|
6134
|
+
| --- | --- | --- |
|
|
6135
|
+
| element | <code>Element</code> | The element or CSS selector describing the element. |
|
|
6136
|
+
|
|
6137
|
+
**Example**
|
|
6138
|
+
```js
|
|
6139
|
+
await mobile.userInteraction.check(selector);
|
|
6140
|
+
```
|
package/lib/index.js
CHANGED
|
@@ -9,6 +9,7 @@ const before_1 = __importDefault(require("./scripts/hooks/before"));
|
|
|
9
9
|
const onPrepare_1 = __importDefault(require("./scripts/hooks/onPrepare"));
|
|
10
10
|
const onComplete_1 = __importDefault(require("./scripts/hooks/onComplete"));
|
|
11
11
|
const after_1 = __importDefault(require("./scripts/hooks/after"));
|
|
12
|
+
const isBrowserDefined_1 = require("./scripts/hooks/utils/isBrowserDefined");
|
|
12
13
|
const pj = require("../package.json");
|
|
13
14
|
module.exports = class CustomWorkerService {
|
|
14
15
|
/**
|
|
@@ -57,9 +58,11 @@ module.exports = class CustomWorkerService {
|
|
|
57
58
|
// @ts-ignore
|
|
58
59
|
async beforeSession(config, capabilities, specs) {
|
|
59
60
|
try {
|
|
60
|
-
|
|
61
|
+
if ((0, isBrowserDefined_1.isBrowserDefined)()) {
|
|
62
|
+
browser.config = config;
|
|
63
|
+
}
|
|
61
64
|
await (0, beforeSession_1.default)(config, capabilities, specs);
|
|
62
|
-
this.config =
|
|
65
|
+
this.config = config;
|
|
63
66
|
}
|
|
64
67
|
catch (e) {
|
|
65
68
|
if (specs && specs[0]) {
|
package/lib/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,+BAA+B;AAC/B,YAAY,CAAC;;;;;AAEb,kFAA+D;AAC/D,oEAAiD;AACjD,0EAAsD;AACtD,4EAAwD;AACxD,kEAA8C;AAC9C,MAAM,EAAE,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAAC;AAEtC,MAAM,CAAC,OAAO,GAAG,MAAM,mBAAmB;IAExC;;;;;;;;;OASG;IACH,aAAa;IACb,YAAY,cAAc,EAAE,YAAY,EAAE,MAAM;QAC9C,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;IAED;;;;OAIG;IACH,aAAa;IACb,KAAK,CAAC,SAAS,CAAC,MAAM,EAAE,YAAY;QAClC,MAAM,IAAI,GAAG;;;;;4BAKW,EAAE,CAAC,OAAO;OAC/B,CAAC;QACJ,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;QAClB,IAAI,CAAC;YACH,MAA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AAiB,EAAE,OAAY;QAC7E,IAAI,CAAC;YACH,MAAM,IAAA,oBAAc,EAAC,QAAQ,EAAE,MAAM,EAAE,YAAY,EAAE,OAAO,CAAC,CAAC;QAChE,CAAC;QAAC,OAAO,CAAC,EAAE,CAAC;YACX,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,2BAA2B,CAAC,EAAE,CAAC,CAAC;QACrD,CAAC;IACH,CAAC;CACF,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.resolveCssSelectorOrElement =
|
|
3
|
+
exports.resolveCssSelectorOrElement = resolveCssSelectorOrElement;
|
|
4
4
|
async function resolveCssSelectorOrElement(elementOrSelector) {
|
|
5
5
|
if (!elementOrSelector) {
|
|
6
6
|
throw new Error("Please provide an element or a CSS selector as first argument.");
|
|
@@ -12,5 +12,4 @@ async function resolveCssSelectorOrElement(elementOrSelector) {
|
|
|
12
12
|
return elementOrSelector;
|
|
13
13
|
}
|
|
14
14
|
}
|
|
15
|
-
exports.resolveCssSelectorOrElement = resolveCssSelectorOrElement;
|
|
16
15
|
//# sourceMappingURL=elementResolving.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"elementResolving.js","sourceRoot":"","sources":["../../../src/reuse/helper/elementResolving.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"elementResolving.js","sourceRoot":"","sources":["../../../src/reuse/helper/elementResolving.ts"],"names":[],"mappings":";;AAEA,kEAUC;AAVM,KAAK,UAAU,2BAA2B,CAAC,iBAAmC;IACnF,IAAI,CAAC,iBAAiB,EAAE,CAAC;QACvB,MAAM,IAAI,KAAK,CAAC,gEAAgE,CAAC,CAAC;IACpF,CAAC;IAED,IAAI,OAAO,iBAAiB,KAAK,QAAQ,EAAE,CAAC;QAC1C,OAAO,MAAM,MAAM,CAAC,OAAO,CAAC,QAAQ,CAAC,iBAAiB,CAAC,CAAC;IAC1D,CAAC;SAAM,CAAC;QACN,OAAO,iBAAiB,CAAC;IAC3B,CAAC;AACH,CAAC"}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.validateValue =
|
|
3
|
+
exports.validateValue = validateValue;
|
|
4
4
|
function validateValue(value) {
|
|
5
5
|
if (typeof value !== "string" && typeof value !== "number") {
|
|
6
6
|
throw new Error("value is invalid. It must be of type 'string' or 'number'");
|
|
7
7
|
}
|
|
8
8
|
}
|
|
9
|
-
exports.validateValue = validateValue;
|
|
10
9
|
//# sourceMappingURL=inputValidation.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inputValidation.js","sourceRoot":"","sources":["../../../src/reuse/helper/inputValidation.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"inputValidation.js","sourceRoot":"","sources":["../../../src/reuse/helper/inputValidation.ts"],"names":[],"mappings":";;AAAA,sCAIC;AAJD,SAAgB,aAAa,CAAC,KAAU;IACtC,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE,CAAC;QAC3D,MAAM,IAAI,KAAK,CAAC,2DAA2D,CAAC,CAAC;IAC/E,CAAC;AACH,CAAC"}
|
package/lib/reuse/index.js
CHANGED
|
@@ -11,6 +11,7 @@ const Common_1 = __importDefault(require("./modules/common/Common"));
|
|
|
11
11
|
const Ui5_1 = __importDefault(require("./modules/ui5/Ui5"));
|
|
12
12
|
const NonUi5_1 = __importDefault(require("./modules/nonUi5/NonUi5"));
|
|
13
13
|
const Service_1 = __importDefault(require("./modules/service/Service"));
|
|
14
|
+
const Mobile_1 = __importDefault(require("./modules/mobile/Mobile"));
|
|
14
15
|
// data
|
|
15
16
|
const authenticators_json_1 = __importDefault(require("./data/authenticators.json"));
|
|
16
17
|
class ReuseLibrary {
|
|
@@ -103,6 +104,22 @@ class ReuseLibrary {
|
|
|
103
104
|
...service,
|
|
104
105
|
...global.service
|
|
105
106
|
};
|
|
107
|
+
/**
|
|
108
|
+
* @global
|
|
109
|
+
* @description Global namespace for mobile modules.
|
|
110
|
+
*/
|
|
111
|
+
const mobile = {
|
|
112
|
+
element: Mobile_1.default.element,
|
|
113
|
+
userInteraction: Mobile_1.default.userInteraction,
|
|
114
|
+
gestures: Mobile_1.default.gestures,
|
|
115
|
+
device: Mobile_1.default.device,
|
|
116
|
+
android: Mobile_1.default.android,
|
|
117
|
+
ios: Mobile_1.default.ios
|
|
118
|
+
};
|
|
119
|
+
global.mobile = {
|
|
120
|
+
...mobile,
|
|
121
|
+
...global.mobile
|
|
122
|
+
};
|
|
106
123
|
}
|
|
107
124
|
}
|
|
108
125
|
exports.default = new ReuseLibrary();
|
package/lib/reuse/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/reuse/index.ts"],"names":[],"mappings":"AAAA,YAAY,CAAC;;;;;AAEb,YAAY;AACZ,4CAAsC;AAEtC,UAAU;AACV,+DAA4C;AAC5C,qEAAkD;AAClD,4DAAyC;AACzC,qEAAkD;AAClD,wEAAqD;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/reuse/index.ts"],"names":[],"mappings":"AAAA,YAAY,CAAC;;;;;AAEb,YAAY;AACZ,4CAAsC;AAEtC,UAAU;AACV,+DAA4C;AAC5C,qEAAkD;AAClD,4DAAyC;AACzC,qEAAkD;AAClD,wEAAqD;AACrD,qEAAkD;AAElD,OAAO;AACP,qFAAwD;AAIxD,MAAM,YAAY;IAChB,IAAI;QACF,mBAAmB;QACnB,aAAa;QACb,MAAM,CAAC,GAAG,GAAG,YAAG,CAAC;QAEjB;;;WAGG;QACH,MAAM,MAAM,GAAG;YACb,SAAS,EAAE,gBAAW,CAAC,SAAS;YAChC,IAAI,EAAE,gBAAW,CAAC,IAAI;YACtB,UAAU,E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GAAG;YACX,GAAG,GAAG;YACN,GAAG,MAAM,CAAC,GAAG;SACd,CAAC;QAEF;;;WAGG;QACH,MAAM,MAAM,GAAG;YACb,SAAS,EAAE,gBAAW,CAAC,SAAS;YAChC,OAAO,EAAE,gBAAW,CAAC,OAAO;YAC5B,UAAU,EAAE,gBAAW,CAAC,UAAU;YAClC,eAAe,EAAE,gBAAW,CAAC,eAAe;YAC5C,OAAO,EAAE,gBAAW,CAAC,OAAO;SAC7B,CAAC;QACF,MAAM,CAAC,MAAM,GAAG;YACd,GAAG,MAAM;YACT,GAAG,MAAM,CAAC,MAAM;SACjB,CAAC;QAEF;;;WAGG;QACH,MAAM,OAAO,GAAG;YACd,KAAK,EAAE,iBAAY,CAAC,KAAK;YACzB,IAAI,EAAE,iBAAY,CAAC,IAAI;SACxB,CAAC;QACF,MAAM,CAAC,OAAO,GAAG;YACf,GAAG,OAAO;YACV,GAAG,MAAM,CAAC,OAAO;SAClB,CAAC;QAEF;;;WAGG;QACH,MAAM,MAAM,GAAG;YACb,OAAO,EAAE,gBAAW,CAAC,OAAO;YAC5B,eAAe,EAAE,gBAAW,CAAC,eAAe;YAC5C,QAAQ,EAAE,gBAAW,CAAC,QAAQ;YAC9B,MAAM,EAAE,gBAAW,CAAC,MAAM;YAC1B,OAAO,EAAE,gBAAW,CAAC,OAAO;YAC5B,GAAG,EAAE,gBAAW,CAAC,GAAG;SACrB,CAAC;QACF,MAAM,CAAC,MAAM,GAAG;YACd,GAAG,MAAM;YACT,GAAG,MAAM,CAAC,MAAM;SACjB,CAAC;IACJ,CAAC;CACF;AAED,kBAAe,IAAI,YAAY,EAAE,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Gestures } from "./gestures";
|
|
2
|
+
import { ElementModule } from "./element";
|
|
3
|
+
import { UserInteraction } from "./userInteraction";
|
|
4
|
+
import { Device } from "./device";
|
|
5
|
+
import { Android } from "./android";
|
|
6
|
+
import { Ios } from "./ios";
|
|
7
|
+
export declare class Mobile {
|
|
8
|
+
gestures: Gestures;
|
|
9
|
+
userInteraction: UserInteraction;
|
|
10
|
+
element: ElementModule;
|
|
11
|
+
device: Device;
|
|
12
|
+
android: Android;
|
|
13
|
+
ios: Ios;
|
|
14
|
+
}
|
|
15
|
+
declare const _default: Mobile;
|
|
16
|
+
export default _default;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.Mobile = void 0;
|
|
7
|
+
const gestures_1 = __importDefault(require("./gestures"));
|
|
8
|
+
const element_1 = __importDefault(require("./element"));
|
|
9
|
+
const userInteraction_1 = __importDefault(require("./userInteraction"));
|
|
10
|
+
const device_1 = __importDefault(require("./device"));
|
|
11
|
+
const android_1 = __importDefault(require("./android"));
|
|
12
|
+
const ios_1 = __importDefault(require("./ios"));
|
|
13
|
+
class Mobile {
|
|
14
|
+
constructor() {
|
|
15
|
+
this.gestures = gestures_1.default;
|
|
16
|
+
this.userInteraction = userInteraction_1.default;
|
|
17
|
+
this.element = element_1.default;
|
|
18
|
+
this.device = device_1.default;
|
|
19
|
+
this.android = android_1.default;
|
|
20
|
+
this.ios = ios_1.default;
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
exports.Mobile = Mobile;
|
|
24
|
+
exports.default = new Mobile();
|
|
25
|
+
//# sourceMappingURL=Mobile.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Mobile.js","sourceRoot":"","sources":["../../../../src/reuse/modules/mobile/Mobile.ts"],"names":[],"mappings":";;;;;;AAAA,0DAAgD;AAChD,wDAAmD;AACnD,wEAAqE;AACrE,sDAA0C;AAC1C,wDAA6C;AAC7C,gDAAiC;AAEjC,MAAa,MAAM;IAAnB;QACE,aAAQ,GAAa,kBAAQ,CAAC;QAC9B,oBAAe,GAAoB,yBAAe,CAAC;QACnD,YAAO,GAAkB,iBAAO,CAAC;QACjC,WAAM,GAAW,gBAAM,CAAC;QACxB,YAAO,GAAY,iBAAO,CAAC;QAC3B,QAAG,GAAQ,aAAG,CAAC;IACjB,CAAC;CAAA;AAPD,wBAOC;AACD,kBAAe,IAAI,MAAM,EAAE,CAAC"}
|