@fprad0/skill-master-mcp 0.0.9 → 0.0.10

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 (195) hide show
  1. package/CHANGELOG.md +11 -0
  2. package/README.md +16 -2
  3. package/VERSION.md +3 -3
  4. package/bin/lib/menu-core.mjs +651 -16
  5. package/bin/skill-master-bootstrap-global.mjs +14 -1
  6. package/bin/skill-master-doctor.mjs +168 -0
  7. package/bin/skill-master-install-global-skills.mjs +30 -10
  8. package/bin/skill-master-menu.mjs +184 -36
  9. package/bin/skill-master-register-clients.mjs +26 -3
  10. package/dist/index.js +30 -5
  11. package/dist/index.js.map +1 -1
  12. package/docs/skill-candidates/v0.0.10/cli-creator/LICENSE.txt +201 -0
  13. package/docs/skill-candidates/v0.0.10/cli-creator/SKILL.md +160 -0
  14. package/docs/skill-candidates/v0.0.10/cli-creator/agents/openai.yaml +4 -0
  15. package/docs/skill-candidates/v0.0.10/cli-creator/references/agent-cli-patterns.md +154 -0
  16. package/docs/skill-candidates/v0.0.10/developer-workstation-ops/SKILL.md +32 -0
  17. package/docs/skill-candidates/v0.0.10/figma/LICENSE.txt +2 -0
  18. package/docs/skill-candidates/v0.0.10/figma/SKILL.md +42 -0
  19. package/docs/skill-candidates/v0.0.10/figma/agents/openai.yaml +14 -0
  20. package/docs/skill-candidates/v0.0.10/figma/assets/figma-small.svg +3 -0
  21. package/docs/skill-candidates/v0.0.10/figma/assets/figma.png +0 -0
  22. package/docs/skill-candidates/v0.0.10/figma/assets/icon.svg +28 -0
  23. package/docs/skill-candidates/v0.0.10/figma/references/figma-mcp-config.md +35 -0
  24. package/docs/skill-candidates/v0.0.10/figma/references/figma-tools-and-prompts.md +34 -0
  25. package/docs/skill-candidates/v0.0.10/figma-code-connect-components/LICENSE.TXT +2 -0
  26. package/docs/skill-candidates/v0.0.10/figma-code-connect-components/SKILL.md +349 -0
  27. package/docs/skill-candidates/v0.0.10/figma-code-connect-components/agents/openai.yaml +14 -0
  28. package/docs/skill-candidates/v0.0.10/figma-code-connect-components/assets/figma-small.svg +3 -0
  29. package/docs/skill-candidates/v0.0.10/figma-code-connect-components/assets/figma.png +0 -0
  30. package/docs/skill-candidates/v0.0.10/figma-code-connect-components/assets/icon.svg +28 -0
  31. package/docs/skill-candidates/v0.0.10/figma-code-connect-components/references/mapping-checklist.md +7 -0
  32. package/docs/skill-candidates/v0.0.10/figma-code-connect-components/scripts/normalize_node_id.py +25 -0
  33. package/docs/skill-candidates/v0.0.10/figma-create-design-system-rules/LICENSE.TXT +2 -0
  34. package/docs/skill-candidates/v0.0.10/figma-create-design-system-rules/SKILL.md +537 -0
  35. package/docs/skill-candidates/v0.0.10/figma-create-design-system-rules/agents/openai.yaml +14 -0
  36. package/docs/skill-candidates/v0.0.10/figma-create-design-system-rules/assets/figma-small.svg +3 -0
  37. package/docs/skill-candidates/v0.0.10/figma-create-design-system-rules/assets/figma.png +0 -0
  38. package/docs/skill-candidates/v0.0.10/figma-create-design-system-rules/assets/icon.svg +28 -0
  39. package/docs/skill-candidates/v0.0.10/figma-create-design-system-rules/references/rule-template.md +15 -0
  40. package/docs/skill-candidates/v0.0.10/figma-create-design-system-rules/scripts/check_agents_md.sh +9 -0
  41. package/docs/skill-candidates/v0.0.10/figma-generate-design/LICENSE.TXT +2 -0
  42. package/docs/skill-candidates/v0.0.10/figma-generate-design/SKILL.md +341 -0
  43. package/docs/skill-candidates/v0.0.10/figma-generate-design/agents/openai.yaml +14 -0
  44. package/docs/skill-candidates/v0.0.10/figma-generate-design/assets/figma-small.svg +3 -0
  45. package/docs/skill-candidates/v0.0.10/figma-generate-design/assets/figma.png +0 -0
  46. package/docs/skill-candidates/v0.0.10/figma-generate-design/assets/icon.svg +28 -0
  47. package/docs/skill-candidates/v0.0.10/figma-generate-design/maintainers.yml +1 -0
  48. package/docs/skill-candidates/v0.0.10/figma-generate-library/LICENSE.TXT +2 -0
  49. package/docs/skill-candidates/v0.0.10/figma-generate-library/SKILL.md +314 -0
  50. package/docs/skill-candidates/v0.0.10/figma-generate-library/agents/openai.yaml +14 -0
  51. package/docs/skill-candidates/v0.0.10/figma-generate-library/assets/figma-small.svg +3 -0
  52. package/docs/skill-candidates/v0.0.10/figma-generate-library/assets/figma.png +0 -0
  53. package/docs/skill-candidates/v0.0.10/figma-generate-library/assets/icon.svg +28 -0
  54. package/docs/skill-candidates/v0.0.10/figma-generate-library/maintainers.yml +3 -0
  55. package/docs/skill-candidates/v0.0.10/figma-generate-library/references/code-connect-setup.md +260 -0
  56. package/docs/skill-candidates/v0.0.10/figma-generate-library/references/component-creation.md +1014 -0
  57. package/docs/skill-candidates/v0.0.10/figma-generate-library/references/discovery-phase.md +518 -0
  58. package/docs/skill-candidates/v0.0.10/figma-generate-library/references/documentation-creation.md +834 -0
  59. package/docs/skill-candidates/v0.0.10/figma-generate-library/references/error-recovery.md +540 -0
  60. package/docs/skill-candidates/v0.0.10/figma-generate-library/references/naming-conventions.md +527 -0
  61. package/docs/skill-candidates/v0.0.10/figma-generate-library/references/token-creation.md +962 -0
  62. package/docs/skill-candidates/v0.0.10/figma-generate-library/scripts/bindVariablesToComponent.js +110 -0
  63. package/docs/skill-candidates/v0.0.10/figma-generate-library/scripts/cleanupOrphans.js +127 -0
  64. package/docs/skill-candidates/v0.0.10/figma-generate-library/scripts/createComponentWithVariants.js +148 -0
  65. package/docs/skill-candidates/v0.0.10/figma-generate-library/scripts/createDocumentationPage.js +139 -0
  66. package/docs/skill-candidates/v0.0.10/figma-generate-library/scripts/createSemanticTokens.js +108 -0
  67. package/docs/skill-candidates/v0.0.10/figma-generate-library/scripts/createVariableCollection.js +49 -0
  68. package/docs/skill-candidates/v0.0.10/figma-generate-library/scripts/inspectFileStructure.js +121 -0
  69. package/docs/skill-candidates/v0.0.10/figma-generate-library/scripts/rehydrateState.js +92 -0
  70. package/docs/skill-candidates/v0.0.10/figma-generate-library/scripts/validateCreation.js +83 -0
  71. package/docs/skill-candidates/v0.0.10/figma-implement-design/LICENSE.txt +2 -0
  72. package/docs/skill-candidates/v0.0.10/figma-implement-design/SKILL.md +258 -0
  73. package/docs/skill-candidates/v0.0.10/figma-implement-design/agents/openai.yaml +14 -0
  74. package/docs/skill-candidates/v0.0.10/figma-implement-design/assets/figma-small.svg +3 -0
  75. package/docs/skill-candidates/v0.0.10/figma-implement-design/assets/figma.png +0 -0
  76. package/docs/skill-candidates/v0.0.10/figma-implement-design/assets/icon.svg +28 -0
  77. package/docs/skill-candidates/v0.0.10/figma-use/LICENSE.TXT +2 -0
  78. package/docs/skill-candidates/v0.0.10/figma-use/SKILL.md +233 -0
  79. package/docs/skill-candidates/v0.0.10/figma-use/agents/openai.yaml +14 -0
  80. package/docs/skill-candidates/v0.0.10/figma-use/assets/figma-small.svg +3 -0
  81. package/docs/skill-candidates/v0.0.10/figma-use/assets/figma.png +0 -0
  82. package/docs/skill-candidates/v0.0.10/figma-use/assets/icon.svg +28 -0
  83. package/docs/skill-candidates/v0.0.10/figma-use/maintainers.yml +1 -0
  84. package/docs/skill-candidates/v0.0.10/figma-use/references/api-reference.md +301 -0
  85. package/docs/skill-candidates/v0.0.10/figma-use/references/common-patterns.md +512 -0
  86. package/docs/skill-candidates/v0.0.10/figma-use/references/component-patterns.md +488 -0
  87. package/docs/skill-candidates/v0.0.10/figma-use/references/effect-style-patterns.md +123 -0
  88. package/docs/skill-candidates/v0.0.10/figma-use/references/gotchas.md +599 -0
  89. package/docs/skill-candidates/v0.0.10/figma-use/references/maintainers.yml +12 -0
  90. package/docs/skill-candidates/v0.0.10/figma-use/references/plugin-api-patterns.md +513 -0
  91. package/docs/skill-candidates/v0.0.10/figma-use/references/plugin-api-standalone.d.ts +11293 -0
  92. package/docs/skill-candidates/v0.0.10/figma-use/references/plugin-api-standalone.index.md +441 -0
  93. package/docs/skill-candidates/v0.0.10/figma-use/references/text-style-patterns.md +203 -0
  94. package/docs/skill-candidates/v0.0.10/figma-use/references/validation-and-recovery.md +109 -0
  95. package/docs/skill-candidates/v0.0.10/figma-use/references/variable-patterns.md +354 -0
  96. package/docs/skill-candidates/v0.0.10/figma-use/references/working-with-design-systems/maintainers.yml +9 -0
  97. package/docs/skill-candidates/v0.0.10/figma-use/references/working-with-design-systems/wwds-components--creating.md +17 -0
  98. package/docs/skill-candidates/v0.0.10/figma-use/references/working-with-design-systems/wwds-components--using.md +17 -0
  99. package/docs/skill-candidates/v0.0.10/figma-use/references/working-with-design-systems/wwds-components.md +50 -0
  100. package/docs/skill-candidates/v0.0.10/figma-use/references/working-with-design-systems/wwds-effect-styles.md +52 -0
  101. package/docs/skill-candidates/v0.0.10/figma-use/references/working-with-design-systems/wwds-text-styles.md +90 -0
  102. package/docs/skill-candidates/v0.0.10/figma-use/references/working-with-design-systems/wwds-variables--creating.md +13 -0
  103. package/docs/skill-candidates/v0.0.10/figma-use/references/working-with-design-systems/wwds-variables--using.md +13 -0
  104. package/docs/skill-candidates/v0.0.10/figma-use/references/working-with-design-systems/wwds-variables.md +64 -0
  105. package/docs/skill-candidates/v0.0.10/figma-use/references/working-with-design-systems/wwds.md +41 -0
  106. package/docs/skill-candidates/v0.0.10/frontend-design/LICENSE.txt +177 -0
  107. package/docs/skill-candidates/v0.0.10/frontend-design/SKILL.md +55 -0
  108. package/docs/skill-candidates/v0.0.10/frontend-ui-ux-systems/SKILL.md +32 -0
  109. package/docs/skill-candidates/v0.0.10/github/SKILL.md +74 -0
  110. package/docs/skill-candidates/v0.0.10/github/agents/openai.yaml +6 -0
  111. package/docs/skill-candidates/v0.0.10/github/assets/github-small.svg +3 -0
  112. package/docs/skill-candidates/v0.0.10/github/assets/github.png +0 -0
  113. package/docs/skill-candidates/v0.0.10/image-graphic-design-rendering/SKILL.md +28 -0
  114. package/docs/skill-candidates/v0.0.10/language-quality-pt-en-fr-it-ru/SKILL.md +28 -0
  115. package/docs/skill-candidates/v0.0.10/math-physics-reasoning/SKILL.md +28 -0
  116. package/docs/skill-candidates/v0.0.10/mcp-builder/LICENSE.txt +202 -0
  117. package/docs/skill-candidates/v0.0.10/mcp-builder/SKILL.md +236 -0
  118. package/docs/skill-candidates/v0.0.10/mcp-builder/reference/evaluation.md +602 -0
  119. package/docs/skill-candidates/v0.0.10/mcp-builder/reference/mcp_best_practices.md +249 -0
  120. package/docs/skill-candidates/v0.0.10/mcp-builder/reference/node_mcp_server.md +970 -0
  121. package/docs/skill-candidates/v0.0.10/mcp-builder/reference/python_mcp_server.md +719 -0
  122. package/docs/skill-candidates/v0.0.10/mcp-builder/scripts/connections.py +151 -0
  123. package/docs/skill-candidates/v0.0.10/mcp-builder/scripts/evaluation.py +373 -0
  124. package/docs/skill-candidates/v0.0.10/mcp-builder/scripts/example_evaluation.xml +22 -0
  125. package/docs/skill-candidates/v0.0.10/mcp-builder/scripts/requirements.txt +2 -0
  126. package/docs/skill-candidates/v0.0.10/mcp-client-readiness/SKILL.md +31 -0
  127. package/docs/skill-candidates/v0.0.10/openai-docs/LICENSE.txt +201 -0
  128. package/docs/skill-candidates/v0.0.10/openai-docs/SKILL.md +161 -0
  129. package/docs/skill-candidates/v0.0.10/openai-docs/agents/openai.yaml +14 -0
  130. package/docs/skill-candidates/v0.0.10/openai-docs/assets/openai-small.svg +3 -0
  131. package/docs/skill-candidates/v0.0.10/openai-docs/assets/openai.png +0 -0
  132. package/docs/skill-candidates/v0.0.10/openai-docs/references/latest-model.md +37 -0
  133. package/docs/skill-candidates/v0.0.10/openai-docs/references/prompting-guide.md +244 -0
  134. package/docs/skill-candidates/v0.0.10/openai-docs/references/upgrade-guide.md +181 -0
  135. package/docs/skill-candidates/v0.0.10/openai-docs/scripts/fetch-codex-manual.mjs +598 -0
  136. package/docs/skill-candidates/v0.0.10/openai-docs/scripts/resolve-latest-model-info.js +147 -0
  137. package/docs/skill-candidates/v0.0.10/playwright/LICENSE.txt +201 -0
  138. package/docs/skill-candidates/v0.0.10/playwright/NOTICE.txt +14 -0
  139. package/docs/skill-candidates/v0.0.10/playwright/SKILL.md +147 -0
  140. package/docs/skill-candidates/v0.0.10/playwright/agents/openai.yaml +6 -0
  141. package/docs/skill-candidates/v0.0.10/playwright/assets/playwright-small.svg +3 -0
  142. package/docs/skill-candidates/v0.0.10/playwright/assets/playwright.png +0 -0
  143. package/docs/skill-candidates/v0.0.10/playwright/references/cli.md +116 -0
  144. package/docs/skill-candidates/v0.0.10/playwright/references/workflows.md +95 -0
  145. package/docs/skill-candidates/v0.0.10/playwright/scripts/playwright_cli.sh +25 -0
  146. package/docs/skill-candidates/v0.0.10/polyglot-backend-engineering/SKILL.md +32 -0
  147. package/docs/skill-candidates/v0.0.10/screenshot/LICENSE.txt +201 -0
  148. package/docs/skill-candidates/v0.0.10/screenshot/SKILL.md +267 -0
  149. package/docs/skill-candidates/v0.0.10/screenshot/agents/openai.yaml +6 -0
  150. package/docs/skill-candidates/v0.0.10/screenshot/assets/screenshot-small.svg +5 -0
  151. package/docs/skill-candidates/v0.0.10/screenshot/assets/screenshot.png +0 -0
  152. package/docs/skill-candidates/v0.0.10/screenshot/scripts/ensure_macos_permissions.sh +54 -0
  153. package/docs/skill-candidates/v0.0.10/screenshot/scripts/macos_display_info.swift +22 -0
  154. package/docs/skill-candidates/v0.0.10/screenshot/scripts/macos_permissions.swift +40 -0
  155. package/docs/skill-candidates/v0.0.10/screenshot/scripts/macos_window_info.swift +126 -0
  156. package/docs/skill-candidates/v0.0.10/screenshot/scripts/take_screenshot.ps1 +163 -0
  157. package/docs/skill-candidates/v0.0.10/screenshot/scripts/take_screenshot.py +585 -0
  158. package/docs/skill-candidates/v0.0.10/skill-master-orchestrator/SKILL.md +62 -0
  159. package/docs/skill-candidates/v0.0.10/skill-master-orchestrator/agents/openai.yaml +4 -0
  160. package/docs/skill-candidates/v0.0.10/skill-master-orchestrator/references/activation-policy.md +77 -0
  161. package/docs/skill-candidates/v0.0.10/skill-master-orchestrator/references/human-approval-policy.md +83 -0
  162. package/docs/skill-candidates/v0.0.10/skill-master-orchestrator/references/persona-dev-senior-master.md +46 -0
  163. package/docs/skill-candidates/v0.0.10/terminal-menu-operations/SKILL.md +30 -0
  164. package/docs/skill-candidates/v0.0.10/terminal-pixel-art-tui/SKILL.md +43 -0
  165. package/docs/skill-candidates/v0.0.10/webapp-testing/LICENSE.txt +202 -0
  166. package/docs/skill-candidates/v0.0.10/webapp-testing/SKILL.md +96 -0
  167. package/docs/skill-candidates/v0.0.10/webapp-testing/examples/console_logging.py +35 -0
  168. package/docs/skill-candidates/v0.0.10/webapp-testing/examples/element_discovery.py +40 -0
  169. package/docs/skill-candidates/v0.0.10/webapp-testing/examples/static_html_automation.py +33 -0
  170. package/docs/skill-candidates/v0.0.10/webapp-testing/scripts/with_server.py +106 -0
  171. package/docs/skill-candidates/v0.0.10/winui-app/LICENSE.txt +202 -0
  172. package/docs/skill-candidates/v0.0.10/winui-app/SKILL.md +94 -0
  173. package/docs/skill-candidates/v0.0.10/winui-app/agents/openai.yaml +5 -0
  174. package/docs/skill-candidates/v0.0.10/winui-app/assets/winui.png +0 -0
  175. package/docs/skill-candidates/v0.0.10/winui-app/config.yaml +50 -0
  176. package/docs/skill-candidates/v0.0.10/winui-app/references/_sections.md +96 -0
  177. package/docs/skill-candidates/v0.0.10/winui-app/references/accessibility-input-and-localization.md +51 -0
  178. package/docs/skill-candidates/v0.0.10/winui-app/references/build-run-and-launch-verification.md +72 -0
  179. package/docs/skill-candidates/v0.0.10/winui-app/references/community-toolkit-controls-and-helpers.md +57 -0
  180. package/docs/skill-candidates/v0.0.10/winui-app/references/controls-layout-and-adaptive-ui.md +84 -0
  181. package/docs/skill-candidates/v0.0.10/winui-app/references/foundation-environment-audit-and-remediation.md +82 -0
  182. package/docs/skill-candidates/v0.0.10/winui-app/references/foundation-setup-and-project-selection.md +67 -0
  183. package/docs/skill-candidates/v0.0.10/winui-app/references/foundation-template-first-recovery.md +62 -0
  184. package/docs/skill-candidates/v0.0.10/winui-app/references/foundation-winui-app-structure.md +62 -0
  185. package/docs/skill-candidates/v0.0.10/winui-app/references/motion-animations-and-polish.md +45 -0
  186. package/docs/skill-candidates/v0.0.10/winui-app/references/performance-diagnostics-and-responsiveness.md +46 -0
  187. package/docs/skill-candidates/v0.0.10/winui-app/references/sample-source-map.md +37 -0
  188. package/docs/skill-candidates/v0.0.10/winui-app/references/shell-navigation-and-windowing.md +67 -0
  189. package/docs/skill-candidates/v0.0.10/winui-app/references/styling-theming-materials-and-icons.md +71 -0
  190. package/docs/skill-candidates/v0.0.10/winui-app/references/testing-debugging-and-review-checklists.md +77 -0
  191. package/docs/skill-candidates/v0.0.10/winui-app/references/windows-app-sdk-lifecycle-notifications-and-deployment.md +52 -0
  192. package/manifests/channels/beta.json +7 -7
  193. package/manifests/channels/stable.json +8 -8
  194. package/network/unapproved-skill-candidates.json +34 -1
  195. package/package.json +2 -1
@@ -0,0 +1,527 @@
1
+ > Part of the [figma-generate-library skill](../SKILL.md).
2
+
3
+ # Naming Conventions Reference
4
+
5
+ This reference documents every naming convention used in the figma-generate-library workflow. Cover all naming decisions in order: variables, components, pages, variants, styles, separators, status indicators. The last section explains when to match an existing file's conventions vs. using the defaults here.
6
+
7
+ ---
8
+
9
+ ## 1. Variable Naming
10
+
11
+ ### Slash hierarchy (the universal pattern)
12
+
13
+ All Figma variables use slash-separated paths. The slash creates visual grouping in the Variables panel and maps directly to the token hierarchy in code.
14
+
15
+ ```
16
+ {category}/{subcategory}/{role}
17
+ ```
18
+
19
+ Real examples from Simple DS and Material 3:
20
+
21
+ ```
22
+ color/bg/primary
23
+ color/bg/secondary
24
+ color/text/primary
25
+ color/text/muted
26
+ color/border/default
27
+ color/border/focus
28
+ color/feedback/error
29
+ color/feedback/success
30
+ spacing/xs
31
+ spacing/sm
32
+ spacing/md
33
+ spacing/lg
34
+ spacing/xl
35
+ spacing/2xl
36
+ radius/none
37
+ radius/sm
38
+ radius/md
39
+ radius/lg
40
+ radius/full
41
+ typography/body/font-size
42
+ typography/body/line-height
43
+ typography/heading/font-size
44
+ typography/heading/font-weight
45
+ ```
46
+
47
+ ### Primitives collection
48
+
49
+ Primitive variables hold raw values and are **not** exposed to consumers (scope = `[]`). They use a flat `{family}/{step}` format matching the color scale convention from Simple DS:
50
+
51
+ ```
52
+ blue/50
53
+ blue/100
54
+ blue/200
55
+ ...
56
+ blue/900
57
+ gray/50
58
+ gray/100
59
+ ...
60
+ gray/900
61
+ red/500
62
+ green/500
63
+ ```
64
+
65
+ Step numbers follow the convention of the target codebase. If the codebase uses `100–900`, use that. If it uses `50–950`, use that. If there is no codebase convention, use `100–900` in increments of 100.
66
+
67
+ ### Semantic collection
68
+
69
+ Semantic variables alias primitives. They use the role-based `{category}/{role}` or `{category}/{subcategory}/{role}` pattern:
70
+
71
+ ```
72
+ color/bg/primary → alias: primitives/white (light), primitives/gray/900 (dark)
73
+ color/bg/secondary → alias: primitives/gray/100 (light), primitives/gray/800 (dark)
74
+ color/text/primary → alias: primitives/gray/900 (light), primitives/white (dark)
75
+ color/text/secondary → alias: primitives/gray/600 (light), primitives/gray/400 (dark)
76
+ color/border/default → alias: primitives/gray/200 (light), primitives/gray/700 (dark)
77
+ ```
78
+
79
+ **Rule:** Semantic variables must never hold raw hex values — they always alias a primitive. If you need a new color value, create the primitive first, then create the semantic alias.
80
+
81
+ ### Casing
82
+
83
+ **Default:** Use **lowercase** with forward slashes: `color/bg/primary`, `spacing/2xl`.
84
+
85
+ **When to deviate:**
86
+ - If the existing file uses PascalCase (e.g., Material 3 uses `Schemes/Primary`) — match it.
87
+ - If the design team prefers PascalCase for readability in the Variables panel — acceptable as long as the code syntax is separately defined and uses the platform-correct case.
88
+ - Mode names can use spaces and mixed case (e.g., `SDS Light`, `Mode 1 → Light`) — these are labels, not identifiers.
89
+
90
+ **Never:** camelCase inside variable names (`colorBgPrimary` as a Figma name is wrong — that belongs in Android code syntax only). Never use spaces inside a path segment: `color/bg primary` is wrong; `color/bg/primary` is correct.
91
+
92
+ **Key distinction:** The casing rule applies to *Figma variable names*. Code syntax names follow *platform conventions* regardless of the Figma name case — see §9 for the full picture.
93
+
94
+ ---
95
+
96
+ ## 2. Component Naming
97
+
98
+ ### Main components: PascalCase, no prefix
99
+
100
+ Published components intended for library consumers use plain PascalCase names:
101
+
102
+ ```
103
+ Button
104
+ Input
105
+ Checkbox
106
+ Toggle
107
+ Avatar
108
+ Badge
109
+ Card
110
+ Dialog
111
+ Tooltip
112
+ Banner
113
+ ```
114
+
115
+ Do not use a namespace prefix for public components (e.g., do not name them `DS/Button` or `sds-Button`). Slashes in component names create nested grouping in the Assets panel, which is correct for sub-components but not for top-level public components.
116
+
117
+ ### Sub-components: underscore prefix + slash namespace
118
+
119
+ Internal sub-components that are NOT meant for library consumers use the `_` prefix. This hides them from the Assets panel by default and signals to other designers that they should not be used directly.
120
+
121
+ ```
122
+ _Button/Slot (internal icon slot for Button)
123
+ _Input/Indicator (internal state indicator for Input)
124
+ _Badge/Dot (internal dot sub-component of Badge)
125
+ _Parts/Avatar.Status (UI3 pattern: _Parts/{ParentName}.{SubPart})
126
+ _Slider/Handle (UI3 pattern: _{ParentName}/{SubPart})
127
+ ```
128
+
129
+ Pattern rules:
130
+ - Use `_` prefix for ALL internal sub-components — no exceptions.
131
+ - Use slash namespacing to group sub-components under their parent: `_Button/IconSlot`.
132
+ - For sub-components shared by multiple parents, use `_Parts/{ComponentName}.{SubPart}`.
133
+
134
+ ### Private documentation components
135
+
136
+ Components used only for internal documentation (not for production use) use the `.` prefix:
137
+
138
+ ```
139
+ .ExampleCard
140
+ .GuidelineHeader
141
+ .DemoFrame
142
+ ```
143
+
144
+ This hides them from consumers while keeping them accessible on the canvas.
145
+
146
+ ---
147
+
148
+ ## 3. Page Naming
149
+
150
+ Five reference design systems use three distinct naming patterns. Choose one pattern and apply it consistently across all pages in the file.
151
+
152
+ ### Pattern 1: Plain names (Simple DS, Material 3, Polaris)
153
+
154
+ The most common pattern. Clean, readable, no decoration.
155
+
156
+ ```
157
+ Cover
158
+ ---
159
+ Foundations
160
+ Icons
161
+ ---
162
+ Accordion
163
+ Avatars
164
+ Buttons
165
+ Cards
166
+ Dialog
167
+ Inputs
168
+ Menu
169
+ ---
170
+ Utilities
171
+ Component Playground
172
+ ```
173
+
174
+ Use this pattern when starting from scratch or when the target file already uses this style.
175
+
176
+ ### Pattern 2: Emoji prefix + status (UI3 Library)
177
+
178
+ The most expressive pattern. The page name encodes asset type, design status, and code readiness.
179
+
180
+ Anatomy: `[Asset Type Emoji] [Optional FPL Label] [Status Circle] Component Name [Code Status Bracket]`
181
+
182
+ | Segment | Values |
183
+ |---------|--------|
184
+ | Asset type | Component pages use the C-flag emoji; pattern pages use the P-flag emoji |
185
+ | Design status | Green circle = Ready, Yellow circle = WIP, Red circle = Do not use |
186
+ | Code status | (none) = Ready in code, `[beta]` = Beta, `[future]` = Not yet built |
187
+
188
+ Examples:
189
+ ```
190
+ Overview
191
+ Status Key
192
+ ---
193
+ FPL COMPONENTS (go/fpl)
194
+ [C-flag] FPL [Green] Buttons
195
+ [C-flag] FPL [Green] Inputs
196
+ [C-flag] FPL [Yellow] Popovers [future]
197
+ ---
198
+ UI3 COMPONENTS
199
+ [C-flag] [Green] Comments
200
+ ---
201
+ PATTERNS
202
+ [P-flag] [Green] Editor / Layers
203
+ ---
204
+ [Book] Cover
205
+ [Headstone] Deprecated
206
+ ```
207
+
208
+ Use this pattern only when building a large, multi-team design system where lifecycle tracking is needed, or when the target file already uses it.
209
+
210
+ ### Pattern 3: Emoji prefix (Shop Minis)
211
+
212
+ A lighter version of the UI3 pattern without status circles.
213
+
214
+ ```
215
+ 📔 Cover
216
+ ℹ️ About
217
+ 🚀 Getting started
218
+ ——— THEME ———
219
+ Color
220
+ Typography
221
+ Spacing
222
+ ——— COMPONENTS ———
223
+ Button
224
+ Input
225
+ Card
226
+ ```
227
+
228
+ Use this pattern when the target file already uses emoji prefixes but does not need lifecycle tracking.
229
+
230
+ ### Universal rules (all patterns)
231
+
232
+ - **Cover** is always first.
233
+ - **Separator pages** come before and after each logical section.
234
+ - **Foundation/token pages** always come before component pages.
235
+ - **Utility and internal pages** always come last.
236
+ - Pick one convention and do not mix patterns within a file.
237
+
238
+ ---
239
+
240
+ ## 4. Variant Naming
241
+
242
+ ### Property=Value format
243
+
244
+ All component variant properties and their values use `Property=Value` format in the Figma component set:
245
+
246
+ ```
247
+ Size=Small, Style=Primary, State=Default
248
+ Size=Medium, Style=Secondary, State=Hover
249
+ Size=Large, Style=Ghost, State=Disabled
250
+ ```
251
+
252
+ Actual property names match code prop names where possible:
253
+
254
+ | Figma Property | Code Prop Equivalent |
255
+ |---------------|---------------------|
256
+ | `Size` | `size` |
257
+ | `Style` / `Variant` | `variant` |
258
+ | `State` | Typically controlled by `:hover`, `:focus`, `:disabled` in CSS, but `state` in some systems |
259
+ | `Type` | `type` |
260
+ | `Disabled` | `disabled` (boolean) |
261
+ | `Icon` | `icon` (boolean or instance swap) |
262
+
263
+ ### Property value casing
264
+
265
+ Property values use **Title Case** in Figma (to be readable in the Variants panel), mapping to lowercase in code:
266
+
267
+ | Figma value | Code value |
268
+ |-------------|-----------|
269
+ | `Small` | `"small"` / `"sm"` |
270
+ | `Medium` | `"medium"` / `"md"` |
271
+ | `Large` | `"large"` / `"lg"` |
272
+ | `Primary` | `"primary"` |
273
+ | `Disabled` | `disabled` (boolean prop) |
274
+ | `Default` | *(typically the absent/unset case)* |
275
+
276
+ ### Boolean properties
277
+
278
+ Boolean component properties in Figma use `true` / `false` as values (Figma's native boolean), not `Yes` / `No` or `On` / `Off`.
279
+
280
+ ---
281
+
282
+ ## 5. Style Naming (Text and Effect Styles)
283
+
284
+ ### Text styles: category/name
285
+
286
+ ```
287
+ Display/Large
288
+ Display/Medium
289
+ Display/Small
290
+ Heading/1
291
+ Heading/2
292
+ Heading/3
293
+ Body/Large
294
+ Body/Medium
295
+ Body/Small
296
+ Label/Large
297
+ Label/Small
298
+ Code/Inline
299
+ ```
300
+
301
+ The category segment maps to the typographic role. Use the same category names as the codebase's typography scale where possible.
302
+
303
+ ### Effect styles (shadows): category/name
304
+
305
+ ```
306
+ Shadow/None
307
+ Shadow/Subtle
308
+ Shadow/Medium
309
+ Shadow/Strong
310
+ Shadow/Overlay
311
+ Elevation/0
312
+ Elevation/1
313
+ Elevation/2
314
+ Elevation/3
315
+ Elevation/4
316
+ Elevation/5
317
+ ```
318
+
319
+ Use `Shadow/` for named semantic shadows. Use `Elevation/N` for Material Design-style numbered elevation levels.
320
+
321
+ ---
322
+
323
+ ## 6. Separator Pages
324
+
325
+ Separator pages are empty pages whose sole purpose is to create visual breaks in the Figma page panel. Two conventions:
326
+
327
+ | Convention | Example | Used by |
328
+ |------------|---------|---------|
329
+ | Three dashes | `---` | Simple DS, UI3, Polaris, Material 3 |
330
+ | Decorated text | `——— COMPONENTS ———` | Shop Minis |
331
+
332
+ The three-dash convention (`---`) is the most common and the default for new files. Use it unless the target file uses the decorated-text style.
333
+
334
+ **Where to place separators:**
335
+
336
+ ```
337
+ Cover
338
+ --- ← after cover
339
+ Foundations
340
+ Icons
341
+ --- ← before components
342
+ [component pages]
343
+ --- ← before utilities
344
+ Utilities
345
+ ```
346
+
347
+ ---
348
+
349
+ ## 7. Status Indicators (UI3 Emoji System)
350
+
351
+ The UI3 Library uses colored circle emojis in page names to communicate design readiness at a glance. This system is optional but powerful for large teams.
352
+
353
+ | Emoji | Meaning | When to use |
354
+ |-------|---------|-------------|
355
+ | Green circle | Ready / Approved | Design is stable, reviewed, and safe to use |
356
+ | Yellow circle | WIP / In Progress | Design is being actively worked on, may change |
357
+ | Red circle | Do not use | Not ready, do not reference; may be deprecated |
358
+
359
+ Code readiness is communicated via brackets appended to the component name:
360
+
361
+ | Bracket | Meaning |
362
+ |---------|---------|
363
+ | (none) | Component is implemented in code and stable |
364
+ | `[beta]` | Component is in code but not yet stable (~3 weeks from ready) |
365
+ | `[future]` | Not yet implemented in code |
366
+
367
+ **Documentation status (within component pages):**
368
+
369
+ If building a UI3-style system, each documentation frame gets a status banner with one of these labels:
370
+
371
+ - `APPROVED` — fully vetted
372
+ - `READY FOR REVIEW` — awaiting sign-off
373
+ - `WORK IN PROGRESS` — actively being designed
374
+ - `NEEDS UPDATE` — outdated, requires revision
375
+ - `DO NOT REFERENCE` — should not be used
376
+
377
+ This system is only recommended for large, multi-team systems where lifecycle tracking provides real value. For smaller systems, skip the emoji status indicators and use plain page names.
378
+
379
+ ---
380
+
381
+ ## 8. When to Match Existing vs. Use Defaults
382
+
383
+ **Always inspect before naming anything.** Run `get_metadata` or `inspectFileStructure` to discover existing conventions before creating any pages or variables.
384
+
385
+ ### Match the existing file when:
386
+
387
+ - The file already has pages with a consistent naming pattern (emoji prefixes, separator style, casing).
388
+ - The file already has variable collections with an established naming scheme.
389
+ - The file was started by a design team and carries intentional decisions.
390
+ - Any existing component names use a specific pattern (PascalCase, kebab-case, namespace prefixes).
391
+
392
+ ### Use the defaults from this document when:
393
+
394
+ - Starting a brand-new Figma file with no existing content.
395
+ - The existing conventions are inconsistent (mix of styles = no convention to match).
396
+ - The user explicitly asks for a fresh design system following best practices.
397
+
398
+ ### When code and Figma disagree:
399
+
400
+ If the codebase uses `button-primary` but Figma has a component named `Button`, do not rename the Figma component. Instead:
401
+ - Keep the Figma name as `Button` (PascalCase, human-readable).
402
+ - Set variable code syntax to match the exact CSS token name from the codebase.
403
+ - Set Code Connect source path to the actual code file and use the exact code component name.
404
+
405
+ **The rule:** Figma names are for designers; code syntax and Code Connect source paths carry the exact code identifiers. These two identity systems operate in parallel.
406
+
407
+ ---
408
+
409
+ ## 9. Figma Variable Names vs Code Names — The Full Picture
410
+
411
+ This is one of the most misunderstood areas. Figma names and code names follow **different conventions on purpose** — they serve different audiences and live in different environments.
412
+
413
+ ### Why they differ
414
+
415
+ | | Figma variable name | Code syntax (WEB) |
416
+ |---|---|---|
417
+ | **Audience** | Designers in the Variables panel | Developers in CSS/Swift/Kotlin |
418
+ | **Separator** | `/` (slash) — creates visual grouping in Figma UI | `-` (hyphen) — required by CSS custom property syntax |
419
+ | **Case** | lowercase (or PascalCase for display — see below) | kebab-case for CSS; camelCase for JS/Android |
420
+ | **Depth** | 2–4 levels | Flat for CSS; dot-notation for JS |
421
+ | **Namespace** | Implicit (by collection) | Explicit prefix (`--p-`, `--md-`, `--cds-`) |
422
+
423
+ ### The transformation
424
+
425
+ ```
426
+ Figma variable name Code syntax (WEB)
427
+ ────────────────── ─────────────────
428
+ color/bg/primary → var(--color-bg-primary)
429
+ spacing/xs → var(--spacing-xs)
430
+ radius/md → var(--radius-md)
431
+ typography/body/font-size → var(--typography-body-font-size)
432
+
433
+ Pattern: replace "/" with "-", wrap in var(--)
434
+
435
+ **CRITICAL: The `var()` wrapper is REQUIRED for WEB code syntax.** Figma expects the full CSS function syntax — not just the property name. If you set `--color-bg-primary` (without `var()`), Dev Mode will show raw hex values instead of the variable reference. Always set `var(--color-bg-primary)`.
436
+ ```
437
+
438
+ ```
439
+ Figma variable name Code syntax (ANDROID)
440
+ ────────────────── ─────────────────────
441
+ color/bg/primary → colorBgPrimary
442
+ spacing/xs → spacingXs
443
+ radius/md → radiusMd
444
+
445
+ Pattern: replace "/" with "", capitalize each word after first
446
+ ```
447
+
448
+ ```
449
+ Figma variable name Code syntax (iOS)
450
+ ────────────────── ─────────────────
451
+ color/bg/primary → Color.bgPrimary
452
+ spacing/xs → Spacing.xs
453
+ radius/md → Radius.md
454
+
455
+ Pattern: first segment becomes class name, remainder becomes property (camelCase)
456
+ ```
457
+
458
+ ### Real-world examples from the 5 reference files
459
+
460
+ | File | Figma variable name | WEB code syntax | ANDROID code syntax |
461
+ |------|--------------------|-----------------|--------------------|
462
+ | Simple DS | `color/bg/primary` | `var(--color-bg-primary)` | `colorBgPrimary` |
463
+ | Simple DS | `spacing/sm` | `var(--spacing-sm)` | `spacingSm` |
464
+ | Material 3 | `Schemes/Primary` | `var(--md-sys-color-primary)` | `colorPrimary` |
465
+ | Material 3 | `Corner/Extra-small` | `var(--md-sys-shape-corner-extra-small)` | `shapeCornerExtraSmall` |
466
+ | Polaris | `color/bg/surface` | `var(--p-color-bg-surface)` | — |
467
+
468
+ **Key observation from Material 3:** The Figma name `Schemes/Primary` uses PascalCase with a space, but the WEB code syntax is `var(--md-sys-color-primary)` — entirely kebab-case with a vendor prefix `md-sys-`. The Figma name and the code syntax bear almost no resemblance. This is intentional and common in mature design systems.
469
+
470
+ ### Casing in Figma: lowercase is default, PascalCase is valid for display
471
+
472
+ The guideline to use lowercase is a default, not a universal rule. Evidence from real files:
473
+
474
+ | File | Figma case | Code output case | Why |
475
+ |------|-----------|------------------|-----|
476
+ | Simple DS | `color/bg/primary` (lowercase) | `var(--color-bg-primary)` | Direct mapping — simple |
477
+ | Material 3 | `Schemes/Primary` (PascalCase) | `var(--md-sys-color-primary)` | PascalCase reads better in Variables panel; code name is independently defined |
478
+ | Polaris | `color/bg/surface` (lowercase) | `var(--p-color-bg-surface)` | Direct mapping with vendor prefix |
479
+
480
+ **Rule:** Use lowercase when the Figma name will map directly to the CSS name. Use PascalCase (or match existing file) when the design system has human-readable variable names that are distinct from the technical code names.
481
+
482
+ ### When the codebase doesn't use CSS custom properties
483
+
484
+ Some JavaScript-first systems (Chakra, Ant Design, MUI) don't use CSS `var(--...)` at all. Their tokens live in JS theme objects:
485
+
486
+ ```
487
+ Chakra: colors.gray[500] → JS: theme.colors.gray[500]
488
+ Ant: colorPrimary → JS: token.colorPrimary
489
+ MUI: palette.primary.main → JS: theme.palette.primary.main
490
+ ```
491
+
492
+ In these cases, set WEB code syntax to the JS property path rather than a CSS variable:
493
+ ```javascript
494
+ // For a JS-object-based system like Chakra:
495
+ v.setVariableCodeSyntax('WEB', 'colors.gray.500');
496
+
497
+ // For Ant Design:
498
+ v.setVariableCodeSyntax('WEB', 'colorPrimary');
499
+ ```
500
+
501
+ ### Hierarchy depth: match the codebase
502
+
503
+ The number of slash levels should mirror the codebase's nesting depth:
504
+
505
+ | Codebase pattern | Figma depth | Example |
506
+ |-----------------|------------|---------|
507
+ | `--primary` (flat) | 1–2 levels | `color/primary` |
508
+ | `--color-bg-surface` (3-part) | 3 levels | `color/bg/surface` |
509
+ | `--md-sys-color-primary` (vendor + 3-part) | 3 levels (vendor prefix goes in code syntax only) | `color/primary` |
510
+ | `theme.palette.primary.main` (4-part) | 3–4 levels | `color/palette/primary/main` |
511
+
512
+ **Important:** Vendor prefixes (`--p-`, `--md-sys-`, `--cds-`) belong in the **code syntax**, not the Figma variable name. The Figma name `color/bg/surface` + code syntax `var(--p-color-bg-surface)` is the correct pattern.
513
+
514
+ ### Action at discovery time
515
+
516
+ During Phase 0 discovery, capture both sides of the mapping explicitly:
517
+
518
+ ```
519
+ For each token found in the codebase:
520
+ CSS variable: --sds-color-background-brand-default
521
+ Figma name: color/bg/brand/default (slash hierarchy, no vendor prefix)
522
+ WEB syntax: var(--sds-color-background-brand-default) (exact CSS name)
523
+ ANDROID syntax: sdsColorBackgroundBrandDefault (camelCase)
524
+ iOS syntax: Color.backgroundBrandDefault (dot-notation)
525
+ ```
526
+
527
+ Store this mapping in the state ledger. Use it when calling `setVariableCodeSyntax` in Phase 1. Never derive the code syntax from the Figma name if you have the original CSS variable name — always use the original.