yuting.cui 3 years ago
parent
commit
0df0f128cd

+ 8 - 1
sph_applet/pages/followAccount/followAccount.js

@@ -6,6 +6,8 @@ Page({
6 6
    * 页面的初始数据
7 7
    */
8 8
   data: {
9
+    isShow: true,
10
+    notice: '公告:“-”代表该视频号预估粉丝增量数据获取异常,对您造成的不便尽请谅解.',
9 11
     safeAreaTop: '',
10 12
     page: 1,
11 13
     time: 1,
@@ -19,13 +21,18 @@ Page({
19 21
    */
20 22
   onLoad: function (options) {
21 23
     this.setData({
22
-      safeAreaTop:50+app.data.safeAreaTop,
24
+      safeAreaTop:30+app.data.safeAreaTop,
23 25
       page: 1,
24 26
       pages: 1,
25 27
       videoList: []
26 28
     })
27 29
     this.getVideoList();
28 30
   },
31
+  switchShow() {
32
+    this.setData({
33
+      isShow: false
34
+    })
35
+  },
29 36
   checkType(e) {
30 37
     this.setData({
31 38
       time: e.currentTarget.dataset.time,

+ 8 - 1
sph_applet/pages/followAccount/followAccount.wxml

@@ -1,7 +1,14 @@
1 1
 <!--pages/followAccount/followAccount.wxml-->
2 2
 <wxs module="filter" src="../../assets/js/common.wxs"></wxs>
3 3
 <custom-header title="收藏的视频号" isBack="true"></custom-header>
4
-<view class="follow" style="margin-top:{{safeAreaTop}}px">
4
+<view class="notice-wrap" style="margin-top:{{safeAreaTop}}px" wx:if="{{isShow}}">
5
+    <view class="tongzhitext">
6
+      <text class="tongzhi-text">{{notice}}</text>
7
+    <image bindtap='switchShow' src="../../assets/img/close11.png" class="closeView">x</image>
8
+    </view>
9
+  </view>
10
+<!-- <view class="follow" style="margin-top:calc({{safeAreaTop}}px {{isShow?' + 80rpx':''}})"> -->
11
+<view class="follow" style="margin-top:{{isShow?'30rpx':(safeAreaTop+20+'px')}}">
5 12
   <view class="flex">
6 13
     <view class="item" bindtap="showBox">{{time==''?'日期筛选':(time==1?'昨日':'近'+time+'天')}}
7 14
       <view class="sort"></view>

+ 48 - 0
sph_applet/pages/followAccount/followAccount.wxss

@@ -172,4 +172,52 @@
172 172
   display: inline-block;
173 173
   width: 100%;
174 174
   height: 100%;
175
+}
176
+
177
+@keyframes remindMessage {
178
+  0% {
179
+    -webkit-transform: translateX(4%);
180
+  }
181
+
182
+  100% {
183
+    -webkit-transform: translateX(-20%);
184
+  }
185
+}
186
+
187
+.tongzhitext {
188
+  margin-right:80rpx;
189
+  margin-left: 20rpx;
190
+  overflow: hidden;
191
+  white-space: nowrap;
192
+  text-overflow: ellipsis;
193
+}
194
+
195
+.tongzhi-text {
196
+  font-size: 24rpx;
197
+  line-height: 52rpx;
198
+  animation: remindMessage 4s linear infinite 3s;
199
+  width: 100%;
200
+  color: #FF7500;
201
+  display: block;
202
+}
203
+
204
+.notice-wrap {
205
+  background: #ffebda;
206
+  width: 100%;
207
+  height: 52rpx;
208
+  line-height: 52rpx;
209
+  color: #FEF6EA;
210
+  font-size: 28rpx;
211
+  position: relative;
212
+  margin-top: 20rpx;
213
+  /* border: 0.5px solid #FF8426; */
214
+}
215
+
216
+.closeView {
217
+  width: 34rpx;
218
+  height: 34rpx;
219
+  position: absolute;
220
+  right: 10rpx;
221
+  top: 50%;
222
+  transform: translateY(-50%);
175 223
 }