import { QueryWindowReducer, QueryWindowState } from "./QueryWindow";
import { EditArtistWindowReducer, EditArtistWindowState } from "./EditArtistWindow";

export enum WindowType {
    Query = "Query",
    EditArtist = "EditArtist",
}

export type WindowState = QueryWindowState | EditArtistWindowState;

export const newWindowReducer = {
    [WindowType.Query]: QueryWindowReducer,
    [WindowType.EditArtist]: EditArtistWindowReducer,
}

export const newWindowState = {
    [WindowType.Query]: () => {
        return {
            editingQuery: false,
            query: null,
            resultsForQuery: null,
        };
    },
    [WindowType.EditArtist]: () => {

    }
}