public function GridStack::getBreakpointItems in GridStack 8.2
Returns options.breakpoints.sm.[width, column, grids, nested].
4 calls to GridStack::getBreakpointItems()
- GridStack::getBreakpointItem in src/
Entity/ GridStack.php - Returns options.breakpoints.sm.[width, column, grids, nested].
- GridStack::getJsonSummaryBreakpoints in src/
Entity/ GridStack.php - Returns JSON for options.breakpoints[xs|sm|md|lg|xl] keyed by indices.
- GridStack::getJsonSummaryNestedBreakpoints in src/
Entity/ GridStack.php - Returns JSON for options.breakpoints[xs|sm|md|lg|xl] keyed by indices.
- GridStack::getLastBreakpoint in src/
Entity/ GridStack.php - Returns options.breakpoints.[lg|xl].[column|width|grids|nested].
File
- src/
Entity/ GridStack.php, line 186
Class
- GridStack
- Defines the GridStack configuration entity.
Namespace
Drupal\gridstack\EntityCode
public function getBreakpointItems($breakpoint = 'lg', $type = 'grids', $clean = TRUE) {
$data = $this
->getBreakpoints($breakpoint);
$data = isset($data[$type]) ? $data[$type] : '';
if (in_array($type, [
'grids',
'nested',
])) {
if ($data && ($output = Json::decode($data))) {
// Do not cleanup nested grids as each needs to map to their parent.
$grids = $clean ? array_filter($output) : $output;
return $type == 'grids' ? $grids : $output;
}
return [];
}
return $data;
}