Moved usage of Dimension directly inside the Container class and disable DimensionLayer
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Siklos 2022-08-03 22:38:55 +02:00
parent 8cee366484
commit c5171caaaa
3 changed files with 35 additions and 2 deletions

View file

@ -35,6 +35,18 @@ const getDimensionsNodes = (root: Container): React.ReactNode[] => {
return dimensions;
};
/**
* A layer containing all dimension
*
* @deprecated In order to avoid adding complexity
* with computing the position in a group hierarchy,
* use Dimension directly inside the Container,
* Currently it is glitched as
* it does not take parents into account,
* and will not work correctly
* @param props
* @returns
*/
export const DimensionLayer: React.FC<IDimensionLayerProps> = (props: IDimensionLayerProps) => {
let dimensions: React.ReactNode[] = [];
if (Array.isArray(props.roots)) {