@tomhughes commented on this pull request.
> @@ -1,80 +1,200 @@
+/* global Popper */
Other global declarations are in `config/eslint.config.mjs` rather than being
done on a per-file basis like this?
>
- const updateMenu = function updateMenu() {
- map.contextmenu.setDisabled(2, map.getZoom() < 12);
- map.contextmenu.setDisabled(4, map.getZoom() < 14);
- };
+ OSM.renderContextMenu($contextMenu, contextmenuItems);
+};
+
+OSM.createSeparator = function () {
This (and `createMenuItem` and `renderContextMenu`) are only used from
`initializeContextMenu` at the moment so they could just be declared in there
rather than being exported in the `OSM` namespace unless you're expecting to be
using them somewhere else?
Though I guess they may go away if you switch to rendering the menu on the
server.
--
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/6410#pullrequestreview-3274933178
You are receiving this because you are subscribed to this thread.
Message ID:
<openstreetmap/openstreetmap-website/pull/6410/review/[email protected]>_______________________________________________
rails-dev mailing list
[email protected]
https://lists.openstreetmap.org/listinfo/rails-dev