@cccsaurora/clue-ui 1.2.0-dev.253 → 1.2.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 (179) hide show
  1. package/ActionForm-pWyIi01Z.js +4460 -0
  2. package/AnnotationDetails-11P7yhyx.js +160 -0
  3. package/AnnotationPreview-BGqlBBcp.js +140 -0
  4. package/ClueEnrichContext-DDZf646J.js +418 -0
  5. package/FlexOne-BXWFOd1T.js +6 -0
  6. package/_MapCache-BiTi0iqu.js +180 -0
  7. package/_Uint8Array-TJBs9NS2.js +101 -0
  8. package/_baseAssignValue-CNMLQZco.js +20 -0
  9. package/_baseClone-DajKHDCs.js +207 -0
  10. package/_baseExtremum-DhV10dXG.js +27 -0
  11. package/_baseFlatten-C8CjmqQ-.js +72 -0
  12. package/_baseGet-DSZygzyq.js +79 -0
  13. package/_baseIsEqual-C08cUUpA.js +147 -0
  14. package/_baseIteratee-DGZdhdqr.js +95 -0
  15. package/_baseSlice-M5RKzt1A.js +10 -0
  16. package/_baseSum-wEbgNeUs.js +10 -0
  17. package/_baseUniq-CGlHphLr.js +79 -0
  18. package/_commonjsHelpers-DaMA6jEr.js +8 -0
  19. package/_createAggregator-BvcoTZto.js +53 -0
  20. package/_getPrototype-Dm06JiGv.js +5 -0
  21. package/_getTag-Cfxlub3L.js +90 -0
  22. package/_setToArray-C7yMOeww.js +29 -0
  23. package/cloneDeep-wjl3XmFj.js +8 -0
  24. package/components/AnnotationBody.js +35 -49
  25. package/components/AnnotationDetailPopover.js +30 -36
  26. package/components/AnnotationDetails.js +7 -7
  27. package/components/AnnotationEntry.js +35 -35
  28. package/components/AnnotationPreview.js +5 -5
  29. package/components/ClassificationChip.js +23 -44
  30. package/components/CountBadge.js +26 -31
  31. package/components/EnrichedCard.js +97 -110
  32. package/components/EnrichedChip.js +105 -130
  33. package/components/EnrichedTypography.js +107 -133
  34. package/components/ErrorBoundary.js +24 -28
  35. package/components/RetryFailedEnrichments.js +9 -10
  36. package/components/SourcePicker.js +49 -57
  37. package/components/actions/ActionForm.js +4 -4
  38. package/components/actions/ExecutePopover.js +59 -75
  39. package/components/actions/ResultModal.js +4 -4
  40. package/components/actions/form/schemaAdapter.js +23 -39
  41. package/components/actions/formats/FileResult.js +59 -86
  42. package/components/actions/formats/index.js +10 -21
  43. package/components/display/graph/ExpandMoreButton.js +10 -10
  44. package/components/display/graph/elements/NodeCard.js +91 -111
  45. package/components/display/graph/elements/NodeTag.js +13 -15
  46. package/components/display/graph/index.js +202 -261
  47. package/components/display/graph/visualizations/Leaf.js +69 -88
  48. package/components/display/graph/visualizations/cloud/index.js +81 -98
  49. package/components/display/graph/visualizations/icons/BaseIcon.js +21 -26
  50. package/components/display/graph/visualizations/icons/BugIcon.js +12 -12
  51. package/components/display/graph/visualizations/icons/HostIcon.js +12 -12
  52. package/components/display/graph/visualizations/icons/NetworkIcon.js +12 -12
  53. package/components/display/graph/visualizations/icons/ProcessIcon.js +12 -12
  54. package/components/display/graph/visualizations/icons/TargetIcon.js +13 -13
  55. package/components/display/graph/visualizations/icons/index.js +13 -14
  56. package/components/display/graph/visualizations/panels/NodePanel.js +8 -10
  57. package/components/display/graph/visualizations/tree/BundleLine.js +81 -108
  58. package/components/display/graph/visualizations/tree/Triangle.js +13 -13
  59. package/components/display/graph/visualizations/tree/index.js +305 -407
  60. package/components/display/icons/Iconified.js +12 -27
  61. package/components/display/json/index.js +4 -4
  62. package/components/display/markdown/index.js +5770 -8678
  63. package/components/enrichment/EnrichPopover.js +46 -54
  64. package/components/fetchers/Fetcher.js +117 -155
  65. package/components/fetchers/PreviewModal.js +17 -20
  66. package/components/fetchers/StatusChip.js +17 -21
  67. package/components/group/Entry.js +11 -13
  68. package/components/group/Group.js +10 -13
  69. package/components/group/GroupControl.js +65 -76
  70. package/components/stats/QueryStatus.js +33 -43
  71. package/countBy-pIyxNZhO.js +8 -0
  72. package/data/event.js +4 -6
  73. package/database/index.js +2 -2
  74. package/debounce-DryYcbJ4.js +56 -0
  75. package/get-CH7kz5Ix.js +8 -0
  76. package/groupBy-yNrpdipq.js +8 -0
  77. package/hooks/ClueActionContext.js +6 -6
  78. package/hooks/ClueComponentContext.js +23 -29
  79. package/hooks/ClueConfigProvider.js +12 -14
  80. package/hooks/ClueDatabaseContext.js +13 -19
  81. package/hooks/ClueEnrichContext.js +8 -8
  82. package/hooks/ClueFetcherContext.js +56 -83
  83. package/hooks/ClueGroupContext.js +14 -17
  84. package/hooks/CluePopupContext.js +5 -5
  85. package/hooks/ClueProvider.js +10 -12
  86. package/hooks/selectors.js +7 -7
  87. package/hooks/useActionResult.js +2 -2
  88. package/hooks/useAnnotations.js +31 -47
  89. package/hooks/useClue.js +4 -6
  90. package/hooks/useClueActions.js +3 -3
  91. package/hooks/useClueConfig.js +4 -6
  92. package/hooks/useClueTypeConfig.js +3 -3
  93. package/hooks/useComparator.js +435 -722
  94. package/hooks/useErrors.js +18 -22
  95. package/hooks/useFetcherResult.js +24 -33
  96. package/hooks/useMyHighlights.js +36 -66
  97. package/hooks/useMyLocalStorage.js +37 -66
  98. package/iconify-BBckr5AQ.js +1263 -0
  99. package/icons/Action.js +49 -66
  100. package/icons/Assessment.js +68 -84
  101. package/icons/Context.js +63 -77
  102. package/icons/Opinion.js +65 -77
  103. package/icons/iconMap.js +2 -2
  104. package/identity-ByMq8VxU.js +6 -0
  105. package/index-BHAe_V9n.js +12768 -0
  106. package/index-CA5CUNZO.js +975 -0
  107. package/index-D_ZywK71.js +358 -0
  108. package/index-Dj5C04IX.js +568 -0
  109. package/index-p5_wX7q1.js +11729 -0
  110. package/isNil-CjWwlQS3.js +6 -0
  111. package/isObject-B53jY8Qg.js +7 -0
  112. package/isObjectLike-BatpeCIi.js +29 -0
  113. package/isSymbol-C3_SC0Qp.js +8 -0
  114. package/last-7CdUxN0r.js +7 -0
  115. package/main.js +60 -60
  116. package/package.json +1 -1
  117. package/sortBy-0BpKRt8p.js +79 -0
  118. package/sumBy-Do6Ff4Bw.js +8 -0
  119. package/text/Frequency.js +23 -42
  120. package/toFinite-BMy6GObD.js +14 -0
  121. package/toNumber-YVhnnJv4.js +31 -0
  122. package/useClueTypeConfig-77zd_zdF.js +2292 -0
  123. package/utils/chain.js +64 -91
  124. package/utils/classificationParser.js +256 -519
  125. package/utils/constants.js +10 -35
  126. package/utils/graph.js +45 -72
  127. package/utils/hashUtil.js +7 -7
  128. package/utils/line.js +81 -131
  129. package/utils/loggerUtil.js +3 -5
  130. package/utils/sessionStorage.js +27 -41
  131. package/utils/time.js +423 -423
  132. package/utils/utils.js +9 -9
  133. package/utils/window.js +10 -21
  134. package/utils-D5hPDE7N.js +129 -0
  135. package/ActionForm-C0aE9HUv.js +0 -5941
  136. package/AnnotationDetails-CEou0vCc.js +0 -175
  137. package/AnnotationPreview-CLMVD6Ec.js +0 -188
  138. package/ClueEnrichContext-BkD9ZwM9.js +0 -541
  139. package/FlexOne-BSYAhhtG.js +0 -9
  140. package/_MapCache-WmuDdwuH.js +0 -222
  141. package/_Uint8Array-DdG4KLKn.js +0 -128
  142. package/_baseAssignValue-CGTuELqU.js +0 -25
  143. package/_baseClone-BpWiBnMp.js +0 -283
  144. package/_baseExtremum-BY663UjY.js +0 -33
  145. package/_baseFlatten-B69cDsaV.js +0 -92
  146. package/_baseGet-Bx3A4Qfp.js +0 -108
  147. package/_baseIsEqual-B4IufFlL.js +0 -208
  148. package/_baseIteratee-7AQvAy1o.js +0 -126
  149. package/_baseSlice-GAv_YFTT.js +0 -20
  150. package/_baseSum-D0WC1dN0.js +0 -13
  151. package/_baseUniq-B8fK6hI-.js +0 -115
  152. package/_commonjsHelpers-DWwsNxpa.js +0 -8
  153. package/_createAggregator-CwGPThny.js +0 -63
  154. package/_getPrototype-CblfEidB.js +0 -5
  155. package/_getTag-jwz4XLoZ.js +0 -126
  156. package/_setToArray-CaPKQhcz.js +0 -33
  157. package/cloneDeep-DmUylbkM.js +0 -8
  158. package/countBy-DqlU5OwT.js +0 -14
  159. package/debounce-bV0h5FC5.js +0 -92
  160. package/get-DSsNkRQs.js +0 -8
  161. package/groupBy-ChDRT7uy.js +0 -14
  162. package/iconify-CXMreGTg.js +0 -1782
  163. package/identity-CPGTqrE4.js +0 -6
  164. package/index-AMfoEg_6.js +0 -696
  165. package/index-B6C2a_Lg.js +0 -1172
  166. package/index-C12gPw2W.js +0 -17698
  167. package/index-DCKkHTvx.js +0 -15750
  168. package/index-UkW8Sur3.js +0 -465
  169. package/isNil-CIubwp4T.js +0 -6
  170. package/isObject-FTY-5JQX.js +0 -7
  171. package/isObjectLike-OAgjjZye.js +0 -48
  172. package/isSymbol-Xd2FsJyp.js +0 -8
  173. package/last-CUCl67Im.js +0 -7
  174. package/sortBy-C7mGPI_D.js +0 -100
  175. package/sumBy-CGALjmwQ.js +0 -8
  176. package/toFinite-Bc55msYj.js +0 -16
  177. package/toNumber-DPxy1FBy.js +0 -39
  178. package/useClueTypeConfig-D2tf4-NM.js +0 -3289
  179. package/utils-71DpzFrA.js +0 -199
@@ -1,52 +1,31 @@
1
- import { jsx } from "react/jsx-runtime";
2
- import { Tooltip, Chip } from "@mui/material";
3
- import useClueConfig from "../hooks/useClueConfig.js";
4
- import { getParts, normalizedClassification } from "../utils/classificationParser.js";
5
- import React__default, { useMemo, memo } from "react";
6
- const THEME_TYPES = ["default", "primary", "secondary", "error", "info", "success", "warning"];
7
- const ClassificationChip = React__default.memo(
8
- ({ classification, ...otherProps }) => {
9
- var _a, _b;
10
- const { config } = useClueConfig();
11
- const parts = useMemo(() => {
12
- if (!config.c12nDef) {
13
- return null;
14
- }
15
- return getParts(classification, config.c12nDef, "short", true);
16
- }, [classification, config.c12nDef]);
17
- const normalized = useMemo(() => {
18
- if (!config.c12nDef || !parts) {
19
- return classification;
20
- }
21
- return normalizedClassification(parts, config.c12nDef, "short", true);
22
- }, [classification, config.c12nDef, parts]);
23
- const chipProps = useMemo(() => {
24
- var _a2, _b2, _c;
25
- const definedColor = (_c = (_b2 = config.c12nDef) == null ? void 0 : _b2.levels_styles_map[(_a2 = config.c12nDef) == null ? void 0 : _a2.levels_map[parts.lvlIdx]]) == null ? void 0 : _c.color;
26
- if (THEME_TYPES.includes(definedColor)) {
27
- return { color: definedColor };
28
- }
29
- if (definedColor) {
30
- return { sx: { color: definedColor } };
31
- }
32
- return { color: "default" };
33
- }, [(_a = config.c12nDef) == null ? void 0 : _a.levels_map, (_b = config.c12nDef) == null ? void 0 : _b.levels_styles_map, parts.lvlIdx]);
34
- return /* @__PURE__ */ jsx(Tooltip, { title: classification, children: /* @__PURE__ */ jsx(
35
- Chip,
1
+ import { jsx as u } from "react/jsx-runtime";
2
+ import { Tooltip as p, Chip as x } from "@mui/material";
3
+ import D from "../hooks/useClueConfig.js";
4
+ import { getParts as C, normalizedClassification as _ } from "../utils/classificationParser.js";
5
+ import v, { useMemo as s, memo as y } from "react";
6
+ const g = ["default", "primary", "secondary", "error", "info", "success", "warning"], A = v.memo(
7
+ ({ classification: r, ...n }) => {
8
+ var i, f;
9
+ const { config: e } = D(), t = s(() => e.c12nDef ? C(r, e.c12nDef, "short", !0) : null, [r, e.c12nDef]), d = s(() => !e.c12nDef || !t ? r : _(t, e.c12nDef, "short", !0), [r, e.c12nDef, t]), o = s(() => {
10
+ var c, a, m;
11
+ const l = (m = (a = e.c12nDef) == null ? void 0 : a.levels_styles_map[(c = e.c12nDef) == null ? void 0 : c.levels_map[t.lvlIdx]]) == null ? void 0 : m.color;
12
+ return g.includes(l) ? { color: l } : l ? { sx: { color: l } } : { color: "default" };
13
+ }, [(i = e.c12nDef) == null ? void 0 : i.levels_map, (f = e.c12nDef) == null ? void 0 : f.levels_styles_map, t.lvlIdx]);
14
+ return /* @__PURE__ */ u(p, { title: r, children: /* @__PURE__ */ u(
15
+ x,
36
16
  {
37
- variant: otherProps.variant || "outlined",
38
- label: normalized,
39
- ...chipProps,
40
- ...otherProps,
17
+ variant: n.variant || "outlined",
18
+ label: d,
19
+ ...o,
20
+ ...n,
41
21
  sx: [
42
- ...Array.isArray(chipProps.sx) ? chipProps.sx : [chipProps.sx],
43
- ...Array.isArray(otherProps.sx) ? otherProps.sx : [otherProps.sx]
22
+ ...Array.isArray(o.sx) ? o.sx : [o.sx],
23
+ ...Array.isArray(n.sx) ? n.sx : [n.sx]
44
24
  ]
45
25
  }
46
26
  ) });
47
27
  }
48
- );
49
- const ClassificationChip$1 = memo(ClassificationChip);
28
+ ), M = y(A);
50
29
  export {
51
- ClassificationChip$1 as default
30
+ M as default
52
31
  };
@@ -1,34 +1,29 @@
1
- import { jsx } from "react/jsx-runtime";
2
- import { Badge } from "@mui/material";
3
- import { forwardRef, cloneElement, Children } from "react";
4
- const CountBadge = forwardRef(({ children, color = "primary", count, disabled, ...props }, ref) => {
5
- if (disabled) {
6
- return cloneElement(Children.only(children), { ref, ...props });
1
+ import { jsx as m } from "react/jsx-runtime";
2
+ import { Badge as l } from "@mui/material";
3
+ import { forwardRef as d, cloneElement as f, Children as g } from "react";
4
+ const b = d(({ children: r, color: a = "primary", count: t, disabled: n, ...e }, o) => n ? f(g.only(r), { ref: o, ...e }) : /* @__PURE__ */ m(
5
+ l,
6
+ {
7
+ ref: o,
8
+ ...e,
9
+ badgeContent: t < 100 ? t : "99+",
10
+ color: a,
11
+ sx: (i) => ({
12
+ "& .MuiBadge-badge": {
13
+ backgroundColor: "transparent",
14
+ color: i.palette[a].main,
15
+ fontWeight: "bold",
16
+ right: 0,
17
+ top: 0,
18
+ transform: `translateY(-25%) translateX(${Math.min(Math.ceil(Math.log10(t)), 3) * 10}%)`,
19
+ px: 0,
20
+ fontSize: ".85rem"
21
+ },
22
+ pr: 1.5
23
+ }),
24
+ children: r
7
25
  }
8
- return /* @__PURE__ */ jsx(
9
- Badge,
10
- {
11
- ref,
12
- ...props,
13
- badgeContent: count < 100 ? count : "99+",
14
- color,
15
- sx: (theme) => ({
16
- "& .MuiBadge-badge": {
17
- backgroundColor: "transparent",
18
- color: theme.palette[color].main,
19
- fontWeight: "bold",
20
- right: 0,
21
- top: 0,
22
- transform: `translateY(-25%) translateX(${Math.min(Math.ceil(Math.log10(count)), 3) * 10}%)`,
23
- px: 0,
24
- fontSize: ".85rem"
25
- },
26
- pr: 1.5
27
- }),
28
- children
29
- }
30
- );
31
- });
26
+ ));
32
27
  export {
33
- CountBadge as default
28
+ b as default
34
29
  };
@@ -1,168 +1,155 @@
1
- import { jsxs, jsx } from "react/jsx-runtime";
2
- import { I as Icon } from "../iconify-CXMreGTg.js";
3
- import { useTheme, Card, CardHeader, Stack, CircularProgress, Divider, CardContent, Grid, Chip, Typography, Tooltip, Box } from "@mui/material";
4
- import { ClueComponentContext } from "../hooks/ClueComponentContext.js";
5
- import { b as useClueEnrichSelector } from "../ActionForm-C0aE9HUv.js";
6
- import useAnnotations from "../hooks/useAnnotations.js";
7
- import useErrors from "../hooks/useErrors.js";
8
- import AssessmentIcon from "../icons/Assessment.js";
9
- import ContextIcon from "../icons/Context.js";
10
- import OpinionIcon from "../icons/Opinion.js";
11
- import { ICON_MAP } from "../icons/iconMap.js";
12
- import FrequencyText from "../text/Frequency.js";
13
- import { u as uniq } from "../useClueTypeConfig-D2tf4-NM.js";
14
- import { memo, useState, useMemo, useCallback } from "react";
15
- import { u as useContextSelector } from "../index-AMfoEg_6.js";
16
- import AnnotationEntry from "./AnnotationEntry.js";
17
- import ExecutePopover from "./actions/ExecutePopover.js";
18
- import EnrichPopover from "./enrichment/EnrichPopover.js";
19
- const EnrichedCard = ({
20
- type,
21
- value,
22
- classification: _classification,
23
- contextIcon = false,
24
- counters = false,
25
- hideLoading = false,
26
- ...otherProps
1
+ import { jsxs as r, jsx as e } from "react/jsx-runtime";
2
+ import { I as C } from "../iconify-BBckr5AQ.js";
3
+ import { useTheme as F, Card as M, CardHeader as O, Stack as W, CircularProgress as B, Divider as D, CardContent as G, Grid as c, Chip as g, Typography as b, Tooltip as H, Box as N } from "@mui/material";
4
+ import { ClueComponentContext as R } from "../hooks/ClueComponentContext.js";
5
+ import { b as v } from "../ActionForm-pWyIi01Z.js";
6
+ import _ from "../hooks/useAnnotations.js";
7
+ import $ from "../hooks/useErrors.js";
8
+ import J from "../icons/Assessment.js";
9
+ import K from "../icons/Context.js";
10
+ import L from "../icons/Opinion.js";
11
+ import { ICON_MAP as y } from "../icons/iconMap.js";
12
+ import Q from "../text/Frequency.js";
13
+ import { u as U } from "../useClueTypeConfig-77zd_zdF.js";
14
+ import { memo as V, useState as X, useMemo as T, useCallback as Y } from "react";
15
+ import { u as Z } from "../index-Dj5C04IX.js";
16
+ import P from "./AnnotationEntry.js";
17
+ import ii from "./actions/ExecutePopover.js";
18
+ import ei from "./enrichment/EnrichPopover.js";
19
+ const ti = ({
20
+ type: s,
21
+ value: o,
22
+ classification: p,
23
+ contextIcon: z = !1,
24
+ counters: d = !1,
25
+ hideLoading: E = !1,
26
+ ...t
27
27
  }) => {
28
- const theme = useTheme();
29
- const { t } = useContextSelector(ClueComponentContext, (ctx) => ctx.i18next);
30
- const defaultClassification = useClueEnrichSelector((ctx) => ctx.defaultClassification);
31
- const enrich = useClueEnrichSelector((state) => state.enrich);
32
- const [filter, setFilter] = useState("all");
33
- const classification = useMemo(
34
- () => _classification ?? defaultClassification,
35
- [_classification, defaultClassification]
36
- );
37
- const [annotations, loading] = useAnnotations(type, value, classification);
38
- const errors = useErrors(value);
39
- const enrichRequest = { type, value, classification };
40
- const options = useMemo(() => ["all", ...uniq(annotations.map((annotation) => annotation.type))], [annotations]);
41
- const forceEnrich = useCallback(() => {
42
- return enrich(type, value, {
43
- classification,
44
- timeout: 15,
45
- force: true
46
- });
47
- }, [classification, enrich, type, value]);
48
- return /* @__PURE__ */ jsxs(
49
- Card,
28
+ const u = F(), { t: I } = Z(R, (i) => i.i18next), x = v((i) => i.defaultClassification), h = v((i) => i.enrich), [S, A] = X("all"), m = T(
29
+ () => p ?? x,
30
+ [p, x]
31
+ ), [n, k] = _(s, o, m), a = $(o), l = { type: s, value: o, classification: m }, q = T(() => ["all", ...U(n.map((i) => i.type))], [n]), w = Y(() => h(s, o, {
32
+ classification: m,
33
+ timeout: 15,
34
+ force: !0
35
+ }), [m, h, s, o]);
36
+ return /* @__PURE__ */ r(
37
+ M,
50
38
  {
51
39
  sx: [
52
40
  {
53
41
  maxWidth: "900px"
54
42
  },
55
- ...Array.isArray(otherProps == null ? void 0 : otherProps.sx) ? otherProps == null ? void 0 : otherProps.sx : [otherProps == null ? void 0 : otherProps.sx]
43
+ ...Array.isArray(t == null ? void 0 : t.sx) ? t == null ? void 0 : t.sx : [t == null ? void 0 : t.sx]
56
44
  ],
57
- ...otherProps,
45
+ ...t,
58
46
  children: [
59
- /* @__PURE__ */ jsx(
60
- CardHeader,
47
+ /* @__PURE__ */ e(
48
+ O,
61
49
  {
62
- title: /* @__PURE__ */ jsxs(Stack, { direction: "row", spacing: 1, alignItems: "center", children: [
63
- /* @__PURE__ */ jsx(FrequencyText, { annotations, value, variant: "h6" }),
64
- /* @__PURE__ */ jsx(
65
- AssessmentIcon,
50
+ title: /* @__PURE__ */ r(W, { direction: "row", spacing: 1, alignItems: "center", children: [
51
+ /* @__PURE__ */ e(Q, { annotations: n, value: o, variant: "h6" }),
52
+ /* @__PURE__ */ e(
53
+ J,
66
54
  {
67
- value: enrichRequest,
68
- annotations,
69
- counters,
55
+ value: l,
56
+ annotations: n,
57
+ counters: d,
70
58
  fontSize: "1em",
71
- disableTooltip: true
59
+ disableTooltip: !0
72
60
  }
73
61
  ),
74
- /* @__PURE__ */ jsx(
75
- OpinionIcon,
62
+ /* @__PURE__ */ e(
63
+ L,
76
64
  {
77
- value: enrichRequest,
78
- annotations,
79
- counters,
65
+ value: l,
66
+ annotations: n,
67
+ counters: d,
80
68
  fontSize: "1em",
81
- disableTooltip: true
69
+ disableTooltip: !0
82
70
  }
83
71
  ),
84
- /* @__PURE__ */ jsx(
85
- ContextIcon,
72
+ /* @__PURE__ */ e(
73
+ K,
86
74
  {
87
- value: enrichRequest,
88
- annotations,
89
- counters,
90
- showExtraIcon: contextIcon,
75
+ value: l,
76
+ annotations: n,
77
+ counters: d,
78
+ showExtraIcon: z,
91
79
  fontSize: "inherit",
92
- disableTooltip: true
80
+ disableTooltip: !0
93
81
  }
94
82
  ),
95
- loading && !hideLoading && /* @__PURE__ */ jsx(CircularProgress, { color: "primary", size: 18 }),
96
- /* @__PURE__ */ jsx("div", { style: { flex: 1 } }),
97
- /* @__PURE__ */ jsx(EnrichPopover, { selector: enrichRequest }),
98
- /* @__PURE__ */ jsx(ExecutePopover, { selectors: [enrichRequest] })
83
+ k && !E && /* @__PURE__ */ e(B, { color: "primary", size: 18 }),
84
+ /* @__PURE__ */ e("div", { style: { flex: 1 } }),
85
+ /* @__PURE__ */ e(ei, { selector: l }),
86
+ /* @__PURE__ */ e(ii, { selectors: [l] })
99
87
  ] })
100
88
  }
101
89
  ),
102
- /* @__PURE__ */ jsx(Divider, { sx: { mx: 1 } }),
103
- /* @__PURE__ */ jsxs(CardContent, { sx: { p: 1 }, children: [
104
- /* @__PURE__ */ jsxs(Grid, { container: true, spacing: 0.5, sx: { mb: 1 }, children: [
105
- options.map((opt, id) => (
90
+ /* @__PURE__ */ e(D, { sx: { mx: 1 } }),
91
+ /* @__PURE__ */ r(G, { sx: { p: 1 }, children: [
92
+ /* @__PURE__ */ r(c, { container: !0, spacing: 0.5, sx: { mb: 1 }, children: [
93
+ q.map((i, f) => (
106
94
  // eslint-disable-next-line react/no-array-index-key
107
- /* @__PURE__ */ jsx(Grid, { item: true, children: /* @__PURE__ */ jsx(
108
- Chip,
95
+ /* @__PURE__ */ e(c, { item: !0, children: /* @__PURE__ */ e(
96
+ g,
109
97
  {
110
98
  size: "small",
111
- variant: opt === filter ? "filled" : "outlined",
112
- icon: ICON_MAP[opt] && /* @__PURE__ */ jsx(Icon, { icon: ICON_MAP[opt] }),
113
- label: /* @__PURE__ */ jsxs(Typography, { variant: "caption", textTransform: "capitalize", children: [
114
- opt,
99
+ variant: i === S ? "filled" : "outlined",
100
+ icon: y[i] && /* @__PURE__ */ e(C, { icon: y[i] }),
101
+ label: /* @__PURE__ */ r(b, { variant: "caption", textTransform: "capitalize", children: [
102
+ i,
115
103
  ":",
116
104
  " ",
117
- opt === "all" ? annotations.length : annotations.filter((annotation) => annotation.type === opt).length
105
+ i === "all" ? n.length : n.filter((j) => j.type === i).length
118
106
  ] }),
119
- onClick: () => setFilter(opt)
107
+ onClick: () => A(i)
120
108
  }
121
- ) }, id)
109
+ ) }, f)
122
110
  )),
123
- (errors == null ? void 0 : errors.length) > 0 && /* @__PURE__ */ jsx(Grid, { item: true, children: /* @__PURE__ */ jsx(
124
- Tooltip,
111
+ (a == null ? void 0 : a.length) > 0 && /* @__PURE__ */ e(c, { item: !0, children: /* @__PURE__ */ e(
112
+ H,
125
113
  {
126
- title: /* @__PURE__ */ jsx("div", { onClick: (e) => e.stopPropagation(), children: errors.map((err) => /* @__PURE__ */ jsxs("div", { children: [
127
- /* @__PURE__ */ jsx("span", { style: { textTransform: "capitalize" }, children: err.source.replace(/-/g, " ") }),
114
+ title: /* @__PURE__ */ e("div", { onClick: (i) => i.stopPropagation(), children: a.map((i) => /* @__PURE__ */ r("div", { children: [
115
+ /* @__PURE__ */ e("span", { style: { textTransform: "capitalize" }, children: i.source.replace(/-/g, " ") }),
128
116
  ":",
129
117
  " ",
130
- err.message
131
- ] }, err.source)) }),
132
- children: /* @__PURE__ */ jsx(
133
- Chip,
118
+ i.message
119
+ ] }, i.source)) }),
120
+ children: /* @__PURE__ */ e(
121
+ g,
134
122
  {
135
123
  size: "small",
136
124
  variant: "outlined",
137
- icon: /* @__PURE__ */ jsx(
138
- Icon,
125
+ icon: /* @__PURE__ */ e(
126
+ C,
139
127
  {
140
128
  icon: "material-symbols:timer-outline",
141
- color: theme.palette.error.main,
129
+ color: u.palette.error.main,
142
130
  style: { filter: "drop-shadow(0px 0px 1px rgb(0 0 0 / 0.4))" }
143
131
  }
144
132
  ),
145
- label: /* @__PURE__ */ jsxs(Typography, { variant: "caption", textTransform: "capitalize", children: [
146
- t("annotation.failed"),
133
+ label: /* @__PURE__ */ r(b, { variant: "caption", textTransform: "capitalize", children: [
134
+ I("annotation.failed"),
147
135
  ": ",
148
- errors.length
136
+ a.length
149
137
  ] }),
150
- onClick: forceEnrich
138
+ onClick: w
151
139
  }
152
140
  )
153
141
  }
154
142
  ) })
155
143
  ] }),
156
- /* @__PURE__ */ jsx(Grid, { container: true, spacing: 1, alignItems: "stretch", children: annotations.map((annotation, id) => (
144
+ /* @__PURE__ */ e(c, { container: !0, spacing: 1, alignItems: "stretch", children: n.map((i, f) => (
157
145
  // eslint-disable-next-line react/no-array-index-key
158
- /* @__PURE__ */ jsx(Grid, { item: true, xs: 6, minWidth: "300px", children: /* @__PURE__ */ jsx(Box, { sx: { border: `thin solid ${theme.palette.divider}`, p: 1, height: "100%" }, children: /* @__PURE__ */ jsx(AnnotationEntry, { annotation }) }) }, id)
146
+ /* @__PURE__ */ e(c, { item: !0, xs: 6, minWidth: "300px", children: /* @__PURE__ */ e(N, { sx: { border: `thin solid ${u.palette.divider}`, p: 1, height: "100%" }, children: /* @__PURE__ */ e(P, { annotation: i }) }) }, f)
159
147
  )) })
160
148
  ] })
161
149
  ]
162
150
  }
163
151
  );
164
- };
165
- const EnrichedCard_default = memo(EnrichedCard);
152
+ }, yi = V(ti);
166
153
  export {
167
- EnrichedCard_default as default
154
+ yi as default
168
155
  };