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

@zag-js/element-size

Package Overview
Dependencies
Maintainers
1
Versions
692
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@zag-js/element-size - npm Package Compare versions

Comparing version 0.0.0-dev-20221005155029 to 0.0.0-dev-20221031080845

7

dist/index.js

@@ -30,2 +30,3 @@ "use strict";

function trackElementSize(element, callback) {
var _a;
if (!element) {

@@ -36,3 +37,3 @@ callback(void 0);

callback({ width: element.offsetWidth, height: element.offsetHeight });
const win = element.ownerDocument.defaultView ?? window;
const win = (_a = element.ownerDocument.defaultView) != null ? _a : window;
const observer = new win.ResizeObserver((entries) => {

@@ -86,6 +87,6 @@ if (!Array.isArray(entries) || !entries.length)

function trackMutation(el, cb) {
var _a;
var _a, _b;
if (!el || !el.parentElement)
return;
const win = ((_a = el.ownerDocument) == null ? void 0 : _a.defaultView) ?? window;
const win = (_b = (_a = el.ownerDocument) == null ? void 0 : _a.defaultView) != null ? _b : window;
const observer = new win.MutationObserver(() => {

@@ -92,0 +93,0 @@ cb();

{
"name": "@zag-js/element-size",
"version": "0.0.0-dev-20221005155029",
"version": "0.0.0-dev-20221031080845",
"description": "Observer the size of an element over time",

@@ -5,0 +5,0 @@ "main": "dist/index.js",

Sorry, the diff of this file is not supported yet

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