mirror of
https://github.com/ZeppelinBot/Zeppelin.git
synced 2025-05-10 20:35:02 +00:00
Documentation work. Add command info for all Utility plugin commands.
This commit is contained in:
parent
d9b65590d8
commit
9b5307ba2b
5 changed files with 197 additions and 52 deletions
|
@ -34,6 +34,15 @@ export const DocsStore: Module<DocsState, RootState> = {
|
|||
if (state.plugins[name]) return;
|
||||
|
||||
const data = await get(`docs/plugins/${name}`);
|
||||
if (data && data.commands) {
|
||||
data.commands.sort((a, b) => {
|
||||
const aName = a.trigger.toLowerCase();
|
||||
const bName = b.trigger.toLowerCase();
|
||||
if (aName > bName) return 1;
|
||||
if (aName < bName) return -1;
|
||||
return 0;
|
||||
});
|
||||
}
|
||||
commit("setPluginData", { name, data });
|
||||
},
|
||||
},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue