@netang/quasar 0.2.1 → 0.2.2
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.
|
@@ -100,9 +100,13 @@
|
|
|
100
100
|
v-for="(fileItem, fileItemIndex) in query"
|
|
101
101
|
:key="`query-item-${fileItem.id}`"
|
|
102
102
|
class="n-uploader-query__item n-uploader-query__item--image"
|
|
103
|
-
:class="
|
|
104
|
-
|
|
105
|
-
|
|
103
|
+
:class="[
|
|
104
|
+
{
|
|
105
|
+
ghost: fileItemIndex === fromIndex,
|
|
106
|
+
},
|
|
107
|
+
itemClass,
|
|
108
|
+
]"
|
|
109
|
+
:style="itemStyle"
|
|
106
110
|
:draggable="currentDrag"
|
|
107
111
|
@mousedown.self="mousedown($event, fileItemIndex)"
|
|
108
112
|
@mouseup="dragEnd"
|
|
@@ -173,6 +177,7 @@
|
|
|
173
177
|
<slot
|
|
174
178
|
name="settings"
|
|
175
179
|
:file="fileItem"
|
|
180
|
+
:index="fileItemIndex"
|
|
176
181
|
/>
|
|
177
182
|
|
|
178
183
|
<!-- 预览 -->
|
|
@@ -198,7 +203,15 @@
|
|
|
198
203
|
/>
|
|
199
204
|
|
|
200
205
|
</div>
|
|
206
|
+
|
|
207
|
+
<!-- 插槽-->
|
|
208
|
+
<slot
|
|
209
|
+
name="item-append"
|
|
210
|
+
:file="fileItem"
|
|
211
|
+
:index="fileItemIndex"
|
|
212
|
+
/>
|
|
201
213
|
</n-img>
|
|
214
|
+
|
|
202
215
|
</div>
|
|
203
216
|
|
|
204
217
|
<!-- 右边方块按钮 -->
|
|
@@ -236,12 +249,18 @@
|
|
|
236
249
|
v-for="(fileItem, fileItemIndex) in query"
|
|
237
250
|
:key="`query-item-${fileItem.id}`"
|
|
238
251
|
class="n-uploader-query__item n-uploader-query__item--file"
|
|
239
|
-
:class="
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
252
|
+
:class="[
|
|
253
|
+
{
|
|
254
|
+
ghost: fileItemIndex === fromIndex,
|
|
255
|
+
},
|
|
256
|
+
itemClass,
|
|
257
|
+
]"
|
|
258
|
+
:style="[
|
|
259
|
+
{
|
|
260
|
+
height: toPx(currentSize),
|
|
261
|
+
},
|
|
262
|
+
itemStyle,
|
|
263
|
+
]"
|
|
245
264
|
:draggable="currentDrag"
|
|
246
265
|
@mousedown.self="mousedown($event, fileItemIndex)"
|
|
247
266
|
@mouseup="dragEnd"
|
|
@@ -321,6 +340,7 @@
|
|
|
321
340
|
<slot
|
|
322
341
|
name="settings"
|
|
323
342
|
:file="fileItem"
|
|
343
|
+
:index="fileItemIndex"
|
|
324
344
|
/>
|
|
325
345
|
|
|
326
346
|
<template v-if="fileItem.status === UPLOAD_STATUS.success">
|
|
@@ -381,6 +401,14 @@
|
|
|
381
401
|
v-if="! noDelete && ! disable && ! readonly"
|
|
382
402
|
/>
|
|
383
403
|
</div>
|
|
404
|
+
|
|
405
|
+
<!-- 插槽-->
|
|
406
|
+
<slot
|
|
407
|
+
name="item-append"
|
|
408
|
+
:file="fileItem"
|
|
409
|
+
:index="fileItemIndex"
|
|
410
|
+
/>
|
|
411
|
+
|
|
384
412
|
</div>
|
|
385
413
|
</template>
|
|
386
414
|
</n-dragger>
|
|
@@ -429,6 +457,10 @@ export default {
|
|
|
429
457
|
* 声明属性
|
|
430
458
|
*/
|
|
431
459
|
props: {
|
|
460
|
+
// 单个文件类名
|
|
461
|
+
itemClass: [String, Array, Object],
|
|
462
|
+
// 单个文件样式
|
|
463
|
+
itemStyle: [String, Array, Object],
|
|
432
464
|
// 按钮类型, 可选值 square button
|
|
433
465
|
buttonType: {
|
|
434
466
|
type: String,
|
package/package.json
CHANGED