bugfixing

This commit is contained in:
Blue 2018-11-20 14:49:16 +03:00
parent f26cdc128b
commit ccc39cac9a
4 changed files with 10 additions and 6 deletions

View file

@ -41,7 +41,7 @@ class NumericBox extends UI {
this._input.addEventListener("input", this._boundInput);
}
_createInput() {
this._input = document.createElement("div");
this._input = document.createElement("input");
this._input.classList.add("numericBox");
this.element.appendChild(this._input);

View file

@ -60,13 +60,13 @@ class SwitchBox extends UI {
this.setValue(!this._value);
}
_setSize() {
let dh = this._width / 2.5;
let dh = this._width / 2;
dh = Math.min(dh, this._height);
let dw = dh * 2.5;
let dw = dh * 2;
this._iWidth = dw;
this._iHeight = dh;
let circleDiameter = Math.round(dh * 0.80);
let circleDiameter = Math.round(dh * 0.75);
this._input.style.width = dw + "px";
this._input.style.height = dh + "px";