@pega/react-sdk-components 24.2.11 → 25.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 (630) hide show
  1. package/lib/bridge/Context/StoreContext.d.ts +0 -1
  2. package/lib/bridge/Context/StoreContext.d.ts.map +1 -1
  3. package/lib/bridge/Context/StoreContext.js.map +1 -1
  4. package/lib/bridge/helpers/sdk_component_map.d.ts.map +1 -1
  5. package/lib/bridge/helpers/sdk_component_map.js +0 -6
  6. package/lib/bridge/helpers/sdk_component_map.js.map +1 -1
  7. package/lib/bridge/react_pconnect.d.ts.map +1 -1
  8. package/lib/bridge/react_pconnect.js +11 -14
  9. package/lib/bridge/react_pconnect.js.map +1 -1
  10. package/lib/components/designSystemExtension/AlertBanner/AlertBanner.js.map +1 -1
  11. package/lib/components/designSystemExtension/Banner/Banner.css +1 -1
  12. package/lib/components/designSystemExtension/Banner/Banner.d.ts.map +1 -1
  13. package/lib/components/designSystemExtension/Banner/Banner.js +2 -2
  14. package/lib/components/designSystemExtension/Banner/Banner.js.map +1 -1
  15. package/lib/components/designSystemExtension/CaseSummaryFields/CaseSummaryFields.css +0 -1
  16. package/lib/components/designSystemExtension/CaseSummaryFields/CaseSummaryFields.d.ts.map +1 -1
  17. package/lib/components/designSystemExtension/CaseSummaryFields/CaseSummaryFields.js +50 -35
  18. package/lib/components/designSystemExtension/CaseSummaryFields/CaseSummaryFields.js.map +1 -1
  19. package/lib/components/designSystemExtension/DetailsFields/DetailsFields.d.ts.map +1 -1
  20. package/lib/components/designSystemExtension/DetailsFields/DetailsFields.js +6 -8
  21. package/lib/components/designSystemExtension/DetailsFields/DetailsFields.js.map +1 -1
  22. package/lib/components/designSystemExtension/FieldGroup/FieldGroup.d.ts +1 -1
  23. package/lib/components/designSystemExtension/FieldGroup/FieldGroup.d.ts.map +1 -1
  24. package/lib/components/designSystemExtension/FieldGroup/FieldGroup.js +3 -5
  25. package/lib/components/designSystemExtension/FieldGroup/FieldGroup.js.map +1 -1
  26. package/lib/components/designSystemExtension/FieldGroupList/FieldGroupList.js +2 -2
  27. package/lib/components/designSystemExtension/FieldGroupList/FieldGroupList.js.map +1 -1
  28. package/lib/components/designSystemExtension/FieldValueList/FieldValueList.d.ts.map +1 -1
  29. package/lib/components/designSystemExtension/FieldValueList/FieldValueList.js +4 -6
  30. package/lib/components/designSystemExtension/FieldValueList/FieldValueList.js.map +1 -1
  31. package/lib/components/designSystemExtension/Operator/Operator.d.ts +1 -1
  32. package/lib/components/designSystemExtension/Operator/Operator.d.ts.map +1 -1
  33. package/lib/components/designSystemExtension/Operator/Operator.js +12 -9
  34. package/lib/components/designSystemExtension/Operator/Operator.js.map +1 -1
  35. package/lib/components/designSystemExtension/Pulse/Pulse.d.ts +1 -1
  36. package/lib/components/designSystemExtension/Pulse/Pulse.d.ts.map +1 -1
  37. package/lib/components/designSystemExtension/Pulse/Pulse.js.map +1 -1
  38. package/lib/components/designSystemExtension/RichTextEditor/RichTextEditor.d.ts.map +1 -1
  39. package/lib/components/designSystemExtension/RichTextEditor/RichTextEditor.js +32 -4
  40. package/lib/components/designSystemExtension/RichTextEditor/RichTextEditor.js.map +1 -1
  41. package/lib/components/designSystemExtension/WssQuickCreate/WssQuickCreate.css +7 -14
  42. package/lib/components/designSystemExtension/WssQuickCreate/WssQuickCreate.d.ts.map +1 -1
  43. package/lib/components/designSystemExtension/WssQuickCreate/WssQuickCreate.js +12 -2
  44. package/lib/components/designSystemExtension/WssQuickCreate/WssQuickCreate.js.map +1 -1
  45. package/lib/components/field/AutoComplete/AutoComplete.d.ts +1 -1
  46. package/lib/components/field/AutoComplete/AutoComplete.d.ts.map +1 -1
  47. package/lib/components/field/AutoComplete/AutoComplete.js.map +1 -1
  48. package/lib/components/field/CancelAlert/CancelAlert.css +4 -4
  49. package/lib/components/field/CancelAlert/CancelAlert.d.ts +1 -1
  50. package/lib/components/field/CancelAlert/CancelAlert.d.ts.map +1 -1
  51. package/lib/components/field/CancelAlert/CancelAlert.js +3 -3
  52. package/lib/components/field/CancelAlert/CancelAlert.js.map +1 -1
  53. package/lib/components/field/Checkbox/Checkbox.d.ts +9 -1
  54. package/lib/components/field/Checkbox/Checkbox.d.ts.map +1 -1
  55. package/lib/components/field/Checkbox/Checkbox.js +52 -3
  56. package/lib/components/field/Checkbox/Checkbox.js.map +1 -1
  57. package/lib/components/field/Currency/Currency.d.ts +1 -1
  58. package/lib/components/field/Currency/Currency.d.ts.map +1 -1
  59. package/lib/components/field/Currency/Currency.js +2 -2
  60. package/lib/components/field/Currency/Currency.js.map +1 -1
  61. package/lib/components/field/Currency/currency-utils.d.ts.map +1 -1
  62. package/lib/components/field/Currency/currency-utils.js +0 -2
  63. package/lib/components/field/Currency/currency-utils.js.map +1 -1
  64. package/lib/components/field/Date/Date.d.ts +1 -1
  65. package/lib/components/field/Date/Date.d.ts.map +1 -1
  66. package/lib/components/field/Date/Date.js +3 -6
  67. package/lib/components/field/Date/Date.js.map +1 -1
  68. package/lib/components/field/DateTime/DateTime.d.ts +1 -1
  69. package/lib/components/field/DateTime/DateTime.d.ts.map +1 -1
  70. package/lib/components/field/DateTime/DateTime.js +4 -7
  71. package/lib/components/field/DateTime/DateTime.js.map +1 -1
  72. package/lib/components/field/Decimal/Decimal.d.ts +1 -1
  73. package/lib/components/field/Decimal/Decimal.d.ts.map +1 -1
  74. package/lib/components/field/Decimal/Decimal.js +2 -4
  75. package/lib/components/field/Decimal/Decimal.js.map +1 -1
  76. package/lib/components/field/Dropdown/Dropdown.d.ts +1 -1
  77. package/lib/components/field/Dropdown/Dropdown.d.ts.map +1 -1
  78. package/lib/components/field/Dropdown/Dropdown.js +6 -9
  79. package/lib/components/field/Dropdown/Dropdown.js.map +1 -1
  80. package/lib/components/field/Email/Email.d.ts +1 -1
  81. package/lib/components/field/Email/Email.d.ts.map +1 -1
  82. package/lib/components/field/Email/Email.js +6 -7
  83. package/lib/components/field/Email/Email.js.map +1 -1
  84. package/lib/components/field/Group/Group.d.ts +2 -2
  85. package/lib/components/field/Group/Group.d.ts.map +1 -1
  86. package/lib/components/field/Group/Group.js +4 -3
  87. package/lib/components/field/Group/Group.js.map +1 -1
  88. package/lib/components/field/Integer/Integer.d.ts +1 -1
  89. package/lib/components/field/Integer/Integer.d.ts.map +1 -1
  90. package/lib/components/field/Integer/Integer.js +4 -5
  91. package/lib/components/field/Integer/Integer.js.map +1 -1
  92. package/lib/components/field/Location/Location.css +4 -0
  93. package/lib/components/field/Location/Location.d.ts +11 -0
  94. package/lib/components/field/Location/Location.d.ts.map +1 -0
  95. package/lib/components/field/Location/Location.js +158 -0
  96. package/lib/components/field/Location/Location.js.map +1 -0
  97. package/lib/components/field/Location/index.d.ts +2 -0
  98. package/lib/components/field/Location/index.d.ts.map +1 -0
  99. package/lib/components/field/Location/index.js +2 -0
  100. package/lib/components/field/Location/index.js.map +1 -0
  101. package/lib/components/field/Multiselect/Multiselect.js.map +1 -1
  102. package/lib/components/field/Multiselect/utils.d.ts +2 -1
  103. package/lib/components/field/Multiselect/utils.d.ts.map +1 -1
  104. package/lib/components/field/Multiselect/utils.js +1 -1
  105. package/lib/components/field/Multiselect/utils.js.map +1 -1
  106. package/lib/components/field/ObjectReference/ObjectReference.d.ts +16 -0
  107. package/lib/components/field/ObjectReference/ObjectReference.d.ts.map +1 -0
  108. package/lib/components/field/ObjectReference/ObjectReference.js +165 -0
  109. package/lib/components/field/ObjectReference/ObjectReference.js.map +1 -0
  110. package/lib/components/field/ObjectReference/index.d.ts +2 -0
  111. package/lib/components/field/ObjectReference/index.d.ts.map +1 -0
  112. package/lib/components/field/ObjectReference/index.js +2 -0
  113. package/lib/components/field/ObjectReference/index.js.map +1 -0
  114. package/lib/components/field/ObjectReference/utils.d.ts +17 -0
  115. package/lib/components/field/ObjectReference/utils.d.ts.map +1 -0
  116. package/lib/components/field/ObjectReference/utils.js +99 -0
  117. package/lib/components/field/ObjectReference/utils.js.map +1 -0
  118. package/lib/components/field/Percentage/Percentage.d.ts +1 -1
  119. package/lib/components/field/Percentage/Percentage.d.ts.map +1 -1
  120. package/lib/components/field/Percentage/Percentage.js +2 -5
  121. package/lib/components/field/Percentage/Percentage.js.map +1 -1
  122. package/lib/components/field/Phone/Phone.d.ts +1 -1
  123. package/lib/components/field/Phone/Phone.d.ts.map +1 -1
  124. package/lib/components/field/Phone/Phone.js +6 -4
  125. package/lib/components/field/Phone/Phone.js.map +1 -1
  126. package/lib/components/field/RadioButtons/RadioButtons.d.ts +8 -1
  127. package/lib/components/field/RadioButtons/RadioButtons.d.ts.map +1 -1
  128. package/lib/components/field/RadioButtons/RadioButtons.js +12 -1
  129. package/lib/components/field/RadioButtons/RadioButtons.js.map +1 -1
  130. package/lib/components/field/RichText/RichText.css +79 -0
  131. package/lib/components/field/RichText/RichText.d.ts +2 -1
  132. package/lib/components/field/RichText/RichText.d.ts.map +1 -1
  133. package/lib/components/field/RichText/RichText.js +1 -0
  134. package/lib/components/field/RichText/RichText.js.map +1 -1
  135. package/lib/components/field/ScalarList/ScalarList.d.ts +1 -1
  136. package/lib/components/field/ScalarList/ScalarList.d.ts.map +1 -1
  137. package/lib/components/field/ScalarList/ScalarList.js +1 -2
  138. package/lib/components/field/ScalarList/ScalarList.js.map +1 -1
  139. package/lib/components/field/SelectableCard/SelectableCard.d.ts +2 -0
  140. package/lib/components/field/SelectableCard/SelectableCard.d.ts.map +1 -0
  141. package/lib/components/field/SelectableCard/SelectableCard.js +57 -0
  142. package/lib/components/field/SelectableCard/SelectableCard.js.map +1 -0
  143. package/lib/components/field/SelectableCard/index.d.ts +2 -0
  144. package/lib/components/field/SelectableCard/index.d.ts.map +1 -0
  145. package/lib/components/field/SelectableCard/index.js +2 -0
  146. package/lib/components/field/SelectableCard/index.js.map +1 -0
  147. package/lib/components/field/SelectableCard/utils.d.ts +13 -0
  148. package/lib/components/field/SelectableCard/utils.d.ts.map +1 -0
  149. package/lib/components/field/SelectableCard/utils.js +183 -0
  150. package/lib/components/field/SelectableCard/utils.js.map +1 -0
  151. package/lib/components/field/SemanticLink/SemanticLink.d.ts +10 -2
  152. package/lib/components/field/SemanticLink/SemanticLink.d.ts.map +1 -1
  153. package/lib/components/field/SemanticLink/SemanticLink.js +128 -15
  154. package/lib/components/field/SemanticLink/SemanticLink.js.map +1 -1
  155. package/lib/components/field/SemanticLink/utils.js +1 -1
  156. package/lib/components/field/SemanticLink/utils.js.map +1 -1
  157. package/lib/components/field/TextArea/TextArea.d.ts +1 -1
  158. package/lib/components/field/TextArea/TextArea.d.ts.map +1 -1
  159. package/lib/components/field/TextArea/TextArea.js +4 -5
  160. package/lib/components/field/TextArea/TextArea.js.map +1 -1
  161. package/lib/components/field/TextContent/TextContent.d.ts +1 -1
  162. package/lib/components/field/TextContent/TextContent.d.ts.map +1 -1
  163. package/lib/components/field/TextContent/TextContent.js +0 -1
  164. package/lib/components/field/TextContent/TextContent.js.map +1 -1
  165. package/lib/components/field/TextInput/TextInput.d.ts +1 -1
  166. package/lib/components/field/TextInput/TextInput.d.ts.map +1 -1
  167. package/lib/components/field/TextInput/TextInput.js +4 -5
  168. package/lib/components/field/TextInput/TextInput.js.map +1 -1
  169. package/lib/components/field/Time/Time.d.ts +1 -1
  170. package/lib/components/field/Time/Time.d.ts.map +1 -1
  171. package/lib/components/field/Time/Time.js +2 -5
  172. package/lib/components/field/Time/Time.js.map +1 -1
  173. package/lib/components/field/URL/URL.d.ts +1 -1
  174. package/lib/components/field/URL/URL.d.ts.map +1 -1
  175. package/lib/components/field/URL/URL.js +4 -5
  176. package/lib/components/field/URL/URL.js.map +1 -1
  177. package/lib/components/field/UserReference/UserReference.d.ts +1 -2
  178. package/lib/components/field/UserReference/UserReference.d.ts.map +1 -1
  179. package/lib/components/field/UserReference/UserReference.js +1 -2
  180. package/lib/components/field/UserReference/UserReference.js.map +1 -1
  181. package/lib/components/field/UserReference/UserReferenceUtils.d.ts.map +1 -1
  182. package/lib/components/field/UserReference/UserReferenceUtils.js.map +1 -1
  183. package/lib/components/helpers/attachmentShared.d.ts +2 -0
  184. package/lib/components/helpers/attachmentShared.d.ts.map +1 -0
  185. package/lib/components/helpers/attachmentShared.js +6 -0
  186. package/lib/components/helpers/attachmentShared.js.map +1 -0
  187. package/lib/components/helpers/case-utils.js.map +1 -1
  188. package/lib/components/helpers/common-utils.d.ts +1 -1
  189. package/lib/components/helpers/common-utils.d.ts.map +1 -1
  190. package/lib/components/helpers/common-utils.js +1 -2
  191. package/lib/components/helpers/common-utils.js.map +1 -1
  192. package/lib/components/helpers/data_page.d.ts.map +1 -1
  193. package/lib/components/helpers/data_page.js +0 -1
  194. package/lib/components/helpers/data_page.js.map +1 -1
  195. package/lib/components/helpers/date-format-utils.d.ts.map +1 -1
  196. package/lib/components/helpers/event-utils.d.ts.map +1 -1
  197. package/lib/components/helpers/event-utils.js.map +1 -1
  198. package/lib/components/helpers/field-group-utils.d.ts +1 -1
  199. package/lib/components/helpers/field-group-utils.d.ts.map +1 -1
  200. package/lib/components/helpers/field-group-utils.js.map +1 -1
  201. package/lib/components/helpers/formatters/Boolean.js.map +1 -1
  202. package/lib/components/helpers/formatters/Currency.d.ts +1 -0
  203. package/lib/components/helpers/formatters/Currency.d.ts.map +1 -1
  204. package/lib/components/helpers/formatters/Currency.js +8 -4
  205. package/lib/components/helpers/formatters/Currency.js.map +1 -1
  206. package/lib/components/helpers/formatters/CurrencyMap.d.ts.map +1 -1
  207. package/lib/components/helpers/formatters/CurrencyMap.js +0 -1
  208. package/lib/components/helpers/formatters/CurrencyMap.js.map +1 -1
  209. package/lib/components/helpers/formatters/Date.js.map +1 -1
  210. package/lib/components/helpers/formatters/index.d.ts +1 -0
  211. package/lib/components/helpers/formatters/index.d.ts.map +1 -1
  212. package/lib/components/helpers/formatters/index.js.map +1 -1
  213. package/lib/components/helpers/instructions-utils.d.ts.map +1 -1
  214. package/lib/components/helpers/object-utils.d.ts +9 -0
  215. package/lib/components/helpers/object-utils.d.ts.map +1 -0
  216. package/lib/components/helpers/object-utils.js +11 -0
  217. package/lib/components/helpers/object-utils.js.map +1 -0
  218. package/lib/components/helpers/reactContextHelpers.d.ts +0 -1
  219. package/lib/components/helpers/reactContextHelpers.d.ts.map +1 -1
  220. package/lib/components/helpers/simpleTableHelpers.d.ts +15 -1
  221. package/lib/components/helpers/simpleTableHelpers.d.ts.map +1 -1
  222. package/lib/components/helpers/simpleTableHelpers.js +111 -5
  223. package/lib/components/helpers/simpleTableHelpers.js.map +1 -1
  224. package/lib/components/helpers/state-utils.d.ts.map +1 -1
  225. package/lib/components/helpers/state-utils.js.map +1 -1
  226. package/lib/components/helpers/template-utils.js.map +1 -1
  227. package/lib/components/helpers/utils.d.ts +1 -0
  228. package/lib/components/helpers/utils.d.ts.map +1 -1
  229. package/lib/components/helpers/utils.js +7 -1
  230. package/lib/components/helpers/utils.js.map +1 -1
  231. package/lib/components/helpers/versionHelpers.d.ts.map +1 -1
  232. package/lib/components/helpers/versionHelpers.js +0 -1
  233. package/lib/components/helpers/versionHelpers.js.map +1 -1
  234. package/lib/components/infra/ActionButtons/ActionButtons.d.ts.map +1 -1
  235. package/lib/components/infra/ActionButtons/ActionButtons.js +12 -7
  236. package/lib/components/infra/ActionButtons/ActionButtons.js.map +1 -1
  237. package/lib/components/infra/Assignment/Assignment.d.ts +2 -2
  238. package/lib/components/infra/Assignment/Assignment.d.ts.map +1 -1
  239. package/lib/components/infra/Assignment/Assignment.js +32 -28
  240. package/lib/components/infra/Assignment/Assignment.js.map +1 -1
  241. package/lib/components/infra/AssignmentCard/AssignmentCard.d.ts +2 -2
  242. package/lib/components/infra/AssignmentCard/AssignmentCard.d.ts.map +1 -1
  243. package/lib/components/infra/AssignmentCard/AssignmentCard.js.map +1 -1
  244. package/lib/components/infra/Containers/FlowContainer/FlowContainer.d.ts +1 -2
  245. package/lib/components/infra/Containers/FlowContainer/FlowContainer.d.ts.map +1 -1
  246. package/lib/components/infra/Containers/FlowContainer/FlowContainer.js +15 -79
  247. package/lib/components/infra/Containers/FlowContainer/FlowContainer.js.map +1 -1
  248. package/lib/components/infra/Containers/FlowContainer/helpers.d.ts.map +1 -1
  249. package/lib/components/infra/Containers/FlowContainer/helpers.js.map +1 -1
  250. package/lib/components/infra/Containers/ModalViewContainer/ListViewActionButtons/ListViewActionButtons.d.ts +1 -1
  251. package/lib/components/infra/Containers/ModalViewContainer/ListViewActionButtons/ListViewActionButtons.d.ts.map +1 -1
  252. package/lib/components/infra/Containers/ModalViewContainer/ListViewActionButtons/ListViewActionButtons.js +0 -1
  253. package/lib/components/infra/Containers/ModalViewContainer/ListViewActionButtons/ListViewActionButtons.js.map +1 -1
  254. package/lib/components/infra/Containers/ModalViewContainer/ModalViewContainer.d.ts +1 -1
  255. package/lib/components/infra/Containers/ModalViewContainer/ModalViewContainer.d.ts.map +1 -1
  256. package/lib/components/infra/Containers/ModalViewContainer/ModalViewContainer.js +4 -5
  257. package/lib/components/infra/Containers/ModalViewContainer/ModalViewContainer.js.map +1 -1
  258. package/lib/components/infra/Containers/SimpleView/SimpleView.d.ts +0 -1
  259. package/lib/components/infra/Containers/SimpleView/SimpleView.d.ts.map +1 -1
  260. package/lib/components/infra/Containers/SimpleView/helper.d.ts +0 -1
  261. package/lib/components/infra/Containers/SimpleView/helper.d.ts.map +1 -1
  262. package/lib/components/infra/Containers/SimpleView/helper.js.map +1 -1
  263. package/lib/components/infra/Containers/ViewContainer/ViewContainer.d.ts +1 -1
  264. package/lib/components/infra/Containers/ViewContainer/ViewContainer.d.ts.map +1 -1
  265. package/lib/components/infra/Containers/ViewContainer/ViewContainer.js +3 -4
  266. package/lib/components/infra/Containers/ViewContainer/ViewContainer.js.map +1 -1
  267. package/lib/components/infra/Containers/container-helpers.d.ts +1 -0
  268. package/lib/components/infra/Containers/container-helpers.d.ts.map +1 -1
  269. package/lib/components/infra/Containers/container-helpers.js +46 -1
  270. package/lib/components/infra/Containers/container-helpers.js.map +1 -1
  271. package/lib/components/infra/DashboardFilter/DashboardFilter.d.ts +2 -2
  272. package/lib/components/infra/DashboardFilter/DashboardFilter.d.ts.map +1 -1
  273. package/lib/components/infra/DashboardFilter/DashboardFilter.js +1 -4
  274. package/lib/components/infra/DashboardFilter/DashboardFilter.js.map +1 -1
  275. package/lib/components/infra/DashboardFilter/filterUtils.d.ts.map +1 -1
  276. package/lib/components/infra/DashboardFilter/filterUtils.js +2 -3
  277. package/lib/components/infra/DashboardFilter/filterUtils.js.map +1 -1
  278. package/lib/components/infra/DeferLoad/DeferLoad.d.ts +1 -1
  279. package/lib/components/infra/DeferLoad/DeferLoad.d.ts.map +1 -1
  280. package/lib/components/infra/DeferLoad/DeferLoad.js +2 -4
  281. package/lib/components/infra/DeferLoad/DeferLoad.js.map +1 -1
  282. package/lib/components/infra/ErrorBoundary/ErrorBoundary.d.ts +1 -1
  283. package/lib/components/infra/ErrorBoundary/ErrorBoundary.d.ts.map +1 -1
  284. package/lib/components/infra/ErrorBoundary/ErrorBoundary.js +0 -2
  285. package/lib/components/infra/ErrorBoundary/ErrorBoundary.js.map +1 -1
  286. package/lib/components/infra/MultiStep/MultiStep.css +48 -70
  287. package/lib/components/infra/MultiStep/MultiStep.d.ts +2 -2
  288. package/lib/components/infra/MultiStep/MultiStep.d.ts.map +1 -1
  289. package/lib/components/infra/MultiStep/MultiStep.js +19 -37
  290. package/lib/components/infra/MultiStep/MultiStep.js.map +1 -1
  291. package/lib/components/infra/NavBar/NavBar.css +1 -1
  292. package/lib/components/infra/NavBar/NavBar.d.ts +1 -1
  293. package/lib/components/infra/NavBar/NavBar.d.ts.map +1 -1
  294. package/lib/components/infra/NavBar/NavBar.js +13 -7
  295. package/lib/components/infra/NavBar/NavBar.js.map +1 -1
  296. package/lib/components/infra/Reference/Reference.d.ts +1 -1
  297. package/lib/components/infra/Reference/Reference.d.ts.map +1 -1
  298. package/lib/components/infra/Reference/Reference.js +2 -3
  299. package/lib/components/infra/Reference/Reference.js.map +1 -1
  300. package/lib/components/infra/Region/Region.d.ts +1 -1
  301. package/lib/components/infra/Region/Region.d.ts.map +1 -1
  302. package/lib/components/infra/Region/Region.js.map +1 -1
  303. package/lib/components/infra/RootContainer/RootContainer.d.ts +2 -2
  304. package/lib/components/infra/RootContainer/RootContainer.d.ts.map +1 -1
  305. package/lib/components/infra/RootContainer/RootContainer.js +0 -1
  306. package/lib/components/infra/RootContainer/RootContainer.js.map +1 -1
  307. package/lib/components/infra/Stages/Stages.d.ts +1 -1
  308. package/lib/components/infra/Stages/Stages.d.ts.map +1 -1
  309. package/lib/components/infra/Stages/Stages.js +2 -2
  310. package/lib/components/infra/Stages/Stages.js.map +1 -1
  311. package/lib/components/infra/VerticalTabs/VerticalTabs/VerticalTabs.js +1 -1
  312. package/lib/components/infra/VerticalTabs/VerticalTabs/VerticalTabs.js.map +1 -1
  313. package/lib/components/infra/View/View.d.ts +2 -2
  314. package/lib/components/infra/View/View.d.ts.map +1 -1
  315. package/lib/components/infra/View/View.js +2 -1
  316. package/lib/components/infra/View/View.js.map +1 -1
  317. package/lib/components/template/AdvancedSearch/AdvancedSearch.d.ts +2 -0
  318. package/lib/components/template/AdvancedSearch/AdvancedSearch.d.ts.map +1 -0
  319. package/lib/components/template/AdvancedSearch/AdvancedSearch.js +68 -0
  320. package/lib/components/template/AdvancedSearch/AdvancedSearch.js.map +1 -0
  321. package/lib/components/template/AdvancedSearch/SearchGroup/persistUtils.d.ts +23 -0
  322. package/lib/components/template/AdvancedSearch/SearchGroup/persistUtils.d.ts.map +1 -0
  323. package/lib/components/template/AdvancedSearch/SearchGroup/persistUtils.js +26 -0
  324. package/lib/components/template/AdvancedSearch/SearchGroup/persistUtils.js.map +1 -0
  325. package/lib/components/template/AdvancedSearch/SearchGroups/SearchGroups.d.ts +3 -0
  326. package/lib/components/template/AdvancedSearch/SearchGroups/SearchGroups.d.ts.map +1 -0
  327. package/lib/components/template/AdvancedSearch/SearchGroups/SearchGroups.js +179 -0
  328. package/lib/components/template/AdvancedSearch/SearchGroups/SearchGroups.js.map +1 -0
  329. package/lib/components/template/AdvancedSearch/SearchGroups/hooks.d.ts +10 -0
  330. package/lib/components/template/AdvancedSearch/SearchGroups/hooks.d.ts.map +1 -0
  331. package/lib/components/template/AdvancedSearch/SearchGroups/hooks.js +25 -0
  332. package/lib/components/template/AdvancedSearch/SearchGroups/hooks.js.map +1 -0
  333. package/lib/components/template/AdvancedSearch/SearchGroups/index.d.ts +2 -0
  334. package/lib/components/template/AdvancedSearch/SearchGroups/index.d.ts.map +1 -0
  335. package/lib/components/template/AdvancedSearch/SearchGroups/index.js +2 -0
  336. package/lib/components/template/AdvancedSearch/SearchGroups/index.js.map +1 -0
  337. package/lib/components/template/AdvancedSearch/SearchGroups/utils.d.ts +16 -0
  338. package/lib/components/template/AdvancedSearch/SearchGroups/utils.d.ts.map +1 -0
  339. package/lib/components/template/AdvancedSearch/SearchGroups/utils.js +22 -0
  340. package/lib/components/template/AdvancedSearch/SearchGroups/utils.js.map +1 -0
  341. package/lib/components/template/AdvancedSearch/TemplateContext.d.ts +10 -0
  342. package/lib/components/template/AdvancedSearch/TemplateContext.d.ts.map +1 -0
  343. package/lib/components/template/AdvancedSearch/TemplateContext.js +11 -0
  344. package/lib/components/template/AdvancedSearch/TemplateContext.js.map +1 -0
  345. package/lib/components/template/AdvancedSearch/index.d.ts +2 -0
  346. package/lib/components/template/AdvancedSearch/index.d.ts.map +1 -0
  347. package/lib/components/template/AdvancedSearch/index.js +2 -0
  348. package/lib/components/template/AdvancedSearch/index.js.map +1 -0
  349. package/lib/components/template/AppShell/AppShell.css +1 -1
  350. package/lib/components/template/AppShell/AppShell.d.ts +2 -2
  351. package/lib/components/template/AppShell/AppShell.d.ts.map +1 -1
  352. package/lib/components/template/AppShell/AppShell.js +10 -13
  353. package/lib/components/template/AppShell/AppShell.js.map +1 -1
  354. package/lib/components/template/BannerPage/BannerPage.d.ts +2 -2
  355. package/lib/components/template/BannerPage/BannerPage.d.ts.map +1 -1
  356. package/lib/components/template/BannerPage/BannerPage.js.map +1 -1
  357. package/lib/components/template/CaseSummary/CaseSummary.d.ts +4 -2
  358. package/lib/components/template/CaseSummary/CaseSummary.d.ts.map +1 -1
  359. package/lib/components/template/CaseSummary/CaseSummary.js +24 -37
  360. package/lib/components/template/CaseSummary/CaseSummary.js.map +1 -1
  361. package/lib/components/template/CaseView/CaseView.d.ts +2 -2
  362. package/lib/components/template/CaseView/CaseView.d.ts.map +1 -1
  363. package/lib/components/template/CaseView/CaseView.js +13 -15
  364. package/lib/components/template/CaseView/CaseView.js.map +1 -1
  365. package/lib/components/template/CaseViewActionsMenu/CaseViewActionsMenu.d.ts +1 -1
  366. package/lib/components/template/CaseViewActionsMenu/CaseViewActionsMenu.d.ts.map +1 -1
  367. package/lib/components/template/CaseViewActionsMenu/CaseViewActionsMenu.js +1 -1
  368. package/lib/components/template/CaseViewActionsMenu/CaseViewActionsMenu.js.map +1 -1
  369. package/lib/components/template/Confirmation/Confirmation.d.ts +2 -2
  370. package/lib/components/template/Confirmation/Confirmation.d.ts.map +1 -1
  371. package/lib/components/template/Confirmation/Confirmation.js +0 -1
  372. package/lib/components/template/Confirmation/Confirmation.js.map +1 -1
  373. package/lib/components/template/DataReference/DataReference.d.ts +9 -2
  374. package/lib/components/template/DataReference/DataReference.d.ts.map +1 -1
  375. package/lib/components/template/DataReference/DataReference.js +239 -80
  376. package/lib/components/template/DataReference/DataReference.js.map +1 -1
  377. package/lib/components/template/DataReference/DataReferenceAdvancedSearchContext.d.ts +8 -0
  378. package/lib/components/template/DataReference/DataReferenceAdvancedSearchContext.d.ts.map +1 -0
  379. package/lib/components/template/DataReference/DataReferenceAdvancedSearchContext.js +9 -0
  380. package/lib/components/template/DataReference/DataReferenceAdvancedSearchContext.js.map +1 -0
  381. package/lib/components/template/DataReference/SearchForm.d.ts +3 -0
  382. package/lib/components/template/DataReference/SearchForm.d.ts.map +1 -0
  383. package/lib/components/template/DataReference/SearchForm.js +87 -0
  384. package/lib/components/template/DataReference/SearchForm.js.map +1 -0
  385. package/lib/components/template/DataReference/utils.d.ts +15 -0
  386. package/lib/components/template/DataReference/utils.d.ts.map +1 -0
  387. package/lib/components/template/DataReference/utils.js +75 -0
  388. package/lib/components/template/DataReference/utils.js.map +1 -0
  389. package/lib/components/template/DefaultForm/DefaultForm.d.ts +2 -2
  390. package/lib/components/template/DefaultForm/DefaultForm.d.ts.map +1 -1
  391. package/lib/components/template/DefaultForm/DefaultForm.js.map +1 -1
  392. package/lib/components/template/DefaultForm/utils/index.d.ts.map +1 -1
  393. package/lib/components/template/DefaultForm/utils/index.js +1 -2
  394. package/lib/components/template/DefaultForm/utils/index.js.map +1 -1
  395. package/lib/components/template/DefaultPage/DefaultPage.d.ts +36 -0
  396. package/lib/components/template/DefaultPage/DefaultPage.d.ts.map +1 -0
  397. package/lib/components/template/DefaultPage/DefaultPage.js +28 -0
  398. package/lib/components/template/DefaultPage/DefaultPage.js.map +1 -0
  399. package/lib/components/template/DefaultPage/index.d.ts +2 -0
  400. package/lib/components/template/DefaultPage/index.d.ts.map +1 -0
  401. package/lib/components/template/DefaultPage/index.js +2 -0
  402. package/lib/components/template/DefaultPage/index.js.map +1 -0
  403. package/lib/components/template/Details/Details/Details.d.ts +1 -1
  404. package/lib/components/template/Details/Details/Details.d.ts.map +1 -1
  405. package/lib/components/template/Details/Details/Details.js +2 -3
  406. package/lib/components/template/Details/Details/Details.js.map +1 -1
  407. package/lib/components/template/Details/DetailsSubTabs/DetailsSubTabs.d.ts +2 -2
  408. package/lib/components/template/Details/DetailsSubTabs/DetailsSubTabs.d.ts.map +1 -1
  409. package/lib/components/template/Details/DetailsSubTabs/DetailsSubTabs.js.map +1 -1
  410. package/lib/components/template/Details/DetailsThreeColumn/DetailsThreeColumn.d.ts +1 -1
  411. package/lib/components/template/Details/DetailsThreeColumn/DetailsThreeColumn.d.ts.map +1 -1
  412. package/lib/components/template/Details/DetailsThreeColumn/DetailsThreeColumn.js +2 -3
  413. package/lib/components/template/Details/DetailsThreeColumn/DetailsThreeColumn.js.map +1 -1
  414. package/lib/components/template/Details/DetailsTwoColumn/DetailsTwoColumn.d.ts +1 -1
  415. package/lib/components/template/Details/DetailsTwoColumn/DetailsTwoColumn.d.ts.map +1 -1
  416. package/lib/components/template/Details/DetailsTwoColumn/DetailsTwoColumn.js +2 -3
  417. package/lib/components/template/Details/DetailsTwoColumn/DetailsTwoColumn.js.map +1 -1
  418. package/lib/components/template/Details/DynamicTabs/DynamicTabs.d.ts +1 -1
  419. package/lib/components/template/Details/DynamicTabs/DynamicTabs.d.ts.map +1 -1
  420. package/lib/components/template/Details/DynamicTabs/DynamicTabs.js.map +1 -1
  421. package/lib/components/template/FieldGroupTemplate/FieldGroupTemplate.d.ts +1 -1
  422. package/lib/components/template/FieldGroupTemplate/FieldGroupTemplate.d.ts.map +1 -1
  423. package/lib/components/template/FieldGroupTemplate/FieldGroupTemplate.js +1 -2
  424. package/lib/components/template/FieldGroupTemplate/FieldGroupTemplate.js.map +1 -1
  425. package/lib/components/template/InlineDashboard/InlineDashboard.d.ts +2 -2
  426. package/lib/components/template/InlineDashboard/InlineDashboard.d.ts.map +1 -1
  427. package/lib/components/template/InlineDashboard/InlineDashboard.js +2 -2
  428. package/lib/components/template/InlineDashboard/InlineDashboard.js.map +1 -1
  429. package/lib/components/template/InlineDashboardPage/InlineDashboardPage.d.ts +2 -2
  430. package/lib/components/template/InlineDashboardPage/InlineDashboardPage.d.ts.map +1 -1
  431. package/lib/components/template/InlineDashboardPage/InlineDashboardPage.js.map +1 -1
  432. package/lib/components/template/ListPage/ListPage.d.ts +1 -1
  433. package/lib/components/template/ListPage/ListPage.d.ts.map +1 -1
  434. package/lib/components/template/ListPage/ListPage.js.map +1 -1
  435. package/lib/components/template/ListView/DefaultViewMeta.js.map +1 -1
  436. package/lib/components/template/ListView/ListView.d.ts +4 -1
  437. package/lib/components/template/ListView/ListView.d.ts.map +1 -1
  438. package/lib/components/template/ListView/ListView.js +133 -64
  439. package/lib/components/template/ListView/ListView.js.map +1 -1
  440. package/lib/components/template/ListView/hooks.d.ts.map +1 -1
  441. package/lib/components/template/ListView/hooks.js +2 -5
  442. package/lib/components/template/ListView/hooks.js.map +1 -1
  443. package/lib/components/template/ListView/utils.d.ts.map +1 -1
  444. package/lib/components/template/ListView/utils.js +28 -5
  445. package/lib/components/template/ListView/utils.js.map +1 -1
  446. package/lib/components/template/MultiReferenceReadOnly/MultiReferenceReadOnly.d.ts +1 -1
  447. package/lib/components/template/MultiReferenceReadOnly/MultiReferenceReadOnly.d.ts.map +1 -1
  448. package/lib/components/template/MultiReferenceReadOnly/MultiReferenceReadOnly.js.map +1 -1
  449. package/lib/components/template/NarrowWide/NarrowWide/NarrowWide.d.ts +2 -2
  450. package/lib/components/template/NarrowWide/NarrowWide/NarrowWide.d.ts.map +1 -1
  451. package/lib/components/template/NarrowWide/NarrowWide/NarrowWide.js.map +1 -1
  452. package/lib/components/template/NarrowWide/NarrowWideDetails/NarrowWideDetails.d.ts +1 -1
  453. package/lib/components/template/NarrowWide/NarrowWideDetails/NarrowWideDetails.d.ts.map +1 -1
  454. package/lib/components/template/NarrowWide/NarrowWideDetails/NarrowWideDetails.js +2 -3
  455. package/lib/components/template/NarrowWide/NarrowWideDetails/NarrowWideDetails.js.map +1 -1
  456. package/lib/components/template/NarrowWide/NarrowWideForm/NarrowWideForm.d.ts +2 -2
  457. package/lib/components/template/NarrowWide/NarrowWideForm/NarrowWideForm.d.ts.map +1 -1
  458. package/lib/components/template/NarrowWide/NarrowWideForm/NarrowWideForm.js.map +1 -1
  459. package/lib/components/template/NarrowWide/NarrowWidePage/NarrowWidePage.d.ts +2 -2
  460. package/lib/components/template/NarrowWide/NarrowWidePage/NarrowWidePage.d.ts.map +1 -1
  461. package/lib/components/template/NarrowWide/NarrowWidePage/NarrowWidePage.js.map +1 -1
  462. package/lib/components/template/OneColumn/OneColumn/OneColumn.d.ts +2 -2
  463. package/lib/components/template/OneColumn/OneColumn/OneColumn.d.ts.map +1 -1
  464. package/lib/components/template/OneColumn/OneColumn/OneColumn.js +2 -2
  465. package/lib/components/template/OneColumn/OneColumn/OneColumn.js.map +1 -1
  466. package/lib/components/template/OneColumn/OneColumnPage/OneColumnPage.d.ts +1 -1
  467. package/lib/components/template/OneColumn/OneColumnPage/OneColumnPage.d.ts.map +1 -1
  468. package/lib/components/template/OneColumn/OneColumnPage/OneColumnPage.js.map +1 -1
  469. package/lib/components/template/OneColumn/OneColumnTab/OneColumnTab.d.ts +2 -2
  470. package/lib/components/template/OneColumn/OneColumnTab/OneColumnTab.d.ts.map +1 -1
  471. package/lib/components/template/OneColumn/OneColumnTab/OneColumnTab.js.map +1 -1
  472. package/lib/components/template/PromotedFilters/PromotedFilters.d.ts +1 -1
  473. package/lib/components/template/PromotedFilters/PromotedFilters.d.ts.map +1 -1
  474. package/lib/components/template/PromotedFilters/PromotedFilters.js +0 -1
  475. package/lib/components/template/PromotedFilters/PromotedFilters.js.map +1 -1
  476. package/lib/components/template/SelfServiceCaseView/SelfServiceCaseView.d.ts +2 -0
  477. package/lib/components/template/SelfServiceCaseView/SelfServiceCaseView.d.ts.map +1 -0
  478. package/lib/components/template/SelfServiceCaseView/SelfServiceCaseView.js +73 -0
  479. package/lib/components/template/SelfServiceCaseView/SelfServiceCaseView.js.map +1 -0
  480. package/lib/components/template/SelfServiceCaseView/index.d.ts +2 -0
  481. package/lib/components/template/SelfServiceCaseView/index.d.ts.map +1 -0
  482. package/lib/components/template/SelfServiceCaseView/index.js +2 -0
  483. package/lib/components/template/SelfServiceCaseView/index.js.map +1 -0
  484. package/lib/components/template/SimpleTable/SimpleTable/SimpleTable.d.ts +1 -1
  485. package/lib/components/template/SimpleTable/SimpleTable/SimpleTable.d.ts.map +1 -1
  486. package/lib/components/template/SimpleTable/SimpleTable/SimpleTable.js +1 -2
  487. package/lib/components/template/SimpleTable/SimpleTable/SimpleTable.js.map +1 -1
  488. package/lib/components/template/SimpleTable/SimpleTableManual/SimpleTableManual.d.ts +2 -2
  489. package/lib/components/template/SimpleTable/SimpleTableManual/SimpleTableManual.d.ts.map +1 -1
  490. package/lib/components/template/SimpleTable/SimpleTableManual/SimpleTableManual.js +34 -32
  491. package/lib/components/template/SimpleTable/SimpleTableManual/SimpleTableManual.js.map +1 -1
  492. package/lib/components/template/SimpleTable/SimpleTableSelect/SimpleTableSelect.d.ts +1 -1
  493. package/lib/components/template/SimpleTable/SimpleTableSelect/SimpleTableSelect.d.ts.map +1 -1
  494. package/lib/components/template/SimpleTable/SimpleTableSelect/SimpleTableSelect.js.map +1 -1
  495. package/lib/components/template/SingleReferenceReadOnly/SingleReferenceReadOnly.d.ts +1 -1
  496. package/lib/components/template/SingleReferenceReadOnly/SingleReferenceReadOnly.d.ts.map +1 -1
  497. package/lib/components/template/SingleReferenceReadOnly/SingleReferenceReadOnly.js +3 -2
  498. package/lib/components/template/SingleReferenceReadOnly/SingleReferenceReadOnly.js.map +1 -1
  499. package/lib/components/template/SubTabs/SubTabs.d.ts +2 -2
  500. package/lib/components/template/SubTabs/SubTabs.d.ts.map +1 -1
  501. package/lib/components/template/SubTabs/SubTabs.js.map +1 -1
  502. package/lib/components/template/SubTabs/tabUtils.d.ts +10 -0
  503. package/lib/components/template/SubTabs/tabUtils.d.ts.map +1 -1
  504. package/lib/components/template/SubTabs/tabUtils.js +102 -1
  505. package/lib/components/template/SubTabs/tabUtils.js.map +1 -1
  506. package/lib/components/template/TwoColumn/TwoColumn/TwoColumn.d.ts +2 -2
  507. package/lib/components/template/TwoColumn/TwoColumn/TwoColumn.d.ts.map +1 -1
  508. package/lib/components/template/TwoColumn/TwoColumn/TwoColumn.js +2 -3
  509. package/lib/components/template/TwoColumn/TwoColumn/TwoColumn.js.map +1 -1
  510. package/lib/components/template/TwoColumn/TwoColumnPage/TwoColumnPage.d.ts +1 -1
  511. package/lib/components/template/TwoColumn/TwoColumnPage/TwoColumnPage.d.ts.map +1 -1
  512. package/lib/components/template/TwoColumn/TwoColumnPage/TwoColumnPage.js.map +1 -1
  513. package/lib/components/template/TwoColumn/TwoColumnTab/TwoColumnTab.d.ts +2 -2
  514. package/lib/components/template/TwoColumn/TwoColumnTab/TwoColumnTab.d.ts.map +1 -1
  515. package/lib/components/template/TwoColumn/TwoColumnTab/TwoColumnTab.js +2 -3
  516. package/lib/components/template/TwoColumn/TwoColumnTab/TwoColumnTab.js.map +1 -1
  517. package/lib/components/template/WideNarrow/WideNarrow/WideNarrow.d.ts +2 -2
  518. package/lib/components/template/WideNarrow/WideNarrow/WideNarrow.d.ts.map +1 -1
  519. package/lib/components/template/WideNarrow/WideNarrow/WideNarrow.js.map +1 -1
  520. package/lib/components/template/WideNarrow/WideNarrowDetails/WideNarrowDetails.d.ts +1 -1
  521. package/lib/components/template/WideNarrow/WideNarrowDetails/WideNarrowDetails.d.ts.map +1 -1
  522. package/lib/components/template/WideNarrow/WideNarrowDetails/WideNarrowDetails.js +2 -3
  523. package/lib/components/template/WideNarrow/WideNarrowDetails/WideNarrowDetails.js.map +1 -1
  524. package/lib/components/template/WideNarrow/WideNarrowForm/WideNarrowForm.d.ts +2 -2
  525. package/lib/components/template/WideNarrow/WideNarrowForm/WideNarrowForm.d.ts.map +1 -1
  526. package/lib/components/template/WideNarrow/WideNarrowForm/WideNarrowForm.js.map +1 -1
  527. package/lib/components/template/WideNarrow/WideNarrowPage/WideNarrowPage.d.ts +2 -2
  528. package/lib/components/template/WideNarrow/WideNarrowPage/WideNarrowPage.d.ts.map +1 -1
  529. package/lib/components/template/WideNarrow/WideNarrowPage/WideNarrowPage.js.map +1 -1
  530. package/lib/components/template/WssNavBar/WssNavBar.css +1 -1
  531. package/lib/components/template/WssNavBar/WssNavBar.d.ts +1 -1
  532. package/lib/components/template/WssNavBar/WssNavBar.d.ts.map +1 -1
  533. package/lib/components/template/WssNavBar/WssNavBar.js +4 -4
  534. package/lib/components/template/WssNavBar/WssNavBar.js.map +1 -1
  535. package/lib/components/template/utils.d.ts +7 -0
  536. package/lib/components/template/utils.d.ts.map +1 -0
  537. package/lib/components/template/utils.js +52 -0
  538. package/lib/components/template/utils.js.map +1 -0
  539. package/lib/components/widget/AppAnnouncement/AppAnnouncement.d.ts +1 -1
  540. package/lib/components/widget/AppAnnouncement/AppAnnouncement.d.ts.map +1 -1
  541. package/lib/components/widget/AppAnnouncement/AppAnnouncement.js.map +1 -1
  542. package/lib/components/widget/Attachment/Attachment.css +6 -8
  543. package/lib/components/widget/Attachment/Attachment.d.ts +4 -2
  544. package/lib/components/widget/Attachment/Attachment.d.ts.map +1 -1
  545. package/lib/components/widget/Attachment/Attachment.js +255 -202
  546. package/lib/components/widget/Attachment/Attachment.js.map +1 -1
  547. package/lib/components/widget/Attachment/Attachment.types.d.ts +90 -0
  548. package/lib/components/widget/Attachment/Attachment.types.d.ts.map +1 -0
  549. package/lib/components/widget/Attachment/Attachment.types.js +2 -0
  550. package/lib/components/widget/Attachment/Attachment.types.js.map +1 -0
  551. package/lib/components/widget/Attachment/AttachmentUtils.d.ts +25 -0
  552. package/lib/components/widget/Attachment/AttachmentUtils.d.ts.map +1 -0
  553. package/lib/components/widget/Attachment/AttachmentUtils.js +255 -0
  554. package/lib/components/widget/Attachment/AttachmentUtils.js.map +1 -0
  555. package/lib/components/widget/CaseHistory/CaseHistory.d.ts +1 -1
  556. package/lib/components/widget/CaseHistory/CaseHistory.d.ts.map +1 -1
  557. package/lib/components/widget/CaseHistory/CaseHistory.js +2 -2
  558. package/lib/components/widget/CaseHistory/CaseHistory.js.map +1 -1
  559. package/lib/components/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.css +0 -14
  560. package/lib/components/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.d.ts +1 -1
  561. package/lib/components/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.d.ts.map +1 -1
  562. package/lib/components/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.js +1 -1
  563. package/lib/components/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.js.map +1 -1
  564. package/lib/components/widget/FileUtility/FileUtility/FileUtility.css +7 -6
  565. package/lib/components/widget/FileUtility/FileUtility/FileUtility.d.ts +2 -1
  566. package/lib/components/widget/FileUtility/FileUtility/FileUtility.d.ts.map +1 -1
  567. package/lib/components/widget/FileUtility/FileUtility/FileUtility.js +29 -17
  568. package/lib/components/widget/FileUtility/FileUtility/FileUtility.js.map +1 -1
  569. package/lib/components/widget/Followers/Followers.d.ts +2 -2
  570. package/lib/components/widget/Followers/Followers.d.ts.map +1 -1
  571. package/lib/components/widget/Followers/Followers.js +0 -2
  572. package/lib/components/widget/Followers/Followers.js.map +1 -1
  573. package/lib/components/widget/QuickCreate/QuickCreate.d.ts +1 -1
  574. package/lib/components/widget/QuickCreate/QuickCreate.d.ts.map +1 -1
  575. package/lib/components/widget/QuickCreate/QuickCreate.js +0 -1
  576. package/lib/components/widget/QuickCreate/QuickCreate.js.map +1 -1
  577. package/lib/components/widget/SummaryItem/SummaryItem.css +9 -11
  578. package/lib/components/widget/SummaryItem/SummaryItem.d.ts +1 -1
  579. package/lib/components/widget/SummaryItem/SummaryItem.d.ts.map +1 -1
  580. package/lib/components/widget/SummaryItem/SummaryItem.js +1 -1
  581. package/lib/components/widget/SummaryItem/SummaryItem.js.map +1 -1
  582. package/lib/components/widget/SummaryList/SummaryList.d.ts +1 -1
  583. package/lib/components/widget/SummaryList/SummaryList.d.ts.map +1 -1
  584. package/lib/components/widget/SummaryList/SummaryList.js.map +1 -1
  585. package/lib/components/widget/ToDo/ToDo.css +1 -13
  586. package/lib/components/widget/ToDo/ToDo.d.ts +1 -1
  587. package/lib/components/widget/ToDo/ToDo.d.ts.map +1 -1
  588. package/lib/components/widget/ToDo/ToDo.js +21 -16
  589. package/lib/components/widget/ToDo/ToDo.js.map +1 -1
  590. package/lib/hooks/useAfterInitialEffect.d.ts +1 -1
  591. package/lib/hooks/useAfterInitialEffect.d.ts.map +1 -1
  592. package/lib/hooks/useAfterInitialEffect.js.map +1 -1
  593. package/lib/hooks/useConsolidatedRef.d.ts +1 -1
  594. package/lib/hooks/useConsolidatedRef.d.ts.map +1 -1
  595. package/lib/hooks/useConsolidatedRef.js.map +1 -1
  596. package/lib/hooks/useFocusFirstField.d.ts.map +1 -1
  597. package/lib/hooks/useFocusFirstField.js.map +1 -1
  598. package/lib/hooks/useGetTabsCount.d.ts +10 -0
  599. package/lib/hooks/useGetTabsCount.d.ts.map +1 -0
  600. package/lib/hooks/useGetTabsCount.js +165 -0
  601. package/lib/hooks/useGetTabsCount.js.map +1 -0
  602. package/lib/hooks/useIsMount.d.ts +2 -0
  603. package/lib/hooks/useIsMount.d.ts.map +1 -0
  604. package/lib/hooks/useIsMount.js +9 -0
  605. package/lib/hooks/useIsMount.js.map +1 -0
  606. package/lib/hooks/useScrolltoTop.d.ts.map +1 -1
  607. package/lib/mediaco/ToDo/ToDo.css +81 -0
  608. package/lib/mediaco/ToDo/ToDo.d.ts +16 -0
  609. package/lib/mediaco/ToDo/ToDo.d.ts.map +1 -0
  610. package/lib/mediaco/ToDo/ToDo.js +187 -0
  611. package/lib/mediaco/ToDo/ToDo.js.map +1 -0
  612. package/lib/mediaco/ToDo/index.d.ts +2 -0
  613. package/lib/mediaco/ToDo/index.d.ts.map +1 -0
  614. package/lib/mediaco/ToDo/index.js +2 -0
  615. package/lib/mediaco/ToDo/index.js.map +1 -0
  616. package/lib/samples/Embedded/styles.css +26 -0
  617. package/lib/sdk-pega-component-map.d.ts +119 -103
  618. package/lib/sdk-pega-component-map.d.ts.map +1 -1
  619. package/lib/sdk-pega-component-map.js +20 -3
  620. package/lib/sdk-pega-component-map.js.map +1 -1
  621. package/lib/theme.d.ts +30 -1
  622. package/lib/theme.d.ts.map +1 -1
  623. package/lib/theme.js +209 -2
  624. package/lib/theme.js.map +1 -1
  625. package/lib/types/PConnProps.d.ts +1 -1
  626. package/package.json +32 -1
  627. package/lib/components/helpers/attachmentHelpers.d.ts +0 -13
  628. package/lib/components/helpers/attachmentHelpers.d.ts.map +0 -1
  629. package/lib/components/helpers/attachmentHelpers.js +0 -72
  630. package/lib/components/helpers/attachmentHelpers.js.map +0 -1
@@ -1,4 +1,4 @@
1
- import { PConnProps } from '../../../types/PConnProps';
1
+ import type { PConnProps } from '../../../types/PConnProps';
2
2
  interface CaseHistoryProps extends PConnProps {
3
3
  }
4
4
  export default function CaseHistory(props: CaseHistoryProps): import("react/jsx-runtime").JSX.Element;
@@ -1 +1 @@
1
- {"version":3,"file":"CaseHistory.d.ts","sourceRoot":"","sources":["../../../../src/components/widget/CaseHistory/CaseHistory.tsx"],"names":[],"mappings":"AAaA,OAAO,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AAEvD,UAAU,gBAAiB,SAAQ,UAAU;CAE5C;AAoBD,MAAM,CAAC,OAAO,UAAU,WAAW,CAAC,KAAK,EAAE,gBAAgB,2CAqI1D"}
1
+ {"version":3,"file":"CaseHistory.d.ts","sourceRoot":"","sources":["../../../../src/components/widget/CaseHistory/CaseHistory.tsx"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AAE5D,UAAU,gBAAiB,SAAQ,UAAU;CAE5C;AAoBD,MAAM,CAAC,OAAO,UAAU,WAAW,CAAC,KAAK,EAAE,gBAAgB,2CAqI1D"}
@@ -34,12 +34,12 @@ export default function CaseHistory(props) {
34
34
  label: thePConn.getLocalizedValue('Date', '', ''),
35
35
  type: 'DateTime',
36
36
  fieldName: 'pxTimeCreated'
37
- },
37
+ }, // 2nd and 3rd args empty string until typedef marked correctly
38
38
  {
39
39
  label: thePConn.getLocalizedValue('Description', '', ''),
40
40
  type: 'TextInput',
41
41
  fieldName: 'pyMessageKey'
42
- },
42
+ }, // 2nd and 3rd args empty string until typedef marked correctly
43
43
  {
44
44
  label: thePConn.getLocalizedValue('Performed by', '', ''),
45
45
  type: 'TextInput',
@@ -1 +1 @@
1
- {"version":3,"file":"CaseHistory.js","sourceRoot":"","sources":["../../../../src/components/widget/CaseHistory/CaseHistory.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,EA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ACjC,GACO,GACb,CACP,CAAC;AACJ,CAAC","sourcesContent":["import { useEffect, useRef, useState } from 'react';\nimport { Theme } from '@mui/material/styles';\nimport withStyles from '@mui/styles/withStyles';\nimport createStyles from '@mui/styles/createStyles';\nimport Table from '@mui/material/Table';\nimport TableBody from '@mui/material/TableBody';\nimport TableCell from '@mui/material/TableCell';\nimport TableContainer from '@mui/material/TableContainer';\nimport TableHead from '@mui/material/TableHead';\nimport TableRow from '@mui/material/TableRow';\nimport isDeepEqual from 'fast-deep-equal/react';\n\nimport { Utils } from '../../helpers/utils';\nimport { PConnProps } from '../../../types/PConnProps';\n\ninterface CaseHistoryProps extends PConnProps {\n // If any, enter additional props that only exist on this component\n}\n\nconst StyledTableCell = withStyles((theme: Theme) =>\n createStyles({\n head: {\n borderWidth: '1px',\n borderStyle: 'solid',\n borderColor: 'silver',\n backgroundColor: theme.palette.text.disabled,\n color: theme.palette.getContrastText(theme.palette.text.disabled)\n },\n body: {\n borderWidth: '1px',\n borderStyle: 'solid',\n borderColor: 'silver'\n // fontSize: 14,\n }\n })\n)(TableCell);\n\nexport default function CaseHistory(props: CaseHistoryProps) {\n const { getPConnect } = props;\n const thePConn = getPConnect();\n // let waitingForData = true;\n\n const displayedColumns = [\n {\n label: thePConn.getLocalizedValue('Date', '', ''),\n type: 'DateTime',\n fieldName: 'pxTimeCreated'\n }, // 2nd and 3rd args empty string until typedef marked correctly\n {\n label: thePConn.getLocalizedValue('Description', '', ''),\n type: 'TextInput',\n fieldName: 'pyMessageKey'\n }, // 2nd and 3rd args empty string until typedef marked correctly\n {\n label: thePConn.getLocalizedValue('Performed by', '', ''),\n type: 'TextInput',\n fieldName: 'pyPerformer'\n } // 2nd and 3rd args empty string until typedef marked correctly\n ];\n\n const rowData: any = useRef([]);\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n const [waitingForData, setWaitingForData] = useState<boolean>(true);\n\n const caseID = thePConn.getValue(PCore.getConstants().CASE_INFO.CASE_INFO_ID, ''); // 2nd arg empty string until typedef marked correctly\n const dataViewName = 'D_pyWorkHistory';\n const context = thePConn.getContextName();\n\n function computeRowData(rows: Object[]): void {\n const theRowData: Object[] = [];\n\n rows.forEach((row: any, rowIndex: number) => {\n // Now, for each property in the index of row properties (displayedColumns), add an object\n // to a new array of values\n const rowDisplayValues: any = [];\n\n displayedColumns.forEach((column: any, rowValIndex) => {\n const theType = column.type;\n const theFieldName = column.fieldName;\n const theValue =\n theType === 'Date' || theType === 'DateTime' ? Utils.generateDateTime(row[theFieldName], 'DateTime-Short') : row[theFieldName];\n rowDisplayValues[rowValIndex] = theValue;\n });\n\n theRowData[rowIndex] = rowDisplayValues;\n });\n\n if (!isDeepEqual(theRowData, rowData.current)) {\n // Only update rowData.current when it actually changes (to prevent infinite loop)\n rowData.current = theRowData;\n }\n }\n\n // Get the case history data when component mounted/initialized\n useEffect(() => {\n let bCallSetWaitingForData = true;\n\n const historyData = PCore.getDataApiUtils().getData(\n dataViewName,\n { dataViewParameters: [{ CaseInstanceKey: caseID }] } as any,\n context\n ) as Promise<any>;\n\n historyData.then((historyJSON: any) => {\n const tableDataResults = historyJSON.data.data;\n\n // compute the rowData using the tableDataResults\n computeRowData(tableDataResults);\n\n // At this point, if we have data ready to render and haven't been asked\n // to NOT call setWaitingForData, we can stop progress indicator\n if (bCallSetWaitingForData) {\n setWaitingForData(false);\n }\n });\n\n return () => {\n // Inspired by https://juliangaramendy.dev/blog/use-promise-subscription\n // The useEffect closure lets us have access to the bCallSetWaitingForData\n // variable inside the useEffect and inside the \"then\" clause of the\n // historyData promise\n // So, if this cleanup code gets run before the promise .then is called,\n // we can avoid calling the useState setter which would otherwise show a warning\n bCallSetWaitingForData = false;\n };\n }, []);\n\n function getTableHeader() {\n const theRowKey = 'CaseHistory.TableHeader';\n\n const theHeaderCells: any[] = displayedColumns.map((headerCol, index) => {\n const theCellKey = `${theRowKey}.${index}`;\n return <StyledTableCell key={theCellKey}>{headerCol.label}</StyledTableCell>;\n });\n\n return <TableRow key={theRowKey}>{theHeaderCells}</TableRow>;\n }\n\n function getTableData() {\n const theDataRows: any[] = [];\n\n // Note: using rowData.current since we're using useRef as a mutatable\n // value that's only updated when it changes.\n if (rowData.current.length > 0) {\n rowData.current.forEach((dataRow: Object[], index) => {\n // using dataRow[0]-dataRow[1] as the array key since it's a unique value\n const theKey = `CaseHistory-${index}`;\n theDataRows.push(\n <TableRow key={theKey}>\n <StyledTableCell>{dataRow[0] ? dataRow[0] : ('---' as any)}</StyledTableCell>\n <StyledTableCell>{dataRow[1] ? dataRow[1] : ('---' as any)}</StyledTableCell>\n <StyledTableCell>{dataRow[2] ? dataRow[2] : ('---' as any)}</StyledTableCell>\n </TableRow>\n );\n });\n }\n\n return theDataRows;\n }\n\n return (\n <div id='CaseHistory'>\n <TableContainer>\n <Table>\n <TableHead>{getTableHeader()}</TableHead>\n <TableBody>{getTableData()}</TableBody>\n </Table>\n </TableContainer>\n </div>\n );\n}\n"]}
1
+ {"version":3,"file":"CaseHistory.js","sourceRoot":"","sources":["../../../../src/components/widget/CaseHistory/CaseHistory.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAEpD,OAAO,UAAU,MAAM,wBAAwB,CAAC;AAChD,OAAO,YAAY,MAAM,0BAA0B,CAAC;AACpD,OAAO,KAAK,MAAM,qBAAqB,CAAC;AACxC,OAAO,SAAS,MAAM,yBAAyB,CAAC;AAChD,OAAO,SAAS,MAAM,yBAAyB,CAAC;AAChD,OAAO,cAAc,MAAM,8BAA8B,CAAC;AAC1D,OAAO,SAAS,MAAM,yBAAyB,CAAC;AAChD,OAAO,QAAQ,MAAM,wBAAwB,CAAC;AAC9C,OAAO,WAAW,MAAM,uBAAuB,CAAC;AAEhD,OAAO,EAAE,KAAK,EAAE,MAAM,qBAAqB,CAAC;AAO5C,MAAM,eAAe,GAAG,UAAU,CAAC,CAAC,KAAY,EAAE,EAAE,CAClD,YAAY,C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,OAAO,CAAC,CAAC,OAAiB,EAAE,KAAK,EAAE,EAAE;gBACnD,yEAAyE;gBACzE,MAAM,MAAM,GAAG,eAAe,KAAK,EAAE,CAAC;gBACtC,WAAW,CAAC,IAAI,CACd,MAAC,QAAQ,eACP,KAAC,eAAe,cAAE,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAE,KAAa,GAAmB,EAC7E,KAAC,eAAe,cAAE,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAE,KAAa,GAAmB,EAC7E,KAAC,eAAe,cAAE,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAE,KAAa,GAAmB,KAHhE,MAAM,CAIV,CACZ,CAAC;YACJ,CAAC,CAAC,CAAC;QACL,CAAC;QAED,OAAO,WAAW,CAAC;IACrB,CAAC;IAED,OAAO,CACL,cAAK,EAAE,EAAC,aAAa,YACnB,KAAC,cAAc,cACb,MAAC,KAAK,eACJ,KAAC,SAAS,cAAE,cAAc,EAAE,GAAa,EACzC,KAAC,SAAS,cAAE,YAAY,EAAE,GAAa,IACjC,GACO,GACb,CACP,CAAC;AACJ,CAAC","sourcesContent":["import { useEffect, useRef, useState } from 'react';\nimport type { Theme } from '@mui/material/styles';\nimport withStyles from '@mui/styles/withStyles';\nimport createStyles from '@mui/styles/createStyles';\nimport Table from '@mui/material/Table';\nimport TableBody from '@mui/material/TableBody';\nimport TableCell from '@mui/material/TableCell';\nimport TableContainer from '@mui/material/TableContainer';\nimport TableHead from '@mui/material/TableHead';\nimport TableRow from '@mui/material/TableRow';\nimport isDeepEqual from 'fast-deep-equal/react';\n\nimport { Utils } from '../../helpers/utils';\nimport type { PConnProps } from '../../../types/PConnProps';\n\ninterface CaseHistoryProps extends PConnProps {\n // If any, enter additional props that only exist on this component\n}\n\nconst StyledTableCell = withStyles((theme: Theme) =>\n createStyles({\n head: {\n borderWidth: '1px',\n borderStyle: 'solid',\n borderColor: 'silver',\n backgroundColor: theme.palette.text.disabled,\n color: theme.palette.getContrastText(theme.palette.text.disabled)\n },\n body: {\n borderWidth: '1px',\n borderStyle: 'solid',\n borderColor: 'silver'\n // fontSize: 14,\n }\n })\n)(TableCell);\n\nexport default function CaseHistory(props: CaseHistoryProps) {\n const { getPConnect } = props;\n const thePConn = getPConnect();\n // let waitingForData = true;\n\n const displayedColumns = [\n {\n label: thePConn.getLocalizedValue('Date', '', ''),\n type: 'DateTime',\n fieldName: 'pxTimeCreated'\n }, // 2nd and 3rd args empty string until typedef marked correctly\n {\n label: thePConn.getLocalizedValue('Description', '', ''),\n type: 'TextInput',\n fieldName: 'pyMessageKey'\n }, // 2nd and 3rd args empty string until typedef marked correctly\n {\n label: thePConn.getLocalizedValue('Performed by', '', ''),\n type: 'TextInput',\n fieldName: 'pyPerformer'\n } // 2nd and 3rd args empty string until typedef marked correctly\n ];\n\n const rowData: any = useRef([]);\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n const [waitingForData, setWaitingForData] = useState<boolean>(true);\n\n const caseID = thePConn.getValue(PCore.getConstants().CASE_INFO.CASE_INFO_ID, ''); // 2nd arg empty string until typedef marked correctly\n const dataViewName = 'D_pyWorkHistory';\n const context = thePConn.getContextName();\n\n function computeRowData(rows: object[]): void {\n const theRowData: object[] = [];\n\n rows.forEach((row: any, rowIndex: number) => {\n // Now, for each property in the index of row properties (displayedColumns), add an object\n // to a new array of values\n const rowDisplayValues: any = [];\n\n displayedColumns.forEach((column: any, rowValIndex) => {\n const theType = column.type;\n const theFieldName = column.fieldName;\n const theValue =\n theType === 'Date' || theType === 'DateTime' ? Utils.generateDateTime(row[theFieldName], 'DateTime-Short') : row[theFieldName];\n rowDisplayValues[rowValIndex] = theValue;\n });\n\n theRowData[rowIndex] = rowDisplayValues;\n });\n\n if (!isDeepEqual(theRowData, rowData.current)) {\n // Only update rowData.current when it actually changes (to prevent infinite loop)\n rowData.current = theRowData;\n }\n }\n\n // Get the case history data when component mounted/initialized\n useEffect(() => {\n let bCallSetWaitingForData = true;\n\n const historyData = PCore.getDataApiUtils().getData(\n dataViewName,\n { dataViewParameters: [{ CaseInstanceKey: caseID }] } as any,\n context\n ) as Promise<any>;\n\n historyData.then((historyJSON: any) => {\n const tableDataResults = historyJSON.data.data;\n\n // compute the rowData using the tableDataResults\n computeRowData(tableDataResults);\n\n // At this point, if we have data ready to render and haven't been asked\n // to NOT call setWaitingForData, we can stop progress indicator\n if (bCallSetWaitingForData) {\n setWaitingForData(false);\n }\n });\n\n return () => {\n // Inspired by https://juliangaramendy.dev/blog/use-promise-subscription\n // The useEffect closure lets us have access to the bCallSetWaitingForData\n // variable inside the useEffect and inside the \"then\" clause of the\n // historyData promise\n // So, if this cleanup code gets run before the promise .then is called,\n // we can avoid calling the useState setter which would otherwise show a warning\n bCallSetWaitingForData = false;\n };\n }, []);\n\n function getTableHeader() {\n const theRowKey = 'CaseHistory.TableHeader';\n\n const theHeaderCells: any[] = displayedColumns.map((headerCol, index) => {\n const theCellKey = `${theRowKey}.${index}`;\n return <StyledTableCell key={theCellKey}>{headerCol.label}</StyledTableCell>;\n });\n\n return <TableRow key={theRowKey}>{theHeaderCells}</TableRow>;\n }\n\n function getTableData() {\n const theDataRows: any[] = [];\n\n // Note: using rowData.current since we're using useRef as a mutatable\n // value that's only updated when it changes.\n if (rowData.current.length > 0) {\n rowData.current.forEach((dataRow: object[], index) => {\n // using dataRow[0]-dataRow[1] as the array key since it's a unique value\n const theKey = `CaseHistory-${index}`;\n theDataRows.push(\n <TableRow key={theKey}>\n <StyledTableCell>{dataRow[0] ? dataRow[0] : ('---' as any)}</StyledTableCell>\n <StyledTableCell>{dataRow[1] ? dataRow[1] : ('---' as any)}</StyledTableCell>\n <StyledTableCell>{dataRow[2] ? dataRow[2] : ('---' as any)}</StyledTableCell>\n </TableRow>\n );\n });\n }\n\n return theDataRows;\n }\n\n return (\n <div id='CaseHistory'>\n <TableContainer>\n <Table>\n <TableHead>{getTableHeader()}</TableHead>\n <TableBody>{getTableData()}</TableBody>\n </Table>\n </TableContainer>\n </div>\n );\n}\n"]}
@@ -11,17 +11,3 @@
11
11
  justify-content: center;
12
12
  display: flex;
13
13
  }
14
-
15
- .primary-button {
16
- background-color: #3f51b5 !important;
17
- color: white !important;
18
- padding: 6px 14px !important;
19
- text-transform: unset !important;
20
- font-size: 14px;
21
- }
22
-
23
- .secondary-button {
24
- box-shadow: 0px 5px 10px 0px rgb(0 0 0 / 20%);
25
- text-transform: unset !important;
26
- padding: 6px 14px !important;
27
- }
@@ -1,4 +1,4 @@
1
- import { PConnProps } from '../../../../types/PConnProps';
1
+ import type { PConnProps } from '../../../../types/PConnProps';
2
2
  import './ActionButtonsForFileUtil.css';
3
3
  interface ActionButtonsForFileUtilProps extends PConnProps {
4
4
  arMainButtons: any[];
@@ -1 +1 @@
1
- {"version":3,"file":"ActionButtonsForFileUtil.d.ts","sourceRoot":"","sources":["../../../../../src/components/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAC1D,OAAO,gCAAgC,CAAC;AAExC,UAAU,6BAA8B,SAAQ,UAAU;IAExD,aAAa,EAAE,GAAG,EAAE,CAAC;IACrB,kBAAkB,EAAE,GAAG,EAAE,CAAC;IAC1B,aAAa,EAAE,GAAG,CAAC;IACnB,eAAe,EAAE,GAAG,CAAC;CACtB;AAED,MAAM,CAAC,OAAO,UAAU,wBAAwB,CAAC,KAAK,EAAE,6BAA6B,2CAmBpF"}
1
+ {"version":3,"file":"ActionButtonsForFileUtil.d.ts","sourceRoot":"","sources":["../../../../../src/components/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAC/D,OAAO,gCAAgC,CAAC;AAExC,UAAU,6BAA8B,SAAQ,UAAU;IAExD,aAAa,EAAE,GAAG,EAAE,CAAC;IACrB,kBAAkB,EAAE,GAAG,EAAE,CAAC;IAC1B,aAAa,EAAE,GAAG,CAAC;IACnB,eAAe,EAAE,GAAG,CAAC;CACtB;AAED,MAAM,CAAC,OAAO,UAAU,wBAAwB,CAAC,KAAK,EAAE,6BAA6B,2CAmBpF"}
@@ -2,6 +2,6 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { Button } from '@mui/material';
3
3
  import './ActionButtonsForFileUtil.css';
4
4
  export default function ActionButtonsForFileUtil(props) {
5
- return (_jsxs("div", { className: 'psdk-actions', children: [_jsx("div", { className: 'psdk-action-buttons', children: props.arSecondaryButtons.map(file => (_jsx(Button, { className: 'secondary-button', onClick: props.secondaryAction, children: file.name }, file.actionID))) }), _jsx("div", { className: 'psdk-action-buttons', children: props.arMainButtons.map(file => (_jsx(Button, { className: 'primary-button', onClick: props.primaryAction, children: file.name }, file.actionID))) })] }));
5
+ return (_jsxs("div", { className: 'psdk-actions', children: [_jsx("div", { className: 'psdk-action-buttons', children: props.arSecondaryButtons.map(file => (_jsx(Button, { className: 'secondary-button', color: 'secondary', variant: 'contained', onClick: props.secondaryAction, children: file.name }, file.actionID))) }), _jsx("div", { className: 'psdk-action-buttons', children: props.arMainButtons.map(file => (_jsx(Button, { className: 'primary-button', color: 'primary', variant: 'contained', onClick: props.primaryAction, children: file.name }, file.actionID))) })] }));
6
6
  }
7
7
  //# sourceMappingURL=ActionButtonsForFileUtil.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ActionButtonsForFileUtil.js","sourceRoot":"","sources":["../../../../../src/components/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AAEvC,OAAO,gCAAgC,CAAC;AAUxC,MAAM,CAAC,OAAO,UAAU,wBAAwB,CAAC,KAAoC;IACnF,OAAO,CACL,eAAK,SAAS,EAAC,cAAc,aAC3B,cAAK,SAAS,EAAC,qBAAqB,YACjC,KAAK,CAAC,kBAAkB,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,CAAC,CACpC,KAAC,MAAM,IAAC,SAAS,EAAC,kBAAkB,EAAqB,OAAO,EAAE,KAAK,CAAC,eAAe,YACpF,IAAI,CAAC,IAAI,IAD8B,IAAI,CAAC,QAAQ,CAE9C,CACV,CAAC,GACE,EACN,cAAK,SAAS,EAAC,qBAAqB,YACjC,KAAK,CAAC,aAAa,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,CAAC,CAC/B,KAAC,MAAM,IAAC,SAAS,EAAC,gBAAgB,EAAqB,OAAO,EAAE,KAAK,CAAC,aAAa,YAChF,IAAI,CAAC,IAAI,IAD4B,IAAI,CAAC,QAAQ,CAE5C,CACV,CAAC,GACE,IACF,CACP,CAAC;AACJ,CAAC","sourcesContent":["import { Button } from '@mui/material';\nimport { PConnProps } from '../../../../types/PConnProps';\nimport './ActionButtonsForFileUtil.css';\n\ninterface ActionButtonsForFileUtilProps extends PConnProps {\n // If any, enter additional props that only exist on this component\n arMainButtons: any[];\n arSecondaryButtons: any[];\n primaryAction: any;\n secondaryAction: any;\n}\n\nexport default function ActionButtonsForFileUtil(props: ActionButtonsForFileUtilProps) {\n return (\n <div className='psdk-actions'>\n <div className='psdk-action-buttons'>\n {props.arSecondaryButtons.map(file => (\n <Button className='secondary-button' key={file.actionID} onClick={props.secondaryAction}>\n {file.name}\n </Button>\n ))}\n </div>\n <div className='psdk-action-buttons'>\n {props.arMainButtons.map(file => (\n <Button className='primary-button' key={file.actionID} onClick={props.primaryAction}>\n {file.name}\n </Button>\n ))}\n </div>\n </div>\n );\n}\n"]}
1
+ {"version":3,"file":"ActionButtonsForFileUtil.js","sourceRoot":"","sources":["../../../../../src/components/widget/FileUtility/ActionButtonsForFileUtil/ActionButtonsForFileUtil.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AAEvC,OAAO,gCAAgC,CAAC;AAUxC,MAAM,CAAC,OAAO,UAAU,wBAAwB,CAAC,KAAoC;IACnF,OAAO,CACL,eAAK,SAAS,EAAC,cAAc,aAC3B,cAAK,SAAS,EAAC,qBAAqB,YACjC,KAAK,CAAC,kBAAkB,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,CAAC,CACpC,KAAC,MAAM,IAAC,SAAS,EAAC,kBAAkB,EAAC,KAAK,EAAC,WAAW,EAAC,OAAO,EAAC,WAAW,EAAqB,OAAO,EAAE,KAAK,CAAC,eAAe,YAC1H,IAAI,CAAC,IAAI,IADoE,IAAI,CAAC,QAAQ,CAEpF,CACV,CAAC,GACE,EACN,cAAK,SAAS,EAAC,qBAAqB,YACjC,KAAK,CAAC,aAAa,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,CAAC,CAC/B,KAAC,MAAM,IAAC,SAAS,EAAC,gBAAgB,EAAC,KAAK,EAAC,SAAS,EAAC,OAAO,EAAC,WAAW,EAAqB,OAAO,EAAE,KAAK,CAAC,aAAa,YACpH,IAAI,CAAC,IAAI,IADgE,IAAI,CAAC,QAAQ,CAEhF,CACV,CAAC,GACE,IACF,CACP,CAAC;AACJ,CAAC","sourcesContent":["import { Button } from '@mui/material';\nimport type { PConnProps } from '../../../../types/PConnProps';\nimport './ActionButtonsForFileUtil.css';\n\ninterface ActionButtonsForFileUtilProps extends PConnProps {\n // If any, enter additional props that only exist on this component\n arMainButtons: any[];\n arSecondaryButtons: any[];\n primaryAction: any;\n secondaryAction: any;\n}\n\nexport default function ActionButtonsForFileUtil(props: ActionButtonsForFileUtilProps) {\n return (\n <div className='psdk-actions'>\n <div className='psdk-action-buttons'>\n {props.arSecondaryButtons.map(file => (\n <Button className='secondary-button' color='secondary' variant='contained' key={file.actionID} onClick={props.secondaryAction}>\n {file.name}\n </Button>\n ))}\n </div>\n <div className='psdk-action-buttons'>\n {props.arMainButtons.map(file => (\n <Button className='primary-button' color='primary' variant='contained' key={file.actionID} onClick={props.primaryAction}>\n {file.name}\n </Button>\n ))}\n </div>\n </div>\n );\n}\n"]}
@@ -2,7 +2,7 @@
2
2
  width: 100%;
3
3
  padding: 0.625rem 0rem;
4
4
  text-align: left;
5
- background-color: white;
5
+ /* background-color: var(--utility-background-color); */
6
6
  border-radius: 0.6125rem;
7
7
  margin: 0.3125rem 0rem;
8
8
  position: relative;
@@ -16,6 +16,7 @@
16
16
  .psdk-file-utility-card-svg-icon {
17
17
  width: 1.4rem;
18
18
  display: inline-block;
19
+ filter: var(--svg-color);
19
20
  }
20
21
 
21
22
  .header-text {
@@ -25,7 +26,7 @@
25
26
  }
26
27
 
27
28
  .psdk-utility-count {
28
- background: #65b5f5;
29
+ background: var(--utility-count-background-color);
29
30
  border-radius: calc(1.125 * 0.5rem);
30
31
  font-size: 0.75rem;
31
32
  font-weight: bold;
@@ -40,7 +41,7 @@
40
41
  align-items: center;
41
42
  height: 100%;
42
43
  width: 100%;
43
- background-color: rgba(100, 100, 100, 0.4);
44
+ background-color: var(--modal-background-color);
44
45
  position: fixed;
45
46
  z-index: 999;
46
47
  top: 0px;
@@ -51,11 +52,11 @@
51
52
  display: table;
52
53
  margin: auto;
53
54
  min-width: 650px;
54
- background-color: white;
55
- border: 1px solid black;
55
+ background-color: var(--modal-top-color);
56
+ border: 1px solid var(--modal-border-color);
56
57
  border-radius: 10px;
57
58
  padding: 20px;
58
- box-shadow: 0 0 10px 3px #777;
59
+ box-shadow: 0 0 10px 3px var(--modal-box-shadow-color);
59
60
  }
60
61
 
61
62
  .psdk-modal-file-selector {
@@ -1,6 +1,7 @@
1
1
  import './FileUtility.css';
2
- import { PConnProps } from '../../../../types/PConnProps';
2
+ import type { PConnProps } from '../../../../types/PConnProps';
3
3
  interface FileUtilityProps extends PConnProps {
4
+ caseId?: string;
4
5
  }
5
6
  export default function FileUtility(props: FileUtilityProps): import("react/jsx-runtime").JSX.Element;
6
7
  export {};
@@ -1 +1 @@
1
- {"version":3,"file":"FileUtility.d.ts","sourceRoot":"","sources":["../../../../../src/components/widget/FileUtility/FileUtility/FileUtility.tsx"],"names":[],"mappings":"AAQA,OAAO,mBAAmB,CAAC;AAM3B,OAAO,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAE1D,UAAU,gBAAiB,SAAQ,UAAU;CAE5C;AAED,MAAM,CAAC,OAAO,UAAU,WAAW,CAAC,KAAK,EAAE,gBAAgB,2CAinB1D"}
1
+ {"version":3,"file":"FileUtility.d.ts","sourceRoot":"","sources":["../../../../../src/components/widget/FileUtility/FileUtility/FileUtility.tsx"],"names":[],"mappings":"AAQA,OAAO,mBAAmB,CAAC;AAO3B,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAE/D,UAAU,gBAAiB,SAAQ,UAAU;IAE3C,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,CAAC,OAAO,UAAU,WAAW,CAAC,KAAK,EAAE,gBAAgB,2CAsnB1D"}
@@ -6,16 +6,18 @@ import download from 'downloadjs';
6
6
  // import SummaryList from '../../SummaryList';
7
7
  // import ActionButtonsForFileUtil from '../ActionButtonsForFileUtil';
8
8
  import './FileUtility.css';
9
- import { IconButton, Menu, MenuItem, Button, CircularProgress } from '@mui/material';
9
+ import { IconButton, Menu, MenuItem, Button, CircularProgress, Card, debounce } from '@mui/material';
10
10
  import MoreVertIcon from '@mui/icons-material/MoreVert';
11
- import { validateMaxSize } from '../../../helpers/attachmentHelpers';
11
+ import { validateMaxSize } from '../../../helpers/attachmentShared';
12
+ import { getResolvedConstantValue } from '../../../helpers/object-utils';
12
13
  import { getComponentFromMap } from '../../../../bridge/helpers/sdk_component_map';
13
14
  export default function FileUtility(props) {
14
15
  // Get emitted components from map (so we can get any override that may exist)
15
16
  const SummaryList = getComponentFromMap('SummaryList');
16
17
  const ActionButtonsForFileUtil = getComponentFromMap('ActionButtonsForFileUtil');
17
- const { getPConnect } = props;
18
+ const { getPConnect, caseId } = props;
18
19
  const thePConn = getPConnect();
20
+ const caseID = caseId ?? getResolvedConstantValue(thePConn, PCore.getConstants().CASE_INFO.CASE_INFO_ID);
19
21
  const required = true;
20
22
  const listTemp = {
21
23
  data: [],
@@ -36,7 +38,7 @@ export default function FileUtility(props) {
36
38
  jsAction: 'attachFiles',
37
39
  name: thePConn.getLocalizedValue('Attach files', '', '')
38
40
  }
39
- ],
41
+ ], // 2nd and 3rd args empty string until typedef marked correctly
40
42
  fileSecondaryButtons: [
41
43
  {
42
44
  actionID: 'cancel',
@@ -56,7 +58,7 @@ export default function FileUtility(props) {
56
58
  jsAction: 'attachLinks',
57
59
  name: thePConn.getLocalizedValue('Attach links', '', '')
58
60
  }
59
- ],
61
+ ], // 2nd and 3rd args empty string until typedef marked correctly
60
62
  linkSecondaryButtons: [
61
63
  {
62
64
  actionID: 'cancel',
@@ -91,7 +93,7 @@ export default function FileUtility(props) {
91
93
  actions = [
92
94
  {
93
95
  id: `Cancel-${att.ID}`,
94
- text: thePConn.getLocalizedValue('Cancel', '', ''),
96
+ text: thePConn.getLocalizedValue('Cancel', '', ''), // 2nd and 3rd args empty string until typedef marked correctly
95
97
  icon: 'times',
96
98
  onClick: cancelFile
97
99
  }
@@ -105,7 +107,7 @@ export default function FileUtility(props) {
105
107
  'download',
106
108
  {
107
109
  id: `download-${ID}`,
108
- text: isFile ? thePConn.getLocalizedValue('Download', '', '') : thePConn.getLocalizedValue('Open', '', ''),
110
+ text: isFile ? thePConn.getLocalizedValue('Download', '', '') : thePConn.getLocalizedValue('Open', '', ''), // 2nd and 3rd args empty string until typedef marked correctly
109
111
  icon: isFile ? 'download' : 'open',
110
112
  onClick: downloadFile
111
113
  }
@@ -114,7 +116,7 @@ export default function FileUtility(props) {
114
116
  'delete',
115
117
  {
116
118
  id: `Delete-${ID}`,
117
- text: thePConn.getLocalizedValue('Delete', '', ''),
119
+ text: thePConn.getLocalizedValue('Delete', '', ''), // 2nd and 3rd args empty string until typedef marked correctly
118
120
  icon: 'trash',
119
121
  onClick: deleteFile
120
122
  }
@@ -131,7 +133,7 @@ export default function FileUtility(props) {
131
133
  actions = [
132
134
  {
133
135
  id: `Remove-${att.ID}`,
134
- text: thePConn.getLocalizedValue('Remove', '', ''),
136
+ text: thePConn.getLocalizedValue('Remove', '', ''), // 2nd and 3rd args empty string until typedef marked correctly
135
137
  icon: 'trash',
136
138
  onClick: removeFile
137
139
  }
@@ -164,7 +166,7 @@ export default function FileUtility(props) {
164
166
  const { ID, name, extension, type } = att;
165
167
  const context = thePConn.getContextName();
166
168
  attachUtils
167
- // @ts-ignore - 3rd parameter "responseEncoding" is optional
169
+ // @ts-expect-error - 3rd parameter "responseEncoding" is optional
168
170
  .downloadAttachment(ID, context)
169
171
  .then((content) => {
170
172
  if (type === 'FILE') {
@@ -187,14 +189,12 @@ export default function FileUtility(props) {
187
189
  attachUtils
188
190
  .deleteAttachment(ID, context)
189
191
  .then(() => {
190
- // eslint-disable-next-line @typescript-eslint/no-use-before-define
191
192
  getAttachments();
192
193
  })
193
194
  .catch();
194
195
  }
195
196
  const getAttachments = () => {
196
197
  const attachmentUtils = PCore.getAttachmentUtils();
197
- const caseID = thePConn.getValue(PCore.getConstants().CASE_INFO.CASE_INFO_ID, ''); // 2nd arg empty string until typedef marked correctly
198
198
  if (caseID && caseID !== '') {
199
199
  const attPromise = attachmentUtils.getCaseAttachments(caseID, thePConn.getContextName());
200
200
  attPromise.then((resp) => {
@@ -226,15 +226,27 @@ export default function FileUtility(props) {
226
226
  });
227
227
  }
228
228
  };
229
+ const debouncedGetAttachments = debounce(getAttachments, 1000);
229
230
  useEffect(() => {
230
- getAttachments();
231
+ debouncedGetAttachments();
231
232
  }, []);
232
233
  useEffect(() => {
233
- PCore.getPubSubUtils().subscribe(PCore.getEvents().getCaseEvent().CASE_ATTACHMENTS_UPDATED_FROM_CASEVIEW, getAttachments, 'caseAttachmentsUpdateFromCaseview');
234
- return () => {
235
- PCore.getPubSubUtils().unsubscribe(PCore.getEvents().getCaseEvent().CASE_ATTACHMENTS_UPDATED_FROM_CASEVIEW, 'caseAttachmentsUpdateFromCaseview');
234
+ const attachSubObject = {
235
+ matcher: 'ATTACHMENTS',
236
+ criteria: {
237
+ ID: caseID
238
+ }
239
+ };
240
+ const attachSubId = PCore.getMessagingServiceManager().subscribe(attachSubObject, debouncedGetAttachments, getPConnect().getContextName());
241
+ return function cleanup() {
242
+ PCore.getMessagingServiceManager().unsubscribe(attachSubId);
236
243
  };
237
244
  }, []);
245
+ useEffect(() => {
246
+ thePConn.registerAdditionalProps({
247
+ lastRefreshTime: `@P ${PCore.getConstants().SUMMARY_OF_ATTACHMENTS_LAST_REFRESH_TIME}`
248
+ });
249
+ }, [thePConn]);
238
250
  function setNewFiles(arFiles) {
239
251
  let index = 0;
240
252
  for (const file of arFiles) {
@@ -432,6 +444,6 @@ export default function FileUtility(props) {
432
444
  .catch(() => setProgress(false));
433
445
  }
434
446
  }
435
- return (_jsxs("div", { className: 'psdk-utility', id: 'file-utility', children: [inProgress && (_jsx("div", { className: 'progress-div', children: _jsx(CircularProgress, {}) })), _jsxs("div", { className: 'psdk-header', children: [_jsx("img", { className: 'psdk-file-utility-card-svg-icon', src: headerSvgIcon$ }), _jsx("div", { className: 'header-text', children: header }), _jsx("div", { className: 'psdk-utility-count', id: 'attachments-count', children: list.count }), _jsx("div", { style: { flexGrow: 1 } }), _jsxs("div", { children: [_jsx(IconButton, { id: 'long-button', "aria-controls": open ? 'simple-menu' : undefined, "aria-expanded": open ? 'true' : undefined, "aria-haspopup": 'true', onClick: handleClick, size: 'large', children: _jsx(MoreVertIcon, {}) }), _jsxs(Menu, { id: 'simple-menu', anchorEl: anchorEl, keepMounted: true, open: Boolean(anchorEl), onClose: handleClose, children: [_jsx(MenuItem, { style: { fontSize: '14px' }, onClick: onAddFilesClick, children: thePConn.getLocalizedValue('Add files', '', '') }), ' ', _jsx(MenuItem, { style: { fontSize: '14px' }, onClick: onAddLinksClick, children: thePConn.getLocalizedValue('Add links', '', '') }), ' '] })] })] }), list.data.length > 0 && (_jsx("div", { style: { marginTop: '1rem' }, children: _jsx(SummaryList, { "arItems$": list.data }) })), list.count > 3 && (_jsx("div", { className: 'psdk-utility-view-all', children: _jsx(Button, { style: { textTransform: 'none' }, color: 'primary', onClick: () => setViewAll(true), children: "View all" }) })), fileData.showfileModal && (_jsx("div", { className: 'psdk-dialog-background', children: _jsxs("div", { className: 'psdk-modal-file-top', children: [_jsx("h3", { children: thePConn.getLocalizedValue('Add local files', '', '') }), _jsxs("div", { className: 'psdk-modal-body', children: [_jsx("div", { className: 'psdk-modal-file-selector', children: _jsxs("label", { htmlFor: 'upload-files', children: [_jsx("input", { style: { display: 'none' }, id: 'upload-files', name: 'upload-files', type: 'file', multiple: true, onChange: uploadMyFiles }), _jsx(Button, { variant: 'outlined', color: 'primary', component: 'span', children: thePConn.getLocalizedValue('Attach files', '', '') }), ' '] }) }), fileData.fileList.length > 0 && (_jsx("div", { style: { marginTop: '1rem' }, children: _jsx(SummaryList, { "menuIconOverride$": 'trash', "arItems$": fileData.fileList, "menuIconOverrideAction$": removeFileFromList }) })), fileData.fileList.length === 0 && _jsx("div", {}), _jsx(ActionButtonsForFileUtil, { arMainButtons: fileData.fileMainButtons, arSecondaryButtons: fileData.fileSecondaryButtons, primaryAction: onAttachFiles, secondaryAction: closeFilePopup })] })] }) })), linkData.showLinkModal && (_jsx("div", { className: 'psdk-dialog-background', children: _jsxs("div", { className: 'psdk-modal-file-top', children: [_jsx("h3", { children: thePConn.getLocalizedValue('Add links', '', '') }), " ", _jsxs("div", { className: 'psdk-modal-body', children: [_jsxs("div", { className: 'psdk-modal-links-row', children: [_jsxs("div", { className: 'psdk-links-two-column', children: [_jsx("div", { className: 'psdk-modal-link-data', children: _jsx(TextField, { fullWidth: true, variant: 'outlined', label: 'Link title', size: 'small', required: required, value: link.title, onChange: fieldlinkOnChange }) }), _jsx("div", { className: 'psdk-modal-link-data', children: _jsx(TextField, { fullWidth: true, variant: 'outlined', label: 'URL', size: 'small', required: required, value: link.url, onChange: fieldurlOnChange }) })] }), _jsxs("div", { className: 'psdk-modal-link-add', children: [_jsx(Button, { className: 'psdk-add-link-action', color: 'primary', variant: 'contained', component: 'span', onClick: addLink, disabled: link.disable, children: thePConn.getLocalizedValue('Add link', '', '') }), ' '] })] }), linkData.linksList.length > 0 && (_jsx("div", { style: { marginTop: '1rem' }, children: _jsx(SummaryList, { "menuIconOverride$": 'trash', "arItems$": linkData.linksList, "menuIconOverrideAction$": removeLinksFromList }) })), _jsx(ActionButtonsForFileUtil, { arMainButtons: linkData.linkMainButtons, arSecondaryButtons: linkData.linkSecondaryButtons, primaryAction: onAttachLinks, secondaryAction: closeAddLinksPopup })] })] }) })), showViewAllModal && (_jsx("div", { className: 'psdk-dialog-background', children: _jsxs("div", { className: 'psdk-modal-file-top', children: [_jsxs("div", { className: 'psdk-view-all-header', children: [_jsx("h3", { children: thePConn.getLocalizedValue('Attachments', '', '') }), " ", _jsx("button", { type: 'button', className: 'psdk-close-button', onClick: () => setViewAll(false), children: _jsx("img", { className: 'psdk-utility-card-actions-svg-icon', src: closeSvgIcon }) })] }), _jsx("div", { className: 'psdk-view-all-body', children: _jsx(SummaryList, { "arItems$": vaItems }) })] }) }))] }));
447
+ return (_jsxs(Card, { className: 'psdk-utility', id: 'file-utility', children: [inProgress && (_jsx("div", { className: 'progress-div', children: _jsx(CircularProgress, {}) })), _jsxs("div", { className: 'psdk-header', children: [_jsx("img", { className: 'psdk-file-utility-card-svg-icon', src: headerSvgIcon$ }), _jsx("div", { className: 'header-text', children: header }), _jsx("div", { className: 'psdk-utility-count', id: 'attachments-count', children: list.count }), _jsx("div", { style: { flexGrow: 1 } }), _jsxs("div", { children: [_jsx(IconButton, { id: 'long-button', "aria-controls": open ? 'simple-menu' : undefined, "aria-expanded": open ? 'true' : undefined, "aria-haspopup": 'true', onClick: handleClick, size: 'large', children: _jsx(MoreVertIcon, {}) }), _jsxs(Menu, { id: 'simple-menu', anchorEl: anchorEl, keepMounted: true, open: Boolean(anchorEl), onClose: handleClose, children: [_jsx(MenuItem, { style: { fontSize: '14px' }, onClick: onAddFilesClick, children: thePConn.getLocalizedValue('Add files', '', '') }), ' ', _jsx(MenuItem, { style: { fontSize: '14px' }, onClick: onAddLinksClick, children: thePConn.getLocalizedValue('Add links', '', '') }), ' '] })] })] }), list.data.length > 0 && (_jsx("div", { style: { marginTop: '1rem' }, children: _jsx(SummaryList, { "arItems$": list.data }) })), list.count > 3 && (_jsx("div", { className: 'psdk-utility-view-all', children: _jsx(Button, { style: { textTransform: 'none' }, color: 'primary', onClick: () => setViewAll(true), children: "View all" }) })), fileData.showfileModal && (_jsx("div", { className: 'psdk-dialog-background', children: _jsxs("div", { className: 'psdk-modal-file-top', children: [_jsx("h3", { children: thePConn.getLocalizedValue('Add local files', '', '') }), _jsxs("div", { className: 'psdk-modal-body', children: [_jsx("div", { className: 'psdk-modal-file-selector', children: _jsxs("label", { htmlFor: 'upload-files', children: [_jsx("input", { style: { display: 'none' }, id: 'upload-files', name: 'upload-files', type: 'file', multiple: true, onChange: uploadMyFiles }), _jsx(Button, { variant: 'outlined', color: 'primary', component: 'span', children: thePConn.getLocalizedValue('Attach files', '', '') }), ' '] }) }), fileData.fileList.length > 0 && (_jsx("div", { style: { marginTop: '1rem' }, children: _jsx(SummaryList, { "menuIconOverride$": 'trash', "arItems$": fileData.fileList, "menuIconOverrideAction$": removeFileFromList }) })), fileData.fileList.length === 0 && _jsx("div", {}), _jsx(ActionButtonsForFileUtil, { arMainButtons: fileData.fileMainButtons, arSecondaryButtons: fileData.fileSecondaryButtons, primaryAction: onAttachFiles, secondaryAction: closeFilePopup })] })] }) })), linkData.showLinkModal && (_jsx("div", { className: 'psdk-dialog-background', children: _jsxs("div", { className: 'psdk-modal-file-top', children: [_jsx("h3", { children: thePConn.getLocalizedValue('Add links', '', '') }), " ", _jsxs("div", { className: 'psdk-modal-body', children: [_jsxs("div", { className: 'psdk-modal-links-row', children: [_jsxs("div", { className: 'psdk-links-two-column', children: [_jsx("div", { className: 'psdk-modal-link-data', children: _jsx(TextField, { fullWidth: true, variant: 'outlined', label: 'Link title', size: 'small', required: required, value: link.title, onChange: fieldlinkOnChange }) }), _jsx("div", { className: 'psdk-modal-link-data', children: _jsx(TextField, { fullWidth: true, variant: 'outlined', label: 'URL', size: 'small', required: required, value: link.url, onChange: fieldurlOnChange }) })] }), _jsxs("div", { className: 'psdk-modal-link-add', children: [_jsx(Button, { className: 'psdk-add-link-action', color: 'primary', variant: 'contained', component: 'span', onClick: addLink, disabled: link.disable, children: thePConn.getLocalizedValue('Add link', '', '') }), ' '] })] }), linkData.linksList.length > 0 && (_jsx("div", { style: { marginTop: '1rem' }, children: _jsx(SummaryList, { "menuIconOverride$": 'trash', "arItems$": linkData.linksList, "menuIconOverrideAction$": removeLinksFromList }) })), _jsx(ActionButtonsForFileUtil, { arMainButtons: linkData.linkMainButtons, arSecondaryButtons: linkData.linkSecondaryButtons, primaryAction: onAttachLinks, secondaryAction: closeAddLinksPopup })] })] }) })), showViewAllModal && (_jsx("div", { className: 'psdk-dialog-background', children: _jsxs("div", { className: 'psdk-modal-file-top', children: [_jsxs("div", { className: 'psdk-view-all-header', children: [_jsx("h3", { children: thePConn.getLocalizedValue('Attachments', '', '') }), " ", _jsx("button", { type: 'button', className: 'psdk-close-button', onClick: () => setViewAll(false), children: _jsx("img", { className: 'psdk-utility-card-actions-svg-icon', src: closeSvgIcon }) })] }), _jsx("div", { className: 'psdk-view-all-body', children: _jsx(SummaryList, { "arItems$": vaItems }) })] }) }))] }));
436
448
  }
437
449
  //# sourceMappingURL=FileUtility.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"FileUtility.js","sourceRoot":"","sources":["../../../../../src/components/widget/FileUtility/FileUtility/FileUtility.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,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I,GAClE,IACL,EACN,cAAK,SAAS,EAAC,oBAAoB,YACjC,KAAC,WAAW,gBAAW,OAAO,GAAI,GAC9B,IACF,GACF,CACP,IACG,CACP,CAAC;AACJ,CAAC","sourcesContent":["import { useEffect, useState } from 'react';\nimport TextField from '@mui/material/TextField';\n\nimport { Utils } from '../../../helpers/utils';\n\nimport download from 'downloadjs';\n// import SummaryList from '../../SummaryList';\n// import ActionButtonsForFileUtil from '../ActionButtonsForFileUtil';\nimport './FileUtility.css';\nimport { IconButton, Menu, MenuItem, Button, CircularProgress } from '@mui/material';\nimport MoreVertIcon from '@mui/icons-material/MoreVert';\n\nimport { validateMaxSize } from '../../../helpers/attachmentHelpers';\nimport { getComponentFromMap } from '../../../../bridge/helpers/sdk_component_map';\nimport { PConnProps } from '../../../../types/PConnProps';\n\ninterface FileUtilityProps extends PConnProps {\n // If any, enter additional props that only exist on this component\n}\n\nexport default function FileUtility(props: FileUtilityProps) {\n // Get emitted components from map (so we can get any override that may exist)\n const SummaryList = getComponentFromMap('SummaryList');\n const ActionButtonsForFileUtil = getComponentFromMap('ActionButtonsForFileUtil');\n\n const { getPConnect } = props;\n const thePConn = getPConnect();\n const required = true;\n const listTemp = {\n data: [],\n count: 0\n };\n const [list, setList] = useState(listTemp);\n const headerSvgIcon$ = Utils.getImageSrc('paper-clip', Utils.getSDKStaticConentUrl());\n const closeSvgIcon = Utils.getImageSrc('times', Utils.getSDKStaticConentUrl());\n const configProps: any = thePConn.resolveConfigProps(thePConn.getConfigProps());\n\n const header = configProps.label;\n const fileTemp = {\n showfileModal: false,\n fileList: [],\n attachedFiles: [],\n fileMainButtons: [\n {\n actionID: 'attach',\n jsAction: 'attachFiles',\n name: thePConn.getLocalizedValue('Attach files', '', '')\n }\n ], // 2nd and 3rd args empty string until typedef marked correctly\n fileSecondaryButtons: [\n {\n actionID: 'cancel',\n jsAction: 'cancel',\n name: thePConn.getLocalizedValue('Cancel', '', '')\n }\n ] // 2nd and 3rd args empty string until typedef marked correctly\n };\n const [fileData, setFileData] = useState(fileTemp);\n const linkTemp = {\n showLinkModal: false,\n linksList: [],\n attachedLinks: [],\n linkMainButtons: [\n {\n actionID: 'attach',\n jsAction: 'attachLinks',\n name: thePConn.getLocalizedValue('Attach links', '', '')\n }\n ], // 2nd and 3rd args empty string until typedef marked correctly\n linkSecondaryButtons: [\n {\n actionID: 'cancel',\n jsAction: 'cancel',\n name: thePConn.getLocalizedValue('Cancel', '', '')\n }\n ] // 2nd and 3rd args empty string until typedef marked correctly\n };\n const [linkData, setLinkData] = useState(linkTemp);\n const [anchorEl, setAnchorEl] = useState(null);\n const open = Boolean(anchorEl);\n const [link, setLink] = useState({ title: '', url: '', disable: true });\n const [inProgress, setProgress] = useState(false);\n const [showViewAllModal, setViewAll] = useState(false);\n const [vaItems, setFullAttachments] = useState([]);\n\n function addAttachments(attsFromResp: any[] = []) {\n attsFromResp = attsFromResp.map(respAtt => {\n const updatedAtt = {\n ...respAtt,\n meta: `${respAtt.category} . ${Utils.generateDateTime(respAtt.createTime, 'DateTime-Since')}, ${respAtt.createdBy}`\n };\n if (updatedAtt.type === 'FILE') {\n updatedAtt.nameWithExt = updatedAtt.fileName;\n }\n return updatedAtt;\n });\n return attsFromResp;\n }\n\n function getListUtilityItemProps({ att, cancelFile, downloadFile, deleteFile, removeFile }) {\n let actions;\n\n if (att.progress && att.progress !== 100) {\n actions = [\n {\n id: `Cancel-${att.ID}`,\n text: thePConn.getLocalizedValue('Cancel', '', ''), // 2nd and 3rd args empty string until typedef marked correctly\n icon: 'times',\n onClick: cancelFile\n }\n ];\n } else if (att.links) {\n const isFile = att.type === 'FILE';\n const ID = att.ID.replace(/\\s/gi, '');\n const actionsMap = new Map([\n [\n 'download',\n {\n id: `download-${ID}`,\n text: isFile ? thePConn.getLocalizedValue('Download', '', '') : thePConn.getLocalizedValue('Open', '', ''), // 2nd and 3rd args empty string until typedef marked correctly\n icon: isFile ? 'download' : 'open',\n onClick: downloadFile\n }\n ],\n [\n 'delete',\n {\n id: `Delete-${ID}`,\n text: thePConn.getLocalizedValue('Delete', '', ''), // 2nd and 3rd args empty string until typedef marked correctly\n icon: 'trash',\n onClick: deleteFile\n }\n ]\n ]);\n actions = [];\n actionsMap.forEach((action, actionKey) => {\n if (att.links[actionKey]) {\n actions.push(action);\n }\n });\n } else if (att.error) {\n actions = [\n {\n id: `Remove-${att.ID}`,\n text: thePConn.getLocalizedValue('Remove', '', ''), // 2nd and 3rd args empty string until typedef marked correctly\n icon: 'trash',\n onClick: removeFile\n }\n ];\n }\n\n return {\n id: att.ID,\n visual: {\n icon: Utils.getIconForAttachment(att),\n progress: att.progress === 100 ? undefined : att.progress\n },\n primary: {\n type: att.type,\n name: att.name,\n icon: 'open',\n click: downloadFile\n },\n secondary: {\n text: att.meta\n },\n actions\n };\n }\n\n function fileDownload(data, fileName, ext) {\n const file = ext ? `${fileName}.${ext}` : fileName;\n download(atob(data), file);\n }\n\n function downloadAttachedFile(att: any) {\n const attachUtils = PCore.getAttachmentUtils();\n const { ID, name, extension, type } = att;\n const context = thePConn.getContextName();\n\n attachUtils\n // @ts-ignore - 3rd parameter \"responseEncoding\" is optional\n .downloadAttachment(ID, context)\n .then((content: any) => {\n if (type === 'FILE') {\n fileDownload(content.data, name, extension);\n } else if (type === 'URL') {\n let { data } = content;\n if (!/^(http|https):\\/\\//.test(data)) {\n data = `//${data}`;\n }\n window.open(content.data, '_blank');\n }\n })\n .catch();\n }\n\n function deleteAttachedFile(att: any) {\n const attachUtils = PCore.getAttachmentUtils();\n const { ID } = att;\n const context = thePConn.getContextName();\n\n attachUtils\n .deleteAttachment(ID, context)\n .then(() => {\n // eslint-disable-next-line @typescript-eslint/no-use-before-define\n getAttachments();\n })\n .catch();\n }\n\n const getAttachments = () => {\n const attachmentUtils = PCore.getAttachmentUtils();\n const caseID = thePConn.getValue(PCore.getConstants().CASE_INFO.CASE_INFO_ID, ''); // 2nd arg empty string until typedef marked correctly\n\n if (caseID && caseID !== '') {\n const attPromise = attachmentUtils.getCaseAttachments(caseID, thePConn.getContextName());\n\n attPromise.then((resp: any) => {\n const arFullListAttachments = addAttachments(resp);\n const attachmentsCount = arFullListAttachments.length;\n const arItems: any = arFullListAttachments.slice(0, 3).map(att => {\n return getListUtilityItemProps({\n att,\n downloadFile: !att.progress ? () => downloadAttachedFile(att) : null,\n cancelFile: null,\n deleteFile: !att.progress ? () => deleteAttachedFile(att) : null,\n removeFile: null\n });\n });\n const viewAllarItems: any = arFullListAttachments.map(att => {\n return getListUtilityItemProps({\n att,\n downloadFile: !att.progress ? () => downloadAttachedFile(att) : null,\n cancelFile: null,\n deleteFile: !att.progress ? () => deleteAttachedFile(att) : null,\n removeFile: null\n });\n });\n setProgress(false);\n setList(current => {\n return { ...current, count: attachmentsCount, data: arItems };\n });\n setFullAttachments(viewAllarItems);\n });\n }\n };\n\n useEffect(() => {\n getAttachments();\n }, []);\n\n useEffect(() => {\n PCore.getPubSubUtils().subscribe(\n (PCore.getEvents().getCaseEvent() as any).CASE_ATTACHMENTS_UPDATED_FROM_CASEVIEW,\n getAttachments,\n 'caseAttachmentsUpdateFromCaseview'\n );\n\n return () => {\n PCore.getPubSubUtils().unsubscribe(\n (PCore.getEvents().getCaseEvent() as any).CASE_ATTACHMENTS_UPDATED_FROM_CASEVIEW,\n 'caseAttachmentsUpdateFromCaseview'\n );\n };\n }, []);\n\n function setNewFiles(arFiles) {\n let index = 0;\n for (const file of arFiles) {\n if (!validateMaxSize(file, '5')) {\n file.error = true;\n file.meta = 'File is too big. Max allowed size is 5MB.';\n }\n file.mimeType = file.type;\n file.icon = Utils.getIconFromFileType(file.type);\n file.ID = `${new Date().getTime()}I${index}`;\n index += 1;\n }\n return arFiles;\n }\n\n function getFiles(arFiles: any[]): any[] {\n return setNewFiles(arFiles);\n }\n\n function uploadMyFiles(event) {\n // alert($event.target.files[0]); // outputs the first file\n const arFiles = getFiles(event.target.files);\n // convert FileList to an array\n const myFiles: any = Array.from(arFiles);\n\n const arFileList$: any = myFiles.map((att: any) => {\n return getListUtilityItemProps({\n att,\n downloadFile: !att.progress ? () => downloadAttachedFile(att) : null,\n cancelFile: null,\n deleteFile: !att.progress ? () => deleteAttachedFile(att) : null,\n removeFile: null\n });\n });\n setFileData(current => {\n return { ...current, fileList: arFileList$, attachedFiles: myFiles };\n });\n }\n\n const handleClick = event => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(null);\n };\n\n function onAddFilesClick() {\n setFileData(current => {\n return { ...current, showfileModal: true };\n });\n setAnchorEl(null);\n }\n\n function removeFileFromList(item: any) {\n let attachedFiles: any = fileData.attachedFiles;\n let fileList: any = fileData.fileList;\n if (item !== null) {\n attachedFiles = attachedFiles.filter(ele => ele.ID !== item.id);\n fileList = fileList.filter(ele => ele.id !== item.id);\n setFileData(current => {\n return { ...current, fileList, attachedFiles };\n });\n }\n }\n\n function closeFilePopup() {\n setFileData(current => {\n return { ...current, showfileModal: false };\n });\n }\n\n function onAttachFiles() {\n const attachmentUtils = PCore.getAttachmentUtils();\n const caseID = thePConn.getValue(PCore.getConstants().CASE_INFO.CASE_INFO_ID, ''); // 2nd arg empty string until typedef marked correctly\n const onUploadProgress = () => {};\n const errorHandler = () => {};\n closeFilePopup();\n if (fileData.attachedFiles && fileData.attachedFiles.length > 0) {\n setProgress(true);\n }\n\n Promise.allSettled(\n fileData.attachedFiles.map(file => attachmentUtils.uploadAttachment(file, onUploadProgress, errorHandler, thePConn.getContextName()))\n )\n .then((fileResponses: any) => {\n const uploadedFiles: any = [];\n fileResponses.forEach(fileResponse => {\n if (fileResponse.status === 'fulfilled') {\n uploadedFiles.push(fileResponse.value);\n }\n });\n if (uploadedFiles.length > 0) {\n (attachmentUtils.linkAttachmentsToCase(caseID, uploadedFiles, 'File', thePConn.getContextName()) as Promise<any>)\n .then(() => {\n setFileData(current => {\n return { ...current, fileList: [], attachedFiles: [] };\n });\n getAttachments();\n })\n .catch();\n }\n })\n .catch();\n }\n\n function onAddLinksClick() {\n setLinkData(current => {\n return { ...current, showLinkModal: true };\n });\n setAnchorEl(null);\n }\n\n function closeAddLinksPopup() {\n setLinkData(current => {\n return { ...current, showLinkModal: false };\n });\n }\n\n const fieldlinkOnChange = event => {\n const title = event.target.value;\n setLink(current => {\n const updatedData = { ...current, title };\n updatedData.disable = !(updatedData.title && updatedData.url);\n return updatedData;\n });\n };\n\n function fieldurlOnChange(event) {\n const url = event.target.value;\n setLink(current => {\n const updatedData = { ...current, url };\n updatedData.disable = !(updatedData.title && updatedData.url);\n return updatedData;\n });\n }\n\n function addLink() {\n // copy list locally\n const localList: any = linkData.linksList.slice();\n const url = link.url;\n if (!/^(http|https):\\/\\//.test(link.url)) {\n link.url = `http://${link.url}`;\n }\n\n // list for display\n let oLink: any = {};\n oLink.icon = 'chain';\n oLink.ID = `${new Date().getTime()}`;\n oLink = getListUtilityItemProps({\n att: oLink,\n downloadFile: null,\n cancelFile: null,\n deleteFile: null,\n removeFile: null\n });\n oLink.type = 'URL';\n oLink.primary.type = oLink.type;\n oLink.visual.icon = 'chain';\n oLink.primary.name = link.title;\n oLink.primary.icon = 'open';\n oLink.secondary.text = url;\n\n localList.push(oLink);\n\n // list for actually attachments\n const attachedListTemp: any = linkData.attachedLinks.slice();\n const attachedLink: any = {};\n attachedLink.id = oLink.id;\n attachedLink.linkTitle = link.title;\n attachedLink.type = oLink.type;\n attachedLink.url = url;\n\n attachedListTemp.push(attachedLink);\n setLinkData(current => {\n return {\n ...current,\n linksList: localList,\n attachedLinks: attachedListTemp\n };\n });\n // clear values\n setLink({ title: '', url: '', disable: true });\n }\n\n function removeLinksFromList(item: any) {\n let attachedLinks: any = linkData.attachedLinks;\n let linksList: any = linkData.linksList;\n if (item !== null) {\n attachedLinks = attachedLinks.filter(ele => ele.id !== item.id);\n linksList = linksList.filter(ele => ele.id !== item.id);\n setLinkData(current => {\n return { ...current, linksList, attachedLinks };\n });\n }\n }\n\n function onAttachLinks() {\n const attachmentUtils = PCore.getAttachmentUtils();\n const caseID = thePConn.getValue(PCore.getConstants().CASE_INFO.CASE_INFO_ID, ''); // 2nd arg empty string until typedef marked correctly\n const links = linkData.attachedLinks;\n closeAddLinksPopup();\n const linksToAttach = links.map((item: any) => ({\n type: 'URL',\n category: 'URL',\n url: item.url,\n name: item.linkTitle\n }));\n\n if (linksToAttach && linksToAttach.length > 0) {\n setProgress(true);\n (attachmentUtils.linkAttachmentsToCase(caseID, linksToAttach, 'URL', thePConn.getContextName()) as Promise<any>)\n .then(() => {\n setLinkData(current => {\n return { ...current, linksList: [], attachedLinks: [] };\n });\n getAttachments();\n })\n .catch(() => setProgress(false));\n }\n }\n\n return (\n <div className='psdk-utility' id='file-utility'>\n {inProgress && (\n <div className='progress-div'>\n <CircularProgress />\n </div>\n )}\n <div className='psdk-header'>\n <img className='psdk-file-utility-card-svg-icon' src={headerSvgIcon$} />\n <div className='header-text'>{header}</div>\n <div className='psdk-utility-count' id='attachments-count'>\n {list.count}\n </div>\n <div style={{ flexGrow: 1 }} />\n <div>\n <IconButton\n id='long-button'\n aria-controls={open ? 'simple-menu' : undefined}\n aria-expanded={open ? 'true' : undefined}\n aria-haspopup='true'\n onClick={handleClick}\n size='large'\n >\n <MoreVertIcon />\n </IconButton>\n <Menu id='simple-menu' anchorEl={anchorEl} keepMounted open={Boolean(anchorEl)} onClose={handleClose}>\n <MenuItem style={{ fontSize: '14px' }} onClick={onAddFilesClick}>\n {thePConn.getLocalizedValue('Add files', '', '')}\n </MenuItem>{' '}\n {/* 2nd and 3rd args empty string until typedef marked correctly */}\n <MenuItem style={{ fontSize: '14px' }} onClick={onAddLinksClick}>\n {thePConn.getLocalizedValue('Add links', '', '')}\n </MenuItem>{' '}\n {/* 2nd and 3rd args empty string until typedef marked correctly */}\n </Menu>\n </div>\n </div>\n {list.data.length > 0 && (\n <div style={{ marginTop: '1rem' }}>\n <SummaryList arItems$={list.data} />\n </div>\n )}\n {list.count > 3 && (\n <div className='psdk-utility-view-all'>\n <Button style={{ textTransform: 'none' }} color='primary' onClick={() => setViewAll(true)}>\n View all\n </Button>\n </div>\n )}\n {fileData.showfileModal && (\n <div className='psdk-dialog-background'>\n <div className='psdk-modal-file-top'>\n <h3>{thePConn.getLocalizedValue('Add local files', '', '')}</h3>\n <div className='psdk-modal-body'>\n <div className='psdk-modal-file-selector'>\n <label htmlFor='upload-files'>\n <input style={{ display: 'none' }} id='upload-files' name='upload-files' type='file' multiple onChange={uploadMyFiles} />\n <Button variant='outlined' color='primary' component='span'>\n {thePConn.getLocalizedValue('Attach files', '', '')}\n </Button>{' '}\n {/* 2nd and 3rd args empty string until typedef marked correctly */}\n </label>\n </div>\n {fileData.fileList.length > 0 && (\n <div style={{ marginTop: '1rem' }}>\n <SummaryList menuIconOverride$='trash' arItems$={fileData.fileList} menuIconOverrideAction$={removeFileFromList} />\n </div>\n )}\n {fileData.fileList.length === 0 && <div />}\n <ActionButtonsForFileUtil\n arMainButtons={fileData.fileMainButtons}\n arSecondaryButtons={fileData.fileSecondaryButtons}\n primaryAction={onAttachFiles}\n secondaryAction={closeFilePopup}\n />\n </div>\n </div>\n </div>\n )}\n {linkData.showLinkModal && (\n <div className='psdk-dialog-background'>\n <div className='psdk-modal-file-top'>\n <h3>{thePConn.getLocalizedValue('Add links', '', '')}</h3> {/* 2nd and 3rd args empty string until typedef marked correctly */}\n <div className='psdk-modal-body'>\n <div className='psdk-modal-links-row'>\n <div className='psdk-links-two-column'>\n <div className='psdk-modal-link-data'>\n <TextField\n fullWidth\n variant='outlined'\n label='Link title'\n size='small'\n required={required}\n value={link.title}\n onChange={fieldlinkOnChange}\n />\n </div>\n <div className='psdk-modal-link-data'>\n <TextField\n fullWidth\n variant='outlined'\n label='URL'\n size='small'\n required={required}\n value={link.url}\n onChange={fieldurlOnChange}\n />\n </div>\n </div>\n <div className='psdk-modal-link-add'>\n <Button\n className='psdk-add-link-action'\n color='primary'\n variant='contained'\n component='span'\n onClick={addLink}\n disabled={link.disable}\n >\n {thePConn.getLocalizedValue('Add link', '', '')}\n </Button>{' '}\n {/* 2nd and 3rd args empty string until typedef marked correctly */}\n </div>\n </div>\n {linkData.linksList.length > 0 && (\n <div style={{ marginTop: '1rem' }}>\n <SummaryList menuIconOverride$='trash' arItems$={linkData.linksList} menuIconOverrideAction$={removeLinksFromList} />\n </div>\n )}\n <ActionButtonsForFileUtil\n arMainButtons={linkData.linkMainButtons}\n arSecondaryButtons={linkData.linkSecondaryButtons}\n primaryAction={onAttachLinks}\n secondaryAction={closeAddLinksPopup}\n />\n </div>\n </div>\n </div>\n )}\n {showViewAllModal && (\n <div className='psdk-dialog-background'>\n <div className='psdk-modal-file-top'>\n <div className='psdk-view-all-header'>\n <h3>{thePConn.getLocalizedValue('Attachments', '', '')}</h3> {/* 2nd and 3rd args empty string until typedef marked correctly */}\n {/* eslint-disable-next-line jsx-a11y/control-has-associated-label */}\n <button type='button' className='psdk-close-button' onClick={() => setViewAll(false)}>\n <img className='psdk-utility-card-actions-svg-icon' src={closeSvgIcon} />\n </button>\n </div>\n <div className='psdk-view-all-body'>\n <SummaryList arItems$={vaItems} />\n </div>\n </div>\n </div>\n )}\n </div>\n );\n}\n"]}
1
+ {"version":3,"file":"FileUtility.js","sourceRoot":"","sources":["../../../../../src/components/widget/FileUtility/FileUtility/FileUtility.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAC5C,OAAO,SAAS,MAAM,yBAAyB,CAAC;AAEhD,OAAO,EAAE,KAAK,EAAE,MAAM,wBAAwB,CAAC;AAE/C,OAAO,QAAQ,MAAM,YAAY,CAAC;AAClC,+CAA+C;AAC/C,sEAAsE;AACtE,OAAO,mBAAmB,CAAC;AAC3B,OAAO,EAAE,UAAU,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,EAAE,gBAAgB,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AACrG,OAAO,YAAY,MAAM,8BAA8B,CAAC;AAExD,OAAO,EAAE,eAA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,qBAAqB,aAClC,eAAK,SAAS,EAAC,sBAAsB,aACnC,uBAAK,QAAQ,CAAC,iBAAiB,CAAC,aAAa,EAAE,EAAE,EAAE,EAAE,CAAC,GAAM,OAC5D,iBAAQ,IAAI,EAAC,QAAQ,EAAC,SAAS,EAAC,mBAAmB,EAAC,OAAO,EAAE,GAAG,EAAE,CAAC,UAAU,CAAC,KAAK,CAAC,YAClF,cAAK,SAAS,EAAC,oCAAoC,EAAC,GAAG,EAAE,YAAY,GAAI,GAClE,IACL,EACN,cAAK,SAAS,EAAC,oBAAoB,YACjC,KAAC,WAAW,gBAAW,OAAO,GAAI,GAC9B,IACF,GACF,CACP,IACI,CACR,CAAC;AACJ,CAAC","sourcesContent":["import { useEffect, useState } from 'react';\nimport TextField from '@mui/material/TextField';\n\nimport { Utils } from '../../../helpers/utils';\n\nimport download from 'downloadjs';\n// import SummaryList from '../../SummaryList';\n// import ActionButtonsForFileUtil from '../ActionButtonsForFileUtil';\nimport './FileUtility.css';\nimport { IconButton, Menu, MenuItem, Button, CircularProgress, Card, debounce } from '@mui/material';\nimport MoreVertIcon from '@mui/icons-material/MoreVert';\n\nimport { validateMaxSize } from '../../../helpers/attachmentShared';\nimport { getResolvedConstantValue } from '../../../helpers/object-utils';\nimport { getComponentFromMap } from '../../../../bridge/helpers/sdk_component_map';\nimport type { PConnProps } from '../../../../types/PConnProps';\n\ninterface FileUtilityProps extends PConnProps {\n // If any, enter additional props that only exist on this component\n caseId?: string;\n}\n\nexport default function FileUtility(props: FileUtilityProps) {\n // Get emitted components from map (so we can get any override that may exist)\n const SummaryList = getComponentFromMap('SummaryList');\n const ActionButtonsForFileUtil = getComponentFromMap('ActionButtonsForFileUtil');\n\n const { getPConnect, caseId } = props;\n const thePConn = getPConnect();\n const caseID = caseId ?? getResolvedConstantValue(thePConn, PCore.getConstants().CASE_INFO.CASE_INFO_ID);\n const required = true;\n const listTemp = {\n data: [],\n count: 0\n };\n const [list, setList] = useState(listTemp);\n const headerSvgIcon$ = Utils.getImageSrc('paper-clip', Utils.getSDKStaticConentUrl());\n const closeSvgIcon = Utils.getImageSrc('times', Utils.getSDKStaticConentUrl());\n const configProps: any = thePConn.resolveConfigProps(thePConn.getConfigProps());\n\n const header = configProps.label;\n const fileTemp = {\n showfileModal: false,\n fileList: [],\n attachedFiles: [],\n fileMainButtons: [\n {\n actionID: 'attach',\n jsAction: 'attachFiles',\n name: thePConn.getLocalizedValue('Attach files', '', '')\n }\n ], // 2nd and 3rd args empty string until typedef marked correctly\n fileSecondaryButtons: [\n {\n actionID: 'cancel',\n jsAction: 'cancel',\n name: thePConn.getLocalizedValue('Cancel', '', '')\n }\n ] // 2nd and 3rd args empty string until typedef marked correctly\n };\n const [fileData, setFileData] = useState(fileTemp);\n const linkTemp = {\n showLinkModal: false,\n linksList: [],\n attachedLinks: [],\n linkMainButtons: [\n {\n actionID: 'attach',\n jsAction: 'attachLinks',\n name: thePConn.getLocalizedValue('Attach links', '', '')\n }\n ], // 2nd and 3rd args empty string until typedef marked correctly\n linkSecondaryButtons: [\n {\n actionID: 'cancel',\n jsAction: 'cancel',\n name: thePConn.getLocalizedValue('Cancel', '', '')\n }\n ] // 2nd and 3rd args empty string until typedef marked correctly\n };\n const [linkData, setLinkData] = useState(linkTemp);\n const [anchorEl, setAnchorEl] = useState(null);\n const open = Boolean(anchorEl);\n const [link, setLink] = useState({ title: '', url: '', disable: true });\n const [inProgress, setProgress] = useState(false);\n const [showViewAllModal, setViewAll] = useState(false);\n const [vaItems, setFullAttachments] = useState([]);\n\n function addAttachments(attsFromResp: any[] = []) {\n attsFromResp = attsFromResp.map(respAtt => {\n const updatedAtt = {\n ...respAtt,\n meta: `${respAtt.category} . ${Utils.generateDateTime(respAtt.createTime, 'DateTime-Since')}, ${respAtt.createdBy}`\n };\n if (updatedAtt.type === 'FILE') {\n updatedAtt.nameWithExt = updatedAtt.fileName;\n }\n return updatedAtt;\n });\n return attsFromResp;\n }\n\n function getListUtilityItemProps({ att, cancelFile, downloadFile, deleteFile, removeFile }) {\n let actions;\n\n if (att.progress && att.progress !== 100) {\n actions = [\n {\n id: `Cancel-${att.ID}`,\n text: thePConn.getLocalizedValue('Cancel', '', ''), // 2nd and 3rd args empty string until typedef marked correctly\n icon: 'times',\n onClick: cancelFile\n }\n ];\n } else if (att.links) {\n const isFile = att.type === 'FILE';\n const ID = att.ID.replace(/\\s/gi, '');\n const actionsMap = new Map([\n [\n 'download',\n {\n id: `download-${ID}`,\n text: isFile ? thePConn.getLocalizedValue('Download', '', '') : thePConn.getLocalizedValue('Open', '', ''), // 2nd and 3rd args empty string until typedef marked correctly\n icon: isFile ? 'download' : 'open',\n onClick: downloadFile\n }\n ],\n [\n 'delete',\n {\n id: `Delete-${ID}`,\n text: thePConn.getLocalizedValue('Delete', '', ''), // 2nd and 3rd args empty string until typedef marked correctly\n icon: 'trash',\n onClick: deleteFile\n }\n ]\n ]);\n actions = [];\n actionsMap.forEach((action, actionKey) => {\n if (att.links[actionKey]) {\n actions.push(action);\n }\n });\n } else if (att.error) {\n actions = [\n {\n id: `Remove-${att.ID}`,\n text: thePConn.getLocalizedValue('Remove', '', ''), // 2nd and 3rd args empty string until typedef marked correctly\n icon: 'trash',\n onClick: removeFile\n }\n ];\n }\n\n return {\n id: att.ID,\n visual: {\n icon: Utils.getIconForAttachment(att),\n progress: att.progress === 100 ? undefined : att.progress\n },\n primary: {\n type: att.type,\n name: att.name,\n icon: 'open',\n click: downloadFile\n },\n secondary: {\n text: att.meta\n },\n actions\n };\n }\n\n function fileDownload(data, fileName, ext) {\n const file = ext ? `${fileName}.${ext}` : fileName;\n download(atob(data), file);\n }\n\n function downloadAttachedFile(att: any) {\n const attachUtils = PCore.getAttachmentUtils();\n const { ID, name, extension, type } = att;\n const context = thePConn.getContextName();\n\n attachUtils\n // @ts-expect-error - 3rd parameter \"responseEncoding\" is optional\n .downloadAttachment(ID, context)\n .then((content: any) => {\n if (type === 'FILE') {\n fileDownload(content.data, name, extension);\n } else if (type === 'URL') {\n let { data } = content;\n if (!/^(http|https):\\/\\//.test(data)) {\n data = `//${data}`;\n }\n window.open(content.data, '_blank');\n }\n })\n .catch();\n }\n\n function deleteAttachedFile(att: any) {\n const attachUtils = PCore.getAttachmentUtils();\n const { ID } = att;\n const context = thePConn.getContextName();\n\n attachUtils\n .deleteAttachment(ID, context)\n .then(() => {\n getAttachments();\n })\n .catch();\n }\n\n const getAttachments = () => {\n const attachmentUtils = PCore.getAttachmentUtils();\n\n if (caseID && caseID !== '') {\n const attPromise = attachmentUtils.getCaseAttachments(caseID, thePConn.getContextName());\n\n attPromise.then((resp: any) => {\n const arFullListAttachments = addAttachments(resp);\n const attachmentsCount = arFullListAttachments.length;\n const arItems: any = arFullListAttachments.slice(0, 3).map(att => {\n return getListUtilityItemProps({\n att,\n downloadFile: !att.progress ? () => downloadAttachedFile(att) : null,\n cancelFile: null,\n deleteFile: !att.progress ? () => deleteAttachedFile(att) : null,\n removeFile: null\n });\n });\n const viewAllarItems: any = arFullListAttachments.map(att => {\n return getListUtilityItemProps({\n att,\n downloadFile: !att.progress ? () => downloadAttachedFile(att) : null,\n cancelFile: null,\n deleteFile: !att.progress ? () => deleteAttachedFile(att) : null,\n removeFile: null\n });\n });\n setProgress(false);\n setList(current => {\n return { ...current, count: attachmentsCount, data: arItems };\n });\n setFullAttachments(viewAllarItems);\n });\n }\n };\n\n const debouncedGetAttachments = debounce(getAttachments, 1000);\n\n useEffect(() => {\n debouncedGetAttachments();\n }, []);\n\n useEffect(() => {\n const attachSubObject = {\n matcher: 'ATTACHMENTS',\n criteria: {\n ID: caseID\n }\n };\n const attachSubId = PCore.getMessagingServiceManager().subscribe(attachSubObject, debouncedGetAttachments, getPConnect().getContextName());\n\n return function cleanup() {\n PCore.getMessagingServiceManager().unsubscribe(attachSubId);\n };\n }, []);\n\n useEffect(() => {\n thePConn.registerAdditionalProps({\n lastRefreshTime: `@P ${PCore.getConstants().SUMMARY_OF_ATTACHMENTS_LAST_REFRESH_TIME}`\n });\n }, [thePConn]);\n\n function setNewFiles(arFiles) {\n let index = 0;\n for (const file of arFiles) {\n if (!validateMaxSize(file, '5')) {\n file.error = true;\n file.meta = 'File is too big. Max allowed size is 5MB.';\n }\n file.mimeType = file.type;\n file.icon = Utils.getIconFromFileType(file.type);\n file.ID = `${new Date().getTime()}I${index}`;\n index += 1;\n }\n return arFiles;\n }\n\n function getFiles(arFiles: any[]): any[] {\n return setNewFiles(arFiles);\n }\n\n function uploadMyFiles(event) {\n // alert($event.target.files[0]); // outputs the first file\n const arFiles = getFiles(event.target.files);\n // convert FileList to an array\n const myFiles: any = Array.from(arFiles);\n\n const arFileList$: any = myFiles.map((att: any) => {\n return getListUtilityItemProps({\n att,\n downloadFile: !att.progress ? () => downloadAttachedFile(att) : null,\n cancelFile: null,\n deleteFile: !att.progress ? () => deleteAttachedFile(att) : null,\n removeFile: null\n });\n });\n setFileData(current => {\n return { ...current, fileList: arFileList$, attachedFiles: myFiles };\n });\n }\n\n const handleClick = event => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(null);\n };\n\n function onAddFilesClick() {\n setFileData(current => {\n return { ...current, showfileModal: true };\n });\n setAnchorEl(null);\n }\n\n function removeFileFromList(item: any) {\n let attachedFiles: any = fileData.attachedFiles;\n let fileList: any = fileData.fileList;\n if (item !== null) {\n attachedFiles = attachedFiles.filter(ele => ele.ID !== item.id);\n fileList = fileList.filter(ele => ele.id !== item.id);\n setFileData(current => {\n return { ...current, fileList, attachedFiles };\n });\n }\n }\n\n function closeFilePopup() {\n setFileData(current => {\n return { ...current, showfileModal: false };\n });\n }\n\n function onAttachFiles() {\n const attachmentUtils = PCore.getAttachmentUtils();\n const caseID = thePConn.getValue(PCore.getConstants().CASE_INFO.CASE_INFO_ID, ''); // 2nd arg empty string until typedef marked correctly\n const onUploadProgress = () => {};\n const errorHandler = () => {};\n closeFilePopup();\n if (fileData.attachedFiles && fileData.attachedFiles.length > 0) {\n setProgress(true);\n }\n\n Promise.allSettled(\n fileData.attachedFiles.map(file => attachmentUtils.uploadAttachment(file, onUploadProgress, errorHandler, thePConn.getContextName()))\n )\n .then((fileResponses: any) => {\n const uploadedFiles: any = [];\n fileResponses.forEach(fileResponse => {\n if (fileResponse.status === 'fulfilled') {\n uploadedFiles.push(fileResponse.value);\n }\n });\n if (uploadedFiles.length > 0) {\n (attachmentUtils.linkAttachmentsToCase(caseID, uploadedFiles, 'File', thePConn.getContextName()) as Promise<any>)\n .then(() => {\n setFileData(current => {\n return { ...current, fileList: [], attachedFiles: [] };\n });\n getAttachments();\n })\n .catch();\n }\n })\n .catch();\n }\n\n function onAddLinksClick() {\n setLinkData(current => {\n return { ...current, showLinkModal: true };\n });\n setAnchorEl(null);\n }\n\n function closeAddLinksPopup() {\n setLinkData(current => {\n return { ...current, showLinkModal: false };\n });\n }\n\n const fieldlinkOnChange = event => {\n const title = event.target.value;\n setLink(current => {\n const updatedData = { ...current, title };\n updatedData.disable = !(updatedData.title && updatedData.url);\n return updatedData;\n });\n };\n\n function fieldurlOnChange(event) {\n const url = event.target.value;\n setLink(current => {\n const updatedData = { ...current, url };\n updatedData.disable = !(updatedData.title && updatedData.url);\n return updatedData;\n });\n }\n\n function addLink() {\n // copy list locally\n const localList: any = linkData.linksList.slice();\n const url = link.url;\n if (!/^(http|https):\\/\\//.test(link.url)) {\n link.url = `http://${link.url}`;\n }\n\n // list for display\n let oLink: any = {};\n oLink.icon = 'chain';\n oLink.ID = `${new Date().getTime()}`;\n oLink = getListUtilityItemProps({\n att: oLink,\n downloadFile: null,\n cancelFile: null,\n deleteFile: null,\n removeFile: null\n });\n oLink.type = 'URL';\n oLink.primary.type = oLink.type;\n oLink.visual.icon = 'chain';\n oLink.primary.name = link.title;\n oLink.primary.icon = 'open';\n oLink.secondary.text = url;\n\n localList.push(oLink);\n\n // list for actually attachments\n const attachedListTemp: any = linkData.attachedLinks.slice();\n const attachedLink: any = {};\n attachedLink.id = oLink.id;\n attachedLink.linkTitle = link.title;\n attachedLink.type = oLink.type;\n attachedLink.url = url;\n\n attachedListTemp.push(attachedLink);\n setLinkData(current => {\n return {\n ...current,\n linksList: localList,\n attachedLinks: attachedListTemp\n };\n });\n // clear values\n setLink({ title: '', url: '', disable: true });\n }\n\n function removeLinksFromList(item: any) {\n let attachedLinks: any = linkData.attachedLinks;\n let linksList: any = linkData.linksList;\n if (item !== null) {\n attachedLinks = attachedLinks.filter(ele => ele.id !== item.id);\n linksList = linksList.filter(ele => ele.id !== item.id);\n setLinkData(current => {\n return { ...current, linksList, attachedLinks };\n });\n }\n }\n\n function onAttachLinks() {\n const attachmentUtils = PCore.getAttachmentUtils();\n const caseID = thePConn.getValue(PCore.getConstants().CASE_INFO.CASE_INFO_ID, ''); // 2nd arg empty string until typedef marked correctly\n const links = linkData.attachedLinks;\n closeAddLinksPopup();\n const linksToAttach = links.map((item: any) => ({\n type: 'URL',\n category: 'URL',\n url: item.url,\n name: item.linkTitle\n }));\n\n if (linksToAttach && linksToAttach.length > 0) {\n setProgress(true);\n (attachmentUtils.linkAttachmentsToCase(caseID, linksToAttach, 'URL', thePConn.getContextName()) as Promise<any>)\n .then(() => {\n setLinkData(current => {\n return { ...current, linksList: [], attachedLinks: [] };\n });\n getAttachments();\n })\n .catch(() => setProgress(false));\n }\n }\n\n return (\n <Card className='psdk-utility' id='file-utility'>\n {inProgress && (\n <div className='progress-div'>\n <CircularProgress />\n </div>\n )}\n <div className='psdk-header'>\n <img className='psdk-file-utility-card-svg-icon' src={headerSvgIcon$} />\n <div className='header-text'>{header}</div>\n <div className='psdk-utility-count' id='attachments-count'>\n {list.count}\n </div>\n <div style={{ flexGrow: 1 }} />\n <div>\n <IconButton\n id='long-button'\n aria-controls={open ? 'simple-menu' : undefined}\n aria-expanded={open ? 'true' : undefined}\n aria-haspopup='true'\n onClick={handleClick}\n size='large'\n >\n <MoreVertIcon />\n </IconButton>\n <Menu id='simple-menu' anchorEl={anchorEl} keepMounted open={Boolean(anchorEl)} onClose={handleClose}>\n <MenuItem style={{ fontSize: '14px' }} onClick={onAddFilesClick}>\n {thePConn.getLocalizedValue('Add files', '', '')}\n </MenuItem>{' '}\n {/* 2nd and 3rd args empty string until typedef marked correctly */}\n <MenuItem style={{ fontSize: '14px' }} onClick={onAddLinksClick}>\n {thePConn.getLocalizedValue('Add links', '', '')}\n </MenuItem>{' '}\n {/* 2nd and 3rd args empty string until typedef marked correctly */}\n </Menu>\n </div>\n </div>\n {list.data.length > 0 && (\n <div style={{ marginTop: '1rem' }}>\n <SummaryList arItems$={list.data} />\n </div>\n )}\n {list.count > 3 && (\n <div className='psdk-utility-view-all'>\n <Button style={{ textTransform: 'none' }} color='primary' onClick={() => setViewAll(true)}>\n View all\n </Button>\n </div>\n )}\n {fileData.showfileModal && (\n <div className='psdk-dialog-background'>\n <div className='psdk-modal-file-top'>\n <h3>{thePConn.getLocalizedValue('Add local files', '', '')}</h3>\n <div className='psdk-modal-body'>\n <div className='psdk-modal-file-selector'>\n <label htmlFor='upload-files'>\n <input style={{ display: 'none' }} id='upload-files' name='upload-files' type='file' multiple onChange={uploadMyFiles} />\n <Button variant='outlined' color='primary' component='span'>\n {thePConn.getLocalizedValue('Attach files', '', '')}\n </Button>{' '}\n {/* 2nd and 3rd args empty string until typedef marked correctly */}\n </label>\n </div>\n {fileData.fileList.length > 0 && (\n <div style={{ marginTop: '1rem' }}>\n <SummaryList menuIconOverride$='trash' arItems$={fileData.fileList} menuIconOverrideAction$={removeFileFromList} />\n </div>\n )}\n {fileData.fileList.length === 0 && <div />}\n <ActionButtonsForFileUtil\n arMainButtons={fileData.fileMainButtons}\n arSecondaryButtons={fileData.fileSecondaryButtons}\n primaryAction={onAttachFiles}\n secondaryAction={closeFilePopup}\n />\n </div>\n </div>\n </div>\n )}\n {linkData.showLinkModal && (\n <div className='psdk-dialog-background'>\n <div className='psdk-modal-file-top'>\n <h3>{thePConn.getLocalizedValue('Add links', '', '')}</h3> {/* 2nd and 3rd args empty string until typedef marked correctly */}\n <div className='psdk-modal-body'>\n <div className='psdk-modal-links-row'>\n <div className='psdk-links-two-column'>\n <div className='psdk-modal-link-data'>\n <TextField\n fullWidth\n variant='outlined'\n label='Link title'\n size='small'\n required={required}\n value={link.title}\n onChange={fieldlinkOnChange}\n />\n </div>\n <div className='psdk-modal-link-data'>\n <TextField\n fullWidth\n variant='outlined'\n label='URL'\n size='small'\n required={required}\n value={link.url}\n onChange={fieldurlOnChange}\n />\n </div>\n </div>\n <div className='psdk-modal-link-add'>\n <Button\n className='psdk-add-link-action'\n color='primary'\n variant='contained'\n component='span'\n onClick={addLink}\n disabled={link.disable}\n >\n {thePConn.getLocalizedValue('Add link', '', '')}\n </Button>{' '}\n {/* 2nd and 3rd args empty string until typedef marked correctly */}\n </div>\n </div>\n {linkData.linksList.length > 0 && (\n <div style={{ marginTop: '1rem' }}>\n <SummaryList menuIconOverride$='trash' arItems$={linkData.linksList} menuIconOverrideAction$={removeLinksFromList} />\n </div>\n )}\n <ActionButtonsForFileUtil\n arMainButtons={linkData.linkMainButtons}\n arSecondaryButtons={linkData.linkSecondaryButtons}\n primaryAction={onAttachLinks}\n secondaryAction={closeAddLinksPopup}\n />\n </div>\n </div>\n </div>\n )}\n {showViewAllModal && (\n <div className='psdk-dialog-background'>\n <div className='psdk-modal-file-top'>\n <div className='psdk-view-all-header'>\n <h3>{thePConn.getLocalizedValue('Attachments', '', '')}</h3> {/* 2nd and 3rd args empty string until typedef marked correctly */}\n <button type='button' className='psdk-close-button' onClick={() => setViewAll(false)}>\n <img className='psdk-utility-card-actions-svg-icon' src={closeSvgIcon} />\n </button>\n </div>\n <div className='psdk-view-all-body'>\n <SummaryList arItems$={vaItems} />\n </div>\n </div>\n </div>\n )}\n </Card>\n );\n}\n"]}
@@ -1,5 +1,5 @@
1
- import { PropsWithChildren } from 'react';
2
- import { PConnProps } from '../../../types/PConnProps';
1
+ import type { PropsWithChildren } from 'react';
2
+ import type { PConnProps } from '../../../types/PConnProps';
3
3
  interface FollowersProps extends PConnProps {
4
4
  }
5
5
  export default function Followers(props: PropsWithChildren<FollowersProps>): import("react/jsx-runtime").JSX.Element;
@@ -1 +1 @@
1
- {"version":3,"file":"Followers.d.ts","sourceRoot":"","sources":["../../../../src/components/widget/Followers/Followers.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAG1C,OAAO,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AAEvD,UAAU,cAAe,SAAQ,UAAU;CAE1C;AAiBD,MAAM,CAAC,OAAO,UAAU,SAAS,CAAC,KAAK,EAAE,iBAAiB,CAAC,cAAc,CAAC,2CAoBzE"}
1
+ {"version":3,"file":"Followers.d.ts","sourceRoot":"","sources":["../../../../src/components/widget/Followers/Followers.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAG/C,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AAE5D,UAAU,cAAe,SAAQ,UAAU;CAE1C;AAeD,MAAM,CAAC,OAAO,UAAU,SAAS,CAAC,KAAK,EAAE,iBAAiB,CAAC,cAAc,CAAC,2CAoBzE"}
@@ -11,8 +11,6 @@ const useStyles = makeStyles(theme => ({
11
11
  marginLeft: theme.spacing(1),
12
12
  marginTop: theme.spacing(1),
13
13
  marginBottom: theme.spacing(1)
14
- // borderLeft: "6px solid",
15
- // borderLeftColor: green[300]
16
14
  }
17
15
  }));
18
16
  export default function Followers(props) {