App.vue 1019 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  1. <template>
  2. <div id="app">
  3. <div class="view-container">
  4. <AppHeader></AppHeader>
  5. <router-view />
  6. </div>
  7. </div>
  8. </template>
  9. <script lang="ts">
  10. import AppHeader from '@/components/AppHeader.vue';
  11. export default {
  12. name: 'app',
  13. components: {
  14. AppHeader,
  15. },
  16. data() {
  17. return {
  18. isGray: false,
  19. };
  20. },
  21. created() {
  22. },
  23. }
  24. </script>
  25. <style>
  26. .view-container{
  27. position: relative;
  28. margin: 0 auto;
  29. width: 100%;
  30. max-width: 1200px;
  31. }
  32. .header-box {
  33. display: flex;
  34. justify-content: center;
  35. align-items: center;
  36. position: fixed;
  37. top: 0;
  38. left: 0;
  39. right: 0;
  40. background: #fff;
  41. border-bottom: 1px solid #f1f1f1;
  42. color: #909090;
  43. height: 5rem;
  44. z-index: 250;
  45. }
  46. .header-item {
  47. display: flex;
  48. justify-content: center;
  49. align-items: center;
  50. flex-direction: column;
  51. padding: 0 80px;
  52. }
  53. nav a {
  54. font-weight: bold;
  55. color: #515767;
  56. }
  57. nav a.route-active {
  58. color: #1e80ff;
  59. }
  60. .header-item i {
  61. font-size: 30px;
  62. margin-bottom: 5px;
  63. }
  64. </style>