@gitlab/ui 52.10.0 → 52.12.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 +14 -0
- package/dist/components/base/new_dropdowns/base_dropdown/base_dropdown.js +23 -5
- package/dist/components/base/new_dropdowns/disclosure/disclosure_dropdown.js +291 -0
- package/dist/components/base/new_dropdowns/disclosure/disclosure_dropdown_group.js +90 -0
- package/dist/components/base/new_dropdowns/disclosure/disclosure_dropdown_item.js +107 -0
- package/dist/components/base/new_dropdowns/disclosure/mock_data.js +128 -0
- package/dist/components/base/new_dropdowns/disclosure/utils.js +15 -0
- package/dist/components/base/new_dropdowns/listbox/listbox.js +4 -4
- package/dist/components/base/new_dropdowns/listbox/listbox_group.js +1 -1
- package/dist/components/base/new_dropdowns/listbox/listbox_item.js +1 -1
- package/dist/components/regions/empty_state/empty_state.js +12 -1
- package/dist/index.css +2 -2
- package/dist/index.css.map +1 -1
- package/dist/index.js +3 -0
- package/package.json +3 -3
- package/src/components/base/new_dropdowns/base_dropdown/base_dropdown.spec.js +3 -3
- package/src/components/base/new_dropdowns/base_dropdown/base_dropdown.vue +21 -3
- package/src/components/base/new_dropdowns/disclosure/disclosure_dropdown.md +114 -0
- package/src/components/base/new_dropdowns/disclosure/disclosure_dropdown.scss +7 -0
- package/src/components/base/new_dropdowns/disclosure/disclosure_dropdown.spec.js +210 -0
- package/src/components/base/new_dropdowns/disclosure/disclosure_dropdown.stories.js +306 -0
- package/src/components/base/new_dropdowns/disclosure/disclosure_dropdown.vue +342 -0
- package/src/components/base/new_dropdowns/disclosure/disclosure_dropdown_group.spec.js +82 -0
- package/src/components/base/new_dropdowns/disclosure/disclosure_dropdown_group.vue +77 -0
- package/src/components/base/new_dropdowns/disclosure/disclosure_dropdown_item.spec.js +94 -0
- package/src/components/base/new_dropdowns/disclosure/disclosure_dropdown_item.vue +98 -0
- package/src/components/base/new_dropdowns/disclosure/mock_data.js +156 -0
- package/src/components/base/new_dropdowns/disclosure/utils.js +18 -0
- package/src/components/base/new_dropdowns/disclosure/utils.spec.js +73 -0
- package/src/components/base/new_dropdowns/dropdown.scss +6 -0
- package/src/components/base/new_dropdowns/listbox/listbox.scss +0 -6
- package/src/components/base/new_dropdowns/listbox/listbox.vue +4 -4
- package/src/components/base/new_dropdowns/listbox/listbox_group.vue +1 -1
- package/src/components/base/new_dropdowns/listbox/listbox_item.vue +1 -1
- package/src/components/regions/empty_state/empty_state.spec.js +35 -0
- package/src/components/regions/empty_state/empty_state.stories.js +5 -0
- package/src/components/regions/empty_state/empty_state.vue +15 -1
- package/src/index.js +3 -0
- package/src/scss/components.scss +2 -0
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
const mockItems = [{
|
|
2
|
+
text: 'Mark as draft',
|
|
3
|
+
href: 'https://gitlab.com',
|
|
4
|
+
extraAttrs: {
|
|
5
|
+
target: '_blank',
|
|
6
|
+
rel: 'nofollow',
|
|
7
|
+
'data-method': 'put'
|
|
8
|
+
}
|
|
9
|
+
}, {
|
|
10
|
+
text: 'Close merge request',
|
|
11
|
+
action: () => {
|
|
12
|
+
// eslint-disable-next-line no-console
|
|
13
|
+
console.log('CLOSED');
|
|
14
|
+
},
|
|
15
|
+
extraAttrs: {
|
|
16
|
+
class: 'gl-text-red-500!',
|
|
17
|
+
rel: 'nofollow',
|
|
18
|
+
'data-method': 'put'
|
|
19
|
+
}
|
|
20
|
+
}, {
|
|
21
|
+
text: 'Create new',
|
|
22
|
+
href: 'https://gitlab.com/gitlab-org/gitlab/-/merge_requests/new',
|
|
23
|
+
extraAttrs: {
|
|
24
|
+
rel: 'nofollow',
|
|
25
|
+
target: '_blank'
|
|
26
|
+
}
|
|
27
|
+
}];
|
|
28
|
+
const mockItemsCustomItem = [{
|
|
29
|
+
text: 'Assigned to you',
|
|
30
|
+
href: 'https://gitlab.com/dashboard/merge_requests',
|
|
31
|
+
count: '2',
|
|
32
|
+
extraAttrs: {
|
|
33
|
+
target: '_blank',
|
|
34
|
+
rel: 'nofollow'
|
|
35
|
+
}
|
|
36
|
+
}, {
|
|
37
|
+
text: 'Review requests from you',
|
|
38
|
+
href: 'https://gitlab.com/dashboard/merge_requests',
|
|
39
|
+
count: 0,
|
|
40
|
+
extraAttrs: {
|
|
41
|
+
target: '_blank',
|
|
42
|
+
rel: 'nofollow'
|
|
43
|
+
}
|
|
44
|
+
}];
|
|
45
|
+
const mockGroups = [{
|
|
46
|
+
name: 'This project',
|
|
47
|
+
items: [{
|
|
48
|
+
text: 'New issue',
|
|
49
|
+
href: 'https://gitlab.com/gitlab-org/gitlab/-/issues/new',
|
|
50
|
+
extraAttrs: {
|
|
51
|
+
target: '_blank',
|
|
52
|
+
rel: 'nofollow'
|
|
53
|
+
}
|
|
54
|
+
}, {
|
|
55
|
+
text: 'New merge request',
|
|
56
|
+
href: 'https://gitlab.com/gitlab-org/gitlab/-/merge_requests/new',
|
|
57
|
+
extraAttrs: {
|
|
58
|
+
target: '_blank',
|
|
59
|
+
rel: 'nofollow'
|
|
60
|
+
}
|
|
61
|
+
}, {
|
|
62
|
+
text: 'New snippet',
|
|
63
|
+
href: 'https://gitlab.com/gitlab-org/gitlab/-/snippets/new',
|
|
64
|
+
extraAttrs: {
|
|
65
|
+
target: '_blank',
|
|
66
|
+
rel: 'nofollow'
|
|
67
|
+
}
|
|
68
|
+
}]
|
|
69
|
+
}, {
|
|
70
|
+
name: 'GitLab',
|
|
71
|
+
items: [{
|
|
72
|
+
text: 'New project',
|
|
73
|
+
href: 'https://gitlab.com/projects/new',
|
|
74
|
+
extraAttrs: {
|
|
75
|
+
target: '_blank',
|
|
76
|
+
rel: 'nofollow'
|
|
77
|
+
}
|
|
78
|
+
}, {
|
|
79
|
+
text: 'New group',
|
|
80
|
+
href: 'https://gitlab.com/groups/new',
|
|
81
|
+
extraAttrs: {
|
|
82
|
+
target: '_blank',
|
|
83
|
+
rel: 'nofollow'
|
|
84
|
+
}
|
|
85
|
+
}, {
|
|
86
|
+
text: 'New snippet',
|
|
87
|
+
href: 'https://gitlab.com/snippets/new',
|
|
88
|
+
extraAttrs: {
|
|
89
|
+
target: '_blank',
|
|
90
|
+
rel: 'nofollow'
|
|
91
|
+
}
|
|
92
|
+
}]
|
|
93
|
+
}];
|
|
94
|
+
const mockProfileGroups = [{
|
|
95
|
+
items: [{
|
|
96
|
+
text: 'Set status',
|
|
97
|
+
href: 'https://gitlab.com',
|
|
98
|
+
icon: 'status_success',
|
|
99
|
+
extraAttrs: {
|
|
100
|
+
target: '_blank',
|
|
101
|
+
rel: 'nofollow'
|
|
102
|
+
}
|
|
103
|
+
}, {
|
|
104
|
+
text: 'Edit profile',
|
|
105
|
+
href: '#',
|
|
106
|
+
extraAttrs: {
|
|
107
|
+
target: '_blank',
|
|
108
|
+
rel: 'nofollow'
|
|
109
|
+
}
|
|
110
|
+
}, {
|
|
111
|
+
text: 'Preferences',
|
|
112
|
+
href: '#',
|
|
113
|
+
extraAttrs: {
|
|
114
|
+
target: '_blank',
|
|
115
|
+
rel: 'nofollow'
|
|
116
|
+
}
|
|
117
|
+
}]
|
|
118
|
+
}, {
|
|
119
|
+
items: [{
|
|
120
|
+
text: 'Sign out',
|
|
121
|
+
action: () => {
|
|
122
|
+
// eslint-disable-next-line no-alert
|
|
123
|
+
window.confirm('Are you sure?');
|
|
124
|
+
}
|
|
125
|
+
}]
|
|
126
|
+
}];
|
|
127
|
+
|
|
128
|
+
export { mockGroups, mockItems, mockItemsCustomItem, mockProfileGroups };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
const itemValidator = _ref => {
|
|
2
|
+
let {
|
|
3
|
+
text,
|
|
4
|
+
href,
|
|
5
|
+
action
|
|
6
|
+
} = _ref;
|
|
7
|
+
return Boolean((text === null || text === void 0 ? void 0 : text.length) && ((href === null || href === void 0 ? void 0 : href.length) || typeof action === 'function'));
|
|
8
|
+
};
|
|
9
|
+
const isItem = item => Boolean(item) && itemValidator(item);
|
|
10
|
+
const isGroup = group => Boolean(group) && Array.isArray(group.items) && Boolean(group.items.length) && group.items.every(isItem);
|
|
11
|
+
const itemsValidator = items => items.every(isItem) || items.every(isGroup);
|
|
12
|
+
const isAllItems = items => items.every(isItem);
|
|
13
|
+
const isAllGroups = items => items.every(isGroup);
|
|
14
|
+
|
|
15
|
+
export { isAllGroups, isAllItems, isGroup, isItem, itemsValidator };
|
|
@@ -93,7 +93,7 @@ var script = {
|
|
|
93
93
|
type: String,
|
|
94
94
|
required: false,
|
|
95
95
|
default: buttonCategoryOptions.primary,
|
|
96
|
-
validator: value =>
|
|
96
|
+
validator: value => value in buttonCategoryOptions
|
|
97
97
|
},
|
|
98
98
|
/**
|
|
99
99
|
* Styling option - dropdown's toggle variant
|
|
@@ -102,7 +102,7 @@ var script = {
|
|
|
102
102
|
type: String,
|
|
103
103
|
required: false,
|
|
104
104
|
default: dropdownVariantOptions.default,
|
|
105
|
-
validator: value =>
|
|
105
|
+
validator: value => value in dropdownVariantOptions
|
|
106
106
|
},
|
|
107
107
|
/**
|
|
108
108
|
* The size of the dropdown toggle
|
|
@@ -111,7 +111,7 @@ var script = {
|
|
|
111
111
|
type: String,
|
|
112
112
|
required: false,
|
|
113
113
|
default: 'medium',
|
|
114
|
-
validator: value =>
|
|
114
|
+
validator: value => value in buttonSizeOptions
|
|
115
115
|
},
|
|
116
116
|
/**
|
|
117
117
|
* Icon name that will be rendered in the toggle button
|
|
@@ -527,7 +527,7 @@ var script = {
|
|
|
527
527
|
const __vue_script__ = script;
|
|
528
528
|
|
|
529
529
|
/* template */
|
|
530
|
-
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('gl-base-dropdown',{ref:"baseDropdown",attrs:{"aria-haspopup":"listbox","aria-labelledby":_vm.toggleAriaLabelledBy,"toggle-id":_vm.toggleId,"toggle-text":_vm.listboxToggleText,"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,"right":_vm.right},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.headerText)?_c('div',{staticClass:"gl-display-flex gl-align-items-center gl-p-4! gl-min-h-8",class:_vm.$options.HEADER_ITEMS_BORDER_CLASSES},[_c('div',{staticClass:"gl-flex-grow-1 gl-font-weight-bold gl-font-sm gl-pr-2",attrs:{"id":_vm.headerId,"data-testid":"listbox-header-text"}},[_vm._v("\n "+_vm._s(_vm.headerText)+"\n ")]),_vm._v(" "),(_vm.showResetButton)?_c('gl-button',{staticClass:"gl-focus-inset-border-2-blue-400! gl-flex-shrink-0 gl-font-sm! gl-px-2! gl-py-2!",attrs:{"category":"tertiary","data-testid":"listbox-reset-button"},on:{"click":_vm.onResetButtonClicked}},[_vm._v("\n "+_vm._s(_vm.resetButtonLabel)+"\n ")]):_vm._e()],1):_vm._e(),_vm._v(" "),(_vm.searchable)?_c('div',{class:_vm.$options.HEADER_ITEMS_BORDER_CLASSES},[_c('gl-listbox-search-input',{ref:"searchBox",attrs:{"aria-owns":_vm.listboxId,"data-testid":"listbox-search-input","placeholder":_vm.searchPlaceholder},on:{"input":_vm.search,"keydown":_vm.onKeydown},model:{value:(_vm.searchStr),callback:function ($$v) {_vm.searchStr=$$v;},expression:"searchStr"}}),_vm._v(" "),(_vm.searching)?_c('gl-loading-icon',{staticClass:"gl-my-3",attrs:{"data-testid":"listbox-search-loader","size":"md"}}):_vm._e()],1):_vm._e(),_vm._v(" "),(_vm.showList)?_c(_vm.listboxTag,{ref:"list",tag:"component",staticClass:"gl-dropdown-contents gl-list-style-none gl-pl-0 gl-mb-0",attrs:{"id":
|
|
530
|
+
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('gl-base-dropdown',{ref:"baseDropdown",attrs:{"aria-haspopup":"listbox","aria-labelledby":_vm.toggleAriaLabelledBy,"toggle-id":_vm.toggleId,"toggle-text":_vm.listboxToggleText,"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,"right":_vm.right},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.headerText)?_c('div',{staticClass:"gl-display-flex gl-align-items-center gl-p-4! gl-min-h-8",class:_vm.$options.HEADER_ITEMS_BORDER_CLASSES},[_c('div',{staticClass:"gl-flex-grow-1 gl-font-weight-bold gl-font-sm gl-pr-2",attrs:{"id":_vm.headerId,"data-testid":"listbox-header-text"}},[_vm._v("\n "+_vm._s(_vm.headerText)+"\n ")]),_vm._v(" "),(_vm.showResetButton)?_c('gl-button',{staticClass:"gl-focus-inset-border-2-blue-400! gl-flex-shrink-0 gl-font-sm! gl-px-2! gl-py-2!",attrs:{"category":"tertiary","data-testid":"listbox-reset-button"},on:{"click":_vm.onResetButtonClicked}},[_vm._v("\n "+_vm._s(_vm.resetButtonLabel)+"\n ")]):_vm._e()],1):_vm._e(),_vm._v(" "),(_vm.searchable)?_c('div',{class:_vm.$options.HEADER_ITEMS_BORDER_CLASSES},[_c('gl-listbox-search-input',{ref:"searchBox",attrs:{"aria-owns":_vm.listboxId,"data-testid":"listbox-search-input","placeholder":_vm.searchPlaceholder},on:{"input":_vm.search,"keydown":_vm.onKeydown},model:{value:(_vm.searchStr),callback:function ($$v) {_vm.searchStr=$$v;},expression:"searchStr"}}),_vm._v(" "),(_vm.searching)?_c('gl-loading-icon',{staticClass:"gl-my-3",attrs:{"data-testid":"listbox-search-loader","size":"md"}}):_vm._e()],1):_vm._e(),_vm._v(" "),(_vm.showList)?_c(_vm.listboxTag,{ref:"list",tag:"component",staticClass:"gl-dropdown-contents gl-list-style-none gl-pl-0 gl-mb-0",attrs:{"id":_vm.listboxId,"aria-labelledby":_vm.listAriaLabelledBy || _vm.headerId || _vm.toggleId,"role":"listbox","tabindex":"-1"},on:{"keydown":_vm.onKeydown}},[_vm._l((_vm.items),function(item,index){return [(_vm.isOption(item))?[_c('gl-listbox-item',_vm._b({key:item.value,attrs:{"data-testid":("listbox-item-" + (item.value)),"is-selected":_vm.isSelected(item),"is-focused":_vm.isFocused(item),"is-check-centered":_vm.isCheckCentered},on:{"select":function($event){return _vm.onSelect(item, $event)}}},'gl-listbox-item',_vm.listboxItemMoreItemsAriaAttributes(index),false),[_vm._t("list-item",function(){return [_vm._v("\n "+_vm._s(item.text)+"\n ")]},{"item":item})],2)]:[_c('gl-listbox-group',{key:item.text,class:_vm.groupClasses(index),attrs:{"name":item.text},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._l((item.options),function(option){return _c('gl-listbox-item',{key:option.value,attrs:{"data-testid":("listbox-item-" + (option.value)),"is-selected":_vm.isSelected(option),"is-focused":_vm.isFocused(option),"is-check-centered":_vm.isCheckCentered},on:{"select":function($event){return _vm.onSelect(option, $event)}}},[_vm._t("list-item",function(){return [_vm._v("\n "+_vm._s(option.text)+"\n ")]},{"item":option})],2)})],2)]]}),_vm._v(" "),(_vm.infiniteScrollLoading)?_c(_vm.listboxTag === 'ul' ? 'li' : 'div',{tag:"component"},[_c('gl-loading-icon',{staticClass:"gl-my-3",attrs:{"data-testid":"listbox-infinite-scroll-loader","size":"md"}})],1):_vm._e(),_vm._v(" "),(_vm.showIntersectionObserver)?_c('gl-intersection-observer',{on:{"appear":_vm.onIntersectionObserverAppear}}):_vm._e()],2):_vm._e(),_vm._v(" "),(_vm.announceSRSearchResults)?_c('span',{staticClass:"gl-sr-only",attrs:{"data-testid":"listbox-number-of-results","aria-live":"assertive"}},[_vm._t("search-summary-sr-only")],2):(_vm.showNoResultsText)?_c('div',{staticClass:"gl-pl-7 gl-pr-5 gl-pt-3 gl-font-base gl-text-gray-600",attrs:{"aria-live":"assertive","data-testid":"listbox-no-results-text"}},[_vm._v("\n "+_vm._s(_vm.noResultsText)+"\n ")]):_vm._e(),_vm._v(" "),_vm._t("footer")],2)};
|
|
531
531
|
var __vue_staticRenderFns__ = [];
|
|
532
532
|
|
|
533
533
|
/* style */
|
|
@@ -17,7 +17,7 @@ var script = {
|
|
|
17
17
|
const __vue_script__ = script;
|
|
18
18
|
|
|
19
19
|
/* template */
|
|
20
|
-
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('ul',{staticClass:"gl-mb-0 gl-pl-0 gl-list-style-none",attrs:{"role":"group","aria-labelledby":_vm.nameId}},[_c('li',{staticClass:"gl-pl-5! gl-py-2! gl-font-
|
|
20
|
+
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('ul',{staticClass:"gl-mb-0 gl-pl-0 gl-list-style-none",attrs:{"role":"group","aria-labelledby":_vm.nameId}},[_c('li',{staticClass:"gl-pl-5! gl-py-2! gl-font-sm gl-font-weight-bold",attrs:{"id":_vm.nameId,"role":"presentation"}},[_vm._t("group-label",function(){return [_vm._v(_vm._s(_vm.name))]})],2),_vm._v(" "),_vm._t("default")],2)};
|
|
21
21
|
var __vue_staticRenderFns__ = [];
|
|
22
22
|
|
|
23
23
|
/* style */
|
|
@@ -52,7 +52,7 @@ var script = {
|
|
|
52
52
|
const __vue_script__ = script;
|
|
53
53
|
|
|
54
54
|
/* template */
|
|
55
|
-
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('li',{staticClass:"gl-dropdown-item gl-
|
|
55
|
+
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('li',{staticClass:"gl-dropdown-item gl-focusable-dropdown-item",attrs:{"role":"option","tabindex":_vm.isFocused ? 0 : -1,"aria-selected":_vm.isSelected},on:{"click":_vm.toggleSelection,"keydown":_vm.onKeydown}},[_c('span',{staticClass:"dropdown-item"},[_c('gl-icon',{class:[
|
|
56
56
|
'gl-dropdown-item-check-icon',
|
|
57
57
|
{ 'gl-visibility-hidden': !_vm.isSelected },
|
|
58
58
|
_vm.checkedClasses ],attrs:{"name":"mobile-issue-close","data-testid":"dropdown-item-checkbox"}}),_vm._v(" "),_c('span',{staticClass:"gl-dropdown-item-text-wrapper"},[_vm._t("default")],2)],1)])};
|
|
@@ -82,6 +82,14 @@ var script = {
|
|
|
82
82
|
type: Boolean,
|
|
83
83
|
required: false,
|
|
84
84
|
default: true
|
|
85
|
+
},
|
|
86
|
+
/**
|
|
87
|
+
* CSS classes to add to the content container
|
|
88
|
+
*/
|
|
89
|
+
contentClass: {
|
|
90
|
+
type: [Array, String, Object],
|
|
91
|
+
required: false,
|
|
92
|
+
default: () => []
|
|
85
93
|
}
|
|
86
94
|
},
|
|
87
95
|
computed: {
|
|
@@ -96,6 +104,9 @@ var script = {
|
|
|
96
104
|
},
|
|
97
105
|
shouldRenderSecondaryButton() {
|
|
98
106
|
return Boolean(this.secondaryButtonLink && this.secondaryButtonText);
|
|
107
|
+
},
|
|
108
|
+
contentClasses() {
|
|
109
|
+
return [this.compact ? 'gl-flex-grow-1 gl-flex-basis-0 gl-px-4' : 'gl-max-w-full gl-m-auto', this.contentClass];
|
|
99
110
|
}
|
|
100
111
|
}
|
|
101
112
|
};
|
|
@@ -107,7 +118,7 @@ const __vue_script__ = script;
|
|
|
107
118
|
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('section',{staticClass:"gl-display-flex",class:{
|
|
108
119
|
'empty-state gl-text-center gl-flex-direction-column': !_vm.compact,
|
|
109
120
|
'gl-flex-direction-row': _vm.compact,
|
|
110
|
-
}},[_c('div',{class:{ 'gl-display-none gl-sm-display-block gl-px-4': _vm.compact, 'gl-max-w-full': !_vm.compact }},[(_vm.svgPath)?_c('div',{staticClass:"svg-250",class:{ 'svg-content': !_vm.compact }},[_c('img',{staticClass:"gl-max-w-full",class:{ 'gl-dark-invert-keep-hue': _vm.invertInDarkMode },attrs:{"src":_vm.svgPath,"alt":"","role":"img","height":_vm.height}})]):_vm._e()]),_vm._v(" "),_c('div',{class:_vm.
|
|
121
|
+
}},[_c('div',{class:{ 'gl-display-none gl-sm-display-block gl-px-4': _vm.compact, 'gl-max-w-full': !_vm.compact }},[(_vm.svgPath)?_c('div',{staticClass:"svg-250",class:{ 'svg-content': !_vm.compact }},[_c('img',{staticClass:"gl-max-w-full",class:{ 'gl-dark-invert-keep-hue': _vm.invertInDarkMode },attrs:{"src":_vm.svgPath,"alt":"","role":"img","height":_vm.height}})]):_vm._e()]),_vm._v(" "),_c('div',{class:_vm.contentClasses,attrs:{"data-testid":"gl-empty-state-content"}},[_c('div',{staticClass:"gl-mx-auto gl-my-0",class:{ 'gl-p-5': !_vm.compact }},[_vm._t("title",function(){return [_c('h1',{staticClass:"gl-font-size-h-display gl-line-height-36",class:_vm.compact ? 'h5' : 'h4'},[_vm._v("\n "+_vm._s(_vm.title)+"\n ")])]}),_vm._v(" "),(_vm.description || _vm.$scopedSlots.description)?_c('p',{ref:"description",staticClass:"gl-mt-3"},[_vm._t("description",function(){return [_vm._v("\n "+_vm._s(_vm.description)+"\n ")]})],2):_vm._e(),_vm._v(" "),_c('div',{staticClass:"gl-display-flex gl-flex-wrap",class:{ 'gl-justify-content-center': !_vm.compact }},[_vm._t("actions",function(){return [(_vm.shouldRenderPrimaryButton)?_c('gl-button',{staticClass:"gl-mb-3",class:_vm.compact ? 'gl-mr-3' : 'gl-mx-2',attrs:{"variant":"confirm","href":_vm.primaryButtonLink}},[_vm._v(_vm._s(_vm.primaryButtonText))]):_vm._e(),_vm._v(" "),(_vm.shouldRenderSecondaryButton)?_c('gl-button',{staticClass:"gl-mb-3 gl-mr-3",class:{ 'gl-mx-2!': !_vm.compact },attrs:{"href":_vm.secondaryButtonLink}},[_vm._v(_vm._s(_vm.secondaryButtonText)+"\n ")]):_vm._e()]})],2)],2)])])};
|
|
111
122
|
var __vue_staticRenderFns__ = [];
|
|
112
123
|
|
|
113
124
|
/* style */
|