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

[feat] 상세 피드 / 피드와 댓글 같이 스크롤 되도록 구현 #138

Merged
merged 23 commits into from
Aug 21, 2023

Conversation

leeeha
Copy link
Member

@leeeha leeeha commented Aug 20, 2023

📝 Work Description

  • 피드와 댓글 리스트가 같이 스크롤 되도록 Concat Adapter 사용했습니다.
  • 댓글이 없는 경우에도 ConcatAdapter 이용했어요!
  • 프래그먼트를 굳이 액티비티로 감쌀 필요가 없어서, 프래그먼트 없애고 액티비티로 전면 수정했습니다!

📣 To Reviewers

  • 변경된 부분이 꽤 있기 때문에 코드 자세히 확인해주세요!

…m/team-winey/Winey-AOS into feature/feat-create-feed-comment

� Conflicts:
�	app/src/main/java/com/android/go/sopt/winey/presentation/main/feed/WineyFeedFragment.kt
�	app/src/main/java/com/android/go/sopt/winey/presentation/main/mypage/myfeed/MyFeedFragment.kt
�	app/src/main/res/values/strings.xml
…o feature/feat-create-feed-comment

� Conflicts:
�	app/src/main/java/com/android/go/sopt/winey/util/binding/BindingAdapter.kt
…m/team-winey/Winey-AOS into feature/feat-create-feed-comment

� Conflicts:
�	app/src/main/java/com/android/go/sopt/winey/util/binding/BindingAdapter.kt
@leeeha leeeha added feat ✨ 새로운 기능 구현 하은 🐰 labels Aug 20, 2023
@leeeha leeeha added this to the 기능 구현 ✨ milestone Aug 20, 2023
@leeeha leeeha self-assigned this Aug 20, 2023
Copy link
Contributor

@sxunea sxunea left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

고생했습니다 👍 변경사항도 확인했어요 !

@@ -256,14 +256,17 @@ class WineyFeedFragment : BindingFragment<FragmentWineyFeedBinding>(R.layout.fra

private fun navigateToDetail(feedId: Int, writerLevel: Int) {
val intent = Intent(requireContext(), DetailActivity::class.java)
intent.putExtra("feedId", feedId)
intent.putExtra("writerLevel", writerLevel)
intent.putExtra(KEY_FEED_ID, feedId)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

이름까지 상수화좋네요 👍

android:text="@string/comment_upload_btn_text"
android:textAppearance="@style/TextAppearance.WINEY.body_m_14"
android:textColor="@color/purple_400"
android:visibility="@{vm.isValidComment ? View.VISIBLE : View.GONE}"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍


if (commentList.isEmpty()) {
binding.rvDetail.adapter = ConcatAdapter(detailFeedAdapter, commentEmptyAdapter)
} else {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

기존의방식(empty layout도 frame Layout에 넣고 isEmpty에 따라 visibility 조절)의 방식을 두고
따로 Empty Adapter를 둔 특별한 이유가 있는지 궁금합니다 ! concat으로 바뀌면서 하단 레이아웃을 갈아끼우기 편해졌고, 댓글 생성창을 또 framelayout으로 넣어야하기 때문에 분리했다고 생각하긴 하는데 또 개인적인 의견이 있었다면 알아가고싶습니다😄

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

댓글 부분 레이아웃 짤 때 두 개의 뷰 (댓글이 아직 없어요 뷰, 댓글 리사이클러뷰) 가 겹쳐보여서 보기에 조금 불편한 감이 있더라구요..! 그리고 visibility를 토글하면서 뷰를 전환하다보면 실수할 여지가 많을 거 같아서, 리스트가 비어있을 때는 아예 새로운 레이아웃이 인플레이트 되는 식으로 구현해봤어요 :)

@leeeha leeeha merged commit ccd7056 into develop Aug 21, 2023
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feat ✨ 새로운 기능 구현 하은 🐰
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants