Sha256: 40f326c317d562b7b45dc196688484d334522d9d64959e09ddaab09b0781d768

Contents?: true

Size: 925 Bytes

Versions: 10

Compression:

Stored size: 925 Bytes

Contents

/* @flow */

import React from 'react'
import classnames from 'classnames'
import { globalProps } from '../utilities/globalProps.js'

import { Body, Title } from '../'

import { buildCss, buildDataProps } from '../utilities/props'

type TitleDetailProps = {
  align?: "left" | "center" | "right",
  className?: string,
  data?: object,
  detail: string,
  id?: string,
  title: string,
}

const TitleDetail = (props: TitleDetailProps) => {
  const { align = 'left', className, data = {}, detail, id, title } = props
  const dataProps = buildDataProps(data)
  const pbCss = buildCss('pb_title_detail_kit', align)

  return (
    <div
        {...dataProps}
        className={classnames(className, pbCss, globalProps(props))}
        id={id}
    >
      <Title
          size={4}
          text={title}
      />
      <Body
          color="light"
          text={detail}
      />
    </div>
  )
}

export default TitleDetail

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
playbook_ui-7.0.0.pre.alpha10 app/pb_kits/playbook/pb_title_detail/_title_detail.jsx
playbook_ui-7.0.0.pre.alpha9 app/pb_kits/playbook/pb_title_detail/_title_detail.jsx
playbook_ui-7.0.0.pre.alpha8 app/pb_kits/playbook/pb_title_detail/_title_detail.jsx
playbook_ui-7.0.0.pre.alpha7 app/pb_kits/playbook/pb_title_detail/_title_detail.jsx
playbook_ui-7.0.0.pre.alpha6 app/pb_kits/playbook/pb_title_detail/_title_detail.jsx
playbook_ui-7.0.0.pre.alpha5 app/pb_kits/playbook/pb_title_detail/_title_detail.jsx
playbook_ui-7.0.0.pre.alpha4 app/pb_kits/playbook/pb_title_detail/_title_detail.jsx
playbook_ui-7.0.0.pre.alpha3 app/pb_kits/playbook/pb_title_detail/_title_detail.jsx
playbook_ui-7.0.0.pre.alpha2 app/pb_kits/playbook/pb_title_detail/_title_detail.jsx
playbook_ui-7.0.0.pre.alpha1 app/pb_kits/playbook/pb_title_detail/_title_detail.jsx