Skip to content

Commit dc6657e

Browse files
committed
refactor: add 'c-' prefixes to active and disabled classes
1 parent 60514a1 commit dc6657e

File tree

13 files changed

+18
-19
lines changed

13 files changed

+18
-19
lines changed

package.json

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -60,9 +60,8 @@
6060
"clear_jest": "jest --clearCache"
6161
},
6262
"dependencies": {
63-
"@coreui/coreui": "next",
64-
"@coreui/icons": "../coreui-icons",
65-
"raw-loader": "^1.0.0",
63+
"@coreui/coreui": "3.0.0-alpha.11",
64+
"@coreui/icons": "coreui/coreui-icons#v.1.0.0-alpha",
6665
"core-js": "^2.5.7",
6766
"element-resize-detector": "^1.2.0",
6867
"popper.js": "^1.14.7",

src/components/Badge/CBadge.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ export default {
2828
`c-badge-${props.variant}`,
2929
{
3030
'c-badge-pill': Boolean(props.pill),
31-
active: props.active,
32-
disabled: props.disabled
31+
'c-active': props.active,
32+
'c-disabled': props.disabled
3333
}
3434
],
3535
domProps,

src/components/Breadcrumb/Breadcrumb.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<template>
22
<ol class="breadcrumb">
33
<li class="breadcrumb-item" :key="index" v-for="(routeObject, index) in routeRecords">
4-
<span class="active" v-if="isLast(index)">{{ getName(routeObject) }}</span>
4+
<span class="c-active" v-if="isLast(index)">{{ getName(routeObject) }}</span>
55
<router-link :to="routeObject" v-else>{{ getName(routeObject) }}</router-link>
66
</li>
77
</ol>

src/components/Breadcrumb/CBreadcrumb.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ export default {
3131
return h('li',
3232
{
3333
staticClass: 'c-breadcrumb-item',
34-
class: { active: isLast },
34+
class: { 'c-active': isLast },
3535
attrs: { role: 'presentation' }
3636
},
3737
[h(tag, itemProps)])

src/components/Button/CButton.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ function computeClasses (props) {
4646
[`c-btn-ghost-${props.variant}`]: props.ghost,
4747
'c-btn-block': props.block,
4848
'c-disabled': props.disabled,
49-
active: props.pressed
49+
'c-active': props.pressed
5050
}
5151
]
5252
}

src/components/Carousel/CCarousel.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<li
55
v-for="(index, key) in items.length"
66
@click="setItem(key)"
7-
:class="{ active: activated === key }"
7+
:class="{ 'c-active': activated === key }"
88
:key="key"
99
></li>
1010
</ol>

src/components/Carousel/CCarouselItem.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ export default {
4747
{
4848
[`c-carousel-item-${this.order}`]: this.order && !this.activated,
4949
[`c-carousel-item-${this.direction}`]: this.transitioning,
50-
'active': this.activated
50+
'c-active': this.activated
5151
}
5252
]
5353
}

src/components/Link/CLink.vue

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ export function propsFactory () {
1616
//these are router-link component props (default active class changed)
1717
activeClass: {
1818
type: String,
19-
default: 'active'
19+
default: 'c-active'
2020
},
2121
append: Boolean,
2222
event: {
@@ -26,7 +26,7 @@ export function propsFactory () {
2626
exact: Boolean,
2727
exactActiveClass: {
2828
type: String,
29-
default: 'active'
29+
default: 'c-active'
3030
},
3131
replace: Boolean,
3232
routerTag: {
@@ -85,7 +85,7 @@ export default {
8585
const componentData = mergeData(data, {
8686
class: {
8787
'c-disabled': props.disabled,
88-
'active': props.active
88+
'c-active': props.active
8989
},
9090
attrs: {
9191
rel,

src/components/ListGroup/CListGroupItem.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,8 @@ export default {
4444
class: {
4545
[`c-list-group-item-${props.variant}`]: Boolean(props.variant),
4646
'c-list-group-item-action': isAction,
47-
active: props.active,
48-
disabled: props.disabled
47+
'c-active': props.active,
48+
'c-disabled': props.disabled
4949
}
5050
}
5151
return h(tag, mergeData(data, componentData), children)

src/components/Pagination/CPagination.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,7 @@
229229
},
230230
setStyle (item) {
231231
if(this.activePage === item) {
232-
return 'c-page-item active'
232+
return 'c-page-item c-active'
233233
}
234234
return 'c-page-item'
235235
}

0 commit comments

Comments
 (0)