@pega/custom-dx-components 8.8.19 → 23.1.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (409) hide show
  1. package/.prettierrc.json +1 -7
  2. package/jest.config.cjs +1 -1
  3. package/package.json +7 -6
  4. package/src/tasks/create/index.js +29 -2
  5. package/src/tasks/create/templates/Constellation/Field/Boolean/index.jsx.mustache +3 -3
  6. package/src/tasks/create/templates/Constellation/Field/Date/config.json.mustache +5 -1
  7. package/src/tasks/create/templates/Constellation/Field/Date/index.jsx.mustache +2 -1
  8. package/src/tasks/create/templates/Constellation/Field/DateTime/index.jsx.mustache +1 -1
  9. package/src/tasks/create/templates/Constellation/Field/Decimal/index.jsx.mustache +3 -3
  10. package/src/tasks/create/templates/Constellation/Field/Decimal-Currency/index.jsx.mustache +3 -3
  11. package/src/tasks/create/templates/Constellation/Field/Decimal-Percentage/index.jsx.mustache +6 -5
  12. package/src/tasks/create/templates/Constellation/Field/Integer/index.jsx.mustache +4 -3
  13. package/src/tasks/create/templates/Constellation/Field/Picklist/index.jsx.mustache +2 -1
  14. package/src/tasks/create/templates/Constellation/Field/Text/index.jsx.mustache +5 -4
  15. package/src/tasks/create/templates/Constellation/Field/Text-Email/index.jsx.mustache +2 -1
  16. package/src/tasks/create/templates/Constellation/Field/Text-Input/index.jsx.mustache +1 -1
  17. package/src/tasks/create/templates/Constellation/Field/Text-Paragraph/index.jsx.mustache +1 -2
  18. package/src/tasks/create/templates/Constellation/Field/Text-Phone/index.jsx.mustache +1 -1
  19. package/src/tasks/create/templates/Constellation/Field/Text-URL/index.jsx.mustache +1 -1
  20. package/src/tasks/create/templates/Constellation/Field/{TimeOfDay → TimeofDay}/index.jsx.mustache +5 -4
  21. package/src/tasks/create/templates/Constellation/Template/DETAILS/demo.stories.jsx.mustache +3 -0
  22. package/src/tasks/create/templates/Constellation/Template/DETAILS/index.jsx.mustache +2 -2
  23. package/src/tasks/create/templates/Constellation/Template/DETAILS-region/demo.stories.jsx.mustache +3 -0
  24. package/src/tasks/create/templates/Constellation/Template/DETAILS-region/index.jsx.mustache +2 -2
  25. package/src/tasks/create/templates/Constellation/Template/FORM/demo.stories.jsx.mustache +5 -2
  26. package/src/tasks/create/templates/Constellation/Template/FORM/index.jsx.mustache +18 -12
  27. package/src/tasks/create/templates/Constellation/Template/FORM-region/demo.stories.jsx.mustache +5 -2
  28. package/src/tasks/create/templates/Constellation/Template/FORM-region/index.jsx.mustache +14 -11
  29. package/src/tasks/create/templates/Constellation/Widget/CASE/config.json.mustache +1 -1
  30. package/src/tasks/create/templates/Constellation/Widget/CASE/index.jsx.mustache +2 -2
  31. package/src/tasks/create/templates/Constellation/Widget/PAGE-CASE/Operator.jsx.mustache +2 -2
  32. package/src/tasks/create/templates/Constellation/Widget/PAGE-CASE/index.jsx.mustache +2 -2
  33. package/src/tasks/create/templates/Launchpad/Field/__components.md +3 -0
  34. package/src/tasks/create/templates/Launchpad/Template/__components.md +3 -0
  35. package/src/tasks/create/templates/Launchpad/Widget/CASE/config.json.mustache +23 -0
  36. package/src/tasks/create/templates/Launchpad/Widget/CASE/demo.stories.jsx.mustache +78 -0
  37. package/src/tasks/create/templates/Launchpad/Widget/CASE/index.jsx.mustache +76 -0
  38. package/src/tasks/create/templates/Launchpad/Widget/CASE/mock.stories.js.mustache +390 -0
  39. package/src/tasks/create/templates/Launchpad/Widget/PAGE-CASE/Operator.jsx.mustache +282 -0
  40. package/src/tasks/create/templates/Launchpad/Widget/PAGE-CASE/config.json.mustache +55 -0
  41. package/src/tasks/create/templates/Launchpad/Widget/PAGE-CASE/demo.stories.jsx.mustache +74 -0
  42. package/src/tasks/create/templates/Launchpad/Widget/PAGE-CASE/index.jsx.mustache +82 -0
  43. package/src/tasks/create/templates/Launchpad/Widget/__components.md +3 -0
  44. package/src/tasks/create-all/index.js +106 -73
  45. package/src/tasks/delete/helper.js +75 -4
  46. package/src/tasks/delete-all/helper.js +67 -3
  47. package/src/tasks/init/template/package.json.mustache +9 -4
  48. package/src/tasks/list/helper.js +63 -5
  49. package/src/tasks/list/index.js +18 -2
  50. package/{src/tasks/init/template/test → tests}/assets/components/create/Pega_DXIL_MyTestText/index.jsx +5 -4
  51. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyBoolean/index.jsx +3 -3
  52. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyCaseWidget/config.json +1 -1
  53. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyCurrency/index.jsx +1 -1
  54. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDate/config.json +5 -1
  55. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDate/index.jsx +2 -1
  56. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDateTime/index.jsx +1 -1
  57. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDecimal/index.jsx +1 -1
  58. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDetails/demo.stories.jsx +3 -0
  59. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyEmail/index.jsx +2 -1
  60. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyForm/demo.stories.jsx +3 -0
  61. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyForm/index.jsx +15 -9
  62. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyInteger/index.jsx +2 -1
  63. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyPageCaseWidget/Avatar.jsx +75 -0
  64. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyPageCaseWidget/OneColumnPage.svg +36 -0
  65. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyPageCaseWidget/mock.stories.js +51 -0
  66. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyPageWidget/OneColumnPage.svg +36 -0
  67. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyParagraph/index.jsx +1 -2
  68. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPercentage/index.jsx +2 -1
  69. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPhone/index.jsx +1 -1
  70. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPicklist/index.jsx +2 -1
  71. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyText/index.jsx +5 -4
  72. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTextInput/index.jsx +1 -1
  73. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTimeOfDay/index.jsx +5 -4
  74. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTwoColumnDetails/demo.stories.jsx +3 -0
  75. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTwoColumnForm/demo.stories.jsx +3 -0
  76. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTwoColumnForm/index.jsx +12 -9
  77. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyTwoColumnForm/styles.js +14 -0
  78. package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyURL/index.jsx +1 -1
  79. package/tests/assets/components/createAll/Constellation/Pega_DXIL_MyURL/styles.js +14 -0
  80. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyBoolean/Boolean.js +38 -0
  81. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyBoolean/boolean-format.js +26 -0
  82. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyBoolean/config.json +145 -0
  83. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyBoolean/demo.stories.jsx +61 -0
  84. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyBoolean/event-utils.js +18 -0
  85. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyBoolean/index.jsx +170 -0
  86. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyBoolean/mock.stories.js +21 -0
  87. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyBoolean/styles.js +14 -0
  88. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyCaseWidget/OneColumnPage.svg +36 -0
  89. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyCaseWidget/config.json +23 -0
  90. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyCaseWidget/demo.stories.jsx +78 -0
  91. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyCaseWidget/index.jsx +73 -0
  92. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyCaseWidget/mock.stories.js +390 -0
  93. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyCaseWidget/styles.js +14 -0
  94. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyCurrency/config.json +291 -0
  95. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyCurrency/demo.stories.jsx +53 -0
  96. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyCurrency/event-utils.js +18 -0
  97. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyCurrency/index.jsx +296 -0
  98. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyCurrency/mock.stories.js +23 -0
  99. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyCurrency/styles.js +14 -0
  100. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyCurrency/suggestions-handler.js +10 -0
  101. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDate/DateFormatter.js +61 -0
  102. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDate/FormattedText.jsx +41 -0
  103. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDate/config.json +199 -0
  104. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDate/date.js +439 -0
  105. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDate/demo.stories.jsx +73 -0
  106. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDate/index.jsx +257 -0
  107. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDate/mock.stories.js +23 -0
  108. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDate/styles.js +14 -0
  109. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDate/suggestions-handler.js +10 -0
  110. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDateTime/config.json +256 -0
  111. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDateTime/date-time.js +92 -0
  112. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDateTime/date-utils.js +288 -0
  113. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDateTime/date.js +331 -0
  114. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDateTime/demo.stories.jsx +73 -0
  115. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDateTime/index.jsx +254 -0
  116. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDateTime/mock.stories.js +23 -0
  117. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDateTime/styles.js +14 -0
  118. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDateTime/suggestions-handler.js +10 -0
  119. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDecimal/config.json +278 -0
  120. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDecimal/demo.stories.jsx +49 -0
  121. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDecimal/event-utils.js +18 -0
  122. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDecimal/index.jsx +270 -0
  123. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDecimal/mock.stories.js +21 -0
  124. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDecimal/styles.js +14 -0
  125. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDecimal/suggestions-handler.js +10 -0
  126. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDetails/OneColumnDetails.svg +22 -0
  127. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDetails/StatusWork.jsx +26 -0
  128. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDetails/config.json +35 -0
  129. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDetails/demo.stories.jsx +135 -0
  130. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDetails/index.jsx +83 -0
  131. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDetails/mock.stories.js +189 -0
  132. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDetails/styles.js +14 -0
  133. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyDetails/utils.js +152 -0
  134. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyEmail/config.json +111 -0
  135. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyEmail/demo.stories.jsx +48 -0
  136. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyEmail/event-utils.js +18 -0
  137. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyEmail/index.jsx +232 -0
  138. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyEmail/mock.stories.js +22 -0
  139. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyEmail/styles.js +14 -0
  140. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyEmail/suggestions-handler.js +10 -0
  141. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyForm/DefaultForm.svg +29 -0
  142. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyForm/config.json +45 -0
  143. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyForm/demo.stories.jsx +169 -0
  144. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyForm/index.jsx +48 -0
  145. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyForm/mock.stories.js +137 -0
  146. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyForm/styles.js +14 -0
  147. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyInteger/config.json +344 -0
  148. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyInteger/demo.stories.jsx +49 -0
  149. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyInteger/event-utils.js +18 -0
  150. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyInteger/index.jsx +334 -0
  151. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyInteger/mock.stories.js +21 -0
  152. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyInteger/styles.js +14 -0
  153. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyInteger/suggestions-handler.js +10 -0
  154. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPage/GetNextWork.jsx +35 -0
  155. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPage/OneColumnPage.svg +36 -0
  156. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPage/config.json +32 -0
  157. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPage/demo.stories.jsx +102 -0
  158. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPage/index.jsx +70 -0
  159. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPage/localizations.json +4 -0
  160. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPage/mock.stories.js +94 -0
  161. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPage/styles.js +14 -0
  162. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPage/utils.js +229 -0
  163. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPageCaseWidget/Avatar.jsx +75 -0
  164. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPageCaseWidget/OneColumnPage.svg +36 -0
  165. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPageCaseWidget/Operator.jsx +279 -0
  166. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPageCaseWidget/config.json +55 -0
  167. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPageCaseWidget/demo.stories.jsx +74 -0
  168. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPageCaseWidget/index.jsx +80 -0
  169. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPageCaseWidget/mock.stories.js +51 -0
  170. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPageCaseWidget/styles.js +14 -0
  171. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPageWidget/OneColumnPage.svg +36 -0
  172. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPageWidget/config.json +59 -0
  173. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPageWidget/demo.stories.jsx +30 -0
  174. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPageWidget/index.jsx +48 -0
  175. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPageWidget/mock.stories.js +23 -0
  176. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPageWidget/styles.js +14 -0
  177. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyParagraph/config.json +111 -0
  178. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyParagraph/demo.stories.jsx +48 -0
  179. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyParagraph/event-utils.js +18 -0
  180. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyParagraph/index.jsx +230 -0
  181. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyParagraph/mock.stories.js +20 -0
  182. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyParagraph/styles.js +14 -0
  183. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyParagraph/suggestions-handler.js +10 -0
  184. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPercentage/config.json +93 -0
  185. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPercentage/demo.stories.jsx +49 -0
  186. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPercentage/event-utils.js +18 -0
  187. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPercentage/index.jsx +276 -0
  188. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPercentage/mock.stories.js +21 -0
  189. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPercentage/styles.js +14 -0
  190. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPercentage/suggestions-handler.js +10 -0
  191. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPhone/config.json +123 -0
  192. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPhone/demo.stories.jsx +46 -0
  193. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPhone/event-utils.js +18 -0
  194. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPhone/index.jsx +266 -0
  195. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPhone/mock.stories.js +37 -0
  196. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPhone/styles.js +14 -0
  197. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPhone/suggestions-handler.js +10 -0
  198. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPicklist/config.json +114 -0
  199. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPicklist/demo.stories.jsx +78 -0
  200. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPicklist/event-utils.js +18 -0
  201. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPicklist/index.jsx +352 -0
  202. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPicklist/mock.stories.js +67 -0
  203. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPicklist/styles.js +14 -0
  204. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyPicklist/suggestions-handler.js +10 -0
  205. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyText/config.json +55 -0
  206. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyText/demo.stories.jsx +51 -0
  207. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyText/index.jsx +61 -0
  208. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyText/mock.stories.js +13 -0
  209. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyText/styles.js +14 -0
  210. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTextInput/StatusWork.jsx +26 -0
  211. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTextInput/config.json +111 -0
  212. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTextInput/demo.stories.jsx +48 -0
  213. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTextInput/event-utils.js +18 -0
  214. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTextInput/index.jsx +239 -0
  215. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTextInput/mock.stories.js +21 -0
  216. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTextInput/styles.js +14 -0
  217. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTextInput/suggestions-handler.js +10 -0
  218. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTimeOfDay/config.json +185 -0
  219. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTimeOfDay/demo.stories.jsx +57 -0
  220. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTimeOfDay/index.jsx +214 -0
  221. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTimeOfDay/mock.stories.js +20 -0
  222. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTimeOfDay/styles.js +14 -0
  223. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTimeOfDay/suggestions-handler.js +10 -0
  224. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTimeOfDay/time-of-day.js +288 -0
  225. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/StatusWork.jsx +26 -0
  226. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/TwoColumnDetails.svg +28 -0
  227. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/config.json +42 -0
  228. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/demo.stories.jsx +139 -0
  229. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/index.jsx +83 -0
  230. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/mock.stories.js +230 -0
  231. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/styles.js +14 -0
  232. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnDetails/utils.js +155 -0
  233. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnForm/TwoColumn.svg +38 -0
  234. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnForm/config.json +27 -0
  235. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnForm/demo.stories.jsx +178 -0
  236. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnForm/index.jsx +48 -0
  237. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnForm/mock.stories.js +143 -0
  238. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyTwoColumnForm/styles.js +14 -0
  239. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyURL/config.json +237 -0
  240. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyURL/demo.stories.jsx +46 -0
  241. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyURL/event-utils.js +18 -0
  242. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyURL/index.jsx +232 -0
  243. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyURL/mock.stories.js +22 -0
  244. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyURL/styles.js +14 -0
  245. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyURL/suggestions-handler.js +10 -0
  246. package/tests/assets/components/createAll/Launchpad/Pega_DXIL_MyURL/text-url.jsx +173 -0
  247. package/{src/tasks/init/template/test/functionTest → tests/functional}/localCreateAllListDeleteAll.test.js +13 -7
  248. package/{src/tasks/init/template/test/functionTest → tests/functional}/localCreateBuildAllDeleteAll.test.js +21 -12
  249. package/{src/tasks/init/template/test/functionTest → tests/functional}/localCreateBuildDelete.test.js +7 -7
  250. package/{src/tasks/init/template/test/functionTest → tests/functional}/localCreateListDelete.test.js +8 -8
  251. package/{src/tasks/init/template/test/functionTest → tests/functional}/localCreatePublishAllDeleteAll.test.js +21 -12
  252. package/{src/tasks/init/template/test/functionTest → tests/functional}/localCreatePublishDelete.test.js +8 -7
  253. package/{src/tasks/init/template/test/functionTest → tests/functional}/localCreateRenameDelete.test.js +6 -6
  254. package/{src/tasks/init/template/test/functionTest → tests/functional}/localPromoteRevertWP.test.js +4 -4
  255. package/{test/unitTest → tests/unit}/util.test.js +3 -3
  256. /package/src/tasks/create/templates/Constellation/Field/{TimeOfDay → TimeofDay}/config.json.mustache +0 -0
  257. /package/src/tasks/create/templates/Constellation/Field/{TimeOfDay → TimeofDay}/demo.stories.jsx.mustache +0 -0
  258. /package/src/tasks/create/templates/Constellation/Field/{TimeOfDay → TimeofDay}/mock.stories.js.mustache +0 -0
  259. /package/src/tasks/create/templates/Constellation/Field/{TimeOfDay → TimeofDay}/styles.js.mustache +0 -0
  260. /package/src/tasks/create/templates/Constellation/Field/{TimeOfDay → TimeofDay}/suggestions-handler.js +0 -0
  261. /package/src/tasks/create/templates/Constellation/Field/{TimeOfDay → TimeofDay}/time-of-day.js.mustache +0 -0
  262. /package/src/tasks/{init/template/test/assets/components/createAll/Pega_DXIL_MyCaseWidget → create/templates/Launchpad/Widget/CASE}/OneColumnPage.svg +0 -0
  263. /package/src/tasks/{init/template/test/assets/components/create/Pega_DXIL_MyTestText/styles.js → create/templates/Launchpad/Widget/CASE/styles.js.mustache} +0 -0
  264. /package/src/tasks/{init/template/test/assets/components/createAll/Pega_DXIL_MyPageCaseWidget/Avatar.jsx → create/templates/Launchpad/Widget/PAGE-CASE/Avatar.jsx.mustache} +0 -0
  265. /package/src/tasks/{init/template/test/assets/components/createAll/Pega_DXIL_MyPage → create/templates/Launchpad/Widget/PAGE-CASE}/OneColumnPage.svg +0 -0
  266. /package/src/tasks/{init/template/test/assets/components/createAll/Pega_DXIL_MyPageCaseWidget/mock.stories.js → create/templates/Launchpad/Widget/PAGE-CASE/mock.stories.js.mustache} +0 -0
  267. /package/src/tasks/{init/template/test/assets/components/createAll/Pega_DXIL_MyBoolean/styles.js → create/templates/Launchpad/Widget/PAGE-CASE/styles.js.mustache} +0 -0
  268. /package/{src/tasks/init/template/test → tests}/assets/components/create/Pega_DXIL_MyTestText/config.json +0 -0
  269. /package/{src/tasks/init/template/test → tests}/assets/components/create/Pega_DXIL_MyTestText/demo.stories.jsx +0 -0
  270. /package/{src/tasks/init/template/test → tests}/assets/components/create/Pega_DXIL_MyTestText/mock.stories.js +0 -0
  271. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyCaseWidget → tests/assets/components/create/Pega_DXIL_MyTestText}/styles.js +0 -0
  272. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyBoolean/Boolean.js +0 -0
  273. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyBoolean/boolean-format.js +0 -0
  274. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyBoolean/config.json +0 -0
  275. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyBoolean/demo.stories.jsx +0 -0
  276. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyBoolean/event-utils.js +0 -0
  277. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyBoolean/mock.stories.js +0 -0
  278. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyCurrency → tests/assets/components/createAll/Constellation/Pega_DXIL_MyBoolean}/styles.js +0 -0
  279. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyPageCaseWidget → tests/assets/components/createAll/Constellation/Pega_DXIL_MyCaseWidget}/OneColumnPage.svg +0 -0
  280. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyCaseWidget/demo.stories.jsx +0 -0
  281. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyCaseWidget/index.jsx +0 -0
  282. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyCaseWidget/mock.stories.js +0 -0
  283. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyDate → tests/assets/components/createAll/Constellation/Pega_DXIL_MyCaseWidget}/styles.js +0 -0
  284. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyCurrency/config.json +0 -0
  285. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyCurrency/demo.stories.jsx +0 -0
  286. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyCurrency/event-utils.js +0 -0
  287. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyCurrency/mock.stories.js +0 -0
  288. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyDateTime → tests/assets/components/createAll/Constellation/Pega_DXIL_MyCurrency}/styles.js +0 -0
  289. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyCurrency/suggestions-handler.js +0 -0
  290. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDate/DateFormatter.js +0 -0
  291. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDate/FormattedText.jsx +0 -0
  292. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDate/date.js +0 -0
  293. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDate/demo.stories.jsx +0 -0
  294. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDate/mock.stories.js +0 -0
  295. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyDecimal → tests/assets/components/createAll/Constellation/Pega_DXIL_MyDate}/styles.js +0 -0
  296. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDate/suggestions-handler.js +0 -0
  297. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDateTime/config.json +0 -0
  298. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDateTime/date-time.js +0 -0
  299. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDateTime/date-utils.js +0 -0
  300. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDateTime/date.js +0 -0
  301. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDateTime/demo.stories.jsx +0 -0
  302. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDateTime/mock.stories.js +0 -0
  303. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyDetails → tests/assets/components/createAll/Constellation/Pega_DXIL_MyDateTime}/styles.js +0 -0
  304. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDateTime/suggestions-handler.js +0 -0
  305. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDecimal/config.json +0 -0
  306. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDecimal/demo.stories.jsx +0 -0
  307. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDecimal/event-utils.js +0 -0
  308. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDecimal/mock.stories.js +0 -0
  309. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyEmail → tests/assets/components/createAll/Constellation/Pega_DXIL_MyDecimal}/styles.js +0 -0
  310. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDecimal/suggestions-handler.js +0 -0
  311. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDetails/OneColumnDetails.svg +0 -0
  312. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDetails/StatusWork.jsx +0 -0
  313. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDetails/config.json +0 -0
  314. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDetails/index.jsx +0 -0
  315. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDetails/mock.stories.js +0 -0
  316. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyForm → tests/assets/components/createAll/Constellation/Pega_DXIL_MyDetails}/styles.js +0 -0
  317. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyDetails/utils.js +0 -0
  318. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyEmail/config.json +0 -0
  319. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyEmail/demo.stories.jsx +0 -0
  320. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyEmail/event-utils.js +0 -0
  321. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyEmail/mock.stories.js +0 -0
  322. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyInteger → tests/assets/components/createAll/Constellation/Pega_DXIL_MyEmail}/styles.js +0 -0
  323. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyEmail/suggestions-handler.js +0 -0
  324. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyForm/DefaultForm.svg +0 -0
  325. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyForm/config.json +0 -0
  326. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyForm/mock.stories.js +0 -0
  327. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyPage → tests/assets/components/createAll/Constellation/Pega_DXIL_MyForm}/styles.js +0 -0
  328. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyInteger/config.json +0 -0
  329. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyInteger/demo.stories.jsx +0 -0
  330. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyInteger/event-utils.js +0 -0
  331. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyInteger/mock.stories.js +0 -0
  332. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyPageCaseWidget → tests/assets/components/createAll/Constellation/Pega_DXIL_MyInteger}/styles.js +0 -0
  333. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyInteger/suggestions-handler.js +0 -0
  334. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPage/GetNextWork.jsx +0 -0
  335. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyPageWidget → tests/assets/components/createAll/Constellation/Pega_DXIL_MyPage}/OneColumnPage.svg +0 -0
  336. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPage/config.json +0 -0
  337. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPage/demo.stories.jsx +0 -0
  338. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPage/index.jsx +0 -0
  339. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPage/localizations.json +0 -0
  340. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPage/mock.stories.js +0 -0
  341. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyPageWidget → tests/assets/components/createAll/Constellation/Pega_DXIL_MyPage}/styles.js +0 -0
  342. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPage/utils.js +0 -0
  343. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPageCaseWidget/Operator.jsx +0 -0
  344. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPageCaseWidget/config.json +0 -0
  345. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPageCaseWidget/demo.stories.jsx +0 -0
  346. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPageCaseWidget/index.jsx +0 -0
  347. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyParagraph → tests/assets/components/createAll/Constellation/Pega_DXIL_MyPageCaseWidget}/styles.js +0 -0
  348. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPageWidget/config.json +0 -0
  349. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPageWidget/demo.stories.jsx +0 -0
  350. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPageWidget/index.jsx +0 -0
  351. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPageWidget/mock.stories.js +0 -0
  352. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyPercentage → tests/assets/components/createAll/Constellation/Pega_DXIL_MyPageWidget}/styles.js +0 -0
  353. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyParagraph/config.json +0 -0
  354. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyParagraph/demo.stories.jsx +0 -0
  355. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyParagraph/event-utils.js +0 -0
  356. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyParagraph/mock.stories.js +0 -0
  357. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyPhone → tests/assets/components/createAll/Constellation/Pega_DXIL_MyParagraph}/styles.js +0 -0
  358. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyParagraph/suggestions-handler.js +0 -0
  359. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPercentage/config.json +0 -0
  360. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPercentage/demo.stories.jsx +0 -0
  361. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPercentage/event-utils.js +0 -0
  362. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPercentage/mock.stories.js +0 -0
  363. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyPicklist → tests/assets/components/createAll/Constellation/Pega_DXIL_MyPercentage}/styles.js +0 -0
  364. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPercentage/suggestions-handler.js +0 -0
  365. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPhone/config.json +0 -0
  366. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPhone/demo.stories.jsx +0 -0
  367. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPhone/event-utils.js +0 -0
  368. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPhone/mock.stories.js +0 -0
  369. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyText → tests/assets/components/createAll/Constellation/Pega_DXIL_MyPhone}/styles.js +0 -0
  370. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPhone/suggestions-handler.js +0 -0
  371. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPicklist/config.json +0 -0
  372. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPicklist/demo.stories.jsx +0 -0
  373. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPicklist/event-utils.js +0 -0
  374. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPicklist/mock.stories.js +0 -0
  375. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyTextInput → tests/assets/components/createAll/Constellation/Pega_DXIL_MyPicklist}/styles.js +0 -0
  376. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyPicklist/suggestions-handler.js +0 -0
  377. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyText/config.json +0 -0
  378. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyText/demo.stories.jsx +0 -0
  379. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyText/mock.stories.js +0 -0
  380. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyTimeOfDay → tests/assets/components/createAll/Constellation/Pega_DXIL_MyText}/styles.js +0 -0
  381. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTextInput/StatusWork.jsx +0 -0
  382. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTextInput/config.json +0 -0
  383. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTextInput/demo.stories.jsx +0 -0
  384. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTextInput/event-utils.js +0 -0
  385. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTextInput/mock.stories.js +0 -0
  386. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyTwoColumnDetails → tests/assets/components/createAll/Constellation/Pega_DXIL_MyTextInput}/styles.js +0 -0
  387. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTextInput/suggestions-handler.js +0 -0
  388. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTimeOfDay/config.json +0 -0
  389. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTimeOfDay/demo.stories.jsx +0 -0
  390. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTimeOfDay/mock.stories.js +0 -0
  391. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyTwoColumnForm → tests/assets/components/createAll/Constellation/Pega_DXIL_MyTimeOfDay}/styles.js +0 -0
  392. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTimeOfDay/suggestions-handler.js +0 -0
  393. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTimeOfDay/time-of-day.js +0 -0
  394. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTwoColumnDetails/StatusWork.jsx +0 -0
  395. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTwoColumnDetails/TwoColumnDetails.svg +0 -0
  396. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTwoColumnDetails/config.json +0 -0
  397. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTwoColumnDetails/index.jsx +0 -0
  398. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTwoColumnDetails/mock.stories.js +0 -0
  399. /package/{src/tasks/init/template/test/assets/components/createAll/Pega_DXIL_MyURL → tests/assets/components/createAll/Constellation/Pega_DXIL_MyTwoColumnDetails}/styles.js +0 -0
  400. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTwoColumnDetails/utils.js +0 -0
  401. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTwoColumnForm/TwoColumn.svg +0 -0
  402. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTwoColumnForm/config.json +0 -0
  403. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyTwoColumnForm/mock.stories.js +0 -0
  404. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyURL/config.json +0 -0
  405. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyURL/demo.stories.jsx +0 -0
  406. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyURL/event-utils.js +0 -0
  407. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyURL/mock.stories.js +0 -0
  408. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyURL/suggestions-handler.js +0 -0
  409. /package/{src/tasks/init/template/test/assets/components/createAll → tests/assets/components/createAll/Constellation}/Pega_DXIL_MyURL/text-url.jsx +0 -0
@@ -2,28 +2,28 @@ import path from 'path';
2
2
  import { URL, fileURLToPath } from 'url';
3
3
  import fs from 'fs';
4
4
  import { promisify } from 'util';
5
- import { join } from 'path';
5
+
6
6
 
7
7
  import inquirer from 'inquirer';
8
8
  import ncp from 'ncp';
9
9
  import chalk from 'chalk';
10
10
 
11
- import { checkPathAccess, showVersion } from '../../util.js';
12
-
13
- export const DXCB_CONFIG_INTERNAL_JSON_FILENAME = 'src/dxcb.config.json';
14
-
15
- import {
11
+ // eslint-disable-next-line import/order
12
+ import { checkPathAccess, showVersion ,
16
13
  convertIntoPascalCase,
17
14
  compileMustacheTemplate,
18
15
  getComponentDirectoryPath,
19
- getPegaConfig,
16
+ getPegaServerConfig,
20
17
  getComponents,
21
18
  getComponentDefaults,
22
19
  sanitize,
23
20
  validateSemver
24
21
  } from '../../util.js';
22
+
25
23
  import { COMPONENT_SCHEMA, COMPONENTS_DIRECTORY_PATH, TASKS_CONFIG_JSON_FILENAME, COMPONENTS_PATH, CATEGORY_CONSTELLATION } from '../../constants.js';
26
24
 
25
+ export const DXCB_CONFIG_INTERNAL_JSON_FILENAME = 'src/dxcb.config.json';
26
+
27
27
  const pegaConfigJsonPath = path.join(path.resolve(), TASKS_CONFIG_JSON_FILENAME);
28
28
 
29
29
  const copy = promisify(ncp);
@@ -64,7 +64,8 @@ export const compileMustacheTemplates = async (
64
64
  let mustacheSubType = subtype;
65
65
 
66
66
  // overrides
67
- if (typeof mustacheSubType == 'string') {
67
+ if (typeof mustacheSubType === 'string') {
68
+ // eslint-disable-next-line default-case
68
69
  switch (mustacheSubType) {
69
70
  case 'FORM-region':
70
71
  mustacheSubType = 'FORM';
@@ -113,8 +114,87 @@ export const compileMustacheTemplates = async (
113
114
  });
114
115
  };
115
116
 
117
+ export const validateCompile = async (
118
+ { library, organization, componentName, componentLabel, version, framework, type, subtype, description, allowedApplications },
119
+ options
120
+ ) => {
121
+ let sSubType = subtype;
122
+ if (Array.isArray(subtype)) {
123
+ sSubType = subtype.join('-');
124
+ }
125
+
126
+ // await checkPathAccess(pegaConfigInternalJsonPath);
127
+
128
+ framework = convertIntoPascalCase(CATEGORY_CONSTELLATION);
129
+
130
+ const templateParentDir = `./templates/${framework}`;
131
+
132
+ let templateDir = `${templateParentDir}/${type}/${sSubType}`;
133
+ let templateDirectory = fileURLToPath(new URL(templateDir, import.meta.url));
134
+ templateDirectory = templateDirectory.replace(`${path.sep }create-all`, `${path.sep }create`);
135
+
136
+ const defaultPegaServerConfig = await getPegaServerConfig();
137
+ const isLaunchpad = defaultPegaServerConfig.serverType === 'launchpad';
138
+ const originalFramework = framework;
139
+
140
+ if (isLaunchpad) {
141
+ framework = "Launchpad";
142
+
143
+ templateDir = `./templates/${framework}/${type}/${sSubType}`;
144
+ templateDirectory = fileURLToPath(new URL(templateDir, import.meta.url));
145
+ templateDirectory = templateDirectory.replace(`${path.sep }create-all`, `${path.sep }create`);
146
+
147
+ // if doesn't exist, revert
148
+ if (!fs.existsSync(templateDirectory)) {
149
+ framework = originalFramework;
150
+
151
+ templateDir = `./templates/${framework}/${type}/${sSubType}`;
152
+ templateDirectory = fileURLToPath(new URL(templateDir, import.meta.url));
153
+ templateDirectory = templateDirectory.replace(`${path.sep }create-all`, `${path.sep }create`);
154
+
155
+ }
156
+
157
+ }
158
+
159
+
160
+
161
+ const componentKey = `${organization}_${library}_${componentName}`;
162
+
163
+ const targetDirectory = await getComponentDirectoryPath(componentKey);
164
+
165
+ const components = await getComponents(false);
166
+
167
+ if (components.includes(componentKey)) {
168
+ console.log(chalk.red(`${componentKey} component already exists in ${targetDirectory}`));
169
+
170
+ return;
171
+ }
172
+
173
+ // component
174
+ await copyComponentTemplate({
175
+ ...options,
176
+ targetDirectory,
177
+ templateDirectory
178
+ });
179
+ await compileMustacheTemplates(targetDirectory, {
180
+ componentKey,
181
+ componentName,
182
+ componentLabel,
183
+ library,
184
+ version,
185
+ type,
186
+ subtype,
187
+ description,
188
+ organization,
189
+ allowedApplications
190
+ });
191
+
192
+ console.log(chalk.green(`created ${componentKey} component in ${targetDirectory}`));
193
+ };
194
+
116
195
  export const validateCompileAll = async ({ prefix, library, version, allowedApplications, organization }, options) => {
117
- for (let fieldIdx in COMPONENT_SCHEMA.subtype.field) {
196
+ // eslint-disable-next-line no-restricted-syntax, guard-for-in
197
+ for (const fieldIdx in COMPONENT_SCHEMA.subtype.field) {
118
198
  const type = 'Field';
119
199
  const subtype = COMPONENT_SCHEMA.subtype.field[fieldIdx].value;
120
200
  const prefixNoSpace = prefix.replace(/\s+/g, '');
@@ -123,6 +203,7 @@ export const validateCompileAll = async ({ prefix, library, version, allowedAppl
123
203
  const componentLabel = ''.concat(prefix).concat(' ').concat(COMPONENT_SCHEMA.subtype.field[fieldIdx].name);
124
204
  const description = componentLabel;
125
205
 
206
+ // eslint-disable-next-line no-await-in-loop
126
207
  await validateCompile(
127
208
  {
128
209
  library,
@@ -139,15 +220,16 @@ export const validateCompileAll = async ({ prefix, library, version, allowedAppl
139
220
  );
140
221
  }
141
222
 
142
- for (let templateIdx in COMPONENT_SCHEMA.subtype.template) {
223
+ // eslint-disable-next-line no-restricted-syntax, guard-for-in
224
+ for (const templateIdx in COMPONENT_SCHEMA.subtype.template) {
143
225
  const type = 'Template';
144
226
  const subtype = COMPONENT_SCHEMA.subtype.template[templateIdx].value;
145
227
  const prefixNoSpace = prefix.replace(/\s+/g, '');
146
- let templateNameOriginal = COMPONENT_SCHEMA.subtype.template[templateIdx].name;
228
+ const templateNameOriginal = COMPONENT_SCHEMA.subtype.template[templateIdx].name;
147
229
  let templateName = convertIntoPascalCase(COMPONENT_SCHEMA.subtype.template[templateIdx].name);
148
230
  let templateLabel = convertIntoPascalCase(COMPONENT_SCHEMA.subtype.template[templateIdx].name);
149
231
  if (templateNameOriginal.indexOf('region') >= 0) {
150
- let templateNameBase = convertIntoPascalCase(templateNameOriginal.replace(' region', ''));
232
+ const templateNameBase = convertIntoPascalCase(templateNameOriginal.replace(' region', ''));
151
233
  templateName = 'TwoColumn'.concat(templateNameBase);
152
234
  templateLabel = 'Two Column '.concat(templateNameBase);
153
235
  }
@@ -155,6 +237,7 @@ export const validateCompileAll = async ({ prefix, library, version, allowedAppl
155
237
  const componentLabel = ''.concat(prefix).concat(' ').concat(templateLabel);
156
238
  const description = componentLabel;
157
239
 
240
+ // eslint-disable-next-line no-await-in-loop
158
241
  await validateCompile(
159
242
  {
160
243
  library,
@@ -171,13 +254,14 @@ export const validateCompileAll = async ({ prefix, library, version, allowedAppl
171
254
  );
172
255
  }
173
256
 
174
- for (let widgetIdx in COMPONENT_SCHEMA.subtype.widget) {
257
+ // eslint-disable-next-line no-restricted-syntax, guard-for-in
258
+ for (const widgetIdx in COMPONENT_SCHEMA.subtype.widget) {
175
259
  const type = 'Widget';
176
260
  const subtype = COMPONENT_SCHEMA.subtype.widget[widgetIdx].value;
177
261
  const prefixNoSpace = prefix.replace(/\s+/g, '');
178
- let widgetNameOriginal = COMPONENT_SCHEMA.subtype.widget[widgetIdx].name;
262
+ const widgetNameOriginal = COMPONENT_SCHEMA.subtype.widget[widgetIdx].name;
179
263
  let widgetName = convertIntoPascalCase(COMPONENT_SCHEMA.subtype.widget[widgetIdx].name).concat('Widget');
180
- let widgetLabel = convertIntoPascalCase(COMPONENT_SCHEMA.subtype.widget[widgetIdx].name).concat(' Widget');
264
+ const widgetLabel = convertIntoPascalCase(COMPONENT_SCHEMA.subtype.widget[widgetIdx].name).concat(' Widget');
181
265
  if (widgetName.indexOf('&') >= 0) {
182
266
  widgetName = convertIntoPascalCase(widgetNameOriginal.replace(' & ', ''));
183
267
  }
@@ -185,6 +269,7 @@ export const validateCompileAll = async ({ prefix, library, version, allowedAppl
185
269
  const componentLabel = ''.concat(prefix).concat(' ').concat(widgetLabel);
186
270
  const description = componentLabel;
187
271
 
272
+ // eslint-disable-next-line no-await-in-loop
188
273
  await validateCompile(
189
274
  {
190
275
  library,
@@ -202,61 +287,7 @@ export const validateCompileAll = async ({ prefix, library, version, allowedAppl
202
287
  }
203
288
  };
204
289
 
205
- export const validateCompile = async (
206
- { library, organization, componentName, componentLabel, version, framework, type, subtype, description, allowedApplications },
207
- options
208
- ) => {
209
- let sSubType = subtype;
210
- if (Array.isArray(subtype)) {
211
- sSubType = subtype.join('-');
212
- }
213
-
214
- const typeLC = type.toLowerCase();
215
-
216
- //await checkPathAccess(pegaConfigInternalJsonPath);
217
-
218
- framework = convertIntoPascalCase(CATEGORY_CONSTELLATION);
219
-
220
- let pegaConfig = await getPegaConfig();
221
- let templateParentDir = `./templates/${framework}`;
222
290
 
223
- const templateDir = `${templateParentDir}/${type}/${sSubType}`;
224
- let templateDirectory = fileURLToPath(new URL(templateDir, import.meta.url));
225
- templateDirectory = templateDirectory.replace(path.sep + 'create-all', path.sep + 'create');
226
-
227
- const componentKey = `${organization}_${library}_${componentName}`;
228
-
229
- const targetDirectory = await getComponentDirectoryPath(componentKey);
230
-
231
- const components = await getComponents(false);
232
-
233
- if (components.includes(componentKey)) {
234
- console.log(chalk.red(`${componentKey} component already exists in ${targetDirectory}`));
235
-
236
- return;
237
- }
238
-
239
- // component
240
- await copyComponentTemplate({
241
- ...options,
242
- targetDirectory,
243
- templateDirectory
244
- });
245
- await compileMustacheTemplates(targetDirectory, {
246
- componentKey,
247
- componentName,
248
- componentLabel,
249
- library,
250
- version,
251
- type,
252
- subtype,
253
- description,
254
- organization,
255
- allowedApplications
256
- });
257
-
258
- console.log(chalk.green(`created ${componentKey} component in ${targetDirectory}`));
259
- };
260
291
 
261
292
  export default async (options) => {
262
293
  showVersion();
@@ -273,16 +304,17 @@ export default async (options) => {
273
304
 
274
305
  const componentData = data[COMPONENTS_PATH];
275
306
 
276
- const { library } = componentData;
307
+ let library;
308
+ ({ library } = componentData);
277
309
  let { organization } = JSON.parse(fs.readFileSync(path.resolve('package.json'), 'utf8'));
278
310
 
279
- let componentDefaults = await getComponentDefaults();
311
+ const componentDefaults = await getComponentDefaults();
280
312
  componentDefaults.library = library;
281
313
 
282
314
  if (options.params.length >= 8) {
283
315
  const prefix = options.params[3];
284
316
  const version = options.params[4];
285
- const library = options.params[5];
317
+ library = options.params[5];
286
318
  const allowedApplications = options.params[6];
287
319
 
288
320
  // overwrite
@@ -339,7 +371,8 @@ export default async (options) => {
339
371
  ];
340
372
 
341
373
  await inquirer.prompt(questions).then(async (answers) => {
342
- const { library, version, allowedApplications } = answers;
374
+ ({library} = answers);
375
+ const { version, allowedApplications } = answers;
343
376
  let { prefix } = answers;
344
377
  prefix = prefix.replace(/[^a-zA-Z0-9 ]/g, '');
345
378
  await validateCompileAll(
@@ -1,22 +1,33 @@
1
+ import fs from 'fs';
1
2
  import chalk from 'chalk';
2
3
  import inquirer from 'inquirer';
3
4
  import ora from 'ora';
4
5
 
6
+ import path from 'path';
7
+ import { join } from 'path';
8
+
5
9
  import {
6
10
  deleteLocalComponent,
7
11
  deleteInfinityServerComponent,
8
12
  deleteLaunchpadServerComponent,
9
13
  getComponents,
10
14
  getPegaServerConfig,
11
- standardizeStr
15
+ standardizeStr,
16
+ sanitize
12
17
  } from '../../util.js';
13
18
  import { getComponentsFromServer } from '../list/helper.js';
14
19
 
20
+ import { TASKS_CONFIG_JSON_FILENAME, COMPONENTS_DIRECTORY_PATH, COMPONENTS_PATH } from '../../constants.js';
21
+
15
22
  export const SOURCE_OF_COMPONENT_TYPES = {
16
23
  SERVER: 'Server',
17
24
  LOCAL: 'Local'
18
25
  };
19
26
 
27
+ let library;
28
+ let organization;
29
+
30
+
20
31
  export const getDeleteComponentsQuestions = async (options) => {
21
32
  const defaultPegaServerConfig = await getPegaServerConfig();
22
33
 
@@ -34,6 +45,53 @@ export const getDeleteComponentsQuestions = async (options) => {
34
45
  ];
35
46
  };
36
47
 
48
+ export const getLaunchPadFilterQuestions = async () => {
49
+ const defaultPegaServerConfig = await getPegaServerConfig();
50
+
51
+ const currentDirectory = process.cwd();
52
+ const pegaConfigJsonPath = join(currentDirectory, TASKS_CONFIG_JSON_FILENAME);
53
+
54
+ let data = fs.readFileSync(pegaConfigJsonPath, { encoding: 'utf8' });
55
+ data = data && JSON.parse(data);
56
+
57
+ if (!data[COMPONENTS_DIRECTORY_PATH]) {
58
+ console.error(
59
+ `${chalk.red.bold('ERROR')} Could not able find components directory path in config.json`
60
+ );
61
+ process.exit(1);
62
+ }
63
+
64
+ const componentData = data[COMPONENTS_PATH];
65
+
66
+ ({ library } = componentData);
67
+ ({ organization } = JSON.parse(fs.readFileSync(path.resolve('package.json'), 'utf8')));
68
+
69
+ return [
70
+ {
71
+ name: 'organization',
72
+ message: 'Enter component organization (required)',
73
+ default: organization,
74
+ validate: value => {
75
+ if (value) {
76
+ return true;
77
+ }
78
+ return 'Please provide value for organization';
79
+ }
80
+ },
81
+ {
82
+ name: 'library',
83
+ message: 'Enter library name (required)',
84
+ default: library,
85
+ validate: value => {
86
+ if (value) {
87
+ return true;
88
+ }
89
+ return 'Please provide value for library';
90
+ }
91
+ }
92
+ ];
93
+ }
94
+
37
95
  export const deleteLocalComponents = async (sourceOfComponents, options) => {
38
96
  const localComponents = await getComponents();
39
97
 
@@ -70,14 +128,27 @@ export const deleteLocalComponents = async (sourceOfComponents, options) => {
70
128
  };
71
129
 
72
130
  export const deleteServerComponents = async (sourceOfComponents, answers) => {
73
- const spinner = ora('Fetching components from server').start();
131
+
74
132
  const defaultPegaServerConfig = await getPegaServerConfig();
75
133
  const isLaunchpad = defaultPegaServerConfig.serverType === 'launchpad';
76
- const data = await getComponentsFromServer(answers);
134
+
135
+
136
+ if (isLaunchpad) {
137
+ const questions = await getLaunchPadFilterQuestions();
138
+ const lpAnswers = await inquirer.prompt(questions);
139
+
140
+ ({library, organization} = lpAnswers);
141
+ }
142
+
143
+ const spinner = ora('Fetching components from server').start();
144
+ const data = await getComponentsFromServer(library, organization);
145
+ spinner.stop();
146
+
77
147
 
78
148
  let serverComponents;
79
149
  if (isLaunchpad) {
80
150
  serverComponents = data;
151
+
81
152
  } else {
82
153
  try {
83
154
  if (typeof data === 'object') {
@@ -89,7 +160,7 @@ export const deleteServerComponents = async (sourceOfComponents, answers) => {
89
160
  /* empty */
90
161
  }
91
162
  }
92
- spinner.stop();
163
+
93
164
 
94
165
  if (serverComponents && serverComponents?.length > 0) {
95
166
  if (isLaunchpad) {
@@ -1,3 +1,6 @@
1
+ import fs from 'fs';
2
+ import path, {join} from 'path';
3
+
1
4
  import chalk from 'chalk';
2
5
  import inquirer from 'inquirer';
3
6
  import ora from 'ora';
@@ -12,12 +15,17 @@ import {
12
15
  validateRulesetVersion
13
16
  } from '../../util.js';
14
17
  import { getComponentsFromServer } from '../list/helper.js';
18
+ import { TASKS_CONFIG_JSON_FILENAME, COMPONENTS_DIRECTORY_PATH, COMPONENTS_PATH } from '../../constants.js';
15
19
 
16
20
  export const SOURCE_OF_COMPONENT_TYPES = {
17
21
  SERVER: 'Server',
18
22
  LOCAL: 'Local'
19
23
  };
20
24
 
25
+ let library;
26
+ let organization;
27
+
28
+
21
29
  export const getDeleteComponentsQuestions = async (options) => {
22
30
  const defaultPegaServerConfig = await getPegaServerConfig();
23
31
 
@@ -35,6 +43,51 @@ export const getDeleteComponentsQuestions = async (options) => {
35
43
  ];
36
44
  };
37
45
 
46
+ export const getLaunchPadFilterQuestions = async () => {
47
+ const currentDirectory = process.cwd();
48
+ const pegaConfigJsonPath = join(currentDirectory, TASKS_CONFIG_JSON_FILENAME);
49
+
50
+ let data = fs.readFileSync(pegaConfigJsonPath, { encoding: 'utf8' });
51
+ data = data && JSON.parse(data);
52
+
53
+ if (!data[COMPONENTS_DIRECTORY_PATH]) {
54
+ console.error(
55
+ `${chalk.red.bold('ERROR')} Could not able find components directory path in config.json`
56
+ );
57
+ process.exit(1);
58
+ }
59
+
60
+ const componentData = data[COMPONENTS_PATH];
61
+
62
+ ({ library } = componentData);
63
+ ({ organization } = JSON.parse(fs.readFileSync(path.resolve('package.json'), 'utf8')));
64
+
65
+ return [
66
+ {
67
+ name: 'organization',
68
+ message: 'Enter component organization (required)',
69
+ default: organization,
70
+ validate: value => {
71
+ if (value) {
72
+ return true;
73
+ }
74
+ return 'Please provide value for organization';
75
+ }
76
+ },
77
+ {
78
+ name: 'library',
79
+ message: 'Enter library name (required)',
80
+ default: library,
81
+ validate: value => {
82
+ if (value) {
83
+ return true;
84
+ }
85
+ return 'Please provide value for library';
86
+ }
87
+ }
88
+ ];
89
+ }
90
+
38
91
  export const deleteLocalComponents = async (sourceOfComponents, options) => {
39
92
  const localComponents = await getComponents();
40
93
 
@@ -79,10 +132,21 @@ export const deleteLocalComponents = async (sourceOfComponents, options) => {
79
132
  };
80
133
 
81
134
  export const deleteServerComponents = async (sourceOfComponents, answers) => {
82
- const spinner = ora('Fetching components from server').start();
135
+
83
136
  const defaultPegaServerConfig = await getPegaServerConfig();
84
137
  const isLaunchpad = defaultPegaServerConfig.serverType === 'launchpad';
85
- const data = await getComponentsFromServer(answers);
138
+
139
+ if (isLaunchpad) {
140
+ const questions = await getLaunchPadFilterQuestions();
141
+ const lpAnswers = await inquirer.prompt(questions);
142
+
143
+ ({library, organization} = lpAnswers);
144
+ }
145
+
146
+ const spinner = ora('Fetching components from server').start();
147
+ const data = await getComponentsFromServer(library, organization);
148
+ spinner.stop();
149
+
86
150
 
87
151
  // const serverComponents = isLaunchpad ? data : data.pxResults;
88
152
  let serverComponents;
@@ -100,7 +164,7 @@ export const deleteServerComponents = async (sourceOfComponents, answers) => {
100
164
  }
101
165
  }
102
166
 
103
- spinner.stop();
167
+
104
168
 
105
169
  if (serverComponents && serverComponents?.length > 0) {
106
170
  if (isLaunchpad) {
@@ -27,7 +27,12 @@
27
27
  "lint:es": "eslint .",
28
28
  "lint:styles": "stylelint \"./**/*.@(js|jsx|ts|tsx)\"",
29
29
  "lint:format": "prettier -c .",
30
- "lint:spelling": "cspell --no-progress **/*"
30
+ "lint:spelling": "cspell --no-progress **/*",
31
+ "test": "echo 'Running functional and unit tests will DELETE existing local components, proceed (y/n)?' && read proceed && if test \"$proceed\" = \"y\"; then npm run test:full; fi ",
32
+ "test:full": "npm run test:functional && npm run test:unit",
33
+ "test:functional": "npm run test:functional:local --prefix node_modules/@pega/custom-dx-components",
34
+ "test-coverage": "node --input-type=module --experimental-vm-modules node_modules/jest/bin/jest.js --runInBand node_modules/@pega/custom-dx-component --ci --testResultsProcessor='jest-junit' --coverage",
35
+ "test:unit": "npm run test:unit:local --prefix node_modules/@pega/custom-dx-components"
31
36
  },
32
37
  "scriptsComments": {
33
38
  "build": "tsc -b tsconfig.build.json",
@@ -46,8 +51,8 @@
46
51
  "license": "Enter License",
47
52
  "sideEffects": false,
48
53
  "dependencies": {
49
- "@pega/cosmos-react-core": "^3.0.11",
50
- "@pega/cosmos-react-work": "3.0.11",
54
+ "@pega/cosmos-react-core": "^4.0.1",
55
+ "@pega/cosmos-react-work": "4.0.1",
51
56
  "dayjs": "^1.11.5",
52
57
  "polished": "^4.2.2",
53
58
  "prop-types": "^15.8.1",
@@ -61,7 +66,7 @@
61
66
  },
62
67
  "devDependencies": {
63
68
  "@pega/configs": "^0.5.3",
64
- "@pega/custom-dx-components": "^8.8.19",
69
+ "@pega/custom-dx-components": "^23.1.10",
65
70
  "@pega/eslint-config": "^0.3.2",
66
71
  "@storybook/addon-actions": "^6.5.12",
67
72
  "@storybook/addon-essentials": "^6.5.12",
@@ -1,16 +1,22 @@
1
1
  import fs from 'fs';
2
-
2
+ import path from 'path';
3
3
  import chalk from 'chalk';
4
4
  import fetch from 'node-fetch';
5
+ import { join } from 'path';
6
+ import ora from 'ora';
7
+
8
+ import inquirer from 'inquirer';
5
9
 
6
- import { LIST_COMPONENT_SERVICE_REST_ENDPOINT, LP_LIST_COMPONENT_SERVICE_REST_ENDPOINT, TOKEN_PATH, COMPONENT_SCHEMA } from '../../constants.js';
7
- import { constructCompleteUrl, getComponents, getPegaServerConfig, getHttpsAgent } from '../../util.js';
10
+ import { LIST_COMPONENT_SERVICE_REST_ENDPOINT, LP_LIST_COMPONENT_SERVICE_REST_ENDPOINT, TOKEN_PATH, COMPONENT_SCHEMA, TASKS_CONFIG_JSON_FILENAME, COMPONENTS_DIRECTORY_PATH, COMPONENTS_PATH } from '../../constants.js';
11
+ import { constructCompleteUrl, getComponents, getPegaServerConfig, getHttpsAgent, sanitize } from '../../util.js';
8
12
 
9
13
  export const SOURCE_OF_COMPONENT_TYPES = {
10
14
  SERVER: 'Server',
11
15
  LOCAL: 'Local'
12
16
  };
13
17
 
18
+
19
+
14
20
  export const getListComponentsQuestions = async (options) => {
15
21
  const defaultPegaServerConfig = await getPegaServerConfig();
16
22
 
@@ -28,6 +34,52 @@ export const getListComponentsQuestions = async (options) => {
28
34
  ];
29
35
  };
30
36
 
37
+ export const getLaunchPadFilterQuestions = async () => {
38
+ const defaultPegaServerConfig = await getPegaServerConfig();
39
+ const currentDirectory = process.cwd();
40
+ const pegaConfigJsonPath = join(currentDirectory, TASKS_CONFIG_JSON_FILENAME);
41
+
42
+ let data = fs.readFileSync(pegaConfigJsonPath, { encoding: 'utf8' });
43
+ data = data && JSON.parse(data);
44
+
45
+ if (!data[COMPONENTS_DIRECTORY_PATH]) {
46
+ console.error(
47
+ `${chalk.red.bold('ERROR')} Could not able find components directory path in config.json`
48
+ );
49
+ process.exit(1);
50
+ }
51
+
52
+ const componentData = data[COMPONENTS_PATH];
53
+
54
+ let { library } = componentData;
55
+ let { organization } = JSON.parse(fs.readFileSync(path.resolve('package.json'), 'utf8'));
56
+
57
+ return [
58
+ {
59
+ name: 'organization',
60
+ message: 'Enter component organization (required)',
61
+ default: organization,
62
+ validate: value => {
63
+ if (value) {
64
+ return true;
65
+ }
66
+ return 'Please provide value for organization';
67
+ }
68
+ },
69
+ {
70
+ name: 'library',
71
+ message: 'Enter library name (required)',
72
+ default: library,
73
+ validate: value => {
74
+ if (value) {
75
+ return true;
76
+ }
77
+ return 'Please provide value for library';
78
+ }
79
+ }
80
+ ];
81
+ }
82
+
31
83
  export const listLocalComponents = async (sourceOfComponents) => {
32
84
  let localComponents = await getComponents();
33
85
  localComponents = localComponents.map((name) => ({ 'Rule name': name }));
@@ -109,13 +161,16 @@ async function fetchComponentsFromLaunchpad(apiUrl, headers) {
109
161
  });
110
162
  }
111
163
 
112
- export const getComponentsFromServer = async () => {
164
+ export const getComponentsFromServer = async (library, organization) => {
113
165
  const defaultPegaServerConfig = await getPegaServerConfig();
114
166
  const isLaunchpad = defaultPegaServerConfig.serverType === 'launchpad';
115
167
  const url = constructCompleteUrl(
116
168
  defaultPegaServerConfig.server,
117
169
  isLaunchpad ? LP_LIST_COMPONENT_SERVICE_REST_ENDPOINT : LIST_COMPONENT_SERVICE_REST_ENDPOINT
118
170
  );
171
+
172
+
173
+
119
174
  return new Promise((resolve, reject) => {
120
175
  try {
121
176
  fs.readFile(TOKEN_PATH, 'utf8', (err, data) => {
@@ -132,7 +187,10 @@ export const getComponentsFromServer = async () => {
132
187
  headers.cookie = `Pega-AAT=${accessToken}`;
133
188
 
134
189
  fetchComponentsFromLaunchpad(url, headers)
135
- .then((response) => resolve(response))
190
+ .then((response) => {
191
+ response = response.filter(component => (component.library === library || library === "*" ) && (component.organization === organization || organization === "*"));
192
+ resolve(response); }
193
+ )
136
194
  .catch((e) => reject(e));
137
195
  } else {
138
196
  headers.Authorization = `${tokenType} ${accessToken}`;