|
1 | | -# Figma Code Connect Integration for Backpack Android |
| 1 | +# Figma Code Connect |
2 | 2 |
|
3 | | -## Overview |
| 3 | +Generates code snippets from Figma designs for Backpack Android components. |
4 | 4 |
|
5 | | -Figma Code Connect bridges the gap between design and development by automatically generating accurate code snippets from Figma designs. This guide walks you through integrating and using Figma Code Connect with Backpack Android components. |
| 5 | +## Quick Start |
6 | 6 |
|
7 | | -## 📚 Documentation Structure |
| 7 | +1. Get [Figma access token](https://www.figma.com/settings) |
| 8 | +2. `export FIGMA_ACCESS_TOKEN="your_token"` |
| 9 | +3. Create `Component.figma.kt` with annotations |
| 10 | +4. Test: `npx @figma/code-connect parse --verbose` |
| 11 | +5. Publish: `npx @figma/code-connect publish` |
8 | 12 |
|
9 | | -This guide is split into focused documents for easier navigation: |
| 13 | +## Documentation |
10 | 14 |
|
11 | | -1. **[Getting Started](./getting-started.md)** - Initial setup and installation |
12 | | -2. **[Component Integration](./component-integration.md)** - How to add Code Connect to components |
13 | | -3. **[Annotations Guide](./annotations-guide.md)** - Complete reference for all annotations |
14 | | -4. **[Testing & Publishing](./testing-publishing.md)** - Verification and deployment workflow |
15 | | -5. **[Examples](./examples.md)** - Real-world implementation examples |
16 | | -6. **[Quick Reference](./quick-reference.md)** - Essential commands and patterns |
| 15 | +- **[Getting Started](./getting-started.md)** - Setup and installation |
| 16 | +- **[Annotations Guide](./annotations-guide.md)** - Annotation reference |
| 17 | +- **[Component Integration](./component-integration.md)** - Adding to components |
| 18 | +- **[Examples](./examples.md)** - Real implementations |
| 19 | +- **[Testing & Publishing](./testing-publishing.md)** - Verification workflow |
| 20 | +- **[CI Integration](./ci-integration.md)** - CI/CD setup |
| 21 | +- **[Quick Reference](./quick-reference.md)** - Commands and patterns |
17 | 22 |
|
18 | | -## 🚀 Quick Start |
| 23 | +## Current Components |
19 | 24 |
|
20 | | -If you're already familiar with the setup, here's the essential workflow: |
21 | | - |
22 | | -1. **Add annotations** to your component |
23 | | -2. **Test locally**: `figma connect parse --verbose` |
24 | | -3. **Test publishing**: `figma connect publish --dry-run` |
25 | | -4. **Publish**: `figma connect publish` |
26 | | - |
27 | | -## 🎯 What You'll Learn |
28 | | - |
29 | | -- ✅ How to set up Figma Code Connect in Backpack Android |
30 | | -- ✅ When and how to use different annotations (`@FigmaConnect`, `@FigmaVariant`, `@FigmaProperty`) |
31 | | -- ✅ Best practices for component integration |
32 | | -- ✅ Testing and publishing workflow |
33 | | -- ✅ Real examples from `BpkButton` and `BpkText` |
34 | | - |
35 | | -## 🔧 Prerequisites |
36 | | - |
37 | | -- Android Studio with Kotlin support |
38 | | -- Node.js (for Figma CLI) |
39 | | -- Access to Backpack Figma workspace |
40 | | -- Figma personal access token |
41 | | - |
42 | | -## 📋 Current Integration Status |
43 | | - |
44 | | -### ✅ Integrated Components |
45 | | -- **BpkButton** - 4 icon variants (None, Left, Right, Icon only) |
46 | | -- **BpkText** - 18 typography variants (Hero1-5, Heading1-5, etc.) |
| 25 | +- **BpkButton** - 4 icon variants |
| 26 | +- **BpkText** - 18 typography variants |
47 | 27 | - **BpkCard** - Basic example |
48 | | - |
49 | | -### 🔄 Integration Pattern |
50 | | -Each component variant uses individual `@FigmaVariant` classes for clean, parser-friendly code generation. |
51 | | - |
52 | | -## 🆘 Need Help? |
53 | | - |
54 | | -- **Quick questions**: Check the [Annotations Guide](annotations-guide.md) |
55 | | -- **Setup issues**: See [Getting Started](getting-started.md) |
56 | | -- **Integration patterns**: Review [Examples](examples.md) |
57 | | -- **Testing problems**: Visit [Testing & Publishing](testing-publishing.md) |
58 | | - |
59 | | ---- |
60 | | - |
61 | | -**Next Step**: Start with [Getting Started](getting-started.md) to set up your development environment. |
0 commit comments