Put the range's ends where a tablet can see them
"Limit to range" looked broken a second time, for a second reason. The ends were added to the filter chip row, and that row scrolls: its own comment records that fourteen chips do not fit across 768 logical pixels, "so that is every tablet in portrait". Two date fields and a caption went straight past the right-hand edge, into the part of the row that has to be panned to. So the fix for a control that appeared to do nothing was itself invisible, and pressing the chip still looked like it did nothing. They have their own line now, below the chips and outside the Flickable, and it exists only while a range does. Nothing competes with it for width, and nothing has to be panned to reach it. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
+33
-24
@@ -1745,18 +1745,42 @@ export component LibraryGrid inherits Rectangle {
|
|||||||
clicked => { root.toggle-date-range(); }
|
clicked => { root.toggle-date-range(); }
|
||||||
}
|
}
|
||||||
|
|
||||||
// The ends, once there is a range to have ends.
|
Rectangle { horizontal-stretch: 1; }
|
||||||
|
|
||||||
|
// What the filter is currently hiding. Without this a narrowed
|
||||||
|
// grid and an empty library look identical, which is the
|
||||||
|
// single most confusing state a filter can leave behind.
|
||||||
|
Caption {
|
||||||
|
text: (root.filter-min-rating > 0 || root.filter-unjudged
|
||||||
|
|| root.filter-flag > 0 || root.local-only)
|
||||||
|
? "filtered" : "";
|
||||||
|
emphasised: true;
|
||||||
|
vertical-alignment: center;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// The range's ends, on their own line.
|
||||||
//
|
//
|
||||||
// Turning the chip on used to be the whole control, and it
|
// Not in the chip row above, which scrolls: fourteen chips
|
||||||
// took its span from the timeline's zoom — which is zero until
|
// already do not fit across a tablet in portrait, so anything
|
||||||
// you zoom, so the range came out as the entire library and
|
// added there lands past the right edge, where it has to be
|
||||||
// the button appeared to do nothing at all. The span is now
|
// panned to. That is how "limit to range" managed to look
|
||||||
// *shown*, and can be typed, so "limit to range" always
|
// broken twice — first because it narrowed to everything, and
|
||||||
// narrows to something a person chose.
|
// then because the controls that fixed that were off-screen.
|
||||||
|
//
|
||||||
|
// Costs nothing when there is no range: the row does not exist
|
||||||
|
// then.
|
||||||
|
//
|
||||||
|
// Turning the chip on used to be the whole control, and it took its
|
||||||
|
// span from the timeline's zoom — which is zero until someone
|
||||||
|
// zooms, so the range came out as the entire library and the button
|
||||||
|
// appeared to do nothing. The span is shown here and can be typed,
|
||||||
|
// so "limit to range" always narrows to something a person chose.
|
||||||
//
|
//
|
||||||
// Still seeded from the timeline: zooming to a fortnight and
|
// Still seeded from the timeline: zooming to a fortnight and
|
||||||
// pressing the chip is the fast path, and these fields say
|
// pressing the chip is the fast path, and these fields say which
|
||||||
// which fortnight it landed on.
|
// fortnight it landed on.
|
||||||
if root.range-active: HorizontalLayout {
|
if root.range-active: HorizontalLayout {
|
||||||
spacing: Theme.gap-sm;
|
spacing: Theme.gap-sm;
|
||||||
|
|
||||||
@@ -1790,21 +1814,6 @@ export component LibraryGrid inherits Rectangle {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Rectangle { horizontal-stretch: 1; }
|
|
||||||
|
|
||||||
// What the filter is currently hiding. Without this a narrowed
|
|
||||||
// grid and an empty library look identical, which is the
|
|
||||||
// single most confusing state a filter can leave behind.
|
|
||||||
Caption {
|
|
||||||
text: (root.filter-min-rating > 0 || root.filter-unjudged
|
|
||||||
|| root.filter-flag > 0 || root.local-only)
|
|
||||||
? "filtered" : "";
|
|
||||||
emphasised: true;
|
|
||||||
vertical-alignment: center;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
y: parent.height - 1px;
|
y: parent.height - 1px;
|
||||||
height: 1px;
|
height: 1px;
|
||||||
|
|||||||
Reference in New Issue
Block a user