CSS Flashcards

1
Q

Inline, Internal, External CSS

A

Inline - defined in the same HTML tag
Internal - defined in the HTML header and within style (open+close) tag.
External - External stylesheet linked to HTML in the header.

External CSS is the way to go, Internal and Inline CSS are frowned upon.

Priority
Inline CSS&raquo_space; Internal CSS&raquo_space; External CSS

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

Debugging CSS

A

Usually its an exercise between looking at browser console and checking if the elements that you are targeting are changing appearances.

Most of the time, its either syntax error, or pointing to the wrong file location.

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

CSS selectors

A

class = “some-class -here”
id=”some-id-here”
HTML tag itself.

These are defined in HTML (not in CSS) and can be used to target specific elements in CSS.

To target class - .some-class-here { }
To target id - #some-id-here { }
To target a HTML tag - body { }

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

Favicons

A

Inserted at the header of HTML.
Used to give your web page an icon that shows besides your web page title.

Also uses a ‘link’ tag with a rel=”icon” tag after it.

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

Positioning

A

Static, Relative, Absolute, Fixed and Sticky.

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

display property CSS

A

Block, Inline-block, Flex, none.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q
color
font-weight
line-height
font-size
letter-spacing
text-transform
A

All of these affect the fonts in HTML.

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

z-index

A

Manually declare height of an HTML element when they have been POSITIONED.

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

Media query

A

@media (query-without-brackets) and (condtions-w/o-brackets) and so on
{ code here }

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

Combining selector

A

.class-name1 .class-name2 - this selects the class with class-name2 inside class-name1

HTMLtag.class-name - this selects the HTML tag with the class name as ‘class-name’

.class-name1 ~ .class-name2 - Selects all the class with name .class-name2 coming after .class-name1.

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

Selector Priority

A

id&raquo_space; class&raquo_space; HTML tag.

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