Jump to content

margin-inline and padding-inline?

Go to solution Solved by duncannah,

Inline margin and padding follow the text's writing direction and orientation. It has two directions: start and end.

So for example, for regular English text (Left to right, horizontal), start would be the equivalent of margin/padding left, and end would be the equivalent of right.

 

image.thumb.png.7c63dfde2ee0f0db2fba68fb973d5eb6.png

.container{

max-width:1180px;

margin-inline:auto; /*container centre*/

padding-inline:var(--padding-inline-section)

}

They're shorthand for margin-inline-start and margin-inline-end. But simply, what do they mean? In terms of padding/margin left, right, top and bottom? I tried looking MDN docs but wasn't clear from there.

Link to comment
https://linustechtips.com/topic/1469942-margin-inline-and-padding-inline/
Share on other sites

Link to post
Share on other sites

Inline margin and padding follow the text's writing direction and orientation. It has two directions: start and end.

So for example, for regular English text (Left to right, horizontal), start would be the equivalent of margin/padding left, and end would be the equivalent of right.

 

image.thumb.png.7c63dfde2ee0f0db2fba68fb973d5eb6.png

🙂

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×