SentenceInput.vue 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744
  1. <!-- -->
  2. <template>
  3. <div
  4. class="Big-Book-prev-Textdes"
  5. v-if="
  6. curQue && judgeAnswer == 'standardAnswer'
  7. ? userErrList.length > 0
  8. ? true
  9. : false
  10. : true
  11. "
  12. >
  13. <h6
  14. v-if="judgeAnswer == 'userAnswer' || judgeAnswer == 'studentAnswer'"
  15. class="standardTitle"
  16. style="margin: 10px 0 8px 24px"
  17. >
  18. {{ judgeAnswer == "userAnswer" ? "Your answer" : "Student answers" }}
  19. </h6>
  20. <h6
  21. v-else-if="judgeAnswer == 'standardAnswer'"
  22. class="standardTitle"
  23. style="margin: 10px 0 8px 24px"
  24. >
  25. Standard answer
  26. </h6>
  27. <h2 v-if="curQue.title">{{ curQue.title }}</h2>
  28. <ul>
  29. <li
  30. v-for="(items, indexs) in judgeAnswer == 'standardAnswer'
  31. ? userErrList
  32. : curQue.option"
  33. :key="indexs"
  34. :class="[
  35. judgeAnswer == 'standardAnswer' ? 'standardAnswer' : '',
  36. judgeAnswer == 'standardAnswer'
  37. ? 'correct'
  38. : judgeAnswer == 'studentAnswer'
  39. ? curQue.Bookanswer[indexs].userAnswerJudge
  40. ? curQue.Bookanswer[indexs].userAnswerJudge == '[JUDGE##F##JUDGE]'
  41. ? 'error'
  42. : 'correct'
  43. : ''
  44. : '',
  45. ]"
  46. >
  47. <b class="xuhao" v-if="items.number">{{ items.number }}</b>
  48. <p
  49. :class="[oldsrc == items.mp3_list[0].id ? palyClass : '']"
  50. @click="handlePlayVoice(items.mp3_list[0].id)"
  51. v-if="items.mp3_list && items.mp3_list.length > 0"
  52. ></p>
  53. <!-- 句子内容 -->
  54. <div class="item-content">
  55. <!-- 如果不是填空题 不替换 -->
  56. <template v-if="dataType.indexOf('sentence_input_chs') == -1">
  57. <template v-if="items.detail.wordsList.length == 0">
  58. <p :class="['content-con']" v-if="items.detail.sentence">
  59. {{ items.detail.sentence }}
  60. </p>
  61. </template>
  62. <template v-else>
  63. <div class="con-box">
  64. <div
  65. :class="['con-item', indexCon === 0 ? 'con-item-0' : '']"
  66. v-for="(itemCon, indexCon) in items.detail.resArr"
  67. :key="indexCon"
  68. v-show="itemCon.isShow"
  69. >
  70. <template
  71. v-if="
  72. items.detail.wordsList[indexCon + 1] &&
  73. items.detail.wordsList[indexCon + 1].chs &&
  74. chsFhList.indexOf(
  75. items.detail.wordsList[indexCon + 1].chs
  76. ) > -1
  77. "
  78. >
  79. <div class="synthesis-box">
  80. <div>
  81. <span
  82. class="pinyin"
  83. :class="[
  84. noFont.indexOf(itemCon.pinyin) > -1 ? 'noFont' : '',
  85. ]"
  86. >{{ itemCon.pinyin }}</span
  87. >
  88. <span class="hanzi content-con">{{ itemCon.chs }}</span>
  89. </div>
  90. <div style="text-align: left">
  91. <span
  92. class="pinyin"
  93. :class="[
  94. noFont.indexOf(
  95. items.detail.wordsList[indexCon + 1].pinyin
  96. ) > -1
  97. ? 'noFont'
  98. : '',
  99. ]"
  100. >{{
  101. items.detail.wordsList[indexCon + 1].pinyin
  102. }}</span
  103. >
  104. <span class="hanzi content-con">{{
  105. items.detail.wordsList[indexCon + 1].chs
  106. }}</span>
  107. </div>
  108. </div>
  109. </template>
  110. <template v-else>
  111. <span
  112. class="pinyin"
  113. :class="[
  114. noFont.indexOf(itemCon.pinyin) > -1 ? 'noFont' : '',
  115. ]"
  116. >{{ itemCon.pinyin }}</span
  117. >
  118. <span class="hanzi content-con">{{ itemCon.chs }}</span>
  119. </template>
  120. </div>
  121. </div>
  122. </template>
  123. <b class="content-en" v-if="items.en">{{ items.en }}</b>
  124. </template>
  125. <template v-else>
  126. <div class="chs_pinyin">
  127. <div
  128. v-for="(conent, conIndex) in items.detail.wordsList"
  129. :key="conIndex + 'con'"
  130. >
  131. <template v-if="items.detail.pyPosition == 'top'">
  132. <div
  133. v-if="conent.pinyin == '__'"
  134. contenteditable="true"
  135. class="input pinyin"
  136. v-html="answerList[indexs].pinyin"
  137. @change="changeAnswerList($event, indexs, 'pinyin')"
  138. ></div>
  139. <!--
  140. v-model="answerList[indexs].pinyin"
  141. -->
  142. <p
  143. class="pinyin"
  144. :class="[
  145. conent.pinyin.indexOf('__') > -1 ? 'pinyin-opacity' : '',
  146. ]"
  147. v-if="conent.pinyin"
  148. >
  149. {{ conent.pinyin }}
  150. </p>
  151. </template>
  152. <template v-if="conent.chs.indexOf('__') > -1">
  153. <!-- {{items.detail.resArr[conIndex].inputNumber}} -->
  154. <EditDiv
  155. class="input chs"
  156. v-model="
  157. curQue.Bookanswer[indexs].answerList[
  158. items.detail.resArr[conIndex].inputNumber
  159. ].chs
  160. "
  161. :canEdit="TaskModel == 'ANSWER' ? false : true"
  162. ></EditDiv>
  163. <!-- <el-input
  164. class="input chs"
  165. type="textarea"
  166. autosize
  167. placeholder="输入"
  168. v-model="curQue.Bookanswer[indexs].answerList[items.detail.resArr[conIndex].inputNumber].chs"
  169. :readonly="TaskModel=='ANSWER'"
  170. maxlength="200">
  171. </el-input> -->
  172. </template>
  173. <template v-else>
  174. <p class="chs">
  175. {{ conent.chs }}
  176. </p>
  177. </template>
  178. <template
  179. v-if="items.detail.pyPosition == 'bottom' && conent.pinyin"
  180. >
  181. <!-- <div
  182. v-if="conent.pinyin == '__'"
  183. contenteditable="true"
  184. class="input pinyin"
  185. v-html="answerList[indexs].pinyin"
  186. @change="changeAnswerList($event, indexs, 'pinyin')"
  187. ></div> -->
  188. <p
  189. class="pinyin"
  190. :class="[
  191. conent.pinyin.indexOf('__') > -1 ? 'pinyin-opacity' : '',
  192. ]"
  193. v-if="conent.pinyin"
  194. >
  195. {{ conent.pinyin }}
  196. </p>
  197. </template>
  198. </div>
  199. </div>
  200. </template>
  201. </div>
  202. <template
  203. v-if="
  204. dataType.indexOf('sentence_answer_chs') > -1 ||
  205. dataType.indexOf('sentence_input_chs') > -1
  206. "
  207. >
  208. <input
  209. @input="handleInput"
  210. :class="['item-input']"
  211. v-model="
  212. judgeAnswer == 'standardAnswer'
  213. ? items.answer[0]
  214. : curQue.Bookanswer[indexs].answer
  215. "
  216. placeholder="输入"
  217. @change="changeuserAnswerJudge(indexs)"
  218. />
  219. </template>
  220. <template v-if="dataType.indexOf('sentence_judge_chs') > -1">
  221. <div
  222. class="judge-box"
  223. :class="[TaskModel == 'ANSWER' ? 'notAllow' : '']"
  224. >
  225. <a
  226. :class="[
  227. 'right-btn',
  228. judgeAnswer == 'standardAnswer'
  229. ? items.judge
  230. ? 'active active-right-btn'
  231. : ''
  232. : curQue.Bookanswer[indexs].answer == 'right'
  233. ? 'active active-right-btn'
  234. : '',
  235. ]"
  236. @click="handleSelectJudge('right', indexs)"
  237. ></a>
  238. <a
  239. :class="[
  240. 'error-btn',
  241. judgeAnswer == 'standardAnswer'
  242. ? items.judge
  243. ? ''
  244. : 'active active-error-btn'
  245. : curQue.Bookanswer[indexs].answer == 'error'
  246. ? 'active active-error-btn'
  247. : '',
  248. ]"
  249. @click="handleSelectJudge('error', indexs)"
  250. ></a>
  251. </div>
  252. </template>
  253. <template v-if="dataType.indexOf('sentence_record_chs') > -1">
  254. <template v-if="dataType.indexOf('sentence_input_chs') != -1">
  255. <Soundrecord
  256. @handleWav="handleWav"
  257. :answerRecordList="curQue.Bookanswer[indexs].recordList"
  258. :tmIndex="indexs"
  259. :TaskModel="TaskModel"
  260. type="normal"
  261. v-if="items.IsRecord"
  262. :style="{ marginLeft: '8px' }"
  263. />
  264. </template>
  265. <template v-else>
  266. <Soundrecord
  267. @handleWav="handleWav"
  268. :answerRecordList="curQue.Bookanswer[indexs].recordList"
  269. :tmIndex="indexs"
  270. :TaskModel="TaskModel"
  271. type="mini"
  272. class="luyin-box"
  273. v-if="items.IsRecord"
  274. :style="{ marginLeft: '8px' }"
  275. />
  276. </template>
  277. </template>
  278. </li>
  279. </ul>
  280. </div>
  281. </template>
  282. <script>
  283. import Soundrecord from "../preview/Soundrecord.vue"; // 录音模板
  284. import EditDiv from "../preview/EditDiv.vue";
  285. export default {
  286. components: { Soundrecord, EditDiv },
  287. props: ["curQue", "TaskModel", "judgeAnswer"],
  288. data() {
  289. return {
  290. audio: new Audio(),
  291. oldsrc: "", // 存储播放音频的src 用来比对是否点击的是同一个音频
  292. palyClass: "",
  293. dataType: [], // 题型
  294. chsFhList: [",", "。", "“", ":", "》", "《", "?", "!", ";"],
  295. noFont: ["~", "!", "@", "#", "$", "%", "^", "&", "*", "(", ")"], // 对应不要拼音字体
  296. answerList: [],
  297. userErrList: [],
  298. };
  299. },
  300. computed: {},
  301. watch: {},
  302. //方法集合
  303. methods: {
  304. // 判断对错
  305. changeuserAnswerJudge(index) {
  306. if (this.dataType.indexOf("sentence_judge_chs") != -1) {
  307. // 判断题
  308. if (
  309. this.curQue.Bookanswer[index].answer == "right" &&
  310. this.curQue.option[index].judge
  311. ) {
  312. this.curQue.Bookanswer[index].userAnswerJudge = "[JUDGE##T##JUDGE]";
  313. } else {
  314. this.curQue.Bookanswer[index].userAnswerJudge = "[JUDGE##F##JUDGE]";
  315. }
  316. } else if (this.dataType.indexOf("sentence_input_chs") != -1) {
  317. // 填空题
  318. if (this.curQue.option[index].answer.length > 0) {
  319. let userAnswerJudge = "[JUDGE##F##JUDGE]";
  320. this.curQue.option[index].answer.forEach((item) => {
  321. if (this.curQue.Bookanswer[index].answer == item) {
  322. userAnswerJudge = "[JUDGE##T##JUDGE]";
  323. }
  324. });
  325. this.curQue.Bookanswer[index].userAnswerJudge = userAnswerJudge;
  326. }
  327. }
  328. },
  329. // input 输入时
  330. handleInput(e) {
  331. e.target.value = e.target.value ? e.target.value.trim() : "";
  332. },
  333. handlePlayVoice(url) {
  334. let _this = this;
  335. if (!url) {
  336. return;
  337. }
  338. if (!this.audio.paused && this.oldsrc == url) {
  339. this.audio.pause();
  340. } else if (this.audio.paused && this.oldsrc == url) {
  341. this.audio.play();
  342. } else {
  343. _this.audio.pause();
  344. _this.audio.load();
  345. _this.audio.src = url;
  346. _this.oldsrc = url;
  347. _this.audio.loop = false;
  348. _this.audio.play();
  349. }
  350. },
  351. // 处理数据
  352. handleData() {
  353. let _this = this;
  354. this.dataType = [];
  355. this.curQue.fn_list.forEach((item) => {
  356. if (item.isFn) {
  357. _this.dataType.push(item.type);
  358. }
  359. });
  360. if (!this.curQue.Bookanswer) {
  361. let answerList = [];
  362. let curCorrect = [];
  363. this.curQue.option.forEach((item) => {
  364. if (this.dataType.indexOf("sentence_input_chs") != -1) {
  365. answerList = [];
  366. item.answer.forEach((it) => {
  367. answerList.push({
  368. chs: "",
  369. pinyin: "",
  370. });
  371. });
  372. }
  373. let userAnswerJudge = "";
  374. if (this.dataType.indexOf("sentence_judge_chs") != -1) {
  375. // 判断题
  376. userAnswerJudge = "[JUDGE##F##JUDGE]";
  377. } else if (this.dataType.indexOf("sentence_input_chs") != -1) {
  378. userAnswerJudge = item.answer.length > 0 ? "[JUDGE##F##JUDGE]" : "";
  379. }
  380. curCorrect.push({
  381. answer: "",
  382. recordList: [],
  383. answerList: answerList,
  384. userAnswerJudge,
  385. });
  386. });
  387. this.$set(this.curQue, "Bookanswer", curCorrect);
  388. }
  389. let curQue = JSON.parse(JSON.stringify(this.curQue));
  390. curQue.option.forEach((dItem, dIndex) => {
  391. let paraArr = [];
  392. let inputNumber = 0;
  393. dItem.detail.wordsList.forEach((sItem, sIndex) => {
  394. this.mergeWordSymbol(dItem.detail.wordsList, sItem, sIndex);
  395. let obj = {
  396. pinyin: sItem.pinyin,
  397. chs: sItem.chs,
  398. isShow: sItem.isShow,
  399. inputNumber: sItem.chs.indexOf("__") > -1 ? inputNumber : "",
  400. };
  401. paraArr.push(obj);
  402. if (sItem.chs.indexOf("__") > -1) {
  403. inputNumber++;
  404. }
  405. });
  406. this.$set(_this.curQue.option[dIndex].detail, "resArr", paraArr);
  407. });
  408. console.log(_this.curQue.option);
  409. // 把错误的答案挑出来
  410. if (this.judgeAnswer == "standardAnswer") {
  411. this.userErrList = [];
  412. this.curQue.Bookanswer.forEach((item, i) => {
  413. if (item.userAnswerJudge == "[JUDGE##F##JUDGE]") {
  414. let obj = JSON.parse(JSON.stringify(this.curQue.option[i]));
  415. this.userErrList.push(obj);
  416. }
  417. });
  418. }
  419. },
  420. //词和标点合一起
  421. mergeWordSymbol(sItem, wItem, curIndex) {
  422. let leg = sItem.length;
  423. if (curIndex < leg - 1) {
  424. if (this.chsFhList.indexOf(wItem.chs) > -1) {
  425. wItem.isShow = false;
  426. } else {
  427. wItem.isShow = true;
  428. }
  429. }
  430. },
  431. // 判断题选择
  432. handleSelectJudge(obj, index) {
  433. if (!this.TaskModel || this.TaskModel != "ANSWER") {
  434. this.curQue.Bookanswer[index].answer = obj;
  435. }
  436. this.changeuserAnswerJudge(index);
  437. },
  438. handleWav(list, tmIndex) {
  439. tmIndex = tmIndex ? tmIndex : 0;
  440. this.$set(this.curQue.Bookanswer[tmIndex], "recordList", list);
  441. },
  442. handleDatas(str, type) {
  443. str = str.trim();
  444. str = str.replace(/_{2,}/g, "^ ");
  445. str =
  446. type == "hanzi" ? str.replace(/\s+/g, "") : str.replace(/\s+/g, " ");
  447. let resArr = type == "hanzi" ? str.split("") : str.split(/\s+/);
  448. return resArr;
  449. },
  450. changeAnswerList(e, index, type, indexs) {
  451. if (type == "pinyin") {
  452. this.curQue.Bookanswer[index].answerList[indexs].pinyin +=
  453. e.target.innerHTML;
  454. } else {
  455. this.curQue.Bookanswer[index].answerList[indexs].chs +=
  456. e.target.innerHTML;
  457. }
  458. },
  459. handleFalse() {
  460. return false;
  461. },
  462. },
  463. //生命周期 - 创建完成(可以访问当前this实例)
  464. created() {
  465. this.handleData();
  466. },
  467. //生命周期 - 挂载完成(可以访问DOM元素)
  468. mounted() {
  469. let _this = this;
  470. _this.audio.addEventListener("play", function () {
  471. _this.palyClass = "active";
  472. });
  473. _this.audio.addEventListener("pause", function () {
  474. _this.palyClass = "";
  475. });
  476. _this.audio.addEventListener("ended", function () {
  477. _this.palyClass = "";
  478. });
  479. },
  480. beforeCreate() {}, //生命周期 - 创建之前
  481. beforeMount() {}, //生命周期 - 挂载之前
  482. beforeUpdate() {}, //生命周期 - 更新之前
  483. updated() {}, //生命周期 - 更新之后
  484. beforeDestroy() {}, //生命周期 - 销毁之前
  485. destroyed() {}, //生命周期 - 销毁完成
  486. activated() {}, //如果页面有keep-alive缓存功能,这个函数会触发
  487. };
  488. </script>
  489. <style lang='scss' scoped>
  490. //@import url(); 引入公共css类
  491. .error {
  492. .active-right-btn {
  493. background: #fff url("../../../assets/newImage/common/error-right-btn.png")
  494. center no-repeat !important;
  495. background-size: 24px !important;
  496. }
  497. .active {
  498. background-color: #ffe5e5 !important;
  499. border-color: #de4444 !important;
  500. }
  501. input {
  502. color: #ed342d !important;
  503. }
  504. }
  505. .correct {
  506. .active-error-btn {
  507. background: #fff
  508. url("../../../assets/newImage/common/correct-error-btn.png") center
  509. no-repeat !important;
  510. background-size: 24px !important;
  511. }
  512. .active {
  513. background-color: #e5fff0 !important;
  514. border-color: #00c850 !important;
  515. }
  516. input {
  517. color: #2ca767 !important;
  518. }
  519. }
  520. .Big-Book-prev-Textdes {
  521. width: 100%;
  522. h2 {
  523. font-weight: normal;
  524. font-size: 16px;
  525. line-height: 150%;
  526. color: #000000;
  527. margin: 0 2px 8px 2px;
  528. }
  529. ul {
  530. display: flex;
  531. flex-flow: wrap;
  532. justify-content: start;
  533. list-style: none;
  534. li {
  535. width: 100%;
  536. background: #ffffff;
  537. border: 1px solid rgba(0, 0, 0, 0.1);
  538. box-sizing: border-box;
  539. border-radius: 8px;
  540. display: flex;
  541. align-items: center;
  542. padding: 8px 12px;
  543. margin-bottom: 8px;
  544. > b {
  545. width: 24px;
  546. line-height: 24px;
  547. font-size: 16px;
  548. text-align: center;
  549. margin-right: 8px;
  550. font-weight: 400;
  551. color: rgba(0, 0, 0, 1);
  552. // margin-top: 4px;
  553. font-family: "FZJCGFKTK";
  554. border-radius: 50%;
  555. }
  556. > p {
  557. width: 16px;
  558. height: 16px;
  559. cursor: pointer;
  560. background: url("../../../assets/NPC/play-red.png") left center
  561. no-repeat;
  562. background-size: 16px;
  563. margin: 0px 8px 0 0;
  564. &.active {
  565. background: url("../../../assets/NPC/icon-voice-play-red.png") left
  566. center no-repeat;
  567. background-size: 16px;
  568. }
  569. }
  570. .item-content {
  571. flex: 1;
  572. .chs_pinyin {
  573. display: flex;
  574. flex-flow: wrap;
  575. align-items: flex-end;
  576. .input {
  577. // margin-left: 16px;
  578. margin-right: 8px;
  579. min-width: 50px;
  580. border-bottom: 1px solid black;
  581. min-height: 28px;
  582. height: auto;
  583. }
  584. .pinyin {
  585. font-family: "GB-PINYINOK-B";
  586. font-size: 14px;
  587. line-height: 130%;
  588. color: rgba(0, 0, 0, 0.6);
  589. margin-top: 8px;
  590. &-opacity {
  591. opacity: 0;
  592. }
  593. }
  594. .chs {
  595. font-family: "FZJCGFKTK";
  596. font-style: normal;
  597. font-weight: normal;
  598. font-size: 20px;
  599. line-height: 150%;
  600. color: #000000;
  601. }
  602. p {
  603. margin: 0;
  604. }
  605. }
  606. .content-con {
  607. font-size: 20px;
  608. line-height: 150%;
  609. color: #000000;
  610. font-family: "FZJCGFKTK";
  611. margin: 0;
  612. &.content-con-small {
  613. font-size: 16px;
  614. }
  615. }
  616. .content-en {
  617. font-weight: normal;
  618. font-size: 16px;
  619. line-height: 150%;
  620. color: #000000;
  621. font-family: "robot";
  622. }
  623. .con-box {
  624. display: flex;
  625. flex-flow: wrap;
  626. .con-item {
  627. text-align: center;
  628. padding: 0 3px;
  629. &.con-item-0 {
  630. text-align: left;
  631. padding-left: 0;
  632. }
  633. }
  634. span {
  635. display: block;
  636. }
  637. .pinyin {
  638. font-family: "GB-PINYINOK-B";
  639. font-size: 14px;
  640. line-height: 130%;
  641. color: #000000;
  642. height: 18px;
  643. &.noFont {
  644. font-family: initial;
  645. }
  646. }
  647. .synthesis-box {
  648. display: flex;
  649. }
  650. }
  651. }
  652. input {
  653. width: 68px;
  654. border: 1px solid rgba(0, 0, 0, 0.15);
  655. box-sizing: border-box;
  656. border-radius: 4px;
  657. outline: none;
  658. height: 32px;
  659. padding: 4px 8px;
  660. color: #000000;
  661. text-align: center;
  662. font-size: 16px;
  663. line-height: 150%;
  664. }
  665. .judge-box {
  666. display: flex;
  667. justify-content: center;
  668. &.notAllow {
  669. a,
  670. a.error-btn {
  671. cursor: not-allowed;
  672. }
  673. }
  674. a {
  675. width: 32px;
  676. height: 32px;
  677. background: #fff url("../../../assets/newImage/common/right-btn.png")
  678. center no-repeat;
  679. background-size: 24px;
  680. border-radius: 8px;
  681. border: 1px solid rgba(0, 0, 0, 0.1);
  682. &:hover,
  683. &.active {
  684. background-color: #e5fff0;
  685. border-color: #00c850;
  686. }
  687. }
  688. a.error-btn {
  689. background: #fff url("../../../assets/newImage/common/error-btn.png")
  690. center no-repeat;
  691. background-size: 24px;
  692. margin-left: 4px;
  693. &:hover,
  694. &.active {
  695. background-color: #ffe5e5;
  696. border-color: #de4444;
  697. }
  698. }
  699. }
  700. .luyin-box {
  701. border: 1px solid rgba(0, 0, 0, 0.1);
  702. border-radius: 8px;
  703. width: 64px;
  704. }
  705. }
  706. }
  707. }
  708. .NPC-Big-Book-preview-green {
  709. .Big-Book-prev-Textdes {
  710. ul {
  711. li {
  712. > p {
  713. background: url("../../../assets/NPC/play-green.png") center no-repeat;
  714. background-size: cover;
  715. &.active {
  716. background-image: url("../../../assets/NPC/icon-voice-play-green.png");
  717. background-size: cover;
  718. }
  719. }
  720. }
  721. }
  722. }
  723. }
  724. .NPC-Big-Book-preview-brown {
  725. .Big-Book-prev-Textdes {
  726. ul {
  727. li {
  728. > p {
  729. background: url("../../../assets/NPC/play-brown.png") center no-repeat;
  730. background-size: cover;
  731. &.active {
  732. background-image: url("../../../assets/NPC/icon-voice-play-brown.png");
  733. background-size: cover;
  734. }
  735. }
  736. }
  737. }
  738. }
  739. }
  740. </style>