W3.CSSLesson 43Free preview
W3.CSS Tags
This lesson is part of W3.CSS · All levels
Summary
Tags are small labels for keywords or content categories, such as article topics. Unlike badges that focus on numbers, .w3-tag is more often inserted in paragraphs or lists. Because of its concise appearance, tags help readers scan topics quickly.
Key points
- .w3-tag displays small labels that align with the surrounding text
- Badge suits the notification number, tag suits the category or keyword
- The background color tag is set to a color class W3.CSS such as .w3-teal
- Pack the tag with <a class="w3-btn"> if you want to be able to click
- Don't pile too many tags because it's actually reducing readability.
Full lesson
Code examples and quizzes
Full lessons, code examples, and quizzes are available to subscribers. 5 questions.