@classic-homes/maps-core 0.2.1 → 0.2.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/dist/index.cjs CHANGED
@@ -172,7 +172,7 @@ var OSM_RASTER_SOURCE = {
172
172
  attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
173
173
  };
174
174
  function generateBasicStyle(theme = lightTheme) {
175
- const colors2 = theme.colors;
175
+ const colors3 = theme.colors;
176
176
  return {
177
177
  version: 8,
178
178
  name: `Classic Theme - ${theme.name}`,
@@ -184,7 +184,7 @@ function generateBasicStyle(theme = lightTheme) {
184
184
  id: "background",
185
185
  type: "background",
186
186
  paint: {
187
- "background-color": colors2.background
187
+ "background-color": colors3.background
188
188
  }
189
189
  },
190
190
  {
@@ -204,19 +204,19 @@ function generateBasicStyle(theme = lightTheme) {
204
204
  }
205
205
  };
206
206
  }
207
- function createWaterLayer(colors2) {
207
+ function createWaterLayer(colors3) {
208
208
  return {
209
209
  id: "water",
210
210
  type: "fill",
211
211
  source: "openmaptiles",
212
212
  "source-layer": "water",
213
213
  paint: {
214
- "fill-color": colors2.water,
214
+ "fill-color": colors3.water,
215
215
  "fill-opacity": 1
216
216
  }
217
217
  };
218
218
  }
219
- function createLanduseLayers(colors2) {
219
+ function createLanduseLayers(colors3) {
220
220
  return [
221
221
  {
222
222
  id: "landuse-residential",
@@ -225,7 +225,7 @@ function createLanduseLayers(colors2) {
225
225
  "source-layer": "landuse",
226
226
  filter: ["==", "class", "residential"],
227
227
  paint: {
228
- "fill-color": colors2.residential,
228
+ "fill-color": colors3.residential,
229
229
  "fill-opacity": 0.6
230
230
  }
231
231
  },
@@ -236,7 +236,7 @@ function createLanduseLayers(colors2) {
236
236
  "source-layer": "landuse",
237
237
  filter: ["==", "class", "commercial"],
238
238
  paint: {
239
- "fill-color": colors2.commercial,
239
+ "fill-color": colors3.commercial,
240
240
  "fill-opacity": 0.6
241
241
  }
242
242
  },
@@ -247,7 +247,7 @@ function createLanduseLayers(colors2) {
247
247
  "source-layer": "landuse",
248
248
  filter: ["==", "class", "industrial"],
249
249
  paint: {
250
- "fill-color": colors2.industrial,
250
+ "fill-color": colors3.industrial,
251
251
  "fill-opacity": 0.6
252
252
  }
253
253
  },
@@ -258,13 +258,13 @@ function createLanduseLayers(colors2) {
258
258
  "source-layer": "landuse",
259
259
  filter: ["in", "class", "park", "grass", "cemetery"],
260
260
  paint: {
261
- "fill-color": colors2.park,
261
+ "fill-color": colors3.park,
262
262
  "fill-opacity": 0.8
263
263
  }
264
264
  }
265
265
  ];
266
266
  }
267
- function createBuildingLayers(colors2) {
267
+ function createBuildingLayers(colors3) {
268
268
  return [
269
269
  {
270
270
  id: "building",
@@ -273,7 +273,7 @@ function createBuildingLayers(colors2) {
273
273
  "source-layer": "building",
274
274
  minzoom: 13,
275
275
  paint: {
276
- "fill-color": colors2.building,
276
+ "fill-color": colors3.building,
277
277
  "fill-opacity": ["interpolate", ["linear"], ["zoom"], 13, 0, 15, 1]
278
278
  }
279
279
  },
@@ -284,14 +284,14 @@ function createBuildingLayers(colors2) {
284
284
  "source-layer": "building",
285
285
  minzoom: 13,
286
286
  paint: {
287
- "line-color": colors2.buildingOutline,
287
+ "line-color": colors3.buildingOutline,
288
288
  "line-width": 1,
289
289
  "line-opacity": ["interpolate", ["linear"], ["zoom"], 13, 0, 15, 1]
290
290
  }
291
291
  }
292
292
  ];
293
293
  }
294
- function createRoadLayers(colors2) {
294
+ function createRoadLayers(colors3) {
295
295
  return [
296
296
  // Road casings (outlines)
297
297
  {
@@ -301,7 +301,7 @@ function createRoadLayers(colors2) {
301
301
  "source-layer": "transportation",
302
302
  filter: ["in", "class", "primary", "trunk", "motorway"],
303
303
  paint: {
304
- "line-color": colors2.roadCasing,
304
+ "line-color": colors3.roadCasing,
305
305
  "line-width": ["interpolate", ["linear"], ["zoom"], 5, 0.5, 12, 4, 18, 20]
306
306
  },
307
307
  layout: {
@@ -316,7 +316,7 @@ function createRoadLayers(colors2) {
316
316
  "source-layer": "transportation",
317
317
  filter: ["in", "class", "secondary", "tertiary"],
318
318
  paint: {
319
- "line-color": colors2.roadCasing,
319
+ "line-color": colors3.roadCasing,
320
320
  "line-width": ["interpolate", ["linear"], ["zoom"], 8, 0.5, 12, 2, 18, 12]
321
321
  },
322
322
  layout: {
@@ -332,7 +332,7 @@ function createRoadLayers(colors2) {
332
332
  "source-layer": "transportation",
333
333
  filter: ["in", "class", "primary", "trunk", "motorway"],
334
334
  paint: {
335
- "line-color": colors2.roadPrimary,
335
+ "line-color": colors3.roadPrimary,
336
336
  "line-width": ["interpolate", ["linear"], ["zoom"], 5, 0.25, 12, 3, 18, 18]
337
337
  },
338
338
  layout: {
@@ -347,7 +347,7 @@ function createRoadLayers(colors2) {
347
347
  "source-layer": "transportation",
348
348
  filter: ["in", "class", "secondary", "tertiary"],
349
349
  paint: {
350
- "line-color": colors2.roadSecondary,
350
+ "line-color": colors3.roadSecondary,
351
351
  "line-width": ["interpolate", ["linear"], ["zoom"], 8, 0.25, 12, 1.5, 18, 10]
352
352
  },
353
353
  layout: {
@@ -363,7 +363,7 @@ function createRoadLayers(colors2) {
363
363
  filter: ["in", "class", "minor", "service", "path"],
364
364
  minzoom: 13,
365
365
  paint: {
366
- "line-color": colors2.roadSecondary,
366
+ "line-color": colors3.roadSecondary,
367
367
  "line-width": ["interpolate", ["linear"], ["zoom"], 13, 0.5, 18, 6]
368
368
  },
369
369
  layout: {
@@ -380,14 +380,14 @@ function createRoadLayers(colors2) {
380
380
  filter: ["==", "class", "rail"],
381
381
  minzoom: 10,
382
382
  paint: {
383
- "line-color": colors2.rail,
383
+ "line-color": colors3.rail,
384
384
  "line-width": ["interpolate", ["linear"], ["zoom"], 10, 0.5, 18, 2],
385
385
  "line-dasharray": [2, 2]
386
386
  }
387
387
  }
388
388
  ];
389
389
  }
390
- function createBoundaryLayers(colors2) {
390
+ function createBoundaryLayers(colors3) {
391
391
  return [
392
392
  {
393
393
  id: "boundary-country",
@@ -396,7 +396,7 @@ function createBoundaryLayers(colors2) {
396
396
  "source-layer": "boundary",
397
397
  filter: ["==", "admin_level", 2],
398
398
  paint: {
399
- "line-color": colors2.adminBoundary,
399
+ "line-color": colors3.adminBoundary,
400
400
  "line-width": ["interpolate", ["linear"], ["zoom"], 2, 0.5, 10, 2],
401
401
  "line-dasharray": [3, 2]
402
402
  }
@@ -409,14 +409,14 @@ function createBoundaryLayers(colors2) {
409
409
  filter: ["==", "admin_level", 4],
410
410
  minzoom: 4,
411
411
  paint: {
412
- "line-color": colors2.boundary,
412
+ "line-color": colors3.boundary,
413
413
  "line-width": ["interpolate", ["linear"], ["zoom"], 4, 0.5, 10, 1.5],
414
414
  "line-dasharray": [2, 2]
415
415
  }
416
416
  }
417
417
  ];
418
418
  }
419
- function createLabelLayers(colors2, typography) {
419
+ function createLabelLayers(colors3, typography) {
420
420
  return [
421
421
  {
422
422
  id: "place-labels-city",
@@ -425,8 +425,8 @@ function createLabelLayers(colors2, typography) {
425
425
  "source-layer": "place",
426
426
  filter: ["in", "class", "city", "town"],
427
427
  paint: {
428
- "text-color": colors2.textPrimary,
429
- "text-halo-color": colors2.textHalo,
428
+ "text-color": colors3.textPrimary,
429
+ "text-halo-color": colors3.textHalo,
430
430
  "text-halo-width": 1.5
431
431
  },
432
432
  layout: {
@@ -445,8 +445,8 @@ function createLabelLayers(colors2, typography) {
445
445
  filter: ["in", "class", "suburb", "neighbourhood", "quarter"],
446
446
  minzoom: 12,
447
447
  paint: {
448
- "text-color": colors2.textSecondary,
449
- "text-halo-color": colors2.textHalo,
448
+ "text-color": colors3.textSecondary,
449
+ "text-halo-color": colors3.textHalo,
450
450
  "text-halo-width": 1
451
451
  },
452
452
  layout: {
@@ -464,8 +464,8 @@ function createLabelLayers(colors2, typography) {
464
464
  "source-layer": "transportation_name",
465
465
  minzoom: 13,
466
466
  paint: {
467
- "text-color": colors2.textPrimary,
468
- "text-halo-color": colors2.textHalo,
467
+ "text-color": colors3.textPrimary,
468
+ "text-halo-color": colors3.textHalo,
469
469
  "text-halo-width": 1
470
470
  },
471
471
  layout: {
@@ -484,8 +484,8 @@ function createLabelLayers(colors2, typography) {
484
484
  "source-layer": "poi",
485
485
  minzoom: 14,
486
486
  paint: {
487
- "text-color": colors2.poi,
488
- "text-halo-color": colors2.textHalo,
487
+ "text-color": colors3.poi,
488
+ "text-halo-color": colors3.textHalo,
489
489
  "text-halo-width": 1
490
490
  },
491
491
  layout: {
@@ -500,7 +500,7 @@ function createLabelLayers(colors2, typography) {
500
500
  ];
501
501
  }
502
502
  function generateVectorStyle(theme = lightTheme, tileSource, glyphsUrl, spriteUrl) {
503
- const colors2 = theme.colors;
503
+ const colors3 = theme.colors;
504
504
  return {
505
505
  version: 8,
506
506
  name: `Classic Theme Vector - ${theme.name}`,
@@ -514,15 +514,15 @@ function generateVectorStyle(theme = lightTheme, tileSource, glyphsUrl, spriteUr
514
514
  id: "background",
515
515
  type: "background",
516
516
  paint: {
517
- "background-color": colors2.land
517
+ "background-color": colors3.land
518
518
  }
519
519
  },
520
- createWaterLayer(colors2),
521
- ...createLanduseLayers(colors2),
522
- ...createBuildingLayers(colors2),
523
- ...createRoadLayers(colors2),
524
- ...createBoundaryLayers(colors2),
525
- ...createLabelLayers(colors2, theme.typography)
520
+ createWaterLayer(colors3),
521
+ ...createLanduseLayers(colors3),
522
+ ...createBuildingLayers(colors3),
523
+ ...createRoadLayers(colors3),
524
+ ...createBoundaryLayers(colors3),
525
+ ...createLabelLayers(colors3, theme.typography)
526
526
  ],
527
527
  metadata: {
528
528
  "classic-theme": theme.name
@@ -3855,6 +3855,120 @@ function getLayersWithErrors(states) {
3855
3855
  return Array.from(states.values()).filter((state) => state.error !== null);
3856
3856
  }
3857
3857
 
3858
+ // src/colors/realEstate.ts
3859
+ var lotAvailabilityColors = {
3860
+ Available: "#4caf50",
3861
+ // Green - ready for sale
3862
+ Future: "#795548",
3863
+ // Brown - coming soon
3864
+ Spec: "#FFEB3B",
3865
+ // Yellow - spec home
3866
+ Model: "#CE93D8",
3867
+ // Lavender - model home
3868
+ "Under Contract": "#81D4FA",
3869
+ // Light Blue - pending sale
3870
+ Sold: "#f44336",
3871
+ // Red - sold
3872
+ Unavailable: "#757575",
3873
+ // Gray - not available
3874
+ Unknown: "#757575"
3875
+ // Gray - default fallback
3876
+ };
3877
+ var inventoryStatusColors = {
3878
+ "Ready Now": "#2E7D32",
3879
+ // Green - available immediately
3880
+ Upcoming: "#ED6C02",
3881
+ // Orange - coming soon
3882
+ default: "#757575"
3883
+ // Gray - unknown status
3884
+ };
3885
+ var lotSizeColors = {
3886
+ Small: "#2196f3",
3887
+ // Blue
3888
+ Medium: "#4caf50",
3889
+ // Green
3890
+ Large: "#ff9800",
3891
+ // Orange
3892
+ "Extra Large": "#f44336",
3893
+ // Red
3894
+ Unknown: "#757575"
3895
+ // Gray
3896
+ };
3897
+ function getContrastTextColor(backgroundColor) {
3898
+ const hex = backgroundColor.replace("#", "");
3899
+ const rgb = hex.match(/.{2}/g).map((c) => {
3900
+ const val = parseInt(c, 16) / 255;
3901
+ return val <= 0.03928 ? val / 12.92 : Math.pow((val + 0.055) / 1.055, 2.4);
3902
+ });
3903
+ const luminance = 0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2];
3904
+ return luminance > 0.179 ? "rgba(0, 0, 0, 0.87)" : "#ffffff";
3905
+ }
3906
+ function getAvailabilityColor(availability) {
3907
+ return lotAvailabilityColors[availability] ?? lotAvailabilityColors.Unknown;
3908
+ }
3909
+ function getSizeColor(size) {
3910
+ return lotSizeColors[size] ?? lotSizeColors.Unknown;
3911
+ }
3912
+ var clusterColors = {
3913
+ small: themeTokens.colors.teal[500],
3914
+ // #3ba4a7 - < 10 points
3915
+ medium: themeTokens.colors.navy[700],
3916
+ // #002e3f - 10-50 points
3917
+ large: themeTokens.colors.plum[700],
3918
+ // #5e2c41 - 50+ points
3919
+ stroke: themeTokens.colors.white,
3920
+ text: themeTokens.colors.white
3921
+ };
3922
+ var boundaryColors = {
3923
+ fill: "#C50F22",
3924
+ // Brand red
3925
+ line: "#C50F22",
3926
+ hoverFill: "#1976d2",
3927
+ defaultFill: "#4A90E2",
3928
+ hoverLine: "#1565c0",
3929
+ defaultLine: "#4A90E2"
3930
+ };
3931
+ var salesOfficeColor = "#C50F22";
3932
+ var nonMatchedColor = "#9e9e9e";
3933
+
3934
+ // src/colors/expressions.ts
3935
+ var lotAvailabilityColorExpression = createCategoricalColorExpression(
3936
+ "availability",
3937
+ lotAvailabilityColors,
3938
+ lotAvailabilityColors.Unknown
3939
+ );
3940
+ var inventoryStatusColorExpression = [
3941
+ "match",
3942
+ ["get", "status"],
3943
+ "Ready Now",
3944
+ inventoryStatusColors["Ready Now"],
3945
+ "Upcoming",
3946
+ inventoryStatusColors["Upcoming"],
3947
+ inventoryStatusColors.default
3948
+ ];
3949
+ var lotSizeColorExpression = createCategoricalColorExpression(
3950
+ "sizeCategory",
3951
+ lotSizeColors,
3952
+ lotSizeColors.Unknown
3953
+ );
3954
+ var clusterColorExpression = [
3955
+ "step",
3956
+ ["get", "point_count"],
3957
+ clusterColors.small,
3958
+ 10,
3959
+ clusterColors.medium,
3960
+ 50,
3961
+ clusterColors.large
3962
+ ];
3963
+ function createMatchedColorExpression(baseColorExpression, matchedProperty = "matched") {
3964
+ return [
3965
+ "case",
3966
+ ["coalesce", ["get", matchedProperty], true],
3967
+ baseColorExpression,
3968
+ nonMatchedColor
3969
+ ];
3970
+ }
3971
+
3858
3972
  exports.BASE_OFFSET = BASE_OFFSET;
3859
3973
  exports.BIKE_LANES = BIKE_LANES;
3860
3974
  exports.BUILTIN_BASEMAPS = BUILTIN_BASEMAPS;
@@ -3891,12 +4005,15 @@ exports.WATERSHEDS = WATERSHEDS;
3891
4005
  exports.ZONING_DISTRICTS = ZONING_DISTRICTS;
3892
4006
  exports.applyMarkerChildProtection = applyMarkerChildProtection;
3893
4007
  exports.applyMarkerProtection = applyMarkerProtection;
4008
+ exports.boundaryColors = boundaryColors;
3894
4009
  exports.boundsToPolygon = boundsToPolygon;
3895
4010
  exports.buildRTreeIndex = buildRTreeIndex;
3896
4011
  exports.buildSpatialIndex = buildSpatialIndex;
3897
4012
  exports.calculateBounds = calculateBounds;
3898
4013
  exports.calculateCentroid = calculateCentroid;
3899
4014
  exports.calculateZoomThresholds = calculateZoomThresholds;
4015
+ exports.clusterColorExpression = clusterColorExpression;
4016
+ exports.clusterColors = clusterColors;
3900
4017
  exports.combineBounds = combineBounds;
3901
4018
  exports.computePositionClasses = computePositionClasses;
3902
4019
  exports.computeVerticalOffsetStyle = computeVerticalOffsetStyle;
@@ -3918,6 +4035,7 @@ exports.createInteractiveStatusColorExpression = createInteractiveStatusColorExp
3918
4035
  exports.createLineStyle = createLineStyle;
3919
4036
  exports.createLotFillStyle = createLotFillStyle;
3920
4037
  exports.createLotOutlineStyle = createLotOutlineStyle;
4038
+ exports.createMatchedColorExpression = createMatchedColorExpression;
3921
4039
  exports.createPredictiveViewportManager = createPredictiveViewportManager;
3922
4040
  exports.createRTreeViewportManager = createRTreeViewportManager;
3923
4041
  exports.createSelectionExpression = createSelectionExpression;
@@ -3966,6 +4084,7 @@ exports.generateMarkersDescription = generateMarkersDescription;
3966
4084
  exports.generateMoveAnnouncement = generateMoveAnnouncement;
3967
4085
  exports.generateVectorStyle = generateVectorStyle;
3968
4086
  exports.geoJSONEqual = geoJSONEqual;
4087
+ exports.getAvailabilityColor = getAvailabilityColor;
3969
4088
  exports.getAvailableBasemaps = getAvailableBasemaps;
3970
4089
  exports.getBasicStyle = getBasicStyle;
3971
4090
  exports.getChangedPaintProps = getChangedPaintProps;
@@ -3973,6 +4092,7 @@ exports.getClusterBounds = getClusterBounds;
3973
4092
  exports.getClusterChildren = getClusterChildren;
3974
4093
  exports.getClusterExpansionZoom = getClusterExpansionZoom;
3975
4094
  exports.getClusterLeaves = getClusterLeaves;
4095
+ exports.getContrastTextColor = getContrastTextColor;
3976
4096
  exports.getHighlightStyle = getHighlightStyle;
3977
4097
  exports.getLayerCategories = getLayerCategories;
3978
4098
  exports.getLayerStatesArray = getLayerStatesArray;
@@ -3982,18 +4102,26 @@ exports.getLayersWithErrors = getLayersWithErrors;
3982
4102
  exports.getSelectionStyle = getSelectionStyle;
3983
4103
  exports.getSimplificationToleranceForZoom = getSimplificationToleranceForZoom;
3984
4104
  exports.getSimplifiedFeaturesForZoom = getSimplifiedFeaturesForZoom;
4105
+ exports.getSizeColor = getSizeColor;
3985
4106
  exports.getTheme = getTheme;
3986
4107
  exports.getTypography = getTypography;
3987
4108
  exports.getVisibleLayerIds = getVisibleLayerIds;
3988
4109
  exports.groupFeaturesByProperty = groupFeaturesByProperty;
3989
4110
  exports.groupLayersByCategory = groupLayersByCategory;
3990
4111
  exports.hideAllLayers = hideAllLayers;
4112
+ exports.inventoryStatusColorExpression = inventoryStatusColorExpression;
4113
+ exports.inventoryStatusColors = inventoryStatusColors;
3991
4114
  exports.isAnyLayerLoading = isAnyLayerLoading;
3992
4115
  exports.isClusterFeature = isClusterFeature;
3993
4116
  exports.isValidBounds = isValidBounds;
3994
4117
  exports.lightBasicStyle = lightBasicStyle;
3995
4118
  exports.lightTheme = lightTheme;
3996
4119
  exports.loadGeoJSON = loadGeoJSON;
4120
+ exports.lotAvailabilityColorExpression = lotAvailabilityColorExpression;
4121
+ exports.lotAvailabilityColors = lotAvailabilityColors;
4122
+ exports.lotSizeColorExpression = lotSizeColorExpression;
4123
+ exports.lotSizeColors = lotSizeColors;
4124
+ exports.nonMatchedColor = nonMatchedColor;
3997
4125
  exports.paintPropsEqual = paintPropsEqual;
3998
4126
  exports.queryByBounds = queryByBounds;
3999
4127
  exports.queryByBoundsWithStats = queryByBoundsWithStats;
@@ -4004,6 +4132,7 @@ exports.reorderLayers = reorderLayers;
4004
4132
  exports.resolveBasemapStyle = resolveBasemapStyle;
4005
4133
  exports.resolveBasemapThumbnail = resolveBasemapThumbnail;
4006
4134
  exports.resolveLayerSourceUrl = resolveLayerSourceUrl;
4135
+ exports.salesOfficeColor = salesOfficeColor;
4007
4136
  exports.searchLayers = searchLayers;
4008
4137
  exports.serializeFilter = serializeFilter;
4009
4138
  exports.setLayerError = setLayerError;
package/dist/index.d.cts CHANGED
@@ -1605,4 +1605,107 @@ declare function isAnyLayerLoading(states: Map<string, OverlayLayerState>): bool
1605
1605
  */
1606
1606
  declare function getLayersWithErrors(states: Map<string, OverlayLayerState>): OverlayLayerState[];
1607
1607
 
1608
- export { BASE_OFFSET, BIKE_LANES, BUILTIN_BASEMAPS, BUILTIN_OVERLAY_LAYERS, BasemapApiKeys, BasemapDefinition, BoundsArray, CATEGORY_META, CITY_LIMITS, CLASSIC_DARK, CLASSIC_LIGHT, type ClusterExpandOptions, type ClusterExpansionResult, type ClusterFeatureProperties, type ColorExpression, ControlPosition, DEFAULT_SIMPLIFICATION_THRESHOLDS, type DynamicLODOptions, type DynamicLODState, type ExtrusionHeightOptions, FLOOD_ZONES, FREE_BASEMAPS, type FeatureGroup, type FilterExpression, type GenerateLODOptions, GeoJSONFeature, GeoJSONFeatureCollection, type GeoJSONFingerprint, GeoJSONPolygon, type GroupFeaturesOptions, KEYBOARD_CONTROLS, type LODData, type LODDataWithSimplification, type LayerManagerProps, LngLat, type LoadGeoJSONOptions, type LoadGeoJSONResult, type LotFillStyleOptions, type LotOutlineStyleOptions, MAPTILER_BASIC, MAPTILER_OUTDOOR, MAPTILER_SATELLITE, MAPTILER_STREETS, MARKER_PROTECTION_CLASS, MapBounds, MapTheme, MarkerData, type NumberExpression, OFFSET_CLASSES, OSM_STANDARD, type OverlayApiKeys, type OverlayDataSource, type OverlayLayerCategory, type OverlayLayerCategoryMeta, type OverlayLayerDefinition, type OverlayLayerLegend, type OverlayLayerState, type OverlayLayerStyle, type OverlayLegendItem, PARKS, POSITION_CLASSES, type PaintProps, type PaintPropsDiff, SCHOOL_DISTRICTS, SPORTS_FACILITIES, STADIA_ALIDADE_DARK, STADIA_ALIDADE_SMOOTH, STADIA_STAMEN_TERRAIN, STADIA_STAMEN_TONER, STADIA_STAMEN_WATERCOLOR, type SimplificationStats, type SimplificationThreshold, TRAILS, TRANSIT_ROUTES, type ValidationResult, WATERSHEDS, ZONING_DISTRICTS, applyMarkerChildProtection, applyMarkerProtection, boundsToPolygon, calculateBounds, calculateCentroid, calculateZoomThresholds, combineBounds, computePositionClasses, computeVerticalOffsetStyle, countFeaturesByType, createCategoricalColorExpression, createCircleStyle, createContinuousColorExpression, createDynamicLODManager, createExtrusionHeightExpression, createExtrusionStyle, createFillStyle, createGeoJSONFingerprint, createHeatmapStyle, createHoverExpression, createInitialLayerStates, createInteractiveExpression, createInteractiveStatusColorExpression, createLineStyle, createLotFillStyle, createLotOutlineStyle, createSelectionExpression, createStatusColorExpression, createZoomExpression, decimalToDMS, deepEqual, expandCluster, expandClusterToBounds, extendBounds, filterByGeometryType, filterEqual, fingerprintEqual, formatArea, formatBearing, formatBounds, formatCoordinates, formatDistance, formatFeatureProperties, formatLabel, formatPitch, formatPropertyValue, formatScale, formatZoom, generateBoundingPolygon, generateConvexHull, generateFeatureCollectionDescription, generateFeatureTable, generateKeyboardControlsDescription, generateLODData, generateLODDataWithSimplification, generateMapDescription, generateMarkerList, generateMarkersDescription, generateMoveAnnouncement, geoJSONEqual, getAvailableBasemaps, getChangedPaintProps, getClusterBounds, getClusterChildren, getClusterExpansionZoom, getClusterLeaves, getHighlightStyle, getLayerCategories, getLayerStatesArray, getLayerStyleForTheme, getLayersByCategory, getLayersWithErrors, getSelectionStyle, getSimplificationToleranceForZoom, getSimplifiedFeaturesForZoom, getVisibleLayerIds, groupFeaturesByProperty, groupLayersByCategory, hideAllLayers, isAnyLayerLoading, isClusterFeature, isValidBounds, loadGeoJSON, paintPropsEqual, removeMarkerProtection, reorderLayers, resolveBasemapStyle, resolveBasemapThumbnail, resolveLayerSourceUrl, searchLayers, serializeFilter, setLayerError, setLayerLoading, setLayerOpacity, showAllLayers, simplifyFeature, simplifyFeatureCollection, simplifyFeatureCollectionWithStats, simplifyPolygon, toggleLayerVisibility, updateLayerState, validateGeoJSON, zoomToScale };
1608
+ /**
1609
+ * Real Estate Domain Colors
1610
+ * Colors for visualizing lot and inventory data on maps.
1611
+ */
1612
+ /**
1613
+ * Lot availability status colors
1614
+ */
1615
+ declare const lotAvailabilityColors: {
1616
+ readonly Available: "#4caf50";
1617
+ readonly Future: "#795548";
1618
+ readonly Spec: "#FFEB3B";
1619
+ readonly Model: "#CE93D8";
1620
+ readonly 'Under Contract': "#81D4FA";
1621
+ readonly Sold: "#f44336";
1622
+ readonly Unavailable: "#757575";
1623
+ readonly Unknown: "#757575";
1624
+ };
1625
+ type LotAvailability = keyof typeof lotAvailabilityColors;
1626
+ /**
1627
+ * Inventory home status colors
1628
+ */
1629
+ declare const inventoryStatusColors: {
1630
+ readonly 'Ready Now': "#2E7D32";
1631
+ readonly Upcoming: "#ED6C02";
1632
+ readonly default: "#757575";
1633
+ };
1634
+ type InventoryStatus = keyof typeof inventoryStatusColors;
1635
+ /**
1636
+ * Lot size category colors
1637
+ */
1638
+ declare const lotSizeColors: {
1639
+ readonly Small: "#2196f3";
1640
+ readonly Medium: "#4caf50";
1641
+ readonly Large: "#ff9800";
1642
+ readonly 'Extra Large': "#f44336";
1643
+ readonly Unknown: "#757575";
1644
+ };
1645
+ type LotSize = keyof typeof lotSizeColors;
1646
+ /**
1647
+ * Get contrast text color for WCAG accessibility
1648
+ */
1649
+ declare function getContrastTextColor(backgroundColor: string): string;
1650
+ declare function getAvailabilityColor(availability: string): string;
1651
+ declare function getSizeColor(size: string): string;
1652
+
1653
+ /**
1654
+ * Map Feature Colors
1655
+ * Colors for common map visualization features.
1656
+ */
1657
+ /**
1658
+ * Cluster visualization colors (using brand tokens)
1659
+ */
1660
+ declare const clusterColors: {
1661
+ readonly small: "#3ba4a7";
1662
+ readonly medium: "#002e3f";
1663
+ readonly large: "#5e2c41";
1664
+ readonly stroke: "#ffffff";
1665
+ readonly text: "#ffffff";
1666
+ };
1667
+ /**
1668
+ * Community/region boundary colors
1669
+ */
1670
+ declare const boundaryColors: {
1671
+ readonly fill: "#C50F22";
1672
+ readonly line: "#C50F22";
1673
+ readonly hoverFill: "#1976d2";
1674
+ readonly defaultFill: "#4A90E2";
1675
+ readonly hoverLine: "#1565c0";
1676
+ readonly defaultLine: "#4A90E2";
1677
+ };
1678
+ /**
1679
+ * Sales office marker color
1680
+ */
1681
+ declare const salesOfficeColor = "#C50F22";
1682
+ /**
1683
+ * Color for non-matched/de-emphasized features
1684
+ */
1685
+ declare const nonMatchedColor = "#9e9e9e";
1686
+
1687
+ /**
1688
+ * Pre-built MapLibre Expressions
1689
+ */
1690
+ /**
1691
+ * Color expression for lot availability (property: 'availability')
1692
+ */
1693
+ declare const lotAvailabilityColorExpression: unknown[];
1694
+ /**
1695
+ * Color expression for inventory home status (property: 'status')
1696
+ */
1697
+ declare const inventoryStatusColorExpression: unknown[];
1698
+ /**
1699
+ * Color expression for lot size (property: 'sizeCategory')
1700
+ */
1701
+ declare const lotSizeColorExpression: unknown[];
1702
+ /**
1703
+ * Cluster color expression based on point_count
1704
+ */
1705
+ declare const clusterColorExpression: unknown[];
1706
+ /**
1707
+ * Create matched/non-matched color expression
1708
+ */
1709
+ declare function createMatchedColorExpression(baseColorExpression: unknown[], matchedProperty?: string): unknown[];
1710
+
1711
+ export { BASE_OFFSET, BIKE_LANES, BUILTIN_BASEMAPS, BUILTIN_OVERLAY_LAYERS, BasemapApiKeys, BasemapDefinition, BoundsArray, CATEGORY_META, CITY_LIMITS, CLASSIC_DARK, CLASSIC_LIGHT, type ClusterExpandOptions, type ClusterExpansionResult, type ClusterFeatureProperties, type ColorExpression, ControlPosition, DEFAULT_SIMPLIFICATION_THRESHOLDS, type DynamicLODOptions, type DynamicLODState, type ExtrusionHeightOptions, FLOOD_ZONES, FREE_BASEMAPS, type FeatureGroup, type FilterExpression, type GenerateLODOptions, GeoJSONFeature, GeoJSONFeatureCollection, type GeoJSONFingerprint, GeoJSONPolygon, type GroupFeaturesOptions, type InventoryStatus, KEYBOARD_CONTROLS, type LODData, type LODDataWithSimplification, type LayerManagerProps, LngLat, type LoadGeoJSONOptions, type LoadGeoJSONResult, type LotAvailability, type LotFillStyleOptions, type LotOutlineStyleOptions, type LotSize, MAPTILER_BASIC, MAPTILER_OUTDOOR, MAPTILER_SATELLITE, MAPTILER_STREETS, MARKER_PROTECTION_CLASS, MapBounds, MapTheme, MarkerData, type NumberExpression, OFFSET_CLASSES, OSM_STANDARD, type OverlayApiKeys, type OverlayDataSource, type OverlayLayerCategory, type OverlayLayerCategoryMeta, type OverlayLayerDefinition, type OverlayLayerLegend, type OverlayLayerState, type OverlayLayerStyle, type OverlayLegendItem, PARKS, POSITION_CLASSES, type PaintProps, type PaintPropsDiff, SCHOOL_DISTRICTS, SPORTS_FACILITIES, STADIA_ALIDADE_DARK, STADIA_ALIDADE_SMOOTH, STADIA_STAMEN_TERRAIN, STADIA_STAMEN_TONER, STADIA_STAMEN_WATERCOLOR, type SimplificationStats, type SimplificationThreshold, TRAILS, TRANSIT_ROUTES, type ValidationResult, WATERSHEDS, ZONING_DISTRICTS, applyMarkerChildProtection, applyMarkerProtection, boundaryColors, boundsToPolygon, calculateBounds, calculateCentroid, calculateZoomThresholds, clusterColorExpression, clusterColors, combineBounds, computePositionClasses, computeVerticalOffsetStyle, countFeaturesByType, createCategoricalColorExpression, createCircleStyle, createContinuousColorExpression, createDynamicLODManager, createExtrusionHeightExpression, createExtrusionStyle, createFillStyle, createGeoJSONFingerprint, createHeatmapStyle, createHoverExpression, createInitialLayerStates, createInteractiveExpression, createInteractiveStatusColorExpression, createLineStyle, createLotFillStyle, createLotOutlineStyle, createMatchedColorExpression, createSelectionExpression, createStatusColorExpression, createZoomExpression, decimalToDMS, deepEqual, expandCluster, expandClusterToBounds, extendBounds, filterByGeometryType, filterEqual, fingerprintEqual, formatArea, formatBearing, formatBounds, formatCoordinates, formatDistance, formatFeatureProperties, formatLabel, formatPitch, formatPropertyValue, formatScale, formatZoom, generateBoundingPolygon, generateConvexHull, generateFeatureCollectionDescription, generateFeatureTable, generateKeyboardControlsDescription, generateLODData, generateLODDataWithSimplification, generateMapDescription, generateMarkerList, generateMarkersDescription, generateMoveAnnouncement, geoJSONEqual, getAvailabilityColor, getAvailableBasemaps, getChangedPaintProps, getClusterBounds, getClusterChildren, getClusterExpansionZoom, getClusterLeaves, getContrastTextColor, getHighlightStyle, getLayerCategories, getLayerStatesArray, getLayerStyleForTheme, getLayersByCategory, getLayersWithErrors, getSelectionStyle, getSimplificationToleranceForZoom, getSimplifiedFeaturesForZoom, getSizeColor, getVisibleLayerIds, groupFeaturesByProperty, groupLayersByCategory, hideAllLayers, inventoryStatusColorExpression, inventoryStatusColors, isAnyLayerLoading, isClusterFeature, isValidBounds, loadGeoJSON, lotAvailabilityColorExpression, lotAvailabilityColors, lotSizeColorExpression, lotSizeColors, nonMatchedColor, paintPropsEqual, removeMarkerProtection, reorderLayers, resolveBasemapStyle, resolveBasemapThumbnail, resolveLayerSourceUrl, salesOfficeColor, searchLayers, serializeFilter, setLayerError, setLayerLoading, setLayerOpacity, showAllLayers, simplifyFeature, simplifyFeatureCollection, simplifyFeatureCollectionWithStats, simplifyPolygon, toggleLayerVisibility, updateLayerState, validateGeoJSON, zoomToScale };
package/dist/index.d.ts CHANGED
@@ -1605,4 +1605,107 @@ declare function isAnyLayerLoading(states: Map<string, OverlayLayerState>): bool
1605
1605
  */
1606
1606
  declare function getLayersWithErrors(states: Map<string, OverlayLayerState>): OverlayLayerState[];
1607
1607
 
1608
- export { BASE_OFFSET, BIKE_LANES, BUILTIN_BASEMAPS, BUILTIN_OVERLAY_LAYERS, BasemapApiKeys, BasemapDefinition, BoundsArray, CATEGORY_META, CITY_LIMITS, CLASSIC_DARK, CLASSIC_LIGHT, type ClusterExpandOptions, type ClusterExpansionResult, type ClusterFeatureProperties, type ColorExpression, ControlPosition, DEFAULT_SIMPLIFICATION_THRESHOLDS, type DynamicLODOptions, type DynamicLODState, type ExtrusionHeightOptions, FLOOD_ZONES, FREE_BASEMAPS, type FeatureGroup, type FilterExpression, type GenerateLODOptions, GeoJSONFeature, GeoJSONFeatureCollection, type GeoJSONFingerprint, GeoJSONPolygon, type GroupFeaturesOptions, KEYBOARD_CONTROLS, type LODData, type LODDataWithSimplification, type LayerManagerProps, LngLat, type LoadGeoJSONOptions, type LoadGeoJSONResult, type LotFillStyleOptions, type LotOutlineStyleOptions, MAPTILER_BASIC, MAPTILER_OUTDOOR, MAPTILER_SATELLITE, MAPTILER_STREETS, MARKER_PROTECTION_CLASS, MapBounds, MapTheme, MarkerData, type NumberExpression, OFFSET_CLASSES, OSM_STANDARD, type OverlayApiKeys, type OverlayDataSource, type OverlayLayerCategory, type OverlayLayerCategoryMeta, type OverlayLayerDefinition, type OverlayLayerLegend, type OverlayLayerState, type OverlayLayerStyle, type OverlayLegendItem, PARKS, POSITION_CLASSES, type PaintProps, type PaintPropsDiff, SCHOOL_DISTRICTS, SPORTS_FACILITIES, STADIA_ALIDADE_DARK, STADIA_ALIDADE_SMOOTH, STADIA_STAMEN_TERRAIN, STADIA_STAMEN_TONER, STADIA_STAMEN_WATERCOLOR, type SimplificationStats, type SimplificationThreshold, TRAILS, TRANSIT_ROUTES, type ValidationResult, WATERSHEDS, ZONING_DISTRICTS, applyMarkerChildProtection, applyMarkerProtection, boundsToPolygon, calculateBounds, calculateCentroid, calculateZoomThresholds, combineBounds, computePositionClasses, computeVerticalOffsetStyle, countFeaturesByType, createCategoricalColorExpression, createCircleStyle, createContinuousColorExpression, createDynamicLODManager, createExtrusionHeightExpression, createExtrusionStyle, createFillStyle, createGeoJSONFingerprint, createHeatmapStyle, createHoverExpression, createInitialLayerStates, createInteractiveExpression, createInteractiveStatusColorExpression, createLineStyle, createLotFillStyle, createLotOutlineStyle, createSelectionExpression, createStatusColorExpression, createZoomExpression, decimalToDMS, deepEqual, expandCluster, expandClusterToBounds, extendBounds, filterByGeometryType, filterEqual, fingerprintEqual, formatArea, formatBearing, formatBounds, formatCoordinates, formatDistance, formatFeatureProperties, formatLabel, formatPitch, formatPropertyValue, formatScale, formatZoom, generateBoundingPolygon, generateConvexHull, generateFeatureCollectionDescription, generateFeatureTable, generateKeyboardControlsDescription, generateLODData, generateLODDataWithSimplification, generateMapDescription, generateMarkerList, generateMarkersDescription, generateMoveAnnouncement, geoJSONEqual, getAvailableBasemaps, getChangedPaintProps, getClusterBounds, getClusterChildren, getClusterExpansionZoom, getClusterLeaves, getHighlightStyle, getLayerCategories, getLayerStatesArray, getLayerStyleForTheme, getLayersByCategory, getLayersWithErrors, getSelectionStyle, getSimplificationToleranceForZoom, getSimplifiedFeaturesForZoom, getVisibleLayerIds, groupFeaturesByProperty, groupLayersByCategory, hideAllLayers, isAnyLayerLoading, isClusterFeature, isValidBounds, loadGeoJSON, paintPropsEqual, removeMarkerProtection, reorderLayers, resolveBasemapStyle, resolveBasemapThumbnail, resolveLayerSourceUrl, searchLayers, serializeFilter, setLayerError, setLayerLoading, setLayerOpacity, showAllLayers, simplifyFeature, simplifyFeatureCollection, simplifyFeatureCollectionWithStats, simplifyPolygon, toggleLayerVisibility, updateLayerState, validateGeoJSON, zoomToScale };
1608
+ /**
1609
+ * Real Estate Domain Colors
1610
+ * Colors for visualizing lot and inventory data on maps.
1611
+ */
1612
+ /**
1613
+ * Lot availability status colors
1614
+ */
1615
+ declare const lotAvailabilityColors: {
1616
+ readonly Available: "#4caf50";
1617
+ readonly Future: "#795548";
1618
+ readonly Spec: "#FFEB3B";
1619
+ readonly Model: "#CE93D8";
1620
+ readonly 'Under Contract': "#81D4FA";
1621
+ readonly Sold: "#f44336";
1622
+ readonly Unavailable: "#757575";
1623
+ readonly Unknown: "#757575";
1624
+ };
1625
+ type LotAvailability = keyof typeof lotAvailabilityColors;
1626
+ /**
1627
+ * Inventory home status colors
1628
+ */
1629
+ declare const inventoryStatusColors: {
1630
+ readonly 'Ready Now': "#2E7D32";
1631
+ readonly Upcoming: "#ED6C02";
1632
+ readonly default: "#757575";
1633
+ };
1634
+ type InventoryStatus = keyof typeof inventoryStatusColors;
1635
+ /**
1636
+ * Lot size category colors
1637
+ */
1638
+ declare const lotSizeColors: {
1639
+ readonly Small: "#2196f3";
1640
+ readonly Medium: "#4caf50";
1641
+ readonly Large: "#ff9800";
1642
+ readonly 'Extra Large': "#f44336";
1643
+ readonly Unknown: "#757575";
1644
+ };
1645
+ type LotSize = keyof typeof lotSizeColors;
1646
+ /**
1647
+ * Get contrast text color for WCAG accessibility
1648
+ */
1649
+ declare function getContrastTextColor(backgroundColor: string): string;
1650
+ declare function getAvailabilityColor(availability: string): string;
1651
+ declare function getSizeColor(size: string): string;
1652
+
1653
+ /**
1654
+ * Map Feature Colors
1655
+ * Colors for common map visualization features.
1656
+ */
1657
+ /**
1658
+ * Cluster visualization colors (using brand tokens)
1659
+ */
1660
+ declare const clusterColors: {
1661
+ readonly small: "#3ba4a7";
1662
+ readonly medium: "#002e3f";
1663
+ readonly large: "#5e2c41";
1664
+ readonly stroke: "#ffffff";
1665
+ readonly text: "#ffffff";
1666
+ };
1667
+ /**
1668
+ * Community/region boundary colors
1669
+ */
1670
+ declare const boundaryColors: {
1671
+ readonly fill: "#C50F22";
1672
+ readonly line: "#C50F22";
1673
+ readonly hoverFill: "#1976d2";
1674
+ readonly defaultFill: "#4A90E2";
1675
+ readonly hoverLine: "#1565c0";
1676
+ readonly defaultLine: "#4A90E2";
1677
+ };
1678
+ /**
1679
+ * Sales office marker color
1680
+ */
1681
+ declare const salesOfficeColor = "#C50F22";
1682
+ /**
1683
+ * Color for non-matched/de-emphasized features
1684
+ */
1685
+ declare const nonMatchedColor = "#9e9e9e";
1686
+
1687
+ /**
1688
+ * Pre-built MapLibre Expressions
1689
+ */
1690
+ /**
1691
+ * Color expression for lot availability (property: 'availability')
1692
+ */
1693
+ declare const lotAvailabilityColorExpression: unknown[];
1694
+ /**
1695
+ * Color expression for inventory home status (property: 'status')
1696
+ */
1697
+ declare const inventoryStatusColorExpression: unknown[];
1698
+ /**
1699
+ * Color expression for lot size (property: 'sizeCategory')
1700
+ */
1701
+ declare const lotSizeColorExpression: unknown[];
1702
+ /**
1703
+ * Cluster color expression based on point_count
1704
+ */
1705
+ declare const clusterColorExpression: unknown[];
1706
+ /**
1707
+ * Create matched/non-matched color expression
1708
+ */
1709
+ declare function createMatchedColorExpression(baseColorExpression: unknown[], matchedProperty?: string): unknown[];
1710
+
1711
+ export { BASE_OFFSET, BIKE_LANES, BUILTIN_BASEMAPS, BUILTIN_OVERLAY_LAYERS, BasemapApiKeys, BasemapDefinition, BoundsArray, CATEGORY_META, CITY_LIMITS, CLASSIC_DARK, CLASSIC_LIGHT, type ClusterExpandOptions, type ClusterExpansionResult, type ClusterFeatureProperties, type ColorExpression, ControlPosition, DEFAULT_SIMPLIFICATION_THRESHOLDS, type DynamicLODOptions, type DynamicLODState, type ExtrusionHeightOptions, FLOOD_ZONES, FREE_BASEMAPS, type FeatureGroup, type FilterExpression, type GenerateLODOptions, GeoJSONFeature, GeoJSONFeatureCollection, type GeoJSONFingerprint, GeoJSONPolygon, type GroupFeaturesOptions, type InventoryStatus, KEYBOARD_CONTROLS, type LODData, type LODDataWithSimplification, type LayerManagerProps, LngLat, type LoadGeoJSONOptions, type LoadGeoJSONResult, type LotAvailability, type LotFillStyleOptions, type LotOutlineStyleOptions, type LotSize, MAPTILER_BASIC, MAPTILER_OUTDOOR, MAPTILER_SATELLITE, MAPTILER_STREETS, MARKER_PROTECTION_CLASS, MapBounds, MapTheme, MarkerData, type NumberExpression, OFFSET_CLASSES, OSM_STANDARD, type OverlayApiKeys, type OverlayDataSource, type OverlayLayerCategory, type OverlayLayerCategoryMeta, type OverlayLayerDefinition, type OverlayLayerLegend, type OverlayLayerState, type OverlayLayerStyle, type OverlayLegendItem, PARKS, POSITION_CLASSES, type PaintProps, type PaintPropsDiff, SCHOOL_DISTRICTS, SPORTS_FACILITIES, STADIA_ALIDADE_DARK, STADIA_ALIDADE_SMOOTH, STADIA_STAMEN_TERRAIN, STADIA_STAMEN_TONER, STADIA_STAMEN_WATERCOLOR, type SimplificationStats, type SimplificationThreshold, TRAILS, TRANSIT_ROUTES, type ValidationResult, WATERSHEDS, ZONING_DISTRICTS, applyMarkerChildProtection, applyMarkerProtection, boundaryColors, boundsToPolygon, calculateBounds, calculateCentroid, calculateZoomThresholds, clusterColorExpression, clusterColors, combineBounds, computePositionClasses, computeVerticalOffsetStyle, countFeaturesByType, createCategoricalColorExpression, createCircleStyle, createContinuousColorExpression, createDynamicLODManager, createExtrusionHeightExpression, createExtrusionStyle, createFillStyle, createGeoJSONFingerprint, createHeatmapStyle, createHoverExpression, createInitialLayerStates, createInteractiveExpression, createInteractiveStatusColorExpression, createLineStyle, createLotFillStyle, createLotOutlineStyle, createMatchedColorExpression, createSelectionExpression, createStatusColorExpression, createZoomExpression, decimalToDMS, deepEqual, expandCluster, expandClusterToBounds, extendBounds, filterByGeometryType, filterEqual, fingerprintEqual, formatArea, formatBearing, formatBounds, formatCoordinates, formatDistance, formatFeatureProperties, formatLabel, formatPitch, formatPropertyValue, formatScale, formatZoom, generateBoundingPolygon, generateConvexHull, generateFeatureCollectionDescription, generateFeatureTable, generateKeyboardControlsDescription, generateLODData, generateLODDataWithSimplification, generateMapDescription, generateMarkerList, generateMarkersDescription, generateMoveAnnouncement, geoJSONEqual, getAvailabilityColor, getAvailableBasemaps, getChangedPaintProps, getClusterBounds, getClusterChildren, getClusterExpansionZoom, getClusterLeaves, getContrastTextColor, getHighlightStyle, getLayerCategories, getLayerStatesArray, getLayerStyleForTheme, getLayersByCategory, getLayersWithErrors, getSelectionStyle, getSimplificationToleranceForZoom, getSimplifiedFeaturesForZoom, getSizeColor, getVisibleLayerIds, groupFeaturesByProperty, groupLayersByCategory, hideAllLayers, inventoryStatusColorExpression, inventoryStatusColors, isAnyLayerLoading, isClusterFeature, isValidBounds, loadGeoJSON, lotAvailabilityColorExpression, lotAvailabilityColors, lotSizeColorExpression, lotSizeColors, nonMatchedColor, paintPropsEqual, removeMarkerProtection, reorderLayers, resolveBasemapStyle, resolveBasemapThumbnail, resolveLayerSourceUrl, salesOfficeColor, searchLayers, serializeFilter, setLayerError, setLayerLoading, setLayerOpacity, showAllLayers, simplifyFeature, simplifyFeatureCollection, simplifyFeatureCollectionWithStats, simplifyPolygon, toggleLayerVisibility, updateLayerState, validateGeoJSON, zoomToScale };
package/dist/index.js CHANGED
@@ -1,6 +1,7 @@
1
1
  import { lightBasicStyle, darkBasicStyle, lightTheme } from './chunk-2NISJ7WE.js';
2
2
  export { THEME_DARK, THEME_LIGHT, darkBasicStyle, darkTheme, generateBasicStyle, generateDarkColors, generateDarkDataColors, generateDarkTheme, generateLightColors, generateLightDataColors, generateLightTheme, generateVectorStyle, getBasicStyle, getTheme, getTypography, lightBasicStyle, lightTheme } from './chunk-2NISJ7WE.js';
3
3
  import RBush from 'rbush';
4
+ import { colors } from '@classic-homes/theme-tokens';
4
5
 
5
6
  // src/utils/accessibility.ts
6
7
  var KEYBOARD_CONTROLS = {
@@ -3319,4 +3320,118 @@ function getLayersWithErrors(states) {
3319
3320
  return Array.from(states.values()).filter((state) => state.error !== null);
3320
3321
  }
3321
3322
 
3322
- export { BASE_OFFSET, BIKE_LANES, BUILTIN_BASEMAPS, BUILTIN_OVERLAY_LAYERS, CATEGORY_META, CITY_LIMITS, CLASSIC_DARK, CLASSIC_LIGHT, DEFAULT_SIMPLIFICATION_THRESHOLDS, FLOOD_ZONES, FREE_BASEMAPS, KEYBOARD_CONTROLS, MAPTILER_BASIC, MAPTILER_OUTDOOR, MAPTILER_SATELLITE, MAPTILER_STREETS, MARKER_PROTECTION_CLASS, OFFSET_CLASSES, OSM_STANDARD, PARKS, POSITION_CLASSES, SCHOOL_DISTRICTS, SPORTS_FACILITIES, STADIA_ALIDADE_DARK, STADIA_ALIDADE_SMOOTH, STADIA_STAMEN_TERRAIN, STADIA_STAMEN_TONER, STADIA_STAMEN_WATERCOLOR, TRAILS, TRANSIT_ROUTES, WATERSHEDS, ZONING_DISTRICTS, applyMarkerChildProtection, applyMarkerProtection, boundsToPolygon, buildRTreeIndex, buildSpatialIndex, calculateBounds, calculateCentroid, calculateZoomThresholds, combineBounds, computePositionClasses, computeVerticalOffsetStyle, countFeaturesByType, createCategoricalColorExpression, createCircleStyle, createContinuousColorExpression, createDynamicLODManager, createExtrusionHeightExpression, createExtrusionStyle, createFillStyle, createGeoJSONFingerprint, createHeatmapStyle, createHoverExpression, createIdleViewportManager, createInitialLayerStates, createInteractiveExpression, createInteractiveStatusColorExpression, createLineStyle, createLotFillStyle, createLotOutlineStyle, createPredictiveViewportManager, createRTreeViewportManager, createSelectionExpression, createStatusColorExpression, createViewportManager, createViewportQuery, createZoomExpression, decimalToDMS, deepEqual, expandCluster, expandClusterToBounds, extendBounds, filterByGeometryType, filterEqual, fingerprintEqual, formatArea, formatBearing, formatBounds, formatCoordinates, formatDistance, formatFeatureProperties, formatLabel, formatPitch, formatPropertyValue, formatScale, formatZoom, generateBoundingPolygon, generateConvexHull, generateFeatureCollectionDescription, generateFeatureTable, generateKeyboardControlsDescription, generateLODData, generateLODDataWithSimplification, generateMapDescription, generateMarkerList, generateMarkersDescription, generateMoveAnnouncement, geoJSONEqual, getAvailableBasemaps, getChangedPaintProps, getClusterBounds, getClusterChildren, getClusterExpansionZoom, getClusterLeaves, getHighlightStyle, getLayerCategories, getLayerStatesArray, getLayerStyleForTheme, getLayersByCategory, getLayersWithErrors, getSelectionStyle, getSimplificationToleranceForZoom, getSimplifiedFeaturesForZoom, getVisibleLayerIds, groupFeaturesByProperty, groupLayersByCategory, hideAllLayers, isAnyLayerLoading, isClusterFeature, isValidBounds, loadGeoJSON, paintPropsEqual, queryByBounds, queryByBoundsWithStats, queryRTreeByBounds, queryRTreeByBoundsWithStats, removeMarkerProtection, reorderLayers, resolveBasemapStyle, resolveBasemapThumbnail, resolveLayerSourceUrl, searchLayers, serializeFilter, setLayerError, setLayerLoading, setLayerOpacity, showAllLayers, simplifyFeature, simplifyFeatureCollection, simplifyFeatureCollectionWithStats, simplifyPolygon, toggleLayerVisibility, updateLayerState, validateGeoJSON, zoomToScale };
3323
+ // src/colors/realEstate.ts
3324
+ var lotAvailabilityColors = {
3325
+ Available: "#4caf50",
3326
+ // Green - ready for sale
3327
+ Future: "#795548",
3328
+ // Brown - coming soon
3329
+ Spec: "#FFEB3B",
3330
+ // Yellow - spec home
3331
+ Model: "#CE93D8",
3332
+ // Lavender - model home
3333
+ "Under Contract": "#81D4FA",
3334
+ // Light Blue - pending sale
3335
+ Sold: "#f44336",
3336
+ // Red - sold
3337
+ Unavailable: "#757575",
3338
+ // Gray - not available
3339
+ Unknown: "#757575"
3340
+ // Gray - default fallback
3341
+ };
3342
+ var inventoryStatusColors = {
3343
+ "Ready Now": "#2E7D32",
3344
+ // Green - available immediately
3345
+ Upcoming: "#ED6C02",
3346
+ // Orange - coming soon
3347
+ default: "#757575"
3348
+ // Gray - unknown status
3349
+ };
3350
+ var lotSizeColors = {
3351
+ Small: "#2196f3",
3352
+ // Blue
3353
+ Medium: "#4caf50",
3354
+ // Green
3355
+ Large: "#ff9800",
3356
+ // Orange
3357
+ "Extra Large": "#f44336",
3358
+ // Red
3359
+ Unknown: "#757575"
3360
+ // Gray
3361
+ };
3362
+ function getContrastTextColor(backgroundColor) {
3363
+ const hex = backgroundColor.replace("#", "");
3364
+ const rgb = hex.match(/.{2}/g).map((c) => {
3365
+ const val = parseInt(c, 16) / 255;
3366
+ return val <= 0.03928 ? val / 12.92 : Math.pow((val + 0.055) / 1.055, 2.4);
3367
+ });
3368
+ const luminance = 0.2126 * rgb[0] + 0.7152 * rgb[1] + 0.0722 * rgb[2];
3369
+ return luminance > 0.179 ? "rgba(0, 0, 0, 0.87)" : "#ffffff";
3370
+ }
3371
+ function getAvailabilityColor(availability) {
3372
+ return lotAvailabilityColors[availability] ?? lotAvailabilityColors.Unknown;
3373
+ }
3374
+ function getSizeColor(size) {
3375
+ return lotSizeColors[size] ?? lotSizeColors.Unknown;
3376
+ }
3377
+ var clusterColors = {
3378
+ small: colors.teal[500],
3379
+ // #3ba4a7 - < 10 points
3380
+ medium: colors.navy[700],
3381
+ // #002e3f - 10-50 points
3382
+ large: colors.plum[700],
3383
+ // #5e2c41 - 50+ points
3384
+ stroke: colors.white,
3385
+ text: colors.white
3386
+ };
3387
+ var boundaryColors = {
3388
+ fill: "#C50F22",
3389
+ // Brand red
3390
+ line: "#C50F22",
3391
+ hoverFill: "#1976d2",
3392
+ defaultFill: "#4A90E2",
3393
+ hoverLine: "#1565c0",
3394
+ defaultLine: "#4A90E2"
3395
+ };
3396
+ var salesOfficeColor = "#C50F22";
3397
+ var nonMatchedColor = "#9e9e9e";
3398
+
3399
+ // src/colors/expressions.ts
3400
+ var lotAvailabilityColorExpression = createCategoricalColorExpression(
3401
+ "availability",
3402
+ lotAvailabilityColors,
3403
+ lotAvailabilityColors.Unknown
3404
+ );
3405
+ var inventoryStatusColorExpression = [
3406
+ "match",
3407
+ ["get", "status"],
3408
+ "Ready Now",
3409
+ inventoryStatusColors["Ready Now"],
3410
+ "Upcoming",
3411
+ inventoryStatusColors["Upcoming"],
3412
+ inventoryStatusColors.default
3413
+ ];
3414
+ var lotSizeColorExpression = createCategoricalColorExpression(
3415
+ "sizeCategory",
3416
+ lotSizeColors,
3417
+ lotSizeColors.Unknown
3418
+ );
3419
+ var clusterColorExpression = [
3420
+ "step",
3421
+ ["get", "point_count"],
3422
+ clusterColors.small,
3423
+ 10,
3424
+ clusterColors.medium,
3425
+ 50,
3426
+ clusterColors.large
3427
+ ];
3428
+ function createMatchedColorExpression(baseColorExpression, matchedProperty = "matched") {
3429
+ return [
3430
+ "case",
3431
+ ["coalesce", ["get", matchedProperty], true],
3432
+ baseColorExpression,
3433
+ nonMatchedColor
3434
+ ];
3435
+ }
3436
+
3437
+ export { BASE_OFFSET, BIKE_LANES, BUILTIN_BASEMAPS, BUILTIN_OVERLAY_LAYERS, CATEGORY_META, CITY_LIMITS, CLASSIC_DARK, CLASSIC_LIGHT, DEFAULT_SIMPLIFICATION_THRESHOLDS, FLOOD_ZONES, FREE_BASEMAPS, KEYBOARD_CONTROLS, MAPTILER_BASIC, MAPTILER_OUTDOOR, MAPTILER_SATELLITE, MAPTILER_STREETS, MARKER_PROTECTION_CLASS, OFFSET_CLASSES, OSM_STANDARD, PARKS, POSITION_CLASSES, SCHOOL_DISTRICTS, SPORTS_FACILITIES, STADIA_ALIDADE_DARK, STADIA_ALIDADE_SMOOTH, STADIA_STAMEN_TERRAIN, STADIA_STAMEN_TONER, STADIA_STAMEN_WATERCOLOR, TRAILS, TRANSIT_ROUTES, WATERSHEDS, ZONING_DISTRICTS, applyMarkerChildProtection, applyMarkerProtection, boundaryColors, boundsToPolygon, buildRTreeIndex, buildSpatialIndex, calculateBounds, calculateCentroid, calculateZoomThresholds, clusterColorExpression, clusterColors, combineBounds, computePositionClasses, computeVerticalOffsetStyle, countFeaturesByType, createCategoricalColorExpression, createCircleStyle, createContinuousColorExpression, createDynamicLODManager, createExtrusionHeightExpression, createExtrusionStyle, createFillStyle, createGeoJSONFingerprint, createHeatmapStyle, createHoverExpression, createIdleViewportManager, createInitialLayerStates, createInteractiveExpression, createInteractiveStatusColorExpression, createLineStyle, createLotFillStyle, createLotOutlineStyle, createMatchedColorExpression, createPredictiveViewportManager, createRTreeViewportManager, createSelectionExpression, createStatusColorExpression, createViewportManager, createViewportQuery, createZoomExpression, decimalToDMS, deepEqual, expandCluster, expandClusterToBounds, extendBounds, filterByGeometryType, filterEqual, fingerprintEqual, formatArea, formatBearing, formatBounds, formatCoordinates, formatDistance, formatFeatureProperties, formatLabel, formatPitch, formatPropertyValue, formatScale, formatZoom, generateBoundingPolygon, generateConvexHull, generateFeatureCollectionDescription, generateFeatureTable, generateKeyboardControlsDescription, generateLODData, generateLODDataWithSimplification, generateMapDescription, generateMarkerList, generateMarkersDescription, generateMoveAnnouncement, geoJSONEqual, getAvailabilityColor, getAvailableBasemaps, getChangedPaintProps, getClusterBounds, getClusterChildren, getClusterExpansionZoom, getClusterLeaves, getContrastTextColor, getHighlightStyle, getLayerCategories, getLayerStatesArray, getLayerStyleForTheme, getLayersByCategory, getLayersWithErrors, getSelectionStyle, getSimplificationToleranceForZoom, getSimplifiedFeaturesForZoom, getSizeColor, getVisibleLayerIds, groupFeaturesByProperty, groupLayersByCategory, hideAllLayers, inventoryStatusColorExpression, inventoryStatusColors, isAnyLayerLoading, isClusterFeature, isValidBounds, loadGeoJSON, lotAvailabilityColorExpression, lotAvailabilityColors, lotSizeColorExpression, lotSizeColors, nonMatchedColor, paintPropsEqual, queryByBounds, queryByBoundsWithStats, queryRTreeByBounds, queryRTreeByBoundsWithStats, removeMarkerProtection, reorderLayers, resolveBasemapStyle, resolveBasemapThumbnail, resolveLayerSourceUrl, salesOfficeColor, searchLayers, serializeFilter, setLayerError, setLayerLoading, setLayerOpacity, showAllLayers, simplifyFeature, simplifyFeatureCollection, simplifyFeatureCollectionWithStats, simplifyPolygon, toggleLayerVisibility, updateLayerState, validateGeoJSON, zoomToScale };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@classic-homes/maps-core",
3
- "version": "0.2.1",
3
+ "version": "0.2.2",
4
4
  "description": "Core utilities and theme for Classic Theme maps",
5
5
  "keywords": [
6
6
  "maps",