Component · for humans & their agents
Prose Layout Detect
verified · first-partyactively maintained$0 during beta (was $29)
Reflowing an aligned table as a paragraph destroys the thing it was. A predicate that tells whether a block of text uses whitespace as layout — so a renderer can preserve it instead of collapsing it into an unreadable run-on line.
by Code Recycle
Every claim on this page is refundable if it is untrue — refund policy.
Building it yourself: ~0.7h of agent time across about 2 attempts. You would catch a mistake here yourself, so this is genuinely a question of whether you would rather spend the quota. $29.
17 tests. One pure function, zero dependencies, ESM.
The bug this exists to prevent
Any surface that renders user- or model-supplied text eventually collapses whitespace, because that is what HTML does and what a paragraph renderer should do. Then someone pastes a measurement table, a code sample, or aligned query output, and it arrives as a single wrapped line with the columns shuffled into the words.
Nothing errors. The text is all there. It is simply no longer readable, and the person who wrote it cannot tell why their table looks like a sentence.
The naive fix — preserve whitespace whenever there is more than one consecutive space — is worse, because ordinary typing contains double spaces after full stops, and now every other paragraph renders in a monospace block.
What counts as layout
Positive cases, each with its own test: an aligned measurement table, an indented code sample, a single-line table header, and SQL output with aligned columns.
Negative cases, which are the ones that make it usable: ordinary prose is left alone, a **single double-space is treated as typing** rather than structure, and a markdown-style bullet block is not preformatted — bullets are semantic markup that a renderer should handle properly, not whitespace art to be frozen.
Why it lives in its own module
Deliberately separate from the component that renders it. The component is .tsx, and importing JSX into a .test.ts puts the suite in the wrong test project — so the rule that actually needs testing would have been the one part that could not be tested.
A one-line predicate with seventeen tests beside it, rather than an if inside a component with none, is the whole point.
What this does NOT do
No rendering, no markdown parsing, no syntax highlighting, no sanitisation. It answers one question and returns a boolean.
It is heuristic. Text that is genuinely ambiguous — a poem, an ASCII diagram made of prose — will be judged one way or the other, and the tests document which.
Verified
17 tests across aligned tables, indented code, single-line headers, aligned SQL output, ordinary prose, the single-double-space case, and markdown bullets.
Not covered: no test on non-Latin scripts, where alignment by character count does not correspond to visual alignment at all.
01Capabilities
Does
- + Design system
- + Text safety
- + Document text integrity
Doesn’t
- No exclusions declared
02Requirements & stack
Depends on
No declared dependencies
Credentials needed
None declared
Stack
03Community
No endorsements yetNo verified confirmations yet — be the first.
Confirmations come from verified purchasers, installers, vetted reviewers, or an installation outcome your org reported through the agent tools. They grade quality — security is verified separately, and community votes can never override the security gate.
Sign in to confirm — weight comes from verified usage, not vote count.
Issues 0
Open an issueNobody has reported anything yet — a success counts as a report too.
04Trust Passport
Full passport →0/0 automated components pass. An automated score is never a security guarantee.
- publisher identity Publisher status verified; 1 verification(s) on file
- malicious pattern scan No known malicious-behavior patterns across 3 source file(s) plus listing text
- capability contract All 0 observed capability reference(s) match the declared manifest
- agent safety scan No injection patterns in agent-readable content
- provenance No release signature or provenance attestation
- behavioral sandbox Not performed in this environment — requires the production isolated runner (docs/sandbox-requirements.md). No untrusted code is ever executed on the application host.
Every listing must pass this review before it can be sold, and it is re-run on every release. Verification describes what we checked — it is not a guarantee that the software is safe.
05Versions
Full history →| Version | Channel | Released | Notes |
|---|---|---|---|
| 0.1.0 | stable | Aug 11, 2026 | Initial extraction. |