Added logging, changed some directory structure

This commit is contained in:
2018-01-13 21:33:40 -05:00
parent f079a5f067
commit 8e72ffb917
73656 changed files with 35284 additions and 53718 deletions

View File

@@ -0,0 +1,61 @@
// @flow
import React from 'react';
import type { Node } from 'react';
import classNames from 'classnames';
import withStyles from '../styles/withStyles';
import { cloneChildrenWithClassName } from '../utils/reactHelpers';
export const styles = {
root: {
height: 52,
display: 'flex',
alignItems: 'center',
padding: '2px 4px',
},
actionSpacing: {
margin: '0 4px',
},
};
type ProvidedProps = {
classes: Object,
disableActionSpacing: boolean,
};
export type Props = {
/**
* The content of the component.
*/
children?: Node,
/**
* Useful to extend the style applied to components.
*/
classes?: Object,
/**
* @ignore
*/
className?: string,
/**
* If `true`, the card actions do not have additional margin.
*/
disableActionSpacing?: boolean,
};
function CardActions(props: ProvidedProps & Props) {
const { disableActionSpacing, children, classes, className, ...other } = props;
return (
<div className={classNames(classes.root, className)} {...other}>
{disableActionSpacing
? children
: cloneChildrenWithClassName(children, classes.actionSpacing)}
</div>
);
}
CardActions.defaultProps = {
disableActionSpacing: false,
};
export default withStyles(styles, { name: 'MuiCardActions' })(CardActions);