workadventure/front/src/Components/EmbedScreens/CoWebsitesContainer.svelte

43 lines
1.1 KiB
Svelte
Raw Normal View History

2022-01-05 10:30:27 +01:00
<script lang="typescript">
2022-01-17 10:04:54 +01:00
import { coWebsites } from "../../Stores/CoWebsiteStore";
2022-01-05 10:30:27 +01:00
import CoWebsiteThumbnail from "./CoWebsiteThumbnailSlot.svelte";
export let vertical = false;
</script>
2022-01-17 10:04:54 +01:00
{#if $coWebsites.length > 0}
2022-01-05 10:30:27 +01:00
<div id="cowebsite-thumbnail-container" class:vertical>
2022-02-10 11:40:36 +01:00
{#each [...$coWebsites.values()] as coWebsite, index (coWebsite.getId())}
2022-01-05 10:30:27 +01:00
<CoWebsiteThumbnail {index} {coWebsite} {vertical} />
{/each}
</div>
{/if}
<style lang="scss">
#cowebsite-thumbnail-container {
pointer-events: all;
2022-01-17 10:04:54 +01:00
height: 100px;
width: 100%;
2022-01-05 10:30:27 +01:00
display: flex;
2022-01-17 10:04:54 +01:00
position: absolute;
bottom: 5px;
left: 2%;
2022-01-05 10:30:27 +01:00
overflow-x: auto;
overflow-y: hidden;
&.vertical {
height: auto !important;
2022-01-17 10:04:54 +01:00
width: auto !important;
bottom: auto !important;
left: auto !important;
position: relative;
2022-01-05 10:30:27 +01:00
overflow-x: hidden;
overflow-y: auto;
flex-direction: column;
align-items: center;
padding-top: 4px;
padding-bottom: 4px;
}
}
</style>