diff --git a/types/react-bootstrap/index.d.ts b/types/react-bootstrap/index.d.ts index a696c4ac6d..b59403cc39 100644 --- a/types/react-bootstrap/index.d.ts +++ b/types/react-bootstrap/index.d.ts @@ -1,1123 +1,125 @@ -// Type definitions for react-bootstrap +// Type definitions for react-bootstrap 0.31 // Project: https://github.com/react-bootstrap/react-bootstrap -// Definitions by: Walker Burgin , Vincent Siao , Danilo Barros , Batbold Gansukh , Raymond May Jr. , Cheng Sieu Ly , Kat Busch +// Definitions by: Walker Burgin , +// Vincent Siao , +// Danilo Barros , +// Batbold Gansukh , +// Raymond May Jr. , +// Cheng Sieu Ly , +// Kat Busch , +// Vito Samson // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped // TypeScript Version: 2.3 import * as React from 'react'; -export = ReactBootstrap; -export as namespace ReactBootstrap; -declare namespace ReactBootstrap { +export type Sizes = 'xs' | 'xsmall' | 'sm' | 'small' | 'medium' | 'lg' | 'large'; - type Sizes = 'xs' | 'xsmall' | 'sm' | 'small' | 'medium' | 'lg' | 'large'; - - - // Change onSelect signature to be (eventKey: any, event: SyntheticEvent<{}>) => any on all React-Bootstrap components, instead of the old inconsistent mishmash (#1604, #1677, #1756) - /** ( eventKey:any, e:React.SyntheticEvent<{}> ):void */ - interface SelectCallback extends React.EventHandler { - (eventKey: any, e: React.SyntheticEvent<{}>): void; - /** - @deprecated - This signature is a hack so can still derive from HTMLProps. - It does not reflect the underlying event and should not be used. - */ - (e: React.MouseEvent<{}>): void; - } - - - interface TransitionCallbacks { - onEnter?: Function; - onEntered?: Function; - onEntering?: Function; - onExit?: Function; - onExited?: Function; - onExiting?: Function; - } - - - // - interface AccordionProps extends React.HTMLProps { - bsSize?: Sizes; - bsStyle?: string; - collapsible?: boolean; - defaultExpanded?: boolean; - eventKey?: any; - expanded?: boolean; - footer?: any; // TODO: Add more specific type - header?: any; // TODO: Add more specific type - } - type Accordion = React.ClassicComponent; - var Accordion: React.ClassicComponentClass; - - - // - interface BreadcrumbProps extends React.Props { - bsClass?: string; - } - interface BreadcrumbClass extends React.ClassicComponentClass { - Item: typeof BreadcrumbItem; - } - type Breadcrumb = React.ClassicComponent; - var Breadcrumb: BreadcrumbClass; - - - // - interface BreadcrumbItemProps extends React.Props { - active?: boolean; - id?: string | number; - href?: string; - title?: React.ReactNode; - target?: string; - } - type BreadcrumbItem = React.ClassicComponent; - var BreadcrumbItem: React.ClassicComponentClass; - - - //