You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(FR-2823): migrate Environment > Images table to server-side ordering
Resolves#7257(FR-2823)
The Images tab on `/environment` paginates server-side but sorted client-side
via per-column `sorter: (a, b) => ...` callbacks, which can only reorder rows on
the current page — column header clicks gave a misleading partial sort. The
backing `image_nodes` GraphQL query already exposes `$order: String`, but the
page hard-coded `order: undefined` and never plumbed the table's sort state
through.
- Add URL-persisted `order` state via `nuqs` `useQueryStates` (default
`-installed`, matching the prior `defaultSortOrder: descend` on the Status
column).
- Pass `order: queryParams.order` through to `image_nodes(...)`.
- Replace each per-column in-memory comparator with `sorter: true` so BAITable
emits sort changes via `onChangeOrder` instead of sorting locally.
- Drop the sortable affordance on `FullImagePath` (computed via
`getImageFullName`, not server-orderable).
- Wire `order` and `onChangeOrder` to BAITable; resetting to page 1 on order
change matches the listing-page convention.
- Remove the now-unused `localeCompare` import.
This follows the URL-state-driven server-order pattern already established in
`react/src/pages/ProjectPage.tsx`.
Verification:
- Relay: PASS (no schema change)
- Lint: PASS
- Format: PASS
- TypeScript: pre-existing failures only (unrelated)
0 commit comments