ButtonsLesson 104Free preview
Social Media Buttons
This lesson is part of How To · All levels
Summary
A social media button is a button-style link that leads to a profile or a sharing page on a social platform. The buttons typically combine icons, short text, and the platform's distinctive colors to make them easily recognizable. Since the function is moving, the proper element is the anchor, not the form button.
Key points
- Use the <a> element because the main action opens the link.
- The icon and the platform's distinctive colors help the identifier, but the text contrast is maintained.
- Display: inline-flex makes it easy to arrange icons and text in one line.
- The link that opens the new tab should use the noopener.
- Provide text labels or labels so that the purpose of the link is clear.
Full lesson
Code examples and quizzes
Full lessons, code examples, and quizzes are available to subscribers. 5 questions.