everypolitician / gender-balance

Crowdsourcing platform for gathering gender information about politicians to improve the data in EveryPolitician
gender-balance.org
15 stars 3 forks source link

Squished pictures for Australia #184

Closed Flupsy closed 9 years ago

tmtmtmtm commented 9 years ago

Is this for all people, or all just a few? Can you attach some screenshots, as the ones I've checked look fine here:

screen shot 2015-07-28 at 12 00 27 screen shot 2015-07-28 at 12 00 21 screen shot 2015-07-28 at 12 00 15 screen shot 2015-07-28 at 12 00 09

Flupsy commented 9 years ago

It might be all images, I've only tried Australia, but this is what they look like for me. Also the page loaded over a hundred images before it displayed anything, total load time was 41 seconds.

1 2

chrismytton commented 9 years ago

@Flupsy What browser is this in?

Flupsy commented 9 years ago

@chrismytton Firefox 39.0 on Windows 8.1.

zarino commented 9 years ago

Regarding the oval pictures, it looks like Firefox isn't respecting the natural aspect ratio of the images, and is instead just resizing them vertically (which is the dimension we limit in the css) and leaving the horizontal width at whatever the image started at. Should be a simple fix. @tmtmtmtm – are images always square?

tmtmtmtm commented 9 years ago

@zarino we know effectively nothing about the underlying images — we're just passing through raw URLs from a variety of different sources. They're all being passed through https://github.com/jpmckinney/image-proxy, though, which allows for various resizing and padding options, so I believe we could make them all be square.

chrismytton commented 9 years ago

@zarino Yes, they will always be a square image of 140px by 140px, which is defined in the image-proxy url here.

zarino commented 9 years ago

This should fix it: https://github.com/everypolitician/gender-balance/pull/189

chrismytton commented 9 years ago

All of the images from the Australian parliament website seem to be broken at the moment(!). But looking at other countries in Firefox seems to confirm that this has been fixed.