Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Fork of Fork of Fork of Let's make a face with D3.js!

Public visualization

Viewing a saved revision (read-only)

cbe6df89af7e48529df3ca09b5a7b214

Fork of Fork of Fork of Let's make a face with D3.js!

0 stars1🌍 Public
NNavaneeth-Ragi
Last edited Feb 23, 2023
Created on Feb 23, 2023

A D3.js smiley face, built from SVG primitives, demonstrates fundamental DOM manipulation and transitions. A green circle forms the head, with two dark circles for eyes and an orange arc for the mouth, all positioned using geometric constants. The animation shows both rectangular eyebrows moving up and down together via chained `transition().duration()` calls that modify their container's `transform` attribute. The code uses D3 v5 selections and the `arc` generator to construct the mouth path, with all elements grouped and translated to the SVG center for easy positioning.

AI-generated description

Demonstrates fundamental DOM manipulation using D3.js by making a smiley face whose eyebrows move.