This makes check box lists like the following snipped work:
- [X] Done
- [ ] not done
Further allow the start attr, sometimes generated for ordered lists.
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
for (let i=node.attributes.length; i--;) {
const name = node.attributes[i].name;
// TODO: we may want to also disallow class and id attrs
- if (!/^(class|id|name|href|src|alt|align|valign)$/i.test(name)) {
+ if (!/^(class|id|name|href|src|alt|align|valign|disabled|checked|start|type)$/i.test(name)) {
node.attributes.removeNamedItem(name);
}
}