@conduction/components 2.2.40 → 2.2.41
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/README.md +1 -0
- package/lib/components/displaySwitch/DisplaySwitch.js +1 -1
- package/lib/components/displaySwitch/DisplaySwitch.module.css +4 -0
- package/package.json +1 -1
- package/src/components/displaySwitch/DisplaySwitch.module.css +4 -0
- package/src/components/displaySwitch/DisplaySwitch.tsx +1 -0
package/README.md
CHANGED
|
@@ -7,7 +7,7 @@ const DisplaySwitch = ({ layoutClassName, buttons }) => {
|
|
|
7
7
|
return (_jsx(ButtonGroup, { className: clsx(styles.displaySwitchButtons, [layoutClassName] && layoutClassName), children: buttons.map((button, idx) => {
|
|
8
8
|
// TODO: Once the Rotterdam design system supports the "pressed" state,
|
|
9
9
|
// remove the `appereance` switch, and use the same appearance for each button.
|
|
10
|
-
return (_jsxs(Button, { pressed: button.pressed, appearance: button.pressed ? "secondary-action-button" : "subtle-button", onClick: button.handleClick, children: [button.icon && _jsx(FontAwesomeIcon, { icon: [button.icon.prefix, button.icon.name] }), _jsx("span", { children: button.label })] }, idx));
|
|
10
|
+
return (_jsxs(Button, { pressed: button.pressed, appearance: button.pressed ? "secondary-action-button" : "subtle-button", onClick: button.handleClick, className: styles.button, children: [button.icon && _jsx(FontAwesomeIcon, { icon: [button.icon.prefix, button.icon.name] }), _jsx("span", { children: button.label })] }, idx));
|
|
11
11
|
}) }));
|
|
12
12
|
};
|
|
13
13
|
export default DisplaySwitch;
|
package/package.json
CHANGED
|
@@ -35,6 +35,7 @@ const DisplaySwitch: React.FC<DisplaySwitchProps> = ({ layoutClassName, buttons
|
|
|
35
35
|
pressed={button.pressed}
|
|
36
36
|
appearance={button.pressed ? "secondary-action-button" : "subtle-button"}
|
|
37
37
|
onClick={button.handleClick}
|
|
38
|
+
className={styles.button}
|
|
38
39
|
>
|
|
39
40
|
{button.icon && <FontAwesomeIcon icon={[button.icon.prefix, button.icon.name]} />}
|
|
40
41
|
<span>{button.label}</span>
|