From 1683313621284e710514d370b6cc843cc33c3db8 Mon Sep 17 00:00:00 2001 From: Asif Sheriff Date: Fri, 15 Mar 2024 05:43:07 +0530 Subject: [PATCH] preserve rows with empty tag values in raw tag editor (#10151) --- CHANGELOG.md | 3 +++ modules/ui/sections/raw_tag_editor.js | 3 --- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 39e125a2f..995a30cfb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -40,6 +40,7 @@ _Breaking developer changes, which may affect downstream projects or sites that #### :tada: New Features * Add button to fully load incompletely downloaded relations ([#5420]) #### :sparkles: Usability & Accessibility +* Preserve rows with empty tag values in raw tag editor ([#10145], thanks [@Asif-Sheriff]) #### :scissors: Operations #### :camera: Street-Level * Show Mapillary username and deep link to external viewer on Mapillary photos ([#10135], thanks [@Sushil642]) @@ -59,8 +60,10 @@ _Breaking developer changes, which may affect downstream projects or sites that [#8415]: https://github.com/openstreetmap/iD/issues/8415 [#9439]: https://github.com/openstreetmap/iD/issues/9439 [#10135]: https://github.com/openstreetmap/iD/issues/10135 +[#10145]: https://github.com/openstreetmap/iD/issues/10145 [@Sushil642]: https://github.com/Sushil642 [@mattiapezzotti]: https://github.com/mattiapezzotti +[@Asif-Sheriff]: https://github.com/Asif-Sheriff # 2.28.1 diff --git a/modules/ui/sections/raw_tag_editor.js b/modules/ui/sections/raw_tag_editor.js index 44d7fadd9..2db9c4d2e 100644 --- a/modules/ui/sections/raw_tag_editor.js +++ b/modules/ui/sections/raw_tag_editor.js @@ -558,9 +558,6 @@ export function uiSectionRawTagEditor(id, context) { // exit if this is a multiselection and no value was entered if (typeof d.value !== 'string' && !this.value) return; - // remove tag if it is now empty - if (!this.value.trim()) return removeTag(d3_event, d); - // exit if we are currently about to delete this row anyway - #6366 if (_pendingChange && _pendingChange.hasOwnProperty(d.key) && _pendingChange[d.key] === undefined) return;