--- a/hugo/data/pluginTypes.json Wed Jan 01 22:12:52 2020 +0000
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,50 +0,0 @@
- "type": "Security and Privacy",
- "en": "Security and Privacy"
- "type": "Notifications",
- "type": "Profile and Status Updates",
- "en": "Profile and Status Updates"
- "type": "Interface Tweaks",
- "en": "Interface Tweaks"
- "type": "Accounts and Logs",
- "en": "Accounts and Logs"
- "type": "Miscellaneous",
\ No newline at end of file
--- a/hugo/layouts/shortcodes/plugintable.html Wed Jan 01 22:12:52 2020 +0000
+++ b/hugo/layouts/shortcodes/plugintable.html Thu Jan 02 02:36:57 2020 +0000
@@ -53,10 +53,15 @@
<input type="text" id="plugin-filter-search" placeholder="{{ T "Search-placeholder" }}" />
<div id="plugin-selector">
- {{ range .Site.Data.pluginTypes }}
+ {{ range .Site.Data.plugins }} + {{ $types = $types | append ( index . "type" ) }} + {{ range uniq $types }} <label class="pidgin-plugin-filter-checkbox">
- <input type="checkbox" data-type="{{ .type }}">
+ <input type="checkbox" data-type="{{ . }}"> --- a/hugo/static/js/plugin-table.js Wed Jan 01 22:12:52 2020 +0000
+++ b/hugo/static/js/plugin-table.js Thu Jan 02 02:36:57 2020 +0000
@@ -37,6 +37,7 @@
@@ -84,7 +85,7 @@
* @param {MouseEvent} event
* @param {HTMLInputElement} event.target
-function pluginTypeSelectorClickEvent(target) {
+function pluginTypeSelectorClickEvent({ target }) { searchState.type[target.checked ? "add" : "delete"](target.dataset.type);
--- a/tools/plugin-map.js Wed Jan 01 22:12:52 2020 +0000
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,20 +0,0 @@
-const fs = require("fs");
-const data = require("../hugo/data/plugins.json");
-const types = new Set();
-data.forEach(plugin => {
- types.add(plugin.type);
-const newData = Array.from(types).map(type => ({
- "../hugo/data/pluginTypes.json",
- JSON.stringify(newData, null, "\t")