ソースを参照

文章取词 去掉标点取词

natasha 2 年 前
コミット
8a9500f2e7

+ 0 - 7
src/components/Adult/preview/DialogueArticleViewChs/NormalModelChs.vue

@@ -237,13 +237,6 @@
                             class="NNPE-chs"
                             style="text-align: left"
                             :class="[
-                              isPlaying &&
-                              item.timeList &&
-                              item.timeList[pItem.sentIndex] &&
-                              curTime >= item.timeList[pItem.sentIndex].bg &&
-                              curTime <= item.timeList[pItem.sentIndex].ed
-                                ? 'active'
-                                : '',
                               pItem.chstimeList &&
                               pItem.chstimeList[pItem.leg - 1] &&
                               curTime >=

+ 9 - 11
src/components/Adult/preview/DialogueArticleViewChs/WordModelChs.vue

@@ -79,7 +79,6 @@
                       : 'textCenter',
                     pItem.chs == '“' ? 'textRight' : '',
                   ]"
-                  @click="showWordDetail($event, pItem)"
                 >
                   <template v-if="!pItem.width">
                     <template v-if="pItem.isShow">
@@ -91,7 +90,7 @@
                           item.wordsList[pIndex + 1].chs &&item.wordsList[pIndex + 1].chs== '#'
                         "
                       >
-                        <span class="NNPE-words-box">
+                        <span class="NNPE-words-box" @click="showWordDetail($event, pItem)">
                           <span
                             v-if="curQue.pyPosition == 'top' && config.isShowPY && item.dhaspinyin"
                             class="NNPE-pinyin"
@@ -99,7 +98,6 @@
                               pItem.className ? pItem.className : '',
                               noFont.indexOf(item.pinyin) > -1 ? 'noFont' : '',
                             ]"
-                            @click.stop="viewNotes($event, pItem.pinyin)"
                             >{{ pItem.pinyin }}</span
                           >
                           <span
@@ -123,11 +121,10 @@
                               pItem.className ? pItem.className : '',
                               noFont.indexOf(item.pinyin) > -1 ? 'noFont' : '',
                             ]"
-                            @click.stop="viewNotes($event, pItem.pinyin)"
                             >{{ pItem.pinyin }}</span
                           >
                         </span>
-                        <span class="NNPE-words-box">
+                        <span class="NNPE-words-box" @click="showWordDetail($event, item.wordsList[pIndex + 1])">
                           <span
                             v-if="curQue.pyPosition == 'top' && config.isShowPY && item.dhaspinyin"
                             class="NNPE-pinyin"
@@ -138,7 +135,6 @@
                                 ? 'noFont'
                                 : '',
                             ]"
-                            @click.stop="viewNotes($event, item.wordsList[pIndex + 1].pinyin)"
                             style="text-align: left"
                             >{{ item.wordsList[pIndex + 1].pinyin }}</span
                           >
@@ -157,7 +153,6 @@
                                 ? 'noFont'
                                 : '',
                             ]"
-                            @click.stop="viewNotes($event, item.wordsList[pIndex + 1].pinyin)"
                             style="text-align: left"
                             >{{ item.wordsList[pIndex + 1].pinyin }}</span
                           >
@@ -170,6 +165,7 @@
                             chsFhList.indexOf(item.wordsList[pIndex + 2].chs) >
                               -1
                           "
+                          @click="showWordDetail($event, item.wordsList[pIndex + 2])"
                         >
                           <span
                             v-if="curQue.pyPosition == 'top' && config.isShowPY && item.dhaspinyin"
@@ -181,7 +177,6 @@
                                 ? 'noFont'
                                 : '',
                             ]"
-                            @click.stop="viewNotes($event, item.wordsList[pIndex + 2].pinyin)"
                             style="text-align: left"
                             >{{ item.wordsList[pIndex + 2].pinyin }}</span
                           >
@@ -216,7 +211,6 @@
                                 ? 'noFont'
                                 : '',
                             ]"
-                            @click.stop="viewNotes($event, item.wordsList[pIndex + 2].pinyin)"
                             style="text-align: left"
                             >{{ item.wordsList[pIndex + 2].pinyin }}</span
                           >
@@ -231,7 +225,7 @@
                             pItem.className ? pItem.className : '',
                             noFont.indexOf(item.pinyin) > -1 ? 'noFont' : '',
                           ]"
-                          @click.stop="viewNotes($event, pItem.pinyin)"
+                          @click="showWordDetail($event, pItem)"
                           >{{ pItem.pinyin }}</span
                         >
                         <span
@@ -245,6 +239,7 @@
                               ? 'wordActive'
                               : '',
                           ]"
+                          @click="showWordDetail($event, pItem)"
                           >{{ NumberList.indexOf(pItem.pinyin)==-1 ? pItem.chs : '' }}</span
                         >
                         <span
@@ -257,7 +252,7 @@
                             pItem.className ? pItem.className : '',
                             noFont.indexOf(item.pinyin) > -1 ? 'noFont' : '',
                           ]"
-                          @click.stop="viewNotes($event, pItem.pinyin)"
+                          @click="showWordDetail($event, pItem)"
                           >{{ pItem.pinyin }}</span
                         >
                       </template>
@@ -623,6 +618,9 @@ export default {
     },
     showWordDetail(e, item) {
       let _this = this;
+      if(this.chsFhList.indexOf(item.chs) > -1||item.chs=='“'||item.chs=='('){
+          return false
+      }
       if (_this.oldHz != item.chs) {
         this.isShow = false;
         setTimeout(() => {

+ 0 - 1
src/components/Adult/preview/DialogueArticleViewChs/index.vue

@@ -278,7 +278,6 @@ export default {
   created() {
     let data = JSON.parse(getToken());
     this.tokenData = data;
-    console.log('2022-10-20')
   },
   //生命周期 - 挂载完成(可以访问DOM元素)
   mounted() {