<!--components/cell/index.wxml-->

<template name="rightIcon">
  <image src="/assets/images/right.png" class="rightIcon" />
</template>

<template name="content">
  <view wx:if="{{!rightArrow}}">
      {{title}}
    </view>
    <view wx:else style="display: flex; justify-content: space-between;align-items: center; width: 100%;">
      {{title}}
      <template is="rightIcon" />
    </view>
</template>

<view class="cellWrapper" wx:if="{{!openType}}" bind:tap="click">
  <view class="content">
    <template is="content" data="{{title, rightArrow}}" />
  </view>
  <view class="borderBottom" wx:if="{{borderBottom}}"></view>
</view>
<view wx:else  bind:tap="click">
  <button class="button" open-type="{{openType}}" 	plain="true">
    <template is="content" data="{{title, rightArrow}}" />
  </button>
  <view class="borderBottom" wx:if="{{borderBottom}}"></view>
</view>
