@burdenoff/microfe-bigconsole 2026.1119.2 → 2026.1119.4
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.
- package/dist/bigconsole/components/parser/ParserSelector.js +150 -145
- package/dist/bigconsole/components/widgets/FilterNotAppliedNotice.d.ts +15 -0
- package/dist/bigconsole/components/widgets/FilterNotAppliedNotice.js +62 -0
- package/dist/bigconsole/components/widgets/WidgetWrapper.js +353 -351
- package/dist/bigconsole/components/widgets/chart/ChartWidget.js +131 -126
- package/dist/bigconsole/components/widgets/chart/chartRows.d.ts +16 -0
- package/dist/bigconsole/components/widgets/chart/chartRows.js +33 -1
- package/dist/bigconsole/components/widgets/metric-card/MetricCardWidget.d.ts +2 -20
- package/dist/bigconsole/components/widgets/metric-card/MetricCardWidget.js +4 -3
- package/dist/bigconsole/components/widgets/metric-card/metricCardData.d.ts +48 -0
- package/dist/bigconsole/components/widgets/metric-card/metricCardData.js +96 -0
- package/dist/bigconsole/components/widgets/metric-card/metricData.d.ts +9 -2
- package/dist/bigconsole/components/widgets/metric-card/metricData.js +10 -69
- package/dist/bigconsole/customWidget/CustomWidgetBuilderSheet.js +50 -49
- package/dist/bigconsole/customWidget/CustomWidgetProposalPanel.js +223 -201
- package/dist/bigconsole/customWidget/index.d.ts +2 -1
- package/dist/bigconsole/customWidget/index.js +1 -0
- package/dist/bigconsole/customWidget/proposalContract.d.ts +55 -1
- package/dist/bigconsole/customWidget/proposalContract.js +37 -14
- package/dist/bigconsole/customWidget/proposalPreviewData.d.ts +18 -0
- package/dist/bigconsole/customWidget/proposalPreviewData.js +70 -0
- package/dist/bigconsole/customWidget/proposalSource.d.ts +10 -0
- package/dist/bigconsole/customWidget/proposalSource.js +197 -51
- package/dist/bigconsole/hooks/useParserOperations.js +80 -74
- package/dist/bigconsole/pages/ParserBuilderPage.js +540 -518
- package/dist/bigconsole/store/parserScope.d.ts +24 -0
- package/dist/bigconsole/store/parserScope.js +17 -0
- package/dist/bigconsole/store/parserStore.d.ts +3 -0
- package/dist/bigconsole/store/parserStore.js +70 -68
- package/dist/bigconsole/utils/applyGlobalFilters.d.ts +3 -1
- package/dist/bigconsole/utils/applyGlobalFilters.js +53 -4
- package/dist/bigconsole/utils/globalFilterMatching.d.ts +21 -3
- package/dist/bigconsole/utils/globalFilterMatching.js +14 -9
- package/dist/generated/wspace-operations.d.ts +10 -0
- package/dist/generated/wspace-operations.js +180 -110
- package/package.json +1 -1
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { Parser } from '../types';
|
|
2
|
+
/** The `consoleId` of a workspace-global parser. */
|
|
3
|
+
export declare const GLOBAL_PARSER_CONSOLE_ID = "default";
|
|
4
|
+
/** Which parsers a reader of the store wants. */
|
|
5
|
+
export type ParserStoreScope =
|
|
6
|
+
/** Every parser the caller can see: global plus each readable dashboard's. */
|
|
7
|
+
{
|
|
8
|
+
kind: 'all';
|
|
9
|
+
}
|
|
10
|
+
/** The parsers of one console (`default` for the global ones). */
|
|
11
|
+
| {
|
|
12
|
+
kind: 'console';
|
|
13
|
+
consoleId: string;
|
|
14
|
+
};
|
|
15
|
+
/** Whether a parser is workspace-global rather than dashboard-scoped. */
|
|
16
|
+
export declare function isGlobalParser(parser: Pick<Parser, 'consoleId'>): boolean;
|
|
17
|
+
/** The stored parsers that belong to `scope`, in insertion order. */
|
|
18
|
+
export declare function selectParsersInScope(parsers: ReadonlyMap<string, Parser>, scope: ParserStoreScope): Parser[];
|
|
19
|
+
/**
|
|
20
|
+
* The store after a complete (unfiltered) fetch of `scope`: the fetched list
|
|
21
|
+
* becomes the truth for that scope, so a parser deleted elsewhere drops out,
|
|
22
|
+
* while parsers of other scopes are kept untouched.
|
|
23
|
+
*/
|
|
24
|
+
export declare function replaceParsersInScope(parsers: ReadonlyMap<string, Parser>, scope: ParserStoreScope, fetched: readonly Parser[]): Map<string, Parser>;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
// src/bigconsole/store/parserScope.ts
|
|
2
|
+
var e = "default";
|
|
3
|
+
function t(e, t) {
|
|
4
|
+
return t.kind === "all" || e.consoleId === t.consoleId;
|
|
5
|
+
}
|
|
6
|
+
function n(e, n) {
|
|
7
|
+
let r = [];
|
|
8
|
+
for (let i of e.values()) t(i, n) && r.push(i);
|
|
9
|
+
return r;
|
|
10
|
+
}
|
|
11
|
+
function r(e, n, r) {
|
|
12
|
+
let i = /* @__PURE__ */ new Map();
|
|
13
|
+
for (let [r, a] of e) t(a, n) || i.set(r, a);
|
|
14
|
+
for (let e of r) i.set(e.id, e);
|
|
15
|
+
return i;
|
|
16
|
+
}
|
|
17
|
+
export { e as GLOBAL_PARSER_CONSOLE_ID, r as replaceParsersInScope, n as selectParsersInScope };
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Parser, ParserType, ParserStatus } from '../types';
|
|
2
|
+
import { ParserStoreScope } from './parserScope';
|
|
2
3
|
/** UI state for individual Parser items */
|
|
3
4
|
interface ParserUIState {
|
|
4
5
|
isLoading: boolean;
|
|
@@ -28,6 +29,8 @@ interface ParserState {
|
|
|
28
29
|
/** Parser store actions */
|
|
29
30
|
interface ParserActions {
|
|
30
31
|
setParsers: (parsers: Parser[]) => void;
|
|
32
|
+
/** Make a complete fetch of `scope` the truth for that scope (BOFF-9770). */
|
|
33
|
+
replaceParsersInScope: (scope: ParserStoreScope, parsers: Parser[]) => void;
|
|
31
34
|
addParser: (parser: Parser) => void;
|
|
32
35
|
updateParser: (id: string, updates: Partial<Parser>) => void;
|
|
33
36
|
removeParser: (id: string) => void;
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { replaceParsersInScope as e } from "./parserScope.js";
|
|
2
|
+
import { create as t } from "zustand";
|
|
3
|
+
import { devtools as n, persist as r } from "zustand/middleware";
|
|
4
|
+
import { createProfileScopedStorage as i } from "@burdenoff/fe-libs/shared/utils";
|
|
4
5
|
// src/bigconsole/store/parserStore.ts
|
|
5
|
-
var
|
|
6
|
+
var a = {
|
|
6
7
|
parsers: /* @__PURE__ */ new Map(),
|
|
7
8
|
parserUIStates: /* @__PURE__ */ new Map(),
|
|
8
9
|
dirtyParserIds: /* @__PURE__ */ new Set(),
|
|
@@ -19,77 +20,78 @@ var i = {
|
|
|
19
20
|
testOutput: null,
|
|
20
21
|
testError: null,
|
|
21
22
|
testExecutionTime: null
|
|
22
|
-
},
|
|
23
|
-
...
|
|
24
|
-
setParsers: (
|
|
25
|
-
let n = new Map(
|
|
26
|
-
for (let
|
|
23
|
+
}, o = t()(n(r((t, n) => ({
|
|
24
|
+
...a,
|
|
25
|
+
setParsers: (e) => t((t) => {
|
|
26
|
+
let n = new Map(t.parsers);
|
|
27
|
+
for (let t of e) n.set(t.id, t);
|
|
27
28
|
return { parsers: n };
|
|
28
29
|
}),
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
30
|
+
replaceParsersInScope: (n, r) => t((t) => ({ parsers: e(t.parsers, n, r) })),
|
|
31
|
+
addParser: (e) => t((t) => {
|
|
32
|
+
let n = new Map(t.parsers);
|
|
33
|
+
return n.set(e.id, e), { parsers: n };
|
|
32
34
|
}),
|
|
33
|
-
updateParser: (
|
|
34
|
-
let r = new Map(
|
|
35
|
-
return i && r.set(
|
|
35
|
+
updateParser: (e, n) => t((t) => {
|
|
36
|
+
let r = new Map(t.parsers), i = r.get(e);
|
|
37
|
+
return i && r.set(e, {
|
|
36
38
|
...i,
|
|
37
39
|
...n
|
|
38
40
|
}), { parsers: r };
|
|
39
41
|
}),
|
|
40
|
-
removeParser: (
|
|
41
|
-
let n = new Map(
|
|
42
|
-
n.delete(
|
|
43
|
-
let r = new Map(
|
|
44
|
-
return r.delete(
|
|
42
|
+
removeParser: (e) => t((t) => {
|
|
43
|
+
let n = new Map(t.parsers);
|
|
44
|
+
n.delete(e);
|
|
45
|
+
let r = new Map(t.parserUIStates);
|
|
46
|
+
return r.delete(e), {
|
|
45
47
|
parsers: n,
|
|
46
48
|
parserUIStates: r,
|
|
47
|
-
selectedParserId:
|
|
49
|
+
selectedParserId: t.selectedParserId === e ? null : t.selectedParserId
|
|
48
50
|
};
|
|
49
51
|
}),
|
|
50
|
-
selectParser: (
|
|
51
|
-
clearSelection: () =>
|
|
52
|
-
setTypeFilter: (
|
|
53
|
-
setStatusFilter: (
|
|
54
|
-
setSearchQuery: (
|
|
55
|
-
clearFilters: () =>
|
|
52
|
+
selectParser: (e) => t({ selectedParserId: e }),
|
|
53
|
+
clearSelection: () => t({ selectedParserId: null }),
|
|
54
|
+
setTypeFilter: (e) => t({ typeFilter: e }),
|
|
55
|
+
setStatusFilter: (e) => t({ statusFilter: e }),
|
|
56
|
+
setSearchQuery: (e) => t({ searchQuery: e }),
|
|
57
|
+
clearFilters: () => t({
|
|
56
58
|
typeFilter: null,
|
|
57
59
|
statusFilter: null,
|
|
58
60
|
searchQuery: ""
|
|
59
61
|
}),
|
|
60
|
-
openCreateDialog: () =>
|
|
62
|
+
openCreateDialog: () => t({
|
|
61
63
|
createDialogOpen: !0,
|
|
62
64
|
currentParser: null
|
|
63
65
|
}),
|
|
64
|
-
closeCreateDialog: () =>
|
|
66
|
+
closeCreateDialog: () => t({
|
|
65
67
|
createDialogOpen: !1,
|
|
66
68
|
currentParser: null
|
|
67
69
|
}),
|
|
68
|
-
openEditDialog: (
|
|
70
|
+
openEditDialog: (e) => t({
|
|
69
71
|
editDialogOpen: !0,
|
|
70
|
-
currentParser:
|
|
72
|
+
currentParser: e
|
|
71
73
|
}),
|
|
72
|
-
closeEditDialog: () =>
|
|
74
|
+
closeEditDialog: () => t({
|
|
73
75
|
editDialogOpen: !1,
|
|
74
76
|
currentParser: null
|
|
75
77
|
}),
|
|
76
|
-
openDeleteDialog: (
|
|
78
|
+
openDeleteDialog: (e) => t({
|
|
77
79
|
deleteDialogOpen: !0,
|
|
78
|
-
currentParser:
|
|
80
|
+
currentParser: e
|
|
79
81
|
}),
|
|
80
|
-
closeDeleteDialog: () =>
|
|
82
|
+
closeDeleteDialog: () => t({
|
|
81
83
|
deleteDialogOpen: !1,
|
|
82
84
|
currentParser: null
|
|
83
85
|
}),
|
|
84
|
-
openTestDialog: (
|
|
86
|
+
openTestDialog: (e) => t({
|
|
85
87
|
testDialogOpen: !0,
|
|
86
|
-
currentParser:
|
|
88
|
+
currentParser: e,
|
|
87
89
|
testInput: "{}",
|
|
88
90
|
testOutput: null,
|
|
89
91
|
testError: null,
|
|
90
92
|
testExecutionTime: null
|
|
91
93
|
}),
|
|
92
|
-
closeTestDialog: () =>
|
|
94
|
+
closeTestDialog: () => t({
|
|
93
95
|
testDialogOpen: !1,
|
|
94
96
|
currentParser: null,
|
|
95
97
|
testInput: "{}",
|
|
@@ -97,76 +99,76 @@ var i = {
|
|
|
97
99
|
testError: null,
|
|
98
100
|
testExecutionTime: null
|
|
99
101
|
}),
|
|
100
|
-
setParserLoading: (
|
|
101
|
-
let r = new Map(
|
|
102
|
+
setParserLoading: (e, n) => t((t) => {
|
|
103
|
+
let r = new Map(t.parserUIStates), i = r.get(e) || {
|
|
102
104
|
isLoading: !1,
|
|
103
105
|
isError: !1,
|
|
104
106
|
isTesting: !1
|
|
105
107
|
};
|
|
106
|
-
return r.set(
|
|
108
|
+
return r.set(e, {
|
|
107
109
|
...i,
|
|
108
110
|
isLoading: n
|
|
109
111
|
}), { parserUIStates: r };
|
|
110
112
|
}),
|
|
111
|
-
setParserError: (
|
|
112
|
-
let r = new Map(
|
|
113
|
+
setParserError: (e, n) => t((t) => {
|
|
114
|
+
let r = new Map(t.parserUIStates), i = r.get(e) || {
|
|
113
115
|
isLoading: !1,
|
|
114
116
|
isError: !1,
|
|
115
117
|
isTesting: !1
|
|
116
118
|
};
|
|
117
|
-
return r.set(
|
|
119
|
+
return r.set(e, {
|
|
118
120
|
...i,
|
|
119
121
|
isError: n !== null,
|
|
120
122
|
errorMessage: n || void 0
|
|
121
123
|
}), { parserUIStates: r };
|
|
122
124
|
}),
|
|
123
|
-
setParserTesting: (
|
|
124
|
-
let r = new Map(
|
|
125
|
+
setParserTesting: (e, n) => t((t) => {
|
|
126
|
+
let r = new Map(t.parserUIStates), i = r.get(e) || {
|
|
125
127
|
isLoading: !1,
|
|
126
128
|
isError: !1,
|
|
127
129
|
isTesting: !1
|
|
128
130
|
};
|
|
129
|
-
return r.set(
|
|
131
|
+
return r.set(e, {
|
|
130
132
|
...i,
|
|
131
133
|
isTesting: n
|
|
132
134
|
}), { parserUIStates: r };
|
|
133
135
|
}),
|
|
134
|
-
markParserDirty: (
|
|
135
|
-
markParserClean: (
|
|
136
|
-
let n = new Set(
|
|
137
|
-
return n.delete(
|
|
138
|
-
}),
|
|
139
|
-
clearAllDirty: () =>
|
|
140
|
-
setTestInput: (
|
|
141
|
-
setTestOutput: (
|
|
142
|
-
setTestError: (
|
|
143
|
-
setTestExecutionTime: (
|
|
144
|
-
clearTestResults: () =>
|
|
136
|
+
markParserDirty: (e) => t((t) => ({ dirtyParserIds: /* @__PURE__ */ new Set([...t.dirtyParserIds, e]) })),
|
|
137
|
+
markParserClean: (e) => t((t) => {
|
|
138
|
+
let n = new Set(t.dirtyParserIds);
|
|
139
|
+
return n.delete(e), { dirtyParserIds: n };
|
|
140
|
+
}),
|
|
141
|
+
clearAllDirty: () => t({ dirtyParserIds: /* @__PURE__ */ new Set() }),
|
|
142
|
+
setTestInput: (e) => t({ testInput: e }),
|
|
143
|
+
setTestOutput: (e) => t({ testOutput: e }),
|
|
144
|
+
setTestError: (e) => t({ testError: e }),
|
|
145
|
+
setTestExecutionTime: (e) => t({ testExecutionTime: e }),
|
|
146
|
+
clearTestResults: () => t({
|
|
145
147
|
testOutput: null,
|
|
146
148
|
testError: null,
|
|
147
149
|
testExecutionTime: null
|
|
148
150
|
}),
|
|
149
|
-
getParserById: (e) =>
|
|
151
|
+
getParserById: (e) => n().parsers.get(e),
|
|
150
152
|
getFilteredParsers: () => {
|
|
151
|
-
let e =
|
|
152
|
-
if (e.typeFilter && (
|
|
153
|
-
let
|
|
154
|
-
|
|
153
|
+
let e = n(), t = Array.from(e.parsers.values());
|
|
154
|
+
if (e.typeFilter && (t = t.filter((t) => t.type === e.typeFilter)), e.statusFilter && (t = t.filter((t) => t.status === e.statusFilter)), e.searchQuery.trim()) {
|
|
155
|
+
let n = e.searchQuery.toLowerCase();
|
|
156
|
+
t = t.filter((e) => e.name.toLowerCase().includes(n) || e.description?.toLowerCase().includes(n) || e.inputSinkKey?.toLowerCase().includes(n));
|
|
155
157
|
}
|
|
156
|
-
return
|
|
158
|
+
return t.sort((e, t) => new Date(t.updatedAt).getTime() - new Date(e.updatedAt).getTime());
|
|
157
159
|
},
|
|
158
160
|
getDirtyParsers: () => {
|
|
159
|
-
let e =
|
|
161
|
+
let e = n();
|
|
160
162
|
return Array.from(e.dirtyParserIds).map((t) => e.parsers.get(t)).filter((e) => e !== void 0);
|
|
161
163
|
},
|
|
162
|
-
reset: () =>
|
|
164
|
+
reset: () => t(a)
|
|
163
165
|
}), {
|
|
164
166
|
name: "bigconsole-parser-store",
|
|
165
|
-
storage:
|
|
167
|
+
storage: i(),
|
|
166
168
|
partialize: (e) => ({
|
|
167
169
|
typeFilter: e.typeFilter,
|
|
168
170
|
statusFilter: e.statusFilter,
|
|
169
171
|
searchQuery: e.searchQuery
|
|
170
172
|
})
|
|
171
173
|
}), { name: "ParserStore" }));
|
|
172
|
-
export {
|
|
174
|
+
export { o as useParserStore };
|
|
@@ -7,7 +7,9 @@
|
|
|
7
7
|
* filter either narrows the rows a widget renders or is reported as not
|
|
8
8
|
* applicable. Envelopes keep every other property (e.g. retention `periods`,
|
|
9
9
|
* chart axes), so derived values such as retention averages are recomputed by
|
|
10
|
-
* the renderer from the narrowed rows.
|
|
10
|
+
* the renderer from the narrowed rows. A heatmap's axes are the exception:
|
|
11
|
+
* labels whose cells were all filtered out are dropped (see
|
|
12
|
+
* `narrowHeatmapEnvelope`), because the renderer draws every axis label.
|
|
11
13
|
*/
|
|
12
14
|
export interface ApplyGlobalFiltersOptions {
|
|
13
15
|
/** Merged filter values keyed by filter id, `ctx_<field>` (drilldown) or a field name. */
|
|
@@ -80,11 +80,60 @@ function f(e, n) {
|
|
|
80
80
|
if (typeof e != "object") return e;
|
|
81
81
|
let o = e, s = t(o, n.widgetType);
|
|
82
82
|
if (!s) return e;
|
|
83
|
-
let c = o[s].filter(a)
|
|
84
|
-
return {
|
|
83
|
+
let c = o[s], l = c.filter(a), u = {
|
|
85
84
|
...o,
|
|
86
|
-
[s]:
|
|
87
|
-
...s === "rows" ? { totalRows:
|
|
85
|
+
[s]: l,
|
|
86
|
+
...s === "rows" ? { totalRows: l.length } : {}
|
|
88
87
|
};
|
|
88
|
+
return s === "cells" && l.length < c.length ? g(u, c, l) : u;
|
|
89
|
+
}
|
|
90
|
+
function p(e) {
|
|
91
|
+
return Array.isArray(e) && e.every((e) => typeof e == "string");
|
|
92
|
+
}
|
|
93
|
+
function m(e) {
|
|
94
|
+
let t;
|
|
95
|
+
for (let n of e) {
|
|
96
|
+
if (typeof n != "object" || !n) continue;
|
|
97
|
+
let e = l(n.value);
|
|
98
|
+
e !== void 0 && (t = t ? {
|
|
99
|
+
min: Math.min(t.min, e),
|
|
100
|
+
max: Math.max(t.max, e)
|
|
101
|
+
} : {
|
|
102
|
+
min: e,
|
|
103
|
+
max: e
|
|
104
|
+
});
|
|
105
|
+
}
|
|
106
|
+
return t;
|
|
107
|
+
}
|
|
108
|
+
function h(e, t) {
|
|
109
|
+
let n = /* @__PURE__ */ new Set();
|
|
110
|
+
for (let r of e) {
|
|
111
|
+
if (typeof r != "object" || !r) continue;
|
|
112
|
+
let e = r[t];
|
|
113
|
+
e != null && n.add(String(e));
|
|
114
|
+
}
|
|
115
|
+
return n;
|
|
116
|
+
}
|
|
117
|
+
function g(e, t, n) {
|
|
118
|
+
let r = { ...e };
|
|
119
|
+
for (let [i, a] of [["rows", "row"], ["columns", "column"]]) {
|
|
120
|
+
let o = e[i];
|
|
121
|
+
if (!p(o)) continue;
|
|
122
|
+
let s = h(t, a), c = h(n, a);
|
|
123
|
+
r[i] = o.filter((e) => !s.has(e) || c.has(e));
|
|
124
|
+
}
|
|
125
|
+
let i = m(t);
|
|
126
|
+
if (!i) return r;
|
|
127
|
+
let a = m(n), o = [[
|
|
128
|
+
"minValue",
|
|
129
|
+
i.min,
|
|
130
|
+
a?.min
|
|
131
|
+
], [
|
|
132
|
+
"maxValue",
|
|
133
|
+
i.max,
|
|
134
|
+
a?.max
|
|
135
|
+
]];
|
|
136
|
+
for (let [t, n, i] of o) l(e[t]) === n && (i === void 0 ? delete r[t] : r[t] = i);
|
|
137
|
+
return r;
|
|
89
138
|
}
|
|
90
139
|
export { f as applyGlobalFilters };
|
|
@@ -43,14 +43,32 @@ export interface InapplicableFilter {
|
|
|
43
43
|
filterId: string;
|
|
44
44
|
name: string;
|
|
45
45
|
field: string;
|
|
46
|
+
/**
|
|
47
|
+
* Why the filter cannot narrow the widget:
|
|
48
|
+
* - `missingField`: no row carries the field (or the data has no rows).
|
|
49
|
+
* - `precomputedValue`: the rows carry the field, but the value the widget
|
|
50
|
+
* shows is a precomputed figure beside them (a metric card's `total`), so
|
|
51
|
+
* narrowing the rows does not change it.
|
|
52
|
+
*/
|
|
53
|
+
reason: 'missingField' | 'precomputedValue';
|
|
54
|
+
}
|
|
55
|
+
export interface FindInapplicableFiltersOptions {
|
|
56
|
+
/**
|
|
57
|
+
* True when the widget shows a single precomputed value rather than a value
|
|
58
|
+
* derived from the rows (see `resolveMetricCardData`). Every active filter is
|
|
59
|
+
* then reported, because none can change that value.
|
|
60
|
+
*/
|
|
61
|
+
precomputedValue?: boolean;
|
|
46
62
|
}
|
|
47
63
|
/**
|
|
48
64
|
* Active filters that cannot narrow this widget's data: either the data has
|
|
49
65
|
* object rows but none carries the filter's configured field, or the data has
|
|
50
|
-
* no rows at all (e.g. a single-value metric card)
|
|
51
|
-
*
|
|
66
|
+
* no rows at all (e.g. a single-value metric card), or the widget shows a
|
|
67
|
+
* precomputed value the rows do not feed (`options.precomputedValue`). Pass
|
|
68
|
+
* the same subtree that is filtered (after dataKey/dataPath resolution).
|
|
69
|
+
* Absent data reports nothing.
|
|
52
70
|
*/
|
|
53
|
-
export declare function findInapplicableFilters(data: unknown, filterMeta: Record<string, FilterMeta>, filterValues: Record<string, unknown>, widgetType?: string): InapplicableFilter[];
|
|
71
|
+
export declare function findInapplicableFilters(data: unknown, filterMeta: Record<string, FilterMeta>, filterValues: Record<string, unknown>, widgetType?: string, options?: FindInapplicableFiltersOptions): InapplicableFilter[];
|
|
54
72
|
/**
|
|
55
73
|
* Category options for a filter. Configured labels always win for the values
|
|
56
74
|
* they cover. With `optionsFromField`, data-derived values lead and configured
|
|
@@ -105,15 +105,20 @@ function d(e, t) {
|
|
|
105
105
|
label: e
|
|
106
106
|
}));
|
|
107
107
|
}
|
|
108
|
-
function f(e, t, r, i) {
|
|
109
|
-
if (e == null || l(e, i)) return [];
|
|
110
|
-
let
|
|
111
|
-
for (let [e, n] of Object.entries(t))
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
108
|
+
function f(e, t, r, i, a = {}) {
|
|
109
|
+
if (e == null || !a.precomputedValue && l(e, i)) return [];
|
|
110
|
+
let c = u(e, i).filter(n), d = [];
|
|
111
|
+
for (let [e, n] of Object.entries(t)) {
|
|
112
|
+
if (o(r[e])) continue;
|
|
113
|
+
let t = c.some((e) => s(e, n.field) !== void 0);
|
|
114
|
+
(!t || a.precomputedValue) && d.push({
|
|
115
|
+
filterId: e,
|
|
116
|
+
name: n.name,
|
|
117
|
+
field: n.field,
|
|
118
|
+
reason: t || a.precomputedValue && c.length === 0 ? "precomputedValue" : "missingField"
|
|
119
|
+
});
|
|
120
|
+
}
|
|
121
|
+
return d;
|
|
117
122
|
}
|
|
118
123
|
function p(e, t, r) {
|
|
119
124
|
let i = (Array.isArray(e) ? e : []).filter(n).map((e) => ({
|
|
@@ -3466,6 +3466,15 @@ export type GetDrilldownTargetDashboardQuery = {
|
|
|
3466
3466
|
};
|
|
3467
3467
|
} | null;
|
|
3468
3468
|
};
|
|
3469
|
+
export type GetParserScopeDashboardQueryVariables = Exact<{
|
|
3470
|
+
id: string | number;
|
|
3471
|
+
}>;
|
|
3472
|
+
export type GetParserScopeDashboardQuery = {
|
|
3473
|
+
getDashboard: {
|
|
3474
|
+
id: string;
|
|
3475
|
+
name: string;
|
|
3476
|
+
} | null;
|
|
3477
|
+
};
|
|
3469
3478
|
export type GetTemplateQueryVariables = Exact<{
|
|
3470
3479
|
id: string | number;
|
|
3471
3480
|
}>;
|
|
@@ -8711,6 +8720,7 @@ export declare const GetDashboardShareDocument: DocumentNode<GetDashboardShareQu
|
|
|
8711
8720
|
export declare const GetDashboardViewDocument: DocumentNode<GetDashboardViewQuery, GetDashboardViewQueryVariables>;
|
|
8712
8721
|
export declare const GetDefaultDashboardViewDocument: DocumentNode<GetDefaultDashboardViewQuery, GetDefaultDashboardViewQueryVariables>;
|
|
8713
8722
|
export declare const GetDrilldownTargetDashboardDocument: DocumentNode<GetDrilldownTargetDashboardQuery, GetDrilldownTargetDashboardQueryVariables>;
|
|
8723
|
+
export declare const GetParserScopeDashboardDocument: DocumentNode<GetParserScopeDashboardQuery, GetParserScopeDashboardQueryVariables>;
|
|
8714
8724
|
export declare const GetTemplateDocument: DocumentNode<GetTemplateQuery, GetTemplateQueryVariables>;
|
|
8715
8725
|
export declare const ListDashboardEmbedPoliciesDocument: DocumentNode<ListDashboardEmbedPoliciesQuery, ListDashboardEmbedPoliciesQueryVariables>;
|
|
8716
8726
|
export declare const ListDashboardSharesDocument: DocumentNode<ListDashboardSharesQuery, ListDashboardSharesQueryVariables>;
|