From 1687ecf6414f977f9115cc1e53987ef6b6dbae6b Mon Sep 17 00:00:00 2001
From: litian <2804272236@qq.com>
Date: 星期三, 15 五月 2024 23:33:50 +0800
Subject: [PATCH] 123

---
 src/assets/main.css |   18 ++++++++++++++++++
 src/views/home.vue  |   31 +++++++++++++++++++++++--------
 2 files changed, 41 insertions(+), 8 deletions(-)

diff --git a/src/assets/main.css b/src/assets/main.css
index b3ac53f..cb765cf 100644
--- a/src/assets/main.css
+++ b/src/assets/main.css
@@ -237,3 +237,21 @@
 .temp-book .page-padding .highLight:hover {
   border: 1px dashed #949494 !important;
 }
+.custom-tree-node{
+  flex:1;
+  display: flex;
+  align-items: center;
+  justify-content: space-between;
+  padding-right: 8px;
+}
+.catalogueLabel{
+  width:200px;
+  display: -webkit-box;
+  -webkit-box-orient: vertical;
+  -webkit-line-clamp: 1;
+  overflow: hidden;
+}
+.pageNum{
+  float: right;
+  color:#707070;
+}
\ No newline at end of file
diff --git a/src/views/home.vue b/src/views/home.vue
index 99ecf54..6ca5fd0 100644
--- a/src/views/home.vue
+++ b/src/views/home.vue
@@ -126,7 +126,14 @@
             v-if="catalogueData.length > 0"
             @node-click="handleNodeClick"
             :filter-node-method="filterNode"
-          />
+          >
+            <template #default="{ node, data }">
+              <div class="custom-tree-node">
+                <div class="catalogueLabel">{{ node.label }}</div>
+                <span class="pageNum">{{ data.page }}</span>
+              </div>
+            </template>
+          </el-tree>
           <div v-if="catalogueData.length == 0">
             <el-empty :image-size="60" description="鏆傛棤鏁版嵁" />
           </div>
@@ -794,7 +801,7 @@
   </el-dialog>
   <el-dialog title="鐧惧害鐧剧" align-center v-model="baiduVisible" width="60%" class="myDialogs">
     <div class="wendabox">
-      <iframe :src="'https://baike.baidu.com/item/' + selectText" frameborder="0"></iframe>
+      <iframe :src="'https://baike.baidu.com/item/' + dialogToolData.txt" frameborder="0"></iframe>
     </div>
   </el-dialog>
   <el-dialog title="AI鏅鸿兘闂瓟" align-center v-model="wendaVisible" width="26%" class="myDialogs">
@@ -805,7 +812,7 @@
   <el-dialog title="璇嶅吀" align-center v-model="cidianVisible" width="60%" class="myDialogs">
     <div class="wendabox">
       <!-- <iframe src="https://www.vocabulary.com/" frameborder="0"></iframe> -->
-      <dictionary :searchCon="selectText" />
+      <dictionary :searchCon="dialogToolData.txt" />
     </div>
   </el-dialog>
   <el-dialog
@@ -996,6 +1003,7 @@
         getSelection(data)
       } else {
         showToolBox.value = false
+        toolActive = ''
       }
     },
     catalogChange: (data) => {
@@ -1033,7 +1041,7 @@
     // getNotesList() // 鑾峰彇绗旇
     // getlineHeightList() //鑾峰彇楂樹寒
     // getScribeList() //鑾峰彇鍒掔嚎
-    // getScreenshotList() //鎴浘
+    getScreenshotList() //鎴浘
   }
 )
 //鑾峰彇鐩綍
@@ -1053,7 +1061,8 @@
 }
 const defaultProps = {
   children: 'children',
-  label: 'label'
+  label: 'label',
+  page: 'page',
 }
 const filterNode = (value, data) => {
   if (!value) return true
@@ -1759,7 +1768,7 @@
   { icon: fuzhi, activeIcon: fuzhi1, name: '澶嶅埗' },
   { icon: AIyuedu, activeIcon: AIyuedu1, name: 'AI闃呰' },
   { icon: cidian2, activeIcon: cidian1, name: '璇嶅吀' },
-  { icon: baidu, activeIcon: cidian1, name: '鐧剧' }
+  { icon: baidu, activeIcon: baidu, name: '鐧剧' }
   // { icon: yuyinyuedu, activeIcon: yuyinyuedu1, name: '璇煶闃呰' }
   // { icon: cidian2, activeIcon: cidian1, name: '缈昏瘧' }
 ])
@@ -1908,6 +1917,7 @@
       cidianVisible.value = true
       break
     case '鐧剧':
+      console.log('https://baike.baidu.com/item/' + dialogToolData.txt)
       baiduVisible.value = true
       break
   }
@@ -2094,6 +2104,8 @@
     lineDelete.showLineDelete = true
     lineDelete.deleteType = type
     lineDelete.id = id
+    lineDelete.top = 500
+    lineDelete.left = 500
   }
 }
 
@@ -2409,7 +2421,7 @@
         align-items: center;
       }
       .resourceBox {
-        padding: 15px 0;
+        padding: 10px 0;
         margin: 0 20px;
         border-bottom: 1px solid rgba(204, 204, 204, 0.32);
         .classification {
@@ -2426,7 +2438,8 @@
           }
           .count {
             width: 35px;
-            margin: 5px auto;
+            margin: 0 auto;
+            margin-top:5px;
             border-radius: 10px;
             background: #fff;
             color: #c8c8c8;
@@ -2456,6 +2469,7 @@
         }
         .inputBox {
           margin-top: 10px;
+          width:100% !important;
         }
       }
       .resourceTab {
@@ -2489,6 +2503,7 @@
         }
       }
       .inputBox {
+        width:85%;
         .custom-input {
           border: 1px solid #0093ff !important;
           border-radius: 50px;

--
Gitblit v1.9.1