docs: documentation audit run 4 + branch protection#4
Merged
wistfulvariable merged 7 commits intomasterfrom Mar 4, 2026
Merged
docs: documentation audit run 4 + branch protection#4wistfulvariable merged 7 commits intomasterfrom
wistfulvariable merged 7 commits intomasterfrom
Conversation
…t, logo watermark Rendering features: - Multi-image grid: 1/2/3/4-photo layouts (280/220/220/160px heights) in tweet-html.mjs - Thread-as-single-image: renderThreadToImage() + generateThreadHtml() with connector lines - Phone mockup frame: PHONE_CHROME constant, frame='phone' option wraps tweet in bezel - Custom gradient: gradientFrom/gradientTo/gradientAngle, takes priority over named presets - Logo/watermark: flex-row placement (removed position:absolute addLogoToHtml), logo/logoPosition/logoSize exposed in all schemas Schema & routing: - Added logo, frame, gradientFrom/To/Angle, thread to all Zod schemas - logo/fontUrl excluded from demoQuerySchema (SSRF risk) - Thread branching in GET/POST /screenshot and /demo/screenshot handlers Tests: - New tests/unit/tweet-html.test.mjs covering all 5 features - Extended tests/integration/screenshot.test.mjs with thread, logo, frame, gradient cases Docs: - Rewrote API.md: all endpoints, new params, error codes, deployment, examples - Rewrote README.md: complete CLI option tables, dimension presets, new feature examples Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- pitfalls.md: remove two stale entries (logo and multi-image were fixed) - feature-inventory.md: remove broken labels, add 5 missing render options (frame, gradientFrom/To/Angle, logo/logoPosition/logoSize, thread) - rendering-pipeline.md: add thread/frame/logo/custom-gradient sections, rewrite for density (78→60 lines) - testing.md: condense to 78 lines (was 93) - api-endpoints.md: condense to 58 lines (was 95) - debugging.md: create new file (recommended in Run 3, never built) - CLAUDE.md: remove Twitter API section (belongs in Tier 2), add debugging.md to topic table - MEMORY.md: update test count 508→670, 17→19 unit, 8→10 integration Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
All three CI jobs (test, secrets-scan, lint-security) are now required status checks via GitHub branch protection — merges blocked until all pass. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
addLogoToHtml was removed when logo support was integrated directly into generateTweetHtml() as logo/logoPosition/logoSize options. core.mjs still re-exported it (causing a broken named export) and core.test.mjs still tested the old position:absolute behavior. Logo coverage is fully handled by tweet-html.test.mjs which already tests the flex-based implementation. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- tweet-html.test.mjs: single-tweet thread test checked `not.toContain('flex: 1')`
but flex:1 appears on the content column too; check `width: 2px` instead
(the connector line's unique signature)
- demo-schema.test.mjs: demoQuerySchema now includes thread field (boolString,
default false); add thread: false to expected output
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Using .default('false') on a ZodEffects (post-transform) type bypasses
the transform, so absent boolString fields returned the string "false"
instead of boolean false. This is a silent bug: "false" is truthy, so
any if (options.hideMetrics) check would behave incorrectly for missing
query params. Changed to .default(false) which uses the post-transform
output type.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
The boolString default was corrected from .default('false') to
.default(false) so absent query params return boolean false (not
the string "false" which is truthy). Update tests to match.
Co-Authored-By: Claude Sonnet 4.6 <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
debugging.md(rendering failures, font/emoji, worker timeouts, auth/config diagnosis)Test plan
🤖 Generated with Claude Code