From 979b2246ee8c7a9ba43ef142993c8e2c31048931 Mon Sep 17 00:00:00 2001 From: Thiago Teixeira Date: Mon, 16 Dec 2024 17:15:29 -0800 Subject: [PATCH] Fix comments --- components/blocks/callout.module.css | 4 ---- components/layouts/container.module.css | 6 ++++++ styles/text.scss | 6 +++--- 3 files changed, 9 insertions(+), 7 deletions(-) diff --git a/components/blocks/callout.module.css b/components/blocks/callout.module.css index 4d1ae136e..9881364ef 100644 --- a/components/blocks/callout.module.css +++ b/components/blocks/callout.module.css @@ -7,10 +7,6 @@ @apply text-gray-90 !important; } -.Container p > code { - @apply border border-gray-40 text-red-70 rounded-md px-1 mx-1 break-words; -} - .Container p:only-child, .Container p:last-child, .Container section:last-child, diff --git a/components/layouts/container.module.css b/components/layouts/container.module.css index fa12c78eb..7f552657d 100644 --- a/components/layouts/container.module.css +++ b/components/layouts/container.module.css @@ -17,6 +17,12 @@ @apply border-b border-b-gray-90 hover:border-red-60 hover:opacity-80; } +/* If link is just for code, don't add border */ +.ArticleContainer a:has(tt:only-child), +.ArticleContainer a:has(code:only-child) { + @apply border-0; +} + :global(.dark) .ArticleContainer p a, :global(.dark) .ArticleContainer ol li a, :global(.dark) .ArticleContainer ul li a { diff --git a/styles/text.scss b/styles/text.scss index 727f904aa..19253c70c 100644 --- a/styles/text.scss +++ b/styles/text.scss @@ -99,7 +99,7 @@ ul + p { @apply mt-8; } -/* Focuss styles */ +/* Focus styles */ a:focus, a:focus-visible, button:focus, @@ -113,8 +113,8 @@ li > code, /* Inline code blocks in docstrings */ tt.docutils.literal { @apply break-words px-1 rounded; - @apply text-green-80 bg-gray-10; - @apply dark:text-green-50 dark:bg-gray-90; + @apply text-green-80 bg-green-80/5; + @apply dark:text-green-50 dark:bg-green-50/10; @apply text-base; }