@uiw/react-overlay-trigger
Advanced tools
Comparing version 4.0.0-alpha.2 to 4.0.0-alpha.3
@@ -54,7 +54,7 @@ "use strict"; | ||
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(n); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); } | ||
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); } | ||
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; } | ||
function _createSuper(Derived) { return function () { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; } | ||
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function () { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; } | ||
@@ -305,4 +305,4 @@ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } } | ||
var scrollLeft = (0, _utils.getScroll)(trigger.ownerDocument.documentElement); | ||
trigger = _objectSpread({}, (0, _getBoundingClientRect.default)(trigger), {}, (0, _getOuterSizes.default)(trigger)); | ||
popup = _objectSpread({}, (0, _getBoundingClientRect.default)(popup), {}, (0, _getOuterSizes.default)(popup)); | ||
trigger = _objectSpread(_objectSpread({}, (0, _getBoundingClientRect.default)(trigger)), (0, _getOuterSizes.default)(trigger)); | ||
popup = _objectSpread(_objectSpread({}, (0, _getBoundingClientRect.default)(popup)), (0, _getOuterSizes.default)(popup)); | ||
var bottom = winSizeHeight - trigger.bottom; | ||
@@ -472,3 +472,3 @@ var right = winSizeWidth - trigger.left - trigger.width; | ||
var props = _objectSpread({}, other, { | ||
var props = _objectSpread(_objectSpread({}, other), {}, { | ||
dialogProps: {} | ||
@@ -493,6 +493,6 @@ }); | ||
props.style = _objectSpread({}, props.style, {}, overlayStyl); | ||
props.style = _objectSpread(_objectSpread({}, props.style), overlayStyl); | ||
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_RefHolder.default, { | ||
ref: this.trigger | ||
}, (0, _react.cloneElement)(child, Object.assign({}, child.props, _objectSpread({}, triggerProps, { | ||
}, (0, _react.cloneElement)(child, Object.assign({}, child.props, _objectSpread(_objectSpread({}, triggerProps), {}, { | ||
className: (0, _classnames3.default)(child.props.className, (0, _defineProperty2.default)({}, "".concat(prefixCls, "-disabled"), disabled)) | ||
@@ -499,0 +499,0 @@ })))), /*#__PURE__*/_react.default.createElement(_reactOverlay.default, (0, _extends2.default)({}, props, { |
@@ -20,3 +20,3 @@ "use strict"; | ||
function _createSuper(Derived) { return function () { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; } | ||
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function () { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; } | ||
@@ -23,0 +23,0 @@ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } } |
@@ -24,3 +24,3 @@ "use strict"; | ||
function getClientRect(offsets) { | ||
return _objectSpread({}, offsets, { | ||
return _objectSpread(_objectSpread({}, offsets), {}, { | ||
right: offsets.left + offsets.width, | ||
@@ -27,0 +27,0 @@ bottom: offsets.top + offsets.height |
@@ -17,7 +17,7 @@ import _extends from "@babel/runtime/helpers/esm/extends"; | ||
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(n); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); } | ||
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); } | ||
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; } | ||
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; } | ||
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function () { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; } | ||
@@ -280,4 +280,4 @@ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } } | ||
var scrollLeft = getScroll(trigger.ownerDocument.documentElement); | ||
trigger = _objectSpread({}, getBoundingClientRect(trigger), {}, getOuterSizes(trigger)); | ||
popup = _objectSpread({}, getBoundingClientRect(popup), {}, getOuterSizes(popup)); | ||
trigger = _objectSpread(_objectSpread({}, getBoundingClientRect(trigger)), getOuterSizes(trigger)); | ||
popup = _objectSpread(_objectSpread({}, getBoundingClientRect(popup)), getOuterSizes(popup)); | ||
var bottom = winSizeHeight - trigger.bottom; | ||
@@ -448,3 +448,3 @@ var right = winSizeWidth - trigger.left - trigger.width; | ||
var props = _objectSpread({}, other, { | ||
var props = _objectSpread(_objectSpread({}, other), {}, { | ||
dialogProps: {} | ||
@@ -469,6 +469,6 @@ }); | ||
props.style = _objectSpread({}, props.style, {}, overlayStyl); | ||
props.style = _objectSpread(_objectSpread({}, props.style), overlayStyl); | ||
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(RefHolder, { | ||
ref: this.trigger | ||
}, cloneElement(child, Object.assign({}, child.props, _objectSpread({}, triggerProps, { | ||
}, cloneElement(child, Object.assign({}, child.props, _objectSpread(_objectSpread({}, triggerProps), {}, { | ||
className: classnames(child.props.className, _defineProperty({}, "".concat(prefixCls, "-disabled"), disabled)) | ||
@@ -475,0 +475,0 @@ })))), /*#__PURE__*/React.createElement(Overlay, _extends({}, props, { |
@@ -6,3 +6,3 @@ import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck"; | ||
function _createSuper(Derived) { return function () { var Super = _getPrototypeOf(Derived), result; if (_isNativeReflectConstruct()) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; } | ||
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function () { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; } | ||
@@ -9,0 +9,0 @@ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } } |
@@ -15,3 +15,3 @@ import _defineProperty from "@babel/runtime/helpers/esm/defineProperty"; | ||
export default function getClientRect(offsets) { | ||
return _objectSpread({}, offsets, { | ||
return _objectSpread(_objectSpread({}, offsets), {}, { | ||
right: offsets.left + offsets.width, | ||
@@ -18,0 +18,0 @@ bottom: offsets.top + offsets.height |
{ | ||
"name": "@uiw/react-overlay-trigger", | ||
"version": "4.0.0-alpha.2", | ||
"version": "4.0.0-alpha.3", | ||
"description": "OverlayTrigger component", | ||
"author": "Kenny Wong <wowohoo@qq.com>", | ||
"homepage": "https://github.com/uiwjs/uiw/tree/master/packages/react-overlay-trigger#readme", | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/uiwjs/uiw.git" | ||
}, | ||
"license": "MIT", | ||
@@ -55,4 +59,4 @@ "main": "lib/cjs/index.js", | ||
"dependencies": { | ||
"@uiw/react-overlay": "4.0.0-alpha.2", | ||
"@uiw/utils": "4.0.0-alpha.2", | ||
"@uiw/react-overlay": "4.0.0-alpha.3", | ||
"@uiw/utils": "4.0.0-alpha.3", | ||
"classnames": "^2.2.6" | ||
@@ -69,3 +73,3 @@ }, | ||
}, | ||
"gitHead": "64af09b5b66c90204315cda3d4f0e3a567ede7a6" | ||
"gitHead": "b69dd5c068ab4d05bae8f347795dd515c0af6e3b" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
202927
0
+ Added@uiw/react-overlay@4.0.0-alpha.3(transitive)
+ Added@uiw/react-portal@4.0.0-alpha.3(transitive)
+ Added@uiw/utils@4.0.0-alpha.3(transitive)
- Removed@uiw/react-overlay@4.0.0-alpha.2(transitive)
- Removed@uiw/react-portal@4.0.0-alpha.2(transitive)
- Removed@uiw/utils@4.0.0-alpha.2(transitive)
Updated@uiw/utils@4.0.0-alpha.3