mali-applet-ui 1.0.104 → 1.0.106
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.
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
</view>
|
|
25
25
|
</view>
|
|
26
26
|
<template v-if="showTree && showTree.length">
|
|
27
|
-
<view class="ml-tree-node" v-for="(item, index) in showTree" :key="index"
|
|
27
|
+
<view class="ml-tree-node" v-for="(item, index) in showTree" :key="index">
|
|
28
28
|
<view class="ml-tree-node__action" v-if="check">
|
|
29
29
|
<ml-checkbox
|
|
30
30
|
:value="checkKey.indexOf(item[useProps.key]) > -1"
|
|
@@ -44,21 +44,21 @@
|
|
|
44
44
|
@tap-icon.stop="handleClickIcon($event, item)"
|
|
45
45
|
:info="getPrefixIcon(item)"
|
|
46
46
|
/>
|
|
47
|
-
<view class="ml-tree-node__title">
|
|
47
|
+
<view class="ml-tree-node__title" :class="{ 'hasExplain': item[useProps.explain] }" @tap.stop="handleIntoChildren(item)">
|
|
48
48
|
<view class="nowrap">{{ item[useProps.label] || '' }}</view>
|
|
49
49
|
<view class="ml-tree-node__explain" v-if="item[useProps.explain]">{{ item[useProps.explain] }}</view>
|
|
50
50
|
</view>
|
|
51
51
|
<view class="ml-tree-node__extra">
|
|
52
52
|
<MlTreeIcon
|
|
53
53
|
:margin-right="15"
|
|
54
|
-
@tap-icon.stop="handleClickIcon($event, item)"
|
|
55
54
|
:info="getSuffixIcon(item)"
|
|
55
|
+
@tap-icon.stop="handleClickIcon($event, item)"
|
|
56
56
|
/>
|
|
57
57
|
<MlTreeIcon
|
|
58
|
-
:margin-right="15"
|
|
59
|
-
@tap-icon.stop="handleIntoChildren(item)"
|
|
60
58
|
v-if="(item.children && item.children.length) || (lazy && !item.isLeaf)"
|
|
59
|
+
:margin-right="15"
|
|
61
60
|
:info="{ icon: 'arrow-right' }"
|
|
61
|
+
@tap-icon.stop="handleIntoChildren(item)"
|
|
62
62
|
/>
|
|
63
63
|
</view>
|
|
64
64
|
</view>
|
|
@@ -160,7 +160,6 @@ export default {
|
|
|
160
160
|
computed: {
|
|
161
161
|
showTree () {
|
|
162
162
|
const { current, tree } = this
|
|
163
|
-
console.log(current)
|
|
164
163
|
if (current) {
|
|
165
164
|
return current.children
|
|
166
165
|
}
|
|
@@ -442,12 +441,19 @@ export default {
|
|
|
442
441
|
font-size: 34rpx;
|
|
443
442
|
display: flex;
|
|
444
443
|
align-items: center;
|
|
445
|
-
height: 116rpx;
|
|
446
444
|
border-bottom: 1rpx solid #efefef;
|
|
447
445
|
|
|
448
446
|
.ml-tree-node__title {
|
|
447
|
+
height: 116rpx;
|
|
449
448
|
flex: 1;
|
|
450
449
|
width: 0;
|
|
450
|
+
display: flex;
|
|
451
|
+
align-items: center;
|
|
452
|
+
&.hasExplain {
|
|
453
|
+
align-items: normal;
|
|
454
|
+
justify-content: center;
|
|
455
|
+
flex-direction: column;
|
|
456
|
+
}
|
|
451
457
|
.nowrap {
|
|
452
458
|
white-space: nowrap;
|
|
453
459
|
overflow: hidden;
|
|
@@ -469,9 +475,15 @@ export default {
|
|
|
469
475
|
}
|
|
470
476
|
|
|
471
477
|
.ml-tree-node__extra {
|
|
478
|
+
height: 116rpx;
|
|
472
479
|
display: flex;
|
|
473
480
|
align-items: center;
|
|
474
481
|
padding: 0 0 0 20rpx;
|
|
482
|
+
.ml-tree-node__extra-item {
|
|
483
|
+
display: flex;
|
|
484
|
+
align-items: center;
|
|
485
|
+
height: 100%;
|
|
486
|
+
}
|
|
475
487
|
}
|
|
476
488
|
|
|
477
489
|
&:last-child {
|
|
@@ -480,6 +492,7 @@ export default {
|
|
|
480
492
|
|
|
481
493
|
.ml-tree-loading-tip {
|
|
482
494
|
flex: 1;
|
|
495
|
+
height: 116rpx;
|
|
483
496
|
text-align: center;
|
|
484
497
|
vertical-align: middle;
|
|
485
498
|
display: flex;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<view class="ml-tree-node__icon" :style="useStyle" v-if="info && info.icon" @tap
|
|
2
|
+
<view class="ml-tree-node__icon" :style="useStyle" v-if="info && info.icon" @tap="handleEvent">
|
|
3
3
|
<ml-icon :name="info.icon"></ml-icon>
|
|
4
4
|
</view>
|
|
5
5
|
</template>
|
|
@@ -30,6 +30,10 @@ export default {
|
|
|
30
30
|
|
|
31
31
|
<style lang="scss" scoped>
|
|
32
32
|
.ml-tree-node__icon {
|
|
33
|
-
|
|
33
|
+
height: 100%;
|
|
34
|
+
display: flex;
|
|
35
|
+
padding: 0 10rpx;
|
|
36
|
+
align-items: center;
|
|
37
|
+
justify-content: center;
|
|
34
38
|
}
|
|
35
39
|
</style>
|