@arcgis/map-components 6.0.0-next.33 → 6.0.0-next.34

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (54) hide show
  1. package/dist/cdn/4UCQJWD2.js +2 -0
  2. package/dist/cdn/6UMEQS35.js +2 -0
  3. package/dist/cdn/7OLHJCFT.js +2 -0
  4. package/dist/cdn/AMRSK274.js +2 -0
  5. package/dist/cdn/D4UNIFIZ.js +2 -0
  6. package/dist/cdn/JKE3FA4Q.js +2 -0
  7. package/dist/cdn/JZTCF52M.js +2 -0
  8. package/dist/cdn/NZK2LVFA.js +2 -0
  9. package/dist/cdn/PTHNXKEA.js +2 -0
  10. package/dist/cdn/QCZQCLAT.js +2 -0
  11. package/dist/cdn/QVIQ66LA.js +2 -0
  12. package/dist/cdn/index.js +1 -1
  13. package/dist/chunks/layer-list-next.js +49 -4
  14. package/dist/components/arcgis-basemap-layer-list-next/customElement.d.ts +3 -0
  15. package/dist/components/arcgis-basemap-layer-list-next/customElement.js +102 -101
  16. package/dist/components/arcgis-catalog-layer-list-next/customElement.d.ts +3 -0
  17. package/dist/components/arcgis-catalog-layer-list-next/customElement.js +87 -86
  18. package/dist/components/arcgis-expand/customElement.js +13 -13
  19. package/dist/components/arcgis-layer-list-next/customElement.d.ts +1 -0
  20. package/dist/components/arcgis-layer-list-next/customElement.js +72 -71
  21. package/dist/components/arcgis-sketch/customElement.d.ts +6 -4
  22. package/dist/components/arcgis-sketch/customElement.js +177 -167
  23. package/dist/components/arcgis-table-list-next/customElement.d.ts +3 -0
  24. package/dist/components/arcgis-table-list-next/customElement.js +44 -43
  25. package/dist/components/arcgis-utility-network-picker/customElement.js +32 -31
  26. package/dist/components/arcgis-utility-network-trace-configuration-picker/customElement.d.ts +10 -4
  27. package/dist/components/arcgis-utility-network-trace-configuration-picker/customElement.js +10 -9
  28. package/dist/components/arcgis-utility-network-trace-inputs/customElement.d.ts +3 -0
  29. package/dist/components/arcgis-utility-network-trace-inputs/customElement.js +7 -7
  30. package/dist/components/arcgis-utility-network-trace-results/customElement.d.ts +1 -1
  31. package/dist/components/arcgis-view-popover/customElement.d.ts +65 -33
  32. package/dist/components/arcgis-view-popover/customElement.js +196 -108
  33. package/dist/components/arcgis-view-popover/index.js +1 -1
  34. package/dist/docs/api.json +1 -1
  35. package/dist/docs/docs.json +1 -1
  36. package/dist/docs/vscode.html-custom-data.json +1 -1
  37. package/dist/docs/web-types.json +1 -1
  38. package/dist/loader.js +1 -1
  39. package/dist/types/lumina.d.ts +1 -1
  40. package/dist/types/preact.d.ts +1 -1
  41. package/dist/types/react.d.ts +1 -1
  42. package/dist/types/stencil.d.ts +1 -1
  43. package/package.json +7 -7
  44. package/dist/cdn/3NUN6DK3.js +0 -2
  45. package/dist/cdn/6FJUKYNB.js +0 -2
  46. package/dist/cdn/7Y6PADB5.js +0 -2
  47. package/dist/cdn/I5F7MVDT.js +0 -2
  48. package/dist/cdn/P5U37XIA.js +0 -2
  49. package/dist/cdn/PD4ELTMF.js +0 -2
  50. package/dist/cdn/RAADOJWX.js +0 -2
  51. package/dist/cdn/TY4XRXLB.js +0 -2
  52. package/dist/cdn/UZ4VANCL.js +0 -2
  53. package/dist/cdn/W4BA3ECA.js +0 -2
  54. package/dist/cdn/ZEQHIKTN.js +0 -2
@@ -1,32 +1,32 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/6.0/LICENSE.txt */
2
2
  import { c as N } from "../../chunks/runtime.js";
3
- import { css as q, noChange as I, html as b } from "lit";
3
+ import { css as q, noChange as z, html as b } from "lit";
4
4
  import { substitute as j } from "@arcgis/core/intl.js";
5
5
  import { GenericController as J, usePropertyChange as Q, useWatchAttributes as X } from "@arcgis/lumina/controllers";
6
6
  import { reEmitEvent as T } from "@arcgis/lumina-toolkit/reEmitEvent";
7
7
  import Y from "@arcgis/core/layers/GraphicsLayer.js";
8
8
  import Z from "@arcgis/core/symbols/TextSymbol.js";
9
- import { LitElement as ee, createEvent as te, nothing as D } from "@arcgis/lumina";
9
+ import { LitElement as ee, createEvent as te, nothing as I } from "@arcgis/lumina";
10
10
  import { watch as v, on as ie, whenOnce as oe } from "@arcgis/core/core/reactiveUtils.js";
11
11
  import { u as se } from "../../chunks/useT9n.js";
12
12
  import { m as ne } from "../../chunks/useViewModel.js";
13
13
  import { V as M } from "../../chunks/visible-element.js";
14
- import { createRef as O, ref as P } from "lit/directives/ref.js";
14
+ import { createRef as L, ref as k } from "lit/directives/ref.js";
15
15
  import le from "@arcgis/core/widgets/Sketch/SketchViewModel.js";
16
16
  import { S as re } from "../../chunks/resources.js";
17
17
  import { getOrCreateMapValue as F, createReactiveMap as ae } from "@arcgis/core/applications/Components/featureUtils.js";
18
18
  import { LayoutPriorities as E } from "@arcgis/common-components";
19
19
  import ce from "@arcgis/core/core/Accessor.js";
20
- import { property as p, subclass as he } from "@arcgis/core/core/accessorSupport/decorators.js";
20
+ import { property as g, subclass as he } from "@arcgis/core/core/accessorSupport/decorators.js";
21
21
  import { ignoreAbortErrors as _ } from "@arcgis/core/core/promiseUtils.js";
22
22
  import de from "@arcgis/core/widgets/Sketch/VisibleElements.js";
23
23
  import pe from "@arcgis/core/widgets/support/SelectionToolbar/SelectionToolbarViewModel.js";
24
- import { c as ue } from "../../chunks/loader-utils.js";
25
- import { AsyncDirective as ge } from "lit/async-directive.js";
24
+ import { c as ge } from "../../chunks/loader-utils.js";
25
+ import { AsyncDirective as ue } from "lit/async-directive.js";
26
26
  import { directive as me, PartType as ve } from "lit/directive.js";
27
27
  import { r as fe } from "../../chunks/async-utils.js";
28
28
  import { observeAncestorsMutation as ye } from "@arcgis/toolkit/dom";
29
- function B(i, e) {
29
+ function D(i, e) {
30
30
  let t = e;
31
31
  for (const o of i.split(".")) {
32
32
  if (typeof t != "object" || t === null)
@@ -35,7 +35,7 @@ function B(i, e) {
35
35
  }
36
36
  return typeof t == "string" ? t : void 0;
37
37
  }
38
- const be = q`.editing-controls-panel{min-inline-size:100px;max-inline-size:400px;-webkit-user-select:none;user-select:none;pointer-events:initial;padding:var(--calcite-space-sm);arcgis-sketch-tooltip-controls+arcgis-snapping-controls{border-block-start:1px solid var(--calcite-color-border-3)}}:host{pointer-events:none}.toolbar-container{block-size:100%;min-block-size:0;min-inline-size:0}arcgis-toolbar-stack[layout=vertical]{block-size:100cqh;min-block-size:100%;max-block-size:100%}`, Ce = {
38
+ const be = q`.editing-controls-panel{min-inline-size:100px;max-inline-size:400px;-webkit-user-select:none;user-select:none;pointer-events:initial;padding:var(--calcite-space-sm);arcgis-sketch-tooltip-controls+arcgis-snapping-controls{border-block-start:1px solid var(--calcite-color-border-3)}}:host{pointer-events:none}.toolbar-container{block-size:100%;min-block-size:0;min-inline-size:0}arcgis-toolbar-stack[layout=vertical]{block-size:100cqh;min-block-size:100%;max-block-size:100%}:host([data-intrinsic-toolbar-sizing]){min-inline-size:0;min-block-size:0;max-inline-size:100%;max-block-size:100%;arcgis-toolbar-stack[layout=vertical]{block-size:100%}}:host([data-intrinsic-toolbar-sizing][layout="vertical"]){display:grid;grid-template-columns:minmax(min-content,1fr);grid-template-rows:minmax(0,1fr);inline-size:fit-content;block-size:100%;.toolbar-container{block-size:auto}.toolbar-container,arcgis-view-popover{grid-area:1 / 1}}:host([data-intrinsic-toolbar-sizing][layout="vertical"][toolbar-kind="floating"]){block-size:auto}`, Ce = {
39
39
  point: "pin",
40
40
  polyline: "line",
41
41
  polygon: "polygon",
@@ -79,9 +79,9 @@ const be = q`.editing-controls-panel{min-inline-size:100px;max-inline-size:400px
79
79
  preferEndSlot: !0
80
80
  }
81
81
  };
82
- var we = Object.defineProperty, Te = Object.getOwnPropertyDescriptor, h = (i, e, t, o) => {
83
- for (var s = o > 1 ? void 0 : o ? Te(e, t) : e, n = i.length - 1, u; n >= 0; n--)
84
- (u = i[n]) && (s = (o ? u(e, t, s) : u(s)) || s);
82
+ var we = Object.defineProperty, Te = Object.getOwnPropertyDescriptor, p = (i, e, t, o) => {
83
+ for (var s = o > 1 ? void 0 : o ? Te(e, t) : e, n = i.length - 1, d; n >= 0; n--)
84
+ (d = i[n]) && (s = (o ? d(e, t, s) : d(s)) || s);
85
85
  return o && s && we(e, t, s), s;
86
86
  };
87
87
  let c = class extends ce {
@@ -106,7 +106,7 @@ let c = class extends ce {
106
106
  },
107
107
  { sync: !0 }
108
108
  ),
109
- ue({
109
+ ge({
110
110
  getLoading: () => this.sketchViewModel?.geometrySimplificationInProgress ?? !1,
111
111
  setEffectiveLoading: (i) => {
112
112
  this._effectiveGeometrySimplificationInProgress = i;
@@ -206,25 +206,25 @@ let c = class extends ce {
206
206
  const { sketchViewModel: i } = this;
207
207
  if (!i)
208
208
  return [];
209
- const e = i.effectiveAvailablePlugins, t = this.state === "disabled", o = this.visibleElements.createTools, s = this.activeTool, n = this._activeCustomToolOptions, u = n || !i.firstPluginWithSwappableLeaf ? this._customToolOptions : [], a = i.rootPlugins, r = u?.map((l) => ({
210
- active: l === n,
209
+ const e = i.effectiveAvailablePlugins, t = this.state === "disabled", o = this.visibleElements.createTools, s = this.activeTool, n = this._activeCustomToolOptions, d = n || !i.firstPluginWithSwappableLeaf ? this._customToolOptions : [], l = i.rootPlugins, r = d?.map((a) => ({
210
+ active: a === n,
211
211
  disabled: t,
212
- icon: l.icon,
213
- labelKey: l.label,
214
- onClick: l === n ? () => this._cancelActiveOperation() : () => this._activateLegacyDrawTool(l.toolName, l.createOptions, l)
212
+ icon: a.icon,
213
+ labelKey: a.label,
214
+ onClick: a === n ? () => this._cancelActiveOperation() : () => this._activateLegacyDrawTool(a.toolName, a.createOptions, a)
215
215
  })) ?? [];
216
- if (n && a)
217
- return [...this._pluginsToActions(a), ...r];
216
+ if (n && l)
217
+ return [...this._pluginsToActions(l), ...r];
218
218
  if (e?.length && this.view?.type !== "3d")
219
219
  return [...this._pluginsToActions(e), ...r];
220
- const d = this.view?.type === "3d";
220
+ const h = this.view?.type === "3d";
221
221
  return [
222
- ...this.availableCreateTools?.filter((l) => d && l === "multipoint" ? !1 : l === "mesh" ? !0 : o[l])?.map((l) => ({
223
- active: l === s,
222
+ ...this.availableCreateTools?.filter((a) => h && a === "multipoint" ? !1 : a === "mesh" ? !0 : o[a])?.map((a) => ({
223
+ active: a === s,
224
224
  disabled: t,
225
- icon: Ce[l],
226
- labelKey: `draw.${l}`,
227
- onClick: l === s ? () => this._cancelActiveOperation() : () => this._activateLegacyDrawTool(l)
225
+ icon: Ce[a],
226
+ labelKey: `draw.${a}`,
227
+ onClick: a === s ? () => this._cancelActiveOperation() : () => this._activateLegacyDrawTool(a)
228
228
  })) ?? [],
229
229
  ...r
230
230
  ];
@@ -282,22 +282,22 @@ let c = class extends ce {
282
282
  labelKey: "selectFeature",
283
283
  onClick: () => this._activateDefaultSelectionTool()
284
284
  });
285
- const u = e.selectionTools;
286
- u["rectangle-selection"] && n.push({
285
+ const d = e.selectionTools;
286
+ d["rectangle-selection"] && n.push({
287
287
  active: t === "rectangle-selection",
288
288
  disabled: s,
289
289
  icon: "cursor-marquee",
290
290
  labelKey: "rectangleSelection",
291
291
  onClick: () => this._activateSelectionTool("rectangle-selection")
292
- }), u["lasso-selection"] && n.push({
292
+ }), d["lasso-selection"] && n.push({
293
293
  active: t === "lasso-selection",
294
294
  disabled: s,
295
295
  icon: "lasso-select",
296
296
  labelKey: "lassoSelection",
297
297
  onClick: () => this._activateSelectionTool("lasso-selection")
298
298
  });
299
- const a = o?.get("selection-toolbar");
300
- return a && n.push(...this._customActionsToSketchActions(a)), n;
299
+ const l = o?.get("selection-toolbar");
300
+ return l && n.push(...this._customActionsToSketchActions(l)), n;
301
301
  }
302
302
  get _selectionSetActions() {
303
303
  const i = this.sketchViewModel?.updateGraphics.length ?? 0;
@@ -570,88 +570,88 @@ let c = class extends ce {
570
570
  }
571
571
  // #endregion
572
572
  };
573
- h([
574
- p()
573
+ p([
574
+ g()
575
575
  ], c.prototype, "_isEffectiveRenderStateFrozen", 1);
576
- h([
577
- p()
576
+ p([
577
+ g()
578
578
  ], c.prototype, "_effectiveGeometrySimplificationInProgress", 2);
579
- h([
580
- p()
579
+ p([
580
+ g()
581
581
  ], c.prototype, "_state", 1);
582
- h([
583
- p()
582
+ p([
583
+ g()
584
584
  ], c.prototype, "_customToolOptions", 2);
585
- h([
586
- p()
585
+ p([
586
+ g()
587
587
  ], c.prototype, "_activeCustomToolOptions", 2);
588
- h([
589
- p()
588
+ p([
589
+ g()
590
590
  ], c.prototype, "_customActions", 2);
591
- h([
592
- p()
591
+ p([
592
+ g()
593
593
  ], c.prototype, "selectionViewModel", 2);
594
- h([
595
- p()
594
+ p([
595
+ g()
596
596
  ], c.prototype, "_activeSelectionTool", 1);
597
- h([
598
- p()
597
+ p([
598
+ g()
599
599
  ], c.prototype, "_activePluginUniqueIds", 1);
600
- h([
601
- p()
600
+ p([
601
+ g()
602
602
  ], c.prototype, "_createToolActions", 1);
603
- h([
604
- p()
603
+ p([
604
+ g()
605
605
  ], c.prototype, "_shouldShowBackButton", 1);
606
- h([
607
- p()
606
+ p([
607
+ g()
608
608
  ], c.prototype, "_selectionToolActions", 1);
609
- h([
610
- p()
609
+ p([
610
+ g()
611
611
  ], c.prototype, "_settingsActions", 1);
612
- h([
613
- p()
612
+ p([
613
+ g()
614
614
  ], c.prototype, "_activeTool", 1);
615
- h([
616
- p()
615
+ p([
616
+ g()
617
617
  ], c.prototype, "_selectionCommands", 1);
618
- h([
619
- p()
618
+ p([
619
+ g()
620
620
  ], c.prototype, "_selectionSetActions", 1);
621
- h([
622
- p()
621
+ p([
622
+ g()
623
623
  ], c.prototype, "_undoRedoActions", 1);
624
- h([
625
- p()
624
+ p([
625
+ g()
626
626
  ], c.prototype, "sketchViewModel", 2);
627
- h([
628
- p()
627
+ p([
628
+ g()
629
629
  ], c.prototype, "visibleElements", 2);
630
- h([
631
- p()
630
+ p([
631
+ g()
632
632
  ], c.prototype, "view", 2);
633
- h([
634
- p()
633
+ p([
634
+ g()
635
635
  ], c.prototype, "settingsPopoverOpen", 2);
636
- h([
637
- p()
636
+ p([
637
+ g()
638
638
  ], c.prototype, "availableCreateTools", 2);
639
- h([
640
- p()
639
+ p([
640
+ g()
641
641
  ], c.prototype, "state", 1);
642
- h([
643
- p()
642
+ p([
643
+ g()
644
644
  ], c.prototype, "activeTool", 1);
645
- h([
646
- p()
645
+ p([
646
+ g()
647
647
  ], c.prototype, "activePluginIds", 1);
648
- h([
649
- p()
648
+ p([
649
+ g()
650
650
  ], c.prototype, "groupedActions", 1);
651
- c = h([
651
+ c = p([
652
652
  he("components.sketch.SketchComponentViewModel")
653
653
  ], c);
654
- class Ee extends ge {
654
+ class Ee extends ue {
655
655
  #t;
656
656
  #e = !1;
657
657
  #i;
@@ -660,7 +660,7 @@ class Ee extends ge {
660
660
  throw new Error("nodeHooks() can only be used on elements");
661
661
  }
662
662
  render(e) {
663
- return I;
663
+ return z;
664
664
  }
665
665
  update(e, [t]) {
666
666
  const o = e.element;
@@ -669,7 +669,7 @@ class Ee extends ge {
669
669
  const s = this.#e ? t.afterUpdate : t.afterCreate;
670
670
  return this.#t = o, this.#e = !0, this.#i = t, queueMicrotask(() => {
671
671
  o.isConnected && s?.(o);
672
- }), I;
672
+ }), z;
673
673
  }
674
674
  disconnected() {
675
675
  const e = this.#t, t = this.#i?.afterRemoved;
@@ -678,8 +678,8 @@ class Ee extends ge {
678
678
  });
679
679
  }
680
680
  }
681
- const W = me(Ee), _e = /* @__PURE__ */ new Set(["arcgis-map", "arcgis-scene"]), Me = 8;
682
- class Pe extends J {
681
+ const B = me(Ee), _e = /* @__PURE__ */ new Set(["arcgis-map", "arcgis-scene"]), Me = 8;
682
+ class ke extends J {
683
683
  constructor(e) {
684
684
  super(e), this.#t = new MutationObserver(() => this.#c()), this.#e = new ResizeObserver(() => this.#v()), this.#i = new ResizeObserver(([t]) => {
685
685
  if (!t)
@@ -688,13 +688,13 @@ class Pe extends J {
688
688
  o !== this.#s && (this.#s = o, this.#v());
689
689
  }), this.#h = [], this.ref = (t) => {
690
690
  this.#o !== t && (this.#o = t, this.#r = void 0, this.#a = void 0, this.#c());
691
- }, this.#u = () => this.#c(), this.exports = void 0, this.onConnected(() => this.#m()), this.onUpdated(() => {
692
- this.#d !== this.component.layout && this.#c();
693
- }), this.onDisconnected(() => this.#b()), this.onLifecycle(
691
+ }, this.#u = () => this.#c(), this.exports = void 0, e.listenOn(window, "resize", () => this.#g()), this.onConnected(() => this.#g()), this.onUpdated(() => {
692
+ (this.#d !== this.component.layout || this.#f !== this.component.toolbarKind) && this.#c();
693
+ }), this.onDisconnected(() => this.#C()), this.onLifecycle(
694
694
  () => v(
695
695
  () => this.component.view?.attributionHeight,
696
696
  () => {
697
- this.#m();
697
+ this.#g();
698
698
  },
699
699
  { initial: !0 }
700
700
  )
@@ -709,44 +709,46 @@ class Pe extends J {
709
709
  #s;
710
710
  #n;
711
711
  #h;
712
- #g;
712
+ #m;
713
713
  #o;
714
714
  /** Last style-write inputs, used to avoid repeating equivalent writes from observer notifications. */
715
715
  #r;
716
716
  #a;
717
717
  /** Layout for which the current context was synchronized; distinct from the last applied style layout. */
718
718
  #d;
719
+ #f;
719
720
  /** Re-uses the same direction observation helper as useDirection; that API has onLifecycle-based cleanup API. */
720
721
  #p;
721
- #m() {
722
+ #g() {
722
723
  queueMicrotask(() => {
723
724
  this.component.el.isConnected && this.#c();
724
725
  });
725
726
  }
726
727
  #c() {
727
- const e = this.#f();
728
- if (!e) {
729
- this.#y(), this.#b();
728
+ this.#f = this.component.toolbarKind;
729
+ const e = this.#y();
730
+ if (this.component.el.toggleAttribute("data-intrinsic-toolbar-sizing", !e), !e) {
731
+ this.#b(), this.#C();
730
732
  return;
731
733
  }
732
- this.#C(e.toolbar), this.#S(e), this.#w(e), this.#v(e);
734
+ this.#S(e.toolbar), this.#w(e), this.#T(e), this.#v(e);
733
735
  }
734
- #f() {
736
+ #y() {
735
737
  const e = this.component.el, t = e.parentElement, o = this.#o, s = e.assignedSlot;
736
738
  if (!t || !_e.has(t.localName) || !o || !s?.parentElement)
737
739
  return;
738
- const n = getComputedStyle(t).direction === "rtl" ? "rtl" : "ltr", u = U(e.slot, n);
739
- if (!u)
740
+ const n = getComputedStyle(t).direction === "rtl" ? "rtl" : "ltr", d = K(e.slot, n);
741
+ if (!d)
740
742
  return;
741
- const a = Array.from(t.children).filter(
743
+ const l = Array.from(t.children).filter(
742
744
  (r) => r instanceof HTMLElement && r.localName !== "arcgis-sketch"
743
745
  );
744
746
  return {
745
747
  assignedSlot: s,
746
- content: a,
748
+ content: l,
747
749
  direction: n,
748
750
  parent: t,
749
- position: u,
751
+ position: d,
750
752
  toolbar: o
751
753
  };
752
754
  }
@@ -754,104 +756,112 @@ class Pe extends J {
754
756
  /**
755
757
  * Keep track of the cross-axis size changes to ensure layout solution remains up-to-date.
756
758
  */
757
- #C(e) {
759
+ #S(e) {
758
760
  this.#d !== this.component.layout && (this.#s = void 0, this.#d = this.component.layout), this.#l !== e && (this.#i.disconnect(), this.#l = e, this.#s = void 0, this.#i.observe(e));
759
761
  }
760
- #S(e) {
762
+ #w(e) {
761
763
  const t = e.assignedSlot;
762
- this.#n !== t && (this.#n?.removeEventListener("slotchange", this.#u), this.#n = t, t.addEventListener("slotchange", this.#u)), this.#g !== e.parent && (this.#t.disconnect(), this.#p?.(), this.#g = e.parent, this.#p = ye(e.parent, ["dir"], () => {
763
- this.#m();
764
+ this.#n !== t && (this.#n?.removeEventListener("slotchange", this.#u), this.#n = t, t.addEventListener("slotchange", this.#u)), this.#m !== e.parent && (this.#t.disconnect(), this.#p?.(), this.#m = e.parent, this.#p = ye(e.parent, ["dir"], () => {
765
+ this.#g();
764
766
  }), this.#t.observe(e.parent, {
765
767
  childList: !0,
766
768
  subtree: !1
767
769
  }));
768
770
  }
769
- #w(e) {
771
+ #T(e) {
770
772
  const t = [e.parent, ...e.content];
771
- Oe(this.#h, t) || (this.#e.disconnect(), t.forEach((o) => this.#e.observe(o)), this.#h = t);
773
+ Le(this.#h, t) || (this.#e.disconnect(), t.forEach((o) => this.#e.observe(o)), this.#h = t);
772
774
  }
773
- #v(e = this.#f()) {
775
+ #v(e = this.#y()) {
774
776
  if (!e) {
775
- this.#y();
777
+ this.#b();
776
778
  return;
777
779
  }
778
- const t = this.component.layout, o = ke({
780
+ const t = this.component.layout, o = e.parent.getBoundingClientRect(), s = Pe({
779
781
  content: Ae(e),
780
782
  gap: Me,
781
783
  layout: t,
782
784
  position: e.position,
783
- sameSlotReserve: Le(e.assignedSlot, this.component.el, t, e.assignedSlot),
785
+ sameSlotReserve: Oe(e.assignedSlot, this.component.el, t, e.assignedSlot),
784
786
  toolbarBounds: e.toolbar.getBoundingClientRect(),
785
- viewBounds: e.parent.getBoundingClientRect()
787
+ viewBounds: o
786
788
  });
787
- this.#T(e.toolbar, t, o);
789
+ let n = s;
790
+ if (e.toolbar.toolbarKind === "floating") {
791
+ const d = getComputedStyle(e.assignedSlot.parentElement.parentElement), l = Math.max(Number.parseFloat(d.marginLeft), Number.parseFloat(d.marginRight)), r = t === "horizontal" ? window.innerWidth : window.innerHeight, h = t === "horizontal" ? o.width : o.height, u = t === "vertical" ? this.component.view?.attributionHeight ?? 0 : 0;
792
+ n = Math.max(
793
+ 0,
794
+ Math.min(s, h - 2 * l - u, r - 2 * l)
795
+ );
796
+ }
797
+ this.#E(e.toolbar, t, s, n);
788
798
  }
789
- #T(e, t, o) {
790
- o === this.#r && t === this.#a || (this.#r = o, this.#a = t, e.style.setProperty("--arcgis-internal-toolbar-available-length", `${o}px`), t === "horizontal" ? (e.style.height = "", e.style.maxHeight = "", e.style.maxWidth = `${o}px`, e.style.width = "fit-content") : (e.style.height = "fit-content", e.style.maxHeight = `${o}px`, e.style.maxWidth = "", e.style.width = ""));
799
+ #E(e, t, o, s) {
800
+ o === this.#r && s === e.allocatedLength && t === this.#a || (this.#r = o, this.#a = t, e.allocatedLength = s, t === "horizontal" ? (e.style.height = "", e.style.maxHeight = "", e.style.maxWidth = `${o}px`, e.style.width = "fit-content") : (e.style.height = "fit-content", e.style.maxHeight = `${o}px`, e.style.maxWidth = "", e.style.width = ""));
791
801
  }
792
802
  /** Remove controller-owned inline sizing when the stack leaves a supported view slot. */
793
- #y() {
794
- this.#o && (this.#o.style.maxHeight = "", this.#o.style.maxWidth = "", this.#o.style.height = "", this.#o.style.width = "", this.#o.style.removeProperty("--arcgis-internal-toolbar-available-length"), this.#r = void 0, this.#a = void 0);
803
+ #b() {
804
+ this.#o && (this.#o.style.maxHeight = "", this.#o.style.maxWidth = "", this.#o.style.height = "", this.#o.style.width = "", this.#o.allocatedLength = void 0, this.#r = void 0, this.#a = void 0);
795
805
  }
796
806
  /** Release subscriptions and cached measurements before disconnecting or entering a new context. */
797
- #b() {
798
- this.#t.disconnect(), this.#p?.(), this.#p = void 0, this.#e.disconnect(), this.#i.disconnect(), this.#l = void 0, this.#s = void 0, this.#h = [], this.#n?.removeEventListener("slotchange", this.#u), this.#n = void 0, this.#r = void 0, this.#a = void 0, this.#d = void 0, this.#g = void 0;
807
+ #C() {
808
+ this.#t.disconnect(), this.#p?.(), this.#p = void 0, this.#e.disconnect(), this.#i.disconnect(), this.#l = void 0, this.#s = void 0, this.#h = [], this.#n?.removeEventListener("slotchange", this.#u), this.#n = void 0, this.#r = void 0, this.#a = void 0, this.#d = void 0, this.#m = void 0;
799
809
  }
800
810
  }
801
- function ke({
811
+ function Pe({
802
812
  content: i,
803
813
  gap: e,
804
814
  layout: t,
805
815
  position: o,
806
816
  sameSlotReserve: s,
807
817
  toolbarBounds: n,
808
- viewBounds: u
818
+ viewBounds: d
809
819
  }) {
810
- const a = L(u, t), r = L(n, t), d = z(o, t), g = d ? r.start - a.start : a.end - r.end;
811
- let l = 0, f = !1;
820
+ const l = O(d, t), r = O(n, t), h = W(o, t), u = h ? r.start - l.start : l.end - r.end;
821
+ let a = 0, f = !1;
812
822
  for (const C of i) {
813
- if (z(C.position, t) === d)
823
+ if (W(C.position, t) === h)
814
824
  continue;
815
- const y = L(C.bounds, t);
825
+ const y = O(C.bounds, t);
816
826
  if (!(y.crossStart < r.crossEnd && y.crossEnd > r.crossStart))
817
827
  continue;
818
- const w = d ? a.end - y.start : y.end - a.start;
819
- l = Math.max(l, w), f = !0;
828
+ const w = h ? l.end - y.start : y.end - l.start;
829
+ a = Math.max(a, w), f = !0;
820
830
  }
821
831
  const m = f ? e : 0;
822
- return Math.max(0, a.length - Math.max(0, g) - s - l - m);
832
+ return Math.max(0, l.length - Math.max(0, u) - s - a - m);
823
833
  }
824
- function L(i, e) {
834
+ function O(i, e) {
825
835
  return e === "horizontal" ? { start: i.left, end: i.right, length: i.width, crossStart: i.top, crossEnd: i.bottom } : { start: i.top, end: i.bottom, length: i.height, crossStart: i.left, crossEnd: i.right };
826
836
  }
827
- function z(i, e) {
837
+ function W(i, e) {
828
838
  return e === "horizontal" ? i.endsWith("left") : i.startsWith("top");
829
839
  }
830
840
  function Ae(i) {
831
841
  return i.content.flatMap((e) => {
832
842
  if (e.assignedSlot === i.assignedSlot)
833
843
  return [];
834
- const t = U(e.slot, i.direction);
844
+ const t = K(e.slot, i.direction);
835
845
  return t ? [{ bounds: e.getBoundingClientRect(), position: t }] : [];
836
846
  });
837
847
  }
838
- function Oe(i, e) {
848
+ function Le(i, e) {
839
849
  return i.length === e.length && i.every((t, o) => t === e[o]);
840
850
  }
841
- function Le(i, e, t, o) {
851
+ function Oe(i, e, t, o) {
842
852
  const s = getComputedStyle(o), n = s.flexDirection;
843
853
  if (!(t === "horizontal" ? n.startsWith("row") : n.startsWith("column")))
844
854
  return 0;
845
- const a = i.assignedElements().filter((m) => m instanceof HTMLElement), r = a.indexOf(e);
855
+ const l = i.assignedElements().filter((m) => m instanceof HTMLElement), r = l.indexOf(e);
846
856
  if (r < 0)
847
857
  return 0;
848
- const d = getComputedStyle(e), g = n === "row" ? Number.parseFloat(d.marginRight) : n === "row-reverse" ? Number.parseFloat(d.marginLeft) : n === "column" ? Number.parseFloat(d.marginBottom) : Number.parseFloat(d.marginTop), l = a.slice(r + 1), f = Number.parseFloat(t === "horizontal" ? s.columnGap : s.rowGap);
849
- return l.reduce((m, C) => {
858
+ const h = getComputedStyle(e), u = n === "row" ? Number.parseFloat(h.marginRight) : n === "row-reverse" ? Number.parseFloat(h.marginLeft) : n === "column" ? Number.parseFloat(h.marginBottom) : Number.parseFloat(h.marginTop), a = l.slice(r + 1), f = Number.parseFloat(t === "horizontal" ? s.columnGap : s.rowGap);
859
+ return a.reduce((m, C) => {
850
860
  const y = C.getBoundingClientRect(), S = getComputedStyle(C), w = t === "horizontal" ? y.width + Number.parseFloat(S.marginLeft) + Number.parseFloat(S.marginRight) : y.height + Number.parseFloat(S.marginTop) + Number.parseFloat(S.marginBottom);
851
861
  return m + w + f;
852
- }, g);
862
+ }, u);
853
863
  }
854
- function U(i, e) {
864
+ function K(i, e) {
855
865
  const [t, o] = i.split("-");
856
866
  if (t !== "bottom" && t !== "top")
857
867
  return;
@@ -867,18 +877,18 @@ const Ge = [
867
877
  "top-start",
868
878
  "top-left",
869
879
  "top-right"
870
- ], $e = new Set(Ge), Re = ne((i) => new le({
880
+ ], Re = new Set(Ge), Ve = ne((i) => new le({
871
881
  ...i,
872
882
  cancelUpdateOnClickAway: !0,
873
883
  creationMode: "continuous",
874
884
  textSymbol: new Z({ text: "hello world" }),
875
885
  useLegacyCreateTools: !1
876
886
  }));
877
- class Ve extends ee {
887
+ class $e extends ee {
878
888
  constructor() {
879
- super(), this.#t = new c(), this.#l = O(), this.#s = new Pe(this), this.#n = O(), this._defaultGraphicsLayer = null, this._messages = se(), this.test = {
889
+ super(), this.#t = new c(), this.#l = L(), this.#s = new ke(this), this.#n = L(), this._defaultGraphicsLayer = null, this._messages = se(), this.test = {
880
890
  componentViewModel: this.#t
881
- }, this._groupLayoutPriorityOverrides = /* @__PURE__ */ new Map(), this._contextualToolLocation = "separate", this._refMap = ae(), this.viewModel = Re(this), this.view = this.viewModel.view, this.autoDestroyDisabled = !1, this.createGraphic = this.viewModel.createGraphic, this.creationMode = this.viewModel.creationMode, this.defaultCreateOptions = this.viewModel.defaultCreateOptions, this.defaultGraphicsLayerDisabled = !1, this.defaultUpdateOptions = this.viewModel.defaultUpdateOptions, this.geometrySimplificationInProgress = this.viewModel.geometrySimplificationInProgress, this.icon = "pencil", this.label = this._messages?.componentLabel, this.labelOptions = this.viewModel.labelOptions, this.layer = this.viewModel.layer, this.layout = "horizontal", this.pointSymbol = this.viewModel.pointSymbol, this.polygonSymbol = this.viewModel.polygonSymbol, this.polylineSymbol = this.viewModel.polylineSymbol, this.activeFillSymbol = this.viewModel.activeFillSymbol, this.activeLineSymbol = this.viewModel.activeLineSymbol, this.activeVertexSymbol = this.viewModel.activeVertexSymbol, this.activeCreateToolDrawMode = this.viewModel.activeCreateToolDrawMode, this.visualScale = "m", this.snappingOptions = this.viewModel.snappingOptions, this.textSymbol = this.viewModel.textSymbol, this.toolbarKind = "floating", this.tooltipOptions = this.viewModel.tooltipOptions, this.useViewOptions = this.viewModel.useViewOptions, this.valueOptions = this.viewModel.valueOptions, this.useLegacyCreateTools = this.viewModel.useLegacyCreateTools, this.updateOnGraphicClickDisabled = this.viewModel.updateOnGraphicClick, this.updateGraphics = this.viewModel.updateGraphics, this.activeTooltip = this.viewModel.activeTooltip, this.arcgisCreate = T(() => this.viewModel, "create"), this.arcgisDelete = T(() => this.viewModel, "delete"), this.arcgisDuplicate = T(() => this.viewModel, "duplicate"), this.arcgisPropertyChange = Q()("activeTool", "geometrySimplificationInProgress", "state"), this.arcgisReady = te(), this.arcgisRedo = T(() => this.viewModel, "redo"), this.arcgisUndo = T(() => this.viewModel, "undo"), this.arcgisUpdate = T(() => this.viewModel, "update"), X(["slot"], () => {
891
+ }, this._groupLayoutPriorityOverrides = /* @__PURE__ */ new Map(), this._contextualToolLocation = "separate", this._refMap = ae(), this.viewModel = Ve(this), this.view = this.viewModel.view, this.autoDestroyDisabled = !1, this.createGraphic = this.viewModel.createGraphic, this.creationMode = this.viewModel.creationMode, this.defaultCreateOptions = this.viewModel.defaultCreateOptions, this.defaultGraphicsLayerDisabled = !1, this.defaultUpdateOptions = this.viewModel.defaultUpdateOptions, this.geometrySimplificationInProgress = this.viewModel.geometrySimplificationInProgress, this.icon = "pencil", this.label = this._messages?.componentLabel, this.labelOptions = this.viewModel.labelOptions, this.layer = this.viewModel.layer, this.layout = "horizontal", this.pointSymbol = this.viewModel.pointSymbol, this.polygonSymbol = this.viewModel.polygonSymbol, this.polylineSymbol = this.viewModel.polylineSymbol, this.activeFillSymbol = this.viewModel.activeFillSymbol, this.activeLineSymbol = this.viewModel.activeLineSymbol, this.activeVertexSymbol = this.viewModel.activeVertexSymbol, this.activeCreateToolDrawMode = this.viewModel.activeCreateToolDrawMode, this.visualScale = "m", this.snappingOptions = this.viewModel.snappingOptions, this.textSymbol = this.viewModel.textSymbol, this.toolbarKind = "floating", this.tooltipOptions = this.viewModel.tooltipOptions, this.useViewOptions = this.viewModel.useViewOptions, this.valueOptions = this.viewModel.valueOptions, this.useLegacyCreateTools = this.viewModel.useLegacyCreateTools, this.updateOnGraphicClickDisabled = this.viewModel.updateOnGraphicClick, this.updateGraphics = this.viewModel.updateGraphics, this.activeTooltip = this.viewModel.activeTooltip, this.arcgisCreate = T(() => this.viewModel, "create"), this.arcgisDelete = T(() => this.viewModel, "delete"), this.arcgisDuplicate = T(() => this.viewModel, "duplicate"), this.arcgisPropertyChange = Q()("activeTool", "geometrySimplificationInProgress", "state"), this.arcgisReady = te(), this.arcgisRedo = T(() => this.viewModel, "redo"), this.arcgisUndo = T(() => this.viewModel, "undo"), this.arcgisUpdate = T(() => this.viewModel, "update"), X(["slot"], () => {
882
892
  this.requestUpdate();
883
893
  }), this.manager.onLifecycle(() => [
884
894
  v(() => this.el.view?.map, (e, t) => {
@@ -900,7 +910,7 @@ class Ve extends ee {
900
910
  });
901
911
  }
902
912
  static {
903
- this.properties = { _groupLayoutPriorityOverrides: 16, _contextualToolLocation: 16, _refMap: 16, viewModel: 0, view: 0, activeTool: 32, autoDestroyDisabled: 5, visibleElements: 0, availableCreateTools: 0, createGraphic: 32, creationMode: 1, defaultCreateOptions: 0, defaultGraphicsLayerDisabled: 5, defaultUpdateOptions: 0, geometrySimplificationInProgress: 36, hideCreateToolsCircle: 5, hideCreateToolsMultipoint: 5, hideCreateToolsPoint: 5, hideCreateToolsPolygon: 5, hideCreateToolsPolyline: 5, hideCreateToolsRectangle: 5, hideDuplicateButton: 5, hideDeleteButton: 5, hideSelectionCountLabel: 5, hideLabelsToggle: 5, hideSelectionToolsLassoSelection: 5, hideSelectionToolsRectangleSelection: 5, hideSettingsMenu: 5, hideSinglePluginBackButton: 5, hideSnappingControls: 5, hideSnappingControlsElementsEnabledToggle: 5, hideSnappingControlsElementsFeatureEnabledToggle: 5, hideSnappingControlsElementsLayerList: 5, hideSnappingControlsElementsSelfEnabledToggle: 5, hideSnappingControlsElementsGridEnabledToggle: 5, hideSnappingControlsElementsGridControls: 5, hideSnappingControlsElementsGridControlsElementsColorSelection: 5, hideSnappingControlsElementsGridControlsElementsDynamicScaleToggle: 5, hideSnappingControlsElementsGridControlsElementsLineIntervalInput: 5, hideSnappingControlsElementsGridControlsElementsNumericInputs: 5, hideSnappingControlsElementsGridControlsElementsOutOfScaleWarning: 5, hideSnappingControlsElementsGridControlsElementsPlacementButtons: 5, hideSnappingControlsElementsGridControlsElementsRotateWithMapToggle: 5, hideTooltipsToggle: 5, hideUndoRedoMenu: 5, icon: 1, label: 1, labelOptions: 0, layer: 0, layout: 1, pointSymbol: 0, polygonSymbol: 0, polylineSymbol: 0, activeFillSymbol: 0, activeLineSymbol: 0, activeVertexSymbol: 0, activeCreateToolDrawMode: 1, referenceElement: 1, relativePosition: 1, scale: 1, visualScale: 1, showSnappingControlsElementsHeader: 5, showCreateToolsFreehandPolygon: 5, showCreateToolsFreehandPolyline: 5, showCreateToolsText: 5, hideGeometrySimplificationActivityIndicator: 5, snappingOptions: 0, state: 32, textSymbol: 0, toolbarKind: 1, tooltipOptions: 0, useViewOptions: 5, valueOptions: 0, useLegacyCreateTools: 5, updateOnGraphicClickDisabled: 5, cancelUpdateOnClickAwayDisabled: 5, updateGraphics: 32, activeTooltip: 0 };
913
+ this.properties = { _groupLayoutPriorityOverrides: 16, _contextualToolLocation: 16, _refMap: 16, viewModel: 0, view: 0, activeTool: 32, autoDestroyDisabled: 5, visibleElements: 0, availableCreateTools: 0, createGraphic: 32, creationMode: 1, defaultCreateOptions: 0, defaultGraphicsLayerDisabled: 5, defaultUpdateOptions: 0, geometrySimplificationInProgress: 36, hideCreateToolsCircle: 5, hideCreateToolsMultipoint: 5, hideCreateToolsPoint: 5, hideCreateToolsPolygon: 5, hideCreateToolsPolyline: 5, hideCreateToolsRectangle: 5, hideDuplicateButton: 5, hideDeleteButton: 5, hideSelectionCountLabel: 5, hideLabelsToggle: 5, hideSelectionToolsLassoSelection: 5, hideSelectionToolsRectangleSelection: 5, hideSettingsMenu: 5, hideSinglePluginBackButton: 5, hideSnappingControls: 5, hideSnappingControlsElementsEnabledToggle: 5, hideSnappingControlsElementsFeatureEnabledToggle: 5, hideSnappingControlsElementsLayerList: 5, hideSnappingControlsElementsSelfEnabledToggle: 5, hideSnappingControlsElementsGridEnabledToggle: 5, hideSnappingControlsElementsGridControls: 5, hideSnappingControlsElementsGridControlsElementsColorSelection: 5, hideSnappingControlsElementsGridControlsElementsDynamicScaleToggle: 5, hideSnappingControlsElementsGridControlsElementsLineIntervalInput: 5, hideSnappingControlsElementsGridControlsElementsNumericInputs: 5, hideSnappingControlsElementsGridControlsElementsOutOfScaleWarning: 5, hideSnappingControlsElementsGridControlsElementsPlacementButtons: 5, hideSnappingControlsElementsGridControlsElementsRotateWithMapToggle: 5, hideTooltipsToggle: 5, hideUndoRedoMenu: 5, icon: 1, label: 1, labelOptions: 0, layer: 0, layout: 3, pointSymbol: 0, polygonSymbol: 0, polylineSymbol: 0, activeFillSymbol: 0, activeLineSymbol: 0, activeVertexSymbol: 0, activeCreateToolDrawMode: 1, referenceElement: 1, relativePosition: 1, scale: 1, visualScale: 1, showSnappingControlsElementsHeader: 5, showCreateToolsFreehandPolygon: 5, showCreateToolsFreehandPolyline: 5, showCreateToolsText: 5, hideGeometrySimplificationActivityIndicator: 5, snappingOptions: 0, state: 32, textSymbol: 0, toolbarKind: 3, tooltipOptions: 0, useViewOptions: 5, valueOptions: 0, useLegacyCreateTools: 5, updateOnGraphicClickDisabled: 5, cancelUpdateOnClickAwayDisabled: 5, updateGraphics: 32, activeTooltip: 0 };
904
914
  }
905
915
  static {
906
916
  this.styles = be;
@@ -1109,8 +1119,8 @@ class Ve extends ee {
1109
1119
  this.#e.undoRedoMenu = !e;
1110
1120
  }
1111
1121
  get relativePosition() {
1112
- const e = this.el.slot;
1113
- return this.#i ?? ($e.has(e) ? e : re.topRight);
1122
+ const e = this.el.slot || this.el.closest("arcgis-expand")?.slot || "";
1123
+ return this.#i ?? (Re.has(e) ? e : re.topRight);
1114
1124
  }
1115
1125
  set relativePosition(e) {
1116
1126
  this.#i = e;
@@ -1233,46 +1243,46 @@ class Ve extends ee {
1233
1243
  this._defaultGraphicsLayer && this.view?.map?.allLayers.includes(this._defaultGraphicsLayer) && this.view?.map?.remove(this._defaultGraphicsLayer), this.cancel(), super.disconnectedCallback();
1234
1244
  }
1235
1245
  render() {
1236
- const e = this._refMap.get("settings")?.value?.actionElement, t = this.#t.groupedActions, { visualScale: o, layout: s, toolbarKind: n, relativePosition: u, _contextualToolLocation: a } = this, r = t.find(({ name: g }) => g === "selectionSet"), d = t.filter(({ name: g }) => g !== "selectionSet");
1237
- return b`<div class="toolbar-container"><arcgis-toolbar-stack .layout=${s} .toolbarKind=${n} .relativePosition=${u} .scale=${o} tooltip-appearance=calcite ${P(this.#s.ref)}><arcgis-toolbar ${P(this.#l)}>${M({ hidden: !r?.visible || a !== "inline", children: this._renderActionGroup(r) })}${d.map((g) => this._renderActionGroup(g))}${M({ hidden: !r?.visible || a !== "inline-end", children: this._renderActionGroup(r) })}</arcgis-toolbar>${M({ hidden: !r?.visible || a !== "separate", children: b`<arcgis-toolbar>${this._renderActionGroup(r)}</arcgis-toolbar>` })}</arcgis-toolbar-stack></div>${M({ hidden: this.hideSettingsMenu, children: b`<arcgis-view-popover .open=${this.#t.settingsPopoverOpen} closable .heading=${this._messages.settings?.heading} .label=${this._messages.settings?.heading} .anchorElement=${e} .visualScale=${o} .actionBarElement=${this.#l.value?.barElement} @arcgisPropertyChange=${(g) => this.#t.settingsPopoverOpen = g.target.open ?? !1} .view=${this.view ?? void 0}>${this._renderSettings()}</arcgis-view-popover>` })}`;
1246
+ const e = this._refMap.get("settings")?.value?.actionElement, t = this.#t.groupedActions, { visualScale: o, layout: s, toolbarKind: n, relativePosition: d, _contextualToolLocation: l } = this, r = t.find(({ name: u }) => u === "selectionSet"), h = t.filter(({ name: u }) => u !== "selectionSet");
1247
+ return b`<div class="toolbar-container"><arcgis-toolbar-stack .layout=${s} .toolbarKind=${n} .relativePosition=${d} .scale=${o} tooltip-appearance=calcite ${k(this.#s.ref)}><arcgis-toolbar ${k(this.#l)}>${M({ hidden: !r?.visible || l !== "inline", children: this._renderActionGroup(r) })}${h.map((u) => this._renderActionGroup(u))}${M({ hidden: !r?.visible || l !== "inline-end", children: this._renderActionGroup(r) })}</arcgis-toolbar>${M({ hidden: !r?.visible || l !== "separate", children: b`<arcgis-toolbar>${this._renderActionGroup(r)}</arcgis-toolbar>` })}</arcgis-toolbar-stack></div>${M({ hidden: this.hideSettingsMenu, children: b`<arcgis-view-popover .open=${this.#t.settingsPopoverOpen} .heading=${this._messages.settings?.heading} .anchorElement=${e} .visualScale=${o} .actionBarElement=${this.#l.value?.barElement} @arcgisPropertyChange=${(u) => this.#t.settingsPopoverOpen = u.target.open ?? !1}>${this._renderSettings()}</arcgis-view-popover>` })}`;
1238
1248
  }
1239
1249
  _renderSettings() {
1240
- const { autoDestroyDisabled: e, hideLabelsToggle: t, hideSnappingControls: o, hideTooltipsToggle: s, showSnappingControlsElementsHeader: n, useViewOptions: u, view: a, viewModel: r } = this;
1241
- return b`<div class="editing-controls-panel"><arcgis-sketch-tooltip-controls .hideLabelsToggle=${t} .hideTooltipsToggle=${u || s} .directionMode=${r.valueOptions.directionMode} .labelsEnabled=${r.labelOptions.enabled} .tooltipsEnabled=${r.tooltipOptions.enabled} @arcgisPropertyChange=${(d) => {
1242
- d.stopPropagation();
1243
- const { labelsEnabled: g, tooltipsEnabled: l, directionMode: f } = d.currentTarget, m = this.viewModel;
1244
- switch (d.detail.name) {
1250
+ const { autoDestroyDisabled: e, hideLabelsToggle: t, hideSnappingControls: o, hideTooltipsToggle: s, showSnappingControlsElementsHeader: n, useViewOptions: d, view: l, viewModel: r } = this;
1251
+ return b`<div class="editing-controls-panel"><arcgis-sketch-tooltip-controls .hideLabelsToggle=${t} .hideTooltipsToggle=${d || s} .directionMode=${r.valueOptions.directionMode} .labelsEnabled=${r.labelOptions.enabled} .tooltipsEnabled=${r.tooltipOptions.enabled} @arcgisPropertyChange=${(h) => {
1252
+ h.stopPropagation();
1253
+ const { labelsEnabled: u, tooltipsEnabled: a, directionMode: f } = h.currentTarget, m = this.viewModel;
1254
+ switch (h.detail.name) {
1245
1255
  case "labelsEnabled":
1246
- m.labelOptions.enabled = g;
1256
+ m.labelOptions.enabled = u;
1247
1257
  break;
1248
1258
  case "directionMode":
1249
1259
  m.valueOptions.directionMode = f;
1250
1260
  break;
1251
1261
  case "tooltipsEnabled":
1252
- m.tooltipOptions.enabled = l;
1262
+ m.tooltipOptions.enabled = a;
1253
1263
  break;
1254
1264
  }
1255
- }}></arcgis-sketch-tooltip-controls>${!u && !o ? b`<arcgis-snapping-controls .autoDestroyDisabled=${e} .view=${a} .visibleElements=${this.#e.snappingControlsElements} .snappingOptions=${r.snappingOptions} .showHeader=${n} @arcgisPropertyChange=${(d) => d.stopPropagation()}></arcgis-snapping-controls>` : void 0}</div>`;
1265
+ }}></arcgis-sketch-tooltip-controls>${!d && !o ? b`<arcgis-snapping-controls .autoDestroyDisabled=${e} .view=${l} .visibleElements=${this.#e.snappingControlsElements} .snappingOptions=${r.snappingOptions} .showHeader=${n} @arcgisPropertyChange=${(h) => h.stopPropagation()}></arcgis-snapping-controls>` : void 0}</div>`;
1256
1266
  }
1257
1267
  _renderActionGroup({ visible: e, commands: t, name: o }) {
1258
1268
  if (!e || !t.length)
1259
1269
  return;
1260
- const { defaultPriority: s, groupKind: n, overflowLabel: u, preferEndSlot: a } = Se[o], d = (o === "geometrySimplification" ? void 0 : this._groupLayoutPriorityOverrides.get(o)) ?? s, g = t.map((f) => this._renderCommand(f)), l = B(`more.${u}`, this._messages);
1270
+ const { defaultPriority: s, groupKind: n, overflowLabel: d, preferEndSlot: l } = Se[o], h = (o === "geometrySimplification" ? void 0 : this._groupLayoutPriorityOverrides.get(o)) ?? s, u = t.map((f) => this._renderCommand(f)), a = D(`more.${d}`, this._messages);
1261
1271
  switch (n) {
1262
1272
  case "more-button":
1263
- return b`<arcgis-toolbar-group .priority=${d} .preferEndSlot=${a}><arcgis-toolbar-more-button .overflowActionLabel=${l} .priority=${d}>${g}</arcgis-toolbar-more-button></arcgis-toolbar-group>`;
1273
+ return b`<arcgis-toolbar-group .priority=${h} .preferEndSlot=${l}><arcgis-toolbar-more-button .overflowActionLabel=${a} .priority=${h}>${u}</arcgis-toolbar-more-button></arcgis-toolbar-group>`;
1264
1274
  case "split-button":
1265
- return b`<arcgis-toolbar-group .priority=${d} .preferEndSlot=${a}><arcgis-toolbar-split-button .overflowActionLabel=${l} .priority=${d}>${g}</arcgis-toolbar-split-button></arcgis-toolbar-group>`;
1275
+ return b`<arcgis-toolbar-group .priority=${h} .preferEndSlot=${l}><arcgis-toolbar-split-button .overflowActionLabel=${a} .priority=${h}>${u}</arcgis-toolbar-split-button></arcgis-toolbar-group>`;
1266
1276
  case "actions":
1267
- return b`<arcgis-toolbar-group .priority=${d} .preferEndSlot=${a}>${g}</arcgis-toolbar-group>`;
1277
+ return b`<arcgis-toolbar-group .priority=${h} .preferEndSlot=${l}>${u}</arcgis-toolbar-group>`;
1268
1278
  }
1269
1279
  }
1270
- _renderCommand({ active: e, afterCreate: t, afterRemoved: o, afterUpdate: s, appearance: n, icon: u, disabled: a, id: r, kind: d, labelKey: g, labelParameters: l, loading: f, tooltipKey: m, iconFlipRTL: C, onClick: y, refKey: S, textEnabled: w, renderAsAction: K }) {
1271
- const { _messages: G, _refMap: H, layout: $ } = this, k = B(g, G), A = k === void 0 ? g : l ? j(k, l) : k, R = G?.[m] ?? A, V = S ? F(H, S, O) : this.#n, x = { afterCreate: t, afterRemoved: o, afterUpdate: s };
1272
- return K ? b`<arcgis-toolbar-action .active=${e} .appearance=${n} .disabled=${a} .icon=${u} .iconFlipRtl=${C} id=${r ?? D} .kind=${d} .loading=${f} .labelText=${$ === "horizontal" ? A : ""} .textEnabled=${w} .tooltipText=${$ === "horizontal" && w ? "" : R} @arcgisToolbarItemSelected=${y} ${W(x)} ${P(V)}></arcgis-toolbar-action>` : b`<arcgis-toolbar-item .active=${e} .disabled=${a} .icon=${u} id=${r ?? D} .iconFlipRtl=${C} .labelText=${A} .tooltipText=${R} @arcgisItemSelected=${y} ${W(x)} ${P(V)}></arcgis-toolbar-item>`;
1280
+ _renderCommand({ active: e, afterCreate: t, afterRemoved: o, afterUpdate: s, appearance: n, icon: d, disabled: l, id: r, kind: h, labelKey: u, labelParameters: a, loading: f, tooltipKey: m, iconFlipRTL: C, onClick: y, refKey: S, textEnabled: w, renderAsAction: U }) {
1281
+ const { _messages: G, _refMap: H, layout: R } = this, P = D(u, G), A = P === void 0 ? u : a ? j(P, a) : P, V = G?.[m] ?? A, $ = S ? F(H, S, L) : this.#n, x = { afterCreate: t, afterRemoved: o, afterUpdate: s };
1282
+ return U ? b`<arcgis-toolbar-action .active=${e} .appearance=${n} .disabled=${l} .icon=${d} .iconFlipRtl=${C} id=${r ?? I} .kind=${h} .loading=${f} .labelText=${R === "horizontal" ? A : ""} .textEnabled=${w} .tooltipText=${R === "horizontal" && w ? "" : V} @arcgisToolbarItemSelected=${y} ${B(x)} ${k($)}></arcgis-toolbar-action>` : b`<arcgis-toolbar-item .active=${e} .disabled=${l} .icon=${d} id=${r ?? I} .iconFlipRtl=${C} .labelText=${A} .tooltipText=${V} @arcgisItemSelected=${y} ${B(x)} ${k($)}></arcgis-toolbar-item>`;
1273
1283
  }
1274
1284
  }
1275
- N("arcgis-sketch", Ve);
1285
+ N("arcgis-sketch", $e);
1276
1286
  export {
1277
- Ve as ArcgisSketch
1287
+ $e as ArcgisSketch
1278
1288
  };