Skip to content
This repository was archived by the owner on Jan 6, 2023. It is now read-only.

Commit 48a3589

Browse files
committed
docs: UiPopover docstrings
1 parent cdfbb71 commit 48a3589

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed

addon/components/ui-popover/component.ts

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,36 @@ import UiContextualContainer, {
55
import { manageFlowThroughFocus } from '@nsf-open/ember-ui-foundation/utils';
66

77
/**
8+
* The UiPopover component attaches itself to its parent element - typically a
9+
* button - and will display some text context in a styled flyout when the parent
10+
* is clicked.
811
*
12+
* The major difference between this an UiTooltip is that the interaction is click
13+
* driven, and highly preferable if interactive content is to be rendered within
14+
* a flyout.
15+
*
16+
* ```handlebars
17+
* <UiButton @variant="primary">
18+
* Log In
19+
* <UiPopover @title="Please Log In to Your Account to Continue">
20+
* <div class="form-group">
21+
* <label for="username">Username</label>
22+
* <input type="text" id="username" class="form-control" />
23+
* </div>
24+
*
25+
* <div class="form-group">
26+
* <label for="password">Password</label>
27+
* <input type="password" id="password" class="form-control" />
28+
* </div>
29+
*
30+
* <div class="text-right">
31+
* <button type="button" class="btn btn-primary" onclick={{this.login}}>
32+
* Login
33+
* </button>
34+
* </div>
35+
* </UiPopover>
36+
* </UiButton>
37+
* ```
938
*/
1039
export default class UiPopoverContextContainer extends UiContextualContainer {
1140
/**

0 commit comments

Comments
 (0)