Merge branch 'master' of https://github.com/primefaces/primevue
commit
d1432ab395
|
@ -19,7 +19,7 @@
|
|||
<sub-menu :model="item.items" v-if="visible(item) && item.items" :key="item.label + '_sub_'"
|
||||
@leaf-click="onLeafClick" :parentActive="item === activeItem" />
|
||||
</li>
|
||||
<li class="p-menu-separator" :style="item.style" v-if="visible(item) && item.separator" :key="'separator' + i" role="separator"></li>
|
||||
<li :class="['p-menu-separator', item.class]" :style="item.style" v-if="visible(item) && item.separator" :key="'separator' + i" role="separator"></li>
|
||||
</template>
|
||||
</ul>
|
||||
</transition>
|
||||
|
|
|
@ -18,6 +18,8 @@ declare class FileUpload extends Vue {
|
|||
uploadLabel?: string;
|
||||
cancelLabel?: string;
|
||||
customUpload?: boolean;
|
||||
showUploadButton?: boolean;
|
||||
showCancelButton?: boolean;
|
||||
$emit(eventName: 'select', e: { originalEvent: Event, files: any }): this;
|
||||
$emit(eventName: 'before-upload', e: { xhr: XMLHttpRequest, formData: any }): this;
|
||||
$emit(eventName: 'progress', e: { originalEvent: Event, progress: any }): this;
|
||||
|
|
|
@ -6,8 +6,8 @@
|
|||
<span class="p-button-icon p-button-icon-left pi pi-fw pi-plus"></span>
|
||||
<span class="p-button-label">{{chooseButtonLabel}}</span>
|
||||
</span>
|
||||
<FileUploadButton :label="uploadButtonLabel" icon="pi pi-upload" @click="upload" :disabled="uploadDisabled" />
|
||||
<FileUploadButton :label="cancelButtonLabel" icon="pi pi-times" @click="clear" :disabled="cancelDisabled" />
|
||||
<FileUploadButton :label="uploadButtonLabel" icon="pi pi-upload" @click="upload" :disabled="uploadDisabled" v-if="showUploadButton" />
|
||||
<FileUploadButton :label="cancelButtonLabel" icon="pi pi-times" @click="clear" :disabled="cancelDisabled" v-if="showCancelButton" />
|
||||
</div>
|
||||
<div ref="content" class="p-fileupload-content" @dragenter="onDragEnter" @dragover="onDragOver" @dragleave="onDragLeave" @drop="onDrop">
|
||||
<FileUploadProgressBar :value="progress" v-if="hasFiles" />
|
||||
|
@ -116,6 +116,14 @@ export default {
|
|||
customUpload: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
showUploadButton: {
|
||||
type: Boolean,
|
||||
default: true
|
||||
},
|
||||
showCancelButton: {
|
||||
type: Boolean,
|
||||
default: true
|
||||
}
|
||||
},
|
||||
duplicateIEEvent: false,
|
||||
|
|
|
@ -35,7 +35,7 @@
|
|||
<span :class="getSubmenuIcon()" v-if="item.items"></span>
|
||||
</a>
|
||||
</li>
|
||||
<li class="p-menu-separator" :style="item.style" v-if="visible(item) && item.separator" :key="'separator' + i" role="separator"></li>
|
||||
<li :class="['p-menu-separator', item.class]" :style="item.style" v-if="visible(item) && item.separator" :key="'separator' + i" role="separator"></li>
|
||||
</template>
|
||||
</ul>
|
||||
</div>
|
||||
|
|
|
@ -7,10 +7,10 @@
|
|||
<li class="p-submenu-header" :key="item.label+i" v-if="item.items">{{item.label}}</li>
|
||||
<template v-for="(child, j) of item.items">
|
||||
<Menuitem v-if="visible(child) && !child.separator" :key="child.label + i + j" :item="child" @click="itemClick" />
|
||||
<li v-else-if="visible(child) && child.separator" class="p-menu-separator" :style="child.style" :key="'separator' + i + j" role="separator"></li>
|
||||
<li v-else-if="visible(child) && child.separator" :class="['p-menu-separator', child.class]" :style="child.style" :key="'separator' + i + j" role="separator"></li>
|
||||
</template>
|
||||
</template>
|
||||
<li v-else-if="visible(item) && item.separator" class="p-menu-separator" :style="item.style" :key="'separator' + i" role="separator"></li>
|
||||
<li v-else-if="visible(item) && item.separator" :class="['p-menu-separator', item.class]" :style="item.style" :key="'separator' + i" role="separator"></li>
|
||||
<Menuitem v-else :key="item.label+i" :item="item" @click="itemClick" />
|
||||
</template>
|
||||
</ul>
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
<sub-menu :model="item.items" v-if="visible(item) && item.items" :key="item.label + '_sub_'" :mobileActive="mobileActive"
|
||||
@leaf-click="onLeafClick" @keydown-item="onChildItemKeyDown" :parentActive="item === activeItem" />
|
||||
</li>
|
||||
<li class="p-menu-separator" :style="item.style" v-if="visible(item) && item.separator" :key="'separator' + i" role="separator"></li>
|
||||
<li :class="['p-menu-separator', item.class]" :style="item.style" v-if="visible(item) && item.separator" :key="'separator' + i" role="separator"></li>
|
||||
</template>
|
||||
</ul>
|
||||
</template>
|
||||
|
|
|
@ -20,7 +20,7 @@
|
|||
</div>
|
||||
</transition>
|
||||
</li>
|
||||
<li class="p-menu-separator" :style="item.style" v-if="visible(item) && item.separator" :key="'separator' + i"></li>
|
||||
<li :class="['p-menu-separator', item.class]" :style="item.style" v-if="visible(item) && item.separator" :key="'separator' + i"></li>
|
||||
</template>
|
||||
</ul>
|
||||
</template>
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
<sub-menu :model="item.items" v-if="visible(item) && item.items" :key="item.label + '_sub_'"
|
||||
@leaf-click="onLeafClick" @keydown-item="onChildItemKeyDown" :parentActive="item === activeItem" />
|
||||
</li>
|
||||
<li class="p-menu-separator" :style="item.style" v-if="visible(item) && item.separator" :key="'separator' + i" role="separator"></li>
|
||||
<li :class="['p-menu-separator', item.class]" :style="item.style" v-if="visible(item) && item.separator" :key="'separator' + i" role="separator"></li>
|
||||
</template>
|
||||
</ul>
|
||||
</template>
|
||||
|
|
|
@ -214,6 +214,18 @@ myUploader(event) {
|
|||
<td>boolean</td>
|
||||
<td>false</td>
|
||||
<td>Whether to use the default upload or a manual implementation defined in uploadHandler callback. Defaults to PrimeVue <router-link to="/locale">Locale</router-link> configuration.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>showUploadButton</td>
|
||||
<td>boolean</td>
|
||||
<td>true</td>
|
||||
<td>Whether to show the upload button.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>showCancelButton</td>
|
||||
<td>boolean</td>
|
||||
<td>true</td>
|
||||
<td>Whether to show the cancel button.</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
|
Loading…
Reference in New Issue