Install any skill in seconds. Free to start, no credit card required.
Get Started Free →dpearson2699/focus-engine
Implements keyboard, directional, and scene-level focus behavior across SwiftUI and UIKit.
Passed 23 of 23 test cases with the skill, and 21 of 23 without it.
2 fixed21 passed either way0 still failing0 broke
Tokens, turns and time describe resource use, not a dollar price.
One of 2 test cases the skill fixed. Same model, same prompt, with and without the skill.
A developer creates a custom SelectableCard in SwiftUI using VStack and .onTapGesture. They want keyboard arrow keys and TV remotes to focus this card and trigger its action when the user presses Enter or the select button. They plan to use .focusable() and attach custom key equivalences. What modifier and interaction parameter should be applied to custom views for standard trigger behavior?
| Checked | Without skill | With skill |
|---|---|---|
| Specifies interactions with activate on the focusable modifier | Missed | Passed |
The instructions your model reads when the skill loads.
Focus behavior for SwiftUI and UIKit apps targeting iOS 26+, iPadOS, macOS, tvOS, and visionOS connected-input paths. Covers keyboard focus, directional focus, scene-focused values, focus restoration, and UIKit focus guides. focusSection() guidance in this skill applies to macOS and tvOS. visionOS gaze-driven hover is an input affordance, not focus. Accessibility-specific focus for VoiceOver and Switch Control lives in the ios-accessibility skill.
When a request mixes focus with accessibility or spatial input, keep the boundary explicit:
ios-accessibility.Use @FocusState to read and write focus placement inside a scene. Use Bool for a single target or an optional Hashable enum for multiple targets.
struct LoginView: View {
enum Field: Hashable { case email, password }
@State private var email = ""
@State private var password = ""
@FocusState private var focusedField: Field?
var body: some View {
Form {
TextField("Email", text: $email)
.focused($focusedField, equals: .email)
SecureField("Password", text: $password)
test cases passed, vs 21 / 23 without
More skills from the same source and nearby in the registry, with their headline benchmark lift.