@spaced-out/ui-design-system 0.0.18-beta.0 → 0.0.18-beta.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/CHANGELOG.md +7 -0
- package/lib/components/ButtonDropdown/ButtonDropdown.js +8 -2
- package/lib/components/ButtonDropdown/ButtonDropdown.js.flow +6 -1
- package/lib/components/ButtonDropdown/ButtonDropdown.module.css +3 -1
- package/lib/components/SideMenuLink/SideMenuLink.module.css +0 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
+
### [0.0.18-beta.1](https://github.com/spaced-out/ui-design-system/compare/v0.0.18-beta.0...v0.0.18-beta.1) (2023-02-02)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### Bug Fixes
|
|
9
|
+
|
|
10
|
+
* buttondropdown doc and fluid fix ([#54](https://github.com/spaced-out/ui-design-system/issues/54)) ([b18aaeb](https://github.com/spaced-out/ui-design-system/commit/b18aaeb64dcc33d420d932960a8270af5b803105))
|
|
11
|
+
|
|
5
12
|
### [0.0.18-beta.0](https://github.com/spaced-out/ui-design-system/compare/v0.0.17...v0.0.18-beta.0) (2023-02-01)
|
|
6
13
|
|
|
7
14
|
### [0.0.17](https://github.com/spaced-out/ui-design-system/compare/v0.0.16...v0.0.17) (2023-02-01)
|
|
@@ -39,6 +39,7 @@ const ButtonDropdown = _ref => {
|
|
|
39
39
|
children,
|
|
40
40
|
iconRightName,
|
|
41
41
|
iconRightType,
|
|
42
|
+
isFluid,
|
|
42
43
|
...restButtonProps
|
|
43
44
|
} = _ref;
|
|
44
45
|
const menuBtnRef = React.useRef();
|
|
@@ -68,7 +69,9 @@ const ButtonDropdown = _ref => {
|
|
|
68
69
|
} = _ref2;
|
|
69
70
|
return /*#__PURE__*/React.createElement("div", {
|
|
70
71
|
"data-testid": "ButtonDropdown",
|
|
71
|
-
className: (0, _classify.classify)(_ButtonDropdownModule.default.buttonDropdownContainer,
|
|
72
|
+
className: (0, _classify.classify)(_ButtonDropdownModule.default.buttonDropdownContainer, {
|
|
73
|
+
[_ButtonDropdownModule.default.isFluid]: isFluid === true
|
|
74
|
+
}, classNames?.dropdownContainer),
|
|
72
75
|
ref: menuBtnRef
|
|
73
76
|
}, /*#__PURE__*/React.createElement(_Button.Button, _extends({}, restButtonProps, {
|
|
74
77
|
iconRightName: children ? isOpen ? 'caret-up' : 'caret-down' : iconRightName ? iconRightName : isOpen ? 'caret-up' : 'caret-down',
|
|
@@ -80,6 +83,7 @@ const ButtonDropdown = _ref => {
|
|
|
80
83
|
e.stopPropagation();
|
|
81
84
|
onOpen();
|
|
82
85
|
},
|
|
86
|
+
isFluid: isFluid,
|
|
83
87
|
classNames: {
|
|
84
88
|
wrapper: classNames?.buttonWrapper
|
|
85
89
|
}
|
|
@@ -91,7 +95,9 @@ const ButtonDropdown = _ref => {
|
|
|
91
95
|
position: strategy,
|
|
92
96
|
top: y ?? _space.spaceNone,
|
|
93
97
|
left: x ?? _space.spaceNone,
|
|
94
|
-
|
|
98
|
+
...(isFluid && {
|
|
99
|
+
width: _size.sizeFluid
|
|
100
|
+
})
|
|
95
101
|
}
|
|
96
102
|
}, /*#__PURE__*/React.createElement(_Menu.Menu, _extends({}, menu, {
|
|
97
103
|
onSelect: option => {
|
|
@@ -64,6 +64,7 @@ export const ButtonDropdown = ({
|
|
|
64
64
|
children,
|
|
65
65
|
iconRightName,
|
|
66
66
|
iconRightType,
|
|
67
|
+
isFluid,
|
|
67
68
|
...restButtonProps
|
|
68
69
|
}: ButtonDropdownProps): React.Node => {
|
|
69
70
|
const menuBtnRef = React.useRef();
|
|
@@ -85,6 +86,9 @@ export const ButtonDropdown = ({
|
|
|
85
86
|
data-testid="ButtonDropdown"
|
|
86
87
|
className={classify(
|
|
87
88
|
css.buttonDropdownContainer,
|
|
89
|
+
{
|
|
90
|
+
[css.isFluid]: isFluid === true,
|
|
91
|
+
},
|
|
88
92
|
classNames?.dropdownContainer,
|
|
89
93
|
)}
|
|
90
94
|
ref={menuBtnRef}
|
|
@@ -110,6 +114,7 @@ export const ButtonDropdown = ({
|
|
|
110
114
|
e.stopPropagation();
|
|
111
115
|
onOpen();
|
|
112
116
|
}}
|
|
117
|
+
isFluid={isFluid}
|
|
113
118
|
classNames={{wrapper: classNames?.buttonWrapper}}
|
|
114
119
|
>
|
|
115
120
|
{children}
|
|
@@ -123,7 +128,7 @@ export const ButtonDropdown = ({
|
|
|
123
128
|
position: strategy,
|
|
124
129
|
top: y ?? spaceNone,
|
|
125
130
|
left: x ?? spaceNone,
|
|
126
|
-
width: sizeFluid,
|
|
131
|
+
...(isFluid && {width: sizeFluid}),
|
|
127
132
|
}}
|
|
128
133
|
>
|
|
129
134
|
<Menu
|