-2

Example photo of preview in Yelp:

enter image description here

When I use some Android or IOS application or Web, I can see the preview of the content before it is loaded sometimes. I mean gray part of the view of list which has ripple effect sometimes. I think many applications are using that function similarly, so I wonder there is some built-in or 3rd party library of Android for that preview function. Or, it is developed by their own code. If it is their own code, how to implement that kinds of preview?

forceson
  • 85
  • 8

2 Answers2

1

This is called Shimmer originally developed by facebook.

iOS: https://github.com/facebook/Shimmer

android: https://github.com/facebook/shimmer-android

Here is SO post of how to use it on list for iOS

Arnab
  • 4,216
  • 2
  • 28
  • 50
0

Here are some libraries.

  1. https://github.com/elye/loaderviewlibrary

  2. https://github.com/ethanhua/Skeleton

You need to convert your layout elements to loader elements. Like below

<com.elyeproj.loaderviewlibrary.LoaderTextView
     android:layout_width="match_parent"
     android:layout_height="wrap_content" />

and

<com.elyeproj.loaderviewlibrary.LoaderImageView
     android:layout_width="100dp"
     android:layout_height="100dp" />
Khemraj Sharma
  • 57,232
  • 27
  • 203
  • 212