Skip to content

feat(tui): use theme-aware glyph for sidebar folder icons (#882) - #893

Open
montionugera wants to merge 2 commits into
LargeModGames:mainfrom
montionugera:fix/issue-882
Open

montionugera wants to merge 2 commits into
LargeModGames:mainfrom
montionugera:fix/issue-882

Conversation

@montionugera

@montionugera montionugera commented Oct 18, 2026 •

Copy link
Copy Markdown

Closes #882

Summary

  • Replace color-bitmap folder emojis in the TUI sidebar and folder popups with monochrome Unicode glyphs that inherit the active theme foreground/highlight colors (theme.text, theme.hovered, theme.active, theme.selected).
  • Add unit tests in src/tui/ui/library.rs verifying folder icon glyph rendering and theme styling.

Verification

  • cargo test --lib --no-default-features --features tui library
  • cargo fmt --all -- --check

Summary by CodeRabbit

  • Style
    • Replaced folder emojis with the ▸ text icon in the Local Files sidebar, playlist folder rows, and add-track picker.
    • Folder icons now follow the configured theme’s text and highlight colors.

@coderabbitai

coderabbitai Bot commented Oct 18, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Repository: LargeModGames/spotatui/.coderabbit.yaml
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 4fef9317-5cdc-4ff8-845d-164d4343f387
📥 Commits

Reviewing files that changed from the base of the PR and between e53c928 and bffffb0.

📒 Files selected for processing: 1
  • CHANGELOG.md

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 3 remain after this review.

📝 Walkthrough

Folder rows in the Local Files sidebar, playlist views, and add-track picker now use the shared FOLDER_ICON text glyph instead of a folder emoji. Tests check the rendered glyph, theme text color, and localized folder prefix.

Changes: Folder icon rendering

Layer / File(s) Summary
Shared folder glyph and UI rendering
src/tui/ui/util.rs, src/tui/ui/library.rs, src/tui/ui/popups.rs, CHANGELOG.md
FOLDER_ICON is set to ▸ and replaces folder emojis in sidebar and picker rows. Back-navigation rows retain their arrow prefix. Tests check the rendered glyph, theme text color, and localized prefix. The changelog records the theme-aware folder icons.

Priority: ⬇️ Low

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Feature · Severity of issue fixed: Low

Merge Risk: ⚪ Minimal · up to bffff

No merge-blocking issue was identified in the folder icon rendering change.

Pre-merge checks: Passed 4
Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed The title uses the valid conventional-commit prefix feat(tui):, has a concise imperative subject, and accurately describes the theme-aware folder icon change. It focuses on the sidebar, while the ch…
Linked Issues check Passed Issue #882 requests theme-controlled color for the left-side folder icons. src/tui/ui/library.rs replaces the color emoji with the text glyph FOLDER_ICON for sidebar folder rows. The row rendering…
Out of Scope Changes check Passed The changes remain connected to #882. The shared FOLDER_ICON constant, sidebar updates, playlist-folder popup update, localization test update, changelog entry, and focused rendering tests support t…
Full details: Title check

Explanation

The title uses the valid conventional-commit prefix feat(tui):, has a concise imperative subject, and accurately describes the theme-aware folder icon change. It focuses on the sidebar, while the changes also cover folder popups, but it remains related to the main change.

Full details: Linked Issues check

Explanation

Issue #882 requests theme-controlled color for the left-side folder icons. src/tui/ui/library.rs replaces the color emoji with the text glyph FOLDER_ICON for sidebar folder rows. The row rendering uses the theme style, and tests verify the glyph and theme.text foreground color. The same glyph is used in playlist-folder popup rows in src/tui/ui/popups.rs.

Full details: Out of Scope Changes check

Explanation

The changes remain connected to #882. The shared FOLDER_ICON constant, sidebar updates, playlist-folder popup update, localization test update, changelog entry, and focused rendering tests support the folder-icon coloring objective. No unrelated change is demonstrated.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create a new PR
✨ Simplify code
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@codecov

codecov Bot commented Oct 18, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@LargeModGames LargeModGames left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add a line for this under ## [Unreleased] in CHANGELOG.md. The code and tests look good, so I'll merge after that.

@montionugera

Copy link
Copy Markdown
Author

Added an entry under ## [Unreleased] in CHANGELOG.md. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Coloring folder icons in the sidebar

2 participants