Skip to content

style: reduce font weights and clean up docs layout#36

Open
SameerJS6 wants to merge 13 commits into
mainfrom
upgrade/full-deps-latest
Open

style: reduce font weights and clean up docs layout#36
SameerJS6 wants to merge 13 commits into
mainfrom
upgrade/full-deps-latest

Conversation

@SameerJS6
Copy link
Copy Markdown
Owner

@SameerJS6 SameerJS6 commented Feb 15, 2026

Summary

  • Reduced font weights across docs titles and prose headings for a lighter, cleaner look
  • Updated hero section typography (title to font-medium, removed subtitle font-medium)
  • Removed unnecessary "use client" directive from docs layout
  • Reordered Tailwind classes in hero for consistency

Summary by CodeRabbit

  • Chores

    • Updated core dependencies, dev tooling, and added formatting & changeset scripts
    • Restored linting to run during builds
  • Style

    • Switched monospace to JetBrains Mono and refined code block, dialog, and preview styling
    • Adjusted typography weights, spacing, and responsive dimensions for consistency
    • Docs headings and link behavior improved
  • Refactor

    • Consolidated theming and utility styles into global stylesheet and streamlined ESLint/config setup

SameerJS6 and others added 11 commits February 15, 2026 01:46
React 19.2, Next.js 16.1.6, Tailwind CSS 4.1, fumadocs 16.6,
and all Radix UI, motion, vaul, cmdk, shiki, zod packages.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Delete tailwind.config.ts, move config to CSS-first @theme inline
- Switch postcss plugin from tailwindcss to @tailwindcss/postcss
- Replace tailwindcss-animate with tw-animate-css
- Add @Utility for no-scrollbar, @custom-variant for dark mode
- Add tailwindStylesheet to prettier config

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Update provider import to fumadocs-ui/provider/next
- Update findNeighbour import to fumadocs-core/page-tree
- Add explicit Page type for custom frontmatter schema fields
- Add fumadocs CSS imports and @source directive in globals.css
- Remove non-async export from code-highlight server actions

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Remove eslint block from next.config.mjs (removed in Next 16)
- Rewrite eslint.config.mjs to native flat config
- Update tsconfig.json for Next.js 16 defaults

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Use data-[state=open/closed] variants instead of shorthand for
  Radix UI compatibility in revola.tsx and dialog.tsx
- Update shadcn dialog to v4 animation pattern (fade + zoom)
- Fix ReactNode type for icon in command menu

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
rehype-pretty-code strips .line class and uses data-line attribute,
causing fumadocs CSS padding rules to not apply.
Load JetBrains Mono as a local font and update all font-geist-mono
references to font-jetbrains-mono across components and registry.
- Change DocsTitle from font-semibold to font-normal
- Override prose heading font-weight to 500 for h2-h6
- Reduce hero title from font-semibold to font-medium, remove subtitle font-medium
- Remove unnecessary "use client" from docs layout
- Reorder Tailwind classes in hero for consistency

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@vercel
Copy link
Copy Markdown
Contributor

vercel Bot commented Feb 15, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
revola Ready Ready Preview, Comment Feb 15, 2026 0:52am

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Feb 15, 2026

📝 Walkthrough

Walkthrough

Updates include Tailwind/PostCSS plugin and global CSS changes, migration from Geist Mono to a local JetBrains Mono font, new exported Page type, ESLint/Prettier and package script/tooling updates, UI styling tweaks across docs and dialog components, and several dependency/version bumps and script additions.

Changes

Cohort / File(s) Summary
Tailwind & Global Styles
postcss.config.mjs, app/globals.css, tailwind.config.ts
Switched PostCSS plugin key to @tailwindcss/postcss, replaced detailed tailwind config by deleting tailwind.config.ts, and reworked app/globals.css to import tailwind/presets, introduce theme tokens, animations, and utilities (including no-scrollbar).
Font migration
app/layout.tsx, components/code-block.tsx, components/component-preview.tsx, registry/.../controlled-demo.tsx, registry/.../default.tsx, registry/.../non-dismissiable.tsx
Replaced Geist Mono with local JetBrains Mono (next/font/local), updated font classnames and related provider import path to fumadocs-ui/provider/next.
Docs & Layout
app/(docs)/docs/[[...slug]]/page.tsx, app/(docs)/layout.tsx, content/docs/why.mdx
Switched neighbourhood lookup to fumadocs-core/page-tree, added Page typing/use, hardened metadata handling, refined MDX component typings/props, adjusted typography and layout classes, removed client directive and explicit sidebar width; changed front-matter icon.
Type exports & lib changes
lib/source.ts, lib/code-highlight.ts
Added and exported a new Page type (InferPageType-based) and updated source import path; removed convertRegistryPaths from public exports in lib/code-highlight.ts.
UI component styling
components/ui/dialog.tsx, components/mobile-preview.tsx, components/hero.tsx, components/component-preview.tsx, registry/revola/revola.tsx
Adjusted dialog overlay opacity and responsive sizing/positioning, reordered animation/state classes, tweaked typography weights and various component sizing/padding tokens across preview and mobile dialog components.
Build, lint, formatting & deps
package.json, eslint.config.mjs, next.config.mjs, .prettierrc.json, .gitignore, tsconfig.json
Removed eslint ignoreDuringBuilds and turbopack dev flag; replaced FlatCompat extends with direct ESLint imports; added Prettier tailwindStylesheet and format/changeset scripts; updated lint scripts to use eslint .; added gitignore entries; bumped many dependencies and dev scripts.
Minor content & examples
components/code-block.tsx, registry/cmdk/examples/shadcn-command-menu.tsx, several registry example files
Styling and class-order tweaks, reduced max-heights, swapped font classnames, and broadened an example icon type to ReactNode.

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~50 minutes

Possibly related PRs

Poem

🐰 Hopping through fonts and Tailwind anew,
JetBrains Mono snug in a burrow of glue.
Types nosed out, styles pruned with delight,
Dialogs and docs dressed up just right —
A little rabbit cheers in soft moonlight! 🥕✨

🚥 Pre-merge checks | ✅ 3 | ❌ 1
❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately reflects the main changes: font weight reductions in docs and hero components, plus removal of unnecessary directives and layout cleanup.
Merge Conflict Detection ✅ Passed ✅ No merge conflicts detected when merging into main

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch upgrade/full-deps-latest

No actionable comments were generated in the recent review. 🎉


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 5

🤖 Fix all issues with AI agents
In `@app/`(docs)/docs/[[...slug]]/page.tsx:
- Around line 145-150: Summary: The computed target prop is being overwritten by
the later props spread; move the spread before setting target so our computed
target wins. Fix: In the anchor renderer (the function returning <Link ... />)
spread props first and then set target using the computed expression
(props.href?.startsWith("https") ? "_blank" : "_self") so any incoming target in
props does not override it; keep the same props cast to
React.ComponentProps<typeof Link> and preserve other attributes. Ensure the
order is: {...(props as React.ComponentProps<typeof Link>)} then target={...}.
- Line 34: Remove the redundant type assertion on the result of source.getPage:
where code assigns const page = source.getPage(params.slug) as Page | undefined,
change it to const page = source.getPage(params.slug) (no assertion). Ensure the
subsequent guard if (!page) notFound() remains intact so TypeScript can narrow
the type; update all call sites in this file that use the same pattern
(references: source.getPage, page, notFound).

In `@components/code-block.tsx`:
- Around line 67-69: The "Loading..." pre is invisible on the bg-black container
because no explicit foreground color is set; update the component (in
components/code-block.tsx) to apply a light text color class (e.g., add
text-white or text-gray-100) to the container div or the <pre> element so the
loading text is readable against bg-black (modify the className on the
surrounding <div className="relative my-6 min-h-125 overflow-hidden rounded-lg
border bg-black text-sm"> or on the <pre> element).

In `@components/component-preview.tsx`:
- Around line 56-68: Replace the incorrect Tailwind attribute selector
data-[state=active] with data-[active] on the Tabs.Tab className strings so the
active styles apply; specifically update the Tabs.Tab instances (the ones
containing "Preview" and "Code") to use data-[active]:border-b-primary
data-[active]:text-foreground data-[active]:shadow-none instead of
data-[state=active]:*; make the same replacement for the Tabs.Tab usages in the
companion component (component-preview-custom-highlight) to ensure active-tab
styling works as intended.

In `@registry/revola/revola.tsx`:
- Around line 170-171: In the desktop variant string in revola.tsx (the long
class list containing "data-[state=open]:animate-in ... outline-none"), remove
the duplicated "max-w-[calc(100%-2rem)]" and resolve the conflicting breakpoint
classes by keeping only the intended "sm:max-w-lg" (remove "sm:max-w-sm"), and
then delete the commented-out old variant line below it; ensure the cleaned
class string is passed unchanged to the same cn()/twMerge call that uses this
value.
🧹 Nitpick comments (4)
app/layout.tsx (1)

19-23: Only the Regular weight is bundled.

If any UI element applies font-bold or font-semibold to text using font-jetbrains-mono, the browser will synthesize a faux bold instead of using a proper weight variant. This is fine if monospace text is only ever displayed at normal weight, but worth confirming.

app/globals.css (1)

1-8: Static analysis warnings are false positives — Tailwind v4 directives.

The Biome and Stylelint errors for @source, @custom-variant, @theme, and @utility are all valid Tailwind CSS v4 syntax that these tools don't yet recognize. Consider adding Tailwind v4-aware parser configuration to Biome/Stylelint to suppress these, or exclude this file from those linters.

components/code-block.tsx (1)

53-65: Potential double border: both the outer div (Line 56) and ScrollArea (Line 60) carry border rounded-lg.

Since ScrollArea uses size-full inside the overflow-hidden parent, the two borders will visually stack. If this is intentional, no action needed — but if a single border is desired, remove border from one of the two elements.

app/(docs)/docs/[[...slug]]/page.tsx (1)

152-158: Inline <code> styling will be fully replaced if props contain a className.

The hardcoded className on Line 155 is set before {...props} is spread. If a rehype/remark plugin or MDX content injects a className, the styling is lost. Wrapping with cn() would be safer, though for pure inline code this is unlikely to be an issue in practice.

💡 Safer merge
 code: ({ ref, ...props }: React.ComponentProps<"code">) => (
   <code
     ref={ref}
-    className="border border-primary/15 bg-secondary/50 px-1 py-[1.5px] font-jetbrains-mono text-secondary-foreground"
     {...props}
+    className={cn("border border-primary/15 bg-secondary/50 px-1 py-[1.5px] font-jetbrains-mono text-secondary-foreground", props.className)}
   />
 ),

Comment thread app/(docs)/docs/[[...slug]]/page.tsx Outdated
Comment thread app/(docs)/docs/[[...slug]]/page.tsx
Comment thread components/code-block.tsx
Comment thread components/component-preview.tsx
Comment thread registry/revola/revola.tsx Outdated
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