hypnagaga/packages/graphics-components/docs/assets/SponsorshipAd-BV27ibKm.js

27 lines
2 KiB
JavaScript

import{j as o}from"./index-bIIEL2MP.js";import{useMDXComponents as s}from"./index-CO-0pc0F.js";import{M as t,C as p}from"./index-Z-6k0Xrj.js";import{S as i,D as m}from"./SponsorshipAd.stories-CAZ21CuR.js";import"./_commonjsHelpers-D6-XlEtG.js";import"./iframe-CzjIX-qr.js";import"./index-aQYXhgXp.js";import"./index-DrFu-skq.js";import"./props-b4vEeO_8.js";import"./runtime-C3rQLW--.js";import"./lifecycle-F2p_Qkk3.js";import"./create-runtime-stories-7AWWVphH.js";import"./snippet-C5kbqVpq.js";import"./svelte-component-C8Ginrj8.js";import"./get-C3XmtPLd.js";import"./ResponsiveAd-CbJNHDhi.js";import"./index-client-BAw8T8-V.js";import"./svelte-head-xbEMkVns.js";import"./throttle-CHB1Npaq.js";import"./key-BFGg-sHz.js";import"./window-DXjFTZv5.js";import"./attributes-Cg6aLqN3.js";import"./style-DvJ3IcV1.js";import"./Block-D3Ui8rd-.js";function n(r){const e={blockquote:"blockquote",code:"code",h1:"h1",p:"p",pre:"pre",strong:"strong",...s(),...r.components};return o.jsxs(o.Fragment,{children:[o.jsx(t,{of:i}),`
`,o.jsx(e.h1,{id:"sponsorshipad",children:"SponsorshipAd"}),`
`,o.jsx(e.p,{children:"Add a sponsorship ad to your page."}),`
`,o.jsxs(e.blockquote,{children:[`
`,o.jsxs(e.p,{children:[o.jsx(e.strong,{children:"IMPORTANT!"})," Make sure ads are only used on dotcom pages, never on embeds."]}),`
`]}),`
`,o.jsx(e.pre,{children:o.jsx(e.code,{className:"language-svelte",children:`<!-- +page.svelte -->
<script>
import { AdScripts } from '@reuters-graphics/graphics-components';
<\/script>
<!-- Include AdScripts only ONCE per page for any type of ad -->
<AdScripts />
`})}),`
`,o.jsx(e.pre,{children:o.jsx(e.code,{className:"language-svelte",children:`<!-- App.svelte -->
<script>
import { SponsorshipAd } from '@reuters-graphics/graphics-components';
let { embedded = false } = $props();
<\/script>
<!-- Check if in an embed context! -->
{#if !embedded}
<SponsorshipAd />
{/if}
`})}),`
`,o.jsx(p,{of:m})]})}function O(r={}){const{wrapper:e}={...s(),...r.components};return e?o.jsx(e,{...r,children:o.jsx(n,{...r})}):n(r)}export{O as default};