UNPKG

lml-main

Version:

This is now a mono repository published into many standalone packages.

108 lines (107 loc) 3.64 kB
import { AppState } from '../../common/reducers'; export declare const SET_ACTIVE_JOB = "SET_ACTIVE_JOB"; export declare const UNSET_ACTIVE_JOB = "UNSET_ACTIVE_JOB"; export declare const SET_JOB_EXPANDED = "SET_JOB_EXPANDED"; export declare const SET_JOB_COLLAPSED = "SET_JOB_COLLAPSED"; export declare const SET_ALL_JOBS_EXPANDED = "SET_ALL_JOBS_EXPANDED"; export declare const SET_ALL_JOBS_COLLAPSED = "SET_ALL_JOBS_COLLAPSED"; export declare const SET_JUMP_TO_JOB = "SET_JUMP_TO_JOB"; export declare const SET_VISIBLE_JOBS = "SET_VISIBLE_JOBS"; export declare const SHOW_JOB_DIRECTIONS = "SHOW_JOB_DIRECTIONS"; export declare const HIDE_JOB_DIRECTIONS = "HIDE_JOB_DIRECTIONS"; export interface SetActiveJobAction { type: 'SET_ACTIVE_JOB'; refId: string; } export interface UnsetActiveJobAction { type: 'UNSET_ACTIVE_JOB'; refId: string; } export interface SetJobExpandedAction { type: 'SET_JOB_EXPANDED'; refId: string; } export interface SetJobCollapsedAction { type: 'SET_JOB_COLLAPSED'; refId: string; } export interface SetAllJobsExpandedAction { type: 'SET_ALL_JOBS_EXPANDED'; refId: string; } export interface SetAllJobsCollapsedAction { type: 'SET_ALL_JOBS_COLLAPSED'; refId: string; } export interface SetJumpToJobAction { type: 'SET_JUMP_TO_JOB'; refId: string; } export interface ShowJobDirectionsAction { type: 'SHOW_JOB_DIRECTIONS'; refId: string; } export interface HideJobDirectionsAction { type: 'HIDE_JOB_DIRECTIONS'; refId: string; } export declare type JobFlagAction = SetActiveJobAction | UnsetActiveJobAction | SetJobExpandedAction | SetJobCollapsedAction | SetAllJobsExpandedAction | SetAllJobsCollapsedAction | ShowJobDirectionsAction | HideJobDirectionsAction | SetJumpToJobAction; /** * Set the active job to a given id or to null * * @param refId */ export declare const setActiveJob: (refId: string) => SetActiveJobAction; /** * If the provided job refId is currently active then set it to null */ export declare const unsetActiveJob: (refId?: string) => UnsetActiveJobAction; /** * Add a job's refId to the array of expanded jobs * * @param refId * @param expanded */ export declare const setJobExpanded: (refId: string) => SetJobExpandedAction; /** * Remove a job's refId from the array of expanded jobs * * @param refId * @param expanded */ export declare const setJobCollapsed: (refId: string) => SetJobCollapsedAction; /** * Mark all jobs as expanded */ export declare const setAllJobsExpanded: () => { type: string; }; /** * Mark all jobs as expanded */ export declare const setAllJobsCollapsed: () => { type: string; }; /** * Set the showingDirections refId in the job flags state * * @param refId * @param showingDirections */ export declare const showJobDirections: (refId: string) => ShowJobDirectionsAction; /** * Reset the showingDirections refId in the job flags state * * @param refId */ export declare const hideJobDirections: (refId: string) => HideJobDirectionsAction; /** * Jumping to a particular job is required by the keyboard shortcuts * * @param refId */ export declare const setJumpToJob: (refId: string) => SetJumpToJobAction; export declare const expandActiveJob: () => (dispatch: (action: any) => void, getState: any) => void; export declare const activateFirstJobIfNoneActive: () => (dispatch: (action: any) => void, getState: any) => void; export declare const activatePreviousJob: () => (dispatch: (action: any) => void, getState: () => AppState) => void; export declare const activateNextJob: () => (dispatch: (action: any) => void, getState: () => AppState) => void;