@arcgis/portal-components 5.2.0-next.3 → 5.2.0-next.31
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/cdn/25UUUQAQ.js +71 -0
- package/dist/cdn/2MV6L7TF.js +2 -0
- package/dist/cdn/2XILGLOG.js +2 -0
- package/dist/cdn/{AQWTJKUH.js → 3MQIRMUM.js} +9 -7
- package/dist/cdn/3XVBYE54.js +2 -0
- package/dist/cdn/3ZYTCYNE.js +2 -0
- package/dist/cdn/{LAFNDBTQ.js → 43IIAMZ3.js} +1 -1
- package/dist/cdn/{QNUYUNEY.js → 4YGBHWHG.js} +1 -1
- package/dist/cdn/5H4VCRNA.js +2 -0
- package/dist/cdn/6AGZRMJC.js +2 -0
- package/dist/cdn/6KRP5D52.js +2 -0
- package/dist/cdn/6W2IHKCA.js +2 -0
- package/dist/cdn/{LQ3DMZ3K.js → 6XWNBD36.js} +1 -1
- package/dist/cdn/7355NM43.js +2 -0
- package/dist/cdn/7LC4ZEXB.js +2 -0
- package/dist/cdn/ADC752YM.js +2 -0
- package/dist/cdn/AX5KYSWU.js +2 -0
- package/dist/cdn/BTYTNPSM.js +2 -0
- package/dist/cdn/BUPFZ5MT.js +2 -0
- package/dist/cdn/DFTUMKSN.js +3 -0
- package/dist/cdn/DWPIXEWQ.js +2 -0
- package/dist/cdn/E67OMPRM.js +2 -0
- package/dist/cdn/ECNI2A4K.js +2 -0
- package/dist/cdn/EIOSA4DR.js +2 -0
- package/dist/cdn/EZ3BR2FP.js +134 -0
- package/dist/cdn/G2YAOSMT.js +2 -0
- package/dist/cdn/G6YH7AFY.js +2 -0
- package/dist/cdn/GNBMYDRC.js +2 -0
- package/dist/cdn/H6QISDOR.js +2 -0
- package/dist/cdn/HA2J6NDT.js +2 -0
- package/dist/cdn/HMBSJR37.js +2 -0
- package/dist/cdn/HVF4Z3VA.js +2 -0
- package/dist/cdn/{V2EOXGK2.js → I234NUZ5.js} +1 -1
- package/dist/cdn/IILAKXVC.js +65 -0
- package/dist/cdn/J2KLHUBJ.js +2 -0
- package/dist/cdn/JEXN44WM.js +2 -0
- package/dist/cdn/KDDYAFAF.js +637 -0
- package/dist/cdn/{ZTHTFEYA.js → KPEWVVE5.js} +1 -1
- package/dist/cdn/MM6SCKYE.js +2 -0
- package/dist/cdn/NWIIOJEG.js +2 -0
- package/dist/cdn/NZVLEDFZ.js +2 -0
- package/dist/cdn/OU2AR22N.js +3 -0
- package/dist/cdn/Q22FWLJZ.js +2 -0
- package/dist/cdn/QUEBM77K.js +2 -0
- package/dist/cdn/QUMJ5FTJ.js +2 -0
- package/dist/cdn/S5XNEB7F.js +99 -0
- package/dist/cdn/S745KWLM.js +34 -0
- package/dist/cdn/{GT26WGJS.js → SXZRHHXC.js} +1 -1
- package/dist/cdn/T6JAFB2A.js +2 -0
- package/dist/cdn/{72N3KAXN.js → TW4LFQA5.js} +1 -1
- package/dist/cdn/U3FVMN32.js +2 -0
- package/dist/cdn/ULD747OT.js +22 -0
- package/dist/cdn/{7WZHZP6U.js → UR7W4CEV.js} +8 -2
- package/dist/cdn/V7LZAIB6.js +2 -0
- package/dist/cdn/{W6PSG4GX.js → VRXKORTR.js} +9 -4
- package/dist/cdn/VSAH76S7.js +2 -0
- package/dist/cdn/{2UUZHENH.js → WSNLUGEP.js} +1 -1
- package/dist/cdn/{53MSUMA3.js → XCZSPNKS.js} +16 -0
- package/dist/cdn/{WOZDQW3S.js → XHM6I6YG.js} +1 -1
- package/dist/cdn/XNZQ5PXA.js +2 -0
- package/dist/cdn/YCAVVVZV.js +2 -0
- package/dist/cdn/YHXXIHQA.js +2 -0
- package/dist/cdn/Z2ZUXONU.js +2 -0
- package/dist/cdn/{DHHSKOUY.js → ZZ4DR3HN.js} +1 -1
- package/dist/cdn/assets/portal-browser/t9n/messages.en.json +1 -0
- package/dist/cdn/assets/portal-group-badges/t9n/messages.en.json +1 -0
- package/dist/cdn/assets/portal-group-card/t9n/messages.en.json +1 -0
- package/dist/cdn/assets/portal-item-type/icons/parquetfeaturelayer16.svg +1 -0
- package/dist/cdn/assets/portal-item-type/icons/parquetfeaturelayer32.svg +1 -0
- package/dist/cdn/assets/portal-item-type/icons/storymapframe16.svg +1 -0
- package/dist/cdn/assets/portal-item-type/icons/storymapframe32.svg +1 -0
- package/dist/cdn/assets/portal-item-type/t9n/messages.en.json +1 -1
- package/dist/cdn/assets/portal-user-popup/t9n/messages.en.json +1 -0
- package/dist/cdn/index.js +1 -1
- package/dist/cdn/main.css +1 -1
- package/dist/chunks/dom.js +36 -0
- package/dist/chunks/functionalities.js +5 -4
- package/dist/chunks/groups.js +7 -83
- package/dist/chunks/item2.js +86 -0
- package/dist/chunks/portal.js +48 -8
- package/dist/chunks/store.js +18 -0
- package/dist/chunks/ui.js +10 -0
- package/dist/chunks/user2.js +26 -25
- package/dist/components/arcgis-portal-ai-assistant/agents/types.d.ts +11 -2
- package/dist/components/arcgis-portal-ai-assistant/customElement.d.ts +4 -2
- package/dist/components/arcgis-portal-ai-assistant/customElement.js +797 -488
- package/dist/components/arcgis-portal-ai-assistant-interrupt/customElement.js +10 -10
- package/dist/components/arcgis-portal-browser/customElement.d.ts +235 -0
- package/dist/components/arcgis-portal-browser/customElement.js +201 -0
- package/dist/components/arcgis-portal-browser/index.d.ts +1 -0
- package/dist/components/arcgis-portal-browser/index.js +6 -0
- package/dist/components/arcgis-portal-browser/utils/store.d.ts +31 -0
- package/dist/components/arcgis-portal-browser/utils/types.d.ts +18 -0
- package/dist/components/arcgis-portal-browser-actions/customElement.d.ts +187 -0
- package/dist/components/arcgis-portal-browser-actions/customElement.js +70 -0
- package/dist/components/arcgis-portal-browser-actions/index.d.ts +1 -0
- package/dist/components/arcgis-portal-browser-actions/index.js +6 -0
- package/dist/components/arcgis-portal-browser-actions/types.d.ts +9 -0
- package/dist/components/arcgis-portal-browser-filter/customElement.d.ts +226 -0
- package/dist/components/arcgis-portal-browser-filter/customElement.js +32 -0
- package/dist/components/arcgis-portal-browser-filter/index.d.ts +1 -0
- package/dist/components/arcgis-portal-browser-filter/index.js +4 -0
- package/dist/components/arcgis-portal-browser-filter-date/customElement.d.ts +233 -0
- package/dist/components/arcgis-portal-browser-filter-date/customElement.js +117 -0
- package/dist/components/arcgis-portal-browser-filter-date/index.d.ts +1 -0
- package/dist/components/arcgis-portal-browser-filter-date/index.js +5 -0
- package/dist/components/arcgis-portal-browser-filter-status/customElement.d.ts +193 -0
- package/dist/components/arcgis-portal-browser-filter-status/customElement.js +56 -0
- package/dist/components/arcgis-portal-browser-filter-status/index.d.ts +1 -0
- package/dist/components/arcgis-portal-browser-filter-status/index.js +5 -0
- package/dist/components/arcgis-portal-browser-filters/customElement.d.ts +7 -0
- package/dist/components/arcgis-portal-browser-filters/customElement.js +29 -0
- package/dist/components/arcgis-portal-browser-filters/index.d.ts +1 -0
- package/dist/components/arcgis-portal-browser-filters/index.js +2 -0
- package/dist/components/arcgis-portal-browser-pagination/customElement.d.ts +194 -0
- package/dist/components/arcgis-portal-browser-pagination/customElement.js +51 -0
- package/dist/components/arcgis-portal-browser-pagination/index.d.ts +1 -0
- package/dist/components/arcgis-portal-browser-pagination/index.js +2 -0
- package/dist/components/arcgis-portal-browser-search/customElement.d.ts +195 -0
- package/dist/components/arcgis-portal-browser-search/customElement.js +65 -0
- package/dist/components/arcgis-portal-browser-search/index.d.ts +1 -0
- package/dist/components/arcgis-portal-browser-search/index.js +3 -0
- package/dist/components/arcgis-portal-browser-sort/customElement.d.ts +196 -0
- package/dist/components/arcgis-portal-browser-sort/customElement.js +93 -0
- package/dist/components/arcgis-portal-browser-sort/index.d.ts +1 -0
- package/dist/components/arcgis-portal-browser-sort/index.js +9 -0
- package/dist/components/arcgis-portal-browser-sort/utils.d.ts +3 -0
- package/dist/components/arcgis-portal-browser-top-bar/customElement.d.ts +184 -0
- package/dist/components/arcgis-portal-browser-top-bar/customElement.js +51 -0
- package/dist/components/arcgis-portal-browser-top-bar/index.d.ts +1 -0
- package/dist/components/arcgis-portal-browser-top-bar/index.js +3 -0
- package/dist/components/arcgis-portal-browser-view/customElement.d.ts +21 -0
- package/dist/components/arcgis-portal-browser-view/customElement.js +30 -0
- package/dist/components/arcgis-portal-browser-view/index.d.ts +1 -0
- package/dist/components/arcgis-portal-browser-view/index.js +5 -0
- package/dist/components/arcgis-portal-group-badges/customElement.d.ts +102 -0
- package/dist/components/arcgis-portal-group-badges/customElement.js +50 -0
- package/dist/components/arcgis-portal-group-badges/index.d.ts +1 -0
- package/dist/components/arcgis-portal-group-badges/index.js +3 -0
- package/dist/components/arcgis-portal-group-badges/types.d.ts +3 -0
- package/dist/components/arcgis-portal-group-card/customElement.d.ts +167 -0
- package/dist/components/arcgis-portal-group-card/customElement.js +183 -0
- package/dist/components/arcgis-portal-group-card/index.d.ts +1 -0
- package/dist/components/arcgis-portal-group-card/index.js +8 -0
- package/dist/components/arcgis-portal-group-thumbnail/customElement.d.ts +32 -0
- package/dist/components/arcgis-portal-group-thumbnail/customElement.js +153 -0
- package/dist/components/arcgis-portal-group-thumbnail/index.d.ts +1 -0
- package/dist/components/arcgis-portal-group-thumbnail/index.js +3 -0
- package/dist/components/arcgis-portal-item-type/customElement.d.ts +2 -0
- package/dist/components/arcgis-portal-item-type/customElement.js +45 -37
- package/dist/components/arcgis-portal-mentionable-text-area/customElement.js +1 -1
- package/dist/components/arcgis-portal-replacement-item-redirect/customElement.js +53 -42
- package/dist/components/arcgis-portal-user-popup/customElement.d.ts +111 -0
- package/dist/components/arcgis-portal-user-popup/customElement.js +224 -0
- package/dist/components/arcgis-portal-user-popup/index.d.ts +1 -0
- package/dist/components/arcgis-portal-user-popup/index.js +5 -0
- package/dist/components/arcgis-portal-voice-input/customElement.d.ts +1 -1
- package/dist/docs/api.json +1 -1
- package/dist/docs/docs.json +1 -1
- package/dist/docs/vscode.html-custom-data.json +1 -1
- package/dist/docs/web-types.json +1 -1
- package/dist/index.d.ts +122 -2
- package/dist/loader.js +19 -4
- package/dist/types/group.d.ts +13 -13
- package/dist/types/item.d.ts +77 -2
- package/dist/types/lumina.d.ts +93 -1
- package/dist/types/preact.d.ts +108 -1
- package/dist/types/react.d.ts +123 -1
- package/dist/types/search.d.ts +27 -0
- package/dist/types/stencil.d.ts +93 -1
- package/dist/types/tracking.d.ts +10 -0
- package/dist/types/user.d.ts +2 -2
- package/package.json +7 -7
- package/dist/cdn/5DPWJ7DI.js +0 -2
- package/dist/cdn/5VSDGPHH.js +0 -2
- package/dist/cdn/ANPXRYLV.js +0 -5
- package/dist/cdn/BEHLBKKM.js +0 -2
- package/dist/cdn/CI5ENGVT.js +0 -2
- package/dist/cdn/EVDOPN3G.js +0 -54
- package/dist/cdn/G47ZZQYL.js +0 -2
- package/dist/cdn/GAHILDQF.js +0 -45
- package/dist/cdn/GHQ3ZW4U.js +0 -2
- package/dist/cdn/GNOZCQ34.js +0 -2
- package/dist/cdn/JNRN6DTV.js +0 -2
- package/dist/cdn/K3HS2LQ7.js +0 -2
- package/dist/cdn/KEKBRUUC.js +0 -2
- package/dist/cdn/N6G6Z7BF.js +0 -516
- package/dist/cdn/OQDPULPD.js +0 -2
- package/dist/cdn/RNLVNDGG.js +0 -2
- package/dist/cdn/SM4GWLRA.js +0 -66
- package/dist/cdn/TMYTUOSS.js +0 -2
- package/dist/cdn/YG5YYL6X.js +0 -2
- package/dist/cdn/YL7PGYWC.js +0 -5
- package/dist/cdn/YMPTDKT6.js +0 -2
- /package/dist/cdn/{B7633S2A.js → 5NIJVBS7.js} +0 -0
package/dist/chunks/portal.js
CHANGED
|
@@ -1,16 +1,56 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
-
const
|
|
3
|
-
function
|
|
4
|
-
return
|
|
2
|
+
const s = (e) => e && !e.endsWith("/") ? `${e}/` : e;
|
|
3
|
+
function i(e) {
|
|
4
|
+
return s(e.restUrl);
|
|
5
5
|
}
|
|
6
|
-
function
|
|
6
|
+
function p(e) {
|
|
7
7
|
return e.credential?.token || e.token || e.user?.credential?.token || e.portalUser?.token || "";
|
|
8
8
|
}
|
|
9
|
-
function
|
|
9
|
+
function c(e) {
|
|
10
10
|
return e.sourceJSON?.isWebTierAuth;
|
|
11
11
|
}
|
|
12
|
+
function a(e, r, t) {
|
|
13
|
+
if (!r?.type)
|
|
14
|
+
return !1;
|
|
15
|
+
const n = r.typeKeywords ?? [];
|
|
16
|
+
switch (e) {
|
|
17
|
+
case "arcgisinstantapps":
|
|
18
|
+
return r.type === "Web Mapping Application" && n.includes("configurableApp");
|
|
19
|
+
case "arcgis360vr":
|
|
20
|
+
return !t && r.type === "360 VR Experience";
|
|
21
|
+
case "survey123":
|
|
22
|
+
return r.type === "Form";
|
|
23
|
+
case "datapipelines":
|
|
24
|
+
return r.type === "Data Pipeline";
|
|
25
|
+
case "dashboards":
|
|
26
|
+
return r.type === "Dashboard";
|
|
27
|
+
case "experienceBuilder":
|
|
28
|
+
return r.type === "Web Experience" || r.type === "Web Experience Template";
|
|
29
|
+
case "webappbuilder":
|
|
30
|
+
return r.type === "Web Mapping Application" && (n.includes("Web AppBuilder") || n.includes("WebAppBuilder"));
|
|
31
|
+
case "fieldmaps":
|
|
32
|
+
return r.type === "Web Map";
|
|
33
|
+
case "arcgisnotebooks":
|
|
34
|
+
return r.type === "Notebook";
|
|
35
|
+
case "HubforArcGIS":
|
|
36
|
+
return [
|
|
37
|
+
"Discussion",
|
|
38
|
+
"Hub Page",
|
|
39
|
+
"Hub Initiative Template",
|
|
40
|
+
"Hub Initiative",
|
|
41
|
+
"Hub Event",
|
|
42
|
+
"Hub Project"
|
|
43
|
+
].includes(r.type);
|
|
44
|
+
default:
|
|
45
|
+
return !1;
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
function u(e, r, t) {
|
|
49
|
+
return (r ?? []).some((n) => a(n, e, t));
|
|
50
|
+
}
|
|
12
51
|
export {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
i
|
|
52
|
+
p as a,
|
|
53
|
+
u as b,
|
|
54
|
+
i as g,
|
|
55
|
+
c as i
|
|
16
56
|
};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
+
import { watch as o } from "@arcgis/core/core/reactiveUtils.js";
|
|
3
|
+
import { createStore as s } from "@arcgis/lumina/controllers/accessor";
|
|
4
|
+
const a = ["folder", "group", "contentType"], c = (e) => e.type === "item-browser", m = (e = {}) => s({
|
|
5
|
+
filters: {},
|
|
6
|
+
hiddenFilters: [],
|
|
7
|
+
...e
|
|
8
|
+
});
|
|
9
|
+
function l(e, r) {
|
|
10
|
+
const t = o(() => e.preview, r);
|
|
11
|
+
return () => t.remove();
|
|
12
|
+
}
|
|
13
|
+
export {
|
|
14
|
+
c as a,
|
|
15
|
+
m as c,
|
|
16
|
+
a as i,
|
|
17
|
+
l as o
|
|
18
|
+
};
|
package/dist/chunks/user2.js
CHANGED
|
@@ -3,28 +3,28 @@ import { i as C, a as b, g as w } from "./portal.js";
|
|
|
3
3
|
import E from "@arcgis/core/identity/IdentityManager.js";
|
|
4
4
|
import A from "@arcgis/core/request.js";
|
|
5
5
|
const u = {}, f = {}, l = {};
|
|
6
|
-
async function p({ requester: t, key: e, id:
|
|
7
|
-
const r = l[e]?.[
|
|
8
|
-
if (u[e]?.[
|
|
9
|
-
return u[e][
|
|
10
|
-
f[e] || (f[e] = {}), (!f[e][
|
|
11
|
-
const o = await f[e][
|
|
12
|
-
if (u[e] || (u[e] = {}), l[e] || (l[e] = {}), u[e][
|
|
13
|
-
const { expireAfter: a, getExpireAfterFromResult: c } =
|
|
14
|
-
l[e][
|
|
6
|
+
async function p({ requester: t, key: e, id: s, cacheOption: n }) {
|
|
7
|
+
const r = l[e]?.[s]?.expireAt, i = !!r && (/* @__PURE__ */ new Date()).getTime() > r;
|
|
8
|
+
if (u[e]?.[s] && !i)
|
|
9
|
+
return u[e][s];
|
|
10
|
+
f[e] || (f[e] = {}), (!f[e][s] || i) && (f[e][s] = t());
|
|
11
|
+
const o = await f[e][s];
|
|
12
|
+
if (u[e] || (u[e] = {}), l[e] || (l[e] = {}), u[e][s] = o, n) {
|
|
13
|
+
const { expireAfter: a, getExpireAfterFromResult: c } = n, h = c || a ? (/* @__PURE__ */ new Date()).getTime() + (c?.(o) ?? a ?? 0) : null;
|
|
14
|
+
l[e][s] = { ...l[e][s], expireAt: h };
|
|
15
15
|
}
|
|
16
16
|
return o;
|
|
17
17
|
}
|
|
18
18
|
async function x({
|
|
19
19
|
url: t,
|
|
20
20
|
portal: e,
|
|
21
|
-
params:
|
|
22
|
-
options:
|
|
21
|
+
params: s = {},
|
|
22
|
+
options: n = {},
|
|
23
23
|
method: r,
|
|
24
24
|
abortControllerId: i,
|
|
25
25
|
excludeJson: o
|
|
26
26
|
}) {
|
|
27
|
-
const a = R(i)?.signal, { customToken: c, addTokenManually: h, addSSL: P, useProxy: S } =
|
|
27
|
+
const a = R(i)?.signal, { customToken: c, addTokenManually: h, addSSL: P, useProxy: S } = n, m = { ...s };
|
|
28
28
|
if (!t.includes("f=") && !o && (m.f = "json"), c)
|
|
29
29
|
m.token = c;
|
|
30
30
|
else if (h !== !1) {
|
|
@@ -34,10 +34,10 @@ async function x({
|
|
|
34
34
|
const T = P ? U(t, e) : t, q = {
|
|
35
35
|
query: m,
|
|
36
36
|
method: r || "auto",
|
|
37
|
-
...
|
|
38
|
-
timeout:
|
|
37
|
+
...n,
|
|
38
|
+
timeout: n.timeout || 0,
|
|
39
39
|
useProxy: S,
|
|
40
|
-
...
|
|
40
|
+
...n?.disableIdentityLookup ? { authMode: "anonymous" } : {}
|
|
41
41
|
}, y = await A(T, { signal: a, ...q });
|
|
42
42
|
return i && (d[i] = void 0), y.data;
|
|
43
43
|
}
|
|
@@ -50,24 +50,24 @@ const $ = async (t) => {
|
|
|
50
50
|
const e = C(t);
|
|
51
51
|
if (!t?.isPortal || !e)
|
|
52
52
|
return b(t);
|
|
53
|
-
const
|
|
54
|
-
if (!
|
|
53
|
+
const s = t?.user;
|
|
54
|
+
if (!s && e)
|
|
55
55
|
return;
|
|
56
|
-
const { token:
|
|
56
|
+
const { token: n } = await p({
|
|
57
57
|
requester: async () => await L(t),
|
|
58
58
|
key: "platformSelf",
|
|
59
|
-
id:
|
|
59
|
+
id: s?.id ?? t.id ?? "<unknown>",
|
|
60
60
|
cacheOption: { getExpireAfterFromResult: (r) => r.expires_in }
|
|
61
61
|
});
|
|
62
|
-
return
|
|
62
|
+
return n;
|
|
63
63
|
}, L = async (t) => {
|
|
64
|
-
const
|
|
64
|
+
const s = {
|
|
65
65
|
"X-Esri-Auth-Client-Id": await M(t),
|
|
66
66
|
"X-Esri-Auth-Redirect-Uri": window.location.href.replace(/#.*$/u, "")
|
|
67
67
|
};
|
|
68
68
|
return (await A(`${w(t)}/oauth2/platformSelf`, {
|
|
69
69
|
authMode: "no-prompt",
|
|
70
|
-
headers:
|
|
70
|
+
headers: s,
|
|
71
71
|
withCredentials: !0,
|
|
72
72
|
method: "post"
|
|
73
73
|
})).data;
|
|
@@ -79,8 +79,8 @@ const $ = async (t) => {
|
|
|
79
79
|
function U(t, e) {
|
|
80
80
|
return window.location.protocol === "https:" || e.allSSL ? t.replace("http:", "https:") : t;
|
|
81
81
|
}
|
|
82
|
-
async function B(t, e,
|
|
83
|
-
const r = `${
|
|
82
|
+
async function B(t, e, s) {
|
|
83
|
+
const r = `${s ? "https://www.arcgis.com/sharing/rest/" : w(e)}community/users/${t}`, i = r?.includes("www.arcgis.com") && e.isPortal, o = r?.includes(".arcgis.com") && !e.isPortal && !e.user, a = i || o ? { disableIdentityLookup: !0, addTokenManually: !1 } : {};
|
|
84
84
|
return await p({
|
|
85
85
|
requester: async () => {
|
|
86
86
|
try {
|
|
@@ -109,5 +109,6 @@ const k = async (t) => {
|
|
|
109
109
|
export {
|
|
110
110
|
p as a,
|
|
111
111
|
k as b,
|
|
112
|
-
B as f
|
|
112
|
+
B as f,
|
|
113
|
+
x as r
|
|
113
114
|
};
|
|
@@ -1,7 +1,16 @@
|
|
|
1
|
-
export type
|
|
1
|
+
export type PortalNavigationTarget = { destinationType: "portal-content"; } | {
|
|
2
2
|
destinationType: "portal-group";
|
|
3
3
|
groupId: string;
|
|
4
4
|
} | { destinationType: "portal-groups"; } | {
|
|
5
5
|
destinationType: "portal-item";
|
|
6
6
|
itemId: string;
|
|
7
|
-
};
|
|
7
|
+
};
|
|
8
|
+
|
|
9
|
+
export type PartialPortalNavigationTargetMap = Partial<PortalNavigationTargetMap>;
|
|
10
|
+
|
|
11
|
+
export interface PortalNavigationTargetMap {
|
|
12
|
+
"portal-content": string;
|
|
13
|
+
"portal-groups": string;
|
|
14
|
+
"portal-item": (itemId: string) => string;
|
|
15
|
+
"portal-group": (groupId: string) => string;
|
|
16
|
+
}
|
|
@@ -3,7 +3,7 @@ import type Portal from "@arcgis/core/portal/Portal.js";
|
|
|
3
3
|
import type PortalUser from "@arcgis/core/portal/PortalUser.js";
|
|
4
4
|
import type { Config } from "@arcgis/core/config.js";
|
|
5
5
|
import type { PublicLitElement as LitElement } from "@arcgis/lumina";
|
|
6
|
-
import type {
|
|
6
|
+
import type { PartialPortalNavigationTargetMap, PortalNavigationTarget } from "./agents/types.js";
|
|
7
7
|
import type { T9nMeta } from "@arcgis/lumina/controllers";
|
|
8
8
|
|
|
9
9
|
/** @internal */
|
|
@@ -13,6 +13,8 @@ export abstract class ArcgisPortalAiAssistant extends LitElement {
|
|
|
13
13
|
accessor config: Config;
|
|
14
14
|
/** @default false */
|
|
15
15
|
accessor defaultClosed: boolean;
|
|
16
|
+
/** Optional map of navigation target overrides for generating navigation hrefs from portal navigation suggestions. */
|
|
17
|
+
accessor navigationTargetMap: PartialPortalNavigationTargetMap | undefined;
|
|
16
18
|
accessor portal: Portal;
|
|
17
19
|
/** @internal */
|
|
18
20
|
protected t9n: {
|
|
@@ -113,7 +115,7 @@ export abstract class ArcgisPortalAiAssistant extends LitElement {
|
|
|
113
115
|
accessor user: PortalUser;
|
|
114
116
|
readonly arcgisPortalNavigationRequest: import("@arcgis/lumina").TargetedEvent<this, {
|
|
115
117
|
href: string;
|
|
116
|
-
targetDetail:
|
|
118
|
+
targetDetail: PortalNavigationTarget;
|
|
117
119
|
}>;
|
|
118
120
|
readonly "@eventTypes": {
|
|
119
121
|
arcgisPortalNavigationRequest: ArcgisPortalAiAssistant["arcgisPortalNavigationRequest"]["detail"];
|