loading... Pacem JS

DataGrid Component

The PacemDataGridElement is a convenient component for tabled data.
At first, you can build it up via declarative PacemDataColumnComponent children plus a referred datasource, like in the tiny example below.

DataColumn Metadata

The PacemDataGridElement also accepts a referred metadata array of DataColumnMetadata items.
Every DataColumnMetadata item provides a comprehensive set of information and customization for each data column.

Explore the sorting capabilities of the datacolumns and the rescalability of the first datacolumn in the following example:

[ { "prop": "capitalCity", "headCell": { "name": "Capital City" }, "dataCell": {"selectMode": "row"}, "isSortable": true, "width": 1, "order": 2, "hide": false }, { "prop": "name", "headCell": { "name": "Region" }, "isSortable": true, "width": 2, "minPixelWidth": 200, "order": 1, "dataCell": {"selectMode": "row"} }, { "prop": "seaCoasts", "headCell": { "name": "Coastal" }, "dataCell": { "horizontalAlign": "center", "cssClass": [ "text-primary" ] }, "dataType": "boolean", "width": "auto", "order": 3 }, { "prop": "istatCode", "headCell": { "name": "Code", "description": "Administrative classification code (known as Codice ISTAT)", "tooltip": "md", "textEllipsis": true }, "dataType": "number", "dataCell": { "format": { "minimumIntegerDigits": 2 }, "autoTooltip": false, "textEllipsis": true, "selectMode": "row" }, "isSortable": true, "isRescalable": true, "minPixelWidth": 40, "width": "auto", "order": 0 } ]