Remove social buttons, add support for Webrings
Signed-off-by: Taevas <code@taevas.xyz>
This commit is contained in:
parent
f56690c8f1
commit
89d7cab81f
5 changed files with 57 additions and 4 deletions
|
@ -18,8 +18,9 @@ export default function Umami() {
|
|||
useEffect(() => {
|
||||
if (data) {
|
||||
try {
|
||||
const plural = data.visits.value !== 1;
|
||||
setElements([
|
||||
<p className="text-left" key={"info"}>Throughout <b>the last 7 days,</b> my website has been visited <b>{data.visits.value} times!</b></p>,
|
||||
<p className="text-left" key={"info"}>Throughout <b>the last 7 days,</b> my website has been visited <b>{data.visits.value} time{plural ? "s" : ""}!</b></p>,
|
||||
]);
|
||||
} catch {
|
||||
setError(true);
|
||||
|
|
|
@ -87,6 +87,18 @@ export default function TabButtons({
|
|||
/>
|
||||
}
|
||||
/>
|
||||
<TabButton
|
||||
colors={`from-cyan-500 to-cyan-600 hover:from-cyan-700 hover:to-cyan-600 ${isTabActive("webrings") ? "brightness-75" : ""}`}
|
||||
onClick={() => {
|
||||
toggleTab("webrings");
|
||||
}}
|
||||
content={
|
||||
<Translatable
|
||||
en={"Webrings"}
|
||||
fr={"Webrings"}
|
||||
/>
|
||||
}
|
||||
/>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
|
|
@ -2,7 +2,6 @@ import React from "react";
|
|||
import AnimateHeight from "react-animate-height";
|
||||
|
||||
import TabButtons from "./TabButtons/index.tsx";
|
||||
import SocialButtons from "./SocialButtons/index.tsx";
|
||||
import Translatable from "#parts/Translatable.tsx";
|
||||
|
||||
import {type TabDetails, TabContext} from "#contexts";
|
||||
|
@ -36,7 +35,6 @@ export default function MainWindow({
|
|||
</div>
|
||||
</AnimateHeight>
|
||||
<div className="p-4">
|
||||
<SocialButtons/>
|
||||
<TabButtons
|
||||
setLang={setLang}
|
||||
setTabs={setTabs}
|
||||
|
|
40
src/Main/Tabs/Webrings/index.tsx
Normal file
40
src/Main/Tabs/Webrings/index.tsx
Normal file
|
@ -0,0 +1,40 @@
|
|||
import React from "react";
|
||||
import Tab from "../Tab.tsx";
|
||||
import Translatable from "#parts/Translatable.tsx";
|
||||
import {UserMultiple} from "@carbon/icons-react";
|
||||
import {type TabDetails} from "#contexts";
|
||||
|
||||
export default function Webrings({
|
||||
setTabs,
|
||||
}: {
|
||||
setTabs: React.Dispatch<React.SetStateAction<TabDetails[]>>;
|
||||
}) {
|
||||
const elements = [(
|
||||
<div className="m-4 pb-2 text-white" key={"webrings"}>
|
||||
<p>
|
||||
<b>
|
||||
<Translatable
|
||||
en={"This website will hopefully be part of some webrings soon enough! For now, there's nothing to show here."}
|
||||
fr={"Ce site web fera bientôt parti de quelques webrings, en tout cas je l'espère ! Pour l'instant, il n'y a rien à montrer ici."}
|
||||
/>
|
||||
</b>
|
||||
</p>
|
||||
</div>
|
||||
)];
|
||||
|
||||
return (
|
||||
<Tab
|
||||
setTabs={setTabs}
|
||||
id="webrings"
|
||||
name={
|
||||
<Translatable
|
||||
en={"Webrings"}
|
||||
fr={"Webrings"}
|
||||
/>
|
||||
}
|
||||
elements={elements}
|
||||
logo={<UserMultiple size={48} fill=""/>}
|
||||
position="lg:left-[700px] lg:top-[400px]"
|
||||
/>
|
||||
);
|
||||
}
|
|
@ -1,9 +1,10 @@
|
|||
import React from "react";
|
||||
import {type TabDetails} from "#contexts";
|
||||
import About from "./About/index.tsx";
|
||||
import Contact from "./Contact/index.tsx";
|
||||
import Projects from "./Projects/index.tsx";
|
||||
import Support from "./Support/index.tsx";
|
||||
import {type TabDetails} from "#contexts";
|
||||
import Webrings from "./Webrings/index.tsx";
|
||||
|
||||
export default function Tabs({
|
||||
setTabs,
|
||||
|
@ -16,6 +17,7 @@ export default function Tabs({
|
|||
<Projects setTabs={setTabs} />
|
||||
<Contact setTabs={setTabs} />
|
||||
<Support setTabs={setTabs} />
|
||||
<Webrings setTabs={setTabs} />
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue