logseq-plugin-todo-master icon indicating copy to clipboard operation
logseq-plugin-todo-master copied to clipboard

Feature request: Display "No progress to track" when there are no tasks to track

Open muhahaaa opened this issue 7 months ago • 0 comments

Problem: I'm using the extension for all of my meetings, and it is crucial for me to quickly identify any open tasks. Currently, it's somewhat challenging to differentiate between having no tasks and having only open tasks, as both display "0%". The only distinction is a slight color variation in the progress bar.

Solution: Display "No progress to track" when there are no tasks to track (refer to screenshot)

image

I have implemented the illustrated solution in my fork: https://github.com/muhahaaa/logseq-plugin-todo-master/blob/a725b2fa741256a09a988290562de692ec0544a8/src/progress-bar.tsx#L42

The only change necessary was in the declaration of the shortText variable: const shortText = total === 0 ? `No progress to track.` : `${percentage}%`;

muhahaaa avatar Dec 06 '23 14:12 muhahaaa