glimesh.tv
glimesh.tv copied to clipboard
🧹 Sanitize characters in chat messages
This is probably a non-trivial challenge, but we may want to avoid messages like this that tend to get spammed when people 'stress test'. Or at least we should make sure it doesn't break our design/layout.
@mja00 Could you provide a text sample of this memery, elixir has great support for codepoints and i can probably strip this type of thing out on message creation
@Eein So that hot garbage I spewed into chat was Zalgo text, and here's an example: ȟ̵̢͇̰̹͚̙̗̤̖̥͔̹̈́a̵̢̫̳̣̲̝̍̄͑́̓̒̽͛̒̃̒̚͠͝͝h̴͚̓̿͐̑͗a̴̡̗͍̱̣̳̦̲̫͈̥͛̃̀̐͜͝h̵͉̟̲̜̔̈́̑͊̋̽̋̄̕ͅe̷̡̺̦̳̙̰̔͐̂̅̍̍̆̃ḩ̵͓̗̮͇͎̯͔͕̺̻͖͑͂̔͐̌͐͌̋̌̈̕͜͠e̴̱͙̒̂̇͜͠
It's worth noting GitHub allows these characters as well:
I think we should be hesitant to actually prevent, change, or sanitize these messages. However I agree we should not let any chat messages extend past the boundaries of the message, especially if it prevents moderator action.