UNPKG

1.4 kBTypeScriptView Raw
1/// <reference types="react" />
2import { CSSProperties, SVGAttributes } from 'react'
3import {
4 Transform,
5 IconProp,
6 FlipProp,
7 SizeProp,
8 PullProp,
9 RotateProp,
10 FaSymbol
11} from '@fortawesome/fontawesome-svg-core'
12
13export function FontAwesomeIcon(props: FontAwesomeIconProps): JSX.Element
14
15/**
16 * @deprecated use FontAwesomeIconProps
17 */
18export type Props = FontAwesomeIconProps
19
20// This is identical to the version of Omit in Typescript 3.5. It is included for compatibility with older versions of Typescript.
21type BackwardCompatibleOmit<T, K extends keyof any> = Pick<T, Exclude<keyof T, K>>;
22
23export interface FontAwesomeIconProps extends BackwardCompatibleOmit<SVGAttributes<SVGSVGElement>, 'children' | 'mask' | 'transform'> {
24 forwardedRef?: ((e: any) => void) | React.MutableRefObject<any> | null
25 icon: IconProp
26 mask?: IconProp
27 maskId?: string
28 className?: string
29 color?: string
30 spin?: boolean
31 spinPulse?: boolean
32 spinReverse?: boolean
33 pulse?: boolean
34 beat?: boolean
35 fade?: boolean
36 beatFade?: boolean
37 bounce?: boolean
38 shake?: boolean
39 border?: boolean
40 fixedWidth?: boolean
41 inverse?: boolean
42 listItem?: boolean
43 flip?: FlipProp
44 size?: SizeProp
45 pull?: PullProp
46 rotation?: RotateProp
47 transform?: string | Transform
48 symbol?: FaSymbol
49 style?: CSSProperties
50 tabIndex?: number;
51 title?: string;
52 titleId?: string;
53 swapOpacity?: boolean;
54}
55
\No newline at end of file