Repository navigation
Draw a pipe with coil: true as a coil of six passes - #9
Merged
Merged
Conversation
A pipe that is really one long looped length, such as an underfloor heating loop, can set `coil: true`. Each of its runs is then drawn as six passes back and forth in the pipe's own colour and weight, with the label above the coil. On `pipe^` the turn node grows to hold the passes and its two legs enter one coil span apart, so the coil takes the place of the plain turn. On a straight run the label slot is made inline and tall enough for the coil, which is let into the level stretch through it; with no such stretch the run draws plain. The coil is only extra route points, so corners are filleted as on any route. Any `coil` value other than true or false is an error. A sheet with no coiled pipe lays out exactly as before. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Summary
A pipe can set
coil: trueto show it is one long looped length, such as an underfloor heating loop. Each of its runs draws as six passes back and forth, label above.pipes: pex_16mm_underfloor: label: 16MM PEX UNDERFLOOR HEATING LOOP size: 16mm + coil: true # anything but true or false is an errorThe coil is only extra points on the route, so
render.tsis untouched: corners are filleted, and colour and weight are the pipe's own. A run with an open end is a card and never coils.Evidence
pex_16mm_underfloor^in a real heating plan drew as a plain U-turn with its label beside the bend.After: the same plan with
coil: truedraws six orange passes east of the two PEX adapters, label above the first pass. A straight coiled run, labelled and unlabelled, was rendered and checked by eye as well.coilare byte-identical: all 14 SVGs and 10 Markdown tables of the project that uses ferrule (4 plumbing plans, 10 looms) were rendered from this branch and compared withcmpagainst the committed ones, 0 differ.npm run typecheck,npm test(85 pass, 4 new) andnpm run buildpass.Not covered by a test: the plain-line fallback on a straight run, which no small plan could be made to trigger.
Merge Danger
Door: two-way
Opt-in key; reverting removes it and nothing else.
Blast Radius: none-unless-opted-in
A plan that already carries a stray non-boolean
coilon a pipe now fails to render.🤖 Generated with Claude Code