<template>
	<swiper class="swiper-box" :style="{'height': height + 'rpx'}" :interval="2000"
		:disable-touch="!list || list.length <= 1" circular :indicator-dots="list && list.length > 1"
		indicator-active-color="#fff">
		<swiper-item class="swiper-item" v-for="(item , index) in list" :key="index">
			<image :src="item" mode="aspectFill" :style="{'border-radius':borderRadius + 'rpx'}"></image>
		</swiper-item>
	</swiper>

</template>

<script>
	export default {
		name: "sw-swiper",
		props: {
			list: {
				type: Array,
				default: () => []
			},
			borderRadius: {
				type: Number,
				default: 0
			},
			height: {
				type: Number,
				default: 200
			}
		},
		data() {
			return {};
		},
		created() {

		},
		methods: {


		},
	}
</script>

<style lang="scss" scoped>
	.swiper-box {
		width: 100%;

		.swiper-item {
			width: 100%;
			height: 100%;

			image {
				width: 100%;
				height: 100%;
			}
		}
	}
</style>