Sha256: 3cde3dd3a3f313aa5d1cdebd4c42c87c4c105ec3fc9fbc1eb527b091dfc43dfe
Contents?: true
Size: 636 Bytes
Versions: 5
Compression:
Stored size: 636 Bytes
Contents
/* @flow */ import React from 'react' import classnames from 'classnames' type CaptionProps = { className?: String, children: Array<React.ReactNode> | React.ReactNode, dark?: Boolean, size?: 'xs' | 'sm' | 'md' | 'lg' | 'xl', tag: String, text: String, } const Caption = ({ className, children, dark=false, size='md', tag='div', text, }: CaptionProps) => { const Tag = `${tag}` const css = classnames([ `pb_caption_kit` + `_${size}` + (dark === true ? '_dark' : ''), className, ]) return ( <Tag className={css} > {text || children} </Tag> ) } export default Caption
Version data entries
5 entries across 5 versions & 1 rubygems