mali-applet-ui 0.1.39 → 0.1.41
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.
|
@@ -16,13 +16,13 @@
|
|
|
16
16
|
</view>
|
|
17
17
|
</view>
|
|
18
18
|
|
|
19
|
-
<ml-
|
|
19
|
+
<ml-drawer v-model="showPopup" title="请选择" height="500rpx" showConfirmButton showCancelButton @confirm="confirmEvent">
|
|
20
20
|
<picker-view v-if="showPicker" :value="selectIndexs" @change="changeEvent" style="height: 400rpx;text-align: center;">
|
|
21
21
|
<picker-view-column v-for="(num, index) in countLevel" :key="index">
|
|
22
22
|
<view class="ml-cascader-picker-picker-item" v-for="(item, cIndex) in pickerDataMaps[index]" :key="cIndex">{{ item[optLabelField] }}</view>
|
|
23
23
|
</picker-view-column>
|
|
24
24
|
</picker-view>
|
|
25
|
-
</ml-
|
|
25
|
+
</ml-drawer>
|
|
26
26
|
</view>
|
|
27
27
|
</template>
|
|
28
28
|
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<view class="ml-
|
|
3
|
-
<view v-if="visible" class="ml-
|
|
4
|
-
<view v-if="showHeader" class="ml-
|
|
2
|
+
<view class="ml-drawer" :class="[className || '', `placement-${placement || 'bottom'}`, {'is-visible': visible, 'is-animate': isAnimate}]" @tap="tapMaskEvent">
|
|
3
|
+
<view v-if="visible" class="ml-drawer-warpper" @tap.stop>
|
|
4
|
+
<view v-if="showHeader" class="ml-drawer-header">
|
|
5
5
|
<slot name="header">
|
|
6
|
-
<view v-if="title" class="ml-
|
|
6
|
+
<view v-if="title" class="ml-drawer-header-title">{{ title }}</view>
|
|
7
7
|
</slot>
|
|
8
8
|
</view>
|
|
9
|
-
<view class="ml-
|
|
9
|
+
<view class="ml-drawer-body" :style="bodyStyles">
|
|
10
10
|
<scroll-view scroll-y>
|
|
11
11
|
<slot></slot>
|
|
12
12
|
</scroll-view>
|
|
13
13
|
</view>
|
|
14
|
-
<view v-if="showConfirmButton || showCancelButton || showFooter" class="ml-
|
|
14
|
+
<view v-if="showConfirmButton || showCancelButton || showFooter" class="ml-drawer-footer">
|
|
15
15
|
<slot name="footer">
|
|
16
|
-
<ml-button v-if="showCancelButton" width="40%"
|
|
17
|
-
<ml-button v-if="showConfirmButton" status="primary" width="40%"
|
|
16
|
+
<ml-button v-if="showCancelButton" width="40%" @click="cancelEvent">{{ cancelButtonText }}</ml-button>
|
|
17
|
+
<ml-button v-if="showConfirmButton" status="primary" width="40%" @click="confirmEvent">{{ confirmButtonText }}</ml-button>
|
|
18
18
|
</slot>
|
|
19
19
|
</view>
|
|
20
20
|
</view>
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
|
|
24
24
|
<script>
|
|
25
25
|
export default {
|
|
26
|
-
name: '
|
|
26
|
+
name: 'MlDrawer',
|
|
27
27
|
props: {
|
|
28
28
|
value: Boolean,
|
|
29
29
|
title: String,
|
|
@@ -128,7 +128,7 @@ export default {
|
|
|
128
128
|
</script>
|
|
129
129
|
|
|
130
130
|
<style lang="scss">
|
|
131
|
-
.ml-
|
|
131
|
+
.ml-drawer {
|
|
132
132
|
display: none;
|
|
133
133
|
position: fixed;
|
|
134
134
|
top: 0;
|
|
@@ -146,55 +146,55 @@ export default {
|
|
|
146
146
|
}
|
|
147
147
|
&.placement-left {
|
|
148
148
|
&.is-animate {
|
|
149
|
-
.ml-
|
|
149
|
+
.ml-drawer-warpper {
|
|
150
150
|
transform: translateX(0);
|
|
151
151
|
}
|
|
152
152
|
}
|
|
153
|
-
.ml-
|
|
153
|
+
.ml-drawer-warpper {
|
|
154
154
|
height: 100%;
|
|
155
155
|
transform: translateX(-100%);
|
|
156
156
|
}
|
|
157
157
|
}
|
|
158
158
|
&.placement-bottom {
|
|
159
159
|
&.is-animate {
|
|
160
|
-
.ml-
|
|
160
|
+
.ml-drawer-warpper {
|
|
161
161
|
transform: translateY(0);
|
|
162
162
|
}
|
|
163
163
|
}
|
|
164
|
-
.ml-
|
|
164
|
+
.ml-drawer-warpper {
|
|
165
165
|
width: 100%;
|
|
166
166
|
transform: translateY(100%);
|
|
167
167
|
}
|
|
168
168
|
}
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
169
|
+
.ml-drawer-warpper {
|
|
170
|
+
position: absolute;
|
|
171
|
+
bottom: 0;
|
|
172
|
+
left: 0;
|
|
173
|
+
padding-bottom: 20rpx;
|
|
174
|
+
background: #fff;
|
|
175
|
+
transition: transform 0.25s ease, transform 0.3s ease;
|
|
176
|
+
}
|
|
177
|
+
.ml-drawer-header {
|
|
178
|
+
padding: 10rpx 20rpx;
|
|
179
|
+
}
|
|
180
|
+
.ml-drawer-header-title {
|
|
181
|
+
text-align: center;
|
|
182
|
+
height: 70rpx;
|
|
183
|
+
line-height: 70rpx;
|
|
184
|
+
font-size: $uni-font-size-base;
|
|
185
|
+
overflow: hidden;
|
|
186
|
+
text-overflow: ellipsis;
|
|
187
|
+
white-space: nowrap;
|
|
188
|
+
}
|
|
189
|
+
.ml-drawer-body {
|
|
190
|
+
padding: 20rpx;
|
|
191
|
+
overflow: auto;
|
|
192
|
+
height: 500rpx;
|
|
193
|
+
}
|
|
194
|
+
.ml-drawer-footer {
|
|
195
|
+
display: flex;
|
|
196
|
+
flex-direction: row;
|
|
197
|
+
padding: 20rpx;
|
|
198
|
+
}
|
|
199
199
|
}
|
|
200
200
|
</style>
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
</view>
|
|
17
17
|
</view>
|
|
18
18
|
|
|
19
|
-
<ml-
|
|
19
|
+
<ml-drawer v-model="showPopup" title="请选择省/市" height="500rpx" showConfirmButton showCancelButton @confirm="confirmEvent">
|
|
20
20
|
<picker-view v-if="showPicker" :value="selectVals" @change="changeEvent" style="height: 400rpx;text-align: center;">
|
|
21
21
|
<picker-view-column>
|
|
22
22
|
<view class="ml-province-city-picker-picker-item" v-for="(item, index) in provinceList" :key="index">{{ item[optLabelField] }}</view>
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
<view class="ml-province-city-picker-picker-item" v-for="(item, index) in cityList" :key="index">{{ item[optLabelField] }}</view>
|
|
26
26
|
</picker-view-column>
|
|
27
27
|
</picker-view>
|
|
28
|
-
</ml-
|
|
28
|
+
</ml-drawer>
|
|
29
29
|
</view>
|
|
30
30
|
</template>
|
|
31
31
|
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<view class="ml-tooltip">
|
|
3
|
+
<slot></slot>
|
|
4
|
+
<view class="ml-tooltip-title">
|
|
5
|
+
<view>{{ title }}</view>
|
|
6
|
+
</view>
|
|
7
|
+
</view>
|
|
8
|
+
</template>
|
|
9
|
+
|
|
10
|
+
<script>
|
|
11
|
+
export default {
|
|
12
|
+
name: 'MlTooltip',
|
|
13
|
+
props: {
|
|
14
|
+
value: Boolean,
|
|
15
|
+
title: String,
|
|
16
|
+
placement: String
|
|
17
|
+
},
|
|
18
|
+
data () {
|
|
19
|
+
return {
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
</script>
|
|
24
|
+
|
|
25
|
+
<style lang="scss">
|
|
26
|
+
|
|
27
|
+
</style>
|