1.1 CSS Layout Concepts Flashcards
Why do developers use normalize css?
It helps your website look consistent across different browsers.
What is normalize CSS changing within
the user agent stylesheet?
It takes away extra margins, paddings, or CSS properties that create implicit rules.
Where is normalize css linked to in the HTML document?
Within the head tag, above author css link.
Why is normalize css document
placed above the developer css file?
The cascading order states that what comes last in CSS,
comes first in actual styling of an element.
How does source order impact the cascade?
When two rules apply that have equal specificity the one that comes last in the CSS is the one that will be used.
What is specificity within cascading order?
Specificity refers to the degree to which rules
are defined in the style.
The more specific, the more it
overrides other style instructions.
How does importance impact cascading order?
Importance is capable of overriding both source and specificity when it comes to source order.
What is the syntax to use importance in CSS?
starts with !
uses word importance
closes with semi colon ;
What does the CSS property Width do?
It controls how wide an element spans the page.
How do you specify the width?
Width can be specified in units or percentages.
What is auto, in a CSS margin context?
The browser calculates the margin for you using auto.
What is a vertical margin collapse?
When items stack, overlap, or lose vertical rhythm
due to a lack of vertical structure.
How do you prevent vertical collapsing?
Add borders,
Add padding
Do horizontal margins collapse?
No
Horizontal margins do not collapse.
Vertical margins can collapse though.
Between mobile, tablet, and desktop,
which is the simplest to develop?
Mobile is the simplest of the three screen sizes.
Do tablet and desktop inherit styling from mobile?
Yes.
What you style in the mobile version can be passed on to other screen sizes to avoid repetition where relevant.
Between mobile, tablet, and desktop,
which has the most restrictions?
Mobile
It’s the smallest in screen size.
What is a sticky footer?
Sticky footer stays at the bottom, regardless of page height.
What is min-height property mean?
It establishes the minimum height of an element.
What is the calc function?
The cal function lets you define an attribute based on simple math. The math is done for you.
What values are typically needed for the calc function?
You typically need to specify the starting and end values for the calc function.
What math symbols does CALC function accept?
+, -, *, /
What direction does inline go?
Left to right
What direction does block go in?
Top to bottom
True or False, do block elements take up the full width of the page?
True
Yes, block elements can take the full width of the space.
Can inline elements stack upon each other? True or false
True
Inline elements appear on the same line as each other.