@vertigis/viewer-spec 43.0.0 → 43.3.1

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.
@@ -22,6 +22,7 @@ import type { MapExtension } from "@vertigis/arcgis-extensions/mapping/MapExtens
22
22
  import type { SublayerExtension } from "@vertigis/arcgis-extensions/mapping/SublayerExtension";
23
23
  import type { LayerExtension, LayerReference as LayerReferenceObject } from "@vertigis/arcgis-extensions/mapping/_LayerExtension";
24
24
  import type { Feature as GraphicJson } from "@vertigis/arcgis-extensions/portal/Feature";
25
+ import type { Geometry as GeometryJson } from "@vertigis/arcgis-extensions/portal/Geometry";
25
26
  import type { LineSymbol3D as LineSymbol3DProperties } from "@vertigis/arcgis-extensions/portal/LineSymbol3D";
26
27
  import type { PictureFillSymbol as PictureFillSymbolProperties } from "@vertigis/arcgis-extensions/portal/PictureFillSymbol";
27
28
  import type { PictureMarkerSymbol as PictureMarkerSymbolProperties } from "@vertigis/arcgis-extensions/portal/PictureMarkerSymbol";
@@ -32,6 +33,7 @@ import type { SimpleLineSymbol as SimpleLineSymbolProperties } from "@vertigis/a
32
33
  import type { SimpleMarkerSymbol as SimpleMarkerSymbolProperties } from "@vertigis/arcgis-extensions/portal/SimpleMarkerSymbol";
33
34
  import type { Viewpoint as ViewpointJson } from "@vertigis/arcgis-extensions/portal/Viewpoint";
34
35
  import type { SublayerLike } from "@vertigis/arcgis-extensions/support/esri";
36
+ import type { ItemRef } from "app-config/common/ItemRef";
35
37
  /**
36
38
  * A model belonging to a component.
37
39
  */
@@ -142,6 +144,26 @@ export interface HasGraphics {
142
144
  */
143
145
  graphics?: GraphicsLike;
144
146
  }
147
+ /**
148
+ * An object with arguments for a command or operation that can display
149
+ * temporary UI.
150
+ */
151
+ export interface HasUITarget {
152
+ /**
153
+ * The layout ID or ItemRef to target for the command/operation. This
154
+ * component will be the parent of the temporary UI that will be removed
155
+ * after the command/operation completes.
156
+ */
157
+ parent?: string | ItemRef;
158
+ /**
159
+ * Optional layout XML attributes to be used for the transient UI container.
160
+ */
161
+ attributes?: Record<string, string | number | boolean | undefined>;
162
+ /**
163
+ * Optional icon that may be used by the transient UI container.
164
+ */
165
+ icon?: string;
166
+ }
145
167
  /**
146
168
  * An object that is convertible to Esri Graphic or set of graphics, or an
147
169
  * object that has graphics.
@@ -150,7 +172,7 @@ export declare type Graphics = GraphicsLike | HasGraphics;
150
172
  /**
151
173
  * An object that is convertible to one or more geometries.
152
174
  */
153
- export declare type GeometryLike = Geometry | Geometry[] | FeaturesLike | GraphicsLike;
175
+ export declare type GeometryLike = GeometryJson | Geometry | (GeometryJson | Geometry)[] | FeaturesLike | GraphicsLike;
154
176
  /**
155
177
  * An object that has a `geometry` property.
156
178
  */
@@ -21,7 +21,7 @@ import type { Command } from "../Command.js";
21
21
  import { CommandRegistry } from "../CommandRegistry.js";
22
22
  import type { Operation } from "../Operation.js";
23
23
  import { OperationRegistry } from "../OperationRegistry.js";
24
- import type { CreateGraphicsResult, GeometryLike, HasFeatures, HasGraphics, HasLayers, HasMaps, HasSymbol, SymbolLike } from "../common.js";
24
+ import type { CreateGraphicsResult, GeometryLike, HasFeatures, HasGraphics, HasLayers, HasMaps, HasSymbol, HasUITarget, SymbolLike } from "../common.js";
25
25
  /**
26
26
  * Symbols supported for drawing.
27
27
  */
@@ -40,7 +40,7 @@ export interface GetDefaultSymbolArgs {
40
40
  * Arguments for the drawing.edit-symbol operation. Only available in Geocortex
41
41
  * Web.
42
42
  */
43
- export interface EditSymbolArgs extends HasMaps, HasLayers, HasGraphics, HasFeatures {
43
+ export interface EditSymbolArgs extends HasMaps, HasLayers, HasGraphics, HasFeatures, HasUITarget {
44
44
  /**
45
45
  * The geometry type for the symbol to create.
46
46
  */
@@ -5,7 +5,7 @@ import type { Command } from "../Command.js";
5
5
  import { CommandRegistry } from "../CommandRegistry.js";
6
6
  import type { Operation } from "../Operation.js";
7
7
  import { OperationRegistry } from "../OperationRegistry.js";
8
- import type { Geometries, HasFeatures, HasGeometry, HasMaps, MapsLike } from "../common.js";
8
+ import type { Geometries, HasFeatures, HasGeometry, HasMaps, HasUITarget, MapsLike } from "../common.js";
9
9
  import type { CaptureGeometryResult } from "./sketching.js";
10
10
  /**
11
11
  * Arguments for the geometry.project operation.
@@ -97,5 +97,5 @@ export declare class GeometryCommands extends CommandRegistry {
97
97
  *
98
98
  * @webOnly
99
99
  */
100
- get showSettings(): Command<void>;
100
+ get showSettings(): Command<HasUITarget>;
101
101
  }
@@ -19,7 +19,7 @@ import type { Event } from "../Event.js";
19
19
  import { EventRegistry } from "../EventRegistry.js";
20
20
  import type { Operation } from "../Operation.js";
21
21
  import { OperationRegistry } from "../OperationRegistry.js";
22
- import type { Features, FeaturesLike, Geometries, GeometryLike, GraphicsLike, Layers, LayersLike, Maps, MapsLike, ViewpointLike } from "../common.js";
22
+ import type { Features, FeaturesLike, Geometries, GeometryLike, GraphicsLike, HasUITarget, Layers, LayersLike, Maps, MapsLike, ViewpointLike } from "../common.js";
23
23
  import type { MapExtensionArgs } from "../mobile.js";
24
24
  import type { EnhancedFileData } from "./file.js";
25
25
  import type { GeometryEditorSettings } from "./sketching.js";
@@ -200,7 +200,7 @@ export interface UpdateLayerArgs {
200
200
  /**
201
201
  * Arguments for the map.create-note command.
202
202
  */
203
- export interface CreateMapNoteArgs {
203
+ export interface CreateMapNoteArgs extends HasUITarget {
204
204
  /**
205
205
  * Optionally the features that can be referenced for inserting snippets.
206
206
  */
@@ -217,7 +217,7 @@ export interface CreateMapNoteArgs {
217
217
  /**
218
218
  * Arguments for the map.edit-note command.
219
219
  */
220
- export interface EditMapNotesArgs {
220
+ export interface EditMapNotesArgs extends HasUITarget {
221
221
  /**
222
222
  * Optionally the features that can be referenced for inserting snippets.
223
223
  */
@@ -234,7 +234,7 @@ export interface EditMapNotesArgs {
234
234
  /**
235
235
  * Arguments for the map.get-user-coordinates-input operation.
236
236
  */
237
- export interface GetCoordinateArgs {
237
+ export interface GetCoordinateArgs extends HasUITarget {
238
238
  /**
239
239
  * The map on which to select the result.
240
240
  */
@@ -4,7 +4,7 @@ import type { Command } from "../Command.js";
4
4
  import { CommandRegistry } from "../CommandRegistry.js";
5
5
  import type { Operation } from "../Operation.js";
6
6
  import { OperationRegistry } from "../OperationRegistry.js";
7
- import type { CreateGraphicsResult, Geometries, HasSymbol, Maps, SymbolLike } from "../common.js";
7
+ import type { CreateGraphicsResult, Geometries, HasSymbol, HasUITarget, Maps, SymbolLike } from "../common.js";
8
8
  import type { MapExtensionArgs } from "../mobile.js";
9
9
  import type { DrawingSymbolConfig } from "./drawing.js";
10
10
  import type { CaptureGeometryArgs, CaptureGeometryResult } from "./sketching.js";
@@ -66,7 +66,7 @@ export declare class MeasurementCommands extends CommandRegistry {
66
66
  *
67
67
  * @webOnly
68
68
  */
69
- get showSettings(): Command<void>;
69
+ get showSettings(): Command<HasUITarget>;
70
70
  /**
71
71
  * Starts drawing a measurement on the map. If a drawing has previously been
72
72
  * started and stopped it will be resumed.
@@ -2,7 +2,7 @@ import type { Event } from "../Event.js";
2
2
  import { EventRegistry } from "../EventRegistry.js";
3
3
  import type { Operation } from "../Operation.js";
4
4
  import { OperationRegistry } from "../OperationRegistry.js";
5
- import type { HasMaps, LayersLike } from "../common.js";
5
+ import type { HasMaps, HasUITarget, LayersLike } from "../common.js";
6
6
  /**
7
7
  * Corresponds to `VertiGIS.Mobile.Infrastructure.Portal.ArcGISPortalExtension`
8
8
  * in the VertiGIS.Mobile SDK.
@@ -12,7 +12,7 @@ export interface ArcGISPortalExtension {
12
12
  /**
13
13
  * Arguments for the "portal.choose-layers" operation.
14
14
  */
15
- export interface ChooseLayersOptions extends HasMaps {
15
+ export interface ChooseLayersOptions extends HasMaps, HasUITarget {
16
16
  /**
17
17
  * Whether the user can choose multiple layers, or just one. Default is
18
18
  * `false`.
@@ -2,7 +2,7 @@ import type { Command } from "../Command.js";
2
2
  import { CommandRegistry } from "../CommandRegistry.js";
3
3
  import type { Operation } from "../Operation.js";
4
4
  import { OperationRegistry } from "../OperationRegistry.js";
5
- import type { Blob, File } from "../common.js";
5
+ import type { Blob, File, HasUITarget } from "../common.js";
6
6
  /**
7
7
  * Arguments for the system.download-file operation.
8
8
  */
@@ -19,7 +19,7 @@ export interface DownloadArgs {
19
19
  /**
20
20
  * Arguments for the system.read-file operation.
21
21
  */
22
- export interface ReadFileArgs {
22
+ export interface ReadFileArgs extends HasUITarget {
23
23
  /**
24
24
  * The accept parameter for the file input.
25
25
  * {@link https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/accept}.
@@ -294,6 +294,18 @@ export declare class UIOperations extends OperationRegistry {
294
294
  * @webOnly
295
295
  */
296
296
  get prompt(): Operation<PromptOperationArgs, string>;
297
+ /**
298
+ * Gets the active color theme of the viewer. Returns the theme's ID.
299
+ *
300
+ * @webOnly
301
+ */
302
+ get getTheme(): Operation<void, string>;
303
+ /**
304
+ * Gets all color themes available to the viewer. Returns the theme IDs.
305
+ *
306
+ * @webOnly
307
+ */
308
+ get getThemes(): Operation<void, string[]>;
297
309
  /**
298
310
  * Gets the visual state of a component.
299
311
  *
@@ -1 +1 @@
1
- import{CommandRegistry}from"../CommandRegistry.js";import{EventRegistry}from"../EventRegistry.js";import{OperationRegistry}from"../OperationRegistry.js";export var NotificationCategory;!function(e){e.ERROR="error",e.INFO="info",e.SUCCESS="success",e.WARNING="warning"}(NotificationCategory||(NotificationCategory={}));export var Position;!function(e){e.BOTTOM="bottom",e.LEFT="left",e.RIGHT="right",e.TOP="top"}(Position||(Position={}));export class UICommands extends CommandRegistry{get activate(){return this._messages.command("ui.activate")}get activeToggle(){return this._messages.command("ui.active-toggle")}get alert(){return this._messages.command("ui.alert")}get await(){return this._messages.command("ui.await")}get deactivate(){return this._messages.command("ui.deactivate")}get displayBusyState(){return this._messages.command("ui.display-busy-state")}get displayNotification(){return this._messages.command("ui.display-notification")}get pauseNotifications(){return this._messages.command("ui.pause-notifications")}get resumeNotifications(){return this._messages.command("ui.resume-notifications")}get focus(){return this._messages.command("ui.focus")}get hideBusyState(){return this._messages.command("ui.hide-busy-state")}get hideNotification(){return this._messages.command("ui.hide-notification")}get narrate(){return this._messages.command("ui.narrate")}get setDensity(){return this._messages.command("ui.set-density")}get setLocale(){return this._messages.command("ui.set-locale")}get setTheme(){return this._messages.command("ui.set-theme")}get setVisualState(){return this._messages.command("ui.set-visual-state")}}export class UIOperations extends OperationRegistry{get confirm(){return this._messages.operation("ui.confirm")}get prompt(){return this._messages.operation("ui.prompt")}get getVisualState(){return this._messages.operation("ui.get-visual-state")}}export class UIEvents extends EventRegistry{get activated(){return this._messages.event("ui.activated")}get added(){return this._messages.event("ui.added")}get ancestorActivated(){return this._messages.event("ui.ancestor-activated")}get ancestorDeactivated(){return this._messages.event("ui.ancestor-deactivated")}get deactivated(){return this._messages.event("ui.deactivated")}get densityChanged(){return this._messages.event("ui.density-changed")}get localeChanged(){return this._messages.event("ui.locale-changed")}get initializing(){return this._messages.event("ui.initializing")}get initialized(){return this._messages.event("ui.initialized")}get removed(){return this._messages.event("ui.removed")}get reordered(){return this._messages.event("ui.reordered")}get themeChanged(){return this._messages.event("ui.theme-changed")}}
1
+ import{CommandRegistry}from"../CommandRegistry.js";import{EventRegistry}from"../EventRegistry.js";import{OperationRegistry}from"../OperationRegistry.js";export var NotificationCategory;!function(e){e.ERROR="error",e.INFO="info",e.SUCCESS="success",e.WARNING="warning"}(NotificationCategory||(NotificationCategory={}));export var Position;!function(e){e.BOTTOM="bottom",e.LEFT="left",e.RIGHT="right",e.TOP="top"}(Position||(Position={}));export class UICommands extends CommandRegistry{get activate(){return this._messages.command("ui.activate")}get activeToggle(){return this._messages.command("ui.active-toggle")}get alert(){return this._messages.command("ui.alert")}get await(){return this._messages.command("ui.await")}get deactivate(){return this._messages.command("ui.deactivate")}get displayBusyState(){return this._messages.command("ui.display-busy-state")}get displayNotification(){return this._messages.command("ui.display-notification")}get pauseNotifications(){return this._messages.command("ui.pause-notifications")}get resumeNotifications(){return this._messages.command("ui.resume-notifications")}get focus(){return this._messages.command("ui.focus")}get hideBusyState(){return this._messages.command("ui.hide-busy-state")}get hideNotification(){return this._messages.command("ui.hide-notification")}get narrate(){return this._messages.command("ui.narrate")}get setDensity(){return this._messages.command("ui.set-density")}get setLocale(){return this._messages.command("ui.set-locale")}get setTheme(){return this._messages.command("ui.set-theme")}get setVisualState(){return this._messages.command("ui.set-visual-state")}}export class UIOperations extends OperationRegistry{get confirm(){return this._messages.operation("ui.confirm")}get prompt(){return this._messages.operation("ui.prompt")}get getTheme(){return this._messages.operation("ui.get-theme")}get getThemes(){return this._messages.operation("ui.get-themes")}get getVisualState(){return this._messages.operation("ui.get-visual-state")}}export class UIEvents extends EventRegistry{get activated(){return this._messages.event("ui.activated")}get added(){return this._messages.event("ui.added")}get ancestorActivated(){return this._messages.event("ui.ancestor-activated")}get ancestorDeactivated(){return this._messages.event("ui.ancestor-deactivated")}get deactivated(){return this._messages.event("ui.deactivated")}get densityChanged(){return this._messages.event("ui.density-changed")}get localeChanged(){return this._messages.event("ui.locale-changed")}get initializing(){return this._messages.event("ui.initializing")}get initialized(){return this._messages.event("ui.initialized")}get removed(){return this._messages.event("ui.removed")}get reordered(){return this._messages.event("ui.reordered")}get themeChanged(){return this._messages.event("ui.theme-changed")}}
@@ -1028,10 +1028,19 @@
1028
1028
  "$ref": "#/definitions/esri.FeatureSet"
1029
1029
  },
1030
1030
  {
1031
- "items": {
1032
- "$ref": "#/definitions/esri.Geometry"
1033
- },
1034
- "type": "array"
1031
+ "$ref": "#/definitions/esri.rest-api.Extent.Extent"
1032
+ },
1033
+ {
1034
+ "$ref": "#/definitions/esri.rest-api.Multipoint.Multipoint"
1035
+ },
1036
+ {
1037
+ "$ref": "#/definitions/esri.rest-api.Polygon.Polygon"
1038
+ },
1039
+ {
1040
+ "$ref": "#/definitions/esri.rest-api.Polyline.Polyline"
1041
+ },
1042
+ {
1043
+ "$ref": "#/definitions/esri.rest-api.Point.Point"
1035
1044
  },
1036
1045
  {
1037
1046
  "$ref": "#/definitions/esri.rest-api.Feature.Feature"
@@ -1076,6 +1085,31 @@
1076
1085
  ]
1077
1086
  },
1078
1087
  "type": "array"
1088
+ },
1089
+ {
1090
+ "items": {
1091
+ "anyOf": [
1092
+ {
1093
+ "$ref": "#/definitions/esri.Geometry"
1094
+ },
1095
+ {
1096
+ "$ref": "#/definitions/esri.rest-api.Extent.Extent"
1097
+ },
1098
+ {
1099
+ "$ref": "#/definitions/esri.rest-api.Multipoint.Multipoint"
1100
+ },
1101
+ {
1102
+ "$ref": "#/definitions/esri.rest-api.Polygon.Polygon"
1103
+ },
1104
+ {
1105
+ "$ref": "#/definitions/esri.rest-api.Polyline.Polyline"
1106
+ },
1107
+ {
1108
+ "$ref": "#/definitions/esri.rest-api.Point.Point"
1109
+ }
1110
+ ]
1111
+ },
1112
+ "type": "array"
1079
1113
  }
1080
1114
  ],
1081
1115
  "description": "An object that is convertible to one or more geometries."
@@ -1241,10 +1241,19 @@
1241
1241
  "$ref": "#/definitions/esri.FeatureSet"
1242
1242
  },
1243
1243
  {
1244
- "items": {
1245
- "$ref": "#/definitions/esri.Geometry"
1246
- },
1247
- "type": "array"
1244
+ "$ref": "#/definitions/esri.rest-api.Extent.Extent"
1245
+ },
1246
+ {
1247
+ "$ref": "#/definitions/esri.rest-api.Multipoint.Multipoint"
1248
+ },
1249
+ {
1250
+ "$ref": "#/definitions/esri.rest-api.Polygon.Polygon"
1251
+ },
1252
+ {
1253
+ "$ref": "#/definitions/esri.rest-api.Polyline.Polyline"
1254
+ },
1255
+ {
1256
+ "$ref": "#/definitions/esri.rest-api.Point.Point"
1248
1257
  },
1249
1258
  {
1250
1259
  "$ref": "#/definitions/esri.rest-api.Feature.Feature"
@@ -1289,6 +1298,31 @@
1289
1298
  ]
1290
1299
  },
1291
1300
  "type": "array"
1301
+ },
1302
+ {
1303
+ "items": {
1304
+ "anyOf": [
1305
+ {
1306
+ "$ref": "#/definitions/esri.Geometry"
1307
+ },
1308
+ {
1309
+ "$ref": "#/definitions/esri.rest-api.Extent.Extent"
1310
+ },
1311
+ {
1312
+ "$ref": "#/definitions/esri.rest-api.Multipoint.Multipoint"
1313
+ },
1314
+ {
1315
+ "$ref": "#/definitions/esri.rest-api.Polygon.Polygon"
1316
+ },
1317
+ {
1318
+ "$ref": "#/definitions/esri.rest-api.Polyline.Polyline"
1319
+ },
1320
+ {
1321
+ "$ref": "#/definitions/esri.rest-api.Point.Point"
1322
+ }
1323
+ ]
1324
+ },
1325
+ "type": "array"
1292
1326
  }
1293
1327
  ],
1294
1328
  "description": "An object that is convertible to one or more geometries."