appDownload.vue 1.68 KB
Newer Older
zhangsan's avatar
zhangsan committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92
<script setup lang="ts">
import { ref } from 'vue'
const downloadUrl = ref(sessionStorage.getItem('appdownload') || '')


const handleDownload = () => {
    window.open(downloadUrl.value, '_blank')
}

</script>

<template>
  <div class="page-container">
    <div class="content">
      <div class="download-section">
        <div class="download-buttons">
          <button class="download-btn android" @click="handleDownload">
            <var-icon name="android" :size="24" />
            <span>Android 下载</span>
          </button>
          <button class="download-btn ios" @click="handleDownload">
            <var-icon name="apple" :size="24" />
            <span>iOS 下载</span>
          </button>
        </div>
      </div>
    </div>
  </div>
</template>

<style lang="scss" scoped>
.page-container {
  min-height: 100vh;
  background: linear-gradient(135deg, #f5f7fa 0%, #e4e7eb 100%);
  padding-bottom: 40px;
}

.content {
  padding: 20px;
}

.app-preview {
  margin: 20px 0;
  text-align: center;

}

.download-section {
  background: white;
  border-radius: 16px;
  padding: 24px;
  margin: 20px 0;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}


.download-buttons {
  display: flex;
  gap: 12px;
  margin-top: 24px;

  .download-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;

    &.android {
      background: #4CAF50;
      color: white;
    
    }

    &.ios {
      background: #000;
      color: white;

      &:active {
        background: #333;
      }
    }
  }
}
</style>