From e900c6b30a1ad94b39c431988284fd7b997f4fa8 Mon Sep 17 00:00:00 2001
From: zhongshujie <2862698242@qq.com>
Date: 星期五, 13 十二月 2024 18:53:11 +0800
Subject: [PATCH] 样式问题调整

---
 packageBookService/pages/psychologyAnswer/testdata/index.js          |    6 +++---
 packageBookService/pages/psychologyAnswer/questionList/index.js      |   17 ++++++++++++++++-
 packageBookService/pages/psychologyAnswer/questionList/index.wxss    |    3 ++-
 packageBookService/pages/psychologyAnswer/questionOptions/index.wxml |    3 ++-
 packageBookService/pages/psychologyAnswer/questionList/index.wxml    |    4 +++-
 5 files changed, 26 insertions(+), 7 deletions(-)

diff --git a/packageBookService/pages/psychologyAnswer/questionList/index.js b/packageBookService/pages/psychologyAnswer/questionList/index.js
index 50596c2..95e115a 100644
--- a/packageBookService/pages/psychologyAnswer/questionList/index.js
+++ b/packageBookService/pages/psychologyAnswer/questionList/index.js
@@ -62,8 +62,23 @@
       type: 'fraction'
     },
     showIndex: 0,
-    isPlay: false
+    isPlay: false,
+    height: 0
   },
+
+  ready() {
+    const query = wx.createSelectorQuery().in(this);
+    query.select('#question-title').boundingClientRect((rect) => {
+      this.setData({
+        height: 'calc(100% - 30px - ' + rect.height + 'px)'
+      })
+    }).exec();
+
+
+  },
+
+
+
   /**
    * 缁勪欢鐨勬柟娉曞垪琛�
    */
diff --git a/packageBookService/pages/psychologyAnswer/questionList/index.wxml b/packageBookService/pages/psychologyAnswer/questionList/index.wxml
index 79043cd..ef84962 100644
--- a/packageBookService/pages/psychologyAnswer/questionList/index.wxml
+++ b/packageBookService/pages/psychologyAnswer/questionList/index.wxml
@@ -4,7 +4,7 @@
   style="background-color:{{isNight ? '#222' : '#fff'}}"
 >
   <!-- 绛旈鎻愮ずtitle -->
-  <view class="question-title" wx:if="{{questionTitle}}">
+  <view id="question-title" class="question-title" wx:if="{{questionTitle}}">
     <rich-text
       class="substance"
       nodes="{{questionTitle}}"
@@ -13,9 +13,11 @@
   </view>
   <!-- 棰樼洰鍒楄〃 -->
   <swiper
+    id="swiper"
     class="swiper"
     bindanimationfinish="changeSwiper"
     current="{{currentIndex}}"
+    style="{{'height:'+height}}"
   >
     <swiper-item
       wx:for="{{questionList}}"
diff --git a/packageBookService/pages/psychologyAnswer/questionList/index.wxss b/packageBookService/pages/psychologyAnswer/questionList/index.wxss
index 838fe15..de3aae6 100644
--- a/packageBookService/pages/psychologyAnswer/questionList/index.wxss
+++ b/packageBookService/pages/psychologyAnswer/questionList/index.wxss
@@ -36,7 +36,8 @@
 }
 
 .swiper {
-  height: 85%;
+  /* height: 85%; */
+  height: calc(100% - 30px - 294px)
 }
 
 /* 鍗曢�夐 */
diff --git a/packageBookService/pages/psychologyAnswer/questionOptions/index.wxml b/packageBookService/pages/psychologyAnswer/questionOptions/index.wxml
index 1dc54f0..2881232 100644
--- a/packageBookService/pages/psychologyAnswer/questionOptions/index.wxml
+++ b/packageBookService/pages/psychologyAnswer/questionOptions/index.wxml
@@ -169,7 +169,8 @@
     <view class="report-content-top">
       <scroll-view scroll-y style="height: 30vh; overflow-y: auto">
         <view class="report-li">
-          <view class="report-li-left">棰樼洰鎬绘暟锛�</view>
+          <view class="report-li-left" style="white-space: nowrap"
+            >棰樼洰鎬绘暟锛�</view>
           <view class="report-li-right">{{questionDataList.length}}閬�</view>
         </view>
         <view
diff --git a/packageBookService/pages/psychologyAnswer/testdata/index.js b/packageBookService/pages/psychologyAnswer/testdata/index.js
index 9324f4a..91603c3 100644
--- a/packageBookService/pages/psychologyAnswer/testdata/index.js
+++ b/packageBookService/pages/psychologyAnswer/testdata/index.js
@@ -286,7 +286,7 @@
         },
         {
           "analysisCon": "鐣�",
-          "id": "0C85D545",
+          "id": "0C85D601",
           "optionIndex": 0,
           "optionStyle": "Txt",
           "questionType": "judge",
@@ -298,7 +298,7 @@
         },
         {
           "analysisCon": "鐣�",
-          "id": "0C85D545",
+          "id": "0C85D602",
           "optionIndex": 0,
           "optionStyle": "Txt",
           "questionType": "judge",
@@ -310,7 +310,7 @@
         },
         {
           "analysisCon": "鐣�",
-          "id": "0C85D545",
+          "id": "0C85D603",
           "optionIndex": 0,
           "optionStyle": "Txt",
           "questionType": "judge",

--
Gitblit v1.9.1