Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Shapes with SVG and CSS

Public visualization

Shapes with SVG and CSS

0 stars1🌍 Public
YYanda Qu
Last edited Jan 27, 2021
Created on Jan 25, 2021
Forked from HTML Cars Report

This example demonstrates basic SVG shapes—circles, rectangles, lines, and a path—stylized via CSS classes and inline attributes. It shows how shape properties like fill, stroke, and stroke-width can be set directly or inherited through grouped elements, with the `g` element using `translate` and `scale` transforms to reposition and enlarge the drawing. The code uses plain SVG APIs and CSS selectors, such as `.lines path` for path-specific styling, without any external JavaScript libraries. The rendering is entirely static, relying on the SVG markup and stylesheet for visual output.

AI-generated description

Comments

Sign in to join the discussion.

MIT Licensed