List

class ui.list.List()

Provides a list view component for displaying sortable elements.

Examples

<hoops-list></hoops-list>

<script>
  const list = document.getElementsByTagName("hoops-list")[0];
  list.list = {
    context: {
      elementsData: new Map([[1, 'Item A'], [2, 'Item B']]),
      sortedByValue: true,
      getContent: (context, key, selected) => `${key}: ${context.elementsData.get(key)}`
    }
  };
  list.selected = [1];
</script>

Custom Element

hoops-list

Since

2025.8.0

Index

Constructors

Properties

Methods

Constructors

ui.list.List.constructor()
List(): List

Returns: List

Properties

ui.list.List.list

Context wrapper providing list data access methods. Reassign to trigger updates.

ui.list.List.selected
selected: number[]

Array of selected element keys. Reassign to trigger updates.

Default

```ts [] ```

Methods

ui.list.List.updateContext()
updateContext(): void

Triggers a re-render by reassigning list context.

Returns: void

void
ui.list.List.updateSelected()
updateSelected(): void

Triggers a re-render by reassigning selected elements.

Returns: void

void