var _a;
import { createSlice } from '@reduxjs/toolkit';
import { DocLocViews } from 'src/lib/types/types';
export var initMarkerPos = { top: -9999999, left: -9999999 };
var initialState = {
    hoveredMarkerId: 0,
    clickedMarkerId: 0,
    scrollToDocId: 0,
    clickedMarkerPosition: initMarkerPos,
    filtersHeight: 0,
    zipLatLng: {},
    comingFromInsideApp: false,
    view: DocLocViews.WELCOME,
    partner: {},
    mobileMapView: false,
    alertModal: { show: false },
    programEnabled: "",
};
export var commonSlice = createSlice({
    name: 'common',
    initialState: initialState,
    reducers: {
        setHoveredMarkerId: function (state, action) {
            state.hoveredMarkerId = action.payload;
        },
        setClickedMarkerId: function (state, action) {
            state.clickedMarkerId = action.payload;
        },
        setClickedMarkerPos: function (state, action) {
            state.clickedMarkerPosition = action.payload;
        },
        setFiltersHeight: function (state, action) {
            state.filtersHeight = action.payload;
        },
        setZipLatLng: function (state, action) {
            state.zipLatLng = action.payload;
        },
        setComingFromInsideApp: function (state, action) {
            state.comingFromInsideApp = action.payload;
        },
        setView: function (state, action) {
            state.view = action.payload;
        },
        setPartner: function (state, action) {
            state.partner = action.payload;
        },
        setMobileMapView: function (state, action) {
            state.mobileMapView = action.payload;
        },
        setScrollToDocId: function (state, action) {
            state.scrollToDocId = action.payload;
        },
        setAlertModal: function (state, action) {
            state.alertModal = action.payload;
        },
        setProgramEnabled: function (state, action) {
            state.programEnabled = action.payload;
        },
    },
});
export var setHoveredMarkerId = (_a = commonSlice.actions, _a.setHoveredMarkerId), setClickedMarkerId = _a.setClickedMarkerId, setClickedMarkerPos = _a.setClickedMarkerPos, setFiltersHeight = _a.setFiltersHeight, setZipLatLng = _a.setZipLatLng, setComingFromInsideApp = _a.setComingFromInsideApp, setView = _a.setView, setPartner = _a.setPartner, setMobileMapView = _a.setMobileMapView, setScrollToDocId = _a.setScrollToDocId, setAlertModal = _a.setAlertModal, setProgramEnabled = _a.setProgramEnabled;
export default commonSlice.reducer;
