ζ-1 abgeschlossen: DeepLinkRouter + Web-Header-Hide

- DeepLinkRouter als pure-Logic-Enum aus RootView extrahiert
  (resolveToWebURL, isExplorePath, route)
- 11 DeepLinkRouterTests grün: custom-scheme, https passthrough,
  Erkunden-vs-Lesen-Routing, Substring-Guard
- WebShellScripts.hideWebHeader: WKUserScript injiziert at
  document.start CSS, das den zitare-Web-Header
  (body header:has(a.brand)) ausblendet. Native TabBar
  übernimmt globale Navigation, Content bleibt sichtbar.
- Simulator-Verifikation: Quote rendert ohne doppelte Nav-Leiste,
  17 (UI + Unit) Tests grün

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
Till 2026-05-14 13:06:37 +02:00
parent 75b5e7113f
commit dd10f85cca
6 changed files with 166 additions and 36 deletions

View file

@ -102,6 +102,7 @@ final class WebNavState {
let config = WKWebViewConfiguration()
config.websiteDataStore = .default()
config.applicationNameForUserAgent = "ZitareNative/0.1 (iOS)"
config.userContentController.addUserScript(WebShellScripts.hideWebHeader)
let webView = WKWebView(frame: .zero, configuration: config)
webView.navigationDelegate = context.coordinator
webView.uiDelegate = context.coordinator
@ -149,6 +150,7 @@ final class WebNavState {
let config = WKWebViewConfiguration()
config.websiteDataStore = .default()
config.applicationNameForUserAgent = "ZitareNative/0.1 (macOS)"
config.userContentController.addUserScript(WebShellScripts.hideWebHeader)
let webView = WKWebView(frame: .zero, configuration: config)
webView.navigationDelegate = context.coordinator
webView.uiDelegate = context.coordinator