index.wxml 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. <view class="{{ classes.backdrop }}" wx:if="{{ backdrop && buttonVisible }}"></view>
  2. <view class="wux-class {{ classes.wrap }}" catchtap="onToggle">
  3. <view class="{{ classes.action }}" hover-class="{{ classes.hover }}">
  4. <image class="{{ classes.text }}" src="{{ action }}" wx:if="{{ action }}" />
  5. <slot name="action" wx:else></slot>
  6. </view>
  7. <block wx:for="{{ buttons }}" wx:for-item="button" wx:key="index">
  8. <button
  9. class="{{ classes.button[index].wrap }}"
  10. data-index="{{ index }}"
  11. data-value="{{ button }}"
  12. data-label="{{ button.label }}"
  13. disabled="{{ button.disabled }}"
  14. open-type="{{ button.openType }}"
  15. hover-class="{{ !button.disabled ? classes.button[index].hover : 'none' }}"
  16. hover-stop-propagation="{{ button.hoverStopPropagation }}"
  17. hover-start-time="{{ button.hoverStartTime }}"
  18. hover-stay-time="{{ button.hoverStayTime }}"
  19. lang="{{ button.lang }}"
  20. bindgetuserinfo="bindgetuserinfo"
  21. session-from="{{ button.sessionFrom }}"
  22. send-message-title="{{ button.sendMessageTitle }}"
  23. send-message-path="{{ button.sendMessagePath }}"
  24. send-message-img="{{ button.sendMessageImg }}"
  25. show-message-card="{{ button.showMessageCard }}"
  26. bindcontact="bindcontact"
  27. bindgetphonenumber="bindgetphonenumber"
  28. app-parameter="{{ button.appParameter }}"
  29. binderror="onError"
  30. bindopensetting="bindopensetting"
  31. catchtap="onTap"
  32. style="{{ buttonStyle[index] }}"
  33. >
  34. <image class="{{ classes.icon }}" src="{{ button.icon }}" />
  35. <view class="{{ classes.label }}" wx:if="{{ button.label }}">{{ button.label }}</view>
  36. </button>
  37. </block>
  38. </view>