html and style fixes

This commit is contained in:
Nils Schneider 2012-05-12 17:06:00 +02:00
parent 54e0461471
commit 1fba1a1517
4 changed files with 17 additions and 34 deletions

View file

@ -14,8 +14,3 @@ line.link {
#chart { #chart {
} }
body {
padding: 0;
margin: 0;
}

View file

@ -1,5 +1,18 @@
var w = window.innerWidth, function getOffset( el ) {
h = window.innerHeight - 10, var _x = 0;
var _y = 0;
while( el && !isNaN( el.offsetLeft ) && !isNaN( el.offsetTop ) ) {
_x += el.offsetLeft - el.scrollLeft;
_y += el.offsetTop - el.scrollTop;
el = el.offsetParent;
}
return { top: _y, left: _x };
}
var offset = getOffset(document.getElementById('chart'));
var w = window.innerWidth - offset.left,
h = window.innerHeight - offset.top - 24,
fill = d3.scale.category20(); fill = d3.scale.category20();
var vis = d3.select("#chart").append("svg") var vis = d3.select("#chart").append("svg")

View file

@ -3,36 +3,12 @@
<link rel="stylesheet" href="theme/default/style.css" type="text/css" /> <link rel="stylesheet" href="theme/default/style.css" type="text/css" />
<style type="text/css"> <style type="text/css">
body, html {
margin: 0; padding: 0;
}
#map { #map {
float: left; float: left;
width: 80%; width: 100%;
box-sizing:border-box; box-sizing:border-box;
}
#infobox {
box-sizing:border-box;
width: 20%;
vertical-align: top;
float: right;
padding: 1em;
}
body {
font:80%/100% 'helvetica neue',sans-serif,'arial';
color: #666;
}
h2 {
margin: 0 0 1em;
color: #f60;
}
li {
margin-bottom: 0.5em;
}
ul {
padding-left: 2em;
} }
.olPopup p { margin:0px; } .olPopup p { margin:0px; }
</style> </style>

View file

@ -11,8 +11,7 @@
<li><a href="geomap.html">Knotenkarte</a></li> <li><a href="geomap.html">Knotenkarte</a></li>
</ul> </ul>
<h2>Knotenkarte</h2> <h2>Knotenkarte</h2>
<div id="map"></div> <div id="chart"></div>
<div id='chart'> </div>
<link href='force.css' rel='stylesheet' type='text/css' /> <link href='force.css' rel='stylesheet' type='text/css' />
<script type="text/javascript" src="d3.js"></script> <script type="text/javascript" src="d3.js"></script>
<script src='d3.layout.js' type='text/javascript'> </script> <script src='d3.layout.js' type='text/javascript'> </script>