All checks were successful
Deploy / Build and Deploy to Production (push) Successful in 19s
Implement Phase 1 of custom Kirby plugin for editing interactive maps: - OpenStreetMap base layer with MapLibre GL JS - Click to add markers, drag to reposition - Marker list sidebar with selection and deletion - Auto-save with debounce (YAML format) - Add marker button creates marker at current map center - Max 50 markers per map (configurable) - Clean UI with marker counter Blueprint updated to use new map-editor field type instead of placeholder. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
26 lines
701 B
PHP
26 lines
701 B
PHP
<?php
|
|
|
|
/**
|
|
* Map Editor Plugin for Kirby CMS
|
|
*
|
|
* Interactive map editor with MapLibre GL JS for creating
|
|
* print-ready maps with markers and rich content.
|
|
*/
|
|
|
|
Kirby::plugin('geoproject/map-editor', [
|
|
'fields' => [
|
|
'map-editor' => [
|
|
'props' => [
|
|
'defaultCenter' => function ($defaultCenter = [43.836699, 4.360054]) {
|
|
return $defaultCenter;
|
|
},
|
|
'defaultZoom' => function ($defaultZoom = 13) {
|
|
return $defaultZoom;
|
|
},
|
|
'maxMarkers' => function ($maxMarkers = 50) {
|
|
return $maxMarkers;
|
|
}
|
|
]
|
|
]
|
|
]
|
|
]);
|