justify-content and align-items Lose Items - Deepstash

justify-content and align-items Lose Items

There is a problem that is especially common with vertical positioning. This is due to the way these properties work. The fact is that the justify-content and align-items properties ignore the size of flex items & they will go beyond its borders and may not be displayed correctly.

For example a modal window with a cross button beyond the window, which makes it unavailable. You need to zoom out of the page to close it.

It can be solved by using the margin property set to auto. Inside a flex container, the auto value will be calculated based on the size of the container and its flex items.

6

17 reads

CURATED FROM

IDEAS CURATED BY

sunnyprakash

Stashing some smashing ideas along the way.

The idea is part of this collection:

Machine Learning With Google

Learn more about computerscience with this collection

Understanding machine learning models

Improving data analysis and decision-making

How Google uses logic in machine learning

Related collections

Read & Learn

20x Faster

without
deepstash

with
deepstash

with

deepstash

Personalized microlearning

100+ Learning Journeys

Access to 200,000+ ideas

Access to the mobile app

Unlimited idea saving

Unlimited history

Unlimited listening to ideas

Downloading & offline access

Supercharge your mind with one idea per day

Enter your email and spend 1 minute every day to learn something new.

Email

I agree to receive email updates