Oct. 2nd, 2025

[personal profile] pixellated
hi again! this is more of a general html/css question, but it has to work within dreamwidth's constraints, so i decided to ask it here. please let me know if this isn't the appropriate comm for this. i hope i used the right tags for this post.

here's what i'm trying to achieve (this would be displayed inside the most recent entry on my journal, so i can use regular CSS and not just inline, in case this matters):


i want to have a big box, and inside it a picture and a small box below that. i want the big box to resize responsively while keeping its proportions: suppose its width:height ratio is 1:2; i want it to keep that ratio always. as it resizes, i want the picture and small box inside to also resize while also keeping their proportions.

normally this would be really easy to do with aspect-ratio (<- this is a link to mozilla's developer resources) but that property doesn't seem to work on dreamwidth -- when i put it in my custom CSS, it doesn't seem to do anything, and it gets highlighted in red. (it works okay when i try it in online CSS editors, so i think it's not my mistake that's causing this.)

assuming this is true and i can't use aspect-ratio on DW, i need to cobble together some other solution, but i'm completely out of ideas. is this possible to achieve without aspect-ratio, or should i just change my idea to something that can be done on DW?

thanks again for your time!

Profile

Dreamwidth style system discussion

October 2025

S M T W T F S
   1 234
567891011
12131415161718
19202122232425
262728293031 

Style Credit

Expand Cut Tags

No cut tags
Page generated Oct. 2nd, 2025 05:38 pm
Powered by Dreamwidth Studios