Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions cspell.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
"astropub",
"astrojs",
"Bluesky",
"d'œuvres",
"Devries",
"dimitri",
"Emscripten",
Expand Down
7 changes: 5 additions & 2 deletions src/components/Header.astro
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ function hrefProps(pathname: string) {
<a {...hrefProps("/articles")}>Articles</a>
<a {...hrefProps("/cfp")}>CFP</a>
<a {...hrefProps("/faqs")}>FAQs</a>
<a {...hrefProps("/schedule")}>Schedule</a>
<a {...hrefProps(links.shop)}>Shop</a>
<a {...hrefProps("/travel")}>Travel</a>
<Button
Expand All @@ -44,6 +45,7 @@ function hrefProps(pathname: string) {
<a {...hrefProps("/articles")}>Articles</a>
<a {...hrefProps("/cfp")}>CFP</a>
<a {...hrefProps("/faqs")}>FAQs</a>
<a {...hrefProps("/schedule")}>Schedule</a>
<a {...hrefProps(links.shop)}>Shop</a>
<a {...hrefProps("/travel")}>Travel</a>
<Button
Expand Down Expand Up @@ -150,7 +152,7 @@ function hrefProps(pathname: string) {
display: flex;
align-items: center;
font-weight: var(--fontWeightLight);
gap: clamp(0.75rem, 1.5vw, 2rem);
gap: clamp(0.55rem, 1.25vw, 2rem);
}

.header-link-inactive {
Expand All @@ -160,9 +162,10 @@ function hrefProps(pathname: string) {
.header-button {
justify-content: center;
margin-left: 0.35rem;
text-wrap: nowrap;
}

@media (width >= 1017px) {
@media (width >= 1117px) {
.header-content-area-mobile {
display: none;
}
Expand Down
141 changes: 141 additions & 0 deletions src/components/ScheduledActivity.astro
Original file line number Diff line number Diff line change
@@ -0,0 +1,141 @@
---
import { markdown } from "@astropub/md";

import { ActivityLocation } from "~/data/schedule";

import Heading from "./Heading.astro";
import Arrow from "./Arrow.astro";

interface Props {
at?: string;
description?: string[];
id?: string;
location?: ActivityLocation;
class?: string;
level?: "h3" | "h4";
title: string;
}

const {
at,
class: className,
description = [],
id,
location,
level = "h3",
title,
...rest
} = Astro.props;

const descriptionLines = await Promise.all(
description.map(async (p) => await markdown(p)),
);
---

<div
class:list={["scheduled-activity", "scheduled-activity-h3", className]}
id={id}
{...rest}
>
<Heading level={level} class="activity-title">
{title}
</Heading>
<div class="activity-locators">
<div class="activity-time">{at ?? "Time TBA"}</div>
{
location && (
<a class="activity-location" href={location.href}>
{location.text}
</a>
)
}
</div>
{
descriptionLines && (
<div class="activity-description">{descriptionLines}</div>
)
}
</div>

<style>
.scheduled-activity {
font-weight: var(--fontWeightLight);
margin: 0 var(--widthBodyPadding);
max-width: var(--widthBodyLean);
scroll-margin-top: 2rem;
}

.scheduled-activity-h3 {
margin-top: 2rem;
}

.activity-title {
font-family: var(--fontFamilyLogo);
font-size: var(--fontSizeMedium);
font-weight: var(--fontWeightLogo);
text-decoration: none;
}

.activity-title-inner {
display: inline;
}

.activity-locators {
display: flex;
font-family: var(--fontFamilyLogo);
font-weight: var(--fontWeightSemibold);
gap: 0.75rem;
justify-content: space-between;
margin: 0.5rem 0;
}

.activity-time {
font-size: var(--fontSizeMedium);
}

.activity-location {
line-height: 1.25;
text-align: right;
}

.activity-description {
display: flex;
gap: 0.5rem;
flex-direction: column;
width: 100%;
}

.activity-within {
list-style: none;
padding-left: 0;
}

@media (min-width: 490px) {
.scheduled-activity {
display: grid;
grid-template-columns: clamp(5rem, 20vw, 10rem) auto;
grid-template-rows: auto auto auto;
gap: 0.75rem 1rem;
}

.activity-title {
grid-area: 1 / 2 / 2 / 3;
}

.activity-locators {
grid-area: 1 / 1 / 3 / 2;
flex-direction: column;
margin: 0;
justify-content: flex-start;
text-align: right;
}

.activity-description {
grid-area: 2 / 2 / 3 / 3;
}

.activity-within {
grid-area: 3 / 1 / 4 / 3;
}
}
</style>
Loading