aoijs / aoi.js

aoi.js - The most advanced string-based package to create a Discord Bot fast and powerful.
https://aoi.js.org
Apache License 2.0
342 stars 134 forks source link

Bug: $addSelectMenu not accepting emojis #512

Closed Faf4a closed 10 months ago

Faf4a commented 11 months ago

Bug Type

Function

Bugged Function

$addSelectMenu[1;string;customId;Hello;1;1;false;Label:descajf:value:false::sip:]

$addSelectMenu[1;string;customId;Hello;1;1;false;Label:descajf:value:false:<:sip:878108113260130375>]

$addSelectMenu[1;string;customId;Hello;1;1;false;Label:descajf:value:false:sip,878108113260130375,false]

Version of aoi.js

v6.5.0

Version of Node.js

v20.5.1 (Current)

Excepted Output

Select menu with emoji.

Relevant log output

N/A

Code of Conduct

Faf4a commented 11 months ago

I will most likely submit a PR to fix this issue along with #511.

valentineu0 commented 11 months ago

This problem continues the same way in version 6.6.1.

error

$addSelectMenu[1;string;smenu;select;1;1;false;Opt 1:test:ticketMenuR1:false:<:valentine_mail_fast:1182061512743993444>;Opt 2:test:ticketMenuR2:false:]

valentineu0 commented 11 months ago

I changed the emoji using #COLON# with aoi.parser and it worked!

$addSelectMenu[1;string;SelectMenu;select;1;1;false;Option 1:test:opt1:false:<#COLON#valentine_mail_fast#COLON#1182061512743993444>]

If the parser is to be continued to be used, it needs to be added to the $addSelectMenu documentation.