-
Notifications
You must be signed in to change notification settings - Fork 0
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: 재생화면 뷰 구현(UI) #29
Conversation
|
||
import UIKit | ||
|
||
final class LODescriptionView: UIView { |
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.
가능하면 mark 주석 부탁드립니다~
descriptionLabel.textColor = .layoverWhite | ||
descriptionLabel.font = .loFont(type: .body2) | ||
descriptionLabel.numberOfLines = 0 |
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.
선언할 때 클로저 내부에서 처리하면 어떨까요
self.addSubview(descriptionLabel) | ||
self.addSubview(titleLabel) |
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.
만들어둔 addsubviews 사용하면 좋을 것 같습니다!
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.
놓쳤네요 감사합니다.
self.minimumTrackTintColor = .primaryPurple | ||
setThumbImage(UIImage(named: normalThumbImage), for: .normal) | ||
self.minimumValue = 1 | ||
self.maximumValue = 100 | ||
self.value = 50 | ||
|
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.
함수로 감싸주세요....
minimumValue, maximumValue는 여기서 설정해줘도 될까요?
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.
일단 레이아웃 뷰 배치만 하려고 임시로 설정했습니다.
private let normalThumbImage: String = "LONormalThumb" | ||
private let selectedThumbImage: String = "LOSelectedThumb" |
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.
이미지 말고 깎아서 쓰는거 어때요... ㅎㅎㅎㅎ
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.
UISlider에 thumb는 UIImage로 밖에 못 넣는거 같아서.. 좀 더 확인해보겠습니다.
private let normalThumbImage: String = "LONormalThumb" | ||
private let selectedThumbImage: String = "LOSelectedThumb" |
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.
resource loader 사용하시면 될 듯 해서 없어도 될 코드 인 것 같습니다.
아래에 후술할게요
} | ||
|
||
override func beginTracking(_ touch: UITouch, with event: UIEvent?) -> Bool { | ||
setThumbImage(UIImage(named: selectedThumbImage), for: .normal) |
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.
setThumbImage(UIImage.selectedThumbImage, for: .normal
required init?(coder: NSCoder) { | ||
fatalError("init(coder:) has not been implemented") | ||
} |
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.
코드 연쇄살인마를 위해 fatalError외에 구현해주세요...
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.
오마오마갓
var config = UIButton.Configuration.plain() | ||
config.titleTextAttributesTransformer = UIConfigurationTextAttributesTransformer { incoming in | ||
var outgoing = incoming | ||
outgoing.font = UIFont.loFont(type: .body2Bold) | ||
return outgoing | ||
} |
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.
👍
button.layer.cornerRadius = 19 | ||
button.layer.borderWidth = 1 | ||
button.layer.borderColor = UIColor.layoverWhite.cgColor | ||
// button.setImage(UIImage(systemName: "cancel"), for: .normal) |
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.
사용하지 않으시면 주석 삭제해도 좋을 것 같습니다
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.
얘 언젠간 쓸거 같아서... 프로필 이미지를 위해 남겨놨습니다.
private func setup() { | ||
let viewController = self | ||
let interactor = PlaybackInteractor() | ||
let presenter = PlaybackPresenter() | ||
let router = PlaybackRouter() | ||
|
||
viewController.router = router | ||
viewController.interactor = interactor | ||
interactor.presenter = presenter | ||
presenter.viewController = viewController | ||
router.viewController = viewController | ||
router.dataStore = interactor | ||
} |
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.
하는김에 configurator 만들어서 분리해도 좋을 것 같습니다
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.
얘는 뷰모델 받아와서 뷰 구성하는 작업할 때 따로 이슈로 만들어서 처리할게요~
✨ feat: HomeViewController 캐러셀 레이아웃 구현
Approve "해줘"주세요.. |
// MARK: - Properties | ||
|
||
private (set) var titleLabel: UILabel = { | ||
let label: UILabel = UILabel() | ||
label.numberOfLines = 1 | ||
label.font = .loFont(type: .body1) | ||
label.textColor = .layoverWhite | ||
label.text = "제목 테스트" | ||
return label | ||
}() | ||
private (set) var descriptionLabel: UILabel = { | ||
let label: UILabel = UILabel() | ||
label.textColor = .layoverWhite | ||
label.font = .loFont(type: .body2) | ||
label.numberOfLines = 0 | ||
return label | ||
}() | ||
|
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.
혹시 라벨을 var로 선언하신 이유가 있을까요 ??
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.
Ready only로 쓰려고 private (set) var를 했는데 이렇게 쓸거면 private 풀고 let 박아두는게 나을거 같아서 수정했습니다 감사합니다.
descriptionLabel.textColor = .layoverWhite | ||
descriptionLabel.font = .loFont(type: .body2) | ||
descriptionLabel.numberOfLines = 0 |
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.
선언시에 처리해주는 걸로 수정하셨으니 이부분은 이제 삭제해도 괜찮지 않을까요 !
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.
아차차... 감사합니다.
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.
고생하셨습니당 👾
🧑🚀 PR 요약
📌 변경 사항
내용 소개가 이상함...
📸 ScreenShot
Simulator.Screen.Recording.-.iPhone.13.mini.-.2023-11-17.at.01.15.33.mp4
Linked Issue
close #9