mirror of
https://github.com/vinta/awesome-python.git
synced 2026-03-24 01:24:43 +08:00
feat(website): add Built-in category tag for stdlib entries
Stdlib entries now show a "Built-in" tag alongside their regular category tag. The tag is clickable and filters to all 17 stdlib entries. Added to data-cats attribute so existing filter logic works. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -347,6 +347,12 @@ th[data-sort].sort-asc::after {
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.tag-source {
|
||||
background: var(--bg-input);
|
||||
color: var(--text-muted);
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
/* === Arrow Column === */
|
||||
.col-arrow {
|
||||
width: 2.5rem;
|
||||
|
||||
@@ -84,7 +84,7 @@
|
||||
<tr
|
||||
class="row"
|
||||
role="button"
|
||||
data-cats="{{ entry.categories | join('||') }}"
|
||||
data-cats="{{ entry.categories | join('||') }}{% if entry.source_type == 'Built-in' %}||Built-in{% endif %}"
|
||||
data-groups="{{ entry.groups | join('||') }}"
|
||||
tabindex="0"
|
||||
aria-expanded="false"
|
||||
@@ -122,6 +122,11 @@
|
||||
{{ cat }}
|
||||
</button>
|
||||
{% endfor %}
|
||||
{% if entry.source_type == 'Built-in' %}
|
||||
<button class="tag tag-source" data-type="cat" data-value="Built-in">
|
||||
Built-in
|
||||
</button>
|
||||
{% endif %}
|
||||
<button class="tag tag-group" data-type="group" data-value="{{ entry.groups[0] }}">
|
||||
{{ entry.groups[0] }}
|
||||
</button>
|
||||
|
||||
Reference in New Issue
Block a user