You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(search-bar): make the placeholder readable in dark mode - #64
Fixes#54. The SearchBar prompt used Color.dash.black1000Alpha30, which has no dark variant, so in dark mode the placeholder was black on near-black.
What was done?
The prompt uses Color.dash.searchPlaceholder: the same black at 30% in light mode (identical colour, so the light reference does not change), white at 50% in dark mode. The dark snapshot reference, which had recorded the bug, is re-recorded from CI.
How Has This Been Tested?
swift build, .github/scripts/conventions.sh.
Snapshot job failed on the old dark reference as expected; the new one was fetched with .github/scripts/fetch-snapshots.sh (run 43237599092).
Before / After
Snapshot references (SearchBarSnapshotTests/testPlaceholderAndText). Light is unchanged (same colour); dark is re-recorded in 306b391.
Before
After
Light
Dark
No visual change (refactor, tests, docs). Say why in "What was done?".
Breaking Changes
None.
Checklist:
I have performed a self-review of my own code
I have commented my code, particularly in hard-to-understand areas
I have added or updated relevant unit/integration/functional/e2e tests
I have made corresponding changes to the documentation
The prompt used black1000Alpha30, which has no dark variant, so on a dark
background the placeholder was black on near-black. It now uses the
searchPlaceholder token: the same black at 30% in light mode, white at 50%
in dark mode.
Fixes#54
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The SearchBar placeholder now uses a theme-aware color token so it stays readable in dark mode, and the light-mode color is unchanged. No merge-blocking risk remains.
Pre-merge checks: 3 · 1
Failed checks: 1 inconclusive
Check name
Status
Explanation
Resolution
Linked Issues check
[#54] Code requirement met in source. The raw summary reports one changed line in Sources/DashUIKit/Components/SearchBar.swift (+1/-1). The prompt now uses Color.dash.searchPlaceholder instead of Colo…
Confirm the re-recorded dark reference testPlaceholderAndText.states-dark.png at head 306b391 matches the searchPlaceholder dark colour (white at 50%) and shows a readable placeholder. Reviewable evidence for that file is needed to reach a …
Passed checks: 3 passed
Check name
Status
Explanation
Description Check
Check skipped - CodeRabbit’s high-level summary is enabled.
Title check
The title names the scope (search-bar) and the change (placeholder readability in dark mode). The diff changes the SearchBar placeholder color from black1000Alpha30 to searchPlaceholder, and the linke…
Out of Scope Changes check
The only reported source change is the single prompt colour token swap in SearchBar.swift, which directly implements [#54]. The re-recorded dark snapshot reference supports the same fix and is a test …
Full details: Title check
Explanation
The title names the scope (search-bar) and the change (placeholder readability in dark mode). The diff changes the SearchBar placeholder color from black1000Alpha30 to searchPlaceholder, and the linked objectives confirm this targets dark-mode readability. The title is short, specific, and matches the main change.
Full details: Out of Scope Changes check
Explanation
The only reported source change is the single prompt colour token swap in SearchBar.swift, which directly implements [#54]. The re-recorded dark snapshot reference supports the same fix and is a test artifact tied to the change. The PR does not change the other Search* tokens. The issue lists those only as optional review items, so their absence is not out of scope. No unrelated change is evident in the summary.
Full details: Linked Issues check
Explanation
[#54] Code requirement met in source. The raw summary reports one changed line in Sources/DashUIKit/Components/SearchBar.swift (+1/-1). The prompt now uses Color.dash.searchPlaceholder instead of Color.dash.black1000Alpha30. This matches the issue Fix section. The token is black at 30% in light mode, so light references stay unchanged. [#54] Requirement to re-record the dark reference depends on SnapshotTests/Tests/DashUIKitSnapshotTests/Snapshots/SearchBarSnapshotTests/testPlaceholderAndText.states-dark.png. That file is excluded by ignored_files rule '!**/.png'. Its content cannot be inspected. The PR description states the file was re-recorded in commit 306b391, but this is not independently verified. The issue also asks for the change to make the placeholder readable in dark mode. The dark snapshot content cannot be confirmed from reviewable evidence. Other unused Search tokens are optional review items, not requirements.
Resolution
Confirm the re-recorded dark reference testPlaceholderAndText.states-dark.png at head 306b391 matches the searchPlaceholder dark colour (white at 50%) and shows a readable placeholder. Reviewable evidence for that file is needed to reach a verdict.
Finishing Touches
Generate unit tests (beta)
Commit to this branch
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.
Reviewing files that changed from the base of the PR and between 41ff490 and 306b391.
Files ignored due to path filters: 1
SnapshotTests/Tests/DashUIKitSnapshotTests/__Snapshots__/SearchBarSnapshotTests/testPlaceholderAndText.states-dark.png is excluded by !**/*.png
Files selected for processing: 1
Sources/DashUIKit/Components/SearchBar.swift
Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.
Rendered by the CI snapshot job for the searchPlaceholder change; the old
reference had recorded the unreadable placeholder.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Fixes #54 with the token that already existed for this purpose. searchPlaceholder has been in Color+DashUI.swift since the scaffold but was unused.
Light mode:SearchPlaceholder and Black1000Alpha30 have the same light value (#0A0B0D at 0.30), so the light reference is unchanged, as the description says.
Dark mode: white at 0.50, the same alpha as TextFieldPlaceholder from #61, so the two input placeholders now match in dark mode.
The dark snapshot reference was re-recorded from CI. The Before/After table links the base and head commits.
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
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.
Issue being fixed or feature implemented
Fixes #54. The
SearchBarprompt usedColor.dash.black1000Alpha30, which has no dark variant, so in dark mode the placeholder was black on near-black.What was done?
The prompt uses
Color.dash.searchPlaceholder: the same black at 30% in light mode (identical colour, so the light reference does not change), white at 50% in dark mode. The dark snapshot reference, which had recorded the bug, is re-recorded from CI.How Has This Been Tested?
swift build,.github/scripts/conventions.sh..github/scripts/fetch-snapshots.sh(run 43237599092).Before / After
Snapshot references (
SearchBarSnapshotTests/testPlaceholderAndText). Light is unchanged (same colour); dark is re-recorded in 306b391.Breaking Changes
None.
Checklist:
🤖 Generated with Claude Code
Summary by CodeRabbit