Global customization: startup route, default sorts, layout, icons, playbar labels, format templates, table columns#357
Merged
Conversation
…sorts, layout positions, icons, playbar labels, format templates, table columns
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.
Makes nearly every part of the UI configurable via config.yml and the Settings screen.
What's new
behavior.startup_route): open on Home, Recently Played, Podcasts, Discover, Artists, or Saved Albums. The screen's data is fetched at startup so it arrives populated.default_sort_playlist_tracks/_saved_albums/_saved_artists/_recently_played):fieldorfield:desc, validated against each screen's available fields. Recently Played gets real sort state (config-seeded, applied on fetch).sidebar_position: left|right|hidden(hidden auto-reveals while the sidebar has focus),playbar_position: bottom|top, configurable responsive breakpoints (small_terminal_width/_height). Layout math is unified incore/layout.rsand shared by rendering and mouse hit-testing, so hitboxes match in every arrangement by construction.behavior.playbar_control_labels): relabel the clickable playbar buttons; hitboxes resize to fit.format:): the playbar status line and window title are{key}templates (newcore/format.rs, zero deps); defaults reproduce the previous output.tables:): reorder, remove, rename, and resize the columns of every track/album/podcast table (newtui/ui/columns.rsregistry).status_message_ttl_percent,playback_poll_seconds,table_scroll_padding,like_animation_frames.Safe by default
Structural config errors (unknown sort field, bad template key, invalid column id, too-wide icon, unknown label key) warn and fall back to the built-in default instead of aborting startup, so a config typo can never brick the app. Only YAML syntax errors and the pre-existing numeric range checks remain fatal.
Docs
docs/configuration.md: full customization guide (valid values per field, template placeholder tables, column ids per table)examples/config.example.yml: commented example covering every new section, guarded by a test that runs it through the real loaderTesting
cargo fmt/clippy -D warnings(slim) clean; full default-features build compiles