Tooltip, popover, dropdown, and menu library
MIT License
Bot releases are visible (Hide)
Published by atomiks over 6 years ago
sticky
option positioning issue on FF due to new Popper.js positioning fixPublished by atomiks over 6 years ago
1.14.1
=> 1.14.2
which has some nice fixes for positioning and bundle size 😄tippy.one()
for creating one single tooltip, it will return the tooltip instance directlypointer-events
on round arrow SVG if not interactivePublished by atomiks over 6 years ago
fix: remove unnecessary files from npm package (#210)
Published by atomiks over 6 years ago
allowTitleHTML
option (#197)tippy.disableAnimations()
to modify defaults to apply no animations to tooltips (mainly for automated testing)Published by atomiks over 6 years ago
.tippy-popper
line-height to 1.4
to prevent descender letters like "g" and "y" from being cut off depending on the font/browser/OS. Will not affect themes with custom line-heights because of lower specificity.Published by atomiks over 6 years ago
Published by atomiks over 6 years ago
Published by atomiks over 6 years ago
livePlacement
option to prevent flipping on scroll.Published by atomiks over 6 years ago
Published by atomiks over 6 years ago
_tippy
dist/
arrowTransform
now doesn't require translate
when using scale
to be positioned accurately due to modified transform-origin
Published by atomiks almost 7 years ago
Published by atomiks almost 7 years ago
Published by atomiks almost 7 years ago
followCursor
+ delay
would not be shown at the correct initial positiontooltips
to an empty array upon destroyAll()
to free up memoryPublished by atomiks almost 7 years ago
followCursor
option if the tooltip is manually shownPublished by atomiks almost 7 years ago
[internal]: private members cleaned up
Published by atomiks almost 7 years ago
The full list of changes are described in the first beta notes.
This full release is the same as beta-2
API-wise with a single change to browser.eventsBound
as that is intended to be private, it's now browser._eventListenersBound
clip-path
to prevent text from overflowing the backdrop when animating fill if the background is sufficiently different from the text color (no IE/Edge support unfortunately)onTransitionEnd()
issue with onHidden
fixedPublished by atomiks almost 7 years ago
Second beta release.
disable()
and enable()
methods for when you want to temporarily disable a tooltip but not destroy ittippy.browser.onUserInputChange()
so you can react to a user's input method change (either mouse or touch). This means you can reliably disable tooltips for touch devices but keep them enabled for mouse if need be.enabled
and visible
properties to the Tippy.state
objectupdateDuration: 0
is specifiedinertia
transition-timing-function has changed to "ease" when it's hiding so it doesn't slingshot back in. To make it look good, use double the duration for show, such as duration: [600, 300]
Published by atomiks almost 7 years ago
Tippy just got a whole lot better.
The docs have been overhauled to display Tippy's features in a more organized fashion.
src
and tests
removed from /dist/
tippy.all.js
and tippy.all.min.js
are bundled versions of the JS and CSS. The CSS is automatically injected into the document's head, so all that's needed is the script file.Tippy instances are now single tooltip instances.
const btn = document.querySelector('.btn')
tippy(btn)
// The Tippy instance is now stored on the reference element via `_tippy`.
// No need to pass any arguments in.
btn._tippy.show()
btn._tippy.hide()
tippy()
is now differentconst tip = tippy('.btn')
tip = {
selector: '.btn',
options: { ... },
tooltips: [Tippy, Tippy, Tippy, ...],
destroyAll() { ... }
}
tippy
props/methodscamelCase has been applied to the naming of everything to simplify it.
tippy.Browser
is now tippy.browser
tippy.Defaults
is now tippy.defaults
tippy.enableDynamicInputDetection
(and disable) have been removed. Simply set the property to true or false inside the browser settings.
Reference elements now have a data-tippy
attribute applied instead of data-tooltipped
.
<button title="tooltip" data-tippy>text</button>
Tippy instances have been simplified.
el
is now reference
show(duration)
hide(duration)
destroy()
update()
removedgetPopperElement()
removedgetReferenceElement()
removedgetReferenceData()
removeddestroyAll()
removedTippy instances now only need 3 methods: show()
, hide()
, destroy()
, as it only refers to a single tooltip.
show()
and hide()
only take 1 argument: a custom transition duration, and destroy()
needs no arguments.
data-tippy-*
has replaced data-*
to prevent conflicts.position
is now placement
animation
has an extra choice: shift-toward
. Additionally, shift
is now shift-away
to better reflect the difference between the two.followCursor
changed the behavior so that the document is the delegate for mousemove
event instead of the reference element itself. This results in smoother behavior.arrowSize
has been replaced by arrowTransform
for far greater control over the arrow.stickyDuration
and flipDuration
are now 1 option: updateDuration
.createPopperInstanceOnInit
- specify whether to create popper instance on init rather than the first show (has a performance impact)arrowType
- Tippy has a new arrow type – 'Round'. It's a custom SVG shape.flip
- brings a popperOption to the base-level optionsflipBehavior
- brings a popperOption to the base-level optionsmaxWidth
- specify the max width of the tooltipThe CSS has been simplified.
Tooltips are smaller by default, including the small
and large
sizes.
.enter
and .leave
"global" classes which can cause conflicts have been replaced by [data-state="visible"
and [data-state="hidden"]
.
IDs are now tippy-{id}
rather than tippy-tooltip-{id}
light
and translucent
themes have been removed to simplify the CSS and reduce bundle size. There is now better documentation on creating a theme (mainly for the arrow which is tricky).[x-arrow]
is now .tippy-arrow
(triangle) or .tippy-roundarrow
(SVG)[x-circle]
is now .tippy-backdrop
.html-template
is now [data-html]
.tippy-active
instead of just .active
to prevent conflictshide()
calls when clicking / touch devices.Published by atomiks almost 7 years ago
Published by atomiks almost 7 years ago
followCursor
- where tooltip would be positioned too far away from cursor/reference if the tooltip was large