{"id":26152777,"url":"https://github.com/liaoinstan/springview","last_synced_at":"2025-05-14T23:06:39.645Z","repository":{"id":47353622,"uuid":"54880411","full_name":"liaoinstan/SpringView","owner":"liaoinstan","description":"🔥 A custom view pull to refresh,support ScrollView,ListView,RecyclerView,WebView and all another views, easy to use","archived":false,"fork":false,"pushed_at":"2020-09-27T11:33:55.000Z","size":30048,"stargazers_count":1928,"open_issues_count":80,"forks_count":352,"subscribers_count":60,"default_branch":"master","last_synced_at":"2025-05-14T23:06:21.258Z","etag":null,"topics":["android-ui","footer","header","pull-to-refresh","pulltorefresh","refreshlayout","smartrefresh"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/liaoinstan.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-03-28T09:07:07.000Z","updated_at":"2025-05-02T12:00:27.000Z","dependencies_parsed_at":"2022-08-22T01:41:27.609Z","dependency_job_id":null,"html_url":"https://github.com/liaoinstan/SpringView","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liaoinstan%2FSpringView","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liaoinstan%2FSpringView/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liaoinstan%2FSpringView/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liaoinstan%2FSpringView/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/liaoinstan","download_url":"https://codeload.github.com/liaoinstan/SpringView/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254243362,"owners_count":22038046,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["android-ui","footer","header","pull-to-refresh","pulltorefresh","refreshlayout","smartrefresh"],"created_at":"2025-03-11T07:21:50.931Z","updated_at":"2025-05-14T23:06:34.615Z","avatar_url":"https://github.com/liaoinstan.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"More, please visit：[My CSDN](http://blog.csdn.net/liaoinstan/article/details/51023907)  　　　　apk demo：[download](https://github.com/liaoinstan/SpringView/blob/master/apk/DemoSpring-1.7.0-release.apk?raw=true)  　　　　中文文档：[中文文档](https://github.com/liaoinstan/SpringView/blob/master/README_CN.md)\n\nSpringView\n=====\n**SpringView**  is one provides the function of the upper and lower drag and drop components, can be highly customized, implement all kinds of drop-down \\ pull painting effect, implementation in the demo: imitation ali travel, imitation Meituan, imitation QQ drop-down brush red envelopes, imitation acfun etc., is fully compatible with the source control such as ListView, RecyclerView, ScrollView, WebView, etc., using a simple, easily customize their style of drag and drop page\n![这里写图片描述](https://github.com/liaoinstan/SpringView/blob/master/screenshot/springview.png)\n\n**SpringView** Individual independence will head/foot,  almost achieve the effect of whatever you want, just need to inherit BaseHeader (or Footer) to implement the interface\n\n**SpringView** Can dynamically replace the head/tail, you just need to set up different Footer：springView.setHeader(MyHeader());\n\n**SpringView** Multi-touch support, can two hands drag and drop in a row, you can customize some interesting results\n\n**SpringView** Provides two methods for drag and drop (overlap and follow), can be dynamically switching\n\n**SpringView** For lazy people don't want to go to the custom head/tail provides 7 kinds of the default implementation (mimics the ali, tencent, Meituan etc. Various style) as follows, will continue to increase\n\n**SpringView** support AppBarLayout\n \n \n![这里写图片描述](https://github.com/liaoinstan/SpringView/blob/master/screenshot/1459212323072_s.gif) ![这里写图片描述](https://github.com/liaoinstan/SpringView/blob/master/screenshot/1459212372609_s.gif)\n![这里写图片描述](https://github.com/liaoinstan/SpringView/blob/master/screenshot/1459212462800_s.gif) ![这里写图片描述](https://github.com/liaoinstan/SpringView/blob/master/screenshot/1459212485237_s.gif)\n![这里写图片描述](https://github.com/liaoinstan/SpringView/blob/master/screenshot/1459212517801_s.gif) ![这里写图片描述](https://github.com/liaoinstan/SpringView/blob/master/screenshot/1459212658972_s.gif)\n![这里写图片描述](https://github.com/liaoinstan/SpringView/blob/master/screenshot/1459212769245_s.gif) \n\n**📌new：** \n\n![这里写图片描述](https://github.com/liaoinstan/SpringView/blob/master/screenshot/weixin_header_s.gif) ![这里写图片描述](https://github.com/liaoinstan/SpringView/blob/master/screenshot/weixin_header_v2_s.gif)\n![这里写图片描述](https://github.com/liaoinstan/SpringView/blob/master/screenshot/auto_footer_s.gif) ![这里写图片描述](https://github.com/liaoinstan/SpringView/blob/master/screenshot/du_header_s.gif)\n\n**How to use SpringView**\n--------\n\nAdd Spring View in the layout file, note that Spring View and ScrollView have the same limitation: only one child element：\n\n```\n\t\u003ccom.liaoinstan.springview.widget.SpringView\n            android:layout_width=\"match_parent\"\n            android:layout_height=\"match_parent\"\n            app:header=\"@layout/myheader\"\n            app:footer=\"@layout/myfooter\"\u003e\n\n            \u003cListView RecyclerView ScrollView or others\n                android:layout_width=\"match_parent\"\n                android:layout_height=\"match_parent\"/\u003e\n\n     \u003c/com.liaoinstan.springview.widget.SpringView\u003e\n```\nOf course, you can also add the header/footer in java code：\n\n```\n\tspringView.setHeader(new DefaultHeader(this));\n\tspringView.setFooter(new DefaultFooter(this));\n```\n\n**Add Listener**\n--------\nIf you need to deal with the case, just add a listener in code：\n\n```\nspringView.setListener(new SpringView.OnFreshListener() {\n      @Override\n      public void onRefresh() {\n      }\n      @Override\n      public void onLoadmore() {\n      }\n});\n```\n\n**Get SpringView**\n--------\nuse Gradle:\n```\ndependencies {\n\n   //SpringView core library (only include DefaultHeader/Footer)\n   implementation 'com.liaoinstan.springview:library:1.7.0'\n\n   //other Headers/Footers, choose one or more that you like\n   implementation 'com.liaoinstan.springview:AcfunHeader:1.7.0'         //AcFun style （header and footer）\n   implementation 'com.liaoinstan.springview:AliHeader:1.7.0'           //Alitrip style （header and footer）\n   implementation 'com.liaoinstan.springview:MeituanHeader:1.7.0'       //Meituan style （header and footer）\n   implementation 'com.liaoinstan.springview:RotationHeader:1.7.0'      //Mechanical gear style （header and footer）\n   implementation 'com.liaoinstan.springview:WeixinHeader:1.7.0'        //WeChat Mini Program header（only header）\n   implementation 'com.liaoinstan.springview:DuHeader:1.7.0'\t\t//Du app header（only header）\n}\n```\nor Maven：\n```\n\u003cdependency\u003e\n  \u003cgroupId\u003ecom.liaoinstan.springview\u003c/groupId\u003e\n  \u003cartifactId\u003elibrary\u003c/artifactId\u003e\n  \u003cversion\u003e1.7.0\u003c/version\u003e\n  \u003ctype\u003epom\u003c/type\u003e\n\u003c/dependency\u003e\n```\n\n\n**Update log**\n--------\n### **v1.7.0**\n- Add new a header (DuHeader), and a auto-scrolling Footer (AutoFooter).\n- Add a new type SCROLL. Based on this mode, effects such as scrolling to the bottom and automatic loading can be achieved.\n- Header / Footer now has setType () method, you can set different Type for Header and Footer respectively.\n- Fix issus.\n \n### **v1.6.0**\n- Add a new header (WeixinHeaderV2) for new version of WeChat (WeChat 7).\n- The movement parameter of SpringView (MovePara) no longer affects both Header and Footer. BaseHeader/Footer now has a new getMovePara() interface that allows you to set different movement parameters for Header and Footer to match different drag-and-drop feel.(if you don't implement the interface, SpringView is still compatible with the previous rules).\n- Update to Android X.\n- Fixed several drag and drop stickiness issues, and callFresh method callback issues.\n \n### **v1.5.1**\n - Fix bug when nested layout, fix bug callFresh() can't spring back when set SpringView Give.NONE.\n\n### **v1.5.0**\n - headers /footers split off from SpringView library(except DefaultHeader/Footer)，simplified core library，now core library's size only **26KB**,You can import headers/footers separately\n\n### **v1.4.0**\n - New function setMovePara(),a new header for weixin:WeixinHeader,a new type DRAG like SwipeRefreshLayout:spring.setType(Type.DRAG)\n\n### **v1.3.3**\n - Optimize several experiential issues,Added onFinishFreshAndLoadDelay(int delay), callFreshDelay(int delay) method,Optimizing performance with BottomSheetBehavior,Optimize the performance used in BottomSheetDialog\n\n### **v1.3.2**\n - Fix the bug of the linkage damping of AppBarLayout in the case of null data,\nnew setEnableFooter(Boolean), setEnableHeader(Boolean) disable or enable header/footer.\n \n### **v1.3.0**\n - Support AppBarLayout,fix sliding conflict\n\n### **v1.2.7**\n - Bug fix\n\n### **v1.2.6**\n - Padding bug fix\n\n### **v1.2.5**\n - Add **setEnable(boolean)** function\n\n### **v1.2.4**\n\n - Add **callFresh()** method, used to call the refresh operation manual\n - Fixes the lateral sliding conflict\n\n### **v1.2.2**\n - Repair the callback refresh many times\n\n### **v1.2.1**\n - Repair the click event occasional failure problem\n\n\n**Feedback**\n--------\nIf there are any questions or Suggestions, please feedback to my email: liaoinstan@outlook.com;\nOr in my blog\n\nIf it works to you, please give me a star for my hardwork ,thank you\n\n**More**\n--------\nMore, please visit：[my CSDN blog](http://blog.csdn.net/liaoinstan)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fliaoinstan%2Fspringview","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fliaoinstan%2Fspringview","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fliaoinstan%2Fspringview/lists"}