SpecOS SpecOS icon Styleguide

Link Preview

A link preview component that displays a preview card when hovering over a trigger element. Built on top of bits-ui's LinkPreview for accessibility and hover interactions.

Import

import LinkPreview from "$lib/components/LinkPreview.svelte";

Basic Usage

A simple link preview that shows content on hover.

Properties

open
Type
boolean
Default: false
Controls the open state of the link preview.
openDelay
Type
number
Default: 200
Delay in milliseconds before opening the preview on hover.
closeDelay
Type
number
Default: 200
Delay in milliseconds before closing the preview when hover ends.