import { CreateGeoJsonSourceActions } from '../composables'; import { GeoJSONSource, GeoJSONSourceSpecification } from 'maplibre-gl'; /** * Enhanced GeoJsonSource component props with comprehensive configuration options */ interface GeoJsonSourceProps { /** Unique identifier for the source */ id?: string; /** GeoJSON data for the source */ data?: GeoJSONSourceSpecification['data']; /** Additional source configuration options */ options?: Partial; /** Callback for registering source actions */ register?: (actions: CreateGeoJsonSourceActions) => void; /** Enable debug logging */ debug?: boolean; /** Automatically cleanup resources on unmount */ autoCleanup?: boolean; /** * Error handling callback. * * Not `onError`: this component also emits `error`, and Vue puts an emit's * handler on `$props` under that same `onError` key. One key for both meant * `@error="fn"` called `fn` twice -- once through the emit, once through * `props.onError` -- and made the two declarations intersect into a type no * handler satisfies. */ onSourceError?: (error: any) => void; /** Source load success callback. Named for the same reason as `onSourceError`. */ onSourceLoad?: (source: GeoJSONSource) => void; /** Data update callback */ onDataUpdate?: (data: GeoJSONSourceSpecification['data']) => void; /** Debounce delay for data updates in milliseconds (default: 100) */ debounceDelay?: number; } /** * Enhanced data setter with validation and error handling * @param newData - New GeoJSON data to set */ declare function handleSetData(newData: GeoJSONSourceSpecification['data']): void; /** * Enhanced cleanup function for disposing resources */ declare function cleanup(): void; declare function __VLS_template(): { default?(_: {}): any; }; declare const __VLS_component: import('vue').DefineComponent, { data: () => { type: string; features: never[]; }; options: () => {}; debug: boolean; autoCleanup: boolean; debounceDelay: number; }>>, { sourceId: string; getSource: import('vue').ShallowRef>; setData: typeof handleSetData; removeSource: () => void; refreshSource: () => void; sourceStatus: import('vue').ComputedRef; isSourceReady: import('vue').ComputedRef; isSourceRegistered: import('vue').Ref; isDataValid: import('vue').ComputedRef; lastDataUpdate: import('vue').ShallowRef | undefined, string | import('geojson').GeoJSON | undefined>; cleanup: typeof cleanup; }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, { register: (actions: CreateGeoJsonSourceActions) => void; error: (error: any) => void; load: (source: any) => void; "data-update": (data: string | import('geojson').GeoJSON) => void; }, string, import('vue').PublicProps, Readonly, { data: () => { type: string; features: never[]; }; options: () => {}; debug: boolean; autoCleanup: boolean; debounceDelay: number; }>>> & Readonly<{ onError?: ((error: any) => any) | undefined; onLoad?: ((source: any) => any) | undefined; onRegister?: ((actions: CreateGeoJsonSourceActions) => any) | undefined; "onData-update"?: ((data: string | import('geojson').GeoJSON) => any) | undefined; }>, { data: GeoJSONSourceSpecification["data"]; debug: boolean; autoCleanup: boolean; options: Partial; debounceDelay: number; }, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>; declare const _default: __VLS_WithTemplateSlots>; export default _default; type __VLS_NonUndefinedable = T extends undefined ? never : T; type __VLS_TypePropsToRuntimeProps = { [K in keyof T]-?: {} extends Pick ? { type: import('vue').PropType<__VLS_NonUndefinedable>; } : { type: import('vue').PropType; required: true; }; }; type __VLS_WithDefaults = { [K in keyof Pick]: K extends keyof D ? __VLS_Prettify : P[K]; }; type __VLS_Prettify = { [K in keyof T]: T[K]; } & {}; type __VLS_WithTemplateSlots = T & { new (): { $slots: S; }; };