管灌系统农户端微信小程序(嘉峪关应用)
zuoxiao
2024-02-26 3f7ec892d68f71e996489d14d9918dc332281b1e
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
<import src="../common/template/badge" />
<import src="../common/template/icon" />
<wxs src="../common/utils.wxs" module="_" />
 
<view
  class="{{_.cls(classPrefix, [['active', active], ['disabled', disabled]])}} class {{prefix}}-class"
  style="{{_._style([style, customStyle])}}"
  bind:tap="handleClick"
  aria-role="button"
  aria-label="{{ active ? '已选中,' + label : label}}"
  aria-label="{{ ariaLabel || (badgeProps.dot || badgeProps.count ? (active ? '已选中,' + label + _.getBadgeAriaLabel({ ...badgeProps }) : label + _.getBadgeAriaLabel({ ...badgeProps })) : '') }}"
  aria-disabled="{{disabled}}"
>
  <block wx:if="{{active}}">
    <view class="{{classPrefix}}__line"></view>
    <view class="{{classPrefix}}__prefix"></view>
    <view class="{{classPrefix}}__suffix"></view>
  </block>
  <template wx:if="{{_icon}}" is="icon" data="{{ class: classPrefix + '__icon', ..._icon }}" />
  <block wx:if="{{badgeProps}}">
    <template is="badge" data="{{ ...badgeProps, content: label }}" />
  </block>
  <block wx:else>{{label}}</block>
</view>