import Component from '@glimmer/component'; import MapboxGlLayer from '@prysmex-engineering/ember-mapbox-gl/components/mapbox-gl/layer'; import type Owner from '@ember/owner'; import type { WithBoundArgs } from '@glint/template'; import type MapCacheService from '@prysmex-engineering/ember-mapbox-gl/services/map-cache'; import type { Map as MapboxMap, SourceSpecification } from 'mapbox-gl'; /** * Adds a data source to the map. The API matches the mapbox [source docs](https://www.mapbox.com/mapbox-gl-js/api/#sources). * * Example: * ```hbs * * * * * * ``` * * @class MapboxGLSource * * An options hash to set as the source. * - #### `options.type` * - A string detailing the map source type. Typically `geojson`. * * - #### `options.data` * - A data hash for the map, following the source.data API detailed by mapbox docs. * @argument {Object} options * * The ID of the source to add. Must not conflict with existing sources. * {@link https://www.mapbox.com/mapbox-gl-js/api/#map#addsource Mapbox} * @argument {string} sourceId */ export interface MapboxGlSourceArgs { map: MapboxMap; options: SourceSpecification; sourceId?: string; cacheKey?: string; cache?: boolean; } export interface MapboxGlSourceYield { layer: WithBoundArgs; id: string; } export interface MapboxGlSourceSignature { Args: MapboxGlSourceArgs; Blocks: { default: [MapboxGlSourceYield]; }; } export default class MapboxGlSourceComponent extends Component { mapCache: MapCacheService; cacheKey: string | undefined; cache: boolean; get sourceId(): string; constructor(owner: Owner, args: MapboxGlSourceArgs); updateSource: void; willDestroy(): void; } //# sourceMappingURL=source.d.ts.map