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

@progress/kendo-popup-common

Package Overview
Dependencies
Maintainers
1
Versions
56
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@progress/kendo-popup-common - npm Package Compare versions

Comparing version 0.2.0 to 0.2.1

9

dist/npm/js/offset.js

@@ -83,8 +83,2 @@ module.exports =

exports.default = function (element) {
var elementLeft = element.style.left;
var elementTop = element.style.top;
element.style.left = '';
element.style.top = '';
var rect = element.getBoundingClientRect();

@@ -103,5 +97,2 @@ var _rect = rect,

element.style.left = elementLeft;
element.style.top = elementTop;
return {

@@ -108,0 +99,0 @@ top: top,

26

e2e/offset.js

@@ -19,3 +19,3 @@ import { $, withRoot } from 'e2e-utils';

it('should return bounding rect applying window scroll position', () => {
it('should return bounding rect without window scroll position', () => {
root.append("<style>body { height: 2000px } .root { position: absolute; top: 100px, width: 100px; height: 80px; }</style>");

@@ -30,3 +30,3 @@ root.addClass("root");

expect(rect.top).toBe(8); //-192 (client rect top) + 200 (scrollY)
expect(rect.top).toBe(-192);
});

@@ -41,4 +41,24 @@

expect(rect.top).toBe(clientRect.top - 20);
expect(rect.top).toBe(clientRect.top);
});
it('should honour positioned with className element', () => {
root.append("<style>.root { position: absolute; top: 200px; }</style>");
root.addClass("root");
const clientRect = root[0].getBoundingClientRect();
const rect = offset(root[0]);
expect(rect.top).toBe(clientRect.top);
});
it('should honour positioned with styles.top/left element', () => {
root.css("position", "absolute");
root.css("top", 200);
const clientRect = root[0].getBoundingClientRect();
const rect = offset(root[0]);
expect(rect.top).toBe(clientRect.top);
});
}));
{
"name": "@progress/kendo-popup-common",
"description": "Kendo UI Popup common package",
"version": "0.2.0",
"version": "0.2.1",
"publishConfig": {

@@ -6,0 +6,0 @@ "registry": "https://registry.npm.telerik.com"

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