Skip to main content

## Module library

Source
Expand description

Library browsing preferences — currently, which folders are hidden.

The setting replaces a hardcoded frontend filter that dropped any item literally named “Podcasts”, which was one user’s folder layout keyed on an English string and shipped to everyone. What is hidden is now a user choice made of stable ids, applied in the repository layer (`repository::exclusions`) so every query path agrees; the frontend only renders a picker over the candidates this module serves.

TRACES: UR-076 | DR-209

## Structs§

ExclusionCandidate
  Something the user may choose to hide: a library, or a folder directly inside one.

## Constants§

CANDIDATE_SCAN_LIMIT 🔒
  How many immediate children of a library the picker will consider.
LIBRARY_SETTINGS_KEY 🔒
  `app_settings` key holding the persisted library preferences (JSON).

## Functions§

library_get_exclusion_candidates
  The folders the user may choose to hide.
library_get_settings
  The library preferences currently in force.
library_set_settings
  Replace the library preferences: apply them to every subsequent query and persist them.
persist_library_settings 🔒
  Write the preferences to `app_settings`.
restore_library_settings
  Restore the persisted preferences at startup, into the exclusion set the repository consults.