Showing
6 changed files
with
19 additions
and
8 deletions
1 | <template> | 1 | <template> |
2 | <div class="header"> | 2 | <div class="header"> |
3 | <div class="back-wrapper flex" @touchend="onBack"> | 3 | <div class="back-wrapper flex" @touchend="onBack"> |
4 | - <div class="back"></div> | 4 | + <div class="back" v-if="showBack"></div> |
5 | </div> | 5 | </div> |
6 | <div class="title flex" :style="{opacity}"> | 6 | <div class="title flex" :style="{opacity}"> |
7 | <slot> | 7 | <slot> |
@@ -24,6 +24,10 @@ export default { | @@ -24,6 +24,10 @@ export default { | ||
24 | opacity: { | 24 | opacity: { |
25 | type: Number, | 25 | type: Number, |
26 | default: 1 | 26 | default: 1 |
27 | + }, | ||
28 | + showBack: { | ||
29 | + type: Boolean, | ||
30 | + default: true | ||
27 | } | 31 | } |
28 | }, | 32 | }, |
29 | computed: { | 33 | computed: { |
1 | <template> | 1 | <template> |
2 | <div class="layout"> | 2 | <div class="layout"> |
3 | - <LayoutHeader class="layout-header" :title="title" :opacity="opacity"></LayoutHeader> | 3 | + <LayoutHeader class="layout-header" :title="title" :opacity="opacity" :show-back="showBack"></LayoutHeader> |
4 | <div class="layout-context" :class="{fixscroll: this.fixscroll}"> | 4 | <div class="layout-context" :class="{fixscroll: this.fixscroll}"> |
5 | <slot></slot> | 5 | <slot></slot> |
6 | </div> | 6 | </div> |
@@ -21,6 +21,10 @@ export default { | @@ -21,6 +21,10 @@ export default { | ||
21 | fixscroll: { | 21 | fixscroll: { |
22 | type: Boolean, | 22 | type: Boolean, |
23 | default: false | 23 | default: false |
24 | + }, | ||
25 | + showBack: { | ||
26 | + type: Boolean, | ||
27 | + default: true | ||
24 | } | 28 | } |
25 | }, | 29 | }, |
26 | components: { | 30 | components: { |
@@ -26,6 +26,10 @@ export default { | @@ -26,6 +26,10 @@ export default { | ||
26 | 26 | ||
27 | <style lang="scss" scoped> | 27 | <style lang="scss" scoped> |
28 | .banner { | 28 | .banner { |
29 | + font-size: 0; | ||
30 | + padding-bottom: 20px; | ||
31 | + background-color: #f0f0f0; | ||
32 | + | ||
29 | img { | 33 | img { |
30 | position: relative; | 34 | position: relative; |
31 | width: 100%; | 35 | width: 100%; |
@@ -71,12 +71,12 @@ export default { | @@ -71,12 +71,12 @@ export default { | ||
71 | font-size: 34px; | 71 | font-size: 34px; |
72 | color: #222; | 72 | color: #222; |
73 | text-align: center; | 73 | text-align: center; |
74 | - font-weight: 600; | 74 | + font-weight: bold; |
75 | margin-bottom: 20px; | 75 | margin-bottom: 20px; |
76 | } | 76 | } |
77 | 77 | ||
78 | .header-wrapper { | 78 | .header-wrapper { |
79 | - position: relative; | 79 | + position: sticky; |
80 | height: 100px; | 80 | height: 100px; |
81 | } | 81 | } |
82 | 82 | ||
@@ -118,10 +118,9 @@ export default { | @@ -118,10 +118,9 @@ export default { | ||
118 | font-size: 28px; | 118 | font-size: 28px; |
119 | color: #444; | 119 | color: #444; |
120 | display: flex; | 120 | display: flex; |
121 | - border-bottom: 0.5PX solid #b0b0b0; | 121 | + border-bottom: 0.5PX solid #e0e0e0; |
122 | line-height: 100px; | 122 | line-height: 100px; |
123 | position: relative; | 123 | position: relative; |
124 | - display: flex; | ||
125 | justify-content: space-between; | 124 | justify-content: space-between; |
126 | } | 125 | } |
127 | 126 |
-
Please register or login to post a comment