Skip to content

Commit

Permalink
chore: add comments
Browse files Browse the repository at this point in the history
  • Loading branch information
VsevolodX committed Mar 27, 2024
1 parent 6497fa9 commit 7336180
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -57,14 +57,15 @@ const Puller = styled(Box)(({ theme, isResizing }) => ({
top: 8,
left: "calc(50% - 15px)",
}));
const TRANSITION_DURATION = 500;
const TRANSITION_DURATION = 500; // ms
const DRAWER_MIN_HEGHT = 20;
export default function ResizableDrawer({ children, open, onClose, refocusChild = false, childIdToRefocus, paperProps, containerRef, }) {
const { height, setHeight, isResizing, enableResize, disableResize } = useResize({
minHeight: DRAWER_MIN_HEGHT,
refocusChild,
childIdToRefocus,
});
// Styles to make the drawer fit the container
const drawerStyles = containerRef && containerRef.current
? {
position: "absolute",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ const Puller = styled(Box)(({ theme, isResizing }: { theme?: Theme; isResizing:
left: "calc(50% - 15px)",
}));

const TRANSITION_DURATION = 500;
const TRANSITION_DURATION = 500; // ms
const DRAWER_MIN_HEGHT = 20;
export default function ResizableDrawer({
children,
Expand All @@ -128,6 +128,7 @@ export default function ResizableDrawer({
childIdToRefocus,
});

// Styles to make the drawer fit the container
const drawerStyles: CSSProperties =
containerRef && containerRef.current
? {
Expand Down

0 comments on commit 7336180

Please sign in to comment.