Skip to content

Fix/mailing list#22

Merged
Aerilym merged 50 commits intomainfrom
fix/mailing_list
Mar 15, 2026
Merged

Fix/mailing list#22
Aerilym merged 50 commits intomainfrom
fix/mailing_list

Conversation

@Aerilym
Copy link
Copy Markdown
Collaborator

@Aerilym Aerilym commented Mar 15, 2026

No description provided.

Aerilym added 30 commits July 17, 2025 17:47
Aerilym and others added 20 commits November 7, 2025 16:02
…optimize pagination

Co-authored-by: Aerilym <5667907+Aerilym@users.noreply.github.com>
Co-authored-by: Aerilym <5667907+Aerilym@users.noreply.github.com>
Co-authored-by: Aerilym <5667907+Aerilym@users.noreply.github.com>
…t page size constant

Co-authored-by: Aerilym <5667907+Aerilym@users.noreply.github.com>
…ode clarity

Co-authored-by: Aerilym <5667907+Aerilym@users.noreply.github.com>
… revalidation)

Co-authored-by: Aerilym <5667907+Aerilym@users.noreply.github.com>
Co-authored-by: Aerilym <5667907+Aerilym@users.noreply.github.com>
…idation

Co-authored-by: Aerilym <5667907+Aerilym@users.noreply.github.com>
Co-authored-by: Aerilym <5667907+Aerilym@users.noreply.github.com>
Copilot AI review requested due to automatic review settings March 15, 2026 21:43
@Aerilym Aerilym merged commit c000534 into main Mar 15, 2026
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This is a large-scale modernization PR that upgrades the Session website from Next.js 11 to 15, React 17 to 19, migrates from Yarn to pnpm, replaces ESLint/Prettier with Biome, adds internationalization (i18n) via next-intl, migrates the mailing list API from Mailerlite to Brevo, consolidates font-face declarations, introduces a blog cache service, and refactors barrel exports to direct imports.

Changes:

  • Upgrades Next.js (11→15), React (17→19), and migrates tooling from Yarn/ESLint/Prettier to pnpm/Biome
  • Adds internationalization support via next-intl with locale-aware routing, translations, and structured data for SEO
  • Migrates the email subscription API from Mailerlite to Brevo, adds a blog caching layer, and implements tiered ISR revalidation based on content age

Reviewed changes

Copilot reviewed 139 out of 156 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
package.json Major dependency upgrades (Next.js 15, React 19), new deps (next-intl, radix-ui, biome), migrate to pnpm
pages/_app.tsx Wraps app in NextIntlClientProvider, adds getInitialProps for locale loading
pages/_document.tsx Adds RTL detection and dynamic lang/dir attributes
pages/api/email/[list].ts Migrates mailing list from Mailerlite to Brevo API
pages/api/sitemap.ts Adds localized URLs, hreflang, structured change frequencies and priorities
services/redirect.ts Replaces getConfig() with direct import, uses top-level await
services/cache.ts New in-memory blog cache with TTL and cleanup
constants/cms.ts Tiered revalidation (1h for new, 24h for old content)
constants/navigation.ts Converts nav items to use locale keys instead of hardcoded strings
styles/globals.css Consolidates 18+ @font-face declarations into 6 using variable font ranges
components/ui/Layout.tsx New Layout component with locale key support
components/navigation/Nav.tsx New Nav with locale switcher dialog and i18n
components/sections/*.tsx Refactored from index dirs to flat files with i18n
biome.json New Biome configuration replacing ESLint/Prettier
tsconfig.json Target changed to ESNext, incremental builds enabled
.nvmrc, .tool-versions Node.js version updated to 24.4.1
Various components Migrated to next/legacy/image, direct imports, type-only imports
Comments suppressed due to low confidence (2)

components/CustomQRCode.tsx:69

  • The onKeyDown handler calls handleOnClick() on every key press without filtering for specific keys (like Enter or Space). This means typing, navigating, or pressing Escape will all trigger the QR code download. The handler should check for event.key === 'Enter' || event.key === ' ' before calling the action.
    components/ui/Button.tsx:77
  • The Button component now renders as a self-closing <button /> with no children prop in its type definition (removed from old Props interface). However, children is still passed via {...rest} since HTMLAttributes<HTMLButtonElement> includes children. This works, but callers that previously relied on children?: string can now pass any ReactNode as children. This is fine functionally, but the button renders as <button ... /> (self-closing JSX) which still renders children from rest. This is correct behavior in React but could be confusing to maintainers — consider explicitly showing {children} or {rest.children} in the JSX for clarity.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread pages/api/email/[list].ts
'X-Version': '2025-02-11',
'Content-Type': 'application/json',
Authorization: `Bearer ${ml_ApiKey}`,
'api-key': brevo_ApiKey!,
Comment thread services/redirect.ts
return redirection;
}

const redirects: IRedirection[] = await config.redirects();
Comment thread pages/api/sitemap.ts

const LOCALIZED_PAGES = ['', 'download', 'blog', 'community'];

const redirects: IRedirection[] = await config.redirects();
Comment thread utils/rss.ts
});

rimraf.sync(`./public/rss`);
rimraf?.sync(`./public/rss`);
Comment thread pages/_app.tsx
Comment on lines +32 to +56
MyApp.getInitialProps = async (appContext: AppContext) => {
// Call page's getInitialProps if it exists
const appProps = await App.getInitialProps(appContext);

const locale = appContext.ctx.locale || 'en';

if (!appProps.pageProps.messages) {
try {
const messages = (await import(`../locales/${locale}.json`)).default;
appProps.pageProps.messages = messages;
} catch (error) {
console.error(`Failed to load messages for locale: ${locale}`, error);

try {
const messages = (await import(`../locales/en.json`)).default;
appProps.pageProps.messages = messages;
} catch (fallbackError) {
console.error('Failed to load fallback messages', fallbackError);
appProps.pageProps.messages = {};
}
}
}

return appProps;
};
@Aerilym Aerilym mentioned this pull request Mar 15, 2026
@Aerilym Aerilym deleted the fix/mailing_list branch March 15, 2026 22:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants