Skip to content

Add Tooltip component and state-rendering tests (loading/empty/error/success) - #688

Merged
mikewheeleer merged 2 commits into
StableRoute-Org:mainfrom
harshaaaaw:feat/tooltip-states-test
Jul 29, 2026
Merged

Add Tooltip component and state-rendering tests (loading/empty/error/success)#688
mikewheeleer merged 2 commits into
StableRoute-Org:mainfrom
harshaaaaw:feat/tooltip-states-test

Conversation

@harshaaaaw

Copy link
Copy Markdown
Contributor

What

Adds a Tooltip component for StableRoute-Org/Stableroute-frontend and tests asserting it renders correctly for the four mutually-exclusive states: loading, empty, error, and success.

How to use

<Tooltip status="success" message="Done">
  <button>Hover me</button>
</Tooltip>

How it works

The component renders its trigger children plus a role="status" surface driven by a status prop. States are mutually exclusive; the status text is exposed via aria-live="polite" for assistive tech.

Testing

  • 7 new tests covering all four states, mutual exclusivity, and a11y.
  • Full suite: 1247 passed, 72 suites. npm run lint clean.

Closes #685

@mikewheeleer
mikewheeleer merged commit 71e1c3c into StableRoute-Org:main Jul 29, 2026
mikewheeleer added a commit that referenced this pull request Jul 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add tests for the tooltips component states

3 participants