Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/pleerock/ngx-tooltip
Simple tooltip control for your angular2 applications using bootstrap3. Does not depend of jquery.
https://github.com/pleerock/ngx-tooltip
Last synced: about 1 month ago
JSON representation
Simple tooltip control for your angular2 applications using bootstrap3. Does not depend of jquery.
- Host: GitHub
- URL: https://github.com/pleerock/ngx-tooltip
- Owner: pleerock
- Archived: true
- Created: 2016-06-16T09:08:26.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2017-04-03T07:55:12.000Z (over 7 years ago)
- Last Synced: 2024-10-26T05:41:49.020Z (about 2 months ago)
- Language: TypeScript
- Size: 85 KB
- Stars: 84
- Watchers: 5
- Forks: 62
- Open Issues: 15
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-angular - ngx-tooltip - Simple tooltip control for your angular2 applications using bootstrap3. Does not depend of jquery. (Uncategorized / Uncategorized)
- awesome-angular-components - pleerock/ngx-tooltip - Simple tooltip control for your angular2 applications using bootstrap3. Does not depend of jquery. (UI Components / Tooltip)
README
> This repository is for demonstration purposes of how it can be implemented in Angular and is not maintaned. Please fork and maintain your own version of this repository.
# ngx-tooltip
Simple tooltip control for your angular2 applications using bootstrap3. Does not depend of jquery.
If you want to use it without bootstrap - simply create proper css classes. Please star a project if you liked it, or create an issue if you have problems with it.![angular 2 tooltip](https://raw.githubusercontent.com/pleerock/ngx-tooltip/master/resources/tooltip-example.png)
## Installation
1. Install npm module:
`npm install ngx-tooltip --save`
2. If you are using system.js you may want to add this into `map` and `package` config:
```json
{
"map": {
"ngx-tooltip": "node_modules/ngx-tooltip"
},
"packages": {
"ngx-tooltip": { "main": "index.js", "defaultExtension": "js" }
}
}
```## Usage
Example of simple usage:
```html
element on which this tooltip is applied.
```Example of usage with dynamic html content:
```html
Very Dynamic Reusable
Tooltip With Html support.element on which this tooltip is applied.
```* ``:
* `tooltip="string"` The message to be shown in the tooltip.
* `[tooltipDisabled]="true|false"` Indicates if tooltip should be disabled. If tooltip is disabled then it will not be shown. Default is **false**
* `[tooltipAnimation]="true|false"` Indicates if all tooltip should be shown with animation or not. Default is **true**.
* `tooltipPlacement="top|bottom|left|right"` Indicates where the tooltip should be placed. Default is **"bottom"**.
* ``:
* `[animation]="true|false"` Indicates if all tooltip should be shown with animation or not. Default is **true**.
* `placement="top|bottom|left|right"` Indicates where the tooltip should be placed. Default is **"bottom"**.## Sample
```typescript
import {Component} from "@angular/core";
import {TooltipModule} from "ngx-tooltip";@Component({
selector: "app",
template: `
It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout.
The point of using Lorem Ipsum is that it has a more-or-less normal distribution of letters, as opposed to using 'Content here, content here', making it look like readable English.
Many desktop publishing packages and web page editors now use Lorem Ipsum as their default model text, and a search for 'lorem ipsum' will uncover many web sites still in their infancy.
Various versions have evolved over the years, sometimes by accident, sometimes on purpose (injected humour and the like)
Very Dynamic Reusable
Tooltip With Html support.
hover this button to see a tooltip
`
})
export class App {}
@NgModule({
imports: [
// ...
TooltipModule
],
declarations: [
App
],
bootstrap: [
App
]
})
export class AppModule {}
```Take a look on samples in [./sample](https://github.com/pleerock/ngx-tooltip/tree/master/sample) for more examples of
usages.