@bdsoft/element 1.1.13 → 1.1.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.html +13 -0
- package/index.js +12 -12
- package/package.json +19 -23
- package/src/App.vue +28 -0
- package/src/assets/css/element.scss +196 -0
- package/src/assets/css/layout.scss +215 -0
- package/src/assets/css/tailwind.scss +67 -0
- package/src/assets/images/banner.gif +0 -0
- package/src/assets/images/banner.png +0 -0
- package/src/assets/images/bg1.svg +22 -0
- package/src/assets/images/bg2.png +0 -0
- package/src/assets/images/ff.png +0 -0
- package/src/assets/images/home-file1.png +0 -0
- package/src/assets/images/ky.png +0 -0
- package/src/assets/images/menu/add.png +0 -0
- package/src/assets/images/menu/del.png +0 -0
- package/src/assets/images/menu/down.png +0 -0
- package/src/assets/images/menu/dr.png +0 -0
- package/src/assets/images/menu/edit.png +0 -0
- package/src/assets/images/menu/kx.png +0 -0
- package/src/assets/images/menu/mb.png +0 -0
- package/src/assets/images/menu/pz.png +0 -0
- package/src/assets/images/menu/save.png +0 -0
- package/src/assets/images/menu/sj.png +0 -0
- package/src/assets/images/menu/sjk.png +0 -0
- package/src/assets/images/menu/up.png +0 -0
- package/src/assets/images/po-i.png +0 -0
- package/src/assets/images/po1-i1.png +0 -0
- package/src/assets/images/po1-i2.png +0 -0
- package/src/assets/images/po1-i3.png +0 -0
- package/src/assets/images/po1-i4.png +0 -0
- package/src/assets/images/po1-i5.png +0 -0
- package/src/assets/images/po1-i6.png +0 -0
- package/src/assets/images/po1-i7.png +0 -0
- package/src/assets/images/po1-i8.png +0 -0
- package/src/assets/images/po2-i1.png +0 -0
- package/src/assets/images/po2-i2.png +0 -0
- package/src/assets/images/po3-i1.png +0 -0
- package/src/assets/images/po4-i1.png +0 -0
- package/src/assets/images/po5-i1.png +0 -0
- package/src/assets/images/po6-i1.png +0 -0
- package/src/assets/images/po6-i2.png +0 -0
- package/src/assets/images/po7-i1.png +0 -0
- package/src/assets/images/tj1.png +0 -0
- package/src/assets/images/tj2.png +0 -0
- package/src/assets/images/tj3.png +0 -0
- package/src/components/3dcloudwords/index.js +346 -0
- package/src/components/3dcloudwords/index.vue +99 -0
- package/src/components/3dcloudwords/readme.md +66 -0
- package/src/components/badge/index.js +167 -0
- package/src/components/badge/index.scss +166 -0
- package/src/components/badge/index.vue +98 -0
- package/src/components/badge/readme.md +18 -0
- package/src/components/basic/Finish.vue +107 -0
- package/src/components/basic/button.vue +19 -0
- package/src/components/basic/readme.md +7 -0
- package/src/components/button/index.vue +48 -0
- package/src/components/button/readme.md +62 -0
- package/src/components/carousel/index.vue +104 -0
- package/src/components/carousel/readme.md +12 -0
- package/src/components/chartconfig/index.vue +141 -0
- package/src/components/chartconfig/readme.md +25 -0
- package/src/components/contextMenu/hookContxtMenu.js +41 -0
- package/src/components/contextMenu/index.vue +245 -0
- package/src/components/contextMenu/readme.md +55 -0
- package/src/components/contextMenu/useElementBounding.js +40 -0
- package/src/components/countup/countUp.js +196 -0
- package/src/components/countup/index.vue +114 -0
- package/src/components/countup/readme.md +9 -0
- package/src/components/empty/assets/build.png +0 -0
- package/src/components/empty/assets/emptybg.gif +0 -0
- package/src/components/empty/assets/emptybg.png +0 -0
- package/src/components/empty/assets/emptybg2.jpg +0 -0
- package/src/components/empty/assets/emptybg3.jpg +0 -0
- package/src/components/empty/assets/wuxiao.png +0 -0
- package/src/components/empty/assets/wuxiao.webp +0 -0
- package/src/components/empty/building.vue +117 -0
- package/src/components/empty/empty.vue +120 -0
- package/src/components/empty/index.js +12 -0
- package/src/components/empty/invalid.vue +56 -0
- package/src/components/error/Error.vue +79 -0
- package/src/components/error/readme.md +20 -0
- package/src/components/form/Form.vue +84 -0
- package/src/components/form/FormItem.vue +143 -0
- package/src/components/form/data.js +52 -0
- package/src/components/form/readme.md +69 -0
- package/src/components/layout/banner.vue +412 -0
- package/src/components/layout/bar.vue +43 -0
- package/src/components/layout/layout1.vue +60 -0
- package/src/components/layout/layout2.vue +134 -0
- package/src/components/layout/layout3.vue +107 -0
- package/src/components/layout/layout4.vue +66 -0
- package/src/components/layout/nav.vue +333 -0
- package/src/components/layout/readme.md +61 -0
- package/src/components/loading/index.vue +122 -0
- package/src/components/loading/readme.md +6 -0
- package/src/components/notice/NoticeList.vue +198 -0
- package/src/components/notice/NoticeListPaging.vue +281 -0
- package/src/components/notice/NoticeView.vue +92 -0
- package/src/components/notice/readme.md +1 -0
- package/src/components/pagination/index.vue +100 -0
- package/src/components/pagination/readme.md +19 -0
- package/src/components/pagination/scroll-to.js +51 -0
- package/src/components/progress/bar.vue +72 -0
- package/src/components/progress/progress.vue +58 -0
- package/src/components/screenfull/index.js +3 -0
- package/src/components/screenfull/index.vue +65 -0
- package/src/components/screenfull/package.json +15 -0
- package/src/components/screenfull/readme.md +6 -0
- package/src/components/statisticalCount/index.vue +80 -0
- package/src/components/statisticalCount/readme.md +21 -0
- package/src/components/username/index.vue +79 -0
- package/src/components/username/readme.md +22 -0
- package/src/components/username//346/225/210/346/236/234/345/233/276.png +0 -0
- package/src/global/index.ts +6 -0
- package/src/global/register-properties.ts +10 -0
- package/src/index.js +88 -0
- package/src/utils/coms/load.jsx +10 -0
- package/src/utils/func.js +62 -0
- package/src/utils/hookDialog.js +38 -0
- package/src/utils/hookPage.js +49 -0
- package/src/utils/index.js +5 -0
- package/src/utils/lib/console.js +39 -0
- package/src/utils/lib/debounce.js +19 -0
- package/src/utils/lib/deepextend.js +51 -0
- package/src/utils/lib/deepset.js +14 -0
- package/src/utils/lib/extend.js +28 -0
- package/src/utils/lib/index.js +13 -0
- package/src/utils/lib/json.js +90 -0
- package/src/utils/lib/mergeprops.js +62 -0
- package/src/utils/lib/mitt.js +43 -0
- package/src/utils/lib/modify.js +8 -0
- package/src/utils/lib/slot.js +19 -0
- package/src/utils/lib/toarray.js +5 -0
- package/src/utils/lib/tocase.js +11 -0
- package/src/utils/lib/todate.js +10 -0
- package/src/utils/lib/toline.js +10 -0
- package/src/utils/lib/tostring.js +7 -0
- package/src/utils/lib/type.js +45 -0
- package/src/utils/lib/unique.js +6 -0
- package/src/utils/message.js +164 -0
- package/src/utils/type.js +45 -0
- package/src/xm_components/HeadSearch/hook/hookSearch.js +96 -0
- package/src/xm_components/HeadSearch/index.vue +206 -0
- package/src/xm_components/HeadSearch/readme.md +12 -0
- package/src/xm_components/HeadSearch//346/220/234/347/264/242/345/210/227/350/241/250.png +0 -0
- package/src/xm_components/Milestone/index.vue +213 -0
- package/src/xm_components/Milestone/readme.md +15 -0
- package/src/xm_components/MultiStatisticalCard/image.png +0 -0
- package/src/xm_components/MultiStatisticalCard/index.vue +114 -0
- package/src/xm_components/MultiStatisticalCard/readme.md +29 -0
- package/src/xm_components/StatisticalCard/image.png +0 -0
- package/src/xm_components/StatisticalCard/index.vue +196 -0
- package/src/xm_components/StatisticalCard/readme.md +41 -0
- package/src/xm_components/readme.md +1 -0
- package/vite.config.js +58 -0
- package/dist/BdElement.js +0 -23432
|
@@ -0,0 +1,196 @@
|
|
|
1
|
+
// target = id of html element or var of previously selected html element where counting occurs
|
|
2
|
+
// startVal = the value you want to begin at
|
|
3
|
+
// endVal = the value you want to arrive at
|
|
4
|
+
// decimals = number of decimal places, default 0
|
|
5
|
+
// duration = duration of animation in seconds, default 2
|
|
6
|
+
// options = optional object of options (see below)
|
|
7
|
+
|
|
8
|
+
var CountUp = function (target, startVal, endVal, decimals, duration, options) {
|
|
9
|
+
// make sure requestAnimationFrame and cancelAnimationFrame are defined
|
|
10
|
+
// polyfill for browsers without native support
|
|
11
|
+
// by Opera engineer Erik Möller
|
|
12
|
+
var lastTime = 0
|
|
13
|
+
var vendors = ['webkit', 'moz', 'ms', 'o']
|
|
14
|
+
for (var x = 0; x < vendors.length && !window.requestAnimationFrame; ++x) {
|
|
15
|
+
window.requestAnimationFrame = window[vendors[x] + 'RequestAnimationFrame']
|
|
16
|
+
window.cancelAnimationFrame = window[vendors[x] + 'CancelAnimationFrame'] || window[vendors[x] + 'CancelRequestAnimationFrame']
|
|
17
|
+
}
|
|
18
|
+
if (!window.requestAnimationFrame) {
|
|
19
|
+
window.requestAnimationFrame = function (callback, element) {
|
|
20
|
+
var currTime = new Date().getTime()
|
|
21
|
+
var timeToCall = Math.max(0, 16 - (currTime - lastTime))
|
|
22
|
+
var id = window.setTimeout(function () {
|
|
23
|
+
callback(currTime + timeToCall)
|
|
24
|
+
}, timeToCall)
|
|
25
|
+
lastTime = currTime + timeToCall
|
|
26
|
+
return id
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
if (!window.cancelAnimationFrame) {
|
|
30
|
+
window.cancelAnimationFrame = function (id) {
|
|
31
|
+
clearTimeout(id)
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
var self = this
|
|
36
|
+
|
|
37
|
+
// default options
|
|
38
|
+
self.options = {
|
|
39
|
+
useEasing: true, // toggle easing
|
|
40
|
+
useGrouping: true, // 1,000,000 vs 1000000
|
|
41
|
+
separator: ',', // character to use as a separator
|
|
42
|
+
decimal: '.', // character to use as a decimal
|
|
43
|
+
easingFn: null, // optional custom easing closure function, default is Robert Penner's easeOutExpo
|
|
44
|
+
formattingFn: null // optional custom formatting function, default is self.formatNumber below
|
|
45
|
+
}
|
|
46
|
+
// extend default options with passed options object
|
|
47
|
+
for (var key in options) {
|
|
48
|
+
if (options.hasOwnProperty(key)) {
|
|
49
|
+
self.options[key] = options[key]
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
if (self.options.separator === '') {
|
|
53
|
+
self.options.useGrouping = false
|
|
54
|
+
}
|
|
55
|
+
if (!self.options.prefix) self.options.prefix = ''
|
|
56
|
+
if (!self.options.suffix) self.options.suffix = ''
|
|
57
|
+
|
|
58
|
+
self.d = typeof target === 'string' ? document.getElementById(target) : target
|
|
59
|
+
self.startVal = Number(startVal)
|
|
60
|
+
self.endVal = Number(endVal)
|
|
61
|
+
self.countDown = self.startVal > self.endVal
|
|
62
|
+
self.frameVal = self.startVal
|
|
63
|
+
self.decimals = Math.max(0, decimals || 0)
|
|
64
|
+
self.dec = Math.pow(10, self.decimals)
|
|
65
|
+
self.duration = Number(duration) * 1000 || 2000
|
|
66
|
+
|
|
67
|
+
self.formatNumber = function (nStr) {
|
|
68
|
+
nStr = nStr.toFixed(self.decimals)
|
|
69
|
+
nStr += ''
|
|
70
|
+
var x, x1, x2, rgx
|
|
71
|
+
x = nStr.split('.')
|
|
72
|
+
x1 = x[0]
|
|
73
|
+
x2 = x.length > 1 ? self.options.decimal + x[1] : ''
|
|
74
|
+
rgx = /(\d+)(\d{3})/
|
|
75
|
+
if (self.options.useGrouping) {
|
|
76
|
+
while (rgx.test(x1)) {
|
|
77
|
+
x1 = x1.replace(rgx, '$1' + self.options.separator + '$2')
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
return self.options.prefix + x1 + x2 + self.options.suffix
|
|
81
|
+
}
|
|
82
|
+
// Robert Penner's easeOutExpo
|
|
83
|
+
self.easeOutExpo = function (t, b, c, d) {
|
|
84
|
+
return (c * (-Math.pow(2, (-10 * t) / d) + 1) * 1024) / 1023 + b
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
self.easingFn = self.options.easingFn ? self.options.easingFn : self.easeOutExpo
|
|
88
|
+
self.formattingFn = self.options.formattingFn ? self.options.formattingFn : self.formatNumber
|
|
89
|
+
|
|
90
|
+
self.version = function () {
|
|
91
|
+
return '1.7.1'
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
// Print value to target
|
|
95
|
+
self.printValue = function (value) {
|
|
96
|
+
var result = self.formattingFn(value)
|
|
97
|
+
|
|
98
|
+
if (self.d?.tagName === 'INPUT') {
|
|
99
|
+
this.d.value = result
|
|
100
|
+
} else if (self.d?.tagName === 'text' || self.d?.tagName === 'tspan') {
|
|
101
|
+
this.d.textContent = result
|
|
102
|
+
} else {
|
|
103
|
+
this.d.innerHTML = result
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
self.count = function (timestamp) {
|
|
108
|
+
if (!self.startTime) {
|
|
109
|
+
self.startTime = timestamp
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
self.timestamp = timestamp
|
|
113
|
+
var progress = timestamp - self.startTime
|
|
114
|
+
self.remaining = self.duration - progress
|
|
115
|
+
|
|
116
|
+
// to ease or not to ease
|
|
117
|
+
if (self.options.useEasing) {
|
|
118
|
+
if (self.countDown) {
|
|
119
|
+
self.frameVal = self.startVal - self.easingFn(progress, 0, self.startVal - self.endVal, self.duration)
|
|
120
|
+
} else {
|
|
121
|
+
self.frameVal = self.easingFn(progress, self.startVal, self.endVal - self.startVal, self.duration)
|
|
122
|
+
}
|
|
123
|
+
} else {
|
|
124
|
+
if (self.countDown) {
|
|
125
|
+
self.frameVal = self.startVal - (self.startVal - self.endVal) * (progress / self.duration)
|
|
126
|
+
} else {
|
|
127
|
+
self.frameVal = self.startVal + (self.endVal - self.startVal) * (progress / self.duration)
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
// don't go past endVal since progress can exceed duration in the last frame
|
|
132
|
+
if (self.countDown) {
|
|
133
|
+
self.frameVal = self.frameVal < self.endVal ? self.endVal : self.frameVal
|
|
134
|
+
} else {
|
|
135
|
+
self.frameVal = self.frameVal > self.endVal ? self.endVal : self.frameVal
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
// decimal
|
|
139
|
+
self.frameVal = Math.round(self.frameVal * self.dec) / self.dec
|
|
140
|
+
|
|
141
|
+
// format and print value
|
|
142
|
+
self.printValue(self.frameVal)
|
|
143
|
+
|
|
144
|
+
// whether to continue
|
|
145
|
+
if (progress < self.duration) {
|
|
146
|
+
self.rAF = requestAnimationFrame(self.count)
|
|
147
|
+
} else {
|
|
148
|
+
if (self.callback) {
|
|
149
|
+
self.callback()
|
|
150
|
+
}
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
// start your animation
|
|
154
|
+
self.start = function (callback) {
|
|
155
|
+
self.callback = callback
|
|
156
|
+
self.rAF = requestAnimationFrame(self.count)
|
|
157
|
+
return false
|
|
158
|
+
}
|
|
159
|
+
// toggles pause/resume animation
|
|
160
|
+
self.pauseResume = function () {
|
|
161
|
+
if (!self.paused) {
|
|
162
|
+
self.paused = true
|
|
163
|
+
cancelAnimationFrame(self.rAF)
|
|
164
|
+
} else {
|
|
165
|
+
self.paused = false
|
|
166
|
+
delete self.startTime
|
|
167
|
+
self.duration = self.remaining
|
|
168
|
+
self.startVal = self.frameVal
|
|
169
|
+
requestAnimationFrame(self.count)
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
// reset to startVal so animation can be run again
|
|
173
|
+
self.reset = function () {
|
|
174
|
+
self.paused = false
|
|
175
|
+
delete self.startTime
|
|
176
|
+
self.startVal = startVal
|
|
177
|
+
cancelAnimationFrame(self.rAF)
|
|
178
|
+
self.printValue(self.startVal)
|
|
179
|
+
}
|
|
180
|
+
// pass a new endVal and start animation
|
|
181
|
+
self.update = function (newEndVal) {
|
|
182
|
+
cancelAnimationFrame(self.rAF)
|
|
183
|
+
self.paused = false
|
|
184
|
+
delete self.startTime
|
|
185
|
+
self.startVal = self.frameVal
|
|
186
|
+
self.endVal = Number(newEndVal)
|
|
187
|
+
self.countDown = self.startVal > self.endVal
|
|
188
|
+
self.rAF = requestAnimationFrame(self.count)
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
// format startVal on initialization
|
|
192
|
+
self.printValue(self.startVal)
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
export { CountUp }
|
|
196
|
+
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
* @FileDescription: 统计组件
|
|
3
|
+
* @Author: 李兵泉
|
|
4
|
+
* @Date: 2021-06-08 09 时
|
|
5
|
+
* @LastEditors: 最后更新作者
|
|
6
|
+
* @LastEditTime: 最后更新时间
|
|
7
|
+
-->
|
|
8
|
+
<script setup>
|
|
9
|
+
import { ref, reactive, nextTick, watch, onMounted } from "vue";
|
|
10
|
+
import { CountUp } from './countUp.js'
|
|
11
|
+
const props = defineProps({
|
|
12
|
+
idName: {
|
|
13
|
+
type: String,
|
|
14
|
+
default: ''
|
|
15
|
+
},
|
|
16
|
+
// 标题显示
|
|
17
|
+
title: {
|
|
18
|
+
type: String,
|
|
19
|
+
default: ''
|
|
20
|
+
},
|
|
21
|
+
startVal: {
|
|
22
|
+
type: Number,
|
|
23
|
+
default: 0
|
|
24
|
+
},
|
|
25
|
+
endVal: {
|
|
26
|
+
type: Number,
|
|
27
|
+
default: 0
|
|
28
|
+
},
|
|
29
|
+
iconType: {
|
|
30
|
+
type: String,
|
|
31
|
+
default: ''
|
|
32
|
+
},
|
|
33
|
+
color: {
|
|
34
|
+
type: String,
|
|
35
|
+
default: '#3b3a3a' // D9524E
|
|
36
|
+
},
|
|
37
|
+
introText: {
|
|
38
|
+
type: String,
|
|
39
|
+
default: ''
|
|
40
|
+
},
|
|
41
|
+
docTypeText: {
|
|
42
|
+
type: String,
|
|
43
|
+
default: ''
|
|
44
|
+
},
|
|
45
|
+
countSize: {
|
|
46
|
+
type: String,
|
|
47
|
+
default: `30px`
|
|
48
|
+
},
|
|
49
|
+
countWeight: {
|
|
50
|
+
type: Number,
|
|
51
|
+
default: 700
|
|
52
|
+
},
|
|
53
|
+
delay: {
|
|
54
|
+
type: Number,
|
|
55
|
+
default: 500
|
|
56
|
+
}
|
|
57
|
+
})
|
|
58
|
+
const className = ref('')
|
|
59
|
+
|
|
60
|
+
function transformValue (val) {
|
|
61
|
+
let endVal = 0
|
|
62
|
+
let unit = ''
|
|
63
|
+
if (val < 1000) {
|
|
64
|
+
endVal = val
|
|
65
|
+
} else if (val >= 1000 && val < 1000000) {
|
|
66
|
+
endVal = parseInt(val / 1000)
|
|
67
|
+
unit = 'K+'
|
|
68
|
+
} else if (val >= 1000000 && val < 10000000000) {
|
|
69
|
+
endVal = parseInt(val / 1000000)
|
|
70
|
+
unit = 'M+'
|
|
71
|
+
} else {
|
|
72
|
+
endVal = parseInt(val / 1000000000)
|
|
73
|
+
unit = 'B+'
|
|
74
|
+
}
|
|
75
|
+
return {
|
|
76
|
+
val: endVal,
|
|
77
|
+
unit: unit
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
let demo = {}
|
|
81
|
+
|
|
82
|
+
watch(() => props.endVal, (val) => {
|
|
83
|
+
const endVal = val
|
|
84
|
+
if (demo.update) { demo.update(endVal) }
|
|
85
|
+
})
|
|
86
|
+
|
|
87
|
+
onMounted(() => {
|
|
88
|
+
nextTick(() => {
|
|
89
|
+
setTimeout(() => {
|
|
90
|
+
|
|
91
|
+
const res = transformValue(props.endVal)
|
|
92
|
+
const endVal = props.endVal // res.val
|
|
93
|
+
let idname = props.idName
|
|
94
|
+
demo = new CountUp(props.idName, props.startVal, endVal, props.decimals, props.duration, props.options)
|
|
95
|
+
if (!demo.error) {
|
|
96
|
+
demo.start()
|
|
97
|
+
}
|
|
98
|
+
}, props.delay)
|
|
99
|
+
})
|
|
100
|
+
})
|
|
101
|
+
|
|
102
|
+
</script>
|
|
103
|
+
<template>
|
|
104
|
+
<div>
|
|
105
|
+
<div v-if="title" style="color: #606266;">{{ title }}</div>
|
|
106
|
+
<div :class="className"
|
|
107
|
+
:style="{ textAlign: 'center', color: color, fontSize: countSize, fontWeight: countWeight, fontFamily: 'PingFang SC' }">
|
|
108
|
+
<span v-cloak :id="idName">{{ startVal }}</span>
|
|
109
|
+
</div>
|
|
110
|
+
<slot name="intro"></slot>
|
|
111
|
+
</div>
|
|
112
|
+
</template>
|
|
113
|
+
|
|
114
|
+
<style lang="scss" scoped></style>
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
# 动态计数组件
|
|
2
|
+
11
|
|
3
|
+
## 示例
|
|
4
|
+
```
|
|
5
|
+
import {BdCountUp} from '@bdsoft/element';
|
|
6
|
+
<count-up class="infor-intro-num user-created-count" id-name="idName3"
|
|
7
|
+
:end-val="statistics.moduleusecount" color="rgba(5, 76, 232, 1)" :countSize="1033" :countWeight="700">
|
|
8
|
+
</count-up>
|
|
9
|
+
```
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
* @FileDescription: 正在建设中
|
|
3
|
+
* @Author: 李兵泉
|
|
4
|
+
* @Date: 2025-03-24
|
|
5
|
+
* @LastEditors: 最后更新作者
|
|
6
|
+
* @LastEditTime: 最后更新时间
|
|
7
|
+
-->
|
|
8
|
+
<script setup>
|
|
9
|
+
import { computed } from "vue";
|
|
10
|
+
const props = defineProps({
|
|
11
|
+
paddingTop: {
|
|
12
|
+
type: String,
|
|
13
|
+
default: '20%'
|
|
14
|
+
},
|
|
15
|
+
// 是自定义图片展示还是默认svg展示 img /svg
|
|
16
|
+
imgType: {
|
|
17
|
+
type: String,
|
|
18
|
+
default: 'img'
|
|
19
|
+
},
|
|
20
|
+
imgSize: {
|
|
21
|
+
type: Number,
|
|
22
|
+
default: 200
|
|
23
|
+
},
|
|
24
|
+
// 可以接收第三方URL地址
|
|
25
|
+
imgUrl: {
|
|
26
|
+
type: String,
|
|
27
|
+
default: ''
|
|
28
|
+
},
|
|
29
|
+
// 指定默认图
|
|
30
|
+
imgName: {
|
|
31
|
+
type: String,
|
|
32
|
+
default: 'build.png'
|
|
33
|
+
},
|
|
34
|
+
// 图片的高
|
|
35
|
+
imgHeight: {
|
|
36
|
+
type: String,
|
|
37
|
+
default: '506px'
|
|
38
|
+
},
|
|
39
|
+
// 图片的宽
|
|
40
|
+
imgWidth: {
|
|
41
|
+
type: String,
|
|
42
|
+
default: '900px'
|
|
43
|
+
},
|
|
44
|
+
// 支持缩放
|
|
45
|
+
scale: {
|
|
46
|
+
type: Number,
|
|
47
|
+
default: 1
|
|
48
|
+
},
|
|
49
|
+
// svg的描述
|
|
50
|
+
des:{
|
|
51
|
+
type: String,
|
|
52
|
+
default: ''
|
|
53
|
+
}
|
|
54
|
+
});
|
|
55
|
+
|
|
56
|
+
const imgUrlPath = computed(() => {
|
|
57
|
+
if (props.imgUrl) {
|
|
58
|
+
return props.imgUrl;
|
|
59
|
+
} else if (props.imgName) {
|
|
60
|
+
return new URL(`./assets/${props.imgName}`, import.meta.url).href;
|
|
61
|
+
}
|
|
62
|
+
// return props.imgUrl? props.imgUrl : new URL('./assets/emptybg2.jpg', import.meta.url).href ;
|
|
63
|
+
});
|
|
64
|
+
</script>
|
|
65
|
+
<template>
|
|
66
|
+
<div ref="emptywarpRef" id="emptywarp">
|
|
67
|
+
|
|
68
|
+
<div style="width: 820px; margin: 0 auto; overflow: hidden;text-align:center" >
|
|
69
|
+
<img id="bdelogo" class="menubar" ref="bdlogoRef" :src="imgUrlPath" alt=""
|
|
70
|
+
:style="{ marginTop: props.paddingTop, height: props.imgHeight, width: props.imgWidth ,transform: `scale(${scale})`}" />
|
|
71
|
+
<br/>
|
|
72
|
+
<span style="color: #bec0c3;font-size: 20px;">{{ des }}</span>
|
|
73
|
+
</div>
|
|
74
|
+
</div>
|
|
75
|
+
</template>
|
|
76
|
+
|
|
77
|
+
<style lang="scss" scoped>
|
|
78
|
+
#emptywarp {
|
|
79
|
+
width: 100%;
|
|
80
|
+
height: 100%;
|
|
81
|
+
margin: 0 auto;
|
|
82
|
+
display: flex;
|
|
83
|
+
transform-style: preserve-3d;
|
|
84
|
+
perspective: 200px;
|
|
85
|
+
cursor: pointer;
|
|
86
|
+
overflow: hidden;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
#bdelogo {
|
|
90
|
+
margin: auto;
|
|
91
|
+
width: 715px;
|
|
92
|
+
height: 493px;
|
|
93
|
+
transform-style: preserve-3d;
|
|
94
|
+
transition: all 0.2s;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
.menubar {
|
|
98
|
+
// animation: im_icon 2s linear infinite;
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
@keyframes im_icon {
|
|
102
|
+
0% {
|
|
103
|
+
// opacity: 0.8;
|
|
104
|
+
transform: translate(0, 0);
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
50% {
|
|
108
|
+
// opacity: 1;
|
|
109
|
+
transform: translate(0, 5px);
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
100% {
|
|
113
|
+
// opacity: 0.8;
|
|
114
|
+
transform: translate(0, 0);
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
</style>
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
* @FileDescription: 空页面 数据未加载前显示 后续可完善能动态元素的效果
|
|
3
|
+
* @Author: 李兵泉
|
|
4
|
+
* @Date: 2021-06-08 09 时
|
|
5
|
+
* @LastEditors: 最后更新作者
|
|
6
|
+
* @LastEditTime: 最后更新时间
|
|
7
|
+
-->
|
|
8
|
+
<script setup>
|
|
9
|
+
import { computed } from "vue";
|
|
10
|
+
const props = defineProps({
|
|
11
|
+
paddingTop: {
|
|
12
|
+
type: String,
|
|
13
|
+
default: '20%'
|
|
14
|
+
},
|
|
15
|
+
// 是自定义图片展示还是默认svg展示 img /svg
|
|
16
|
+
imgType: {
|
|
17
|
+
type: String,
|
|
18
|
+
default: 'img'
|
|
19
|
+
},
|
|
20
|
+
imgSize: {
|
|
21
|
+
type: Number,
|
|
22
|
+
default: 200
|
|
23
|
+
},
|
|
24
|
+
// 可以接收第三方URL地址
|
|
25
|
+
imgUrl: {
|
|
26
|
+
type: String,
|
|
27
|
+
default: ''
|
|
28
|
+
},
|
|
29
|
+
// 指定默认图
|
|
30
|
+
imgName: {
|
|
31
|
+
type: String,
|
|
32
|
+
default: 'emptybg.png'
|
|
33
|
+
},
|
|
34
|
+
// 图片的高
|
|
35
|
+
imgHeight: {
|
|
36
|
+
type: String,
|
|
37
|
+
default: '493px'
|
|
38
|
+
},
|
|
39
|
+
// 图片的宽
|
|
40
|
+
imgWidth: {
|
|
41
|
+
type: String,
|
|
42
|
+
default: '715px'
|
|
43
|
+
},
|
|
44
|
+
// 支持缩放
|
|
45
|
+
scale: {
|
|
46
|
+
type: Number,
|
|
47
|
+
default: 1
|
|
48
|
+
},
|
|
49
|
+
// svg的描述
|
|
50
|
+
des:{
|
|
51
|
+
type: String,
|
|
52
|
+
default: '无数据'
|
|
53
|
+
}
|
|
54
|
+
});
|
|
55
|
+
|
|
56
|
+
const imgUrlPath = computed(() => {
|
|
57
|
+
if (props.imgUrl) {
|
|
58
|
+
return props.imgUrl;
|
|
59
|
+
} else if (props.imgName) {
|
|
60
|
+
return new URL(`./assets/${props.imgName}`, import.meta.url).href;
|
|
61
|
+
}
|
|
62
|
+
// return props.imgUrl? props.imgUrl : new URL('./assets/emptybg2.jpg', import.meta.url).href ;
|
|
63
|
+
});
|
|
64
|
+
</script>
|
|
65
|
+
<template>
|
|
66
|
+
<div ref="emptywarpRef" id="emptywarp">
|
|
67
|
+
<div v-if="imgType == 'svg'" style="width: 420px; margin: 0 auto; overflow: hidden" >
|
|
68
|
+
<el-empty :image-size="imgSize" :description="des" />
|
|
69
|
+
</div>
|
|
70
|
+
|
|
71
|
+
<div v-else style="width: 820px; margin: 0 auto; overflow: hidden;text-align:center" >
|
|
72
|
+
<img id="bdelogo" class="menubar" ref="bdlogoRef" :src="imgUrlPath" alt=""
|
|
73
|
+
:style="{ marginTop: props.paddingTop, height: props.imgHeight, width: props.imgWidth ,transform: `scale(${scale})`}" />
|
|
74
|
+
<br/>
|
|
75
|
+
<span style="color: #bec0c3;font-size: 20px;">{{ des }}</span>
|
|
76
|
+
</div>
|
|
77
|
+
</div>
|
|
78
|
+
</template>
|
|
79
|
+
|
|
80
|
+
<style lang="scss" scoped>
|
|
81
|
+
#emptywarp {
|
|
82
|
+
width: 100%;
|
|
83
|
+
height: 100%;
|
|
84
|
+
margin: 0 auto;
|
|
85
|
+
display: flex;
|
|
86
|
+
transform-style: preserve-3d;
|
|
87
|
+
perspective: 200px;
|
|
88
|
+
cursor: pointer;
|
|
89
|
+
overflow: hidden;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
#bdelogo {
|
|
93
|
+
margin: auto;
|
|
94
|
+
width: 715px;
|
|
95
|
+
height: 493px;
|
|
96
|
+
transform-style: preserve-3d;
|
|
97
|
+
transition: all 0.2s;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
.menubar {
|
|
101
|
+
animation: im_icon 2s linear infinite;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
@keyframes im_icon {
|
|
105
|
+
0% {
|
|
106
|
+
// opacity: 0.8;
|
|
107
|
+
transform: translate(0, 0);
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
50% {
|
|
111
|
+
// opacity: 1;
|
|
112
|
+
transform: translate(0, 5px);
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
100% {
|
|
116
|
+
// opacity: 0.8;
|
|
117
|
+
transform: translate(0, 0);
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
</style>
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
* @FileDescription: 空页面 数据未加载前显示 后续可完善能动态元素的效果
|
|
3
|
+
* @Author: 李兵泉
|
|
4
|
+
* @Date: 2021-06-08 09 时
|
|
5
|
+
* @LastEditors: 最后更新作者
|
|
6
|
+
* @LastEditTime: 最后更新时间
|
|
7
|
+
-->
|
|
8
|
+
<script setup>
|
|
9
|
+
import { computed } from "vue";
|
|
10
|
+
import empty from "./empty.vue";
|
|
11
|
+
</script>
|
|
12
|
+
<template>
|
|
13
|
+
<empty imgName="wuxiao.png" imgWidth="100%" des="" imgHeight="auto"></empty>
|
|
14
|
+
</template>
|
|
15
|
+
|
|
16
|
+
<style lang="scss" scoped>
|
|
17
|
+
#emptywarp {
|
|
18
|
+
width: 100%;
|
|
19
|
+
height: 100%;
|
|
20
|
+
margin: 0 auto;
|
|
21
|
+
display: flex;
|
|
22
|
+
transform-style: preserve-3d;
|
|
23
|
+
perspective: 200px;
|
|
24
|
+
cursor: pointer;
|
|
25
|
+
overflow: hidden;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
#bdelogo {
|
|
29
|
+
margin: auto;
|
|
30
|
+
width: 715px;
|
|
31
|
+
height: 493px;
|
|
32
|
+
transform-style: preserve-3d;
|
|
33
|
+
transition: all 0.2s;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
.menubar {
|
|
37
|
+
animation: im_icon 2s linear infinite;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
@keyframes im_icon {
|
|
41
|
+
0% {
|
|
42
|
+
// opacity: 0.8;
|
|
43
|
+
transform: translate(0, 0);
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
50% {
|
|
47
|
+
// opacity: 1;
|
|
48
|
+
transform: translate(0, 5px);
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
100% {
|
|
52
|
+
// opacity: 0.8;
|
|
53
|
+
transform: translate(0, 0);
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
</style>
|