<template>
	<uni-popup ref="popupRef" type="bottom">

		<view class="popup-box">
			<view class="title-box">
				<text class="title-name">选择币种</text>
				<image class="title-close" src="../../../static/logo.png" mode="aspectFit"></image>
			</view>

			<view class="content-box">
				<view class="search-box">
					<input class="search-input" placeholder-class="search-input-placeholder" placeholder="搜索您要的币种"/>
					<image class="search-icon" src="../../../static/logo.png" mode="aspectFit"></image>
				</view>

				<view class="content-item" v-for="(item , index) in contentList" :key="`content_${index}`">
					<image class="item-icon" :src="item.icon" mode="aspectFit"></image>
					<text class="item-text hide_1">{{item.name}}</text>
				</view>
			</view>
		</view>
	</uni-popup>
</template>

<script>
	export default {
		name: "exchangeSelectCoin",
		data() {
			return {
				contentList: [{
					icon: require('../../../static/icon/icon_01.png'),
					name: 'BTC'
				}, {
					icon: require('../../../static/icon/icon_02.png'),
					name: 'FIL'
				}, {
					icon: require('../../../static/icon/icon_03.png'),
					name: 'ETH'
				}, {
					icon: require('../../../static/icon/icon_04.png'),
					name: 'SHIB'
				}]
			};
		},
		mounted() {
			// this.$refs.popupRef.open()
		},
		methods: {
			open() {
				this.$nextTick(() => {
					this.$refs.popupRef.open();
				})
			}

		}
	}
</script>

<style lang="scss" scoped>
	.popup-box {
		width: 100%;
		min-height: 45vh;
		max-height: 75vh;
		border-radius: 50rpx 50rpx 0px 0px;
		background-color: #fff;

		.title-box {
			width: 100%;
			height: 113rpx;
			border-radius: 50rpx 50rpx 0px 0px;
			background-color: #F7F7F7 !important;
			display: flex;
			justify-content: space-between;
			align-items: center;
			padding: 0 $pages-padding;

			.title-name {

				font-size: 34rpx;
				font-family: PingFang SC, PingFang SC-Bold;
				font-weight: 700;
				text-align: center;
				color: #1a1a1a;
				line-height: 48rpx;
			}

			.title-close {
				width: 25rpx;
				height: 25rpx;
				// background-color: #666666;
			}
		}

		.content-box {
			width: 100%;
			height: calc(100% - 113rpx);
			padding: 0 $pages-padding 20rpx;
			.search-box{
				margin: 30rpx 0 20rpx;
				width: 100%;
				height: 60rpx;
				display: flex;
				align-items: center;
				background-color: #dbdce0;
				border-radius: 30rpx;
				padding: 0 30rpx;
				// <view class="search-box">
				// 	<input class="search-input" placeholder-class="search-input-placeholder" placeholder="请输入密码"/>
				// 	<image class="search-icon" src="../../../static/logo.png" mode="aspectFit"></image>
				// </view>
				.search-input{
					flex: 1;
					height: 100%;
				}
				.search-input,.search-input-placeholder{
				 
					font-size: 24rpx;
					font-family: PingFang SC, PingFang SC-Regular;
					font-weight: 400;
					text-align: left;
					color: #333333;
				}
				.search-icon{
					width: 38rpx;
					height: 38rpx;
					flex-shrink: 0;
				}
				
			}
			.content-item {
				width: 100%;
				height: 66rpx;
				display: flex;
				align-items: center;

				.item-icon {
					width: 46rpx;
					height: 46rpx;
					flex-shrink: 0;
				}

				.item-text {

					font-size: 26rpx;
					font-family: PingFang SC, PingFang SC-Bold;
					font-weight: 700;
					text-align: left;
					color: #343434;
					line-height: 37rpx;
					padding-left: 14rpx;
				}
			}
		}

	}
</style>