CSS Flashcards

1
Q

How do you flip an image?

A

img:hover {
transform: scaleX(-1);
}

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

how do u break long words and wrap onto the next line?

A

word-wrap

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

what does align-items do

A

align the items inside a flexible container

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

what are selectors? Mention their types

A

.CSS selectors are used to “find” (or select) the HTML elements you want to style.

We can divide CSS selectors into five categories:

Simple selectors (select elements based on name, id, class)
Combinator selectors (select elements based on a specific relationship between them)
Pseudo-class selectors (select elements based on a certain state)
Pseudo-elements selectors (select and style a part of an element)
Attribute selectors (select elements based on an attribute or attribute value)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

how do u Insert something after the content of each <p> element and Insert something before the content of each </p><p> element?</p>

A

::after and ::before

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

Mention few websafe fonts

A

arial , verdana , georgia , courier new , tahoma , times new roman

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

Mention the 5 generic fallback fonts

A

serif , sans serif , monospace , cursive , fantasy

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

write a piece of code to animate the background from red to blue

A

@keyframes mymove {
from {background-color: red;}
to {background-color: blue;}
}

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

what is pc in units?

A

picas

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

conversion from in to px and cm , from pt to int , pc to pt

A

inches (1in = 96px = 2.54cm)
pixels (1px = 1/96th of 1in)
points (1pt = 1/72 of 1in)
picas (1pc = 12 pt)

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

what are the two lengths in css?

A

absolute lengths and relative lengths

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

explain em

A

Relative to the font-size of the element (2em means 2 times the size of the current font)

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

16px = ….. em

A

1 em

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