Skip to content

fix: repair cross-package bugs causing test and type failures#58

Open
stooit wants to merge 1 commit into
mainfrom
quantcode/e2e-tier3-2435-1782577900
Open

fix: repair cross-package bugs causing test and type failures#58
stooit wants to merge 1 commit into
mainfrom
quantcode/e2e-tier3-2435-1782577900

Conversation

@stooit

@stooit stooit commented Jun 27, 2026

Copy link
Copy Markdown
Contributor

Summary

Fixes all 4 cross-package bugs in the monorepo. bun run test now reports 13 pass / 0 fail, and there are no TypeScript errors in source code.

Changes

File Bug Fix
apps/web/src/lib/api.ts Hook renamed useThrottleuseDebounce in @e2e/utils, old name still imported, breaking the useSearchDebounce re-export Import/re-export useDebounce
packages/utils/src/format/date.ts Explicit numeric options overrode locale ordering, producing 01/03/2024 instead of day-first 1/03/2024 Use { dateStyle: "short" } so en-AU controls ordering
packages/ui/src/components/Button/Button.tsx aria-label destructured but never applied to <button> Forward aria-label to the DOM, with fallback for icon-only buttons
packages/ui/src/components/DataTable/DataTable.tsx Stale-closure: handleSort read render-time sortDir, caught by controlled re-render test Use functional updater setSortDir(prev => ...)

Verification

  • bun run test → 13 pass, 0 fail
  • tsc --noEmit → no source errors (remaining bun:test module-resolution errors are confined to test files, pre-existing; test files were not modified per task constraints)

Assumptions

  • Did not modify test files or add dependencies (per constraints).
  • dateStyle: "short" matches the existing formatDateTime convention in the same file and satisfies day-first test assertions.
  • Icon-only aria-label fallback is a minimal safety net; descriptive labels remain the caller's responsibility.

🤖 Generated with autonomous agent

- api.ts: use renamed useDebounce hook for useSearchDebounce re-export
- date.ts: use en-AU dateStyle 'short' for day-first formatting
- Button: forward aria-label to DOM with fallback for icon-only buttons
- DataTable: use functional state updater to fix stale-closure on sort
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.

1 participant