Files
Sam SelikoffandGitHub a345140862 Instant navs devtools revamp (#94027)
This updates the Instant Navs DevTools panel to better model capture
state across pending, SPA, and MPA navigations.

- Revamps the Navigation Inspector UI states, controls, focus behavior,
and panel transitions
- Resets capture state when closing the panel from active capture states
- Keeps MPA reloads and root-layout-crossing navigations from briefly
showing stale or optimistic SPA state
- Consolidates the panel state flow so cookie state, re-arming, and
rendered UI status are easier to follow
- Expands the instant navs fixture and tests to cover SPA captures, MPA
captures, reloads, close/reset, Continue Rendering, and root-layout MPA
links
2026-05-22 12:54:48 -05:00

27 lines
493 B
TypeScript

'use client'
import { useEffect, useState } from 'react'
export function HydrationMarker() {
const [hydrated, setHydrated] = useState(false)
useEffect(() => {
setHydrated(true)
}, [])
return (
<span
data-testid="app-hydration-marker"
data-hydrated={hydrated ? 'true' : 'false'}
style={{
position: 'absolute',
width: 1,
height: 1,
overflow: 'hidden',
opacity: 0,
pointerEvents: 'none',
}}
/>
)
}