mali-applet-ui 0.0.49 → 0.0.52

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.
@@ -4,7 +4,7 @@
4
4
  <view class="ml-approval-record-header-title">审批记录</view>
5
5
  </view>
6
6
  <view class="ml-approval-record-body">
7
- <view class="ml-approval-record-list" v-for="(group, gIndex) in options" :key="gIndex">
7
+ <view class="ml-approval-record-list" v-for="(group, gIndex) in flowOptions" :key="gIndex">
8
8
  <view class="ml-approval-record-flow-line"></view>
9
9
  <view class="ml-approval-record-item">
10
10
  <view class="ml-approval-record-item-title">{{ group.name }}</view>
@@ -37,11 +37,46 @@
37
37
  </template>
38
38
 
39
39
  <script>
40
+ import globalStore from '../../config/store'
41
+
40
42
  export default {
41
43
  name: 'MlApprovalRecord',
42
44
  props: {
43
45
  value: Array,
46
+ code: String,
44
47
  options: Array
48
+ },
49
+ data () {
50
+ return {
51
+ flowOptions: []
52
+ }
53
+ },
54
+ watch: {
55
+ code () {
56
+ this.load()
57
+ }
58
+ },
59
+ created () {
60
+ this.flowOptions = this.options || []
61
+ this.load()
62
+ },
63
+ methods: {
64
+ load () {
65
+ if (!this.code) {
66
+ return
67
+ }
68
+ if (globalStore.approval && globalStore.approval.record) {
69
+ const optionMethod = globalStore.approval.record.optionMethod
70
+ if (optionMethod) {
71
+ Promise.resolve(optionMethod({
72
+ value: this.value,
73
+ code: this.code
74
+ })).then(options => {
75
+ this.flowOptions = options
76
+ })
77
+ }
78
+ }
79
+ }
45
80
  }
46
81
  }
47
82
  </script>
@@ -4,7 +4,8 @@
4
4
  <view class="ml-approval-select-header-title">审批流程</view>
5
5
  </view>
6
6
  <view class="ml-approval-select-body">
7
- <view class="ml-approval-select-list" v-for="(group, gIndex) in options" :key="gIndex">
7
+ <view class="ml-approval-select-list" v-for="(group, gIndex) in flowOptions" :key="gIndex">
8
+ <view class="ml-approval-select-flow-line"></view>
8
9
  <view class="ml-approval-select-item">
9
10
  <view class="ml-approval-select-item-title">{{ group.name }}</view>
10
11
  </view>
@@ -12,9 +13,6 @@
12
13
  <view class="ml-approval-select-user-item" v-for="(item, uIndex) in group.users" :key="uIndex">
13
14
  <image class="ml-approval-select-user-picture" :src="item.picture" mode="scaleToFill"></image>
14
15
  <view class="ml-approval-select-user-name">{{ item.name }}</view>
15
- <view class="ml-approval-select-user-remove">
16
- <ml-icon name="close"></ml-icon>
17
- </view>
18
16
  </view>
19
17
  <view class="ml-approval-select-user-add" @click="openAddUser">
20
18
  <view class="ml-approval-select-user-add-icon">
@@ -24,24 +22,49 @@
24
22
  </view>
25
23
  </view>
26
24
  </view>
27
-
28
- <uni-popup ref="popup" type="bottom">
29
- <text>Popup</text>
30
- <button @click="close">关闭</button>
31
- </uni-popup>
32
25
  </view>
33
26
  </template>
34
27
 
35
28
  <script>
29
+ import globalStore from '../../config/store'
30
+
36
31
  export default {
37
32
  name: 'MlApprovalSelect',
38
33
  props: {
39
34
  value: Array,
35
+ code: String,
40
36
  options: Array
41
37
  },
38
+ data () {
39
+ return {
40
+ flowOptions: []
41
+ }
42
+ },
43
+ watch: {
44
+ code () {
45
+ this.load()
46
+ }
47
+ },
48
+ created () {
49
+ this.flowOptions = this.options || []
50
+ this.load()
51
+ },
42
52
  methods: {
43
- openAddUser () {
44
- this.$refs.popup.open()
53
+ load () {
54
+ if (!this.code) {
55
+ return
56
+ }
57
+ if (globalStore.approval && globalStore.approval.select) {
58
+ const optionMethod = globalStore.approval.select.optionMethod
59
+ if (optionMethod) {
60
+ Promise.resolve(optionMethod({
61
+ value: this.value,
62
+ code: this.code
63
+ })).then(options => {
64
+ this.flowOptions = options
65
+ })
66
+ }
67
+ }
45
68
  }
46
69
  }
47
70
  }
@@ -59,49 +82,77 @@ export default {
59
82
  line-height: 60rpx;
60
83
  }
61
84
  .ml-approval-select-list {
85
+ position: relative;
62
86
  padding-bottom: 10rpx;
87
+ .ml-approval-select-flow-line {
88
+ position: absolute;
89
+ top: 0;
90
+ left: 0;
91
+ height: 100%;
92
+ width: 4rpx;
93
+ background: #D9D9D9;
94
+ &::before {
95
+ content: "";
96
+ position: absolute;
97
+ top: 12rpx;
98
+ left: -10rpx;
99
+ width: 24rpx;
100
+ height: 24rpx;
101
+ border-radius: 50%;
102
+ background: #D9D9D9;
103
+ }
104
+ }
105
+ &:first-child {
106
+ .ml-approval-select-flow-line {
107
+ top: 12rpx;
108
+ &::before {
109
+ top: 0;
110
+ }
111
+ }
112
+ }
113
+ &:last-child {
114
+ .ml-approval-select-flow-line {
115
+ height: 30rpx;
116
+ }
117
+ }
63
118
  }
64
119
  .ml-approval-select-item-title {
65
- padding-left: 20rpx;
120
+ padding-left: 40rpx;
66
121
  line-height: 50rpx;
67
122
  }
68
123
  .ml-approval-select-users {
69
124
  display: flex;
70
125
  flex-direction: row;
71
- flex-wrap: wrap;
126
+ padding-left: 40rpx;
72
127
  }
73
128
  .ml-approval-select-user-item {
74
- position: relative;
129
+ display: flex;
130
+ flex-direction: column;
75
131
  padding: 10rpx;
76
- width: 150rpx;
77
132
  text-align: center;
133
+ width: 140rpx;
78
134
  .ml-approval-select-user-picture {
79
135
  width: 100rpx;
80
136
  height: 100rpx;
81
137
  border-radius: 50%;
138
+ margin: 0 auto;
82
139
  }
83
140
  .ml-approval-select-user-name {
141
+ display: inline-block;
142
+ vertical-align: middle;
143
+ max-width: 150rpx;
84
144
  overflow: hidden;
85
145
  text-overflow: ellipsis;
86
146
  white-space: nowrap;
147
+ margin-right: 10rpx;
87
148
  font-size: 24rpx;
88
- }
89
- .ml-approval-select-user-remove {
90
- position: absolute;
91
- top: 0;
92
- right: 10rpx;
93
- width: 40rpx;
94
- height: 40rpx;
95
- line-height: 40rpx;
96
- border-radius: 50%;
97
- text-align: center;
98
- color: #ffffff;
99
- background: rgba(0, 0, 0, 0.45);
149
+ color: rgba(0, 0, 0, 0.85);
100
150
  }
101
151
  }
102
152
  .ml-approval-select-user-add {
153
+ display: flex;
154
+ flex-direction: column;
103
155
  padding: 10rpx;
104
- width: 160rpx;
105
156
  text-align: center;
106
157
  .ml-approval-select-user-add-icon {
107
158
  width: 100rpx;
@@ -114,4 +165,4 @@ export default {
114
165
  overflow: hidden;
115
166
  }
116
167
  }
117
- </style>
168
+ </style>
@@ -45,8 +45,9 @@ export default {
45
45
  .ml-chunk-item {
46
46
  display: flex;
47
47
  flex-direction: column;
48
- padding: 20rpx 10rpx;
48
+ padding: 20rpx;
49
49
  line-height: 50rpx;
50
+ font-size: $uni-font-size-base;
50
51
  $spans: 4.16667%, 8.33333%, 12.5%, 16.66667%, 20.83333%, 25%, 29.16667%, 33.33333%,
51
52
  37.5%, 41.66667%, 45.83333%, 50%, 54.16667%, 58.33333%, 62.5%, 66.66667%,
52
53
  70.83333%, 75%, 79.16667%, 83.33333%, 87.5%, 91.66667%, 95.83333%, 100%;
@@ -3,7 +3,17 @@
3
3
  <slot>
4
4
  <view v-for="(item, index) in items" :key="index">
5
5
  <ml-form-group v-if="item.children && item.children.length" :title="item.title">
6
- <ml-form-item v-for="(cItem, cIndex) in item.children" :key="cIndex" :title="cItem.title" :field="cItem.field" :itemRender="cItem.itemRender" @modelvalue="updateModel"></ml-form-item>
6
+ <ml-form-item
7
+ v-for="(cItem, cIndex) in item.children"
8
+ :key="cIndex"
9
+ :title="cItem.title"
10
+ :field="cItem.field"
11
+ :vertical="cItem.vertical"
12
+ :align="cItem.align"
13
+ :titleAlign="cItem.titleAlign"
14
+ :itemRender="cItem.itemRender"
15
+ @modelvalue="updateModel">
16
+ </ml-form-item>
7
17
  </ml-form-group>
8
18
  <ml-form-item v-else :title="item.title" :field="item.field" :itemRender="item.itemRender" @modelvalue="updateModel"></ml-form-item>
9
19
  </view>
@@ -183,5 +183,6 @@ export default {
183
183
  .ml-form-item-content-warpper {
184
184
  flex-grow: 1;
185
185
  width: 100%;
186
+ padding: 10rpx 0;
186
187
  }
187
188
  </style>
@@ -4,6 +4,7 @@
4
4
  <scroll-view scroll-y>
5
5
  <slot></slot>
6
6
  </scroll-view>
7
+ <uni-load-more v-if="loadMore" v-show="!loading" :status="loadStatus"></uni-load-more>
7
8
  </view>
8
9
  </view>
9
10
  </template>
@@ -16,6 +17,7 @@ export default {
16
17
  },
17
18
  props: {
18
19
  title: String,
20
+ loadMore: Boolean,
19
21
  className: String
20
22
  }
21
23
  }
@@ -59,7 +59,7 @@ export default {
59
59
  display: flex;
60
60
  flex-direction: row;
61
61
  padding: 20rpx;
62
- margin: 10rpx 0;
62
+ margin: 20rpx 0;
63
63
  border-radius: 10rpx;
64
64
  background: #ffffff;
65
65
  .ml-list-item-content {
@@ -55,6 +55,10 @@ export default {
55
55
  }
56
56
  .ml-month-picker-text {
57
57
  flex-grow: 1;
58
+ padding-right: 10rpx;
59
+ overflow: hidden;
60
+ text-overflow: ellipsis;
61
+ white-space: nowrap;
58
62
  }
59
63
  .ml-month-picker-icon {
60
64
  color: #6a6a6a;
@@ -0,0 +1,352 @@
1
+ /*
2
+ * HTML5 Parser By Sam Blowes
3
+ *
4
+ * Designed for HTML5 documents
5
+ *
6
+ * Original code by John Resig (ejohn.org)
7
+ * http://ejohn.org/blog/pure-javascript-html-parser/
8
+ * Original code by Erik Arvidsson, Mozilla Public License
9
+ * http://erik.eae.net/simplehtmlparser/simplehtmlparser.js
10
+ *
11
+ * ----------------------------------------------------------------------------
12
+ * License
13
+ * ----------------------------------------------------------------------------
14
+ *
15
+ * This code is triple licensed using Apache Software License 2.0,
16
+ * Mozilla Public License or GNU Public License
17
+ *
18
+ * ////////////////////////////////////////////////////////////////////////////
19
+ *
20
+ * Licensed under the Apache License, Version 2.0 (the "License"); you may not
21
+ * use this file except in compliance with the License. You may obtain a copy
22
+ * of the License at http://www.apache.org/licenses/LICENSE-2.0
23
+ *
24
+ * ////////////////////////////////////////////////////////////////////////////
25
+ *
26
+ * The contents of this file are subject to the Mozilla Public License
27
+ * Version 1.1 (the "License"); you may not use this file except in
28
+ * compliance with the License. You may obtain a copy of the License at
29
+ * http://www.mozilla.org/MPL/
30
+ *
31
+ * Software distributed under the License is distributed on an "AS IS"
32
+ * basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
33
+ * License for the specific language governing rights and limitations
34
+ * under the License.
35
+ *
36
+ * The Original Code is Simple HTML Parser.
37
+ *
38
+ * The Initial Developer of the Original Code is Erik Arvidsson.
39
+ * Portions created by Erik Arvidssson are Copyright (C) 2004. All Rights
40
+ * Reserved.
41
+ *
42
+ * ////////////////////////////////////////////////////////////////////////////
43
+ *
44
+ * This program is free software; you can redistribute it and/or
45
+ * modify it under the terms of the GNU General Public License
46
+ * as published by the Free Software Foundation; either version 2
47
+ * of the License, or (at your option) any later version.
48
+ *
49
+ * This program is distributed in the hope that it will be useful,
50
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
51
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
52
+ * GNU General Public License for more details.
53
+ *
54
+ * You should have received a copy of the GNU General Public License
55
+ * along with this program; if not, write to the Free Software
56
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
57
+ *
58
+ * ----------------------------------------------------------------------------
59
+ * Usage
60
+ * ----------------------------------------------------------------------------
61
+ *
62
+ * // Use like so:
63
+ * HTMLParser(htmlString, {
64
+ * start: function(tag, attrs, unary) {},
65
+ * end: function(tag) {},
66
+ * chars: function(text) {},
67
+ * comment: function(text) {}
68
+ * });
69
+ *
70
+ * // or to get an XML string:
71
+ * HTMLtoXML(htmlString);
72
+ *
73
+ * // or to get an XML DOM Document
74
+ * HTMLtoDOM(htmlString);
75
+ *
76
+ * // or to inject into an existing document/DOM node
77
+ * HTMLtoDOM(htmlString, document);
78
+ * HTMLtoDOM(htmlString, document.body);
79
+ *
80
+ */
81
+ // Regular Expressions for parsing tags and attributes
82
+ var startTag = /^<([-A-Za-z0-9_]+)((?:\s+[a-zA-Z_:][-a-zA-Z0-9_:.]*(?:\s*=\s*(?:(?:"[^"]*")|(?:'[^']*')|[^>\s]+))?)*)\s*(\/?)>/;
83
+ var endTag = /^<\/([-A-Za-z0-9_]+)[^>]*>/;
84
+ var attr = /([a-zA-Z_:][-a-zA-Z0-9_:.]*)(?:\s*=\s*(?:(?:"((?:\\.|[^"])*)")|(?:'((?:\\.|[^'])*)')|([^>\s]+)))?/g; // Empty Elements - HTML 5
85
+
86
+ var empty = makeMap('area,base,basefont,br,col,frame,hr,img,input,link,meta,param,embed,command,keygen,source,track,wbr'); // Block Elements - HTML 5
87
+ // fixed by xxx 将 ins 标签从块级名单中移除
88
+
89
+ var block = makeMap('a,address,article,applet,aside,audio,blockquote,button,canvas,center,dd,del,dir,div,dl,dt,fieldset,figcaption,figure,footer,form,frameset,h1,h2,h3,h4,h5,h6,header,hgroup,hr,iframe,isindex,li,map,menu,noframes,noscript,object,ol,output,p,pre,section,script,table,tbody,td,tfoot,th,thead,tr,ul,video'); // Inline Elements - HTML 5
90
+
91
+ var inline = makeMap('abbr,acronym,applet,b,basefont,bdo,big,br,button,cite,code,del,dfn,em,font,i,iframe,img,input,ins,kbd,label,map,object,q,s,samp,script,select,small,span,strike,strong,sub,sup,textarea,tt,u,var'); // Elements that you can, intentionally, leave open
92
+ // (and which close themselves)
93
+
94
+ var closeSelf = makeMap('colgroup,dd,dt,li,options,p,td,tfoot,th,thead,tr'); // Attributes that have their values filled in disabled="disabled"
95
+
96
+ var fillAttrs = makeMap('checked,compact,declare,defer,disabled,ismap,multiple,nohref,noresize,noshade,nowrap,readonly,selected'); // Special Elements (can contain anything)
97
+
98
+ var special = makeMap('script,style');
99
+ function HTMLParser(html, handler) {
100
+ var index;
101
+ var chars;
102
+ var match;
103
+ var stack = [];
104
+ var last = html;
105
+
106
+ stack.last = function () {
107
+ return this[this.length - 1];
108
+ };
109
+
110
+ while (html) {
111
+ chars = true; // Make sure we're not in a script or style element
112
+
113
+ if (!stack.last() || !special[stack.last()]) {
114
+ // Comment
115
+ if (html.indexOf('<!--') == 0) {
116
+ index = html.indexOf('-->');
117
+
118
+ if (index >= 0) {
119
+ if (handler.comment) {
120
+ handler.comment(html.substring(4, index));
121
+ }
122
+
123
+ html = html.substring(index + 3);
124
+ chars = false;
125
+ } // end tag
126
+
127
+ } else if (html.indexOf('</') == 0) {
128
+ match = html.match(endTag);
129
+
130
+ if (match) {
131
+ html = html.substring(match[0].length);
132
+ match[0].replace(endTag, parseEndTag);
133
+ chars = false;
134
+ } // start tag
135
+
136
+ } else if (html.indexOf('<') == 0) {
137
+ match = html.match(startTag);
138
+
139
+ if (match) {
140
+ html = html.substring(match[0].length);
141
+ match[0].replace(startTag, parseStartTag);
142
+ chars = false;
143
+ }
144
+ }
145
+
146
+ if (chars) {
147
+ index = html.indexOf('<');
148
+ var text = index < 0 ? html : html.substring(0, index);
149
+ html = index < 0 ? '' : html.substring(index);
150
+
151
+ if (handler.chars) {
152
+ handler.chars(text);
153
+ }
154
+ }
155
+ } else {
156
+ html = html.replace(new RegExp('([\\s\\S]*?)<\/' + stack.last() + '[^>]*>'), function (all, text) {
157
+ text = text.replace(/<!--([\s\S]*?)-->|<!\[CDATA\[([\s\S]*?)]]>/g, '$1$2');
158
+
159
+ if (handler.chars) {
160
+ handler.chars(text);
161
+ }
162
+
163
+ return '';
164
+ });
165
+ parseEndTag('', stack.last());
166
+ }
167
+
168
+ if (html == last) {
169
+ throw 'Parse Error: ' + html;
170
+ }
171
+
172
+ last = html;
173
+ } // Clean up any remaining tags
174
+
175
+
176
+ parseEndTag();
177
+
178
+ function parseStartTag(tag, tagName, rest, unary) {
179
+ tagName = tagName.toLowerCase();
180
+
181
+ if (block[tagName]) {
182
+ while (stack.last() && inline[stack.last()]) {
183
+ parseEndTag('', stack.last());
184
+ }
185
+ }
186
+
187
+ if (closeSelf[tagName] && stack.last() == tagName) {
188
+ parseEndTag('', tagName);
189
+ }
190
+
191
+ unary = empty[tagName] || !!unary;
192
+
193
+ if (!unary) {
194
+ stack.push(tagName);
195
+ }
196
+
197
+ if (handler.start) {
198
+ var attrs = [];
199
+ rest.replace(attr, function (match, name) {
200
+ var value = arguments[2] ? arguments[2] : arguments[3] ? arguments[3] : arguments[4] ? arguments[4] : fillAttrs[name] ? name : '';
201
+ attrs.push({
202
+ name: name,
203
+ value: value,
204
+ escaped: value.replace(/(^|[^\\])"/g, '$1\\\"') // "
205
+
206
+ });
207
+ });
208
+
209
+ if (handler.start) {
210
+ handler.start(tagName, attrs, unary);
211
+ }
212
+ }
213
+ }
214
+
215
+ function parseEndTag(tag, tagName) {
216
+ // If no tag name is provided, clean shop
217
+ if (!tagName) {
218
+ var pos = 0;
219
+ } // Find the closest opened tag of the same type
220
+ else {
221
+ for (var pos = stack.length - 1; pos >= 0; pos--) {
222
+ if (stack[pos] == tagName) {
223
+ break;
224
+ }
225
+ }
226
+ }
227
+
228
+ if (pos >= 0) {
229
+ // Close all the open elements, up the stack
230
+ for (var i = stack.length - 1; i >= pos; i--) {
231
+ if (handler.end) {
232
+ handler.end(stack[i]);
233
+ }
234
+ } // Remove the open elements from the stack
235
+
236
+
237
+ stack.length = pos;
238
+ }
239
+ }
240
+ }
241
+
242
+ function makeMap(str) {
243
+ var obj = {};
244
+ var items = str.split(',');
245
+
246
+ for (var i = 0; i < items.length; i++) {
247
+ obj[items[i]] = true;
248
+ }
249
+
250
+ return obj;
251
+ }
252
+
253
+ function removeDOCTYPE(html) {
254
+ return html.replace(/<\?xml.*\?>\n/, '').replace(/<!doctype.*>\n/, '').replace(/<!DOCTYPE.*>\n/, '');
255
+ }
256
+
257
+ function parseAttrs(attrs) {
258
+ return attrs.reduce(function (pre, attr) {
259
+ var value = attr.value;
260
+ var name = attr.name;
261
+
262
+ if (pre[name]) {
263
+ pre[name] = pre[name] + " " + value;
264
+ } else {
265
+ pre[name] = value;
266
+ }
267
+
268
+ return pre;
269
+ }, {});
270
+ }
271
+
272
+ function parseHtml(html) {
273
+ html = removeDOCTYPE(html);
274
+ var stacks = [];
275
+ var results = {
276
+ node: 'root',
277
+ children: []
278
+ };
279
+ HTMLParser(html, {
280
+ start: function start(tag, attrs, unary) {
281
+ var node = {
282
+ name: tag
283
+ };
284
+
285
+ if (attrs.length !== 0) {
286
+ node.attrs = parseAttrs(attrs);
287
+ }
288
+
289
+ if (unary) {
290
+ var parent = stacks[0] || results;
291
+
292
+ if (!parent.children) {
293
+ parent.children = [];
294
+ }
295
+
296
+ parent.children.push(node);
297
+ } else {
298
+ stacks.unshift(node);
299
+ }
300
+ },
301
+ end: function end(tag) {
302
+ var node = stacks.shift();
303
+ if (node.name !== tag) console.error('invalid state: mismatch end tag');
304
+
305
+ if (stacks.length === 0) {
306
+ results.children.push(node);
307
+ } else {
308
+ var parent = stacks[0];
309
+
310
+ if (!parent.children) {
311
+ parent.children = [];
312
+ }
313
+
314
+ parent.children.push(node);
315
+ }
316
+ },
317
+ chars: function chars(text) {
318
+ var node = {
319
+ type: 'text',
320
+ text: text
321
+ };
322
+
323
+ if (stacks.length === 0) {
324
+ results.children.push(node);
325
+ } else {
326
+ var parent = stacks[0];
327
+
328
+ if (!parent.children) {
329
+ parent.children = [];
330
+ }
331
+
332
+ parent.children.push(node);
333
+ }
334
+ },
335
+ comment: function comment(text) {
336
+ var node = {
337
+ node: 'comment',
338
+ text: text
339
+ };
340
+ var parent = stacks[0];
341
+
342
+ if (!parent.children) {
343
+ parent.children = [];
344
+ }
345
+
346
+ parent.children.push(node);
347
+ }
348
+ });
349
+ return results.children;
350
+ }
351
+
352
+ export default parseHtml;
@@ -0,0 +1,44 @@
1
+ <template>
2
+ <view class="ml-rich-text">
3
+ <rich-text :nodes="nodes" :selectable="selectable"></rich-text>
4
+ </view>
5
+ </template>
6
+
7
+ <script>
8
+ import parseHtml from './html-parser'
9
+
10
+ export default {
11
+ name: 'MlRichText',
12
+ props: {
13
+ value: String,
14
+ selectable: {
15
+ type: Boolean,
16
+ default: true
17
+ }
18
+ },
19
+ data () {
20
+ return {
21
+ nodes: []
22
+ }
23
+ },
24
+ watch: {
25
+ value () {
26
+ this.value()
27
+ }
28
+ },
29
+ created () {
30
+ this.load()
31
+ },
32
+ methods: {
33
+ load () {
34
+ this.nodes = this.value ? parseHtml(this.value) : []
35
+ }
36
+ }
37
+ }
38
+ </script>
39
+
40
+ <style lang="scss">
41
+ .ml-rich-text {
42
+ display: block;
43
+ }
44
+ </style>
@@ -118,6 +118,7 @@ export default {
118
118
  }
119
119
  .ml-select-picker-text {
120
120
  flex-grow: 1;
121
+ padding-right: 10rpx;
121
122
  overflow: hidden;
122
123
  text-overflow: ellipsis;
123
124
  white-space: nowrap;
@@ -1,5 +1,5 @@
1
1
  <template>
2
- <view class="ml-upload" :class="className">
2
+ <view class="ml-upload" :class="[className || '']">
3
3
  <view v-if="isFromReadonly">
4
4
  <view v-if="mediatype === 'image'" class="ml-upload-image-list">
5
5
  <view class="ml-upload-file-item" v-for="(item, index) in value" :key="index">
@@ -55,6 +55,10 @@ export default {
55
55
  }
56
56
  .ml-year-picker-text {
57
57
  flex-grow: 1;
58
+ padding-right: 10rpx;
59
+ overflow: hidden;
60
+ text-overflow: ellipsis;
61
+ white-space: nowrap;
58
62
  }
59
63
  .ml-year-picker-icon {
60
64
  color: #6a6a6a;
package/config/store.js CHANGED
@@ -16,6 +16,17 @@ const globalStore = {
16
16
  downloadFile: null,
17
17
  // 删除附件方法
18
18
  removeFile: null
19
+ },
20
+ // 审批组件
21
+ approval: {
22
+ // 审批流程
23
+ select: {
24
+ optionMethod: null
25
+ },
26
+ // 审批记录
27
+ record: {
28
+ optionMethod: null
29
+ }
19
30
  }
20
31
  }
21
32
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mali-applet-ui",
3
- "version": "0.0.49",
3
+ "version": "0.0.52",
4
4
  "description": "码里云小程序组件库",
5
5
  "files": [
6
6
  "components",
@@ -14,6 +14,19 @@
14
14
  "devDependencies": {
15
15
  "xe-utils": "3.5.6"
16
16
  },
17
+ "uni-app": {
18
+ "scripts": {
19
+ "mp-dingtalk": {
20
+ "title": "钉钉小程序",
21
+ "env": {
22
+ "UNI_PLATFORM": "mp-alipay"
23
+ },
24
+ "define": {
25
+ "MP-DINGTALK": true
26
+ }
27
+ }
28
+ }
29
+ },
17
30
  "author": "xu_liangzhan@163.com",
18
31
  "keywords": [
19
32
  "mali-ui",