CrowdStrike / ember-headless-table

https://ember-headless-table.pages.dev
MIT License
23 stars 8 forks source link

Feature request: column grouping #189

Open NullVoxPopuli opened 1 year ago

NullVoxPopuli commented 1 year ago

Not dissimilar to https://github.com/CrowdStrike/ember-headless-table/issues/20

group a group b
sub a a sub a b sub b a sub b b
data a data b data c data d

configuration could look like this:

import { defineColumns, GroupedColumns } from 'the-group-plugin';
// ...
headlessTable({
  columns: () => defineColumns([
    {
      groupName: 'group a',
      columns: [...]
    },
   {
      groupName: 'group b',
      columns: [...]
    }
   ]),
  plugins: [GroupedColumns, ColumnReordering, ColumnResizing]
});

I think the existing column Re-ordering and Column re-sizing plugins should still work with grouped columns.