fleet/frontend/components/icons/svg/base.jsx
Mike Stone ac9a38c207 Login page scaffolding (#142)
* LoginPage component and route

* animated SVG background image utility

* Kolide text, User, Lock, & Kolide logo SVG icons

* styleguide

* Adds global footer

* Adds InputFieldWithIcon component

* Adds LoginForm component

* Render LoginForm from the LoginPage
2016-09-12 11:14:07 -04:00

30 lines
651 B
JavaScript

import React, { Component, PropTypes } from 'react';
import { keys, pick } from 'lodash';
import radium from 'radium';
export const basePropTypes = {
alt: PropTypes.string,
name: PropTypes.string,
style: PropTypes.object,
variant: PropTypes.string,
};
export default function (SVGComponent) {
class ComponentWrapper extends Component {
static propTypes = {
...basePropTypes,
};
static defaultProps = {
variant: 'default',
};
render () {
const svgProps = pick(this.props, keys(ComponentWrapper.propTypes));
return <SVGComponent {...svgProps} />;
}
}
return radium(ComponentWrapper);
}