Skip to content

Commit

Permalink
Refs #3; Added more chart examples to the dark theme rendering test.
Browse files Browse the repository at this point in the history
  • Loading branch information
rsandor committed Jul 9, 2014
1 parent a228b11 commit 1f8d49e
Showing 1 changed file with 63 additions and 0 deletions.
63 changes: 63 additions & 0 deletions tests/render/themes/dark.html
Original file line number Diff line number Diff line change
Expand Up @@ -127,13 +127,76 @@ <h2>Category 20c</h2>
});
</script>

<h2>Chart Examples</h2>

<div class="epoch gauge-medium"></div>
<script>
$(function() {
$('.gauge-medium').epoch({ type: 'time.gauge', value: 0.25 });
});
</script>

<div id="pie" class="epoch" style="width: 300px; height: 300px;"></div>
<script>
$(function() {
var data = [],
className = 'category10';

for (var j = 0; j < 10; j++) {
data.push({label: String.fromCharCode(65+j), value: 10});
}

$('#pie').epoch({
type: 'pie',
inner: 80,
data: data
});
});
</script>


<div id="bar" class="epoch" style="height: 220px"></div>
<script>
$(function(){
var data = [
{label: 'A', values: []},
{label: 'B', values: []},
{label: 'C', values: []}
],
length = 10;

for (var i = 0; i < length; i++) {
var x = i * 10 / length;
data[0].values.push({x: x, y: x});
data[1].values.push({x: x, y: 2*x});
data[2].values.push({x: x, y: 3*x});
}

$('#bar').epoch({
type: 'bar',
data: data
});
});
</script>

<div id="line" class="epoch" style="height: 220px"></div>
<script>
$(function() {
var data = [
{ label: 'A', values: [] },
{ label: 'B', values: [] }
],
length = 128;
for (var i = 0; i < length; i++) {
var x = i * 2 * Math.PI / length;
data[0].values.push({x: x, y: x*Math.sin(x)});
data[1].values.push({x: x, y: x*Math.cos(x)});
}
$('#line').epoch({type: 'line', data: data});
});
</script>


<script>
$(function() {
$('div[data-refs-range]').each(function(i, el) {
Expand Down

0 comments on commit 1f8d49e

Please sign in to comment.