mirror of
https://github.com/iczer/vue-antd-admin.git
synced 2025-12-19 20:46:59 +08:00
37 lines
637 B
Vue
37 lines
637 B
Vue
<template>
|
|
<div class="style">
|
|
<img :src="img" />
|
|
<div v-if="selected" class="select-item">
|
|
<a-icon type="check" />
|
|
</div>
|
|
</div>
|
|
</template>
|
|
|
|
<script>
|
|
export default {
|
|
name: 'StyleItem',
|
|
props: ['selected', 'img']
|
|
}
|
|
</script>
|
|
|
|
<style lang="less" scoped>
|
|
.style{
|
|
margin-right: 16px;
|
|
position: relative;
|
|
border-radius: 4px;
|
|
cursor: pointer;
|
|
.select-item{
|
|
position: absolute;
|
|
top: 0;
|
|
right: 0;
|
|
width: 100%;
|
|
padding-top: 15px;
|
|
padding-left: 24px;
|
|
height: 100%;
|
|
color: #1890ff;
|
|
font-size: 14px;
|
|
font-weight: bold;
|
|
}
|
|
}
|
|
</style>
|