import Subheader from 'react-native-material-design-components/lib/Subheader.js'
Subheader
Extends:
react-native~Component → Subheader
Subheaders are special list tiles that delineate distinct sections of a list or grid list and are typically related to the current filtering or sorting criteria. Subheader tiles are either displayed inline with tiles or can be associated with content, for example, in an adjacent column.
Example:
import {TYPO, COLOR, Subheader } from 'react-native-material-design-components';
...
<Subheader text="Subheader normal"/>
<Subheader text="Subheader with color" primaryColor={COLOR[`${primary}500`].color}/>
<Subheader text="Subheader normal, inset" inset={true}/>
<Subheader text="Subheader with color, inset" primaryColor={COLOR[`${primary}500`].color}inset={true}/>
Constructor Summary
Public Constructor | ||
public |
constructor(props: object) |
Public Constructors
public constructor(props: object) source
Params:
Name | Type | Attribute | Description |
props | object | ||
props.text | string | Subheader text. |
|
props.primaryColor | string |
|
Primary color of Subheader. Accept a color string such as RGBA,RGB,HEX. |
props.inset | boolean |
|
If |
props.theme | enum(THEME_NAME) |
|
The theme of Subheader. |