Skip to content

Commit

Permalink
style for component fcns
Browse files Browse the repository at this point in the history
  • Loading branch information
birm committed May 31, 2024
1 parent a77415a commit 36661fd
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@ import VisSortableItem from './VisSortableItem/VisSortableItem';

import './VisDataTableControl.css';

const SortableContainer = ({ children }) => <div>{children}</div>;
function SortableContainer({ children }) {
return <div>{children}</div>;
}

export default class VisDataTableControl extends PureComponent {
constructor(props) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { useDrag } from 'react-dnd';

import './VisSortableItem.css';

const DragHandle = () => {
function DragHandle() {
const [{ isDragging }, drag] = useDrag({
collect: (monitor) => ({
isDragging: !!monitor.isDragging(),
Expand All @@ -17,9 +17,9 @@ const DragHandle = () => {
<FontAwesomeIcon icon={faGripLines} style={{ opacity: isDragging ? 0.4 : 1 }} />
</div>
);
};
}

const VisSortableItem = (props) => {
function VisSortableItem(props) {
return (
<div className="vis-sortable-item">
<DragHandle />
Expand All @@ -37,6 +37,6 @@ const VisSortableItem = (props) => {
</div>
</div>
);
};
}

export default VisSortableItem;

0 comments on commit 36661fd

Please sign in to comment.