At various times in the past, upgrades in the sanitize-html library that
changed behavior of HTML filtering have caused things like emotes to
break unexpectedly. This commit adds a basic test to sanitize
non-alphanumeric characters found in channels' emote codes so that if
the library changes, the test will break and give a heads up that
something changed.
Camo: https://github.com/atmos/camo. This has a couple advantages over
just allowing images to be dumped as-is:
- Prevents mixed-content warnings by allowing the server to proxy HTTP
images to an HTTPS camo instance
- Protects users' privacy by not exposing their browser directly to
the image host
- Allows the camo proxy to intercept and reject bad image sources
(URLs that are not actually images, gigapixel-sized images likely to
DoS users' browsers, etc.)
Whitelisting specific domains is supported for cases where the source is
known to be trustworthy.
Code is not used anywhere yet, but the end goal is:
* Replace the bash-style algorithm with a less kludgy one
* Add the ability to customize tab completion method (will also
include default zsh-style completion)
* Abstract tab completion so it can be shared for chat and emote names
as available options