feat: reloadOnRevoke option, modal close button, compliance docs - #98
Open
DaSchTour wants to merge 4 commits into
Open
feat: reloadOnRevoke option, modal close button, compliance docs#98DaSchTour wants to merge 4 commits into
DaSchTour wants to merge 4 commits into
Conversation
…rade Already-loaded third-party scripts (analytics, ads, ...) can't be unloaded from a running page once consent is withdrawn or a previously accepted category is declined. reloadOnRevoke (default false) reloads the page as the standard industry remedy, firing after logging/dispatch so sendBeacon/keepalive-fetch delivery survives the navigation. Never triggered by first consent or accept-all. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The settings modal could previously only be left via overlay click or Escape, with no on-screen affordance — an accessibility gap. Adds a close (×) button in the top corner, mirroring the existing banner close-button pattern (buildCloseButton / km-banner__close), that returns to the banner view via the existing data-action delegation. aria-label comes from the new optional modal.close translation key (default "Close"), added to all bundled locales. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Documents the mode config option in the README and adds a clearly visible warning in both the README and docs/compliance.md: opt-out mode is intended for CCPA-style jurisdictions only, since DSGVO Art. 6(1)(a) and ePrivacy Art. 5(3) require prior opt-in consent in the EU/EEA (and the UK under PECR). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…ings Most DPAs accept the banner's primary/secondary button styling since both buttons are equally sized, equally weighted, and both on Layer 1. The strictest CNIL/Garante/DSK readings expect identical colour, not just identical size — document the nuance in docs/compliance.md and point to it from the README theming section, with the concrete --km-secondary / --km-secondary-text override to equalize the buttons. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
Bundle ReportChanges will increase total bundle size by 2.03kB (2.79%) ⬆️. This is within the configured threshold ✅ Detailed changes
Affected Assets, Files, and Routes:view changes for bundle: keksmeister-Keksmeister-esmAssets Changed:
Files in
view changes for bundle: keksmeister-Keksmeister-umdAssets Changed:
Files in
|
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
reloadOnRevokeconfig option. Already-loaded third-party scripts can't be unloaded once consent is withdrawn — when enabled,revokeAll()and consent-downgradingapplyChoices()calls (accepted → declined) reload the page after logging/dispatch complete (sendBeacon/keepalive-fetch survive navigation). Never triggered by first consent or accept-all.data-actiondelegation and a new optionalmodal.closetranslation key (added to all 7 bundled locales).mode: 'opt-out'is CCPA-only and unlawful under GDPR/ePrivacy for EU/EEA visitors, in bothdocs/compliance.mdand the README.--km-secondary/--km-secondary-textCSS override to equalize them.Test plan
bun run test— 121/121 tests pass (6 new consent-manager tests forreloadOnRevoke, 3 new UI tests for the modal close button)bun run typecheck— cleanbun run build— succeeds (ESM + UMD)🤖 Generated with Claude Code