LibWeb: Don't skip last keyframe

This commit is contained in:
Gingeh 2025-06-19 13:13:53 +10:00 committed by Jelle Raaijmakers
commit 4292344729
Notes: github-actions[bot] 2025-06-23 19:02:33 +00:00
3 changed files with 46 additions and 2 deletions

View file

@ -1334,8 +1334,10 @@ void StyleComputer::collect_animation_into(DOM::Element& element, Optional<CSS::
return keyframes.begin();
}
auto potential_match = keyframes.find_largest_not_above_iterator(key);
if (output_progress.value() >= 0) {
return --potential_match;
auto next = potential_match;
++next;
if (next.is_end()) {
--potential_match;
}
return potential_match;
}();