X-Git-Url: https://adrianiainlam.tk/git/?a=blobdiff_plain;ds=inline;f=gallery%2Frange-selector.js;h=09bfd49c32b98280e5e3e6959655ff2d3bdce12c;hb=a907c94dfb7693a6e721c78012bdf36719da0b19;hp=3b13ebb20f3ff01092df61c53ad687fef9cb00eb;hpb=192d58e7c9fab1ae32da4a2dac723955f1639a54;p=dygraphs.git
diff --git a/gallery/range-selector.js b/gallery/range-selector.js
index 3b13ebb..09bfd49 100644
--- a/gallery/range-selector.js
+++ b/gallery/range-selector.js
@@ -11,7 +11,12 @@ Gallery.register(
"
",
"",
"Roll period of 14 timesteps, custom range selector height and plot color.
",
- ""].join("\n");
+ "",
+ "",
+ "",
+ "
Dark background, custom range selector gradient color.
",
+ "
",
+ "
"].join("\n");
},
run: function() {
new Dygraph(
@@ -41,6 +46,26 @@ Gallery.register(
rangeSelectorHeight: 30,
rangeSelectorPlotStrokeColor: 'yellow',
rangeSelectorPlotFillColor: 'lightyellow'
- });
+ }
+ );
+ new Dygraph(
+ document.getElementById("darkbg"),
+ data_temp,
+ {
+ rollPeriod: 14,
+ showRoller: true,
+ customBars: true,
+ title: 'Nightly Temperatures in New York vs. San Francisco',
+ ylabel: 'Temperature (F)',
+ legend: 'always',
+ labelsDivStyles: { 'textAlign': 'right', 'backgroundColor': '#101015' },
+ showRangeSelector: true,
+ rangeSelectorPlotFillColor: 'MediumSlateBlue',
+ rangeSelectorPlotFillGradientColor: 'rgba(123, 104, 238, 0)',
+ axisLabelColor: 'white',
+ colorValue: 0.9,
+ fillAlpha: 0.4
+ }
+ );
}
});