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

TitledView, TitledTextField #60

Merged
merged 6 commits into from
Jan 26, 2023

Conversation

yy0867
Copy link
Collaborator

@yy0867 yy0867 commented Jan 26, 2023

작업 내용

질문 및 특이사항

Simulator Screen Recording - iPhone 14 Pro - 2023-01-26 at 17 21 22

테스트할 때 메인 타겟의 SceneDelegate를 다음과 같이 작성합니다.

import UIKit

// DO NOT COMMIT
import GongGanGam_UI
// DO NOT COMMIT

class SceneDelegate: UIResponder, UIWindowSceneDelegate {
    
    var window: UIWindow?
    
    func scene(_ scene: UIScene, willConnectTo session: UISceneSession, options connectionOptions: UIScene.ConnectionOptions) {
        // DO NOT COMMIT
        guard let windowScene = (scene as? UIWindowScene) else { return }
        
        self.window = UIWindow(windowScene: windowScene)
        self.window?.rootViewController = UINavigationController(rootViewController: ExampleViewController())
        self.window?.overrideUserInterfaceStyle = .dark
        self.window?.makeKeyAndVisible()
        // DO NOT COMMIT
    }
}

체크리스트

  • 빌드가 되는 코드인가요?
  • Warning이 없는 코드인가요?
  • Merge할 브랜치가 올바른가요?
  • 코딩 컨벤션이 올바른가요?

@yy0867 yy0867 added the 💄 Style 뷰 관련 label Jan 26, 2023
@yy0867 yy0867 self-assigned this Jan 26, 2023
@yy0867 yy0867 marked this pull request as ready for review January 26, 2023 08:20
Copy link
Contributor

@chansooo chansooo left a comment

Choose a reason for hiding this comment

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

👍

Copy link
Collaborator

@ByeongjooYoo ByeongjooYoo left a comment

Choose a reason for hiding this comment

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

👍

Comment on lines +23 to +36
/// Title label of `TitledView`.
/// Based on `UILabel`
///
/// - default font: `Pretendard.Body(400)`
/// - default textColor: `Neutral-10`
///
/// 이 label의 `text`를 변경하여 `TitledView`의 타이틀을 설정할 수 있습니다.
public lazy var titleLabel: UILabel = {
let label = UILabel()

label.font = Pretendard.body
label.textColor = GongGanGamUIAsset.neutral10.color
return label
}()
Copy link
Collaborator

@ByeongjooYoo ByeongjooYoo Jan 26, 2023

Choose a reason for hiding this comment

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

titleLabel의 text만 변경되고 나머지 속성값들은 변경될 일이 없다면 해당 Label을 private하게 두고
setTitleLabelText(_ text: String) 같은 함수로 text를 변경하는 건 어떨까용?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

text를 제외하고도 font나 color 등의 여러 색상이 변경될 여지가 있다고 판단해서 public으로 두었습니다..!

@yy0867 yy0867 merged commit 18f1025 into feature/ui-framework Jan 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
💄 Style 뷰 관련
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

3 participants