0.22.0
Added
- Added
directionsattribute to thecolslot of the table component. This
allows you to override the default sort directions, e.g. to specify
nulls-first or nulls-last. - Added
thead_th_attrsandth_wrapper_attrsattributes to thecolslot
of the table component. - Added
thead_th_attrsattribute to theactionslot of the table component.
Changed
- Renamed
attrsmattribute on thecolandactionslots of the table
component totbody_td_attrsin order to match the naming of the global
table options.
Upgrade guide
Rename the attrs attribute to tbody_td_attrs in both the col slot and the
action slot:
<Flop.Phoenix.table items={@pets} meta={@meta} path={~p"/pets"}>
- <:col :let={p} attrs={[class="my-class"]}><%= p.id %></:col>
- <:action :let={p} attrs={[class="my-class"]}>button</:col>
+ <:col :let={p} tbody_td_attrs={[class="my-class"]}><%= p.id %></:col>
+ <:action :let={p} tbody_td_attrs={[class="my-class"]}>button</:col>
</Flop.Phoenix.table>