Page 1 of 1

Few questions about limiting content in LayoutGrid

Posted: Mon Dec 07, 2020 10:04 am
by Markus
WB 15.4.5 x64

Hello Community,

I have a few questions about limiting content in a LayoutGrid and a FlexContainer.

What I actually want to achieve is the following:
The content should appear in a block (LayoutGrid or FlexContainer) that cannot be wider than 1024 pixels.
This works quite well if you place text elements in the LayoutGrid or FlexContainer and set the maximum width of the grid or container to 1024 pixels.

Image

Here is an example how it should look like in the browser.

Image

But I have a question about the scaling behavior of the background image
Text and other elements are correctly limited to 1024 pixels.

But if the LayoutGrid or FlexContainer has a background image, the image itself must have a width of 1024 pixels. Unfortunately I did not find an option in the settings that limits a larger image to the maximum width of 1024 pixels.

The only thing that works is if the image has a width of 1024 pixels and nothing is selected in the background settings of the LayoutGrid or FlexContainer in section "size".

Image

If the image is even 1 pixel larger than 1024 pixels, it is immediately displayed over the entire view width (even if all other settings of the LayoutGrid or FlexContainer are untouched).

Image

Is this behavior normal or should the LayoutGrid or FlexContainer also limit larger images to 1024 pixels if the maximum width is set? Shouldn't the image options 'cover', 'contain' etc. refer to the area up to 1024 pixels?


Another thing concerns the dividers of an LayoutGrid or FlexContainer.
These dividers are always as wide as the view, even if the width is limited to 1024 pixels in the LayoutGrids or FlexContainer.

Image

This looks not good.

Is it possible to limit the dividers so that they are only as wide as the LayoutGrid or FlexContainer? The width setting with the percentage value on the divider is too imprecise for that.

You will find a relating demo projekt here: http://www.filedropper.com/questionmarkus

Markus

Re: Few questions about limiting content in LayoutGrid

Posted: Mon Dec 07, 2020 10:49 am
by Pablo
If you put a '-' in front of the max width then the background will also be limited to 1024 pixels. See also the help.

This only works for the layout grids.

Re: Few questions about limiting content in LayoutGrid

Posted: Mon Dec 07, 2020 11:26 am
by Markus
Great, thanks for your help, Pablo.
This also solves the problem with the too wide dividers.

Your support is really outstanding!