<template>
<div class="banner-page" onclick="handleClose">
<div class="banner-page__context">
<image class="banner-image"
onclick="handleClickBanner"
style="{{`margin-top:${top}px;${width}px;height:${height}px;`}}"
src="{{imageUrl}}"></image>
<image class="close"
src="/common/image/close.png"></image>
</div>
</div>
</template>
<script>
export default {
data() {
return {}
},
props: {
imageUrl: {
type: String,
default: `http://img1.imgtn.bdimg.com/it/u=3551116015,2313778618&fm=26&gp=0.jpg`
},
top: {
type: Number,
default: 400
},
{
type:[String,Number],
default:500
},
height:{
type:[String,Number],
default:500
}
},
handleClose(){
this.$emit('close')
},
handleClickBanner(evt){
// console.log(evt)
// evt.stop()
this.$emit('banner')
}
}
</script>
<style lang="less" scoped>
.banner-page {
100%;
height: 100%;
left: 0;
right: 0;
top: 0;
bottom: 0;
position: fixed;
background-color: rgba(0, 0, 0, 0.5);
.banner-page__context {
align-items: center;
flex-direction: column;
/* justify-content: center; */
100%;
.banner-image {
200px;
height: 200px;
display: block;
margin-top: 500px;
}
.close {
130px;
height:130px;
padding:30px;
}
}
}
</style>