natasha 1 рік тому
батько
коміт
58a56ff707

+ 175 - 115
src/components/common/AudioLine.vue

@@ -1,69 +1,119 @@
 <template>
-  <div :class="['Audio', mp3Source && mp3Source == 'tts' ? 'Audio-tts' : '',colorObj?'Audio-'+colorObj.type:'']">
-    <template v-if="type==='full'">
-        <div class="full-drive" @click="PlayAudio">
-            <svg-icon icon-class="Type-drive"></svg-icon>
-            <span>听对比</span>
-        </div>
+  <div
+    :class="[
+      'Audio',
+      mp3Source && mp3Source == 'tts' ? 'Audio-tts' : '',
+      colorObj ? 'Audio-' + colorObj.type : '',
+    ]"
+  >
+    <template v-if="type === 'full'">
+      <div class="full-drive" @click="PlayAudio">
+        <svg-icon icon-class="Type-drive"></svg-icon>
+        <span>听对比</span>
+      </div>
     </template>
     <template v-else>
-    <div class="audioLine" :class="[]">
-      <div
-        class="play"
-        :class="[
-          audio.loading ? 'loadBtn' : audio.playing ? 'playBtn' : 'pauseBtn',
-        ]"
-        @click="PlayAudio"
-      >
-        <i class="el-icon-loading" v-if="audio.loading"></i>
-        <a class="active" v-if="audio.playing&&!audio.loading" :style="{background:audio.playing?colorObj.audioBtnBg?colorObj.audioBtnBg:'':'none'}"><svg-icon icon-class="pause" className="icon-svg" :style="{color:colorObj?colorObj.audioBtnColor:''}"></svg-icon></a>
-        <a v-if="!audio.playing&&!audio.loading" :style="{background:audio.playing?colorObj.audioBtnBg?colorObj.audioBtnBg:'':'none'}"><svg-icon icon-class="play-fill" className="icon-svg" :style="{color:colorObj?colorObj.audioBtnColor:''}"></svg-icon></a>
-      </div>
-      <span class="time-box" :style="{color:colorObj?colorObj.audioTimeColor:''}"
-        ><template v-if="audio.playing">-</template
-        >{{
-        audio.maxTime
-            ? realFormatSecond(audio.maxTime - audio.currentTime)
-            : ""
-        }}</span
-      >
-      <el-slider
-        v-model="playValue"
-        :style="{ width: sliderWidth + 'px', height: '2px'}"
-        :format-tooltip="formatProcessToolTip"
-        @change="changeCurrentTime"
-      />
-      <el-dropdown
-        trigger="hover"
-        placement="top"
-        szie="mini"
-        @command="handleSpeed"
-      >
-        <span class="el-dropdown-link">
-            <span :style="{color: colorObj.audioSpeedColor?colorObj.audioSpeedColor:'#2F3742', cursor: 'pointer', width: '35px', display:'block', textAlign: 'center'}">{{playbackRateValue}}</span>
-        </span>
-        <el-dropdown-menu slot="dropdown">
-            <el-dropdown-item :command="i" v-for="i in 5" :key="i" 
-                >{{ i * 0.5 }}</el-dropdown-item
+      <div class="audioLine" :class="[]">
+        <div
+          class="play"
+          :class="[
+            audio.loading ? 'loadBtn' : audio.playing ? 'playBtn' : 'pauseBtn',
+          ]"
+          @click="PlayAudio"
+        >
+          <i class="el-icon-loading" v-if="audio.loading"></i>
+          <a
+            class="active"
+            v-if="audio.playing && !audio.loading"
+            :style="{
+              background: audio.playing
+                ? colorObj
+                  ? colorObj.audioBtnBg
+                  : ''
+                : 'none',
+            }"
+            ><svg-icon
+              icon-class="pause"
+              className="icon-svg"
+              :style="{ color: colorObj ? colorObj.audioBtnColor : '' }"
+            ></svg-icon
+          ></a>
+          <a
+            v-if="!audio.playing && !audio.loading"
+            :style="{
+              background: audio.playing
+                ? colorObj
+                  ? colorObj.audioBtnBg
+                  : ''
+                : 'none',
+            }"
+            ><svg-icon
+              icon-class="play-fill"
+              className="icon-svg"
+              :style="{ color: colorObj ? colorObj.audioBtnColor : '' }"
+            ></svg-icon
+          ></a>
+        </div>
+        <span
+          class="time-box"
+          :style="{ color: colorObj ? colorObj.audioTimeColor : '' }"
+          ><template v-if="audio.playing">-</template
+          >{{
+            audio.maxTime
+              ? realFormatSecond(audio.maxTime - audio.currentTime)
+              : ""
+          }}</span
+        >
+        <el-slider
+          v-model="playValue"
+          :style="{ width: sliderWidth + 'px', height: '2px' }"
+          :format-tooltip="formatProcessToolTip"
+          @change="changeCurrentTime"
+        />
+        <el-dropdown
+          trigger="hover"
+          placement="top"
+          szie="mini"
+          @command="handleSpeed"
+        >
+          <span class="el-dropdown-link">
+            <span
+              :style="{
+                color: colorObj ? colorObj.audioSpeedColor : '#2F3742',
+                cursor: 'pointer',
+                width: '35px',
+                display: 'block',
+                textAlign: 'center',
+              }"
+              >{{ playbackRateValue }}</span
             >
-        </el-dropdown-menu>
-      </el-dropdown>
-      <el-dropdown trigger="click" placement="top" szie="mini">
-        <span class="el-dropdown-link">
-            <svg-icon icon-class="voice" className="icon-voice" :style="{color:colorObj?colorObj.audioBtnColor:''}"></svg-icon>
-        </span>
-        <el-dropdown-menu slot="dropdown">
+          </span>
+          <el-dropdown-menu slot="dropdown">
+            <el-dropdown-item :command="i" v-for="i in 5" :key="i">{{
+              i * 0.5
+            }}</el-dropdown-item>
+          </el-dropdown-menu>
+        </el-dropdown>
+        <el-dropdown trigger="click" placement="top" szie="mini">
+          <span class="el-dropdown-link">
+            <svg-icon
+              icon-class="voice"
+              className="icon-voice"
+              :style="{ color: colorObj ? colorObj.audioBtnColor : '' }"
+            ></svg-icon>
+          </span>
+          <el-dropdown-menu slot="dropdown">
             <el-slider
-                v-model="sound"
-                @input="changeSound"
-                vertical
-                height="100px"
+              v-model="sound"
+              @input="changeSound"
+              vertical
+              height="100px"
             >
             </el-slider>
-        </el-dropdown-menu>
-      </el-dropdown>
-      <!-- <svg-icon icon-class="repeat" :class="['icon-repeat',isRepeat?'active':'']"></svg-icon> -->
-    </div>
+          </el-dropdown-menu>
+        </el-dropdown>
+        <!-- <svg-icon icon-class="repeat" :class="['icon-repeat',isRepeat?'active':'']"></svg-icon> -->
+      </div>
     </template>
     <audio
       :id="audioId"
@@ -98,7 +148,7 @@ export default {
     "audioId",
     "type",
     "borderRadius",
-    "colorObj"
+    "colorObj",
   ],
   data() {
     // 这里存放数据
@@ -114,14 +164,14 @@ export default {
         isPlaying: false,
         loading: false,
         playbackRate: 1,
-        volume: 100
+        volume: 100,
       },
       audioAllTime: null, // 展示总时间
       duioCurrentTime: null, // 剩余时间
       count: 0,
       loading: null,
       isClick: false,
-      playbackRateValue: '1x',
+      playbackRateValue: "1x",
       sound: 100,
     };
   },
@@ -153,16 +203,16 @@ export default {
     "audio.playing": {
       handler(val) {
         this.$emit("playChange", val);
-        if (val) this.$emit("handleChangeStopAudio",this.audio.playing);
+        if (val) this.$emit("handleChangeStopAudio", this.audio.playing);
       },
     },
-    mp3:{
+    mp3: {
       handler(val, oldVal) {
         const _this = this;
         if (val) {
           _this.$refs[_this.audioId].pause();
           _this.audio.playing = false;
-          _this.audio.currentTime = 0
+          _this.audio.currentTime = 0;
         }
       },
       // 深度观察监听
@@ -177,7 +227,7 @@ export default {
     let audioId = _this.audioId;
     _this.$refs[audioId].addEventListener("loadstart", function () {});
     _this.$refs[audioId].addEventListener("play", function () {
-      if(_this.audio.currentTime<1){
+      if (_this.audio.currentTime < 1) {
         _this.$emit("addPlayRecord");
       }
       _this.audio.playing = true;
@@ -194,7 +244,7 @@ export default {
     _this.$refs[audioId].addEventListener("ended", function () {
       _this.audio.playing = false;
       _this.audio.isPlaying = false;
-      _this.audio.currentTime = 0
+      _this.audio.currentTime = 0;
       _this.$emit("handleListenRead", false);
       _this.isClick = false;
     });
@@ -219,27 +269,35 @@ export default {
     PlayAudio() {
       let audioId = this.audioId;
       let audio = document.getElementsByTagName("audio");
-      if(audio&&audio.length>0&&window.location.href.indexOf('GCLS-Learn')==-1){
+      if (
+        audio &&
+        audio.length > 0 &&
+        window.location.href.indexOf("GCLS-Learn") == -1
+      ) {
         audio.forEach((item) => {
-            if (item.src == this.mp3) {
+          if (item.src == this.mp3) {
             if (item.id !== audioId) {
-                item.pause();
+              item.pause();
             }
-            } else {
+          } else {
             item.pause();
-            }
+          }
         });
       }
       let video = document.getElementsByTagName("video");
-      if(video&&video.length>0&&window.location.href.indexOf('GCLS-Learn')==-1){
+      if (
+        video &&
+        video.length > 0 &&
+        window.location.href.indexOf("GCLS-Learn") == -1
+      ) {
         video.forEach((vItem) => {
-            vItem.pause();
+          vItem.pause();
         });
       }
       if (this.audio.playing) {
         this.$refs[audioId].pause();
         this.audio.playing = false;
-        this.$emit("handleChangeStopAudio",false);
+        this.$emit("handleChangeStopAudio", false);
         this.$emit("handleListenRead", false);
         this.isClick = false;
       } else {
@@ -247,7 +305,7 @@ export default {
           this.audio.loading = true;
           this.count++;
         }
-        this.$emit("handleChangeStopAudio",true);
+        this.$emit("handleChangeStopAudio", true);
         if (this.hideSlider) {
           this.$refs[audioId].play();
           this.onTimeupdateTime(this.bg / 1000);
@@ -299,18 +357,18 @@ export default {
       if (this.type == "audioLine") {
         if (!this.isClick && this.audio.currentTime * 1000 > this.ed) {
           this.$refs[audioId].pause();
-          if(this.$parent.repeatAfter){
-            this.$emit("emptyEd",true);
-          }else{
+          if (this.$parent.repeatAfter) {
+            this.$emit("emptyEd", true);
+          } else {
+            this.$emit("emptyEd");
+          }
+        } else if (this.showEd && this.audio.currentTime * 1000 > this.ed) {
+          this.$refs[audioId].pause();
+          if (this.$parent.repeatAfter) {
+            this.$emit("emptyEd", true);
+          } else {
             this.$emit("emptyEd");
           }
-        }else if(this.showEd && this.audio.currentTime * 1000 > this.ed){
-            this.$refs[audioId].pause();
-            if(this.$parent.repeatAfter){
-                this.$emit("emptyEd",true);
-            }else{
-                this.$emit("emptyEd");
-            }
         }
       } else {
         if (this.audio.currentTime * 1000 > this.ed) {
@@ -319,16 +377,16 @@ export default {
       }
     },
     onTimeupdateTime(res, playFlag) {
-      if (!res&&res!=0) return;
+      if (!res && res != 0) return;
       let audioId = this.audioId;
       this.$refs[audioId].currentTime = res;
       this.playValue = (res / this.audio.maxTime) * 100;
       if (playFlag) {
         let audio = document.getElementsByTagName("audio");
         audio.forEach((item) => {
-            if (item.id !== audioId) {
-                item.pause();
-            }
+          if (item.id !== audioId) {
+            item.pause();
+          }
         });
         this.$refs[audioId].play();
       }
@@ -372,7 +430,7 @@ export default {
     handleSpeed(val) {
       let audio = this.$refs[this.audioId];
       audio.playbackRate = val * 0.5;
-      this.playbackRateValue = val * 0.5 + 'x'
+      this.playbackRateValue = val * 0.5 + "x";
     },
     // 改变音量
     changeSound(val) {
@@ -400,20 +458,21 @@ export default {
     width: 100%;
     .play {
       cursor: pointer;
-      a{
+      a {
         width: 32px;
         height: 32px;
         display: block;
         text-align: center;
-        background: #EEF3FF;
+        background: #eef3ff;
         border-radius: 4px;
         // &:hover,&.active{
         //     background: #EEF3FF;
         //     border-radius: 4px;
         // }
       }
-      .el-icon-loading,.icon-svg{
-        color: #175DFF;
+      .el-icon-loading,
+      .icon-svg {
+        color: #175dff;
         width: 24px;
         height: 24px;
         margin-top: 4px;
@@ -423,41 +482,42 @@ export default {
     .time-box {
       font-size: 16px;
       line-height: 24px;
-      color:#2F3742;
+      color: #2f3742;
       margin-right: 10px;
       min-width: 66px;
       text-align: right;
     }
   }
-  .icon-voice,.icon-repeat{
+  .icon-voice,
+  .icon-repeat {
     width: 24px;
     height: 24px;
-    color: #175DFF;
+    color: #175dff;
     cursor: pointer;
     flex-shrink: 0;
   }
-  .icon-repeat{
+  .icon-repeat {
     margin: 0 8px;
-    color: #D0D3D9;
-    &.active{
-        color: #175DFF;
+    color: #d0d3d9;
+    &.active {
+      color: #175dff;
     }
   }
 }
 </style>
 <style lang="scss">
 .Audio {
-  .el-slider{
+  .el-slider {
     height: 20px !important;
     margin-right: 8px;
   }
   .el-slider__bar {
     height: 20px;
-    background: #175DFF;
+    background: #175dff;
     border-radius: 20px;
   }
   .el-slider__button {
-    background: #175DFF;
+    background: #175dff;
     border: none;
   }
   .el-slider__button-wrapper {
@@ -484,31 +544,31 @@ export default {
   .el-slider {
     position: relative;
   }
-  .el-dropdown{
+  .el-dropdown {
     margin: 0 8px;
   }
-  &-darkGreen{
+  &-darkGreen {
     .el-slider__bar {
-        background: #299772;
+      background: #299772;
     }
     .el-slider__button {
-        background: #299772;
+      background: #299772;
     }
   }
-  &-darkBlue{
+  &-darkBlue {
     .el-slider__bar {
-        background: #5373E7;
+      background: #5373e7;
     }
     .el-slider__button {
-        background: #5373E7;
+      background: #5373e7;
     }
   }
-  &-armyGreen{
+  &-armyGreen {
     .el-slider__bar {
-        background: #30A47D;
+      background: #30a47d;
     }
     .el-slider__button {
-        background: #30A47D;
+      background: #30a47d;
     }
   }
 }

+ 393 - 291
src/views/bookShelf/components/MagazineSentence.vue

@@ -1,341 +1,443 @@
 <template>
-    <div class="sentence-box" :style="{background:themeList[sentenceTheme].bg}">
-        <div class="sentence-top">
-            <a class="play-btn" @click="handlePlay" :style="{background:themeList[sentenceTheme].playBtnBg}">
-                <svg-icon v-if="isPlay" icon-class="pause"></svg-icon>
-                <svg-icon v-else icon-class="play"></svg-icon>
-            </a>
-            <div class="sentence-right" :style="{color:themeList[sentenceTheme].rightBtnColor}">
-                <a class="btn" @click="handlePage('-')"><svg-icon icon-class="arrow-left-s-line"></svg-icon></a>
-                <span>{{sentenceActive+1 + '/' + data.length}}</span>
-                <a class="btn" @click="handlePage('+')"><svg-icon icon-class="arrow-right-s-line"></svg-icon></a>
-                <i class="el-icon-close" @click="closeWord"></i>
-            </div>
-        </div>
-        <div class="content-inner" :style="{background:themeList[sentenceTheme].contentBg}">
-            <div v-for="(itemC,indexC) in data[sentenceActive].wordList" :key="indexC" :class="['content-item',activeWordIndex===null&&currentTime*1000<=data[sentenceActive].e&&currentTime*1000>=data[sentenceActive].timeList[indexC].s||activeWordIndex===indexC?'active':'']" :style="{color:activeWordIndex===null&&currentTime*1000<=data[sentenceActive].e&&currentTime*1000>=data[sentenceActive].timeList[indexC].s||activeWordIndex===indexC?themeList[sentenceTheme].sentenceActiveColor:themeList[sentenceTheme].sentenceColor,fontSize:fontSize+'px',lineHeight:fontSize+8+'px'}" @click="palyWord(indexC)">
-                {{itemC}}
-            </div>
-        </div>
-        <div class="sentence-bottom">
-            <div class="fontsize-box" :style="{background:themeList[sentenceTheme].bottomBg}">
-                <span :style="{background:fontSize===32?themeList[sentenceTheme].bottomBarActiveBtnBg:'',color:fontSize===32?themeList[sentenceTheme].bottomBarActive:''}" @click="handleChangeBgColor(32,'fontSize')">小</span>
-                <div class="border" :style="{background:fontSize===48?themeList[sentenceTheme].bottomBarBorder:''}"></div>
-                <span :style="{background:fontSize===40?themeList[sentenceTheme].bottomBarActiveBtnBg:'',color:fontSize===40?themeList[sentenceTheme].bottomBarActive:''}" @click="handleChangeBgColor(40,'fontSize')">中</span>
-                <div class="border" :style="{background:fontSize===32?themeList[sentenceTheme].bottomBarBorder:''}"></div>
-                <span :style="{background:fontSize===48?themeList[sentenceTheme].bottomBarActiveBtnBg:'',color:fontSize===48?themeList[sentenceTheme].bottomBarActive:''}" @click="handleChangeBgColor(48,'fontSize')">大</span>
-            </div>
-            <ul class="article-color" :style="{background:themeList[sentenceTheme].bottomBg}">
-                <li :class="['color-item',sentenceTheme===indexC?'active':'']" v-for="(itemC,indexC) in themeList" :key="indexC" @click="handleChangeBgColor(indexC,'theme')" :style="{borderColor:sentenceTheme===indexC?itemC.boxBorder:''}">
-                    <a :style="{background:itemC.themeBg,borderColor:sentenceTheme===indexC?itemC.themeActiveBorder:''}"></a>
-                </li>
-            </ul>
-        </div>
+  <div
+    class="sentence-box"
+    :style="{ background: themeList[sentenceTheme].bg }"
+  >
+    <div class="sentence-top">
+      <a
+        class="play-btn"
+        @click="handlePlay"
+        :style="{ background: themeList[sentenceTheme].playBtnBg }"
+      >
+        <svg-icon v-if="isPlay" icon-class="pause"></svg-icon>
+        <svg-icon v-else icon-class="play"></svg-icon>
+      </a>
+      <div
+        class="sentence-right"
+        :style="{ color: themeList[sentenceTheme].rightBtnColor }"
+      >
+        <a class="btn" @click="handlePage('-')"
+          ><svg-icon icon-class="arrow-left-s-line"></svg-icon
+        ></a>
+        <span>{{ sentenceActive + 1 + "/" + data.length }}</span>
+        <a class="btn" @click="handlePage('+')"
+          ><svg-icon icon-class="arrow-right-s-line"></svg-icon
+        ></a>
+        <i class="el-icon-close" @click="closeWord"></i>
+      </div>
     </div>
+    <div
+      class="content-inner"
+      :style="{ background: themeList[sentenceTheme].contentBg }"
+    >
+      <div
+        v-for="(itemC, indexC) in data[sentenceActive].tokens"
+        :key="indexC"
+        :class="[
+          'content-item',
+          (activeWordIndex === null &&
+            currentTime * 1000 <= data[sentenceActive].e &&
+            currentTime * 1000 >= data[sentenceActive].tokens[indexC].s) ||
+          activeWordIndex === indexC
+            ? 'active'
+            : '',
+        ]"
+        :style="{
+          color:
+            (activeWordIndex === null &&
+              currentTime * 1000 <= data[sentenceActive].e &&
+              currentTime * 1000 >= data[sentenceActive].tokens[indexC].s) ||
+            activeWordIndex === indexC
+              ? themeList[sentenceTheme].sentenceActiveColor
+              : themeList[sentenceTheme].sentenceColor,
+          fontSize: fontSize + 'px',
+          lineHeight: fontSize + 8 + 'px',
+          marginRight: itemC.a === '' ? '0' : '',
+        }"
+        @click="palyWord(indexC)"
+      >
+        {{ itemC.w }}
+      </div>
+    </div>
+    <div class="sentence-bottom">
+      <div
+        class="fontsize-box"
+        :style="{ background: themeList[sentenceTheme].bottomBg }"
+      >
+        <span
+          :style="{
+            background:
+              fontSize === 32
+                ? themeList[sentenceTheme].bottomBarActiveBtnBg
+                : '',
+            color:
+              fontSize === 32 ? themeList[sentenceTheme].bottomBarActive : '',
+          }"
+          @click="handleChangeBgColor(32, 'fontSize')"
+          >小</span
+        >
+        <div
+          class="border"
+          :style="{
+            background:
+              fontSize === 48 ? themeList[sentenceTheme].bottomBarBorder : '',
+          }"
+        ></div>
+        <span
+          :style="{
+            background:
+              fontSize === 40
+                ? themeList[sentenceTheme].bottomBarActiveBtnBg
+                : '',
+            color:
+              fontSize === 40 ? themeList[sentenceTheme].bottomBarActive : '',
+          }"
+          @click="handleChangeBgColor(40, 'fontSize')"
+          >中</span
+        >
+        <div
+          class="border"
+          :style="{
+            background:
+              fontSize === 32 ? themeList[sentenceTheme].bottomBarBorder : '',
+          }"
+        ></div>
+        <span
+          :style="{
+            background:
+              fontSize === 48
+                ? themeList[sentenceTheme].bottomBarActiveBtnBg
+                : '',
+            color:
+              fontSize === 48 ? themeList[sentenceTheme].bottomBarActive : '',
+          }"
+          @click="handleChangeBgColor(48, 'fontSize')"
+          >大</span
+        >
+      </div>
+      <ul
+        class="article-color"
+        :style="{ background: themeList[sentenceTheme].bottomBg }"
+      >
+        <li
+          :class="['color-item', sentenceTheme === indexC ? 'active' : '']"
+          v-for="(itemC, indexC) in themeList"
+          :key="indexC"
+          @click="handleChangeBgColor(indexC, 'theme')"
+          :style="{
+            borderColor: sentenceTheme === indexC ? itemC.boxBorder : '',
+          }"
+        >
+          <a
+            :style="{
+              background: itemC.themeBg,
+              borderColor:
+                sentenceTheme === indexC ? itemC.themeActiveBorder : '',
+            }"
+          ></a>
+        </li>
+      </ul>
+    </div>
+  </div>
 </template>
 
 <script>
 //这里可以导入其它文件(比如:组件,工具js,第三方插件js,json文件,图片文件等等)
 //例如:import 《组件名称》from ‘《组件路径》';
 
-
 export default {
   //import引入的组件需要注入到对象中才能使用
-  components: { },
-  props: ["fontSize","sentenceTheme","data","activeIndex","mp3Url"],
+  components: {},
+  props: ["fontSize", "sentenceTheme", "data", "activeIndex", "mp3Url"],
   data() {
     //这里存放数据
     return {
-        isPlay: false, // 音频是否在播放
-        sentenceActive: this.activeIndex,
-        themeList:[
-            {
-                type:'white',
-                bg:'#E5E6EB',
-                playBtnBg:'#175DFF', // 播放按钮背景色
-                rightBtnColor:'rgba(0, 0, 0, 0.96)',// 右侧按钮颜色
-                contentBg:'#F7F8FA',
-                sentenceColor:'rgba(0, 0, 0, 0.96)',
-                sentenceActiveColor:'#175DFF',
-                bottomBg:'#F2F3F5',
-                bottomBarActiveBtnBg:'#FFFFFF',
-                bottomBarColor:'#4E5969',
-                bottomBarActive:'#165DFF',
-                bottomBarBorder:'#E5E6EB',
-                themeBg:'#FFFFFF',
-                themeActiveBorder:'#E5E6EB',
-                boxBorder:'#3459D2', // 选中时高亮的外圈边框
-            },
-            {
-                type:'darkGreen',
-                bg:'#C2C9C6',
-                playBtnBg:'#236E55', // 播放按钮背景色
-                rightBtnColor:'rgba(0, 0, 0, 0.96)',// 右侧按钮颜色
-                contentBg:'#DFE4E2',
-                sentenceColor:'rgba(0, 0, 0, 0.96)',
-                sentenceActiveColor:'#236E55',
-                bottomBg:'#DFE4E2',
-                bottomBarActiveBtnBg:'#FFFFFF',
-                bottomBarColor:'#4E5969',
-                bottomBarActive:'#236E55',
-                bottomBarBorder:'#C2C9C6',
-                themeBg:'#5BB99A',
-                themeActiveBorder:'#5BB99A',
-                boxBorder:'#fff', // 选中时高亮的外圈边框
-            },
-            {
-                type:'darkBlue',
-                bg:'#1C2129',
-                playBtnBg:'#5373E7', // 播放按钮背景色
-                rightBtnColor:'#fff',// 右侧按钮颜色
-                contentBg:'#2F3742',
-                sentenceColor:'#C1C5CD',
-                sentenceActiveColor:'#5373E7',
-                bottomBg:'#2F3742',
-                bottomBarActiveBtnBg:'#1C2129',
-                bottomBarColor:'#929CA8',
-                bottomBarActive:'#5373E7',
-                bottomBarBorder:'#1C2129',
-                themeBg:'#1F2C5C',
-                themeActiveBorder:'#1F2C5C',
-                boxBorder:'#fff', // 选中时高亮的外圈边框
-            },
-            {
-                type:'armyGreen',
-                bg:'#2A2F2C',
-                playBtnBg:'#30A47D', // 播放按钮背景色
-                rightBtnColor:'#fff',// 右侧按钮颜色
-                contentBg:'#393F3C',
-                sentenceColor:'#C1C5CD',
-                sentenceActiveColor:'#30A47D',
-                bottomBg:'#393F3C',
-                bottomBarActiveBtnBg:'#2A2F2C',
-                bottomBarColor:'#C1C5CD',
-                bottomBarActive:'#30A47D',
-                bottomBarBorder:'#2A2F2C',
-                themeBg:'#13392E',
-                themeActiveBorder:'#13392E',
-                boxBorder:'#fff', // 选中时高亮的外圈边框
-            }
-        ],
-        currentTime:0,
-        audio: new Audio(),
-        ed: null,
-        activeWordIndex: null
-    }
+      isPlay: false, // 音频是否在播放
+      sentenceActive: this.activeIndex,
+      themeList: [
+        {
+          type: "white",
+          bg: "#E5E6EB",
+          playBtnBg: "#175DFF", // 播放按钮背景色
+          rightBtnColor: "rgba(0, 0, 0, 0.96)", // 右侧按钮颜色
+          contentBg: "#F7F8FA",
+          sentenceColor: "rgba(0, 0, 0, 0.96)",
+          sentenceActiveColor: "#175DFF",
+          bottomBg: "#F2F3F5",
+          bottomBarActiveBtnBg: "#FFFFFF",
+          bottomBarColor: "#4E5969",
+          bottomBarActive: "#165DFF",
+          bottomBarBorder: "#E5E6EB",
+          themeBg: "#FFFFFF",
+          themeActiveBorder: "#E5E6EB",
+          boxBorder: "#3459D2", // 选中时高亮的外圈边框
+        },
+        {
+          type: "darkGreen",
+          bg: "#C2C9C6",
+          playBtnBg: "#236E55", // 播放按钮背景色
+          rightBtnColor: "rgba(0, 0, 0, 0.96)", // 右侧按钮颜色
+          contentBg: "#DFE4E2",
+          sentenceColor: "rgba(0, 0, 0, 0.96)",
+          sentenceActiveColor: "#236E55",
+          bottomBg: "#DFE4E2",
+          bottomBarActiveBtnBg: "#FFFFFF",
+          bottomBarColor: "#4E5969",
+          bottomBarActive: "#236E55",
+          bottomBarBorder: "#C2C9C6",
+          themeBg: "#5BB99A",
+          themeActiveBorder: "#5BB99A",
+          boxBorder: "#fff", // 选中时高亮的外圈边框
+        },
+        {
+          type: "darkBlue",
+          bg: "#1C2129",
+          playBtnBg: "#5373E7", // 播放按钮背景色
+          rightBtnColor: "#fff", // 右侧按钮颜色
+          contentBg: "#2F3742",
+          sentenceColor: "#C1C5CD",
+          sentenceActiveColor: "#5373E7",
+          bottomBg: "#2F3742",
+          bottomBarActiveBtnBg: "#1C2129",
+          bottomBarColor: "#929CA8",
+          bottomBarActive: "#5373E7",
+          bottomBarBorder: "#1C2129",
+          themeBg: "#1F2C5C",
+          themeActiveBorder: "#1F2C5C",
+          boxBorder: "#fff", // 选中时高亮的外圈边框
+        },
+        {
+          type: "armyGreen",
+          bg: "#2A2F2C",
+          playBtnBg: "#30A47D", // 播放按钮背景色
+          rightBtnColor: "#fff", // 右侧按钮颜色
+          contentBg: "#393F3C",
+          sentenceColor: "#C1C5CD",
+          sentenceActiveColor: "#30A47D",
+          bottomBg: "#393F3C",
+          bottomBarActiveBtnBg: "#2A2F2C",
+          bottomBarColor: "#C1C5CD",
+          bottomBarActive: "#30A47D",
+          bottomBarBorder: "#2A2F2C",
+          themeBg: "#13392E",
+          themeActiveBorder: "#13392E",
+          boxBorder: "#fff", // 选中时高亮的外圈边框
+        },
+      ],
+      currentTime: 0,
+      audio: new Audio(),
+      ed: null,
+      activeWordIndex: null,
+    };
   },
   //计算属性 类似于data概念
   computed: {},
   //监控data中数据变化
-  watch: {
-
-  },
+  watch: {},
   //方法集合
   methods: {
     // 播放、暂停
-    handlePlay(){
-        let _this = this
-        _this.activeWordIndex = null
-        _this.isPlay = !_this.isPlay
-        if(!_this.isPlay){
-            _this.audio.pause();
-            return
-        }
+    handlePlay() {
+      let _this = this;
+      _this.activeWordIndex = null;
+      _this.isPlay = !_this.isPlay;
+      if (!_this.isPlay) {
         _this.audio.pause();
-        _this.audio.load();
-        _this.audio.src = _this.mp3Url;
-        if(_this.currentTime<=_this.data[_this.sentenceActive].s/1000){
-            _this.audio.currentTime = _this.data[_this.sentenceActive].s / 1000
-        }else{
-            _this.audio.currentTime = _this.currentTime
-        }
-        _this.ed = _this.data[_this.sentenceActive].e / 1000
-        _this.audio.loop = false;
-        _this.audio.play();
+        return;
+      }
+      _this.audio.pause();
+      _this.audio.load();
+      _this.audio.src = _this.mp3Url;
+      if (_this.currentTime <= _this.data[_this.sentenceActive].s / 1000) {
+        _this.audio.currentTime = _this.data[_this.sentenceActive].s / 1000;
+      } else {
+        _this.audio.currentTime = _this.currentTime;
+      }
+      _this.ed = _this.data[_this.sentenceActive].e / 1000;
+      _this.audio.loop = false;
+      _this.audio.play();
     },
-    palyWord(index){
-        let _this = this
-        _this.activeWordIndex = index
-        _this.audio.pause();
-        _this.audio.load();
-        _this.audio.src = _this.mp3Url;
-        _this.audio.currentTime = _this.data[_this.sentenceActive].timeList[index].s/1000
-        _this.ed = _this.data[_this.sentenceActive].timeList[index].e / 1000
-        _this.audio.loop = false;
-        _this.audio.play();
+    palyWord(index) {
+      let _this = this;
+      _this.activeWordIndex = index;
+      _this.audio.pause();
+      _this.audio.load();
+      _this.audio.src = _this.mp3Url;
+      _this.audio.currentTime =
+        _this.data[_this.sentenceActive].tokens[index].s / 1000;
+      _this.ed = _this.data[_this.sentenceActive].tokens[index].e / 1000;
+      _this.audio.loop = false;
+      _this.audio.play();
     },
     // 关闭
-    closeWord(){
-        this.$emit('closeWord')
+    closeWord() {
+      this.$emit("closeWord");
     },
-    handlePage(type){
-        if(type==='-'){
-            if(this.sentenceActive>0){
-                this.audio.pause()
-                this.isPlay = false
-                this.currentTime = 0
-                this.sentenceActive--
-            }else{
-                this.$message.warning('已经是第一句')
-            }
-        }else{
-            if(this.sentenceActive<this.data.length-1){
-                this.audio.pause()
-                this.isPlay = false
-                this.currentTime = 0
-                this.sentenceActive++
-            }else{
-                this.$message.warning('已经是最后一句')
-            }
+    handlePage(type) {
+      if (type === "-") {
+        if (this.sentenceActive > 0) {
+          this.audio.pause();
+          this.isPlay = false;
+          this.currentTime = 0;
+          this.sentenceActive--;
+        } else {
+          this.$message.warning("已经是第一句");
         }
+      } else {
+        if (this.sentenceActive < this.data.length - 1) {
+          this.audio.pause();
+          this.isPlay = false;
+          this.currentTime = 0;
+          this.sentenceActive++;
+        } else {
+          this.$message.warning("已经是最后一句");
+        }
+      }
     },
     // 切换主题颜色
-    handleChangeBgColor(index,type){
-        if(type==='fontSize'){
-            this.$emit('changeTheme','',index)
-        }else{
-            this.$emit('changeTheme',index)
-        }
-        
-    }
+    handleChangeBgColor(index, type) {
+      if (type === "fontSize") {
+        this.$emit("changeTheme", "", index);
+      } else {
+        this.$emit("changeTheme", index);
+      }
+    },
   },
   //生命周期 - 创建完成(可以访问当前this实例)
-  created() {
-  },
+  created() {},
   //生命周期 - 挂载完成(可以访问DOM元素)
   mounted() {
-    let _this = this
+    let _this = this;
     _this.audio.addEventListener("timeupdate", function () {
-        _this.currentTime = _this.audio.currentTime
-        const currentTime = _this.audio.currentTime;
-        if (_this.ed&&currentTime >= _this.ed) {
-            _this.audio.pause();
-            _this.isPlay = false
-            _this.currentTime = 0
-        }
-    });
+      _this.currentTime = _this.audio.currentTime;
+      const currentTime = _this.audio.currentTime;
+      if (_this.ed && currentTime >= _this.ed) {
+        _this.audio.pause();
+        _this.isPlay = false;
+        _this.currentTime = 0;
+      }
+    });
   },
   //生命周期-创建之前
-  beforeCreated() { },
+  beforeCreated() {},
   //生命周期-挂载之前
-  beforeMount() { },
+  beforeMount() {},
   //生命周期-更新之前
-  beforUpdate() { },
+  beforUpdate() {},
   //生命周期-更新之后
-  updated() { },
+  updated() {},
   //生命周期-销毁之前
-  beforeDestory() { },
+  beforeDestory() {},
   //生命周期-销毁完成
-  destoryed() { },
+  destoryed() {},
   //如果页面有keep-alive缓存功能,这个函数会触发
-  activated() { }
-}
+  activated() {},
+};
 </script>
 <style lang="scss" scoped>
 /* @import url(); 引入css类 */
-.sentence-box{
-    padding: 16px;
-    .sentence-top{
-        display: flex;
-        justify-content: space-between;
-        .play-btn{
-            width: 40px;
-            height: 40px;
-            border-radius: 20px;
-            padding: 8px;
-            background: #175DFF;
-            color: rgba(255, 255, 255, 0.96);
-        }
-        .sentence-right{
-            color: rgba(0, 0, 0, 0.96);
-            font-weight: 700;
-            font-size: 12px;
-            line-height: 20px;
-            display: flex;
-            align-items: center;
-            .btn{
-                width: 40px;
-                height: 40px;
-                padding: 8px;
-            }
-            span{
-                min-width: 40px;
-                text-align: center;
-            }
-            .el-icon-close{
-                cursor: pointer;
-                font-size: 16px;
-                font-weight: 700;
-            }
-        }
-        .svg-icon{
-            font-size: 24px;
-        }
+.sentence-box {
+  padding: 16px;
+  .sentence-top {
+    display: flex;
+    justify-content: space-between;
+    .play-btn {
+      width: 40px;
+      height: 40px;
+      border-radius: 20px;
+      padding: 8px;
+      background: #175dff;
+      color: rgba(255, 255, 255, 0.96);
     }
-    .content-inner{
-        padding: 40px 45px;
-        border-radius: 8px;
-        margin: 16px 0;
-        display: flex;
-        flex-flow: wrap;
-        .content-item{
-            margin: 0 3px;
-            font-size: 32px;
-            line-height: 40px;
-            cursor: pointer;
-            &.active{
-                font-weight: 700;
-            }
-        }
+    .sentence-right {
+      color: rgba(0, 0, 0, 0.96);
+      font-weight: 700;
+      font-size: 12px;
+      line-height: 20px;
+      display: flex;
+      align-items: center;
+      .btn {
+        width: 40px;
+        height: 40px;
+        padding: 8px;
+      }
+      span {
+        min-width: 40px;
+        text-align: center;
+      }
+      .el-icon-close {
+        cursor: pointer;
+        font-size: 16px;
+        font-weight: 700;
+      }
     }
-    .sentence-bottom{
-        display: flex;
-        .fontsize-box{
-            display: flex;
-            padding: 3px;
-            border-radius: 20px;
-            align-items: center;
-            span{
-                font-weight: 400;
-                font-size: 14px;
-                line-height: 22px;
-                width: 38px;
-                padding: 2px 12px;
-                border-radius: 20px;
-                cursor: pointer;
-                &.active{
-                    font-weight: 500;
-                }
-            }
-            .border{
-                width: 1px;
-                height: 14px;
-            }
+    .svg-icon {
+      font-size: 24px;
+    }
+  }
+  .content-inner {
+    padding: 40px 45px;
+    border-radius: 8px;
+    margin: 16px 0;
+    display: flex;
+    flex-flow: wrap;
+    .content-item {
+      margin: 0 6px 0 0;
+      font-size: 32px;
+      line-height: 40px;
+      cursor: pointer;
+      &.active {
+        font-weight: 700;
+      }
+    }
+  }
+  .sentence-bottom {
+    display: flex;
+    .fontsize-box {
+      display: flex;
+      padding: 3px;
+      border-radius: 20px;
+      align-items: center;
+      span {
+        font-weight: 400;
+        font-size: 14px;
+        line-height: 22px;
+        width: 38px;
+        padding: 2px 12px;
+        border-radius: 20px;
+        cursor: pointer;
+        &.active {
+          font-weight: 500;
         }
-        .article-color{
-            display: flex;
-            width: 132px;
-            height: 32px;
-            justify-content: space-between;
-            align-items: center;
-            border-radius: 40px;
-            margin-left: 12px;
-            padding: 4px;
-            .color-item{
-                padding: 2px;
-                border: 2px solid transparent;
-                border-radius: 50%;
-                a{
-                    width: 16px;
-                    height: 16px;
-                    border-radius: 50%;
-                    display: block;
-                    border: 1px solid transparent;
-                    padding: 0;
-                }
-                
-            }
+      }
+      .border {
+        width: 1px;
+        height: 14px;
+      }
+    }
+    .article-color {
+      display: flex;
+      width: 132px;
+      height: 32px;
+      justify-content: space-between;
+      align-items: center;
+      border-radius: 40px;
+      margin-left: 12px;
+      padding: 4px;
+      .color-item {
+        padding: 2px;
+        border: 2px solid transparent;
+        border-radius: 50%;
+        a {
+          width: 16px;
+          height: 16px;
+          border-radius: 50%;
+          display: block;
+          border: 1px solid transparent;
+          padding: 0;
         }
+      }
     }
+  }
 }
-</style>
+</style>

+ 47 - 50
src/views/bookShelf/components/MagazineVideo.vue

@@ -1,88 +1,85 @@
 <template>
-    <div style="position:relative">
-        <i class="el-icon-close" @click="closeWord"></i>
-        <div class="video" id="video-box"></div>
-    </div>
+  <div style="position: relative">
+    <i class="el-icon-close" @click="closeWord"></i>
+    <div class="video" id="video-box"></div>
+  </div>
 </template>
 
 <script>
 //这里可以导入其它文件(比如:组件,工具js,第三方插件js,json文件,图片文件等等)
 //例如:import 《组件名称》from ‘《组件路径》';
-import Player from 'xgplayer';
-import 'xgplayer/dist/index.min.css';
+import Player from "xgplayer";
+import "xgplayer/dist/index.min.css";
 
 export default {
   //import引入的组件需要注入到对象中才能使用
-  components: { },
-  props: [],
+  components: {},
+  props: ["url"],
   data() {
     //这里存放数据
     return {
-        player: null,  
-    }
+      player: null,
+    };
   },
   //计算属性 类似于data概念
   computed: {},
   //监控data中数据变化
-  watch: {
-
-  },
+  watch: {},
   //方法集合
   methods: {
     // 关闭
-    closeWord(){
-        this.$emit('closeWord')
-    }
+    closeWord() {
+      this.$emit("closeWord");
+    },
   },
   //生命周期 - 创建完成(可以访问当前this实例)
-  created() {
-  },
+  created() {},
   //生命周期 - 挂载完成(可以访问DOM元素)
   mounted() {
     this.player = new Player({
-        id: 'video-box',
-        url: '//sf1-cdn-tos.huoshanstatic.com/obj/media-fe/xgplayer_doc_video/mp4/xgplayer-demo-360p.mp4',
-        height: '100%',
-        width: '100%',
-        cssFullscreen: false,
-        commonStyle:{
-            progressColor: 'rgba(255, 255, 255, 0.7)',
-            playedColor: '#0081F1',
-            volumeColor: '#0081F1',
-            sliderBtnStyle: {},
-        },
-        poster: require('../../../assets/poster.png'), // 封面图
+      id: "video-box",
+      url: this.url,
+      height: "100%",
+      width: "100%",
+      cssFullscreen: false,
+      commonStyle: {
+        progressColor: "rgba(255, 255, 255, 0.7)",
+        playedColor: "#0081F1",
+        volumeColor: "#0081F1",
+        sliderBtnStyle: {},
+      },
+      poster: "", // 封面图
     });
   },
   //生命周期-创建之前
-  beforeCreated() { },
+  beforeCreated() {},
   //生命周期-挂载之前
-  beforeMount() { },
+  beforeMount() {},
   //生命周期-更新之前
-  beforUpdate() { },
+  beforUpdate() {},
   //生命周期-更新之后
-  updated() { },
+  updated() {},
   //生命周期-销毁之前
-  beforeDestory() { },
+  beforeDestory() {},
   //生命周期-销毁完成
-  destoryed() { },
+  destoryed() {},
   //如果页面有keep-alive缓存功能,这个函数会触发
-  activated() { }
-}
+  activated() {},
+};
 </script>
 <style lang="scss" scoped>
 /* @import url(); 引入css类 */
-.video{
-    height: 450px !important;
+.video {
+  height: 450px !important;
 }
-.el-icon-close{
-    font-size: 16px;
-    padding: 8px;
-    cursor: pointer;
-    position: absolute;
-    right: 0;
-    top: 0;
-    z-index: 1;
-    color: #fff;
+.el-icon-close {
+  font-size: 16px;
+  padding: 8px;
+  cursor: pointer;
+  position: absolute;
+  right: 0;
+  top: 0;
+  z-index: 1;
+  color: #fff;
 }
-</style>
+</style>

+ 715 - 451
src/views/bookShelf/magazineDetail.vue

@@ -1,70 +1,140 @@
 <template>
   <div class="magazine-detail">
-    <Header
-      :LoginNavIndex="1"
-    />
+    <Header :LoginNavIndex="1" />
     <div class="navBar">
-        <div class="navBar-left">
-            <a class="goback" @click="$router.go(-1)"><i class="el-icon-arrow-left"></i> 第 856 期</a>
-            <div class="border"></div>
-            <p class="article-title">Making room for the pet boom</p>
-        </div>
+      <div class="navBar-left">
+        <a class="goback" @click="$router.go(-1)"
+          ><i class="el-icon-arrow-left"></i> 第 {{ iss_no }} 期</a
+        >
+        <div class="border"></div>
+        <p class="article-title">{{ iss_name }}</p>
+      </div>
     </div>
     <div class="magazine-inner">
-        <div class="btn-box">
-            <el-button round class="btn-left" @click="handlePage('-')"><svg-icon icon-class="arrow-left-s-line"></svg-icon>上一页</el-button>
-            <!-- <el-button round class="explain-video" @click="handleVideo"><svg-icon icon-class="video-line"></svg-icon>讲解视频</el-button> -->
-            <div class="audio-box">
-                <div
-                    class="aduioLine-content aduioLine-box"
-                    v-if="
-                        art_sound_url
-                    "
-                >
-                    <AudioLine
-                        audioId="artMagazineAudio"
-                        :mp3="art_sound_url"
-                        :getCurTime="getCurTime"
-                        ref="audioLine"
-                        :mp3Source="'mp3'"
-                        type="audioLine"
-                        :ed="ed"
-                        :showEd="showEd"
-                        @emptyEd="emptyEd"
-                    />
-                    <!-- <svg-icon icon-class="icon-wrapper" class="wrapper" @click="fullScreen"></svg-icon> -->
-                </div>
-            </div>
-            <el-button round class="btn-right" @click="handlePage('+')">下一页<svg-icon icon-class="arrow-right-s-line"></svg-icon></el-button>
-        </div>
-        <div class="magazine-box">
-            <a class="btn-left" @click="handlePage('-')"><svg-icon icon-class="arrow-left-s-line"></svg-icon></a>
-            <a class="btn-right" @click="handlePage('+')"><svg-icon icon-class="arrow-right-s-line"></svg-icon></a>
-            <template v-for="(item,index) in magazineList">
-                <div :key="index" class="magazine" :style="{top:24+(index-activePage)*16+'px',marginLeft:-554+(index-activePage)*16+'px',zIndex:(10-index),height:783-(index-activePage)*16+'px'}" v-if="index>=activePage&&index<=activePage+3">
-                    <img :src="item.img"/>
-                    <div v-for="(itemP,indexP) in item.positionList" :key="indexP" :class="['position-item',mageazineDetailIndex===indexP?'active':'']" :style="{width:itemP.width,height:itemP.height,left:itemP.x,top:itemP.y}" @click="handleChangePosition(indexP)"></div>
-                </div>
-            </template>
+      <div class="btn-box">
+        <el-button round class="btn-left" @click="handlePage('-')"
+          ><svg-icon icon-class="arrow-left-s-line"></svg-icon>上一页</el-button
+        >
+        <el-button
+          v-if="
+            magazineList[activePage] &&
+            magazineList[activePage].video &&
+            magazineList[activePage].video.id
+          "
+          round
+          class="explain-video"
+          @click="handleVideo"
+          ><svg-icon icon-class="video-line"></svg-icon>讲解视频</el-button
+        >
+        <el-button round class="btn-right" @click="handlePage('+')"
+          >下一页<svg-icon icon-class="arrow-right-s-line"></svg-icon
+        ></el-button>
+      </div>
+
+      <div class="audio-box">
+        <div
+          class="aduioLine-content aduioLine-box"
+          v-if="
+            magazineList[activePage] &&
+            magazineList[activePage].sound &&
+            magazineList[activePage].sound.id
+          "
+        >
+          <AudioLine
+            audioId="artMagazineAudio"
+            :mp3="magazineList[activePage].sound.url"
+            :getCurTime="getCurTime"
+            ref="audioLine"
+            :mp3Source="'mp3'"
+            type="audioLine"
+            :ed="ed"
+            :showEd="showEd"
+            @emptyEd="emptyEd"
+          />
+          <!-- <svg-icon icon-class="icon-wrapper" class="wrapper" @click="fullScreen"></svg-icon> -->
         </div>
+      </div>
+      <div class="magazine-box">
+        <a class="btn-left" @click="handlePage('-')"
+          ><svg-icon icon-class="arrow-left-s-line"></svg-icon
+        ></a>
+        <a class="btn-right" @click="handlePage('+')"
+          ><svg-icon icon-class="arrow-right-s-line"></svg-icon
+        ></a>
+        <template v-for="(item, index) in magazineList">
+          <div
+            :key="index"
+            class="magazine"
+            :class="['magazine' + index]"
+            :style="{
+              top: 24 + (index - activePage) * 16 + 'px',
+              marginLeft: -554 + (index - activePage) * 16 + 'px',
+              zIndex: magazineList.length - index,
+              height: 783 - (index - activePage) * 16 + 'px',
+            }"
+            v-if="index >= activePage && index <= activePage + 3"
+          >
+            <div
+              class="img-box"
+              :style="{
+                background:
+                  'url(' + item.img.url + ') center / cover no-repeat',
+              }"
+            >
+              <div
+                v-for="(itemP, indexP) in item.hotspots"
+                :key="indexP"
+                :class="[
+                  'position-item',
+                  mageazineDetailIndex === indexP ? 'active' : '',
+                ]"
+                :style="{
+                  width: itemP.width,
+                  height: itemP.height,
+                  left: itemP.x,
+                  top: itemP.y,
+                }"
+                @click="handleChangePosition(indexP)"
+              ></div>
+            </div>
+          </div>
+        </template>
+      </div>
     </div>
     <el-dialog
-        :visible.sync="magazineVideoShow"
-        :show-close="false"
-        :close-on-click-modal="false"
-        width="800px"
-        class="login-dialog"
-        v-if="magazineVideoShow">
-        <magazine-video @closeWord="closeWord"></magazine-video>
+      :visible.sync="magazineVideoShow"
+      :show-close="false"
+      :close-on-click-modal="false"
+      width="800px"
+      class="login-dialog"
+      v-if="magazineVideoShow"
+    >
+      <magazine-video
+        :url="magazineList[activePage].video.url"
+        @closeWord="closeWord"
+      ></magazine-video>
     </el-dialog>
     <el-dialog
-        :visible.sync="mageazineDetailShow"
-        :show-close="false"
-        :close-on-click-modal="false"
-        width="500px"
-        class="login-dialog magazine-detail-dialog"
-        v-if="mageazineDetailShow">
-        <magazine-sentence :fontSize="fontSize" :sentenceTheme="sentenceTheme" :data="magazineList[activePage].sentenceList" :activeIndex="mageazineDetailIndex" @closeWord="closeMagazineSentence" @changeTheme="changeTheme" :mp3Url="art_sound_url"></magazine-sentence>
+      :visible.sync="mageazineDetailShow"
+      :show-close="false"
+      :close-on-click-modal="false"
+      width="500px"
+      class="login-dialog magazine-detail-dialog"
+      v-if="mageazineDetailShow"
+    >
+      <magazine-sentence
+        :fontSize="fontSize"
+        :sentenceTheme="sentenceTheme"
+        :data="magazineList[activePage].hotspots"
+        :activeIndex="mageazineDetailIndex"
+        @closeWord="closeMagazineSentence"
+        @changeTheme="changeTheme"
+        :mp3Url="
+          magazineList[activePage].sound && magazineList[activePage].sound.url
+            ? magazineList[activePage].sound.url
+            : ''
+        "
+      ></magazine-sentence>
     </el-dialog>
   </div>
 </template>
@@ -73,251 +143,398 @@
 //这里可以导入其它文件(比如:组件,工具js,第三方插件js,json文件,图片文件等等)
 //例如:import 《组件名称》from ‘《组件路径》';
 import Header from "../../components/Header.vue";
-import MagazineVideo from "./components/MagazineVideo.vue"
-import MagazineSentence from "./components/MagazineSentence.vue"
-import AudioLine from "@/components/common/AudioLine.vue"
+import MagazineVideo from "./components/MagazineVideo.vue";
+import MagazineSentence from "./components/MagazineSentence.vue";
+import AudioLine from "@/components/common/AudioLine.vue";
+import { getLogin } from "@/api/ajax";
 export default {
   //import引入的组件需要注入到对象中才能使用
-  components: { Header,MagazineVideo,MagazineSentence,AudioLine},
+  components: { Header, MagazineVideo, MagazineSentence, AudioLine },
   props: [],
   data() {
     //这里存放数据
     return {
-        magazineList:[
+      magazineList: [
+        {
+          img: require("../../assets/ed88685cd9fe892adb12382427d3c429.jpg"),
+          positionList: [
+            {
+              width: "270px",
+              height: "140px",
+              x: "390px",
+              y: "37px",
+            },
+            {
+              width: "288px",
+              height: "120px",
+              x: "500px",
+              y: "237px",
+            },
             {
-              img:require('../../assets/ed88685cd9fe892adb12382427d3c429.jpg'),
-              positionList:[
+              width: "130px",
+              height: "100px",
+              x: "525px",
+              y: "587px",
+            },
+          ],
+          sentenceList: [
+            {
+              sentence: "I have a super ‘mouth’",
+              wordList: ["I", "have", "a", "super", "‘mouth’"],
+              s: 21500,
+              e: 24000,
+              timeList: [
+                {
+                  s: 21500,
+                  e: 21800,
+                },
                 {
-                    width:'270px',
-                    height:'140px',
-                    x:'390px',
-                    y:'37px'
+                  s: 21800,
+                  e: 22200,
                 },
                 {
-                    width:'288px',
-                    height:'120px',
-                    x:'500px',
-                    y:'237px'
+                  s: 22200,
+                  e: 22400,
                 },
                 {
-                    width:'130px',
-                    height:'100px',
-                    x:'525px',
-                    y:'587px'
+                  s: 22400,
+                  e: 22900,
+                },
+                {
+                  s: 22900,
+                  e: 24000,
                 },
               ],
-              sentenceList:[
-                    {
-                        sentence:"I have a super ‘mouth’",
-                        wordList:['I','have','a','super','‘mouth’'],
-                        s: 21500,
-                        e: 24000,
-                        timeList:[
-                            {
-                                s:21500,
-                                e:21800
-                            },
-                            {
-                                s:21800,
-                                e:22200
-                            },
-                            {
-                                s:22200,
-                                e:22400
-                            },
-                            {
-                                s:22400,
-                                e:22900
-                            },
-                            {
-                                s:22900,
-                                e:24000
-                            }
-                        ]
-                    },
-                    {
-                        sentence:"I am a shoebill (鲸头鹳). I live in Africa (非洲). I get my name because of my big bill (鸟喙). Does it look like a Dutch clog (荷兰木屐)?",
-                        wordList:['I','am','a','shoebill (鲸头鹳).','I','live',"in","Africa (非洲).","I","get","my","name","because","of","my","big","bill (鸟喙).","Does","it","look","like","a","Dutch","clog (荷兰木屐)?"],
-                        s: 35000,
-                        e: 46300,
-                        timeList: [
-                            {
-                                s:35000,
-                                e:35400
-                            },
-                            {
-                                s:35400,
-                                e:35600
-                            },
-                            {
-                                s:35600,
-                                e:36000
-                            },
-                            {
-                                s:36000,
-                                e:37000
-                            },
-                            {
-                                s:37000,
-                                e:37300
-                            },
-                            {
-                                s:37300,
-                                e:37600
-                            },
-                            {
-                                s:37600,
-                                e:37900
-                            },
-                            {
-                                s:38000,
-                                e:38900
-                            },
-                            {
-                                s:39200,
-                                e:39400
-                            },
-                            {
-                                s:39400,
-                                e:39800
-                            },
-                            {
-                                s:39800,
-                                e:40400
-                            },
-                            {
-                                s:40400,
-                                e:40900
-                            },
-                            {
-                                s:40900,
-                                e:41700
-                            },
-                            {
-                                s:41700,
-                                e:41900
-                            },
-                            {
-                                s:41900,
-                                e:42500
-                            },
-                            {
-                                s:42500,
-                                e:42900
-                            },
-                            {
-                                s:42900,
-                                e:43800
-                            },
-                            {
-                                s:43800,
-                                e:44200
-                            },
-                            {
-                                s:44200,
-                                e:44500
-                            },
-                            {
-                                s:44500,
-                                e:44800
-                            },
-                            {
-                                s:44800,
-                                e:45000
-                            },
-                            {
-                                s:45000,
-                                e:45200
-                            },
-                            {
-                                s:45200,
-                                e:45600
-                            },
-                            {
-                                s:45600,
-                                e:46300
-                            },
-                        ]
-                    },
-                    {
-                        sentence:"My bill is important. It helps me a lot.",
-                        wordList:['My','bill','is','important.','It','helps','me',"a","lot."],
-                        s: 48000,
-                        e: 52000,
-                        timeList:[
-                            {
-                                s:48000,
-                                e:48400
-                            },
-                            {
-                                s:48400,
-                                e:48700
-                            },
-                            {
-                                s:48700,
-                                e:48900
-                            },
-                            {
-                                s:48900,
-                                e:49900
-                            },
-                            {
-                                s:49900,
-                                e:50200
-                            },
-                            {
-                                s:50200,
-                                e:50800
-                            },
-                            {
-                                s:50800,
-                                e:51100
-                            },
-                            {
-                                s:51100,
-                                e:51400
-                            },
-                            {
-                                s:51400,
-                                e:52000
-                            },
-                        ]
-                    }
-                ]
             },
             {
-              img:require('../../assets/f70b022cce193716cc091e5c8c54d6e5.jpg'),
-            }
-        ],
-        art_sound_url:require('../../assets/21hk_99_165420_1.mp3'),
-        activePage:0, // 当前显示第几页 
-        magazineVideoShow:false, // 讲解视频是否显示
-        mageazineDetailIndex:null, // 当前画刊高亮第几个
-        mageazineDetailShow:false,
-        fontSize:32,
-        sentenceTheme:0,
-        sentenceList:[
-            {
-                sentence:"With a lot of water in a cactus' body, a grown-up plant may weigh 6 tons or more. That's as heavy as an elephant!",
-                wordList:['With','a','lot','of','water','in','a',"cactus'","body,","a","grown-up","plant","may","weigh","6","tons","or","more.","That's","as","heavy","as","an","elephant!"]
-            },
-            {
-                sentence:"With a lot of water in a cactus' body, a grown-up plant may weigh 6 tons or more. That's as heavy as an elephant!",
-                wordList:['With','a','lot','of','water','in','a',"cactus'","body,","a","grown-up","plant","may","weigh","6","tons","or","more.","That's","as","heavy","as","an","elephant!"]
+              sentence:
+                "I am a shoebill (鲸头鹳). I live in Africa (非洲). I get my name because of my big bill (鸟喙). Does it look like a Dutch clog (荷兰木屐)?",
+              wordList: [
+                "I",
+                "am",
+                "a",
+                "shoebill (鲸头鹳).",
+                "I",
+                "live",
+                "in",
+                "Africa (非洲).",
+                "I",
+                "get",
+                "my",
+                "name",
+                "because",
+                "of",
+                "my",
+                "big",
+                "bill (鸟喙).",
+                "Does",
+                "it",
+                "look",
+                "like",
+                "a",
+                "Dutch",
+                "clog (荷兰木屐)?",
+              ],
+              s: 35000,
+              e: 46300,
+              timeList: [
+                {
+                  s: 35000,
+                  e: 35400,
+                },
+                {
+                  s: 35400,
+                  e: 35600,
+                },
+                {
+                  s: 35600,
+                  e: 36000,
+                },
+                {
+                  s: 36000,
+                  e: 37000,
+                },
+                {
+                  s: 37000,
+                  e: 37300,
+                },
+                {
+                  s: 37300,
+                  e: 37600,
+                },
+                {
+                  s: 37600,
+                  e: 37900,
+                },
+                {
+                  s: 38000,
+                  e: 38900,
+                },
+                {
+                  s: 39200,
+                  e: 39400,
+                },
+                {
+                  s: 39400,
+                  e: 39800,
+                },
+                {
+                  s: 39800,
+                  e: 40400,
+                },
+                {
+                  s: 40400,
+                  e: 40900,
+                },
+                {
+                  s: 40900,
+                  e: 41700,
+                },
+                {
+                  s: 41700,
+                  e: 41900,
+                },
+                {
+                  s: 41900,
+                  e: 42500,
+                },
+                {
+                  s: 42500,
+                  e: 42900,
+                },
+                {
+                  s: 42900,
+                  e: 43800,
+                },
+                {
+                  s: 43800,
+                  e: 44200,
+                },
+                {
+                  s: 44200,
+                  e: 44500,
+                },
+                {
+                  s: 44500,
+                  e: 44800,
+                },
+                {
+                  s: 44800,
+                  e: 45000,
+                },
+                {
+                  s: 45000,
+                  e: 45200,
+                },
+                {
+                  s: 45200,
+                  e: 45600,
+                },
+                {
+                  s: 45600,
+                  e: 46300,
+                },
+              ],
             },
             {
-                sentence:"With a lot of water in a cactus' body, a grown-up plant may weigh 6 tons or more. That's as heavy as an elephant!",
-                wordList:['With','a','lot','of','water','in','a',"cactus'","body,","a","grown-up","plant","may","weigh","6","tons","or","more.","That's","as","heavy","as","an","elephant!"]
+              sentence: "My bill is important. It helps me a lot.",
+              wordList: [
+                "My",
+                "bill",
+                "is",
+                "important.",
+                "It",
+                "helps",
+                "me",
+                "a",
+                "lot.",
+              ],
+              s: 48000,
+              e: 52000,
+              timeList: [
+                {
+                  s: 48000,
+                  e: 48400,
+                },
+                {
+                  s: 48400,
+                  e: 48700,
+                },
+                {
+                  s: 48700,
+                  e: 48900,
+                },
+                {
+                  s: 48900,
+                  e: 49900,
+                },
+                {
+                  s: 49900,
+                  e: 50200,
+                },
+                {
+                  s: 50200,
+                  e: 50800,
+                },
+                {
+                  s: 50800,
+                  e: 51100,
+                },
+                {
+                  s: 51100,
+                  e: 51400,
+                },
+                {
+                  s: 51400,
+                  e: 52000,
+                },
+              ],
             },
-            {
-                sentence:"With a lot of water in a cactus' body, a grown-up plant may weigh 6 tons or more. That's as heavy as an elephant!",
-                wordList:['With','a','lot','of','water','in','a',"cactus'","body,","a","grown-up","plant","may","weigh","6","tons","or","more.","That's","as","heavy","as","an","elephant!"]
-            }
-        ],
-        ed: undefined,
-        showEd: false, //是否看ed的值
-        curTime: 0, //单位s
-    }
+          ],
+        },
+        {
+          img: require("../../assets/f70b022cce193716cc091e5c8c54d6e5.jpg"),
+        },
+      ],
+      art_sound_url: require("../../assets/21hk_99_165420_1.mp3"),
+      activePage: 0, // 当前显示第几页
+      magazineVideoShow: false, // 讲解视频是否显示
+      mageazineDetailIndex: null, // 当前画刊高亮第几个
+      mageazineDetailShow: false,
+      fontSize: 32,
+      sentenceTheme: 0,
+      sentenceList: [
+        {
+          sentence:
+            "With a lot of water in a cactus' body, a grown-up plant may weigh 6 tons or more. That's as heavy as an elephant!",
+          wordList: [
+            "With",
+            "a",
+            "lot",
+            "of",
+            "water",
+            "in",
+            "a",
+            "cactus'",
+            "body,",
+            "a",
+            "grown-up",
+            "plant",
+            "may",
+            "weigh",
+            "6",
+            "tons",
+            "or",
+            "more.",
+            "That's",
+            "as",
+            "heavy",
+            "as",
+            "an",
+            "elephant!",
+          ],
+        },
+        {
+          sentence:
+            "With a lot of water in a cactus' body, a grown-up plant may weigh 6 tons or more. That's as heavy as an elephant!",
+          wordList: [
+            "With",
+            "a",
+            "lot",
+            "of",
+            "water",
+            "in",
+            "a",
+            "cactus'",
+            "body,",
+            "a",
+            "grown-up",
+            "plant",
+            "may",
+            "weigh",
+            "6",
+            "tons",
+            "or",
+            "more.",
+            "That's",
+            "as",
+            "heavy",
+            "as",
+            "an",
+            "elephant!",
+          ],
+        },
+        {
+          sentence:
+            "With a lot of water in a cactus' body, a grown-up plant may weigh 6 tons or more. That's as heavy as an elephant!",
+          wordList: [
+            "With",
+            "a",
+            "lot",
+            "of",
+            "water",
+            "in",
+            "a",
+            "cactus'",
+            "body,",
+            "a",
+            "grown-up",
+            "plant",
+            "may",
+            "weigh",
+            "6",
+            "tons",
+            "or",
+            "more.",
+            "That's",
+            "as",
+            "heavy",
+            "as",
+            "an",
+            "elephant!",
+          ],
+        },
+        {
+          sentence:
+            "With a lot of water in a cactus' body, a grown-up plant may weigh 6 tons or more. That's as heavy as an elephant!",
+          wordList: [
+            "With",
+            "a",
+            "lot",
+            "of",
+            "water",
+            "in",
+            "a",
+            "cactus'",
+            "body,",
+            "a",
+            "grown-up",
+            "plant",
+            "may",
+            "weigh",
+            "6",
+            "tons",
+            "or",
+            "more.",
+            "That's",
+            "as",
+            "heavy",
+            "as",
+            "an",
+            "elephant!",
+          ],
+        },
+      ],
+      ed: undefined,
+      showEd: false, //是否看ed的值
+      curTime: 0, //单位s
+      iss_name: "",
+      iss_no: 0,
+      picObj: {}, // 存放图片地址
+      soundObj: {}, //存放音频地址
+      videoObj: {}, //存放视频地址
+      pageIds: [],
+    };
   },
   //计算属性 类似于data概念
   computed: {},
@@ -326,216 +543,263 @@ export default {
   //方法集合
   methods: {
     // 翻页
-    handlePage(type){
-        if(type==='-'){
-            if(this.activePage>0){
-                this.activePage--
-                this.mageazineDetailIndex = null
-            }else{
-                this.$message.warning('已经是第一张')
-            }
-        }else{
-            if(this.activePage<this.magazineList.length-1){
-                this.activePage++
-                this.mageazineDetailIndex = null
-            }else{
-                this.$message.warning('已经是最后一张')
-            }
+    handlePage(type) {
+      if (type === "-") {
+        if (this.activePage > 0) {
+          this.activePage--;
+          this.mageazineDetailIndex = null;
+        } else {
+          this.$message.warning("已经是第一张");
         }
+      } else {
+        if (this.activePage < this.magazineList.length - 1) {
+          this.activePage++;
+          this.mageazineDetailIndex = null;
+        } else {
+          this.$message.warning("已经是最后一张");
+        }
+      }
     },
     // 讲解视频
-    handleVideo(){
-        this.magazineVideoShow = true
+    handleVideo() {
+      this.magazineVideoShow = true;
     },
     // 关闭视频
-    closeWord(){
-        this.magazineVideoShow = false
+    closeWord() {
+      this.magazineVideoShow = false;
     },
     // 切换画刊里面的卡片
-    handleChangePosition(index){
-        if(this.$refs.audioLine.audio.playing){
-            this.$refs.audioLine.PlayAudio()
-        }
-        this.mageazineDetailIndex = index
-        this.mageazineDetailShow = true
+    handleChangePosition(index) {
+      if (this.$refs.audioLine.audio.playing) {
+        this.$refs.audioLine.PlayAudio();
+      }
+      this.mageazineDetailIndex = index;
+      this.mageazineDetailShow = true;
     },
     // 关闭画刊卡片
-    closeMagazineSentence(){
-        this.mageazineDetailShow = false
+    closeMagazineSentence() {
+      this.mageazineDetailShow = false;
     },
     // 切换主题色和文字大小
-    changeTheme(theme,size){
-        if(theme!=='') this.sentenceTheme = theme
-        if(size) this.fontSize = size
-        
+    changeTheme(theme, size) {
+      if (theme !== "") this.sentenceTheme = theme;
+      if (size) this.fontSize = size;
     },
     getCurTime(curTime) {
-        this.curTime = curTime * 1000;  
-        for(let i=0; i<this.magazineList[this.activePage].sentenceList.length;i++){
-            if(this.curTime>=this.magazineList[this.activePage].sentenceList[i].s&&this.curTime<this.magazineList[this.activePage].sentenceList[i].e){
-                this.mageazineDetailIndex = i
-                break
-            }else{
-                this.mageazineDetailIndex = null
-            }
+      this.curTime = curTime * 1000;
+      for (
+        let i = 0;
+        i < this.magazineList[this.activePage].hotspots.length;
+        i++
+      ) {
+        if (
+          this.curTime >= this.magazineList[this.activePage].hotspots[i].s &&
+          this.curTime < this.magazineList[this.activePage].hotspots[i].e
+        ) {
+          this.mageazineDetailIndex = i;
+          break;
+        } else {
+          this.mageazineDetailIndex = null;
         }
-      
+      }
     },
     emptyEd(flag) {
       this.ed = undefined;
-      if(flag){
-        this.showEd = false
+      if (flag) {
+        this.showEd = false;
       }
     },
+    // 画刊信息
+    getIssueDetail() {
+      let MethodName = "/PaperServer/Client/PicIssue/GetIssueBriefInfo";
+      let data = {
+        id: this.$route.query.iss_id,
+      };
+      getLogin(MethodName, data)
+        .then((res) => {
+          if (res.status === 1) {
+            this.iss_no = res.data.iss_no;
+            this.iss_name = res.data.iss_name;
+          }
+        })
+        .catch(() => {});
+    },
+    getIssuePages() {
+      this.magazineList = [];
+      let MethodName = "/PaperServer/Client/PicIssue/GetPicIssueArticleContent";
+      let data = {
+        id: this.$route.query.iss_id,
+      };
+      getLogin(MethodName, data)
+        .then((res) => {
+          if (res.status === 1) {
+            this.pageIds = res.data.pageIds;
+            res.data.pageIds.forEach((item) => {
+              this.magazineList.push(res.data.pages[item]);
+            });
+          }
+        })
+        .catch(() => {});
+    },
   },
   //生命周期 - 创建完成(可以访问当前this实例)
   created() {
-    
+    this.getIssueDetail();
+    this.getIssuePages();
   },
   //生命周期 - 挂载完成(可以访问DOM元素)
-  mounted() {
-    
-  },
+  mounted() {},
   //生命周期-创建之前
-  beforeCreated() { },
+  beforeCreated() {},
   //生命周期-挂载之前
-  beforeMount() { },
+  beforeMount() {},
   //生命周期-更新之前
-  beforUpdate() { },
+  beforUpdate() {},
   //生命周期-更新之后
-  updated() { },
+  updated() {},
   //生命周期-销毁之前
-  beforeDestory() { },
+  beforeDestory() {},
   //生命周期-销毁完成
-  destoryed() { },
+  destoryed() {},
   //如果页面有keep-alive缓存功能,这个函数会触发
-  activated() { }
-}
+  activated() {},
+};
 </script>
 <style lang="scss" scoped>
 /* @import url(); 引入css类 */
-.magazine-inner{
-    padding-top: 96px;
-    .btn-box{
-        width: 1108px;
-        margin: 0 auto;
-        display: flex;
-        justify-content: space-between;
-        align-items: center;
-        .el-button{
-            width: 96px;
-            height: 32px;
-            padding: 0;
-            background: transparent;
-            border-color: #165DFF;
-            color: #165DFF;
-            font-weight: 400;
-            font-size: 14px;
-        }
-        .btn-left,.explain-video{
-            .svg-icon{
-                margin-right: 8px;
-            }
-        }
-        .btn-right{
-            .svg-icon{
-                margin-left: 8px;
-            }
-        }
-        .explain-video{
-            background: #FFB224;
-            border-color: #FFB224;
-            color: #FFFFFF;
-            width: 110px;
-        }
+.magazine-inner {
+  padding-top: 96px;
+  .btn-box {
+    width: 1108px;
+    margin: 0 auto;
+    display: flex;
+    justify-content: space-between;
+    align-items: center;
+    .el-button {
+      width: 96px;
+      height: 32px;
+      padding: 0;
+      background: transparent;
+      border-color: #165dff;
+      color: #165dff;
+      font-weight: 400;
+      font-size: 14px;
+    }
+    .btn-left,
+    .explain-video {
+      .svg-icon {
+        margin-right: 8px;
+      }
+    }
+    .btn-right {
+      .svg-icon {
+        margin-left: 8px;
+      }
+    }
+    .explain-video {
+      background: #ffb224;
+      border-color: #ffb224;
+      color: #ffffff;
+      width: 110px;
+    }
+  }
+
+  .magazine-box {
+    position: relative;
+    padding-top: 24px;
+    min-height: 820px;
+    width: 1108px;
+    margin: 0 auto;
+    .btn-left,
+    .btn-right {
+      position: absolute;
+      color: #175dff;
+      top: 50%;
+      margin-top: 24px;
+      left: -57px;
+      .svg-icon {
+        width: 48px;
+        height: 48px;
+      }
+    }
+    .btn-right {
+      left: auto;
+      right: -100px;
     }
-    .magazine-box{
+    .magazine {
+      background: #ffffff;
+      padding: 16px;
+      border: 1px solid #e5e6eb;
+      border-radius: 16px;
+      width: 1108px;
+      height: 783px;
+      position: absolute;
+      margin: 0 auto;
+      top: 24px;
+      left: 50%;
+      margin-left: -554px;
+      text-align: center;
+      overflow: hidden;
+      .img-box {
         position: relative;
-        padding-top: 24px;
-        min-height: 820px;
-        width: 1108px;
-        margin: 0 auto;
-        .btn-left,.btn-right{
-            position: absolute;
-            color: #175DFF;
-            top: 50%;
-            margin-top: 24px;
-            left: -57px;
-            .svg-icon{
-                width: 48px;
-                height: 48px;
-            }
-        }
-        .btn-right{
-            left: auto;
-            right: -100px;
+        width: 1075px;
+        height: 751px;
+      }
+      img {
+        width: 100%;
+        height: 100%;
+      }
+      .position-item {
+        position: absolute;
+        z-index: 1;
+        cursor: pointer;
+        border: 3px solid transparent;
+        &.active {
+          border-color: #ff1616;
         }
-        .magazine{
-            background: #FFFFFF;
-            padding: 16px;
-            border: 1px solid #E5E6EB;
-            border-radius: 16px;
-            width: 1108px;
-            height: 783px;
-            position: absolute;
-            margin: 0 auto;
-            top: 24px;
-            left: 50%;
-            margin-left: -554px;
-            text-align: center;
-            img{
-                max-width: 100%;
-                height: 100%;
-            }
-            .position-item{
-                position: absolute;
-                z-index: 1;
-                cursor: pointer;
-                border: 3px solid transparent;
-                &.active{
-                    border-color: #FF1616;
-                }
-                &:hover{
-                    border-color: #FF1616;
-                }
-            }
+        &:hover {
+          border-color: #ff1616;
         }
+      }
     }
+  }
 }
-.audio-box{
-    width: 500px;
-    display: flex;
-    align-items: center;
-    justify-content: space-between;
+.audio-box {
+  width: 1108px;
+  display: flex;
+  align-items: center;
+  justify-content: space-between;
+  margin: 16px auto 0 auto;
 }
-.aduioLine-box{
-    width: 516px;
-    height: 48px;
-    background: #FFFFFF;
-    border: 1px solid #EBEBEB;
-    border-radius: 30px;
-    display: flex;
-    align-items: center;
-    padding: 8px 24px;
-    .wrapper{
-        width: 24px;
-        height: 24px;
-        flex-shrink: 0;
-        color: #175DFF;
-        margin-left: 8px;
-    }
-    .Audio{
-        // width: 430px;
-    }
+.aduioLine-box {
+  width: 1108px;
+  height: 48px;
+  background: #ffffff;
+  border: 1px solid #ebebeb;
+  border-radius: 30px;
+  display: flex;
+  align-items: center;
+  padding: 8px 24px;
+  .wrapper {
+    width: 24px;
+    height: 24px;
+    flex-shrink: 0;
+    color: #175dff;
+    margin-left: 8px;
+  }
+  .Audio {
+    // width: 430px;
+  }
 }
 </style>
 <style lang="scss">
-.magazine-detail-dialog{
-    .el-dialog{
-        box-shadow: 0px 6px 30px 5px rgba(0, 0, 0, 0.05), 0px 16px 24px 2px rgba(0, 0, 0, 0.04), 0px 8px 10px -5px rgba(0, 0, 0, 0.08);
-        border-radius: 16px;
-        border: none;
-    }
-    
+.magazine-detail-dialog {
+  .el-dialog {
+    box-shadow: 0px 6px 30px 5px rgba(0, 0, 0, 0.05),
+      0px 16px 24px 2px rgba(0, 0, 0, 0.04),
+      0px 8px 10px -5px rgba(0, 0, 0, 0.08);
+    border-radius: 16px;
+    border: none;
+  }
 }
-</style>
+</style>

+ 1 - 1
src/views/search/searchDetail.vue

@@ -320,7 +320,7 @@ export default {
                   name: "全部",
                 },
               ];
-              this.gradeList = gradeList.concat(res.study_phase_list);
+              this.gradeList = gradeList.concat(res.data.exData.studyPhases);
             }
           }
         })