mirror of
https://github.com/bartgryszko/react-native-circular-progress.git
synced 2026-01-25 16:25:58 +00:00
Update typings
The prop `fill` is marked as required in the propTypes for `CircularProgress` but is optional in the Typescript type declaration. This results in Typescript not complaining when leaving the prop empty, while propTypes generates the following warning during runtime: `Failed prop type: The prop 'fill' is marked as required in 'AnimatedCircularProgress', but its value is 'undefined'.`. The fix is to change the Typescript declaration for `fill` from optional to required.
This commit is contained in:
parent
1ff5559216
commit
0dc9b5efff
15
index.d.ts
vendored
15
index.d.ts
vendored
@ -24,6 +24,13 @@ declare module 'react-native-circular-progress' {
|
||||
*/
|
||||
width: number;
|
||||
|
||||
/**
|
||||
* Current progress / fill
|
||||
*
|
||||
* @type {number}
|
||||
*/
|
||||
fill: number;
|
||||
|
||||
/**
|
||||
* Thickness of background circle
|
||||
*
|
||||
@ -32,14 +39,6 @@ declare module 'react-native-circular-progress' {
|
||||
*/
|
||||
backgroundWidth?: number;
|
||||
|
||||
/**
|
||||
* Current progress / fill
|
||||
*
|
||||
* @type {number}
|
||||
* @default 0
|
||||
*/
|
||||
fill?: number;
|
||||
|
||||
/**
|
||||
* Color of the progress line
|
||||
*
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user