Home Manual Reference Source Repository
import Subheader from 'mrn/lib/Subheader.js'
public class | source

Subheader

Extends:

react-native~Component → Subheader

Subheader Component

Example:


<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

Public Constructors

public constructor(props: object) source

Params:

NameTypeAttributeDescription
props object
props.text string

Subheader text.

props.primaryColor string
  • optional
  • default: 'rgba(0,0,0,.54)'

Primary color of Subheader. Accept a color string such as RGBA,RGB,HEX.

props.inset boolean
  • optional
  • default: false

If true, Subheader is aligned with the text content with 72dp paddingLeft. Often with a left-aligned floating action button.

props.theme enum(THEME_NAME)
  • optional
  • default: 'light'

The theme of Subheader.