fix(dashboard): enable sorting by default based on apiColumn state (#14167)

Co-authored-by: Oli Juhl <59018053+olivermrbl@users.noreply.github.com>
This commit is contained in:
Adil BasriandOli Juhl authored and GitHub committed 2025-12-01 16:17:51 +01:00
1 parent b74ef4a784
commit 8f1b97898b
2 files changed
+6 -1

No files matched your search

+5
View File
@@ -0,0 +1,5 @@
---
"@medusajs/dashboard": patch
---
Enable sorting by default based on the `apiColumn` state
@@ -69,7 +69,7 @@ export function useConfigurableTableColumns<TData = any>(
column: apiColumn, // Store column metadata for future use
},
enableHiding: apiColumn.hideable,
enableSorting: false, // Disable sorting for all columns by default
enableSorting: apiColumn.sortable,
headerAlign, // Pass the header alignment to the DataTable
} as any)
})