UNPKG

1.07 kBTypeScriptView Raw
1import React from 'react';
2import { GraphQLSchema, GraphQLNamedType } from 'graphql';
3import { FieldType } from './DocExplorer/types';
4declare type NavStackItem = {
5 name: string;
6 title?: string;
7 search?: string;
8 def?: GraphQLNamedType | FieldType;
9};
10declare type DocExplorerProps = {
11 schema?: GraphQLSchema | null;
12};
13declare type DocExplorerState = {
14 navStack: NavStackItem[];
15};
16export declare class DocExplorer extends React.Component<DocExplorerProps, DocExplorerState> {
17 constructor(props: DocExplorerProps);
18 shouldComponentUpdate(nextProps: DocExplorerProps, nextState: DocExplorerState): boolean;
19 render(): JSX.Element;
20 showDoc(typeOrField: GraphQLNamedType | FieldType): void;
21 showDocForReference(reference: any): void;
22 showSearch(search: string): void;
23 reset(): void;
24 handleNavBackClick: () => void;
25 handleClickType: (type: GraphQLNamedType) => void;
26 handleClickField: (field: FieldType) => void;
27 handleSearch: (value: string) => void;
28}
29export {};
30//# sourceMappingURL=DocExplorer.d.ts.map
\No newline at end of file