@homebound/beam 2.225.0 → 2.225.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.
|
@@ -12,7 +12,9 @@ const defaultTestId_1 = require("../utils/defaultTestId");
|
|
|
12
12
|
function ButtonGroup(props) {
|
|
13
13
|
const { buttons, disabled = false, size = "sm" } = props;
|
|
14
14
|
const tid = (0, utils_1.useTestIds)(props, "buttonGroup");
|
|
15
|
-
return (
|
|
15
|
+
return (
|
|
16
|
+
// Adding `line-height: 0` prevent inheriting line-heights that might throw off sizing within the button group.
|
|
17
|
+
(0, jsx_runtime_1.jsx)("div", Object.assign({}, tid, { css: Css_1.Css.df.lh(0).add(sizeStyles[size]).$ }, { children: buttons.map(({ disabled: buttonDisabled, ...buttonProps }, i) => (
|
|
16
18
|
// Disable the button if the ButtonGroup is disabled or if the current button is disabled.
|
|
17
19
|
(0, jsx_runtime_1.jsx)(GroupButton, Object.assign({}, buttonProps, { disabled: disabled || buttonDisabled, size: size }, tid), i))) }), void 0));
|
|
18
20
|
}
|