UNPKG

react-native-components-inspector

Version:

react native components inspector can used to click the component and open the code in the editor

97 lines (96 loc) 2.53 kB
import * as react_native0 from "react-native"; import { View } from "react-native"; import React, { ReactNode, RefObject } from "react"; //#region src/utils/stringifyPropsForDisplay.d.ts declare function stringifyPropsForDisplay(value: any, options?: { maxDepth?: number; maxKeys?: number; maxString?: number; }): string; //#endregion //#region src/utils/constants.d.ts declare const BLOCKED_COMPONENTS: string[]; //#endregion //#region src/devServer.d.ts declare function getDevServerBaseURL(): string | null; //#endregion //#region src/components/useInspector.d.ts interface HighlightInfo { x: number; y: number; width: number; height: number; } interface PopoverInfo { frame?: { left: number; top: number; width: number; height: number; }; props?: any; hierarchy?: any[]; selectedIndex?: number; source?: any; style?: any; ancestorsSources?: Array<{ name?: string; source?: { file?: string; line?: number; column?: number; } | any; }>; } declare function useInspector(params: { wrapperRef: RefObject<View | null>; isInspectorEnabled: boolean; blockComponents: string[]; }): { readonly panHandlers: react_native0.GestureResponderHandlers; readonly highlightInfo: HighlightInfo | null; readonly popoverInfo: PopoverInfo | null; readonly reset: () => void; }; //#endregion //#region src/components/InspectorWrapper.d.ts interface InspectorWrapperProps { children: ReactNode; blockComponents?: string[]; } declare const InspectorWrapper: React.FC<InspectorWrapperProps>; //#endregion //#region src/components/InspectorPopover.d.ts interface InspectorPopoverProps { x: number; y: number; title: string; sizeText: string; propsText?: string; source?: { file?: string; line?: number; column?: number; } | any; styleText?: string; ancestorsSources?: Array<{ name?: string; source?: { file?: string; line?: number; column?: number; } | any; }>; } declare const InspectorPopover: React.FC<InspectorPopoverProps>; //#endregion //#region src/components/InspectorHighlight.d.ts interface InspectorHighlightProps { x: number; y: number; width: number; height: number; } declare const InspectorHighlight: React.FC<InspectorHighlightProps>; //#endregion export { BLOCKED_COMPONENTS, HighlightInfo, InspectorHighlight, InspectorHighlightProps, InspectorPopover, InspectorPopoverProps, InspectorWrapper, PopoverInfo, getDevServerBaseURL, stringifyPropsForDisplay, useInspector };