Showing
5 changed files
with
18 additions
and
20 deletions
@@ -37,8 +37,6 @@ | @@ -37,8 +37,6 @@ | ||
37 | margin-top: 6rpx; | 37 | margin-top: 6rpx; |
38 | } | 38 | } |
39 | .order-action-selected-button { | 39 | .order-action-selected-button { |
40 | - /* display: flex; */ | ||
41 | - /* align-items: center; */ | ||
42 | height: 80rpx; | 40 | height: 80rpx; |
43 | width: 224rpx; | 41 | width: 224rpx; |
44 | font-family: PingFang-SC-Medium; | 42 | font-family: PingFang-SC-Medium; |
@@ -49,8 +47,6 @@ | @@ -49,8 +47,6 @@ | ||
49 | align-items: center; | 47 | align-items: center; |
50 | padding-top: 10rpx; | 48 | padding-top: 10rpx; |
51 | padding-bottom: 10rpx; | 49 | padding-bottom: 10rpx; |
52 | - /* padding-left: 40rpx; | ||
53 | - padding-right: 40rpx; */ | ||
54 | margin-left: 20rpx; | 50 | margin-left: 20rpx; |
55 | 51 | ||
56 | } | 52 | } |
@@ -61,22 +57,15 @@ | @@ -61,22 +57,15 @@ | ||
61 | .order-action-unselected-button { | 57 | .order-action-unselected-button { |
62 | height: 80rpx; | 58 | height: 80rpx; |
63 | width: 224rpx; | 59 | width: 224rpx; |
64 | - /* display: flex; */ | ||
65 | - /* align-items: center; */ | ||
66 | font-family: PingFang-SC-Regular; | 60 | font-family: PingFang-SC-Regular; |
67 | font-size: 24rpx; | 61 | font-size: 24rpx; |
68 | color: #999999; | 62 | color: #999999; |
69 | background-color: #FFFFFF; | 63 | background-color: #FFFFFF; |
70 | - border: 2rpx solid #CCCCCC; | 64 | + border: 1rpx solid #CCCCCC; |
71 | border-radius: 0; | 65 | border-radius: 0; |
72 | padding-top: 10rpx; | 66 | padding-top: 10rpx; |
73 | padding-bottom: 10rpx; | 67 | padding-bottom: 10rpx; |
74 | - /* padding-left: 40rpx; | ||
75 | - padding-right: 40rpx; */ | ||
76 | - /* border-style: none; */ | ||
77 | - /* margin-right: 20rpx; */ | ||
78 | - /* padding-left: 40rpx; | ||
79 | - padding-right: 40rpx; */ | 68 | + |
80 | } | 69 | } |
81 | .order-action-left-view { | 70 | .order-action-left-view { |
82 | display: flex; | 71 | display: flex; |
@@ -12,7 +12,7 @@ | @@ -12,7 +12,7 @@ | ||
12 | /* padding-right: 40rpx; */ | 12 | /* padding-right: 40rpx; */ |
13 | } | 13 | } |
14 | .component-order-right-view { | 14 | .component-order-right-view { |
15 | - width: 100%; | 15 | + width: 468rpx; |
16 | display: flex; | 16 | display: flex; |
17 | flex-direction: column; | 17 | flex-direction: column; |
18 | justify-content: space-between; | 18 | justify-content: space-between; |
@@ -33,7 +33,8 @@ Page({ | @@ -33,7 +33,8 @@ Page({ | ||
33 | slideOffset: 0, | 33 | slideOffset: 0, |
34 | activeIndex: 0, | 34 | activeIndex: 0, |
35 | sliderWidth: 96, | 35 | sliderWidth: 96, |
36 | - contentHeight: 0 | 36 | + contentHeight: 0, |
37 | + contentWidth:0 | ||
37 | }, | 38 | }, |
38 | 39 | ||
39 | /** | 40 | /** |
@@ -48,7 +49,8 @@ Page({ | @@ -48,7 +49,8 @@ Page({ | ||
48 | that.setData({ | 49 | that.setData({ |
49 | sliderWidth: (res.windowWidth - 20) / that.data.tabs.length, | 50 | sliderWidth: (res.windowWidth - 20) / that.data.tabs.length, |
50 | sliderOffset: (res.windowWidth - 20) / that.data.tabs.length * that.data.activeIndex, | 51 | sliderOffset: (res.windowWidth - 20) / that.data.tabs.length * that.data.activeIndex, |
51 | - contentHeight: res.windowHeight - res.windowWidth / 750 * 108//计算内容区高度,rpx -> px计算 | 52 | + contentHeight: res.windowHeight - res.windowWidth / 750 * 108,//计算内容区高度,rpx -> px计算 |
53 | + contentWidth: res.windowWidth | ||
52 | }); | 54 | }); |
53 | that.setData({ api: api }); | 55 | that.setData({ api: api }); |
54 | that.fetchOrderList(2,1); | 56 | that.fetchOrderList(2,1); |
1 | <view class="order-list-page"> | 1 | <view class="order-list-page"> |
2 | <view class="order-list-navbar"> | 2 | <view class="order-list-navbar"> |
3 | + <view class='order-list-navbar-item-space'></view> | ||
3 | <block wx:for="{{tabs}}" wx:key="{{index}}"> | 4 | <block wx:for="{{tabs}}" wx:key="{{index}}"> |
4 | <view id="{{index}}" class="order-list-navbar-item {{activeIndex == index ? 'order-list-navbar-item-on' : ''}}" bindtap="navTabClick"> | 5 | <view id="{{index}}" class="order-list-navbar-item {{activeIndex == index ? 'order-list-navbar-item-on' : ''}}" bindtap="navTabClick"> |
5 | {{item.name}} | 6 | {{item.name}} |
6 | <!-- <text class="order-list-navbar-title">{{item.name}}</text> --> | 7 | <!-- <text class="order-list-navbar-title">{{item.name}}</text> --> |
7 | </view> | 8 | </view> |
8 | </block> | 9 | </block> |
10 | + <view class='order-list-navbar-item-space'></view> | ||
9 | <view class="order-list-navbar-slider" style="width: {{sliderWidth}}px; transform: translateX({{sliderOffset}}px); -webkit-transform: translateX({{sliderOffset}}px);"></view> | 11 | <view class="order-list-navbar-slider" style="width: {{sliderWidth}}px; transform: translateX({{sliderOffset}}px); -webkit-transform: translateX({{sliderOffset}}px);"></view> |
10 | </view> | 12 | </view> |
11 | - <view style="position: absolute;top: 108rpx;width: 100%;height:{{contentHeight}}px"> | 13 | + <view style="position: absolute;top: 108rpx;width: {{contentWidth}}px;height:{{contentHeight}}px;"> |
12 | <swiper current="{{activeIndex}}" duration="300" bindchange="bindChange" type> | 14 | <swiper current="{{activeIndex}}" duration="300" bindchange="bindChange" type> |
13 | <swiper-item wx:for="{{tabs}}" wx:for-item="tab" wx:key="{{index}}" catchtouchmove='catchTouchMove'> | 15 | <swiper-item wx:for="{{tabs}}" wx:for-item="tab" wx:key="{{index}}" catchtouchmove='catchTouchMove'> |
14 | <block wx:if="{{tab && tab.data && tab.data.data.length > 0}}"> | 16 | <block wx:if="{{tab && tab.data && tab.data.data.length > 0}}"> |
@@ -12,12 +12,16 @@ | @@ -12,12 +12,16 @@ | ||
12 | position: absolute; | 12 | position: absolute; |
13 | z-index: 500; | 13 | z-index: 500; |
14 | top: 0; | 14 | top: 0; |
15 | - width: calc( 100% - 80rpx ); | 15 | + width: 100%; |
16 | height: 96rpx; | 16 | height: 96rpx; |
17 | border-top: 2rpx solid #eeeeee; | 17 | border-top: 2rpx solid #eeeeee; |
18 | border-bottom: 2rpx solid #eeeeee; | 18 | border-bottom: 2rpx solid #eeeeee; |
19 | - margin-left: 40rpx; | ||
20 | - margin-right: 40rpx; | 19 | + /* align-content: center; */ |
20 | + /* padding-left: 40rpx; | ||
21 | + padding-right: 40rpx; */ | ||
22 | +} | ||
23 | +.order-list-navbar-item-space { | ||
24 | + width: 0rpx; | ||
21 | } | 25 | } |
22 | .order-list-navbar-item { | 26 | .order-list-navbar-item { |
23 | /* display: block; | 27 | /* display: block; |
@@ -29,6 +33,7 @@ | @@ -29,6 +33,7 @@ | ||
29 | font-weight: 500; | 33 | font-weight: 500; |
30 | font-size: 28rpx; | 34 | font-size: 28rpx; |
31 | color: #999999; | 35 | color: #999999; |
36 | + align-self: center; | ||
32 | } | 37 | } |
33 | .order-list-navbar-item-on { | 38 | .order-list-navbar-item-on { |
34 | color: #000000; | 39 | color: #000000; |
-
Please register or login to post a comment