To style the first letter of a block element (a paragraph) or its first line:
p: first-letter {color: red;} p: first-line {color: gray;} context can define relationships between elements: if we define that EM kept within an H1 are gray:
h1 em {color: gray;} Classification of elements:
- Block Elements. Force a line break at the end thereof: paragraphs headings, tables, lists, DIV, BODY.
- inline elements. Links, emphasis, SPAN.
- List items. Contain elements LI.
can change the display of blocks or lists using the display property. You can take the values \u200b\u200bblock, inline, list-item, none (hidden item).
For paragraphs (block elements) get online:
p {display: inline;} Ref:
Programacion.com
0 comments:
Post a Comment