Skip to content

Commit f414a7a

Browse files
committed
fix: fix charts
1 parent 8bf4e29 commit f414a7a

File tree

2 files changed

+22
-17
lines changed

2 files changed

+22
-17
lines changed

src/views/charts/MainChartExample.vue

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ function random (min, max) {
1515
}
1616
1717
export default {
18+
name: 'MainChartExample',
1819
components: {
1920
CChartLine
2021
},
@@ -39,23 +40,23 @@ export default {
3940
label: 'My First dataset',
4041
backgroundColor: hexToRgba(brandInfo, 10),
4142
borderColor: brandInfo,
42-
pointHoverBackgroundColor: '#fff',
43+
pointHoverBackgroundColor: brandInfo,
4344
borderWidth: 2,
4445
data: data1
4546
},
4647
{
4748
label: 'My Second dataset',
4849
backgroundColor: 'transparent',
4950
borderColor: brandSuccess,
50-
pointHoverBackgroundColor: '#fff',
51+
pointHoverBackgroundColor: brandSuccess,
5152
borderWidth: 2,
5253
data: data2
5354
},
5455
{
5556
label: 'My Third dataset',
5657
backgroundColor: 'transparent',
5758
borderColor: brandDanger,
58-
pointHoverBackgroundColor: '#fff',
59+
pointHoverBackgroundColor: brandDanger,
5960
borderWidth: 1,
6061
borderDash: [8, 5],
6162
data: data3

src/views/widgets/WidgetsBrand.vue

Lines changed: 18 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,12 @@
1010
left-footer="feeds"
1111
>
1212
<CIcon
13-
name="socialFacebook"
13+
name="facebook"
1414
height="52"
1515
class="my-4"
1616
/>
1717
<CChartLineSimple
18-
style="height:100px"
19-
class="position-absolute"
18+
class="c-chart-brand"
2019
background-color="rgba(255,255,255,.1)"
2120
:data-points="[65, 59, 84, 84, 51, 55, 40]"
2221
label="Friends"
@@ -33,13 +32,12 @@
3332
left-footer="tweets"
3433
>
3534
<CIcon
36-
name="socialTwitter"
35+
name="twitter"
3736
height="52"
3837
class="my-4"
3938
/>
4039
<CChartLineSimple
41-
style="height:100px"
42-
class="position-absolute"
40+
class="c-chart-brand"
4341
background-color="rgba(255,255,255,.1)"
4442
:data-points="[1, 13, 9, 17, 34, 41, 38]"
4543
label="Followers"
@@ -56,13 +54,12 @@
5654
left-footer="feeds"
5755
>
5856
<CIcon
59-
name="socialLinkedin"
57+
name="linkedin"
6058
height="52"
6159
class="my-4"
6260
/>
6361
<CChartLineSimple
64-
style="height:100px"
65-
class="position-absolute"
62+
class="c-chart-brand"
6663
background-color="rgba(255,255,255,.1)"
6764
:data-points="[78, 81, 80, 45, 34, 12, 40]"
6865
label="Contracts"
@@ -84,8 +81,7 @@
8481
class="my-4"
8582
/>
8683
<CChartLineSimple
87-
style="height:100px"
88-
class="position-absolute"
84+
class="c-chart-brand"
8985
background-color="rgba(255,255,255,.1)"
9086
:data-points="[35, 23, 56, 22, 97, 23, 64]"
9187
label="Followers"
@@ -104,7 +100,7 @@
104100
left-footer="feeds"
105101
>
106102
<CIcon
107-
name="socialFacebook"
103+
name="facebook"
108104
height="56"
109105
class="my-4"
110106
/>
@@ -119,7 +115,7 @@
119115
left-footer="tweets"
120116
>
121117
<CIcon
122-
name="socialTwitter"
118+
name="twitter"
123119
height="56"
124120
class="my-4"
125121
/>
@@ -134,7 +130,7 @@
134130
left-footer="feeds"
135131
>
136132
<CIcon
137-
name="socialLinkedin"
133+
name="linkedin"
138134
height="56"
139135
class="my-4"
140136
/>
@@ -172,3 +168,11 @@ export default {
172168
}
173169
}
174170
</script>
171+
172+
<style scoped>
173+
.c-chart-brand {
174+
position: absolute;
175+
width: 100%;
176+
height: 100px;
177+
}
178+
</style>

0 commit comments

Comments
 (0)