Closed nil0x42 closed 3 years ago
Hi, checking the generated source of unchecked todo item, it looks like this:
<input type="checkbox" disabled="disabled">
So in a script, I would just do something like:
note.getContent().includes('<input type="checkbox" disabled="disabled">');
In upcoming 0.46 I would create a saved search with this search string:
note.rawContent *=* '<input type="checkbox" disabled="disabled">'
(rawContent was just added and is not available in 0.45.X)
In upcoming 0.46 I would create a saved search with this search string:
note.rawContent *=* '<input type="checkbox" disabled="disabled">'
Wow ! awesome, i can't wait to try v0.46 :)
After trying & testing this feature in v0.46.0-beta with success, i'm now proud user of my new saved search:
Notes with pending tasks
note.type = text note.rawContent *=* '<input type="checkbox" disabled="disabled">'
So i'm closing this issue :)
Hi ! I am a heavy user of
day notes
and generally ofckeditor to-do lists
in my workflow. Therefore, i frequently forget old notes with a pending task.I would like to make a js plugin that checks if a text note has at least one
to-do list
checkbox unchecked, so i can decide to highlight it, or create asaved search note
to be able to list notes with pending tasks.Do you have some insight on how to achieve that ?
PS: If trilium was my baby, i would even include it as a built-in note property
note.todoCount
(defaulting to 0 for non-text notes)