Skip to content

Commit 6dcae81

Browse files
committed
Fix uninstall animation snapping after a prior FLIP slide
1 parent 09baee6 commit 6dcae81

1 file changed

Lines changed: 11 additions & 0 deletions

File tree

src/gui/src/UI/Dashboard/TabApps.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -224,6 +224,13 @@ function showUninstallModal ({ appName, appTitle, appUid, self, $el_window }) {
224224
el.style.transition = `transform ${DRAG_FLIP_ANIM_MS}ms ${DRAG_FLIP_EASING}`;
225225
el.style.transform = '';
226226
}
227+
// The transform-only inline transition must not outlive the
228+
// slide: left in place it overrides .myapps-tile-removing's
229+
// transition on the next uninstall, snapping opacity to 0
230+
// with no shrink animation.
231+
setTimeout(() => {
232+
for ( const el of moved ) el.style.transition = '';
233+
}, DRAG_FLIP_ANIM_MS + 60);
227234
}
228235
settleRemoval();
229236
};
@@ -233,6 +240,10 @@ function showUninstallModal ({ appName, appTitle, appUid, self, $el_window }) {
233240
if ( tileEl && ! self._reduceMotion() ) {
234241
// Let the modal's departure settle before the tile starts to go.
235242
setTimeout(() => {
243+
// An earlier FLIP (uninstall slide or drag reorder) may have
244+
// left a stale inline transition on this tile; clear it so
245+
// the removing class's transition takes effect.
246+
tileEl.style.transition = '';
236247
tileEl.classList.add('myapps-tile-removing');
237248
setTimeout(finishRemoval, TILE_REMOVE_ANIM_MS);
238249
}, TILE_REMOVE_DELAY_MS);

0 commit comments

Comments
 (0)