fix(admin): no wordmark on mail a person wrote - #365
Merged
Merged
Conversation
An operator signs off "ByteVeda Academy" and the layout stamped "byteveda." two lines above it, contradicting the signature. The footer named our internal tooling to the customer. Both go; mail the console sends on its own account keeps them, because nobody signs one. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
2 Skipped Deployments
|
pratyush618
approved these changes
Sep 22, 2026
This branch was successfully deployed
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.
A sheet went out from the composer and arrived looking like this:
Two things wrong, and they are the same thing twice.
layout()stamps abyteveda.wordmark at the top of every message the console sends. On a signup confirmation that is right — nobody signs those, so the mark is the only thing saying who wrote. On a message an operator typed and signed "ByteVeda Academy", it is a second, quieter, lowercase, differently branded signature sitting two lines above the real one.The footer is worse. "Sent from the ByteVeda console." tells a parent waiting on a worksheet the name of our internal tooling. That sentence was written for us and ended up addressed to them.
The rule
Mail the console sends on its own account — signup confirmations, announcements, broadcasts — keeps the wordmark and the footer. Mail a person wrote — replies and composed messages — gets neither, because the person signs it themselves.
shell()now holds the card markup,layout()adds the masthead and footer rows to it, andplainLayout()does not.replyEmailandcomposedEmailuse the plain one. The paragraph-splitting both of them duplicated moved into a sharedparagraphs()helper on the way past.Nothing else changes: same card, same width, same type.
Tests
templates.tshad none, which is how a user-visible regression got out. There are now ten, covering the rule in both directions — operator mail carries no wordmark and no console footer, a confirmation still does — plus the subject handling, theRe:prefix not doubling, quoting, paragraph breaks, and that a body is escaped before it reaches a mail client.248 admin tests pass. Typecheck and Biome clean repo-wide.
Rendered the composed HTML to check it against the intended layout rather than assuming: card, four paragraphs, no masthead row, no footer row.