Skip to content

Commit 493c671

Browse files
authored
fix: update syntax highlighting transformer styles (#558)
1 parent c863c82 commit 493c671

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/styles/typography.css

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@
7171
}
7272

7373
.astro-code code {
74-
@apply bg-inherit p-0;
74+
@apply flex-[1_0_100%] bg-inherit p-0;
7575
}
7676

7777
blockquote {
@@ -93,7 +93,7 @@
9393

9494
/* ===== Code Blocks & Syntax Highlighting ===== */
9595
.astro-code {
96-
@apply border bg-(--shiki-light-bg) text-(--shiki-light) outline-border [&_span]:text-(--shiki-light);
96+
@apply flex border bg-(--shiki-light-bg) text-(--shiki-light) outline-border [&_span]:text-(--shiki-light);
9797
}
9898

9999
html[data-theme="dark"] .astro-code {
@@ -104,13 +104,13 @@
104104
/* https://shiki.style/packages/transformers */
105105
.astro-code {
106106
.line.diff.add {
107-
@apply relative *:bg-green-500/20 before:absolute before:-left-3 before:text-green-500 before:content-['+'];
107+
@apply relative inline-block w-full bg-green-400/20 before:absolute before:-left-3 before:text-green-500 before:content-['+'];
108108
}
109109
.line.diff.remove {
110-
@apply relative *:bg-red-500/30 before:absolute before:-left-3 before:text-red-500 before:content-['-'];
110+
@apply relative inline-block w-full bg-red-500/20 before:absolute before:-left-3 before:text-red-500 before:content-['-'];
111111
}
112112
.line.highlighted {
113-
@apply *:!bg-slate-400/20;
113+
@apply inline-block w-full bg-slate-400/20;
114114
}
115115
.highlighted-word {
116116
@apply rounded-sm border border-border px-0.5 py-px;

0 commit comments

Comments
 (0)