From 90e0894a08019c3589f511f5c56212c5e0df2e0a Mon Sep 17 00:00:00 2001 From: Benjamin Leonard Date: Wed, 27 Nov 2024 12:53:17 +0000 Subject: [PATCH 1/2] Add convenience classes for inline code and links --- components/dist/asciidoc.css | 17 ++--------------- components/src/assets/asciidoc.css | 17 ++--------------- 2 files changed, 4 insertions(+), 30 deletions(-) diff --git a/components/dist/asciidoc.css b/components/dist/asciidoc.css index fc9c3d6..1565c4d 100644 --- a/components/dist/asciidoc.css +++ b/components/dist/asciidoc.css @@ -274,8 +274,8 @@ .asciidoc-body h3 code, .asciidoc-body h4 code, .asciidoc-body h5 code, - .asciidoc-body table code { - @apply text-secondary; + .asciidoc-body table code .inline-code { + @apply text-[0.825rem] text-secondary; @apply ml-[1px] mr-[1px] rounded border px-[4px] py-[1px] align-[1px] bg-raise border-secondary; } @@ -296,19 +296,6 @@ @apply overflow-x-auto !text-[13px] text-mono-code; } - .asciidoc-body h1 code, - .asciidoc-body h2 code, - .asciidoc-body h3 code, - .asciidoc-body h4 code, - .asciidoc-body h5 code { - @apply text-[0.825em]; - } - - .asciidoc-body .paragraph > code, - .asciidoc-body p code { - @apply text-[0.825rem]; - } - .asciidoc-body code { font-feature-settings: 'calt' 0; } diff --git a/components/src/assets/asciidoc.css b/components/src/assets/asciidoc.css index fc9c3d6..1565c4d 100644 --- a/components/src/assets/asciidoc.css +++ b/components/src/assets/asciidoc.css @@ -274,8 +274,8 @@ .asciidoc-body h3 code, .asciidoc-body h4 code, .asciidoc-body h5 code, - .asciidoc-body table code { - @apply text-secondary; + .asciidoc-body table code .inline-code { + @apply text-[0.825rem] text-secondary; @apply ml-[1px] mr-[1px] rounded border px-[4px] py-[1px] align-[1px] bg-raise border-secondary; } @@ -296,19 +296,6 @@ @apply overflow-x-auto !text-[13px] text-mono-code; } - .asciidoc-body h1 code, - .asciidoc-body h2 code, - .asciidoc-body h3 code, - .asciidoc-body h4 code, - .asciidoc-body h5 code { - @apply text-[0.825em]; - } - - .asciidoc-body .paragraph > code, - .asciidoc-body p code { - @apply text-[0.825rem]; - } - .asciidoc-body code { font-feature-settings: 'calt' 0; } From 021dabf090dec3621eb50236fb9c89f862cfa169 Mon Sep 17 00:00:00 2001 From: Benjamin Leonard Date: Wed, 27 Nov 2024 12:55:05 +0000 Subject: [PATCH 2/2] Add accent link --- components/dist/asciidoc.css | 10 ++++++++-- components/src/assets/asciidoc.css | 10 ++++++++-- 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/components/dist/asciidoc.css b/components/dist/asciidoc.css index 1565c4d..02cfa08 100644 --- a/components/dist/asciidoc.css +++ b/components/dist/asciidoc.css @@ -7,6 +7,12 @@ */ @layer components { + .accent-link { + @apply text-accent-secondary hover:text-accent; + text-decoration: underline; + text-decoration-color: var(--content-accent-tertiary); + } + .asciidoc-body .line-through { text-decoration: line-through; } @@ -546,8 +552,8 @@ @apply border-r-0; } - /* - specificity to handle nested tables + /* + specificity to handle nested tables todo: check if it's needed in any of the other table styles */ .asciidoc-body tbody > tr:last-child > td, diff --git a/components/src/assets/asciidoc.css b/components/src/assets/asciidoc.css index 1565c4d..02cfa08 100644 --- a/components/src/assets/asciidoc.css +++ b/components/src/assets/asciidoc.css @@ -7,6 +7,12 @@ */ @layer components { + .accent-link { + @apply text-accent-secondary hover:text-accent; + text-decoration: underline; + text-decoration-color: var(--content-accent-tertiary); + } + .asciidoc-body .line-through { text-decoration: line-through; } @@ -546,8 +552,8 @@ @apply border-r-0; } - /* - specificity to handle nested tables + /* + specificity to handle nested tables todo: check if it's needed in any of the other table styles */ .asciidoc-body tbody > tr:last-child > td,