-
Notifications
You must be signed in to change notification settings - Fork 111
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
required padding added, added dev-tools link in footer
- Loading branch information
1 parent
0794959
commit f5b5129
Showing
8 changed files
with
59 additions
and
126 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes
File renamed without changes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,58 +1,45 @@ | ||
import Header from "../layout/Header.jsx"; | ||
import Footer from "../layout/Footer.jsx"; | ||
import Section from "../layout/Section.jsx"; | ||
import style from "../style/index.js"; | ||
import PageHeader from "../layout/PageHeader.jsx"; | ||
import { devTools } from "../data/developerToolsList.js"; | ||
import useDisplayCategory from "../hooks/useDisplayCategory.js"; | ||
import { Link, Outlet, useLocation } from "react-router-dom"; | ||
import { Outlet, useLocation } from "react-router-dom"; | ||
import { Helmet } from "react-helmet"; | ||
import LinkButton from "../controls/LinkButton.jsx"; | ||
import { useEffect, useState } from "react"; | ||
|
||
|
||
export default function DeveloperLayout() { | ||
const location = useLocation(); | ||
const pathParts = location.pathname.split("/"); | ||
const countryId = pathParts[1]; // Assumes the countryId is always the second segment in the path | ||
const displayCategory = useDisplayCategory(); | ||
const { pathname } = useLocation(); | ||
|
||
|
||
if (pathname.length > 20) { | ||
return ( | ||
<main> | ||
<Outlet /> | ||
</main> | ||
); | ||
} | ||
|
||
return ( | ||
<> | ||
<main> | ||
<Helmet> | ||
<title>Developer Hub | PolicyEngine</title> | ||
<title>Developer Tools | PolicyEngine</title> | ||
</Helmet> | ||
<div> | ||
<div > | ||
<Header /> | ||
|
||
<PageHeader | ||
title="Developer Hub" | ||
title="Developer Tools" | ||
backgroundColor={style.colors.BLUE_98} | ||
> | ||
<p style={{ margin: 0 }}> | ||
Welcome to the Developer Hub page for PolicyEngine! This hub is | ||
Welcome to the Developer Tools page for PolicyEngine! This hub is | ||
designed to enhance your experience with our open-source projects by | ||
providing quick access to essential resources. | ||
</p> | ||
</PageHeader> | ||
|
||
<Outlet /> | ||
<Footer /> | ||
</div> | ||
</> | ||
</main> | ||
); | ||
} | ||
|
||
const DynamicBanner = () => { | ||
const location = useLocation(); | ||
const pathParts = location.pathname.split("/"); | ||
|
||
return ( | ||
<> | ||
<PageHeader title="Developer Hub" backgroundColor={style.colors.BLUE_98}> | ||
<p style={{ margin: 0 }}> | ||
Welcome to the Developer Hub page for PolicyEngine! This hub is | ||
designed to enhance your experience with our open-source projects by | ||
providing quick access to essential resources. | ||
</p> | ||
</PageHeader> | ||
</> | ||
); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters