const mongoose = require("mongoose");
const Schema = mongoose.Schema;

const configSchema = new Schema({
  theme: { type: String },
  customTheme: { type: Boolean },
  customThemeColors: [{ type: String }],
  favThemes: [{ type: String }],
  showKeyTips: { type: Boolean },
  showLiveWpm: { type: Boolean },
  showTimerProgress: { type: Boolean },
  smoothCaret: { type: Boolean },
  quickTab: { type: Boolean },
  punctuation: { type: Boolean },
  numbers: { type: Boolean },
  words: { type: Number },
  time: { type: Number },
  mode: { type: String },
  quoteLength: [{ type: Number }],
  language: { type: String },
  fontSize: { type: Number },
  freedomMode: { type: Boolean },
  difficulty: { type: String },
  blindMode: { type: Boolean },
  quickEnd: { type: Boolean },
  caretStyle: { type: String },
  paceCaretStyle: { type: String },
  flipTestColors: { type: Boolean },
  capsLockBackspace: { type: Boolean },
  layout: { type: String },
  confidenceMode: { type: String },
  indicateTypos: { type: Boolean },
  timerStyle: { type: String },
  colorfulMode: { type: Boolean },
  randomTheme: { type: String }, //feels like this should be a boolean
  timerColor: { type: String },
  timerOpacity: { type: String }, //maybe should be a number
  stopOnError: { type: String },
  showAllLines: { type: Boolean },
  keymapMode: { type: String },
  keymapStyle: { type: String },
  keymapLegendStyle: { type: String },
  keymapLayout: { type: String },
  fontFamily: { type: String },
  smoothLineScroll: { type: Boolean },
  alwaysShowDecimalPlaces: { type: Boolean },
  alwaysShowWordsHistory: { type: Boolean },
  singleListCommandLine: { type: String },
  playSoundOnError: { type: Boolean },
  playSoundOnClick: { type: String },
  startGraphsAtZero: { type: Boolean },
  swapEscAndTab: { type: Boolean },
  showOutOfFocusWarning: { type: Boolean },
  paceCaret: { type: String },
  paceCaretCustomSpeed: { type: Number },
  pageWidth: { type: String },
  chartAccuracy: { type: Boolean },
  chartStyle: { type: String },
  minWpm: { type: String },
  minWpmCustomSpeed: { type: Number },
  highlightMode: { type: String },
  alwaysShowCPM: { type: Boolean },
  enableAds: { type: String },
  hideExtraLetters: { type: Boolean },
  strictSpace: { type: Boolean },
  minAcc: { type: String },
  minAccCustom: { type: Number },
  showLiveAcc: { type: Boolean },
  monkey: { type: Boolean },
  repeatQuotes: { type: String },
  oppositeShiftMode: { type: String },
  customBackground: { type: String },
  customBackgroundSize: { type: String },
  customBackgroundFilter: [{ type: Number }],
  customLayoutfluid: { type: String },
});

module.exports = { configSchema };
