fix emoji dropdown

This commit is contained in:
derpystuff 2023-11-26 20:45:48 +01:00
parent dea9e04641
commit ba73854391
2 changed files with 7 additions and 2 deletions

View file

@ -176,6 +176,11 @@ module.exports = {
return p.id == ctx.data.values[0]
})
// this sucks but works, ensures the newly selected option stays selected
for (let i = 0; i < components.components[0].components[0].options.length; i++) {
components.components[0].components[0].options[i].default = (components.components[0].components[0].options[i].value == ctx.data.values[0])
}
currentView = createEmbed("default", context, {
author: {
iconUrl: ico,
@ -199,7 +204,7 @@ module.exports = {
return {
label: r.version,
value: r.id,
default: (r.id == res.data.latest)
default: (r.id == res.data.platforms[args.type].images[0].id)
}
})

View file

@ -726,7 +726,7 @@ module.exports.EMOJIPEDIA_PLATFORM_TYPES = [
]
module.exports.EMOJIPEDIA_PLATFORM_TYPE_ALIASES = {
"fluent": "microsoft-teams",
"fluent": "microsoft-3D-fluent",
"twemoji": "twitter",
"playstation": "sony",
"ios": "apple",