@sinequa/atomic 2.0.0 → 2.0.1
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/README.md +70 -8
- package/dist/atomic.js +465 -453
- package/dist/atomic.umd.cjs +1 -1
- package/dist/authentication/constants.d.ts +8 -0
- package/dist/authentication/constants.d.ts.map +1 -1
- package/dist/authentication/providers/oauth-authentication.d.ts.map +1 -1
- package/dist/authentication/providers/saml-authentication.d.ts.map +1 -1
- package/dist/authentication/session/login.d.ts.map +1 -1
- package/dist/utils/notification.d.ts +5 -0
- package/dist/utils/notification.d.ts.map +1 -1
- package/package.json +4 -4
package/dist/atomic.js
CHANGED
|
@@ -16,7 +16,7 @@ const g = {
|
|
|
16
16
|
bearer: (e) => ({ kind: "bearer", token: e }),
|
|
17
17
|
unknown: () => ({ kind: "unknown" })
|
|
18
18
|
};
|
|
19
|
-
function
|
|
19
|
+
function he(e, t) {
|
|
20
20
|
const { useCredentials: r, useSSO: n, useSAML: o } = e;
|
|
21
21
|
return o && t.autoSAMLProvider ? g.saml(t.autoSAMLProvider) : r && n ? g.unknown() : r ? g.credentials() : n ? g.sso() : t.authMode ?? g.unknown();
|
|
22
22
|
}
|
|
@@ -56,16 +56,46 @@ function S(e) {
|
|
|
56
56
|
l.authMode = o;
|
|
57
57
|
return;
|
|
58
58
|
}
|
|
59
|
-
(t !== void 0 || r !== void 0 || n !== void 0) && (l.authMode =
|
|
59
|
+
(t !== void 0 || r !== void 0 || n !== void 0) && (l.authMode = he(
|
|
60
60
|
{ useCredentials: t, useSSO: r, useSAML: n },
|
|
61
61
|
l
|
|
62
62
|
));
|
|
63
63
|
}
|
|
64
|
-
const
|
|
65
|
-
|
|
64
|
+
const H = {
|
|
65
|
+
store: {},
|
|
66
|
+
getItem(e) {
|
|
67
|
+
return this.store[e] ?? null;
|
|
68
|
+
},
|
|
69
|
+
setItem(e, t) {
|
|
70
|
+
this.store[e] = t.toString();
|
|
71
|
+
},
|
|
72
|
+
removeItem(e) {
|
|
73
|
+
delete this.store[e];
|
|
74
|
+
},
|
|
75
|
+
clear() {
|
|
76
|
+
this.store = {};
|
|
77
|
+
}
|
|
78
|
+
}, J = H;
|
|
79
|
+
function ge(e) {
|
|
80
|
+
return typeof window > "u" || !window.localStorage ? H.getItem(e) : window.localStorage.getItem(e);
|
|
81
|
+
}
|
|
82
|
+
function pe(e) {
|
|
83
|
+
typeof window > "u" || !window.localStorage ? H.removeItem(e) : window.localStorage.removeItem(e);
|
|
84
|
+
}
|
|
85
|
+
function W(e) {
|
|
86
|
+
return typeof window > "u" || !window.sessionStorage ? J.getItem(e) : window.sessionStorage.getItem(e);
|
|
87
|
+
}
|
|
88
|
+
function X(e, t) {
|
|
89
|
+
typeof window > "u" || !window.sessionStorage ? J.setItem(e, t) : window.sessionStorage.setItem(e, t);
|
|
90
|
+
}
|
|
91
|
+
function $(e) {
|
|
92
|
+
typeof window > "u" || !window.sessionStorage ? J.removeItem(e) : window.sessionStorage.removeItem(e);
|
|
93
|
+
}
|
|
94
|
+
const me = /.*:\(?([><=\d\-.AND ]+)\)?/;
|
|
95
|
+
function wt(e, t) {
|
|
66
96
|
return !e?.items || e?.items?.length === 0 ? [] : e.items.reduce((o, a) => {
|
|
67
97
|
if (!a.value || a.value === "") return o;
|
|
68
|
-
const s =
|
|
98
|
+
const s = we(a, e.column);
|
|
69
99
|
return o.push({
|
|
70
100
|
operator: s.operator,
|
|
71
101
|
value: s.value,
|
|
@@ -76,8 +106,8 @@ function mt(e, t) {
|
|
|
76
106
|
}), o;
|
|
77
107
|
}, []);
|
|
78
108
|
}
|
|
79
|
-
function
|
|
80
|
-
const r = t, n = e.value.match(
|
|
109
|
+
function we(e, t) {
|
|
110
|
+
const r = t, n = e.value.match(me);
|
|
81
111
|
if (n?.[1]) {
|
|
82
112
|
const a = (n?.[1].split(" AND ")).map((s) => {
|
|
83
113
|
const c = s.indexOf(">=") !== -1 ? "gte" : "lt", i = s.substring(s.indexOf(" ") + 1);
|
|
@@ -102,20 +132,20 @@ function de(e, t) {
|
|
|
102
132
|
display: e.display
|
|
103
133
|
};
|
|
104
134
|
}
|
|
105
|
-
function
|
|
135
|
+
function _t(e, t, r) {
|
|
106
136
|
return e.valuesAreExpressions ? t.display === r.display : t.value === r.value;
|
|
107
137
|
}
|
|
108
|
-
function
|
|
109
|
-
return e.items && (e.items = e.items.map((t) =>
|
|
138
|
+
function _e(e) {
|
|
139
|
+
return e.items && (e.items = e.items.map((t) => _e(t))), e.items && e.items.some((t) => t.$selected || t.$opened) && (e.$opened = !0), e;
|
|
110
140
|
}
|
|
111
|
-
function
|
|
141
|
+
function kt(e, t) {
|
|
112
142
|
const r = [];
|
|
113
143
|
if (e.length > 0) {
|
|
114
144
|
const n = /* @__PURE__ */ new Map(), a = t.replace(/[.*+?^${}()|[\]\\]/g, "\\$&").normalize("NFD").replace(/[\u0300-\u036f]/g, ""), s = new RegExp("\\b" + a, "i");
|
|
115
145
|
e.forEach((c) => {
|
|
116
146
|
if (c.display.length > 1) {
|
|
117
147
|
const i = c.display.normalize("NFD").replace(/[\u0300-\u036f]/g, ""), d = s.exec(i);
|
|
118
|
-
|
|
148
|
+
ae(
|
|
119
149
|
r,
|
|
120
150
|
n,
|
|
121
151
|
"/",
|
|
@@ -129,7 +159,7 @@ function _t(e, t) {
|
|
|
129
159
|
}
|
|
130
160
|
return r;
|
|
131
161
|
}
|
|
132
|
-
function
|
|
162
|
+
function ae(e, t, r, n, o, a, s) {
|
|
133
163
|
const c = n.indexOf("/", r.length), i = n.substring(0, c + 1);
|
|
134
164
|
let d = t.get(i);
|
|
135
165
|
if (!d) {
|
|
@@ -144,7 +174,7 @@ function te(e, t, r, n, o, a, s) {
|
|
|
144
174
|
$path: k
|
|
145
175
|
}, t.set(i, d), e.push(d);
|
|
146
176
|
}
|
|
147
|
-
i.length < n.length && (d.hasChildren = !0,
|
|
177
|
+
i.length < n.length && (d.hasChildren = !0, ae(
|
|
148
178
|
d.items,
|
|
149
179
|
t,
|
|
150
180
|
i,
|
|
@@ -154,18 +184,18 @@ function te(e, t, r, n, o, a, s) {
|
|
|
154
184
|
s
|
|
155
185
|
));
|
|
156
186
|
}
|
|
157
|
-
function
|
|
187
|
+
function St(e, t) {
|
|
158
188
|
return e.reduce((r, n) => (t(n) ? r.true.push(n) : r.false.push(n), r), { true: [], false: [] });
|
|
159
189
|
}
|
|
160
|
-
const
|
|
161
|
-
function
|
|
190
|
+
const ke = /(([\+\-])?\(([^\)]+)\))|(([\+\-])?\[([^\]]+)\])|(([\+\-])?\"([^\"]+)\")|(([\+\-])?\/([^\/]+)\/)|(([\+\-])?(\S+))/g, Se = 2, E = 3, be = 5, T = 6, ve = 8, ee = 9, Ce = 11, te = 12, Re = 14, re = 15;
|
|
191
|
+
function F(e) {
|
|
162
192
|
if (!e) return [];
|
|
163
|
-
const t = [], r = e.matchAll(
|
|
193
|
+
const t = [], r = e.matchAll(ke);
|
|
164
194
|
for (let n of r)
|
|
165
|
-
n[
|
|
195
|
+
n[E] ? t.push({ type: "group", value: n[E], op: n[Se] }) : n[T] ? t.push({ type: "adjacent", value: n[T], op: n[be] }) : n[ee] ? t.push({ type: "exact", value: n[ee], op: n[ve] }) : n[te] ? t.push({ type: "regex", value: n[te], op: n[Ce] }) : n[re] && t.push({ type: "token", value: n[re], op: n[Re] });
|
|
166
196
|
return t;
|
|
167
197
|
}
|
|
168
|
-
function
|
|
198
|
+
function Y(e) {
|
|
169
199
|
return e.map((t) => {
|
|
170
200
|
const r = t.op || "";
|
|
171
201
|
switch (t.type) {
|
|
@@ -182,28 +212,28 @@ function G(e) {
|
|
|
182
212
|
}
|
|
183
213
|
}).join(" ");
|
|
184
214
|
}
|
|
185
|
-
function
|
|
186
|
-
let n =
|
|
215
|
+
function bt(e, t, r) {
|
|
216
|
+
let n = F(e);
|
|
187
217
|
for (let o of t)
|
|
188
218
|
n.push({ type: "adjacent", value: o, op: r });
|
|
189
|
-
return
|
|
190
|
-
}
|
|
191
|
-
function bt(e, t) {
|
|
192
|
-
const r = N(t), n = r.findIndex((o) => o.value === e);
|
|
193
|
-
return n !== -1 ? (r.splice(n, 1), t = G(r)) : t;
|
|
219
|
+
return Y(n);
|
|
194
220
|
}
|
|
195
|
-
function vt(e) {
|
|
196
|
-
const
|
|
197
|
-
return
|
|
221
|
+
function vt(e, t) {
|
|
222
|
+
const r = F(t), n = r.findIndex((o) => o.value === e);
|
|
223
|
+
return n !== -1 ? (r.splice(n, 1), t = Y(r)) : t;
|
|
198
224
|
}
|
|
199
225
|
function Ct(e) {
|
|
200
|
-
|
|
226
|
+
const t = F(e).filter((r) => r.type !== "adjacent");
|
|
227
|
+
return Y(t);
|
|
201
228
|
}
|
|
202
|
-
function Rt(e
|
|
203
|
-
|
|
229
|
+
function Rt(e) {
|
|
230
|
+
return F(e).filter((t) => t.type === "adjacent").map((t) => t.value);
|
|
231
|
+
}
|
|
232
|
+
function Pt(e, t, r) {
|
|
233
|
+
const n = new Intl.RelativeTimeFormat(e, { numeric: "auto" }), { offset: o, unit: a, isFuture: s } = Pe(t, r);
|
|
204
234
|
return n.format(o * (s ? 1 : -1), a);
|
|
205
235
|
}
|
|
206
|
-
function
|
|
236
|
+
function Pe(e, t) {
|
|
207
237
|
const r = new Date(e), n = t ? new Date(t) : /* @__PURE__ */ new Date(), o = Math.abs(n.getTime() - r.getTime());
|
|
208
238
|
return {
|
|
209
239
|
offset: Math.floor(o / (1e3 * 60 * 60 * 24)),
|
|
@@ -211,17 +241,17 @@ function ke(e, t) {
|
|
|
211
241
|
isFuture: r > n
|
|
212
242
|
};
|
|
213
243
|
}
|
|
214
|
-
function
|
|
244
|
+
function yt(e) {
|
|
215
245
|
const t = e.target;
|
|
216
246
|
return t && t.nodeName !== "INPUT" && t.nodeName !== "TEXTAREA";
|
|
217
247
|
}
|
|
218
|
-
function
|
|
248
|
+
function xt(e) {
|
|
219
249
|
if (e === void 0) return;
|
|
220
|
-
const { q: t, f: r, p: n, s: o, t: a, n: s, b: c } =
|
|
250
|
+
const { q: t, f: r, p: n, s: o, t: a, n: s, b: c } = L(e), [i] = e.split("?");
|
|
221
251
|
return {
|
|
222
252
|
path: i,
|
|
223
253
|
text: t,
|
|
224
|
-
filters: r ?
|
|
254
|
+
filters: r ? se(r) : void 0,
|
|
225
255
|
page: n ? parseInt(n, 10) : void 0,
|
|
226
256
|
sort: o,
|
|
227
257
|
tab: a,
|
|
@@ -229,19 +259,19 @@ function yt(e) {
|
|
|
229
259
|
basket: c
|
|
230
260
|
};
|
|
231
261
|
}
|
|
232
|
-
function
|
|
262
|
+
function Lt(e) {
|
|
233
263
|
if (!e) return "";
|
|
234
264
|
const { text: t, filters: r, page: n, sort: o, tab: a, name: s, basket: c } = e, i = {};
|
|
235
265
|
t && (i.q = t), r && (i.f = JSON.stringify(r)), n && (i.p = n.toString()), o && (i.s = o), a && (i.t = a), s && (i.n = s), c && (i.b = c);
|
|
236
266
|
const d = new URLSearchParams(i).toString();
|
|
237
267
|
return d || "";
|
|
238
268
|
}
|
|
239
|
-
function
|
|
269
|
+
function $t(e) {
|
|
240
270
|
if (e === void 0) return [];
|
|
241
|
-
const { f: t } =
|
|
242
|
-
return
|
|
271
|
+
const { f: t } = L(e);
|
|
272
|
+
return se(t);
|
|
243
273
|
}
|
|
244
|
-
function
|
|
274
|
+
function se(e) {
|
|
245
275
|
const t = decodeURIComponent(e);
|
|
246
276
|
try {
|
|
247
277
|
return JSON.parse(t ?? "[]");
|
|
@@ -249,26 +279,26 @@ function re(e) {
|
|
|
249
279
|
return console.error(`Error parsing filters from URI: ${e}`), [];
|
|
250
280
|
}
|
|
251
281
|
}
|
|
252
|
-
function
|
|
282
|
+
function L(e) {
|
|
253
283
|
const t = e.split("?")[1];
|
|
254
284
|
if (t === void 0) return {};
|
|
255
285
|
const r = new URLSearchParams(t);
|
|
256
286
|
return Object.fromEntries(r);
|
|
257
287
|
}
|
|
258
|
-
function
|
|
259
|
-
const { q: t = "" } =
|
|
288
|
+
function Ut(e) {
|
|
289
|
+
const { q: t = "" } = L(e);
|
|
260
290
|
return t;
|
|
261
291
|
}
|
|
262
|
-
function
|
|
263
|
-
const { id: t } =
|
|
292
|
+
function Ot(e) {
|
|
293
|
+
const { id: t } = L(e);
|
|
264
294
|
return decodeURIComponent(t);
|
|
265
295
|
}
|
|
266
|
-
function
|
|
267
|
-
const { p: t = "0" } =
|
|
296
|
+
function At(e) {
|
|
297
|
+
const { p: t = "0" } = L(e);
|
|
268
298
|
return parseInt(t, 10);
|
|
269
299
|
}
|
|
270
300
|
function Dt(e) {
|
|
271
|
-
const { t } =
|
|
301
|
+
const { t } = L(e);
|
|
272
302
|
return t;
|
|
273
303
|
}
|
|
274
304
|
function It(e, t) {
|
|
@@ -282,21 +312,21 @@ function It(e, t) {
|
|
|
282
312
|
o++;
|
|
283
313
|
e[o] === "]" && (r = o + 1);
|
|
284
314
|
}
|
|
285
|
-
const a =
|
|
315
|
+
const a = j(e, r, !1);
|
|
286
316
|
if (!a)
|
|
287
317
|
return e;
|
|
288
318
|
const s = t.charCodeAt(0), c = t.charCodeAt(1);
|
|
289
319
|
let i = a;
|
|
290
320
|
for (; i; )
|
|
291
321
|
if (s === i.lang1 && c === i.lang2) {
|
|
292
|
-
const k =
|
|
322
|
+
const k = j(e, i.end + 4, !0);
|
|
293
323
|
return e.substring(k.start, k.end);
|
|
294
324
|
} else
|
|
295
|
-
i =
|
|
325
|
+
i = j(e, i.end + 4, !1);
|
|
296
326
|
const d = e.substring(a.start, a.end);
|
|
297
327
|
return d || e;
|
|
298
328
|
}
|
|
299
|
-
function
|
|
329
|
+
function j(e, t, r) {
|
|
300
330
|
for (let n = t, o = e.length - 3; n < o; n++)
|
|
301
331
|
if (e[n] === "[" && e[n + 3] === "]")
|
|
302
332
|
return {
|
|
@@ -313,11 +343,11 @@ function B(e, t, r) {
|
|
|
313
343
|
lang2: -1
|
|
314
344
|
};
|
|
315
345
|
}
|
|
316
|
-
function
|
|
346
|
+
function Nt(e, t) {
|
|
317
347
|
const { useLocale: r, useLocaleAsPrefix: n, indexFile: o, path: a, folder: s } = t, c = r ? `${e}/` : null, i = n ? `${e}.${o}` : o ?? "";
|
|
318
348
|
return [a, s, `${c || ""}${i}`].filter((d) => d !== void 0).join("/");
|
|
319
349
|
}
|
|
320
|
-
function
|
|
350
|
+
function D(e) {
|
|
321
351
|
const t = new CustomEvent("notification", {
|
|
322
352
|
bubbles: !0,
|
|
323
353
|
cancelable: !1,
|
|
@@ -325,48 +355,48 @@ function O(e) {
|
|
|
325
355
|
});
|
|
326
356
|
dispatchEvent(t);
|
|
327
357
|
}
|
|
328
|
-
const
|
|
358
|
+
const qt = {
|
|
329
359
|
success: (e, t) => {
|
|
330
|
-
|
|
360
|
+
D({
|
|
331
361
|
type: "success",
|
|
332
362
|
message: e,
|
|
333
363
|
options: t
|
|
334
364
|
});
|
|
335
365
|
},
|
|
336
366
|
info: (e, t) => {
|
|
337
|
-
|
|
367
|
+
D({
|
|
338
368
|
type: "info",
|
|
339
369
|
message: e,
|
|
340
370
|
options: t
|
|
341
371
|
});
|
|
342
372
|
},
|
|
343
373
|
warning: (e, t) => {
|
|
344
|
-
|
|
374
|
+
D({
|
|
345
375
|
type: "warning",
|
|
346
376
|
message: e,
|
|
347
377
|
options: t
|
|
348
378
|
});
|
|
349
379
|
},
|
|
350
380
|
error: (e, t) => {
|
|
351
|
-
|
|
381
|
+
D({
|
|
352
382
|
type: "error",
|
|
353
383
|
message: e,
|
|
354
384
|
options: t
|
|
355
385
|
});
|
|
356
386
|
}
|
|
357
387
|
};
|
|
358
|
-
var
|
|
359
|
-
let
|
|
388
|
+
var ie = /* @__PURE__ */ ((e) => (e[e.DEBUG = 0] = "DEBUG", e[e.INFO = 1] = "INFO", e[e.WARN = 2] = "WARN", e[e.ERROR = 3] = "ERROR", e[e.NONE = 4] = "NONE", e))(ie || {});
|
|
389
|
+
let I = {
|
|
360
390
|
level: 1,
|
|
361
391
|
enableConsoleOutput: !0
|
|
362
392
|
};
|
|
363
|
-
function
|
|
364
|
-
|
|
393
|
+
function Ft(e) {
|
|
394
|
+
I = { ...I, ...e };
|
|
365
395
|
}
|
|
366
|
-
function
|
|
367
|
-
if (e <
|
|
368
|
-
const o = `${`[${
|
|
369
|
-
if (
|
|
396
|
+
function B(e, t, r) {
|
|
397
|
+
if (e < I.level) return;
|
|
398
|
+
const o = `${`[${ie[e]}]`} ${t}`;
|
|
399
|
+
if (I.enableConsoleOutput)
|
|
370
400
|
switch (e) {
|
|
371
401
|
case 0:
|
|
372
402
|
console.debug(o, r || "");
|
|
@@ -382,48 +412,48 @@ function q(e, t, r) {
|
|
|
382
412
|
break;
|
|
383
413
|
}
|
|
384
414
|
}
|
|
385
|
-
function
|
|
386
|
-
|
|
415
|
+
function U(e, t) {
|
|
416
|
+
B(0, e, t);
|
|
387
417
|
}
|
|
388
|
-
function
|
|
389
|
-
|
|
418
|
+
function x(e, t) {
|
|
419
|
+
B(1, e, t);
|
|
390
420
|
}
|
|
391
|
-
function
|
|
392
|
-
|
|
421
|
+
function N(e, t) {
|
|
422
|
+
B(2, e, t);
|
|
393
423
|
}
|
|
394
424
|
function f(e, t) {
|
|
395
|
-
|
|
425
|
+
B(3, e, t);
|
|
396
426
|
}
|
|
397
|
-
function
|
|
398
|
-
const t =
|
|
427
|
+
function O(e) {
|
|
428
|
+
const t = Z(), r = new Headers(e);
|
|
399
429
|
r.append("Sinequa-Force-Camel-Case", "true"), r.append("accept", "application/json"), t && r.append("Sinequa-csrf-token", t);
|
|
400
430
|
const { userOverride: n, userOverrideActive: o, bearerToken: a } = l;
|
|
401
431
|
return a && r.append("Authorization", `Bearer ${a}`), n && o && (r.append("sinequa-override-user", n.username), r.append("sinequa-override-domain", n.domain)), r;
|
|
402
432
|
}
|
|
403
|
-
class
|
|
433
|
+
class P extends Error {
|
|
404
434
|
status;
|
|
405
435
|
constructor(t, r) {
|
|
406
436
|
super(t), this.name = "ApiError", this.status = r;
|
|
407
437
|
}
|
|
408
438
|
}
|
|
409
|
-
class
|
|
439
|
+
class ne extends P {
|
|
410
440
|
constructor(t = "Server error") {
|
|
411
441
|
super(t, 500), this.name = "ServerError";
|
|
412
442
|
}
|
|
413
443
|
}
|
|
414
|
-
class
|
|
444
|
+
class ye extends P {
|
|
415
445
|
constructor(t = "Request timed out") {
|
|
416
446
|
super(t, 408), this.name = "TimeoutError";
|
|
417
447
|
}
|
|
418
448
|
}
|
|
419
|
-
class
|
|
449
|
+
class G extends P {
|
|
420
450
|
constructor(t = "Unauthorized access") {
|
|
421
451
|
super(t, 401), this.name = "UnauthorizedError";
|
|
422
452
|
}
|
|
423
453
|
}
|
|
424
|
-
async function
|
|
454
|
+
async function y(e, t = "json") {
|
|
425
455
|
const r = e.headers.get("sinequa-jwt-refresh");
|
|
426
|
-
if (r !== null &&
|
|
456
|
+
if (r !== null && q(r), e.status === 200)
|
|
427
457
|
switch (t) {
|
|
428
458
|
case "arraybuffer":
|
|
429
459
|
return await e.arrayBuffer();
|
|
@@ -441,27 +471,27 @@ async function P(e, t = "json") {
|
|
|
441
471
|
n = await e.clone().json();
|
|
442
472
|
} catch {
|
|
443
473
|
}
|
|
444
|
-
throw
|
|
474
|
+
throw N("Unauthorized access attempt with user override", {
|
|
445
475
|
endpoint: e.url,
|
|
446
476
|
error: n
|
|
447
|
-
}), new
|
|
477
|
+
}), new G(
|
|
448
478
|
n.errorMessage ?? n.message ?? "Unauthorized... User override failed."
|
|
449
479
|
);
|
|
450
480
|
}
|
|
451
|
-
return await
|
|
481
|
+
return await Q(e, 401);
|
|
452
482
|
}
|
|
453
|
-
return e.status === 500 ? (f("Server error occurred", { endpoint: e.url }), await
|
|
483
|
+
return e.status === 500 ? (f("Server error occurred", { endpoint: e.url }), await Q(e, 500)) : (N(`Unexpected response status: ${e.status}`, {
|
|
454
484
|
endpoint: e.url
|
|
455
|
-
}), await
|
|
485
|
+
}), await Q(e, e.status));
|
|
456
486
|
}
|
|
457
|
-
async function
|
|
487
|
+
async function Q(e, t) {
|
|
458
488
|
try {
|
|
459
489
|
const { done: r, value: n } = await e.body?.getReader().read() || {
|
|
460
490
|
done: !0,
|
|
461
491
|
value: void 0
|
|
462
492
|
};
|
|
463
493
|
if (r || !n)
|
|
464
|
-
throw t === 401 ? new
|
|
494
|
+
throw t === 401 ? new G() : t === 500 ? new ne() : new P(`Request failed with status ${t}`, t);
|
|
465
495
|
const o = JSON.parse(new TextDecoder().decode(n));
|
|
466
496
|
throw new Error(
|
|
467
497
|
o.errorMessage || o.message || `Request failed with status ${t}`,
|
|
@@ -473,31 +503,31 @@ async function M(e, t) {
|
|
|
473
503
|
}
|
|
474
504
|
);
|
|
475
505
|
} catch (r) {
|
|
476
|
-
throw r instanceof
|
|
506
|
+
throw r instanceof P ? r : t === 401 ? new G(r.message) : t === 500 ? new ne(r.message) : new P(
|
|
477
507
|
r.message ?? `Request failed with status ${t}`,
|
|
478
508
|
t
|
|
479
509
|
);
|
|
480
510
|
}
|
|
481
511
|
}
|
|
482
|
-
async function
|
|
483
|
-
const n =
|
|
484
|
-
|
|
512
|
+
async function xe(e, t, r) {
|
|
513
|
+
const n = O(r?.headers), { backendUrl: o } = l, a = t ? `?${new URLSearchParams(t)}` : "", s = o ? `${o}/${e}${a}` : `${e}${a}`;
|
|
514
|
+
U(`Making DELETE request to: ${s}`);
|
|
485
515
|
try {
|
|
486
516
|
const c = await fetch(s, {
|
|
487
517
|
method: "DELETE",
|
|
488
518
|
credentials: "include",
|
|
489
519
|
headers: n
|
|
490
520
|
});
|
|
491
|
-
return
|
|
521
|
+
return y(c, r?.responseType);
|
|
492
522
|
} catch (c) {
|
|
493
523
|
throw f("Error making DELETE request:", c), c;
|
|
494
524
|
}
|
|
495
525
|
}
|
|
496
526
|
async function _(e, t, r) {
|
|
497
|
-
const n =
|
|
527
|
+
const n = O(r?.headers), { backendUrl: o } = l, a = t ? `?${new URLSearchParams(t)}` : "";
|
|
498
528
|
e.startsWith("plugin") && (e = `api/v1/${e}`);
|
|
499
529
|
const s = o ? `${o}/${e}${a}` : `${e}${a}`;
|
|
500
|
-
|
|
530
|
+
U(`Making GET request to: ${s}`);
|
|
501
531
|
try {
|
|
502
532
|
const c = await fetch(s, {
|
|
503
533
|
method: "GET",
|
|
@@ -505,13 +535,13 @@ async function _(e, t, r) {
|
|
|
505
535
|
headers: n,
|
|
506
536
|
signal: r?.signal
|
|
507
537
|
});
|
|
508
|
-
return
|
|
538
|
+
return y(c, r?.responseType);
|
|
509
539
|
} catch (c) {
|
|
510
540
|
throw f("Error making GET request:", c), c;
|
|
511
541
|
}
|
|
512
542
|
}
|
|
513
|
-
async function
|
|
514
|
-
const n =
|
|
543
|
+
async function Le(e, t, r) {
|
|
544
|
+
const n = O(r?.headers);
|
|
515
545
|
n.append("content-type", "application/json");
|
|
516
546
|
const { app: o, backendUrl: a } = l, s = {
|
|
517
547
|
app: o,
|
|
@@ -520,7 +550,7 @@ async function ve(e, t, r) {
|
|
|
520
550
|
noUserOverride: !0,
|
|
521
551
|
noAutoAuthentication: !0
|
|
522
552
|
}, c = a ? `${a}/${e}` : `${e}`;
|
|
523
|
-
|
|
553
|
+
U(`Making PATCH request to: ${c}`);
|
|
524
554
|
try {
|
|
525
555
|
const i = await fetch(c, {
|
|
526
556
|
method: "PATCH",
|
|
@@ -528,13 +558,13 @@ async function ve(e, t, r) {
|
|
|
528
558
|
credentials: "include",
|
|
529
559
|
body: JSON.stringify(s)
|
|
530
560
|
});
|
|
531
|
-
return
|
|
561
|
+
return y(i, r?.responseType);
|
|
532
562
|
} catch (i) {
|
|
533
563
|
throw f("Error making PATCH request:", i), i;
|
|
534
564
|
}
|
|
535
565
|
}
|
|
536
566
|
async function u(e, t, r) {
|
|
537
|
-
const n =
|
|
567
|
+
const n = O(r?.headers), { app: o, backendUrl: a } = l;
|
|
538
568
|
n.has("Content-Type") || n.set("Content-Type", "application/json");
|
|
539
569
|
const s = {
|
|
540
570
|
app: o,
|
|
@@ -545,7 +575,7 @@ async function u(e, t, r) {
|
|
|
545
575
|
};
|
|
546
576
|
e.startsWith("plugin") && (e = `api/v1/${e}`);
|
|
547
577
|
const c = a ? `${a}/${e}` : `${e}`;
|
|
548
|
-
|
|
578
|
+
U(`Making POST request to: ${c}`);
|
|
549
579
|
try {
|
|
550
580
|
const i = await fetch(c, {
|
|
551
581
|
method: "POST",
|
|
@@ -554,20 +584,20 @@ async function u(e, t, r) {
|
|
|
554
584
|
body: JSON.stringify(s),
|
|
555
585
|
signal: r?.signal
|
|
556
586
|
});
|
|
557
|
-
return
|
|
587
|
+
return y(i, r?.responseType);
|
|
558
588
|
} catch (i) {
|
|
559
589
|
throw f("Error making POST request:", i), i;
|
|
560
590
|
}
|
|
561
591
|
}
|
|
562
|
-
async function
|
|
563
|
-
const n =
|
|
592
|
+
async function Bt(e, t, r) {
|
|
593
|
+
const n = O(r?.headers), { app: o, backendUrl: a } = l, s = {
|
|
564
594
|
app: o,
|
|
565
595
|
...t,
|
|
566
596
|
locale: t.locale || navigator.language,
|
|
567
597
|
noUserOverride: !0,
|
|
568
598
|
noAutoAuthentication: !0
|
|
569
599
|
}, c = `${a}/${e}`;
|
|
570
|
-
|
|
600
|
+
U(`Making PUT request to: ${c}`);
|
|
571
601
|
try {
|
|
572
602
|
const i = await fetch(c, {
|
|
573
603
|
method: "PUT",
|
|
@@ -575,45 +605,45 @@ async function Ft(e, t, r) {
|
|
|
575
605
|
credentials: "include",
|
|
576
606
|
body: JSON.stringify(s)
|
|
577
607
|
});
|
|
578
|
-
return
|
|
608
|
+
return y(i, r?.responseType);
|
|
579
609
|
} catch (i) {
|
|
580
610
|
throw f("Error making PUT request:", i), i;
|
|
581
611
|
}
|
|
582
612
|
}
|
|
583
|
-
function
|
|
613
|
+
function v(e) {
|
|
584
614
|
const t = new AbortController(), { signal: r } = t;
|
|
585
615
|
return e && setTimeout(() => {
|
|
586
|
-
r.aborted || t.abort(new
|
|
616
|
+
r.aborted || t.abort(new ye(`Request timed out after ${e}ms`));
|
|
587
617
|
}, e), { controller: t, signal: r };
|
|
588
618
|
}
|
|
589
|
-
function
|
|
619
|
+
function ce(e) {
|
|
590
620
|
if (!e) return;
|
|
591
621
|
const t = new Date(e);
|
|
592
622
|
return Number.isNaN(t.getTime()) ? void 0 : t;
|
|
593
623
|
}
|
|
594
|
-
function
|
|
595
|
-
const t =
|
|
624
|
+
function Mt(e) {
|
|
625
|
+
const t = ce(e);
|
|
596
626
|
return !!t && t.getTime() <= Date.now();
|
|
597
627
|
}
|
|
598
|
-
function
|
|
599
|
-
const r =
|
|
628
|
+
function jt(e, t = 7) {
|
|
629
|
+
const r = ce(e);
|
|
600
630
|
if (!r) return !1;
|
|
601
631
|
const n = Date.now(), o = n + t * 24 * 60 * 60 * 1e3, a = r.getTime();
|
|
602
632
|
return a > n && a <= o;
|
|
603
633
|
}
|
|
604
|
-
async function
|
|
634
|
+
async function Qt(e, t = 0, r = 1e3) {
|
|
605
635
|
let n;
|
|
606
636
|
for (let o = 0; o <= t; o++)
|
|
607
637
|
try {
|
|
608
638
|
return await e();
|
|
609
639
|
} catch (a) {
|
|
610
|
-
if (n = a, a instanceof
|
|
640
|
+
if (n = a, a instanceof P && a.status >= 400 && a.status < 500 && a.status !== 429 || a instanceof DOMException && a.name === "AbortError")
|
|
611
641
|
throw a;
|
|
612
|
-
o < t && (
|
|
642
|
+
o < t && (N(`Retrying request (${o + 1}/${t})`, { error: a }), await new Promise((s) => setTimeout(s, r)));
|
|
613
643
|
}
|
|
614
644
|
throw n;
|
|
615
645
|
}
|
|
616
|
-
function
|
|
646
|
+
function Vt(e, t, r) {
|
|
617
647
|
if (!e || !t) return;
|
|
618
648
|
if (r) {
|
|
619
649
|
const a = Object.keys(t.queries).find((i) => i === r?.toLowerCase());
|
|
@@ -625,10 +655,10 @@ function Qt(e, t, r) {
|
|
|
625
655
|
const n = t.indexes?._?.columns, o = Object.entries(n).find((a) => a[1].aliases?.includes(e));
|
|
626
656
|
if (o) return o[0];
|
|
627
657
|
}
|
|
628
|
-
var
|
|
629
|
-
const
|
|
630
|
-
var
|
|
631
|
-
function
|
|
658
|
+
var R = /* @__PURE__ */ ((e) => (e.None = "None", e.Search_FirstPage = "Search_FirstPage", e.Search_Text = "Search_Text", e.Search_Refine = "Search_Refine", e.Search_Select_Item = "Search_Select_Item", e.Search_Select_Custom = "Search_Select_Custom", e.Search_Select_Concept = "Search_Select_Concept", e.Search_Select_Correction = "Search_Select_Correction", e.Search_GotoPage = "Search_GotoPage", e.Search_GotoTab = "Search_GotoTab", e.Search_DisplayResult = "Search_DisplayResult", e.Search_RemoveResult = "Search_RemoveResult", e.Search_RemoveAdvanced = "Search_RemoveAdvanced", e.Search_SavedQuery = "Search_SavedQuery", e.Search_WebService = "Search_WebService", e.Search_DidYouMean_Original = "Search_DidYouMean_Original", e.Search_DidYouMean_Correction = "Search_DidYouMean_Correction", e.Search_ExportCSV = "Search_ExportCSV", e.Search_SavedQuery_ExportCSV = "Search_SavedQuery_ExportCSV", e.Search_Selection_ExportCSV = "Search_Selection_ExportCSV", e.Search_AlertQuery = "Search_AlertQuery", e.Search_Select_AnalyticsItem = "Search_Select_AnalyticsItem", e.Search_Sort = "Search_Sort", e.Search_Exit_Logout = "Search_Exit_Logout", e.Search_Timeline_Usage = "Search_Timeline_Usage", e.Search_AutoComplete = "Search_Autocomplete", e.Search_Login_Success = "Login_Success_Form", e.Search_QueryIntent_Detected = "Search_QueryIntent_Detected", e.SavedQuery_Add = "SavedQuery_Add", e.SavedQuery_Delete = "SavedQuery_Delete", e.SavedQuery_DeleteAll = "SavedQuery_DeleteAll", e.SavedQuery_Rename = "SavedQuery_Rename", e.Alert_Edit = "Alert_Edit", e.Alert_Delete = "Alert_Delete", e.Alert_DeleteAll = "Alert_DeleteAll", e.Link_Display = "Link_Display", e.Link_Click = "Link_Click", e.Basket_Add = "Basket_Add", e.Basket_Delete = "Basket_Delete", e.Basket_DeleteAll = "Basket_DeleteAll", e.Basket_Rename = "Basket_Rename", e.Basket_AddDoc = "Basket_AddDoc", e.Basket_RemoveDoc = "Basket_RemoveDoc", e.Basket_Open = "Basket_Open", e.Basket_ExportCSV = "Basket_ExportCSV", e.Label_Add = "Label_Add", e.Label_Delete = "Label_Delete", e.Label_Rename = "Label_Rename", e.Label_Open = "Label_Open", e.Label_AddDoc = "Label_AddDoc", e.Label_RemoveDoc = "Label_RemoveDoc", e.Label_ExportCSV = "Label_ExportCSV", e.Label_Menu_ExportCSV = "Label_Menu_ExportCSV", e.Rating_Set = "Rating_Set", e.Rating_Delete = "Rating_Delete", e.Doc_Preview = "Doc_Preview", e.Doc_CacheHtml = "Doc_CacheHtml", e.Doc_CachePdf = "Doc_CachePdf", e.Doc_CacheOriginal = "Doc_CacheOriginal", e.Doc_Url1 = "Doc_Url1", e.Doc_Url2 = "Doc_Url2", e.Preview_Close = "Preview_Close", e.Click_ResultLink = "Click_ResultLink", e.Click_ResultLink1 = "Click_ResultLink1", e.Click_ResultLink2 = "Click_ResultLink2", e.Click_ResultLink3 = "Click_ResultLink3", e.Click_ResultLink4 = "Click_ResultLink4", e.Click_ResultLink5 = "Click_ResultLink5", e.Click_ResultLink6 = "Click_ResultLink6", e.Click_ResultLink7 = "Click_ResultLink7", e.Click_ResultLink8 = "Click_ResultLink8", e.Click_ResultLink9 = "Click_ResultLink9", e.Click_ResultLink10 = "Click_ResultLink10", e.Click_PreviewLink1 = "Click_PreviewLink1", e.Click_PreviewLink2 = "Click_PreviewLink2", e.Click_PreviewLink3 = "Click_PreviewLink3", e.Click_PreviewLink4 = "Click_PreviewLink4", e.Click_PreviewLink5 = "Click_PreviewLink5", e.Click_PreviewLink6 = "Click_PreviewLink6", e.Click_PreviewLink7 = "Click_PreviewLink7", e.Click_PreviewLink8 = "Click_PreviewLink8", e.Click_PreviewLink9 = "Click_PreviewLink9", e.Click_PreviewLink10 = "Click_PreviewLink10", e.RFM_ClickSet = "RFM_ClickSet", e.RFM_ClickReset = "RFM_ClickReset", e.RFM_Like = "RFM_Like", e.RFM_LikeReset = "RFM_LikeReset", e.RFM_Dislike = "RFM_Dislike", e.RFM_Important = "RFM_Important", e.RFM_ImportantReset = "RFM_ImportantReset", e.RFM_Ban = "RFM_Ban", e.Navigation_Exit = "Navigation_Exit", e.Navigation_Return = "Navigation_Return", e.Navigation_Route = "Navigation_Route", e.Answer_Display = "Answer_Display", e.Answer_Click = "Answer_Click", e.Answer_Result = "Answer_Result", e.Answer_Liked = "Answer_Liked", e.Answer_Disliked = "Answer_Disliked", e.Answer_Liked_Cancelled = "Answer_Liked_Cancelled", e.Answer_Disliked_Cancelled = "Answer_Disliked_Cancelled", e.TopPassages_Display = "TopPassages_Display", e.TopPassages_Click = "TopPassages_Click", e.UserSettings_Reset = "UserSettings_Reset", e.Change_Password_Failed = "change.password.failed", e.Change_Password_Success_Form = "change.password.success.form", e.Forgot_Password_Request = "forgot.password.request", e.Login_Denied = "login.denied", e.Login_Success_Form = "login.success.form", e.Send_Reset_Password_Link = "send.reset.password.link", e.Xrest_ChangePassword = "xrest.changepassword", e))(R || {}), h = /* @__PURE__ */ ((e) => (e[e.none = 0] = "none", e[e.bool = 1] = "bool", e[e.date = 2] = "date", e[e.dateTime = 3] = "dateTime", e[e.time = 4] = "time", e[e.unsigned = 5] = "unsigned", e[e.integer = 6] = "integer", e[e.float = 7] = "float", e[e.double = 8] = "double", e[e.dates = 9] = "dates", e[e.dateTimes = 10] = "dateTimes", e[e.times = 11] = "times", e[e.varchar = 12] = "varchar", e[e.binary = 13] = "binary", e[e.string = 14] = "string", e[e.csv = 15] = "csv", e))(h || {}), w = /* @__PURE__ */ ((e) => (e[e.none = 0] = "none", e[e.a = 2053] = "a", e[e.c = 4] = "c", e[e.d = 8] = "d", e[e.e = 2068] = "e", e[e.i = 256] = "i", e[e.l = 2052] = "l", e[e.n = 8192] = "n", e[e.t = 524292] = "t", e[e.x = 8388608] = "x", e[e.z = 33554432] = "z", e[e.f_ordinal = 8192] = "f_ordinal", e[e.f_multidates = 8192] = "f_multidates", e[e.f_varchar = 33554432] = "f_varchar", e[e.f_binary = 33562624] = "f_binary", e[e.f_string = 33562888] = "f_string", e[e.f_csv = 42477853] = "f_csv", e[e.f_overridable = 33554696] = "f_overridable", e))(w || {});
|
|
659
|
+
const zt = "1.0";
|
|
660
|
+
var $e = /* @__PURE__ */ ((e) => (e[e.Original = 0] = "Original", e[e.Corrected = 1] = "Corrected", e))($e || {}), Ue = /* @__PURE__ */ ((e) => (e[e.none = 0] = "none", e[e.positiveRate = 1] = "positiveRate", e[e.mainlyPosRate = 2] = "mainlyPosRate", e[e.unrate = 4] = "unrate", e[e.mainlyNegRate = 8] = "mainlyNegRate", e[e.negativeRate = 16] = "negativeRate", e[e.all = 31] = "all", e[e.positiveOnly = 7] = "positiveOnly", e[e.negativeOnly = 28] = "negativeOnly", e[e.personalAll = 21] = "personalAll", e[e.personalPosOnly = 5] = "personalPosOnly", e[e.personalNegOnly = 20] = "personalNegOnly", e))(Ue || {});
|
|
661
|
+
function Oe(e) {
|
|
632
662
|
if (!e)
|
|
633
663
|
return h.none;
|
|
634
664
|
switch (e.toLocaleLowerCase()) {
|
|
@@ -667,7 +697,7 @@ function Pe(e) {
|
|
|
667
697
|
return h.none;
|
|
668
698
|
}
|
|
669
699
|
}
|
|
670
|
-
function
|
|
700
|
+
function Ae(e) {
|
|
671
701
|
switch (e) {
|
|
672
702
|
case "a":
|
|
673
703
|
return w.a;
|
|
@@ -693,15 +723,15 @@ function ye(e) {
|
|
|
693
723
|
return w.none;
|
|
694
724
|
}
|
|
695
725
|
}
|
|
696
|
-
function
|
|
726
|
+
function De(e) {
|
|
697
727
|
let t = w.none;
|
|
698
728
|
if (e)
|
|
699
729
|
for (const r of e)
|
|
700
|
-
t |=
|
|
730
|
+
t |= Ae(r);
|
|
701
731
|
return t;
|
|
702
732
|
}
|
|
703
733
|
function p(e, t, r, n) {
|
|
704
|
-
const o =
|
|
734
|
+
const o = Oe(t), a = De(r || "");
|
|
705
735
|
return {
|
|
706
736
|
name: e,
|
|
707
737
|
type: t,
|
|
@@ -730,10 +760,10 @@ const Gt = {
|
|
|
730
760
|
accesslists: p("accesslists", "varchar", void 0, ["accessLists"])
|
|
731
761
|
// json
|
|
732
762
|
};
|
|
733
|
-
function
|
|
763
|
+
function le(e) {
|
|
734
764
|
return e.filter((t) => !!t);
|
|
735
765
|
}
|
|
736
|
-
const
|
|
766
|
+
const Ht = {
|
|
737
767
|
// ── Scalar (leaf) operators ───────────────────────────────────────────────
|
|
738
768
|
/** `field = value`. */
|
|
739
769
|
eq: (e, t) => ({
|
|
@@ -815,23 +845,23 @@ const zt = {
|
|
|
815
845
|
* Combine filters with logical AND. Falsy operands are ignored; with a single
|
|
816
846
|
* effective operand the operand is returned as-is, with none `undefined`.
|
|
817
847
|
*/
|
|
818
|
-
and: (...e) =>
|
|
848
|
+
and: (...e) => oe("and", e),
|
|
819
849
|
/** Combine filters with logical OR. Same collapsing rules as {@link filter.and}. */
|
|
820
|
-
or: (...e) =>
|
|
850
|
+
or: (...e) => oe("or", e),
|
|
821
851
|
/**
|
|
822
852
|
* Negate filters. Falsy operands are ignored; returns `undefined` if nothing
|
|
823
853
|
* remains. A `not` node is always kept (even with a single operand).
|
|
824
854
|
*/
|
|
825
855
|
not: (...e) => {
|
|
826
|
-
const t =
|
|
856
|
+
const t = le(e);
|
|
827
857
|
return t.length ? { operator: "not", filters: t } : void 0;
|
|
828
858
|
}
|
|
829
859
|
};
|
|
830
|
-
function
|
|
831
|
-
const r =
|
|
860
|
+
function oe(e, t) {
|
|
861
|
+
const r = le(t);
|
|
832
862
|
return r.length === 0 ? void 0 : r.length === 1 ? r[0] : { operator: e, filters: r };
|
|
833
863
|
}
|
|
834
|
-
function
|
|
864
|
+
function Jt(e, t) {
|
|
835
865
|
let r = e[t];
|
|
836
866
|
return r === void 0 ? [] : (typeof r == "string" && (r = String(r).split(",")), Array.isArray(r) ? r.map((n) => {
|
|
837
867
|
if (typeof n == "string") return n.trim();
|
|
@@ -839,7 +869,7 @@ function Ht(e, t) {
|
|
|
839
869
|
return n.display.trim();
|
|
840
870
|
}).filter((n) => n !== void 0) : [String(r).trim()]);
|
|
841
871
|
}
|
|
842
|
-
function
|
|
872
|
+
function Wt(e, t) {
|
|
843
873
|
let r = e[t];
|
|
844
874
|
if (r === void 0) return [];
|
|
845
875
|
if (typeof r == "string" && (r = String(r).split(",")), Array.isArray(r))
|
|
@@ -856,35 +886,35 @@ function Jt(e, t) {
|
|
|
856
886
|
const n = String(r).trim();
|
|
857
887
|
return [{ display: n, value: n }];
|
|
858
888
|
}
|
|
859
|
-
function
|
|
889
|
+
function M(e) {
|
|
860
890
|
return e !== null && typeof e == "object";
|
|
861
891
|
}
|
|
862
|
-
function
|
|
863
|
-
return
|
|
892
|
+
function Ie(e) {
|
|
893
|
+
return M(e) && Object.prototype.toString.call(e) === "[object ArrayBuffer]";
|
|
864
894
|
}
|
|
865
|
-
function
|
|
866
|
-
return
|
|
895
|
+
function Ne(e) {
|
|
896
|
+
return M(e) && Object.prototype.toString.call(e) === "[object Blob]";
|
|
867
897
|
}
|
|
868
|
-
function
|
|
898
|
+
function qe(e) {
|
|
869
899
|
return Object.prototype.toString.call(e) === "[object Date]";
|
|
870
900
|
}
|
|
871
|
-
function
|
|
901
|
+
function Fe(e) {
|
|
872
902
|
return typeof e == "string";
|
|
873
903
|
}
|
|
874
|
-
function
|
|
875
|
-
return (
|
|
904
|
+
function Xt(e) {
|
|
905
|
+
return (M(e) || Array.isArray(e)) && !Ie(e) && !Ne(e) && !Fe(e);
|
|
876
906
|
}
|
|
877
|
-
function
|
|
907
|
+
function Be(e) {
|
|
878
908
|
return e ? (e.getHours() * 60 * 60 + e.getMinutes() * 60 + e.getSeconds()) * 1e3 + e.getMilliseconds() : 0;
|
|
879
909
|
}
|
|
880
|
-
function
|
|
910
|
+
function Me(e = !0) {
|
|
881
911
|
let t = Date.now();
|
|
882
912
|
return (e ? "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx" : "xxxxxxxxxxxx4xxxyxxxxxxxxxxxxxxx").replace(/[xy]/g, (n) => {
|
|
883
913
|
const o = (t + Math.random() * 16) % 16 | 0;
|
|
884
914
|
return t = Math.floor(t / 16), (n === "x" ? o : o & 3 | 8).toString(16);
|
|
885
915
|
});
|
|
886
916
|
}
|
|
887
|
-
function
|
|
917
|
+
function Yt(e) {
|
|
888
918
|
if (!e)
|
|
889
919
|
return "``";
|
|
890
920
|
if (e = String(e), e.search(/[\\`]/) === -1)
|
|
@@ -896,36 +926,36 @@ function Xt(e) {
|
|
|
896
926
|
}
|
|
897
927
|
return t.push("`"), t.join("");
|
|
898
928
|
}
|
|
899
|
-
function
|
|
929
|
+
function Kt(e) {
|
|
900
930
|
if (typeof crypto < "u" && crypto.subtle && typeof crypto.subtle.digest == "function")
|
|
901
931
|
try {
|
|
902
932
|
return crypto.subtle.digest("SHA-512", new TextEncoder().encode(e)).then(
|
|
903
933
|
(t) => Array.prototype.map.call(new Uint8Array(t), (r) => `00${r.toString(16)}`.slice(-2)).join("")
|
|
904
|
-
).catch(() => Promise.resolve(
|
|
934
|
+
).catch(() => Promise.resolve(V(e)));
|
|
905
935
|
} catch {
|
|
906
|
-
return Promise.resolve(
|
|
936
|
+
return Promise.resolve(V(e));
|
|
907
937
|
}
|
|
908
|
-
return Promise.resolve(
|
|
938
|
+
return Promise.resolve(V(e));
|
|
909
939
|
}
|
|
910
|
-
function
|
|
940
|
+
function V(e) {
|
|
911
941
|
let n = 2166136261;
|
|
912
942
|
for (let k = 0; k < e.length; k++)
|
|
913
943
|
n ^= e.charCodeAt(k), n = n * 16777619 >>> 0;
|
|
914
944
|
const o = n.toString(16).padStart(8, "0"), a = ((n ^ 2863311530) >>> 0).toString(16).padStart(8, "0"), s = ((n ^ 1431655765) >>> 0).toString(16).padStart(8, "0"), c = ((n ^ 3435973836) >>> 0).toString(16).padStart(8, "0"), i = o + a + s + c;
|
|
915
945
|
return (i + i + i + i).substring(0, 128);
|
|
916
946
|
}
|
|
917
|
-
let
|
|
918
|
-
function
|
|
919
|
-
let r =
|
|
920
|
-
r && (
|
|
947
|
+
let z, ue;
|
|
948
|
+
function A(e, t = !0) {
|
|
949
|
+
let r = je(e.$auditRecord);
|
|
950
|
+
r && (Qe(r), t && Ve(r)), e.$auditRecord = r;
|
|
921
951
|
}
|
|
922
|
-
function
|
|
952
|
+
function je(e) {
|
|
923
953
|
if (!e)
|
|
924
954
|
return;
|
|
925
955
|
let t;
|
|
926
956
|
if (Array.isArray(e))
|
|
927
957
|
t = e;
|
|
928
|
-
else if (
|
|
958
|
+
else if (M(e)) {
|
|
929
959
|
const r = e;
|
|
930
960
|
if (r.auditEvents || r.mlAuditEvents)
|
|
931
961
|
return r;
|
|
@@ -933,42 +963,42 @@ function Ae(e) {
|
|
|
933
963
|
}
|
|
934
964
|
return { auditEvents: t };
|
|
935
965
|
}
|
|
936
|
-
function
|
|
937
|
-
const t =
|
|
966
|
+
function Qe(e) {
|
|
967
|
+
const t = ze();
|
|
938
968
|
return e.auditEvents?.forEach((r) => {
|
|
939
969
|
r.detail || (r.detail = {}), r.detail.sessionid = t;
|
|
940
970
|
}), e;
|
|
941
971
|
}
|
|
942
|
-
function
|
|
972
|
+
function Ve(e) {
|
|
943
973
|
const t = typeof window < "u" ? decodeURIComponent(window.location.href) : "http://localhost";
|
|
944
974
|
return e?.auditEvents?.forEach((r) => {
|
|
945
975
|
r.detail || (r.detail = {}), r.detail.url = t;
|
|
946
976
|
}), e;
|
|
947
977
|
}
|
|
948
|
-
function
|
|
949
|
-
return (!
|
|
978
|
+
function ze() {
|
|
979
|
+
return (!z || Ge()) && (z = Me()), ue = /* @__PURE__ */ new Date(), z;
|
|
950
980
|
}
|
|
951
|
-
function
|
|
952
|
-
return (/* @__PURE__ */ new Date()).getTime() -
|
|
981
|
+
function Ge() {
|
|
982
|
+
return (/* @__PURE__ */ new Date()).getTime() - ue.getTime() > 600 * 1e3;
|
|
953
983
|
}
|
|
954
|
-
async function
|
|
984
|
+
async function He(e, t = !0) {
|
|
955
985
|
const r = {
|
|
956
|
-
event:
|
|
986
|
+
event: R.None,
|
|
957
987
|
$auditRecord: e
|
|
958
988
|
};
|
|
959
|
-
return
|
|
989
|
+
return A(r, t), u("api/v1/audit.notify", r);
|
|
960
990
|
}
|
|
961
|
-
const
|
|
962
|
-
async function
|
|
991
|
+
const Zt = { notify: He };
|
|
992
|
+
async function Et(e, t, r) {
|
|
963
993
|
const n = e.items?.length || 0, o = 10, a = {
|
|
964
994
|
query: { ...t, action: "aggregate", aggregations: { [e.name]: { skip: n, count: o } } },
|
|
965
995
|
$auditRecord: { auditEvents: [r] }
|
|
966
996
|
};
|
|
967
|
-
|
|
968
|
-
const s = await u("api/v1/query", a), c = await
|
|
997
|
+
A(a);
|
|
998
|
+
const s = await u("api/v1/query", a), c = await y(s), { aggregations: i } = c, d = i[0];
|
|
969
999
|
return d.$hasMore = d.items.length > o, d.items = [...e.items, ...d.items], Promise.resolve(d);
|
|
970
1000
|
}
|
|
971
|
-
function
|
|
1001
|
+
function Je(e, t) {
|
|
972
1002
|
if (e.authMode?.kind === "credentials") return g.credentials();
|
|
973
1003
|
if (e.bearerToken) return g.bearer(e.bearerToken);
|
|
974
1004
|
const r = e.autoOAuthProvider || t?.autoOAuthProvider;
|
|
@@ -976,18 +1006,18 @@ function je(e, t) {
|
|
|
976
1006
|
const n = e.autoSAMLProvider || t?.autoSAMLProvider;
|
|
977
1007
|
return n ? g.saml(n) : g.unknown();
|
|
978
1008
|
}
|
|
979
|
-
async function
|
|
1009
|
+
async function Tt(e) {
|
|
980
1010
|
const t = e || l.app, r = new URLSearchParams({ app: t || "" });
|
|
981
1011
|
return _("api/v1/app", r);
|
|
982
1012
|
}
|
|
983
|
-
async function
|
|
1013
|
+
async function We() {
|
|
984
1014
|
const { app: e } = l, t = new URLSearchParams({
|
|
985
1015
|
app: e || "",
|
|
986
1016
|
preLogin: "true"
|
|
987
1017
|
});
|
|
988
1018
|
return _("api/v1/app", t);
|
|
989
1019
|
}
|
|
990
|
-
function
|
|
1020
|
+
function Xe() {
|
|
991
1021
|
let { backendUrl: e, app: t } = l;
|
|
992
1022
|
if (typeof window < "u") {
|
|
993
1023
|
if (e || (e = window.location.origin), !t) {
|
|
@@ -1003,8 +1033,8 @@ function Ve() {
|
|
|
1003
1033
|
autoOAuthProvider: void 0,
|
|
1004
1034
|
autoSAMLProvider: void 0,
|
|
1005
1035
|
bearerToken: void 0
|
|
1006
|
-
}), Promise.resolve({})) :
|
|
1007
|
-
const n =
|
|
1036
|
+
}), Promise.resolve({})) : We().then((r) => {
|
|
1037
|
+
const n = Je(l, r);
|
|
1008
1038
|
return S({
|
|
1009
1039
|
authMode: n,
|
|
1010
1040
|
// Persist the resolved providers as inputs so login()/redirect helpers can read them.
|
|
@@ -1015,21 +1045,21 @@ function Ve() {
|
|
|
1015
1045
|
throw f("atomic:fetchAppPreLogin error", r), r;
|
|
1016
1046
|
});
|
|
1017
1047
|
}
|
|
1018
|
-
const
|
|
1019
|
-
async function
|
|
1048
|
+
const er = Xe;
|
|
1049
|
+
async function tr(e, t, r = {}) {
|
|
1020
1050
|
const n = `api/v1/search.dataset/${e}/${t}`, o = await u(n, { parameters: r }), a = t[0].toLowerCase() + t.slice(1), s = o.datasets[a];
|
|
1021
1051
|
if ("errorCode" in s && "errorMessage" in s)
|
|
1022
1052
|
throw new Error(s.errorMessage);
|
|
1023
1053
|
return s;
|
|
1024
1054
|
}
|
|
1025
|
-
async function
|
|
1055
|
+
async function rr(e, t) {
|
|
1026
1056
|
const r = `api/v1/search.dataset/${e}`, { parameters: n = {}, datasets: o = [] } = t;
|
|
1027
1057
|
return (await u(r, { parameters: n, datasets: o })).datasets;
|
|
1028
1058
|
}
|
|
1029
|
-
async function
|
|
1059
|
+
async function nr(e) {
|
|
1030
1060
|
return await _(`api/v1/search.dataset/${e}`);
|
|
1031
1061
|
}
|
|
1032
|
-
async function
|
|
1062
|
+
async function or(e, t = !0, r) {
|
|
1033
1063
|
try {
|
|
1034
1064
|
return (await u("api/v1/labels", {
|
|
1035
1065
|
action: "list",
|
|
@@ -1042,7 +1072,7 @@ async function nr(e, t = !0, r) {
|
|
|
1042
1072
|
throw f("Error in fetchLabels", n), n;
|
|
1043
1073
|
}
|
|
1044
1074
|
}
|
|
1045
|
-
async function
|
|
1075
|
+
async function Ye() {
|
|
1046
1076
|
try {
|
|
1047
1077
|
const { app: e = "" } = l, t = new URLSearchParams({
|
|
1048
1078
|
app: e,
|
|
@@ -1053,7 +1083,7 @@ async function Ge() {
|
|
|
1053
1083
|
throw f("Error in getUserRights", e), e;
|
|
1054
1084
|
}
|
|
1055
1085
|
}
|
|
1056
|
-
async function
|
|
1086
|
+
async function Ke(e, t, r = !0) {
|
|
1057
1087
|
try {
|
|
1058
1088
|
const n = {
|
|
1059
1089
|
action: "add",
|
|
@@ -1063,7 +1093,7 @@ async function ze(e, t, r = !0) {
|
|
|
1063
1093
|
$auditRecord: {
|
|
1064
1094
|
auditEvents: [
|
|
1065
1095
|
{
|
|
1066
|
-
type:
|
|
1096
|
+
type: R.Label_AddDoc,
|
|
1067
1097
|
detail: {
|
|
1068
1098
|
public: r,
|
|
1069
1099
|
label: e ? e.toString() : null,
|
|
@@ -1084,7 +1114,7 @@ async function ze(e, t, r = !0) {
|
|
|
1084
1114
|
throw f("Error in add", n), n;
|
|
1085
1115
|
}
|
|
1086
1116
|
}
|
|
1087
|
-
async function
|
|
1117
|
+
async function Ze(e, t, r = !0) {
|
|
1088
1118
|
try {
|
|
1089
1119
|
const n = {
|
|
1090
1120
|
action: "remove",
|
|
@@ -1094,7 +1124,7 @@ async function He(e, t, r = !0) {
|
|
|
1094
1124
|
$auditRecord: {
|
|
1095
1125
|
auditEvents: [
|
|
1096
1126
|
{
|
|
1097
|
-
type:
|
|
1127
|
+
type: R.Label_RemoveDoc,
|
|
1098
1128
|
detail: {
|
|
1099
1129
|
public: r,
|
|
1100
1130
|
label: e ? e.toString() : null,
|
|
@@ -1115,7 +1145,7 @@ async function He(e, t, r = !0) {
|
|
|
1115
1145
|
throw f("Error in remove", n), n;
|
|
1116
1146
|
}
|
|
1117
1147
|
}
|
|
1118
|
-
async function
|
|
1148
|
+
async function Ee(e, t, r = !0) {
|
|
1119
1149
|
try {
|
|
1120
1150
|
const n = {
|
|
1121
1151
|
action: "rename",
|
|
@@ -1123,7 +1153,7 @@ async function Je(e, t, r = !0) {
|
|
|
1123
1153
|
newLabel: t,
|
|
1124
1154
|
public: r,
|
|
1125
1155
|
auditEvents: {
|
|
1126
|
-
type:
|
|
1156
|
+
type: R.Label_Rename,
|
|
1127
1157
|
detail: {
|
|
1128
1158
|
public: r,
|
|
1129
1159
|
oldlabel: e ? e.toString() : null,
|
|
@@ -1136,14 +1166,14 @@ async function Je(e, t, r = !0) {
|
|
|
1136
1166
|
throw f("Error in rename", n), n;
|
|
1137
1167
|
}
|
|
1138
1168
|
}
|
|
1139
|
-
async function
|
|
1169
|
+
async function Te(e, t = !0) {
|
|
1140
1170
|
try {
|
|
1141
1171
|
const r = {
|
|
1142
1172
|
action: "delete",
|
|
1143
1173
|
labels: e,
|
|
1144
1174
|
public: t,
|
|
1145
1175
|
auditEvents: {
|
|
1146
|
-
type:
|
|
1176
|
+
type: R.Label_Delete,
|
|
1147
1177
|
detail: {
|
|
1148
1178
|
public: t,
|
|
1149
1179
|
label: e ? e.toString() : null
|
|
@@ -1155,7 +1185,7 @@ async function We(e, t = !0) {
|
|
|
1155
1185
|
throw f("Error in deleteLabels", r), r;
|
|
1156
1186
|
}
|
|
1157
1187
|
}
|
|
1158
|
-
async function
|
|
1188
|
+
async function et(e, t, r = !0) {
|
|
1159
1189
|
try {
|
|
1160
1190
|
const n = {
|
|
1161
1191
|
action: "bulkAdd",
|
|
@@ -1163,7 +1193,7 @@ async function Xe(e, t, r = !0) {
|
|
|
1163
1193
|
query: t,
|
|
1164
1194
|
public: r,
|
|
1165
1195
|
auditEvents: {
|
|
1166
|
-
type:
|
|
1196
|
+
type: R.Label_Add,
|
|
1167
1197
|
detail: {
|
|
1168
1198
|
public: r,
|
|
1169
1199
|
label: e ? e.toString() : null,
|
|
@@ -1176,7 +1206,7 @@ async function Xe(e, t, r = !0) {
|
|
|
1176
1206
|
throw f("Error in bulkAdd", n), n;
|
|
1177
1207
|
}
|
|
1178
1208
|
}
|
|
1179
|
-
async function
|
|
1209
|
+
async function tt(e, t, r = !0) {
|
|
1180
1210
|
try {
|
|
1181
1211
|
const n = {
|
|
1182
1212
|
action: "bulkRemove",
|
|
@@ -1184,7 +1214,7 @@ async function Ye(e, t, r = !0) {
|
|
|
1184
1214
|
query: t,
|
|
1185
1215
|
public: r,
|
|
1186
1216
|
auditEvents: {
|
|
1187
|
-
type:
|
|
1217
|
+
type: R.Label_Delete,
|
|
1188
1218
|
detail: {
|
|
1189
1219
|
public: r,
|
|
1190
1220
|
label: e ? e.toString() : null,
|
|
@@ -1197,16 +1227,16 @@ async function Ye(e, t, r = !0) {
|
|
|
1197
1227
|
throw f("Error in bulkRemove", n), n;
|
|
1198
1228
|
}
|
|
1199
1229
|
}
|
|
1200
|
-
const
|
|
1201
|
-
getUserRights:
|
|
1202
|
-
add:
|
|
1203
|
-
remove:
|
|
1204
|
-
rename:
|
|
1205
|
-
delete:
|
|
1206
|
-
bulkAdd:
|
|
1207
|
-
bulkRemove:
|
|
1230
|
+
const ar = {
|
|
1231
|
+
getUserRights: Ye,
|
|
1232
|
+
add: Ke,
|
|
1233
|
+
remove: Ze,
|
|
1234
|
+
rename: Ee,
|
|
1235
|
+
delete: Te,
|
|
1236
|
+
bulkAdd: et,
|
|
1237
|
+
bulkRemove: tt
|
|
1208
1238
|
};
|
|
1209
|
-
async function
|
|
1239
|
+
async function sr(e, t) {
|
|
1210
1240
|
if (typeof window > "u")
|
|
1211
1241
|
return u("api/v1/preview", {
|
|
1212
1242
|
action: "get",
|
|
@@ -1221,7 +1251,7 @@ async function ar(e, t) {
|
|
|
1221
1251
|
browserUrl: r
|
|
1222
1252
|
});
|
|
1223
1253
|
}
|
|
1224
|
-
async function
|
|
1254
|
+
async function ir(e) {
|
|
1225
1255
|
const t = new Headers();
|
|
1226
1256
|
t.append("content-type", "text");
|
|
1227
1257
|
const r = await fetch(
|
|
@@ -1231,16 +1261,16 @@ async function sr(e) {
|
|
|
1231
1261
|
headers: t
|
|
1232
1262
|
}
|
|
1233
1263
|
);
|
|
1234
|
-
|
|
1264
|
+
y(r);
|
|
1235
1265
|
}
|
|
1236
|
-
async function
|
|
1266
|
+
async function rt() {
|
|
1237
1267
|
const e = new URLSearchParams({
|
|
1238
1268
|
action: "get",
|
|
1239
1269
|
noAutoAuthentication: "true"
|
|
1240
1270
|
});
|
|
1241
1271
|
return _("api/v1/principal", e);
|
|
1242
1272
|
}
|
|
1243
|
-
async function
|
|
1273
|
+
async function nt(e) {
|
|
1244
1274
|
const t = {
|
|
1245
1275
|
noAutoAuthentication: "true",
|
|
1246
1276
|
...e
|
|
@@ -1249,7 +1279,7 @@ async function Ze(e) {
|
|
|
1249
1279
|
o !== void 0 && r.append(n, String(o));
|
|
1250
1280
|
}), _("api/v1/principal/list", r);
|
|
1251
1281
|
}
|
|
1252
|
-
async function
|
|
1282
|
+
async function ot(e) {
|
|
1253
1283
|
if (!e)
|
|
1254
1284
|
return Promise.reject(new Error("userid is required"));
|
|
1255
1285
|
const t = new URLSearchParams({
|
|
@@ -1259,7 +1289,7 @@ async function Ee(e) {
|
|
|
1259
1289
|
});
|
|
1260
1290
|
return _("api/v1/principal", t);
|
|
1261
1291
|
}
|
|
1262
|
-
async function
|
|
1292
|
+
async function at(e) {
|
|
1263
1293
|
if (e.length === 0)
|
|
1264
1294
|
return Promise.reject(new Error("userids is required"));
|
|
1265
1295
|
const t = new URLSearchParams({
|
|
@@ -1268,27 +1298,27 @@ async function Te(e) {
|
|
|
1268
1298
|
});
|
|
1269
1299
|
return _("api/v1/principal/userids", t);
|
|
1270
1300
|
}
|
|
1271
|
-
const
|
|
1301
|
+
const cr = {
|
|
1272
1302
|
principal: {
|
|
1273
|
-
get:
|
|
1274
|
-
list:
|
|
1275
|
-
userid:
|
|
1276
|
-
userids:
|
|
1303
|
+
get: rt,
|
|
1304
|
+
list: nt,
|
|
1305
|
+
userid: ot,
|
|
1306
|
+
userids: at
|
|
1277
1307
|
}
|
|
1278
|
-
},
|
|
1279
|
-
async function
|
|
1308
|
+
}, de = 11;
|
|
1309
|
+
async function lr(e, t, r) {
|
|
1280
1310
|
const o = await u("api/v1/query", {
|
|
1281
1311
|
query: e,
|
|
1282
1312
|
$auditRecord: t,
|
|
1283
1313
|
queryIntentData: r
|
|
1284
1314
|
});
|
|
1285
1315
|
o.aggregations.forEach((s) => {
|
|
1286
|
-
s.$hasMore = !1, !s.isDistribution && !s.isTree && s.items && (s.$hasMore = s.items.length ===
|
|
1316
|
+
s.$hasMore = !1, !s.isDistribution && !s.isTree && s.items && (s.$hasMore = s.items.length === de), s.isTree && s.items && K(s);
|
|
1287
1317
|
}), o.records?.map((s) => Object.assign(s, { value: s.title, type: "default" }));
|
|
1288
1318
|
const a = { ...o, nextPage: o.page < Math.ceil(o.rowCount / o.pageSize) ? o.page + 1 : void 0, previousPage: o.page > 1 ? o.page - 1 : void 0 };
|
|
1289
1319
|
return Promise.resolve(a);
|
|
1290
1320
|
}
|
|
1291
|
-
async function
|
|
1321
|
+
async function ur(e, t, r) {
|
|
1292
1322
|
const { app: n = "" } = l, o = {
|
|
1293
1323
|
methods: [],
|
|
1294
1324
|
mode: t,
|
|
@@ -1304,20 +1334,20 @@ async function lr(e, t, r) {
|
|
|
1304
1334
|
const a = await u("api/v1/multi", o);
|
|
1305
1335
|
a.results.forEach((c) => {
|
|
1306
1336
|
c.aggregations.forEach((i) => {
|
|
1307
|
-
i.$hasMore = !1, !i.isDistribution && !i.isTree && i.items && (i.$hasMore = i.items.length ===
|
|
1337
|
+
i.$hasMore = !1, !i.isDistribution && !i.isTree && i.items && (i.$hasMore = i.items.length === de), i.isTree && K(i);
|
|
1308
1338
|
});
|
|
1309
1339
|
}), a.results.forEach((c) => c.records?.map((i) => Object.assign(i, { value: i.title, type: "default" })));
|
|
1310
1340
|
const s = a.results.map((c) => ({ ...c, nextPage: c.page < Math.ceil(c.rowCount / c.pageSize) ? c.page + 1 : void 0, previousPage: c.page > 1 ? c.page - 1 : void 0 }));
|
|
1311
1341
|
return Promise.resolve(s);
|
|
1312
1342
|
}
|
|
1313
|
-
function
|
|
1343
|
+
function K(e, t = "", r = 0) {
|
|
1314
1344
|
let n = [];
|
|
1315
1345
|
return e.items && e.items.forEach((o) => {
|
|
1316
1346
|
let a = t ? `${t}/${o.value}` : o.value, s = r + 1;
|
|
1317
|
-
n.push({ path: a, level: s }), o.$path = a, o.$level = s, o.hasChildren ? n = n.concat(
|
|
1347
|
+
n.push({ path: a, level: s }), o.$path = a, o.$level = s, o.hasChildren ? n = n.concat(K(o, a, s)) : o.hasChildren = !1;
|
|
1318
1348
|
}), n;
|
|
1319
1349
|
}
|
|
1320
|
-
async function
|
|
1350
|
+
async function dr({ model: e, appName: t, query: r, article: n }) {
|
|
1321
1351
|
const { webservice: o, format: a, maxcount: s, exportedColumns: c, export: i } = e, d = {
|
|
1322
1352
|
app: t,
|
|
1323
1353
|
webservice: o,
|
|
@@ -1335,14 +1365,14 @@ async function ur({ model: e, appName: t, query: r, article: n }) {
|
|
|
1335
1365
|
}]
|
|
1336
1366
|
}
|
|
1337
1367
|
};
|
|
1338
|
-
return
|
|
1368
|
+
return A(d), await u("api/v1/search.queryexport", d, { responseType: "blob" });
|
|
1339
1369
|
}
|
|
1340
|
-
async function
|
|
1370
|
+
async function fr(e) {
|
|
1341
1371
|
return (await u("api/v1/queryintent", {
|
|
1342
1372
|
query: e
|
|
1343
1373
|
}))?.intents;
|
|
1344
1374
|
}
|
|
1345
|
-
async function
|
|
1375
|
+
async function hr(e, t, r) {
|
|
1346
1376
|
return (await u(
|
|
1347
1377
|
"api/v1/similardocuments",
|
|
1348
1378
|
{
|
|
@@ -1354,17 +1384,17 @@ async function fr(e, t, r) {
|
|
|
1354
1384
|
{ signal: r }
|
|
1355
1385
|
)).data;
|
|
1356
1386
|
}
|
|
1357
|
-
async function
|
|
1387
|
+
async function gr(e, t) {
|
|
1358
1388
|
return (await u("api/v1/query.links", {
|
|
1359
1389
|
webservice: e,
|
|
1360
1390
|
query: t
|
|
1361
1391
|
}))?.links?.map((o) => ({ ...o, query: t }));
|
|
1362
1392
|
}
|
|
1363
|
-
function
|
|
1393
|
+
function st(e, t) {
|
|
1364
1394
|
if (typeof e == "number")
|
|
1365
1395
|
return `${e}`;
|
|
1366
|
-
if (
|
|
1367
|
-
return
|
|
1396
|
+
if (qe(e))
|
|
1397
|
+
return it(e);
|
|
1368
1398
|
if (typeof e == "boolean")
|
|
1369
1399
|
return e ? "true" : "false";
|
|
1370
1400
|
if (e === null)
|
|
@@ -1377,11 +1407,11 @@ function et(e, t) {
|
|
|
1377
1407
|
}
|
|
1378
1408
|
return e;
|
|
1379
1409
|
}
|
|
1380
|
-
function
|
|
1410
|
+
function it(e) {
|
|
1381
1411
|
if (!e)
|
|
1382
1412
|
return "";
|
|
1383
1413
|
try {
|
|
1384
|
-
if (
|
|
1414
|
+
if (Be(e) === 0)
|
|
1385
1415
|
return new Intl.DateTimeFormat("en-CA", {
|
|
1386
1416
|
year: "numeric",
|
|
1387
1417
|
month: "2-digit",
|
|
@@ -1400,7 +1430,7 @@ function tt(e) {
|
|
|
1400
1430
|
return "Invalid date";
|
|
1401
1431
|
}
|
|
1402
1432
|
}
|
|
1403
|
-
async function
|
|
1433
|
+
async function pr(e, t, r, n, o) {
|
|
1404
1434
|
const { app: a } = l, s = {
|
|
1405
1435
|
app: a || "",
|
|
1406
1436
|
suggestQuery: e,
|
|
@@ -1418,7 +1448,7 @@ async function gr(e, t, r, n, o) {
|
|
|
1418
1448
|
throw console.error("Error fetching suggestions:", c), c;
|
|
1419
1449
|
}
|
|
1420
1450
|
}
|
|
1421
|
-
async function
|
|
1451
|
+
async function mr(e, t, r, n) {
|
|
1422
1452
|
const { app: o } = l;
|
|
1423
1453
|
return (await u(
|
|
1424
1454
|
"api/v1/suggestquery",
|
|
@@ -1431,7 +1461,7 @@ async function pr(e, t, r, n) {
|
|
|
1431
1461
|
}
|
|
1432
1462
|
)).suggests;
|
|
1433
1463
|
}
|
|
1434
|
-
async function
|
|
1464
|
+
async function wr(e, t, r) {
|
|
1435
1465
|
if (!t) return Promise.resolve([]);
|
|
1436
1466
|
const { app: n } = l, a = await u(
|
|
1437
1467
|
"api/v1/suggestfield",
|
|
@@ -1443,10 +1473,10 @@ async function mr(e, t, r) {
|
|
|
1443
1473
|
}
|
|
1444
1474
|
);
|
|
1445
1475
|
return a.suggests.forEach((s) => {
|
|
1446
|
-
s.display =
|
|
1476
|
+
s.display = st(s.display);
|
|
1447
1477
|
}), a.suggests;
|
|
1448
1478
|
}
|
|
1449
|
-
async function
|
|
1479
|
+
async function _r(e, t, r, n, o, a) {
|
|
1450
1480
|
return u("api/v1/doc.textchunks", {
|
|
1451
1481
|
id: e,
|
|
1452
1482
|
textChunks: t,
|
|
@@ -1456,73 +1486,73 @@ async function wr(e, t, r, n, o, a) {
|
|
|
1456
1486
|
rightSentencesCount: a
|
|
1457
1487
|
});
|
|
1458
1488
|
}
|
|
1459
|
-
async function
|
|
1489
|
+
async function kr() {
|
|
1460
1490
|
const { app: e } = l, t = new URLSearchParams({
|
|
1461
1491
|
app: e || "",
|
|
1462
1492
|
action: "load"
|
|
1463
1493
|
});
|
|
1464
1494
|
return _("api/v1/usersettings", t);
|
|
1465
1495
|
}
|
|
1466
|
-
async function
|
|
1496
|
+
async function ct(e, t) {
|
|
1467
1497
|
const r = {
|
|
1468
1498
|
action: "save",
|
|
1469
1499
|
userSettings: e,
|
|
1470
1500
|
$auditRecord: { auditEvents: [t] }
|
|
1471
1501
|
};
|
|
1472
|
-
return
|
|
1502
|
+
return A(r), u("api/v1/usersettings", r);
|
|
1473
1503
|
}
|
|
1474
|
-
async function
|
|
1504
|
+
async function Sr(e, t) {
|
|
1475
1505
|
const n = {
|
|
1476
1506
|
action: "patch",
|
|
1477
1507
|
userSettings: e,
|
|
1478
1508
|
$auditRecord: t ? { auditEvents: [t] } : void 0
|
|
1479
1509
|
};
|
|
1480
|
-
return
|
|
1510
|
+
return A(n), u("api/v1/usersettings", n);
|
|
1481
1511
|
}
|
|
1482
|
-
async function
|
|
1483
|
-
return
|
|
1512
|
+
async function br() {
|
|
1513
|
+
return ct({}, { type: "UserSettings_Reset" });
|
|
1484
1514
|
}
|
|
1485
|
-
async function
|
|
1515
|
+
async function vr(e, t) {
|
|
1486
1516
|
return u("api/v2/security/password/change", { newPassword: e, currentPassword: t });
|
|
1487
1517
|
}
|
|
1488
|
-
async function
|
|
1518
|
+
async function Cr(e) {
|
|
1489
1519
|
const t = "api/v2/security/password/ask-reset-email", n = {
|
|
1490
1520
|
changePasswordRedirectUrl: `${window.location.origin}/login?mode=changepassword`,
|
|
1491
1521
|
userName: e
|
|
1492
1522
|
};
|
|
1493
1523
|
return u(t, n);
|
|
1494
1524
|
}
|
|
1495
|
-
async function
|
|
1525
|
+
async function Rr(e) {
|
|
1496
1526
|
return await _(`api/v2/user-profile/${e}`);
|
|
1497
1527
|
}
|
|
1498
|
-
async function
|
|
1528
|
+
async function Pr(e) {
|
|
1499
1529
|
return await u("api/v2/user-profile", e);
|
|
1500
1530
|
}
|
|
1501
|
-
async function
|
|
1502
|
-
return await
|
|
1531
|
+
async function yr(e, t, r) {
|
|
1532
|
+
return await Le(
|
|
1503
1533
|
`api/v2/user-profile/${e.data?.id}/${t}/${r}`,
|
|
1504
1534
|
e
|
|
1505
1535
|
);
|
|
1506
1536
|
}
|
|
1507
|
-
async function
|
|
1537
|
+
async function xr(e, t, r) {
|
|
1508
1538
|
try {
|
|
1509
|
-
return (await
|
|
1539
|
+
return (await xe(
|
|
1510
1540
|
`api/v2/user-profile/${e.data?.id}/${t}/${r}`
|
|
1511
1541
|
)).success === !0;
|
|
1512
1542
|
} catch {
|
|
1513
1543
|
return !1;
|
|
1514
1544
|
}
|
|
1515
1545
|
}
|
|
1516
|
-
async function
|
|
1546
|
+
async function Lr() {
|
|
1517
1547
|
return await _("api/v2/version");
|
|
1518
1548
|
}
|
|
1519
|
-
const
|
|
1549
|
+
const C = 1e4, b = "sinequa-auth-redirect-attempt", lt = async () => {
|
|
1520
1550
|
const { autoOAuthProvider: e } = l;
|
|
1521
1551
|
if (!e)
|
|
1522
1552
|
throw new Error("autoOAuthProvider is not configured in globalConfig");
|
|
1523
1553
|
if (typeof window > "u")
|
|
1524
1554
|
try {
|
|
1525
|
-
const { signal: r } =
|
|
1555
|
+
const { signal: r } = v(C);
|
|
1526
1556
|
return await u(
|
|
1527
1557
|
"security.oauth",
|
|
1528
1558
|
{
|
|
@@ -1543,26 +1573,32 @@ const v = 1e4, nt = async () => {
|
|
|
1543
1573
|
originalUrl: window.location.href
|
|
1544
1574
|
};
|
|
1545
1575
|
try {
|
|
1546
|
-
const { signal: r } =
|
|
1576
|
+
const { signal: r } = v(C), n = await u(
|
|
1547
1577
|
"api/v1/security.oauth",
|
|
1548
1578
|
t,
|
|
1549
1579
|
{ signal: r }
|
|
1550
1580
|
);
|
|
1551
1581
|
if (n.redirectUrl) {
|
|
1552
1582
|
const o = new URL(n.redirectUrl, window.location.origin);
|
|
1553
|
-
(o.protocol === "https:" || o.protocol === "http:")
|
|
1583
|
+
if (o.protocol === "https:" || o.protocol === "http:") {
|
|
1584
|
+
if (W(b))
|
|
1585
|
+
throw $(b), new Error(
|
|
1586
|
+
`OAuth sign-in with provider "${e}" did not establish a session — its callback is likely not authorized for this application.`
|
|
1587
|
+
);
|
|
1588
|
+
X(b, "1"), window.location.href = o.href;
|
|
1589
|
+
}
|
|
1554
1590
|
}
|
|
1555
1591
|
return n;
|
|
1556
1592
|
} catch (r) {
|
|
1557
1593
|
throw f("Failed to authenticate with OAuth", r), r;
|
|
1558
1594
|
}
|
|
1559
|
-
},
|
|
1595
|
+
}, ut = async () => {
|
|
1560
1596
|
const { autoSAMLProvider: e } = l;
|
|
1561
1597
|
if (!e)
|
|
1562
1598
|
throw new Error("autoSAMLProvider is not configured in globalConfig");
|
|
1563
1599
|
if (typeof window > "u")
|
|
1564
1600
|
try {
|
|
1565
|
-
const { signal: r } =
|
|
1601
|
+
const { signal: r } = v(C);
|
|
1566
1602
|
return await u(
|
|
1567
1603
|
"security.saml",
|
|
1568
1604
|
{
|
|
@@ -1583,67 +1619,43 @@ const v = 1e4, nt = async () => {
|
|
|
1583
1619
|
originalUrl: window.location.href
|
|
1584
1620
|
};
|
|
1585
1621
|
try {
|
|
1586
|
-
const { signal: r } =
|
|
1622
|
+
const { signal: r } = v(C), n = await u(
|
|
1587
1623
|
"api/v1/security.saml",
|
|
1588
1624
|
t,
|
|
1589
1625
|
{ signal: r }
|
|
1590
1626
|
);
|
|
1591
1627
|
if (n.redirectUrl) {
|
|
1592
1628
|
const o = new URL(n.redirectUrl, window.location.origin);
|
|
1593
|
-
(o.protocol === "https:" || o.protocol === "http:")
|
|
1629
|
+
if (o.protocol === "https:" || o.protocol === "http:") {
|
|
1630
|
+
if (W(b))
|
|
1631
|
+
throw $(b), new Error(
|
|
1632
|
+
`SAML sign-in with provider "${e}" did not establish a session — its callback is likely not authorized for this application.`
|
|
1633
|
+
);
|
|
1634
|
+
X(b, "1"), window.location.href = o.href;
|
|
1635
|
+
}
|
|
1594
1636
|
}
|
|
1595
1637
|
return n;
|
|
1596
1638
|
} catch (r) {
|
|
1597
1639
|
throw f("Failed to authenticate with SAML", r), r;
|
|
1598
1640
|
}
|
|
1599
|
-
},
|
|
1600
|
-
store: {},
|
|
1601
|
-
getItem(e) {
|
|
1602
|
-
return this.store[e] ?? null;
|
|
1603
|
-
},
|
|
1604
|
-
setItem(e, t) {
|
|
1605
|
-
this.store[e] = t.toString();
|
|
1606
|
-
},
|
|
1607
|
-
removeItem(e) {
|
|
1608
|
-
delete this.store[e];
|
|
1609
|
-
},
|
|
1610
|
-
clear() {
|
|
1611
|
-
this.store = {};
|
|
1612
|
-
}
|
|
1613
|
-
}, J = H;
|
|
1614
|
-
function at(e) {
|
|
1615
|
-
return typeof window > "u" || !window.localStorage ? H.getItem(e) : window.localStorage.getItem(e);
|
|
1616
|
-
}
|
|
1617
|
-
function st(e) {
|
|
1618
|
-
typeof window > "u" || !window.localStorage ? H.removeItem(e) : window.localStorage.removeItem(e);
|
|
1619
|
-
}
|
|
1620
|
-
function it(e) {
|
|
1621
|
-
return typeof window > "u" || !window.sessionStorage ? J.getItem(e) : window.sessionStorage.getItem(e);
|
|
1622
|
-
}
|
|
1623
|
-
function ct(e, t) {
|
|
1624
|
-
typeof window > "u" || !window.sessionStorage ? J.setItem(e, t) : window.sessionStorage.setItem(e, t);
|
|
1625
|
-
}
|
|
1626
|
-
function lt(e) {
|
|
1627
|
-
typeof window > "u" || !window.sessionStorage ? J.removeItem(e) : window.sessionStorage.removeItem(e);
|
|
1628
|
-
}
|
|
1629
|
-
const A = (e) => ct(
|
|
1641
|
+
}, q = (e) => X(
|
|
1630
1642
|
"sinequa-credentials",
|
|
1631
1643
|
JSON.stringify({ data: { csrfToken: e } })
|
|
1632
|
-
),
|
|
1644
|
+
), dt = async () => {
|
|
1633
1645
|
try {
|
|
1634
|
-
const { signal: e } =
|
|
1646
|
+
const { signal: e } = v(C), t = await _(
|
|
1635
1647
|
"api/v1/challenge?action=getCsrfToken&suppressErrors=true",
|
|
1636
1648
|
void 0,
|
|
1637
1649
|
{ signal: e }
|
|
1638
1650
|
);
|
|
1639
1651
|
if (t?.csrfToken)
|
|
1640
|
-
return
|
|
1652
|
+
return q(t.csrfToken), t.csrfToken;
|
|
1641
1653
|
throw new Error("No CSRF token returned");
|
|
1642
1654
|
} catch (e) {
|
|
1643
1655
|
throw f("Failed to get CSRF token", e), e;
|
|
1644
1656
|
}
|
|
1645
1657
|
};
|
|
1646
|
-
async function
|
|
1658
|
+
async function fe(e) {
|
|
1647
1659
|
if (e) {
|
|
1648
1660
|
const { username: t, password: r } = e, n = {
|
|
1649
1661
|
action: "get",
|
|
@@ -1654,12 +1666,12 @@ async function ce(e) {
|
|
|
1654
1666
|
noAutoAuthentication: !0
|
|
1655
1667
|
};
|
|
1656
1668
|
try {
|
|
1657
|
-
const { signal: o } =
|
|
1669
|
+
const { signal: o } = v(C), a = await u(
|
|
1658
1670
|
"api/v1/security.webtoken",
|
|
1659
1671
|
n,
|
|
1660
1672
|
{ signal: o }
|
|
1661
1673
|
);
|
|
1662
|
-
return a?.csrfToken ? (
|
|
1674
|
+
return a?.csrfToken ? (q(a.csrfToken), a.csrfToken) : null;
|
|
1663
1675
|
} catch (o) {
|
|
1664
1676
|
throw f("Failed to get JWT", o), o;
|
|
1665
1677
|
}
|
|
@@ -1678,96 +1690,96 @@ async function ce(e) {
|
|
|
1678
1690
|
const n = new Headers();
|
|
1679
1691
|
n.append("Sinequa-Force-Camel-Case", "true"), n.append("accept", "application/json"), n.append("Content-Type", "application/json"), n.append("Authorization", `Bearer ${r}`);
|
|
1680
1692
|
try {
|
|
1681
|
-
const { signal: o } =
|
|
1693
|
+
const { signal: o } = v(C), a = await u(
|
|
1682
1694
|
"api/v1/security.webtoken",
|
|
1683
1695
|
t,
|
|
1684
1696
|
{ headers: n, signal: o }
|
|
1685
1697
|
);
|
|
1686
|
-
return a?.csrfToken ? (
|
|
1698
|
+
return a?.csrfToken ? (q(a.csrfToken), a.csrfToken) : null;
|
|
1687
1699
|
} catch (o) {
|
|
1688
1700
|
throw f("Failed to get JWT without credentials", o), o;
|
|
1689
1701
|
}
|
|
1690
1702
|
}
|
|
1691
1703
|
}
|
|
1692
|
-
const
|
|
1693
|
-
const e =
|
|
1704
|
+
const Z = () => {
|
|
1705
|
+
const e = W("sinequa-credentials");
|
|
1694
1706
|
if (e)
|
|
1695
1707
|
try {
|
|
1696
1708
|
const n = JSON.parse(e).data?.csrfToken;
|
|
1697
1709
|
if (n) return n;
|
|
1698
1710
|
} catch (r) {
|
|
1699
|
-
|
|
1711
|
+
N(
|
|
1700
1712
|
"Failed to parse session storage credentials, falling back to local storage",
|
|
1701
1713
|
r
|
|
1702
1714
|
);
|
|
1703
1715
|
}
|
|
1704
|
-
const t =
|
|
1716
|
+
const t = ge("csrfToken");
|
|
1705
1717
|
return t || null;
|
|
1706
|
-
},
|
|
1718
|
+
}, $r = async (e) => {
|
|
1707
1719
|
if (e) {
|
|
1708
1720
|
const { username: r, password: n } = e;
|
|
1709
|
-
return !r || !n ? (f("Credentials are required for authentication"), m(!1), !1) :
|
|
1721
|
+
return !r || !n ? (f("Credentials are required for authentication"), m(!1), !1) : ft({ username: r, password: n });
|
|
1710
1722
|
}
|
|
1711
1723
|
const t = l.authMode ?? g.unknown();
|
|
1712
1724
|
if (t.kind === "credentials")
|
|
1713
1725
|
return m(!1), !1;
|
|
1714
1726
|
if (t.kind === "bearer")
|
|
1715
|
-
return
|
|
1716
|
-
if (
|
|
1717
|
-
return S({ isRedirectUrl: !1 }), m(!0), !0;
|
|
1727
|
+
return ht();
|
|
1728
|
+
if (Z())
|
|
1729
|
+
return S({ isRedirectUrl: !1 }), $(b), m(!0), !0;
|
|
1718
1730
|
try {
|
|
1719
|
-
if (
|
|
1720
|
-
return
|
|
1731
|
+
if (x("Checking for an existing session via CSRF token retrieval"), await dt())
|
|
1732
|
+
return x("User already authenticated (existing session / SSO)"), $(b), t.kind === "unknown" && S({ authMode: g.sso() }), m(!0), !0;
|
|
1721
1733
|
} catch {
|
|
1722
1734
|
}
|
|
1723
1735
|
switch (t.kind) {
|
|
1724
1736
|
case "oauth":
|
|
1725
|
-
return
|
|
1737
|
+
return x("Initiating OAuth authentication flow"), await lt(), m(!1), !1;
|
|
1726
1738
|
case "saml":
|
|
1727
|
-
return
|
|
1739
|
+
return x("Initiating SAML authentication flow"), await ut(), m(!1), !1;
|
|
1728
1740
|
case "sso":
|
|
1729
1741
|
return m(!1), !1;
|
|
1730
1742
|
default:
|
|
1731
1743
|
return S({ authMode: g.credentials() }), m(!1), !1;
|
|
1732
1744
|
}
|
|
1733
1745
|
};
|
|
1734
|
-
async function
|
|
1735
|
-
|
|
1736
|
-
const { userOverrideActive: t,
|
|
1737
|
-
S({ userOverrideActive: !1,
|
|
1746
|
+
async function ft(e) {
|
|
1747
|
+
x("Attempting authentication using credentials"), S({ authMode: g.credentials() });
|
|
1748
|
+
const { userOverrideActive: t, userOverride: r } = l;
|
|
1749
|
+
S({ userOverrideActive: !1, userOverride: void 0 });
|
|
1738
1750
|
try {
|
|
1739
|
-
await
|
|
1751
|
+
await fe(e);
|
|
1740
1752
|
} catch (n) {
|
|
1741
1753
|
throw m(!1), n;
|
|
1742
1754
|
}
|
|
1743
|
-
return S({ userOverrideActive: t,
|
|
1755
|
+
return S({ userOverrideActive: t, userOverride: r }), m(!0), !0;
|
|
1744
1756
|
}
|
|
1745
|
-
async function
|
|
1757
|
+
async function ht() {
|
|
1746
1758
|
try {
|
|
1747
|
-
if (
|
|
1759
|
+
if (x("Attempting authentication using bearer token"), await fe())
|
|
1748
1760
|
return m(!0), !0;
|
|
1749
1761
|
} catch (e) {
|
|
1750
1762
|
throw f("Bearer authentication failed", e), m(!1), e;
|
|
1751
1763
|
}
|
|
1752
1764
|
return m(!1), !1;
|
|
1753
1765
|
}
|
|
1754
|
-
const
|
|
1766
|
+
const gt = async () => {
|
|
1755
1767
|
const e = new URLSearchParams({
|
|
1756
1768
|
action: "deleteWebTokenCookie",
|
|
1757
1769
|
noUserOverride: "true",
|
|
1758
1770
|
noAutoAuthentication: "true"
|
|
1759
|
-
}), { signal: t } =
|
|
1771
|
+
}), { signal: t } = v(C);
|
|
1760
1772
|
return _(
|
|
1761
1773
|
"api/v1/challenge",
|
|
1762
1774
|
e,
|
|
1763
1775
|
{ signal: t }
|
|
1764
1776
|
);
|
|
1765
1777
|
};
|
|
1766
|
-
async function
|
|
1778
|
+
async function Ur() {
|
|
1767
1779
|
const { userOverrideActive: e } = l;
|
|
1768
|
-
if (
|
|
1780
|
+
if (pt(), !e)
|
|
1769
1781
|
try {
|
|
1770
|
-
const { methodresult: t, logoutUrl: r } = await
|
|
1782
|
+
const { methodresult: t, logoutUrl: r } = await gt();
|
|
1771
1783
|
if (t === "ok")
|
|
1772
1784
|
return r;
|
|
1773
1785
|
f("logout failed");
|
|
@@ -1775,141 +1787,141 @@ async function $r() {
|
|
|
1775
1787
|
f("logout failed", t);
|
|
1776
1788
|
}
|
|
1777
1789
|
}
|
|
1778
|
-
function
|
|
1779
|
-
|
|
1790
|
+
function pt() {
|
|
1791
|
+
pe("csrfToken"), $("sinequa-credentials"), m(!1);
|
|
1780
1792
|
}
|
|
1781
|
-
const
|
|
1793
|
+
const Or = () => !!Z();
|
|
1782
1794
|
export {
|
|
1783
|
-
|
|
1784
|
-
|
|
1785
|
-
|
|
1786
|
-
|
|
1795
|
+
cr as API,
|
|
1796
|
+
P as ApiError,
|
|
1797
|
+
Zt as Audit,
|
|
1798
|
+
R as AuditEventType,
|
|
1787
1799
|
g as AuthMode,
|
|
1788
|
-
|
|
1800
|
+
$e as DidYouMeanKind,
|
|
1789
1801
|
h as EngineType,
|
|
1790
1802
|
w as EngineTypeModifier,
|
|
1791
|
-
|
|
1792
|
-
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
|
|
1798
|
-
|
|
1799
|
-
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
1804
|
-
|
|
1805
|
-
|
|
1806
|
-
|
|
1807
|
-
|
|
1808
|
-
|
|
1809
|
-
|
|
1810
|
-
|
|
1811
|
-
|
|
1812
|
-
|
|
1813
|
-
|
|
1814
|
-
|
|
1815
|
-
|
|
1816
|
-
|
|
1803
|
+
ie as LogLevel,
|
|
1804
|
+
zt as MINIMUM_COMPATIBLE_SERVER_API_VERSION,
|
|
1805
|
+
Ue as RFMDisplay,
|
|
1806
|
+
ne as ServerError,
|
|
1807
|
+
ye as TimeoutError,
|
|
1808
|
+
G as UnauthorizedError,
|
|
1809
|
+
A as addAuditAdditionalInfo,
|
|
1810
|
+
bt as addConcepts,
|
|
1811
|
+
Qe as addSessionId,
|
|
1812
|
+
Ve as addUrl,
|
|
1813
|
+
me as aggItemRegex,
|
|
1814
|
+
_t as aggregationItemStrictCompare,
|
|
1815
|
+
er as appInitializerFn,
|
|
1816
|
+
St as bisect,
|
|
1817
|
+
K as buildPathsAndLevels,
|
|
1818
|
+
pt as clearSessionTokens,
|
|
1819
|
+
Ft as configureLogger,
|
|
1820
|
+
O as createHeaders,
|
|
1821
|
+
v as createTimeoutController,
|
|
1822
|
+
Pr as createUserProfile,
|
|
1823
|
+
U as debug,
|
|
1824
|
+
xe as del,
|
|
1825
|
+
xr as deleteUserProfileProperty,
|
|
1826
|
+
br as deleteUserSettings,
|
|
1827
|
+
gt as deleteWebTokenCookie,
|
|
1828
|
+
Je as detectAuthMode,
|
|
1817
1829
|
m as emitAuthenticatedEvent,
|
|
1818
1830
|
f as error,
|
|
1819
|
-
|
|
1820
|
-
|
|
1831
|
+
Yt as escapeExpr,
|
|
1832
|
+
jt as expiresSoon,
|
|
1821
1833
|
Gt as extraColumns,
|
|
1822
|
-
|
|
1823
|
-
|
|
1824
|
-
|
|
1825
|
-
|
|
1826
|
-
|
|
1827
|
-
|
|
1828
|
-
|
|
1829
|
-
|
|
1830
|
-
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
|
|
1839
|
-
|
|
1840
|
-
|
|
1841
|
-
|
|
1842
|
-
|
|
1843
|
-
|
|
1844
|
-
|
|
1845
|
-
|
|
1846
|
-
|
|
1847
|
-
|
|
1848
|
-
|
|
1849
|
-
|
|
1850
|
-
|
|
1834
|
+
Et as fetchAggregation,
|
|
1835
|
+
Tt as fetchApp,
|
|
1836
|
+
We as fetchAppPreLogin,
|
|
1837
|
+
ur as fetchBulkQuery,
|
|
1838
|
+
vr as fetchChangePassword,
|
|
1839
|
+
tr as fetchDataset,
|
|
1840
|
+
nr as fetchDatasetList,
|
|
1841
|
+
rr as fetchDatasets,
|
|
1842
|
+
or as fetchLabels,
|
|
1843
|
+
sr as fetchPreview,
|
|
1844
|
+
ir as fetchPreviewUrl,
|
|
1845
|
+
rt as fetchPrincipal,
|
|
1846
|
+
nt as fetchPrincipalList,
|
|
1847
|
+
ot as fetchPrincipalUserid,
|
|
1848
|
+
at as fetchPrincipalUserids,
|
|
1849
|
+
lr as fetchQuery,
|
|
1850
|
+
dr as fetchQueryExport,
|
|
1851
|
+
fr as fetchQueryIntent,
|
|
1852
|
+
Cr as fetchSendPasswordResetEmail,
|
|
1853
|
+
hr as fetchSimilarDocuments,
|
|
1854
|
+
gr as fetchSponsoredLinks,
|
|
1855
|
+
pr as fetchSuggest,
|
|
1856
|
+
wr as fetchSuggestField,
|
|
1857
|
+
mr as fetchSuggestQuery,
|
|
1858
|
+
_r as fetchTextChunks,
|
|
1859
|
+
Rr as fetchUserProfile,
|
|
1860
|
+
kr as fetchUserSettings,
|
|
1861
|
+
Lr as fetchVersion,
|
|
1862
|
+
Ht as filter,
|
|
1851
1863
|
_ as get,
|
|
1852
|
-
|
|
1853
|
-
|
|
1854
|
-
|
|
1855
|
-
|
|
1856
|
-
|
|
1857
|
-
|
|
1858
|
-
|
|
1859
|
-
|
|
1860
|
-
|
|
1861
|
-
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
+
Rt as getConcepts,
|
|
1865
|
+
dt as getCsrfToken,
|
|
1866
|
+
se as getFiltersFromURI,
|
|
1867
|
+
$t as getFiltersFromUrl,
|
|
1868
|
+
Nt as getHelpIndexUrl,
|
|
1869
|
+
Ot as getIdFromUrl,
|
|
1870
|
+
fe as getJWToken,
|
|
1871
|
+
Jt as getMetadata,
|
|
1872
|
+
Wt as getMetadataWithValues,
|
|
1873
|
+
Pe as getOffsetFromDates,
|
|
1874
|
+
At as getQueryPageFromUrl,
|
|
1875
|
+
xt as getQueryParamsFromUrl,
|
|
1864
1876
|
Dt as getQueryTabFromUrl,
|
|
1865
|
-
|
|
1866
|
-
|
|
1867
|
-
|
|
1868
|
-
|
|
1869
|
-
|
|
1877
|
+
Ut as getQueryTextFromUrl,
|
|
1878
|
+
Pt as getRelativeDate,
|
|
1879
|
+
Be as getTime,
|
|
1880
|
+
Z as getToken,
|
|
1881
|
+
Lt as getUrlParamsFromQueryParams,
|
|
1870
1882
|
l as globalConfig,
|
|
1871
|
-
|
|
1872
|
-
|
|
1873
|
-
|
|
1874
|
-
|
|
1875
|
-
|
|
1876
|
-
|
|
1877
|
-
|
|
1878
|
-
|
|
1879
|
-
|
|
1880
|
-
|
|
1881
|
-
|
|
1882
|
-
|
|
1883
|
-
|
|
1884
|
-
|
|
1885
|
-
|
|
1886
|
-
|
|
1887
|
-
|
|
1883
|
+
Me as guid,
|
|
1884
|
+
y as handleResponse,
|
|
1885
|
+
x as info,
|
|
1886
|
+
Xe as initializeAppConfig,
|
|
1887
|
+
Ie as isArrayBuffer,
|
|
1888
|
+
Or as isAuthenticated,
|
|
1889
|
+
Ne as isBlob,
|
|
1890
|
+
qe as isDate,
|
|
1891
|
+
Mt as isExpired,
|
|
1892
|
+
Xt as isJsonable,
|
|
1893
|
+
yt as isNotInputEvent,
|
|
1894
|
+
M as isObject,
|
|
1895
|
+
Fe as isString,
|
|
1896
|
+
ar as labels,
|
|
1897
|
+
he as legacyBooleansToAuthMode,
|
|
1898
|
+
$r as login,
|
|
1899
|
+
Ur as logout,
|
|
1888
1900
|
p as makeColumn,
|
|
1889
|
-
|
|
1890
|
-
|
|
1891
|
-
|
|
1892
|
-
|
|
1893
|
-
|
|
1894
|
-
|
|
1895
|
-
|
|
1901
|
+
qt as notify,
|
|
1902
|
+
_e as openParentNodes,
|
|
1903
|
+
F as parseText,
|
|
1904
|
+
we as parseValueAndOperatorFromItem,
|
|
1905
|
+
Le as patch,
|
|
1906
|
+
yr as patchUserProfile,
|
|
1907
|
+
Sr as patchUserSettings,
|
|
1896
1908
|
u as post,
|
|
1897
|
-
|
|
1898
|
-
|
|
1899
|
-
|
|
1900
|
-
|
|
1901
|
-
|
|
1902
|
-
|
|
1903
|
-
|
|
1909
|
+
Bt as put,
|
|
1910
|
+
L as queryParamsFromUrl,
|
|
1911
|
+
vt as removeConcept,
|
|
1912
|
+
Ct as removeConcepts,
|
|
1913
|
+
Vt as resolveToColumnName,
|
|
1914
|
+
Y as rewriteText,
|
|
1915
|
+
ct as saveUserSettings,
|
|
1904
1916
|
S as setGlobalConfig,
|
|
1905
|
-
|
|
1906
|
-
|
|
1907
|
-
|
|
1917
|
+
q as setToken,
|
|
1918
|
+
Kt as sha512,
|
|
1919
|
+
kt as suggestionsToTreeAggregationNodes,
|
|
1908
1920
|
It as sysLang,
|
|
1909
|
-
|
|
1910
|
-
|
|
1911
|
-
|
|
1912
|
-
|
|
1913
|
-
|
|
1914
|
-
|
|
1921
|
+
ce as toDate,
|
|
1922
|
+
wt as translateAggregationToDateOptions,
|
|
1923
|
+
lt as tryOAuthAuthentication,
|
|
1924
|
+
ut as trySAMLAuthentication,
|
|
1925
|
+
N as warn,
|
|
1926
|
+
Qt as withRetry
|
|
1915
1927
|
};
|