PocketLib

Custom views(eg. Searchable Spinner Dialog) and Base Class for Activity, Fragment, Adapter and ViewHolder.

Installation

  • gradle
            
              allprojects {
    repositories {
        maven { url 'https://jitpack.io' }
    }
}
//add dependency
dependencies {
    implementation 'com.github.jamesdeperio:PocketLib:2.2.0'

    //To use BaseSwipeFragment include
    implementation 'me.yokeyword:swipebackfragment:0.4.0'

    //To use EventPublisher include
    implementation 'io.reactivex.rxjava2:rxjava:x.x.x'
    implementation 'io.reactivex.rxjava2:rxandroid:x.x.x'

    //To use PocketDialog include
    implementation 'com.airbnb.android:lottie:2.7.0'
}

Multiple ViewHolder

You can create different view holder design as much as you want with easier patttern.

Lazy Adapter Setup

Simpliest way to setup recyclerview adapter.

Searchable Spinner Dialog

Pass any object and just specify what item to display!

ViewPager Builder

Build your viewpager easily with few line of code!

Clean Code

For better readability and understanding.

Lazy Coding

Don't code too much! You can minify and remove boilerplate.

Read the documentation for better understanding and customization

Documentation

Changelog

2.2.0

10/26/2018
  • ADDED A VIEW: PocketSpinner
  • UPDATED: changed button style in PocketDialog
  • ADDED: setSpinnerView(?) method in PocketSpinnerDialog

v2.1.1

10/17/2018
  • ADDED: isDialogShowing() method for PocketDialog
  • ADDED: PocketDialog.Type.DIALOG_SEARCH
  • FIXED: action button margin
  • FIXED: viewSeparator should not be visible by default in PocketDialog.Loader
  • IMPROVED: reduced method count
  • UPDATED: PocketDialog.Type.ERROR changed default lottieview animation
  • UPDATED: gradle dependency to v3.2.1
  • UPDATED: maven dependency to v2.1
  • MERGED: PR of @marjorietiozon :
          - ADDED: default blank value for title in PageBuilder.addPage()
          - IMPROVED: optimized code for PageBuilder.setupWithViewPager

v2.1.0

9/27/2018
  • UPDATED: kotlin dependency to v1.2.71
  • UPDATED: gradle dependency to v3.2.0
  • UPDATED: lottie dependency to v2.7.0
  • UPDATED: android support dependency to v28.0.0
  • ADDED: rxjava dependency v2.2.2
  • ADDED: rxandroid dependency v2.1.0
  • ADDED: EventPublisher class use to listen in a channel.
  • CHANGES:
  • To use BaseSwipeFragment include 'me.yokeyword:swipebackfragment:0.4.0' as dependency
  • To use EventPublisher include rxjava & rxandroid as dependency
  • To use PocketDialog include 'com.airbnb.android:lottie:2.7.0' as dependency

v2.0.3

9/6/2018
  • FIXED: PocketDialog.Type.DIALOG_NO_INTERNET_CONNECTION default description
  • FIXED: PocketSpinnerDialog error in inflating PocketRecyclerView
  • FIXED: PocketDialog.Type.DIALOG_NO_INTERNET_CONNECTION default lottieview repeat count
  • UPDATED: PocketDialog setCancelable to false by default
  • UPDATED: PocketDialog.Type.Loading changed dialog to public
  • UPDATED: PocketSpinnerDialog support lambda for listener method
  • UPDATED: changed listener to setOnItemSelectedListener
  • ADDED: new method (setButtonAsSpinner) to assign onclicklistener and view to display text in PocketSpinnerDialog.onItemSelected
  • UPDATED: add view parameter to PocketSpinnerDialog.Listener.onItemSelected

v2.0.2

9/6/2018
  • Fixed: PocketDialog.Type.NoInternetConnection default lottieview

v2.0.1

8/24/2018
  • Updated: kotlin dependency
  • Fixed: exclude 'META-INF/app_release.kotlin_module'

v2.0.0

5/17/2018
  • Changed: version 2.x of codepocket (renamed)
  • Base class for activity,fragment,adapter,viewholder
  • Page Buider for view pager
  • Navigate Util
  • Custom Views
  • Added: PocketSpinnerDialog
  • Added: PocketDialog
  • Removed: retrofit module has been moved to separate library(retrofitkit)