diff options
author | Rich Barton <emptyarray@users.noreply.github.com> | 2017-07-10 06:51:07 -0700 |
---|---|---|
committer | Christopher Speller <crspeller@gmail.com> | 2017-07-10 06:51:07 -0700 |
commit | 998b8f70c2d88151b080657dea1ce0b9aca36d58 (patch) | |
tree | a9c74e7745005bcd588797b36e9b076c82cd7253 /webapp/tests/utils/formatting_imgs.test.jsx | |
parent | b03b9d736297a536bb1385c80f76f55473c9f637 (diff) | |
download | chat-998b8f70c2d88151b080657dea1ce0b9aca36d58.tar.gz chat-998b8f70c2d88151b080657dea1ce0b9aca36d58.tar.bz2 chat-998b8f70c2d88151b080657dea1ce0b9aca36d58.zip |
PLT-6659 Fixed upload thumbnails that weren't properly rotated (#6816)
- Used client-side EXIF data to rotate profile picture thumbnails
- Added a small package for correctly translating EXIF orientation into CSS transforms
- Instead of displaying the image using FileReader, used URL.createObjectURL because it is faster
- For upload thumbnails, the original behavior was scaling the entire original image, without accounting for EXIF rotate. I changed this to use the thumbnail image, which does respect rotation.
- The preview image was not available when the upload request returned, because handling the preview image creation was in a goroutine. I used sync.WaitGroup to block until the preview image creation is done.
Diffstat (limited to 'webapp/tests/utils/formatting_imgs.test.jsx')
0 files changed, 0 insertions, 0 deletions