Files
netris-nestri/apps/auth/src/theme.ts
T
Wanjohi 8326d88894 refactor(auth): make every issuer screen a value of its own
The issuer's screens were written inline in its route handlers, so the
only way to look at one was to reach the condition that produces it: an
expired cookie, a refused grant, ten wrong guesses. They now live in
ui/issuer.ts and the handlers call them, with no change to copy, status
or markup.

The app's theme moves to its own module for the same reason: it can be
used without importing the issuer and its database stores.
2026-10-02 05:27:27 +03:00

28 lines
1.3 KiB
TypeScript

import type { Theme } from '@nestri/auth/ui/theme';
/**
* The sign-in screen's theme.
*
* Almost everything that used to live here is now stated in
* `packages/auth/src/ui/css.ts`, which states the product's design language
* longhand. What is left here is the handful of values the
* issuer itself needs — and `primary`, which is the one colour the stylesheet
* reads back from the theme so the brand has a single source.
*
* There is no `background` and no light variant on purpose: the page is dark
* only, and the derived-colour scheme that made two schemes possible is
* exactly what rendered the sign-in field's text the colour of its own
* background.
*/
export const THEME_NESTRI: Theme = {
title: 'Login | Nestri',
primary: 'hsl(12 84% 53%)',
favicon: 'https://nestri.io/images/favicon.ico',
// Mona Sans for the display line and the action, Geist for everything a
// person reads or types. Served from the Fontsource CDN because the
// self-hosted font packages need a bundler and nothing preprocesses this
// page — it is assembled as a string at request time. The family names must
// match the ones the stylesheet asks for.
css: `@import url('https://cdn.jsdelivr.net/fontsource/css/mona-sans:vf@latest/wght.css');@import url('https://cdn.jsdelivr.net/fontsource/css/geist:vf@latest/wght.css');`
};