Adding dot style in Paragraph component
This commit is contained in:
parent
431e0281a4
commit
e64da52fa1
|
@ -13,18 +13,19 @@ type Props = {
|
||||||
color?: 'soft' | 'medium' | 'dark' | 'white' | 'fancy' | 'primary' | 'warning',
|
color?: 'soft' | 'medium' | 'dark' | 'white' | 'fancy' | 'primary' | 'warning',
|
||||||
transform?: 'capitalize' | 'lowercase' | 'uppercase',
|
transform?: 'capitalize' | 'lowercase' | 'uppercase',
|
||||||
children: React$Node,
|
children: React$Node,
|
||||||
|
dot?: boolean,
|
||||||
className?: string,
|
className?: string,
|
||||||
}
|
}
|
||||||
|
|
||||||
class Paragraph extends React.PureComponent<Props> {
|
class Paragraph extends React.PureComponent<Props> {
|
||||||
render() {
|
render() {
|
||||||
const {
|
const {
|
||||||
weight, children, color, align, size, transform, noMargin, className, ...props
|
weight, children, color, align, size, transform, noMargin, className, dot, ...props
|
||||||
} = this.props
|
} = this.props
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<p
|
<p
|
||||||
className={cx(styles.paragraph, className, weight, { noMargin }, size, color, transform, align)}
|
className={cx(styles.paragraph, className, weight, { noMargin }, { dot }, size, color, transform, align)}
|
||||||
{...props}
|
{...props}
|
||||||
>
|
>
|
||||||
{ children }
|
{ children }
|
||||||
|
|
|
@ -88,4 +88,8 @@
|
||||||
|
|
||||||
.bold {
|
.bold {
|
||||||
font-weight: $boldFont;
|
font-weight: $boldFont;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.dot {
|
||||||
|
display: list-item;
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in New Issue