mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-08-31 21:19:21 +03:00
js -> jsx
This commit is contained in:
parent
3bcf23f8fa
commit
08ccf55577
43 changed files with 2342 additions and 2347 deletions
|
|
@ -1,6 +1,6 @@
|
|||
|
||||
import ko from 'ko';
|
||||
import Utils from 'Common/Utils';
|
||||
import {isUnd} from 'Common/Utils';
|
||||
import {AbstractComponent} from 'Component/Abstract';
|
||||
|
||||
class AbstracCheckbox extends AbstractComponent
|
||||
|
|
@ -13,30 +13,30 @@ class AbstracCheckbox extends AbstractComponent
|
|||
super();
|
||||
|
||||
this.value = params.value;
|
||||
if (Utils.isUnd(this.value) || !this.value.subscribe)
|
||||
if (isUnd(this.value) || !this.value.subscribe)
|
||||
{
|
||||
this.value = ko.observable(Utils.isUnd(this.value) ? false : !!this.value);
|
||||
this.value = ko.observable(isUnd(this.value) ? false : !!this.value);
|
||||
}
|
||||
|
||||
this.enable = params.enable;
|
||||
if (Utils.isUnd(this.enable) || !this.enable.subscribe)
|
||||
if (isUnd(this.enable) || !this.enable.subscribe)
|
||||
{
|
||||
this.enable = ko.observable(Utils.isUnd(this.enable) ? true : !!this.enable);
|
||||
this.enable = ko.observable(isUnd(this.enable) ? true : !!this.enable);
|
||||
}
|
||||
|
||||
this.disable = params.disable;
|
||||
if (Utils.isUnd(this.disable) || !this.disable.subscribe)
|
||||
if (isUnd(this.disable) || !this.disable.subscribe)
|
||||
{
|
||||
this.disable = ko.observable(Utils.isUnd(this.disable) ? false : !!this.disable);
|
||||
this.disable = ko.observable(isUnd(this.disable) ? false : !!this.disable);
|
||||
}
|
||||
|
||||
this.label = params.label || '';
|
||||
this.inline = Utils.isUnd(params.inline) ? false : params.inline;
|
||||
this.inline = isUnd(params.inline) ? false : params.inline;
|
||||
|
||||
this.readOnly = Utils.isUnd(params.readOnly) ? false : !!params.readOnly;
|
||||
this.inverted = Utils.isUnd(params.inverted) ? false : !!params.inverted;
|
||||
this.readOnly = isUnd(params.readOnly) ? false : !!params.readOnly;
|
||||
this.inverted = isUnd(params.inverted) ? false : !!params.inverted;
|
||||
|
||||
this.labeled = !Utils.isUnd(params.label);
|
||||
this.labeled = !isUnd(params.label);
|
||||
this.labelAnimated = !!params.labelAnimated;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue