@@ -26,14 +26,18 @@ const VersionToggle: React.FC = () => {
2626 const history = useHistory ( ) ;
2727 const isAnalyticsPage = history . location . pathname . includes ( '/analytics' ) ;
2828 const isPoolPage = history . location . pathname . includes ( '/pools' ) ;
29- const analyticsVersion = useAnalyticsVersion ( ) ;
29+ const analyticsVersion = useAnalyticsVersion ( ) ; // TODO: change default version in useAnalyticsVersion if it's needed to show total and v2
3030 const version =
3131 params && params . version
3232 ? params . version
3333 : isAnalyticsPage
3434 ? analyticsVersion
3535 : 'v3' ;
3636
37+ // Hide v2 and total tab for now
38+ const hideV2 = true ; // TODO: false to show v2
39+ const hideTotal = true ; // TODO: false to show total
40+
3741 useEffect ( ( ) => {
3842 updateIsV2 ( version === 'v2' ) ;
3943 updateIsLpLock ( version === 'lpLocker' ) ;
@@ -67,7 +71,7 @@ const VersionToggle: React.FC = () => {
6771
6872 return (
6973 < Box className = 'version-toggle-container' >
70- { v2Available && (
74+ { ! hideV2 && v2Available && (
7175 < Box
7276 className = { version === 'v2' ? 'version-toggle-active' : '' }
7377 onClick = { ( ) => {
@@ -143,14 +147,16 @@ const VersionToggle: React.FC = () => {
143147 < small > { t ( 'liquidityHub' ) } </ small >
144148 </ Box >
145149 ) }
146- < Box
147- className = { version === 'total' ? 'version-toggle-active' : '' }
148- onClick = { ( ) => {
149- redirectWithVersion ( 'total' ) ;
150- } }
151- >
152- < small > { t ( 'total' ) } </ small >
153- </ Box >
150+ { ! hideTotal && (
151+ < Box
152+ className = { version === 'total' ? 'version-toggle-active' : '' }
153+ onClick = { ( ) => {
154+ redirectWithVersion ( 'total' ) ;
155+ } }
156+ >
157+ < small > { t ( 'total' ) } </ small >
158+ </ Box >
159+ ) }
154160 </ >
155161 ) }
156162 </ Box >
0 commit comments