Skip to content

MazContainer

MazContainer is a lightweight component to wrap content with optional header, border, elevation, and rounded corners - a simpler alternative to MazCard

Before use it, you should install the MazUi plugin in your project, follow instructions in Getting Started

TIP

MazContainer is designed to be a lighter alternative to MazCard. Use it when you need a simple container with basic styling options without the extra features like galleries, collapsible content, or actions.

Basic usage

Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s.

With title

Add a header with a title using the title prop or the title slot.

Section Title
Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s.

With icons

Add icons to the header using left-icon and right-icon props.

Settings
Configure your application settings here.
User Profile
View and edit your profile information.

Styling options

Elevation

Add shadow to make the container stand out.

Container with elevation effect and no border.

Bordered

By default, the container has a border. You can disable it.

With border (default)
This container has a border.
Without border
This container has no border.

Transparent

Remove the background color with the transparent prop.

Transparent container
This container has a transparent background.

Rounded sizes

Customize the border radius with the rounded-size prop.

none
sm
md
lg
xl
full

No padding

Remove internal padding with :padding="false".

No padding
Content without container padding - useful for custom layouts.

Full width

Use the block prop to make the container take full width.

Full width container
This container spans the full width of its parent.

Custom header

Use the header slot to fully customize the header, or use title, icon-left, and icon-right slots for more granular control.

Custom Header New
Content with a fully customized header.

Combining options

Dashboard Overview

Users

1,234

Revenue

$12.5k

Orders

567

Props

NameDescriptionTypeRequiredDefaultPossible values
titleTitle of the card in headerstringNoundefined-
elevationAdd elevation to the componentbooleanNofalse-
paddingAdd padding to the contentbooleanNotrue-
borderedAdd border to the componentbooleanNotrue-
rounded-sizeSize of the rounded'none' | 'sm' | 'md' | 'lg' | 'xl' | 'full'Noundefined'none' | 'sm' | 'md' | 'lg' | 'xl' | 'full'
transparentRemove background colorbooleanNofalse-
overflow-hiddenHide overflowbooleanNotrue-
left-iconAdd icon to the header on the leftIconComponent | stringNoundefined-
right-iconAdd icon to the header on the rightIconComponent | stringNoundefined-
icon-sizeSize of the iconMazIconProps['size']Nomd-
blockDisplay the container in full widthbooleanNofalse-

Slots

NameDescriptionBindings
headerReplace the header
icon-lefticon left
titletitle
icon-righticon right
defaultcontent of the container