Feature Library

Site header and footer with a phone menu

<0.01 CPU ms
A still of the Site header and footer with a phone menu demo
Still
The live demo starts when it’s in view.Scroll inside the company page · open a dropdown, or choose Phone width and open Menu · Tab through the links

A sticky site header with logo, navigation, an optional call to action and a responsive phone menu.

The header condenses without shifting content. Includes a skip link, current-page state, one level of desktop dropdowns and a separate site footer with link columns, social links, a legal row and a form slot.

What it costs a frame

<0.01 ms
GPU
not used
CPU, median
<0.01 ms
CPU, 95th pct
<0.01 ms
Draw calls
0
Weight
Light

Measured 20 November 2026 on RTX 4060 Laptop, 13th Gen Intel(R) Core(TM) i9-13900H, Chrome 157, 1920×1080 at 1×. 600 frames × 3 rounds, median kept (rounds ranged CPU <0.01–<0.01 ms). What ran: Phone-width company page. The menu opens and closes twice from real input while sampled. Scroll and navigation otherwise run only in response to input. Phones: tiers are being measured next.

How steadily it runs on RTX 4060 Laptop · 13th Gen Intel(R) Core(TM) i9-13900H · reference

Typical frame ?
30.80 ms
1% low ?
30 fps
Varies by ?
±5.84 ms
All metricsRTX 4060 Laptop · 13th Gen Intel(R) Core(TM) i9-13900H · reference
p50p95p9916.01 ms32.95 ms +
How long each frame took. Most frames sit in the tall bars; a long tail to the right is hitching.

Frames run on a 60 Hz timer (a page demo), so most frames take about one tick, 16.7 ms: the spread around it is what matters.

Frames

Median (p50) ?
30.80 ms
p95 ?
31.70 ms
p99 ?
32.07 ms
Slowest ?
34.44 ms
Mean ?
27.99 ms
Standard deviation ?
5.84 ms
1% low ?
30 fps
0.1% low ?
29 fps
Hitches ?
0 of 600
Over budget ?
0 of 600

Main thread

Long tasks ?
0
Long frames ?
0
Event-loop delay ?
0.0 / 0.2 / 0.3 ms

Input

Interactions ?
8
Input to paint ?
2.7 ms, worst 31.4
Longest handler ?
2.6 ms

Memory

JavaScript heap ?
32.4 → 31.8 MB
Growth ?
-0.53 MB

Browser

JavaScript a frame ?
0.07 ms
All tasks a frame ?
0.31 ms
Layout / style ?
0.00 / 0.01 ms
Main thread busy ?
1%

Garbage collection

Collections ?
2 (1 minor, 1 major)
Pauses ?
7.1 ms in all, longest 3.9

What it needs

Renders with
DOM and CSSPlain DOM and CSS: every current browser.
Your browser
Runs hereNo WebGPU needed
Depends on
NothingNo other packages
With an agent
install("site-shell")Your coding agent reads its pitfalls and installs it through the library’s MCP server. Set it up

What it’s for

  1. Site header with navigation that collapses to a phone menu
  2. Site footer with links and legal controls
  3. Header and footer for marketing, product and company websites
  4. Sticky navigation with a logo, primary links and call to action

Pitfalls, in brief

  1. Keep anchor targets below the sticky header.
  2. Keep focus inside the phone menu while it is open.
  3. Use buttons for desktop dropdowns.
  4. Keep the reserved header space constant during condense.
  5. Pass the exact link href to setCurrent after route changes.
5 pitfalls in full, the hook-up guide, the module source and its tests come with the part.

Where it comes from

Written for the library. Adapted from published work, named below.

Hannes Andersson: Feature Library accessible-dialog scroll lock and focus handling.

site headersite footerphone menumobile navigationresponsivestickydropdownskip linklegal linksaccessibilitykeyboardright to left

Near it in the frame