mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-08-30 12:39: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
8
dev/External/ko.js
vendored
8
dev/External/ko.js
vendored
|
|
@ -21,7 +21,7 @@ ko.bindingHandlers.tooltipErrorTip = {
|
|||
};
|
||||
|
||||
ko.bindingHandlers.onEnter = {
|
||||
init: (element, fValueAccessor, fAllBindingsAccessor, viewModel) => {
|
||||
init: (element, fValueAccessor, fAllBindings, viewModel) => {
|
||||
let fn = event => {
|
||||
if ('Enter' == event.key) {
|
||||
element.dispatchEvent(new Event('change'));
|
||||
|
|
@ -34,7 +34,7 @@ ko.bindingHandlers.onEnter = {
|
|||
};
|
||||
|
||||
ko.bindingHandlers.onSpace = {
|
||||
init: (element, fValueAccessor, fAllBindingsAccessor, viewModel) => {
|
||||
init: (element, fValueAccessor, fAllBindings, viewModel) => {
|
||||
let fn = event => {
|
||||
if (' ' == event.key) {
|
||||
fValueAccessor().call(viewModel, event);
|
||||
|
|
@ -73,7 +73,7 @@ ko.bindingHandlers.title = {
|
|||
};
|
||||
|
||||
ko.bindingHandlers.command = {
|
||||
init: (element, fValueAccessor, fAllBindingsAccessor, viewModel, bindingContext) => {
|
||||
init: (element, fValueAccessor, fAllBindings, viewModel, bindingContext) => {
|
||||
const command = fValueAccessor();
|
||||
|
||||
if (!command || !command.enabled || !command.canExecute) {
|
||||
|
|
@ -83,7 +83,7 @@ ko.bindingHandlers.command = {
|
|||
ko.bindingHandlers['FORM'==element.nodeName ? 'submit' : 'click'].init(
|
||||
element,
|
||||
fValueAccessor,
|
||||
fAllBindingsAccessor,
|
||||
fAllBindings,
|
||||
viewModel,
|
||||
bindingContext
|
||||
);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue