diff --git a/web/app/guides/[slug]/page.tsx b/web/app/guides/[slug]/page.tsx index 8e65e9a..cd4aab2 100644 --- a/web/app/guides/[slug]/page.tsx +++ b/web/app/guides/[slug]/page.tsx @@ -38,7 +38,9 @@ export async function generateStaticParams() { } function wrapCodeBlocksWithCopyable(content: string) { + // Expresión regular mejorada para detectar bloques de código y aplicar CopyableCode directamente const codeBlockRegex = /
([\s\S]*?)<\/code><\/pre>/g
+
return content.replace(codeBlockRegex, (match, code) => {
return ` `
})
@@ -55,8 +57,9 @@ export default async function GuidePage({ params }: { params: { slug: string } }
className="prose prose-gray max-w-none
[&>h1]:text-gray-900 [&>h2]:text-gray-800 [&>h3]:text-gray-700
[&>p]:text-gray-600 [&>ul>li]:text-gray-600 [&>ol>li]:text-gray-600"
- dangerouslySetInnerHTML={{ __html: guideContent }}
- />
+ >
+
+
)