Skip to content
This repository was archived by the owner on Feb 5, 2025. It is now read-only.

Commit f8124a7

Browse files
authored
Merge pull request #124 from wordpress-mobile/fix/more-dark-mode
Dark mode: text and button fixes
2 parents 28fd97a + 80d1cd0 commit f8124a7

File tree

4 files changed

+11
-6
lines changed

4 files changed

+11
-6
lines changed

WordPressAuthenticator.podspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Pod::Spec.new do |s|
22
s.name = "WordPressAuthenticator"
3-
s.version = "1.8.0-beta.12"
3+
s.version = "1.8.0-beta.13"
44
s.summary = "WordPressAuthenticator implements an easy and elegant way to authenticate your WordPress Apps."
55

66
s.description = <<-DESC

WordPressAuthenticator/Extensions/WPStyleGuide+Login.swift

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -190,12 +190,15 @@ extension WPStyleGuide {
190190
/// - Returns: A properly styled UIButton
191191
///
192192
class func termsButton() -> UIButton {
193+
let style = WordPressAuthenticator.shared.style
194+
193195
let baseString = NSLocalizedString("By signing up, you agree to our _Terms of Service_.", comment: "Legal disclaimer for signup buttons, the underscores _..._ denote underline")
194196

195-
let labelString = baseString.underlined()
197+
let attrStrNormal = baseString.underlined(color: style.subheadlineColor, underlineColor: style.textButtonColor)
198+
let attrStrHighlight = baseString.underlined(color: style.subheadlineColor, underlineColor: style.textButtonHighlightColor)
199+
let font = WPStyleGuide.mediumWeightFont(forStyle: .footnote)
196200

197-
let font = WPStyleGuide.mediumWeightFont(forStyle: .caption2)
198-
return textButton(normal: labelString, highlighted: labelString, font: font, alignment: .center)
201+
return textButton(normal: attrStrNormal, highlighted: attrStrHighlight, font: font, alignment: .center)
199202
}
200203

201204
private class func textButton(normal normalString: NSAttributedString, highlighted highlightString: NSAttributedString, font: UIFont, alignment: UIControl.NaturalContentHorizontalAlignment = .leading) -> UIButton {

WordPressAuthenticator/NUX/NUXButton.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ import WordPressUI
1010

1111
@objc let activityIndicator: UIActivityIndicatorView = {
1212
let indicator = UIActivityIndicatorView(style: .white)
13+
indicator.color = WordPressAuthenticator.shared.style.primaryTitleColor
1314
indicator.hidesWhenStopped = true
1415
return indicator
1516
}()

WordPressAuthenticator/Signin/LoginSocialErrorCell.swift

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,10 +60,11 @@ open class LoginSocialErrorCell: UITableViewCell {
6060
labelStack.axis = .vertical
6161
labelStack.spacing = Constants.labelSpacing
6262

63+
let style = WordPressAuthenticator.shared.style
6364
titleLabel.font = WPStyleGuide.fontForTextStyle(.footnote)
64-
titleLabel.textColor = WPStyleGuide.greyDarken30()
65+
titleLabel.textColor = style.instructionColor
6566
descriptionLabel.font = WPStyleGuide.mediumWeightFont(forStyle: .subheadline)
66-
descriptionLabel.textColor = WPStyleGuide.darkGrey()
67+
descriptionLabel.textColor = style.subheadlineColor
6768
descriptionLabel.numberOfLines = 0
6869
descriptionLabel.heightAnchor.constraint(greaterThanOrEqualToConstant: Constants.descriptionMinHeight).isActive = true
6970

0 commit comments

Comments
 (0)