@colisweb/rescript-toolkit 5.43.2 → 5.43.3
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/package.json +1 -1
- package/src/vendors/Here.res +20 -10
package/package.json
CHANGED
package/src/vendors/Here.res
CHANGED
|
@@ -2,6 +2,7 @@ type coordinates = {
|
|
|
2
2
|
lat: float,
|
|
3
3
|
lng: float,
|
|
4
4
|
}
|
|
5
|
+
type mapObject
|
|
5
6
|
|
|
6
7
|
module Geo = {
|
|
7
8
|
module Point = {
|
|
@@ -117,7 +118,6 @@ module Platform = {
|
|
|
117
118
|
|
|
118
119
|
module Map = {
|
|
119
120
|
type instance
|
|
120
|
-
type object
|
|
121
121
|
type objectLayer
|
|
122
122
|
type padding = {top?: int, left?: int, bottom?: int, right?: int}
|
|
123
123
|
|
|
@@ -131,6 +131,16 @@ module Map = {
|
|
|
131
131
|
@new
|
|
132
132
|
external make: (Dom.element, Layers.map, options) => instance = "H.Map"
|
|
133
133
|
|
|
134
|
+
@send
|
|
135
|
+
external addObject: (instance, mapObject) => unit = "addObject"
|
|
136
|
+
@send
|
|
137
|
+
external addObjects: (instance, array<mapObject>) => unit = "addObject"
|
|
138
|
+
|
|
139
|
+
@send
|
|
140
|
+
external removeObject: (instance, mapObject) => unit = "removeObject"
|
|
141
|
+
@send
|
|
142
|
+
external removeObjects: (instance, array<mapObject>) => unit = "removeObjects"
|
|
143
|
+
|
|
134
144
|
@val
|
|
135
145
|
external engineType: Js.Dict.t<string> = "H.Map.EngineType"
|
|
136
146
|
|
|
@@ -173,7 +183,7 @@ module Map = {
|
|
|
173
183
|
@send
|
|
174
184
|
external addEventListener: (t, string, Event.t<'a> => unit) => unit = "addEventListener"
|
|
175
185
|
|
|
176
|
-
external toObject: t =>
|
|
186
|
+
external toObject: t => mapObject = "%identity"
|
|
177
187
|
}
|
|
178
188
|
module DomMarker = {
|
|
179
189
|
type t
|
|
@@ -190,7 +200,7 @@ module Map = {
|
|
|
190
200
|
@send
|
|
191
201
|
external addEventListener: (t, string, Event.t<'a> => unit) => unit = "addEventListener"
|
|
192
202
|
|
|
193
|
-
external toObject: t =>
|
|
203
|
+
external toObject: t => mapObject = "%identity"
|
|
194
204
|
}
|
|
195
205
|
|
|
196
206
|
module Viewport = {
|
|
@@ -225,7 +235,7 @@ module Map = {
|
|
|
225
235
|
@new
|
|
226
236
|
external make: unit => t = "H.map.Group"
|
|
227
237
|
|
|
228
|
-
type makeOptions = {objects: array<
|
|
238
|
+
type makeOptions = {objects: array<mapObject>}
|
|
229
239
|
@new
|
|
230
240
|
external makeFromObjects: makeOptions => t = "H.map.Group"
|
|
231
241
|
|
|
@@ -241,11 +251,11 @@ module Map = {
|
|
|
241
251
|
@send
|
|
242
252
|
external removeAll: (t, unit) => unit = "removeAll"
|
|
243
253
|
@send
|
|
244
|
-
external removeObject: (t,
|
|
254
|
+
external removeObject: (t, mapObject) => unit = "removeObject"
|
|
245
255
|
@send
|
|
246
|
-
external removeObjects: (t, array<
|
|
256
|
+
external removeObjects: (t, array<mapObject>) => unit = "removeObjects"
|
|
247
257
|
|
|
248
|
-
external toObject: t =>
|
|
258
|
+
external toObject: t => mapObject = "%identity"
|
|
249
259
|
}
|
|
250
260
|
module Polyline = {
|
|
251
261
|
type t
|
|
@@ -270,7 +280,7 @@ module Map = {
|
|
|
270
280
|
and style = {fillColor?: string}
|
|
271
281
|
@new
|
|
272
282
|
external make: (Geo.Point.t, int, options) => t = "H.map.Circle"
|
|
273
|
-
external toObject: t =>
|
|
283
|
+
external toObject: t => mapObject = "%identity"
|
|
274
284
|
|
|
275
285
|
type dataOptions = {maxZoom?: int}
|
|
276
286
|
|
|
@@ -283,7 +293,7 @@ module Map = {
|
|
|
283
293
|
@send
|
|
284
294
|
external addGroup: (instance, Group.t) => unit = "addObject"
|
|
285
295
|
@send
|
|
286
|
-
external addObject: (instance,
|
|
296
|
+
external addObject: (instance, mapObject) => unit = "addObject"
|
|
287
297
|
@send
|
|
288
298
|
external addPolyline: (instance, Polyline.t) => unit = "addObject"
|
|
289
299
|
|
|
@@ -297,7 +307,7 @@ module Map = {
|
|
|
297
307
|
external setZoom: (instance, int) => unit = "setZoom"
|
|
298
308
|
|
|
299
309
|
@send
|
|
300
|
-
external getObjects: (instance, unit) => array<
|
|
310
|
+
external getObjects: (instance, unit) => array<mapObject> = "getObjects"
|
|
301
311
|
@send
|
|
302
312
|
external getViewPort: (instance, unit) => Viewport.t = "getViewPort"
|
|
303
313
|
@send
|