Skip to content

Commit b07bd73

Browse files
chore(website): hide Sponsors page and tiers until funding channels are ready (#112)
* chore(website): hide Sponsors page and tiers until funding channels are ready * test(website): gate support page visibility audit * fix(website): un-gate offline FAQ and hide remaining paid-support ads The previous change hid the offline FAQ instead of the financial-support item, so the visible page no longer matched the gated JSON-LD. Gate the GitHub Sponsors FAQ, privacy disclosure, README CTAs, and footer e2e assertion behind SHOW_SUPPORT_PROJECT, and keep the placeholder noindex. * fix(website): add types for SHOW_SUPPORT_PROJECT in e2e typecheck The e2e suite imports the JS feature flag, and tsc treated that module as implicit any. A sibling declaration unblocks website typecheck. * fix(website): derive FAQ e2e count from SHOW_SUPPORT_PROJECT The support FAQ no longer hardcodes 16 questions. Visible and JSON-LD counts follow the flag (15 + optional financial item), and the flag-true path still asserts that question is present. * fix(website): refresh visual baselines after hiding Support the project Replace the 24 full-page snapshots that still showed the gated footer link. Images are the ubuntu-latest Website E2E actuals from the failed fb96f7b run so they match the CI comparison environment. --------- Co-authored-by: Cursor Agent <cursoragent@cursor.com> Co-authored-by: Kevin Arthur <K-Arthur@users.noreply.github.com>
1 parent 9c9ec3d commit b07bd73

43 files changed

Lines changed: 120 additions & 27 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎README.md‎

Lines changed: 6 additions & 2 deletions

‎apps/website/scripts/audit-theme.mjs‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
* node scripts/audit-theme.mjs [--base http://localhost:4321/varve] [--route /docs]
1111
*/
1212
import { chromium } from 'playwright';
13+
import { SHOW_SUPPORT_PROJECT } from '../src/config/features.js';
1314

1415
const base =
1516
process.env.BASE ??
@@ -48,7 +49,7 @@ const routes = [
4849
'/support/known-issues',
4950
'/support/report-issue',
5051
'/support/troubleshooting',
51-
'/support-project',
52+
...(SHOW_SUPPORT_PROJECT ? ['/support-project'] : []),
5253
'/contribute',
5354
'/contribute/guidelines',
5455
'/learn',

‎apps/website/src/components/SiteFooter.astro‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
import DownloadCTA from './DownloadCTA.astro';
1414
import { CONTACTS } from '@varve/shared';
1515
import { sitePath } from '../lib/siteUrl';
16+
import { SHOW_SUPPORT_PROJECT } from '../config/features.js';
1617
import release from '../data/release-manifest.json';
1718
1819
const statusLabel = release.hasRelease && release.version
@@ -102,7 +103,7 @@ const statusLabel = release.hasRelease && release.version
102103
<h3>Project</h3>
103104
<ul>
104105
<li><a href={sitePath('/contribute')}>Contribute</a></li>
105-
<li><a href={sitePath('/support-project')}>Support the project</a></li>
106+
{SHOW_SUPPORT_PROJECT && <li><a href={sitePath('/support-project')}>Support the project</a></li>}
106107
<li><a href={sitePath('/about')}>About</a></li>
107108
<li><a href={sitePath('/about/how-its-built')}>How Varve is built</a></li>
108109
<li><a href={sitePath('/press')}>Press &amp; brand assets</a></li>
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
/** Website feature switches. */
2+
export const SHOW_SUPPORT_PROJECT: boolean;
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
/** Website feature switches. */
2+
export const SHOW_SUPPORT_PROJECT = false;

‎apps/website/src/pages/about.astro‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
import Button from '../components/Button.astro';
33
import Layout from '../layouts/Layout.astro';
44
import { sitePath } from '../lib/siteUrl';
5+
import { SHOW_SUPPORT_PROJECT } from '../config/features.js';
56
import { CONTACTS } from '@varve/shared';
67
---
78

@@ -53,13 +54,13 @@ import { CONTACTS } from '@varve/shared';
5354
<Button variant="secondary" href={sitePath('/about/license')}>Read the full license</Button>
5455
</section>
5556

56-
<section class="about-section">
57+
{SHOW_SUPPORT_PROJECT && <section class="about-section">
5758
<h2>Support the project</h2>
5859
<p>
5960
As an independently developed project, Varve relies on community support to continue development. Financial support enables platform support, stability work, and features that might otherwise be deferred. Non-financial contributions — testing, documentation, design, translations — are equally valuable.
6061
</p>
6162
<Button href={sitePath('/support-project')}>Support the Project</Button>
62-
</section>
63+
</section>}
6364

6465
<section class="about-section">
6566
<h2>Privacy policy</h2>

‎apps/website/src/pages/about/privacy.astro‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
import Button from '../../components/Button.astro';
33
import Layout from '../../layouts/Layout.astro';
44
import { sitePath } from '../../lib/siteUrl';
5+
import { SHOW_SUPPORT_PROJECT } from '../../config/features.js';
56
import { CONTACTS } from '@varve/shared';
67
---
78

@@ -107,7 +108,7 @@ import { CONTACTS } from '@varve/shared';
107108
</p>
108109
<ul>
109110
<li><strong>GitHub</strong> — for issue tracking, discussions, source code hosting, and release distribution. See <a href="https://docs.github.com/en/site-policy/privacy-policies" target="_blank" rel="noopener noreferrer">GitHub's Privacy Policy</a>.</li>
110-
<li><strong>GitHub Sponsors</strong> — for financial support. Transactions are processed through GitHub's platform. See <a href="https://docs.github.com/en/site-policy/privacy-policies" target="_blank" rel="noopener noreferrer">GitHub's Privacy Policy</a>.</li>
111+
{SHOW_SUPPORT_PROJECT && <li><strong>GitHub Sponsors</strong> — for financial support. Transactions are processed through GitHub's platform. See <a href="https://docs.github.com/en/site-policy/privacy-policies" target="_blank" rel="noopener noreferrer">GitHub's Privacy Policy</a>.</li>}
111112
</ul>
112113
<p>
113114
Optional website analytics use GoatCounter only after a fresh consent choice and deliberate

‎apps/website/src/pages/learn/community.astro‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
import Button from '../../components/Button.astro';
33
import Layout from '../../layouts/Layout.astro';
44
import { sitePath } from '../../lib/siteUrl';
5+
import { SHOW_SUPPORT_PROJECT } from '../../config/features.js';
56
---
67

78
<Layout title="Community" description="Connect with the Varve community through GitHub Discussions, issue reports, cross-platform testing, documentation, and workflow feedback.">
@@ -48,9 +49,9 @@ import { sitePath } from '../../lib/siteUrl';
4849

4950
<section class="community-section">
5051
<h2>Support</h2>
51-
<p>Support the project financially or through practical non-financial contributions:</p>
52+
<p>{SHOW_SUPPORT_PROJECT ? 'Support the project financially or through practical non-financial contributions:' : 'Support the project through practical contributions:'}</p>
5253
<ul>
53-
<li><a href={sitePath('/support-project')}>Financial Support</a> - GitHub Sponsors</li>
54+
{SHOW_SUPPORT_PROJECT && <li><a href={sitePath('/support-project')}>Financial Support</a> - GitHub Sponsors</li>}
5455
<li><a href={sitePath('/contribute')}>Non-Financial Contribution</a> - Bugs, testing, docs, workflows, and design feedback</li>
5556
</ul>
5657
</section>

‎apps/website/src/pages/sitemap.xml.ts‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import type { APIRoute } from 'astro';
2+
import { SHOW_SUPPORT_PROJECT } from '../config/features.js';
23
import { siteUrl } from '../lib/siteUrl';
34

45
/**
@@ -22,6 +23,7 @@ function toRoute(filePath: string): string | null {
2223
// 404 is not a destination; dynamic routes cannot be enumerated without
2324
// knowing their params, and we have none today.
2425
if (relative === '404') return null;
26+
if (relative === 'support-project' && !SHOW_SUPPORT_PROJECT) return null;
2527
// Legacy security URL is a redirect alias for the canonical /security page.
2628
if (relative === 'about/security') return null;
2729
// /releases is a noindex redirect alias for /changelog; a sitemap must not

‎apps/website/src/pages/support-project.astro‎

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,19 @@
22
import Button from '../components/Button.astro';
33
import Layout from '../layouts/Layout.astro';
44
import { sitePath } from '../lib/siteUrl';
5+
import { SHOW_SUPPORT_PROJECT } from '../config/features.js';
56
---
67

8+
{!SHOW_SUPPORT_PROJECT ? (
9+
<Layout title="Support the Project" description="This page isn't available yet." noindex>
10+
<div class="container-custom">
11+
<main class="support-project-page">
12+
<h1 class="site-page-title">Support the Project</h1>
13+
<p>This page isn't available yet.</p>
14+
</main>
15+
</div>
16+
</Layout>
17+
) : (
718
<Layout title="Support the Project" description="Varve is built by one developer. GitHub Sponsors funds platform work, stability, and new features; non-financial contributions are equally valuable.">
819
<div class="container-custom">
920
<div class="support-project-page">
@@ -131,6 +142,7 @@ import { sitePath } from '../lib/siteUrl';
131142
</div>
132143
</div>
133144
</Layout>
145+
)}
134146

135147
<style>
136148
.support-project-page {

0 commit comments

Comments
 (0)