mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-08-29 12:09:20 +03:00
KnockoutJS:
* remove deprecated allBindings as Accessor https://github.com/knockout/knockout/pull/2133 * remove unused event '*Bubble' https://knockoutjs.com/documentation/event-binding.html#note-4-preventing-the-event-from-bubbling * remove unused 'completeOn' https://knockoutjs.com/documentation/binding-lifecycle-events.html#indicating-that-a-control-flow-binding-completes-asynchronously
This commit is contained in:
parent
4cb88b408c
commit
3a32a09f2a
8 changed files with 96 additions and 116 deletions
9
dev/External/User/ko.js
vendored
9
dev/External/User/ko.js
vendored
|
|
@ -64,13 +64,12 @@ ko.bindingHandlers.moment = {
|
|||
};
|
||||
|
||||
ko.bindingHandlers.emailsTags = {
|
||||
init: (element, fValueAccessor, fAllBindingsAccessor) => {
|
||||
const fValue = fValueAccessor(),
|
||||
fAllBindings = fAllBindingsAccessor();
|
||||
init: (element, fValueAccessor, fAllBindings) => {
|
||||
const fValue = fValueAccessor();
|
||||
|
||||
element.addresses = new EmailAddressesComponent(element, {
|
||||
focusCallback: value => fValue.focused && fValue.focused(!!value),
|
||||
autoCompleteSource: fAllBindings.autoCompleteSource || null,
|
||||
autoCompleteSource: fAllBindings.get('autoCompleteSource'),
|
||||
onChange: value => fValue(value)
|
||||
});
|
||||
|
||||
|
|
@ -220,7 +219,7 @@ ko.bindingHandlers.initDom = {
|
|||
};
|
||||
|
||||
ko.bindingHandlers.onEsc = {
|
||||
init: (element, fValueAccessor, fAllBindingsAccessor, viewModel) => {
|
||||
init: (element, fValueAccessor, fAllBindings, viewModel) => {
|
||||
let fn = event => {
|
||||
if ('Escape' == event.key) {
|
||||
element.dispatchEvent(new Event('change'));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue