Skip to content

Fix PlayerBar layout at narrow widths - #270

Merged
sozercan merged 3 commits into
sozercan:mainfrom
itsmeshibintmz:fix/playerbar-compact-controls
May 31, 2026
Merged

Fix PlayerBar layout at narrow widths#270
sozercan merged 3 commits into
sozercan:mainfrom
itsmeshibintmz:fix/playerbar-compact-controls

Conversation

@itsmeshibintmz

Copy link
Copy Markdown
Contributor

Description

Fixes PlayerBar control overflow at narrow window widths by switching secondary controls into a compact overflow menu and increasing the main window minimum width to match the compact layout breakpoint.

AI Prompt (Optional)

🤖 AI Prompt Used
Fix PlayerBar layout at narrow widths.

AI Tool: Codex

Type of Change

  • 🐛 Bug fix (non-breaking change that fixes an issue)
  • ✨ New feature (non-breaking change that adds functionality)
  • 💥 Breaking change (fix or feature that would cause existing functionality to change)
  • 📚 Documentation update
  • 🎨 UI/UX improvement
  • ♻️ Refactoring (no functional changes)
  • 🧪 Test update
  • 🔧 Build/CI configuration

Related Issues

Fixes #

Changes Made

  • Added width tracking for PlayerBar to detect compact layouts below 980pt.
  • Moved AirPlay, like/dislike, lyrics, queue, mini player, and video actions into a compact “More” menu at narrow widths.
  • Kept volume controls visible while reducing horizontal pressure on the PlayerBar.
  • Preserved seek/progress layout by layering expanded seek controls over compact progress state.
  • Updated main window minimum width from 900pt to 980pt.

Testing

  • Unit tests pass (xcodebuild test -only-testing:KasetTests)
  • Manual testing performed
  • UI tested on macOS 26+

Checklist

  • My code follows the project's style guidelines
  • I have run swiftlint --strict && swiftformat .
  • I have added tests that prove my fix/feature works
  • New and existing unit tests pass locally
  • I have updated documentation if needed
  • I have checked for any performance implications
  • My changes generate no new warnings

Screenshots

  • Added screenshots or recordings showing the PlayerBar at narrow and normal widths.
Screenshot 2026-05-28 at 4 54 57 PM

Additional Notes

This is a layout-only fix. It does not change playback behavior or introduce new dependencies.

Copilot AI review requested due to automatic review settings May 28, 2026 11:27

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: c8cb0b8e19

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +199 to +201
if self.playerService.isCurrentItemLive {
self.liveIndicatorView
.transition(.opacity)

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Gate live indicator behind hover state

For live items, this branch now renders liveIndicatorView whenever a track is present, even when showsSeekControls is false. In the center ZStack, the normal track info remains visible at rest, so the LIVE badge can overlap the title/artist instead of only replacing the seek area on hover as it did before; this affects live radio/stream playback in the player bar.

Useful? React with 👍 / 👎.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

Fixed. The LIVE indicator is now opacity-gated by `showsSeekControls`, so it only appears while hovering the player bar seek area and no longer overlaps the track title/artist at rest.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot's findings

  • Files reviewed: 2/2 changed files
  • Comments generated: 0 new

@sozercan
sozercan merged commit b886bd8 into sozercan:main May 31, 2026
6 checks passed
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.

3 participants