mirror of
https://github.com/laurent22/joplin.git
synced 2024-12-24 10:27:10 +02:00
Desktop, Cli: Fixes #3402: Fixed import of checkboxes in ENEX files
This commit is contained in:
parent
05acc51054
commit
acf1ff6d1d
@ -3,7 +3,7 @@
|
||||
<p>For example, consider an exported Evernote list with todo checkboxes like this:</p>
|
||||
<ul>
|
||||
<li>
|
||||
<div><input type="checkbox" onclick="return false;">Foo</div>
|
||||
<div><input checked="checked" type="checkbox" onclick="return false;">Foo</div>
|
||||
</li>
|
||||
<li>
|
||||
<div><input type="checkbox" onclick="return false;"><b>Bar</b></div>
|
||||
|
@ -123,7 +123,9 @@ function enexXmlToHtml_(stream, resources) {
|
||||
section.lines = addResourceTag(section.lines, resource, nodeAttributes);
|
||||
}
|
||||
} else if (tagName == 'en-todo') {
|
||||
section.lines.push('<input type="checkbox" onclick="return false;" />');
|
||||
const nodeAttributes = attributeToLowerCase(node);
|
||||
const checkedHtml = nodeAttributes.checked && nodeAttributes.checked.toLowerCase() == 'true' ? ' checked="checked" ' : ' ';
|
||||
section.lines.push(`<input${checkedHtml}type="checkbox" onclick="return false;" />`);
|
||||
} else if (isSelfClosingTag(tagName)) {
|
||||
section.lines.push(`<${tagName}${attributesStr}/>`);
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user