<!--packageE/foot/foot.wxml-->
<view class="component-wrapper {{'component-'+datas.id}}}" wx:if="{{routeDataShow}}">

  <view style="height: {{iPnoneBottomBol? '84': '50'}}px;"></view>

  <view class="advertising-preview" style="width: {{clientWidth}}px;background-color: {{tab_style.bg_set.bg_color}};padding-bottom: {{iPnoneBottomBol? '34': '0'}}px;">
    <view class="ul weixin-menu" id="weixin-menu" style="width: {{clientWidth}}px;">
      <view
          wx:for="{{menu_button}}" wx:key="index" wx:for-index="index" wx:for-item="btn" data-index="{{index}}" data-item="{{btn}}"
          class="li menu-item {{selectedMenuIndex === index ? 'current': ''}}"
          style="max-width: {{100/menu_button.length}}%;background-color: {{selectedMenuIndex === index ? tab_style.bg_set.bg_choose_color : tab_style.bg_set.bg_color}};border: {{tab_style.border_set.border_show?'1':'0'}}px solid {{selectedMenuIndex === index ?tab_style.border_set.border_choose_color :tab_style.border_set.border_color}};"
          catchtap="selectedMenu"
      >
        <view class="menu-item-title"
              style="height: {{(tab_style.icon_set.icon_position=='top' && tab_style.text_set.text_show && btn.isIcon != '3')?'':'50px'}};line-height: {{(tab_style.icon_set.icon_position=='top' && tab_style.text_set.text_show && btn.isIcon != '3')?'25px':'50px'}};display: {{tab_style.icon_set.icon_position=='left' ?'flex':''}};justify-content: center;">
          <icon class="menu-icon iconfont {{btn.isIcon == '1'?btn.icon||'icon-fenlei4':''}}"
                style="display: {{tab_style.icon_set.icon_show? '':'none'}};color : {{selectedMenuIndex === index ? tab_style.icon_set.icon_choose_color: tab_style.icon_set.icon_color}};font-size: {{btn.size}}px;"
                wx:if="{{btn.isIcon == '1'&& tab_style.icon_set.icon_show}}"></icon>
          <image class="icon-img" wx:if="{{btn.isIcon == '2'&& tab_style.icon_set.icon_show}}" mode='widthFix' style="margin-top: {{tab_style.icon_set.icon_position=='left' ?'':'4px'}};align-self: center"  src="{{btn.image|| emptyImage}}" mode='aspectFill'/>
          <view class="hide-box" wx:if="{{tab_style.icon_set.icon_position=='top' && btn.isIcon != '3'}}"
                style="height: 10px;display: {{tab_style.icon_set.icon_show? 'none':''}};"></view>
          <view wx:if="{{tab_style.text_set.text_show}}" class="span menu-text"
                style="display: {{tab_style.icon_set.icon_position=='top'?'block':''}};width: {{tab_style.icon_set.icon_position=='left'?'':'100%'}};margin-left: {{tab_style.icon_set.icon_position=='left' ?'5px':''}};margin-top: {{tab_style.icon_set.icon_position=='left' ?'':'-2px'}};color : {{selectedMenuIndex === index ? tab_style.text_set.text_choose_color: tab_style.text_set.text_color}};">
            {{ btn.text }}
          </view>
        </view>
        <view class="ul weixin-sub-menu"
              wx:if="{{selectedMenuIndex === index && btn.sub_button && btn.sub_button.length > 0}}">
          <view
              wx:for="{{btn.sub_button}}" wx:key="i2" wx:for-index="i2" wx:for-item="sub" data-index="{{i2}}" data-item="{{sub}}"
              class="li menu-sub-item {{seletedId === sub.id ? 'current' :''}}"
              style="border: {{tab_style.border_set.border_show?'1':'0'}}px solid {{seletedId === sub.id ? tab_style.border_set.border_choose_color:tab_style.border_set.border_color}};"
              catchtap="selectedSubMenu"
          >
            <view class="menu-item-title"
                  style="height: {{( tab_style.icon_set.icon_position=='top' && tab_style.text_set.text_show && btn.isIcon != '3')?'':'50px'}};line-height: {{(tab_style.icon_set.icon_position=='top' && tab_style.icon_set.icon_show && tab_style.text_set.text_show && sub.isIcon != '3' )?'25px':'50px'}};background-color: {{tab_style.children_set.children_bg_color}};display: {{tab_style.icon_set.icon_position=='left' ?'flex':''}};justify-content: center;">
              <icon class="menu-icon iconfont {{sub.isIcon == '1'?sub.icon||'icon-fenlei4':''}}"
                    style="display: {{tab_style.icon_set.icon_show? '':'none'}};color : {{seletedId === sub.id ? tab_style.children_set.children_choose_color :tab_style.children_set.children_color}};"
                    wx:if="{{sub.isIcon == '1'&& tab_style.icon_set.icon_show}}"></icon>
              <image class="icon-img" wx:if="{{sub.isIcon == '2' && tab_style.icon_set.icon_show}}" mode='widthFix' style="margin-top: {{tab_style.icon_set.icon_position=='left' ?'':'4px'}};align-self: center"  src="{{sub.image|| emptyImage}}" mode='aspectFill'/>
              <view wx:if="{{tab_style.text_set.text_show}}" class="span menu-text"
                    style="display: {{tab_style.icon_set.icon_position=='top'?'block':''}};width: {{tab_style.icon_set.icon_position=='left'?'':'100%'}};margin-left: {{tab_style.icon_set.icon_position=='left' ?'5px':''}};margin-top: {{tab_style.icon_set.icon_position=='left' ?'':'-2px'}};color : {{seletedId === sub.id ? tab_style.children_set.children_choose_color:tab_style.children_set.children_color}};">
                {{sub.text}}
              </view>
            </view>
          </view>
        </view>
      </view>
    </view>
  </view>

</view>
