This lean and updated variant of #4777 follows the rules laid out in #5328 that were implemented in #5362. Since the editing of the user preference happens on a different view/site, there is no need to listen to color scheme changes on the fly and the whole logic can happen in the initialization of `L.OSM.TileLayer`. |Before|After| |-|-| |||
Additionally, a "dark" CSS class is introduced to allow better style targeting if the user wants to. for example like this:  You can view, comment on, or merge this pull request online at: https://github.com/openstreetmap/openstreetmap-website/pull/5396 -- Commit Summary -- * Add an OSM.isDarkMap() function * Use schemed map properties in L.OSM.TileLayer initialization * Add dark Transport map url * Use the schemed map urls * Set normal tile display as standard * Let the main map pass its filters to the keys -- File Changes -- M app/assets/javascripts/osm.js.erb (8) M app/assets/stylesheets/common.scss (2) M vendor/assets/leaflet/leaflet.osm.js (14) -- Patch Links -- https://github.com/openstreetmap/openstreetmap-website/pull/5396.patch https://github.com/openstreetmap/openstreetmap-website/pull/5396.diff -- Reply to this email directly or view it on GitHub: https://github.com/openstreetmap/openstreetmap-website/pull/5396 You are receiving this because you are subscribed to this thread. Message ID: <openstreetmap/openstreetmap-website/pull/5...@github.com>
_______________________________________________ rails-dev mailing list rails-dev@openstreetmap.org https://lists.openstreetmap.org/listinfo/rails-dev