mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-23 22:55:00 +00:00
Various Improvements
This commit is contained in:
@@ -26,7 +26,7 @@ enum ChatTitleContent {
|
||||
|
||||
case peer(peerView: PeerView, onlineMemberCount: Int32?, isScheduledMessages: Bool)
|
||||
case replyThread(type: ReplyThreadType, count: Int)
|
||||
case custom(String, Bool)
|
||||
case custom(String, String?, Bool)
|
||||
}
|
||||
|
||||
private enum ChatTitleIcon {
|
||||
@@ -214,8 +214,9 @@ final class ChatTitleView: UIView, NavigationBarTitleView {
|
||||
}
|
||||
|
||||
isEnabled = false
|
||||
case let .custom(text, enabled):
|
||||
segments = [.text(0, NSAttributedString(string: text, font: Font.medium(17.0), textColor: titleTheme.rootController.navigationBar.primaryTextColor))]
|
||||
case let .custom(text, _, enabled):
|
||||
let font = Font.with(size: 17.0, design: .regular, weight: .medium, traits: .monospacedNumbers)
|
||||
segments = [.text(0, NSAttributedString(string: text, font: font, textColor: titleTheme.rootController.navigationBar.primaryTextColor))]
|
||||
isEnabled = enabled
|
||||
}
|
||||
|
||||
@@ -472,6 +473,9 @@ final class ChatTitleView: UIView, NavigationBarTitleView {
|
||||
}
|
||||
}
|
||||
}
|
||||
case let .custom(_, subtitle?, _):
|
||||
let string = NSAttributedString(string: subtitle, font: Font.regular(13.0), textColor: titleTheme.rootController.navigationBar.secondaryTextColor)
|
||||
state = .info(string, .generic)
|
||||
default:
|
||||
break
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user