Skip to content

Commit

Permalink
Merge pull request #1570 from stripe-ios/kg-designfixes
Browse files Browse the repository at this point in the history
Financial Connections: font fixes based off new designs.
  • Loading branch information
kgaidis-stripe authored Nov 9, 2022
2 parents 2e55ddf + 32f4111 commit 2cad5e6
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 17 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ private func CreateLabelView(
iconUrl: String?,
action: @escaping (URL) -> Void
) -> UIView {
let imageView = AlwaysTemplateImageView(tintColor: .textPrimary)
let imageView = AlwaysTemplateImageView(tintColor: .textSecondary)
imageView.contentMode = .scaleAspectFit
imageView.setImage(with: iconUrl)
imageView.translatesAutoresizingMaskIntoConstraints = false
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -107,9 +107,9 @@ private func CreateContentView(
}
if let connectedAccountNotice = connectedAccountNotice {
let connectedAccountNoticeLabel = ClickableLabel(
font: .stripeFont(forTextStyle: .caption),
boldFont: .stripeFont(forTextStyle: .captionEmphasized),
linkFont: .stripeFont(forTextStyle: .captionEmphasized),
font: .stripeFont(forTextStyle: .detail),
boldFont: .stripeFont(forTextStyle: .detailEmphasized),
linkFont: .stripeFont(forTextStyle: .detailEmphasized),
textColor: .textSecondary
)
connectedAccountNoticeLabel.setText(connectedAccountNotice, action: didSelectURL)
Expand All @@ -135,9 +135,9 @@ private func CreateHeaderView(
didSelectURL: @escaping (URL) -> Void
) -> UIView {
let headerLabel = ClickableLabel(
font: .stripeFont(forTextStyle: .bodyEmphasized),
boldFont: .stripeFont(forTextStyle: .bodyEmphasized),
linkFont: .stripeFont(forTextStyle: .bodyEmphasized),
font: .stripeFont(forTextStyle: .heading),
boldFont: .stripeFont(forTextStyle: .heading),
linkFont: .stripeFont(forTextStyle: .heading),
textColor: .textPrimary
)
headerLabel.setText(text, action: didSelectURL)
Expand All @@ -162,21 +162,21 @@ private func CreateBulletinView(

let verticalLabelStackView = UIStackView()
verticalLabelStackView.axis = .vertical
verticalLabelStackView.spacing = 5
verticalLabelStackView.spacing = 2
if let title = title {
let primaryLabel = ClickableLabel(
font: .stripeFont(forTextStyle: .detailEmphasized),
boldFont: .stripeFont(forTextStyle: .detailEmphasized),
linkFont: .stripeFont(forTextStyle: .detailEmphasized),
font: .stripeFont(forTextStyle: .bodyEmphasized),
boldFont: .stripeFont(forTextStyle: .bodyEmphasized),
linkFont: .stripeFont(forTextStyle: .bodyEmphasized),
textColor: .textPrimary
)
primaryLabel.setText(title, action: didSelectURL)
verticalLabelStackView.addArrangedSubview(primaryLabel)
}
let subtitleLabel = ClickableLabel(
font: .stripeFont(forTextStyle: .caption),
boldFont: .stripeFont(forTextStyle: .captionEmphasized),
linkFont: .stripeFont(forTextStyle: .captionEmphasized),
font: .stripeFont(forTextStyle: .detail),
boldFont: .stripeFont(forTextStyle: .detailEmphasized),
linkFont: .stripeFont(forTextStyle: .detailEmphasized),
textColor: .textSecondary
)
subtitleLabel.setText(subtitle, action: didSelectURL)
Expand All @@ -200,9 +200,9 @@ private func CreateLearnMoreLabel(
didSelectURL: @escaping (URL) -> Void
) -> UIView {
let label = ClickableLabel(
font: .stripeFont(forTextStyle: .caption),
boldFont: .stripeFont(forTextStyle: .captionEmphasized),
linkFont: .stripeFont(forTextStyle: .captionEmphasized),
font: .stripeFont(forTextStyle: .detail),
boldFont: .stripeFont(forTextStyle: .detailEmphasized),
linkFont: .stripeFont(forTextStyle: .detailEmphasized),
textColor: .textSecondary
)
label.setText(text, action: didSelectURL)
Expand Down

0 comments on commit 2cad5e6

Please sign in to comment.