Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Mastering CSS

You're reading from   Mastering CSS A guided journey through modern CSS

Arrow left icon
Product type Paperback
Published in Oct 2017
Publisher Packt
ISBN-13 9781787281585
Length 522 pages
Edition 1st Edition
Languages
Tools
Concepts
Arrow right icon
Author (1):
Arrow left icon
Rich Finelli Rich Finelli
Author Profile Icon Rich Finelli
Rich Finelli
Arrow right icon
View More author details
Toc

Table of Contents (12) Chapters Close

Preface 1. CSS Foundations 2. Ramping Up FREE CHAPTER 3. Creating a Page Layout with Floats 4. Creating Buttons with Modular, Reusable CSS Classes, and CSS3 5. Creating the Main Navigation and Drop-Down Menu 6. Becoming Responsive 7. Web Fonts 8. Workflow for HiDPI Devices 9. Flexbox, Part 1 10. Flexbox, Part 2 11. Wrapping Up

Multiple classes

To recap, so far you've learned how to create a class that can be reused anywhere on our web page in order to create a button. However, buttons tend to vary across a website. You may have, for instance, buttons like: Okay, Close, Cancel, Submit, and Add to cart. All of which have different meanings so are all colored or styled slightly differently. In some scenarios, as in the case of our movies and index pages, the buttons just end up varying based on the page that they're on because of the layout differences between the pages. In this section, we'll get even more modular and learn how to use multiple classes in order to change the appearance of our buttons. We'll look at a few examples of how multiple classes can provide us some affordances in regard to styling our buttons throughout the site.

The following screenshot illustrates the final...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime