Make lane count optional and stop displaying it (PP-4506)#283
Conversation
|
Claude finished @dbernstein's task in 1m 17s —— View job Code Review — PP-4506 (lane count optional)
SummaryClean, well-scoped change. Making |
ea52344 to
f5b64c9
Compare
tdilauro
left a comment
There was a problem hiding this comment.
Looks good! 🔥
One comment below for adding a TODO for future clean up.
| // Deprecated: the backend no longer returns a lane count (lane sizes were | ||
| // removed). Kept optional for backward compatibility with older servers; the | ||
| // UI no longer displays it. | ||
| count?: number; |
There was a problem hiding this comment.
Minor: Add a TODO: about when / under what circumstances this optional and the deprecation comment can be removed.
There was a problem hiding this comment.
Done in 700b8af — added a TODO noting that count and the deprecation comment can be removed once the backend changes in ThePalaceProject/circulation#3424 have been released to production.
The Palace Manager backend no longer returns a lane `count` field — lane size maintenance was removed there. Mark `LaneData.count` optional (for backward compatibility with older servers) and stop rendering the "(count)" suffix next to the lane name in the Lane component.
The "(count)" suffix is no longer rendered (lane count was removed), so the "drags a top-level lane" test no longer asserts it — it still verifies the post-drag lane order via the lane names.
f5b64c9 to
c76e069
Compare
Addresses review feedback: note that LaneData.count and its deprecation comment can be removed once ThePalaceProject/circulation#3424 has been released to production. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Description
The Palace Manager backend is removing lane-size maintenance (see ThePalaceProject/circulation#3424), so the admin
GET .../lanesresponse no longer includes a per-lanecount.interfaces.ts: makeLaneData.countoptional (count?: number) for backward compatibility with older servers.Lane.tsx: stop rendering the" (count)"suffix next to the lane name.countwas display-only — no logic depended on it — so this degrades gracefully and is safe to ship independently of the backend change.Motivation and Context
JIRA: PP-4506
Companion to ThePalaceProject/circulation#3424, which removes the lane
size/countfrom the backend.How Has This Been Tested?
tsctype-check passes.tests/jest/components/Lane.test.tsxpasses (2/2); Prettier clean.