@tanem/react-nprogress
Advanced tools
Comparing version 1.0.4 to 1.0.5
# Changelog | ||
## [v1.0.5](https://github.com/tanem/react-nprogress/tree/v1.0.5) (2018-10-21) | ||
[Full Changelog](https://github.com/tanem/react-nprogress/compare/v1.0.4...v1.0.5) | ||
**Merged pull requests:** | ||
- Add propTypes [\#16](https://github.com/tanem/react-nprogress/pull/16) ([tanem](https://github.com/tanem)) | ||
## [v1.0.4](https://github.com/tanem/react-nprogress/tree/v1.0.4) (2018-10-21) | ||
@@ -4,0 +11,0 @@ [Full Changelog](https://github.com/tanem/react-nprogress/compare/v1.0.3...v1.0.4) |
@@ -7,2 +7,3 @@ 'use strict'; | ||
var _inheritsLoose = _interopDefault(require('@babel/runtime/helpers/inheritsLoose')); | ||
var PropTypes = require('prop-types'); | ||
var React = require('react'); | ||
@@ -204,4 +205,11 @@ | ||
}; | ||
ReactNProgress.propTypes = { | ||
animationDuration: PropTypes.number, | ||
children: PropTypes.func, | ||
incrementDuration: PropTypes.number, | ||
isAnimating: PropTypes.bool, | ||
minimum: PropTypes.number | ||
}; | ||
module.exports = ReactNProgress; | ||
//# sourceMappingURL=react-nprogress.development.js.map |
import _extends from '@babel/runtime/helpers/extends'; | ||
import _inheritsLoose from '@babel/runtime/helpers/inheritsLoose'; | ||
import { number, func, bool } from 'prop-types'; | ||
import { Component } from 'react'; | ||
@@ -199,4 +200,11 @@ | ||
}; | ||
ReactNProgress.propTypes = process.env.NODE_ENV !== "production" ? { | ||
animationDuration: number, | ||
children: func, | ||
incrementDuration: number, | ||
isAnimating: bool, | ||
minimum: number | ||
} : {}; | ||
export default ReactNProgress; | ||
//# sourceMappingURL=react-nprogress.js.map |
@@ -0,1 +1,2 @@ | ||
import * as PropTypes from 'prop-types'; | ||
import * as React from 'react'; | ||
@@ -5,5 +6,5 @@ export interface Props { | ||
children: (renderProps: RenderProps) => React.ReactNode; | ||
incrementDuration: number; | ||
isAnimating: boolean; | ||
minimum: number; | ||
incrementDuration: number; | ||
} | ||
@@ -22,2 +23,9 @@ export interface State { | ||
}; | ||
static propTypes: { | ||
animationDuration: PropTypes.Requireable<number>; | ||
children: PropTypes.Requireable<(...args: any[]) => any>; | ||
incrementDuration: PropTypes.Requireable<number>; | ||
isAnimating: PropTypes.Requireable<boolean>; | ||
minimum: PropTypes.Requireable<number>; | ||
}; | ||
initialState: { | ||
@@ -24,0 +32,0 @@ isFinished: boolean; |
{ | ||
"name": "@tanem/react-nprogress", | ||
"version": "1.0.4", | ||
"version": "1.0.5", | ||
"description": "A React primitive for building slim progress bars inspired by Google, YouTube, and Medium.", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
(function (global, factory) { | ||
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('react')) : | ||
typeof define === 'function' && define.amd ? define(['react'], factory) : | ||
(global.NProgress = factory(global.React)); | ||
}(this, (function (React) { 'use strict'; | ||
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('prop-types'), require('react')) : | ||
typeof define === 'function' && define.amd ? define(['prop-types', 'react'], factory) : | ||
(global.NProgress = factory(global.PropTypes,global.React)); | ||
}(this, (function (PropTypes,React) { 'use strict'; | ||
@@ -235,2 +235,9 @@ function createCommonjsModule(fn, module) { | ||
}; | ||
ReactNProgress.propTypes = { | ||
animationDuration: PropTypes.number, | ||
children: PropTypes.func, | ||
incrementDuration: PropTypes.number, | ||
isAnimating: PropTypes.bool, | ||
minimum: PropTypes.number | ||
}; | ||
@@ -237,0 +244,0 @@ return ReactNProgress; |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
73728
614
2