Star on GitHub0

Link Preview

Link Preview Component

The LinkPreview component is an interactive UI element that displays a preview of a link when hovered over. It enhances user experience by providing additional context about the link.

Features

  • Hover Preview: Displays a preview of the link when hovered.
  • Customizable Icon: Optionally show an icon next to the link text.
  • Interactive Design: Smooth animations and responsive behavior.
Loading component preview...

Source Code

Props

PropertyTypeDefaultDescription
link
string
required
The URL of the link to preview.
text
string
required
The text to display for the link.
showIcon
boolean
true
Whether to show an icon next to the link text.
...linkProps
React.HTMLAttributes<HTMLAnchorElement>
undefined
Additional props to pass to the anchor element.

Dependencies

This component uses the following third-party dependencies: