Skip to content

fix: settings/db-provider accessibility - #13999

Merged
deon-sanchez merged 17 commits into
release-1.12.0from
db-provider-a11y
Jul 22, 2026
Merged

fix: settings/db-provider accessibility#13999
deon-sanchez merged 17 commits into
release-1.12.0from
db-provider-a11y

Conversation

@deon-sanchez

@deon-sanchez deon-sanchez commented Jul 9, 2026

Copy link
Copy Markdown
Collaborator

This pull request introduces a comprehensive accessibility (a11y) testing framework for the Langflow frontend, including new documentation, GitHub Actions workflows for both route-based and component-level accessibility scans, and supporting skill guides. It also adds an internationalization (i18n) review skill and updates E2E testing tag requirements. These changes ensure that user-facing text and UI components are accessible and properly internationalized, and that E2E tests are consistently tagged for release coverage.

Accessibility Testing Infrastructure

  • Added .github/workflows/a11y-scan.yml to run IBM Equal Access accessibility scans on frontend routes using Playwright, with job summary and artifact upload. This workflow runs on PRs, on a nightly schedule, and via manual dispatch.
  • Added .github/workflows/a11y-unit-tests.yml to run jest-axe component-level accessibility unit tests on frontend changes, blocking PRs on regressions.
  • Added .agents/skills/ibm-a11y-automation/SKILL.md with detailed instructions for running and interpreting the accessibility scanner, including route selection, state actions, and reporting.

Internationalization (i18n) Review

  • Added .agents/skills/frontend-i18n/SKILL.md describing the i18n system, review checklist, and rules for user-facing text in the frontend, ensuring all UI strings go through the translation system and are present in all locale files.
  • Updated .agents/skills/frontend-code-review/SKILL.md to reference the new i18n review skill for any diffs that add or change user-facing text.

E2E Testing Tag Policy

  • Updated .agents/skills/e2e-testing/SKILL.md to require every test to be tagged with @release and clarified allowed domain tags, ensuring tests are included in release coverage. [1] [2]

CI Workflow and Filter Updates

  • Updated .github/workflows/ci.yml to only run Python tests when relevant files are changed, improving CI efficiency.
  • Removed the unused mainpage filter from .github/changes-filter.yaml.

QA: /settings/db-providers accessibility

Automated

cd src/frontend
npx playwright test tests/a11y/db-providers.a11y.spec.ts --grep "@release"

Optional route scan:

uv run python scripts/a11y/a11y_scan.py \
  --url http://localhost:3000 \
  --route /settings/db-providers \
  --out /tmp/db-providers-a11y.json \
  --html /tmp/db-providers-a11y.html

Expect 0 violations on default load.

Manual checklist

Open Settings → DB Providers. Prefer Chrome + one other browser. Use keyboard-only + VoiceOver/NVDA for SR checks.

Keyboard

  • Tab through provider list; focus ring visible; Enter/Space selects provider
  • Form fields are labeled; empty required fields keep Test connection / Save and use disabled
  • OpenSearch SSL / Verify certs toggles work with Space
  • Masked password clears on focus for re-entry
  • Save / test connection: button disables while pending and keeps an accessible name (not spinner-only)

Visual

  • Coming soon badges readable in light + dark
  • Coming soon rows not overly faded
  • Disabled vs enabled actions clearly distinct

States to cover

  1. Chroma Local active (default)
  2. Chroma Cloud empty form (actions disabled)
  3. OpenSearch empty form (toggles on; actions disabled)
  4. OpenSearch toggles off
  5. OpenSearch configured (password ••••••••)
  6. Password edit/unmasked
  7. Coming soon panel (e.g. Astra)
  8. Save success toast
  9. Save error toast (if reproducible)
  10. Test connection success + failure

Pass / fail

Pass: no critical axe issues; full keyboard path works; loading buttons + toasts announced; coming soon contrast OK in both themes.
Fail: invisible/trapped focus; unnamed loading button; unannounced toasts; unreadable coming soon UI.

Summary by CodeRabbit

  • Accessibility

    • Alerts now provide a translated “Notifications” region for improved screen reader navigation.
    • Loading buttons announce their busy state while preserving accessible labels.
  • UI Improvements

    • “Coming soon” database providers are no longer visually muted and use updated badge styling.
  • Tests

    • Expanded accessibility coverage for alerts, buttons, and database provider settings.
    • Added coverage for provider configuration, loading states, connection checks, and success or error notifications.

…Area and Button components

- Added `useTranslation` for internationalization in `AlertDisplayArea`, providing an aria-label for better accessibility.
- Updated `Button` component to include `aria-busy` attribute during loading and ensured the accessible name is preserved with a visually hidden label.
- Enhanced accessibility tests for both components to verify the presence of roles and attributes.
@deon-sanchez deon-sanchez self-assigned this Jul 9, 2026
@coderabbitai

coderabbitai Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Important

Review skipped

Auto incremental reviews are disabled on this repository.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: aca3ec28-148b-4e0e-8114-85c09b3469cf

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Walkthrough

Adds explicit accessibility semantics for alert regions and loading buttons, updates DB provider “coming soon” styling, and introduces end-to-end accessibility coverage for provider configuration, saving, and connection-testing states.

Changes

Accessibility semantics and DB provider coverage

Layer / File(s) Summary
Alert region semantics
src/frontend/src/alerts/displayArea/...
Adds a translated Notifications region around alerts and verifies live-region containment in accessibility tests.
Loading button accessibility
src/frontend/src/components/ui/...
Adds aria-busy and screen-reader-only loading text while preserving the button’s existing loading presentation.
DB provider accessibility coverage
src/frontend/src/pages/SettingsPage/pages/DBProvidersPage/index.tsx, src/frontend/tests/a11y/db-providers.a11y.spec.ts
Updates coming-soon provider styling and adds accessibility tests covering provider states, save flows, toasts, and connection testing.

Estimated code review effort: 3 (Moderate) | ~25 minutes

Possibly related PRs

Suggested reviewers: viktoravelino, olayinkaadelakun, keval718

🚥 Pre-merge checks | ✅ 8 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (8 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Test Coverage For New Implementations ✅ Passed The PR adds targeted tests for the updated Button and AlertDisplayArea code plus a broad DB Providers Playwright a11y spec with real assertions, matching repo conventions.
Test Quality And Coverage ✅ Passed The new RTL/jest-axe and Playwright tests cover the changed a11y behaviors, loading states, and DB-provider success/error flows with proper async patterns.
Test File Naming And Structure ✅ Passed PASS: Jest config accepts .test/.spec files; the new a11y tests live in expected dirs, use descriptive names, and cover positive/negative paths with shared setup helpers.
Excessive Mock Usage Warning ✅ Passed Mocks are minimal and targeted: 3 jest.mock shims for external UI deps and API route stubs for backend calls; no sign of over-mocking core logic.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title matches the main theme of the changes: accessibility improvements, especially around the settings DB providers area.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch db-provider-a11y

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions github-actions Bot added the bug Something isn't working label Jul 9, 2026
@github-actions

github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

Migration Validation Passed

All migrations follow the Expand-Contract pattern correctly.

@deon-sanchez
deon-sanchez changed the base branch from main to release-1.11.0 July 9, 2026 20:31
@github-actions github-actions Bot added bug Something isn't working and removed bug Something isn't working labels Jul 9, 2026
@github-actions

github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

Build successful! ✅
Deploying docs draft.
Deploy successful! View draft

@deon-sanchez
deon-sanchez marked this pull request as ready for review July 10, 2026 23:06
@github-actions github-actions Bot added bug Something isn't working and removed bug Something isn't working labels Jul 10, 2026
@github-actions

Copy link
Copy Markdown
Contributor

✅ Test Coverage Advisor

No source changes detected without accompanying tests. Thanks for keeping coverage up! 🎉

Advisory check only — never blocks merge.

@github-actions github-actions Bot added bug Something isn't working and removed bug Something isn't working labels Jul 10, 2026

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@src/frontend/tests/a11y/db-providers.a11y.spec.ts`:
- Around line 352-360: Update the loading-state comment to acknowledge that the
sr-only label preserves the button’s accessible name during loading, and change
the locator associated with useChromaButton to page.getByRole("button", { name:
"Use Chroma" }) so the test verifies that fix.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 3227ef5a-168f-46b2-a5ab-790274029194

📥 Commits

Reviewing files that changed from the base of the PR and between 7f28257 and 5232c27.

📒 Files selected for processing (6)
  • src/frontend/src/alerts/displayArea/__tests__/displayArea.a11y.test.tsx
  • src/frontend/src/alerts/displayArea/index.tsx
  • src/frontend/src/components/ui/__tests__/button.a11y.test.tsx
  • src/frontend/src/components/ui/button.tsx
  • src/frontend/src/pages/SettingsPage/pages/DBProvidersPage/index.tsx
  • src/frontend/tests/a11y/db-providers.a11y.spec.ts

Comment on lines +352 to +360
// Locate by text content rather than accessible role name: the
// Button component visually hides its label (CSS `invisible`) while
// `loading` is true, which strips the accessible name from the a11y
// tree — a real gap this scan is designed to surface — so a
// name-based role query would stop matching mid-flight.
await page.getByTestId("db-provider-item-chroma").click();
const useChromaButton = page
.getByRole("button")
.filter({ hasText: "Use Chroma" });

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win

Update loading-state comment and query to reflect the sr-only accessible-name fix.

The comment states the Button's loading state "strips the accessible name from the a11y tree" and that "a name-based role query would stop matching mid-flight." However, this PR's button.tsx changes add an sr-only span that preserves the accessible name during loading. The comment is now inconsistent with the fix it ships alongside.

Consider using getByRole("button", { name: "Use Chroma" }) instead of getByRole("button").filter({ hasText: "Use Chroma" }) to actually verify the sr-only fix works. If the text-based query is intentionally kept for robustness, update the comment to reflect the post-fix rationale.

💚 Proposed fix
       // Locate by text content rather than accessible role name: the
       // Button component visually hides its label (CSS `invisible`) while
-      // `loading` is true, which strips the accessible name from the a11y
-      // tree — a real gap this scan is designed to surface — so a
-      // name-based role query would stop matching mid-flight.
+      // `loading` is true. The sr-only span added in button.tsx preserves
+      // the accessible name, so a name-based role query remains stable
+      // throughout the loading state.
       await page.getByTestId("db-provider-item-chroma").click();
       const useChromaButton = page
-        .getByRole("button")
-        .filter({ hasText: "Use Chroma" });
+        .getByRole("button", { name: "Use Chroma" });
       await expect(useChromaButton).toBeEnabled();
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
// Locate by text content rather than accessible role name: the
// Button component visually hides its label (CSS `invisible`) while
// `loading` is true, which strips the accessible name from the a11y
// tree — a real gap this scan is designed to surface — so a
// name-based role query would stop matching mid-flight.
await page.getByTestId("db-provider-item-chroma").click();
const useChromaButton = page
.getByRole("button")
.filter({ hasText: "Use Chroma" });
// Locate by text content rather than accessible role name: the
// Button component visually hides its label (CSS `invisible`) while
// `loading` is true. The sr-only span added in button.tsx preserves
// the accessible name, so a name-based role query remains stable
// throughout the loading state.
await page.getByTestId("db-provider-item-chroma").click();
const useChromaButton = page
.getByRole("button", { name: "Use Chroma" });
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@src/frontend/tests/a11y/db-providers.a11y.spec.ts` around lines 352 - 360,
Update the loading-state comment to acknowledge that the sr-only label preserves
the button’s accessible name during loading, and change the locator associated
with useChromaButton to page.getByRole("button", { name: "Use Chroma" }) so the
test verifies that fix.

@github-actions github-actions Bot added bug Something isn't working and removed bug Something isn't working labels Jul 13, 2026
@github-actions

github-actions Bot commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

Frontend Unit Test Coverage Report

Coverage Summary

Lines Statements Branches Functions
Coverage: 46%
46.98% (67176/142981) 70.05% (9441/13476) 45.47% (1546/3400)

Unit Test Results

Tests Skipped Failures Errors Time
5356 0 💤 0 ❌ 0 🔥 20m 37s ⏱️

@codecov

codecov Bot commented Jul 13, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 91.48936% with 12 lines in your changes missing coverage. Please review.
✅ Project coverage is 61.42%. Comparing base (f8c5f9c) to head (e6a6c42).
⚠️ Report is 1 commits behind head on release-1.12.0.

Files with missing lines Patch % Lines
src/frontend/src/alerts/displayArea/index.tsx 28.57% 5 Missing ⚠️
src/frontend/src/components/ui/button.tsx 95.14% 5 Missing ⚠️
...pages/SettingsPage/pages/DBProvidersPage/index.tsx 33.33% 2 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@                Coverage Diff                 @@
##           release-1.12.0   #13999      +/-   ##
==================================================
+ Coverage           61.30%   61.42%   +0.12%     
==================================================
  Files                2342     2339       -3     
  Lines              237114   237131      +17     
  Branches            33340    35400    +2060     
==================================================
+ Hits               145354   145657     +303     
+ Misses              89963    89677     -286     
  Partials             1797     1797              
Flag Coverage Δ
backend 69.04% <ø> (-0.01%) ⬇️
lfx 60.21% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
...rontend/src/CustomNodes/helpers/mutate-template.ts 96.72% <100.00%> (+50.11%) ⬆️
...FlowPage/components/nodeToolbarComponent/index.tsx 84.48% <100.00%> (+9.69%) ⬆️
...pages/SettingsPage/pages/DBProvidersPage/index.tsx 40.06% <33.33%> (+22.68%) ⬆️
src/frontend/src/alerts/displayArea/index.tsx 35.86% <28.57%> (-1.34%) ⬇️
src/frontend/src/components/ui/button.tsx 97.89% <95.14%> (-2.11%) ⬇️

... and 79 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@github-actions github-actions Bot added bug Something isn't working and removed bug Something isn't working labels Jul 13, 2026
@github-actions github-actions Bot added bug Something isn't working and removed bug Something isn't working labels Jul 13, 2026
@github-actions github-actions Bot removed the bug Something isn't working label Jul 13, 2026
@github-actions github-actions Bot added the bug Something isn't working label Jul 21, 2026
@deon-sanchez
deon-sanchez added this pull request to the merge queue Jul 21, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to a conflict with the base branch Jul 21, 2026
@github-actions github-actions Bot added bug Something isn't working and removed bug Something isn't working labels Jul 21, 2026
@deon-sanchez
deon-sanchez enabled auto-merge July 21, 2026 22:46
@github-actions github-actions Bot added bug Something isn't working and removed bug Something isn't working labels Jul 21, 2026
@github-actions github-actions Bot added bug Something isn't working and removed bug Something isn't working labels Jul 21, 2026
@github-actions github-actions Bot added bug Something isn't working and removed bug Something isn't working labels Jul 22, 2026
@github-actions github-actions Bot added bug Something isn't working and removed bug Something isn't working labels Jul 22, 2026
@github-actions github-actions Bot added bug Something isn't working and removed bug Something isn't working labels Jul 22, 2026
@deon-sanchez
deon-sanchez added this pull request to the merge queue Jul 22, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Jul 22, 2026
@deon-sanchez
deon-sanchez added this pull request to the merge queue Jul 22, 2026
@deon-sanchez
deon-sanchez removed this pull request from the merge queue due to a manual request Jul 22, 2026
@deon-sanchez
deon-sanchez added this pull request to the merge queue Jul 22, 2026
Merged via the queue into release-1.12.0 with commit 597d05f Jul 22, 2026
271 of 273 checks passed
@deon-sanchez
deon-sanchez deleted the db-provider-a11y branch July 22, 2026 21:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working lgtm This PR has been approved by a maintainer

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants