Programmatically generate SVG (vector) images, animations, and interactive Jupyter widgets
1<?xml version="1.0" encoding="UTF-8"?> 2<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" 3 width="200" height="100" viewBox="0 0 200 100"> 4<defs> 5<linearGradient x1="0" y1="0" x2="1" y2="0" gradientUnits="objectBoundingBox" id="mask10"> 6<stop offset="0" stop-color="white" /> 7<stop offset="1" stop-color="black" /> 8</linearGradient> 9<mask id="mask11"> 10<rect x="30" y="0" width="100" height="100" fill="url(#mask10)" /> 11</mask> 12</defs> 13<rect x="0" y="0" width="200" height="100" fill="cyan" stroke="blue" stroke-width="2" /> 14<rect x="0" y="0" width="200" height="100" fill="pink" stroke="red" stroke-width="2" mask="url(#mask11)" /> 15</svg>