@paulpaulstudio/plasmic-consent-embeds
v0.1.0
Published
DSGVO-konforme Two-Klick-Embeds für Plasmic — YouTube/Vimeo/Maps/Twitter blocken bis Consentic-Consent vorliegt.
Maintainers
Readme
@paulpaulstudio/plasmic-consent-embeds
DSGVO-konforme Two-Klick-Embeds für Plasmic. YouTube/Vimeo/Maps/Twitter/Spotify werden blockiert bis der User über das Consentic-Banner explizit zustimmt — danach laden die echten iframes automatisch.
Nutzt @paulpaulstudio/plasmic-consentic als peer-Dependency. Beide Pakete müssen installiert sein.
Components
<ConsentGatedEmbed consentCategory="…">— generischer Wrapper, beliebige Embeds<YouTubeEmbed videoId="…">— YouTube (defaultyoutube-nocookie.com)<VimeoEmbed videoId="…">— Vimeo (defaultdnt=1)<GoogleMapsEmbed query="…" apiKey="…">— Google Maps Embed (besser: Pigeon Maps für DSGVO)<TwitterEmbed tweetId="…" username="…">— Twitter / X<SpotifyEmbed kind="track|album|playlist|…" spotifyId="…">— Spotify
Default-consentCategory ist "marketing" — passt zur Standard-Consentic-Kategorisierung.
Verhalten
| Zustand | Was passiert | |---|---| | Im Plasmic Studio Canvas | Embed wird immer gerendert (Designer sieht das echte Element) | | Live, Consent fehlt | Default-Placeholder mit „Cookie-Einstellungen ändern"-Button (öffnet Consentic-Modal) | | Live, Consent gegeben | Echtes iframe lädt vom Drittanbieter |
Install
npm install @paulpaulstudio/plasmic-consent-embeds @paulpaulstudio/plasmic-consenticUse with @plasmicapp/loader-nextjs
import { initPlasmicLoader } from "@plasmicapp/loader-nextjs";
import { registerConsentic } from "@paulpaulstudio/plasmic-consentic/register-loader";
import { registerConsentEmbeds } from "@paulpaulstudio/plasmic-consent-embeds/register-loader";
export const PLASMIC = initPlasmicLoader({ projects: [...] });
registerConsentic(PLASMIC);
registerConsentEmbeds(PLASMIC);License
MIT
