mirror of
https://github.com/SideStore/SideStore.git
synced 2026-02-08 22:33:26 +01:00
Adds AddSourceViewController to add sources by URL or from list of recommended sources
This commit is contained in:
@@ -154,9 +154,21 @@ extension AppBannerView
|
||||
{
|
||||
self.style = .source
|
||||
|
||||
self.titleLabel.text = source.name
|
||||
let subtitle: String
|
||||
if let text = source.subtitle
|
||||
{
|
||||
subtitle = text
|
||||
}
|
||||
else if let scheme = source.sourceURL.scheme
|
||||
{
|
||||
subtitle = source.sourceURL.absoluteString.replacingOccurrences(of: scheme + "://", with: "")
|
||||
}
|
||||
else
|
||||
{
|
||||
subtitle = source.sourceURL.absoluteString
|
||||
}
|
||||
|
||||
let subtitle = source.subtitle ?? source.sourceURL.absoluteString
|
||||
self.titleLabel.text = source.name
|
||||
self.subtitleLabel.text = subtitle
|
||||
|
||||
let tintColor = source.effectiveTintColor ?? .altPrimary
|
||||
|
||||
@@ -66,6 +66,8 @@ class PillButton: UIButton
|
||||
|
||||
var style: Style = .pill {
|
||||
didSet {
|
||||
guard self.style != oldValue else { return }
|
||||
|
||||
if self.style == .custom
|
||||
{
|
||||
// Reset insets for custom style.
|
||||
|
||||
Reference in New Issue
Block a user