Skip to content

Commit 9e0d8ef

Browse files
author
lzm
committed
feat(blog): responsive tweaks for taxonomy cloud and series box
Add @media (max-width: 768px) rules so the home taxonomy chip cloud goes full-width with smaller chips on narrow screens (plus a 340px step-down), and so the series box's prev/next nav stacks vertically instead of squeezing two links side by side.
1 parent 890b829 commit 9e0d8ef

2 files changed

Lines changed: 40 additions & 2 deletions

File tree

assets/css/extended/home-taxonomies.css

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,4 +85,26 @@
8585
font-size: 0.7rem;
8686
font-weight: 600;
8787
line-height: 1;
88-
}
88+
}
89+
/* Mobile: single-column, tighter chips so nothing overflows on 340px. */
90+
@media screen and (max-width: 768px) {
91+
.home-taxonomies {
92+
max-width: 100%;
93+
padding: 1.25rem 1rem 0;
94+
margin-top: 1.25rem;
95+
gap: 1rem;
96+
}
97+
.home-taxonomy-chip {
98+
font-size: 0.8rem;
99+
padding: 0.25rem 0.6rem;
100+
}
101+
.home-taxonomy-count {
102+
min-width: 1.3em;
103+
height: 1.3em;
104+
}
105+
}
106+
@media screen and (max-width: 340px) {
107+
.home-taxonomy-chip {
108+
font-size: 0.75rem;
109+
}
110+
}

assets/css/extended/series-box.css

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,4 +182,20 @@
182182
color: var(--secondary);
183183
font-size: 1rem;
184184
line-height: 1;
185-
}
185+
}
186+
/* Mobile: stack the prev/next nav vertically so long titles stay readable. */
187+
@media screen and (max-width: 768px) {
188+
.series-box {
189+
padding: 0.75rem 1rem;
190+
}
191+
.series-box-list li {
192+
padding: 0.4rem 0;
193+
}
194+
.series-box-nav {
195+
flex-direction: column;
196+
gap: 0.5rem;
197+
}
198+
.series-box-nav-link {
199+
max-width: 100%;
200+
}
201+
}

0 commit comments

Comments
 (0)