暂无描述

index.d.ts 860B

123456789101112131415161718192021222324252627282930313233
  1. // Type definitions for react-native-autoheight-webview 1.x
  2. // Project: https://github.com/iou90/react-native-autoheight-webview
  3. // Definitions by: Naveen Ithappu <https://github.com/naveen-ithappu>
  4. // TypeScript Version: 2.8
  5. import { Component } from 'react';
  6. import { WebViewProps } from 'react-native-webview';
  7. import { ViewStyle } from 'react-native';
  8. export interface StylesFile {
  9. href: string;
  10. type: string;
  11. rel: string;
  12. }
  13. export interface SizeUpdate {
  14. width: number;
  15. height: number;
  16. }
  17. export interface AutoHeightWebViewProps extends WebViewProps {
  18. onSizeUpdated: (size: SizeUpdate) => void;
  19. files: StylesFile[];
  20. style: ViewStyle;
  21. customScript: string;
  22. customStyle: string;
  23. zoomable: boolean;
  24. scrollEnabledWithZoomedin: boolean;
  25. }
  26. export default class AutoHeightWebView extends Component<Partial<AutoHeightWebViewProps>> {}