Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
Webmention avatars are sometimes very large #126
Is there anything we can do to make these smaller?
How are these fetched?
It looks like the Twitter API supports standardized sizes https://developer.twitter.com/en/docs/accounts-and-users/user-profile-images-and-banners.html
256px is the smaller resized version. webmention.io will resize all avatars down to 256px regardless of whether they come from Twitter accounts or individual blogs.
The avatars don't always come from Twitter so I can't rely on using the twitter API for fetching profile images.
A ha—cruised through the source a bit and found https://github.com/aaronpk/ca3db-ruby
I wonder if it’s possible to entertain reducing this max size? Is this a change you might be comfortable with? Or a query param to opt-in to save some bandwidth?
Your site renders these at 36×36 (which would need a 7× retina screen to see 256×256 level of detail, but I believe that’s well beyond what the human eye is capable of—not counting for page zoom, of course)
yeah I show them kinda small, but some people show them a lot bigger.
One trick here is that the resizing is done system-wide, not per user account. So I can't make it resize avatars for you differently than for other users of webmention.io. The only way around that would be to let you put in your own S3 credentials to save the resized avatars to your own S3 account, and then I could let you also choose the dimensions. Is that something you'd be interested in?
There is already a checkbox in the settings where you can opt out of the resizing/archiving entirely, for example if you wanted to handle resizing on your own.