refactor: small style tweaks

- cursor styles on dnd
This commit is contained in:
Carlos Valente
2025-07-27 16:46:08 +02:00
committed by Carlos Valente
parent 3ce539af2a
commit 8a7f8c8ebc
8 changed files with 23 additions and 5 deletions
@@ -15,13 +15,15 @@ interface SortableCellProps {
export function SortableCell({ header, injectedStyles, children }: SortableCellProps) {
const { column, colSpan } = header;
const { attributes, listeners, setNodeRef, transform, transition } = useSortable({
const { attributes, listeners, setNodeRef, transform, transition, isDragging } = useSortable({
id: column.id,
});
// build drag styles
const dragStyle = {
...injectedStyles,
zIndex: isDragging ? 2 : 'inherit',
cursor: isDragging ? 'grabbing' : 'grab',
transform: CSS.Translate.toString(transform),
transition,
};