Skip to content

Commit 74b6bde

Browse files
graycreateclaude
andcommitted
fix: improve tab bar icon visibility in dark mode
- Added .renderingMode(.template) to tab icons for proper tinting - Applied different opacity for selected (100%) vs unselected (60%) tab items - Icons now properly respect TintColor which switches to white in dark mode - Improved visual hierarchy with clearer selected/unselected state distinction 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
1 parent e64aaa6 commit 74b6bde

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

V2er/View/Widget/TabBar.swift

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ struct TabBar: View {
3838
.frame(height: 3)
3939
.cornerRadius(0)
4040
Image(tab.icon)
41+
.renderingMode(.template)
4142
.resizable()
4243
.scaledToFit()
4344
.frame(height: 18)
@@ -57,7 +58,7 @@ struct TabBar: View {
5758
.fontWeight(isSelected ? .semibold : .regular)
5859
.padding(.bottom, 8)
5960
}
60-
.foregroundColor(Color.tintColor)
61+
.foregroundColor(isSelected ? Color.tintColor : Color.tintColor.opacity(0.6))
6162
.background(self.bg(isSelected: isSelected))
6263
.padding(.horizontal, 16)
6364
.background(Color.almostClear)

0 commit comments

Comments
 (0)