<template>
	<uni-popup ref="popupRef" background-color="#fff" >
		<view class="phone-question-answer-box">
			<view class="phone-line-title">答案解析</view>
			<view class="btdf-row">本题得分：<text>{{data.score}}</text>分</view>
			<view class="zqda-row">正确答案：<text>{{data.result}}</text></view>
			<view class="ndda-row">您的答案：<text>{{data.reply}}</text></view>
			<view class="dajx-row">答案解析: 
				<rich-text :nodes="data.answer"></rich-text>
			</view>
		</view>
	</uni-popup>
</template>

<script setup>
	import {ref,reactive} from "vue";
	const popupRef = ref('popupRef');
	const data = reactive({
		score: 0,
		reply: '',
		result: '',
		answer: '',
	})
	
	function showPopup(options) {
		console.log('options',options)
		data.score = options.score;
		data.reply = options.reply;
		data.result = options.result;
		data.answer = options.answer;
		
		popupRef.value.open('bottom')
	}
	
	defineExpose({showPopup})
</script>

<style>

</style>