react-compound-timer
Advanced tools
Comparing version 1.0.12 to 1.0.13
import React from 'react'; | ||
import { TimePartsType } from 'src/lib/helpers/getTimeParts'; | ||
import { TimerStateType } from 'src/lib/models/TimerState'; | ||
import { TimePartsType } from '../../lib/helpers/getTimeParts'; | ||
import { TimerStateType } from '../../lib/models/TimerState'; | ||
declare type FormatValueType = (value: number) => string; | ||
@@ -5,0 +5,0 @@ declare type TimerContextType = TimePartsType & { |
@@ -89,3 +89,3 @@ import getTimeParts from '../helpers/getTimeParts'; | ||
callImmediately && this.onChange(this.getTimeParts(this.time)); | ||
this.timerId = setInterval(repeatedFunc, this.timeToUpdate); | ||
this.timerId = window.setInterval(repeatedFunc, this.timeToUpdate); | ||
}; | ||
@@ -92,0 +92,0 @@ Timer.prototype.computeTime = function () { |
@@ -7,4 +7,4 @@ export var INITED = 'INITED'; | ||
function TimerState(onChangeStatus) { | ||
var _this = this; | ||
if (onChangeStatus === void 0) { onChangeStatus = function (obj) { }; } | ||
var _this = this; | ||
this.state = INITED; | ||
@@ -11,0 +11,0 @@ this.onChange = function () { return onChangeStatus({ timerState: _this.state }); }; |
{ | ||
"name": "react-compound-timer", | ||
"version": "1.0.12", | ||
"version": "1.0.13", | ||
"description": "Timer compound react component", | ||
@@ -25,7 +25,8 @@ "main": "build/components/Timer/Timer", | ||
"devDependencies": { | ||
"@types/jest": "^24.0.4", | ||
"@types/react": "^16.8.3", | ||
"@types/jest": "^24.0.11", | ||
"@types/react": "^16.8.14", | ||
"@types/react-dom": "^16.8.4", | ||
"jest": "^24.1.0", | ||
"react-docgen-typescript": "^1.12.3", | ||
"react-dom": "^16.7.0", | ||
"react-dom": "^16.8.6", | ||
"react-styleguidist": "^8.0.6", | ||
@@ -42,4 +43,4 @@ "ts-jest": "^23.10.5", | ||
"dependencies": { | ||
"react": "^16.8.2" | ||
"react": "^16.8.6" | ||
} | ||
} |
@@ -11,7 +11,8 @@ { | ||
"lib": ["dom", "es2015", "es2016", "es2017"], | ||
"types": ["jest"], | ||
"declaration": true, | ||
"outDir": "./build" | ||
}, | ||
"exclude": ["node_modules", "build"], | ||
"exclude": ["node_modules", "build", "src/**/*.test.tsx", "src/**/*.test.ts"], | ||
"include": ["src/**/*.ts", "src/**/*.tsx"] | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
52964
795
15
Updatedreact@^16.8.6