[Feat] #54 - 보관함 뷰 UI 구성 및 기능 구현#55
Merged
EunHee-Jeong merged 9 commits intoTeamRecorDream:developfrom Dec 11, 2022
Merged
Conversation
added 8 commits
December 8, 2022 19:08
- 클릭 시 grid, list의 두 가지 타입으로 셀 보여줌
- 보일러 플레이트 코드 제거
L-j-h-c
previously approved these changes
Dec 10, 2022
Comment on lines
+11
to
+23
| public class RDCollectionViewFlowLayout: UICollectionViewFlowLayout { | ||
| // MARK: - Properties | ||
| public enum CollectionDisplay { | ||
| case grid | ||
| case list | ||
| } | ||
| public var display: CollectionDisplay = .grid { | ||
| didSet { | ||
| if display != oldValue { | ||
| self.invalidateLayout() | ||
| } | ||
| } | ||
| } |
Comment on lines
+11
to
+21
| public enum DreamStorageSection: String, CaseIterable { | ||
| case filters = "나의 감정" | ||
| case records | ||
|
|
||
| public static func type(_ index: Int) -> DreamStorageSection { | ||
| return self.allCases[index] | ||
| } | ||
| public var title: String { | ||
| return self.rawValue | ||
| } | ||
| } |
Contributor
There was a problem hiding this comment.
요 열거형을 DSKit의 Constants에 넣으신 의도가 있으신가용?
Member
Author
There was a problem hiding this comment.
아래 extension 부분에서 DSKit의 리소스만 가져와 사용하기도 하고, 내부 함수와 프로퍼티들이 static하게 들어가기 때문에 디자인 시스템으로 빼게 되었습니다...!
두 번째 이유로는 준호님께서 만드셨던 Section을 재사용 하려고 했는데 저는 필터에서 '미설정'타입도 필요해서 추가하기 애매하더라고용... 그래서 섹션 따로 만들어서뺐습니다!
Comment on lines
+13
to
+14
| public class RDSegmentControl: UISegmentedControl { | ||
| private lazy var rdCollectionViewFlowLayout = RDCollectionViewFlowLayout(display: .grid) |
Contributor
There was a problem hiding this comment.
RDSegmentControl이라는 범용적인 이름을 가지고 있는 만큼, 변화 하는 값에 다른 타입들을 넣을 수 있도록 protocol로 관리하는 방식도 좋을 것 같아요!
- RDSegmentControl: class → protocol
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
👻 작업한 내용
RDControllable로 관리🎤 PR Point
📮 관련 이슈