mirror of
https://gitlab.com/bignutty/labscore.git
synced 2025-06-23 05:17:04 -04:00
update extreme conditions icons
This commit is contained in:
parent
a6efe07e07
commit
61b3e760a7
2 changed files with 21 additions and 8 deletions
|
@ -41,33 +41,33 @@ module.exports.stringwrap = function(content = "", length, newlines = true){
|
|||
}
|
||||
|
||||
module.exports.pill = function(content = ""){
|
||||
return " **` " + content.toString().replace(/\`/g, 'ˋ') + " `**"
|
||||
return " **` " + content.toString().replace(/\`/g, 'ˋ') + " `**"
|
||||
}
|
||||
|
||||
module.exports.smallPill = function(content = ""){
|
||||
return " ` " + content.toString().replace(/\`/g, 'ˋ') + " `"
|
||||
return " ` " + content.toString().replace(/\`/g, 'ˋ') + " `"
|
||||
}
|
||||
|
||||
module.exports.iconPill = function(icon, content = ""){
|
||||
if(!ICONS[icon]) icon = "question"
|
||||
return ICONS[icon].replace(/:[a-z1-9_]*:/, ':i:') + " **` " + content.toString().replace(/\`/g, 'ˋ') + " `**"
|
||||
return ICONS[icon].replace(/:[a-z1-9_]*:/, ':i:') + " **` " + content.toString().replace(/\`/g, 'ˋ') + " `**"
|
||||
}
|
||||
|
||||
module.exports.smallIconPill = function(icon, content = ""){
|
||||
if(!ICONS[icon]) icon = "question"
|
||||
return ICONS[icon].replace(/:[a-z1-9_]*:/, ':i:') + " ` " + content.toString().replace(/\`/g, 'ˋ') + " `"
|
||||
return ICONS[icon].replace(/:[a-z1-9_]*:/, ':i:') + " ` " + content.toString().replace(/\`/g, 'ˋ') + " `"
|
||||
}
|
||||
|
||||
module.exports.iconLinkPill = function(icon, url, content = "", tooltip = ""){
|
||||
if(!ICONS[icon]) icon = "question"
|
||||
if(tooltip.length) tooltip = ` '${tooltip}'`
|
||||
if(content) return `${ICONS[icon].replace(/:[a-z1-9_]*:/, ':i:')} [**\` ${content.toString().replace(/\`/g, 'ˋ')} \`**](${url.replace(/\)/g, '\\)')}${tooltip})`
|
||||
if(content) return `${ICONS[icon].replace(/:[a-z1-9_]*:/, ':i:')} [**\` ${content.toString().replace(/\`/g, 'ˋ')} \`**](${url.replace(/\)/g, '\\)')}${tooltip})`
|
||||
return url
|
||||
}
|
||||
|
||||
module.exports.linkPill = function(url, content = "", tooltip = ""){
|
||||
if(tooltip.length) tooltip = ` '${tooltip}'`
|
||||
if(content) return `[**\` ${content.toString().replace(/\`/g, 'ˋ')} \`**](${url.replace(/\)/g, '\\)')}${tooltip})`
|
||||
if(content) return `[**\` ${content.toString().replace(/\`/g, 'ˋ')} \`**](${url.replace(/\)/g, '\\)')}${tooltip})`
|
||||
return url
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue