@pega/sdk 0.0.5 → 0.0.7

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 (269) hide show
  1. package/README.md +10 -3
  2. package/dist/index.js +828 -165
  3. package/package.json +1 -1
  4. package/templates/react-native-sdk-reference/.claude/settings.json +5 -0
  5. package/templates/react-native-sdk-reference/.prettierignore +17 -0
  6. package/templates/react-native-sdk-reference/.vscode/extensions.json +1 -0
  7. package/templates/react-native-sdk-reference/.vscode/settings.json +7 -0
  8. package/templates/react-native-sdk-reference/AGENTS.md +3 -0
  9. package/templates/react-native-sdk-reference/CLAUDE.md +1 -0
  10. package/templates/react-native-sdk-reference/README.md +56 -0
  11. package/templates/react-native-sdk-reference/app.json +40 -5
  12. package/templates/react-native-sdk-reference/assets/expo.icon/Assets/expo-symbol 2.svg +3 -0
  13. package/templates/react-native-sdk-reference/assets/expo.icon/Assets/grid.png +0 -0
  14. package/templates/react-native-sdk-reference/assets/expo.icon/icon.json +35 -0
  15. package/templates/react-native-sdk-reference/assets/icons/bell.png +0 -0
  16. package/templates/react-native-sdk-reference/assets/icons/clock.png +0 -0
  17. package/templates/react-native-sdk-reference/assets/icons/cross.png +0 -0
  18. package/templates/react-native-sdk-reference/assets/icons/donut.png +0 -0
  19. package/templates/react-native-sdk-reference/assets/icons/gear.png +0 -0
  20. package/templates/react-native-sdk-reference/assets/icons/globe.png +0 -0
  21. package/templates/react-native-sdk-reference/assets/icons/internet.png +0 -0
  22. package/templates/react-native-sdk-reference/assets/icons/music.png +0 -0
  23. package/templates/react-native-sdk-reference/assets/icons/right-arrow.png +0 -0
  24. package/templates/react-native-sdk-reference/assets/icons/speed.png +0 -0
  25. package/templates/react-native-sdk-reference/assets/images/MediaCo.png +0 -0
  26. package/templates/react-native-sdk-reference/assets/images/adaptive-icon.png +0 -0
  27. package/templates/react-native-sdk-reference/assets/images/android-icon-background.png +0 -0
  28. package/templates/react-native-sdk-reference/assets/images/android-icon-foreground.png +0 -0
  29. package/templates/react-native-sdk-reference/assets/images/android-icon-monochrome.png +0 -0
  30. package/templates/react-native-sdk-reference/assets/images/expo-badge-white.png +0 -0
  31. package/templates/react-native-sdk-reference/assets/images/expo-badge.png +0 -0
  32. package/templates/react-native-sdk-reference/assets/images/expo-logo.png +0 -0
  33. package/templates/react-native-sdk-reference/assets/images/favicon.png +0 -0
  34. package/templates/react-native-sdk-reference/assets/images/icon.png +0 -0
  35. package/templates/react-native-sdk-reference/assets/images/logo-glow.png +0 -0
  36. package/templates/react-native-sdk-reference/assets/images/partial-react-logo.png +0 -0
  37. package/templates/react-native-sdk-reference/assets/images/react-logo.png +0 -0
  38. package/templates/react-native-sdk-reference/assets/images/react-logo@2x.png +0 -0
  39. package/templates/react-native-sdk-reference/assets/images/react-logo@3x.png +0 -0
  40. package/templates/react-native-sdk-reference/assets/images/splash-icon.png +0 -0
  41. package/templates/react-native-sdk-reference/assets/images/tutorial-web.png +0 -0
  42. package/templates/react-native-sdk-reference/eslint.config.mjs +68 -0
  43. package/templates/react-native-sdk-reference/package.json +59 -14
  44. package/templates/react-native-sdk-reference/pega-constellationjs-0.26.3.tgz +0 -0
  45. package/templates/react-native-sdk-reference/pega-sdk-react-0.1.0.tgz +0 -0
  46. package/templates/react-native-sdk-reference/pega-sdk-types-0.1.0.tgz +0 -0
  47. package/templates/react-native-sdk-reference/sdk-config.json +31 -9
  48. package/templates/react-native-sdk-reference/src/app/_layout.tsx +38 -0
  49. package/templates/react-native-sdk-reference/src/app/home/_layout.tsx +39 -0
  50. package/templates/react-native-sdk-reference/src/app/home/contact.tsx +11 -0
  51. package/templates/react-native-sdk-reference/src/app/home/index.tsx +36 -0
  52. package/templates/react-native-sdk-reference/src/app/home/shop.tsx +11 -0
  53. package/templates/react-native-sdk-reference/src/app/home/your-services.tsx +11 -0
  54. package/templates/react-native-sdk-reference/src/app/index.tsx +72 -0
  55. package/templates/react-native-sdk-reference/src/app/workarea.tsx +135 -0
  56. package/templates/react-native-sdk-reference/src/bridge/Context/StoreContext.ts +4 -0
  57. package/templates/react-native-sdk-reference/src/bridge/RootComponent.tsx +12 -0
  58. package/templates/react-native-sdk-reference/src/bridge/react_pconnect.jsx +334 -0
  59. package/templates/react-native-sdk-reference/src/components/common/DisplayField.tsx +29 -0
  60. package/templates/react-native-sdk-reference/src/components/common/FormFieldWrapper.tsx +5 -0
  61. package/templates/react-native-sdk-reference/src/components/common/HelperText.tsx +11 -0
  62. package/templates/react-native-sdk-reference/src/components/common/LabelText.tsx +22 -0
  63. package/templates/react-native-sdk-reference/src/components/common/inputTheme.ts +17 -0
  64. package/templates/react-native-sdk-reference/src/components/design-system/AutoComplete.tsx +126 -0
  65. package/templates/react-native-sdk-reference/src/components/design-system/FieldGroup.tsx +72 -0
  66. package/templates/react-native-sdk-reference/src/components/design-system/Radio.tsx +61 -0
  67. package/templates/react-native-sdk-reference/src/components/field/AutoComplete/AutoComplete.tsx +196 -0
  68. package/templates/react-native-sdk-reference/src/components/field/AutoComplete/index.tsx +1 -0
  69. package/templates/react-native-sdk-reference/src/components/field/Checkbox/Checkbox.tsx +89 -0
  70. package/templates/react-native-sdk-reference/src/components/field/Checkbox/index.tsx +1 -0
  71. package/templates/react-native-sdk-reference/src/components/field/Currency/Currency.tsx +84 -0
  72. package/templates/react-native-sdk-reference/src/components/field/Currency/index.tsx +1 -0
  73. package/templates/react-native-sdk-reference/src/components/field/Date/Date.tsx +94 -0
  74. package/templates/react-native-sdk-reference/src/components/field/Date/index.tsx +1 -0
  75. package/templates/react-native-sdk-reference/src/components/field/Dropdown/Dropdown.tsx +211 -0
  76. package/templates/react-native-sdk-reference/src/components/field/Dropdown/index.tsx +1 -0
  77. package/templates/react-native-sdk-reference/src/components/field/Email/Email.tsx +81 -0
  78. package/templates/react-native-sdk-reference/src/components/field/Email/index.tsx +1 -0
  79. package/templates/react-native-sdk-reference/src/components/field/Group/Group.tsx +47 -0
  80. package/templates/react-native-sdk-reference/src/components/field/Group/index.tsx +1 -0
  81. package/templates/react-native-sdk-reference/src/components/field/Integer/Integer.tsx +84 -0
  82. package/templates/react-native-sdk-reference/src/components/field/Integer/index.tsx +1 -0
  83. package/templates/react-native-sdk-reference/src/components/field/Phone/Phone.tsx +85 -0
  84. package/templates/react-native-sdk-reference/src/components/field/Phone/index.ts +1 -0
  85. package/templates/react-native-sdk-reference/src/components/field/RadioButtons/RadioButtons.tsx +118 -0
  86. package/templates/react-native-sdk-reference/src/components/field/RadioButtons/index.ts +1 -0
  87. package/templates/react-native-sdk-reference/src/components/field/TextArea/TextArea.tsx +86 -0
  88. package/templates/react-native-sdk-reference/src/components/field/TextArea/index.tsx +1 -0
  89. package/templates/react-native-sdk-reference/src/components/field/TextInput/TextInput.tsx +84 -0
  90. package/templates/react-native-sdk-reference/src/components/field/TextInput/index.tsx +1 -0
  91. package/templates/react-native-sdk-reference/src/components/field/URL/URL.tsx +86 -0
  92. package/templates/react-native-sdk-reference/src/components/field/URL/index.tsx +1 -0
  93. package/templates/react-native-sdk-reference/src/components/helpers/data_page.ts +20 -0
  94. package/templates/react-native-sdk-reference/src/components/helpers/event-utils.ts +20 -0
  95. package/templates/react-native-sdk-reference/src/components/helpers/instructions-utils.ts +57 -0
  96. package/templates/react-native-sdk-reference/src/components/helpers/state-utils.tsx +46 -0
  97. package/templates/react-native-sdk-reference/src/components/helpers/template-utils.ts +75 -0
  98. package/templates/react-native-sdk-reference/src/components/helpers/utils.ts +339 -0
  99. package/templates/react-native-sdk-reference/src/components/infra/ActionButtons/ActionButtons.tsx +63 -0
  100. package/templates/react-native-sdk-reference/src/components/infra/ActionButtons/index.tsx +1 -0
  101. package/templates/react-native-sdk-reference/src/components/infra/Assignment/Assignment.tsx +348 -0
  102. package/templates/react-native-sdk-reference/src/components/infra/Assignment/index.tsx +1 -0
  103. package/templates/react-native-sdk-reference/src/components/infra/AssignmentCard/AssignmentCard.tsx +56 -0
  104. package/templates/react-native-sdk-reference/src/components/infra/AssignmentCard/index.tsx +1 -0
  105. package/templates/react-native-sdk-reference/src/components/infra/Containers/FlowContainer/FlowContainer.tsx +57 -0
  106. package/templates/react-native-sdk-reference/src/components/infra/Containers/FlowContainer/helpers.ts +137 -0
  107. package/templates/react-native-sdk-reference/src/components/infra/Containers/FlowContainer/index.tsx +1 -0
  108. package/templates/react-native-sdk-reference/src/components/infra/Containers/RootContainer/RootContainer.tsx +52 -0
  109. package/templates/react-native-sdk-reference/src/components/infra/Containers/RootContainer/index.tsx +1 -0
  110. package/templates/react-native-sdk-reference/src/components/infra/Containers/SimpleView/helper.ts +128 -0
  111. package/templates/react-native-sdk-reference/src/components/infra/Containers/SimpleView/index.tsx +59 -0
  112. package/templates/react-native-sdk-reference/src/components/infra/Containers/ViewContainer/ViewContainer.tsx +31 -0
  113. package/templates/react-native-sdk-reference/src/components/infra/Containers/ViewContainer/helper.ts +39 -0
  114. package/templates/react-native-sdk-reference/src/components/infra/Containers/ViewContainer/index.ts +1 -0
  115. package/templates/react-native-sdk-reference/src/components/infra/Containers/helper.ts +9 -0
  116. package/templates/react-native-sdk-reference/src/components/infra/ErrorBoundary/ErrorBoundary.tsx +53 -0
  117. package/templates/react-native-sdk-reference/src/components/infra/ErrorBoundary/index.tsx +1 -0
  118. package/templates/react-native-sdk-reference/src/components/infra/MultiStep/MultiStep.tsx +24 -0
  119. package/templates/react-native-sdk-reference/src/components/infra/MultiStep/index.ts +1 -0
  120. package/templates/react-native-sdk-reference/src/components/infra/Reference/Reference.tsx +68 -0
  121. package/templates/react-native-sdk-reference/src/components/infra/Reference/index.tsx +1 -0
  122. package/templates/react-native-sdk-reference/src/components/infra/Reference/utils.ts +16 -0
  123. package/templates/react-native-sdk-reference/src/components/infra/Region/Region.tsx +10 -0
  124. package/templates/react-native-sdk-reference/src/components/infra/Region/index.tsx +1 -0
  125. package/templates/react-native-sdk-reference/src/components/infra/View/View.tsx +49 -0
  126. package/templates/react-native-sdk-reference/src/components/template/DefaultForm/DefaultForm.tsx +38 -0
  127. package/templates/react-native-sdk-reference/src/components/template/DefaultForm/index.tsx +1 -0
  128. package/templates/react-native-sdk-reference/src/components/template/DefaultForm/utils/index.ts +28 -0
  129. package/templates/react-native-sdk-reference/src/components/template/Details/Details.tsx +82 -0
  130. package/templates/react-native-sdk-reference/src/components/template/Details/index.tsx +1 -0
  131. package/templates/react-native-sdk-reference/src/components/template/OneColumn/OneColumn.tsx +29 -0
  132. package/templates/react-native-sdk-reference/src/components/template/OneColumn/index.tsx +1 -0
  133. package/templates/react-native-sdk-reference/src/context/LoaderContext.tsx +42 -0
  134. package/templates/react-native-sdk-reference/src/mediaco/AdvBanner.tsx +62 -0
  135. package/templates/react-native-sdk-reference/src/mediaco/Header.tsx +60 -0
  136. package/templates/react-native-sdk-reference/src/mediaco/HomeScreen.tsx +78 -0
  137. package/templates/react-native-sdk-reference/src/mediaco/QuickActions.tsx +68 -0
  138. package/templates/react-native-sdk-reference/src/mediaco/ResolutionScreen.tsx +48 -0
  139. package/templates/react-native-sdk-reference/src/mediaco/SafeArea.tsx +11 -0
  140. package/templates/react-native-sdk-reference/src/mediaco/TabBar.tsx +102 -0
  141. package/templates/react-native-sdk-reference/src/mediaco/YourServices.tsx +90 -0
  142. package/templates/react-native-sdk-reference/src/sdk-pega-component-map.ts +64 -0
  143. package/templates/react-native-sdk-reference/src/types/PConnProps.d.ts +41 -0
  144. package/templates/react-native-sdk-reference/src/utils/auth.ts +62 -0
  145. package/templates/react-native-sdk-reference/src/utils/init-pcore.ts +37 -0
  146. package/templates/react-native-sdk-reference/src/utils/pcore-polyfills.ts +66 -0
  147. package/templates/react-native-sdk-reference/tsconfig.json +9 -8
  148. package/templates/react-sdk-reference/.ai-common/agents/embedded-flow-expert.md +171 -0
  149. package/templates/react-sdk-reference/.ai-common/agents/implementation-expert.md +25 -26
  150. package/templates/react-sdk-reference/.ai-common/global/ai-agent-instructions-embedded.md +119 -0
  151. package/templates/react-sdk-reference/.ai-common/global/ai-agent-instructions.md +70 -121
  152. package/templates/react-sdk-reference/.ai-common/instructions/component-map.md +7 -19
  153. package/templates/react-sdk-reference/.ai-common/instructions/dse-component.md +10 -40
  154. package/templates/react-sdk-reference/.ai-common/instructions/embedded-component.md +134 -0
  155. package/templates/react-sdk-reference/.ai-common/instructions/field-component.md +15 -43
  156. package/templates/react-sdk-reference/.ai-common/instructions/template-component.md +11 -63
  157. package/templates/react-sdk-reference/.ai-common/instructions/widget-component.md +12 -57
  158. package/templates/react-sdk-reference/.ai-common/mcp/claude-code.mcp.json +8 -0
  159. package/templates/react-sdk-reference/.ai-common/mcp/copilot.mcp.json +8 -0
  160. package/templates/react-sdk-reference/.ai-common/mcp/cursor.mcp.json +11 -0
  161. package/templates/react-sdk-reference/.ai-common/prompts/add-component.md +45 -71
  162. package/templates/react-sdk-reference/.ai-common/prompts/component-manifest.json +98 -0
  163. package/templates/react-sdk-reference/.ai-common/prompts/embedded-component-manifest.md +155 -0
  164. package/templates/react-sdk-reference/.ai-common/prompts/generate-all-components.md +67 -237
  165. package/templates/react-sdk-reference/.ai-common/prompts/generate-dse-components.md +26 -77
  166. package/templates/react-sdk-reference/.ai-common/prompts/generate-embedded-components.md +315 -0
  167. package/templates/react-sdk-reference/.ai-common/prompts/generate-field-components.md +31 -80
  168. package/templates/react-sdk-reference/.ai-common/prompts/generate-template-components.md +43 -99
  169. package/templates/react-sdk-reference/.ai-common/prompts/generate-widget-components.md +33 -83
  170. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/AlertBanner.md +60 -74
  171. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/Banner.md +64 -84
  172. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/CaseSummaryFields.md +76 -109
  173. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/DetailsFields.md +84 -101
  174. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/FieldGroup.md +62 -87
  175. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/FieldGroupList.md +56 -76
  176. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/FieldValueList.md +61 -85
  177. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/Operator.md +84 -107
  178. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/Pulse.md +36 -44
  179. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/RichTextEditor.md +125 -189
  180. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/WssQuickCreate.md +34 -50
  181. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension.md +57 -179
  182. package/templates/react-sdk-reference/.ai-common/skills/embedded-flow/analyze-customer-repo.md +130 -0
  183. package/templates/react-sdk-reference/.ai-common/skills/embedded-flow/authenticate.md +311 -0
  184. package/templates/react-sdk-reference/.ai-common/skills/embedded-flow/run-and-verify-integration.md +156 -0
  185. package/templates/react-sdk-reference/.ai-common/skills/embedded-flow/wire-integration.md +476 -0
  186. package/templates/react-sdk-reference/.ai-common/skills/field-components.md +120 -242
  187. package/templates/react-sdk-reference/.ai-common/skills/field-skills/AutoComplete.md +71 -212
  188. package/templates/react-sdk-reference/.ai-common/skills/field-skills/CancelAlert.md +47 -209
  189. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Checkbox.md +90 -259
  190. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Currency.md +75 -169
  191. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Date.md +65 -160
  192. package/templates/react-sdk-reference/.ai-common/skills/field-skills/DateTime.md +59 -157
  193. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Decimal.md +55 -134
  194. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Dropdown.md +61 -185
  195. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Email.md +60 -138
  196. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Group.md +40 -99
  197. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Integer.md +44 -111
  198. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Location.md +57 -165
  199. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Multiselect.md +41 -122
  200. package/templates/react-sdk-reference/.ai-common/skills/field-skills/ObjectReference.md +32 -130
  201. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Percentage.md +48 -112
  202. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Phone.md +43 -153
  203. package/templates/react-sdk-reference/.ai-common/skills/field-skills/RadioButtons.md +76 -183
  204. package/templates/react-sdk-reference/.ai-common/skills/field-skills/RichText.md +59 -176
  205. package/templates/react-sdk-reference/.ai-common/skills/field-skills/ScalarList.md +30 -123
  206. package/templates/react-sdk-reference/.ai-common/skills/field-skills/SelectableCard.md +47 -178
  207. package/templates/react-sdk-reference/.ai-common/skills/field-skills/SemanticLink.md +31 -117
  208. package/templates/react-sdk-reference/.ai-common/skills/field-skills/TextArea.md +51 -106
  209. package/templates/react-sdk-reference/.ai-common/skills/field-skills/TextContent.md +22 -75
  210. package/templates/react-sdk-reference/.ai-common/skills/field-skills/TextInput.md +54 -116
  211. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Time.md +46 -100
  212. package/templates/react-sdk-reference/.ai-common/skills/field-skills/URL.md +44 -93
  213. package/templates/react-sdk-reference/.ai-common/skills/field-skills/UserReference.md +40 -167
  214. package/templates/react-sdk-reference/.ai-common/skills/infra-components.md +165 -0
  215. package/templates/react-sdk-reference/.ai-common/skills/infra-skills/ActionButtons.md +122 -0
  216. package/templates/react-sdk-reference/.ai-common/skills/infra-skills/MultiStep.md +178 -0
  217. package/templates/react-sdk-reference/.ai-common/skills/infra-skills/Stages.md +140 -0
  218. package/templates/react-sdk-reference/.ai-common/skills/template-components.md +74 -228
  219. package/templates/react-sdk-reference/.ai-common/skills/template-skills/AdvancedSearch.md +66 -167
  220. package/templates/react-sdk-reference/.ai-common/skills/template-skills/AppShell.md +57 -170
  221. package/templates/react-sdk-reference/.ai-common/skills/template-skills/BannerPage.md +41 -76
  222. package/templates/react-sdk-reference/.ai-common/skills/template-skills/CaseSummary.md +53 -109
  223. package/templates/react-sdk-reference/.ai-common/skills/template-skills/CaseView.md +86 -289
  224. package/templates/react-sdk-reference/.ai-common/skills/template-skills/CaseViewActionsMenu.md +60 -185
  225. package/templates/react-sdk-reference/.ai-common/skills/template-skills/Confirmation.md +66 -115
  226. package/templates/react-sdk-reference/.ai-common/skills/template-skills/DataReference.md +33 -68
  227. package/templates/react-sdk-reference/.ai-common/skills/template-skills/DefaultForm.md +53 -133
  228. package/templates/react-sdk-reference/.ai-common/skills/template-skills/DefaultPage.md +39 -82
  229. package/templates/react-sdk-reference/.ai-common/skills/template-skills/Details.md +38 -91
  230. package/templates/react-sdk-reference/.ai-common/skills/template-skills/DetailsSubTabs.md +47 -101
  231. package/templates/react-sdk-reference/.ai-common/skills/template-skills/DetailsThreeColumn.md +27 -34
  232. package/templates/react-sdk-reference/.ai-common/skills/template-skills/DetailsTwoColumn.md +25 -40
  233. package/templates/react-sdk-reference/.ai-common/skills/template-skills/DynamicTabs.md +34 -104
  234. package/templates/react-sdk-reference/.ai-common/skills/template-skills/FieldGroupTemplate.md +46 -147
  235. package/templates/react-sdk-reference/.ai-common/skills/template-skills/HierarchicalForm.md +139 -100
  236. package/templates/react-sdk-reference/.ai-common/skills/template-skills/InlineDashboard.md +43 -82
  237. package/templates/react-sdk-reference/.ai-common/skills/template-skills/InlineDashboardPage.md +47 -80
  238. package/templates/react-sdk-reference/.ai-common/skills/template-skills/ListPage.md +16 -29
  239. package/templates/react-sdk-reference/.ai-common/skills/template-skills/ListView.md +43 -228
  240. package/templates/react-sdk-reference/.ai-common/skills/template-skills/MultiReferenceReadOnly.md +20 -65
  241. package/templates/react-sdk-reference/.ai-common/skills/template-skills/NarrowWide.md +49 -97
  242. package/templates/react-sdk-reference/.ai-common/skills/template-skills/OneColumn.md +37 -71
  243. package/templates/react-sdk-reference/.ai-common/skills/template-skills/PromotedFilters.md +58 -148
  244. package/templates/react-sdk-reference/.ai-common/skills/template-skills/SelfServiceCaseView.md +82 -107
  245. package/templates/react-sdk-reference/.ai-common/skills/template-skills/SimpleTable.md +21 -60
  246. package/templates/react-sdk-reference/.ai-common/skills/template-skills/SingleReferenceReadOnly.md +43 -100
  247. package/templates/react-sdk-reference/.ai-common/skills/template-skills/SubTabs.md +36 -76
  248. package/templates/react-sdk-reference/.ai-common/skills/template-skills/TwoColumn.md +41 -90
  249. package/templates/react-sdk-reference/.ai-common/skills/template-skills/WideNarrow.md +36 -43
  250. package/templates/react-sdk-reference/.ai-common/skills/template-skills/WssNavBar.md +25 -115
  251. package/templates/react-sdk-reference/.ai-common/skills/widget-components.md +38 -174
  252. package/templates/react-sdk-reference/.ai-common/skills/widget-skills/AppAnnouncement.md +30 -57
  253. package/templates/react-sdk-reference/.ai-common/skills/widget-skills/Attachment.md +55 -101
  254. package/templates/react-sdk-reference/.ai-common/skills/widget-skills/CaseHistory.md +38 -121
  255. package/templates/react-sdk-reference/.ai-common/skills/widget-skills/FileUtility.md +37 -98
  256. package/templates/react-sdk-reference/.ai-common/skills/widget-skills/Followers.md +18 -33
  257. package/templates/react-sdk-reference/.ai-common/skills/widget-skills/QuickCreate.md +26 -91
  258. package/templates/react-sdk-reference/.ai-common/skills/widget-skills/SummaryItem.md +28 -120
  259. package/templates/react-sdk-reference/.ai-common/skills/widget-skills/ToDo.md +41 -272
  260. package/templates/react-sdk-reference/package.json +1 -1
  261. package/templates/react-sdk-reference/pega-auth-0.2.44.tgz +0 -0
  262. package/templates/react-sdk-reference/pega-sdk-react-0.1.0.tgz +0 -0
  263. package/templates/react-sdk-reference/src/components/helpers/formatters/index.ts +13 -3
  264. package/templates/react-native-sdk-reference/.github/AGENTS.md +0 -23
  265. package/templates/react-native-sdk-reference/.github/copilot-instructions.md +0 -40
  266. package/templates/react-native-sdk-reference/.github/skills/pega-sdk-component.md +0 -48
  267. package/templates/react-native-sdk-reference/App.tsx +0 -49
  268. package/templates/react-native-sdk-reference/expo-env.d.ts +0 -3
  269. package/templates/react-sdk-reference/pega-auth-0.2.42.tgz +0 -0
@@ -48,40 +48,36 @@ Read the full contents of `{{SKILL_DIR}}/design-system-extension.md`.
48
48
  This gives you:
49
49
 
50
50
  - All three implementation patterns (Pure display, Field value display, Complex display with PConnect)
51
- - The `// [DS RENDER]` placeholder approach for Pattern B components
52
51
  - The Design System Adaptation section — pattern categorisation, variant mapping table, DS discovery guidance
53
52
  - Styling patterns — when to use CSS files vs DS style props
54
53
  - Registration conventions
55
54
 
56
55
  Keep this context active throughout the entire generation session. Do not re-read it per component.
57
56
 
57
+ > Pattern A/C components (FieldValueList, FieldGroup, Pulse, etc.) use PConnect bridge or plain CSS — they do not use the DS API. Only Pattern B components consume DS primitives.
58
+
58
59
  ---
59
60
 
60
61
  ## Step 2 — Install and discover the design system (once)
61
62
 
62
- ### 2a — Check and install the DS package
63
-
64
- Run this command in your terminal:
63
+ Check the project's dependency manifest to determine whether the design system package is already installed. If it is **not** listed in the project's dependencies, install it using the project's package manager. Report what was installed.
65
64
 
66
- ```bash
67
- cat package.json | grep "<design-system-package>"
68
- ```
65
+ **Immediately after installation**, read `node_modules/<designSystem>/README.md` in full. From it, note the correct import paths, usage patterns, version-specific guidance, global CSS/styles import path, provider wrapper component name, and any peer dependency requirements. Store this information in your memory and use it for all subsequent steps — do not re-read the README later. If the README lists peer dependencies that are not already installed in the project, install them now — the design system will not function correctly without them.
69
66
 
70
- If the design system package is **not** listed in `dependencies` or `devDependencies`, install it:
67
+ You MUST also thoroughly inspect the installed design system package, focusing on display primitives (Alert, Card, Avatar, Badge, Tag, Notification) since only Pattern B components consume DS primitives:
71
68
 
72
- ```bash
73
- npm install <design-system-package>
74
- ```
69
+ 1. **Discover all available display primitives** — browse the installed package's directory tree under `node_modules/<designSystem>/` to find every component it exports. Do not assume a specific folder structure (e.g. `dist/`) — packages vary widely in how they organize source, types, and entry points. Navigate through the package's folders, read its entry-point files and type definitions, and build a complete list of every display primitive the package actually provides. Store all discovered component names and their import paths in your memory for reference during code generation.
70
+ 2. **Map each Pattern B component to the best available DS primitive** — component names from the skill files may not have an exact name match in the installed design system. Using the complete list you just discovered, identify which DS primitive best serves the same purpose (e.g. an alert/notification primitive for AlertBanner). If no single DS component is a close match, compose the requested behavior from multiple available DS primitives. Never fabricate a component import that does not exist in the installed package.
71
+ 3. **Read the props interface of every primitive you plan to use** — for each component you intend to use, locate and read its TypeScript type definitions (`.d.ts` files or inline types) to understand the exact prop names, types, required vs. optional status, and any relevant enums or union types. Pay special attention to **variant/type/severity prop names** — each DS uses different names for alert severity (e.g., `type`, `status`, `severity`, `variant`). Store this information in your memory alongside the component names.
72
+ 4. **Use ONLY confirmed component names and prop names** — when generating code, you must exclusively use the component names and prop names you discovered from the installed package. Do not rely on training knowledge of the design system's API, as it may be outdated, inaccurate, or refer to components/props that do not exist in the installed version.
75
73
 
76
- Also install any peer dependencies documented in the package's README. Report what was installed.
77
-
78
- ### 2a.1 — Install the DS styles package and configure global CSS (MANDATORY)
74
+ ### 2.1 — Install the DS styles package and configure global CSS (MANDATORY)
79
75
 
80
76
  Design systems require their global stylesheet — without it, components render unstyled.
81
77
 
82
- #### Known DS style requirements (examples — verify from README for exact paths):
78
+ #### Known DS style requirements (examples — verify against the README you already read):
83
79
 
84
- | Design System | Styles Package (example) | CSS Import in `src/main.tsx` (example) | Provider Wrapper (example) |
80
+ | Design System | Styles Package (example) | CSS Import (example) | Provider Wrapper (example) |
85
81
  | ------------- | ------------------------ | ---------------------------------------- | -------------------------- |
86
82
  | Carbon | `@carbon/styles` | `import '@carbon/react/css/styles.css';` | `<Theme>` |
87
83
  | Ant Design | (included) | `import 'antd/dist/reset.css';` | `<ConfigProvider>` |
@@ -90,49 +86,22 @@ Design systems require their global stylesheet — without it, components render
90
86
  | Shadcn/ui | (Tailwind) | `import './globals.css';` | None |
91
87
  | MUI | (included) | (none — CSS-in-JS) | `<ThemeProvider>` |
92
88
 
93
- These are **examples** based on common versions. Always verify the exact import path and provider name from the installed package's README (`node_modules/<ds>/README.md`).
94
-
95
- If in table: install styles package (if separate), add CSS import as **first import** in `src/main.tsx`, add Provider in `src/AppProviders.tsx`.
96
- If not in table: check README and `find node_modules/<ds> -name "*.css" -path "*/dist/*" | head -5`.
97
-
98
- Verification: `grep -n "import.*css\|import.*styles" src/main.tsx` must return a result. Do NOT proceed until confirmed.
99
-
100
- Report what was installed and configured.
101
-
102
- > Pattern A/C components (FieldValueList, FieldGroup, Pulse, etc.) use PConnect bridge or plain CSS — they do not use the DS API. Only Pattern B components consume DS primitives.
103
-
104
- Run these commands to discover the actual API (do NOT rely on training knowledge):
89
+ Above mentioned are **examples** based on common versions. Use the import path and provider name you noted from the README — they take precedence over this table.
105
90
 
106
- 1. Read the README for correct import paths and usage patterns:
91
+ If in table and not already configured: install styles package (if separate), add the global CSS import as the **first import** in the application's entry file, and add the Provider wrapper in the application's providers file.
92
+ If not in table: browse the installed design system's folder in `node_modules` for a `styles/` or `dist/` directory containing CSS files, and use what you find there.
107
93
 
108
- ```bash
109
- cat node_modules/<designSystem>/README.md
110
- ```
94
+ Before implementing any component, verify whether design-system-specific styles are already configured in the existing codebase — check the application's entry file for a matching CSS import. If the styles are already imported and configured, skip this step and report "already configured".
111
95
 
112
- 2. List every exported component — focus on display primitives (Alert, Card, Avatar, Badge, Tag, Notification):
96
+ Report what was installed/configured (or "already configured").
113
97
 
114
- ```bash
115
- grep "^export" node_modules/<designSystem>/dist/index.d.ts 2>/dev/null || grep -rl "^export" node_modules/<designSystem> --include="index.d.ts" | head -3 | xargs grep "^export"
116
- ```
117
-
118
- 3. For every display primitive you plan to use, read its prop interface:
119
-
120
- ```bash
121
- find node_modules/<designSystem> -name "Alert.d.ts" -o -name "Card.d.ts" -o -name "Avatar.d.ts" | head -5
122
- grep -A 40 "interface.*Props" <path-from-above>
123
- ```
124
-
125
- 4. Check for **variant/type/severity prop names** — each DS uses different names for alert severity (e.g., `type`, `status`, `severity`, `variant`).
126
-
127
- Only use component names and prop names confirmed in these files.
128
-
129
- Build a **DS display primitive reference map** from this discovery. Reuse it for every Pattern B component — do not repeat these commands per component.
98
+ Keep all DS discovery information active throughout the entire session. Reference it whenever generating a component — do NOT re-run discovery per component.
130
99
 
131
100
  ---
132
101
 
133
102
  ## Step 3 — Overwrite check (all at once)
134
103
 
135
- For each component in the list, check whether `<outputPath>/<ComponentName>/<ComponentName>.tsx` already exists.
104
+ For each component in the list, check whether the component's file or directory already exists at the output path.
136
105
 
137
106
  If **any** exist, report them all at once and ask:
138
107
 
@@ -168,34 +137,20 @@ If no skill file exists at that path, use the general pattern from `design-syste
168
137
 
169
138
  Create the directory `<outputPath>/<ComponentName>/`.
170
139
 
171
- Create `<ComponentName>.tsx` using the structure matching the pattern from `design-system-extension.md` (loaded in Step 1):
140
+ Create the component's main implementation file using the file naming convention and extension appropriate to the project's framework (determine this by examining existing components in the project).
172
141
 
173
- - **Pattern B** (Pure display — AlertBanner, Banner, Operator, WssQuickCreate): variant mapping (urgent→error, warning→warning, info→info, success→success) + DS Alert/Card/Avatar primitive from Step 2. No `getPConnect`.
174
- - **Pattern A** (PConnect display — CaseSummaryFields, DetailsFields, FieldValueList): CSS classes + optional DS typography, no DS component primitives. May use `getPConnect`.
175
- - **Pattern C** (Complex display — FieldGroup, FieldGroupList, Pulse, RichTextEditor): `createElement(createPConnectComponent(), ...)` for PConnect children, semantic HTML. No DS primitives.
142
+ Follow the implementation structure described in `design-system-extension.md` (loaded in Step 1) for the component's pattern classification — B (Pure display), A (PConnect display), or C (Complex display) — as identified in Step 4a. That file specifies the framework-specific approach for each pattern. Pattern B components should use the DS display primitive you identified in Step 2.
176
143
 
177
144
  Apply the Behavioral Contract from the component skill file (exact props, variant logic, edge cases).
178
145
 
179
- Create `index.tsx` if required by the skill file:
180
-
181
- ```typescript
182
- export { default } from './<ComponentName>';
183
- ```
184
-
185
- Create any CSS file required by the skill file.
146
+ If the project uses barrel/re-export files (check existing component directories for the convention), create one in the same directory following the same pattern. Create any CSS file required by the skill file.
186
147
 
187
148
  ### 4c — Register the component
188
149
 
189
- Edit `src/components/component-map.ts`:
150
+ Open the project's component map file (the file that maps component names to their implementations) and:
190
151
 
191
- 1. Add an import at the top of the file in the **Design System Extension** section:
192
- ```typescript
193
- import <ComponentName> from './designSystemExtension/<ComponentName>';
194
- ```
195
- 2. Add an entry in the return object of `getSampleComponentMap()` under the DSE comment:
196
- ```typescript
197
- <ComponentName>,
198
- ```
152
+ 1. Add an import at the top of the file in the **Design System Extension** section
153
+ 2. Add an entry in the component map object under the DSE comment
199
154
 
200
155
  Do not reorder or restructure any existing entries.
201
156
 
@@ -207,10 +162,4 @@ After each component: "`<ComponentName>` ✓ — Pattern `<B/A/C>`<`, using <DS
207
162
 
208
163
  ## Step 5 — Verify the build
209
164
 
210
- Run:
211
-
212
- ```bash
213
- npm run build
214
- ```
215
-
216
- If build errors occur, fix them before reporting completion. Report a summary: list of all files created and all entries added to `component-map.ts`.
165
+ Run the project's build process to confirm everything compiles without errors. Fix any build errors before reporting completion. Report a summary: list of all files created and all entries added to the component map.
@@ -0,0 +1,315 @@
1
+ ---
2
+ ai-description: "Generate Pega components styled to match a customer's existing application — given a component list and a Design Profile, produces a pega-components/ folder with implementations that satisfy the Pega behavioral contract while rendering with the customer's design system, tokens, and styling approach, and reading like their own code"
3
+ ---
4
+
5
+ ## Step 0 — Resolve missing information
6
+
7
+ Read the user's message carefully. Extract:
8
+
9
+ - **Component list** — the Pega component names to generate (e.g., `TextInput`, `Dropdown`, `DefaultForm`, `TwoColumn`, `ToDo`)
10
+ - **Design Profile location** — the path to the `.design-profile.md` file (default: `pega-components/.design-profile.md`)
11
+ - **Output path** — where to write the generated components (default: `pega-components/`)
12
+
13
+ The **component list** is required. If it is not provided and cannot be inferred from prior conversation context, stop and ask the user.
14
+
15
+ Two components are required whether or not the list names them. Add them silently and note the addition in the summary report:
16
+
17
+ - **`FieldValueList`** — when the list contains any field component. Every field renders its display-only mode through it
18
+ - **`ActionButtons`** — always. Every assignment renders action controls, and leaving it ungenerated puts SDK-styled buttons in the middle of the customer's form
19
+
20
+ If no Design Profile exists at the expected location:
21
+
22
+ - Ask the user: "No Design Profile found. Should I analyze your codebase first to create one?"
23
+ - If yes, execute the `{{SKILL_DIR}}/embedded-flow/analyze-customer-repo.md` skill first, then return here.
24
+
25
+ ---
26
+
27
+ ## Step 1 — Name resolution and categorization
28
+
29
+ Every component you generate must correspond to one canonical component listed in `{{PROMPT_DIR}}/component-manifest.json`. Pega defines a fixed set of components, and the manifest is the complete list of them. A name the user supplies may not be one of those names — it may be the name their design system uses. Your job in this step is to turn every requested name into exactly one canonical name.
30
+
31
+ Read `{{PROMPT_DIR}}/component-manifest.json` once. It contains three things you need here:
32
+
33
+ - `components` — the canonical names, grouped by type (`field`, `template`, `widget`, `designSystemExtension`, `infra`)
34
+ - `aliases` — known non-canonical names and the canonical name each one maps to
35
+ - `behaviorClasses` — a fixed list of behaviour descriptions, each mapping to one or more canonical names
36
+
37
+ For each component name in the user's list, work through the following stages in order. Stop at the first stage that produces an answer.
38
+
39
+ ### Stage 1 — Normalized name match
40
+
41
+ 1. Take the requested name and make a normalized form: convert it to lowercase, then remove all spaces, hyphens, and underscores, then remove a trailing `field`, `component`, `input`, or `control` if one is present.
42
+ 2. Build the same normalized form for every canonical name in `components`.
43
+ 3. If exactly one canonical name has the same normalized form, that is the answer.
44
+
45
+ ### Stage 2 — Alias lookup
46
+
47
+ 1. Look up the requested name in the `aliases` object. Compare using the normalized form from Stage 1 so that casing and spacing do not matter.
48
+ 2. If the name is present, the value it maps to is the answer.
49
+
50
+ ### Stage 3 — Behaviour class match
51
+
52
+ Do not search for a "similar sounding" name here. Follow these three sub-steps exactly.
53
+
54
+ 1. Decide what the requested component does for the end user, and choose **exactly one** entry from the `behaviorClasses` list that describes that behaviour. You must pick one of the listed classes. If you cannot honestly place the component in any of them, go to Stage 4.
55
+ 2. Read the canonical names that class maps to. If the class maps to exactly one name, that is the candidate.
56
+ 3. Read the candidate's skill file (see Step 4a for the location) and confirm its behavioural contract covers what the user asked for. If it clearly does not, go to Stage 4.
57
+
58
+ If the class maps to more than one canonical name, choose between them using the case type and surrounding context the user has already given you. If the context does not make the choice obvious, go to Stage 4.
59
+
60
+ ### Stage 4 — Ask the user
61
+
62
+ Tell the user that the requested name is not a Pega component name, list the two or three canonical names you considered most likely, and ask which one they want. Do not guess, and do not proceed with that component until they answer.
63
+
64
+ ### Rules for this step
65
+
66
+ - This process always ends in one of two ways: a single canonical name, or a question to the user. It never ends with you inventing a component.
67
+ - Once a canonical name is chosen, use it everywhere afterwards: the type grouping, the skill file you read, the generated folder name, and the registry key. The originally requested name is only used when reporting the substitution back to the user.
68
+ - Record the pairing of requested name and canonical name. You will report it in Step 6e.
69
+ - If two different requested names resolve to the same canonical name, generate that component once.
70
+ - If a requested name resolves to a component listed under `infra` in the manifest, generate it only if it is one of the three overridable chrome components (`ActionButtons`, `Stages`, `MultiStep`). Every other `infra` component is SDK-provided and must be skipped. See Guardrail 9.
71
+
72
+ After every name is resolved, group the canonical names by type so you can read each type's skill files together.
73
+
74
+ ---
75
+
76
+ ## Step 2 — Read foundational context (once)
77
+
78
+ Read the following **once** before the generation loop:
79
+
80
+ 1. **The Design Profile** — read the full `.design-profile.md`. Its design tokens, styling convention, and validation display convention are authoritative and must be replicated. Its component patterns (input interface, state management, event handling) and file conventions describe the customer's own code — read them for context, but generated components follow the Pega contract and Pega-owned paths instead.
81
+
82
+ 2. **General type-level skills** — for each component type present in the grouped list, read the corresponding general skill:
83
+
84
+ | Type | Skill file |
85
+ | ----------------------- | ------------------------------------------ |
86
+ | `field` | `{{SKILL_DIR}}/field-components.md` |
87
+ | `template` | `{{SKILL_DIR}}/template-components.md` |
88
+ | `widget` | `{{SKILL_DIR}}/widget-components.md` |
89
+ | `designSystemExtension` | `{{SKILL_DIR}}/design-system-extension.md` |
90
+ | `infra` | `{{SKILL_DIR}}/infra-components.md` |
91
+
92
+ These establish the shared behavioral contract for each category.
93
+
94
+ 3. **The embedded component rules** — read `{{INSTRUCTIONS_DIR}}/embedded-component{{AI_FILE_EXT}}` for the constraints specific to embedded/customer-context generation.
95
+
96
+ ---
97
+
98
+ ## Step 3 — Discover and inspect the customer's UI primitives (once)
99
+
100
+ The Design Profile names the customer's UI library and lists representative components, but it does not record how those components are _called_. This step fills that gap. Collect rendering surface only — import path, composition shape, and the prop names for value, change, disabled, and invalid states. Behaviour is not part of this: Pega owns state, events, and validation regardless of what the customer's primitive offers.
101
+
102
+ The two cases below are not exclusive — a project that vendors its UI library into its own source tree is both.
103
+
104
+ 1. If the customer uses a third-party UI library:
105
+ - Locate the library's installed package in the project
106
+ - Inspect its available components (input, select, checkbox, radio, textarea, layout containers, cards, etc.)
107
+ - Note their prop interfaces and usage patterns from the package documentation or type definitions
108
+
109
+ 2. If the customer's primitives live in their own source tree:
110
+ - Read the components listed in the Design Profile's representative component examples
111
+ - Note the same details from the source
112
+
113
+ 3. For each primitive, record whether it is a single element or a composed set — a select may be `<Select>` alone, or a `Select` plus trigger, value, content, and item parts that must be nested in a fixed order.
114
+
115
+ 4. Produce a **UI Primitive Inventory** (kept in working memory, not written to disk):
116
+
117
+ | Primitive kind | Customer's component | Import | Composition and props |
118
+ | -------------- | -------------------- | ------ | --------------------- |
119
+ | Text input | ... | ... | ... |
120
+ | Select | ... | ... | ... |
121
+ | ... | ... | ... | ... |
122
+
123
+ If a primitive kind has no equivalent in the customer's project, record that too. Step 4b composes one from the primitives that do exist, and Guardrail 1 still applies — composition uses their primitives, never an invented or newly installed one.
124
+
125
+ ---
126
+
127
+ ## Step 4 — Generate components (loop)
128
+
129
+ For each component in the list, in the grouped order (fields first, then templates, then widgets, then DSE, then any overridable chrome components):
130
+
131
+ ### 4a. Read the component-specific skill
132
+
133
+ Look for `{{SKILL_DIR}}/{type}-skills/{ComponentName}.md` where `{type}` is `field`, `template`, `widget`, `design-system-extension`, or `infra`.
134
+
135
+ If the file exists, read it fully. It defines:
136
+
137
+ - The component's specific behavioral contract (beyond the general type contract)
138
+ - Required states, modes, and edge cases
139
+ - Any sub-components or dependencies
140
+
141
+ Use the canonical name resolved in Step 1 to locate this file — not the name the user originally typed. Because Step 1 always ends at a canonical name, a skill file is expected to exist. Rely on the general type skill alone only when the resolved canonical name genuinely has no skill file of its own.
142
+
143
+ ### 4b. Determine the target UI primitive
144
+
145
+ From the UI Primitive Inventory (Step 3), identify the customer's primitive to render this Pega component with. If no direct equivalent exists, compose from the customer's available primitives.
146
+
147
+ ### 4c. Generate the component
148
+
149
+ Create the component implementation that satisfies **both**:
150
+
151
+ 1. **The Pega behavioral contract** (from skill files):
152
+ - All required inputs/outputs as defined by the type contract
153
+ - All required behaviors (display modes, validation feedback, event handling, accessibility)
154
+ - Bridge integration (PConnect access, registry lookups for sub-components)
155
+
156
+ 2. **The customer's conventions** (from Design Profile):
157
+ - Use the customer's UI library primitives for rendering
158
+ - Follow the customer's styling approach (apply styles the way they do)
159
+ - Follow the customer's import conventions (aliases, grouping, named/default)
160
+ - Use the customer's export style and co-located file layout (barrel files, types, styles)
161
+
162
+ State, events, validation wiring, and prop contracts are deliberately absent from that list — they come from the Pega behavioral contract above, no matter how the customer writes their own forms. A customer whose own screens use a form library does not change how a generated component holds a value or commits it.
163
+
164
+ **Exception — the output path is not the customer's to choose.** `pega-components/` is a generated, Pega-owned tree that the customer never authors in, so its layout is fixed rather than inferred from the Design Profile. Write the component to:
165
+
166
+ ```
167
+ {output_path}/{type}/{ComponentName}/{ComponentName}.{ext}
168
+ ```
169
+
170
+ - `{type}` is literal — `field`, `template`, `widget`, `designSystemExtension`, or `infra` — and is never renamed or flattened. The instruction globs match on it.
171
+ - `{ComponentName}` is the canonical Pega component name resolved in Step 1, verbatim, for both the folder and the implementation file, whatever the customer's naming style is. `Checkbox` produces `Checkbox/Checkbox.*`, never `checkbox/CheckboxField.*`; `Date` produces `Date/Date.*`, never `date/DateField.*`.
172
+ - `{ext}` follows the customer's framework, not their file-naming style.
173
+
174
+ Deterministic paths are what let tooling, globs, and regeneration find components again. Customer conventions govern the _contents_ of these files, not their location or name. If the customer's repo lints file names, exclude `pega-components/` from that rule rather than bending the paths.
175
+
176
+ ### 4d. Register the component
177
+
178
+ Add an entry for this component in the registry file at `{output_path}/component-map.*`:
179
+
180
+ - The key must be the canonical Pega component name (as resolved in Step 1)
181
+ - The value must reference the generated component's export
182
+
183
+ ---
184
+
185
+ ## Step 5 — Create the registry file
186
+
187
+ After all components are generated, ensure the registry file (`{output_path}/component-map.*`) is complete:
188
+
189
+ 1. It must export a function that registers all generated components into a provided component registry
190
+ 2. It must spread/include the SDK's built-in infrastructure components from the SDK adapter package. Most of these are **never generated** — they ship as-is from the SDK with their own styling (loaded via the SDK stylesheet imported in the host entry point):
191
+ - **NavBar** — renders navigation controls
192
+ - **DeferLoad** — handles deferred/lazy content loading
193
+ - **VerticalTabs** — renders vertical tab navigation
194
+ - **DashboardFilter** — renders dashboard filtering controls
195
+ 3. Three infrastructure components are **overridable chrome**. They render inline with the case form, so SDK styling on them is the most visible mismatch in an embedded flow — they may be generated and registered as overrides. An override key replaces the spread SDK entry, so it must be listed _after_ the spread:
196
+ - **ActionButtons** — the Cancel/Save/Submit row at the bottom of an assignment
197
+ - **Stages** — the case stage progress indicator
198
+ - **MultiStep** — the step navigation within a multi-step assignment
199
+ 4. Every component from the input list must have a corresponding entry
200
+ 5. No `infra` component other than those three may appear in the generated output — the rest are always sourced from the SDK adapter package
201
+
202
+ ---
203
+
204
+ ## Step 5.1 — Create a fallback component
205
+
206
+ Generate a simple fallback component at `{output_path}/FallbackComponent.*` that renders when the SDK requests a component not found in the registry. This component should:
207
+
208
+ 1. Accept the same base interface as all Pega components (the PConnect accessor)
209
+ 2. Display the unresolved component's name so the developer knows what's missing
210
+ 3. Render any children passed to it (so the component tree continues rendering)
211
+ 4. Use minimal, unobtrusive styling (a bordered box with the component name) following the customer's styling approach
212
+ 5. Be suitable for development only — in production, all components should be registered
213
+
214
+ The registry file from Step 5 should export this fallback component alongside the registration function.
215
+
216
+ ---
217
+
218
+ ## Step 6 — Verify
219
+
220
+ Execute the following checks. Do **not** declare completion until all pass.
221
+
222
+ ### 6a. Type/compilation check
223
+
224
+ Run the project's type-checking or compilation command. If any errors exist in the generated files:
225
+
226
+ - Read the error messages
227
+ - Fix the affected component
228
+ - Re-run the check
229
+ - Maximum 2 retry cycles per component
230
+
231
+ ### 6b. Contract compliance
232
+
233
+ For each generated component, verify it meets its behavioral contract by reading the source:
234
+
235
+ **Field components must:**
236
+
237
+ - Accept and use the PConnect accessor
238
+ - Handle display modes (at minimum: editable, display-only)
239
+ - Render validation feedback when validation state is present
240
+ - Wire value change and commit events through the SDK actions API
241
+ - Pass through the test identifier
242
+
243
+ **Template components must:**
244
+
245
+ - Traverse child component descriptors via the PConnect accessor
246
+ - Delegate child rendering to the SDK bridge component
247
+ - Support inherited property propagation to children
248
+
249
+ **Widget components must:**
250
+
251
+ - Consume configuration properties from the PConnect accessor
252
+ - Render display content based on provided data sources
253
+
254
+ **Design system extension components must:**
255
+
256
+ - Accept the inputs their pattern requires — the PConnect accessor for data-aware display components, plain display props for pure-presentation components, the field input contract for rich editors
257
+ - Render display content only — no value commit wiring, since these components do not own field state
258
+ - Preserve the prop shape other components depend on, because they are resolved through the registry rather than imported directly (for example, every field component renders its display-only mode through `FieldValueList`, which must keep accepting `name`, `value`, and an optional `variant`)
259
+ - Pass through the test identifier when the component renders an identifiable container
260
+
261
+ **Infrastructure (chrome) components must:**
262
+
263
+ - Accept exactly the props the SDK component accepts — these do not share one shape. `ActionButtons` takes `arMainButtons`, `arSecondaryButtons`, and `onButtonPress(action, buttonType)` and receives **no** PConnect accessor; `Stages` takes the PConnect accessor plus `stages`; `MultiStep` takes the PConnect accessor plus `children`, `itemKey`, `actionButtons`, and `onButtonPress`
264
+ - Localize labels through the Pega locale utilities rather than hardcoding text
265
+ - Differ from the SDK implementation in markup and styling only — props, callback signatures, and localization are unchanged
266
+
267
+ ### 6c. Registry completeness
268
+
269
+ Read the generated registry file and confirm:
270
+
271
+ - Every component from the input list has a corresponding key
272
+ - All imports resolve to existing generated files
273
+ - The SDK infrastructure components are included via spread/merge
274
+
275
+ ### 6d. Dependency validation
276
+
277
+ Verify that every import in the generated files resolves to either:
278
+
279
+ - A package present in the customer's dependency manifest
280
+ - A file within the generated `pega-components/` folder
281
+ - The Pega SDK packages (added in integration wiring)
282
+
283
+ If any import references a package not in the project, either:
284
+
285
+ - Replace it with an available equivalent, or
286
+ - Flag it for the user: "The component `X` requires package `Y` which is not currently installed."
287
+
288
+ ### 6e. Summary report
289
+
290
+ Output a table summarizing the generation:
291
+
292
+ | Requested Name | Resolved As | Type | Status | Notes |
293
+ | -------------- | ------------ | -------- | ------ | -------------------------------------------- |
294
+ | TextInput | TextInput | field | ✅ | Generated using [customer's input component] |
295
+ | Combobox | AutoComplete | field | ✅ | Resolved by alias |
296
+ | DefaultForm | DefaultForm | template | ✅ | Uses [customer's grid/layout] |
297
+ | ... | ... | ... | ... | ... |
298
+
299
+ Whenever `Requested Name` and `Resolved As` differ, say so in your reply as well, and name the stage that produced the match (normalized name, alias, behaviour class, or user's choice). The user must never discover a substitution only by reading the generated files.
300
+
301
+ ---
302
+
303
+ ## Guardrails
304
+
305
+ 1. **Never invent UI primitives** — only use components available in the customer's UI library or their custom component set
306
+ 2. **Never skip behavioral requirements** — every item in the skill file's contract must be implemented, even if the customer's equivalent doesn't natively support it (add the behavior manually)
307
+ 3. **Never break existing code** — the generated `pega-components/` folder is additive; never modify the customer's existing components. This prompt does not wire the integration or verify it — those are separate steps, and they are the only ones permitted to edit the customer's files, confined to the seams their skills enumerate
308
+ 4. **Never hardcode design tokens** — always reference the customer's token system (variables, constants, theme values)
309
+ 5. **Respect the customer's code conventions** — the contents of generated files should look like the customer wrote them
310
+ 6. **One folder per component** — each component gets its own folder named after its canonical Pega name; paths are Pega's, contents are the customer's
311
+ 7. **Preserve SDK bridge contract** — the component must work with the SDK bridge component's resolution and rendering mechanism; the input interface defined in the skill file is non-negotiable
312
+ 8. **Only canonical components exist** — every generated component must correspond to a canonical name in the component manifest, and every registry key must be that canonical name. Never create a component for a name that is not in the manifest, and never add the user's original wording as an extra registry key or alias. Pega resolves components by its own naming standard, so a non-canonical key would never be requested at runtime.
313
+ 9. **Never generate infrastructure components, except the three overridable chrome components** — `ActionButtons`, `MultiStep`, and `Stages` may be generated into `{output_path}/infra/` and registered as overrides, because they render inline with the case form and must match the customer's UI. They are not interchangeable: `ActionButtons` and `MultiStep` are **assignment** chrome and belong in an embedded flow, whereas `Stages` is **case** chrome that only appears on a case-view surface and must not be generated for an embedded flow. Every other component categorized as `infra` in the component manifest (NavBar, DeferLoad, VerticalTabs, DashboardFilter) is provided by the SDK adapter package and must never be generated, overridden, or customized. If one of those appears in the input list, skip it and note in the summary report that it is SDK-provided.
314
+
315
+ 10. **Reproduce the chrome components' contract exactly** — read the skill file for `ActionButtons`, `MultiStep`, or `Stages` in `{{SKILL_DIR}}/infra-skills/` before generating it. Only the markup and styling change; props, callback signatures, and localization are fixed by the SDK.