Fix the seemingly safe spellings found by codespell

Untested, only checked by inspection.
This commit is contained in:
Peter Newman
2020-06-28 23:06:44 +01:00
parent 977c15fe54
commit 2c47a11008
49 changed files with 87 additions and 87 deletions
+2 -2
View File
@@ -177,7 +177,7 @@ iD is written in a modular style and bundled with [rollup.js](http://rollupjs.or
which makes hot code replacement tricky. (ES6 module exports are
[immutable live bindings](http://www.2ality.com/2015/07/es6-module-exports.html)).
Because of this, the parts of iD which are designed for customization are exported
as live bound objects that can be overriden at runtime _before initializing the iD context_.
as live bound objects that can be overridden at runtime _before initializing the iD context_.
### Services
@@ -219,7 +219,7 @@ iD.fileFetcher.cache().imagery = [{
```
Each imagery source should have the following properties:
* `id` - Unique identifier for this source (also used as a url paramater)
* `id` - Unique identifier for this source (also used as a url parameter)
* `name` - Display name for the source
* `type` - Source type, currently only `tms` is supported
* `template` - Url template, valid replacement tokens include:
+1 -1
View File
@@ -440,7 +440,7 @@ A one-way line does not have a valid connection at its first or last node.
##### `incompatible_source`
The `source` tag of a feature references a data source known to have a license incompatiable with OpenStreetMap. This is very much not exhaustive and currently only flags sources containing "google".
The `source` tag of a feature references a data source known to have a license incompatible with OpenStreetMap. This is very much not exhaustive and currently only flags sources containing "google".
##### `invalid_format`
+10 -10
View File
@@ -830,7 +830,7 @@ _Press <kbd>G</kbd> to toggle change highlighting._
* Fix error upon changing the Unsquare Building threshold ([#6690])
* Don't hide all multilingual names upon deleting one ([#6491])
* Correctly populate the Bike Lanes field with existing values ([#6141])
* Show the correct location for coordinates in the `N DD° MM.MMM' W DD° MM.MMM'` format without a commma separator ([#6582])
* Show the correct location for coordinates in the `N DD° MM.MMM' W DD° MM.MMM'` format without a comma separator ([#6582])
* Don't treat platforms with a `kerb` tag as primarily curbs ([#6742])
* Remove deleted features from the map immediately when undoing or redoing ([#6480])
* Properly resize Mapillary and Bing Streetside photos when resizing the viewer ([#6286])
@@ -1433,7 +1433,7 @@ _Map all the branded businesses in your town!_
[#5901]: https://github.com/openstreetmap/iD/issues/5901
#### :mortar_board: Walkthrough / Help
- Make the keyboard shorcuts viewable on narrow window sizes ([#6174])
- Make the keyboard shortcuts viewable on narrow window sizes ([#6174])
[#6174]: https://github.com/openstreetmap/iD/issues/6174
@@ -1607,7 +1607,7 @@ _Map all the branded businesses in your town!_
[#5979]: https://github.com/openstreetmap/iD/issues/5979
#### :rocket: Presets
* Add Bar field to Restuarant, Cafe, and Hotel ([#5947], [#5970], thanks [@alphagamer7])
* Add Bar field to Restaurant, Cafe, and Hotel ([#5947], [#5970], thanks [@alphagamer7])
* Rename Jeweler to Jewelry Store ([#5948])
* Add unsearchable generic Boundary preset ([#5975])
* Don't render roads with a "footway" tag too thin ([#5936])
@@ -1932,7 +1932,7 @@ _Click the new "zoom to" link on the sidebar under the preset icon, or press <kb
#### :sparkles: Usability
* Open the combobox when clicking anywhere in the text field ([#5596], [#5636], thanks [@maxgrossman])
* Add close buttom to the save sidebar ([#5614], [#5622], thanks [@maxgrossman])
* Add close button to the save sidebar ([#5614], [#5622], thanks [@maxgrossman])
* Render reservoirs and fountains with the water fill pattern ([#5606], thanks [@RudyTheDev])
* Render marine barriers with a blue stroke ([#5606], thanks [@RudyTheDev])
* Press enter to submit values in combo fields without deselecting the feature ([#5725])
@@ -3488,7 +3488,7 @@ _Check out the new help texts by opening the Help pane (shortcut <kbd>H</kbd>)._
* Add Retail Building to buildings, switch Commercial icon to suitcase ([#4590])
* Change tourist attraction icon from monument to star ([#4563], [#4584], thanks [@lucymk])
* Add preset for `man_made=monitoring_station` ([#4581], thanks [@abdeldjalil09])
* Deprectate (i.e. make non-searchable) `office=administrative` ([#4578])
* Deprecate (i.e. make non-searchable) `office=administrative` ([#4578])
* Update transit-related presets for Public Transport v2 schema ([#3041], [#3508], [#4566], [#4585])
* Changed Marketplace preset to not default to `building=yes` ([#4559], [#4568], thanks [@tastrax])
* Add preset for `railway=miniature` ([#4555], thanks [@tastrax])
@@ -5025,7 +5025,7 @@ _Map traffic signals, stop signs, benches, crossings, street lamps, fountains, t
##### 2016-Mar-18
* Avoid jumpiness when dragging node markers (#3003)
* Rename "Dock" -> "Wet Dock / Dry Dock" (#3030)
* Refresh lables when switching to a new GPX file (#3032)
* Refresh labels when switching to a new GPX file (#3032)
* Fix bug where adding a space to a name would undo a previous edit (#3035)
* Display GPX tracks immediately when loaded or toggled (#3027)
* Include "Local GPX" in imagery used list when GPX loaded via url parameter (#2804)
@@ -5077,13 +5077,13 @@ _Map traffic signals, stop signs, benches, crossings, street lamps, fountains, t
* Add 'building' combo field for ice rink and swim facility
* Building field should be combo not typeCombo (because `building=yes` is a valid tag)
* Link to wiki for guidance on good changeset comments (#2923, thanks @kepta)
* Make preset fields section collapsable (#2894)
* Make preset fields section collapsible (#2894)
* Make sure DrawLine mode is called with a clean pre-operation graph (#2303, thanks @tyrasd)
* Default to user's language when localizing names (#2882, thanks @kepta)
* Autocomplete changeset comments from previous changeset comments (#2002, thanks @jfirebaugh)
* Add universal multiline text field for description, fixme (#1518)
* Fix crash when selecting a category preset with enter button
* Remove overly agressive regexes for cleaning up websites and emails (#2892, thanks @kepta)
* Remove overly aggressive regexes for cleaning up websites and emails (#2892, thanks @kepta)
* Correct typo "Platic" -> "Plastic" (#2925, thanks @M1dgard)
* Rename "Unclassified Road" to "Minor Road" (#2916)
@@ -5433,7 +5433,7 @@ _Map traffic signals, stop signs, benches, crossings, street lamps, fountains, t
##### 2014-Mar-28
* Disable circularize and orthogonalize operations when way is <80% contained in the viewport
* Add place=neighbourhood preset
* Add denomination=* field for cemetary, graveyard, funeral home
* Add denomination=* field for cemetery, graveyard, funeral home
* Add preset for shop=funeral_directors
* Add icon for public_transport=stop_position
* Support quartile scheme for any imagery source (#2112)
@@ -5451,7 +5451,7 @@ _Map traffic signals, stop signs, benches, crossings, street lamps, fountains, t
* Add amenity=nightclub
* Add smoking field for many presets under amenity, building, office, tourism (#1990)
* barrier=fence shouldn't be an area (fixes #2158)
* Remove building_area from hospital, school, kindergarden
* Remove building_area from hospital, school, kindergarten
* Fix recycling field keys (#2140)
+1 -1
View File
@@ -1,5 +1,5 @@
/* narrow width miscellanous things */
/* narrow width miscellaneous things */
path.line.shadow.tag-aerialway,
path.line.shadow.tag-attraction-summer_toboggan,
path.line.shadow.tag-attraction-water_slide,
+1 -1
View File
@@ -727,7 +727,7 @@ button.add-note svg.icon {
justify-content: flex-end;
}
/* Hide/Toggle collapsable sections (aka Disclosure)
/* Hide/Toggle collapsible sections (aka Disclosure)
------------------------------------------------------- */
.hide-toggle .icon.pre-text {
vertical-align: text-top;
+2 -2
View File
@@ -30,7 +30,7 @@ A basic preset is of the form:
],
// The geometry types for which this preset is valid.
// options are point, area, line, and vertex.
// vertexes are points that are parts of lines, like the nodes in a road
// vertices are points that are parts of lines, like the nodes in a road
// lines are unclosed ways, and areas are closed ways
"geometry": [
"point", "area"
@@ -379,7 +379,7 @@ For combo fields, spaces are replaced with underscores in the tag value if `snak
##### `caseSensitive`
For combo fields, case-sensitve field values are allowed if `caseSensitive` is `true`. The default is `false`.
For combo fields, case-sensitive field values are allowed if `caseSensitive` is `true`. The default is `false`.
##### `min_value`
@@ -4,5 +4,5 @@
"reference": {
"key": "healthcare"
},
"label": "Specialties"
"label": "Specialities"
}
@@ -30,7 +30,7 @@
"point"
],
"terms": [
"kindergarden",
"kindergarten",
"pre-school"
],
"tags": {
@@ -8,7 +8,7 @@
},
"terms": [
"agriculture",
"auxilary",
"auxiliary",
"chicken coop",
"farm auxiliary",
"pigsty",
@@ -4,7 +4,7 @@
"area"
],
"terms": [
"kindergarden",
"kindergarten",
"pre-school"
],
"tags": {
+1 -1
View File
@@ -11,7 +11,7 @@
"terms": [
"DVD",
"VHS",
"video casette"
"video cassette"
],
"tags": {
"shop": "video"
@@ -19,7 +19,7 @@
},
"terms": [
"Street Artwork",
"Guerilla Artwork",
"Guerrilla Artwork",
"Graffiti Artwork"
],
"name": "Graffiti"
+5 -5
View File
@@ -40,7 +40,7 @@ export function actionCircularize(wayId, projection, maxAngle) {
var sign = d3_polygonArea(points) > 0 ? 1 : -1;
var ids, i, j, k;
// we need atleast two key nodes for the algorithm to work
// we need at least two key nodes for the algorithm to work
if (!keyNodes.length) {
keyNodes = [nodes[0]];
keyPoints = [points[0]];
@@ -55,8 +55,8 @@ export function actionCircularize(wayId, projection, maxAngle) {
}
// key points and nodes are those connected to the ways,
// they are projected onto the circle, inbetween nodes are moved
// to constant intervals between key nodes, extra inbetween nodes are
// they are projected onto the circle, in between nodes are moved
// to constant intervals between key nodes, extra in between nodes are
// added if necessary.
for (i = 0; i < keyPoints.length; i++) {
var nextKeyNodeIndex = (i + 1) % keyNodes.length;
@@ -119,7 +119,7 @@ export function actionCircularize(wayId, projection, maxAngle) {
graph = graph.replace(node);
}
// add new inbetween nodes if necessary
// add new in between nodes if necessary
for (j = 0; j < numberNewPoints; j++) {
angle = startAngle + (indexRange + j) * eachAngle;
loc = projection.invert([
@@ -147,7 +147,7 @@ export function actionCircularize(wayId, projection, maxAngle) {
// Check for other ways that share these keyNodes..
// If keyNodes are adjacent in both ways,
// we can add inBetween nodes to that shared way too..
// we can add inBetweenNodes to that shared way too..
if (indexRange === 1 && inBetweenNodes.length) {
var startIndex1 = way.nodes.lastIndexOf(startNode.id);
var endIndex1 = way.nodes.lastIndexOf(endNode.id);
+1 -1
View File
@@ -13,7 +13,7 @@ export function actionDeleteMultiple(ids) {
var action = function(graph) {
ids.forEach(function(id) {
if (graph.hasEntity(id)) { // It may have been deleted aready.
if (graph.hasEntity(id)) { // It may have been deleted already.
graph = actions[graph.entity(id).type](id)(graph);
}
});
+1 -1
View File
@@ -1,7 +1,7 @@
import { osmNode } from '../osm/node';
// Disconect the ways at the given node.
// Disconnect the ways at the given node.
//
// Optionally, disconnect only the given ways.
//
+1 -1
View File
@@ -167,7 +167,7 @@ export function behaviorDrawWay(context, wayID, mode, startGraph) {
if (includeDrawNode) {
if (parentWay.isClosed()) {
// don't test the last segment for closed ways - #4655
// (still test the first segement)
// (still test the first segment)
nodes.pop();
}
} else { // discount the draw node
+1 -1
View File
@@ -156,7 +156,7 @@ export function behaviorHash(context) {
var maxdist = 500;
// Don't allow the hash location to change too much while drawing
// This can happen if the user accidently hit the back button. #3996
// This can happen if the user accidentally hit the back button. #3996
if (mode && mode.id.match(/^draw/) !== null && dist > maxdist) {
context.enter(modeBrowse(context));
return;
+4 -4
View File
@@ -60,7 +60,7 @@ export function coreLocalizer() {
if (_loadPromise) return _loadPromise;
return _loadPromise = Promise.all([
// load the list of langauges
// load the list of languages
fileFetcher.get('languages'),
// load the list of supported locales
fileFetcher.get('locales')
@@ -237,7 +237,7 @@ export function coreLocalizer() {
localizer.languageName = (code, options) => {
if (_languageNames[code]) { // name in locale langauge
if (_languageNames[code]) { // name in locale language
// e.g. "German"
return _languageNames[code];
}
@@ -252,9 +252,9 @@ export function coreLocalizer() {
return localizer.t('translate.language_and_code', { language: langInfo.nativeName, code: code });
} else if (langInfo.base && langInfo.script) {
const base = langInfo.base; // the code of the langauge this is based on
const base = langInfo.base; // the code of the language this is based on
if (_languageNames[base]) { // base language name in locale langauge
if (_languageNames[base]) { // base language name in locale language
const scriptCode = langInfo.script;
const script = _scriptNames[scriptCode] || scriptCode;
// e.g. "Serbian (Cyrillic)"
+1 -1
View File
@@ -26,7 +26,7 @@ export function coreTree(head) {
function segmentBBox(segment) {
var extent = segment.extent(head);
// extent can be null if the node entites aren't in the graph for some reason
// extent can be null if the node entities aren't in the graph for some reason
if (!extent) return null;
var bbox = extent.bbox();
+1 -1
View File
@@ -413,7 +413,7 @@ export function coreValidator(context) {
.on('redone.validator', validator.validate); // redo
// but not on 'change' (e.g. while drawing)
// When user chages editing modes:
// When user changes editing modes:
context
.on('exit.validator', validator.validate);
+1 -1
View File
@@ -324,7 +324,7 @@ export function modeDragNode(context) {
for (k = 0; k < rings.length; k++) {
if (k === activeIndex) continue;
// make sure active ring doesnt cross passive rings
// make sure active ring doesn't cross passive rings
if (geoHasLineIntersections(rings[activeIndex].nodes, rings[k].nodes, entity.id)) {
return 'multipolygonRing';
}
+1 -1
View File
@@ -92,7 +92,7 @@ export function modeSelect(context, selectedIDs) {
for (var i = 0; i < selectedIDs.length; i++) {
var entity = context.hasEntity(selectedIDs[i]);
if (!entity || entity.geometry(graph) !== 'vertex') {
return []; // selection includes some not vertexes
return []; // selection includes some not vertices
}
var currParents = graph.parentWays(entity).map(function(w) { return w.id; });
+1 -1
View File
@@ -20,7 +20,7 @@ export class QAItem {
}
update(props) {
// You can't override this inital information
// You can't override this initial information
const { loc, service, itemType, id } = this;
Object.keys(props).forEach(prop => this[prop] = props[prop]);
+1 -1
View File
@@ -91,7 +91,7 @@ export function presetPreset(presetID, preset, addable, allFields, allPresets) {
if (_this.suggestion) {
let path = presetID.split('/');
path.pop(); // remove brand name
// NOTE: insert an en-dash, not a hypen (to avoid conflict with fr - nl names in Brussels etc)
// NOTE: insert an en-dash, not a hyphen (to avoid conflict with fr - nl names in Brussels etc)
return _this.originalName + ' ' + t('presets.presets.' + path.join('/') + '.name');
}
return _this.t('name', { 'default': _this.originalName });
+1 -1
View File
@@ -500,7 +500,7 @@ export function rendererMap(context) {
);
// On Firefox Windows and Linux we always get +/- the scroll line amount (default 3)
// There doesn't seem to be any scroll accelleration.
// There doesn't seem to be any scroll acceleration.
// This multiplier increases the speed a little bit - #5512
if (detected.os !== 'mac') {
dY *= 5;
+1 -1
View File
@@ -104,7 +104,7 @@ function cardinalDirection(bearing) {
return t(`QA.improveOSM.directions.${compass[dir]}`);
}
// Errors shouldn't obscure eachother
// Errors shouldn't obscure each other
function preventCoincident(loc, bumpUp) {
let coincident = false;
do {
+1 -1
View File
@@ -519,7 +519,7 @@ export default {
//
// There is some logic here to batch up clicks into a _mlyClicks array
// because the user might click on a lot of markers quickly and nodechanged
// may be called out of order asychronously.
// may be called out of order asynchronously.
//
// Clicks are added to the array in `selectedImage` and removed here.
//
+1 -1
View File
@@ -949,7 +949,7 @@ export default {
// Calls `status` and dispatches an `apiStatusChange` event if the returned
// status differs from the cached status.
reloadApiStatus: function() {
// throttle to avoid unncessary API calls
// throttle to avoid unnecessary API calls
if (!this.throttledReloadApiStatus) {
var that = this;
this.throttledReloadApiStatus = _throttle(function() {
+1 -1
View File
@@ -49,7 +49,7 @@ function updateRtree(item, replace) {
}
}
// Issues shouldn't obscure eachother
// Issues shouldn't obscure each other
function preventCoincident(loc) {
let coincident = false;
do {
+1 -1
View File
@@ -33,7 +33,7 @@ export default {
type: 'item',
// the language to search
language: lang,
// the langauge for the label and description in the result
// the language for the label and description in the result
uselang: lang,
limit: 10,
origin: '*'
+1 -1
View File
@@ -262,7 +262,7 @@ export function svgStreetside(projection, context, dispatch) {
/**
* drawImages()
* drawImages is the method that is returned (and that runs) everytime 'svgStreetside()' is called.
* drawImages is the method that is returned (and that runs) every time 'svgStreetside()' is called.
* 'svgStreetside()' is called from index.js
*/
function drawImages(selection) {
+2 -2
View File
@@ -304,7 +304,7 @@ export function svgVertices(projection, context) {
function addChildVertices(entity) {
// avoid redunant work and infinite recursion of circular relations
// avoid redundant work and infinite recursion of circular relations
if (seenIds[entity.id]) return;
seenIds[entity.id] = true;
@@ -368,7 +368,7 @@ export function svgVertices(projection, context) {
}
// Collect important vertices from the `entities` list..
// (during a paritial redraw, it will not contain everything)
// (during a partial redraw, it will not contain everything)
for (var i = 0; i < entities.length; i++) {
var entity = entities[i];
var geometry = entity.geometry(graph);
+1 -1
View File
@@ -304,7 +304,7 @@ export function uiFieldLocalized(field, context) {
}
// Remove whatever is after the last ' '
// NOTE: split/join on en-dash, not a hypen (to avoid conflict with fr - nl names in Brussels etc)
// NOTE: split/join on en-dash, not a hyphen (to avoid conflict with fr - nl names in Brussels etc)
function cleanName(name) {
var parts = name.split(' ');
if (parts.length > 1) {
+2 -2
View File
@@ -65,7 +65,7 @@ export function uiOsmoseDetails(context) {
.append('div')
.attr('class', 'qa-details-subsection');
// Suggested Fix (musn't exist for every issue type)
// Suggested Fix (mustn't exist for every issue type)
if (issueString(_qaItem, 'fix')) {
const div = detailsEnter
.append('div')
@@ -83,7 +83,7 @@ export function uiOsmoseDetails(context) {
.attr('target', '_blank');
}
// Common Pitfalls (musn't exist for every issue type)
// Common Pitfalls (mustn't exist for every issue type)
if (issueString(_qaItem, 'trap')) {
const div = detailsEnter
.append('div')
+1 -1
View File
@@ -128,7 +128,7 @@ export function uiPanelBackground(context) {
.selectAll('.background-info-span-vintage')
.text(metadata.vintage);
// update other metdata
// update other metadata
metadataKeys.forEach(function(k) {
if (k === 'zoom' || k === 'vintage') return; // done already
var val = result[k];
+1 -1
View File
@@ -386,7 +386,7 @@ export function uiPresetList(context) {
.append('div')
.attr('class', 'label-inner');
// NOTE: split/join on en-dash, not a hypen (to avoid conflict with fr - nl names in Brussels etc)
// NOTE: split/join on en-dash, not a hyphen (to avoid conflict with fr - nl names in Brussels etc)
label.selectAll('.namepart')
.data(preset.name().split(' '))
.enter()
+1 -1
View File
@@ -95,7 +95,7 @@ export function uiSectionFeatureType(context) {
.preset(_presets.length === 1 ? _presets[0] : presetManager.item('point'))
);
// NOTE: split on en-dash, not a hypen (to avoid conflict with hyphenated names)
// NOTE: split on en-dash, not a hyphen (to avoid conflict with hyphenated names)
var names = _presets.length === 1 ? _presets[0].name().split(' ') : [t('inspector.multiple_types')];
var label = selection.select('.label-inner');
+2 -2
View File
@@ -63,7 +63,7 @@ export function uiSectionRawMembershipEditor(context) {
function changeRole(d) {
if (d === 0) return; // called on newrow (shoudn't happen)
if (d === 0) return; // called on newrow (shouldn't happen)
if (_inChange) return; // avoid accidental recursive call #5731
var oldRole = d.member.role;
@@ -107,7 +107,7 @@ export function uiSectionRawMembershipEditor(context) {
function deleteMembership(d) {
this.blur(); // avoid keeping focus on the button
if (d === 0) return; // called on newrow (shoudn't happen)
if (d === 0) return; // called on newrow (shouldn't happen)
// remove the hover-highlight styling
utilHighlightEntities([d.relation.id], false, context);
+3 -3
View File
@@ -170,11 +170,11 @@ export function validationAlmostJunction(context) {
return false;
}
let occurences = 0;
let occurrences = 0;
for (const index in way.nodes) {
if (way.nodes[index] === node.id) {
occurences += 1;
if (occurences > 1) {
occurrences += 1;
if (occurrences > 1) {
return false;
}
}
+2 -2
View File
@@ -453,12 +453,12 @@ export function validationCrossingWays(context) {
} else if (context.graph().geometry(this.entityIds[0]) === 'line' &&
context.graph().geometry(this.entityIds[1]) === 'line') {
// don't recommend adding bridges to waterways since they're uncommmon
// don't recommend adding bridges to waterways since they're uncommon
if (allowsBridge(selectedFeatureType) && selectedFeatureType !== 'waterway') {
fixes.push(makeAddBridgeOrTunnelFix('add_a_bridge', 'temaki-bridge', 'bridge'));
}
// don't recommend adding tunnels under waterways since they're uncommmon
// don't recommend adding tunnels under waterways since they're uncommon
var skipTunnelFix = otherFeatureType === 'waterway' && selectedFeatureType !== 'waterway';
if (allowsTunnel(selectedFeatureType) && !skipTunnelFix) {
fixes.push(makeAddBridgeOrTunnelFix('add_a_tunnel', 'temaki-tunnel', 'tunnel'));
+3 -3
View File
@@ -46,11 +46,11 @@ export function validationImpossibleOneway() {
}
function nodeOccursMoreThanOnce(way, nodeID) {
var occurences = 0;
var occurrences = 0;
for (var index in way.nodes) {
if (way.nodes[index] === nodeID) {
occurences += 1;
if (occurences > 1) return true;
occurrences += 1;
if (occurrences > 1) return true;
}
}
return false;
+5 -5
View File
@@ -210,7 +210,7 @@ describe('iD.actionDisconnect', function () {
});
it('replaces later occurrences in a self-intersecting way', function() {
// Situtation:
// Situation:
// a --- b
// \ /
// \ /
@@ -233,7 +233,7 @@ describe('iD.actionDisconnect', function () {
});
it('disconnects a way with multiple intersection points', function() {
// Situtation:
// Situation:
// a == b -- c
// | |
// e -- d
@@ -264,7 +264,7 @@ describe('iD.actionDisconnect', function () {
});
it('disconnects a shared non-closing node in an area', function() {
// Situtation:
// Situation:
// a -- b -- c
// | |
// e -- d
@@ -291,7 +291,7 @@ describe('iD.actionDisconnect', function () {
});
it('disconnects the closing node of an area without breaking the area', function() {
// Situtation:
// Situation:
// a --- b --- d
// \ / \ /
// \ / \ /
@@ -324,7 +324,7 @@ describe('iD.actionDisconnect', function () {
});
it('disconnects multiple closing nodes of multiple areas without breaking the areas', function() {
// Situtation:
// Situation:
// a --- b --- d
// \ / \ /
// \ / \ /
+1 -1
View File
@@ -28,7 +28,7 @@ describe('iD.actionRevert', function() {
describe('reverting way child nodes', function () {
it('removes new node, updates parent way nodelist', function() {
// note: test with a 3 node way so w1 doesnt go degenerate..
// note: test with a 3 node way so w1 doesn't go degenerate..
var n1 = iD.osmNode({id: 'n1'}),
n2 = iD.osmNode({id: 'n2'}),
n3 = iD.osmNode({id: 'n-3'}),
+1 -1
View File
@@ -64,7 +64,7 @@ describe('iD.actionUpgradeTags', function () {
expect(graph.entity(entity.id).tags).to.eql({ shop: 'supermarket', name: 'Foo' });
});
it('upgrades a tag with a wildcard replacement and replaces the exisiting "no" value', function () {
it('upgrades a tag with a wildcard replacement and replaces the existing "no" value', function () {
var oldTags = { amenity: 'shop' },
newTags = { shop: '*' },
entity = iD.osmEntity({ tags: { amenity: 'shop', shop: 'no', name: 'Foo' }}),
+1 -1
View File
@@ -104,7 +104,7 @@ describe('iD.geo - geography', function() {
var b = [0, 0];
expect(iD.geoSphericalDistance(a, b)).to.eql(0);
});
it('a straight 1 degree line at the equator is aproximately 111 km', function() {
it('a straight 1 degree line at the equator is approximately 111 km', function() {
var a = [0, 0];
var b = [1, 0];
expect(iD.geoSphericalDistance(a, b)).to.be.closeTo(110946, 10);
+2 -2
View File
@@ -91,12 +91,12 @@ describe('iD.operationStraighten', function () {
expect(result).to.be.ok;
});
it('is available for 2 selected nodes in non-adjacent ways, providing inbetween ways are selected', function () {
it('is available for 2 selected nodes in non-adjacent ways, providing in between ways are selected', function () {
var result = iD.operationStraighten(fakeContext, ['n2', 'n7', 'w4', 'w1', 'w3', 'w2']).available();
expect(result).to.be.ok;
});
it('is available for 2 selected nodes in non-adjacent, non-same-directional ways, providing inbetween ways are selected', function () {
it('is available for 2 selected nodes in non-adjacent, non-same-directional ways, providing in between ways are selected', function () {
var result = iD.operationStraighten(fakeContext, ['n2', 'n7', 'w4', 'w1', 'w3', 'w2-2']).available();
expect(result).to.be.ok;
});
+4 -4
View File
@@ -419,7 +419,7 @@ describe('iD.Lanes', function() {
expect(bothways.length).to.eql(0);
});
it('should have corrent number of direction elements', function() {
it('should have correct number of direction elements', function() {
var lanes = iD.osmWay({tags: { highway: 'residential', lanes: 5, 'lanes:backward': 1, 'lanes:both_ways': 1 }}).lanes().lanes;
var forward = lanes.filter(function(l) {
return l.direction === 'forward';
@@ -1018,7 +1018,7 @@ describe('iD.Lanes', function() {
highway: 'residential',
lanes: 5,
maxspeed: '30kmh',
'maxspeed:lanes': '30|40|fourty|40|40'
'maxspeed:lanes': '30|40|forty|40|40'
}
}).lanes().metadata.maxspeedLanes;
expect(maxspeedLanes.unspecified).to.deep.equal([
@@ -1029,7 +1029,7 @@ describe('iD.Lanes', function() {
highway: 'residential',
lanes: 5,
maxspeed: '30kmh',
'maxspeed:lanes': '30|40|fourty|40|random'
'maxspeed:lanes': '30|40|forty|40|random'
}
}).lanes().metadata.maxspeedLanes;
@@ -1057,7 +1057,7 @@ describe('iD.Lanes', function() {
highway: 'residential',
lanes: 5,
maxspeed: '30kmh',
'maxspeed:lanes': '30|40|fourty|40|40'
'maxspeed:lanes': '30|40|forty|40|40'
}
}).lanes().lanes;
var maxspeedLanes = lanes.unspecified.map(function (l) {
+1 -1
View File
@@ -261,7 +261,7 @@ describe('iD.serviceTaginfo', function() {
server.respondWith('GET', /\/key\/values/,
[200, { 'Content-Type': 'application/json' },
'{"data":[{"value":"parking","description":"A place for parking cars", "fraction":0.2},'
+ '{"value":"PArking","description":"A common mispelling", "fraction":0.2},'
+ '{"value":"PArking","description":"A common misspelling", "fraction":0.2},'
+ '{"value":"parking;partying","description":"A place for parking cars *and* partying", "fraction":0.2},'
+ '{"value":"parking, partying","description":"A place for parking cars *and* partying", "fraction":0.2},'
+ '{"value":"*","description":"", "fraction":0.2}]}']
+5 -5
View File
@@ -17,7 +17,7 @@ describe('iD.validations.almost_junction', function () {
iD.actionAddEntity(w1)
);
// vertical road to the west of w1 by 0.00001 logitude degree
// vertical road to the west of w1 by 0.00001 longitude degree
// 5th digit after decimal point has a resolution of ~1 meter
var n3 = iD.osmNode({id: 'n-3', loc: [22.42356, 0.001]});
var n4 = iD.osmNode({id: 'n-4', loc: [22.42356, -0.001]});
@@ -42,7 +42,7 @@ describe('iD.validations.almost_junction', function () {
iD.actionAddEntity(w1)
);
// tilted road to the west of w1 by 0.00001 logitude degree
// tilted road to the west of w1 by 0.00001 longitude degree
var n3 = iD.osmNode({id: 'n-3', loc: [22.423555, 0.001]});
var n4 = iD.osmNode({id: 'n-4', loc: [22.423565, -0.001]});
var w2 = iD.osmWay({id: 'w-2', nodes: ['n-3', 'n-4'], tags: { highway: 'residential' }});
@@ -66,7 +66,7 @@ describe('iD.validations.almost_junction', function () {
iD.actionAddEntity(w1)
);
// vertical road to the west of w1 by 0.00007 logitude degree
// vertical road to the west of w1 by 0.00007 longitude degree
var n3 = iD.osmNode({id: 'n-3', loc: [22.42350, 0.001]});
var n4 = iD.osmNode({id: 'n-4', loc: [22.42350, -0.001]});
var w2 = iD.osmWay({id: 'w-2', nodes: ['n-3', 'n-4'], tags: { highway: 'residential' }});
@@ -114,7 +114,7 @@ describe('iD.validations.almost_junction', function () {
iD.actionAddEntity(w1)
);
// vertical road to the west of w1 by 0.00001 logitude degree
// vertical road to the west of w1 by 0.00001 longitude degree
var n3 = iD.osmNode({id: 'n-3', loc: [22.42356, 0.001]});
var n4 = iD.osmNode({id: 'n-4', loc: [22.42356, -0.001]});
var w2 = iD.osmWay({id: 'w-2', nodes: ['n-3', 'n-4'], tags: { highway: 'residential' }});
@@ -194,7 +194,7 @@ describe('iD.validations.almost_junction', function () {
}
function closeEndNodesBothSmallAngle() {
// Square path with both endpoints near eachother
// Square path with both endpoints near each other
var n1 = iD.osmNode({id: 'n-1', loc: [0, 22.4427453]});
var n2 = iD.osmNode({id: 'n-2', loc: [0, 22.4429810]});
var n3 = iD.osmNode({id: 'n-3', loc: [0.0000063, 22.4429810]});