learn-morse-code/src/app-modes/PracticeMode.js

23 lines
663 B
JavaScript
Raw Normal View History

import React, {useContext} from 'react';
2020-01-09 10:06:38 +01:00
import '../css/App.css';
import {KeyTypeContext} from "../contexts/keyTypeContext"
import StraightKey from '../components/StraightKey'
import ElectronicKey from '../components/ElectronicKey'
2020-01-09 10:06:38 +01:00
import MorseBufferDisplay from '../components/MorseBufferDisplay'
2020-01-19 04:35:11 +01:00
import MorseHistory from '../components/MorseHistory'
2020-01-09 10:06:38 +01:00
export default React.memo(function PracticeMode() {
const {keyType} = useContext(KeyTypeContext)
2020-01-09 10:06:38 +01:00
return (
<>
2020-01-19 04:35:11 +01:00
{/* {keyType === "straight" ? <StraightKey /> : <ElectronicKey />}
<MorseBufferDisplay /><br/>
2020-01-19 04:35:11 +01:00
<MorseHistory /><br/> */}
2020-01-09 10:06:38 +01:00
</>
);
})