Bug Fixes
v-calendar
- Fix bug where initial
update:frompage
andupdate:topage
events missing page argument. Closes #125.
v-date-picker
- Fix bug where
formats
prop not getting forwarded tov-calendar
. Closes #123.
popover
- Modify
tabindex
to improve tab navigation. Closes #119. - Fix bug where content container element was overflowing window on mobile.
Improvements
v-date-picker
- Improve input key handing, specifically for
enter
andesc
keys - Added
update-on-input-keyup
prop to update picker selection on everykeyup
event. - Custom slot method
updateValue
can now accept options as the second parameter. Closes #118.
Property | Description | Default Value |
---|---|---|
formatInput
| If new value is valid, date picker should reformat the inputValue (based on formats.input ).
| true
|
hidePopover
| If new valud is valid, date picker should hide popover. | !popoverKeepVisibleOnInput
|
So, by default, without using a custom input slot, v-date-picker
will have the following behavior when the input control has focus
Action | Update w/ Value | formatInput | hidePopover |
---|---|---|---|
enter keyup (change event)
| Input value | true
| false
|
esc keyup
| Last value (input ignored) | true
| true
|
Any other keyup | Input value if update-on-input-keyup === true . None otherwise.
| false
| false
|
Here is an example of passing the parameters with a custom slot.
<v-date-picker
v-model='date'>
<input
slot-scope='{ inputValue, updateValue }'
:value='inputValue'
@change='updateValue(inputValue, { formatInput: true, hidePopover: false })'
@keyup='updateValue(inputValue, { formatInput: false, hidePopover: false })' />
</v-date-picker>
defaults
- Added
datePickerUpdateOnKeyup
as default value forv-date-picker.update-on-keyup
prop.