Skip to content

Commit eee6196

Browse files
c376WZYSzys
authored andcommitted
Revisions in README.md English version (hustcc#38)
1 parent aa4104c commit eee6196

File tree

1 file changed

+18
-15
lines changed

1 file changed

+18
-15
lines changed

README.md

Lines changed: 18 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# canvas-nest.js
22

3-
> A nest backgroud of website draw on canvas. [中文 Readme 帮助文档](README-zh.md).
3+
> This background effect for web pages is drawn using tools based on html5 canvas. The final result is pretty awesome! [中文 Readme 帮助文档](README-zh.md).
44
55
[![npm](https://img.shields.io/badge/demo-online-brightgreen.svg)](https://git.hust.cc/canvas-nest.js)
66
[![npm](https://img.shields.io/npm/v/canvas-nest.js.svg)](https://www.npmjs.com/package/canvas-nest.js)
@@ -12,10 +12,11 @@
1212

1313
## Feature
1414

15-
- No need jQuery.
16-
- Light, only 2 Kb.
17-
- Easy to use, even you are not a web developer.
18-
- Modular & area render.
15+
- It does not depend on jQuery and original javascrpit is used.
16+
- Small size, only 2 Kb.
17+
- Easy to implement, simple configuration.
18+
- You do not have to be a web developer to use it.
19+
- Modularized with area rendering.
1920

2021

2122
## Usage
@@ -28,7 +29,7 @@ Insert the code below `between <body> and </body>`.
2829
<script src="dist/canvas-nest.js"></script>
2930
```
3031

31-
Suggest before the tag `</body>`, like below:
32+
Strongly suggest to insert before the tag `</body>`, as the following:
3233

3334
```html
3435
<html>
@@ -46,13 +47,13 @@ Suggest before the tag `</body>`, like below:
4647
Then ok! `Please do not add the code in the <head> </head>`.
4748

4849

49-
- Module usage (Area render)
50+
- Modular usage (Area render)
5051

5152
> npm i --save canvas-nest.js
5253
53-
Or import the `umd` package use `script` tag.
54+
You could import `umd` packages with `script` tag or with modules.
5455

55-
There is only one API, use it like:
56+
There is only one API, use it as below:
5657

5758
```js
5859
import CanvasNest from 'canvas-nest.js';
@@ -62,28 +63,30 @@ const config = {
6263
count: 88,
6364
};
6465

65-
// render nest on element with config.
66+
// Using config rendering effect at 'element'.
6667
const cn = new CanvasNest(element, config);
6768

6869
// destroy
6970
cn.destroy();
7071
```
7172

7273

73-
## Config
74+
## Configurations and settings
7475

75-
- **`color`**: the canvas line color, default: `'0,0,0'`; the color is (R,G,B).
76+
- **`color`**: color of lines, default: `'0,0,0'`; RGB values: (R,G,B).(note: use ',' to separate.)
7677
- **`opacity`**: the opacity of line (0~1), default: `0.5`.
7778
- **`count`**: the number of lines, default: `99`.
78-
- **`zIndex`**: the index of z space, default: `-1`.
79+
- **`zIndex`**: z-index property of the background, default: `-1`.
7980

8081
Example:
8182

8283
```html
8384
<script type="text/javascript" color="0,0,255" opacity='0.7' zIndex="-2" count="99" src="dist/canvas-nest.js"></script>
8485
```
8586

86-
Or
87+
These property configuration settings are in the js script tag as its property values. If these settings are not customized, default values are available as well.
88+
89+
With modules,use config values as below:
8790

8891
```js
8992
{
@@ -103,7 +106,7 @@ Or
103106

104107
## Used by
105108

106-
- [A Tool](https://atools.vip/): Tools for human.
109+
- [A Tool](https://atools.vip/): a convenient tool box.
107110

108111

109112

0 commit comments

Comments
 (0)