We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 73ab9f8 commit 6e250b2Copy full SHA for 6e250b2
src/components/toc-hero/toc-hero-contents.tsx
@@ -26,9 +26,11 @@ export function TocHeroContents({
26
<ul
27
className={clsx(
28
"grid grid-flow-row-dense grid-rows-2 gap-px border-t border-inherit bg-neu-300 dark:bg-neu-100",
29
- sections.length > 3
+ sections.length % 3 === 0
30
? "grid-cols-2 lg:grid-cols-[repeat(3,1fr)]"
31
- : "grid-cols-1",
+ : sections.length % 2 === 0
32
+ ? "grid-cols-2"
33
+ : "grid-cols-1",
34
)}
35
>
36
{sections.map((section, i) => {
0 commit comments