From 28f79c906721eea9ff2c74cf87ae1179a831d534 Mon Sep 17 00:00:00 2001 From: 闫增涛 <1829501689@qq.com> Date: 星期二, 04 六月 2024 17:43:59 +0800 Subject: [PATCH] 合并 --- src/components/matching/matching.vue | 12 ++++++------ 1 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/components/matching/matching.vue b/src/components/matching/matching.vue index 85cb98d..875ff46 100644 --- a/src/components/matching/matching.vue +++ b/src/components/matching/matching.vue @@ -54,7 +54,7 @@ </div> <!-- 瑙f瀽 --> <ul class="show-answer" v-if="isShowAnswer"> - <li>绛旀缁撴灉锛�</li> + <li v-if="isRight !== null">绛旀缁撴灉锛�<span v-if="isRight" style="color: #83e089;">姝g‘</span> <span v-if="isRight == false" style="color:#d81e06">閿欒</span></li> <li class="show-answer-box"> <div>绛旀:</div> <div> @@ -85,7 +85,7 @@ checkItemIndex: null, isShowAnswer: false, isRight: null, - value:[{left:0,right:0}], + value:[], pageNum:null }; }, @@ -336,13 +336,13 @@ const rightIndex = this.item.options.linkValues.findIndex( (citem) => citem.oldId == item.oldId ); - debugger; answerArr.push({ left: index, right: rightIndex, }); } this.isRight = this.areArraysEqual(this.item.userChoise,answerArr) + this.item.showAnswer = true console.log( "绛旀", answerArr, @@ -385,6 +385,7 @@ }, // 閲嶅仛 redo() { + this.item.showAnswer = false localStorage.removeItem(this.config.activeBook.name + '-matching-' + this.pageNum) this.value = [] for (let index = 0; index < this.leftArr.length; index++) { @@ -460,10 +461,9 @@ margin: 30px auto; width: 100%; height: min-content; - // background-color: pink; box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1); - .show-answer-box { - padding: 10px; + li { + padding:10px } } .btn-bottom { -- Gitblit v1.9.1