UrlProductCarouselView

UrlProductCarouselView
UrlProductCarouselView

UrlProductCarouselView is a custom view that contains a horizontal RecyclerView created from a ProductCarouselView. As a difference from ProductCarouselView where you need to send all the product information, UrlProductCarouselView only needs an API url that matches the Product List contract. This view fetches all the product information from the first page using the use case GetProductListPage, handling the loading and error states. If the user clicks on "view all", the Product List screen will open with all the pages available.

Anatomy

UrlProductCarouselView anatomy
UrlProductCarouselView anatomy

  1. ProductCarouselView

Usage

You can set it up in code or in the layout:

In code:

fun setUp(urlProductCarousel: UrlProductCarousel)
In the layout:
<com.poqstudio.platform.view.urlproductcarousel.ui.PoqUrlProductCarouselView
android:layout_width="match_parent"
android:layout_height="wrap_content"/>