summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Wu <peter@lekensteyn.nl>2014-05-26 15:23:29 +0200
committerPeter Wu <peter@lekensteyn.nl>2014-05-26 15:23:29 +0200
commit1fdc3412b370fb6aeea35733c77187fb81d38901 (patch)
tree9ea4eb800dccce14a8f174e9a093a8b1ec3240dc
parent50775bcb4ca05cc8985eebdeaea6f04da70465cc (diff)
downloadd3viz-1fdc3412b370fb6aeea35733c77187fb81d38901.tar.gz
Split SVG styling to separate file
Might be useful if a SVG element gets exported.
-rw-r--r--spamviz.html31
-rw-r--r--svg.css30
2 files changed, 31 insertions, 30 deletions
diff --git a/spamviz.html b/spamviz.html
index 9f414e8..aef31b3 100644
--- a/spamviz.html
+++ b/spamviz.html
@@ -83,37 +83,8 @@ html, body {
margin: 0;
padding: 0;
}
-/* style for svg contents */
-.node {
- stroke: #fff;
- stroke-width: 0.5px;
-}
-.node.spam {
- fill: orange;
-}
-.node.ham {
- fill: #6c6;
-}
-.node.neighbor {
- fill: #fcc;
-}
-.node.selected {
- fill: #f00;
-}
-.link {
- stroke: #ddd;
- stroke-opacity: .6;
- /* fill none to prevent arcs lines being too thick */
- fill: none;
-}
-.arrow-head {
- fill: #399;
- fill-opacity: .6;
-}
-.link.neighbor {
- stroke: #f99;
-}
</style>
+<link rel="stylesheet" href="svg.css">
<body>
<div id="infobox">
diff --git a/svg.css b/svg.css
new file mode 100644
index 0000000..aca104a
--- /dev/null
+++ b/svg.css
@@ -0,0 +1,30 @@
+/* style for svg contents */
+.node {
+ stroke: #fff;
+ stroke-width: 0.5px;
+}
+.node.spam {
+ fill: orange;
+}
+.node.ham {
+ fill: #6c6;
+}
+.node.neighbor {
+ fill: #fcc;
+}
+.node.selected {
+ fill: #f00;
+}
+.link {
+ stroke: #ddd;
+ stroke-opacity: .6;
+ /* fill none to prevent arcs lines being too thick */
+ fill: none;
+}
+.arrow-head {
+ fill: #399;
+ fill-opacity: .6;
+}
+.link.neighbor {
+ stroke: #f99;
+}