import type { ColorToken } from './map.types'; /** * A named, toggleable layer of map content. * * @description * Deliberately **not** called `layers` — that prop already exists on `` and * means Google's native traffic / transit / bicycling overlays. Renaming it * would silently change the meaning of working code, so the new concept gets a * new name: `dataLayers`. * * Markers and geometries point at a layer through `layerId`; toggling the layer * shows or hides everything that belongs to it. */ export interface MapDataLayer { id: string; label: string; /** Optional heading used to group layers in the panel. */ group?: string; /** Swatch shown beside the label. */ colorToken?: ColorToken; /** @default true */ visible?: boolean; /** Stacking order for everything in the layer. Higher draws on top. */ zIndex?: number; /** Multiplies each feature's own opacity. @default 1 */ opacity?: number; } /** Resolved visibility per layer id. Features with no `layerId` are always visible. */ export type MapLayerVisibility = Record; export declare function resolveLayerVisibility(layers: MapDataLayer[] | undefined): MapLayerVisibility; export declare function isLayerVisible(layerId: string | undefined, visibility: MapLayerVisibility): boolean; export declare function layerById(layerId: string | undefined, layers: MapDataLayer[] | undefined): MapDataLayer | undefined; /** * Combines a feature's own opacity with its layer's. * * With four overlays stacked at once the effective opacity has to be a single * number, so layer and feature multiply rather than one overriding the other. */ export declare function effectiveOpacity(featureOpacity: number | undefined, layer: MapDataLayer | undefined): number; /** A feature's z-index falls back to its layer's. */ export declare function effectiveZIndex(featureZIndex: number | undefined, layer: MapDataLayer | undefined): number | undefined;