LBD Components

lbd-tooltip

A Web Component for creating accessible tooltips

WAI-ARIA Authoring Practices

Examples

General usage example:

<script type="module" src="lbd-tooltip.js"></script>

<lbd-tooltip>
  <img
    src="https://images.unsplash.com/photo-1472099645785-5658abf4ff4e?ixlib=rb-1.2.1&ixid=eyJhcHBfaWQiOjEyMDd9&auto=format&fit=facearea&facepad=2&w=100&h=100&q=80"
    alt="Tom Cook profile picture"
    title="Tom Cook"
  />
</lbd-tooltip>

Features

This Web Component allows you to:

Installation

You have a few options (choose one of these):

  1. Install via npm: npm install @lunchbreakdev/lbd-tooltip
  2. Download the source manually from GitHub into your project.
  3. Skip this step and use the script directly via a 3rd party CDN (not recommended for production use)

Demo

Tom Cook profile picture

Changelog

Edit this page