@perses-dev/plugin-system 0.55.0-beta.3 → 0.55.0-beta.6

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 (550) hide show
  1. package/dist/components/Annotations/AnnotationEditorForm/AnnotationEditorForm.d.ts +3 -3
  2. package/dist/components/Annotations/AnnotationEditorForm/AnnotationEditorForm.d.ts.map +1 -1
  3. package/dist/components/Annotations/AnnotationEditorForm/AnnotationEditorForm.js +11 -11
  4. package/dist/components/Annotations/AnnotationEditorForm/AnnotationEditorForm.js.map +1 -1
  5. package/dist/components/Annotations/AnnotationEditorForm/AnnotationPreview.d.ts +3 -3
  6. package/dist/components/Annotations/AnnotationEditorForm/AnnotationPreview.d.ts.map +1 -1
  7. package/dist/components/Annotations/AnnotationEditorForm/AnnotationPreview.js +6 -6
  8. package/dist/components/Annotations/AnnotationEditorForm/AnnotationPreview.js.map +1 -1
  9. package/dist/components/Annotations/AnnotationEditorForm/index.js +1 -1
  10. package/dist/components/Annotations/AnnotationEditorForm/index.js.map +1 -1
  11. package/dist/components/Annotations/index.js +2 -2
  12. package/dist/components/Annotations/index.js.map +1 -1
  13. package/dist/components/CalculationSelector/CalculationSelector.d.ts +2 -2
  14. package/dist/components/CalculationSelector/CalculationSelector.d.ts.map +1 -1
  15. package/dist/components/CalculationSelector/CalculationSelector.js +2 -2
  16. package/dist/components/CalculationSelector/CalculationSelector.js.map +1 -1
  17. package/dist/components/CalculationSelector/index.js +1 -1
  18. package/dist/components/CalculationSelector/index.js.map +1 -1
  19. package/dist/components/DatasourceEditorForm/DatasourceEditorForm.d.ts +2 -2
  20. package/dist/components/DatasourceEditorForm/DatasourceEditorForm.d.ts.map +1 -1
  21. package/dist/components/DatasourceEditorForm/DatasourceEditorForm.js +7 -7
  22. package/dist/components/DatasourceEditorForm/DatasourceEditorForm.js.map +1 -1
  23. package/dist/components/DatasourceEditorForm/index.js +1 -1
  24. package/dist/components/DatasourceEditorForm/index.js.map +1 -1
  25. package/dist/components/DatasourceSelect/DatasourceSelect.d.ts +4 -4
  26. package/dist/components/DatasourceSelect/DatasourceSelect.d.ts.map +1 -1
  27. package/dist/components/DatasourceSelect/DatasourceSelect.js +7 -7
  28. package/dist/components/DatasourceSelect/DatasourceSelect.js.map +1 -1
  29. package/dist/components/DatasourceSelect/index.js +1 -1
  30. package/dist/components/DatasourceSelect/index.js.map +1 -1
  31. package/dist/components/DatasourceTestConnectionButton/DatasourceTestConnectionButton.d.ts +2 -2
  32. package/dist/components/DatasourceTestConnectionButton/DatasourceTestConnectionButton.d.ts.map +1 -1
  33. package/dist/components/DatasourceTestConnectionButton/DatasourceTestConnectionButton.js +4 -4
  34. package/dist/components/DatasourceTestConnectionButton/DatasourceTestConnectionButton.js.map +1 -1
  35. package/dist/components/DatasourceTestConnectionButton/index.js +1 -1
  36. package/dist/components/DatasourceTestConnectionButton/index.js.map +1 -1
  37. package/dist/components/HTTPSettingsEditor/HTTPSettingsEditor.d.ts +2 -2
  38. package/dist/components/HTTPSettingsEditor/HTTPSettingsEditor.d.ts.map +1 -1
  39. package/dist/components/HTTPSettingsEditor/HTTPSettingsEditor.js +9 -9
  40. package/dist/components/HTTPSettingsEditor/HTTPSettingsEditor.js.map +1 -1
  41. package/dist/components/HTTPSettingsEditor/index.js +1 -1
  42. package/dist/components/HTTPSettingsEditor/index.js.map +1 -1
  43. package/dist/components/ItemSelectionActionsOptionsEditor/ItemSelectionActionsOptionsEditor.d.ts +1 -1
  44. package/dist/components/ItemSelectionActionsOptionsEditor/ItemSelectionActionsOptionsEditor.d.ts.map +1 -1
  45. package/dist/components/ItemSelectionActionsOptionsEditor/ItemSelectionActionsOptionsEditor.js +24 -24
  46. package/dist/components/ItemSelectionActionsOptionsEditor/ItemSelectionActionsOptionsEditor.js.map +1 -1
  47. package/dist/components/ItemSelectionActionsOptionsEditor/index.js +1 -1
  48. package/dist/components/ItemSelectionActionsOptionsEditor/index.js.map +1 -1
  49. package/dist/components/LayoutEditor/LayoutEditor.d.ts +4 -4
  50. package/dist/components/LayoutEditor/LayoutEditor.d.ts.map +1 -1
  51. package/dist/components/LayoutEditor/LayoutEditor.js +7 -7
  52. package/dist/components/LayoutEditor/LayoutEditor.js.map +1 -1
  53. package/dist/components/LayoutEditor/RepeatLayoutPreview.d.ts +1 -1
  54. package/dist/components/LayoutEditor/RepeatLayoutPreview.d.ts.map +1 -1
  55. package/dist/components/LayoutEditor/RepeatLayoutPreview.js +4 -4
  56. package/dist/components/LayoutEditor/RepeatLayoutPreview.js.map +1 -1
  57. package/dist/components/LayoutEditor/RepeatVariableEditor.d.ts +4 -4
  58. package/dist/components/LayoutEditor/RepeatVariableEditor.d.ts.map +1 -1
  59. package/dist/components/LayoutEditor/RepeatVariableEditor.js +3 -3
  60. package/dist/components/LayoutEditor/RepeatVariableEditor.js.map +1 -1
  61. package/dist/components/LayoutEditor/index.js +3 -3
  62. package/dist/components/LayoutEditor/index.js.map +1 -1
  63. package/dist/components/LegendOptionsEditor/LegendOptionsEditor.d.ts +2 -2
  64. package/dist/components/LegendOptionsEditor/LegendOptionsEditor.d.ts.map +1 -1
  65. package/dist/components/LegendOptionsEditor/LegendOptionsEditor.js +5 -5
  66. package/dist/components/LegendOptionsEditor/LegendOptionsEditor.js.map +1 -1
  67. package/dist/components/LegendOptionsEditor/index.js +1 -1
  68. package/dist/components/LegendOptionsEditor/index.js.map +1 -1
  69. package/dist/components/LinksEditor/LinksEditor.d.ts +3 -3
  70. package/dist/components/LinksEditor/LinksEditor.d.ts.map +1 -1
  71. package/dist/components/LinksEditor/LinksEditor.js +6 -6
  72. package/dist/components/LinksEditor/LinksEditor.js.map +1 -1
  73. package/dist/components/LinksEditor/index.js +1 -1
  74. package/dist/components/LinksEditor/index.js.map +1 -1
  75. package/dist/components/MetricLabelInput/MetricLabelInput.d.ts +1 -1
  76. package/dist/components/MetricLabelInput/MetricLabelInput.d.ts.map +1 -1
  77. package/dist/components/MetricLabelInput/MetricLabelInput.js +2 -2
  78. package/dist/components/MetricLabelInput/MetricLabelInput.js.map +1 -1
  79. package/dist/components/MetricLabelInput/index.js +1 -1
  80. package/dist/components/MetricLabelInput/index.js.map +1 -1
  81. package/dist/components/MultiQueryEditor/MultiQueryEditor.d.ts +3 -3
  82. package/dist/components/MultiQueryEditor/MultiQueryEditor.d.ts.map +1 -1
  83. package/dist/components/MultiQueryEditor/MultiQueryEditor.js +6 -6
  84. package/dist/components/MultiQueryEditor/MultiQueryEditor.js.map +1 -1
  85. package/dist/components/MultiQueryEditor/QueryEditorContainer.d.ts +3 -3
  86. package/dist/components/MultiQueryEditor/QueryEditorContainer.d.ts.map +1 -1
  87. package/dist/components/MultiQueryEditor/QueryEditorContainer.js +14 -14
  88. package/dist/components/MultiQueryEditor/QueryEditorContainer.js.map +1 -1
  89. package/dist/components/MultiQueryEditor/index.js +2 -2
  90. package/dist/components/MultiQueryEditor/index.js.map +1 -1
  91. package/dist/components/MultiQueryEditor/utils.d.ts +1 -1
  92. package/dist/components/MultiQueryEditor/utils.d.ts.map +1 -1
  93. package/dist/components/MultiQueryEditor/utils.js.map +1 -1
  94. package/dist/components/OptionsEditorRadios/OptionsEditorRadios.d.ts +1 -1
  95. package/dist/components/OptionsEditorRadios/OptionsEditorRadios.d.ts.map +1 -1
  96. package/dist/components/OptionsEditorRadios/OptionsEditorRadios.js +4 -4
  97. package/dist/components/OptionsEditorRadios/OptionsEditorRadios.js.map +1 -1
  98. package/dist/components/OptionsEditorRadios/index.js +1 -1
  99. package/dist/components/OptionsEditorRadios/index.js.map +1 -1
  100. package/dist/components/OptionsEditorTabPanel/OptionsEditorTabPanel.d.ts +1 -1
  101. package/dist/components/OptionsEditorTabPanel/OptionsEditorTabPanel.d.ts.map +1 -1
  102. package/dist/components/OptionsEditorTabPanel/OptionsEditorTabPanel.js +1 -1
  103. package/dist/components/OptionsEditorTabPanel/OptionsEditorTabPanel.js.map +1 -1
  104. package/dist/components/OptionsEditorTabPanel/index.js +1 -1
  105. package/dist/components/OptionsEditorTabPanel/index.js.map +1 -1
  106. package/dist/components/OptionsEditorTabs/OptionsEditorTabs.d.ts +1 -1
  107. package/dist/components/OptionsEditorTabs/OptionsEditorTabs.d.ts.map +1 -1
  108. package/dist/components/OptionsEditorTabs/OptionsEditorTabs.js +4 -4
  109. package/dist/components/OptionsEditorTabs/OptionsEditorTabs.js.map +1 -1
  110. package/dist/components/OptionsEditorTabs/index.js +1 -1
  111. package/dist/components/OptionsEditorTabs/index.js.map +1 -1
  112. package/dist/components/PanelSpecEditor/PanelAnnotationsEditor.d.ts +2 -2
  113. package/dist/components/PanelSpecEditor/PanelAnnotationsEditor.d.ts.map +1 -1
  114. package/dist/components/PanelSpecEditor/PanelAnnotationsEditor.js +9 -9
  115. package/dist/components/PanelSpecEditor/PanelAnnotationsEditor.js.map +1 -1
  116. package/dist/components/PanelSpecEditor/PanelSpecEditor.d.ts +5 -5
  117. package/dist/components/PanelSpecEditor/PanelSpecEditor.d.ts.map +1 -1
  118. package/dist/components/PanelSpecEditor/PanelSpecEditor.js +9 -9
  119. package/dist/components/PanelSpecEditor/PanelSpecEditor.js.map +1 -1
  120. package/dist/components/PanelSpecEditor/index.js +1 -1
  121. package/dist/components/PanelSpecEditor/index.js.map +1 -1
  122. package/dist/components/PluginEditor/PluginEditor.d.ts +2 -2
  123. package/dist/components/PluginEditor/PluginEditor.d.ts.map +1 -1
  124. package/dist/components/PluginEditor/PluginEditor.js +7 -7
  125. package/dist/components/PluginEditor/PluginEditor.js.map +1 -1
  126. package/dist/components/PluginEditor/index.js +2 -2
  127. package/dist/components/PluginEditor/index.js.map +1 -1
  128. package/dist/components/PluginEditor/plugin-editor-api.d.ts +3 -3
  129. package/dist/components/PluginEditor/plugin-editor-api.d.ts.map +1 -1
  130. package/dist/components/PluginEditor/plugin-editor-api.js +4 -4
  131. package/dist/components/PluginEditor/plugin-editor-api.js.map +1 -1
  132. package/dist/components/PluginKindSelect/PluginKindSelect.d.ts +3 -3
  133. package/dist/components/PluginKindSelect/PluginKindSelect.d.ts.map +1 -1
  134. package/dist/components/PluginKindSelect/PluginKindSelect.js +4 -4
  135. package/dist/components/PluginKindSelect/PluginKindSelect.js.map +1 -1
  136. package/dist/components/PluginKindSelect/index.js +1 -1
  137. package/dist/components/PluginKindSelect/index.js.map +1 -1
  138. package/dist/components/PluginRegistry/PluginRegistry.d.ts +2 -2
  139. package/dist/components/PluginRegistry/PluginRegistry.d.ts.map +1 -1
  140. package/dist/components/PluginRegistry/PluginRegistry.js +5 -5
  141. package/dist/components/PluginRegistry/PluginRegistry.js.map +1 -1
  142. package/dist/components/PluginRegistry/getPluginSearchHelper.d.ts +2 -2
  143. package/dist/components/PluginRegistry/getPluginSearchHelper.d.ts.map +1 -1
  144. package/dist/components/PluginRegistry/getPluginSearchHelper.js +2 -2
  145. package/dist/components/PluginRegistry/getPluginSearchHelper.js.map +1 -1
  146. package/dist/components/PluginRegistry/index.js +1 -1
  147. package/dist/components/PluginRegistry/index.js.map +1 -1
  148. package/dist/components/PluginRegistry/plugin-indexes.d.ts +2 -1
  149. package/dist/components/PluginRegistry/plugin-indexes.d.ts.map +1 -1
  150. package/dist/components/PluginRegistry/plugin-indexes.js +3 -3
  151. package/dist/components/PluginRegistry/plugin-indexes.js.map +1 -1
  152. package/dist/components/PluginSpecEditor/DatasourceSpecEditor.d.ts +3 -3
  153. package/dist/components/PluginSpecEditor/DatasourceSpecEditor.d.ts.map +1 -1
  154. package/dist/components/PluginSpecEditor/DatasourceSpecEditor.js +3 -3
  155. package/dist/components/PluginSpecEditor/DatasourceSpecEditor.js.map +1 -1
  156. package/dist/components/PluginSpecEditor/PluginSpecEditor.d.ts +4 -4
  157. package/dist/components/PluginSpecEditor/PluginSpecEditor.d.ts.map +1 -1
  158. package/dist/components/PluginSpecEditor/PluginSpecEditor.js +4 -4
  159. package/dist/components/PluginSpecEditor/PluginSpecEditor.js.map +1 -1
  160. package/dist/components/PluginSpecEditor/index.js +1 -1
  161. package/dist/components/PluginSpecEditor/index.js.map +1 -1
  162. package/dist/components/SelectionOptionsEditor/SelectionOptionsEditor.d.ts +1 -1
  163. package/dist/components/SelectionOptionsEditor/SelectionOptionsEditor.d.ts.map +1 -1
  164. package/dist/components/SelectionOptionsEditor/SelectionOptionsEditor.js +3 -3
  165. package/dist/components/SelectionOptionsEditor/SelectionOptionsEditor.js.map +1 -1
  166. package/dist/components/SelectionOptionsEditor/index.js +1 -1
  167. package/dist/components/SelectionOptionsEditor/index.js.map +1 -1
  168. package/dist/components/TimeRangeControls/TimeRangeControls.d.ts +2 -2
  169. package/dist/components/TimeRangeControls/TimeRangeControls.d.ts.map +1 -1
  170. package/dist/components/TimeRangeControls/TimeRangeControls.js +10 -10
  171. package/dist/components/TimeRangeControls/TimeRangeControls.js.map +1 -1
  172. package/dist/components/TimeRangeControls/index.js +1 -1
  173. package/dist/components/TimeRangeControls/index.js.map +1 -1
  174. package/dist/components/Variables/VariableEditorForm/VariableEditorForm.d.ts +3 -3
  175. package/dist/components/Variables/VariableEditorForm/VariableEditorForm.d.ts.map +1 -1
  176. package/dist/components/Variables/VariableEditorForm/VariableEditorForm.js +11 -11
  177. package/dist/components/Variables/VariableEditorForm/VariableEditorForm.js.map +1 -1
  178. package/dist/components/Variables/VariableEditorForm/VariablePreview.d.ts +2 -2
  179. package/dist/components/Variables/VariableEditorForm/VariablePreview.d.ts.map +1 -1
  180. package/dist/components/Variables/VariableEditorForm/VariablePreview.js +7 -7
  181. package/dist/components/Variables/VariableEditorForm/VariablePreview.js.map +1 -1
  182. package/dist/components/Variables/VariableEditorForm/index.js +3 -3
  183. package/dist/components/Variables/VariableEditorForm/index.js.map +1 -1
  184. package/dist/components/Variables/VariableEditorForm/variable-editor-form-model.d.ts +2 -2
  185. package/dist/components/Variables/VariableEditorForm/variable-editor-form-model.d.ts.map +1 -1
  186. package/dist/components/Variables/VariableEditorForm/variable-editor-form-model.js.map +1 -1
  187. package/dist/components/Variables/index.js +2 -2
  188. package/dist/components/Variables/index.js.map +1 -1
  189. package/dist/components/Variables/variable-model.d.ts +4 -4
  190. package/dist/components/Variables/variable-model.d.ts.map +1 -1
  191. package/dist/components/Variables/variable-model.js +3 -3
  192. package/dist/components/Variables/variable-model.js.map +1 -1
  193. package/dist/components/index.js +21 -21
  194. package/dist/components/index.js.map +1 -1
  195. package/dist/constants/index.js +2 -2
  196. package/dist/constants/index.js.map +1 -1
  197. package/dist/context/ValidationProvider.d.ts +5 -5
  198. package/dist/context/ValidationProvider.d.ts.map +1 -1
  199. package/dist/context/ValidationProvider.js +5 -5
  200. package/dist/context/ValidationProvider.js.map +1 -1
  201. package/dist/context/index.js +1 -1
  202. package/dist/context/index.js.map +1 -1
  203. package/dist/index.js +9 -9
  204. package/dist/index.js.map +1 -1
  205. package/dist/model/alerts-queries.d.ts +4 -4
  206. package/dist/model/alerts-queries.d.ts.map +1 -1
  207. package/dist/model/alerts-queries.js.map +1 -1
  208. package/dist/model/annotations.d.ts +3 -3
  209. package/dist/model/annotations.d.ts.map +1 -1
  210. package/dist/model/annotations.js.map +1 -1
  211. package/dist/model/calculations.d.ts +1 -1
  212. package/dist/model/calculations.d.ts.map +1 -1
  213. package/dist/model/calculations.js.map +1 -1
  214. package/dist/model/datasource.d.ts +2 -2
  215. package/dist/model/datasource.d.ts.map +1 -1
  216. package/dist/model/datasource.js.map +1 -1
  217. package/dist/model/explore.d.ts +2 -2
  218. package/dist/model/explore.d.ts.map +1 -1
  219. package/dist/model/explore.js.map +1 -1
  220. package/dist/model/index.js +17 -17
  221. package/dist/model/index.js.map +1 -1
  222. package/dist/model/json-queries.d.ts +3 -3
  223. package/dist/model/json-queries.d.ts.map +1 -1
  224. package/dist/model/json-queries.js.map +1 -1
  225. package/dist/model/legend.d.ts +2 -2
  226. package/dist/model/legend.d.ts.map +1 -1
  227. package/dist/model/legend.js +2 -2
  228. package/dist/model/legend.js.map +1 -1
  229. package/dist/model/log-queries.d.ts +3 -3
  230. package/dist/model/log-queries.d.ts.map +1 -1
  231. package/dist/model/log-queries.js.map +1 -1
  232. package/dist/model/panels.d.ts +4 -4
  233. package/dist/model/panels.d.ts.map +1 -1
  234. package/dist/model/panels.js.map +1 -1
  235. package/dist/model/plugin-base.d.ts +1 -1
  236. package/dist/model/plugin-base.d.ts.map +1 -1
  237. package/dist/model/plugin-base.js.map +1 -1
  238. package/dist/model/plugin-loading.d.ts +1 -1
  239. package/dist/model/plugin-loading.d.ts.map +1 -1
  240. package/dist/model/plugin-loading.js +1 -1
  241. package/dist/model/plugin-loading.js.map +1 -1
  242. package/dist/model/plugins.d.ts +14 -14
  243. package/dist/model/plugins.d.ts.map +1 -1
  244. package/dist/model/plugins.js.map +1 -1
  245. package/dist/model/profile-queries.d.ts +4 -4
  246. package/dist/model/profile-queries.d.ts.map +1 -1
  247. package/dist/model/profile-queries.js.map +1 -1
  248. package/dist/model/silences-queries.d.ts +4 -4
  249. package/dist/model/silences-queries.d.ts.map +1 -1
  250. package/dist/model/silences-queries.js.map +1 -1
  251. package/dist/model/time-series-queries.d.ts +4 -4
  252. package/dist/model/time-series-queries.d.ts.map +1 -1
  253. package/dist/model/time-series-queries.js.map +1 -1
  254. package/dist/model/trace-queries.d.ts +4 -4
  255. package/dist/model/trace-queries.d.ts.map +1 -1
  256. package/dist/model/trace-queries.js.map +1 -1
  257. package/dist/model/variables.d.ts +3 -3
  258. package/dist/model/variables.d.ts.map +1 -1
  259. package/dist/model/variables.js.map +1 -1
  260. package/dist/remote/PluginLoaderComponent.d.ts +1 -1
  261. package/dist/remote/PluginLoaderComponent.d.ts.map +1 -1
  262. package/dist/remote/PluginLoaderComponent.js +2 -2
  263. package/dist/remote/PluginLoaderComponent.js.map +1 -1
  264. package/dist/remote/PluginRuntime.d.ts +2 -2
  265. package/dist/remote/PluginRuntime.d.ts.map +1 -1
  266. package/dist/remote/PluginRuntime.js +18 -18
  267. package/dist/remote/PluginRuntime.js.map +1 -1
  268. package/dist/remote/index.js +2 -2
  269. package/dist/remote/index.js.map +1 -1
  270. package/dist/remote/remotePluginLoader.d.ts +2 -2
  271. package/dist/remote/remotePluginLoader.d.ts.map +1 -1
  272. package/dist/remote/remotePluginLoader.js +3 -3
  273. package/dist/remote/remotePluginLoader.js.map +1 -1
  274. package/dist/runtime/DataQueriesProvider/DataQueriesProvider.d.ts +3 -3
  275. package/dist/runtime/DataQueriesProvider/DataQueriesProvider.d.ts.map +1 -1
  276. package/dist/runtime/DataQueriesProvider/DataQueriesProvider.js +10 -10
  277. package/dist/runtime/DataQueriesProvider/DataQueriesProvider.js.map +1 -1
  278. package/dist/runtime/DataQueriesProvider/index.js +2 -2
  279. package/dist/runtime/DataQueriesProvider/index.js.map +1 -1
  280. package/dist/runtime/DataQueriesProvider/model.d.ts +3 -3
  281. package/dist/runtime/DataQueriesProvider/model.d.ts.map +1 -1
  282. package/dist/runtime/DataQueriesProvider/model.js.map +1 -1
  283. package/dist/runtime/RouterProvider.d.ts +2 -1
  284. package/dist/runtime/RouterProvider.d.ts.map +1 -1
  285. package/dist/runtime/RouterProvider.js +3 -3
  286. package/dist/runtime/RouterProvider.js.map +1 -1
  287. package/dist/runtime/TimeRangeProvider/TimeRangeProvider.d.ts +3 -2
  288. package/dist/runtime/TimeRangeProvider/TimeRangeProvider.d.ts.map +1 -1
  289. package/dist/runtime/TimeRangeProvider/TimeRangeProvider.js +6 -6
  290. package/dist/runtime/TimeRangeProvider/TimeRangeProvider.js.map +1 -1
  291. package/dist/runtime/TimeRangeProvider/TimeRangeProviders.d.ts +3 -2
  292. package/dist/runtime/TimeRangeProvider/TimeRangeProviders.d.ts.map +1 -1
  293. package/dist/runtime/TimeRangeProvider/TimeRangeProviders.js +4 -4
  294. package/dist/runtime/TimeRangeProvider/TimeRangeProviders.js.map +1 -1
  295. package/dist/runtime/TimeRangeProvider/TimeRangeSettingsProvider.d.ts +2 -2
  296. package/dist/runtime/TimeRangeProvider/TimeRangeSettingsProvider.d.ts.map +1 -1
  297. package/dist/runtime/TimeRangeProvider/TimeRangeSettingsProvider.js +3 -3
  298. package/dist/runtime/TimeRangeProvider/TimeRangeSettingsProvider.js.map +1 -1
  299. package/dist/runtime/TimeRangeProvider/index.js +4 -4
  300. package/dist/runtime/TimeRangeProvider/index.js.map +1 -1
  301. package/dist/runtime/TimeRangeProvider/query-params.d.ts +3 -3
  302. package/dist/runtime/TimeRangeProvider/query-params.d.ts.map +1 -1
  303. package/dist/runtime/TimeRangeProvider/query-params.js +4 -4
  304. package/dist/runtime/TimeRangeProvider/query-params.js.map +1 -1
  305. package/dist/runtime/TimeRangeProvider/refresh-interval.d.ts +1 -1
  306. package/dist/runtime/TimeRangeProvider/refresh-interval.d.ts.map +1 -1
  307. package/dist/runtime/TimeRangeProvider/refresh-interval.js +2 -2
  308. package/dist/runtime/TimeRangeProvider/refresh-interval.js.map +1 -1
  309. package/dist/runtime/UsageMetricsProvider.d.ts +3 -3
  310. package/dist/runtime/UsageMetricsProvider.d.ts.map +1 -1
  311. package/dist/runtime/UsageMetricsProvider.js +3 -3
  312. package/dist/runtime/UsageMetricsProvider.js.map +1 -1
  313. package/dist/runtime/alerts-queries.d.ts +2 -2
  314. package/dist/runtime/alerts-queries.d.ts.map +1 -1
  315. package/dist/runtime/alerts-queries.js +5 -5
  316. package/dist/runtime/alerts-queries.js.map +1 -1
  317. package/dist/runtime/annotations.d.ts +2 -2
  318. package/dist/runtime/annotations.d.ts.map +1 -1
  319. package/dist/runtime/annotations.js +6 -6
  320. package/dist/runtime/annotations.js.map +1 -1
  321. package/dist/runtime/builtin-variables.d.ts +2 -2
  322. package/dist/runtime/builtin-variables.d.ts.map +1 -1
  323. package/dist/runtime/builtin-variables.js +1 -1
  324. package/dist/runtime/builtin-variables.js.map +1 -1
  325. package/dist/runtime/datasources.d.ts +2 -2
  326. package/dist/runtime/datasources.d.ts.map +1 -1
  327. package/dist/runtime/datasources.js +2 -2
  328. package/dist/runtime/datasources.js.map +1 -1
  329. package/dist/runtime/index.js +16 -16
  330. package/dist/runtime/index.js.map +1 -1
  331. package/dist/runtime/item-actions.d.ts +3 -3
  332. package/dist/runtime/item-actions.d.ts.map +1 -1
  333. package/dist/runtime/item-actions.js +1 -1
  334. package/dist/runtime/item-actions.js.map +1 -1
  335. package/dist/runtime/json-queries.d.ts +2 -2
  336. package/dist/runtime/json-queries.d.ts.map +1 -1
  337. package/dist/runtime/json-queries.js +4 -4
  338. package/dist/runtime/json-queries.js.map +1 -1
  339. package/dist/runtime/log-queries.d.ts +3 -3
  340. package/dist/runtime/log-queries.d.ts.map +1 -1
  341. package/dist/runtime/log-queries.js +5 -5
  342. package/dist/runtime/log-queries.js.map +1 -1
  343. package/dist/runtime/plugin-registry.d.ts +3 -3
  344. package/dist/runtime/plugin-registry.d.ts.map +1 -1
  345. package/dist/runtime/plugin-registry.js +2 -2
  346. package/dist/runtime/plugin-registry.js.map +1 -1
  347. package/dist/runtime/profile-queries.d.ts +2 -2
  348. package/dist/runtime/profile-queries.d.ts.map +1 -1
  349. package/dist/runtime/profile-queries.js +4 -4
  350. package/dist/runtime/profile-queries.js.map +1 -1
  351. package/dist/runtime/silences-queries.d.ts +2 -2
  352. package/dist/runtime/silences-queries.d.ts.map +1 -1
  353. package/dist/runtime/silences-queries.js +5 -5
  354. package/dist/runtime/silences-queries.js.map +1 -1
  355. package/dist/runtime/time-series-queries.d.ts +3 -3
  356. package/dist/runtime/time-series-queries.d.ts.map +1 -1
  357. package/dist/runtime/time-series-queries.js +6 -6
  358. package/dist/runtime/time-series-queries.js.map +1 -1
  359. package/dist/runtime/trace-queries.d.ts +2 -2
  360. package/dist/runtime/trace-queries.d.ts.map +1 -1
  361. package/dist/runtime/trace-queries.js +6 -6
  362. package/dist/runtime/trace-queries.js.map +1 -1
  363. package/dist/runtime/utils.d.ts +1 -1
  364. package/dist/runtime/utils.d.ts.map +1 -1
  365. package/dist/runtime/utils.js.map +1 -1
  366. package/dist/runtime/variables.d.ts +1 -1
  367. package/dist/runtime/variables.d.ts.map +1 -1
  368. package/dist/runtime/variables.js +4 -4
  369. package/dist/runtime/variables.js.map +1 -1
  370. package/dist/schema/index.js +1 -1
  371. package/dist/schema/index.js.map +1 -1
  372. package/dist/schema/panel.d.ts +2 -2
  373. package/dist/schema/panel.d.ts.map +1 -1
  374. package/dist/schema/panel.js +2 -2
  375. package/dist/schema/panel.js.map +1 -1
  376. package/dist/test/index.js +2 -2
  377. package/dist/test/index.js.map +1 -1
  378. package/dist/test/mock-data.d.ts +1 -1
  379. package/dist/test/mock-data.d.ts.map +1 -1
  380. package/dist/test/mock-data.js.map +1 -1
  381. package/dist/test/render-hook.d.ts +2 -2
  382. package/dist/test/render-hook.d.ts.map +1 -1
  383. package/dist/test/render-hook.js +2 -2
  384. package/dist/test/render-hook.js.map +1 -1
  385. package/dist/test/render.d.ts +3 -3
  386. package/dist/test/render.d.ts.map +1 -1
  387. package/dist/test/render.js +3 -3
  388. package/dist/test/render.js.map +1 -1
  389. package/dist/test/setup-tests.js +1 -1
  390. package/dist/test/test-plugins/bert/index.d.ts +3 -3
  391. package/dist/test/test-plugins/bert/index.d.ts.map +1 -1
  392. package/dist/test/test-plugins/bert/index.js.map +1 -1
  393. package/dist/test/test-plugins/ernie/index.d.ts +1 -1
  394. package/dist/test/test-plugins/ernie/index.d.ts.map +1 -1
  395. package/dist/test/test-plugins/ernie/index.js.map +1 -1
  396. package/dist/test/test-plugins/index.d.ts +1 -1
  397. package/dist/test/test-plugins/index.d.ts.map +1 -1
  398. package/dist/test/test-plugins/index.js +5 -5
  399. package/dist/test/test-plugins/index.js.map +1 -1
  400. package/dist/test/utils.d.ts +2 -2
  401. package/dist/test/utils.d.ts.map +1 -1
  402. package/dist/test/utils.js +4 -4
  403. package/dist/test/utils.js.map +1 -1
  404. package/dist/test-utils/index.js +1 -1
  405. package/dist/test-utils/index.js.map +1 -1
  406. package/dist/test-utils/mock-plugin-registry.d.ts +2 -2
  407. package/dist/test-utils/mock-plugin-registry.d.ts.map +1 -1
  408. package/dist/test-utils/mock-plugin-registry.js +1 -1
  409. package/dist/test-utils/mock-plugin-registry.js.map +1 -1
  410. package/dist/utils/event.js +1 -1
  411. package/dist/utils/index.js +3 -3
  412. package/dist/utils/index.js.map +1 -1
  413. package/dist/utils/variables.js +1 -1
  414. package/package.json +7 -7
  415. package/dist/cjs/components/Annotations/AnnotationEditorForm/AnnotationEditorForm.js +0 -283
  416. package/dist/cjs/components/Annotations/AnnotationEditorForm/AnnotationPreview.js +0 -197
  417. package/dist/cjs/components/Annotations/AnnotationEditorForm/index.js +0 -30
  418. package/dist/cjs/components/Annotations/constants.js +0 -23
  419. package/dist/cjs/components/Annotations/index.js +0 -31
  420. package/dist/cjs/components/CalculationSelector/CalculationSelector.js +0 -49
  421. package/dist/cjs/components/CalculationSelector/index.js +0 -30
  422. package/dist/cjs/components/DatasourceEditorForm/DatasourceEditorForm.js +0 -271
  423. package/dist/cjs/components/DatasourceEditorForm/index.js +0 -30
  424. package/dist/cjs/components/DatasourceSelect/DatasourceSelect.js +0 -266
  425. package/dist/cjs/components/DatasourceSelect/index.js +0 -30
  426. package/dist/cjs/components/DatasourceTestConnectionButton/DatasourceTestConnectionButton.js +0 -53
  427. package/dist/cjs/components/DatasourceTestConnectionButton/index.js +0 -30
  428. package/dist/cjs/components/HTTPSettingsEditor/HTTPSettingsEditor.js +0 -593
  429. package/dist/cjs/components/HTTPSettingsEditor/index.js +0 -30
  430. package/dist/cjs/components/ItemSelectionActionsOptionsEditor/ItemSelectionActionsOptionsEditor.js +0 -1175
  431. package/dist/cjs/components/ItemSelectionActionsOptionsEditor/index.js +0 -30
  432. package/dist/cjs/components/LayoutEditor/LayoutEditor.js +0 -123
  433. package/dist/cjs/components/LayoutEditor/RepeatLayoutPreview.js +0 -105
  434. package/dist/cjs/components/LayoutEditor/RepeatVariableEditor.js +0 -176
  435. package/dist/cjs/components/LayoutEditor/index.js +0 -32
  436. package/dist/cjs/components/LegendOptionsEditor/LegendOptionsEditor.js +0 -211
  437. package/dist/cjs/components/LegendOptionsEditor/index.js +0 -30
  438. package/dist/cjs/components/LinksEditor/LinksEditor.js +0 -162
  439. package/dist/cjs/components/LinksEditor/index.js +0 -30
  440. package/dist/cjs/components/MetricLabelInput/MetricLabelInput.js +0 -41
  441. package/dist/cjs/components/MetricLabelInput/index.js +0 -30
  442. package/dist/cjs/components/MultiQueryEditor/MultiQueryEditor.js +0 -162
  443. package/dist/cjs/components/MultiQueryEditor/QueryEditorContainer.js +0 -250
  444. package/dist/cjs/components/MultiQueryEditor/index.js +0 -31
  445. package/dist/cjs/components/MultiQueryEditor/utils.js +0 -36
  446. package/dist/cjs/components/OptionsEditorRadios/OptionsEditorRadios.js +0 -69
  447. package/dist/cjs/components/OptionsEditorRadios/index.js +0 -30
  448. package/dist/cjs/components/OptionsEditorTabPanel/OptionsEditorTabPanel.js +0 -39
  449. package/dist/cjs/components/OptionsEditorTabPanel/index.js +0 -30
  450. package/dist/cjs/components/OptionsEditorTabs/OptionsEditorTabs.js +0 -61
  451. package/dist/cjs/components/OptionsEditorTabs/index.js +0 -30
  452. package/dist/cjs/components/PanelSpecEditor/PanelAnnotationsEditor.js +0 -246
  453. package/dist/cjs/components/PanelSpecEditor/PanelSpecEditor.js +0 -144
  454. package/dist/cjs/components/PanelSpecEditor/index.js +0 -30
  455. package/dist/cjs/components/PluginEditor/PluginEditor.js +0 -99
  456. package/dist/cjs/components/PluginEditor/index.js +0 -31
  457. package/dist/cjs/components/PluginEditor/plugin-editor-api.js +0 -136
  458. package/dist/cjs/components/PluginKindSelect/PluginKindSelect.js +0 -109
  459. package/dist/cjs/components/PluginKindSelect/index.js +0 -30
  460. package/dist/cjs/components/PluginRegistry/PluginRegistry.js +0 -86
  461. package/dist/cjs/components/PluginRegistry/getPluginSearchHelper.js +0 -92
  462. package/dist/cjs/components/PluginRegistry/index.js +0 -30
  463. package/dist/cjs/components/PluginRegistry/plugin-indexes.js +0 -88
  464. package/dist/cjs/components/PluginSpecEditor/DatasourceSpecEditor.js +0 -70
  465. package/dist/cjs/components/PluginSpecEditor/PluginSpecEditor.js +0 -69
  466. package/dist/cjs/components/PluginSpecEditor/index.js +0 -30
  467. package/dist/cjs/components/SelectionOptionsEditor/SelectionOptionsEditor.js +0 -43
  468. package/dist/cjs/components/SelectionOptionsEditor/index.js +0 -30
  469. package/dist/cjs/components/TimeRangeControls/TimeRangeControls.js +0 -235
  470. package/dist/cjs/components/TimeRangeControls/index.js +0 -30
  471. package/dist/cjs/components/Variables/VariableEditorForm/VariableEditorForm.js +0 -613
  472. package/dist/cjs/components/Variables/VariableEditorForm/VariablePreview.js +0 -193
  473. package/dist/cjs/components/Variables/VariableEditorForm/index.js +0 -32
  474. package/dist/cjs/components/Variables/VariableEditorForm/variable-editor-form-model.js +0 -143
  475. package/dist/cjs/components/Variables/index.js +0 -31
  476. package/dist/cjs/components/Variables/variable-model.js +0 -211
  477. package/dist/cjs/components/index.js +0 -50
  478. package/dist/cjs/constants/index.js +0 -31
  479. package/dist/cjs/constants/repeat.js +0 -32
  480. package/dist/cjs/constants/user-interface-text.js +0 -32
  481. package/dist/cjs/context/ValidationProvider.js +0 -77
  482. package/dist/cjs/context/index.js +0 -30
  483. package/dist/cjs/index.js +0 -38
  484. package/dist/cjs/model/alerts-queries.js +0 -16
  485. package/dist/cjs/model/annotations.js +0 -16
  486. package/dist/cjs/model/calculations.js +0 -178
  487. package/dist/cjs/model/datasource.js +0 -16
  488. package/dist/cjs/model/explore.js +0 -16
  489. package/dist/cjs/model/index.js +0 -46
  490. package/dist/cjs/model/json-queries.js +0 -16
  491. package/dist/cjs/model/legend.js +0 -111
  492. package/dist/cjs/model/log-queries.js +0 -16
  493. package/dist/cjs/model/log-volume-utils.js +0 -124
  494. package/dist/cjs/model/panels.js +0 -16
  495. package/dist/cjs/model/plugin-base.js +0 -16
  496. package/dist/cjs/model/plugin-loading.js +0 -56
  497. package/dist/cjs/model/plugins.js +0 -26
  498. package/dist/cjs/model/profile-queries.js +0 -16
  499. package/dist/cjs/model/silences-queries.js +0 -16
  500. package/dist/cjs/model/time-series-queries.js +0 -26
  501. package/dist/cjs/model/trace-queries.js +0 -16
  502. package/dist/cjs/model/variables.js +0 -16
  503. package/dist/cjs/remote/PersesPlugin.types.js +0 -16
  504. package/dist/cjs/remote/PluginLoaderComponent.js +0 -87
  505. package/dist/cjs/remote/PluginRuntime.js +0 -323
  506. package/dist/cjs/remote/index.js +0 -31
  507. package/dist/cjs/remote/remotePluginLoader.js +0 -101
  508. package/dist/cjs/runtime/DataQueriesProvider/DataQueriesProvider.js +0 -162
  509. package/dist/cjs/runtime/DataQueriesProvider/index.js +0 -31
  510. package/dist/cjs/runtime/DataQueriesProvider/model.js +0 -34
  511. package/dist/cjs/runtime/RouterProvider.js +0 -114
  512. package/dist/cjs/runtime/TimeRangeProvider/TimeRangeProvider.js +0 -215
  513. package/dist/cjs/runtime/TimeRangeProvider/TimeRangeProviders.js +0 -66
  514. package/dist/cjs/runtime/TimeRangeProvider/TimeRangeSettingsProvider.js +0 -126
  515. package/dist/cjs/runtime/TimeRangeProvider/index.js +0 -33
  516. package/dist/cjs/runtime/TimeRangeProvider/query-params.js +0 -250
  517. package/dist/cjs/runtime/TimeRangeProvider/refresh-interval.js +0 -30
  518. package/dist/cjs/runtime/UsageMetricsProvider.js +0 -102
  519. package/dist/cjs/runtime/alerts-queries.js +0 -101
  520. package/dist/cjs/runtime/annotations.js +0 -148
  521. package/dist/cjs/runtime/builtin-variables.js +0 -81
  522. package/dist/cjs/runtime/datasources.js +0 -80
  523. package/dist/cjs/runtime/index.js +0 -45
  524. package/dist/cjs/runtime/item-actions.js +0 -302
  525. package/dist/cjs/runtime/json-queries.js +0 -70
  526. package/dist/cjs/runtime/log-queries.js +0 -76
  527. package/dist/cjs/runtime/plugin-registry.js +0 -135
  528. package/dist/cjs/runtime/profile-queries.js +0 -73
  529. package/dist/cjs/runtime/silences-queries.js +0 -101
  530. package/dist/cjs/runtime/time-series-queries.js +0 -165
  531. package/dist/cjs/runtime/trace-queries.js +0 -106
  532. package/dist/cjs/runtime/utils.js +0 -39
  533. package/dist/cjs/runtime/variables.js +0 -160
  534. package/dist/cjs/schema/index.js +0 -30
  535. package/dist/cjs/schema/panel.js +0 -56
  536. package/dist/cjs/test/index.js +0 -31
  537. package/dist/cjs/test/mock-data.js +0 -366
  538. package/dist/cjs/test/render-hook.js +0 -31
  539. package/dist/cjs/test/render.js +0 -31
  540. package/dist/cjs/test/setup-tests.js +0 -26
  541. package/dist/cjs/test/test-plugins/bert/index.js +0 -99
  542. package/dist/cjs/test/test-plugins/ernie/index.js +0 -149
  543. package/dist/cjs/test/test-plugins/index.js +0 -81
  544. package/dist/cjs/test/utils.js +0 -58
  545. package/dist/cjs/test-utils/index.js +0 -30
  546. package/dist/cjs/test-utils/mock-plugin-registry.js +0 -81
  547. package/dist/cjs/utils/csv-export.js +0 -248
  548. package/dist/cjs/utils/event.js +0 -30
  549. package/dist/cjs/utils/index.js +0 -32
  550. package/dist/cjs/utils/variables.js +0 -44
@@ -1,283 +0,0 @@
1
- // Copyright The Perses Authors
2
- // Licensed under the Apache License, Version 2.0 (the "License");
3
- // you may not use this file except in compliance with the License.
4
- // You may obtain a copy of the License at
5
- //
6
- // http://www.apache.org/licenses/LICENSE-2.0
7
- //
8
- // Unless required by applicable law or agreed to in writing, software
9
- // distributed under the License is distributed on an "AS IS" BASIS,
10
- // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11
- // See the License for the specific language governing permissions and
12
- // limitations under the License.
13
- "use strict";
14
- Object.defineProperty(exports, "__esModule", {
15
- value: true
16
- });
17
- Object.defineProperty(exports, "AnnotationEditorForm", {
18
- enumerable: true,
19
- get: function() {
20
- return AnnotationEditorForm;
21
- }
22
- });
23
- const _jsxruntime = require("react/jsx-runtime");
24
- const _zod = require("@hookform/resolvers/zod");
25
- const _material = require("@mui/material");
26
- const _components = require("@perses-dev/components");
27
- const _reactquery = require("@tanstack/react-query");
28
- const _InvertColors = /*#__PURE__*/ _interop_require_default(require("mdi-material-ui/InvertColors"));
29
- const _react = require("react");
30
- const _reacthookform = require("react-hook-form");
31
- const _context = require("../../../context");
32
- const _PluginEditor = require("../../PluginEditor");
33
- const _constants = require("../constants");
34
- const _AnnotationPreview = require("./AnnotationPreview");
35
- function _interop_require_default(obj) {
36
- return obj && obj.__esModule ? obj : {
37
- default: obj
38
- };
39
- }
40
- function FallbackPreview() {
41
- return /*#__PURE__*/ (0, _jsxruntime.jsx)("div", {
42
- children: "Error previewing annotations"
43
- });
44
- }
45
- function AnnotationPluginControl({ action, control, onRunQuery }) {
46
- const plugin = (0, _reacthookform.useWatch)({
47
- control,
48
- name: 'plugin'
49
- });
50
- const kind = plugin?.kind;
51
- const pluginSpec = plugin?.spec;
52
- return /*#__PURE__*/ (0, _jsxruntime.jsx)(_reacthookform.Controller, {
53
- control: control,
54
- name: "plugin",
55
- render: ({ field })=>{
56
- return /*#__PURE__*/ (0, _jsxruntime.jsx)(_PluginEditor.PluginEditor, {
57
- withRunQueryButton: true,
58
- width: "100%",
59
- pluginTypes: [
60
- 'Annotation'
61
- ],
62
- pluginKindLabel: "Source",
63
- value: {
64
- selection: {
65
- type: 'Annotation',
66
- kind: kind ?? 'StaticListAnnotation'
67
- },
68
- spec: pluginSpec ?? {}
69
- },
70
- isReadonly: action === 'read',
71
- onChange: (v)=>{
72
- field.onChange({
73
- kind: v.selection.kind,
74
- spec: v.spec
75
- });
76
- },
77
- onRunQuery: onRunQuery
78
- });
79
- }
80
- });
81
- }
82
- function AnnotationEditorForm({ initialAnnotationSpec, action, isDraft, isReadonly, onActionChange, onSave, onClose, onDelete }) {
83
- const queryClient = (0, _reactquery.useQueryClient)();
84
- const [isDiscardDialogOpened, setDiscardDialogOpened] = (0, _react.useState)(false);
85
- const titleAction = (0, _components.getTitleAction)(action, isDraft);
86
- const submitText = (0, _components.getSubmitText)(action, isDraft);
87
- const { annotationEditorSchema } = (0, _context.useValidationSchemas)();
88
- const form = (0, _reacthookform.useForm)({
89
- resolver: (0, _zod.zodResolver)(annotationEditorSchema),
90
- mode: 'onBlur',
91
- defaultValues: initialAnnotationSpec
92
- });
93
- /* We use `previewDefinition` to explicitly update the spec
94
- * that will be used for preview when running query. The reason why we do this is to avoid
95
- * having to re-fetch the values when the user is still editing the spec.
96
- * Using structuredClone to not have reference issues with nested objects.
97
- */ const [previewSpec, setPreviewSpec] = (0, _react.useState)(structuredClone(form.getValues()));
98
- const handleRunQuery = (0, _react.useCallback)(async ()=>{
99
- const values = form.getValues();
100
- if (JSON.stringify(previewSpec) === JSON.stringify(values)) {
101
- await queryClient.invalidateQueries({
102
- queryKey: [
103
- 'annotation',
104
- previewSpec
105
- ]
106
- });
107
- } else {
108
- setPreviewSpec(structuredClone(values));
109
- }
110
- }, [
111
- form,
112
- previewSpec,
113
- queryClient
114
- ]);
115
- const processForm = (data)=>{
116
- // reset display attributes to undefined when empty, because we don't want to save empty strings
117
- onSave(data);
118
- };
119
- function handleCancel() {
120
- if (JSON.stringify(initialAnnotationSpec) !== JSON.stringify(form.getValues())) {
121
- setDiscardDialogOpened(true);
122
- } else {
123
- onClose();
124
- }
125
- }
126
- return /*#__PURE__*/ (0, _jsxruntime.jsxs)(_reacthookform.FormProvider, {
127
- ...form,
128
- children: [
129
- /*#__PURE__*/ (0, _jsxruntime.jsxs)(_material.Box, {
130
- sx: {
131
- display: 'flex',
132
- alignItems: 'center',
133
- padding: (theme)=>theme.spacing(1, 2),
134
- borderBottom: (theme)=>`1px solid ${theme.palette.divider}`
135
- },
136
- children: [
137
- /*#__PURE__*/ (0, _jsxruntime.jsxs)(_material.Typography, {
138
- variant: "h2",
139
- children: [
140
- titleAction,
141
- " Annotation"
142
- ]
143
- }),
144
- /*#__PURE__*/ (0, _jsxruntime.jsx)(_components.FormActions, {
145
- action: action,
146
- submitText: submitText,
147
- isReadonly: isReadonly,
148
- isValid: form.formState.isValid,
149
- onActionChange: onActionChange,
150
- onSubmit: form.handleSubmit(processForm),
151
- onDelete: onDelete,
152
- onCancel: handleCancel
153
- })
154
- ]
155
- }),
156
- /*#__PURE__*/ (0, _jsxruntime.jsxs)(_material.Box, {
157
- padding: 2,
158
- sx: {
159
- overflowY: 'scroll'
160
- },
161
- children: [
162
- /*#__PURE__*/ (0, _jsxruntime.jsxs)(_material.Grid, {
163
- container: true,
164
- spacing: 2,
165
- mb: 2,
166
- children: [
167
- /*#__PURE__*/ (0, _jsxruntime.jsx)(_material.Grid, {
168
- item: true,
169
- xs: 12,
170
- children: /*#__PURE__*/ (0, _jsxruntime.jsx)(_reacthookform.Controller, {
171
- control: form.control,
172
- name: "display.name",
173
- render: ({ field, fieldState })=>/*#__PURE__*/ (0, _jsxruntime.jsx)(_material.TextField, {
174
- ...field,
175
- required: true,
176
- fullWidth: true,
177
- label: "Name",
178
- InputLabelProps: {
179
- shrink: action === 'read' ? true : undefined
180
- },
181
- InputProps: {
182
- disabled: action === 'update' && !isDraft,
183
- readOnly: action === 'read'
184
- },
185
- error: !!fieldState.error,
186
- helperText: fieldState.error?.message,
187
- value: field.value ?? '',
188
- onChange: (event)=>{
189
- field.onChange(event);
190
- }
191
- })
192
- })
193
- }),
194
- /*#__PURE__*/ (0, _jsxruntime.jsx)(_material.Grid, {
195
- item: true,
196
- xs: 12,
197
- children: /*#__PURE__*/ (0, _jsxruntime.jsxs)(_material.Stack, {
198
- direction: "row",
199
- gap: 1,
200
- children: [
201
- /*#__PURE__*/ (0, _jsxruntime.jsx)(_reacthookform.Controller, {
202
- control: form.control,
203
- name: "display.color",
204
- render: ({ field })=>{
205
- const isEnabled = field.value !== undefined;
206
- return /*#__PURE__*/ (0, _jsxruntime.jsx)(_jsxruntime.Fragment, {
207
- children: isEnabled ? /*#__PURE__*/ (0, _jsxruntime.jsx)(_components.OptionsColorPicker, {
208
- size: "medium",
209
- label: "annotation",
210
- color: field.value ?? _constants.DEFAULT_ANNOTATION_COLOR,
211
- onColorChange: (color)=>field.onChange(color),
212
- onClear: ()=>field.onChange(undefined)
213
- }) : /*#__PURE__*/ (0, _jsxruntime.jsx)(_material.IconButton, {
214
- size: "medium",
215
- onClick: ()=>field.onChange(_constants.DEFAULT_ANNOTATION_COLOR),
216
- children: /*#__PURE__*/ (0, _jsxruntime.jsx)(_InvertColors.default, {})
217
- })
218
- });
219
- }
220
- }),
221
- /*#__PURE__*/ (0, _jsxruntime.jsx)(_reacthookform.Controller, {
222
- control: form.control,
223
- name: "display.description",
224
- render: ({ field, fieldState })=>/*#__PURE__*/ (0, _jsxruntime.jsx)(_material.TextField, {
225
- ...field,
226
- fullWidth: true,
227
- label: "Description",
228
- InputLabelProps: {
229
- shrink: action === 'read' ? true : undefined
230
- },
231
- InputProps: {
232
- readOnly: action === 'read'
233
- },
234
- error: !!fieldState.error,
235
- helperText: fieldState.error?.message,
236
- value: field.value ?? '',
237
- onChange: (event)=>{
238
- field.onChange(event);
239
- }
240
- })
241
- })
242
- ]
243
- })
244
- })
245
- ]
246
- }),
247
- /*#__PURE__*/ (0, _jsxruntime.jsx)(_material.Divider, {}),
248
- /*#__PURE__*/ (0, _jsxruntime.jsx)(_components.ErrorBoundary, {
249
- FallbackComponent: FallbackPreview,
250
- resetKeys: [
251
- previewSpec
252
- ],
253
- children: /*#__PURE__*/ (0, _jsxruntime.jsx)(_AnnotationPreview.AnnotationPreview, {
254
- spec: previewSpec,
255
- sx: {
256
- marginY: 2
257
- }
258
- })
259
- }),
260
- /*#__PURE__*/ (0, _jsxruntime.jsx)(_components.ErrorBoundary, {
261
- FallbackComponent: _components.ErrorAlert,
262
- children: /*#__PURE__*/ (0, _jsxruntime.jsx)(AnnotationPluginControl, {
263
- action: action,
264
- control: form.control,
265
- onRunQuery: handleRunQuery
266
- })
267
- })
268
- ]
269
- }),
270
- /*#__PURE__*/ (0, _jsxruntime.jsx)(_components.DiscardChangesConfirmationDialog, {
271
- description: "Are you sure you want to discard these changes? Changes cannot be recovered.",
272
- isOpen: isDiscardDialogOpened,
273
- onCancel: ()=>{
274
- setDiscardDialogOpened(false);
275
- },
276
- onDiscardChanges: ()=>{
277
- setDiscardDialogOpened(false);
278
- onClose();
279
- }
280
- })
281
- ]
282
- });
283
- }
@@ -1,197 +0,0 @@
1
- // Copyright The Perses Authors
2
- // Licensed under the Apache License, Version 2.0 (the "License");
3
- // you may not use this file except in compliance with the License.
4
- // You may obtain a copy of the License at
5
- //
6
- // http://www.apache.org/licenses/LICENSE-2.0
7
- //
8
- // Unless required by applicable law or agreed to in writing, software
9
- // distributed under the License is distributed on an "AS IS" BASIS,
10
- // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11
- // See the License for the specific language governing permissions and
12
- // limitations under the License.
13
- "use strict";
14
- Object.defineProperty(exports, "__esModule", {
15
- value: true
16
- });
17
- Object.defineProperty(exports, "AnnotationPreview", {
18
- enumerable: true,
19
- get: function() {
20
- return AnnotationPreview;
21
- }
22
- });
23
- const _jsxruntime = require("react/jsx-runtime");
24
- const _material = require("@mui/material");
25
- const _components = require("@perses-dev/components");
26
- const _Alert = /*#__PURE__*/ _interop_require_default(require("mdi-material-ui/Alert"));
27
- const _react = require("react");
28
- const _runtime = require("../../../runtime");
29
- function _interop_require_default(obj) {
30
- return obj && obj.__esModule ? obj : {
31
- default: obj
32
- };
33
- }
34
- function AnnotationPreviewCard({ value, formatWithUserTimeZone, ...props }) {
35
- const start = (0, _components.getDateAndTime)(value.start, formatWithUserTimeZone);
36
- const end = value.end !== undefined ? (0, _components.getDateAndTime)(value.start, formatWithUserTimeZone) : null;
37
- const tags = (0, _react.useMemo)(()=>{
38
- return Object.entries(value.tags ?? []).map(([key, value])=>{
39
- return {
40
- key: key,
41
- value: value
42
- };
43
- });
44
- }, [
45
- value.tags
46
- ]);
47
- return /*#__PURE__*/ (0, _jsxruntime.jsx)(_material.Card, {
48
- ...props,
49
- children: /*#__PURE__*/ (0, _jsxruntime.jsxs)(_material.CardContent, {
50
- children: [
51
- /*#__PURE__*/ (0, _jsxruntime.jsxs)(_material.Stack, {
52
- gap: 2,
53
- children: [
54
- value.title && /*#__PURE__*/ (0, _jsxruntime.jsx)(_material.Typography, {
55
- variant: "h3",
56
- children: value.title
57
- }),
58
- value.legend && /*#__PURE__*/ (0, _jsxruntime.jsx)(_material.Typography, {
59
- children: value.legend
60
- }),
61
- /*#__PURE__*/ (0, _jsxruntime.jsx)(_material.Stack, {
62
- flexWrap: "wrap",
63
- direction: "row",
64
- gap: 0.5,
65
- children: tags.map((tag)=>/*#__PURE__*/ (0, _jsxruntime.jsx)(_material.Chip, {
66
- size: "small",
67
- label: `${tag.key}: ${tag.value}`
68
- }, `${tag.key}=${tag.value}`))
69
- })
70
- ]
71
- }),
72
- /*#__PURE__*/ (0, _jsxruntime.jsx)(_material.Divider, {
73
- sx: {
74
- marginY: 2
75
- }
76
- }),
77
- /*#__PURE__*/ (0, _jsxruntime.jsxs)(_material.Stack, {
78
- gap: 0.5,
79
- direction: "row",
80
- children: [
81
- /*#__PURE__*/ (0, _jsxruntime.jsxs)(_material.Typography, {
82
- variant: "caption",
83
- children: [
84
- start.formattedDate,
85
- " - ",
86
- /*#__PURE__*/ (0, _jsxruntime.jsx)("strong", {
87
- children: start.formattedTime
88
- })
89
- ]
90
- }),
91
- end && /*#__PURE__*/ (0, _jsxruntime.jsxs)(_jsxruntime.Fragment, {
92
- children: [
93
- /*#__PURE__*/ (0, _jsxruntime.jsx)(_material.Typography, {
94
- variant: "caption",
95
- children: ' → '
96
- }),
97
- /*#__PURE__*/ (0, _jsxruntime.jsxs)(_material.Typography, {
98
- variant: "caption",
99
- children: [
100
- end.formattedDate,
101
- " - ",
102
- /*#__PURE__*/ (0, _jsxruntime.jsx)("strong", {
103
- children: end.formattedTime
104
- })
105
- ]
106
- })
107
- ]
108
- })
109
- ]
110
- })
111
- ]
112
- })
113
- });
114
- }
115
- function AnnotationPreview({ spec, ...props }) {
116
- const { data, isFetching, error } = (0, _runtime.useAnnotationData)(spec);
117
- const { formatWithUserTimeZone } = (0, _components.useTimeZone)();
118
- const [showAll, setShowAll] = (0, _react.useState)(false);
119
- const annotationsToShow = showAll ? data : data?.slice(0, 1);
120
- let notShown = 0;
121
- if (data && data?.length > 0 && annotationsToShow) {
122
- notShown = data.length - annotationsToShow.length;
123
- }
124
- const stateIndicator = (0, _react.useMemo)(()=>{
125
- if (isFetching) {
126
- return /*#__PURE__*/ (0, _jsxruntime.jsx)(_material.CircularProgress, {
127
- "aria-label": "loading",
128
- size: "1.125rem"
129
- });
130
- } else if (error) {
131
- return /*#__PURE__*/ (0, _jsxruntime.jsx)(_components.InfoTooltip, {
132
- description: error.toString(),
133
- children: /*#__PURE__*/ (0, _jsxruntime.jsx)(_material.IconButton, {
134
- "aria-label": "preview errors",
135
- size: "small",
136
- children: /*#__PURE__*/ (0, _jsxruntime.jsx)(_Alert.default, {
137
- fontSize: "inherit",
138
- sx: {
139
- color: (theme)=>theme.palette.error.main
140
- }
141
- })
142
- })
143
- });
144
- }
145
- }, [
146
- isFetching,
147
- error
148
- ]);
149
- return /*#__PURE__*/ (0, _jsxruntime.jsxs)(_material.Card, {
150
- variant: "outlined",
151
- ...props,
152
- children: [
153
- /*#__PURE__*/ (0, _jsxruntime.jsx)(_material.CardHeader, {
154
- title: /*#__PURE__*/ (0, _jsxruntime.jsxs)(_material.Stack, {
155
- direction: "row",
156
- justifyContent: "space-between",
157
- children: [
158
- /*#__PURE__*/ (0, _jsxruntime.jsx)(_material.Typography, {
159
- variant: "h4",
160
- children: "Preview Annotations"
161
- }),
162
- stateIndicator
163
- ]
164
- })
165
- }),
166
- /*#__PURE__*/ (0, _jsxruntime.jsxs)(_material.CardContent, {
167
- sx: {
168
- display: 'flex',
169
- flexWrap: 'wrap',
170
- gap: 1,
171
- paddingY: 0
172
- },
173
- children: [
174
- annotationsToShow?.map((item, index)=>/*#__PURE__*/ (0, _jsxruntime.jsx)(AnnotationPreviewCard, {
175
- value: item,
176
- formatWithUserTimeZone: formatWithUserTimeZone,
177
- sx: {
178
- width: '100%'
179
- }
180
- }, index)),
181
- notShown > 0 && /*#__PURE__*/ (0, _jsxruntime.jsx)(_material.Chip, {
182
- onClick: ()=>setShowAll(true),
183
- variant: "outlined",
184
- size: "small",
185
- label: `+${notShown} more`
186
- }),
187
- showAll && data && data.length > 1 && /*#__PURE__*/ (0, _jsxruntime.jsx)(_material.Chip, {
188
- onClick: ()=>setShowAll(false),
189
- variant: "outlined",
190
- size: "small",
191
- label: "-"
192
- })
193
- ]
194
- })
195
- ]
196
- });
197
- }
@@ -1,30 +0,0 @@
1
- // Copyright The Perses Authors
2
- // Licensed under the Apache License, Version 2.0 (the "License");
3
- // you may not use this file except in compliance with the License.
4
- // You may obtain a copy of the License at
5
- //
6
- // http://www.apache.org/licenses/LICENSE-2.0
7
- //
8
- // Unless required by applicable law or agreed to in writing, software
9
- // distributed under the License is distributed on an "AS IS" BASIS,
10
- // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11
- // See the License for the specific language governing permissions and
12
- // limitations under the License.
13
- "use strict";
14
- Object.defineProperty(exports, "__esModule", {
15
- value: true
16
- });
17
- _export_star(require("./AnnotationEditorForm"), exports);
18
- function _export_star(from, to) {
19
- Object.keys(from).forEach(function(k) {
20
- if (k !== "default" && !Object.prototype.hasOwnProperty.call(to, k)) {
21
- Object.defineProperty(to, k, {
22
- enumerable: true,
23
- get: function() {
24
- return from[k];
25
- }
26
- });
27
- }
28
- });
29
- return from;
30
- }
@@ -1,23 +0,0 @@
1
- // Copyright The Perses Authors
2
- // Licensed under the Apache License, Version 2.0 (the "License");
3
- // you may not use this file except in compliance with the License.
4
- // You may obtain a copy of the License at
5
- //
6
- // http://www.apache.org/licenses/LICENSE-2.0
7
- //
8
- // Unless required by applicable law or agreed to in writing, software
9
- // distributed under the License is distributed on an "AS IS" BASIS,
10
- // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11
- // See the License for the specific language governing permissions and
12
- // limitations under the License.
13
- "use strict";
14
- Object.defineProperty(exports, "__esModule", {
15
- value: true
16
- });
17
- Object.defineProperty(exports, "DEFAULT_ANNOTATION_COLOR", {
18
- enumerable: true,
19
- get: function() {
20
- return DEFAULT_ANNOTATION_COLOR;
21
- }
22
- });
23
- const DEFAULT_ANNOTATION_COLOR = '#FF6B6B';
@@ -1,31 +0,0 @@
1
- // Copyright The Perses Authors
2
- // Licensed under the Apache License, Version 2.0 (the "License");
3
- // you may not use this file except in compliance with the License.
4
- // You may obtain a copy of the License at
5
- //
6
- // http://www.apache.org/licenses/LICENSE-2.0
7
- //
8
- // Unless required by applicable law or agreed to in writing, software
9
- // distributed under the License is distributed on an "AS IS" BASIS,
10
- // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11
- // See the License for the specific language governing permissions and
12
- // limitations under the License.
13
- "use strict";
14
- Object.defineProperty(exports, "__esModule", {
15
- value: true
16
- });
17
- _export_star(require("./AnnotationEditorForm"), exports);
18
- _export_star(require("./constants"), exports);
19
- function _export_star(from, to) {
20
- Object.keys(from).forEach(function(k) {
21
- if (k !== "default" && !Object.prototype.hasOwnProperty.call(to, k)) {
22
- Object.defineProperty(to, k, {
23
- enumerable: true,
24
- get: function() {
25
- return from[k];
26
- }
27
- });
28
- }
29
- });
30
- return from;
31
- }
@@ -1,49 +0,0 @@
1
- // Copyright The Perses Authors
2
- // Licensed under the Apache License, Version 2.0 (the "License");
3
- // you may not use this file except in compliance with the License.
4
- // You may obtain a copy of the License at
5
- //
6
- // http://www.apache.org/licenses/LICENSE-2.0
7
- //
8
- // Unless required by applicable law or agreed to in writing, software
9
- // distributed under the License is distributed on an "AS IS" BASIS,
10
- // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11
- // See the License for the specific language governing permissions and
12
- // limitations under the License.
13
- "use strict";
14
- Object.defineProperty(exports, "__esModule", {
15
- value: true
16
- });
17
- Object.defineProperty(exports, "CalculationSelector", {
18
- enumerable: true,
19
- get: function() {
20
- return CalculationSelector;
21
- }
22
- });
23
- const _jsxruntime = require("react/jsx-runtime");
24
- const _components = require("@perses-dev/components");
25
- const _model = require("../../model");
26
- const CALC_OPTIONS = Object.entries(_model.CALCULATIONS_CONFIG).map(([id, config])=>{
27
- return {
28
- id: id,
29
- ...config
30
- };
31
- });
32
- function CalculationSelector({ value, onChange }) {
33
- const handleCalculationChange = (_, newValue)=>{
34
- onChange(newValue.id);
35
- };
36
- const calcConfig = _model.CALCULATIONS_CONFIG[value];
37
- return /*#__PURE__*/ (0, _jsxruntime.jsx)(_components.OptionsEditorControl, {
38
- label: "Calculation",
39
- control: /*#__PURE__*/ (0, _jsxruntime.jsx)(_components.SettingsAutocomplete, {
40
- value: {
41
- ...calcConfig,
42
- id: value
43
- },
44
- options: CALC_OPTIONS,
45
- onChange: handleCalculationChange,
46
- disableClearable: true
47
- })
48
- });
49
- }
@@ -1,30 +0,0 @@
1
- // Copyright The Perses Authors
2
- // Licensed under the Apache License, Version 2.0 (the "License");
3
- // you may not use this file except in compliance with the License.
4
- // You may obtain a copy of the License at
5
- //
6
- // http://www.apache.org/licenses/LICENSE-2.0
7
- //
8
- // Unless required by applicable law or agreed to in writing, software
9
- // distributed under the License is distributed on an "AS IS" BASIS,
10
- // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11
- // See the License for the specific language governing permissions and
12
- // limitations under the License.
13
- "use strict";
14
- Object.defineProperty(exports, "__esModule", {
15
- value: true
16
- });
17
- _export_star(require("./CalculationSelector"), exports);
18
- function _export_star(from, to) {
19
- Object.keys(from).forEach(function(k) {
20
- if (k !== "default" && !Object.prototype.hasOwnProperty.call(to, k)) {
21
- Object.defineProperty(to, k, {
22
- enumerable: true,
23
- get: function() {
24
- return from[k];
25
- }
26
- });
27
- }
28
- });
29
- return from;
30
- }