1.0.7 • Published 5 months ago

rt-overflow-tooltip v1.0.7

Weekly downloads
-
License
MIT
Repository
github
Last release
5 months ago

About

RT Overflow Tooltip

npm.io

Install

npm i rt-overflow-tooltip
yarn add rt-overflow-tooltip

Provides directive that shows tooltip when text is overflowed.

Usage

Add RtOverflowTooltipModule in imports into your `module:

import {RtOverflowTooltipModule} from 'rt-overflow-tooltip';

@NgModule({
  ...
  imports: [
    ...
    RtOverflowTooltipModule,
    ...
  ],
  ...
})
export class YourModule {
}  

Apply the rt-overflow-tooltip attribute to the required element. Provided text will be displayed only if it is overflowed. RtOverflowTooltip extends MatToolTip so you can use all its properties.

Please note that RtOverflowTooltip only defines the tooltip's logic. You should define the display of the overflowing element itself.

Example

Simple usage:

<div>
  <div class="css-hide-overflow" [rtOverflowTooltip]="'tooltip'">Some text</div>
</div>

<style>
  .css-hide-overflow {
    display: block;
    width: 100px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
</style>

https://www.regulus.team/

1.0.7

5 months ago

1.0.6

8 months ago

1.0.5

11 months ago

1.0.4

11 months ago

1.0.3

11 months ago

1.0.2

11 months ago

1.0.1

11 months ago

1.0.0

11 months ago