import React from "react"; 
import {StatusBar,StyleSheet,} from 'react-native';

const initialState = {
    PageTheme: {},
    customStyle: StyleSheet.create({}),
    globalStyle: StyleSheet.create({}),
    customeButtonStyle:StyleSheet.create({}),
    ModalStyle:StyleSheet.create({}),
    DarkMode:false,   
};

const themeReducer = (state = initialState, action) => {
    switch(action.type) {
        case 'GET_THEME':
            return {...state};
        case 'SET_THEME_STYLES':              
            return {...state,PageTheme:action.PageTheme,customStyle:action.customStyle,globalStyle:action.globalStyle,ModalStyle:action.ModalStyle,customeButtonStyle:action.customeButtonStyle};
        case 'SET_THEME':              
            return {...state,DarkMode:action.DarkMode};        
        default:
            return state;
    }
}
export default themeReducer;