@esri/solutions-components 0.7.24 → 0.7.25

Sign up to get free protection for your applications and to get access to all the features.
Files changed (85) hide show
  1. package/dist/cjs/{info-card_4.cjs.entry.js → basemap-gallery_7.cjs.entry.js} +410 -324
  2. package/dist/cjs/buffer-tools_3.cjs.entry.js +3 -4
  3. package/dist/cjs/{calcite-alert_3.cjs.entry.js → calcite-alert_4.cjs.entry.js} +296 -3
  4. package/dist/cjs/calcite-combobox_6.cjs.entry.js +1 -2
  5. package/dist/cjs/calcite-flow_4.cjs.entry.js +3 -4
  6. package/dist/cjs/calcite-shell-panel_14.cjs.entry.js +1 -2
  7. package/dist/cjs/{card-manager_2.cjs.entry.js → card-manager_3.cjs.entry.js} +182 -5
  8. package/dist/cjs/crowdsource-manager.cjs.entry.js +1 -2
  9. package/dist/cjs/crowdsource-reporter.cjs.entry.js +32 -90
  10. package/dist/cjs/{downloadUtils-401356b5.js → downloadUtils-83c6d3c3.js} +6 -6
  11. package/dist/cjs/{index.es-a9a4ff08.js → index.es-bd1a93b2.js} +2 -2
  12. package/dist/cjs/layout-manager.cjs.entry.js +1 -2
  13. package/dist/cjs/loader.cjs.js +1 -1
  14. package/dist/cjs/{locale-1ff119f5.js → locale-a476e15d.js} +24 -3
  15. package/dist/cjs/map-select-tools_3.cjs.entry.js +4 -5
  16. package/dist/cjs/{popupUtils-8d5b6e94.js → popupUtils-a73902a6.js} +2 -2
  17. package/dist/cjs/public-notification.cjs.entry.js +3 -4
  18. package/dist/cjs/solution-configuration.cjs.entry.js +1 -2
  19. package/dist/cjs/solution-contents_3.cjs.entry.js +1 -2
  20. package/dist/cjs/solutions-components.cjs.js +1 -1
  21. package/dist/cjs/spatial-ref.cjs.entry.js +1 -2
  22. package/dist/collection/components/crowdsource-reporter/crowdsource-reporter.css +5 -27
  23. package/dist/collection/components/crowdsource-reporter/crowdsource-reporter.js +69 -95
  24. package/dist/collection/demos/crowdsource-reporter.html +96 -45
  25. package/dist/components/crowdsource-reporter.js +95 -209
  26. package/dist/esm/{info-card_4.entry.js → basemap-gallery_7.entry.js} +406 -323
  27. package/dist/esm/buffer-tools_3.entry.js +1 -2
  28. package/dist/esm/{calcite-alert_3.entry.js → calcite-alert_4.entry.js} +295 -3
  29. package/dist/esm/calcite-combobox_6.entry.js +1 -2
  30. package/dist/esm/calcite-flow_4.entry.js +3 -4
  31. package/dist/esm/calcite-shell-panel_14.entry.js +1 -2
  32. package/dist/esm/{card-manager_2.entry.js → card-manager_3.entry.js} +181 -5
  33. package/dist/esm/crowdsource-manager.entry.js +1 -2
  34. package/dist/esm/crowdsource-reporter.entry.js +32 -90
  35. package/dist/esm/{downloadUtils-067dc2ff.js → downloadUtils-a301c193.js} +2 -2
  36. package/dist/esm/{index.es-92e46d8b.js → index.es-37a9907e.js} +2 -2
  37. package/dist/esm/layout-manager.entry.js +1 -2
  38. package/dist/esm/loader.js +1 -1
  39. package/dist/esm/{locale-13e3c96c.js → locale-731e75a8.js} +22 -2
  40. package/dist/esm/map-select-tools_3.entry.js +2 -3
  41. package/dist/esm/{popupUtils-b71f30fc.js → popupUtils-a593bd78.js} +1 -1
  42. package/dist/esm/public-notification.entry.js +2 -3
  43. package/dist/esm/solution-configuration.entry.js +1 -2
  44. package/dist/esm/solution-contents_3.entry.js +1 -2
  45. package/dist/esm/solutions-components.js +1 -1
  46. package/dist/esm/spatial-ref.entry.js +1 -2
  47. package/dist/solutions-components/demos/crowdsource-reporter.html +96 -45
  48. package/dist/solutions-components/{p-36cbf14f.js → p-0587972d.js} +1 -1
  49. package/dist/solutions-components/p-0b4f4b0e.entry.js +6 -0
  50. package/dist/solutions-components/{p-f54f3719.entry.js → p-0b619197.entry.js} +1 -1
  51. package/dist/solutions-components/{p-d50f34c4.entry.js → p-2656c6e4.entry.js} +1 -1
  52. package/dist/solutions-components/p-284cc5cd.entry.js +6 -0
  53. package/dist/solutions-components/{p-01032eec.entry.js → p-29f661f5.entry.js} +2 -2
  54. package/dist/solutions-components/p-5af99fd8.entry.js +6 -0
  55. package/dist/solutions-components/{p-d9061e5d.entry.js → p-7116f96d.entry.js} +1 -1
  56. package/dist/solutions-components/p-7c13406e.entry.js +6 -0
  57. package/dist/solutions-components/{p-685257d1.entry.js → p-7dbccc10.entry.js} +1 -1
  58. package/dist/solutions-components/p-8308f64c.entry.js +6 -0
  59. package/dist/solutions-components/{p-ca4023f4.entry.js → p-891682da.entry.js} +1 -1
  60. package/dist/solutions-components/{p-14ff1465.js → p-a603e673.js} +2 -2
  61. package/dist/solutions-components/p-b37ec1f3.entry.js +6 -0
  62. package/dist/solutions-components/{p-fec77450.js → p-db868283.js} +1 -1
  63. package/dist/solutions-components/{p-fb1c6811.entry.js → p-dded59a7.entry.js} +1 -1
  64. package/dist/solutions-components/p-e88a64be.entry.js +6 -0
  65. package/dist/solutions-components/p-e902ba19.js +36 -0
  66. package/dist/solutions-components/p-fe295e9d.entry.js +6 -0
  67. package/dist/solutions-components/solutions-components.esm.js +1 -1
  68. package/dist/types/components/crowdsource-reporter/crowdsource-reporter.d.ts +14 -28
  69. package/dist/types/components.d.ts +16 -0
  70. package/package.json +1 -1
  71. package/dist/cjs/basemap-gallery_5.cjs.entry.js +0 -573
  72. package/dist/cjs/loadModules-46d14e81.js +0 -30
  73. package/dist/esm/basemap-gallery_5.entry.js +0 -565
  74. package/dist/esm/loadModules-cea493da.js +0 -28
  75. package/dist/solutions-components/p-3606c4b8.entry.js +0 -6
  76. package/dist/solutions-components/p-48ff9cea.js +0 -21
  77. package/dist/solutions-components/p-5e832d65.entry.js +0 -6
  78. package/dist/solutions-components/p-8fc072ca.entry.js +0 -6
  79. package/dist/solutions-components/p-a2d3df14.entry.js +0 -6
  80. package/dist/solutions-components/p-ab006ace.js +0 -21
  81. package/dist/solutions-components/p-ba56035f.entry.js +0 -6
  82. package/dist/solutions-components/p-c0ed2b83.entry.js +0 -6
  83. package/dist/solutions-components/p-cc88bb42.entry.js +0 -6
  84. package/dist/solutions-components/p-db69f4ba.entry.js +0 -6
  85. package/dist/solutions-components/p-e3061220.entry.js +0 -6
@@ -1,565 +0,0 @@
1
- /*!
2
- * Copyright 2022 Esri
3
- * Licensed under the Apache License, Version 2.0
4
- * http://www.apache.org/licenses/LICENSE-2.0
5
- */
6
- import { r as registerInstance, h, H as Host, g as getElement, c as createEvent } from './index-7183ce4a.js';
7
- import { l as loadModules } from './loadModules-cea493da.js';
8
- import './esri-loader-eda07632.js';
9
- import './_commonjsHelpers-d5f9d613.js';
10
-
11
- const basemapGalleryCss = ":host{display:block}";
12
-
13
- const BasemapGallery = class {
14
- constructor(hostRef) {
15
- registerInstance(this, hostRef);
16
- this.mapView = undefined;
17
- this.basemapConfig = undefined;
18
- this.basemapWidget = undefined;
19
- }
20
- //--------------------------------------------------------------------------
21
- //
22
- // Watch handlers
23
- //
24
- //--------------------------------------------------------------------------
25
- async mapViewWatchHandler() {
26
- await this.mapView.when(() => {
27
- void this._initBaseMapGallery(this.mapView);
28
- });
29
- }
30
- //--------------------------------------------------------------------------
31
- //
32
- // Methods (public)
33
- //
34
- //--------------------------------------------------------------------------
35
- //--------------------------------------------------------------------------
36
- //
37
- // Events (public)
38
- //
39
- //--------------------------------------------------------------------------
40
- //--------------------------------------------------------------------------
41
- //
42
- // Functions (lifecycle)
43
- //
44
- //--------------------------------------------------------------------------
45
- /**
46
- * StencilJS: Called once just after the component is first connected to the DOM.
47
- */
48
- async componentWillLoad() {
49
- return this._initModules();
50
- }
51
- /**
52
- * StencilJS: Renders the component.
53
- */
54
- render() {
55
- return (h(Host, null, h("div", { ref: (el) => { this._basemapElement = el; } })));
56
- }
57
- /**
58
- * StencilJS: Called once just after the component is fully loaded and the first render() occurs.
59
- */
60
- async componentDidLoad() {
61
- if (this.mapView) {
62
- await this.mapViewWatchHandler();
63
- }
64
- }
65
- //--------------------------------------------------------------------------
66
- //
67
- // Functions (protected)
68
- //
69
- //--------------------------------------------------------------------------
70
- /**
71
- * Load esri javascript api modules
72
- *
73
- * @returns Promise resolving when function is done
74
- *
75
- * @protected
76
- */
77
- async _initModules() {
78
- const [BasemapGallery, PortalBasemapsSource] = await loadModules([
79
- "esri/widgets/BasemapGallery",
80
- "esri/widgets/BasemapGallery/support/PortalBasemapsSource"
81
- ]);
82
- this.BasemapGallery = BasemapGallery;
83
- this.PortalBasemapsSource = PortalBasemapsSource;
84
- }
85
- /**
86
- * Initialize the basemap gallery or reset the current view if it already exists
87
- *
88
- * @protected
89
- */
90
- async _initBaseMapGallery(view) {
91
- var _a;
92
- if (this.BasemapGallery) {
93
- if (this.basemapWidget) {
94
- this.basemapWidget.destroy();
95
- }
96
- const source = new this.PortalBasemapsSource({
97
- query: ((_a = this.basemapConfig) === null || _a === void 0 ? void 0 : _a.basemapGroupId) ? `id:${this.basemapConfig.basemapGroupId}` : null,
98
- filterFunction: this.basemapConfig ? (basemap) => {
99
- return !this.basemapConfig.basemapIdsToFilter.includes(basemap.portalItem.id);
100
- } : () => true
101
- });
102
- await source.refresh();
103
- this.basemapWidget = new this.BasemapGallery({
104
- container: this._basemapElement,
105
- view,
106
- source
107
- });
108
- }
109
- }
110
- get el() { return getElement(this); }
111
- static get watchers() { return {
112
- "mapView": ["mapViewWatchHandler"]
113
- }; }
114
- };
115
- BasemapGallery.style = basemapGalleryCss;
116
-
117
- const floorFilterCss = ":host{display:block}";
118
-
119
- const FloorFilter = class {
120
- constructor(hostRef) {
121
- registerInstance(this, hostRef);
122
- this.levelChanged = createEvent(this, "levelChanged", 7);
123
- this.enabled = undefined;
124
- this.floorFilterWidget = undefined;
125
- this.mapView = undefined;
126
- }
127
- //--------------------------------------------------------------------------
128
- //
129
- // Watch handlers
130
- //
131
- //--------------------------------------------------------------------------
132
- async mapViewWatchHandler() {
133
- await this.mapView.when(() => {
134
- this._initFloorFilter(this.mapView);
135
- });
136
- }
137
- //--------------------------------------------------------------------------
138
- //
139
- // Functions (lifecycle)
140
- //
141
- //--------------------------------------------------------------------------
142
- /**
143
- * StencilJS: Called once just after the component is first connected to the DOM.
144
- */
145
- async componentWillLoad() {
146
- return this._initModules();
147
- }
148
- render() {
149
- return (h(Host, null, h("div", { ref: (el) => { this._floorFilterElement = el; } })));
150
- }
151
- //--------------------------------------------------------------------------
152
- //
153
- // Functions (protected)
154
- //
155
- //--------------------------------------------------------------------------
156
- /**
157
- * Load esri javascript api modules
158
- *
159
- * @returns Promise resolving when function is done
160
- *
161
- * @protected
162
- */
163
- async _initModules() {
164
- const [FloorFilter, reactiveUtils] = await loadModules([
165
- "esri/widgets/FloorFilter",
166
- "esri/core/reactiveUtils"
167
- ]);
168
- this.FloorFilter = FloorFilter;
169
- this.reactiveUtils = reactiveUtils;
170
- }
171
- /**
172
- * Initialize the floor filter or reset the current view if it already exists
173
- */
174
- _initFloorFilter(view) {
175
- var _a;
176
- if (view && this.enabled && this.FloorFilter && ((_a = view === null || view === void 0 ? void 0 : view.map) === null || _a === void 0 ? void 0 : _a.floorInfo)) {
177
- if (!this.floorFilterWidget) {
178
- this.floorFilterWidget = new this.FloorFilter({
179
- container: this._floorFilterElement,
180
- view
181
- });
182
- if (this._levelHandle) {
183
- this._levelHandle.remove();
184
- }
185
- this._levelHandle = this.reactiveUtils.watch(() => this.floorFilterWidget.level, (level) => {
186
- this.levelChanged.emit(level);
187
- });
188
- }
189
- else {
190
- this.floorFilterWidget.view = view;
191
- }
192
- }
193
- }
194
- get el() { return getElement(this); }
195
- static get watchers() { return {
196
- "mapView": ["mapViewWatchHandler"]
197
- }; }
198
- };
199
- FloorFilter.style = floorFilterCss;
200
-
201
- const mapFullscreenCss = ":host{display:block}";
202
-
203
- const MapFullscreen = class {
204
- constructor(hostRef) {
205
- registerInstance(this, hostRef);
206
- this.fullscreenStateChange = createEvent(this, "fullscreenStateChange", 7);
207
- this.mapView = undefined;
208
- this.fullscreenWidget = undefined;
209
- }
210
- //--------------------------------------------------------------------------
211
- //
212
- // Watch handlers
213
- //
214
- //--------------------------------------------------------------------------
215
- /**
216
- * Called each time the mapView prop is changed.
217
- *
218
- * @returns Promise when complete
219
- */
220
- async mapViewWatchHandler() {
221
- await this.mapView.when(async () => {
222
- await this._initFullscreenWidget();
223
- });
224
- }
225
- //--------------------------------------------------------------------------
226
- //
227
- // Functions (lifecycle)
228
- //
229
- //--------------------------------------------------------------------------
230
- /**
231
- * StencilJS: Called once just after the component is first connected to the DOM.
232
- */
233
- async componentWillLoad() {
234
- await this._initModules();
235
- }
236
- /**
237
- * Renders the component.
238
- */
239
- render() {
240
- return (h(Host, null, h("div", { class: "fullscreen-widget", ref: (el) => { this._fullscreenElement = el; } })));
241
- }
242
- /**
243
- * StencilJS: Called just after the component updates.
244
- * It's never called during the first render().
245
- */
246
- async componentDidUpdate() {
247
- await this._initFullscreenWidget();
248
- }
249
- /**
250
- * StencilJS: Called once just after the component is fully loaded and the first render() occurs.
251
- */
252
- async componentDidLoad() {
253
- await this._initFullscreenWidget();
254
- }
255
- //--------------------------------------------------------------------------
256
- //
257
- // Functions (protected)
258
- //
259
- //--------------------------------------------------------------------------
260
- /**
261
- * Load esri javascript api modules
262
- *
263
- * @returns Promise resolving when function is done
264
- *
265
- * @protected
266
- */
267
- async _initModules() {
268
- const [Fullscreen, reactiveUtils] = await loadModules([
269
- "esri/widgets/Fullscreen",
270
- "esri/core/reactiveUtils"
271
- ]);
272
- this.Fullscreen = Fullscreen;
273
- this.reactiveUtils = reactiveUtils;
274
- }
275
- /**
276
- * Initialize the search widget
277
- *
278
- * @protected
279
- */
280
- async _initFullscreenWidget() {
281
- if (this.mapView && this._fullscreenElement && !this.fullscreenWidget) {
282
- this.fullscreenWidget = new this.Fullscreen({
283
- view: this.mapView
284
- });
285
- await this.fullscreenWidget.when(() => {
286
- if (this._fullscreenStateChangeHandle) {
287
- this._fullscreenStateChangeHandle.remove();
288
- }
289
- this._fullscreenStateChangeHandle = this.reactiveUtils.watch(() => this.fullscreenWidget.viewModel.state, (state) => this.fullscreenStateChange.emit(state));
290
- });
291
- }
292
- else if (this.fullscreenWidget) {
293
- this.fullscreenWidget.view = this.mapView;
294
- }
295
- }
296
- static get watchers() { return {
297
- "mapView": ["mapViewWatchHandler"]
298
- }; }
299
- };
300
- MapFullscreen.style = mapFullscreenCss;
301
-
302
- const mapLegendCss = ":host{display:block}";
303
-
304
- const MapLegend = class {
305
- constructor(hostRef) {
306
- registerInstance(this, hostRef);
307
- this.mapView = undefined;
308
- this.legendWidget = undefined;
309
- }
310
- //--------------------------------------------------------------------------
311
- //
312
- // Watch handlers
313
- //
314
- //--------------------------------------------------------------------------
315
- async mapViewWatchHandler() {
316
- await this.mapView.when(() => {
317
- this._initLegend(this.mapView);
318
- });
319
- }
320
- //--------------------------------------------------------------------------
321
- //
322
- // Methods (public)
323
- //
324
- //--------------------------------------------------------------------------
325
- //--------------------------------------------------------------------------
326
- //
327
- // Events (public)
328
- //
329
- //--------------------------------------------------------------------------
330
- //--------------------------------------------------------------------------
331
- //
332
- // Functions (lifecycle)
333
- //
334
- //--------------------------------------------------------------------------
335
- /**
336
- * StencilJS: Called once just after the component is first connected to the DOM.
337
- */
338
- async componentWillLoad() {
339
- return this._initModules();
340
- }
341
- /**
342
- * StencilJS: Renders the component.
343
- */
344
- render() {
345
- return (h(Host, null, h("div", { ref: (el) => { this._legendElement = el; } })));
346
- }
347
- /**
348
- * StencilJS: Called once just after the component is fully loaded and the first render() occurs.
349
- */
350
- async componentDidLoad() {
351
- if (this.mapView) {
352
- await this.mapViewWatchHandler();
353
- }
354
- }
355
- //--------------------------------------------------------------------------
356
- //
357
- // Functions (protected)
358
- //
359
- //--------------------------------------------------------------------------
360
- /**
361
- * Load esri javascript api modules
362
- *
363
- * @returns Promise resolving when function is done
364
- *
365
- * @protected
366
- */
367
- async _initModules() {
368
- const [Legend] = await loadModules([
369
- "esri/widgets/Legend"
370
- ]);
371
- this.Legend = Legend;
372
- }
373
- /**
374
- * Initialize the basemap gallery or reset the current view if it already exists
375
- */
376
- _initLegend(view) {
377
- if (view && this.Legend) {
378
- if (!this.legendWidget) {
379
- this.legendWidget = new this.Legend({
380
- container: this._legendElement,
381
- view
382
- });
383
- }
384
- else {
385
- this.legendWidget.view = view;
386
- }
387
- }
388
- }
389
- get el() { return getElement(this); }
390
- static get watchers() { return {
391
- "mapView": ["mapViewWatchHandler"]
392
- }; }
393
- };
394
- MapLegend.style = mapLegendCss;
395
-
396
- const mapSearchCss = ":host{display:block}.search-widget{width:100% !important;border:1px solid var(--calcite-color-border-input)}";
397
-
398
- const MapSearch = class {
399
- constructor(hostRef) {
400
- registerInstance(this, hostRef);
401
- this.mapView = undefined;
402
- this.popupEnabled = false;
403
- this.resultGraphicEnabled = false;
404
- this.searchConfiguration = undefined;
405
- this.searchTerm = undefined;
406
- this.searchWidget = undefined;
407
- }
408
- //--------------------------------------------------------------------------
409
- //
410
- // Watch handlers
411
- //
412
- //--------------------------------------------------------------------------
413
- /**
414
- * Called each time the searchConfiguration prop is changed.
415
- *
416
- * @returns Promise when complete
417
- */
418
- async watchSearchConfigurationHandler() {
419
- this._initSearchWidget();
420
- }
421
- /**
422
- * Called each time the mapView prop is changed.
423
- *
424
- * @returns Promise when complete
425
- */
426
- async mapViewWatchHandler() {
427
- await this.mapView.when(() => {
428
- this._initSearchWidget();
429
- });
430
- }
431
- //--------------------------------------------------------------------------
432
- //
433
- // Methods (public)
434
- //
435
- //--------------------------------------------------------------------------
436
- //--------------------------------------------------------------------------
437
- //
438
- // Events (public)
439
- //
440
- //--------------------------------------------------------------------------
441
- //--------------------------------------------------------------------------
442
- //
443
- // Functions (lifecycle)
444
- //
445
- //--------------------------------------------------------------------------
446
- /**
447
- * StencilJS: Called once just after the component is first connected to the DOM.
448
- */
449
- async componentWillLoad() {
450
- await this._initModules();
451
- }
452
- /**
453
- * StencilJS: Called once just after the component is fully loaded and the first render() occurs.
454
- */
455
- async componentDidLoad() {
456
- return this._initSearchWidget();
457
- }
458
- /**
459
- * Renders the component.
460
- */
461
- render() {
462
- return (h(Host, null, h("div", { class: "search-widget", ref: (el) => { this._searchElement = el; } })));
463
- }
464
- //--------------------------------------------------------------------------
465
- //
466
- // Functions (protected)
467
- //
468
- //--------------------------------------------------------------------------
469
- /**
470
- * Load esri javascript api modules
471
- *
472
- * @returns Promise resolving when function is done
473
- *
474
- * @protected
475
- */
476
- async _initModules() {
477
- const [Search, FeatureLayer] = await loadModules([
478
- "esri/widgets/Search",
479
- "esri/layers/FeatureLayer"
480
- ]);
481
- this.Search = Search;
482
- this.FeatureLayer = FeatureLayer;
483
- }
484
- /**
485
- * Initialize the search widget
486
- *
487
- * @protected
488
- */
489
- _initSearchWidget() {
490
- if (this.mapView && this._searchElement && !this.searchWidget) {
491
- let searchOptions = {
492
- view: this.mapView,
493
- container: this._searchElement,
494
- searchTerm: this.searchTerm
495
- };
496
- if (this.searchConfiguration) {
497
- const searchConfiguration = this._getSearchConfig(this.searchConfiguration, this.mapView);
498
- searchOptions = Object.assign({}, searchConfiguration);
499
- }
500
- this.searchWidget = new this.Search(searchOptions);
501
- this.searchWidget.popupEnabled = this.popupEnabled;
502
- this.searchWidget.resultGraphicEnabled = this.resultGraphicEnabled;
503
- }
504
- else {
505
- if (this.searchWidget) {
506
- this.searchWidget.view = this.mapView;
507
- }
508
- }
509
- }
510
- /**
511
- * Initialize the search widget based on user defined configuration
512
- *
513
- * @param searchConfiguration search configuration defined by the user
514
- * @param view the current map view
515
- *
516
- * @protected
517
- */
518
- _getSearchConfig(searchConfiguration, view) {
519
- const INCLUDE_DEFAULT_SOURCES = "includeDefaultSources";
520
- const sources = searchConfiguration.sources;
521
- if ((sources === null || sources === void 0 ? void 0 : sources.length) > 0) {
522
- searchConfiguration[INCLUDE_DEFAULT_SOURCES] = false;
523
- sources.forEach((source) => {
524
- var _a, _b;
525
- const isLayerSource = source.hasOwnProperty("layer");
526
- if (isLayerSource) {
527
- const layerSource = source;
528
- const layerId = (_a = layerSource.layer) === null || _a === void 0 ? void 0 : _a.id;
529
- const layerFromMap = layerId ? view.map.findLayerById(layerId) : null;
530
- const layerUrl = (_b = layerSource === null || layerSource === void 0 ? void 0 : layerSource.layer) === null || _b === void 0 ? void 0 : _b.url;
531
- if (layerFromMap) {
532
- layerSource.layer = layerFromMap;
533
- }
534
- else if (layerUrl) {
535
- layerSource.layer = new this.FeatureLayer(layerUrl);
536
- }
537
- }
538
- });
539
- sources === null || sources === void 0 ? void 0 : sources.forEach((source) => {
540
- const isLocatorSource = source.hasOwnProperty("locator");
541
- if (isLocatorSource) {
542
- const locatorSource = source;
543
- if ((locatorSource === null || locatorSource === void 0 ? void 0 : locatorSource.name) === "ArcGIS World Geocoding Service") {
544
- const outFields = locatorSource.outFields || ["Addr_type", "Match_addr", "StAddr", "City"];
545
- locatorSource.outFields = outFields;
546
- locatorSource.singleLineFieldName = "SingleLine";
547
- }
548
- locatorSource.url = locatorSource.url;
549
- delete locatorSource.url;
550
- }
551
- });
552
- }
553
- else {
554
- searchConfiguration = Object.assign(Object.assign({}, searchConfiguration), { includeDefaultSources: true });
555
- }
556
- return searchConfiguration;
557
- }
558
- static get watchers() { return {
559
- "searchConfiguration": ["watchSearchConfigurationHandler"],
560
- "mapView": ["mapViewWatchHandler"]
561
- }; }
562
- };
563
- MapSearch.style = mapSearchCss;
564
-
565
- export { BasemapGallery as basemap_gallery, FloorFilter as floor_filter, MapFullscreen as map_fullscreen, MapLegend as map_legend, MapSearch as map_search };
@@ -1,28 +0,0 @@
1
- /*!
2
- * Copyright 2022 Esri
3
- * Licensed under the Apache License, Version 2.0
4
- * http://www.apache.org/licenses/LICENSE-2.0
5
- */
6
- import { e as esriLoader } from './esri-loader-eda07632.js';
7
-
8
- /** @license
9
- * Copyright 2022 Esri
10
- *
11
- * Licensed under the Apache License, Version 2.0 (the "License");
12
- * you may not use this file except in compliance with the License.
13
- * You may obtain a copy of the License at
14
- *
15
- * http://www.apache.org/licenses/LICENSE-2.0
16
- *
17
- * Unless required by applicable law or agreed to in writing, software
18
- * distributed under the License is distributed on an "AS IS" BASIS,
19
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
20
- * See the License for the specific language governing permissions and
21
- * limitations under the License.
22
- */
23
- const loadModules = async (moduleNames, options) => {
24
- const mods = await esriLoader.loadModules(moduleNames, options);
25
- return mods.map((mod) => (mod.__esModule && mod.default ? mod.default : mod));
26
- };
27
-
28
- export { loadModules as l };
@@ -1,6 +0,0 @@
1
- /*!
2
- * Copyright 2022 Esri
3
- * Licensed under the Apache License, Version 2.0
4
- * http://www.apache.org/licenses/LICENSE-2.0
5
- */
6
- import{r as t,h as i,H as e,g as s}from"./p-78780f63.js";import{g as h}from"./p-ab006ace.js";import{E as l}from"./p-c1cf3ebc.js";import{g as o}from"./p-4566438a.js";import"./p-48ff9cea.js";import"./p-d918ec36.js";import"./p-e1a4994d.js";const a=class{constructor(i){t(this,i),this._shouldSetMapView=!1,this.defaultCenter="",this.defaultFilter="",this.defaultGlobalId="",this.defaultLayer="",this.defaultLevel="",this.defaultOid="",this.defaultWebmap="",this.enableAutoRefresh=!1,this.enableColumnReorder=!0,this.enableCSV=!0,this.enableFloorFilter=!0,this.enableFullscreen=!0,this.enableInlineEdit=!1,this.enableLegend=!0,this.enableSearch=!0,this.enableShare=!1,this.enableHome=!0,this.enableZoom=!0,this.enableBasemap=!0,this.basemapConfig=void 0,this.showNewestFirst=!0,this.mapInfos=[],this.onlyShowUpdatableLayers=!0,this.searchConfiguration=void 0,this.shareIncludeEmbed=void 0,this.shareIncludeSocial=void 0,this.theme="light",this.zoomAndScrollToSelected=!1,this._expandPopup=!1,this._hideFooter=!1,this._hideTable=!1,this._isMobile=void 0,this._translations=void 0,this._layer=void 0,this._layoutMode=l.GRID,this._mapInfo=void 0,this._mapView=void 0,this._panelOpen=!0,this._numSelected=0,this._tableOnly=!1}defaultCenterWatchHandler(){this._defaultCenter=this.defaultCenter?this.defaultCenter.split(";").map((t=>parseFloat(t))):void 0}defaultFilterWatchHandler(){this._defaultFilter=JSON.parse(this.defaultFilter)}defaultGlobalIdWatchHandler(){this._defaultGlobalId=this.defaultGlobalId?this.defaultGlobalId.indexOf(",")>-1?this.defaultGlobalId.split(","):[this.defaultGlobalId]:void 0}defaultOidWatchHandler(){this._defaultOid=this.defaultOid?this.defaultOid.indexOf(",")>-1?this.defaultOid.split(",").map((t=>parseInt(t,10))):[parseInt(this.defaultOid,10)]:void 0}defaultLevelWatchHandler(){this._defaultLevel=this.defaultLevel?parseInt(this.defaultLevel,10):void 0}enableZoomWatchHandler(){this._initMapZoom()}async featureSelectionChange(t){var i;this._numSelected=null===(i=t.detail)||void 0===i?void 0:i.length}async popupClosed(){this._isMobile&&this.showHideMapPopupAndTable(!1)}async idsFound(t){const i=t.detail;this._tableOnly=i.tableIds.length>0&&0===i.layerIds.length,this._tableOnly&&(this._expandPopup=!0)}async layoutChanged(t){this._layoutMode=t.detail}async mapChanged(t){this._mapChange=t.detail,await this._mapChange.mapView.when((async()=>{await this._setMapView()}))}async beforeMapChanged(){this._expandPopup&&(this._shouldSetMapView=!0,this._expandPopup=!1)}async layerSelectionChange(t){const i=t.detail[0],e=await o(this._mapView,i);await e.when((()=>{this._layer=e}))}async componentWillLoad(){await this._getTranslations(),this._resizeObserver=new ResizeObserver((()=>this._onResize()))}render(){return i(e,null,i("calcite-shell",{class:"position-relative"},i("calcite-panel",{class:"width-full height-full"},this._getBody(this._layoutMode,this._panelOpen,this._hideTable)),this._getFooter()))}async componentDidRender(){this._shouldSetMapView&&(this._shouldSetMapView=!1,await this._setMapView())}async componentDidLoad(){this._resizeObserver.observe(this.el)}_getFooter(){var t,e,s,h;const l=(null===(t=this._layer)||void 0===t?void 0:t.editingEnabled)&&(null===(h=null===(s=null===(e=this._layer)||void 0===e?void 0:e.capabilities)||void 0===s?void 0:s.operations)||void 0===h?void 0:h.supportsDelete);return this._isMobile&&this._numSelected>0&&!this._hideFooter?i("div",{class:"width-100",slot:"footer"},i("div",{class:"display-flex padding-1-2"},i("calcite-button",{appearance:"solid",id:"solutions-show",onClick:()=>this.showHideMapPopupAndTable(!0),width:"full"},this._translations.view.replace("{{n}}",this._numSelected.toString())),l?i("delete-button",{class:"padding-inline-start-1 width-full",id:"solutions-delete",ids:this._layerTable.selectedIds,layer:this._layer}):void 0)):void 0}_getDividerIcon(t,i){let e="";switch(t){case l.HORIZONTAL:e=i?"chevrons-up":"chevrons-down";break;case l.VERTICAL:case l.GRID:e=i?"chevrons-left":"chevrons-right"}return e}_getMapSizeClass(t,i){let e="";switch(t){case l.HORIZONTAL:e=(i?"height-1-2 display-grid":"height-0")+" width-full position-relative";break;case l.GRID:e="height-full position-relative "+(i?"width-1-3":"width-0");break;case l.VERTICAL:e="height-full position-relative "+(i?"width-1-2":"width-0")}return e}_getTableSizeClass(t,i){let e="";switch(t){case l.HORIZONTAL:e=(i?"height-1-2":"height-full")+" width-full display-flex flex-column";break;case l.GRID:e=(i?"width-2-3":"width-full")+" height-full display-flex";break;case l.VERTICAL:e=(i?"width-1-2":"width-full")+" height-full display-flex"}return e}_getBody(t,e,s){return i("calcite-panel",{class:"width-full height-full"},i("div",{class:"width-full height-full overflow-hidden "+(t===l.HORIZONTAL?"":"display-flex")},this._getMapAndCard(t,e),this._getTable(t,e,s)))}_getMapAndCard(t,e){const s=this._getMapSizeClass(t,e);return i("div",{class:`${s} overflow-hidden`},this._getMapNode(t,e),this._getPopupExpandNode())}_getMapNode(t,e){var s;return i("div",{class:`${this._layoutMode!==l.HORIZONTAL||this._isMobile&&!e?"adjusted-height-50":""} overflow-hidden ${t===l.HORIZONTAL||t===l.GRID?"":"visibility-hidden"}`},i("map-card",{basemapConfig:this.basemapConfig,class:"width-full",defaultWebmapId:this.defaultWebmap,enableBasemap:this.enableBasemap,enableFloorFilter:this.enableFloorFilter,enableFullscreen:this.enableFullscreen,enableHome:this.enableHome,enableLegend:this.enableLegend,enableSearch:this.enableSearch,enableSingleExpand:!0,hidden:this._expandPopup,homeZoomIndex:3,homeZoomPosition:"top-left",homeZoomToolsSize:"s",mapInfos:null===(s=this.mapInfos)||void 0===s?void 0:s.filter((t=>!1!==t.visible)),mapWidgetsIndex:0,mapWidgetsPosition:"top-right",mapWidgetsSize:"m",stackTools:!0,theme:this.theme,toolOrder:["legend","search","fullscreen","basemap","floorfilter"]}))}_getPopupExpandNode(){var t;const e=this._expandPopup?"chevrons-down":"chevrons-up",s="expand-popup",h=this._expandPopup?this._translations.collapsePopup:this._translations.expandPopup,l="dark"===this.theme?"calcite-mode-dark":"calcite-mode-light",o=this._expandPopup?1===(null===(t=this.mapInfos)||void 0===t?void 0:t.length)||this._isMobile?"position-absolute-0":"position-absolute-50":"height-full",a=this._isMobile?"display-none height-0":"";return i("div",{class:`${this._isMobile?"calcite-mode-light":"calcite-mode-dark"} ${o} ${this._isMobile&&this._hideTable?"position-fixed width-full height-full":this._isMobile?"display-none height-0":""}`},i("calcite-panel",null,this._isMobile?void 0:i("div",{class:`display-flex align-items-center ${a}`,slot:"header-content"},i("calcite-icon",{icon:"information",scale:"s"}),i("div",{class:"padding-inline-start-75"},this._translations.information)),i("calcite-action",{class:a,disabled:this._tableOnly,icon:e,id:s,onClick:()=>this._togglePopup(),slot:"header-actions-end",text:""}),this._tableOnly?void 0:i("calcite-tooltip",{class:l,label:"",placement:"bottom","reference-element":s},i("span",null,h)),this._getCardNode()))}_togglePopup(){this._expandPopup=!this._expandPopup}_getCardNode(){return i("div",{class:"width-50 height-full "+("dark"===this.theme?"calcite-mode-dark":"calcite-mode-light")},i("card-manager",{class:(this._expandPopup||this._isMobile?"height-full":"height-50")+" width-full",isMobile:this._isMobile,mapView:null==this?void 0:this._mapView,zoomAndScrollToSelected:this.zoomAndScrollToSelected}))}_getTable(t,e,s){const h=s&&this._isMobile?"visibility-hidden":"",o=this._getTableSizeClass(t,e),a=this._getDividerIcon(t,e),d=e?this._translations.close:this._translations.open,n="toggle-layout",r=this.defaultWebmap&&this.defaultLayer;return i("calcite-shell",{class:`${o} ${h} border-bottom`},this._isMobile?void 0:i("calcite-action-bar",{class:"border-sides",expandDisabled:!0,layout:t===l.HORIZONTAL?"horizontal":"vertical",slot:t===l.HORIZONTAL?"header":"panel-start"},i("calcite-action",{class:"toggle-node",icon:a,id:n,onClick:()=>this._toggleLayout(),text:""}),i("calcite-tooltip",{label:d,placement:"bottom","reference-element":n},i("span",null,d))),i("div",{class:"width-full height-full position-relative"},i("layer-table",{defaultFilter:r?this._defaultFilter:void 0,defaultGlobalId:r?this._defaultGlobalId:void 0,defaultLayerId:r?this.defaultLayer:"",defaultOid:r&&!this.defaultGlobalId?this._defaultOid:void 0,enableAutoRefresh:this.enableAutoRefresh,enableCSV:this.enableCSV,enableColumnReorder:this.enableColumnReorder,enableInlineEdit:this.enableInlineEdit,enableShare:this.enableShare,isMobile:this._isMobile,mapInfo:this._mapInfo,mapView:null==this?void 0:this._mapView,onlyShowUpdatableLayers:this.onlyShowUpdatableLayers,ref:t=>this._layerTable=t,shareIncludeEmbed:this.shareIncludeEmbed,shareIncludeSocial:this.shareIncludeSocial,showNewestFirst:this.showNewestFirst,zoomAndScrollToSelected:this.zoomAndScrollToSelected})))}_onResize(){this._isMobile=this.el.offsetWidth<1024,this._layoutMode=this._isMobile?l.HORIZONTAL:l.GRID,this._panelOpen=!0}_toggleLayout(){this._panelOpen=!this._panelOpen}showHideMapPopupAndTable(t){this._expandPopup=!1,this._hideTable=t,this._hideFooter=t}_getMapInfo(t){let i;return this.mapInfos.some((e=>{if(e.id===t)return i=e,!0})),Object.assign({},i)}async _setMapView(){this._mapInfo=this._getMapInfo(this._mapChange.id),this._mapView=this._mapChange.mapView,this._initMapZoom(),this._mapView.popupEnabled=!1,this._defaultCenter&&this._defaultLevel&&(await this._mapView.goTo({center:this._defaultCenter,zoom:this._defaultLevel}),this._defaultCenter=void 0,this._defaultLevel=void 0)}_initMapZoom(){this.enableZoom?this.enableZoom&&this._mapView.ui.add({component:"zoom",position:"top-left",index:0}):this._mapView.ui.remove("zoom")}async _getTranslations(){const t=await h(this.el);this._translations=t[0]}get el(){return s(this)}static get watchers(){return{defaultCenter:["defaultCenterWatchHandler"],defaultFilter:["defaultFilterWatchHandler"],defaultGlobalId:["defaultGlobalIdWatchHandler"],defaultOid:["defaultOidWatchHandler"],defaultLevel:["defaultLevelWatchHandler"],enableZoom:["enableZoomWatchHandler"]}}};a.style=":host{display:block;--calcite-label-margin-bottom:0px;--solutions-theme-foreground-color:var(--calcite-color-foreground-1)}.padding-1-2{padding:0.5rem}.display-flex{display:flex}.width-full{width:100%}.width-1-2{position:relative;width:50%}.width-1-3{position:relative;width:33.33%}.width-2-3{position:relative;width:66.66%}.width-0{width:0}.height-full{height:100%}.height-1-2{position:relative;height:50%}.height-0{height:0}.toggle-node{width:51px;height:51px}.overflow-hidden{overflow:hidden}.flex-column{flex-direction:column}.border{border:1px solid var(--calcite-color-border-3)}.border-bottom{border-bottom:1px solid var(--calcite-color-border-3)}.border-sides{border-left:1px solid var(--calcite-color-border-3);border-right:1px solid var(--calcite-color-border-3)}.position-relative{position:relative}.height-50{height:50%}.adjusted-height-50{height:calc(50% - 25px)}.adjusted-height-100{height:calc(100% - 50px)}.adjusted-height-100-50{height:calc(100% - 50px)}.display-none{display:none}.height-53{height:53px}.position-absolute-53{position:absolute;top:53px}.display-grid{display:grid}.height-50-px{height:50px}.padding-inline-start-75{padding-inline-start:0.75rem}.align-items-center{align-items:center}.esri-floor-filter__close-levels-button{width:40px !important;height:40px !important}.esri-floor-filter__level-button{width:40px !important;height:40px !important}.esri-floor-filter__browse-button{width:40px !important;height:40px !important}.position-absolute-50{position:absolute;top:50px;bottom:0px;left:0px;right:0px}.position-absolute-0{position:absolute;top:0px;bottom:0px;left:0px;right:0px}.visibility-hidden{visibility:hidden;height:0px}.position-fixed{position:fixed}";export{a as crowdsource_manager}
@@ -1,21 +0,0 @@
1
- /*!
2
- * Copyright 2022 Esri
3
- * Licensed under the Apache License, Version 2.0
4
- * http://www.apache.org/licenses/LICENSE-2.0
5
- */
6
- import{e as a}from"./p-d918ec36.js";
7
- /** @license
8
- * Copyright 2022 Esri
9
- *
10
- * Licensed under the Apache License, Version 2.0 (the "License");
11
- * you may not use this file except in compliance with the License.
12
- * You may obtain a copy of the License at
13
- *
14
- * http://www.apache.org/licenses/LICENSE-2.0
15
- *
16
- * Unless required by applicable law or agreed to in writing, software
17
- * distributed under the License is distributed on an "AS IS" BASIS,
18
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19
- * See the License for the specific language governing permissions and
20
- * limitations under the License.
21
- */const s=async(s,o)=>(await a.loadModules(s,o)).map((a=>a.__esModule&&a.default?a.default:a));export{s as l}