import type { FileSection } from '../../components/ui/FilesManager/src/fileType'; import type { ViewerKey, ViewerNames } from '../../types/dbTypes'; import type { ActionMap } from '../ActionMap'; export declare const DEFAULT_FILE_TAB_SECTION_ORDER: readonly FileSection[]; export type SidebarTabType = 'file' | 'layers' | 'communication' | 'sensors' | 'settings'; /** A built-in tab or a plugin one. Separate from `SidebarTabType`, which stays exhaustive. */ export type SidebarTabKey = SidebarTabType | `plugin:${string}`; /** Request from a viewer marker to open a comment's editor/reply box in the sidebar. */ export type CommentActionRequest = { commentId: number; action: 'edit' | 'reply'; /** Monotonic id so the same request fires again even if the target is unchanged. */ requestId: number; }; /** Request from a viewer marker to open a sensor's editor in the sidebar. */ export type SensorActionRequest = { sensorId: number; action: 'edit'; /** Monotonic id so the same request fires again even if the target is unchanged. */ requestId: number; }; interface MenusTypes { currentViewer: ViewerKey; rowsPerPage: number; selectedTab: SidebarTabKey; commentsVisibleInViewer: ViewerNames[]; currentCommentId: number | null; /** Comment double-clicked to zoom/focus. Drives the thick focus ring + camera move. */ focusedCommentId: number | null; /** Monotonic counter bumped on every focus dispatch so re-focusing the same comment re-zooms. */ focusRequestId: number; pendingCommentAction: CommentActionRequest | null; sensorsVisibleInViewer: ViewerNames[]; visibleSensorTypes: Partial>; visibleSensorTags: Partial>; currentSensorId: number | null; currentSensorTypeId: number | null; /** Sensor double-clicked to zoom/focus. Drives the thick focus ring + camera move. */ focusedSensorId: number | null; /** Monotonic counter bumped on every sensor focus dispatch so re-focusing re-zooms. */ sensorFocusRequestId: number; pendingSensorAction: SensorActionRequest | null; /** Legend card shown for this viewer. An absent entry means shown. */ sensorLegendVisible: Partial>; /** Sensor type the legend is pinned to, overriding the focused sensor's own type. */ sensorLegendTypeId: Partial>; /** File tab section order, as left by the user's last reorder. Session-lived. */ fileTabSectionOrder: readonly FileSection[]; } export type MenusState = MenusTypes; export type MenusPayload = { ['SET_VIEWER']: Pick; ['SET_PAGINATION_ROWS_PER_PAGE']: Pick; ['SET_SIDEBAR_SELECTED_TAB']: Pick; ['SHOW_COMMENTS_IN_VIEWER']: { viewer: ViewerNames; }; ['HIDE_COMMENTS_IN_VIEWER']: { viewer: ViewerNames; }; ['SET_CURRENT_COMMENT_ID']: { commentId: number | null; }; ['SET_FOCUSED_COMMENT_ID']: { commentId: number | null; }; ['REQUEST_COMMENT_ACTION']: { commentId: number; action: 'edit' | 'reply'; }; ['CLEAR_PENDING_COMMENT_ACTION']: undefined; ['TOGGLE_SENSOR_TYPE_VISIBILITY']: { viewer: ViewerNames; sensorTypeId: number; force?: boolean; }; ['TOGGLE_SENSOR_TAG_VISIBILITY']: { viewer: ViewerNames; sensorTag: string; force?: boolean; }; ['SHOW_ALL_SENSOR_IN_VIEWER']: { viewer: ViewerNames; }; ['HIDE_ALL_SENSORS_IN_VIEWER']: { viewer: ViewerNames; }; ['HIDE_ALL_SENSOR_TAGS_IN_VIEWER']: { viewer: ViewerNames; }; ['SET_CURRENT_SENSOR_ID']: Pick; ['SET_CURRENT_SENSOR_TYPE_ID']: Pick; ['SET_FOCUSED_SENSOR_ID']: { sensorId: number | null; }; ['REQUEST_SENSOR_ACTION']: { sensorId: number; }; ['CLEAR_PENDING_SENSOR_ACTION']: undefined; /** `visible` sets explicitly; omit it to flip. Not the `force` ("only show") shape used by * the visibility toggles above, because the legend's close button needs an explicit hide. */ ['TOGGLE_SENSOR_LEGEND']: { viewer: ViewerNames; visible?: boolean; }; ['SET_SENSOR_LEGEND_TYPE_ID']: { viewer: ViewerNames; sensorTypeId: number | null; }; ['SET_FILE_TAB_SECTION_ORDER']: Pick; }; export type MenusActions = ActionMap[keyof ActionMap]; export declare const MenusReducer: (state: MenusState, action: MenusActions) => MenusTypes; export {}; //# sourceMappingURL=reducer.d.ts.map