mirror of
https://github.com/FoggedLens/iD.git
synced 2026-05-15 05:30:35 +02:00
Refactor Entity, Node, Relation, Tags, Way from core to osm
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import * as d3 from 'd3';
|
||||
import { utilRebind } from '../../util/rebind';
|
||||
import { t } from '../../util/locale';
|
||||
import { coreOneWayTags } from '../../core/index';
|
||||
import { osmOneWayTags } from '../../osm/index';
|
||||
|
||||
export { uiFieldCheck as uiFieldDefaultcheck };
|
||||
|
||||
@@ -36,7 +36,7 @@ export function uiFieldCheck(field) {
|
||||
// where implied oneway tag exists (e.g. `junction=roundabout`) #2220, #1841
|
||||
if (field.id === 'oneway') {
|
||||
for (var key in entity.tags) {
|
||||
if (key in coreOneWayTags && (entity.tags[key] in coreOneWayTags[key])) {
|
||||
if (key in osmOneWayTags && (entity.tags[key] in osmOneWayTags[key])) {
|
||||
texts[0] = t('presets.fields.oneway_yes.options.undefined');
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -2,7 +2,7 @@ import * as d3 from 'd3';
|
||||
import { t } from '../../util/locale';
|
||||
|
||||
import { behaviorHover } from '../../behavior/index';
|
||||
import { coreEntity } from '../../core/index';
|
||||
import { osmEntity } from '../../osm/index';
|
||||
|
||||
import {
|
||||
actionRestrictTurn,
|
||||
@@ -128,7 +128,7 @@ export function uiFieldRestrictions(field, context) {
|
||||
|
||||
function click() {
|
||||
var datum = d3.event.target.__data__;
|
||||
if (datum instanceof coreEntity) {
|
||||
if (datum instanceof osmEntity) {
|
||||
fromNodeID = intersection.adjacentNodeId(datum.id);
|
||||
render();
|
||||
} else if (datum instanceof geoTurn) {
|
||||
|
||||
Reference in New Issue
Block a user