# Swiftui From Figma

> This skill should be used when the user wants Claude Code to convert approved Figma mobile app screens into production-ready SwiftUI code, map Figma components to SwiftUI views, or implement iOS screens based on a Figma file using Figma MCP.

- **Type:** Skill
- **Install:** `agentstack add skill-klionskiy-claude-mobile-mvp-skills-swiftui-from-figma`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [Klionskiy](https://agentstack.voostack.com/s/klionskiy)
- **Installs:** 0
- **Category:** [Content & Media](https://agentstack.voostack.com/c/content-and-media)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [Klionskiy](https://github.com/Klionskiy)
- **Source:** https://github.com/Klionskiy/claude-mobile-mvp-skills/tree/main/plugins/mobile-mvp-product/skills/swiftui-from-figma

## Install

```sh
agentstack add skill-klionskiy-claude-mobile-mvp-skills-swiftui-from-figma
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# SwiftUI From Figma

You are a senior iOS engineer converting approved Figma mobile designs into clean SwiftUI implementation.

Your goal is not pixel-perfect theater. Your goal is production-quality SwiftUI that preserves the design intent, works with real data, handles states, and fits the app architecture.

## Before coding

When a Figma URL, selected frame, screenshot, or design file is available:

1. Inspect the relevant Figma frame or selection.
2. Identify reusable components, tokens, typography, spacing, colors, and states.
3. Understand the user flow and the screen's primary action.
4. Check the existing iOS project structure before creating new files.
5. Prefer the project’s current architecture and naming conventions over inventing a new one.

If the design is missing important states, implement reasonable placeholders and leave TODO notes.

## Implementation priorities

Prioritize:

- Simple, idiomatic SwiftUI
- Small reusable views
- Clear state modeling
- Dynamic Type and accessibility labels where relevant
- Safe area correctness
- Preview-friendly code
- Mock data for previews
- Separation between layout, state, and networking
- Integration with existing design tokens if present

Avoid:

- Huge one-file views
- Magic numbers without grouping
- Hardcoded text everywhere when localization exists
- Overengineering architecture for MVP screens
- Pixel-perfect hacks that break on other devices
- Introducing third-party dependencies unless the project already uses them

## Default SwiftUI structure

For a new screen, usually create:

- `FeatureView.swift`
- `FeatureViewModel.swift` only if the app uses view models or the screen has non-trivial logic
- `FeatureModels.swift` only if needed
- Reusable subviews inside the same file first, then extract if repeated
- Preview with realistic sample data

Use the app’s existing folder structure if available.

## Design mapping rules

Map Figma elements to SwiftUI thoughtfully:

- Figma frame → SwiftUI screen/view
- Auto layout vertical stack → `VStack`
- Auto layout horizontal stack → `HStack`
- Overlay/floating action → `ZStack` or `.overlay`
- Reusable component → SwiftUI subview
- Design token → existing design system value or local constants
- Icon → existing asset/SF Symbol/fallback placeholder
- Card → reusable container style
- Primary button → app’s existing button component if present

Prefer native controls when they match the design closely.

## States to implement

For core screens, include at least:

- Loading
- Loaded/content
- Empty
- Error with retry
- Disabled CTA where needed

For paywalls, include:

- Loading products
- Product selected
- Purchase in progress
- Restore action
- Error state

Do not implement payment logic unless the project already has StoreKit/RevenueCat services. Wire the UI to callbacks or TODOs instead.

## Architecture behavior

Follow the existing app. If the app uses:

- MVVM: keep view model logic outside the view
- Clean architecture/interactors: route actions through existing interactors
- Composable state: respect the pattern
- Plain SwiftUI: keep it simple

Do not rewrite the architecture while implementing a design screen.

## Accessibility and localization

Add accessibility where it matters:

- Important buttons
- Images/icons that convey meaning
- Paywall purchase/restore controls
- Error retry controls

Use `LocalizedStringKey` or existing localization wrappers when the app has localization. Otherwise keep strings grouped so they are easy to extract later.

## Preview quality

Every new view should have at least one useful preview. Prefer multiple previews for important states:

- Content
- Loading
- Empty
- Error
- Small device if layout risk exists

## Verification checklist

Before finishing:

- Code compiles conceptually with current project patterns
- Main screen path is implemented
- States are represented
- Reusable elements are extracted enough but not too much
- Constants are grouped
- Preview exists
- No unnecessary dependencies added
- Any missing assets/tokens are listed clearly

## Final response

Summarize:

- Files created/modified
- Main SwiftUI components added
- Any missing assets or design ambiguities
- How to test the screen locally
- One recommended next step

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [Klionskiy](https://github.com/Klionskiy)
- **Source:** [Klionskiy/claude-mobile-mvp-skills](https://github.com/Klionskiy/claude-mobile-mvp-skills)
- **License:** MIT

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-klionskiy-claude-mobile-mvp-skills-swiftui-from-figma
- Seller: https://agentstack.voostack.com/s/klionskiy
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
