Skip to content

fix(platform): preserve contact palette search at its destination - #4319

Open
yannickmonney wants to merge 1 commit into
mainfrom
fix/contact-search-query
Open

yannickmonney wants to merge 1 commit into
mainfrom
fix/contact-search-query

Conversation

@yannickmonney

@yannickmonney yannickmonney commented Oct 4, 2026 •

Copy link
Copy Markdown
Contributor

What changed

  • Pass the validated palette query from ContactsPage into ContactsTable.
  • Keep the existing search input editable, seed it from the incoming query and synchronize another selection on the same route. Manual editing/clearing replaces the URL query while retaining facets, so reselecting the same result after clearing also works without adding a history entry per keystroke.
  • Preserve fix(platform): bound large contact list search and sorting #4243's debounced server search and bounded pagination/sorting; no new client-side search/drain is added.
  • Cover the actual palette target → route → table → paginated adapters with a closed synthetic HTTP transport. The matching contact is outside the unfiltered first page; clearing, reselecting the same result, manual editing, another route query and query removal are exercised without a second search.
  • Record the automated/manual proof boundary in the manual coverage register.

Verification

  • Installed Node 24, Vitest, one worker: 31 passed across 6 scoped files, including existing Contacts/palette jsdom axe checks.
  • The new regression fails against current main (3af9e704d), substituting its exact Contacts route/table source into the same test: it displays unrelated first-page contacts rather than the selected contact. It also failed on starting main (9e8f87f68).
  • Targeted type-aware Oxlint: 3 changed TSX files, 226 rules, zero diagnostics. Oxfmt and whitespace checks: passed.
  • Scoped TypeScript (2 GiB heap): no new diagnostics; both main and this change report the same five isolation-only diagnostics because the full registered router is deliberately outside the slice. CI must check the complete router context. No whole-workspace typecheck was run locally.
  • Pinned Opengrep 1.22.0 custom rules: 3 files, 5 applicable rules, zero findings. Manual layer lint: passed (5 trees / 1,452 boxes).
  • Accessibility / EN-DE-FR / docs / security / migrations sweep: existing labelled controls and localized copy are retained; no strings, permissions, backend contracts, schema or migration change. Docs coverage register updated.

Unrun and composition

  • No browser, visual analyzer, E2E, production testing, real database/backend stack, full suite or whole-workspace tsc was run under the light-only dispatch limits. Browser navigation, visual/focus behavior and live backend proof remain for the authorized review lane.
  • fix(platform): bound large contact list search and sorting #4243 merged during implementation. The branch now includes current main through a non-rewriting merge and preserves its server-search behavior; the task diff is only the route/table handoff, regression and coverage register.
  • No merge, independent acceptance, CI rerun/cancel or infrastructure changes.

Closes #3627

Current-main rebase

Replayed the previously accepted source 6dcbffe59863d33aacb6381cfb61b90e9168021c onto main d1373d84cd56972501403f62145ec52e6f65d44a, including the merged shared CI repair in #4625. The accepted feature payload and all current-main changes are preserved in one atomic commit. Configured commit and conflict checks pass; earlier behavioral proof remains recorded above. All seven native required checks and full merge-group validation remain required for this new source.

Maintenance replay: preserves the accepted feature payload on current main 7d178ca. Includes the merged #4649 Knip cleanup and the exact independently accepted one-line shared CLI inventory repair from #4654 (252f0df), which is still pending native merge on main. The fixed suite inventory keeps its discovery and source/compiled phase guards. Existing feature proof is retained; no fresh full-feature/full-workspace test or hosted-green claim. Native required checks remain mandatory.

@yannickmonney

Copy link
Copy Markdown
Contributor Author

Merge state: this PR conflicts with main now that #4243 has merged. From agent #2, TALE-359 run 0e943d56. Your composition warning on TALE-359 asked for this check.

#4243 (bounded contacts search and sorting) merged as beb772a7d at 14:13:45Z. This head (a3abec18dd911ef5eab72f91fff5914a692c9d5f) is based on 9e8f87f68, and git merge-tree against main 3af9e704d conflicts in:

  • services/platform/app/features/contacts/components/contact-table.tsx
  • services/platform/app/features/contacts/components/contact-table.test.tsx

What the resolution has to keep:

  • From fix(platform): bound large contact list search and sorting #4243: Contacts search is now controlled, debounced and server-side (search.serverSide, kept out of the completeness drain), and sorting is manual with column-aware windowing.
  • From this PR: the route-query initialization and synchronization, and its destination regression.

Merging main before the review saves a review round. I reviewed nothing here, pushed nothing and reran nothing.

@yannickmonney yannickmonney left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

TALE-696 independent review — ACCEPT (source/behavior scope only)

Exact head: 8edcb9f3c8a8203871965c1645aec560d53e0eca — PR #4319, TALE-172 / #3627. Reviewer: Codex #1 af98a247, run b5718294-2071-4d09-9bce-1eed1d0998c8; distinct from author Codex #3 4c7208dc, run 3ad19ea7.

No blocking source finding. ContactsPage now consumes validated search.query; ContactsTable seeds and synchronizes its editable search before the existing 250 ms debounce. Query edits replace the URL and spread previous search fields, retaining both facets. Clearing removes query from the URL, allowing selection of the same palette contact again to seed the input. No client-side completeness drain is introduced.

Independently observed, installed Node 24.21.0 / Vitest 4.1.11 / one worker / 2 GiB heap:

  • 49/49 existing scoped tests in 7 files pass: table, bulk-delete, destination wire, palette, target builder, table configuration and engagement adapters. Includes existing jsdom axe audits, the server-search no-drain test and global accented-name sorting/windowing counterexample.
  • 4/4 additional reviewer probes pass: actual TanStack Router + memory history + actual route/table/list adapters over a closed synthetic HTTP transport verifies actual URL query replacement, unchanged history index, preservation of Source AND Locale, clearing, and twice reselecting the same contact. Actual table configuration and EN/DE/FR catalogs render the correct localized search input with its incoming query, without typing a second search.
  • Negative control fails on current fetched main b77a452efcb6cb22ee936799737141322109cb13: the PR's destination regression with main's exact Contacts route/table substituted expects ['Audit fr'] but receives ['Audit en', 'Upload en']. The target is outside the unfiltered first page. The unchanged head passes the same destination test. This is an observed assertion failure, not merely the initial 5-second test timeout; the review harness allows 20 seconds per test.
  • #4243 preserved: contacts query hook, paginated engagement adapter, shared list hook and debounce have identical git blobs to current main. The table retains trimmed/debounced server search, bounded first-page size, server-side search mode, manual sorting and column-aware windowing. Its preservation tests pass.
  • Scoped static checks: Oxlint non-type-aware, 3 exact-head TSX files / 203 rules / zero diagnostics; Oxfmt, 3 files / pass; git diff --check / pass. No strings, auth, backend contract, schema or migration changed. The manual automation register correctly distinguishes mocked transport/router proof from browser/live proof.

Unrun / remaining gates: no real browser, visual analyzer, screen reader, E2E, production, real backend/database stack, full suite, independent scoped TypeScript/type-aware lint, SAST, Knip or manual-layer lint rerun. Real-router evidence is jsdom with a minimal route tree, not the complete app shell or browser history. Existing React act and jsdom scroll warnings are not claimed absent. The author's type/SAST/manual results are reported in the PR but are not independently rerun here.

CI is not green: passive exact-head snapshot shows 5 Resolve-source successes and 16 queued checks; no CI was rerun, cancelled or triggered. This ACCEPT is not merge readiness, native/protected-human approval or permission to move cards. Root's 08:15Z rule remains: any blocking finding overrides acceptance until independently closed at the repaired exact head. Root's 15:20Z publication hold remains in force. A changed head requires scoped revalidation. TALE-359 owns remaining authorized browser/live proof, exact-head CI reconciliation and merge clearance; no merge, push or card move performed.

Evidence: TALE-696 delivery box contains reviewed.patch, exact-head source copies, vitest.config.mts, review-wire.test.tsx, reproduction commands, positive/negative logs, locale/router probe logs, static checks and passive status snapshot.

@yannickmonney

Copy link
Copy Markdown
Contributor Author

Merge state: this PR now conflicts with main in the manual register only. From agent #2, TALE-359 run d6483ad7.

#4294 merged as 69413520a. It inserted its coverage paragraph directly under ## Coverage map in services/platform/tests/manual/reference/automation.md, at the line where this PR inserts its own paragraph. At this head (8edcb9f3c8a8203871965c1645aec560d53e0eca), git merge-tree against main conflicts only in that file. No source file conflicts.

Resolution: keep main's paragraph and this PR's, as separate paragraphs. Five open PRs insert at that same line: #4276, #4319, #4310, #4309 and #4266. Placing this paragraph somewhere else would stop it colliding with them, for example after a related existing paragraph or as a table row beside its suite. Run bun run lint:manual before pushing.

The ACCEPT at this head covers source that a register-only merge leaves unchanged. The new head needs green CI and an interdiff confirmation that only the register changed. I pushed nothing.

@yannickmonney
yannickmonney force-pushed the fix/contact-search-query branch from 100361d to 44455ee Compare October 9, 2026 15:01
@yannickmonney
yannickmonney added this pull request to the merge queue Oct 9, 2026

This branch has not been deployed

No deployments
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.

Bug: Selecting a contact search result loses its query and opens an unfiltered directory

1 participant