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

✨ 피드 신고 UI #57

Merged
merged 29 commits into from
May 14, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
185d9c2
feat: 피드 케밥 메뉴 아이콘 분리
BangDori May 13, 2024
b3fe295
feat: 케밥 메뉴 상호작용 기능 연결
BangDori May 13, 2024
dfc2b4d
feat: 피드 케밥 메뉴 UI
BangDori May 13, 2024
468f400
feat: useToggle 공용 훅 추가
BangDori May 13, 2024
4ff328a
style: useToggle 주석 추가
BangDori May 13, 2024
4b85e69
feat: useToggle 훅 적용 및 신고하기 UI
BangDori May 13, 2024
cdb09d4
feat: ConfirmReportModal 위치 이동
BangDori May 13, 2024
0078000
feat: 피드 신고 양식 추가
BangDori May 13, 2024
b76103a
feat: ConfirmReportModal 스타일 적용
BangDori May 13, 2024
a79da57
feat: checkoff, checkon 아이콘 추가
BangDori May 13, 2024
5331df7
style: 피드 신고 모달창 너비값 수정
BangDori May 13, 2024
c421094
feat: 신고 아이템 리스트 추가
BangDori May 13, 2024
e4384e1
feat: 신고 아이템 체크박스 기능
BangDori May 13, 2024
618181c
feat: 신고 리스트 스타일 적용
BangDori May 13, 2024
c8bbd53
feat: textarea 전역 설정 추가
BangDori May 13, 2024
ba47bcf
feat: 신고 사유 입력창
BangDori May 14, 2024
3b01b35
feat: textarea 최대 길이 설정
BangDori May 14, 2024
1880f79
feat: checkbox 아이콘 추가 및 분리
BangDori May 14, 2024
1cac1f4
feat: 체크박스 숨기기 UI
BangDori May 14, 2024
ee90d3e
feat: isHiddenPost -> isBlind 상태명 수정
BangDori May 14, 2024
51afa06
feat: content.length 제거거
BangDori May 14, 2024
67c202c
refactor: useInput 훅스 적용
BangDori May 14, 2024
a16e12e
feat: useToggle 훅스 as const 적용
BangDori May 14, 2024
2f0ddb3
feat: 신고 사유 리스트 및 훅스 네이밍 수정
BangDori May 14, 2024
5224e2b
feat: 신고 카테고리 관리 훅스 타입 명시 및 유틸리티 함수 추가
BangDori May 14, 2024
a3ee67a
refactor: 피드 신고 양식 리팩토링
BangDori May 14, 2024
37bce5e
feat: CategoryId 타입 수정
BangDori May 14, 2024
6604d20
feat: ConfirmReportModal children 타입 수정
BangDori May 14, 2024
a048471
feat: useCallback 제거
BangDori May 14, 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
1 change: 1 addition & 0 deletions src/widgets/feed-kebab/model/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export { useVisibilityKebabMenu } from './useVisibilityKebabMenu';
11 changes: 11 additions & 0 deletions src/widgets/feed-kebab/model/useVisibilityKebabMenu.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import { useCallback, useState } from 'react';

export const useVisibilityKebabMenu = () => {
const [isVisibilityKebabMenu, setIsVisibilityKebabMenu] = useState(false);

const toggleVisibility = useCallback(() => {
setIsVisibilityKebabMenu((prevVisibility) => !prevVisibility);
}, []);
Legitgoons marked this conversation as resolved.
Show resolved Hide resolved

return { isVisibilityKebabMenu, toggleVisibility };
};
15 changes: 12 additions & 3 deletions src/widgets/feed-kebab/ui/FeedKebabButton.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,18 @@
import { Icon } from '@/shared/ui';

import { useVisibilityKebabMenu } from '../model';

import { KebabMenu } from './KebabMenu';

export const FeedKebabButton = () => {
const { isVisibilityKebabMenu, toggleVisibility } = useVisibilityKebabMenu();

return (
<button className='icon kebab-icon-btn'>
<Icon name='kebab-menu' width='20' height='20' />
</button>
<>
<button className='icon kebab-icon-btn' onClick={toggleVisibility}>
<Icon name='kebab-menu' width='20' height='20' />
</button>
{isVisibilityKebabMenu && <KebabMenu />}
</>
);
};
3 changes: 3 additions & 0 deletions src/widgets/feed-kebab/ui/KebabMenu.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
export const KebabMenu = () => {
return <div>KebabMenu</div>;
};