@datarecce/ui 0.2.0 → 0.2.1-nightly.20260410

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 (168) hide show
  1. package/dist/AuthModal-DkDGa1jY.js +7 -0
  2. package/dist/AuthModal-DkDGa1jY.js.map +1 -0
  3. package/dist/{RouteConfigContext-z8YNimdP.d.ts → RouteConfigContext-DWFg6bll.d.ts} +13 -14
  4. package/dist/RouteConfigContext-DWFg6bll.d.ts.map +1 -0
  5. package/dist/{RunProgress-DyFIALbI.d.ts → RunProgress-CyDIiyNR.d.ts} +18 -18
  6. package/dist/RunProgress-CyDIiyNR.d.ts.map +1 -0
  7. package/dist/{ScreenshotDataGrid-BfxYUThx.d.ts → ScreenshotDataGrid-BAsPWcde.d.ts} +6 -7
  8. package/dist/ScreenshotDataGrid-BAsPWcde.d.ts.map +1 -0
  9. package/dist/{SplitPane-B-BLxZaQ.d.ts → SplitPane-C-WArAED.d.ts} +301 -103
  10. package/dist/SplitPane-C-WArAED.d.ts.map +1 -0
  11. package/dist/advanced.d.ts +34 -9
  12. package/dist/advanced.d.ts.map +1 -1
  13. package/dist/advanced.js +1 -1
  14. package/dist/advanced.js.map +1 -1
  15. package/dist/api-E1dkaTi_.js +3 -0
  16. package/dist/api-E1dkaTi_.js.map +1 -0
  17. package/dist/{api-ZZ4cc9b9.d.ts → api-ZsJanCwW.d.ts} +27 -28
  18. package/dist/api-ZsJanCwW.d.ts.map +1 -0
  19. package/dist/api.d.ts +2 -2
  20. package/dist/api.js +1 -1
  21. package/dist/{colors--47Kkns4.js → colors-BbPSDR1X.js} +2 -2
  22. package/dist/colors-BbPSDR1X.js.map +1 -0
  23. package/dist/components-run.d.ts +3 -6
  24. package/dist/components-run.js +1 -1
  25. package/dist/components.d.ts +9 -22
  26. package/dist/components.js +1 -1
  27. package/dist/{constants-DD5vJv2q.js → constants-D-hOGDbU.js} +1 -1
  28. package/dist/{constants-DD5vJv2q.js.map → constants-D-hOGDbU.js.map} +1 -1
  29. package/dist/constants.d.ts +1 -1
  30. package/dist/constants.js +1 -1
  31. package/dist/contexts.d.ts +4 -5
  32. package/dist/contexts.js +1 -1
  33. package/dist/fetchClient-BVyYwVMf.js +3 -0
  34. package/dist/fetchClient-BVyYwVMf.js.map +1 -0
  35. package/dist/fetchClient-CTnJ39EA.d.ts +19 -0
  36. package/dist/fetchClient-CTnJ39EA.d.ts.map +1 -0
  37. package/dist/hooks.d.ts +2 -14
  38. package/dist/hooks.js +1 -1
  39. package/dist/{index-h_fw6R9U.d.ts → index-3E87oNEi.d.ts} +43 -8
  40. package/dist/index-3E87oNEi.d.ts.map +1 -0
  41. package/dist/{index-o48TPoFN.d.ts → index-B5W4Cu7o.d.ts} +38 -28
  42. package/dist/index-B5W4Cu7o.d.ts.map +1 -0
  43. package/dist/{index-CiPcALu4.d.ts → index-BJOCIgE1.d.ts} +6 -4
  44. package/dist/index-BJOCIgE1.d.ts.map +1 -0
  45. package/dist/{colors-vY9Yzui0.d.ts → index-CHJ0PCEg.d.ts} +131 -6
  46. package/dist/index-CHJ0PCEg.d.ts.map +1 -0
  47. package/dist/{index-CkXLPYZY.d.ts → index-CZ7gueQV.d.ts} +1 -1
  48. package/dist/index-CZ7gueQV.d.ts.map +1 -0
  49. package/dist/{index-DVoQsx5c.d.ts → index-CaSERvsu.d.ts} +148 -146
  50. package/dist/index-CaSERvsu.d.ts.map +1 -0
  51. package/dist/{index-Ba3hp2Ng.d.ts → index-D2OTg1N4.d.ts} +92 -91
  52. package/dist/index-D2OTg1N4.d.ts.map +1 -0
  53. package/dist/{index-DTCpHvX_.d.ts → index-DCbl1RRQ.d.ts} +12 -11
  54. package/dist/index-DCbl1RRQ.d.ts.map +1 -0
  55. package/dist/{index-BFkbe0aF.d.ts → index-ielAdd0Z.d.ts} +21 -15
  56. package/dist/index-ielAdd0Z.d.ts.map +1 -0
  57. package/dist/index.d.ts +17 -24
  58. package/dist/index.js +1 -1
  59. package/dist/{flag-CiR2E5oz.d.ts → instanceInfo-Ch_8ckjl.d.ts} +86 -73
  60. package/dist/instanceInfo-Ch_8ckjl.d.ts.map +1 -0
  61. package/dist/keepAlive-DbC0X4zr.js +3 -0
  62. package/dist/keepAlive-DbC0X4zr.js.map +1 -0
  63. package/dist/lib/api/{axiosClient.d.ts → queryClient.d.ts} +2 -2
  64. package/dist/lib/api/queryClient.d.ts.map +1 -0
  65. package/dist/lib/api/{axiosClient.js → queryClient.js} +1 -1
  66. package/dist/lib/api/queryClient.js.map +1 -0
  67. package/dist/lib/api/track.d.ts.map +1 -1
  68. package/dist/lib/api/track.js +2 -1
  69. package/dist/lib/api/track.js.map +1 -0
  70. package/dist/lib/api/user.d.ts +2 -2
  71. package/dist/lib/api/user.d.ts.map +1 -1
  72. package/dist/lib/api/user.js +2 -1
  73. package/dist/lib/api/user.js.map +1 -0
  74. package/dist/lib/const.d.ts.map +1 -1
  75. package/dist/lib/const.js +2 -1
  76. package/dist/lib/const.js.map +1 -0
  77. package/dist/lib/result/ResultErrorFallback.d.ts.map +1 -1
  78. package/dist/lib/result/ResultErrorFallback.js +2 -1
  79. package/dist/lib/result/ResultErrorFallback.js.map +1 -0
  80. package/dist/{index-C_kD4ZQ3.d.ts → lineage-Bprdx2yV.d.ts} +398 -168
  81. package/dist/lineage-Bprdx2yV.d.ts.map +1 -0
  82. package/dist/{primitives-CgGUvwHB.d.ts → primitives-DO8U1w1D.d.ts} +197 -22
  83. package/dist/primitives-DO8U1w1D.d.ts.map +1 -0
  84. package/dist/primitives.d.ts +7 -11
  85. package/dist/primitives.js +1 -1
  86. package/dist/result.d.ts +1 -2
  87. package/dist/result.js +1 -1
  88. package/dist/src-9c_XVr7Z.js +12 -0
  89. package/dist/src-9c_XVr7Z.js.map +1 -0
  90. package/dist/style.css +308 -0
  91. package/dist/styles.css +2 -2
  92. package/dist/theme-B_XT39eO.js +3 -0
  93. package/dist/theme-B_XT39eO.js.map +1 -0
  94. package/dist/theme.d.ts +1 -2
  95. package/dist/theme.js +1 -1
  96. package/dist/{types-CFbNxrx2.d.ts → types-BlAAcT0V.d.ts} +7 -7
  97. package/dist/types-BlAAcT0V.d.ts.map +1 -0
  98. package/dist/{types-CZre3j02.d.ts → types-EUGeM5p7.d.ts} +15 -4
  99. package/dist/types-EUGeM5p7.d.ts.map +1 -0
  100. package/dist/types.d.ts +10 -14
  101. package/dist/types.js.map +1 -1
  102. package/dist/useThemeColors-OwCMwSrx.d.ts +79 -0
  103. package/dist/useThemeColors-OwCMwSrx.d.ts.map +1 -0
  104. package/dist/utils-BJxZkzLz.js +3 -0
  105. package/dist/utils-BJxZkzLz.js.map +1 -0
  106. package/dist/utils-Crcz1Rb5.js +6 -0
  107. package/dist/utils-Crcz1Rb5.js.map +1 -0
  108. package/dist/utils.d.ts +2 -6
  109. package/dist/utils.js +1 -1
  110. package/package.json +45 -19
  111. package/dist/AuthModal-C8LetZNB.js +0 -23
  112. package/dist/AuthModal-C8LetZNB.js.map +0 -1
  113. package/dist/LineageCanvas-CR38SDYr.d.ts +0 -41
  114. package/dist/LineageCanvas-CR38SDYr.d.ts.map +0 -1
  115. package/dist/ResultErrorFallback-C7c-TN1p.js +0 -3
  116. package/dist/ResultErrorFallback-C7c-TN1p.js.map +0 -1
  117. package/dist/RouteConfigContext-z8YNimdP.d.ts.map +0 -1
  118. package/dist/RunProgress-DyFIALbI.d.ts.map +0 -1
  119. package/dist/ScreenshotDataGrid-BfxYUThx.d.ts.map +0 -1
  120. package/dist/SplitPane-B-BLxZaQ.d.ts.map +0 -1
  121. package/dist/api-ZZ4cc9b9.d.ts.map +0 -1
  122. package/dist/api-_i6BZPkM.js +0 -3
  123. package/dist/api-_i6BZPkM.js.map +0 -1
  124. package/dist/colors--47Kkns4.js.map +0 -1
  125. package/dist/colors-vY9Yzui0.d.ts.map +0 -1
  126. package/dist/const-DbXBkrxT.js +0 -3
  127. package/dist/const-DbXBkrxT.js.map +0 -1
  128. package/dist/flag-CiR2E5oz.d.ts.map +0 -1
  129. package/dist/flag-koeDAqr3.js +0 -3
  130. package/dist/flag-koeDAqr3.js.map +0 -1
  131. package/dist/index-BFkbe0aF.d.ts.map +0 -1
  132. package/dist/index-Ba3hp2Ng.d.ts.map +0 -1
  133. package/dist/index-C_kD4ZQ3.d.ts.map +0 -1
  134. package/dist/index-CiPcALu4.d.ts.map +0 -1
  135. package/dist/index-CkXLPYZY.d.ts.map +0 -1
  136. package/dist/index-DTCpHvX_.d.ts.map +0 -1
  137. package/dist/index-DVoQsx5c.d.ts.map +0 -1
  138. package/dist/index-DmwYRgDR.d.ts +0 -192
  139. package/dist/index-DmwYRgDR.d.ts.map +0 -1
  140. package/dist/index-N8N7XmRj.d.ts +0 -130
  141. package/dist/index-N8N7XmRj.d.ts.map +0 -1
  142. package/dist/index-h_fw6R9U.d.ts.map +0 -1
  143. package/dist/index-o48TPoFN.d.ts.map +0 -1
  144. package/dist/keepAlive-CEzyrDfg.js +0 -3
  145. package/dist/keepAlive-CEzyrDfg.js.map +0 -1
  146. package/dist/lib/api/axiosClient.d.ts.map +0 -1
  147. package/dist/lib/api/axiosClient.js.map +0 -1
  148. package/dist/primitives-CgGUvwHB.d.ts.map +0 -1
  149. package/dist/src-BgHSbbHk.js +0 -67
  150. package/dist/src-BgHSbbHk.js.map +0 -1
  151. package/dist/theme-CeWzymUn.js +0 -64
  152. package/dist/theme-CeWzymUn.js.map +0 -1
  153. package/dist/track-9ZQpBlUK.js +0 -3
  154. package/dist/track-9ZQpBlUK.js.map +0 -1
  155. package/dist/types-CFbNxrx2.d.ts.map +0 -1
  156. package/dist/types-CZre3j02.d.ts.map +0 -1
  157. package/dist/useRecceServerFlag-Bg5R67J4.js +0 -3
  158. package/dist/useRecceServerFlag-Bg5R67J4.js.map +0 -1
  159. package/dist/useThemeColors--prVbMmM.js +0 -3
  160. package/dist/useThemeColors--prVbMmM.js.map +0 -1
  161. package/dist/useThemeColors-DHEroo8f.d.ts +0 -104
  162. package/dist/useThemeColors-DHEroo8f.d.ts.map +0 -1
  163. package/dist/user-DMT7E0fc.js +0 -3
  164. package/dist/user-DMT7E0fc.js.map +0 -1
  165. package/dist/utils-CW2skXm_.js +0 -3
  166. package/dist/utils-CW2skXm_.js.map +0 -1
  167. package/dist/utils-CXWhfyxC.js +0 -5
  168. package/dist/utils-CXWhfyxC.js.map +0 -1
@@ -1,4 +1,98 @@
1
1
 
2
+ import { Theme } from "@mui/material/styles";
3
+ import * as _$ag_grid_community0 from "ag-grid-community";
4
+ import * as _$_mui_material0 from "@mui/material";
5
+
6
+ //#region src/components/data/agGridTheme.d.ts
7
+ /**
8
+ * Light theme for AG Grid data grids
9
+ */
10
+ declare const dataGridThemeLight: _$ag_grid_community0.Theme<_$ag_grid_community0.ThemeDefaultParams>;
11
+ /**
12
+ * Dark theme for AG Grid data grids
13
+ */
14
+ declare const dataGridThemeDark: _$ag_grid_community0.Theme<_$ag_grid_community0.ThemeDefaultParams>;
15
+ //#endregion
16
+ //#region src/theme/chartTheme.d.ts
17
+ /**
18
+ * Shared Chart.js theme utilities for dark mode support
19
+ */
20
+ interface ChartThemeColors {
21
+ gridColor: string;
22
+ textColor: string;
23
+ borderColor: string;
24
+ tooltipBackgroundColor: string;
25
+ tooltipTextColor: string;
26
+ }
27
+ /**
28
+ * Get theme-aware colors for Chart.js charts
29
+ * @param isDark - Whether dark mode is active
30
+ * @returns Theme colors for Chart.js configuration
31
+ */
32
+ declare function getChartThemeColors(isDark: boolean): ChartThemeColors;
33
+ /**
34
+ * Get Chart.js scale options with theme-aware colors
35
+ * @param isDark - Whether dark mode is active
36
+ * @param showGrid - Whether to show grid lines
37
+ * @returns Partial scale options for Chart.js
38
+ */
39
+ declare function getThemedScaleOptions(isDark: boolean, showGrid?: boolean): {
40
+ grid: {
41
+ color: string | undefined;
42
+ display: boolean;
43
+ };
44
+ ticks: {
45
+ color: string;
46
+ };
47
+ border: {
48
+ color: string;
49
+ };
50
+ };
51
+ /**
52
+ * Get Chart.js plugin options with theme-aware colors
53
+ * @param isDark - Whether dark mode is active
54
+ * @returns Plugin options for Chart.js (legend, title, tooltip)
55
+ */
56
+ declare function getThemedPluginOptions(isDark: boolean): {
57
+ legend: {
58
+ labels: {
59
+ color: string;
60
+ };
61
+ };
62
+ title: {
63
+ color: string;
64
+ };
65
+ tooltip: {
66
+ backgroundColor: string;
67
+ titleColor: string;
68
+ bodyColor: string;
69
+ borderColor: string;
70
+ borderWidth: number;
71
+ };
72
+ };
73
+ declare const CURRENT_BAR_COLOR = "#63B3ED";
74
+ declare const BASE_BAR_COLOR = "#F6AD55";
75
+ declare const CURRENT_BAR_COLOR_WITH_ALPHA = "#63B3EDA5";
76
+ declare const BASE_BAR_COLOR_WITH_ALPHA = "#F6AD55A5";
77
+ declare const CURRENT_BAR_COLOR_DARK = "#90CDF4";
78
+ declare const BASE_BAR_COLOR_DARK = "#FBD38D";
79
+ declare const CURRENT_BAR_COLOR_DARK_WITH_ALPHA = "#90CDF4A5";
80
+ declare const BASE_BAR_COLOR_DARK_WITH_ALPHA = "#FBD38DA5";
81
+ declare const INFO_VAL_COLOR = "#63B3ED";
82
+ declare const INFO_VAL_COLOR_DARK = "#90CDF4";
83
+ /**
84
+ * Get theme-aware bar colors for charts
85
+ * @param isDark - Whether dark mode is active
86
+ * @returns Object with current and base bar colors
87
+ */
88
+ declare function getBarColors(isDark: boolean): {
89
+ current: string;
90
+ base: string;
91
+ currentWithAlpha: string;
92
+ baseWithAlpha: string;
93
+ info: string;
94
+ };
95
+ //#endregion
2
96
  //#region src/theme/colors.d.ts
3
97
  /**
4
98
  * Recce brand colors and palette definitions
@@ -11,9 +105,7 @@
11
105
  * ui/src/components/ui/mui-theme.ts for consistency.
12
106
  */
13
107
  declare const colors: {
14
- /** White color */
15
- readonly white: "#FFFFFF";
16
- /** Black color */
108
+ /** White color */readonly white: "#FFFFFF"; /** Black color */
17
109
  readonly black: "#000000";
18
110
  /**
19
111
  * Primary brand color - Orange/Coral
@@ -197,7 +289,7 @@ declare const colors: {
197
289
  readonly warning: {
198
290
  readonly main: "#EAB308";
199
291
  readonly light: "#FACC15";
200
- readonly dark: "#CA8A04";
292
+ readonly dark: "#78350F";
201
293
  readonly contrastText: "#000000";
202
294
  };
203
295
  readonly error: {
@@ -251,5 +343,38 @@ declare const semanticVariantMap: Record<string, number>;
251
343
  */
252
344
  declare function token(path: string): string | undefined;
253
345
  //#endregion
254
- export { semanticVariantMap as a, colors as i, SemanticColorVariant as n, token as o, colorAliases as r, ColorShade as t };
255
- //# sourceMappingURL=colors-vY9Yzui0.d.ts.map
346
+ //#region src/theme/theme.d.ts
347
+ /**
348
+ * MUI Theme configuration with CSS Variables mode
349
+ *
350
+ * This theme uses MUI 7's CSS Variables mode with `colorSchemeSelector: 'class'`
351
+ * to toggle between light and dark modes using the `.dark` class on the document.
352
+ * This integrates with the ThemeContext which manages the class toggle.
353
+ *
354
+ * Color values and component variants are aligned with the main Recce theme at
355
+ * ui/src/components/ui/mui-theme.ts for consistency.
356
+ */
357
+ /**
358
+ * MUI Theme with CSS Variables mode enabled
359
+ *
360
+ * Uses `colorSchemeSelector: 'class'` to switch themes via `.dark` class,
361
+ * which is toggled by the ThemeContext provider.
362
+ *
363
+ * Usage:
364
+ * ```tsx
365
+ * import { ThemeProvider } from '@mui/material/styles';
366
+ * import { theme } from '@datarecce/ui/theme';
367
+ *
368
+ * <ThemeProvider theme={theme}>
369
+ * <App />
370
+ * </ThemeProvider>
371
+ * ```
372
+ */
373
+ declare const theme: _$_mui_material0.Theme;
374
+ /**
375
+ * Theme type export for consumers who need to type their theme
376
+ */
377
+ type RecceTheme = typeof theme;
378
+ //#endregion
379
+ export { getThemedPluginOptions as C, dataGridThemeLight as E, getChartThemeColors as S, dataGridThemeDark as T, CURRENT_BAR_COLOR_WITH_ALPHA as _, SemanticColorVariant as a, INFO_VAL_COLOR_DARK as b, semanticVariantMap as c, BASE_BAR_COLOR_DARK as d, BASE_BAR_COLOR_DARK_WITH_ALPHA as f, CURRENT_BAR_COLOR_DARK_WITH_ALPHA as g, CURRENT_BAR_COLOR_DARK as h, ColorShade as i, token as l, CURRENT_BAR_COLOR as m, RecceTheme as n, colorAliases as o, BASE_BAR_COLOR_WITH_ALPHA as p, theme as r, colors as s, Theme as t, BASE_BAR_COLOR as u, ChartThemeColors as v, getThemedScaleOptions as w, getBarColors as x, INFO_VAL_COLOR as y };
380
+ //# sourceMappingURL=index-CHJ0PCEg.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index-CHJ0PCEg.d.ts","names":[],"sources":["../src/components/data/agGridTheme.ts","../src/theme/chartTheme.ts","../src/theme/colors.ts","../src/theme/theme.ts"],"mappings":";;;;;;;;;cAkBa,kBAAA,EAAkB,oBAAA,CAAA,KAAA,CAa7B,oBAAA,CAb6B,kBAAA;;AAA/B;;cAkBa,iBAAA,EAAiB,oBAAA,CAAA,KAAA,CAa5B,oBAAA,CAb4B,kBAAA;;;;;;UChCb,gBAAA;EACf,SAAA;EACA,SAAA;EACA,WAAA;EACA,sBAAA;EACA,gBAAA;AAAA;AD2BF;;;;;AAAA,iBCnBgB,mBAAA,CAAoB,MAAA,YAAkB,gBAAA;;;AAbtD;;;;iBA6BgB,qBAAA,CAAsB,MAAA,WAAiB,QAAA;;;;;;;;;;;;AAAvD;;;;;AAAA,iBAqBgB,sBAAA,CAAuB,MAAA;;;;;;;;;;;;;;;;;cAsB1B,iBAAA;AAAA,cACA,cAAA;AAAA,cACA,4BAAA;AAAA,cACA,yBAAA;AAAA,cAGA,sBAAA;AAAA,cACA,mBAAA;AAAA,cACA,iCAAA;AAAA,cACA,8BAAA;AAAA,cAGA,cAAA;AAAA,cACA,mBAAA;;AAbb;;;;iBAoBgB,YAAA,CAAa,MAAA;;;;;;;;;;;;;;AD9E7B;;;;;cEPa,MAAA;EFsCX,6CAb4B;EAAA;;;;AChC9B;;;;;;;;;;;;;;EAaoC;;AAgBpC;;EAhBoC;;;;;;;;;;;;;EAqCpB;;;;EAAA;;;;;;;;;;;;;;AAsBhB;;;;;;;;;;;;;;;;EAGsC;;;;EAAA;;;;;;;;;;;;;EAKQ;;AAC9C;;EAD8C;;;;;;;;;;;;;EAY9B;;;;EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cCyIH,YAAA,EAAc,MAAA,sBAA4B,MAAA;;;;KAQ3C,UAAA;;;;KAgBA,oBAAA;;;;;;;;cASC,kBAAA,EAAoB,MAAA;;;;;;;;;;;;;;;;iBAwBjB,KAAA,CAAM,IAAA;;;;;;;;AFhRtB;;;;;AAkBA;;;;;;;;AChCA;;;;;;;;ADgCA,cGkmBa,KAAA,EAuMX,gBAAA,CAvMgB,KAAA;;;AFrnBlB;KEi0BY,UAAA,UAAoB,KAAA"}
@@ -10,4 +10,4 @@ declare const DisableTooltipMessages: {
10
10
  type DisableTooltipMessageKey = keyof typeof DisableTooltipMessages;
11
11
  //#endregion
12
12
  export { DisableTooltipMessages as n, DisableTooltipMessageKey as t };
13
- //# sourceMappingURL=index-CkXLPYZY.d.ts.map
13
+ //# sourceMappingURL=index-CZ7gueQV.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index-CZ7gueQV.d.ts","names":[],"sources":["../src/constants/tooltipMessage.ts"],"mappings":";;;AAIA;;;cAAa,sBAAA;EAAA,SAEH,aAAA;AAAA;AAAA,KAEE,wBAAA,gBAAwC,sBAAA"}
@@ -1,9 +1,149 @@
1
1
 
2
- import { i as RecceInstanceInfo } from "./flag-CiR2E5oz.js";
3
- import * as _tanstack_react_query5 from "@tanstack/react-query";
2
+ import { t as RecceInstanceInfo } from "./instanceInfo-Ch_8ckjl.js";
3
+ import * as _$_tanstack_react_query0 from "@tanstack/react-query";
4
4
  import { Dispatch, ReactNode, SetStateAction } from "react";
5
- import * as react_jsx_runtime130 from "react/jsx-runtime";
5
+ import * as _$react_jsx_runtime0 from "react/jsx-runtime";
6
6
 
7
+ //#region src/contexts/instance/types.d.ts
8
+ /**
9
+ * Feature mode for the Recce instance.
10
+ * - "read only": No modifications allowed
11
+ * - "metadata only": Database queries disabled
12
+ * - null: Full functionality enabled
13
+ */
14
+ type RecceFeatureMode = "read only" | "metadata only" | null;
15
+ /**
16
+ * Feature toggles that control what actions are available in the UI.
17
+ * These are derived from the server's instance info based on server mode.
18
+ */
19
+ interface RecceFeatureToggles {
20
+ /** Current feature mode based on server_mode */
21
+ mode: RecceFeatureMode;
22
+ /** Disable saving state to file */
23
+ disableSaveToFile: boolean;
24
+ /** Disable exporting state file */
25
+ disableExportStateFile: boolean;
26
+ /** Disable importing state file */
27
+ disableImportStateFile: boolean;
28
+ /** Disable updating checklist */
29
+ disableUpdateChecklist: boolean;
30
+ /** Disable database query execution */
31
+ disableDatabaseQuery: boolean;
32
+ /** Disable view action dropdown menu */
33
+ disableViewActionDropdown: boolean;
34
+ /** Disable node action dropdown menu */
35
+ disableNodeActionDropdown: boolean;
36
+ /** Disable share functionality */
37
+ disableShare: boolean;
38
+ }
39
+ /**
40
+ * Instance information exposed through the RecceInstanceContext.
41
+ * Contains feature toggles and session information.
42
+ */
43
+ interface InstanceInfoType {
44
+ /** Whether running in single environment mode */
45
+ singleEnv: boolean;
46
+ /** Whether user is authenticated */
47
+ authed: boolean;
48
+ /** Feature toggles based on server mode */
49
+ featureToggles: RecceFeatureToggles;
50
+ /** When the instance lifetime expires */
51
+ lifetimeExpiredAt?: Date;
52
+ /** URL for sharing the instance */
53
+ shareUrl?: string;
54
+ /** Current session ID */
55
+ sessionId?: string;
56
+ /** Python runtime version (e.g., "3.9.18") */
57
+ pythonVersion?: string;
58
+ }
59
+ /**
60
+ * Default feature toggles with all features enabled.
61
+ */
62
+ declare const defaultFeatureToggles: RecceFeatureToggles;
63
+ /**
64
+ * Default instance info values.
65
+ */
66
+ declare const defaultInstanceInfo: InstanceInfoType;
67
+ //#endregion
68
+ //#region src/contexts/instance/RecceInstanceContext.d.ts
69
+ /**
70
+ * Provider that fetches and processes Recce instance information.
71
+ *
72
+ * This provider:
73
+ * 1. Fetches instance info from the server using useRecceInstanceInfo
74
+ * 2. Computes feature toggles based on server_mode
75
+ * 3. Provides the processed data through context
76
+ *
77
+ * Feature toggles are computed based on:
78
+ * - server_mode: "read-only" disables all modifications
79
+ * - server_mode: "preview" disables database queries but allows metadata operations
80
+ * - single_env: disables checklist updates and sharing
81
+ * - cloud_instance: disables sharing
82
+ *
83
+ * @example
84
+ * ```tsx
85
+ * function App() {
86
+ * return (
87
+ * <RecceProvider api={{ baseUrl: "/api" }}>
88
+ * <RecceInstanceInfoProvider>
89
+ * <MyComponent />
90
+ * </RecceInstanceInfoProvider>
91
+ * </RecceProvider>
92
+ * );
93
+ * }
94
+ * ```
95
+ */
96
+ declare function RecceInstanceInfoProvider({
97
+ children
98
+ }: {
99
+ children: ReactNode;
100
+ }): _$react_jsx_runtime0.JSX.Element;
101
+ /**
102
+ * Hook to access the Recce instance context.
103
+ *
104
+ * Returns the current instance information including feature toggles,
105
+ * authentication status, and session information.
106
+ *
107
+ * @returns InstanceInfoType with feature toggles and session info
108
+ *
109
+ * @example
110
+ * ```tsx
111
+ * function FeatureGate() {
112
+ * const { featureToggles } = useRecceInstanceContext();
113
+ *
114
+ * if (featureToggles.disableDatabaseQuery) {
115
+ * return <div>Database queries are disabled</div>;
116
+ * }
117
+ *
118
+ * return <QueryEditor />;
119
+ * }
120
+ * ```
121
+ */
122
+ declare function useRecceInstanceContext(): InstanceInfoType;
123
+ //#endregion
124
+ //#region src/contexts/instance/useRecceInstanceInfo.d.ts
125
+ /**
126
+ * Hook to fetch Recce instance information from the server.
127
+ *
128
+ * Uses TanStack Query to cache the response and the configured API client.
129
+ * Works both inside RecceProvider (uses configured client) and outside (uses default API client).
130
+ *
131
+ * @returns Query result with RecceInstanceInfo data
132
+ *
133
+ * @example
134
+ * ```tsx
135
+ * function InstanceStatus() {
136
+ * const { data, isLoading, error } = useRecceInstanceInfo();
137
+ *
138
+ * if (isLoading) return <div>Loading...</div>;
139
+ * if (error) return <div>Error loading instance info</div>;
140
+ *
141
+ * return <div>Server mode: {data?.server_mode}</div>;
142
+ * }
143
+ * ```
144
+ */
145
+ declare function useRecceInstanceInfo(): _$_tanstack_react_query0.UseQueryResult<RecceInstanceInfo, Error>;
146
+ //#endregion
7
147
  //#region src/contexts/action/types.d.ts
8
148
  /**
9
149
  * Query parameters for API requests
@@ -137,7 +277,7 @@ declare function RecceActionProvider({
137
277
  onShowRunId,
138
278
  initialRunId,
139
279
  initialHistoryOpen
140
- }: RecceActionProviderProps): react_jsx_runtime130.JSX.Element;
280
+ }: RecceActionProviderProps): _$react_jsx_runtime0.JSX.Element;
141
281
  /**
142
282
  * Hook to access the RecceAction context.
143
283
  *
@@ -184,7 +324,7 @@ declare function IdleTimeoutProvider({
184
324
  children
185
325
  }: {
186
326
  children: ReactNode;
187
- }): react_jsx_runtime130.JSX.Element;
327
+ }): _$react_jsx_runtime0.JSX.Element;
188
328
  /**
189
329
  * Hook to access idle timeout context
190
330
  * @throws Error if used outside IdleTimeoutProvider
@@ -197,7 +337,7 @@ declare function useIdleTimeout(): IdleTimeoutContextType;
197
337
  *
198
338
  * This hook:
199
339
  * - Listens for user activities (focus, mouse, keyboard, scroll)
200
- * - Sends keep-alive requests (throttled at axios layer to minimum 3 seconds)
340
+ * - Sends keep-alive requests (throttled at API layer to minimum 3 seconds)
201
341
  * - Pauses when the tab is inactive (using Page Visibility API)
202
342
  * - Immediately sends a keep-alive when tab becomes active
203
343
  * - Only activates when idle_timeout is configured on the server
@@ -207,143 +347,5 @@ declare function useIdleTimeout(): IdleTimeoutContextType;
207
347
  */
208
348
  declare function useIdleDetection(): void;
209
349
  //#endregion
210
- //#region src/contexts/instance/types.d.ts
211
- /**
212
- * Feature mode for the Recce instance.
213
- * - "read only": No modifications allowed
214
- * - "metadata only": Database queries disabled
215
- * - null: Full functionality enabled
216
- */
217
- type RecceFeatureMode = "read only" | "metadata only" | null;
218
- /**
219
- * Feature toggles that control what actions are available in the UI.
220
- * These are derived from the server's instance info based on server mode.
221
- */
222
- interface RecceFeatureToggles {
223
- /** Current feature mode based on server_mode */
224
- mode: RecceFeatureMode;
225
- /** Disable saving state to file */
226
- disableSaveToFile: boolean;
227
- /** Disable exporting state file */
228
- disableExportStateFile: boolean;
229
- /** Disable importing state file */
230
- disableImportStateFile: boolean;
231
- /** Disable updating checklist */
232
- disableUpdateChecklist: boolean;
233
- /** Disable database query execution */
234
- disableDatabaseQuery: boolean;
235
- /** Disable view action dropdown menu */
236
- disableViewActionDropdown: boolean;
237
- /** Disable node action dropdown menu */
238
- disableNodeActionDropdown: boolean;
239
- /** Disable share functionality */
240
- disableShare: boolean;
241
- }
242
- /**
243
- * Instance information exposed through the RecceInstanceContext.
244
- * Contains feature toggles and session information.
245
- */
246
- interface InstanceInfoType {
247
- /** Whether running in single environment mode */
248
- singleEnv: boolean;
249
- /** Whether user is authenticated */
250
- authed: boolean;
251
- /** Feature toggles based on server mode */
252
- featureToggles: RecceFeatureToggles;
253
- /** When the instance lifetime expires */
254
- lifetimeExpiredAt?: Date;
255
- /** URL for sharing the instance */
256
- shareUrl?: string;
257
- /** Current session ID */
258
- sessionId?: string;
259
- }
260
- /**
261
- * Default feature toggles with all features enabled.
262
- */
263
- declare const defaultFeatureToggles: RecceFeatureToggles;
264
- /**
265
- * Default instance info values.
266
- */
267
- declare const defaultInstanceInfo: InstanceInfoType;
268
- //#endregion
269
- //#region src/contexts/instance/RecceInstanceContext.d.ts
270
- /**
271
- * Provider that fetches and processes Recce instance information.
272
- *
273
- * This provider:
274
- * 1. Fetches instance info from the server using useRecceInstanceInfo
275
- * 2. Computes feature toggles based on server_mode
276
- * 3. Provides the processed data through context
277
- *
278
- * Feature toggles are computed based on:
279
- * - server_mode: "read-only" disables all modifications
280
- * - server_mode: "preview" disables database queries but allows metadata operations
281
- * - single_env: disables checklist updates and sharing
282
- * - cloud_instance: disables sharing
283
- *
284
- * @example
285
- * ```tsx
286
- * function App() {
287
- * return (
288
- * <RecceProvider api={{ baseUrl: "/api" }}>
289
- * <RecceInstanceInfoProvider>
290
- * <MyComponent />
291
- * </RecceInstanceInfoProvider>
292
- * </RecceProvider>
293
- * );
294
- * }
295
- * ```
296
- */
297
- declare function RecceInstanceInfoProvider({
298
- children
299
- }: {
300
- children: ReactNode;
301
- }): react_jsx_runtime130.JSX.Element;
302
- /**
303
- * Hook to access the Recce instance context.
304
- *
305
- * Returns the current instance information including feature toggles,
306
- * authentication status, and session information.
307
- *
308
- * @returns InstanceInfoType with feature toggles and session info
309
- *
310
- * @example
311
- * ```tsx
312
- * function FeatureGate() {
313
- * const { featureToggles } = useRecceInstanceContext();
314
- *
315
- * if (featureToggles.disableDatabaseQuery) {
316
- * return <div>Database queries are disabled</div>;
317
- * }
318
- *
319
- * return <QueryEditor />;
320
- * }
321
- * ```
322
- */
323
- declare function useRecceInstanceContext(): InstanceInfoType;
324
- //#endregion
325
- //#region src/contexts/instance/useRecceInstanceInfo.d.ts
326
- /**
327
- * Hook to fetch Recce instance information from the server.
328
- *
329
- * Uses TanStack Query to cache the response and the configured API client.
330
- * Works both inside RecceProvider (uses configured client) and outside (uses default axios).
331
- *
332
- * @returns Query result with RecceInstanceInfo data
333
- *
334
- * @example
335
- * ```tsx
336
- * function InstanceStatus() {
337
- * const { data, isLoading, error } = useRecceInstanceInfo();
338
- *
339
- * if (isLoading) return <div>Loading...</div>;
340
- * if (error) return <div>Error loading instance info</div>;
341
- *
342
- * return <div>Server mode: {data?.server_mode}</div>;
343
- * }
344
- * ```
345
- */
346
- declare function useRecceInstanceInfo(): _tanstack_react_query5.UseQueryResult<RecceInstanceInfo, Error>;
347
- //#endregion
348
- export { AxiosQueryParams as _, RecceFeatureMode as a, SubmitRunTrackProps as b, defaultInstanceInfo as c, useIdleTimeout as d, IdleTimeoutContextType as f, useRecceActionContext as g, RecceActionProviderProps as h, InstanceInfoType as i, useIdleDetection as l, RecceActionProvider as m, RecceInstanceInfoProvider as n, RecceFeatureToggles as o, useIdleTimeoutSafe as p, useRecceInstanceContext as r, defaultFeatureToggles as s, useRecceInstanceInfo as t, IdleTimeoutProvider as u, RecceActionContextType as v, RecceActionOptions as y };
349
- //# sourceMappingURL=index-DVoQsx5c.d.ts.map
350
+ export { RecceFeatureMode as _, useIdleTimeoutSafe as a, defaultInstanceInfo as b, useRecceActionContext as c, RecceActionOptions as d, SubmitRunTrackProps as f, InstanceInfoType as g, useRecceInstanceContext as h, IdleTimeoutContextType as i, AxiosQueryParams as l, RecceInstanceInfoProvider as m, IdleTimeoutProvider as n, RecceActionProvider as o, useRecceInstanceInfo as p, useIdleTimeout as r, RecceActionProviderProps as s, useIdleDetection as t, RecceActionContextType as u, RecceFeatureToggles as v, defaultFeatureToggles as y };
351
+ //# sourceMappingURL=index-CaSERvsu.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index-CaSERvsu.d.ts","names":[],"sources":["../src/contexts/instance/types.ts","../src/contexts/instance/RecceInstanceContext.tsx","../src/contexts/instance/useRecceInstanceInfo.ts","../src/contexts/action/types.ts","../src/contexts/action/RecceActionContext.tsx","../src/contexts/idle/types.ts","../src/contexts/idle/IdleTimeoutContext.tsx","../src/contexts/idle/useIdleDetection.ts"],"mappings":"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"}