Reduce the number of messages from meme, img, anim, sticker, meme, and giphy

Issue #7 resolved
Dave created an issue

Currently when calling any of the above commands, the message returned (if successful) will just be a link which is then processed by Image in Hipchat which creates another message.

Would it be worth returning back html with the url in an image tag to reduce the "spaminess" of sassy?

Comments (2)

  1. Robert Bergman Account Deactivated

    The original implementation(s) of Sassy actually did this, and people hated it, unfortunately.

    Here are the current downsides to returning HTML instead of a link:

    • HTML notifications can't be minimized in clients. Until they can, it's possible to circumvent client settings to automatically minimize animated gifs, and disables the ability for people to minimize returned images they'd rather not look at (for whatever reason).

    • At the time, there was no ability for an add-on to set the max width/height of an image included as an HTML tag, due to the server-side HTML sanitizer. I believe this limitation has since been solved, but at the time this meant that Sassy's images could be huge and take up enormous swaths of chat UI real estate.

    That said there was one really big upside to using an image tag to link images (which is why I originally implemented it that way) -- I was using a resizing proxy to generate thumbnails (though, sadly, sometimes the resizer failed, which could cause the giant image problem mentioned above) for inclusion in the chat stream, with the thumbnails linking to a full sized image in an external browser when clicked. This would greatly reduce the bandwidth required to display linked images, which could be quite meaningful in mobile scenarios. The UX problems dominated, though, and Sassy switched back to responding to image searches with vanilla links.

    If the HipChat clients ever get the ability minimize notifications in addition to image previews, I think Sassy could viably return to this approach.

  2. Dave reporter

    The minimising is a good point! I should have thought about that sorry.

    For the max-Height and max-width, they still get removed when placed in a style tag but you can place them in a class tag to mimic the css of Crappie Image messages

    Thanks!

  3. Log in to comment