mirror of
https://github.com/olehomelchenko/astrolabe.git
synced 2026-08-08 02:02:33 +00:00
Donate: redirect to Ukraine's defense (savelife.in.ua)
This commit is contained in:
+5
-1
@@ -114,7 +114,11 @@ export function App() {
|
|||||||
<Icon name="info" />
|
<Icon name="info" />
|
||||||
</IconButton>
|
</IconButton>
|
||||||
<span className={styles.headerDivider} aria-hidden="true" />
|
<span className={styles.headerDivider} aria-hidden="true" />
|
||||||
<Button variant="soft-accent" onClick={() => openModal('donate')} title="Support Astrolabe">
|
<Button
|
||||||
|
variant="soft-accent"
|
||||||
|
onClick={() => openModal('donate')}
|
||||||
|
title="Support Ukraine's defense"
|
||||||
|
>
|
||||||
Donate
|
Donate
|
||||||
</Button>
|
</Button>
|
||||||
<ThemeToggle />
|
<ThemeToggle />
|
||||||
|
|||||||
@@ -43,4 +43,9 @@ describe('DonateModal', () => {
|
|||||||
const link = container.querySelector('a')!;
|
const link = container.querySelector('a')!;
|
||||||
expect((link.textContent ?? '').trim().length).toBeGreaterThan(0);
|
expect((link.textContent ?? '').trim().length).toBeGreaterThan(0);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
test('the CTA points to the Ukraine-defense donation, not a placeholder', () => {
|
||||||
|
const link = container.querySelector('a')!;
|
||||||
|
expect(link.getAttribute('href')).toBe('https://savelife.in.ua/en/donate-en/');
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -2,35 +2,36 @@
|
|||||||
* Donate modal body (spec §01B/§01C).
|
* Donate modal body (spec §01B/§01C).
|
||||||
*
|
*
|
||||||
* Rendered inside ModalShell — no backdrop, close button, or focus trap here;
|
* Rendered inside ModalShell — no backdrop, close button, or focus trap here;
|
||||||
* the shell owns all of that (docs/architecture/03 → Layer 3). Minimal by design:
|
* the shell owns all of that (docs/architecture/03 → Layer 3). The project asks
|
||||||
* a sincere message and a single clear primary action.
|
* for nothing for itself: the one solicitation redirects to Ukraine's defense,
|
||||||
*
|
* where the author would forward any project donations anyway.
|
||||||
* TODO: Replace DONATE_URL placeholder with the real donation URL before launch.
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
import styles from './DonateModal.module.css';
|
import styles from './DonateModal.module.css';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Placeholder donation URL — replace before launch.
|
* Donations go to Ukraine's defense, not the project. savelife.in.ua is the
|
||||||
*
|
* Come Back Alive (Повернись живим) foundation — Ukraine's largest, supporting
|
||||||
* TODO: Set the real donation URL (e.g. a Ko-fi / Open Collective / GitHub
|
* the people defending the country against Russia's invasion.
|
||||||
* Sponsors link) here. The href is intentionally "#" until that is decided so
|
|
||||||
* the modal renders correctly without causing any outbound navigation.
|
|
||||||
*/
|
*/
|
||||||
const DONATE_URL = '#'; // TODO: replace with real donation URL
|
const DONATE_URL = 'https://savelife.in.ua/en/donate-en/';
|
||||||
|
|
||||||
export function DonateModal() {
|
export function DonateModal() {
|
||||||
return (
|
return (
|
||||||
<div className={styles.donate}>
|
<div className={styles.donate}>
|
||||||
<p className={styles.body}>
|
<p className={styles.body}>
|
||||||
Astrolabe is free, open-source, and built in spare time. If it has saved you hours of
|
Astrolabe is free and open-source, built in spare time — there's nothing to buy and no one
|
||||||
context-switching or helped you ship a chart faster, consider supporting its development.
|
to pay.
|
||||||
|
</p>
|
||||||
|
<p className={styles.body}>
|
||||||
|
If it has saved you time and you'd like to give something back, please send it where it
|
||||||
|
matters far more than it would to me: Ukraine's defense against Russia's invasion. The Come
|
||||||
|
Back Alive foundation supports the people defending the country.
|
||||||
</p>
|
</p>
|
||||||
<p className={styles.body}>Every contribution, however small, keeps the project alive.</p>
|
|
||||||
|
|
||||||
<div className={styles.actions}>
|
<div className={styles.actions}>
|
||||||
<a href={DONATE_URL} className={styles.primary} target="_blank" rel="noopener noreferrer">
|
<a href={DONATE_URL} className={styles.primary} target="_blank" rel="noopener noreferrer">
|
||||||
Support Astrolabe
|
Donate to Ukraine's defense
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user