← All Components
<mth-load-more>
Explicit load-more pagination control integrating DataController cursor appending, progress summary, error retry, and standalone cancelable mth-load-more dispatch.
When NOT to use: Use a lightweight @methane-ui/css layout class instead of a custom element when static CSS suffices.
Live Interactive Preview
Ready · interact with <mth-load-more>, or toggle Theme, Direction (LTR/RTL), or props above.
Multi-Framework Playground & Snippets
<script type="module" src="@methane-ui/ui/load-more"></script>
<mth-load-more loaded-count="0" total-count="0">Example</mth-load-more>import '@methane-ui/ui/load-more';
import '@methane-ui/react';
export function Example() {
return <mth-load-more loaded-count="0" total-count="0">Example</mth-load-more>;
}<script setup lang="ts">
import '@methane-ui/ui/load-more';
</script>
<template>
<mth-load-more loaded-count="0" total-count="0">Example</mth-load-more>
</template>import { Component, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
import '@methane-ui/ui/load-more';
import { MthLoadMoreDirective } from '@methane-ui/angular';
@Component({
standalone: true,
schemas: [CUSTOM_ELEMENTS_SCHEMA],
imports: [MthLoadMoreDirective],
template: `<mth-load-more loaded-count="0" total-count="0">Example</mth-load-more>`,
})
export class ExampleComponent {}<script lang="ts">
import '@methane-ui/ui/load-more';
import MthLoadMore from '@methane-ui/svelte/MthLoadMore.svelte';
</script>
<MthLoadMore loaded-count="0" total-count="0">Example</MthLoadMore>Properties & Attributes
| Property | Attribute | Type | Default | Description |
|---|---|---|---|---|
loading | loading | boolean | false | Reflects or forces the loading state. |
complete | complete | boolean | false | Marks the collection as fully loaded. |
disabled | disabled | boolean | false | Prevents manual load-more and retry triggers. |
loadedCount | loaded-count | number | 0 | Optional explicit count of currently loaded items when not bound to dataSource. |
totalCount | total-count | number | 0 | Optional explicit total count of items when not bound to dataSource. |
dataSource | — | unknown | null | null | Optional DataSource<T> connected to DataController. |
renderItem | — | (item: unknown, index: number) => unknown | — | Optional custom renderer for items returned by DataController. |
Events
| Event | Detail Type | Description |
|---|---|---|
mth-load-more | { cursor: string | null } | Cancelable event emitted when the user activates load-more or retry. |
APG Keyboard Matrix
| Key | Direction | When | Expected Behavior |
|---|---|---|---|
| Enter | both | Load-more or retry button is focused | Triggers loading the next page of items |
| Space | both | Load-more or retry button is focused | Triggers loading the next page of items |
Accessibility Checklist
| Category | Requirement | Verified By |
|---|---|---|
| aria | All aria-* IDREFs resolve within the same DOM root (ADR-003). | scanSameRootAria |
| focus | delegatesFocus: true with zero host internals.role (ADR-014). | lint-plugin & spec-compiler |
| contrast | Renders legible borders, focus outlines, and selection indicators under forced-colors: active. | Playwright forced-colors matrix |
| keyboard | Implements all 2 APG keyboard transitions across LTR/RTL. | mth-load-more.spec.test.ts |
| states | Exposes ElementInternals CustomStateSet flags: :state(loading), :state(complete), :state(disabled), :state(error), :state(empty). | Conformance suite |
| i18n | Routes 7 UI/ARIA strings through @methane-ui/core i18n catalog. | Locale context test |