Skip to content

Commit 905ed9c

Browse files
committed
master: Fixed 左右两次实现
1 parent 2d88541 commit 905ed9c

File tree

15 files changed

+1180
-102
lines changed

15 files changed

+1180
-102
lines changed

package.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,8 @@
3535
"vue-echarts": "^7.0.3",
3636
"vue-i18n": "^10.0.4",
3737
"vue-router": "^4.4.5",
38+
"vue3-count-to": "^1.1.2",
39+
"vue3-seamless-scroll": "^2.0.1",
3840
"vuedraggable": "^2.24.3",
3941
"xgplayer": "^3.0.20"
4042
},

pnpm-lock.yaml

Lines changed: 31 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/assets/images/box-bg.png

588 Bytes
Loading

src/components/Box.vue

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
<template>
22
<div class="flex flex-col">
33
<div class="box-title w-full h-28px"
4-
><span class="color-#f0f0f0 font-bold block w-90px text-center">{{ title }}</span></div
4+
><span class="color-#f0f0f0 font-bold block w-90px text-center" :style="{ width: wHeader }">{{
5+
title
6+
}}</span></div
57
>
68
<div class="box-content p-15px bg-#031e559c" :style="styleContent">
79
<slot></slot>
@@ -15,13 +17,14 @@
1517
type: String,
1618
default: '标题'
1719
},
20+
wHeader: String,
1821
styleContent: String
1922
})
2023
</script>
2124

2225
<style lang="scss" scoped>
2326
.box-title {
2427
background: url('@/assets/images/box-h-bg.png') no-repeat center;
25-
background-size: 100%;
28+
background-size: 100% 100%;
2629
}
2730
</style>

src/components/Countto.vue

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
<template>
2+
<count-to v-bind="$attrs" :duration="2000"></count-to>
3+
</template>
4+
5+
<script setup>
6+
import { CountTo } from 'vue3-count-to'
7+
</script>

src/components/ECharts/ECharts.vue

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
import * as echarts from 'echarts'
66
import 'echarts-liquidfill'
77
8-
let myChart = ref(null)
8+
let myChart = shallowRef(null)
99
1010
const props = defineProps({
1111
// 区分chart
@@ -67,14 +67,11 @@
6767
text: '',
6868
color: '#409eff',
6969
textColor: '#000',
70-
maskColor: 'rgba(255, 255, 255, .95)',
70+
maskColor: 'rgba(56, 155, 255, .45)',
7171
zlevel: 0,
7272
lineWidth: 2
7373
})
74-
if (!props.loading) {
75-
myChart.value.hideLoading()
76-
myChart.value.setOption(props.fullOptions.options, true)
77-
}
74+
7875
//自适应不同屏幕时改变图表尺寸
7976
window.addEventListener('resize', cancalDebounce)
8077
})

0 commit comments

Comments
 (0)