We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Especially for <abbr title="Vermont Department of Health">VDH</abbr> elements with title attribute.
<abbr title="Vermont Department of Health">VDH</abbr>
title
Here are but biggest driver is going to be perf/bundle size. We don't need a lot of features
<button aria-label="Hey tooltip!" data-microtip-position="up" role="tooltip">
<span data-wenk="I'm to the right!" data-wenk-pos="right">Wenk to the right!</span>
<div class="tooltip">Hover over me <span class="tooltiptext">Tooltip text</span> </div>
<abbr data-tooltip="Vermont Department of Health">VDH</abbr> /
*[data-tooltip] { position: relative; } *[data-tooltip]::after { content: attr(data-tooltip); position: absolute; bottom: -145%; left: -100%; display: inline-block; white-space: pre; z-index: 99; padding: 2px 7px; font-size: 1rem; line-height: 1rem; color: white; background: black; box-shadow: 1px 1px 1px grey; border-radius: 3px; pointer-events: none; opacity: 0; transition: opacity 0.4s ease; transition-delay: 0.2s; } *[data-tooltip]:hover::after { opacity: 1; }
<button id="myButton">My Button</button>
var el = document.getElementByID("myButton") new Tooltip(el , { placement: 'top', // or bottom, left, right, and variations title: "Tooltip text" });
tippy('#myButton', {content: "I'm a Tippy tooltip!"})
<abbr title="Vermont Department of Health">VDH</abbr> /
document.querySelectorAll("body [title]").forEach(function(el) { var tooltip = document.createElement("div") tooltip.classList.add("tooltip-text") tooltip.innerText = el.title el.title = "" el.classList.add("tooltip") el.append(tooltip) el.onmouseover = function() { tooltip.classList.add("active"); setTimeout(function() {tooltip.classList.remove("active") }, 5000) } el.onmouseout = function() { tooltip.classList.remove("active") } });
The text was updated successfully, but these errors were encountered:
#23 add css tooltip
f458b7c
#85 remove tooltips from #23
5adcb94
KyleMit
No branches or pull requests
Especially for
<abbr title="Vermont Department of Health">VDH</abbr>
elements withtitle
attribute.Here are but biggest driver is going to be perf/bundle size. We don't need a lot of features
CSS
microtip - 1.2 KB
wenk - 0.7 KB
W3 Schools - 0.3 KB
Custom
JS
popper.js / tooltip.js - 7.3 KB + 2.2. KB
Tippy.js - 7.3 KB + 7.6 KB
Custom
The text was updated successfully, but these errors were encountered: