Skip to content

Commit

Permalink
Added documentation for BingMaps and MapBox. (#3492)
Browse files Browse the repository at this point in the history
* Added documentation for BingMaps and MapBox.

* Added Azuremaps format, fixed typo.

* Update MapLayerFormatRegistry.ts

* change log

* api-extract

Co-authored-by: Paul Connelly <[email protected]>
  • Loading branch information
mdastous-bentley and pmconne authored Apr 8, 2022
1 parent 00747c1 commit d2ec9cb
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 5 deletions.
4 changes: 0 additions & 4 deletions common/api/core-frontend.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -5799,13 +5799,9 @@ export enum MapLayerImageryProviderStatus {

// @beta
export interface MapLayerOptions {
// (undocumented)
[format: string]: MapLayerKey | undefined;
// (undocumented)
AzureMaps?: MapLayerKey;
// (undocumented)
BingMaps?: MapLayerKey;
// (undocumented)
MapboxImagery?: MapLayerKey;
}

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"changes": [
{
"packageName": "@itwin/core-frontend",
"comment": "Added documentation for MapLayerKey.",
"type": "none"
}
],
"packageName": "@itwin/core-frontend"
}
6 changes: 5 additions & 1 deletion core/frontend/src/tile/map/MapLayerFormatRegistry.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,16 +36,20 @@ export interface MapLayerSourceValidation {
}

/**
* Options to be passed to the IModelApp on startup which contain access keys for various layer formats
* Options supplied at startup via [[IModelAppOptions.mapLayerOptions]] to specify access keys for various map layer formats.
* @beta
*/
export interface MapLayerOptions {
/** Access key for Azure Maps in the format `{ key: "subscription-key", value: "your-azure-maps-key" }`. */
// eslint-disable-next-line @typescript-eslint/naming-convention
AzureMaps?: MapLayerKey;
/** Access key for Mapbox in the format `{ key: "access_token", value: "your-mapbox-key" }`. */
// eslint-disable-next-line @typescript-eslint/naming-convention
MapboxImagery?: MapLayerKey;
/** Access key for Bing Maps in the format `{ key: "key", value: "your-bing-maps-key" }`. */
// eslint-disable-next-line @typescript-eslint/naming-convention
BingMaps?: MapLayerKey;
/** Access keys for additional map layer formats. */
[format: string]: MapLayerKey | undefined;
}

Expand Down

0 comments on commit d2ec9cb

Please sign in to comment.