You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On consecutive renders, Panes flex-grow are set with size.toPrecision(precision)
The difference between the raw size and the rounded one cause a tiny layout shift just after hydration. (eg. flex-grow:64.3238875877 becomes flex-grow:64.3).
Is it possible to apply same constraints on defaultSize than on size to prevent this?
Possible user workaround: store rounded sizes[] in cookie/backend instead of the raw one.
I experiment a tiny layout shift (tenth of a percent) after hydration.
On the server, and during the first render on the client, Panes flex-grow are set with
defaultSize
:react-resizable-panels/packages/react-resizable-panels/src/utils/computePanelFlexBoxStyle.ts
Line 29 in 6d9f1b3
On consecutive renders, Panes flex-grow are set with
size.toPrecision(precision)
The difference between the raw size and the rounded one cause a tiny layout shift just after hydration. (eg. flex-grow:
64.3238875877
becomesflex-grow:64.3
).Is it possible to apply same constraints on
defaultSize
than onsize
to prevent this?Possible user workaround: store rounded
sizes[]
in cookie/backend instead of the raw one.The text was updated successfully, but these errors were encountered: