Skip to content

Commit 48d9d0e

Browse files
committed
updatedocs
1 parent 11af97d commit 48d9d0e

File tree

3 files changed

+45
-7
lines changed

3 files changed

+45
-7
lines changed

docs/docs/en.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1144,6 +1144,25 @@ Is dragging
11441144
```
11451145

11461146

1147+
### dropElementActive
1148+
1149+
Is Dragged to container
1150+
1151+
* **Type:** `Boolean`
1152+
1153+
* **Read only:** `true`
1154+
1155+
* **Default:** `false`
1156+
1157+
* **Usage:**
1158+
```html
1159+
<app>
1160+
<file-upload ref="upload" :drop="true"></file-upload>
1161+
<span v-show="$refs.upload && $refs.upload.dropActive && $refs.upload.dropElementActive">Already dragged here, release the mouse to add the file</span>
1162+
</app>
1163+
```
1164+
1165+
11471166

11481167

11491168

docs/docs/zh-cn.md

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -930,7 +930,26 @@ Add, update, remove pre-filter
930930
```html
931931
<app>
932932
<file-upload ref="upload" :drop="true"></file-upload>
933-
<span v-show="$refs.upload && $refs.upload.dropActive">拖拽到这里上传</span>
933+
<span v-show="$refs.upload && $refs.upload.dropActive">拖拽到此处上传</span>
934+
</app>
935+
```
936+
937+
938+
### dropElementActive
939+
940+
是否拖拽到容器组件内
941+
942+
* **类型:** `Boolean`
943+
944+
* **只读:** `true`
945+
946+
* **默认值:** `false`
947+
948+
* **示例:**
949+
```html
950+
<app>
951+
<file-upload ref="upload" :drop="true"></file-upload>
952+
<span v-show="$refs.upload && $refs.upload.dropActive && $refs.upload.dropElementActive">已拖到此处 释放鼠标即可添加文件</span>
934953
</app>
935954
```
936955

docs/views/examples/Multiple.vue

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@
66
:class="{ 'drop-element-active': $refs.upload1 && $refs.upload1.dropElementActive }">
77
<h3>
88
{{ $refs.upload1 && $refs.upload1.dropElementActive ?
9-
"Drop files to upload1 (element)"
9+
"Release the mouse to add to upload1 (element)"
1010
:
11-
"Drop files to upload1" }}
11+
"Drag and drop here to upload1" }}
1212
</h3>
1313
</div>
1414

@@ -22,7 +22,7 @@
2222
<span v-else></span>
2323
</li>
2424
</ul>
25-
<h5 class="drop-title">Drag and drop files into the container to upload</h5>
25+
<h5 class="drop-title">Drag and drop files into the container to upload1</h5>
2626
<div class="example-btn">
2727
<file-upload class="btn btn-primary" input-id="file1" post-action="/upload/post" v-model="files1" ref="upload1"
2828
drop=".upload-drop-container-1" :drop-directory="true" :multiple="true">
@@ -57,9 +57,9 @@
5757
<h3>
5858
{{ $refs.upload2 && $refs.upload2.dropElementActive
5959
?
60-
"Drop files to upload2 (element)"
60+
"Release the mouse to add to upload2 (element)"
6161
:
62-
"Drop files to upload2" }}
62+
"Drag and drop here to upload2" }}
6363
</h3>
6464
</div>
6565
<ul>
@@ -72,7 +72,7 @@
7272
<span v-else></span>
7373
</li>
7474
</ul>
75-
<h5 class="drop-title">Drag and drop files into the container to upload</h5>
75+
<h5 class="drop-title">Drag and drop files into the container to upload2</h5>
7676
<div class="example-btn">
7777
<file-upload class="btn btn-primary" input-id="file2" post-action="/upload/post" v-model="files2" ref="upload2"
7878
drop=".upload-drop-container-2" :drop-directory="true" :multiple="true">

0 commit comments

Comments
 (0)