Skip to content

Refresh the docs homepage, code blocks, admonitions and screenshots - #78

Merged
fmercadop merged 5 commits into
mainfrom
docs-home-redesign
Nov 27, 2026
Merged

fmercadop merged 5 commits into
mainfrom
docs-home-redesign

Conversation

@gams87

@gams87 gams87 commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor

Summary

A proposal for a new docs homepage. The current one leads with the company mission and a sales banner, and its three cards use clipart icons in mixed styles. Most visitors come to search or to find a specific topic, so the new page puts that first:

  • Hero with a large search box. It opens the same search modal as the navbar (Cmd/Ctrl+K), plus Get started and Tutorials buttons.
  • Start here by role. Administrators and developers each get a card with direct links into Getting Started.
  • Browse by topic. Eight cards (Airflow, dbt, VS Code, Snowflake, Git, Security and secrets, Metrics and logs, Administration), each with links to the most used pages.
  • Consistent line icons (Lucide, ISC license) inlined in the brand blue, with no new dependency.
  • How-tos, Best practices and Reference kept as a compact row.
  • The sales section reduced to a one-line "Book a demo" band.
  • Works in light and dark mode and on small screens.

The old HomepageFeatures and CTA components and their three SVGs are removed; nothing else used them.

Code blocks

  • Bash, SQL and Jinja are highlighted. Docusaurus only bundles a few Prism languages, so the 39 bash and 24 sql blocks rendered as plain text. They are now loaded through additionalLanguages, with django for the dbt Jinja blocks (fenced as jinja2) and ini for the .env snippets.
  • New themes: One Light and One Dark (were GitHub and Dracula), a matching pair that sits better with the navy and blue palette.
  • Lighter styling: a thin border instead of the drop shadow, slightly smaller type, a quieter title bar, and a matching border on inline code.
  • Six fences renamed so they match a Prism language (jinja to jinja2, JSON to json, env to ini).

Admonitions and screenshots

  • Admonitions (note, tip, info, warning, caution) get a light tint, a colored left edge and a colored title, with the regular text color for the body. In dark mode this replaces Infima's flat gray note and heavy brown warning.
  • Screenshots inside the docs get a thin frame and rounded corners, and in dark mode are dimmed slightly with a soft shadow so white product captures don't glare.

About 235 blocks still declare no language and render as plain text; adding it is content cleanup for a follow-up.

Screenshots

Before

home-light

After (light)

new-light

After (dark)

new-dark

After (mobile)

new-mobile

Code blocks

Before After
Bash before-bash-light after-bash-light
SQL before-sql-light after-sql-light
YAML before-yaml-light after-yaml-light
Python (dark) before-python-dark after-python-dark

Admonitions (light and dark)

Before After
admonitions-before admonitions-after

Screenshot in dark mode

Before After
image-dark-before image-dark-after

Checklist

  • [Mandatory] My pull request represents one logical piece of work and my commits are related and look clean.

🤖 Generated with Claude Code

https://claude.ai/code/session_015pcV34KcZ9UzUQGmj35oJJ

@gams87
gams87 requested a review from noel November 13, 2026 22:03
@gams87
gams87 marked this pull request as draft November 13, 2026 22:08
@gams87 gams87 changed the title Redesign the docs homepage around search, roles and topics Redesign the docs homepage and code blocks Nov 13, 2026
gams87 and others added 2 commits November 13, 2026 16:13
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015pcV34KcZ9UzUQGmj35oJJ
@gams87 gams87 changed the title Redesign the docs homepage and code blocks Refresh the docs homepage, code blocks, admonitions and screenshots Nov 13, 2026
@gams87
gams87 marked this pull request as ready for review November 13, 2026 22:30
@noel

noel commented Nov 25, 2026

Copy link
Copy Markdown
Contributor

@gams87 this looks great

@fmercadop can you do a quick review and we can merge it

@fmercadop

Copy link
Copy Markdown
Contributor

@noel, @gams87, I went through the new homepage and the docs pages visually, in light and dark mode, on desktop and mobile, and I really like it. It's a big improvement over what we have today. Search comes first, and the role and topic cards make it much easier to find things. The new code blocks and admonitions look much cleaner, especially in dark mode. Nice work!

I also asked Claude to help me review the code side. It built the site locally, checked that it merges cleanly with the latest main, clicked through all the homepage links and tested the search button. Everything works. It found a few small things, none of them blocking:

  1. Jinja comments are highlighted as code. In blocks like {# Correct #}, words inside the comment get colored as variables or keywords. prism-react-renderer tokenizes the original code, so the markup-templating placeholders that django/jinja2 rely on are never applied. It's still better than plain text, just FYI.
  2. The hero shows "Ctrl K" on Mac, while the navbar search shows ⌘K right next to it. The search plugin already detects Apple devices (isAppleDevice()), so the hero could do the same. It could also hide the hint on mobile.
  3. openSearch() sends a synthetic Cmd/Ctrl+K keydown, so it relies on how the current search plugin handles that shortcut. If we ever switch search plugins, the hero button would stop working without any error. A short comment or a fallback would help.
  4. New fences will need the right names. Anyone who writes ```jinja or ```env in the future will get plain text again. A note in the README, or an alias, would help. Also, 'sql' in additionalLanguages isn't needed (prism-react-renderer already bundles it), and the one kusto block is still not highlighted.
  5. .demoBand { margin-bottom: -3rem } depends on .footer { margin-top: 3rem } in custom.css. If one changes without the other, the white strip comes back.
  6. Lucide's ISC license asks to include its copyright and permission notice. Right now icons.js only names the license.
  7. Small copy nit: "Configure your repository" links to a page titled "Update Repository for Airflow".

@noel

noel commented Nov 25, 2026

Copy link
Copy Markdown
Contributor

@gams87 can you make these updates?

- Highlight dbt Jinja with a grammar of its own, so {# comments #} are
  comments; prism-react-renderer never runs the markup-templating hooks
  Prism's django grammar relies on.
- Add fence aliases (jinja, env, dotenv, kql), load kusto, drop the
  bundled sql, and document code block languages in the README.
- Show the hero's shortcut as ⌘ K on Apple devices, hide it on phones.
- Open search by clicking the navbar button, falling back to Cmd/Ctrl+K.
- Tie the demo band's negative margin to the footer gap variable.
- Include Lucide's full license notices.
- Rename "Configure your repository" to match the page it opens.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@gams87

gams87 commented Nov 25, 2026

Copy link
Copy Markdown
Contributor Author

@noel @fmercadop thanks for the review! All seven points are addressed in 1be7362:

  1. Jinja comments: dbt Jinja now has its own grammar (src/theme/prism-include-languages.js), so {# … #} renders as a comment, and functions, strings and keywords inside {{ }} / {% %} are colored. Tags have to close on the same line, so the deliberately broken examples in the compilation errors page stay plain text. markup-templating and django are no longer loaded.
  2. Shortcut hint: the hero shows ⌘ K on Apple devices and Ctrl K elsewhere, using the same check as the search plugin. It's set after hydration and hidden on phones.
  3. openSearch(): it clicks the navbar search button, and falls back to the Cmd/Ctrl+K shortcut only if that button isn't there. A comment says to re-check both if the search plugin changes.
  4. Fence names: added aliases jinja, env, dotenv and kql, loaded kusto (that block is highlighted now), dropped the bundled sql, and added a "Code blocks" section to the README.
  5. Demo band: both sides use one variable, --dcv-footer-gap, so they can't drift apart.
  6. Lucide license: the full license file, including the MIT notice for the Feather-derived icons we use (search, arrow-right, terminal, code), is in src/components/Home/LICENSE-lucide.txt, and icons.js points to it.
  7. Copy: the link now reads "Update your repository for Airflow".

I checked the changes with Playwright against a local build (11 checks: shortcut label on Mac/Windows/mobile, the search modal and its fallback, band flush with the footer in both themes, the renamed link, and Jinja and Kusto tokens), and reviewed the screenshots.

One thing outside this PR: every page logs React hydration error #418, on main too. It most likely comes from the search plugin's button computing ⌘/Ctrl from navigator during render. Worth a separate ticket.

@noel

noel commented Nov 25, 2026

Copy link
Copy Markdown
Contributor

@gams87 can you create the other ticket and see if that can be fixed, the React hydration

@noel

noel commented Nov 25, 2026

Copy link
Copy Markdown
Contributor

@fmercadop can you check this again, but manually e.g. running it locally to see that inkgs look good etc

@fmercadop
fmercadop merged commit bf5436e into main Nov 27, 2026
2 checks passed
@fmercadop
fmercadop deleted the docs-home-redesign branch November 27, 2026 18:57
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