wrolpi/app/public
Roland 57985cea94
ui: media filtering is a per-theme setting, not a night-mode hardcode
Filtering media was keyed on `data-theme="night"`, which made it a property of
the theme that no user could turn off.  Some people want their media tinted to
match the interface; some want to see the actual image.

A theme now declares a filter and whether it starts on, and the user decides:

  night   night-red    on by default.  An unfiltered thumbnail undoes dark
                       adaptation, which is the whole point of the mode.
  amber   amber-mono   off by default.  Amber is a look, not a night-vision
                       aid, so media keeps its real colors until asked for.
  light   -            no filter offered, so no toggle is shown.
  dark    -

The choice is stored per theme, so wanting amber's tint says nothing about
wanting night's.  The toggle lives in the theme picker, which puts it on the
Settings page and in the gallery at once.

Mechanically the rules now key on a `data-media-filter` attribute rather than
`data-theme`: a rule keyed on the theme could not be turned off.  index.html
stamps that attribute before first paint alongside data-theme -- without it,
night mode paints a screen of unfiltered thumbnails while the bundle arrives
over a hotspot, costing the user the adaptation the theme exists to protect.
Tests cover both the attribute rule and the fact that the inline script's
duplicated ids and defaults still agree with names.ts.

The amber matrix is the same luminance collapse tinted to #ff9500 (red full,
green 0.584, blue zero) with a gentler gamma than night's: amber carries far
more luminance and clips to a flat wash otherwise.

The gallery gains a Media filtering section showing the WROLPi logo filtered,
beside an unfiltered copy that opts out with `night-unfiltered`.  That copy is
behind a click on purpose -- an unfiltered image is a bright patch, and night
mode should not spring one on someone reading in the dark.

ui-design.md gains the media filtering contract it never got in Phase 0,
including the note that a Phase 3 custom theme names an existing filter id and
cannot ship its own matrix, since that would be code rather than data.
2026-08-08 18:04:00 -06:00
..
epub Adding simple search to epub viewer. 2026-04-13 17:23:20 -06:00
android-chrome-192x192.png Zim/Kiwix (Wikipedia) feature 2023-07-10 21:30:40 -06:00
android-chrome-512x512.png Zim/Kiwix (Wikipedia) feature 2023-07-10 21:30:40 -06:00
apple-touch-icon.png Zim/Kiwix (Wikipedia) feature 2023-07-10 21:30:40 -06:00
favicon-16x16.png Zim/Kiwix (Wikipedia) feature 2023-07-10 21:30:40 -06:00
favicon-32x32.png Zim/Kiwix (Wikipedia) feature 2023-07-10 21:30:40 -06:00
favicon-blue.svg Changing favicon color when navbar color changes. 2026-02-04 12:28:55 -07:00
favicon-brown.svg Changing favicon color when navbar color changes. 2026-02-04 12:28:55 -07:00
favicon-green.svg Changing favicon color when navbar color changes. 2026-02-04 12:28:55 -07:00
favicon-grey.svg Changing favicon color when navbar color changes. 2026-02-04 12:28:55 -07:00
favicon-olive.svg Changing favicon color when navbar color changes. 2026-02-04 12:28:55 -07:00
favicon-orange.svg Changing favicon color when navbar color changes. 2026-02-04 12:28:55 -07:00
favicon-pink.svg Changing favicon color when navbar color changes. 2026-02-04 12:28:55 -07:00
favicon-purple.svg Changing favicon color when navbar color changes. 2026-02-04 12:28:55 -07:00
favicon-red.svg Changing favicon color when navbar color changes. 2026-02-04 12:28:55 -07:00
favicon-teal.svg Changing favicon color when navbar color changes. 2026-02-04 12:28:55 -07:00
favicon-violet.svg Changing favicon color when navbar color changes. 2026-02-04 12:28:55 -07:00
favicon-yellow.svg Changing favicon color when navbar color changes. 2026-02-04 12:28:55 -07:00
favicon.ico Zim/Kiwix (Wikipedia) feature 2023-07-10 21:30:40 -06:00
icon-transparent.png Fixing rebrand binary hook (wrong cwd) and using the new transparent logo. 2026-05-25 20:16:02 -06:00
icon.svg Fixing bug where file search would issue twice on load. 2023-04-09 14:34:33 -06:00
index.html ui: media filtering is a per-theme setting, not a night-mode hardcode 2026-08-08 18:04:00 -06:00
logo192.png Fixing JS warnings. 2022-09-23 11:25:55 -06:00
logo512.png Fixing JS warnings. 2022-09-23 11:25:55 -06:00
manifest.json Zim/Kiwix (Wikipedia) feature 2023-07-10 21:30:40 -06:00
mstile-150x150.png Zim/Kiwix (Wikipedia) feature 2023-07-10 21:30:40 -06:00
one-time-pad-cheat-sheet.pdf A new start 2021-11-01 16:43:09 -06:00
robots.txt A new start 2021-11-01 16:43:09 -06:00