index.wxml 654B

1234567891011121314151617181920212223242526
  1. <van-cell
  2. center
  3. title="{{ title }}"
  4. label="{{ label }}"
  5. border="{{ border }}"
  6. icon="{{ icon }}"
  7. custom-class="van-switch-cell"
  8. use-label-slot="{{ useLabelSlot }}"
  9. >
  10. <slot slot="icon" name="icon" />
  11. <slot slot="title" name="title" />
  12. <slot slot="label" name="label" />
  13. <van-switch
  14. size="{{ size }}"
  15. checked="{{ checked }}"
  16. loading="{{ loading }}"
  17. disabled="{{ disabled }}"
  18. active-color="{{ activeColor }}"
  19. inactive-color="{{ inactiveColor }}"
  20. active-value="{{ activeValue }}"
  21. inactive-value="{{ inactiveValue }}"
  22. custom-class="van-switch-cell__switch"
  23. bind:change="onChange"
  24. />
  25. </van-cell>