@@ -3,7 +3,6 @@ import { Dispatch } from 'redux';
3
3
import { IconType } from 'react-icons' ;
4
4
import { BiTargetLock } from 'react-icons/bi' ;
5
5
import { BsFillExclamationOctagonFill } from 'react-icons/bs' ;
6
- import { FiLayers , FiZoomIn , FiZoomOut } from 'react-icons/fi' ;
7
6
import { FaCompass } from 'react-icons/fa' ;
8
7
import { GiRailway } from 'react-icons/gi' ;
9
8
import { isNil } from 'lodash' ;
@@ -15,6 +14,7 @@ import { selectLayers } from 'reducers/editor';
15
14
import { Shortcut } from 'utils/hooks/useKeyboardShortcuts' ;
16
15
import { ModalContextType } from 'common/BootstrapSNCF/ModalSNCF/ModalProvider' ;
17
16
import InfraSelectorModal from 'common/InfraSelector/InfraSelectorModal' ;
17
+ import { GoSearch , GoStack , GoZoomIn , GoZoomOut } from 'react-icons/go' ;
18
18
import { EditorState , EDITOAST_TO_LAYER_DICT , EditoastType } from './tools/types' ;
19
19
import LayersModal from './components/LayersModal' ;
20
20
import { SelectionState } from './tools/selection/types' ;
@@ -52,6 +52,7 @@ export interface NavButton {
52
52
setViewport : ( newViewport : Partial < Viewport > ) => void ;
53
53
openModal : ModalContextType [ 'openModal' ] ;
54
54
closeModal : ModalContextType [ 'closeModal' ] ;
55
+ setIsSearchToolOpened : React . Dispatch < React . SetStateAction < boolean > > ;
55
56
mapRef : MapRef ;
56
57
} ,
57
58
toolContext : {
@@ -65,9 +66,17 @@ export interface NavButton {
65
66
66
67
const NavButtons : NavButton [ ] [ ] = [
67
68
[
69
+ {
70
+ id : 'search' ,
71
+ icon : GoSearch ,
72
+ labelTranslationKey : 'common.search' ,
73
+ onClick ( { setIsSearchToolOpened } ) {
74
+ setIsSearchToolOpened ( ( state ) => ! state ) ;
75
+ } ,
76
+ } ,
68
77
{
69
78
id : 'zoom-in' ,
70
- icon : FiZoomIn ,
79
+ icon : GoZoomIn ,
71
80
labelTranslationKey : 'common.zoom-in' ,
72
81
onClick ( { setViewport, viewport } ) {
73
82
setViewport ( {
@@ -78,7 +87,7 @@ const NavButtons: NavButton[][] = [
78
87
} ,
79
88
{
80
89
id : 'zoom-out' ,
81
- icon : FiZoomOut ,
90
+ icon : GoZoomOut ,
82
91
labelTranslationKey : 'common.zoom-out' ,
83
92
onClick ( { setViewport, viewport } ) {
84
93
setViewport ( {
@@ -114,7 +123,7 @@ const NavButtons: NavButton[][] = [
114
123
[
115
124
{
116
125
id : 'layers' ,
117
- icon : FiLayers ,
126
+ icon : GoStack ,
118
127
labelTranslationKey : 'Editor.nav.toggle-layers' ,
119
128
shortcut : { code : 'KeyL' , optionalKeys : { ctrlKey : true , shiftKey : true } } ,
120
129
onClick ( { openModal, editorState } , { activeTool, toolState, setToolState } ) {
0 commit comments