docusaurus-styling

Align Docusaurus visuals with the Avalonia Customer Portal theme using TailwindCSS and CSS variables.

157|301|Updated Apr 24, 2023
One-click install
npx skills add https://github.com/AvaloniaUI/avalonia-docs --skill docusaurus-styling
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: docusaurus-styling
Source: https://github.com/AvaloniaUI/avalonia-docs/tree/main/.claude/skills/docusaurus-styling
Command: npx skills add https://github.com/AvaloniaUI/avalonia-docs --skill docusaurus-styling

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Docusaurus pages often diverge from Avalonia branding; this Skill provides a structured approach to style Docusaurus to match the Avalonia Customer Portal theme using TailwindCSS, CSS variables, and optional component swizzling to ensure a unified brand experience.

Core Features & Use Cases

  • Theme alignment: Mirror the Customer Portal palette, typography, spacing, and shadows across the docs site.
  • Tailwind + CSS variables: Leverage Tailwind utilities and global CSS variables to implement consistent theming with minimal drift.
  • Component swizzling guidance: Provide safe strategies for swapping or wrapping Docusaurus components to reuse Customer Portal UI patterns when needed.
  • Use Case: When a docs site needs to visually align with the customer portal to present a single brand experience.

Quick Start

Configure the Docusaurus project to mirror the Customer Portal by aligning TailwindCSS, CSS variables, and, if needed, component swizzling.

Frequently Asked Questions about docusaurus-styling

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I align Docusaurus styling with a custom brand theme?

You align Docusaurus styling by mapping CSS variables to your brand palette and applying TailwindCSS utilities for consistent typography and spacing. This approach ensures the documentation site mirrors the customer portal visually with minimal drift.

What is component swizzling in Docusaurus and when do I need it?

Component swizzling in Docusaurus is the process of swapping or wrapping internal theme components to inject custom UI patterns. You need it when standard CSS variables and TailwindCSS cannot fully replicate the customer portal's design.

Can I use TailwindCSS with Docusaurus for theming?

Yes, you can use TailwindCSS with Docusaurus to implement consistent theming across your documentation site. It works alongside global CSS variables mapped to your brand palette to maintain unified visual styling.

How do I map CSS variables to a custom palette in Docusaurus?

You map CSS variables to a custom palette in Docusaurus by overriding the default theme tokens with your brand's specific colors, shadows, and spacing values. This creates a single source of truth for styling across all pages.

What is the best way to prevent style drift in Docusaurus documentation?

The best way to prevent style drift in Docusaurus is to leverage TailwindCSS utilities and global CSS variables mapped to the customer portal palette. This structured approach ensures consistent theming and minimizes visual divergence.

Do I need to swizzle Docusaurus components to match portal branding?

No, swizzling Docusaurus components is optional and only required when standard CSS variables and TailwindCSS cannot fully reproduce the customer portal UI. Often, mapping CSS variables is sufficient for unified branding.