@itwin/frontend-devtools 3.6.0-dev.8 → 3.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 (372) hide show
  1. package/CHANGELOG.md +33 -1
  2. package/LICENSE.md +1 -1
  3. package/lib/cjs/ClipboardUtilities.d.ts +8 -8
  4. package/lib/cjs/ClipboardUtilities.js +26 -26
  5. package/lib/cjs/ClipboardUtilities.js.map +1 -1
  6. package/lib/cjs/FrontEndDevTools.d.ts +19 -19
  7. package/lib/cjs/FrontEndDevTools.js +221 -221
  8. package/lib/cjs/FrontEndDevTools.js.map +1 -1
  9. package/lib/cjs/effects/Convolution.d.ts +68 -68
  10. package/lib/cjs/effects/Convolution.js +165 -165
  11. package/lib/cjs/effects/Convolution.js.map +1 -1
  12. package/lib/cjs/effects/EffectTools.d.ts +33 -33
  13. package/lib/cjs/effects/EffectTools.js +68 -68
  14. package/lib/cjs/effects/EffectTools.js.map +1 -1
  15. package/lib/cjs/effects/Explosion.d.ts +12 -12
  16. package/lib/cjs/effects/Explosion.js +168 -168
  17. package/lib/cjs/effects/Explosion.js.map +1 -1
  18. package/lib/cjs/effects/FlipImage.d.ts +30 -30
  19. package/lib/cjs/effects/FlipImage.js +99 -99
  20. package/lib/cjs/effects/FlipImage.js.map +1 -1
  21. package/lib/cjs/effects/LensDistortion.d.ts +34 -34
  22. package/lib/cjs/effects/LensDistortion.js +109 -109
  23. package/lib/cjs/effects/LensDistortion.js.map +1 -1
  24. package/lib/cjs/effects/Random.d.ts +24 -24
  25. package/lib/cjs/effects/Random.js +49 -49
  26. package/lib/cjs/effects/Random.js.map +1 -1
  27. package/lib/cjs/effects/Saturation.d.ts +30 -30
  28. package/lib/cjs/effects/Saturation.js +85 -85
  29. package/lib/cjs/effects/Saturation.js.map +1 -1
  30. package/lib/cjs/effects/Snow.d.ts +76 -76
  31. package/lib/cjs/effects/Snow.js +187 -187
  32. package/lib/cjs/effects/Snow.js.map +1 -1
  33. package/lib/cjs/effects/Vignette.d.ts +39 -39
  34. package/lib/cjs/effects/Vignette.js +108 -108
  35. package/lib/cjs/effects/Vignette.js.map +1 -1
  36. package/lib/cjs/frontend-devtools.d.ts +82 -82
  37. package/lib/cjs/frontend-devtools.js +98 -98
  38. package/lib/cjs/frontend-devtools.js.map +1 -1
  39. package/lib/cjs/tools/AnimationIntervalTool.d.ts +15 -15
  40. package/lib/cjs/tools/AnimationIntervalTool.js +30 -30
  41. package/lib/cjs/tools/AnimationIntervalTool.js.map +1 -1
  42. package/lib/cjs/tools/ChangeUnitsTool.d.ts +15 -15
  43. package/lib/cjs/tools/ChangeUnitsTool.js +41 -41
  44. package/lib/cjs/tools/ChangeUnitsTool.js.map +1 -1
  45. package/lib/cjs/tools/ClipTools.d.ts +67 -67
  46. package/lib/cjs/tools/ClipTools.js +164 -164
  47. package/lib/cjs/tools/ClipTools.js.map +1 -1
  48. package/lib/cjs/tools/DisplayStyleTools.d.ts +145 -145
  49. package/lib/cjs/tools/DisplayStyleTools.js +370 -370
  50. package/lib/cjs/tools/DisplayStyleTools.js.map +1 -1
  51. package/lib/cjs/tools/EmphasizeElementsTool.d.ts +60 -60
  52. package/lib/cjs/tools/EmphasizeElementsTool.js +154 -154
  53. package/lib/cjs/tools/EmphasizeElementsTool.js.map +1 -1
  54. package/lib/cjs/tools/FrustumDecoration.d.ts +57 -57
  55. package/lib/cjs/tools/FrustumDecoration.js +374 -374
  56. package/lib/cjs/tools/FrustumDecoration.js.map +1 -1
  57. package/lib/cjs/tools/InspectElementTool.d.ts +42 -42
  58. package/lib/cjs/tools/InspectElementTool.js +198 -198
  59. package/lib/cjs/tools/InspectElementTool.js.map +1 -1
  60. package/lib/cjs/tools/MapLayerTool.d.ts +264 -264
  61. package/lib/cjs/tools/MapLayerTool.js +507 -507
  62. package/lib/cjs/tools/MapLayerTool.js.map +1 -1
  63. package/lib/cjs/tools/MeasureTileLoadTime.d.ts +12 -12
  64. package/lib/cjs/tools/MeasureTileLoadTime.js +63 -63
  65. package/lib/cjs/tools/MeasureTileLoadTime.js.map +1 -1
  66. package/lib/cjs/tools/ModelAppearanceTools.d.ts +86 -86
  67. package/lib/cjs/tools/ModelAppearanceTools.js +183 -183
  68. package/lib/cjs/tools/ModelAppearanceTools.js.map +1 -1
  69. package/lib/cjs/tools/PlanProjectionTools.d.ts +40 -40
  70. package/lib/cjs/tools/PlanProjectionTools.js +149 -149
  71. package/lib/cjs/tools/PlanProjectionTools.js.map +1 -1
  72. package/lib/cjs/tools/PlanarMaskTools.d.ts +182 -182
  73. package/lib/cjs/tools/PlanarMaskTools.js +393 -393
  74. package/lib/cjs/tools/PlanarMaskTools.js.map +1 -1
  75. package/lib/cjs/tools/ProjectExtents.d.ts +41 -41
  76. package/lib/cjs/tools/ProjectExtents.js +110 -110
  77. package/lib/cjs/tools/ProjectExtents.js.map +1 -1
  78. package/lib/cjs/tools/RealityModelTools.d.ts +116 -116
  79. package/lib/cjs/tools/RealityModelTools.js +281 -281
  80. package/lib/cjs/tools/RealityModelTools.js.map +1 -1
  81. package/lib/cjs/tools/RealityTransitionTool.d.ts +25 -25
  82. package/lib/cjs/tools/RealityTransitionTool.js +116 -116
  83. package/lib/cjs/tools/RealityTransitionTool.js.map +1 -1
  84. package/lib/cjs/tools/RenderSystemTools.d.ts +38 -38
  85. package/lib/cjs/tools/RenderSystemTools.js +70 -70
  86. package/lib/cjs/tools/RenderSystemTools.js.map +1 -1
  87. package/lib/cjs/tools/RenderTargetTools.d.ts +107 -107
  88. package/lib/cjs/tools/RenderTargetTools.js +174 -174
  89. package/lib/cjs/tools/RenderTargetTools.js.map +1 -1
  90. package/lib/cjs/tools/ReportWebGLCompatibilityTool.d.ts +11 -11
  91. package/lib/cjs/tools/ReportWebGLCompatibilityTool.js +30 -30
  92. package/lib/cjs/tools/ReportWebGLCompatibilityTool.js.map +1 -1
  93. package/lib/cjs/tools/SavedViews.d.ts +46 -46
  94. package/lib/cjs/tools/SavedViews.js +136 -136
  95. package/lib/cjs/tools/SavedViews.js.map +1 -1
  96. package/lib/cjs/tools/ScheduleScriptTools.d.ts +37 -37
  97. package/lib/cjs/tools/ScheduleScriptTools.js +159 -159
  98. package/lib/cjs/tools/ScheduleScriptTools.js.map +1 -1
  99. package/lib/cjs/tools/SelectionTools.d.ts +28 -28
  100. package/lib/cjs/tools/SelectionTools.js +87 -87
  101. package/lib/cjs/tools/SelectionTools.js.map +1 -1
  102. package/lib/cjs/tools/SetGpuMemoryLimitTool.d.ts +15 -15
  103. package/lib/cjs/tools/SetGpuMemoryLimitTool.js +33 -33
  104. package/lib/cjs/tools/SetGpuMemoryLimitTool.js.map +1 -1
  105. package/lib/cjs/tools/SourceAspectIdTools.d.ts +40 -40
  106. package/lib/cjs/tools/SourceAspectIdTools.js +86 -86
  107. package/lib/cjs/tools/SourceAspectIdTools.js.map +1 -1
  108. package/lib/cjs/tools/TileRequestDecoration.d.ts +12 -12
  109. package/lib/cjs/tools/TileRequestDecoration.js +83 -83
  110. package/lib/cjs/tools/TileRequestDecoration.js.map +1 -1
  111. package/lib/cjs/tools/TileTreeBoundsDecoration.d.ts +11 -11
  112. package/lib/cjs/tools/TileTreeBoundsDecoration.js +74 -74
  113. package/lib/cjs/tools/TileTreeBoundsDecoration.js.map +1 -1
  114. package/lib/cjs/tools/ToolTipProvider.d.ts +15 -15
  115. package/lib/cjs/tools/ToolTipProvider.js +66 -66
  116. package/lib/cjs/tools/ToolTipProvider.js.map +1 -1
  117. package/lib/cjs/tools/ViewportTools.d.ts +218 -218
  118. package/lib/cjs/tools/ViewportTools.js +516 -516
  119. package/lib/cjs/tools/ViewportTools.js.map +1 -1
  120. package/lib/cjs/tools/parseArgs.d.ts +23 -23
  121. package/lib/cjs/tools/parseArgs.js +51 -51
  122. package/lib/cjs/tools/parseArgs.js.map +1 -1
  123. package/lib/cjs/tools/parseBoolean.d.ts +8 -8
  124. package/lib/cjs/tools/parseBoolean.js +26 -26
  125. package/lib/cjs/tools/parseBoolean.js.map +1 -1
  126. package/lib/cjs/tools/parseToggle.d.ts +8 -8
  127. package/lib/cjs/tools/parseToggle.js +25 -25
  128. package/lib/cjs/tools/parseToggle.js.map +1 -1
  129. package/lib/cjs/ui/Button.d.ts +29 -29
  130. package/lib/cjs/ui/Button.js +26 -26
  131. package/lib/cjs/ui/Button.js.map +1 -1
  132. package/lib/cjs/ui/CheckBox.d.ts +23 -23
  133. package/lib/cjs/ui/CheckBox.js +27 -27
  134. package/lib/cjs/ui/CheckBox.js.map +1 -1
  135. package/lib/cjs/ui/ColorInput.d.ts +27 -27
  136. package/lib/cjs/ui/ColorInput.js +53 -53
  137. package/lib/cjs/ui/ColorInput.js.map +1 -1
  138. package/lib/cjs/ui/ComboBox.d.ts +28 -28
  139. package/lib/cjs/ui/ComboBox.js +42 -42
  140. package/lib/cjs/ui/ComboBox.js.map +1 -1
  141. package/lib/cjs/ui/DataList.d.ts +27 -27
  142. package/lib/cjs/ui/DataList.js +39 -39
  143. package/lib/cjs/ui/DataList.js.map +1 -1
  144. package/lib/cjs/ui/NestedMenu.d.ts +19 -19
  145. package/lib/cjs/ui/NestedMenu.js +46 -46
  146. package/lib/cjs/ui/NestedMenu.js.map +1 -1
  147. package/lib/cjs/ui/NumericInput.d.ts +35 -35
  148. package/lib/cjs/ui/NumericInput.js +61 -61
  149. package/lib/cjs/ui/NumericInput.js.map +1 -1
  150. package/lib/cjs/ui/RadioBox.d.ts +29 -29
  151. package/lib/cjs/ui/RadioBox.js +76 -76
  152. package/lib/cjs/ui/RadioBox.js.map +1 -1
  153. package/lib/cjs/ui/Slider.d.ts +28 -26
  154. package/lib/cjs/ui/Slider.d.ts.map +1 -1
  155. package/lib/cjs/ui/Slider.js +42 -34
  156. package/lib/cjs/ui/Slider.js.map +1 -1
  157. package/lib/cjs/ui/TextBox.d.ts +32 -32
  158. package/lib/cjs/ui/TextBox.js +56 -56
  159. package/lib/cjs/ui/TextBox.js.map +1 -1
  160. package/lib/cjs/widgets/DiagnosticsPanel.d.ts +37 -37
  161. package/lib/cjs/widgets/DiagnosticsPanel.js +81 -81
  162. package/lib/cjs/widgets/DiagnosticsPanel.js.map +1 -1
  163. package/lib/cjs/widgets/FpsTracker.d.ts +19 -19
  164. package/lib/cjs/widgets/FpsTracker.js +56 -56
  165. package/lib/cjs/widgets/FpsTracker.js.map +1 -1
  166. package/lib/cjs/widgets/GpuProfiler.d.ts +16 -16
  167. package/lib/cjs/widgets/GpuProfiler.js +192 -192
  168. package/lib/cjs/widgets/GpuProfiler.js.map +1 -1
  169. package/lib/cjs/widgets/KeyinField.d.ts +61 -61
  170. package/lib/cjs/widgets/KeyinField.js +187 -187
  171. package/lib/cjs/widgets/KeyinField.js.map +1 -1
  172. package/lib/cjs/widgets/MemoryTracker.d.ts +27 -27
  173. package/lib/cjs/widgets/MemoryTracker.js +243 -243
  174. package/lib/cjs/widgets/MemoryTracker.js.map +1 -1
  175. package/lib/cjs/widgets/RenderCommandBreakdown.d.ts +15 -15
  176. package/lib/cjs/widgets/RenderCommandBreakdown.js +68 -68
  177. package/lib/cjs/widgets/RenderCommandBreakdown.js.map +1 -1
  178. package/lib/cjs/widgets/TileMemoryBreakdown.d.ts +30 -30
  179. package/lib/cjs/widgets/TileMemoryBreakdown.js +204 -204
  180. package/lib/cjs/widgets/TileMemoryBreakdown.js.map +1 -1
  181. package/lib/cjs/widgets/TileStatisticsTracker.d.ts +21 -21
  182. package/lib/cjs/widgets/TileStatisticsTracker.js +142 -142
  183. package/lib/cjs/widgets/TileStatisticsTracker.js.map +1 -1
  184. package/lib/cjs/widgets/ToolSettingsTracker.d.ts +9 -9
  185. package/lib/cjs/widgets/ToolSettingsTracker.js +211 -211
  186. package/lib/cjs/widgets/ToolSettingsTracker.js.map +1 -1
  187. package/lib/esm/ClipboardUtilities.d.ts +8 -8
  188. package/lib/esm/ClipboardUtilities.js +22 -22
  189. package/lib/esm/ClipboardUtilities.js.map +1 -1
  190. package/lib/esm/FrontEndDevTools.d.ts +19 -19
  191. package/lib/esm/FrontEndDevTools.js +217 -217
  192. package/lib/esm/FrontEndDevTools.js.map +1 -1
  193. package/lib/esm/effects/Convolution.d.ts +68 -68
  194. package/lib/esm/effects/Convolution.js +155 -155
  195. package/lib/esm/effects/Convolution.js.map +1 -1
  196. package/lib/esm/effects/EffectTools.d.ts +33 -33
  197. package/lib/esm/effects/EffectTools.js +62 -62
  198. package/lib/esm/effects/EffectTools.js.map +1 -1
  199. package/lib/esm/effects/Explosion.d.ts +12 -12
  200. package/lib/esm/effects/Explosion.js +164 -164
  201. package/lib/esm/effects/Explosion.js.map +1 -1
  202. package/lib/esm/effects/FlipImage.d.ts +30 -30
  203. package/lib/esm/effects/FlipImage.js +94 -94
  204. package/lib/esm/effects/FlipImage.js.map +1 -1
  205. package/lib/esm/effects/LensDistortion.d.ts +34 -34
  206. package/lib/esm/effects/LensDistortion.js +104 -104
  207. package/lib/esm/effects/LensDistortion.js.map +1 -1
  208. package/lib/esm/effects/Random.d.ts +24 -24
  209. package/lib/esm/effects/Random.js +41 -41
  210. package/lib/esm/effects/Random.js.map +1 -1
  211. package/lib/esm/effects/Saturation.d.ts +30 -30
  212. package/lib/esm/effects/Saturation.js +80 -80
  213. package/lib/esm/effects/Saturation.js.map +1 -1
  214. package/lib/esm/effects/Snow.d.ts +76 -76
  215. package/lib/esm/effects/Snow.js +182 -182
  216. package/lib/esm/effects/Snow.js.map +1 -1
  217. package/lib/esm/effects/Vignette.d.ts +39 -39
  218. package/lib/esm/effects/Vignette.js +103 -103
  219. package/lib/esm/effects/Vignette.js.map +1 -1
  220. package/lib/esm/frontend-devtools.d.ts +82 -82
  221. package/lib/esm/frontend-devtools.js +86 -86
  222. package/lib/esm/frontend-devtools.js.map +1 -1
  223. package/lib/esm/tools/AnimationIntervalTool.d.ts +15 -15
  224. package/lib/esm/tools/AnimationIntervalTool.js +26 -26
  225. package/lib/esm/tools/AnimationIntervalTool.js.map +1 -1
  226. package/lib/esm/tools/ChangeUnitsTool.d.ts +15 -15
  227. package/lib/esm/tools/ChangeUnitsTool.js +37 -37
  228. package/lib/esm/tools/ChangeUnitsTool.js.map +1 -1
  229. package/lib/esm/tools/ClipTools.d.ts +67 -67
  230. package/lib/esm/tools/ClipTools.js +158 -158
  231. package/lib/esm/tools/ClipTools.js.map +1 -1
  232. package/lib/esm/tools/DisplayStyleTools.d.ts +145 -145
  233. package/lib/esm/tools/DisplayStyleTools.js +356 -356
  234. package/lib/esm/tools/DisplayStyleTools.js.map +1 -1
  235. package/lib/esm/tools/EmphasizeElementsTool.d.ts +60 -60
  236. package/lib/esm/tools/EmphasizeElementsTool.js +145 -145
  237. package/lib/esm/tools/EmphasizeElementsTool.js.map +1 -1
  238. package/lib/esm/tools/FrustumDecoration.d.ts +57 -57
  239. package/lib/esm/tools/FrustumDecoration.js +367 -367
  240. package/lib/esm/tools/FrustumDecoration.js.map +1 -1
  241. package/lib/esm/tools/InspectElementTool.d.ts +42 -42
  242. package/lib/esm/tools/InspectElementTool.js +194 -194
  243. package/lib/esm/tools/InspectElementTool.js.map +1 -1
  244. package/lib/esm/tools/MapLayerTool.d.ts +264 -264
  245. package/lib/esm/tools/MapLayerTool.js +485 -485
  246. package/lib/esm/tools/MapLayerTool.js.map +1 -1
  247. package/lib/esm/tools/MeasureTileLoadTime.d.ts +12 -12
  248. package/lib/esm/tools/MeasureTileLoadTime.js +59 -59
  249. package/lib/esm/tools/MeasureTileLoadTime.js.map +1 -1
  250. package/lib/esm/tools/ModelAppearanceTools.d.ts +86 -86
  251. package/lib/esm/tools/ModelAppearanceTools.js +172 -172
  252. package/lib/esm/tools/ModelAppearanceTools.js.map +1 -1
  253. package/lib/esm/tools/PlanProjectionTools.d.ts +40 -40
  254. package/lib/esm/tools/PlanProjectionTools.js +143 -143
  255. package/lib/esm/tools/PlanProjectionTools.js.map +1 -1
  256. package/lib/esm/tools/PlanarMaskTools.d.ts +182 -182
  257. package/lib/esm/tools/PlanarMaskTools.js +377 -377
  258. package/lib/esm/tools/PlanarMaskTools.js.map +1 -1
  259. package/lib/esm/tools/ProjectExtents.d.ts +41 -41
  260. package/lib/esm/tools/ProjectExtents.js +104 -104
  261. package/lib/esm/tools/ProjectExtents.js.map +1 -1
  262. package/lib/esm/tools/RealityModelTools.d.ts +116 -116
  263. package/lib/esm/tools/RealityModelTools.js +268 -268
  264. package/lib/esm/tools/RealityModelTools.js.map +1 -1
  265. package/lib/esm/tools/RealityTransitionTool.d.ts +25 -25
  266. package/lib/esm/tools/RealityTransitionTool.js +112 -112
  267. package/lib/esm/tools/RealityTransitionTool.js.map +1 -1
  268. package/lib/esm/tools/RenderSystemTools.d.ts +38 -38
  269. package/lib/esm/tools/RenderSystemTools.js +63 -63
  270. package/lib/esm/tools/RenderSystemTools.js.map +1 -1
  271. package/lib/esm/tools/RenderTargetTools.d.ts +107 -107
  272. package/lib/esm/tools/RenderTargetTools.js +159 -159
  273. package/lib/esm/tools/RenderTargetTools.js.map +1 -1
  274. package/lib/esm/tools/ReportWebGLCompatibilityTool.d.ts +11 -11
  275. package/lib/esm/tools/ReportWebGLCompatibilityTool.js +26 -26
  276. package/lib/esm/tools/ReportWebGLCompatibilityTool.js.map +1 -1
  277. package/lib/esm/tools/SavedViews.d.ts +46 -46
  278. package/lib/esm/tools/SavedViews.js +128 -128
  279. package/lib/esm/tools/SavedViews.js.map +1 -1
  280. package/lib/esm/tools/ScheduleScriptTools.d.ts +37 -37
  281. package/lib/esm/tools/ScheduleScriptTools.js +153 -153
  282. package/lib/esm/tools/ScheduleScriptTools.js.map +1 -1
  283. package/lib/esm/tools/SelectionTools.d.ts +28 -28
  284. package/lib/esm/tools/SelectionTools.js +82 -82
  285. package/lib/esm/tools/SelectionTools.js.map +1 -1
  286. package/lib/esm/tools/SetGpuMemoryLimitTool.d.ts +15 -15
  287. package/lib/esm/tools/SetGpuMemoryLimitTool.js +29 -29
  288. package/lib/esm/tools/SetGpuMemoryLimitTool.js.map +1 -1
  289. package/lib/esm/tools/SourceAspectIdTools.d.ts +40 -40
  290. package/lib/esm/tools/SourceAspectIdTools.js +80 -80
  291. package/lib/esm/tools/SourceAspectIdTools.js.map +1 -1
  292. package/lib/esm/tools/TileRequestDecoration.d.ts +12 -12
  293. package/lib/esm/tools/TileRequestDecoration.js +79 -79
  294. package/lib/esm/tools/TileRequestDecoration.js.map +1 -1
  295. package/lib/esm/tools/TileTreeBoundsDecoration.d.ts +11 -11
  296. package/lib/esm/tools/TileTreeBoundsDecoration.js +70 -70
  297. package/lib/esm/tools/TileTreeBoundsDecoration.js.map +1 -1
  298. package/lib/esm/tools/ToolTipProvider.d.ts +15 -15
  299. package/lib/esm/tools/ToolTipProvider.js +62 -62
  300. package/lib/esm/tools/ToolTipProvider.js.map +1 -1
  301. package/lib/esm/tools/ViewportTools.d.ts +218 -218
  302. package/lib/esm/tools/ViewportTools.js +492 -492
  303. package/lib/esm/tools/ViewportTools.js.map +1 -1
  304. package/lib/esm/tools/parseArgs.d.ts +23 -23
  305. package/lib/esm/tools/parseArgs.js +47 -47
  306. package/lib/esm/tools/parseArgs.js.map +1 -1
  307. package/lib/esm/tools/parseBoolean.d.ts +8 -8
  308. package/lib/esm/tools/parseBoolean.js +22 -22
  309. package/lib/esm/tools/parseBoolean.js.map +1 -1
  310. package/lib/esm/tools/parseToggle.d.ts +8 -8
  311. package/lib/esm/tools/parseToggle.js +21 -21
  312. package/lib/esm/tools/parseToggle.js.map +1 -1
  313. package/lib/esm/ui/Button.d.ts +29 -29
  314. package/lib/esm/ui/Button.js +22 -22
  315. package/lib/esm/ui/Button.js.map +1 -1
  316. package/lib/esm/ui/CheckBox.d.ts +23 -23
  317. package/lib/esm/ui/CheckBox.js +23 -23
  318. package/lib/esm/ui/CheckBox.js.map +1 -1
  319. package/lib/esm/ui/ColorInput.d.ts +27 -27
  320. package/lib/esm/ui/ColorInput.js +48 -48
  321. package/lib/esm/ui/ColorInput.js.map +1 -1
  322. package/lib/esm/ui/ComboBox.d.ts +28 -28
  323. package/lib/esm/ui/ComboBox.js +38 -38
  324. package/lib/esm/ui/ComboBox.js.map +1 -1
  325. package/lib/esm/ui/DataList.d.ts +27 -27
  326. package/lib/esm/ui/DataList.js +34 -34
  327. package/lib/esm/ui/DataList.js.map +1 -1
  328. package/lib/esm/ui/NestedMenu.d.ts +19 -19
  329. package/lib/esm/ui/NestedMenu.js +42 -42
  330. package/lib/esm/ui/NestedMenu.js.map +1 -1
  331. package/lib/esm/ui/NumericInput.d.ts +35 -35
  332. package/lib/esm/ui/NumericInput.js +56 -56
  333. package/lib/esm/ui/NumericInput.js.map +1 -1
  334. package/lib/esm/ui/RadioBox.d.ts +29 -29
  335. package/lib/esm/ui/RadioBox.js +72 -72
  336. package/lib/esm/ui/RadioBox.js.map +1 -1
  337. package/lib/esm/ui/Slider.d.ts +28 -26
  338. package/lib/esm/ui/Slider.d.ts.map +1 -1
  339. package/lib/esm/ui/Slider.js +38 -30
  340. package/lib/esm/ui/Slider.js.map +1 -1
  341. package/lib/esm/ui/TextBox.d.ts +32 -32
  342. package/lib/esm/ui/TextBox.js +52 -52
  343. package/lib/esm/ui/TextBox.js.map +1 -1
  344. package/lib/esm/widgets/DiagnosticsPanel.d.ts +37 -37
  345. package/lib/esm/widgets/DiagnosticsPanel.js +77 -77
  346. package/lib/esm/widgets/DiagnosticsPanel.js.map +1 -1
  347. package/lib/esm/widgets/FpsTracker.d.ts +19 -19
  348. package/lib/esm/widgets/FpsTracker.js +52 -52
  349. package/lib/esm/widgets/FpsTracker.js.map +1 -1
  350. package/lib/esm/widgets/GpuProfiler.d.ts +16 -16
  351. package/lib/esm/widgets/GpuProfiler.js +188 -188
  352. package/lib/esm/widgets/GpuProfiler.js.map +1 -1
  353. package/lib/esm/widgets/KeyinField.d.ts +61 -61
  354. package/lib/esm/widgets/KeyinField.js +183 -183
  355. package/lib/esm/widgets/KeyinField.js.map +1 -1
  356. package/lib/esm/widgets/MemoryTracker.d.ts +27 -27
  357. package/lib/esm/widgets/MemoryTracker.js +238 -238
  358. package/lib/esm/widgets/MemoryTracker.js.map +1 -1
  359. package/lib/esm/widgets/RenderCommandBreakdown.d.ts +15 -15
  360. package/lib/esm/widgets/RenderCommandBreakdown.js +64 -64
  361. package/lib/esm/widgets/RenderCommandBreakdown.js.map +1 -1
  362. package/lib/esm/widgets/TileMemoryBreakdown.d.ts +30 -30
  363. package/lib/esm/widgets/TileMemoryBreakdown.js +200 -200
  364. package/lib/esm/widgets/TileMemoryBreakdown.js.map +1 -1
  365. package/lib/esm/widgets/TileStatisticsTracker.d.ts +21 -21
  366. package/lib/esm/widgets/TileStatisticsTracker.js +138 -138
  367. package/lib/esm/widgets/TileStatisticsTracker.js.map +1 -1
  368. package/lib/esm/widgets/ToolSettingsTracker.d.ts +9 -9
  369. package/lib/esm/widgets/ToolSettingsTracker.js +207 -207
  370. package/lib/esm/widgets/ToolSettingsTracker.js.map +1 -1
  371. package/lib/public/locales/en/FrontendDevTools.json +484 -484
  372. package/package.json +7 -7
@@ -1,16 +1,16 @@
1
- /** @packageDocumentation
2
- * @module Tools
3
- */
4
- import { GpuMemoryLimit, Tool } from "@itwin/core-frontend";
5
- /** Adjust the value of [TileAdmin.gpuMemoryLimit]($frontend). This controls how much GPU memory is allowed to be consumed
6
- * by tile graphics before the system starts discarding the graphics for the least recently drawn tiles.
7
- * @beta
8
- */
9
- export declare class SetGpuMemoryLimitTool extends Tool {
10
- static toolId: string;
11
- static get minArgs(): number;
12
- static get maxArgs(): number;
13
- run(limit?: GpuMemoryLimit): Promise<boolean>;
14
- parseAndRun(...args: string[]): Promise<boolean>;
15
- }
1
+ /** @packageDocumentation
2
+ * @module Tools
3
+ */
4
+ import { GpuMemoryLimit, Tool } from "@itwin/core-frontend";
5
+ /** Adjust the value of [TileAdmin.gpuMemoryLimit]($frontend). This controls how much GPU memory is allowed to be consumed
6
+ * by tile graphics before the system starts discarding the graphics for the least recently drawn tiles.
7
+ * @beta
8
+ */
9
+ export declare class SetGpuMemoryLimitTool extends Tool {
10
+ static toolId: string;
11
+ static get minArgs(): number;
12
+ static get maxArgs(): number;
13
+ run(limit?: GpuMemoryLimit): Promise<boolean>;
14
+ parseAndRun(...args: string[]): Promise<boolean>;
15
+ }
16
16
  //# sourceMappingURL=SetGpuMemoryLimitTool.d.ts.map
@@ -1,30 +1,30 @@
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
- /** @packageDocumentation
6
- * @module Tools
7
- */
8
- import { IModelApp, Tool } from "@itwin/core-frontend";
9
- /** Adjust the value of [TileAdmin.gpuMemoryLimit]($frontend). This controls how much GPU memory is allowed to be consumed
10
- * by tile graphics before the system starts discarding the graphics for the least recently drawn tiles.
11
- * @beta
12
- */
13
- export class SetGpuMemoryLimitTool extends Tool {
14
- static get minArgs() { return 1; }
15
- static get maxArgs() { return 1; }
16
- async run(limit) {
17
- if (undefined !== limit) {
18
- IModelApp.tileAdmin.gpuMemoryLimit = limit;
19
- IModelApp.requestNextAnimation();
20
- }
21
- return true;
22
- }
23
- async parseAndRun(...args) {
24
- const maxBytes = Number.parseInt(args[0], 10);
25
- const limit = Number.isNaN(maxBytes) ? args[0] : maxBytes;
26
- return this.run(limit);
27
- }
28
- }
29
- SetGpuMemoryLimitTool.toolId = "SetGpuMemoryLimit";
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
+ /** @packageDocumentation
6
+ * @module Tools
7
+ */
8
+ import { IModelApp, Tool } from "@itwin/core-frontend";
9
+ /** Adjust the value of [TileAdmin.gpuMemoryLimit]($frontend). This controls how much GPU memory is allowed to be consumed
10
+ * by tile graphics before the system starts discarding the graphics for the least recently drawn tiles.
11
+ * @beta
12
+ */
13
+ export class SetGpuMemoryLimitTool extends Tool {
14
+ static get minArgs() { return 1; }
15
+ static get maxArgs() { return 1; }
16
+ async run(limit) {
17
+ if (undefined !== limit) {
18
+ IModelApp.tileAdmin.gpuMemoryLimit = limit;
19
+ IModelApp.requestNextAnimation();
20
+ }
21
+ return true;
22
+ }
23
+ async parseAndRun(...args) {
24
+ const maxBytes = Number.parseInt(args[0], 10);
25
+ const limit = Number.isNaN(maxBytes) ? args[0] : maxBytes;
26
+ return this.run(limit);
27
+ }
28
+ }
29
+ SetGpuMemoryLimitTool.toolId = "SetGpuMemoryLimit";
30
30
  //# sourceMappingURL=SetGpuMemoryLimitTool.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SetGpuMemoryLimitTool.js","sourceRoot":"","sources":["../../../src/tools/SetGpuMemoryLimitTool.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F;;GAEG;AAEH,OAAO,EAAkB,SAAS,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AAEvE;;;GAGG;AACH,MAAM,OAAO,qBAAsB,SAAQ,IAAI;IAEtC,MAAM,KAAc,OAAO,KAAK,OAAO,CAAC,CAAC,CAAC,CAAC;IAC3C,MAAM,KAAc,OAAO,KAAK,OAAO,CAAC,CAAC,CAAC,CAAC;IAElC,KAAK,CAAC,GAAG,CAAC,KAAsB;QAC9C,IAAI,SAAS,KAAK,KAAK,EAAE;YACvB,SAAS,CAAC,SAAS,CAAC,cAAc,GAAG,KAAK,CAAC;YAC3C,SAAS,CAAC,oBAAoB,EAAE,CAAC;SAClC;QAED,OAAO,IAAI,CAAC;IACd,CAAC;IAEe,KAAK,CAAC,WAAW,CAAC,GAAG,IAAc;QACjD,MAAM,QAAQ,GAAG,MAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC;QAC9C,MAAM,KAAK,GAAG,MAAM,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAmB,CAAC,CAAC,CAAC,QAAQ,CAAC;QAC5E,OAAO,IAAI,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;IACzB,CAAC;;AAjBsB,4BAAM,GAAG,mBAAmB,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Tools\r\n */\r\n\r\nimport { GpuMemoryLimit, IModelApp, Tool } from \"@itwin/core-frontend\";\r\n\r\n/** Adjust the value of [TileAdmin.gpuMemoryLimit]($frontend). This controls how much GPU memory is allowed to be consumed\r\n * by tile graphics before the system starts discarding the graphics for the least recently drawn tiles.\r\n * @beta\r\n */\r\nexport class SetGpuMemoryLimitTool extends Tool {\r\n public static override toolId = \"SetGpuMemoryLimit\";\r\n public static override get minArgs() { return 1; }\r\n public static override get maxArgs() { return 1; }\r\n\r\n public override async run(limit?: GpuMemoryLimit): Promise<boolean> {\r\n if (undefined !== limit) {\r\n IModelApp.tileAdmin.gpuMemoryLimit = limit;\r\n IModelApp.requestNextAnimation();\r\n }\r\n\r\n return true;\r\n }\r\n\r\n public override async parseAndRun(...args: string[]): Promise<boolean> {\r\n const maxBytes = Number.parseInt(args[0], 10);\r\n const limit = Number.isNaN(maxBytes) ? args[0] as GpuMemoryLimit : maxBytes;\r\n return this.run(limit);\r\n }\r\n}\r\n"]}
1
+ {"version":3,"file":"SetGpuMemoryLimitTool.js","sourceRoot":"","sources":["../../../src/tools/SetGpuMemoryLimitTool.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F;;GAEG;AAEH,OAAO,EAAkB,SAAS,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AAEvE;;;GAGG;AACH,MAAM,OAAO,qBAAsB,SAAQ,IAAI;IAEtC,MAAM,KAAc,OAAO,KAAK,OAAO,CAAC,CAAC,CAAC,CAAC;IAC3C,MAAM,KAAc,OAAO,KAAK,OAAO,CAAC,CAAC,CAAC,CAAC;IAElC,KAAK,CAAC,GAAG,CAAC,KAAsB;QAC9C,IAAI,SAAS,KAAK,KAAK,EAAE;YACvB,SAAS,CAAC,SAAS,CAAC,cAAc,GAAG,KAAK,CAAC;YAC3C,SAAS,CAAC,oBAAoB,EAAE,CAAC;SAClC;QAED,OAAO,IAAI,CAAC;IACd,CAAC;IAEe,KAAK,CAAC,WAAW,CAAC,GAAG,IAAc;QACjD,MAAM,QAAQ,GAAG,MAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC;QAC9C,MAAM,KAAK,GAAG,MAAM,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAmB,CAAC,CAAC,CAAC,QAAQ,CAAC;QAC5E,OAAO,IAAI,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;IACzB,CAAC;;AAjBsB,4BAAM,GAAG,mBAAmB,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\n/** @packageDocumentation\n * @module Tools\n */\n\nimport { GpuMemoryLimit, IModelApp, Tool } from \"@itwin/core-frontend\";\n\n/** Adjust the value of [TileAdmin.gpuMemoryLimit]($frontend). This controls how much GPU memory is allowed to be consumed\n * by tile graphics before the system starts discarding the graphics for the least recently drawn tiles.\n * @beta\n */\nexport class SetGpuMemoryLimitTool extends Tool {\n public static override toolId = \"SetGpuMemoryLimit\";\n public static override get minArgs() { return 1; }\n public static override get maxArgs() { return 1; }\n\n public override async run(limit?: GpuMemoryLimit): Promise<boolean> {\n if (undefined !== limit) {\n IModelApp.tileAdmin.gpuMemoryLimit = limit;\n IModelApp.requestNextAnimation();\n }\n\n return true;\n }\n\n public override async parseAndRun(...args: string[]): Promise<boolean> {\n const maxBytes = Number.parseInt(args[0], 10);\n const limit = Number.isNaN(maxBytes) ? args[0] as GpuMemoryLimit : maxBytes;\n return this.run(limit);\n }\n}\n"]}
@@ -1,41 +1,41 @@
1
- import { Tool } from "@itwin/core-frontend";
2
- /** Base class for a tool that can convert between source aspect Ids and element Ids.
3
- * A "source aspect Id" is a string that identifies an object (such as an element) in the source document from which the iModel originated.
4
- * For example, if the iModel was produced by the MicroStation bridge, the source aspect Id is usually a V8 element Id.
5
- * @beta
6
- */
7
- export declare abstract class SourceAspectIdTool extends Tool {
8
- static get minArgs(): number;
9
- static get maxArgs(): number;
10
- protected abstract getECSql(queryId: string): string;
11
- run(idToQuery?: string, copyToClipboard?: boolean): Promise<boolean>;
12
- parseAndRun(...keyinArgs: string[]): Promise<boolean>;
13
- private doQuery;
14
- }
15
- /** Given a source aspect Id, output the Id of the corresponding element in the iModel.
16
- * A "source aspect Id" is a string that identifies an object (such as an element) in the source document from which the iModel originated.
17
- * For example, if the iModel was produced by the MicroStation bridge, the source aspect Id is usually a V8 element Id.
18
- * Arguments:
19
- * - `id=elementId` where `elementId` is the numeric Id of the element of interest (e.g., `0x13a6c`; decimal notation is also permitted).
20
- * - `copy=0|1` where `1` indicates the source aspect Id should be copied to the clipboard.
21
- * The command outputs to the IModelApp.notifications the corresponding source aspect Id, or "NOT FOUND".
22
- * @beta
23
- */
24
- export declare class SourceAspectIdFromElementIdTool extends SourceAspectIdTool {
25
- static toolId: string;
26
- protected getECSql(queryId: string): string;
27
- }
28
- /** Given the Id of an element in the iModel, output the source aspect Id of the object in the source document from which the element originated.
29
- * A "source aspect Id" is a string that identifies an object (such as an element) in the source document from which the iModel originated.
30
- * For example, if the iModel was produced by the MicroStation bridge, the source aspect Id is usually a V8 element Id.
31
- * Arguments:
32
- * - `id=sourceAspectId` where `sourceAspectId` is the string identifier of the object of interest.
33
- * - `copy=0|1` where `1` indicates the element Id should be copied to the clipboard.
34
- * The command outputs to the IModelApp.notifications the corresponding element Id, or "NOT FOUND".
35
- * @beta
36
- */
37
- export declare class ElementIdFromSourceAspectIdTool extends SourceAspectIdTool {
38
- static toolId: string;
39
- protected getECSql(queryId: string): string;
40
- }
1
+ import { Tool } from "@itwin/core-frontend";
2
+ /** Base class for a tool that can convert between source aspect Ids and element Ids.
3
+ * A "source aspect Id" is a string that identifies an object (such as an element) in the source document from which the iModel originated.
4
+ * For example, if the iModel was produced by the MicroStation bridge, the source aspect Id is usually a V8 element Id.
5
+ * @beta
6
+ */
7
+ export declare abstract class SourceAspectIdTool extends Tool {
8
+ static get minArgs(): number;
9
+ static get maxArgs(): number;
10
+ protected abstract getECSql(queryId: string): string;
11
+ run(idToQuery?: string, copyToClipboard?: boolean): Promise<boolean>;
12
+ parseAndRun(...keyinArgs: string[]): Promise<boolean>;
13
+ private doQuery;
14
+ }
15
+ /** Given a source aspect Id, output the Id of the corresponding element in the iModel.
16
+ * A "source aspect Id" is a string that identifies an object (such as an element) in the source document from which the iModel originated.
17
+ * For example, if the iModel was produced by the MicroStation bridge, the source aspect Id is usually a V8 element Id.
18
+ * Arguments:
19
+ * - `id=elementId` where `elementId` is the numeric Id of the element of interest (e.g., `0x13a6c`; decimal notation is also permitted).
20
+ * - `copy=0|1` where `1` indicates the source aspect Id should be copied to the clipboard.
21
+ * The command outputs to the IModelApp.notifications the corresponding source aspect Id, or "NOT FOUND".
22
+ * @beta
23
+ */
24
+ export declare class SourceAspectIdFromElementIdTool extends SourceAspectIdTool {
25
+ static toolId: string;
26
+ protected getECSql(queryId: string): string;
27
+ }
28
+ /** Given the Id of an element in the iModel, output the source aspect Id of the object in the source document from which the element originated.
29
+ * A "source aspect Id" is a string that identifies an object (such as an element) in the source document from which the iModel originated.
30
+ * For example, if the iModel was produced by the MicroStation bridge, the source aspect Id is usually a V8 element Id.
31
+ * Arguments:
32
+ * - `id=sourceAspectId` where `sourceAspectId` is the string identifier of the object of interest.
33
+ * - `copy=0|1` where `1` indicates the element Id should be copied to the clipboard.
34
+ * The command outputs to the IModelApp.notifications the corresponding element Id, or "NOT FOUND".
35
+ * @beta
36
+ */
37
+ export declare class ElementIdFromSourceAspectIdTool extends SourceAspectIdTool {
38
+ static toolId: string;
39
+ protected getECSql(queryId: string): string;
40
+ }
41
41
  //# sourceMappingURL=SourceAspectIdTools.d.ts.map
@@ -1,81 +1,81 @@
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
- /** @packageDocumentation
6
- * @module Tools
7
- */
8
- import { BentleyError } from "@itwin/core-bentley";
9
- import { QueryRowFormat } from "@itwin/core-common";
10
- import { IModelApp, NotifyMessageDetails, OutputMessagePriority, Tool } from "@itwin/core-frontend";
11
- import { copyStringToClipboard } from "../ClipboardUtilities";
12
- import { parseArgs } from "./parseArgs";
13
- /** Base class for a tool that can convert between source aspect Ids and element Ids.
14
- * A "source aspect Id" is a string that identifies an object (such as an element) in the source document from which the iModel originated.
15
- * For example, if the iModel was produced by the MicroStation bridge, the source aspect Id is usually a V8 element Id.
16
- * @beta
17
- */
18
- export class SourceAspectIdTool extends Tool {
19
- static get minArgs() { return 1; }
20
- static get maxArgs() { return 2; }
21
- async run(idToQuery, copyToClipboard) {
22
- if (typeof idToQuery === "string")
23
- await this.doQuery(idToQuery, true === copyToClipboard);
24
- return true;
25
- }
26
- async parseAndRun(...keyinArgs) {
27
- const args = parseArgs(keyinArgs);
28
- return this.run(args.get("i"), args.getBoolean("c"));
29
- }
30
- async doQuery(queryId, copyToClipboard) {
31
- var _a;
32
- const imodel = (_a = IModelApp.viewManager.selectedView) === null || _a === void 0 ? void 0 : _a.iModel;
33
- if (undefined === imodel)
34
- return;
35
- let resultId;
36
- try {
37
- for await (const row of imodel.query(this.getECSql(queryId), undefined, { rowFormat: QueryRowFormat.UseJsPropertyNames, limit: { count: 1 } }))
38
- resultId = row.resultId;
39
- }
40
- catch (ex) {
41
- resultId = BentleyError.getErrorMessage(ex);
42
- }
43
- if (typeof resultId !== "string")
44
- resultId = "NOT FOUND";
45
- if (copyToClipboard)
46
- copyStringToClipboard(resultId);
47
- const message = `${queryId} => ${resultId}`;
48
- IModelApp.notifications.outputMessage(new NotifyMessageDetails(OutputMessagePriority.Info, message));
49
- }
50
- }
51
- /** Given a source aspect Id, output the Id of the corresponding element in the iModel.
52
- * A "source aspect Id" is a string that identifies an object (such as an element) in the source document from which the iModel originated.
53
- * For example, if the iModel was produced by the MicroStation bridge, the source aspect Id is usually a V8 element Id.
54
- * Arguments:
55
- * - `id=elementId` where `elementId` is the numeric Id of the element of interest (e.g., `0x13a6c`; decimal notation is also permitted).
56
- * - `copy=0|1` where `1` indicates the source aspect Id should be copied to the clipboard.
57
- * The command outputs to the IModelApp.notifications the corresponding source aspect Id, or "NOT FOUND".
58
- * @beta
59
- */
60
- export class SourceAspectIdFromElementIdTool extends SourceAspectIdTool {
61
- getECSql(queryId) {
62
- return `SELECT Identifier as resultId FROM BisCore.ExternalSourceAspect WHERE Element.Id=${queryId} AND [Kind]='Element'`;
63
- }
64
- }
65
- SourceAspectIdFromElementIdTool.toolId = "SourceAspectIdFromElementId";
66
- /** Given the Id of an element in the iModel, output the source aspect Id of the object in the source document from which the element originated.
67
- * A "source aspect Id" is a string that identifies an object (such as an element) in the source document from which the iModel originated.
68
- * For example, if the iModel was produced by the MicroStation bridge, the source aspect Id is usually a V8 element Id.
69
- * Arguments:
70
- * - `id=sourceAspectId` where `sourceAspectId` is the string identifier of the object of interest.
71
- * - `copy=0|1` where `1` indicates the element Id should be copied to the clipboard.
72
- * The command outputs to the IModelApp.notifications the corresponding element Id, or "NOT FOUND".
73
- * @beta
74
- */
75
- export class ElementIdFromSourceAspectIdTool extends SourceAspectIdTool {
76
- getECSql(queryId) {
77
- return `SELECT Element.Id as resultId FROM BisCore.ExternalSourceAspect WHERE Identifier='${queryId}' AND [Kind]='Element'`;
78
- }
79
- }
80
- ElementIdFromSourceAspectIdTool.toolId = "ElementIdFromSourceAspectId";
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
+ /** @packageDocumentation
6
+ * @module Tools
7
+ */
8
+ import { BentleyError } from "@itwin/core-bentley";
9
+ import { QueryRowFormat } from "@itwin/core-common";
10
+ import { IModelApp, NotifyMessageDetails, OutputMessagePriority, Tool } from "@itwin/core-frontend";
11
+ import { copyStringToClipboard } from "../ClipboardUtilities";
12
+ import { parseArgs } from "./parseArgs";
13
+ /** Base class for a tool that can convert between source aspect Ids and element Ids.
14
+ * A "source aspect Id" is a string that identifies an object (such as an element) in the source document from which the iModel originated.
15
+ * For example, if the iModel was produced by the MicroStation bridge, the source aspect Id is usually a V8 element Id.
16
+ * @beta
17
+ */
18
+ export class SourceAspectIdTool extends Tool {
19
+ static get minArgs() { return 1; }
20
+ static get maxArgs() { return 2; }
21
+ async run(idToQuery, copyToClipboard) {
22
+ if (typeof idToQuery === "string")
23
+ await this.doQuery(idToQuery, true === copyToClipboard);
24
+ return true;
25
+ }
26
+ async parseAndRun(...keyinArgs) {
27
+ const args = parseArgs(keyinArgs);
28
+ return this.run(args.get("i"), args.getBoolean("c"));
29
+ }
30
+ async doQuery(queryId, copyToClipboard) {
31
+ var _a;
32
+ const imodel = (_a = IModelApp.viewManager.selectedView) === null || _a === void 0 ? void 0 : _a.iModel;
33
+ if (undefined === imodel)
34
+ return;
35
+ let resultId;
36
+ try {
37
+ for await (const row of imodel.query(this.getECSql(queryId), undefined, { rowFormat: QueryRowFormat.UseJsPropertyNames, limit: { count: 1 } }))
38
+ resultId = row.resultId;
39
+ }
40
+ catch (ex) {
41
+ resultId = BentleyError.getErrorMessage(ex);
42
+ }
43
+ if (typeof resultId !== "string")
44
+ resultId = "NOT FOUND";
45
+ if (copyToClipboard)
46
+ copyStringToClipboard(resultId);
47
+ const message = `${queryId} => ${resultId}`;
48
+ IModelApp.notifications.outputMessage(new NotifyMessageDetails(OutputMessagePriority.Info, message));
49
+ }
50
+ }
51
+ /** Given a source aspect Id, output the Id of the corresponding element in the iModel.
52
+ * A "source aspect Id" is a string that identifies an object (such as an element) in the source document from which the iModel originated.
53
+ * For example, if the iModel was produced by the MicroStation bridge, the source aspect Id is usually a V8 element Id.
54
+ * Arguments:
55
+ * - `id=elementId` where `elementId` is the numeric Id of the element of interest (e.g., `0x13a6c`; decimal notation is also permitted).
56
+ * - `copy=0|1` where `1` indicates the source aspect Id should be copied to the clipboard.
57
+ * The command outputs to the IModelApp.notifications the corresponding source aspect Id, or "NOT FOUND".
58
+ * @beta
59
+ */
60
+ export class SourceAspectIdFromElementIdTool extends SourceAspectIdTool {
61
+ getECSql(queryId) {
62
+ return `SELECT Identifier as resultId FROM BisCore.ExternalSourceAspect WHERE Element.Id=${queryId} AND [Kind]='Element'`;
63
+ }
64
+ }
65
+ SourceAspectIdFromElementIdTool.toolId = "SourceAspectIdFromElementId";
66
+ /** Given the Id of an element in the iModel, output the source aspect Id of the object in the source document from which the element originated.
67
+ * A "source aspect Id" is a string that identifies an object (such as an element) in the source document from which the iModel originated.
68
+ * For example, if the iModel was produced by the MicroStation bridge, the source aspect Id is usually a V8 element Id.
69
+ * Arguments:
70
+ * - `id=sourceAspectId` where `sourceAspectId` is the string identifier of the object of interest.
71
+ * - `copy=0|1` where `1` indicates the element Id should be copied to the clipboard.
72
+ * The command outputs to the IModelApp.notifications the corresponding element Id, or "NOT FOUND".
73
+ * @beta
74
+ */
75
+ export class ElementIdFromSourceAspectIdTool extends SourceAspectIdTool {
76
+ getECSql(queryId) {
77
+ return `SELECT Element.Id as resultId FROM BisCore.ExternalSourceAspect WHERE Identifier='${queryId}' AND [Kind]='Element'`;
78
+ }
79
+ }
80
+ ElementIdFromSourceAspectIdTool.toolId = "ElementIdFromSourceAspectId";
81
81
  //# sourceMappingURL=SourceAspectIdTools.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SourceAspectIdTools.js","sourceRoot":"","sources":["../../../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MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,QAAQ,CAAC,OAAO,CAAC,EAAE,SAAS,EAAE,EAAE,SAAS,EAAE,cAAc,CAAC,kBAAkB,EAAE,KAAK,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE,EAAE,CAAC;gBAC5I,QAAQ,GAAG,GAAG,CAAC,QAAQ,CAAC;SAC3B;QAAC,OAAO,EAAE,EAAE;YACX,QAAQ,GAAG,YAAY,CAAC,eAAe,CAAC,EAAE,CAAC,CAAC;SAC7C;QAED,IAAI,OAAO,QAAQ,KAAK,QAAQ;YAC9B,QAAQ,GAAG,WAAW,CAAC;QAEzB,IAAI,eAAe;YACjB,qBAAqB,CAAC,QAAQ,CAAC,CAAC;QAElC,MAAM,OAAO,GAAG,GAAG,OAAO,OAAO,QAAQ,EAAE,CAAC;QAC5C,SAAS,CAAC,aAAa,CAAC,aAAa,CAAC,IAAI,oBAAoB,CAAC,qBAAqB,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC,CAAC;IACvG,CAAC;CACF;AAED;;;;;;;;GAQG;AACH,MAAM,OAAO,+BAAgC,SAAQ,kBAAkB;IAG3D,QAAQ,CAAC,OAAe;QAChC,OAAO,oFAAoF,OAAO,uBAAuB,CAAC;IAC5H,CAAC;;AAJsB,sCAAM,GAAG,6BAA6B,CAAC;AAOhE;;;;;;;;GAQG;AACH,MAAM,OAAO,+BAAgC,SAAQ,kBAAkB;IAG3D,QAAQ,CAAC,OAAe;QAChC,OAAO,qFAAqF,OAAO,wBAAwB,CAAC;IAC9H,CAAC;;AAJsB,sCAAM,GAAG,6BAA6B,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n\r\n/** @packageDocumentation\r\n * @module Tools\r\n */\r\n\r\nimport { BentleyError } from \"@itwin/core-bentley\";\r\nimport { QueryRowFormat } from \"@itwin/core-common\";\r\nimport { IModelApp, NotifyMessageDetails, OutputMessagePriority, Tool } from \"@itwin/core-frontend\";\r\nimport { copyStringToClipboard } from \"../ClipboardUtilities\";\r\nimport { parseArgs } from \"./parseArgs\";\r\n\r\n/** Base class for a tool that can convert between source aspect Ids and element Ids.\r\n * A \"source aspect Id\" is a string that identifies an object (such as an element) in the source document from which the iModel originated.\r\n * For example, if the iModel was produced by the MicroStation bridge, the source aspect Id is usually a V8 element Id.\r\n * @beta\r\n */\r\nexport abstract class SourceAspectIdTool extends Tool {\r\n public static override get minArgs() { return 1; }\r\n public static override get maxArgs() { return 2; }\r\n\r\n protected abstract getECSql(queryId: string): string;\r\n\r\n public override async run(idToQuery?: string, copyToClipboard?: boolean): Promise<boolean> {\r\n if (typeof idToQuery === \"string\")\r\n await this.doQuery(idToQuery, true === copyToClipboard);\r\n\r\n return true;\r\n }\r\n\r\n public override async parseAndRun(...keyinArgs: string[]): Promise<boolean> {\r\n const args = parseArgs(keyinArgs);\r\n return this.run(args.get(\"i\"), args.getBoolean(\"c\"));\r\n }\r\n\r\n private async doQuery(queryId: string, copyToClipboard: boolean): Promise<void> {\r\n const imodel = IModelApp.viewManager.selectedView?.iModel;\r\n if (undefined === imodel)\r\n return;\r\n\r\n let resultId;\r\n try {\r\n for await (const row of imodel.query(this.getECSql(queryId), undefined, { rowFormat: QueryRowFormat.UseJsPropertyNames, limit: { count: 1 } }))\r\n resultId = row.resultId;\r\n } catch (ex) {\r\n resultId = BentleyError.getErrorMessage(ex);\r\n }\r\n\r\n if (typeof resultId !== \"string\")\r\n resultId = \"NOT FOUND\";\r\n\r\n if (copyToClipboard)\r\n copyStringToClipboard(resultId);\r\n\r\n const message = `${queryId} => ${resultId}`;\r\n IModelApp.notifications.outputMessage(new NotifyMessageDetails(OutputMessagePriority.Info, message));\r\n }\r\n}\r\n\r\n/** Given a source aspect Id, output the Id of the corresponding element in the iModel.\r\n * A \"source aspect Id\" is a string that identifies an object (such as an element) in the source document from which the iModel originated.\r\n * For example, if the iModel was produced by the MicroStation bridge, the source aspect Id is usually a V8 element Id.\r\n * Arguments:\r\n * - `id=elementId` where `elementId` is the numeric Id of the element of interest (e.g., `0x13a6c`; decimal notation is also permitted).\r\n * - `copy=0|1` where `1` indicates the source aspect Id should be copied to the clipboard.\r\n * The command outputs to the IModelApp.notifications the corresponding source aspect Id, or \"NOT FOUND\".\r\n * @beta\r\n */\r\nexport class SourceAspectIdFromElementIdTool extends SourceAspectIdTool {\r\n public static override toolId = \"SourceAspectIdFromElementId\";\r\n\r\n protected getECSql(queryId: string): string {\r\n return `SELECT Identifier as resultId FROM BisCore.ExternalSourceAspect WHERE Element.Id=${queryId} AND [Kind]='Element'`;\r\n }\r\n}\r\n\r\n/** Given the Id of an element in the iModel, output the source aspect Id of the object in the source document from which the element originated.\r\n * A \"source aspect Id\" is a string that identifies an object (such as an element) in the source document from which the iModel originated.\r\n * For example, if the iModel was produced by the MicroStation bridge, the source aspect Id is usually a V8 element Id.\r\n * Arguments:\r\n * - `id=sourceAspectId` where `sourceAspectId` is the string identifier of the object of interest.\r\n * - `copy=0|1` where `1` indicates the element Id should be copied to the clipboard.\r\n * The command outputs to the IModelApp.notifications the corresponding element Id, or \"NOT FOUND\".\r\n * @beta\r\n */\r\nexport class ElementIdFromSourceAspectIdTool extends SourceAspectIdTool {\r\n public static override toolId = \"ElementIdFromSourceAspectId\";\r\n\r\n protected getECSql(queryId: string): string {\r\n return `SELECT Element.Id as resultId FROM BisCore.ExternalSourceAspect WHERE Identifier='${queryId}' AND [Kind]='Element'`;\r\n }\r\n}\r\n"]}
1
+ {"version":3,"file":"SourceAspectIdTools.js","sourceRoot":"","sources":["../../../src/tools/SourceAspectIdTools.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAE/F;;GAEG;AAEH,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAAE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QAAQ,GAAG,GAAG,CAAC,QAAQ,CAAC;SAC3B;QAAC,OAAO,EAAE,EAAE;YACX,QAAQ,GAAG,YAAY,CAAC,eAAe,CAAC,EAAE,CAAC,CAAC;SAC7C;QAED,IAAI,OAAO,QAAQ,KAAK,QAAQ;YAC9B,QAAQ,GAAG,WAAW,CAAC;QAEzB,IAAI,eAAe;YACjB,qBAAqB,CAAC,QAAQ,CAAC,CAAC;QAElC,MAAM,OAAO,GAAG,GAAG,OAAO,OAAO,QAAQ,EAAE,CAAC;QAC5C,SAAS,CAAC,aAAa,CAAC,aAAa,CAAC,IAAI,oBAAoB,CAAC,qBAAqB,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC,CAAC;IACvG,CAAC;CACF;AAED;;;;;;;;GAQG;AACH,MAAM,OAAO,+BAAgC,SAAQ,kBAAkB;IAG3D,QAAQ,CAAC,OAAe;QAChC,OAAO,oFAAoF,OAAO,uBAAuB,CAAC;IAC5H,CAAC;;AAJsB,sCAAM,GAAG,6BAA6B,CAAC;AAOhE;;;;;;;;GAQG;AACH,MAAM,OAAO,+BAAgC,SAAQ,kBAAkB;IAG3D,QAAQ,CAAC,OAAe;QAChC,OAAO,qFAAqF,OAAO,wBAAwB,CAAC;IAC9H,CAAC;;AAJsB,sCAAM,GAAG,6BAA6B,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\n\n/** @packageDocumentation\n * @module Tools\n */\n\nimport { BentleyError } from \"@itwin/core-bentley\";\nimport { QueryRowFormat } from \"@itwin/core-common\";\nimport { IModelApp, NotifyMessageDetails, OutputMessagePriority, Tool } from \"@itwin/core-frontend\";\nimport { copyStringToClipboard } from \"../ClipboardUtilities\";\nimport { parseArgs } from \"./parseArgs\";\n\n/** Base class for a tool that can convert between source aspect Ids and element Ids.\n * A \"source aspect Id\" is a string that identifies an object (such as an element) in the source document from which the iModel originated.\n * For example, if the iModel was produced by the MicroStation bridge, the source aspect Id is usually a V8 element Id.\n * @beta\n */\nexport abstract class SourceAspectIdTool extends Tool {\n public static override get minArgs() { return 1; }\n public static override get maxArgs() { return 2; }\n\n protected abstract getECSql(queryId: string): string;\n\n public override async run(idToQuery?: string, copyToClipboard?: boolean): Promise<boolean> {\n if (typeof idToQuery === \"string\")\n await this.doQuery(idToQuery, true === copyToClipboard);\n\n return true;\n }\n\n public override async parseAndRun(...keyinArgs: string[]): Promise<boolean> {\n const args = parseArgs(keyinArgs);\n return this.run(args.get(\"i\"), args.getBoolean(\"c\"));\n }\n\n private async doQuery(queryId: string, copyToClipboard: boolean): Promise<void> {\n const imodel = IModelApp.viewManager.selectedView?.iModel;\n if (undefined === imodel)\n return;\n\n let resultId;\n try {\n for await (const row of imodel.query(this.getECSql(queryId), undefined, { rowFormat: QueryRowFormat.UseJsPropertyNames, limit: { count: 1 } }))\n resultId = row.resultId;\n } catch (ex) {\n resultId = BentleyError.getErrorMessage(ex);\n }\n\n if (typeof resultId !== \"string\")\n resultId = \"NOT FOUND\";\n\n if (copyToClipboard)\n copyStringToClipboard(resultId);\n\n const message = `${queryId} => ${resultId}`;\n IModelApp.notifications.outputMessage(new NotifyMessageDetails(OutputMessagePriority.Info, message));\n }\n}\n\n/** Given a source aspect Id, output the Id of the corresponding element in the iModel.\n * A \"source aspect Id\" is a string that identifies an object (such as an element) in the source document from which the iModel originated.\n * For example, if the iModel was produced by the MicroStation bridge, the source aspect Id is usually a V8 element Id.\n * Arguments:\n * - `id=elementId` where `elementId` is the numeric Id of the element of interest (e.g., `0x13a6c`; decimal notation is also permitted).\n * - `copy=0|1` where `1` indicates the source aspect Id should be copied to the clipboard.\n * The command outputs to the IModelApp.notifications the corresponding source aspect Id, or \"NOT FOUND\".\n * @beta\n */\nexport class SourceAspectIdFromElementIdTool extends SourceAspectIdTool {\n public static override toolId = \"SourceAspectIdFromElementId\";\n\n protected getECSql(queryId: string): string {\n return `SELECT Identifier as resultId FROM BisCore.ExternalSourceAspect WHERE Element.Id=${queryId} AND [Kind]='Element'`;\n }\n}\n\n/** Given the Id of an element in the iModel, output the source aspect Id of the object in the source document from which the element originated.\n * A \"source aspect Id\" is a string that identifies an object (such as an element) in the source document from which the iModel originated.\n * For example, if the iModel was produced by the MicroStation bridge, the source aspect Id is usually a V8 element Id.\n * Arguments:\n * - `id=sourceAspectId` where `sourceAspectId` is the string identifier of the object of interest.\n * - `copy=0|1` where `1` indicates the element Id should be copied to the clipboard.\n * The command outputs to the IModelApp.notifications the corresponding element Id, or \"NOT FOUND\".\n * @beta\n */\nexport class ElementIdFromSourceAspectIdTool extends SourceAspectIdTool {\n public static override toolId = \"ElementIdFromSourceAspectId\";\n\n protected getECSql(queryId: string): string {\n return `SELECT Element.Id as resultId FROM BisCore.ExternalSourceAspect WHERE Identifier='${queryId}' AND [Kind]='Element'`;\n }\n}\n"]}
@@ -1,13 +1,13 @@
1
- import { Tool } from "@itwin/core-frontend";
2
- /** Display in every viewport a range graphic for every tile currently being requested for the viewport that was initially selected when the decorator was installed.
3
- * Green indicates queued (http request not yet sent), red indicates active (http request sent). White indicates unexpected state.
4
- * @beta
5
- */
6
- export declare class ToggleTileRequestDecorationTool extends Tool {
7
- static toolId: string;
8
- static get minArgs(): number;
9
- static get maxArgs(): number;
10
- run(enable?: boolean): Promise<boolean>;
11
- parseAndRun(...args: string[]): Promise<boolean>;
12
- }
1
+ import { Tool } from "@itwin/core-frontend";
2
+ /** Display in every viewport a range graphic for every tile currently being requested for the viewport that was initially selected when the decorator was installed.
3
+ * Green indicates queued (http request not yet sent), red indicates active (http request sent). White indicates unexpected state.
4
+ * @beta
5
+ */
6
+ export declare class ToggleTileRequestDecorationTool extends Tool {
7
+ static toolId: string;
8
+ static get minArgs(): number;
9
+ static get maxArgs(): number;
10
+ run(enable?: boolean): Promise<boolean>;
11
+ parseAndRun(...args: string[]): Promise<boolean>;
12
+ }
13
13
  //# sourceMappingURL=TileRequestDecoration.d.ts.map
@@ -1,80 +1,80 @@
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
- /** @packageDocumentation
6
- * @module Tools
7
- */
8
- import { ColorDef, LinePixels } from "@itwin/core-common";
9
- import { GraphicType, IModelApp, Tool } from "@itwin/core-frontend";
10
- import { parseToggle } from "./parseToggle";
11
- class TileRequestDecoration {
12
- constructor(vp) {
13
- /** This will allow the render system to cache and reuse the decorations created by this decorator's decorate() method. */
14
- this.useCachedDecorations = true;
15
- this._targetVp = vp;
16
- this._removeDecorator = IModelApp.viewManager.addDecorator(this);
17
- }
18
- stop() {
19
- if (this._removeDecorator) {
20
- this._removeDecorator();
21
- this._removeDecorator = undefined;
22
- }
23
- }
24
- decorate(context) {
25
- const tiles = IModelApp.tileAdmin.getRequestsForUser(this._targetVp);
26
- if (undefined === tiles)
27
- return;
28
- const map = new Map();
29
- for (const tile of tiles) {
30
- let builder = map.get(tile.tree);
31
- if (undefined === builder) {
32
- builder = context.createGraphicBuilder(GraphicType.WorldDecoration, tile.tree.iModelTransform);
33
- map.set(tile.tree, builder);
34
- }
35
- let color = ColorDef.white;
36
- if (undefined !== tile.request)
37
- color = tile.request.isQueued ? ColorDef.green : ColorDef.red;
38
- builder.setSymbology(color, color, 1, LinePixels.Solid);
39
- builder.addRangeBox(tile.range);
40
- }
41
- for (const builder of map.values())
42
- context.addDecorationFromBuilder(builder);
43
- }
44
- static toggle(vp, enabled) {
45
- const instance = TileRequestDecoration._instance;
46
- if (undefined !== enabled) {
47
- if ((undefined !== instance) === enabled)
48
- return;
49
- }
50
- if (undefined === instance) {
51
- TileRequestDecoration._instance = new TileRequestDecoration(vp);
52
- }
53
- else {
54
- instance.stop();
55
- TileRequestDecoration._instance = undefined;
56
- }
57
- }
58
- }
59
- /** Display in every viewport a range graphic for every tile currently being requested for the viewport that was initially selected when the decorator was installed.
60
- * Green indicates queued (http request not yet sent), red indicates active (http request sent). White indicates unexpected state.
61
- * @beta
62
- */
63
- export class ToggleTileRequestDecorationTool extends Tool {
64
- static get minArgs() { return 0; }
65
- static get maxArgs() { return 1; }
66
- async run(enable) {
67
- const vp = IModelApp.viewManager.selectedView;
68
- if (undefined !== vp)
69
- TileRequestDecoration.toggle(vp, enable);
70
- return true;
71
- }
72
- async parseAndRun(...args) {
73
- const enable = parseToggle(args[0]);
74
- if (typeof enable !== "string")
75
- await this.run(enable);
76
- return true;
77
- }
78
- }
79
- ToggleTileRequestDecorationTool.toolId = "ToggleTileRequestDecoration";
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
+ /** @packageDocumentation
6
+ * @module Tools
7
+ */
8
+ import { ColorDef, LinePixels } from "@itwin/core-common";
9
+ import { GraphicType, IModelApp, Tool } from "@itwin/core-frontend";
10
+ import { parseToggle } from "./parseToggle";
11
+ class TileRequestDecoration {
12
+ constructor(vp) {
13
+ /** This will allow the render system to cache and reuse the decorations created by this decorator's decorate() method. */
14
+ this.useCachedDecorations = true;
15
+ this._targetVp = vp;
16
+ this._removeDecorator = IModelApp.viewManager.addDecorator(this);
17
+ }
18
+ stop() {
19
+ if (this._removeDecorator) {
20
+ this._removeDecorator();
21
+ this._removeDecorator = undefined;
22
+ }
23
+ }
24
+ decorate(context) {
25
+ const tiles = IModelApp.tileAdmin.getRequestsForUser(this._targetVp);
26
+ if (undefined === tiles)
27
+ return;
28
+ const map = new Map();
29
+ for (const tile of tiles) {
30
+ let builder = map.get(tile.tree);
31
+ if (undefined === builder) {
32
+ builder = context.createGraphicBuilder(GraphicType.WorldDecoration, tile.tree.iModelTransform);
33
+ map.set(tile.tree, builder);
34
+ }
35
+ let color = ColorDef.white;
36
+ if (undefined !== tile.request)
37
+ color = tile.request.isQueued ? ColorDef.green : ColorDef.red;
38
+ builder.setSymbology(color, color, 1, LinePixels.Solid);
39
+ builder.addRangeBox(tile.range);
40
+ }
41
+ for (const builder of map.values())
42
+ context.addDecorationFromBuilder(builder);
43
+ }
44
+ static toggle(vp, enabled) {
45
+ const instance = TileRequestDecoration._instance;
46
+ if (undefined !== enabled) {
47
+ if ((undefined !== instance) === enabled)
48
+ return;
49
+ }
50
+ if (undefined === instance) {
51
+ TileRequestDecoration._instance = new TileRequestDecoration(vp);
52
+ }
53
+ else {
54
+ instance.stop();
55
+ TileRequestDecoration._instance = undefined;
56
+ }
57
+ }
58
+ }
59
+ /** Display in every viewport a range graphic for every tile currently being requested for the viewport that was initially selected when the decorator was installed.
60
+ * Green indicates queued (http request not yet sent), red indicates active (http request sent). White indicates unexpected state.
61
+ * @beta
62
+ */
63
+ export class ToggleTileRequestDecorationTool extends Tool {
64
+ static get minArgs() { return 0; }
65
+ static get maxArgs() { return 1; }
66
+ async run(enable) {
67
+ const vp = IModelApp.viewManager.selectedView;
68
+ if (undefined !== vp)
69
+ TileRequestDecoration.toggle(vp, enable);
70
+ return true;
71
+ }
72
+ async parseAndRun(...args) {
73
+ const enable = parseToggle(args[0]);
74
+ if (typeof enable !== "string")
75
+ await this.run(enable);
76
+ return true;
77
+ }
78
+ }
79
+ ToggleTileRequestDecorationTool.toolId = "ToggleTileRequestDecoration";
80
80
  //# sourceMappingURL=TileRequestDecoration.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"TileRequestDecoration.js","sourceRoot":"","sources":["../../../src/tools/TileRequestDecoration.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAE/F;;GAEG;AAEH,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAC1D,OAAO,EAAmC,WAAW,EAAE,SAAS,EAAY,IAAI,EAAY,MAAM,sBAAsB,CAAC;AACzH,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAE5C,MAAM,qB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AAC,CAAC;QAEzB,OAAO,IAAI,CAAC;IACd,CAAC;;AAlBsB,sCAAM,GAAG,6BAA6B,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n\r\n/** @packageDocumentation\r\n * @module Tools\r\n */\r\n\r\nimport { ColorDef, LinePixels } from \"@itwin/core-common\";\r\nimport { DecorateContext, GraphicBuilder, GraphicType, IModelApp, TileTree, Tool, Viewport } from \"@itwin/core-frontend\";\r\nimport { parseToggle } from \"./parseToggle\";\r\n\r\nclass TileRequestDecoration {\r\n private static _instance?: TileRequestDecoration;\r\n private _removeDecorator?: () => void;\r\n private readonly _targetVp: Viewport;\r\n\r\n private constructor(vp: Viewport) {\r\n this._targetVp = vp;\r\n this._removeDecorator = IModelApp.viewManager.addDecorator(this);\r\n }\r\n\r\n private stop(): void {\r\n if (this._removeDecorator) {\r\n this._removeDecorator();\r\n this._removeDecorator = undefined;\r\n }\r\n }\r\n\r\n /** This will allow the render system to cache and reuse the decorations created by this decorator's decorate() method. */\r\n public readonly useCachedDecorations = true;\r\n\r\n public decorate(context: DecorateContext): void {\r\n const tiles = IModelApp.tileAdmin.getRequestsForUser(this._targetVp);\r\n if (undefined === tiles)\r\n return;\r\n\r\n const map = new Map<TileTree, GraphicBuilder>();\r\n for (const tile of tiles) {\r\n let builder = map.get(tile.tree);\r\n if (undefined === builder) {\r\n builder = context.createGraphicBuilder(GraphicType.WorldDecoration, tile.tree.iModelTransform);\r\n map.set(tile.tree, builder);\r\n }\r\n\r\n let color = ColorDef.white;\r\n if (undefined !== tile.request)\r\n color = tile.request.isQueued ? ColorDef.green : ColorDef.red;\r\n\r\n builder.setSymbology(color, color, 1, LinePixels.Solid);\r\n builder.addRangeBox(tile.range);\r\n }\r\n\r\n for (const builder of map.values())\r\n context.addDecorationFromBuilder(builder);\r\n }\r\n\r\n public static toggle(vp: Viewport, enabled?: boolean): void {\r\n const instance = TileRequestDecoration._instance;\r\n if (undefined !== enabled) {\r\n if ((undefined !== instance) === enabled)\r\n return;\r\n }\r\n\r\n if (undefined === instance) {\r\n TileRequestDecoration._instance = new TileRequestDecoration(vp);\r\n } else {\r\n instance.stop();\r\n TileRequestDecoration._instance = undefined;\r\n }\r\n }\r\n}\r\n\r\n/** Display in every viewport a range graphic for every tile currently being requested for the viewport that was initially selected when the decorator was installed.\r\n * Green indicates queued (http request not yet sent), red indicates active (http request sent). White indicates unexpected state.\r\n * @beta\r\n */\r\nexport class ToggleTileRequestDecorationTool extends Tool {\r\n public static override toolId = \"ToggleTileRequestDecoration\";\r\n public static override get minArgs() { return 0; }\r\n public static override get maxArgs() { return 1; }\r\n\r\n public override async run(enable?: boolean): Promise<boolean> {\r\n const vp = IModelApp.viewManager.selectedView;\r\n if (undefined !== vp)\r\n TileRequestDecoration.toggle(vp, enable);\r\n\r\n return true;\r\n }\r\n\r\n public override async parseAndRun(...args: string[]): Promise<boolean> {\r\n const enable = parseToggle(args[0]);\r\n if (typeof enable !== \"string\")\r\n await this.run(enable);\r\n\r\n return true;\r\n }\r\n}\r\n"]}
1
+ {"version":3,"file":"TileRequestDecoration.js","sourceRoot":"","sources":["../../../src/tools/TileRequestDecoration.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAE/F;;GAEG;AAEH,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAC1D,OAAO,EAAmC,WAAW,EAAE,SAAS,EAAY,IAAI,EAAY,MAAM,sBAAsB,CAAC;AACzH,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAE5C,MAAM,qBAAqB;IAKzB,YAAoB,EAAY;QAYhC,0HAA0H;QAC1G,yBAAoB,GAAG,IAAI,CAAC;QAZ1C,IAAI,CAAC,SAAS,GAAG,EAAE,CAAC;QACpB,IAAI,CAAC,gBAAgB,GAAG,SAAS,CAAC,W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C,OAAO,CAAC,CAAC;IAC9C,CAAC;IAEM,MAAM,CAAC,MAAM,CAAC,EAAY,EAAE,OAAiB;QAClD,MAAM,QAAQ,GAAG,qBAAqB,CAAC,SAAS,CAAC;QACjD,IAAI,SAAS,KAAK,OAAO,EAAE;YACzB,IAAI,CAAC,SAAS,KAAK,QAAQ,CAAC,KAAK,OAAO;gBACtC,OAAO;SACV;QAED,IAAI,SAAS,KAAK,QAAQ,EAAE;YAC1B,qBAAqB,CAAC,SAAS,GAAG,IAAI,qBAAqB,CAAC,EAAE,CAAC,CAAC;SACjE;aAAM;YACL,QAAQ,CAAC,IAAI,EAAE,CAAC;YAChB,qBAAqB,CAAC,SAAS,GAAG,SAAS,CAAC;SAC7C;IACH,CAAC;CACF;AAED;;;GAGG;AACH,MAAM,OAAO,+BAAgC,SAAQ,IAAI;IAEhD,MAAM,KAAc,OAAO,KAAK,OAAO,CAAC,CAAC,CAAC,CAAC;IAC3C,MAAM,KAAc,OAAO,KAAK,OAAO,CAAC,CAAC,CAAC,CAAC;IAElC,KAAK,CAAC,GAAG,CAAC,MAAgB;QACxC,MAAM,EAAE,GAAG,SAAS,CAAC,WAAW,CAAC,YAAY,CAAC;QAC9C,IAAI,SAAS,KAAK,EAAE;YAClB,qBAAqB,CAAC,MAAM,CAAC,EAAE,EAAE,MAAM,CAAC,CAAC;QAE3C,OAAO,IAAI,CAAC;IACd,CAAC;IAEe,KAAK,CAAC,WAAW,CAAC,GAAG,IAAc;QACjD,MAAM,MAAM,GAAG,WAAW,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC;QACpC,IAAI,OAAO,MAAM,KAAK,QAAQ;YAC5B,MAAM,IAAI,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;QAEzB,OAAO,IAAI,CAAC;IACd,CAAC;;AAlBsB,sCAAM,GAAG,6BAA6B,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\n\n/** @packageDocumentation\n * @module Tools\n */\n\nimport { ColorDef, LinePixels } from \"@itwin/core-common\";\nimport { DecorateContext, GraphicBuilder, GraphicType, IModelApp, TileTree, Tool, Viewport } from \"@itwin/core-frontend\";\nimport { parseToggle } from \"./parseToggle\";\n\nclass TileRequestDecoration {\n private static _instance?: TileRequestDecoration;\n private _removeDecorator?: () => void;\n private readonly _targetVp: Viewport;\n\n private constructor(vp: Viewport) {\n this._targetVp = vp;\n this._removeDecorator = IModelApp.viewManager.addDecorator(this);\n }\n\n private stop(): void {\n if (this._removeDecorator) {\n this._removeDecorator();\n this._removeDecorator = undefined;\n }\n }\n\n /** This will allow the render system to cache and reuse the decorations created by this decorator's decorate() method. */\n public readonly useCachedDecorations = true;\n\n public decorate(context: DecorateContext): void {\n const tiles = IModelApp.tileAdmin.getRequestsForUser(this._targetVp);\n if (undefined === tiles)\n return;\n\n const map = new Map<TileTree, GraphicBuilder>();\n for (const tile of tiles) {\n let builder = map.get(tile.tree);\n if (undefined === builder) {\n builder = context.createGraphicBuilder(GraphicType.WorldDecoration, tile.tree.iModelTransform);\n map.set(tile.tree, builder);\n }\n\n let color = ColorDef.white;\n if (undefined !== tile.request)\n color = tile.request.isQueued ? ColorDef.green : ColorDef.red;\n\n builder.setSymbology(color, color, 1, LinePixels.Solid);\n builder.addRangeBox(tile.range);\n }\n\n for (const builder of map.values())\n context.addDecorationFromBuilder(builder);\n }\n\n public static toggle(vp: Viewport, enabled?: boolean): void {\n const instance = TileRequestDecoration._instance;\n if (undefined !== enabled) {\n if ((undefined !== instance) === enabled)\n return;\n }\n\n if (undefined === instance) {\n TileRequestDecoration._instance = new TileRequestDecoration(vp);\n } else {\n instance.stop();\n TileRequestDecoration._instance = undefined;\n }\n }\n}\n\n/** Display in every viewport a range graphic for every tile currently being requested for the viewport that was initially selected when the decorator was installed.\n * Green indicates queued (http request not yet sent), red indicates active (http request sent). White indicates unexpected state.\n * @beta\n */\nexport class ToggleTileRequestDecorationTool extends Tool {\n public static override toolId = \"ToggleTileRequestDecoration\";\n public static override get minArgs() { return 0; }\n public static override get maxArgs() { return 1; }\n\n public override async run(enable?: boolean): Promise<boolean> {\n const vp = IModelApp.viewManager.selectedView;\n if (undefined !== vp)\n TileRequestDecoration.toggle(vp, enable);\n\n return true;\n }\n\n public override async parseAndRun(...args: string[]): Promise<boolean> {\n const enable = parseToggle(args[0]);\n if (typeof enable !== \"string\")\n await this.run(enable);\n\n return true;\n }\n}\n"]}