All Projects → iammert → Tabscrollattacher

iammert / Tabscrollattacher

Attach TabLayout and RecyclerView. Useful for categorizing RecyclerView items.

Programming Languages

kotlin
9241 projects

Projects that are alternatives of or similar to Tabscrollattacher

Coder
Android Material Design 风格控件的学习及遇到的问题;Tablayout | 横向布局标签,TextInputLayout | 文字输入布局 ,FloatingActionButton | 悬浮按钮, CoordinatorLayout APPBarLayout CollapsingTabLayout实现折叠头布局,BottomSheetDialog | 底部对话框,Touch Feedback| 触摸反馈,Reveal Effect| 揭示效果,Curved motion | 曲线运动,Animated Vector Drawables | 矢量图片动画
Stars: ✭ 502 (+156.12%)
Mutual labels:  recyclerview, tablayout
TabSync
A lightweight synchronizer between Android's Tabs and Lists. Available on the View system and Jetpack Compose.
Stars: ✭ 98 (-50%)
Mutual labels:  recyclerview, tablayout
Fastadapter
快速使用的RecyclerView Adapter
Stars: ✭ 170 (-13.27%)
Mutual labels:  recyclerview
Moretype
new method to build data in RecyclerView with Kotlin!
Stars: ✭ 189 (-3.57%)
Mutual labels:  recyclerview
Dragdroptworecyclerviews
A code example demonstrating a dragging and dropping from one RecyclerView into another RecyclerView.
Stars: ✭ 181 (-7.65%)
Mutual labels:  recyclerview
Customadapter
RV Adapter 优雅封装,抽取列表模版,可以快速的添加一个列表,使用组装的方式构建Adapter,抽象Cell 角色,负责创建ViewHolder,绑定数据和逻辑处理。Cell为一个独立的组件。
Stars: ✭ 172 (-12.24%)
Mutual labels:  recyclerview
Infinitescroll
Infinite Scroll (Endless Scrolling) for RecyclerView in Android
Stars: ✭ 183 (-6.63%)
Mutual labels:  recyclerview
Timeline
瀑布流式的时间轴
Stars: ✭ 2,028 (+934.69%)
Mutual labels:  recyclerview
Multiselectadapter
MultiSelectAdapter可以让你的Adapter快速实现多选和批量操作
Stars: ✭ 195 (-0.51%)
Mutual labels:  recyclerview
Nopaginate
Android pagination library (updated 01.05.2018)
Stars: ✭ 180 (-8.16%)
Mutual labels:  recyclerview
Easyadapter
This project demonstrates simple approach for implementation complex lists, based on RecyclerView.
Stars: ✭ 187 (-4.59%)
Mutual labels:  recyclerview
Sortrecyclerviewlist
Recyclerview实现字母排序,过滤搜索,顶部悬浮,波浪形的侧边栏
Stars: ✭ 179 (-8.67%)
Mutual labels:  recyclerview
Airbnb Android Google Map View
This is a sample Android Application which has Google Map view similar to what AirBnb Android Application. Moving Markers like Uber/Ola. Custom Google Search for places. Recycler view with Animations added.
Stars: ✭ 175 (-10.71%)
Mutual labels:  recyclerview
Sherlockadapter
一个万能的封装了RecyclerView.Adapter的功能库。
Stars: ✭ 186 (-5.1%)
Mutual labels:  recyclerview
Binding
Simple API implement DataBinding and ViewBinding. 简单的 API 实现 DataBinding 和 ViewBinding,欢迎 star
Stars: ✭ 169 (-13.78%)
Mutual labels:  recyclerview
Diffadapter
A high-performance , easy-to-use Adapter for RecyclerView ,using diffutil
Stars: ✭ 193 (-1.53%)
Mutual labels:  recyclerview
Pinnedsectionitemdecoration
A powerful ItemDecoration for Recyclerview, supports the common layoutmanager.
Stars: ✭ 2,027 (+934.18%)
Mutual labels:  recyclerview
Placeholderview
This library provides advance views for lists and stacks. Some of the views are build on top of RecyclerView and others are written in their own. Annotations are compiled by annotation processor to generate bind classes. DOCS -->
Stars: ✭ 2,104 (+973.47%)
Mutual labels:  recyclerview
Android Tablayouthelper
A small library which helps to use TabLayout with ViewPager more easily.
Stars: ✭ 181 (-7.65%)
Mutual labels:  tablayout
Advancedrecyclerview
An easy, empowering Kotlin library for RecyclerView
Stars: ✭ 197 (+0.51%)
Mutual labels:  recyclerview

What? 🤔

It is not a custom TabLayout or RecyclerView. It is just a helper library to attach to your RecyclerView with your TabLayout. If you don't want to go with sticky header RecyclerView or something like that, and also want to provide a good experience when your user is scrolling the content, this small library is for you.

How? 🤨

You fetch your product list and their categories. All you need to do is calcualate start index for all categories. Attacher will do the rest.

If your backend guy returns this json,

CategoryA -> 10 items (between 0..10)
CategoryB -> 20 items (between 10..30)
CategoryC -> 30 items (between 30..60)

Then your offset list will be,

//3 tabs and their offset indexes in total list.
val categoryIndexOffsetList = [0,10,30]

Then? 🙄

Then you attach.

val attacher = TabScrollAttacher(tabLayout, recyclerView, categoryIndexOffsetList)
attacher.attach()

Detach when you don't need anymore.

attacher.detach()

Configure? 🧑‍🔧

  • scrollDirectly(): If you don't want to see the scrolling process, use it.
  • scrollSmoothly(): If you want to see the flowing items while scrolling, this is for you.
  • scrollSmoothly(limit = 10): If you have a lot of items and smooth scrolling takes too long, you can set a scrolling item limit. It will scroll directly until the limit items left, then rest of the items will scroll smoothly.
TabScrollAttacher(tabLayout, recyclerView, categoryIndexOffsetList) {
    // Configuration
}

Where? 🤩

maven { url 'https://jitpack.io' }
dependencies {
  compile 'com.github.iammert:TabScrollAttacher:1.0.2'
}

When? 😇

When you have LinearLayoutManager, GridLayoutManager in any orientation (horizontal or vertical) you can use this library.

Who? 👻

License

Copyright 2019 Mert Şimşek

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].