Readable Start/Stop colours, exact selectors, fork notes

- Colour-coded Start/Stop links use #2e7d32 / #c62828, which meet the
  4.5:1 text contrast ratio on white and on the mobile backgrounds
  (limegreen was ~2:1, red ~4:1)
- Selectors match the end of the link address (/timer/start,
  /timer/stop), exactly what stopwatch.js rewrites, instead of any
  address containing "start"/"stop"
- highlighted_links setting uses a string key like default_activity,
  has a default, and the form sends 0 when unticked
- Context-menu hook uses the calling view (hook_caller) instead of
  building a new view context
- README: "Changes in this fork" section (GPLv3 modification notice)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BiwYMjhoQvL7XsKKfRz4pM
This commit is contained in:
Claude committed 2026-10-28 23:54:19 -04:00
1 parent ec38414f06
commit fe0933c132
6 files changed
+37 -18

No files matched your search

+2 -1
View File
@@ -5,5 +5,6 @@
<p>
<label for="settings_highlighted_links"><%= t '.label_highlighted_links' %> </label>
<%= check_box_tag 'settings[highlighted_links]', 1, Setting.plugin_stopwatch[:highlighted_links] %>
<%= hidden_field_tag 'settings[highlighted_links]', '0', id: nil %>
<%= check_box_tag 'settings[highlighted_links]', '1', Stopwatch.highlighted_links, id: 'settings_highlighted_links' %>
</p>