Ellpeck / ObsidianSimpleTimeTracker

Multi-purpose time trackers for your notes!
MIT License
132 stars 19 forks source link

Update Duration Accumulation to support displaying durations longer than 24 hours #12

Closed sudokyle closed 1 year ago

sudokyle commented 1 year ago

Problem

See #11 for description.

Solution

I think there are two ways of doing this and also keeping it simple:

  1. we use asHours instead of hours and just let the hours be the top most unit of time we aggregate with minute and second staying in their respective periods.
  2. We use year as the top most unit of time we aggregate and update to include month and day. So year would aggregate endlessly with month, day, hour, minute, and second staying in their respective periods.

I decided on option 1 so that we minimize how soon really large numbers start to show up as the tracker is used.

Ellpeck commented 1 year ago

Thanks so much! This looks great.

sudokyle commented 1 year ago

@Ellpeck I ran npm install and it changed some files so i committed that, should I revert that, or are those changes needed? Sorry, I'm a TS noob 😅

sudokyle commented 1 year ago

@Ellpeck no rush of course, just curious if when you have a chance, the version could be bumped, and a release for this could be cut? Or if you want me to open a PR that bumps the version so all you have to do is cut a release I can get that PR goin' for ya! Whatever flow and timeline works best for ya, just let me know 👍