CSS Master
383 Pages
English

CSS Master

-

Description

CSS Master is tailor-made for the web designer who's really serious about taking their skills to the next level. Discover how to keep ahead of the game by adhering to best practice and employing the most effective cutting-edge CSS techniques.


  • Organize your CSS to create the most efficient and most maintainable code
  • Discover advanced layout techniques: grid layouts, multi-column, table layout mode, and more
  • Use advanced effects: transitions, transforms, filter effect, and animations
  • Take advantage of pre- and post-processors to maximize your efficiency
  • Combine CSS and SVG to create seriously powerful effects

Subjects

Informations

Published by
Published 22 September 2015
Reads 202
EAN13 9781457193033
Language English
Document size 10 MB

Legal information: rental price per page €. This information is given for information only in accordance with current legislation.

CSS CSS MASTER BYTIFFANY B. BROWN CSS MASTER
ORGANIZED, EFFICENT, POWERFUL–CSS DONE RIGHT!
Safety Area:All Text, Logos & Barcode should remain inside the Pink Dotted Lines BleedArea:AllBackgroundsshouldextendto,butnotpast,theBlueDottedLines
Summary of Contents
Preface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xvii 1. Selectors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 2. CSS Architecture and Organization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71 3. Debugging and Optimization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 95 4. Complex Layouts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 129 5. Transitions and Animation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 189 6. CSS Transforms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 223 7. Applying CSS Conditionally . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 277 8. Using CSS with SVG . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 305 9. Preprocessors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 329 10. Conclusion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 351
CSS MASTER BYTIFFANY B. BROWN
iv
CSS Master by Tiffany B. Brown
Copyright©2015 SitePoint Pty. Ltd.
Product Manager: Simon Mackie Technical Reviewer: Rachel Andrew
English Editor: Ralph Mason Cover Designer: Alex Walker
Notice of Rights All rights reserved. No part of this book may be reproduced, stored in a retrieval system or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of brief quotations embodied in critical articles or reviews.
Notice of Liability The author and publisher have made every effort to ensure the accuracy of the information herein. However, the information contained in this book is sold without warranty, either express or implied. Neither the authors and SitePoint Pty. Ltd., nor its dealers or distributors will be held liable for any damages to be caused either directly or indirectly by the instructions contained in this book, or by the software or hardware products described herein.
Trademark Notice Rather than indicating every occurrence of a trademarked name as such, this book uses the names only in an editorial fashion and to the benefit of the trademark owner with no intention of infringement of the trademark.
Published by SitePoint Pty. Ltd.
48 Cambridge Street Collingwood VIC Australia 3066 Web: www.sitepoint.com Email: business@sitepoint.com
ISBN 9780994182623 (print)
ISBN 9780994346940 (ebook) Printed and bound in the United States of America
About Tiffany B. Brown
Tiffany B. Brown is a freelance web developer and writer based in Los Angeles, California. She has worked on the web for more than a decade, for a mix of media companies and agencies. Brown is also a coauthor of SitePoint's "Jump Start: HTML5." Before founding her consultancy, Webinista, Inc, she was part of the Opera Software Developer Relations & Tools team. Now she offers web development and consulting services to agencies and small design teams.
About SitePoint
SitePoint specializes in publishing fun, practical, and easytounderstand content for web professionals. Visit http://www.sitepoint.com/ to access our blogs, books, newsletters, articles, and community forums. You’ll find a stack of information on JavaScript, PHP, Ruby, mobile development, design, and more.
v
To Molly H.
Table of Contents
Prefacexvii. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Who Should Read This Book . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xvii Conventions Used . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xviii Code Samples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xviii Tips, Notes, and Warnings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xix Supplementary Materials . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xix Want to take your learning further? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xx
Chapter 1Selectors1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Combinators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2 The Descendant Combinator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 The Child Combinator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7 The Adjacent Sibling Combinator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 The General Sibling Combinator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 Attribute Selectors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 Matching Attribute Presence . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 Matching Hyphenated Attribute Values . . . . . . . . . . . . . . . . . . . . . . 14 Matching Attribute Values by Substring . . . . . . . . . . . . . . . . . . . . . . 17 Pseudoclasses versus Pseudoelements . . . . . . . . . . . . . . . . . . . . . . . . . . 19 Pseudoelements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 ::beforeand::after. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 Creating Typographic Effects with::firstletter. . . . . . . . . . 23 Creating Typographic Effects with::firstline. . . . . . . . . . . . 31 User Interface Fun with::selection. . . . . . . . . . . . . . . . . . . . . . 35 Pseudoclasses . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38 Highlighting Page Fragments with:target. . . . . . . . . . . . . . . . . . 38 Negating Selectors with:not(). . . . . . . . . . . . . . . . . . . . . . . . . . . . 42