Skip to content

Commit

Permalink
format
Browse files Browse the repository at this point in the history
  • Loading branch information
mck committed Dec 5, 2024
1 parent 685d6f9 commit 731eb10
Showing 1 changed file with 9 additions and 14 deletions.
23 changes: 9 additions & 14 deletions packages/graph-editor/src/components/DndList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,40 +12,35 @@ interface ISortableHandleElement extends React.HTMLAttributes<HTMLDivElement> {
className?: string;
}

interface ISortableItem extends SortableElementProps, React.HTMLAttributes<HTMLDivElement> {
interface ISortableItem
extends SortableElementProps,
React.HTMLAttributes<HTMLDivElement> {
className?: string;
}

interface ISortableContainer extends SortableContainerProps, React.HTMLAttributes<HTMLDivElement> {
interface ISortableContainer
extends SortableContainerProps,
React.HTMLAttributes<HTMLDivElement> {
className?: string;
}

export const DndTrigger: React.ComponentClass<ISortableHandleElement, unknown> =
SortableHandle(
({
children,
className,
}: React.HTMLAttributes<HTMLDivElement>) => (
({ children, className }: React.HTMLAttributes<HTMLDivElement>) => (
<div className={`${styles.trigger} ${className || ''}`}>{children}</div>
),
);

export const DndItem: React.ComponentClass<ISortableItem, unknown> =
SortableElement(
({
children,
className,
}: React.HTMLAttributes<HTMLDivElement>) => (
({ children, className }: React.HTMLAttributes<HTMLDivElement>) => (
<div className={`${styles.item} ${className || ''}`}>{children}</div>
),
);

export const DndList: React.ComponentClass<ISortableContainer, unknown> =
SortableContainer(
({
children,
className,
}: React.HTMLAttributes<HTMLDivElement>) => {
({ children, className }: React.HTMLAttributes<HTMLDivElement>) => {
return (
<div className={`${styles.container} ${className || ''}`}>
{children}
Expand Down

0 comments on commit 731eb10

Please sign in to comment.