@iamnishankhan/opencode-kit-grok 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (198) hide show
  1. package/bin/cli.js +46 -0
  2. package/kit/.opencode/AGENTS.md +392 -0
  3. package/kit/.opencode/README.md +71 -0
  4. package/kit/.opencode/USAGE.md +405 -0
  5. package/kit/.opencode/agents/backend-specialist.md +278 -0
  6. package/kit/.opencode/agents/code-archaeologist.md +114 -0
  7. package/kit/.opencode/agents/database-architect.md +233 -0
  8. package/kit/.opencode/agents/debugger.md +234 -0
  9. package/kit/.opencode/agents/devops-engineer.md +252 -0
  10. package/kit/.opencode/agents/documentation-writer.md +111 -0
  11. package/kit/.opencode/agents/explorer-agent.md +83 -0
  12. package/kit/.opencode/agents/frontend-specialist.md +606 -0
  13. package/kit/.opencode/agents/game-developer.md +169 -0
  14. package/kit/.opencode/agents/mobile-developer.md +385 -0
  15. package/kit/.opencode/agents/orchestrator.md +213 -0
  16. package/kit/.opencode/agents/penetration-tester.md +197 -0
  17. package/kit/.opencode/agents/performance-optimizer.md +194 -0
  18. package/kit/.opencode/agents/product-manager.md +120 -0
  19. package/kit/.opencode/agents/product-owner.md +103 -0
  20. package/kit/.opencode/agents/project-planner.md +418 -0
  21. package/kit/.opencode/agents/qa-automation-engineer.md +113 -0
  22. package/kit/.opencode/agents/security-auditor.md +179 -0
  23. package/kit/.opencode/agents/seo-specialist.md +119 -0
  24. package/kit/.opencode/agents/test-engineer.md +169 -0
  25. package/kit/.opencode/commands/brainstorm.md +113 -0
  26. package/kit/.opencode/commands/coordinate.md +72 -0
  27. package/kit/.opencode/commands/create.md +63 -0
  28. package/kit/.opencode/commands/debug.md +102 -0
  29. package/kit/.opencode/commands/deploy.md +175 -0
  30. package/kit/.opencode/commands/enhance.md +62 -0
  31. package/kit/.opencode/commands/orchestrate.md +241 -0
  32. package/kit/.opencode/commands/plan.md +89 -0
  33. package/kit/.opencode/commands/preview.md +80 -0
  34. package/kit/.opencode/commands/remember.md +67 -0
  35. package/kit/.opencode/commands/status.md +86 -0
  36. package/kit/.opencode/commands/test.md +143 -0
  37. package/kit/.opencode/commands/verify.md +71 -0
  38. package/kit/.opencode/memory/MEMORY.md +6 -0
  39. package/kit/.opencode/memory/feedback-history.md +9 -0
  40. package/kit/.opencode/memory/project-conventions.md +16 -0
  41. package/kit/.opencode/memory/tech-decisions.md +10 -0
  42. package/kit/.opencode/memory/user-preferences.md +9 -0
  43. package/kit/.opencode/opencode.json +15 -0
  44. package/kit/.opencode/scripts/README.md +95 -0
  45. package/kit/.opencode/scripts/auto_preview.py +149 -0
  46. package/kit/.opencode/scripts/checklist.py +75 -0
  47. package/kit/.opencode/scripts/component_registry.py +238 -0
  48. package/kit/.opencode/scripts/dependency_graph.py +73 -0
  49. package/kit/.opencode/scripts/generate_manifest.py +44 -0
  50. package/kit/.opencode/scripts/session_manager.py +120 -0
  51. package/kit/.opencode/scripts/tests/test_toolkit.py +238 -0
  52. package/kit/.opencode/scripts/validate_kit.py +397 -0
  53. package/kit/.opencode/scripts/validation_runner.py +216 -0
  54. package/kit/.opencode/scripts/verify_all.py +85 -0
  55. package/kit/.opencode/skills/api-patterns/SKILL.md +83 -0
  56. package/kit/.opencode/skills/api-patterns/api-style.md +42 -0
  57. package/kit/.opencode/skills/api-patterns/auth.md +24 -0
  58. package/kit/.opencode/skills/api-patterns/documentation.md +26 -0
  59. package/kit/.opencode/skills/api-patterns/graphql.md +41 -0
  60. package/kit/.opencode/skills/api-patterns/rate-limiting.md +31 -0
  61. package/kit/.opencode/skills/api-patterns/response.md +37 -0
  62. package/kit/.opencode/skills/api-patterns/rest.md +40 -0
  63. package/kit/.opencode/skills/api-patterns/scripts/api_validator.py +211 -0
  64. package/kit/.opencode/skills/api-patterns/security-testing.md +122 -0
  65. package/kit/.opencode/skills/api-patterns/trpc.md +41 -0
  66. package/kit/.opencode/skills/api-patterns/versioning.md +22 -0
  67. package/kit/.opencode/skills/app-builder/SKILL.md +78 -0
  68. package/kit/.opencode/skills/app-builder/agent-coordination.md +71 -0
  69. package/kit/.opencode/skills/app-builder/feature-building.md +53 -0
  70. package/kit/.opencode/skills/app-builder/project-detection.md +45 -0
  71. package/kit/.opencode/skills/app-builder/scaffolding.md +110 -0
  72. package/kit/.opencode/skills/app-builder/tech-stack.md +41 -0
  73. package/kit/.opencode/skills/app-builder/templates/SKILL.md +39 -0
  74. package/kit/.opencode/skills/app-builder/templates/astro-static/TEMPLATE.md +78 -0
  75. package/kit/.opencode/skills/app-builder/templates/chrome-extension/TEMPLATE.md +96 -0
  76. package/kit/.opencode/skills/app-builder/templates/cli-tool/TEMPLATE.md +88 -0
  77. package/kit/.opencode/skills/app-builder/templates/electron-desktop/TEMPLATE.md +97 -0
  78. package/kit/.opencode/skills/app-builder/templates/express-api/TEMPLATE.md +89 -0
  79. package/kit/.opencode/skills/app-builder/templates/flutter-app/TEMPLATE.md +93 -0
  80. package/kit/.opencode/skills/app-builder/templates/monorepo-turborepo/TEMPLATE.md +97 -0
  81. package/kit/.opencode/skills/app-builder/templates/nextjs-fullstack/TEMPLATE.md +126 -0
  82. package/kit/.opencode/skills/app-builder/templates/nextjs-saas/TEMPLATE.md +125 -0
  83. package/kit/.opencode/skills/app-builder/templates/nextjs-static/TEMPLATE.md +174 -0
  84. package/kit/.opencode/skills/app-builder/templates/nuxt-app/TEMPLATE.md +127 -0
  85. package/kit/.opencode/skills/app-builder/templates/python-fastapi/TEMPLATE.md +94 -0
  86. package/kit/.opencode/skills/app-builder/templates/react-native-app/TEMPLATE.md +121 -0
  87. package/kit/.opencode/skills/architecture/SKILL.md +57 -0
  88. package/kit/.opencode/skills/architecture/context-discovery.md +43 -0
  89. package/kit/.opencode/skills/architecture/examples.md +94 -0
  90. package/kit/.opencode/skills/architecture/pattern-selection.md +68 -0
  91. package/kit/.opencode/skills/architecture/patterns-reference.md +50 -0
  92. package/kit/.opencode/skills/architecture/trade-off-analysis.md +77 -0
  93. package/kit/.opencode/skills/bash-linux/SKILL.md +201 -0
  94. package/kit/.opencode/skills/batch-operations/SKILL.md +105 -0
  95. package/kit/.opencode/skills/behavioral-modes/SKILL.md +253 -0
  96. package/kit/.opencode/skills/brainstorming/SKILL.md +178 -0
  97. package/kit/.opencode/skills/brainstorming/dynamic-questioning.md +350 -0
  98. package/kit/.opencode/skills/clean-code/SKILL.md +201 -0
  99. package/kit/.opencode/skills/code-review-checklist/SKILL.md +111 -0
  100. package/kit/.opencode/skills/code-review-graph/SKILL.md +305 -0
  101. package/kit/.opencode/skills/context-compression/SKILL.md +145 -0
  102. package/kit/.opencode/skills/coordinator-mode/SKILL.md +208 -0
  103. package/kit/.opencode/skills/database-design/SKILL.md +54 -0
  104. package/kit/.opencode/skills/database-design/database-selection.md +43 -0
  105. package/kit/.opencode/skills/database-design/indexing.md +39 -0
  106. package/kit/.opencode/skills/database-design/migrations.md +48 -0
  107. package/kit/.opencode/skills/database-design/optimization.md +36 -0
  108. package/kit/.opencode/skills/database-design/orm-selection.md +30 -0
  109. package/kit/.opencode/skills/database-design/schema-design.md +56 -0
  110. package/kit/.opencode/skills/database-design/scripts/schema_validator.py +172 -0
  111. package/kit/.opencode/skills/deployment-procedures/SKILL.md +243 -0
  112. package/kit/.opencode/skills/design-spec/SKILL.md +185 -0
  113. package/kit/.opencode/skills/design-spec/collection.md +106 -0
  114. package/kit/.opencode/skills/documentation-templates/SKILL.md +196 -0
  115. package/kit/.opencode/skills/frontend-architecture/SKILL.md +245 -0
  116. package/kit/.opencode/skills/frontend-design/SKILL.md +1222 -0
  117. package/kit/.opencode/skills/frontend-design/redesign.md +178 -0
  118. package/kit/.opencode/skills/frontend-design/scripts/accessibility_checker.py +145 -0
  119. package/kit/.opencode/skills/frontend-design/scripts/ux_audit.py +722 -0
  120. package/kit/.opencode/skills/frontend-design/style-brutalist.md +92 -0
  121. package/kit/.opencode/skills/frontend-design/style-minimalist.md +85 -0
  122. package/kit/.opencode/skills/game-development/2d-games/SKILL.md +118 -0
  123. package/kit/.opencode/skills/game-development/3d-games/SKILL.md +134 -0
  124. package/kit/.opencode/skills/game-development/SKILL.md +169 -0
  125. package/kit/.opencode/skills/game-development/game-art/SKILL.md +184 -0
  126. package/kit/.opencode/skills/game-development/game-audio/SKILL.md +189 -0
  127. package/kit/.opencode/skills/game-development/game-design/SKILL.md +128 -0
  128. package/kit/.opencode/skills/game-development/mobile-games/SKILL.md +107 -0
  129. package/kit/.opencode/skills/game-development/multiplayer/SKILL.md +131 -0
  130. package/kit/.opencode/skills/game-development/pc-games/SKILL.md +143 -0
  131. package/kit/.opencode/skills/game-development/vr-ar/SKILL.md +122 -0
  132. package/kit/.opencode/skills/game-development/web-games/SKILL.md +149 -0
  133. package/kit/.opencode/skills/geo-fundamentals/SKILL.md +158 -0
  134. package/kit/.opencode/skills/geo-fundamentals/scripts/geo_checker.py +273 -0
  135. package/kit/.opencode/skills/i18n-localization/SKILL.md +156 -0
  136. package/kit/.opencode/skills/i18n-localization/scripts/i18n_checker.py +223 -0
  137. package/kit/.opencode/skills/intelligent-routing/SKILL.md +337 -0
  138. package/kit/.opencode/skills/lint-and-validate/SKILL.md +47 -0
  139. package/kit/.opencode/skills/lint-and-validate/scripts/lint_runner.py +184 -0
  140. package/kit/.opencode/skills/lint-and-validate/scripts/type_coverage.py +245 -0
  141. package/kit/.opencode/skills/mcp-builder/SKILL.md +205 -0
  142. package/kit/.opencode/skills/memory-system/SKILL.md +181 -0
  143. package/kit/.opencode/skills/mobile-design/SKILL.md +396 -0
  144. package/kit/.opencode/skills/mobile-design/decision-trees.md +516 -0
  145. package/kit/.opencode/skills/mobile-design/mobile-backend.md +491 -0
  146. package/kit/.opencode/skills/mobile-design/mobile-color-system.md +420 -0
  147. package/kit/.opencode/skills/mobile-design/mobile-debugging.md +122 -0
  148. package/kit/.opencode/skills/mobile-design/mobile-design-thinking.md +357 -0
  149. package/kit/.opencode/skills/mobile-design/mobile-navigation.md +458 -0
  150. package/kit/.opencode/skills/mobile-design/mobile-performance.md +767 -0
  151. package/kit/.opencode/skills/mobile-design/mobile-testing.md +356 -0
  152. package/kit/.opencode/skills/mobile-design/mobile-typography.md +433 -0
  153. package/kit/.opencode/skills/mobile-design/platform-android.md +666 -0
  154. package/kit/.opencode/skills/mobile-design/platform-ios.md +561 -0
  155. package/kit/.opencode/skills/mobile-design/scripts/mobile_audit.py +670 -0
  156. package/kit/.opencode/skills/mobile-design/touch-psychology.md +537 -0
  157. package/kit/.opencode/skills/nextjs-react-expert/1-async-eliminating-waterfalls.md +351 -0
  158. package/kit/.opencode/skills/nextjs-react-expert/2-bundle-bundle-size-optimization.md +240 -0
  159. package/kit/.opencode/skills/nextjs-react-expert/3-server-server-side-performance.md +490 -0
  160. package/kit/.opencode/skills/nextjs-react-expert/4-client-client-side-data-fetching.md +264 -0
  161. package/kit/.opencode/skills/nextjs-react-expert/5-rerender-re-render-optimization.md +581 -0
  162. package/kit/.opencode/skills/nextjs-react-expert/6-rendering-rendering-performance.md +432 -0
  163. package/kit/.opencode/skills/nextjs-react-expert/7-js-javascript-performance.md +684 -0
  164. package/kit/.opencode/skills/nextjs-react-expert/8-advanced-advanced-patterns.md +150 -0
  165. package/kit/.opencode/skills/nextjs-react-expert/9-cache-components.md +103 -0
  166. package/kit/.opencode/skills/nextjs-react-expert/SKILL.md +293 -0
  167. package/kit/.opencode/skills/nextjs-react-expert/scripts/convert_rules.py +222 -0
  168. package/kit/.opencode/skills/nextjs-react-expert/scripts/react_performance_checker.py +281 -0
  169. package/kit/.opencode/skills/nodejs-best-practices/SKILL.md +336 -0
  170. package/kit/.opencode/skills/parallel-agents/SKILL.md +192 -0
  171. package/kit/.opencode/skills/performance-profiling/SKILL.md +145 -0
  172. package/kit/.opencode/skills/performance-profiling/scripts/bundle_analyzer.py +120 -0
  173. package/kit/.opencode/skills/performance-profiling/scripts/lighthouse_audit.py +108 -0
  174. package/kit/.opencode/skills/plan-writing/SKILL.md +153 -0
  175. package/kit/.opencode/skills/powershell-windows/SKILL.md +169 -0
  176. package/kit/.opencode/skills/python-patterns/SKILL.md +443 -0
  177. package/kit/.opencode/skills/red-team-tactics/SKILL.md +201 -0
  178. package/kit/.opencode/skills/rust-pro/SKILL.md +177 -0
  179. package/kit/.opencode/skills/seo-fundamentals/SKILL.md +131 -0
  180. package/kit/.opencode/skills/seo-fundamentals/scripts/seo_checker.py +219 -0
  181. package/kit/.opencode/skills/server-management/SKILL.md +163 -0
  182. package/kit/.opencode/skills/simplify-code/SKILL.md +131 -0
  183. package/kit/.opencode/skills/skillify/SKILL.md +115 -0
  184. package/kit/.opencode/skills/systematic-debugging/SKILL.md +111 -0
  185. package/kit/.opencode/skills/tailwind-patterns/SKILL.md +271 -0
  186. package/kit/.opencode/skills/tdd-workflow/SKILL.md +151 -0
  187. package/kit/.opencode/skills/testing-patterns/SKILL.md +180 -0
  188. package/kit/.opencode/skills/testing-patterns/scripts/test_runner.py +219 -0
  189. package/kit/.opencode/skills/verify-changes/SKILL.md +127 -0
  190. package/kit/.opencode/skills/vulnerability-scanner/SKILL.md +278 -0
  191. package/kit/.opencode/skills/vulnerability-scanner/checklists.md +124 -0
  192. package/kit/.opencode/skills/vulnerability-scanner/scripts/dependency_analyzer.py +144 -0
  193. package/kit/.opencode/skills/vulnerability-scanner/scripts/security_scan.py +410 -0
  194. package/kit/.opencode/skills/web-design-guidelines/SKILL.md +56 -0
  195. package/kit/.opencode/skills/webapp-testing/SKILL.md +189 -0
  196. package/kit/.opencode/skills/webapp-testing/scripts/playwright_runner.py +123 -0
  197. package/lib/init.js +61 -0
  198. package/package.json +21 -0
@@ -0,0 +1,396 @@
1
+ ---
2
+ name: mobile-design
3
+ description: Mobile-first design thinking and decision-making for iOS and Android apps. Touch interaction, performance patterns, platform conventions. Teaches principles, not fixed values. Use when building React Native, Flutter, or native mobile apps.
4
+ compatibility: opencode
5
+ metadata:
6
+ when_to_use: "\"When designing mobile app interfaces for iOS/Android, React Native, or Flutter. Touch interaction and platform conventions. NOT for web apps.\""
7
+ version: "1.0.0"
8
+ ---
9
+ # Mobile Design System
10
+
11
+ > **Philosophy:** Touch-first. Battery-conscious. Platform-respectful. Offline-capable.
12
+ > **Core Principle:** Mobile is NOT a small desktop. THINK mobile constraints, ASK platform choice.
13
+
14
+ ---
15
+
16
+ ## 🔧 Runtime Scripts
17
+
18
+ **Execute these for validation (don't read, just run):**
19
+
20
+ | Script | Purpose | Usage |
21
+ |--------|---------|-------|
22
+ | `.opencode/scripts/mobile_audit.py` | Mobile UX & Touch Audit | `python .opencode/scripts/mobile_audit.py <project_path>` |
23
+
24
+ ---
25
+
26
+ ## 🔴 MANDATORY: Read Reference Files Before Working!
27
+
28
+ **⛔ DO NOT start development until you read the relevant files:**
29
+
30
+ ### Universal (Always Read)
31
+
32
+ | File | Content | Status |
33
+ |------|---------|--------|
34
+ | **[mobile-design-thinking.md](mobile-design-thinking.md)** | **⚠️ ANTI-MEMORIZATION: Forces thinking, prevents AI defaults** | **⬜ CRITICAL FIRST** |
35
+ | **[touch-psychology.md](touch-psychology.md)** | **Fitts' Law, gestures, haptics, thumb zone** | **⬜ CRITICAL** |
36
+ | **[mobile-performance.md](mobile-performance.md)** | **RN/Flutter performance, 60fps, memory** | **⬜ CRITICAL** |
37
+ | **[mobile-backend.md](mobile-backend.md)** | **Push notifications, offline sync, mobile API** | **⬜ CRITICAL** |
38
+ | **[mobile-testing.md](mobile-testing.md)** | **Testing pyramid, E2E, platform-specific** | **⬜ CRITICAL** |
39
+ | **[mobile-debugging.md](mobile-debugging.md)** | **Native vs JS debugging, RN DevTools, Logcat** | **⬜ CRITICAL** |
40
+ | [mobile-navigation.md](mobile-navigation.md) | Tab/Stack/Drawer, deep linking | ⬜ Read |
41
+ | [mobile-typography.md](mobile-typography.md) | System fonts, Dynamic Type, a11y | ⬜ Read |
42
+ | [mobile-color-system.md](mobile-color-system.md) | OLED, dark mode, battery-aware | ⬜ Read |
43
+ | [decision-trees.md](decision-trees.md) | Framework/state/storage selection | ⬜ Read |
44
+
45
+ > 🧠 **mobile-design-thinking.md is PRIORITY!** This file ensures AI thinks instead of using memorized patterns.
46
+
47
+ ### Platform-Specific (Read Based on Target)
48
+
49
+ | Platform | File | Content | When to Read |
50
+ |----------|------|---------|--------------|
51
+ | **iOS** | [platform-ios.md](platform-ios.md) | Human Interface Guidelines, SF Pro, SwiftUI patterns | Building for iPhone/iPad |
52
+ | **Android** | [platform-android.md](platform-android.md) | Material Design 3, Roboto, Compose patterns | Building for Android |
53
+ | **Cross-Platform** | Both above | Platform divergence points | React Native / Flutter |
54
+
55
+ > 🔴 **If building for iOS → Read platform-ios.md FIRST!**
56
+ > 🔴 **If building for Android → Read platform-android.md FIRST!**
57
+ > 🔴 **If cross-platform → Read BOTH and apply conditional platform logic!**
58
+
59
+ ---
60
+
61
+ ## ⚠️ CRITICAL: ASK BEFORE ASSUMING (MANDATORY)
62
+
63
+ > **STOP! If the user's request is open-ended, DO NOT default to your favorites.**
64
+
65
+ ### You MUST Ask If Not Specified:
66
+
67
+ | Aspect | Ask | Why |
68
+ |--------|-----|-----|
69
+ | **Platform** | "iOS, Android, or both?" | Affects EVERY design decision |
70
+ | **Framework** | "React Native, Flutter, or native?" | Determines patterns and tools |
71
+ | **Navigation** | "Tab bar, drawer, or stack-based?" | Core UX decision |
72
+ | **State** | "What state management? (Zustand/Redux/Riverpod/BLoC?)" | Architecture foundation |
73
+ | **Offline** | "Does this need to work offline?" | Affects data strategy |
74
+ | **Target devices** | "Phone only, or tablet support?" | Layout complexity |
75
+
76
+ ### ⛔ AI MOBILE ANTI-PATTERNS (BANNED LIST)
77
+
78
+ > 🚫 **These are AI default tendencies that MUST be avoided!**
79
+
80
+ #### Performance Sins
81
+
82
+ | ❌ NEVER DO | Why It's Wrong | ✅ ALWAYS DO |
83
+ |-------------|----------------|--------------|
84
+ | **ScrollView for long lists** | Renders ALL items, memory explodes | Use `FlatList` / `FlashList` / `ListView.builder` |
85
+ | **Inline renderItem function** | New function every render, all items re-render | `useCallback` + `React.memo` |
86
+ | **Missing keyExtractor** | Index-based keys cause bugs on reorder | Unique, stable ID from data |
87
+ | **Skip getItemLayout** | Async layout = janky scroll | Provide when items have fixed height |
88
+ | **setState() everywhere** | Unnecessary widget rebuilds | Targeted state, `const` constructors |
89
+ | **Native driver: false** | Animations blocked by JS thread | `useNativeDriver: true` always |
90
+ | **console.log in production** | Blocks JS thread severely | Remove before release build |
91
+ | **Skip React.memo/const** | Every item re-renders on any change | Memoize list items ALWAYS |
92
+
93
+ #### Touch/UX Sins
94
+
95
+ | ❌ NEVER DO | Why It's Wrong | ✅ ALWAYS DO |
96
+ |-------------|----------------|--------------|
97
+ | **Touch target < 44px** | Impossible to tap accurately, frustrating | Minimum 44pt (iOS) / 48dp (Android) |
98
+ | **Spacing < 8px between targets** | Accidental taps on neighbors | Minimum 8-12px gap |
99
+ | **Gesture-only interactions** | Motor impaired users excluded | Always provide button alternative |
100
+ | **No loading state** | User thinks app crashed | ALWAYS show loading feedback |
101
+ | **No error state** | User stuck, no recovery path | Show error with retry option |
102
+ | **No offline handling** | Crash/block when network lost | Graceful degradation, cached data |
103
+ | **Ignore platform conventions** | Users confused, muscle memory broken | iOS feels iOS, Android feels Android |
104
+
105
+ #### Security Sins
106
+
107
+ | ❌ NEVER DO | Why It's Wrong | ✅ ALWAYS DO |
108
+ |-------------|----------------|--------------|
109
+ | **Token in AsyncStorage** | Easily accessible, stolen on rooted device | `SecureStore` / `Keychain` / `EncryptedSharedPreferences` |
110
+ | **Hardcode API keys** | Reverse engineered from APK/IPA | Environment variables, secure storage |
111
+ | **Skip SSL pinning** | MITM attacks possible | Pin certificates in production |
112
+ | **Log sensitive data** | Logs can be extracted | Never log tokens, passwords, PII |
113
+
114
+ #### Architecture Sins
115
+
116
+ | ❌ NEVER DO | Why It's Wrong | ✅ ALWAYS DO |
117
+ |-------------|----------------|--------------|
118
+ | **Business logic in UI** | Untestable, unmaintainable | Service layer separation |
119
+ | **Global state for everything** | Unnecessary re-renders, complexity | Local state default, lift when needed |
120
+ | **Deep linking as afterthought** | Notifications, shares broken | Plan deep links from day one |
121
+ | **Skip dispose/cleanup** | Memory leaks, zombie listeners | Clean up subscriptions, timers |
122
+
123
+ ---
124
+
125
+ ## 📱 Platform Decision Matrix
126
+
127
+ ### When to Unify vs Diverge
128
+
129
+ ```
130
+ UNIFY (same on both) DIVERGE (platform-specific)
131
+ ─────────────────── ──────────────────────────
132
+ Business Logic ✅ Always -
133
+ Data Layer ✅ Always -
134
+ Core Features ✅ Always -
135
+
136
+ Navigation - ✅ iOS: edge swipe, Android: back button
137
+ Gestures - ✅ Platform-native feel
138
+ Icons - ✅ SF Symbols vs Material Icons
139
+ Date Pickers - ✅ Native pickers feel right
140
+ Modals/Sheets - ✅ iOS: bottom sheet vs Android: dialog
141
+ Typography - ✅ SF Pro vs Roboto (or custom)
142
+ Error Dialogs - ✅ Platform conventions for alerts
143
+ ```
144
+
145
+ ### Quick Reference: Platform Defaults
146
+
147
+ | Element | iOS | Android |
148
+ |---------|-----|---------|
149
+ | **Primary Font** | SF Pro / SF Compact | Roboto |
150
+ | **Min Touch Target** | 44pt × 44pt | 48dp × 48dp |
151
+ | **Back Navigation** | Edge swipe left | System back button/gesture |
152
+ | **Bottom Tab Icons** | SF Symbols | Material Symbols |
153
+ | **Action Sheet** | UIActionSheet from bottom | Bottom Sheet / Dialog |
154
+ | **Progress** | Spinner | Linear progress (Material) |
155
+ | **Pull to Refresh** | Native UIRefreshControl | SwipeRefreshLayout |
156
+
157
+ ---
158
+
159
+ ## 🧠 Mobile UX Psychology (Quick Reference)
160
+
161
+ ### Fitts' Law for Touch
162
+
163
+ ```
164
+ Desktop: Cursor is precise (1px)
165
+ Mobile: Finger is imprecise (~7mm contact area)
166
+
167
+ → Touch targets MUST be 44-48px minimum
168
+ → Important actions in THUMB ZONE (bottom of screen)
169
+ → Destructive actions AWAY from easy reach
170
+ ```
171
+
172
+ ### Thumb Zone (One-Handed Usage)
173
+
174
+ ```
175
+ ┌─────────────────────────────┐
176
+ │ HARD TO REACH │ ← Navigation, menu, back
177
+ │ (stretch) │
178
+ ├─────────────────────────────┤
179
+ │ OK TO REACH │ ← Secondary actions
180
+ │ (natural) │
181
+ ├─────────────────────────────┤
182
+ │ EASY TO REACH │ ← PRIMARY CTAs, tab bar
183
+ │ (thumb's natural arc) │ ← Main content interaction
184
+ └─────────────────────────────┘
185
+ [ HOME ]
186
+ ```
187
+
188
+ ### Mobile-Specific Cognitive Load
189
+
190
+ | Desktop | Mobile Difference |
191
+ |---------|-------------------|
192
+ | Multiple windows | ONE task at a time |
193
+ | Keyboard shortcuts | Touch gestures |
194
+ | Hover states | NO hover (tap or nothing) |
195
+ | Large viewport | Limited space, scroll vertical |
196
+ | Stable attention | Interrupted constantly |
197
+
198
+ For deep dive: [touch-psychology.md](touch-psychology.md)
199
+
200
+ ---
201
+
202
+ ## ⚡ Performance Principles (Quick Reference)
203
+
204
+ ### React Native Critical Rules
205
+
206
+ ```typescript
207
+ // ✅ CORRECT: Memoized renderItem + React.memo wrapper
208
+ const ListItem = React.memo(({ item }: { item: Item }) => (
209
+ <View style={styles.item}>
210
+ <Text>{item.title}</Text>
211
+ </View>
212
+ ));
213
+
214
+ const renderItem = useCallback(
215
+ ({ item }: { item: Item }) => <ListItem item={item} />,
216
+ []
217
+ );
218
+
219
+ // ✅ CORRECT: FlatList with all optimizations
220
+ <FlatList
221
+ data={items}
222
+ renderItem={renderItem}
223
+ keyExtractor={(item) => item.id} // Stable ID, NOT index
224
+ getItemLayout={(data, index) => ({
225
+ length: ITEM_HEIGHT,
226
+ offset: ITEM_HEIGHT * index,
227
+ index,
228
+ })}
229
+ removeClippedSubviews={true}
230
+ maxToRenderPerBatch={10}
231
+ windowSize={5}
232
+ />
233
+ ```
234
+
235
+ ### Flutter Critical Rules
236
+
237
+ ```dart
238
+ // ✅ CORRECT: const constructors prevent rebuilds
239
+ class MyWidget extends StatelessWidget {
240
+ const MyWidget({super.key}); // CONST!
241
+
242
+ @override
243
+ Widget build(BuildContext context) {
244
+ return const Column( // CONST!
245
+ children: [
246
+ Text('Static content'),
247
+ MyConstantWidget(),
248
+ ],
249
+ );
250
+ }
251
+ }
252
+
253
+ // ✅ CORRECT: Targeted state with ValueListenableBuilder
254
+ ValueListenableBuilder<int>(
255
+ valueListenable: counter,
256
+ builder: (context, value, child) => Text('$value'),
257
+ child: const ExpensiveWidget(), // Won't rebuild!
258
+ )
259
+ ```
260
+
261
+ ### Animation Performance
262
+
263
+ ```
264
+ GPU-accelerated (FAST): CPU-bound (SLOW):
265
+ ├── transform ├── width, height
266
+ ├── opacity ├── top, left, right, bottom
267
+ └── (use these ONLY) ├── margin, padding
268
+ └── (AVOID animating these)
269
+ ```
270
+
271
+ For complete guide: [mobile-performance.md](mobile-performance.md)
272
+
273
+ ---
274
+
275
+ ## 📝 CHECKPOINT (MANDATORY Before Any Mobile Work)
276
+
277
+ > **Before writing ANY mobile code, you MUST complete this checkpoint:**
278
+
279
+ ```
280
+ 🧠 CHECKPOINT:
281
+
282
+ Platform: [ iOS / Android / Both ]
283
+ Framework: [ React Native / Flutter / SwiftUI / Kotlin ]
284
+ Files Read: [ List the skill files you've read ]
285
+
286
+ 3 Principles I Will Apply:
287
+ 1. _______________
288
+ 2. _______________
289
+ 3. _______________
290
+
291
+ Anti-Patterns I Will Avoid:
292
+ 1. _______________
293
+ 2. _______________
294
+ ```
295
+
296
+ **Example:**
297
+ ```
298
+ 🧠 CHECKPOINT:
299
+
300
+ Platform: iOS + Android (Cross-platform)
301
+ Framework: React Native + Expo
302
+ Files Read: touch-psychology.md, mobile-performance.md, platform-ios.md, platform-android.md
303
+
304
+ 3 Principles I Will Apply:
305
+ 1. FlatList with React.memo + useCallback for all lists
306
+ 2. 48px touch targets, thumb zone for primary CTAs
307
+ 3. Platform-specific navigation (edge swipe iOS, back button Android)
308
+
309
+ Anti-Patterns I Will Avoid:
310
+ 1. ScrollView for lists → FlatList
311
+ 2. Inline renderItem → Memoized
312
+ 3. AsyncStorage for tokens → SecureStore
313
+ ```
314
+
315
+ > 🔴 **Can't fill the checkpoint? → GO BACK AND READ THE SKILL FILES.**
316
+
317
+ ---
318
+
319
+ ## 🔧 Framework Decision Tree
320
+
321
+ ```
322
+ WHAT ARE YOU BUILDING?
323
+
324
+ ├── Need OTA updates + rapid iteration + web team
325
+ │ └── ✅ React Native + Expo
326
+
327
+ ├── Need pixel-perfect custom UI + performance critical
328
+ │ └── ✅ Flutter
329
+
330
+ ├── Deep native features + single platform focus
331
+ │ ├── iOS only → SwiftUI
332
+ │ └── Android only → Kotlin + Jetpack Compose
333
+
334
+ ├── Existing RN codebase + new features
335
+ │ └── ✅ React Native (bare workflow)
336
+
337
+ └── Enterprise + existing Flutter codebase
338
+ └── ✅ Flutter
339
+ ```
340
+
341
+ For complete decision trees: [decision-trees.md](decision-trees.md)
342
+
343
+ ---
344
+
345
+ ## 📋 Pre-Development Checklist
346
+
347
+ ### Before Starting ANY Mobile Project
348
+
349
+ - [ ] **Platform confirmed?** (iOS / Android / Both)
350
+ - [ ] **Framework chosen?** (RN / Flutter / Native)
351
+ - [ ] **Navigation pattern decided?** (Tabs / Stack / Drawer)
352
+ - [ ] **State management selected?** (Zustand / Redux / Riverpod / BLoC)
353
+ - [ ] **Offline requirements known?**
354
+ - [ ] **Deep linking planned from day one?**
355
+ - [ ] **Target devices defined?** (Phone / Tablet / Both)
356
+
357
+ ### Before Every Screen
358
+
359
+ - [ ] **Touch targets ≥ 44-48px?**
360
+ - [ ] **Primary CTA in thumb zone?**
361
+ - [ ] **Loading state exists?**
362
+ - [ ] **Error state with retry exists?**
363
+ - [ ] **Offline handling considered?**
364
+ - [ ] **Platform conventions followed?**
365
+
366
+ ### Before Release
367
+
368
+ - [ ] **console.log removed?**
369
+ - [ ] **SecureStore for sensitive data?**
370
+ - [ ] **SSL pinning enabled?**
371
+ - [ ] **Lists optimized (memo, keyExtractor)?**
372
+ - [ ] **Memory cleanup on unmount?**
373
+ - [ ] **Tested on low-end devices?**
374
+ - [ ] **Accessibility labels on all interactive elements?**
375
+
376
+ ---
377
+
378
+ ## 📚 Reference Files
379
+
380
+ For deeper guidance on specific areas:
381
+
382
+ | File | When to Use |
383
+ |------|-------------|
384
+ | [mobile-design-thinking.md](mobile-design-thinking.md) | **FIRST! Anti-memorization, forces context-based thinking** |
385
+ | [touch-psychology.md](touch-psychology.md) | Understanding touch interaction, Fitts' Law, gesture design |
386
+ | [mobile-performance.md](mobile-performance.md) | Optimizing RN/Flutter, 60fps, memory/battery |
387
+ | [platform-ios.md](platform-ios.md) | iOS-specific design, HIG compliance |
388
+ | [platform-android.md](platform-android.md) | Android-specific design, Material Design 3 |
389
+ | [mobile-navigation.md](mobile-navigation.md) | Navigation patterns, deep linking |
390
+ | [mobile-typography.md](mobile-typography.md) | Type scale, system fonts, accessibility |
391
+ | [mobile-color-system.md](mobile-color-system.md) | OLED optimization, dark mode, battery |
392
+ | [decision-trees.md](decision-trees.md) | Framework, state, storage decisions |
393
+
394
+ ---
395
+
396
+ > **Remember:** Mobile users are impatient, interrupted, and using imprecise fingers on small screens. Design for the WORST conditions: bad network, one hand, bright sun, low battery. If it works there, it works everywhere.