templateA.vue 997 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. <template>
  2. <div class="website-frame">
  3. <mtaheader></mtaheader>
  4. <div class="nuxt-box">
  5. <Nuxt />
  6. </div>
  7. <mtafooter></mtafooter>
  8. <bottomMenu></bottomMenu>
  9. <mtaSidebar></mtaSidebar>
  10. </div>
  11. </template>
  12. <script>
  13. import Mtafooter from '~/components/footer.vue'
  14. import Mtaheader from '~/components/header.vue'
  15. import mtaSidebar from '~/components/sidebar.vue'
  16. import bottomMenu from '~/components/bottomMenu.vue'
  17. export default {
  18. name: 'mtaFooter',
  19. components: {
  20. Mtafooter,
  21. Mtaheader,
  22. bottomMenu,
  23. mtaSidebar
  24. },
  25. //监测路由变化,滚动条置于最上方
  26. watch: {
  27. $route: function(to, from) {
  28. document.body.scrollTop = 0;
  29. document.documentElement.scrollTop = 0;
  30. }
  31. },
  32. }
  33. </script>
  34. <style lang="scss">
  35. .nuxt-box:not(.client-index-page){
  36. width: 100%;padding-top: 72px;
  37. // 移动端手机尺寸(0-768)
  38. @media (max-width: 768px){padding-top: 61px;}
  39. }
  40. </style>