大屏样式

master
xy 1 year ago
parent ac38097321
commit 02d8c03662

@ -21,6 +21,7 @@
"echarts": "^4.2.1",
"element-ui": "2.13.2",
"file-saver": "^2.0.5",
"gsap": "^3.12.5",
"js-cookie": "2.2.0",
"less-loader": "^5.0.0",
"moment": "^2.29.2",

@ -0,0 +1 @@
<svg t="1724137695350" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="7416" width="200" height="200"><path d="M711.424 11.904a38.4 38.4 0 0 1 13.056 52.736l-66.56 110.144a209.536 209.536 0 0 1 103.552 54.272l125.952-95.168a38.4 38.4 0 0 1 46.336 61.312l-127.552 96.384c12.8 27.52 19.584 57.6 19.584 88.576a38.4 38.4 0 1 1-76.8 0 132.672 132.672 0 1 0-265.344 0 38.4 38.4 0 0 1-76.8 0 209.472 209.472 0 0 1 160.32-203.648L658.688 24.96a38.4 38.4 0 0 1 52.736-13.056zM178.752 456.96a38.208 38.208 0 0 1 14.336-2.304h593.216a38.272 38.272 0 0 1 39.424 40.576 38.4 38.4 0 0 1-1.536 8.832 346.368 346.368 0 0 1-296.064 254.336v176h160a38.4 38.4 0 1 1 0 76.8H291.328a38.4 38.4 0 0 1 0-76.8h160v-176A346.368 346.368 0 0 1 154.24 500.096a38.4 38.4 0 0 1 24.512-43.008z m68.224 74.496a269.568 269.568 0 0 0 485.44 0H247.04zM293.248 286.336a132.672 132.672 0 0 1 93.824-38.912 38.4 38.4 0 0 0 0-76.8A209.472 209.472 0 0 0 177.536 380.16a38.4 38.4 0 0 0 76.8 0c0-35.2 14.016-68.992 38.912-93.824z" fill="#b565ff" p-id="7417"></path></svg>

After

Width:  |  Height:  |  Size: 1.0 KiB

@ -0,0 +1 @@
<svg t="1724138162736" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="4609" width="200" height="200"><path d="M587.776 929.792H299.52c-84.992 0-154.624-69.12-154.624-154.624v-227.84H58.368c-10.752 0-20.48-6.656-24.064-16.384-3.584-10.24-1.024-21.504 7.168-28.672l453.632-401.408c9.728-8.704 24.576-8.704 34.304 0L983.04 502.272c8.192 7.168 10.752 18.432 7.168 28.672-3.584 10.24-13.312 16.384-24.064 16.384h-86.528v227.84c0 53.248-27.136 102.4-72.192 131.072-12.288 7.68-28.16 4.096-35.328-8.192-7.68-11.776-4.096-28.16 8.192-35.328a102.4 102.4 0 0 0 48.128-87.04V522.24c0-14.336 11.776-25.6 25.6-25.6h44.544L512 154.624 125.952 496.128h44.544c14.336 0 25.6 11.776 25.6 25.6v253.44c0 56.832 46.08 102.912 102.912 102.912h288.256c14.336 0 25.6 11.776 25.6 25.6 0.512 14.336-10.752 26.112-25.088 26.112z m-0.512 0c-14.336 0-25.6-11.776-25.6-25.6 0-14.336 11.776-25.6 25.6-25.6 21.504 0 38.4-17.408 38.4-38.4v-186.88c0-21.504-17.408-38.4-38.4-38.4H436.736c-21.504 0-38.4 17.408-38.4 38.4v120.32c0 14.336-11.776 25.6-25.6 25.6s-25.6-11.776-25.6-25.6v-120.32c0-49.664 40.448-90.112 90.112-90.112h150.528c49.664 0 90.112 40.448 90.112 90.112V839.68c-0.512 49.664-40.96 90.112-90.624 90.112z" fill="#fe7629" p-id="4610"></path></svg>

After

Width:  |  Height:  |  Size: 1.2 KiB

@ -0,0 +1 @@
<svg t="1724138091003" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2366" width="200" height="200"><path d="M838.6 226.2L697.4 64 512 179.9 326.6 64l-139 162.2-23.2 231.7L512 736l347.6-278.1-21-231.7zM512 572.1L298.7 401.4 310.9 279l41.2-48.1 92 57.5 67.8 42.4 67.8-42.4 92.7-58 42.3 48.6 11.1 122L512 572.1zM864 512v96L608 800v160h128v-96l256-192V512zM160 512H32v160l256 192v96h128V800L160 608z" p-id="2367" class="custom-cursor-on-hover" fill="#01acff"></path></svg>

After

Width:  |  Height:  |  Size: 516 B

@ -0,0 +1 @@
<svg t="1724138323662" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="32079" width="200" height="200"><path d="M866 812.2c-28-28.05-99.71-109.51-99.71-109.51s7.7-9.2 22.56-36c26.17-47.31 42.62-110.09 44.42-164.1 6.95-209.17-180.73-379.78-388.5-352-207.26 27.62-343.47 242.32-281.86 441.64 59.25 191.69 278.65 293.61 463 214 21-9.08 52.24-28.59 69.69-40.72 6.65-4.61 8.94-7.35 8.94-7.35S801 856.57 812 865.69c33.18 27.55 91.34-14.53 54-53.49z m-374.95-49.32c-144.42 0.43-265.33-117.06-271.46-260.74-6.47-151.85 118.92-282.24 270.83-282.43 147.58-0.19 271.72 123.68 271.13 271.52-0.73 147.52-122.37 271.21-270.5 271.65z" fill="#f13131" p-id="32080"></path><path d="M689.77 510l-96.38-0.88-63.59-179.18a28.5 28.5 0 0 0-53.85 0.38L417.81 501.8 395 449.25a28.5 28.5 0 0 0-49-5.67l-63.53 85.34a28.5 28.5 0 0 0 45.72 34l34.14-45.86L395 592.24a28.48 28.48 0 0 0 26.13 17.14h1.19A28.5 28.5 0 0 0 448.08 590l55.47-163.61L546.33 547a28.51 28.51 0 0 0 26.6 19l116.32 1h0.26a28.5 28.5 0 0 0 0.26-57z" fill="#f13131" p-id="32081"></path></svg>

After

Width:  |  Height:  |  Size: 1.0 KiB

@ -0,0 +1 @@
<svg t="1724137855449" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="8455" width="200" height="200"><path d="M265.6 937.6c-12.8 0-27.2-4.8-38.4-12.8-19.2-14.4-28.8-35.2-27.2-59.2l24-240L64 446.4c-16-17.6-20.8-41.6-12.8-64s25.6-38.4 48-43.2L334.4 288l121.6-208c11.2-20.8 32-32 56-32s44.8 12.8 56 32l121.6 208 235.2 51.2c22.4 4.8 41.6 20.8 48 43.2s1.6 46.4-12.8 64L800 625.6l24 240c1.6 24-8 44.8-27.2 59.2-19.2 14.4-43.2 16-64 6.4l-220.8-96-220.8 97.6c-8 3.2-17.6 4.8-25.6 4.8zM512 771.2c9.6 0 17.6 1.6 25.6 4.8l220.8 97.6 1.6-1.6-24-240c-1.6-17.6 4.8-36.8 16-49.6l160-179.2 6.4-33.6-6.4 32L676.8 352c-17.6-3.2-33.6-14.4-41.6-30.4l-121.6-208H512l-121.6 208c-9.6 16-24 27.2-41.6 30.4L112 403.2v1.6l160 179.2c12.8 12.8 17.6 32 16 49.6l-24 240 1.6 1.6 220.8-97.6c8-4.8 16-6.4 25.6-6.4z" fill="#00cf92" p-id="8456"></path></svg>

After

Width:  |  Height:  |  Size: 869 B

@ -1,5 +1,5 @@
$word-color: #59d4fc;
$card-color: rgba(6, 34, 108, 0.55);
$card-color: rgba(6, 34, 108, 0.37);
.color-word {
color: $word-color;

@ -2,7 +2,7 @@
<div class="bottom">
<div class="bs-card">
<div class="bs-card__title jc-between">
<p class="bs-card__title--text"></p>
<p class="bs-card__title--text">疗陪护</p>
<div class="color-white">
<span class="color-word">1</span>
@ -18,7 +18,7 @@
</div>
<div class="bs-card">
<div class="bs-card__title jc-between">
<p class="bs-card__title--text">物业</p>
<p class="bs-card__title--text">项目</p>
<div class="color-white">
<span class="color-word">1</span>
@ -34,7 +34,7 @@
</div>
<div class="bs-card">
<div class="bs-card__title jc-between">
<p class="bs-card__title--text">分公司</p>
<p class="bs-card__title--text">分公司/站点</p>
<div class="color-white">
<span class="color-word">1</span>
@ -50,7 +50,7 @@
</div>
<div class="bs-card">
<div class="bs-card__title jc-between">
<p class="bs-card__title--text">站点</p>
<p class="bs-card__title--text">活动集锦</p>
<div class="color-white">
<span class="color-word">1</span>

@ -6,7 +6,7 @@
<img :src="require('@/assets/bigScreen/img1.png')" alt="">
</div>
<div class="card-text">
<p class="color-word">工人数</p>
<p class="color-word"></p>
<p>
<span class="color-white fw-b" style="font-size: 42px;">10000</span>
<span class="color-word" style="padding-left: 5px">人次/</span>
@ -18,10 +18,10 @@
<img :src="require('@/assets/bigScreen/img2.png')" alt="">
</div>
<div class="card-text">
<p class="color-word">服务驿站</p>
<p class="color-word">服务覆盖人数</p>
<p>
<span class="color-white fw-b" style="font-size: 42px;">658</span>
<span class="color-word" style="padding-left: 5px"></span>
<span class="color-word" style="padding-left: 5px"></span>
</p>
</div>
</div>
@ -39,25 +39,74 @@
</div>
</div>
<div class="bottom">
<video ref="video">
<div class="bottom" @mouseenter="isMouseHover = true" @mouseleave="isMouseHover = false" @click="playVideo">
<video ref="video" loop>
<source src="https://highlight-video.cdn.bcebos.com/video/6s/fa06ca8e-536b-11ef-8efc-7cd30ab516e3.mp4">
</video>
<img class="video-btn" :src="require('@/assets/bigScreen/video-btn.png')" alt="" @click="playVideo">
<transition name="fade">
<div class="video-btn" v-show="isPaused || isMouseHover">
<svg viewBox="0 0 100 100">
<defs>
<linearGradient id="yellow" x1="50%" x2="50%" y1="0%" y2="100%">
<stop offset="0%" stop-color="#eacab1"></stop>
<stop offset="40%" stop-color="#bf9271"></stop>
</linearGradient>
<linearGradient id="yellow1" x1="50%" x2="50%" y1="0%" y2="100%">
<stop offset="0%" stop-color="#e0c0a8"></stop>
<stop offset="40%" stop-color="#caa182"></stop>
</linearGradient>
</defs>
<path d="M 50 50 m 0 47a 47 47 0 1 1 0 -94a 47 47 0 1 1 0 94"
stroke="url(#yellow)"
stroke-width="4"
style="stroke-dasharray: 260.1482px, 295.31px;stroke-dashoffset: -4.9137px;"
fill="none"></path>
<path :d="isPaused ? 'M 38.6 30 l 0 40 l 34.6 -20 Z' : 'M 38.6 30 l 0 40 M 61.4 30 l 0 40'"
ref="icon"
fill="none"
class="icon"
stroke="url(#yellow1)"
stroke-width="4">
</path>
</svg>
</div>
</transition>
<div class="type-change" @click.stop>
<div class="type-change-item">
<i class="el-icon-picture type-change-item__icon"></i>
<div class="type-change-item__num">2</div>
</div>
<div class="type-change-item">
<i class="el-icon-video-camera-solid type-change-item__icon"></i>
<div class="type-change-item__num">6</div>
</div>
</div>
</div>
</div>
</template>
<script>
import gsap from "gsap";
export default {
data() {
return {
isPaused: true
isPaused: true,
isMouseHover: false,
}
},
methods: {
playVideo () {
gsap.set(this.$refs['icon'],{
strokeDasharray: "6.148px, 442.31px",
strokeDashoffset: "100.9137px"
})
gsap.to(this.$refs['icon'],{
strokeDasharray: "126.148px, 442.31px",
strokeDashoffset: "19.9137px"
})
if (this.$refs['video'].paused) {
this.isPaused = false;
this.$refs['video'].play()
@ -84,13 +133,13 @@ export default {
display: flex;
justify-content: space-between;
align-items: center;
padding: 20px 15px;
padding: 20px 14px;
.card-icon {
width: 62px;
height: 58px;
& > img {
width: 62px;
object-fit: cover;
}
}
@ -125,13 +174,91 @@ export default {
height: calc(100% - 12px);
width: calc(100% - 12px);
}
//.video-btn {
// cursor: pointer;
// width: 230px;
// height: 230px;
// position: absolute;
// top: calc(50% - 115px);
// left: calc(50% - 115px);
//}
.video-btn {
border-radius: 100%;
background-color: #e7e6e630;
cursor: pointer;
width: 230px;
height: 230px;
width: 195px;
height: 195px;
display: flex;
justify-content: center;
align-items: center;
position: absolute;
top: calc(50% - 97.5px);
left: calc(50% - 97.5px);
&::after {
content: "";
width: 143px;
height: 143px;
background: #fffd;
border-radius: 100%;
position: absolute;
top: calc(50% - 71.5px);
left: calc(50% - 71.5px);
}
svg {
width: 72px;
height: 72px;
position: relative;
z-index: 2;
.icon {
stroke-dasharray: 126.148px, 442.31px;
stroke-dashoffset: 19.9137px;
}
}
}
.type-change {
border-radius: 19px;
background: #ffffff19;
padding: 9px 15px;
display: flex;
align-items: center;
position: absolute;
top: calc(50% - 115px);
left: calc(50% - 115px);
bottom: 14px;
right: 30px;
&-item {
cursor: pointer;
font-size: 24px;
line-height: 24px;
display: flex;
align-items: center;
&__icon {
color: #fff;
}
&__num {
color: #fff;
margin-left: 10px;
}
&:nth-child(1) {
margin-right: 30px;
position: relative;
&::after {
content: "";
height: 100%;
width: 2px;
background: #ffffff;
opacity: .2;
position: absolute;
top: 0;
right: -16px;
}
}
}
}
}
}

@ -3,69 +3,23 @@
<div class="bs-card business-buy">
<div class="bs-card__title jc-between">
<p class="bs-card__title--text">
政府购买服务
康养服务
</p>
<p>
<span class="color-word">658</span>
<span class="color-white">人次/每分钟</span>
<span class="color-white">人次/</span>
</p>
</div>
<div class="business-buy__body">
<div class="digital">
<p class="digital-item">60%</p>
<p class="digital-item">18%</p>
<p class="digital-item">22%</p>
<img :src="require('@/assets/bigScreen/business-buy.png')" alt="">
</div>
<div class="progress">
<div class="progress-item" v-for="i in 3">
<svg viewBox="0 0 100 100" style="transform: rotate(-90deg)">
<path d="M 50 50 m 0 47a 47 47 0 1 1 0 -94a 47 47 0 1 1 0 94"
stroke="#f56c6c"
stroke-width="8"
fill="none"
style="stroke-dasharray: 5,4; stroke-dashoffset: -36.9137px;"></path>
<path d="M 50 50 m 0 47 a 47 47 0 1 1 0 -94 a 47 47 0 1 1 0 94"
stroke="#0e2168"
fill="none"
stroke-linecap="round"
stroke-width="8"
style="stroke-dasharray: 74.1482px, 295.31px; stroke-dashoffset: -36.9137px; transition: stroke-dasharray 0.6s, stroke 0.6s;"></path>
</svg>
<div class="progress-name">
长护
</div>
<div class="progress-rate">
30%
</div>
</div>
<div>
<div id="property-line-chart"></div>
</div>
</div>
</div>
<div class="bs-card property">
<div class="bs-card__title jc-between">
<p class="bs-card__title--text">
物业
</p>
<div class="chart-legend">
<div class="chart-legend__item">
<div style="background: #00d9d5;"></div>
<p class="color-white">商业服务面积</p>
</div>
<div class="chart-legend__item">
<div style="background: linear-gradient(0deg, #e67725 0%, #ff9d62 100%);"></div>
<p class="color-white">住宅服务面积</p>
</div>
</div>
</div>
<div>
<div id="property-line-chart"></div>
</div>
<div id="property-pie-chart"></div>
</div>
</div>
</template>
@ -82,8 +36,51 @@ export default {
this.chart = echarts.init(document.querySelector('#property-line-chart'), 'macarons');
this.setOptions(this.chartData);
},
initPieChart () {
this.chartPie = echarts.init(document.querySelector('#property-pie-chart'));
this.setPieOptions(this.chartData);
},
setOptions(chartdata) {
let data = [{
name: '长护',
val: 7100,
color: '#c95038'
},{
name: '残联',
val: 8120,
color: '#e1884a'
},{
name: '民政',
val: 5612,
color: '#ebb34c'
},{
name: "陪诊",
val: 8143,
color: '#316922'
},{
name: "问诊",
val: 4231,
color: '#71dc7a'
},{
name: "居家照护",
val: 6501,
color: '#6bb7be'
},{
name: "医院陪护",
val: 3420,
color: '#2050e0'
},{
name: "个性化\n服务",
val: 6501,
color: '#9952f6'
}]
this.chart.setOption({
tooltip: {
trigger: 'axis',
axisPointer: {
type: 'shadow'
}
},
grid: {
top: 10,
left: '2%',
@ -91,64 +88,127 @@ export default {
bottom: '3%',
containLabel: true
},
xAxis: [{
xAxis: {
type: 'value',
}],
yAxis: [{
type: 'category',
date: ['商业服务面积','住宅服务面积']
}],
series: [{
name: '商业服务面积',
type: 'bar',
barWidth: '30%',
data: [550],
itemStyle: {
color: "#00d9d5",
barBorderRadius: [0,4,4,0],
},
label: {
splitLine: {
show: true,
position: 'right',
color: '#31abe3',
fontWeight: 'bold',
formatter: '{c}㎡'
},
animationDuration: 3000
},{
name: '住宅服务面积',
type: 'bar',
barWidth: '30%',
data: [550],
itemStyle: {
color: new echarts.graphic.LinearGradient(1, 0.5, 0, 0.5, [
{
offset: 0,
color: '#e67725'
lineStyle: {
color: '#384b8f', // X 线
}
}
},
yAxis: {
type: 'category',
data: data.map(i => i.name),
axisLabel: {
textStyle: {
color: "#fff"
}
}
},
series: [
{
name: '人数',
type: 'bar',
data: data.map(i => i.val),
label: {
show: true,
position: 'insideRight',
color: '#fff',
fontWeight: 'bold',
formatter: '{c}'
},
itemStyle: {
color: (params) => {
return data[params.dataIndex].color
},
{
offset: 1,
color: '#ff9d62'
}
]),
barBorderRadius: [0,4,4,0],
barBorderRadius: [0,4,4,0],
},
}
]
})
},
setPieOptions () {
let data = [{
name: "政府",
val: 40,
color: new echarts.graphic.LinearGradient(0.5, 0, 0.5, 1, [
{
offset: 0,
color: '#202aed'
},
label: {
show: true,
position: 'right',
color: '#31abe3',
fontWeight: 'bold',
formatter: '{c}㎡'
{
offset: 1,
color: '#3b82f0'
}
])
},{
name: "商业",
val: 60,
color: new echarts.graphic.LinearGradient(0.5, 0, 0.5, 1, [
{
offset: 0,
color: '#84d7ee'
},
animationDuration: 3000
}]
})
{
offset: 1,
color: '#6fe7fa'
}
])
}]
this.chartPie.setOption({
title: {
show: false,
},
tooltip: {
trigger: 'item'
},
series: [
{
type: 'pie',
radius: '64%',
center: ['50%', '50%'],
data: data.map(i => ({
value: i.val,
name: i.name,
itemStyle: {
color: i.color,
shadowBlur: 10,
}
})).sort(function (a, b) {
return a.value - b.value;
}),
roseType: 'radius',
label: {
color: '#fff',
formatter: '{b} \n {d}%'
},
labelLine: {
lineStyle: {
color: '#71e8fc'
},
smooth: 0.2,
length: 10,
length2: 20
},
animationType: 'scale',
animationEasing: 'elasticOut',
animationDelay: function (idx) {
return Math.random() * 200;
}
}
]
})
}
},
computed: {},
mounted() {
this.initChart()
this.initPieChart()
}
}
</script>
@ -255,7 +315,11 @@ export default {
}
#property-line-chart {
height: 140px;
width: 388px;
height: 335px;
width: 100%;
}
#property-pie-chart {
width: 100%;
height: 100%;
}
</style>

File diff suppressed because it is too large Load Diff

@ -27,7 +27,7 @@ export default {
.title-img {
height: 72px;
width: 477px;
margin: 0 auto;
margin: 6px auto 0;
display: block;
}
.line {

@ -65,8 +65,8 @@ export default {
flex: 0;
height: 648px;
display: grid;
grid-template-areas: "left center center right";
grid-template-columns: repeat(4, 1fr);
grid-template-areas: "left left left left left center center center center center center center center center center center center right right right right right right right";
grid-template-columns: repeat(24, 1fr);
grid-column-gap: 30px;
padding: 0 30px;
margin-top: 25px;

Loading…
Cancel
Save