mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-20 09:48:00 +01:00
Fix completion preview error in 3.6a2
--HG-- extra : rebase_source : 33da194d4dc35758f42183b0969132289d9594cc
This commit is contained in:
@@ -474,15 +474,22 @@ const util = { //{{{
|
||||
return ns + ":" + node.localName;
|
||||
return node.localName.toLowerCase();
|
||||
}
|
||||
let tag = "<" + [namespaced(elem)].concat(
|
||||
[namespaced(a) + "=" + template.highlight(a.value, true)
|
||||
for ([i, a] in util.Array.iteritems(elem.attributes))]).join(" ");
|
||||
try
|
||||
{
|
||||
let tag = "<" + [namespaced(elem)].concat(
|
||||
[namespaced(a) + "=" + template.highlight(a.value, true)
|
||||
for ([i, a] in util.Array.iteritems(elem.attributes))]).join(" ");
|
||||
|
||||
if (!elem.firstChild || /^\s*$/.test(elem.firstChild) && !elem.firstChild.nextSibling)
|
||||
tag += '/>';
|
||||
else
|
||||
tag += '>...</' + namespaced(elem) + '>';
|
||||
return tag;
|
||||
if (!elem.firstChild || /^\s*$/.test(elem.firstChild) && !elem.firstChild.nextSibling)
|
||||
tag += '/>';
|
||||
else
|
||||
tag += '>...</' + namespaced(elem) + '>';
|
||||
return tag;
|
||||
}
|
||||
catch (e)
|
||||
{
|
||||
return {}.toString.call(elem);
|
||||
}
|
||||
}
|
||||
|
||||
try
|
||||
|
||||
Reference in New Issue
Block a user