UNPKG

@moxb/stellar-router-react

Version:

Stellar router: React widgets

19 lines (18 loc) 677 B
/// <reference types="react" /> import { UIFragmentSpec } from '@moxb/react-html'; import { NavigableContent, SubStateCoreInfo } from '@moxb/stellar-router-core'; /** * This is the full spec of the root-or-details component */ interface OwnProps<DataType> { ifRoot: SubStateCoreInfo<UIFragmentSpec, DataType>; ifDetails: SubStateCoreInfo<UIFragmentSpec, DataType>; } declare type ComponentProps<DataType> = NavigableContent<DataType>; export interface DetailProps { token: string; } export declare function rootOrDetails<DataType>(ownProps: OwnProps<DataType>): ((props: ComponentProps<DataType>) => JSX.Element | null) & { displayName: string; }; export {};