Skip to content

Commit ca203f1

Browse files
JoblersTunebosbaberstrapiJonathanMattheyAnca2022
authored
feat: improve astro–strapi integration, mdx sync pipeline, and CI workflows (#133)
* docs: trivial change to readme * chore: trivial experimental change * ci: CMS changes to merge will now cause strapi rebuild (#47) * ci: trivial change to trigger cms build (#48) * ci: better reloadign of bashrc (#49) * ci: changed pipeline structure (#50) * ci: merged ci scripts and triggered rebuild (#51) * ci: use pnpm to run sync script (#52) * ci: trivial changes to test (#53) * ci: trigger another test (#54) * ci: trigger another test (#55) * fix: merge detection issue (#56) * ci: pipeline test (#57) * fix: add packages field to cms workspace yaml (#58) * test: workflow changes (#59) * chore: update pnpm lockfile * chore: revert test changes * fix: add packages field to cms pnpm-workspace.yaml * test: workflow changes * fix: should be able to do mdx sync on staging as well (#60) * chore: update pnpm lockfile * chore: revert test changes * fix: add packages field to cms pnpm-workspace.yaml * test: workflow changes * fix: allow sync-mdx to run from staging branch * test: trigger sync-mdx job * ci: test mdx change (#61) * chore: update pnpm lockfile * chore: revert test changes * fix: add packages field to cms pnpm-workspace.yaml * test: workflow changes * fix: allow sync-mdx to run from staging branch * test: trigger sync-mdx job * ci: test mdx change * fix: improve pr detection (#62) * chore: update pnpm lockfile * chore: revert test changes * fix: add packages field to cms pnpm-workspace.yaml * test: workflow changes * fix: allow sync-mdx to run from staging branch * test: trigger sync-mdx job * ci: test mdx change * fix: improve PR detection to prioritize API check * ci: tweak to test * ci: trigger (#63) * chore: update pnpm lockfile * chore: revert test changes * fix: add packages field to cms pnpm-workspace.yaml * test: workflow changes * fix: allow sync-mdx to run from staging branch * test: trigger sync-mdx job * ci: test mdx change * fix: improve PR detection to prioritize API check * ci: tweak to test * ci: trigger * fix: restrict manual workflow dispatch to staging branch only (#64) * ci: removed NODE_VERSION override for netlify (#65) * ci: staging preview build (#66) * ci: removed NODE_VERSION override for netlify * fix: convining netlify to stay in its lane * ci: added staging server to vite (#68) * ci: removed NODE_VERSION override for netlify * fix: convining netlify to stay in its lane * vite server allows * ci: netlify config for previews (#69) * ci: removed NODE_VERSION override for netlify * fix: convining netlify to stay in its lane * vite server allows * ci: deploy branches * ci: fixed issue with deploy previews (#70) * ci: removed NODE_VERSION override for netlify * fix: convining netlify to stay in its lane * vite server allows * ci: deploy branches * fix: remove dev * fix: use frozen lock file * ci: vite config issue * ci: pnpm should filter for website only (#71) * ci: removed NODE_VERSION override for netlify * fix: convining netlify to stay in its lane * vite server allows * ci: deploy branches * fix: remove dev * fix: use frozen lock file * ci: vite config issue * ci: pnpm should filter for website only * fix: preview for dev (#72) * ci: removed NODE_VERSION override for netlify * fix: convining netlify to stay in its lane * vite server allows * ci: deploy branches * fix: remove dev * fix: use frozen lock file * ci: vite config issue * ci: pnpm should filter for website only * ci: tweaks * merge * fix: ci typo double build (#73) * ci: removed NODE_VERSION override for netlify * fix: convining netlify to stay in its lane * vite server allows * ci: deploy branches * fix: remove dev * fix: use frozen lock file * ci: vite config issue * ci: pnpm should filter for website only * ci: tweaks * merge * fix: typo * ci: preview build debugging (#74) * ci: removed NODE_VERSION override for netlify * fix: convining netlify to stay in its lane * vite server allows * ci: deploy branches * fix: remove dev * fix: use frozen lock file * ci: vite config issue * ci: pnpm should filter for website only * ci: tweaks * merge * fix: typo * different dev * ci: cleanup (#75) * ci: removed NODE_VERSION override for netlify * fix: convining netlify to stay in its lane * vite server allows * ci: deploy branches * fix: remove dev * fix: use frozen lock file * ci: vite config issue * ci: pnpm should filter for website only * ci: tweaks * merge * fix: typo * different dev * cleanup * test: trivial change to trigger pipeline (#76) * test: added trivial change to blog (#77) * test: trivial change to trigger pipeline * test: added trivial change to blog * fix: corrected the linting issue caused during testing (#78) * chore: remove unused bun files (#67) * test(sync-mdx): add sync-mdx test coverage jon/intorg-399 (#41) * test(cms): add sync-mdx tests * fix(cms): resolve ESLint errors in sync-mdx tests Replace require() imports with ES module imports and use @ts-expect-error instead of `as any` for intentional type errors in tests. * update pnpm lock * test(cms): improve mock schema and add optional fields test Update siteSchemas mock to use async import with a realistic schema including sections and CTAs. Add test case covering optional frontmatter fields (description, heroImage, sections). * test(cms): add sync-mdx test utilities * feat: add new collection types jon/intorg-284 (#36) * refactor: standardize content types and layout hierarchy Content type naming: - Rename blog-post API to foundation-blog-post - Move src/content/blog/ to src/content/foundation-blog-posts/ - Move src/content/summit/ to src/content/summit-pages/ - Move src/content/developers/blog/ to src/content/developers-blog-posts/ Layout hierarchy: - BaseLayout: HTML shell with slots for header/footer - FoundationPageLayout: extends BaseLayout with Foundation nav - SummitPageLayout: extends BaseLayout with Summit nav and dark theme - DevelopersBlogLayout/FoundationBlogLayout: extend FoundationPageLayout Removes duplicate layouts (SummitLayout) * feat(sync-mdx): add foundation-blog-posts import and improve schema - jm/sync-mdx-foundationblog (#79) * refactor: standardize content types and layout hierarchy Content type naming: - Rename blog-post API to foundation-blog-post - Move src/content/blog/ to src/content/foundation-blog-posts/ - Move src/content/summit/ to src/content/summit-pages/ - Move src/content/developers/blog/ to src/content/developers-blog-posts/ Layout hierarchy: - BaseLayout: HTML shell with slots for header/footer - FoundationPageLayout: extends BaseLayout with Foundation nav - SummitPageLayout: extends BaseLayout with Summit nav and dark theme - DevelopersBlogLayout/FoundationBlogLayout: extend FoundationPageLayout Removes duplicate layouts (SummitLayout, LanderLayout) and hackathon-2023 page. * feat: add engineering blog collection and schema * feat: add prerender flag to blog page routes * stub out developer preview - not avail on strapi * fix(ci): update content-change detection to match synced paths * fix(pages): restore hackathon 2023 page * Update src/schemas/content.ts Co-authored-by: Anca Matei <98110730+Anca2022@users.noreply.github.com> * refactor: engineering-blog should be developers blog * restore lander header for hackathon 2023 * fix(lander): restore header and layout * add ogImageUrl to og-summit.png * fix(pages): update rendering * format * download og summit img in public folder * feat(sync-mdx): add foundation-blog-posts import and improve schema - Add foundation-blog-posts to config, validation, and mdxTransformer - Extend foundationBlogFrontmatterSchema: z.coerce.date(), authors, tags default, localizes/locale - MDX as single source of truth for content (no preserve-existing fallback) - Scan supports .md files in addition to .mdx Co-authored-by: Cursor <cursoragent@cursor.com> * feat(sync-mdx): add --force flag to bypass branch check Co-authored-by: Cursor <cursoragent@cursor.com> * Update cms/scripts/sync-mdx/index.ts Co-authored-by: Anca Matei <98110730+Anca2022@users.noreply.github.com> --------- Co-authored-by: Anca Matei <98110730+Anca2022@users.noreply.github.com> Co-authored-by: Cursor <cursoragent@cursor.com> * chore: rename frontmatter variable "lang" to "locale" (#82) rename frontmatter variable "lang" to "locale" * chore: Strapi Foundation blog post fields / frontmatter (#80) * update Strapi fields for Foundation blog post * update schema for foundationBlogFrontmatterSchema * set user friendly labels for Strapi Foundation Blog Post fields * docs: update README (#46) * feat(seo): add shared SeoHead and crawl controls. jm/SEO-Baseline-Handling (#86) Key changes: - Added sitemap generation and excluded /blog/preview from sitemap entries. - Updated crawl controls: robots.txt allows normal crawling but disallows /blog/preview. - Centralized metadata in shared SeoHead usage and improved tags - Added structured data improvements: site-level Organization and WebSite JSON-LD - Added canonical handling for paginated blog listing pages. * feat: strapi and astro Ambassador components and page previews (#8) * ambassador: add "Erica Hargreave" * ambassador: unpublish "Erica Hargreave" * ambassador: add "Erica Hargreave" * cohort: add "Ambassadors 2025" * cohort: delete "Ambassadors 2025" * cohort: add "Ambassadors 2025" * ambassador: add "Caroline Sinders" * cohort: delete "Ambassadors 2025" * cohort: add "Ambassadors 2024" * cohort: delete "Ambassadors 2024" * cohort: add "Ambassadors 2025" * page: add "test-ambassadors" (en) * page: unpublish "test-ambassadors" (en) * page: add "test-ambassadors" (en) * page: unpublish "test-ambassadors" (en) * page: add "test-ambassadors" (en) * page: unpublish "test-ambassadors" (en) * page: add "test-ambassadors" (en) * page: delete "test-ambassadors" (en) * wip: ambassador and associated content * cohort: add "alumni" * page: add "ambassadors" (en) * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * remove cohort * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * page: add "test-ambs" (en) * page: delete "test-ambs" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * ambassador: unpublish "Erica Hargreave" * ambassador: add "Erica Hargreave" * ambassador: unpublish "Erica Hargreave" * ambassador: add "Erica Hargreave" * setup lifecycle and page to serialise and render ambassador * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * use ordering from strapi instead of sorting * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * fix page previews * fix linter error * lint and format * format & lint * ambassador: add "Jeremiah Lee" * ambassador: add "Kokayi Issa" * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: delete "test-page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * update readme with preview setup * remove @astrojs/tailwind, fixes npm i * Component - blockquote (#11) Add BlockQuote as a component * ambassador: add "Caroline Sinders" * page: unpublish "test page" (en) * page: add "test page" (en) * ambassador: unpublish "Caroline Sinders" * ambassador: add "Caroline Sinders" * DRY the code * error handling in ambassador lifecycle * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * remove order from ambassador colection * make photo mandatory for ambassador * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * update readme, copy paths utils from main * ambassador: add "test ambassador" * ambassador: add "test ambassador 3" * ambassador: unpublish "test ambassador 3" * ambassador: add "test ambassador 3" * ambassador: delete "test ambassador 3" * ambassador: add "test mdx 4" * switch to mdx for ambassadors and add import functionality * ambassador: delete "Kokayi Issa" * remove test data * aria fixes * cleanup * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * refactor * cleanup * ambassador: add "Stephanie Perrin" * page: unpublish "test page" (en) * page: add "test page" (en) * cleanup * ambassador: add "Stephanie Perrin2" * page: unpublish "test page" (en) * page: add "test page" (en) * make heading jsx prop for ambassador grid * page: add "About Us" (en) * page: add "Grant for web" (en) * page: add "Internet of Oppor­tunity" (en) * page: add "Interledger 2026" (en) * page: add "new page" (en) * page: add "policy-and-advocacy" (en) * update readme with future notes * Post-merge: add ambassador/blockquote serializers + update @/ imports - Create cms/src/serializers/blocks/ambassador.serializer.ts - Create cms/src/serializers/blocks/ambassadors-grid.serializer.ts - Create cms/src/serializers/blocks/blockquote.serializer.ts - Register all three in cms/src/serializers/blocks/index.ts - Update relative imports to @/ alias in ambassador/blockquote components and page-preview.astro (AmbassadorGrid, AmbassadorBlock, AmbassadorsGridBlock, BlockquoteBlock, Blockquote, page-preview) * paths and autogenerated types * lockfiles * fix: lint — prettier format + eslint no-console in DynamicZone * ambassador sync script with locale * --force flag to allow sync from non main branches * update readme, fix component inclusion in pages * fix blockquote output * format * ci: use Node 20 and frozen lockfile in lint workflow - Upgrade from EOL Node 18 to Node 20 to match local dev environment and avoid subtle runtime differences in Prettier's MDX formatting - Switch to --frozen-lockfile to prevent pnpm from re-resolving dependencies on Linux, which could hoist the transitive prettier@3.3.3 (from cms workspace) over the pinned root prettier@3.8.1 * fix: pin prettier@3.8.1 in cms workspace and fix pnpm override format The cms workspace's lockfile had prettier@3.3.3 as a transitive dependency (via prettier-plugin-packagejson). On Linux, pnpm can hoist this into root node_modules/.bin, overriding the root workspace's prettier@3.8.1 and causing the lint CI to fail with formatting errors on MDX files that pass locally. - Add pnpm.overrides.prettier = "3.8.1" to cms/package.json so the cms lockfile no longer resolves prettier@3.3.3 - Convert the pre-existing esbuild override from npm-style "overrides" to pnpm-style "pnpm.overrides" so it's actually applied by pnpm - Regenerate cms/pnpm-lock.yaml with prettier@3.8.1 throughout * fix: add root pnpm override to eliminate prettier@3.3.3 from lockfile The root pnpm-lock.yaml manages cms workspace deps including prettier-plugin-packagejson which pulls in prettier@3.3.3 as a transitive peer dep. With pnpm hoisting, this can put prettier@3.3.3 in root node_modules/.bin on Linux, shadowing the intended @3.8.1 and causing the lint CI to fail. Adding "pnpm.overrides.prettier = 3.8.1" in root package.json forces the root lockfile to resolve all prettier references to 3.8.1, eliminating the conflicting version entirely. The root devDependency alone does not prevent prettier@3.3.3 from appearing in the lockfile — the override is required for that. * remove bun lockfiles * ci: add debug step to show exact prettier diff on Linux * cleanup * fix locale lifecycle * format * refactor * format, remove compiled file * fix tsconfig * fix previews and quote rendering * format * format * review * fix(scripts/README): update content type mappings to current dirs * Update src/components/ambassadors/AmbassadorGrid.astro Co-authored-by: Sarah Jones <sarah@interledger.org> * rename client url to astro preview url * fix cms types * update preview prefix * fix sync throwing error even on successful deletion of ambassador after sync * remove redundant checks * remove dead code * cleanup * format --------- Co-authored-by: Sarah Jones <sarah@interledger.org> * chore: Foundation articles id pages (#85) This PR matches the styles and structure of the Foundation article ID pages in v5 with the current prod website: - pillars for accent-color and feature-gradient: header, links, quotes - creates the ArticleBio and ArticleTags components in Astro - separates CommunityLinks component into CommunityLinksDevelopers and CommunityLinksFoundation - adds article bio content (image + text - in frontmatter) to Foundation blog articles that have a bio on production website * fix: update tests (#81) * ambassador: add "Erica Hargreave" * ambassador: unpublish "Erica Hargreave" * ambassador: add "Erica Hargreave" * cohort: add "Ambassadors 2025" * cohort: delete "Ambassadors 2025" * cohort: add "Ambassadors 2025" * ambassador: add "Caroline Sinders" * cohort: delete "Ambassadors 2025" * cohort: add "Ambassadors 2024" * cohort: delete "Ambassadors 2024" * cohort: add "Ambassadors 2025" * page: add "test-ambassadors" (en) * page: unpublish "test-ambassadors" (en) * page: add "test-ambassadors" (en) * page: unpublish "test-ambassadors" (en) * page: add "test-ambassadors" (en) * page: unpublish "test-ambassadors" (en) * page: add "test-ambassadors" (en) * page: delete "test-ambassadors" (en) * wip: ambassador and associated content * cohort: add "alumni" * page: add "ambassadors" (en) * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * remove cohort * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * page: add "test-ambs" (en) * page: delete "test-ambs" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * ambassador: unpublish "Erica Hargreave" * ambassador: add "Erica Hargreave" * ambassador: unpublish "Erica Hargreave" * ambassador: add "Erica Hargreave" * setup lifecycle and page to serialise and render ambassador * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * use ordering from strapi instead of sorting * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * fix page previews * fix linter error * lint and format * format & lint * ambassador: add "Jeremiah Lee" * ambassador: add "Kokayi Issa" * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: delete "test-page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * update readme with preview setup * remove @astrojs/tailwind, fixes npm i * Component - blockquote (#11) Add BlockQuote as a component * ambassador: add "Caroline Sinders" * page: unpublish "test page" (en) * page: add "test page" (en) * ambassador: unpublish "Caroline Sinders" * ambassador: add "Caroline Sinders" * DRY the code * error handling in ambassador lifecycle * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * remove order from ambassador colection * make photo mandatory for ambassador * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * update readme, copy paths utils from main * ambassador: add "test ambassador" * ambassador: add "test ambassador 3" * ambassador: unpublish "test ambassador 3" * ambassador: add "test ambassador 3" * ambassador: delete "test ambassador 3" * ambassador: add "test mdx 4" * switch to mdx for ambassadors and add import functionality * ambassador: delete "Kokayi Issa" * remove test data * aria fixes * cleanup * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * refactor * cleanup * ambassador: add "Stephanie Perrin" * page: unpublish "test page" (en) * page: add "test page" (en) * cleanup * ambassador: add "Stephanie Perrin2" * page: unpublish "test page" (en) * page: add "test page" (en) * make heading jsx prop for ambassador grid * page: add "About Us" (en) * page: add "Grant for web" (en) * page: add "Internet of Oppor­tunity" (en) * page: add "Interledger 2026" (en) * page: add "new page" (en) * page: add "policy-and-advocacy" (en) * update readme with future notes * Post-merge: add ambassador/blockquote serializers + update @/ imports - Create cms/src/serializers/blocks/ambassador.serializer.ts - Create cms/src/serializers/blocks/ambassadors-grid.serializer.ts - Create cms/src/serializers/blocks/blockquote.serializer.ts - Register all three in cms/src/serializers/blocks/index.ts - Update relative imports to @/ alias in ambassador/blockquote components and page-preview.astro (AmbassadorGrid, AmbassadorBlock, AmbassadorsGridBlock, BlockquoteBlock, Blockquote, page-preview) * paths and autogenerated types * lockfiles * fix: lint — prettier format + eslint no-console in DynamicZone * ambassador sync script with locale * --force flag to allow sync from non main branches * update readme, fix component inclusion in pages * fix blockquote output * format * ci: use Node 20 and frozen lockfile in lint workflow - Upgrade from EOL Node 18 to Node 20 to match local dev environment and avoid subtle runtime differences in Prettier's MDX formatting - Switch to --frozen-lockfile to prevent pnpm from re-resolving dependencies on Linux, which could hoist the transitive prettier@3.3.3 (from cms workspace) over the pinned root prettier@3.8.1 * fix: pin prettier@3.8.1 in cms workspace and fix pnpm override format The cms workspace's lockfile had prettier@3.3.3 as a transitive dependency (via prettier-plugin-packagejson). On Linux, pnpm can hoist this into root node_modules/.bin, overriding the root workspace's prettier@3.8.1 and causing the lint CI to fail with formatting errors on MDX files that pass locally. - Add pnpm.overrides.prettier = "3.8.1" to cms/package.json so the cms lockfile no longer resolves prettier@3.3.3 - Convert the pre-existing esbuild override from npm-style "overrides" to pnpm-style "pnpm.overrides" so it's actually applied by pnpm - Regenerate cms/pnpm-lock.yaml with prettier@3.8.1 throughout * fix: add root pnpm override to eliminate prettier@3.3.3 from lockfile The root pnpm-lock.yaml manages cms workspace deps including prettier-plugin-packagejson which pulls in prettier@3.3.3 as a transitive peer dep. With pnpm hoisting, this can put prettier@3.3.3 in root node_modules/.bin on Linux, shadowing the intended @3.8.1 and causing the lint CI to fail. Adding "pnpm.overrides.prettier = 3.8.1" in root package.json forces the root lockfile to resolve all prettier references to 3.8.1, eliminating the conflicting version entirely. The root devDependency alone does not prevent prettier@3.3.3 from appearing in the lockfile — the override is required for that. * remove bun lockfiles * ci: add debug step to show exact prettier diff on Linux * cleanup * fix locale lifecycle * format * refactor * format, remove compiled file * fix tsconfig * fix previews and quote rendering * format * format * review * fix(scripts/README): update content type mappings to current dirs * fix tests * format * feat: Callout Text component (#17) * ambassador: add "Erica Hargreave" * ambassador: unpublish "Erica Hargreave" * ambassador: add "Erica Hargreave" * cohort: add "Ambassadors 2025" * cohort: delete "Ambassadors 2025" * cohort: add "Ambassadors 2025" * ambassador: add "Caroline Sinders" * cohort: delete "Ambassadors 2025" * cohort: add "Ambassadors 2024" * cohort: delete "Ambassadors 2024" * cohort: add "Ambassadors 2025" * page: add "test-ambassadors" (en) * page: unpublish "test-ambassadors" (en) * page: add "test-ambassadors" (en) * page: unpublish "test-ambassadors" (en) * page: add "test-ambassadors" (en) * page: unpublish "test-ambassadors" (en) * page: add "test-ambassadors" (en) * page: delete "test-ambassadors" (en) * wip: ambassador and associated content * cohort: add "alumni" * page: add "ambassadors" (en) * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * remove cohort * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * page: unpublish "ambassadors" (en) * page: add "ambassadors" (en) * page: add "test-ambs" (en) * page: delete "test-ambs" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * ambassador: unpublish "Erica Hargreave" * ambassador: add "Erica Hargreave" * ambassador: unpublish "Erica Hargreave" * ambassador: add "Erica Hargreave" * setup lifecycle and page to serialise and render ambassador * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * use ordering from strapi instead of sorting * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * fix page previews * fix linter error * lint and format * format & lint * ambassador: add "Jeremiah Lee" * ambassador: add "Kokayi Issa" * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: unpublish "test-page" (en) * page: add "test-page" (en) * page: delete "test-page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * update readme with preview setup * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * wip: blockquote * update readme * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * use non-rich text for quote src, styling fixes * wip: callout text * page: unpublish "test page" (en) * page: add "test page" (en) * page: unpublish "test page" (en) * page: add "test page" (en) * remove @astrojs/tailwind, fixes npm i * Component - blockquote (#11) Add BlockQuote as a component * fix paths * remove unused page * cleanup * cleanup * chore(foundation-blog): add Strapi lifecycle file to create / update / delete mdx in Astro (#94) * foundation blog lifecycle base * type BlogEvent * export article as mdx file * refactor: group author bio data into articleBios object[] and update MDX frontmatter accordingly * handle updating / deleting blog posts * escape single quotes in frontematter values * tweaks * format * update REDME * remove async from createBlogLifecycle to export plain lifecycle object * add additional .join('') * tweaks * feat: add MDX block parser foundation for JSX imports (#93) * mdx parser and jsx extraction setup * update lockfile * refactor(sync-mdx): remove redundant JSX flow element cast * refactor(sync-mdx): deduplicate parser error construction * chore(sync-mdx): import ambassadors before other content types * feat(sync-mdx): Ambassador + AmbassadorGrid E2E import pipeline (#95) * mdx parser and jsx extraction setup * update lockfile * import ambassador and grid * template and comments * chore(sync-mdx): import ambassadors before other content types * refactor(cms): simplify sync-mdx JSX attribute extraction * Revert "refactor(cms): simplify sync-mdx JSX attribute extraction" This reverts commit 9007139. * refactor(sync-mdx): remove redundant JSX flow element cast * update and link component template * format --------- Co-authored-by: Jonathan Matthey <mattheyj@gmail.com> * feat(ambassadors): localize schema and export all locales to MDX Jm/intorg 453 (#96) * feat(ambassadors): localize all schema fields, export all locales to MDX * refactor(cms): adopt shared flat locale MDX lifecycle * feat(sync-mdx): add Blockquote + CalloutText import pipeline (#99) * mdx parser and jsx extraction setup * update lockfile * import ambassador and grid * template and comments * chore(sync-mdx): import ambassadors before other content types * refactor(cms): simplify sync-mdx JSX attribute extraction * Revert "refactor(cms): simplify sync-mdx JSX attribute extraction" This reverts commit 9007139. * refactor(sync-mdx): remove redundant JSX flow element cast * update and link component template * format * add import pipeline for BlockQuote and Callout Text comps Also added fix for an edge case where if the component's opening and closing tags were on the same line they were not being parsed properly due to the node getting wrapped in a paragraph node * fix inline tag parsing in mdx files * lockfile * refactor * Revert "refactor" This reverts commit 406e20f. * feat(sync-mdx): translations pass — tests, serializer fixes, round-trips - Fix ambassador.serializer.ts: add showLinks prop, fix photoAlt source - Add locale context tests for blockquote, calloutText, ambassador handlers - Add locale integration tests for mdxTransformer - Add export serializer tests (ambassador, blockquote, callout-text) - Add round-trip tests (blockquote, calloutText) - Add test:serializers script to cms/package.json - Add translations-pass.md plan doc, update jsx-imports-implementation.md * format --------- Co-authored-by: Jonathan Matthey <mattheyj@gmail.com> * fix: types in serializer test file (#103) fix tests * chore: add llm rules jon/intorg-335 (#39) docs(rules): update cursor and claude guidance * fix(cms): update git sync lifecycles (#100) * refactor(git-sync): use git status inference and unified repo paths * fix 2 bugs - quotes and extra line * fix(git-sync): skip git sync when running sync:navigation script * ambassador export - single quotes * foundation-page: create page-for-ambassadors * pnpm format --------- Co-authored-by: Anca Matei <98110730+Anca2022@users.noreply.github.com> * chore: add TagFilter to blog view pages (#90) Add TagFilter to blog view pages (/blog and /developers/blog) * ci: slack notification to frontend team (#109) * ci: introduction of playground environment (#110) * ci: introduced workflow for staging * ci: introduced playground merge * fix(ci): remove stray page-for-ambassadors (#111) remove stray page-for-ambassadors * feat(sync-mdx): add Paragraph component handler for MDX import jm/intorg-457-paragraph-component (#102) * add Paragraph to mdx files * fix(cms): delete orphaned localizations before recreating to preserve document links * fix(cms): use js-yaml v4 custom engine for single-quoted YAML frontmatter * feat(cms): add Paragraph block handler for sync-mdx parser * feat: render paragraph blocks as <Paragraph> JSX component * pnpm format * fix(sync-mdx): preserve dash bullet list marker on paragraph import * fix(sync-mdx): fix bullet lists handling in component handlers and add new tests (#108) * add Paragraph to mdx files * feat(cms): add Paragraph block handler for sync-mdx parser * pnpm format * fix bullet list handling, refactor * add and cleanup tests * format --------- Co-authored-by: Jonathan Matthey <mattheyj@gmail.com> * fix(ci): refresh cms lockfile for js-yaml (#113) * feat(404): add custom 404 page for static hosting jm/intorg-484-404page (#114) * feat(404): add custom 404 page for static hosting * pnpm format * refactor(utils): convert create-excerpt to TypeScript - jon/intorg-445 (#115) refactor(utils): convert create-excerpt to TypeScript * ci(lint): add build job to lint workflow jon/intorg-405 (#117) ci(lint): add build job to lint workflow * feat(seo): add per-page meta title, description, image, and canonical… jon/intorg-446 (#116) * feat(seo): add per-page meta title, description, image, and canonical URL * pnpm format * chore(cms): update Strapi dependencies [INTORG-334] (#112) * feat: tailwind setup (#104) * refactor: modular CSS architecture with Tailwind v4 theme tokens - Decompose monolithic tailwind.css and pages.css into focused, layer-aware files - Add src/styles/theme.css with @theme tokens (typography, spacing, colors, animations) - Add src/styles/base/ for reset, typography (@font-face), and runtime CSS variables - Add src/styles/components/ for prose variants (default, blog, foundation, summit) and navigation - Move design tokens out of tailwind.config.mjs into @theme (removes duplication) - Rename [data-category] to [data-pillar] theming system - Standardise variable namespaces: --step-* → --text-step-*, --space-* → --spacing-space-* - Scope Starlight docs variables to :where(.sl-container) to prevent global leakage - Replace inline Tailwind arbitrary-variant classes with data-prose, data-prose-summit, data-nav-links attributes - Delete src/styles/pages.css (content redistributed into new modular files) * fix: update remaining --space-* references to --spacing-space-* AmbassadorGrid, SummitHeader, and FoundationHeader were still using the old --space-s variable name which no longer exists after the CSS variable namespace rename. * cleanup * pillar * fix schema * cleanup * review * Address PR feedback and prepare for staging merge * revert mdxTransformer * Delete cms/scripts/sync-mdx/README.md * ci: any change to the cms folder should trigger a rebuild (#118) * chore: update Astro dependencies [INTORG-333] (#119) * chore(cms): update @strapi/strapi 5.31.3 → 5.38.0, remove dead overrides [INTORG-334] - Bump @strapi/strapi from 5.31.3 to 5.38.0 (latest stable) - Remove inert pnpm.overrides block from cms/package.json — pnpm ignores overrides in workspace packages; only root overrides apply - All three plugins (@_sh/strapi-plugin-ckeditor, @ckeditor/strapi-plugin-ckeditor, @notum-cz/strapi-plugin-record-locking) accept @strapi/strapi ^5.0.0 * foundation-page: sync (2 created) * ambassador: create caroline-sinders * fix(cms): bump @_sh/strapi-plugin-ckeditor to ^7.1.0 The v6 plugin bundles @strapi/design-system 2.0.0-rc.18 which conflicts with Strapi 5.38.0's design-system 2.2.0, causing a styled-components crash in the admin panel. v7.1.0 uses design-system 2.1.2 which is compatible. * foundation-page: update test-page * remove test-page fixtures from content * cleanup, auto generated types * lockfile * foundation-page: sync (2 created) * ambassador: create caroline-sinders * foundation-page: update test-page * chore: upgrade to Astro 6, Node 22, and bump dependencies INTORG-333 Upgrade the Astro site from v5 to v6 and move from Node 20 (lts/iron) to Node 22 (lts/jod). Remove unused @astrojs/node adapter. Bump all major dependencies: @astrojs/mdx 5, @astrojs/netlify 7, @astrojs/starlight 0.38, Tailwind 4.2, Zod 4, marked 17, and eslint/typescript-eslint tooling. Update CI workflows to Node 22. Build, lint, all tests, and visual QA pass with no apparent regressions. * cleanup * cleanup * chore(cms): upgrade Strapi to 5.39.0 * docs: document dual lockfile setup for root and cms * ci(lint): fix build job to use Node 22 (required by Astro 6) * chore: bump deps — starlight-links-validator, better-sqlite3, @types/node, vitest * chore: pin pnpm to v10.27.0 across repo and CI workflows (#120) * chore: pin pnpm to v10.27.0 across repo and CI workflows * fix(ci): remove explicit pnpm version from workflows — read from packageManager field * ci: better file change detection to trigger build (#121) * ci: will now use change api to detect changes * ci: make sure we use pnpm 10.27.0 * Update .github/workflows/staging-merge.yml Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Update .github/workflows/staging-merge.yml Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * ci: fixed reference issues --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * fix: align i18n routes and rename slug to pathSlug (#107) * fix: align i18n routes and rename slug to pathSlug * chore(deps): add better-sqlite3 to onlyBuiltDependencies and pin conflicting deps with overrides * ci: pipeline should source basrc for nvm to work (#126) * ci: explicit export of NVM_DIR (#127) * ci: clean node modules before rebuild (#128) * ci: force clean build (#129) * ci: playground merge pipeline cleanup fix (#130) * chore: store Sessionize data as JSON files (#131) * feat: add Netlify-backed contact form (#87) * feat(contact): add contact us page * pnpm format * chore: exclude preview pages from seo (#135) exclude preview from seo * feat(cms): cleanup strapi admin UI INTORG-481 (#106) * fix(cms): disable draft and publish on all content types * feat(cms): configure edit view layouts for ambassador and SEO * feat(cms): customize admin panel styles and navigation * pnpm format * feat(cms): improve admin field labels and edit view layouts * feat(cms): add labels and full-width layout for ambassador, blockquote, callout-text * fix(cms): always apply field labels, not only when Strapi default * fix page title too * update labels * hide preview button * feat(cms): add help text for Directory Structure field * fix - hide preview button * simplify hiding open entity * add mutable observable to doc * stricter ID check in title * refactor(404): reuse shared 404 page instead of inline not-found sect… (#137) * refactor(404): reuse shared 404 page instead of inline not-found sections Replace per-page inline 404 markup in [...page].astro and summit/[...page].astro with redirects to /404, and disable Starlight's built-in 404 route so the shared page is used consistently across the site. * pnpm format * chore: update buildBlogPayload to handle all fields in frontmatter (#105) This PR updates the `sync:mdx` script to handle all frontmatter fields in blog post articles: `tags`, `articleBio`, `featureImage` + alt text, `thumbnailImage` +alt text --------- Co-authored-by: Jonathan Matthey <mattheyj@gmail.com> * fix: remove unused value from interface definition (#139) * feat: PdfEmbed component (#132) * pdf embed * add download attribute * fallback styling * fix(lockfile): remove duplicate overrides keys from pnpm-lock.yaml Merge introduced duplicate @strapi/design-system and @strapi/icons keys in the overrides section, breaking frozen-lockfile installs. * Delete src/content/foundation-pages/test-page.mdx * Delete src/content/es/foundation-pages/test-page.mdx * format * revie and merge * format * fix(cms): target preview aside by nth-child instead of last-of-type (#142) :last-of-type was hiding the wrong aside after a Strapi UI update moved the publish panel. Switch to :nth-child(2) to reliably target only the preview aside. * fix(lockfile): update cms/pnpm-lock.yaml to include pnpm.overrides (#144) The @strapi/design-system and @strapi/icons overrides added to cms/package.json were missing from cms/pnpm-lock.yaml, causing ERR_PNPM_LOCKFILE_CONFIG_MISMATCH during the staging rebuild CI step. * feat: add localization support for foundation-blog-posts (#143) - add localization support for foundation-blog-posts - remove `language` field from Strapi Admin ui for Blog post (redundant, we already use locale)- - add back `afterUpdate` hooks in lifecycles (after switching off drafts for content, the lifecycles have changed they behaviour) * chore: Create list pages for Summit talks and speakers (#136) * chore: add base logic for summit talks list page * chore: add base HTML structure to summit talks page * chore: create Summit Speakers list page * add Spanish summit list pages * add comments * refactor list pages * style(summit): remove redundant .ts extensions from imports * apply changes as per review request --------- Co-authored-by: Jonathan Matthey <mattheyj@gmail.com> * ci: trigger sync on navigation changes and run sync:all jm/intorg-493-syncall (#138) * ci: trigger sync on navigation changes and run sync:all Navigation changes now trigger the sync job, same as MDX content. Switched to sync:all to run both syncs together, and renamed the job to match. * ci: set navigation_changed in all fallback sync paths * feat: added locale awareness to content collections (#134) --------- Co-authored-by: Stephan Butler <stephan@interledger.foundation> Co-authored-by: strapi <strapi@vm> Co-authored-by: Jonathan Matthey <mattheyj@gmail.com> Co-authored-by: Anca Matei <98110730+Anca2022@users.noreply.github.com> Co-authored-by: Cursor <cursoragent@cursor.com> Co-authored-by: Ravi Soni <soni.ravi829@gmail.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
1 parent 865eea0 commit ca203f1

530 files changed

Lines changed: 52945 additions & 10022 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.

.cursorrules

Lines changed: 103 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,103 @@
1+
# Developer Practices
2+
3+
## Project
4+
5+
- Stack: Astro, Tailwind, Strapi, TypeScript
6+
- Mobile-first design
7+
- Strapi is a headless data layer only. All presentation logic lives in Astro.
8+
- Astro is the source of truth for content structure, routing, and rendering
9+
10+
## Astro Conventions
11+
12+
- Use content collections and `getStaticPaths` for any route-driven content
13+
- Shared types live in `src/types/`, utilities in `src/utils/`, layouts in `src/layouts/`
14+
- Prefer static output (`output: 'static'`) unless a page explicitly needs SSR
15+
16+
## Code Style
17+
18+
- Optimize for the next reader. Clarity over cleverness.
19+
- Name things well — good names reduce the need for comments
20+
- Keep functions small and focused. If a function can't be described in one sentence, it's doing too much.
21+
- Logic functions over 50 lines are likely doing too much — suggest splitting. Astro component markup is exempt, but frontmatter should stay lean.
22+
- Prefer early returns over deep nesting
23+
- No magic numbers in logic — use named constants. Tailwind classes and markup content are fine inline.
24+
- Extract repeated logic into well-named utilities
25+
- Don't mix concerns (data fetching, transformation, rendering, side effects) in one function
26+
27+
## TypeScript
28+
29+
- Use strict typing everywhere
30+
- Prefer compile-time errors over runtime errors
31+
- Define shared interfaces in `src/types/` — don't redeclare shapes across files
32+
- Type API responses from Strapi explicitly; don't trust `any`
33+
34+
## Styling
35+
36+
- Use Tailwind utility classes
37+
- Prefer shared components and design tokens over one-off styles
38+
- If a style pattern appears three or more times, extract it into a component
39+
- Respect the existing design system before introducing new patterns
40+
41+
## Dependencies
42+
43+
- Before suggesting a new dependency, check if something already in the project solves it
44+
- Only suggest actively maintained, widely-used packages
45+
- Always suggest the latest stable version
46+
- Flag if a dependency seems unnecessary.
47+
48+
## Error Handling & Edge Cases
49+
50+
- Always consider edge cases and error states
51+
- Add error handling by default — don't leave happy-path-only code
52+
- Handle empty states, loading states, and API failures gracefully
53+
- Validate data at boundaries (API responses, user input, URL params)
54+
55+
## Testing
56+
57+
- Write tests for utility functions and data transformations
58+
- Test edge cases explicitly — empty arrays, null values, malformed input
59+
- If a bug is fixed, add a test that would have caught it
60+
61+
## Accessibility
62+
63+
- Accessibility is non-negotiable
64+
- Use semantic HTML
65+
- Ensure keyboard navigability and visible focus states
66+
- Add aria attributes only when semantic HTML isn't sufficient
67+
- Consider zoom, reduced motion preferences, and screen reader behavior
68+
- Interactive elements need accessible names and visible focus indicators
69+
70+
## Performance
71+
72+
- Watch bundle size — flag large imports
73+
- Prefer static output
74+
- Avoid unnecessary client-side JavaScript
75+
- Lazy-load images and heavy components
76+
- Optimize assets before committing
77+
- Prefer native HTML/CSS solutions over JS when possible
78+
79+
## Git
80+
81+
- Use Conventional Commits: `type(scope): description` (e.g., `feat(blog): add search filtering to index`, `fix(api): handle empty Strapi response`)
82+
- Types: `feat`, `fix`, `docs`, `style`, `refactor`, `perf`, `test`, `chore`, `ci`
83+
- Scope should match the area of the codebase affected
84+
- One logical change per commit
85+
- Branch naming: `type/short-description` (e.g., `feat/blog-search`, `fix/strapi-null-response`)
86+
- Branch from `main` (or `develop` if applicable) — keep branches short-lived
87+
- PR titles follow Conventional Commit format
88+
- Add linear ID in Git PR so it's linked
89+
- PR descriptions should explain _why_, not just _what_ — include context, decisions made, and anything reviewers should watch for
90+
91+
## When Asked to Generate Code
92+
93+
- Produce clean, readable, well-named, strongly typed code by default
94+
- Suggest splitting if a function is getting long
95+
- Flag any tradeoffs or edge cases in the implementation
96+
- If a new dependency is needed, explain why and confirm no existing alternative exists
97+
- Don't solve the local problem while breaking the global structure
98+
99+
## When Asked to Review Code
100+
101+
- Check for: edge cases, accessibility, performance, error handling, naming clarity, unnecessary complexity, mixed concerns, and missing types
102+
- Be direct. Say what's wrong and why. Suggest a fix.
103+
- Comments should be correct, necessary, and non-obvious. Flag any that just restate the code.

.env.example

Lines changed: 30 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,35 @@
1-
# Server (generate with: pnpm dlx tsx -e "console.log('APP_KEYS=' + ...)" etc. - see cms/README.md)
2-
APP_KEYS=...
3-
API_TOKEN_SALT=...
4-
ADMIN_JWT_SECRET=...
5-
TRANSFER_TOKEN_SALT=...
1+
# Strapi core secrets — generate these with the commands in QUICKSTART.md
2+
APP_KEYS=key1,key2,key3,key4
3+
API_TOKEN_SALT=your-api-token-salt
4+
ADMIN_JWT_SECRET=your-admin-jwt-secret
5+
TRANSFER_TOKEN_SALT=your-transfer-token-salt
6+
JWT_SECRET=your-jwt-secret
67

7-
# Strapi API
8+
# Strapi server
9+
HOST=0.0.0.0
10+
PORT=1337
11+
12+
# Database
13+
DATABASE_CLIENT=better-sqlite3
14+
DATABASE_FILENAME=.tmp/data.db
15+
16+
# Strapi API (used by Astro to fetch content)
817
STRAPI_URL=http://localhost:1337
918
STRAPI_API_TOKEN=your-api-token
1019

11-
# Optional: disable git sync during local development
20+
# Astro frontend URL (used by Strapi for preview iframe)
21+
ASTRO_PREVIEW_URL=http://localhost:1103
22+
23+
# CORS — space-separated list of allowed frontend origins
24+
# FRONTEND_ORIGINS=http://localhost:1103
25+
26+
# Media uploads
27+
# Only needed if uploads are hosted externally (CDN, S3, etc.).
28+
# When unset, upload URLs are kept as relative paths (/uploads/...).
29+
# STRAPI_UPLOADS_BASE_URL=https://cdn.example.com
30+
31+
# Git sync
32+
# Set to "true" to disable automatic git commit + push after content changes.
33+
# Useful in local development to avoid committing every published change.
1234
# STRAPI_DISABLE_GIT_SYNC=true
35+
# STRAPI_GIT_SYNC_REPO_PATH

.github/copilot-instructions.md

Lines changed: 20 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ Ensure these are installed before running any commands:
3131

3232
### CI Validation Pipeline
3333

34-
The GitHub Actions workflow (`.github/workflows/test-build.yml`) runs on every PR:
34+
The GitHub Actions workflow (`.github/workflows/lint.yml`) runs on every PR and push to main:
3535
1. Checkout code
3636
2. Setup Node.js (v18)
3737
3. Setup pnpm
@@ -41,6 +41,8 @@ The GitHub Actions workflow (`.github/workflows/test-build.yml`) runs on every P
4141

4242
**To replicate CI locally**: Run `pnpm install && pnpm run lint && pnpm run build`. Both lint and build must pass with no output errors.
4343

44+
**Note**: CI uses npm for installation despite Bun being the preferred local package manager. This is intentional for CI consistency.
45+
4446
### Important Caveats
4547

4648
- **Node Version**: The system may have multiple Node versions. If build fails with "Node.js vX.X.X is not supported by Astro", upgrade to >=18.20.8. The .nvmrc specifies `lts/iron` (Node 20), which is recommended.
@@ -54,11 +56,11 @@ The GitHub Actions workflow (`.github/workflows/test-build.yml`) runs on every P
5456
├── src/ # Main Astro site
5557
│ ├── pages/ # Route pages (catch-all in [...page].astro)
5658
│ ├── content/ # MDX content organized by section
57-
│ │ ├── blog/ # Blog posts (developers section)
58-
│ │ ├── developers/ # Developer documentation
59+
│ │ ├── foundation-blog-posts/ # Foundation blog posts (+ optional locale subdirs)
60+
│ │ ├── developers-blog-posts/ # Developer blog posts (+ optional locale subdirs)
5961
│ │ ├── docs/ # Specification documents
60-
│ │ ├── foundation-pages/ # Pages managed by Strapi CMS
61-
│ │ └── summit/ # Summit-specific content
62+
│ │ ├── foundation-pages/ # Pages managed by Strapi CMS (+ optional locale subdirs)
63+
│ │ └── summit-pages/ # Summit-specific content (+ optional locale subdirs)
6264
│ ├── layouts/ # Astro layout components
6365
│ ├── components/ # Reusable Astro components
6466
│ │ ├── blocks/ # Content blocks
@@ -98,7 +100,7 @@ The GitHub Actions workflow (`.github/workflows/test-build.yml`) runs on every P
98100

99101
## Content and Routing
100102

101-
- **Main navigation**: Configured in `src/config/navigation.json`
103+
- **Foundation navigation**: Configured in `src/config/foundation-navigation.json`
102104
- **Summit navigation**: Configured in `src/config/summit-navigation.json`
103105
- **Dynamic routing**: `src/pages/[...page].astro` handles catch-all routes
104106
- **Blog routing**: `src/pages/blog/[...page].astro` and `src/pages/developers/blog/[...page].astro` for dated blog content
@@ -109,6 +111,7 @@ The GitHub Actions workflow (`.github/workflows/test-build.yml`) runs on every P
109111
- **Branches**: `staging` is the preview environment, `main` is production.
110112
- **Strapi publishing**: Lifecycle hooks generate MDX and commit/push to `staging`.
111113
- **Netlify**: Auto-builds `staging` to preview and `main` to production.
114+
- **Self-hosted runner**: The `.github/workflows/staging-merge.yml` runs on push to `staging` via a self-hosted runner (`strapi-vm`). It automatically rebuilds Strapi CMS when `cms/` changes are detected, and syncs MDX to Strapi when `.md` or `.mdx` files change in `src/content/foundation-pages`, `src/content/summit-pages`, `src/content/foundation-blog-posts`, or `src/content/ambassadors`, including localized mirrors under `src/content/<locale>/...`.
112115
- **Promotion**: Content moves from `staging` to `main` via PR approval.
113116
- **Preview drafts**: Drafts can be previewed via SSR without publishing.
114117

@@ -126,7 +129,7 @@ The GitHub Actions workflow (`.github/workflows/test-build.yml`) runs on every P
126129

127130
1. **ESLint warnings in CMS**: The file `cms/src/api/page/content-types/page/lifecycles.ts` contains warnings about unused variables and `any` types. These exist in the repo and are pre-existing. They do not block the build but do prevent `pnpm run lint` from passing.
128131

129-
2. **Node version mismatch in CI**: The GitHub Actions workflow uses Node 18, but newer patch versions (>=18.20.8) are required. The workflow's `actions/setup-node@v3` should install a compatible patch version automatically.
132+
2. **Translation structure commented out**: `src/config` in astro.config.mjs has an i18n config block commented with TODO. Do not enable without understanding the full routing implications.
130133

131134
3. **Translation structure commented out**: `src/config` in astro.config.mjs has an i18n config block commented with TODO. Do not enable without understanding the full routing implications.
132135

@@ -136,17 +139,23 @@ The GitHub Actions workflow (`.github/workflows/test-build.yml`) runs on every P
136139

137140
The CMS (Strapi v5.31.3) runs independently and uses **pnpm**:
138141
```bash
142+
# Local development (uses npm)
139143
cd cms
140144
pnpm install
141145
pnpm run develop # Runs on localhost:1337/admin
142146
pnpm run build # Production build
143147
```
144148

145-
Content published in the CMS automatically generates MDX files in `src/content/foundation-pages/` via lifecycle hooks. MDX generation is handled by `cms/scripts/sync-mdx.cjs`.
149+
**Production builds** (self-hosted runner on `staging` push):
150+
- Uses `pnpm install && pnpm run build` via `.github/workflows/staging-merge.yml`
151+
- Includes `NODE_OPTIONS="--max-old-space-size=4096"` to handle OOM errors during build
152+
- Automatically restarts the `strapi.service` after rebuild
153+
154+
Content published in the CMS automatically generates MDX files in collection directories such as `src/content/foundation-pages/`, with localizations nested under the type directory (for example `src/content/foundation-pages/es/`). MDX generation is handled by `cms/scripts/sync-mdx/index.ts`.
146155

147-
For pages and blog posts, those lifecycle hooks also run a git add/commit/pull --rebase/push to trigger preview builds. Grant tracks only write/delete MDX locally. Set `STRAPI_DISABLE_GIT_SYNC=true` to disable the git sync.
156+
For pages and blog posts, lifecycle hooks may trigger git synchronization for preview builds. Set `STRAPI_DISABLE_GIT_SYNC=true` to disable the git sync.
148157

149-
CMS code changes are deployed to the Strapi VM when merged to `staging`. Content-only changes can be rebuilt into Strapi via `cms/scripts/sync-mdx.cjs`.
158+
CMS code changes are deployed to the Strapi VM when merged to `staging`. The self-hosted runner will automatically rebuild if `cms/` directory changes are detected.
150159

151160
## Making Changes
152161

@@ -158,7 +167,7 @@ When making changes to Astro components, pages, or styles:
158167
5. If format fails due to ESLint warnings, address warnings manually (check files listed in format output)
159168
6. Verify `pnpm run build` succeeds (no output errors)
160169

161-
For content changes (MDX files), they are hot-reloaded during dev. For navigation changes, edit `src/config/navigation.json` and verify the sidebar updates correctly.
170+
For content changes (MDX files), they are hot-reloaded during dev. For navigation changes, edit `src/config/foundation-navigation.json` or `src/config/summit-navigation.json` and verify the sidebar updates correctly.
162171

163172
## Files to Avoid Modifying
164173

@@ -167,7 +176,6 @@ These files are auto-generated or have special constraints and should not be man
167176
- `cms/src/index.ts` – Generated by Strapi plugin (in eslint ignore list)
168177
- `cms/src/admin/app.tsx` – Generated by Strapi (in eslint ignore list)
169178
- `public/scripts/highlight.min.js` – Minified third-party library
170-
- `src/pages/financial-services.astro` – In eslint ignore list (pre-existing issues)
171179
- `.astro/` directory – Build cache
172180

173181
## Trust These Instructions

.github/workflows/lint.yml

Lines changed: 21 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Lint
1+
name: Lint and Build
22

33
on:
44
pull_request:
@@ -8,19 +8,34 @@ on:
88
jobs:
99
lint:
1010
runs-on: ubuntu-latest
11-
11+
1212
steps:
1313
- uses: actions/checkout@v4
1414

1515
- uses: pnpm/action-setup@v4
16-
with:
17-
version: 10
1816

1917
- uses: actions/setup-node@v4
2018
with:
21-
node-version: 18
19+
node-version: 22
2220
cache: pnpm
2321

24-
- run: pnpm install --no-frozen-lockfile
22+
- run: pnpm install --frozen-lockfile
2523

2624
- run: pnpm run lint
25+
26+
build:
27+
runs-on: ubuntu-latest
28+
29+
steps:
30+
- uses: actions/checkout@v4
31+
32+
- uses: pnpm/action-setup@v4
33+
34+
- uses: actions/setup-node@v4
35+
with:
36+
node-version: 22
37+
cache: pnpm
38+
39+
- run: pnpm install --frozen-lockfile
40+
41+
- run: pnpm run build

.github/workflows/main-merge.yml

Lines changed: 0 additions & 68 deletions
This file was deleted.

0 commit comments

Comments
 (0)