Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DEV TO MAIN #1707

Merged
merged 58 commits into from
Nov 15, 2024
Merged
Changes from all commits
Commits
Show all changes
58 commits
Select commit Hold shift + click to select a range
3b240d1
[FE] REFACT: 필요없는 코드 삭제 및 정리 #1680
jnkeniaem Sep 6, 2024
478da02
[FE] FEAT: IButtonProps에 isLoading 추가#1680
jnkeniaem Sep 6, 2024
5cbbd10
[FE] FIX: 카드 버튼 개별로 감싸는 CardButtonWrapper(cardButtonsWrapper X)추가해 로딩…
jnkeniaem Sep 6, 2024
30e450c
[FE] REFACT: 프로필 알림 카드 설정 변경 관련 custom axios 이름 구체적으로 변경 #1680
jnkeniaem Sep 9, 2024
f5d699b
[FE] REFACT: 통일성 높이기 위해 저장버튼 클릭시 pointer events 변경대신 debounce 적용 #1680
jnkeniaem Sep 9, 2024
fedbd60
[FE] REFACT: CardButtonWrapper 삭제(기존 구조 복구) #1680
jnkeniaem Sep 9, 2024
34a4f4f
[FE] REFACT: api 요청에 대한 응답 오기 전까지 취소버튼 눌러도 아무런 동작 안하게 변경 #1680
jnkeniaem Sep 9, 2024
1950c37
[FE] FIX: api 요청 후 응답 수신 전까지 취소버튼 hover시 cursor 속성값 not-allowed로 설정#1680
jnkeniaem Sep 9, 2024
455f8a5
[FE] FIX: grid template areas의 ALERT->ALARM으로 수정 #1680
jnkeniaem Sep 9, 2024
3207554
[FE] FIX: 프로필과 Admin Slack 에 Notification 을 Alarm 으로 변경해 백앤드와 통일
junyoung2015 Sep 10, 2024
d7b7014
Merge branch 'fe/dev/fix_firebase_error/#1680' of https://github.com/…
jnkeniaem Sep 10, 2024
0127766
[FE] FIX: 알람 관련된 부분은 notification->alarm, 그 외의 부분은 원래대 로 복구 #1680
jnkeniaem Sep 10, 2024
94fe6fd
[FE] FEAT: 유저 로그인, post login, 홈페이지 제외 페이지 lazy import 적용 #1687
jnkeniaem Sep 25, 2024
ebe87da
[FE] REFACT: 빌딩 및 나의 대여 정보 불러오기를 상위컴포넌트(Layout)에서 처리 #1687
jnkeniaem Sep 25, 2024
ce5b241
[FE] FIX: 로딩이 끝나면 top nav 띄워 loading animation 움직이지 않게 고정 #1687
jnkeniaem Sep 25, 2024
680b0ad
[FE] FEAT: meta description 과 keywords 추가 #1687
junyoung2015 Oct 2, 2024
6231e5c
[FE] FEAT: robots.txt 생성 #1687
junyoung2015 Oct 2, 2024
2dc1a4b
[FE] FIX: Do Hyeon 폰트 import 최적화 #1687
junyoung2015 Oct 2, 2024
6993d76
[FE] FIX: Do Hyeon 폰트 import 최적화 #1687
junyoung2015 Oct 2, 2024
4790329
[FE] FEAT: lighthouse Webp 적용 #1687
Minkyu01 Oct 7, 2024
6342684
[FE] FEAT: webp 정리 #1687
Minkyu01 Oct 8, 2024
09f0c96
[FE] FIX: coin size 조절 #1687
Minkyu01 Oct 8, 2024
d3c2ae9
FIX: 캐시 설정을 위한 Nginx conf 설정 추가
saewoo1 Oct 8, 2024
2e37a01
[FE] REFACT: 400 상태코드 대신 axios HttpStatusCode enum의 HttpStatusCode.Ba…
jnkeniaem Oct 14, 2024
aaf596b
Merge branch 'dev' of https://github.com/innovationacademy-kr/Cabi in…
jnkeniaem Oct 14, 2024
c8630ec
[FE] FIX: 브라우저 환경에서 getMessaging 호출 #1680
jnkeniaem Oct 14, 2024
c2f2706
[FE] FIX: 상태코드 401을 수신했을땐 센트리 로깅에 제외 #1680
jnkeniaem Oct 15, 2024
e41edd9
[FE] ETC: 필요없는 코드 삭제 #1680
jnkeniaem Oct 15, 2024
e5daee3
[FE] CHORE: 각 프로세스에 맞게 console 출력 메시지 수정 #1680
jnkeniaem Oct 15, 2024
8d521f5
[FE] HOTFIX: 층 정보가 localStorage recoil-persist 에 존재하지 않을 경우 TypeError…
junyoung2015 Oct 28, 2024
e6076c8
Merge branch 'dev' of github.com:innovationacademy-kr/Cabi into dev
junyoung2015 Oct 28, 2024
9e2f56c
[BE] FIX: nginx cache 설정 원상복구 #1687
junyoung2015 Oct 28, 2024
572b2f7
[BE] FIX: cabinet share 인원 수정
wet6123 Oct 28, 2024
37fa31a
[FE] HOTFIX: 공유사물함 대기중 연장권이 사용되는 버그 해결
Oct 28, 2024
9a23e0a
[FE] ETC: firebase 최신 버전으로 업그레이드 #1680
jnkeniaem Oct 29, 2024
92762c3
[FE] FEAT: isSupported 메서드 사용해 브라우저에서 푸시 알림 api 사용가능 여부 확인 후 처리 #1680
jnkeniaem Oct 31, 2024
d0cd6d9
[FE] FEAT: response modal에 메시지 띄우기 위해 modalContents useState 선언 및 사용 …
jnkeniaem Oct 31, 2024
d776e13
[FE] FEAT: 브라우저에서 푸시 알림 기능 지원하는 경우에만 getMessaging 호출 #1680
jnkeniaem Oct 31, 2024
b69f1ab
[FE] FIX: await 키워드 말고 then 사용해 프로미스 후속 처리 #1680
jnkeniaem Oct 31, 2024
37aa76c
[FE] CHORE: 가독성 위해 줄바꿈 #1680
jnkeniaem Oct 31, 2024
38d6dda
[FE] FEAT: api 응답 수신전까지 토글 클릭 방지 #1680
jnkeniaem Nov 4, 2024
27de2d6
[FE] FEAT: font 추가
Minkyu01 Nov 5, 2024
85e9941
Merge branch 'dev' of https://github.com/innovationacademy-kr/Cabi in…
jnkeniaem Nov 5, 2024
c860114
Merge pull request #1685 from innovationacademy-kr/fe/dev/fix_firebas…
jnkeniaem Nov 5, 2024
d62ec07
Merge branch 'dev' of https://github.com/innovationacademy-kr/Cabi in…
jnkeniaem Nov 5, 2024
56796c9
[FE] CHORE: strict mode 적용되게 원상 복구 #1680
jnkeniaem Nov 7, 2024
ef48f3a
[FE] FIX: 로딩시 Init style 보여주기
Minkyu01 Nov 12, 2024
36e7133
Merge pull request #1704 from innovationacademy-kr/fe/dev/lighthouse#…
jnkeniaem Nov 13, 2024
205bc44
[FE] ETC: config 수정
jnkeniaem Nov 13, 2024
a0f62da
[FE] ETC: VITE_BE_HOST로 dev 브랜치 식별되나 테스트
jnkeniaem Nov 13, 2024
6575a71
[FE] ETC: 조건 없이 firebase getMessaging 호출 테스트
jnkeniaem Nov 13, 2024
20af0ec
[FE] ETC: 브라우저 환경이 아닌 환경에서 firebase getMessaging 호출 테스트
jnkeniaem Nov 13, 2024
9d442f1
[FE] ETC: getMessaging 호출 조건 원상복구
jnkeniaem Nov 13, 2024
f2c6a03
[FE] ETC: 테스트 후 main.tsx 원상복구
jnkeniaem Nov 13, 2024
cd5588c
[FE] ETC: .env 수정
jnkeniaem Nov 13, 2024
ae24253
[FE] FIX: 폰트 꺠짐 수정 #1687
Minkyu01 Nov 15, 2024
9941154
[FE] FIX: image loading error #1687
Minkyu01 Nov 15, 2024
55ac3ef
Merge pull request #1706 from innovationacademy-kr/fe/dev/lighthouse#…
Minkyu01 Nov 15, 2024
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
232 changes: 116 additions & 116 deletions backend/database/cabi_local.sql

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion config
30 changes: 27 additions & 3 deletions frontend/index.html
Original file line number Diff line number Diff line change
@@ -6,14 +6,34 @@
src="/src/Cabinet/components/Card/DisplayStyleCard/displayStyleInitializer.ts"
></script>
<meta charset="UTF-8" />
<meta
name="description"
content="여러분의 일상을 가볍게: 42서울 학생들을 위한 캐비닛 대여 서비스"
/>
<meta
name="keywords"
content="42, 42 Seoul, 42 서울, Cabi, 사물함, 사물함 대여, 동아리 사물함, 수요지식회"
/>

<link
rel="icon"
href="/src/Cabinet/assets/images/logo.ico"
type="image/x-icon"
/>
<link rel="shortcut icon" href="/src/Cabinet/assets/images/logo.png" />
<link rel="apple-touch-icon" href="/src/Cabinet/assets/images/logo.png" />
<link rel="manifest" href="/manifest.json" />
<link
rel="shortcut icon"
type="image/png"
href="/src/Cabinet/assets/images/logo.png"
/>

<!-- Apple Touch Icon -->
<link
rel="apple-touch-icon"
type="image/png"
href="/src/Cabinet/assets/images/logo.png"
/>

<!-- Apple Touch Icons with different sizes -->
<link
rel="apple-touch-icon"
sizes="192x192"
@@ -34,6 +54,8 @@
sizes="512x512"
href="/icons/icon-512x512.png"
/>

<link rel="manifest" href="/manifest.json" />
<meta
name="viewport"
content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no"
@@ -42,6 +64,8 @@
<meta property="og:type" content="website" />
<meta property="og:url" content="https://cabi.42seoul.io" />
<meta property="og:title" content="Cabi" />

<!-- Open Graph Image -->
<meta
property="og:image"
content="https://dev.cabi.42seoul.io/src/assets/images/desktopLogo.png"
983 changes: 543 additions & 440 deletions frontend/package-lock.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion frontend/package.json
Original file line number Diff line number Diff line change
@@ -21,7 +21,7 @@
"@sentry/react": "^8.18.0",
"@types/react-color": "^3.0.7",
"axios": "^1.7.2",
"firebase": "^10.4.0",
"firebase": "^10.14.1",
"react": "^18.2.0",
"react-color": "^2.19.3",
"react-cookie": "^4.1.1",
Binary file added frontend/public/icons/icon-192x192.webp
Binary file not shown.
Binary file added frontend/public/icons/icon-256x256.webp
Binary file not shown.
Binary file added frontend/public/icons/icon-384x384.webp
Binary file not shown.
Binary file added frontend/public/icons/icon-512x512.webp
Binary file not shown.
2 changes: 2 additions & 0 deletions frontend/public/robots.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
User-agent: *
Allow : /
52 changes: 32 additions & 20 deletions frontend/src/App.tsx
Original file line number Diff line number Diff line change
@@ -2,32 +2,34 @@ import PageTracker from "@/api/analytics/PageTracker";
import * as Sentry from "@sentry/react";
import React, { Suspense, lazy } from "react";
import { BrowserRouter, Route, Routes } from "react-router-dom";
import AvailablePage from "@/Cabinet/pages/AvailablePage";
import ClubPage from "@/Cabinet/pages/ClubPage";
import CoinLogPage from "@/Cabinet/pages/CoinLogPage";
import HomePage from "@/Cabinet/pages/HomePage";
import InventoryPage from "@/Cabinet/pages/InventoryPage";
import ItemUsageLogPage from "@/Cabinet/pages/ItemUsageLogPage";
import Layout from "@/Cabinet/pages/Layout";
import LogPage from "@/Cabinet/pages/LogPage";
import LoginPage from "@/Cabinet/pages/LoginPage";
import MainPage from "@/Cabinet/pages/MainPage";
import PostLogin from "@/Cabinet/pages/PostLogin";
import ProfilePage from "@/Cabinet/pages/ProfilePage";
import StoreMainPage from "@/Cabinet/pages/StoreMainPage";
import AdminMainPage from "@/Cabinet/pages/admin/AdminMainPage";
import AdminSlackNotiPage from "@/Cabinet/pages/admin/AdminSlackNotiPage";
import AdminStorePage from "@/Cabinet/pages/admin/AdminStorePage";
import LoadingAnimation from "@/Cabinet/components/Common/LoadingAnimation";
import DetailPage from "@/Presentation/pages/DetailPage";
import PresentationHomePage from "@/Presentation/pages/HomePage";
import PresentationLayout from "@/Presentation/pages/Layout";
import PresentationLogPage from "@/Presentation/pages/LogPage";
import RegisterPage from "@/Presentation/pages/RegisterPage";
import AdminPresentationLayout from "@/Presentation/pages/admin/AdminLayout";

const NotFoundPage = lazy(() => import("@/Cabinet/pages/NotFoundPage"));
const LoginFailurePage = lazy(() => import("@/Cabinet/pages/LoginFailurePage"));
const NotFoundPage = lazy(() => import("@/Cabinet/pages/NotFoundPage"));
const AvailablePage = lazy(() => import("@/Cabinet/pages/AvailablePage"));
const ClubPage = lazy(() => import("@/Cabinet/pages/ClubPage"));
const CoinLogPage = lazy(() => import("@/Cabinet/pages/CoinLogPage"));
const InventoryPage = lazy(() => import("@/Cabinet/pages/InventoryPage"));
const ItemUsageLogPage = lazy(() => import("@/Cabinet/pages/ItemUsageLogPage"));
const LogPage = lazy(() => import("@/Cabinet/pages/LogPage"));
const MainPage = lazy(() => import("@/Cabinet/pages/MainPage"));
const ProfilePage = lazy(() => import("@/Cabinet/pages/ProfilePage"));
const StoreMainPage = lazy(() => import("@/Cabinet/pages/StoreMainPage"));

// NOTE : 수요지식회
const PresentationHomePage = lazy(
() => import("@/Presentation/pages/HomePage")
);
const PresentationLayout = lazy(() => import("@/Presentation/pages/Layout"));
const DetailPage = lazy(() => import("@/Presentation/pages/DetailPage"));
const PresentationLogPage = lazy(() => import("@/Presentation/pages/LogPage"));
const RegisterPage = lazy(() => import("@/Presentation/pages/RegisterPage"));

// NOTE : admin
const AdminLayout = lazy(() => import("@/Cabinet/pages/admin/AdminLayout"));
const AdminLoginPage = lazy(
() => import("@/Cabinet/pages/admin/AdminLoginPage")
@@ -38,6 +40,16 @@ const AdminLoginFailurePage = lazy(
() => import("@/Cabinet/pages/admin/AdminLoginFailurePage")
);
const AdminHomePage = lazy(() => import("@/Cabinet/pages/admin/AdminHomePage"));
const AdminMainPage = lazy(() => import("@/Cabinet/pages/admin/AdminMainPage"));
const AdminSlackAlarmPage = lazy(
() => import("@/Cabinet/pages/admin/AdminSlackAlarmPage")
);
const AdminStorePage = lazy(
() => import("@/Cabinet/pages/admin/AdminStorePage")
);
const AdminPresentationLayout = lazy(
() => import("@/Presentation/pages/admin/AdminLayout")
);

function App(): React.ReactElement {
const SentryRoutes = Sentry.withSentryReactRouterV6Routing(Routes);
@@ -74,7 +86,7 @@ function App(): React.ReactElement {
<Route path="main" element={<AdminMainPage />} />
<Route path="search" element={<SearchPage />} />
<Route path="club" element={<AdminClubPage />} />
<Route path="slack-notification" element={<AdminSlackNotiPage />} />
<Route path="slack-alarm" element={<AdminSlackAlarmPage />} />
<Route path="available" element={<AvailablePage />} />
<Route path="store" element={<AdminStorePage />} />
</Route>
21 changes: 13 additions & 8 deletions frontend/src/Cabinet/api/axios/axios.custom.ts
Original file line number Diff line number Diff line change
@@ -28,10 +28,15 @@ export const axiosMyInfo = async (): Promise<any> => {
}
};

const axiosUpdateAlarmURL = "/v4/users/me/alarms";
export const axiosUpdateAlarm = async (alarm: AlarmInfo): Promise<any> => {
const axiosUpdateAlarmReceptionPathURL = "/v4/users/me/alarms";
export const axiosUpdateAlarmReceptionPath = async (
alarm: AlarmInfo
): Promise<any> => {
try {
const response = await instance.put(axiosUpdateAlarmURL, alarm);
const response = await instance.put(
axiosUpdateAlarmReceptionPathURL,
alarm
);
return response;
} catch (error) {
throw error;
@@ -891,13 +896,13 @@ export const axiosGetAvailableCabinets = async (): Promise<any> => {
}
};

const axiosSendSlackNotificationToUserURL = "/slack/send";
export const axiosSendSlackNotificationToUser = async (
const axiosSendSlackAlarmToUserURL = "/slack/send";
export const axiosSendSlackAlarmToUser = async (
receiverName: string,
message: string
): Promise<any> => {
try {
const response = await instance.post(axiosSendSlackNotificationToUserURL, {
const response = await instance.post(axiosSendSlackAlarmToUserURL, {
receiverName: receiverName,
message: message,
});
@@ -907,13 +912,13 @@ export const axiosSendSlackNotificationToUser = async (
}
};

export const axiosSendSlackNotificationToChannel = async (
export const axiosSendSlackAlarmToChannel = async (
receiverName: string,
message: string,
channel: string | undefined
): Promise<any> => {
try {
await instance.post(axiosSendSlackNotificationToUserURL + `/${channel}`, {
await instance.post(axiosSendSlackAlarmToUserURL + `/${channel}`, {
receiverName: receiverName,
message: message,
});
2 changes: 2 additions & 0 deletions frontend/src/Cabinet/api/axios/axios.log.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { captureException } from "@sentry/react";
import { HttpStatusCode } from "axios";
import ErrorType from "@/Cabinet/types/enum/error.type.enum";
import { getCookie } from "@/Cabinet/api/react_cookie/cookies";

@@ -12,6 +13,7 @@ export const logAxiosError = (
errorMsg: string,
isAdmin = false
) => {
if (error.response?.status === HttpStatusCode.BadRequest) return;
error.message = (isAdmin ? "[Admin] " : "") + errorMsg;
captureException(error, {
tags: {
15 changes: 7 additions & 8 deletions frontend/src/Cabinet/assets/images/storeCoin.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added frontend/src/Cabinet/assets/images/webp/logo.webp
Binary file not shown.
Binary file not shown.
Binary file not shown.
22 changes: 20 additions & 2 deletions frontend/src/Cabinet/components/Announce/AnnounceTemplate.tsx
Original file line number Diff line number Diff line change
@@ -36,9 +36,27 @@ const AnnounceTemplate = (props: Itext) => {
<TitleStyled>{title}</TitleStyled>
<CabiImgStyled>
{type === "ERROR" ? (
<img src="/src/Cabinet/assets/images/sadCcabiWhite.png"></img>
<picture>
<source
type="image/webp"
srcSet="/src/Cabinet/assets/images/webp/sadCcabiWhite.webp"
/>
<img
src="/src/Cabinet/assets/images/sadCcabiWhite.png"
alt="sad cabi"
/>
</picture>
) : (
<img src="/src/Cabinet/assets/images/happyCcabiWhite.png"></img>
<picture>
<source
type="image/webp"
srcSet="/src/Cabinet/assets/images/webp/happyCcabiWhite.webp"
/>
<img
src="/src/Cabinet/assets/images/happyCcabiWhite.png"
alt="happy cabi"
/>
</picture>
)}
</CabiImgStyled>
<SubTitleStyled>{subTitle}</SubTitleStyled>
Original file line number Diff line number Diff line change
@@ -51,8 +51,7 @@ const CabinetInfoArea: React.FC<{
closeModal,
isSwappable,
}) => {
const isExtensionVisible = isMine && selectedCabinetInfo;
// selectedCabinetInfo.status !== "IN_SESSION";
const isExtensionVisible = isMine && selectedCabinetInfo && selectedCabinetInfo.status !== "IN_SESSION";
const isHoverBoxVisible =
selectedCabinetInfo &&
selectedCabinetInfo.lentsLength <= 1 &&
Original file line number Diff line number Diff line change
@@ -1,17 +1,31 @@
import styled from "styled-components";
import { ReactComponent as CabiImage } from "@/Cabinet/assets/images/happyCcabi.svg";

const EmptySection = ({ message }: { message: string }): JSX.Element => {
return (
<EmptySectionStyled>
<CabiImageStyled
src="/src/Cabinet/assets/images/happyCcabi.png"
alt="happy cabi"
/>
<CabinetTypeIconStyled>
<CabiImage />
</CabinetTypeIconStyled>
<ContentStyled>{message}</ContentStyled>
</EmptySectionStyled>
);
};

const CabinetTypeIconStyled = styled.div`
width: 200px;
height: 200px;
& g {
fill: var(--normal-text-color);
}
& > svg {
width: 200px;
height: 200px;
}
`;

const EmptySectionStyled = styled.div`
display: flex;
justify-content: center;
Loading