File tree Expand file tree Collapse file tree 1 file changed +28
-21
lines changed Expand file tree Collapse file tree 1 file changed +28
-21
lines changed Original file line number Diff line number Diff line change 1
1
<template >
2
- <span :class =" ['badge',labelVariant,labelType ]" >
2
+ <span :class =" ['badge',badgeVariant,badgeType,badgePill ]" >
3
3
<slot ></slot >
4
4
</span >
5
5
</template >
6
6
7
7
<script >
8
- export default {
9
- replace: true ,
10
- computed: {
11
- labelVariant () {
12
- return ! this .variant || this .variant === ` default` ? ` badge-default` : ` badge-${ this .variant } `
13
- },
14
- labelType () {
15
- return ! this .type ? ` ` : ` tag-${ this .type } `
16
- }
17
- },
18
- props: {
19
- variant: {
20
- type: String ,
21
- default: ' default'
22
- },
23
- type: {
24
- type: String ,
25
- default: ' '
26
- }
8
+ export default {
9
+ replace: true ,
10
+ computed: {
11
+ badgeVariant () {
12
+ return ! this .variant || this .variant === ` default` ? ` badge-default` : ` badge-${ this .variant } ` ;
13
+ },
14
+ badgeType () {
15
+ return ! this .type ? ` ` : ` badge-${ this .type } ` ;
16
+ },
17
+ badgePill (){
18
+ return this .pill ? ' badge-pill' : ' ' ;
19
+ }
20
+ },
21
+ props: {
22
+ variant: {
23
+ type: String ,
24
+ default: ' default'
25
+ },
26
+ type: {
27
+ type: String ,
28
+ default: ' '
29
+ },
30
+ pill: {
31
+ type: Boolean ,
32
+ default: false
33
+ }
34
+ }
27
35
}
28
- }
29
36
</script >
You can’t perform that action at this time.
0 commit comments