jiaqingjiayi-xiaochengxu/甲情_甲意/miniprogram/node_modules/antd-mini/less/Calendar/index.axml
2024-11-10 15:01:22 +08:00

71 lines
3.1 KiB
XML

<import-sjs name="helper" from="./index.sjs" />
<mask onMaskTap="onClose" a:if="{{showMask}}" />
<view
class="ant-calendar-wrapper {{className}}"
style="height: {{ fullScreen ? '100vh' : height }} {{style}}"
data-id="{{$id}}"
data-renderTimes="{{renderTimes}}"
data-checkScroll="{{checkTimes}}"
change:data-renderTimes="{{helper.handleCalendarChange}}"
change:data-checkScroll="{{helper.handleCheckScroll}}"
>
<slot name="header">
<view class="ant-calendar-default-title {{ fullScreen ? 'ant-calendar-default-title-no-border-radius' : '' }}" a:if="{{showTitle}}">
<text>日期选择</text>
<image onTap="onClose" src="https://gw.alipayobjects.com/mdn/rms_6d74f8/afts/img/A*8wn2TKSKSSUAAAAAAAAAAAAAARQnAQ" class="ant-calendar-default-title-close" />
</view>
</slot>
<view
class="ant-calendar-days"
>
<block a:for="{{['一', '二', '三', '四', '五', '六', '日']}}">
<view class="ant-calendar-day">{{item}}</view>
</block>
</view>
<view class="ant-subcalendar-wrapper">
<scroll-view
class="ant-subcalendar"
onScroll="{{helper.handleTouchMove}}"
data-id="{{$id}}"
scroll-y="{{true}}"
>
<block
a:for="{{ calendarList }}"
>
<view class="ant-calendar-subtitle-wrapper">
<view class="ant-calendar-subtitle">{{item.monthDisplay}}</view>
</view>
<view
class="ant-calendar-dates"
>
<view
class="ant-calendar-week"
a:for="{{ item.weeks }}"
a:for-index="weekIndex"
a:for-item="weekItem"
>
<view
class="ant-calendar-date-wrap"
a:for="{{ weekItem }} "
a:for-index="dateItemIndex"
a:for-item="dateItem"
>
<date-item
dateItem="{{ dateItem }}"
onChange="onDateChange"
/>
</view>
</view>
</view>
</block>
</scroll-view>
</view>
<view class="ant-calendar-button-wrapper" a:if="{{(showConfirmButton || showResetButton) && !!selectionMode}}">
<view class="ant-calendar-botton-inner-cancel {{ buttonDisabled ? 'ant-calendar-botton-disabled' : '' }}" a:if="{{showResetButton}}" onTap="onCancel">重 置</view>
<view class="ant-calendar-botton-inner-check {{ buttonDisabled ? 'ant-calendar-botton-disabled' : '' }}" a:if="{{showConfirmButton}}" onTap="onCheck">确 认</view>
</view>
<!-- <view class="ant-calendar-button-single-wrapper" a:if="{{ selectionMode === 'single' }}">
<view class="ant-calendar-botton-inner-check" onTap="onCheck">确 认</view>
</view> -->
</view>