zhuf 1 year ago
parent
commit
21b8eeffe6
9 changed files with 77 additions and 48 deletions
  1. 2 2
      index.html
  2. 7 8
      src/App.vue
  3. 34 0
      src/pages/caiji/index.vue
  4. 12 0
      src/pages/caiji/sy/read.vue
  5. 1 13
      src/pages/home.vue
  6. 11 6
      src/pages/home/caiji/index.vue
  7. 0 15
      src/style.css
  8. 10 2
      tsconfig.json
  9. 0 2
      vite.config.ts

+ 2 - 2
index.html

@@ -6,8 +6,8 @@
     <meta name="viewport" content="width=device-width, initial-scale=1.0" />
     <title>Ai慕课</title>
   </head>
-  <body>
-    <div id="app"></div>
+  <body class="m-0 p-0">
+    <div id="app" class="h-screen w-screen bg-hex-22252f"></div>
     <script type="module" src="/src/main.ts"></script>
   </body>
 </html>

+ 7 - 8
src/App.vue

@@ -1,10 +1,9 @@
-<script setup lang="ts">
-</script>
-
 <template>
-  <router-view class="h-screen w-screen bg-hex-40424a"></router-view>
+  <van-config-provider theme="dark" :theme-vars="{
+    'tabbar-background': '#59595928',
+    'tabbar-item-active-background': '#59595928',
+    'nav-bar-background': '#00000003',
+  }">
+    <router-view></router-view>
+  </van-config-provider>
 </template>
-
-<style scoped>
-
-</style>

+ 34 - 0
src/pages/caiji/index.vue

@@ -0,0 +1,34 @@
+<script setup lang='ts'>
+import rx from '~/assets/caiji/rx.webp'
+import sy from '~/assets/caiji/sy.webp'
+
+const router = useRouter()
+
+</script>
+
+<template>
+  <van-nav-bar title="AI慕课采集"></van-nav-bar>
+  <div class="flex flex-col items-center space-y-6 px-24px">
+    <div class="relative" @click="router.push({ name: 'home-caiji-sy-read' })">
+      <img :src="sy" alt="">
+      <div class="absolute inset-0 flex flex-col items-center text-white font-bold mt-40px space-y-20px">
+        <div>声音采集</div>
+        <van-button plain round size="small" type="success" class="px-4">点击进入</van-button>
+      </div>
+    </div>
+    <div class="relative">
+      <img :src="rx" alt="">
+      <div class="absolute inset-0 flex flex-col items-center text-white font-bold mt-40px space-y-20px">
+        <div>人像采集</div>
+        <van-button plain round size="small" type="success" class="px-4">点击进入</van-button>
+      </div>
+    </div>
+    <ul class="w-full text-xs text-white leading-5 opacity-60 space-y-4 list-disc list-inside -indent-4 pl-4">
+      <li>录音时位置确定后尽量不要动,就是说嘴和话筒的距离确定后不要随便乱动,有的人好动,这个避免不了,但是幅度不要太大,要不然会影响音色和动态。</li>
+      <li>拍摄时现场严禁大声喧哗,嬉笑打闹;人脸正面免冠照片,需露出眉毛、眼睛及耳朵,亮度均衡。</li>
+    </ul>
+
+  </div>
+</template>
+
+

+ 12 - 0
src/pages/caiji/sy/read.vue

@@ -0,0 +1,12 @@
+<script setup lang='ts'>
+const router = useRouter()
+
+function onClickLeft() {
+  router.back()
+}
+</script>
+
+<template>
+  <van-nav-bar title="声音采集" left-arrow @click-left="onClickLeft"></van-nav-bar>
+  <div></div>
+</template>

+ 1 - 13
src/pages/home.vue

@@ -1,7 +1,7 @@
 <template>
   <div>
     <router-view></router-view>
-    <van-tabbar v-model="active" @change="onChange">
+    <van-tabbar v-model="active" @change="onChange" active-color="#db664d" inactive-color="#b3b3b3">
       <van-tabbar-item v-for="(item, index) in tabData" :key="index" :name="item.name">
         <span>{{item.title}}</span>
         <template #icon="props">
@@ -57,15 +57,3 @@ function onChange(name) {
 }
 </script>
 
-<style lang="scss" scoped>
-.van-tabbar {
-  background: unset;
-  .van-tabbar-item {
-    color: #b3b3b3;
-  }
-  .van-tabbar-item--active {
-    color: #db664d;
-    background: unset;
-  }
-}
-</style>

+ 11 - 6
src/pages/home/caiji/index.vue

@@ -1,7 +1,15 @@
+<script setup lang='ts'>
+import rx from '~/assets/caiji/rx.webp'
+import sy from '~/assets/caiji/sy.webp'
+
+const router = useRouter()
+
+</script>
+
 <template>
   <van-nav-bar title="AI慕课采集"></van-nav-bar>
-  <div class="flex flex-col items-center space-y-6 px-24px">
-    <div class="relative">
+  <div class="flex flex-col items-center space-y-6 px-24px py-18px">
+    <div class="relative" @click="router.push({ name: 'caiji-sy-read' })">
       <img :src="sy" alt="">
       <div class="absolute inset-0 flex flex-col items-center text-white font-bold mt-40px space-y-20px">
         <div>声音采集</div>
@@ -23,7 +31,4 @@
   </div>
 </template>
 
-<script setup>
-import rx from '~/assets/caiji/rx.webp'
-import sy from '~/assets/caiji/sy.webp'
-</script>
+

+ 0 - 15
src/style.css

@@ -1,15 +0,0 @@
-body {
-  margin: 0;
-}
-
-.van-nav-bar {
-  background: unset !important;
-}
-
-.van-nav-bar .van-nav-bar__title {
-  color: #fff;
-}
-
-.van-nav-bar:after {
-  content: none !important;
-}

+ 10 - 2
tsconfig.json

@@ -18,8 +18,16 @@
     "strict": true,
     "noUnusedLocals": true,
     "noUnusedParameters": true,
-    "noFallthroughCasesInSwitch": true
+    "noFallthroughCasesInSwitch": true,
+    "types": [
+      "vite/client",
+      "unplugin-vue-macros/macros-global"
+    ],
+    "baseUrl": ".",
+    "paths": {
+      "~/*": ["src/*"]
+    },
   },
-  "include": ["src/**/*.ts", "src/**/*.tsx", "src/**/*.vue"],
+  "include": ["src/**/*.ts", "src/**/*.tsx", "src/**/*.vue","./auto-imports.d.ts"],
   "references": [{ "path": "./tsconfig.node.json" }]
 }

+ 0 - 2
vite.config.ts

@@ -1,5 +1,3 @@
-/// <reference types="vitest" />
-
 import path from 'node:path'
 import { defineConfig } from 'vite'
 import Vue from '@vitejs/plugin-vue'