@itwin/reports-config-widget-react 0.2.1 → 0.4.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 (343) hide show
  1. package/.rush/temp/operation/rebuild/all.log +9 -0
  2. package/.rush/temp/operation/rebuild/state.json +3 -0
  3. package/.rush/temp/package-deps_rebuild.json +48 -44
  4. package/.rush/temp/shrinkwrap-deps.json +228 -207
  5. package/CHANGELOG.json +44 -0
  6. package/CHANGELOG.md +24 -1
  7. package/coverage/clover.xml +562 -542
  8. package/coverage/coverage-final.json +24 -20
  9. package/coverage/lcov-report/index.html +51 -51
  10. package/coverage/lcov-report/src/ReportsConfigWidget.ts.html +22 -22
  11. package/coverage/lcov-report/src/index.html +21 -21
  12. package/coverage/lcov-report/src/test/index.html +11 -11
  13. package/coverage/lcov-report/src/test/test-utils.tsx.html +20 -140
  14. package/coverage/lcov-report/src/widget/ReportsConfigUiProvider.tsx.html +14 -35
  15. package/coverage/lcov-report/src/widget/components/ActionPanel.tsx.html +26 -20
  16. package/coverage/lcov-report/src/widget/components/AddMappingsModal.tsx.html +94 -109
  17. package/coverage/lcov-report/src/widget/components/BulkExtractor.ts.html +55 -52
  18. package/coverage/lcov-report/src/widget/components/Constants.ts.html +1 -1
  19. package/coverage/lcov-report/src/widget/components/DeleteModal.tsx.html +28 -46
  20. package/coverage/lcov-report/src/widget/components/ExtractionStates/FailedExtractionState.tsx.html +1 -1
  21. package/coverage/lcov-report/src/widget/components/ExtractionStates/QueuedExtractionState.tsx.html +1 -1
  22. package/coverage/lcov-report/src/widget/components/ExtractionStates/RunningExtractionState.tsx.html +1 -1
  23. package/coverage/lcov-report/src/widget/components/ExtractionStates/StartingExtractionState.tsx.html +1 -1
  24. package/coverage/lcov-report/src/widget/components/ExtractionStates/SucceededExtractionState.tsx.html +1 -1
  25. package/coverage/lcov-report/src/widget/components/ExtractionStates/index.html +1 -1
  26. package/coverage/lcov-report/src/widget/components/ExtractionStatus.tsx.html +1 -1
  27. package/coverage/lcov-report/src/widget/components/ExtractionToast.tsx.html +1 -1
  28. package/coverage/lcov-report/src/widget/components/HorizontalTile.tsx.html +3 -3
  29. package/coverage/lcov-report/src/widget/components/LocalizedTablePaginator.tsx.html +8 -8
  30. package/coverage/lcov-report/src/widget/components/ReportAction.tsx.html +36 -81
  31. package/coverage/lcov-report/src/widget/components/ReportHorizontalTile.tsx.html +38 -41
  32. package/coverage/lcov-report/src/widget/components/ReportMappingHorizontalTile.tsx.html +46 -46
  33. package/coverage/lcov-report/src/widget/components/ReportMappings.tsx.html +127 -142
  34. package/coverage/lcov-report/src/widget/components/Reports.tsx.html +189 -312
  35. package/coverage/lcov-report/src/widget/components/ReportsConfigContext.tsx.html +370 -0
  36. package/coverage/lcov-report/src/widget/components/ReportsContainer.tsx.html +111 -33
  37. package/coverage/lcov-report/src/widget/components/ReportsHeader.tsx.html +166 -0
  38. package/coverage/lcov-report/src/widget/components/ReportsRouter.tsx.html +274 -0
  39. package/coverage/lcov-report/src/widget/components/SearchBar.tsx.html +22 -7
  40. package/coverage/lcov-report/src/widget/components/SelectIModel.tsx.html +40 -94
  41. package/coverage/lcov-report/src/widget/components/index.html +142 -97
  42. package/coverage/lcov-report/src/widget/components/utils.tsx.html +22 -19
  43. package/coverage/lcov-report/src/widget/context/{ReportsApiConfigContext.tsx.html → BulkExtractorContext.tsx.html} +23 -26
  44. package/coverage/lcov-report/src/widget/context/ReportsConfigApiContext.tsx.html +202 -0
  45. package/coverage/lcov-report/src/widget/context/index.html +30 -15
  46. package/coverage/lcov-report/src/widget/hooks/index.html +1 -1
  47. package/coverage/lcov-report/src/widget/hooks/useValidator.ts.html +11 -11
  48. package/coverage/lcov-report/src/widget/index.html +13 -13
  49. package/coverage/lcov.info +1036 -1034
  50. package/jest.config.js +1 -0
  51. package/lib/cjs/ReportsConfigWidget.js +1 -1
  52. package/lib/cjs/ReportsConfigWidget.js.map +1 -1
  53. package/lib/cjs/reports-config-widget-react.d.ts +5 -0
  54. package/lib/cjs/reports-config-widget-react.d.ts.map +1 -1
  55. package/lib/cjs/reports-config-widget-react.js +11 -0
  56. package/lib/cjs/reports-config-widget-react.js.map +1 -1
  57. package/lib/cjs/test/AddMappingModal.test.js +20 -34
  58. package/lib/cjs/test/AddMappingModal.test.js.map +1 -1
  59. package/lib/cjs/test/BulkExtractor.test.js +13 -19
  60. package/lib/cjs/test/BulkExtractor.test.js.map +1 -1
  61. package/lib/cjs/test/DeleteModal.test.d.ts.map +1 -1
  62. package/lib/cjs/test/DeleteModal.test.js +4 -62
  63. package/lib/cjs/test/DeleteModal.test.js.map +1 -1
  64. package/lib/cjs/test/ReportAction.test.js +14 -79
  65. package/lib/cjs/test/ReportAction.test.js.map +1 -1
  66. package/lib/cjs/test/ReportMappingHorizontalTile.test.js +20 -54
  67. package/lib/cjs/test/ReportMappingHorizontalTile.test.js.map +1 -1
  68. package/lib/cjs/test/ReportMappings.test.d.ts.map +1 -1
  69. package/lib/cjs/test/ReportMappings.test.js +51 -106
  70. package/lib/cjs/test/ReportMappings.test.js.map +1 -1
  71. package/lib/cjs/test/Reports.test.js +41 -96
  72. package/lib/cjs/test/Reports.test.js.map +1 -1
  73. package/lib/cjs/test/WidgetHeader.test.js +9 -3
  74. package/lib/cjs/test/WidgetHeader.test.js.map +1 -1
  75. package/lib/cjs/test/test-utils.d.ts +3 -8
  76. package/lib/cjs/test/test-utils.d.ts.map +1 -1
  77. package/lib/cjs/test/test-utils.js +6 -34
  78. package/lib/cjs/test/test-utils.js.map +1 -1
  79. package/lib/cjs/tsconfig.tsbuildinfo +1 -1
  80. package/lib/cjs/widget/ReportsConfigUiProvider.d.ts +3 -3
  81. package/lib/cjs/widget/ReportsConfigUiProvider.d.ts.map +1 -1
  82. package/lib/cjs/widget/ReportsConfigUiProvider.js +5 -7
  83. package/lib/cjs/widget/ReportsConfigUiProvider.js.map +1 -1
  84. package/lib/cjs/widget/components/ActionPanel.d.ts +3 -3
  85. package/lib/cjs/widget/components/ActionPanel.d.ts.map +1 -1
  86. package/lib/cjs/widget/components/ActionPanel.js +4 -4
  87. package/lib/cjs/widget/components/ActionPanel.js.map +1 -1
  88. package/lib/cjs/widget/components/ActionPanel.scss +2 -3
  89. package/lib/cjs/widget/components/AddMappingsModal.d.ts +4 -4
  90. package/lib/cjs/widget/components/AddMappingsModal.d.ts.map +1 -1
  91. package/lib/cjs/widget/components/AddMappingsModal.js +39 -43
  92. package/lib/cjs/widget/components/AddMappingsModal.js.map +1 -1
  93. package/lib/cjs/widget/components/AddMappingsModal.scss +1 -2
  94. package/lib/cjs/widget/components/BulkExtractor.d.ts +4 -4
  95. package/lib/cjs/widget/components/BulkExtractor.d.ts.map +1 -1
  96. package/lib/cjs/widget/components/BulkExtractor.js +8 -8
  97. package/lib/cjs/widget/components/BulkExtractor.js.map +1 -1
  98. package/lib/cjs/widget/components/DeleteModal.d.ts +4 -5
  99. package/lib/cjs/widget/components/DeleteModal.d.ts.map +1 -1
  100. package/lib/cjs/widget/components/DeleteModal.js +11 -15
  101. package/lib/cjs/widget/components/DeleteModal.js.map +1 -1
  102. package/lib/cjs/widget/components/DeleteModal.scss +2 -3
  103. package/lib/cjs/widget/components/ExtractionStatus.js +2 -2
  104. package/lib/cjs/widget/components/ExtractionStatus.js.map +1 -1
  105. package/lib/cjs/widget/components/ExtractionStatus.scss +6 -7
  106. package/lib/cjs/widget/components/HorizontalTile.js +2 -2
  107. package/lib/cjs/widget/components/HorizontalTile.js.map +1 -1
  108. package/lib/cjs/widget/components/HorizontalTile.scss +11 -14
  109. package/lib/cjs/widget/components/LocalizedTablePaginator.js +2 -2
  110. package/lib/cjs/widget/components/LocalizedTablePaginator.js.map +1 -1
  111. package/lib/cjs/widget/components/ReportAction.d.ts +4 -5
  112. package/lib/cjs/widget/components/ReportAction.d.ts.map +1 -1
  113. package/lib/cjs/widget/components/ReportAction.js +24 -26
  114. package/lib/cjs/widget/components/ReportAction.js.map +1 -1
  115. package/lib/cjs/widget/components/ReportAction.scss +1 -2
  116. package/lib/cjs/widget/components/ReportHorizontalTile.d.ts +4 -4
  117. package/lib/cjs/widget/components/ReportHorizontalTile.d.ts.map +1 -1
  118. package/lib/cjs/widget/components/ReportHorizontalTile.js +33 -20
  119. package/lib/cjs/widget/components/ReportHorizontalTile.js.map +1 -1
  120. package/lib/cjs/widget/components/ReportMappingHorizontalTile.d.ts +1 -1
  121. package/lib/cjs/widget/components/ReportMappingHorizontalTile.d.ts.map +1 -1
  122. package/lib/cjs/widget/components/ReportMappingHorizontalTile.js +36 -21
  123. package/lib/cjs/widget/components/ReportMappingHorizontalTile.js.map +1 -1
  124. package/lib/cjs/widget/components/ReportMappings.d.ts +4 -6
  125. package/lib/cjs/widget/components/ReportMappings.d.ts.map +1 -1
  126. package/lib/cjs/widget/components/ReportMappings.js +50 -63
  127. package/lib/cjs/widget/components/ReportMappings.js.map +1 -1
  128. package/lib/cjs/widget/components/ReportMappings.scss +10 -11
  129. package/lib/cjs/widget/components/Reports.d.ts +6 -1
  130. package/lib/cjs/widget/components/Reports.d.ts.map +1 -1
  131. package/lib/cjs/widget/components/Reports.js +53 -94
  132. package/lib/cjs/widget/components/Reports.js.map +1 -1
  133. package/lib/cjs/widget/components/Reports.scss +15 -15
  134. package/lib/cjs/widget/components/ReportsConfigContext.d.ts +18 -0
  135. package/lib/cjs/widget/components/ReportsConfigContext.d.ts.map +1 -0
  136. package/lib/cjs/widget/components/ReportsConfigContext.js +79 -0
  137. package/lib/cjs/widget/components/ReportsConfigContext.js.map +1 -0
  138. package/lib/cjs/widget/components/ReportsContainer.d.ts +14 -0
  139. package/lib/cjs/widget/components/ReportsContainer.d.ts.map +1 -1
  140. package/lib/cjs/widget/components/ReportsContainer.js +27 -16
  141. package/lib/cjs/widget/components/ReportsContainer.js.map +1 -1
  142. package/lib/cjs/widget/components/ReportsContainer.scss +1 -3
  143. package/lib/cjs/widget/components/ReportsHeader.d.ts +7 -0
  144. package/lib/cjs/widget/components/ReportsHeader.d.ts.map +1 -0
  145. package/lib/cjs/widget/components/ReportsHeader.js +20 -0
  146. package/lib/cjs/widget/components/ReportsHeader.js.map +1 -0
  147. package/lib/cjs/widget/components/ReportsRouter.d.ts +8 -0
  148. package/lib/cjs/widget/components/ReportsRouter.d.ts.map +1 -0
  149. package/lib/cjs/widget/components/ReportsRouter.js +51 -0
  150. package/lib/cjs/widget/components/ReportsRouter.js.map +1 -0
  151. package/lib/cjs/widget/components/SearchBar.d.ts.map +1 -1
  152. package/lib/cjs/widget/components/SearchBar.js +4 -5
  153. package/lib/cjs/widget/components/SearchBar.js.map +1 -1
  154. package/lib/cjs/widget/components/SearchBar.scss +1 -2
  155. package/lib/cjs/widget/components/SelectIModel.d.ts +3 -3
  156. package/lib/cjs/widget/components/SelectIModel.d.ts.map +1 -1
  157. package/lib/cjs/widget/components/SelectIModel.js +10 -30
  158. package/lib/cjs/widget/components/SelectIModel.js.map +1 -1
  159. package/lib/cjs/widget/components/SelectIModel.scss +2 -3
  160. package/lib/cjs/widget/components/utils.d.ts +1 -1
  161. package/lib/cjs/widget/components/utils.d.ts.map +1 -1
  162. package/lib/cjs/widget/components/utils.js +1 -1
  163. package/lib/cjs/widget/components/utils.js.map +1 -1
  164. package/lib/cjs/widget/components/utils.scss +16 -8
  165. package/lib/cjs/widget/context/BulkExtractorContext.d.ts +10 -0
  166. package/lib/cjs/widget/context/BulkExtractorContext.d.ts.map +1 -0
  167. package/lib/cjs/widget/context/{ReportsApiConfigContext.js → BulkExtractorContext.js} +7 -10
  168. package/lib/cjs/widget/context/BulkExtractorContext.js.map +1 -0
  169. package/lib/cjs/widget/context/ReportsConfigApiContext.d.ts +16 -0
  170. package/lib/cjs/widget/context/ReportsConfigApiContext.d.ts.map +1 -0
  171. package/lib/cjs/widget/context/ReportsConfigApiContext.js +43 -0
  172. package/lib/cjs/widget/context/ReportsConfigApiContext.js.map +1 -0
  173. package/lib/cjs/widget/hooks/useValidator.js +1 -1
  174. package/lib/cjs/widget/hooks/useValidator.js.map +1 -1
  175. package/lib/esm/ReportsConfigWidget.js +1 -1
  176. package/lib/esm/ReportsConfigWidget.js.map +1 -1
  177. package/lib/esm/reports-config-widget-react.d.ts +5 -0
  178. package/lib/esm/reports-config-widget-react.d.ts.map +1 -1
  179. package/lib/esm/reports-config-widget-react.js +5 -0
  180. package/lib/esm/reports-config-widget-react.js.map +1 -1
  181. package/lib/esm/test/AddMappingModal.test.js +17 -31
  182. package/lib/esm/test/AddMappingModal.test.js.map +1 -1
  183. package/lib/esm/test/BulkExtractor.test.js +14 -17
  184. package/lib/esm/test/BulkExtractor.test.js.map +1 -1
  185. package/lib/esm/test/DeleteModal.test.d.ts.map +1 -1
  186. package/lib/esm/test/DeleteModal.test.js +5 -44
  187. package/lib/esm/test/DeleteModal.test.js.map +1 -1
  188. package/lib/esm/test/ReportAction.test.js +14 -60
  189. package/lib/esm/test/ReportAction.test.js.map +1 -1
  190. package/lib/esm/test/ReportMappingHorizontalTile.test.js +4 -38
  191. package/lib/esm/test/ReportMappingHorizontalTile.test.js.map +1 -1
  192. package/lib/esm/test/ReportMappings.test.d.ts.map +1 -1
  193. package/lib/esm/test/ReportMappings.test.js +43 -98
  194. package/lib/esm/test/ReportMappings.test.js.map +1 -1
  195. package/lib/esm/test/Reports.test.js +24 -60
  196. package/lib/esm/test/Reports.test.js.map +1 -1
  197. package/lib/esm/test/WidgetHeader.test.js +8 -2
  198. package/lib/esm/test/WidgetHeader.test.js.map +1 -1
  199. package/lib/esm/test/test-utils.d.ts +3 -8
  200. package/lib/esm/test/test-utils.d.ts.map +1 -1
  201. package/lib/esm/test/test-utils.js +4 -31
  202. package/lib/esm/test/test-utils.js.map +1 -1
  203. package/lib/esm/tsconfig.tsbuildinfo +1 -1
  204. package/lib/esm/widget/ReportsConfigUiProvider.d.ts +3 -3
  205. package/lib/esm/widget/ReportsConfigUiProvider.d.ts.map +1 -1
  206. package/lib/esm/widget/ReportsConfigUiProvider.js +2 -4
  207. package/lib/esm/widget/ReportsConfigUiProvider.js.map +1 -1
  208. package/lib/esm/widget/components/ActionPanel.d.ts +3 -3
  209. package/lib/esm/widget/components/ActionPanel.d.ts.map +1 -1
  210. package/lib/esm/widget/components/ActionPanel.js +4 -4
  211. package/lib/esm/widget/components/ActionPanel.js.map +1 -1
  212. package/lib/esm/widget/components/ActionPanel.scss +2 -3
  213. package/lib/esm/widget/components/AddMappingsModal.d.ts +4 -4
  214. package/lib/esm/widget/components/AddMappingsModal.d.ts.map +1 -1
  215. package/lib/esm/widget/components/AddMappingsModal.js +35 -39
  216. package/lib/esm/widget/components/AddMappingsModal.js.map +1 -1
  217. package/lib/esm/widget/components/AddMappingsModal.scss +1 -2
  218. package/lib/esm/widget/components/BulkExtractor.d.ts +4 -4
  219. package/lib/esm/widget/components/BulkExtractor.d.ts.map +1 -1
  220. package/lib/esm/widget/components/BulkExtractor.js +7 -8
  221. package/lib/esm/widget/components/BulkExtractor.js.map +1 -1
  222. package/lib/esm/widget/components/DeleteModal.d.ts +4 -5
  223. package/lib/esm/widget/components/DeleteModal.d.ts.map +1 -1
  224. package/lib/esm/widget/components/DeleteModal.js +11 -15
  225. package/lib/esm/widget/components/DeleteModal.js.map +1 -1
  226. package/lib/esm/widget/components/DeleteModal.scss +2 -3
  227. package/lib/esm/widget/components/ExtractionStatus.scss +6 -7
  228. package/lib/esm/widget/components/HorizontalTile.scss +11 -14
  229. package/lib/esm/widget/components/ReportAction.d.ts +4 -5
  230. package/lib/esm/widget/components/ReportAction.d.ts.map +1 -1
  231. package/lib/esm/widget/components/ReportAction.js +17 -21
  232. package/lib/esm/widget/components/ReportAction.js.map +1 -1
  233. package/lib/esm/widget/components/ReportAction.scss +1 -2
  234. package/lib/esm/widget/components/ReportHorizontalTile.d.ts +4 -4
  235. package/lib/esm/widget/components/ReportHorizontalTile.d.ts.map +1 -1
  236. package/lib/esm/widget/components/ReportHorizontalTile.js +6 -9
  237. package/lib/esm/widget/components/ReportHorizontalTile.js.map +1 -1
  238. package/lib/esm/widget/components/ReportMappingHorizontalTile.d.ts +1 -1
  239. package/lib/esm/widget/components/ReportMappingHorizontalTile.d.ts.map +1 -1
  240. package/lib/esm/widget/components/ReportMappingHorizontalTile.js +12 -13
  241. package/lib/esm/widget/components/ReportMappingHorizontalTile.js.map +1 -1
  242. package/lib/esm/widget/components/ReportMappings.d.ts +4 -6
  243. package/lib/esm/widget/components/ReportMappings.d.ts.map +1 -1
  244. package/lib/esm/widget/components/ReportMappings.js +43 -56
  245. package/lib/esm/widget/components/ReportMappings.js.map +1 -1
  246. package/lib/esm/widget/components/ReportMappings.scss +10 -11
  247. package/lib/esm/widget/components/Reports.d.ts +6 -1
  248. package/lib/esm/widget/components/Reports.d.ts.map +1 -1
  249. package/lib/esm/widget/components/Reports.js +46 -87
  250. package/lib/esm/widget/components/Reports.js.map +1 -1
  251. package/lib/esm/widget/components/Reports.scss +15 -15
  252. package/lib/esm/widget/components/ReportsConfigContext.d.ts +18 -0
  253. package/lib/esm/widget/components/ReportsConfigContext.d.ts.map +1 -0
  254. package/lib/esm/widget/components/ReportsConfigContext.js +56 -0
  255. package/lib/esm/widget/components/ReportsConfigContext.js.map +1 -0
  256. package/lib/esm/widget/components/ReportsContainer.d.ts +14 -0
  257. package/lib/esm/widget/components/ReportsContainer.d.ts.map +1 -1
  258. package/lib/esm/widget/components/ReportsContainer.js +27 -17
  259. package/lib/esm/widget/components/ReportsContainer.js.map +1 -1
  260. package/lib/esm/widget/components/ReportsContainer.scss +1 -3
  261. package/lib/esm/widget/components/ReportsHeader.d.ts +7 -0
  262. package/lib/esm/widget/components/ReportsHeader.d.ts.map +1 -0
  263. package/lib/esm/widget/components/ReportsHeader.js +13 -0
  264. package/lib/esm/widget/components/ReportsHeader.js.map +1 -0
  265. package/lib/esm/widget/components/ReportsRouter.d.ts +8 -0
  266. package/lib/esm/widget/components/ReportsRouter.d.ts.map +1 -0
  267. package/lib/esm/widget/components/ReportsRouter.js +44 -0
  268. package/lib/esm/widget/components/ReportsRouter.js.map +1 -0
  269. package/lib/esm/widget/components/SearchBar.d.ts.map +1 -1
  270. package/lib/esm/widget/components/SearchBar.js +2 -3
  271. package/lib/esm/widget/components/SearchBar.js.map +1 -1
  272. package/lib/esm/widget/components/SearchBar.scss +1 -2
  273. package/lib/esm/widget/components/SelectIModel.d.ts +3 -3
  274. package/lib/esm/widget/components/SelectIModel.d.ts.map +1 -1
  275. package/lib/esm/widget/components/SelectIModel.js +7 -27
  276. package/lib/esm/widget/components/SelectIModel.js.map +1 -1
  277. package/lib/esm/widget/components/SelectIModel.scss +2 -3
  278. package/lib/esm/widget/components/utils.d.ts +1 -1
  279. package/lib/esm/widget/components/utils.d.ts.map +1 -1
  280. package/lib/esm/widget/components/utils.js +2 -2
  281. package/lib/esm/widget/components/utils.js.map +1 -1
  282. package/lib/esm/widget/components/utils.scss +16 -8
  283. package/lib/esm/widget/context/BulkExtractorContext.d.ts +10 -0
  284. package/lib/esm/widget/context/BulkExtractorContext.d.ts.map +1 -0
  285. package/lib/esm/widget/context/BulkExtractorContext.js +11 -0
  286. package/lib/esm/widget/context/BulkExtractorContext.js.map +1 -0
  287. package/lib/esm/widget/context/ReportsConfigApiContext.d.ts +16 -0
  288. package/lib/esm/widget/context/ReportsConfigApiContext.d.ts.map +1 -0
  289. package/lib/esm/widget/context/ReportsConfigApiContext.js +20 -0
  290. package/lib/esm/widget/context/ReportsConfigApiContext.js.map +1 -0
  291. package/lib/public/locales/en/ReportsConfigWidget.json +6 -1
  292. package/package.json +29 -29
  293. package/public/locales/en/ReportsConfigWidget.json +6 -1
  294. package/reports-config-widget-react.build.error.log +6 -6
  295. package/reports-config-widget-react.build.log +52 -49
  296. package/src/reports-config-widget-react.ts +6 -0
  297. package/src/test/AddMappingModal.test.tsx +20 -37
  298. package/src/test/BulkExtractor.test.ts +15 -17
  299. package/src/test/DeleteModal.test.tsx +4 -73
  300. package/src/test/ReportAction.test.tsx +17 -90
  301. package/src/test/ReportMappingHorizontalTile.test.tsx +3 -54
  302. package/src/test/ReportMappings.test.tsx +50 -135
  303. package/src/test/Reports.test.tsx +21 -80
  304. package/src/test/WidgetHeader.test.tsx +9 -2
  305. package/src/test/test-utils.tsx +9 -49
  306. package/src/widget/ReportsConfigUiProvider.tsx +7 -14
  307. package/src/widget/components/ActionPanel.scss +2 -3
  308. package/src/widget/components/ActionPanel.tsx +17 -15
  309. package/src/widget/components/AddMappingsModal.scss +1 -2
  310. package/src/widget/components/AddMappingsModal.tsx +55 -60
  311. package/src/widget/components/BulkExtractor.ts +11 -10
  312. package/src/widget/components/DeleteModal.scss +2 -3
  313. package/src/widget/components/DeleteModal.tsx +17 -23
  314. package/src/widget/components/ExtractionStatus.scss +6 -7
  315. package/src/widget/components/HorizontalTile.scss +11 -14
  316. package/src/widget/components/ReportAction.scss +1 -2
  317. package/src/widget/components/ReportAction.tsx +18 -33
  318. package/src/widget/components/ReportHorizontalTile.tsx +11 -12
  319. package/src/widget/components/ReportMappingHorizontalTile.tsx +30 -30
  320. package/src/widget/components/ReportMappings.scss +10 -11
  321. package/src/widget/components/ReportMappings.tsx +67 -72
  322. package/src/widget/components/Reports.scss +15 -15
  323. package/src/widget/components/Reports.tsx +140 -181
  324. package/src/widget/components/ReportsConfigContext.tsx +95 -0
  325. package/src/widget/components/ReportsContainer.scss +1 -3
  326. package/src/widget/components/ReportsContainer.tsx +47 -21
  327. package/src/widget/components/ReportsHeader.tsx +27 -0
  328. package/src/widget/components/ReportsRouter.tsx +63 -0
  329. package/src/widget/components/SearchBar.scss +1 -2
  330. package/src/widget/components/SearchBar.tsx +7 -2
  331. package/src/widget/components/SelectIModel.scss +2 -3
  332. package/src/widget/components/SelectIModel.tsx +11 -29
  333. package/src/widget/components/utils.scss +16 -8
  334. package/src/widget/components/utils.tsx +8 -7
  335. package/src/widget/context/{ReportsApiConfigContext.tsx → BulkExtractorContext.tsx} +9 -10
  336. package/src/widget/context/ReportsConfigApiContext.tsx +39 -0
  337. package/lib/cjs/widget/context/ReportsApiConfigContext.d.ts +0 -9
  338. package/lib/cjs/widget/context/ReportsApiConfigContext.d.ts.map +0 -1
  339. package/lib/cjs/widget/context/ReportsApiConfigContext.js.map +0 -1
  340. package/lib/esm/widget/context/ReportsApiConfigContext.d.ts +0 -9
  341. package/lib/esm/widget/context/ReportsApiConfigContext.d.ts.map +0 -1
  342. package/lib/esm/widget/context/ReportsApiConfigContext.js +0 -14
  343. package/lib/esm/widget/context/ReportsApiConfigContext.js.map +0 -1
@@ -3,14 +3,14 @@
3
3
  * See LICENSE.md in the project root for license terms and full copyright notice.
4
4
  *--------------------------------------------------------------------------------------------*/
5
5
  import type {
6
- AbstractWidgetProps,
7
6
  UiItemsProvider,
8
- } from "@itwin/appui-abstract";
7
+ Widget,
8
+ } from "@itwin/appui-react";
9
9
  import {
10
10
  StagePanelLocation,
11
11
  StagePanelSection,
12
12
  StageUsage,
13
- } from "@itwin/appui-abstract";
13
+ } from "@itwin/appui-react";
14
14
  import type { AccessToken } from "@itwin/core-bentley";
15
15
 
16
16
  import * as React from "react";
@@ -37,26 +37,19 @@ export class ReportsConfigProvider implements UiItemsProvider {
37
37
  stageUsage: string,
38
38
  location: StagePanelLocation,
39
39
  section?: StagePanelSection
40
- ): ReadonlyArray<AbstractWidgetProps> {
41
- const widgets: AbstractWidgetProps[] = [];
40
+ ): ReadonlyArray<Widget> {
41
+ const widgets: Widget[] = [];
42
42
  if (
43
43
  location === StagePanelLocation.Left &&
44
44
  section === StagePanelSection.Start &&
45
45
  stageUsage === StageUsage.General
46
46
  ) {
47
- const ReportsWidget: AbstractWidgetProps = {
47
+ const ReportsWidget: Widget = {
48
48
  id: "reports-config-widget",
49
49
  label: ReportsConfigWidget.localization.getLocalizedString(
50
50
  "ReportsConfigWidget:ReportsConfig"
51
51
  ),
52
- getWidgetContent: () => {
53
- return (
54
- <ReportsContainer
55
- getAccessToken={this._getAccessToken}
56
- baseUrl={this._baseUrl}
57
- />
58
- );
59
- },
52
+ content: <ReportsContainer getAccessToken={this._getAccessToken} baseUrl={this._baseUrl} />,
60
53
  };
61
54
 
62
55
  widgets.push(ReportsWidget);
@@ -2,11 +2,10 @@
2
2
  * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
3
  * See LICENSE.md in the project root for license terms and full copyright notice.
4
4
  *--------------------------------------------------------------------------------------------*/
5
- @import "~@itwin/itwinui-css/scss/variables";
6
5
 
7
6
  .rcw-action-panel {
8
7
  display: flex;
9
8
  justify-content: right;
10
- padding: $iui-baseline * 2 $iui-m $iui-baseline;
11
- gap: $iui-s;
9
+ padding: calc(var(--iui-size-s) * 2) var(--iui-size-m) var(--iui-size-s);
10
+ gap: var(--iui-size-xs);
12
11
  }
@@ -1,7 +1,7 @@
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
- *--------------------------------------------------------------------------------------------*/
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
5
  import { Button } from "@itwin/itwinui-react";
6
6
  import * as React from "react";
7
7
  import { ReportsConfigWidget } from "../../ReportsConfigWidget";
@@ -11,7 +11,7 @@ import { LoadingSpinner } from "./utils";
11
11
  export interface ActionPanelProps {
12
12
  actionLabel: string;
13
13
  onAction: () => Promise<void>;
14
- onCancel: () => void;
14
+ onCancel?: () => void;
15
15
  isCancelDisabled?: boolean;
16
16
  isSavingDisabled?: boolean;
17
17
  isLoading?: boolean;
@@ -24,7 +24,7 @@ const ActionPanel = ({
24
24
  isCancelDisabled = false,
25
25
  isSavingDisabled = false,
26
26
  isLoading = false,
27
- }: ActionPanelProps): JSX.Element => {
27
+ }: ActionPanelProps): React.ReactElement => {
28
28
  return (
29
29
  <div className="rcw-action-panel">
30
30
  {isLoading && <LoadingSpinner />}
@@ -35,16 +35,18 @@ const ActionPanel = ({
35
35
  >
36
36
  {actionLabel}
37
37
  </Button>
38
- <Button
39
- styleType="default"
40
- type="button"
41
- onClick={onCancel}
42
- disabled={isCancelDisabled || isLoading}
43
- >
44
- {ReportsConfigWidget.localization.getLocalizedString(
45
- "ReportsConfigWidget:Cancel"
46
- )}
47
- </Button>
38
+ {onCancel && (
39
+ <Button
40
+ styleType="default"
41
+ type="button"
42
+ onClick={onCancel}
43
+ disabled={isCancelDisabled || isLoading}
44
+ >
45
+ {ReportsConfigWidget.localization.getLocalizedString(
46
+ "ReportsConfigWidget:Cancel"
47
+ )}
48
+ </Button>
49
+ )}
48
50
  </div>
49
51
  );
50
52
  };
@@ -2,12 +2,11 @@
2
2
  * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
3
  * See LICENSE.md in the project root for license terms and full copyright notice.
4
4
  *--------------------------------------------------------------------------------------------*/
5
- @import "~@itwin/itwinui-css/scss/variables";
6
5
 
7
6
  .rcw-add-mappings-container {
8
7
  display: flex;
9
8
  flex-direction: column;
10
- gap: $iui-baseline;
9
+ gap: var(--iui-size-s);
11
10
  width: 45vw;
12
11
  min-width: 100%;
13
12
  overflow: auto;
@@ -3,35 +3,33 @@
3
3
  * See LICENSE.md in the project root for license terms and full copyright notice.
4
4
  *--------------------------------------------------------------------------------------------*/
5
5
  import { Modal, Table, tableFilters } from "@itwin/itwinui-react";
6
- import React, { useEffect, useMemo, useState } from "react";
7
- import type { Mapping } from "@itwin/insights-client";
8
- import { MappingsClient, REPORTING_BASE_PATH, ReportsClient } from "@itwin/insights-client";
6
+ import React, { useCallback, useEffect, useMemo, useRef, useState } from "react";
7
+ import type { Mapping, MappingsClient } from "@itwin/insights-client";
9
8
  import ActionPanel from "./ActionPanel";
10
9
  import "./AddMappingsModal.scss";
11
10
  import { LocalizedTablePaginator } from "./LocalizedTablePaginator";
12
11
  import type { ReportMappingAndMapping } from "./ReportMappings";
13
- import type { ReportsApiConfig } from "../context/ReportsApiConfigContext";
14
- import { useReportsApiConfig } from "../context/ReportsApiConfigContext";
12
+ import { useReportsConfigApi } from "../context/ReportsConfigApiContext";
15
13
  import { SelectIModel } from "./SelectIModel";
16
14
  import type { CreateTypeFromInterface } from "./utils";
17
- import { generateUrl, handleError } from "./utils";
15
+ import { handleError } from "./utils";
18
16
  import { ReportsConfigWidget } from "../../ReportsConfigWidget";
17
+ import type { AccessToken } from "@itwin/core-bentley";
18
+ import type { Column } from "react-table";
19
19
 
20
20
  export type MappingType = CreateTypeFromInterface<Mapping>;
21
21
 
22
22
  const fetchMappings = async (
23
- setMappings: React.Dispatch<React.SetStateAction<Mapping[]>>,
23
+ setMappings: (mappings: Mapping[]) => void,
24
24
  iModelId: string,
25
- setIsLoading: React.Dispatch<React.SetStateAction<boolean>>,
26
- apiContext: ReportsApiConfig
25
+ setIsLoading: (isLoading: boolean) => void,
26
+ mappingsClient: MappingsClient,
27
+ getAccessToken: () => Promise<AccessToken>
27
28
  ) => {
28
29
  try {
29
30
  setIsLoading(true);
30
- const mappingsClientApi = new MappingsClient(
31
- generateUrl(REPORTING_BASE_PATH, apiContext.baseUrl)
32
- );
33
- const accessToken = await apiContext.getAccessToken();
34
- const mappings = await mappingsClientApi.getMappings(
31
+ const accessToken = await getAccessToken();
32
+ const mappings = await mappingsClient.getMappings(
35
33
  accessToken,
36
34
  iModelId
37
35
  );
@@ -43,24 +41,26 @@ const fetchMappings = async (
43
41
  }
44
42
  };
45
43
 
46
- interface AddMappingsModalProps {
44
+ export interface AddMappingsModalProps {
47
45
  reportId: string;
48
46
  existingMappings: ReportMappingAndMapping[];
49
47
  show: boolean;
50
- returnFn: () => Promise<void>;
48
+ onClose: () => Promise<void>;
49
+ defaultIModelId?: string;
51
50
  }
52
51
 
53
52
  export const AddMappingsModal = ({
54
53
  reportId,
55
54
  existingMappings,
56
55
  show,
57
- returnFn,
56
+ onClose,
57
+ defaultIModelId,
58
58
  }: AddMappingsModalProps) => {
59
59
  const [isLoading, setIsLoading] = useState<boolean>(false);
60
- const [selectedMappings, setSelectedMappings] = useState<Mapping[]>([]);
61
- const [selectedIModelId, setSelectediModelId] = useState<string>("");
60
+ const selectedMappings = useRef<Mapping[]>([]);
61
+ const [selectedIModelId, setSelectediModelId] = useState<string | undefined>(defaultIModelId);
62
62
  const [mappings, setMappings] = useState<Mapping[]>([]);
63
- const apiConfig = useReportsApiConfig();
63
+ const { getAccessToken, mappingsClient, reportsClient } = useReportsConfigApi();
64
64
 
65
65
  useEffect(() => {
66
66
  if (selectedIModelId) {
@@ -68,35 +68,30 @@ export const AddMappingsModal = ({
68
68
  setMappings,
69
69
  selectedIModelId,
70
70
  setIsLoading,
71
- apiConfig
71
+ mappingsClient,
72
+ getAccessToken
72
73
  );
73
74
  }
74
- }, [apiConfig, selectedIModelId, setIsLoading]);
75
+ }, [getAccessToken, mappingsClient, selectedIModelId, setIsLoading]);
75
76
 
76
77
  const mappingsColumns = useMemo(
77
- () => [
78
+ (): Column<CreateTypeFromInterface<Mapping>>[] => [
78
79
  {
79
- Header: "Table",
80
- columns: [
81
- {
82
- id: "mappingName",
83
- Header: ReportsConfigWidget.localization.getLocalizedString(
84
- "ReportsConfigWidget:MappingName"
85
- ),
86
- accessor: "mappingName",
87
- Filter: tableFilters.TextFilter(),
88
- },
89
- {
90
- id: "description",
91
- Header: ReportsConfigWidget.localization.getLocalizedString(
92
- "ReportsConfigWidget:Description"
93
- ),
94
- accessor: "description",
95
- Filter: tableFilters.TextFilter(),
96
- },
97
- ],
80
+ id: "mappingName",
81
+ Header: ReportsConfigWidget.localization.getLocalizedString(
82
+ "ReportsConfigWidget:MappingName"
83
+ ),
84
+ accessor: "mappingName",
85
+ Filter: tableFilters.TextFilter(),
98
86
  },
99
- ],
87
+ {
88
+ id: "description",
89
+ Header: ReportsConfigWidget.localization.getLocalizedString(
90
+ "ReportsConfigWidget:Description"
91
+ ),
92
+ accessor: "description",
93
+ Filter: tableFilters.TextFilter(),
94
+ }],
100
95
  []
101
96
  );
102
97
 
@@ -104,18 +99,15 @@ export const AddMappingsModal = ({
104
99
  try {
105
100
  if (!selectedIModelId) return;
106
101
  setIsLoading(true);
107
- const reportsClientApi = new ReportsClient(
108
- generateUrl(REPORTING_BASE_PATH, apiConfig.baseUrl)
109
- );
110
- const accessToken = await apiConfig.getAccessToken();
111
- for (const mapping of selectedMappings) {
112
- await reportsClientApi.createReportMapping(accessToken, reportId, {
102
+ const accessToken = await getAccessToken();
103
+ for (const mapping of selectedMappings.current) {
104
+ await reportsClient.createReportMapping(accessToken, reportId, {
113
105
  imodelId: selectedIModelId,
114
106
  mappingId: mapping.id,
115
107
  });
116
108
  }
117
109
 
118
- await returnFn();
110
+ await onClose();
119
111
  } catch (error: any) {
120
112
  handleError(error.status);
121
113
  } finally {
@@ -123,6 +115,14 @@ export const AddMappingsModal = ({
123
115
  }
124
116
  };
125
117
 
118
+ const onSelect = useCallback((selectData: Mapping[] | undefined) => {
119
+ if (selectData) selectedMappings.current = selectData;
120
+ }, []);
121
+
122
+ const tableData = useMemo(() => isLoading ? [] : mappings, [isLoading, mappings]);
123
+ const isRowDisabled = useCallback((rowData: MappingType) =>
124
+ existingMappings.some((v) => v.mappingId === rowData.id), [existingMappings]);
125
+
126
126
  return (
127
127
  <Modal
128
128
  title={ReportsConfigWidget.localization.getLocalizedString(
@@ -131,7 +131,7 @@ export const AddMappingsModal = ({
131
131
  isOpen={show}
132
132
  isDismissible={!isLoading}
133
133
  onClose={async () => {
134
- await returnFn();
134
+ await onClose();
135
135
  }}
136
136
  style={{ display: "flex", flexDirection: "column", maxHeight: "77vh" }}
137
137
  >
@@ -141,7 +141,7 @@ export const AddMappingsModal = ({
141
141
  setSelectedIModelId={setSelectediModelId}
142
142
  />
143
143
  <Table<MappingType>
144
- data={isLoading ? [] : mappings}
144
+ data={tableData}
145
145
  columns={mappingsColumns}
146
146
  className="rcw-add-mappings-table"
147
147
  emptyTableContent={ReportsConfigWidget.localization.getLocalizedString(
@@ -150,22 +150,17 @@ export const AddMappingsModal = ({
150
150
  isSortable
151
151
  isSelectable
152
152
  isLoading={isLoading}
153
- isRowDisabled={(rowData) =>
154
- existingMappings.some((v) => v.mappingId === rowData.id)
155
- }
156
- onSelect={(selectData: Mapping[] | undefined) => {
157
- selectData && setSelectedMappings(selectData);
158
- }}
153
+ isRowDisabled={isRowDisabled}
154
+ onSelect={onSelect}
159
155
  paginatorRenderer={LocalizedTablePaginator}
160
156
  />
161
157
  </div>
158
+ {/* Add button permanently enabled as a workaround to the warning stating that the table and parent component are being rendered at the same time. */}
162
159
  <ActionPanel
163
160
  actionLabel={ReportsConfigWidget.localization.getLocalizedString(
164
161
  "ReportsConfigWidget:Add"
165
162
  )}
166
163
  onAction={onSave}
167
- onCancel={returnFn}
168
- isSavingDisabled={selectedMappings.length === 0}
169
164
  isLoading={isLoading}
170
165
  />
171
166
  </Modal>
@@ -2,12 +2,12 @@
2
2
  * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
3
  * See LICENSE.md in the project root for license terms and full copyright notice.
4
4
  *--------------------------------------------------------------------------------------------*/
5
- import { ExtractionClient, ExtractorState, REPORTING_BASE_PATH, ReportsClient } from "@itwin/insights-client";
6
- import type { ReportMapping } from "@itwin/insights-client";
7
- import { generateUrl, handleError } from "./utils";
8
- import type { ReportsApiConfig } from "../context/ReportsApiConfigContext";
5
+ import { ExtractorState } from "@itwin/insights-client";
6
+ import type { ExtractionClient, ReportMapping, ReportsClient } from "@itwin/insights-client";
7
+ import { handleError } from "./utils";
9
8
  import { ExtractionStates } from "./ExtractionStatus";
10
9
  import { STATUS_CHECK_INTERVAL } from "./Constants";
10
+ import type { AccessToken } from "@itwin/core-bentley";
11
11
 
12
12
  export type ReportMappingAndMapping = ReportMapping & {
13
13
  mappingName: string;
@@ -15,7 +15,7 @@ export type ReportMappingAndMapping = ReportMapping & {
15
15
  iModelName: string;
16
16
  };
17
17
 
18
- export default class BulkExtractor {
18
+ export class BulkExtractor {
19
19
  private _reportsClientApi: ReportsClient;
20
20
  private _extractionClientApi: ExtractionClient;
21
21
  private _accessToken: () => Promise<string>;
@@ -31,14 +31,15 @@ export default class BulkExtractor {
31
31
  private _iModels: string[] = [];
32
32
 
33
33
  constructor(
34
- apiConfig: ReportsApiConfig,
34
+ reportsClient: ReportsClient,
35
+ extractionClient: ExtractionClient,
36
+ getAccessToken: () => Promise<AccessToken>,
35
37
  successfulExtractionToast: (iModelName: string, odataFeedUrl: string) => void,
36
38
  failedExtractionToast: (iModelName: string) => void,
37
39
  ) {
38
- const url = generateUrl(REPORTING_BASE_PATH, apiConfig.baseUrl);
39
- this._reportsClientApi = new ReportsClient(url);
40
- this._extractionClientApi = new ExtractionClient(url);
41
- this._accessToken = apiConfig.getAccessToken;
40
+ this._reportsClientApi = reportsClient;
41
+ this._extractionClientApi = extractionClient;
42
+ this._accessToken = getAccessToken;
42
43
  this._successfulExtractionToast = successfulExtractionToast;
43
44
  this._failedExtractionToast = failedExtractionToast;
44
45
  }
@@ -2,11 +2,10 @@
2
2
  * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
3
  * See LICENSE.md in the project root for license terms and full copyright notice.
4
4
  *--------------------------------------------------------------------------------------------*/
5
- @import "~@itwin/itwinui-css/scss/variables";
6
5
 
7
6
  .rcw-delete-modal-body-text {
8
7
  display: flex;
9
- gap: $iui-xs;
8
+ gap: var(--iui-size-2xs);
10
9
  flex-wrap: wrap;
11
10
 
12
11
  >strong {
@@ -15,5 +14,5 @@
15
14
  }
16
15
 
17
16
  .rcw-loading-delete {
18
- margin-right: $iui-s;
17
+ margin-right: var(--iui-size-xs);
19
18
  }
@@ -4,11 +4,11 @@
4
4
  *--------------------------------------------------------------------------------------------*/
5
5
  import {
6
6
  Button,
7
- Leading,
8
7
  MiddleTextTruncation,
9
8
  Modal,
10
9
  ModalButtonBar,
11
10
  ModalContent,
11
+ Text,
12
12
  } from "@itwin/itwinui-react";
13
13
  import React, { useState } from "react";
14
14
  import { ReportsConfigWidget } from "../../ReportsConfigWidget";
@@ -16,32 +16,30 @@ import "./DeleteModal.scss";
16
16
  import { handleError, LoadingSpinner } from "./utils";
17
17
 
18
18
  export interface DeleteModalProps {
19
- entityName: string;
20
- show: boolean;
21
- setShow: React.Dispatch<React.SetStateAction<boolean>>;
19
+ entityName?: string;
20
+ onClose: () => void;
22
21
  onDelete: () => Promise<void>;
23
22
  refresh: () => Promise<void>;
24
23
  }
25
24
 
26
25
  export const DeleteModal = ({
27
26
  entityName,
28
- show,
29
- setShow,
27
+ onClose,
30
28
  onDelete,
31
29
  refresh,
32
30
  }: DeleteModalProps) => {
33
- const [isLoading, setIsLoading] = useState<boolean>(false);
31
+ const [isDeleting, setIsDeleting] = useState<boolean>(false);
34
32
 
35
33
  const deleteCallback = async () => {
36
34
  try {
37
- setIsLoading(true);
35
+ setIsDeleting(true);
38
36
  await onDelete();
39
- setShow(false);
40
37
  await refresh();
38
+ onClose();
41
39
  } catch (error: any) {
42
40
  handleError(error.status);
43
41
  } finally {
44
- setIsLoading(false);
42
+ setIsDeleting(false);
45
43
  }
46
44
  };
47
45
 
@@ -50,24 +48,22 @@ export const DeleteModal = ({
50
48
  title={ReportsConfigWidget.localization.getLocalizedString(
51
49
  "ReportsConfigWidget:Confirm"
52
50
  )}
53
- isOpen={show}
54
- isDismissible={!isLoading}
55
- onClose={() => {
56
- setShow(false);
57
- }}
51
+ isOpen={!!entityName}
52
+ isDismissible={!isDeleting}
53
+ onClose={onClose}
58
54
  >
59
55
  <ModalContent>
60
56
  <div className="rcw-delete-modal-body-text">
61
- <Leading>
57
+ <Text variant='leading'>
62
58
  {ReportsConfigWidget.localization.getLocalizedString(
63
59
  "ReportsConfigWidget:AreYouSureYouWantToDelete"
64
60
  )}
65
- </Leading>
61
+ </Text>
66
62
  <strong>{<MiddleTextTruncation text={`${entityName}?`} />}</strong>
67
63
  </div>
68
64
  </ModalContent>
69
65
  <ModalButtonBar>
70
- {isLoading && (
66
+ {isDeleting && (
71
67
  <div className="rcw-loading-delete" data-testid="rcw-loading-delete">
72
68
  <LoadingSpinner />
73
69
  </div>
@@ -75,7 +71,7 @@ export const DeleteModal = ({
75
71
  <Button
76
72
  styleType="high-visibility"
77
73
  onClick={deleteCallback}
78
- disabled={isLoading}
74
+ disabled={isDeleting}
79
75
  >
80
76
  {ReportsConfigWidget.localization.getLocalizedString(
81
77
  "ReportsConfigWidget:Delete"
@@ -83,10 +79,8 @@ export const DeleteModal = ({
83
79
  </Button>
84
80
  <Button
85
81
  styleType="default"
86
- onClick={() => {
87
- setShow(false);
88
- }}
89
- disabled={isLoading}
82
+ onClick={onClose}
83
+ disabled={isDeleting}
90
84
  >
91
85
  {ReportsConfigWidget.localization.getLocalizedString(
92
86
  "ReportsConfigWidget:Cancel"
@@ -2,7 +2,6 @@
2
2
  * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
3
  * See LICENSE.md in the project root for license terms and full copyright notice.
4
4
  *--------------------------------------------------------------------------------------------*/
5
- @import "~@itwin/itwinui-css/scss/variables";
6
5
 
7
6
  .rcw-extraction-status {
8
7
  align-items: center;
@@ -10,10 +9,10 @@
10
9
  display: flex;
11
10
 
12
11
  .rcw-status-icon {
13
- width: $iui-icons-default;
14
- height: $iui-icons-default;
12
+ width: var(--iui-size-m);
13
+ height: var(--iui-size-m);
15
14
  align-items: center;
16
- margin: auto $iui-xs * 3;
15
+ margin: auto calc(var(--iui-size-2xs) * 3);
17
16
  display: flex;
18
17
  }
19
18
  }
@@ -22,11 +21,11 @@
22
21
  align-items: center;
23
22
  height: 38px;
24
23
  display: flex;
25
- margin: auto $iui-xs * 3;
24
+ margin: auto calc(var(--iui-size-2xs) * 3);
26
25
 
27
26
  .rcw-status-icon {
28
- width: $iui-icons-default;
29
- height: $iui-icons-default;
27
+ width: var(--iui-size-m);
28
+ height: var(--iui-size-m);
30
29
  }
31
30
  }
32
31
 
@@ -2,17 +2,14 @@
2
2
  * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
3
  * See LICENSE.md in the project root for license terms and full copyright notice.
4
4
  *--------------------------------------------------------------------------------------------*/
5
- @import "~@itwin/itwinui-css/scss/variables";
6
- @import "~@itwin/itwinui-css/scss/icon/index";
7
-
8
5
  .rcw-horizontal-tile {
9
6
  &-container {
10
7
  display: flex;
11
8
  justify-content: space-between;
12
9
  border-radius: 5px;
13
- background-color: var(--iui-color-background-2);
14
- height: $iui-baseline * 4;
15
- padding: 5.5px $iui-s;
10
+ background-color: var(--iui-color-background-backdrop);
11
+ min-height: calc(var(--iui-size-s) * 5);
12
+ padding: 5.5px var(--iui-size-xs);
16
13
 
17
14
  .rcw-body-container {
18
15
  display: flex;
@@ -37,16 +34,16 @@
37
34
  align-self: center;
38
35
  min-width: 36px;
39
36
  flex-shrink: 0;
40
- display: flex;
37
+ margin-right: var(--iui-size-2xs);
41
38
  }
42
39
  }
43
40
 
44
41
  &-selected {
45
- @include themed {
46
- border: 1px solid t(iui-color-foreground-primary);
47
- background: linear-gradient(rgba(t(iui-color-foreground-primary-rgb), t(iui-opacity-6)),
48
- rgba(t(iui-color-foreground-primary-rgb), t(iui-opacity-6))),
49
- linear-gradient(t(iui-color-background-1), t(iui-color-background-1));
50
- }
42
+ border: 1px solid var(--iui-color-border-accent);
43
+ background: linear-gradient(
44
+ rgba(var(--iui-color-accent-hsl), var(--iui-opacity-6)),
45
+ rgba(var(--iui-color-accent-hsl), var(--iui-opacity-6))
46
+ ),
47
+ linear-gradient(var(--iui-color-background), var(--iui-color-background));
51
48
  }
52
- }
49
+ }
@@ -2,7 +2,6 @@
2
2
  * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
3
  * See LICENSE.md in the project root for license terms and full copyright notice.
4
4
  *--------------------------------------------------------------------------------------------*/
5
- @import "~@itwin/itwinui-css/scss/variables";
6
5
 
7
6
  .rcw-details-form-container {
8
7
  overflow-x: auto;
@@ -11,6 +10,6 @@
11
10
  .rcw-details-form {
12
11
  display: flex;
13
12
  flex-direction: column;
14
- gap: $iui-baseline;
13
+ gap: var(--iui-size-);
15
14
  }
16
15
  }