撸一个简单的小程序红包页面

先上图

撸一个简单的小程序红包页面_第1张图片

 

json文件配置导航栏背景颜色和字体颜色

{
  "navigationBarTitleText": "投票领红包",
  "navigationBarBackgroundColor": "#D55B46",
  "navigationBarTextStyle": "white"
}

 


wxml:

<view class="top">
  
view>
<view class="btn-open" bindtap="goRuselt">
  <text>查看红包text>
view>

wxss:

page {
  background: linear-gradient(0deg, rgba(220, 87, 68, 1), rgba(213, 91, 70, 1));
  color: #333;
}

.top {
  background: linear-gradient(0deg, rgba(220, 87, 68, 1), rgba(213, 91, 70, 1));
  height: 64vh;
  border-radius: 0rpx 0rpx 68% 68% / 0rpx 0rpx 25% 25%;
  box-shadow:0px 7rpx 30rpx 0px rgba(157,60,26,1);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 7%;
}

.btn-open{
  width: 220rpx;
  height: 220rpx;
  margin: 0 auto;
  margin-top: -110rpx;
  border-radius: 50%;
  background:rgba(254,214,155,1);
  box-shadow:0px 7rpx 30rpx 0px rgba(157,60,26,1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 36rpx;
  font-weight: bold;
  color: #DA5844;
}

 

转载于:https://www.cnblogs.com/Leesttee/p/11582888.html

你可能感兴趣的:(撸一个简单的小程序红包页面)