|  | @@ -40,7 +40,7 @@
 | 
											
												
													
														|  |        <div
 |  |        <div
 | 
											
												
													
														|  |          v-for="(itemP, indexP) in data.input_list"
 |  |          v-for="(itemP, indexP) in data.input_list"
 | 
											
												
													
														|  |          :key="'input' + indexP"
 |  |          :key="'input' + indexP"
 | 
											
												
													
														|  | -        :class="['position-item position-item-input', 'active']"
 |  | 
 | 
											
												
													
														|  | 
 |  | +        :class="['position-item position-item-input', 'active', ...computedAnswerClass(indexP)]"
 | 
											
												
													
														|  |          :style="{
 |  |          :style="{
 | 
											
												
													
														|  |            width: itemP.width,
 |  |            width: itemP.width,
 | 
											
												
													
														|  |            height: itemP.height,
 |  |            height: itemP.height,
 | 
											
										
											
												
													
														|  | @@ -48,7 +48,45 @@
 | 
											
												
													
														|  |            top: itemP.y,
 |  |            top: itemP.y,
 | 
											
												
													
														|  |          }"
 |  |          }"
 | 
											
												
													
														|  |        >
 |  |        >
 | 
											
												
													
														|  | -        <el-input v-model="answer.answer_list[indexP].text" type="textarea" style="height: 100%" placeholder="请输入" />
 |  | 
 | 
											
												
													
														|  | 
 |  | +        <el-input
 | 
											
												
													
														|  | 
 |  | +          v-model="answer.answer_list[indexP].text"
 | 
											
												
													
														|  | 
 |  | +          :disabled="disabled"
 | 
											
												
													
														|  | 
 |  | +          type="textarea"
 | 
											
												
													
														|  | 
 |  | +          style="height: 100%"
 | 
											
												
													
														|  | 
 |  | +          placeholder="请输入"
 | 
											
												
													
														|  | 
 |  | +        />
 | 
											
												
													
														|  | 
 |  | +      </div>
 | 
											
												
													
														|  | 
 |  | +    </div>
 | 
											
												
													
														|  | 
 |  | +    <div v-if="isShowRightAnswer" class="right-answer">
 | 
											
												
													
														|  | 
 |  | +      <div class="title">正确答案</div>
 | 
											
												
													
														|  | 
 |  | +      <div
 | 
											
												
													
														|  | 
 |  | +        v-if="image_url"
 | 
											
												
													
														|  | 
 |  | +        class="img-box"
 | 
											
												
													
														|  | 
 |  | +        :style="{
 | 
											
												
													
														|  | 
 |  | +          background: 'url(' + image_url + ') center / contain no-repeat',
 | 
											
												
													
														|  | 
 |  | +          width: data.image_width + 'px',
 | 
											
												
													
														|  | 
 |  | +          height: data.image_height + 'px',
 | 
											
												
													
														|  | 
 |  | +        }"
 | 
											
												
													
														|  | 
 |  | +      >
 | 
											
												
													
														|  | 
 |  | +        <div
 | 
											
												
													
														|  | 
 |  | +          v-for="(itemP, indexP) in data.input_list"
 | 
											
												
													
														|  | 
 |  | +          :key="'input' + indexP"
 | 
											
												
													
														|  | 
 |  | +          :class="['position-item position-item-input', 'active']"
 | 
											
												
													
														|  | 
 |  | +          :style="{
 | 
											
												
													
														|  | 
 |  | +            width: itemP.width,
 | 
											
												
													
														|  | 
 |  | +            height: itemP.height,
 | 
											
												
													
														|  | 
 |  | +            left: itemP.x,
 | 
											
												
													
														|  | 
 |  | +            top: itemP.y,
 | 
											
												
													
														|  | 
 |  | +          }"
 | 
											
												
													
														|  | 
 |  | +        >
 | 
											
												
													
														|  | 
 |  | +          <el-input
 | 
											
												
													
														|  | 
 |  | +            v-model="itemP.text"
 | 
											
												
													
														|  | 
 |  | +            :disabled="disabled"
 | 
											
												
													
														|  | 
 |  | +            type="textarea"
 | 
											
												
													
														|  | 
 |  | +            style="height: 100%"
 | 
											
												
													
														|  | 
 |  | +            placeholder="请输入"
 | 
											
												
													
														|  | 
 |  | +          />
 | 
											
												
													
														|  | 
 |  | +        </div>
 | 
											
												
													
														|  |        </div>
 |  |        </div>
 | 
											
												
													
														|  |      </div>
 |  |      </div>
 | 
											
												
													
														|  |      <el-dialog
 |  |      <el-dialog
 | 
											
										
											
												
													
														|  | @@ -147,6 +185,27 @@ export default {
 | 
											
												
													
														|  |          });
 |  |          });
 | 
											
												
													
														|  |        });
 |  |        });
 | 
											
												
													
														|  |      },
 |  |      },
 | 
											
												
													
														|  | 
 |  | +    /**
 | 
											
												
													
														|  | 
 |  | +     * 计算答题对错选项字体颜色
 | 
											
												
													
														|  | 
 |  | +     * @param {string} mark 选项标识
 | 
											
												
													
														|  | 
 |  | +     */
 | 
											
												
													
														|  | 
 |  | +    computedAnswerClass(i) {
 | 
											
												
													
														|  | 
 |  | +      if (!this.isJudgingRightWrong && !this.isShowRightAnswer) {
 | 
											
												
													
														|  | 
 |  | +        return '';
 | 
											
												
													
														|  | 
 |  | +      }
 | 
											
												
													
														|  | 
 |  | +      let answerOption = this.data.input_list[i] ? this.data.input_list[i].text : '';
 | 
											
												
													
														|  | 
 |  | +      let selectValue = this.answer.answer_list[i].text ? this.answer.answer_list[i].text.trim() : '';
 | 
											
												
													
														|  | 
 |  | +      let classList = [];
 | 
											
												
													
														|  | 
 |  | +      let isRight = answerOption && answerOption === selectValue;
 | 
											
												
													
														|  | 
 |  | +      if (this.isJudgingRightWrong && answerOption) {
 | 
											
												
													
														|  | 
 |  | +        isRight ? classList.push('right') : classList.push('wrong');
 | 
											
												
													
														|  | 
 |  | +      }
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +      if (this.isShowRightAnswer && !isRight) {
 | 
											
												
													
														|  | 
 |  | +        classList.push('show-right-answer');
 | 
											
												
													
														|  | 
 |  | +      }
 | 
											
												
													
														|  | 
 |  | +      return classList;
 | 
											
												
													
														|  | 
 |  | +    },
 | 
											
												
													
														|  |      getCurTime(curTime) {
 |  |      getCurTime(curTime) {
 | 
											
												
													
														|  |        this.curTime = curTime * 1000;
 |  |        this.curTime = curTime * 1000;
 | 
											
												
													
														|  |        this.getSentIndex(this.curTime);
 |  |        this.getSentIndex(this.curTime);
 | 
											
										
											
												
													
														|  | @@ -204,10 +263,27 @@ export default {
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |    &.position-item-input {
 |  |    &.position-item-input {
 | 
											
												
													
														|  |      border-color: #f90;
 |  |      border-color: #f90;
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +    &.right {
 | 
											
												
													
														|  | 
 |  | +      border-color: $right-color;
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +      :deep .el-textarea__inner {
 | 
											
												
													
														|  | 
 |  | +        color: $right-color;
 | 
											
												
													
														|  | 
 |  | +      }
 | 
											
												
													
														|  | 
 |  | +    }
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +    &.wrong {
 | 
											
												
													
														|  | 
 |  | +      border-color: $error-color;
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +      :deep .el-textarea__inner {
 | 
											
												
													
														|  | 
 |  | +        color: $error-color;
 | 
											
												
													
														|  | 
 |  | +      }
 | 
											
												
													
														|  | 
 |  | +    }
 | 
											
												
													
														|  |    }
 |  |    }
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |    :deep .el-textarea__inner {
 |  |    :deep .el-textarea__inner {
 | 
											
												
													
														|  |      height: 100%;
 |  |      height: 100%;
 | 
											
												
													
														|  | 
 |  | +    padding: 5px;
 | 
											
												
													
														|  |      font-family: 'League', '楷体';
 |  |      font-family: 'League', '楷体';
 | 
											
												
													
														|  |      text-align: center;
 |  |      text-align: center;
 | 
											
												
													
														|  |      resize: none;
 |  |      resize: none;
 | 
											
										
											
												
													
														|  | @@ -220,6 +296,12 @@ export default {
 | 
											
												
													
														|  |    position: relative;
 |  |    position: relative;
 | 
											
												
													
														|  |    margin: 20px auto;
 |  |    margin: 20px auto;
 | 
											
												
													
														|  |  }
 |  |  }
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +.right-answer {
 | 
											
												
													
														|  | 
 |  | +  .title {
 | 
											
												
													
														|  | 
 |  | +    margin: 24px 0;
 | 
											
												
													
														|  | 
 |  | +  }
 | 
											
												
													
														|  | 
 |  | +}
 | 
											
												
													
														|  |  </style>
 |  |  </style>
 | 
											
												
													
														|  |  <style lang="scss">
 |  |  <style lang="scss">
 | 
											
												
													
														|  |  .magazine-detail-dialog {
 |  |  .magazine-detail-dialog {
 |