clarms-plugins-upload.vue 1.98 KB
<template>
	<div class="comp">
		<div class="clarms-container">
			<div class="clarms-box">
				<div class="clarms-tips" v-if="tipsVisible">
					<div class="cont">{{options.toast}}</div>
				</div>
				<div class="clarms-header">
					<div class="clarms-header-2">
						<div class="clarms-icon" @mouseover="onShowTipsOverHandler($event)" @mouseout="onShowTipsOutHandler($event)">
							<img :src='icon'>
						</div>
						<div class="clarms-title-container">
							<div class="clarms-t1" :class="{clarmsActivty:images && images.length > 0}">{{options.name}}</div>
							<div class="clarms-t2">{{$t('clarms.step2.uploadFile')}}{{uploadFiles}}</div>
						</div>
					</div>
					<div class="clarms-btn" :class="{disabled:uploading}" @click="selectMutilFile">
						{{$t('clarms.step2.btnUpload')}}
					</div>
				</div>
				<div v-if="images && images.length > 0">
					<div class="line">
						<hr>
					</div>
					<div class="clarms-img-group">
						<div class="clarms-img-item-plugin" @mouseover="onOverHandler($event,item,index)" v-for="(item,index) in images" :key="index">
							<div class="clarms-img-item">
								<img class="clarms-img-cont" :src="item.data">
								<div class="clarms-img-mask" v-if="item.showMask && !item.intervial && !item.err">
									<img src="@/assets/images/clarms/close.png">
								</div>
								<div class="clarms-img-mask" v-if="item.showMask &&  !item.intervial && !item.err" @mouseout="onOutHandler($event,item,index)" @click="removeItem(index)">
								</div>
								<div class="clarms-img-mask mask-bg-2" v-if="item.intervial">
									{{item.tips}}
								</div>
								<div class="clarms-img-mask mask-bg-2" v-if="item.err" @click="removeItem(index)">
									{{item.err}}
								</div>
							</div>
						</div>
					</div>
					<!-- <div class="clarms-empty-line"></div> -->
				</div>
			</div>
		</div>
	</div>
</template>


<script src="./clarms-plugins-upload.js"></script>
<style lang="scss" scoped>
@import "./clarms-plugins-upload.scss";
</style>