Skip to content

fix(apollo-react): keep Toolbox rows interactive while a search is pending - #1404

Open
snuziale wants to merge 1 commit into
mainfrom
fix/toolbox-search-pending-rows
Open

snuziale wants to merge 1 commit into
mainfrom
fix/toolbox-search-pending-rows

Conversation

@snuziale

Copy link
Copy Markdown
Collaborator

Problem

  • Toolbox treated an in-flight onSearch promise as loading, and ListView disabled every row
  • Rows dropped to 50% opacity and came back on every pause in typing for any async onSearch
  • Visible on every search in Flow's add-node panel (400 ms debounce + network search)

Fix

  • Toolbox: isLoading={awaitingChildren || loading}; searchLoading goes to a new ListView searchPending prop
  • ListView.searchPending: sets aria-busy on the listbox and keeps the skeleton-on-empty path; never disables rows
  • SearchBox: swaps the search icon for a same-sized Spinner while pending, so nothing shifts
  • Stale answers were already dropped by the request-id guard, so the previous list stays clickable (stale-while-revalidate)
  • loading prop and lazy category resolution (awaitingChildren) still disable rows exactly as before
  • New toolbox.search.pending string in en.json only; other locales to follow

Tests

  • 13 new tests across Toolbox, ListView, SearchBox: rows stay enabled and have no loading class during a pending search, aria-busy and spinner toggle, click during pending selects, stale answer ignored, skeletons replace a stale empty state, awaitingChildren still disables
  • Existing loading / isLoading tests unchanged
  • Full canvas suite: 3604 passed

Manual check

  • Storybook: Components / Controls / Toolbox / With Slow Search
  • Type, pause, type again: rows keep full opacity, spinner shows in the search field, rows are clickable while pending

🤖 Generated with Claude Code

…nding

Toolbox treated an in-flight onSearch promise as a loading state and
ListView turned that into disabled on every row, so any consumer with an
async search saw the list dim and brighten on each pause in typing.

- Toolbox passes isLoading={awaitingChildren || loading} and routes
  searchLoading to a new ListView searchPending prop
- ListView searchPending only sets aria-busy on the listbox and keeps the
  skeleton-on-empty path; rows are never disabled by it
- SearchBox swaps the search icon for a same-sized Spinner while pending
- WithSlowSearch story with a 500ms onSearch for manual verification

The request-id guard in handleSearch already discards stale answers, so
disabling rows protected nothing. The panel-level loading prop and lazy
category resolution still disable rows as before.

Co-Authored-By: Claude Mythos 5.1 <noreply@anthropic.com>
Copilot AI balanced review requested due to automatic review settings October 17, 2026 21:01

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@github-actions

Copy link
Copy Markdown
Contributor

Dependency License Review

  • ✅ 1947 package(s) scanned
  • ✅ No license issues found
  • ⚠️ 2 package(s) excluded (see details below)
License distribution
License Packages
MIT 1713
ISC 91
Apache-2.0 56
BSD-3-Clause 28
BSD-2-Clause 23
BlueOak-1.0.0 8
MPL-2.0 4
MIT-0 3
CC0-1.0 3
MIT OR Apache-2.0 2
(MIT OR Apache-2.0) 2
Unlicense 2
LGPL-3.0-or-later 1
Python-2.0 1
CC-BY-4.0 1
(MPL-2.0 OR Apache-2.0) 1
Unknown 1
Artistic-2.0 1
(WTFPL OR MIT) 1
(BSD-2-Clause OR MIT OR Apache-2.0) 1
CC-BY-3.0 1
0BSD 1
(MIT OR CC0-1.0) 1
MIT AND ISC 1
Excluded packages
Package Version License Reason
@img/sharp-libvips-linux-x64 1.3.4 LGPL-3.0-or-later LGPL pre-built binary, not linked
khroma 2.1.0 Unknown MIT per GitHub repo, missing license field in package.json

@github-actions

Copy link
Copy Markdown
Contributor

📊 Coverage + size by package

Per-package coverage and bundle size on this PR. New-line coverage = of the source lines this PR adds or changes, the % hit by tests.

Package Coverage New-line coverage Packed (gzip) Unpacked vs main
@uipath/apollo-core — — 42.02 MB 50.17 MB ±0
@uipath/apollo-react 51.3% 33.3% (3/9) 7.99 MB 31.45 MB +267 B
@uipath/apollo-ui-icons — — 2.86 MB 6.97 MB ±0
@uipath/apollo-vertex — — — — —
@uipath/apollo-wind — — 785.2 KB 4.55 MB +5 B
@uipath/ap-chat 85.8% — 40.37 MB 45.58 MB +17 B

"Coverage" is each package's own coverage.include scope (e.g. apollo-core instruments only scripts/). "Packed"/"Unpacked" come from npm pack --dry-run and only cover built packages — "—" means not measured this run (package not affected / not built). "vs main" is the packed (gzipped) delta against the last successful main build (the package-sizes artifact from the Release workflow); "—" there means no main baseline was available this run. The baseline is main's latest build, not this PR's exact merge-base, so it includes any drift since the branch diverged. Packages with no vitest config are omitted.

@github-actions

Copy link
Copy Markdown
Contributor

Storybook visual diff

⚠️ Visual changes detected: 45 changed, 2 added (of 402 compared, 355 unchanged). View report

Baseline is the deployed main Storybook, so changes merged to main after this branch was last updated can also appear here. Logs

Updated (PT): Oct 17, 2026, 02:26:05 PM

This branch had an error being deployed

1 failed and 3 active deployments
preview/apollo-docs — 9a337e1c Deployed Oct 17, 2026 by github-actions[bot]
preview/apollo-landing — 9a337e1c Deployed Oct 17, 2026 by github-actions[bot]
preview/apollo-vertex — 9a337e1c Deployed Oct 17, 2026 by github-actions[bot]
preview/apollo-design — 9a337e1c Deployed Oct 17, 2026 by github-actions[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pkg:apollo-react size:L 100-499 changed lines.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants