UNPKG

@kiwicom/orbit-components

Version:

<div align="center"> <a href="https://orbit.kiwi" target="_blank"> <img alt="orbit-components" src="https://orbit.kiwi/wp-content/uploads/2018/08/orbit-components.png" srcset="https://orbit.kiwi/wp-content/uploads/2018/08/orbit-components@2x.png 2x"

32 lines (28 loc) 1.34 kB
# Heading To implement Heading component into your project you'll need to add the import: ```jsx import Heading from "@kiwicom/orbit-components/lib/Heading"; ``` After adding import into your project you can use it simply like: ```jsx <Heading>Hello World!</Heading> ``` ## Props Table below contains all types of the props available in Heading component. | Name | Type | Default | Description | | :------------ | :---------------------| :--------- | :------------------------------- | | children | `React.Node` | | The content of the Heading. | dataTest | `string` | | Optional prop for testing purposes. | **element** | [`enum`](#enum) | `"h1"` | The element used for the root node. | inverted | `boolean` | | The `true`, the Heading color will be white. | spaceAfter | `enum` | | Additional `margin-bottom` after component. [See this docs](../common/getSpacingToken) | **type** | [`enum`](#enum) | `"title1"` | The size type of Heading. ### enum | element | type | | :------ | :---------- | | `"h1"` | `"display"` | | `"h2"` | `"title1"` | | `"h3"` | `"title2"` | | `"h4"` | `"title3"` | | `"h5"` | | | `"h6"` | |