File tree Expand file tree Collapse file tree 1 file changed +18
-21
lines changed
website/src/pages/queries Expand file tree Collapse file tree 1 file changed +18
-21
lines changed Original file line number Diff line number Diff line change @@ -21,6 +21,9 @@ for (const query of remoteQueries.queries) {
21
21
}
22
22
}
23
23
24
+ // Get an array of plugin names that have queries
25
+ const pluginNamesWithQueries = Array .from (pluginsWithQueries ).sort ();
26
+
24
27
const allQueries = remoteQueries ;
25
28
---
26
29
@@ -86,27 +89,21 @@ Anyquery allows you to run SQL queries on pretty-much any data source`}
86
89
</h2 >
87
90
<div class =" flex flex-wrap gap-2" >
88
91
{
89
- Array .from (pluginsWithQueries )
90
- .sort ((a , b ) => a [0 ].localeCompare (b [0 ]))
91
- .map (([pluginName , _ ]) => {
92
- const plugin = pluginsMapper [pluginName ];
93
- if (! plugin ) {
94
- return ;
95
- }
96
- return (
97
- <a
98
- class = " flex items-center text-xs bg-white/10 px-4 py-2 rounded-md"
99
- href = { ` /queries/plugin/${plugin .name } ` }
100
- >
101
- <img
102
- class = " h-4 w-4 mr-2"
103
- src = { plugin .icon }
104
- alt = " "
105
- />
106
- { plugin .display_name }
107
- </a >
108
- );
109
- })
92
+ pluginNamesWithQueries .map ((pluginName ) => {
93
+ const plugin = pluginsMapper [pluginName ];
94
+ if (! plugin ) {
95
+ return ;
96
+ }
97
+ return (
98
+ <a
99
+ class = " flex items-center text-xs bg-white/10 px-4 py-2 rounded-md"
100
+ href = { ` /queries/plugin/${plugin .name } ` }
101
+ >
102
+ <img class = " h-4 w-4 mr-2" src = { plugin .icon } alt = " " />
103
+ { plugin .display_name }
104
+ </a >
105
+ );
106
+ })
110
107
}
111
108
</div >
112
109
<a
You can’t perform that action at this time.
0 commit comments