index.axml 3.3 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. <view class='page-container-classname' ref='saveChildRef0'>
  2. <import-sjs from='./index.sjs' name='computed'>
  3. </import-sjs>
  4. <demo-block title='基础用法' ref='saveChildRef1'>
  5. <van-cell is-link=" " title='选择单个日期' data-type='single' data-id='selectSingle' value='{{ computed.formatFullDate(date.selectSingle) }}' onClick='show' ref='saveChildRef2'>
  6. </van-cell>
  7. <van-cell is-link=" " title='选择多个日期' data-type='multiple' data-id='selectMultiple' value='{{ computed.formatMultiple(date.selectMultiple) }}' onClick='show' ref='saveChildRef3'>
  8. </van-cell>
  9. <van-cell is-link=" " title='选择日期区间' data-type='range' data-id='selectRange' value='{{ computed.formatRange(date.selectRange) }}' onClick='show' ref='saveChildRef4'>
  10. </van-cell>
  11. </demo-block>
  12. <demo-block title='快捷选择' ref='saveChildRef5'>
  13. <van-cell is-link=" " title='选择单个日期' data-type='single' data-id='quickSelect1' value='{{ computed.formatFullDate(date.quickSelect1) }}' onClick='show' ref='saveChildRef6'>
  14. </van-cell>
  15. <van-cell is-link=" " title='选择日期区间' data-type='range' data-id='quickSelect2' value='{{ computed.formatRange(date.quickSelect2) }}' onClick='show' ref='saveChildRef7'>
  16. </van-cell>
  17. </demo-block>
  18. <demo-block title='自定义日历' ref='saveChildRef8'>
  19. <van-cell is-link=" " title='自定义颜色' data-type='range' data-id='customColor' value='{{ computed.formatRange(date.customColor) }}' onClick='show' ref='saveChildRef9'>
  20. </van-cell>
  21. <van-cell is-link=" " title='自定义日期范围' data-type='single' data-id='customRange' value='{{ computed.formatFullDate(date.customRange) }}' onClick='show' ref='saveChildRef10'>
  22. </van-cell>
  23. <van-cell is-link=" " title='自定义按钮文字' data-type='range' data-id='customConfirm' value='{{ computed.formatRange(date.customConfirm) }}' onClick='show' ref='saveChildRef11'>
  24. </van-cell>
  25. <van-cell is-link=" " title='自定义日期文案' data-type='range' data-id='customDayText' value='{{ computed.formatRange(date.customDayText) }}' onClick='show' ref='saveChildRef12'>
  26. </van-cell>
  27. <van-cell is-link=" " title='自定义弹出位置' data-type='single' data-id='customPosition' value='{{ computed.formatFullDate(date.customPosition) }}' onClick='show' ref='saveChildRef13'>
  28. </van-cell>
  29. <van-cell is-link=" " title='日期区间最大范围' data-type='range' data-id='maxRange' value='{{ computed.formatRange(date.maxRange) }}' onClick='show' ref='saveChildRef14'>
  30. </van-cell>
  31. </demo-block>
  32. <demo-block title='平铺展示' ref='saveChildRef15'>
  33. <van-calendar title='日历' poppable='{{ false }}' show-confirm='{{ false }}' min-date='{{ tiledMinDate }}' max-date='{{ tiledMaxDate }}' class='tiled-calendar' ref='saveChildRef16'>
  34. </van-calendar>
  35. </demo-block>
  36. <van-calendar show='{{ showCalendar }}' type='{{ type }}' color='{{ color }}' round='{{ round }}' position='{{ position }}' min-date='{{ minDate }}' max-date='{{ maxDate }}' max-range='{{ maxRange }}' onFormatter='_dayFormatter' show-confirm='{{ showConfirm }}' confirm-text='{{ confirmText }}' confirm-disabled-text='{{ confirmDisabledText }}' onConfirm='onConfirm' onSelect='onSelect' onUnselect='onUnselect' onOpen='onOpen' onOpened='onOpened' onClose='onClose' onClosed='onClosed' ref='saveChildRef18'>
  37. </van-calendar>
  38. </view>