Skip to content
This repository was archived by the owner on May 29, 2019. It is now read-only.

Commit 9a26b36

Browse files
brunolellischrisirhc
authored andcommitted
demo(tooltip): add tooltip-enable description, example
- Simple description about tooltip-enable. - Add section demonstrating tooltip-enable Closes #3372
1 parent f74b958 commit 9a26b36

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed

src/tooltip/docs/demo.html

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,5 +31,15 @@
3131
<label>Or use custom triggers, like focus: </label>
3232
<input type="text" value="Click me!" tooltip="See? Now click away..." tooltip-trigger="focus" tooltip-placement="right" class="form-control" />
3333
</div>
34+
35+
<div class="form-group" ng-class="{'has-error' : !inputModel}">
36+
<label>Disable tooltips conditionally:</label>
37+
<input type="text" ng-model="inputModel" class="form-control"
38+
placeholder="Hover over this for a tooltip until this is filled"
39+
tooltip="Enter something in this input field to disable this tooltip"
40+
tooltip-placement="top"
41+
tooltip-trigger="mouseenter"
42+
tooltip-enable="!inputModel" />
43+
</div>
3444
</form>
3545
</div>

src/tooltip/docs/readme.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@ will display:
1616
- `tooltip-popup-delay`: For how long should the user have to have the mouse
1717
over the element before the tooltip shows (in milliseconds)? Defaults to 0.
1818
- `tooltip-trigger`: What should trigger a show of the tooltip?
19+
Note: this attribute is no longer observable. See `tooltip-enable`.
20+
- `tooltip-enable`: Is it enabled? It will enable or disable the configured
21+
`tooltip-trigger`.
1922
- `tooltip-append-to-body`: Should the tooltip be appended to `$body` instead of
2023
the parent element?
2124

0 commit comments

Comments
 (0)