Repository navigation
fix(subtitles): shift tvOS size ladder down one notch - #55
Conversation
tvOS default subtitles read one size too big in the living room. Shift the ladder down so large (the default) takes the old medium value and every other preset moves down correspondingly; small becomes a new ~1.2x step below medium.
📝 WalkthroughWalkthroughThe tvOS-specific point-size values in ChangesSubtitle Font Size Preset Update
Estimated code review effort: 1 (Trivial) | ~3 minutes Possibly related issues
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
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. Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
iosApp/iosApp/Screens/Player/Subtitles/SubtitleAppearance.swift (1)
40-49: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winAdd tvOS test coverage for the new ladder.
The new tvOS values are internally consistent with the stated ~1.2x step ratios in the comment, and the naming/style conventions are followed. However,
SubtitleStylingOverrideTests.swift(per the provided snippet) only asserts the iOS ladder inside#if os(iOS); there's no equivalent tvOS assertion. Given this file has already needed a correction once ("defaults read one size too big in the living room" per the comment), adding a#if os(tvOS)test block would prevent silent regressions on the next rebase.♻️ Suggested test addition (in SubtitleStylingOverrideTests.swift)
func testFontSizePresetsRebasedForTVOS() { `#if` os(tvOS) XCTAssertEqual(SubtitleFontSizePreset.small.pointSize, 43) XCTAssertEqual(SubtitleFontSizePreset.medium.pointSize, 51) XCTAssertEqual(SubtitleFontSizePreset.large.pointSize, 63) XCTAssertEqual(SubtitleFontSizePreset.xlarge.pointSize, 74) XCTAssertEqual(SubtitleFontSizePreset.xxlarge.pointSize, 88) `#endif` }🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@iosApp/iosApp/Screens/Player/Subtitles/SubtitleAppearance.swift` around lines 40 - 49, Add tvOS coverage for the subtitle font-size ladder so the new preset values are asserted on that platform too. Update SubtitleStylingOverrideTests.swift by adding a `#if` os(tvOS) test alongside the existing iOS checks, and verify SubtitleFontSizePreset.small through .xxlarge match the new pointSize values in SubtitleAppearance. Keep the test names and enum references aligned with the existing subtitle styling tests so the tvOS rebasing cannot regress silently.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In `@iosApp/iosApp/Screens/Player/Subtitles/SubtitleAppearance.swift`:
- Around line 40-49: Add tvOS coverage for the subtitle font-size ladder so the
new preset values are asserted on that platform too. Update
SubtitleStylingOverrideTests.swift by adding a `#if` os(tvOS) test alongside the
existing iOS checks, and verify SubtitleFontSizePreset.small through .xxlarge
match the new pointSize values in SubtitleAppearance. Keep the test names and
enum references aligned with the existing subtitle styling tests so the tvOS
rebasing cannot regress silently.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro Plus
Run ID: 1e9e354c-5fa5-48ea-bdfb-daf8f8375b98
📒 Files selected for processing (1)
iosApp/iosApp/Screens/Player/Subtitles/SubtitleAppearance.swift
Summary
tvOS default subtitles read one size too big in the living room. This shifts the tvOS size ladder down one notch so
.large(the default) takes the old medium value, with every other preset moving down correspondingly.Only the tvOS block in
SubtitleAppearance.swiftchanged; iOS and macOS ladders are untouched.Test plan
Note
The aspect-ratio scale fix that was briefly bundled here is now split into #56. This branch still carries that commit until it's rebased out — see #56.