Image 图片

    1. <view class="page__hd">
    2. <view class="page__title">Image</view>
    3. <view class="page__desc">图片</view>
    4. </view>
    5. <view class="page__bd">
    6. <view class="sub-title">Shape</view>
    7. <wux-row>
    8. <wux-col span="4">
    9. <wux-image wux-class="image" shape="rounded" src="https://picsum.photos/750/750/?random&s=1" />
    10. </wux-col>
    11. <wux-col span="4">
    12. <wux-image wux-class="image" shape="circle" src="https://picsum.photos/750/750/?random&s=2" loading="Loading" />
    13. </wux-col>
    14. <wux-col span="4">
    15. <image src="https://loading.io/spinners/spinner/index.ajax-spinner-preloader.svg" slot="loading" />
    16. </wux-image>
    17. </wux-col>
    18. </wux-row>
    19. <view class="sub-title">Loading</view>
    20. <wux-row>
    21. <wux-col span="4">
    22. <wux-image wux-class="image" src="https://picsum.photos/750/750/?random&s=4" />
    23. </wux-col>
    24. <wux-col span="4">
    25. </wux-col>
    26. <wux-col span="4">
    27. <wux-image wux-class="image" src="https://picsum.photos/750/750/?random&s=6">
    28. <image src="https://loading.io/spinners/spinner/index.ajax-spinner-preloader.svg" slot="loading" />
    29. </wux-image>
    30. </wux-col>
    31. </wux-row>
    32. <view class="sub-title">Empty</view>
    33. <wux-row>
    34. <wux-col span="4">
    35. <wux-image wux-class="image" src="" />
    36. </wux-col>
    37. <wux-image wux-class="image" src="" empty="Empty" />
    38. </wux-col>
    39. <wux-col span="4">
    40. <wux-image wux-class="image" src="">
    41. <image src="data:image/gif;base64,R0lGODdhAQABAPAAAMPDwwAAACwAAAAAAQABAAACAkQBADs=" slot="empty" />
    42. </wux-image>
    43. </wux-col>
    44. </wux-row>
    45. <view class="sub-title">Error</view>
    46. <wux-row>
    47. <wux-col span="4">
    48. <wux-image wux-class="image" src="error" />
    49. <wux-col span="4">
    50. <wux-image wux-class="image" src="error" error="Error" />
    51. </wux-col>
    52. <wux-col span="4">
    53. <wux-image wux-class="image" src="error">
    54. <image src="https://wux.cdn.cloverstd.com/logo.png" slot="error" />
    55. </wux-image>
    56. </wux-col>
    57. </wux-row>
    58. </view>

    Image