Skip to content

Commit ae46889

Browse files
Anthony Baileyclaude
andcommitted
Embed DonorBox form on /littlehelpers page
Replace temporary redirect with embedded donation form: - Add DonorBoxEmbed.svelte component with locale support - Add littlehelpers.md with campaign content matching DonorBox page - Remove /littlehelpers redirect from redirects.ts Phase 1 of Little Helpers campaign integration (issue #5). 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
1 parent 501eab5 commit ae46889

File tree

3 files changed

+75
-3
lines changed

3 files changed

+75
-3
lines changed
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
<script lang="ts">
2+
import { onMount } from 'svelte'
3+
import { getLocale } from '$lib/paraglide/runtime'
4+
5+
/** DonorBox campaign slug (required) */
6+
export let campaignSlug: string
7+
8+
/** iframe height in pixels */
9+
export let height = 685
10+
11+
/** Whether to enable PayPal Express in the widget */
12+
export let paypalExpress = true
13+
14+
$: locale = getLocale()
15+
$: embedSrc = `https://donorbox.org/embed/${campaignSlug}?hide_donation_meter=true&language=${locale}`
16+
17+
onMount(() => {
18+
const script = document.createElement('script')
19+
script.src = 'https://donorbox.org/widget.js'
20+
if (paypalExpress) {
21+
script.setAttribute('paypalExpress', 'true')
22+
}
23+
document.body.appendChild(script)
24+
25+
return () => {
26+
document.body.removeChild(script)
27+
}
28+
})
29+
</script>
30+
31+
<div class="donorbox-container">
32+
<iframe
33+
src={embedSrc}
34+
height="{height}px"
35+
width="100%"
36+
style="max-width: 500px; min-width: 310px;"
37+
seamless
38+
name="donorbox"
39+
frameborder="0"
40+
scrolling="no"
41+
allowpaymentrequest
42+
title="Donation form"
43+
></iframe>
44+
</div>
45+
46+
<style>
47+
.donorbox-container {
48+
display: flex;
49+
justify-content: center;
50+
margin: 2rem 0;
51+
}
52+
</style>

src/lib/redirects.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,7 @@ const REDIRECTS: Record<string, string> = {
99
}
1010

1111
/** Temporary redirects (302) - for time-limited campaigns, A/B tests, etc. */
12-
const TEMPORARY_REDIRECTS: Record<string, string> = {
13-
'/littlehelpers': 'https://donorbox.org/pauseai-s-little-helpers'
14-
}
12+
const TEMPORARY_REDIRECTS: Record<string, string> = {}
1513

1614
export function handleRedirects(path: string) {
1715
const permanent = REDIRECTS[path]

src/posts/littlehelpers.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
---
2+
title: Little Helpers Campaign
3+
description: Help fund volunteer stipends for PauseAI advocates working to address AI safety concerns.
4+
---
5+
6+
<script>
7+
import DonorBoxEmbed from '$lib/components/DonorBoxEmbed.svelte'
8+
</script>
9+
10+
Volunteers like Maxime, Raluca, and Mark are the heartbeat of PauseAI—from organizing protests in Paris to building chapters across four continents. This December, we're showcasing their work in daily videos.
11+
12+
A €175/month stipend transforms a volunteer who can squeeze in a few hours on weekends into someone who can dedicate real time to this work. It's the difference between sending a few emails and leading a chapter, between attending one meeting and coordinating with policymakers.
13+
14+
We're raising €21,000 to fund stipends for at least ten volunteers throughout 2026. Any funds beyond this goal will support volunteer microgrants.
15+
16+
**Generous donors have pledged to match contributions through Christmas.**
17+
18+
Help us grow this movement. Give the gift of dedicated advocacy this holiday season—become a Little Helper yourself.
19+
20+
<DonorBoxEmbed campaignSlug="pauseai-s-little-helpers" />
21+
22+
**Planning a larger contribution?** For donations of €1,000 or more, please [contact us](mailto:ella@pauseai.info) about IBAN transfers to minimize fees.

0 commit comments

Comments
 (0)