@pega/sdk 0.0.5 → 0.0.6

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 (266) hide show
  1. package/README.md +10 -3
  2. package/dist/index.js +764 -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/prompts/add-component.md +45 -71
  159. package/templates/react-sdk-reference/.ai-common/prompts/component-manifest.json +98 -0
  160. package/templates/react-sdk-reference/.ai-common/prompts/embedded-component-manifest.md +155 -0
  161. package/templates/react-sdk-reference/.ai-common/prompts/generate-all-components.md +67 -237
  162. package/templates/react-sdk-reference/.ai-common/prompts/generate-dse-components.md +26 -77
  163. package/templates/react-sdk-reference/.ai-common/prompts/generate-embedded-components.md +315 -0
  164. package/templates/react-sdk-reference/.ai-common/prompts/generate-field-components.md +31 -80
  165. package/templates/react-sdk-reference/.ai-common/prompts/generate-template-components.md +43 -99
  166. package/templates/react-sdk-reference/.ai-common/prompts/generate-widget-components.md +33 -83
  167. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/AlertBanner.md +60 -74
  168. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/Banner.md +64 -84
  169. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/CaseSummaryFields.md +76 -109
  170. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/DetailsFields.md +84 -101
  171. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/FieldGroup.md +62 -87
  172. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/FieldGroupList.md +56 -76
  173. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/FieldValueList.md +61 -85
  174. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/Operator.md +84 -107
  175. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/Pulse.md +36 -44
  176. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/RichTextEditor.md +125 -189
  177. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension-skills/WssQuickCreate.md +34 -50
  178. package/templates/react-sdk-reference/.ai-common/skills/design-system-extension.md +57 -179
  179. package/templates/react-sdk-reference/.ai-common/skills/embedded-flow/analyze-customer-repo.md +130 -0
  180. package/templates/react-sdk-reference/.ai-common/skills/embedded-flow/authenticate.md +311 -0
  181. package/templates/react-sdk-reference/.ai-common/skills/embedded-flow/run-and-verify-integration.md +156 -0
  182. package/templates/react-sdk-reference/.ai-common/skills/embedded-flow/wire-integration.md +476 -0
  183. package/templates/react-sdk-reference/.ai-common/skills/field-components.md +120 -242
  184. package/templates/react-sdk-reference/.ai-common/skills/field-skills/AutoComplete.md +71 -212
  185. package/templates/react-sdk-reference/.ai-common/skills/field-skills/CancelAlert.md +47 -209
  186. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Checkbox.md +90 -259
  187. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Currency.md +75 -169
  188. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Date.md +65 -160
  189. package/templates/react-sdk-reference/.ai-common/skills/field-skills/DateTime.md +59 -157
  190. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Decimal.md +55 -134
  191. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Dropdown.md +61 -185
  192. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Email.md +60 -138
  193. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Group.md +40 -99
  194. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Integer.md +44 -111
  195. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Location.md +57 -165
  196. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Multiselect.md +41 -122
  197. package/templates/react-sdk-reference/.ai-common/skills/field-skills/ObjectReference.md +32 -130
  198. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Percentage.md +48 -112
  199. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Phone.md +43 -153
  200. package/templates/react-sdk-reference/.ai-common/skills/field-skills/RadioButtons.md +76 -183
  201. package/templates/react-sdk-reference/.ai-common/skills/field-skills/RichText.md +59 -176
  202. package/templates/react-sdk-reference/.ai-common/skills/field-skills/ScalarList.md +30 -123
  203. package/templates/react-sdk-reference/.ai-common/skills/field-skills/SelectableCard.md +47 -178
  204. package/templates/react-sdk-reference/.ai-common/skills/field-skills/SemanticLink.md +31 -117
  205. package/templates/react-sdk-reference/.ai-common/skills/field-skills/TextArea.md +51 -106
  206. package/templates/react-sdk-reference/.ai-common/skills/field-skills/TextContent.md +22 -75
  207. package/templates/react-sdk-reference/.ai-common/skills/field-skills/TextInput.md +54 -116
  208. package/templates/react-sdk-reference/.ai-common/skills/field-skills/Time.md +46 -100
  209. package/templates/react-sdk-reference/.ai-common/skills/field-skills/URL.md +44 -93
  210. package/templates/react-sdk-reference/.ai-common/skills/field-skills/UserReference.md +40 -167
  211. package/templates/react-sdk-reference/.ai-common/skills/infra-components.md +165 -0
  212. package/templates/react-sdk-reference/.ai-common/skills/infra-skills/ActionButtons.md +122 -0
  213. package/templates/react-sdk-reference/.ai-common/skills/infra-skills/MultiStep.md +178 -0
  214. package/templates/react-sdk-reference/.ai-common/skills/infra-skills/Stages.md +140 -0
  215. package/templates/react-sdk-reference/.ai-common/skills/template-components.md +74 -228
  216. package/templates/react-sdk-reference/.ai-common/skills/template-skills/AdvancedSearch.md +66 -167
  217. package/templates/react-sdk-reference/.ai-common/skills/template-skills/AppShell.md +57 -170
  218. package/templates/react-sdk-reference/.ai-common/skills/template-skills/BannerPage.md +41 -76
  219. package/templates/react-sdk-reference/.ai-common/skills/template-skills/CaseSummary.md +53 -109
  220. package/templates/react-sdk-reference/.ai-common/skills/template-skills/CaseView.md +86 -289
  221. package/templates/react-sdk-reference/.ai-common/skills/template-skills/CaseViewActionsMenu.md +60 -185
  222. package/templates/react-sdk-reference/.ai-common/skills/template-skills/Confirmation.md +66 -115
  223. package/templates/react-sdk-reference/.ai-common/skills/template-skills/DataReference.md +33 -68
  224. package/templates/react-sdk-reference/.ai-common/skills/template-skills/DefaultForm.md +53 -133
  225. package/templates/react-sdk-reference/.ai-common/skills/template-skills/DefaultPage.md +39 -82
  226. package/templates/react-sdk-reference/.ai-common/skills/template-skills/Details.md +38 -91
  227. package/templates/react-sdk-reference/.ai-common/skills/template-skills/DetailsSubTabs.md +47 -101
  228. package/templates/react-sdk-reference/.ai-common/skills/template-skills/DetailsThreeColumn.md +27 -34
  229. package/templates/react-sdk-reference/.ai-common/skills/template-skills/DetailsTwoColumn.md +25 -40
  230. package/templates/react-sdk-reference/.ai-common/skills/template-skills/DynamicTabs.md +34 -104
  231. package/templates/react-sdk-reference/.ai-common/skills/template-skills/FieldGroupTemplate.md +46 -147
  232. package/templates/react-sdk-reference/.ai-common/skills/template-skills/HierarchicalForm.md +139 -100
  233. package/templates/react-sdk-reference/.ai-common/skills/template-skills/InlineDashboard.md +43 -82
  234. package/templates/react-sdk-reference/.ai-common/skills/template-skills/InlineDashboardPage.md +47 -80
  235. package/templates/react-sdk-reference/.ai-common/skills/template-skills/ListPage.md +16 -29
  236. package/templates/react-sdk-reference/.ai-common/skills/template-skills/ListView.md +43 -228
  237. package/templates/react-sdk-reference/.ai-common/skills/template-skills/MultiReferenceReadOnly.md +20 -65
  238. package/templates/react-sdk-reference/.ai-common/skills/template-skills/NarrowWide.md +49 -97
  239. package/templates/react-sdk-reference/.ai-common/skills/template-skills/OneColumn.md +37 -71
  240. package/templates/react-sdk-reference/.ai-common/skills/template-skills/PromotedFilters.md +58 -148
  241. package/templates/react-sdk-reference/.ai-common/skills/template-skills/SelfServiceCaseView.md +82 -107
  242. package/templates/react-sdk-reference/.ai-common/skills/template-skills/SimpleTable.md +21 -60
  243. package/templates/react-sdk-reference/.ai-common/skills/template-skills/SingleReferenceReadOnly.md +43 -100
  244. package/templates/react-sdk-reference/.ai-common/skills/template-skills/SubTabs.md +36 -76
  245. package/templates/react-sdk-reference/.ai-common/skills/template-skills/TwoColumn.md +41 -90
  246. package/templates/react-sdk-reference/.ai-common/skills/template-skills/WideNarrow.md +36 -43
  247. package/templates/react-sdk-reference/.ai-common/skills/template-skills/WssNavBar.md +25 -115
  248. package/templates/react-sdk-reference/.ai-common/skills/widget-components.md +38 -174
  249. package/templates/react-sdk-reference/.ai-common/skills/widget-skills/AppAnnouncement.md +30 -57
  250. package/templates/react-sdk-reference/.ai-common/skills/widget-skills/Attachment.md +55 -101
  251. package/templates/react-sdk-reference/.ai-common/skills/widget-skills/CaseHistory.md +38 -121
  252. package/templates/react-sdk-reference/.ai-common/skills/widget-skills/FileUtility.md +37 -98
  253. package/templates/react-sdk-reference/.ai-common/skills/widget-skills/Followers.md +18 -33
  254. package/templates/react-sdk-reference/.ai-common/skills/widget-skills/QuickCreate.md +26 -91
  255. package/templates/react-sdk-reference/.ai-common/skills/widget-skills/SummaryItem.md +28 -120
  256. package/templates/react-sdk-reference/.ai-common/skills/widget-skills/ToDo.md +41 -272
  257. package/templates/react-sdk-reference/package.json +1 -1
  258. package/templates/react-sdk-reference/pega-auth-0.2.44.tgz +0 -0
  259. package/templates/react-sdk-reference/pega-sdk-react-0.1.0.tgz +0 -0
  260. package/templates/react-sdk-reference/src/components/helpers/formatters/index.ts +13 -3
  261. package/templates/react-native-sdk-reference/.github/AGENTS.md +0 -23
  262. package/templates/react-native-sdk-reference/.github/copilot-instructions.md +0 -40
  263. package/templates/react-native-sdk-reference/.github/skills/pega-sdk-component.md +0 -48
  264. package/templates/react-native-sdk-reference/App.tsx +0 -49
  265. package/templates/react-native-sdk-reference/expo-env.d.ts +0 -3
  266. package/templates/react-sdk-reference/pega-auth-0.2.42.tgz +0 -0
@@ -2,138 +2,118 @@
2
2
 
3
3
  WYSIWYG rich text editor field backed by TinyMCE. Supports editable and read-only modes, optional label, helper text, error/required states, and a file picker for image uploads.
4
4
 
5
- > **Prerequisite skill:** [`design-system-extension.md`](../design-system-extension.md) — covers architecture, props interface, styling patterns, and registration patterns common to ALL DSE components.
5
+ > **Prerequisite skill:** [`design-system-extension.md`](../design-system-extension.md) — covers architecture, input contracts, styling patterns, and registration patterns common to ALL DSE components.
6
6
 
7
7
  ---
8
8
 
9
9
  ## Component Purpose
10
10
 
11
- Renders a rich text editing area (WYSIWYG) for Pega case properties that store HTML content. In **edit mode**, uses TinyMCE with a bottom toolbar. In **read-only mode**, renders the HTML content as a read-only `<div>`. Wraps the editor in a `FormControl` with an optional floating label and helper text, consistent with other field components.
11
+ Renders a rich text editing area (WYSIWYG) for Pega case properties that store HTML content. In **edit mode**, uses a rich text editor library with a bottom toolbar. In **read-only mode**, renders the HTML content as a read-only `<div>`. Wraps the editor in a form field wrapper with an optional label and helper text, consistent with other field components.
12
12
 
13
- The editor is a `forwardRef` component — the ref is connected to the underlying TinyMCE editor instance.
13
+ The editor supports exposing its instance to parent components — use the framework's standard instance-sharing mechanism.
14
14
 
15
- > **Note:** TinyMCE is the reference editor library. In non-MUI or non-TinyMCE implementations, this component can be replaced with an alternative rich text library (Quill, ProseMirror, Slate.js, etc.). The behavioral contract below remains the same regardless of library.
15
+ > **Note:** TinyMCE is the reference editor library. In other implementations, this component can be replaced with an alternative rich text library (Quill, ProseMirror, Slate.js, Tiptap, etc.). The behavioral contract below remains the same regardless of library.
16
16
 
17
17
  ## Pega Metadata
18
18
 
19
19
  - **Pega Name:** `RichTextEditor`
20
- - **Registration key:** `RichTextEditor` (in `component-map.ts`)
21
- - **Does NOT extend PConnProps** — receives all data as explicit field-like props
22
-
23
- ## Props
24
-
25
- | Prop | Type | Required | Description |
26
- | -------------- | ------------------------- | -------- | ----------------------------------------------------------------- |
27
- | `id` | `string` | No | DOM id for the editor element. Defaults to a generated UID |
28
- | `defaultValue` | `string` | Yes | Initial HTML content of the editor |
29
- | `label` | `string` | Yes | Field label displayed above the editor |
30
- | `labelHidden` | `boolean` | Yes | If `true`, hide the label |
31
- | `info` | `string` | No | Helper text displayed below the editor |
32
- | `testId` | `string` | No | Value for `data-test-id` attribute on the FormControl wrapper |
33
- | `placeholder` | `string` | No | Placeholder text shown in empty editor |
34
- | `disabled` | `boolean` | Yes | If `true`, editor is in read-only/disabled mode with no toolbar |
35
- | `required` | `boolean` | Yes | If `true`, marks the field as required |
36
- | `readOnly` | `boolean` | Yes | If `true`, render as static HTML display (not interactive editor) |
37
- | `error` | `boolean` | Yes | If `true`, applies error styling to the FormControl |
38
- | `onBlur` | `React.EventHandler<any>` | Yes | Called when the editor loses focus |
39
- | `onChange` | `React.EventHandler<any>` | Yes | Called when the editor content changes |
40
-
41
- ## Component Skeleton
42
-
43
- ```typescript
44
- import { forwardRef } from 'react';
45
- import { useAfterInitialEffect, useConsolidatedRef, useUID } from '@pega/sdk-react';
46
-
47
- interface RichTextEditorProps {
48
- id?: string; defaultValue: string; label: string; labelHidden: boolean;
49
- info?: string; testId?: string; placeholder?: string;
50
- disabled: boolean; required: boolean; readOnly: boolean;
51
- error: boolean; onBlur: any; onChange: any;
52
- }
53
-
54
- const RichTextEditor = forwardRef((props: RichTextEditorProps, ref) => {
55
- const { defaultValue, label, labelHidden, info, testId, placeholder,
56
- disabled, required, readOnly, error, onBlur, onChange } = props;
57
- const editorRef = useConsolidatedRef(ref);
58
- const id = props.id || useUID();
59
-
60
- // 1. Mode transitions after initial mount
61
- useAfterInitialEffect([readOnly, disabled], () => {
62
- editorRef?.current?.mode?.set(readOnly || disabled ? 'readonly' : 'design');
63
- });
64
-
65
- // 2. Read-only mode: static HTML display
66
- if (readOnly) {
67
- return (
68
- <FormWrapper testId={testId} error={error} required={required}>
69
- {!labelHidden && <Label>{label}</Label>}
70
- <div className="readonly-richtext-editor"
71
- dangerouslySetInnerHTML={{ __html: defaultValue || '--' }} />
72
- {info && <HelperText>{info}</HelperText>}
73
- </FormWrapper>
74
- );
75
- }
76
-
77
- // 3. Edit mode: TinyMCE (or equivalent) editor
78
- // Key init config: skin (theme-aware), menubar: false, statusbar: false,
79
- // toolbar_location: 'bottom', min_height: 130, plugins: [lists, advlist, autolink, image, link, autoresize]
80
- // toolbar: 'blocks | bold italic strikethrough | bullist numlist outdent indent | link image' (or false if disabled)
81
- // file_picker_callback: creates <input type='file' accept='image/*'>, reads as DataURL, caches blob
82
- // content_style: theme-aware CSS string
83
- // onInit: store editor instance in editorRef.current
84
-
85
- return (
86
- <FormWrapper testId={testId} error={error} required={required}>
87
- {!labelHidden && <Label>{label}</Label>}
88
- <RichTextEditorWidget id={id} initialValue={defaultValue}
89
- disabled={disabled} onBlur={onBlur} onEditorChange={onChange}
90
- placeholder={placeholder} onInit={(evt, editor) => { editorRef.current = editor; }} />
91
- {info && <HelperText>{info}</HelperText>}
92
- </FormWrapper>
93
- );
94
- });
95
-
96
- export default RichTextEditor;
97
- ```
20
+ - **Registration key:** `RichTextEditor` (in the project's component map)
21
+ - **Does NOT extend the base PConnect interface** — receives all data as explicit field-like inputs
22
+
23
+ ## Component Inputs
24
+
25
+ The component accepts the following inputs. Define the input contract using the project's framework conventions.
26
+
27
+ | Name | Type | Required | Description |
28
+ | -------------- | ---------- | -------- | ----------------------------------------------------------------- |
29
+ | `id` | `string` | No | DOM id for the editor element. Defaults to a generated UID |
30
+ | `defaultValue` | `string` | Yes | Initial HTML content of the editor |
31
+ | `label` | `string` | Yes | Field label displayed above the editor |
32
+ | `labelHidden` | `boolean` | Yes | If `true`, hide the label |
33
+ | `info` | `string` | No | Helper text displayed below the editor |
34
+ | `testId` | `string` | No | Value for the test id attribute on the form wrapper |
35
+ | `placeholder` | `string` | No | Placeholder text shown in empty editor |
36
+ | `disabled` | `boolean` | Yes | If `true`, editor is in read-only/disabled mode with no toolbar |
37
+ | `required` | `boolean` | Yes | If `true`, marks the field as required |
38
+ | `readOnly` | `boolean` | Yes | If `true`, render as static HTML display (not interactive editor) |
39
+ | `error` | `boolean` | Yes | If `true`, applies error styling to the form wrapper |
40
+ | `onBlur` | `function` | Yes | Called when the editor loses focus |
41
+ | `onChange` | `function` | Yes | Called when the editor content changes |
42
+
43
+ ## Implementation Structure
44
+
45
+ ### Module Setup
46
+
47
+ The component imports:
48
+
49
+ - The framework's mechanism for exposing the editor instance to parent components (e.g., ref forwarding in React, `@ViewChild` in Angular)
50
+ - Lifecycle and utility helpers from the SDK bridge package: a post-initial-mount change watcher, a consolidated instance reference utility, and a unique ID generator
51
+ - A rich text editor library (TinyMCE in the reference implementation — can be swapped for Quill, ProseMirror, Tiptap, etc.)
52
+ - Form wrapper components from the design system (form control, helper text, label)
53
+ - Theme/token access from the design system for palette and typography values
54
+
55
+ The component is named `RichTextEditor`, accepts the inputs listed above, and supports exposing the editor instance to parent components. Define the input contract and export the component following the project's framework conventions.
56
+
57
+ ### Editor Instance and ID Management
58
+
59
+ - Use the SDK bridge package's consolidated reference utility to create a reference to the editor instance — the rich text editor instance is stored here after initialization via `onInit`.
60
+ - If `id` is not provided in the inputs, generate one using the SDK bridge package's unique ID generator.
61
+
62
+ ### Mode Transition Effect
63
+
64
+ After initial mount, use the SDK bridge package's post-initial-mount change watcher, observing `[readOnly, disabled]`. When either changes, switch the editor's mode to read-only if either `readOnly` or `disabled` is true, otherwise switch to edit/design mode. This transitions the editor mode without re-mounting it.
65
+
66
+ ### Render Paths
67
+
68
+ The component has two mutually exclusive render paths, both wrapped in a common form wrapper:
69
+
70
+ **Read-only path** (when `readOnly === true`):
71
+
72
+ - Render a `<div>` with the resolved `id`, class `readonly-richtext-editor`, and raw HTML content containing `defaultValue` (or `'--'` if defaultValue is falsy) via the framework's trusted HTML injection mechanism.
73
+ - Skip the TinyMCE Editor entirely.
74
+
75
+ **Edit path** (when `readOnly === false`):
76
+
77
+ - Render the TinyMCE editor instance with the configuration described in the Behavioral Contract sections below.
78
+ - On init, store the editor instance in the component's editor reference.
79
+
80
+ ### Wrapper Structure
81
+
82
+ Both paths are wrapped in a form field wrapper (the DS's form control component) with:
83
+
84
+ - The test id attribute set to the `testId` input
85
+ - `error` and `required` states passed through
86
+ - If `labelHidden` is false: render a label element with class `fieldLabel` containing the `label` text (non-floating — positioned relative with no transform)
87
+ - The rich text component (either read-only div or interactive editor)
88
+ - If `info` is provided: render a helper text element containing the info text
98
89
 
99
90
  ## Behavioral Contract
100
91
 
101
- ### 1. Ref Forwarding
92
+ ### 1. Exposing the Editor Instance
102
93
 
103
- The component uses `forwardRef`. Internally, use `useConsolidatedRef(ref)` from `@pega/sdk-react` to create `editorRef` — the TinyMCE editor instance is stored here after initialization.
94
+ The component exposes the editor instance to parent components. Internally, use the SDK bridge package's consolidated reference utility to store the editor instance after initialization.
104
95
 
105
96
  ### 2. UID for id
106
97
 
107
- If `id` is not provided, generate one using `useUID()` from `@pega/sdk-react`.
98
+ If `id` is not provided, generate one using the SDK bridge package's unique ID generator.
108
99
 
109
100
  ### 3. Read-Only Mode
110
101
 
111
- If `readOnly` is `true`, render:
112
-
113
- ```
114
- <div
115
- key={id}
116
- id={id}
117
- className='readonly-richtext-editor'
118
- dangerouslySetInnerHTML={{ __html: defaultValue || '--' }}
119
- />
120
- ```
121
-
122
- Skip the TinyMCE Editor entirely in this case.
102
+ If `readOnly` is `true`, render a `<div>` with `key` and `id` set to the resolved id, class `readonly-richtext-editor`, and the raw HTML content set to `defaultValue` (or `'--'` as fallback if defaultValue is falsy). Skip the interactive editor entirely in this case.
123
103
 
124
104
  ### 4. Edit Mode (TinyMCE)
125
105
 
126
- When `readOnly` is `false`, render `<Editor>` from `@tinymce/tinymce-react` with:
106
+ When `readOnly` is `false`, render the TinyMCE editor component from the project's framework-specific TinyMCE integration package with:
127
107
 
128
- | Config | Value |
129
- | ------------------ | ----------------------------------------- |
130
- | `tinymceScriptSrc` | `'tinymce/tinymce.min.js'` (local script) |
131
- | `id` | The resolved `id` |
132
- | `initialValue` | `defaultValue` |
133
- | `disabled` | `disabled` prop |
134
- | `onBlur` | `onBlur` prop |
135
- | `onEditorChange` | `onChange` prop |
136
- | `onInit` | Store editor in `editorRef.current` |
108
+ | Config | Value |
109
+ | ------------------ | ------------------------------------------------ |
110
+ | `tinymceScriptSrc` | `'tinymce/tinymce.min.js'` (local script) |
111
+ | `id` | The resolved `id` |
112
+ | `initialValue` | `defaultValue` |
113
+ | `disabled` | `disabled` input |
114
+ | `onBlur` | `onBlur` input |
115
+ | `onEditorChange` | `onChange` input |
116
+ | `onInit` | Store editor in the component's editor reference |
137
117
 
138
118
  ### 5. TinyMCE `init` Configuration
139
119
 
@@ -152,51 +132,21 @@ When `readOnly` is `false`, render `<Editor>` from `@tinymce/tinymce-react` with
152
132
  | `file_picker_types` | `'image'` |
153
133
  | `file_picker_callback` | See file picker section below |
154
134
  | `content_style` | Theme-aware CSS string (see below) |
155
- | `placeholder` | `placeholder` prop |
135
+ | `placeholder` | `placeholder` input |
156
136
 
157
137
  ### 6. Theme-Aware Content Style
158
138
 
159
- Inject a `content_style` string that uses theme values for the editor body:
160
-
161
- ```css
162
- body {
163
- font-family: <theme.typography.fontFamily>;
164
- font-size: <theme.typography.fontSize>px;
165
- color: <theme.palette.text.primary>;
166
- background: <theme.palette.background.paper>;
167
- }
168
- a {
169
- color: <theme.palette.primary.main>;
170
- }
171
- h1-h6 {
172
- color: <theme.palette.text.primary>;
173
- font-family: <theme.typography.fontFamily>;
174
- }
175
- blockquote {
176
- color: <theme.palette.text.secondary>;
177
- border-left: 4px solid <theme.palette.primary.light>;
178
- padding-left: 8px;
179
- }
180
- ul,
181
- ol {
182
- color: <theme.palette.text.primary>;
183
- }
184
- input,
185
- textarea,
186
- select {
187
- background: <theme.palette.background.paper>;
188
- color: <theme.palette.text.primary>;
189
- border: 1px solid <theme.palette.divider>;
190
- border-radius: 4px;
191
- padding: 6px 10px;
192
- font-size: 1em;
193
- font-family: inherit;
194
- }
195
- .mce-content-body[data-mce-placeholder]:not(.mce-visualblocks)::before {
196
- color: <theme.palette.text.secondary>;
197
- opacity: 0.7;
198
- }
199
- ```
139
+ Inject a `content_style` string into the TinyMCE init config that uses theme values. The style string should set properties for the following selectors:
140
+
141
+ | CSS Selector | Properties |
142
+ | ------------------------------------------------------------------------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
143
+ | `body` | `font-family` from theme typography; `font-size` from theme typography (in px); `color` from theme's primary text color; `background` from theme's paper/surface background |
144
+ | `a` | `color` from theme's primary/link color |
145
+ | `h1` through `h6` | `color` from theme's primary text color; `font-family` from theme typography |
146
+ | `blockquote` | `color` from theme's secondary text color; `border-left: 4px solid` using theme's primary-light color; `padding-left: 8px` |
147
+ | `ul, ol` | `color` from theme's primary text color |
148
+ | `input, textarea, select` | `background` from theme's paper/surface background; `color` from theme's primary text color; `border: 1px solid` using theme's divider color; `border-radius: 4px`; `padding: 6px 10px`; `font-size: 1em`; `font-family: inherit` |
149
+ | `.mce-content-body[data-mce-placeholder]:not(.mce-visualblocks)::before` | `color` from theme's secondary text color; `opacity: 0.7` |
200
150
 
201
151
  ### 7. File Picker Callback
202
152
 
@@ -204,32 +154,25 @@ When a user clicks the image upload in the toolbar:
204
154
 
205
155
  1. Create a hidden `<input type='file' accept='image/*'>`.
206
156
  2. On file selected: read as DataURL using `FileReader`.
207
- 3. On `FileReader.load`: create a blob in TinyMCE's blob cache (`editorRef.current.editorUpload.blobCache`), then call `cb(blobInfo.blobUri(), { title: file.name })`.
157
+ 3. On `FileReader.load`: create a blob in TinyMCE's blob cache (accessed via the stored editor instance's `editorUpload.blobCache`), then call `cb(blobInfo.blobUri(), { title: file.name })`.
208
158
  4. Programmatically click the input to open the file dialog.
209
159
 
210
160
  ### 8. readOnly/disabled Transition (after initial mount)
211
161
 
212
- Use `useAfterInitialEffect([readOnly, disabled])` from `@pega/sdk-react`:
213
-
214
- ```
215
- editorRef?.current.mode.set(readOnly || disabled ? 'readonly' : 'design')
216
- ```
217
-
218
- This switches the TinyMCE mode without re-mounting the editor.
162
+ Use the SDK bridge package's post-initial-mount change watcher, observing `[readOnly, disabled]`. When either value changes after the initial render, switch the editor mode to read-only (if readOnly or disabled is true) or to editable/design mode (otherwise). This transitions the editor mode without re-mounting it.
219
163
 
220
164
  ### 9. Wrapper Structure
221
165
 
222
- ```
223
- <FormControl variant='standard' data-test-id={testId} error={error} required={required}>
224
- {!labelHidden && <InputLabel className='fieldLabel'>{label}</InputLabel>}
225
- {richTextComponent} ← either readOnly div or <Editor>
226
- {info && <FormHelperText>{info}</FormHelperText>}
227
- </FormControl>
228
- ```
166
+ The component nests elements in this order:
167
+
168
+ 1. **Form field wrapper** (the DS's form control) with the test id attribute, `error`, and `required` states
169
+ 2. Inside the wrapper, conditionally: **Label element** with class `fieldLabel` containing `{label}` (only if `labelHidden` is false)
170
+ 3. The rich text component — either the read-only div or the interactive editor
171
+ 4. Conditionally: **Helper text element** containing `{info}` (only if `info` is provided)
229
172
 
230
173
  ## Visual Specifications
231
174
 
232
- Derived from `RichTextEditor.tsx` makeStyles:
175
+ Derived from the component's companion styles:
233
176
 
234
177
  ### Label
235
178
 
@@ -238,7 +181,7 @@ Derived from `RichTextEditor.tsx` makeStyles:
238
181
  | Position | relative |
239
182
  | Transform | `translate(0, 0px) scale(1)` (non-floating — stays at top) |
240
183
  | Margin bottom | 5px |
241
- | Color | `theme.palette.text.secondary` |
184
+ | Color | secondary text color |
242
185
 
243
186
  **CSS-only implementation notes:**
244
187
 
@@ -254,37 +197,30 @@ Derived from `RichTextEditor.tsx` makeStyles:
254
197
 
255
198
  - `defaultValue` in read-only mode falls back to `'--'` if empty.
256
199
  - `readOnly` and `disabled` are both handled — `readOnly` suppresses the editor entirely; `disabled` keeps the editor mounted but in TinyMCE's `readonly` mode with no toolbar.
257
- - Mode transitions (readOnly/disabled changing after mount) use `useAfterInitialEffect` — this hook fires on updates but NOT on the initial render, preventing a double-set on mount.
200
+ - Mode transitions (readOnly/disabled changing after mount) use the SDK bridge package's post-initial-mount change watcher — it fires on subsequent changes but NOT on the initial mount, preventing a double-set.
258
201
  - The file picker creates a transient `<input type='file'>` element that is never appended to the DOM — it is clicked programmatically.
259
- - `id` must be stable across renders — use `useUID()` only as a fallback when `id` prop is absent.
202
+ - `id` must be stable across renders — use the SDK's unique ID generator only as a fallback when `id` input is absent.
260
203
 
261
204
  ## Dependencies
262
205
 
263
- - `Editor` from `@tinymce/tinymce-react` — TinyMCE React wrapper (can be swapped for Quill, ProseMirror, Slate.js, etc.)
264
- - `useAfterInitialEffect`, `useConsolidatedRef`, `useUID` from `@pega/sdk-react` — SDK hooks
265
- - `useTheme` from `@mui/material` — for theme-aware content styles
266
- - `FormControl`, `FormHelperText`, `InputLabel` from `@mui/material` — wrapper structure
206
+ - A rich text editor library (TinyMCE in the reference — can be swapped for Quill, ProseMirror, Slate.js, Tiptap, etc.)
207
+ - Lifecycle and utility helpers from the SDK bridge package: a post-initial-mount change watcher, a consolidated instance reference utility, and a unique ID generator
208
+ - The design system's theme/token mechanism — for theme-aware content styles
209
+ - The design system's form field wrapper components (form control, helper text, label)
267
210
 
268
211
  ## Design System Mapping
269
212
 
270
213
  **UI control type:** Rich text / WYSIWYG editor field with label, helper text, and error state.
271
214
 
272
- Listed design systems are examples only.
273
-
274
- | Design System | Rich Text Library |
275
- | ------------------ | ------------------------------------------------------------- |
276
- | Default (CSS only) | `contenteditable` div with custom toolbar, or `<textarea>` |
277
- | MUI | TinyMCE (`@tinymce/tinymce-react`) wrapped in `<FormControl>` |
278
- | Ant Design | Quill (`react-quill`) or TinyMCE inside an `<AntForm.Item>` |
279
- | Chakra UI | Quill or Slate.js inside a `<FormControl>` |
280
- | Shadcn/ui | Tiptap (`@tiptap/react`) inside a field wrapper |
281
-
282
215
  When implementing in a specific design system, map the following:
283
216
 
284
- - `defaultValue` → initial HTML content
285
- - `readOnly={true}` → always render as static HTML `<div>` (no editor instance)
286
- - `disabled={true}` → editor mounted but read-only (toolbar hidden)
287
- - `onBlur` / `onChange` → editor's blur and content-change callbacks
288
- - `error` + `info` → FormControl error state + helper/description text below
289
- - `labelHidden` → conditionally render the label element
290
- - File picker → `<input type='file' accept='image/*'>` triggered programmatically
217
+ - **Rich text editor** → use TinyMCE, Quill, ProseMirror, Tiptap, or any WYSIWYG library appropriate for the project
218
+ - **Form wrapper** → use the DS's form field wrapper (form control, form group, or field container) with error/required states
219
+ - **Label** → use the DS's field label component (non-floating, positioned above the editor)
220
+ - **Helper text** → use the DS's helper/description text below the editor, with error color when `error` is true
221
+ - **`defaultValue`** → initial HTML content
222
+ - **`readOnly` = true** → always render as static HTML display (no editor instance)
223
+ - **`disabled` = true** → editor mounted but in read-only mode with toolbar hidden
224
+ - **`onBlur` / `onChange`** → editor's blur and content-change callbacks
225
+ - **File picker** → `<input type='file' accept='image/*'>` triggered programmatically when the image toolbar button is clicked
226
+ - **Theme-aware styles** → inject the DS's typography and palette values into the editor's content styles so content inside the editor matches the app's theme
@@ -2,7 +2,7 @@
2
2
 
3
3
  Quick-launch action grid that displays a heading and a set of labeled buttons, each optionally with an icon, for creating WSS cases.
4
4
 
5
- > **Prerequisite skill:** [`design-system-extension.md`](../design-system-extension.md) — covers architecture, props interface, styling patterns, and registration patterns common to ALL DSE components.
5
+ > **Prerequisite skill:** [`design-system-extension.md`](../design-system-extension.md) — covers architecture, input contracts, styling patterns, and registration patterns common to ALL DSE components.
6
6
 
7
7
  ---
8
8
 
@@ -13,46 +13,39 @@ Renders a titled section of clickable action cards arranged in a responsive CSS
13
13
  ## Pega Metadata
14
14
 
15
15
  - **Pega Name:** `WssQuickCreate`
16
- - **Registration key:** `WssQuickCreate` (in `component-map.ts`)
17
- - **Does NOT use `getPConnect`** — receives all data as direct props
16
+ - **Registration key:** `WssQuickCreate` (in the project's component map)
17
+ - **Does NOT use `getPConnect`** — receives all data as direct inputs
18
18
 
19
- ## Props
19
+ ## Component Inputs
20
20
 
21
- | Prop | Type | Required | Description |
21
+ The component accepts the following inputs. Define the input contract using the project's framework conventions.
22
+
23
+ | Name | Type | Required | Description |
22
24
  | --------- | -------------------------------------------------------------- | -------- | ---------------------------------------------------------------------------- |
23
25
  | `heading` | `string` | Yes | Section title rendered as an `<h1>` |
24
26
  | `actions` | `Array<{ label: string; onClick: () => void; icon?: string }>` | No | List of action items; each has a label, click handler, and optional icon URL |
25
27
 
26
- ## Component Skeleton
27
-
28
- ```typescript
29
- import './WssQuickCreate.css';
30
-
31
- interface WssQuickCreateProps {
32
- heading: string;
33
- actions?: Array<{ label: string; onClick: () => void; icon?: string }>;
34
- }
35
-
36
- export default function WssQuickCreate({ heading, actions }: WssQuickCreateProps) {
37
- return (
38
- <>
39
- <h1 id="quick-links-heading" className="quick-links-heading">{heading}</h1>
40
- <ul id="quick-links" className="quick-link-ul-list">
41
- {actions?.map((action, index) => (
42
- <li key={index} className="quickLinkList">
43
- <button type="button" className="quick-link-button" onClick={action.onClick}>
44
- <span className="quick-link-button-span">
45
- {action.icon && <img className="quick-link-icon" src={action.icon} />}
46
- <span>{action.label}</span>
47
- </span>
48
- </button>
49
- </li>
50
- ))}
51
- </ul>
52
- </>
53
- );
54
- }
55
- ```
28
+ ## Implementation Structure
29
+
30
+ ### Module Setup
31
+
32
+ The component requires companion styles (for action list and button styling) co-located following the project's styling convention. It does NOT import any Pega SDK modules — all data arrives via direct inputs.
33
+
34
+ The component is named `WssQuickCreate` and accepts the inputs listed in the table above. Define the input contract and export the component following the project's framework conventions.
35
+
36
+ ### Component Logic
37
+
38
+ The component receives `heading` and `actions` as inputs, then renders:
39
+
40
+ 1. **Heading** — an `<h1>` element with `id="quick-links-heading"` and class `quick-links-heading`, containing the `heading` text.
41
+ 2. **Action list** — a `<ul>` with `id="quick-links"` and class `quick-link-ul-list`.
42
+ 3. **Action items** — if `actions` is provided, iterate over the array rendering one `<li>` per action:
43
+ - The `<li>` has the `quickLinkList` style class (styled card appearance with border, rounded corners, and themed background color).
44
+ - Inside each `<li>`, render a `<button>` with `type="button"`, class `quick-link-button`, and the action's `onClick` handler.
45
+ - Button content is a `<span>` with class `quick-link-button-span` (flex column layout) containing:
46
+ - If `action.icon` is provided: an `<img>` with class `quick-link-icon` and `src` set to the icon URL.
47
+ - A `<span>` containing `action.label`.
48
+ 4. If `actions` is not provided or is empty, render only the heading with an empty list.
56
49
 
57
50
  ## Behavioral Contract
58
51
 
@@ -68,7 +61,7 @@ export default function WssQuickCreate({ heading, actions }: WssQuickCreateProps
68
61
 
69
62
  ## Visual Specifications
70
63
 
71
- Derived from `WssQuickCreate.css` and component makeStyles:
64
+ Derived from the component's companion styles:
72
65
 
73
66
  ### Section Heading
74
67
 
@@ -150,19 +143,10 @@ Derived from `WssQuickCreate.css` and component makeStyles:
150
143
 
151
144
  **UI control type:** Responsive grid of action cards / quick-launch buttons.
152
145
 
153
- Listed design systems are examples only.
154
-
155
- | Design System | Recommended Component |
156
- | ------------------ | ----------------------------------------------------------------------- |
157
- | Default (CSS only) | CSS grid `<ul>` + `<button>` cards with flex icon/label layout |
158
- | MUI | `<Button>` inside Grid items; use `makeStyles` or `sx` for card styling |
159
- | Ant Design | `<List>` with `<Card>` items or `<Button>` blocks inside a CSS grid |
160
- | Chakra UI | `<SimpleGrid>` with `<Button>` children; `flexDir='column'` |
161
- | Shadcn/ui | Grid of custom `<Button variant='outline'>` cards |
162
-
163
146
  When implementing in a specific design system, map the following:
164
147
 
165
- - Card border/background → design system's card or outlined button variant
166
- - Button `onClick` → standard click handler prop
167
- - Icon + label stacked layout → `flexDirection: 'column'` button content
168
- - Responsive grid → design system's grid or `SimpleGrid` equivalent
148
+ - **Card border/background** → use the DS's card or outlined button variant with the themed background and border colors
149
+ - **Button click** → standard click handler wired to `action.onClick`
150
+ - **Icon + label stacked layout** → use a flex column layout inside the button content area
151
+ - **Responsive grid** → use the DS's responsive grid component or CSS grid with `repeat(auto-fit, minmax(min(20ch, 100%), 1fr))`
152
+ - **Dark/light mode background** → use `var(--app-background-color)` in dark mode or `var(--link-button-color)` in light mode (or detect from the DS's theme mode)