cssgrid-ama icon indicating copy to clipboard operation
cssgrid-ama copied to clipboard

Break a fixed-percentage-width-image out of a container and keep text aligned to left of that container

Open mdominguez opened this issue 6 years ago • 1 comments

Hi Rachel,

What I would like to achieve is to have a fixed-percentage/vw-width-image pop-out of a max-width'ed container when keeping the textblock aligned to the left of the max-widht'ed container.

What I need to accomplish: sketch

I've made a simpler version in a pen: view pen So I need the green text to be aligned to the left of the purple text BUT on the condition that the gray image always stays 40% or 40vw of the viewport width.

css_-_break_a_fixed-percentage-width-image_out_of_a_container_and_keep_text_aligned_to_left_of_that_container_-_stack_overflow

Thanks in advance!

mdominguez avatar Apr 11 '18 06:04 mdominguez

I think I've found a solution, maybe you can check and point out if I could do anything in a more efficient or simpler way? Maybe a way without the need to use position: absolute on the image block? Thanks!

new pen

mdominguez avatar Apr 11 '18 09:04 mdominguez