Skip to content
loseta

Components / Overlays

Hover Card

Shows a preview of content when a trigger is hovered or focused.

Status stableInstalls popover-primitive
@loseta

loseta

Native CSS component scaffolds with the shadcn feel.

Joined November 2026

<div style="display: flex; align-items: center; justify-content: center; min-height: 14rem">
  <span class="hover-card">
    <a href="#" aria-describedby="hover-card-profile">@loseta</a>
    <div data-popover data-side="bottom" data-align="start" id="hover-card-profile">
      <div>
        <h3>loseta</h3>
        <p>Native CSS component scaffolds with the shadcn feel.</p>
      </div>
      <p>Joined November 2026</p>
    </div>
  </span>
</div>

Installation

pnpm dlx loseta add hover-card
npx loseta add hover-card

Accessibility and behavior

  • CSS-only: opens on hover and focus-within with a 300ms delay. Point the trigger at the panel with aria-describedby. Use popover for interactive content that needs explicit dismissal.

Files

components/hover-card.cssbase
styles/nova/hover-card.cssstyle

Install contract

The CLI writes the base file under components/, the visual file for the selected style under styles/<name>/, and any primitive dependency underprimitives/. The generated index.css imports them in the right layer order.

← Back to components

loseta is MIT licensed. Built with native CSS, no runtime. Inspired byshadcn/ui.