"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.theme = theme;
var _actionTypes = require("../constants/actionTypes");
function theme() {
  let state = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {
    theme: 'default',
    scheme: 'default',
    colorPreference: 'auto'
  };
  let action = arguments.length > 1 ? arguments[1] : undefined;
  if (action.type === _actionTypes.CHANGE_THEME) {
    return {
      theme: action.theme,
      scheme: action.scheme,
      colorPreference: action.colorPreference
    };
  }
  return state;
}