惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

人人都是产品经理
人人都是产品经理
D
Docker
GbyAI
GbyAI
B
Blog RSS Feed
博客园 - 司徒正美
博客园 - Franky
美团技术团队
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
aimingoo的专栏
aimingoo的专栏
C
Check Point Blog
IT之家
IT之家
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
www.infosecurity-magazine.com
www.infosecurity-magazine.com
AI
AI
O
OpenAI News
Attack and Defense Labs
Attack and Defense Labs
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
T
Tailwind CSS Blog
酷 壳 – CoolShell
酷 壳 – CoolShell
S
Secure Thoughts
博客园 - 聂微东
L
LINUX DO - 最新话题
U
Unit 42
SecWiki News
SecWiki News
A
Arctic Wolf
Schneier on Security
Schneier on Security
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
V
Visual Studio Blog
量子位
The Cloudflare Blog
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
大猫的无限游戏
大猫的无限游戏
Google DeepMind News
Google DeepMind News
G
Google Developers Blog
T
Threat Research - Cisco Blogs
TaoSecurity Blog
TaoSecurity Blog
Recent Commits to openclaw:main
Recent Commits to openclaw:main
B
Blog
博客园 - 【当耐特】
C
CERT Recently Published Vulnerability Notes
Scott Helme
Scott Helme
Last Week in AI
Last Week in AI
D
Darknet – Hacking Tools, Hacker News & Cyber Security
Microsoft Security Blog
Microsoft Security Blog
Apple Machine Learning Research
Apple Machine Learning Research
F
Full Disclosure
Hacker News: Ask HN
Hacker News: Ask HN
A
About on SuperTechFans
博客园 - 三生石上(FineUI控件)
Latest news
Latest news

Stuff & Nonsense Blog feed

The camera that took me places - Stuff & Nonsense Last week in the studio (CW27-26) - Stuff & Nonsense Last week in the studio (CW26-26) - Stuff & Nonsense Tracking down a nasty Netlify bandwidth burner - Stuff & Nonsense Last week in the studio (CW25-26) - Stuff & Nonsense Eleventy in a Box. A premium Eleventy start kit - Stuff & Nonsense Migrating from Statamic to Eleventy. This site’s had major surgery - Stuff & Nonsense Last week in the studio (CW24-26) - Stuff & Nonsense Last week in the studio (CW21-26) - Stuff & Nonsense Last week in the studio (CW20-26) - Stuff & Nonsense Last week in the studio (CW19-26) - Stuff & Nonsense Websites shouldn’t need maintenance. They need momentum. - Stuff & Nonsense Making my view options toolbar more intuitive - Stuff & Nonsense Unfinished Business #142: The perfect request for proposal - Stuff & Nonsense Last week in the studio (CW18-26) - Stuff & Nonsense Militant masthead logo (r)evolution - Stuff & Nonsense Eleventy in a Box just add water - Stuff & Nonsense Last week in the studio (CW17-26) - Stuff & Nonsense Last week in the studio (CW16-26) - Stuff & Nonsense Far Right So Wrong; Stop Reform t-shirts are back in my shop - Stuff & Nonsense Last week in the studio (CW15-26) - Stuff & Nonsense I got tired of correcting machines, so I gave them five rules - Stuff & Nonsense How I designed an information-rich website for The Shared Homeland Paradigm - Stuff & Nonsense A bold new website for the Academy of Scoring Arts - Stuff & Nonsense
I added a spring mode to my animated SVG landscape - Stuff & Nonsense
Andy Clarke, Stuff & Nonsense Ltd. · 2026-04-19 · via Stuff & Nonsense Blog feed

I’ve added a “spring mode” to my animated SVG desert. Flowers bloom, colours shift, and the whole scene feels more alive—all without creating a separate version. Instead, I’m layering changes on top of the same SVG and letting CSS and JavaScript do the work.

Flowers are blooming on my website, courtesy of a new ‘Spring mode,’ which adds new colours and animations. Spring’s definitely sprung, and it’s a wonderful time to be in the desert.

My spring home page graphic animation

Visit my home page to see this in action. Flowers bloom on the cacti and between the craggy rocks, turning a dry landscape into something more alive.

Instead of creating a separate version of the animated SVG scene, I treated spring as a new layer of behavioural and visual changes and applied it to the same SVG. That meant I could reuse the structure and progressively enhance it with animation, colour, and details.

How I layered seasonal changes in SVG

Adding spring to my animated SVG landscape meant introducing a few new layers:

  • A static layer to recolour the background
  • Blue, purple, red, white, and yellow flowers

The static layer sits above the base illustration. It lightens the clouds, shifts the sky to blue, and warms the rocks into sandier tones. I treat this as a seasonal mode or reusable layer that changes how the same SVG looks and behaves without duplicating it.

Summer background colours
Spring background colours

I’m layering changes on top, keeping everything flexible and making maintenance easier. This isn’t just about SVG; JavaScript controls the state, and CSS defines how it looks.

Spring mode flowers

How the mode works

JavaScript determines which mode the animated SVG scene is in. It handles switching, prepares the flowers, and remembers a visitor’s choice when they return. CSS handles how that mode looks—changing colours, revealing elements, and animating them into view. This all hinges on adding a spring-mode class to my SVG.

How flowers are animated

Flowers are hidden by default and become visible when spring mode is active. JavaScript assigns each flower a slightly different delay, so they appear in a scattered sequence across the landscape without an obvious pattern. Each flower starts hidden and scaled down:

opacity: 0;
scale: 0;
visibility: hidden;

When spring mode is active and motion is allowed, the flowers play a short “pop” animation:

@media (prefers-reduced-motion:no-preference) {
#svg-large[data-animations=on].spring-mode .spring-flower {
animation-delay:var(--flower-delay,0s);
animation-duration:1.1s;
animation-fill-mode:both;
animation-name:spring-flower-pop;
animation-timing-function:cubic-bezier(.2,1.45,.35,1); }
}

The animation slightly overshoots before settling, giving a gentle, organic feel:

@keyframes spring-flower-pop {
0% {opacity:0;scale:0;visibility:hidden; }
70% {opacity:1;scale:1.06;visibility:visible; }
100% {opacity:1;scale:1;visibility:visible}; }
}

Respecting reduced motion

Animations only run when visitors haven’t asked for reduced motion. If they have, flowers appear without animation. It’s a small detail, but it keeps the experience inclusive without compromising the design.

The result

Spring mode off
Spring mode on

Use the flower button to toggle spring mode and see how these layers transform the scene.

Why this approach works

Treating spring as a mode rather than a separate design keeps everything lightweight and flexible. I can evolve the same SVG over time by adding seasonal or thematic variations without rebuilding it from scratch.

Plus, I love that these animated SVGs keep giving me new ways to play with my website.


April 18, 2026 • Andy Clarke • animationcsssvg

You might also like