@pega/custom-dx-components 23.1.13 → 24.1.11

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 (236) hide show
  1. package/README.md +1 -1
  2. package/package.json +1 -1
  3. package/src/cli.js +1 -1
  4. package/src/constants.js +4 -0
  5. package/src/tasks/build-all/helper.js +6 -0
  6. package/src/tasks/build-comp/helper.js +8 -0
  7. package/src/tasks/bundle/builder/webpack.config.js +15 -1
  8. package/src/tasks/create/index.js +3 -0
  9. package/src/tasks/create/templates/Constellation/Field/Boolean/demo.stories.tsx.mustache +3 -13
  10. package/src/tasks/create/templates/Constellation/Field/Boolean/index.tsx.mustache +8 -5
  11. package/src/tasks/create/templates/Constellation/Field/Date/demo.stories.tsx.mustache +8 -19
  12. package/src/tasks/create/templates/Constellation/Field/DateTime/demo.stories.tsx.mustache +7 -18
  13. package/src/tasks/create/templates/Constellation/Field/DateTime/mock.ts.mustache +1 -0
  14. package/src/tasks/create/templates/Constellation/Field/Decimal/demo.stories.tsx.mustache +1 -7
  15. package/src/tasks/create/templates/Constellation/Field/Decimal/mock.ts.mustache +1 -0
  16. package/src/tasks/create/templates/Constellation/Field/Decimal-Currency/demo.stories.tsx.mustache +2 -9
  17. package/src/tasks/create/templates/Constellation/Field/Decimal-Currency/mock.ts.mustache +2 -0
  18. package/src/tasks/create/templates/Constellation/Field/Decimal-Percentage/demo.stories.tsx.mustache +2 -6
  19. package/src/tasks/create/templates/Constellation/Field/Decimal-Percentage/mock.ts.mustache +1 -0
  20. package/src/tasks/create/templates/Constellation/Field/Icon-Button-URL/PConnProps.d.ts.mustache +46 -0
  21. package/src/tasks/create/templates/Constellation/Field/Icon-Button-URL/config.json.mustache +64 -0
  22. package/src/tasks/create/templates/Constellation/Field/Icon-Button-URL/demo.stories.tsx.mustache +104 -0
  23. package/src/tasks/create/templates/Constellation/Field/Icon-Button-URL/index.tsx.mustache +218 -0
  24. package/src/tasks/create/templates/Constellation/Field/Icon-Button-URL/mock.ts.mustache +5 -0
  25. package/src/tasks/create/templates/Constellation/Field/Icon-Button-URL/styles.ts.mustache +8 -0
  26. package/src/tasks/create/templates/Constellation/Field/Integer/demo.stories.tsx.mustache +2 -6
  27. package/src/tasks/create/templates/Constellation/Field/Picklist/demo.stories.tsx.mustache +2 -6
  28. package/src/tasks/create/templates/Constellation/Field/Picklist/mock.ts.mustache +1 -0
  29. package/src/tasks/create/templates/Constellation/Field/Picklist-Autocomplete/demo.stories.tsx.mustache +2 -8
  30. package/src/tasks/create/templates/Constellation/Field/Picklist-Autocomplete/index.tsx.mustache +11 -0
  31. package/src/tasks/create/templates/Constellation/Field/Picklist-Autocomplete/utils.ts.mustache +3 -0
  32. package/src/tasks/create/templates/Constellation/Field/Picklist-RadioButtons/demo.stories.tsx.mustache +1 -7
  33. package/src/tasks/create/templates/Constellation/Field/Text/demo.stories.tsx.mustache +0 -3
  34. package/src/tasks/create/templates/Constellation/Field/Text/index.tsx.mustache +94 -4
  35. package/src/tasks/create/templates/Constellation/Field/Text-Email/demo.stories.tsx.mustache +1 -5
  36. package/src/tasks/create/templates/Constellation/Field/Text-Input/StatusWork.tsx +3 -9
  37. package/src/tasks/create/templates/Constellation/Field/Text-Input/demo.stories.tsx.mustache +1 -5
  38. package/src/tasks/create/templates/Constellation/Field/Text-Input/mock.ts.mustache +1 -0
  39. package/src/tasks/create/templates/Constellation/Field/Text-Paragraph/demo.stories.tsx.mustache +1 -5
  40. package/src/tasks/create/templates/Constellation/Field/Text-Paragraph/mock.ts.mustache +1 -0
  41. package/src/tasks/create/templates/Constellation/Field/Text-Phone/demo.stories.tsx.mustache +2 -5
  42. package/src/tasks/create/templates/Constellation/Field/Text-Phone/mock.ts.mustache +1 -0
  43. package/src/tasks/create/templates/Constellation/Field/Text-URL/demo.stories.tsx.mustache +1 -5
  44. package/src/tasks/create/templates/Constellation/Field/Text-URL/mock.ts.mustache +1 -0
  45. package/src/tasks/create/templates/Constellation/Field/TimeofDay/demo.stories.tsx.mustache +5 -15
  46. package/src/tasks/create/templates/Constellation/Template/DETAILS/Avatar.tsx.mustache +78 -0
  47. package/src/tasks/create/templates/Constellation/Template/DETAILS/DetailsRender.tsx.mustache +55 -0
  48. package/src/tasks/create/templates/Constellation/Template/DETAILS/HighlightRender.tsx.mustache +49 -0
  49. package/src/tasks/create/templates/Constellation/Template/DETAILS/Operator.tsx.mustache +218 -0
  50. package/src/tasks/create/templates/Constellation/Template/DETAILS/StatusWork.tsx.mustache +17 -19
  51. package/src/tasks/create/templates/Constellation/Template/DETAILS/demo.stories.tsx.mustache +79 -25
  52. package/src/tasks/create/templates/Constellation/Template/DETAILS/index.tsx.mustache +51 -40
  53. package/src/tasks/create/templates/Constellation/Template/DETAILS/mock.ts.mustache +78 -20
  54. package/src/tasks/create/templates/Constellation/Template/DETAILS/styles.ts.mustache +16 -0
  55. package/src/tasks/create/templates/Constellation/Template/DETAILS-region/Avatar.tsx.mustache +78 -0
  56. package/src/tasks/create/templates/Constellation/Template/DETAILS-region/DetailsRender.tsx.mustache +55 -0
  57. package/src/tasks/create/templates/Constellation/Template/DETAILS-region/HighlightRender.tsx.mustache +49 -0
  58. package/src/tasks/create/templates/Constellation/Template/DETAILS-region/Operator.tsx.mustache +218 -0
  59. package/src/tasks/create/templates/Constellation/Template/DETAILS-region/StatusWork.tsx.mustache +17 -19
  60. package/src/tasks/create/templates/Constellation/Template/DETAILS-region/demo.stories.tsx.mustache +96 -27
  61. package/src/tasks/create/templates/Constellation/Template/DETAILS-region/index.tsx.mustache +42 -39
  62. package/src/tasks/create/templates/Constellation/Template/DETAILS-region/mock.ts.mustache +68 -10
  63. package/src/tasks/create/templates/Constellation/Template/DETAILS-region/styles.ts.mustache +15 -0
  64. package/src/tasks/create/templates/Constellation/Template/FORM/DetailsRender.tsx +59 -0
  65. package/src/tasks/create/templates/Constellation/Template/FORM/demo.stories.tsx.mustache +5 -3
  66. package/src/tasks/create/templates/Constellation/Template/FORM/index.tsx.mustache +31 -5
  67. package/src/tasks/create/templates/Constellation/Template/FORM-region/DetailsRender.tsx +59 -0
  68. package/src/tasks/create/templates/Constellation/Template/FORM-region/demo.stories.tsx.mustache +4 -2
  69. package/src/tasks/create/templates/Constellation/Template/FORM-region/index.tsx.mustache +29 -7
  70. package/src/tasks/create/templates/Constellation/Template/PAGE/GetNextWork.tsx.mustache +2 -1
  71. package/src/tasks/create/templates/Constellation/Template/PAGE/demo.stories.tsx.mustache +4 -3
  72. package/src/tasks/create/templates/Constellation/Template/PAGE/localizations.json.mustache +4 -2
  73. package/src/tasks/create/templates/Constellation/Widget/CASE/demo.stories.tsx.mustache +3 -2
  74. package/src/tasks/create/templates/Constellation/Widget/PAGE/demo.stories.tsx.mustache +91 -13
  75. package/src/tasks/create/templates/Constellation/Widget/PAGE/index.tsx.mustache +67 -5
  76. package/src/tasks/create/templates/Constellation/Widget/PAGE-CASE/demo.stories.tsx.mustache +5 -4
  77. package/src/tasks/create/templates/Launchpad/Field/Icon-Button-URL/PConnProps.d.ts.mustache +46 -0
  78. package/src/tasks/create/templates/Launchpad/Field/Icon-Button-URL/config.json.mustache +32 -0
  79. package/src/tasks/create/templates/Launchpad/Field/Icon-Button-URL/demo.stories.tsx.mustache +103 -0
  80. package/src/tasks/create/templates/Launchpad/Field/Icon-Button-URL/index.tsx.mustache +216 -0
  81. package/src/tasks/create/templates/Launchpad/Field/Icon-Button-URL/mock.ts.mustache +5 -0
  82. package/src/tasks/create/templates/Launchpad/Field/Icon-Button-URL/styles.ts.mustache +8 -0
  83. package/src/tasks/create/templates/Launchpad/Widget/PAGE/OneColumnPage.svg +36 -0
  84. package/src/tasks/create/templates/Launchpad/Widget/PAGE/PConnProps.d.ts.mustache +46 -0
  85. package/src/tasks/create/templates/Launchpad/Widget/PAGE/config.json.mustache +59 -0
  86. package/src/tasks/create/templates/Launchpad/Widget/PAGE/demo.stories.tsx.mustache +120 -0
  87. package/src/tasks/create/templates/Launchpad/Widget/PAGE/index.tsx.mustache +109 -0
  88. package/src/tasks/create/templates/Launchpad/Widget/PAGE/mock.ts.mustache +25 -0
  89. package/src/tasks/create/templates/Launchpad/Widget/PAGE/styles.ts.mustache +8 -0
  90. package/src/tasks/create-all/index.js +3 -0
  91. package/src/tasks/init/template/.storybook/preview.js +3 -0
  92. package/src/tasks/init/template/package.json.mustache +6 -6
  93. package/src/tasks/init/template/tsconfig.build.json +3 -1
  94. package/src/tasks/promote-webpack/webpack.config.js +26 -0
  95. package/src/tasks/revert-webpack/index.js +1 -5
  96. package/src/tasks/validator/index.js +7 -1
  97. package/src/util.js +72 -33
  98. package/tests/assets/components/create/Pega_DXIL_MyDetails.zip +0 -0
  99. package/tests/assets/components/create/Pega_DXIL_MyTestText/demo.stories.tsx +0 -3
  100. package/tests/assets/components/create/Pega_DXIL_MyTestText/index.tsx +94 -4
  101. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyBoolean/demo.stories.tsx +3 -13
  102. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyBoolean/index.tsx +8 -5
  103. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyCaseWidget/demo.stories.tsx +3 -2
  104. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyCurrency/demo.stories.tsx +2 -9
  105. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyCurrency/mock.ts +2 -0
  106. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyDate/demo.stories.tsx +8 -19
  107. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyDateTime/demo.stories.tsx +7 -18
  108. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyDateTime/mock.ts +1 -0
  109. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyDecimal/demo.stories.tsx +1 -7
  110. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyDecimal/mock.ts +1 -0
  111. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyDetails/Avatar.tsx +78 -0
  112. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyDetails/DetailsRender.tsx +52 -0
  113. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyDetails/HighlightRender.tsx +46 -0
  114. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyDetails/Operator.tsx +215 -0
  115. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyDetails/StatusWork.tsx +17 -19
  116. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyDetails/demo.stories.tsx +79 -25
  117. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyDetails/index.tsx +48 -37
  118. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyDetails/mock.ts +78 -20
  119. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyDetails/styles.ts +16 -0
  120. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyDetails.zip +0 -0
  121. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyEmail/demo.stories.tsx +1 -5
  122. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyForm/DetailsRender.tsx +59 -0
  123. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyForm/demo.stories.tsx +5 -3
  124. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyForm/index.tsx +28 -5
  125. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyIconButtonURL/PConnProps.d.ts +46 -0
  126. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyIconButtonURL/config.json +64 -0
  127. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyIconButtonURL/demo.stories.tsx +104 -0
  128. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyIconButtonURL/index.tsx +215 -0
  129. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyIconButtonURL/mock.ts +5 -0
  130. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyIconButtonURL/styles.ts +8 -0
  131. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyInteger/demo.stories.tsx +2 -6
  132. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyPage/GetNextWork.tsx +2 -1
  133. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyPage/demo.stories.tsx +4 -3
  134. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyPage/localizations.json +4 -2
  135. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyPageCaseWidget/demo.stories.tsx +5 -4
  136. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyPageWidget/demo.stories.tsx +91 -13
  137. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyPageWidget/index.tsx +67 -5
  138. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyParagraph/demo.stories.tsx +1 -5
  139. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyParagraph/mock.ts +1 -0
  140. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyPercentage/demo.stories.tsx +2 -6
  141. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyPercentage/mock.ts +1 -0
  142. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyPhone/demo.stories.tsx +2 -5
  143. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyPhone/mock.ts +1 -0
  144. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyPicklist/demo.stories.tsx +2 -6
  145. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyPicklist/mock.ts +1 -0
  146. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyRadioButtons/demo.stories.tsx +1 -7
  147. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MySearchbox/demo.stories.tsx +2 -8
  148. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MySearchbox/index.tsx +11 -0
  149. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MySearchbox/utils.ts +3 -0
  150. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyText/demo.stories.tsx +0 -3
  151. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyText/index.tsx +94 -4
  152. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyTextInput/StatusWork.tsx +3 -9
  153. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyTextInput/demo.stories.tsx +1 -5
  154. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyTextInput/mock.ts +1 -0
  155. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyTimeOfDay/demo.stories.tsx +5 -15
  156. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyTwoColumnDetails/Avatar.tsx +78 -0
  157. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyTwoColumnDetails/DetailsRender.tsx +52 -0
  158. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyTwoColumnDetails/HighlightRender.tsx +46 -0
  159. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyTwoColumnDetails/Operator.tsx +215 -0
  160. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyTwoColumnDetails/StatusWork.tsx +17 -19
  161. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyTwoColumnDetails/demo.stories.tsx +96 -27
  162. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyTwoColumnDetails/index.tsx +39 -36
  163. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyTwoColumnDetails/mock.ts +68 -10
  164. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyTwoColumnDetails/styles.ts +15 -0
  165. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyTwoColumnForm/DetailsRender.tsx +59 -0
  166. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyTwoColumnForm/demo.stories.tsx +4 -2
  167. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyTwoColumnForm/index.tsx +23 -4
  168. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyURL/demo.stories.tsx +1 -5
  169. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyURL/mock.ts +1 -0
  170. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyBoolean/demo.stories.tsx +3 -13
  171. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyBoolean/index.tsx +8 -5
  172. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyCurrency/demo.stories.tsx +2 -9
  173. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyCurrency/mock.ts +2 -0
  174. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDate/demo.stories.tsx +8 -19
  175. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDateTime/demo.stories.tsx +7 -18
  176. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDateTime/mock.ts +1 -0
  177. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDecimal/demo.stories.tsx +1 -7
  178. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDecimal/mock.ts +1 -0
  179. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDetails/Avatar.tsx +78 -0
  180. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDetails/DetailsRender.tsx +52 -0
  181. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDetails/HighlightRender.tsx +46 -0
  182. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDetails/Operator.tsx +215 -0
  183. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDetails/StatusWork.tsx +17 -19
  184. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDetails/demo.stories.tsx +79 -25
  185. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDetails/index.tsx +48 -37
  186. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDetails/mock.ts +78 -20
  187. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDetails/styles.ts +16 -0
  188. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDetails.zip +0 -0
  189. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyEmail/demo.stories.tsx +1 -5
  190. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyForm/DetailsRender.tsx +59 -0
  191. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyForm/demo.stories.tsx +5 -3
  192. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyForm/index.tsx +28 -5
  193. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyIconButtonURL/PConnProps.d.ts +46 -0
  194. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyIconButtonURL/config.json +32 -0
  195. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyIconButtonURL/demo.stories.tsx +103 -0
  196. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyIconButtonURL/index.tsx +213 -0
  197. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyIconButtonURL/mock.ts +5 -0
  198. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyIconButtonURL/styles.ts +8 -0
  199. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyInteger/demo.stories.tsx +2 -6
  200. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPage/GetNextWork.tsx +2 -1
  201. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPage/demo.stories.tsx +4 -3
  202. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPage/localizations.json +4 -2
  203. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPageWidget/demo.stories.tsx +88 -9
  204. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPageWidget/index.tsx +67 -5
  205. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyParagraph/demo.stories.tsx +1 -5
  206. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyParagraph/mock.ts +1 -0
  207. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPercentage/demo.stories.tsx +2 -6
  208. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPercentage/mock.ts +1 -0
  209. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPhone/demo.stories.tsx +2 -5
  210. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPhone/mock.ts +1 -0
  211. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPicklist/demo.stories.tsx +2 -6
  212. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPicklist/mock.ts +1 -0
  213. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyRadioButtons/demo.stories.tsx +1 -7
  214. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MySearchbox/demo.stories.tsx +2 -8
  215. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MySearchbox/index.tsx +11 -0
  216. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MySearchbox/utils.ts +3 -0
  217. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyText/demo.stories.tsx +0 -3
  218. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyText/index.tsx +94 -4
  219. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTextInput/StatusWork.tsx +3 -9
  220. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTextInput/demo.stories.tsx +1 -5
  221. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTextInput/mock.ts +1 -0
  222. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTimeOfDay/demo.stories.tsx +5 -15
  223. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/Avatar.tsx +78 -0
  224. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/DetailsRender.tsx +52 -0
  225. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/HighlightRender.tsx +46 -0
  226. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/Operator.tsx +215 -0
  227. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/StatusWork.tsx +17 -19
  228. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/demo.stories.tsx +96 -27
  229. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/index.tsx +39 -36
  230. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/mock.ts +68 -10
  231. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/styles.ts +15 -0
  232. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnForm/DetailsRender.tsx +59 -0
  233. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnForm/demo.stories.tsx +4 -2
  234. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnForm/index.tsx +23 -4
  235. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyURL/demo.stories.tsx +1 -5
  236. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyURL/mock.ts +1 -0
@@ -16,6 +16,7 @@ export const pyReviewRaw = {
16
16
  config: {
17
17
  value: '@P .pyStatusWork',
18
18
  label: '@L Work Status',
19
+ hideLabel: true,
19
20
  displayMode: 'STACKED_LARGE_VAL',
20
21
  displayAsStatus: true,
21
22
  key: 'pyStatusWork'
@@ -26,6 +27,7 @@ export const pyReviewRaw = {
26
27
  config: {
27
28
  value: '@P .pyID',
28
29
  label: '@L Case ID',
30
+ hideLabel: true,
29
31
  displayMode: 'STACKED_LARGE_VAL',
30
32
  key: 'pyID'
31
33
  }
@@ -35,6 +37,7 @@ export const pyReviewRaw = {
35
37
  config: {
36
38
  value: '@P .pxCreateDateTime',
37
39
  label: '@L Create date/time',
40
+ hideLabel: true,
38
41
  displayMode: 'STACKED_LARGE_VAL',
39
42
  key: 'pxCreateDateTime'
40
43
  }
@@ -43,6 +46,7 @@ export const pyReviewRaw = {
43
46
  type: 'UserReference',
44
47
  config: {
45
48
  label: '@L Create Operator',
49
+ hideLabel: true,
46
50
  value: '@USER .pxCreateOperator',
47
51
  placeholder: 'Select...',
48
52
  displayMode: 'STACKED_LARGE_VAL',
@@ -160,7 +164,6 @@ export const pyReviewResolved = {
160
164
  config: {
161
165
  value: 'New',
162
166
  label: 'Work Status',
163
- displayMode: 'STACKED_LARGE_VAL',
164
167
  displayAsStatus: true
165
168
  }
166
169
  },
@@ -168,16 +171,14 @@ export const pyReviewResolved = {
168
171
  type: 'TextInput',
169
172
  config: {
170
173
  value: 'M-1002',
171
- label: 'Case ID',
172
- displayMode: 'STACKED_LARGE_VAL'
174
+ label: 'Case ID'
173
175
  }
174
176
  },
175
177
  {
176
178
  type: 'DateTime',
177
179
  config: {
178
180
  value: '2022-12-11T20:06:27.232Z',
179
- label: 'Create date/time',
180
- displayMode: 'STACKED_LARGE_VAL'
181
+ label: 'Create date/time'
181
182
  }
182
183
  },
183
184
  {
@@ -188,8 +189,7 @@ export const pyReviewResolved = {
188
189
  userId: 'conns',
189
190
  userName: 'Sara Connor'
190
191
  },
191
- placeholder: 'Select...',
192
- displayMode: 'STACKED_LARGE_VAL'
192
+ placeholder: 'Select...'
193
193
  }
194
194
  }
195
195
  ],
@@ -199,22 +199,25 @@ export const pyReviewResolved = {
199
199
  export const regionChildrenResolved = [
200
200
  {
201
201
  readOnly: true,
202
- value: '',
202
+ value: 'Deadline',
203
203
  label: 'SLA Deadline',
204
+ hideLabel: true,
204
205
  displayMode: 'LABELS_LEFT',
205
206
  key: 'SLA Deadline'
206
207
  },
207
208
  {
208
209
  readOnly: true,
209
- value: '',
210
+ value: 'Goal',
210
211
  label: 'SLA Goal',
212
+ hideLabel: true,
211
213
  displayMode: 'LABELS_LEFT',
212
214
  key: 'SLA Goal'
213
215
  },
214
216
  {
215
217
  readOnly: true,
216
- value: '',
218
+ value: 'Start Time',
217
219
  label: 'SLA Start Time',
220
+ hideLabel: true,
218
221
  listType: 'associated',
219
222
  datasource: [
220
223
  {
@@ -230,3 +233,58 @@ export const regionChildrenResolved = [
230
233
  key: 'SLA Start Time'
231
234
  }
232
235
  ];
236
+
237
+ export const operatorDetails = {
238
+ data: {
239
+ pzLoadTime: 'January 18, 2023 10:33:19 AM EST',
240
+ pzPageNameHash: '_pa1519192551088960pz',
241
+ pyOperatorInfo: {
242
+ pyUserName: 'french DigV2',
243
+ pyPosition: '',
244
+ pyImageInsKey: '',
245
+ pySkills: [
246
+ {
247
+ pySkillName: '',
248
+ pzIndexOwnerKey: 'DATA-ADMIN-OPERATOR-ID FRENCHTEST.DIGV2',
249
+ pySkillRating: 0
250
+ }
251
+ ],
252
+ pyReportToUserName: '',
253
+ pyReportTo: '',
254
+ pyOrganization: 'DXIL',
255
+ pyTitle: '',
256
+ pyLabel: 'frenchTest.DigV2',
257
+ pyEmailAddress: 'User@DigV2',
258
+ pyTelephone: ''
259
+ }
260
+ },
261
+ status: 200,
262
+ statusText: '',
263
+ headers: {
264
+ 'content-length': '435',
265
+ 'content-type': 'application/json;charset=UTF-8'
266
+ },
267
+ request: {}
268
+ };
269
+
270
+ export const configProps = {
271
+ label: 'Create operator',
272
+ createLabel: 'Created',
273
+ updateLabel: 'Updated',
274
+ updateDateTime: '2023-01-16T14:53:33.280Z',
275
+ createDateTime: '2023-01-16T14:53:33.198Z',
276
+ updateOperator: {
277
+ userId: 'admin@mediaco',
278
+ userName: 'admin'
279
+ },
280
+ createOperator: {
281
+ userId: 'admin@mediaco',
282
+ userName: 'admin'
283
+ },
284
+ resolveLabel: '',
285
+ resolveOperator: '',
286
+ resolveDateTime: '',
287
+ hideLabel: true,
288
+ key: '_532zx1dah',
289
+ displayMode: 'LABELS_LEFT'
290
+ };
@@ -6,3 +6,18 @@ export default styled.div(() => {
6
6
  margin: 0px 0;
7
7
  `;
8
8
  });
9
+
10
+ export const StyledDetailsGridContainer = styled.div(() => {
11
+ return css`
12
+ margin-line-start: 1;
13
+ `;
14
+ });
15
+
16
+ export const StyledHighlightedFieldsHrLine = styled.hr(() => {
17
+ return css`
18
+ line: {
19
+ margin: '0.75rem 0';
20
+ opacity: '50%'
21
+ }
22
+ `;
23
+ });
@@ -0,0 +1,59 @@
1
+ import { Fragment, ReactElement } from 'react';
2
+ import { FieldValueList } from '@pega/cosmos-react-core';
3
+
4
+ interface DetailsRenderProps {
5
+ children?: never;
6
+ child: NonNullable<ReactElement>;
7
+ }
8
+
9
+ const DetailsRender = (props: DetailsRenderProps) => {
10
+ const { child } = props;
11
+
12
+ const kids = child.props.getPConnect().getChildren();
13
+
14
+ const displayCompArr: ReactElement[] = [];
15
+
16
+ Object.values(kids).forEach((value: any) => {
17
+ const { type } = value.getPConnect().getRawMetadata();
18
+ const { hideLabel, variant, testId, label } = value
19
+ .getPConnect()
20
+ .resolveConfigProps(value.getPConnect().getConfigProps());
21
+
22
+ let displayComp;
23
+ const key = JSON.stringify(value.getPConnect());
24
+
25
+ if (type === 'reference') {
26
+ const refElement = value.getPConnect().getComponent();
27
+
28
+ displayCompArr.push(refElement);
29
+ } else {
30
+ const element = value.getPConnect().getComponent();
31
+ const displayEl = <Fragment key={key}>{element}</Fragment>;
32
+
33
+ const fvlStyle = {
34
+ myColGap: {
35
+ columnGap: '0',
36
+ marginLineStart: 0
37
+ }
38
+ };
39
+
40
+ // const myEl = <div>boo</div>;
41
+ displayComp = (
42
+ <Fragment key={key}>
43
+ <FieldValueList
44
+ style={fvlStyle.myColGap}
45
+ variant={hideLabel ? 'stacked' : variant}
46
+ data-testid={testId}
47
+ fields={[{ id: '1', name: hideLabel ? '' : label, value: displayEl }]}
48
+ />
49
+ </Fragment>
50
+ );
51
+
52
+ displayCompArr.push(displayComp);
53
+ }
54
+ });
55
+
56
+ return <>{displayCompArr}</>;
57
+ };
58
+
59
+ export default DetailsRender;
@@ -142,7 +142,6 @@ const renderField = resolvedProps => {
142
142
 
143
143
  export const BasePegaDxilMyTwoColumnForm: Story = args => {
144
144
  const props = {
145
- template: 'DefaultForm',
146
145
  getPConnect: () => {
147
146
  return {
148
147
  getChildren: () => {
@@ -187,4 +186,7 @@ export const BasePegaDxilMyTwoColumnForm: Story = args => {
187
186
  );
188
187
  };
189
188
 
190
- BasePegaDxilMyTwoColumnForm.args = {};
189
+ BasePegaDxilMyTwoColumnForm.args = {
190
+ showLabel: true,
191
+ label: 'Form Region template',
192
+ };
@@ -1,6 +1,7 @@
1
1
  import { Grid, Flex, FieldGroup, withConfiguration } from '@pega/cosmos-react-core';
2
2
 
3
3
  import type { PConnFieldProps } from './PConnProps';
4
+ import DetailsRender from './DetailsRender';
4
5
 
5
6
  import StyledPegaDxilMyTwoColumnFormWrapper from './styles';
6
7
 
@@ -11,19 +12,17 @@ interface PegaDxilMyTwoColumnFormProps extends PConnFieldProps {
11
12
  children: any;
12
13
  }
13
14
 
14
- // Duplicated runtime code from Constellation Design System Component
15
-
16
15
  // props passed in combination of props from property panel (config.json) and run time props from Constellation
17
16
  // any default values in config.pros should be set in defaultProps at bottom of this file
18
17
  function PegaDxilMyTwoColumnForm(props: PegaDxilMyTwoColumnFormProps) {
19
18
 
20
19
 
21
- const { children = [], label, showLabel, getPConnect } = props;
20
+ const { children = [], label, showLabel, getPConnect, readOnly, displayMode } = props;
22
21
  const propsToUse = { label, showLabel, ...getPConnect().getInheritedProps() };
23
22
 
24
23
  const numRegions = children?.length;
25
24
  const gridRepeat = "repeat(".concat(numRegions).concat(", 1fr)");
26
- const gridContainer = {"colGap" : 1};
25
+ const gridContainer = {"colGap" : 6};
27
26
  // @ts-ignore
28
27
  gridContainer.cols = gridRepeat;
29
28
  // @ts-ignore
@@ -33,6 +32,26 @@ function PegaDxilMyTwoColumnForm(props: PegaDxilMyTwoColumnFormProps) {
33
32
  // @ts-ignore
34
33
  flexContainer.gap = 2;
35
34
 
35
+ if (readOnly && readOnly === true && displayMode && displayMode === 'DISPLAY_ONLY') {
36
+ return (
37
+ <StyledPegaDxilMyTwoColumnFormWrapper>
38
+ <FieldGroup name={propsToUse.showLabel ? propsToUse.label : ''}>
39
+ <Grid container={gridContainer} data-testid={`column-count-${numRegions}`}>
40
+ {children.map((child: any, i: number) => (
41
+ <Flex
42
+ // @ts-ignore
43
+ container={{ direction: 'column', alignItems: 'normal', colGap: 1, rowGap: 1.5 }}
44
+ key={`r-${i + 1}`}
45
+ >
46
+ <DetailsRender child={child} />
47
+ </Flex>
48
+ ))}
49
+ </Grid>
50
+ </FieldGroup>
51
+ </StyledPegaDxilMyTwoColumnFormWrapper>
52
+ );
53
+ }
54
+
36
55
  return (
37
56
  <StyledPegaDxilMyTwoColumnFormWrapper>
38
57
  <FieldGroup name={propsToUse.showLabel ? propsToUse.label : ''}>
@@ -19,12 +19,7 @@ export const BasePegaDxilMyUrl: Story = args => {
19
19
 
20
20
  const props = {
21
21
  value: configProps.value,
22
- placeholder: configProps.placeholder,
23
- label: configProps.label,
24
- helperText: configProps.helperText,
25
- testId: configProps.testId,
26
22
  hasSuggestions: configProps.hasSuggestions,
27
- validatemessage: '',
28
23
  getPConnect: () => {
29
24
  return {
30
25
  getStateProps: () => {
@@ -62,5 +57,6 @@ BasePegaDxilMyUrl.args = {
62
57
  status: configProps.status,
63
58
  hideLabel: configProps.hideLabel,
64
59
  displayMode: configProps.displayMode,
60
+ variant: configProps.variant,
65
61
  validatemessage: configProps.validatemessage
66
62
  };
@@ -8,6 +8,7 @@ export const configProps = {
8
8
  testId: 'url-12345678',
9
9
  hasSuggestions: false,
10
10
  displayMode: '',
11
+ variant: '',
11
12
  hideLabel: false,
12
13
  readOnly: false,
13
14
  required: false,