What I want to do is to arrange the list items (coming from a binding) in a grid with columns. Here is my code:
UI5 1.60 introduces a new control named sap.f.GridList
API that combines functionalities of sap.m.ListBase
(e.g. growing
) with the ability to display list items in a grid layout (display: grid
in CSS internally).
The custom layout GridBoxLayout
API enables displaying the grid items in a responsive way, which can be configured via boxPerRowConfig
and boxMinWidth
properties.
Source: https://ui5.sap.com/#/sample/sap.f.sample.GridListBoxContainer/preview
Note: sap.f.GridList
currently has dependencies to sap.m
, sap.f
, and sap.ui.layout
. Add them to the list of dependencies, e.g. in the app descriptor, so that those libraries can be loaded in parallel with other dependent libs asynchronously:
"sap.ui5": {
"dependencies": {
"libs": {
"sap.ui.core": {},
"sap.m": {},
"sap.f": {},
"sap.ui.layout": {}
}
}
}