prevent expand chevron icon from disappearing
This commit is contained in:
parent
4e8a69ec30
commit
4e05d01651
1 changed files with 4 additions and 4 deletions
|
|
@ -134,10 +134,10 @@ export function ExpandableToolbarPreview(props: ExpandableToolbarPreviewProps) {
|
|||
|
||||
useEffect(() => {
|
||||
const resizeObserver = new ResizeObserver(() => {
|
||||
setContentDims({
|
||||
width: contentRef.current?.scrollWidth ?? 0,
|
||||
height: contentRef.current?.scrollHeight ?? 0,
|
||||
});
|
||||
setContentDims(prevValue => ({
|
||||
width: contentRef.current?.scrollWidth ?? prevValue.width,
|
||||
height: contentRef.current?.scrollHeight ?? prevValue.height,
|
||||
}));
|
||||
});
|
||||
|
||||
if (contentRef.current) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue