mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2026-06-03 19:22:27 +00:00
Further style tweaks to #321
This commit is contained in:
@@ -61,9 +61,9 @@ var processRow = function(prevColumns) {
|
||||
} else if(cellMatch[2]) {
|
||||
// End of row
|
||||
if(prevCell && colSpanCount > 1) {
|
||||
try {
|
||||
colSpanCount += prevCell.attributes.colspan.value;
|
||||
} catch(e) {
|
||||
if(prevCell.attributes && prevCell.attributes && prevCell.attributes.colspan) {
|
||||
colSpanCount += prevCell.attributes.colspan.value;
|
||||
} else {
|
||||
colSpanCount -= 1;
|
||||
}
|
||||
$tw.utils.addAttributeToParseTreeNode(prevCell,"colspan",colSpanCount);
|
||||
|
||||
@@ -20,7 +20,7 @@ exports.addAttributeToParseTreeNode = function(node,name,value) {
|
||||
};
|
||||
|
||||
exports.getAttributeValueFromParseTreeNode = function(node,name,defaultValue) {
|
||||
if(node.type === "element" && node.attributes && node.attributes[name] && node.attributes[name].value != undefined) {
|
||||
if(node.type === "element" && node.attributes && node.attributes[name] && node.attributes[name].value !== undefined) {
|
||||
return node.attributes[name].value;
|
||||
}
|
||||
return defaultValue;
|
||||
|
||||
Reference in New Issue
Block a user