diff --git a/lib/core/checklist.dart b/lib/core/checklist.dart index 23d305c9..d9718889 100644 --- a/lib/core/checklist.dart +++ b/lib/core/checklist.dart @@ -327,9 +327,12 @@ class MarkdownRenderer implements md.NodeVisitor { var attr = element.attributes; print(attr); if (attr['class'] == 'todo' && attr['type'] == 'checkbox') { - bool val = attr.containsKey('checked'); - if (val) { - buffer.write('[x]'); + if (attr.containsKey('checked')) { + if (attr.containsKey('uppercase')) { + buffer.write('[X]'); + } else { + buffer.write('[x]'); + } } else { buffer.write('[ ]'); } diff --git a/test/checklist_test.dart b/test/checklist_test.dart index 3d078ff2..def2642c 100644 --- a/test/checklist_test.dart +++ b/test/checklist_test.dart @@ -229,7 +229,7 @@ How are you doing? - [ ] item 1 - [x] item 2 -- [x] item 3 +- [X] item 3 - [ ] item 4 - [ ] item 5 @@ -282,7 +282,7 @@ How are you doing? - [x] item 1 - [ ] Foo -- [x] item 3 +- [X] item 3 - [ ] item 4 - [ ] Howdy