Skip to content

FCE-2061: Premium docs look & feel via @swmansion/t-rex-ui#272

Open
roznawsk wants to merge 1 commit into
mainfrom
fce-2061
Open

FCE-2061: Premium docs look & feel via @swmansion/t-rex-ui#272
roznawsk wants to merge 1 commit into
mainfrom
fce-2061

Conversation

@roznawsk

Copy link
Copy Markdown
Member

What

Adopts Software Mansion's t-rex-ui Docusaurus theme (suggested in FCE-2061) for a premium look, rebranded to Fishjam — orange #dd6460 accents, warm near-black text, beige navbar/footer, DM Sans. Light-only is preserved.

Build is green (1146 pages, 0 SSG failures), tsc clean. Preview locally: yarn build && yarn serve → search/code/Scalar render on docs pages.

⚠️ Toolchain tradeoffs (please weigh in)

t-rex-ui 1.3.3 hard-constrains the stack, so this PR also:

  • Pins Docusaurus to 3.9.2 (down from 3.10) via resolutions — t-rex imports 3.9-only theme-common internals (useKeyboardNavigation, removed in 3.10). future.fasterfuture.experimental_faster. This is the main thing to sign off on.
  • Bumps React 18 → 19 — t-rex bundles a React 19 JSX runtime (React 18 crashes its SSR). Also aligns the repo, which already had @types/react@19 + react-native@0.80 (needs 19).

Other notable changes

  • Inline configureWebpack plugin transpiles t-rex's untranspiled JSX shipped under node_modules (Docusaurus's excludeJS skips node_modules).
  • Search: swapped @docsearch/docusaurus-adapter → classic Algolia (themeConfig.algolia, bundled in preset-classic) because t-rex's navbar search reads themeConfig.algolia and the adapter forbids that key. Ask-AI sidepanel keys moved to customFields.askAi (still rendered via @docsearch/react in Root).
  • Branding: t-rex's design tokens vendored in src/css/trex-theme.css; custom.css remaps t-rex's --swm-navy-*/--swm-purple-* base scales → Fishjam orange + warm neutrals, fixing the old flat primary scale.

Preserved

Shiki + Twoslash highlighting & the copy button, Scalar REST (/api/rest), the /search page, Ask-AI sidepanel, custom tab titles, light-only mode.

Minor / follow-ups

  • The REST page's version-dropdown-hiding (NavbarItem swizzle) is bypassed by t-rex's navbar; low impact.
  • t-rex's premium SearchPage may be shadowed by the classic Algolia search page.

Adopt Software Mansion's t-rex-ui Docusaurus theme for a premium feel,
rebranded to Fishjam (orange accents, warm neutrals, beige navbar/footer,
DM Sans). Light-only is preserved; Shiki + Twoslash + copy button, Scalar
REST, /search and the Ask-AI sidepanel all keep working.

t-rex-ui 1.3.3 constrains the toolchain, so this also:
- Pins the whole Docusaurus tree to 3.9.2 via `resolutions` (t-rex uses
  3.9-only theme-common internals; renames future.faster ->
  experimental_faster).
- Bumps React 18 -> 19 (t-rex bundles a React 19 JSX runtime; also aligns
  with the repo's existing @types/react@19 / react-native 0.80).
- Adds an inline configureWebpack plugin to transpile t-rex's untranspiled
  JSX under node_modules (Docusaurus excludes node_modules otherwise).
- Swaps @docsearch/docusaurus-adapter for classic Algolia
  (themeConfig.algolia) so t-rex's navbar search works; moves Ask-AI keys
  to customFields.askAi (still rendered via @docsearch/react in Root).

Theme tokens vendored in src/css/trex-theme.css; Fishjam overrides in
custom.css remap t-rex's navy/purple base scales to the brand palette.
@linear

linear Bot commented Jun 30, 2026

Copy link
Copy Markdown

FCE-2061

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.

1 participant