Collections (CMS)

How to Configure the Output Parameters of Elements on the Page

9min

You can show or hide specific elements/items in a collection using filters based on the values ​​in the collection fields, and sort the content. You can also set up pagination when displaying a large number of elements/items.

Filtering, Sorting and Pagination

To manage these settings, select the Collection widget and go to the Settings tab (right panel).

Document image


Filters

Add a filter by clicking on the "+" on the right. You can filter the data output depending on the value of a specific field. To do this, select the desired field from the list and set the filter condition.

Document image




Document image




You can add multiple filters using the "+" button, and also remove an already added filter by clicking on the "-" next to it.

Document image


Sorting

Add sorting by clicking on the "+" on the right. You can sort data by selecting the desired field and setting the sorting order.

Document image




Document image




You can add multiple sorting rules using the "+" button, and also remove an already added rule by clicking on the "-" next to it.

Document image


Sorting rules can be moved to change the order in which they are executed. To do this, drag the rule while holding the icon to the left of the name.

Document image


Pagination

You can add pagination by selecting the desired type and number of elements on the page.

Document image




Document image




Pagination types:

  • Pages - Displays buttons to go to the previous and next pages
Document image

  • Load more - Displays a button to load the next pages. 
Document image

  • Page by page - Displays page numbers and arrows to go to the previous and next pages. 
Document image


When you switch pages, the URL in the browser will change, only if:

  • an index page is used
  • the widget is assigned a semantic URL
  • the pagination type is selected: Pages or Page by Page

In other cases, the URL will not change.

Empty state of a collection

You can configure the appearance of the Collection widget when it has no elements/items to display on the page. To do this, in the General section of the settings, select the Empty option.

Document image


The widget will appear on the canvas in an empty state. The default message text is "Nothing found." You can change the message text and customize the design of the block.

Document image