SurfaceBulma.Table (surface_bulma v0.5.1)

A Bulma HTML table.

You can create a table by passing data to it and defining columns using the Table.Column component.

Look in the documentation for Table.Column for information on how to do sorting.

properties

Properties

  • id :string, required: true - The id of the live component (required by LiveView for stateful components).

  • data :generator, required: true, root: true - The data that populates the table internal

  • expanded :boolean, default: true - The table is expanded (full-width)

  • bordered :boolean, default: false - Add borders to all the cells

  • striped :boolean, default: false - Add stripes to the table

  • class :css_class, default: default - The CSS class for the wrapping <div> element

  • row_class :fun - A function that returns a class for the item's underlying <tr> element. The function receives the item and index related to the row.

slots

Slots

  • cols, generator_prop: :data, required: true - The columns of the table

Link to this section Summary

Link to this section Functions

Link to this function

handle_event(binary, map, socket)

Callback implementation for Phoenix.LiveComponent.handle_event/3.

Callback implementation for Phoenix.LiveComponent.mount/1.

Link to this function

render(assigns)

Callback implementation for Phoenix.LiveComponent.render/1.

Link to this function

update(assigns, socket)

Callback implementation for Phoenix.LiveComponent.update/2.