@arcgis/portal-components 5.2.0-next.87 → 5.2.0-next.89

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.
@@ -5,6 +5,11 @@ import type { PortalBrowserState } from "../arcgis-portal-browser/utils/store.js
5
5
  import type { BrowserPageDetail } from "../arcgis-portal-browser/utils/types.js";
6
6
  import type { PortalGroupCardProps, PortalGroupCardSlotType } from "../arcgis-portal-group-card/customElement.js";
7
7
 
8
+ export interface PortalGroupBrowserSearchParamInteraction {
9
+ read?: boolean;
10
+ write?: boolean;
11
+ }
12
+
8
13
  export interface PortalGroupBrowserFiltersConfig {
9
14
  created?: GroupFilterConfig<PortalGroupBrowserDateFilterProps>;
10
15
  modified?: GroupFilterConfig<PortalGroupBrowserDateFilterProps>;
@@ -8,18 +8,18 @@ import { g as oe, b as xe } from "../../chunks/url.js";
8
8
  import { a as B } from "../../chunks/requests.js";
9
9
  import { repeat as U } from "lit/directives/repeat.js";
10
10
  import { m as Pt } from "../../chunks/icons.js";
11
- import { i as M, c as me, a as Tt } from "../../chunks/user2.js";
12
- import { c as Nt, d as Ct, e as Mt, f as Lt, h as Ot } from "../../chunks/portal2.js";
11
+ import { i as M, c as me, a as Ct } from "../../chunks/user2.js";
12
+ import { c as Tt, d as Nt, e as Mt, f as Lt, h as Ot } from "../../chunks/portal2.js";
13
13
  import { c as Et, d as jt, e as Dt } from "../../chunks/user.js";
14
14
  import { i as Se, a as zt } from "../../chunks/utils2.js";
15
15
  import { g as Gt } from "../../chunks/request.js";
16
16
  import { g as Ie } from "../../chunks/item.js";
17
17
  import { keyed as se } from "lit/directives/keyed.js";
18
18
  import { e as ae, n as Ut, a as ce, f as q, g as Bt } from "../../chunks/portal.js";
19
- import { ref as R, createRef as W } from "lit/directives/ref.js";
20
- import { c as Ft, g as Wt } from "../../chunks/dom.js";
19
+ import { ref as W, createRef as F } from "lit/directives/ref.js";
20
+ import { c as Rt, g as Ft } from "../../chunks/dom.js";
21
21
  import { debounce as fe } from "@arcgis/toolkit/function";
22
- import Rt from "@arcgis/core/identity/IdentityManager.js";
22
+ import Wt from "@arcgis/core/identity/IdentityManager.js";
23
23
  import { t as Vt } from "../../chunks/functionalities.js";
24
24
  import { c as Ht } from "../../chunks/string.js";
25
25
  function ge({ portal: e, productInfo: t }) {
@@ -32,7 +32,7 @@ function qt({ navigate: e, portal: t, product: i, productInfo: n, productHref: r
32
32
  e({ event: m, href: r });
33
33
  }} class="logo fade-in logo--link">${ge({ portal: t, productInfo: n })}</a>` : c`<div class="logo fade-in">${ge({ portal: t, productInfo: n })}</div>`;
34
34
  }
35
- const Y = {}, C = {
35
+ const Y = {}, N = {
36
36
  Month: 2628e3,
37
37
  Week: 604800,
38
38
  Day: 86400,
@@ -43,31 +43,31 @@ const Y = {}, C = {
43
43
  function Pe(e) {
44
44
  if (!e)
45
45
  return null;
46
- const t = Math.floor(e / 1e3), i = Math.abs(t), n = C.Day * 365;
46
+ const t = Math.floor(e / 1e3), i = Math.abs(t), n = N.Day * 365;
47
47
  switch (!0) {
48
- case i < C.Minute:
49
- return [Math.floor(t / C.Second), "second"];
50
- case i < C.Hour:
51
- return [Math.floor(t / C.Minute), "minute"];
52
- case i < C.Day:
53
- return [Math.floor(t / C.Hour), "hour"];
54
- case i < C.Week:
55
- return [Math.floor(t / C.Day), "day"];
56
- case i < C.Month:
57
- return [Math.floor(t / C.Week), "week"];
48
+ case i < N.Minute:
49
+ return [Math.floor(t / N.Second), "second"];
50
+ case i < N.Hour:
51
+ return [Math.floor(t / N.Minute), "minute"];
52
+ case i < N.Day:
53
+ return [Math.floor(t / N.Hour), "hour"];
54
+ case i < N.Week:
55
+ return [Math.floor(t / N.Day), "day"];
56
+ case i < N.Month:
57
+ return [Math.floor(t / N.Week), "week"];
58
58
  case i < n:
59
- return [Math.floor(t / C.Month), "month"];
59
+ return [Math.floor(t / N.Month), "month"];
60
60
  default:
61
61
  return [Math.floor(t / n), "year"];
62
62
  }
63
63
  }
64
- function Te(e) {
64
+ function Ce(e) {
65
65
  return (typeof e == "number" ? e : e.getTime?.()) - (/* @__PURE__ */ new Date()).getTime();
66
66
  }
67
- function Ne({ locale: e, time: t, t9n: i }) {
67
+ function Te({ locale: e, time: t, t9n: i }) {
68
68
  if (!e || !t)
69
69
  return "";
70
- const n = Te(t);
70
+ const n = Ce(t);
71
71
  Y[e] ??= new Intl.RelativeTimeFormat(e, { style: "long" });
72
72
  const r = Pe(n);
73
73
  return r ? r[1] === "second" ? i?.lessThanOneMinute || `< ${Y[e].format(r[0] > 0 ? 1 : -1, "minutes")}` : Y[e].format(r[0], r[1]) : "";
@@ -95,10 +95,10 @@ async function Xt({ portal: e }) {
95
95
  async function Yt(e, t) {
96
96
  if (!e?.user)
97
97
  return { success: !0 };
98
- const i = t.map((o) => ({ portal: e, id: o })).map(Ce);
98
+ const i = t.map((o) => ({ portal: e, id: o })).map(Ne);
99
99
  return { success: !((await Promise.allSettled(i))?.filter((o) => o.status === "rejected" || !o.value?.success)).length };
100
100
  }
101
- async function Ce({
101
+ async function Ne({
102
102
  portal: e,
103
103
  id: t
104
104
  }) {
@@ -177,7 +177,7 @@ function ti({
177
177
  }) {
178
178
  if (e?.received && e.id) {
179
179
  const r = {
180
- date: Ne({ locale: i, time: e.received, t9n: n }),
180
+ date: Te({ locale: i, time: e.received, t9n: n }),
181
181
  id: e.id,
182
182
  text: "",
183
183
  icon: ei(e.type)
@@ -567,7 +567,7 @@ function G(e, t, i) {
567
567
  function Oe() {
568
568
  return `${V()}svg-app-circle.svg`;
569
569
  }
570
- function Ti(e, t, i) {
570
+ function Ci(e, t, i) {
571
571
  const n = e.properties?.appSwitcher?.image || e.icon;
572
572
  return {
573
573
  abbr: e.properties?.appSwitcher?.abbr || e.abbreviation,
@@ -580,7 +580,7 @@ function Ti(e, t, i) {
580
580
  placeHolderIcon: e.placeHolderIcon || Oe()
581
581
  };
582
582
  }
583
- function Ni(e, t, i) {
583
+ function Ti(e, t, i) {
584
584
  return e.appSwitcher?.image || e.icon ? e.image = Le(e, t, i) : e.placeHolderIcon = Oe(), e.abbr = e.appSwitcher?.abbr || e.abbreviation, delete e.abbreviation, delete e.appSwitcher, delete e.approvedApp, delete e.webMappingApp, e;
585
585
  }
586
586
  function _e(e, t) {
@@ -588,7 +588,7 @@ function _e(e, t) {
588
588
  i.uid === "Map Viewer Beta" && (i.uid = "Map Viewer"), t.isPortal && (i.uid === "Operations Dashboard for ArcGIS" ? i.uid = "ArcGIS Dashboards Classic" : i.uid === "Workforce for ArcGIS" && (i.uid = "ArcGIS Workforce"));
589
589
  });
590
590
  }
591
- async function Ci({
591
+ async function Ni({
592
592
  userApps: e,
593
593
  servers: t,
594
594
  portal: i,
@@ -604,7 +604,7 @@ async function Ci({
604
604
  const g = {}, p = {}, $ = Ii(i, l, a, n), y = Pi(i), w = [], I = e.length;
605
605
  for (let h = 0; h < I; h++) {
606
606
  const u = e[h], v = u.itemId || u.title;
607
- let T = !0;
607
+ let C = !0;
608
608
  const _ = !u.serverFunction || t?.some((x) => (x.serverFunction?.split(",") || []).includes(u.serverFunction)), b = r?.some(
609
609
  (x) => u.itemId && u.itemId === x.itemid || u.title && u.title === x.title
610
610
  );
@@ -613,9 +613,9 @@ async function Ci({
613
613
  const k = u.title;
614
614
  if ($[k] && !$[k]?.hasAccess())
615
615
  continue;
616
- const N = i.sourceJSON?.subscriptionInfo;
616
+ const T = i.sourceJSON?.subscriptionInfo;
617
617
  if (u.subscriptionType) {
618
- N?.type === u.subscriptionType && (p[v].canAccess = !0, w.push(G(u, v, i)));
618
+ T?.type === u.subscriptionType && (p[v].canAccess = !0, w.push(G(u, v, i)));
619
619
  continue;
620
620
  }
621
621
  if (u.orgCapabilities) {
@@ -633,15 +633,15 @@ async function Ci({
633
633
  if (u.privileges?.length && i.user?.privileges) {
634
634
  for (let x = 0; x < u.privileges.length; x++)
635
635
  if (!i.user.privileges.includes(u.privileges[x])) {
636
- T = !1;
636
+ C = !1;
637
637
  break;
638
638
  }
639
- if (!u.isLicensed && T && _) {
639
+ if (!u.isLicensed && C && _) {
640
640
  p[v].canAccess = !0, w.push(G(u, v, i));
641
641
  continue;
642
642
  }
643
643
  }
644
- if (u.isLicensed && T && _) {
644
+ if (u.isLicensed && C && _) {
645
645
  for (let x = 0; x < o.length; x++)
646
646
  if (v === o[x].itemId || v === o[x].title) {
647
647
  p[v].canAccess = !0, w.push(G(u, v, i));
@@ -652,7 +652,7 @@ async function Ci({
652
652
  const P = await Gt(i);
653
653
  return o.forEach((h) => {
654
654
  if (h.type === "Web Mapping Application" && !y[h.clientId] && !g[h.itemId] && h.url && h.title && !g[h.title] && !h.typeKeywords.includes("hideFromAppSwitcher")) {
655
- const u = Ti(h, i, P);
655
+ const u = Ci(h, i, P);
656
656
  p[h.itemId] = u, w.push(u);
657
657
  }
658
658
  }), {
@@ -665,7 +665,7 @@ async function Ci({
665
665
  approvedApp: !0,
666
666
  canAccess: !d
667
667
  };
668
- return p[h.itemId] = u, Ni(u, i, P);
668
+ return p[h.itemId] = u, Ti(u, i, P);
669
669
  }),
670
670
  ...w
671
671
  ],
@@ -698,8 +698,8 @@ async function Mi({
698
698
  hi(e),
699
699
  jt(e),
700
700
  Dt(e),
701
+ Tt(e),
701
702
  Nt(e),
702
- Ct(e),
703
703
  Mt(e),
704
704
  fi(e)
705
705
  ]), g = e.isPortal ? await Lt(e) : null, p = s?.result?.properties;
@@ -722,7 +722,7 @@ async function Mi({
722
722
  clientId: _.id
723
723
  });
724
724
  });
725
- const I = _i(d, m), { apps: P, appDictionary: f } = await Ci({
725
+ const I = _i(d, m), { apps: P, appDictionary: f } = await Ni({
726
726
  userApps: $,
727
727
  servers: g,
728
728
  portal: e,
@@ -758,10 +758,10 @@ async function Mi({
758
758
  for (const A of Object.keys(b))
759
759
  b[A].canAccess && (b[A].isNew = !0, f[A] = b[A], h.push(b[A]));
760
760
  }
761
- const v = [...h, ...u], T = u.reduce((_, b) => (b.itemId && (_[b.itemId] = !0), _), {});
761
+ const v = [...h, ...u], C = u.reduce((_, b) => (b.itemId && (_[b.itemId] = !0), _), {});
762
762
  return {
763
763
  apps: v,
764
- hiddenApps: T,
764
+ hiddenApps: C,
765
765
  signInSettings: d,
766
766
  licenses: w,
767
767
  userProperties: p
@@ -806,7 +806,7 @@ function ji({ app: e, messages: t }) {
806
806
  if (!e || !t)
807
807
  return null;
808
808
  const { title: i, itemId: n, label: r, url: o, isNew: s } = e, a = t?.descriptions?.[i] || t?.descriptions?.[r];
809
- return c`<li class="list-item"><a class="list-item__link" href=${o ?? O} target=_blank id=${n ?? O} aria-describedby=${`${n}--tooltip`}>${c`<span class="list-item__container">${Ee({ app: e })}<span class="list-item__title">${i || r}</span>${s && c`<calcite-chip scale=s class="list-item__chip" .label=${t.new}>${t.new}</calcite-chip>` || ""}</span>`}</a>${a && c`<calcite-tooltip .referenceElement=${n} placement=trailing .id=${`${n}--tooltip`} role=tooltip>${a}</calcite-tooltip>` || ""}</li>`;
809
+ return c`<li class="list-item"><a class="list-item__link" href=${o ?? O} target=_blank id=${n ?? O} aria-describedby=${`${n}--tooltip`}>${c`<span class="list-item__container">${Ee({ app: e })}<span class="list-item__title">${r || i}</span>${s && c`<calcite-chip scale=s class="list-item__chip" .label=${t.new}>${t.new}</calcite-chip>` || ""}</span>`}</a>${a && c`<calcite-tooltip .referenceElement=${n} placement=trailing .id=${`${n}--tooltip`} role=tooltip>${a}</calcite-tooltip>` || ""}</li>`;
810
810
  }
811
811
  function Di({ apps: e, appsLoading: t, appsSearchTerm: i, hiddenApps: n, messages: r, handleAppsSearch: o, handleAppReorder: s, handleAppSave: a, handleAppHide: l, handleAppDelete: d, handleAppCancel: m, handleAppEdit: g, editingApplications: p, portal: $ }) {
812
812
  if (!e || !r)
@@ -851,17 +851,17 @@ function zi({
851
851
  }) {
852
852
  if (!t || !e)
853
853
  return [];
854
- const o = e.sourceJSON?.subscriptionInfo, s = Fi({ messages: t, portal: e });
854
+ const o = e.sourceJSON?.subscriptionInfo, s = Ri({ messages: t, portal: e });
855
855
  if (!e.user)
856
856
  return s;
857
857
  if (!e || !s || e?.user && !i && !M(e))
858
858
  return [];
859
- const a = Ri({
859
+ const a = Wi({
860
860
  portal: e,
861
861
  licenses: i,
862
862
  subscriptionInfo: o
863
863
  });
864
- return Wi({ messages: t, portal: e, clientId: n, signInSettings: r, navLinkDictionary: a });
864
+ return Fi({ messages: t, portal: e, clientId: n, signInSettings: r, navLinkDictionary: a });
865
865
  }
866
866
  function Gi(e) {
867
867
  const { id: t, access: i, isPortal: n } = e;
@@ -904,7 +904,7 @@ function De({
904
904
  ...(s === "all" || s === "members" && p) && !r ? ["gallery"] : [],
905
905
  ...(l === "all" || l === "members" && p || l === "mapCreators" && me(n)) && !r ? ["map"] : [],
906
906
  ...(m === "all" || m === "members" && p || m === "sceneCreators" && me(n)) && !r ? ["scene"] : [],
907
- ...!o && (!e.isPortal || e.sourceJSON.supportsHostedNotebooks) && (d === "members" && p || d === "notebookCreators" && Tt(n)) && !r ? ["notebook"] : [],
907
+ ...!o && (!e.isPortal || e.sourceJSON.supportsHostedNotebooks) && (d === "members" && p || d === "notebookCreators" && Ct(n)) && !r ? ["notebook"] : [],
908
908
  ...(a === "all" || a === "members" && p) && !r ? ["groups"] : [],
909
909
  ...p && !r ? ["myContent", "organization"] : []
910
910
  ], g;
@@ -932,7 +932,7 @@ function Bi({
932
932
  }
933
933
  }), n;
934
934
  }
935
- function Fi({
935
+ function Ri({
936
936
  messages: e,
937
937
  portal: t
938
938
  }) {
@@ -950,7 +950,7 @@ function Fi({
950
950
  };
951
951
  return (Gi(t) ? ["overview", "pricing", "map", "scene", "help"] : De({ portal: t })).map((o) => n[o]);
952
952
  }
953
- function Wi({
953
+ function Fi({
954
954
  messages: e,
955
955
  portal: t,
956
956
  clientId: i,
@@ -980,7 +980,7 @@ function Wi({
980
980
  }
981
981
  ] : Bi({ keys: s, messages: e, navLinkDictionary: r });
982
982
  }
983
- function Ri({
983
+ function Wi({
984
984
  portal: e,
985
985
  licenses: t,
986
986
  subscriptionInfo: i
@@ -1051,20 +1051,20 @@ function Ri({
1051
1051
  function Vi({ portal: e, item: t, messages: i, navigate: n, locale: r }) {
1052
1052
  if (!t || !i || !t.modified)
1053
1053
  return null;
1054
- const o = t.modified, s = { lessThanOneMinute: i.lessThanOneMinute }, a = Pe(Te(o)), l = a?.[1] === "year" || a?.[1] === "month" ? Qt({ locale: r, time: o }, a?.[1] === "year") : Ne({ locale: r, time: o, t9n: s }), d = `item.html?id=${t.id}`, m = `${E(e)}${d}}`;
1054
+ const o = t.modified, s = { lessThanOneMinute: i.lessThanOneMinute }, a = Pe(Ce(o)), l = a?.[1] === "year" || a?.[1] === "month" ? Qt({ locale: r, time: o }, a?.[1] === "year") : Te({ locale: r, time: o, t9n: s }), d = `item.html?id=${t.id}`, m = `${E(e)}${d}}`;
1055
1055
  return se(t.id, c`<li class="list-item"><a class="list-item__link" href=${m ?? O} @click=${(g) => {
1056
1056
  n({ event: g, href: m, relativePath: d });
1057
1057
  }}>${c`<span class="list-item__container"><span class="list-item__logo list-item__logo--item-type"><arcgis-portal-item-type .item=${t} .user=${e.user} hide-text></arcgis-portal-item-type></span><span class="list-item__content"><span class="list-item__title list-item__title--regular">${t.title}</span><span class="list-item__subtitle">${K(i.lastUpdated, { date: l })}</span></span></span>`}</a></li>`);
1058
1058
  }
1059
- function Hi({ locale: e, navigate: t, portal: i, open: n, apps: r, appsLoading: o, hiddenApps: s, appsSearchTerm: a, handlePlatformClose: l, handleAppsSearch: d, handleAppReorder: m, handleAppSave: g, handleAppDelete: p, handleAppHide: $, handleAppCancel: y, handleAppEdit: w, handleItemSearch: I, editingApplications: P, recentContent: f, recentContentLoading: h, recentContentSearchTerm: u, product: v, platformInfo: T, links: _, messages: b }) {
1059
+ function Hi({ locale: e, navigate: t, portal: i, open: n, apps: r, appsLoading: o, hiddenApps: s, appsSearchTerm: a, handlePlatformClose: l, handleAppsSearch: d, handleAppReorder: m, handleAppSave: g, handleAppDelete: p, handleAppHide: $, handleAppCancel: y, handleAppEdit: w, handleItemSearch: I, editingApplications: P, recentContent: f, recentContentLoading: h, recentContentSearchTerm: u, product: v, platformInfo: C, links: _, messages: b }) {
1060
1060
  if (!v || !i || !b)
1061
1061
  return null;
1062
- const { name: A, icon: k } = T || {};
1063
- return c`<calcite-sheet class="platform" .label=${b.label} position=inline-start display-mode=overlay id=example-sheet .open=${n} @calciteSheetClose=${l}><calcite-panel class="platform__panel"><div slot=header-content class="platform__header"><img src=${k ?? O} class="platform__header-image"><div class="platform__header-text"><h2 class="platform__title">${A}</h2><p class="platform__subtitle">${i.name}</p></div><calcite-action icon=x text="Close menu" scale=l @click=${l}></calcite-action></div><div class="platform__container"><div class="platform__tiles">${_.filter(({ icon: N }) => N).map(({ label: N, href: L, icon: x, relativePath: j }) => c`<calcite-tile .icon=${x} .description=${N} .href=${L} alignment=center scale=s @keydown=${(D) => {
1062
+ const { name: A, icon: k } = C || {};
1063
+ return c`<calcite-sheet class="platform" .label=${b.label} position=inline-start display-mode=overlay id=example-sheet .open=${n} @calciteSheetClose=${l}><calcite-panel class="platform__panel"><div slot=header-content class="platform__header"><img src=${k ?? O} class="platform__header-image"><div class="platform__header-text"><h2 class="platform__title">${A}</h2><p class="platform__subtitle">${i.name}</p></div><calcite-action icon=x text="Close menu" scale=l @click=${l}></calcite-action></div><div class="platform__container"><div class="platform__tiles">${_.filter(({ icon: T }) => T).map(({ label: T, href: L, icon: x, relativePath: j }) => c`<calcite-tile .icon=${x} .description=${T} .href=${L} alignment=center scale=s @keydown=${(D) => {
1064
1064
  (D.key === "Enter" || D.key === " ") && t({ event: D, href: L, relativePath: j });
1065
1065
  }} @click=${(D) => {
1066
1066
  t({ event: D, href: L, relativePath: j });
1067
- }}></calcite-tile>`)}</div>${i?.user && c`<calcite-tabs layout=center class="platform__tabs"><calcite-tab-nav slot=title-group>${!M(i) && c`<calcite-tab-title selected>${b.myApps}</calcite-tab-title>` || ""}<calcite-tab-title>${b.recentContent}</calcite-tab-title></calcite-tab-nav>${!M(i) && c`<calcite-tab selected class="platform__tab">${o && c`<calcite-scrim loading></calcite-scrim>` || ""}${Di({ apps: r, appsLoading: o, appsSearchTerm: a, hiddenApps: s, messages: b, handleAppsSearch: d, handleAppReorder: m, handleAppSave: g, handleAppDelete: p, handleAppHide: $, handleAppCancel: y, handleAppEdit: w, editingApplications: P, portal: i })}</calcite-tab>` || ""}<calcite-tab class="platform__tab"><div class="list__header"><calcite-input type=search icon .placeholder=${b.searchRecentContent} scale=m class="list__search" @calciteInputInput=${(N) => I(N.target.value)}></calcite-input></div>${h && !o && c`<calcite-scrim loading></calcite-scrim>` || ""}<div class="list__container">${f?.length > 0 || h ? c`<ul class="list">${U(f, (N) => N.id, (N) => Vi({ portal: i, messages: b, navigate: t, item: N, locale: e }))}</ul>` : u?.length ? J({ title: K(b.noAppResults, { term: u }), description: b.recentContentNoResultsDescription, icon: "search" }) : J({ title: b.noContent, description: b.noContentDescription, icon: "clock" })}</div></calcite-tab></calcite-tabs>` || ""}</div></calcite-panel></calcite-sheet>`;
1067
+ }}></calcite-tile>`)}</div>${i?.user && c`<calcite-tabs layout=center class="platform__tabs"><calcite-tab-nav slot=title-group>${!M(i) && c`<calcite-tab-title selected>${b.myApps}</calcite-tab-title>` || ""}<calcite-tab-title>${b.recentContent}</calcite-tab-title></calcite-tab-nav>${!M(i) && c`<calcite-tab selected class="platform__tab">${o && c`<calcite-scrim loading></calcite-scrim>` || ""}${Di({ apps: r, appsLoading: o, appsSearchTerm: a, hiddenApps: s, messages: b, handleAppsSearch: d, handleAppReorder: m, handleAppSave: g, handleAppDelete: p, handleAppHide: $, handleAppCancel: y, handleAppEdit: w, editingApplications: P, portal: i })}</calcite-tab>` || ""}<calcite-tab class="platform__tab"><div class="list__header"><calcite-input type=search icon .placeholder=${b.searchRecentContent} .value=${u} scale=m class="list__search" @calciteInputInput=${(T) => I(T.target.value)}></calcite-input></div>${h && !o && c`<calcite-scrim loading></calcite-scrim>` || ""}<div class="list__container">${f?.length > 0 || h ? c`<ul class="list">${U(f, (T) => T.id, (T) => Vi({ portal: i, messages: b, navigate: t, item: T, locale: e }))}</ul>` : u?.length ? J({ title: K(b.noAppResults, { term: u }), description: b.recentContentNoResultsDescription, icon: "search" }) : J({ title: b.noContent, description: b.noContentDescription, icon: "clock" })}</div></calcite-tab></calcite-tabs>` || ""}</div></calcite-panel></calcite-sheet>`;
1068
1068
  }
1069
1069
  const ne = [
1070
1070
  "new",
@@ -1144,7 +1144,7 @@ function Xi({ navigate: e, portal: t, projectTitle: i, editedProjectTitle: n, ha
1144
1144
  v.preventDefault(), await r?.(n);
1145
1145
  }} @keydown=${(v) => {
1146
1146
  v.key === "Escape" && s?.();
1147
- }}><calcite-input id=project-title-input type=text scale=l class="rename__input" .label=${f.title} .value=${n} .status=${u ? "invalid" : "idle"} @calciteInputInput=${(v) => o?.(v.target.value)} ${R(I)}></calcite-input>${u && c`<calcite-popover open .label=${f.error} .referenceElement=${I?.value || "project-title-input"} pointer-disabled placement=bottom-start><calcite-notice kind=danger open><div slot=message>${g}</div></calcite-notice></calcite-popover>` || ""}<calcite-action .disabled=${m} icon=check scale=l .text=${f?.saveRename} active class="rename__action" type=submit .loading=${m}></calcite-action><calcite-action .disabled=${m} icon=x scale=l .text=${f?.cancelRename} class="rename__action" @click=${() => s?.()}></calcite-action></form>` : c`<calcite-dropdown width=m class="fade-in project__dropdown"><button slot=trigger class="project" ${R(P)}>${p && c`<calcite-icon scale=s .icon=${p} class="project__menu-icon"></calcite-icon>` || ""}<span class="project__text">${i}</span>${$ && c`<calcite-icon scale=s icon=bullet-point-large class="project__indicator"></calcite-icon>` || ""}<calcite-icon scale=s icon=chevron-down></calcite-icon></button>${U(Object.entries(h).filter(([v, T]) => T.length), ([v, T]) => v, ([v, T]) => c`<calcite-dropdown-group selection-mode=none>${T.map((_) => Qi({ menuItem: _, navigate: e, portal: t, messages: f, portalItem: l, openProjectTitleEdit: a, projectMenuClick: y }))}</calcite-dropdown-group>`)}</calcite-dropdown>`;
1147
+ }}><calcite-input id=project-title-input type=text scale=l class="rename__input" .label=${f.title} .value=${n} .status=${u ? "invalid" : "idle"} @calciteInputInput=${(v) => o?.(v.target.value)} ${W(I)}></calcite-input>${u && c`<calcite-popover open .label=${f.error} .referenceElement=${I?.value || "project-title-input"} pointer-disabled placement=bottom-start><calcite-notice kind=danger open><div slot=message>${g}</div></calcite-notice></calcite-popover>` || ""}<calcite-action .disabled=${m} icon=check scale=l .text=${f?.saveRename} active class="rename__action" type=submit .loading=${m}></calcite-action><calcite-action .disabled=${m} icon=x scale=l .text=${f?.cancelRename} class="rename__action" @click=${() => s?.()}></calcite-action></form>` : c`<calcite-dropdown width=m class="fade-in project__dropdown"><button slot=trigger class="project" ${W(P)}>${p && c`<calcite-icon scale=s .icon=${p} class="project__menu-icon"></calcite-icon>` || ""}<span class="project__text">${i}</span>${$ && c`<calcite-icon scale=s icon=bullet-point-large class="project__indicator"></calcite-icon>` || ""}<calcite-icon scale=s icon=chevron-down></calcite-icon></button>${U(Object.entries(h).filter(([v, C]) => C.length), ([v, C]) => v, ([v, C]) => c`<calcite-dropdown-group selection-mode=none>${C.map((_) => Qi({ menuItem: _, navigate: e, portal: t, messages: f, portalItem: l, openProjectTitleEdit: a, projectMenuClick: y }))}</calcite-dropdown-group>`)}</calcite-dropdown>`;
1148
1148
  }
1149
1149
  function Yi(e) {
1150
1150
  return ["Location Platform", "Online", "Enterprise"].includes(e);
@@ -1188,7 +1188,7 @@ function nn({ currentPathname: e, navigate: t, product: i, portal: n, messages:
1188
1188
  const w = ze({ portal: n, searchType: s, searchTerm: a }), I = `/${w}`, P = `${E(n)}${w}`;
1189
1189
  return o ? c`<div class="search" id=search-reference-element><calcite-input type=search scale=l icon=search class="search__input" .ariaLabel=${r.label} .placeholder=${s === "vector" ? r.searchType.semanticPlaceholder : r.searchType.keywordPlaceholder} @calciteInputInput=${(f) => p(f.target.value)} @keydown=${(f) => {
1190
1190
  f.key === "Enter" && (t({ href: P, event: f, relativePath: I }), f.defaultPrevented || (window.location.href = P)), f.key === "Escape" && $(!1);
1191
- }} ${R(d)}></calcite-input><calcite-action icon=x scale=l .text=${r?.close} active class="search__action" @click=${() => $(!1)}></calcite-action><calcite-popover .label=${r.suggestions} reference-element=search-reference-element .open=${o && !!a} pointer-disabled placement=bottom-start trigger-disabled .focusTrapOptions=${{ initialFocus: !1 }} ${R(g)}><div class="suggestions__header"><h3 class="suggestions__title">${r.topResults}</h3>${tn({ portal: n, messages: r, searchType: s, handleSearchTypeChange: y })}</div><div class="suggestions__results">${en({ portal: n, suggestions: l, navigate: t, messages: r, searchType: s, searchTerm: a })}</div></calcite-popover></div>` : c`<calcite-action icon=search scale=l text=search class="search__action fade-in" @click=${() => $(!0)} ${R(m)}></calcite-action>`;
1191
+ }} ${W(d)}></calcite-input><calcite-action icon=x scale=l .text=${r?.close} active class="search__action" @click=${() => $(!1)}></calcite-action><calcite-popover .label=${r.suggestions} reference-element=search-reference-element .open=${o && !!a} pointer-disabled placement=bottom-start trigger-disabled .focusTrapOptions=${{ initialFocus: !1 }} ${W(g)}><div class="suggestions__header"><h3 class="suggestions__title">${r.topResults}</h3>${tn({ portal: n, messages: r, searchType: s, handleSearchTypeChange: y })}</div><div class="suggestions__results">${en({ portal: n, suggestions: l, navigate: t, messages: r, searchType: s, searchTerm: a })}</div></calcite-popover></div>` : c`<calcite-action icon=search scale=l text=search class="search__action fade-in" @click=${() => $(!0)} ${W(m)}></calcite-action>`;
1192
1192
  }
1193
1193
  function rn({ signIn: e, messages: t }) {
1194
1194
  return c`<calcite-menu slot=user .label=${t?.account || ""} class="border-start fade-in"><calcite-menu-item .label=${t?.signIn || ""} text-enabled .text=${t?.signIn || ""} @calciteMenuItemSelect=${() => e()}></calcite-menu-item></calcite-menu>`;
@@ -1203,7 +1203,7 @@ function sn({ userLinks: e, messages: t, navigate: i, openAccountSwitcher: n, po
1203
1203
  }} @click=${(y) => {
1204
1204
  i({ event: y, href: p, relativePath: $ });
1205
1205
  }}>${g}</calcite-dropdown-item>`)}</calcite-dropdown-group>`)}<calcite-dropdown-group selection-mode=none>${n && c`<calcite-dropdown-item icon-start=users @calciteDropdownItemSelect=${(l) => {
1206
- const d = Ft(l.target, "calcite-dropdown");
1206
+ const d = Rt(l.target, "calcite-dropdown");
1207
1207
  d && (d.open = !1), n();
1208
1208
  }}>${t.switchAccounts}</calcite-dropdown-item>` || ""}<calcite-dropdown-item icon-start=sign-out @calciteDropdownItemSelect=${() => o()}>${t.signOut}</calcite-dropdown-item></calcite-dropdown-group></calcite-dropdown></div>`;
1209
1209
  }
@@ -1571,7 +1571,7 @@ function Be(e) {
1571
1571
  };
1572
1572
  }
1573
1573
  }
1574
- function Fe({
1574
+ function Re({
1575
1575
  name: e,
1576
1576
  fileName: t,
1577
1577
  icon: i
@@ -1582,16 +1582,16 @@ function Fe({
1582
1582
  icon: ee(`assets/portal-navigation/apps/${i}.avif`)
1583
1583
  };
1584
1584
  }
1585
- function We({ portal: e, clientId: t }) {
1585
+ function Fe({ portal: e, clientId: t }) {
1586
1586
  return e?.sourceJSON?.subscriptionInfo?.options?.includes("Developer") ? "Location Platform" : de(t) ? "GeoAnalytics Fabric" : ue(t) ? "GeoAnalytics Engine" : e?.isPortal ? "Enterprise" : "Online";
1587
1587
  }
1588
1588
  function bn(e) {
1589
- const t = We(e);
1590
- return Fe(Be(t));
1589
+ const t = Fe(e);
1590
+ return Re(Be(t));
1591
1591
  }
1592
1592
  function $e(e) {
1593
- const t = e?.product === "Online" ? We(e) : e?.product;
1594
- return Fe(Be(t));
1593
+ const t = e?.product === "Online" ? Fe(e) : e?.product;
1594
+ return Re(Be(t));
1595
1595
  }
1596
1596
  function vn() {
1597
1597
  const e = It();
@@ -1612,14 +1612,14 @@ function wn() {
1612
1612
  }
1613
1613
  function yn(e, t = window.location.href) {
1614
1614
  const i = window.location.href.startsWith("http://"), n = Bt(e);
1615
- Rt.destroyCredentials(), wn();
1615
+ Wt.destroyCredentials(), wn();
1616
1616
  const r = new URL(q(`${ce(e)}oauth2/signout`, e)), { searchParams: o } = r;
1617
1617
  o.append("client_id", "arcgisonline"), o.append("redirect_uri", t), n && i && (e.isPortal || e.user?.sourceJSON.provider === "enterprise") && o.append("token", n), window.location.href = r.href;
1618
1618
  }
1619
1619
  function z(e, t) {
1620
1620
  if (!e)
1621
1621
  return 0;
1622
- const i = Wt({ text: e, font: `${t === "s" ? ".875rem" : "1rem"} 'Avenir Next'` });
1622
+ const i = Ft({ text: e, font: `${t === "s" ? ".875rem" : "1rem"} 'Avenir Next'` });
1623
1623
  return Math.ceil(i);
1624
1624
  }
1625
1625
  function $n({
@@ -1652,7 +1652,7 @@ function An({
1652
1652
  user: m ? "avatar" : "full"
1653
1653
  };
1654
1654
  }
1655
- const Re = ' -type:"Code Attachment" -type:"Featured Items" -type:"Symbol Set" -type:"Color Set" -type:"Windows Viewer Add In" -type:"Windows Viewer Configuration" -type:"Map Area" -typekeywords:"MapAreaPackage" -type:"Indoors Map Configuration" -typekeywords:"SMX"';
1655
+ const We = ' -type:"Code Attachment" -type:"Featured Items" -type:"Symbol Set" -type:"Color Set" -type:"Windows Viewer Add In" -type:"Windows Viewer Configuration" -type:"Map Area" -typekeywords:"MapAreaPackage" -type:"Indoors Map Configuration" -typekeywords:"SMX"';
1656
1656
  async function Ae({
1657
1657
  portal: e,
1658
1658
  searchTerm: t
@@ -1662,7 +1662,7 @@ async function Ae({
1662
1662
  try {
1663
1663
  return (await e.queryItems({
1664
1664
  ...t ? { query: t } : {},
1665
- filter: `owner:${e.user.username}${Re}`,
1665
+ filter: `owner:${e.user.username}${We}`,
1666
1666
  num: 20,
1667
1667
  sortField: "modified",
1668
1668
  sortOrder: "desc"
@@ -1677,7 +1677,7 @@ async function kn({
1677
1677
  }) {
1678
1678
  if (!e)
1679
1679
  return [];
1680
- const i = Ht((t || "").substring(0, 409)), n = `${e?.id ? `accountid:"${e.id}"` : ""}${Re}`, r = `${ce(e)}search/suggest`;
1680
+ const i = Ht((t || "").substring(0, 409)), n = `${e?.id ? `accountid:"${e.id}"` : ""}${We}`, r = `${ce(e)}search/suggest`;
1681
1681
  return (await B(r, { query: {
1682
1682
  suggest: i,
1683
1683
  filters: n,
@@ -1691,7 +1691,7 @@ function Sn({ messages: e, portal: t, showNav: i, openPlatformMenu: n, handleTog
1691
1691
  }
1692
1692
  class In extends $t {
1693
1693
  constructor() {
1694
- super(...arguments), this.messages = At({ blocking: !0 }), this.refreshNotifications = async () => {
1694
+ super(...arguments), this.messages = At({ blocking: !0 }), this.originalRecentContent = [], this.refreshNotifications = async () => {
1695
1695
  const { portal: t, messages: i } = this;
1696
1696
  this.notifications = await be({ portal: t, locale: i._t9nLocale, t9n: i.notifications });
1697
1697
  }, this.deleteNotifications = async (t) => {
@@ -1701,7 +1701,7 @@ class In extends $t {
1701
1701
  else {
1702
1702
  let n = 0;
1703
1703
  for await (const r of t)
1704
- await Ce({ id: r, portal: i }), this.notificationDeleteProgress = Math.ceil(n++ / t.length * 100);
1704
+ await Ne({ id: r, portal: i }), this.notificationDeleteProgress = Math.ceil(n++ / t.length * 100);
1705
1705
  }
1706
1706
  this.notificationDeleteProgress = void 0, this.refreshNotifications();
1707
1707
  }, this.navigate = (t) => {
@@ -1738,7 +1738,7 @@ class In extends $t {
1738
1738
  }, this.openAccountSwitcher = () => {
1739
1739
  this.accountSwitcherOpen = !0;
1740
1740
  }, this.handlePlatformClose = () => {
1741
- this.platformMenuOpen = !1, this.handleAppCancel(), this.appsSearchTerm = "";
1741
+ this.platformMenuOpen = !1, this.handleAppCancel(), this.appsSearchTerm = "", this.recentContent = this.originalRecentContent, this.recentContentSearchTerm = "";
1742
1742
  }, this.handleAppSave = async () => {
1743
1743
  const { hiddenApps: t, sortedApps: i, userProperties: n, portal: r } = this;
1744
1744
  this.apps = [...i], this.editingApplications = !1, this.appsLoading = !0;
@@ -1759,7 +1759,7 @@ class In extends $t {
1759
1759
  }, this.handleItemSearch = (t) => {
1760
1760
  this.recentContentLoading = !0, this.recentContentSearchTerm = t, this.debouncedItemSearch(t);
1761
1761
  }, this.debouncedItemSearch = fe(async (t) => {
1762
- this.recentContent = await Ae({ portal: this.portal, searchTerm: t }), this.recentContentLoading = !1;
1762
+ this.recentContent = await Ae({ portal: this.portal, searchTerm: t }), this.recentContentLoading = !1, t || (this.originalRecentContent = [...this.recentContent]);
1763
1763
  }, 1e3), this.debouncedSuggest = fe(async (t) => {
1764
1764
  this.suggestions = await kn({ portal: this.portal, searchTerm: t });
1765
1765
  }, 1e3), this.handleSearch = (t) => {
@@ -1782,7 +1782,7 @@ class In extends $t {
1782
1782
  });
1783
1783
  }, this.handleSearchTypeChange = (t) => {
1784
1784
  this.searchType = t;
1785
- }, this.searchInput = W(), this.searchAction = W(), this.searchPopover = W(), this.projectTitleInputRef = W(), this.projectButtonRef = W(), this.initialDocumentOverflowStyle = document.documentElement.style.overflow, this.links = [], this.notifications = [], this.notificationsActive = !1, this.apps = [], this.hiddenApps = {}, this.sortedApps = [], this.appsSearchTerm = "", this.appsLoading = !0, this.editingApplications = !1, this.recentContent = [], this.recentContentSearchTerm = "", this.recentContentLoading = !0, this.platformMenuOpen = !1, this.accountSwitcherOpen = !1, this.projectTitleEditing = !1, this.projectTitleSaving = !1, this.screenWidth = window.innerWidth, this.searchActive = !1, this.searchTerm = "", this.searchType = "keyword", this.projectMenuOptions = [], this.currentPathname = window.location.pathname, this.arcgisNavigate = H(), this.arcgisNavigationProjectMenuClick = H(), this.arcgisNavigationSignIn = H(), this.arcgisNavigationSignOut = H();
1785
+ }, this.searchInput = F(), this.searchAction = F(), this.searchPopover = F(), this.projectTitleInputRef = F(), this.projectButtonRef = F(), this.initialDocumentOverflowStyle = document.documentElement.style.overflow, this.links = [], this.notifications = [], this.notificationsActive = !1, this.apps = [], this.hiddenApps = {}, this.sortedApps = [], this.appsSearchTerm = "", this.appsLoading = !0, this.editingApplications = !1, this.recentContent = [], this.recentContentSearchTerm = "", this.recentContentLoading = !0, this.platformMenuOpen = !1, this.accountSwitcherOpen = !1, this.projectTitleEditing = !1, this.projectTitleSaving = !1, this.screenWidth = window.innerWidth, this.searchActive = !1, this.searchTerm = "", this.searchType = "keyword", this.projectMenuOptions = [], this.currentPathname = window.location.pathname, this.arcgisNavigate = H(), this.arcgisNavigationProjectMenuClick = H(), this.arcgisNavigationSignIn = H(), this.arcgisNavigationSignOut = H();
1786
1786
  }
1787
1787
  static {
1788
1788
  this.properties = { infoBanner: 16, links: 16, userLinks: 16, notifications: 16, notificationsActive: 16, apps: 16, hiddenApps: 16, sortedApps: 16, previousAppState: 16, appsSearchTerm: 16, appsLoading: 16, editingApplications: 16, recentContent: 16, recentContentSearchTerm: 16, recentContentLoading: 16, platformMenuOpen: 16, accountSwitcherOpen: 16, editedProjectTitle: 16, projectTitleEditing: 16, projectTitleSaving: 16, projectTitleErrorMessage: 16, productInfo: 16, platformInfo: 16, notificationDeleteProgress: 16, measurements: 16, screenWidth: 16, showProduct: 16, showNav: 16, showUser: 16, searchActive: 16, searchTerm: 16, suggestions: 16, searchType: 16, portal: 0, portalItem: 0, product: 1, productHref: 1, projectTitle: 1, projectTitleSave: 0, projectMenuIcon: 1, projectMenuSaveIndicator: 5, projectMenuOptions: 0, disableTrackViewer: 5, disableNotebookServer: 5, clientId: 1, currentPathname: 1, maxWidth: 9 };
@@ -1793,7 +1793,7 @@ class In extends $t {
1793
1793
  #e;
1794
1794
  async loaded() {
1795
1795
  const { portal: t, messages: i, clientId: n, product: r } = this;
1796
- this.calculateMeasurements(), this.productInfo = $e({ product: r, clientId: n, portal: t }), this.platformInfo = bn({ clientId: n, portal: t }), this.userLinks = cn({ portal: t, messages: i.user, clientId: n }), this.notifications = await be({ portal: t, locale: i._t9nLocale, t9n: i.notifications }), this.recentContent = await Ae({ portal: t }), this.recentContentLoading = !1;
1796
+ this.calculateMeasurements(), this.productInfo = $e({ product: r, clientId: n, portal: t }), this.platformInfo = bn({ clientId: n, portal: t }), this.userLinks = cn({ portal: t, messages: i.user, clientId: n }), this.notifications = await be({ portal: t, locale: i._t9nLocale, t9n: i.notifications }), this.recentContent = await Ae({ portal: t }), this.originalRecentContent = [...this.recentContent], this.recentContentLoading = !1;
1797
1797
  const { apps: o, hiddenApps: s, signInSettings: a, licenses: l, userProperties: d } = await Mi({
1798
1798
  portal: t,
1799
1799
  trackViewerEnabled: !this.disableTrackViewer,
@@ -1845,8 +1845,8 @@ class In extends $t {
1845
1845
  }
1846
1846
  }
1847
1847
  render() {
1848
- const { accountSwitcherOpen: t, apps: i, appsLoading: n, appsSearchTerm: r, currentPathname: o, handleAppCancel: s, handleAppDelete: a, handleAppHide: l, handleAppReorder: d, handleAppSave: m, handleItemSearch: g, handlePlatformClose: p, handleSearch: $, handleToggleSearch: y, handleSearchTypeChange: w, hiddenApps: I, infoBanner: P, links: f, messages: h, navigate: u, notifications: v, notificationsActive: T, notificationDeleteProgress: _, openAccountSwitcher: b, platformInfo: A, portal: k, portalItem: N, product: L, productInfo: x, productHref: j, projectTitle: D, editedProjectTitle: Ve, handleProjectTitleSave: He, handleProjectTitleEdit: qe, handleProjectTitleCancel: Je, handleToggleNotifications: he, openProjectTitleEdit: Ke, openPlatformMenu: Qe, platformMenuOpen: Xe, projectTitleEditing: Q, projectTitleSaving: Ye, projectTitleErrorMessage: Ze, projectMenuIcon: et, projectMenuSaveIndicator: tt, projectMenuClick: it, projectMenuOptions: nt, projectTitleInputRef: rt, projectButtonRef: ot, recentContent: st, recentContentSearchTerm: at, recentContentLoading: ct, userLinks: lt, searchActive: F, searchTerm: ut, searchType: dt, searchInput: pt, searchAction: ht, searchPopover: mt, showNav: X, showProduct: ft, showUser: gt, suggestions: bt } = this, vt = k?.user, _t = pe(L) && !f?.length || !this.measurements;
1849
- return c`<calcite-scrim class=${te({ scrim: !0, "scrim--active": F })}></calcite-scrim><div class="wrapper" style=${ke({ "--arcgis-portal-navigation-max-width": this.maxWidth ? `${this.maxWidth}px` : "100%" })}><arcgis-portal-info-banner .config=${P}></arcgis-portal-info-banner>${k?.isPortal && N?.loaded && c`<arcgis-portal-classification-banner .portalItem=${N}></arcgis-portal-classification-banner>` || ""}<header class=${te({ navigation: !0, "navigation--loading": _t })}>${Sn({ messages: h?.platform, portal: k, showNav: X, openPlatformMenu: Qe, handleToggleSearch: y })}${ft && qt({ navigate: u, portal: k, product: L, productInfo: x, productHref: j, messages: h?.logo, showNav: X, searchActive: F, projectTitleEditing: Q }) || ""}${Xi({ navigate: u, portal: k, portalItem: N, messages: h?.project, projectTitle: D, editedProjectTitle: Ve, handleProjectTitleSave: He, handleProjectTitleEdit: qe, openProjectTitleEdit: Ke, projectTitleErrorMessage: Ze, handleProjectTitleCancel: Je, projectTitleEditing: Q, projectTitleSaving: Ye, projectMenuIcon: et, projectMenuSaveIndicator: tt, projectMenuClick: it, projectMenuOptions: nt, projectTitleInputRef: rt, projectButtonRef: ot })}${X && on({ searchActive: F, navigate: u, portal: k, product: L, messages: h?.links, links: f, currentPathname: o }) || ""}<div slot=content-end class="content-end fade-in" .hidden=${Q || F}><slot name=content-end></slot></div>${nn({ currentPathname: o, navigate: u, portal: k, product: L, messages: h?.search, searchActive: F, searchType: dt, searchTerm: ut, suggestions: bt, handleSearch: $, handleToggleSearch: y, handleSearchTypeChange: w, searchInputRef: pt, searchActionRef: ht, searchPopoverRef: mt })}${vt ? c`<div class="border-start fade-in">${ii({ notifications: v, notificationsActive: T, messages: h?.notifications, handleToggleNotifications: he, handleToggleSearch: y })}${ni({ notificationsActive: T, notifications: v, navigate: u, portal: k, deleteNotifications: this.deleteNotifications, handleToggleNotifications: he, messages: h?.notifications, notificationDeleteProgress: _ })}</div>${sn({ portal: k, userLinks: lt, openAccountSwitcher: k?.isPortal ? void 0 : b, signOut: this.signOut, messages: h?.user, textDisabled: gt === "avatar", navigate: u })}` : rn({ messages: h.user, signIn: this.signIn })}</header>${Hi({ locale: h._t9nLocale, navigate: u, portal: k, product: L, platformInfo: A, messages: h?.platform, apps: i, appsLoading: n, hiddenApps: I, appsSearchTerm: r, editingApplications: this.editingApplications, open: Xe, links: f, recentContent: st, recentContentSearchTerm: at, recentContentLoading: ct, handlePlatformClose: p, handleAppReorder: d, handleAppEdit: () => this.editingApplications = !0, handleAppDelete: a, handleAppsSearch: (wt) => this.appsSearchTerm = wt, handleAppSave: m, handleAppCancel: s, handleAppHide: l, handleItemSearch: g })}${t && c`<arcgis-portal-account-switcher .portal=${k} @arcgisClose=${() => {
1848
+ const { accountSwitcherOpen: t, apps: i, appsLoading: n, appsSearchTerm: r, currentPathname: o, handleAppCancel: s, handleAppDelete: a, handleAppHide: l, handleAppReorder: d, handleAppSave: m, handleItemSearch: g, handlePlatformClose: p, handleSearch: $, handleToggleSearch: y, handleSearchTypeChange: w, hiddenApps: I, infoBanner: P, links: f, messages: h, navigate: u, notifications: v, notificationsActive: C, notificationDeleteProgress: _, openAccountSwitcher: b, platformInfo: A, portal: k, portalItem: T, product: L, productInfo: x, productHref: j, projectTitle: D, editedProjectTitle: Ve, handleProjectTitleSave: He, handleProjectTitleEdit: qe, handleProjectTitleCancel: Je, handleToggleNotifications: he, openProjectTitleEdit: Ke, openPlatformMenu: Qe, platformMenuOpen: Xe, projectTitleEditing: Q, projectTitleSaving: Ye, projectTitleErrorMessage: Ze, projectMenuIcon: et, projectMenuSaveIndicator: tt, projectMenuClick: it, projectMenuOptions: nt, projectTitleInputRef: rt, projectButtonRef: ot, recentContent: st, recentContentSearchTerm: at, recentContentLoading: ct, userLinks: lt, searchActive: R, searchTerm: ut, searchType: dt, searchInput: pt, searchAction: ht, searchPopover: mt, showNav: X, showProduct: ft, showUser: gt, suggestions: bt } = this, vt = k?.user, _t = pe(L) && !f?.length || !this.measurements;
1849
+ return c`<calcite-scrim class=${te({ scrim: !0, "scrim--active": R })}></calcite-scrim><div class="wrapper" style=${ke({ "--arcgis-portal-navigation-max-width": this.maxWidth ? `${this.maxWidth}px` : "100%" })}><arcgis-portal-info-banner .config=${P}></arcgis-portal-info-banner>${k?.isPortal && T?.loaded && c`<arcgis-portal-classification-banner .portalItem=${T}></arcgis-portal-classification-banner>` || ""}<header class=${te({ navigation: !0, "navigation--loading": _t })}>${Sn({ messages: h?.platform, portal: k, showNav: X, openPlatformMenu: Qe, handleToggleSearch: y })}${ft && qt({ navigate: u, portal: k, product: L, productInfo: x, productHref: j, messages: h?.logo, showNav: X, searchActive: R, projectTitleEditing: Q }) || ""}${Xi({ navigate: u, portal: k, portalItem: T, messages: h?.project, projectTitle: D, editedProjectTitle: Ve, handleProjectTitleSave: He, handleProjectTitleEdit: qe, openProjectTitleEdit: Ke, projectTitleErrorMessage: Ze, handleProjectTitleCancel: Je, projectTitleEditing: Q, projectTitleSaving: Ye, projectMenuIcon: et, projectMenuSaveIndicator: tt, projectMenuClick: it, projectMenuOptions: nt, projectTitleInputRef: rt, projectButtonRef: ot })}${X && on({ searchActive: R, navigate: u, portal: k, product: L, messages: h?.links, links: f, currentPathname: o }) || ""}<div slot=content-end class="content-end fade-in" .hidden=${Q || R}><slot name=content-end></slot></div>${nn({ currentPathname: o, navigate: u, portal: k, product: L, messages: h?.search, searchActive: R, searchType: dt, searchTerm: ut, suggestions: bt, handleSearch: $, handleToggleSearch: y, handleSearchTypeChange: w, searchInputRef: pt, searchActionRef: ht, searchPopoverRef: mt })}${vt ? c`<div class="border-start fade-in">${ii({ notifications: v, notificationsActive: C, messages: h?.notifications, handleToggleNotifications: he, handleToggleSearch: y })}${ni({ notificationsActive: C, notifications: v, navigate: u, portal: k, deleteNotifications: this.deleteNotifications, handleToggleNotifications: he, messages: h?.notifications, notificationDeleteProgress: _ })}</div>${sn({ portal: k, userLinks: lt, openAccountSwitcher: k?.isPortal ? void 0 : b, signOut: this.signOut, messages: h?.user, textDisabled: gt === "avatar", navigate: u })}` : rn({ messages: h.user, signIn: this.signIn })}</header>${Hi({ locale: h._t9nLocale, navigate: u, portal: k, product: L, platformInfo: A, messages: h?.platform, apps: i, appsLoading: n, hiddenApps: I, appsSearchTerm: r, editingApplications: this.editingApplications, open: Xe, links: f, recentContent: st, recentContentSearchTerm: at, recentContentLoading: ct, handlePlatformClose: p, handleAppReorder: d, handleAppEdit: () => this.editingApplications = !0, handleAppDelete: a, handleAppsSearch: (wt) => this.appsSearchTerm = wt, handleAppSave: m, handleAppCancel: s, handleAppHide: l, handleItemSearch: g })}${t && c`<arcgis-portal-account-switcher .portal=${k} @arcgisClose=${() => {
1850
1850
  this.accountSwitcherOpen = !1;
1851
1851
  }}></arcgis-portal-account-switcher>` || ""}</div>`;
1852
1852
  }
@@ -1,59 +1,9 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
- import { html as f } from "lit";
3
- import { substitute as P } from "@arcgis/core/intl.js";
4
- import { nothing as B } from "@arcgis/lumina";
5
- import { PortalBrowserFilterItem as F } from "../portal-browser-filter/customElement.js";
6
- const y = 1440 * 60 * 1e3;
7
- function u(t) {
8
- const i = typeof t == "string" ? Number.parseInt(t, 10) : typeof t == "number" ? t : (t ?? /* @__PURE__ */ new Date()).valueOf(), r = new Date(i);
9
- return r.setHours(0, 0, 0, 0), r.valueOf();
10
- }
11
- function g(t) {
12
- return u(t) + y - 1;
13
- }
14
- const E = 7 * y, w = ["today", "yesterday", "last7", "last30", "never", "custom"], M = (t, i, r) => {
15
- const s = u(), a = g();
16
- switch (t) {
17
- case "yesterday":
18
- return [s - y, s - 1];
19
- case "today":
20
- return [s, a];
21
- case "last7":
22
- return [s - E, a];
23
- case "last30":
24
- return [s - y * 30, a];
25
- case "never":
26
- return [-1, -1];
27
- case "custom":
28
- return i && r ? [u(i), g(r)] : null;
29
- default:
30
- return null;
31
- }
32
- };
33
- function H(t) {
34
- const { clearLabel: i, end: r, expanded: s, filterDateMessages: a, includeNever: $, onFilter: b, onRemove: v, property: d, range: l, serverProperty: h, setExpanded: O, start: m } = t, I = a.title[d], S = $ ? w : w.filter((e) => e !== "never"), k = (/* @__PURE__ */ new Date()).toISOString().slice(0, 10), x = !!(l && (l !== "custom" || m && r)), D = (e, n, c) => {
35
- const p = h ?? (d === "modified" ? "modified" : "uploaded"), o = M(e, n, c), A = e ? a[e] : "";
36
- b?.({
37
- id: d,
38
- label: e ? P(a[d], { date: A }) : "",
39
- value: o ? `(${p}:[${o[0]} TO ${o[1]}])` : "",
40
- range: e,
41
- start: o ? new Date(o[0]) : void 0,
42
- end: o ? new Date(o[1]) : void 0
43
- });
44
- };
45
- return F({ heading: I, expanded: s, setExpanded: O, active: x, clearLabel: i, onRemove: v, children: f`<div><calcite-tree selection-mode=children scale=m @calciteTreeSelect=${(e) => {
46
- const n = e.target.selectedItems?.[0]?.dataset.range, c = l === n ? null : n;
47
- if (!c) {
48
- v?.();
49
- return;
50
- }
51
- D(c, m, r);
52
- }}>${S.map((e) => f`<calcite-tree-item data-range=${e ?? B} .selected=${e === l}>${a[e]}</calcite-tree-item>`)}</calcite-tree>${l === "custom" && f`<calcite-input-date-picker class="custom-date-picker" @calciteInputDatePickerChange=${(e) => {
53
- const n = e.target.valueAsDate, [c, p] = Array.isArray(n) ? n : [];
54
- c && p && D("custom", c, p);
55
- }} scale=s .max=${k} calendars=1 layout=vertical month-style=abbreviated proximity-selection-disabled range .valueAsDate=${m && r ? [new Date(u(m)), new Date(u(r))] : []}></calcite-input-date-picker>` || ""}</div>` });
56
- }
2
+ import "lit";
3
+ import "@arcgis/core/intl.js";
4
+ import "@arcgis/lumina";
5
+ import "../portal-browser-filter/customElement.js";
6
+ import { P as e } from "../../../../chunks/portal-browser-filter-date.js";
57
7
  export {
58
- H as PortalBrowserFilterDate
8
+ e as PortalBrowserFilterDate
59
9
  };
@@ -3,7 +3,7 @@ import { html as a } from "lit";
3
3
  import { substitute as m } from "@arcgis/core/intl.js";
4
4
  import { nothing as u } from "@arcgis/lumina";
5
5
  import { i as ie } from "../../chunks/users.js";
6
- import { PortalBrowserFilterDate as pe } from "../portal-browser/components/portal-browser-filter-date/customElement.js";
6
+ import { P as pe } from "../../chunks/portal-browser-filter-date.js";
7
7
  import { PortalBrowserFilterItem as g } from "../portal-browser/components/portal-browser-filter/customElement.js";
8
8
  import { PortalBrowserFilters as de } from "../portal-browser/components/portal-browser-filters/customElement.js";
9
9
  import { g as me, a as ue, b as ge, c as be, d as fe } from "../../chunks/query.js";