|
7 | 7 | --font-roboto-mono: "Roboto Mono", monospace;
|
8 | 8 | }
|
9 | 9 |
|
10 |
| -html { |
11 |
| - @apply text-neutral-950 dark:text-white selection:bg-neutral-950 selection:text-white dark:selection:bg-white dark:selection:text-neutral-950; |
12 |
| -} |
| 10 | +@layer base { |
| 11 | + html { |
| 12 | + @apply text-neutral-950 dark:text-white selection:bg-neutral-950 selection:text-white dark:selection:bg-white dark:selection:text-neutral-950; |
| 13 | + scroll-behavior: smooth; |
| 14 | + } |
| 15 | + |
| 16 | + body { |
| 17 | + font-family: var(--font-outfit); |
| 18 | + } |
| 19 | + |
| 20 | + h1[id], |
| 21 | + h2[id] { |
| 22 | + @apply scroll-mt-16; |
| 23 | + } |
| 24 | + |
| 25 | + .prose h1 { |
| 26 | + @apply text-4xl font-black text-neutral-950 dark:text-white; |
| 27 | + } |
| 28 | + |
| 29 | + .prose h2 { |
| 30 | + @apply text-3xl font-extrabold text-neutral-950 dark:text-white; |
| 31 | + } |
| 32 | + |
| 33 | + .prose h3 { |
| 34 | + @apply text-xl font-bold text-neutral-950 dark:text-white; |
| 35 | + } |
| 36 | + |
| 37 | + .prose h1:first-of-type { |
| 38 | + @apply hidden; |
| 39 | + } |
| 40 | + |
| 41 | + .prose a { |
| 42 | + @apply text-blue-400 no-underline hover:underline; |
| 43 | + } |
| 44 | + |
| 45 | + .prose strong { |
| 46 | + @apply font-black text-neutral-950 dark:text-white; |
| 47 | + } |
| 48 | + |
| 49 | + .prose hr { |
| 50 | + @apply border-1 border-neutral-200 dark:border-neutral-800 rounded-xl my-8 first:hidden; |
| 51 | + } |
| 52 | + |
| 53 | + .prose blockquote { |
| 54 | + @apply border-l-4 pl-4 italic text-neutral-500 border-neutral-200 dark:border-neutral-800 rounded-xl; |
| 55 | + quotes: "“" "”"; |
| 56 | + } |
| 57 | + |
| 58 | + .prose blockquote::before { |
| 59 | + content: "“"; |
| 60 | + color: theme("colors.neutral.500"); |
| 61 | + font-family: "Victor Mono", monospace; |
| 62 | + font-size: 4rem; |
| 63 | + line-height: 0; |
| 64 | + margin-right: 0.25rem; |
| 65 | + vertical-align: -0.4em; |
| 66 | + } |
| 67 | + |
| 68 | + .prose blockquote::after { |
| 69 | + content: "”"; |
| 70 | + display: none; |
| 71 | + } |
| 72 | + |
| 73 | + .prose blockquote cite { |
| 74 | + @apply block text-sm font-medium mt-2 text-right text-neutral-500; |
| 75 | + } |
| 76 | + |
| 77 | + .prose table { |
| 78 | + @apply w-full text-sm text-left rtl:text-right text-white; |
| 79 | + } |
| 80 | + |
| 81 | + .prose thead { |
| 82 | + @apply text-xs font-black uppercase bg-neutral-800 text-white; |
| 83 | + } |
| 84 | + |
| 85 | + .prose tr > th { |
| 86 | + @apply min-w-52 text-xs px-4 py-2; |
| 87 | + } |
| 88 | + |
| 89 | + .prose tr { |
| 90 | + @apply border-b border-transparent; |
| 91 | + } |
| 92 | + |
| 93 | + .prose tr > td { |
| 94 | + @apply min-w-52 text-xs px-4 h-10 pb-1; |
| 95 | + } |
| 96 | + |
| 97 | + .prose ul > li::marker { |
| 98 | + @apply font-bold text-neutral-500 leading-relaxed; |
| 99 | + /* content: '- '; */ |
| 100 | + } |
| 101 | + |
| 102 | + .prose :not(pre) > code { |
| 103 | + @apply text-neutral-950 dark:text-white bg-neutral-100 dark:bg-neutral-900 border-2 border-neutral-200 dark:border-neutral-800 rounded-lg px-1.5 py-0.5 font-medium; |
| 104 | + } |
| 105 | + |
| 106 | + .prose :not(pre) > code::before, |
| 107 | + .prose :not(pre) > code::after { |
| 108 | + content: none !important; |
| 109 | + } |
| 110 | + |
| 111 | + .prose pre { |
| 112 | + @apply rounded-xl border-2 border-neutral-200 dark:border-neutral-800 overflow-x-auto p-4 !bg-neutral-100 dark:!bg-neutral-900; |
| 113 | + } |
| 114 | + |
| 115 | + .prose pre code { |
| 116 | + @apply text-sm lg:text-xs font-mono leading-relaxed text-neutral-950 dark:text-white; |
| 117 | + font-family: "Fira Code", monospace; |
| 118 | + } |
| 119 | + |
| 120 | + .prose pre { |
| 121 | + overflow-x: auto; |
| 122 | + overflow-y: hidden; |
| 123 | + } |
| 124 | + |
| 125 | + .prose pre::-webkit-scrollbar { |
| 126 | + height: 8px; |
| 127 | + width: 0px; |
| 128 | + } |
| 129 | + |
| 130 | + .prose pre::-webkit-scrollbar-track { |
| 131 | + background: transparent; |
| 132 | + margin-left: 8px; |
| 133 | + margin-right: 8px; |
| 134 | + } |
| 135 | + |
| 136 | + .prose pre::-webkit-scrollbar-thumb { |
| 137 | + background-color: #737373; |
| 138 | + border-radius: 10px; |
| 139 | + border: 2px solid transparent; |
| 140 | + background-clip: content-box; |
| 141 | + transition: background-color 0.2s ease; |
| 142 | + } |
13 | 143 |
|
14 |
| -body { |
15 |
| - font-family: var(--font-outfit); |
| 144 | + .prose pre::-webkit-scrollbar-thumb:active { |
| 145 | + background-color: rgba(255, 255, 255, 0.9); |
| 146 | + } |
16 | 147 | }
|
17 | 148 |
|
18 | 149 | ::-webkit-scrollbar {
|
|
0 commit comments