Skip to content

Commit

Permalink
Merge pull request #198 from SW-CSS/develop
Browse files Browse the repository at this point in the history
RELEASE
  • Loading branch information
llddang authored Sep 12, 2024
2 parents 48b99a5 + e6f99be commit cc3cdc1
Show file tree
Hide file tree
Showing 85 changed files with 64 additions and 64 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import PageTitle from '@/app/components/PageTitle';
import PageTitle from '@/app/(client)/components/PageTitle';
import TabButton from '@/components/TabButton';

import FindFooter from '../components/FindFooter';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import PageTitle from '@/app/components/PageTitle';
import PageTitle from '@/app/(client)/components/PageTitle';
import TabButton from '@/components/TabButton';

import FindForm from './components/FindForm';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import { useRouter } from 'next/navigation';

import { InputFixedText, Input, InputLabel, InputWrapper, SignButton } from '@/app/(auth)/styled';
import { InputFixedText, Input, InputLabel, InputWrapper, SignButton } from '@/app/(client)/(auth)/styled';
import { useAppDispatch, useAppSelector } from '@/lib/hooks/redux';
import { signIn } from '@/store/auth.slice';
import { useSignInMutation } from '@/lib/hooks/useApi';
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import { Formik, Form } from 'formik';
import * as Yup from 'yup';

import { TextInput } from '@/app/components/Formik/TextInput';
import { TextInput } from '@/app/(client)/components/Formik/TextInput';

import EmailTextInput from './components/EmailTextInput';
import { useState } from 'react';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
import { Formik, Form } from 'formik';
import * as Yup from 'yup';

import { Dropdown } from '@/app/components/Formik/Dropdown';
import { TextInput } from '@/app/components/Formik/TextInput';
import { Dropdown } from '@/app/(client)/components/Formik/Dropdown';
import { TextInput } from '@/app/(client)/components/Formik/TextInput';
import { careerCategory } from '@/data/signUp';

import MajorDropdown from './components/MajorDropdown';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import { useEffect, useState } from 'react';

import PageTitle from '@/app/components/PageTitle';
import PageTitle from '@/app/(client)/components/PageTitle';
import { SignUpPhase } from '@/data/signUp';

import SignUpFirstPage, { FirstInfo } from './components/SignUpFirstPage';
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
'use client';

import Pagination from '@/app/components/Pagination';
import Pagination from '@/app/(client)/components/Pagination';
import { useHackathonTeamsQuery } from '@/lib/hooks/useApi';
import { HackathonTeamDto } from '@/types/common.dto';
import Image from 'next/image';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Pagination from '@/app/components/Pagination';
import Pagination from '@/app/(client)/components/Pagination';
import Title from '@/components/Title';
import { HackathonState } from '@/data/hackathon';
import { getHackathons } from '@/lib/api/server.api';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/* eslint-disable @next/next/no-page-custom-font */

import Sidebar from '@/components/Sidebar';
import Sidebar from '@/app/(client)/components/Sidebar';

import { Content, ContentWrapper, PageWithSidebarWrapper } from './styled';

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/* eslint-disable jsx-a11y/control-has-associated-label */
/* eslint-disable max-len */
import Pagination from '@/app/components/Pagination';
import Pagination from '@/app/(client)/components/Pagination';
import MilestoneGroupLabel from '@/components/MilestoneGroupLabel';
import { MilestoneHistoryStatus } from '@/data/milestone';
import { useAppSelector } from '@/lib/hooks/redux';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { Period } from '@/types/common';
import MilestoneHistoryTable from './components/MilestoneHistoryTable';
import MilestoneOverview from './components/MilestoneOverview';
import { Content, SubTitle } from './styled';
import MilestonePeriodSearchForm from '../../../../components/MilestonePeriodSearchForm';
import MilestonePeriodSearchForm from '@/components/MilestonePeriodSearchForm';
import { useSearchParams } from 'next/navigation';

const Page = () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
/* eslint-disable jsx-a11y/control-has-associated-label */
/* eslint-disable max-len */

import MilestoneHistoryStatusLabel from '@/app/(withSidebar)/my-page/components/MilestoneHistoryStatusLabel';
import MilestoneHistoryStatusLabel from '@/app/(client)/(withSidebar)/my-page/components/MilestoneHistoryStatusLabel';
import { getMilestoneHistoriesOfStudent } from '@/lib/api/server.api';
import { getAuthFromCookie } from '@/lib/utils/auth';
import { MilestoneHistorySortCriteria, SortDirection } from '@/types/milestone';

import MilestoneHistoryDeleteButton from '../MilestoneHistoryDeleteButton';
import Pagination from '@/app/components/Pagination';
import Pagination from '@/app/(client)/components/Pagination';
import { headers } from 'next/headers';

interface MilestoneHistoryTableProp {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import Link from 'next/link';

import PageTitle from '@/app/components/PageTitle';
import PageTitle from '@/app/(client)/components/PageTitle';

import MilestoneHistoryTable from './components/MilestoneHistoryTable';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
/* eslint-disable implicit-arrow-linebreak */
import { Dispatch, SetStateAction, useEffect, useMemo, useState } from 'react';

import { Dropdown, DropdownOption, DropdownProps } from '@/app/components/Formik/Dropdown';
import { Dropdown, DropdownOption, DropdownProps } from '@/app/(client)/components/Formik/Dropdown';
import { MilestoneGroup } from '@/data/milestone';
import { useMilestoneQuery } from '@/lib/hooks/useApi';
import { Milestone, MilestoneCategory } from '@/types/milestone';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ import { useState } from 'react';
import * as Yup from 'yup';
import { toast } from 'react-toastify';

import { DatePicker } from '@/app/components/Formik/DatePicker';
import { FileUploader } from '@/app/components/Formik/FileUploader';
import { TextInput } from '@/app/components/Formik/TextInput';
import PageTitle from '@/app/components/PageTitle';
import { DatePicker } from '@/components/Formik/DatePicker';
import { FileUploader } from '@/components/Formik/FileUploader';
import { TextInput } from '@/app/(client)/components/Formik/TextInput';
import PageTitle from '@/app/(client)/components/PageTitle';
import { useMilestoneHistoryCreateMutation } from '@/lib/hooks/useApi';
import { MilestoneHistoryCreateDto } from '@/types/common.dto';
import { Milestone, MilestoneCategory } from '@/types/milestone';
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ const Sidebar = () => {

useEffect(() => {
setCurrentCategory(headerInfos.filter((headerInfo) => pathname.startsWith(headerInfo.url))[0]);
setIsOpenNavigationBar(false);
}, [pathname]);

useEffect(() => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ export const SidebarCategoryList = styled.div<SidebarCategoryListProps>`
display: flex;
margin-top: 30px;
flex-direction: column;
z-index: 0;
z-index: 49;
@media screen and (max-width: ${RESPONSIVE_WIDTH.desktop}) {
transition: all 0.6s ease-in-out;
Expand Down Expand Up @@ -105,7 +105,7 @@ export const SidebarMobileButton = styled.button`
background-color: ${COLOR.secondary.main};
color: ${COLOR.white};
padding: 0px 15px;
z-index: 0;
z-index: 49;
@media screen and (max-width: ${RESPONSIVE_WIDTH.desktop}) {
display: flex;
Expand Down
File renamed without changes.
File renamed without changes.
15 changes: 15 additions & 0 deletions frontend/src/app/(client)/layout.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
/* eslint-disable @next/next/no-page-custom-font */

import Footer from '@/components/Footer';
import Header from '@/components/Header';

import { PageWrapper } from './layout-styled';

const RootLayout = ({ children }: Readonly<{ children: React.ReactNode }>) => (
<>
<Header />
<PageWrapper>{children}</PageWrapper>
<Footer />
</>
);
export default RootLayout;
File renamed without changes.
File renamed without changes.
36 changes: 0 additions & 36 deletions frontend/src/app/CustomLayout.tsx

This file was deleted.

18 changes: 18 additions & 0 deletions frontend/src/app/admin/layout.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
/* eslint-disable @next/next/no-page-custom-font */

import AdminFooter from '@/adminComponents/Footer';
import AdminHeader from '@/adminComponents/Header';
import AdminSidebar from '@/adminComponents/Sidebar';
import { ADMIN_HEADER_HEIGHT, ADMIN_SIDEBAR_WIDTH, COLOR } from '@/adminConstants';

const Layout = ({ children }: Readonly<{ children: React.ReactNode }>) => (
<>
<AdminHeader />
<AdminSidebar />
<div className={`min-h-[100vh] w-[100vw] bg-[${COLOR.secondary.light}] pt-adminHeaderHeight pl-adminSidebarWidth`}>
<section className="relative m-5 min-h-[80vh] min-w-admin rounded-sm bg-white p-5">{children}</section>
<AdminFooter />
</div>
</>
);
export default Layout;
2 changes: 1 addition & 1 deletion frontend/src/app/admin/milestone/register/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { useRouter } from 'next/navigation';
import { toast } from 'react-toastify';
import * as Yup from 'yup';

import { FileUploader } from '@/app/components/Formik/FileUploader';
import { FileUploader } from '@/components/Formik/FileUploader';
import { useRegisterHistoryInBatchMutation } from '@/lib/hooks/useAdminApi';

const validationSchema = Yup.object().shape({
Expand Down
4 changes: 1 addition & 3 deletions frontend/src/app/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@ import ReactQueryProvider from '@/lib/utils/reactQueryProvider';
import ReduxProvider from '@/lib/utils/reduxProvider';
import StyledComponentsRegistry from '@/theme/StyledComponentsRegistry';

import CustomLayout from './CustomLayout';

import './globals.css';

export const metadata: Metadata = {
Expand All @@ -27,7 +25,7 @@ const RootLayout = ({ children }: Readonly<{ children: React.ReactNode }>) => (
<ReactQueryProvider>
<ReduxProvider>
<StyledComponentsRegistry>
<CustomLayout>{children}</CustomLayout>
{children}
<ToastContainer autoClose={1500} position="bottom-right" />
</StyledComponentsRegistry>
</ReduxProvider>
Expand Down
4 changes: 2 additions & 2 deletions frontend/src/lib/hooks/useApi.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/* eslint-disable implicit-arrow-linebreak */
import { FirstInfo } from '@/app/(auth)/sign-up/components/SignUpFirstPage';
import { SecondInfo } from '@/app/(auth)/sign-up/components/SignUpSecondPage';
import { FirstInfo } from '@/app/(client)/(auth)/sign-up/components/SignUpFirstPage';
import { SecondInfo } from '@/app/(client)/(auth)/sign-up/components/SignUpSecondPage';
import { MilestoneHistoryStatus } from '@/data/milestone';
import { QueryKeys } from '@/data/queryKey';
import { client } from '@/lib/api/client.axios';
Expand Down
4 changes: 4 additions & 0 deletions frontend/tailwind.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@ module.exports = {
md: '768px',
lg: '1200px',
},
padding: {
adminSidebarWidth: '220px',
adminHeaderHeight: '55px',
},
colors: {
white: '#FFFFFF',
black: '#333333',
Expand Down

0 comments on commit cc3cdc1

Please sign in to comment.