carlosrovira commented on issue #1070:
URL: https://github.com/apache/royale-asjs/issues/1070#issuecomment-771561987
Hi BIlbo,
regarding widths, the concept of "Responsive Grid" is about to divide the
total width in columns. A column is a "GridCell". That means you can divide in
12 columns and each column will be 1/12. 2 columns will be each column 1/2 of
the total width, and so on. In that way you can use a "numerator" and a
"denominator" for type of device. We have setup a phone, tablet, dektop,...
widths so you can do:
```xml
<j:Grid gap="{useGap}">
<j:GridCell desktopNumerator="1" desktopDenominator="1"
tabletNumerator="1" tabletDenominator="1" phoneNumerator="1"
phoneDenominator="1">
<html:Div text="1"/>
</j:GridCell>
...
```
Then in each column you add cards, controls, or any other component.
Depending of the component you need to design for different screen widths and
that means set the widht to 100%, but in other cases, where a component has a
concrete width, you probably will need plan the column so the layout adapts as
you change the width. Sometimes you'll need to change the layout others change
widths, and so on...
With that in mind you have the tools, but the "responsive game" is a world
itself and you need to test thing.
Finally many components in Jewel are implemented with "Adaptiveness" in
mind. For example:
- DataField should work better that Flex control, since the DataChooser is
designed with devices in mind
- NumericStepper, layout in desktop in the legacy flex way, but in devices
the buttons change its position to be more usable and "touchable"
- ComboBox: The popup shows in desktop like in flex, opening from the combo
control position, but in phone and tablets the popup shows from the bottom of
screen filling the space, and the renders are more "touchable".
HTH
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]