Skip to content

Commit

Permalink
오류 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
myheyjay committed Feb 19, 2024
1 parent b59d878 commit 8cfad57
Show file tree
Hide file tree
Showing 15 changed files with 83 additions and 21 deletions.
2 changes: 0 additions & 2 deletions component/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ import {
LabelLarge,
LabelMedium,
LabelSmall,
Button,
} from './Typography';

export {
Expand All @@ -33,5 +32,4 @@ export {
LabelLarge,
LabelMedium,
LabelSmall,
Button,
};
5 changes: 4 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,12 @@
"react-device-detect": "^2.2.3",
"react-dom": "^18.2.0",
"styled-components": "5",
"tailwindcss": "3.3.3"
"tailwindcss": "3.3.3",
"update-browserslist-db": "latest"
},
"devDependencies": {
"@emotion/eslint-plugin": "^11.11.0",
"@tanstack/eslint-plugin-query": "^5.20.1",
"@types/node": "20.5.4",
"@types/react": "18.2.21",
"@types/react-dom": "18.2.7",
Expand Down
7 changes: 4 additions & 3 deletions pages/_app.tsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import '@/styles/globals.css';
import React from 'react';
import { ThemeProvider } from '@primer/react';
import type { AppProps } from 'next/app';
import { QueryClient, QueryClientProvider } from '@tanstack/react-query';
import { ReactQueryDevtools } from '@tanstack/react-query-devtools';
import '@/styles/globals.css';

export default function App({ Component, pageProps }: AppProps) {
const queryClient = new QueryClient();
const queryClient = new QueryClient();

export default function App({ Component, pageProps }: AppProps) {
return (
<>
<QueryClientProvider client={queryClient}>
Expand Down
1 change: 1 addition & 0 deletions pages/_document.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import React from 'react';
import { Html, Head, Main, NextScript } from 'next/document';

export default function Document() {
Expand Down
3 changes: 2 additions & 1 deletion pages/admin/cooldown/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ const CooldownPagination = ({
const router = useRouter();
const [currentPage, setCurrentPage] = useState<number>(0);

// eslint-disable-next-line
const cooldownFetcher = async ({ queryKey }: { queryKey: any }) => {
const [_key, { page, yelloId }] = queryKey;
return axios
Expand Down Expand Up @@ -234,7 +235,7 @@ const CooldownPagination = ({
const index = () => {
const [searchYelloId, setSearchYelloId] = useState<string>('');
const router = useRouter();
let inputField = useRef<string>('');
const inputField = useRef<string>('');

return (
<>
Expand Down
5 changes: 3 additions & 2 deletions pages/admin/notification/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,11 @@ const index = () => {
const [lastUser, setLastUser] = useState<HTMLDivElement | null>(null);
const router = useRouter();

// eslint-disable-next-line
const userFetcher = async ({ queryKey }: { queryKey: any }) => {
const [_key, { page, field, value }] = queryKey;

let params: any = { page };
// eslint-disable-next-line
const params: any = { page };

if (field !== '' && value !== '') {
params.field = field;
Expand Down
11 changes: 10 additions & 1 deletion pages/admin/question/[id]/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ const index = () => {
const [voteList, setVoteList] = useState<Vote[]>([]);
const router = useRouter();

// eslint-disable-next-line
const questionDetailFetcher = async ({ queryKey }: { queryKey: any }) => {
const [_key, { questionId }] = queryKey;
return axios
Expand All @@ -98,10 +99,12 @@ const index = () => {
});
};

// eslint-disable-next-line
const userFetcher = async ({ queryKey }: { queryKey: any }) => {
const [_key, { page, field, value }] = queryKey;

let params: any = { page };
// eslint-disable-next-line
const params: any = { page };

if (field !== '' && value !== '') {
params.field = field;
Expand Down Expand Up @@ -432,10 +435,12 @@ const index = () => {
<Headline_02
style={{ width: '50px', marginLeft: '16px' }}
>
{/* eslint-disable-next-line */}
{vote.sender?.id}
</Headline_02>

<Image
// eslint-disable-next-line
src={vote.sender?.imageUrl!}
alt={'image'}
width={24}
Expand Down Expand Up @@ -476,6 +481,7 @@ const index = () => {
</Headline_02>

<Image
// eslint-disable-next-line
src={vote.receiver?.imageUrl!}
alt={'image'}
width={24}
Expand Down Expand Up @@ -613,6 +619,7 @@ const index = () => {
</Headline_02>

<Image
// eslint-disable-next-line
src={currentVote?.sender.imageUrl!}
alt={'image'}
width={48}
Expand Down Expand Up @@ -653,10 +660,12 @@ const index = () => {
<Headline_02
style={{ width: '50px', marginLeft: '16px' }}
>
{/* eslint-disable-next-line */}
{currentVote?.receiver.id}
</Headline_02>

<Image
// eslint-disable-next-line
src={currentVote?.receiver.imageUrl!}
alt={'image'}
width={48}
Expand Down
6 changes: 4 additions & 2 deletions pages/admin/question/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -59,10 +59,12 @@ const UserPagination = ({ field, value }: { field: string; value: string }) => {
});
const router = useRouter();

// eslint-disable-next-line
const questionFetcher = async ({ queryKey }: { queryKey: any }) => {
const [_key, { page, field, value }] = queryKey;

let params: any = { page };
// eslint-disable-next-line
const params: any = { page };

if (field !== '' && value !== '') {
params.field = field;
Expand Down Expand Up @@ -370,7 +372,7 @@ const index = () => {
const [searchValue, setSearchValue] = useState<string>('');

const router = useRouter();
let inputField = useRef<string>('');
const inputField = useRef<string>('');

return (
<>
Expand Down
4 changes: 3 additions & 1 deletion pages/admin/user/[id]/edit.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ const index = () => {
const router = useRouter();
const [userDetailData, setUserDetailData] = useState<UserDetail>();

// eslint-disable-next-line
const userDetailFetcher = async ({ queryKey }: { queryKey: any }) => {
const [_key, { userId }] = queryKey;
return axios
Expand Down Expand Up @@ -100,7 +101,7 @@ const index = () => {

const onClickPost = (userId: number) => {
if (confirm(userId + '를 수정하시겠습니까?')) {
let request = userDetailData;
const request = userDetailData;
delete request?.id;
delete request?.deletedAt;
delete request?.group;
Expand Down Expand Up @@ -242,6 +243,7 @@ const index = () => {
alt={'profileImage'}
width={128}
height={128}
// eslint-disable-next-line
src={data?.data.profileImage!}
/>
</BodyLarge>
Expand Down
2 changes: 2 additions & 0 deletions pages/admin/user/[id]/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ const BASE_URL = process.env.NEXT_PUBLIC_SERVER_URL;
const index = () => {
const router = useRouter();

// eslint-disable-next-line
const userDetailFetcher = async ({ queryKey }: { queryKey: any }) => {
const [_key, { userId }] = queryKey;
return axios
Expand Down Expand Up @@ -188,6 +189,7 @@ const index = () => {
alt={'profileImage'}
width={128}
height={128}
// eslint-disable-next-line
src={data?.data.profileImage!}
/>
</BodyLarge>
Expand Down
7 changes: 5 additions & 2 deletions pages/admin/user/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -60,10 +60,12 @@ const UserPagination = ({ field, value }: { field: string; value: string }) => {
});
const router = useRouter();

// eslint-disable-next-line
const userFetcher = async ({ queryKey }: { queryKey: any }) => {
const [_key, { page, field, value }] = queryKey;

let params: any = { page };
// eslint-disable-next-line
const params: any = { page };

if (field !== '' && value !== '') {
params.field = field;
Expand Down Expand Up @@ -233,7 +235,7 @@ const index = () => {
const [searchValue, setSearchValue] = useState<string>('');

const router = useRouter();
let inputField = useRef<string>('');
const inputField = useRef<string>('');

return (
<>
Expand Down Expand Up @@ -275,6 +277,7 @@ const index = () => {
}}
trailingAction={
<TextInput.Action
key={1}
onClick={(e) => {
setSearchValue(inputField.current);
}}
Expand Down
3 changes: 2 additions & 1 deletion pages/school-attack/[groupId].tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import { Collapse } from '@/component/Collapse';
import { Button } from '@/component/Button';
import { pallete } from '@/styles/Color';

import { MainLayout, SystemLayout } from './styled';
import { MainLayout, SystemLayout } from '../../styles/SchoolAttack.styled';

import background_main from '@/public/background_main.svg';
import message_square_svg from '@/component/Icon/asset/message-square.svg';
Expand Down Expand Up @@ -276,6 +276,7 @@ export default function SchoolAttack() {
{page.data.data.statisticsList.map((statistics, index) => {
return (
<ListItem
key={index}
groupName={statistics.userGroupName}
rank={statistics.rankNumber}
diffRank={
Expand Down
File renamed without changes.
3 changes: 2 additions & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@
"incremental": true,
"paths": {
"@/*": ["./*"]
}
},
"rootDir": "./"
},
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx"],
"exclude": ["node_modules"]
Expand Down
45 changes: 41 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,15 @@ __metadata:
languageName: node
linkType: hard

"@emotion/eslint-plugin@npm:^11.11.0":
version: 11.11.0
resolution: "@emotion/eslint-plugin@npm:11.11.0"
peerDependencies:
eslint: 6 || 7 || 8
checksum: 2d555b6790700e0d0c2862d4aa2fd697ea5851faa7e406ab459028e66daad2ee0dc3dec29362c2edc2656a63f826ac15629112d3e9aca64323fa40f9e5674bd4
languageName: node
linkType: hard

"@emotion/hash@npm:^0.9.1":
version: 0.9.1
resolution: "@emotion/hash@npm:0.9.1"
Expand Down Expand Up @@ -913,6 +922,17 @@ __metadata:
languageName: node
linkType: hard

"@tanstack/eslint-plugin-query@npm:^5.20.1":
version: 5.20.1
resolution: "@tanstack/eslint-plugin-query@npm:5.20.1"
dependencies:
"@typescript-eslint/utils": ^6.20.0
peerDependencies:
eslint: ^8.0.0
checksum: dd8542271643b9d1f033dd96340f0b3b00771cbf6792aa71ce657a36992386ee9da92cccfd3cb55c432477e89821661e0adfec51972333372114ce41abd1f11c
languageName: node
linkType: hard

"@tanstack/query-core@npm:5.20.5":
version: 5.20.5
resolution: "@tanstack/query-core@npm:5.20.5"
Expand Down Expand Up @@ -1293,7 +1313,7 @@ __metadata:
languageName: node
linkType: hard

"@typescript-eslint/utils@npm:6.21.0":
"@typescript-eslint/utils@npm:6.21.0, @typescript-eslint/utils@npm:^6.20.0":
version: 6.21.0
resolution: "@typescript-eslint/utils@npm:6.21.0"
dependencies:
Expand Down Expand Up @@ -1807,9 +1827,9 @@ __metadata:
linkType: hard

"caniuse-lite@npm:^1.0.30001406, caniuse-lite@npm:^1.0.30001517, caniuse-lite@npm:^1.0.30001520":
version: 1.0.30001522
resolution: "caniuse-lite@npm:1.0.30001522"
checksum: 56e3551c02ae595085114073cf242f7d9d54d32255c80893ca9098a44f44fc6eef353936f234f31c7f4cb894dd2b6c9c4626e30649ee29e04d70aa127eeefeb0
version: 1.0.30001588
resolution: "caniuse-lite@npm:1.0.30001588"
checksum: 2ab5fcec8fd3ee5d817a44bf1fb69804a6924d190e476863fb519692cd3e85a3a775bf4a2b6ba793f8db592ca61255b7f77f3d773ff7d42b452216f180bcdd2f
languageName: node
linkType: hard

Expand Down Expand Up @@ -6576,6 +6596,20 @@ __metadata:
languageName: node
linkType: hard

"update-browserslist-db@npm:latest":
version: 1.0.13
resolution: "update-browserslist-db@npm:1.0.13"
dependencies:
escalade: ^3.1.1
picocolors: ^1.0.0
peerDependencies:
browserslist: ">= 4.21.0"
bin:
update-browserslist-db: cli.js
checksum: 1e47d80182ab6e4ad35396ad8b61008ae2a1330221175d0abd37689658bdb61af9b705bfc41057fd16682474d79944fb2d86767c5ed5ae34b6276b9bed353322
languageName: node
linkType: hard

"uri-js@npm:^4.2.2":
version: 4.4.1
resolution: "uri-js@npm:4.4.1"
Expand Down Expand Up @@ -6772,10 +6806,12 @@ __metadata:
version: 0.0.0-use.local
resolution: "yello-admin@workspace:."
dependencies:
"@emotion/eslint-plugin": ^11.11.0
"@emotion/react": ^11.11.3
"@emotion/styled": ^11.11.0
"@primer/octicons-react": ^19.6.0
"@primer/react": ^35.28.0
"@tanstack/eslint-plugin-query": ^5.20.1
"@tanstack/react-query": ^5.17.0
"@tanstack/react-query-devtools": ^5.17.21
"@types/node": 20.5.4
Expand Down Expand Up @@ -6807,6 +6843,7 @@ __metadata:
tailwindcss: 3.3.3
typescript: latest
typescript-plugin-css-modules: ^5.0.2
update-browserslist-db: latest
languageName: unknown
linkType: soft

Expand Down

0 comments on commit 8cfad57

Please sign in to comment.