<template>
  <div id="app">
    <component :is="page"></component>
  </div>
</template>
<script>
import pc from '@/views/PcPage.vue'
import ios from '@/views/IosPage.vue'
import android from '@/views/AndroidPage.vue'
export default {
  name: 'App',
  computed: {
    page: () => {
      let component = pc
      const u = navigator.userAgent.toLowerCase()
      // console.log(u)
      if (-1 != u.indexOf('android') || -1 != u.indexOf('adr')) {
        component = android
      } else if (-1 != u.indexOf("iphone") || -1 != u.indexOf("ipad")) {
        component = ios
      }

      return component
    }
  }
}

</script>
<style>
#app {
  height: 100%;
  font-family: 'Avenir', Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-align: center;
  color: #2c3e50;
  /*margin-top: 60px;*/
  margin: 0;
  padding: 0;
}

</style>
