zhongshujie
2024-07-04 38b2ebcdd71d5f59b79c2e9db9f6a857fef34c63
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; // 当textarea聚焦时,设置为true
    },
    handleBlur(id) {
      this.isFocused = null; // 当textarea失去焦点时,设置为false
    },
    setBookQuestion() {
      console.log("保存");
      localStorage.setItem(