From 23e4da200757db311b838d564b9d45a54a36bc38 Mon Sep 17 00:00:00 2001 From: erik-sn Date: Sat, 3 Oct 2020 11:07:21 -0400 Subject: [PATCH] moved navigation to use react router dom --- .../twitter/components/BottomNavigation.js | 19 ++++++++++++++++--- .../src/apps/twitter/components/TwitterApp.js | 9 ++++++++- 2 files changed, 24 insertions(+), 4 deletions(-) diff --git a/phone/src/apps/twitter/components/BottomNavigation.js b/phone/src/apps/twitter/components/BottomNavigation.js index 50d6353..91cd2b8 100644 --- a/phone/src/apps/twitter/components/BottomNavigation.js +++ b/phone/src/apps/twitter/components/BottomNavigation.js @@ -1,4 +1,5 @@ import React from "react"; +import { Link } from "react-router-dom"; import { makeStyles } from "@material-ui/core/styles"; import { BottomNavigation, BottomNavigationAction } from "@material-ui/core"; import HomeIcon from "@material-ui/icons/Home"; @@ -20,9 +21,21 @@ export function TwitterBottomNavigation({ activePage, handleChange }) { onChange={handleChange} className={classes.root} > - } /> - } /> - } /> + } + /> + } + /> + } + /> ); } diff --git a/phone/src/apps/twitter/components/TwitterApp.js b/phone/src/apps/twitter/components/TwitterApp.js index bc1daa8..d4b5fdb 100644 --- a/phone/src/apps/twitter/components/TwitterApp.js +++ b/phone/src/apps/twitter/components/TwitterApp.js @@ -1,4 +1,5 @@ import React, { useState, useEffect } from "react"; +import { Switch, Route } from "react-router-dom"; import { makeStyles } from "@material-ui/core/styles"; import Nui from "../../../os/nui-events/utils/Nui"; @@ -70,7 +71,13 @@ export const TwitterApp = () => {
- {PAGE_COMPONENT_MAPPING[activePage]} + + + + + + + {showTweetButton && }