Show more

The "Show More" component is a common design pattern used at the bottom of e-commerce category or search engine result pages to load more content triggered by a user interaction.

<sdx-show-more />:HTMLSdxShowMoreElement

Attribute / property (attributes are used in HTML, properties in JavaScript)

from-label / fromLabel = translate("from")

string

 

Label for "from".

increment-by / incrementBy = 10

number

 

How many items to add by each turn.

initial-items / initialItems = 0

number

 

Number of items to start from.

loading = false

boolean

 

Shows a loading spinner and disables the sdx-show-more.

more-label / moreLabel = translate("Show more")

string

 

Label for "more" button.

total-items / totalItems = 0

number

 

Number of all items in total.

Events

sdxshowmore

{ detail: { { currentlyDisplayedItems: number; } } }

 

Emitted when user clicks on the button.

Methods

reset(): Promise<void>

 

Resets the counter.