move images out of public/static folder

This way, we get compile error if there problem with images. Also allows
images to be optimized.
This commit is contained in:
David Lechner
2020-05-26 21:20:08 -05:00
committed by David Lechner
parent 865d37a138
commit 3e4ea382e5
19 changed files with 18 additions and 16 deletions
+4 -2
View File
@@ -9,6 +9,8 @@ import { RootState } from '../reducers';
import { BLEConnectionState } from '../reducers/ble';
import { BootloaderConnectionState } from '../reducers/bootloader';
import ActionButton, { ActionButtonProps } from './ActionButton';
import btConnectedIcon from './images/bt-connected.svg';
import btDisconnectedIcon from './images/bt-disconnected.svg';
type Dispatch = ThunkDispatch<{}, {}, AnyAction>;
@@ -23,14 +25,14 @@ const mapStateToProps = (state: RootState): StateProps => {
) {
return {
tooltip: 'Connect using Bluetooth',
icon: 'btdisconnected.svg',
icon: btDisconnectedIcon,
context: 'connect',
enabled: true,
};
} else {
return {
tooltip: 'Disconnect Bluetooth',
icon: 'btconnected.svg',
icon: btConnectedIcon,
context: 'disconnect',
enabled: state.ble.connection === BLEConnectionState.Connected,
};