Ukiyo-e Woodblock
Rain Lines
96 diagonal rain streaks fall over layered indigo/coral hill bands and a village silhouette beneath a bokashi cream sky with a pale moon disc.
canvasmedium complexitymoderate motion
Open on the canvas to copy the code → Free account · 3 copies a day · membership goes unlimited
Worth keeping?
Votes steer what gets built next — sign in to cast one, free to read
When to use it
Ambient backgrounds for Japanese-aesthetic projects, portfolio headers, or calm looping screensavers on dark-themed pages.
When not to
Light backgrounds (sky hardcoded cream/navy). Contexts where moving rain competes with legible text overlays.
Working with an AI agent
Every component ships agent-ready metadata. An example instruction for this one:
Increase rain streak count to 150 by changing N=96 to N=150, shift the rain to a warmer white by changing RAIN to "#f5e8d0", and slow fall speed by changing rs[i]=0.45+Math.random()*0.55 to rs[i]=0.25+Math.random()*0.35. Theme: dark tokens live in :root, the light variant in :root[data-theme="light"]; ?theme=light or a {type:'forever:theme'} postMessage switches at runtime.
Safe to edit
- rain count (N=96)
- rain slant (SLOPE=0.34)
- rain color (RAIN variable)
- fall speed range (rs[i] = 0.45+random*0.55)
- hill band positions (H*0.50..H*0.80)
- palette constants (SKY_TOP, CORAL, HILL1, etc.)
- theme tokens (:root dark defaults + [data-theme=light] overrides)
Keep intact
- IIFE wrapper
- prefers-reduced-motion static frame guard
- visibilitychange stop/start
- DPR-aware canvas resize
- theme hook (?theme= bootstrap + forever:theme message listener + theme tokens)
Known limitations
- Background and sky colors are hardcoded — must edit palette constants to change overall tone
- Village roofline positions use deterministic pseudo-random math — altering M changes the silhouette unpredictably
More Ukiyo-e Woodblock components
- Wave CrestA stylized ukiyo-e-inspired cresting wave with curling foam claws, an indigo sea gradient, Fuji-like cone, and coral sun — all drawn procedurally on canvas.
- Crane Glide7 cranes with flapping wings glide across flat indigo/teal bands past a coral sun and Mt. Fuji silhouette, with scrolling wave crests.
- Blossom Fall110 sakura petals drift and flutter down over an indigo-to-coral bokashi sky with a stylised woodblock mountain and bare branch silhouette.
- Mountain ConeSnow-capped Fuji cone under a bokashi sky cycling night-dawn-day-dusk every 24s; sun/moon disc arcs overhead while 7 cranes drift across.
- Koi RippleA kohaku koi undulates across a dark pond as four concentric ripple rings expand and coral petals drift, all rendered in woodblock palette.
- Bamboo SwayNine indigo bamboo stalks sway with sine-wave lean and leaf flicker against a cream bokashi sky and low coral moon, rendered in flat woodblock style.