소스 검색

周五演示版 网页AI助教

zhuf 1 년 전
부모
커밋
d6254e8ffa

+ 1 - 1
index.html

@@ -1,5 +1,5 @@
 <!DOCTYPE html>
-<html lang="en">
+<html lang="zh-CN">
 
 <head>
   <meta charset="UTF-8">

+ 3 - 0
package.json

@@ -15,8 +15,11 @@
     "@element-plus/icons-vue": "^2.3.1",
     "@vueuse/core": "^9.13.0",
     "axios": "^0.27.2",
+    "crypto-js": "^4.2.0",
     "element-plus": "^2.3.3",
     "file-saver": "^2.0.5",
+    "lottie-web": "^5.12.2",
+    "marked": "^11.1.1",
     "pinia": "^2.0.35",
     "pinia-plugin-persist": "^1.0.0",
     "qrcode.vue": "^3.4.1",

+ 27 - 0
pnpm-lock.yaml

@@ -1,5 +1,9 @@
 lockfileVersion: '6.0'
 
+settings:
+  autoInstallPeers: true
+  excludeLinksFromLockfile: false
+
 dependencies:
   '@element-plus/icons-vue':
     specifier: ^2.3.1
@@ -10,12 +14,21 @@ dependencies:
   axios:
     specifier: ^0.27.2
     version: registry.npmmirror.com/axios@0.27.2
+  crypto-js:
+    specifier: ^4.2.0
+    version: 4.2.0
   element-plus:
     specifier: ^2.3.3
     version: registry.npmmirror.com/element-plus@2.3.3(vue@3.2.47)
   file-saver:
     specifier: ^2.0.5
     version: registry.npmmirror.com/file-saver@2.0.5
+  lottie-web:
+    specifier: ^5.12.2
+    version: 5.12.2
+  marked:
+    specifier: ^11.1.1
+    version: 11.1.1
   pinia:
     specifier: ^2.0.35
     version: 2.0.35(typescript@4.9.5)(vue@3.2.47)
@@ -1943,6 +1956,10 @@ packages:
       which: registry.npmmirror.com/which@2.0.2
     dev: true
 
+  /crypto-js@4.2.0:
+    resolution: {integrity: sha512-KALDyEYgpY+Rlob/iriUtjV6d5Eq+Y191A5g4UqLAi8CyGP9N1+FdVbkc1SxKc2r4YAYqG8JzO2KGL+AizD70Q==}
+    dev: false
+
   /cssesc@3.0.0:
     resolution: {integrity: sha512-/Tb/JcjK111nNScGob5MNtsntNM1aCNUDipB/TkwZFhyDrrE47SOx/18wF2bbjgc3ZzCSKW1T5nt5EbFoAz/Vg==}
     engines: {node: '>=4'}
@@ -3487,6 +3504,10 @@ packages:
     resolution: {integrity: sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==}
     dev: true
 
+  /lottie-web@5.12.2:
+    resolution: {integrity: sha512-uvhvYPC8kGPjXT3MyKMrL3JitEAmDMp30lVkuq/590Mw9ok6pWcFCwXJveo0t5uqYw1UREQHofD+jVpdjBv8wg==}
+    dev: false
+
   /loupe@2.3.6:
     resolution: {integrity: sha512-RaPMZKiMy8/JruncMU5Bt6na1eftNoo++R4Y+N2FrxkDVTrGvcyzFTsaGif4QTeKESheMGegbhw6iUAq+5A8zA==}
     dependencies:
@@ -3556,6 +3577,12 @@ packages:
       - supports-color
     dev: true
 
+  /marked@11.1.1:
+    resolution: {integrity: sha512-EgxRjgK9axsQuUa/oKMx5DEY8oXpKJfk61rT5iY3aRlgU6QJtUcxU5OAymdhCvWvhYcd9FKmO5eQoX8m9VGJXg==}
+    engines: {node: '>= 18'}
+    hasBin: true
+    dev: false
+
   /md5-hex@3.0.1:
     resolution: {integrity: sha512-BUiRtTtV39LIJwinWBjqVsU9xhdnz7/i889V859IBFpuqGAj6LuOvHv5XLbgZ2R7ptJoJaEcxkv88/h25T7Ciw==}
     engines: {node: '>=8'}

BIN
src/assets/bot.jpg


BIN
src/components/chat-bot/audio/哪些学习的记忆方法较好.mp3


BIN
src/components/chat-bot/audio/如何培养良好的学习习惯.mp3


BIN
src/components/chat-bot/audio/如何锻炼英语口语的发音.mp3


+ 162 - 0
src/components/chat-bot/index.vue

@@ -0,0 +1,162 @@
+<script setup lang='ts'>
+// import lottie from 'lottie-web'
+// import animationData from './robot.json'
+import { Microphone } from '@element-plus/icons-vue'
+import placeImg from './place.png'
+import { qa_audio, qa_text } from './qa.ts'
+
+// const anim = ref(null)
+
+// onMounted(() => {
+//   lottie.loadAnimation({
+//     container: anim.value,
+//     renderer: 'svg',
+//     loop: true,
+//     autoplay: true,
+//     animationData,
+//   })
+// })
+
+const videoRef = ref<HTMLVideoElement>()
+
+function startVideoPlay() {
+  console.log('startVideoPlay')
+  videoRef.value!.play()
+}
+function pauseVideoPlay() {
+  console.log('pauseVideoPlay')
+  videoRef.value!.pause()
+  videoRef.value!.currentTime = 0
+}
+
+const ifDrawer = ref(false)
+function openDrawer() {
+  ifDrawer.value = true
+}
+
+const scrollbarRef = ref()
+
+const chatList = ref<any[]>([])
+
+const questionInput = ref('')
+
+const audioEl = new Audio()
+audioEl.addEventListener('ended', () => {
+  pauseVideoPlay()
+})
+
+function handleSendMessage(q?: string, isInput?: boolean) {
+  if (isInput)
+    return
+  if (!q)
+    return
+  const t = Date.now()
+  chatList.value.push({
+    left: false,
+    name: '我',
+    d: encodeURIComponent(q),
+    t,
+  })
+  questionInput.value = ''
+  setTimeout(() => {
+    const answer = {
+      left: true,
+      name: 'AI助教',
+      d: '',
+      t: t + 1,
+    }
+    const i = chatList.value.push(answer)
+    nextTick(() => {
+      scrollbarRef.value.setScrollTop(99999999)
+    })
+    startVideoPlay()
+    const fullAnswer = qa_text[q].replace(/(\r\n|\n|\r)/gm, '<br />') ?? ''
+    const fullAnswerList = fullAnswer.match(/.{1,3}/g) ?? []
+    const answerAudio = qa_audio[q]
+    if (answerAudio) {
+      audioEl.src = answerAudio
+      audioEl.play()
+    }
+    const timer = setInterval(() => {
+      if (fullAnswerList.length === 0) {
+        clearInterval(timer)
+        // pauseVideoPlay()
+        return
+      }
+      const item = fullAnswerList!.shift()
+      chatList.value[i - 1].d += encodeURIComponent(item)
+      nextTick(() => {
+        scrollbarRef.value.setScrollTop(99999999)
+      })
+    }, 100)
+  }, 1000)
+}
+
+const optionInputs = [
+  '如何培养良好的学习习惯',
+  '如何锻炼英语口语的发音',
+  '哪些学习的记忆方法较好',
+]
+</script>
+
+<template>
+  <div
+    class="fixed bottom-200px right-40px h-200px w-200px flex cursor-pointer items-center justify-center"
+    @click="openDrawer"
+  >
+    <!-- <div ref="anim" /> -->
+    <img :src="placeImg" alt="">
+  </div>
+  <el-drawer
+    v-model="ifDrawer" direction="rtl" append-to-body :size="800" title="AI助教" :z-index="201"
+    style="background-color: #f0f0f0;"
+    class="no-mb"
+  >
+    <div class="flex">
+      <div class="h-820px w-400px">
+        <video
+          ref="videoRef" src="https://ossdownload.bozedu.net/static/webm/preview.webm "
+          class="h-full flex items-center justify-center" loop muted
+        />
+      </div>
+      <div class="w-360px flex flex-col justify-between rounded bg-white px-10px py-10px">
+        <el-scrollbar ref="scrollbarRef" height="680px" class="px-14px">
+          <div class="flex flex-col gap-4">
+            <div class="rounded-4px bg-hex-f0f0f0 p-14px text-gray-500">
+              <div class="mb-10px text-xs">
+                您可以试着问我:
+              </div>
+              <ul class="space-y-3">
+                <li
+                  v-for="item in optionInputs" :key="item"
+                  class="h-32px flex cursor-pointer items-center justify-between rounded-16px bg-white px-18px text-12px leading-32px text-black"
+                  @click="handleSendMessage(item)"
+                >
+                  {{ item }}
+                </li>
+              </ul>
+            </div>
+            <info-item v-for="item in chatList" :key="item.t" :left="item.left" :name="item.name" :d="item.d" />
+          </div>
+        </el-scrollbar>
+        <div class="flex items-start justify-between space-x-14px">
+          <div class="h-32px w-32px flex flex-none cursor-pointer items-center justify-center rounded-16px bg-[#626aef] text-white">
+            <Microphone class="h-20px w-20px" />
+          </div>
+
+          <el-input
+            v-model="questionInput" disabled size="large" type="textarea" placeholder="请输入您的问题"
+            :autosize="{ minRows: 1, maxRows: 4 }"
+          />
+          <el-button color="#626aef" @click="handleSendMessage(questionInput, true)">
+            发送
+          </el-button>
+        </div>
+      </div>
+    </div>
+  </el-drawer>
+</template>
+
+<style>
+.no-mb .el-drawer__header{margin-bottom: 0px;}
+</style>

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 290 - 0
src/components/chat-bot/indey.vue


+ 60 - 0
src/components/chat-bot/info-item.vue

@@ -0,0 +1,60 @@
+<script setup lang="ts">
+import { marked } from 'marked'
+
+const props = defineProps<{
+  left: boolean
+  name?: string
+  d: any
+}>()
+
+const showMsg = $computed(() => marked(decodeURIComponent(props.d!)))
+</script>
+
+<template>
+  <div class="w-full text-dark-400" :class="left ? 'left' : 'right'">
+    <div class="r_flex-row-reverse flex items-end gap-4">
+      <div>{{ name }}</div>
+    </div>
+    <div class="r_flex-row-reverse mt-2 flex">
+      <div
+        class="text_wrapper max-w-284px min-h-44px min-w-50px rounded-3xl bg-white px-14px py-10px"
+        v-html="showMsg"
+      />
+    </div>
+  </div>
+</template>
+
+<style scoped lang="scss">
+.text_wrapper  {
+  margin: 0;
+  padding: 10px;
+  word-wrap: break-word;
+  overflow-wrap: break-word;
+  // word-break: break-all;
+
+  img{
+    display: inline-block;
+    vertical-align: bottom;
+    margin: 0 2px;
+  }
+}
+
+.left {
+  .text_wrapper {
+    border-radius: 2px 24px 24px 24px;
+    background-color: beige;
+  }
+}
+
+.right {
+  .r_flex-row-reverse {
+    flex-direction: row-reverse;
+  }
+
+  .text_wrapper {
+    background-color: #397FF6;
+    color: white;
+    border-radius: 24px 2px 24px 24px;
+  }
+}
+</style>

BIN
src/components/chat-bot/place.png


+ 33 - 0
src/components/chat-bot/qa.ts

@@ -0,0 +1,33 @@
+import audio1 from './audio/如何培养良好的学习习惯.mp3'
+import audio2 from './audio/如何锻炼英语口语的发音.mp3'
+import audio3 from './audio/哪些学习的记忆方法较好.mp3'
+
+export const qa_text = {
+  如何培养良好的学习习惯: `培养良好的学习习惯是一个逐步的过程,需要时间和持续的努力。以下是一些帮助你培养良好学习习惯的建议:
+  1、设定明确的目标:确定你想要达成的学习目标,并将它们分解成小的、可管理的任务。
+  2、制定学习计划:为你的学习活动制定时间表,包括每天的学习时间和休息时间。坚持这个计划可以帮助你建立例行公事。
+  3、创建适宜的学习环境:找到一个安静、整洁、光线充足的地方进行学习。确保你的学习空间舒适且有利于集中注意力。
+  4、消除干扰:在学习时关闭手机、电视和其他可能分散你注意力的电子设备。
+  通过持续实践这些策略,你可以逐渐培养出良好的学习习惯,从而提高学习效率和成绩。`,
+
+  如何锻炼英语口语的发音: `锻炼英语口语的发音需要系统的训练和大量的实践。以下是一些可以帮助你提高英语口语发音的方法:
+  1. 听力训练:多听英语原声材料,如电影、电视剧、播客、新闻和TED演讲等。注意模仿发音和语调。
+  2. 跟读练习:选择一段录音材料,听一遍后尝试跟读,模仿发音、语调和节奏。可以使用影视剧中的对话或者听力材料进行练习。
+  3. 发音练习:专注于单个音标的发音练习,可以使用专门的语音教程或者应用程序来学习不同音标的正确发音。
+  4. 口型和舌位:了解并练习正确的口型和舌位,这对于准确发音非常重要。
+  记住,每个人的学习速度都不一样,不要和别人比较,专注于自己的进步。通过不断的练习和实践,英语口语发音会逐渐提高。`,
+
+  哪些学习的记忆方法较好: `学习的记忆方法很多,而不同的方法适合不同的人。一些广为接受且效果较好的记忆方法包括:
+  1. 艾宾浩斯遗忘曲线 : 使用时间间隔重复的方法来加强记忆,比如在学习后的20分钟、1小时、1天、2天、1周等时点复习材料。
+  2. 费曼技巧 : 以简单的语言教授给他人,通过教学的过程来理解和记忆复杂的概念。
+  3. 联想记忆法 : 将新信息与已知的信息建立联系,例如使用故事、图像或感觉等来帮助记忆。
+  4. 分布式练习 : 把学习时间分散到几天或几周,而不是集中在一次长时间的学习上。
+  总之,这些方法并不是相互排斥的,而是可以结合起来使用,以达到最佳的学习效果。实践和经验会告诉你哪些方法最适合你的学习风格。`,
+
+} as { [key: string]: string }
+
+export const qa_audio = {
+  如何培养良好的学习习惯: audio1,
+  如何锻炼英语口语的发音: audio2,
+  哪些学习的记忆方法较好: audio3,
+}

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 1 - 0
src/components/chat-bot/robot.json


+ 289 - 132
src/pages/frontpage/homePage/index.vue

@@ -7,7 +7,7 @@ let videosData = $ref({
 request({
   baseURL: window.GLOBAL_CONFIG.api,
   url: '/aimooc/spjj/main',
-}).then(res => {
+}).then((res) => {
   videosData = res.data
 })
 
@@ -18,9 +18,10 @@ function viewMore() {
 
 function goDetail(item) {
   router.push({
-    path: '/frontpage/videoDetail', query: {
-      as_id: item.as_id
-    }
+    path: '/frontpage/videoDetail',
+    query: {
+      as_id: item.as_id,
+    },
   })
 }
 </script>
@@ -28,70 +29,110 @@ function goDetail(item) {
 <template>
   <div style="display: flex;height: 500px;">
     <div style="width: 50%;height: 100%;">
-      <div style="background-color: #f7f6fb;height: 230px;width: 50%;margin-top: 10%;"></div>
-    </div>
-    <div style="width: 50%;height: 100%;background-color: #f7f6fb;">
-
+      <div style="background-color: #f7f6fb;height: 230px;width: 50%;margin-top: 10%;" />
     </div>
+    <div style="width: 50%;height: 100%;background-color: #f7f6fb;" />
   </div>
   <div style="height: 700px;max-height:700px;margin-top: -500px;">
     <div style="display: flex;justify-content: center;width: 100%;padding: 40px 0px">
-      <img src="../../../assets/divider.png" style="width: 1200px;" />
+      <img src="../../../assets/divider.png" style="width: 1200px;">
     </div>
     <div style="display: flex;width: 100%;">
       <div style="width: 900px;margin-left: calc((100% - 1200px)/2);">
         <div style="display: flex;margin-top: 60px;">
-          <div v-if="videosData.videos_one[0]" @click="goDetail(videosData.videos_one[0])"
-            style="width: 300px;padding: 0 5px;cursor: pointer;">
-            <el-image :src="videosData.videos_one[0].as_img"
-              style="width: 100%;border-radius: 12px;width: 290px;height: 188px;" />
-            <div style="font-size: 15px;font-weight: Medium;">{{ videosData.videos_one[0].as_title }}</div>
+          <div
+            v-if="videosData.videos_one[0]" style="width: 300px;padding: 0 5px;cursor: pointer;"
+            @click="goDetail(videosData.videos_one[0])"
+          >
+            <el-image
+              :src="videosData.videos_one[0].as_img"
+              style="width: 100%;border-radius: 12px;width: 290px;height: 188px;"
+            />
+            <div style="font-size: 15px;font-weight: Medium;">
+              {{ videosData.videos_one[0].as_title }}
+            </div>
           </div>
-          <div v-if="videosData.videos_one[1]" @click="goDetail(videosData.videos_one[1])"
-            style="width: 300px;padding: 0 5px;cursor: pointer;">
-            <el-image :src="videosData.videos_one[1].as_img"
-              style="width: 100%;border-radius: 12px;width: 290px;height: 188px;" />
-            <div style="font-size: 15px;font-weight: Medium;">{{ videosData.videos_one[1].as_title }}</div>
+          <div
+            v-if="videosData.videos_one[1]" style="width: 300px;padding: 0 5px;cursor: pointer;"
+            @click="goDetail(videosData.videos_one[1])"
+          >
+            <el-image
+              :src="videosData.videos_one[1].as_img"
+              style="width: 100%;border-radius: 12px;width: 290px;height: 188px;"
+            />
+            <div style="font-size: 15px;font-weight: Medium;">
+              {{ videosData.videos_one[1].as_title }}
+            </div>
           </div>
-          <div v-if="videosData.videos_one[2]" @click="goDetail(videosData.videos_one[2])"
-            style="width: 300px;padding: 0 5px;cursor: pointer;">
-            <el-image :src="videosData.videos_one[2].as_img"
-              style="width: 100%;border-radius: 12px;width: 290px;height: 188px;" />
-            <div style="font-size: 15px;font-weight: Medium;">{{ videosData.videos_one[2].as_title }}</div>
+          <div
+            v-if="videosData.videos_one[2]" style="width: 300px;padding: 0 5px;cursor: pointer;"
+            @click="goDetail(videosData.videos_one[2])"
+          >
+            <el-image
+              :src="videosData.videos_one[2].as_img"
+              style="width: 100%;border-radius: 12px;width: 290px;height: 188px;"
+            />
+            <div style="font-size: 15px;font-weight: Medium;">
+              {{ videosData.videos_one[2].as_title }}
+            </div>
           </div>
         </div>
       </div>
       <div style="width: 300px;background-color: #9f93cd;height: 300px;">
         <div style="display: flex;flex-direction: column;justify-content: center;height: 100%;">
-          <div style="color: white;font-size: 30px;font-weight: Medium;text-align: center;">精品课程</div>
-          <div style="color: #c5c3da;font-size: 40px;font-weight: bold;text-align: center;">PREMIUM</div>
-          <div style="color: #c5c3da;font-size: 40px;font-weight: bold;text-align: center;">COURSES</div>
-          <div style="color: white;cursor: pointer;text-align: center;" @click="viewMore()">查看更多 》</div>
+          <div style="color: white;font-size: 30px;font-weight: Medium;text-align: center;">
+            精品课程
+          </div>
+          <div style="color: #c5c3da;font-size: 40px;font-weight: bold;text-align: center;">
+            PREMIUM
+          </div>
+          <div style="color: #c5c3da;font-size: 40px;font-weight: bold;text-align: center;">
+            COURSES
+          </div>
+          <div style="color: white;cursor: pointer;text-align: center;" @click="viewMore()">
+            查看更多 》
+          </div>
         </div>
       </div>
-      <div style="width: calc((100% - 1200px)/2);background-color: #9f93cd;height: 300px;"></div>
+      <div style="width: calc((100% - 1200px)/2);background-color: #9f93cd;height: 300px;" />
     </div>
     <div>
       <div style="display: flex;width: 1200px;margin-left: calc((100% - 1200px)/2);margin-top: 30px;">
-        <div v-if="videosData.videos_one[3]" style="width: 300px;padding: 0 5px;cursor: pointer;"
-          @click="goDetail(videosData.videos_one[3])">
+        <div
+          v-if="videosData.videos_one[3]" style="width: 300px;padding: 0 5px;cursor: pointer;"
+          @click="goDetail(videosData.videos_one[3])"
+        >
           <el-image :src="videosData.videos_one[3].as_img" style="border-radius: 12px;width: 290px;height: 188px;" />
-          <div style="font-size: 15px;font-weight: Medium;">{{ videosData.videos_one[3].as_title }}</div>
+          <div style="font-size: 15px;font-weight: Medium;">
+            {{ videosData.videos_one[3].as_title }}
+          </div>
         </div>
-        <div v-if="videosData.videos_one[4]" style="width: 300px;padding: 0 5px;cursor: pointer;"
-          @click="goDetail(videosData.videos_one[4])">
+        <div
+          v-if="videosData.videos_one[4]" style="width: 300px;padding: 0 5px;cursor: pointer;"
+          @click="goDetail(videosData.videos_one[4])"
+        >
           <el-image :src="videosData.videos_one[4].as_img" style="border-radius: 12px;width: 290px;height: 188px;" />
-          <div style="font-size: 15px;font-weight: Medium;">{{ videosData.videos_one[4].as_title }}</div>
+          <div style="font-size: 15px;font-weight: Medium;">
+            {{ videosData.videos_one[4].as_title }}
+          </div>
         </div>
-        <div v-if="videosData.videos_one[5]" style="width: 300px;padding: 0 5px;cursor: pointer;"
-          @click="goDetail(videosData.videos_one[5])">
+        <div
+          v-if="videosData.videos_one[5]" style="width: 300px;padding: 0 5px;cursor: pointer;"
+          @click="goDetail(videosData.videos_one[5])"
+        >
           <el-image :src="videosData.videos_one[5].as_img" style="border-radius: 12px;width: 290px;height: 188px;" />
-          <div style="font-size: 15px;font-weight: Medium;">{{ videosData.videos_one[5].as_title }}</div>
+          <div style="font-size: 15px;font-weight: Medium;">
+            {{ videosData.videos_one[5].as_title }}
+          </div>
         </div>
-        <div v-if="videosData.videos_one[6]" style="width: 300px;padding: 0 5px;cursor: pointer;"
-          @click="goDetail(videosData.videos_one[6])">
+        <div
+          v-if="videosData.videos_one[6]" style="width: 300px;padding: 0 5px;cursor: pointer;"
+          @click="goDetail(videosData.videos_one[6])"
+        >
           <el-image :src="videosData.videos_one[6].as_img" style="border-radius: 12px;width: 290px;height: 188px;" />
-          <div style="font-size: 15px;font-weight: Medium;">{{ videosData.videos_one[6].as_title }}</div>
+          <div style="font-size: 15px;font-weight: Medium;">
+            {{ videosData.videos_one[6].as_title }}
+          </div>
         </div>
       </div>
     </div>
@@ -99,62 +140,102 @@ function goDetail(item) {
 
   <div style="height: 600px;">
     <div style="display: flex;justify-content: center;width: 100%;padding: 40px 0px">
-      <img src="../../../assets/divider.png" style="width: 1200px;" />
+      <img src="../../../assets/divider.png" style="width: 1200px;">
     </div>
     <div style="width: 100%;">
       <div style="width: 1200px;display: flex;margin-left: calc((100% - 1200px)/2);">
-        <div v-if="videosData.videos_two[0]" style="width: 400px;padding: 0 5px;cursor: pointer;"
-          @click="goDetail(videosData.videos_two[0])">
-          <img src="../../../assets/champion.png" class="cornerMarkImg" />
+        <div
+          v-if="videosData.videos_two[0]" style="width: 400px;padding: 0 5px;cursor: pointer;"
+          @click="goDetail(videosData.videos_two[0])"
+        >
+          <img src="../../../assets/champion.png" class="cornerMarkImg">
           <div class="cornerMark" style="background-color: #f2dc8c;margin-top: -3px;">
-            1</div>
-          <el-image :src="videosData.videos_two[0].as_img"
-            style="border-radius: 12px;width: 390px;height: 253px;margin-top: -40px;" />
-          <div style="font-size: 15px;font-weight: Medium;">{{ videosData.videos_two[0].as_title }}</div>
+            1
+          </div>
+          <el-image
+            :src="videosData.videos_two[0].as_img"
+            style="border-radius: 12px;width: 390px;height: 253px;margin-top: -40px;"
+          />
+          <div style="font-size: 15px;font-weight: Medium;">
+            {{ videosData.videos_two[0].as_title }}
+          </div>
         </div>
-        <div v-if="videosData.videos_two[1]" style="width: 400px;padding: 0 5px;cursor: pointer;"
-          @click="goDetail(videosData.videos_two[1])">
-          <img src="../../../assets/secondWinner.png" class="cornerMarkImg" />
+        <div
+          v-if="videosData.videos_two[1]" style="width: 400px;padding: 0 5px;cursor: pointer;"
+          @click="goDetail(videosData.videos_two[1])"
+        >
+          <img src="../../../assets/secondWinner.png" class="cornerMarkImg">
           <div class="cornerMark" style="background-color: #d7d8d8;margin-top: -3px;">
-            2</div>
-          <el-image :src="videosData.videos_two[1].as_img"
-            style="border-radius: 12px;width: 390px;height: 253px;margin-top: -40px;" />
-          <div style="font-size: 15px;font-weight: Medium;">{{ videosData.videos_two[1].as_title }}</div>
+            2
+          </div>
+          <el-image
+            :src="videosData.videos_two[1].as_img"
+            style="border-radius: 12px;width: 390px;height: 253px;margin-top: -40px;"
+          />
+          <div style="font-size: 15px;font-weight: Medium;">
+            {{ videosData.videos_two[1].as_title }}
+          </div>
         </div>
-        <div v-if="videosData.videos_two[2]" style="width: 400px;padding: 0 5px;cursor: pointer;"
-          @click="goDetail(videosData.videos_two[2])">
-          <img src="../../../assets/thirdWinner.png" class="cornerMarkImg" />
+        <div
+          v-if="videosData.videos_two[2]" style="width: 400px;padding: 0 5px;cursor: pointer;"
+          @click="goDetail(videosData.videos_two[2])"
+        >
+          <img src="../../../assets/thirdWinner.png" class="cornerMarkImg">
           <div class="cornerMark" style="background-color: #ff4f32;margin-top: -3px;">
-            3</div>
-          <el-image :src="videosData.videos_two[2].as_img"
-            style="border-radius: 12px;width: 390px;height: 253px;margin-top: -40px;" />
-          <div style="font-size: 15px;font-weight: Medium;">{{ videosData.videos_two[2].as_title }}</div>
+            3
+          </div>
+          <el-image
+            :src="videosData.videos_two[2].as_img"
+            style="border-radius: 12px;width: 390px;height: 253px;margin-top: -40px;"
+          />
+          <div style="font-size: 15px;font-weight: Medium;">
+            {{ videosData.videos_two[2].as_title }}
+          </div>
         </div>
       </div>
       <div style="display: flex;margin-top: 30px;">
         <div
-          style="background-color: #9f93cd;height: 220px;width: calc((100% - 1200px)/2 + 600px);display: flex;justify-content: flex-end;">
+          style="background-color: #9f93cd;height: 220px;width: calc((100% - 1200px)/2 + 600px);display: flex;justify-content: flex-end;"
+        >
           <div style="width: 600px;height: 220px;display: flex;flex-direction: column;justify-content: center;">
-            <div style="color: white;font-size: 30px;font-weight: Medium;text-align: center;">热视频排名</div>
-            <div style="color: #c5c3da;font-size: 40px;font-weight: bold;text-align: center;">HOT VIDEO RANKING</div>
+            <div style="color: white;font-size: 30px;font-weight: Medium;text-align: center;">
+              热视频排名
+            </div>
+            <div style="color: #c5c3da;font-size: 40px;font-weight: bold;text-align: center;">
+              HOT VIDEO RANKING
+            </div>
           </div>
         </div>
         <div style="display: flex;">
-          <div v-if="videosData.videos_two[3]" style="width: 300px;padding: 0 5px;cursor: pointer;"
-            @click="goDetail(videosData.videos_two[3])">
+          <div
+            v-if="videosData.videos_two[3]" style="width: 300px;padding: 0 5px;cursor: pointer;"
+            @click="goDetail(videosData.videos_two[3])"
+          >
             <div class="cornerMark" style="background-color: #ff8d7a;">
-              4</div>
-            <el-image :src="videosData.videos_two[3].as_img"
-              style="border-radius: 12px;width: 290px;height: 188px;margin-top: -40px;" />
-            <div style="font-size: 15px;font-weight: Medium;">{{ videosData.videos_two[0].as_title }}</div>
+              4
+            </div>
+            <el-image
+              :src="videosData.videos_two[3].as_img"
+              style="border-radius: 12px;width: 290px;height: 188px;margin-top: -40px;"
+            />
+            <div style="font-size: 15px;font-weight: Medium;">
+              {{ videosData.videos_two[0].as_title }}
+            </div>
           </div>
-          <div v-if="videosData.videos_two[4]" style="width: 300px;padding: 0 5px;cursor: pointer;"
-            @click="goDetail(videosData.videos_two[4])">
+          <div
+            v-if="videosData.videos_two[4]" style="width: 300px;padding: 0 5px;cursor: pointer;"
+            @click="goDetail(videosData.videos_two[4])"
+          >
             <div class="cornerMark" style="background-color: #ff8d7a;">
-              5</div>
-            <el-image :src="videosData.videos_two[4].as_img"
-              style="border-radius: 12px;width: 290px;height: 188px;margin-top: -40px;" />
-            <div style="font-size: 15px;font-weight: Medium;">{{ videosData.videos_two[0].as_title }}</div>
+              5
+            </div>
+            <el-image
+              :src="videosData.videos_two[4].as_img"
+              style="border-radius: 12px;width: 290px;height: 188px;margin-top: -40px;"
+            />
+            <div style="font-size: 15px;font-weight: Medium;">
+              {{ videosData.videos_two[0].as_title }}
+            </div>
           </div>
         </div>
       </div>
@@ -162,95 +243,171 @@ function goDetail(item) {
   </div>
   <div>
     <div style="display: flex;justify-content: center;width: 100%;padding: 40px 0px">
-      <img src="../../../assets/divider.png" style="width: 1200px;" />
+      <img src="../../../assets/divider.png" style="width: 1200px;">
     </div>
     <div style="width: 1200px;margin: auto;display: flex;">
-      <div v-if="videosData.videos_three[0]" style="width: 400px;padding: 0 5px;cursor: pointer;"
-        @click="goDetail(videosData.videos_three[0])">
-        <img src="../../../assets/champion.png" class="cornerMarkImg" />
+      <div
+        v-if="videosData.videos_three[0]" style="width: 400px;padding: 0 5px;cursor: pointer;"
+        @click="goDetail(videosData.videos_three[0])"
+      >
+        <img src="../../../assets/champion.png" class="cornerMarkImg">
         <div class="cornerMark" style="background-color: #f2dc8c;margin-top: -3px;">
-          1</div>
-        <el-image :src="videosData.videos_three[0].as_img"
-          style="width: 390px;height: 253px;border-radius: 12px;margin-top: -40px;" />
-        <div style="font-size: 15px;font-weight: Medium;">{{ videosData.videos_three[0].as_title }}</div>
+          1
+        </div>
+        <el-image
+          :src="videosData.videos_three[0].as_img"
+          style="width: 390px;height: 253px;border-radius: 12px;margin-top: -40px;"
+        />
+        <div style="font-size: 15px;font-weight: Medium;">
+          {{ videosData.videos_three[0].as_title }}
+        </div>
       </div>
-      <div v-if="videosData.videos_three[1]" style="width: 400px;padding: 0 5px;cursor: pointer;"
-        @click="goDetail(videosData.videos_three[1])">
-        <img src="../../../assets/secondWinner.png" class="cornerMarkImg" />
+      <div
+        v-if="videosData.videos_three[1]" style="width: 400px;padding: 0 5px;cursor: pointer;"
+        @click="goDetail(videosData.videos_three[1])"
+      >
+        <img src="../../../assets/secondWinner.png" class="cornerMarkImg">
         <div class="cornerMark" style="background-color: #d7d8d8;margin-top: -3px;">
-          2</div>
-        <el-image :src="videosData.videos_three[1].as_img"
-          style="width: 390px;height: 253px;border-radius: 12px;margin-top: -40px;" />
-        <div style="font-size: 15px;font-weight: Medium;">{{ videosData.videos_three[1].as_title }}</div>
+          2
+        </div>
+        <el-image
+          :src="videosData.videos_three[1].as_img"
+          style="width: 390px;height: 253px;border-radius: 12px;margin-top: -40px;"
+        />
+        <div style="font-size: 15px;font-weight: Medium;">
+          {{ videosData.videos_three[1].as_title }}
+        </div>
       </div>
-      <div v-if="videosData.videos_three[2]" style="width: 400px;padding: 0 5px;cursor: pointer;"
-        @click="goDetail(videosData.videos_three[2])">
-        <img src="../../../assets/thirdWinner.png" class="cornerMarkImg" />
+      <div
+        v-if="videosData.videos_three[2]" style="width: 400px;padding: 0 5px;cursor: pointer;"
+        @click="goDetail(videosData.videos_three[2])"
+      >
+        <img src="../../../assets/thirdWinner.png" class="cornerMarkImg">
         <div class="cornerMark" style="background-color: #ff4f32;margin-top: -3px;">
-          3</div>
-        <el-image :src="videosData.videos_three[2].as_img"
-          style="width: 390px;height: 253px;border-radius: 12px;margin-top: -40px;" />
-        <div style="font-size: 15px;font-weight: Medium;">{{ videosData.videos_three[2].as_title }}</div>
+          3
+        </div>
+        <el-image
+          :src="videosData.videos_three[2].as_img"
+          style="width: 390px;height: 253px;border-radius: 12px;margin-top: -40px;"
+        />
+        <div style="font-size: 15px;font-weight: Medium;">
+          {{ videosData.videos_three[2].as_title }}
+        </div>
       </div>
     </div>
     <div style="width: 1200px;margin:auto;display: flex;margin-top: 30px;">
-      <div v-if="videosData.videos_three[3]" style="width: 300px;padding: 0 5px;cursor: pointer;"
-        @click="goDetail(videosData.videos_three[3])">
+      <div
+        v-if="videosData.videos_three[3]" style="width: 300px;padding: 0 5px;cursor: pointer;"
+        @click="goDetail(videosData.videos_three[3])"
+      >
         <div class="cornerMark" style="background-color: #ff8d7a;">
-          4</div>
-        <el-image :src="videosData.videos_three[3].as_img"
-          style="width: 290px;height: 188px;border-radius: 12px;margin-top: -40px;" />
-        <div style="font-size: 15px;font-weight: Medium;">{{ videosData.videos_three[0].as_title }}</div>
+          4
+        </div>
+        <el-image
+          :src="videosData.videos_three[3].as_img"
+          style="width: 290px;height: 188px;border-radius: 12px;margin-top: -40px;"
+        />
+        <div style="font-size: 15px;font-weight: Medium;">
+          {{ videosData.videos_three[0].as_title }}
+        </div>
       </div>
-      <div v-if="videosData.videos_three[4]" style="width: 300px;padding: 0 5px;cursor: pointer;"
-        @click="goDetail(videosData.videos_three[4])">
+      <div
+        v-if="videosData.videos_three[4]" style="width: 300px;padding: 0 5px;cursor: pointer;"
+        @click="goDetail(videosData.videos_three[4])"
+      >
         <div class="cornerMark" style="background-color: #ff8d7a;">
-          5</div>
-        <el-image :src="videosData.videos_three[4].as_img"
-          style="width: 290px;height: 188px;border-radius: 12px;margin-top: -40px;" />
-        <div style="font-size: 15px;font-weight: Medium;">{{ videosData.videos_three[0].as_title }}</div>
+          5
+        </div>
+        <el-image
+          :src="videosData.videos_three[4].as_img"
+          style="width: 290px;height: 188px;border-radius: 12px;margin-top: -40px;"
+        />
+        <div style="font-size: 15px;font-weight: Medium;">
+          {{ videosData.videos_three[0].as_title }}
+        </div>
       </div>
       <div style="background-color: #9f93cd;height: 220px;width: 600px;display: flex;justify-content: flex-end;">
         <div style="width: 600px;height: 220px;display: flex;flex-direction: column;justify-content: center;">
-          <div style="color: white;font-size: 30px;font-weight: Medium;text-align: center;">点赞量火爆视频</div>
-          <div style="color: #c5c3da;font-size: 40px;font-weight: bold;text-align: center;">POPULAR</div>
-          <div style="color: #c5c3da;font-size: 40px;font-weight: bold;text-align: center;">LIKES VIDEOS</div>
+          <div style="color: white;font-size: 30px;font-weight: Medium;text-align: center;">
+            点赞量火爆视频
+          </div>
+          <div style="color: #c5c3da;font-size: 40px;font-weight: bold;text-align: center;">
+            POPULAR
+          </div>
+          <div style="color: #c5c3da;font-size: 40px;font-weight: bold;text-align: center;">
+            LIKES VIDEOS
+          </div>
         </div>
       </div>
     </div>
     <div class="bg">
       <div style="width: 1200px;margin: auto;display: flex;align-items: center;height: 100%;display: flex;">
         <div
-          style="background-color:rgba(119,110,151,0.5);border-radius: 10px;width: 290px;height: 335px;display: flex;flex-direction: column;justify-content: center;">
-          <div style="color: white;font-size: 30px;font-weight: Medium;text-align: center;">博智AI慕课</div>
-          <div style="color: white;font-size: 30px;font-weight: Medium;text-align: center;">优势</div>
-          <div style="color: #c5c3da;font-size: 33px;font-weight: bold;text-align: center;">BOZHI AI MUKE</div>
-          <div style="color: #c5c3da;font-size: 40px;font-weight: bold;text-align: center;">Advantages</div>
+          style="background-color:rgba(119,110,151,0.5);border-radius: 10px;width: 290px;height: 335px;display: flex;flex-direction: column;justify-content: center;"
+        >
+          <div style="color: white;font-size: 30px;font-weight: Medium;text-align: center;">
+            博智AI慕课
+          </div>
+          <div style="color: white;font-size: 30px;font-weight: Medium;text-align: center;">
+            优势
+          </div>
+          <div style="color: #c5c3da;font-size: 33px;font-weight: bold;text-align: center;">
+            BOZHI AI MUKE
+          </div>
+          <div style="color: #c5c3da;font-size: 40px;font-weight: bold;text-align: center;">
+            Advantages
+          </div>
         </div>
         <div style="width: 910px;display: flex;justify-content: space-around;">
           <div>
-            <div style="display: flex;justify-content: center;"><img src="../../../assets/icon1.png" /></div>
-            <div style="font-size: 32px;color: white;text-align: center;margin-top: 20px;">AI驱动</div>
-            <div style="font-size: 18px;color:white;text-align: center;">支持数字人实时渲染</div>
-            <div style="font-size: 18px;color:white;text-align: center;">提供PaaS技术支持底座</div>
+            <div style="display: flex;justify-content: center;">
+              <img src="../../../assets/icon1.png">
+            </div>
+            <div style="font-size: 32px;color: white;text-align: center;margin-top: 20px;">
+              AI驱动
+            </div>
+            <div style="font-size: 18px;color:white;text-align: center;">
+              支持数字人实时渲染
+            </div>
+            <div style="font-size: 18px;color:white;text-align: center;">
+              提供PaaS技术支持底座
+            </div>
           </div>
           <div>
-            <div style="display: flex;justify-content: center;"><img src="../../../assets/icon2.png" /></div>
-            <div style="font-size: 32px;color: white;text-align: center;margin-top: 20px;">智能生产制作</div>
-            <div style="font-size: 18px;color:white;text-align: center;">支持云剪辑视频与资源文件</div>
-            <div style="font-size: 18px;color:white;text-align: center;">提供剪辑合成、特效与生产</div>
+            <div style="display: flex;justify-content: center;">
+              <img src="../../../assets/icon2.png">
+            </div>
+            <div style="font-size: 32px;color: white;text-align: center;margin-top: 20px;">
+              智能生产制作
+            </div>
+            <div style="font-size: 18px;color:white;text-align: center;">
+              支持云剪辑视频与资源文件
+            </div>
+            <div style="font-size: 18px;color:white;text-align: center;">
+              提供剪辑合成、特效与生产
+            </div>
           </div>
           <div>
-            <div style="display: flex;justify-content: center;"><img src="../../../assets/icon3.png" /></div>
-            <div style="font-size: 32px;color: white;text-align: center;margin-top: 20px;">成本和效率</div>
-            <div style="font-size: 18px;color:white;text-align: center;">相比真人出镜更灵活高效</div>
-            <div style="font-size: 18px;color:white;text-align: center;">大大节省制作成本和时间</div>
+            <div style="display: flex;justify-content: center;">
+              <img src="../../../assets/icon3.png">
+            </div>
+            <div style="font-size: 32px;color: white;text-align: center;margin-top: 20px;">
+              成本和效率
+            </div>
+            <div style="font-size: 18px;color:white;text-align: center;">
+              相比真人出镜更灵活高效
+            </div>
+            <div style="font-size: 18px;color:white;text-align: center;">
+              大大节省制作成本和时间
+            </div>
           </div>
         </div>
       </div>
     </div>
   </div>
+  <chat-bot />
 </template>
+
 <style lang="scss" scoped>
 .bg {
   margin-top: 70px;