forked from scotthmurray/scattered-scatterplot
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path03_svg.html
More file actions
executable file
·37 lines (30 loc) · 913 Bytes
/
Copy path03_svg.html
File metadata and controls
executable file
·37 lines (30 loc) · 913 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>D3: SVG</title>
<script type="text/javascript" src="d3.v3.js"></script>
<style type="text/css">
body {
background-color: gray;
}
svg {
background-color: white;
}
</style>
</head>
<body>
<svg width="400" height="400">
<line x1="4" y1="10" x2="190" y2="190" stroke="teal" stroke-width="2" />
<line x1="190" y1="190" x2="400" y2="0" stroke="teal" stroke-width="2" />
<rect x="200" y="10" width="100" height="100" fill="salmon" />
<circle cx="275" cy="115" r="25" fill="red" />
<circle cx="300" cy="140" r="25" fill="blue" />
<circle cx="250" cy="140" r="25" fill="yellow" />
<text x="250" y="100" fill="charcoal" font-size="36" font-weight="bold">Sample image</text>
</svg>
<script type="text/javascript">
// Your beautiful D3 code will go here
</script>
</body>
</html>