Skip to content

Add new features to Dismissible widget #21230

Open

Description

@grigy

The Dismissible widget is awesome but has very limited functionality which makes it not usable in many real world applications. Let's consider adding the following features (in order of priority):

  1. Allow onResize() callback to get the direction in which the item was dismissed. This is needed to implement two types of functions depending on swipe direction (e.g. bookmark and delete).

  2. Add an "undo" function to restore the dismissed item by moving it back to its position. This may be useful in case if user wants to undo the dismiss action.

  3. Allow custom animation in the background widgets for example by adding a new callback which gets the slider's position. The animation can be a function of a slider position, like in Google Inbox (resizing the icon on the background).

Activity

  1. added
    c: new featureNothing broken; request for a new capability
    frameworkflutter/packages/flutter repository. See also f: labels.
    p: material_uimaterial_ui package in flutter/packages
    on Aug 30, 2018
  2. added this to the milestone on Aug 30, 2018
  3. modified the milestones: , on Feb 13, 2019
  4. tp commented on Jun 5, 2019

    @tp

    I was also looking for suggestion number 3: having a callback to get the progress of the dismiss action.

    Wondering whether we should split these up into individual tickets though, having separate concerns combined probably just makes this harder to gain traction.

  5. leviatan21 commented on Aug 25, 2019

    @leviatan21

    Hi: I'm also looking for suggestion number 1: Allow onResize() callback to get the direction in which the item was dismissed

    Thanks

  6. added
    P2Important issues not at the top of the work list
    on May 29, 2020
  7. removed this from the milestone on Aug 17, 2020
  8. BazinC commented on Jan 25, 2021

    @BazinC

    We also miss the ability for _resizeController and _moveController to move together in the same time.
    For now it moves THEN it resizes.
    It would make it feel faster/smoother to start resizing earlier.
    See iOs Gmail swipe to delete animation :)

  9. IlyaMax commented on Aug 16, 2022

    @IlyaMax

    It would be great if moveController was exposed, it solves many issues I think

  10. lukepighetti commented on Dec 15, 2022

    @lukepighetti
    Contributor

    Would love to be able to trigger a dismiss programmatically dismissibleController.dismiss(DismissDirection.up)

    I was expecting to be able to access DismissibleState via GlobalKey and find a helper function for performing this action

  11. added
    packageflutter/packages repository. See also p: labels.
    and removed
    frameworkflutter/packages/flutter repository. See also f: labels.
    on Aug 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Important issues not at the top of the work listc: new featureNothing broken; request for a new capabilityc: proposalA detailed proposal for a change to Flutterp: material_uimaterial_ui package in flutter/packagespackageflutter/packages repository. See also p: labels.team-designOwned by Design Languages teamtriaged-designTriaged by Design Languages team

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions