Giter Club home page Giter Club logo

flutter_snaplist's People

Contributors

ariedov avatar kumar-aakash86 avatar raacker avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

flutter_snaplist's Issues

snaplist padding

I tried to use this package but i do not understand how padding works. In example with horizontal padding there is only padding.left property used. If i remove padding property - snap list item have 0 lef padding, but still it is centered vertical, so i assume it has vertical padding. How can i remoe all paddins or set my own?

Request for disabling scroll

This could be circumvented by either using the snaplist or using other widgets, but if it is easy to accomplish it would be great to pass a parameter during build that can disable the ability to scroll for scenarios where the items in the snaplist are smaller than the space allotted and are more of a static list than a scroll widget. Is that something you guys would consider implementing?

Not working

Including the library and perfomre the "Showcase" example does not work. Nothing happens. The examples also didn't work. You have to copy the example code and create new files then import them. Anyways, how to get to work the "showcase" example?

The data.center is showing wrong values

In my code, the data.center is not showing the correct indexes, sometimes it's even showing the same center index for different pages.


SnapList(
    padding: EdgeInsets.only(
        left: (screenSize.width - cardSize.width) / 2),
    sizeProvider: (index, data) => cardSize,
    separatorProvider: (index, data) => Size(10.0, 10.0),
    positionUpdate: (int index) {
        print("Current Index: ${index}/${pageCards.length}");
        if (index == pageCards.length - 1) {
            //                          loadMore();
        }
    },
    builder: (context, index, data) {
        print("###########################");
        print("Index: ${index}");
        print("Center: ${data.center}");
        print("Next: ${data.next}");
        print("Progress: ${data.progress}");
        return ProfileCard(pageCards[index], image1, offset,
            () {}, dismissCard);
    },
    count: pageCards.length,
)

Hot reload issues

When changing a parameter on the Snaplist itself the app has to be restarted to apply changes.

How to get pop up effect using snaplist

@ariedov Hi,

how did you get the pop effect of the card in the vertical scroll list. I am referring to the screenshot you have with list of diff movies.

I am able to get the scroll but can't figure out the pop of effect of the card when it comes to the center.

Thanks

Future update not reflecting

Hi,
Thanks for this great plugin. But I am facing one issue in this.

Once you bind the SnapList on page it is not updating when data changed.
I tried this with streambuilder, futurebuilder & async data list.

In FutureBuilder & StreamBuilder, its loading the data & list count is changed but SnapList items are not changing. Also it keep firing positionUpdate callback after list refresh.

In async data list, one the page load I am getting the data from server & when I call setState its showing first item. No gesture is working & positionUpdate callback fires with index as "-1".

I am trying now with this project's branch. Will let you know if I found something.

How to use it

I want to use it in my flutter project. I know how to import it, but the main question is that if I have widget which has an image in it, I want that to be shown in the view, but don't know how to implement it. I just want the view same the horizontal view of the example. If you could show me the code of your example, I will get it somehow. But right now I'm clueless on how to use it in my project. Any help would be appreciated.

Handling dynamic hight changes (Re-Sizing) using snapList and SliverPersistentHeader

Hello Sir
I have been trying to use your package for a while now and I am not able to Re-size your widget dynamically
(actually i can, but the current snapped object goes off the view) and I am not able to maintain the current object in view(it goes off left).
HERE is a link to a small video showcasing the issue :
and here is the code of the SliverPersistentHeaderDelegate I attempted to do :
CodePile code.
I also mailed you on your email ID
Ps: SizeConfig is nothing more than just
((MeDiaQuery.of(context).size.[widthORheight])/100) = percentage of the screen in blocs

How did you achieve the sliding effect

image
In the above GIF, you have dismissed the movie Predator.

How was that possible? I have been trying to do it for hours now and fail

Update:
I can't make it so the right card moves to the left to take place of the removed card

Initial scroll to position

First, thank you for this awesome plugin. Looking forward to using it.

Because there is no controller accepted as a parameter to the SnapList constructor, there is no way to facilitate starting at an initial index, or scrolling to a particular index. It would be wonderful if such functionality could be added.

RTL support

When changing the locale to RTL languages, the vertical scroll remains its direction.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.