From: Akihiko Kusanagi Date: Tue, 29 Jan 2019 12:34:16 +0000 (+0800) Subject: Fix typos and make the docs consistent (#6020) X-Git-Tag: v2.8.0-rc.1~45 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0d01bcf5cca3a85c97305ad44925113cdead9c74;p=thirdparty%2FChart.js.git Fix typos and make the docs consistent (#6020) --- diff --git a/docs/README.md b/docs/README.md index fe0b60c53..d0b0544ab 100644 --- a/docs/README.md +++ b/docs/README.md @@ -14,11 +14,11 @@ In this example, we create a bar chart for a single dataset and render that in o ```html + ``` Now, we can create a chart. We add a script to our page: @@ -24,12 +24,12 @@ var chart = new Chart(ctx, { // The data for our dataset data: { - labels: ["January", "February", "March", "April", "May", "June", "July"], + labels: ['January', 'February', 'March', 'April', 'May', 'June', 'July'], datasets: [{ - label: "My First dataset", + label: 'My First dataset', backgroundColor: 'rgb(255, 99, 132)', borderColor: 'rgb(255, 99, 132)', - data: [0, 10, 5, 2, 20, 30, 45], + data: [0, 10, 5, 2, 20, 30, 45] }] }, @@ -40,4 +40,4 @@ var chart = new Chart(ctx, { It's that easy to get started using Chart.js! From here you can explore the many options that can help you customise your charts with scales, tooltips, labels, colors, custom actions, and much more. -There are many examples of Chart.js that are available in the `/samples` folder of `Chart.js.zip` that is attached to every [release](https://github.com/chartjs/Chart.js/releases). \ No newline at end of file +All our examples are [available online](https://www.chartjs.org/samples/latest/) but you can also download the `Chart.js.zip` archive attached to every [release](https://github.com/chartjs/Chart.js/releases) to experiment with our samples locally from the `/samples` folder. diff --git a/docs/getting-started/installation.md b/docs/getting-started/installation.md index ea9daea23..783bd1310 100644 --- a/docs/getting-started/installation.md +++ b/docs/getting-started/installation.md @@ -40,7 +40,7 @@ If you download or clone the repository, you must [build](../developers/contribu # Selecting the Correct Build -Chart.js provides two different builds for you to choose: `Stand-Alone Build`, `Bundled Build`. +Chart.js provides two different builds for you to choose: **Stand-Alone Build**, **Bundled Build**. ## Stand-Alone Build Files: @@ -54,4 +54,4 @@ Files: * `dist/Chart.bundle.js` * `dist/Chart.bundle.min.js` -The bundled build includes Moment.js in a single file. You should use this version if you require time axes and want to include a single file. You should not use this build if your application already included Moment.js. Otherwise, Moment.js will be included twice which results in increasing page load time and possible version compatability issues. The Moment.js version in the bundled build is private to Chart.js so if you want to use Moment.js yourself, it's better to use Chart.js (non bundled) and import Moment.js manually. +The bundled build includes Moment.js in a single file. You should use this version if you require time axes and want to include a single file. You should not use this build if your application already included Moment.js. Otherwise, Moment.js will be included twice which results in increasing page load time and possible version compatibility issues. The Moment.js version in the bundled build is private to Chart.js so if you want to use Moment.js yourself, it's better to use Chart.js (non bundled) and import Moment.js manually. diff --git a/docs/getting-started/integration.md b/docs/getting-started/integration.md index 95ccbc46d..285bf195b 100644 --- a/docs/getting-started/integration.md +++ b/docs/getting-started/integration.md @@ -28,9 +28,9 @@ var myChart = new Chart(ctx, {...}); ## Require JS ```javascript -require(['path/to/chartjs/dist/Chart.js'], function(Chart){ +require(['path/to/chartjs/dist/Chart.js'], function(Chart) { var myChart = new Chart(ctx, {...}); }); ``` -> **Important:** RequireJS [can **not** load CommonJS module as is](http://www.requirejs.org/docs/commonjs.html#intro), so be sure to require one of the built UMD files instead (i.e. `dist/Chart.js`, `dist/Chart.min.js`, etc.). +> **Important:** RequireJS [can **not** load CommonJS module as is](https://requirejs.org/docs/commonjs.html#intro), so be sure to require one of the built UMD files instead (i.e. `dist/Chart.js`, `dist/Chart.min.js`, etc.). diff --git a/docs/getting-started/usage.md b/docs/getting-started/usage.md index 739c83859..0a0d48b99 100644 --- a/docs/getting-started/usage.md +++ b/docs/getting-started/usage.md @@ -11,10 +11,10 @@ To create a chart, we need to instantiate the `Chart` class. To do this, we need ```javascript // Any of the following formats may be used -var ctx = document.getElementById("myChart"); -var ctx = document.getElementById("myChart").getContext("2d"); -var ctx = $("#myChart"); -var ctx = "myChart"; +var ctx = document.getElementById('myChart'); +var ctx = document.getElementById('myChart').getContext('2d'); +var ctx = $('#myChart'); +var ctx = 'myChart'; ``` Once you have the element or context, you're ready to instantiate a pre-defined chart-type or create your own! @@ -24,11 +24,11 @@ The following example instantiates a bar chart showing the number of votes for d ```html -``` \ No newline at end of file +``` diff --git a/docs/notes/README.md b/docs/notes/README.md index 2795faebc..94d9a69f2 100644 --- a/docs/notes/README.md +++ b/docs/notes/README.md @@ -1 +1 @@ -# Additional Notes \ No newline at end of file +# Additional Notes diff --git a/docs/notes/comparison.md b/docs/notes/comparison.md index 3cb9c99af..b7a723163 100644 --- a/docs/notes/comparison.md +++ b/docs/notes/comparison.md @@ -9,7 +9,7 @@ Library Features | SVG | | ✓ | ✓ | ✓ | | Built-in Charts | ✓ | | ✓ | ✓ | | 8+ Chart Types | ✓ | ✓ | ✓ | | -| Extendable to Custom Charts | ✓ | ✓ | | | +| Extendable to Custom Charts | ✓ | ✓ | | | | Supports Modern Browsers | ✓ | ✓ | ✓ | ✓ | | Extensive Documentation | ✓ | ✓ | ✓ | ✓ | | Open Source | ✓ | ✓ | | ✓ | @@ -24,9 +24,8 @@ Built in Chart Types | Horizontal Bar | ✓ | ✓ | ✓ | | Pie/Doughnut | ✓ | ✓ | ✓ | | Polar Area | ✓ | ✓ | | -| Radar | ✓ | | | +| Radar | ✓ | | | | Scatter | ✓ | ✓ | ✓ | | Bubble | ✓ | | | | Gauges | | ✓ | | | Maps (Heat/Tree/etc.) | | ✓ | | - diff --git a/docs/notes/extensions.md b/docs/notes/extensions.md index 91d520a8e..f8f53f3d5 100644 --- a/docs/notes/extensions.md +++ b/docs/notes/extensions.md @@ -65,6 +65,6 @@ In addition, many plugins can be found on the [npm registry](https://www.npmjs.c ### Ember.js - ember-cli-chart - + ### Omi (v5+) - omi-chart diff --git a/docs/notes/license.md b/docs/notes/license.md index 01a0a1da5..9bc3c6792 100644 --- a/docs/notes/license.md +++ b/docs/notes/license.md @@ -1,3 +1,3 @@ # License -Chart.js is open source and available under the MIT license. \ No newline at end of file +Chart.js is open source and available under the MIT license.