Wrap text around any image or shape that you want with shape-outside and shape-margin

Wrap text around any image or shape that you want with shape-outside and shape-margin

Kevin Powell

3 года назад

78,910 Просмотров

Ссылки и html тэги не поддерживаются


Комментарии:

Erich Wolf
Erich Wolf - 08.11.2023 19:28

This is great!!!! Thanks!

Ответить
Huawei Trainings Africa
Huawei Trainings Africa - 01.10.2023 23:19

For this to work, I think the image has to be the first child. I was working with a design that required the image to be second child (that is after the text) and wasn't working. Until I moved the image before the text. Then gave my image "float:right;" style. If anyone has an alternative workaround, please help. DISCLAIMER; I am not really good with floats.

Ответить
AntoniKrokodyl
AntoniKrokodyl - 28.08.2023 21:11

Great video, love the t shirt.

Ответить
Vivian Hayles
Vivian Hayles - 27.08.2023 13:06

Hello Kevin. Your video is really helpful. I have managed to use the "shape-outside: circle ();" command in my CSS file on Notepad. However, when I used the "shape-outside: url();" command, nothing changed, that is, my text is still not wrapping around my irregular image. Any suggestions?

Ответить
MiguelSkytwins 91
MiguelSkytwins 91 - 11.04.2023 23:03

THANK YOU!

Ответить
Saada Mehdi
Saada Mehdi - 09.04.2023 11:56

There's a big issue. How does this work witih a figure element (I need figcaptions) ? It doesn't... shape-outside only applies to img

Ответить
Jatin Khatri
Jatin Khatri - 10.01.2023 11:31

struggling for this thing for one day. Thanks a lot. You made my day.😇

Ответить
Denis TRUFFAUT
Denis TRUFFAUT - 12.11.2022 02:56

Awesome !

Ответить
The Von Munchies
The Von Munchies - 24.08.2022 22:46

Super useful! Thank you!

Ответить
Asrar
Asrar - 07.05.2022 16:18

I stumbled across this after pondering how to do something similar with images

Ответить
Jason Burnett
Jason Burnett - 29.03.2022 11:00

Can you only do this with image elements or could you use the shape features to wrap around, say a headline?

Ответить
Alex Pascanu
Alex Pascanu - 02.03.2022 13:56

Why you did not get rid of 'float:left'?

Ответить
Pallavi singh Chandan singh
Pallavi singh Chandan singh - 14.02.2022 08:22

Thank you very much sir I am a child and you really helped me

Ответить
Tessa MacTaggart
Tessa MacTaggart - 03.02.2022 12:28

Just wow.. and so well explained! Thank you.

Ответить
iiviiGames
iiviiGames - 16.01.2022 04:11

If I had watched this when I woke up this morning, I would have saved myself 10 hours of rage and I'd still have a 2 monitor setup.

Ответить
Gonca Negis
Gonca Negis - 24.10.2021 21:37

This has definitely made my portfolio better looking, thank you so much!

Ответить
JOEL
JOEL - 21.10.2021 22:45

Can't seem to get the shape-outside: url('path'); to work -- it still wraps like an old school float. Help....

Ответить
holo mode
holo mode - 13.10.2021 20:13

since the latest ui update firefox became an amazing browser again, not only for development purposes

Ответить
Jane Migliore
Jane Migliore - 19.08.2021 22:36

Hi Kevin, Does it only work with webp images? I'm using a png with a transparent bkgd but it's not working. Thanks!

Ответить
Coleman Alexander
Coleman Alexander - 21.07.2021 19:47

This blew my mind . I'm making a website for Basics of Web Development class and it's a presidential campaign page for Saitama from one punch man. I wrapped the bio text around OPM and my teacher said he didn't know how I did that so it blew his mind too!

Ответить