Skip to content

Commit

Permalink
Merge pull request #1366 from massenergize/rewiring-america
Browse files Browse the repository at this point in the history
feat:  #1298 Add rewiring america route
  • Loading branch information
archx3 authored Jun 25, 2024
2 parents c76a5f9 + 5cfa5a1 commit fe89810
Show file tree
Hide file tree
Showing 2 changed files with 39 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/AppRouter.js
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@ import ProfileSettings from "./components/Pages/ProfilePage/ProfileSettings";
import Celebrate from "./components/Pages/Widgets/Celebrate";
import METoast from "./components/Pages/Widgets/METoast/METoast";
import { child } from "firebase/database";
import RewiringAmerica from "./components/Pages/RewiringAmerica.js";

class AppRouter extends Component {
constructor(props) {
Expand Down Expand Up @@ -220,6 +221,7 @@ class AppRouter extends Component {
profile: `${prefix}/profile`,
policies: `${prefix}/policies`,
contactus: `${prefix}/contactus`,
rewiring_america: `${prefix}/rewiring-america`,
});

if (community) {
Expand Down Expand Up @@ -699,6 +701,11 @@ class AppRouter extends Component {
<Route exact path={links.profile} component={ProfilePage} />
<Route path={links.policies} component={PoliciesPage} />
<Route path={links.contactus} component={ContactPage} />
{/* <Route path={links.rewiring_america} component={RewiringAmerica} /> */}
<Route
path={links.rewiring_america}
component={RewiringAmerica}
/>
<Route component={HomePage} />
{/* This was something for completeing registration for invited users, not needed? <Route path="/completeRegistration?" component={RegisterPage} />*/}
</Switch>
Expand Down
32 changes: 32 additions & 0 deletions src/components/Pages/RewiringAmerica.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
import React from "react";
import Seo from "../Shared/Seo";
import { useSelector } from "react-redux";
import URLS from "../../api/urls";

function RewiringAmerica() {
const community = useSelector((state) => state?.page?.community);
return (
<div style={{ paddingTop: 50 }}>
{Seo({
title: "Rewiring America",
description: "",
url: `${window?.location?.pathname}`,
site_name: community?.name,
})}
<div style={{ width: "100%", height: "100vh", background: "white" }}>
<iframe
src={`${URLS.ROOT}/rewiring_america`}
title="Rewiring America"
style={{
width: "100%",
height: "100%",
border: "none",
overflow: "hidden",
}}
></iframe>
</div>
</div>
);
}

export default RewiringAmerica;

0 comments on commit fe89810

Please sign in to comment.