Rename DefaultX, DefaultY to X and Y + add docs

This commit is contained in:
Eric NGUYEN 2022-08-31 15:34:25 +02:00
parent 4cd8f76d7c
commit 4588aa9443
2 changed files with 80 additions and 6 deletions

View file

@ -234,8 +234,8 @@ export function AddContainers(
const right: number = containerConfig.Margin?.right ?? 0;
// Default coordinates
let x = containerConfig.DefaultX ?? 0;
let y = containerConfig.DefaultY ?? 0;
let x = containerConfig.X ?? 0;
let y = containerConfig.Y ?? 0;
let width = containerConfig.Width ?? containerConfig.MaxWidth ?? containerConfig.MinWidth ?? parentClone.properties.width;
let height = containerConfig.Height ?? parentClone.properties.height;
@ -403,8 +403,8 @@ function InitializeDefaultChild(
const bottom: number = currentConfig.Margin?.bottom ?? 0;
const top: number = currentConfig.Margin?.top ?? 0;
const right: number = currentConfig.Margin?.right ?? 0;
let x = currentConfig.DefaultX ?? 0;
let y = currentConfig.DefaultY ?? 0;
let x = currentConfig.X ?? 0;
let y = currentConfig.Y ?? 0;
let width = currentConfig.Width ?? currentConfig.MaxWidth ?? currentConfig.MinWidth ?? parent.properties.width;
let height = currentConfig.Height ?? parent.properties.height;