Skip to content

Commit fd71f35

Browse files
committed
Rename [md-tooltip] to [mdTooltip].
1 parent 3bd7adc commit fd71f35

File tree

5 files changed

+17
-19
lines changed

5 files changed

+17
-19
lines changed

src/demo-app/tabs/tabs-demo.html

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,9 +42,7 @@ <h1>Tab Group Demo - Dynamic Tabs</h1>
4242
</md-card-content>
4343
</md-card>
4444

45-
<md-tab-group class="demo-tab-group"
46-
mdDynamicHeight
47-
[(selectedIndex)]="activeTabIndex">
45+
<md-tab-group class="demo-tab-group" dynamicHeight [(selectedIndex)]="activeTabIndex">
4846
<md-tab *ngFor="let tab of dynamicTabs" [disabled]="tab.disabled">
4947
<template md-tab-label>{{tab.label}}</template>
5048
{{tab.content}}
@@ -92,7 +90,7 @@ <h1>Tab Group Demo - Dynamic Tabs</h1>
9290

9391
<h1>Tab Group Demo - Dynamic Height</h1>
9492

95-
<md-tab-group class="demo-tab-group" mdDynamicHeight>
93+
<md-tab-group class="demo-tab-group" dynamicHeight>
9694
<md-tab *ngFor="let tab of tabs" [disabled]="tab.disabled">
9795
<template md-tab-label>{{tab.label}}</template>
9896
{{tab.content}}

src/demo-app/tooltip/tooltip-demo.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@ <h1>Tooltip Demo</h1>
55
<button #tooltip="mdTooltip"
66
md-raised-button
77
color="primary"
8-
[md-tooltip]="message"
9-
[tooltipPosition]="position"
10-
[tooltipShowDelay]="showDelay"
11-
[tooltipHideDelay]="hideDelay">
8+
[mdTooltip]="message"
9+
[mdTooltipPosition]="position"
10+
[mdTooltipShowDelay]="showDelay"
11+
[mdTooltipHideDelay]="hideDelay">
1212
Mouse over to see the tooltip
1313
</button>
1414
</p>

src/lib/tooltip/README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,18 +6,18 @@ The positions `before` and `after` should be used instead of `left` and `right`
66
### Examples
77
A button with a tooltip
88
```html
9-
<button md-tooltip="some message" tooltipPosition="below">Button</button>
9+
<button mdTooltip="some message" mdTooltipPosition="below">Button</button>
1010
```
1111

1212

1313

14-
## `[md-tooltip]`
14+
## `[mdTooltip]`
1515
### Properties
1616

1717
| Name | Type | Description |
1818
| --- | --- | --- |
19-
| `md-tooltip` | `string` | The message to be displayed. |
20-
| `tooltipPosition` | `"before"|"after"|"above"|"below"|"left"|"right"` | The position of the tooltip. |
19+
| `mdTooltip` | `string` | The message to be displayed. |
20+
| `mdTooltipPosition` | `"before"|"after"|"above"|"below"|"left"|"right"` | The position of the tooltip. |
2121

2222
### Methods
2323

src/lib/tooltip/tooltip.spec.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -302,8 +302,8 @@ describe('MdTooltip', () => {
302302
selector: 'app',
303303
template: `
304304
<button *ngIf="showButton"
305-
[md-tooltip]="message"
306-
[tooltipPosition]="position">
305+
[mdTooltip]="message"
306+
[mdTooltipPosition]="position">
307307
Button
308308
</button>`
309309
})

src/lib/tooltip/tooltip.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ export const TOUCHEND_HIDE_DELAY = 1500;
4343
* https://material.google.com/components/tooltips.html
4444
*/
4545
@Directive({
46-
selector: '[md-tooltip], [mat-tooltip]',
46+
selector: '[md-tooltip], [mat-tooltip], [mdTooltip]',
4747
host: {
4848
'(longpress)': 'show()',
4949
'(touchend)': 'hide(' + TOUCHEND_HIDE_DELAY + ')',
@@ -58,7 +58,7 @@ export class MdTooltip {
5858

5959
/** Allows the user to define the position of the tooltip relative to the parent element */
6060
private _position: TooltipPosition = 'below';
61-
@Input('tooltipPosition') get position(): TooltipPosition {
61+
@Input('mdTooltipPosition') get position(): TooltipPosition {
6262
return this._position;
6363
}
6464

@@ -80,14 +80,14 @@ export class MdTooltip {
8080
}
8181

8282
/** The default delay in ms before showing the tooltip after show is called */
83-
@Input('tooltipShowDelay') showDelay = 0;
83+
@Input('mdTooltipShowDelay') showDelay = 0;
8484

8585
/** The default delay in ms before hiding the tooltip after hide is called */
86-
@Input('tooltipHideDelay') hideDelay = 0;
86+
@Input('mdTooltipHideDelay') hideDelay = 0;
8787

8888
/** The message to be displayed in the tooltip */
8989
private _message: string;
90-
@Input('md-tooltip') get message() {
90+
@Input('mdTooltip') get message() {
9191
return this._message;
9292
}
9393
set message(value: string) {

0 commit comments

Comments
 (0)