1- import { IonContent , IonHeader , IonIcon , IonLabel , IonPage , IonRouterOutlet , IonTabBar , IonTabButton , IonTabs , IonTitle , IonToolbar } from '@ionic/react' ;
1+ import {
2+ IonContent ,
3+ IonHeader ,
4+ IonIcon ,
5+ IonLabel ,
6+ IonPage ,
7+ IonRouterOutlet ,
8+ IonTabBar ,
9+ IonTabButton ,
10+ IonTabs ,
11+ IonTitle ,
12+ IonToolbar ,
13+ } from '@ionic/react' ;
214import { homeOutline , radioOutline , libraryOutline , searchOutline } from 'ionicons/icons' ;
315import React from 'react' ;
416import { Route , Redirect } from 'react-router-dom' ;
@@ -57,38 +69,40 @@ const SearchPage: React.FC = () => (
5769
5870const TabsDirectNavigation : React . FC = ( ) => {
5971 return (
60- < IonTabs data-testid = "tabs-direct-navigation" >
61- < IonRouterOutlet >
62- < Redirect exact path = "/tabs-direct-navigation" to = "/tabs-direct-navigation/home" />
63- < Route path = "/tabs-direct-navigation/home" render = { ( ) => < HomePage /> } exact = { true } />
64- < Route path = "/tabs-direct-navigation/radio" render = { ( ) => < RadioPage /> } exact = { true } />
65- < Route path = "/tabs-direct-navigation/library" render = { ( ) => < LibraryPage /> } exact = { true } />
66- < Route path = "/tabs-direct-navigation/search" render = { ( ) => < SearchPage /> } exact = { true } />
67- </ IonRouterOutlet >
72+ < IonPage >
73+ < IonTabs data-testid = "tabs-direct-navigation" >
74+ < IonRouterOutlet >
75+ < Redirect exact path = "/tabs-direct-navigation" to = "/tabs-direct-navigation/home" />
76+ < Route path = "/tabs-direct-navigation/home" render = { ( ) => < HomePage /> } exact = { true } />
77+ < Route path = "/tabs-direct-navigation/radio" render = { ( ) => < RadioPage /> } exact = { true } />
78+ < Route path = "/tabs-direct-navigation/library" render = { ( ) => < LibraryPage /> } exact = { true } />
79+ < Route path = "/tabs-direct-navigation/search" render = { ( ) => < SearchPage /> } exact = { true } />
80+ </ IonRouterOutlet >
6881
69- < IonTabBar slot = "bottom" data-testid = "tab-bar" >
70- < IonTabButton tab = "home" href = "/tabs-direct-navigation/home" data-testid = "home-tab" >
71- < IonIcon icon = { homeOutline } > </ IonIcon >
72- < IonLabel > Home</ IonLabel >
73- </ IonTabButton >
82+ < IonTabBar slot = "bottom" data-testid = "tab-bar" >
83+ < IonTabButton tab = "home" href = "/tabs-direct-navigation/home" data-testid = "home-tab" >
84+ < IonIcon icon = { homeOutline } > </ IonIcon >
85+ < IonLabel > Home</ IonLabel >
86+ </ IonTabButton >
7487
75- < IonTabButton tab = "radio" href = "/tabs-direct-navigation/radio" data-testid = "radio-tab" >
76- < IonIcon icon = { radioOutline } > </ IonIcon >
77- < IonLabel > Radio</ IonLabel >
78- </ IonTabButton >
88+ < IonTabButton tab = "radio" href = "/tabs-direct-navigation/radio" data-testid = "radio-tab" >
89+ < IonIcon icon = { radioOutline } > </ IonIcon >
90+ < IonLabel > Radio</ IonLabel >
91+ </ IonTabButton >
7992
80- < IonTabButton tab = "library" href = "/tabs-direct-navigation/library" data-testid = "library-tab" >
81- < IonIcon icon = { libraryOutline } > </ IonIcon >
82- < IonLabel > Library</ IonLabel >
83- </ IonTabButton >
93+ < IonTabButton tab = "library" href = "/tabs-direct-navigation/library" data-testid = "library-tab" >
94+ < IonIcon icon = { libraryOutline } > </ IonIcon >
95+ < IonLabel > Library</ IonLabel >
96+ </ IonTabButton >
8497
85- < IonTabButton tab = "search" href = "/tabs-direct-navigation/search" data-testid = "search-tab" >
86- < IonIcon icon = { searchOutline } > </ IonIcon >
87- < IonLabel > Search</ IonLabel >
88- </ IonTabButton >
89- </ IonTabBar >
90- </ IonTabs >
98+ < IonTabButton tab = "search" href = "/tabs-direct-navigation/search" data-testid = "search-tab" >
99+ < IonIcon icon = { searchOutline } > </ IonIcon >
100+ < IonLabel > Search</ IonLabel >
101+ </ IonTabButton >
102+ </ IonTabBar >
103+ </ IonTabs >
104+ </ IonPage >
91105 ) ;
92106} ;
93107
94- export default TabsDirectNavigation ;
108+ export default TabsDirectNavigation ;
0 commit comments