@ringcentral/juno 2.20.1 → 2.21.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/Buttons/IconButton/IconButton.js +1 -1
- package/components/Buttons/IconButton/deprecated/IconButtonProps.d.ts +0 -2
- package/components/Downshift/utils/useDownshiftTag.js +2 -0
- package/components/Tabs/Tabs/MoreMenuTabs/MoreMenuTabs.js +1 -1
- package/es6/components/Buttons/IconButton/IconButton.js +1 -1
- package/es6/components/Downshift/utils/useDownshiftTag.js +2 -0
- package/es6/components/Tabs/Tabs/MoreMenuTabs/MoreMenuTabs.js +1 -1
- package/package.json +1 -1
|
@@ -17,7 +17,7 @@ var _RcIconButton = react_1.memo(react_1.forwardRef(function (inProps, ref) {
|
|
|
17
17
|
// eslint-disable-next-line react-hooks/rules-of-hooks
|
|
18
18
|
foundation_1.useDeprecatedCheck(RcIconButton, props, IconButtonProps_1.rcIconButtonWarning);
|
|
19
19
|
}
|
|
20
|
-
var _b = props.buttonRef, buttonRef = _b === void 0 ? ref : _b, _c = props.IconProps, IconProps = _c === void 0 ? {} : _c, className = props.className, classesProp = props.classes, children = props.children, title = props.title, disabledFakeBorder = props.disabledFakeBorder, symbol = props.symbol, disabled = props.disabled, invisible = props.invisible, type = props.type, loading = props.loading, TouchRippleProps = props.TouchRippleProps, variant = props.variant, CircularProgressProps = props.CircularProgressProps, color = props.color, shouldPersistBg = props.shouldPersistBg, stretchIcon = props.stretchIcon, iconColor = props.iconColor, iconSize = props.iconSize, disableTouchRipple = props.disableTouchRipple, useColorWhenDisabled = props.useColorWhenDisabled, size = props.size, radius = props.radius, elevation = props.elevation, activeElevation = props.activeElevation, aRef = props.aRef, tooltipTitle = props.tooltipTitle, tooltipForceHide = props.tooltipForceHide, disableToolTip = props.disableToolTip, alwaysEnableTooltip = props.alwaysEnableTooltip, tooltipPlacement = props.tooltipPlacement, ariaLabel = props.ariaLabel, popperProps = props.popperProps, externalLink = props.externalLink, download = props.download,
|
|
20
|
+
var _b = props.buttonRef, buttonRef = _b === void 0 ? ref : _b, _c = props.IconProps, IconProps = _c === void 0 ? {} : _c, className = props.className, classesProp = props.classes, children = props.children, title = props.title, disabledFakeBorder = props.disabledFakeBorder, symbol = props.symbol, disabled = props.disabled, invisible = props.invisible, type = props.type, loading = props.loading, TouchRippleProps = props.TouchRippleProps, variant = props.variant, CircularProgressProps = props.CircularProgressProps, color = props.color, shouldPersistBg = props.shouldPersistBg, stretchIcon = props.stretchIcon, iconColor = props.iconColor, iconSize = props.iconSize, disableTouchRipple = props.disableTouchRipple, useColorWhenDisabled = props.useColorWhenDisabled, size = props.size, radius = props.radius, elevation = props.elevation, activeElevation = props.activeElevation, aRef = props.aRef, tooltipTitle = props.tooltipTitle, tooltipForceHide = props.tooltipForceHide, disableToolTip = props.disableToolTip, alwaysEnableTooltip = props.alwaysEnableTooltip, tooltipPlacement = props.tooltipPlacement, ariaLabel = props.ariaLabel, popperProps = props.popperProps, externalLink = props.externalLink, download = props.download, href = props.href, rest = tslib_1.__rest(props, ["buttonRef", "IconProps", "className", "classes", "children", "title", "disabledFakeBorder", "symbol", "disabled", "invisible", "type", "loading", "TouchRippleProps", "variant", "CircularProgressProps", "color", "shouldPersistBg", "stretchIcon", "iconColor", "iconSize", "disableTouchRipple", "useColorWhenDisabled", "size", "radius", "elevation", "activeElevation", "aRef", "tooltipTitle", "tooltipForceHide", "disableToolTip", "alwaysEnableTooltip", "tooltipPlacement", "ariaLabel", "popperProps", "externalLink", "download", "href"]);
|
|
21
21
|
var theme = foundation_1.useTheme();
|
|
22
22
|
var isOutline = variant === 'outline';
|
|
23
23
|
var isContained = variant === 'contained';
|
|
@@ -45,8 +45,6 @@ declare type RcIconButtonProps = RcIconButtonBaseProps & {
|
|
|
45
45
|
as?: ElementType | keyof JSX.IntrinsicElements;
|
|
46
46
|
} & RcIconButtonDeprecatedProps & RcBaseProps<RcIconProps, 'color' | 'children' | 'size'>;
|
|
47
47
|
declare type RcIconButtonDeprecatedProps = {
|
|
48
|
-
/** @deprecated don't have any logic below, now need anymore */
|
|
49
|
-
autoFocus?: boolean;
|
|
50
48
|
/**
|
|
51
49
|
* @deprecated
|
|
52
50
|
* enable tooltip even button is disabled. default with false
|
|
@@ -187,10 +187,12 @@ exports.useDownshiftTag = function (_a) {
|
|
|
187
187
|
}
|
|
188
188
|
},
|
|
189
189
|
onDelete: function (e) {
|
|
190
|
+
var _a;
|
|
190
191
|
// * left button clicked
|
|
191
192
|
if (e.button === 0) {
|
|
192
193
|
removeTag(selectedItem);
|
|
193
194
|
setFocused(false);
|
|
195
|
+
(_a = inputRef.current) === null || _a === void 0 ? void 0 : _a.focus();
|
|
194
196
|
}
|
|
195
197
|
},
|
|
196
198
|
}, restTagProps);
|
|
@@ -39,6 +39,7 @@ var _MoreMenuTabs = react_1.forwardRef(function (props, ref) {
|
|
|
39
39
|
var hasResizeRef = react_1.useRef(true);
|
|
40
40
|
var forceUpdate = foundation_1.useForceUpdate();
|
|
41
41
|
var sizeChange = function (size) {
|
|
42
|
+
hasResizeRef.current = true;
|
|
42
43
|
if (tabsSizeRef.current.height !== size.height ||
|
|
43
44
|
tabsSizeRef.current.width !== size.width) {
|
|
44
45
|
tabsSizeRef.current = size;
|
|
@@ -50,7 +51,6 @@ var _MoreMenuTabs = react_1.forwardRef(function (props, ref) {
|
|
|
50
51
|
var _b = tslib_1.__read(_a, 1), entry = _b[0];
|
|
51
52
|
var _c = entry.contentRect, width = _c.width, height = _c.height;
|
|
52
53
|
var obj = { width: width, height: height };
|
|
53
|
-
hasResizeRef.current = true;
|
|
54
54
|
throttleTabsSizeChange(obj);
|
|
55
55
|
}, { mode: 'none' });
|
|
56
56
|
var tabsSize = tabsSizeRef.current;
|
|
@@ -15,7 +15,7 @@ var _RcIconButton = memo(forwardRef(function (inProps, ref) {
|
|
|
15
15
|
// eslint-disable-next-line react-hooks/rules-of-hooks
|
|
16
16
|
useDeprecatedCheck(RcIconButton, props, rcIconButtonWarning);
|
|
17
17
|
}
|
|
18
|
-
var _b = props.buttonRef, buttonRef = _b === void 0 ? ref : _b, _c = props.IconProps, IconProps = _c === void 0 ? {} : _c, className = props.className, classesProp = props.classes, children = props.children, title = props.title, disabledFakeBorder = props.disabledFakeBorder, symbol = props.symbol, disabled = props.disabled, invisible = props.invisible, type = props.type, loading = props.loading, TouchRippleProps = props.TouchRippleProps, variant = props.variant, CircularProgressProps = props.CircularProgressProps, color = props.color, shouldPersistBg = props.shouldPersistBg, stretchIcon = props.stretchIcon, iconColor = props.iconColor, iconSize = props.iconSize, disableTouchRipple = props.disableTouchRipple, useColorWhenDisabled = props.useColorWhenDisabled, size = props.size, radius = props.radius, elevation = props.elevation, activeElevation = props.activeElevation, aRef = props.aRef, tooltipTitle = props.tooltipTitle, tooltipForceHide = props.tooltipForceHide, disableToolTip = props.disableToolTip, alwaysEnableTooltip = props.alwaysEnableTooltip, tooltipPlacement = props.tooltipPlacement, ariaLabel = props.ariaLabel, popperProps = props.popperProps, externalLink = props.externalLink, download = props.download,
|
|
18
|
+
var _b = props.buttonRef, buttonRef = _b === void 0 ? ref : _b, _c = props.IconProps, IconProps = _c === void 0 ? {} : _c, className = props.className, classesProp = props.classes, children = props.children, title = props.title, disabledFakeBorder = props.disabledFakeBorder, symbol = props.symbol, disabled = props.disabled, invisible = props.invisible, type = props.type, loading = props.loading, TouchRippleProps = props.TouchRippleProps, variant = props.variant, CircularProgressProps = props.CircularProgressProps, color = props.color, shouldPersistBg = props.shouldPersistBg, stretchIcon = props.stretchIcon, iconColor = props.iconColor, iconSize = props.iconSize, disableTouchRipple = props.disableTouchRipple, useColorWhenDisabled = props.useColorWhenDisabled, size = props.size, radius = props.radius, elevation = props.elevation, activeElevation = props.activeElevation, aRef = props.aRef, tooltipTitle = props.tooltipTitle, tooltipForceHide = props.tooltipForceHide, disableToolTip = props.disableToolTip, alwaysEnableTooltip = props.alwaysEnableTooltip, tooltipPlacement = props.tooltipPlacement, ariaLabel = props.ariaLabel, popperProps = props.popperProps, externalLink = props.externalLink, download = props.download, href = props.href, rest = __rest(props, ["buttonRef", "IconProps", "className", "classes", "children", "title", "disabledFakeBorder", "symbol", "disabled", "invisible", "type", "loading", "TouchRippleProps", "variant", "CircularProgressProps", "color", "shouldPersistBg", "stretchIcon", "iconColor", "iconSize", "disableTouchRipple", "useColorWhenDisabled", "size", "radius", "elevation", "activeElevation", "aRef", "tooltipTitle", "tooltipForceHide", "disableToolTip", "alwaysEnableTooltip", "tooltipPlacement", "ariaLabel", "popperProps", "externalLink", "download", "href"]);
|
|
19
19
|
var theme = useTheme();
|
|
20
20
|
var isOutline = variant === 'outline';
|
|
21
21
|
var isContained = variant === 'contained';
|
|
@@ -185,10 +185,12 @@ export var useDownshiftTag = function (_a) {
|
|
|
185
185
|
}
|
|
186
186
|
},
|
|
187
187
|
onDelete: function (e) {
|
|
188
|
+
var _a;
|
|
188
189
|
// * left button clicked
|
|
189
190
|
if (e.button === 0) {
|
|
190
191
|
removeTag(selectedItem);
|
|
191
192
|
setFocused(false);
|
|
193
|
+
(_a = inputRef.current) === null || _a === void 0 ? void 0 : _a.focus();
|
|
192
194
|
}
|
|
193
195
|
},
|
|
194
196
|
}, restTagProps);
|
|
@@ -37,6 +37,7 @@ var _MoreMenuTabs = forwardRef(function (props, ref) {
|
|
|
37
37
|
var hasResizeRef = useRef(true);
|
|
38
38
|
var forceUpdate = useForceUpdate();
|
|
39
39
|
var sizeChange = function (size) {
|
|
40
|
+
hasResizeRef.current = true;
|
|
40
41
|
if (tabsSizeRef.current.height !== size.height ||
|
|
41
42
|
tabsSizeRef.current.width !== size.width) {
|
|
42
43
|
tabsSizeRef.current = size;
|
|
@@ -48,7 +49,6 @@ var _MoreMenuTabs = forwardRef(function (props, ref) {
|
|
|
48
49
|
var _b = __read(_a, 1), entry = _b[0];
|
|
49
50
|
var _c = entry.contentRect, width = _c.width, height = _c.height;
|
|
50
51
|
var obj = { width: width, height: height };
|
|
51
|
-
hasResizeRef.current = true;
|
|
52
52
|
throttleTabsSizeChange(obj);
|
|
53
53
|
}, { mode: 'none' });
|
|
54
54
|
var tabsSize = tabsSizeRef.current;
|