index.axml 3.5 KB

12345678910111213141516171819202122232425262728293031323334
  1. <view class='dialog-index {{className}}' style='{{style}}' ref='saveChildRef0'>
  2. <import-sjs from='../wxs/utils.sjs' name='utils'>
  3. </import-sjs>
  4. <van-popup show='{{ show }}' z-index='{{ zIndex }}' overlay='{{ overlay }}' transition='{{ transition }}' custom-class='van-dialog van-dialog--{{ theme }} {{ className }}' custom-style='width: {{ utils.addUnit(width) }};{{ customStyle }}' overlay-style='{{ overlayStyle }}' close-on-click-overlay='{{ closeOnClickOverlay }}' onClose='onClickOverlay' ref='saveChildRef1'>
  5. <view a:if='{{ title || useTitleSlot }}' class="{{ utils.bem('dialog__header', { isolated: !(message || useSlot) }) }}">
  6. <slot a:if='{{ useTitleSlot }}' name='title'>
  7. </slot>
  8. <block a:elif='{{ title }}'>
  9. {{ title }}
  10. </block>
  11. </view>
  12. <slot a:if='{{ useSlot }}'>
  13. </slot>
  14. <view a:elif='{{ message }}' class="{{ utils.bem('dialog__message', [theme, messageAlign, { hasTitle: title }]) }}">
  15. <text class='van-dialog__message-text'>
  16. {{ message }} </text>
  17. </view> <van-goods-action a:if="{{ theme === 'round-button' }}" custom-class='van-dialog__footer--round-button' ref='saveChildRef2'>
  18. <van-goods-action-button a:if='{{ showCancelButton }}' size='large' loading='{{ loading.cancel }}' class='van-dialog__button van-hairline--right' custom-class='van-dialog__cancel' custom-style='color: {{ cancelButtonColor }}' onClick='onCancel' ref='saveChildRef3'>
  19. {{ cancelButtonText }}
  20. </van-goods-action-button>
  21. <van-goods-action-button a:if='{{ showConfirmButton }}' size='large' class='van-dialog__button' loading='{{ loading.confirm }}' custom-class='van-dialog__confirm' custom-style='color: {{ confirmButtonColor }}' open-type='{{ confirmButtonOpenType }}' lang='{{ lang }}' business-id='{{ businessId }}' session-from='{{ sessionFrom }}' send-message-title='{{ sendMessageTitle }}' send-message-path='{{ sendMessagePath }}' send-message-img='{{ sendMessageImg }}' show-message-card='{{ showMessageCard }}' app-parameter='{{ appParameter }}' onClick='onConfirm' onGetuserinfo='bindGetUserInfo' onContact='bindContact' onGetphonenumber='bindGetPhoneNumber' onError='bindError' onLaunchapp='bindLaunchApp' onOpensetting='bindOpenSetting' ref='saveChildRef4'>
  22. {{ confirmButtonText }}
  23. </van-goods-action-button>
  24. </van-goods-action>
  25. <view a:else class='van-hairline--top van-dialog__footer'>
  26. <van-button a:if='{{ showCancelButton }}' size='large' loading='{{ loading.cancel }}' class='van-dialog__button van-hairline--right' custom-class='van-dialog__cancel' custom-style='color: {{ cancelButtonColor }}' onClick='onCancel' ref='saveChildRef5'>
  27. {{ cancelButtonText }}
  28. </van-button>
  29. <van-button a:if='{{ showConfirmButton }}' size='large' class='van-dialog__button' loading='{{ loading.confirm }}' custom-class='van-dialog__confirm' custom-style='color: {{ confirmButtonColor }}' open-type='{{ confirmButtonOpenType }}' lang='{{ lang }}' business-id='{{ businessId }}' session-from='{{ sessionFrom }}' send-message-title='{{ sendMessageTitle }}' send-message-path='{{ sendMessagePath }}' send-message-img='{{ sendMessageImg }}' show-message-card='{{ showMessageCard }}' app-parameter='{{ appParameter }}' onClick='onConfirm' onGetuserinfo='bindGetUserInfo' onContact='bindContact' onGetphonenumber='bindGetPhoneNumber' onError='bindError' onLaunchapp='bindLaunchApp' onOpensetting='bindOpenSetting' ref='saveChildRef6'>
  30. {{ confirmButtonText }}
  31. </van-button>
  32. </view>
  33. </van-popup>
  34. </view>