components
components copied to clipboard
[SL-GRID] ability to sort filter options
Provide a general summary of the issue here
filter options in an sl-grid are sorted alphabetically. But this behavior is not always desired. In the screenshot below the locations should be sorted on a sequence number rather than alphabet.
๐ค Expected Behavior?
๐ฏ Current Behavior
๐ Possible Solution
maybe it is possible to add a sort function to the filter options to ColumnDefinition
{
id: 'unitName',
path: 'unitName',
label: msg('Location'),
filter: {
mode: 'select',
sort: (a, b) => a.sequenceNumber - b.sequenceNumber)
}
}
๐ฅ๏ธ Steps to Reproduce
What browsers are you seeing the problem on? (only for bugs in code)
Chrome
If other, please specify.
No response
What operating system are you using?
WSL
๐ค Your name
Frans de Boer
๐งข Your product/team
Magister
๐จ Your Theme(s)
Magister