Skip to content
Devix Open Source

Nothing can cover it or clip it

The anchor sits inside an overflow:hidden box, on a page with an element at the maximum z-index. Hover it — and then try the same thing the old way.

Live preview
<div class="demo demo--wide">
  <div class="card">
    <p class="demo-hint">A card with <code>overflow: hidden</code></p>
    <button class="demo-btn demo-btn--ghost" id="good">Top layer</button>
    <button class="demo-btn demo-btn--ghost" id="bad">The old way</button>
  </div>

  <div class="stack">z-index: 2147483647 lives here</div>

  <div class="demo-row">
    <div class="demo-seg" id="placement" role="group" aria-label="Placement">
      <button type="button" data-placement="top">top</button>
      <button type="button" data-placement="bottom" aria-pressed="true">bottom</button>
      <button type="button" data-placement="left">left</button>
      <button type="button" data-placement="right">right</button>
    </div>
  </div>

  <dl class="demo-kv" id="out"></dl>

  <p class="demo-hint">Escape closes it without moving the mouse. Move the pointer onto the panel and
    it stays. Both are <strong>WCAG 2.2 SC 1.4.13</strong>, and both have a test.</p>
</div>