锚点关注话题刷新按钮

This commit is contained in:
duanhao 2025-08-19 14:37:11 +08:00
parent b6163e3f75
commit 188ce22bcf
3 changed files with 29 additions and 1 deletions

2
package-lock.json generated
View File

@ -2789,7 +2789,7 @@
},
"node_modules/sass": {
"version": "1.90.0",
"resolved": "https://registry.npmjs.org/sass/-/sass-1.90.0.tgz",
"resolved": "https://registry.npmmirror.com/sass/-/sass-1.90.0.tgz",
"integrity": "sha512-9GUyuksjw70uNpb1MTYWsH9MQHOHY6kwfnkafC24+7aOMZn9+rVMBxRbLvw756mrBFbIsFg6Xw9IkR2Fnn3k+Q==",
"dev": true,
"license": "MIT",

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

View File

@ -1,6 +1,7 @@
<template>
<div class="attentionTopic-component">
<img src="@/assets/images/head/anchorTopicTitle.png" alt="" class="headerImage" />
<div class="attentionTopic-content">
<div class="topic-list">
<div class="topic-item" v-for="item in currentTopicList" :key="item.id">
@ -13,6 +14,7 @@
</div>
</div>
</div>
<div class="refresh-btn" @click="handleRefresh"></div>
<div id="topicChart" class="topic-chart"></div>
</div>
</div>
@ -20,6 +22,7 @@
<script setup>
import { ref, onMounted, onUnmounted } from "vue"
import * as echarts from "echarts"
import { useKeyNodeRecognitionStore } from "@/store/keyNodeRecognition/index"
const keyNodeStore = useKeyNodeRecognitionStore()
@ -241,10 +244,22 @@ const initTopicChart = () => {
//
const handleRefresh = () => {
if (myChart) {
//
clearInterval(timer)
//
keyNodeStore.riskEventIndex = -1
//
currentTopicList.value = []
//
keyNodeStore.statisticsList[3].number = 0
keyNodeStore.statisticsList[4].number = 0
//
myChart.dispose()
//
initTopicChart()
//
dynamicShowEventList()
}
}
@ -275,6 +290,7 @@ onUnmounted(() => {
margin-top: vh(-8);
}
.attentionTopic-content {
position: relative;
padding: vh(10) vw(10);
color: #fff;
.topic-list {
@ -322,6 +338,18 @@ onUnmounted(() => {
}
}
}
.refresh-btn {
position: absolute;
width: vw(30);
height: vw(30);
right: vw(20);
top: vh(300);
background-image: url("@/assets/images/icon/refresh.png");
background-size: 100% 100%;
border-radius: vw(5);
cursor: pointer;
z-index: 2;
}
.topic-chart {
width: 100%;
height: vh(200);