<template>
	<view class="inputPop">
		<PopManager :show="inputShow" @clickmask="closePop">
			<view class="replyView">
				<view class="replyViewPackage" >
					<view class="replyInput" ><textarea :placeholder="titleText+':'" v-if="inputShow" v-model="getText"></textarea></view>
					<view class="sendButton" @click="returnText" ><text>确定</text></view>
				</view>
			</view>
		</PopManager>
	</view>
</template>

<script>
import PopManager from '@/components/template/PopManager';
export default {
	components: {
		PopManager
	},
	props: {
		inputShow: {
			type: Boolean,
			default: false
		},
		titleText:{
			type:String,
			default: ''
		},
		texts:{
			type:String,
			default: ''
		}
	},
	data() {
		return {
			getText:''
		};
	},
	mounted(){
		let _this=this
		_this.getText=_this.texts
	},
	watch:{
		'texts':{
			handler(){
				let _this=this
				_this.getText=_this.texts
			}
		}
	},
	methods: {
		closePop() {
			let _this = this;
			this.$emit('closeInputPop');
		},
		returnText(){
			let _this = this;
			this.$emit('returnText',_this.getText);
		}
	}
};
</script>

<style lang="less">
.inputPop {
	font-size: 0;
}
.replyViewPackage {
	padding: 30upx;
}

.coverView {
	z-index: 2;
	position: fixed;
	top: 84upx;
	background: rgba(0, 0, 0, 0);
	width: 750upx;
}

.replyInput {
	background: rgba(248, 248, 248, 1);
	width: 500upx;
	height: 200upx;
	vertical-align: middle;
	margin: 20upx auto 0 auto;
	background: white;
	font-size: 24upx;
	font-family: Source Han Sans CN;

	color: rgba(51, 51, 51, 1);

	> textarea {
		background: rgba(248, 248, 248, 1);
		width: 500upx !important;
		height: 200upx !important;
	}
}

.sendButton {
	text-align: center;
	margin: 20upx auto 0 auto;
	width: 292upx;
	height: 74upx;
	background: #3388ff;
	border-radius: 37upx;
	> text {
		line-height: 74upx;
		font-size: 24upx;

		color: #ffffff;
	}
}

.replyView {
	border: 1upx solid rgba(0, 0, 0, 0);
	width: 600upx;
	background: rgba(255, 255, 255, 1);
	border-radius: 20upx;
	background: #f8f8f8;
}
</style>
