Skip to content

fix(sidebar): stack the empty Favorites actions so the view fits the sidebar on macOS 15 - #2229

Merged
datlechin merged 1 commit into
TableProApp:mainfrom
manfad:fix/favorites-empty-state-narrow-sidebar
Aug 19, 2026
Merged

fix(sidebar): stack the empty Favorites actions so the view fits the sidebar on macOS 15#2229
datlechin merged 1 commit into
TableProApp:mainfrom
manfad:fix/favorites-empty-state-narrow-sidebar

Conversation

@manfad

@manfad manfad commented Aug 19, 2026

Copy link
Copy Markdown
Contributor

On macOS 15 the empty Favorites sidebar does not fit its own width. The description and the three action buttons run past both edges and are cut off, so "New Favorite..." and "Link a Folder..." cannot be read (TablePro 0.66.0, macOS 15.6.1, sidebar at its default width):

Empty Favorites sidebar on macOS 15 with the description and buttons clipped on both sides

Root cause

ContentUnavailableView lays its actions out in a row. Three buttons side by side are wider than the sidebar, and on macOS 15 the view sizes its whole content to that row instead of the width it was given, so the description wraps at the row's width and the entire block overflows. It is not the description that is too wide: with the buttons stacked, the same text wraps inside 220 pt.

Change

FavoritesTabView.emptyState wraps the three buttons in a VStack(spacing: 8). That is the only layout change; the view stays a stock ContentUnavailableView like the other sidebar empty states, and the strings and actions are untouched. A doc comment on the property records why the actions are stacked, so it is not "simplified" back into a row.

Before / after

Same view code, rendered at sidebar widths of 260 pt and 220 pt on macOS 15.6.1:

Before and after at 260 pt: buttons stacked, description wraps inside the width

Before and after at 220 pt

Verification

  • The after renders above are from a small standalone SwiftUI harness on macOS 15.6.1 that hosts the exact emptyState body (literal strings, no-op actions) in a 260 pt and a 220 pt window and snapshots the view. Its "before" reproduces the clipping in the app screenshot pixel for pixel. I could not build TablePro itself here (Xcode 16.4, the project needs Xcode 26), so please give it a run on a Mac with Xcode 26; the diff is a plain VStack wrapper and should not behave differently.
  • swiftlint lint --strict is clean on FavoritesTabView.swift.
  • CHANGELOG.md has an entry under [Unreleased] > Fixed.
  • No tests: pure layout, no logic touched.

🤖 Generated with Claude Code

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits.
Repo admins can enable using credits for code reviews in their settings.

@datlechin datlechin left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thank you

@datlechin
datlechin merged commit da7d014 into TableProApp:main Aug 19, 2026
4 of 5 checks passed
@manfad
manfad deleted the fix/favorites-empty-state-narrow-sidebar branch August 19, 2026 07:16
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.

2 participants