navbar.wxml 1.2 KB

123456789101112131415161718192021
  1. <!--pages/navbar/navbar.wxml-->
  2. <view style="margin-bottom: {{height*2 + 20}}px;">
  3. <view class='nav-wrap' style='height: {{height*2 + 20}}px;'>
  4. <view class='nav-title' style='line-height: {{height*2 + 44}}px;'>{{navbarData.title}}</view>
  5. <view style='display: flex; justify-content: space-around;flex-direction: column'>
  6. <!-- // 导航栏 左上角的返回按钮 和home按钮 -->
  7. <!-- // 其中wx:if='{{navbarData.showCapsule}}' 是控制左上角按钮的显示隐藏,首页不显示 -->
  8. <view class='nav-capsule' style='height: {{height*2 + 44}}px;' wx:if='{{navbarData.showCapsule}}'>
  9. <!-- //左上角的返回按钮,wx:if='{{!share}}'空制返回按钮显示 -->
  10. <!-- //从分享进入小程序时 返回上一级按钮不应该存在 -->
  11. <view bindtap='_navback' wx:if='{{navbarData.share}}'>
  12. <image src='/img/history.png' mode='aspectFill' class='back-pre'></image>
  13. </view>
  14. <!-- <view class='navbar-v-line' wx:if='{{!share}}'></view> -->
  15. <view bindtap='_backhome' wx:else>
  16. <image src='/img/index.png' mode='aspectFill' class='back-home'></image>
  17. </view>
  18. </view>
  19. </view>
  20. </view>
  21. </view>