Created
March 31, 2016 14:42
-
-
Save fcavalcantirj/4fadc3c55bd5c244c02a75e752854a2e to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import CountDownClock from 'react-countdown-clock' | |
import { emit } from '../garupa' | |
const {createClass, createFactory} = React | |
const {div} = React.DOM | |
const countDownTimer = createFactory(CountDownClock) | |
const CountDownTimer = createClass({ | |
displayName: 'CountDownTimer', | |
callback() { | |
emit('chamada::falhou') | |
}, | |
render() { | |
return div(null, | |
countDownTimer({ | |
seconds:300, | |
color:'#90C3D4', | |
alpha:0.9, | |
size:150, | |
onComplete: this.callback | |
}) | |
) | |
} | |
}) | |
export default createFactory(CountDownTimer) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
import CountDownClock from 'react-countdown-clock'
const countDownTimer = createFactory(CountDownClock)
countDownTimer({
seconds:300,
color:'#90C3D4',
alpha:0.9,
size:150,
onComplete: this.callback
})