All files / src/theme/ui palette.js

100% Statements 13/13
100% Branches 2/2
100% Functions 1/1
100% Lines 13/13

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147                12x                         12x                 12x                 12x                 12x                 12x                 12x                 12x         12x                   12x                               91x                                     91x                                     91x    
import { alpha } from '@mui/material/styles';
 
// ----------------------------------------------------------------------
 
 
 
// SETUP COLORS
 
export const grey = {
  0: '#FFFFFF',
  100: '#F9FAFB',
  200: '#F4F6F8',
  300: '#DFE3E8',
  400: '#C4CDD5',
  500: '#919EAB',
  600: '#637381',
  700: '#454F5B',
  800: '#212B36',
  900: '#161C24',
};
 
export const primary = {
    lighter: "#E6F4FC",
    light: "#5BB8EA",
    main: "#0091DE",
    dark: "#007AB8",
    darker: "#005A87",
    contrastText: "#FFFFFF",
};
 
export const secondary = {
    lighter: "#EBF5FF",
    light: "#7EC8F5",
    main: "#38A3E8",
    dark: "#1E88C9",
    darker: "#156595",
    contrastText: "#FFFFFF",
};
 
export const info = {
    lighter: "#E6F4FC",
    light: "#5BB8EA",
    main: "#0091DE",
    dark: "#007AB8",
    darker: "#005A87",
    contrastText: "#FFFFFF",
};
 
export const success = {
  lighter: '#D8FBDE',
  light: '#86E8AB',
  main: '#36B37E',
  dark: '#1B806A',
  darker: '#0A5554',
  contrastText: '#FFFFFF',
};
 
export const warning = {
  lighter: '#FFF5CC',
  light: '#FFD666',
  main: '#FFAB00',
  dark: '#B76E00',
  darker: '#7A4100',
  contrastText: grey[800],
};
 
export const error = {
  lighter: '#FFE9D5',
  light: '#FFAC82',
  main: '#FF5630',
  dark: '#B71D18',
  darker: '#7A0916',
  contrastText: '#FFFFFF',
};
 
export const common = {
  black: '#000000',
  white: '#FFFFFF',
};
 
export const action = {
  hover: alpha(grey[500], 0.08),
  selected: alpha(grey[500], 0.16),
  disabled: alpha(grey[500], 0.8),
  disabledBackground: alpha(grey[500], 0.24),
  focus: alpha(grey[500], 0.24),
  hoverOpacity: 0.08,
  disabledOpacity: 0.48,
};
 
const base = {
  primary,
  secondary,
  info,
  success,
  warning,
  error,
  grey,
  common,
  divider: alpha(grey[500], 0.2),
  action,
};
 
// ----------------------------------------------------------------------
 
export function palette(mode) {
  const light = {
    ...base,
    mode: 'light',
    text: {
      primary: grey[800],
      secondary: grey[600],
      disabled: grey[500],
    },
    background: {
      paper: '#FFFFFF',
      default: '#F4F9FD',
      neutral: '#E8F2FA',
    },
    action: {
      ...base.action,
      active: grey[600],
    },
  };
 
  const dark = {
    ...base,
    mode: 'dark',
    text: {
      primary: '#FFFFFF',
      secondary: grey[500],
      disabled: grey[600],
    },
    background: {
      paper: '#1E293B',
      default: '#0F172A',
      neutral: alpha('#64748B', 0.16),
    },
    action: {
      ...base.action,
      active: grey[500],
    },
  };
 
  return mode === 'light' ? light : dark;
}