All Projects → laenger → Viewpagerbottomsheet

laenger / Viewpagerbottomsheet

Licence: apache-2.0
Use ViewPagers in Bottom Sheets!

Programming Languages

java
68154 projects - #9 most used programming language

Projects that are alternatives of or similar to Viewpagerbottomsheet

Animatedbottombar
A customizable and easy to use BottomBar navigation view with sleek animations, with support for ViewPager, ViewPager2, NavController, and badges.
Stars: ✭ 797 (+102.8%)
Mutual labels:  android-ui, viewpager
Scrollingpagerindicator
Pager indicator inspired by Instagram. Lightweight and easy to set up.
Stars: ✭ 419 (+6.62%)
Mutual labels:  android-ui, viewpager
Discretescrollview
A scrollable list of items that centers the current element and provides easy-to-use APIs for cool item animations.
Stars: ✭ 5,533 (+1307.89%)
Mutual labels:  android-ui, viewpager
Adaptablebottomnavigation
A simpler way for implementing the Bottom Navigation View on Android
Stars: ✭ 844 (+114.76%)
Mutual labels:  android-ui, viewpager
Pageindicator
An Instagram like page indicator compatible with RecyclerView and ViewPager.
Stars: ✭ 236 (-39.95%)
Mutual labels:  android-ui, viewpager
ArcPageIndicator
Android Page Indicator for ViewPager with original animations. It uses an ellipse to dispose indication spots, and can draw a hand, like in old elevators.
Stars: ✭ 73 (-81.42%)
Mutual labels:  viewpager, android-ui
OnboardingDemo
Onboarding Example. Uses ViewPager's PageTransformer to animate elements.
Stars: ✭ 44 (-88.8%)
Mutual labels:  viewpager, android-ui
Reside-Menu
By applying viewpager animation you can also make AMAZING Reside Menu's
Stars: ✭ 72 (-81.68%)
Mutual labels:  viewpager, android-ui
Graceviewpager
1.支持ViewPager按需添加、删除视图,以及局部刷新; 2.修复多场景下ViewPager.PageTransformer返回的position错误,让开发者专注于动画实现; 3.修复ViewPager的width、paddingLeft、paddingRight、pageMargin动态改变导致当前page定位异常的问题; 4.提供自定义GraceViewPager,可快速实现一屏显示多Page的功能。
Stars: ✭ 341 (-13.23%)
Mutual labels:  viewpager
Indicatorscrollview
🧀 A dynamic scroll view that animates indicators according to its scroll position.
Stars: ✭ 355 (-9.67%)
Mutual labels:  android-ui
Expenso
📊 A Minimal Expense Tracker App built to demonstrate the use of modern android architecture component with MVVM Architecture
Stars: ✭ 325 (-17.3%)
Mutual labels:  android-ui
Stacklayoutmanager
customized layoutmanager,let item pile up like stackview/类似最美有物卡片堆叠效果
Stars: ✭ 343 (-12.72%)
Mutual labels:  android-ui
Corbind
Kotlin Coroutines binding APIs for Android UI widgets from the platform and support libraries
Stars: ✭ 357 (-9.16%)
Mutual labels:  viewpager
Fastadapter
The bullet proof, fast and easy to use adapter library, which minimizes developing time to a fraction...
Stars: ✭ 3,512 (+793.64%)
Mutual labels:  android-ui
Pudding
🌟 Pudding use WindowManager(don't need request permission) to pull down a view that are displayed on top their attached window
Stars: ✭ 371 (-5.6%)
Mutual labels:  android-ui
Rtl Viewpager
ViewPager with RTL support 🔄
Stars: ✭ 323 (-17.81%)
Mutual labels:  viewpager
Oneadapter
A Viewholderless Adapter for RecyclerView, who supports builtin diffing, states (paging, empty...), events (clicking, swiping...), and more.
Stars: ✭ 321 (-18.32%)
Mutual labels:  android-ui
Loginui Android
Login User Interface in android with innovative, beautiful and creative background 😊😊😉
Stars: ✭ 374 (-4.83%)
Mutual labels:  android-ui
Viewpagerindicator
一个简单好用的ViewPagerIndicator,提供了六种类型,为viewpager添加酷炫效果,并且支持轮播图( A simple, cool, customizable ViewPagerIndicator.show cool indicator for viewpager , it also good for viewpager as carousel )
Stars: ✭ 366 (-6.87%)
Mutual labels:  viewpager
Awesome Android Ui
😎 A curated list of awesome Android UI/UX libraries
Stars: ✭ 353 (-10.18%)
Mutual labels:  android-ui

ViewPagerBottomSheet

Use ViewPagers in Bottom Sheets and Bottom Sheet Dialogs!

Example

This repository features an example app that demonstrates nested ViewPagers inside a bottom sheet:

Example App

Use for your project

Add the maven repo url to your build.gradle:

repositories {
    maven { url "https://raw.github.com/laenger/maven-releases/master/releases" }
}

Add the library to the dependencies:

dependencies {
    compile "biz.laenger.android:vpbs:0.0.6"
}

Use ViewPagerBottomSheetBehavior for your bottom sheet view:

app:layout_behavior="@string/view_pager_bottom_sheet_behavior"

Setup any nested ViewPager inside the bottom sheet:

BottomSheetUtils.setupViewPager(bottomSheetViewPager)

(This also works when the ViewPager is the bottom sheet view and for further nested ViewPagers)

Use with Bottom Sheet Dialogs

Use ViewPagerBottomSheetDialogFragment as super-class and setup any ViewPager as follows:

public class DialogFragment extends ViewPagerBottomSheetDialogFragment {
    @Override
    public void setupDialog(Dialog dialog, int style) {
        super.setupDialog(dialog, style);
        final View contentView = View.inflate(getContext(), R.layout.dialog_bottom_sheet, null);

        ViewPager viewPager = (ViewPager) contentView.findViewById(R.id.viewpager);
        // ...
        BottomSheetUtils.setupViewPager(viewPager);

        dialog.setContentView(contentView);
    }
}

Example App

How does this work?

ViewPagerBottomSheetBehavior is essentially identical to the original BottomSheetBehavior from the Design Support Library but adds important details: ViewPagers are now properly handled when finding the scrolling child, and this reference can be updated on ViewPager page changes. See the key diff in this commit: 2775715

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].