Skip to content

Uiux/discovery empty error states#130

Open
gabrieltemtsen wants to merge 1 commit into
RevoraOrg:masterfrom
gabrieltemtsen:uiux/discovery-empty-error-states
Open

Uiux/discovery empty error states#130
gabrieltemtsen wants to merge 1 commit into
RevoraOrg:masterfrom
gabrieltemtsen:uiux/discovery-empty-error-states

Conversation

@gabrieltemtsen
Copy link
Copy Markdown
Contributor

@gabrieltemtsen gabrieltemtsen commented Jun 2, 2026

closes #107

- Add DiscoveryState discriminated union (loaded | filtered-empty |
  truly-empty | error) to drive the result area in InvestorDiscovery
- Wire search input and filter toggle to live state resolution
- Add DiscoveryEmptyState component (exported, independently testable)
  - 'filtered' variant: echoes query, shows clear-filters CTA
  - 'truly-empty' variant: reassuring copy + how-it-works CTA
- Add DiscoveryErrorState component (exported, independently testable)
  - Retry button with attempt counter (singular/plural copy)
  - role='alert' + aria-live='assertive' for immediate SR announcement
- Add __simulateState prop for test/Storybook state overrides
- Add progressbar role + aria-valuenow/min/max on funding bars
- Add aria-pressed on filter toggle button
- Add aria-live='polite' on result section and filter indicator
- Add 10 design-system CSS tokens (--ds-*) and 11 component classes
  (.discovery-state-container, .discovery-state-icon-wrap,
   --empty / --error modifiers, .discovery-state-title/body/query/
   retry-hint/action, .discovery-filter-btn--active/badge)

WCAG 2.1 AA: SC 1.3.1, 1.4.3, 2.1.1, 2.4.3, 2.4.7, 4.1.3 addressed

Tests (src/components/InvestorDiscovery.test.tsx):
- 64 tests across 10 groups
- 97.56% stmts / 97.87% branches / 100% funcs / 100% lines
- Coverage threshold ≥95% enforced in vite.config.ts

Docs (docs/uiux/ux107-discovery-empty-error-states.md):
- State model, component API tables, token reference, CSS class list,
  layout diagram, ARIA table, WCAG mapping, test coverage summary

Closes RevoraOrg#107
@gabrieltemtsen gabrieltemtsen force-pushed the uiux/discovery-empty-error-states branch from 6795ff2 to 5371654 Compare June 2, 2026 10:34
@drips-wave
Copy link
Copy Markdown

drips-wave Bot commented Jun 2, 2026

@gabrieltemtsen Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

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.

[UI/UX Design] Design the empty and error states for the offering discovery results

1 participant