<!-- 参考：https://zhuanlan.zhihu.com/p/117244248 -->
<view class="nav-bar"
      style="position:{{navBarConfig.booFixed ? 'fixed' : 'relative'}}; height:{{navBarHeight}}px; background-color: {{navBarConfig.backgroundColor || 'transparent'}};">
  <view class="nav-bar-wrap"
        style="height:{{menuHeight}}px; min-height:{{menuHeight}}px; line-height:{{menuHeight}}px;left:{{menuRight}}px; bottom:{{menuBottom}}px;"
        bind:tap="navBarEvent">
    <view class="jump-home"
          wx:if="{{historyLength <=1 && navBarConfig.icon === 'back'}}">
      <image class="home-icon" src="{{tools.imgFilter('/common/nav_icon_home_white@2x.png')}}"></image>
      <text class="home-text">首页</text>
    </view>
    <block wx:else>
      <image class="icon {{navBarConfig.icon}}"
             src="{{tools.imgFilter(navBarConfig.iconPath)}}"
             wx:if="{{navBarConfig.icon}}"></image>
      <text class="label"
            wx:if="{{navBarConfig.label}}">{{navBarConfig.label}}</text>
    </block>
  </view>
  <view class="title"
        style="height:{{menuHeight}}px; min-height:{{menuHeight}}px; line-height:{{menuHeight}}px;left:{{menuRight}}px;right:{{menuRight}}px;bottom:{{menuBottom}}px;"
        wx:if="{{navBarConfig.title}}">{{navBarConfig.title}}
  </view>
</view>
<wxs src="../wxs/index.wxs" module="tools"></wxs>
