---
title: "12 modern CSS one-line upgrades"
publication: "Frontend Focus"
issue: 627
published_at: "2024-01-24"
canonical_url: "https://frontendfoc.us/issues/627"
---

Plus animated sparkly text, and yet more AI for web devs (and Chrome users). |       

Together with [![Sentry logo\](https://res.cloudinary.com/cpress/image/upload/c_fill,g_auto,e_trim,w_350,h_100/e_make_transparent/co_white,e_outline:7/xdmchdxkka938lxfr86f.png)](https://www-git-debugging-workshop.sentry.dev/community/?utm_source=frontendfocus&utm_medium=paid-community&utm_campaign=general-fy24q4-nextjsworkshop&utm_content=newsletter-nextjsworkshop-watch)        

🚀 **Frontend** Focus 

#​627 — January 24, 2024 | [Read on the web](https://frontendfoc.us/issues/627)      

[![\](https://res.cloudinary.com/cpress/image/upload/w_1280,e_sharpen:60,q_auto/v1706097196/swke3kavef8nxt9wg43e.png)](https://moderncss.dev/12-modern-css-one-line-upgrades/)  

[12 Modern CSS One-Line Upgrades](https://moderncss.dev/12-modern-css-one-line-upgrades/) — Here’s a dozen CSS properties that are well worth knowing — these one-line upgrades will help reduce technical debt, remove unnecessary lines of JavaScript, and score some easy wins for user experience, too. Think things like `object-fit`, `scroll-margin`, `accent-color`, etc. 

Stephanie Eckles   [![\](https://copm.s3.amazonaws.com/a96328d7.png)](https://www-git-debugging-workshop.sentry.dev/community/?utm_source=frontendfocus&utm_medium=paid-community&utm_campaign=general-fy24q4-nextjsworkshop&utm_content=newsletter-nextjsworkshop-watch) 

[[Guide\] Debugging Your Next.js App With Sentry](https://www-git-debugging-workshop.sentry.dev/community/?utm_source=frontendfocus&utm_medium=paid-community&utm_campaign=general-fy24q4-nextjsworkshop&utm_content=newsletter-nextjsworkshop-watch) — Get all the basics to monitoring and debugging your Next.js app with Sentry in this [7-part video series.](https://sentry.io/community/?utm_source=frontendfocus&utm_medium=paid-community&utm_campaign=general-fy24q4-nextjsworkshop&utm_content=newsletter-nextjsworkshop-watch) You’ll learn how to instrument your app with Sentry, how to identify a few specific issues, and follow errors from the client to the server. 

Sentry sponsor   

[A Practical Introduction to Scroll-Driven Animations with CSS `scroll()` and `view()`](https://tympanus.net/codrops/2024/01/17/a-practical-introduction-to-scroll-driven-animations-with-css-scroll-and-view/) — Shows us how, with just CSS, we can add scroll animations that toggle shadows on navbars, reveal images, add so-called 'scrolly-telling', link up carousel elements, and more. 

Adam Argyle   

[AI for Web Devs](https://austingil.com/ai-for-web-devs-set-up/) — Austin has just published the last post in this eight part series on using AI in web development, covering prompt engineerings, security, deployment, and more. 

Austin Gil     

⚡️ Quick Links 

- 🤔 Google is [adding experimental AI features to Chrome](https://www.theverge.com/2024/1/23/24047843/google-chrome-browser-ai-organize-tabs-themes) in an effort to help organize and customize the browser.
- 🧑‍🚀 Version [4.2 of Astro is out now](https://astro.build/blog/astro-420/), with a handful of new community-built features.
- 🧭 [Here's what new WebKit features](https://webkit.org/blog/14919/webkit-features-in-safari-17-3/) you can find in Safari 17.3.     

📙 **Tutorials, Articles & Opinion** 

[![\](https://res.cloudinary.com/cpress/image/upload/w_1280,e_sharpen:60,q_auto/v1706096066/tgvuzbyaeysngv2wlsd0.png)](https://www.youtube.com/watch?v=nn3vYS_msc0)  

▶[Modern CSS, The State of the Web, Safari's Progress, and More](https://www.youtube.com/watch?v=nn3vYS_msc0) — Jen Simmons, of the WebKit team, was a guest on Kevin Powell’s channel to talk about all things CSS, web standards, `font-size-adjust`, `margin-trim`, `text-box-trim`, `text-box-edge`, and of course, Safari. 

Kevin Powell   

[Try a Lightning-Fast Pairing Tool Built with You in Mind](https://tuple.app?utm_source=cooperpress&utm_medium=newsletter&utm_campaign=Q1_2024&utm_content=FrontEnd+Focus_Sponsored+Link) — Tuple will change the way you think about pair programming. Try it with your team free for 14 days, no card required. 

Tuple sponsor   

[Learn the `:has()` Selector by Example](https://bejamas.io/blog/learn-css-has-selector-by-examples-top-use-cases/) — Five practical examples of how to use this selector. There’s [a video running through things](https://www.youtube.com/watch?v=VW8tq3rfhUo) too if you’d rather that. 

Mojtaba Seyedi  

[![\](https://res.cloudinary.com/cpress/image/upload/w_1280,e_sharpen:60,q_auto/v1706095263/vfi7om6hhacullvrmgxv.png)](https://www.amitmerchant.com/fading-content-using-transparent-gradients-in-css/)  

[Fading Content using Transparent Gradient in CSS](https://www.amitmerchant.com/fading-content-using-transparent-gradients-in-css/) — A nice effect, and one that’s easily realised. 

Amit Merchant   

✨ However, whilst the effect above does look great, [Kilian Valkhof highlights some downsides](https://polypane.app/blog/my-take-on-fading-content-using-transparent-gradients-in-css/) and shares some solutions that give the pattern a little more flexibility.  

[Better Form UX with the `field-sizing` Property](https://blog.stephaniestimac.com/posts/2024/01/css-field-sizing/) — A look at how the `field-sizing` CSS property could improve web form user experience. 

Stephanie Stimac   

[Design Better Pagination](https://coyleandrew.medium.com/design-better-pagination-a022a3b161e1) — Andrew shares some pagination UI best practices along with some considerations for more complex needs. Lots of visuals here to help things along. 

Andrew Coyle   

[Disable Browser Caching with Meta HTML Tags](https://cristian.sulea.net/blog/disable-browser-caching-with-meta-html-tags/) — Worth knowing (_or at least bookmarking_). 

Cristian Sulea   

[Three Lessons from Building a Chrome Extension with TypeScript](https://shawnsomething.substack.com/p/3-lessons-from-building-a-chrome) 
Shawn Khoo   

[Create a Currency Converter with HTML, CSS, and Vanilla JavaScript](https://webdesign.tutsplus.com/currency-converter-with-html-css-and-vanilla-javascript--cms-108362t) 
Esther Vaati   

▶[Building a Greener Web](https://css-irl.info/video-building-a-greener-web-smashing-meets/) 
Michelle Barker  

🔧 **Code, Tools & Resources** 

[![\](https://res.cloudinary.com/cpress/image/upload/w_1280,e_sharpen:60,q_auto/nf1icbktdsiqkr6rc5yg.jpg)](https://github.com/stefanjudis/sparkly-text)  

✨ [sparkly-text: A Small Web Component for Making Text _Sparkle_](https://github.com/stefanjudis/sparkly-text) — A cute effect that uses animated SVG under the hood. You can see a few examples in [this post](https://www.stefanjudis.com/blog/a-web-component-to-make-your-text-sparkle/). 

Stefan Judis   

[Design Systems Database: A Database of Best-in-Class Design Systems, Organized and Sorted by Components and Directories](https://designsystems.surf/) — Useful for studying the public design systems of well-known technical teams (Adobe, GitHub, MailChimp, Shopify, etc.), divided into systems, directories, components, and blueprints. Handy stuff. 

Ilya Greben   

[Generate and Render Dynamic JSON-Based Forms Right in Your App](https://surveyjs.io/?utm_source=frontend_focus&utm_medium=email) — Self-host SurveyJS UI libraries to design and style forms with a no-code builder that features CSS theme editor and GUI for conditional rules. 

SurveyJS sponsor   

[SVG Filter Maker: A GUI To Interactively Build SVG Filters](https://svgfm.chriskirknielsen.com/) — Not to be confused with CSS filters, this is for building the much more complex SVG filters using the `<filter>` element and one or more of the many filter primitives. 

Christopher Kirk-Nielsen   [![\](https://res.cloudinary.com/cpress/image/upload/w_1280,e_sharpen:60,q_auto/v1706094817/vz4ylz6vip7udnlr2gce.png)](https://codepen.io/nicolasjesenberger/pen/mdomqGR) 

[Wooden Toggles](https://codepen.io/nicolasjesenberger/pen/mdomqGR) — I’m sharing this HTML and CSS CodePen demo just for the skeuomorphic memories it evokes of the texture, depth and ‘[rich Corinthian leather](https://www.macworld.com/article/221261/why-ill-miss-skeuomorphism-in-ios.html)’ found in the early days of iOS. 

Nicolas Jesenberger   

[Typeculator: A Different Approach to Generating Type Scales](https://typeculator.alexpaul.me/) — Based on something called the “Golden Thread” technique, which helps overcome problems like fractional values, challenges with multiple typefaces, etc. 

Alex Paul   

[worker-timers: `setInterval`/`setTimeout` But for Unfocused Windows](https://github.com/chrisguttandin/worker-timers) — When a tab loses focus, any timers used within can be throttled. One solution is to use a Web Worker instead. 

Christoph Guttandin     

🕰️ ICYMI (_Older links, still worth checking out_) 

- [Stephanie Stimac explains](https://blog.stephaniestimac.com/posts/2023/10/css-text-wrap/) when to use CSS `text-wrap: balance;` vs `text-wrap: pretty;`.
- Ever wanted to have a scroll-driven animation run just the _one_ time? [Bramus shows us how here](https://www.bram.us/2023/10/05/run-a-scroll-driven-animation-only-once/).
- Adam Silver [highlights the issue with disabled buttons](https://adamsilver.io/blog/the-problem-with-disabled-buttons-and-what-to-do-instead/), and what to do instead.
- Patricia Egyed shows us [how to create dynamic web experiences by using interactive SVG animations](https://www.sitepoint.com/dynamic-web-experiences-interactive-svg-animations/).
- Preethi Sam shares a look at how to go about [animating along a path in CSS](https://www.smashingmagazine.com/2023/10/animate-along-path-css/).      

☁️ ...and finally  [![\](https://res.cloudinary.com/cpress/image/upload/w_1280,e_sharpen:60,q_auto/v1706017936/jib6fewnlmac8ou0trys.png)](https://spite.github.io/CSS3DClouds/) 

[CSS 3D Clouds](https://spite.github.io/CSS3DClouds/) — This striking demo (from a decade ago) has been doing the rounds this week — it set out to create 3D-like clouds using CSS, transforms, and a touch of JavaScript. The approach to create such a thing now might be a little different, but this result remains good. You can make fluffy clouds, stormy ones, or even go with an over-the-top Michael Bay approach. [Repo here](https://github.com/spite/CSS3DClouds), and there’s [a tutorial](https://www.clicktorelease.com/blog/how-to-make-clouds-with-css-3d/), if you want to look back at how it was put together. 

Jaume Sánchez    

📬 

**Got a new email address?** You can [change your email here](https://frontendfoc.us/edit_subscription/*|UID|*). 

--- 

**Bored of us?** Click [here to stop getting this newsletter](https://frontendfoc.us/leave/*|UID|*). 

--- 

**Got a link for us?** Reply and tell us. We can't include everything but we'll take a look. 

--- 

Published by Cooper Press Ltd.
Curated by [Chris Brandrick](https://mastodon.social/@brandrick) & [Peter Cooper](https://twitter.com/cooperx86).
Fairfield Enterprise Centre, Louth, LN11 0LS, United Kingdom 

[Stop getting this newsletter](https://frontendfoc.us/leave/*|UID|*)  

[Ipx.](https://frontendfoc.us/open/627/*|UID|*?ipx=t)
