I've written a post with better examples and more features.
This probably reflects a standard bio card thing. The image is centered by default. The background color is semi-transparent so you can see that there are no overlaps. The page texture also shows through, so this isn't a fake punch-out effect.
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras vitae tempor dolor, et pulvinar nulla. Nunc nibh eros, feugiat et vehicula a, tincidunt nec augue.
You can scale the entire box just by changing the text size. The image, radius, punch-out, etc. all scale with it.
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras vitae tempor dolor, et pulvinar nulla. Nunc nibh eros, feugiat et vehicula a, tincidunt nec augue.
Change the background color for your site. Account for different avatar images that maybe you don't want to scale to completely fill the circle.
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras vitae tempor dolor, et pulvinar nulla. Nunc nibh eros, feugiat et vehicula a, tincidunt nec augue.
While the box has a practical maximum size based on the font size you choose, it also doesn't need to fill the entire width of the page (container).
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras vitae tempor dolor, et pulvinar nulla. Nunc nibh eros, feugiat et vehicula a, tincidunt nec augue.
Maybe you don't want the image centered. That's cool. In this case I put the edge of the punch-out in line with the edge of the text. Because alignment, or some designery stuff like that.
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras vitae tempor dolor, et pulvinar nulla. Nunc nibh eros, feugiat et vehicula a, tincidunt nec augue.
What's that? You want a bigger image? Ugh. Fine.
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras vitae tempor dolor, et pulvinar nulla. Nunc nibh eros, feugiat et vehicula a, tincidunt nec augue.
I suppose now you want a quote thinger with the image hanging off the bottom. I'll even scale it up so you can see more image/text overlap.
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras vitae tempor dolor, et pulvinar nulla. Nunc nibh eros, feugiat et vehicula a, tincidunt nec augue.
That's it. That's all I have time for. Now go make your own variations.
In the interests of accessibility best practices:
- Pay attention to color contrast between the text and background,
- All of my examples assume left-to-right reading order,
- Do not insert any images that have text to be read or otherwise convey information,
- If you choose to do that anyway, consider adding some alternative text into the HTML itself and then using an off-screen technique to hide it.
If that last bullet confused you, here is an example of what I mean. If you look at the HTML, you will see some text is where the image lives.
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras vitae tempor dolor, et pulvinar nulla. Nunc nibh eros, feugiat et vehicula a, tincidunt nec augue.
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras vitae tempor dolor, et pulvinar nulla. Nunc nibh eros, feugiat et vehicula a, tincidunt nec augue.
Sorry. You probably wanted the image hanging off the box. Got it.
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras vitae tempor dolor, et pulvinar nulla. Nunc nibh eros, feugiat et vehicula a, tincidunt nec augue.
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras vitae tempor dolor, et pulvinar nulla. Nunc nibh eros, feugiat et vehicula a, tincidunt nec augue.