index.wxml 1.0 KB

123456789101112131415161718192021
  1. <view
  2. class="container {{mask?'containerShowMask':'containerNoMask'}}"
  3. hidden="{{!status}}"
  4. style="z-index:{{zIndex}}">
  5. <view class="l-bg-class toast-bg" wx:if="{{mask}}"></view>
  6. <view class="l-class toast toast-{{placement || 'bottom'}}" style="padding-top:{{(placement || 'bottom')=== 'bottom' ? image || icon ? '25rpx': '': ''}};position:relative;left:{{offsetX}}rpx;top:{{offsetY}}rpx;margin-bottom:{{distance}}px" >
  7. <image class="l-image-class toast-icon"
  8. wx:if="{{image}}"
  9. src="{{image}}"
  10. />
  11. <l-icon
  12. class="l-icon-class toast-icon toast-icon-{{icon === 'loading'?'loading':''}}"
  13. wx:elif="{{icon && !image}}"
  14. size="{{iconSize? iconSize : 60}}"
  15. color="{{iconColor? iconColor: icon === 'success'? '#00C292' : icon === 'error' ? '#F4516C' : '#ffffff'}}"
  16. name="{{icon}}"
  17. />
  18. <slot wx:else/>
  19. <text class="toast-text l-title-class toast-text-{{placement}}" style="{{placement || 'bottom' === 'bottom' ? icon || image? 'margin-top:10rpx' : '': '' }}">{{ title }}</text>
  20. </view>
  21. </view>