Skip to content

Commit bdc0ea1

Browse files
committed
HMS formatting for times. Many more props and settings
1 parent ab6ff3c commit bdc0ea1

File tree

5 files changed

+64
-11
lines changed

5 files changed

+64
-11
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# Changelog
22

3+
## 1.0.8 - Aug 8, 2016
4+
5+
* Updated React version in peerDependencies
6+
* Added new props for fontSize, font, timeFormat and showMilliseconds
7+
* Added ability to render minutes and hours
8+
39
## 1.0.7 - Aug 7, 2016
410

511
* Weight of circle can now be configured. Thanks @rutan.

README.md

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,18 @@ npm install react-countdown-clock
2626

2727
## Props
2828

29-
* `seconds` to count down
30-
* `color` you'd like it to be as a hex/css colour code
31-
* `alpha` transparency for component
32-
* `size` for height and width of canvas element, in pixels.
33-
* `weight` for weight of circle, in pixels.
34-
* `onComplete` callback when timer completes
29+
| prop | type | default | description |
30+
|------------------|----------------|---------|------------------------------------------------|
31+
| seconds | integer | 60 | Seconds to countdown |
32+
| color | string | #000 | Colour of counter |
33+
| alpha | float | 1.0 | Alpha transparency of counter |
34+
| size | integer | 300 | Width & height of canvas element |
35+
| weight | integer | | Weight of circle, in pixels |
36+
| fontSize | integer/string | auto | px size of font. `auto` for dynamic sizing. |
37+
| font | string | Arial | Font of counter |
38+
| timeFormat | string | seconds | Counter style; `seconds` or `hms` |
39+
| showMilliseconds | boolean | true | Show milliseconds for last 10 seconds |
40+
| onComplete | func | | Callback when time completes |
3541

3642
## Bugs & Contributions
3743

build/react-countdown-clock.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)