Ver código fonte

Merge pull request #172 from systemride/master

Add type definitions for style prop
Gaëtan Renaudeau 7 anos atrás
pai
commit
e517fcb5f3
Nenhuma conta vinculada ao e-mail do autor do commit
1 arquivos alterados com 5 adições e 0 exclusões
  1. 5
    0
      src/index.d.ts

+ 5
- 0
src/index.d.ts Ver arquivo

10
 
10
 
11
 declare module 'react-native-view-shot' {
11
 declare module 'react-native-view-shot' {
12
     import { Component, ReactInstance } from 'react'
12
     import { Component, ReactInstance } from 'react'
13
+    import { StyleObj } from 'react-native/Libraries/StyleSheet/StyleSheetTypes'
13
 
14
 
14
     export interface CaptureOptions {
15
     export interface CaptureOptions {
15
         /**
16
         /**
66
          * @param {Error} error
67
          * @param {Error} error
67
          */
68
          */
68
         onCaptureFailure?(error: Error): void;
69
         onCaptureFailure?(error: Error): void;
70
+        /**
71
+         * style prop as StyleObj
72
+         */
73
+        style?: StyleObj;
69
     }
74
     }
70
 
75
 
71
     export default class ViewShot extends Component<ViewShotProperties> {
76
     export default class ViewShot extends Component<ViewShotProperties> {