fisharebest / webtrees

Online genealogy
https://webtrees.net
GNU General Public License v3.0
418 stars 290 forks source link

Datatables v2 breaks table layouts #4964

Open ddrury opened 3 months ago

ddrury commented 3 months ago

At commit e124422,

Cell borders missing and cell alignment is wrong (visible on latest demo)

ddrury commented 3 months ago

This is caused by commit https://github.com/fisharebest/webtrees/commit/d11b6d871f0ef4a835494c1d71b139bb6dc3209d updating datatables.net-bs5 to version 2.0.2

1.13.11 works, 2.0.1 doesn't

See Upgrading to DataTables 2

fisharebest commented 3 months ago

Oops - that's not good.

fisharebest commented 3 months ago

I think it's related to https://github.com/DataTables/Dist-DataTables-Bootstrap5/issues/11

ddrury commented 3 months ago

There are at least another couple of things that need attention,

  1. resources/views/lists/datatables-attributes.phtml will need significant work (in particular the new layout attribute)
  2. something I've not fully figured out yet, take the Individual surname list (resources/views/lists/surnames-table.phtml), the first column is right justified and examining the html it gets the class dt-type-numeric. Changing it in the html does correct the alignment but changing the code has no effect so I guess it's added as a default by datatables - does this mean we have to define all columns for every table?
fisharebest commented 3 months ago

I have downgraded to datatables 1.x until the upstream issue is fixed.

Keep this issue open until we can work with 2.x.

miqrogroove commented 2 months ago

I thought it was intentional. I like the wider name fields. Maybe just row borders should come back.