保誠-保戶業務員媒合平台
Tomas
2021-11-12 6e27ae8c429549cc568ed0bc4e0bd22c8d3e0611
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
93
94
95
<template>
    <div class="pam-background">
        <UiGoToTop></UiGoToTop>
        <BackActionBar></BackActionBar>
        <div class="banner" :class="bannerClassName"></div>
        <Nuxt class="page-container"></Nuxt>
        <Footer ref="defaultLayoutFooter"></Footer>
    </div>
</template>
 
<script lang="ts">
import { Vue, Component } from 'vue-property-decorator';
 
@Component
export default class DefaultLayout extends Vue {
  pageHieght = '';
 
  get bannerClassName() {
    if (this.$route.name) {
      return this.noBanner(this.$route.name) ? 'noBanner' : this.$route.name.split('-')[0]
    } else {
      return '';
    }
  }
 
  noBanner(routerName : string) {
    return routerName.match('questionnaire') || routerName.match('agentInfo');
  }
 
}
</script>
 
<style lang="scss" scoped>
  .pam-background {
    background-color: #F8F9FA;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    .page-container {
      flex: 1;
    }
  }
 
  .page-container {
    padding: 30px 40px;
  }
 
  @include desktop {
    .page-container{
      width: 700px;
      margin: 0 auto;
      overflow-x: hidden;
    }
  }
 
  .banner {
    width: 100%;
    height: 120px;
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
  }
 
  .noBanner {
    display: none;
  }
 
  .quickFilter {
    background-image: url('~/assets/images/quickFilter/banner_mob.svg');
  }
 
  .recommendConsultant {
    background-image: url('~/assets/images/recommendConsultant/banner_mob.svg');
  }
 
  .myConsultantList {
    background-image: url('~/assets/images/myConsultantList/banner_mob.svg');
  }
 
  @media (min-width: 768px) {
 
    .quickFilter {
      background-image: url('~/assets/images/quickFilter/banner_web.svg');
    }
 
    .recommendConsultant {
      background-image: url('~/assets/images/recommendConsultant/banner_web.svg');
    }
 
    .myConsultantList {
      background-image: url('~/assets/images/myConsultantList/banner_web.svg');
    }
  }
 
</style>