ransome1 / sleek

todo.txt manager for Linux, Windows and MacOS, free and open-source (FOSS)
https://github.com/ransome1/sleek/wiki
MIT License
1.28k stars 99 forks source link

WIP: When friendly dates are enabled, group elements use friendly dates #717

Open jcarstairs-scottlogic opened 3 weeks ago

jcarstairs-scottlogic commented 3 weeks ago

This PR is a WIP. I'm putting it up so that nobody duplicates effort. And @ransome1, feel free to let me know if this the intent of this PR is not what you want, and I'll stop working on it!

TODO:


I love the 'friendly dates' feature. Right now, when you enable it in Settings, tags for due dates and threshold dates are displayed using localised, human-friendly words like 'today' and 'tomorrow' rather than ISO strings.

I would love it if this feature extended to 'group elements', ie the headings which appear above grouped todo items.

This PR does that. Now, when the user enables friendly dates in settings, those group elements use friendly dates. (If the user doesn't enable friendly dates in settings, nothing is different.)

Screenshot of group elements showing friendly dates for due dates

ransome1 commented 3 weeks ago

@jcarstairs-scottlogic Hey, thank you so much for the PR. I'm currently not really available but as soon as I find some time I will look into it and report back :) Very happy to see new contributions.

ransome1 commented 2 weeks ago

@jcarstairs-scottlogic I checked it out and it seems to work without any noticable issues :)

However I also agree, that the grouping of headlines, as done in the sidebar, might be necessary.

Only if grouped, it does really help the user to get a better overview of the tasks. But of course I also know, that this is not the easiest thing to achieve.

Screenshot 2024-06-14 at 11 49 33 AM

Anyhow I want to thank you for this first commit and hope we can fine grind this, as it is a nice addition.

joeacarstairs commented 2 weeks ago

@jcarstairs-scottlogic I checked it out and it seems to work without any noticable issues :)

However I also agree, that the grouping of headlines, as done in the sidebar, might be necessary.

Only if grouped, it does really help the user to get a better overview of the tasks. But of course I also know, that this is not the easiest thing to achieve.

Screenshot 2024-06-14 at 11 49 33 AM

Anyhow I want to thank you for this first commit and hope we can fine grind this, as it is a nice addition.

I see the problem -- well spotted! I've put aside some time next week for this