Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ final class EmotionRegisterCompletionViewController: UIViewController {
static let speechImageBottomSpacing: CGFloat = 24
static let speechLabelHorizontalSpacing: CGFloat = 20
static let speechLabelTopSpacing: CGFloat = 22
static let speechLabelBottomSpacing: CGFloat = 32
static let groundImageHeight: CGFloat = 171
static let pomoImageWidth: CGFloat = 200
static let pomoImageHeight: CGFloat = 282
Expand Down Expand Up @@ -79,7 +80,10 @@ final class EmotionRegisterCompletionViewController: UIViewController {

speechImageView.image = BitnagilGraphic.marbleSpeechGraphic?.withRenderingMode(.alwaysTemplate)
speechImageView.tintColor = BitnagilColor.gray10
speechLabel.font = BitnagilFont.init(style: .cafe24Title2, weight: .light).font
speechLabel.font = BitnagilFont.init(
family: .cafe24Ssurround,
style: .cafe24Title2,
weight: .light).font
speechLabel.numberOfLines = 2
speechLabel.textColor = .white
speechLabel.textAlignment = .center
Expand Down Expand Up @@ -139,6 +143,7 @@ final class EmotionRegisterCompletionViewController: UIViewController {

speechLabel.snp.makeConstraints { make in
make.top.equalTo(speechImageView.snp.top).offset(Layout.speechLabelTopSpacing)
make.bottom.equalTo(speechImageView.snp.bottom).offset(-Layout.speechLabelBottomSpacing)
make.horizontalEdges.equalTo(speechImageView).inset(Layout.speechImageHorizontalSpacing)
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ final class EmotionRegistrationViewController: BaseViewController<EmotionRegiste
static let speechImageHorizontalSpacing: CGFloat = 54
static let speechImageHeight: CGFloat = 102
static let speechLabelTopSpacing: CGFloat = 22
static let speechLabelBottomSpacing: CGFloat = 32
static let fomoHandImageWidth: CGFloat = 263
static let fomoHandImageHeight: CGFloat = 207
static let fomoThumbImageWidth: CGFloat = 80
Expand Down Expand Up @@ -124,7 +125,10 @@ final class EmotionRegistrationViewController: BaseViewController<EmotionRegiste
speechImageView.tintColor = .clear
speechLabel.numberOfLines = 2
speechLabel.textAlignment = .center
speechLabel.font = BitnagilFont.init(style:.cafe24Title2, weight: .light).font
speechLabel.font = BitnagilFont.init(
family: .cafe24Ssurround,
style:.cafe24Title2,
weight: .light).font
speechLabel.textColor = .clear

infoSwipeOverlayView.backgroundColor = .clear
Expand Down Expand Up @@ -197,6 +201,7 @@ final class EmotionRegistrationViewController: BaseViewController<EmotionRegiste

speechLabel.snp.makeConstraints { make in
make.top.equalTo(speechImageView.snp.top).offset(Layout.speechLabelTopSpacing)
make.bottom.equalTo(speechImageView.snp.bottom).offset(-Layout.speechLabelBottomSpacing)
make.centerX.equalTo(speechImageView)
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ final class RoutineCreationCardView<ContentView: UIView & RoutineCreationExpanda
private let divideLine = UIView()
private let contentView = ContentView()
private var labelStackViewBottomConstraint: Constraint?
private var divideLineTopConstraint: Constraint?
public var onAction: ((ContentView.Action) -> Void)? {
didSet { contentView.action = onAction }
}
Expand Down Expand Up @@ -164,9 +165,12 @@ final class RoutineCreationCardView<ContentView: UIView & RoutineCreationExpanda
}

divideLine.snp.makeConstraints { make in
make.top.equalTo(labelStackView.snp.bottom).offset(Layout.divideLineTopSpacing)
make.horizontalEdges.equalToSuperview().inset(Layout.edgeSpacing)
make.height.equalTo(Layout.divideLineHeight)

divideLineTopConstraint = make.top
.equalTo(labelStackView.snp.bottom)
.offset(CGFloat.zero).constraint
}

contentView.snp.makeConstraints { make in
Expand Down Expand Up @@ -250,11 +254,15 @@ final class RoutineCreationCardView<ContentView: UIView & RoutineCreationExpanda
contentView.isHidden = false
divideLine.isHidden = false
chevronImageView.image = BitnagilIcon.chevronIcon(direction: .up)

divideLineTopConstraint?.update(offset: Layout.edgeSpacing)
} else {
labelStackViewBottomConstraint?.isActive = true
contentView.isHidden = true
divideLine.isHidden = true
chevronImageView.image = BitnagilIcon.chevronIcon(direction: .down)

divideLineTopConstraint?.update(offset: CGFloat.zero)
}

contentView.setExpanded(expanded: nextExpandedState)
Expand Down