generated from nhcarrigan/template
feat: add net-zero co2 badge (#30)
Reviewed-on: https://codeberg.org/nhcarrigan/portfolio/pulls/30 Co-authored-by: Naomi Carrigan <commits@nhcarrigan.com> Co-committed-by: Naomi Carrigan <commits@nhcarrigan.com>
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
"use client";
|
||||
import React from "react";
|
||||
import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
|
||||
import {
|
||||
faComments,
|
||||
} from "@fortawesome/free-solid-svg-icons";
|
||||
import { usePathname } from "next/navigation";
|
||||
import Script from "next/script";
|
||||
|
||||
const Footer = (): JSX.Element => {
|
||||
return (
|
||||
<>
|
||||
<div className="fixed w-full bottom-0 z-50 flex justify-between items-center h-14 px-4 bg-[--background] text-[--foreground]">
|
||||
<p>© Naomi Carrigan</p>
|
||||
<a href="https://chat.nhcarrigan.com" target="_blank" rel="noreferrer">
|
||||
<FontAwesomeIcon icon={faComments} size="lg" />
|
||||
</a>
|
||||
<div className="h-4/5" id="tree-nation-offset-website"></div>
|
||||
<Script id="tree-nation">{`TreeNationOffsetWebsite({code: 'a17464e0cd351220', lang: 'en', theme: 'dark'}).render('#tree-nation-offset-website');`}</Script>
|
||||
</div>
|
||||
</>
|
||||
);
|
||||
};
|
||||
|
||||
export function ClientFooter() {
|
||||
const pathname = usePathname();
|
||||
const isRootPath = pathname === "/";
|
||||
|
||||
if (isRootPath) return null;
|
||||
return <Footer />;
|
||||
}
|
||||
Reference in New Issue
Block a user