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 statebooleanfalse

Container Slots

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

Header Attributes

AttributeDescriptionTypeAccepted ValuesDefault
heightheight of the headerstring60px
fixedfixed positionbooleanfalse
shadowadd shadowbooleanfalse
borderadd border bottombooleanfalse

Header Slots

NameDescription
customize default content

Aside Attributes

AttributeDescriptionTypeAccepted ValuesDefault
widthwidth of the side sectionstring300px

Aside Slots

NameDescription
customize default content

Main Attributes

AttributeDescriptionTypeAccepted ValuesDefault
fluidfluid widthbooleanfalse

Main Slots

NameDescription
customize default content
AttributeDescriptionTypeAccepted ValuesDefault
heightheight of the footerstring60px
NameDescription
customize default content

Divider Attributes

AttributeDescriptionTypeAccepted ValuesDefault
verticalvertical directionbooleanfalse
content-positionposition of inner contentstringcenter / left / rightcenter
no-spacingno spacingbooleanfalse

Divider Slots

NameDescription
customize default content

Spacer Attributes

AttributeDescriptionTypeAccepted ValuesDefault
widthhorizontal spacingstring / number0
heightvertical spacingstring / number0
Last Updated:
Contributors: Tam Mai