]> git.ipfire.org Git - thirdparty/Chart.js.git/commitdiff
Fix some errors with docs that were noticed when building 2.0.0-beta2
authorEvert Timberg <evert.timberg@gmail.com>
Mon, 28 Dec 2015 13:29:54 +0000 (08:29 -0500)
committerEvert Timberg <evert.timberg@gmail.com>
Mon, 28 Dec 2015 13:29:54 +0000 (08:29 -0500)
docs/01-Scales.md
docs/04-Radar-Chart.md
docs/07-Advanced.md

index 5bcab3303abd1574ff311303c7cd0f61470e05c5..9af33818b9ca9a56adebc7d1b601c84703582fc3 100644 (file)
@@ -1,14 +1,13 @@
 ---
-title: Getting started
+title: Scales
 anchor: scales
 ---
 
-###Scales
-
 Scales in v2.0 of Chart.js are significantly more powerful, but also different than those of v1.0.
-- Multiple x & y axes are now supported.
-- A built-in label auto-skip feature now detects would-be overlapping ticks and labels and removes every nth label to keep things displaying normally.
-- Scale titles are now supported
+* Multiple x & y axes are now supported.
+* A built-in label auto-skip feature now detects would-be overlapping ticks and labels and removes every nth label to keep things displaying normally.
+* Scale titles are now supported
+* New scale types can be extended without writing an entirely new chart type
 
 Every scale extends a core scale class with the following options:
 
@@ -82,7 +81,7 @@ The `callback` method may be used for advanced tick customization. The following
 }
 ```
 
-#### Category Scale
+### Category Scale
 The category scale will be familiar to those who have used v1.0. Labels are drawn in from the labels array included in the chart data.
 
 The category scale extends the core scale class with the following tick template:
@@ -93,7 +92,7 @@ The category scale extends the core scale class with the following tick template
 }
 ```
 
-#### Linear Scale
+### Linear Scale
 The linear scale can be used to display numerical data. It can be placed on either the x or y axis. The scatter chart type automatically configures a line chart to use one of these scales for the x axis.
 
 The linear scale extends the core scale class with the following tick template:
@@ -130,7 +129,7 @@ The linear scale extends the core scale class with the following tick template:
 }
 ```
 
-#### Logarithmic Scale
+### Logarithmic Scale
 The logarithmic scale is used to display logarithmic data of course. It can be placed on either the x or y axis.
 
 The log scale extends the core scale class with the following tick template:
@@ -152,7 +151,7 @@ The log scale extends the core scale class with the following tick template:
 }
 ```
 
-#### Time Scale
+### Time Scale
 The time scale is used to display times and dates. It can be placed on the x axis. When building its ticks, it will automatically calculate the most comfortable unit base on the size of the scale.
 
 The time scale extends the core scale class with the following tick template:
@@ -229,7 +228,7 @@ The following time measurements are supported:
 }
 ```
 
-#### Radial Linear Scale
+### Radial Linear Scale
 The radial linear scale is used specifically for the radar chart type.
 
 The radial linear scale extends the core scale class with the following tick template:
index d20cdc850c42bff2f5de312c1a8d0128a3b86849..358b2ee40b37622c8c5e4a41fce51f0c9f2c51f3 100644 (file)
@@ -3,7 +3,7 @@ title: Radar Chart
 anchor: radar-chart
 ---
 
-###Introduction
+### Introduction
 A radar chart is a way of showing multiple data points and the variation between them.
 
 They are often useful for comparing the points of two or more different data sets.
@@ -12,7 +12,7 @@ They are often useful for comparing the points of two or more different data set
        <canvas width="250" height="125"></canvas>
 </div>
 
-###Example usage
+### Example usage
 
 ```javascript
 var myRadarChart = new Chart(ctx, {
@@ -22,7 +22,7 @@ var myRadarChart = new Chart(ctx, {
 });
 ```
 
-###Data structure
+### Data structure
 ```javascript
 var data = {
        labels: ["Eating", "Drinking", "Sleeping", "Designing", "Coding", "Cycling", "Running"],
@@ -52,10 +52,10 @@ var data = {
 ```
 For a radar chart, to provide context of what each point means, we include an array of strings that show around each point in the chart.
 For the radar chart data, we have an array of datasets. Each of these is an object, with a fill colour, a stroke colour, a colour for the fill of each point, and a colour for the stroke of each point. We also have an array of data values.
-
 The label key on each dataset is optional, and can be used when generating a scale for the chart.
 
-### Chart options
+
+### Chart Options
 
 These are the customisation options specific to Radar charts. These options are merged with the [global chart configuration options](#getting-started-global-chart-configuration), and form the options of the chart.
 
@@ -91,4 +91,3 @@ new Chart(ctx, {
 ```
 
 We can also change these defaults values for each Radar type that is created, this object is available at `Chart.defaults.radar`.
-
index 2263916c12c932514cd9418d25ad32c90922625d..6c523f3611f8b715045b7ddd8081a06848dc2078 100644 (file)
@@ -96,7 +96,7 @@ myLineChart.generateLegend();
 
 Calling `getElementAtEvent(event)` on your Chart instance passing an argument of an event, or jQuery event, will return the single element at the event position. If there are multiple items within range, only the first is returned
 
-```javscript
+```javascript
 myLineChart.getElementAtEvent(e);
 // => returns the first element at the event point.
 ```
@@ -275,7 +275,7 @@ Optionally, the following methods may also be overwritten, but an implementation
 ```
 
 The Core.Scale base class also has some utility functions that you may find useful.
-```javscript
+```javascript
 {      
        // Returns true if the scale instance is horizontal
        isHorizontal: function(){},