@kiwicom/orbit-components
Version:
Orbit-components is a React component library which provides developers with the easiest possible way of building Kiwi.com’s products.
44 lines (34 loc) • 1.05 kB
Flow
// @flow
/*
DOCUMENTATION: https://orbit.kiwi/components/textlink/
*/
import type { ReactComponentStyled, Interpolation } from "styled-components";
import type { Globals, Component } from "../common/common.js.flow";
import type { ThemeProps } from "../defaultTheme";
type Type = "primary" | "secondary";
type Size = "large" | "normal" | "small";
export type Props = {|
+children: React$Node,
+href?: string,
+icon?: React$Node,
+onClick?: (SyntheticEvent<HTMLLinkElement>) => void | Promise<any>,
+external?: boolean,
+type?: Type,
+size?: Size,
+rel?: string,
+tabIndex?: string,
+component?: Component,
...Globals,
|};
type styledTextLink = {
tokens?: { [key: string]: string | number },
type?: Type,
};
export type GetLinkStyleProps = {
type: Type,
...ThemeProps,
};
export type GetLinkStyle = GetLinkStyleProps => Interpolation[];
declare export var getLinkStyle: GetLinkStyle;
declare export var StyledTextLink: ReactComponentStyled<styledTextLink>;
declare export default React$ComponentType<Props>;