LayoutClass
extends AbstractLayoutClass
in package
Helper class for managing bootstrap theme's high-level (body vs. sidebar) page layout.
Tags
Table of Contents
- $offcanvas : bool
- $rtl : bool
- $sidebarOnLeft : bool
- __construct() : mixed
- Constructor
- __invoke() : string
- Helper to allow easily configurable page layout -- given a broad class name, return appropriate CSS classes to lay out the page according to the current configuration file settings.
Properties
$offcanvas
protected
bool
$offcanvas
= false
$rtl
protected
bool
$rtl
= false
$sidebarOnLeft
protected
bool
$sidebarOnLeft
= false
Methods
__construct()
Constructor
public
__construct([bool $sidebarOnLeft = false ][, bool $offcanvas = false ][, bool $rtl = false ]) : mixed
Parameters
- $sidebarOnLeft : bool = false
-
Does the sidebar go on the left?
- $offcanvas : bool = false
-
Is offcanvas menu active?
- $rtl : bool = false
-
Are we in right-to-left mode?
Return values
mixed —__invoke()
Helper to allow easily configurable page layout -- given a broad class name, return appropriate CSS classes to lay out the page according to the current configuration file settings.
public
__invoke(string $class[, bool $hasSidebar = true ]) : string
Parameters
- $class : string
-
Type of class to return ('mainbody' or 'sidebar')
- $hasSidebar : bool = true
-
Whether sidebar is available
Return values
string —CSS classes to apply