<script lang="ts">
    import { onMount } from "svelte"
    import CookieSet from "./cookieSet.svelte"
    $: iframeTitle = "testrest"

    let setHeight = (element: HTMLIFrameElement) => {
        element.style.height = (element.offsetWidth / 16) * 9 + "px"
    }
</script>

<CookieSet cookieName="{'googleMaps'}" textPosition="{'unten'}" background="{'rgba(44, 44, 44, 0.4)'}">
    <!-- svelte-ignore a11y-missing-attribute -->
    <iframe
        src="https://www.google.com/maps/embed?pb=!1m18!1m12!1m3!1d20097.11535738499!2d11.016094258611309!3d50.976613538609506!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x47a47295445dec17%3A0x78ec05d774043a43!2sall%20kids%20-%20Secondhand%20Kinderbekleidung!5e0!3m2!1sde!2sde!4v1694951373813!5m2!1sde!2sde"
        use:setHeight
        id="iframe"
        style="border:0;"
        allowfullscreen="{true}"
        loading="lazy"
        referrerpolicy="no-referrer-when-downgrade"></iframe>
</CookieSet>

<style>
    iframe {
        width: 100%;
        max-width: 100%;
        border: 0;
    }
</style>
