@wulperstudio/cms
Version:
Wulper Studio Library Components CMS
77 lines • 1.97 kB
JavaScript
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
var _excluded = ["children", "value", "index"];
import React from 'react';
import { Tabs, styled } from '@mui/material';
import { jsx as _jsx } from "react/jsx-runtime";
export var StyledTabs = styled(Tabs, {
shouldForwardProp: function shouldForwardProp(prop) {
return prop !== 'fullWidth' && prop !== 'textColor' && prop !== 'indicator';
}
})({
'& ': {
minHeight: '44px',
width: '100%',
maxWidth: '100%',
overflowX: 'auto'
},
'& div ': {
display: 'flex',
gap: '10px',
'& *': {
flexGrow: 0
}
},
'& .MuiTabs-indicator': {
display: 'flex',
justifyContent: 'center',
backgroundColor: 'transparent',
maxHeight: '5px',
height: '5px',
borderRadius: '10px'
}
});
export var TabPanel = function TabPanel(props) {
var children = props.children,
value = props.value,
index = props.index,
other = _objectWithoutProperties(props, _excluded);
return /*#__PURE__*/_jsx("div", Object.assign({
style: {
width: '100%',
height: value === index ? '100%' : 0,
maxWidth: '100%',
overflowY: 'auto'
}
}, other, {
children: value === index && children
}));
};
export var WrapperTabs = styled('div', {
shouldForwardProp: function shouldForwardProp(prop) {
return prop !== 'padding';
}
})(function (_ref) {
var padding = _ref.padding;
return {
width: '100%',
maxWidth: '100%',
backgroundColor: 'transparent',
marginTop: '0px',
marginBottom: '0px',
padding: padding || '15px 0',
position: 'relative',
overflowX: 'auto'
};
});
export var WraperComponent = styled('div')({
display: 'grid',
gridTemplateRows: 'auto 1fr',
height: '100%'
});
export var WrapperTab = styled('div', {
shouldForwardProp: function shouldForwardProp(prop) {
return prop !== 'textColor' && prop !== 'value';
}
})({
cursor: 'pointer'
});