@@ -6,7 +6,6 @@ import { connect } from 'react-redux';
6
6
import { HandlerProps } from 'react-reflex' ;
7
7
import { useMediaQuery } from 'react-responsive' ;
8
8
import { bindActionCreators , Dispatch } from 'redux' ;
9
- import { createStructuredSelector } from 'reselect' ;
10
9
import store from 'store' ;
11
10
import { editor } from 'monaco-editor' ;
12
11
import type { FitAddon } from 'xterm-addon-fit' ;
@@ -22,6 +21,7 @@ import {
22
21
ChallengeNode ,
23
22
CompletedChallenge ,
24
23
ResizeProps ,
24
+ SavedChallenge ,
25
25
SavedChallengeFiles ,
26
26
Test
27
27
} from '../../../redux/prop-types' ;
@@ -72,11 +72,11 @@ import { mergeChallengeFiles } from './saved-challenges';
72
72
import './classic.css' ;
73
73
import '../components/test-frame.css' ;
74
74
75
- const mapStateToProps = createStructuredSelector ( {
76
- challengeFiles : challengeFilesSelector ,
77
- output : consoleOutputSelector ,
78
- isChallengeCompleted : isChallengeCompletedSelector ,
79
- savedChallenges : savedChallengesSelector
75
+ const mapStateToProps = ( state : unknown ) => ( {
76
+ challengeFiles : challengeFilesSelector ( state ) as ChallengeFiles ,
77
+ output : consoleOutputSelector ( state ) as string [ ] ,
78
+ isChallengeCompleted : isChallengeCompletedSelector ( state ) as boolean ,
79
+ savedChallenges : savedChallengesSelector ( state ) as SavedChallenge [ ]
80
80
} ) ;
81
81
82
82
const mapDispatchToProps = ( dispatch : Dispatch ) =>
@@ -120,7 +120,7 @@ interface ShowClassicProps extends Pick<PreviewProps, 'previewMounted'> {
120
120
openModal : ( modal : string ) => void ;
121
121
setEditorFocusability : ( canFocus : boolean ) => void ;
122
122
setIsAdvancing : ( arg : boolean ) => void ;
123
- savedChallenges : CompletedChallenge [ ] ;
123
+ savedChallenges : SavedChallenge [ ] ;
124
124
}
125
125
126
126
interface ReflexLayout {
0 commit comments