mirror of
https://github.com/hibiken/asynqmon.git
synced 2025-03-16 14:40:12 +08:00
18 lines
456 B
TypeScript
18 lines
456 B
TypeScript
|
// List of settings related action types.
|
||
|
export const POLL_INTERVAL_CHANGE = "POLL_INTERVAL_CHANGE";
|
||
|
|
||
|
interface PollIntervalChangeAction {
|
||
|
type: typeof POLL_INTERVAL_CHANGE;
|
||
|
value: number; // new poll interval value in seconds
|
||
|
}
|
||
|
|
||
|
// Union of all settings related action types.
|
||
|
export type SettingsActionTypes = PollIntervalChangeAction;
|
||
|
|
||
|
export function pollIntervalChange(value: number) {
|
||
|
return {
|
||
|
type: POLL_INTERVAL_CHANGE,
|
||
|
value,
|
||
|
};
|
||
|
}
|