@zag-js/dom-query
Advanced tools
Comparing version 0.0.0-dev-20221018140542 to 0.0.0-dev-20221031080845
@@ -53,8 +53,10 @@ "use strict"; | ||
function getDocument(el) { | ||
var _a; | ||
if (isDocument(el)) | ||
return el; | ||
return (el == null ? void 0 : el.ownerDocument) ?? document; | ||
return (_a = el == null ? void 0 : el.ownerDocument) != null ? _a : document; | ||
} | ||
function getWindow(el) { | ||
return getDocument(el).defaultView ?? window; | ||
var _a; | ||
return (_a = getDocument(el).defaultView) != null ? _a : window; | ||
} | ||
@@ -66,4 +68,4 @@ | ||
getRootNode(ctx) { | ||
var _a; | ||
return ((_a = ctx.getRootNode) == null ? void 0 : _a.call(ctx)) ?? document; | ||
var _a, _b; | ||
return (_b = (_a = ctx.getRootNode) == null ? void 0 : _a.call(ctx)) != null ? _b : document; | ||
}, | ||
@@ -84,3 +86,3 @@ getDoc(ctx) { | ||
return function emit(evt, detail, options) { | ||
const { bubbles = true, cancelable, composed = true } = options ?? {}; | ||
const { bubbles = true, cancelable, composed = true } = options != null ? options : {}; | ||
const eventName = `zag:${String(evt)}`; | ||
@@ -87,0 +89,0 @@ const init = { |
{ | ||
"name": "@zag-js/dom-query", | ||
"version": "0.0.0-dev-20221018140542", | ||
"version": "0.0.0-dev-20221031080845", | ||
"description": "The dom helper library for zag.js machines", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
Sorry, the diff of this file is not supported yet
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
10248
227