// src/theme.ts
// import ArrowDownwardIcon from '@mui/icons-material/ArrowDownward';
import { createTheme, ThemeOptions } from '@mui/material';
const sharedThemeOptions: ThemeOptions = {
   components: {
      MuiButton: {
         defaultProps: {
            size: 'small'
         }
      },
      MuiButtonGroup: {
         defaultProps: {
            size: 'small'
         }
      },
      MuiCheckbox: {
         defaultProps: {
            size: 'small'
         }
      },
      MuiFab: {
         defaultProps: {
            size: 'small'
         }
      },
      MuiFormControl: {
         defaultProps: {
            size: 'small'
         }
      },
      MuiFormHelperText: {
         defaultProps: {
            margin: 'dense'
         }
      },
      MuiIconButton: {
         defaultProps: {
            size: 'small'
         }
      },
      MuiInputBase: {
         defaultProps: {
            fullWidth: true
         }
      },
      MuiInputLabel: {
         defaultProps: {}
      },
      MuiRadio: {
         defaultProps: {
            size: 'small'
         }
      },
      MuiSwitch: {
         defaultProps: {
            size: 'small'
         }
      },
      MuiTextField: {
         defaultProps: {
            size: 'small',
            fullWidth: true,
            sx: { margin: '8px 0' }
         }
      },
      MuiAutocomplete: {
         defaultProps: {
            size: 'small'
         }
      },
      MuiAccordion: {
         defaultProps: {
            disableGutters: true,
            elevation: 0,
            square: true,
            defaultExpanded: true
         }
      },
      MuiAccordionSummary: {
         defaultProps: {
            //  expandIcon: <ArrowDownwardIcon />,
            sx: { minHeight: 'auto' }
         }
      }
   },
   shape: {
      borderRadius: 2
   },
   spacing: 4,
   typography: {
      fontSize: 12,
      fontWeightBold: 400
   }
};
const theme =  createTheme({
   // palette:
   //  {
   //    mode: 'dark',
   //     primary: {
   //        main: '#0e639c' /* --theia-button-background */,
   //        contrastText: '#ffffff' /* --theia-button-foreground */,
   //        dark: '#1177bb' /* --theia-button-hoverBackground */,
   //        light: '#3794ff' /* --theia-editorInfo-foreground */
   //     },
   //    secondary: {
   //       main: '#3a3d41' /* --theia-button-secondaryBackground */,
   //       contrastText: '#ffffff' /* --theia-button-secondaryForeground */,
   //       dark: '#45494e' /* --theia-button-secondaryHoverBackground */,
   //       light: 'rgba(238, 238, 238, 0.7)' /* --theia-editorHint-foreground */
   //    },
   //    background: {
   //       default: '#1e1e1e' /* --theia-editor-background */,
   //       paper: '#1e1e1e' /* --theia-editor-background */
   //    },
   //    text: {
   //       primary: '#d4d4d4',
   //    }
   // },
palette: {
    "mode": "light",
    "primary": {
        "main": "#007acc",
        "contrastText": "#ffffff",
        "dark": "#0062a3",
        "light": "#1a85ff"
    },
    "secondary": {
        "main": "#5f6a79",
        "contrastText": "#ffffff",
        "dark": "#4c5561",
        "light": "#6c6c6c"
    },
    "background": {
        "default": "#ffffff",
        "paper": "#ffffff"
    },
    "text": {
        "primary": "#000000",
        "secondary": "rgba(0, 0, 0, 0.6)",
        "disabled": "rgba(0, 0, 0, 0.38)"
    },
    "common": {
        "black": "#000",
        "white": "#fff"
    },
    "error": {
        "main": "#d32f2f",
        "light": "#ef5350",
        "dark": "#c62828",
        "contrastText": "#fff"
    },
    "warning": {
        "main": "#ed6c02",
        "light": "#ff9800",
        "dark": "#e65100",
        "contrastText": "#fff"
    },
    "info": {
        "main": "#0288d1",
        "light": "#03a9f4",
        "dark": "#01579b",
        "contrastText": "#fff"
    },
    "success": {
        "main": "#2e7d32",
        "light": "#4caf50",
        "dark": "#1b5e20",
        "contrastText": "#fff"
    },
    "grey": {
        "50": "#fafafa",
        "100": "#f5f5f5",
        "200": "#eeeeee",
        "300": "#e0e0e0",
        "400": "#bdbdbd",
        "500": "#9e9e9e",
        "600": "#757575",
        "700": "#616161",
        "800": "#424242",
        "900": "#212121",
        "A100": "#f5f5f5",
        "A200": "#eeeeee",
        "A400": "#bdbdbd",
        "A700": "#616161"
    },
    "contrastThreshold": 3,
    "tonalOffset": 0.2,
    "divider": "rgba(0, 0, 0, 0.12)",
    "action": {
        "active": "rgba(0, 0, 0, 0.54)",
        "hover": "rgba(0, 0, 0, 0.04)",
        "hoverOpacity": 0.04,
        "selected": "rgba(0, 0, 0, 0.08)",
        "selectedOpacity": 0.08,
        "disabled": "rgba(0, 0, 0, 0.26)",
        "disabledBackground": "rgba(0, 0, 0, 0.12)",
        "disabledOpacity": 0.38,
        "focus": "rgba(0, 0, 0, 0.12)",
        "focusOpacity": 0.12,
        "activatedOpacity": 0.12
    }
 },
   ...sharedThemeOptions
 });

export default theme;
