Skip to content

Commit

Permalink
Merge pull request #12 from cloudmix-dev/bugfix/code-prose-styling
Browse files Browse the repository at this point in the history
Fix Code component styling within Prose component
  • Loading branch information
samlaycock authored Dec 30, 2023
2 parents ec00a5c + 307bdaf commit 9c59fd4
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/giant-trees-trade.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@cloudmix-dev/react": patch
---

Fix Code component rendering within Prose component
2 changes: 1 addition & 1 deletion packages/react/src/components/code.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ function Code({ content, copy, fileExplorer, language, numbers }: CodeProps) {
};

return (
<div className="relative p-4 bg-neutral-900 rounded-lg font-mono ring-1 ring-neutral-700">
<div className="not-prose relative p-4 bg-neutral-900 rounded-lg font-mono ring-1 ring-neutral-700">
<div className="absolute -top-px left-20 right-11 h-px bg-gradient-to-r from-brand-300/0 via-brand-300/70 to-brand-300/0 dark:from-brand-700/0 dark:via-brand-700/50 dark:to-brand-700/0" />
<div className="absolute -bottom-px left-11 right-20 h-px bg-gradient-to-r from-brand-400/0 via-brand-400 to-brand-400/0 dark:from-brand-600/0 dark:via-brand-600/70 dark:to-brand-600/0" />
{fileExplorer && (
Expand Down

0 comments on commit 9c59fd4

Please sign in to comment.