var __rest = (this && this.__rest) || function (s, e) {
    var t = {};
    for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
        t[p] = s[p];
    if (s != null && typeof Object.getOwnPropertySymbols === "function")
        for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
            if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
                t[p[i]] = s[p[i]];
        }
    return t;
};
import React from 'react';
import { Box, Tab, Typography, styled, lighten } from '@material-ui/core';
export const a11yProps = (index) => {
    return {
        id: `simple-tab-${index}`,
        'aria-controls': `simple-tabpanel-${index}`
    };
};
export const StyledTab = styled(Tab)(({ theme, style }) => (Object.assign({ textTransform: 'none', '&.Mui-selected': {
        backgroundColor: lighten(theme.palette.secondary.light, 0.9),
        color: theme.palette.primary.main
    }, backgroundColor: theme.palette.background.paper }, style)));
/**
 * TabPanel
 *
 * @param {TabPanelProps} props
 * @return {*}
 */
export const TabPanel = (props) => {
    const { children, value, index, sx } = props, other = __rest(props, ["children", "value", "index", "sx"]);
    return (React.createElement("div", Object.assign({ role: "tabpanel", hidden: value !== index, id: `simple-tabpanel-${index}`, "aria-labelledby": `simple-tab-${index}` }, other), value === index && (
    // @ts-ignore
    React.createElement(Box, { sx: sx ? Object.assign({}, sx) : { p: 3 } }, React.createElement(Typography, { variant: "subtitle2" }, children)))));
};
//# sourceMappingURL=TabPanel.js.map