@applitools/driver
Advanced tools
Comparing version 1.19.7 to 1.20.0
# Changelog | ||
## [1.20.0](https://github.com/Applitools-Dev/sdk/compare/js/driver@1.19.7...js/driver@1.20.0) (2024-11-12) | ||
### Features | ||
* add an option to keep the navigation bar for android devices ([#2608](https://github.com/Applitools-Dev/sdk/issues/2608)) ([e7647e0](https://github.com/Applitools-Dev/sdk/commit/e7647e0105a7aa47e6bf3b20ab033f1e389ca849)) | ||
## [1.19.7](https://github.com/Applitools-Dev/sdk/compare/js/driver@1.19.6...js/driver@1.19.7) (2024-11-07) | ||
@@ -4,0 +11,0 @@ |
@@ -308,3 +308,3 @@ "use strict"; | ||
} | ||
async getViewport() { | ||
async getViewport({ keepNavigationBar } = {}) { | ||
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0; | ||
@@ -346,5 +346,5 @@ var _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, _14, _15; | ||
} | ||
if (navigationBar === null || navigationBar === void 0 ? void 0 : navigationBar.visible) { | ||
if ((navigationBar === null || navigationBar === void 0 ? void 0 : navigationBar.visible) && !keepNavigationBar) { | ||
this._logger.log('Driver navigation size', navigationBar); | ||
// if navigation bar is placed on the right side is screen the the orientation is landscape-secondary | ||
// if navigation bar is placed on the right side of the screen then the orientation is landscape-secondary | ||
if (navigationBar.x > 0) | ||
@@ -390,3 +390,3 @@ this._viewport.orientation = 'landscape-secondary'; | ||
this._viewport.viewportSize.height -= this._viewport.statusBarSize; | ||
if (environment.isAndroid) { | ||
if (environment.isAndroid && !keepNavigationBar) { | ||
this._viewport.viewportSize[((_u = this._viewport.orientation) === null || _u === void 0 ? void 0 : _u.startsWith('landscape')) ? 'width' : 'height'] -= | ||
@@ -393,0 +393,0 @@ this._viewport.navigationBarSize; |
{ | ||
"name": "@applitools/driver", | ||
"version": "1.19.7", | ||
"version": "1.20.0", | ||
"description": "Applitools universal framework wrapper", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
@@ -74,3 +74,5 @@ /// <reference types="node" /> | ||
getEnvironment(): Promise<Environment>; | ||
getViewport(): Promise<Viewport>; | ||
getViewport({ keepNavigationBar }?: { | ||
keepNavigationBar?: boolean; | ||
}): Promise<Viewport>; | ||
getFeatures(): Promise<Features>; | ||
@@ -77,0 +79,0 @@ getSessionId(): Promise<string | null>; |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
283470
4390