@minmaps-dev/mm-web-sdk 1.0.0-rc.34 → 1.0.0-rc.35

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/dist/react.d.ts CHANGED
@@ -17,12 +17,17 @@ interface POI {
17
17
  floorId: string | number;
18
18
  /** Category/type of amenity (e.g., 'restroom', 'elevator') */
19
19
  amenityType?: string;
20
+ /** Locale-stable classification text (name + type + keywords, frozen at
21
+ * load before any locale patch can translate them). Copied from the
22
+ * source `Amenity.classifyText`; used by `amenityCategoryFor`/rank
23
+ * instead of the live, possibly-translated fields. See `Amenity.classifyText`. */
24
+ classifyText?: string;
20
25
  /** Which amenity icon layer this POI renders in — `'connector'`,
21
- * `'entrance'`, `'parking'`, `'bus'` or `'other'`. Derived from the
22
- * amenity's connector flag, name, type and keywords; emitted as the
23
- * `amenityCategory` feature property the theme filters on. Amenities
24
- * only. See `amenityCategoryFor`. */
25
- amenityCategory?: 'connector' | 'entrance' | 'parking' | 'bus' | 'other';
26
+ * `'entrance'`, `'parking'`, `'bus'`, `'information'` or `'other'`.
27
+ * Derived from the amenity's connector flag, name, type and keywords;
28
+ * emitted as the `amenityCategory` feature property the theme filters on.
29
+ * Amenities only. See `amenityCategoryFor`. */
30
+ amenityCategory?: 'connector' | 'entrance' | 'parking' | 'bus' | 'information' | 'other';
26
31
  /** Search keywords */
27
32
  keywords?: string[];
28
33
  /** Additional properties */
@@ -55,6 +60,9 @@ interface Waypoint {
55
60
  zoneId?: string | number;
56
61
  }
57
62
 
63
+ /** SW/NE bounding box */
64
+ type Bounds = [[number, number], [number, number]];
65
+
58
66
  /**
59
67
  * Padding kept clear inside the viewport when the SDK frames bounds —
60
68
  * the initial venue/floor fit and the wayfinding route fit. A plain
@@ -123,6 +131,20 @@ interface SDKOptions {
123
131
  * controls the automatic highlight on `routeReady`.
124
132
  */
125
133
  routeStepHighlight?: boolean;
134
+ /**
135
+ * Whether restroom pins that are too close together to draw individually
136
+ * collapse into a single Material `wc` badge. Defaults to `true`.
137
+ *
138
+ * Venues author men's and women's restrooms as two amenities a few metres
139
+ * apart. Both are wayfinding-critical (rank 0) and both draw on a layer that
140
+ * doesn't allow icon overlap, so without this MapLibre resolves the collision
141
+ * by hiding one of them outright until the camera is very close in. Grouping
142
+ * shows one badge in their place and hands back *all* the members when it's
143
+ * tapped, so the consumer can offer directions to each.
144
+ *
145
+ * Set `false` to opt out and get the raw collision behaviour back.
146
+ */
147
+ groupRestroomIcons?: boolean;
126
148
  initialFloor?: string | number;
127
149
  enableInteractions?: boolean;
128
150
  customSprite?: string;
@@ -135,6 +157,16 @@ interface SDKOptions {
135
157
  */
136
158
  wallThickness?: number;
137
159
  boundsPadding?: BoundsPadding;
160
+ /**
161
+ * Caps how far a visitor can pan/zoom out. By default the SDK derives this
162
+ * from the venue's own bounds, scaled to 3x its width/height around the
163
+ * same center — enough room to pan around the building without drifting
164
+ * into an empty, un-tiled region. Pass a number to use a different
165
+ * multiplier (e.g. `1.5` for a tighter leash), explicit `[[west, south],
166
+ * [east, north]]` bounds to override entirely, or `false` to disable
167
+ * max-bounds clamping.
168
+ */
169
+ maxBounds?: Bounds | number | false;
138
170
  /**
139
171
  * Pitch (deg) for the opening view, applied centred on the kiosk ("You
140
172
  * are here"). Omit for top-down.
@@ -185,6 +217,21 @@ interface SDKOptions {
185
217
  * unless this is set explicitly.
186
218
  */
187
219
  connectorBadge?: AmenityBadgeStyle | false;
220
+ /**
221
+ * Badge for information-desk amenities (curated `information`/`info`
222
+ * icon). These render as their own visual class — a green disc with a
223
+ * white glyph by default — so information reads distinct from the gold
224
+ * service amenities. Pass `false` to fall them back into the regular gold
225
+ * badge, or an object to tune the disc / ring. When `amenityBadge` is
226
+ * `false`, information icons are badge-less too unless this is set
227
+ * explicitly.
228
+ */
229
+ informationBadge?: AmenityBadgeStyle | false;
230
+ /**
231
+ * Glyph colour for information icons on their badge. Default white
232
+ * (matches `informationBadge`'s default green disc).
233
+ */
234
+ informationIconColor?: string;
188
235
  styleMode?: 'venueStyleUrl' | 'sdkTemplate';
189
236
  templateOverrideMode?: 'colorsOnly' | 'colorsAndConstants' | 'all';
190
237
  }