Skip to content

Commit

Permalink
feat(mobile): 시간선택 View Layout을 구현합니다. (#48)
Browse files Browse the repository at this point in the history
  • Loading branch information
jungwoo3490 authored Oct 23, 2024
1 parent e5c4db9 commit 4ae540c
Show file tree
Hide file tree
Showing 9 changed files with 73 additions and 4 deletions.
1 change: 1 addition & 0 deletions apps/mobile/app/layout.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import "../styles/globals.css";
import "./globals.css";
import type { Metadata } from "next";

Expand Down
2 changes: 0 additions & 2 deletions apps/mobile/app/page.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import "../styles/globals.css";

export default function Home() {
return <div>dd</div>;
}
14 changes: 14 additions & 0 deletions apps/mobile/app/select-time/layout.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import SelectTimeHeader from "../../components/SelectTimeHeader";

export default function Layout({
children,
}: Readonly<{
children: React.ReactNode;
}>) {
return (
<>
<SelectTimeHeader />
{children}
</>
);
}
3 changes: 3 additions & 0 deletions apps/mobile/app/select-time/page.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
export default function Page() {
return <div>셀렉트타임</div>;
}
40 changes: 40 additions & 0 deletions apps/mobile/components/SelectTimeHeader.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
"use client";

import { MobileIconDonate, MobileIconSharing, MobileIconTeam, MobileLogo } from "@setaday/icon";
import Link from "next/link";
import React from "react";

function SelectTimeHeader() {
const handleClickDonateButton = () => {
// 기부하기 버튼 클릭 시
};

const handleClickTeamButton = () => {
// 팀 버튼 클릭 시
};

const handleClickSharingButton = () => {
// 공유하기 버튼 클릭 시
};

return (
<header className="border-gray-1 flex h-[5.2rem] items-center justify-between border-b-2 px-[2rem]">
<Link href="/">
<MobileLogo />
</Link>
<div className="flex gap-[0.8rem]">
<button onClick={handleClickDonateButton}>
<MobileIconDonate />
</button>
<button onClick={handleClickTeamButton}>
<MobileIconTeam />
</button>
<button onClick={handleClickSharingButton}>
<MobileIconSharing />
</button>
</div>
</header>
);
}

export default SelectTimeHeader;
2 changes: 2 additions & 0 deletions apps/mobile/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@
"build:css": "tailwindcss -i ./styles/globals.css -o ./dist/output.css --minify"
},
"dependencies": {
"@setaday/design-token": "workspace:*",
"@setaday/icon": "workspace:*",
"@setaday/ui": "workspace:*",
"next": "15.0.0-rc.0",
"react": "19.0.0-rc-f994737d14-20240522",
Expand Down
2 changes: 1 addition & 1 deletion apps/mobile/styles/globals.css
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@
#root,
body,
html {
@apply m-0 mx-auto min-h-[100dvh] max-w-[43rem] bg-[#f5f5f5];
@apply m-0 mx-auto min-h-[100dvh] w-[100vw] max-w-[43rem];
-ms-overflow-style: none;
scrollbar-width: none;
}
Expand Down
7 changes: 6 additions & 1 deletion apps/mobile/tailwind.config.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,13 @@
import { color, font } from "@setaday/design-token";

/** @type {import('tailwindcss').Config} */
module.exports = {
content: ["./app/**/*.{js,ts,jsx,tsx}", "./components/**/*.{js,ts,jsx,tsx}"],
theme: {
extend: {},
extend: {
colors: color,
fontSize: font,
},
},
plugins: [],
};
6 changes: 6 additions & 0 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 4ae540c

Please sign in to comment.