mirror of
https://github.com/nuintun/command-manager.git
synced 2025-12-15 23:30:48 +08:00
update files
This commit is contained in:
@@ -8,12 +8,19 @@
|
||||
// use it in the terminal.
|
||||
function isBoldBroken(){
|
||||
var el = document.createElement('span');
|
||||
|
||||
el.innerHTML = 'hello world';
|
||||
|
||||
document.body.appendChild(el);
|
||||
|
||||
var w1 = el.scrollWidth;
|
||||
|
||||
el.style.fontWeight = 'bold';
|
||||
|
||||
var w2 = el.scrollWidth;
|
||||
|
||||
document.body.removeChild(el);
|
||||
|
||||
return w1 !== w2;
|
||||
}
|
||||
|
||||
@@ -21,11 +28,9 @@ module.exports = function (Terminal){
|
||||
/**
|
||||
* Open Terminal
|
||||
*/
|
||||
|
||||
Terminal.prototype.open = function (){
|
||||
var self = this,
|
||||
i = 0,
|
||||
div;
|
||||
var i = 0;
|
||||
var div;
|
||||
|
||||
this.element = document.createElement('div');
|
||||
this.element.className = 'terminal';
|
||||
@@ -33,6 +38,7 @@ module.exports = function (Terminal){
|
||||
|
||||
for (; i < this.rows; i++) {
|
||||
div = document.createElement('div');
|
||||
|
||||
this.element.appendChild(div);
|
||||
this.children.push(div);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user