Files
Copilot 59aabcef31 Fix themed status-bar/notch color rendering as white after SwiftUI migration (#4761)
## Summary
After the SwiftUI migration (#4748), the themed status-bar bar moved
from a UIKit `statusBarView` to a SwiftUI `themedStatusBar` in
`HomeAssistantView`. The new implementation rendered nothing, exposing
the white window background in the notch/status-bar area instead of the
theme color.

Root cause: the bar was built as

```swift
Color(uiColor: color)
    .frame(maxWidth: .infinity)
    .frame(height: 0)
    .ignoresSafeArea(edges: .top)
```

The rigid `.frame(height: 0)` collapses the colored region to zero
height — `ignoresSafeArea` can't grow a fixed-size frame — so the top
safe-area inset stayed empty and showed white (the web view is inset
below it when the bar is enabled).

Changes (`Sources/App/Frontend/WebView/HomeAssistantView.swift`):
- Draw the theme color as a full-bleed
`Color(uiColor:).ignoresSafeArea()` layer applied via
`.background(themedStatusBar)` instead of a zero-height `.overlay`. The
opaque, top-inset web view covers everything below the status bar, so
only the top inset shows the color.
- Behavior unchanged for edge-to-edge/full-screen (`statusBarColor ==
nil` → no bar) and empty-state overlays (respect the safe area, so the
themed inset still shows).

## Screenshots
<!-- If this is a user-facing change not in the frontend, please include
screenshots in light and dark mode. -->

## Link to pull request in Documentation repository
Documentation: home-assistant/companion.home-assistant#

## Any other notes
Verified on Linux without Xcode, so the iOS target was not compiled; the
change is confined to SwiftUI status-bar rendering.

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
2026-06-17 15:15:23 +00:00
..