max-width for images and videos?

Discussions related to the forums itself. Call for moderators. Trash Posts area.
Post Reply
User avatar
db48x
Fast Inserter
Fast Inserter
Posts: 106
Joined: Wed Mar 13, 2013 12:15 pm
Contact:

max-width for images and videos?

Post by db48x »

Can the theme be tweaked so that it applies max-width: 100%; to images and videos in posts? This will cause the browser to scale them down so that they fit inside the post, rather than showing them at full size but clipping them. Images and videos that are smaller than the width of the post won't be affected. Thanks!

Zeblote
Filter Inserter
Filter Inserter
Posts: 973
Joined: Fri Oct 31, 2014 11:55 am
Contact:

Re: max-width for images and videos?

Post by Zeblote »

I'm pretty sure it already does this, since I requested it like 1 year ago?

Jap2.0
Smart Inserter
Smart Inserter
Posts: 2339
Joined: Tue Jun 20, 2017 12:02 am
Contact:

Re: max-width for images and videos?

Post by Jap2.0 »

I've seen plenty of images wider than my screen, so no, unless it only scales new images, in which case I'm not sure.
There are 10 types of people: those who get this joke and those who don't.

User avatar
Klonan
Factorio Staff
Factorio Staff
Posts: 5148
Joined: Sun Jan 11, 2015 2:09 pm
Contact:

Re: max-width for images and videos?

Post by Klonan »

This image is 4k but looks just fine, fits inside the post pretty reasonably, even though its almost twice my screen resolution

Image

If you could elaborate on the specific problem i could take a look

Jap2.0
Smart Inserter
Smart Inserter
Posts: 2339
Joined: Tue Jun 20, 2017 12:02 am
Contact:

Re: max-width for images and videos?

Post by Jap2.0 »

Yep, that looks fine for me too. Just prior to this, the post I was looking at (the second image) had a picture that went outside the post. I really see no pattern in what does and 2what doesn't, though.
There are 10 types of people: those who get this joke and those who don't.

User avatar
Kayanor
Global Moderator
Global Moderator
Posts: 565
Joined: Sat May 10, 2014 7:20 am
Contact:

Re: max-width for images and videos?

Post by Kayanor »

Seems to depend on if you are using [img] tags to insert your picture or attachments.
Former moderator.

Zeblote
Filter Inserter
Filter Inserter
Posts: 973
Joined: Fri Oct 31, 2014 11:55 am
Contact:

Re: max-width for images and videos?

Post by Zeblote »

Jap2.0 wrote:Yep, that looks fine for me too. Just prior to this, the post I was looking at (the second image) had a picture that went outside the post. I really see no pattern in what does and 2what doesn't, though.
Everything on that page looks correct to me.

User avatar
db48x
Fast Inserter
Fast Inserter
Posts: 106
Joined: Wed Mar 13, 2013 12:15 pm
Contact:

Re: max-width for images and videos?

Post by db48x »

Perhaps I misremembered about images; it's been a while since I posted one.

However, videos need the same treatment; here's one I posted recently: viewtopic.php?f=194&t=46855&p=299916#p299916

Jap2.0
Smart Inserter
Smart Inserter
Posts: 2339
Joined: Tue Jun 20, 2017 12:02 am
Contact:

Re: max-width for images and videos?

Post by Jap2.0 »

Hmm, I don't see the video at all (it's probably my firewall or something), but here is a picture of the pictures from my view (cropped together in paint, there are scrollbars on both axis.
Attachments
Picture.png
Picture.png (1.89 MiB) Viewed 3655 times
There are 10 types of people: those who get this joke and those who don't.

Jap2.0
Smart Inserter
Smart Inserter
Posts: 2339
Joined: Tue Jun 20, 2017 12:02 am
Contact:

Re: max-width for images and videos?

Post by Jap2.0 »

Hmm, that image looks larger than the screen as well. I uploaded it as a .png attachment, if it helps any.
There are 10 types of people: those who get this joke and those who don't.

orzelek
Smart Inserter
Smart Inserter
Posts: 3911
Joined: Fri Apr 03, 2015 10:20 am
Contact:

Re: max-width for images and videos?

Post by orzelek »

Both original thread and your image work properly here. And developer mode shows max width set to 100% for image element.
I'm using latest Opera (Chromium) - browser differences maybe?

Post Reply

Return to “This Forum”