@jahia/cypress 3.17.1 → 3.17.2

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.
@@ -26,7 +26,9 @@ var Dropdown = /** @class */ (function (_super) {
26
26
  }
27
27
  Dropdown.prototype.select = function (item) {
28
28
  this.get().click();
29
- utils_1.getComponent(menu_1.Menu, null, function ($el) { return expect($el).to.be.visible; }).select(item);
29
+ // eslint-disable-next-line cypress/no-unnecessary-waiting
30
+ cy.wait(500);
31
+ utils_1.getComponent(menu_1.Menu, this).select(item);
30
32
  return this;
31
33
  };
32
34
  Dropdown.defaultSelector = '.moonstone-dropdown_container';
@@ -34,7 +34,7 @@ var Menu = /** @class */ (function (_super) {
34
34
  this.get().find(".moonstone-menuItem[data-sel-role=\"" + item + "\"]").trigger('click');
35
35
  return this;
36
36
  };
37
- Menu.defaultSelector = '.moonstone-menu:visible';
37
+ Menu.defaultSelector = '.moonstone-menu:not(.moonstone-hidden)';
38
38
  return Menu;
39
39
  }(baseComponent_1.BaseComponent));
40
40
  exports.Menu = Menu;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jahia/cypress",
3
- "version": "3.17.1",
3
+ "version": "3.17.2",
4
4
  "scripts": {
5
5
  "build": "tsc",
6
6
  "lint": "eslint src -c .eslintrc.json --ext .ts"
@@ -7,7 +7,9 @@ export class Dropdown extends BaseComponent {
7
7
 
8
8
  select(item: string): Dropdown {
9
9
  this.get().click();
10
- getComponent(Menu, null, $el => expect($el).to.be.visible).select(item);
10
+ // eslint-disable-next-line cypress/no-unnecessary-waiting
11
+ cy.wait(500);
12
+ getComponent(Menu, this).select(item);
11
13
  return this;
12
14
  }
13
15
  }
@@ -1,7 +1,7 @@
1
1
  import {BaseComponent} from '../baseComponent';
2
2
 
3
3
  export class Menu extends BaseComponent {
4
- static defaultSelector = '.moonstone-menu:visible'
4
+ static defaultSelector = '.moonstone-menu:not(.moonstone-hidden)'
5
5
 
6
6
  select(item: string): Menu {
7
7
  // eslint-disable-next-line cypress/no-unnecessary-waiting