<template>
	<view class="rank">
		<view class="rank-ul">
			<view class="rank-li" v-for="(item, index) in viewModel" :key="index" >
				<text class="rank-li-text">{{item.name}}</text>
				<text class="rank-li-intro">{{item.intro}}</text>
				<view class="rank-li-bottom">
					<text class="rank-li-num" :style="{color: item.bgcolor}">{{item.value}}</text>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		props: {
			count: {},
			viewModel: {}
		}
	} 
</script>

<style lang="scss" scoped>
	.rank {
		padding: 30rpx 10rpx;
		padding-bottom: 10rpx;
		&-ul{
			display: flex;
			flex-wrap: wrap;
		}
		&-li {
			width: 345rpx;
			min-height: 140rpx;
			margin: 0 10rpx;
			box-sizing: border-box;
			padding: 15rpx;
			margin-bottom: 20rpx;
			border-radius: 5rpx;
			background-color: #FFFFFF;
			position: relative;
			display: flex;
			flex-direction: column;
			justify-content: space-between;
			box-shadow: 0 0 12px rgba(0, 0, 0, 0.13);
			&-text{
				@include styleFont(#343434, 26rpx);
				line-height: 26rpx;
			}
			&-intro{
				@include styleFont(#9699a2, 20rpx);
			}
			&-bottom{
				margin: 10rpx 0;
			}
			&-num{
				@include styleFont(#fff, 32rpx, 1);
			}
		}
	}
</style>
