Merge pull request #17587 from vincaslt/master

Update react-fontawesome typedefs
This commit is contained in:
Ryan Cavanaugh
2017-07-13 16:48:27 -07:00
committed by GitHub
3 changed files with 29 additions and 29 deletions

View File

@@ -1,35 +1,36 @@
// Type definitions for react-fontawesome 1.5.0
// Type definitions for react-fontawesome 1.6
// Project: https://github.com/danawoodman/react-fontawesome
// Definitions by: Timur Rustamov <https://github.com/timurrustamov>, Anton Kandybo <https://github.com/dublicator>
// Definitions by: Timur Rustamov <https://github.com/timurrustamov>,
// Anton Kandybo <https://github.com/dublicator>
// Vincas Stonys <https://github.com/vincaslt>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.3
declare module "react-fontawesome" {
import * as React from 'react';
import * as React from 'react';
export = FontAwesome;
type FontAwesomeSize = 'lg' | '2x' | '3x' | '4x' | '5x';
type FontAwesomeStack = "1x" | "2x";
type FontAwesomeFlip = "horizontal" | "vertical";
declare namespace FontAwesome {
type FontAwesomeSize = 'lg' | '2x' | '3x' | '4x' | '5x';
type FontAwesomeStack = "1x" | "2x";
type FontAwesomeFlip = "horizontal" | "vertical";
interface FontAwesomeProps {
ariaLabel?: string,
border?: boolean,
className?: string,
cssModule?: any,
fixedWidth?: boolean,
flip?: FontAwesomeFlip,
inverse?: boolean,
name: string,
pulse?: boolean,
rotate?: number,
size?: FontAwesomeSize,
spin?: boolean,
stack?: FontAwesomeStack,
tag?: string
}
class FontAwesome extends React.Component<FontAwesomeProps> {}
export = FontAwesome;
interface FontAwesomeProps {
ariaLabel?: string;
border?: boolean;
className?: string;
cssModule?: any;
fixedWidth?: boolean;
flip?: FontAwesomeFlip;
inverse?: boolean;
name: string;
pulse?: boolean;
rotate?: number;
size?: FontAwesomeSize;
spin?: boolean;
stack?: FontAwesomeStack;
tag?: string;
}
}
declare class FontAwesome extends React.Component<FontAwesome.FontAwesomeProps> {}

View File

@@ -3,9 +3,7 @@ import * as ReactDOM from "react-dom";
import FontAwesome = require('react-fontawesome');
class TestComponent extends React.Component {
render() {
return (
<FontAwesome
className='super-crazy-colors'

View File

@@ -0,0 +1 @@
{ "extends": "dtslint/dt.json" }