# ButtonLink

To implement ButtonLink component into your project you'll need to add the import:

```jsx
import { ButtonLink } from '@kiwicom/orbit-react-native';
```

After adding import into your project you can use it simply like:

```jsx
<ButtonLink>Hello World!</ButtonLink>
```

## Props

Table below contains all types of the props available in ButtonLink component.

| Name               | Type                         | Default     | Description                                                                                                                                    |
| :----------------- | :--------------------------- | :---------- | :--------------------------------------------------------------------------------------------------------------------------------------------- |
| fullWidth          | `boolean`                    | `false`     | If `true`, the ButtonLink will grow up to the full width of its container.                                                                     |
| circled            | `boolean`                    | `false`     | If `true`, the ButtonLink will have circular shape.                                                                                            |
| children           | `React.Node`                 |             | The content of the ButtonLink. [See Functional specs](#functional-specs)                                                                       |
| disabled           | `boolean`                    | `false`     | If `true`, the ButtonLink will be disabled.                                                                                                    |
| testID             | `string`                     |             | Optional prop for testing purposes. (This disables the 'layout-only view removal' optimization for this view!)                                 |
| iconLeft           | `React.Node`                 |             | The displayed icon on the left.                                                                                                                |
| iconRight          | `React.Node`                 |             | The displayed icon on the right.                                                                                                               |
| onPress            | `(event) => void \| Promise` |             | Function for handling onPress event.                                                                                                           |
| ref                | `func`                       |             | Prop for forwarded ref of the Button.                                                                                                          |
| **size**           | [`enum`](#enum)              | `"normal"`  | The size of the ButtonLink.                                                                                                                    |
| spaceAfter         | `enum`                       |             | Additional `marginBottom` after component. [See this docs](https://github.com/kiwicom/orbit-components/tree/master/src/common/getSpacingToken) |
| transparent        | `boolean`                    | `false`     | If `true`, the ButtonLink will not have `:hover` and `:active` state.                                                                          |
| accessibilityRole  | `string`                     |             | Specifies the role of an element.                                                                                                              |
| accessibilityLabel | `string`                     |             | Adds `accessibilityLabel`                                                                                                                      |
| accessibilityHint  | `string`                     |             | Adds `accessibilityHint` [See this docs](https://facebook.github.io/react-native/docs/accessibility#accessibilityhint-ios-android)             |
| **type**           | [`enum`](#enum)              | `"primary"` | The type of ButtonLink.                                                                                                                        |
| width              | `number`                     |             | The width of the ButtonLink. Number is defined in `pt`.                                                                                        |

### enum

| type          | size       |
| :------------ | :--------- |
| `"primary"`   | `"small"`  |
| `"secondary"` | `"normal"` |
|               | `"large"`  |

## Functional specs

- If you want to render **Icon only ButtonLink**, you just need to let `children` prop empty and set up any `leftIcon` you want to use.
