欢迎光临
感谢一路有你

小程序样式 | 收款样式

如果你对该文章中的内容有疑问/不解,可以点击此处链接提问
要注明问题和此文章链接地址 点击此处跳转
 

 

wxml

<view class="container page">
  <view class="panel">
    <view class="header">
    </view>
    <view class="barcode">
      <view class="barnum">{{code}}</view>
      <canvas canvas-id="barcode" />
    </view>
    <view class="qrcode">
      <canvas canvas-id="qrcode" />
    </view>
  </view>
</view>

wxss

page {
    background-color: #439057;
}
.page {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}
.container {
    padding-bottom: 10rpx;
}
.panel {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: stretch;
    box-sizing: border-box;
    width: 710rpx;
    margin-top: 40rpx;
    border-radius: 10rpx;
    background-color: #fff;
}
.header {
    height: 140rpx;
    background-color: #f0f0f0;
    border-radius: 10rpx 10rpx 0 0;
}
.barcode {
    display: flex;
    height: 320rpx;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}
.barnum {
    width: 670rpx;
    height: 100rpx;
    line-height: 100rpx;
    font-size: 38rpx;
    font-weight: bold;
    text-align: center;
    letter-spacing: 10rpx;
    white-space: nowrap;
}
.barcode > canvas {
    width: 680rpx;
    height: 200rpx;  
}
.qrcode {
    height: 420rpx;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: center;
}
.qrcode > canvas {
    width: 420rpx;
    height: 420rpx;
}

 

 

 

赞(0) 打赏
未经允许不得转载:王明昌博客 » 小程序样式 | 收款样式
分享到: 更多 (0)

相关推荐

  • 暂无文章

觉得文章有用就打赏一下文章作者

支付宝扫一扫打赏

微信扫一扫打赏

×
订阅图标按钮