InteractiveConfigSchema
constInteractiveConfigSchema:z.ZodType<{click?: {action?:string;emit?:EmitConfig;flyTo?: {center?: [number,number];duration?:number;zoom?:number; };popup?:any[];zoomToFeature?: {duration?:number;maxZoom?:number;padding?:number; }; };hover?: {cursor?:string;emit?:EmitConfig;highlight?:boolean;popup?:any[]; };mouseenter?: {action?:string; };mouseleave?: {action?:string; }; } |undefined>
Defined in: packages/core/src/schemas/layer.schema.ts:293
Interactive event configuration for layers.
Remarks
Section titled “Remarks”Defines hover and click behaviors for map features.
Events:
hover- Cursor and highlight on mouseoverclick- Popup, actions, or navigation on clickmouseenter- Custom action on mouse entermouseleave- Custom action on mouse leave
Examples
Section titled “Examples”Hover Cursor
interactive: hover: cursor: pointerClick Popup
interactive: click: popup: - h3: - property: name - p: - property: descriptionClick with FlyTo
interactive: click: flyTo: zoom: 15 duration: 1000