1 Star 0 Fork 47

chenyijun0119 / DM_screen_web

forked from yuanjinwie / DM_screen_web 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
README.md 4.54 KB
一键复制 编辑 原始数据 按行查看 历史
yuanjinwie 提交于 2023-10-11 15:55 . docs: 文档修改

DM_screen_web

介绍

🔥🔥Vue3 + TS + Echarts + Pinia 优秀可视化数据大屏解决方案,包括移动端与 PC 端的响应式适配处理
账号:yuan
密码:123456

项目地址

http://124.221.177.11/#/login

gitee开源地址https://gitee.com/yuanjinwei/DM_screen_web

github开源地址https://github.com/williamyuanjw/DM_screen_web

软件架构

node v16.14.2

项目展示

  • 登录页

img

  • PC 端首页

img

  • 小于 576px 设备效果

img

操作文档

登录项目之后,在首页以关注度图表为例

  1. 图表可支持左右滑动,图表内长按鼠标左滑或者右滑进行不同月份的展示
  2. 右上角从左到右图标的功能分别为:切换至折线图、切换至柱状图、详情弹窗
  3. 打开详情弹窗后可以通过下拉搜索框进行输入搜索选择要添加至图表的项目,也可进行删除

img

img

项目中间部分的雷达图和虚拟列表可以进行交互,点击列表的项目可以添加至雷达图,点击雷达图某个项目可以展示详情,点击 remove 可以移除

img

img

使用说明

  1. npm install 或 yarn
  2. npm run dev
  3. 代码提交需要符合 Eslint、Commitlint、Stylelint 等规范
  4. 使用前请在 vscode 安装 Prettier Eslint Stylelint 等插件,方便格式化代码

项目亮点

  • 实现对不同大小的屏幕/设备的良好适配以及针对小屏幕设备有不同的布局以及兼容
  • 不定高无限滚动加载虚拟列表的实现,控制列表渲染数据量的同时实现列表无限滚动
参数/事件 说明 类型 默认值
dataSource 传入的数组 Array 必传
loading 分页加载loading状态 Boolean 必传
estimatedHeight 每一项的初始高度,用于传入渲染后再通过计算得到不定高列表的真实高度 Number 必传
@scrollEnd 列表滚动到底部触发的方法 Function -
<virtual-list
	:data-source="github.dataSource"
	:loading="github.loading"
	:estimated-height="30"
	@scroll-end="github.addData"
	class="virtual-list"
>
	<template #item="{ item }">
		<a-tooltip placement="top" color="rgba(73, 146, 255, 0.8)">
			<template #title>
				<span>项目名:{{ item.name }}</span>
			</template>
			<div class="virtual-list-item" @click="radarFirst.chart.addRadarData(item.name)">
				<span class="virtual-list-item-col">{{ item.name }}</span>
				<span class="virtual-list-item-col">{{ item.influence }}</span>
				<span class="virtual-list-item-col">{{ item.trend }}</span>
				<span class="virtual-list-item-col">{{ item.response }}</span>
				<span class="virtual-list-item-col">{{ item.activity }}</span>
				<span class="virtual-list-item-col">{{ item.github }}</span>
			</div>
		</a-tooltip>
	</template>
</virtual-list>
  • Echarts 图表相关 hooks 的封装,提高如折柱混合图、图表详情弹窗的代码复用性
  • 实现下拉搜索选择框、列表与图表之间的增删交互,根据文档解决雷达图等图表增删时的异常问题
  • 使用 transition 标签以及图片预加载来优化图片未加载完全等导致的用户视觉体验问题
  • 实现 Echarts 等组件的按需加载。在打包过程中对项目大体积模块进行分块打包以及优化项目字体文件大小

参与贡献

  1. 根据 dev 分支创建新分支
  2. 在新分支上开发 提交代码时 pull dev 分支的代码再提交
  3. 之后在 gitee 上发起代码合并请求,请求将代码合并至 master
  4. 有问题与想法欢迎大家提Issues
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/chenyijun0119/DM_screen_web.git
git@gitee.com:chenyijun0119/DM_screen_web.git
chenyijun0119
DM_screen_web
DM_screen_web
master

搜索帮助

344bd9b3 5694891 D2dac590 5694891