main.vue 905 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. <template>
  2. <div class="layout-main">
  3. <Scale-box >
  4. <template v-slot:default="scalebox">
  5. <div class="app-layout">
  6. <app-header></app-header>
  7. <router-view :scale='scalebox.scale'/>
  8. </div>
  9. </template>
  10. </Scale-box>
  11. </div>
  12. </template>
  13. <script>
  14. import ScaleBox from './pages/common/ScaleBox'
  15. import AppHeader from '@/components/AppHeader'
  16. export default {
  17. components:{ ScaleBox, AppHeader },
  18. data(){
  19. return{
  20. }
  21. },
  22. }
  23. </script>
  24. <style lang="less" scoped>
  25. .layout-main{
  26. width: 100%;
  27. height: 100%;
  28. overflow: hidden;
  29. position: relative;
  30. background-color: #00365A;
  31. .app-layout {
  32. padding: 10px 0px 14px;
  33. height: 100%;
  34. display: flex;
  35. flex-direction: column;
  36. background: url('~@/assets/images/header-bg.png') no-repeat;
  37. background-size: contain;
  38. background-position: center center;
  39. .app-body {
  40. flex: 1;
  41. }
  42. }
  43. }
  44. </style>