I'm trying to get my image preview in full screen, it does show image preview but not in full screen.
Code and Demo
var Main = {
data() {
return {
srcList: [
'https://fuss10.elemecdn.com/e/5d/4a731a90594a4af544c0c25941171jpeg.jpeg',
'https://fuss10.elemecdn.com/e/5d/4a731a90594a4af544c0c25941171jpeg.jpeg'
],
photos: [
'https://fuss10.elemecdn.com/e/5d/4a731a90594a4af544c0c25941171jpeg.jpeg',
'https://fuss10.elemecdn.com/e/5d/4a731a90594a4af544c0c25941171jpeg.jpeg'
],
}
},
}
var Ctor = Vue.extend(Main)
new Ctor().$mount('#app')
@import url("//unpkg.com/element-ui/lib/theme-chalk/index.css");
<script src="https://cdnjs.cloudflare.com/ajax/libs/vue/2.5.17/vue.js"></script>
<script src="//unpkg.com/vue/dist/vue.js"></script>
<script src="//unpkg.com/element-ui/lib/index.js"></script>
<div id="app">
<el-main>
<!-- gallery -->
<el-col :xs="24" :sm="24" :md="{span: 18, offset: 3}" :lg="{span: 18, offset: 3}" :xl="{span: 18, offset: 3}">
<el-card shadow="always" :body-style="{ padding: '0px' }">
<el-row class="mt-5" :gutter="10">
<el-col :xs="24" :sm="24" :md="12" :lg="8" :xl="8" class="text-center mb-3">
<div v-if="photos!=undefined && photos.length > 0">
<el-carousel trigger="click" type="card">
<el-carousel-item v-for="(item, key) in photos" :key="key">
<h3 class="medium">
<el-image
class="image"
:src="item"
style="height:270px;"
:alt="item.caption"
:key="item.id"
:preview-src-list="srcList"></el-image>
</h3>
</el-carousel-item>
</el-carousel>
</div>
</el-col>
</el-row>
</el-card>
</el-col>
</el-main>
</div>
As you see in my demo, When I click to see my images in preview mode they won't show in full screen as in documents , instead they just show on top of my images.
How can i fix it?
