YouTip LogoYouTip

Api Tooltip

# jQuery UI API - Tooltip Widget ## Category (#) ## Usage **Description:** A customizable, themeable tooltip, replacing native tooltips. **Added in:** 1.9 The Tooltip replaces native tooltips, making them themeable and allowing for various customizations: * Show content other than just the title, such as inline footnotes or extra content retrieved via Ajax. * Custom positioning, such as centering the tooltip on an element. * Add extra styling to customize the appearance of warning or error areas. By default, a fade animation is used to show and hide tooltips, which looks more lively than simply toggling visibility. This can be customized with the [`show`](#) and [`hide`](#) options. The [`items`](#) and [`content`](#) options need to be kept in sync. If you change one, you need to change the other as well. In general, disabled elements do not fire any DOM events. Therefore, it is not possible to properly control tooltips on disabled elements, as we need to listen for events to determine when to show and hide the tooltip. This means that jQuery UI cannot guarantee any level of support for tooltips attached to disabled elements. This means that if you need to provide tooltips for disabled elements, you may need to use a combination of native tooltips and the jQuery UI Tooltip. ### Theming The Tooltip widget uses the (#) to define its look and feel. To use tooltip-specific styles, use the following CSS class names: * `ui-tooltip`: The outer container for the tooltip. * `ui-tooltip-content`: The content of the tooltip. ### Dependencies (optional; used with the [`show`](#) and [`hide`](#) options) ### Additional Notes * This widget requires some functional CSS, otherwise it won't work. If you create a custom theme, use the widget's specific CSS file as a starting point. ## Example Create a tooltip on the document, using event delegation on all elements with a title attribute. Tooltip Widget Demo

Anchor text

$( document ).tooltip(); (#) [](#)[jQuery UI API – Tabs Widget](#) [jQuery UI Example – Draggable](#)[](#) [Volcengine Coding Plan supports mainstream large models like Doubao, GLM, DeepSeek, Kimi, MiniMax, officially supplied, stable and reliable. Configuration Guide Β₯9.9/month Subscribe Now](https://maas.xfyun.cn/modelSquare?ch=maas_lm_l2E)
← Dom Obj KeygenApi Tabs β†’