vue2-client 1.18.36 → 1.18.37
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/.eslintrc.js +90 -90
- package/Components.md +60 -60
- package/docs/index.md +30 -30
- package/index.js +31 -31
- package/jest-transform-stub.js +8 -8
- package/jest.setup.js +7 -7
- package/package.json +1 -1
- package/src/assets/img/querySlotDemo.svg +15 -15
- package/src/base-client/components/common/AmapMarker/AmapPointRendering.vue +120 -120
- package/src/base-client/components/common/CitySelect/index.js +3 -3
- package/src/base-client/components/common/CitySelect/index.md +109 -109
- package/src/base-client/components/common/CreateQuery/CreateQuery.vue +669 -669
- package/src/base-client/components/common/CreateQuery/index.js +3 -3
- package/src/base-client/components/common/CreateQuery/index.md +42 -42
- package/src/base-client/components/common/CreateSimpleFormQuery/index.js +3 -3
- package/src/base-client/components/common/CreateSimpleFormQuery/index.md +42 -42
- package/src/base-client/components/common/FormGroupEdit/index.js +3 -3
- package/src/base-client/components/common/FormGroupEdit/index.md +43 -43
- package/src/base-client/components/common/FormGroupQuery/FormGroupQuery.vue +166 -166
- package/src/base-client/components/common/FormGroupQuery/index.js +3 -3
- package/src/base-client/components/common/FormGroupQuery/index.md +43 -43
- package/src/base-client/components/common/JSONToTree/jsontotree.vue +271 -271
- package/src/base-client/components/common/PersonSetting/PersonSetting.vue +208 -208
- package/src/base-client/components/common/PersonSetting/index.js +3 -3
- package/src/base-client/components/common/Tree/Tree.vue +149 -149
- package/src/base-client/components/common/Tree/index.js +2 -2
- package/src/base-client/components/common/Upload/index.js +3 -3
- package/src/base-client/components/common/XAddNativeForm/index.md +146 -146
- package/src/base-client/components/common/XCard/XCard.vue +64 -64
- package/src/base-client/components/common/XDataDrawer/XDataDrawer.vue +180 -180
- package/src/base-client/components/common/XDataDrawer/index.js +3 -3
- package/src/base-client/components/common/XDataDrawer/index.md +41 -41
- package/src/base-client/components/common/XDescriptions/XDescriptions.vue +174 -174
- package/src/base-client/components/common/XDescriptions/index.js +3 -3
- package/src/base-client/components/common/XDescriptions/index.md +322 -322
- package/src/base-client/components/common/XForm/index.md +178 -178
- package/src/base-client/components/common/XFormTable/demo.vue +125 -125
- package/src/base-client/components/common/XSimpleDescriptions/XSimpleDescriptions.vue +166 -166
- package/src/base-client/components/common/XStepView/XStepView.vue +252 -252
- package/src/base-client/components/common/XStepView/index.js +3 -3
- package/src/base-client/components/common/XStepView/index.md +31 -31
- package/src/base-client/components/common/XTable/XTable.vue +1715 -1715
- package/src/base-client/components/common/XTable/XTableWrapper.vue +759 -756
- package/src/base-client/components/common/XTable/index.md +255 -255
- package/src/base-client/components/system/DictionaryDetailsView/DictionaryDetailsView.vue +232 -232
- package/src/base-client/plugins/Config.js +19 -19
- package/src/base-client/plugins/tabs-page-plugin.js +39 -39
- package/src/components/Charts/Bar.vue +62 -62
- package/src/components/Charts/ChartCard.vue +134 -134
- package/src/components/Charts/Liquid.vue +67 -67
- package/src/components/Charts/MiniArea.vue +39 -39
- package/src/components/Charts/MiniBar.vue +39 -39
- package/src/components/Charts/MiniProgress.vue +75 -75
- package/src/components/Charts/MiniSmoothArea.vue +40 -40
- package/src/components/Charts/Radar.vue +68 -68
- package/src/components/Charts/RankList.vue +77 -77
- package/src/components/Charts/TagCloud.vue +113 -113
- package/src/components/Charts/TransferBar.vue +64 -64
- package/src/components/Charts/Trend.vue +82 -82
- package/src/components/Charts/chart.less +12 -12
- package/src/components/Charts/smooth.area.less +13 -13
- package/src/components/NumberInfo/NumberInfo.vue +54 -54
- package/src/components/NumberInfo/index.js +3 -3
- package/src/components/NumberInfo/index.less +54 -54
- package/src/components/NumberInfo/index.md +43 -43
- package/src/components/card/ChartCard.vue +79 -79
- package/src/components/chart/Bar.vue +60 -60
- package/src/components/chart/MiniArea.vue +67 -67
- package/src/components/chart/MiniBar.vue +59 -59
- package/src/components/chart/MiniProgress.vue +57 -57
- package/src/components/chart/Radar.vue +80 -80
- package/src/components/chart/RankingList.vue +60 -60
- package/src/components/chart/Trend.vue +79 -79
- package/src/components/chart/index.less +9 -9
- package/src/components/checkbox/ColorCheckbox.vue +157 -157
- package/src/components/input/IInput.vue +66 -66
- package/src/components/menu/SideMenu.vue +75 -75
- package/src/components/menu/menu.js +273 -273
- package/src/components/tool/AStepItem.vue +60 -60
- package/src/config/CreateQueryConfig.js +325 -325
- package/src/layouts/CommonLayout.vue +56 -56
- package/src/layouts/header/HeaderNotice.vue +177 -177
- package/src/lib.js +1 -1
- package/src/mock/extend/index.js +84 -84
- package/src/mock/goods/index.js +108 -108
- package/src/pages/XTreeOneProExample/index.vue +67 -67
- package/src/pages/dashboard/workplace/WorkPlace.vue +141 -141
- package/src/pages/system/dictionary/index.vue +44 -44
- package/src/pages/system/monitor/loginInfor/index.vue +37 -37
- package/src/pages/system/monitor/operLog/index.vue +37 -37
- package/src/services/api/cas.js +79 -79
- package/src/store/modules/setting.js +119 -119
- package/src/utils/authority-utils.js +85 -85
- package/src/utils/errorCode.js +6 -6
- package//350/277/201/347/247/273/346/227/245/345/277/227.md +15 -15
|
@@ -1,75 +1,75 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div class="chart-mini-progress">
|
|
3
|
-
<div class="target" :style="{ left: target + '%'}">
|
|
4
|
-
<span :style="{ backgroundColor: color }" />
|
|
5
|
-
<span :style="{ backgroundColor: color }"/>
|
|
6
|
-
</div>
|
|
7
|
-
<div class="progress-wrapper">
|
|
8
|
-
<div class="progress" :style="{ backgroundColor: color, width: percentage + '%', height: height }"></div>
|
|
9
|
-
</div>
|
|
10
|
-
</div>
|
|
11
|
-
</template>
|
|
12
|
-
|
|
13
|
-
<script>
|
|
14
|
-
export default {
|
|
15
|
-
name: 'MiniProgress',
|
|
16
|
-
props: {
|
|
17
|
-
target: {
|
|
18
|
-
type: Number,
|
|
19
|
-
default: 0
|
|
20
|
-
},
|
|
21
|
-
height: {
|
|
22
|
-
type: String,
|
|
23
|
-
default: '10px'
|
|
24
|
-
},
|
|
25
|
-
color: {
|
|
26
|
-
type: String,
|
|
27
|
-
default: '#13C2C2'
|
|
28
|
-
},
|
|
29
|
-
percentage: {
|
|
30
|
-
type: Number,
|
|
31
|
-
default: 0
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
</script>
|
|
36
|
-
|
|
37
|
-
<style lang="less" scoped>
|
|
38
|
-
.chart-mini-progress {
|
|
39
|
-
padding: 5px 0;
|
|
40
|
-
position: relative;
|
|
41
|
-
width: 100%;
|
|
42
|
-
|
|
43
|
-
.target {
|
|
44
|
-
position: absolute;
|
|
45
|
-
top: 0;
|
|
46
|
-
bottom: 0;
|
|
47
|
-
|
|
48
|
-
span {
|
|
49
|
-
border-radius: 100px;
|
|
50
|
-
position: absolute;
|
|
51
|
-
top: 0;
|
|
52
|
-
left: 0;
|
|
53
|
-
height: 4px;
|
|
54
|
-
width: 2px;
|
|
55
|
-
|
|
56
|
-
&:last-child {
|
|
57
|
-
top: auto;
|
|
58
|
-
bottom: 0;
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
}
|
|
62
|
-
.progress-wrapper {
|
|
63
|
-
background-color: #f5f5f5;
|
|
64
|
-
position: relative;
|
|
65
|
-
|
|
66
|
-
.progress {
|
|
67
|
-
transition: all .4s cubic-bezier(.08,.82,.17,1) 0s;
|
|
68
|
-
border-radius: 1px 0 0 1px;
|
|
69
|
-
background-color: #1890ff;
|
|
70
|
-
width: 0;
|
|
71
|
-
height: 100%;
|
|
72
|
-
}
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<div class="chart-mini-progress">
|
|
3
|
+
<div class="target" :style="{ left: target + '%'}">
|
|
4
|
+
<span :style="{ backgroundColor: color }" />
|
|
5
|
+
<span :style="{ backgroundColor: color }"/>
|
|
6
|
+
</div>
|
|
7
|
+
<div class="progress-wrapper">
|
|
8
|
+
<div class="progress" :style="{ backgroundColor: color, width: percentage + '%', height: height }"></div>
|
|
9
|
+
</div>
|
|
10
|
+
</div>
|
|
11
|
+
</template>
|
|
12
|
+
|
|
13
|
+
<script>
|
|
14
|
+
export default {
|
|
15
|
+
name: 'MiniProgress',
|
|
16
|
+
props: {
|
|
17
|
+
target: {
|
|
18
|
+
type: Number,
|
|
19
|
+
default: 0
|
|
20
|
+
},
|
|
21
|
+
height: {
|
|
22
|
+
type: String,
|
|
23
|
+
default: '10px'
|
|
24
|
+
},
|
|
25
|
+
color: {
|
|
26
|
+
type: String,
|
|
27
|
+
default: '#13C2C2'
|
|
28
|
+
},
|
|
29
|
+
percentage: {
|
|
30
|
+
type: Number,
|
|
31
|
+
default: 0
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
</script>
|
|
36
|
+
|
|
37
|
+
<style lang="less" scoped>
|
|
38
|
+
.chart-mini-progress {
|
|
39
|
+
padding: 5px 0;
|
|
40
|
+
position: relative;
|
|
41
|
+
width: 100%;
|
|
42
|
+
|
|
43
|
+
.target {
|
|
44
|
+
position: absolute;
|
|
45
|
+
top: 0;
|
|
46
|
+
bottom: 0;
|
|
47
|
+
|
|
48
|
+
span {
|
|
49
|
+
border-radius: 100px;
|
|
50
|
+
position: absolute;
|
|
51
|
+
top: 0;
|
|
52
|
+
left: 0;
|
|
53
|
+
height: 4px;
|
|
54
|
+
width: 2px;
|
|
55
|
+
|
|
56
|
+
&:last-child {
|
|
57
|
+
top: auto;
|
|
58
|
+
bottom: 0;
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
.progress-wrapper {
|
|
63
|
+
background-color: #f5f5f5;
|
|
64
|
+
position: relative;
|
|
65
|
+
|
|
66
|
+
.progress {
|
|
67
|
+
transition: all .4s cubic-bezier(.08,.82,.17,1) 0s;
|
|
68
|
+
border-radius: 1px 0 0 1px;
|
|
69
|
+
background-color: #1890ff;
|
|
70
|
+
width: 0;
|
|
71
|
+
height: 100%;
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
</style>
|
|
@@ -1,40 +1,40 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div :class="prefixCls">
|
|
3
|
-
<div class="chart-wrapper" :style="{ height: 46 }">
|
|
4
|
-
<v-chart :force-fit="true" :height="height" :data="dataSource" :scale="scale" :padding="[36, 0, 18, 0]">
|
|
5
|
-
<v-tooltip />
|
|
6
|
-
<v-smooth-line position="x*y" :size="2" />
|
|
7
|
-
<v-smooth-area position="x*y" />
|
|
8
|
-
</v-chart>
|
|
9
|
-
</div>
|
|
10
|
-
</div>
|
|
11
|
-
</template>
|
|
12
|
-
|
|
13
|
-
<script>
|
|
14
|
-
export default {
|
|
15
|
-
name: 'MiniSmoothArea',
|
|
16
|
-
props: {
|
|
17
|
-
prefixCls: {
|
|
18
|
-
type: String,
|
|
19
|
-
default: 'ant-pro-smooth-area'
|
|
20
|
-
},
|
|
21
|
-
scale: {
|
|
22
|
-
type: [Object, Array],
|
|
23
|
-
required: true
|
|
24
|
-
},
|
|
25
|
-
dataSource: {
|
|
26
|
-
type: Array,
|
|
27
|
-
required: true
|
|
28
|
-
}
|
|
29
|
-
},
|
|
30
|
-
data () {
|
|
31
|
-
return {
|
|
32
|
-
height: 100
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
</script>
|
|
37
|
-
|
|
38
|
-
<style lang="less" scoped>
|
|
39
|
-
@import "smooth.area.less";
|
|
40
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<div :class="prefixCls">
|
|
3
|
+
<div class="chart-wrapper" :style="{ height: 46 }">
|
|
4
|
+
<v-chart :force-fit="true" :height="height" :data="dataSource" :scale="scale" :padding="[36, 0, 18, 0]">
|
|
5
|
+
<v-tooltip />
|
|
6
|
+
<v-smooth-line position="x*y" :size="2" />
|
|
7
|
+
<v-smooth-area position="x*y" />
|
|
8
|
+
</v-chart>
|
|
9
|
+
</div>
|
|
10
|
+
</div>
|
|
11
|
+
</template>
|
|
12
|
+
|
|
13
|
+
<script>
|
|
14
|
+
export default {
|
|
15
|
+
name: 'MiniSmoothArea',
|
|
16
|
+
props: {
|
|
17
|
+
prefixCls: {
|
|
18
|
+
type: String,
|
|
19
|
+
default: 'ant-pro-smooth-area'
|
|
20
|
+
},
|
|
21
|
+
scale: {
|
|
22
|
+
type: [Object, Array],
|
|
23
|
+
required: true
|
|
24
|
+
},
|
|
25
|
+
dataSource: {
|
|
26
|
+
type: Array,
|
|
27
|
+
required: true
|
|
28
|
+
}
|
|
29
|
+
},
|
|
30
|
+
data () {
|
|
31
|
+
return {
|
|
32
|
+
height: 100
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
</script>
|
|
37
|
+
|
|
38
|
+
<style lang="less" scoped>
|
|
39
|
+
@import "smooth.area.less";
|
|
40
|
+
</style>
|
|
@@ -1,68 +1,68 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<v-chart :forceFit="true" height="400" :data="data" :padding="[20, 20, 95, 20]" :scale="scale">
|
|
3
|
-
<v-tooltip></v-tooltip>
|
|
4
|
-
<v-axis :dataKey="axis1Opts.dataKey" :line="axis1Opts.line" :tickLine="axis1Opts.tickLine" :grid="axis1Opts.grid" />
|
|
5
|
-
<v-axis :dataKey="axis2Opts.dataKey" :line="axis2Opts.line" :tickLine="axis2Opts.tickLine" :grid="axis2Opts.grid" />
|
|
6
|
-
<v-legend dataKey="user" marker="circle" :offset="30" />
|
|
7
|
-
<v-coord type="polar" radius="0.8" />
|
|
8
|
-
<v-line position="item*score" color="user" :size="2" />
|
|
9
|
-
<v-point position="item*score" color="user" :size="4" shape="circle" />
|
|
10
|
-
</v-chart>
|
|
11
|
-
</template>
|
|
12
|
-
|
|
13
|
-
<script>
|
|
14
|
-
const axis1Opts = {
|
|
15
|
-
dataKey: 'item',
|
|
16
|
-
line: null,
|
|
17
|
-
tickLine: null,
|
|
18
|
-
grid: {
|
|
19
|
-
lineStyle: {
|
|
20
|
-
lineDash: null
|
|
21
|
-
},
|
|
22
|
-
hideFirstLine: false
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
const axis2Opts = {
|
|
26
|
-
dataKey: 'score',
|
|
27
|
-
line: null,
|
|
28
|
-
tickLine: null,
|
|
29
|
-
grid: {
|
|
30
|
-
type: 'polygon',
|
|
31
|
-
lineStyle: {
|
|
32
|
-
lineDash: null
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
const scale = [
|
|
38
|
-
{
|
|
39
|
-
dataKey: 'score',
|
|
40
|
-
min: 0,
|
|
41
|
-
max: 80
|
|
42
|
-
}, {
|
|
43
|
-
dataKey: 'user',
|
|
44
|
-
alias: '类型'
|
|
45
|
-
}
|
|
46
|
-
]
|
|
47
|
-
|
|
48
|
-
export default {
|
|
49
|
-
name: 'Radar',
|
|
50
|
-
props: {
|
|
51
|
-
data: {
|
|
52
|
-
type: Array,
|
|
53
|
-
default: null
|
|
54
|
-
}
|
|
55
|
-
},
|
|
56
|
-
data () {
|
|
57
|
-
return {
|
|
58
|
-
axis1Opts,
|
|
59
|
-
axis2Opts,
|
|
60
|
-
scale
|
|
61
|
-
}
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
</script>
|
|
65
|
-
|
|
66
|
-
<style scoped>
|
|
67
|
-
|
|
68
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<v-chart :forceFit="true" height="400" :data="data" :padding="[20, 20, 95, 20]" :scale="scale">
|
|
3
|
+
<v-tooltip></v-tooltip>
|
|
4
|
+
<v-axis :dataKey="axis1Opts.dataKey" :line="axis1Opts.line" :tickLine="axis1Opts.tickLine" :grid="axis1Opts.grid" />
|
|
5
|
+
<v-axis :dataKey="axis2Opts.dataKey" :line="axis2Opts.line" :tickLine="axis2Opts.tickLine" :grid="axis2Opts.grid" />
|
|
6
|
+
<v-legend dataKey="user" marker="circle" :offset="30" />
|
|
7
|
+
<v-coord type="polar" radius="0.8" />
|
|
8
|
+
<v-line position="item*score" color="user" :size="2" />
|
|
9
|
+
<v-point position="item*score" color="user" :size="4" shape="circle" />
|
|
10
|
+
</v-chart>
|
|
11
|
+
</template>
|
|
12
|
+
|
|
13
|
+
<script>
|
|
14
|
+
const axis1Opts = {
|
|
15
|
+
dataKey: 'item',
|
|
16
|
+
line: null,
|
|
17
|
+
tickLine: null,
|
|
18
|
+
grid: {
|
|
19
|
+
lineStyle: {
|
|
20
|
+
lineDash: null
|
|
21
|
+
},
|
|
22
|
+
hideFirstLine: false
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
const axis2Opts = {
|
|
26
|
+
dataKey: 'score',
|
|
27
|
+
line: null,
|
|
28
|
+
tickLine: null,
|
|
29
|
+
grid: {
|
|
30
|
+
type: 'polygon',
|
|
31
|
+
lineStyle: {
|
|
32
|
+
lineDash: null
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
const scale = [
|
|
38
|
+
{
|
|
39
|
+
dataKey: 'score',
|
|
40
|
+
min: 0,
|
|
41
|
+
max: 80
|
|
42
|
+
}, {
|
|
43
|
+
dataKey: 'user',
|
|
44
|
+
alias: '类型'
|
|
45
|
+
}
|
|
46
|
+
]
|
|
47
|
+
|
|
48
|
+
export default {
|
|
49
|
+
name: 'Radar',
|
|
50
|
+
props: {
|
|
51
|
+
data: {
|
|
52
|
+
type: Array,
|
|
53
|
+
default: null
|
|
54
|
+
}
|
|
55
|
+
},
|
|
56
|
+
data () {
|
|
57
|
+
return {
|
|
58
|
+
axis1Opts,
|
|
59
|
+
axis2Opts,
|
|
60
|
+
scale
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
</script>
|
|
65
|
+
|
|
66
|
+
<style scoped>
|
|
67
|
+
|
|
68
|
+
</style>
|
|
@@ -1,77 +1,77 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div class="rank">
|
|
3
|
-
<h4 class="title">{{ title }}</h4>
|
|
4
|
-
<ul class="list">
|
|
5
|
-
<li :key="index" v-for="(item, index) in list">
|
|
6
|
-
<span :class="index < 3 ? 'active' : null">{{ index + 1 }}</span>
|
|
7
|
-
<span>{{ item.name }}</span>
|
|
8
|
-
<span>{{ item.total }}</span>
|
|
9
|
-
</li>
|
|
10
|
-
</ul>
|
|
11
|
-
</div>
|
|
12
|
-
</template>
|
|
13
|
-
|
|
14
|
-
<script>
|
|
15
|
-
export default {
|
|
16
|
-
name: 'RankList',
|
|
17
|
-
// ['title', 'list']
|
|
18
|
-
props: {
|
|
19
|
-
title: {
|
|
20
|
-
type: String,
|
|
21
|
-
default: ''
|
|
22
|
-
},
|
|
23
|
-
list: {
|
|
24
|
-
type: Array,
|
|
25
|
-
default: null
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
</script>
|
|
30
|
-
|
|
31
|
-
<style lang="less" scoped>
|
|
32
|
-
|
|
33
|
-
.rank {
|
|
34
|
-
padding: 0 32px 32px 72px;
|
|
35
|
-
|
|
36
|
-
.list {
|
|
37
|
-
margin: 25px 0 0;
|
|
38
|
-
padding: 0;
|
|
39
|
-
list-style: none;
|
|
40
|
-
|
|
41
|
-
li {
|
|
42
|
-
margin-top: 16px;
|
|
43
|
-
|
|
44
|
-
span {
|
|
45
|
-
color: rgba(0, 0, 0, .65);
|
|
46
|
-
font-size: 14px;
|
|
47
|
-
line-height: 22px;
|
|
48
|
-
|
|
49
|
-
&:first-child {
|
|
50
|
-
background-color: #f5f5f5;
|
|
51
|
-
border-radius: 20px;
|
|
52
|
-
display: inline-block;
|
|
53
|
-
font-size: 12px;
|
|
54
|
-
font-weight: 600;
|
|
55
|
-
margin-right: 24px;
|
|
56
|
-
height: 20px;
|
|
57
|
-
line-height: 20px;
|
|
58
|
-
width: 20px;
|
|
59
|
-
text-align: center;
|
|
60
|
-
}
|
|
61
|
-
&.active {
|
|
62
|
-
background-color: #314659;
|
|
63
|
-
color: #fff;
|
|
64
|
-
}
|
|
65
|
-
&:last-child {
|
|
66
|
-
float: right;
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
}
|
|
70
|
-
}
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
.mobile .rank {
|
|
74
|
-
padding: 0 32px 32px 32px;
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<div class="rank">
|
|
3
|
+
<h4 class="title">{{ title }}</h4>
|
|
4
|
+
<ul class="list">
|
|
5
|
+
<li :key="index" v-for="(item, index) in list">
|
|
6
|
+
<span :class="index < 3 ? 'active' : null">{{ index + 1 }}</span>
|
|
7
|
+
<span>{{ item.name }}</span>
|
|
8
|
+
<span>{{ item.total }}</span>
|
|
9
|
+
</li>
|
|
10
|
+
</ul>
|
|
11
|
+
</div>
|
|
12
|
+
</template>
|
|
13
|
+
|
|
14
|
+
<script>
|
|
15
|
+
export default {
|
|
16
|
+
name: 'RankList',
|
|
17
|
+
// ['title', 'list']
|
|
18
|
+
props: {
|
|
19
|
+
title: {
|
|
20
|
+
type: String,
|
|
21
|
+
default: ''
|
|
22
|
+
},
|
|
23
|
+
list: {
|
|
24
|
+
type: Array,
|
|
25
|
+
default: null
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
</script>
|
|
30
|
+
|
|
31
|
+
<style lang="less" scoped>
|
|
32
|
+
|
|
33
|
+
.rank {
|
|
34
|
+
padding: 0 32px 32px 72px;
|
|
35
|
+
|
|
36
|
+
.list {
|
|
37
|
+
margin: 25px 0 0;
|
|
38
|
+
padding: 0;
|
|
39
|
+
list-style: none;
|
|
40
|
+
|
|
41
|
+
li {
|
|
42
|
+
margin-top: 16px;
|
|
43
|
+
|
|
44
|
+
span {
|
|
45
|
+
color: rgba(0, 0, 0, .65);
|
|
46
|
+
font-size: 14px;
|
|
47
|
+
line-height: 22px;
|
|
48
|
+
|
|
49
|
+
&:first-child {
|
|
50
|
+
background-color: #f5f5f5;
|
|
51
|
+
border-radius: 20px;
|
|
52
|
+
display: inline-block;
|
|
53
|
+
font-size: 12px;
|
|
54
|
+
font-weight: 600;
|
|
55
|
+
margin-right: 24px;
|
|
56
|
+
height: 20px;
|
|
57
|
+
line-height: 20px;
|
|
58
|
+
width: 20px;
|
|
59
|
+
text-align: center;
|
|
60
|
+
}
|
|
61
|
+
&.active {
|
|
62
|
+
background-color: #314659;
|
|
63
|
+
color: #fff;
|
|
64
|
+
}
|
|
65
|
+
&:last-child {
|
|
66
|
+
float: right;
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
.mobile .rank {
|
|
74
|
+
padding: 0 32px 32px 32px;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
</style>
|