@pega/dx-component-builder-sdk 0.1.47 → 0.1.49

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 (268) hide show
  1. package/package.json +3 -2
  2. package/src/auth.js +726 -508
  3. package/src/cli.js +1 -1
  4. package/src/constants.js +728 -2
  5. package/src/tasks/authenticate/index.js +12 -2
  6. package/src/tasks/build/helper.js +10 -6
  7. package/src/tasks/build/index.js +76 -22
  8. package/src/tasks/build-all/helper.js +16 -11
  9. package/src/tasks/build-all/index.js +106 -42
  10. package/src/tasks/bundle/{builder → builderAngular}/paths.js +3 -2
  11. package/src/tasks/bundle/builderAngular/webpack.config.js +342 -0
  12. package/src/tasks/bundle/builderAssociated/index.js +218 -0
  13. package/src/tasks/bundle/builderAssociated/modules.js +139 -0
  14. package/src/tasks/bundle/builderAssociated/paths.js +51 -0
  15. package/src/tasks/bundle/{builder → builderAssociated}/webpack.config.js +5 -4
  16. package/src/tasks/bundle/builderReact/index.js +218 -0
  17. package/src/tasks/bundle/builderReact/modules.js +139 -0
  18. package/src/tasks/bundle/builderReact/paths.js +51 -0
  19. package/src/tasks/bundle/builderReact/webpack.config.js +337 -0
  20. package/src/tasks/bundle/index.js +122 -5
  21. package/src/tasks/create/index.js +54 -12
  22. package/src/tasks/create/templates/Constellation/field/Boolean/styles.js.mustache +13 -6
  23. package/src/tasks/create/templates/Constellation/field/Date/DateFormatter.js.mustache +7 -7
  24. package/src/tasks/create/templates/Constellation/field/Date/date.js.mustache +8 -8
  25. package/src/tasks/create/templates/Constellation/field/Date/styles.js.mustache +13 -6
  26. package/src/tasks/create/templates/Constellation/field/DateTime/date-time.js.mustache +10 -10
  27. package/src/tasks/create/templates/Constellation/field/DateTime/date-utils.js.mustache +6 -5
  28. package/src/tasks/create/templates/Constellation/field/DateTime/date.js.mustache +6 -3
  29. package/src/tasks/create/templates/Constellation/field/DateTime/styles.js.mustache +13 -6
  30. package/src/tasks/create/templates/Constellation/field/Decimal/index.jsx.mustache +2 -2
  31. package/src/tasks/create/templates/Constellation/field/Decimal/styles.js.mustache +13 -6
  32. package/src/tasks/create/templates/Constellation/field/Decimal-Currency/index.jsx.mustache +2 -2
  33. package/src/tasks/create/templates/Constellation/field/Decimal-Currency/styles.js.mustache +13 -6
  34. package/src/tasks/create/templates/Constellation/field/Decimal-Percentage/index.jsx.mustache +4 -4
  35. package/src/tasks/create/templates/Constellation/field/Decimal-Percentage/styles.js.mustache +13 -6
  36. package/src/tasks/create/templates/Constellation/field/Integer/index.jsx.mustache +2 -2
  37. package/src/tasks/create/templates/Constellation/field/Integer/styles.js.mustache +13 -6
  38. package/src/tasks/create/templates/Constellation/field/Picklist/styles.js.mustache +13 -6
  39. package/src/tasks/create/templates/Constellation/field/Text/styles.js.mustache +13 -6
  40. package/src/tasks/create/templates/Constellation/field/Text-Email/styles.js.mustache +13 -6
  41. package/src/tasks/create/templates/Constellation/field/Text-Input/styles.js.mustache +13 -6
  42. package/src/tasks/create/templates/Constellation/field/Text-Paragraph/styles.js.mustache +13 -6
  43. package/src/tasks/create/templates/Constellation/field/Text-Phone/index.jsx.mustache +0 -1
  44. package/src/tasks/create/templates/Constellation/field/Text-Phone/styles.js.mustache +13 -6
  45. package/src/tasks/create/templates/Constellation/field/Text-URL/styles.js.mustache +13 -6
  46. package/src/tasks/create/templates/Constellation/field/TimeOfDay/styles.js.mustache +14 -0
  47. package/src/tasks/create/templates/Constellation/field/{TimeofDay → TimeOfDay}/time-of-day.js.mustache +6 -5
  48. package/src/tasks/create/templates/Constellation/template/DETAILS/demo.stories.jsx.mustache +20 -6
  49. package/src/tasks/create/templates/Constellation/template/DETAILS/index.jsx.mustache +2 -2
  50. package/src/tasks/create/templates/Constellation/template/DETAILS/mock.stories.js.mustache +20 -10
  51. package/src/tasks/create/templates/Constellation/template/DETAILS/styles.js.mustache +13 -6
  52. package/src/tasks/create/templates/Constellation/template/DETAILS-region/demo.stories.jsx.mustache +20 -7
  53. package/src/tasks/create/templates/Constellation/template/DETAILS-region/index.jsx.mustache +2 -2
  54. package/src/tasks/create/templates/Constellation/template/DETAILS-region/mock.stories.js.mustache +28 -13
  55. package/src/tasks/create/templates/Constellation/template/DETAILS-region/styles.js.mustache +13 -6
  56. package/src/tasks/create/templates/Constellation/template/FORM/demo.stories.jsx.mustache +92 -16
  57. package/src/tasks/create/templates/Constellation/template/FORM/index.jsx.mustache +2 -2
  58. package/src/tasks/create/templates/Constellation/template/FORM/mock.stories.js.mustache +24 -12
  59. package/src/tasks/create/templates/Constellation/template/FORM/styles.js.mustache +13 -6
  60. package/src/tasks/create/templates/Constellation/template/FORM-region/demo.stories.jsx.mustache +91 -13
  61. package/src/tasks/create/templates/Constellation/template/FORM-region/index.jsx.mustache +2 -2
  62. package/src/tasks/create/templates/Constellation/template/FORM-region/mock.stories.js.mustache +24 -12
  63. package/src/tasks/create/templates/Constellation/template/FORM-region/styles.js.mustache +13 -6
  64. package/src/tasks/create/templates/Constellation/template/PAGE/demo.stories.jsx.mustache +1 -0
  65. package/src/tasks/create/templates/Constellation/template/PAGE/styles.js.mustache +13 -6
  66. package/src/tasks/create/templates/Constellation/widget/CASE/index.jsx.mustache +2 -2
  67. package/src/tasks/create/templates/Constellation/widget/CASE/styles.js.mustache +13 -6
  68. package/src/tasks/create/templates/Constellation/widget/PAGE/styles.js.mustache +13 -6
  69. package/src/tasks/create/templates/Constellation/widget/PAGE-CASE/Operator.jsx.mustache +2 -2
  70. package/src/tasks/create/templates/Constellation/widget/PAGE-CASE/index.jsx.mustache +2 -2
  71. package/src/tasks/create/templates/Constellation/widget/PAGE-CASE/styles.js.mustache +13 -6
  72. package/src/tasks/create/templates/SDK-Angular/field/Boolean/boolean.component.html.mustache +42 -0
  73. package/src/tasks/create/templates/SDK-Angular/field/Boolean/boolean.component.scss.mustache +24 -0
  74. package/src/tasks/create/templates/SDK-Angular/field/Boolean/boolean.component.spec.ts.mustache +25 -0
  75. package/src/tasks/create/templates/SDK-Angular/field/Boolean/boolean.component.ts.mustache +165 -0
  76. package/src/tasks/create/templates/SDK-Angular/field/Boolean/config.json.mustache +87 -0
  77. package/src/tasks/create/templates/SDK-Angular/field/Boolean/demo.stories.jsx.mustache +56 -0
  78. package/src/tasks/create/templates/SDK-Angular/field/Boolean/mock.stories.js.mustache +15 -0
  79. package/src/tasks/create/templates/SDK-Angular/field/Date/config.json.mustache +147 -0
  80. package/src/tasks/create/templates/SDK-Angular/field/Date/date.component.html.mustache +35 -0
  81. package/src/tasks/create/templates/SDK-Angular/field/Date/date.component.scss.mustache +20 -0
  82. package/src/tasks/create/templates/SDK-Angular/field/Date/date.component.spec.ts.mustache +25 -0
  83. package/src/tasks/create/templates/SDK-Angular/field/Date/date.component.ts.mustache +209 -0
  84. package/src/tasks/create/templates/SDK-Angular/field/DateTime/config.json.mustache +204 -0
  85. package/src/tasks/create/templates/SDK-Angular/field/DateTime/date-time.component.html.mustache +31 -0
  86. package/src/tasks/create/templates/SDK-Angular/field/DateTime/date-time.component.scss.mustache +20 -0
  87. package/src/tasks/create/templates/SDK-Angular/field/DateTime/date-time.component.spec.ts.mustache +25 -0
  88. package/src/tasks/create/templates/SDK-Angular/field/DateTime/date-time.component.ts.mustache +177 -0
  89. package/src/tasks/create/templates/SDK-Angular/field/Decimal/config.json.mustache +94 -0
  90. package/src/tasks/create/templates/SDK-Angular/field/Decimal/decimal.component.html.mustache +32 -0
  91. package/src/tasks/create/templates/SDK-Angular/field/Decimal/decimal.component.scss.mustache +20 -0
  92. package/src/tasks/create/templates/SDK-Angular/field/Decimal/decimal.component.spec.ts.mustache +25 -0
  93. package/src/tasks/create/templates/SDK-Angular/field/Decimal/decimal.component.ts.mustache +170 -0
  94. package/src/tasks/create/templates/SDK-Angular/field/Decimal-Currency/config.json.mustache +125 -0
  95. package/src/tasks/create/templates/SDK-Angular/field/Decimal-Currency/decimal-currency.component.html.mustache +33 -0
  96. package/src/tasks/create/templates/SDK-Angular/field/Decimal-Currency/decimal-currency.component.scss.mustache +20 -0
  97. package/src/tasks/create/templates/SDK-Angular/field/Decimal-Currency/decimal-currency.component.spec.ts.mustache +25 -0
  98. package/src/tasks/create/templates/SDK-Angular/field/Decimal-Currency/decimal-currency.component.ts.mustache +175 -0
  99. package/src/tasks/create/templates/SDK-Angular/field/Decimal-Percentage/config.json.mustache +94 -0
  100. package/src/tasks/create/templates/SDK-Angular/field/Decimal-Percentage/decimal-percentage.component.html.mustache +33 -0
  101. package/src/tasks/create/templates/SDK-Angular/field/Decimal-Percentage/decimal-percentage.component.scss.mustache +20 -0
  102. package/src/tasks/create/templates/SDK-Angular/field/Decimal-Percentage/decimal-percentage.component.spec.ts.mustache +25 -0
  103. package/src/tasks/create/templates/SDK-Angular/field/Decimal-Percentage/decimal-percentage.component.ts.mustache +176 -0
  104. package/src/tasks/create/templates/SDK-Angular/field/Integer/config.json.mustache +88 -0
  105. package/src/tasks/create/templates/SDK-Angular/field/Integer/integer.component.html.mustache +33 -0
  106. package/src/tasks/create/templates/SDK-Angular/field/Integer/integer.component.scss.mustache +20 -0
  107. package/src/tasks/create/templates/SDK-Angular/field/Integer/integer.component.spec.ts.mustache +25 -0
  108. package/src/tasks/create/templates/SDK-Angular/field/Integer/integer.component.ts.mustache +180 -0
  109. package/src/tasks/create/templates/SDK-Angular/field/Picklist/config.json.mustache +86 -0
  110. package/src/tasks/create/templates/SDK-Angular/field/Picklist/picklist.component.html.mustache +30 -0
  111. package/src/tasks/create/templates/SDK-Angular/field/Picklist/picklist.component.scss.mustache +25 -0
  112. package/src/tasks/create/templates/SDK-Angular/field/Picklist/picklist.component.spec.ts.mustache +25 -0
  113. package/src/tasks/create/templates/SDK-Angular/field/Picklist/picklist.component.ts.mustache +195 -0
  114. package/src/tasks/create/templates/SDK-Angular/field/Text/config.json.mustache +83 -0
  115. package/src/tasks/create/templates/SDK-Angular/field/Text/text.component.html.mustache +17 -0
  116. package/src/tasks/create/templates/SDK-Angular/field/Text/text.component.scss.mustache +30 -0
  117. package/src/tasks/create/templates/SDK-Angular/field/Text/text.component.spec.ts.mustache +25 -0
  118. package/src/tasks/create/templates/SDK-Angular/field/Text/text.component.ts.mustache +145 -0
  119. package/src/tasks/create/templates/SDK-Angular/field/Text-Email/config.json.mustache +83 -0
  120. package/src/tasks/create/templates/SDK-Angular/field/Text-Email/text-email.component.html.mustache +31 -0
  121. package/src/tasks/create/templates/SDK-Angular/field/Text-Email/text-email.component.scss.mustache +20 -0
  122. package/src/tasks/create/templates/SDK-Angular/field/Text-Email/text-email.component.spec.ts.mustache +25 -0
  123. package/src/tasks/create/templates/SDK-Angular/field/Text-Email/text-email.component.ts.mustache +175 -0
  124. package/src/tasks/create/templates/SDK-Angular/field/Text-Input/config.json.mustache +83 -0
  125. package/src/tasks/create/templates/SDK-Angular/field/Text-Input/text.component.html.mustache +31 -0
  126. package/src/tasks/create/templates/SDK-Angular/field/Text-Input/text.component.scss.mustache +20 -0
  127. package/src/tasks/create/templates/SDK-Angular/field/Text-Input/text.component.spec.ts.mustache +25 -0
  128. package/src/tasks/create/templates/SDK-Angular/field/Text-Input/text.component.ts.mustache +177 -0
  129. package/src/tasks/create/templates/SDK-Angular/field/Text-Paragraph/config.json.mustache +83 -0
  130. package/src/tasks/create/templates/SDK-Angular/field/Text-Paragraph/text-paragraph.component.html.mustache +31 -0
  131. package/src/tasks/create/templates/SDK-Angular/field/Text-Paragraph/text-paragraph.component.scss.mustache +20 -0
  132. package/src/tasks/create/templates/SDK-Angular/field/Text-Paragraph/text-paragraph.component.spec.ts.mustache +25 -0
  133. package/src/tasks/create/templates/SDK-Angular/field/Text-Paragraph/text-paragraph.component.ts.mustache +179 -0
  134. package/src/tasks/create/templates/SDK-Angular/field/Text-Phone/config.json.mustache +95 -0
  135. package/src/tasks/create/templates/SDK-Angular/field/Text-Phone/text-phone.component.html.mustache +30 -0
  136. package/src/tasks/create/templates/SDK-Angular/field/Text-Phone/text-phone.component.scss.mustache +81 -0
  137. package/src/tasks/create/templates/SDK-Angular/field/Text-Phone/text-phone.component.spec.ts.mustache +25 -0
  138. package/src/tasks/create/templates/SDK-Angular/field/Text-Phone/text-phone.component.ts.mustache +194 -0
  139. package/src/tasks/create/templates/SDK-Angular/field/Text-URL/config.json.mustache +111 -0
  140. package/src/tasks/create/templates/SDK-Angular/field/Text-URL/text-url.component.html.mustache +30 -0
  141. package/src/tasks/create/templates/SDK-Angular/field/Text-URL/text-url.component.scss.mustache +20 -0
  142. package/src/tasks/create/templates/SDK-Angular/field/Text-URL/text-url.component.spec.ts.mustache +26 -0
  143. package/src/tasks/create/templates/SDK-Angular/field/Text-URL/text-url.component.ts.mustache +174 -0
  144. package/src/tasks/create/templates/SDK-Angular/field/TimeOfDay/time-of-day.component.html.mustache +30 -0
  145. package/src/tasks/create/templates/SDK-Angular/field/TimeOfDay/time-of-day.component.scss.mustache +20 -0
  146. package/src/tasks/create/templates/SDK-Angular/field/TimeOfDay/time-of-day.component.spec.ts.mustache +25 -0
  147. package/src/tasks/create/templates/SDK-Angular/field/TimeOfDay/time-of-day.component.ts.mustache +172 -0
  148. package/src/tasks/create/templates/SDK-Angular/template/DETAILS/DefaultForm.svg +29 -0
  149. package/src/tasks/create/templates/SDK-Angular/template/DETAILS/config.json.mustache +21 -0
  150. package/src/tasks/create/templates/SDK-Angular/template/DETAILS/demo.stories.jsx.mustache +71 -0
  151. package/src/tasks/create/templates/SDK-Angular/template/DETAILS/details.component.html.mustache +7 -0
  152. package/src/tasks/create/templates/SDK-Angular/template/DETAILS/details.component.scss.mustache +7 -0
  153. package/src/tasks/create/templates/SDK-Angular/template/DETAILS/details.component.spec.ts.mustache +25 -0
  154. package/src/tasks/create/templates/SDK-Angular/template/DETAILS/details.component.ts.mustache +121 -0
  155. package/src/tasks/create/templates/SDK-Angular/template/DETAILS/mock.stories.js.mustache +294 -0
  156. package/src/tasks/create/templates/SDK-Angular/template/DETAILS-region/TwoColumnDetails.svg +28 -0
  157. package/src/tasks/create/templates/SDK-Angular/template/DETAILS-region/config.json.mustache +27 -0
  158. package/src/tasks/create/templates/SDK-Angular/template/DETAILS-region/demo.stories.jsx.mustache +73 -0
  159. package/src/tasks/create/templates/SDK-Angular/template/DETAILS-region/details.component.html.mustache +6 -0
  160. package/src/tasks/create/templates/SDK-Angular/template/DETAILS-region/details.component.scss.mustache +7 -0
  161. package/src/tasks/create/templates/SDK-Angular/template/DETAILS-region/details.component.spec.ts.mustache +25 -0
  162. package/src/tasks/create/templates/SDK-Angular/template/DETAILS-region/details.component.ts.mustache +92 -0
  163. package/src/tasks/create/templates/SDK-Angular/template/DETAILS-region/mock.stories.js.mustache +290 -0
  164. package/src/tasks/create/templates/SDK-Angular/template/FORM/DefaultForm.svg +29 -0
  165. package/src/tasks/create/templates/SDK-Angular/template/FORM/config.json.mustache +45 -0
  166. package/src/tasks/create/templates/SDK-Angular/template/FORM/demo.stories.jsx.mustache +215 -0
  167. package/src/tasks/create/templates/SDK-Angular/template/FORM/form.component.html.mustache +23 -0
  168. package/src/tasks/create/templates/SDK-Angular/template/FORM/form.component.scss.mustache +33 -0
  169. package/src/tasks/create/templates/SDK-Angular/template/FORM/form.component.spec.ts.mustache +25 -0
  170. package/src/tasks/create/templates/SDK-Angular/template/FORM/form.component.ts.mustache +71 -0
  171. package/src/tasks/create/templates/SDK-Angular/template/FORM-region/TwoColumn.svg +38 -0
  172. package/src/tasks/create/templates/SDK-Angular/template/FORM-region/config.json.mustache +49 -0
  173. package/src/tasks/create/templates/SDK-Angular/template/FORM-region/demo.stories.jsx.mustache +183 -0
  174. package/src/tasks/create/templates/SDK-Angular/template/FORM-region/form.component.html.mustache +16 -0
  175. package/src/tasks/create/templates/SDK-Angular/template/FORM-region/form.component.scss.mustache +28 -0
  176. package/src/tasks/create/templates/SDK-Angular/template/FORM-region/form.component.spec.ts.mustache +25 -0
  177. package/src/tasks/create/templates/SDK-Angular/template/FORM-region/form.component.ts.mustache +26 -0
  178. package/src/tasks/create/templates/SDK-Angular/template/FORM-region/mock.stories.js.mustache +132 -0
  179. package/src/tasks/create/templates/SDK-Angular/template/PAGE/OneColumnPage.svg +28 -0
  180. package/src/tasks/create/templates/SDK-Angular/template/PAGE/config.json.mustache +32 -0
  181. package/src/tasks/create/templates/SDK-Angular/template/PAGE/demo.stories.jsx.mustache +80 -0
  182. package/src/tasks/create/templates/SDK-Angular/template/PAGE/mock.stories.js.mustache +115 -0
  183. package/src/tasks/create/templates/SDK-Angular/template/PAGE/page.component.html.mustache +15 -0
  184. package/src/tasks/create/templates/SDK-Angular/template/PAGE/page.component.scss.mustache +3 -0
  185. package/src/tasks/create/templates/SDK-Angular/template/PAGE/page.component.spec.ts.mustache +25 -0
  186. package/src/tasks/create/templates/SDK-Angular/template/PAGE/page.component.ts.mustache +63 -0
  187. package/src/tasks/create/templates/SDK-Angular/widget/CASE/OneColumnPage.svg +36 -0
  188. package/src/tasks/create/templates/SDK-Angular/widget/CASE/case.component.html.mustache +15 -0
  189. package/src/tasks/create/templates/SDK-Angular/widget/CASE/case.component.scss.mustache +22 -0
  190. package/src/tasks/create/templates/SDK-Angular/widget/CASE/case.component.spec.ts.mustache +25 -0
  191. package/src/tasks/create/templates/SDK-Angular/widget/CASE/case.component.ts.mustache +111 -0
  192. package/src/tasks/create/templates/SDK-Angular/widget/CASE/config.json.mustache +23 -0
  193. package/src/tasks/create/templates/SDK-Angular/widget/CASE/demo.stories.jsx.mustache +70 -0
  194. package/src/tasks/create/templates/SDK-Angular/widget/CASE/mock.stories.js.mustache +390 -0
  195. package/src/tasks/create/templates/SDK-Angular/widget/PAGE/OneColumnPage.svg +36 -0
  196. package/src/tasks/create/templates/SDK-Angular/widget/PAGE/config.json.mustache +59 -0
  197. package/src/tasks/create/templates/SDK-Angular/widget/PAGE/demo.stories.jsx.mustache +29 -0
  198. package/src/tasks/create/templates/SDK-Angular/widget/PAGE/mock.stories.js.mustache +23 -0
  199. package/src/tasks/create/templates/SDK-Angular/widget/PAGE/page.component.html.mustache +17 -0
  200. package/src/tasks/create/templates/SDK-Angular/widget/PAGE/page.component.scss.mustache +19 -0
  201. package/src/tasks/create/templates/SDK-Angular/widget/PAGE/page.component.ts.mustache +32 -0
  202. package/src/tasks/create/templates/SDK-Angular/widget/PAGE/pagecomponent.spec.ts.mustache +25 -0
  203. package/src/tasks/create/templates/SDK-Angular/widget/PAGE-CASE/OneColumnPage.svg +36 -0
  204. package/src/tasks/create/templates/SDK-Angular/widget/PAGE-CASE/config.json.mustache +66 -0
  205. package/src/tasks/create/templates/SDK-Angular/widget/PAGE-CASE/demo.stories.jsx.mustache +52 -0
  206. package/src/tasks/create/templates/SDK-Angular/widget/PAGE-CASE/mock.stories.js.mustache +52 -0
  207. package/src/tasks/create/templates/SDK-Angular/widget/PAGE-CASE/page-case.component.html.mustache +28 -0
  208. package/src/tasks/create/templates/SDK-Angular/widget/PAGE-CASE/page-case.component.scss.mustache +137 -0
  209. package/src/tasks/create/templates/SDK-Angular/widget/PAGE-CASE/page-case.component.spec.ts.mustache +25 -0
  210. package/src/tasks/create/templates/SDK-Angular/widget/PAGE-CASE/page-case.component.ts.mustache +115 -0
  211. package/src/tasks/create/templates/SDK-React/field/Boolean/index.tsx.mustache +3 -3
  212. package/src/tasks/create/templates/SDK-React/field/Date/index.tsx.mustache +2 -2
  213. package/src/tasks/create/templates/SDK-React/field/DateTime/index.tsx.mustache +6 -7
  214. package/src/tasks/create/templates/SDK-React/field/Decimal/demo.stories.jsx.mustache +5 -1
  215. package/src/tasks/create/templates/SDK-React/field/Decimal/index.tsx.mustache +78 -28
  216. package/src/tasks/create/templates/SDK-React/field/Decimal-Currency/index.tsx.mustache +3 -3
  217. package/src/tasks/create/templates/SDK-React/field/Decimal-Percentage/index.tsx.mustache +2 -2
  218. package/src/tasks/create/templates/SDK-React/field/Integer/index.tsx.mustache +2 -2
  219. package/src/tasks/create/templates/SDK-React/field/Picklist/demo.stories.jsx.mustache +13 -0
  220. package/src/tasks/create/templates/SDK-React/field/Picklist/index.tsx.mustache +30 -10
  221. package/src/tasks/create/templates/SDK-React/field/Text/index.tsx.mustache +2 -2
  222. package/src/tasks/create/templates/SDK-React/field/Text-Email/index.tsx.mustache +2 -2
  223. package/src/tasks/create/templates/SDK-React/field/Text-Input/index.tsx.mustache +2 -2
  224. package/src/tasks/create/templates/SDK-React/field/Text-Paragraph/index.tsx.mustache +2 -2
  225. package/src/tasks/create/templates/SDK-React/field/Text-Phone/index.tsx.mustache +6 -5
  226. package/src/tasks/create/templates/SDK-React/field/Text-URL/index.tsx.mustache +11 -0
  227. package/src/tasks/create/templates/SDK-React/field/TimeOfDay/config.json.mustache +135 -0
  228. package/src/tasks/create/templates/SDK-React/field/{TimeofDay → TimeOfDay}/index.tsx.mustache +12 -1
  229. package/src/tasks/create/templates/SDK-React/template/DETAILS/index.tsx.mustache +7 -3
  230. package/src/tasks/create/templates/SDK-React/template/DETAILS-region/index.tsx.mustache +8 -4
  231. package/src/tasks/create/templates/SDK-React/template/FORM/index.tsx.mustache +30 -20
  232. package/src/tasks/create/templates/SDK-React/template/FORM-region/demo.stories.jsx.mustache +2 -2
  233. package/src/tasks/create/templates/SDK-React/template/PAGE/demo.stories.jsx.mustache +1 -0
  234. package/src/tasks/create/templates/SDK-React/widget/CASE/index.tsx.mustache +4 -3
  235. package/src/tasks/create/templates/SDK-React/widget/PAGE/index.tsx.mustache +7 -7
  236. package/src/tasks/create/templates/SDK-React/widget/PAGE-CASE/demo.stories.jsx.mustache +2 -10
  237. package/src/tasks/create/templates/SDK-React/widget/PAGE-CASE/index.tsx.mustache +138 -36
  238. package/src/tasks/create/templates/SDK-React/widget/PAGE-CASE/mock.stories.js.mustache +1 -1
  239. package/src/tasks/create-all/index.js +112 -56
  240. package/src/tasks/delete/helper.js +88 -24
  241. package/src/tasks/delete/index.js +17 -8
  242. package/src/tasks/delete-all/helper.js +88 -25
  243. package/src/tasks/delete-all/index.js +15 -6
  244. package/src/tasks/list/helper.js +2 -3
  245. package/src/tasks/list/index.js +14 -7
  246. package/src/tasks/map/map.js +212 -20
  247. package/src/tasks/map-all/index.js +19 -2
  248. package/src/tasks/override/index.js +140 -79
  249. package/src/tasks/override-all/index.js +54 -6
  250. package/src/tasks/publish/helper.js +94 -51
  251. package/src/tasks/publish/index.js +87 -34
  252. package/src/tasks/publish-all/helper.js +97 -58
  253. package/src/tasks/publish-all/index.js +127 -48
  254. package/src/tasks/rename/index.js +184 -111
  255. package/src/tasks/validator/index.js +31 -7
  256. package/src/util.js +187 -39
  257. package/src/tasks/create/templates/Constellation/field/TimeofDay/styles.js.mustache +0 -7
  258. /package/src/tasks/bundle/{builder → builderAngular}/index.js +0 -0
  259. /package/src/tasks/bundle/{builder → builderAngular}/modules.js +0 -0
  260. /package/src/tasks/create/templates/Constellation/field/{TimeofDay → TimeOfDay}/config.json.mustache +0 -0
  261. /package/src/tasks/create/templates/Constellation/field/{TimeofDay → TimeOfDay}/demo.stories.jsx.mustache +0 -0
  262. /package/src/tasks/create/templates/Constellation/field/{TimeofDay → TimeOfDay}/index.jsx.mustache +0 -0
  263. /package/src/tasks/create/templates/Constellation/field/{TimeofDay → TimeOfDay}/mock.stories.js.mustache +0 -0
  264. /package/src/tasks/create/templates/Constellation/field/{TimeofDay → TimeOfDay}/suggestions-handler.js +0 -0
  265. /package/src/tasks/create/templates/{SDK-React/field/TimeofDay → SDK-Angular/field/TimeOfDay}/config.json.mustache +0 -0
  266. /package/src/tasks/create/templates/SDK-React/field/{TimeofDay → TimeOfDay}/demo.stories.jsx.mustache +0 -0
  267. /package/src/tasks/create/templates/SDK-React/field/{TimeofDay → TimeOfDay}/mock.stories.js.mustache +0 -0
  268. /package/src/tasks/create/templates/SDK-React/field/{TimeofDay → TimeOfDay}/styles.js.mustache +0 -0
@@ -0,0 +1,36 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <svg width="100px" height="70px" viewBox="0 0 100 70" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
3
+ <title>1 col </title>
4
+ <defs>
5
+ <rect id="path-1" x="0" y="0" width="100" height="70"></rect>
6
+ </defs>
7
+ <g id="Concepts" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
8
+ <g id="Templates" transform="translate(-98.000000, -108.000000)">
9
+ <g id="Change-template" transform="translate(42.000000, 36.000000)">
10
+ <g id="1-col-" transform="translate(56.000000, 72.000000)">
11
+ <mask id="mask-2" fill="white">
12
+ <use xlink:href="#path-1"></use>
13
+ </mask>
14
+ <rect stroke="#A5A8BC" stroke-width="0.5" x="0.25" y="0.25" width="99.5" height="69.5"></rect>
15
+ <g id="white" mask="url(#mask-2)" fill="#FFFFFF">
16
+ <g transform="translate(3.000000, 3.000000)" id="Rectangle">
17
+ <rect x="0" y="0" width="94" height="66.5"></rect>
18
+ </g>
19
+ </g>
20
+ <g id="gray" mask="url(#mask-2)" fill="#8084A7">
21
+ <g transform="translate(6.000000, 6.000000)" id="Rectangle">
22
+ <rect x="0" y="-2.84217094e-14" width="88" height="77.8"></rect>
23
+ </g>
24
+ </g>
25
+ <g id="labels" mask="url(#mask-2)" font-family="OpenSans-Semibold, Open Sans" font-size="11" font-weight="500">
26
+ <g transform="translate(44.000000, 17.000000)" id="A">
27
+ <text>
28
+ <tspan x="0.75" y="12" fill="#FFFFFF">A</tspan>
29
+ </text>
30
+ </g>
31
+ </g>
32
+ </g>
33
+ </g>
34
+ </g>
35
+ </g>
36
+ </svg>
@@ -0,0 +1,66 @@
1
+ {
2
+ "name": "{{COMPONENT_KEY}}",
3
+ "label": "{{COMPONENT_LABEL}}",
4
+ "description": "{{DESCRIPTION}}",
5
+ "organization": "{{ORGANIZATION}}",
6
+ "version": "{{VERSION}}",
7
+ "library": "{{LIBRARY}}",
8
+ "allowedApplications": {{{ALLOWEDAPPS}}},
9
+ "componentKey": "{{COMPONENT_KEY}}",
10
+ "type": "{{TYPE}}",
11
+ "subtype": {{{SUB_TYPE}}},
12
+ "icon": "OneColumnPage.svg",
13
+ "properties": [
14
+ {
15
+ "name": "title",
16
+ "label": "Label value",
17
+ "format": "TEXT"
18
+ },
19
+ {
20
+ "format": "SELECT",
21
+ "label": "Usage",
22
+ "name": "label",
23
+ "defaultValue": "Create operator",
24
+ "localize": true,
25
+ "source": [
26
+ {
27
+ "key": "Create operator",
28
+ "value": "Create operator"
29
+ },
30
+ {
31
+ "key": "Update operator",
32
+ "value": "Update operator"
33
+ },
34
+ {
35
+ "key": "Resolve operator",
36
+ "value": "Resolve operator"
37
+ }
38
+ ]
39
+ },
40
+
41
+ {
42
+ "label": "Conditions",
43
+ "format": "GROUP",
44
+ "properties": [
45
+ {
46
+ "name": "visibility",
47
+ "label": "Visibility",
48
+ "format": "VISIBILITY"
49
+ }
50
+ ]
51
+ }
52
+ ],
53
+ "defaultConfig": {
54
+ "label": "Create operator",
55
+ "title": "Create operator",
56
+ "createLabel": "@L Created",
57
+ "updateLabel": "@L Updated",
58
+ "createOperator": "@USER .pxCreateOperator",
59
+ "updateOperator": "@USER .pxUpdateOperator",
60
+ "createDateTime": "@P .pxCreateDateTime",
61
+ "updateDateTime": "@P .pxUpdateDateTime",
62
+ "resolveLabel": "@L Resolved",
63
+ "resolveOperator": "@USER .pyResolvedUserID",
64
+ "resolveDateTime": "@P .pyResolvedTimestamp"
65
+ }
66
+ }
@@ -0,0 +1,52 @@
1
+ import { withKnobs } from '@storybook/addon-knobs';
2
+
3
+ import { caseOpConfig, operatorDetails } from './mock.stories';
4
+
5
+ import {{COMPONENT_CLASS_NAME}} from './index.tsx';
6
+
7
+ export default {
8
+ title: '{{COMPONENT_CLASS_NAME}}',
9
+ decorators: [withKnobs],
10
+ component: {{COMPONENT_CLASS_NAME}}
11
+ };
12
+
13
+ if (!window.PCore) {
14
+ window.PCore = {};
15
+ }
16
+
17
+ window.PCore.getUserApi = () => {
18
+ return {
19
+ getOperatorDetails: () => {
20
+ return new Promise(resolve => {
21
+ resolve(operatorDetails);
22
+ });
23
+ }
24
+ };
25
+ };
26
+
27
+ export const Base{{COMPONENT_CLASS_NAME}} = () => {
28
+
29
+ const props = {
30
+ caseOpConfig,
31
+ getPConnect: () => {
32
+ return {
33
+ getActionsApi: () => {
34
+ return {
35
+ updateFieldValue: () => {/* nothing */},
36
+ triggerFieldChange: () => {/* nothing */}
37
+ };
38
+ },
39
+ ignoreSuggestion: () => {/* nothing */},
40
+ acceptSuggestion: () => {/* nothing */},
41
+ setInheritedProps: () => {/* nothing */},
42
+ resolveConfigProps: () => {/* nothing */}
43
+ };
44
+ }
45
+ };
46
+
47
+ return (
48
+ <>
49
+ <{{COMPONENT_CLASS_NAME}} {...props} />
50
+ </>
51
+ );
52
+ };
@@ -0,0 +1,52 @@
1
+
2
+ export const caseOpConfig = {
3
+ label: 'Create operator',
4
+ createLabel: 'Created',
5
+ updateLabel: 'Updated',
6
+ updateDateTime: '2023-01-16T14:53:33.280Z',
7
+ createDateTime: '2023-01-16T14:53:33.198Z',
8
+ updateOperator: {
9
+ userId: 'admin@mediaco',
10
+ userName: 'admin'
11
+ },
12
+ createOperator: {
13
+ userId: 'admin@mediaco',
14
+ userName: 'admin'
15
+ },
16
+ hideLabel: true,
17
+ key: '_532zx1dah',
18
+ displayMode: 'LABELS_LEFT'
19
+ };
20
+
21
+ export const operatorDetails = {
22
+ data: {
23
+ pzLoadTime: 'January 18, 2023 10:33:19 AM EST',
24
+ pzPageNameHash: '_pa1519192551088960pz',
25
+ pyOperatorInfo: {
26
+ pyUserName: 'french DigV2',
27
+ pyPosition: '',
28
+ pyImageInsKey: '',
29
+ pySkills: [
30
+ {
31
+ pySkillName: '',
32
+ pzIndexOwnerKey: 'DATA-ADMIN-OPERATOR-ID FRENCHTEST.DIGV2',
33
+ pySkillRating: 0
34
+ }
35
+ ],
36
+ pyReportToUserName: '',
37
+ pyReportTo: '',
38
+ pyOrganization: 'DXIL',
39
+ pyTitle: '',
40
+ pyLabel: 'frenchTest.DigV2',
41
+ pyEmailAddress: 'User@DigV2',
42
+ pyTelephone: ''
43
+ }
44
+ },
45
+ status: 200,
46
+ statusText: '',
47
+ headers: {
48
+ 'content-length': '435',
49
+ 'content-type': 'application/json;charset=UTF-8'
50
+ },
51
+ request: {}
52
+ };
@@ -0,0 +1,28 @@
1
+ {{! pick new delimiters for mustache }}
2
+ {{=<% %>=}}
3
+ <div class="psdk-case-summary-fields">
4
+ <dl *ngFor="let field of primaryFields$" class="psdk-case-summary-fields-primary">
5
+ <div class="psdk-csf-primary-field">
6
+ <dt class="psdk-csf-primary-field-header">
7
+ {{ field.config.displayLabel }}
8
+ </dt>
9
+ <dd class="psdk-csf-primary-field-data">
10
+ <div>
11
+ <component-mapper
12
+ *ngIf="field.config.label.toLowerCase() == 'create operator'"
13
+ name="Operator"
14
+ [props]="{ name$: field.config.createOperator.userName, date$: field.config.updateDateTime, id$: field.config.createOperator.userId }"
15
+ ></component-mapper>
16
+ </div>
17
+ <div>
18
+ <component-mapper
19
+ *ngIf="field.config.label.toLowerCase() == 'updated'"
20
+ name="Operator"
21
+ [props]="{ name$: field.config.updateOperator.userName, date$: field.config.updateDateTime, id$: field.config.updateOperator.userId }"
22
+ ></component-mapper>
23
+ </div>
24
+ </dd>
25
+ </div>
26
+ </dl>
27
+ </div>
28
+ <%={{ }}=%> {{! revert delimiters for mustache }}
@@ -0,0 +1,137 @@
1
+ @import '@pega/angular-sdk-library/_shared/styles.scss';
2
+
3
+ .psdk-case-summary {
4
+ display: block;
5
+ margin: 0.625rem;
6
+ }
7
+
8
+ .psdk-case-summary-primary {
9
+ text-align: left;
10
+ margin-bottom: 0.75rem;
11
+ }
12
+
13
+ .psdk-case-summary-secondary {
14
+ text-align: left;
15
+ margin-bottom: 0.75rem;
16
+ }
17
+
18
+ .psdk-case-summary-status {
19
+ text-align: left;
20
+ margin-bottom: 0.75rem;
21
+ }
22
+
23
+ .psdk-case-summary-status-data {
24
+ display: block;
25
+ background-color: lavender;
26
+ color: $app-primary-color;
27
+ padding: 0rem 0.625rem;
28
+ display: inline;
29
+ font-size: 0.75rem;
30
+ font-weight: 700;
31
+ text-transform: uppercase;
32
+ line-height: 1.5rem;
33
+ }
34
+
35
+ .psdk-case-summary-primary .label {
36
+ font-weight: 600;
37
+ }
38
+
39
+ .psdk-case-summary-primary .data {
40
+ font-weight: 600;
41
+ font-size: 1.625rem;
42
+ }
43
+
44
+ .psdk-case-summary-secondary .label {
45
+ font-weight: 600;
46
+ }
47
+ .psdk-case-summary-secondary .data {
48
+ font-weight: 600;
49
+ color: $app-primary-color;
50
+ padding-left: 1.25rem;
51
+ }
52
+
53
+ .psdk-case-summary-fields {
54
+ padding: calc(2 * 0.5rem);
55
+ display: inline-flex;
56
+ grid-row-gap: calc(2 * 0.5rem);
57
+ column-gap: 4rem;
58
+ }
59
+
60
+ .psdk-case-summary-fields-primary {
61
+ grid-template-columns: 20ch 1fr;
62
+ display: grid;
63
+ grid-column-gap: calc(2 * 0.5rem);
64
+ grid-row-gap: calc(2 * 0.5rem);
65
+ }
66
+
67
+ .psdk-csf-primary-field {
68
+ display: grid;
69
+ grid-template-columns: 1fr;
70
+ grid-column-gap: calc(0 * 0.5rem);
71
+ }
72
+
73
+ .psdk-csf-primary-field-header {
74
+ word-break: break-word;
75
+ grid-column-start: 1;
76
+ grid-row-start: 1;
77
+ max-width: max-content;
78
+ font-size: 0.8125rem;
79
+ font-weight: 400;
80
+ color: rgba(0, 0, 0, 0.8);
81
+ }
82
+
83
+ .psdk-csf-primary-field-data {
84
+ word-break: break-word;
85
+ grid-column-start: 1;
86
+ grid-row-start: 2;
87
+ margin-inline-start: unset;
88
+ }
89
+
90
+ .psdk-case-summary-fields-secondary {
91
+ width: 100%;
92
+ display: grid;
93
+ grid-template-columns: 1fr;
94
+ grid-column-gap: calc(2 * 0.5rem);
95
+ grid-row-gap: calc(1 * 0.5rem);
96
+ }
97
+
98
+ .psdk-csf-secondary-field {
99
+ display: grid;
100
+ grid-template-columns: auto;
101
+ grid-column-gap: calc(2 * 0.5rem);
102
+ }
103
+
104
+ .psdk-csf-secondary-field-header {
105
+ word-break: break-word;
106
+ grid-column-start: 1;
107
+ grid-row-start: 1;
108
+ max-width: max-content;
109
+ font-size: 0.8125rem;
110
+ font-weight: 400;
111
+ color: rgba(0, 0, 0, 0.8);
112
+ }
113
+
114
+ .psdk-csf-secondary-field-data {
115
+ word-break: break-word;
116
+ grid-column-start: 2;
117
+ grid-row-start: 1;
118
+ margin-inline-start: unset;
119
+ }
120
+
121
+ span.psdk-csf-text-style {
122
+ font-size: 1.125rem;
123
+ font-weight: 600;
124
+ }
125
+
126
+ span.psdk-csf-status-style {
127
+ background-color: #e9eef3;
128
+ border-radius: calc(0.25 * 0.5rem);
129
+ color: #4c5a67;
130
+ display: inline-block;
131
+ font-size: 0.75rem;
132
+ font-weight: bold;
133
+ line-height: calc(0.5rem * 2.5);
134
+ height: calc(0.5rem * 2.5);
135
+ padding: 0 0.5rem;
136
+ text-transform: uppercase;
137
+ }
@@ -0,0 +1,25 @@
1
+ import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
2
+
3
+ import { {{COMPONENT_CLASS_NAME}}Component } from './{{COMPONENT_CLASS_NAME_KEBAB}}.component';
4
+
5
+ describe('{{COMPONENT_CLASS_NAME}}Component', () => {
6
+ let component: {{COMPONENT_CLASS_NAME}}Component;
7
+ let fixture: ComponentFixture<{{COMPONENT_CLASS_NAME}}Component>;
8
+
9
+ beforeEach(waitForAsync(() => {
10
+ TestBed.configureTestingModule({
11
+ declarations: [ {{COMPONENT_CLASS_NAME}}Component ]
12
+ })
13
+ .compileComponents();
14
+ }));
15
+
16
+ beforeEach(() => {
17
+ fixture = TestBed.createComponent({{COMPONENT_CLASS_NAME}}Component);
18
+ component = fixture.componentInstance;
19
+ fixture.detectChanges();
20
+ });
21
+
22
+ it('should create', () => {
23
+ expect(component).toBeTruthy();
24
+ });
25
+ });
@@ -0,0 +1,115 @@
1
+ import { Component, OnInit, Input, forwardRef } from '@angular/core';
2
+ import { CommonModule } from '@angular/common';
3
+ import { Utils } from '@pega/angular-sdk-library';
4
+ import { ComponentMapperComponent } from '@pega/angular-sdk-library';
5
+ import { AngularPConnectService } from '@pega/angular-sdk-library';
6
+
7
+ declare const window: any;
8
+
9
+ @Component({
10
+ selector: 'app-{{COMPONENT_CLASS_NAME_KEBAB}}',
11
+ templateUrl: './{{COMPONENT_CLASS_NAME_KEBAB}}.component.html',
12
+ styleUrls: ['./{{COMPONENT_CLASS_NAME_KEBAB}}.component.scss'],
13
+ standalone: true,
14
+ imports: [CommonModule, forwardRef(() => ComponentMapperComponent)]
15
+ })
16
+ export class {{COMPONENT_CLASS_NAME}}Component implements OnInit {
17
+ @Input() status$: string;
18
+ @Input() bShowStatus$: boolean;
19
+
20
+ @Input() primaryFields$: Array<any>;
21
+
22
+ @Input() pConn$: any;
23
+ PCore$: any;
24
+
25
+ // For interaction with AngularPConnect
26
+ angularPConnectData: any = {};
27
+ configProps$: Object;
28
+
29
+ controlName$: string;
30
+
31
+
32
+ constructor(private utils: Utils, private angularPConnect: AngularPConnectService) {}
33
+
34
+ ngOnInit(): void {
35
+
36
+ if (!this.PCore$) {
37
+ this.PCore$ = window.PCore;
38
+ }
39
+
40
+ // First thing in initialization is registering and subscribing to the AngularPConnect service
41
+ this.angularPConnectData = this.angularPConnect.registerAndSubscribeComponent(this, this.onStateChange);
42
+ this.controlName$ = this.angularPConnect.getComponentID(this);
43
+
44
+ // call updateSelf when initializing
45
+ // this.updateSelf();
46
+ this.checkAndUpdate();
47
+
48
+
49
+ }
50
+
51
+ checkAndUpdate() {
52
+ // Should always check the bridge to see if the component should
53
+ // update itself (re-render)
54
+ const bUpdateSelf = this.angularPConnect.shouldComponentUpdate(this);
55
+
56
+ // ONLY call updateSelf when the component should update
57
+ if (bUpdateSelf) {
58
+ this.updateSelf();
59
+ }
60
+ }
61
+
62
+ // updateSelf
63
+ updateSelf(): void {
64
+ // moved this from ngOnInit() and call this from there instead...
65
+ this.configProps$ = this.pConn$.resolveConfigProps(this.pConn$.getConfigProps());
66
+
67
+ this.primaryFields$ = new Array();
68
+
69
+ let createConfig = {}
70
+ createConfig["label"] = this.configProps$["label"];
71
+ createConfig["updateDateTime"] = this.configProps$["createDateTime"];
72
+ createConfig["displayLabel"] = this.configProps$["createLabel"];
73
+ createConfig["createOperator"] = this.configProps$["createOperator"];
74
+ let elConfig = {};
75
+ elConfig["config"] = createConfig;
76
+
77
+ this.primaryFields$.push(elConfig);
78
+
79
+ let updateConfig = {};
80
+ updateConfig["label"] = this.configProps$["updateLabel"];
81
+ updateConfig["updateDateTime"] = this.configProps$["updateDateTime"];
82
+ updateConfig["displayLabel"] = this.configProps$["updateLabel"];
83
+ updateConfig["updateOperator"] = this.configProps$["updateOperator"];
84
+ let elConfig1 = {};
85
+ elConfig1["config"] = updateConfig;
86
+
87
+ this.primaryFields$.push(elConfig1);
88
+ }
89
+
90
+ // Callback passed when subscribing to store change
91
+ onStateChange() {
92
+ this.checkAndUpdate();
93
+ }
94
+
95
+ ngOnChanges() {
96
+ this.updateLabelAndDate(this.primaryFields$);
97
+ }
98
+
99
+ updateLabelAndDate(arData: Array<any>) {
100
+ for (let field of arData) {
101
+ switch (field.type.toLowerCase()) {
102
+ case 'caseoperator':
103
+ if (field.config.label.toLowerCase() == 'create operator') {
104
+ field.config['displayLabel'] = field.config.createLabel;
105
+ } else if (field.config.label.toLowerCase() == 'update operator') {
106
+ field.config['displayLabel'] = field.config.updateLabel;
107
+ }
108
+ break;
109
+ case 'date':
110
+ field.config.value = this.utils.generateDate(field.config.value, 'Date-Long');
111
+ break;
112
+ }
113
+ }
114
+ }
115
+ }
@@ -25,6 +25,7 @@ export default function {{COMPONENT_CLASS_NAME}}(props: any) {
25
25
  readOnly,
26
26
  testId,
27
27
  required,
28
+ disabled,
28
29
  status,
29
30
  helperText,
30
31
  validatemessage,
@@ -61,15 +62,14 @@ export default function {{COMPONENT_CLASS_NAME}}(props: any) {
61
62
  thePConn.getValidationApi().validate(event.target.checked);
62
63
  };
63
64
 
64
- let theCheckbox = <Checkbox color='primary' />;
65
+ let theCheckbox = <Checkbox color='primary' disabled={disabled} />;
65
66
 
66
67
  if (readOnly) {
67
68
  // Workaround for lack of InputProps readOnly from https://github.com/mui-org/material-ui/issues/17043
68
69
  // Also note that we need to turn off the onChange call in the FormControlLabel wrapper, too. See below!
69
- theCheckbox = <Checkbox value={value || false} onChange={handleChange} readOnly={readOnly} />;
70
+ theCheckbox = <Checkbox value={value || false} readOnly={readOnly} />;
70
71
  }
71
72
 
72
-
73
73
  return (
74
74
  <Styled{{COMPONENT_CLASS_NAME}}Wrapper>
75
75
  <FormControl required={required} error={status === 'error'}>
@@ -100,10 +100,10 @@ export default function {{COMPONENT_CLASS_NAME}}(props: any) {
100
100
  onChange={handleChange}
101
101
  onBlur={!readOnly ? onBlur : undefined}
102
102
  onAccept={handleAccept}
103
- {{! pick new delimiteres for mustache }}
103
+ {{! pick new delimiters for mustache }}
104
104
  {{=<% %>=}}
105
105
  InputProps={{ ...testProp }}
106
- <%={{ }}=%> {{! revert delimiteres for mustache }}
106
+ <%={{ }}=%> {{! revert delimiters for mustache }}
107
107
  />
108
108
  </MuiPickersUtilsProvider>
109
109
  </Styled{{COMPONENT_CLASS_NAME}}Wrapper>
@@ -47,19 +47,18 @@ export default function {{COMPONENT_CLASS_NAME}}(props: any) {
47
47
 
48
48
 
49
49
  if (displayMode === 'LABELS_LEFT') {
50
- const formattedDate = format(props.value, 'datetime', { format: `${dateFormatInfo.dateFormatString} hh:mm a` });
51
- return <FieldValueList name={hideLabel ? '' : label} value={formattedDate} />;
50
+ const formattedDateTime = format(props.value, 'datetime', { format: `${dateFormatInfo.dateFormatString} hh:mm a` });
51
+ return <FieldValueList name={hideLabel ? '' : label} value={formattedDateTime} />;
52
52
  }
53
53
 
54
54
  if (displayMode === 'STACKED_LARGE_VAL') {
55
- const formattedDate = format(props.value, 'datetime', { format: `${dateFormatInfo.dateFormatString} hh:mm a` });
56
- return <FieldValueList name={hideLabel ? '' : label} value={formattedDate} variant='stacked' />;
55
+ const formattedDateTime = format(props.value, 'datetime', { format: `${dateFormatInfo.dateFormatString} hh:mm a` });
56
+ return <FieldValueList name={hideLabel ? '' : label} value={formattedDateTime} variant='stacked' />;
57
57
  }
58
58
 
59
59
  if (readOnly) {
60
- const formattedDate = format(props.value, 'datetime');
61
- props.value = formattedDate;
62
- return <TextInput {...props} />;
60
+ const formattedDateTime = format(props.value, 'datetime');
61
+ return <TextInput {...props} value={formattedDateTime} />;
63
62
  }
64
63
 
65
64
  const handleChange = date => {
@@ -26,11 +26,15 @@ export const Base{{COMPONENT_CLASS_NAME}} = () => {
26
26
  return {
27
27
  updateFieldValue: (propName, theValue) => {
28
28
  setValue(theValue);
29
- }
29
+ },
30
+ triggerFieldChange: () => {/* nothing */}
30
31
  };
31
32
  },
32
33
  getStateProps: () => {
33
34
  return { value: '.name' };
35
+ },
36
+ getComponentName: () => {
37
+ return 'Decimal';
34
38
  }
35
39
  };
36
40
  },