Ver Fonte

语料库

natasha há 2 anos atrás
pai
commit
fcb427cf88
1 ficheiros alterados com 254 adições e 46 exclusões
  1. 254 46
      src/views/corpus/Result.vue

+ 254 - 46
src/views/corpus/Result.vue

@@ -4,9 +4,6 @@
     <div class="main">
       <div
         class="hanzi_list"
-        :style="{
-          overflowY: unfold ? 'scroll' : 'hidden',
-        }"
       >
         <div class="top_jf">
           <div class="j_f">
@@ -18,44 +15,48 @@
             </div>
           </div>
         </div>
-        <div
-          class="list_one"
-          v-for="(item, index) in ShowHzData"
-          :key="'index' + index"
-        >
-          <Strockplayredline
-            v-if="item.hzDetail.hz_json"
-            :Book_text="JFIndex == 0 ? item.con : item.fanti"
-            :playStorkes="true"
-            :curItem="item.hzDetail"
-            :targetDiv="'bwcHanziIntp' + index + item.con"
-            :isHighlight="false"
-            :judgeAnswer="2"
-          />
-          <div class="Highlight" v-if="item.hzDetail.hz_json">
-            <div class="play_audio">
-              <img src="../../assets/teacherdev/speaker-one.png" alt="" />
-              <span>{{ item.pinyin }}</span>
-            </div>
+        <div class="list_one_box"
+            :style="{
+                overflowY: unfold ? 'scroll' : 'hidden',
+            }">
             <div
-              v-for="(items, indexs) in item.hzDetail.hz_json.medians.length"
-              :key="'row' + indexs"
-              class="row"
+            class="list_one"
+            v-for="(item, index) in ShowHzData"
+            :key="'index' + index"
             >
-              <Strockplayredline
+            <Strockplayredline
+                v-if="item.hzDetail.hz_json"
                 :Book_text="JFIndex == 0 ? item.con : item.fanti"
-                :playStorkes="false"
+                :playStorkes="true"
                 :curItem="item.hzDetail"
-                :targetDiv="'bwcHanziIntp_height' + index + item.con + indexs"
-                :isHighlight="true"
-                :judgeAnswer="indexs + 1"
-              />
-              <div class="number">{{ indexs + 1 }}</div>
+                :targetDiv="'bwcHanziIntp' + index + item.con"
+                :isHighlight="false"
+                :judgeAnswer="2"
+            />
+            <div class="Highlight" v-if="item.hzDetail.hz_json">
+                <div class="play_audio">
+                <img src="../../assets/teacherdev/speaker-one.png" alt="" />
+                <span>{{ item.pinyin }}</span>
+                </div>
+                <div
+                v-for="(items, indexs) in item.hzDetail.hz_json.medians.length"
+                :key="'row' + indexs"
+                class="row"
+                >
+                <Strockplayredline
+                    :Book_text="JFIndex == 0 ? item.con : item.fanti"
+                    :playStorkes="false"
+                    :curItem="item.hzDetail"
+                    :targetDiv="'bwcHanziIntp_height' + index + item.con + indexs"
+                    :isHighlight="true"
+                    :judgeAnswer="indexs + 1"
+                />
+                <div class="number">{{ indexs + 1 }}</div>
+                </div>
+            </div>
             </div>
-          </div>
         </div>
-
-        <div class="shouqi">
+        <div class="shouqi" v-if="hzData.length>2">
           <span @click="updownHz">
             <template v-if="unfold">
               <img src="../../assets/teacherdev/up.png" alt="" />
@@ -250,13 +251,14 @@
               </template>
             </div>
             <div class="page">
-              <span class="text"> 共 条 命中 次 </span>
+              <span class="text"> 共 196 条 命中 213 次 </span>
               <el-pagination
                 background
                 @current-change="handleCurrentChange"
                 :current-page.sync="page"
                 layout="prev, pager, next"
                 :total="1000"
+                :pager-count="6"
               >
               </el-pagination>
             </div>
@@ -304,7 +306,7 @@
             <div class="one all">
               <div>
                 <span></span>
-                <span>全部</span>
+                <span>合计</span>
               </div>
               <div>
                 <span>{{ allNumber }}</span>
@@ -358,12 +360,22 @@ export default {
       rightList: [
         {
           name: "good",
-          value: "10",
-          ratio: "0.1",
+          value: "4",
+          ratio: "0.4",
         },
         {
           name: "OK",
-          value: "10",
+          value: "3",
+          ratio: "0.3",
+        },
+        {
+          name: "nice",
+          value: "2",
+          ratio: "0.2",
+        },
+        {
+          name: "yes",
+          value: "1",
           ratio: "0.1",
         },
       ],
@@ -398,6 +410,174 @@ export default {
           shiyi: "good, ok",
           laiyuan: "《轻松学中文1》  Unit 1  课文一  P16",
         },
+        {
+          number: 2,
+          mp3: "",
+          wordsList: [
+            {
+              pinyin: "wǒ",
+              con: "我",
+            },
+            {
+              pinyin: "hěn",
+              con: "很",
+            },
+            {
+              pinyin: "hǎo",
+              con: "好",
+            },
+            {
+              pinyin: "",
+              con: "。",
+            },
+          ],
+          shiyi: "good, ok",
+          laiyuan: "《轻松学中文1》  Unit 1  课文一  P16",
+        },
+        {
+          number: 3,
+          mp3: "",
+          wordsList: [
+            {
+              pinyin: "jīn",
+              con: "今",
+            },
+            {
+              pinyin: "tiān",
+              con: "天",
+            },
+            {
+              pinyin: "hǎo",
+              con: "一",
+            },
+            {
+              pinyin: "ma",
+              con: "起",
+            },
+            {
+              pinyin: "",
+              con: "去",
+            },
+            {
+              pinyin: "dà",
+              con: "看",
+            },
+            {
+              pinyin: "wéi",
+              con: "电",
+            },
+            {
+              pinyin: "hǎo",
+              con: "影",
+            },
+            {
+              pinyin: "ma",
+              con: "好",
+            },
+            {
+              pinyin: "",
+              con: "吗",
+            },
+            {
+              pinyin: "",
+              con: "?",
+            },
+          ],
+          shiyi: "good, ok",
+          laiyuan: "《轻松学中文1》  Unit 1  课文一  P16",
+        },
+        {
+          number: 4,
+          mp3: "",
+          wordsList: [
+            {
+              pinyin: "dà",
+              con: "这",
+            },
+            {
+              pinyin: "wéi",
+              con: "里",
+            },
+            {
+              pinyin: "hǎo",
+              con: "已",
+            },
+            {
+              pinyin: "ma",
+              con: "经",
+            },
+            {
+              pinyin: "",
+              con: "很",
+            },
+            {
+              pinyin: "dà",
+              con: "久",
+            },
+            {
+              pinyin: "wéi",
+              con: "很",
+            },
+            {
+              pinyin: "hǎo",
+              con: "久",
+            },
+            {
+              pinyin: "",
+              con: "很",
+            },
+            {
+              pinyin: "dà",
+              con: "久",
+            },
+            {
+              pinyin: "wéi",
+              con: "没",
+            },
+            {
+              pinyin: "hǎo",
+              con: "有",
+            },
+            {
+              pinyin: "ma",
+              con: "过",
+            },
+            {
+              pinyin: "",
+              con: "这",
+            },
+            {
+              pinyin: "dà",
+              con: "么",
+            },
+            {
+              pinyin: "wéi",
+              con: "好",
+            },
+            {
+              pinyin: "hǎo",
+              con: "的",
+            },
+            {
+              pinyin: "ma",
+              con: "天",
+            },
+            {
+              pinyin: "",
+              con: "气",
+            },
+            {
+              pinyin: "ma",
+              con: "了",
+            },
+            {
+              pinyin: "",
+              con: "。",
+            },
+          ],
+          shiyi: "good, ok",
+          laiyuan: "《轻松学中文1》  Unit 1  课文一  P16",
+        },
       ],
       KWICData: [
         {
@@ -580,6 +760,9 @@ export default {
       this.hzData = [];
       let arr = this.$route.query.keyword.split("");
       arr.forEach((item) => {
+        if(!/^[\u4e00-\u9fa5]/.test(item)){
+            return
+        }
         let result = pinyinUtil.getPinyin(item);
         let obj = {
           con: item,
@@ -631,12 +814,13 @@ export default {
     padding-bottom: 66px;
   }
   .hanzi_list {
-    width: 1120px;
-    max-height: 858px;
+    width: 1200px;
     margin: 0 auto;
     background: #ffffff;
     border-radius: 8px;
-    padding: 40px;
+    padding: 40px 13px;
+    position: relative;
+    box-sizing: border-box;
     .top_jf {
       width: 128px;
     }
@@ -672,6 +856,22 @@ export default {
         background: #de4444;
       }
     }
+    .list_one_box{ 
+        max-height: 750px;
+        padding: 0 27px;
+        &::-webkit-scrollbar-track-piece {
+            background: #fff;
+        }
+
+        &::-webkit-scrollbar {
+            width: 4px;
+        }
+
+        &::-webkit-scrollbar-thumb {
+            background: #D9D9D9;
+            border-radius: 20px;
+        }
+    }
     .list_one {
       margin-bottom: 20px;
       display: flex;
@@ -718,10 +918,17 @@ export default {
       margin-top: 21;
       display: flex;
       justify-content: flex-end;
+      position: absolute;
+      right: 26px;
+      bottom: 13px;
       span {
         cursor: pointer;
         display: flex;
         align-items: center;
+        font-size: 16px;
+        line-height: 24px;
+        font-weight: 400;
+        color: rgba(0, 0, 0, 0.5);
       }
       img {
         width: 24px;
@@ -857,7 +1064,7 @@ export default {
         }
       }
       .main {
-        height: 95%;
+        // height: 95%;
         .list {
           margin-top: 16px;
           .one {
@@ -969,12 +1176,13 @@ export default {
           }
         }
         .page {
-          padding: 0 24px 0 12px;
-          width: 93%;
+          padding: 0 10px 0 12px;
+          width: 562px;
           position: absolute;
           bottom: 16px;
           display: flex;
           justify-content: space-between;
+          box-sizing: border-box;
           .text {
             font-weight: 400;
             font-size: 14px;