Browse Source

no message

feature/v2.1
xpz2018 4 years ago
parent
commit
35637bfcdb
2 changed files with 11 additions and 15 deletions
  1. 6
      components/calendar/calendar.wxml
  2. 20
      components/common/utils.js

6
components/calendar/calendar.wxml

@ -19,11 +19,7 @@
<van-button wx:if="{{ showConfirm }}" round block type="danger" color="{{ color }}"
custom-class="van-calendar__confirm" disabled="{{ computed.getButtonDisabled(type, currentDate) }}"
nativeType="text" bind:click="onConfirm">
{{
computed.getButtonDisabled(type, currentDate)
? confirmDisabledText
: confirmText
}}
{{ computed.getButtonDisabled(type, currentDate) ? confirmDisabledText : confirmText }}
</van-button>
</view>
</view>

20
components/common/utils.js

@ -33,15 +33,15 @@ export function addUnit(value) {
export function requestAnimationFrame(cb) {
const systemInfo = getSystemInfoSync();
if (systemInfo.platform === 'devtools') {
return setTimeout(() => {
cb();
}, 1000 / 30);
return setTimeout(() => {
cb();
}, 1000 / 30);
}
return wx
.createSelectorQuery()
.selectViewport()
.boundingClientRect()
.exec(() => {
cb();
});
}
.createSelectorQuery()
.selectViewport()
.boundingClientRect()
.exec(() => {
cb();
});
}
Loading…
Cancel
Save