InterviewSolution
Saved Bookmarks
| 1. |
What are Pseudo elements and Pseudo classes? |
|
Answer» Pseudo-elements allows US to create items that do not normally exist in the document tree, for example ::after.
In the below example, the color will appear only on the first line of the paragraph. p: :first-line { color: #ffOOOO; font-variant: small-caps;}Pseudo-classes SELECT regular elements but under certain conditions like when the user is hovering over the link.
Example of the pseudo-class, In the below example, the color applies to the anchor tag when it’s HOVERED. /* mouse over link */a:hover { color: #FFOOFF;} |
|