2017-11-16 12:47:32 +02:00
|
|
|
import React from 'react';
|
|
|
|
import styled from 'styled-components';
|
|
|
|
import is from 'styled-is';
|
2017-10-09 21:01:34 +03:00
|
|
|
|
2017-05-18 21:21:33 +03:00
|
|
|
import Baseline from '../baseline';
|
2017-02-20 18:15:36 +02:00
|
|
|
|
2017-11-16 12:47:32 +02:00
|
|
|
const StyledFieldset = styled.div`
|
2017-02-20 18:15:36 +02:00
|
|
|
display: inline-block;
|
|
|
|
margin: 0;
|
|
|
|
padding: 0;
|
|
|
|
border: none;
|
|
|
|
overflow: hidden;
|
|
|
|
height: auto;
|
|
|
|
|
|
|
|
-webkit-margin-start: 0;
|
|
|
|
-webkit-margin-end: 0;
|
|
|
|
-webkit-padding-before: 0;
|
|
|
|
-webkit-padding-start: 0;
|
|
|
|
-webkit-padding-end: 0;
|
|
|
|
-webkit-padding-after: 0;
|
2017-11-16 12:47:32 +02:00
|
|
|
|
|
|
|
${is('fluid')`
|
|
|
|
width: 100%;
|
|
|
|
`};
|
2017-11-23 14:18:38 +02:00
|
|
|
|
|
|
|
${is('right')`
|
|
|
|
float: right;
|
|
|
|
`};
|
2017-02-20 18:15:36 +02:00
|
|
|
`;
|
|
|
|
|
2017-11-16 12:47:32 +02:00
|
|
|
const Fieldset = ({ children, ...rest }) => (
|
|
|
|
<StyledFieldset role="group" {...rest}>
|
|
|
|
{children}
|
|
|
|
</StyledFieldset>
|
|
|
|
);
|
|
|
|
|
|
|
|
export default Baseline(Fieldset);
|