MCPAsk AI

Search

Search skills, authors and topics

kemiljk / skills

dxe-apple-native-ui

Build or review native Apple interfaces, including platform controls, accessibility, state, navigation, and macOS window behavior.

Install

npx skills add https://github.com/kemiljk/skills --skill dxe-apple-native-ui

Apple native verification

Use this for rendered claims, not as a mandatory toolchain recipe. Record unavailable checks as limits.

Minimum evidence

  1. Run the repository's Xcode build and test targets when available.
  2. Exercise the primary user task on the primary target and one contrasting form factor: iPhone plus iPad split view, resizable macOS window, or the relevant watchOS/tvOS/visionOS target.
  3. Repeat relevant surfaces with larger Dynamic Type, dark appearance, Reduce Motion, and right-to-left layout when the product supports it.
  4. Inspect VoiceOver behaviour with Accessibility Inspector or a device: names, values, traits, order, grouping, adjustable controls, and focus after presentation/dismissal.
  5. Capture simulator/device runtime diagnostics separately from build warnings. Reproduce before describing one as a product defect.

Settled UI tests

Do not sample a sheet, menu, alert, or animation immediately after its trigger. Wait for the target state.

swift
let savedNotice = app.staticTexts["Saved"]app.buttons["Save"].tap()XCTAssertTrue(savedNotice.waitForExistence(timeout: 2))XCTAssertTrue(savedNotice.isHittable)

For tests that query accessibility state, wait for the native element or visible result that establishes completion. A fixed sleep is only a last-resort diagnostic, never the evidence boundary.

Platform reminders

  • iOS/iPadOS: keyboard avoidance, safe areas, rotation, split view, pointer, and state restoration.
  • macOS: window resizing, menu and command validation, toolbar placement, keyboard-only workflows, selection, copy/paste, drag/drop, undo, Finder/open-save integration, and multi-window state restoration across relaunch. Use the behaviour probes in macos-native-workflows.md [blocked].
  • watchOS/tvOS/visionOS: the platform's focus, navigation, input, and power constraints are primary contracts.

#Preview is useful local evidence, but it does not replace accessibility or device/runtime verification.

iOS and iPadOS probes

Pick the probes that match the change. Each names the defect it catches. Confirm flags and commands against the installed Xcode; they are tooling, and tooling changes.

Worst-case layout

  • Smallest supported iPhone at the largest accessibility text size, then the smallest text size. If both hold, the middle does.
  • Rotation, and on iPad every multitasking width, including the narrowest.
  • Change text size, appearance, and Reduce Motion while the screen is showing. A setting that needs a relaunch to apply is a defect.

Scheme launch arguments

Set these under the scheme's Run arguments. They last for that process only.

ArgumentShows
-NSDoubleLocalizedString YESLayouts that break on longer translations
-NSShowNonLocalizedStrings YESStrings that are not localised
-NSForceRightToLeftWritingDirection YESRight-to-left layout without changing language
-AppleLanguages (de) / -AppleLocale de_DEA language or region without changing device settings
-UIFocusLoopDebuggerEnabled YESKeyboard focus order as an overlay

Launch arguments override user defaults, so a project's own flags (seed data, skip onboarding, force an entitlement) can jump a test straight to a deep screen. Keep such flags out of release logic.

Assistive technology

  • VoiceOver with Screen Curtain, from a cold launch, through one complete task.
  • Voice Control's names and numbers overlays for labels, order, and grouping.
  • Accessibility Inspector: auto-navigate, audit, settings toggles, contrast calculator. Cross-check SwiftUI audit results by hand.
  • Actions rotor through every drag and drop and every hidden row control.
  • Full keyboard: Tab between groups, arrows within, Return to open, and the Command overlay for shortcut coverage. UIFocusDebugger in LLDB explains why an item cannot take focus.
  • A pointer on iPad for hover regions and effects. The simulator can capture the Mac's pointer.

Performance

  • Release configuration, on the oldest supported device as well as a recent one.
  • Instruments: App Launch for start-up, Animation Hitches for scrolling, the SwiftUI template for body evaluation, Allocations for memory.
  • Simulator Debug menu: Color Blended Layers for overdraw.
  • A launch test with XCTOSSignpostMetric.applicationLaunch catches regressions.
  • For image memory, capture a memory graph and compare its footprint before and after a change with vmmap --summary.

Entry points

Exercise each on both a cold launch and a running app, and once while signed out.

EntrySimulator probe
URL scheme or universal linkxcrun simctl openurl <device> <url>
Push notificationxcrun simctl push <device> <bundle-id> payload.json, or drag a .apns file onto the simulator
Quick action or other launch-time pathThe scheme's "wait for the executable to be launched" option, then launch from the Home Screen
App Clip invocationThe _XCAppClipURL scheme environment variable; Local Experiences in Developer settings on a device
Spotlight resultThe Core Spotlight testing options in Developer settings
State restorationBackground the app, stop the debugger, run again. Force-quitting discards saved state.

Name the device by identifier when more than one simulator is booted; booted picks one arbitrarily. simctl io records screenshots and video as evidence, and simctl addmedia seeds the photo library.

System state

  • Low Power Mode and the Reduce Transparency, Increase Contrast, Bold Text, and Button Shapes settings, toggled while the app is frontmost.
  • Dark appearance on a real device, comparing a presented sheet against the view under it.
  • iCloud signed out, and permissions revoked in Settings between launches.
  • A share extension with the largest photo in the library.

Development assets and #Preview data are stripped from release builds. Reference them only from preview code.