Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
128 changes: 128 additions & 0 deletions src/app/page.module.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,128 @@
.container {
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
padding: 4rem 8rem;
}

.title {
font-family: var(--font-roboto-slab);
font-size: 6rem;
color: #333;
margin-bottom: 2rem;
}

.lead {
font-size: 1.8rem;
line-height: 1.8;
margin-bottom: 5rem;
text-align: center;
}

.grid {
display: grid;
grid-template-columns: repeat(2, 1fr);
gap: 2rem;

div {
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;

svg {
width: 70px;
height: auto;
margin-bottom: 1rem;
}
}
}

.card-title {
font-size: 2rem;
font-weight: 700;
margin-bottom: 3rem;
}

.card-body {
font-size: 1.6rem;
color: #444;
margin-bottom: 3rem;
}

.button {
display: inline-block;
width: 100%;
font-size: 1.6rem;
font-weight: 700;
background: var(--accent);
color: #444;
border-radius: 8px;
text-decoration: none;
text-align: center;
padding: 1.6rem 0;
position: relative;
transition:
background 160ms ease,
transform 160ms ease;
box-shadow: 4px 4px 4px rgba(0, 0, 0, 0.1);
}

.button::after {
content: "→";
display: inline-block;
margin-left: 0.6rem;
transform: translateX(0);
transition: transform 160ms ease;
color: inherit;
}

.button:hover {
background: color-mix(in srgb, var(--accent), #000 10%);
}

.button:hover::after {
transform: translateX(6px);
}

.link {
display: inline-block;
text-decoration: underline;
font-size: 1.6rem;
font-weight: 600;
margin-top: 1rem;
}

@media (max-width: 899px) {
.grid {
grid-template-columns: 1fr;
}
}

@media (max-width: 640px) {
.container {
padding: 2rem 4rem;
}

.title {
font-size: 4rem;
}

.lead {
font-size: 1.4rem;
}

.card-title {
font-size: 1.8rem;
}

.card-body {
font-size: 1.4rem;
}

.button {
font-size: 1.4rem;
padding: 1.2rem 0;
}
}
53 changes: 51 additions & 2 deletions src/app/page.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,54 @@
import { redirect } from "next/navigation";
import CalenderIcon from "@/components/CalenderIcon";
import ProgramCodeIcon from "@/components/ProgramCodeIcon";
import Paper from "@/components/ui/Paper";
import Link from "next/link";
import styles from "./page.module.css";

export default function Home() {
redirect("/events");
return (
<div className={styles.container}>
<h1 className={styles.title}>KCL Works</h1>

<p className={styles.lead}>
KCL Works は、KCL(Kyutech Code
Lab)に参加する九州工業大学の学生による作品と活動成果を紹介するポートフォリオサイトです。
<br />
ハッカソン、企業連携イベント、開発プロジェクトなど、学生の挑戦の記録を掲載しています。
<br />
<Link
href="https://www.kyutech.ac.jp/career/kcl.html"
target="_blank"
rel="noopener noreferrer"
className={styles.link}
>
KCLについてはこちらをご覧ください
</Link>
</p>
<p></p>

<div className={styles.grid}>
<Paper>
<CalenderIcon />
<h3 className={styles["card-title"]}>Events</h3>
<p className={styles["card-body"]}>
KCLで行われたハッカソンや企業連携イベントを紹介します。
</p>
<Link href="/events" className={styles.button}>
イベントを見る
</Link>
</Paper>

<Paper>
<ProgramCodeIcon />
<h3 className={styles["card-title"]}>Works</h3>
<p className={styles["card-body"]}>
学生が制作したアプリやプロダクトを掲載しています。
</p>
<Link href="/works" className={styles.button}>
作品を見る
</Link>
</Paper>
</div>
</div>
);
}
19 changes: 19 additions & 0 deletions src/components/CalenderIcon/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
const CalenderIcon = () => {
return (
<svg
width="36"
height="36"
viewBox="0 0 36 36"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<title>Calender Icon</title>
<path
d="M27.6269 6.9H25.3881V6C25.3881 5.1 24.791 4.5 23.8955 4.5C23 4.5 22.403 5.1 22.403 6V6.9H16.7313C15.8358 6.9 15.2388 7.5 15.2388 8.4C15.2388 9.3 15.8358 9.9 16.7313 9.9H22.5522V10.8C22.5522 11.7 23.1493 12.3 24.0448 12.3C24.9403 12.3 25.5373 11.7 25.5373 10.8V9.9H27.7761C28.8209 9.9 29.8657 10.8 29.8657 12V14.1H5.98507V12C5.98507 10.8 7.02985 9.9 8.22388 9.9H10.4627V10.8C10.4627 11.7 11.0597 12.3 11.9552 12.3C12.8507 12.3 13.4478 11.7 13.4478 10.8V8.4V6C13.4478 5.1 12.8507 4.5 11.9552 4.5C11.0597 4.5 10.4627 5.1 10.4627 6V6.9H8.22388C5.23881 6.9 3 9.15 3 12V26.4C3 29.25 5.23881 31.5 8.22388 31.5H27.7761C30.6119 31.5 33 29.25 33 26.4V12C32.8507 9.15 30.6119 6.9 27.6269 6.9ZM27.6269 28.5H8.22388C7.02985 28.5 5.98507 27.6 5.98507 26.4V17.1H29.8657V26.4C29.8657 27.6 28.8209 28.5 27.6269 28.5Z"
fill="black"
/>
</svg>
);
};

export default CalenderIcon;
9 changes: 7 additions & 2 deletions src/components/Header/index.tsx
Original file line number Diff line number Diff line change
@@ -1,16 +1,21 @@
"use client";

import { usePathname } from "next/navigation";
import Image from "next/image";
import Link from "next/link";
import Logo from "../../../public/logo_ver2.png";
import Toggle from "../ui/Toggle";
import styles from "./styles.module.css";

const Header = () => {
const pathname = usePathname();

return (
<header className={styles.header}>
<Link href="/events">
<Link href="/">
<Image src={Logo} alt="KCL Works Logo" className={styles.logo} />
</Link>
<Toggle />
{pathname !== "/" && <Toggle />}
</header>
);
};
Expand Down
27 changes: 27 additions & 0 deletions src/components/ProgramCodeIcon/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
const ProgramCodeIcon = () => {
return (
<svg
width="36"
height="36"
viewBox="0 0 36 36"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<title>Program Code Icon</title>
<path
d="M27.7151 3H8.43042C4.66389 3 1.5 6.15 1.5 9.9V24.6C1.5 28.35 4.66389 31.5 8.43042 31.5H27.5644C31.4816 31.5 34.4948 28.35 34.4948 24.6V9.9C34.6455 6.15 31.4816 3 27.7151 3ZM31.6323 24.6C31.6323 26.7 29.8243 28.5 27.7151 28.5H8.43042C6.32116 28.5 4.51323 26.7 4.51323 24.6V12.75H28.9204C29.8243 12.75 30.427 12.15 30.427 11.25C30.427 10.35 29.6737 9.75 28.9204 9.75H4.51323C4.66389 7.65 6.32116 6 8.43042 6H27.5644C29.8243 6 31.6323 7.8 31.6323 9.9V24.6Z"
fill="black"
/>
<path
d="M15.984 15.5063C15.5475 14.9352 14.529 14.7925 13.947 15.3635L9.4365 19.2183C9.1455 19.5038 9 19.9321 9 20.3604C9 20.7887 9.1455 21.217 9.4365 21.5025L13.947 25.2145C14.238 25.5 14.529 25.5 14.9655 25.5C15.402 25.5 15.8385 25.3572 16.1295 25.0717C16.7115 24.5006 16.566 23.644 15.984 23.073L12.783 20.3604L15.984 17.6478C16.566 16.934 16.566 16.0774 15.984 15.5063Z"
fill="black"
/>
<path
d="M21.9075 15.3686C21.3255 14.7896 20.307 14.9343 19.8705 15.5133C19.2885 16.0922 19.434 16.9606 20.016 17.5396L23.217 20.2895L20.016 23.0395C19.434 23.6184 19.2885 24.4869 19.8705 25.0658C20.1615 25.3553 20.598 25.5 21.0345 25.5C21.3255 25.5 21.762 25.3553 22.053 25.2105L26.5635 21.3027C26.8545 21.0132 27 20.579 27 20.1448C27 19.7106 26.8545 19.2764 26.5635 18.9869L21.9075 15.3686Z"
fill="black"
/>
</svg>
);
};

export default ProgramCodeIcon;