@itwin/reports-config-widget-react 0.4.0 → 0.6.0

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 (393) hide show
  1. package/CHANGELOG.json +61 -0
  2. package/CHANGELOG.md +23 -2
  3. package/LICENSE.md +9 -9
  4. package/README.md +38 -38
  5. package/__mocks__/fileMock.js +4 -4
  6. package/api/reports-config-widget-react.api.md +130 -0
  7. package/api/reports-config-widget-react.exports.csv +14 -0
  8. package/api/temp/reports-config-widget-react.api.md +130 -0
  9. package/coverage/clover.xml +524 -514
  10. package/coverage/coverage-final.json +32 -32
  11. package/coverage/lcov-report/favicon.png +0 -0
  12. package/coverage/lcov-report/index.html +26 -26
  13. package/coverage/lcov-report/sort-arrow-sprite.png +0 -0
  14. package/coverage/lcov-report/src/ReportsConfigWidget.ts.html +15 -15
  15. package/coverage/lcov-report/src/index.html +1 -1
  16. package/coverage/lcov-report/src/test/index.html +15 -15
  17. package/coverage/lcov-report/src/test/test-utils.tsx.html +233 -20
  18. package/coverage/lcov-report/src/widget/ReportsConfigUiProvider.tsx.html +22 -64
  19. package/coverage/lcov-report/src/widget/components/ActionPanel.tsx.html +5 -38
  20. package/coverage/lcov-report/src/widget/components/AddMappingsModal.tsx.html +23 -119
  21. package/coverage/lcov-report/src/widget/components/BulkExtractor.ts.html +117 -90
  22. package/coverage/lcov-report/src/widget/components/Constants.ts.html +16 -10
  23. package/coverage/lcov-report/src/widget/components/DeleteModal.tsx.html +16 -106
  24. package/coverage/lcov-report/src/widget/components/ExtractionStates/FailedExtractionState.tsx.html +6 -21
  25. package/coverage/lcov-report/src/widget/components/ExtractionStates/QueuedExtractionState.tsx.html +6 -21
  26. package/coverage/lcov-report/src/widget/components/ExtractionStates/RunningExtractionState.tsx.html +7 -22
  27. package/coverage/lcov-report/src/widget/components/ExtractionStates/StartingExtractionState.tsx.html +7 -28
  28. package/coverage/lcov-report/src/widget/components/ExtractionStates/SucceededExtractionState.tsx.html +6 -21
  29. package/coverage/lcov-report/src/widget/components/ExtractionStates/index.html +1 -1
  30. package/coverage/lcov-report/src/widget/components/ExtractionStatus.tsx.html +20 -47
  31. package/coverage/lcov-report/src/widget/components/ExtractionToast.tsx.html +20 -11
  32. package/coverage/lcov-report/src/widget/components/HorizontalTile.tsx.html +16 -79
  33. package/coverage/lcov-report/src/widget/components/LocalizedTablePaginator.tsx.html +15 -108
  34. package/coverage/lcov-report/src/widget/components/ReportAction.tsx.html +36 -75
  35. package/coverage/lcov-report/src/widget/components/ReportHorizontalTile.tsx.html +62 -92
  36. package/coverage/lcov-report/src/widget/components/ReportMappingHorizontalTile.tsx.html +104 -128
  37. package/coverage/lcov-report/src/widget/components/ReportMappings.tsx.html +86 -299
  38. package/coverage/lcov-report/src/widget/components/Reports.tsx.html +64 -226
  39. package/coverage/lcov-report/src/widget/components/ReportsConfigContext.tsx.html +63 -45
  40. package/coverage/lcov-report/src/widget/components/ReportsContainer.tsx.html +10 -49
  41. package/coverage/lcov-report/src/widget/components/ReportsHeader.tsx.html +8 -47
  42. package/coverage/lcov-report/src/widget/components/ReportsRouter.tsx.html +6 -12
  43. package/coverage/lcov-report/src/widget/components/SearchBar.tsx.html +15 -27
  44. package/coverage/lcov-report/src/widget/components/SelectIModel.tsx.html +12 -57
  45. package/coverage/lcov-report/src/widget/components/index.html +56 -56
  46. package/coverage/lcov-report/src/widget/components/utils.tsx.html +32 -176
  47. package/coverage/lcov-report/src/widget/context/BulkExtractorContext.tsx.html +9 -15
  48. package/coverage/lcov-report/src/widget/context/ReportsConfigApiContext.tsx.html +9 -15
  49. package/coverage/lcov-report/src/widget/context/index.html +1 -1
  50. package/coverage/lcov-report/src/widget/hooks/index.html +1 -1
  51. package/coverage/lcov-report/src/widget/hooks/useValidator.ts.html +12 -54
  52. package/coverage/lcov-report/src/widget/index.html +1 -1
  53. package/coverage/lcov.info +959 -922
  54. package/jest.config.js +14 -17
  55. package/lib/cjs/ReportsConfigWidget.d.ts +4 -0
  56. package/lib/cjs/ReportsConfigWidget.d.ts.map +1 -1
  57. package/lib/cjs/ReportsConfigWidget.js +4 -0
  58. package/lib/cjs/ReportsConfigWidget.js.map +1 -1
  59. package/lib/cjs/reports-config-widget-react.js +8 -4
  60. package/lib/cjs/reports-config-widget-react.js.map +1 -1
  61. package/lib/cjs/test/AddMappingModal.test.js +24 -72
  62. package/lib/cjs/test/AddMappingModal.test.js.map +1 -1
  63. package/lib/cjs/test/BulkExtractor.test.js +73 -44
  64. package/lib/cjs/test/BulkExtractor.test.js.map +1 -1
  65. package/lib/cjs/test/DeleteModal.test.js +3 -3
  66. package/lib/cjs/test/DeleteModal.test.js.map +1 -1
  67. package/lib/cjs/test/ReportAction.test.js +6 -4
  68. package/lib/cjs/test/ReportAction.test.js.map +1 -1
  69. package/lib/cjs/test/ReportMappingHorizontalTile.test.js +76 -86
  70. package/lib/cjs/test/ReportMappingHorizontalTile.test.js.map +1 -1
  71. package/lib/cjs/test/ReportMappings.test.js +53 -80
  72. package/lib/cjs/test/ReportMappings.test.js.map +1 -1
  73. package/lib/cjs/test/Reports.test.js +54 -50
  74. package/lib/cjs/test/Reports.test.js.map +1 -1
  75. package/lib/cjs/test/WidgetHeader.test.js +3 -3
  76. package/lib/cjs/test/WidgetHeader.test.js.map +1 -1
  77. package/lib/cjs/test/test-utils.d.ts +38 -0
  78. package/lib/cjs/test/test-utils.d.ts.map +1 -1
  79. package/lib/cjs/test/test-utils.js +79 -5
  80. package/lib/cjs/test/test-utils.js.map +1 -1
  81. package/lib/cjs/tsconfig.tsbuildinfo +1 -1
  82. package/lib/cjs/widget/ReportsConfigUiProvider.d.ts +7 -0
  83. package/lib/cjs/widget/ReportsConfigUiProvider.d.ts.map +1 -1
  84. package/lib/cjs/widget/ReportsConfigUiProvider.js +13 -4
  85. package/lib/cjs/widget/ReportsConfigUiProvider.js.map +1 -1
  86. package/lib/cjs/widget/components/ActionPanel.d.ts.map +1 -1
  87. package/lib/cjs/widget/components/ActionPanel.js +5 -1
  88. package/lib/cjs/widget/components/ActionPanel.js.map +1 -1
  89. package/lib/cjs/widget/components/AddMappingsModal.d.ts +1 -1
  90. package/lib/cjs/widget/components/AddMappingsModal.d.ts.map +1 -1
  91. package/lib/cjs/widget/components/AddMappingsModal.js +12 -8
  92. package/lib/cjs/widget/components/AddMappingsModal.js.map +1 -1
  93. package/lib/cjs/widget/components/AddMappingsModal.scss +1 -1
  94. package/lib/cjs/widget/components/BulkExtractor.d.ts +7 -4
  95. package/lib/cjs/widget/components/BulkExtractor.d.ts.map +1 -1
  96. package/lib/cjs/widget/components/BulkExtractor.js +52 -35
  97. package/lib/cjs/widget/components/BulkExtractor.js.map +1 -1
  98. package/lib/cjs/widget/components/Constants.d.ts +1 -0
  99. package/lib/cjs/widget/components/Constants.d.ts.map +1 -1
  100. package/lib/cjs/widget/components/Constants.js +5 -4
  101. package/lib/cjs/widget/components/Constants.js.map +1 -1
  102. package/lib/cjs/widget/components/DeleteModal.d.ts +1 -1
  103. package/lib/cjs/widget/components/DeleteModal.d.ts.map +1 -1
  104. package/lib/cjs/widget/components/DeleteModal.js +10 -6
  105. package/lib/cjs/widget/components/DeleteModal.js.map +1 -1
  106. package/lib/cjs/widget/components/DeleteModal.scss +2 -2
  107. package/lib/cjs/widget/components/ExtractionStates/FailedExtractionState.d.ts.map +1 -1
  108. package/lib/cjs/widget/components/ExtractionStates/FailedExtractionState.js +3 -3
  109. package/lib/cjs/widget/components/ExtractionStates/FailedExtractionState.js.map +1 -1
  110. package/lib/cjs/widget/components/ExtractionStates/QueuedExtractionState.d.ts.map +1 -1
  111. package/lib/cjs/widget/components/ExtractionStates/QueuedExtractionState.js +3 -3
  112. package/lib/cjs/widget/components/ExtractionStates/QueuedExtractionState.js.map +1 -1
  113. package/lib/cjs/widget/components/ExtractionStates/RunningExtractionState.d.ts.map +1 -1
  114. package/lib/cjs/widget/components/ExtractionStates/RunningExtractionState.js +3 -3
  115. package/lib/cjs/widget/components/ExtractionStates/RunningExtractionState.js.map +1 -1
  116. package/lib/cjs/widget/components/ExtractionStates/StartingExtractionState.d.ts.map +1 -1
  117. package/lib/cjs/widget/components/ExtractionStates/StartingExtractionState.js +3 -3
  118. package/lib/cjs/widget/components/ExtractionStates/StartingExtractionState.js.map +1 -1
  119. package/lib/cjs/widget/components/ExtractionStates/SucceededExtractionState.d.ts.map +1 -1
  120. package/lib/cjs/widget/components/ExtractionStates/SucceededExtractionState.js +3 -3
  121. package/lib/cjs/widget/components/ExtractionStates/SucceededExtractionState.js.map +1 -1
  122. package/lib/cjs/widget/components/ExtractionStatus.d.ts +1 -1
  123. package/lib/cjs/widget/components/ExtractionStatus.d.ts.map +1 -1
  124. package/lib/cjs/widget/components/ExtractionStatus.js +14 -10
  125. package/lib/cjs/widget/components/ExtractionStatus.js.map +1 -1
  126. package/lib/cjs/widget/components/ExtractionStatus.scss +1 -1
  127. package/lib/cjs/widget/components/ExtractionToast.d.ts.map +1 -1
  128. package/lib/cjs/widget/components/ExtractionToast.js +3 -3
  129. package/lib/cjs/widget/components/ExtractionToast.js.map +1 -1
  130. package/lib/cjs/widget/components/HorizontalTile.d.ts.map +1 -1
  131. package/lib/cjs/widget/components/HorizontalTile.js +1 -2
  132. package/lib/cjs/widget/components/HorizontalTile.js.map +1 -1
  133. package/lib/cjs/widget/components/HorizontalTile.scss +1 -4
  134. package/lib/cjs/widget/components/LocalizedTablePaginator.d.ts.map +1 -1
  135. package/lib/cjs/widget/components/LocalizedTablePaginator.js +6 -2
  136. package/lib/cjs/widget/components/LocalizedTablePaginator.js.map +1 -1
  137. package/lib/cjs/widget/components/ReportAction.d.ts +8 -0
  138. package/lib/cjs/widget/components/ReportAction.d.ts.map +1 -1
  139. package/lib/cjs/widget/components/ReportAction.js +14 -8
  140. package/lib/cjs/widget/components/ReportAction.js.map +1 -1
  141. package/lib/cjs/widget/components/ReportAction.scss +1 -1
  142. package/lib/cjs/widget/components/ReportHorizontalTile.d.ts.map +1 -1
  143. package/lib/cjs/widget/components/ReportHorizontalTile.js +9 -5
  144. package/lib/cjs/widget/components/ReportHorizontalTile.js.map +1 -1
  145. package/lib/cjs/widget/components/ReportMappingHorizontalTile.d.ts.map +1 -1
  146. package/lib/cjs/widget/components/ReportMappingHorizontalTile.js +51 -46
  147. package/lib/cjs/widget/components/ReportMappingHorizontalTile.js.map +1 -1
  148. package/lib/cjs/widget/components/ReportMappings.d.ts +8 -0
  149. package/lib/cjs/widget/components/ReportMappings.d.ts.map +1 -1
  150. package/lib/cjs/widget/components/ReportMappings.js +30 -12
  151. package/lib/cjs/widget/components/ReportMappings.js.map +1 -1
  152. package/lib/cjs/widget/components/Reports.d.ts +9 -1
  153. package/lib/cjs/widget/components/Reports.d.ts.map +1 -1
  154. package/lib/cjs/widget/components/Reports.js +12 -9
  155. package/lib/cjs/widget/components/Reports.js.map +1 -1
  156. package/lib/cjs/widget/components/Reports.scss +0 -1
  157. package/lib/cjs/widget/components/ReportsConfigContext.d.ts +8 -0
  158. package/lib/cjs/widget/components/ReportsConfigContext.d.ts.map +1 -1
  159. package/lib/cjs/widget/components/ReportsConfigContext.js +20 -7
  160. package/lib/cjs/widget/components/ReportsConfigContext.js.map +1 -1
  161. package/lib/cjs/widget/components/ReportsContainer.d.ts +1 -1
  162. package/lib/cjs/widget/components/ReportsContainer.d.ts.map +1 -1
  163. package/lib/cjs/widget/components/ReportsContainer.js +7 -5
  164. package/lib/cjs/widget/components/ReportsContainer.js.map +1 -1
  165. package/lib/cjs/widget/components/ReportsContainer.scss +1 -1
  166. package/lib/cjs/widget/components/ReportsHeader.d.ts +1 -1
  167. package/lib/cjs/widget/components/ReportsHeader.d.ts.map +1 -1
  168. package/lib/cjs/widget/components/ReportsHeader.js +6 -7
  169. package/lib/cjs/widget/components/ReportsHeader.js.map +1 -1
  170. package/lib/cjs/widget/components/ReportsRouter.d.ts.map +1 -1
  171. package/lib/cjs/widget/components/ReportsRouter.js +3 -3
  172. package/lib/cjs/widget/components/ReportsRouter.js.map +1 -1
  173. package/lib/cjs/widget/components/SearchBar.d.ts +1 -1
  174. package/lib/cjs/widget/components/SearchBar.d.ts.map +1 -1
  175. package/lib/cjs/widget/components/SearchBar.js +9 -5
  176. package/lib/cjs/widget/components/SearchBar.js.map +1 -1
  177. package/lib/cjs/widget/components/SelectIModel.d.ts +1 -1
  178. package/lib/cjs/widget/components/SelectIModel.d.ts.map +1 -1
  179. package/lib/cjs/widget/components/SelectIModel.js +7 -3
  180. package/lib/cjs/widget/components/SelectIModel.js.map +1 -1
  181. package/lib/cjs/widget/components/SelectIModel.scss +1 -1
  182. package/lib/cjs/widget/components/utils.d.ts +1 -1
  183. package/lib/cjs/widget/components/utils.d.ts.map +1 -1
  184. package/lib/cjs/widget/components/utils.js +5 -5
  185. package/lib/cjs/widget/components/utils.js.map +1 -1
  186. package/lib/cjs/widget/components/utils.scss +1 -1
  187. package/lib/cjs/widget/context/BulkExtractorContext.d.ts.map +1 -1
  188. package/lib/cjs/widget/context/BulkExtractorContext.js +5 -1
  189. package/lib/cjs/widget/context/BulkExtractorContext.js.map +1 -1
  190. package/lib/cjs/widget/context/ReportsConfigApiContext.d.ts.map +1 -1
  191. package/lib/cjs/widget/context/ReportsConfigApiContext.js +5 -1
  192. package/lib/cjs/widget/context/ReportsConfigApiContext.js.map +1 -1
  193. package/lib/cjs/widget/hooks/useValidator.d.ts +1 -4
  194. package/lib/cjs/widget/hooks/useValidator.d.ts.map +1 -1
  195. package/lib/cjs/widget/hooks/useValidator.js +3 -3
  196. package/lib/cjs/widget/hooks/useValidator.js.map +1 -1
  197. package/lib/esm/ReportsConfigWidget.d.ts +4 -0
  198. package/lib/esm/ReportsConfigWidget.d.ts.map +1 -1
  199. package/lib/esm/ReportsConfigWidget.js +4 -0
  200. package/lib/esm/ReportsConfigWidget.js.map +1 -1
  201. package/lib/esm/reports-config-widget-react.js +3 -3
  202. package/lib/esm/reports-config-widget-react.js.map +1 -1
  203. package/lib/esm/test/AddMappingModal.test.js +12 -64
  204. package/lib/esm/test/AddMappingModal.test.js.map +1 -1
  205. package/lib/esm/test/BulkExtractor.test.js +69 -44
  206. package/lib/esm/test/BulkExtractor.test.js.map +1 -1
  207. package/lib/esm/test/DeleteModal.test.js +4 -4
  208. package/lib/esm/test/DeleteModal.test.js.map +1 -1
  209. package/lib/esm/test/ReportAction.test.js +7 -5
  210. package/lib/esm/test/ReportAction.test.js.map +1 -1
  211. package/lib/esm/test/ReportMappingHorizontalTile.test.js +66 -80
  212. package/lib/esm/test/ReportMappingHorizontalTile.test.js.map +1 -1
  213. package/lib/esm/test/ReportMappings.test.js +42 -73
  214. package/lib/esm/test/ReportMappings.test.js.map +1 -1
  215. package/lib/esm/test/Reports.test.js +32 -51
  216. package/lib/esm/test/Reports.test.js.map +1 -1
  217. package/lib/esm/test/WidgetHeader.test.js +3 -3
  218. package/lib/esm/test/WidgetHeader.test.js.map +1 -1
  219. package/lib/esm/test/test-utils.d.ts +38 -0
  220. package/lib/esm/test/test-utils.d.ts.map +1 -1
  221. package/lib/esm/test/test-utils.js +73 -3
  222. package/lib/esm/test/test-utils.js.map +1 -1
  223. package/lib/esm/tsconfig.tsbuildinfo +1 -1
  224. package/lib/esm/widget/ReportsConfigUiProvider.d.ts +7 -0
  225. package/lib/esm/widget/ReportsConfigUiProvider.d.ts.map +1 -1
  226. package/lib/esm/widget/ReportsConfigUiProvider.js +9 -4
  227. package/lib/esm/widget/ReportsConfigUiProvider.js.map +1 -1
  228. package/lib/esm/widget/components/ActionPanel.d.ts.map +1 -1
  229. package/lib/esm/widget/components/ActionPanel.js.map +1 -1
  230. package/lib/esm/widget/components/AddMappingsModal.d.ts +1 -1
  231. package/lib/esm/widget/components/AddMappingsModal.d.ts.map +1 -1
  232. package/lib/esm/widget/components/AddMappingsModal.js +7 -7
  233. package/lib/esm/widget/components/AddMappingsModal.js.map +1 -1
  234. package/lib/esm/widget/components/AddMappingsModal.scss +1 -1
  235. package/lib/esm/widget/components/BulkExtractor.d.ts +7 -4
  236. package/lib/esm/widget/components/BulkExtractor.d.ts.map +1 -1
  237. package/lib/esm/widget/components/BulkExtractor.js +53 -36
  238. package/lib/esm/widget/components/BulkExtractor.js.map +1 -1
  239. package/lib/esm/widget/components/Constants.d.ts +1 -0
  240. package/lib/esm/widget/components/Constants.d.ts.map +1 -1
  241. package/lib/esm/widget/components/Constants.js +4 -3
  242. package/lib/esm/widget/components/Constants.js.map +1 -1
  243. package/lib/esm/widget/components/DeleteModal.d.ts +1 -1
  244. package/lib/esm/widget/components/DeleteModal.d.ts.map +1 -1
  245. package/lib/esm/widget/components/DeleteModal.js +6 -6
  246. package/lib/esm/widget/components/DeleteModal.js.map +1 -1
  247. package/lib/esm/widget/components/DeleteModal.scss +2 -2
  248. package/lib/esm/widget/components/ExtractionStates/FailedExtractionState.d.ts.map +1 -1
  249. package/lib/esm/widget/components/ExtractionStates/FailedExtractionState.js +3 -3
  250. package/lib/esm/widget/components/ExtractionStates/FailedExtractionState.js.map +1 -1
  251. package/lib/esm/widget/components/ExtractionStates/QueuedExtractionState.d.ts.map +1 -1
  252. package/lib/esm/widget/components/ExtractionStates/QueuedExtractionState.js +3 -3
  253. package/lib/esm/widget/components/ExtractionStates/QueuedExtractionState.js.map +1 -1
  254. package/lib/esm/widget/components/ExtractionStates/RunningExtractionState.d.ts.map +1 -1
  255. package/lib/esm/widget/components/ExtractionStates/RunningExtractionState.js +3 -3
  256. package/lib/esm/widget/components/ExtractionStates/RunningExtractionState.js.map +1 -1
  257. package/lib/esm/widget/components/ExtractionStates/StartingExtractionState.d.ts.map +1 -1
  258. package/lib/esm/widget/components/ExtractionStates/StartingExtractionState.js +3 -3
  259. package/lib/esm/widget/components/ExtractionStates/StartingExtractionState.js.map +1 -1
  260. package/lib/esm/widget/components/ExtractionStates/SucceededExtractionState.d.ts.map +1 -1
  261. package/lib/esm/widget/components/ExtractionStates/SucceededExtractionState.js +3 -3
  262. package/lib/esm/widget/components/ExtractionStates/SucceededExtractionState.js.map +1 -1
  263. package/lib/esm/widget/components/ExtractionStatus.d.ts +1 -1
  264. package/lib/esm/widget/components/ExtractionStatus.d.ts.map +1 -1
  265. package/lib/esm/widget/components/ExtractionStatus.js +9 -9
  266. package/lib/esm/widget/components/ExtractionStatus.js.map +1 -1
  267. package/lib/esm/widget/components/ExtractionStatus.scss +1 -1
  268. package/lib/esm/widget/components/ExtractionToast.d.ts.map +1 -1
  269. package/lib/esm/widget/components/ExtractionToast.js +3 -3
  270. package/lib/esm/widget/components/ExtractionToast.js.map +1 -1
  271. package/lib/esm/widget/components/HorizontalTile.d.ts.map +1 -1
  272. package/lib/esm/widget/components/HorizontalTile.js +1 -2
  273. package/lib/esm/widget/components/HorizontalTile.js.map +1 -1
  274. package/lib/esm/widget/components/HorizontalTile.scss +1 -4
  275. package/lib/esm/widget/components/LocalizedTablePaginator.d.ts.map +1 -1
  276. package/lib/esm/widget/components/LocalizedTablePaginator.js +1 -1
  277. package/lib/esm/widget/components/LocalizedTablePaginator.js.map +1 -1
  278. package/lib/esm/widget/components/ReportAction.d.ts +8 -0
  279. package/lib/esm/widget/components/ReportAction.d.ts.map +1 -1
  280. package/lib/esm/widget/components/ReportAction.js +10 -8
  281. package/lib/esm/widget/components/ReportAction.js.map +1 -1
  282. package/lib/esm/widget/components/ReportAction.scss +1 -1
  283. package/lib/esm/widget/components/ReportHorizontalTile.d.ts.map +1 -1
  284. package/lib/esm/widget/components/ReportHorizontalTile.js +6 -6
  285. package/lib/esm/widget/components/ReportHorizontalTile.js.map +1 -1
  286. package/lib/esm/widget/components/ReportMappingHorizontalTile.d.ts.map +1 -1
  287. package/lib/esm/widget/components/ReportMappingHorizontalTile.js +47 -46
  288. package/lib/esm/widget/components/ReportMappingHorizontalTile.js.map +1 -1
  289. package/lib/esm/widget/components/ReportMappings.d.ts +8 -0
  290. package/lib/esm/widget/components/ReportMappings.d.ts.map +1 -1
  291. package/lib/esm/widget/components/ReportMappings.js +28 -14
  292. package/lib/esm/widget/components/ReportMappings.js.map +1 -1
  293. package/lib/esm/widget/components/Reports.d.ts +9 -1
  294. package/lib/esm/widget/components/Reports.d.ts.map +1 -1
  295. package/lib/esm/widget/components/Reports.js +8 -9
  296. package/lib/esm/widget/components/Reports.js.map +1 -1
  297. package/lib/esm/widget/components/Reports.scss +0 -1
  298. package/lib/esm/widget/components/ReportsConfigContext.d.ts +8 -0
  299. package/lib/esm/widget/components/ReportsConfigContext.d.ts.map +1 -1
  300. package/lib/esm/widget/components/ReportsConfigContext.js +17 -8
  301. package/lib/esm/widget/components/ReportsConfigContext.js.map +1 -1
  302. package/lib/esm/widget/components/ReportsContainer.d.ts +1 -1
  303. package/lib/esm/widget/components/ReportsContainer.d.ts.map +1 -1
  304. package/lib/esm/widget/components/ReportsContainer.js +2 -4
  305. package/lib/esm/widget/components/ReportsContainer.js.map +1 -1
  306. package/lib/esm/widget/components/ReportsContainer.scss +1 -1
  307. package/lib/esm/widget/components/ReportsHeader.d.ts +1 -1
  308. package/lib/esm/widget/components/ReportsHeader.d.ts.map +1 -1
  309. package/lib/esm/widget/components/ReportsHeader.js +6 -7
  310. package/lib/esm/widget/components/ReportsHeader.js.map +1 -1
  311. package/lib/esm/widget/components/ReportsRouter.d.ts.map +1 -1
  312. package/lib/esm/widget/components/ReportsRouter.js +3 -3
  313. package/lib/esm/widget/components/ReportsRouter.js.map +1 -1
  314. package/lib/esm/widget/components/SearchBar.d.ts +1 -1
  315. package/lib/esm/widget/components/SearchBar.d.ts.map +1 -1
  316. package/lib/esm/widget/components/SearchBar.js +4 -4
  317. package/lib/esm/widget/components/SearchBar.js.map +1 -1
  318. package/lib/esm/widget/components/SelectIModel.d.ts +1 -1
  319. package/lib/esm/widget/components/SelectIModel.d.ts.map +1 -1
  320. package/lib/esm/widget/components/SelectIModel.js +3 -3
  321. package/lib/esm/widget/components/SelectIModel.js.map +1 -1
  322. package/lib/esm/widget/components/SelectIModel.scss +1 -1
  323. package/lib/esm/widget/components/utils.d.ts +1 -1
  324. package/lib/esm/widget/components/utils.d.ts.map +1 -1
  325. package/lib/esm/widget/components/utils.js +6 -6
  326. package/lib/esm/widget/components/utils.js.map +1 -1
  327. package/lib/esm/widget/components/utils.scss +1 -1
  328. package/lib/esm/widget/context/BulkExtractorContext.d.ts.map +1 -1
  329. package/lib/esm/widget/context/BulkExtractorContext.js.map +1 -1
  330. package/lib/esm/widget/context/ReportsConfigApiContext.d.ts.map +1 -1
  331. package/lib/esm/widget/context/ReportsConfigApiContext.js.map +1 -1
  332. package/lib/esm/widget/hooks/useValidator.d.ts +1 -4
  333. package/lib/esm/widget/hooks/useValidator.d.ts.map +1 -1
  334. package/lib/esm/widget/hooks/useValidator.js +3 -3
  335. package/lib/esm/widget/hooks/useValidator.js.map +1 -1
  336. package/package.json +37 -31
  337. package/src/ReportsConfigWidget.ts +9 -9
  338. package/src/reports-config-widget-react.ts +3 -3
  339. package/src/test/AddMappingModal.test.tsx +47 -122
  340. package/src/test/BulkExtractor.test.ts +73 -118
  341. package/src/test/DeleteModal.test.tsx +6 -23
  342. package/src/test/ReportAction.test.tsx +20 -38
  343. package/src/test/ReportMappingHorizontalTile.test.tsx +140 -161
  344. package/src/test/ReportMappings.test.tsx +80 -146
  345. package/src/test/Reports.test.tsx +57 -169
  346. package/src/test/WidgetHeader.test.tsx +3 -3
  347. package/src/test/test-utils.tsx +80 -9
  348. package/src/widget/ReportsConfigUiProvider.tsx +16 -30
  349. package/src/widget/components/ActionPanel.tsx +3 -14
  350. package/src/widget/components/AddMappingsModal.scss +1 -1
  351. package/src/widget/components/AddMappingsModal.tsx +19 -51
  352. package/src/widget/components/BulkExtractor.ts +63 -54
  353. package/src/widget/components/Constants.ts +5 -3
  354. package/src/widget/components/DeleteModal.scss +2 -2
  355. package/src/widget/components/DeleteModal.tsx +11 -41
  356. package/src/widget/components/ExtractionStates/FailedExtractionState.tsx +4 -9
  357. package/src/widget/components/ExtractionStates/QueuedExtractionState.tsx +4 -9
  358. package/src/widget/components/ExtractionStates/RunningExtractionState.tsx +4 -9
  359. package/src/widget/components/ExtractionStates/StartingExtractionState.tsx +4 -11
  360. package/src/widget/components/ExtractionStates/SucceededExtractionState.tsx +4 -9
  361. package/src/widget/components/ExtractionStatus.scss +1 -1
  362. package/src/widget/components/ExtractionStatus.tsx +9 -18
  363. package/src/widget/components/ExtractionToast.tsx +12 -9
  364. package/src/widget/components/HorizontalTile.scss +1 -4
  365. package/src/widget/components/HorizontalTile.tsx +12 -33
  366. package/src/widget/components/LocalizedTablePaginator.tsx +13 -44
  367. package/src/widget/components/ReportAction.scss +1 -1
  368. package/src/widget/components/ReportAction.tsx +26 -39
  369. package/src/widget/components/ReportHorizontalTile.tsx +45 -55
  370. package/src/widget/components/ReportMappingHorizontalTile.tsx +70 -78
  371. package/src/widget/components/ReportMappings.tsx +59 -130
  372. package/src/widget/components/Reports.scss +0 -1
  373. package/src/widget/components/Reports.tsx +28 -82
  374. package/src/widget/components/ReportsConfigContext.tsx +32 -26
  375. package/src/widget/components/ReportsContainer.scss +1 -1
  376. package/src/widget/components/ReportsContainer.tsx +8 -21
  377. package/src/widget/components/ReportsHeader.tsx +6 -19
  378. package/src/widget/components/ReportsRouter.tsx +4 -6
  379. package/src/widget/components/SearchBar.tsx +9 -13
  380. package/src/widget/components/SelectIModel.scss +1 -1
  381. package/src/widget/components/SelectIModel.tsx +10 -25
  382. package/src/widget/components/utils.scss +1 -1
  383. package/src/widget/components/utils.tsx +21 -69
  384. package/src/widget/context/BulkExtractorContext.tsx +4 -6
  385. package/src/widget/context/ReportsConfigApiContext.tsx +4 -6
  386. package/src/widget/hooks/useValidator.ts +10 -24
  387. package/tsconfig.json +11 -11
  388. package/.rush/temp/operation/rebuild/all.log +0 -9
  389. package/.rush/temp/operation/rebuild/state.json +0 -3
  390. package/.rush/temp/package-deps_rebuild.json +0 -68
  391. package/.rush/temp/shrinkwrap-deps.json +0 -898
  392. package/reports-config-widget-react.build.error.log +0 -14
  393. package/reports-config-widget-react.build.log +0 -63
package/CHANGELOG.json CHANGED
@@ -1,6 +1,67 @@
1
1
  {
2
2
  "name": "@itwin/reports-config-widget-react",
3
3
  "entries": [
4
+ {
5
+ "date": "Mon, 10 Jun 2024 17:40:08 GMT",
6
+ "version": "0.6.0",
7
+ "tag": "@itwin/reports-config-widget-react_v0.6.0",
8
+ "comments": {
9
+ "patch": [
10
+ {
11
+ "author": "Guillar1@users.noreply.github.com",
12
+ "package": "@itwin/reports-config-widget-react",
13
+ "commit": "5afd6004849184a8a417df306e956af6d5eca51b",
14
+ "comment": "Fixed an issue that caused the extraction state for the mappings in the ReportMappings component to keep appearing after every rerender while in a final state."
15
+ }
16
+ ],
17
+ "none": [
18
+ {
19
+ "author": "hansraj.koravenciah@bentley.com",
20
+ "package": "@itwin/reports-config-widget-react",
21
+ "commit": "36c49a556b4c99a4203d243fcb44581ec80ee9fb",
22
+ "comment": "Ran prettier on ec3, lca, reportconfig and reportmapping widgets"
23
+ }
24
+ ],
25
+ "minor": [
26
+ {
27
+ "author": "hansraj.koravenciah@bentley.com",
28
+ "package": "@itwin/reports-config-widget-react",
29
+ "commit": "fb68ffda26c43a99920e14d53d4d0a70c9a79c38",
30
+ "comment": "Upgraded insights-client version to 0.10.1, fixed functions using old dependencies"
31
+ }
32
+ ]
33
+ }
34
+ },
35
+ {
36
+ "date": "Tue, 21 May 2024 13:26:36 GMT",
37
+ "version": "0.5.0",
38
+ "tag": "@itwin/reports-config-widget-react_v0.5.0",
39
+ "comments": {
40
+ "none": [
41
+ {
42
+ "author": "Guillar1@users.noreply.github.com",
43
+ "package": "@itwin/reports-config-widget-react",
44
+ "commit": "60fe54a19b5a2d8354163b137da975cd27be8489",
45
+ "comment": ""
46
+ }
47
+ ]
48
+ }
49
+ },
50
+ {
51
+ "date": "Mon, 29 Jan 2024 21:37:20 GMT",
52
+ "version": "0.5.0",
53
+ "tag": "@itwin/reports-config-widget-react_v0.5.0",
54
+ "comments": {
55
+ "minor": [
56
+ {
57
+ "author": "Guillar1@users.noreply.github.com",
58
+ "package": "@itwin/reports-config-widget-react",
59
+ "commit": "4d4f9d3fc3641ed87537be729e5fffd7312c4402",
60
+ "comment": "Updated iModels client"
61
+ }
62
+ ]
63
+ }
64
+ },
4
65
  {
5
66
  "version": "0.4.0",
6
67
  "tag": "@itwin/reports-config-widget-react_v0.4.0",
package/CHANGELOG.md CHANGED
@@ -1,6 +1,28 @@
1
1
  # Change Log - @itwin/reports-config-widget-react
2
2
 
3
- This log was last generated on Thu, 17 Aug 2023 14:42:37 GMT and should not be manually modified.
3
+ This log was last generated on Mon, 10 Jun 2024 17:40:08 GMT and should not be manually modified.
4
+
5
+ <!-- Start content -->
6
+
7
+ ## 0.6.0
8
+
9
+ Mon, 10 Jun 2024 17:40:08 GMT
10
+
11
+ ### Minor changes
12
+
13
+ - Upgraded insights-client version to 0.10.1, fixed functions using old dependencies ([#841](https://github.com/iTwin/viewer-components-react/pull/841))
14
+
15
+ ### Patches
16
+
17
+ - Fixed an issue that caused the extraction state for the mappings in the ReportMappings component to keep appearing after every rerender while in a final state. ([#866](https://github.com/iTwin/viewer-components-react/pull/866))
18
+
19
+ ## 0.5.0
20
+
21
+ Mon, 29 Jan 2024 21:37:20 GMT
22
+
23
+ ### Minor changes
24
+
25
+ - Updated iModels client ([#747](https://github.com/iTwin/viewer-components-react/pull/747))
4
26
 
5
27
  ## 0.4.0
6
28
  Thu, 17 Aug 2023 14:42:37 GMT
@@ -106,4 +128,3 @@ Tue, 14 Jun 2022 16:01:06 GMT
106
128
  ### Patches
107
129
 
108
130
  - Initial release of the reports config widget for Reporting Platform
109
-
package/LICENSE.md CHANGED
@@ -1,9 +1,9 @@
1
- # MIT License
2
-
3
- Copyright © 2022 Bentley Systems, Inc. All rights reserved.
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
6
-
7
- The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
8
-
9
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
1
+ # MIT License
2
+
3
+ Copyright © 2022 Bentley Systems, Inc. All rights reserved.
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
6
+
7
+ The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
8
+
9
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
package/README.md CHANGED
@@ -1,38 +1,38 @@
1
- # @itwin/reports-config-widget-react
2
-
3
- Copyright © Bentley Systems, Incorporated. All rights reserved.
4
- The Reports Config widget is a UI component for iTwin Viewer applications that simplifies how users (and developers) interface with the [Reporting Platform APIs](https://developer.bentley.com/apis/insights/overview/). This widget is one piece of the Reporting story that focuses on the configuration of Reports and the extraction thereof. It complements the [Grouping & Mapping Widget](https://www.npmjs.com/package/@itwin/grouping-mapping-widget).
5
- The reports-config-widget-react package provides a UiProvider class - `ReportsConfigProvider` - which can be passed into the `uiProviders` prop of the iTwin Viewer's `<Viewer />` component.
6
-
7
- ## Getting Started
8
-
9
- This is not a standalone UI and requires a parent iTwin Viewer application to work as intended.
10
- A guide on how to create a basic iTwin Viewer application can be found here: <https://www.itwinjs.org/learning/tutorials/develop-web-viewer/>.
11
- This package provides a viewer 'widget'. Documentation on how to add a widget to your application can be found here: <https://developer.bentley.com/tutorials/itwin-viewer-hello-world/#2-your-first-ui-widget>.
12
-
13
- ## Permissions and Scopes
14
-
15
- The SPA client used by your iTwin viewer must have these additional scopes:
16
-
17
- - `insights:read`
18
- - `insights:modify`
19
- - `projects:read`
20
-
21
- In addition, users must have the `imodels_read` and `imodels_write` [permissions](https://developer.bentley.com/apis/insights/operations/create-mapping/#authorization) assigned at either the Project or iModel level. Further instruction on how to create roles and assign permissions can be found in the [iTwin Platform Projects API documentation](https://developer.bentley.com/apis/projects/tutorials/).
22
-
23
- ## Sample usage
24
-
25
- ### Call ReportsConfigWidget.initialize() **_before_** making use of the provider
26
-
27
- ```ts
28
- import { ReportsConfigProvider, ReportsConfigWidget } from '@itwin/reports-config-widget-react'
29
-
30
- ...
31
-
32
- await ReportsConfigWidget.initialize(IModelApp.localization);
33
-
34
- <Viewer
35
- ...
36
- uiProviders={[new ReportsConfigProvider()]}
37
- />
38
- ```
1
+ # @itwin/reports-config-widget-react
2
+
3
+ Copyright © Bentley Systems, Incorporated. All rights reserved.
4
+ The Reports Config widget is a UI component for iTwin Viewer applications that simplifies how users (and developers) interface with the [Reporting Platform APIs](https://developer.bentley.com/apis/insights/overview/). This widget is one piece of the Reporting story that focuses on the configuration of Reports and the extraction thereof. It complements the [Grouping & Mapping Widget](https://www.npmjs.com/package/@itwin/grouping-mapping-widget).
5
+ The reports-config-widget-react package provides a UiProvider class - `ReportsConfigProvider` - which can be passed into the `uiProviders` prop of the iTwin Viewer's `<Viewer />` component.
6
+
7
+ ## Getting Started
8
+
9
+ This is not a standalone UI and requires a parent iTwin Viewer application to work as intended.
10
+ A guide on how to create a basic iTwin Viewer application can be found here: <https://www.itwinjs.org/learning/tutorials/develop-web-viewer/>.
11
+ This package provides a viewer 'widget'. Documentation on how to add a widget to your application can be found here: <https://developer.bentley.com/tutorials/itwin-viewer-hello-world/#2-your-first-ui-widget>.
12
+
13
+ ## Permissions and Scopes
14
+
15
+ The SPA client used by your iTwin viewer must have these additional scopes:
16
+
17
+ - `insights:read`
18
+ - `insights:modify`
19
+ - `projects:read`
20
+
21
+ In addition, users must have the `imodels_read` and `imodels_write` [permissions](https://developer.bentley.com/apis/insights/operations/create-mapping/#authorization) assigned at either the Project or iModel level. Further instruction on how to create roles and assign permissions can be found in the [iTwin Platform Projects API documentation](https://developer.bentley.com/apis/projects/tutorials/).
22
+
23
+ ## Sample usage
24
+
25
+ ### Call ReportsConfigWidget.initialize() **_before_** making use of the provider
26
+
27
+ ```ts
28
+ import { ReportsConfigProvider, ReportsConfigWidget } from '@itwin/reports-config-widget-react'
29
+
30
+ ...
31
+
32
+ await ReportsConfigWidget.initialize(IModelApp.localization);
33
+
34
+ <Viewer
35
+ ...
36
+ uiProviders={[new ReportsConfigProvider()]}
37
+ />
38
+ ```
@@ -1,5 +1,5 @@
1
1
  /*---------------------------------------------------------------------------------------------
2
- * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
- * See LICENSE.md in the project root for license terms and full copyright notice.
4
- *--------------------------------------------------------------------------------------------*/
5
- module.exports = {};
2
+ * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
+ * See LICENSE.md in the project root for license terms and full copyright notice.
4
+ *--------------------------------------------------------------------------------------------*/
5
+ module.exports = {};
@@ -0,0 +1,130 @@
1
+ ## API Report File for "@itwin/reports-config-widget-react"
2
+
3
+ > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
4
+
5
+ ```ts
6
+
7
+ /// <reference types="react" />
8
+
9
+ import type { AccessToken } from '@itwin/core-bentley';
10
+ import { ExtractionClient } from '@itwin/insights-client';
11
+ import type { ExtractionRequestDetails } from '@itwin/insights-client';
12
+ import { IModelsClient } from '@itwin/imodels-client-management';
13
+ import type { Localization } from '@itwin/core-common';
14
+ import { MappingsClient } from '@itwin/insights-client';
15
+ import { default as React_2 } from 'react';
16
+ import type { Report } from '@itwin/insights-client';
17
+ import { ReportsClient } from '@itwin/insights-client';
18
+ import { StagePanelLocation } from '@itwin/appui-react';
19
+ import { StagePanelSection } from '@itwin/appui-react';
20
+ import type { UiItemsProvider } from '@itwin/appui-react';
21
+ import type { Widget } from '@itwin/appui-react';
22
+
23
+ // @public (undocumented)
24
+ export class BulkExtractor {
25
+ constructor(reportsClient: ReportsClient, extractionClient: ExtractionClient, getAccessToken: () => Promise<AccessToken>, successfulExtractionToast: (iModelName: string, odataFeedUrl: string) => void, failedExtractionToast: (iModelName: string) => void);
26
+ // (undocumented)
27
+ getIModelState(iModelId: string, iModelName: string, odataFeedUrl: string): Promise<ExtractionStates>;
28
+ // (undocumented)
29
+ getReportState(reportId: string): Promise<ExtractionStates>;
30
+ // (undocumented)
31
+ runIModelExtraction(extractionRequestDetails: ExtractionRequestDetails): Promise<void>;
32
+ // (undocumented)
33
+ runIModelExtractions(extractionRequestsDetails: ExtractionRequestDetails[]): Promise<void>;
34
+ // (undocumented)
35
+ runReportExtractions(reportIds: string[]): Promise<void>;
36
+ // (undocumented)
37
+ setHook(setJobRunning: React.Dispatch<React.SetStateAction<boolean>>, iModels: string[]): void;
38
+ }
39
+
40
+ // @public
41
+ export const ReportAction: ({ report, onSaveSuccess, onClickCancel }: ReportActionProps) => JSX.Element;
42
+
43
+ // @public
44
+ export interface ReportActionProps {
45
+ // (undocumented)
46
+ onClickCancel?: () => void;
47
+ // (undocumented)
48
+ onSaveSuccess: () => void;
49
+ // (undocumented)
50
+ report?: Report;
51
+ }
52
+
53
+ // @public
54
+ export const ReportMappings: ({ report, onClickClose, defaultIModelId }: ReportMappingsProps) => JSX.Element | null;
55
+
56
+ // @public
57
+ export interface ReportMappingsProps {
58
+ // (undocumented)
59
+ defaultIModelId?: string;
60
+ // (undocumented)
61
+ onClickClose: () => void;
62
+ // (undocumented)
63
+ report: Report;
64
+ }
65
+
66
+ // @public
67
+ export const Reports: ({ onClickAddReport, onClickReportModify, onClickReportTitle }: ReportsProps) => JSX.Element | null;
68
+
69
+ // @internal (undocumented)
70
+ export const REPORTS_CONFIG_BASE_URL = "https://api.bentley.com";
71
+
72
+ // @public
73
+ export const ReportsConfigContext: (props: ReportsConfigContextProps) => JSX.Element;
74
+
75
+ // @public
76
+ export interface ReportsConfigContextProps {
77
+ // (undocumented)
78
+ baseUrl?: string;
79
+ // (undocumented)
80
+ bulkExtractor?: BulkExtractor;
81
+ // (undocumented)
82
+ children?: React_2.ReactNode;
83
+ // (undocumented)
84
+ extractionClient?: ExtractionClient;
85
+ // (undocumented)
86
+ getAccessToken?: GetAccessTokenFn;
87
+ // (undocumented)
88
+ iModelsClient?: IModelsClient;
89
+ // (undocumented)
90
+ iTwinId: string;
91
+ // (undocumented)
92
+ mappingsClient?: MappingsClient;
93
+ // (undocumented)
94
+ reportsClient?: ReportsClient;
95
+ }
96
+
97
+ // @public
98
+ export class ReportsConfigProvider implements UiItemsProvider {
99
+ constructor(getAccessToken?: () => Promise<AccessToken>, baseUrl?: string);
100
+ // (undocumented)
101
+ readonly id = "ReportsConfigProvider";
102
+ // (undocumented)
103
+ provideWidgets(_stageId: string, stageUsage: string, location: StagePanelLocation, section?: StagePanelSection): ReadonlyArray<Widget>;
104
+ }
105
+
106
+ // @public
107
+ export class ReportsConfigWidget {
108
+ // (undocumented)
109
+ static initialize(localization?: Localization): Promise<void>;
110
+ // (undocumented)
111
+ static get localization(): Localization;
112
+ // (undocumented)
113
+ static get localizationNamespace(): string;
114
+ // (undocumented)
115
+ static terminate(): void;
116
+ }
117
+
118
+ // @public
119
+ export interface ReportsProps {
120
+ // (undocumented)
121
+ onClickAddReport?: () => void;
122
+ // (undocumented)
123
+ onClickReportModify?: (report: Report) => void;
124
+ // (undocumented)
125
+ onClickReportTitle?: (report: Report) => void;
126
+ }
127
+
128
+ // (No @packageDocumentation comment for this package)
129
+
130
+ ```
@@ -0,0 +1,14 @@
1
+ sep=;
2
+ Release Tag;API Item
3
+ public;BulkExtractor
4
+ public;ReportAction: ({ report, onSaveSuccess, onClickCancel }: ReportActionProps) => JSX.Element
5
+ public;ReportActionProps
6
+ public;ReportMappings: ({ report, onClickClose, defaultIModelId }: ReportMappingsProps) => JSX.Element | null
7
+ public;ReportMappingsProps
8
+ public;Reports: ({ onClickAddReport, onClickReportModify, onClickReportTitle }: ReportsProps) => JSX.Element | null
9
+ internal;REPORTS_CONFIG_BASE_URL = "https://api.bentley.com"
10
+ public;ReportsConfigContext: (props: ReportsConfigContextProps) => JSX.Element
11
+ public;ReportsConfigContextProps
12
+ public;ReportsConfigProvider
13
+ public;ReportsConfigWidget
14
+ public;ReportsProps
@@ -0,0 +1,130 @@
1
+ ## API Report File for "@itwin/reports-config-widget-react"
2
+
3
+ > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
4
+
5
+ ```ts
6
+
7
+ /// <reference types="react" />
8
+
9
+ import type { AccessToken } from '@itwin/core-bentley';
10
+ import { ExtractionClient } from '@itwin/insights-client';
11
+ import type { ExtractionRequestDetails } from '@itwin/insights-client';
12
+ import { IModelsClient } from '@itwin/imodels-client-management';
13
+ import type { Localization } from '@itwin/core-common';
14
+ import { MappingsClient } from '@itwin/insights-client';
15
+ import { default as React_2 } from 'react';
16
+ import type { Report } from '@itwin/insights-client';
17
+ import { ReportsClient } from '@itwin/insights-client';
18
+ import { StagePanelLocation } from '@itwin/appui-react';
19
+ import { StagePanelSection } from '@itwin/appui-react';
20
+ import type { UiItemsProvider } from '@itwin/appui-react';
21
+ import type { Widget } from '@itwin/appui-react';
22
+
23
+ // @public (undocumented)
24
+ export class BulkExtractor {
25
+ constructor(reportsClient: ReportsClient, extractionClient: ExtractionClient, getAccessToken: () => Promise<AccessToken>, successfulExtractionToast: (iModelName: string, odataFeedUrl: string) => void, failedExtractionToast: (iModelName: string) => void);
26
+ // (undocumented)
27
+ getIModelState(iModelId: string, iModelName: string, odataFeedUrl: string): Promise<ExtractionStates>;
28
+ // (undocumented)
29
+ getReportState(reportId: string): Promise<ExtractionStates>;
30
+ // (undocumented)
31
+ runIModelExtraction(extractionRequestDetails: ExtractionRequestDetails): Promise<void>;
32
+ // (undocumented)
33
+ runIModelExtractions(extractionRequestsDetails: ExtractionRequestDetails[]): Promise<void>;
34
+ // (undocumented)
35
+ runReportExtractions(reportIds: string[]): Promise<void>;
36
+ // (undocumented)
37
+ setHook(setJobRunning: React.Dispatch<React.SetStateAction<boolean>>, iModels: string[]): void;
38
+ }
39
+
40
+ // @public
41
+ export const ReportAction: ({ report, onSaveSuccess, onClickCancel }: ReportActionProps) => JSX.Element;
42
+
43
+ // @public
44
+ export interface ReportActionProps {
45
+ // (undocumented)
46
+ onClickCancel?: () => void;
47
+ // (undocumented)
48
+ onSaveSuccess: () => void;
49
+ // (undocumented)
50
+ report?: Report;
51
+ }
52
+
53
+ // @public
54
+ export const ReportMappings: ({ report, onClickClose, defaultIModelId }: ReportMappingsProps) => JSX.Element | null;
55
+
56
+ // @public
57
+ export interface ReportMappingsProps {
58
+ // (undocumented)
59
+ defaultIModelId?: string;
60
+ // (undocumented)
61
+ onClickClose: () => void;
62
+ // (undocumented)
63
+ report: Report;
64
+ }
65
+
66
+ // @public
67
+ export const Reports: ({ onClickAddReport, onClickReportModify, onClickReportTitle }: ReportsProps) => JSX.Element | null;
68
+
69
+ // @internal (undocumented)
70
+ export const REPORTS_CONFIG_BASE_URL = "https://api.bentley.com";
71
+
72
+ // @public
73
+ export const ReportsConfigContext: (props: ReportsConfigContextProps) => JSX.Element;
74
+
75
+ // @public
76
+ export interface ReportsConfigContextProps {
77
+ // (undocumented)
78
+ baseUrl?: string;
79
+ // (undocumented)
80
+ bulkExtractor?: BulkExtractor;
81
+ // (undocumented)
82
+ children?: React_2.ReactNode;
83
+ // (undocumented)
84
+ extractionClient?: ExtractionClient;
85
+ // (undocumented)
86
+ getAccessToken?: GetAccessTokenFn;
87
+ // (undocumented)
88
+ iModelsClient?: IModelsClient;
89
+ // (undocumented)
90
+ iTwinId: string;
91
+ // (undocumented)
92
+ mappingsClient?: MappingsClient;
93
+ // (undocumented)
94
+ reportsClient?: ReportsClient;
95
+ }
96
+
97
+ // @public
98
+ export class ReportsConfigProvider implements UiItemsProvider {
99
+ constructor(getAccessToken?: () => Promise<AccessToken>, baseUrl?: string);
100
+ // (undocumented)
101
+ readonly id = "ReportsConfigProvider";
102
+ // (undocumented)
103
+ provideWidgets(_stageId: string, stageUsage: string, location: StagePanelLocation, section?: StagePanelSection): ReadonlyArray<Widget>;
104
+ }
105
+
106
+ // @public
107
+ export class ReportsConfigWidget {
108
+ // (undocumented)
109
+ static initialize(localization?: Localization): Promise<void>;
110
+ // (undocumented)
111
+ static get localization(): Localization;
112
+ // (undocumented)
113
+ static get localizationNamespace(): string;
114
+ // (undocumented)
115
+ static terminate(): void;
116
+ }
117
+
118
+ // @public
119
+ export interface ReportsProps {
120
+ // (undocumented)
121
+ onClickAddReport?: () => void;
122
+ // (undocumented)
123
+ onClickReportModify?: (report: Report) => void;
124
+ // (undocumented)
125
+ onClickReportTitle?: (report: Report) => void;
126
+ }
127
+
128
+ // (No @packageDocumentation comment for this package)
129
+
130
+ ```