Skip to content

Feat/sidebar current task widget - #25

Open
MegaBadCoder wants to merge 2 commits into
mainfrom
feat/sidebar-current-task-widget
Open

Feat/sidebar current task widget#25
MegaBadCoder wants to merge 2 commits into
mainfrom
feat/sidebar-current-task-widget

Conversation

@MegaBadCoder

Copy link
Copy Markdown
Owner

No description provided.

i.seliverstov added 2 commits August 13, 2026 13:41
The widget answered "what am I on" but not "for how long" — the thing you
actually open it for — so you still had to go to the calendar. Each row now
carries the remaining time, a progress bar, and the pomodoro count, with a
left accent bar echoing the calendar's current-time line.
The window maths moved into a private getWindow(), so the active-task filter
and the progress readout are built on one definition and cannot disagree.
Header is now "Идёт сейчас": the old "Текущая задача" was singular while the
list can hold several rows.
Rows carry a border rather than relying on bg-sidebar-accent/40 alone — in
light mode that fill sat within 1.7% of the sidebar background (0.968 vs 0.985
oklch) and the rows were effectively invisible. The play button keeps its 32px
visual size but expands to a 44px hit area via ::before, and the progress fill
honours prefers-reduced-motion.
The row now says whether the timer is on this task — a red pulsing "идёт"
while it ticks, a muted "пауза" while it is armed but stopped.
This is not only a label: the play button is removed in the running state
because startTask() rewinds to the first phase, so a stray click on a live
task would discard the pomodoros already worked.
The paused state keeps a button, which resumes via toggleTimer instead of
restarting. That matters because startTask only *arms* a session — ticking
starts separately — so a row lands in `paused` immediately after the widget's
own play click. Dropping the button there would have made the widget unable to
start a timer at all.
timer-store now exposes activeTaskId; without it a row cannot tell "running"
from "running on something else".
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

@MegaBadCoder