New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

itooltip

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

itooltip

The JavaScript library let’s you transform native tooltip’s into customizable overlays.

latest
Source
npmnpm
Version
1.1.1
Version published
Maintainers
1
Created
Source

iTooltip

The JavaScript library let’s you transform native tooltip’s into customizable overlays.

Use:

<script src="/path/to/iTooltip.js"></script>
<script>
    var tooltip = new iTooltip();
    tooltip.init();
</script>

Change selector:

var tooltip = new iTooltip('.my-selector')
tooltip.init()

Set options:

var tooltip = new iTooltip()
tooltip.init({
    className: 'my-class-name',
    indentX: 3,
    indentY: 3,
    positionX: 'left',
    positionY: 'center'
})

Options:

  • className - Sets the class name for a block with a hint. Default: 'tooltip';
  • indentX - Horizontal indent from the cursor (in pixels). Default: 10;
  • indentY - Vertical indent from the cursor (in pixels). Default: 15;
  • positionX - The initial position of the tooltip horizontally. Default: 'right'. Variants: 'left', 'right', 'center';
  • positionY - The initial position of the tooltip vertically. Default: 'bottom'. Variants: 'top', 'bottom', 'center';

WARNING! positionX and positionY can not simultaneously have the value "center".

Change the style for the tooltip:

.tooltip { /* or your class if changed */
    background-color: #282c34;
    color: #98c379;
    /* other styles */
}

FAQs

Package last updated on 11 Sep 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts