on-codemerge
Version:
A WYSIWYG editor for on-codemerge is a user-friendly interface that allows users to edit and view their code in real time, exactly as it will appear in the final product
23 lines (22 loc) • 634 B
JavaScript
var n = Object.defineProperty;
var s = (t, e, i) => e in t ? n(t, e, { enumerable: !0, configurable: !0, writable: !0, value: i }) : t[e] = i;
var l = (t, e, i) => s(t, typeof e != "symbol" ? e + "" : e, i);
import { focusNodeStart as m } from "../../../utils/Selection.mjs";
class h {
constructor(e) {
l(this, "element");
this.element = e, this.initialize();
}
initialize() {
this.element.contentEditable = "true", this.element.firstChild || this.element.appendChild(document.createTextNode(""));
}
focus() {
m(this.element);
}
getElement() {
return this.element;
}
}
export {
h as TableCell
};