mirror of
https://github.com/FoggedLens/iD.git
synced 2026-02-27 16:03:52 +00:00
Make sure photo filter controls are always shown in the same order
This commit is contained in:
@@ -112,7 +112,7 @@ export function uiSectionPhotoOverlays(context) {
|
||||
|
||||
var ul = selection
|
||||
.selectAll('.layer-list-photo-types')
|
||||
.data(context.photos().shouldFilterByPhotoType() ? [0] : []);
|
||||
.data([0]);
|
||||
|
||||
ul.exit()
|
||||
.remove();
|
||||
@@ -123,7 +123,7 @@ export function uiSectionPhotoOverlays(context) {
|
||||
.merge(ul);
|
||||
|
||||
var li = ul.selectAll('.list-item-photo-types')
|
||||
.data(data);
|
||||
.data(context.photos().shouldFilterByPhotoType() ? data : []);
|
||||
|
||||
li.exit()
|
||||
.remove();
|
||||
@@ -175,7 +175,7 @@ export function uiSectionPhotoOverlays(context) {
|
||||
|
||||
var ul = selection
|
||||
.selectAll('.layer-list-date-filter')
|
||||
.data(context.photos().shouldFilterByDate() ? [0] : []);
|
||||
.data([0]);
|
||||
|
||||
ul.exit()
|
||||
.remove();
|
||||
@@ -186,7 +186,7 @@ export function uiSectionPhotoOverlays(context) {
|
||||
.merge(ul);
|
||||
|
||||
var li = ul.selectAll('.list-item-date-filter')
|
||||
.data(data);
|
||||
.data(context.photos().shouldFilterByDate() ? data : []);
|
||||
|
||||
li.exit()
|
||||
.remove();
|
||||
@@ -241,7 +241,7 @@ export function uiSectionPhotoOverlays(context) {
|
||||
}
|
||||
var ul = selection
|
||||
.selectAll('.layer-list-username-filter')
|
||||
.data(context.photos().shouldFilterByUsername() ? [0] : []);
|
||||
.data([0]);
|
||||
|
||||
ul.exit()
|
||||
.remove();
|
||||
@@ -252,7 +252,7 @@ export function uiSectionPhotoOverlays(context) {
|
||||
.merge(ul);
|
||||
|
||||
var li = ul.selectAll('.list-item-username-filter')
|
||||
.data(['username-filter']);
|
||||
.data(context.photos().shouldFilterByUsername() ? ['username-filter'] : []);
|
||||
|
||||
li.exit()
|
||||
.remove();
|
||||
|
||||
Reference in New Issue
Block a user