mirror of
https://github.com/FoggedLens/iD.git
synced 2026-05-27 18:32:25 +02:00
Remove old _tkeys_ code
This was used for debugging translations, it would replace each string with the translation key, so people could see what key was used where in the UI. As far as I know, nobody was using this.
This commit is contained in:
+3
-30
@@ -29,27 +29,6 @@ export function coreContext() {
|
||||
context.version = '2.17.2';
|
||||
context.privacyVersion = '20191217';
|
||||
|
||||
// // create a special translation that contains the keys in place of the strings
|
||||
// let tkeys = JSON.parse(JSON.stringify(dataEn)); // clone deep
|
||||
// let parents = [];
|
||||
|
||||
// function traverser(v, k, obj) {
|
||||
// parents.push(k);
|
||||
// if (typeof v === 'object') {
|
||||
// forOwn(v, traverser);
|
||||
// } else if (typeof v === 'string') {
|
||||
// obj[k] = parents.join('.');
|
||||
// }
|
||||
// parents.pop();
|
||||
// }
|
||||
|
||||
// function forOwn(obj, fn) {
|
||||
// Object.keys(obj).forEach(k => fn(obj[k], k, obj));
|
||||
// }
|
||||
|
||||
// forOwn(tkeys, traverser);
|
||||
// addLocale('_tkeys_', tkeys);
|
||||
|
||||
|
||||
// https://github.com/openstreetmap/iD/issues/772
|
||||
// http://mathiasbynens.be/notes/localstorage-pattern#comment-9
|
||||
@@ -206,17 +185,11 @@ export function coreContext() {
|
||||
};
|
||||
|
||||
|
||||
context.maxCharsForTagKey = function() {
|
||||
return 255;
|
||||
};
|
||||
context.maxCharsForTagKey = () => 255;
|
||||
|
||||
context.maxCharsForTagValue = function() {
|
||||
return 255;
|
||||
};
|
||||
context.maxCharsForTagValue = () => 255;
|
||||
|
||||
context.maxCharsForRelationRole = function() {
|
||||
return 255;
|
||||
};
|
||||
context.maxCharsForRelationRole = () => 255;
|
||||
|
||||
|
||||
/* History */
|
||||
|
||||
Reference in New Issue
Block a user