@gitlab/ui 54.2.2 → 54.2.3
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/components/base/new_dropdowns/disclosure/disclosure_dropdown.js +1 -1
- package/dist/components/base/new_dropdowns/disclosure/mock_data.js +2 -2
- package/package.json +4 -4
- package/src/components/base/new_dropdowns/disclosure/disclosure_dropdown.stories.js +2 -2
- package/src/components/base/new_dropdowns/disclosure/disclosure_dropdown.vue +1 -0
- package/src/components/base/new_dropdowns/disclosure/mock_data.js +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,10 @@
|
|
|
1
|
+
## [54.2.3](https://gitlab.com/gitlab-org/gitlab-ui/compare/v54.2.2...v54.2.3) (2023-01-31)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* **GlDisclosureDropdown:** pass `item` object to the item component ([d393007](https://gitlab.com/gitlab-org/gitlab-ui/commit/d3930078bc4d407928d1a4c07092f7a3211fe8b9))
|
|
7
|
+
|
|
1
8
|
## [54.2.2](https://gitlab.com/gitlab-org/gitlab-ui/compare/v54.2.1...v54.2.2) (2023-01-31)
|
|
2
9
|
|
|
3
10
|
|
|
@@ -265,7 +265,7 @@ var script = {
|
|
|
265
265
|
const __vue_script__ = script;
|
|
266
266
|
|
|
267
267
|
/* template */
|
|
268
|
-
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('gl-base-dropdown',{ref:"baseDropdown",staticClass:"gl-disclosure-dropdown",attrs:{"aria-labelledby":_vm.toggleAriaLabelledBy,"toggle-id":_vm.toggleId,"toggle-text":_vm.toggleText,"toggle-class":_vm.toggleClass,"text-sr-only":_vm.textSrOnly,"category":_vm.category,"variant":_vm.variant,"size":_vm.size,"icon":_vm.icon,"disabled":_vm.disabled,"loading":_vm.loading,"no-caret":_vm.noCaret,"placement":_vm.placement},on:_vm._d({},[_vm.$options.events.GL_DROPDOWN_SHOWN,_vm.onShow,_vm.$options.events.GL_DROPDOWN_HIDDEN,_vm.onHide]),scopedSlots:_vm._u([(_vm.hasCustomToggle)?{key:"toggle",fn:function(){return [_vm._t("toggle")]},proxy:true}:null],null,true)},[_vm._v(" "),_vm._t("header"),_vm._v(" "),_c(_vm.disclosureOptions.tag,{ref:"content",tag:"component",staticClass:"gl-new-dropdown-contents",attrs:{"id":_vm.disclosureId,"role":_vm.disclosureOptions.role,"aria-labelledby":_vm.listAriaLabelledBy || _vm.toggleId,"data-testid":"disclosure-content","tabindex":"-1"},on:{"keydown":_vm.onKeydown}},[_vm._t("default",function(){return [_vm._l((_vm.items),function(item,index){return [(_vm.isItem(item))?[_c('gl-disclosure-dropdown-item',{key:item.text,attrs:{"item":item},on:{"action":_vm.handleAction}},[_vm._t("list-item",null,{"item":item})],2)]:[_c('gl-disclosure-dropdown-group',{key:item.name,attrs:{"bordered":index !== 0,"group":item},on:{"action":_vm.handleAction},scopedSlots:_vm._u([(_vm.$scopedSlots['group-label'])?{key:"group-label",fn:function(){return [_vm._t("group-label",null,{"group":item})]},proxy:true}:null],null,true)},[_vm._v(" "),(_vm.$scopedSlots['list-item'])?_vm._l((item.items),function(groupItem){return _c('gl-disclosure-dropdown-item',{key:groupItem.text,on:{"action":_vm.handleAction}},[_vm._t("list-item",null,{"item":groupItem})],2)}):_vm._e()],2)]]})]})],2),_vm._v(" "),_vm._t("footer")],2)};
|
|
268
|
+
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('gl-base-dropdown',{ref:"baseDropdown",staticClass:"gl-disclosure-dropdown",attrs:{"aria-labelledby":_vm.toggleAriaLabelledBy,"toggle-id":_vm.toggleId,"toggle-text":_vm.toggleText,"toggle-class":_vm.toggleClass,"text-sr-only":_vm.textSrOnly,"category":_vm.category,"variant":_vm.variant,"size":_vm.size,"icon":_vm.icon,"disabled":_vm.disabled,"loading":_vm.loading,"no-caret":_vm.noCaret,"placement":_vm.placement},on:_vm._d({},[_vm.$options.events.GL_DROPDOWN_SHOWN,_vm.onShow,_vm.$options.events.GL_DROPDOWN_HIDDEN,_vm.onHide]),scopedSlots:_vm._u([(_vm.hasCustomToggle)?{key:"toggle",fn:function(){return [_vm._t("toggle")]},proxy:true}:null],null,true)},[_vm._v(" "),_vm._t("header"),_vm._v(" "),_c(_vm.disclosureOptions.tag,{ref:"content",tag:"component",staticClass:"gl-new-dropdown-contents",attrs:{"id":_vm.disclosureId,"role":_vm.disclosureOptions.role,"aria-labelledby":_vm.listAriaLabelledBy || _vm.toggleId,"data-testid":"disclosure-content","tabindex":"-1"},on:{"keydown":_vm.onKeydown}},[_vm._t("default",function(){return [_vm._l((_vm.items),function(item,index){return [(_vm.isItem(item))?[_c('gl-disclosure-dropdown-item',{key:item.text,attrs:{"item":item},on:{"action":_vm.handleAction}},[_vm._t("list-item",null,{"item":item})],2)]:[_c('gl-disclosure-dropdown-group',{key:item.name,attrs:{"bordered":index !== 0,"group":item},on:{"action":_vm.handleAction},scopedSlots:_vm._u([(_vm.$scopedSlots['group-label'])?{key:"group-label",fn:function(){return [_vm._t("group-label",null,{"group":item})]},proxy:true}:null],null,true)},[_vm._v(" "),(_vm.$scopedSlots['list-item'])?_vm._l((item.items),function(groupItem){return _c('gl-disclosure-dropdown-item',{key:groupItem.text,attrs:{"item":groupItem},on:{"action":_vm.handleAction}},[_vm._t("list-item",null,{"item":groupItem})],2)}):_vm._e()],2)]]})]})],2),_vm._v(" "),_vm._t("footer")],2)};
|
|
269
269
|
var __vue_staticRenderFns__ = [];
|
|
270
270
|
|
|
271
271
|
/* style */
|
|
@@ -27,7 +27,7 @@ const mockItems = [{
|
|
|
27
27
|
}];
|
|
28
28
|
const mockItemsCustomItem = [{
|
|
29
29
|
text: 'Assigned to you',
|
|
30
|
-
href: 'https://gitlab.com/dashboard/merge_requests',
|
|
30
|
+
href: 'https://gitlab.com/dashboard/merge_requests?assignee_username=root',
|
|
31
31
|
count: '2',
|
|
32
32
|
extraAttrs: {
|
|
33
33
|
target: '_blank',
|
|
@@ -35,7 +35,7 @@ const mockItemsCustomItem = [{
|
|
|
35
35
|
}
|
|
36
36
|
}, {
|
|
37
37
|
text: 'Review requests from you',
|
|
38
|
-
href: 'https://gitlab.com/dashboard/merge_requests',
|
|
38
|
+
href: 'https://gitlab.com/dashboard/merge_requests?reviewer_username=root',
|
|
39
39
|
count: 0,
|
|
40
40
|
extraAttrs: {
|
|
41
41
|
target: '_blank',
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gitlab/ui",
|
|
3
|
-
"version": "54.2.
|
|
3
|
+
"version": "54.2.3",
|
|
4
4
|
"description": "GitLab UI Components",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -123,9 +123,9 @@
|
|
|
123
123
|
"glob": "^7.2.0",
|
|
124
124
|
"identity-obj-proxy": "^3.0.0",
|
|
125
125
|
"inquirer-select-directory": "^1.2.0",
|
|
126
|
-
"jest": "^29.4.
|
|
127
|
-
"jest-circus": "29.4.
|
|
128
|
-
"jest-environment-jsdom": "29.4.
|
|
126
|
+
"jest": "^29.4.1",
|
|
127
|
+
"jest-circus": "29.4.1",
|
|
128
|
+
"jest-environment-jsdom": "29.4.1",
|
|
129
129
|
"markdownlint-cli": "^0.29.0",
|
|
130
130
|
"mockdate": "^2.0.5",
|
|
131
131
|
"npm-run-all": "^4.1.5",
|
|
@@ -147,7 +147,7 @@ export const CustomListItem = (args, { argTypes }) => ({
|
|
|
147
147
|
template: template(
|
|
148
148
|
`
|
|
149
149
|
<template #list-item="{ item }">
|
|
150
|
-
<a ref="link" class="gl-display-flex gl-align-items-center gl-justify-content-space-between gl-hover-text-gray-900 gl-hover-text-decoration-none gl-text-gray-900" :href="item.href" v-bind="item.extraAttrs">
|
|
150
|
+
<a tabindex="-1" ref="link" class="gl-display-flex gl-align-items-center gl-justify-content-space-between gl-hover-text-gray-900 gl-hover-text-decoration-none gl-text-gray-900" :href="item.href" v-bind="item.extraAttrs">
|
|
151
151
|
{{ item.text }}
|
|
152
152
|
<gl-badge pill size="sm" variant="neutral">{{ item.count }}</gl-badge>
|
|
153
153
|
</a>
|
|
@@ -231,7 +231,7 @@ export const CustomGroupsAndItems = (args, { argTypes }) => ({
|
|
|
231
231
|
{{ group.name }} <gl-badge pill size="sm" variant="neutral">{{ getTotalMrs(group.items) }}</gl-badge>
|
|
232
232
|
</template>
|
|
233
233
|
<template #list-item="{ item }">
|
|
234
|
-
<a
|
|
234
|
+
<a tabindex="-1" ref="link" class="gl-display-flex gl-align-items-center gl-justify-content-space-between gl-hover-text-gray-900 gl-hover-text-decoration-none gl-text-gray-900" :href="item.href" v-bind="item.extraAttrs">
|
|
235
235
|
{{ item.text }}
|
|
236
236
|
<gl-badge pill size="sm" variant="neutral">{{ item.count }}</gl-badge>
|
|
237
237
|
</a>
|
|
@@ -33,7 +33,7 @@ export const mockItems = [
|
|
|
33
33
|
export const mockItemsCustomItem = [
|
|
34
34
|
{
|
|
35
35
|
text: 'Assigned to you',
|
|
36
|
-
href: 'https://gitlab.com/dashboard/merge_requests',
|
|
36
|
+
href: 'https://gitlab.com/dashboard/merge_requests?assignee_username=root',
|
|
37
37
|
count: '2',
|
|
38
38
|
extraAttrs: {
|
|
39
39
|
target: '_blank',
|
|
@@ -42,7 +42,7 @@ export const mockItemsCustomItem = [
|
|
|
42
42
|
},
|
|
43
43
|
{
|
|
44
44
|
text: 'Review requests from you',
|
|
45
|
-
href: 'https://gitlab.com/dashboard/merge_requests',
|
|
45
|
+
href: 'https://gitlab.com/dashboard/merge_requests?reviewer_username=root',
|
|
46
46
|
count: 0,
|
|
47
47
|
extraAttrs: {
|
|
48
48
|
target: '_blank',
|