mirror of
https://gitlab.com/bignutty/labscore.git
synced 2025-06-10 15:13:04 -04:00
use pill helper
This commit is contained in:
parent
974f5c6a53
commit
1e880ded55
1 changed files with 9 additions and 5 deletions
|
@ -1,4 +1,4 @@
|
||||||
const { codeblock, highlight, icon, link } = require('../../../labscore/utils/markdown')
|
const { codeblock, highlight, icon, link, pill } = require('../../../labscore/utils/markdown')
|
||||||
const { createEmbed, formatPaginationEmbeds } = require('../../../labscore/utils/embed')
|
const { createEmbed, formatPaginationEmbeds } = require('../../../labscore/utils/embed')
|
||||||
|
|
||||||
const { DISCORD_INVITES } = require('../../../labscore/constants')
|
const { DISCORD_INVITES } = require('../../../labscore/constants')
|
||||||
|
@ -12,7 +12,7 @@ function createHelpPage(context, title, contents, descriptions){
|
||||||
createEmbed("default", context, {
|
createEmbed("default", context, {
|
||||||
description: `${title}\n\n` +
|
description: `${title}\n\n` +
|
||||||
renderCommandList(contents, descriptions) +
|
renderCommandList(contents, descriptions) +
|
||||||
`\n\n${icon("question")} Use ${highlight(` ${context.commandClient.prefixes.custom.first()}help <command> `)} to view more information about a command.`
|
`\n\n${icon("question")} Use ${pill(`${context.commandClient.prefixes.custom.first()}help <command>`)} to view more information about a command.`
|
||||||
})
|
})
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
@ -39,10 +39,14 @@ function renderCommandList(commands, descriptions, limit){
|
||||||
}
|
}
|
||||||
|
|
||||||
function createCommandPage(context, prefix, command){
|
function createCommandPage(context, prefix, command){
|
||||||
alias = ''
|
alias = ' '
|
||||||
if(command.aliases.length >= 1) alias = ' ` ' + command.aliases.join(' ` ` ') + ' `\n'
|
if(command.aliases.length >= 1){
|
||||||
|
for(const al of command.aliases) alias += pill(al)
|
||||||
|
alias += "\n"
|
||||||
|
}
|
||||||
|
|
||||||
let page = createEmbed("default", context, {
|
let page = createEmbed("default", context, {
|
||||||
description: `${icon("command")} **\` ${command.name} \`**\n${alias}\n${command.metadata.description}`,
|
description: `${icon("command")} ${pill(command.name)}\n${alias}\n${command.metadata.description}`,
|
||||||
fields: []
|
fields: []
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue