Skip to content

Open-source event management and ticket selling platform — perfect for concerts, conferences, and everything in between 🎟️ If you find this project helpful, please consider giving us a star ⭐️

762 B
Raw Blame
import {ActionIcon, Tooltip} from '@mantine/core';
import {IconCalendarPlus} from '@tabler/icons-react';
import {t} from "@lingui/macro";
import {Event, EventOccurrence} from "../../../types.ts";
import {CalendarOptionsPopover} from "../CalendarOptionsPopover";

interface AddToCalendarProps {
    event: Event;
    occurrence?: EventOccurrence;
}

export const AddToEventCalendarButton = ({event, occurrence}: AddToCalendarProps) => {
    return (
        <CalendarOptionsPopover event={event} occurrence={occurrence}>
            <Tooltip label={t`Add to Calendar`}>
                <ActionIcon variant="subtle">
                    <IconCalendarPlus size={20}/>
                </ActionIcon>
            </Tooltip>
        </CalendarOptionsPopover>
    );
};