From 0e6467836bbd3fcd85d1cfaefcf763e58c9149be Mon Sep 17 00:00:00 2001 From: 闫增涛 <1829501689@qq.com> Date: 星期四, 04 七月 2024 15:36:48 +0800 Subject: [PATCH] Merge branch 'master' of http://182.92.203.7:2001/r/testbookLayout --- src/books/artAndDrama/view/components/chapter002.vue | 12 +++++++++--- 1 files changed, 9 insertions(+), 3 deletions(-) diff --git a/src/books/artAndDrama/view/components/chapter002.vue b/src/books/artAndDrama/view/components/chapter002.vue index 515195d..8c0f6b2 100644 --- a/src/books/artAndDrama/view/components/chapter002.vue +++ b/src/books/artAndDrama/view/components/chapter002.vue @@ -115,13 +115,12 @@ <p class="text">甯歌█閬擄細鑹█涓�鍙ヤ笁鍐殩锛屾伓璇激浜哄叚鏈堝瘨銆傝瑷�鍦ㄤ汉涓庝汉鐨勪氦寰�涓捣鐫�閲嶈鐨勪綔鐢紝鏈夌潃鏃犵┓鐨勫姏閲忋��</p> <p class="text t-l" ><span class="hs1">鈼�</span>濡傛灉鏈嬪弸蹇冩儏涓嶅ソ锛屼綘璇ユ�庝箞瀹夋叞浠�/濂瑰憿锛� <textarea v-model="questionData.reading.one" placeholder="璇疯緭鍏ュ唴瀹�" rows="6" - style="margin-left: 40px; width: 92%" class="fz-16 fm-son" @change="setBookQuestion"></textarea> + style="margin-left: 40px; width: 92%" class="" @change="setBookQuestion" :class="{ 'textarea-focused': isFocused === 'one' }" @focus="handleFocus('one')" @blur="handleBlur('one')" ></textarea> </p> <p class="text t-l"><span class="hs1">鈼�</span>濡傛灉浣犻個璇峰ソ鏈嬪弸鏉ュ閲屽仛瀹紝浣犺璇翠粈涔堟潵娆㈣繋浠�/濂瑰憿锛� <textarea v-model="questionData.reading.two" placeholder="璇疯緭鍏ュ唴瀹�" rows="6" - style="margin-left: 40px; width: 92%" class="fz-16 fm-son" @change="setBookQuestion"> - </textarea> + style="margin-left: 40px; width: 92%" class="" @change="setBookQuestion" :class="{ 'textarea-focused': isFocused === 'two' }" @focus="handleFocus('two')" @blur="handleBlur('two')" ></textarea> </p> <h3 class="lefth3" id="c016" style="margin-top: 7%;"><img class="img-gn1" alt="" @@ -294,6 +293,7 @@ auidoPathThree: "", auidoPathFour: "", auidoPathFive: "", + isFocused: null, // 鐢ㄤ簬璺熻釜textarea鐨勮仛鐒︾姸鎬� chapterData: { isCollectImg: false, isCollectVideo: false, @@ -469,6 +469,12 @@ "a37bb621b2591e3666e94d1a3bc23bc0" ); }, + handleFocus(id) { + this.isFocused = id; // 褰搕extarea鑱氱劍鏃讹紝璁剧疆涓簍rue + }, + handleBlur(id) { + this.isFocused = null; // 褰搕extarea澶卞幓鐒︾偣鏃讹紝璁剧疆涓篺alse + }, setBookQuestion() { console.log("淇濆瓨"); localStorage.setItem( -- Gitblit v1.9.1