Skip to content

Commit 78e1bd7

Browse files
committed
get in touch page
1 parent 7a88bc4 commit 78e1bd7

12 files changed

Lines changed: 907 additions & 198 deletions

File tree

package-lock.json

Lines changed: 777 additions & 171 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/components/organisms/Navigation.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ const isActive = (item: NavItemType) => {
6262
<!-- Right side: Nav Links + Search + Mobile Menu -->
6363
<div class="flex items-center gap-6">
6464
<!-- Navigation Links -->
65-
<div class="hidden items-center space-x-1 md:flex">
65+
<div class="hidden items-center gap-x-6 md:flex lg:gap-x-8">
6666
{
6767
items.map((item) => (
6868
<NavItem
Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
---
2+
export interface Props {
3+
calLink?: string;
4+
namespace?: string;
5+
origin?: string;
6+
minHeight?: string;
7+
}
8+
9+
const {
10+
calLink = 'book/30min',
11+
namespace = '30min',
12+
origin = 'https://cal.draftlab.org',
13+
minHeight = '720px',
14+
} = Astro.props;
15+
16+
const containerId = `cal-inline-${namespace}`;
17+
---
18+
19+
<div class="mx-auto -my-6 w-full max-w-5xl sm:-my-8">
20+
<div
21+
id={containerId}
22+
class="w-full overflow-scroll"
23+
style={`min-height:${minHeight}`}
24+
></div>
25+
</div>
26+
27+
<script
28+
is:inline
29+
type="text/javascript"
30+
define:vars={{ containerId, calLink, namespace, origin }}
31+
>
32+
(function (C, A, L) {
33+
let p = function (a, ar) { a.q.push(ar); };
34+
let d = C.document;
35+
C.Cal = C.Cal || function () {
36+
let cal = C.Cal;
37+
let ar = arguments;
38+
if (!cal.loaded) {
39+
cal.ns = {};
40+
cal.q = cal.q || [];
41+
d.head.appendChild(d.createElement("script")).src = A;
42+
cal.loaded = true;
43+
}
44+
if (ar[0] === L) {
45+
const api = function () { p(api, arguments); };
46+
const ns = ar[1];
47+
api.q = api.q || [];
48+
if (typeof ns === "string") {
49+
cal.ns[ns] = cal.ns[ns] || api;
50+
p(cal.ns[ns], ar);
51+
p(cal, ["initNamespace", ns]);
52+
} else {
53+
p(cal, ar);
54+
}
55+
return;
56+
}
57+
p(cal, ar);
58+
};
59+
})(window, origin + "/embed/embed.js", "init");
60+
61+
Cal("init", namespace, { origin: origin });
62+
63+
Cal.ns[namespace]("inline", {
64+
elementOrSelector: "#" + containerId,
65+
config: { layout: "month_view", useSlotsViewOnSmallScreen: "true" },
66+
calLink: calLink,
67+
});
68+
69+
Cal.ns[namespace]("ui", { hideEventTypeDetails: false, layout: "month_view" });
70+
</script>

src/components/sections/PeopleSection.astro

Lines changed: 16 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,9 @@ const skillsBySlug = new Map(
2929
<div class="grid gap-8 sm:grid-cols-2 lg:grid-cols-2">
3030
{
3131
people.map((person) => (
32-
<div class="flex max-h-44 items-stretch gap-5 overflow-hidden">
32+
<div class="flex items-start gap-5">
3333
{person.headshot && (
34-
<div class="aspect-square shrink-0 self-stretch">
34+
<div class="aspect-square w-28 shrink-0 shadow-sm sm:w-32">
3535
<Image
3636
src={person.headshot}
3737
alt={person.name}
@@ -41,20 +41,9 @@ const skillsBySlug = new Map(
4141
/>
4242
</div>
4343
)}
44-
<div class="min-w-0">
44+
<div class="min-w-0 flex-1">
4545
<h3 class="font-serif text-lg font-normal text-ink">
46-
{person.url ? (
47-
<Link
48-
href={person.url}
49-
variant="unstyled"
50-
class="underline decoration-sand decoration-1 underline-offset-2 hover:decoration-secondary-400"
51-
external
52-
>
53-
{person.name}
54-
</Link>
55-
) : (
56-
person.name
57-
)}
46+
{person.name}
5847
</h3>
5948
{person.bio && (
6049
<p class="mt-2 line-clamp-4 text-sm leading-relaxed text-ink-soft">
@@ -76,6 +65,18 @@ const skillsBySlug = new Map(
7665
))}
7766
</div>
7867
)}
68+
{person.url && (
69+
<p class="mt-3 text-xs text-ink-muted">
70+
<Link
71+
href={person.url}
72+
variant="unstyled"
73+
class="underline decoration-sand decoration-1 underline-offset-2 hover:text-secondary-500 hover:decoration-secondary-400"
74+
external
75+
>
76+
Personal website ↗
77+
</Link>
78+
</p>
79+
)}
7980
</div>
8081
</div>
8182
))

src/components/sections/Sections.astro

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
---
22
import ButtonSection from '@components/sections/ButtonSection.astro';
3+
import CalEmbedSection from '@components/sections/CalEmbedSection.astro';
34
import CardSection from '@components/sections/CardSection.astro';
45
import FlexiSection from '@components/sections/FlexiSection.astro';
56
import FrameworkSection from '@components/sections/FrameworkSection.astro';
@@ -134,6 +135,15 @@ const { sectionItems } = Astro.props;
134135
limit={section.limit}
135136
/>
136137
);
138+
case 'calEmbed':
139+
return (
140+
<CalEmbedSection
141+
calLink={section.calLink}
142+
namespace={section.namespace}
143+
origin={section.origin}
144+
minHeight={section.minHeight}
145+
/>
146+
);
137147
default:
138148
return null;
139149
}

src/content/config.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -168,6 +168,13 @@ const pagesCollection = defineCollection({
168168
filterType: z.enum(['client', 'partner', 'funder']).optional(),
169169
limit: z.number().optional(),
170170
}),
171+
SectionCommonSchema.extend({
172+
type: z.literal('calEmbed'),
173+
calLink: z.string().optional(),
174+
namespace: z.string().optional(),
175+
origin: z.string().optional(),
176+
minHeight: z.string().optional(),
177+
}),
171178
]);
172179

173180
const flexiSectionSchema = SectionCommonSchema.extend({

src/content/navigation/footer-2.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,10 @@
2020
},
2121
{
2222
"type": "link",
23-
"label": "Contact",
23+
"label": "Get in touch",
2424
"link": {
25-
"type": "external",
26-
"url": "mailto:hello@draftlab.org"
25+
"type": "internal",
26+
"pageRef": "/get-in-touch"
2727
}
2828
}
2929
]

src/content/navigation/main.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,12 @@
2222
},
2323
{
2424
"type": "link",
25-
"label": "Contact",
25+
"label": "Get in touch",
2626
"link": {
27-
"type": "external",
28-
"url": "mailto:hello@draftlab.org"
27+
"type": "internal",
28+
"pageRef": "/get-in-touch"
2929
},
30-
"description": "Get in touch"
30+
"description": "Book a conversation with Draftlab"
3131
}
3232
]
3333
}

src/content/pages/about.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ sections:
3434
### Open Technology Fund pro bono support
3535
3636
37-
Draftlab provides pro bono design and technical support to internet freedom projects through the Open Technology Fund. If you're an OTF-funded project that could use help with user research, product design, or technical architecture, [get in touch](mailto:hello@draftlab.org).
37+
Draftlab provides pro bono design and technical support to internet freedom projects through the Open Technology Fund. If you're an OTF-funded project that could use help with user research, product design, or technical architecture, [get in touch](/get-in-touch).
3838
- type: button
3939
buttons:
4040
- variant: primary
@@ -43,5 +43,5 @@ sections:
4343
text: See our work
4444
- variant: outline
4545
size: lg
46-
href: mailto:hello@draftlab.org
46+
href: /get-in-touch
4747
text: Get in touch
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
title: Get in touch
2+
status: published
3+
description: Book a 30-minute conversation with Draftlab.
4+
sections:
5+
- type: hero
6+
title: Get in touch
7+
subtitle: Book a 30-minute conversation. We'll listen to where you are, what you're working on, and figure out together whether we're the right fit.
8+
- type: calEmbed
9+
calLink: book/30min
10+
namespace: 30min
11+
origin: https://cal.draftlab.org
12+
minHeight: 720px
13+
- type: richText
14+
content: >-
15+
Prefer email? Write to [hello@draftlab.org](mailto:hello@draftlab.org) and we'll get back to you.

0 commit comments

Comments
 (0)