Automattic / _s

Hi. I'm a starter theme called _s, or underscores, if you like. I'm a theme meant for hacking so don't use me as a Parent Theme. Instead try turning me into the next, most awesome, WordPress theme out there. That's what I'm here for.
http://underscores.me/
GNU General Public License v2.0
10.94k stars 3.12k forks source link

Can we align `.alignleft` and `.alignright` to be full-width in mobile devices? #1376

Closed mayeenulislam closed 4 years ago

mayeenulislam commented 4 years ago

The idea is behind a common pattern that, in mobile devices float images often make the text to be unreadable or difficult to read. So, in mobile devices (viewport lesser than 37.5em) we can make the images full-width to make the text distributed in a nicer way.

Current

At present the content breaks because of float on mobile devices if the image is small.
floatright

Expected

Expecting a good-read text top or bottom of the image while in smaller viewport.
floatnone

Actually we did similar in our development. So we thought it'd be nice to have that in core _s.

philiparthurmoore commented 4 years ago

Sometimes images aren't big, though. How do you cover those cases?

philiparthurmoore commented 4 years ago

Closing this - there is an assumption in this issue that all images on mobile will be large enough to fit mobile viewports. That's not true.

I suggest you work on mobile image size handling rather than how they are aligned in mobile views.