mirror of
https://github.com/vinta/awesome-python.git
synced 2026-03-23 13:56:43 +08:00
feat: show category label on mobile in project name column
On narrow screens the category column is hidden. This adds a .mobile-cat span inside the name cell that renders the first category below the project name, giving mobile users the context they were missing. Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -611,6 +611,10 @@ kbd {
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.mobile-cat {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.col-name > a {
|
||||
color: var(--ink);
|
||||
font-size: clamp(1rem, 1.5vw, 1.08rem);
|
||||
@@ -1066,6 +1070,18 @@ th[data-sort].sort-asc::after {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.col-name {
|
||||
white-space: normal;
|
||||
}
|
||||
|
||||
.mobile-cat {
|
||||
display: block;
|
||||
margin-top: 0.25rem;
|
||||
font-size: var(--text-tag);
|
||||
font-weight: 600;
|
||||
color: var(--ink-muted);
|
||||
}
|
||||
|
||||
.col-stars {
|
||||
width: 5.4rem;
|
||||
}
|
||||
|
||||
@@ -151,6 +151,7 @@
|
||||
<a href="{{ entry.url }}" target="_blank" rel="noopener"
|
||||
>{{ entry.name }}</a
|
||||
>
|
||||
<span class="mobile-cat">{{ entry.categories[0] }}</span>
|
||||
</td>
|
||||
<td class="col-stars">
|
||||
{% if entry.stars is not none %}{{ "{:,}".format(entry.stars) }}{%
|
||||
|
||||
Reference in New Issue
Block a user