摘要: vue快捷工具组件:小地图导航、全屏、刷新 效果 代码 <!-- * @description 快捷工具 !--> <template> <div class="quick-tools" :style="{ ...quickToolsStyle }"> <template v-for="val in 阅读全文
posted @ 2024-11-22 18:15 hong_li 阅读(102) 评论(0) 推荐(0)
摘要: 拖拽bar横向滚动页面组件 拖拽横向滚动页面,效果图如下 <!-- * @description 滑块滚动条 !--> <template> <div ref="scrollBarBoxRef" class="scroll-bar-box"> <div class="line"></div> <di 阅读全文
posted @ 2024-11-22 17:33 hong_li 阅读(216) 评论(0) 推荐(0)
摘要: 思路:使用多个移表盘叠加 效果图: 代码: setGaugeChart() { this.gaugeChart && this.gaugeChart?.dispose && this.gaugeChart?.dispose() this.gaugeChart = echarts.init(this. 阅读全文
posted @ 2024-11-20 10:07 hong_li 阅读(35) 评论(0) 推荐(0)
摘要: vue组件中,如何在less/scss中使用变量,以二次封装el-tab样式组件为例 <!-- * @description 封装el-tab样式 !--> <template> <div class="tab-comp" :style="{ '--item-max-width': itemMaxW 阅读全文
posted @ 2024-11-19 14:42 hong_li 阅读(122) 评论(0) 推荐(0)
摘要: tooltip配置 tooltip: { show: true, trigger: 'axis', formatter: params => { let result = `<div>${params[0].axisValue}</div>` params.forEach(item => { if 阅读全文
posted @ 2024-11-14 17:46 hong_li 阅读(160) 评论(0) 推荐(0)
摘要: echarts饼图在中间显示百分比,使用graphic setEchartOption(val) { const seriesData = [ { value: 1048, name: '完成值' }, { value: 735, name: '目标值' } ] const option = { g 阅读全文
posted @ 2024-11-14 17:44 hong_li 阅读(1212) 评论(0) 推荐(0)
摘要: 组织架构树形数据,且存在一个人员在多公司/或部门计数重复问题 // 统计组织架构内人员数量 const countNodesProperty = (treeItemData, propertyName, propertyValue) => { let count = 0 const userArr 阅读全文
posted @ 2024-11-14 11:51 hong_li 阅读(52) 评论(0) 推荐(0)
摘要: .text-ellipsis-2-line { width: 100%; height: 44px; font-size: 14px; line-height: 22px; word-break: break-all; text-overflow: ellipsis; overflow: hidde 阅读全文
posted @ 2024-11-07 15:16 hong_li 阅读(22) 评论(0) 推荐(0)
摘要: 因为img标签是行内标签自带间距,导致图片和div之间有间隙 <div class="img-container"> <img src="xxxxxxxxx" /> </div> <style lang='less'> .img-container { width: 200px; font-size 阅读全文
posted @ 2024-11-06 14:34 hong_li 阅读(12) 评论(0) 推荐(0)
摘要: this.$refs.rowRef.scrollIntoView({ block: 'start', behavior: 'smooth' }) 阅读全文
posted @ 2024-11-06 11:34 hong_li 阅读(19) 评论(0) 推荐(0)