Catalog: holder clearance calculator, a draggable column, and three matching-rule fixes - #7
Merged
Merged
Conversation
Takes the 1.0.0 migration, the group reach curve and #6's material-wall fix onto the clearance work. Three conflicts, all in the drawing seam: - catalog-drawing.tsx: keeps this branch's extraction of the measurement into shared/assembly-gaps, and takes main's reservation semantics with it — MATERIAL_ROOM rather than the retired materialRoom prop. main's DEV ClearanceProbe is kept; its `outline !== null` guard goes, because gapsFor already returns null where the package draws no outline. - tool-details.tsx: main's ratio rule for the sheet box, which its own e2e test pins — the sheet is as wide as the room or three quarters of its height, whichever is less. This branch's 22 rem floor under an 18 rem cap was the flat cap that rule replaced. - catalog-drawing.test.tsx: keeps main's new zoom sensor and this branch's comment on the test below it. #6 fixed the cutting radius in catalog-drawing.tsx, which this branch had already moved to shared/assembly-gaps, so the merge resolved it in a file nothing reads any more and the defect would have survived it. cuttingRadiusOf now returns `number | null` under main's guard, where the three clearance boxes read it as well as the drawing — a fix applied to the drawing alone would leave a box reading a gap taken from r = 0 while the picture beside it had stopped drawing one.
The guard #6 put on the drawing, as a sensor on the module that now owns it. `!== undefined` was true of both shapes a silent vendor leaves — a `DC` of `null` and a `DC` of `0` — so the wall was measured from `r = 0` and drawn through the tool. Reverting cuttingRadiusOf to `(DC ?? 0) / 2` fails both cases; nothing else in the suite notices.
BradEstey
requested changes
Sep 11, 2026
BradEstey
left a comment
Member
There was a problem hiding this comment.
Can you rename column-width to panel-width so it doesn't conflict with the table column naming? Resizable sections are called panels everywhere else.
Brad, PR #7: the resizable section over the part is a panel everywhere else in this application, and "column" is what a table column is called. column-width.ts becomes panel-width.ts, column-resizer.tsx becomes panel-resizer.tsx, and their exports, the route's locals and the docs follow. The stored key is tool-catalog.panel-width, so a width dragged before this gets the defaults back once.
The conflict resolutions are in the merge under this. What is here is the three tests that had to move with them, changed rather than dropped: - column-filter.test.tsx and filter-panel.test.tsx pinned `fixed z-50`, which was this branch's own positioning for the menus. Brad's branch moved both to the kit's `Menu.Popover`, so the placing is the kit's now. They pin the bound the application still owns — the menu scrolls inside the room the screen left — and the anti-clip invariant they exist for is unchanged and still passing. jsdom does no layout, so `toBeVisible` cannot answer for the kit's popover; the browser is asked instead, in `tests/on-the-part.spec.ts`. - Brad's `the columns divide the panel` sampled `boundingBox()` straight after a viewport change. This branch's panel is resizable, so the table is laid out twice and the handle can be asked in the gap between — the resizers are all there, the first just has no box yet. It waits for the handle now; nothing it asserts has changed. Table resizing follows brad/table exactly: use-fitted-columns.ts, column-width.ts, column-layout.ts, component-table.tsx and part-tool-table.tsx are byte-identical to his. `panel-width.ts` is this branch's and sizes the details panel, which is why the rename off `column-width` in 9af3738 left his name free.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Release candidate for catalog.toolpath.com. Seven commits on top of
main,all in
apps/catalogand its docs — no change topackages/, toapps/dfm, orto any server or API-key path.
The holder clearance calculator
A shop can now state the three numbers a stack has to clear, in three boxes
under the drawing, and see the verdict against the assembly it is looking at.
app/shared/clearance-entry.ts— which of the three numbers a shop stated,and what each box takes besides a number.
app/components/clearance-entry.tsx— the three boxes themselves.app/shared/assembly-gaps.ts— the room a stack leaves, measured once forevery reader instead of separately inside the drawing. This is an extraction
out of
catalog-drawing.tsx, which drops from its own measurement to wiringthe package up.
cuttingRadiusOfnow returnsnumber | null.!== undefinedwas true of bothshapes a silent vendor leaves — a
DCofnulland aDCof0— so a wallwas measured from
r = 0and drawn through the tool. The guard #6 put on thedrawing moved with the measurement into
assembly-gaps, andshared/tool-marks.test.tspins both cases: reverting to(DC ?? 0) / 2failsthem, and nothing else in the suite notices.
The column over the part is draggable
One column carries all four, so one drag widens all of them. Double-click
forgets the stated width; the arrow keys move it by 16px, because a drag target
only a mouse can reach is one half the room cannot use. Held between 256px and
seven tenths of the viewer.
app/shared/column-width.tsis every number,app/components/column-resizer.tsxthe handle, and
tests/on-the-part.spec.ts§ widening the column over the partthe drag — including that the edge takes the press so it never orbits the part
underneath, and that a dozen pixels off it the canvas still does.
Three matching rules corrected
group capped at ⌀0.286 in was listing ⌀0.438 in to ⌀0.750 in cutters: they
were removed for reach, so the diameter question was never put to them —
judging stops at the first feature that rules a tool out — and they came back
as "the closest" under a filter no part of them was near.
nearEnoughinapp/shared/tool-fit.tsis the rule, applied a tool at a time in the workerbefore the fifty nearest are taken.
should. A ⌀0.125 in mill under a ⌀0.136 inhole is listed with a caution saying the room it leaves (
0.006 in a side to helix in) rather than refused in red — it can still plunge or bore the holeout. The refusal is the bore itself, which row 2 already holds. One line of
rules.csv.fact about the sweep; what a row says is a fact about the tool, so the page
narrows the swept pool on the two term axes itself against the same
query.termsthe drill list reads. A vendor holding no tap for this thread isa nought behind the
…row rather than a question the header refuses to ask.tests/threaded-hole.spec.ts§ narrows the taps by vendor / § by familyare the sensors, over the sample catalog's one tap vendor and the one that
holds none.
Typography and UI
app/shared/type.tsgrows from the heading face and the small-capitals label toa dialog's whole voice, with
app/type-scale.test.tsas its sensor. Filterpanel, column filter, assembly tree panel, selection panel, tool details and the
group editor all take it, and
app/styles.csscarries the roles.Verification
pnpm check— pass (check-style, lint, build, check-types, test).pnpm format:check— pass.pnpm test:e2e:catalog— pass, 132 tests in 1.5m.Note on the deploy
Nothing in this repository names
catalog.toolpath.com—.github/workflows/holds
ci.ymlonly. Merging this PR does not itself publish anything; whateverdrives that host is configured outside the repo.