diff --git a/css/map.css b/css/map.css index 885c8195c..bea6edde3 100644 --- a/css/map.css +++ b/css/map.css @@ -648,7 +648,13 @@ text.pointlabel { } .pathlabel .textpath { + dominant-baseline: middle; +} + +/* Opera doesn't support dominant-baseline */ +.opera .pathlabel .textpath { baseline-shift: -33%; + dominant-baseline: auto; } .pointlabel-halo, diff --git a/js/id/id.js b/js/id/id.js index 665e0b0a1..df986bc5f 100644 --- a/js/id/id.js +++ b/js/id/id.js @@ -127,6 +127,8 @@ iD.detect = function() { browser.support = true; } + browser.opera = ua.indexOf('Opera') >= 0; + browser.locale = navigator.language; function nav(x) { diff --git a/js/id/ui.js b/js/id/ui.js index 529d8bca5..ecab88470 100644 --- a/js/id/ui.js +++ b/js/id/ui.js @@ -12,6 +12,8 @@ iD.ui = function(context) { return; } + if (iD.detect().opera) container.classed('opera', true); + function hintprefix(x, y) { return '' + y + '' + '
' + x + '
'; }