Repository navigation
Round the Stars action buttons into capsules like the iOS client - #138
Merged
macosswift merged 1 commit intoOct 29, 2026
Merged
Conversation
This was referenced Oct 27, 2026
Contributor
Author
1 task done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Key change
Round the five 40 pt action buttons of the Stars windows into capsules by changing their corner radius from 10 to 20 (half of the button height):
Star_ListScreen.swift)Star_PurchaseInApp.swift)Star_ReactionsController.swift)Star_AuctionListController.swift)Reason
In the Telegram iOS client these buttons are
ButtonComponentbuttons in the.glassstyle, andButtonComponentdraws every glass button as a capsule: the corner radius isavailableSize.height * 0.5unless a custom radius is passed (submodules/TelegramUI/Components/ButtonComponent/Sources/ButtonComponent.swift, lines 756-758). The iOS Stars transaction screen uses this style for its main and cancel buttons.The macOS client already follows this rule for the buttons of its modal windows (
acceptView.layer?.cornerRadius = acceptRect.height / 2inModal.swift). The Stars windows drew their own buttons with a fixed radius of 10, so they looked squarish next to the capsule buttons of the modal windows. The same fixed radius of 10 is also used by the Premium buttons (PremiumBoardingController.swift,PremiumLimitController.swift) and by the Boost and Stars withdrawal buttons (BoostChannelModalController.swift, the monetization withdrawal inputs); those are changed in #139 and #142. Until they are merged too, the Stars buttons will differ from them.All five buttons are 40 pt high, so a fixed 20 is exactly half of the height. Buttons of other packages with the same fixed radius (PremiumUI, BoostUI, MonetizationUI) are not touched, to keep this change to one window family.
Screenshot/video result (before/after)
My Stars window, same account and same scroll position. Left: before (radius 10). Right: after (radius 20). The transaction history is cropped out of the screenshot.
Confirmation
Tested on macOS 26.7.1 (25G241), Apple M2, with local Debug builds of
masterat e188309 without and with this commit.Testing limitations:
Only the "Buy More Stars" button on My Stars was checked in the app. The withdraw button of the same screen, the pay button of the purchase window, the send button of the Stars reactions window and the "raise bid" button of the auction list were not opened. They are the same one-line change on controls of the same height, and I checked their heights in code.
Only macOS 26.7.1 was available. No other macOS version, no Intel machine, no dark theme.
I built with the Postbox
assertinOrderedItemListTable.replaceItemsdisabled (-assert-config Release), because a Debug build traps on my account at launch on a duplicate recent inline bot entry. This is unrelated to the change.I confirm that I have tested the affected behavior and verified that it works properly, or verified the content and links for a documentation-only change.