@superdispatch/ui 0.17.1 → 0.19.0
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/dist-node/index.js +25 -12
- package/dist-node/index.js.map +1 -1
- package/dist-src/adaptive-vertical-toolbar/AdaptiveVerticalToolbar.js +9 -12
- package/dist-src/index.js +1 -0
- package/dist-src/utils/ExitTransitionPlaceholder.js +15 -0
- package/dist-types/index.d.ts +7 -1
- package/dist-web/index.js +26 -14
- package/dist-web/index.js.map +1 -1
- package/package.json +2 -2
package/dist-node/index.js
CHANGED
|
@@ -420,19 +420,17 @@ var AdaptiveVerticalToolbar = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
420
420
|
onClose: () => {
|
|
421
421
|
setMenuButtonRef(undefined);
|
|
422
422
|
},
|
|
423
|
-
children: menuItems.
|
|
423
|
+
children: menuItems.flatMap((item, index, arr) => {
|
|
424
424
|
var next = arr[index + 1];
|
|
425
|
-
return /*#__PURE__*/jsxRuntime.
|
|
426
|
-
|
|
427
|
-
onClick
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
}, item.key), next && next.menuGroupKey !== item.menuGroupKey && /*#__PURE__*/jsxRuntime.jsx(core.Divider, {})]
|
|
435
|
-
});
|
|
425
|
+
return [/*#__PURE__*/jsxRuntime.jsx(core.MenuItem, {
|
|
426
|
+
onClick: event => {
|
|
427
|
+
var _item$onClick;
|
|
428
|
+
|
|
429
|
+
(_item$onClick = item.onClick) === null || _item$onClick === void 0 ? void 0 : _item$onClick.call(item, event);
|
|
430
|
+
setMenuButtonRef(undefined);
|
|
431
|
+
},
|
|
432
|
+
children: renderMenuItem(item)
|
|
433
|
+
}, item.key), next && next.menuGroupKey !== item.menuGroupKey && /*#__PURE__*/jsxRuntime.jsx(core.Divider, {}, "".concat(item.key, "-divider"))];
|
|
436
434
|
})
|
|
437
435
|
})]
|
|
438
436
|
})]
|
|
@@ -3672,6 +3670,20 @@ var Tiles = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
3672
3670
|
});
|
|
3673
3671
|
if (process.env.NODE_ENV !== "production") Tiles.displayName = "Tiles";
|
|
3674
3672
|
|
|
3673
|
+
function ExitTransitionPlaceholder(_ref) {
|
|
3674
|
+
var {
|
|
3675
|
+
in: inProp,
|
|
3676
|
+
children: childrenProp
|
|
3677
|
+
} = _ref;
|
|
3678
|
+
var [children, setChildren] = React.useState(childrenProp);
|
|
3679
|
+
React.useEffect(() => {
|
|
3680
|
+
if (inProp) {
|
|
3681
|
+
setChildren(childrenProp);
|
|
3682
|
+
}
|
|
3683
|
+
}, [inProp, childrenProp]);
|
|
3684
|
+
return renderChildren(children);
|
|
3685
|
+
}
|
|
3686
|
+
|
|
3675
3687
|
exports.AdaptiveToolbar = AdaptiveToolbar;
|
|
3676
3688
|
exports.AdaptiveVerticalToolbar = AdaptiveVerticalToolbar;
|
|
3677
3689
|
exports.AvatarButton = AvatarButton;
|
|
@@ -3688,6 +3700,7 @@ exports.DrawerContent = DrawerContent;
|
|
|
3688
3700
|
exports.DrawerList = DrawerList;
|
|
3689
3701
|
exports.DrawerTitle = DrawerTitle;
|
|
3690
3702
|
exports.DropdownButton = DropdownButton;
|
|
3703
|
+
exports.ExitTransitionPlaceholder = ExitTransitionPlaceholder;
|
|
3691
3704
|
exports.GridStack = GridStack;
|
|
3692
3705
|
exports.InfoCard = InfoCard;
|
|
3693
3706
|
exports.Inline = Inline;
|