Containers

Container components for scaffolding basic structure of the page:

<b-container>: wrapper container. When nested with a <b-header> or <b-footer>, all its child elements will be vertically arranged. Otherwise horizontally.

<b-header>: container for headers.

<b-aside>: container for side sections (usually a side nav).

<b-main>: container for main sections.

<b-footer>: container for footers.

<b-spacer>: spacer.

<b-divider>: section divider horizontal or vertical.

TIP

These components use flex for layout, so please make sure your browser supports it. Besides, <b-container>'s direct child elements have to be one or more of the latter four components. And father element of the latter four components must be a <b-container>.

Common layouts

Divider

Spacer

Container Attributes

AttributeDescriptionTypeAccepted ValuesDefault
directionlayout direction for child elementsstringhorizontal / verticalvertical when nested with b-header or b-footer; horizontal otherwise
header-heightset header heightstring / number——
aside-widthset aside widthstring /number——
off-canvasset offcanvas stateboolean—false

Container Slots

NameDescriptionSubtags
—customize default contentContainer / Header / Aside / Main / Footer

Header Attributes

AttributeDescriptionTypeAccepted ValuesDefault
heightheight of the headerstring—60px
fixedfixed positionboolean—false
shadowadd shadowboolean—false
borderadd border bottomboolean—false

Header Slots

NameDescription
—customize default content

Aside Attributes

AttributeDescriptionTypeAccepted ValuesDefault
widthwidth of the side sectionstring—300px

Aside Slots

NameDescription
—customize default content

Main Attributes

AttributeDescriptionTypeAccepted ValuesDefault
fluidfluid widthboolean—false

Main Slots

NameDescription
—customize default content
AttributeDescriptionTypeAccepted ValuesDefault
heightheight of the footerstring—60px
NameDescription
—customize default content

Divider Attributes

AttributeDescriptionTypeAccepted ValuesDefault
verticalvertical directionboolean—false
content-positionposition of inner contentstringcenter / left / rightcenter
no-spacingno spacingboolean—false

Divider Slots

NameDescription
—customize default content

Spacer Attributes

AttributeDescriptionTypeAccepted ValuesDefault
widthhorizontal spacingstring / number—0
heightvertical spacingstring / number—0
Last Updated:
Contributors: Tam Mai