-
Notifications
You must be signed in to change notification settings - Fork 1
[Feat] 답변에 대한 댓글 뷰 추가 #362
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
Changes from 9 commits
6b6207d
188636c
4fa4d09
1413f4c
cb0c0bd
aa0ddc7
f52774f
1e5a970
415d652
db2f877
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,23 @@ | ||
| // | ||
| // AnswerComment.swift | ||
| // Qapple | ||
| // | ||
| // Created by 문인범 on 4/14/25. | ||
| // | ||
|
|
||
| import Foundation | ||
|
|
||
| // MARK: 임시 Entity | ||
| struct AnswerComment: Identifiable, Equatable { | ||
| let id: Int | ||
| let writeId: Int | ||
| let writerGeneration: String | ||
| let content: String | ||
| var heartCount: Int | ||
| var isLiked: Bool | ||
| let isMine: Bool | ||
| var isReport: Bool | ||
| let createdAt: Date | ||
|
|
||
| var anonymityId: Int | ||
| } | ||
|
Comment on lines
+11
to
+23
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 임시로 만들어놓은 답변에 대한 댓글 엔티티 입니다. |
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -12,4 +12,5 @@ enum DataType: Equatable { | |
| case answer(Answer) | ||
| case bulletinBoard(BulletinBoard) | ||
| case comment(BoardComment) | ||
| case answerComment(AnswerComment) | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 답변-댓글의 신고 대응 |
||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -33,6 +33,8 @@ struct AnswerListFeature { | |
| case networkingFailed(Error) | ||
| case seeMoreAction(Answer) | ||
| case backButtonTapped | ||
| case likeAnswerButtonTapped | ||
| case answerCommentButtonTapped(Answer) | ||
| case toggleLoading(Bool) | ||
| case sheet(PresentationAction<Sheet.Action>) | ||
| case alert(PresentationAction<Alert>) | ||
|
|
@@ -113,6 +115,13 @@ struct AnswerListFeature { | |
| state.answerList = state.answerList.reversed().filter(UserDefaults.filterAnswerBlockedUser) | ||
| return .none | ||
|
|
||
| case .likeAnswerButtonTapped: | ||
| // TODO: 좋아요 기능 구현 필요 | ||
| return .none | ||
|
|
||
| case .answerCommentButtonTapped: | ||
| return .none | ||
|
|
||
|
Comment on lines
+122
to
+124
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 답변-댓글 뷰로 이동하는 액션 |
||
| case let .networkingFailed(error): | ||
| HapticService.notification(type: .error) | ||
| state.alert = .failedNetworking(with: error) | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
디버그에서도 실제 서버로 들어가지길레 수정했습니다!