From bfa83022a590ab82c68f5cb57c4e326c84c5315b Mon Sep 17 00:00:00 2001 From: Clark Sell <clark.sell@csell.net> Date: Tue, 16 Jan 2024 06:36:46 -0600 Subject: [PATCH] fix: unscheduled sessions --- src/_components/activities/Card.svelte | 13 ++++++++++--- src/_components/activities/List.svelte | 18 ++++++++++-------- 2 files changed, 20 insertions(+), 11 deletions(-) diff --git a/src/_components/activities/Card.svelte b/src/_components/activities/Card.svelte index 42c787c..b765f38 100644 --- a/src/_components/activities/Card.svelte +++ b/src/_components/activities/Card.svelte @@ -236,7 +236,10 @@ </div> {#if status === 'CANCELLED'} <div class="flex-grow justify-self-end pb-1 pr-3 sm:-mt-2"> - <img class="lazyload h-10" alt="canceled session" src="/images/canceled-stamp.svg" /> + <img + class="lazyload h-10 -rotate-45" + alt="canceled session" + src="/images/canceled-stamp.svg" /> </div> {/if} </div> @@ -408,7 +411,7 @@ {#if status === 'CANCELLED'} <div class="flex items-center justify-center"> <img - class="lazyload relative h-28" + class="lazyload relative h-28 -rotate-45" alt="canceled session" src="/images/canceled-stamp.svg" /> </div> @@ -518,7 +521,11 @@ <div class="flex justify-center space-x-2"> <Icon data={mapMarker} class="h-4 w-4" /> - <span>{lookupEnumLabel(location?.destination)}</span> + {#if location?.destination} + <span>{lookupEnumLabel(location?.destination)}</span> + {:else} + <span>Unscheduled</span> + {/if} </div> </div> </div> diff --git a/src/_components/activities/List.svelte b/src/_components/activities/List.svelte index 699ccfd..c7c635b 100644 --- a/src/_components/activities/List.svelte +++ b/src/_components/activities/List.svelte @@ -285,16 +285,18 @@ {#each day.timeSlots as ts} <div class="relative"> - <h2 - class="sticky top-16 z-10 whitespace-nowrap bg-gray-100 pb-6 pt-2 text-3xl + {#if day.dayOfYear !== 'Invalid Date'} + <h2 + class="sticky top-16 z-10 whitespace-nowrap bg-gray-100 pb-6 pt-2 text-3xl font-bold leading-9 tracking-tight text-thatOrange-400 sm:text-4xl sm:leading-10 lg:top-20 lg:text-5xl"> - {#if !dayjs(ts.timeSlot).isValid()} - Unscheduled - {:else} - {dayjs(ts.timeSlot).format('h:mm A z')} - {/if} - </h2> + {#if !dayjs(ts.timeSlot).isValid()} + Unscheduled + {:else} + {dayjs(ts.timeSlot).format('h:mm A z')} + {/if} + </h2> + {/if} <div class="mb-12"> <ul