We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7d775a2 commit 513458aCopy full SHA for 513458a
Sources/UIKitBackend/UIKitBackend+Control.swift
@@ -18,15 +18,12 @@ final class ButtonWidget: WrapperWidget<UIButton> {
18
}
19
20
init() {
21
- let type: UIButton.ButtonType
22
#if os(tvOS)
23
- type = .system
24
event = .primaryActionTriggered
25
#else
26
- type = .custom
27
event = .touchUpInside
28
#endif
29
- super.init(child: UIButton(type: type))
+ super.init(child: UIButton(type: .system))
30
31
32
@@ -268,7 +265,8 @@ extension UIKitBackend {
268
265
UIKitBackend.attributedString(
269
266
text: label,
270
267
environment: environment,
271
- defaultForegroundColor: .link
+ // Handle Mac Catalyst
+ defaultForegroundColor: deviceClass == .desktop ? .label : .link
272
),
273
for: .normal
274
)
0 commit comments