Skip to content
This repository was archived by the owner on Feb 5, 2025. It is now read-only.
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
2 changes: 1 addition & 1 deletion WordPressAuthenticator.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = "WordPressAuthenticator"
s.version = "1.10.0-beta.3"
s.version = "1.10.0-beta.4"
s.summary = "WordPressAuthenticator implements an easy and elegant way to authenticate your WordPress Apps."

s.description = <<-DESC
Expand Down
20 changes: 18 additions & 2 deletions WordPressAuthenticator/NUX/NUXButton.swift
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,21 @@ import WordPressUI
return activityIndicator.isAnimating
}

open override var isEnabled: Bool {
didSet {
if #available(iOS 13, *) {
activityIndicator.color = isEnabled ? style.primaryTitleColor : style.secondaryTitleColor
}
}
}

@objc let activityIndicator: UIActivityIndicatorView = {
let indicator = UIActivityIndicatorView(style: .white)
let indicator: UIActivityIndicatorView
if #available(iOS 13, *) {
indicator = UIActivityIndicatorView(style: .medium)
} else {
indicator = UIActivityIndicatorView(style: .white)
}
indicator.color = WordPressAuthenticator.shared.style.primaryTitleColor
indicator.hidesWhenStopped = true
return indicator
Expand Down Expand Up @@ -69,7 +82,10 @@ import WordPressUI
open override func awakeFromNib() {
super.awakeFromNib()
configureAppearance()
activityIndicator.style = .gray
guard #available(iOS 13, *) else {
activityIndicator.style = .gray
Copy link
Contributor

Choose a reason for hiding this comment

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

Do we need this? Should we just initialise the indicator with a .gray appearance instead of white?

return
}
}

/// Setup: shorter reference for style
Expand Down