Show HN: I saw this cool navigation reveal, so I made a simple HTML+CSS version

Published: (February 7, 2026 at 12:45 PM EST)
1 min read

Source: Hacker News

This is a simple code exploration, inspired by (and stolen from) , and originally seen on X here.

Navigation reveal demo

In this example I implement a menu that is revealed when the user clicks a button, using only HTML + CSS (no JavaScript).

Clip‑paths

  1. Reveal circle – The menu is uncovered by a circle that expands from the top‑left corner to the bottom‑right corner. The clip‑path is calculated with:

    clip-path: circle(calc(1.42 * 100vmax) at 0 0);
    • 100vmax uses the larger of the viewport width or height.
    • Multiplying by 1.42 (≈ √2) ensures the circle’s diameter covers the diagonal of the viewport.
  2. Ray polygon – A polygon clip‑path simulates a “ray” effect. The polygon is currently hard‑coded, but it could be generated with JavaScript to adapt dynamically to different navigation dimensions and maintain responsiveness.

Thanks for stopping by.

0 views
Back to Blog

Related posts

Read more »

Build an Accessible Audio Controller

Overview After two days of ARIA theory lessons on freeCodeCamp, the next workshop focused on building an accessible audio controller. The session began with a...

Untitled

HTML html Cadastro de Produção PCP - Paris Atacado / CSS is included in the CSS section below / Salvar Lote 📥 Exportar para Excel .csv Limpar Todo o Banco 📋...