css-positioning Flashcards

1
Q

What is the default value for the position property of HTML elements?

A

Static flow

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

How does setting position: relative on an element affect document flow?

A

This does not affect the position of surrounding elements; they stay in the position they would be in in normal flow.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

How does setting position: relative on an element affect where it appears on the page?

A

It does not change anything until you add offset properties.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

How does setting position: absolute on an element affect document flow?

A

Removes element that are static.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

How does setting position: absolute on an element affect where it appears on the page?

A

It will look for its closest positioned ancestor

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

How do you constrain an absolutely positioned element to a containing block?

A

Containing block should have a non-static positioning

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What are the four box offset properties?

A

top or bottom and left or right

How well did you know this?
1
Not at all
2
3
4
5
Perfectly