@@ -15,9 +15,7 @@ export default function ExportButton() {
15
15
const [ modal , setModal ] = useState ( null ) ;
16
16
const state = useSelector ( ( store : RootState ) => store . appState ) ;
17
17
18
- const genOptions : string [ ] = [
19
- 'Export components'
20
- ] ;
18
+ const genOptions : string [ ] = [ 'Export components' ] ;
21
19
22
20
// Closes out the open modal
23
21
const closeModal = ( ) => setModal ( '' ) ;
@@ -27,6 +25,7 @@ export default function ExportButton() {
27
25
< List className = "export-preference" >
28
26
{ genOptions . map ( ( option : string , i : number ) => (
29
27
< ListItem
28
+ id = "export-modal"
30
29
key = { i }
31
30
onClick = { ( ) => chooseGenOptions ( ) }
32
31
style = { {
@@ -60,7 +59,7 @@ export default function ExportButton() {
60
59
) ;
61
60
} ;
62
61
63
- const exportKeyBind = useCallback ( e => {
62
+ const exportKeyBind = useCallback ( ( e ) => {
64
63
//Export Project
65
64
( e . key === 'e' && e . metaKey ) || ( e . key === 'e' && e . ctrlKey )
66
65
? showGenerateAppModal ( )
@@ -75,10 +74,18 @@ export default function ExportButton() {
75
74
} , [ ] ) ;
76
75
return (
77
76
< div >
78
- < button onClick = { showGenerateAppModal } > Export Project
79
- < svg xmlns = "http://www.w3.org/2000/svg" width = "16" height = "16" fill = "currentColor" className = "bi bi-download" viewBox = "0 0 16 16" >
80
- < path d = "M.5 9.9a.5.5 0 0 1 .5.5v2.5a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1v-2.5a.5.5 0 0 1 1 0v2.5a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2v-2.5a.5.5 0 0 1 .5-.5z" />
81
- < path d = "M7.646 11.854a.5.5 0 0 0 .708 0l3-3a.5.5 0 0 0-.708-.708L8.5 10.293V1.5a.5.5 0 0 0-1 0v8.793L5.354 8.146a.5.5 0 1 0-.708.708l3 3z" />
77
+ < button onClick = { showGenerateAppModal } >
78
+ Export Project
79
+ < svg
80
+ xmlns = "http://www.w3.org/2000/svg"
81
+ width = "16"
82
+ height = "16"
83
+ fill = "currentColor"
84
+ className = "bi bi-download"
85
+ viewBox = "0 0 16 16"
86
+ >
87
+ < path d = "M.5 9.9a.5.5 0 0 1 .5.5v2.5a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1v-2.5a.5.5 0 0 1 1 0v2.5a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2v-2.5a.5.5 0 0 1 .5-.5z" />
88
+ < path d = "M7.646 11.854a.5.5 0 0 0 .708 0l3-3a.5.5 0 0 0-.708-.708L8.5 10.293V1.5a.5.5 0 0 0-1 0v8.793L5.354 8.146a.5.5 0 1 0-.708.708l3 3z" />
82
89
</ svg >
83
90
</ button >
84
91
{ modal }
@@ -90,7 +97,6 @@ export default function ExportButton() {
90
97
//The below code is exclusive to ReacType's Electron App
91
98
//If you would like to deploy the app, please comment out the exportButton function above and uncomment the code below
92
99
93
-
94
100
// export default function ExportButton() {
95
101
// const [modal, setModal] = useState(null);
96
102
// const state = useSelector(store => store.appState)
0 commit comments