Add common top-level Action type

This makes for better type inference.
This commit is contained in:
David Lechner
2020-05-26 21:20:08 -05:00
committed by David Lechner
parent 6713afe198
commit 6e4b22f841
15 changed files with 90 additions and 25 deletions
+1 -1
View File
@@ -2,7 +2,7 @@
// Copyright (c) 2020 The Pybricks Authors
import { connect } from 'react-redux';
import { Dispatch } from 'redux';
import { Dispatch } from '../actions';
import { flashFirmware } from '../actions/bootloader';
import * as notification from '../actions/notification';
import { RootState } from '../reducers';
+1 -1
View File
@@ -2,7 +2,7 @@
// Copyright (c) 2020 The Pybricks Authors
import { connect } from 'react-redux';
import { Dispatch } from 'redux';
import { Dispatch } from '../actions';
import * as editor from '../actions/editor';
import * as notification from '../actions/notification';
import { RootState } from '../reducers';
+1 -1
View File
@@ -4,7 +4,7 @@
import React from 'react';
import Toast from 'react-bootstrap/Toast';
import { connect } from 'react-redux';
import { Dispatch } from 'redux';
import { Dispatch } from '../actions';
import * as notification from '../actions/notification';
interface DispatchProps {
+1 -1
View File
@@ -2,7 +2,7 @@
// Copyright (c) 2020 The Pybricks Authors
import { connect } from 'react-redux';
import { Dispatch } from 'redux';
import { Dispatch } from '../actions';
import * as editor from '../actions/editor';
import { RootState } from '../reducers';
import ActionButton, { ActionButtonProps } from './ActionButton';
+1 -1
View File
@@ -4,10 +4,10 @@
import React from 'react';
import { connect } from 'react-redux';
import ResizeObserver from 'react-resize-observer';
import { Dispatch } from 'redux';
import { Subscription } from 'rxjs';
import { Terminal as XTerm } from 'xterm';
import { FitAddon } from 'xterm-addon-fit';
import { Dispatch } from '../actions';
import { receiveData } from '../actions/terminal';
import { terminalOutput } from '../epics/terminal';