Skip to content

Commit

Permalink
Apply Biome recommendations (#529)
Browse files Browse the repository at this point in the history
  • Loading branch information
No767 authored Sep 6, 2024
1 parent 90ef606 commit 320daab
Show file tree
Hide file tree
Showing 6 changed files with 29 additions and 12 deletions.
4 changes: 3 additions & 1 deletion react/src/components/GlobalFooter.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,16 @@ function GlobalFooter() {
className="z-0 w-full h-full"
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 1440 320"
role="img"
aria-label="title"
>
<path
width="100"
height="100"
fill="#00e1bfcc"
fillOpacity="1"
d="M0,96L80,80C160,64,320,32,480,53.3C640,75,800,149,960,154.7C1120,160,1280,96,1360,64L1440,32L1440,320L1360,320C1280,320,1120,320,960,320C800,320,640,320,480,320C320,320,160,320,80,320L0,320Z"
></path>
/>
</svg>

<div className="bg-landing opacity-80 w-full max-h-max py-8 top-4 gap-16 text-center">
Expand Down
12 changes: 7 additions & 5 deletions react/src/components/GlobalNavbar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@ import ACMLogo from "../assets/acm_logo_v2.png";
function GlobalNavbar() {
const [isMenuOpen, setIsMenuOpen] = React.useState(false);

const UCMACMLogo = () => <img src={ACMLogo} width={76} height={76} />;
const UCMACMLogo = () => (
<img src={ACMLogo} width={76} height={76} alt="ACM Logo" />
);
// Come back later for the others
const menuItems = [
{
Expand Down Expand Up @@ -45,8 +47,8 @@ function GlobalNavbar() {
</NavbarContent>

<NavbarContent className="hidden sm:flex gap-6" justify="center">
{menuItems.map((item, index) => (
<NavbarItem key={`${item}-${index}`}>
{menuItems.map((item) => (
<NavbarItem key={`${item}-${item.title}`}>
<Link
color="foreground"
className="w-full"
Expand All @@ -59,8 +61,8 @@ function GlobalNavbar() {
))}
</NavbarContent>
<NavbarMenu>
{menuItems.map((item, index) => (
<NavbarMenuItem key={`${item}-${index}`}>
{menuItems.map((item) => (
<NavbarMenuItem key={`${item}-${item.title}`}>
<Link
color="foreground"
className="w-full"
Expand Down
9 changes: 7 additions & 2 deletions react/src/components/WaveHeader.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,17 @@ function WaveHeader() {
<p>hi</p>
</div>
<div className="z-0 gap-16 flex">
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 320">
<svg
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 1440 320"
role="img"
aria-label="title"
>
<path
fill="#00e1bf"
fillOpacity="0.8"
d="M0,256L80,224C160,192,320,128,480,122.7C640,117,800,171,960,192C1120,213,1280,203,1360,197.3L1440,192L1440,0L1360,0C1280,0,1120,0,960,0C800,0,640,0,480,0C320,0,160,0,80,0L0,0Z"
></path>
/>
</svg>
</div>
</>
Expand Down
1 change: 1 addition & 0 deletions react/src/main.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import "./index.css";
import { NextUIProvider } from "@nextui-org/react";
import { BrowserRouter } from "react-router-dom";

// biome-ignore lint/style/noNonNullAssertion: Provided by React. Nothing we can do
ReactDOM.createRoot(document.getElementById("root")!).render(
<React.StrictMode>
<NextUIProvider>
Expand Down
11 changes: 8 additions & 3 deletions react/src/pages/front.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,17 @@ function Front() {
<p>hi</p>
</div>
<div className="z-0 gap-16 flex">
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 320">
<svg
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 1440 320"
role="img"
aria-label="title"
>
<path
fill="#00e1bf"
fillOpacity="0.8"
d="M0,256L80,224C160,192,320,128,480,122.7C640,117,800,171,960,192C1120,213,1280,203,1360,197.3L1440,192L1440,0L1360,0C1280,0,1120,0,960,0C800,0,640,0,480,0C320,0,160,0,80,0L0,0Z"
></path>
/>
</svg>
</div>

Expand Down Expand Up @@ -43,7 +48,7 @@ function Front() {
</p>
</div>
<div className="align-center">
<img src={AboutUsImage} />
<img src={AboutUsImage} aria-label="title" />
</div>
</div>
</section>
Expand Down
4 changes: 3 additions & 1 deletion react/src/pages/sigs.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -52,12 +52,14 @@ const Sigs = () => {
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 1440 320"
className="home__wave"
role="img"
aria-label="title"
>
<path
fill="#00e1bfcc"
fillOpacity="1"
d="M0,256L80,224C160,192,320,128,480,122.7C640,117,800,171,960,192C1120,213,1280,203,1360,197.3L1440,192L1440,0L1360,0C1280,0,1120,0,960,0C800,0,640,0,480,0C320,0,160,0,80,0L0,0Z"
></path>
/>
</svg>
<section>
<ul className="mx-28 font-montseratt tracking-wider text-[20px]">
Expand Down

0 comments on commit 320daab

Please sign in to comment.