@gitlab/ui 83.0.0 → 84.0.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 +15 -0
- package/dist/components/base/badge/badge.js +5 -13
- package/dist/components/experimental/experiment_badge/experiment_badge.js +1 -1
- package/dist/index.css +1 -1
- package/dist/index.css.map +1 -1
- package/dist/tokens/tokens_table.js +1 -1
- package/package.json +1 -1
- package/src/components/base/badge/badge.scss +14 -16
- package/src/components/base/badge/badge.vue +7 -18
- package/src/components/base/label/label.scss +7 -5
- package/src/components/experimental/experiment_badge/experiment_badge.vue +1 -1
- package/src/tokens/tokens_table.vue +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,18 @@
|
|
|
1
|
+
# [84.0.0](https://gitlab.com/gitlab-org/gitlab-ui/compare/v83.0.0...v84.0.0) (2024-06-21)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Features
|
|
5
|
+
|
|
6
|
+
* **GlBadge:** One size fits all ([91f2129](https://gitlab.com/gitlab-org/gitlab-ui/commit/91f2129ed2fef3eb47c48cce2a5af1a38844f280))
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### BREAKING CHANGES
|
|
10
|
+
|
|
11
|
+
* **GlBadge:** The `size` prop has been removed from `GlBadge`. This
|
|
12
|
+
might affect test which check that the prop was provided, but more
|
|
13
|
+
importantly this could affect layout for badges which were set small or
|
|
14
|
+
large.
|
|
15
|
+
|
|
1
16
|
# [83.0.0](https://gitlab.com/gitlab-org/gitlab-ui/compare/v82.1.0...v83.0.0) (2024-06-21)
|
|
2
17
|
|
|
3
18
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { BBadge } from 'bootstrap-vue/esm/index.js';
|
|
2
|
-
import {
|
|
2
|
+
import { badgeVariantOptions, badgeIconSizeOptions } from '../../../utils/constants';
|
|
3
3
|
import GlIcon from '../icon/icon';
|
|
4
4
|
import __vue_normalize__ from 'vue-runtime-helpers/dist/normalize-component.js';
|
|
5
5
|
|
|
@@ -12,17 +12,6 @@ var script = {
|
|
|
12
12
|
},
|
|
13
13
|
inheritAttrs: false,
|
|
14
14
|
props: {
|
|
15
|
-
/**
|
|
16
|
-
* The size of the badge.
|
|
17
|
-
*/
|
|
18
|
-
size: {
|
|
19
|
-
type: String,
|
|
20
|
-
default: badgeSizeOptions.md,
|
|
21
|
-
validator(value) {
|
|
22
|
-
return badgeSizeOptions[value] !== undefined;
|
|
23
|
-
},
|
|
24
|
-
required: false
|
|
25
|
-
},
|
|
26
15
|
/**
|
|
27
16
|
* The variant of the badge.
|
|
28
17
|
*/
|
|
@@ -57,6 +46,9 @@ var script = {
|
|
|
57
46
|
// eslint-disable-next-line @gitlab/vue-prefer-dollar-scopedslots
|
|
58
47
|
return Boolean(this.icon && Object.keys(this.$slots).length === 0);
|
|
59
48
|
},
|
|
49
|
+
isCircularIcon() {
|
|
50
|
+
return ['issue-open-m', 'issue-close'].includes(this.icon);
|
|
51
|
+
},
|
|
60
52
|
role() {
|
|
61
53
|
return this.hasIconOnly ? 'img' : undefined;
|
|
62
54
|
},
|
|
@@ -76,7 +68,7 @@ var script = {
|
|
|
76
68
|
const __vue_script__ = script;
|
|
77
69
|
|
|
78
70
|
/* template */
|
|
79
|
-
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('b-badge',_vm._b({class:
|
|
71
|
+
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('b-badge',_vm._b({staticClass:"gl-badge",class:{ 'gl-px-2!': !_vm.$scopedSlots.default },attrs:{"variant":_vm.variant,"role":_vm.role,"aria-label":_vm.ariaLabel,"pill":""}},'b-badge',_vm.$attrs,false),[(_vm.icon)?_c('gl-icon',{staticClass:"gl-badge-icon",class:{ '-gl-ml-2 gl-ml-n2': _vm.isCircularIcon },attrs:{"size":_vm.iconSizeComputed,"name":_vm.icon}}):_vm._e(),_vm._v(" "),_vm._t("default")],2)};
|
|
80
72
|
var __vue_staticRenderFns__ = [];
|
|
81
73
|
|
|
82
74
|
/* style */
|
|
@@ -69,7 +69,7 @@ var script = {
|
|
|
69
69
|
const __vue_script__ = script;
|
|
70
70
|
|
|
71
71
|
/* template */
|
|
72
|
-
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('gl-badge',{staticClass:"gl-mx-4 gl-hover-cursor-pointer",attrs:{"id":_vm.triggerId,"variant":"neutral"
|
|
72
|
+
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('gl-badge',{staticClass:"gl-mx-4 gl-hover-cursor-pointer",attrs:{"id":_vm.triggerId,"variant":"neutral"}},[_c('span',[_vm._v(_vm._s(_vm.activeType.BADGE))]),_vm._v(" "),_c('gl-popover',{attrs:{"triggers":"click","show-close-button":"","placement":_vm.popoverPlacement,"target":_vm.triggerId,"css-classes":['gl-z-index-9999!'],"title":_vm.activeType.POPOVER_TITLE}},[_c('gl-sprintf',{attrs:{"message":_vm.activeType.POPOVER_CONTENT},scopedSlots:_vm._u([{key:"link",fn:function(ref){
|
|
73
73
|
var content = ref.content;
|
|
74
74
|
return [(_vm.helpPageUrl)?_c('gl-link',{staticClass:"gl-font-sm!",attrs:{"href":_vm.helpPageUrl,"target":"_blank"}},[_vm._v("\n "+_vm._s(content)+"\n ")]):_c('span',[_vm._v(_vm._s(content))])]}},{key:"bullets",fn:function(){return [_c('ul',{staticClass:"gl-mb-0 gl-pl-5"},_vm._l((_vm.activeType.POPOVER_BULLETS),function(item,i){return _c('li',{key:("li-" + i)},[_vm._v("\n "+_vm._s(item)+"\n ")])}),0)]},proxy:true},{key:"line-break",fn:function(ref){
|
|
75
75
|
var content = ref.content;
|