Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@applitools/utils

Package Overview
Dependencies
Maintainers
28
Versions
73
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@applitools/utils - npm Package Compare versions

Comparing version 1.2.13 to 1.2.14

16

dist/geometry.js

@@ -22,3 +22,3 @@ "use strict";

Object.defineProperty(exports, "__esModule", { value: true });
exports.divide = exports.equals = exports.contains = exports.isIntersected = exports.intersect = exports.offsetNegative = exports.offset = exports.scale = exports.rotate = exports.round = exports.isEmpty = exports.region = exports.size = exports.location = void 0;
exports.divide = exports.equals = exports.contains = exports.isIntersected = exports.intersect = exports.offsetNegative = exports.offset = exports.scale = exports.rotate = exports.ceil = exports.round = exports.isEmpty = exports.region = exports.size = exports.location = void 0;
const types = __importStar(require("./types"));

@@ -57,2 +57,16 @@ const guard = __importStar(require("./guard"));

exports.round = round;
function ceil(target) {
const result = Object.assign({}, target);
if (types.has(target, ['x', 'y'])) {
// intentionally using Math.round and not Math.ceil here, because the point is that for width and height it makes sense to use ceil, but not for x and y
result.x = Math.round(target.x);
result.y = Math.round(target.y);
}
if (types.has(target, ['width', 'height'])) {
result.width = Math.ceil(target.width);
result.height = Math.ceil(target.height);
}
return result;
}
exports.ceil = ceil;
function rotate(target, degrees, size) {

@@ -59,0 +73,0 @@ degrees = (360 + degrees) % 360;

4

package.json
{
"name": "@applitools/utils",
"version": "1.2.13",
"version": "1.2.14",
"keywords": [

@@ -53,3 +53,3 @@ "applitools",

"devDependencies": {
"@applitools/sdk-release-kit": "0.13.11",
"@applitools/bongo": "^2.0.2",
"@types/node": "^14.14.7",

@@ -56,0 +56,0 @@ "@typescript-eslint/eslint-plugin": "^4.7.0",

@@ -23,2 +23,5 @@ declare type Location = {

export declare function round(region: Location): Location;
export declare function ceil(region: Region): Region;
export declare function ceil(region: RectangleSize): RectangleSize;
export declare function ceil(region: Location): Location;
export declare function rotate(size: RectangleSize, degrees: number): RectangleSize;

@@ -25,0 +28,0 @@ export declare function rotate(region: Region, degrees: number, size: RectangleSize): Region;

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc