Skip to content

Fix CI and the keyboard navigation regression from range selection. - #10

Merged
dpage merged 1 commit into
mainfrom
fix/ci
Oct 15, 2026
Merged

dpage merged 1 commit into
mainfrom
fix/ci

Conversation

@dpage

@dpage dpage commented Oct 15, 2026

Copy link
Copy Markdown

CI has been red on main since the range selection change (8ddaa7b). This gets every step passing again, and fixes a real keyboard regression along the way.

Behaviour fix

  • handleKeyDown sent every shift + key press to the range selection branch, whether or not enableRangeSelection was set, so shift + space row selection and shift + tab navigation stopped working everywhere. Now only shift + arrow keys extend the range, and only when range selection is on; everything else goes through the normal navigation and input path. The range mouse handlers are also only attached when range selection is enabled.
  • Group rows spread rangeSelectionMode and the capture handlers onto their div (the TS2322 typecheck error), and TreeDataGrid leaked selectedCellsRange into group rows. Both are fixed.
  • New test/browser/rangeSelection.test.tsx covers shift + arrow with range selection both on and off. The existing keyboard navigation and shift + space tests pass unchanged.

Toolchain

With no lockfile, npm i had drifted onto versions that no longer work: rolldown 1.x dropped cssEntryFileNames and CSS bundling, newer TanStack router rejects the route files, and newer rolldown-vite no longer pulls in the esbuild that cssMinify: 'esbuild' needs. I've pinned rolldown (1.0.0-beta.35) and rolldown-plugin-dts (0.16.12) exactly, and committed a package-lock.json resolved with npm install --before=2025-10-24. That locks CI to the toolchain the range selection change was written against, and stops it breaking again the next time something upstream moves. /package-lock.json comes out of .gitignore as a result.

lib/ is rebuilt from the pinned toolchain, and a clean rebuild reproduces it byte for byte. Apart from the source changes, the only differences from the previous lib/ are five /* @__PURE__ */ comments in index.js and some deduplicated react imports in index.d.ts. No published rolldown version reproduces the previous output exactly, and the upstream beta.58 tarball shows the same pattern.

Smaller fixes

  • The ESLint warnings are gone: the object-shorthand warnings in DataGrid.tsx and the any usage in the range selection demo.
  • /lib is added to .prettierignore. It is generated output, and it used to be skipped only because it was gitignored.
Known Firefox issue

resizable.test.tsx > should remeasure flex columns when resizing a column fails locally in Firefox on sub-pixel column widths (101px 908.5px against the hard-coded expected values). It fails the same way on upstream 12fb93e, so it is environmental rather than caused by this change. Everything else passes in both browsers.

The range selection change diverted every shift + key press away from
normal handling, which broke shift + space row selection and shift + tab
navigation even when enableRangeSelection was off. Only shift + arrow
keys now extend the range, and only when range selection is enabled; the
range mouse handlers are likewise only attached when it is enabled.

Group rows no longer spread the range selection props onto their div
(the TS2322 typecheck failure), and TreeDataGrid no longer leaks
selectedCellsRange into group rows.

The build toolchain floated to versions that no longer work: rolldown
1.x dropped cssEntryFileNames and CSS bundling, newer TanStack router
rejects the route files, and newer rolldown-vite no longer pulls in
esbuild for cssMinify. Pin rolldown and rolldown-plugin-dts exactly and
commit a package-lock.json resolved as of 24 October 2025, so CI installs the
toolchain the range selection change was written against.

Also fix the ESLint warnings, keep Prettier off the generated lib/, add
browser tests for the range selection keyboard behaviour and rebuild lib/.
@dpage
dpage merged commit 29cd589 into main Oct 15, 2026
1 check passed
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