mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-05-26 19:04:13 +08:00
Merge pull request #28350 from t49tran/react-bootstrap/update-nav-dropdown-definition
[react-bootstrap] update nav dropdown title definition
This commit is contained in:
1
types/react-bootstrap/index.d.ts
vendored
1
types/react-bootstrap/index.d.ts
vendored
@@ -13,6 +13,7 @@
|
||||
// Aaron Beall <https://github.com/aaronbeall>
|
||||
// Johann Rakotoharisoa <https://github.com/jrakotoharisoa>
|
||||
// Andrew Makarov <https://github.com/r3nya>
|
||||
// Duong Tran <https://github.com/t49tran>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.8
|
||||
|
||||
|
||||
4
types/react-bootstrap/lib/NavDropdown.d.ts
vendored
4
types/react-bootstrap/lib/NavDropdown.d.ts
vendored
@@ -1,4 +1,5 @@
|
||||
import * as React from 'react';
|
||||
import { Omit } from 'react-bootstrap';
|
||||
import { DropdownBaseProps } from './Dropdown';
|
||||
|
||||
declare namespace NavDropdown {
|
||||
@@ -6,9 +7,10 @@ declare namespace NavDropdown {
|
||||
active?: boolean;
|
||||
noCaret?: boolean;
|
||||
eventKey?: any;
|
||||
title: React.ReactNode;
|
||||
}
|
||||
|
||||
export type NavDropdownProps = NavDropdownBaseProps & React.HTMLProps<NavDropdown>;
|
||||
export type NavDropdownProps = NavDropdownBaseProps & Omit<React.HTMLProps<NavDropdown>, 'title'>;
|
||||
}
|
||||
declare class NavDropdown extends React.Component<NavDropdown.NavDropdownProps> { }
|
||||
export = NavDropdown;
|
||||
|
||||
@@ -166,7 +166,7 @@ export class ReactBootstrapIndividualComponentsTest extends React.Component {
|
||||
<ModalHeader />
|
||||
<ModalTitle />
|
||||
<Nav />
|
||||
<NavDropdown id="foo" />
|
||||
<NavDropdown id="foo" title={<h4>Test</h4>} />
|
||||
<NavItem />
|
||||
<Navbar />
|
||||
<NavbarBrand />
|
||||
|
||||
Reference in New Issue
Block a user