Skip to content

Commit a46fe31

Browse files
committed
fixes #341 - introduced debounce functionality into formatValueToModel
* Updated to fecha 2.3.2 * Moved the majority of logic from computed.value.set() to new `updateModelValue(newValue, oldValue)` method to allow other components to use similar techniques. If `formatValueToModel` returns a function, then the function is called without setting the model value. It is the functions responsibility to call `this.updateModelValue(newValue, oldValue)`. Otherwise, calls `this.updateModelValue(newValue, oldValue)` to execute the original logic. * If the input type is date, datetime, or datetime-local then it creates a debounced function for setting the value in fieldInput's mounted hook and then returns a function that calls this debounced function from `formatValueToModel` * Reduced the repeated code for date formatting by adding a DATETIME_FORMATS constant, and using that to get the "format" for fecha.parse()
1 parent 5c42f3e commit a46fe31

File tree

6 files changed

+1037
-97
lines changed

6 files changed

+1037
-97
lines changed

dist/vfg-core.js

+3-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/vfg.js

+4-4
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)