mcndt / obsidian-toggl-integration

A Toggl integration plugin for the popular knowledge base application Obsidian.
GNU General Public License v3.0
267 stars 19 forks source link

Additional status bar format options #150

Open leoccyao opened 6 months ago

leoccyao commented 6 months ago

An easy improvement, since the setting already exists. Code for handing numbers very similar to https://github.com/liamcain/obsidian-calendar-plugin/blob/master/src/settings.ts#L108-L122

Also removes a duplicate initiation of a status bar item (which has been creating additional spacing in the status bar)

Edit: also closes #151

leoccyao commented 6 months ago

Added a number more options for formatting the status bar. Increases the rate at which the status bar text is updated to once per second, though the Toggl API is still polled at the previous rate of every 6 seconds.

Partially remediates #5 (oops not #6, which refers to the sidebar), though does not yet allow full customization (a template string with substitutions such as "{project}" "{description}", such as how https://github.com/lukeleppan/better-word-count does it, would be a further improvement)

Also ran into the source of the bug for #151 while working on project in status bar!

socket-security[bot] commented 6 months ago

New dependencies detected. Learn more about Socket for GitHub ↗︎

Packages Version New capabilities Transitives Size Publisher
moment-duration-format 2.3.2 None +0 678 kB jsmreese
mcndt commented 5 months ago

Hi Leo, thanks for your PRs (also #149)!! I really appreciate other people building together on this.

I'm a bit in a slow mode when it comes to maintaining my Obsidian plugins, but I will try to take some time out of my schedule the next week or two to properly review and test your code, so that it can merge to main and ship to plugin users.

leoccyao commented 2 months ago

Just wondering if there's any update on when my contribution can be reviewed!