@arcgis/map-components 5.2.0-next.168 → 5.2.0-next.169
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cdn/{OP3MZHXU.js → 3YACO47M.js} +1 -1
- package/dist/cdn/42V6ISWG.js +2 -0
- package/dist/cdn/5VOAPFZ5.js +2 -0
- package/dist/cdn/6ZMVEWJQ.js +2 -0
- package/dist/cdn/{OQPX2UPC.js → AFY6JQ77.js} +1 -1
- package/dist/cdn/{VHM26W3Y.js → AW5FFER6.js} +1 -1
- package/dist/cdn/{NY6QZ4MA.js → ODY56P7R.js} +1 -1
- package/dist/cdn/OOCIGOT6.js +2 -0
- package/dist/cdn/{MZ47CPKO.js → RDBCKSUZ.js} +1 -1
- package/dist/cdn/{7XO4NAD5.js → WC5ZQ5SQ.js} +1 -1
- package/dist/cdn/index.js +1 -1
- package/dist/chunks/screenLocation.js +10 -10
- package/dist/components/arcgis-area-measurement-3d/customElement.d.ts +2 -1
- package/dist/components/arcgis-basemap-layer-list/customElement.d.ts +7 -7
- package/dist/components/arcgis-basemap-layer-list-next/customElement.d.ts +4 -4
- package/dist/components/arcgis-bookmarks/customElement.d.ts +1 -0
- package/dist/components/arcgis-bookmarks/types.d.ts +2 -2
- package/dist/components/arcgis-building-explorer/customElement.d.ts +5 -5
- package/dist/components/arcgis-catalog-layer-list/customElement.d.ts +4 -4
- package/dist/components/arcgis-catalog-layer-list-next/customElement.d.ts +2 -2
- package/dist/components/arcgis-daylight/customElement.d.ts +4 -4
- package/dist/components/arcgis-direct-line-measurement-3d/customElement.d.ts +4 -4
- package/dist/components/arcgis-directions/customElement.d.ts +4 -4
- package/dist/components/arcgis-editor/customElement.d.ts +19 -2
- package/dist/components/arcgis-expand/customElement.d.ts +2 -1
- package/dist/components/arcgis-feature-form/customElement.d.ts +7 -7
- package/dist/components/arcgis-feature-table/customElement.d.ts +25 -25
- package/dist/components/arcgis-features/customElement.d.ts +5 -5
- package/dist/components/arcgis-features-next/customElement.d.ts +4 -4
- package/dist/components/arcgis-features-next/customElement.js +27 -26
- package/dist/components/arcgis-grid-controls/customElement.d.ts +1 -1
- package/dist/components/arcgis-layer-list/customElement.d.ts +2 -2
- package/dist/components/arcgis-layer-list-next/customElement.d.ts +6 -6
- package/dist/components/arcgis-legend/customElement.d.ts +1 -1
- package/dist/components/arcgis-line-of-sight/customElement.d.ts +2 -2
- package/dist/components/arcgis-link-chart/customElement.d.ts +6 -6
- package/dist/components/arcgis-map/customElement.d.ts +13 -17
- package/dist/components/arcgis-oriented-imagery-viewer/customElement.d.ts +0 -1
- package/dist/components/arcgis-oriented-imagery-viewer-non-panoramic-viewer/customElement.js +6 -5
- package/dist/components/arcgis-oriented-imagery-viewer-panoramic-viewer/customElement.js +19 -18
- package/dist/components/arcgis-popup/customElement.d.ts +8 -7
- package/dist/components/arcgis-presentation/customElement.d.ts +5 -5
- package/dist/components/arcgis-presentation/customElement.js +74 -75
- package/dist/components/arcgis-print/customElement.d.ts +1 -1
- package/dist/components/arcgis-scale-range-slider/customElement.d.ts +4 -4
- package/dist/components/arcgis-scene/customElement.d.ts +10 -13
- package/dist/components/arcgis-search/customElement.d.ts +4 -4
- package/dist/components/arcgis-selection-list/customElement.d.ts +2 -2
- package/dist/components/arcgis-selection-toolbar/customElement.d.ts +6 -6
- package/dist/components/arcgis-sketch/SketchComponentViewModel.d.ts +1 -1
- package/dist/components/arcgis-sketch/customElement.d.ts +20 -2
- package/dist/components/arcgis-sketch/customElement.js +18 -11
- package/dist/components/arcgis-slice/customElement.d.ts +2 -2
- package/dist/components/arcgis-slider-binary-color-size-legacy/customElement.d.ts +4 -3
- package/dist/components/arcgis-slider-classed-color-legacy/customElement.d.ts +2 -2
- package/dist/components/arcgis-slider-classed-size-legacy/customElement.d.ts +3 -3
- package/dist/components/arcgis-slider-color-legacy/customElement.d.ts +3 -3
- package/dist/components/arcgis-slider-color-size-legacy/customElement.d.ts +5 -4
- package/dist/components/arcgis-slider-heatmap-legacy/customElement.d.ts +2 -2
- package/dist/components/arcgis-slider-opacity-legacy/customElement.d.ts +2 -2
- package/dist/components/arcgis-slider-scale-range/customElement.d.ts +4 -4
- package/dist/components/arcgis-slider-size-legacy/customElement.d.ts +3 -3
- package/dist/components/arcgis-table-list-next/customElement.js +5 -5
- package/dist/components/arcgis-time-slider/customElement.d.ts +6 -5
- package/dist/components/arcgis-track/customElement.d.ts +4 -4
- package/dist/components/arcgis-utility-network-associations/customElement.d.ts +1 -1
- package/dist/components/arcgis-utility-network-trace-analysis/customElement.d.ts +1 -1
- package/dist/components/arcgis-utility-network-trace-analysis/types.d.ts +272 -9
- package/dist/components/arcgis-utility-network-trace-configuration-picker/customElement.d.ts +1 -1
- package/dist/components/arcgis-utility-network-trace-configuration-picker/customElement.js +25 -33
- package/dist/components/arcgis-utility-network-trace-locations/customElement.d.ts +1 -1
- package/dist/components/arcgis-value-picker-legacy/customElement.d.ts +14 -16
- package/dist/components/arcgis-video/customElement.d.ts +1 -1
- package/dist/components/arcgis-volume-measurement/customElement.d.ts +2 -2
- package/dist/components/arcgis-weather/customElement.d.ts +1 -1
- package/dist/components/slider-legacy/types.d.ts +2 -3
- package/dist/docs/api.json +1 -1
- package/dist/docs/docs.json +1 -1
- package/dist/docs/vscode.html-custom-data.json +1 -1
- package/dist/docs/web-types.json +1 -1
- package/package.json +6 -6
- package/dist/cdn/2IAD3DI5.js +0 -2
- package/dist/cdn/67UW6MJM.js +0 -2
- package/dist/cdn/C6T7AQOJ.js +0 -2
- package/dist/cdn/CL5JQN4B.js +0 -2
|
@@ -87,7 +87,7 @@ export abstract class ArcgisTrack extends LitElement {
|
|
|
87
87
|
*/
|
|
88
88
|
accessor geolocationOptions: PositionOptions | undefined;
|
|
89
89
|
/**
|
|
90
|
-
* Indicates whether
|
|
90
|
+
* Indicates whether navigation to the position and scale of the geolocated result is disabled.
|
|
91
91
|
*
|
|
92
92
|
* @default false
|
|
93
93
|
*/
|
|
@@ -176,7 +176,7 @@ export abstract class ArcgisTrack extends LitElement {
|
|
|
176
176
|
*
|
|
177
177
|
* @since 4.27
|
|
178
178
|
* @example
|
|
179
|
-
* // Exclude locations that
|
|
179
|
+
* // Exclude locations that fall outside an extent.
|
|
180
180
|
* trackComponent.positionFilterFunction = (value) => {
|
|
181
181
|
* const { longitude, latitude } = value.position.coords;
|
|
182
182
|
* const myLocation = new Point({ longitude, latitude });
|
|
@@ -194,8 +194,8 @@ export abstract class ArcgisTrack extends LitElement {
|
|
|
194
194
|
*/
|
|
195
195
|
accessor referenceElement: ArcgisReferenceElement | string | undefined;
|
|
196
196
|
/**
|
|
197
|
-
* Indicates whether
|
|
198
|
-
* the Geolocation
|
|
197
|
+
* Indicates whether automatic rotation to the device heading is disabled. Rotation is based on
|
|
198
|
+
* the Geolocation API's [`GeolocationCoordinates.heading`](https://developer.mozilla.org/docs/Web/API/GeolocationCoordinates/heading)
|
|
199
199
|
* property. The map will not rotate if the speed is `0`,
|
|
200
200
|
* or if the device is unable to provide heading information.
|
|
201
201
|
*
|
|
@@ -195,7 +195,7 @@ export abstract class ArcgisUtilityNetworkAssociations extends LitElement {
|
|
|
195
195
|
*/
|
|
196
196
|
accessor showConnectivityAssociationsSettingsCapSelect: boolean;
|
|
197
197
|
/**
|
|
198
|
-
* If true,
|
|
198
|
+
* If true, shows the max allowable associations slider.
|
|
199
199
|
*
|
|
200
200
|
* @default false
|
|
201
201
|
* @since 5.0
|
|
@@ -169,7 +169,7 @@ export abstract class ArcgisUtilityNetworkTraceAnalysis extends LitElement {
|
|
|
169
169
|
* Set the default aggregated geometry graphics color to red in HTML.
|
|
170
170
|
* ```html
|
|
171
171
|
* <arcgis-map item-id="967a4180aa6c46b68996ea9406e8a606">
|
|
172
|
-
* <arcgis-utility-network-trace-analysis slot="bottom-left" aggregated-geometry-graphics-color="red">
|
|
172
|
+
* <arcgis-utility-network-trace-analysis slot="bottom-left" aggregated-geometry-results-graphics-color="red">
|
|
173
173
|
* </arcgis-utility-network-trace-analysis>
|
|
174
174
|
* </arcgis-map>
|
|
175
175
|
* ```
|
|
@@ -8,24 +8,287 @@ export type UtilityNetworkTraceAnalysisDisplayMode = "add-spatial-feature" | "ad
|
|
|
8
8
|
export type UtilityNetworkTraceResultItemState = "disabled" | "loading" | "ready";
|
|
9
9
|
|
|
10
10
|
/**
|
|
11
|
-
*
|
|
11
|
+
* Describes the properties and lifecycle methods used by the built-in trace result item components.
|
|
12
|
+
*
|
|
13
|
+
* Use this interface as a reference when creating a custom trace result item component to place in the default
|
|
14
|
+
* slot of [arcgis-utility-network-trace-results](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/). It describes the context, configuration, readiness,
|
|
15
|
+
* and cleanup behavior you may want to implement, depending on what your custom result item component displays or does.
|
|
16
|
+
*
|
|
17
|
+
* A custom result item component only needs the optional context and configuration properties it uses.
|
|
18
|
+
*
|
|
19
|
+
* The trace results component does not assign these properties to slotted custom result item components.
|
|
20
|
+
* Set the properties your custom result item component needs, for example by reading the
|
|
21
|
+
* [trace result](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#traceResult) from the parent trace results component.
|
|
22
|
+
* Listen for the parent's [arcgis-utility-network-trace-results.@arcgisPropertyChange](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#event-arcgisPropertyChange)
|
|
23
|
+
* event to handle subsequent changes, ignoring events whose target is not the parent.
|
|
24
|
+
* Remove event listeners when the custom result item component disconnects.
|
|
25
|
+
*
|
|
26
|
+
* ## Coordinate result readiness
|
|
27
|
+
*
|
|
28
|
+
* Set [UtilityNetworkTraceResultItem](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-analysis/types#UtilityNetworkTraceResultItem-emitsArcgisResultReady)
|
|
29
|
+
* to `true` before slotting a custom item if the trace results component should wait for that result item to emit
|
|
30
|
+
* `arcgisResultReady` before displaying trace results. For example, a result item that queries features should
|
|
31
|
+
* set `emitsArcgisResultReady` to `true` and emit `arcgisResultReady` after the feature queries finish and the
|
|
32
|
+
* result item is ready to display its results.
|
|
33
|
+
*
|
|
34
|
+
* The trace results component stays in its [loading state](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#state)
|
|
35
|
+
* until every participating result item (including default result items) has signaled completion by emitting `arcgisResultReady`.
|
|
36
|
+
* The trace results component then emits [arcgis-utility-network-trace-results.@arcgisResultsReady](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#event-arcgisResultsReady).
|
|
37
|
+
*
|
|
38
|
+
* Signal completion even when processing produces no applicable results or fails, after displaying any error.
|
|
39
|
+
* Otherwise, the trace results component keeps waiting.
|
|
40
|
+
*
|
|
41
|
+
* Set `emitsArcgisResultReady` to `false` for an item that does not need to delay readiness,
|
|
42
|
+
* such as static content about the trace results.
|
|
43
|
+
*
|
|
44
|
+
* ## Clear output between trace results
|
|
45
|
+
*
|
|
46
|
+
* Specify a [UtilityNetworkTraceResultItem](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-analysis/types#UtilityNetworkTraceResultItem-clearResult)
|
|
47
|
+
* method to clean up a custom result item component's side effects. The trace results component calls this method
|
|
48
|
+
* when its [trace result](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#traceResult) changes or
|
|
49
|
+
* [arcgis-utility-network-trace-results.clearResults()](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#clearResults) is called.
|
|
50
|
+
* For example, if a custom result item adds graphics to the map, its `clearResult` callback may
|
|
51
|
+
* remove the graphics from the map.
|
|
52
|
+
*
|
|
53
|
+
* Cleanup is independent of readiness: an item with `emitsArcgisResultReady` set to `false` can still provide
|
|
54
|
+
* `clearResult`. Cleanup must be safe to repeat and must not emit `arcgisResultReady` or destroy the item.
|
|
55
|
+
* Keep the item ready to process the next trace result.
|
|
56
|
+
*
|
|
57
|
+
* Adding any content to the trace results component's default slot replaces all default result items,
|
|
58
|
+
* so include each built-in or custom item you want to display.
|
|
12
59
|
*
|
|
13
|
-
* @internal
|
|
14
60
|
* @since 5.2
|
|
61
|
+
* @example
|
|
62
|
+
* After registering a custom element named `my-trace-result-item`, add it alongside a built-in result item.
|
|
63
|
+
* The custom item is responsible for reading its context from the trace results component and processing each trace result.
|
|
64
|
+
* ```html
|
|
65
|
+
* <arcgis-map item-id="471eb0bf37074b1fbb972b1da70fb310">
|
|
66
|
+
* <arcgis-utility-network-trace-analysis slot="bottom-left">
|
|
67
|
+
* <arcgis-utility-network-trace-results slot="results">
|
|
68
|
+
* <arcgis-utility-network-trace-elements-result-item></arcgis-utility-network-trace-elements-result-item>
|
|
69
|
+
* <my-trace-result-item></my-trace-result-item>
|
|
70
|
+
* </arcgis-utility-network-trace-results>
|
|
71
|
+
* </arcgis-utility-network-trace-analysis>
|
|
72
|
+
* </arcgis-map>
|
|
73
|
+
* ```
|
|
74
|
+
* @example
|
|
75
|
+
* This custom element excerpt queries up to 25 point features in the current view extent, adds them to the map,
|
|
76
|
+
* and removes them when `clearResult` is called.
|
|
77
|
+
* ```ts
|
|
78
|
+
* import type FeatureLayer from "@arcgis/core/layers/FeatureLayer.js";
|
|
79
|
+
* import type Graphic from "@arcgis/core/Graphic.js";
|
|
80
|
+
* import type MapView from "@arcgis/core/views/MapView.js";
|
|
81
|
+
*
|
|
82
|
+
* class MyTraceResultItem extends HTMLElement {
|
|
83
|
+
* emitsArcgisResultReady = true;
|
|
84
|
+
* #controller?: AbortController;
|
|
85
|
+
* #view?: MapView;
|
|
86
|
+
* #graphics: Graphic[] = [];
|
|
87
|
+
*
|
|
88
|
+
* async processResult(layer: FeatureLayer, view: MapView): Promise<void> {
|
|
89
|
+
* this.clearResult();
|
|
90
|
+
* const controller = new AbortController();
|
|
91
|
+
* this.#controller = controller;
|
|
92
|
+
*
|
|
93
|
+
* try {
|
|
94
|
+
* const query = layer.createQuery();
|
|
95
|
+
* query.geometry = view.extent;
|
|
96
|
+
* query.num = 25;
|
|
97
|
+
* query.returnGeometry = true;
|
|
98
|
+
* query.outSpatialReference = view.spatialReference;
|
|
99
|
+
* const { features } = await layer.queryFeatures(query, { signal: controller.signal });
|
|
100
|
+
* if (controller.signal.aborted) {
|
|
101
|
+
* return;
|
|
102
|
+
* }
|
|
103
|
+
*
|
|
104
|
+
* this.#view = view;
|
|
105
|
+
* this.#graphics = features;
|
|
106
|
+
* view.graphics.addMany(features);
|
|
107
|
+
* } catch (error) {
|
|
108
|
+
* if (!controller.signal.aborted) {
|
|
109
|
+
* console.error(error);
|
|
110
|
+
* this.textContent = "Could not load trace results.";
|
|
111
|
+
* }
|
|
112
|
+
* } finally {
|
|
113
|
+
* if (this.#controller === controller) {
|
|
114
|
+
* this.#controller = undefined;
|
|
115
|
+
* this.dispatchEvent(new CustomEvent("arcgisResultReady"));
|
|
116
|
+
* }
|
|
117
|
+
* }
|
|
118
|
+
* }
|
|
119
|
+
*
|
|
120
|
+
* clearResult(): void {
|
|
121
|
+
* this.#controller?.abort();
|
|
122
|
+
* this.#controller = undefined;
|
|
123
|
+
* this.#view?.graphics.removeMany(this.#graphics);
|
|
124
|
+
* this.#view = undefined;
|
|
125
|
+
* this.#graphics = [];
|
|
126
|
+
* this.replaceChildren();
|
|
127
|
+
* }
|
|
128
|
+
* }
|
|
129
|
+
* ```
|
|
130
|
+
* `clearResult` aborts an in-flight query; its canceled work does not emit `arcgisResultReady`.
|
|
131
|
+
* The sample's extent query is illustrative; use a query appropriate to the trace result in your component.
|
|
132
|
+
* @see [arcgis-utility-network-trace-results](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/)
|
|
133
|
+
* @see [arcgis-utility-network-trace-aggregated-geometry-result-item](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-aggregated-geometry-result-item/)
|
|
134
|
+
* @see [arcgis-utility-network-trace-elements-result-item](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-elements-result-item/)
|
|
135
|
+
* @see [arcgis-utility-network-trace-functions-result-item](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-functions-result-item/)
|
|
15
136
|
*/
|
|
16
137
|
export interface UtilityNetworkTraceResultItem {
|
|
17
|
-
/**
|
|
138
|
+
/**
|
|
139
|
+
* The [layers and tables](https://developers.arcgis.com/javascript/latest/references/core/layers/Layer/)
|
|
140
|
+
* used to query features associated with the trace result.
|
|
141
|
+
*
|
|
142
|
+
* The [elements result item](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-elements-result-item/#layers)
|
|
143
|
+
* uses this configuration to restrict feature queries to specific utility network layers and tables.
|
|
144
|
+
* An empty array uses the map's layers and tables that belong to the selected utility network.
|
|
145
|
+
*
|
|
146
|
+
* The trace results component forwards its [layers](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#layers)
|
|
147
|
+
* only to its internally created elements result item. Custom result items decide how to use this property.
|
|
148
|
+
*
|
|
149
|
+
* @see [arcgis-utility-network-trace-results.layers](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#layers)
|
|
150
|
+
* @see [arcgis-utility-network-trace-elements-result-item.layers](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-elements-result-item/#layers)
|
|
151
|
+
*/
|
|
18
152
|
layers?: Layer[];
|
|
19
|
-
/**
|
|
153
|
+
/**
|
|
154
|
+
* The heading displayed by the result item.
|
|
155
|
+
*
|
|
156
|
+
* Configure this on the custom result item component, not on the trace results component.
|
|
157
|
+
* The [trace results component heading](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#heading)
|
|
158
|
+
* describes the whole trace rather than an individual item.
|
|
159
|
+
*
|
|
160
|
+
* For example,
|
|
161
|
+
* the [functions result item](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-functions-result-item/#heading)
|
|
162
|
+
* displays this heading above its table and uses a localized default when it is omitted or empty.
|
|
163
|
+
* Custom items control where the heading appears and whether a default is provided.
|
|
164
|
+
*
|
|
165
|
+
* @see [arcgis-utility-network-trace-aggregated-geometry-result-item.heading](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-aggregated-geometry-result-item/#heading)
|
|
166
|
+
* @see [arcgis-utility-network-trace-elements-result-item.heading](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-elements-result-item/#heading)
|
|
167
|
+
* @see [arcgis-utility-network-trace-functions-result-item.heading](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-functions-result-item/#heading)
|
|
168
|
+
*/
|
|
20
169
|
heading?: string;
|
|
21
|
-
/**
|
|
170
|
+
/**
|
|
171
|
+
* The [trace result](https://developers.arcgis.com/javascript/latest/references/core/rest/networks/support/TraceResult/)
|
|
172
|
+
* processed and displayed by the result item.
|
|
173
|
+
*
|
|
174
|
+
* Read this value from the parent [trace results component](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#traceResult).
|
|
175
|
+
* Built-in items process the relevant part of the result: elements, aggregated geometry, or function results.
|
|
176
|
+
* Custom items can process any part they need.
|
|
177
|
+
*
|
|
178
|
+
* To access the full trace response in JSON format, including fields not exposed by the `TraceResult` class, use
|
|
179
|
+
* [`TraceResult.sourceJSON`](https://developers.arcgis.com/javascript/latest/references/core/rest/networks/support/TraceResult/#sourceJSON).
|
|
180
|
+
*
|
|
181
|
+
* Handle an `undefined` value when no result is available, and replace output from the previous result when a
|
|
182
|
+
* new result arrives.
|
|
183
|
+
*
|
|
184
|
+
* If the item participates in
|
|
185
|
+
* [readiness tracking](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-analysis/types#UtilityNetworkTraceResultItem-emitsArcgisResultReady),
|
|
186
|
+
* signal completion even when the result contains no data relevant to the item.
|
|
187
|
+
*
|
|
188
|
+
* @see [arcgis-utility-network-trace-results.traceResult](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#traceResult)
|
|
189
|
+
* @see [TraceResult.sourceJSON](https://developers.arcgis.com/javascript/latest/references/core/rest/networks/support/TraceResult/#sourceJSON)
|
|
190
|
+
*/
|
|
22
191
|
traceResult?: TraceResult;
|
|
23
|
-
/**
|
|
192
|
+
/**
|
|
193
|
+
* The [utility network](https://developers.arcgis.com/javascript/latest/references/core/networks/UtilityNetwork/)
|
|
194
|
+
* associated with the trace result.
|
|
195
|
+
*
|
|
196
|
+
* Read this value from the parent
|
|
197
|
+
* [trace results component](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#utilityNetwork).
|
|
198
|
+
* The [elements result item](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-elements-result-item/#utilityNetwork)
|
|
199
|
+
* uses it to identify utility network layers and resolve trace elements to features.
|
|
200
|
+
*
|
|
201
|
+
* @see [arcgis-utility-network-trace-results.utilityNetwork](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#utilityNetwork)
|
|
202
|
+
* @see [arcgis-utility-network-trace-elements-result-item.utilityNetwork](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-elements-result-item/#utilityNetwork)
|
|
203
|
+
*/
|
|
24
204
|
utilityNetwork?: UtilityNetwork;
|
|
25
|
-
/**
|
|
205
|
+
/**
|
|
206
|
+
* The [map view](https://developers.arcgis.com/javascript/latest/references/core/views/MapView/)
|
|
207
|
+
* used to display and interact with the trace result.
|
|
208
|
+
*
|
|
209
|
+
* Read this value from the parent [trace results component](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#view).
|
|
210
|
+
* The [elements result item](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-elements-result-item/#view)
|
|
211
|
+
* uses it to query layers and highlight features. The
|
|
212
|
+
* [aggregated geometry result item](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-aggregated-geometry-result-item/#view)
|
|
213
|
+
* uses it to display graphics.
|
|
214
|
+
*
|
|
215
|
+
* @see [arcgis-utility-network-trace-results.view](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#view)
|
|
216
|
+
* @see [arcgis-utility-network-trace-elements-result-item.view](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-elements-result-item/#view)
|
|
217
|
+
* @see [arcgis-utility-network-trace-aggregated-geometry-result-item.view](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-aggregated-geometry-result-item/#view)
|
|
218
|
+
*/
|
|
26
219
|
view?: MapView;
|
|
27
|
-
/**
|
|
220
|
+
/**
|
|
221
|
+
* Indicates whether the result item emits an `arcgisResultReady` event after processing a trace result.
|
|
222
|
+
*
|
|
223
|
+
* Set this to `true` before adding the item to the trace results component to participate in readiness tracking.
|
|
224
|
+
* Dispatch `arcgisResultReady` from the custom result item component after processing a trace result. No event detail is required.
|
|
225
|
+
* Once all participating result item components (including default result items) emit `arcgisResultReady`,
|
|
226
|
+
* the trace results component changes its state to `"ready"` and emits
|
|
227
|
+
* [arcgis-utility-network-trace-results.@arcgisResultsReady](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#event-arcgisResultsReady).
|
|
228
|
+
*
|
|
229
|
+
* Signal completion when processing finishes, including when there are no applicable results or processing fails.
|
|
230
|
+
* If this property is `true` and a custom result item never emits `arcgisResultReady`, the trace results component remains
|
|
231
|
+
* in its `"loading"` state and does not emit `arcgisResultsReady`.
|
|
232
|
+
* Do not emit `arcgisResultReady` for work canceled by `clearResult`.
|
|
233
|
+
*
|
|
234
|
+
* Set this to `false` when the trace results component does not need to wait for the custom result item,
|
|
235
|
+
* e.g., displaying static content for the trace result.
|
|
236
|
+
*
|
|
237
|
+
* @example
|
|
238
|
+
* Set the property and dispatch the event after the current result has finished processing:
|
|
239
|
+
* ```ts
|
|
240
|
+
* class MyTraceResultItem extends HTMLElement {
|
|
241
|
+
* emitsArcgisResultReady = true;
|
|
242
|
+
*
|
|
243
|
+
* finishProcessing(): void {
|
|
244
|
+
* this.dispatchEvent(new CustomEvent("arcgisResultReady"));
|
|
245
|
+
* }
|
|
246
|
+
* }
|
|
247
|
+
* ```
|
|
248
|
+
* @see [arcgis-utility-network-trace-results.state](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#state)
|
|
249
|
+
* @see [arcgis-utility-network-trace-results.@arcgisResultsReady](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#event-arcgisResultsReady)
|
|
250
|
+
* @see [UtilityNetworkTraceResultItem](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-analysis/types#UtilityNetworkTraceResultItem-clearResult)
|
|
251
|
+
*/
|
|
28
252
|
emitsArcgisResultReady: boolean;
|
|
29
|
-
/**
|
|
253
|
+
/**
|
|
254
|
+
* Clears the result item's rendered output and side effects, such as graphics added to the map.
|
|
255
|
+
*
|
|
256
|
+
* The trace results component calls this function when its
|
|
257
|
+
* [arcgis-utility-network-trace-results.clearResults()](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#clearResults) method is called or its
|
|
258
|
+
* [trace result](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#traceResult) changes.
|
|
259
|
+
*
|
|
260
|
+
* Cancel pending work, clear the item's stored trace result and rendered output, and undo other side effects here.
|
|
261
|
+
* Ensure canceled work cannot restore stale output or emit `arcgisResultReady`.
|
|
262
|
+
* It must be safe to call this function when the item is already clear.
|
|
263
|
+
*
|
|
264
|
+
* This function is synchronous and must not emit `arcgisResultReady`. It does not destroy the item or remove
|
|
265
|
+
* its context listeners; the item can be reused for subsequent trace results.
|
|
266
|
+
*
|
|
267
|
+
* @example
|
|
268
|
+
* This excerpt shows cleanup for the query example above. Abort the pending query, remove only the graphics
|
|
269
|
+
* created by this component, and clear any displayed error:
|
|
270
|
+
* ```ts
|
|
271
|
+
* import type Graphic from "@arcgis/core/Graphic.js";
|
|
272
|
+
* import type MapView from "@arcgis/core/views/MapView.js";
|
|
273
|
+
*
|
|
274
|
+
* class MyTraceResultItem extends HTMLElement {
|
|
275
|
+
* #controller?: AbortController;
|
|
276
|
+
* #view?: MapView;
|
|
277
|
+
* #graphics: Graphic[] = [];
|
|
278
|
+
*
|
|
279
|
+
* clearResult(): void {
|
|
280
|
+
* this.#controller?.abort();
|
|
281
|
+
* this.#controller = undefined;
|
|
282
|
+
* this.#view?.graphics.removeMany(this.#graphics);
|
|
283
|
+
* this.#view = undefined;
|
|
284
|
+
* this.#graphics = [];
|
|
285
|
+
* this.replaceChildren();
|
|
286
|
+
* }
|
|
287
|
+
* }
|
|
288
|
+
* ```
|
|
289
|
+
* @see [arcgis-utility-network-trace-results.clearResults()](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#clearResults)
|
|
290
|
+
* @see [arcgis-utility-network-trace-results.traceResult](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-results/#traceResult)
|
|
291
|
+
* @see [UtilityNetworkTraceResultItem](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-utility-network-trace-analysis/types#UtilityNetworkTraceResultItem-emitsArcgisResultReady)
|
|
292
|
+
*/
|
|
30
293
|
clearResult: () => void;
|
|
31
294
|
}
|
package/dist/components/arcgis-utility-network-trace-configuration-picker/customElement.d.ts
CHANGED
|
@@ -39,7 +39,7 @@ import type { T9nMeta } from "@arcgis/lumina/controllers";
|
|
|
39
39
|
* ```javascript
|
|
40
40
|
* const picker = document.createElement("arcgis-utility-network-trace-configuration-picker");
|
|
41
41
|
* picker.utilityNetwork = utilityNetwork;
|
|
42
|
-
* picker.traceConfigurations =
|
|
42
|
+
* picker.traceConfigurations = utilityNetwork.sharedNamedTraceConfigurations;
|
|
43
43
|
* document.body.append(picker);
|
|
44
44
|
* ```
|
|
45
45
|
* @since 5.2
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
|
|
2
|
-
import { c as
|
|
2
|
+
import { c as m } from "../../chunks/runtime.js";
|
|
3
3
|
import c from "@arcgis/core/networks/support/UNTraceConfiguration.js";
|
|
4
|
-
import { LitElement as
|
|
4
|
+
import { LitElement as d, createEvent as h } from "@arcgis/lumina";
|
|
5
5
|
import { u as b } from "../../chunks/useT9n.js";
|
|
6
6
|
import { css as g, html as r } from "lit";
|
|
7
7
|
import { log as l } from "@arcgis/toolkit/log";
|
|
8
8
|
import { usePropertyChange as f } from "@arcgis/lumina/controllers";
|
|
9
9
|
import { q as k } from "../../chunks/layer-utils.js";
|
|
10
|
-
const w = g`:host{height:100%;flex-grow:1}.subnetwork-details{border-radius:var(--calcite-border-radius);border:solid 1px var(--calcite-color-border-3)}.key-value-pair{padding:var(--calcite-space-sm)}.key-value-pair__key{font-size:var(--calcite-font-size--2);color:var(--calcite-color-text-3)}.key-value-pair__value{font-size:var(--calcite-font-size--1);color:var(--calcite-color-text-1)}calcite-block{--calcite-block-content-space: 0;--calcite-block-border-color: transparent;margin:0}calcite-block :is(calcite-combobox,calcite-input,calcite-label,calcite-notice){margin:0 var(--calcite-space-md)
|
|
11
|
-
class N extends
|
|
10
|
+
const w = g`:host{height:100%;flex-grow:1}.subnetwork-details{border-radius:var(--calcite-border-radius);border:solid 1px var(--calcite-color-border-3)}.key-value-pair{padding:var(--calcite-space-sm)}.key-value-pair__key{font-size:var(--calcite-font-size--2);color:var(--calcite-color-text-3)}.key-value-pair__value{font-size:var(--calcite-font-size--1);color:var(--calcite-color-text-1)}calcite-block{--calcite-block-content-space: 0;--calcite-block-border-color: transparent;margin:0}calcite-block :is(calcite-combobox,calcite-input,calcite-label,calcite-notice){margin:0 var(--calcite-space-md)}calcite-block>:is(calcite-combobox,calcite-input,calcite-notice):not(:last-child){margin-bottom:var(--calcite-space-md)}calcite-block calcite-input-message{padding:var(--calcite-space-sm) var(--calcite-space-md) 0}calcite-notice{margin:var(--calcite-space-md)}#subnetwork-info-block{margin:var(--calcite-space-md) var(--calcite-space-md) 0}.inline-loader{--calcite-loader-spacing: var(--calcite-space-md)}`, p = 20, C = /* @__PURE__ */ new Set(["subnetwork", "subnetwork-controller", "upstream", "downstream", "isolation"]);
|
|
11
|
+
class N extends d {
|
|
12
12
|
constructor() {
|
|
13
13
|
super(...arguments), this._messages = b({ blocking: !0 }), this._subnetworkNamesState = "ready", this._compatibleSubnetworkNames = [], this.traceConfigurations = [], this.hideSubnetworkInfo = !1, this.hideErrors = !1, this.state = "ready", this.arcgisPropertyChange = f()("selectedNamedTraceConfiguration", "traceConfiguration"), this.arcgisError = h();
|
|
14
14
|
}
|
|
@@ -29,12 +29,12 @@ class N extends m {
|
|
|
29
29
|
return !!e?.traceConfiguration?.subnetworkName && e?.traceType === "subnetwork";
|
|
30
30
|
}
|
|
31
31
|
willUpdate(e) {
|
|
32
|
-
e.has("traceConfigurations") && this.#m(), e.has("selectedNamedTraceConfiguration") && this.#o(), e.has("utilityNetwork") && this.#
|
|
32
|
+
e.has("traceConfigurations") && this.#m(), e.has("selectedNamedTraceConfiguration") && this.#o(), e.has("utilityNetwork") && this.#u();
|
|
33
33
|
}
|
|
34
34
|
async #o() {
|
|
35
|
-
const { selectedNamedTraceConfiguration: e
|
|
36
|
-
if (!(e
|
|
37
|
-
this.#t(
|
|
35
|
+
const { selectedNamedTraceConfiguration: e } = this;
|
|
36
|
+
if (!e || !(e.traceConfiguration instanceof c)) {
|
|
37
|
+
this.#t(e ? this._messages.errors.noTraceConfiguration : this._messages.errors.traceConfigurationNotFound), this.traceConfiguration = void 0, this.arcgisPropertyChange.emit({ name: "traceConfiguration" });
|
|
38
38
|
return;
|
|
39
39
|
}
|
|
40
40
|
this.#i(), this.traceConfiguration = e.traceConfiguration.clone(), this.arcgisPropertyChange.emit({ name: "selectedNamedTraceConfiguration" }), this.arcgisPropertyChange.emit({ name: "traceConfiguration" }), this.isSubnetworkNameTraceSelected && (this._subnetworkNamesState = "loading", this.state = "loading", await this.#s(this.traceConfiguration), this._subnetworkNamesState = "ready", this.state = "ready");
|
|
@@ -58,19 +58,11 @@ class N extends m {
|
|
|
58
58
|
const e = this.traceConfiguration, t = `DOMAINNETWORKNAME = '${e.domainNetworkName}'`, i = `TIERNAME = '${e.tierName}'`;
|
|
59
59
|
return [t, i].join(" AND ");
|
|
60
60
|
}
|
|
61
|
-
#u(
|
|
62
|
-
const t = this.traceConfigurations.find((i) => i.globalId === e);
|
|
63
|
-
if (!t) {
|
|
64
|
-
this.#t(this._messages.errors.traceConfigurationNotFound), this.traceConfiguration = void 0, this.selectedNamedTraceConfiguration = void 0;
|
|
65
|
-
return;
|
|
66
|
-
}
|
|
67
|
-
this.#i(), this.selectedNamedTraceConfiguration = t;
|
|
68
|
-
}
|
|
69
|
-
#d() {
|
|
61
|
+
#u() {
|
|
70
62
|
this.#e = void 0, this._subnetworksTable = void 0, this._compatibleSubnetworkNames = [];
|
|
71
63
|
}
|
|
72
64
|
#m() {
|
|
73
|
-
this.traceConfiguration = void 0, this.selectedNamedTraceConfiguration = void 0, this.traceConfigurations.length ? (this.#i(), this.selectedNamedTraceConfiguration = this.traceConfigurations.find((e) => e.traceConfiguration instanceof c)
|
|
65
|
+
this.traceConfiguration = void 0, this.selectedNamedTraceConfiguration = void 0, this.traceConfigurations.length ? (this.#i(), this.selectedNamedTraceConfiguration = this.traceConfigurations.find((e) => e.traceConfiguration instanceof c) ?? this.traceConfigurations.at(0)) : this.#t(this._messages.errors.noTraceConfigurations);
|
|
74
66
|
}
|
|
75
67
|
#t(e) {
|
|
76
68
|
l("error", this, e), this.error = e, this.state = "error", this.arcgisError.emit();
|
|
@@ -84,25 +76,25 @@ class N extends m {
|
|
|
84
76
|
#r(e, t = !1, i = "exclamation-mark-triangle") {
|
|
85
77
|
return this.hideErrors ? null : r`<calcite-notice .closable=${t} kind=danger open scale=s width=auto .icon=${i}><div slot=message>${e}</div></calcite-notice>`;
|
|
86
78
|
}
|
|
87
|
-
#
|
|
88
|
-
const
|
|
89
|
-
return r`<calcite-label>${e
|
|
79
|
+
#d() {
|
|
80
|
+
const e = this.selectedNamedTraceConfiguration?.title;
|
|
81
|
+
return e ? r`<calcite-label>${e}</calcite-label>` : null;
|
|
90
82
|
}
|
|
91
|
-
#
|
|
83
|
+
#h() {
|
|
92
84
|
const e = this.traceConfigurations.map((i) => r`<calcite-combobox-item .value=${i.globalId} .heading=${i.title} .selected=${i.globalId === this.selectedNamedTraceConfiguration?.globalId}></calcite-combobox-item>`), t = this._messages.labels.traceConfiguration;
|
|
93
85
|
return r`<calcite-combobox .label=${t} selection-mode=single-persist @calciteComboboxChange=${({ currentTarget: i }) => {
|
|
94
86
|
const a = i.selectedItems[0]?.value;
|
|
95
|
-
this
|
|
87
|
+
this.selectedNamedTraceConfiguration = this.traceConfigurations.find((o) => o.globalId === a);
|
|
96
88
|
}}>${e}</calcite-combobox>`;
|
|
97
89
|
}
|
|
98
|
-
#
|
|
90
|
+
#b() {
|
|
99
91
|
const { _messages: e } = this;
|
|
100
92
|
if (this.error === e.errors.noTraceConfigurations)
|
|
101
93
|
return this.#r(e.errors.noTraceConfigurations);
|
|
102
|
-
const t = this.error ? this.#r(this.error) : null, i = this.traceConfigurations.length > 1 ? this.#
|
|
94
|
+
const t = this.error ? this.#r(this.error) : null, i = this.traceConfigurations.length > 1 ? this.#h() : this.#d(), a = this._messages.labels.traceConfiguration, o = this.heading ?? a;
|
|
103
95
|
return r`<calcite-block .heading=${o} .label=${a} expanded>${i}${t}</calcite-block>`;
|
|
104
96
|
}
|
|
105
|
-
#
|
|
97
|
+
#g() {
|
|
106
98
|
if (this.hideSubnetworkInfo)
|
|
107
99
|
return null;
|
|
108
100
|
const { _messages: e, selectedNamedTraceConfiguration: t } = this;
|
|
@@ -112,26 +104,26 @@ class N extends m {
|
|
|
112
104
|
const { domainNetworkName: i, tierName: a, targetTierName: o } = t.traceConfiguration;
|
|
113
105
|
return !i && !a && !o ? (l("warn", this, "`namedTraceConfig.traceConfiguration` has no `domainNetworkName`, `tierName`, or `targetTierName`."), null) : r`<calcite-block id=subnetwork-info-block expanded .label=${this._messages.labels.subnetworkInfo}><div class="subnetwork-details">${i ? this.#a(e.headings.domainNetwork, i) : null}${a ? this.#a(e.headings.tier, a) : null}${o ? this.#a(e.headings.targetTier, o) : null}</div></calcite-block>`;
|
|
114
106
|
}
|
|
115
|
-
#
|
|
107
|
+
#f() {
|
|
116
108
|
const { _messages: e } = this, t = e.labels.subnetworkName;
|
|
117
|
-
return this.isSubnetworkNameTraceSelected ? this._subnetworkNamesState === "loading" ? r`<calcite-loader class="inline-loader" label=loading scale=s></calcite-loader>` : this._compatibleSubnetworkNames.length ? r`<calcite-block .heading=${t} .label=${t} expanded>${this._compatibleSubnetworkNames.length >
|
|
109
|
+
return this.isSubnetworkNameTraceSelected ? this._subnetworkNamesState === "loading" ? r`<calcite-loader class="inline-loader" label=loading scale=s></calcite-loader>` : this._compatibleSubnetworkNames.length ? r`<calcite-block .heading=${t} .label=${t} expanded>${this._compatibleSubnetworkNames.length > p ? this.#k() : this.#w()}</calcite-block>` : this.#r(e.errors.noCompatibleSubnetworks) : null;
|
|
118
110
|
}
|
|
119
|
-
#
|
|
111
|
+
#k() {
|
|
120
112
|
const { _messages: e } = this;
|
|
121
113
|
return r`<calcite-input clearable type=text .placeholder=${e.instructions.enterSubnetworkName} max-length=64 .status=${this.#e ? "valid" : "invalid"} .value=${this.#e} @calciteInputInput=${(t) => this.#e = t.target.value}></calcite-input><calcite-input-message icon=exclamation-mark-triangle status=idle>${e.labels.tooManySubnetworks}</calcite-input-message>`;
|
|
122
114
|
}
|
|
123
|
-
#
|
|
115
|
+
#w() {
|
|
124
116
|
return r`<calcite-combobox .label=${this._messages.labels.subnetworkName} selection-mode=single-persist @calciteComboboxChange=${({ currentTarget: e }) => {
|
|
125
117
|
const t = e.selectedItems[0]?.value;
|
|
126
118
|
this.#e = t;
|
|
127
119
|
}}>${this._compatibleSubnetworkNames.map((e) => r`<calcite-combobox-item .value=${e} .heading=${e} .selected=${e === this.#e}></calcite-combobox-item>`)}</calcite-combobox>`;
|
|
128
120
|
}
|
|
129
121
|
render() {
|
|
130
|
-
const { selectedNamedTraceConfiguration: e } = this, i = e?.traceType &&
|
|
131
|
-
return r`${this.#
|
|
122
|
+
const { selectedNamedTraceConfiguration: e } = this, i = e?.traceType && C.has(e.traceType) ? r`${this.#g()}${this.#f()}` : null;
|
|
123
|
+
return r`${this.#b()}${i}`;
|
|
132
124
|
}
|
|
133
125
|
}
|
|
134
|
-
|
|
126
|
+
m("arcgis-utility-network-trace-configuration-picker", N);
|
|
135
127
|
export {
|
|
136
128
|
N as ArcgisUtilityNetworkTraceConfigurationPicker
|
|
137
129
|
};
|
|
@@ -276,7 +276,7 @@ export abstract class ArcgisUtilityNetworkTraceLocations extends LitElement {
|
|
|
276
276
|
* Adding or removing locations through the component's UI updates this collection and the map markers.
|
|
277
277
|
*
|
|
278
278
|
* When a user selects terminals, these choices are stored in `flagProperties.selectedTerminals`; they do not
|
|
279
|
-
*
|
|
279
|
+
* create a separate `traceLocation` for each selected terminal. When constructing trace inputs, account for
|
|
280
280
|
* the selected terminals rather than using only each entry's `traceLocation.terminalId`.
|
|
281
281
|
*
|
|
282
282
|
* @since 5.2
|
|
@@ -37,7 +37,7 @@ import type { Icon } from "@esri/calcite-components/components/calcite-icon";
|
|
|
37
37
|
* 
|
|
38
38
|
*
|
|
39
39
|
* ```html
|
|
40
|
-
* <arcgis-map
|
|
40
|
+
* <arcgis-map item-id="462c629e8e604c15baf45627c4f337d6">
|
|
41
41
|
* <arcgis-value-picker-legacy slot="top-right"></arcgis-value-picker-legacy>
|
|
42
42
|
* </arcgis-map>
|
|
43
43
|
* ```
|
|
@@ -52,7 +52,7 @@ import type { Icon } from "@esri/calcite-components/components/calcite-icon";
|
|
|
52
52
|
* valuePicker.addEventListener("arcgisNext", () => { console.log("user clicks next"); });
|
|
53
53
|
* ```
|
|
54
54
|
*
|
|
55
|
-
* <span id="
|
|
55
|
+
* <span id="from-labels"></span>
|
|
56
56
|
* #### 2. Using the label component to present items
|
|
57
57
|
*
|
|
58
58
|
* Consider using the [label component](https://developers.arcgis.com/javascript/latest/references/core/widgets/ValuePicker/ValuePickerLabel/) to step through a fixed list of predefined values like land use zones.
|
|
@@ -206,7 +206,7 @@ import type { Icon } from "@esri/calcite-components/components/calcite-icon";
|
|
|
206
206
|
* ```js
|
|
207
207
|
* valuePicker.addEventListener("arcgisPropertyChange", () => {
|
|
208
208
|
* console.log("The current opacity is: ", valuePicker.values[0]);
|
|
209
|
-
* layer.opacity = valuePicker.values[0] /
|
|
209
|
+
* layer.opacity = valuePicker.values[0] / 10;
|
|
210
210
|
* });
|
|
211
211
|
* ```
|
|
212
212
|
*
|
|
@@ -229,7 +229,7 @@ import type { Icon } from "@esri/calcite-components/components/calcite-icon";
|
|
|
229
229
|
* collection: basemapCollection,
|
|
230
230
|
* });
|
|
231
231
|
*
|
|
232
|
-
*
|
|
232
|
+
* valuePicker.values = ["topo-vector"];
|
|
233
233
|
* ```
|
|
234
234
|
*
|
|
235
235
|
* @deprecated since 5.1. Use the [Value Picker component](https://developers.arcgis.com/javascript/latest/references/common-components/components/arcgis-value-picker/) instead.
|
|
@@ -307,7 +307,7 @@ export abstract class ArcgisValuePickerLegacy extends LitElement {
|
|
|
307
307
|
*/
|
|
308
308
|
get canPlay(): boolean;
|
|
309
309
|
/**
|
|
310
|
-
* Returns `true` if the Value Picker can
|
|
310
|
+
* Returns `true` if the Value Picker can move to the previous item.
|
|
311
311
|
*
|
|
312
312
|
* @default false
|
|
313
313
|
* @example
|
|
@@ -380,21 +380,21 @@ export abstract class ArcgisValuePickerLegacy extends LitElement {
|
|
|
380
380
|
*/
|
|
381
381
|
accessor component: ValuePickerComponent | null | undefined;
|
|
382
382
|
/**
|
|
383
|
-
* When set to `
|
|
383
|
+
* When set to `true`, the next button (or up button when vertical) is not displayed.
|
|
384
384
|
*
|
|
385
385
|
* @default false
|
|
386
386
|
* @since 5.0
|
|
387
387
|
*/
|
|
388
388
|
accessor hideNextButton: boolean;
|
|
389
389
|
/**
|
|
390
|
-
* When set to `
|
|
390
|
+
* When set to `true`, the play/pause button is not displayed.
|
|
391
391
|
*
|
|
392
392
|
* @default false
|
|
393
393
|
* @since 5.0
|
|
394
394
|
*/
|
|
395
395
|
accessor hidePlayButton: boolean;
|
|
396
396
|
/**
|
|
397
|
-
* When set to `
|
|
397
|
+
* When set to `true`, the previous button (or down button when vertical) is not displayed.
|
|
398
398
|
*
|
|
399
399
|
* @default false
|
|
400
400
|
* @since 5.0
|
|
@@ -513,11 +513,9 @@ export abstract class ArcgisValuePickerLegacy extends LitElement {
|
|
|
513
513
|
*
|
|
514
514
|
* valuePickerBasemap.values = ["topo-vector"];
|
|
515
515
|
*
|
|
516
|
-
*
|
|
517
|
-
* if (
|
|
518
|
-
*
|
|
519
|
-
* functionName: valuePickerLandCover.values[0],
|
|
520
|
-
* };
|
|
516
|
+
* valuePickerBasemap.addEventListener("arcgisPropertyChange", () => {
|
|
517
|
+
* if (valuePickerBasemap.values?.[0]) {
|
|
518
|
+
* mapElement.basemap = valuePickerBasemap.values[0];
|
|
521
519
|
* }
|
|
522
520
|
* });
|
|
523
521
|
* ```
|
|
@@ -543,7 +541,7 @@ export abstract class ArcgisValuePickerLegacy extends LitElement {
|
|
|
543
541
|
* valuePicker.values = [0];
|
|
544
542
|
* console.log("Current value:", valuePicker.values[0]); // "Current value: 0"
|
|
545
543
|
*
|
|
546
|
-
* valuePicker.next();
|
|
544
|
+
* await valuePicker.next();
|
|
547
545
|
* console.log("Current value:", valuePicker.values[0]); // "Current value: 1"
|
|
548
546
|
* ```
|
|
549
547
|
*/
|
|
@@ -595,7 +593,7 @@ export abstract class ArcgisValuePickerLegacy extends LitElement {
|
|
|
595
593
|
* valuePicker.values = [3];
|
|
596
594
|
* console.log("Current value:", valuePicker.values[0]); // "Current value: 3"
|
|
597
595
|
*
|
|
598
|
-
* valuePicker.previous();
|
|
596
|
+
* await valuePicker.previous();
|
|
599
597
|
* console.log("Current value:", valuePicker.values[0]); // "Current value: 2"
|
|
600
598
|
* ```
|
|
601
599
|
*/
|
|
@@ -622,7 +620,7 @@ export abstract class ArcgisValuePickerLegacy extends LitElement {
|
|
|
622
620
|
* // Update ImageryLayer's raster function accordingly.
|
|
623
621
|
* valuePicker.addEventListener("arcgisPropertyChange", (event) =>{
|
|
624
622
|
* layer.rasterFunction = {
|
|
625
|
-
* functionName:
|
|
623
|
+
* functionName: valuePicker.values[0],
|
|
626
624
|
* };
|
|
627
625
|
* });
|
|
628
626
|
* ```
|
|
@@ -126,7 +126,7 @@ export abstract class ArcgisVideo extends LitElement {
|
|
|
126
126
|
* @see [when()](https://developers.arcgis.com/javascript/latest/references/core/views/VideoView/#when)
|
|
127
127
|
*/
|
|
128
128
|
get ready(): boolean;
|
|
129
|
-
/** The [VideoView](https://developers.arcgis.com/javascript/latest/references/core/views/VideoView/) instance created and
|
|
129
|
+
/** The [VideoView](https://developers.arcgis.com/javascript/latest/references/core/views/VideoView/) instance created and managed by the component. Accessible once the component is fully loaded. */
|
|
130
130
|
get view(): VideoView;
|
|
131
131
|
/** Destroys the view, and any associated resources, including its map, popup, and UI elements. */
|
|
132
132
|
destroy(): Promise<void>;
|