- {Object.keys(props.extraVariants || {}).map((slug) => (
+ {Object.keys(extraVariants || {}).map((slug) => (
{slug}
- {Object.keys(props.extraVariants?.[slug].extraSource || {}).map((key) => (
+ {Object.keys(extraVariants?.[slug].extraSource || {}).map((key) => (
- {key}: {props.extraVariants?.[slug]?.extraSource?.[key]}
+ {key}:{' '}
+ {extraVariants?.[slug]?.extraSource?.[key]
+ ? hastToJsx(extraVariants[slug].extraSource![key])
+ : null}
))}
diff --git a/docs/app/docs-infra/components/code-highlighter/demos/demo-fallback/DemoContentLoading.tsx b/docs/app/docs-infra/components/code-highlighter/demos/demo-fallback/DemoContentLoading.tsx
index 8babec8af..db44881d7 100644
--- a/docs/app/docs-infra/components/code-highlighter/demos/demo-fallback/DemoContentLoading.tsx
+++ b/docs/app/docs-infra/components/code-highlighter/demos/demo-fallback/DemoContentLoading.tsx
@@ -2,6 +2,8 @@
import * as React from 'react';
import type { ContentLoadingProps } from '@mui/internal-docs-infra/CodeHighlighter/types';
+import { useCodeFallback } from '@mui/internal-docs-infra/CodeHighlighter';
+import { hastToJsx } from '@mui/internal-docs-infra/pipeline/hastUtils';
import { Tabs } from '@/components/Tabs';
import styles from '../DemoContent.module.css';
@@ -9,6 +11,7 @@ import '../syntax.css';
export function DemoContentLoading(props: ContentLoadingProps