mirror of
https://github.com/FoggedLens/iD.git
synced 2026-02-13 17:23:02 +00:00
Yep, detecting opera.
Goal can be achieved with two different svg styles, but Opera only implements one, Firefox the other. Can't apply both because Chrome implements both.
This commit is contained in:
@@ -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,
|
||||
|
||||
@@ -127,6 +127,8 @@ iD.detect = function() {
|
||||
browser.support = true;
|
||||
}
|
||||
|
||||
browser.opera = ua.indexOf('Opera') >= 0;
|
||||
|
||||
browser.locale = navigator.language;
|
||||
|
||||
function nav(x) {
|
||||
|
||||
@@ -12,6 +12,8 @@ iD.ui = function(context) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (iD.detect().opera) container.classed('opera', true);
|
||||
|
||||
function hintprefix(x, y) {
|
||||
return '<span>' + y + '</span>' + '<div class="keyhint-wrap"><span class="keyhint"> ' + x + '</span></div>';
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user