clear width/hieght on done

This commit is contained in:
Seth Trowbridge 2023-05-20 08:15:09 -04:00
parent 52c731c794
commit de6115248a
1 changed files with 3 additions and 2 deletions

View File

@ -17,7 +17,7 @@ export const Menu =(props:{children:React.JSX.Element|React.JSX.Element[]})=>
const [stateGet, stateSet] = React.useContext(CTX);
const refElement:React.MutableRefObject<HTMLElement|null> = React.useRef( null );
const refControl:React.MutableRefObject<CollapseControls|null> = React.useRef( null );
const classDefault = "relative transition-all duration-700 border";
const classOpen = "h-auto w-auto top-10 px-4 ";
const classShut = "h-0 w-[300px] top-0 px-0";
@ -57,7 +57,8 @@ export function Collapser(inElement:HTMLElement, initialState = false)
inEvent.stopPropagation();
if (userMode)
{
inElement.style.height = "auto";
inElement.style.height = "";
inElement.style.width = "";
inElement.style.overflow = "visible";
}
userDone(userMode);