Repository navigation
feat: add option to reverse the timer dial direction - #519
Open
MaximilianLoose wants to merge 3 commits into
Open
MaximilianLoose wants to merge 3 commits into
MaximilianLoose wants to merge 3 commits into
Conversation
MaximilianLoose
force-pushed
the
feat/change-dial-direction
branch
from
October 29, 2026 12:41
be8301c to
6a09a86
Compare
MaximilianLoose
force-pushed
the
feat/change-dial-direction
branch
from
October 29, 2026 12:44
6a09a86 to
f9af9a1
Compare
The tray icon always drew its progress arc clockwise, so it moved against the dial when "Reverse Dial Direction" was enabled. Mirror the arc around the vertical axis when the setting is on, and re-render the icon when the setting changes or is reset to defaults.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a setting to reverse the direction in which the timer dial moves.
The option is in Settings → Timer and is off by default, so existing
behavior is unchanged.
Changes
TimerDial.svelte: newdial_directionprop. When true, the SVG ismirrored horizontally (
scaleX(-1)), which reverses the arc's direction.The start point stays at the top. Works in elapsed and countdown mode;
progress calculation and tween animation are unchanged.
(
settings/defaults.rs,settings/mod.rs),types.tsandsettings.tsupdated to match.
TimerSection.svelte: new toggle in the settings UI.tray.rs,commands.rs,lib.rs): newreverse_directionfield in
TrayState. When set, the progress arc is mirrored around thevertical axis (the start point at 12 o'clock stays in place). The icon is
re-rendered immediately when the setting changes and the value is reset
with "Reset to defaults". Includes a unit test.
CStr::from_bytes_with_nul_unchecked(b"...\0")with a
c"..."literal to satisfyclippy::manual_c_str_literalsonmacOS.
Screenshots
Setting (Settings → Timer):
Notes
enanddetranslations are included; other languages need thenew keys.
Checklist
npm run formatnpm run checkcargo test --manifest-path src-tauri/Cargo.tomlcargo clippy --manifest-path src-tauri/Cargo.toml -- -D warnings