@rc-component/trigger
Advanced tools
Comparing version 1.13.2 to 1.13.3
@@ -42,3 +42,2 @@ import { warning } from 'rc-util'; | ||
var win = getWin(popupEle); | ||
var targetRoot = targetEle === null || targetEle === void 0 ? void 0 : targetEle.getRootNode(); | ||
win.addEventListener('mousedown', onWindowMouseDown); | ||
@@ -56,3 +55,5 @@ win.addEventListener('click', onWindowClick); | ||
if (process.env.NODE_ENV !== 'production') { | ||
var popupRoot = popupEle.getRootNode(); | ||
var _targetEle$getRootNod, _popupEle$getRootNode; | ||
var targetRoot = targetEle === null || targetEle === void 0 ? void 0 : (_targetEle$getRootNod = targetEle.getRootNode) === null || _targetEle$getRootNod === void 0 ? void 0 : _targetEle$getRootNod.call(targetEle); | ||
var popupRoot = (_popupEle$getRootNode = popupEle.getRootNode) === null || _popupEle$getRootNode === void 0 ? void 0 : _popupEle$getRootNode.call(popupEle); | ||
warning(targetRoot === popupRoot, "trigger element and popup element should in same shadow root."); | ||
@@ -59,0 +60,0 @@ } |
@@ -50,3 +50,2 @@ "use strict"; | ||
var win = (0, _util.getWin)(popupEle); | ||
var targetRoot = targetEle === null || targetEle === void 0 ? void 0 : targetEle.getRootNode(); | ||
win.addEventListener('mousedown', onWindowMouseDown); | ||
@@ -64,3 +63,5 @@ win.addEventListener('click', onWindowClick); | ||
if (process.env.NODE_ENV !== 'production') { | ||
var popupRoot = popupEle.getRootNode(); | ||
var _targetEle$getRootNod, _popupEle$getRootNode; | ||
var targetRoot = targetEle === null || targetEle === void 0 ? void 0 : (_targetEle$getRootNod = targetEle.getRootNode) === null || _targetEle$getRootNod === void 0 ? void 0 : _targetEle$getRootNod.call(targetEle); | ||
var popupRoot = (_popupEle$getRootNode = popupEle.getRootNode) === null || _popupEle$getRootNode === void 0 ? void 0 : _popupEle$getRootNode.call(popupEle); | ||
(0, _rcUtil.warning)(targetRoot === popupRoot, "trigger element and popup element should in same shadow root."); | ||
@@ -67,0 +68,0 @@ } |
{ | ||
"name": "@rc-component/trigger", | ||
"version": "1.13.2", | ||
"version": "1.13.3", | ||
"description": "base abstract trigger component for react", | ||
@@ -5,0 +5,0 @@ "engines": { |
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
168429
63
3711