Skip to main content
100%

Fork of Shapes and Colors with SVG and CSS

✓ Published0🌍 Public
AAbdullah Andrabi
Last edited Apr 2, 2024
Created on Apr 2, 2024

This example demonstrates basic SVG shapes—circles, rectangles, lines, and paths—styled with CSS using inline attributes and classes. It shows how the same geometry changes appearance through fills, strokes, stroke-widths, and the `transform` attribute for scaling and translation. The code uses raw SVG in an HTML document with an external stylesheet, applying presentation attributes like `fill` and `stroke` directly on elements and grouping them with `<g>` tags. The `.lines` class in CSS defines stroke properties for the line and path elements.

AI-generated description

An example including some commonly used features of SVG.

MIT Licensed

Similar vizzes