<!-- 中弹窗 二行文字 -->
<template>
	<uni-popup ref="tipMiddlePopup" :animation="false" :is-mask-click="false"
	 mask-background-color="rgba(0,0,0, 0.76);">
	 <view class="ezy-tip-dialog tip-middle-dialog">
		<view class="tip-content-box">
			<view class="tip-title">{{title}}</view>
			<view class="tip-content">{{content}}</view>
			<view class="tip-btn-box">
				<ezyActiveVue class="ezy-btn-active not-confirm-btn" @aclick="handleClose">{{qxBtnName}}</ezyActiveVue>
				<ezyActiveVue class="ezy-btn-active confirm-btn" @aclick="confirmBtn">{{qrBtnName}}</ezyActiveVue>
			</view>
		</view>
	 </view>
	</uni-popup>
</template>

<script setup>
	import { ref } from 'vue';
	import ezyActiveVue from "@/components/ezyActive/ezyActive.vue";
	const props = defineProps({
	  title: {
	    type: String,
	    default: '提示'
	  },
	  content: {
	    type: String,
		require: true,
	    default: ''
	  },
	  qxBtnName: {
	    type: String,
	    default: '取消'
	  },
	  qrBtnName: {
	    type: String,
	    default: '确认'
	  },
	});
	const tipMiddlePopup = ref(null); // 索引
	const $emit = defineEmits(['confirm-btn'])
	// 打开弹窗
	function handleShow() {
		tipMiddlePopup.value.open();
	}
	// 取消
	function handleClose() {
		tipMiddlePopup.value.close();
	}
	// 确认
	function confirmBtn(){
		$emit('confirm-btn');
		tipMiddlePopup.value.close();
	}
	defineExpose({
			handleShow,
			handleClose
		})
</script>

<style>
</style>