web-components
0.0.6
Patch Changes
- 3a60e4b: Update vulnerable transitive dependencies to patched versions.
- Updated dependencies [3dc13a0]
0.0.5
Patch Changes
- ba3ce20: Update Axios and SvelteKit to patched releases and refresh vulnerable transitive dependencies.
- Updated dependencies [bb844a5]
- Updated dependencies [c3fe401]
- Updated dependencies [b821430]
- Updated dependencies [9518dbb]
- Updated dependencies [c3fe401]
0.0.4
Patch Changes
- Updated dependencies [f5911a6]
0.0.3
Patch Changes
0.0.2
Patch Changes
9a490af: Pick the "Powered by Consent Pro" logo colour from the banner background.
consentpro-utils
- New
relativeLuminanceandcontrastingMonochromehelpers: WCAG 2.1 relative luminance, and a black/white pick by contrast ratio against a background.
web-components
ConsentBanner's wordmark now reads--consentpro-color-attribution, falling back to the banner's own text colour. The wordmark is alreadycurrentColor, so the variable flips it; the "Powered by" label keeps the banner's text colour.
consentpro-v2 / web-app
- Both set
--consentpro-color-attributionfrom the banner background, so the live banner and the style preview render the same logo.
- New
8384efa: Show a placeholder overlay on iframes blocked for want of consent on custom (non-Webflow) sites.
Custom sites have no pasted
fs-consent-element="placeholder"markup, so a blocked embed simply lost itssrcand rendered as a blank box. The overlay now ships as a web component thatcore/v2swaps into the blocked iframe itself.web-components
- New
<consentpro-placeholder>custom element, built as its ownplaceholder.jsCDN bundle. Like every other component in this package, its props are plain JS properties observed as no attribute, and its buttons dispatch bubbling, composedconsentpro:open-preferences/consentpro:allowevents.
consentpro-dictionary
getConsentCopyreturns aplaceholderblock (message,preferencesText,acceptAllText), so the overlay is localized like every other component.
server
GET /v2/cdn/web-components/placeholder.jsserves the new bundle, andcopy.jsoncarries theplaceholderstrings.
consentpro-v2
new/custom-site/placeholder.tsbuilds the blocked iframe's document as a string, which the existing blob path swaps into the iframe'ssrc. It is self-contained: the CDN module that registers the element, plus the script that waits for that registration, creates the element and assigns the copy as JS properties. No markup is parsed, mutated or serialized on the way, and the copy is escaped into the script rather than interpolated into HTML.- That script tag is pinned with the build-time
sha384hash, soplaceholder.jsis now SRI-checked like the other component bundles. - Blocked iframes wire the overlay's events through
custom-site/events.ts: the document is a same-originblob:, so the component'sconsentpro:*events reach the consent-state layer directly. - A blocked iframe's own
sandboxis stashed and dropped while the placeholder is shown, then restored verbatim before the original URL loads again. It applies to the untrusted embed, not to our placeholder, and withoutallow-scriptsit kept the overlay from ever rendering. iframe-blockednow fires once per blocked iframe, carrying the embed's URL. Re-rendering a placeholder whose copy arrived late no longer emits a second event whosesrchad already been replaced.
- New
d7331e4: Style the preferences toggle and the dialog backdrop from the web app.
web-app
- The Open preferences colours card now carries Toggle Inactive Track, Toggle Active Track (the former "Preferences Checkbox"), Toggle Circular Handle and Preferences Overlay. Left on their defaults the columns stay
null, so an existing banner looks exactly as before. ColorFieldtakes analphaprop: an opacity track under the hue slider, a checkerboard behind every swatch, and a hex field that accepts#rrggbbaa. Only the overlay opts in — a colour that paints a surface has nothing to be translucent over.- The overlay starts at no backdrop (
#00000000). Choosing a colour on a transparent field lands at 20% opacity rather than staying invisible; the opacity track can still take it back to nothing.
web-components
ConsentPreferencesDialog's backdrop default drops from 10% black totransparent: a dialog washes the page only where a site asks for it. The backdrop box is unchanged otherwise, so click-to-close still works, and any site setting--consentpro-color-overlayis unaffected.
server / consentpro-types
checkbox_inactive_color,checkbox_handle_colorandpreferences_overlay_colorare read, validated and saved onbanner_settingsandbanner_instances, and published ascheckboxInactive,checkboxHandleandpreferencesOverlay. The overlay column validates#rrggbbor#rrggbbaa; the rest stay six digits.
consentpro-v2
- Maps those to
--consentpro-color-toggle-off,--consentpro-color-toggle-thumband--consentpro-color-overlay. The handle keeps whatever colour is picked in both switch states — nothing recolours it from the track any more.
- The Open preferences colours card now carries Toggle Inactive Track, Toggle Active Track (the former "Preferences Checkbox"), Toggle Circular Handle and Preferences Overlay. Left on their defaults the columns stay
Updated dependencies [fecdc78]
Updated dependencies [fecdc78]
Updated dependencies [8384efa]
Updated dependencies [d3e426d]
Updated dependencies [a580774]
Updated dependencies [d7331e4]
Updated dependencies [2ebb655]