<template>
	<view class="add">
		<view class="add-content">
			<view class="content">
				<view class="title">举报原因</view>
				<view class="info">
					<view class="li" :class="tabIndex == 1?'li-on':''" @click="tabItem(1)">
						垃圾广告/骗子
						<image class="img1" src="@/static/icon-check.png"></image><image class="img2" src="@/static/icon-check-on.png"></image>
					</view>
					<view class="li" :class="tabIndex == 2?'li-on':''" @click="tabItem(2)">
						虚假信息/盗用照片
						<image class="img1" src="@/static/icon-check.png"></image><image class="img2" src="@/static/icon-check-on.png"></image>
					</view>
					<view class="li" :class="tabIndex == 3?'li-on':''" @click="tabItem(3)">
						色情低俗
						<image class="img1" src="@/static/icon-check.png"></image><image class="img2" src="@/static/icon-check-on.png"></image>
					</view>
					<view class="li" :class="tabIndex == 4?'li-on':''" @click="tabItem(4)">
						骚扰谩骂
						<image class="img1" src="@/static/icon-check.png"></image><image class="img2" src="@/static/icon-check-on.png"></image>
					</view>
					<view class="li" :class="tabIndex == 5?'li-on':''" @click="tabItem(5)">
						骗子
						<image class="img1" src="@/static/icon-check.png"></image><image class="img2" src="@/static/icon-check-on.png"></image>
					</view>
				</view>
			</view>
			<view class="content">
				<view class="title">补充说明</view>
				<view class="box">
					<textarea maxlength="200" placeholder="如有必要，请详细描述(200字以内)~"></textarea>
				</view>
			</view>
			<view class="content">
				<view class="title">上传图片</view>
				<view class="list">
					<view class="item">
						<image class="pic" src="@/static/1.png"></image>
						<image class="del" src="@/static/fabu-cha.png"></image>
					</view>
					<view class="upload">
						<image class="pic" src="@/static/fankui-tianjia.png"></image>
						<view class="txt">上传图片</view>
					</view>
				</view>
			</view>
		</view>
		<view class="add-fd">
			<view class="btn">提交</view>
		</view>
		<u-popup v-model="show" mode="center" border-radius="20" :mask-close-able="true">
			<view class="feed">
				<image src="@/static/feed-01.png"></image>
				<view class="title">反馈提交成功</view>
				<view class="btn">我知道了</view>
			</view>
		</u-popup>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				show: false,
				tabIndex: 1
			};
		},
		methods: {
			tabItem(index) {
				this.tabIndex = index;
			}
		}
	}
</script>

<style scoped lang="scss">
.add{
	overflow: hidden;
	padding-bottom: 110rpx;
	.feed{
		width: 670rpx;
		height: 688rpx;
		background: #FFFFFF;
		border-radius: 20rpx;
		text-align: center;
		padding-top: 70rpx;
		box-sizing: border-box;
		image{
			width: 408rpx;
			height: 315rpx;
		}
		.title{
			font-weight: 500;
			font-size: 36rpx;
			color: #222222;
			margin-top: 50rpx;
		}
		.btn{
			width: 400rpx;
			line-height: 90rpx;
			background: linear-gradient(0deg, #000000, #3D3B38);
			box-shadow: 0px 4rpx 18rpx 0px rgba(42,41,39,0.34);
			border-radius: 90rpx;
			font-weight: 500;
			font-size: 30rpx;
			color: #FFFFFF;
			margin: 0 auto;
			margin-top: 50rpx;
		}
	}
	&-content{
		padding: 0 25rpx;
		overflow: hidden;
		.content{
			background: #FFFFFF;
			border-radius: 20rpx;
			padding: 30rpx;
			box-sizing: border-box;
			margin-top: 20rpx;
			overflow: hidden;
			.box{
				width: 100%;
				height: 220rpx;
				background: #F6F6F6;
				border-radius: 10rpx;
				padding: 30rpx;
				box-sizing: border-box;
				margin-top: 30rpx;
				textarea{
					width: 100%;
					height: 100%;
					font-weight: 400;
					font-size: 30rpx;
					color: #212121;
				}
			}
			
			.li{
				display: flex;
				align-items: center;
				justify-content: space-between;
				padding: 20rpx 0;
				font-weight: 500;
				font-size: 30rpx;
				color: #333333;
				image{
					width: 35rpx;
					height: 35rpx;
				}
				.img1{
					display: block;
				}
				.img2{
					display: none;
				}
				&-on{
					.img1{
						display: none;
					}
					.img2{
						display: block;
					}
				}
			}
		}
		.title{
			font-size: 34rpx;
			color: #333333;
		}
		.list{
			width: 110%;
			.upload{
				width: 150rpx;
				height: 150rpx;
				background: #FFFFFF;
				border-radius: 10rpx;
				border: 1px solid #DDDDDD;
				float: left;
				font-weight: 400;
				text-align: center;
				font-size: 24rpx;
				color: #999999;
				margin-top: 30rpx;
				image{
					width: 50rpx;
					height: 50rpx;
					display: block;
					margin: 0 auto;
					margin-top: 25rpx;
					margin-bottom: 10rpx;
				}
			}
			.item{
				width: 150rpx;
				height: 150rpx;
				border-radius: 10rpx;
				float: left;
				margin-top: 30rpx;
				overflow: hidden;
				position: relative;
				margin-right: 12rpx;
				.pic{
					width: 100%;
					height: 100%;
				}
				.del{
					width: 35rpx;
					height: 35rpx;
					position: absolute;
					right: 0;
					top: 0;
					z-index: 2;
				}
			}
		}
	}
	&-fd{
		background-color: #F3F4F5;
		width: 100%;
		padding: 30rpx 25rpx;
		box-sizing: border-box;
		position: fixed;
		left: 0;
		bottom: 0;
		z-index: 22;
		.btn{
			width: 100%;
			line-height: 98rpx;
			background: linear-gradient(0deg, #000000, #3D3B38);
			box-shadow: 0px 4rpx 18rpx 0px rgba(42,41,39,0.34);
			border-radius: 98rpx;
			text-align: center;
			font-weight: 400;
			font-size: 30rpx;
			color: #FFFFFF;
			letter-spacing: 5rpx;
		}
	}
}
</style>