Skip to content

Commit

Permalink
chore: merge dev
Browse files Browse the repository at this point in the history
  • Loading branch information
SeieunYoo committed Aug 13, 2024
2 parents 3f0c591 + a514e0f commit c23baeb
Show file tree
Hide file tree
Showing 89 changed files with 2,589 additions and 616 deletions.
27 changes: 27 additions & 0 deletions .github/workflows/auto_assign.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Auto Assign

on:
pull_request:
types: [opened, ready_for_review, converted_to_draft]
issues:
types: [opened]

jobs:
assign_pull_request:
runs-on: ubuntu-latest
if: github.event_name == 'pull_request'
steps:
- uses: hkusu/review-assign-action@v1
with:
assignees: ${{ github.actor }}

auto_assign_issue:
runs-on: ubuntu-latest
if: github.event_name == 'issues'
permissions:
issues: write
steps:
- name: "Auto-assign issue"
uses: pozil/auto-assign-issue@v2
with:
assignees: ${{ github.actor }}
40 changes: 40 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: build

on:
push:
branches:
- main
- dev
pull_request:
types: [opened, ready_for_review, converted_to_draft]
branches:
- main
- dev

jobs:
build:
runs-on: ubuntu-latest
env:
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
TURBO_TEAM: ${{ vars.TURBO_TEAM }}

steps:
- name: Checkout repository
uses: actions/checkout@v2

- name: Set up Node.js 20.x
uses: actions/setup-node@v2
with:
node-version: 20.x

- name: Install pnpm
uses: pnpm/action-setup@v3
with:
version: 8
run_install: false

- name: Install dependencies
run: pnpm install

- name: Run build
run: pnpm run build
Binary file removed apps/admin/app/fonts/GeistMonoVF.woff
Binary file not shown.
Binary file removed apps/admin/app/fonts/GeistVF.woff
Binary file not shown.
55 changes: 55 additions & 0 deletions apps/admin/app/global.css
Original file line number Diff line number Diff line change
@@ -1 +1,56 @@
@layer reset, base, tokens, recipes, utilities;
@import url("@wow-class/ui/styles.css");

@font-face {
font-family: "SUIT";
font-weight: 200;
src: url("/fonts/SUIT-Thin.ttf") format("truetype");
}

@font-face {
font-family: "SUIT";
font-weight: 300;
src: url("/fonts/SUIT-ExtraLight.ttf") format("truetype");
}

@font-face {
font-family: "SUIT";
font-weight: 400;
src: url("/fonts/SUIT-Regular.ttf") format("truetype");
}

@font-face {
font-family: "SUIT";
font-weight: 500;
src: url("/fonts/SUIT-Medium.ttf") format("truetype");
}

@font-face {
font-family: "SUIT";
font-weight: 600;
src: url("/fonts/SUIT-SemiBold.ttf") format("truetype");
}

@font-face {
font-family: "SUIT";
font-weight: 700;
src: url("/fonts/SUIT-Bold.ttf") format("truetype");
}

@font-face {
font-family: "SUIT";
font-weight: 800;
src: url("/fonts/SUIT-ExtraBold.ttf") format("truetype");
}

@font-face {
font-family: "SUIT";
font-weight: 900;
src: url("/fonts/SUIT-Heavy.ttf") format("truetype");
}

body {
font-family: "SUIT" !important;
display: flex;
flex-direction: row;
}
20 changes: 8 additions & 12 deletions apps/admin/app/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,10 @@ import "./global.css";
import "wowds-ui/styles.css";
import "@wow-class/ui/styles.css";

import Navbar from "components/Navbar";
import type { Metadata } from "next";
import localFont from "next/font/local";

const geistSans = localFont({
src: "./fonts/GeistVF.woff",
variable: "--font-geist-sans",
});
const geistMono = localFont({
src: "./fonts/GeistMonoVF.woff",
variable: "--font-geist-mono",
});
import { JotaiProvider } from "../components/JotaiProvider";

export const metadata: Metadata = {
title: "Create Next App",
Expand All @@ -25,9 +18,12 @@ const RootLayout = ({
children: React.ReactNode;
}>) => {
return (
<html lang="en">
<body className={`${geistSans.variable} ${geistMono.variable}`}>
{children}
<html lang="ko">
<body>
<JotaiProvider>
<Navbar />
{children}
</JotaiProvider>
</body>
</html>
);
Expand Down
3 changes: 1 addition & 2 deletions apps/admin/app/page.tsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
import { styled } from "@styled-system/jsx";
import { Button, Text } from "@wow-class/ui";
import { Text } from "@wow-class/ui";

const Home = () => {
return (
<div>
Home
<Button appName="admin">버튼</Button>
<styled.div color="red.300">sdf</styled.div>
<styled.div color="mono.100">sdf</styled.div>
<Text color="error" typo="h1">
Expand Down
5 changes: 5 additions & 0 deletions apps/admin/app/participants/page.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
const Participants = () => {
return <div>Participants</div>;
};

export default Participants;
5 changes: 5 additions & 0 deletions apps/admin/app/studies/[study]/page.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
const Study = () => {
return <div>Study</div>;
};

export default Study;
5 changes: 5 additions & 0 deletions apps/admin/app/studies/page.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
const Studies = () => {
return <div>Studies</div>;
};

export default Studies;
8 changes: 8 additions & 0 deletions apps/admin/components/JotaiProvider.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
"use client";

import { Provider } from "jotai";
import type { ReactNode } from "react";

export const JotaiProvider = ({ children }: { children: ReactNode }) => {
return <Provider>{children}</Provider>;
};
81 changes: 81 additions & 0 deletions apps/admin/components/Navbar.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
import { css } from "@styled-system/css";
import { Flex } from "@styled-system/jsx";
import { NavItem } from "@wow-class/ui";
import Image from "next/image";

import { navMenu } from "../constants/navMenu";
import adminImageUrl from "../public/images/administrator.svg";
import logoImageUrl from "../public/images/logo.svg";

/**
* @description admin 내비게이션 바 컴포넌트입니다.
*/

const Navbar = () => {
return (
<aside aria-label="admin navigation bar" className={navbarContainerStyle}>
<Flex align="center" gap={8} padding="6px 0px 7px 20px">
<div className={logoTextStyle}>와우클래스 멘토</div>
<Image
alt="logo"
height={20.5}
src={logoImageUrl}
width={42}
className={css({
width: "42px",
height: "20.5px",
})}
/>
</Flex>
<nav
aria-label="admin nav menu"
className={navContainerStyle}
role="navigation"
>
<ul>
{navMenu.map((menu) => (
<NavItem
alt={menu.alt}
href={menu.href}
imageUrl={menu.imageUrl}
items={menu.items}
key={menu.name}
name={menu.name}
/>
))}
</ul>
<NavItem
alt="administrator-icon"
href=""
imageUrl={adminImageUrl}
name="멘티 페이지로 전환"
/>
</nav>
</aside>
);
};

export default Navbar;

const navbarContainerStyle = css({
width: "250px",
minHeight: "100vh",
paddingTop: "54px",
borderRightWidth: "arrow",
borderColor: "mono.400",
});

const logoTextStyle = css({
fontSize: "24px",
fontWeight: 700,
lineHeight: "130%",
letterSpacing: "-0.24px",
});

const navContainerStyle = css({
padding: "8px 0px",
display: "flex",
flexDirection: "column",
minHeight: "calc(100vh - 98px)",
justifyContent: "space-between",
});
38 changes: 38 additions & 0 deletions apps/admin/constants/navMenu.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
import folderImageUrl from "../public/images/folder.svg";
import homeImageUrl from "../public/images/home.svg";
import participantImageUrl from "../public/images/particpant.svg";

export const navMenu = [
{
href: "studies",
imageUrl: homeImageUrl,
alt: "home-icon",
name: "개설된 스터디",
items: [
{
href: "basic-web-study",
imageUrl: folderImageUrl,
alt: "folder-icon",
name: "기초 웹 스터디",
},
{
href: "dev-beginner-study",
imageUrl: folderImageUrl,
alt: "folder-icon",
name: "개발 입문 스터디",
},
{
href: "basic-mobile-study",
imageUrl: folderImageUrl,
alt: "folder-icon",
name: "기초 모바일 스터디",
},
],
},
{
href: "participants",
imageUrl: participantImageUrl,
alt: "participant-icon",
name: "수강생 관리",
},
];
13 changes: 12 additions & 1 deletion apps/admin/next.config.mjs
Original file line number Diff line number Diff line change
@@ -1,4 +1,15 @@
/** @type {import('next').NextConfig} */
const nextConfig = {};
const nextConfig = {
async redirects() {
return [
{
source: "/",
destination: "/studies",
permanent: false,
statusCode: 301,
},
];
},
};

export default nextConfig;
16 changes: 9 additions & 7 deletions apps/admin/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,18 +10,20 @@
},
"dependencies": {
"@wow-class/ui": "workspace:*",
"react": "latest",
"react-dom": "latest",
"next": "latest"
"jotai": "^2.9.2",
"next": "^14.2.5",
"react": "^18.3.1",
"react-dom": "^18.3.1"
},
"devDependencies": {
"@wow-class/eslint-config": "workspace:*",
"@wow-class/typescript-config": "workspace:*",
"typescript": "^5",
"@types/node": "^20",
"@types/react": "^18",
"@types/react-dom": "^18",
"@wow-class/eslint-config": "workspace:*",
"@wow-class/typescript-config": "workspace:*",
"@wow-class/utils": "workspace:*",
"eslint": "^8",
"eslint-config-next": "latest"
"eslint-config-next": "^14.2.5",
"typescript": "^5"
}
}
2 changes: 1 addition & 1 deletion apps/admin/panda.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ import commonConfig from "@wow-class/panda-config/common-config";

export default defineConfig({
...commonConfig,
include: ["./app/**/*.{ts,tsx,js,jsx}"],
include: ["./app/**/*.{ts,tsx,js,jsx}", "./components/**/*.{ts,tsx,js,jsx}"],
});
Binary file added apps/admin/public/fonts/SUIT-Bold.ttf
Binary file not shown.
Binary file added apps/admin/public/fonts/SUIT-ExtraBold.ttf
Binary file not shown.
Binary file added apps/admin/public/fonts/SUIT-ExtraLight.ttf
Binary file not shown.
Binary file added apps/admin/public/fonts/SUIT-Heavy.ttf
Binary file not shown.
Binary file added apps/admin/public/fonts/SUIT-Light.ttf
Binary file not shown.
Binary file added apps/admin/public/fonts/SUIT-Medium.ttf
Binary file not shown.
Binary file added apps/admin/public/fonts/SUIT-Regular.ttf
Binary file not shown.
Binary file added apps/admin/public/fonts/SUIT-SemiBold.ttf
Binary file not shown.
Binary file added apps/admin/public/fonts/SUIT-Thin.ttf
Binary file not shown.
13 changes: 13 additions & 0 deletions apps/admin/public/images/administrator.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 4 additions & 0 deletions apps/admin/public/images/folder.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit c23baeb

Please sign in to comment.