@perses-dev/logs-table-plugin 0.1.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 (173) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +41 -0
  3. package/__mf/css/async/2341.d3010b86.css +1 -0
  4. package/__mf/css/async/5263.d3010b86.css +1 -0
  5. package/__mf/css/async/6759.d3010b86.css +1 -0
  6. package/__mf/font/lato-all-300-normal.322bdf14.woff +0 -0
  7. package/__mf/font/lato-all-400-normal.63513b00.woff +0 -0
  8. package/__mf/font/lato-all-700-normal.bb27db94.woff +0 -0
  9. package/__mf/font/lato-all-900-normal.a27049a3.woff +0 -0
  10. package/__mf/font/lato-latin-300-normal.c5195215.woff2 +0 -0
  11. package/__mf/font/lato-latin-400-normal.b7ffde23.woff2 +0 -0
  12. package/__mf/font/lato-latin-700-normal.d5eb20bc.woff2 +0 -0
  13. package/__mf/font/lato-latin-900-normal.d884a71c.woff2 +0 -0
  14. package/__mf/font/lato-latin-ext-300-normal.abcc64a9.woff2 +0 -0
  15. package/__mf/font/lato-latin-ext-400-normal.6ebed106.woff2 +0 -0
  16. package/__mf/font/lato-latin-ext-700-normal.8697d1d5.woff2 +0 -0
  17. package/__mf/font/lato-latin-ext-900-normal.20a2b415.woff2 +0 -0
  18. package/__mf/js/LogsTable.a40d0de0.js +5 -0
  19. package/__mf/js/async/1143.f9fce74a.js +1 -0
  20. package/__mf/js/async/1553.9685a45a.js +1 -0
  21. package/__mf/js/async/1640.45bfe57d.js +1 -0
  22. package/__mf/js/async/1964.ad38a6aa.js +2 -0
  23. package/__mf/js/async/1964.ad38a6aa.js.LICENSE.txt +9 -0
  24. package/__mf/js/async/2292.0c8c55a4.js +2 -0
  25. package/__mf/js/async/2292.0c8c55a4.js.LICENSE.txt +24 -0
  26. package/__mf/js/async/2641.888f4d12.js +1 -0
  27. package/__mf/js/async/2651.c6ed9c77.js +1 -0
  28. package/__mf/js/async/2836.59bc5080.js +22 -0
  29. package/__mf/js/async/2836.59bc5080.js.LICENSE.txt +9 -0
  30. package/__mf/js/async/2849.eafadb0f.js +2 -0
  31. package/__mf/js/async/2849.eafadb0f.js.LICENSE.txt +37 -0
  32. package/__mf/js/async/3224.dc93eeb9.js +1 -0
  33. package/__mf/js/async/3474.cee21897.js +1 -0
  34. package/__mf/js/async/3863.98efb1d2.js +2 -0
  35. package/__mf/js/async/3863.98efb1d2.js.LICENSE.txt +9 -0
  36. package/__mf/js/async/3960.a5f4b6df.js +2 -0
  37. package/__mf/js/async/3960.a5f4b6df.js.LICENSE.txt +8 -0
  38. package/__mf/js/async/4062.75b22d96.js +1 -0
  39. package/__mf/js/async/4075.3f3a9fce.js +1 -0
  40. package/__mf/js/async/4168.4ce3a017.js +2 -0
  41. package/__mf/js/async/4238.3f9124d4.js +1 -0
  42. package/__mf/js/async/5214.4ce95313.js +1 -0
  43. package/__mf/js/async/5409.360142aa.js +1 -0
  44. package/__mf/js/async/5981.ef618ada.js +2 -0
  45. package/__mf/js/async/5981.ef618ada.js.LICENSE.txt +8 -0
  46. package/__mf/js/async/6292.7a6b1e5f.js +1 -0
  47. package/__mf/js/async/6569.74fed404.js +1 -0
  48. package/__mf/js/async/6770.344b116a.js +1 -0
  49. package/__mf/js/async/694.f6a520bb.js +1 -0
  50. package/__mf/js/async/6981.aaaaabbb.js +110 -0
  51. package/__mf/js/async/6981.aaaaabbb.js.LICENSE.txt +27 -0
  52. package/__mf/js/async/711.d4a39c83.js +1 -0
  53. package/__mf/js/async/738.1432e533.js +1 -0
  54. package/__mf/js/async/7482.e107e534.js +2 -0
  55. package/__mf/js/async/7482.e107e534.js.LICENSE.txt +9 -0
  56. package/__mf/js/async/7623.43e701ce.js +1 -0
  57. package/__mf/js/async/7740.213e06a7.js +1 -0
  58. package/__mf/js/async/8488.c1d50599.js +1 -0
  59. package/__mf/js/async/9173.947266e0.js +2 -0
  60. package/__mf/js/async/9173.947266e0.js.LICENSE.txt +19 -0
  61. package/__mf/js/async/9370.e9cdeb7d.js +7 -0
  62. package/__mf/js/async/9370.e9cdeb7d.js.LICENSE.txt +21 -0
  63. package/__mf/js/async/9815.6b212862.js +37 -0
  64. package/__mf/js/async/__federation_expose_LogsTable.86c05a98.js +1 -0
  65. package/__mf/js/async/lib-router.c75d9d73.js +2 -0
  66. package/__mf/js/async/lib-router.c75d9d73.js.LICENSE.txt +32 -0
  67. package/__mf/js/main.3283cbfb.js +5 -0
  68. package/lib/LogsTable.d.ts +4 -0
  69. package/lib/LogsTable.d.ts.map +1 -0
  70. package/lib/LogsTable.js +33 -0
  71. package/lib/LogsTable.js.map +1 -0
  72. package/lib/LogsTableComponent.d.ts +4 -0
  73. package/lib/LogsTableComponent.d.ts.map +1 -0
  74. package/lib/LogsTableComponent.js +35 -0
  75. package/lib/LogsTableComponent.js.map +1 -0
  76. package/lib/LogsTablePanel.d.ts +4 -0
  77. package/lib/LogsTablePanel.d.ts.map +1 -0
  78. package/lib/LogsTablePanel.js +34 -0
  79. package/lib/LogsTablePanel.js.map +1 -0
  80. package/lib/LogsTableSettingsEditor.d.ts +7 -0
  81. package/lib/LogsTableSettingsEditor.d.ts.map +1 -0
  82. package/lib/LogsTableSettingsEditor.js +49 -0
  83. package/lib/LogsTableSettingsEditor.js.map +1 -0
  84. package/lib/bootstrap.d.ts +2 -0
  85. package/lib/bootstrap.d.ts.map +1 -0
  86. package/lib/bootstrap.js +19 -0
  87. package/lib/bootstrap.js.map +1 -0
  88. package/lib/cjs/LogsTable.js +41 -0
  89. package/lib/cjs/LogsTableComponent.js +43 -0
  90. package/lib/cjs/LogsTablePanel.js +42 -0
  91. package/lib/cjs/LogsTableSettingsEditor.js +57 -0
  92. package/lib/cjs/bootstrap.js +26 -0
  93. package/lib/cjs/components/EmptyLogsState.js +49 -0
  94. package/lib/cjs/components/LogRow/LogDetailsTable.js +71 -0
  95. package/lib/cjs/components/LogRow/LogRow.js +163 -0
  96. package/lib/cjs/components/LogRow/LogTimestamp.js +44 -0
  97. package/lib/cjs/components/LogRow/LogsStyles.js +85 -0
  98. package/lib/cjs/components/LogRow/index.js +37 -0
  99. package/lib/cjs/components/LogsList.js +44 -0
  100. package/lib/cjs/components/VirtualizedLogsList.js +64 -0
  101. package/lib/cjs/components/hooks/useExpandedRows.js +45 -0
  102. package/lib/cjs/env.d.js +14 -0
  103. package/lib/cjs/getPluginModule.js +27 -0
  104. package/lib/cjs/index-federation.js +55 -0
  105. package/lib/cjs/index.js +26 -0
  106. package/lib/cjs/model.js +16 -0
  107. package/lib/cjs/setup-tests.js +19 -0
  108. package/lib/cjs/test/mock-query-results.js +76 -0
  109. package/lib/components/EmptyLogsState.d.ts +7 -0
  110. package/lib/components/EmptyLogsState.d.ts.map +1 -0
  111. package/lib/components/EmptyLogsState.js +36 -0
  112. package/lib/components/EmptyLogsState.js.map +1 -0
  113. package/lib/components/LogRow/LogDetailsTable.d.ts +8 -0
  114. package/lib/components/LogRow/LogDetailsTable.d.ts.map +1 -0
  115. package/lib/components/LogRow/LogDetailsTable.js +58 -0
  116. package/lib/components/LogRow/LogDetailsTable.js.map +1 -0
  117. package/lib/components/LogRow/LogRow.d.ts +14 -0
  118. package/lib/components/LogRow/LogRow.d.ts.map +1 -0
  119. package/lib/components/LogRow/LogRow.js +109 -0
  120. package/lib/components/LogRow/LogRow.js.map +1 -0
  121. package/lib/components/LogRow/LogTimestamp.d.ts +7 -0
  122. package/lib/components/LogRow/LogTimestamp.d.ts.map +1 -0
  123. package/lib/components/LogRow/LogTimestamp.js +31 -0
  124. package/lib/components/LogRow/LogTimestamp.js.map +1 -0
  125. package/lib/components/LogRow/LogsStyles.d.ts +21 -0
  126. package/lib/components/LogRow/LogsStyles.d.ts.map +1 -0
  127. package/lib/components/LogRow/LogsStyles.js +63 -0
  128. package/lib/components/LogRow/LogsStyles.js.map +1 -0
  129. package/lib/components/LogRow/index.d.ts +3 -0
  130. package/lib/components/LogRow/index.d.ts.map +1 -0
  131. package/lib/components/LogRow/index.js +16 -0
  132. package/lib/components/LogRow/index.js.map +1 -0
  133. package/lib/components/LogsList.d.ts +10 -0
  134. package/lib/components/LogsList.d.ts.map +1 -0
  135. package/lib/components/LogsList.js +31 -0
  136. package/lib/components/LogsList.js.map +1 -0
  137. package/lib/components/VirtualizedLogsList.d.ts +12 -0
  138. package/lib/components/VirtualizedLogsList.d.ts.map +1 -0
  139. package/lib/components/VirtualizedLogsList.js +51 -0
  140. package/lib/components/VirtualizedLogsList.js.map +1 -0
  141. package/lib/components/hooks/useExpandedRows.d.ts +6 -0
  142. package/lib/components/hooks/useExpandedRows.d.ts.map +1 -0
  143. package/lib/components/hooks/useExpandedRows.js +37 -0
  144. package/lib/components/hooks/useExpandedRows.js.map +1 -0
  145. package/lib/env.d.js +15 -0
  146. package/lib/env.d.js.map +1 -0
  147. package/lib/getPluginModule.d.ts +6 -0
  148. package/lib/getPluginModule.d.ts.map +1 -0
  149. package/lib/getPluginModule.js +16 -0
  150. package/lib/getPluginModule.js.map +1 -0
  151. package/lib/index-federation.d.ts +1 -0
  152. package/lib/index-federation.d.ts.map +1 -0
  153. package/lib/index-federation.js +15 -0
  154. package/lib/index-federation.js.map +1 -0
  155. package/lib/index.d.ts +4 -0
  156. package/lib/index.d.ts.map +1 -0
  157. package/lib/index.js +5 -0
  158. package/lib/index.js.map +1 -0
  159. package/lib/model.d.ts +15 -0
  160. package/lib/model.d.ts.map +1 -0
  161. package/lib/model.js +15 -0
  162. package/lib/model.js.map +1 -0
  163. package/lib/setup-tests.d.ts +2 -0
  164. package/lib/setup-tests.d.ts.map +1 -0
  165. package/lib/setup-tests.js +17 -0
  166. package/lib/setup-tests.js.map +1 -0
  167. package/lib/test/mock-query-results.d.ts +14 -0
  168. package/lib/test/mock-query-results.d.ts.map +1 -0
  169. package/lib/test/mock-query-results.js +60 -0
  170. package/lib/test/mock-query-results.js.map +1 -0
  171. package/mf-manifest.json +336 -0
  172. package/mf-stats.json +390 -0
  173. package/package.json +61 -0
@@ -0,0 +1,31 @@
1
+ // Copyright 2025 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
+ import { jsx as _jsx } from "react/jsx-runtime";
14
+ import React from 'react';
15
+ const dateFromStr = (timestamp)=>{
16
+ return /^\d+$/.test(timestamp) ? new Date(parseInt(timestamp) * 1000) : new Date(Date.parse(timestamp));
17
+ };
18
+ export const LogTimestamp = ({ timestamp })=>{
19
+ const date = typeof timestamp === 'number' ? new Date(timestamp * 1000) : dateFromStr(timestamp);
20
+ return /*#__PURE__*/ _jsx("time", {
21
+ style: {
22
+ fontSize: '12px',
23
+ whiteSpace: 'nowrap',
24
+ minWidth: 'max-content'
25
+ },
26
+ dateTime: date.toISOString(),
27
+ children: date.toISOString()
28
+ });
29
+ };
30
+
31
+ //# sourceMappingURL=LogTimestamp.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../src/components/LogRow/LogTimestamp.tsx"],"sourcesContent":["// Copyright 2025 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport React from 'react';\n\ninterface LogTimestampProps {\n timestamp: number | string;\n}\n\nconst dateFromStr = (timestamp: string): Date => {\n return /^\\d+$/.test(timestamp) ? new Date(parseInt(timestamp) * 1000) : new Date(Date.parse(timestamp));\n};\n\nexport const LogTimestamp: React.FC<LogTimestampProps> = ({ timestamp }) => {\n const date = typeof timestamp === 'number' ? new Date(timestamp * 1000) : dateFromStr(timestamp);\n return (\n <time\n style={{\n fontSize: '12px',\n whiteSpace: 'nowrap',\n minWidth: 'max-content',\n }}\n dateTime={date.toISOString()}\n >\n {date.toISOString()}\n </time>\n );\n};\n"],"names":["React","dateFromStr","timestamp","test","Date","parseInt","parse","LogTimestamp","date","time","style","fontSize","whiteSpace","minWidth","dateTime","toISOString"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;;AAEjC,OAAOA,WAAW,QAAQ;AAM1B,MAAMC,cAAc,CAACC;IACnB,OAAO,QAAQC,IAAI,CAACD,aAAa,IAAIE,KAAKC,SAASH,aAAa,QAAQ,IAAIE,KAAKA,KAAKE,KAAK,CAACJ;AAC9F;AAEA,OAAO,MAAMK,eAA4C,CAAC,EAAEL,SAAS,EAAE;IACrE,MAAMM,OAAO,OAAON,cAAc,WAAW,IAAIE,KAAKF,YAAY,QAAQD,YAAYC;IACtF,qBACE,KAACO;QACCC,OAAO;YACLC,UAAU;YACVC,YAAY;YACZC,UAAU;QACZ;QACAC,UAAUN,KAAKO,WAAW;kBAEzBP,KAAKO,WAAW;;AAGvB,EAAE"}
@@ -0,0 +1,21 @@
1
+ export declare const LogRowContainer: import("@emotion/styled").StyledComponent<import("@mui/system").BoxOwnProps<import("@mui/material").Theme> & Omit<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
2
+ ref?: ((instance: HTMLDivElement | null) => void | import("react").DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof import("react").DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | import("react").RefObject<HTMLDivElement> | null | undefined;
3
+ }, keyof import("@mui/system").BoxOwnProps<import("@mui/material").Theme>> & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme> & {
4
+ severityColor?: string;
5
+ }, {}, {}>;
6
+ export declare const LogRowContent: import("@emotion/styled").StyledComponent<import("@mui/system").BoxOwnProps<import("@mui/material").Theme> & Omit<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
7
+ ref?: ((instance: HTMLDivElement | null) => void | import("react").DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof import("react").DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | import("react").RefObject<HTMLDivElement> | null | undefined;
8
+ }, keyof import("@mui/system").BoxOwnProps<import("@mui/material").Theme>> & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme> & {
9
+ isExpandable: boolean;
10
+ }, {}, {}>;
11
+ export declare const ExpandButton: import("@emotion/styled").StyledComponent<import("@mui/material").IconButtonOwnProps & Omit<import("@mui/material").ButtonBaseOwnProps, "classes"> & import("@mui/material/OverridableComponent").CommonProps & Omit<Omit<import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref"> & {
12
+ ref?: ((instance: HTMLButtonElement | null) => void | import("react").DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof import("react").DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | import("react").RefObject<HTMLButtonElement> | null | undefined;
13
+ }, "color" | "children" | "sx" | "style" | "className" | "tabIndex" | "disabled" | "action" | "loading" | "size" | "classes" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "onFocusVisible" | "TouchRippleProps" | "touchRippleRef" | "disableFocusRipple" | "edge" | "loadingIndicator"> & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme> & {
14
+ isExpanded: boolean;
15
+ }, {}, {}>;
16
+ export declare const LogText: import("@emotion/styled").StyledComponent<import("@mui/material").TypographyOwnProps & import("@mui/material/OverridableComponent").CommonProps & Omit<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & {
17
+ ref?: ((instance: HTMLSpanElement | null) => void | import("react").DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof import("react").DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | import("react").RefObject<HTMLSpanElement> | null | undefined;
18
+ }, "border" | "borderTop" | "borderRight" | "borderBottom" | "borderLeft" | "borderColor" | "borderRadius" | "display" | "displayPrint" | "overflow" | "textOverflow" | "visibility" | "whiteSpace" | "flexBasis" | "flexDirection" | "flexWrap" | "justifyContent" | "alignItems" | "alignContent" | "order" | "flex" | "flexGrow" | "flexShrink" | "alignSelf" | "justifyItems" | "justifySelf" | "gap" | "columnGap" | "rowGap" | "gridColumn" | "gridRow" | "gridAutoFlow" | "gridAutoColumns" | "gridAutoRows" | "gridTemplateColumns" | "gridTemplateRows" | "gridTemplateAreas" | "gridArea" | "bgcolor" | "color" | "zIndex" | "position" | "top" | "right" | "bottom" | "left" | "boxShadow" | "width" | "maxWidth" | "minWidth" | "height" | "maxHeight" | "minHeight" | "boxSizing" | "m" | "mt" | "mr" | "mb" | "ml" | "mx" | "my" | "p" | "pt" | "pr" | "pb" | "pl" | "px" | "py" | "margin" | "marginTop" | "marginRight" | "marginBottom" | "marginLeft" | "marginX" | "marginY" | "marginInline" | "marginInlineStart" | "marginInlineEnd" | "marginBlock" | "marginBlockStart" | "marginBlockEnd" | "padding" | "paddingTop" | "paddingRight" | "paddingBottom" | "paddingLeft" | "paddingX" | "paddingY" | "paddingInline" | "paddingInlineStart" | "paddingInlineEnd" | "paddingBlock" | "paddingBlockStart" | "paddingBlockEnd" | "typography" | "fontFamily" | "fontSize" | "fontStyle" | "fontWeight" | "letterSpacing" | "lineHeight" | "textAlign" | "textTransform" | "children" | "sx" | "style" | "className" | "align" | "classes" | "gutterBottom" | "noWrap" | "paragraph" | "variant" | "variantMapping"> & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme> & {
19
+ allowWrap: boolean;
20
+ }, {}, {}>;
21
+ //# sourceMappingURL=LogsStyles.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LogsStyles.d.ts","sourceRoot":"","sources":["../../../../src/components/LogRow/LogsStyles.tsx"],"names":[],"mappings":"AAeA,eAAO,MAAM,eAAe;;;oBAEP,MAAM;UAKxB,CAAC;AAEJ,eAAO,MAAM,aAAa;;;kBAEP,OAAO;UAUvB,CAAC;AAEJ,eAAO,MAAM,YAAY;;;gBAER,OAAO;UAOrB,CAAC;AAEJ,eAAO,MAAM,OAAO;;;eAEJ,OAAO;UAgBpB,CAAC"}
@@ -0,0 +1,63 @@
1
+ // Copyright 2025 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
+ import { Box, styled, IconButton, Typography } from '@mui/material';
14
+ export const LogRowContainer = styled(Box, {
15
+ shouldForwardProp: (prop)=>prop !== 'severityColor'
16
+ })(({ severityColor })=>({
17
+ borderLeft: `4px solid ${severityColor}`,
18
+ transition: 'all 0.2s ease',
19
+ marginBottom: '4px',
20
+ fontFamily: '"DejaVu Sans Mono", monospace'
21
+ }));
22
+ export const LogRowContent = styled(Box, {
23
+ shouldForwardProp: (prop)=>prop !== 'isExpandable'
24
+ })(({ theme, isExpandable })=>({
25
+ display: 'grid',
26
+ gridTemplateColumns: isExpandable ? '16px minmax(160px, max-content) 1fr' : 'minmax(160px, max-content) 1fr',
27
+ alignItems: 'flex-start',
28
+ padding: '4px 8px',
29
+ cursor: isExpandable ? 'pointer' : 'default',
30
+ gap: '12px',
31
+ '&:hover': {
32
+ backgroundColor: theme.palette.action.hover
33
+ }
34
+ }));
35
+ export const ExpandButton = styled(IconButton, {
36
+ shouldForwardProp: (prop)=>prop !== 'isExpanded'
37
+ })(({ theme, isExpanded })=>({
38
+ padding: 0,
39
+ width: '16px',
40
+ height: '16px',
41
+ color: theme.palette.text.secondary,
42
+ transform: isExpanded ? 'rotate(90deg)' : 'rotate(0deg)',
43
+ transition: 'transform 0.2s ease'
44
+ }));
45
+ export const LogText = styled(Typography, {
46
+ shouldForwardProp: (prop)=>prop !== 'allowWrap'
47
+ })(({ allowWrap })=>({
48
+ fontSize: '12px',
49
+ flex: 1,
50
+ lineHeight: 1.4,
51
+ textAlign: 'left',
52
+ ...allowWrap ? {
53
+ wordBreak: 'break-word',
54
+ whiteSpace: 'pre-wrap',
55
+ overflow: 'visible',
56
+ textOverflow: 'unset'
57
+ } : {
58
+ wordBreak: 'normal',
59
+ whiteSpace: 'nowrap'
60
+ }
61
+ }));
62
+
63
+ //# sourceMappingURL=LogsStyles.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../src/components/LogRow/LogsStyles.tsx"],"sourcesContent":["// Copyright 2025 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { Box, styled, IconButton, Typography } from '@mui/material';\n\nexport const LogRowContainer = styled(Box, {\n shouldForwardProp: (prop) => prop !== 'severityColor',\n})<{ severityColor?: string }>(({ severityColor }) => ({\n borderLeft: `4px solid ${severityColor}`,\n transition: 'all 0.2s ease',\n marginBottom: '4px',\n fontFamily: '\"DejaVu Sans Mono\", monospace',\n}));\n\nexport const LogRowContent = styled(Box, {\n shouldForwardProp: (prop) => prop !== 'isExpandable',\n})<{ isExpandable: boolean }>(({ theme, isExpandable }) => ({\n display: 'grid',\n gridTemplateColumns: isExpandable ? '16px minmax(160px, max-content) 1fr' : 'minmax(160px, max-content) 1fr',\n alignItems: 'flex-start',\n padding: '4px 8px',\n cursor: isExpandable ? 'pointer' : 'default',\n gap: '12px',\n '&:hover': {\n backgroundColor: theme.palette.action.hover,\n },\n}));\n\nexport const ExpandButton = styled(IconButton, {\n shouldForwardProp: (prop) => prop !== 'isExpanded',\n})<{ isExpanded: boolean }>(({ theme, isExpanded }) => ({\n padding: 0,\n width: '16px',\n height: '16px',\n color: theme.palette.text.secondary,\n transform: isExpanded ? 'rotate(90deg)' : 'rotate(0deg)',\n transition: 'transform 0.2s ease',\n}));\n\nexport const LogText = styled(Typography, {\n shouldForwardProp: (prop) => prop !== 'allowWrap',\n})<{ allowWrap: boolean }>(({ allowWrap }) => ({\n fontSize: '12px',\n flex: 1,\n lineHeight: 1.4,\n textAlign: 'left',\n ...(allowWrap\n ? {\n wordBreak: 'break-word',\n whiteSpace: 'pre-wrap',\n overflow: 'visible',\n textOverflow: 'unset',\n }\n : {\n wordBreak: 'normal',\n whiteSpace: 'nowrap',\n }),\n}));\n"],"names":["Box","styled","IconButton","Typography","LogRowContainer","shouldForwardProp","prop","severityColor","borderLeft","transition","marginBottom","fontFamily","LogRowContent","theme","isExpandable","display","gridTemplateColumns","alignItems","padding","cursor","gap","backgroundColor","palette","action","hover","ExpandButton","isExpanded","width","height","color","text","secondary","transform","LogText","allowWrap","fontSize","flex","lineHeight","textAlign","wordBreak","whiteSpace","overflow","textOverflow"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,SAASA,GAAG,EAAEC,MAAM,EAAEC,UAAU,EAAEC,UAAU,QAAQ,gBAAgB;AAEpE,OAAO,MAAMC,kBAAkBH,OAAOD,KAAK;IACzCK,mBAAmB,CAACC,OAASA,SAAS;AACxC,GAA+B,CAAC,EAAEC,aAAa,EAAE,GAAM,CAAA;QACrDC,YAAY,CAAC,UAAU,EAAED,eAAe;QACxCE,YAAY;QACZC,cAAc;QACdC,YAAY;IACd,CAAA,GAAI;AAEJ,OAAO,MAAMC,gBAAgBX,OAAOD,KAAK;IACvCK,mBAAmB,CAACC,OAASA,SAAS;AACxC,GAA8B,CAAC,EAAEO,KAAK,EAAEC,YAAY,EAAE,GAAM,CAAA;QAC1DC,SAAS;QACTC,qBAAqBF,eAAe,wCAAwC;QAC5EG,YAAY;QACZC,SAAS;QACTC,QAAQL,eAAe,YAAY;QACnCM,KAAK;QACL,WAAW;YACTC,iBAAiBR,MAAMS,OAAO,CAACC,MAAM,CAACC,KAAK;QAC7C;IACF,CAAA,GAAI;AAEJ,OAAO,MAAMC,eAAexB,OAAOC,YAAY;IAC7CG,mBAAmB,CAACC,OAASA,SAAS;AACxC,GAA4B,CAAC,EAAEO,KAAK,EAAEa,UAAU,EAAE,GAAM,CAAA;QACtDR,SAAS;QACTS,OAAO;QACPC,QAAQ;QACRC,OAAOhB,MAAMS,OAAO,CAACQ,IAAI,CAACC,SAAS;QACnCC,WAAWN,aAAa,kBAAkB;QAC1CjB,YAAY;IACd,CAAA,GAAI;AAEJ,OAAO,MAAMwB,UAAUhC,OAAOE,YAAY;IACxCE,mBAAmB,CAACC,OAASA,SAAS;AACxC,GAA2B,CAAC,EAAE4B,SAAS,EAAE,GAAM,CAAA;QAC7CC,UAAU;QACVC,MAAM;QACNC,YAAY;QACZC,WAAW;QACX,GAAIJ,YACA;YACEK,WAAW;YACXC,YAAY;YACZC,UAAU;YACVC,cAAc;QAChB,IACA;YACEH,WAAW;YACXC,YAAY;QACd,CAAC;IACP,CAAA,GAAI"}
@@ -0,0 +1,3 @@
1
+ export { LogRow } from './LogRow';
2
+ export * from './LogsStyles';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/LogRow/index.ts"],"names":[],"mappings":"AAaA,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,cAAc,cAAc,CAAC"}
@@ -0,0 +1,16 @@
1
+ // Copyright 2025 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
+ export { LogRow } from './LogRow';
14
+ export * from './LogsStyles';
15
+
16
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../src/components/LogRow/index.ts"],"sourcesContent":["// Copyright 2025 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nexport { LogRow } from './LogRow';\nexport * from './LogsStyles';\n"],"names":["LogRow"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,SAASA,MAAM,QAAQ,WAAW;AAClC,cAAc,eAAe"}
@@ -0,0 +1,10 @@
1
+ import React from 'react';
2
+ import { LogEntry } from '@perses-dev/core';
3
+ import { LogsTableOptions } from '../model';
4
+ interface LogsListProps {
5
+ logs: LogEntry[];
6
+ spec: LogsTableOptions;
7
+ }
8
+ export declare const LogsList: React.FC<LogsListProps>;
9
+ export {};
10
+ //# sourceMappingURL=LogsList.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LogsList.d.ts","sourceRoot":"","sources":["../../../src/components/LogsList.tsx"],"names":[],"mappings":"AAaA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5C,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAK5C,UAAU,aAAa;IACrB,IAAI,EAAE,QAAQ,EAAE,CAAC;IACjB,IAAI,EAAE,gBAAgB,CAAC;CACxB;AAED,eAAO,MAAM,QAAQ,EAAE,KAAK,CAAC,EAAE,CAAC,aAAa,CAQ5C,CAAC"}
@@ -0,0 +1,31 @@
1
+ // Copyright 2025 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
+ import { jsx as _jsx } from "react/jsx-runtime";
14
+ import React from 'react';
15
+ import { EmptyLogsState } from './EmptyLogsState';
16
+ import { useExpandedRows } from './hooks/useExpandedRows';
17
+ import { VirtualizedLogsList } from './VirtualizedLogsList';
18
+ export const LogsList = ({ logs, spec })=>{
19
+ const { expandedRows, toggleExpand } = useExpandedRows();
20
+ if (!logs.length) {
21
+ return /*#__PURE__*/ _jsx(EmptyLogsState, {});
22
+ }
23
+ return /*#__PURE__*/ _jsx(VirtualizedLogsList, {
24
+ logs: logs,
25
+ spec: spec,
26
+ expandedRows: expandedRows,
27
+ onToggleExpand: toggleExpand
28
+ });
29
+ };
30
+
31
+ //# sourceMappingURL=LogsList.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/components/LogsList.tsx"],"sourcesContent":["// Copyright 2025 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport React from 'react';\nimport { LogEntry } from '@perses-dev/core';\nimport { LogsTableOptions } from '../model';\nimport { EmptyLogsState } from './EmptyLogsState';\nimport { useExpandedRows } from './hooks/useExpandedRows';\nimport { VirtualizedLogsList } from './VirtualizedLogsList';\n\ninterface LogsListProps {\n logs: LogEntry[];\n spec: LogsTableOptions;\n}\n\nexport const LogsList: React.FC<LogsListProps> = ({ logs, spec }) => {\n const { expandedRows, toggleExpand } = useExpandedRows();\n\n if (!logs.length) {\n return <EmptyLogsState />;\n }\n\n return <VirtualizedLogsList logs={logs} spec={spec} expandedRows={expandedRows} onToggleExpand={toggleExpand} />;\n};\n"],"names":["React","EmptyLogsState","useExpandedRows","VirtualizedLogsList","LogsList","logs","spec","expandedRows","toggleExpand","length","onToggleExpand"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;;AAEjC,OAAOA,WAAW,QAAQ;AAG1B,SAASC,cAAc,QAAQ,mBAAmB;AAClD,SAASC,eAAe,QAAQ,0BAA0B;AAC1D,SAASC,mBAAmB,QAAQ,wBAAwB;AAO5D,OAAO,MAAMC,WAAoC,CAAC,EAAEC,IAAI,EAAEC,IAAI,EAAE;IAC9D,MAAM,EAAEC,YAAY,EAAEC,YAAY,EAAE,GAAGN;IAEvC,IAAI,CAACG,KAAKI,MAAM,EAAE;QAChB,qBAAO,KAACR;IACV;IAEA,qBAAO,KAACE;QAAoBE,MAAMA;QAAMC,MAAMA;QAAMC,cAAcA;QAAcG,gBAAgBF;;AAClG,EAAE"}
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { LogEntry } from '@perses-dev/core';
3
+ import { LogsTableOptions } from '../model';
4
+ interface VirtualizedLogsListProps {
5
+ logs: LogEntry[];
6
+ spec: LogsTableOptions;
7
+ expandedRows: Set<number>;
8
+ onToggleExpand: (index: number) => void;
9
+ }
10
+ export declare const VirtualizedLogsList: React.FC<VirtualizedLogsListProps>;
11
+ export {};
12
+ //# sourceMappingURL=VirtualizedLogsList.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VirtualizedLogsList.d.ts","sourceRoot":"","sources":["../../../src/components/VirtualizedLogsList.tsx"],"names":[],"mappings":"AAaA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5C,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAG5C,UAAU,wBAAwB;IAChC,IAAI,EAAE,QAAQ,EAAE,CAAC;IACjB,IAAI,EAAE,gBAAgB,CAAC;IACvB,YAAY,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC;IAC1B,cAAc,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;CACzC;AAED,eAAO,MAAM,mBAAmB,EAAE,KAAK,CAAC,EAAE,CAAC,wBAAwB,CA0ClE,CAAC"}
@@ -0,0 +1,51 @@
1
+ // Copyright 2025 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
+ import { jsx as _jsx } from "react/jsx-runtime";
14
+ import React from 'react';
15
+ import { Box, useTheme } from '@mui/material';
16
+ import { Virtuoso } from 'react-virtuoso';
17
+ import { LogRow } from './LogRow/LogRow';
18
+ export const VirtualizedLogsList = ({ logs, spec, expandedRows, onToggleExpand })=>{
19
+ const theme = useTheme();
20
+ const renderLogRow = (index)=>{
21
+ const log = logs[index];
22
+ if (!log) return null;
23
+ return /*#__PURE__*/ _jsx(LogRow, {
24
+ isExpandable: spec.enableDetails,
25
+ log: log,
26
+ index: index,
27
+ isExpanded: expandedRows.has(index),
28
+ onToggle: onToggleExpand,
29
+ allowWrap: spec.allowWrap,
30
+ showTime: spec.showTime
31
+ });
32
+ };
33
+ return /*#__PURE__*/ _jsx(Box, {
34
+ sx: {
35
+ height: '100%',
36
+ backgroundColor: theme.palette.background.default,
37
+ overflow: 'hidden',
38
+ boxShadow: theme.shadows[1]
39
+ },
40
+ children: /*#__PURE__*/ _jsx(Virtuoso, {
41
+ style: {
42
+ height: '100%'
43
+ },
44
+ initialItemCount: spec.showAll ? logs.length : undefined,
45
+ totalCount: logs.length,
46
+ itemContent: renderLogRow
47
+ })
48
+ });
49
+ };
50
+
51
+ //# sourceMappingURL=VirtualizedLogsList.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/components/VirtualizedLogsList.tsx"],"sourcesContent":["// Copyright 2025 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport React from 'react';\nimport { Box, useTheme } from '@mui/material';\nimport { Virtuoso } from 'react-virtuoso';\nimport { LogEntry } from '@perses-dev/core';\nimport { LogsTableOptions } from '../model';\nimport { LogRow } from './LogRow/LogRow';\n\ninterface VirtualizedLogsListProps {\n logs: LogEntry[];\n spec: LogsTableOptions;\n expandedRows: Set<number>;\n onToggleExpand: (index: number) => void;\n}\n\nexport const VirtualizedLogsList: React.FC<VirtualizedLogsListProps> = ({\n logs,\n spec,\n expandedRows,\n onToggleExpand,\n}) => {\n const theme = useTheme();\n\n const renderLogRow = (index: number) => {\n const log = logs[index];\n if (!log) return null;\n\n return (\n <LogRow\n isExpandable={spec.enableDetails}\n log={log}\n index={index}\n isExpanded={expandedRows.has(index)}\n onToggle={onToggleExpand}\n allowWrap={spec.allowWrap}\n showTime={spec.showTime}\n />\n );\n };\n\n return (\n <Box\n sx={{\n height: '100%',\n backgroundColor: theme.palette.background.default,\n overflow: 'hidden',\n boxShadow: theme.shadows[1],\n }}\n >\n <Virtuoso\n style={{ height: '100%' }}\n initialItemCount={spec.showAll ? logs.length : undefined}\n totalCount={logs.length}\n itemContent={renderLogRow}\n />\n </Box>\n );\n};\n"],"names":["React","Box","useTheme","Virtuoso","LogRow","VirtualizedLogsList","logs","spec","expandedRows","onToggleExpand","theme","renderLogRow","index","log","isExpandable","enableDetails","isExpanded","has","onToggle","allowWrap","showTime","sx","height","backgroundColor","palette","background","default","overflow","boxShadow","shadows","style","initialItemCount","showAll","length","undefined","totalCount","itemContent"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;;AAEjC,OAAOA,WAAW,QAAQ;AAC1B,SAASC,GAAG,EAAEC,QAAQ,QAAQ,gBAAgB;AAC9C,SAASC,QAAQ,QAAQ,iBAAiB;AAG1C,SAASC,MAAM,QAAQ,kBAAkB;AASzC,OAAO,MAAMC,sBAA0D,CAAC,EACtEC,IAAI,EACJC,IAAI,EACJC,YAAY,EACZC,cAAc,EACf;IACC,MAAMC,QAAQR;IAEd,MAAMS,eAAe,CAACC;QACpB,MAAMC,MAAMP,IAAI,CAACM,MAAM;QACvB,IAAI,CAACC,KAAK,OAAO;QAEjB,qBACE,KAACT;YACCU,cAAcP,KAAKQ,aAAa;YAChCF,KAAKA;YACLD,OAAOA;YACPI,YAAYR,aAAaS,GAAG,CAACL;YAC7BM,UAAUT;YACVU,WAAWZ,KAAKY,SAAS;YACzBC,UAAUb,KAAKa,QAAQ;;IAG7B;IAEA,qBACE,KAACnB;QACCoB,IAAI;YACFC,QAAQ;YACRC,iBAAiBb,MAAMc,OAAO,CAACC,UAAU,CAACC,OAAO;YACjDC,UAAU;YACVC,WAAWlB,MAAMmB,OAAO,CAAC,EAAE;QAC7B;kBAEA,cAAA,KAAC1B;YACC2B,OAAO;gBAAER,QAAQ;YAAO;YACxBS,kBAAkBxB,KAAKyB,OAAO,GAAG1B,KAAK2B,MAAM,GAAGC;YAC/CC,YAAY7B,KAAK2B,MAAM;YACvBG,aAAazB;;;AAIrB,EAAE"}
@@ -0,0 +1,6 @@
1
+ export declare const useExpandedRows: () => {
2
+ expandedRows: Set<number>;
3
+ toggleExpand: (index: number) => void;
4
+ clearExpanded: () => void;
5
+ };
6
+ //# sourceMappingURL=useExpandedRows.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useExpandedRows.d.ts","sourceRoot":"","sources":["../../../../src/components/hooks/useExpandedRows.ts"],"names":[],"mappings":"AAeA,eAAO,MAAM,eAAe;;0BAGe,MAAM;;CAqBhD,CAAC"}
@@ -0,0 +1,37 @@
1
+ // Copyright 2025 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
+ import { useState, useCallback } from 'react';
14
+ export const useExpandedRows = ()=>{
15
+ const [expandedRows, setExpandedRows] = useState(new Set());
16
+ const toggleExpand = useCallback((index)=>{
17
+ setExpandedRows((prev)=>{
18
+ const newSet = new Set(prev);
19
+ if (newSet.has(index)) {
20
+ newSet.delete(index);
21
+ } else {
22
+ newSet.add(index);
23
+ }
24
+ return newSet;
25
+ });
26
+ }, []);
27
+ const clearExpanded = useCallback(()=>{
28
+ setExpandedRows(new Set());
29
+ }, []);
30
+ return {
31
+ expandedRows,
32
+ toggleExpand,
33
+ clearExpanded
34
+ };
35
+ };
36
+
37
+ //# sourceMappingURL=useExpandedRows.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../src/components/hooks/useExpandedRows.ts"],"sourcesContent":["// Copyright 2025 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { useState, useCallback } from 'react';\n\nexport const useExpandedRows = () => {\n const [expandedRows, setExpandedRows] = useState<Set<number>>(new Set());\n\n const toggleExpand = useCallback((index: number) => {\n setExpandedRows((prev) => {\n const newSet = new Set(prev);\n if (newSet.has(index)) {\n newSet.delete(index);\n } else {\n newSet.add(index);\n }\n return newSet;\n });\n }, []);\n\n const clearExpanded = useCallback(() => {\n setExpandedRows(new Set());\n }, []);\n\n return {\n expandedRows,\n toggleExpand,\n clearExpanded,\n };\n};\n"],"names":["useState","useCallback","useExpandedRows","expandedRows","setExpandedRows","Set","toggleExpand","index","prev","newSet","has","delete","add","clearExpanded"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,SAASA,QAAQ,EAAEC,WAAW,QAAQ,QAAQ;AAE9C,OAAO,MAAMC,kBAAkB;IAC7B,MAAM,CAACC,cAAcC,gBAAgB,GAAGJ,SAAsB,IAAIK;IAElE,MAAMC,eAAeL,YAAY,CAACM;QAChCH,gBAAgB,CAACI;YACf,MAAMC,SAAS,IAAIJ,IAAIG;YACvB,IAAIC,OAAOC,GAAG,CAACH,QAAQ;gBACrBE,OAAOE,MAAM,CAACJ;YAChB,OAAO;gBACLE,OAAOG,GAAG,CAACL;YACb;YACA,OAAOE;QACT;IACF,GAAG,EAAE;IAEL,MAAMI,gBAAgBZ,YAAY;QAChCG,gBAAgB,IAAIC;IACtB,GAAG,EAAE;IAEL,OAAO;QACLF;QACAG;QACAO;IACF;AACF,EAAE"}
package/lib/env.d.js ADDED
@@ -0,0 +1,15 @@
1
+ // Copyright 2025 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
+ /// <reference types="@rsbuild/core/types" />
14
+
15
+ //# sourceMappingURL=env.d.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/env.d.ts"],"sourcesContent":["// Copyright 2025 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\n/// <reference types=\"@rsbuild/core/types\" />\n"],"names":[],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,6CAA6C"}
@@ -0,0 +1,6 @@
1
+ import { PluginModuleResource } from '@perses-dev/plugin-system';
2
+ /**
3
+ * Returns the plugin module information from package.json
4
+ */
5
+ export declare function getPluginModule(): PluginModuleResource;
6
+ //# sourceMappingURL=getPluginModule.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getPluginModule.d.ts","sourceRoot":"","sources":["../../src/getPluginModule.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAoB,MAAM,2BAA2B,CAAC;AAGnF;;GAEG;AACH,wBAAgB,eAAe,IAAI,oBAAoB,CAUtD"}
@@ -0,0 +1,16 @@
1
+ import packageJson from '../package.json';
2
+ /**
3
+ * Returns the plugin module information from package.json
4
+ */ export function getPluginModule() {
5
+ const { name, version, perses } = packageJson;
6
+ return {
7
+ kind: 'PluginModule',
8
+ metadata: {
9
+ name,
10
+ version
11
+ },
12
+ spec: perses
13
+ };
14
+ }
15
+
16
+ //# sourceMappingURL=getPluginModule.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/getPluginModule.ts"],"sourcesContent":["import { PluginModuleResource, PluginModuleSpec } from '@perses-dev/plugin-system';\nimport packageJson from '../package.json';\n\n/**\n * Returns the plugin module information from package.json\n */\nexport function getPluginModule(): PluginModuleResource {\n const { name, version, perses } = packageJson;\n return {\n kind: 'PluginModule',\n metadata: {\n name,\n version,\n },\n spec: perses as PluginModuleSpec,\n };\n}\n"],"names":["packageJson","getPluginModule","name","version","perses","kind","metadata","spec"],"mappings":"AACA,OAAOA,iBAAiB,kBAAkB;AAE1C;;CAEC,GACD,OAAO,SAASC;IACd,MAAM,EAAEC,IAAI,EAAEC,OAAO,EAAEC,MAAM,EAAE,GAAGJ;IAClC,OAAO;QACLK,MAAM;QACNC,UAAU;YACRJ;YACAC;QACF;QACAI,MAAMH;IACR;AACF"}
@@ -0,0 +1 @@
1
+ //# sourceMappingURL=index-federation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index-federation.d.ts","sourceRoot":"","sources":["../../src/index-federation.ts"],"names":[],"mappings":""}
@@ -0,0 +1,15 @@
1
+ // Copyright 2025 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
+ import('./bootstrap');
14
+
15
+ //# sourceMappingURL=index-federation.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/index-federation.ts"],"sourcesContent":["// Copyright 2025 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport('./bootstrap');\n"],"names":[],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,MAAM,CAAC"}
package/lib/index.d.ts ADDED
@@ -0,0 +1,4 @@
1
+ export { getPluginModule } from './getPluginModule';
2
+ export * from './model';
3
+ export * from './LogsTable';
4
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,cAAc,SAAS,CAAC;AACxB,cAAc,aAAa,CAAC"}
package/lib/index.js ADDED
@@ -0,0 +1,5 @@
1
+ export { getPluginModule } from './getPluginModule';
2
+ export * from './model';
3
+ export * from './LogsTable';
4
+
5
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/index.ts"],"sourcesContent":["export { getPluginModule } from './getPluginModule';\nexport * from './model';\nexport * from './LogsTable';\n"],"names":["getPluginModule"],"mappings":"AAAA,SAASA,eAAe,QAAQ,oBAAoB;AACpD,cAAc,UAAU;AACxB,cAAc,cAAc"}
package/lib/model.d.ts ADDED
@@ -0,0 +1,15 @@
1
+ import { LogData, ThresholdOptions } from '@perses-dev/core';
2
+ import { PanelProps, LegendSpecOptions } from '@perses-dev/plugin-system';
3
+ export type LogsTableProps = PanelProps<LogsTableOptions, LogsQueryData>;
4
+ export interface LogsQueryData {
5
+ logs?: LogData;
6
+ }
7
+ export interface LogsTableOptions {
8
+ legend?: LegendSpecOptions;
9
+ thresholds?: ThresholdOptions;
10
+ allowWrap?: boolean;
11
+ enableDetails?: boolean;
12
+ showTime?: boolean;
13
+ showAll?: boolean;
14
+ }
15
+ //# sourceMappingURL=model.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"model.d.ts","sourceRoot":"","sources":["../../src/model.ts"],"names":[],"mappings":"AAaA,OAAO,EAAE,OAAO,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;AAC7D,OAAO,EAAE,UAAU,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAE1E,MAAM,MAAM,cAAc,GAAG,UAAU,CAAC,gBAAgB,EAAE,aAAa,CAAC,CAAC;AAEzE,MAAM,WAAW,aAAa;IAC5B,IAAI,CAAC,EAAE,OAAO,CAAC;CAChB;AAED,MAAM,WAAW,gBAAgB;IAC/B,MAAM,CAAC,EAAE,iBAAiB,CAAC;IAC3B,UAAU,CAAC,EAAE,gBAAgB,CAAC;IAC9B,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB"}
package/lib/model.js ADDED
@@ -0,0 +1,15 @@
1
+ // Copyright 2025 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
+ export { };
14
+
15
+ //# sourceMappingURL=model.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/model.ts"],"sourcesContent":["// Copyright 2025 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { LogData, ThresholdOptions } from '@perses-dev/core';\nimport { PanelProps, LegendSpecOptions } from '@perses-dev/plugin-system';\n\nexport type LogsTableProps = PanelProps<LogsTableOptions, LogsQueryData>;\n\nexport interface LogsQueryData {\n logs?: LogData;\n}\n\nexport interface LogsTableOptions {\n legend?: LegendSpecOptions;\n thresholds?: ThresholdOptions;\n allowWrap?: boolean;\n enableDetails?: boolean;\n showTime?: boolean;\n showAll?: boolean;\n}\n"],"names":[],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAWjC,WAOC"}
@@ -0,0 +1,2 @@
1
+ import '@testing-library/jest-dom';
2
+ //# sourceMappingURL=setup-tests.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"setup-tests.d.ts","sourceRoot":"","sources":["../../src/setup-tests.ts"],"names":[],"mappings":"AAaA,OAAO,2BAA2B,CAAC"}
@@ -0,0 +1,17 @@
1
+ // Copyright 2025 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
+ import '@testing-library/jest-dom';
14
+ // Always mock e-charts during tests since we don't have a proper canvas in jsdom
15
+ jest.mock('echarts/core');
16
+
17
+ //# sourceMappingURL=setup-tests.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/setup-tests.ts"],"sourcesContent":["// Copyright 2025 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport '@testing-library/jest-dom';\n\n// Always mock e-charts during tests since we don't have a proper canvas in jsdom\njest.mock('echarts/core');\n"],"names":["jest","mock"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,OAAO,4BAA4B;AAEnC,iFAAiF;AACjFA,KAAKC,IAAI,CAAC"}
@@ -0,0 +1,14 @@
1
+ import { LogsQueryData } from '../model';
2
+ export declare const MOCK_LOGS_QUERY_RESULT: LogsQueryData;
3
+ export declare const MOCK_LOGS_QUERY_DEFINITION: {
4
+ kind: string;
5
+ spec: {
6
+ plugin: {
7
+ kind: string;
8
+ spec: {
9
+ query: string;
10
+ };
11
+ };
12
+ };
13
+ };
14
+ //# sourceMappingURL=mock-query-results.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mock-query-results.d.ts","sourceRoot":"","sources":["../../../src/test/mock-query-results.ts"],"names":[],"mappings":"AAaA,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAEzC,eAAO,MAAM,sBAAsB,EAAE,aAkCpC,CAAC;AAEF,eAAO,MAAM,0BAA0B;;;;;;;;;;CAUtC,CAAC"}