Skip to content

Conversation

@jon-fern
Copy link
Contributor

@jon-fern jon-fern commented Jan 6, 2026

Description

Refs: Companion PR to fern-api/fern-platform#6225

Adds a new light-mode-code setting to docs.yml that forces code blocks to display in light mode regardless of the selected theme. This is the inverse of the existing dark-mode-code setting.

Changes Made

  • Added light-mode-code property to DocsSettingsConfig in the docs.yml API definition
  • Added lightModeCode to the TypeScript API type with JSDoc documentation
  • Added serialization support mapping light-mode-code (YAML) to lightModeCode (TypeScript)
  • Updated parseDocsConfiguration to include the new setting with default value false
  • Added changelog entry for version 3.36.0

Usage

# docs.yml
settings:
  light-mode-code: true  # Forces light code blocks even in dark mode

Testing

  • Lint checks pass (pnpm run check)
  • Manual testing completed (requires fern-platform PR to be merged first)

Human Review Checklist


Link to Devin run: https://app.devin.ai/sessions/c0ff290bf09844f79c4ff090e370dd59
Requested by: @jon-fern

Co-Authored-By: jon@buildwithfern.com <jon@buildwithfern.com>
@devin-ai-integration
Copy link
Contributor

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment and CI monitoring

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 766d34e0b2

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines 409 to +411
return {
darkModeCode: settings.darkModeCode ?? false,
lightModeCode: settings.lightModeCode ?? false,

Choose a reason for hiding this comment

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

P1 Badge Add schema support for light-mode-code

The new lightModeCode field added here won’t ever make it through docs loading because packages/cli/workspace/loader/src/docs-yml.schema.json still lists only search-text, disable-search, dark-mode-code, default-search-filters, etc. under DocsSettingsConfig with additionalProperties: false, so a docs.yml that sets settings.light-mode-code will fail schema validation before parsing. Regenerate or update the schema to include light-mode-code so the new setting can be used.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants