Skip to content

Commit

Permalink
maps/react: fix widgets namespaces and JS
Browse files Browse the repository at this point in the history
  • Loading branch information
vellip committed Jan 30, 2025
1 parent 8bd36e4 commit 1a956e7
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
2 changes: 1 addition & 1 deletion meinberlin/react/contrib/map/react_choose_point_init.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import AddMarkerControl
from 'adhocracy4/adhocracy4/maps_react/static/a4maps_react/AddMarkerControl'

function init () {
ReactWidget.initialise('a4', 'choose-point', function (el) {
ReactWidget.initialise('a4', 'react-choose-point', function (el) {
const props = JSON.parse(el.getAttribute('data-attributes'))
const root = createRoot(el)
root.render(
Expand Down
10 changes: 9 additions & 1 deletion webpack.common.js
Original file line number Diff line number Diff line change
Expand Up @@ -184,14 +184,22 @@ module.exports = {
],
dependOn: 'adhocracy4'
},
a4maps_choose_point: {
a4maps_react_choose_point: {
import: [
'leaflet/dist/leaflet.css',
'maplibre-gl/dist/maplibre-gl.css',
'./meinberlin/react/contrib/map/react_choose_point_init.jsx'
],
dependOn: 'adhocracy4'
},
a4maps_choose_point: {
import: [
'leaflet/dist/leaflet.css',
'maplibre-gl/dist/maplibre-gl.css',
'adhocracy4/adhocracy4/maps/static/a4maps/a4maps_choose_point.js'
],
dependOn: 'adhocracy4'
},
a4maps_choose_polygon: {
import: [
'leaflet/dist/leaflet.css',
Expand Down

0 comments on commit 1a956e7

Please sign in to comment.