An open API service indexing awesome lists of open source software.

https://github.com/angular-ru/angular-ru-tooltip-example-app

DEMO: https://angular-ru.github.io/angular-ru-tooltip-example-app/
https://github.com/angular-ru/angular-ru-tooltip-example-app

Last synced: 5 days ago
JSON representation

DEMO: https://angular-ru.github.io/angular-ru-tooltip-example-app/

Awesome Lists containing this project

README

        

## Tooltip directive for your Angular app

[![npm version](https://badge.fury.io/js/%40angular-ru%2Ftooltip.svg)](https://badge.fury.io/js/%40angular-ru%2Ftooltip)
[![npm-stat](https://img.shields.io/npm/dt/@angular-ru/tooltip.svg)](https://npm-stat.com/charts.html?package=@angular-ru/tooltip&from=2017-01-12)

## Introduction

Demo: https://angular-ru.github.io/angular-ru-tooltip-example-app/

```bash
$ npm install @angular-ru/tooltip
```

- Add styles to `styles.scss` file:

```scss
@import '~@angular-ru/tooltip/styles';

// ...
```

```ts
import { TooltipModule } from '@angular-ru/tooltip';
import { NgModule } from '@angular/core';

@NgModule({
imports: [
// ...
TooltipModule.forRoot()
]
})
export class AppModule {}
```

#### Basic example

```html

Bottom

Right

Left

Top

```

The value of option `'[tooltip-placement]'` by default is `'top'`.

#### A custom template for the tooltip (html)

```html

Bottom with HTML

Hello {{ context.name }}

```