rc-drawer
Advanced tools
Comparing version 3.0.2 to 3.1.0
@@ -28,3 +28,2 @@ function _typeof(obj) { if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); } | ||
import KeyCode from "rc-util/es/KeyCode"; | ||
import switchScrollingEffect from "rc-util/es/switchScrollingEffect"; | ||
import * as React from 'react'; | ||
@@ -238,3 +237,4 @@ import { polyfill } from 'react-lifecycles-compat'; | ||
ease = _this$props5.ease, | ||
getOpenCount = _this$props5.getOpenCount; | ||
getOpenCount = _this$props5.getOpenCount, | ||
switchScrollingEffect = _this$props5.switchScrollingEffect; | ||
var openCount = getOpenCount && getOpenCount(); | ||
@@ -280,3 +280,4 @@ | ||
ease = _this$props6.ease, | ||
getOpenCount = _this$props6.getOpenCount; | ||
getOpenCount = _this$props6.getOpenCount, | ||
switchScrollingEffect = _this$props6.switchScrollingEffect; | ||
var openCount = getOpenCount && getOpenCount(); | ||
@@ -444,3 +445,4 @@ | ||
getOpenCount = _this$props7.getOpenCount, | ||
open = _this$props7.open; | ||
open = _this$props7.open, | ||
switchScrollingEffect = _this$props7.switchScrollingEffect; | ||
var openCount = typeof getOpenCount === 'function' && getOpenCount(); | ||
@@ -491,3 +493,4 @@ delete currentDrawer[this.drawerId]; | ||
getOpenCount = _this$props8.getOpenCount, | ||
props = _objectWithoutProperties(_this$props8, ["className", "children", "style", "width", "height", "defaultOpen", "open", "prefixCls", "placement", "level", "levelMove", "ease", "duration", "getContainer", "handler", "onChange", "afterVisibleChange", "showMask", "maskClosable", "maskStyle", "onClose", "onHandleClick", "keyboard", "getOpenCount"]); // 首次渲染都将是关闭状态。 | ||
switchScrollingEffect = _this$props8.switchScrollingEffect, | ||
props = _objectWithoutProperties(_this$props8, ["className", "children", "style", "width", "height", "defaultOpen", "open", "prefixCls", "placement", "level", "levelMove", "ease", "duration", "getContainer", "handler", "onChange", "afterVisibleChange", "showMask", "maskClosable", "maskStyle", "onClose", "onHandleClick", "keyboard", "getOpenCount", "switchScrollingEffect"]); // 首次渲染都将是关闭状态。 | ||
@@ -494,0 +497,0 @@ |
@@ -38,3 +38,4 @@ import * as React from 'react'; | ||
getOpenCount?: () => number; | ||
switchScrollingEffect?: (close?: boolean) => void; | ||
} | ||
export {}; |
@@ -14,4 +14,2 @@ "use strict"; | ||
var _switchScrollingEffect = _interopRequireDefault(require("rc-util/lib/switchScrollingEffect")); | ||
var React = _interopRequireWildcard(require("react")); | ||
@@ -23,4 +21,6 @@ | ||
function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } | ||
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function _getRequireWildcardCache() { return cache; }; return cache; } | ||
function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; } | ||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } | ||
@@ -257,7 +257,8 @@ | ||
ease = _this$props5.ease, | ||
getOpenCount = _this$props5.getOpenCount; | ||
getOpenCount = _this$props5.getOpenCount, | ||
switchScrollingEffect = _this$props5.switchScrollingEffect; | ||
var openCount = getOpenCount && getOpenCount(); | ||
if (openCount === 1) { | ||
(0, _switchScrollingEffect.default)(); | ||
switchScrollingEffect(); | ||
} | ||
@@ -299,7 +300,8 @@ | ||
ease = _this$props6.ease, | ||
getOpenCount = _this$props6.getOpenCount; | ||
getOpenCount = _this$props6.getOpenCount, | ||
switchScrollingEffect = _this$props6.switchScrollingEffect; | ||
var openCount = getOpenCount && getOpenCount(); | ||
if (!openCount) { | ||
(0, _switchScrollingEffect.default)(true); | ||
switchScrollingEffect(true); | ||
} | ||
@@ -463,3 +465,4 @@ | ||
getOpenCount = _this$props7.getOpenCount, | ||
open = _this$props7.open; | ||
open = _this$props7.open, | ||
switchScrollingEffect = _this$props7.switchScrollingEffect; | ||
var openCount = typeof getOpenCount === 'function' && getOpenCount(); | ||
@@ -475,3 +478,3 @@ delete currentDrawer[this.drawerId]; | ||
document.body.style.overflow = ''; | ||
(0, _switchScrollingEffect.default)(true); | ||
switchScrollingEffect(true); | ||
} | ||
@@ -511,3 +514,4 @@ } // tslint:disable-next-line:member-ordering | ||
getOpenCount = _this$props8.getOpenCount, | ||
props = _objectWithoutProperties(_this$props8, ["className", "children", "style", "width", "height", "defaultOpen", "open", "prefixCls", "placement", "level", "levelMove", "ease", "duration", "getContainer", "handler", "onChange", "afterVisibleChange", "showMask", "maskClosable", "maskStyle", "onClose", "onHandleClick", "keyboard", "getOpenCount"]); // 首次渲染都将是关闭状态。 | ||
switchScrollingEffect = _this$props8.switchScrollingEffect, | ||
props = _objectWithoutProperties(_this$props8, ["className", "children", "style", "width", "height", "defaultOpen", "open", "prefixCls", "placement", "level", "levelMove", "ease", "duration", "getContainer", "handler", "onChange", "afterVisibleChange", "showMask", "maskClosable", "maskStyle", "onClose", "onHandleClick", "keyboard", "getOpenCount", "switchScrollingEffect"]); // 首次渲染都将是关闭状态。 | ||
@@ -514,0 +518,0 @@ |
@@ -16,4 +16,6 @@ "use strict"; | ||
function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } } | ||
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function _getRequireWildcardCache() { return cache; }; return cache; } | ||
function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; } | ||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } | ||
@@ -20,0 +22,0 @@ |
@@ -38,3 +38,4 @@ import * as React from 'react'; | ||
getOpenCount?: () => number; | ||
switchScrollingEffect?: (close?: boolean) => void; | ||
} | ||
export {}; |
{ | ||
"name": "rc-drawer", | ||
"version": "3.0.2", | ||
"version": "3.1.0", | ||
"description": "drawer component for react", | ||
@@ -75,5 +75,5 @@ "keywords": [ | ||
"classnames": "^2.2.6", | ||
"rc-util": "^4.11.2", | ||
"rc-util": "^4.16.1", | ||
"react-lifecycles-compat": "^3.0.4" | ||
} | ||
} |
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
92702
1989
Updatedrc-util@^4.16.1