Event Overview

{#if loading}
{:else if event}

{event.name}

Date: {formatDate(event.date)}
Created: {formatDate(event.created_at)}

Email Details

Subject:

{event.email_subject}

Body:

{event.email_body}

{:else if error}

{error}

{/if}

Google Account

Required for syncing participants and sending emails

{ // Refresh the page or update UI state as needed error = ''; }} onError={(errorMsg) => { error = errorMsg; }} />

Participants

{#if participantsLoading}
{#each Array(5) as _}
{/each}
{:else if participants.length > 0}
{#each participants as participant} {/each}
Name Surname Email Scanned Email Sent
{participant.name} {participant.surname} {participant.email} {#if participant.scanned}
{:else}
{/if}
{#if participant.email_sent}
{:else}
{/if}
{:else}

No participants found. Click "Sync Participants" to load from Google Sheets.

{/if}

Send Emails

{participants.filter(p => !p.email_sent).length} uncontacted participants
{#if sendingEmails}
Sending {emailProgress.total} emails... Please wait.
{:else}
{#if participants.filter(p => !p.email_sent).length > 0}
Warning: Do not close this window while emails are being sent. The process may take several minutes.
{:else}

All participants have been contacted!

No pending emails to send.

{/if}
{/if}
{#if emailResults}

Email Results

{emailResults.summary.success} successful, {emailResults.summary.errors} failed
Sent: {emailResults.summary.success}
Failed: {emailResults.summary.errors}
Total: {emailResults.summary.total}
{#if emailResults.results.length > 0}
{#each emailResults.results as result} {/each}
Name Email Status
{result.participant.name} {result.participant.surname} {result.participant.email} {#if result.success}
Sent
{:else}
Failed {#if result.error} ({result.error}) {/if}
{/if}
{/if}
{/if} {#if error}

{error}

{/if}