Browse Source

完成 首页背景bitflower效果

million 1 year ago
parent
commit
c6be050c57
4 changed files with 10 additions and 4 deletions
  1. 1 1
      src/components/Nav.vue
  2. BIN
      src/media/0727(12).mp4
  3. BIN
      src/media/0727(7).mp4
  4. 9 3
      src/views/HomeView.vue

+ 1 - 1
src/components/Nav.vue

@@ -21,7 +21,7 @@ onMounted(() => {
 
 const sunAndMoon = () => {
   if (sunStore.sun) {
-    document.documentElement.style.setProperty('--color-background', '#181818')
+    document.documentElement.style.setProperty('--color-background', '#000000')
     document.documentElement.style.setProperty('--color-text', '#f2f2f2')
     document.documentElement.style.setProperty('--vt-c-border', '#555555')
     document.documentElement.style.setProperty('--vt-c-pure', '#000000')

BIN
src/media/0727(12).mp4


BIN
src/media/0727(7).mp4


+ 9 - 3
src/views/HomeView.vue

@@ -23,7 +23,10 @@ const toPage = (url:string) => {
         <img class="left" v-show="sunStore.sun" src="../assets/home/header.svg" alt="header">
       </div>
       <div class="right">
-        <img class="right" src="../assets/home/flower-white.svg" alt="flower">
+        <video v-show="!sunStore.sun" autoplay="autoplay" playsinline="playsinline" muted="muted" width="640" height="640" src="../media/0727(7).mp4">
+        </video>
+        <video v-show="sunStore.sun" autoplay="autoplay" playsinline="playsinline" muted="muted" width="640" height="640" src="../media/0727(12).mp4">
+        </video>
       </div>
     </div>
     <div class="airdrop">
@@ -284,6 +287,7 @@ const toPage = (url:string) => {
     position: absolute;
     top: 0;
     z-index: -1;
+    display: none;
   }
 
   .header {
@@ -298,8 +302,10 @@ const toPage = (url:string) => {
     }
 
     .right {
-      user-select: none;
-      -webkit-user-drag: none;
+      //user-select: none;
+      //-webkit-user-drag: none;
+      //width: 320px;
+      //height: 180px;
     }
   }