Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resize images before upload in web UI to reduce bandwidth #7223

Merged
merged 3 commits into from Apr 22, 2018

Conversation

Projects
None yet
3 participants
@Gargron
Copy link
Member

Gargron commented Apr 21, 2018

Fix #7218

@Gargron Gargron added the ui label Apr 21, 2018

@ykzts

ykzts approved these changes Apr 22, 2018

@ykzts ykzts added the performance label Apr 22, 2018

};

const resizeImage = (inputFile, callback) => {
if (inputFile.type.match(/image.*/)) {

This comment has been minimized.

@unarist

unarist Apr 22, 2018

Collaborator

Animated gifs will pass this test and it will lost animation.

This comment has been minimized.

@Gargron

Gargron Apr 22, 2018

Author Member

But a GIF image larger than 1280px... is there any point in keeping it animated, since it will be a large file size..?

This comment has been minimized.

@unarist

unarist Apr 22, 2018

Collaborator

but if you do so silently. they won't be aware of losing animation before posting it.

I think most cases will be covered even if we exclude GIFs from this process.

@Gargron Gargron merged commit 05fb6f0 into master Apr 22, 2018

8 checks passed

ci/circleci: check-i18n Your tests passed on CircleCI!
Details
ci/circleci: install Your tests passed on CircleCI!
Details
ci/circleci: install-ruby2.4 Your tests passed on CircleCI!
Details
ci/circleci: install-ruby2.5 Your tests passed on CircleCI!
Details
ci/circleci: test-ruby2.4 Your tests passed on CircleCI!
Details
ci/circleci: test-ruby2.5 Your tests passed on CircleCI!
Details
ci/circleci: test-webui Your tests passed on CircleCI!
Details
codeclimate All good!
Details

@Gargron Gargron deleted the feature-js-resize branch Apr 22, 2018

byronhulcher added a commit to byronhulcher/mastodon that referenced this pull request Aug 18, 2018

Resize images before upload in web UI to reduce bandwidth (tootsuite#…
…7223)

* Resize images before upload in web UI to reduce bandwidth

Fix tootsuite#7218

* Fix issues

* Do not resize GIFs in JS
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.