Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Spec for nimble-tooltip #595

Merged
merged 17 commits into from
Jun 16, 2022
Merged
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"type": "none",
"comment": "tooltip spec (#309)",
"packageName": "@ni/nimble-components",
"email": "[email protected]",
aidendk marked this conversation as resolved.
Show resolved Hide resolved
"dependentChangeType": "none"
}
65 changes: 65 additions & 0 deletions packages/nimble-components/src/tooltip/tooltip.spec.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
# Nimble Tooltip

## Overview

The `nimble-tooltip` is a popup that displays information related to an element when the element receives keyboard focus or the mouse hovers over it. It typically appears after a small delay and disappears when Escape is pressed or on mouse out. The Nimble tooltip is based upon [FAST's tooltip component](https://github.com/microsoft/fast/tree/master/packages/web-components/fast-foundation/src/tooltip)

aidendk marked this conversation as resolved.
Show resolved Hide resolved
### Background

[Nimble issue #309: Tooltip](https://github.com/ni/nimble/issues/309)

[Visual desgin spec](https://xd.adobe.com/view/8ce280ab-1559-4961-945c-182955c7780b-d9b1/screen/044414d7-1714-40f2-9679-2ce2c8202d1c/specs/)

---

## Design

### API

[FAST tooltip API](https://github.com/microsoft/fast/blob/de7f234ef871204fcac2b5df59433d919809341d/packages/web-components/fast-foundation/src/tooltip/tooltip.spec.md)

Plan to extend API to support all cases shown in visual design XD document. Will add
once tooltip is sucessfully implemented with one case.
aidendk marked this conversation as resolved.
Show resolved Hide resolved

- _Component Name:_ `nimble-tooltip`
- _Properties/Attributes:_ Unchanged
- _Methods:_ Unchanged
- _Events:_ Unchanged
- _CSS Classes and Custom Properties that affect the component:_ None
- _Slots:_ Unchanged
- _Template:_ Unchanged

### Angular integration

An Angular directive will be created for the component. The component will not have form association, so a `ControlValueAccessor` will not be created.

### Blazor integration

A Blazor wrapper will be created for the component.

### Additional requirements
aidendk marked this conversation as resolved.
Show resolved Hide resolved

- _User interaction: Do the FAST component's behaviors match the visual design spec? When they differ, which approach is preferable and why?_
- No additional requirements
- _Styling: Does FAST provide APIs to achieve the styling in the visual design spec?_
- FAST API most likely won't be sufficient for creating extra states in spec, will be adressed later on.
- _Testing: Is FAST's coverage sufficient? Should we write any tests beyond Chromatic visual tests?_
- Will look at options as building, testing may be difficult because only displayed on hover.
aidendk marked this conversation as resolved.
Show resolved Hide resolved
- _Documentation: Any requirements besides standard Storybook docs and updating the Example Client App demo?_
- No additional requirements
- _Tooling: Any new tools, updates to tools, code generation, etc?_
- No additional requirements
- _Accessibility: keyboard navigation/focus, form input, use with assistive technology, etc._
- All accessibility needs should be covered by FAST's implementation. We should do some manual testing to verify that the custom template doesn't break any accessibility behavior.
aidendk marked this conversation as resolved.
Show resolved Hide resolved
- _Globalization: special RTL handling, swapping of icons/visuals, localization, etc._
- No additional requirements
- _Performance: does the FAST component meet Nimble's performance requirements?_
- No additional requirements
- _Security: Any requirements for security?_
- No additional requirements

---

## Open Issues

None