Fixed CHTML.addElement to be able to create non-span elements (e.g., the <a> needed for href attributes)
This commit is contained in:
parent
17e02d710c
commit
0412d8ec7e
|
@ -324,8 +324,9 @@
|
||||||
if (type.substr(0,4) === "mjx-") {
|
if (type.substr(0,4) === "mjx-") {
|
||||||
if (!def) def = {};
|
if (!def) def = {};
|
||||||
if (def.className) def.className = type+" "+def.className; else def.className = type;
|
if (def.className) def.className = type+" "+def.className; else def.className = type;
|
||||||
|
type = "span";
|
||||||
}
|
}
|
||||||
return this.HTMLElement("span",def,content);
|
return this.HTMLElement(type,def,content);
|
||||||
},
|
},
|
||||||
addElement: function (node,type,def,content) {
|
addElement: function (node,type,def,content) {
|
||||||
return node.appendChild(this.Element(type,def,content));
|
return node.appendChild(this.Element(type,def,content));
|
||||||
|
|
Loading…
Reference in New Issue
Block a user