@tomtom-org/maps-sdk 0.30.0 → 0.30.2
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/CHANGELOG.md +14 -0
- package/README.md +16 -10
- package/core/dist/core.cjs.js +1 -1
- package/core/dist/core.cjs.min.js +1 -1
- package/core/dist/core.es.js +1 -1
- package/map/dist/THIRD_PARTY.txt +1 -1
- package/map/dist/index.d.ts +6 -41
- package/map/dist/map.cjs.js +55 -2
- package/map/dist/map.cjs.js.map +1 -1
- package/map/dist/map.cjs.min.js +1 -1
- package/map/dist/map.cjs.min.js.map +1 -1
- package/map/dist/map.es.js +1 -1
- package/map/dist/map.es.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,20 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
+
## [0.30.2](https://github.com/tomtom-internal/maps-sdk-js/compare/v0.30.1...v0.30.2) (2025-11-06)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### Bug Fixes
|
|
9
|
+
|
|
10
|
+
* example having incorrect references ([695d654](https://github.com/tomtom-internal/maps-sdk-js/commit/695d654ac8309ba735db67d190726c6e79db6158))
|
|
11
|
+
|
|
12
|
+
## [0.30.1](https://github.com/tomtom-internal/maps-sdk-js/compare/v0.30.0...v0.30.1) (2025-11-05)
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
### Bug Fixes
|
|
16
|
+
|
|
17
|
+
* pin category mapping ([a6aecb8](https://github.com/tomtom-internal/maps-sdk-js/commit/a6aecb8569e3865d32ca814684f1c8c8d1f3b3e0))
|
|
18
|
+
|
|
5
19
|
## [0.30.0](https://github.com/tomtom-internal/maps-sdk-js/compare/v0.29.2...v0.30.0) (2025-11-05)
|
|
6
20
|
|
|
7
21
|
|
package/README.md
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
# TomTom Maps SDK for JavaScript
|
|
4
4
|
|
|
5
5
|
[**Examples**](https://docs.tomtom.com/maps-sdk-js/examples/) |
|
|
6
|
-
[**Documentation**](https://docs.tomtom.com/maps-sdk-js/introduction/overview)
|
|
6
|
+
[**Documentation**](https://docs.tomtom.com/maps-sdk-js/introduction/overview)
|
|
7
7
|
|
|
8
8
|
[](https://www.npmjs.com/package/@tomtom-org/maps-sdk)
|
|
9
9
|
|
|
@@ -15,12 +15,19 @@ It leverages the power of [MapLibre GL JS](https://github.com/maplibre/maplibre-
|
|
|
15
15
|
to seamlessly integrate TomTom maps and services with convenient out-of-the-box support, while staying highly customizable and extensible.
|
|
16
16
|
<br/><br/>
|
|
17
17
|
|
|
18
|
+
## ⚠️ Public Preview Notice
|
|
19
|
+
We have released some capabilities in the Maps SDK under [Public Preview](https://docs.tomtom.com/legal/public-preview) to collect feedback from the community.
|
|
20
|
+
While our goal is to keep the design of the interface stable, breaking changes may occur.
|
|
21
|
+
We will do our utmost to communicate these breaking changes in advance, whenever possible.
|
|
22
|
+
<br/><br/>
|
|
23
|
+
|
|
18
24
|
## 🚀 Getting Started using npm
|
|
19
25
|
```
|
|
20
26
|
npm i @tomtom-org/maps-sdk
|
|
21
27
|
```
|
|
22
28
|
Additionally:
|
|
23
29
|
* If you use the map: ```npm i maplibre-gl```
|
|
30
|
+
<br/><br/>
|
|
24
31
|
|
|
25
32
|
## 📚 Documentation & Examples
|
|
26
33
|
|
|
@@ -32,16 +39,14 @@ Explore comprehensive guides and interactive examples to get the most out of Map
|
|
|
32
39
|
### 📖 Documentation
|
|
33
40
|
- **[Getting Started Guide](https://docs.tomtom.com/maps-sdk-js/introduction/overview)** - Introduction and key features
|
|
34
41
|
- **[Project Setup](https://docs.tomtom.com/maps-sdk-js/introduction/project-setup)** - Step-by-step setup instructions
|
|
35
|
-
- **[
|
|
36
|
-
- **[Services Guides](https://docs.tomtom.com/maps-sdk-js/guides/services/)** - Search, routing, and geocoding
|
|
37
|
-
- **[Core Utilities](https://docs.tomtom.com/maps-sdk-js/guides/core/)** - Common configurations and utilities
|
|
42
|
+
- **[How the SDK Works](https://docs.tomtom.com/maps-sdk-js/guides/how-the-sdk-works)** - Architecture and concepts
|
|
38
43
|
|
|
39
44
|
### 📋 API Reference
|
|
40
45
|
- **[API Reference](https://docs.tomtom.com/maps-sdk-js/reference/overview)** - Complete API documentation
|
|
41
46
|
|
|
42
47
|
### 📝 Latest Updates
|
|
43
48
|
- **[Release Notes](https://docs.tomtom.com/maps-sdk-js/overview/release-notes)** - What's new and breaking changes
|
|
44
|
-
<br/><br
|
|
49
|
+
<br/><br/>
|
|
45
50
|
|
|
46
51
|
## 🌍 Where can you run it on?
|
|
47
52
|
* **web**: display and configure a map, search for places, plan routes, and easily display and interact with them, including your own data
|
|
@@ -51,14 +56,15 @@ Explore comprehensive guides and interactive examples to get the most out of Map
|
|
|
51
56
|
|
|
52
57
|
## 📦 Bundles
|
|
53
58
|
* [Map](#map): MapLibre-powered library for readily styled, service-compatible and interactive TomTom Maps
|
|
54
|
-
*
|
|
59
|
+
* [MapLibre](https://maplibre.org/maplibre-gl-js/docs/) is an open source peer dependency so your application can also use it directly
|
|
55
60
|
* [Services](#services): Functions with GeoJSON services for TomTom location APIs
|
|
56
|
-
*
|
|
61
|
+
* Compatible with web, nodejs and React Native applications
|
|
57
62
|
* [Core](#core): shared configuration, types and utilities
|
|
58
|
-
*
|
|
63
|
+
* Facilitates seamless integration between map and services
|
|
64
|
+
<br/><br/>
|
|
59
65
|
|
|
60
66
|
## 🗺️ Map
|
|
61
|
-
The SDK [Map bundle](https://
|
|
67
|
+
The SDK [Map bundle](https://docs.tomtom.com/maps-sdk-js/guides/map/quickstart) is built on top of [MapLibre GL JS](https://maplibre.org/maplibre-gl-js/docs/), and shares it as a dependency with your app.\
|
|
62
68
|
You can both use the TomTom and MapLibre SDKs together at any time.
|
|
63
69
|
|
|
64
70
|
### ✨ Feature highlights
|
|
@@ -80,7 +86,7 @@ Code imports from the SDK Map Bundle will come from ```@tomtom-org/maps-sdk/map`
|
|
|
80
86
|
<br/><br/>
|
|
81
87
|
|
|
82
88
|
## 🔧 Services
|
|
83
|
-
The SDK [Services bundle](https://
|
|
89
|
+
The SDK [Services bundle](https://docs.tomtom.com/maps-sdk-js/guides/services/quickstart) integrates the TomTom location APIs into comprehensive [GeoJSON](https://geojson.org/) services.\
|
|
84
90
|
The services can be integrated in **web**, [nodejs](https://nodejs.org/) and [React Native](https://reactnative.dev/) apps.\
|
|
85
91
|
The compatibility of both inputs and outputs with [GeoJSON](https://geojson.org/) helps with further integration with geospatial tools.
|
|
86
92
|
|
package/core/dist/core.cjs.js
CHANGED
|
@@ -273,7 +273,7 @@ const validateTrackingId = (trackingId) => {
|
|
|
273
273
|
return trackingId;
|
|
274
274
|
};
|
|
275
275
|
const generateTomTomHeaders = (params) => ({
|
|
276
|
-
"TomTom-User-Agent": `${TOMTOM_USER_AGENT_SDK_NAME}/${"0.30.
|
|
276
|
+
"TomTom-User-Agent": `${TOMTOM_USER_AGENT_SDK_NAME}/${"0.30.2"}`,
|
|
277
277
|
// TODO: restore if we implement oauth2 access
|
|
278
278
|
// optional oauth2 access token:
|
|
279
279
|
// ...(params.apiAccessToken && { Authorization: `Bearer ${params.apiAccessToken}` }),
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e={commonBaseURL:"https://api.tomtom.com",apiKey:"",apiVersion:1},t=class{constructor(){this.config={...e}}put(e){this.config={...this.config,...e}}reset(){this.config={...e}}get(){return this.config}};t.instance=new t;let r=t;const o=["carTrain","ferry","tunnel","motorway","pedestrian","toll","tollVignette","country","vehicleRestricted","traffic","carpool","urban","unpaved","lowEmissionZone","speedLimit","roadShields","importantRoadStretch"],n=[...o,"lanes"],a=[...n,"leg"],i=e=>!!e&&(e.length>=4&&e[3]!==e[1]&&e[2]!==e[0]),s=(e,t)=>{if(e&&!(e.length<2))return t?[t[0]>e[0]?e[0]:t[0],t[1]>e[1]?e[1]:t[1],t[2]<e[0]?e[0]:t[2],t[3]<e[1]?e[1]:t[3]]:[e[0],e[1],e[0],e[1]]},p=(e,t)=>t&&e?[t[0]>e[0]?e[0]:t[0],t[1]>e[1]?e[1]:t[1],t[2]<e[2]?e[2]:t[2],t[3]<e[3]?e[3]:t[3]]:e||t,c=e=>e?.length?e.reduce((e,t)=>p(t,e)):void 0,u=e=>{const t=e?.length;if(!t)return;let r;const o=Math.ceil(t/1e3);for(let n=0;n<t;n+=o)r=s(e[n],r);return 1===o?r:s(e[t-1],r)},d=e=>{if(e){if(Array.isArray(e))return"number"==typeof e[0]?e.length>=4?e:void 0:c(e.map(e=>d(e)));if(e.bbox)return e.bbox;switch(e.type){case"Feature":return d(e.geometry);case"FeatureCollection":return c(e.features.map(d));case"GeometryCollection":return c(e.geometries.map(d));case"Point":return s(e.coordinates);case"LineString":case"MultiPoint":return u(e.coordinates);case"MultiLineString":case"Polygon":return c(e.coordinates.map(u));case"MultiPolygon":return c(e.coordinates.flatMap(e=>e.map(u)));default:return}}},l="MapsSDKJS",_=e=>{if(!/^[a-zA-Z0-9-]{1,100}$/.test(e))throw new TypeError(`a string matching regular expression ^[a-zA-Z0-9-]{1,100}$ is expected, but ${e} ['${typeof e}'] given`);return e},y=(e,t)=>{if(e){if(Array.isArray(e))return e;if(e.coordinates)return e.coordinates;if(e.geometry){if("main-when-available"===t?.useEntryPoint){const t=(r=e,r?.properties?.entryPoints?.find(e=>"main"===e.type));return t?.position??e.geometry.coordinates}return e.geometry.coordinates}}var r;return null},h=(e,t)=>{const r=y(e,t);if(!r)throw new Error(`The received object does not have lng-lat coordinates: ${JSON.stringify(e)}`);return r},C=e=>({type:"Feature",geometry:{type:"Point",coordinates:e},properties:{}});const g=e=>e?.minutes??"min",m=1609.344,b=e=>e?.meters??"m",$=e=>e?.kilometers??"km",S=(e,t,r)=>t<3?((e,t,r)=>{const o=Number.parseInt(t.toString()),n=t-o,a=e<0?"-":"";if(n<.125)return`${a}${o} ${r}`;const i=o>0?o:"";return n<.375?`${a}${i}¼ ${r}`:n<.625?`${a}${i}½ ${r}`:n<.875?`${a}${i}¾ ${r}`:`${a}${o+1} ${r}`})(e,t,r):t<10?((e,t,r)=>{const o=Number.parseInt(t.toString()),n=t-o,a=e<0?"-":"";return n<.25?`${a}${o} ${r}`:n<.75?`${a}${o}½ ${r}`:`${a}${o+1} ${r}`})(e,t,r):`${Math.round(e)} ${r}`,x=e=>e.miles??"mi",f=(e,t)=>{const r=e/m,o=Math.abs(r);return o<.125?((e,t)=>{const r=Math.round(e/.3048),o=Math.abs(r);return o<30?`${r} ${t}`:o<500?`${10*Math.round(r/10)} ${t}`:`${100*Math.round(r/100)} ${t}`})(e,t.feet??"ft"):S(r,o,x(t))},T=(e,t)=>{const r=e/m,o=Math.abs(r);return o<.125?((e,t)=>{const r=Math.round(e/.9144);return Math.abs(r)<10?`${Math.round(r)} ${t}`:`${10*Math.round(r/10)} ${t}`})(e,t.yards??"yd"):S(r,o,x(t))};exports.TOMTOM_USER_AGENT_SDK_NAME=l,exports.TomTomConfig=r,exports.asSoftWaypoint=(e,t)=>{let r;return r=Array.isArray(e)||"Feature"!==e.type?C(h(e)):e,{...r,properties:{...r.properties,radiusMeters:t}}},exports.avoidableTypes=["tollRoads","motorways","ferries","unpavedRoads","carpools","alreadyUsedRoads","borderCrossings","tunnels","carTrains","lowEmissionZones"],exports.bboxCenter=e=>[(e[0]+e[2])/2,(e[1]+e[3])/2],exports.bboxExpandedWithBBox=p,exports.bboxExpandedWithGeoJSON=(e,t)=>p(d(e),t),exports.bboxExpandedWithPosition=s,exports.bboxFromBBoxes=c,exports.bboxFromCoordsArray=u,exports.bboxFromGeoJSON=d,exports.bboxOnlyIfWithArea=e=>i(e)?e:void 0,exports.chargingPointCapabilities=["ChargingProfileCapable","ChargingPreferencesCapable","ChipCardSupport","ContactlessCardSupport","CreditCardPayable","DebitCardPayable","PedTerminal","RemoteStartStopCapable","Reservable","RfidReader","StartSessionConnectorRequired","TokenGroupCapable","UnlockCapable","PlugAndCharge","Unknown"],exports.chargingPointRestrictions=["EvOnly","Plugged","Disabled","Customers","Motorcycles"],exports.chargingPointStatus=["Available","Reserved","Occupied","OutOfService","Unknown"],exports.chargingStationAccessTypes=["Public","Authorized","Restricted","Private","Unknown"],exports.connectorTypes=["StandardHouseholdCountrySpecific","IEC62196Type1","IEC62196Type1CCS","IEC62196Type2CableAttached","IEC62196Type2Outlet","IEC62196Type2CCS","IEC62196Type3","Chademo","GBT20234Part2","GBT20234Part3","IEC60309AC3PhaseRed","IEC60309AC1PhaseBlue","IEC60309DCWhite","Tesla"],exports.currentTypes=["AC1","AC3","DC"],exports.defaultConfig=e,exports.formatDistance=(e,t)=>{if(null==e)return"";const o={...r.instance.get().displayUnits?.distance,...t};switch(o?.type??"metric"){case"metric":return((e,t)=>{const r=Math.abs(e);if(r<10)return`${e} ${b(t)}`;if(r<500)return`${10*Math.round(e/10)} ${b(t)}`;if(r<1e3){const r=100*Math.round(e/100);return 1e3===r||-1e3===r?`${e<0?"-":""}1 ${$(t)}`:`${r} ${b(t)}`}return r<1e4?`${100*Math.round(e/100)/1e3} ${$(t)}`:`${Math.round(e/1e3)} ${$(t)}`})(e,o);case"imperial_us":return f(e,o);case"imperial_uk":return T(e,o)}},exports.formatDuration=(e,t)=>{if(e){const n=Math.abs(e)/3600;let a=Math.floor(n),i=Math.round(n%1*60);60===i&&(i=0,a++);const s={...r.instance.get().displayUnits?.time,...t};if(a)return`${a} ${o=s,o?.hours??"hr"} ${i.toString().padStart(2,"0")} ${g(s)}`;if(i)return`${i.toString()} ${g(s)}`}var o},exports.generateId=()=>Date.now().toString(36)+Math.random().toString(36).substring(2),exports.generateTomTomHeaders=e=>({"TomTom-User-Agent":`${l}/0.30.
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e={commonBaseURL:"https://api.tomtom.com",apiKey:"",apiVersion:1},t=class{constructor(){this.config={...e}}put(e){this.config={...this.config,...e}}reset(){this.config={...e}}get(){return this.config}};t.instance=new t;let r=t;const o=["carTrain","ferry","tunnel","motorway","pedestrian","toll","tollVignette","country","vehicleRestricted","traffic","carpool","urban","unpaved","lowEmissionZone","speedLimit","roadShields","importantRoadStretch"],n=[...o,"lanes"],a=[...n,"leg"],i=e=>!!e&&(e.length>=4&&e[3]!==e[1]&&e[2]!==e[0]),s=(e,t)=>{if(e&&!(e.length<2))return t?[t[0]>e[0]?e[0]:t[0],t[1]>e[1]?e[1]:t[1],t[2]<e[0]?e[0]:t[2],t[3]<e[1]?e[1]:t[3]]:[e[0],e[1],e[0],e[1]]},p=(e,t)=>t&&e?[t[0]>e[0]?e[0]:t[0],t[1]>e[1]?e[1]:t[1],t[2]<e[2]?e[2]:t[2],t[3]<e[3]?e[3]:t[3]]:e||t,c=e=>e?.length?e.reduce((e,t)=>p(t,e)):void 0,u=e=>{const t=e?.length;if(!t)return;let r;const o=Math.ceil(t/1e3);for(let n=0;n<t;n+=o)r=s(e[n],r);return 1===o?r:s(e[t-1],r)},d=e=>{if(e){if(Array.isArray(e))return"number"==typeof e[0]?e.length>=4?e:void 0:c(e.map(e=>d(e)));if(e.bbox)return e.bbox;switch(e.type){case"Feature":return d(e.geometry);case"FeatureCollection":return c(e.features.map(d));case"GeometryCollection":return c(e.geometries.map(d));case"Point":return s(e.coordinates);case"LineString":case"MultiPoint":return u(e.coordinates);case"MultiLineString":case"Polygon":return c(e.coordinates.map(u));case"MultiPolygon":return c(e.coordinates.flatMap(e=>e.map(u)));default:return}}},l="MapsSDKJS",_=e=>{if(!/^[a-zA-Z0-9-]{1,100}$/.test(e))throw new TypeError(`a string matching regular expression ^[a-zA-Z0-9-]{1,100}$ is expected, but ${e} ['${typeof e}'] given`);return e},y=(e,t)=>{if(e){if(Array.isArray(e))return e;if(e.coordinates)return e.coordinates;if(e.geometry){if("main-when-available"===t?.useEntryPoint){const t=(r=e,r?.properties?.entryPoints?.find(e=>"main"===e.type));return t?.position??e.geometry.coordinates}return e.geometry.coordinates}}var r;return null},h=(e,t)=>{const r=y(e,t);if(!r)throw new Error(`The received object does not have lng-lat coordinates: ${JSON.stringify(e)}`);return r},C=e=>({type:"Feature",geometry:{type:"Point",coordinates:e},properties:{}});const g=e=>e?.minutes??"min",m=1609.344,b=e=>e?.meters??"m",$=e=>e?.kilometers??"km",S=(e,t,r)=>t<3?((e,t,r)=>{const o=Number.parseInt(t.toString()),n=t-o,a=e<0?"-":"";if(n<.125)return`${a}${o} ${r}`;const i=o>0?o:"";return n<.375?`${a}${i}¼ ${r}`:n<.625?`${a}${i}½ ${r}`:n<.875?`${a}${i}¾ ${r}`:`${a}${o+1} ${r}`})(e,t,r):t<10?((e,t,r)=>{const o=Number.parseInt(t.toString()),n=t-o,a=e<0?"-":"";return n<.25?`${a}${o} ${r}`:n<.75?`${a}${o}½ ${r}`:`${a}${o+1} ${r}`})(e,t,r):`${Math.round(e)} ${r}`,x=e=>e.miles??"mi",f=(e,t)=>{const r=e/m,o=Math.abs(r);return o<.125?((e,t)=>{const r=Math.round(e/.3048),o=Math.abs(r);return o<30?`${r} ${t}`:o<500?`${10*Math.round(r/10)} ${t}`:`${100*Math.round(r/100)} ${t}`})(e,t.feet??"ft"):S(r,o,x(t))},T=(e,t)=>{const r=e/m,o=Math.abs(r);return o<.125?((e,t)=>{const r=Math.round(e/.9144);return Math.abs(r)<10?`${Math.round(r)} ${t}`:`${10*Math.round(r/10)} ${t}`})(e,t.yards??"yd"):S(r,o,x(t))};exports.TOMTOM_USER_AGENT_SDK_NAME=l,exports.TomTomConfig=r,exports.asSoftWaypoint=(e,t)=>{let r;return r=Array.isArray(e)||"Feature"!==e.type?C(h(e)):e,{...r,properties:{...r.properties,radiusMeters:t}}},exports.avoidableTypes=["tollRoads","motorways","ferries","unpavedRoads","carpools","alreadyUsedRoads","borderCrossings","tunnels","carTrains","lowEmissionZones"],exports.bboxCenter=e=>[(e[0]+e[2])/2,(e[1]+e[3])/2],exports.bboxExpandedWithBBox=p,exports.bboxExpandedWithGeoJSON=(e,t)=>p(d(e),t),exports.bboxExpandedWithPosition=s,exports.bboxFromBBoxes=c,exports.bboxFromCoordsArray=u,exports.bboxFromGeoJSON=d,exports.bboxOnlyIfWithArea=e=>i(e)?e:void 0,exports.chargingPointCapabilities=["ChargingProfileCapable","ChargingPreferencesCapable","ChipCardSupport","ContactlessCardSupport","CreditCardPayable","DebitCardPayable","PedTerminal","RemoteStartStopCapable","Reservable","RfidReader","StartSessionConnectorRequired","TokenGroupCapable","UnlockCapable","PlugAndCharge","Unknown"],exports.chargingPointRestrictions=["EvOnly","Plugged","Disabled","Customers","Motorcycles"],exports.chargingPointStatus=["Available","Reserved","Occupied","OutOfService","Unknown"],exports.chargingStationAccessTypes=["Public","Authorized","Restricted","Private","Unknown"],exports.connectorTypes=["StandardHouseholdCountrySpecific","IEC62196Type1","IEC62196Type1CCS","IEC62196Type2CableAttached","IEC62196Type2Outlet","IEC62196Type2CCS","IEC62196Type3","Chademo","GBT20234Part2","GBT20234Part3","IEC60309AC3PhaseRed","IEC60309AC1PhaseBlue","IEC60309DCWhite","Tesla"],exports.currentTypes=["AC1","AC3","DC"],exports.defaultConfig=e,exports.formatDistance=(e,t)=>{if(null==e)return"";const o={...r.instance.get().displayUnits?.distance,...t};switch(o?.type??"metric"){case"metric":return((e,t)=>{const r=Math.abs(e);if(r<10)return`${e} ${b(t)}`;if(r<500)return`${10*Math.round(e/10)} ${b(t)}`;if(r<1e3){const r=100*Math.round(e/100);return 1e3===r||-1e3===r?`${e<0?"-":""}1 ${$(t)}`:`${r} ${b(t)}`}return r<1e4?`${100*Math.round(e/100)/1e3} ${$(t)}`:`${Math.round(e/1e3)} ${$(t)}`})(e,o);case"imperial_us":return f(e,o);case"imperial_uk":return T(e,o)}},exports.formatDuration=(e,t)=>{if(e){const n=Math.abs(e)/3600;let a=Math.floor(n),i=Math.round(n%1*60);60===i&&(i=0,a++);const s={...r.instance.get().displayUnits?.time,...t};if(a)return`${a} ${o=s,o?.hours??"hr"} ${i.toString().padStart(2,"0")} ${g(s)}`;if(i)return`${i.toString()} ${g(s)}`}var o},exports.generateId=()=>Date.now().toString(36)+Math.random().toString(36).substring(2),exports.generateTomTomHeaders=e=>({"TomTom-User-Agent":`${l}/0.30.2`,...e.trackingId&&{"Tracking-ID":_(e.trackingId)}}),exports.geographyTypes=["Country","CountrySubdivision","CountrySecondarySubdivision","CountryTertiarySubdivision","Municipality","MunicipalitySubdivision","Neighbourhood","PostalCodeArea"],exports.getPosition=y,exports.getPositionStrict=h,exports.getRoutePlanningLocationType=e=>Array.isArray(e)?Array.isArray(e[0])?"path":"waypoint":"Feature"===e.type&&"LineString"===e.geometry.type?"path":"waypoint",exports.indexedMagnitudes=["unknown","minor","moderate","major","indefinite"],exports.inputSectionTypes=o,exports.inputSectionTypesWithGuidance=n,exports.isBBoxWithArea=i,exports.mergeFromGlobal=(e={})=>({...r.instance.get(),...e}),exports.paymentMethods=["No_Payment","Subscription","Direct"],exports.placeTypes=["POI","Street","Geography","Point Address","Address Range","Cross Street"],exports.plugTypes=["Small_Paddle_Inductive","Large_Paddle_Inductive","IEC_60309_1_Phase","IEC_60309_3_Phase","IEC_62196_Type_1_Outlet","IEC_62196_Type_2_Outlet","IEC_62196_Type_3_Outlet","IEC_62196_Type_1_Connector_Cable_Attached","IEC_62196_Type_2_Connector_Cable_Attached","IEC_62196_Type_3_Connector_Cable_Attached","Combo_to_IEC_62196_Type_1_Base","Combo_to_IEC_62196_Type_2_Base","Type_E_French_Standard_CEE_7_5","Type_F_Schuko_CEE_7_4","Type_G_British_Standard_BS_1363","Type_J_Swiss_Standard_SEV_1011","China_GB_Part_2","China_GB_Part_3","IEC_309_DC_Plug","AVCON_Connector","Tesla_Connector","NEMA_5_20","CHAdeMO","SAE_J1772","TEPCO","Better_Place_Socket","Marechal_Socket","Standard_Household_Country_Specific"],exports.sectionTypes=a,exports.toPointFeature=C,exports.views=["Unified","AR","IN","PK","IL","MA","RU","TR","CN"];
|
|
2
2
|
//# sourceMappingURL=core.cjs.min.js.map
|
package/core/dist/core.es.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const e={commonBaseURL:"https://api.tomtom.com",apiKey:"",apiVersion:1},t=class{constructor(){this.config={...e}}put(e){this.config={...this.config,...e}}reset(){this.config={...e}}get(){return this.config}};t.instance=new t;let r=t;const n=(e={})=>({...r.instance.get(),...e}),a=["Public","Authorized","Restricted","Private","Unknown"],o=["Available","Reserved","Occupied","OutOfService","Unknown"],i=["ChargingProfileCapable","ChargingPreferencesCapable","ChipCardSupport","ContactlessCardSupport","CreditCardPayable","DebitCardPayable","PedTerminal","RemoteStartStopCapable","Reservable","RfidReader","StartSessionConnectorRequired","TokenGroupCapable","UnlockCapable","PlugAndCharge","Unknown"],s=["EvOnly","Plugged","Disabled","Customers","Motorcycles"],u=["StandardHouseholdCountrySpecific","IEC62196Type1","IEC62196Type1CCS","IEC62196Type2CableAttached","IEC62196Type2Outlet","IEC62196Type2CCS","IEC62196Type3","Chademo","GBT20234Part2","GBT20234Part3","IEC60309AC3PhaseRed","IEC60309AC1PhaseBlue","IEC60309DCWhite","Tesla"],c=["AC1","AC3","DC"],d=["Country","CountrySubdivision","CountrySecondarySubdivision","CountryTertiarySubdivision","Municipality","MunicipalitySubdivision","Neighbourhood","PostalCodeArea"],l=["POI","Street","Geography","Point Address","Address Range","Cross Street"],_=["Small_Paddle_Inductive","Large_Paddle_Inductive","IEC_60309_1_Phase","IEC_60309_3_Phase","IEC_62196_Type_1_Outlet","IEC_62196_Type_2_Outlet","IEC_62196_Type_3_Outlet","IEC_62196_Type_1_Connector_Cable_Attached","IEC_62196_Type_2_Connector_Cable_Attached","IEC_62196_Type_3_Connector_Cable_Attached","Combo_to_IEC_62196_Type_1_Base","Combo_to_IEC_62196_Type_2_Base","Type_E_French_Standard_CEE_7_5","Type_F_Schuko_CEE_7_4","Type_G_British_Standard_BS_1363","Type_J_Swiss_Standard_SEV_1011","China_GB_Part_2","China_GB_Part_3","IEC_309_DC_Plug","AVCON_Connector","Tesla_Connector","NEMA_5_20","CHAdeMO","SAE_J1772","TEPCO","Better_Place_Socket","Marechal_Socket","Standard_Household_Country_Specific"],p=["No_Payment","Subscription","Direct"],y=["tollRoads","motorways","ferries","unpavedRoads","carpools","alreadyUsedRoads","borderCrossings","tunnels","carTrains","lowEmissionZones"],C=["carTrain","ferry","tunnel","motorway","pedestrian","toll","tollVignette","country","vehicleRestricted","traffic","carpool","urban","unpaved","lowEmissionZone","speedLimit","roadShields","importantRoadStretch"],h=[...C,"lanes"],$=[...h,"leg"],g=["Unified","AR","IN","PK","IL","MA","RU","TR","CN"],m=e=>!!e&&(e.length>=4&&e[3]!==e[1]&&e[2]!==e[0]),f=e=>m(e)?e:void 0,S=(e,t)=>{if(e&&!(e.length<2))return t?[t[0]>e[0]?e[0]:t[0],t[1]>e[1]?e[1]:t[1],t[2]<e[0]?e[0]:t[2],t[3]<e[1]?e[1]:t[3]]:[e[0],e[1],e[0],e[1]]},b=(e,t)=>t&&e?[t[0]>e[0]?e[0]:t[0],t[1]>e[1]?e[1]:t[1],t[2]<e[2]?e[2]:t[2],t[3]<e[3]?e[3]:t[3]]:e||t,E=e=>e?.length?e.reduce((e,t)=>b(t,e)):void 0,M=e=>{const t=e?.length;if(!t)return;let r;const n=Math.ceil(t/1e3);for(let a=0;a<t;a+=n)r=S(e[a],r);return 1===n?r:S(e[t-1],r)},P=e=>{if(e){if(Array.isArray(e))return"number"==typeof e[0]?e.length>=4?e:void 0:E(e.map(e=>P(e)));if(e.bbox)return e.bbox;switch(e.type){case"Feature":return P(e.geometry);case"FeatureCollection":return E(e.features.map(P));case"GeometryCollection":return E(e.geometries.map(P));case"Point":return S(e.coordinates);case"LineString":case"MultiPoint":return M(e.coordinates);case"MultiLineString":case"Polygon":return E(e.coordinates.map(M));case"MultiPolygon":return E(e.coordinates.flatMap(e=>e.map(M)));default:return}}},T=(e,t)=>b(P(e),t),A=e=>[(e[0]+e[2])/2,(e[1]+e[3])/2],I=()=>Date.now().toString(36)+Math.random().toString(36).substring(2),v="MapsSDKJS",w=e=>{if(!/^[a-zA-Z0-9-]{1,100}$/.test(e))throw new TypeError(`a string matching regular expression ^[a-zA-Z0-9-]{1,100}$ is expected, but ${e} ['${typeof e}'] given`);return e},R=e=>({"TomTom-User-Agent":`${v}/0.30.
|
|
1
|
+
const e={commonBaseURL:"https://api.tomtom.com",apiKey:"",apiVersion:1},t=class{constructor(){this.config={...e}}put(e){this.config={...this.config,...e}}reset(){this.config={...e}}get(){return this.config}};t.instance=new t;let r=t;const n=(e={})=>({...r.instance.get(),...e}),a=["Public","Authorized","Restricted","Private","Unknown"],o=["Available","Reserved","Occupied","OutOfService","Unknown"],i=["ChargingProfileCapable","ChargingPreferencesCapable","ChipCardSupport","ContactlessCardSupport","CreditCardPayable","DebitCardPayable","PedTerminal","RemoteStartStopCapable","Reservable","RfidReader","StartSessionConnectorRequired","TokenGroupCapable","UnlockCapable","PlugAndCharge","Unknown"],s=["EvOnly","Plugged","Disabled","Customers","Motorcycles"],u=["StandardHouseholdCountrySpecific","IEC62196Type1","IEC62196Type1CCS","IEC62196Type2CableAttached","IEC62196Type2Outlet","IEC62196Type2CCS","IEC62196Type3","Chademo","GBT20234Part2","GBT20234Part3","IEC60309AC3PhaseRed","IEC60309AC1PhaseBlue","IEC60309DCWhite","Tesla"],c=["AC1","AC3","DC"],d=["Country","CountrySubdivision","CountrySecondarySubdivision","CountryTertiarySubdivision","Municipality","MunicipalitySubdivision","Neighbourhood","PostalCodeArea"],l=["POI","Street","Geography","Point Address","Address Range","Cross Street"],_=["Small_Paddle_Inductive","Large_Paddle_Inductive","IEC_60309_1_Phase","IEC_60309_3_Phase","IEC_62196_Type_1_Outlet","IEC_62196_Type_2_Outlet","IEC_62196_Type_3_Outlet","IEC_62196_Type_1_Connector_Cable_Attached","IEC_62196_Type_2_Connector_Cable_Attached","IEC_62196_Type_3_Connector_Cable_Attached","Combo_to_IEC_62196_Type_1_Base","Combo_to_IEC_62196_Type_2_Base","Type_E_French_Standard_CEE_7_5","Type_F_Schuko_CEE_7_4","Type_G_British_Standard_BS_1363","Type_J_Swiss_Standard_SEV_1011","China_GB_Part_2","China_GB_Part_3","IEC_309_DC_Plug","AVCON_Connector","Tesla_Connector","NEMA_5_20","CHAdeMO","SAE_J1772","TEPCO","Better_Place_Socket","Marechal_Socket","Standard_Household_Country_Specific"],p=["No_Payment","Subscription","Direct"],y=["tollRoads","motorways","ferries","unpavedRoads","carpools","alreadyUsedRoads","borderCrossings","tunnels","carTrains","lowEmissionZones"],C=["carTrain","ferry","tunnel","motorway","pedestrian","toll","tollVignette","country","vehicleRestricted","traffic","carpool","urban","unpaved","lowEmissionZone","speedLimit","roadShields","importantRoadStretch"],h=[...C,"lanes"],$=[...h,"leg"],g=["Unified","AR","IN","PK","IL","MA","RU","TR","CN"],m=e=>!!e&&(e.length>=4&&e[3]!==e[1]&&e[2]!==e[0]),f=e=>m(e)?e:void 0,S=(e,t)=>{if(e&&!(e.length<2))return t?[t[0]>e[0]?e[0]:t[0],t[1]>e[1]?e[1]:t[1],t[2]<e[0]?e[0]:t[2],t[3]<e[1]?e[1]:t[3]]:[e[0],e[1],e[0],e[1]]},b=(e,t)=>t&&e?[t[0]>e[0]?e[0]:t[0],t[1]>e[1]?e[1]:t[1],t[2]<e[2]?e[2]:t[2],t[3]<e[3]?e[3]:t[3]]:e||t,E=e=>e?.length?e.reduce((e,t)=>b(t,e)):void 0,M=e=>{const t=e?.length;if(!t)return;let r;const n=Math.ceil(t/1e3);for(let a=0;a<t;a+=n)r=S(e[a],r);return 1===n?r:S(e[t-1],r)},P=e=>{if(e){if(Array.isArray(e))return"number"==typeof e[0]?e.length>=4?e:void 0:E(e.map(e=>P(e)));if(e.bbox)return e.bbox;switch(e.type){case"Feature":return P(e.geometry);case"FeatureCollection":return E(e.features.map(P));case"GeometryCollection":return E(e.geometries.map(P));case"Point":return S(e.coordinates);case"LineString":case"MultiPoint":return M(e.coordinates);case"MultiLineString":case"Polygon":return E(e.coordinates.map(M));case"MultiPolygon":return E(e.coordinates.flatMap(e=>e.map(M)));default:return}}},T=(e,t)=>b(P(e),t),A=e=>[(e[0]+e[2])/2,(e[1]+e[3])/2],I=()=>Date.now().toString(36)+Math.random().toString(36).substring(2),v="MapsSDKJS",w=e=>{if(!/^[a-zA-Z0-9-]{1,100}$/.test(e))throw new TypeError(`a string matching regular expression ^[a-zA-Z0-9-]{1,100}$ is expected, but ${e} ['${typeof e}'] given`);return e},R=e=>({"TomTom-User-Agent":`${v}/0.30.2`,...e.trackingId&&{"Tracking-ID":w(e.trackingId)}}),k=(e,t)=>{if(e){if(Array.isArray(e))return e;if(e.coordinates)return e.coordinates;if(e.geometry){if("main-when-available"===t?.useEntryPoint){const t=(r=e,r?.properties?.entryPoints?.find(e=>"main"===e.type));return t?.position??e.geometry.coordinates}return e.geometry.coordinates}}var r;return null},O=(e,t)=>{const r=k(e,t);if(!r)throw new Error(`The received object does not have lng-lat coordinates: ${JSON.stringify(e)}`);return r},B=e=>({type:"Feature",geometry:{type:"Point",coordinates:e},properties:{}}),U=(e,t)=>{let r;return r=Array.isArray(e)||"Feature"!==e.type?B(O(e)):e,{...r,properties:{...r.properties,radiusMeters:t}}},D=e=>Array.isArray(e)?Array.isArray(e[0])?"path":"waypoint":"Feature"===e.type&&"LineString"===e.geometry.type?"path":"waypoint",N=["unknown","minor","moderate","major","indefinite"];const G=e=>e?.minutes??"min",F=(e,t)=>{if(e){const a=Math.abs(e)/3600;let o=Math.floor(a),i=Math.round(a%1*60);60===i&&(i=0,o++);const s={...r.instance.get().displayUnits?.time,...t};if(o)return`${o} ${n=s,n?.hours??"hr"} ${i.toString().padStart(2,"0")} ${G(s)}`;if(i)return`${i.toString()} ${G(s)}`}var n},L=1609.344,x=e=>e?.meters??"m",J=e=>e?.kilometers??"km",V=(e,t,r)=>t<3?((e,t,r)=>{const n=Number.parseInt(t.toString()),a=t-n,o=e<0?"-":"";if(a<.125)return`${o}${n} ${r}`;const i=n>0?n:"";return a<.375?`${o}${i}¼ ${r}`:a<.625?`${o}${i}½ ${r}`:a<.875?`${o}${i}¾ ${r}`:`${o}${n+1} ${r}`})(e,t,r):t<10?((e,t,r)=>{const n=Number.parseInt(t.toString()),a=t-n,o=e<0?"-":"";return a<.25?`${o}${n} ${r}`:a<.75?`${o}${n}½ ${r}`:`${o}${n+1} ${r}`})(e,t,r):`${Math.round(e)} ${r}`,Z=e=>e.miles??"mi",z=(e,t)=>{const r=e/L,n=Math.abs(r);return n<.125?((e,t)=>{const r=Math.round(e/.3048),n=Math.abs(r);return n<30?`${r} ${t}`:n<500?`${10*Math.round(r/10)} ${t}`:`${100*Math.round(r/100)} ${t}`})(e,t.feet??"ft"):V(r,n,Z(t))},H=(e,t)=>{const r=e/L,n=Math.abs(r);return n<.125?((e,t)=>{const r=Math.round(e/.9144);return Math.abs(r)<10?`${Math.round(r)} ${t}`:`${10*Math.round(r/10)} ${t}`})(e,t.yards??"yd"):V(r,n,Z(t))},K=(e,t)=>{if(null==e)return"";const n={...r.instance.get().displayUnits?.distance,...t};switch(n?.type??"metric"){case"metric":return((e,t)=>{const r=Math.abs(e);if(r<10)return`${e} ${x(t)}`;if(r<500)return`${10*Math.round(e/10)} ${x(t)}`;if(r<1e3){const r=100*Math.round(e/100);return 1e3===r||-1e3===r?`${e<0?"-":""}1 ${J(t)}`:`${r} ${x(t)}`}return r<1e4?`${100*Math.round(e/100)/1e3} ${J(t)}`:`${Math.round(e/1e3)} ${J(t)}`})(e,n);case"imperial_us":return z(e,n);case"imperial_uk":return H(e,n)}};export{v as TOMTOM_USER_AGENT_SDK_NAME,r as TomTomConfig,U as asSoftWaypoint,y as avoidableTypes,A as bboxCenter,b as bboxExpandedWithBBox,T as bboxExpandedWithGeoJSON,S as bboxExpandedWithPosition,E as bboxFromBBoxes,M as bboxFromCoordsArray,P as bboxFromGeoJSON,f as bboxOnlyIfWithArea,i as chargingPointCapabilities,s as chargingPointRestrictions,o as chargingPointStatus,a as chargingStationAccessTypes,u as connectorTypes,c as currentTypes,e as defaultConfig,K as formatDistance,F as formatDuration,I as generateId,R as generateTomTomHeaders,d as geographyTypes,k as getPosition,O as getPositionStrict,D as getRoutePlanningLocationType,N as indexedMagnitudes,C as inputSectionTypes,h as inputSectionTypesWithGuidance,m as isBBoxWithArea,n as mergeFromGlobal,p as paymentMethods,l as placeTypes,_ as plugTypes,$ as sectionTypes,B as toPointFeature,g as views};
|
|
2
2
|
//# sourceMappingURL=core.es.js.map
|
package/map/dist/THIRD_PARTY.txt
CHANGED
package/map/dist/index.d.ts
CHANGED
|
@@ -939,24 +939,8 @@ declare type BaseSourceAndLayers = {
|
|
|
939
939
|
};
|
|
940
940
|
|
|
941
941
|
/**
|
|
942
|
-
* Builds the
|
|
943
|
-
*
|
|
944
|
-
* @remarks
|
|
945
|
-
* Determines the appropriate title to display on the map by prioritizing
|
|
946
|
-
* POI name over the freeform address. This ensures that named locations
|
|
947
|
-
* (e.g., "Starbucks", "Central Park") are shown with their recognizable names
|
|
948
|
-
* while regular addresses use their street address.
|
|
949
|
-
*
|
|
950
|
-
* @param place - The place feature to extract the title from
|
|
951
|
-
* @returns The display title, either the POI name or freeform address
|
|
952
|
-
*
|
|
953
|
-
* @example
|
|
954
|
-
* ```ts
|
|
955
|
-
* const place = { properties: { poi: { name: "Eiffel Tower" }, address: { freeformAddress: "..." } } };
|
|
956
|
-
* const title = buildPlaceTitle(place); // Returns "Eiffel Tower"
|
|
957
|
-
* ```
|
|
958
|
-
*
|
|
959
|
-
* @group Places
|
|
942
|
+
* Builds the title of the place to display it on the map.
|
|
943
|
+
* @param place The place to display.
|
|
960
944
|
*/
|
|
961
945
|
export declare const buildPlaceTitle: (place: Place_2) => string;
|
|
962
946
|
|
|
@@ -3053,29 +3037,10 @@ export declare type GeometryTextConfig = {
|
|
|
3053
3037
|
};
|
|
3054
3038
|
|
|
3055
3039
|
/**
|
|
3056
|
-
*
|
|
3057
|
-
*
|
|
3058
|
-
* @
|
|
3059
|
-
*
|
|
3060
|
-
* 1. Custom icons matching the place's classification code
|
|
3061
|
-
* 2. Pin-style icons based on category IDs
|
|
3062
|
-
* 3. POI-style icons based on classification codes
|
|
3063
|
-
* 4. Default fallback pin icon
|
|
3064
|
-
*
|
|
3065
|
-
* The icon style is determined by the configuration, supporting both 'pin' and 'poi-like' styles.
|
|
3066
|
-
*
|
|
3067
|
-
* @param place - The place feature to determine the icon for
|
|
3068
|
-
* @param config - Optional configuration for icon style and custom icons
|
|
3069
|
-
* @param map - Optional map instance (reserved for future use)
|
|
3070
|
-
* @returns The sprite image ID to use for rendering the place icon
|
|
3071
|
-
*
|
|
3072
|
-
* @example
|
|
3073
|
-
* ```ts
|
|
3074
|
-
* const iconId = getIconIDForPlace(place, {
|
|
3075
|
-
* iconConfig: { iconStyle: 'pin', customIcons: [...] }
|
|
3076
|
-
* }, map);
|
|
3077
|
-
* ```
|
|
3078
|
-
* @group Places
|
|
3040
|
+
* Gets the map style sprite image ID to display on the map for the give place.
|
|
3041
|
+
* @param place The place to display.
|
|
3042
|
+
* @param map
|
|
3043
|
+
* @param config
|
|
3079
3044
|
*/
|
|
3080
3045
|
export declare const getIconIDForPlace: (place: Place_2, config?: PlacesModuleConfig, map?: Map_2) => string;
|
|
3081
3046
|
|
package/map/dist/map.cjs.js
CHANGED
|
@@ -2911,6 +2911,60 @@ const buildPlacesLayerSpecs = (config, idPrefix, map) => {
|
|
|
2911
2911
|
(spec, index) => withConfig(spec, config, `${idPrefix}-${index === 0 ? "main" : "selected"}`)
|
|
2912
2912
|
);
|
|
2913
2913
|
};
|
|
2914
|
+
const supportedPinSubcategories = /* @__PURE__ */ new Set([
|
|
2915
|
+
7339002,
|
|
2916
|
+
8099002,
|
|
2917
|
+
7369004,
|
|
2918
|
+
7321003,
|
|
2919
|
+
7376006,
|
|
2920
|
+
9362003,
|
|
2921
|
+
9362004,
|
|
2922
|
+
9160004,
|
|
2923
|
+
9376007,
|
|
2924
|
+
7315015,
|
|
2925
|
+
9376006,
|
|
2926
|
+
9376002,
|
|
2927
|
+
7315078,
|
|
2928
|
+
7315149,
|
|
2929
|
+
9376005,
|
|
2930
|
+
7372003,
|
|
2931
|
+
9352045,
|
|
2932
|
+
9352032,
|
|
2933
|
+
9361048,
|
|
2934
|
+
9902003,
|
|
2935
|
+
9378005,
|
|
2936
|
+
7383004,
|
|
2937
|
+
9910004,
|
|
2938
|
+
7320002,
|
|
2939
|
+
9362016,
|
|
2940
|
+
7320003,
|
|
2941
|
+
9362025,
|
|
2942
|
+
9942002,
|
|
2943
|
+
9942003,
|
|
2944
|
+
7380005,
|
|
2945
|
+
9663003,
|
|
2946
|
+
9361021,
|
|
2947
|
+
9379009,
|
|
2948
|
+
9379004,
|
|
2949
|
+
7315147,
|
|
2950
|
+
9376003,
|
|
2951
|
+
9160002,
|
|
2952
|
+
9160003,
|
|
2953
|
+
9352008,
|
|
2954
|
+
9361006,
|
|
2955
|
+
7389004,
|
|
2956
|
+
9910006
|
|
2957
|
+
]);
|
|
2958
|
+
const toMapDisplayPin = (place) => {
|
|
2959
|
+
const categoryID = place.properties.poi?.categoryIds?.[0];
|
|
2960
|
+
if (!categoryID) {
|
|
2961
|
+
return "default_pin";
|
|
2962
|
+
}
|
|
2963
|
+
if (supportedPinSubcategories.has(categoryID)) {
|
|
2964
|
+
return categoryID.toString();
|
|
2965
|
+
}
|
|
2966
|
+
return categoryID.toString().substring(0, 4);
|
|
2967
|
+
};
|
|
2914
2968
|
const buildPlaceTitle = (place) => place.properties.poi?.name ?? place.properties.address.freeformAddress;
|
|
2915
2969
|
const getIconIDForPlace = (place, config = {}, map) => {
|
|
2916
2970
|
const iconStyle = config.iconConfig?.iconStyle ?? "pin";
|
|
@@ -2922,8 +2976,7 @@ const getIconIDForPlace = (place, config = {}, map) => {
|
|
|
2922
2976
|
}
|
|
2923
2977
|
let iconId;
|
|
2924
2978
|
if (iconStyle === "pin") {
|
|
2925
|
-
|
|
2926
|
-
iconId = categoryID ? String(categoryID) : "default_pin";
|
|
2979
|
+
iconId = toMapDisplayPin(place);
|
|
2927
2980
|
} else {
|
|
2928
2981
|
iconId = (classificationCode && `poi-${toMapDisplayPOICategory(classificationCode)}`) ?? "default_pin";
|
|
2929
2982
|
}
|