metis/src/EventModal.svelte

26 lines
683 B
Svelte
Raw Normal View History

2022-03-06 00:59:36 +01:00
<script>
import { Modal, ModalHeader, ModalBody, ModalFooter, Icon } from 'sveltestrap';
export let event = undefined;
export let open = undefined;
export let toggle = undefined;
</script>
<Modal isOpen={open} {toggle} centered scrollable>
<ModalHeader {toggle}>{event.title}</ModalHeader>
{#if event.extendedProps.description}
<ModalBody>
{#each event.extendedProps.description.split('\n') as line}
<p>{line}</p>
{/each}
</ModalBody>
{/if}
2022-03-06 01:14:43 +01:00
2022-03-06 00:59:36 +01:00
{#if event.extendedProps.location}
2022-03-06 01:14:43 +01:00
<ModalFooter class="justify-content-start">
2022-03-06 00:59:36 +01:00
<Icon name="geo" />
2022-03-06 01:14:43 +01:00
<span>{event.extendedProps.location}</span>
2022-03-06 00:59:36 +01:00
</ModalFooter>
{/if}
</Modal>