CSS Zen Garden(csszengarden.com) A demonstration of what can be accomplished through CSS-based design. Select any style sheet from the list to load it into this page.
Default styles for h1 elements are changing(mozilla.org) Browsers are starting to roll out changes in default UA styles for nested section headings. Developers should check that their sites don't rely on UA styles for certain cases to avoid unexpected results and failing Lighthouse checks. In this post, we'll have a look at what the incoming changes are, how to identify if it's an issue on your pages, and some hints for conformant and better-structured websites.
368 points by soheilpro 24 days ago | 264 comments
Better typography with text-wrap pretty(webkit.org) Support for text-wrap: pretty just shipped in Safari Technology Preview, bringing an unprecedented level of polish to typography on the web. Let’s take a look at what the WebKit version of pretty does — it’s probably a lot more than you expect. Then, we’ll compare it to balance and the other text-wrap values to better understand when to use which one.
364 points by todsacerdoti 26 days ago | 153 comments
Dark mode with almost no CSS(feep.dev) Feep! now has a dark mode theme! The stylesheet for the site is a fairly minimal set of overrides on top of the browser default stylesheet, so adding this support was actually pretty straightforward, though there were a few complications.
CSS-Only Glitch Effect(muffinman.io) Let me show you how I created a CSS-only image glitch effect. I was working on the robot poet and wanted my robotic bard to glitch - because it felt fitting given the quality of poetry it generates.
15 points by todsacerdoti 31 days ago | 1 comments
Item Flow, Part 1: A new unified concept for layout(webkit.org) CSS Grid and Flexbox brought incredible layout tools to the web, but they don’t yet do everything a designer might want. One of those things is a popular layout pattern called “masonry” or “waterfall,” which currently still requires a Javascript library to accomplish.
Minding the gaps: A new way to draw separators in CSS(windows.com) Drawing separator lines between various sections of a webpage is a common design technique, which can help to structure the content and make it more readable, as well as more aesthetically pleasing.
Take a New Look at CSS Shapes (2018)(smashingmagazine.com) This week, CSS Shapes ships in a production version of Firefox with the release of Firefox 62 — along with a very nice addition to the Firefox DevTools to help us work with Shapes.
Privacy and the :visited selector(mozilla.org) Before about 2010, the CSS :visited selector allowed websites to uncover a user's browsing history and figure out what sites the user had visited. This was done through window.getComputedStyle and other techniques. This process was quick to execute, and made it possible not only to determine where the user had been on the web, but could also be used to guess a lot of information about the user's identity.
5 points by spaghetti-code 54 days ago | 1 comments
You suck at CSS and that's okay (2022)(rexriepe.com) This book is about writing CSS. It's also about not writing CSS. It's aimed at people who want to learn CSS, people who want to avoid CSS, amateurs, professionals and everyone in-between. The book aims to provide context as to why CSS and the design ecosystem surrounding it are the way they are. It's written to support the California Stylesheets CSS framework.
Functions in CSS?(css-tricks.com) A much-needed disclaimer: You (kinda) can use functions now! I know, it isn’t the most pleasant feeling to finish reading about a new feature just for the author to say “And we’ll hopefully see it in a couple of years”. Luckily, right now you can use an (incomplete) version of CSS functions in Chrome Canary behind an experimental flag, although who knows when we’ll get to use them in a production environment.
Knowing CSS is mastery to front end development(helloanselm.com) There are countless articles why developers should not focus on Frameworks too much and instead learn to understand the underlying languages. But I think rarely we can find good reasons except that Frameworks come and go. To me, the main reason is different: You won’t be a master at frontend development if you don’t understand underlying mechanisms of a language.
163 points by OuterVale 73 days ago | 167 comments
The difference between zoom and scale(css-tip.com) Do you know the zoom property? It works the same way as a scale transformation but unlike scale, it affects the page layout. In other words, the page layout is recalculated considering the new dimension of the scaled element.