Skip to content

feat: support invalid selectable state#9765

Draft
Saithej2k wants to merge 1 commit into
elastic:mainfrom
Saithej2k:feat/selectable-invalid-state
Draft

feat: support invalid selectable state#9765
Saithej2k wants to merge 1 commit into
elastic:mainfrom
Saithej2k:feat/selectable-invalid-state

Conversation

@Saithej2k

Copy link
Copy Markdown

Summary

  • Add an isInvalid prop to EuiSelectable.
  • Apply aria-invalid to both the searchable input and the options listbox.
  • Keep listbox aria-invalid in sync when the prop changes.

API Changes

component / parent prop / child change description
EuiSelectable isInvalid Added Marks the search input and listbox as invalid for assistive technologies.

Impact Assessment

Impact level: Low. This adds an optional accessibility prop without changing default behavior.

Testing

  • git diff --check
  • yarn --cwd packages/eui eslint src/components/selectable/selectable.tsx src/components/selectable/selectable_list/selectable_list.tsx src/components/selectable/selectable.test.tsx src/components/selectable/selectable_list/selectable_list.test.tsx
  • yarn --cwd packages/eui test-unit selectable.test.tsx selectable_list.test.tsx --runInBand
  • git push pre-push checks

Closes #8991

@github-actions

Copy link
Copy Markdown

👋 Since this is a community submitted pull request, a Buildkite build has not been started automatically. Would an Elastic organization member please verify the contents of this pull request and kick off a build manually?

@github-actions github-actions Bot added the community contribution (Don't delete - used for automation) label Jun 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

community contribution (Don't delete - used for automation)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[EuiSelectable] Support isInvalid prop

1 participant