From: Marc Foley Date: Thu, 17 Apr 2025 13:45:35 +0000 (+0100) Subject: Update tags.html X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=e94a06717e93cb0fe563cb074440920de36d8008;p=thirdparty%2Fgoogle%2Ffonts.git Update tags.html --- diff --git a/tags.html b/tags.html index e27d4e85a..b128a196c 100644 --- a/tags.html +++ b/tags.html @@ -160,8 +160,8 @@

No families found for this tag. Please add some

-
- +
+
@@ -194,6 +194,9 @@ toTag() { return `${this.name},${this.category},${this.score}`; } + get tag() { + return this.toTag(); + } toUrl() { return "https://fonts.googleapis.com/css2?family=" + this.name.replace(" ", "+").replace('"', ""); @@ -245,11 +248,12 @@ function axesCombos(axes) { } Vue.component('family-item', { - props: ['family', 'ready', 'index'], + props: ['family', 'ready', 'index', 'category'], template: `
- {{ familyDisplayName }} + {{ familyTag }} + {{ familyDisplayName }}
@@ -279,6 +283,9 @@ function axesCombos(axes) { }, familyDisplayName() { return this.family.displayName; + }, + familyTag() { + return this.family.tag } } }); @@ -301,7 +308,7 @@ function axesCombos(axes) { toFamily: "", currentCategory: "/Expressive/Calm", sortMethod: "Score", - categories: new Set(), + categories: new Set([" All"]), tags: [], reverseTags: false, seen: new Set(), @@ -370,9 +377,11 @@ function axesCombos(axes) { return bFamilyData[_this.sortMethod.toLowerCase()] - aFamilyData[_this.sortMethod.toLowerCase()]; } } - let ll = this.tags; - let filtered = ll.filter(family => family.category === this.currentCategory); - filtered = filtered.filter(family => family.name.toLowerCase().includes(this.tagFilter.toLowerCase())); + let filtered = this.tags; + if (this.currentCategory !== " All") { + filtered = filtered.filter(family => family.category === this.currentCategory); + } + filtered = filtered.filter(family => family.tag.match(this.tagFilter)); filtered.sort(sortFunc); if (this.reverseTags) {