@gitlab/ui 58.5.1 → 58.6.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/CHANGELOG.md +7 -0
- package/dist/utility_classes.css +1 -1
- package/dist/utility_classes.css.map +1 -1
- package/package.json +1 -1
- package/src/components/base/button_group/button_group.stories.js +16 -4
- package/src/scss/utilities.scss +14 -0
- package/src/scss/utility-mixins/grid.scss +4 -0
- package/src/scss/utility-mixins/spacing.scss +4 -0
package/package.json
CHANGED
|
@@ -1,16 +1,22 @@
|
|
|
1
1
|
import GlButton from '../button/button.vue';
|
|
2
2
|
import GlDropdown from '../dropdown/dropdown.vue';
|
|
3
3
|
import GlDropdownItem from '../dropdown/dropdown_item.vue';
|
|
4
|
+
import { buttonSizeOptions } from '../../../utils/constants';
|
|
4
5
|
import GlButtonGroup from './button_group.vue';
|
|
5
6
|
import readme from './button_group.md';
|
|
6
7
|
|
|
7
|
-
const
|
|
8
|
+
const defaultValue = (prop) => GlButton.props[prop].default;
|
|
9
|
+
|
|
10
|
+
const generateProps = ({ vertical = false, size = defaultValue('size') } = {}) => ({
|
|
11
|
+
vertical,
|
|
12
|
+
size,
|
|
13
|
+
});
|
|
8
14
|
|
|
9
15
|
const template = `
|
|
10
16
|
<gl-button-group :vertical="vertical">
|
|
11
|
-
<gl-button>Button 1</gl-button>
|
|
12
|
-
<gl-button>Button 2</gl-button>
|
|
13
|
-
<gl-dropdown text="Some dropdown">
|
|
17
|
+
<gl-button :size="size">Button 1</gl-button>
|
|
18
|
+
<gl-button :size="size">Button 2</gl-button>
|
|
19
|
+
<gl-dropdown :size="size" text="Some dropdown">
|
|
14
20
|
<gl-dropdown-item>First item</gl-dropdown-item>
|
|
15
21
|
<gl-dropdown-item>Second item</gl-dropdown-item>
|
|
16
22
|
<gl-dropdown-item>Last item</gl-dropdown-item>
|
|
@@ -37,4 +43,10 @@ export default {
|
|
|
37
43
|
},
|
|
38
44
|
},
|
|
39
45
|
},
|
|
46
|
+
argTypes: {
|
|
47
|
+
size: {
|
|
48
|
+
options: Object.keys(buttonSizeOptions),
|
|
49
|
+
control: 'select',
|
|
50
|
+
},
|
|
51
|
+
},
|
|
40
52
|
};
|
package/src/scss/utilities.scss
CHANGED
|
@@ -3886,6 +3886,14 @@
|
|
|
3886
3886
|
}
|
|
3887
3887
|
}
|
|
3888
3888
|
|
|
3889
|
+
.gl-grid-template-columns-4 {
|
|
3890
|
+
grid-template-columns: 1fr 1fr 1fr 1fr;
|
|
3891
|
+
}
|
|
3892
|
+
|
|
3893
|
+
.gl-grid-template-columns-4\! {
|
|
3894
|
+
grid-template-columns: 1fr 1fr 1fr 1fr !important;
|
|
3895
|
+
}
|
|
3896
|
+
|
|
3889
3897
|
.gl-lg-grid-template-columns-4 {
|
|
3890
3898
|
@include gl-media-breakpoint-up(lg) {
|
|
3891
3899
|
grid-template-columns: repeat(4, 1fr);
|
|
@@ -6675,6 +6683,12 @@
|
|
|
6675
6683
|
.gl-gap-6\! {
|
|
6676
6684
|
gap: $gl-spacing-scale-6 !important;
|
|
6677
6685
|
}
|
|
6686
|
+
.gl-gap-7 {
|
|
6687
|
+
gap: $gl-spacing-scale-7;
|
|
6688
|
+
}
|
|
6689
|
+
.gl-gap-7\! {
|
|
6690
|
+
gap: $gl-spacing-scale-7 !important;
|
|
6691
|
+
}
|
|
6678
6692
|
.gl-column-gap-6 {
|
|
6679
6693
|
column-gap: $gl-spacing-scale-6;
|
|
6680
6694
|
}
|