Repository navigation
feat: add snek speech bubble promoting newsletter signup - #340
Merged
Merged
Conversation
Adds a dismissible speech bubble above the smol snek announcing the newsletter. Clicking the bubble jumps to the footer signup form; dismissal is persisted in localStorage so it only shows until a visitor acknowledges it. https://claude.ai/code/session_017HZSVp3xRBBfzXgoyAS7sc
JesperDramsch
added a commit
that referenced
this pull request
Jun 27, 2026
) Two independent regressions kept "Run JavaScript Tests" red on main and blocked unrelated dependabot PRs: 1. jest-environment-jsdom was bumped to ^30.3.0 (jsdom 26) while jest core stayed at 29. jsdom 26 makes window.location non-configurable, so the `delete window.location` / Object.defineProperty mocks used across the frontend tests throw ("Cannot redefine property: location" / "navigation not implemented"), failing 11 tests. Pin jest-environment-jsdom back to ^29.7.0 to match jest core and restore jsdom 20 location semantics. Verified: full suite green on jsdom 20. 2. snek.js coverage fell below threshold after #340 added the newsletter speech bubble without tests (functions 28.57% vs 40% required). Add a "Newsletter Speech Bubble" test block covering dismissSpeechBubble, both dismiss handlers, and the dismissed/not-dismissed branches. snek.js now exceeds all thresholds (stmts/lines 90%, branches 100%, funcs 71%) with no threshold relaxation. Full suite: 15 suites, 423 tests passing with --coverage --ci. Follow-up (separate PR): modernise the location mocks (history.replaceState) so the suite can move to jest + jsdom v30.
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.
Adds a dismissible speech bubble above the smol snek announcing the newsletter. Clicking the bubble jumps to the footer signup form; dismissal is persisted in localStorage so it only shows until a visitor acknowledges it.