import * as ts from "typescript"; import type { ParentType } from "./utilities/getParentType"; export interface StringIndexedObject { [key: string]: T; } export interface ComponentDoc { expression?: ts.Symbol; displayName: string; filePath: string; description: string; props: Props; methods: Method[]; tags?: StringIndexedObject; } export declare type Props = StringIndexedObject; export interface PropItem { name: string; required: boolean; type: PropItemType; description: string; defaultValue: any; parent?: ParentType; declarations?: ParentType[]; tags?: StringIndexedObject; } export interface Method { name: string; docblock: string; modifiers: string[]; params: MethodParameter[]; returns?: { description?: string | null; type?: string; } | null; description: string; } export interface MethodParameter { name: string; description?: string | null; type: MethodParameterType; } export interface MethodParameterType { name: string; } export interface Component { name: string; } export interface PropItemType { name: string; value?: any; raw?: string; } export declare type PropFilter = (props: PropItem, component: Component) => boolean; export declare type ComponentNameResolver = (exp: ts.Symbol, source: ts.SourceFile) => string | undefined | null | false; export interface StaticPropFilter { skipPropsWithName?: string[] | string; skipPropsWithoutDoc?: boolean; } export interface FileParser { parse(filePathOrPaths: string | string[]): ComponentDoc[]; parseWithProgramProvider(filePathOrPaths: string | string[], programProvider?: () => ts.Program): ComponentDoc[]; } export interface JSDoc { description: string; fullComment: string; tags: StringIndexedObject; }