<!--component/tarbar/tarbar.wxml-->
<view class="tabBar">
    <block wx:for="{{tarbarList}}" wx:for-item="item" wx:key="index">
      <view class="tabBar-item">
        <navigator open-type="switchTab" url="{{item.pagePath}}" hover-class="none">
          <view>
            <image class="icon" src='{{index == currentList[current] ? item.selectedIconPath : item.iconPath}}'></image>
          </view>
          <view class="{{index == currentList[current] ? 'tabBartext' :''}}">{{item.text}}</view>
        </navigator>
      </view>
    </block>
  </view>