mirror of
https://github.com/FoggedLens/iD.git
synced 2026-05-14 13:18:15 +02:00
+3
-2
@@ -1322,8 +1322,9 @@ text.pointlabel {
|
||||
}
|
||||
|
||||
/* Opera doesn't support dominant-baseline. See #715 */
|
||||
.opera .linelabel-halo .textpath,
|
||||
.opera .linelabel .textpath {
|
||||
/* Safari 10 seems to have regressed too */
|
||||
.linelabel-halo .textpath,
|
||||
.linelabel .textpath {
|
||||
baseline-shift: -33%;
|
||||
dominant-baseline: auto;
|
||||
}
|
||||
|
||||
@@ -15,6 +15,8 @@ import { utilDisplayName, utilEntitySelector } from '../util/index';
|
||||
|
||||
export function svgLabels(projection, context) {
|
||||
var path = d3.geoPath().projection(projection),
|
||||
detected = utilDetect(),
|
||||
baselineHack = (detected.ie || detected.browser.toLowerCase() === 'edge'),
|
||||
rdrawn = rbush(),
|
||||
rskipped = rbush(),
|
||||
textWidthCache = {},
|
||||
@@ -119,6 +121,7 @@ export function svgLabels(projection, context) {
|
||||
texts.enter()
|
||||
.append('text')
|
||||
.attr('class', function(d, i) { return classes + ' ' + labels[i].classes + ' ' + d.id; })
|
||||
.attr('dy', baselineHack ? '0.35em' : null)
|
||||
.append('textPath')
|
||||
.attr('class', 'textpath');
|
||||
|
||||
|
||||
+1
-6
@@ -2,12 +2,11 @@ import * as d3 from 'd3';
|
||||
import { d3keybinding } from '../lib/d3.keybinding.js';
|
||||
import { t, textDirection } from '../util/locale';
|
||||
import { tooltip } from '../util/tooltip';
|
||||
import { utilDetect } from '../util/detect';
|
||||
import { utilSetDimensions } from '../util/dimensions';
|
||||
|
||||
import { svgDefs, svgIcon } from '../svg/index';
|
||||
import { modeBrowse } from '../modes/index';
|
||||
import { behaviorHash } from '../behavior/index';
|
||||
import { utilSetDimensions } from '../util/dimensions';
|
||||
|
||||
import { uiAccount } from './account';
|
||||
import { uiAttribution } from './attribution';
|
||||
@@ -39,10 +38,6 @@ export function uiInit(context) {
|
||||
function render(container) {
|
||||
var map = context.map();
|
||||
|
||||
if (utilDetect().opera) {
|
||||
container.classed('opera', true);
|
||||
}
|
||||
|
||||
var hash = behaviorHash(context);
|
||||
hash();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user